How a semitone shift works
Every chord root sits somewhere on a 12-note chromatic scale: C, C#/Db, D, D#/Eb, E, F, F#/Gb, G, G#/Ab, A, A#/Bb, B, then back to C. Shifting a chord by a number of semitones just moves its root that many steps along this cycle and keeps the chord's quality, so a G7 shifted up 3 semitones becomes a Bb7, and a Cmaj7 shifted down 2 semitones becomes a Bbmaj7. Picking a from and to key instead of a raw number does the same thing after first working out the semitone gap between the two keys.
Extended and slash chords transpose the same way, piece by piece: in D/F#, both the D and the F# move by the shift amount, so shifting that chord up a whole tone (2 semitones) gives E/G#. A chord like Asus4 or Cadd9 keeps its suffix untouched and only the letter name moves, since the sus, add, dim, and similar labels describe the chord's shape rather than its root.