@stokelp/styled-system 2.7.0 → 2.9.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.7.0",
3
+ "version": "2.9.0",
4
4
  "description": "Stokelp UI styled-system",
5
5
  "type": "module",
6
6
  "publishConfig": {
@@ -49,6 +49,7 @@
49
49
  "justifyContent]___[value:center",
50
50
  "flex]___[value:0 0 auto",
51
51
  "borderRadius]___[value:9999px",
52
+ "paddingBottom]___[value:space-24",
52
53
  "display]___[value:grid",
53
54
  "gridTemplateColumns]___[value:repeat(auto-fit, minmax(300px, 1fr))",
54
55
  "gap]___[value:10px",
@@ -154,16 +155,19 @@
154
155
  "severity]___[value:warning]___[recipe:tag",
155
156
  "severity]___[value:error]___[recipe:tag"
156
157
  ],
157
- "productCardCatalog": [],
158
+ "appNavigation": [
159
+ "variant]___[value:prod]___[recipe:appNavigation"
160
+ ],
158
161
  "heading": [
159
162
  "size]___[value:h2]___[recipe:heading"
160
163
  ],
164
+ "collapsible": [],
165
+ "productCardCatalog": [],
161
166
  "accordion": [
162
167
  "size]___[value:md]___[recipe:accordion"
163
168
  ],
164
169
  "actionCard": [],
165
170
  "breadcrumb": [],
166
- "collapsible": [],
167
171
  "combobox": [
168
172
  "size]___[value:md]___[recipe:combobox"
169
173
  ],
@@ -0,0 +1,35 @@
1
+ /* eslint-disable */
2
+ import type { ConditionalValue } from '../types/index';
3
+ import type { DistributiveOmit, Pretty } from '../types/system-types';
4
+
5
+ interface AppNavigationVariant {
6
+ /**
7
+ * @default "prod"
8
+ */
9
+ variant: "prod" | "staging" | "dev"
10
+ }
11
+
12
+ type AppNavigationVariantMap = {
13
+ [key in keyof AppNavigationVariant]: Array<AppNavigationVariant[key]>
14
+ }
15
+
16
+ export type AppNavigationVariantProps = {
17
+ [key in keyof AppNavigationVariant]?: ConditionalValue<AppNavigationVariant[key]> | undefined
18
+ }
19
+
20
+ export interface AppNavigationRecipe {
21
+ __type: AppNavigationVariantProps
22
+ (props?: AppNavigationVariantProps): Pretty<Record<"root" | "header" | "body" | "item" | "itemLabel" | "itemIcon" | "itemContent" | "itemSubItems" | "footer", string>>
23
+ raw: (props?: AppNavigationVariantProps) => AppNavigationVariantProps
24
+ variantMap: AppNavigationVariantMap
25
+ variantKeys: Array<keyof AppNavigationVariant>
26
+ splitVariantProps<Props extends AppNavigationVariantProps>(props: Props): [AppNavigationVariantProps, Pretty<DistributiveOmit<Props, keyof AppNavigationVariantProps>>]
27
+ getVariantProps: (props?: AppNavigationVariantProps) => AppNavigationVariantProps
28
+ }
29
+
30
+ /**
31
+ * The styles for the AppNavigation component
32
+
33
+
34
+ */
35
+ export declare const appNavigation: AppNavigationRecipe
@@ -0,0 +1,74 @@
1
+ import { compact, getSlotCompoundVariant, memo, splitProps } from '../helpers.mjs';
2
+ import { createRecipe } from './create-recipe.mjs';
3
+
4
+ const appNavigationDefaultVariants = {
5
+ "variant": "prod"
6
+ }
7
+ const appNavigationCompoundVariants = []
8
+
9
+ const appNavigationSlotNames = [
10
+ [
11
+ "root",
12
+ "app-navigation__root"
13
+ ],
14
+ [
15
+ "header",
16
+ "app-navigation__header"
17
+ ],
18
+ [
19
+ "body",
20
+ "app-navigation__body"
21
+ ],
22
+ [
23
+ "item",
24
+ "app-navigation__item"
25
+ ],
26
+ [
27
+ "itemLabel",
28
+ "app-navigation__itemLabel"
29
+ ],
30
+ [
31
+ "itemIcon",
32
+ "app-navigation__itemIcon"
33
+ ],
34
+ [
35
+ "itemContent",
36
+ "app-navigation__itemContent"
37
+ ],
38
+ [
39
+ "itemSubItems",
40
+ "app-navigation__itemSubItems"
41
+ ],
42
+ [
43
+ "footer",
44
+ "app-navigation__footer"
45
+ ]
46
+ ]
47
+ const appNavigationSlotFns = /* @__PURE__ */ appNavigationSlotNames.map(([slotName, slotKey]) => [slotName, createRecipe(slotKey, appNavigationDefaultVariants, getSlotCompoundVariant(appNavigationCompoundVariants, slotName))])
48
+
49
+ const appNavigationFn = memo((props = {}) => {
50
+ return Object.fromEntries(appNavigationSlotFns.map(([slotName, slotFn]) => [slotName, slotFn.recipeFn(props)]))
51
+ })
52
+
53
+ const appNavigationVariantKeys = [
54
+ "variant"
55
+ ]
56
+ const getVariantProps = (variants) => ({ ...appNavigationDefaultVariants, ...compact(variants) })
57
+
58
+ export const appNavigation = /* @__PURE__ */ Object.assign(appNavigationFn, {
59
+ __recipe__: false,
60
+ __name__: 'appNavigation',
61
+ raw: (props) => props,
62
+ variantKeys: appNavigationVariantKeys,
63
+ variantMap: {
64
+ "variant": [
65
+ "prod",
66
+ "staging",
67
+ "dev"
68
+ ]
69
+ },
70
+ splitVariantProps(props) {
71
+ return splitProps(props, appNavigationVariantKeys)
72
+ },
73
+ getVariantProps
74
+ })
package/recipes/icon.d.ts CHANGED
@@ -6,7 +6,7 @@ interface IconVariant {
6
6
  /**
7
7
  * @default "md"
8
8
  */
9
- size: "md"
9
+ size: "sm" | "md"
10
10
  }
11
11
 
12
12
  type IconVariantMap = {
package/recipes/icon.mjs CHANGED
@@ -7,6 +7,7 @@ const iconFn = /* @__PURE__ */ createRecipe('icon', {
7
7
 
8
8
  const iconVariantMap = {
9
9
  "size": [
10
+ "sm",
10
11
  "md"
11
12
  ]
12
13
  }
@@ -41,4 +41,5 @@ export * from './switch-card';
41
41
  export * from './radio-card-group';
42
42
  export * from './checkbox-card';
43
43
  export * from './combobox';
44
- export * from './collapsible';
44
+ export * from './collapsible';
45
+ export * from './app-navigation';
package/recipes/index.mjs CHANGED
@@ -40,4 +40,5 @@ export * from './switch-card.mjs';
40
40
  export * from './radio-card-group.mjs';
41
41
  export * from './checkbox-card.mjs';
42
42
  export * from './combobox.mjs';
43
- export * from './collapsible.mjs';
43
+ export * from './collapsible.mjs';
44
+ export * from './app-navigation.mjs';