@svadmin/surface 0.9.0 → 0.10.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/README.md +9 -3
- package/STYLING.md +4 -2
- package/compatibility.json +18 -7
- package/dist/agent-contract.d.ts +1 -1
- package/dist/agent-contract.js +5 -2
- package/dist/builtin-schemas.js +1 -1
- package/dist/business-data.d.ts +16 -0
- package/dist/business-data.js +42 -0
- package/dist/business-definitions.d.ts +28 -0
- package/dist/business-definitions.js +53 -0
- package/dist/business.d.ts +3 -0
- package/dist/business.js +17 -0
- package/dist/components/ActivityFeedWidget.svelte +34 -0
- package/dist/components/ActivityFeedWidget.svelte.d.ts +4 -0
- package/dist/components/MetricWidget.svelte +2 -1
- package/dist/components/MetricWidget.svelte.d.ts +1 -0
- package/dist/components/ResourceDetailWidget.svelte +56 -0
- package/dist/components/ResourceDetailWidget.svelte.d.ts +4 -0
- package/dist/components/ResourceFormBody.svelte +1 -1
- package/dist/components/ResourceTableWidget.svelte +2 -1
- package/dist/components/ResourceTableWidget.svelte.d.ts +1 -0
- package/dist/components/SurfaceEditPreview.svelte +1 -1
- package/dist/components/SurfaceRenderer.svelte +2 -1
- package/dist/components/SurfaceRenderer.svelte.d.ts +1 -0
- package/dist/design-contract.d.ts +2 -0
- package/dist/design-contract.js +2 -0
- package/dist/localization.d.ts +11 -1
- package/dist/localization.js +20 -0
- package/dist/recipes.d.ts +20 -0
- package/dist/recipes.js +20 -0
- package/dist/styles/{editor.generated.js → editor.js} +1 -1
- package/dist/styles.css +41 -1260
- package/dist/types.d.ts +1 -1
- package/dist/validation.js +12 -6
- package/dist/workflows/catalog.js +1 -1
- package/package.json +15 -8
- package/dist/styled-system/css/conditions.js +0 -36
- package/dist/styled-system/css/css.d.ts +0 -22
- package/dist/styled-system/css/css.js +0 -45
- package/dist/styled-system/css/cva.d.ts +0 -6
- package/dist/styled-system/css/cva.js +0 -87
- package/dist/styled-system/css/cx.d.ts +0 -5
- package/dist/styled-system/css/cx.js +0 -15
- package/dist/styled-system/css/index.d.ts +0 -5
- package/dist/styled-system/css/index.js +0 -4
- package/dist/styled-system/css/sva.d.ts +0 -4
- package/dist/styled-system/css/sva.js +0 -46
- package/dist/styled-system/design-contract.d.ts +0 -13
- package/dist/styled-system/design-contract.js +0 -11
- package/dist/styled-system/helpers.js +0 -316
- package/dist/styled-system/patterns/aspect-ratio.d.ts +0 -20
- package/dist/styled-system/patterns/aspect-ratio.js +0 -38
- package/dist/styled-system/patterns/bleed.d.ts +0 -21
- package/dist/styled-system/patterns/bleed.js +0 -24
- package/dist/styled-system/patterns/box.d.ts +0 -20
- package/dist/styled-system/patterns/box.js +0 -15
- package/dist/styled-system/patterns/center.d.ts +0 -20
- package/dist/styled-system/patterns/center.js +0 -21
- package/dist/styled-system/patterns/circle.d.ts +0 -20
- package/dist/styled-system/patterns/circle.js +0 -25
- package/dist/styled-system/patterns/container.d.ts +0 -20
- package/dist/styled-system/patterns/container.js +0 -21
- package/dist/styled-system/patterns/cq.d.ts +0 -21
- package/dist/styled-system/patterns/cq.js +0 -21
- package/dist/styled-system/patterns/divider.d.ts +0 -22
- package/dist/styled-system/patterns/divider.js +0 -25
- package/dist/styled-system/patterns/flex.d.ts +0 -26
- package/dist/styled-system/patterns/flex.js +0 -26
- package/dist/styled-system/patterns/float.d.ts +0 -23
- package/dist/styled-system/patterns/float.js +0 -52
- package/dist/styled-system/patterns/grid-item.d.ts +0 -25
- package/dist/styled-system/patterns/grid-item.js +0 -25
- package/dist/styled-system/patterns/grid.d.ts +0 -24
- package/dist/styled-system/patterns/grid.js +0 -27
- package/dist/styled-system/patterns/hstack.d.ts +0 -21
- package/dist/styled-system/patterns/hstack.js +0 -24
- package/dist/styled-system/patterns/index.d.ts +0 -21
- package/dist/styled-system/patterns/index.js +0 -20
- package/dist/styled-system/patterns/link-overlay.d.ts +0 -20
- package/dist/styled-system/patterns/link-overlay.js +0 -24
- package/dist/styled-system/patterns/spacer.d.ts +0 -20
- package/dist/styled-system/patterns/spacer.js +0 -25
- package/dist/styled-system/patterns/square.d.ts +0 -20
- package/dist/styled-system/patterns/square.js +0 -24
- package/dist/styled-system/patterns/stack.d.ts +0 -23
- package/dist/styled-system/patterns/stack.js +0 -24
- package/dist/styled-system/patterns/visually-hidden.d.ts +0 -20
- package/dist/styled-system/patterns/visually-hidden.js +0 -18
- package/dist/styled-system/patterns/vstack.d.ts +0 -21
- package/dist/styled-system/patterns/vstack.js +0 -24
- package/dist/styled-system/patterns/wrap.d.ts +0 -24
- package/dist/styled-system/patterns/wrap.js +0 -25
- package/dist/styled-system/recipes/content-header.d.ts +0 -31
- package/dist/styled-system/recipes/content-header.js +0 -65
- package/dist/styled-system/recipes/content-page.d.ts +0 -34
- package/dist/styled-system/recipes/content-page.js +0 -43
- package/dist/styled-system/recipes/create-recipe.js +0 -82
- package/dist/styled-system/recipes/index.d.ts +0 -17
- package/dist/styled-system/recipes/index.js +0 -16
- package/dist/styled-system/recipes/metric-block.d.ts +0 -34
- package/dist/styled-system/recipes/metric-block.js +0 -76
- package/dist/styled-system/recipes/product-list.d.ts +0 -31
- package/dist/styled-system/recipes/product-list.js +0 -73
- package/dist/styled-system/recipes/product-section.d.ts +0 -31
- package/dist/styled-system/recipes/product-section.js +0 -49
- package/dist/styled-system/recipes/product-settings-row.d.ts +0 -34
- package/dist/styled-system/recipes/product-settings-row.js +0 -58
- package/dist/styled-system/recipes/product-settings.d.ts +0 -31
- package/dist/styled-system/recipes/product-settings.js +0 -57
- package/dist/styled-system/recipes/product-status.d.ts +0 -34
- package/dist/styled-system/recipes/product-status.js +0 -45
- package/dist/styled-system/recipes/product-toolbar.d.ts +0 -31
- package/dist/styled-system/recipes/product-toolbar.js +0 -41
- package/dist/styled-system/recipes/product-workspace.d.ts +0 -34
- package/dist/styled-system/recipes/product-workspace.js +0 -58
- package/dist/styled-system/recipes/surface-metric.d.ts +0 -38
- package/dist/styled-system/recipes/surface-metric.js +0 -63
- package/dist/styled-system/recipes/surface-table.d.ts +0 -34
- package/dist/styled-system/recipes/surface-table.js +0 -62
- package/dist/styled-system/recipes/ui-badge.d.ts +0 -31
- package/dist/styled-system/recipes/ui-badge.js +0 -38
- package/dist/styled-system/recipes/ui-button.d.ts +0 -32
- package/dist/styled-system/recipes/ui-button.js +0 -43
- package/dist/styled-system/recipes/ui-input.d.ts +0 -31
- package/dist/styled-system/recipes/ui-input.js +0 -49
- package/dist/styled-system/recipes/ui-textarea.d.ts +0 -31
- package/dist/styled-system/recipes/ui-textarea.js +0 -24
- package/dist/styled-system/styles.css +0 -1257
- package/dist/styled-system/tokens/index.d.ts +0 -9
- package/dist/styled-system/tokens/index.js +0 -268
- package/dist/styled-system/tokens/tokens.d.ts +0 -36
- package/dist/styled-system/types/composition.d.ts +0 -227
- package/dist/styled-system/types/conditions.d.ts +0 -236
- package/dist/styled-system/types/csstype.d.ts +0 -22570
- package/dist/styled-system/types/index.d.ts +0 -6
- package/dist/styled-system/types/parts.d.ts +0 -8
- package/dist/styled-system/types/pattern.d.ts +0 -78
- package/dist/styled-system/types/prop-type.d.ts +0 -223
- package/dist/styled-system/types/recipe.d.ts +0 -181
- package/dist/styled-system/types/selectors.d.ts +0 -59
- package/dist/styled-system/types/static-css.d.ts +0 -56
- package/dist/styled-system/types/style-props.d.ts +0 -8088
- package/dist/styled-system/types/system-types.d.ts +0 -151
- /package/dist/styles/{editor.generated.d.ts → editor.d.ts} +0 -0
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import { getPatternStyles, patternFns } from '../helpers.js';
|
|
2
|
-
import { css } from '../css/index.js';
|
|
3
|
-
|
|
4
|
-
const wrapConfig = {
|
|
5
|
-
transform(props) {
|
|
6
|
-
const { columnGap, rowGap, gap = columnGap || rowGap ? void 0 : "8px", align, justify, ...rest } = props;
|
|
7
|
-
return {
|
|
8
|
-
display: "flex",
|
|
9
|
-
flexWrap: "wrap",
|
|
10
|
-
alignItems: align,
|
|
11
|
-
justifyContent: justify,
|
|
12
|
-
gap,
|
|
13
|
-
columnGap,
|
|
14
|
-
rowGap,
|
|
15
|
-
...rest
|
|
16
|
-
};
|
|
17
|
-
}}
|
|
18
|
-
|
|
19
|
-
export const getWrapStyle = (styles = {}) => {
|
|
20
|
-
const _styles = getPatternStyles(wrapConfig, styles)
|
|
21
|
-
return wrapConfig.transform(_styles, patternFns)
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
export const wrap = (styles) => css(getWrapStyle(styles))
|
|
25
|
-
wrap.raw = getWrapStyle
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import type { ConditionalValue } from '../types/index';
|
|
3
|
-
import type { DistributiveOmit, Pretty } from '../types/system-types';
|
|
4
|
-
|
|
5
|
-
interface ContentHeaderVariant {
|
|
6
|
-
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
type ContentHeaderVariantMap = {
|
|
10
|
-
[key in keyof ContentHeaderVariant]: Array<ContentHeaderVariant[key]>
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
type ContentHeaderSlot = "root" | "breadcrumbs" | "currentCrumb" | "row" | "heading" | "eyebrow" | "title" | "description" | "actions"
|
|
14
|
-
|
|
15
|
-
export type ContentHeaderVariantProps = {
|
|
16
|
-
[key in keyof ContentHeaderVariant]?: ConditionalValue<ContentHeaderVariant[key]> | undefined
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
export interface ContentHeaderRecipe {
|
|
20
|
-
__slot: ContentHeaderSlot
|
|
21
|
-
__type: ContentHeaderVariantProps
|
|
22
|
-
(props?: ContentHeaderVariantProps): Pretty<Record<ContentHeaderSlot, string>>
|
|
23
|
-
raw: (props?: ContentHeaderVariantProps) => ContentHeaderVariantProps
|
|
24
|
-
variantMap: ContentHeaderVariantMap
|
|
25
|
-
variantKeys: Array<keyof ContentHeaderVariant>
|
|
26
|
-
splitVariantProps<Props extends ContentHeaderVariantProps>(props: Props): [ContentHeaderVariantProps, Pretty<DistributiveOmit<Props, keyof ContentHeaderVariantProps>>]
|
|
27
|
-
getVariantProps: (props?: ContentHeaderVariantProps) => ContentHeaderVariantProps
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
export declare const contentHeader: ContentHeaderRecipe
|
|
@@ -1,65 +0,0 @@
|
|
|
1
|
-
import { compact, getSlotCompoundVariant, memo, splitProps } from '../helpers.js';
|
|
2
|
-
import { createRecipe } from './create-recipe.js';
|
|
3
|
-
|
|
4
|
-
const contentHeaderDefaultVariants = {}
|
|
5
|
-
const contentHeaderCompoundVariants = []
|
|
6
|
-
|
|
7
|
-
const contentHeaderSlotNames = [
|
|
8
|
-
[
|
|
9
|
-
"root",
|
|
10
|
-
"content-header__root"
|
|
11
|
-
],
|
|
12
|
-
[
|
|
13
|
-
"breadcrumbs",
|
|
14
|
-
"content-header__breadcrumbs"
|
|
15
|
-
],
|
|
16
|
-
[
|
|
17
|
-
"currentCrumb",
|
|
18
|
-
"content-header__currentCrumb"
|
|
19
|
-
],
|
|
20
|
-
[
|
|
21
|
-
"row",
|
|
22
|
-
"content-header__row"
|
|
23
|
-
],
|
|
24
|
-
[
|
|
25
|
-
"heading",
|
|
26
|
-
"content-header__heading"
|
|
27
|
-
],
|
|
28
|
-
[
|
|
29
|
-
"eyebrow",
|
|
30
|
-
"content-header__eyebrow"
|
|
31
|
-
],
|
|
32
|
-
[
|
|
33
|
-
"title",
|
|
34
|
-
"content-header__title"
|
|
35
|
-
],
|
|
36
|
-
[
|
|
37
|
-
"description",
|
|
38
|
-
"content-header__description"
|
|
39
|
-
],
|
|
40
|
-
[
|
|
41
|
-
"actions",
|
|
42
|
-
"content-header__actions"
|
|
43
|
-
]
|
|
44
|
-
]
|
|
45
|
-
const contentHeaderSlotFns = /* @__PURE__ */ contentHeaderSlotNames.map(([slotName, slotKey]) => [slotName, createRecipe(slotKey, contentHeaderDefaultVariants, getSlotCompoundVariant(contentHeaderCompoundVariants, slotName))])
|
|
46
|
-
|
|
47
|
-
const contentHeaderFn = memo((props = {}) => {
|
|
48
|
-
return Object.fromEntries(contentHeaderSlotFns.map(([slotName, slotFn]) => [slotName, slotFn.recipeFn(props)]))
|
|
49
|
-
})
|
|
50
|
-
|
|
51
|
-
const contentHeaderVariantKeys = []
|
|
52
|
-
const getVariantProps = (variants) => ({ ...contentHeaderDefaultVariants, ...compact(variants) })
|
|
53
|
-
|
|
54
|
-
export const contentHeader = /* @__PURE__ */ Object.assign(contentHeaderFn, {
|
|
55
|
-
__recipe__: false,
|
|
56
|
-
__name__: 'contentHeader',
|
|
57
|
-
raw: (props) => props,
|
|
58
|
-
classNameMap: {},
|
|
59
|
-
variantKeys: contentHeaderVariantKeys,
|
|
60
|
-
variantMap: {},
|
|
61
|
-
splitVariantProps(props) {
|
|
62
|
-
return splitProps(props, contentHeaderVariantKeys)
|
|
63
|
-
},
|
|
64
|
-
getVariantProps
|
|
65
|
-
})
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import type { ConditionalValue } from '../types/index';
|
|
3
|
-
import type { DistributiveOmit, Pretty } from '../types/system-types';
|
|
4
|
-
|
|
5
|
-
interface ContentPageVariant {
|
|
6
|
-
/**
|
|
7
|
-
* @default "default"
|
|
8
|
-
*/
|
|
9
|
-
width: "narrow" | "default" | "wide"
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
type ContentPageVariantMap = {
|
|
13
|
-
[key in keyof ContentPageVariant]: Array<ContentPageVariant[key]>
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
type ContentPageSlot = "root"
|
|
17
|
-
|
|
18
|
-
export type ContentPageVariantProps = {
|
|
19
|
-
[key in keyof ContentPageVariant]?: ConditionalValue<ContentPageVariant[key]> | undefined
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
export interface ContentPageRecipe {
|
|
23
|
-
__slot: ContentPageSlot
|
|
24
|
-
__type: ContentPageVariantProps
|
|
25
|
-
(props?: ContentPageVariantProps): Pretty<Record<ContentPageSlot, string>>
|
|
26
|
-
raw: (props?: ContentPageVariantProps) => ContentPageVariantProps
|
|
27
|
-
variantMap: ContentPageVariantMap
|
|
28
|
-
variantKeys: Array<keyof ContentPageVariant>
|
|
29
|
-
splitVariantProps<Props extends ContentPageVariantProps>(props: Props): [ContentPageVariantProps, Pretty<DistributiveOmit<Props, keyof ContentPageVariantProps>>]
|
|
30
|
-
getVariantProps: (props?: ContentPageVariantProps) => ContentPageVariantProps
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
export declare const contentPage: ContentPageRecipe
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
import { compact, getSlotCompoundVariant, memo, splitProps } from '../helpers.js';
|
|
2
|
-
import { createRecipe } from './create-recipe.js';
|
|
3
|
-
|
|
4
|
-
const contentPageDefaultVariants = {
|
|
5
|
-
"width": "default"
|
|
6
|
-
}
|
|
7
|
-
const contentPageCompoundVariants = []
|
|
8
|
-
|
|
9
|
-
const contentPageSlotNames = [
|
|
10
|
-
[
|
|
11
|
-
"root",
|
|
12
|
-
"content-page__root"
|
|
13
|
-
]
|
|
14
|
-
]
|
|
15
|
-
const contentPageSlotFns = /* @__PURE__ */ contentPageSlotNames.map(([slotName, slotKey]) => [slotName, createRecipe(slotKey, contentPageDefaultVariants, getSlotCompoundVariant(contentPageCompoundVariants, slotName))])
|
|
16
|
-
|
|
17
|
-
const contentPageFn = memo((props = {}) => {
|
|
18
|
-
return Object.fromEntries(contentPageSlotFns.map(([slotName, slotFn]) => [slotName, slotFn.recipeFn(props)]))
|
|
19
|
-
})
|
|
20
|
-
|
|
21
|
-
const contentPageVariantKeys = [
|
|
22
|
-
"width"
|
|
23
|
-
]
|
|
24
|
-
const getVariantProps = (variants) => ({ ...contentPageDefaultVariants, ...compact(variants) })
|
|
25
|
-
|
|
26
|
-
export const contentPage = /* @__PURE__ */ Object.assign(contentPageFn, {
|
|
27
|
-
__recipe__: false,
|
|
28
|
-
__name__: 'contentPage',
|
|
29
|
-
raw: (props) => props,
|
|
30
|
-
classNameMap: {},
|
|
31
|
-
variantKeys: contentPageVariantKeys,
|
|
32
|
-
variantMap: {
|
|
33
|
-
"width": [
|
|
34
|
-
"narrow",
|
|
35
|
-
"default",
|
|
36
|
-
"wide"
|
|
37
|
-
]
|
|
38
|
-
},
|
|
39
|
-
splitVariantProps(props) {
|
|
40
|
-
return splitProps(props, contentPageVariantKeys)
|
|
41
|
-
},
|
|
42
|
-
getVariantProps
|
|
43
|
-
})
|
|
@@ -1,82 +0,0 @@
|
|
|
1
|
-
import { finalizeConditions, sortConditions } from '../css/conditions.js';
|
|
2
|
-
import { css } from '../css/css.js';
|
|
3
|
-
import { assertCompoundVariant, getCompoundVariantCss } from '../css/cva.js';
|
|
4
|
-
import { cx } from '../css/cx.js';
|
|
5
|
-
import { compact, createCss, splitProps, uniq, withoutSpace } from '../helpers.js';
|
|
6
|
-
|
|
7
|
-
export const createRecipe = (name, defaultVariants, compoundVariants) => {
|
|
8
|
-
const getVariantProps = (variants) => {
|
|
9
|
-
return {
|
|
10
|
-
[name]: '__ignore__',
|
|
11
|
-
...defaultVariants,
|
|
12
|
-
...compact(variants),
|
|
13
|
-
};
|
|
14
|
-
};
|
|
15
|
-
|
|
16
|
-
const recipeFn = (variants, withCompoundVariants = true) => {
|
|
17
|
-
const transform = (prop, value) => {
|
|
18
|
-
assertCompoundVariant(name, compoundVariants, variants, prop)
|
|
19
|
-
|
|
20
|
-
if (value === '__ignore__') {
|
|
21
|
-
return { className: name }
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
value = withoutSpace(value)
|
|
25
|
-
return { className: `${name}--${prop}_${value}` }
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
const recipeCss = createCss({
|
|
29
|
-
|
|
30
|
-
conditions: {
|
|
31
|
-
shift: sortConditions,
|
|
32
|
-
finalize: finalizeConditions,
|
|
33
|
-
breakpoints: { keys: ["base"] }
|
|
34
|
-
},
|
|
35
|
-
utility: {
|
|
36
|
-
prefix: "svadmin",
|
|
37
|
-
toHash: (path, hashFn) => hashFn(path.join(":")),
|
|
38
|
-
transform,
|
|
39
|
-
}
|
|
40
|
-
})
|
|
41
|
-
|
|
42
|
-
const recipeStyles = getVariantProps(variants)
|
|
43
|
-
|
|
44
|
-
if (withCompoundVariants) {
|
|
45
|
-
const compoundVariantStyles = getCompoundVariantCss(compoundVariants, recipeStyles)
|
|
46
|
-
return cx(recipeCss(recipeStyles), css(compoundVariantStyles))
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
return recipeCss(recipeStyles)
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
return {
|
|
53
|
-
recipeFn,
|
|
54
|
-
getVariantProps,
|
|
55
|
-
__getCompoundVariantCss__: (variants) => {
|
|
56
|
-
return getCompoundVariantCss(compoundVariants, getVariantProps(variants));
|
|
57
|
-
},
|
|
58
|
-
}
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
export const mergeRecipes = (recipeA, recipeB) => {
|
|
62
|
-
if (recipeA && !recipeB) return recipeA
|
|
63
|
-
if (!recipeA && recipeB) return recipeB
|
|
64
|
-
|
|
65
|
-
const recipeFn = (...args) => cx(recipeA(...args), recipeB(...args))
|
|
66
|
-
const variantKeys = uniq(recipeA.variantKeys, recipeB.variantKeys)
|
|
67
|
-
const variantMap = variantKeys.reduce((acc, key) => {
|
|
68
|
-
acc[key] = uniq(recipeA.variantMap[key], recipeB.variantMap[key])
|
|
69
|
-
return acc
|
|
70
|
-
}, {})
|
|
71
|
-
|
|
72
|
-
return Object.assign(recipeFn, {
|
|
73
|
-
__recipe__: true,
|
|
74
|
-
__name__: `${recipeA.__name__} ${recipeB.__name__}`,
|
|
75
|
-
raw: (props) => props,
|
|
76
|
-
variantKeys,
|
|
77
|
-
variantMap,
|
|
78
|
-
splitVariantProps(props) {
|
|
79
|
-
return splitProps(props, variantKeys)
|
|
80
|
-
},
|
|
81
|
-
})
|
|
82
|
-
}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
export * from './ui-button';
|
|
3
|
-
export * from './ui-badge';
|
|
4
|
-
export * from './ui-textarea';
|
|
5
|
-
export * from './surface-metric';
|
|
6
|
-
export * from './surface-table';
|
|
7
|
-
export * from './ui-input';
|
|
8
|
-
export * from './product-section';
|
|
9
|
-
export * from './product-toolbar';
|
|
10
|
-
export * from './product-workspace';
|
|
11
|
-
export * from './product-settings';
|
|
12
|
-
export * from './product-settings-row';
|
|
13
|
-
export * from './product-list';
|
|
14
|
-
export * from './product-status';
|
|
15
|
-
export * from './content-page';
|
|
16
|
-
export * from './content-header';
|
|
17
|
-
export * from './metric-block';
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
export * from './ui-button.js';
|
|
2
|
-
export * from './ui-badge.js';
|
|
3
|
-
export * from './ui-textarea.js';
|
|
4
|
-
export * from './surface-metric.js';
|
|
5
|
-
export * from './surface-table.js';
|
|
6
|
-
export * from './ui-input.js';
|
|
7
|
-
export * from './product-section.js';
|
|
8
|
-
export * from './product-toolbar.js';
|
|
9
|
-
export * from './product-workspace.js';
|
|
10
|
-
export * from './product-settings.js';
|
|
11
|
-
export * from './product-settings-row.js';
|
|
12
|
-
export * from './product-list.js';
|
|
13
|
-
export * from './product-status.js';
|
|
14
|
-
export * from './content-page.js';
|
|
15
|
-
export * from './content-header.js';
|
|
16
|
-
export * from './metric-block.js';
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import type { ConditionalValue } from '../types/index';
|
|
3
|
-
import type { DistributiveOmit, Pretty } from '../types/system-types';
|
|
4
|
-
|
|
5
|
-
interface MetricBlockVariant {
|
|
6
|
-
/**
|
|
7
|
-
* @default "neutral"
|
|
8
|
-
*/
|
|
9
|
-
trendTone: "positive" | "negative" | "warning" | "neutral"
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
type MetricBlockVariantMap = {
|
|
13
|
-
[key in keyof MetricBlockVariant]: Array<MetricBlockVariant[key]>
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
type MetricBlockSlot = "root" | "header" | "label" | "icon" | "skeleton" | "value" | "meta" | "trend" | "detail"
|
|
17
|
-
|
|
18
|
-
export type MetricBlockVariantProps = {
|
|
19
|
-
[key in keyof MetricBlockVariant]?: ConditionalValue<MetricBlockVariant[key]> | undefined
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
export interface MetricBlockRecipe {
|
|
23
|
-
__slot: MetricBlockSlot
|
|
24
|
-
__type: MetricBlockVariantProps
|
|
25
|
-
(props?: MetricBlockVariantProps): Pretty<Record<MetricBlockSlot, string>>
|
|
26
|
-
raw: (props?: MetricBlockVariantProps) => MetricBlockVariantProps
|
|
27
|
-
variantMap: MetricBlockVariantMap
|
|
28
|
-
variantKeys: Array<keyof MetricBlockVariant>
|
|
29
|
-
splitVariantProps<Props extends MetricBlockVariantProps>(props: Props): [MetricBlockVariantProps, Pretty<DistributiveOmit<Props, keyof MetricBlockVariantProps>>]
|
|
30
|
-
getVariantProps: (props?: MetricBlockVariantProps) => MetricBlockVariantProps
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
export declare const metricBlock: MetricBlockRecipe
|
|
@@ -1,76 +0,0 @@
|
|
|
1
|
-
import { compact, getSlotCompoundVariant, memo, splitProps } from '../helpers.js';
|
|
2
|
-
import { createRecipe } from './create-recipe.js';
|
|
3
|
-
|
|
4
|
-
const metricBlockDefaultVariants = {
|
|
5
|
-
"trendTone": "neutral"
|
|
6
|
-
}
|
|
7
|
-
const metricBlockCompoundVariants = []
|
|
8
|
-
|
|
9
|
-
const metricBlockSlotNames = [
|
|
10
|
-
[
|
|
11
|
-
"root",
|
|
12
|
-
"metric-block__root"
|
|
13
|
-
],
|
|
14
|
-
[
|
|
15
|
-
"header",
|
|
16
|
-
"metric-block__header"
|
|
17
|
-
],
|
|
18
|
-
[
|
|
19
|
-
"label",
|
|
20
|
-
"metric-block__label"
|
|
21
|
-
],
|
|
22
|
-
[
|
|
23
|
-
"icon",
|
|
24
|
-
"metric-block__icon"
|
|
25
|
-
],
|
|
26
|
-
[
|
|
27
|
-
"skeleton",
|
|
28
|
-
"metric-block__skeleton"
|
|
29
|
-
],
|
|
30
|
-
[
|
|
31
|
-
"value",
|
|
32
|
-
"metric-block__value"
|
|
33
|
-
],
|
|
34
|
-
[
|
|
35
|
-
"meta",
|
|
36
|
-
"metric-block__meta"
|
|
37
|
-
],
|
|
38
|
-
[
|
|
39
|
-
"trend",
|
|
40
|
-
"metric-block__trend"
|
|
41
|
-
],
|
|
42
|
-
[
|
|
43
|
-
"detail",
|
|
44
|
-
"metric-block__detail"
|
|
45
|
-
]
|
|
46
|
-
]
|
|
47
|
-
const metricBlockSlotFns = /* @__PURE__ */ metricBlockSlotNames.map(([slotName, slotKey]) => [slotName, createRecipe(slotKey, metricBlockDefaultVariants, getSlotCompoundVariant(metricBlockCompoundVariants, slotName))])
|
|
48
|
-
|
|
49
|
-
const metricBlockFn = memo((props = {}) => {
|
|
50
|
-
return Object.fromEntries(metricBlockSlotFns.map(([slotName, slotFn]) => [slotName, slotFn.recipeFn(props)]))
|
|
51
|
-
})
|
|
52
|
-
|
|
53
|
-
const metricBlockVariantKeys = [
|
|
54
|
-
"trendTone"
|
|
55
|
-
]
|
|
56
|
-
const getVariantProps = (variants) => ({ ...metricBlockDefaultVariants, ...compact(variants) })
|
|
57
|
-
|
|
58
|
-
export const metricBlock = /* @__PURE__ */ Object.assign(metricBlockFn, {
|
|
59
|
-
__recipe__: false,
|
|
60
|
-
__name__: 'metricBlock',
|
|
61
|
-
raw: (props) => props,
|
|
62
|
-
classNameMap: {},
|
|
63
|
-
variantKeys: metricBlockVariantKeys,
|
|
64
|
-
variantMap: {
|
|
65
|
-
"trendTone": [
|
|
66
|
-
"positive",
|
|
67
|
-
"negative",
|
|
68
|
-
"warning",
|
|
69
|
-
"neutral"
|
|
70
|
-
]
|
|
71
|
-
},
|
|
72
|
-
splitVariantProps(props) {
|
|
73
|
-
return splitProps(props, metricBlockVariantKeys)
|
|
74
|
-
},
|
|
75
|
-
getVariantProps
|
|
76
|
-
})
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import type { ConditionalValue } from '../types/index';
|
|
3
|
-
import type { DistributiveOmit, Pretty } from '../types/system-types';
|
|
4
|
-
|
|
5
|
-
interface ProductListVariant {
|
|
6
|
-
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
type ProductListVariantMap = {
|
|
10
|
-
[key in keyof ProductListVariant]: Array<ProductListVariant[key]>
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
type ProductListSlot = "filters" | "filter" | "filterCount" | "table" | "identity" | "avatar" | "name" | "secondary" | "numeric" | "footer" | "help"
|
|
14
|
-
|
|
15
|
-
export type ProductListVariantProps = {
|
|
16
|
-
[key in keyof ProductListVariant]?: ConditionalValue<ProductListVariant[key]> | undefined
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
export interface ProductListRecipe {
|
|
20
|
-
__slot: ProductListSlot
|
|
21
|
-
__type: ProductListVariantProps
|
|
22
|
-
(props?: ProductListVariantProps): Pretty<Record<ProductListSlot, string>>
|
|
23
|
-
raw: (props?: ProductListVariantProps) => ProductListVariantProps
|
|
24
|
-
variantMap: ProductListVariantMap
|
|
25
|
-
variantKeys: Array<keyof ProductListVariant>
|
|
26
|
-
splitVariantProps<Props extends ProductListVariantProps>(props: Props): [ProductListVariantProps, Pretty<DistributiveOmit<Props, keyof ProductListVariantProps>>]
|
|
27
|
-
getVariantProps: (props?: ProductListVariantProps) => ProductListVariantProps
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
export declare const productList: ProductListRecipe
|
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
import { compact, getSlotCompoundVariant, memo, splitProps } from '../helpers.js';
|
|
2
|
-
import { createRecipe } from './create-recipe.js';
|
|
3
|
-
|
|
4
|
-
const productListDefaultVariants = {}
|
|
5
|
-
const productListCompoundVariants = []
|
|
6
|
-
|
|
7
|
-
const productListSlotNames = [
|
|
8
|
-
[
|
|
9
|
-
"filters",
|
|
10
|
-
"product-list__filters"
|
|
11
|
-
],
|
|
12
|
-
[
|
|
13
|
-
"filter",
|
|
14
|
-
"product-list__filter"
|
|
15
|
-
],
|
|
16
|
-
[
|
|
17
|
-
"filterCount",
|
|
18
|
-
"product-list__filterCount"
|
|
19
|
-
],
|
|
20
|
-
[
|
|
21
|
-
"table",
|
|
22
|
-
"product-list__table"
|
|
23
|
-
],
|
|
24
|
-
[
|
|
25
|
-
"identity",
|
|
26
|
-
"product-list__identity"
|
|
27
|
-
],
|
|
28
|
-
[
|
|
29
|
-
"avatar",
|
|
30
|
-
"product-list__avatar"
|
|
31
|
-
],
|
|
32
|
-
[
|
|
33
|
-
"name",
|
|
34
|
-
"product-list__name"
|
|
35
|
-
],
|
|
36
|
-
[
|
|
37
|
-
"secondary",
|
|
38
|
-
"product-list__secondary"
|
|
39
|
-
],
|
|
40
|
-
[
|
|
41
|
-
"numeric",
|
|
42
|
-
"product-list__numeric"
|
|
43
|
-
],
|
|
44
|
-
[
|
|
45
|
-
"footer",
|
|
46
|
-
"product-list__footer"
|
|
47
|
-
],
|
|
48
|
-
[
|
|
49
|
-
"help",
|
|
50
|
-
"product-list__help"
|
|
51
|
-
]
|
|
52
|
-
]
|
|
53
|
-
const productListSlotFns = /* @__PURE__ */ productListSlotNames.map(([slotName, slotKey]) => [slotName, createRecipe(slotKey, productListDefaultVariants, getSlotCompoundVariant(productListCompoundVariants, slotName))])
|
|
54
|
-
|
|
55
|
-
const productListFn = memo((props = {}) => {
|
|
56
|
-
return Object.fromEntries(productListSlotFns.map(([slotName, slotFn]) => [slotName, slotFn.recipeFn(props)]))
|
|
57
|
-
})
|
|
58
|
-
|
|
59
|
-
const productListVariantKeys = []
|
|
60
|
-
const getVariantProps = (variants) => ({ ...productListDefaultVariants, ...compact(variants) })
|
|
61
|
-
|
|
62
|
-
export const productList = /* @__PURE__ */ Object.assign(productListFn, {
|
|
63
|
-
__recipe__: false,
|
|
64
|
-
__name__: 'productList',
|
|
65
|
-
raw: (props) => props,
|
|
66
|
-
classNameMap: {},
|
|
67
|
-
variantKeys: productListVariantKeys,
|
|
68
|
-
variantMap: {},
|
|
69
|
-
splitVariantProps(props) {
|
|
70
|
-
return splitProps(props, productListVariantKeys)
|
|
71
|
-
},
|
|
72
|
-
getVariantProps
|
|
73
|
-
})
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import type { ConditionalValue } from '../types/index';
|
|
3
|
-
import type { DistributiveOmit, Pretty } from '../types/system-types';
|
|
4
|
-
|
|
5
|
-
interface ProductSectionVariant {
|
|
6
|
-
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
type ProductSectionVariantMap = {
|
|
10
|
-
[key in keyof ProductSectionVariant]: Array<ProductSectionVariant[key]>
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
type ProductSectionSlot = "root" | "heading" | "title" | "description" | "actions"
|
|
14
|
-
|
|
15
|
-
export type ProductSectionVariantProps = {
|
|
16
|
-
[key in keyof ProductSectionVariant]?: ConditionalValue<ProductSectionVariant[key]> | undefined
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
export interface ProductSectionRecipe {
|
|
20
|
-
__slot: ProductSectionSlot
|
|
21
|
-
__type: ProductSectionVariantProps
|
|
22
|
-
(props?: ProductSectionVariantProps): Pretty<Record<ProductSectionSlot, string>>
|
|
23
|
-
raw: (props?: ProductSectionVariantProps) => ProductSectionVariantProps
|
|
24
|
-
variantMap: ProductSectionVariantMap
|
|
25
|
-
variantKeys: Array<keyof ProductSectionVariant>
|
|
26
|
-
splitVariantProps<Props extends ProductSectionVariantProps>(props: Props): [ProductSectionVariantProps, Pretty<DistributiveOmit<Props, keyof ProductSectionVariantProps>>]
|
|
27
|
-
getVariantProps: (props?: ProductSectionVariantProps) => ProductSectionVariantProps
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
export declare const productSection: ProductSectionRecipe
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
import { compact, getSlotCompoundVariant, memo, splitProps } from '../helpers.js';
|
|
2
|
-
import { createRecipe } from './create-recipe.js';
|
|
3
|
-
|
|
4
|
-
const productSectionDefaultVariants = {}
|
|
5
|
-
const productSectionCompoundVariants = []
|
|
6
|
-
|
|
7
|
-
const productSectionSlotNames = [
|
|
8
|
-
[
|
|
9
|
-
"root",
|
|
10
|
-
"product-section__root"
|
|
11
|
-
],
|
|
12
|
-
[
|
|
13
|
-
"heading",
|
|
14
|
-
"product-section__heading"
|
|
15
|
-
],
|
|
16
|
-
[
|
|
17
|
-
"title",
|
|
18
|
-
"product-section__title"
|
|
19
|
-
],
|
|
20
|
-
[
|
|
21
|
-
"description",
|
|
22
|
-
"product-section__description"
|
|
23
|
-
],
|
|
24
|
-
[
|
|
25
|
-
"actions",
|
|
26
|
-
"product-section__actions"
|
|
27
|
-
]
|
|
28
|
-
]
|
|
29
|
-
const productSectionSlotFns = /* @__PURE__ */ productSectionSlotNames.map(([slotName, slotKey]) => [slotName, createRecipe(slotKey, productSectionDefaultVariants, getSlotCompoundVariant(productSectionCompoundVariants, slotName))])
|
|
30
|
-
|
|
31
|
-
const productSectionFn = memo((props = {}) => {
|
|
32
|
-
return Object.fromEntries(productSectionSlotFns.map(([slotName, slotFn]) => [slotName, slotFn.recipeFn(props)]))
|
|
33
|
-
})
|
|
34
|
-
|
|
35
|
-
const productSectionVariantKeys = []
|
|
36
|
-
const getVariantProps = (variants) => ({ ...productSectionDefaultVariants, ...compact(variants) })
|
|
37
|
-
|
|
38
|
-
export const productSection = /* @__PURE__ */ Object.assign(productSectionFn, {
|
|
39
|
-
__recipe__: false,
|
|
40
|
-
__name__: 'productSection',
|
|
41
|
-
raw: (props) => props,
|
|
42
|
-
classNameMap: {},
|
|
43
|
-
variantKeys: productSectionVariantKeys,
|
|
44
|
-
variantMap: {},
|
|
45
|
-
splitVariantProps(props) {
|
|
46
|
-
return splitProps(props, productSectionVariantKeys)
|
|
47
|
-
},
|
|
48
|
-
getVariantProps
|
|
49
|
-
})
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import type { ConditionalValue } from '../types/index';
|
|
3
|
-
import type { DistributiveOmit, Pretty } from '../types/system-types';
|
|
4
|
-
|
|
5
|
-
interface ProductSettingsRowVariant {
|
|
6
|
-
/**
|
|
7
|
-
* @default false
|
|
8
|
-
*/
|
|
9
|
-
separated: boolean
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
type ProductSettingsRowVariantMap = {
|
|
13
|
-
[key in keyof ProductSettingsRowVariant]: Array<ProductSettingsRowVariant[key]>
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
type ProductSettingsRowSlot = "root" | "heading" | "label" | "description" | "control"
|
|
17
|
-
|
|
18
|
-
export type ProductSettingsRowVariantProps = {
|
|
19
|
-
[key in keyof ProductSettingsRowVariant]?: ConditionalValue<ProductSettingsRowVariant[key]> | undefined
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
export interface ProductSettingsRowRecipe {
|
|
23
|
-
__slot: ProductSettingsRowSlot
|
|
24
|
-
__type: ProductSettingsRowVariantProps
|
|
25
|
-
(props?: ProductSettingsRowVariantProps): Pretty<Record<ProductSettingsRowSlot, string>>
|
|
26
|
-
raw: (props?: ProductSettingsRowVariantProps) => ProductSettingsRowVariantProps
|
|
27
|
-
variantMap: ProductSettingsRowVariantMap
|
|
28
|
-
variantKeys: Array<keyof ProductSettingsRowVariant>
|
|
29
|
-
splitVariantProps<Props extends ProductSettingsRowVariantProps>(props: Props): [ProductSettingsRowVariantProps, Pretty<DistributiveOmit<Props, keyof ProductSettingsRowVariantProps>>]
|
|
30
|
-
getVariantProps: (props?: ProductSettingsRowVariantProps) => ProductSettingsRowVariantProps
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
export declare const productSettingsRow: ProductSettingsRowRecipe
|