LiquidGlassStyle class
Lengths are dp. The shader shrinks bevel and refraction to fit a pane too small for them, so that a button bends in proportion to the dock.
- Annotations
Constructors
- LiquidGlassStyle({required Color tint, double contrast = 0, double blur = 2.5, double haze = 0, double hazeBlur = 0, double refraction = 60, double bevel = 20, double saturation = 1.5, double brightness = 1, double rim = 0.6, double rimWidth = 1.3, double rimTail = 0, double rimFocus = 0, double rimAdded = 0, double endShade = 0, double dispersion = 0, double rimBlur = 0, double hairline = 0, double? hairlineSide})
-
const
- LiquidGlassStyle.alert(ColorScheme colorScheme)
-
factory
-
iOS 27's notification banner (.agents/architecture.md).
factory
- LiquidGlassStyle.editMenu(ColorScheme colorScheme)
-
iOS 27's edit menu, far clearer than a menu card.
factory
- LiquidGlassStyle.lens(ColorScheme colorScheme)
-
factory
- LiquidGlassStyle.lensContent(ColorScheme colorScheme)
-
factory
-
Thicker than LiquidGlassStyle.regular, for rows that read over anything.
It takes its rim from a LiquidGlassRim.
factory
- LiquidGlassStyle.pill(ColorScheme colorScheme)
-
factory
- LiquidGlassStyle.regular(ColorScheme colorScheme)
-
factory
- LiquidGlassStyle.tinted(ColorScheme colorScheme, Color color)
-
factory
Properties
- bevel → double
-
final
- blur → double
-
final
- brightness → double
-
final
- contrast → double
-
How far the tint thickens toward opaque over content much darker, or if
negative much lighter, than it, so what sits on the glass stays legible.
final
- dispersion → double
-
final
- endShade → double
-
final
- hairline → double
-
final
- hairlineSide → double?
-
final
- hashCode → int
-
The hash code for this object.
no setteroverride
- haze → double
-
The share of the backdrop seen through hazeBlur rather than blur.
final
- hazeBlur → double
-
final
- refraction → double
-
Negative for a raised lens, which reads outward all around its rim.
final
- rim → double
-
final
- rimAdded → double
-
The share of rim added as light rather than screened toward white.
final
- rimBlur → double
-
final
- rimFocus → double
-
0 dims rim round the ends as on iOS's tab bar, 1 as on its controls.
final
- rimTail → double
-
final
- rimWidth → double
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- saturation → double
-
final
- tint → Color
-
final
Methods
-
copyWith(
{double? blur, double? hazeBlur}) → LiquidGlassStyle -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
scale(
double t) → LiquidGlassStyle - Eases in from bare air, as glass materializes by bending, not fading.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override
Static Methods
-
lerp(
LiquidGlassStyle a, LiquidGlassStyle b, double t) → LiquidGlassStyle