Themes
Xumina provides a powerful and flexible theming system that allows you to customize the look and feel of your application. Themes in Xumina are defined using PHP classes, making it easy to create, modify, and apply custom color schemes and styles.
Default Themes
Xumina comes with several pre-built themes out of the box. These themes provide a variety of color schemes to suit different tastes and design requirements.
Changing Theme
To apply a theme to your panel, use the theme
method inside your panel’s boot
method:
Replace DefaultTheme::class with the theme of your choice.
Theme customization
You can also customize the selected theme by passing a closure to the theme method. The method has one parameter which is the current theme
Each function takes three parameter: float hue
, float saturation
, float lightness
Custom theme
Xumina provides an Artisan command to quickly generate a new theme:
Theme Structure
A Xumina theme class extends the BaseTheme
class and implements the Theme
interface.
Color Definition
Colors in Xumina themes are defined using the HSL (Hue, Saturation, Lightness) color model. Each color is represented as a string with three space-separated values:
- The first value is the hue (0-360)
- The second value is the saturation (0-100%)
- The third value is the lightness (0-100%)