@stokelp/styled-system 2.24.0 → 2.26.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stokelp/styled-system",
3
- "version": "2.24.0",
3
+ "version": "2.26.0",
4
4
  "description": "Stokelp UI styled-system",
5
5
  "type": "module",
6
6
  "publishConfig": {
@@ -38,14 +38,21 @@
38
38
  "width]___[value:16",
39
39
  "height]___[value:16",
40
40
  "paddingInline]___[value:space-8",
41
+ "width]___[value:21px]___[cond:& > svg",
42
+ "height]___[value:15px]___[cond:& > svg",
43
+ "borderRadius]___[value:3px]___[cond:& > svg",
44
+ "display]___[value:flex",
45
+ "alignItems]___[value:center",
46
+ "gap]___[value:space-8",
47
+ "flexDirection]___[value:row",
48
+ "width]___[value:full",
49
+ "width]___[value:fit-content !important",
41
50
  "transitionProperty]___[value:opacity",
42
51
  "transitionDuration]___[value:fast",
43
52
  "opacity]___[value:0",
44
53
  "visibility]___[value:hidden",
45
54
  "opacity]___[value:1]___[cond:_groupHover",
46
55
  "visibility]___[value:visible]___[cond:_groupHover",
47
- "display]___[value:flex",
48
- "alignItems]___[value:center",
49
56
  "justifyContent]___[value:center",
50
57
  "flex]___[value:0 0 auto",
51
58
  "borderRadius]___[value:9999px",
@@ -69,7 +76,6 @@
69
76
  "gap]___[value:space-32",
70
77
  "padding]___[value:space-16",
71
78
  "marginTop]___[value:100",
72
- "flexDirection]___[value:row",
73
79
  "color]___[value:primary.500",
74
80
  "color]___[value:secondary.500",
75
81
  "color]___[value:success.500",
@@ -77,7 +83,6 @@
77
83
  "borderRadius]___[value:radius-24",
78
84
  "height]___[value:200",
79
85
  "width]___[value:400",
80
- "gap]___[value:space-8",
81
86
  "maxHeight]___[value:102",
82
87
  "overflowY]___[value:auto",
83
88
  "alignSelf]___[value:flex-end",
@@ -102,9 +107,7 @@
102
107
  "color]___[value:grey.100",
103
108
  "textStyle]___[value:body.lg",
104
109
  "textStyle]___[value:body.md",
105
- "textStyle]___[value:body.sm",
106
- "borderRadius]___[value:3px]___[cond:& > svg",
107
- "width]___[value:full"
110
+ "textStyle]___[value:body.sm"
108
111
  ],
109
112
  "recipes": {
110
113
  "iconButton": [
@@ -28,6 +28,7 @@ export * from './tabs';
28
28
  export * from './tag';
29
29
  export * from './status-tag-select';
30
30
  export * from './select';
31
+ export * from './select-language';
31
32
  export * from './chip';
32
33
  export * from './action-card';
33
34
  export * from './tooltip';
package/recipes/index.mjs CHANGED
@@ -27,6 +27,7 @@ export * from './tabs.mjs';
27
27
  export * from './tag.mjs';
28
28
  export * from './status-tag-select.mjs';
29
29
  export * from './select.mjs';
30
+ export * from './select-language.mjs';
30
31
  export * from './chip.mjs';
31
32
  export * from './action-card.mjs';
32
33
  export * from './tooltip.mjs';
@@ -0,0 +1,31 @@
1
+ /* eslint-disable */
2
+ import type { ConditionalValue } from '../types/index';
3
+ import type { DistributiveOmit, Pretty } from '../types/system-types';
4
+
5
+ interface SelectLanguageVariant {
6
+ /**
7
+ * @default "default"
8
+ */
9
+ variant: "default" | "compact"
10
+ }
11
+
12
+ type SelectLanguageVariantMap = {
13
+ [key in keyof SelectLanguageVariant]: Array<SelectLanguageVariant[key]>
14
+ }
15
+
16
+ export type SelectLanguageVariantProps = {
17
+ [key in keyof SelectLanguageVariant]?: ConditionalValue<SelectLanguageVariant[key]> | undefined
18
+ }
19
+
20
+ export interface SelectLanguageRecipe {
21
+ __type: SelectLanguageVariantProps
22
+ (props?: SelectLanguageVariantProps): Pretty<Record<"label" | "positioner" | "trigger" | "indicator" | "clearTrigger" | "item" | "itemText" | "itemIndicator" | "itemGroup" | "itemGroupLabel" | "list" | "content" | "root" | "control" | "valueText", string>>
23
+ raw: (props?: SelectLanguageVariantProps) => SelectLanguageVariantProps
24
+ variantMap: SelectLanguageVariantMap
25
+ variantKeys: Array<keyof SelectLanguageVariant>
26
+ splitVariantProps<Props extends SelectLanguageVariantProps>(props: Props): [SelectLanguageVariantProps, Pretty<DistributiveOmit<Props, keyof SelectLanguageVariantProps>>]
27
+ getVariantProps: (props?: SelectLanguageVariantProps) => SelectLanguageVariantProps
28
+ }
29
+
30
+
31
+ export declare const selectLanguage: SelectLanguageRecipe
@@ -0,0 +1,97 @@
1
+ import { compact, getSlotCompoundVariant, memo, splitProps } from '../helpers.mjs';
2
+ import { createRecipe } from './create-recipe.mjs';
3
+
4
+ const selectLanguageDefaultVariants = {
5
+ "variant": "default"
6
+ }
7
+ const selectLanguageCompoundVariants = []
8
+
9
+ const selectLanguageSlotNames = [
10
+ [
11
+ "label",
12
+ "select-language__label"
13
+ ],
14
+ [
15
+ "positioner",
16
+ "select-language__positioner"
17
+ ],
18
+ [
19
+ "trigger",
20
+ "select-language__trigger"
21
+ ],
22
+ [
23
+ "indicator",
24
+ "select-language__indicator"
25
+ ],
26
+ [
27
+ "clearTrigger",
28
+ "select-language__clearTrigger"
29
+ ],
30
+ [
31
+ "item",
32
+ "select-language__item"
33
+ ],
34
+ [
35
+ "itemText",
36
+ "select-language__itemText"
37
+ ],
38
+ [
39
+ "itemIndicator",
40
+ "select-language__itemIndicator"
41
+ ],
42
+ [
43
+ "itemGroup",
44
+ "select-language__itemGroup"
45
+ ],
46
+ [
47
+ "itemGroupLabel",
48
+ "select-language__itemGroupLabel"
49
+ ],
50
+ [
51
+ "list",
52
+ "select-language__list"
53
+ ],
54
+ [
55
+ "content",
56
+ "select-language__content"
57
+ ],
58
+ [
59
+ "root",
60
+ "select-language__root"
61
+ ],
62
+ [
63
+ "control",
64
+ "select-language__control"
65
+ ],
66
+ [
67
+ "valueText",
68
+ "select-language__valueText"
69
+ ]
70
+ ]
71
+ const selectLanguageSlotFns = /* @__PURE__ */ selectLanguageSlotNames.map(([slotName, slotKey]) => [slotName, createRecipe(slotKey, selectLanguageDefaultVariants, getSlotCompoundVariant(selectLanguageCompoundVariants, slotName))])
72
+
73
+ const selectLanguageFn = memo((props = {}) => {
74
+ return Object.fromEntries(selectLanguageSlotFns.map(([slotName, slotFn]) => [slotName, slotFn.recipeFn(props)]))
75
+ })
76
+
77
+ const selectLanguageVariantKeys = [
78
+ "variant"
79
+ ]
80
+ const getVariantProps = (variants) => ({ ...selectLanguageDefaultVariants, ...compact(variants) })
81
+
82
+ export const selectLanguage = /* @__PURE__ */ Object.assign(selectLanguageFn, {
83
+ __recipe__: false,
84
+ __name__: 'selectLanguage',
85
+ raw: (props) => props,
86
+ variantKeys: selectLanguageVariantKeys,
87
+ variantMap: {
88
+ "variant": [
89
+ "default",
90
+ "compact"
91
+ ]
92
+ },
93
+ splitVariantProps(props) {
94
+ return splitProps(props, selectLanguageVariantKeys)
95
+ },
96
+ getVariantProps
97
+ })
@@ -146,7 +146,7 @@ export interface UtilityValues {
146
146
  transitionDuration: Tokens["durations"];
147
147
  transition: "all" | "common" | "background" | "colors" | "opacity" | "shadow" | "transform";
148
148
  animation: Tokens["animations"];
149
- animationName: "blob" | "bounce" | "fade-in" | "fade-out" | "fadeIn" | "fadeInFromRight" | "fadeInSkew" | "fadeOut" | "fadeOutFromRight" | "fadeOutSkew" | "ping" | "pulse" | "skeleton-pulse" | "slide-in" | "slide-in-left" | "slide-in-modal" | "slide-in-right" | "slide-out" | "slide-out-left" | "slide-out-modal" | "slide-out-right" | "slideInFromBottom" | "slideOutToBottom" | "collapse-in" | "collapse-out" | "spin";
149
+ animationName: "blob" | "bounce" | "fade-in" | "fade-out" | "fadeIn" | "fadeInFromRight" | "fadeInSkew" | "fadeOut" | "fadeOutFromRight" | "fadeOutSkew" | "ping" | "pulse" | "skeleton-pulse" | "slide-in" | "slide-in-left" | "slide-in-modal" | "slide-in-top-modal" | "slide-in-right" | "slide-out" | "slide-out-left" | "slide-out-modal" | "slide-out-top-modal" | "slide-out-right" | "slideInFromBottom" | "slideOutToBottom" | "collapse-in" | "collapse-out" | "spin";
150
150
  animationTimingFunction: Tokens["easings"];
151
151
  animationDuration: Tokens["durations"];
152
152
  animationDelay: Tokens["durations"];