@plumeria/core 6.3.2 → 7.0.0
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/css.d.mts +12 -7
- package/dist/css.mjs +3 -1
- package/package.json +1 -1
package/dist/css.d.mts
CHANGED
|
@@ -31,13 +31,13 @@ interface CommonProperties extends BaseCSSProperties {
|
|
|
31
31
|
caretColor?: CSSColorProperty;
|
|
32
32
|
columnRuleColor?: CSSColorProperty;
|
|
33
33
|
}
|
|
34
|
-
type
|
|
35
|
-
type
|
|
34
|
+
type ArrayString = `[${string}`;
|
|
35
|
+
type ArraySelector = { [key in ArrayString]: CommonProperties | CSSVariableProperty };
|
|
36
36
|
type ColonString = `:${string}`;
|
|
37
|
-
type ColonSelector = { [key in ColonString]: CommonProperties };
|
|
37
|
+
type ColonSelector = { [key in ColonString]: CommonProperties | CSSVariableProperty };
|
|
38
38
|
type Query = `@media ${string}` | `@container ${string}`;
|
|
39
|
-
type QuerySelector = { [K in Query]: CommonProperties | ColonSelector |
|
|
40
|
-
type CSSProperties = CommonProperties |
|
|
39
|
+
type QuerySelector = { [K in Query]: CommonProperties | ColonSelector | ArraySelector | CSSVariableProperty };
|
|
40
|
+
type CSSProperties = CommonProperties | ArraySelector | ColonSelector | QuerySelector | CSSVariableProperty;
|
|
41
41
|
type CreateStyleType<T> = { readonly [K in keyof T]: T[K] extends CSSProperties ? CSSProperties : T[K] };
|
|
42
42
|
type CreateStyle = {
|
|
43
43
|
[key: string]: CSSProperties;
|
|
@@ -45,7 +45,7 @@ type CreateStyle = {
|
|
|
45
45
|
type Selector<Properties> = {
|
|
46
46
|
readonly properties: Properties;
|
|
47
47
|
};
|
|
48
|
-
type ReturnType<T> = { [K in keyof T]: Readonly<{ [P in keyof T[K]]: P extends `@media ${string}` | `@container ${string}` | `:${string}` |
|
|
48
|
+
type ReturnType<T> = { [K in keyof T]: Readonly<{ [P in keyof T[K]]: P extends `@media ${string}` | `@container ${string}` | `:${string}` | `[${string}` ? Selector<keyof T[K][P]> : T[K][P] }> };
|
|
49
49
|
type CreateStatic = Record<string, string | number>;
|
|
50
50
|
type CreateTheme = Record<string, Record<string, string | number>>;
|
|
51
51
|
type ReturnVariableType<T> = { [K in keyof T]: CSSVariableValue };
|
|
@@ -58,6 +58,7 @@ type ViewTransition = {
|
|
|
58
58
|
old?: CSSProperties;
|
|
59
59
|
};
|
|
60
60
|
type Variant = Record<string, Record<string, CSSProperties>>;
|
|
61
|
+
type ContainerStyleQuery = `@container style(--${string}: 1)`;
|
|
61
62
|
|
|
62
63
|
type create = typeof create;
|
|
63
64
|
type props = typeof props;
|
|
@@ -66,6 +67,8 @@ type createStatic = typeof createStatic;
|
|
|
66
67
|
type keyframes = typeof keyframes;
|
|
67
68
|
type viewTransition = typeof viewTransition;
|
|
68
69
|
type variants = typeof variants;
|
|
70
|
+
type marker = typeof marker;
|
|
71
|
+
type extended = typeof extended;
|
|
69
72
|
declare const create: <const T extends Record<string, CSSProperties>>(_rule: CreateStyleType<T>) => ReturnType<T>;
|
|
70
73
|
declare const props: (..._rules: (false | CSSProperties | null | undefined)[]) => string;
|
|
71
74
|
declare const createTheme: <const T extends CreateTheme>(_rule: T) => ReturnVariableType<T>;
|
|
@@ -73,5 +76,7 @@ declare const createStatic: <const T extends CreateStatic>(_rule: T) => T;
|
|
|
73
76
|
declare const keyframes: (_rule: Keyframes) => string;
|
|
74
77
|
declare const viewTransition: (_rule: ViewTransition) => string;
|
|
75
78
|
declare const variants: <T extends Variant>(_rule: T) => (_props: { [K in keyof T]: keyof T[K] }) => CSSProperties;
|
|
79
|
+
declare const marker: (_id: string, _pseudo: string) => CSSProperties;
|
|
80
|
+
declare const extended: (_id: string, _pseudo: string) => ContainerStyleQuery;
|
|
76
81
|
|
|
77
|
-
export { type CSSProperties, type CreateStyle, create, createStatic, createTheme, keyframes, props, variants, viewTransition };
|
|
82
|
+
export { type CSSProperties, type CreateStyle, create, createStatic, createTheme, extended, keyframes, marker, props, variants, viewTransition };
|
package/dist/css.mjs
CHANGED
|
@@ -8,5 +8,7 @@ const createStatic = (_rule) => errorFn();
|
|
|
8
8
|
const keyframes = (_rule) => errorFn();
|
|
9
9
|
const viewTransition = (_rule) => errorFn();
|
|
10
10
|
const variants = (_rule) => (_props) => errorFn();
|
|
11
|
+
const marker = (_id, _pseudo) => errorFn();
|
|
12
|
+
const extended = (_id, _pseudo) => errorFn();
|
|
11
13
|
|
|
12
|
-
export { create, createStatic, createTheme, keyframes, props, variants, viewTransition };
|
|
14
|
+
export { create, createStatic, createTheme, extended, keyframes, marker, props, variants, viewTransition };
|