Mantine
@theme-kit/mantine
Map Theme semantic tokens onto a Mantine theme, with color-scheme forced to match the active Theme Kit mode.
Installation
Install the adapter alongside @theme-kit/core (or a framework integration that provides the runtime).
pnpm add @theme-kit/mantinePick your framework
The adapter is framework-agnostic — it's a hook, composable, directive or custom element depending on your stack. Pick yours to see the native API.
Quick Start
The snippet below uses the framework you picked — switch the picker above to see that framework's native API.
1import { ThemeProvider, useThemeRuntime } from "@theme-kit/react";
2import { MantineThemeProvider } from "@theme-kit/mantine";
3
4function Zone() {
5 const runtime = useThemeRuntime();
6 return (
7 <MantineThemeProvider runtime={runtime}>
8 <YourApp />
9 </MantineThemeProvider>
10 );
11}
12
13export function App() {
14 return (
15 <ThemeProvider>
16 <Zone />
17 </ThemeProvider>
18 );
19}What's Available
@theme-kit/mantine ships 3 exports in 2 categories. Click any export to reveal what it does and how to use it.
Provider
Create
Use Cases
The important features in practice — copy any of these straight into your app.
Build a static Mantine theme
Generate a Mantine theme (with shades, fonts, radius) from tokens.
import { createMantineTheme } from "@theme-kit/mantine";
const theme = createMantineTheme({ family: "cocoa", mode: "dark" });More Examples
Static themes generated from concrete tokens, and runtime subscriptions.
import { createMantineTheme } from "@theme-kit/mantine";
const theme = createMantineTheme({ family: "cocoa", mode: "dark" });API Reference
Provider
| Export | Description |
|---|---|
MantineThemeProvider | Wraps Mantine's `MantineProvider`, forcing the color scheme to match the active Theme Kit mode. |
useMantineTheme(runtime) | Subscribes to a runtime and returns a Mantine `Theme` rebuilt on changes. |
Create
| Export | Description |
|---|---|
createMantineTheme(source) | Builds a Mantine theme — colors (with generated shades), fonts, radius, spacing, shadows, breakpoints. |