195 KiB
1.7.0-beta02 (September 2024)
Changes since release/1.7.0-beta01
Breaking changes
Desktop
Resources
Features
Multiple Platforms
iOS
Desktop
Fixes
- CMP-5066 PR
- CMP-5892 PR
- CMP-5939 PR
- CMP-6558 PR
- CMP-6576 PR
- CMP-1230 PR
- CMP-1230 PR
- CMP-5069 PR
- CMP-4303 PR
- CMP-5835 PR
- CMP-1403 PR
- CMP-4735 PR
Dependencies
-
Gradle Plugin
org.jetbrains.compose
, version1.7.0-beta02
. Based on Jetpack Compose libraries: -
Lifecycle libraries
org.jetbrains.androidx.lifecycle:lifecycle-*:2.8.2
. Based on Jetpack Lifecycle 2.8.4 -
Navigation libraries
org.jetbrains.androidx.navigation:navigation-*:2.8.0-alpha10
. Based on Jetpack Navigation 2.8.0-rc01 -
Material3 Adaptive libraries
org.jetbrains.compose.material3.adaptive:adaptive*:1.0.0-alpha03
. Based on Jetpack Material3 Adaptive 1.0.0-rc01
1.7.0-beta01 (September 2024)
Changes since release/1.7.0-alpha03
Breaking changes
iOS
UIKitView
andUIKitViewController
inpackage androidx.compose.ui.interop
are deprecated. New API are mentioned in deprecation message. Deprecated invocations should work fine unless customonResize
is used, it is disallowed now and will print a warning.- Actual of expected
InteropView
on iOS isUIResponder
now instead ofUIView
. It's the first common ancestor forUIViewController
andUIView
, both of which can be integrated using iOS interop APIs - The app will crash by default, if
CADisableMinimumFrameDurationOnPhone
is not set to true inInfo.plist
. Use newly addedComposeUIViewControllerConfiguration.enforceStrictPlistSanityCheck
to opt-out of this behavior
Features
Multiple Platforms
iOS
- New
UIKitView
andUIKitViewController
API inpackage androidx.compose.ui.viewinterop
. Support ofonReset
to reuse the interop composable emitted node and avoid excessive native views reallocations, fine-grain touches strategy control (cooperative with explicit time delay, non-cooperative where no touches are received by Compose, ignoring touches)
Desktop
- Added support for input methods (languages such as Chinese, Korean, Arabic) to BasicTextField(TextFieldState, ...)
- Add dynamic Drag&Drop target indication (🚫 icon under cursor if currently there is no valid drop target under it)
Resources
- Added support of test resources in Compose Multiplatform projects
- Added support of multi-module resources in JVM-only projects
Fixes
Multiple Platforms
- (prerelease fix) Fix redirect on android artifacts for "window-core" module
iOS
Desktop
Resources
- (prerelease fix) Fix a resource reading on iOS 12
- (prerelease fix) Fix resource reading on Java 11
Gradle Plugin
Dependencies
-
Gradle Plugin
org.jetbrains.compose
, version1.7.0-beta01
. Based on Jetpack Compose libraries: -
Lifecycle libraries
org.jetbrains.androidx.lifecycle:lifecycle-*:2.8.1
. Based on Jetpack Lifecycle 2.8.4 -
Navigation libraries
org.jetbrains.androidx.navigation:navigation-*:2.8.0-alpha09
. Based on Jetpack Navigation 2.8.0-beta05 -
Material3 Adaptive libraries
org.jetbrains.compose.material3.adaptive:adaptive*:1.0.0-alpha02
. Based on Jetpack Material3 Adaptive 1.0.0-rc01
1.7.0-alpha03 (August 2024)
Changes since 1.7.0-alpha02
Features
Multiple Platforms
- Skia is updated to m126
- Commonized
org.jetbrains.compose.material3:material3-window-size-class
module - Commonized
org.jetbrains.compose.material3.adaptive:adaptive*
modules
Resources
Fixes
Desktop
- [macOS] Fix crash when right-clicking an empty
SelectionContainer
or on the padding of aText
inside aSelectionContainer
- (prerelease fix) Fix input methods position on the screen and
NullPointerException: Cannot read field
iOS
Gradle Plugin
Dependencies
-
Gradle Plugin
org.jetbrains.compose
, version1.7.0-alpha03
. Based on Jetpack Compose libraries: -
Lifecycle libraries
org.jetbrains.androidx.lifecycle:lifecycle-*:2.8.0
. Based on Jetpack Lifecycle 2.8.0 -
Navigation libraries
org.jetbrains.androidx.navigation:navigation-*:2.8.0-alpha09
. Based on Jetpack Navigation 2.8.0-beta05 -
Material3 Adaptive libraries
org.jetbrains.compose.material3.adaptive:adaptive*:1.0.0-alpha01
. Based on Jetpack Material3 Adaptive 1.0.0-beta04
To use Material3 Adaptive add the dependencies for the artifacts you need in the build.gradle
file for your app or module:
dependencies {
implementation("org.jetbrains.compose.material3.adaptive:adaptive:1.0.0-alpha01")
implementation("org.jetbrains.compose.material3.adaptive:adaptive-layout:1.0.0-alpha01")
implementation("org.jetbrains.compose.material3.adaptive:adaptive-navigation:1.0.0-alpha01")
}
1.7.0-alpha02 (July 2024)
Changes since 1.7.0-alpha01
Features
Multiple Platforms
- The
clickable
modifier now responds to NumPadEnter and Spacebar, too, in addition to Enter LocalLifecycleOwner
moved from Compose UI tolifecycle-runtime-compose
so that its Compose-based helper APIs can be used outside of Compose UI
iOS
Desktop
Resources
- Now the gradle plugin generates resources map to find a resource by a string ID
- To avoid constant reading raw font bytes on each Font usage on non-android targets, there was added the font cache. Android has own font cache inside the platform implementation
Fixes
Multiple Platforms
iOS
- Interop views are now correctly clipped when their measured clipped and unclipped bounding boxes don't match
- Touches inside interop views are not exclusive to them and are processed on Compose side as well.
- Fix
material3.ModalBottomSheet
safe area usage - Fix hiding interop element during quick scroll
- (prerelease fix) Fixed floating cursor isn't working
- Fixed the keyboard appearing when selecting from SelectionContainer
- Fix status bar padding on iPad devices
- VoiceOver doesn't allow to perform a11y actions (scrolling, activate, customActions) when disabled() semantics is present in affected element
Desktop
- Fix scrolling non-same direction nested scrolls with trackpad
- Fix fling velocity for precise wheel scroll
- (prerelease fix) Fix remaining focus indication after a click
Resources
- (prerelease fix) Fix an android app compose resources packaging broken after introduction AS previews
- Now drawables from upper DPIs will be downscalled to the expected size. (the same behavior as on Android)
Gradle plugin
Dependencies
-
Gradle Plugin
org.jetbrains.compose
, version1.7.0-alpha02
. Based on Jetpack Compose libraries: -
Lifecycle libraries
org.jetbrains.androidx.lifecycle:lifecycle-*:2.8.0
. Based on Jetpack Lifecycle 2.8.0 -
Navigation libraries
org.jetbrains.androidx.navigation:navigation-*:2.8.0-alpha08
. Based on Jetpack Navigation 2.8.0-beta03
1.7.0-alpha01 (July 2024)
Changes since 1.6.11
Highlights
- Compose Multiplatform resources are stored in the android assets now. This fixes Android Studio Preview and cases such as a rendering resource files in WebViews or Media Players
- Shared Element Transitions
- Safe Args in Navigation Compose
Breaking changes
Android
Features
iOS
- Initial iOS floating cursor support
- Added
accessibilityEnabled: Boolean = true
argument toUIKitView
andUIKitViewController
preferredStatusBarStyle
,preferredStatysBarAnimation
andprefersStatusBarHidden
are added toComposeUIViewControllerDelegate
to allow status bar appearance modification
Desktop
- Add constructor with
RenderSettings
toComposePanel
. Added a classRenderSettings
withval isVsyncEnabled: Boolean?
. When set totrue
gives a hint to renderer implementation of the particularComposePanel
to reduce the latency between the input and visual changes in exchange for possible screen tearing - Add public
moveEnabled
andpositionPercentage
setters inSplitPaneState
Resources
- Speed resources web rendering up by the reading a cached value instantly
- If there is no resource with suitable density, use resource with the most suitable density, otherwise use default (similar to the Android logic)
- Add a customization for resources directories. Now it is possible to use e.g downloaded resources
Fixes
Multiple Platforms
- Fix "ComposePanel. Focus moves to child after focusing/unfocusing the main window"
- Don't show code completion for non-existenst API in
commonMain
that fails on Android withNoSuchMethodException
- Fix order of interop elements in some cases
- Fixed
Popup
jerking during ripple effect animation - Fix applying
ShaderBrush
to part ofAnnotatedString
- Fix text
brush
animation and optimized updating some visual text properties (applying time is reduced up to 40%) - Fix initial cursor position in the empty
TextField
with explicitly setTextAlignment
- Fix focus for editable
TextField
insideExposedDropdownMenuBox
iOS
- Pressing directional keys on a physical keyboard connected to iOS device doesn't cause a crash
- Dismissing popup or dialogue within a very short timespan after its creation doesn't cause a crash
- Fix missing invalidations during native view resize
- Fixed a memory spike when continuously resizing the
ComposeUIViewController
(such as when used in modal sheet presentation context with different detents) - visibility of selection handles in single-line textfields with LTR + RTL text in iOS
Desktop
- Fix possible
UninitializedPropertyAccessException
indesktopTest
- Fixed
ComposePanel.requestFocus()
, making it correctly assign focus to the first focusable child - When using
ComposePanel
inside a Swing application on macOS, VoiceOver will now correctly go into theComposePanel
when traversing accessible elements - When using
ComposePanel
inside a Swing application on Windows with NVDA turned on, focus will now correctly go into theComposePanel
when traversing with (ctrl)-shift-tab - Correctly save
WindowState
with unspecifiedsize
instead of crashing - Fix
IndexOutOfBoundsException
crash on Windows when traversing a11y elements
Web
- Process
keydown
andkeyup
keys for identified keys from virtual keyboard - Allow preloading the fallback fonts. This enables the usage of emojis and other unicode characters without manually composing the Text with AnnotatedString
- Make sure the web app distribution doesn't contain a duplicate
skiko.wasm
Resources
- Delete
contextClassLoader
usage on JVM targets - Create an empty resource dir with "podspec" task instead "podInstall"
- Fix resource accessors escaping. Now it is possible to use resources with names: "package", "is", "item_$xxx" etc
- Read exactly requested count of bytes from InputStream on jvm platforms
Gradle Plugin
- Make sure tryGetSkikoRuntimeIfNeeded is executed only during the task execution
- Delete outdated build services
Dependencies
-
Gradle Plugin
org.jetbrains.compose
, version1.7.0-alpha01
. Based on Jetpack Compose libraries: -
Lifecycle libraries
org.jetbrains.androidx.lifecycle:lifecycle-*:2.8.0
. Based on Jetpack Lifecycle 2.8.0 -
Navigation libraries
org.jetbrains.androidx.navigation:navigation-*:2.8.0-alpha08
. Based on Jetpack Navigation 2.8.0-beta03
1.6.11 (June 2024)
Changes since 1.6.10
Fixes
Multiple Platforms
- Fix endless re-layout when layout is invalidated by measure, which includes measuring
TextField(singleLine=true)
withIntrinsicSize
- Fix container size for
Dialog
centering insideImageComposeScene
iOS
Desktop
- Fix
DropdownMenu
/Popup
positioning when a window is moved to a screen with a different density - Fix possible scrolling without animation on some mouse models
Web
Resources
Gradle Plugin
Dependencies
-
Gradle Plugin
org.jetbrains.compose
, version1.6.11
. Based on Jetpack Compose libraries: -
Lifecycle libraries
org.jetbrains.androidx.lifecycle:lifecycle-*:2.8.0
. Based on Jetpack Lifecycle 2.8.0 -
Navigation libraries
org.jetbrains.androidx.navigation:navigation-*:2.7.0-alpha07
. Based on Jetpack Navigation 2.7.7
1.6.10 (May 2024)
Changes since 1.6.2
Highlights
- Experimental multiplatform support of
Lifecycle
andViewModel
. See documentation for details - Experimental multiplatform support of Jetpack Navigation. See documentation for details or check out the nav_cupcake project which was converted from the Navigate between screens with Compose Android codelab
- Support multi-module projects and libraries publication with Compose resources (Kotlin
2.0.0-Beta05
or higher is required)
Breaking changes
- Since Kotlin
2.0-RC2
, the additionalorg.jetbrains.kotlin.plugin.compose
Gradle plugin is required. See the migration guide
Features
Multiple Platforms
- Add font rasterization settings in paragraph style
- Localize internal strings in
ui
,material
andmaterial3
iOS
- Magnifier for iOS 17+
- Support software keyboard inset in
Dialog
- iOS a11y dialogues and popups integration
- OS logging integrated with
trace
- Support accessibility scroll
- Improve iOS a11y sync behavior
- Add throttle for text context menu updates
- Support a11y for interop views
- Support
HapticFeedback
on iOS - iOS support
LiveRegion
semantics in a11y
Desktop
- Add an
alwaysOnTop
flag toDialogWindow
- Basic support of
BasicTextField2
: #1227, #1264 full support and support for other platforms is planned for 1.7.0
Web
- Listen to browser clipboard events and bind them with Compose TextFieldSelectionManager and SelectionManager
- Introduce ComposeViewport function that renders content in parent container
- Introduce minimal virtual keyboard support
- Basic IME keyboard support
- Some experimental Compose Multiplatform Gradle plugin APIs for web app configuration were deprecated. Their usage is not required anymore.
Resources
- Support three letters locales
- Add DSL to configure compose resources
- Support plural string resource
- Add option to disable compose resources generation
- XML resource optimizations
- Get resource files as URI
- Support source set's hierarchy for compose resources
- Support SVG drawables for non android platforms
- Delete the experimental mark from the stable resources library API
- Add functions to retrieve bytes from drawable or font resources
- To disable the Compose Resources publication and the multimodule support in cases of problems add
org.jetbrains.compose.resources.multimodule.disable=true
to the rootgradle.properties
Gradle Plugin
- Add possibility to modify the macOS minimum version
- Make desktop preview task fully configuration cache compliant
- Option to pack jars as uber JAR, support Proguard for uber JAR
Fixes
Multiple Platforms
- Fix
NaN
font metrics by initializing typeface forTextStyle
- Fix render order of interop views
- Reimplement SortedSet for JS/Native to improve performance
- Allow drawing outside of platform layers
- Prevent a few unnecessary re-compositions in
Popup
andDesktopMenu
- Propagate composition locals to layers in the (re)composition phase
- Move the effects and synthetic events dispatching to after the draw phase in the render loop
- Fix Kotlin/Native can't use
T::class
in inline function of@Composable
- Fix missing recomposition after showing
Dialog
iOS
- Fix keyboard disappear on IME action
- Fix nested scroll when
Pager
involved in scrolling process - Fix a11y wrong bounds calculation
- Delay tap indication inside scroll
- Fix keyboard opening when scrolling begins within a
TextField
- Fix IME window insets and view offset when keyboard appears
- Fix animation frozen after app went background
- Fixed appearing of text editing menu (#1269, #1293)
- Fix content rect calculation in
SelectionManager
Desktop
- Fix nested scrolling on mouse wheel
- Trigger fling callbacks on mouse wheel scroll (fixes
Pager
and lazy column/row spanning) - Fix
Pager
direction detection for mouse wheel - Fix missing clicks inside
SelectionContainer
- Fix clipping bounds of
SwingPanel
- Locale-aware date formatting for desktop
- Pass the id of the node whose layout changed to accessibility controllers
WINDOW
layer fixes: #1181, #1185, #1187, #1189- Fix crash when we resize
ComposePanel
after re-adding it to the hierarchy - Fix propagation of
LocalLocalization
- Re-show the tooltip on mouse-move following a click in TooltipArea
- Fix the direction of scrolling when pressing on the scrollbar track with
reverseLayout=true
- Fix crash and allow selection in
SelectionContainer
to start when drag starts below the bounds of the visible text - Fix a crash on Windows without
dcomp.dll
- Fix crash when creating SwingRedrawer on DirectX
- Option to not throw
RenderException
when use OpenGL on macOS - Sync all AccessibilityControllers when an a11y query is received
- Fix crash when modifying Compose state from a non-UI thread
- Close
Popup
/Dialog
by clicking any mouse button outside
Web
- Implement actual
fun isCopyKeyEvent
- Fix metadata compilation
- Support
sendKey
test utility function on wasm target - Send correct window sized on resize
- Dispose all listened events alongside with the application being disposed
- Modify
buttonFlags
only onPress
andRelease
- Fix keyboard mappings
- Correct density rounding in
ComposeWindow::resize
- Fix
MouseEvent
toPointerButton
mapping - Correct virtual keyboard mode resolution
- Fix browser clipboard events handling on Windows
- Rename
viewportContainer
toviewportContainerId
parameter inComposeViewport
Resources
- Fix resource accessors compilation when there are huge number of resource files
- Init resource accessors lazily and in external function to avoid
MethodTooLargeException
- Fix
Res
class generation if the library is declared as 'api' - Fix resource packaging in APK when 'build' task is used with AGP 8.2+
- Use first of preferred locales instead of a current on iOS
- Fix
readResourceBytes
function on Android if font is located under qualified directory - Fix android fonts in APKs
- Handle special characters for quantity strings
- Select default resource if there are no exact language+region or default language match
- Add validation checks on invalid XML or item type
Gradle plugin
Dependencies
-
Gradle Plugin
org.jetbrains.compose
, version1.6.10
. Based on Jetpack Compose libraries: -
Lifecycle libraries
org.jetbrains.androidx.lifecycle:lifecycle-*:2.8.0
. Based on Jetpack Lifecycle 2.8.0 -
Navigation libraries
org.jetbrains.androidx.navigation:navigation-*:2.7.0-alpha07
. Based on Jetpack Navigation 2.7.7
1.6.10-rc03 (May 2024)
Changes since 1.6.10-rc02
Fixes
iOS
Dependencies
-
Gradle Plugin
org.jetbrains.compose
, version1.6.10-rc03
. Based on Jetpack Compose libraries: -
Lifecycle libraries
org.jetbrains.androidx.lifecycle:lifecycle-*:2.8.0-rc03
. Based on Jetpack Lifecycle 2.8.0 -
Navigation libraries
org.jetbrains.androidx.navigation:navigation-*:2.7.0-alpha06
. Based on Jetpack Navigation 2.7.7
1.6.10-rc02 (May 2024)
Changes since 1.6.10-rc01
Known issues
- iOS compilation might fail on some projects with
org.jetbrains.kotlin.backend.konan.llvm.NativeCodeGeneratorException: Exception during generating code for following declaration: private fun $init_global()
Features
Web
Fixes
iOS
Resources
- To disable the Compose Resources publication and the multimodule support in cases of problems add
org.jetbrains.compose.resources.multimodule.disable=true
to the rootgradle.properties
- (prerelease fix) Fix resources with cocoapods integration
- (prerelease fix) Fix AGP lint tasks dependency issues
Dependencies
-
Gradle Plugin
org.jetbrains.compose
, version1.6.10-rc02
. Based on Jetpack Compose libraries: -
Lifecycle libraries
org.jetbrains.androidx.lifecycle:lifecycle-*:2.8.0-rc02
. Based on Jetpack Lifecycle 2.8.0-rc01 -
Navigation libraries
org.jetbrains.androidx.navigation:navigation-*:2.7.0-alpha05
. Based on Jetpack Navigation 2.7.7
1.6.10-rc01 (May 2024)
Changes since 1.6.10-beta03
Known issues
- A project with Android flavors cannot be imported into any IDE if it has Compose Multiplatform resources 1.6.10 + Kotlin 2.0.0
- If you experience the
org.jetbrains.compose.resources.MissingResourceException: Missing resource with path: ...
error after switching your Kotlin version from 1.9 to 2.0 (or the other way around), this might be resolved by manually cleaning thebuild
directories in your project - this includes thebuild
folders located in the root and module folders of your project.
Fixes
Desktop
- (prerelease fix) Fix inconsistency in closing
Dialog
by mouse clicking on scrim that was introduced by1.6.10-beta02
Web
- Fix browser clipboard events handling on Windows
- Rename
viewportContainer
toviewportContainerId
parameter inComposeViewport
Dependencies
-
Gradle Plugin
org.jetbrains.compose
, version1.6.10-rc01
. Based on Jetpack Compose libraries: -
Lifecycle libraries
org.jetbrains.androidx.lifecycle:lifecycle-*:2.8.0-rc01
. Based on Jetpack Lifecycle 2.8.0-rc01 -
Navigation libraries
org.jetbrains.androidx.navigation:navigation-*:2.7.0-alpha04
. Based on Jetpack Navigation 2.7.7
1.6.10-beta03 (April 2024)
Changes since 1.6.10-beta02
Highlights
Breaking changes
- Since Kotlin
2.0-RC2
, the additionalorg.jetbrains.kotlin.plugin.compose
Gradle plugin is required. See the migration guide org.jetbrains.androidx.navigation
is downgraded to2.7
from2.8
. Some API can no longer be available
Known issues
lifecycle-runtime
breaks Compose UI compatibility with Java 11 on desktop, it requires Java 17 or above now. Expected to be fixed in1.6.10-rc01
- A project with Android flavors cannot be imported into any IDE if it has Compose Multiplatform resources 1.6.10 + Kotlin 2.0.0
Features
Multiple Platforms
- (prerelease fix) Publish additional targets for
lifecycle-runtime-compose
Lifecycle
- (prerelease fix) Update Lifecycle handling on iOS based on feedback
Web
Fixes
Multiple Platforms
- (prerelease fix) Fix frozen composition with pager and text field
Desktop
- Fix crash when creating SwingRedrawer on DirectX
- Option to not throw
RenderException
when use OpenGL on macOS
Resources
Gradle plugin
Dependencies
-
Gradle Plugin
org.jetbrains.compose
, version1.6.10-beta03
. Based on Jetpack Compose libraries: -
Lifecycle libraries
org.jetbrains.androidx.lifecycle:lifecycle-*:2.8.0-beta02
. Based on Jetpack Lifecycle 2.8.0-beta01 -
Navigation libraries
org.jetbrains.androidx.navigation:navigation-*:2.7.0-alpha03
. Based on Jetpack Navigation 2.7.7
1.6.10-beta02 (April 2024)
Changes since 1.6.10-beta01
Known issues
lifecycle-runtime
breaks Compose UI compatibility with Java 11 on desktop, it requires Java 17 or above now. Expected to be fixed in1.6.10-rc01
navigation-compose:2.8.0-*
on Android brings Compose1.7.*
dependency and might cause compatibility issues with1.6.*
Features
Lifecycle
- Publish additional targets for non-compose modules
- Commonize
inline fun <reified VM> viewModel(..)
- Provide
ViewModelStoreOwner
by Compose view
Resources
- Delete the experimental mark from the stable resources library API
- Add functions to retrieve bytes from drawable or font resources
Navigation
Fixes
Multiple Platforms
- Fix Kotlin/Native can't use
T::class
in inline function of@Composable
- Fix missing recomposition after showing
Dialog
- (prerelease fix) Fix shadow behind dialogs in platform-layer mode
iOS
- Fixed appearing of text editing menu (#1269, #1293)
- Fix content rect calculation in
SelectionManager
- (prerelease fix) Fix crash on loading
UITextLoupeSession
on old iOS versions - (prerelease fix) Fix memory leaks (#1292, #1302)
Desktop
- Sync all AccessibilityControllers when an a11y query is received
- Fix crash when modifying Compose state from a non-UI thread
- Close
Popup
/Dialog
by clicking any mouse button outside - (prerelease fix) Fix
KeyEvent
binary compatibility
Web
- Fix
MouseEvent
toPointerButton
mapping - Correct virtual keyboard mode resolution
- (prerelease fix) Correct
Key.isTypedEvent
behavior
Navigation
- (prerelease fix) Fix overriding dependency visibility
- (prerelease fix) Fix finding graph without route
Dependencies
-
Gradle Plugin
org.jetbrains.compose
, version1.6.10-beta02
. Based on Jetpack Compose libraries: -
Lifecycle libraries
org.jetbrains.androidx.lifecycle:lifecycle-*:2.8.0-beta01
. Based on Jetpack Lifecycle 2.8.0-beta01 -
Navigation libraries
org.jetbrains.androidx.navigation:navigation-*:2.8.0-alpha02
. Based on Jetpack Navigation 2.8.0-alpha05
1.6.10-beta01 (April 2024)
Changes since 1.6.2
Highlights
- Experimental multiplatform support of
Lifecycle
andViewModel
. See documentation for details - Experimental multiplatform support of Jetpack Navigation. See documentation for details or check out the nav_cupcake project which was converted from the Navigate between screens with Compose Android codelab
- Support multi-module projects and libraries publication with Compose resources (Kotlin
2.0.0-Beta05
or higher is required)
Known issues
- ⚠️ Crash at startup on pre-iOS 17 devices due to loading
UITextLoupeSession
lifecycle-runtime
breaks Compose UI compatibility with Java 11 on desktop, it requires Java 17 or above now.inline fun <reified VM> viewModel(...)
is not available from common due to compiler bug. Please usefun <VM> viewModel(KClass, ...)
overload instead- Compose Multiplatform doesn't provide default
ViewModelStoreOwner
yet. For usingViewModel
s outside ofNavHost
you need to provide custom store owner viaLocalViewModelStoreOwner
Features
Multiple Platforms
- Add font rasterization settings in paragraph style
- Localize internal strings in
ui
,material
andmaterial3
iOS
- Magnifier for iOS 17+
- Support software keyboard inset in
Dialog
- iOS a11y dialogues and popups integration
- OS logging integrated with
trace
- Support accessibility scroll
- Improve iOS a11y sync behavior
- Add throttle for text context menu updates
- Support a11y for interop views
- Support
HapticFeedback
on iOS - iOS support
LiveRegion
semantics in a11y
Desktop
- Add an
alwaysOnTop
flag toDialogWindow
- Basic support of
BasicTextField2
: #1227, #1264 full support and support for other platforms is planned for 1.7.0
Web
- Listen to browser clipboard events and bind them with Compose TextFieldSelectionManager and SelectionManager
- Introduce ComposeViewport function that renders content in parent container
- Introduce minimal virtual keyboard support
Resources
- Support three letters locales
- Add DSL to configure compose resources
- Support plural string resource
- Add option to disable compose resources generation
- XML resource optimizations
- Get resource files as URI
- Support source set's hierarchy for compose resources
- Support SVG drawables for non android platforms
Gradle Plugin
- Add possibility to modify the macOS minimum version
- Make desktop preview task fully configuration cache compliant
- Option to pack jars as uber JAR, support Proguard for uber JAR
Fixes
Multiple Platforms
- Fix
NaN
font metrics by initializing typeface forTextStyle
- Fix render order of interop views
- Reimplement SortedSet for JS/Native to improve performance
- Allow drawing outside of platform layers
- Prevent a few unnecessary re-compositions in
Popup
andDesktopMenu
- Propagate composition locals to layers in the (re)composition phase
- Move the effects and synthetic events dispatching to after the draw phase in the render loop
iOS
- Fix keyboard disappear on IME action
- Fix nested scroll when
Pager
involved in scrolling process - Fix a11y wrong bounds calculation
- Delay tap indication inside scroll
- Fix keyboard opening when scrolling begins within a
TextField
- Fix IME window insets and view offset when keyboard appears
- Fix animation frozen after app went background
Desktop
- Fix nested scrolling on mouse wheel
- Trigger fling callbacks on mouse wheel scroll (fixes
Pager
and lazy column/row spanning) - Fix
Pager
direction detection for mouse wheel - Fix missing clicks inside
SelectionContainer
- Fix clipping bounds of
SwingPanel
- Locale-aware date formatting for desktop
- Pass the id of the node whose layout changed to accessibility controllers
WINDOW
layer fixes: #1181, #1185, #1187, #1189- Fix crash when we resize
ComposePanel
after re-adding it to the hierarchy - Fix propagation of
LocalLocalization
- Re-show the tooltip on mouse-move following a click in TooltipArea
- Fix the direction of scrolling when pressing on the scrollbar track with
reverseLayout=true
- Fix crash and allow selection in
SelectionContainer
to start when drag starts below the bounds of the visible text - Fix a crash on Windows without
dcomp.dll
Web
- Implement actual
fun isCopyKeyEvent
- Fix metadata compilation
- Support
sendKey
test utility function on wasm target - Send correct window sized on resize
- Dispose all listened events alongside with the application being disposed
- Modify
buttonFlags
only onPress
andRelease
- Fix keyboard mappings
- Correct density rounding in
ComposeWindow::resize
Resources
- Fix resource accessors compilation when there are huge number of resource files
- Init resource accessors lazily and in external function to avoid
MethodTooLargeException
- Fix
Res
class generation if the library is declared as 'api' - Fix resource packaging in APK when 'build' task is used with AGP 8.2+
- Use first of preferred locales instead of a current on iOS
- Fix
readResourceBytes
function on Android if font is located under qualified directory - Fix android fonts in APKs
- Handle special characters for quantity strings
- Select default resource if there are no exact language+region or default language match
Dependencies
-
Gradle Plugin
org.jetbrains.compose
, version1.6.10-beta01
. Based on Jetpack Compose libraries: -
Lifecycle libraries
org.jetbrains.androidx.lifecycle:lifecycle-*:2.8.0-alpha01
. Based on:- Lifecycle 2.8.0-alpha04
- Lifecycle Runtime Compose 2.8.0-alpha02 (due to Compose
1.6.*
compatibility)
-
Navigation libraries
org.jetbrains.androidx.navigation:navigation-*:2.8.0-alpha01
. Based on Jetpack Navigation 2.8.0-alpha05
1.6.2 (April 2024)
Changes since 1.6.1
Features
Common
Fixes
iOS, Desktop, Web
- Propagate composition locals to layers in the (re)composition phase
- Add transactions to
FocusOwnerImpl
takeFocus
andreleaseFocus
to prevent crash when a window is re-shown - Fix crash and allow selection in
SelectionContainer
to start when drag starts below the bounds of the visible text
iOS
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.6.1 (March 2024)
Changes since 1.6.0
Features
Common
Fixes
iOS, Desktop, Web
- Consume less CPU for text field cursor blinking
- Fix Material3 slider getting stuck while dragging
- Fix
ExposedDropdownMenuBox
recomposing unnecessarily
iOS
- Fix AppStore/TestFlight verification failure due to skiko/skia conflicting names with ICU library
- Fix
Pager
scroll with scrollable content on top - Fix crash when selecting a character before the punctuation sign
- Fix unintended state reset
- Context menu isn't showing in empty textfield
- Fix a logical error causing Compose tree corruption and consequent crash
- Fix
TextField
crash when using speech-to-text
Web
Desktop
- Fix additional windows creation with
COMPONENT
layer type - Keep adding interop order consistent between platforms
Resources
- Support three letters locales
- Init resource accessors lazily and in external function to avoid MethodTooLargeException
- Fix
Res
class generation if the library is declared as 'api' - Fix
regionCode
crash on iOS before 17 - Fix package name of generated
Res
file when project is building forJsTarget
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.6.0 (February 2024)
Changes since 1.5.12
Highlights
An overview of highlights for this release is also available in the Compose Multiplatform documentation: What's new in 1.6.0.
Common
- Resource library improvements (an example project)
- Experimental support is available for tests in common code
- Support Kotlin 2.0.0-Beta4
iOS, Desktop, Web
- Support
LineHeightStyle.Trim
- Add a way to use fonts installed on the system
- Add support for text decoration line styles via PlatformTextStyle
iOS
- Native-like caret behaviour by long/single taps in textfields(1, 2)
- Basic accessibility support
Popup
s/Dialog
s can now be displayed outside aViewController
over native components- Allow selecting
Text
inSelectionContainer
by double and triple tap
Web
- Compose for Web (Wasm) artifacts are available in Maven Central Warning: Kotlin 1.9.21 has an issue with web target. Use Kotlin 1.9.22.
Desktop
- Proper clipping of
SwingPanel
interop (under an experimental flag, see the link) Popup
s/Dialog
s can now be displayed outside the main window or panel and over native components (under an experimental flag, see the link)
Breaking changes
Common
- Resource library (
compose.components.resources
) changes- resources from
*Main\resources
should be moved to*Main\composeResources\drawable
,commonMain\composeResources\font
or*Main\composeResources\files
depending on the resource type painterResource("resource.xml")
should be replaced bypainterResource(Res.drawable.resource)
- resources from
google()
maven repository is now required. Add this tobuild.gradle.kts
:
If the project doesn't have it, there will be an errorrepositories { ... google() }
Could not find androidx.annotation:annotation:...
orCould not find org.jetbrains.compose.collection-internal:collection
.- Text with
lineHeight
set is trimmed by default - Text with
fontSize
set withoutlineHeight
insideMaterialTheme
has different line height
iOS/Desktop/Web
- Deprecate
public ComposeScene
in favour of@InternalComposeUiApi MultiLayerComposeScene
- Hide deprecated DropdownMenu overloads
iOS
- Separate platform views for
Popup
s/Dialog
s that are enabled by default, unable to draw anything out of their own bounds (for example, a shadow of the topmost container). It will be fixed in a future version, but if you're relying on this behavior, you can switch back to the old behavior by setting theplatformLayers
parameter tofalse
:ComposeUIViewController(configure = { platformLayers = false }) { // ... }
Desktop
Web (k/js)
- Libraries which depend on earlier Compose Multiplatform version are not compatible with 1.6.0 anymore. This is because decoys generation was disabled. Projects which apply Compose Compiler plugin manually need to remove this argument:
plugin:androidx.compose.compiler.plugins.kotlin:generateDecoys=true
.
Features
Common
iOS
- Adjust overscroll effect params to match iOS animations
- Add ability to change opacity for compose view
- Introduce
@Composable fun UIKitViewController
- Remove iOS experimental flag in gradle.properties
Desktop
- Support select till the end of the file / till the start of the file keyboard actions on Windows
- Add LinuxArm64 target to Compose runtime
- Add dedicated feature flags class for desktop
Web
HTML library
Gradle Plugin
Fixes
iOS/Desktop/Web
- Fix "DropdownMenu performs onDismissRequest twice"
- Use a large rectangle for the picture bounds in RenderNodeLayer.drawLayer to prevent clipping
- Fix closing scene during scroll animation
- Fix "Using
painterResource(:DrawableResource)
outside desktop Window can produceUnsatisfiedLinkError
" - Fix "Rect::makeLTRB expected l <= r" crashes
- Fix "
TextLayoutResult#getLineForVerticalPosition
returns wrong value + slow performance" - Run all effects before sending synthetic events
Font
constructor with lazy data loading- Optimise
TextLayoutResult#getLineForOffset
- Fix "SwingPanel/UIKitView doesn't apply Modifier.offset if it's after Modifier.size"
- DatePicker. Fix empty row
- DatePicker. Fix selection of the current day
- Fix
LayoutCoordinates.localToWindow
coordinates conversion for non-full Compose components
iOS
- Fixed unexpected fling animation over scrolling content
- Fix UIKitView z-order
- Fix missing case for loading
SystemFont
on iOS - Fix selection container crash
- Fix
WindowInfo.containerSize
withoutplatformLayers
flag - Disable encoding on separate thread for iOS
- Synchronise IME insets with iOS keyboard
Desktop
- Protect against
MouseInfo.getPointerInfo()
returning null inWindowDraggableArea
- Support Rtl in
SplitPane
- Fix a native crash on
makeGL
- Add Arial and Consolas as backup fonts on Linux and mention font name when one fails to load
- Fix blurry app icon in the system application switcher
- Insert a new line on
NumPadEnter
- Don't restart the drag gesture when the
onDrag(matcher=
changes - Fix "Resizing window on desktop sometimes triggers onClick handlers of Composables"
- Fix "
ComposePanel
doesn't calculate its preferredSize correctly when it's called before doLayout" - Fix input methods on JBR, disable input methods when we lose focus
- Fix "BasicTextField could not input any Chinese character when using JBR"
- Take into account
enabled
inscrollable
for mouse input - Fix NPE for getComponentAfter/Before in ComposePanel
- Transparency support for D3D (previously it supported via fallback on OpenGL)
Web
- Add a
SystemThemeObserver
implementation for wasmJs - Fix keyboard events with meta key on wasm/js targets
- Added WASM to
components.uiToolingPreview
library - Fix "The cursor is invisible in compose web"
- Use an alternative implementation of
Image.toBitmap
Gradle Plugin
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
See the announce of Jetpack Compose 1.6. Notes:
Changes to default font padding
affects only Android target.Added support for selection by mouse, including text.
concerns only Android. Other targets supported it before 1.6.- Some of the features are not ported yet (they will be ported in the next versions):
- BasicTextField2
- Support for nonlinear font scaling
- Multipaltform Drag and drop. It works only for Android right now. For desktop there is the old API
Modifier.onExternalDrag
- MultiParagraph.fillBoundingBoxes
See the announce of Material 1.2.
1.6.0-rc03 (February 2024)
Changes since 1.6.0-rc02
- Support Kotlin 2.0.0-Beta4 Common
- (prerelease fix) Resources. Don't return a cached value when pass new args Common
- (prerelease fix) Fix crash "ComposeUIViewController.view should be attached to window iOS
- (prerelease fix) Fix App crashes when Compose SwfitUI View container removed from hierarchy iOS
- (prerelease fix) Fix Keyboard disappears on IME action iOS
- (prerelease fix) Fix
SelectionContainer
occasionally crashes on iOS iOS - (prerelease fix) Fix crash after open/close dropdown on iOS iOS
- (prerelease fix) Fix Password popup disappears only on the second focused TextField iOS
- (prerelease fix) Fix mouse input above SwingPanel Desktop
- (prerelease fix) Fix non working accessibility on Desktop Desktop
- (prerelease fix) Resources. Fix import of Android flavors Android
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.6.0-rc02 (February 2024)
Changes since 1.6.0-rc01
Breaking changes
since 1.6.0-beta01
- When the resource library is used, resources should be imported explicitly
To quickly change your code to a new state, replace this:
import <modulePackage>.generated.resources.Res
by this:
import <modulePackage>.generated.resources.*
and perform "Code - Optimize Imports" to apply the project code style. If code style doesn't allow wildcrads,
import <modulePackage>.generated.resources.*
will be replaced by explicit imports.
iOS/desktop/web
Fixes
- (prerelease fix) Fix "AlertDialog doesn't work with ProvidableCompositionLocal"
Resource library
Fixes
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.6.0-rc01 (February 2024)
Changes since 1.6.0-beta02
Known issues and solutions
Could not find "org.jetbrains.compose.annotation-internal:annotation"
(or org.jetbrains.compose.collection-internal:collection), link
It happens because some library depends on 1.6.0-beta02
which isn't binary compatible with 1.6.0-rc01
.
To find this library, call ./gradlew shared:dependencies
(replace shared
by your main module). Downgrade this library or ask the library author to upgrade it to 1.6.0-rc01
.
Could not find androidx.annotation:annotation:...
(or org.jetbrains.compose.collection-internal:collection)
It happens because 1.6.0
depends on collection and annnotation libraries that are available only in the Google Maven repository.
To solve this, add google()
maven repository to build.gradle.kts
:
repositories {
...
google()
}
iOS/desktop/web
Fixes
- Fix "DropdownMenu performs onDismissRequest twice"
- Use a large rectangle for the picture bounds in RenderNodeLayer.drawLayer to prevent clipping
- Fix closing scene during scroll animation
- Fix "Using
painterResource(:DrawableResource)
outside desktop Window can produceUnsatisfiedLinkError
" - Fix "Rect::makeLTRB expected l <= r" crashes
- (prerelease fix) Commonize BasicTooltipBox
- (prerelease fix) Fix sharing composition locals with new platform layers
iOS
Fixes
- Fixed unexpected fling animation over scrolling content
- (prerelease fix) Fix "Wrong scroll behaviour of LazyColumn inside HorizontalPager"
- (prerelease fix) Fix scene size after sending the app to background or changing orientation with open modal
Desktop
Fixes
- Protect against
MouseInfo.getPointerInfo()
returning null inWindowDraggableArea
- Support Rtl in
SplitPane
- Fix a native crash on
makeGL
- (prerelease fix) Fix "Skiko RenderException" when creating
ComposePanel
Web
Fixes
- Add a
SystemThemeObserver
implementation for wasmJs - Fix keyboard events with meta key on wasm/js targets
- Added WASM to
components.uiToolingPreview
library - Fix "The cursor is invisible in compose web"
Gradle Plugin
Fixes
- (prerelease fix) Relocate a bundled
KotlinPoet
to the internal package
Resource library
Fixes
- (prerelease fix) Add a type name to the resource initializers
- (prerelease fix) Don't make resource IDs lowercased
- (prerelease fix) Clean code-gen directory if there was deleted a dependency on the res library
- (prerelease fix) Register all hierarchical compose resources in android compilation
- (prerelease fix) Fix fonts duplication in android app
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.6.0-beta02 (February 2024)
Changes since 1.6.0-beta01
Highlights
- Basic accessibility support iOS
- Popups/Dialogs can now be displayed outside a ViewController over native components on iOS by default iOS
- Allow selecting
Text
inSelectionContainer
by double and triple tap iOS - Add support for text decoration line styles via PlatformTextStyle iOS, desktop, web
- Bugfixes in the resource library (see below for the details)
iOS/desktop/web
Fixes
- Fix "
TextLayoutResult#getLineForVerticalPosition
returns wrong value + slow performance" - Run all effects before sending synthetic events
- (prerelease bug) Fix the pointer icon in
SelectionContainer
iOS
Features
- Adjust overscroll effect params to match iOS animations
- Add ability to change opacity for compose view
Fixes
- Fix UIKitView z-order
- Fix missing case for loading
SystemFont
on iOS - Fix selection container crash
- Fix
WindowInfo.containerSize
withoutplatformLayers
flag - (prerelease fix) Fix "textfield with visual transformation crashes after single tap"
- (prerelease fix) Fix selection handles crossed
- (prerelease fix) Fix CMPViewControllerMisuse error
- (prerelease fix) Fix selection handles with platformLayers=true
- (prerelease fix) Fix interaction handling for interop views
Desktop
Fixes
Breaking changes and deprecated API
HTML library
Features
Gradle Plugin
Features
Resource library
Fixes
- (prerelease fix) Configure Android resources after AGP is applied and ignore hidden files in resources
- (prerelease fix) Generate Res class if there is no common composeResource dir
- (prerelease fix) Support Res class generation in JVM only compose projects
- (prerelease fix) Support Compose resources for iOS tests
- (prerelease fix) Fix sub-module gradle properties for res class generation
- (prerelease fix) Fix Native xml parser
- (prerelease fix) Generate initializer functions in the Res file to avoid the
MethodTooLargeException
- (prerelease fix) Improve handling of special characters in string resources
- (prerelease fix) Add a
ttf
font to the resources demo app
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.5.12
Common
Features
Desktop
Fixes
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.6.0-beta01 (January 2024)
Highlights
- Resource library improvements (an example project)
- Experimental support is available for tests in common code
- Compose for Web (Wasm) artifacts are available in Maven Central. Warning: Kotlin 1.9.21 has an issue with web target. Use Kotlin 1.9.22.
- iOS. Native-like caret behaviour by long/single taps in textfields(1, 2)
- Support
LineHeightStyle.Trim
- Desktop. Proper clipping of
SwingPanel
interop (under an experimental flag, see the link) - Popups/Dialogs can now be displayed outside the main window or panel over native components on iOS and desktop (under experimental flags, see the links)
- Add a way to use fonts installed on the system (desktop/web in this version, iOS in the next version, Android isn't supported)
Breaking changes
- Text with
lineHeight
set is trimmed by default - Text with
fontSize
set withoutlineHeight
insideMaterialTheme
has different line height - Resource library (
compose.components.resources
) changes- resources from
*Main\resources
should be moved to*Main\composeResources\drawable
,commonMain\composeResources\font
or*Main\composeResources\files
depending on the resource type painterResource("resource.xml")
should be replaced bypainterResource(Res.drawable.resource)
- resources from
Known issues
compose.components.resources
library doesn't work yet if you applykotlin("jvm")
Gradle plugin. For now, it only works withkotlin("multiplatform")
Common
Features
iOS/desktop/web
Features
Fixes
- Optimise
TextLayoutResult#getLineForOffset
- Fix "SwingPanel/UIKitView doesn't apply Modifier.offset if it's after Modifier.size"
- DatePicker. Fix empty row
- DatePicker. Fix selection of the current day
- Fix
LayoutCoordinates.localToWindow
coordinates conversion for non-full Compose components
Breaking changes and deprecated API
- Deprecate
public ComposeScene
in favour of@InternalComposeUiApi MultiLayerComposeScene
- Hide deprecated DropdownMenu overloads
iOS
Features
Fixes
Desktop
Features
- Support select till the end of the file / till the start of the file keyboard actions on Windows
- Add LinuxArm64 target to Compose runtime
- Add dedicated feature flags class for desktop
Fixes
- Fix blurry app icon in the system application switcher
- Insert a new line on
NumPadEnter
- Don't restart the drag gesture when the
onDrag(matcher=
changes - Fix "BasicTextField NPE-crash on JBR 17.0.9 on Linux when clicked"
- Fix "Resizing window on desktop sometimes triggers onClick handlers of Composables"
- Fix "
ComposePanel
doesn't calculate its preferredSize correctly when it's called before doLayout" - Fix input methods on JBR, disable input methods when we lose focus
- Fix "BasicTextField could not input any Chinese character when using JBR"
- Take into account
enabled
inscrollable
for mouse input - Fix NPE for getComponentAfter/Before in ComposePanel
- Transparency support for D3D (previously it supported via fallback on OpenGL)
Web
Features
Fixes
HTML library
Features
Gradle Plugin
Features
Fixes
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
- Compiler 1.5.8
- Runtime 1.6.0-rc01
- UI 1.6.0-rc01
- Foundation 1.6.0-rc01
- Material 1.6.0-rc01
- Material3 1.1.2
1.5.11 (November 2023)
Common
Features
iOS
Fixes
- Fix crash at GrGpuResource::release()
- Fix crash with custom font
- Composable functions returning null cause crash (fixed in Kotlin 1.9.21 and JetBrains Compose Compiler 1.5.4)
Desktop
Fixes
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.5.10 (October 2023)
This is a combined changelog from the prerelease versions:
Common
Features
- Support Kotlin 1.9.20
- Introduce Material 3 components in common
- Introduce Material component
ExposedDropDownMenu
in common - Introduce
WindowInfo.containerSize
experimental api - Implement
defaultTimePickerLayoutType
based on screen orientation - Add an option to disable insets in
Popup
/Dialog
- Commonize insets
Modifier
's (additionally toWindowInsets.*
)
Fixes
ExposedDropdownMenuBox.onExpandedChange
was not recomposed- Override
RootLayout
insets only in case ofusePlatformInsets
- Don't send synthetic Move events before Press/Release for touch
iOS
Breaking changes
Features
- Compilation speed up due to enabling compiler caches for Kotlin 1.9.20+
- Added crossfade animation during orientation change when used within UIKit hierarchy
- Compose Multiplatform should warn when
CADisableMinimumFrameDurationOnPhone
is not configured properly - Fast delete mode on software keyboard. When you hold a backspace, “turbo mode” is enabled after deleting the first 21 symbols. In turbo mode each tick deletes two words.
- On a long scrollable TextFields, If it’s scrolled up to caret position while typing. Then it stopped on the line above the line with a caret.
- Add
UIViewController
lifetime hooks - Implement iOS native feel scrolls for large text fields
- Improve rendering performance
- Double tap and triple tap gesture handling in
TextField
s
Fixes
- Rendering synchronization of multiple
UIKitView
s within a screen - Today's date is not highlighted with a circle in the material3 datePicker on iOS
- Fix text-to-speech crash in iOS 16.0.*
- Compose window is shown before the first frame is rendered
- iOS TextField, Compound emojis are being treated as many symbols
- Use
CADisplayLink.targetTimestamp
value as the time for animation frames - iOS. Improved performance on 120 hz devices
- Expanded
ModalBottomSheet
: scrim doesn't occupy complete screen - Fix interop view intercepting touches for popups
- Fix applying
WindowInsets
insidePopup
/Dialog
- Scrolling behavior bugs
OutlinedTextField
label is clipped- Black screens with
UIKitView
after navigating away and navigating back - Long text field overscroll effect not clipped correctly
- First screen is recomposed twice
- Bug with selection handle
- Ignore unpressed events during velocity calculation
- Crash with Asian languages in
TextField
Desktop
Features
- Improve accessibility support
Fixes
LocalLayoutDirection
isn't propagated intoDialogWindow
- CompositionLocals given in application scope are not take into account in window scope (such as
LocalLayoutDirection
) - Fix accessibility issue with actions in popups
- Apply custom Dialog's scrim blend mode only when window is transparent
- Can't type in
TextField
placed inModalBottomSheet
- Accessibility not reporting changes
- Crash "LayoutNode should be attached to an owner exception"
- Window loses its focus after recomposition of another window
- Report semantic
ProgressBarRangeInfo
changes for accessibility - Fix NPE for getComponentAfter/Before in ComposePanel
- Take into account
enabled
inscrollable
for mouse input - Improve accessibility on Windows
- Fix Chinese characters input when using JBR
Gradle Plugin
Features
Fixes
- Increase Kotlinx Serialization version used by the Compose Gradle Plugin
- Switch to notarytool for notarization
- Fix configuration cache for
syncComposeResourcesForIos
HTML library
Features
Web
Features
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.5.10-rc02 (October 2023)
Common
Features
Desktop
Fixes
- Fix NPE for getComponentAfter/Before in ComposePanel
- Take into account
enabled
inscrollable
for mouse input - Improve accessibility on Windows
- Fix Chinese characters input when using JBR
Web
Features
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.5.10-rc01 (October 2023)
Common
Features
Fixes
- Override
RootLayout
insets only in case ofusePlatformInsets
- Don't send synthetic Move events before Press/Release for touch
iOS
Fixes
- Scrolling behavior bugs
OutlinedTextField
label is clipped- Black screens with
UIKitView
after navigating away and navigating back - Long text field overscroll effect not clipped correctly
- First screen is recomposed twice
- Bug with selection handle
- Ignore unpressed events during velocity calculation
- Crash with Asian languages in
TextField
Desktop
Fixes
- Accessibility not reporting changes
- Crash "LayoutNode should be attached to an owner exception"
- Window loses its focus after recomposition of another window
- Report semantic
ProgressBarRangeInfo
changes for accessibility
Gradle Plugin
Fixes
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.5.3 (October 2023)
Desktop
Fixes
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.5.10-beta02 (September 2023)
Common
Features
- Support kotlin 1.9.20-Beta2 with basic K2 support
- Implement
defaultTimePickerLayoutType
based on screen orientation - Add an option to disable insets in
Popup
/Dialog
- Commonize insets
Modifier
's (additionally toWindowInsets.*
)
Fixes
iOS
Features
- Improve rendering performance
- Double tap and triple tap gesture handling in
TextField
s
Fixes
- Expanded
ModalBottomSheet
: scrim doesn't occupy complete screen - Fix interop view intercepting touches for popups
- Fix applying
WindowInsets
insidePopup
/Dialog
Desktop
Features
- Improve accessibility support
Fixes
Gradle Plugin
Features
Fixes
HTML library
Features
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.5.2 (September 2023)
Desktop
Fixes
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.5.10-beta01 (September 2023)
Common
Features
- Support Kotlin 1.9.20-Beta
- Introduce Material 3 components in common
- Introduce Material component
ExposedDropDownMenu
in common - Introduce
WindowInfo.containerSize
experimental api
iOS
Breaking changes
Features
- Compilation speed up due to enabling compiler caches for Kotlin 1.9.20+
- Added crossfade animation during orientation change when used within UIKit hierarchy
- Compose Multiplatform should warn when
CADisableMinimumFrameDurationOnPhone
is not configured properly - Fast delete mode on software keyboard. When you hold a backspace, “turbo mode” is enabled after deleting the first 21 symbols. In turbo mode each tick deletes two words.
- On a long scrollable TextFields, If it’s scrolled up to caret position while typing. Then it stopped on the line above the line with a caret.
- Add
UIViewController
lifetime hooks - Implement iOS native feel scrolls for large text fields
Fixes
- Rendering synchronization of multiple
UIKitView
s within a screen - Today's date is not highlighted with a circle in the material3 datePicker on iOS
- Fix text-to-speech crash in iOS 16.0.*
- Compose window is shown before the first frame is rendered
- iOS TextField, Compound emojis are being treated as many symbols
- Use
CADisplayLink.targetTimestamp
value as the time for animation frames - iOS. Improved performance on 120 hz devices
Desktop
Fixes
LocalLayoutDirection
isn't propagated intoDialogWindow
- CompositionLocals given in application scope are not take into account in window scope (such as
LocalLayoutDirection
) - Fix accessibility issue with actions in popups
- Apply custom Dialog's scrim blend mode only when window is transparent
Gradle Plugin
Fixes
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.5.1 (September 2023)
Common
Features
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.5.0 (August 2023)
This is a combined changelog from the prerelease versions:
Common
Features
Dialog
API is available to use from common source setPopup
API is available to use from common source setWindowInsets
API is available to use from common source set- A warning if
compose.kotlinCompilerPlugin
is set toandroidx.compose.compiler.compiler
androidx.compose.material.DropdownMenu
is available to use from common source setandroidx.compose.material3.DropdownMenu
is available to use from common source setandroidx.compose.material.AlertDialog
is available to use from common source setandroidx.compose.material3.AlertDialog
is available to use from common source set- Add
PopupProperties.clippingEnabled
setting - material3. Support
DatePicker
,DatePickerDialog
andTimePicker
Fixes
Popup
. Fix overridingpressOwner
on multitouch- Fix sending multiple touches in tests
- Fix multi-owner input processing
- Fix paragraph word boundary unicode handling
- Optimize the
Canvas
transformation functions - Fix click outside of common
Dialog
behaviour
API Changes
iOS
Features
- iOS native scroll and feel
- Simplify resource management (works without CocoaPods now)
TextField
keyboardOptions, capitalizationTextField
, keyboard behavior when have fullscreen size TextFieldTextField
, different behavior strategies on appearing the keyboard- Insets on iOS
- Support
Density.textSize
(Dynamic Type) - Change default fonts (San Francisco is the default font)
- UIKit public
LocalUIViewController
- Support singleLine and
KeyboardAction
Fixes
- Fix dynamic framework support
- Fix
TextField
context menu - Fix complex blending on iOS
ViewConfiguration.touchSlop
value is quite low on iOS- Fix
topLeftOffset
calculation on iOS in Split View Modifier.draggable
onDragStopped
not calledUIKitView
. Fix lifetime discrepancy within the composition- Support 120hz screens
- Fix incorrect Skiko render target on iOS Metal
- Properly detect content based text direction on native
- Implemented all low-level functions to avoid random crashes
- Fix memory leak in
ComposeUIViewController
- Manage Kotlin native cache kind automatically based on Kotlin version (
kotlin.native.cacheKind=none
is no longer needed) - Limit max
Dialog
andPopup
size by safe area on iOS TextField
, Korean characters are not normally enteredColorMatrix
value range for 5th column was incorrect on Skiko backed platformsisSystemDarkTheme
now automatically react to the system theme changes
API Changes
- Resource management was reimplemented. Follow the guide in the PR to support new feautures
CADisableMinimumFrameDurationOnPhone
added to the template'sInfo.plist
to support 120HzComposeUIViewController
. Dispose composition onviewDidDisappear
Desktop
Features
- Swing interop. Experimental off-screen rendering on graphics (hardware accelerated only on macOs at the moment)
- Swing interop.
ComposePanel
that can be disposed manually - Add semantic properties to
DialogWindow
,Popup
andDialog
- Use
Segoe UI
as sans serif font on Windows - Add ProGuard optimize flag
Fixes
- Fix loosing frames on macOs
- Scrolling
LazyColumn
via mouse wheel stops working Slider
can be moved using keyboard, but cannot be submitted- Make one pixel beyond the scrollbar thumb react correctly to clicks
VerticalScrollbar
doesn't work properly whenLazyColumn
existsStickyHeader
- All
Popup
overloads call dismiss onEsc
key by default - Fix Could not infer Java runtime version for Java home directory
- Usage of deprecated
forEachGesture
inScrollbar.desktop.kt
- Test framework fixes
- Implement idling resources for tests
- Implement
SemanticsNodeInteraction.captureToImage()
- Wait until compose is idle before returning from
DesktopTestOwner.getRoots()
- When the test main clock is advanced, call
ComposeScene.render
with the current test time - Add timestamps to batched test input events, and advance the test clock accordingly when sending them
- Tests support semanatic nodes inside
Window
andDialogWindow
API Changes
Web
Features
- Let
ComposeWindow
accept a custom canvas id (html canvas element id) - Support
Scrollbar
- Make
CanvasBasedWindow
apply default styles, set title
Fixes
- Workaround
ComposeWindow
multiple event listeners on resize - Fix
Modifier.pointerHoverIcon
for browser apps - Fux
RoundedCornerShape
with zero corners - Fix
ScrollConfig
in web target - Implemented low-level functions to avoid random crashes:
HTML library
Features
Gradle Plugin
Features
API Changes
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.5.0-beta02 (August 2023)
Common
Features
androidx.compose.material.DropdownMenu
is available to use from common source setandroidx.compose.material3.DropdownMenu
is available to use from common source setandroidx.compose.material.AlertDialog
is available to use from common source setandroidx.compose.material3.AlertDialog
is available to use from common source set- Add
PopupProperties.clippingEnabled
setting - material3. Support
DatePicker
,DatePickerDialog
andTimePicker
API Changes
iOS
Features
Fixes
- Fix memory leak in
ComposeUIViewController
- Manage Kotlin native cache kind automatically based on Kotlin version (
kotlin.native.cacheKind=none
is no longer needed) - Limit max
Dialog
andPopup
size by safe area on iOS TextField
, Korean characters are not normally enteredColorMatrix
value range for 5th column was incorrect on Skiko backed platformsisSystemDarkTheme
now automatically react to the system theme changes
API Changes
Web
Features
Gradle Plugin
Features
API Changes
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.5.0-beta01 (July 2023)
Common
Features
Dialog
API is available to use from common source setPopup
API is available to use from common source setWindowInsets
API is available to use from common source set- A warning if
compose.kotlinCompilerPlugin
is set toandroidx.compose.compiler.compiler
Fixes
Popup
. Fix overridingpressOwner
on multitouch- Fix sending multiple touches in tests
- Fix multi-owner input processing
- Fix paragraph word boundary unicode handling
- Optimize the
Canvas
transformation functions - Fix click outside of common
Dialog
behaviour
iOS
Features
- iOS native scroll and feel
- Simplify resource management (works without CocoaPods now)
TextField
keyboardOptions, capitalizationTextField
, keyboard behavior when have fullscreen size TextFieldTextField
, different behavior strategies on appearing the keyboard- Insets on iOS
- Support
Density.textSize
(Dynamic Type) - Change default fonts (San Francisco is the default font)
- UIKit public
LocalUIViewController
Fixes
- Fix dynamic framework support
- Fix
TextField
context menu - Fix complex blending on iOS
ViewConfiguration.touchSlop
value is quite low on iOS- Fix
topLeftOffset
calculation on iOS in Split View Modifier.draggable
onDragStopped
not calledUIKitView
. Fix lifetime discrepancy within the composition- Support 120hz screens
- Fix incorrect Skiko render target on iOS Metal
- Properly detect content based text direction on native
- Implemented all low-level functions to avoid random crashes
API Changes
- Resource management was reimplemented. Follow the guide in the PR to support new features
CADisableMinimumFrameDurationOnPhone
added to the template'sInfo.plist
to support 120Hz
Desktop
Features
- Swing interop. Experimental off-screen rendering on graphics (hardware accelerated only on macOs at the moment)
- Swing interop.
ComposePanel
that can be disposed manually - Add semantic properties to
DialogWindow
,Popup
andDialog
- Use
Segoe UI
as sans serif font on Windows - Add ProGuard optimize flag
Fixes
- Fix loosing frames on macOs
- Scrolling
LazyColumn
via mouse wheel stops working Slider
can be moved using keyboard, but cannot be submitted- Make one pixel beyond the scrollbar thumb react correctly to clicks
VerticalScrollbar
doesn't work properly whenLazyColumn
existsStickyHeader
- All
Popup
overloads call dismiss onEsc
key by default - Fix Could not infer Java runtime version for Java home directory
- Usage of deprecated
forEachGesture
inScrollbar.desktop.kt
- Test framework fixes
- Implement idling resources for tests
- Implement
SemanticsNodeInteraction.captureToImage()
- Wait until compose is idle before returning from
DesktopTestOwner.getRoots()
- When the test main clock is advanced, call
ComposeScene.render
with the current test time - Add timestamps to batched test input events, and advance the test clock accordingly when sending them
- Tests support semanatic nodes inside
Window
andDialogWindow
API Changes
Web
Features
Fixes
- Workaround
ComposeWindow
multiple event listeners on resize - Fix
Modifier.pointerHoverIcon
for browser apps - Fux
RoundedCornerShape
with zero corners - Fix
ScrollConfig
in web target - Implemented low-level functions to avoid random crashes:
HTML library
Features
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
- Compiler 1.5.0
- Runtime 1.5.0-beta03
- UI 1.5.0-beta03
- Foundation 1.5.0-beta03
- Material 1.5.0-beta03
- Material3 1.1.1
1.4.3 (July 2023)
Common
Features
- Support Kotlin 1.8.21, 1.8.22, 1.9.0
iOS
Fixes
- Using Indication as a parameter in extension function doesn't compile on iOS
- Compile error when using delegated property with @Composable getters in objects
- Using a public property extensions inside a class or object with a @Composable backing delegate fails to link for iOS targets
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.4.1 (June 2023)
Common
Fixes
- Fix perspective transform usage
- After each ComposeScene.render phase, send apply notifications and perform the corresponding changes
- Fix awaitDragStartOnSlop to detect slop-passing on both axes
Desktop
Fixes
- Fix
DesktopDropdownMenuPositionProvider
to align with the correct horizontal side of the window - Propagate LocalLayoutDirection into PopupLayout
- Fix missing scrolling events
- Make popups accessible on desktop
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.4.0 (April 2023)
Common
Features
- Support perspective projection and
cameraDistance
parameter ingraphicsLayer
- Support
brush
parameter inTextStyle
for complex coloring - Support
drawStyle
parameter inTextStyle
for drawing outlined text - Support
blendMode
parameter when drawing text on Canvas - Support compositing strategy on
graphicsLayer
- Add
minLines
parameter toBasicTextField
- Support
painterResource
function in common source set
Fixes
- Actually remember provider in
rememberComponentRectPositionProvider
- Fix merging multiple selection areas inside
SelectionContainer
- Fix crash on selecting text if layout result is invalid
- Fix error on call an
expect
/actual
function with default arguments and a Composable argument
iOS
Desktop
Features
- Support external drag and drop
- Animate scroll initiated by mouse wheel input
- Remove AWT dependency in
rememberCursorPositionProvider
- Major scrollbar overhaul
- Scrollbar now works correctly in lazy lists when items vary in size
- Scrollbar now works correctly with lazy list
contentPadding
- Scrollbar now works correctly in lazy list with spacing between items
- Scrollbar now works correctly if the size of the scrollbar doesn't match the size of the widget it scrolls
- Pressing the scrollbar track now works correctly
- Added scrollbar support for lazy grids and text fields
Fixes
- Fix using a custom shape for an
AlertDialog
- Fix
AlertDialog
width to match the maximum of its content - Change
ContextMenuArea
to emit a single element, rather than two elements - Use state hoisting instead of global mouse position to determine where context menus, dropdown menus and tooltips should be displayed
- Limit error dialog width in case of long error message
- Fix window flashing background with unspecified size
- Fix crash
SplitPane
with a modifier - Fix applying
ComposePanel
visibility
Web
Compose for Web
is renamed toCompose HTML Library
- The new experimental
Compose for Web
based on Kotlin/Wasm is available
Tools
Features
Fixes
API Changes
- Remove deprecated
SkiaRootForTest.processPointerInput
- Remove deprecated
PointerEvent.awtEvent
,KeyEvent.awtEvent
- Make accidentally exposed to public
ParagraphLayouter
classinternal
as designed androidx.compose.foundation.v2.ScrollbarAdapter
is introduced in order to allow scrollbars of a size different from the scrolled widget
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.3.1 (March 2023)
Common
- Added support for Kotlin 1.8.10
Fixes
Desktop
Fixes
- Korean text input
- Size UndecoratedWindowResizer to the size of the window
- Fix sizing a window with unspecified size to its content's size
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.3.0 (January 2023)
Common
Fixes
- Fix configuration cache issues
- Use global directory to download wix toolset
- IDEA plugin - Redo: set until-build to undefined value
Desktop
Features
Fixes
- Fix San Francisco font as a default (macOS)
- Make ScrollbarAdapter for LazyList take contentPadding into account
- Fix AlertDialog dismiss on click to Dialog content
- Fix shaky scrolling of LazyColumn when the items are of varying size
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.2.2 (December 2022)
Desktop
Features
Fixes
- Fix Performance degradation after some time if there are animations on the screen
- Fix SwingPanel throws NPE on focus request if nothing focusable
- Fix jvmTarget value specified using jvmToolchain is ignored and overwritten with "1.8"
- Fix Trying to delete a word via Ctrl+Backspace in an empty TextField causes an exception
Web
Fixes
- Fix Compose Web 1.2.1 regression: unexpected recompositions
- Fix Wrong instance remembered when several remember calls in one scope
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.2.1 (November 2022)
Common
Fixes
- Fix
kotlinCompilerPlugin
property - Fix runDistributable fails in v1.2.0-beta01
- Fix Packaging fails on JDK-19
Desktop
Fixes
- Fix
duplicate definition of resource file
when running packageRelease - Fix support of GPU's which don't support DirectX 12 (Windows)
Web
Fixes
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.2.0 (October 2022)
Common
Features
- Allow to use Compose on multiple Kotlin versions
import org.jetbrains.compose.compose
is no longer needed in build.gradle.kts- Allow to use a custom Compose Compiler
Desktop
Features
- Support Kotlin 1.7.20
- ProGuard integration for packaging
- New experimental event API (onClick, onDrag, WindowInfo.keyboardModifiers)
- Focus
- Ability to override text context menu globally
- Context menu implementation for integrating into Swing applications
- Animated image component
- Show a new window/dialog on the same display
- Change default Font on MacOs to San Francisco
- Support performKeyInput, performMouseInput, performTextInput in tests.
- Focus switches seamlessly between Swing and Compose components using SwingPanel or ComposePanel
- Documentation for how to package apps using Conveyor
Fixes
- Fix IDEA plugin compatibility
- Fixes for Right-to-Left languages support
- LayoutDirection is detected from the system settings
- Fix RTL selection in a multiline text
- Fix cursor visual position at BiDi transition
- Fix the cursor position after the '\n' character in RTL
- In placeAutoMirrored for RTL, calculate the placement position using the placeable width respecting the constraints
- Placing the root content properly for RTL layout
- TextField
- Fix DesktopMenu and DesktopAlertDialog to invoke dismiss callback once
- Fix a large icon in macOs menu
- Fix hover in LazyColumn
- Fix pointerHoverIcon: update icon when it's changed conditionally
- Fix focusable parameter for Window and Dialog
- Fix 2 SplitPanel minor bugs
- Fix
java.lang.IllegalStateException: cannot open system clipboard
crash - Fix
System.setProperty("skiko.renderApi", "SOFTWARE"
on macOS
API changes
- Deprecate experimental pointerMoveFilter in favor of onPointerEvent
- Deprecate experimental Modifier.mouseClickable in favor of Modifier.onClick
Web
Features
- Support Kotlin 1.7.10
- Add support for transition in CSS api
- Add missing
background-blend-mode
property - SVG: Publish custom attr functions
- Add list overload for
classes
- Add support of dl, dt and dd
Fixes
API changes
- Deprecate 3 overloads of StyleScope.borderWidth with wrong parameter names
- Remove deprecated compose.web.web-widgets from the source code
- Remove unnecessary parameter for
required
attribute
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.1.1 (Mar 2022)
Desktop
Fixes
API changes
If you use Dispatchers.Swing
or Dispatchers.Main
in your code, add this dependency into build.gradle.kts
:
dependencies {
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-swing:$coroutinesVersion")
}
Also, usage of Dispatchers.Swing
or Dispatchers.Main
inside internals of Compose is implementation details, and can be changed in the future. If you need to avoid race conditions with Compose UI, you can obtain appropriate coroutine scope via rememberCoroutineScope
:
import androidx.compose.runtime.DisposableEffect
import androidx.compose.runtime.remember
import androidx.compose.runtime.rememberCoroutineScope
import androidx.compose.ui.ExperimentalComposeUiApi
import androidx.compose.ui.window.application
@OptIn(ExperimentalComposeUiApi::class, androidx.compose.foundation.ExperimentalFoundationApi::class)
fun main() = application {
val scope = rememberCoroutineScope()
val someApplicationObject = remember(scope) { SomeApplicationObject(scope) }
DisposableEffect(Unit) {
SomeGlobalObject.init(scope)
onDispose { }
}
}
1.1.0 (Feb 2022)
Desktop
Features
- Implement experimental accessibility support for Windows
- Implement accessibility focus tracking by Tab
- All bugfixes/features between Jetpack Compose 1.1.0-beta02 and 1.1.0 (see the release notes for each module here)
Fixes
- Fixes for TextField (1, 2, 3, 4)
- Fix exception when we initialize a window with visible = false, undecorated = true
- Fix crash in ImageComposeScene
- Fixes for situations, when hover state doesn't disappear during scrolling
- Fixes for Slider/Scrollbar dragging (1, 2)
- Fixed a case where [event.modifiersEx] does not provide info about the pressed mouse button (AWT)
- Fix TextField crashes after selecting the text and then deactivating the text field
- Fix consuming events by mouse clickable
- Hide top-level dialog from the taskbar
API changes
- The first frame of the window draws offscreen now. If your application has too long start, measure your first frame, and move the heavy logic to background or to the next frames. You can measure the first frame with this snippet:
import androidx.compose.runtime.getValue
import androidx.compose.runtime.mutableStateOf
import androidx.compose.runtime.setValue
import androidx.compose.ui.window.singleWindowApplication
private var time by mutableStateOf(System.nanoTime())
private var frame by mutableStateOf(0)
fun main() = singleWindowApplication {
if (frame == 0) {
frame++
} else if (frame == 1) {
val duration = ((System.nanoTime() - time) / 1E6).toLong()
println("First frame millis: $duration")
}
}
PointerEvent.awtEvent
,KeyEvent.awtEvent
are deprecated, usePointerEvent.awtEventOrNull
,KeyEvent.awtEventOrNull
instead. The event can be null, if it isn't sent by AWT (for example, Compose can send synthetic Move events on relayout)
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
1.0.1 (Dec 2021)
This is basically 1.0.0 that works with Kotlin 1.6.10
1.0.0 (Dec 2021)
Desktop
Features
- Experimental support for material3
- All clickable components are focusable and react to Enter key
- All clickable/draggable components no longer react to right clicks by default
- Show the default error dialog when an error occurs
- ContextMenu, AlertDialog, DropdownMenu close on Esc key by default
- Application by default calls exitProcess after its Composable is disposed
API changes
- Introduced experimental onPointerEvent (will replace mouseScrollFilter/pointerMoveFilter in the future)
- Introduced PointerEventType.Scroll, which can be used in common code
- MouseEvent.mouseEvent and KeyEvent.nativeKeyEvent are replaced by MouseEvent.awtEvent and KeyEvent.awtEvent
- Experimental overload for loading resources painterResource(String, ResourceLoader)
Web
API changes
- compose.web.widgets is deprecated
- All CSSSelectors can't be instantiated via constructor now (they're private). Please use functions provided in SelectorsScope instead
- Some functions were made internal (either not related to compose-web or not intended for usage in apps): buildCSS , StylePropertyList.nativeEquals , variableValue , buildCSSStyleRule , buildKeyframes , jsObject , CSSKeyframesRule.appendRule
- CSSMediaRule: functions feature and combine were made extensions functions on GenericStyleSheetBuilder. This makes them consistent with the rest of functions which create CSSMediaQuery.MediaFeature instances
Dependencies
This version of Compose Multiplatform is based on the next Jetpack Compose libraries:
- Compiler 1.1.0-beta02
- Runtime 1.1.0-beta02
- UI 1.1.0-beta02
- Foundation 1.1.0-beta02
- Material 1.1.0-beta02
- Material3 1.0.0-alpha03
1.0.0-beta (Oct 2021)
Common
- no Android artifacts are published anymore. Google-published artifacts are referenced instead. This approach eliminates compatibility issues.
Desktop
Features
- Accessibility support on MacOS
- Smart rendering fallback logic (no crashes on bad hardware/drivers anymore)
- Performance improvement of software rendering (up to 100%)
- Transparent window support
clickable
andtoggleable
components have a hoverable indication
API changes
- DesktopMaterialTheme is deprecated, use MaterialTheme instead
- WindowSize is deprecated, use DpSize instead
- Modifier.pointerMoveFilter marked as Experimental, stable alternatives are Modifier.hoverable or Modifier.pointerInput
- Modifier.mouseScrollFilter marked as Experimental, this API will likely change in the future
API breaking changes
- Old Window API (AppWindow, AppManager) was removed
- Modifier.pointerIcon is replaced with Modifier.pointerHoverIcon
- Tray can be used only inside ApplicationScope now
- Tray(hint=) replaced with Tray(tooltip=)
Web
Features
- SVG support
API changes
- Controlled Inputs were added
- New API for testing - test-utils was added
1.0.0-alpha (Aug 2021)
Common
- Desktop, Web, and Android artifacts publish at the same time with the same version
Desktop
Features
- Context menu support in selectable text
- Cursor change behavior in text and pointer icon API
- Mouse Clickable modifier
- Tab navigation between text fields by default
- Resource packing to native distribution
- Support @Preview annotation in desktopMain sourceSet's (when the Compose MPP plugin is installed in IDEA)
- New features for Composable menu (icons, shortcuts, mnemonics, radiob buttons, checkboxes
- Adaptive window size
- Support Linux on ARM64
- Support hidpi on some Linux distros
- Support resizing of undecorated resizable windows (
Window(undecorated=true, resizable=true, ...)
)
API changes
- new Window API is no longer experimental
- old Window API is deprecated
- classes from
android.compose.desktop.*
moved toandroidx.compose.ui.awt.*
(ComposeWindow, ComposePanel, etc) svgResource
/vectorXmlResource
/imageResource
replaced by painterResource
API breaking changes
- Window level keyboard API for the old Window API removed
- Window(icon: BufferedImage) replaced by Window(icon: Painter)
- ContextMenu renamed to CursorDropdownMenu
Web
API changes
- classes behave cumulatively
- removed content builder for empty elements
- Introduce CSS arithmetic operations
- Improved the types of Inputs and input events
- CSS Animations
- All event types expose native properties
- Added a complete list of HTML color aliases
- Introduce support for CSS Grid API
- Deprecate Color.RGB, Color.HSL etc. functions in favor of top-level rgb, hsl an so on
- negate CSSNumeric value directly
API breaking changes
- boolean like attributes don't have any parameters anymore
- removed input type specific event listeners
- replaced maxWidth/minWidth media queries with prefixed names
- Remove CSSVariables context and introduce specialized methods for adding String- and Number-valued CSS variables
- inline style builder was moved into AttributeBuilder scope
M4 (Jun 2021)
- New experimental Composable Window API
- Tooltips
- Use Metal renderer for macOS by default
- Expose a swing mouse event in Modifier.pointerInput
- Improved keyboard support in TextField
- Avoid forcing discrete GPU on multi-GPU MacOS machines in Skiko and native distributions
- Make DropdownMenu focusable by default
- Scrollbar. get rid of itemCount and averageItemSize from rememberScrollbarAdapte
- Support scrollbars for LazyColumn with reverseLayout = true
- Fix memory leak
- Fix Scroll NaN rounding bug, desktop version
- Fix Dragging prevents pointer move events
- Fix Dragging window to another display makes Icon show up incorrectly
- Fix "Padding must be non-negative" after resizing window with Slider and Box
- Breaking change old Dialog/Menubar/Tray are moved to androidx.compose.ui.window.v1
M3 (Feb 2021)
- Improve TextField
- Support SVG
- Support vsync, sync composition with rendering frames
- Support DirectX on Windows by default
- Support software rendering fallback
- Implement signing and notarization for macOS
- Improve Swing interoperability support Swing component in Compose hierarchy
- Support using Compose in IntelliJ plugins
- Skiko native binaries are now signed on macOS (x64 and arm)
- Fix Ambients are not transferred across pop ups
- Fix Laggy UI on Linux
- Fix Using AndroidX Compose specific dependencies for Android target
M2 (Dec 2020)
- Swing interoperability support (Compose in Swing frame)
- Support XML vector images
- Support for Gradle 6.6 and 6.7
- Support macOS 10.13 and 10.14
- Support Apple Silicon (arm64) natively
- Support letter spacing in text
- Implemented desktop "ActualDialog" and "ActualPopup"
- Fix input method bar positioning
- Fix text alignment
- Fix dropdown/popup positioning
- Fix using with Compose in same app as Java FX
- Added screenshots of example apps
M1 (Nov 2020)
- Initial release