@okshaun/components 0.5.8 → 1.0.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/README.md +22 -26
- package/dist/.mcp.json +11 -0
- package/dist/index.d.ts +3 -1268
- package/dist/index.js +1231 -957
- package/dist/index.js.map +1 -1
- package/dist/okshaun-logo-white.svg +11 -0
- package/dist/okshaun-logo.svg +11 -0
- package/dist/preset-BzrKiUEH.js +8452 -0
- package/dist/preset-BzrKiUEH.js.map +1 -0
- package/dist/preset.js +3 -7234
- package/dist/preset.js.map +1 -1
- package/dist/specs/animation-styles.json +4 -0
- package/dist/specs/color-palette.json +98 -0
- package/dist/specs/conditions.json +1901 -0
- package/dist/specs/keyframes.json +137 -0
- package/dist/specs/layer-styles.json +23 -0
- package/dist/specs/patterns.json +475 -0
- package/dist/specs/recipes.json +907 -0
- package/dist/specs/semantic-tokens.json +2837 -0
- package/dist/specs/text-styles.json +149 -0
- package/dist/specs/tokens.json +2750 -0
- package/dist/sprite.svg +1 -1
- package/dist/sprite.symbol.html +14 -14
- package/dist/styles/global.css +148 -0
- package/dist/styles/recipes/avatar.css +185 -0
- package/dist/styles/recipes/badge.css +85 -0
- package/dist/styles/recipes/breadcrumbs.css +38 -0
- package/dist/styles/recipes/button.css +195 -0
- package/dist/styles/recipes/card.css +57 -0
- package/dist/styles/recipes/checkbox-input.css +12 -0
- package/dist/styles/recipes/checkbox.css +90 -0
- package/dist/styles/recipes/chip.css +137 -0
- package/dist/styles/recipes/code.css +12 -0
- package/dist/styles/recipes/divider.css +43 -0
- package/dist/styles/recipes/form-field.css +39 -0
- package/dist/styles/recipes/heading.css +40 -0
- package/dist/styles/recipes/icon-button.css +181 -0
- package/dist/styles/recipes/label.css +14 -0
- package/dist/styles/recipes/link.css +49 -0
- package/dist/styles/recipes/menu.css +141 -0
- package/dist/styles/recipes/modal.css +99 -0
- package/dist/styles/recipes/pre.css +16 -0
- package/dist/styles/recipes/radio-input.css +7 -0
- package/dist/styles/recipes/radio.css +82 -0
- package/dist/styles/recipes/select.css +103 -0
- package/dist/styles/recipes/spinner.css +36 -0
- package/dist/styles/recipes/tag.css +27 -0
- package/dist/styles/recipes/text.css +46 -0
- package/dist/styles/recipes/textarea.css +91 -0
- package/dist/styles/recipes/textinput.css +87 -0
- package/dist/styles/recipes/theme-switcher.css +53 -0
- package/dist/styles/recipes/toggle-input.css +12 -0
- package/dist/styles/recipes/toggle.css +125 -0
- package/dist/styles/recipes/tooltip.css +133 -0
- package/dist/styles/recipes.css +30 -0
- package/dist/styles/reset.css +1 -0
- package/dist/styles/tokens.css +1016 -0
- package/dist/styles/utilities.css +1694 -0
- package/dist/styles.css +7 -0
- package/dist/svgs/building.svg +1 -0
- package/dist/types/index.d.ts +21626 -0
- package/dist/types/preset.d.ts +19 -0
- package/package.json +37 -35
- package/src/recipes/avatar.ts +205 -0
- package/src/recipes/badge.ts +203 -0
- package/src/recipes/box.ts +13 -0
- package/src/recipes/breadcrumbs.ts +29 -0
- package/src/recipes/button.ts +319 -0
- package/src/recipes/card.ts +148 -0
- package/src/recipes/checkbox.ts +87 -0
- package/src/recipes/checkboxinput.ts +15 -0
- package/src/recipes/chip.ts +189 -0
- package/src/recipes/code.ts +35 -0
- package/src/recipes/divider.ts +41 -0
- package/src/recipes/formField.ts +60 -0
- package/src/recipes/index.ts +28 -0
- package/src/recipes/menu.ts +205 -0
- package/src/recipes/modal.ts +120 -0
- package/src/recipes/radio.ts +71 -0
- package/src/recipes/radioinput.ts +12 -0
- package/src/recipes/select.ts +142 -0
- package/src/recipes/spinner.ts +52 -0
- package/src/recipes/tag.ts +262 -0
- package/src/recipes/text.ts +193 -0
- package/src/recipes/textarea.ts +153 -0
- package/src/recipes/textinput.ts +100 -0
- package/src/recipes/themeSwitcher.ts +48 -0
- package/src/recipes/toggle.ts +116 -0
- package/src/recipes/toggleinput.ts +16 -0
- package/src/recipes/tooltip.ts +359 -0
- package/src/styles/index.css +1 -0
- package/src/styles/primitives/animations.ts +16 -0
- package/src/styles/primitives/aspectRatios.ts +22 -0
- package/src/styles/primitives/blurs.ts +25 -0
- package/src/styles/primitives/borderWidths.ts +10 -0
- package/src/styles/primitives/borders.ts +36 -0
- package/src/styles/primitives/colors.ts +228 -0
- package/src/styles/primitives/durations.ts +25 -0
- package/src/styles/primitives/easings.ts +19 -0
- package/src/styles/primitives/fontSizes.ts +16 -0
- package/src/styles/primitives/fontWeights.ts +9 -0
- package/src/styles/primitives/fonts.ts +18 -0
- package/src/styles/primitives/index.ts +46 -0
- package/src/styles/primitives/letterSpacings.ts +22 -0
- package/src/styles/primitives/lineHeights.ts +16 -0
- package/src/styles/primitives/radii.ts +14 -0
- package/src/styles/primitives/shadows.ts +73 -0
- package/src/styles/primitives/sizes.ts +86 -0
- package/src/styles/primitives/spacings.ts +7 -0
- package/src/styles/semantics/colors.ts +774 -0
- package/src/styles/semantics/index.ts +2 -0
- package/src/styles/semantics/shadows.ts +32 -0
- package/src/styles/utilities/breakpoints.ts +8 -0
- package/src/styles/utilities/conditions.ts +140 -0
- package/src/styles/utilities/containerSizes.ts +17 -0
- package/src/styles/utilities/filters.ts +12 -0
- package/src/styles/utilities/globalStyle.ts +93 -0
- package/src/styles/utilities/index.ts +9 -0
- package/src/styles/utilities/keyframes.ts +89 -0
- package/src/styles/utilities/layerStyles.ts +18 -0
- package/src/styles/utilities/textStyles.ts +135 -0
- package/src/styles/utilities/transitions.ts +92 -0
- package/src/utils/injectSprite.ts +36 -0
- package/src/utils/splitProps.ts +19 -0
- package/src/utils/spriteContent.ts +4 -0
- package/dist/panda.buildinfo.json +0 -448
- package/dist/preset.d.ts +0 -5
- package/dist/transitions-DUgH88VW.js +0 -1041
- package/dist/transitions-DUgH88VW.js.map +0 -1
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { defineSemanticTokens } from '@pandacss/dev';
|
|
2
|
+
|
|
3
|
+
export const shadows = defineSemanticTokens.shadows({
|
|
4
|
+
zero: {
|
|
5
|
+
value: { base: '{shadows.zeroShadow}', _dark: '{shadows.zeroShadow}' },
|
|
6
|
+
},
|
|
7
|
+
raised: {
|
|
8
|
+
value: { base: '{shadows.raisedLight}', _dark: '{shadows.raisedDark}' },
|
|
9
|
+
},
|
|
10
|
+
elevated: {
|
|
11
|
+
value: { base: '{shadows.elevatedLight}', _dark: '{shadows.elevatedDark}' },
|
|
12
|
+
},
|
|
13
|
+
overlay: {
|
|
14
|
+
value: { base: '{shadows.overlayLight}', _dark: '{shadows.overlayDark}' },
|
|
15
|
+
},
|
|
16
|
+
overflow: {
|
|
17
|
+
value: { base: '{shadows.overflowLight}', _dark: '{shadows.overflowDark}' },
|
|
18
|
+
},
|
|
19
|
+
// TODO: delete below once migration is complete
|
|
20
|
+
low: {
|
|
21
|
+
value: { base: '{shadows.lowLight}', _dark: '{shadows.lowDark}' },
|
|
22
|
+
},
|
|
23
|
+
medium: {
|
|
24
|
+
value: { base: '{shadows.mediumLight}', _dark: '{shadows.mediumDark}' },
|
|
25
|
+
},
|
|
26
|
+
high: {
|
|
27
|
+
value: { base: '{shadows.highLight}', _dark: '{shadows.highDark}' },
|
|
28
|
+
},
|
|
29
|
+
inset: {
|
|
30
|
+
value: { base: '{shadows.insetLight}', _dark: '{shadows.insetDark}' },
|
|
31
|
+
},
|
|
32
|
+
});
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
export const conditions = {
|
|
2
|
+
hover: '&:is(:hover, [data-hover=true])',
|
|
3
|
+
focus: '&:is(:focus, [data-focus=true])',
|
|
4
|
+
focusWithin: '&:focus-within',
|
|
5
|
+
focusVisible: '&:is(:focus-visible, [data-focus-visible=true])',
|
|
6
|
+
disabled:
|
|
7
|
+
'&:is(:disabled, [disabled], [data-disabled], [aria-disabled=true])',
|
|
8
|
+
deleted: '&:is(:deleted, [deleted], [data-deleted=true])',
|
|
9
|
+
active: '&:is(:active, [data-active=true])',
|
|
10
|
+
visited: '&:visited',
|
|
11
|
+
target: '&:target',
|
|
12
|
+
readOnly: '&:is(:read-only, [data-read-only], [aria-readonly=true])',
|
|
13
|
+
readWrite: '&:read-write',
|
|
14
|
+
empty: '&:is(:empty, [data-empty])',
|
|
15
|
+
checked:
|
|
16
|
+
'&:is(:checked, [data-checked], [aria-checked=true], [data-state="checked"])',
|
|
17
|
+
enabled: '&:enabled',
|
|
18
|
+
expanded:
|
|
19
|
+
'&:is([aria-expanded=true], [data-expanded], [data-state="expanded"])',
|
|
20
|
+
collapsed:
|
|
21
|
+
'&:is([aria-collapsed=true], [data-collapsed], [data-state="collapsed"])',
|
|
22
|
+
highlighted: '&[data-highlighted]',
|
|
23
|
+
complete: '&[data-complete]',
|
|
24
|
+
incomplete: '&[data-incomplete]',
|
|
25
|
+
dragging: '&[data-dragging]',
|
|
26
|
+
utility: '&[data-utility=true]',
|
|
27
|
+
|
|
28
|
+
before: '&::before',
|
|
29
|
+
after: '&::after',
|
|
30
|
+
firstLetter: '&::first-letter',
|
|
31
|
+
firstLine: '&::first-line',
|
|
32
|
+
marker: '&::marker, &::-webkit-details-marker',
|
|
33
|
+
selection: '&::selection',
|
|
34
|
+
file: '&::file-selector-button',
|
|
35
|
+
backdrop: '&::backdrop',
|
|
36
|
+
|
|
37
|
+
first: '&:first-child',
|
|
38
|
+
last: '&:last-child',
|
|
39
|
+
only: '&:only-child',
|
|
40
|
+
even: '&:nth-child(even)',
|
|
41
|
+
odd: '&:nth-child(odd)',
|
|
42
|
+
|
|
43
|
+
firstOfType: '&:first-of-type',
|
|
44
|
+
lastOfType: '&:last-of-type',
|
|
45
|
+
onlyOfType: '&:only-of-type',
|
|
46
|
+
|
|
47
|
+
peerFocus: '.peer:is(:focus, [data-focus]) ~ &',
|
|
48
|
+
peerHover: '.peer:is(:hover, [data-hover]) ~ &',
|
|
49
|
+
peerActive: '.peer:is(:active, [data-active]) ~ &',
|
|
50
|
+
peerFocusWithin: '.peer:focus-within ~ &',
|
|
51
|
+
peerFocusVisible: '.peer:is(:focus-visible, [data-focus-visible]) ~ &',
|
|
52
|
+
peerDisabled:
|
|
53
|
+
'.peer:is(:disabled, [disabled], [data-disabled], [aria-disabled=true]) ~ &',
|
|
54
|
+
peerChecked:
|
|
55
|
+
'.peer:is(:checked, [data-checked], [aria-checked=true], [data-state="checked"]) ~ &',
|
|
56
|
+
peerInvalid: '.peer:is(:invalid, [data-invalid], [aria-invalid=true]) ~ &',
|
|
57
|
+
peerExpanded:
|
|
58
|
+
'.peer:is([aria-expanded=true], [data-expanded], [data-state="expanded"]) ~ &',
|
|
59
|
+
peerPlaceholderShown: '.peer:placeholder-shown ~ &',
|
|
60
|
+
|
|
61
|
+
groupFocus: '.group:is(:focus, [data-focus]) &',
|
|
62
|
+
groupHover: '.group:is(:hover, [data-hover]) &',
|
|
63
|
+
groupActive: '.group:is(:active, [data-active]) &',
|
|
64
|
+
groupFocusWithin: '.group:focus-within &',
|
|
65
|
+
groupFocusVisible: '.group:is(:focus-visible, [data-focus-visible]) &',
|
|
66
|
+
groupDisabled:
|
|
67
|
+
'.group:is(:disabled, [disabled], [data-disabled], [aria-disabled=true]) &',
|
|
68
|
+
groupChecked:
|
|
69
|
+
'.group:is(:checked, [data-checked], [aria-checked=true], [data-state="checked"]) &',
|
|
70
|
+
groupExpanded:
|
|
71
|
+
'.group:is([aria-expanded=true], [data-expanded], [data-state="expanded"]) &',
|
|
72
|
+
groupInvalid: '.group:is(:invalid, [data-invalid], [aria-invalid=true]) &',
|
|
73
|
+
|
|
74
|
+
indeterminate:
|
|
75
|
+
'&:is(:indeterminate, [data-indeterminate], [aria-checked=mixed], [data-state="indeterminate"])',
|
|
76
|
+
required: '&:is(:required, [data-required], [aria-required=true])',
|
|
77
|
+
valid: '&:is(:valid, [data-valid])',
|
|
78
|
+
invalid: '&:is(:invalid, [data-invalid], [aria-invalid=true])',
|
|
79
|
+
error: '&:is([data-error], [data-error=true])',
|
|
80
|
+
autofill: '&:autofill',
|
|
81
|
+
inRange: '&:is(:in-range, [data-in-range])',
|
|
82
|
+
outOfRange: '&:is(:out-of-range, [data-outside-range])',
|
|
83
|
+
placeholder: '&::placeholder, &[data-placeholder]',
|
|
84
|
+
placeholderShown: '&:is(:placeholder-shown, [data-placeholder-shown])',
|
|
85
|
+
pressed: '&:is([aria-pressed=true], [data-pressed])',
|
|
86
|
+
selected: '&:is([aria-selected=true], [data-selected=true])',
|
|
87
|
+
grabbed: '&:is([aria-grabbed=true], [data-grabbed])',
|
|
88
|
+
underValue: '&[data-state=under-value]',
|
|
89
|
+
overValue: '&[data-state=over-value]',
|
|
90
|
+
atValue: '&[data-state=at-value]',
|
|
91
|
+
|
|
92
|
+
default: '&:default',
|
|
93
|
+
optional: '&:optional',
|
|
94
|
+
open: '&:is([open], [data-open], [data-state="open"], :popover-open)',
|
|
95
|
+
closed: '&:is([closed], [data-closed], [data-state="closed"])',
|
|
96
|
+
fullscreen: '&:is(:fullscreen, [data-fullscreen])',
|
|
97
|
+
loading: '&:is([data-loading], [aria-busy=true])',
|
|
98
|
+
hidden: '&:is([hidden], [data-hidden])',
|
|
99
|
+
|
|
100
|
+
current: '&:is([aria-current=true], [data-current])',
|
|
101
|
+
currentPage: '&[aria-current=page]',
|
|
102
|
+
currentStep: '&[aria-current=step]',
|
|
103
|
+
today: '&:is([data-today])',
|
|
104
|
+
unavailable: '&[data-unavailable]',
|
|
105
|
+
rangeStart: '&[data-range-start]',
|
|
106
|
+
rangeEnd: '&[data-range-end]',
|
|
107
|
+
now: '&[data-now]',
|
|
108
|
+
topmost: '&[data-topmost]',
|
|
109
|
+
|
|
110
|
+
motionReduce: '@media (prefers-reduced-motion: reduce)',
|
|
111
|
+
motionSafe: '@media (prefers-reduced-motion: no-preference)',
|
|
112
|
+
paused: '&:is([data-paused=true])',
|
|
113
|
+
print: '@media print',
|
|
114
|
+
landscape: '@media (orientation: landscape)',
|
|
115
|
+
portrait: '@media (orientation: portrait)',
|
|
116
|
+
|
|
117
|
+
dark: '.dark &, &:is([data-color-mode=dark] *), [data-color-mode=dark] &',
|
|
118
|
+
light: '.light &, &:is([data-color-mode=light] *), [data-color-mode=light] &',
|
|
119
|
+
osDark: '@media (prefers-color-scheme: dark)',
|
|
120
|
+
osLight: '@media (prefers-color-scheme: light)',
|
|
121
|
+
|
|
122
|
+
highContrast: '@media (forced-colors: active)',
|
|
123
|
+
lessContrast: '@media (prefers-contrast: less)',
|
|
124
|
+
moreContrast: '@media (prefers-contrast: more)',
|
|
125
|
+
|
|
126
|
+
ltr: ':where([dir=ltr], :dir(ltr)) &',
|
|
127
|
+
rtl: ':where([dir=rtl], :dir(rtl)) &',
|
|
128
|
+
|
|
129
|
+
scrollbar: '&::-webkit-scrollbar',
|
|
130
|
+
scrollbarThumb: '&::-webkit-scrollbar-thumb',
|
|
131
|
+
scrollbarTrack: '&::-webkit-scrollbar-track',
|
|
132
|
+
|
|
133
|
+
horizontal: '&[data-orientation=horizontal]',
|
|
134
|
+
vertical: '&[data-orientation=vertical]',
|
|
135
|
+
|
|
136
|
+
icon: '& :where(svg)',
|
|
137
|
+
starting: '@starting-style',
|
|
138
|
+
noscript: '@media (scripting: none)',
|
|
139
|
+
invertedColors: '@media (inverted-colors: inverted)',
|
|
140
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
// Raw values for Panda containerSizes config (no value wrappers)
|
|
2
|
+
// Panda's setupContainers() expects raw strings it can call .match() on
|
|
3
|
+
export const containerSizes = {
|
|
4
|
+
'2xs': '16rem', // 256px
|
|
5
|
+
xs: '20rem', // 320px
|
|
6
|
+
sm: '24rem', // 384px
|
|
7
|
+
md: '28rem', // 448px
|
|
8
|
+
lg: '32rem', // 512px
|
|
9
|
+
xl: '36rem', // 576px
|
|
10
|
+
'2xl': '42rem', // 672px
|
|
11
|
+
'3xl': '48rem', // 768px
|
|
12
|
+
'4xl': '56rem', // 896px
|
|
13
|
+
'5xl': '64rem', // 1024px
|
|
14
|
+
'6xl': '72rem', // 1152px
|
|
15
|
+
'7xl': '80rem', // 1280px
|
|
16
|
+
'8xl': '90rem', // 1440px
|
|
17
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { defineUtility } from '@pandacss/dev';
|
|
2
|
+
|
|
3
|
+
export const filters = {
|
|
4
|
+
invert: { value: 'invert(1)' },
|
|
5
|
+
blur: { value: 'blur(8px)' },
|
|
6
|
+
none: { value: 'none' },
|
|
7
|
+
};
|
|
8
|
+
|
|
9
|
+
export const filtersProperty = defineUtility({
|
|
10
|
+
className: 'filters',
|
|
11
|
+
values: 'filters',
|
|
12
|
+
});
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
import { defineGlobalStyles } from '@pandacss/dev';
|
|
2
|
+
|
|
3
|
+
// includes some normalize styles from:
|
|
4
|
+
// https://github.com/sindresorhus/modern-normalize/blob/main/modern-normalize.css
|
|
5
|
+
|
|
6
|
+
export const globalCss = defineGlobalStyles({
|
|
7
|
+
'*, *::before, *::after': {
|
|
8
|
+
boxSizing: 'border-box',
|
|
9
|
+
margin: 0,
|
|
10
|
+
padding: 0,
|
|
11
|
+
_focusVisible: {
|
|
12
|
+
borderColor: 'border.focused',
|
|
13
|
+
},
|
|
14
|
+
_disabled: {
|
|
15
|
+
opacity: 0.4,
|
|
16
|
+
cursor: 'not-allowed',
|
|
17
|
+
pointerEvents: 'none',
|
|
18
|
+
},
|
|
19
|
+
},
|
|
20
|
+
html: {
|
|
21
|
+
'--global-font-heading': 'fonts.heading',
|
|
22
|
+
'--global-font-body': 'fonts.body',
|
|
23
|
+
'--global-font-sans': 'fonts.sans',
|
|
24
|
+
'--global-font-serif': 'fonts.serif',
|
|
25
|
+
'--global-font-mono': 'fonts.mono',
|
|
26
|
+
fontSize: '16',
|
|
27
|
+
lineHeight: 'calc(1em + 0.5rem)',
|
|
28
|
+
'-webkit-text-size-adjust': '100%',
|
|
29
|
+
tabSize: '4',
|
|
30
|
+
},
|
|
31
|
+
body: {
|
|
32
|
+
fontFamily: 'body',
|
|
33
|
+
bg: 'surface',
|
|
34
|
+
color: 'text.subtlest',
|
|
35
|
+
fontWeight: 'normal',
|
|
36
|
+
},
|
|
37
|
+
'h1, h2, h3, h4, h5, h6': {
|
|
38
|
+
color: 'text',
|
|
39
|
+
fontWeight: 'bold',
|
|
40
|
+
lineHeight: 'calc(1em + 0.5rem)',
|
|
41
|
+
},
|
|
42
|
+
p: {
|
|
43
|
+
marginBottom: '0.5rem',
|
|
44
|
+
},
|
|
45
|
+
'b, strong': {
|
|
46
|
+
fontWeight: 'bolder',
|
|
47
|
+
},
|
|
48
|
+
'i, em': {
|
|
49
|
+
fontStyle: 'italic',
|
|
50
|
+
},
|
|
51
|
+
u: {
|
|
52
|
+
textDecoration: 'underline',
|
|
53
|
+
},
|
|
54
|
+
'code, kbd, samp, pre': {
|
|
55
|
+
fontFamily: 'mono',
|
|
56
|
+
fontSize: '1em',
|
|
57
|
+
},
|
|
58
|
+
table: {
|
|
59
|
+
borderColor: 'border.subtle',
|
|
60
|
+
},
|
|
61
|
+
'button, input, optgroup, select, textarea': {
|
|
62
|
+
fontFamily: 'body',
|
|
63
|
+
fontSize: '100%',
|
|
64
|
+
lineHeight: 'calc(1em + 0.5rem)',
|
|
65
|
+
margin: '0',
|
|
66
|
+
},
|
|
67
|
+
'button, [type="button"], [type="reset"], [type="submit"]': {
|
|
68
|
+
'-webkit-appearance': 'button',
|
|
69
|
+
},
|
|
70
|
+
legend: {
|
|
71
|
+
padding: '0',
|
|
72
|
+
},
|
|
73
|
+
progress: {
|
|
74
|
+
verticalAlign: 'baseline',
|
|
75
|
+
},
|
|
76
|
+
'::-webkit-inner-spin-button, ::-webkit-outer-spin-button': {
|
|
77
|
+
height: 'auto',
|
|
78
|
+
},
|
|
79
|
+
'[type="search"]': {
|
|
80
|
+
'-webkit-appearance': 'textfield',
|
|
81
|
+
outlineOffset: '-2px',
|
|
82
|
+
},
|
|
83
|
+
'::-webkit-search-decoration': {
|
|
84
|
+
'-webkit-appearance': 'none',
|
|
85
|
+
},
|
|
86
|
+
'::-webkit-file-upload-button': {
|
|
87
|
+
'-webkit-appearance': 'button',
|
|
88
|
+
font: 'inherit',
|
|
89
|
+
},
|
|
90
|
+
summary: {
|
|
91
|
+
display: 'list-item',
|
|
92
|
+
},
|
|
93
|
+
});
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export * from './breakpoints';
|
|
2
|
+
export * from './conditions';
|
|
3
|
+
export * from './containerSizes';
|
|
4
|
+
export * from './filters';
|
|
5
|
+
export * from './globalStyle';
|
|
6
|
+
export * from './keyframes';
|
|
7
|
+
export * from './layerStyles';
|
|
8
|
+
export * from './textStyles';
|
|
9
|
+
export * from './transitions';
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
import { defineKeyframes } from '@pandacss/dev';
|
|
2
|
+
|
|
3
|
+
export const keyframes = defineKeyframes({
|
|
4
|
+
spin: {
|
|
5
|
+
to: {
|
|
6
|
+
transform: 'rotate(360deg)',
|
|
7
|
+
},
|
|
8
|
+
},
|
|
9
|
+
ping: {
|
|
10
|
+
'75%, 100%': {
|
|
11
|
+
transform: 'scale(2)',
|
|
12
|
+
opacity: '0',
|
|
13
|
+
},
|
|
14
|
+
},
|
|
15
|
+
pulse: {
|
|
16
|
+
'50%': {
|
|
17
|
+
opacity: '.5',
|
|
18
|
+
},
|
|
19
|
+
},
|
|
20
|
+
bounce: {
|
|
21
|
+
'0%, 100%': {
|
|
22
|
+
transform: 'translateY(-25%)',
|
|
23
|
+
animationTimingFunction: 'cubic-bezier(0.8,0,1,1)',
|
|
24
|
+
},
|
|
25
|
+
'50%': {
|
|
26
|
+
transform: 'none',
|
|
27
|
+
animationTimingFunction: 'cubic-bezier(0,0,0.2,1)',
|
|
28
|
+
},
|
|
29
|
+
},
|
|
30
|
+
badgePop: {
|
|
31
|
+
'0%': {
|
|
32
|
+
transform: 'translate(50%, -50%) scale(1)',
|
|
33
|
+
},
|
|
34
|
+
'50%': {
|
|
35
|
+
transform: 'translate(50%, -50%) scale(1.2)',
|
|
36
|
+
},
|
|
37
|
+
'100%': {
|
|
38
|
+
transform: 'translate(50%, -50%) scale(1)',
|
|
39
|
+
},
|
|
40
|
+
},
|
|
41
|
+
badgePopStandalone: {
|
|
42
|
+
'0%': {
|
|
43
|
+
transform: 'scale(1)',
|
|
44
|
+
},
|
|
45
|
+
'50%': {
|
|
46
|
+
transform: 'scale(1.2)',
|
|
47
|
+
},
|
|
48
|
+
'100%': {
|
|
49
|
+
transform: 'scale(1)',
|
|
50
|
+
},
|
|
51
|
+
},
|
|
52
|
+
slideLeft: {
|
|
53
|
+
'0%': { transform: 'translateX(100%)', opacity: '0' },
|
|
54
|
+
'100%': { transform: 'translateX(0)', opacity: '1' },
|
|
55
|
+
},
|
|
56
|
+
slideRight: {
|
|
57
|
+
'0%': { transform: 'translateX(-100%)', opacity: '0' },
|
|
58
|
+
'100%': { transform: 'translateX(0)', opacity: '1' },
|
|
59
|
+
},
|
|
60
|
+
// Modal animations
|
|
61
|
+
modalFadeIn: {
|
|
62
|
+
'0%': { opacity: '0' },
|
|
63
|
+
'100%': { opacity: '1' },
|
|
64
|
+
},
|
|
65
|
+
modalFadeOut: {
|
|
66
|
+
'0%': { opacity: '1' },
|
|
67
|
+
'100%': { opacity: '0' },
|
|
68
|
+
},
|
|
69
|
+
modalScaleIn: {
|
|
70
|
+
'0%': {
|
|
71
|
+
opacity: '0',
|
|
72
|
+
transform: 'translate(-50%, -50%) scale(0.95) translateY(-10px)',
|
|
73
|
+
},
|
|
74
|
+
'100%': {
|
|
75
|
+
opacity: '1',
|
|
76
|
+
transform: 'translate(-50%, -50%) scale(1) translateY(0)',
|
|
77
|
+
},
|
|
78
|
+
},
|
|
79
|
+
modalScaleOut: {
|
|
80
|
+
'0%': {
|
|
81
|
+
opacity: '1',
|
|
82
|
+
transform: 'translate(-50%, -50%) scale(1) translateY(0)',
|
|
83
|
+
},
|
|
84
|
+
'100%': {
|
|
85
|
+
opacity: '0',
|
|
86
|
+
transform: 'translate(-50%, -50%) scale(0.95) translateY(-10px)',
|
|
87
|
+
},
|
|
88
|
+
},
|
|
89
|
+
});
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { defineLayerStyles } from '@pandacss/dev';
|
|
2
|
+
|
|
3
|
+
export const layerStyles = defineLayerStyles({
|
|
4
|
+
surface: {
|
|
5
|
+
raised: {
|
|
6
|
+
value: {
|
|
7
|
+
background: 'surface.raised',
|
|
8
|
+
boxShadow: 'shadow.raised',
|
|
9
|
+
},
|
|
10
|
+
},
|
|
11
|
+
overlay: {
|
|
12
|
+
value: {
|
|
13
|
+
background: 'surface.overlay',
|
|
14
|
+
boxShadow: 'shadow.overlay',
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
},
|
|
18
|
+
});
|
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
import { defineTextStyles, defineStyles } from '@pandacss/dev';
|
|
2
|
+
|
|
3
|
+
const baseHeadingStyles = defineStyles({
|
|
4
|
+
value: {
|
|
5
|
+
fontFamily: 'sans',
|
|
6
|
+
fontWeight: 'bold',
|
|
7
|
+
color: 'text',
|
|
8
|
+
lineHeight: 'default',
|
|
9
|
+
},
|
|
10
|
+
});
|
|
11
|
+
|
|
12
|
+
const baseBodyTextStyles = defineStyles({
|
|
13
|
+
value: {
|
|
14
|
+
fontFamily: 'serif',
|
|
15
|
+
fontWeight: 'normal',
|
|
16
|
+
color: 'text.subtlest',
|
|
17
|
+
lineHeight: 'default',
|
|
18
|
+
},
|
|
19
|
+
});
|
|
20
|
+
|
|
21
|
+
const baseMonoStyles = defineStyles({
|
|
22
|
+
value: {
|
|
23
|
+
fontFamily: 'mono',
|
|
24
|
+
fontWeight: 'normal',
|
|
25
|
+
color: 'text.subtlest',
|
|
26
|
+
lineHeight: 'default',
|
|
27
|
+
},
|
|
28
|
+
});
|
|
29
|
+
|
|
30
|
+
export const textStyles = defineTextStyles({
|
|
31
|
+
display: {
|
|
32
|
+
lg: {
|
|
33
|
+
value: {
|
|
34
|
+
...baseHeadingStyles,
|
|
35
|
+
fontSize: '72',
|
|
36
|
+
},
|
|
37
|
+
},
|
|
38
|
+
md: {
|
|
39
|
+
value: {
|
|
40
|
+
...baseHeadingStyles,
|
|
41
|
+
fontSize: '64',
|
|
42
|
+
},
|
|
43
|
+
},
|
|
44
|
+
sm: {
|
|
45
|
+
value: {
|
|
46
|
+
...baseHeadingStyles,
|
|
47
|
+
fontSize: '56',
|
|
48
|
+
},
|
|
49
|
+
},
|
|
50
|
+
xs: {
|
|
51
|
+
value: {
|
|
52
|
+
...baseHeadingStyles,
|
|
53
|
+
fontSize: '48',
|
|
54
|
+
},
|
|
55
|
+
},
|
|
56
|
+
},
|
|
57
|
+
heading: {
|
|
58
|
+
lg: {
|
|
59
|
+
value: {
|
|
60
|
+
...baseHeadingStyles,
|
|
61
|
+
fontSize: '40',
|
|
62
|
+
},
|
|
63
|
+
},
|
|
64
|
+
md: {
|
|
65
|
+
value: {
|
|
66
|
+
...baseHeadingStyles,
|
|
67
|
+
fontSize: '32',
|
|
68
|
+
},
|
|
69
|
+
},
|
|
70
|
+
sm: {
|
|
71
|
+
value: {
|
|
72
|
+
...baseHeadingStyles,
|
|
73
|
+
fontSize: '24',
|
|
74
|
+
},
|
|
75
|
+
},
|
|
76
|
+
xs: {
|
|
77
|
+
value: {
|
|
78
|
+
...baseHeadingStyles,
|
|
79
|
+
fontSize: '20',
|
|
80
|
+
},
|
|
81
|
+
},
|
|
82
|
+
},
|
|
83
|
+
body: {
|
|
84
|
+
lg: {
|
|
85
|
+
value: {
|
|
86
|
+
...baseBodyTextStyles,
|
|
87
|
+
fontSize: '20',
|
|
88
|
+
},
|
|
89
|
+
},
|
|
90
|
+
md: {
|
|
91
|
+
value: {
|
|
92
|
+
...baseBodyTextStyles,
|
|
93
|
+
fontSize: '16',
|
|
94
|
+
},
|
|
95
|
+
},
|
|
96
|
+
sm: {
|
|
97
|
+
value: {
|
|
98
|
+
...baseBodyTextStyles,
|
|
99
|
+
fontSize: '14',
|
|
100
|
+
},
|
|
101
|
+
},
|
|
102
|
+
xs: {
|
|
103
|
+
value: {
|
|
104
|
+
...baseBodyTextStyles,
|
|
105
|
+
fontSize: '12',
|
|
106
|
+
},
|
|
107
|
+
},
|
|
108
|
+
},
|
|
109
|
+
mono: {
|
|
110
|
+
lg: {
|
|
111
|
+
value: {
|
|
112
|
+
...baseMonoStyles,
|
|
113
|
+
fontSize: '20',
|
|
114
|
+
},
|
|
115
|
+
},
|
|
116
|
+
md: {
|
|
117
|
+
value: {
|
|
118
|
+
...baseMonoStyles,
|
|
119
|
+
fontSize: '16',
|
|
120
|
+
},
|
|
121
|
+
},
|
|
122
|
+
sm: {
|
|
123
|
+
value: {
|
|
124
|
+
...baseMonoStyles,
|
|
125
|
+
fontSize: '14',
|
|
126
|
+
},
|
|
127
|
+
},
|
|
128
|
+
xs: {
|
|
129
|
+
value: {
|
|
130
|
+
...baseMonoStyles,
|
|
131
|
+
fontSize: '12',
|
|
132
|
+
},
|
|
133
|
+
},
|
|
134
|
+
},
|
|
135
|
+
});
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import { defineUtility } from '@pandacss/dev';
|
|
2
|
+
import { durations, easings } from '../primitives';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Transition property tokens for use with strictTokens.
|
|
6
|
+
* These are common CSS property combinations for transitions.
|
|
7
|
+
* Usage: transitionProperty: 'colors' or transitionProperty: 'transform'
|
|
8
|
+
*/
|
|
9
|
+
export const transitionProperties = {
|
|
10
|
+
none: {
|
|
11
|
+
value: 'none',
|
|
12
|
+
},
|
|
13
|
+
all: {
|
|
14
|
+
value: 'all',
|
|
15
|
+
},
|
|
16
|
+
common: {
|
|
17
|
+
value:
|
|
18
|
+
'background-color, border-color, color, fill, stroke, opacity, box-shadow, transform',
|
|
19
|
+
},
|
|
20
|
+
colors: {
|
|
21
|
+
value: 'background-color, border-color, color, fill, stroke',
|
|
22
|
+
},
|
|
23
|
+
opacity: {
|
|
24
|
+
value: 'opacity',
|
|
25
|
+
},
|
|
26
|
+
shadow: {
|
|
27
|
+
value: 'box-shadow',
|
|
28
|
+
},
|
|
29
|
+
transform: {
|
|
30
|
+
value: 'transform',
|
|
31
|
+
},
|
|
32
|
+
position: {
|
|
33
|
+
value: 'top, right, bottom, left',
|
|
34
|
+
},
|
|
35
|
+
size: {
|
|
36
|
+
value: 'width, height',
|
|
37
|
+
},
|
|
38
|
+
spacing: {
|
|
39
|
+
value: 'margin, padding',
|
|
40
|
+
},
|
|
41
|
+
outline: {
|
|
42
|
+
value: 'outline, outline-color, outline-offset',
|
|
43
|
+
},
|
|
44
|
+
border: {
|
|
45
|
+
value: 'border, border-color',
|
|
46
|
+
},
|
|
47
|
+
};
|
|
48
|
+
|
|
49
|
+
// Shorthands
|
|
50
|
+
export const transitions = {
|
|
51
|
+
none: {
|
|
52
|
+
value: 'none',
|
|
53
|
+
},
|
|
54
|
+
all: {
|
|
55
|
+
value: `${transitionProperties.all} ${durations.normal} ${easings.default}`,
|
|
56
|
+
},
|
|
57
|
+
common: {
|
|
58
|
+
value: `${transitionProperties.common} ${durations.normal} ${easings.default}`,
|
|
59
|
+
},
|
|
60
|
+
colors: {
|
|
61
|
+
value: `${transitionProperties.colors} ${durations.normal} ${easings.default}`,
|
|
62
|
+
},
|
|
63
|
+
opacity: {
|
|
64
|
+
value: `${transitionProperties.opacity} ${durations.normal} ${easings.default}`,
|
|
65
|
+
},
|
|
66
|
+
shadow: {
|
|
67
|
+
value: `${transitionProperties.shadow} ${durations.normal} ${easings.default}`,
|
|
68
|
+
},
|
|
69
|
+
transform: {
|
|
70
|
+
value: `${transitionProperties.transform} ${durations.normal} ${easings.default}`,
|
|
71
|
+
},
|
|
72
|
+
position: {
|
|
73
|
+
value: `${transitionProperties.position} ${durations.normal} ${easings.default}`,
|
|
74
|
+
},
|
|
75
|
+
size: {
|
|
76
|
+
value: `${transitionProperties.size} ${durations.normal} ${easings.default}`,
|
|
77
|
+
},
|
|
78
|
+
spacing: {
|
|
79
|
+
value: `${transitionProperties.spacing} ${durations.normal} ${easings.default}`,
|
|
80
|
+
},
|
|
81
|
+
outline: {
|
|
82
|
+
value: `${transitionProperties.outline} ${durations.normal} ${easings.default}`,
|
|
83
|
+
},
|
|
84
|
+
border: {
|
|
85
|
+
value: `${transitionProperties.border} ${durations.normal} ${easings.default}`,
|
|
86
|
+
},
|
|
87
|
+
};
|
|
88
|
+
|
|
89
|
+
export const transitionProperty = defineUtility({
|
|
90
|
+
className: 'transition-property',
|
|
91
|
+
values: 'transitions',
|
|
92
|
+
});
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
// The sprite content is auto-generated by generate-sprite.js
|
|
2
|
+
import { spriteContent } from './spriteContent';
|
|
3
|
+
|
|
4
|
+
let spriteInjected = false;
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Injects the SVG sprite into the DOM.
|
|
8
|
+
* This is called automatically when the first Icon is rendered.
|
|
9
|
+
* The sprite content is bundled with the library.
|
|
10
|
+
*/
|
|
11
|
+
export function injectSprite(): void {
|
|
12
|
+
if (spriteInjected || typeof document === 'undefined') return;
|
|
13
|
+
|
|
14
|
+
try {
|
|
15
|
+
// Create a container for the sprite
|
|
16
|
+
const container = document.createElement('div');
|
|
17
|
+
container.style.display = 'none';
|
|
18
|
+
container.setAttribute('aria-hidden', 'true');
|
|
19
|
+
container.innerHTML = spriteContent;
|
|
20
|
+
|
|
21
|
+
// Inject at the start of body
|
|
22
|
+
if (document.body) {
|
|
23
|
+
document.body.insertBefore(container, document.body.firstChild);
|
|
24
|
+
spriteInjected = true;
|
|
25
|
+
}
|
|
26
|
+
} catch (error) {
|
|
27
|
+
console.error('Error injecting sprite:', error);
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
* Reset the injection state (useful for testing)
|
|
33
|
+
*/
|
|
34
|
+
export function resetSpriteInjection(): void {
|
|
35
|
+
spriteInjected = false;
|
|
36
|
+
}
|