about summary refs log tree commit diff
path: root/src/view/com/lightbox/ImageViewing/components/ImageItem/ImageItem.tsx
Commit message (Collapse)AuthorAgeFilesLines
* [Lightbox] Always rely on Expo Image cache (#6189)dan2024-11-091-0/+2
| | | | | | | | | | | | | | | * Inline useImageAspectRatio * Switch AutoSizedImage to read dimensions from Expo Image cache * Include thumbnail dimensions in image data * Use dims from Expo Image cache in lightbox * Fix wiring so all thumbnails get dimensions * Fix type * Oops
* [Lightbox] Open animation (#6159)dan2024-11-091-5/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Measure all rects for embeds * Measure avi rects too * Animate lightbox in and out * Account for safe area in the animation * Tune spring times * Remove null checks for measurements * Remove superfluous view * Block swipe while opening * Interpolate width/height on native side for Android * Make it fast by animating only affine transforms * Fix tall image final state The initial animation frame is still off on both platforms. * Try to squeeze perf * Avoid blank images during animation on iOS * Fix bad rebase * Fix a huge memory issue due to expo/expo#24894 * Fix last frame flash * Fix thum dim calculation for tall images
* [Lightbox] New dismiss gesture (#6135)dan2024-11-081-2/+7
| | | | | | | | | | | | | | | | | | | | | | | | | * Make iOS scrollview bounded to the image I've had to remove the dismiss handling because the scroll view no longer scrolls at rest. * Fix double-tap not working right after a vertical swipe It seems like for some reason the vertical swipe is still being handled by the scroll view, so double tap gets eaten while it's "coming back". But you don't really see it moving. Weird. * Add an intermediate LightboxImage component * Hoist useImageDimensions up * Implement xplat dismiss gesture This is now shared between platforms, letting us animate the backdrop and add a consistent "fly away" behavior. * Optimize Android compositing perf * Fix supertall images For example, https://bsky.app/profile/schlagteslinks.bsky.social/post/3l7y4l6yur72e * Fix oopsie
* Remove SCREEN from lightbox layout (#6124)dan2024-11-061-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | * Assign an ID to lightbox and use it as a key * Consolidate lightbox props into an object * Remove unused prop * Move SafeAreaView declaration * Keep SafeAreaView always mounted When exploring Android animation, I noticed its content jumps on the first frame. I think this should help prevent that. * Pass safe area down for measurement * Remove dependency on SCREEN in Android event handlers * Remove dependency on SCREEN in iOS event handlers * Remove dependency on SCREEN on iOS * Remove dependency on SCREEN on Android * Remove dependency on JS calc in controls * Use flex for iOS layout
* Sort imports (#6009)dan2024-10-291-0/+1
| | | | | * Mark import sort/order/style rules as error * npm run lint -- --fix
* use `showControls` to show/hide live text icon on ios (#2982)Hailey2024-02-231-0/+1
|
* Toggle lightbox controls on tap (#1687)dan2023-10-131-0/+1
| | | | | | | * Make the lightbox controls animation smoother * Toggle controls on tap * Disable pointer events when hidden
* Change lightbox to use Pager (#1666)dan2023-10-101-3/+1
| | | | | | | | | * Change lightbox to use Pager * Fix crash issue on ios --------- Co-authored-by: Paul Frazee <pfrazee@gmail.com>
* Rewrite Android lightbox (#1624)dan2023-10-051-1/+4
|
* Remove unused lightbox options (#1616)dan2023-10-051-4/+0
| | | | | | | | | | | | | | | | | | | | | | | * Inline lightbox helpers * Delete unused useImagePrefetch * Delete unused long press gesture * Always enable double tap * Always enable swipe to close * Remove unused onImageIndexChange * Inline custom Hooks into ImageViewing * Declare LightboxFooter outside Lightbox * Add more TODO comments * Inline useDoubleTapToZoom * Remove dead utils, move utils used only once
* Fix all type errorsPaul Frazee2023-01-261-0/+21