@boreal-ui/types 0.2.11 → 0.2.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +21 -0
- package/dist/types/public.types.d.ts +1 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -8,6 +8,27 @@ npm install -D @boreal-ui/types
|
|
|
8
8
|
|
|
9
9
|
The runtime packages `@boreal-ui/core` and `@boreal-ui/next` reference this package for their public TypeScript declarations.
|
|
10
10
|
|
|
11
|
+
Import shared types directly when defining a custom color scheme:
|
|
12
|
+
|
|
13
|
+
```ts
|
|
14
|
+
import type { ColorScheme } from "@boreal-ui/types";
|
|
15
|
+
import { registerColorScheme, setBorealStyleConfig } from "@boreal-ui/core";
|
|
16
|
+
|
|
17
|
+
const appScheme: ColorScheme = {
|
|
18
|
+
name: "App Theme",
|
|
19
|
+
primaryColor: "#2563eb",
|
|
20
|
+
secondaryColor: "#64748b",
|
|
21
|
+
tertiaryColor: "#0d9488",
|
|
22
|
+
quaternaryColor: "#f1f5f9",
|
|
23
|
+
backgroundColor: "#ffffff",
|
|
24
|
+
};
|
|
25
|
+
|
|
26
|
+
registerColorScheme([appScheme]);
|
|
27
|
+
setBorealStyleConfig({ defaultColorSchemeName: appScheme.name });
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
For Next.js, import the runtime functions from `@boreal-ui/next`.
|
|
31
|
+
|
|
11
32
|
Published peer and type-verification boundaries are documented in the
|
|
12
33
|
[compatibility matrix](https://github.com/DaveC6662/borealui/blob/main/docs/compatibility.md).
|
|
13
34
|
|