@hautechai/webui.themeprovider
v2.1.8
Published
Context provider component for theme management, supplying theme values to all child components in the component tree.
Readme
ThemeProvider
Purpose
Context provider component for theme management, supplying theme values to all child components in the component tree.
Installation
# pnpm (recommended)
pnpm add @hautechai/webui.themeprovider
# npm
npm install @hautechai/webui.themeprovider
# yarn
yarn add @hautechai/webui.themeproviderParameters
| Parameter | Type | Description | | --------- | --------------- | --------------------------------------------------------- | | theme | ThemeType | Optional theme object to override default theme values | | children | React.ReactNode | Required child components that will receive theme context |
Usage Example
import { ThemeProvider, Theme } from '@hautechai/webui.themeprovider';
<ThemeProvider theme={customTheme || Theme}>
<App />
</ThemeProvider>;