Releases: saket/telephoto
Releases · saket/telephoto
0.15.1
0.15.0
This release introduces a new library for telephoto
: Modifier.zoomablePeekOverlay()
, a modifier for displaying transient overlaid zoom effect, inspired by Instagram.
AsyncImage(
modifier = Modifier.zoomablePeekOverlay(…),
model = "https://example.com/image.jpg",
contentDescription = "…",
)
zoom-overlay-demo.mp4
Other changes
- Auto-enabled ultra HDR mode for compatible images
- Customizable over-zoom behavior using
OverzoomEffect
(example). - #9: iOS support for
Modifier.zoomable()
- #118: Added partial support for AVIF images
- #120:
SubSamplingImageSource
is no longersealed
. Apps can now display custom content such as PDFs and maps usingSubSamplingImage()
.
Bug fixes
- #114: Fixed flicker in
ZoomableImage()
when a new image is loaded - #122: Fixed a bug where images stopped loading under system stress
- #129, #110: Worked around crashes related to color spaces in Compose UI
Dependency updates
- Compose multiplatform: 1.7.1
- Compile SDK: 35
- Kotlin: 2.1.0
0.14.0
New changes
- Support for Coil 3 (
me.saket.telephoto:zoomable-image-coil3:{version}
) - State restoration of zoom & pan values across orientation changes
- Zoom & pan transformations now render synchronously instead of lagging behind by a frame, eliminating flicker during layout size changes
- Added ZoomableImageState#isImageDisplayedInFullQuality
- Added new APIs for custom
ZoomableImageSource
implementations:
Bug fixes
- #95: Removed explicit recycling of bitmap decoders
- #97: Added protection against
NaN
velocities - #99: Added handling for non-existent content URIs to prevent crashes
- #110: Added workaround for a Compose UI issue with unknown color spaces
ZoomableImage()
will now display itscontentDescription
even if the image isn't loaded yet- Content alignment can now be updated even if the image is zoomed in
- Prevented multiple buffering of
SubSamplingImageSource.rawSource()
Deprecations
ZoomableContentLocation#size()
is no longer usedSubSamplingImageState#isImageLoaded
→isImageDisplayed
SubSamplingImageState#isImageLoadedInFullQuality
→isImageDisplayedInFullQuality
ZoomableState#setContentLocation()
→setContentLocationSynchronously()
0.13.0
0.12.1
New changes
- Added
DoubleClickToZoomListener.cycle()
, which allows setting a custom max zoom factor for double clicks.
Bug fixes
- Fixed a bug that prevented back buttons from working when
ZoomableImage()
was focused.
0.12.0
New changes
- #78: Support for keyboard and mouse shortcuts (by @evant)
- #67: New APIs in
ZoomableState
for controlling zoom from code:panBy
,zoomBy
, andzoomTo
- #32: New
onDoubleClick
parameters inZoomableImage()
andModifier.zoomable()
for customizing double-click behavior - #91: Reduced
minSdk
to 21 (by @iwb-florien-flament) - Significantly reduced the amount of work required by a
ZoomableImageSource
by offloading the detection of bad content URIs toSubSamplingImageSource.contentUriOrNull()
Bug fixes
- #93:
NullPointerException
when an image is zoomed before it is initialized - #50:
FileNotFoundException: No content provider
when disk caching of an image is disabled usingCache-Control
HTTP headers. - Fixed infinite reloading of images when unstable image request listener are used in
ZoomableAsyncImage()
. This removes the need for usingremember
withImageRequest.listener
andImageRequest.placeholder
values.
0.11.2
Bug fixes
- #84: Fixed an issue causing placeholders to sometimes take up the full screen (by @rharter)
- #37: Prevent a crash in
ZoomableAsyncImage()
after the app's disk cache is cleared - #83: Correctly display single-frame GIFs
New changes
- Increase memory cache hit rate with Coil by using
Precision.INEXACT
0.10.0
0.9.0
0.8.0
Breaking changes
- Reordered
SubSamplingImage()
's parameters to moveModifier
below all required parameters.
New changes
- Update Compose UI to
1.6.1
and Compose Multiplatform to1.6.0-rc02
- Introduced ZoomableState#transformedContentBounds for observing transformed content bounds. This can be used for drawing decorations around the content or performing hit tests.
- Placeholder images now respond to click listeners. Additionally, they will swallow all other zoom gestures instead of ignoring them.
- #3: Read color space of bitmaps from Coil and Glide.
Bug fixes
- #60, #65: Improved detection of pinch-to-zoom gestures.
- #8: Composables with
Modifier.zoomable()
are now drawn on the first frame. This fixes their broken layout preview. - #58: Fixed a resource leak when an image's EXIF metadata is read.
ZoomableState#resetZoom()
now calculates the content's position on the same UI frame.- Images no longer flicker on start when they can't zoom-in any further.