Class ShadowBuilder
Provides utility methods for generating CSS shadow classes based on elevation levels.
public class ShadowBuilder
- Inheritance
-
ShadowBuilder
- Inherited Members
Constructors
ShadowBuilder(TwBlazorOptions)
Provides utility methods for generating CSS shadow classes based on elevation levels.
public ShadowBuilder(TwBlazorOptions options)
Parameters
optionsTwBlazorOptions
Methods
GetButtonShadow(TwButtonTheme?, Shadow?, bool, bool)
Gets the Tailwind CSS shadow classes for button states from theme configuration.
public string GetButtonShadow(TwButtonTheme? buttonTheme, Shadow? overrideShadow = null, bool includeHover = true, bool includeActive = true)
Parameters
buttonThemeTwButtonThemeThe button theme configuration containing shadow settings.
overrideShadowShadow?When set, overrides the theme's default button shadow (e.g. an explicit Shadow parameter passed to the component instance). Leave null to fall back to
buttonTheme's configured shadow.includeHoverboolWhether to include hover state shadow.
includeActiveboolWhether to include active state shadow.
Returns
- string
The corresponding Tailwind CSS classes.
GetShadow(Shadow?)
Gets the Tailwind CSS shadow class for the specified shadow level.
public string GetShadow(Shadow? shadow)
Parameters
shadowShadow?The shadow level.
Returns
- string
The corresponding Tailwind CSS class.