@luxonis/depthai-pipeline-lib 1.4.13 → 1.4.14
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/panda.css +670 -809
- package/dist/src/styled-system/css/conditions.mjs +4 -2
- package/dist/src/styled-system/css/css.d.mts +15 -2
- package/dist/src/styled-system/css/css.mjs +2 -1
- package/dist/src/styled-system/css/cva.d.mts +1 -1
- package/dist/src/styled-system/css/cva.mjs +28 -4
- package/dist/src/styled-system/css/sva.mjs +9 -3
- package/dist/src/styled-system/helpers.mjs +109 -64
- package/dist/src/styled-system/patterns/aspect-ratio.d.mts +1 -1
- package/dist/src/styled-system/patterns/aspect-ratio.mjs +5 -2
- package/dist/src/styled-system/patterns/bleed.d.mts +3 -3
- package/dist/src/styled-system/patterns/bleed.mjs +12 -7
- package/dist/src/styled-system/patterns/box.d.mts +1 -1
- package/dist/src/styled-system/patterns/box.mjs +5 -2
- package/dist/src/styled-system/patterns/center.d.mts +1 -1
- package/dist/src/styled-system/patterns/center.mjs +5 -2
- package/dist/src/styled-system/patterns/circle.d.mts +2 -2
- package/dist/src/styled-system/patterns/circle.mjs +5 -2
- package/dist/src/styled-system/patterns/container.d.mts +1 -1
- package/dist/src/styled-system/patterns/container.mjs +5 -2
- package/dist/src/styled-system/patterns/cq.d.mts +22 -0
- package/dist/src/styled-system/patterns/cq.mjs +21 -0
- package/dist/src/styled-system/patterns/divider.d.mts +1 -1
- package/dist/src/styled-system/patterns/divider.mjs +8 -4
- package/dist/src/styled-system/patterns/flex.d.mts +8 -8
- package/dist/src/styled-system/patterns/flex.mjs +5 -2
- package/dist/src/styled-system/patterns/float.d.mts +1 -1
- package/dist/src/styled-system/patterns/float.mjs +10 -3
- package/dist/src/styled-system/patterns/grid-item.d.mts +1 -1
- package/dist/src/styled-system/patterns/grid-item.mjs +5 -2
- package/dist/src/styled-system/patterns/grid.d.mts +4 -4
- package/dist/src/styled-system/patterns/grid.mjs +12 -5
- package/dist/src/styled-system/patterns/hstack.d.mts +3 -3
- package/dist/src/styled-system/patterns/hstack.mjs +8 -4
- package/dist/src/styled-system/patterns/index.d.mts +2 -2
- package/dist/src/styled-system/patterns/index.mjs +2 -2
- package/dist/src/styled-system/patterns/link-overlay.d.mts +1 -1
- package/dist/src/styled-system/patterns/link-overlay.mjs +5 -5
- package/dist/src/styled-system/patterns/spacer.d.mts +1 -1
- package/dist/src/styled-system/patterns/spacer.mjs +5 -2
- package/dist/src/styled-system/patterns/square.d.mts +2 -2
- package/dist/src/styled-system/patterns/square.mjs +5 -2
- package/dist/src/styled-system/patterns/stack.d.mts +5 -5
- package/dist/src/styled-system/patterns/stack.mjs +8 -4
- package/dist/src/styled-system/patterns/visually-hidden.d.mts +1 -1
- package/dist/src/styled-system/patterns/visually-hidden.mjs +5 -2
- package/dist/src/styled-system/patterns/vstack.d.mts +3 -3
- package/dist/src/styled-system/patterns/vstack.mjs +8 -4
- package/dist/src/styled-system/patterns/wrap.d.mts +6 -6
- package/dist/src/styled-system/patterns/wrap.mjs +5 -2
- package/dist/src/styled-system/recipes/accordion.d.mts +8 -4
- package/dist/src/styled-system/recipes/accordion.mjs +6 -4
- package/dist/src/styled-system/recipes/alert-description.d.mts +8 -4
- package/dist/src/styled-system/recipes/alert-description.mjs +8 -3
- package/dist/src/styled-system/recipes/alert-dialog.d.mts +8 -4
- package/dist/src/styled-system/recipes/alert-dialog.mjs +6 -4
- package/dist/src/styled-system/recipes/alert-title.d.mts +8 -4
- package/dist/src/styled-system/recipes/alert-title.mjs +8 -3
- package/dist/src/styled-system/recipes/alert.d.mts +12 -5
- package/dist/src/styled-system/recipes/alert.mjs +8 -3
- package/dist/src/styled-system/recipes/avatar.d.mts +8 -4
- package/dist/src/styled-system/recipes/avatar.mjs +6 -4
- package/dist/src/styled-system/recipes/badge.d.mts +12 -5
- package/dist/src/styled-system/recipes/badge.mjs +8 -3
- package/dist/src/styled-system/recipes/blockquote.d.mts +8 -4
- package/dist/src/styled-system/recipes/blockquote.mjs +8 -3
- package/dist/src/styled-system/recipes/button.d.mts +15 -5
- package/dist/src/styled-system/recipes/button.mjs +8 -3
- package/dist/src/styled-system/recipes/calendar.d.mts +8 -4
- package/dist/src/styled-system/recipes/calendar.mjs +6 -4
- package/dist/src/styled-system/recipes/card-content.d.mts +8 -4
- package/dist/src/styled-system/recipes/card-content.mjs +8 -3
- package/dist/src/styled-system/recipes/card-description.d.mts +8 -4
- package/dist/src/styled-system/recipes/card-description.mjs +8 -3
- package/dist/src/styled-system/recipes/card-footer.d.mts +8 -4
- package/dist/src/styled-system/recipes/card-footer.mjs +8 -3
- package/dist/src/styled-system/recipes/card-header.d.mts +8 -4
- package/dist/src/styled-system/recipes/card-header.mjs +8 -3
- package/dist/src/styled-system/recipes/card-title.d.mts +8 -4
- package/dist/src/styled-system/recipes/card-title.mjs +8 -3
- package/dist/src/styled-system/recipes/card.d.mts +8 -4
- package/dist/src/styled-system/recipes/card.mjs +8 -3
- package/dist/src/styled-system/recipes/checkbox.d.mts +8 -4
- package/dist/src/styled-system/recipes/checkbox.mjs +6 -4
- package/dist/src/styled-system/recipes/collapsible.d.mts +8 -4
- package/dist/src/styled-system/recipes/collapsible.mjs +6 -4
- package/dist/src/styled-system/recipes/command-dialog.d.mts +8 -4
- package/dist/src/styled-system/recipes/command-dialog.mjs +6 -4
- package/dist/src/styled-system/recipes/command.d.mts +8 -4
- package/dist/src/styled-system/recipes/command.mjs +6 -4
- package/dist/src/styled-system/recipes/context-menu.d.mts +12 -5
- package/dist/src/styled-system/recipes/context-menu.mjs +6 -4
- package/dist/src/styled-system/recipes/create-recipe.mjs +39 -7
- package/dist/src/styled-system/recipes/dialog.d.mts +8 -4
- package/dist/src/styled-system/recipes/dialog.mjs +6 -4
- package/dist/src/styled-system/recipes/dropdown-menu.d.mts +8 -4
- package/dist/src/styled-system/recipes/dropdown-menu.mjs +6 -4
- package/dist/src/styled-system/recipes/form-control.d.mts +8 -4
- package/dist/src/styled-system/recipes/form-control.mjs +8 -3
- package/dist/src/styled-system/recipes/form-description.d.mts +8 -4
- package/dist/src/styled-system/recipes/form-description.mjs +8 -3
- package/dist/src/styled-system/recipes/form-item.d.mts +8 -4
- package/dist/src/styled-system/recipes/form-item.mjs +8 -3
- package/dist/src/styled-system/recipes/form-label.d.mts +8 -4
- package/dist/src/styled-system/recipes/form-label.mjs +8 -3
- package/dist/src/styled-system/recipes/form-message.d.mts +8 -4
- package/dist/src/styled-system/recipes/form-message.mjs +8 -3
- package/dist/src/styled-system/recipes/h1.d.mts +8 -4
- package/dist/src/styled-system/recipes/h1.mjs +8 -3
- package/dist/src/styled-system/recipes/h2.d.mts +8 -4
- package/dist/src/styled-system/recipes/h2.mjs +8 -3
- package/dist/src/styled-system/recipes/h3.d.mts +8 -4
- package/dist/src/styled-system/recipes/h3.mjs +8 -3
- package/dist/src/styled-system/recipes/h4.d.mts +8 -4
- package/dist/src/styled-system/recipes/h4.mjs +8 -3
- package/dist/src/styled-system/recipes/hover-card.d.mts +8 -4
- package/dist/src/styled-system/recipes/hover-card.mjs +6 -4
- package/dist/src/styled-system/recipes/icon.d.mts +24 -5
- package/dist/src/styled-system/recipes/icon.mjs +8 -3
- package/dist/src/styled-system/recipes/inline-code.d.mts +8 -4
- package/dist/src/styled-system/recipes/inline-code.mjs +8 -3
- package/dist/src/styled-system/recipes/input.d.mts +8 -4
- package/dist/src/styled-system/recipes/input.mjs +8 -3
- package/dist/src/styled-system/recipes/label.d.mts +8 -4
- package/dist/src/styled-system/recipes/label.mjs +8 -3
- package/dist/src/styled-system/recipes/large.d.mts +8 -4
- package/dist/src/styled-system/recipes/large.mjs +8 -3
- package/dist/src/styled-system/recipes/lead.d.mts +8 -4
- package/dist/src/styled-system/recipes/lead.mjs +8 -3
- package/dist/src/styled-system/recipes/link.d.mts +8 -4
- package/dist/src/styled-system/recipes/link.mjs +8 -3
- package/dist/src/styled-system/recipes/list.d.mts +8 -4
- package/dist/src/styled-system/recipes/list.mjs +8 -3
- package/dist/src/styled-system/recipes/menubar.d.mts +8 -4
- package/dist/src/styled-system/recipes/menubar.mjs +6 -4
- package/dist/src/styled-system/recipes/muted.d.mts +8 -4
- package/dist/src/styled-system/recipes/muted.mjs +8 -3
- package/dist/src/styled-system/recipes/navigation-menu.d.mts +8 -4
- package/dist/src/styled-system/recipes/navigation-menu.mjs +6 -4
- package/dist/src/styled-system/recipes/p.d.mts +8 -4
- package/dist/src/styled-system/recipes/p.mjs +8 -3
- package/dist/src/styled-system/recipes/popover.d.mts +8 -4
- package/dist/src/styled-system/recipes/popover.mjs +6 -4
- package/dist/src/styled-system/recipes/progress.d.mts +8 -4
- package/dist/src/styled-system/recipes/progress.mjs +6 -4
- package/dist/src/styled-system/recipes/radio-group.d.mts +8 -4
- package/dist/src/styled-system/recipes/radio-group.mjs +6 -4
- package/dist/src/styled-system/recipes/scroll-area.d.mts +8 -4
- package/dist/src/styled-system/recipes/scroll-area.mjs +6 -4
- package/dist/src/styled-system/recipes/select.d.mts +8 -4
- package/dist/src/styled-system/recipes/select.mjs +6 -4
- package/dist/src/styled-system/recipes/separator.d.mts +12 -5
- package/dist/src/styled-system/recipes/separator.mjs +8 -3
- package/dist/src/styled-system/recipes/sheet.d.mts +12 -5
- package/dist/src/styled-system/recipes/sheet.mjs +6 -4
- package/dist/src/styled-system/recipes/skeleton.d.mts +8 -4
- package/dist/src/styled-system/recipes/skeleton.mjs +8 -3
- package/dist/src/styled-system/recipes/slider.d.mts +8 -4
- package/dist/src/styled-system/recipes/slider.mjs +6 -4
- package/dist/src/styled-system/recipes/small.d.mts +8 -4
- package/dist/src/styled-system/recipes/small.mjs +8 -3
- package/dist/src/styled-system/recipes/switch-recipe.d.mts +8 -4
- package/dist/src/styled-system/recipes/switch-recipe.mjs +6 -4
- package/dist/src/styled-system/recipes/table-body.d.mts +8 -4
- package/dist/src/styled-system/recipes/table-body.mjs +8 -3
- package/dist/src/styled-system/recipes/table-caption.d.mts +8 -4
- package/dist/src/styled-system/recipes/table-caption.mjs +8 -3
- package/dist/src/styled-system/recipes/table-cell.d.mts +8 -4
- package/dist/src/styled-system/recipes/table-cell.mjs +8 -3
- package/dist/src/styled-system/recipes/table-container.d.mts +8 -4
- package/dist/src/styled-system/recipes/table-container.mjs +8 -3
- package/dist/src/styled-system/recipes/table-footer.d.mts +8 -4
- package/dist/src/styled-system/recipes/table-footer.mjs +8 -3
- package/dist/src/styled-system/recipes/table-head.d.mts +8 -4
- package/dist/src/styled-system/recipes/table-head.mjs +8 -3
- package/dist/src/styled-system/recipes/table-header.d.mts +8 -4
- package/dist/src/styled-system/recipes/table-header.mjs +8 -3
- package/dist/src/styled-system/recipes/table-row.d.mts +8 -4
- package/dist/src/styled-system/recipes/table-row.mjs +8 -3
- package/dist/src/styled-system/recipes/table.d.mts +8 -4
- package/dist/src/styled-system/recipes/table.mjs +8 -3
- package/dist/src/styled-system/recipes/tabs.d.mts +8 -4
- package/dist/src/styled-system/recipes/tabs.mjs +6 -4
- package/dist/src/styled-system/recipes/textarea.d.mts +8 -4
- package/dist/src/styled-system/recipes/textarea.mjs +8 -3
- package/dist/src/styled-system/recipes/toast-viewport.d.mts +8 -4
- package/dist/src/styled-system/recipes/toast-viewport.mjs +8 -3
- package/dist/src/styled-system/recipes/toast.d.mts +12 -5
- package/dist/src/styled-system/recipes/toast.mjs +6 -4
- package/dist/src/styled-system/recipes/toggle.d.mts +15 -5
- package/dist/src/styled-system/recipes/toggle.mjs +8 -3
- package/dist/src/styled-system/recipes/tooltip.d.mts +8 -4
- package/dist/src/styled-system/recipes/tooltip.mjs +6 -4
- package/dist/src/styled-system/recipes/typography-table-container.d.mts +8 -4
- package/dist/src/styled-system/recipes/typography-table-container.mjs +8 -3
- package/dist/src/styled-system/recipes/typography-table.d.mts +8 -4
- package/dist/src/styled-system/recipes/typography-table.mjs +8 -3
- package/dist/src/styled-system/tokens/index.mjs +271 -219
- package/dist/src/styled-system/tokens/tokens.d.mts +18 -18
- package/dist/src/styled-system/types/composition.d.mts +70 -17
- package/dist/src/styled-system/types/conditions.d.mts +105 -49
- package/dist/src/styled-system/types/csstype.d.mts +1270 -721
- package/dist/src/styled-system/types/global.d.mts +1 -0
- package/dist/src/styled-system/types/index.d.mts +1 -2
- package/dist/src/styled-system/types/parts.d.mts +3 -1
- package/dist/src/styled-system/types/pattern.d.mts +20 -3
- package/dist/src/styled-system/types/prop-type.d.mts +59 -135
- package/dist/src/styled-system/types/recipe.d.mts +42 -9
- package/dist/src/styled-system/types/selectors.d.mts +1 -1
- package/dist/src/styled-system/types/static-css.d.mts +56 -0
- package/dist/src/styled-system/types/style-props.d.mts +7540 -678
- package/dist/src/styled-system/types/system-types.d.mts +128 -20
- package/package.json +3 -3
- package/dist/src/styled-system/chunks/src__components__Node.css +0 -195
- package/dist/src/styled-system/chunks/src__components__PipelineCanvas.css +0 -25
- package/dist/src/styled-system/global.css +0 -70
- package/dist/src/styled-system/patterns/link-box.d.mts +0 -21
- package/dist/src/styled-system/patterns/link-box.mjs +0 -19
- package/dist/src/styled-system/recipes/create-recipe.d.mts +0 -1
- package/dist/src/styled-system/reset.css +0 -206
- package/dist/src/styled-system/static.css +0 -320
- package/dist/src/styled-system/tokens/index.css +0 -620
- package/dist/src/styled-system/tokens/keyframes.css +0 -56
- package/dist/src/styled-system/types/helpers.d.mts +0 -2
|
@@ -13,6 +13,7 @@ declare module '@pandacss/dev' {
|
|
|
13
13
|
export function defineStyles(definition: SystemStyleObject): SystemStyleObject
|
|
14
14
|
export function defineGlobalStyles(definition: GlobalStyleObject): Panda.GlobalStyleObject
|
|
15
15
|
export function defineTextStyles(definition: CompositionStyles['textStyles']): Panda.TextStyles
|
|
16
|
+
export function defineAnimationStyles(definition: CompositionStyles['animationStyles']): Panda.AnimationStyles
|
|
16
17
|
export function defineLayerStyles(definition: CompositionStyles['layerStyles']): Panda.LayerStyles
|
|
17
18
|
export function definePattern<T extends PatternProperties>(config: PatternConfig<T>): Panda.PatternConfig
|
|
18
19
|
export function defineParts<T extends Parts>(parts: T): (config: Partial<Record<keyof T, SystemStyleObject>>) => Partial<Record<keyof T, SystemStyleObject>>
|
|
@@ -13,11 +13,20 @@ export type PatternProperty =
|
|
|
13
13
|
|
|
14
14
|
export interface PatternHelpers {
|
|
15
15
|
map: (value: any, fn: (value: string) => string | undefined) => any
|
|
16
|
+
isCssUnit: (value: any) => boolean
|
|
17
|
+
isCssVar: (value: any) => boolean
|
|
18
|
+
isCssFunction: (value: any) => boolean
|
|
16
19
|
}
|
|
17
20
|
|
|
18
|
-
export
|
|
21
|
+
export interface PatternProperties {
|
|
22
|
+
[key: string]: PatternProperty
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
type InferProps<T> = Record<LiteralUnion<keyof T>, any>
|
|
19
26
|
|
|
20
|
-
type
|
|
27
|
+
export type PatternDefaultValue<T> = Partial<InferProps<T>>
|
|
28
|
+
|
|
29
|
+
export type PatternDefaultValueFn<T> = (props: InferProps<T>) => PatternDefaultValue<T>
|
|
21
30
|
|
|
22
31
|
export interface PatternConfig<T extends PatternProperties = PatternProperties> {
|
|
23
32
|
/**
|
|
@@ -33,10 +42,18 @@ export interface PatternConfig<T extends PatternProperties = PatternProperties>
|
|
|
33
42
|
* The properties of the pattern.
|
|
34
43
|
*/
|
|
35
44
|
properties?: T
|
|
45
|
+
/**
|
|
46
|
+
* The default values of the pattern.
|
|
47
|
+
*/
|
|
48
|
+
defaultValues?: PatternDefaultValue<T> | PatternDefaultValueFn<T>
|
|
36
49
|
/**
|
|
37
50
|
* The css object this pattern will generate.
|
|
38
51
|
*/
|
|
39
|
-
transform?: (props:
|
|
52
|
+
transform?: (props: InferProps<T>, helpers: PatternHelpers) => SystemStyleObject
|
|
53
|
+
/**
|
|
54
|
+
* Whether the pattern is deprecated.
|
|
55
|
+
*/
|
|
56
|
+
deprecated?: boolean | string
|
|
40
57
|
/**
|
|
41
58
|
* The jsx element name this pattern will generate.
|
|
42
59
|
*/
|
|
@@ -3,31 +3,24 @@ import type { ConditionalValue } from './conditions.d.mts';
|
|
|
3
3
|
import type { CssProperties } from './system-types.d.mts';
|
|
4
4
|
import type { Tokens } from '../tokens/index.d.mts';
|
|
5
5
|
|
|
6
|
-
interface
|
|
7
|
-
aspectRatio: "
|
|
8
|
-
zIndex: Tokens["zIndex"];
|
|
6
|
+
export interface UtilityValues {
|
|
7
|
+
aspectRatio: Tokens["aspectRatios"];
|
|
9
8
|
top: Tokens["spacing"];
|
|
10
9
|
left: Tokens["spacing"];
|
|
10
|
+
inset: "auto" | Tokens["spacing"];
|
|
11
11
|
insetInline: Tokens["spacing"];
|
|
12
12
|
insetBlock: Tokens["spacing"];
|
|
13
|
-
inset: "auto" | Tokens["spacing"];
|
|
14
13
|
insetBlockEnd: Tokens["spacing"];
|
|
15
14
|
insetBlockStart: Tokens["spacing"];
|
|
16
15
|
insetInlineEnd: Tokens["spacing"];
|
|
17
16
|
insetInlineStart: Tokens["spacing"];
|
|
18
17
|
right: Tokens["spacing"];
|
|
19
18
|
bottom: Tokens["spacing"];
|
|
20
|
-
|
|
21
|
-
insetY: Tokens["spacing"] | CssProperties["insetBlock"];
|
|
22
|
-
float: "left" | "right" | "start" | "end";
|
|
19
|
+
float: "start" | "end" | CssProperties["float"];
|
|
23
20
|
hideFrom: Tokens["breakpoints"];
|
|
24
21
|
hideBelow: Tokens["breakpoints"];
|
|
25
|
-
flexBasis: Tokens["
|
|
22
|
+
flexBasis: Tokens["sizes"] | "1/2" | "1/3" | "2/3" | "1/4" | "2/4" | "3/4" | "1/5" | "2/5" | "3/5" | "4/5" | "1/6" | "2/6" | "3/6" | "4/6" | "5/6" | "1/12" | "2/12" | "3/12" | "4/12" | "5/12" | "6/12" | "7/12" | "8/12" | "9/12" | "10/12" | "11/12" | "full";
|
|
26
23
|
flex: "1" | "auto" | "initial" | "none";
|
|
27
|
-
gridTemplateColumns: "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | "10" | "11" | "12";
|
|
28
|
-
gridTemplateRows: "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | "10" | "11" | "12";
|
|
29
|
-
gridColumn: "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | "10" | "11" | "12" | "full";
|
|
30
|
-
gridRow: "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | "10" | "11" | "12" | "full";
|
|
31
24
|
gridAutoColumns: "min" | "max" | "fr";
|
|
32
25
|
gridAutoRows: "min" | "max" | "fr";
|
|
33
26
|
gap: Tokens["spacing"];
|
|
@@ -58,11 +51,11 @@ interface PropertyValueTypes {
|
|
|
58
51
|
marginInline: "auto" | Tokens["spacing"];
|
|
59
52
|
marginInlineEnd: "auto" | Tokens["spacing"];
|
|
60
53
|
marginInlineStart: "auto" | Tokens["spacing"];
|
|
54
|
+
spaceX: Tokens["spacing"] | CssProperties["marginInlineStart"];
|
|
55
|
+
spaceY: Tokens["spacing"] | CssProperties["marginBlockStart"];
|
|
61
56
|
outlineColor: Tokens["colors"];
|
|
62
57
|
outline: Tokens["borders"];
|
|
63
58
|
outlineOffset: Tokens["spacing"];
|
|
64
|
-
divideX: string;
|
|
65
|
-
divideY: string;
|
|
66
59
|
divideColor: Tokens["colors"];
|
|
67
60
|
divideStyle: CssProperties["borderStyle"];
|
|
68
61
|
width: "auto" | Tokens["sizes"] | "1/2" | "1/3" | "2/3" | "1/4" | "2/4" | "3/4" | "1/5" | "2/5" | "3/5" | "4/5" | "1/6" | "2/6" | "3/6" | "4/6" | "5/6" | "1/12" | "2/12" | "3/12" | "4/12" | "5/12" | "6/12" | "7/12" | "8/12" | "9/12" | "10/12" | "11/12" | "screen";
|
|
@@ -88,14 +81,13 @@ interface PropertyValueTypes {
|
|
|
88
81
|
textEmphasisColor: Tokens["colors"];
|
|
89
82
|
textIndent: Tokens["spacing"];
|
|
90
83
|
textShadow: Tokens["shadows"];
|
|
84
|
+
textShadowColor: Tokens["colors"];
|
|
91
85
|
textWrap: "wrap" | "balance" | "nowrap";
|
|
92
86
|
truncate: boolean;
|
|
93
|
-
listStyleImage: Tokens["assets"];
|
|
94
87
|
background: Tokens["colors"];
|
|
95
88
|
backgroundColor: Tokens["colors"];
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
textGradient: Tokens["gradients"] | "to-t" | "to-tr" | "to-r" | "to-br" | "to-b" | "to-bl" | "to-l" | "to-tl";
|
|
89
|
+
backgroundGradient: "to-t" | "to-tr" | "to-r" | "to-br" | "to-b" | "to-bl" | "to-l" | "to-tl";
|
|
90
|
+
textGradient: "to-t" | "to-tr" | "to-r" | "to-br" | "to-b" | "to-bl" | "to-l" | "to-tl";
|
|
99
91
|
gradientFrom: Tokens["colors"];
|
|
100
92
|
gradientTo: Tokens["colors"];
|
|
101
93
|
gradientVia: Tokens["colors"];
|
|
@@ -117,20 +109,16 @@ interface PropertyValueTypes {
|
|
|
117
109
|
border: Tokens["borders"];
|
|
118
110
|
borderColor: Tokens["colors"];
|
|
119
111
|
borderInline: Tokens["borders"];
|
|
120
|
-
borderInlineWidth: Tokens["borderWidths"];
|
|
121
112
|
borderInlineColor: Tokens["colors"];
|
|
122
113
|
borderBlock: Tokens["borders"];
|
|
123
|
-
borderBlockWidth: Tokens["borderWidths"];
|
|
124
114
|
borderBlockColor: Tokens["colors"];
|
|
125
115
|
borderLeft: Tokens["borders"];
|
|
126
116
|
borderLeftColor: Tokens["colors"];
|
|
127
117
|
borderInlineStart: Tokens["borders"];
|
|
128
|
-
borderInlineStartWidth: Tokens["borderWidths"];
|
|
129
118
|
borderInlineStartColor: Tokens["colors"];
|
|
130
119
|
borderRight: Tokens["borders"];
|
|
131
120
|
borderRightColor: Tokens["colors"];
|
|
132
121
|
borderInlineEnd: Tokens["borders"];
|
|
133
|
-
borderInlineEndWidth: Tokens["borderWidths"];
|
|
134
122
|
borderInlineEndColor: Tokens["colors"];
|
|
135
123
|
borderTop: Tokens["borders"];
|
|
136
124
|
borderTopColor: Tokens["colors"];
|
|
@@ -144,11 +132,10 @@ interface PropertyValueTypes {
|
|
|
144
132
|
boxShadow: Tokens["shadows"];
|
|
145
133
|
boxShadowColor: Tokens["colors"];
|
|
146
134
|
filter: "auto";
|
|
147
|
-
dropShadow: Tokens["dropShadows"];
|
|
148
135
|
blur: Tokens["blurs"];
|
|
149
136
|
backdropFilter: "auto";
|
|
150
137
|
backdropBlur: "none" | "sm" | "base" | "md" | "lg" | "xl" | "2xl" | "3xl" | CssProperties["backdropFilter"];
|
|
151
|
-
borderSpacing: Tokens["spacing"];
|
|
138
|
+
borderSpacing: Tokens["spacing"] | "auto";
|
|
152
139
|
borderSpacingX: Tokens["spacing"];
|
|
153
140
|
borderSpacingY: Tokens["spacing"];
|
|
154
141
|
transitionTimingFunction: Tokens["easings"];
|
|
@@ -156,18 +143,25 @@ interface PropertyValueTypes {
|
|
|
156
143
|
transitionDuration: Tokens["durations"];
|
|
157
144
|
transition: "all" | "common" | "background" | "colors" | "opacity" | "shadow" | "transform";
|
|
158
145
|
animation: Tokens["animations"];
|
|
159
|
-
animationName:
|
|
146
|
+
animationName: "spin" | "ping" | "pulse" | "bounce" | "enter" | "exit" | "accordion-down" | "accordion-up";
|
|
147
|
+
animationTimingFunction: Tokens["easings"];
|
|
148
|
+
animationDuration: Tokens["durations"];
|
|
160
149
|
animationDelay: Tokens["durations"];
|
|
150
|
+
rotate: "auto" | "auto-3d" | CssProperties["rotate"];
|
|
151
|
+
rotateX: CssProperties["rotate"];
|
|
152
|
+
rotateY: CssProperties["rotate"];
|
|
153
|
+
rotateZ: CssProperties["rotate"];
|
|
161
154
|
scale: "auto" | CssProperties["scale"];
|
|
162
155
|
translate: Tokens["spacing"] | CssProperties["translate"];
|
|
163
156
|
translateX: Tokens["spacing"];
|
|
164
157
|
translateY: Tokens["spacing"];
|
|
158
|
+
translateZ: Tokens["spacing"] | "1/2" | "1/3" | "2/3" | "1/4" | "2/4" | "3/4" | "full" | "-1/2" | "-1/3" | "-2/3" | "-1/4" | "-2/4" | "-3/4" | "-full";
|
|
165
159
|
accentColor: Tokens["colors"];
|
|
166
160
|
caretColor: Tokens["colors"];
|
|
167
161
|
scrollbar: "visible" | "hidden";
|
|
162
|
+
scrollbarColor: Tokens["colors"];
|
|
163
|
+
scrollbarWidth: Tokens["sizes"];
|
|
168
164
|
scrollMargin: Tokens["spacing"];
|
|
169
|
-
scrollMarginX: Tokens["spacing"] | CssProperties["scrollMarginInline"];
|
|
170
|
-
scrollMarginY: Tokens["spacing"] | CssProperties["scrollMarginBlock"];
|
|
171
165
|
scrollMarginLeft: Tokens["spacing"];
|
|
172
166
|
scrollMarginRight: Tokens["spacing"];
|
|
173
167
|
scrollMarginTop: Tokens["spacing"];
|
|
@@ -185,8 +179,6 @@ interface PropertyValueTypes {
|
|
|
185
179
|
scrollPaddingInline: Tokens["spacing"];
|
|
186
180
|
scrollPaddingInlineEnd: Tokens["spacing"];
|
|
187
181
|
scrollPaddingInlineStart: Tokens["spacing"];
|
|
188
|
-
scrollPaddingX: Tokens["spacing"] | CssProperties["scrollPaddingInline"];
|
|
189
|
-
scrollPaddingY: Tokens["spacing"] | CssProperties["scrollPaddingBlock"];
|
|
190
182
|
scrollPaddingLeft: Tokens["spacing"];
|
|
191
183
|
scrollPaddingRight: Tokens["spacing"];
|
|
192
184
|
scrollPaddingTop: Tokens["spacing"];
|
|
@@ -202,6 +194,8 @@ interface PropertyValueTypes {
|
|
|
202
194
|
stroke: Tokens["colors"];
|
|
203
195
|
srOnly: boolean;
|
|
204
196
|
debug: boolean;
|
|
197
|
+
container: boolean;
|
|
198
|
+
containerName: CssProperties["containerName"];
|
|
205
199
|
animateIn: boolean;
|
|
206
200
|
animateOut: boolean;
|
|
207
201
|
fadeIn: Tokens["opacity"];
|
|
@@ -218,123 +212,53 @@ interface PropertyValueTypes {
|
|
|
218
212
|
gradientFromAlpha: string;
|
|
219
213
|
gradientToAlpha: string;
|
|
220
214
|
borderAlpha: CssProperties["borderColor"];
|
|
221
|
-
container: boolean;
|
|
222
215
|
focusRingWidth: "0" | "1" | "2" | "4" | "8" | "base";
|
|
223
216
|
focusRingColor: Tokens["colors"];
|
|
224
217
|
focusRingOffsetWidth: "0" | "1" | "2" | "4" | "8";
|
|
225
218
|
focusRingOffsetColor: Tokens["colors"];
|
|
226
219
|
focusRingInset: boolean;
|
|
227
|
-
spaceY: Tokens["spacing"];
|
|
228
|
-
spaceX: Tokens["spacing"];
|
|
229
220
|
textAlpha: CssProperties["color"];
|
|
230
|
-
colorPalette: "rose" | "pink" | "fuchsia" | "purple" | "violet" | "indigo" | "blue" | "sky" | "cyan" | "teal" | "emerald" | "green" | "lime" | "yellow" | "amber" | "orange" | "red" | "neutral" | "stone" | "zinc" | "gray" | "slate" | "hover" | "hover.light" | "hover.dark" | "light" | "dark" | "text" | "decoration" | "
|
|
221
|
+
colorPalette: "current" | "black" | "white" | "transparent" | "rose" | "pink" | "fuchsia" | "purple" | "violet" | "indigo" | "blue" | "sky" | "cyan" | "teal" | "emerald" | "green" | "lime" | "yellow" | "amber" | "orange" | "red" | "neutral" | "stone" | "zinc" | "gray" | "slate" | "grayscale" | "hover" | "hover.light" | "hover.dark" | "light" | "dark" | "text" | "decoration" | "background" | "foreground" | "muted" | "card" | "popover" | "border" | "input" | "secondary" | "accent" | "destructive" | "ring" | "primary";
|
|
231
222
|
textStyle: "xs" | "sm" | "md" | "lg" | "xl" | "2xl" | "3xl" | "4xl" | "5xl" | "6xl" | "7xl" | "8xl" | "9xl" | "h1" | "h2" | "h3" | "h4" | "p" | "lead" | "large" | "small";
|
|
232
|
-
layerStyle: string;
|
|
233
223
|
}
|
|
234
224
|
|
|
235
225
|
|
|
236
226
|
|
|
237
|
-
|
|
227
|
+
type WithColorOpacityModifier<T> = [T] extends [string] ? `${T}/${string}` & { __colorOpacityModifier?: true } : never
|
|
238
228
|
|
|
239
|
-
|
|
229
|
+
type ImportantMark = "!" | "!important"
|
|
230
|
+
type WhitespaceImportant = ` ${ImportantMark}`
|
|
231
|
+
type Important = ImportantMark | WhitespaceImportant
|
|
232
|
+
type WithImportant<T> = [T] extends [string] ? `${T}${Important}` & { __important?: true } : never
|
|
240
233
|
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
pe: Shorthand<"paddingInlineEnd">;
|
|
259
|
-
paddingEnd: Shorthand<"paddingInlineEnd">;
|
|
260
|
-
ps: Shorthand<"paddingInlineStart">;
|
|
261
|
-
paddingStart: Shorthand<"paddingInlineStart">;
|
|
262
|
-
ml: Shorthand<"marginLeft">;
|
|
263
|
-
mr: Shorthand<"marginRight">;
|
|
264
|
-
mt: Shorthand<"marginTop">;
|
|
265
|
-
mb: Shorthand<"marginBottom">;
|
|
266
|
-
m: Shorthand<"margin">;
|
|
267
|
-
my: Shorthand<"marginBlock">;
|
|
268
|
-
marginY: Shorthand<"marginBlock">;
|
|
269
|
-
mx: Shorthand<"marginInline">;
|
|
270
|
-
marginX: Shorthand<"marginInline">;
|
|
271
|
-
me: Shorthand<"marginInlineEnd">;
|
|
272
|
-
marginEnd: Shorthand<"marginInlineEnd">;
|
|
273
|
-
ms: Shorthand<"marginInlineStart">;
|
|
274
|
-
marginStart: Shorthand<"marginInlineStart">;
|
|
275
|
-
ringWidth: Shorthand<"outlineWidth">;
|
|
276
|
-
ringColor: Shorthand<"outlineColor">;
|
|
277
|
-
ring: Shorthand<"outline">;
|
|
278
|
-
ringOffset: Shorthand<"outlineOffset">;
|
|
279
|
-
w: Shorthand<"width">;
|
|
280
|
-
minW: Shorthand<"minWidth">;
|
|
281
|
-
maxW: Shorthand<"maxWidth">;
|
|
282
|
-
h: Shorthand<"height">;
|
|
283
|
-
minH: Shorthand<"minHeight">;
|
|
284
|
-
maxH: Shorthand<"maxHeight">;
|
|
285
|
-
tracking: Shorthand<"letterSpacing">;
|
|
286
|
-
leading: Shorthand<"lineHeight">;
|
|
287
|
-
bgPosition: Shorthand<"backgroundPosition">;
|
|
288
|
-
bgPositionX: Shorthand<"backgroundPositionX">;
|
|
289
|
-
bgPositionY: Shorthand<"backgroundPositionY">;
|
|
290
|
-
bgAttachment: Shorthand<"backgroundAttachment">;
|
|
291
|
-
bgClip: Shorthand<"backgroundClip">;
|
|
292
|
-
bg: Shorthand<"background">;
|
|
293
|
-
bgColor: Shorthand<"backgroundColor">;
|
|
294
|
-
bgOrigin: Shorthand<"backgroundOrigin">;
|
|
295
|
-
bgImage: Shorthand<"backgroundImage">;
|
|
296
|
-
bgRepeat: Shorthand<"backgroundRepeat">;
|
|
297
|
-
bgBlendMode: Shorthand<"backgroundBlendMode">;
|
|
298
|
-
bgSize: Shorthand<"backgroundSize">;
|
|
299
|
-
bgGradient: Shorthand<"backgroundGradient">;
|
|
300
|
-
rounded: Shorthand<"borderRadius">;
|
|
301
|
-
roundedTopLeft: Shorthand<"borderTopLeftRadius">;
|
|
302
|
-
roundedTopRight: Shorthand<"borderTopRightRadius">;
|
|
303
|
-
roundedBottomRight: Shorthand<"borderBottomRightRadius">;
|
|
304
|
-
roundedBottomLeft: Shorthand<"borderBottomLeftRadius">;
|
|
305
|
-
roundedTop: Shorthand<"borderTopRadius">;
|
|
306
|
-
roundedRight: Shorthand<"borderRightRadius">;
|
|
307
|
-
roundedBottom: Shorthand<"borderBottomRadius">;
|
|
308
|
-
roundedLeft: Shorthand<"borderLeftRadius">;
|
|
309
|
-
roundedStartStart: Shorthand<"borderStartStartRadius">;
|
|
310
|
-
roundedStartEnd: Shorthand<"borderStartEndRadius">;
|
|
311
|
-
roundedStart: Shorthand<"borderStartRadius">;
|
|
312
|
-
roundedEndStart: Shorthand<"borderEndStartRadius">;
|
|
313
|
-
roundedEndEnd: Shorthand<"borderEndEndRadius">;
|
|
314
|
-
roundedEnd: Shorthand<"borderEndRadius">;
|
|
315
|
-
borderX: Shorthand<"borderInline">;
|
|
316
|
-
borderXWidth: Shorthand<"borderInlineWidth">;
|
|
317
|
-
borderXColor: Shorthand<"borderInlineColor">;
|
|
318
|
-
borderY: Shorthand<"borderBlock">;
|
|
319
|
-
borderYWidth: Shorthand<"borderBlockWidth">;
|
|
320
|
-
borderYColor: Shorthand<"borderBlockColor">;
|
|
321
|
-
borderStart: Shorthand<"borderInlineStart">;
|
|
322
|
-
borderStartWidth: Shorthand<"borderInlineStartWidth">;
|
|
323
|
-
borderStartColor: Shorthand<"borderInlineStartColor">;
|
|
324
|
-
borderEnd: Shorthand<"borderInlineEnd">;
|
|
325
|
-
borderEndWidth: Shorthand<"borderInlineEndWidth">;
|
|
326
|
-
borderEndColor: Shorthand<"borderInlineEndColor">;
|
|
327
|
-
shadow: Shorthand<"boxShadow">;
|
|
328
|
-
shadowColor: Shorthand<"boxShadowColor">;
|
|
329
|
-
x: Shorthand<"translateX">;
|
|
330
|
-
y: Shorthand<"translateY">;
|
|
331
|
-
bga: Shorthand<"backgroundAlpha">;
|
|
332
|
-
bca: Shorthand<"borderAlpha">;
|
|
333
|
-
ca: Shorthand<"textAlpha">;
|
|
334
|
-
}
|
|
234
|
+
/**
|
|
235
|
+
* Only relevant when using `strictTokens` or `strictPropertyValues` in your config.
|
|
236
|
+
* - Allows you to use an escape hatch (e.g. `[123px]`) to use any string as a value.
|
|
237
|
+
* - Allows you to use a color opacity modifier (e.g. `red/300`) with known color values.
|
|
238
|
+
* - Allows you to use an important mark (e.g. `!` or `!important`) in the value.
|
|
239
|
+
*
|
|
240
|
+
* This is useful when you want to use a value that is not defined in the config or want to opt-out of the defaults.
|
|
241
|
+
*
|
|
242
|
+
* @example
|
|
243
|
+
* css({
|
|
244
|
+
* fontSize: '[123px]', // ⚠️ will not throw even if you haven't defined 123px as a token
|
|
245
|
+
* })
|
|
246
|
+
*
|
|
247
|
+
* @see https://panda-css.com/docs/concepts/writing-styles#stricttokens
|
|
248
|
+
* @see https://panda-css.com/docs/concepts/writing-styles#strictpropertyvalues
|
|
249
|
+
*/
|
|
250
|
+
export type WithEscapeHatch<T> = T | `[${string}]` | WithColorOpacityModifier<T> | WithImportant<T>
|
|
335
251
|
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
252
|
+
/**
|
|
253
|
+
* Will restrict the value of properties that have predefined values to those values only.
|
|
254
|
+
*
|
|
255
|
+
* @example
|
|
256
|
+
* css({
|
|
257
|
+
* display: 'abc', // ❌ will throw
|
|
258
|
+
* })
|
|
259
|
+
*
|
|
260
|
+
* @see https://panda-css.com/docs/concepts/writing-styles#strictpropertyvalues
|
|
261
|
+
*/
|
|
262
|
+
export type OnlyKnown<Key, Value> = Value extends boolean
|
|
263
|
+
? Value
|
|
264
|
+
: Value extends `${infer _}` ? Value : never
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
/* eslint-disable */
|
|
2
|
-
import type {
|
|
3
|
-
|
|
4
|
-
type Pretty<T> = { [K in keyof T]: T[K] } & {}
|
|
2
|
+
import type { RecipeRule } from './static-css.d.mts';
|
|
3
|
+
import type { SystemStyleObject, DistributiveOmit, Pretty } from './system-types.d.mts';
|
|
5
4
|
|
|
6
5
|
type StringToBoolean<T> = T extends 'true' | 'false' ? boolean : T
|
|
7
6
|
|
|
@@ -10,15 +9,26 @@ export type RecipeVariantRecord = Record<any, Record<any, SystemStyleObject>>
|
|
|
10
9
|
export type RecipeSelection<T extends RecipeVariantRecord> = keyof any extends keyof T
|
|
11
10
|
? {}
|
|
12
11
|
: {
|
|
13
|
-
[K in keyof T]?: StringToBoolean<keyof T[K]>
|
|
12
|
+
[K in keyof T]?: StringToBoolean<keyof T[K]> | undefined
|
|
14
13
|
}
|
|
15
14
|
|
|
16
15
|
export type RecipeVariantFn<T extends RecipeVariantRecord> = (props?: RecipeSelection<T>) => string
|
|
17
16
|
|
|
17
|
+
/**
|
|
18
|
+
* Extract the variant as optional props from a `cva` function.
|
|
19
|
+
* Intended to be used with a JSX component, prefer `RecipeVariant` for a more strict type.
|
|
20
|
+
*/
|
|
18
21
|
export type RecipeVariantProps<
|
|
19
22
|
T extends RecipeVariantFn<RecipeVariantRecord> | SlotRecipeVariantFn<string, SlotRecipeVariantRecord<string>>,
|
|
20
23
|
> = Pretty<Parameters<T>[0]>
|
|
21
24
|
|
|
25
|
+
/**
|
|
26
|
+
* Extract the variants from a `cva` function.
|
|
27
|
+
*/
|
|
28
|
+
export type RecipeVariant<
|
|
29
|
+
T extends RecipeVariantFn<RecipeVariantRecord> | SlotRecipeVariantFn<string, SlotRecipeVariantRecord<string>>,
|
|
30
|
+
> = Exclude<Pretty<Required<RecipeVariantProps<T>>>, undefined>
|
|
31
|
+
|
|
22
32
|
type RecipeVariantMap<T extends RecipeVariantRecord> = {
|
|
23
33
|
[K in keyof T]: Array<keyof T[K]>
|
|
24
34
|
}
|
|
@@ -36,23 +46,28 @@ export interface RecipeRuntimeFn<T extends RecipeVariantRecord> extends RecipeVa
|
|
|
36
46
|
splitVariantProps<Props extends RecipeSelection<T>>(
|
|
37
47
|
props: Props,
|
|
38
48
|
): [RecipeSelection<T>, Pretty<DistributiveOmit<Props, keyof T>>]
|
|
49
|
+
getVariantProps: (props?: RecipeSelection<T>) => RecipeSelection<T>
|
|
39
50
|
}
|
|
40
51
|
|
|
41
52
|
type OneOrMore<T> = T | Array<T>
|
|
42
53
|
|
|
43
54
|
export type RecipeCompoundSelection<T> = {
|
|
44
|
-
[K in keyof T]?: OneOrMore<StringToBoolean<keyof T[K]>>
|
|
55
|
+
[K in keyof T]?: OneOrMore<StringToBoolean<keyof T[K]>> | undefined
|
|
45
56
|
}
|
|
46
57
|
|
|
47
58
|
export type RecipeCompoundVariant<T> = T & {
|
|
48
59
|
css: SystemStyleObject
|
|
49
60
|
}
|
|
50
61
|
|
|
51
|
-
export interface RecipeDefinition<T extends RecipeVariantRecord> {
|
|
62
|
+
export interface RecipeDefinition<T extends RecipeVariantRecord = RecipeVariantRecord> {
|
|
52
63
|
/**
|
|
53
64
|
* The base styles of the recipe.
|
|
54
65
|
*/
|
|
55
66
|
base?: SystemStyleObject
|
|
67
|
+
/**
|
|
68
|
+
* Whether the recipe is deprecated.
|
|
69
|
+
*/
|
|
70
|
+
deprecated?: boolean | string
|
|
56
71
|
/**
|
|
57
72
|
* The multi-variant styles of the recipe.
|
|
58
73
|
*/
|
|
@@ -71,7 +86,7 @@ export type RecipeCreatorFn = <T extends RecipeVariantRecord>(config: RecipeDefi
|
|
|
71
86
|
|
|
72
87
|
interface RecipeConfigMeta {
|
|
73
88
|
/**
|
|
74
|
-
* The name of the recipe.
|
|
89
|
+
* The class name of the recipe.
|
|
75
90
|
*/
|
|
76
91
|
className: string
|
|
77
92
|
/**
|
|
@@ -85,6 +100,10 @@ interface RecipeConfigMeta {
|
|
|
85
100
|
* @example ['Button', 'Link', /Button$/]
|
|
86
101
|
*/
|
|
87
102
|
jsx?: Array<string | RegExp>
|
|
103
|
+
/**
|
|
104
|
+
* Variants to pre-generate, will be include in the final `config.staticCss`
|
|
105
|
+
*/
|
|
106
|
+
staticCss?: RecipeRule[]
|
|
88
107
|
}
|
|
89
108
|
|
|
90
109
|
export interface RecipeConfig<T extends RecipeVariantRecord = RecipeVariantRecord>
|
|
@@ -108,14 +127,28 @@ export interface SlotRecipeRuntimeFn<S extends string, T extends SlotRecipeVaria
|
|
|
108
127
|
raw: (props?: RecipeSelection<T>) => Record<S, SystemStyleObject>
|
|
109
128
|
variantKeys: (keyof T)[]
|
|
110
129
|
variantMap: RecipeVariantMap<T>
|
|
111
|
-
splitVariantProps<Props extends RecipeSelection<T>>(
|
|
130
|
+
splitVariantProps<Props extends RecipeSelection<T>>(
|
|
131
|
+
props: Props,
|
|
132
|
+
): [RecipeSelection<T>, Pretty<DistributiveOmit<Props, keyof T>>]
|
|
133
|
+
getVariantProps: (props?: RecipeSelection<T>) => RecipeSelection<T>
|
|
112
134
|
}
|
|
113
135
|
|
|
114
136
|
export type SlotRecipeCompoundVariant<S extends string, T> = T & {
|
|
115
137
|
css: SlotRecord<S, SystemStyleObject>
|
|
116
138
|
}
|
|
117
139
|
|
|
118
|
-
export interface SlotRecipeDefinition<
|
|
140
|
+
export interface SlotRecipeDefinition<
|
|
141
|
+
S extends string = string,
|
|
142
|
+
T extends SlotRecipeVariantRecord<S> = SlotRecipeVariantRecord<S>,
|
|
143
|
+
> {
|
|
144
|
+
/**
|
|
145
|
+
* An optional class name that can be used to target slots in the DOM.
|
|
146
|
+
*/
|
|
147
|
+
className?: string
|
|
148
|
+
/**
|
|
149
|
+
* Whether the recipe is deprecated.
|
|
150
|
+
*/
|
|
151
|
+
deprecated?: boolean | string
|
|
119
152
|
/**
|
|
120
153
|
* The parts/slots of the recipe.
|
|
121
154
|
*/
|
|
@@ -53,7 +53,7 @@ type DataAttributes =
|
|
|
53
53
|
type AttributeSelector = `&${Pseudos | DataAttributes | AriaAttributes}`
|
|
54
54
|
type ParentSelector = `${DataAttributes | AriaAttributes} &`
|
|
55
55
|
|
|
56
|
-
type AtRuleType = 'media' | 'layer' | 'container' | 'supports' | 'page'
|
|
56
|
+
type AtRuleType = 'media' | 'layer' | 'container' | 'supports' | 'page' | 'scope' | 'starting-style'
|
|
57
57
|
|
|
58
58
|
export type AnySelector = `${string}&` | `&${string}` | `@${AtRuleType}${string}`
|
|
59
59
|
export type Selectors = AttributeSelector | ParentSelector
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
interface ConditionOptions {
|
|
3
|
+
/**
|
|
4
|
+
* The conditions to generate for the rule.
|
|
5
|
+
* @example ['hover', 'focus']
|
|
6
|
+
*/
|
|
7
|
+
conditions?: string[]
|
|
8
|
+
/**
|
|
9
|
+
* Whether to generate responsive styles for the rule.
|
|
10
|
+
*/
|
|
11
|
+
responsive?: boolean
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
export interface CssRule extends ConditionOptions {
|
|
15
|
+
/**
|
|
16
|
+
* The css properties to generate utilities for.
|
|
17
|
+
* @example ['margin', 'padding']
|
|
18
|
+
*/
|
|
19
|
+
properties: {
|
|
20
|
+
[property: string]: Array<string | number>
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
interface RecipeRuleVariants {
|
|
25
|
+
[variant: string]: boolean | string[]
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export type RecipeRuleObject = RecipeRuleVariants & ConditionOptions
|
|
29
|
+
export type RecipeRule = '*' | RecipeRuleObject
|
|
30
|
+
|
|
31
|
+
export type PatternRule = '*' | CssRule
|
|
32
|
+
|
|
33
|
+
export interface StaticCssOptions {
|
|
34
|
+
/**
|
|
35
|
+
* The css utility classes to generate.
|
|
36
|
+
*/
|
|
37
|
+
css?: CssRule[]
|
|
38
|
+
/**
|
|
39
|
+
* The css recipes to generate.
|
|
40
|
+
*/
|
|
41
|
+
recipes?:
|
|
42
|
+
| '*'
|
|
43
|
+
| {
|
|
44
|
+
[recipe: string]: RecipeRule[]
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
* The css patterns to generate.
|
|
48
|
+
*/
|
|
49
|
+
patterns?: {
|
|
50
|
+
[pattern: string]: PatternRule[]
|
|
51
|
+
}
|
|
52
|
+
/**
|
|
53
|
+
* The CSS themes to generate
|
|
54
|
+
*/
|
|
55
|
+
themes?: string[]
|
|
56
|
+
}
|