@julien-wiegandt/open-ui 0.3.4 → 0.3.9
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/dist/components/common/index.d.ts +1 -0
- package/dist/components/divider/index.d.ts +3 -2
- package/dist/components/dropdown/index.d.ts +39 -0
- package/dist/components/dropdown/style.d.ts +73 -0
- package/dist/components/flex/index.d.ts +5 -1
- package/dist/components/modal/index.d.ts +4 -0
- package/dist/components/popover/style.d.ts +4 -0
- package/dist/components/toast/style.d.ts +4 -0
- package/dist/components/tooltip/style.d.ts +4 -0
- package/dist/components/utils/use-auto-contrast-color.d.ts +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/llm-docs/index.d.ts +1 -0
- package/dist/open-ui.js +3276 -2636
- package/dist/open-ui.umd.cjs +379 -96
- package/dist/theme/create-theme.d.ts +2 -0
- package/dist/theme/types.d.ts +11 -0
- package/dist/theme/utils/colors.d.ts +4 -0
- package/package.json +1 -1
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ColorPalette, Radius, Theme } from './types';
|
|
2
2
|
export declare const getPalette: (color: string | ColorPalette) => ColorPalette;
|
|
3
3
|
export declare const createTheme: (props: {
|
|
4
|
+
mode?: "dark" | "light";
|
|
4
5
|
radius: Radius;
|
|
5
6
|
primary: string | ColorPalette;
|
|
6
7
|
secondary?: string | ColorPalette;
|
|
@@ -8,5 +9,6 @@ export declare const createTheme: (props: {
|
|
|
8
9
|
error?: string | ColorPalette;
|
|
9
10
|
titleFontFamily?: string;
|
|
10
11
|
textFontFamily?: string;
|
|
12
|
+
semantic?: Partial<Theme["semantic"]>;
|
|
11
13
|
components?: Theme["components"];
|
|
12
14
|
}) => Theme;
|
package/dist/theme/types.d.ts
CHANGED
|
@@ -16,9 +16,19 @@ export declare const isColorPalette: (color: string | ColorPalette) => color is
|
|
|
16
16
|
type Text = {
|
|
17
17
|
fontFamily: string;
|
|
18
18
|
};
|
|
19
|
+
export type SemanticPalette = {
|
|
20
|
+
foreground: string;
|
|
21
|
+
background: string;
|
|
22
|
+
surface: string;
|
|
23
|
+
muted: string;
|
|
24
|
+
border: string;
|
|
25
|
+
shadow: string;
|
|
26
|
+
};
|
|
19
27
|
export type Theme = {
|
|
28
|
+
mode?: "dark" | "light";
|
|
20
29
|
radius: Radius;
|
|
21
30
|
palette: Palette;
|
|
31
|
+
semantic: SemanticPalette;
|
|
22
32
|
title: Text;
|
|
23
33
|
text: Text;
|
|
24
34
|
components?: {
|
|
@@ -26,6 +36,7 @@ export type Theme = {
|
|
|
26
36
|
checkbox?: Record<string, any>;
|
|
27
37
|
chip?: Record<string, any>;
|
|
28
38
|
divider?: Record<string, any>;
|
|
39
|
+
dropdown?: Record<string, any>;
|
|
29
40
|
flex?: Record<string, any>;
|
|
30
41
|
image?: Record<string, any>;
|
|
31
42
|
input?: Record<string, any>;
|
|
@@ -21,3 +21,7 @@ export declare function parseColorToRgb(color: string): RGBA;
|
|
|
21
21
|
export declare function generateColorPalette(baseColor: string, baseShadeKey?: 50 | 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900 | 950): {
|
|
22
22
|
[shade: string]: string;
|
|
23
23
|
};
|
|
24
|
+
export declare const withOpacity: (color: string, opacity: number) => string;
|
|
25
|
+
export declare const getContrastColor: (bg: string, options?: {
|
|
26
|
+
opacity?: number;
|
|
27
|
+
}) => string;
|