PHPackages                             octopyid/filament-palette - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. octopyid/filament-palette

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

octopyid/filament-palette
=========================

Easily switch and customize the UI color palette for your FilamentPHP

v1.0.3(6mo ago)13985↑31.3%1MITPHPPHP ^8.2

Since Jun 10Pushed 3mo agoCompare

[ Source](https://github.com/OctopyID/FilamentPalette)[ Packagist](https://packagist.org/packages/octopyid/filament-palette)[ RSS](/packages/octopyid-filament-palette/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (4)Dependencies (1)Versions (5)Used By (0)

 [![Filament Palette](art.png)](art.png)

 [![Version](https://camo.githubusercontent.com/835adda33561c8cc77bb552d272827f7fc994185aad40c4b4924a90addd4f017/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6f63746f707969642f66696c616d656e742d70616c657474652e7376673f7374796c653d666f722d7468652d6261646765)](https://camo.githubusercontent.com/835adda33561c8cc77bb552d272827f7fc994185aad40c4b4924a90addd4f017/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6f63746f707969642f66696c616d656e742d70616c657474652e7376673f7374796c653d666f722d7468652d6261646765) [![Downloads](https://camo.githubusercontent.com/b348e60bdcaea9dcaec71227355f4b00edc37507a61ca79febf68a9ab70fa71c/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6f63746f707969642f66696c616d656e742d70616c657474652e7376673f7374796c653d666f722d7468652d626164676526636f6c6f723d463238443141)](https://camo.githubusercontent.com/b348e60bdcaea9dcaec71227355f4b00edc37507a61ca79febf68a9ab70fa71c/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6f63746f707969642f66696c616d656e742d70616c657474652e7376673f7374796c653d666f722d7468652d626164676526636f6c6f723d463238443141) [![License](https://camo.githubusercontent.com/cdb709958a391702eb4726910b4145a7b66d644751077056095a67b7557f0439/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f6f63746f707969642f66696c616d656e742d70616c657474652e7376673f7374796c653d666f722d7468652d6261646765)](https://camo.githubusercontent.com/cdb709958a391702eb4726910b4145a7b66d644751077056095a67b7557f0439/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f6f63746f707969642f66696c616d656e742d70616c657474652e7376673f7374796c653d666f722d7468652d6261646765)

Filament Palette Switcher
=========================

[](#filament-palette-switcher)

A **FilamentPHP plugin** that allows users to easily switch and customize the UI color palette in their Filament admin panels. This plugin provides a seamless way to change themes, either per user or globally across the application.

---

✨ Features
----------

[](#-features)

- ✅ **User-specific themes** – Each user can choose their preferred color palette.
- 🌐 **Global theme support** – Apply a single theme for all users.
- 🧠 **Conditional visibility** – Show or hide the palette switcher based on custom logic.
- 🎨 **Custom color palettes** – Define your own color schemes or modify existing ones.
- 🌈 **Pre-built palettes** – Includes 9 beautiful ready-to-use palettes.
- ⚡ **Easy integration** – Simple installation with minimal configuration.
- 🔧 **Flexible customization** – Full control over theme application and visibility.

---

🚀 Installation
--------------

[](#-installation)

Install the package via Composer:

```
composer require octopyid/filament-palette
```

Filament v3 (Tailwind v3) — add plugin views to tailwind.config.js:

```
content: [
    './vendor/octopyid/filament-palette/resources/**/*.blade.php',
]
```

Filament v4 (Tailwind v4) — declare sources in your panel theme CSS (paths are relative to this CSS file):

```
@source '../../../../vendor/octopyid/filament-palette/resources';
```

Optionally, publish the configuration file:

```
php artisan vendor:publish --tag=filament-palette
```

---

⚙️ Usage
--------

[](#️-usage)

### Basic Setup

[](#basic-setup)

Add the plugin to your Filament panel configuration:

```
public function panel(Panel $panel): Panel
{
    return $panel->plugin(
        \Octopy\Filament\Palette\PaletteSwitcherPlugin::make()
    );
}
```

By default, the color palette is applied individually to each user, allowing them to freely choose their preferred colors.

### Global Theme Application;

[](#global-theme-application)

To apply themes globally across all users:

```
public function panel(Panel $panel): Panel
{
    return $panel->plugin(
        \Octopy\Filament\Palette\PaletteSwitcherPlugin::make()->applyThemeGlobally(true)
    );
}
```

### Conditional Visibility

[](#conditional-visibility)

Hide the palette switcher programmatically based on custom conditions:

```
public function panel(Panel $panel): Panel
{
    return $panel->plugin(
        \Octopy\Filament\Palette\PaletteSwitcherPlugin::make()->hidden(function () {
            return auth()->user()->email === 'foo@bar.baz';
        }),
    );
}
```

---

🎨 Customization
---------------

[](#-customization)

### Available Color Palettes

[](#available-color-palettes)

The plugin includes 9 pre-configured palettes:

- Slate – Professional gray-blue theme
- Stone – Warm neutral theme
- Red – Bold red theme
- Amber – Warm orange theme
- Emerald – Fresh green theme
- Teal – Cool blue-green theme
- Sky – Bright blue theme
- Violet – Rich purple theme
- Fuchsia – Vibrant pink theme

### Custom Color Palettes

[](#custom-color-palettes)

You can tailor your palettes by editing the configuration file located at `config/filament-palette.php`. This file gives you full control to define new color schemes or modify existing ones using various methods.

```
