io.github.palexdev.mfxresources.themes.material.abstracts._ripple.scss Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of materialfx-all Show documentation
Show all versions of materialfx-all Show documentation
Material Design/Modern components for JavaFX, now packed as a single Jar
@use "../tokens/theme" as Theme;
/// Computes the color of the ripple layer given the base color and the interaction/layer state
@function RippleLayer($color, $layer_state) {
@return rgba(Theme.GetSchemeColor($color), Theme.GetStateLayer($layer_state));
}
/// Shortcut for the ripple_layer function with 'pressed' as the interaction state.
/// On the web, the ripple layer is an actual container that changes its color based on the user interaction with the
/// component. Here on the desktop the ripple is not a layer but just an effect, because of this, the ripple color
/// will always refer to the 'pressed' state.
@function Ripple($color) {
@return RippleLayer($color, 'pressed');
}