ThemeAnimationState
A state holder that manages theme toggle animations.
This class provides internal state management for theme animations, including the current theme state, button position tracking, and recording coordination for smooth theme transitions. It is not recommended to use the class constructor directly. Use the rememberThemeAnimationState method instead.
Parameters
A ThemeProvider instance that provides the current theme and allows for theme updates. Typically, a data access object that saves the theme to a local or remote storage.
The coroutine scope used for launching asynchronous operations, such as record request coordination.
The animation specification for theme transitions.
The format/style of the theme animation. See ThemeAnimationFormat for available styles.
Whether to capture and animate dynamic content during theme transitions. If set to true, the target content (that is, the theme
to which the theme is toggled) will be drawn dynamically and any changes to it, including scrolling,
animations etc. will be preserved. Note that the abandoned theme will still be drawn statically, which may lead to inconsistency
between the target and abandoned parts of the animation. Defaults to
false.