Package com.vaadin.copilot.theme
Class AppThemeUtils
java.lang.Object
com.vaadin.copilot.theme.AppThemeUtils
Utility class for checking the current application theme in use.
This class provides helper methods to determine whether the active
application theme is ApplicationTheme.LUMO or
ApplicationTheme.AURA.
The methods rely on the ApplicationDetectedThemeHolder singleton to
retrieve the currently detected ApplicationTheme.
Usage Example:
if (AppThemeUtils.isLumo()) {
// Apply Lumo-specific styling or logic
}
This class cannot be instantiated.
-
Method Summary
Modifier and TypeMethodDescriptionstatic booleanisAura()Checks if the currently active application theme isApplicationTheme.AURA.static booleanisLumo()Checks if the currently active application theme isApplicationTheme.LUMO.
-
Method Details
-
isLumo
public static boolean isLumo()Checks if the currently active application theme isApplicationTheme.LUMO.- Returns:
trueif the detected theme is Lumo,falseotherwise
-
isAura
public static boolean isAura()Checks if the currently active application theme isApplicationTheme.AURA.- Returns:
trueif the detected theme is Aura,falseotherwise
-