Posted by Nick Butcher, Product Manager, Jetpack Compose Today, the Jetpack Compose August ‘26 release is stable! 12 across core Compose modules (see the full BOM mapping ), introducing rich visual APIs like Mesh Gradients and Wide Color Gamut (WCG) support, structural layout features like named areas in Grid, seamless integration with Android’s Credential Manager, and significant testing and performance improvements. 1.
As a reminder, Compose will always target the latest compileSdk . Learn more about this change here . onVisibilityChanged() , which provides more precise visibility threshold tracking.
12 introduces MeshGradientPainter to help you create multi-point, organic color gradients. paint(gradientPainter) ) For more information and examples, see the documentation . Wide Color Gamut & HDR Support Modern displays offer extended color fidelity and higher dynamic range.
12, full pipeline support for Wide Color Gamut (P3) and HDR rendering has been enabled across Compose graphics, paint, and shaders. Colors defined in non-sRGB color spaces (such as Display P3) are preserved through to platform rendering without color clamping. g.
g Bt2020Hlg on Android 13 and below), or if the app is running on Android 9 (API 28) and below. graphicsLayer , which you can use to increase the visual bounds of the layer beyond its measured size. Apply LayerOutsets to avoid the implicit clipToBounds behavior when the layer is promoted to an offscreen buffer.
Styles At Google I/O, we shared our early vision for the Compose Styles API —a unified, performant way to style components. Since then, we have continued building the underlying architecture to guarantee strict type safety and predictable correctness, and to support building custom design systems. To ensure we get this foundational layer correct, the API will remain experimental, and you can expect breaking changes.
Runtime Optimizations Keyed SideEffect Overload SideEffect now supports key arguments, which lets you fire one-shot side effects whenever specific keys change. This can lead to better performance compared to using a LaunchedEffect or DisposableEffect when you don’t need the coroutine or dispose block. SideEffect is up to 90% faster than LaunchedEffect and around 20% faster than DisposableEffect .
Note that SideEffect runs its effect before DisposableEffect and LaunchedEffect , so use caution if migrating existing effects to this API, especially for LaunchedEffects that rely on being dispatched to start after the current frame is completed. logScreenView(userId, screenName) } } Animation DeferredTargetAnimation has graduated out of experimental status. g.
for predictive back gesture tracking. , tracking a swipe gesture). Seamless handoff: Once the deferred phase ends, the transition engine takes over and performs a seamless handoff, including velocity transfer, to the automatic transition.
Shared element support: A new permitTransformDuringDeferredTransition flag in SharedContentConfig controls whether shared elements visually transform along with their parent containers during the deferred transition phase. DeferredAnimatedContent( targetState = targetScreen, mutableTransformSpec = { MutableContentTransform { // Manually manipulate properties during the deferred phase initialContentTransform { scale = swipeProgress } } } ) { screen -> ScreenContent(screen) } Below are two demos of use cases where a gesture-driven animation is handed off to a triggered animation: Text, Input & Platform Integrations Editable Text Formatting New APIs offer rich-text formatting for editable text in BasicTextField . edit { ...
} or an InputTransformation ). Additionally, TextFieldBuffer provides getSpanStyles() and getParagraphStyles() APIs that return TrackedRange objects, allowing you to read, update, or remove applied styles. To complement formatting creation, TextFieldState now exposes a read-only textStyles property for querying active styles across ranges, while TextFieldBuffer provides originalTextStyles to inspect formatting state prior to an edit.
Text formatting and custom annotations are persisted across configuration changes. textStyles Text Selection A new SelectionState API provides programmatic control and observability over text selection within a SelectionContainer . Hoisting a SelectionState object via rememberSelectionState() and passing into SelectionContainer exposes selectedTexts as a reactive list of AnnotatedStrings and provides methods like selectAll() , clear() , select(TextRange) , and extendSelectionByWord() .
Additionally, use getSelectableTexts() to retrieve all selectable text items in layout order and select text across composables in the SelectionContainer using a global range. credentialslibrary ). By attaching the new credentialRequest semantics property with CredentialRequestData , text inputs can prompt passkeys, saved credentials, or sign-in requests directly within the user input flow.
semantics { credentialRequest = credentialData } ) } Other notable changes: Support for font variation settings in downloadable fonts . Enabled auto-scrolling when dragging text selection beyond the viewport in SelectionContainer . Added support for automatic interaction sounds (clicks and focus navigation) to Compose components, with a new SoundEffectOnInteraction composable to allow opt-out.
Note that as a consequence of this change, semantics click listeners must now be called from the main thread, which may affect a small number of test cases. KeyboardType now includes Date , Time , DateTime , and SignedDecimal . System by default, while RevealLastTyped serves as an absolute override.
Layout Enhancements Named Areas in Grid Layout Building complex 2D layouts is now easier with named areas in the @Experimental Grid component. Rather than managing numeric column and row indices across items, you can define semantic regions in your GridConfigurationScope and position composables by area name. gridItem(areaId = "content")) } } For more information, see the documentation .
Performance As with every release, we continue to invest in Compose's performance to ensure that the framework helps you to build beautiful, performant apps. In this release we've focused on improving startup performance and are now seeing Time to Initial Display (the time it takes for an app to produce its first frame) that is comparable to Views in our benchmarks . 12 introduces new test APIs designed to reduce test execution times and eliminate flakiness during state sampling: hasPendingWork : Passively checks if the UI has pending work without advancing the clock, which is ideal for manual animation loops.
g. animation tests). runWithoutImplicitWait { // This is most effective when querying multiple nodes in a single frame.
// It prevents the redundant synchronization overhead that would // otherwise occur on every individual query. left) } } } } Other notable changes: The captureToImage API now allows you to capture a popup or dialog together with its anchor in a single bitmap. Added onRootWithViewInteraction to scope Compose semantic searches to specific Android Views.
This simplifies testing hybrid UIs, such as RecyclerViews, without requiring unique test tags in production code. @PreviewWrapper annotations can now be applied to custom @MultiPreview classes, enabling reusable preview setups (such as custom themes) across multiple components. Happy Composing!
12 makes app development easier and more expressive than ever, with mesh gradients, wide color gamut support, downloadable variable fonts, Credential Manager integration, and faster testing tools. As always, we value your input, so please share your feedback on these changes or what you'd like to see next on our issue tracker . Happy composing!
Android Developers Blog
android-developers.googleblog.com