@pandacss/studio 0.13.0 → 0.13.1
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 +8 -8
- package/styled-system/css/conditions.mjs +16 -18
- package/styled-system/css/css.d.ts +1 -1
- package/styled-system/css/css.mjs +12 -11
- package/styled-system/css/cva.d.ts +2 -2
- package/styled-system/css/cva.mjs +2 -2
- package/styled-system/css/cx.mjs +1 -1
- package/styled-system/css/index.d.ts +4 -4
- package/styled-system/css/index.mjs +4 -4
- package/styled-system/css/sva.d.ts +1 -1
- package/styled-system/css/sva.mjs +10 -8
- package/styled-system/global.css +30 -33
- package/styled-system/helpers.mjs +165 -154
- package/styled-system/jsx/aspect-ratio.d.ts +3 -3
- package/styled-system/jsx/aspect-ratio.mjs +5 -5
- package/styled-system/jsx/bleed.d.ts +3 -3
- package/styled-system/jsx/bleed.mjs +5 -5
- package/styled-system/jsx/box.d.ts +3 -3
- package/styled-system/jsx/box.mjs +4 -4
- package/styled-system/jsx/center.d.ts +3 -3
- package/styled-system/jsx/center.mjs +5 -5
- package/styled-system/jsx/circle.d.ts +3 -3
- package/styled-system/jsx/circle.mjs +5 -5
- package/styled-system/jsx/container.d.ts +3 -3
- package/styled-system/jsx/container.mjs +4 -4
- package/styled-system/jsx/divider.d.ts +3 -3
- package/styled-system/jsx/divider.mjs +5 -5
- package/styled-system/jsx/factory.d.ts +1 -1
- package/styled-system/jsx/factory.mjs +19 -18
- package/styled-system/jsx/flex.d.ts +3 -3
- package/styled-system/jsx/flex.mjs +5 -5
- package/styled-system/jsx/float.d.ts +3 -3
- package/styled-system/jsx/float.mjs +5 -5
- package/styled-system/jsx/grid-item.d.ts +3 -3
- package/styled-system/jsx/grid-item.mjs +5 -5
- package/styled-system/jsx/grid.d.ts +3 -3
- package/styled-system/jsx/grid.mjs +5 -5
- package/styled-system/jsx/hstack.d.ts +3 -3
- package/styled-system/jsx/hstack.mjs +5 -5
- package/styled-system/jsx/index.d.ts +27 -24
- package/styled-system/jsx/index.mjs +23 -23
- package/styled-system/jsx/is-valid-prop.mjs +13 -12
- package/styled-system/jsx/link-box.d.ts +3 -3
- package/styled-system/jsx/link-box.mjs +4 -4
- package/styled-system/jsx/link-overlay.d.ts +3 -3
- package/styled-system/jsx/link-overlay.mjs +4 -4
- package/styled-system/jsx/spacer.d.ts +3 -3
- package/styled-system/jsx/spacer.mjs +5 -5
- package/styled-system/jsx/square.d.ts +3 -3
- package/styled-system/jsx/square.mjs +5 -5
- package/styled-system/jsx/stack.d.ts +3 -3
- package/styled-system/jsx/stack.mjs +5 -5
- package/styled-system/jsx/styled-link.d.ts +3 -3
- package/styled-system/jsx/styled-link.mjs +4 -4
- package/styled-system/jsx/visually-hidden.d.ts +3 -3
- package/styled-system/jsx/visually-hidden.mjs +4 -4
- package/styled-system/jsx/vstack.d.ts +3 -3
- package/styled-system/jsx/vstack.mjs +5 -5
- package/styled-system/jsx/wrap.d.ts +3 -3
- package/styled-system/jsx/wrap.mjs +5 -5
- package/styled-system/patterns/aspect-ratio.d.ts +5 -5
- package/styled-system/patterns/aspect-ratio.mjs +29 -30
- package/styled-system/patterns/bleed.d.ts +5 -5
- package/styled-system/patterns/bleed.mjs +13 -14
- package/styled-system/patterns/box.d.ts +5 -5
- package/styled-system/patterns/box.mjs +6 -7
- package/styled-system/patterns/center.d.ts +5 -5
- package/styled-system/patterns/center.mjs +12 -13
- package/styled-system/patterns/circle.d.ts +5 -5
- package/styled-system/patterns/circle.mjs +16 -17
- package/styled-system/patterns/container.d.ts +5 -5
- package/styled-system/patterns/container.mjs +12 -13
- package/styled-system/patterns/divider.d.ts +5 -5
- package/styled-system/patterns/divider.mjs +15 -16
- package/styled-system/patterns/flex.d.ts +5 -5
- package/styled-system/patterns/flex.mjs +17 -18
- package/styled-system/patterns/float.d.ts +5 -5
- package/styled-system/patterns/float.mjs +39 -40
- package/styled-system/patterns/grid-item.d.ts +5 -5
- package/styled-system/patterns/grid-item.mjs +16 -17
- package/styled-system/patterns/grid.d.ts +5 -5
- package/styled-system/patterns/grid.mjs +14 -20
- package/styled-system/patterns/hstack.d.ts +5 -5
- package/styled-system/patterns/hstack.mjs +14 -15
- package/styled-system/patterns/index.d.ts +21 -21
- package/styled-system/patterns/index.mjs +21 -21
- package/styled-system/patterns/link-box.d.ts +5 -5
- package/styled-system/patterns/link-box.mjs +13 -14
- package/styled-system/patterns/link-overlay.d.ts +5 -5
- package/styled-system/patterns/link-overlay.mjs +18 -19
- package/styled-system/patterns/spacer.d.ts +5 -5
- package/styled-system/patterns/spacer.mjs +12 -13
- package/styled-system/patterns/square.d.ts +5 -5
- package/styled-system/patterns/square.mjs +15 -16
- package/styled-system/patterns/stack.d.ts +5 -5
- package/styled-system/patterns/stack.mjs +14 -15
- package/styled-system/patterns/styled-link.d.ts +5 -5
- package/styled-system/patterns/styled-link.mjs +12 -13
- package/styled-system/patterns/visually-hidden.d.ts +5 -5
- package/styled-system/patterns/visually-hidden.mjs +9 -10
- package/styled-system/patterns/vstack.d.ts +5 -5
- package/styled-system/patterns/vstack.mjs +14 -15
- package/styled-system/patterns/wrap.d.ts +5 -5
- package/styled-system/patterns/wrap.mjs +16 -17
- package/styled-system/reset.css +4 -3
- package/styled-system/static.css +3 -3
- package/styled-system/styles.css +50 -50
- package/styled-system/tokens/index.css +434 -434
- package/styled-system/tokens/index.d.ts +2 -2
- package/styled-system/tokens/index.mjs +1419 -1421
- package/styled-system/tokens/keyframes.css +23 -25
- package/styled-system/types/composition.d.ts +1 -1
- package/styled-system/types/conditions.d.ts +1 -1
- package/styled-system/types/global.d.ts +6 -5
- package/styled-system/types/index.d.ts +3 -3
- package/styled-system/types/jsx.d.ts +2 -2
- package/styled-system/types/pattern.d.ts +2 -2
- package/styled-system/types/prop-type.d.ts +2 -2
- package/styled-system/types/recipe.d.ts +1 -1
- package/styled-system/types/selectors.d.ts +1 -1
- package/styled-system/types/style-props.d.ts +3 -3
- package/styled-system/types/system-types.d.ts +3 -3
|
@@ -1,23 +1,22 @@
|
|
|
1
|
-
import { mapObject } from '../helpers.mjs'
|
|
2
|
-
import { css } from '../css/index.mjs'
|
|
1
|
+
import { mapObject } from '../helpers.mjs';
|
|
2
|
+
import { css } from '../css/index.mjs';
|
|
3
3
|
|
|
4
4
|
const gridItemConfig = {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
}
|
|
5
|
+
transform(props, { map }) {
|
|
6
|
+
const { colSpan, rowSpan, colStart, rowStart, colEnd, rowEnd, ...rest } = props;
|
|
7
|
+
const spanFn = (v) => v === "auto" ? v : `span ${v}`;
|
|
8
|
+
return {
|
|
9
|
+
gridColumn: colSpan != null ? map(colSpan, spanFn) : void 0,
|
|
10
|
+
gridRow: rowSpan != null ? map(rowSpan, spanFn) : void 0,
|
|
11
|
+
gridColumnStart: colStart,
|
|
12
|
+
gridColumnEnd: colEnd,
|
|
13
|
+
gridRowStart: rowStart,
|
|
14
|
+
gridRowEnd: rowEnd,
|
|
15
|
+
...rest
|
|
16
|
+
};
|
|
17
|
+
}}
|
|
19
18
|
|
|
20
19
|
export const getGridItemStyle = (styles = {}) => gridItemConfig.transform(styles, { map: mapObject })
|
|
21
20
|
|
|
22
21
|
export const gridItem = (styles) => css(getGridItemStyle(styles))
|
|
23
|
-
gridItem.raw = getGridItemStyle
|
|
22
|
+
gridItem.raw = getGridItemStyle
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types'
|
|
3
|
-
import type { Properties } from '../types/csstype'
|
|
4
|
-
import type { PropertyValue } from '../types/prop-type'
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types'
|
|
6
|
-
import type { Tokens } from '../tokens'
|
|
2
|
+
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
+
import type { Properties } from '../types/csstype';
|
|
4
|
+
import type { PropertyValue } from '../types/prop-type';
|
|
5
|
+
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
+
import type { Tokens } from '../tokens/index';
|
|
7
7
|
|
|
8
8
|
export type GridProperties = {
|
|
9
9
|
gap?: PropertyValue<'gap'>
|
|
@@ -1,26 +1,20 @@
|
|
|
1
|
-
import { mapObject } from '../helpers.mjs'
|
|
2
|
-
import { css } from '../css/index.mjs'
|
|
1
|
+
import { mapObject } from '../helpers.mjs';
|
|
2
|
+
import { css } from '../css/index.mjs';
|
|
3
3
|
|
|
4
4
|
const gridConfig = {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
columnGap,
|
|
17
|
-
rowGap,
|
|
18
|
-
...rest,
|
|
19
|
-
}
|
|
20
|
-
},
|
|
21
|
-
}
|
|
5
|
+
transform(props, { map }) {
|
|
6
|
+
const { columnGap, rowGap, gap = columnGap || rowGap ? void 0 : "10px", columns, minChildWidth, ...rest } = props;
|
|
7
|
+
return {
|
|
8
|
+
display: "grid",
|
|
9
|
+
gridTemplateColumns: columns != null ? map(columns, (v) => `repeat(${v}, minmax(0, 1fr))`) : minChildWidth != null ? map(minChildWidth, (v) => `repeat(auto-fit, minmax(${v}, 1fr))`) : void 0,
|
|
10
|
+
gap,
|
|
11
|
+
columnGap,
|
|
12
|
+
rowGap,
|
|
13
|
+
...rest
|
|
14
|
+
};
|
|
15
|
+
}}
|
|
22
16
|
|
|
23
17
|
export const getGridStyle = (styles = {}) => gridConfig.transform(styles, { map: mapObject })
|
|
24
18
|
|
|
25
19
|
export const grid = (styles) => css(getGridStyle(styles))
|
|
26
|
-
grid.raw = getGridStyle
|
|
20
|
+
grid.raw = getGridStyle
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types'
|
|
3
|
-
import type { Properties } from '../types/csstype'
|
|
4
|
-
import type { PropertyValue } from '../types/prop-type'
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types'
|
|
6
|
-
import type { Tokens } from '../tokens'
|
|
2
|
+
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
+
import type { Properties } from '../types/csstype';
|
|
4
|
+
import type { PropertyValue } from '../types/prop-type';
|
|
5
|
+
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
+
import type { Tokens } from '../tokens/index';
|
|
7
7
|
|
|
8
8
|
export type HstackProperties = {
|
|
9
9
|
justify?: PropertyValue<'justifyContent'>
|
|
@@ -1,21 +1,20 @@
|
|
|
1
|
-
import { mapObject } from '../helpers.mjs'
|
|
2
|
-
import { css } from '../css/index.mjs'
|
|
1
|
+
import { mapObject } from '../helpers.mjs';
|
|
2
|
+
import { css } from '../css/index.mjs';
|
|
3
3
|
|
|
4
4
|
const hstackConfig = {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
}
|
|
5
|
+
transform(props) {
|
|
6
|
+
const { justify, gap = "10px", ...rest } = props;
|
|
7
|
+
return {
|
|
8
|
+
display: "flex",
|
|
9
|
+
alignItems: "center",
|
|
10
|
+
justifyContent: justify,
|
|
11
|
+
gap,
|
|
12
|
+
flexDirection: "row",
|
|
13
|
+
...rest
|
|
14
|
+
};
|
|
15
|
+
}}
|
|
17
16
|
|
|
18
17
|
export const getHstackStyle = (styles = {}) => hstackConfig.transform(styles, { map: mapObject })
|
|
19
18
|
|
|
20
19
|
export const hstack = (styles) => css(getHstackStyle(styles))
|
|
21
|
-
hstack.raw = getHstackStyle
|
|
20
|
+
hstack.raw = getHstackStyle
|
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
/* eslint-disable */
|
|
2
|
-
export * from './box'
|
|
3
|
-
export * from './flex'
|
|
4
|
-
export * from './stack'
|
|
5
|
-
export * from './vstack'
|
|
6
|
-
export * from './hstack'
|
|
7
|
-
export * from './spacer'
|
|
8
|
-
export * from './square'
|
|
9
|
-
export * from './circle'
|
|
10
|
-
export * from './center'
|
|
11
|
-
export * from './link-box'
|
|
12
|
-
export * from './link-overlay'
|
|
13
|
-
export * from './aspect-ratio'
|
|
14
|
-
export * from './grid'
|
|
15
|
-
export * from './grid-item'
|
|
16
|
-
export * from './wrap'
|
|
17
|
-
export * from './container'
|
|
18
|
-
export * from './divider'
|
|
19
|
-
export * from './float'
|
|
20
|
-
export * from './bleed'
|
|
21
|
-
export * from './visually-hidden'
|
|
22
|
-
export * from './styled-link'
|
|
2
|
+
export * from './box';
|
|
3
|
+
export * from './flex';
|
|
4
|
+
export * from './stack';
|
|
5
|
+
export * from './vstack';
|
|
6
|
+
export * from './hstack';
|
|
7
|
+
export * from './spacer';
|
|
8
|
+
export * from './square';
|
|
9
|
+
export * from './circle';
|
|
10
|
+
export * from './center';
|
|
11
|
+
export * from './link-box';
|
|
12
|
+
export * from './link-overlay';
|
|
13
|
+
export * from './aspect-ratio';
|
|
14
|
+
export * from './grid';
|
|
15
|
+
export * from './grid-item';
|
|
16
|
+
export * from './wrap';
|
|
17
|
+
export * from './container';
|
|
18
|
+
export * from './divider';
|
|
19
|
+
export * from './float';
|
|
20
|
+
export * from './bleed';
|
|
21
|
+
export * from './visually-hidden';
|
|
22
|
+
export * from './styled-link';
|
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
export * from './box.mjs'
|
|
2
|
-
export * from './flex.mjs'
|
|
3
|
-
export * from './stack.mjs'
|
|
4
|
-
export * from './vstack.mjs'
|
|
5
|
-
export * from './hstack.mjs'
|
|
6
|
-
export * from './spacer.mjs'
|
|
7
|
-
export * from './square.mjs'
|
|
8
|
-
export * from './circle.mjs'
|
|
9
|
-
export * from './center.mjs'
|
|
10
|
-
export * from './link-box.mjs'
|
|
11
|
-
export * from './link-overlay.mjs'
|
|
12
|
-
export * from './aspect-ratio.mjs'
|
|
13
|
-
export * from './grid.mjs'
|
|
14
|
-
export * from './grid-item.mjs'
|
|
15
|
-
export * from './wrap.mjs'
|
|
16
|
-
export * from './container.mjs'
|
|
17
|
-
export * from './divider.mjs'
|
|
18
|
-
export * from './float.mjs'
|
|
19
|
-
export * from './bleed.mjs'
|
|
20
|
-
export * from './visually-hidden.mjs'
|
|
21
|
-
export * from './styled-link.mjs'
|
|
1
|
+
export * from './box.mjs';
|
|
2
|
+
export * from './flex.mjs';
|
|
3
|
+
export * from './stack.mjs';
|
|
4
|
+
export * from './vstack.mjs';
|
|
5
|
+
export * from './hstack.mjs';
|
|
6
|
+
export * from './spacer.mjs';
|
|
7
|
+
export * from './square.mjs';
|
|
8
|
+
export * from './circle.mjs';
|
|
9
|
+
export * from './center.mjs';
|
|
10
|
+
export * from './link-box.mjs';
|
|
11
|
+
export * from './link-overlay.mjs';
|
|
12
|
+
export * from './aspect-ratio.mjs';
|
|
13
|
+
export * from './grid.mjs';
|
|
14
|
+
export * from './grid-item.mjs';
|
|
15
|
+
export * from './wrap.mjs';
|
|
16
|
+
export * from './container.mjs';
|
|
17
|
+
export * from './divider.mjs';
|
|
18
|
+
export * from './float.mjs';
|
|
19
|
+
export * from './bleed.mjs';
|
|
20
|
+
export * from './visually-hidden.mjs';
|
|
21
|
+
export * from './styled-link.mjs';
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types'
|
|
3
|
-
import type { Properties } from '../types/csstype'
|
|
4
|
-
import type { PropertyValue } from '../types/prop-type'
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types'
|
|
6
|
-
import type { Tokens } from '../tokens'
|
|
2
|
+
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
+
import type { Properties } from '../types/csstype';
|
|
4
|
+
import type { PropertyValue } from '../types/prop-type';
|
|
5
|
+
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
+
import type { Tokens } from '../tokens/index';
|
|
7
7
|
|
|
8
8
|
export type LinkBoxProperties = {
|
|
9
9
|
|
|
@@ -1,20 +1,19 @@
|
|
|
1
|
-
import { mapObject } from '../helpers.mjs'
|
|
2
|
-
import { css } from '../css/index.mjs'
|
|
1
|
+
import { mapObject } from '../helpers.mjs';
|
|
2
|
+
import { css } from '../css/index.mjs';
|
|
3
3
|
|
|
4
4
|
const linkBoxConfig = {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
}
|
|
5
|
+
transform(props) {
|
|
6
|
+
return {
|
|
7
|
+
position: "relative",
|
|
8
|
+
"& :where(a, abbr)": {
|
|
9
|
+
position: "relative",
|
|
10
|
+
zIndex: "1"
|
|
11
|
+
},
|
|
12
|
+
...props
|
|
13
|
+
};
|
|
14
|
+
}}
|
|
16
15
|
|
|
17
16
|
export const getLinkBoxStyle = (styles = {}) => linkBoxConfig.transform(styles, { map: mapObject })
|
|
18
17
|
|
|
19
18
|
export const linkBox = (styles) => css(getLinkBoxStyle(styles))
|
|
20
|
-
linkBox.raw = getLinkBoxStyle
|
|
19
|
+
linkBox.raw = getLinkBoxStyle
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types'
|
|
3
|
-
import type { Properties } from '../types/csstype'
|
|
4
|
-
import type { PropertyValue } from '../types/prop-type'
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types'
|
|
6
|
-
import type { Tokens } from '../tokens'
|
|
2
|
+
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
+
import type { Properties } from '../types/csstype';
|
|
4
|
+
import type { PropertyValue } from '../types/prop-type';
|
|
5
|
+
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
+
import type { Tokens } from '../tokens/index';
|
|
7
7
|
|
|
8
8
|
export type LinkOverlayProperties = {
|
|
9
9
|
|
|
@@ -1,25 +1,24 @@
|
|
|
1
|
-
import { mapObject } from '../helpers.mjs'
|
|
2
|
-
import { css } from '../css/index.mjs'
|
|
1
|
+
import { mapObject } from '../helpers.mjs';
|
|
2
|
+
import { css } from '../css/index.mjs';
|
|
3
3
|
|
|
4
4
|
const linkOverlayConfig = {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
}
|
|
5
|
+
transform(props) {
|
|
6
|
+
return {
|
|
7
|
+
position: "static",
|
|
8
|
+
_before: {
|
|
9
|
+
content: '""',
|
|
10
|
+
display: "block",
|
|
11
|
+
position: "absolute",
|
|
12
|
+
cursor: "inherit",
|
|
13
|
+
inset: "0",
|
|
14
|
+
zIndex: "0",
|
|
15
|
+
...props["_before"]
|
|
16
|
+
},
|
|
17
|
+
...props
|
|
18
|
+
};
|
|
19
|
+
}}
|
|
21
20
|
|
|
22
21
|
export const getLinkOverlayStyle = (styles = {}) => linkOverlayConfig.transform(styles, { map: mapObject })
|
|
23
22
|
|
|
24
23
|
export const linkOverlay = (styles) => css(getLinkOverlayStyle(styles))
|
|
25
|
-
linkOverlay.raw = getLinkOverlayStyle
|
|
24
|
+
linkOverlay.raw = getLinkOverlayStyle
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types'
|
|
3
|
-
import type { Properties } from '../types/csstype'
|
|
4
|
-
import type { PropertyValue } from '../types/prop-type'
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types'
|
|
6
|
-
import type { Tokens } from '../tokens'
|
|
2
|
+
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
+
import type { Properties } from '../types/csstype';
|
|
4
|
+
import type { PropertyValue } from '../types/prop-type';
|
|
5
|
+
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
+
import type { Tokens } from '../tokens/index';
|
|
7
7
|
|
|
8
8
|
export type SpacerProperties = {
|
|
9
9
|
size?: ConditionalValue<Tokens["spacing"]>
|
|
@@ -1,19 +1,18 @@
|
|
|
1
|
-
import { mapObject } from '../helpers.mjs'
|
|
2
|
-
import { css } from '../css/index.mjs'
|
|
1
|
+
import { mapObject } from '../helpers.mjs';
|
|
2
|
+
import { css } from '../css/index.mjs';
|
|
3
3
|
|
|
4
4
|
const spacerConfig = {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
}
|
|
5
|
+
transform(props, { map }) {
|
|
6
|
+
const { size, ...rest } = props;
|
|
7
|
+
return {
|
|
8
|
+
alignSelf: "stretch",
|
|
9
|
+
justifySelf: "stretch",
|
|
10
|
+
flex: map(size, (v) => v == null ? "1" : `0 0 ${v}`),
|
|
11
|
+
...rest
|
|
12
|
+
};
|
|
13
|
+
}}
|
|
15
14
|
|
|
16
15
|
export const getSpacerStyle = (styles = {}) => spacerConfig.transform(styles, { map: mapObject })
|
|
17
16
|
|
|
18
17
|
export const spacer = (styles) => css(getSpacerStyle(styles))
|
|
19
|
-
spacer.raw = getSpacerStyle
|
|
18
|
+
spacer.raw = getSpacerStyle
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types'
|
|
3
|
-
import type { Properties } from '../types/csstype'
|
|
4
|
-
import type { PropertyValue } from '../types/prop-type'
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types'
|
|
6
|
-
import type { Tokens } from '../tokens'
|
|
2
|
+
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
+
import type { Properties } from '../types/csstype';
|
|
4
|
+
import type { PropertyValue } from '../types/prop-type';
|
|
5
|
+
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
+
import type { Tokens } from '../tokens/index';
|
|
7
7
|
|
|
8
8
|
export type SquareProperties = {
|
|
9
9
|
size?: PropertyValue<'width'>
|
|
@@ -1,22 +1,21 @@
|
|
|
1
|
-
import { mapObject } from '../helpers.mjs'
|
|
2
|
-
import { css } from '../css/index.mjs'
|
|
1
|
+
import { mapObject } from '../helpers.mjs';
|
|
2
|
+
import { css } from '../css/index.mjs';
|
|
3
3
|
|
|
4
4
|
const squareConfig = {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
}
|
|
5
|
+
transform(props) {
|
|
6
|
+
const { size, ...rest } = props;
|
|
7
|
+
return {
|
|
8
|
+
display: "flex",
|
|
9
|
+
alignItems: "center",
|
|
10
|
+
justifyContent: "center",
|
|
11
|
+
flex: "0 0 auto",
|
|
12
|
+
width: size,
|
|
13
|
+
height: size,
|
|
14
|
+
...rest
|
|
15
|
+
};
|
|
16
|
+
}}
|
|
18
17
|
|
|
19
18
|
export const getSquareStyle = (styles = {}) => squareConfig.transform(styles, { map: mapObject })
|
|
20
19
|
|
|
21
20
|
export const square = (styles) => css(getSquareStyle(styles))
|
|
22
|
-
square.raw = getSquareStyle
|
|
21
|
+
square.raw = getSquareStyle
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types'
|
|
3
|
-
import type { Properties } from '../types/csstype'
|
|
4
|
-
import type { PropertyValue } from '../types/prop-type'
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types'
|
|
6
|
-
import type { Tokens } from '../tokens'
|
|
2
|
+
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
+
import type { Properties } from '../types/csstype';
|
|
4
|
+
import type { PropertyValue } from '../types/prop-type';
|
|
5
|
+
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
+
import type { Tokens } from '../tokens/index';
|
|
7
7
|
|
|
8
8
|
export type StackProperties = {
|
|
9
9
|
align?: PropertyValue<'alignItems'>
|
|
@@ -1,21 +1,20 @@
|
|
|
1
|
-
import { mapObject } from '../helpers.mjs'
|
|
2
|
-
import { css } from '../css/index.mjs'
|
|
1
|
+
import { mapObject } from '../helpers.mjs';
|
|
2
|
+
import { css } from '../css/index.mjs';
|
|
3
3
|
|
|
4
4
|
const stackConfig = {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
}
|
|
5
|
+
transform(props) {
|
|
6
|
+
const { align, justify, direction = "column", gap = "10px", ...rest } = props;
|
|
7
|
+
return {
|
|
8
|
+
display: "flex",
|
|
9
|
+
flexDirection: direction,
|
|
10
|
+
alignItems: align,
|
|
11
|
+
justifyContent: justify,
|
|
12
|
+
gap,
|
|
13
|
+
...rest
|
|
14
|
+
};
|
|
15
|
+
}}
|
|
17
16
|
|
|
18
17
|
export const getStackStyle = (styles = {}) => stackConfig.transform(styles, { map: mapObject })
|
|
19
18
|
|
|
20
19
|
export const stack = (styles) => css(getStackStyle(styles))
|
|
21
|
-
stack.raw = getStackStyle
|
|
20
|
+
stack.raw = getStackStyle
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types'
|
|
3
|
-
import type { Properties } from '../types/csstype'
|
|
4
|
-
import type { PropertyValue } from '../types/prop-type'
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types'
|
|
6
|
-
import type { Tokens } from '../tokens'
|
|
2
|
+
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
+
import type { Properties } from '../types/csstype';
|
|
4
|
+
import type { PropertyValue } from '../types/prop-type';
|
|
5
|
+
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
+
import type { Tokens } from '../tokens/index';
|
|
7
7
|
|
|
8
8
|
export type StyledLinkProperties = {
|
|
9
9
|
|
|
@@ -1,19 +1,18 @@
|
|
|
1
|
-
import { mapObject } from '../helpers.mjs'
|
|
2
|
-
import { css } from '../css/index.mjs'
|
|
1
|
+
import { mapObject } from '../helpers.mjs';
|
|
2
|
+
import { css } from '../css/index.mjs';
|
|
3
3
|
|
|
4
4
|
const styledLinkConfig = {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
}
|
|
5
|
+
transform:(props) => ({
|
|
6
|
+
display: "inline-flex",
|
|
7
|
+
alignItems: "center",
|
|
8
|
+
opacity: "0.5",
|
|
9
|
+
borderBottom: "1px solid transparent",
|
|
10
|
+
cursor: "pointer",
|
|
11
|
+
_hover: { opacity: 1, borderBottomColor: "black" },
|
|
12
|
+
...props
|
|
13
|
+
})}
|
|
15
14
|
|
|
16
15
|
export const getStyledLinkStyle = (styles = {}) => styledLinkConfig.transform(styles, { map: mapObject })
|
|
17
16
|
|
|
18
17
|
export const styledLink = (styles) => css(getStyledLinkStyle(styles))
|
|
19
|
-
styledLink.raw = getStyledLinkStyle
|
|
18
|
+
styledLink.raw = getStyledLinkStyle
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types'
|
|
3
|
-
import type { Properties } from '../types/csstype'
|
|
4
|
-
import type { PropertyValue } from '../types/prop-type'
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types'
|
|
6
|
-
import type { Tokens } from '../tokens'
|
|
2
|
+
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
+
import type { Properties } from '../types/csstype';
|
|
4
|
+
import type { PropertyValue } from '../types/prop-type';
|
|
5
|
+
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
+
import type { Tokens } from '../tokens/index';
|
|
7
7
|
|
|
8
8
|
export type VisuallyHiddenProperties = {
|
|
9
9
|
|
|
@@ -1,16 +1,15 @@
|
|
|
1
|
-
import { mapObject } from '../helpers.mjs'
|
|
2
|
-
import { css } from '../css/index.mjs'
|
|
1
|
+
import { mapObject } from '../helpers.mjs';
|
|
2
|
+
import { css } from '../css/index.mjs';
|
|
3
3
|
|
|
4
4
|
const visuallyHiddenConfig = {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
}
|
|
5
|
+
transform(props) {
|
|
6
|
+
return {
|
|
7
|
+
srOnly: true,
|
|
8
|
+
...props
|
|
9
|
+
};
|
|
10
|
+
}}
|
|
12
11
|
|
|
13
12
|
export const getVisuallyHiddenStyle = (styles = {}) => visuallyHiddenConfig.transform(styles, { map: mapObject })
|
|
14
13
|
|
|
15
14
|
export const visuallyHidden = (styles) => css(getVisuallyHiddenStyle(styles))
|
|
16
|
-
visuallyHidden.raw = getVisuallyHiddenStyle
|
|
15
|
+
visuallyHidden.raw = getVisuallyHiddenStyle
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/* eslint-disable */
|
|
2
|
-
import type { SystemStyleObject, ConditionalValue } from '../types'
|
|
3
|
-
import type { Properties } from '../types/csstype'
|
|
4
|
-
import type { PropertyValue } from '../types/prop-type'
|
|
5
|
-
import type { DistributiveOmit } from '../types/system-types'
|
|
6
|
-
import type { Tokens } from '../tokens'
|
|
2
|
+
import type { SystemStyleObject, ConditionalValue } from '../types/index';
|
|
3
|
+
import type { Properties } from '../types/csstype';
|
|
4
|
+
import type { PropertyValue } from '../types/prop-type';
|
|
5
|
+
import type { DistributiveOmit } from '../types/system-types';
|
|
6
|
+
import type { Tokens } from '../tokens/index';
|
|
7
7
|
|
|
8
8
|
export type VstackProperties = {
|
|
9
9
|
justify?: PropertyValue<'justifyContent'>
|