Checking for 'Closest' here isn't needed since TransSnap.snapTarget callback is already ensuring the selected target is the closest. Also don't reuse the pre-calculated distance, since its only valid to do this when there are no snap points and this isn't a significant gain to avoid the extra calculation - run once per update.