@nexim/tailwind-material-colors
Version:
A Tailwind CSS plugin to automatically generate and apply Material Design 3 color palettes.
34 lines (20 loc) • 1.22 kB
Markdown
[@nexim/tailwind-material-colors](../README.md) / materialThemeBuilder
# Function: materialThemeBuilder()
> **materialThemeBuilder**(`options`: [`MaterialThemePluginOptions`](../interfaces/MaterialThemePluginOptions.md)): [`MaterialThemePalettes`](../interfaces/MaterialThemePalettes.md)
Generates light and dark material design 3 color palettes based on the provided colors and scheme.
## Parameters
| Parameter | Type | Description |
| --------- | --------------------------------------------------------------------------- | ---------------------------------------------- |
| `options` | [`MaterialThemePluginOptions`](../interfaces/MaterialThemePluginOptions.md) | The options for generating the color palettes. |
## Returns
[`MaterialThemePalettes`](../interfaces/MaterialThemePalettes.md)
An object containing light and dark color palettes.
## Example
```ts
import { materialThemeBuilder } from '@nexim/material-design-color-tailwind-plugin';
const options = {
primaryColor: '#6200EE',
};
const { lightColors, darkColors } = materialThemeBuilder(options);
console.log(lightColors.primary);
```