diff --git a/.github/workflows/native-release.yml b/.github/workflows/native-release.yml index 8ae47c946..336fab11a 100644 --- a/.github/workflows/native-release.yml +++ b/.github/workflows/native-release.yml @@ -161,6 +161,19 @@ jobs: # development profile, which needs a registered device), so client/fastlane/Fastfile # imports the stored distribution certificate and creates the App Store profile # through the API key. + # The tag's message, past its subject line, is what testers read under + # "What to Test": one short line per change worth trying. + - name: TestFlight notes from the tag + if: startsWith(github.ref, 'refs/tags/') + run: | + git fetch --force --depth=1 origin "+${GITHUB_REF}:${GITHUB_REF}" + { + echo 'TESTFLIGHT_NOTES<> "$GITHUB_ENV" + - name: Build and upload to TestFlight working-directory: client env: diff --git a/client/fastlane/Fastfile b/client/fastlane/Fastfile index b477cb0cb..11dd1da92 100644 --- a/client/fastlane/Fastfile +++ b/client/fastlane/Fastfile @@ -103,9 +103,13 @@ platform :ios do # Upload to App Store Connect; it shows up in TestFlight after Apple finishes processing. # Internal testing needs no App Review, so nothing here submits the app for review. + # "What to Test" comes from the release tag's message (native-release.yml). Apple only + # takes it once the build is processed, so with notes the lane waits for that. + notes = ENV.fetch("TESTFLIGHT_NOTES", "").strip upload_to_testflight( api_key: key, - skip_waiting_for_build_processing: true, + changelog: notes.empty? ? nil : notes, + skip_waiting_for_build_processing: notes.empty?, skip_submission: true, ) end diff --git a/client/src/components/Journey/JourneyEntryCover.test.tsx b/client/src/components/Journey/JourneyEntryCover.test.tsx index 5b746454a..cbab5a8f3 100644 --- a/client/src/components/Journey/JourneyEntryCover.test.tsx +++ b/client/src/components/Journey/JourneyEntryCover.test.tsx @@ -84,10 +84,12 @@ describe('JourneyEntryCover', () => { const { container, rerender } = render( {}} />, ) - expect(container.querySelector('button')!.className).toContain('w-[136px]') + expect(container.querySelector('button')!.className).toContain('scale-100') rerender( {}} />) - expect(container.querySelector('button')!.className).toContain('w-[164px]') + // Drawn larger, not laid out larger: the box stays, so nothing beside it moves. + expect(container.querySelector('button')!.className).toContain('scale-[1.18]') + expect(container.querySelector('button')!.className).toContain('w-[136px]') }) it('FE-JRN-COVER-007: a shared journey serves its photos through the share token', () => { diff --git a/client/src/components/Journey/JourneyEntryCover.tsx b/client/src/components/Journey/JourneyEntryCover.tsx index 689cb5973..2d23eb7d9 100644 --- a/client/src/components/Journey/JourneyEntryCover.tsx +++ b/client/src/components/Journey/JourneyEntryCover.tsx @@ -103,8 +103,13 @@ export default function JourneyEntryCover({ // The whole card is the photo, so its own ring is what separates it from the // map behind. A suggestion is drawn as an outline rather than a solid thing: // it is somewhere you planned to be, not somewhere you have written about. - className={`relative flex-none overflow-hidden rounded-[18px] text-start transition-[width,height] duration-150 ${ - isActive ? 'h-[180px] w-[164px] shadow-[0_18px_40px_-16px_rgba(0,0,0,.55)]' : 'h-[152px] w-[136px] shadow-[0_10px_24px_-14px_rgba(0,0,0,.5)]' + // + // Every card takes the same room and the active one is only drawn larger: + // growing its box moved every card after it once a swipe had landed, and the + // snap then pulled the strip again, which read as a jolt (carousels keep the + // room for it with their gap and top padding). + className={`relative h-[152px] w-[136px] flex-none origin-bottom overflow-hidden rounded-[18px] text-start transition-[transform,box-shadow] duration-300 ease-[cubic-bezier(.2,.8,.2,1)] motion-reduce:transition-none ${ + isActive ? 'z-[1] scale-[1.18] shadow-[0_18px_40px_-16px_rgba(0,0,0,.55)]' : 'scale-100 shadow-[0_10px_24px_-14px_rgba(0,0,0,.5)]' } ${src ? '' : emptyGround} ${isSuggestion ? 'opacity-90' : ''}`} // backgroundImage, not background: the shorthand would drop the opaque colour // the class supplies and leave the map showing through a card that is only a diff --git a/client/src/components/Journey/MobileMapTimeline.test.tsx b/client/src/components/Journey/MobileMapTimeline.test.tsx index 4c6227c78..6399907a7 100644 --- a/client/src/components/Journey/MobileMapTimeline.test.tsx +++ b/client/src/components/Journey/MobileMapTimeline.test.tsx @@ -150,7 +150,7 @@ describe('MobileMapTimeline', () => { await userEvent.click(segments[1]) const { cards } = carouselOf(container) - expect(cards[1].querySelector('button')!.className).toContain('w-[164px]') + expect(cards[1].querySelector('button')!.className).toContain('scale-[1.18]') }) it('FE-COMP-JMAPTL-003: the first entry starts out active and drives the map highlight', () => { diff --git a/client/src/components/Journey/MobileMapTimeline.tsx b/client/src/components/Journey/MobileMapTimeline.tsx index 28acc53c8..6a0ca4c44 100644 --- a/client/src/components/Journey/MobileMapTimeline.tsx +++ b/client/src/components/Journey/MobileMapTimeline.tsx @@ -187,7 +187,7 @@ export default function MobileMapTimeline({ />
({ if (settleTimer != null) window.clearTimeout(settleTimer); settleTimer = window.setTimeout(pickNearestCard, 150); }; + // Where the browser says when the snap has landed, the card grows right then + // instead of a beat later; the timer stays for the ones that do not. + const onScrollEnd = () => { + if (settleTimer != null) window.clearTimeout(settleTimer); + settleTimer = null; + pickNearestCard(); + }; el.addEventListener('scroll', onScroll, { passive: true }); + el.addEventListener('scrollend', onScrollEnd, { passive: true }); return () => { el.removeEventListener('scroll', onScroll); + el.removeEventListener('scrollend', onScrollEnd); if (settleTimer != null) window.clearTimeout(settleTimer); }; }, [entries.length, pickNearestCard]); diff --git a/client/src/mobile/screens/journey/MJourneyDetail.tsx b/client/src/mobile/screens/journey/MJourneyDetail.tsx index 28d9a4963..ea346b810 100644 --- a/client/src/mobile/screens/journey/MJourneyDetail.tsx +++ b/client/src/mobile/screens/journey/MJourneyDetail.tsx @@ -498,7 +498,7 @@ export default function MJourneyDetail({ journeyId, embedded = false }: JourneyD />
{entries.map((entry, i) => (