@nearform/quantum 1.8.0 → 1.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/README.md +19 -1
- package/dist/animations/index.d.ts +25 -0
- package/dist/animations/index.js +14 -37
- package/dist/animations/index.js.map +1 -1
- package/dist/assets/build/open-source.icon.d.ts +2 -0
- package/dist/assets/build/open-source.icon.js +7 -0
- package/dist/assets/build/open-source.icon.js.map +1 -0
- package/dist/assets/index.d.ts +13 -0
- package/dist/assets/index.js +29 -0
- package/dist/assets/index.js.map +1 -0
- package/dist/colors/accent.d.ts +16 -0
- package/dist/colors/accent.js +21 -0
- package/dist/colors/accent.js.map +1 -0
- package/dist/colors/background.d.ts +36 -0
- package/dist/colors/background.js +41 -0
- package/dist/colors/background.js.map +1 -0
- package/dist/colors/base.d.ts +136 -0
- package/dist/colors/base.js +140 -0
- package/dist/colors/base.js.map +1 -0
- package/dist/colors/border.d.ts +16 -0
- package/dist/colors/border.js +21 -0
- package/dist/colors/border.js.map +1 -0
- package/dist/colors/button.d.ts +106 -0
- package/dist/colors/button.js +115 -0
- package/dist/colors/button.js.map +1 -0
- package/dist/colors/feedback.d.ts +27 -0
- package/dist/colors/feedback.js +32 -0
- package/dist/colors/feedback.js.map +1 -0
- package/dist/colors/foreground.d.ts +35 -0
- package/dist/colors/foreground.js +40 -0
- package/dist/colors/foreground.js.map +1 -0
- package/dist/colors/index.d.ts +351 -0
- package/dist/colors/index.js +13 -416
- package/dist/colors/index.js.map +1 -1
- package/dist/components/Accordion/index.d.ts +13 -0
- package/dist/components/Accordion/index.js +97 -0
- package/dist/components/Accordion/index.js.map +1 -0
- package/dist/components/AppHeader/index.d.ts +21 -0
- package/dist/components/AppHeader/index.js +98 -0
- package/dist/components/AppHeader/index.js.map +1 -0
- package/dist/components/Avatar/index.d.ts +30 -0
- package/dist/components/Avatar/index.js +116 -0
- package/dist/components/Avatar/index.js.map +1 -0
- package/dist/components/BackLink/index.d.ts +9 -0
- package/dist/components/BackLink/index.js +80 -0
- package/dist/components/BackLink/index.js.map +1 -0
- package/dist/components/Badge/index.d.ts +48 -0
- package/dist/components/Badge/index.js +160 -0
- package/dist/components/Badge/index.js.map +1 -0
- package/dist/components/Breadcrumb/index.d.ts +13 -0
- package/dist/components/Breadcrumb/index.js +90 -0
- package/dist/components/Breadcrumb/index.js.map +1 -0
- package/dist/components/Button/index.d.ts +17 -0
- package/dist/components/Button/index.js +204 -0
- package/dist/components/Button/index.js.map +1 -0
- package/dist/components/ButtonGroup/index.d.ts +11 -0
- package/dist/components/ButtonGroup/index.js +102 -0
- package/dist/components/ButtonGroup/index.js.map +1 -0
- package/dist/components/Calendar/index.d.ts +8 -0
- package/dist/components/Calendar/index.js +146 -0
- package/dist/components/Calendar/index.js.map +1 -0
- package/dist/components/Card/index.d.ts +28 -0
- package/dist/components/Card/index.js +155 -0
- package/dist/components/Card/index.js.map +1 -0
- package/dist/components/Chat/index.d.ts +39 -0
- package/dist/components/Chat/index.js +100 -0
- package/dist/components/Chat/index.js.map +1 -0
- package/dist/components/Checkbox/index.d.ts +5 -0
- package/dist/components/Checkbox/index.js +128 -0
- package/dist/components/Checkbox/index.js.map +1 -0
- package/dist/components/CheckboxGroup/CheckboxGroup.d.ts +61 -0
- package/dist/components/CheckboxGroup/CheckboxGroup.js +107 -0
- package/dist/components/CheckboxGroup/CheckboxGroup.js.map +1 -0
- package/dist/components/CheckboxGroup/CheckboxGroupItem.d.ts +19 -0
- package/dist/components/CheckboxGroup/CheckboxGroupItem.js +83 -0
- package/dist/components/CheckboxGroup/CheckboxGroupItem.js.map +1 -0
- package/dist/components/CheckboxGroup/index.d.ts +2 -0
- package/dist/components/CheckboxGroup/index.js +9 -0
- package/dist/components/CheckboxGroup/index.js.map +1 -0
- package/dist/components/Chip/index.d.ts +11 -0
- package/dist/components/Chip/index.js +105 -0
- package/dist/components/Chip/index.js.map +1 -0
- package/dist/components/CodeBlock/index.d.ts +7 -0
- package/dist/components/CodeBlock/index.js +57 -0
- package/dist/components/CodeBlock/index.js.map +1 -0
- package/dist/components/ControlLabel/index.d.ts +13 -0
- package/dist/components/ControlLabel/index.js +83 -0
- package/dist/components/ControlLabel/index.js.map +1 -0
- package/dist/components/DateInput/index.d.ts +26 -0
- package/dist/components/DateInput/index.js +261 -0
- package/dist/components/DateInput/index.js.map +1 -0
- package/dist/components/DocsList/index.d.ts +18 -0
- package/dist/components/DocsList/index.js +125 -0
- package/dist/components/DocsList/index.js.map +1 -0
- package/dist/components/FormGroup/index.d.ts +121 -0
- package/dist/components/FormGroup/index.js +359 -0
- package/dist/components/FormGroup/index.js.map +1 -0
- package/dist/components/HeroButton/index.d.ts +17 -0
- package/dist/components/HeroButton/index.js +139 -0
- package/dist/components/HeroButton/index.js.map +1 -0
- package/dist/components/IconButton/index.d.ts +77 -0
- package/dist/components/IconButton/index.js +235 -0
- package/dist/components/IconButton/index.js.map +1 -0
- package/dist/components/Input/index.d.ts +27 -0
- package/dist/components/Input/index.js +179 -0
- package/dist/components/Input/index.js.map +1 -0
- package/dist/components/Label/index.d.ts +12 -0
- package/dist/components/Label/index.js +89 -0
- package/dist/components/Label/index.js.map +1 -0
- package/dist/components/Link/index.d.ts +8 -0
- package/dist/components/Link/index.js +40 -0
- package/dist/components/Link/index.js.map +1 -0
- package/dist/components/Modal/index.d.ts +26 -0
- package/dist/components/Modal/index.js +143 -0
- package/dist/components/Modal/index.js.map +1 -0
- package/dist/components/Navigation/index.d.ts +8 -0
- package/dist/components/Navigation/index.js +65 -0
- package/dist/components/Navigation/index.js.map +1 -0
- package/dist/components/Notice/index.d.ts +17 -0
- package/dist/components/Notice/index.js +134 -0
- package/dist/components/Notice/index.js.map +1 -0
- package/dist/components/PageHeader/index.d.ts +15 -0
- package/dist/components/PageHeader/index.js +90 -0
- package/dist/components/PageHeader/index.js.map +1 -0
- package/dist/components/Pagination/index.d.ts +17 -0
- package/dist/components/Pagination/index.js +118 -0
- package/dist/components/Pagination/index.js.map +1 -0
- package/dist/components/Password/index.d.ts +18 -0
- package/dist/components/Password/index.js +106 -0
- package/dist/components/Password/index.js.map +1 -0
- package/dist/components/Popover/index.d.ts +28 -0
- package/dist/components/Popover/index.js +97 -0
- package/dist/components/Popover/index.js.map +1 -0
- package/dist/components/Radio/RadioGroup.d.ts +42 -0
- package/dist/components/Radio/RadioGroup.js +82 -0
- package/dist/components/Radio/RadioGroup.js.map +1 -0
- package/dist/components/Radio/RadioGroupItem.d.ts +17 -0
- package/dist/components/Radio/RadioGroupItem.js +117 -0
- package/dist/components/Radio/RadioGroupItem.js.map +1 -0
- package/dist/components/Radio/index.d.ts +2 -0
- package/dist/components/Radio/index.js +8 -0
- package/dist/components/Radio/index.js.map +1 -0
- package/dist/components/Select/index.d.ts +19 -0
- package/dist/components/Select/index.js +206 -0
- package/dist/components/Select/index.js.map +1 -0
- package/dist/components/Slider/index.d.ts +18 -0
- package/dist/components/Slider/index.js +122 -0
- package/dist/components/Slider/index.js.map +1 -0
- package/dist/components/SortAndShow/index.d.ts +15 -0
- package/dist/components/SortAndShow/index.js +68 -0
- package/dist/components/SortAndShow/index.js.map +1 -0
- package/dist/components/SplitButton/index.d.ts +25 -0
- package/dist/components/SplitButton/index.js +224 -0
- package/dist/components/SplitButton/index.js.map +1 -0
- package/dist/components/Stats/index.d.ts +10 -0
- package/dist/components/Stats/index.js +63 -0
- package/dist/components/Stats/index.js.map +1 -0
- package/dist/components/Stepper/index.d.ts +23 -0
- package/dist/components/Stepper/index.js +142 -0
- package/dist/components/Stepper/index.js.map +1 -0
- package/dist/components/StepsIndicator/Step.d.ts +6 -0
- package/dist/components/StepsIndicator/Step.js +24 -0
- package/dist/components/StepsIndicator/Step.js.map +1 -0
- package/dist/components/StepsIndicator/StepsIndicator.d.ts +12 -0
- package/dist/components/StepsIndicator/StepsIndicator.js +67 -0
- package/dist/components/StepsIndicator/StepsIndicator.js.map +1 -0
- package/dist/components/StepsIndicator/index.d.ts +2 -0
- package/dist/components/StepsIndicator/index.js +19 -0
- package/dist/components/StepsIndicator/index.js.map +1 -0
- package/dist/components/Subnav/index.d.ts +14 -0
- package/dist/components/Subnav/index.js +94 -0
- package/dist/components/Subnav/index.js.map +1 -0
- package/dist/components/Switch/index.d.ts +4 -0
- package/dist/components/Switch/index.js +103 -0
- package/dist/components/Switch/index.js.map +1 -0
- package/dist/components/Table/index.d.ts +48 -0
- package/dist/components/Table/index.js +147 -0
- package/dist/components/Table/index.js.map +1 -0
- package/dist/components/Tabs/index.d.ts +16 -0
- package/dist/components/Tabs/index.js +168 -0
- package/dist/components/Tabs/index.js.map +1 -0
- package/dist/components/Textarea/index.d.ts +13 -0
- package/dist/components/Textarea/index.js +96 -0
- package/dist/components/Textarea/index.js.map +1 -0
- package/dist/components/Toast/index.d.ts +24 -0
- package/dist/components/Toast/index.js +171 -0
- package/dist/components/Toast/index.js.map +1 -0
- package/dist/components/ToggleList/index.d.ts +20 -0
- package/dist/components/ToggleList/index.js +68 -0
- package/dist/components/ToggleList/index.js.map +1 -0
- package/dist/components/Tooltip/index.d.ts +11 -0
- package/dist/components/Tooltip/index.js +66 -0
- package/dist/components/Tooltip/index.js.map +1 -0
- package/dist/components/WebsiteFooter/index.d.ts +23 -0
- package/dist/components/WebsiteFooter/index.js +113 -0
- package/dist/components/WebsiteFooter/index.js.map +1 -0
- package/dist/components/WebsiteHeader/index.d.ts +21 -0
- package/dist/components/WebsiteHeader/index.js +98 -0
- package/dist/components/WebsiteHeader/index.js.map +1 -0
- package/dist/components/choice-group.d.ts +109 -0
- package/dist/components/choice-group.js +200 -0
- package/dist/components/choice-group.js.map +1 -0
- package/dist/components/index.d.ts +49 -0
- package/dist/components/index.js +66 -0
- package/dist/components/index.js.map +1 -0
- package/dist/esm/animations/index.js +17 -0
- package/dist/esm/animations/index.js.map +1 -0
- package/dist/esm/colors/accent.js +18 -0
- package/dist/esm/colors/accent.js.map +1 -0
- package/dist/esm/colors/background.js +38 -0
- package/dist/esm/colors/background.js.map +1 -0
- package/dist/esm/colors/base.js +137 -0
- package/dist/esm/colors/base.js.map +1 -0
- package/dist/esm/colors/border.js +18 -0
- package/dist/esm/colors/border.js.map +1 -0
- package/dist/esm/colors/button.js +112 -0
- package/dist/esm/colors/button.js.map +1 -0
- package/dist/esm/colors/feedback.js +29 -0
- package/dist/esm/colors/feedback.js.map +1 -0
- package/dist/esm/colors/foreground.js +37 -0
- package/dist/esm/colors/foreground.js.map +1 -0
- package/dist/esm/colors/index.js +13 -0
- package/dist/esm/colors/index.js.map +1 -0
- package/dist/esm/package.json +1 -0
- package/dist/esm/tailwind-base.js +31 -0
- package/dist/esm/tailwind-base.js.map +1 -0
- package/dist/esm/tailwind-plugin.js +29 -0
- package/dist/esm/tailwind-plugin.js.map +1 -0
- package/dist/esm/theme.js +55 -0
- package/dist/esm/theme.js.map +1 -0
- package/dist/global.css +552 -485
- package/dist/index.d.ts +3 -1315
- package/dist/index.js +23 -6468
- package/dist/index.js.map +1 -1
- package/dist/lib/utils.d.ts +16 -0
- package/dist/lib/utils.js +23 -0
- package/dist/lib/utils.js.map +1 -0
- package/dist/tailwind-base.js +33 -0
- package/dist/tailwind-base.js.map +1 -0
- package/dist/tailwind-plugin.js +31 -497
- package/dist/tailwind-plugin.js.map +1 -1
- package/dist/theme.js +60 -0
- package/dist/theme.js.map +1 -0
- package/package.json +8 -11
- package/dist/animations/index.mjs +0 -8
- package/dist/animations/index.mjs.map +0 -1
- package/dist/chunk-36NLQKQR.mjs +0 -22
- package/dist/chunk-36NLQKQR.mjs.map +0 -1
- package/dist/chunk-3FFF7Q7C.mjs +0 -55
- package/dist/chunk-3FFF7Q7C.mjs.map +0 -1
- package/dist/chunk-GTI4HTES.mjs +0 -386
- package/dist/chunk-GTI4HTES.mjs.map +0 -1
- package/dist/colors/index.mjs +0 -8
- package/dist/colors/index.mjs.map +0 -1
- package/dist/global.css.map +0 -1
- package/dist/index.d.mts +0 -1315
- package/dist/index.mjs +0 -6043
- package/dist/index.mjs.map +0 -1
- package/dist/tailwind-plugin.mjs +0 -67
- package/dist/tailwind-plugin.mjs.map +0 -1
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { colors } from "./base.js";
|
|
2
|
+
export const background = {
|
|
3
|
+
DEFAULT: '#FFF',
|
|
4
|
+
dark: '#000',
|
|
5
|
+
alt: {
|
|
6
|
+
DEFAULT: colors.grey['100'],
|
|
7
|
+
dark: colors.grey['700']
|
|
8
|
+
},
|
|
9
|
+
subtle: {
|
|
10
|
+
DEFAULT: colors.grey['50'],
|
|
11
|
+
dark: colors.grey['800']
|
|
12
|
+
},
|
|
13
|
+
/**
|
|
14
|
+
* The resting fill of a container that sits on the page: a card, a popover,
|
|
15
|
+
* a table body, a dialog panel.
|
|
16
|
+
*
|
|
17
|
+
* It exists because `background` cannot play that role in both modes. In
|
|
18
|
+
* light the page is `background-alt` and `background` is a step off it, so a
|
|
19
|
+
* surface painted `background` reads as raised (1.10:1). In dark the page is
|
|
20
|
+
* `background` itself, so the same class paints the surface the colour of
|
|
21
|
+
* the page it sits on - 1.00:1, a container that is only a container because
|
|
22
|
+
* of its border.
|
|
23
|
+
*
|
|
24
|
+
* So the light value is `background`'s, unchanged, and the dark value is one
|
|
25
|
+
* step up from the page. That keeps the step `subtle` adds for a header or a
|
|
26
|
+
* zebra stripe (1.21:1 above this, against light's 1.05:1) and leaves `alt`
|
|
27
|
+
* free for the selected row, which would otherwise collide with the stripes.
|
|
28
|
+
*/
|
|
29
|
+
surface: {
|
|
30
|
+
DEFAULT: '#FFF',
|
|
31
|
+
dark: colors.grey['900']
|
|
32
|
+
},
|
|
33
|
+
inverse: {
|
|
34
|
+
DEFAULT: colors.grey['900'],
|
|
35
|
+
dark: '#FFF'
|
|
36
|
+
}
|
|
37
|
+
};
|
|
38
|
+
//# sourceMappingURL=background.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"background.js","sourceRoot":"","sources":["../../../src/colors/background.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAElC,MAAM,CAAC,MAAM,UAAU,GAAG;IACxB,OAAO,EAAE,MAAM;IACf,IAAI,EAAE,MAAM;IACZ,GAAG,EAAE;QACH,OAAO,EAAE,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC;QAC3B,IAAI,EAAE,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC;KACzB;IACD,MAAM,EAAE;QACN,OAAO,EAAE,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC;QAC1B,IAAI,EAAE,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC;KACzB;IACD;;;;;;;;;;;;;;;OAeG;IACH,OAAO,EAAE;QACP,OAAO,EAAE,MAAM;QACf,IAAI,EAAE,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC;KACzB;IACD,OAAO,EAAE;QACP,OAAO,EAAE,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC;QAC3B,IAAI,EAAE,MAAM;KACb;CACF,CAAA"}
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
export const colors = {
|
|
2
|
+
grey: {
|
|
3
|
+
50: '#F9FAFB',
|
|
4
|
+
100: '#F3F4F6',
|
|
5
|
+
200: '#E5E7EB',
|
|
6
|
+
300: '#D1D5DB',
|
|
7
|
+
400: '#9CA3AF',
|
|
8
|
+
500: '#6B7280',
|
|
9
|
+
600: '#4B5563',
|
|
10
|
+
700: '#374151',
|
|
11
|
+
800: '#1F2A37',
|
|
12
|
+
900: '#111928'
|
|
13
|
+
},
|
|
14
|
+
blue: {
|
|
15
|
+
50: '#F5FAFF',
|
|
16
|
+
100: '#E1EFFE',
|
|
17
|
+
200: '#C3DDFD',
|
|
18
|
+
300: '#A4CAFE',
|
|
19
|
+
400: '#76A9FA',
|
|
20
|
+
500: '#3F83F8',
|
|
21
|
+
600: '#2165E3',
|
|
22
|
+
700: '#1A56DB',
|
|
23
|
+
800: '#1E429F',
|
|
24
|
+
900: '#000E38'
|
|
25
|
+
},
|
|
26
|
+
red: {
|
|
27
|
+
50: '#FDF2F2',
|
|
28
|
+
100: '#FDE8E8',
|
|
29
|
+
200: '#FBD5D5',
|
|
30
|
+
300: '#F8B4B4',
|
|
31
|
+
400: '#F98080',
|
|
32
|
+
500: '#F05252',
|
|
33
|
+
600: '#E02424',
|
|
34
|
+
700: '#C81E1E',
|
|
35
|
+
800: '#9B1C1C',
|
|
36
|
+
900: '#771D1D'
|
|
37
|
+
},
|
|
38
|
+
orange: {
|
|
39
|
+
50: '#FFF8F1',
|
|
40
|
+
100: '#FEECDC',
|
|
41
|
+
200: '#FCD9BD',
|
|
42
|
+
300: '#FDBA8C',
|
|
43
|
+
400: '#FF8A4C',
|
|
44
|
+
500: '#FF5A1F',
|
|
45
|
+
600: '#D03801',
|
|
46
|
+
700: '#B43403',
|
|
47
|
+
800: '#8A2C0D',
|
|
48
|
+
900: '#771D1D'
|
|
49
|
+
},
|
|
50
|
+
yellow: {
|
|
51
|
+
50: '#FDFDEA',
|
|
52
|
+
100: '#FDF6B2',
|
|
53
|
+
200: '#FCE96A',
|
|
54
|
+
300: '#FACA15',
|
|
55
|
+
400: '#E3A008',
|
|
56
|
+
500: '#C27803',
|
|
57
|
+
600: '#9F580A',
|
|
58
|
+
700: '#8E4B10',
|
|
59
|
+
800: '#723B13',
|
|
60
|
+
900: '#633112'
|
|
61
|
+
},
|
|
62
|
+
green: {
|
|
63
|
+
50: '#F3FAF7',
|
|
64
|
+
100: '#DEF7EC',
|
|
65
|
+
200: '#BCF0DA',
|
|
66
|
+
300: '#84E1BC',
|
|
67
|
+
400: '#31C48D',
|
|
68
|
+
500: '#0E9F6E',
|
|
69
|
+
600: '#057A55',
|
|
70
|
+
700: '#046C4E',
|
|
71
|
+
800: '#03543F',
|
|
72
|
+
900: '#014737'
|
|
73
|
+
},
|
|
74
|
+
teal: {
|
|
75
|
+
50: '#EDFAFA',
|
|
76
|
+
100: '#D5F5F6',
|
|
77
|
+
200: '#AFECEF',
|
|
78
|
+
300: '#7EDCE2',
|
|
79
|
+
400: '#16BDCA',
|
|
80
|
+
500: '#0694A2',
|
|
81
|
+
600: '#047481',
|
|
82
|
+
700: '#036672',
|
|
83
|
+
800: '#05505C',
|
|
84
|
+
900: '#014451'
|
|
85
|
+
},
|
|
86
|
+
indigo: {
|
|
87
|
+
50: '#F0F5FF',
|
|
88
|
+
100: '#E5EDFF',
|
|
89
|
+
200: '#CDDBFE',
|
|
90
|
+
300: '#B4C6FC',
|
|
91
|
+
400: '#8DA2FB',
|
|
92
|
+
500: '#6875F5',
|
|
93
|
+
600: '#5850EC',
|
|
94
|
+
700: '#5145CD',
|
|
95
|
+
800: '#42389D',
|
|
96
|
+
900: '#362F78'
|
|
97
|
+
},
|
|
98
|
+
purple: {
|
|
99
|
+
50: '#F6F5FF',
|
|
100
|
+
100: '#EDEBFE',
|
|
101
|
+
200: '#DCD7FE',
|
|
102
|
+
300: '#CABFFD',
|
|
103
|
+
400: '#AC94FA',
|
|
104
|
+
500: '#8950FF',
|
|
105
|
+
600: '#7E3AF2',
|
|
106
|
+
700: '#6C2BD9',
|
|
107
|
+
800: '#5521B5',
|
|
108
|
+
900: '#4A1D96'
|
|
109
|
+
},
|
|
110
|
+
pink: {
|
|
111
|
+
50: '#FFF6F9',
|
|
112
|
+
100: '#FFF1F5',
|
|
113
|
+
200: '#FFE8EE',
|
|
114
|
+
300: '#FFD9E3',
|
|
115
|
+
400: '#FFBFD0',
|
|
116
|
+
500: '#FF9DB7',
|
|
117
|
+
600: '#FB7A9C',
|
|
118
|
+
700: '#D95477',
|
|
119
|
+
800: '#A02042',
|
|
120
|
+
900: '#731837'
|
|
121
|
+
},
|
|
122
|
+
brandMidnight: {
|
|
123
|
+
10: '#f4f8fa',
|
|
124
|
+
30: '#97a1b8',
|
|
125
|
+
50: '#526288',
|
|
126
|
+
80: '#0c3d60',
|
|
127
|
+
100: '#000e38'
|
|
128
|
+
},
|
|
129
|
+
brandGreen: {
|
|
130
|
+
10: '#e5fcf5',
|
|
131
|
+
30: '#b2f7e1',
|
|
132
|
+
50: '#78edc4',
|
|
133
|
+
80: '#32ebae',
|
|
134
|
+
100: '#03e5a4'
|
|
135
|
+
}
|
|
136
|
+
};
|
|
137
|
+
//# sourceMappingURL=base.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"base.js","sourceRoot":"","sources":["../../../src/colors/base.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,MAAM,GAAG;IACpB,IAAI,EAAE;QACJ,EAAE,EAAE,SAAS;QACb,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;KACf;IACD,IAAI,EAAE;QACJ,EAAE,EAAE,SAAS;QACb,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;KACf;IACD,GAAG,EAAE;QACH,EAAE,EAAE,SAAS;QACb,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;KACf;IACD,MAAM,EAAE;QACN,EAAE,EAAE,SAAS;QACb,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAA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SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;KACf;IACD,IAAI,EAAE;QACJ,EAAE,EAAE,SAAS;QACb,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;QACd,GAAG,EAAE,SAAS;KACf;IACD,aAAa,EAAE;QACb,EAAE,EAAE,SAAS;QACb,EAAE,EAAE,SAAS;QACb,EAAE,EAAE,SAAS;QACb,EAAE,EAAE,SAAS;QACb,GAAG,EAAE,SAAS;KACf;IACD,UAAU,EAAE;QACV,EAAE,EAAE,SAAS;QACb,EAAE,EAAE,SAAS;QACb,EAAE,EAAE,SAAS;QACb,EAAE,EAAE,SAAS;QACb,GAAG,EAAE,SAAS;KACf;CACF,CAAA"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { colors } from "./base.js";
|
|
2
|
+
export const border = {
|
|
3
|
+
DEFAULT: colors.brandMidnight['30'],
|
|
4
|
+
dark: colors.brandMidnight['50'],
|
|
5
|
+
hover: {
|
|
6
|
+
DEFAULT: colors.brandMidnight['50'],
|
|
7
|
+
dark: colors.brandMidnight['80']
|
|
8
|
+
},
|
|
9
|
+
focus: {
|
|
10
|
+
DEFAULT: colors.brandMidnight['80'],
|
|
11
|
+
dark: colors.grey['400']
|
|
12
|
+
},
|
|
13
|
+
subtle: {
|
|
14
|
+
DEFAULT: colors.brandMidnight['10'],
|
|
15
|
+
dark: colors.grey['700']
|
|
16
|
+
}
|
|
17
|
+
};
|
|
18
|
+
//# sourceMappingURL=border.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"border.js","sourceRoot":"","sources":["../../../src/colors/border.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAElC,MAAM,CAAC,MAAM,MAAM,GAAG;IACpB,OAAO,EAAE,MAAM,CAAC,aAAa,CAAC,IAAI,CAAC;IACnC,IAAI,EAAE,MAAM,CAAC,aAAa,CAAC,IAAI,CAAC;IAChC,KAAK,EAAE;QACL,OAAO,EAAE,MAAM,CAAC,aAAa,CAAC,IAAI,CAAC;QACnC,IAAI,EAAE,MAAM,CAAC,aAAa,CAAC,IAAI,CAAC;KACjC;IACD,KAAK,EAAE;QACL,OAAO,EAAE,MAAM,CAAC,aAAa,CAAC,IAAI,CAAC;QACnC,IAAI,EAAE,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC;KACzB;IACD,MAAM,EAAE;QACN,OAAO,EAAE,MAAM,CAAC,aAAa,CAAC,IAAI,CAAC;QACnC,IAAI,EAAE,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC;KACzB;CACF,CAAA"}
|
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
import { colors } from "./base.js";
|
|
2
|
+
import { accent } from "./accent.js";
|
|
3
|
+
import { background } from "./background.js";
|
|
4
|
+
import { border } from "./border.js";
|
|
5
|
+
import { feedback } from "./feedback.js";
|
|
6
|
+
export const button = {
|
|
7
|
+
primary: {
|
|
8
|
+
DEFAULT: accent.DEFAULT,
|
|
9
|
+
dark: accent.dark,
|
|
10
|
+
hover: {
|
|
11
|
+
DEFAULT: accent.hover.DEFAULT,
|
|
12
|
+
dark: accent.hover.dark
|
|
13
|
+
},
|
|
14
|
+
focus: {
|
|
15
|
+
DEFAULT: accent.focus.DEFAULT,
|
|
16
|
+
dark: accent.focus.dark
|
|
17
|
+
},
|
|
18
|
+
disabled: {
|
|
19
|
+
DEFAULT: background.subtle.DEFAULT,
|
|
20
|
+
dark: background.subtle.dark
|
|
21
|
+
},
|
|
22
|
+
selected: {
|
|
23
|
+
DEFAULT: colors.grey['100'],
|
|
24
|
+
dark: background.subtle.dark
|
|
25
|
+
}
|
|
26
|
+
},
|
|
27
|
+
secondary: {
|
|
28
|
+
DEFAULT: '#FFF',
|
|
29
|
+
dark: colors.grey['900'],
|
|
30
|
+
hover: {
|
|
31
|
+
DEFAULT: background.subtle.DEFAULT,
|
|
32
|
+
dark: background.subtle.dark
|
|
33
|
+
},
|
|
34
|
+
focus: {
|
|
35
|
+
DEFAULT: background.alt.DEFAULT,
|
|
36
|
+
dark: background.alt.dark
|
|
37
|
+
},
|
|
38
|
+
disabled: {
|
|
39
|
+
DEFAULT: background.subtle.DEFAULT,
|
|
40
|
+
dark: background.subtle.dark
|
|
41
|
+
},
|
|
42
|
+
border: {
|
|
43
|
+
DEFAULT: border.DEFAULT,
|
|
44
|
+
dark: border.dark,
|
|
45
|
+
hover: {
|
|
46
|
+
DEFAULT: border.hover.DEFAULT,
|
|
47
|
+
dark: border.hover.dark
|
|
48
|
+
},
|
|
49
|
+
focus: {
|
|
50
|
+
DEFAULT: border.DEFAULT,
|
|
51
|
+
dark: border.focus.dark
|
|
52
|
+
},
|
|
53
|
+
disabled: {
|
|
54
|
+
DEFAULT: border.subtle.DEFAULT,
|
|
55
|
+
dark: border.subtle.dark
|
|
56
|
+
},
|
|
57
|
+
selected: {
|
|
58
|
+
DEFAULT: colors.grey['100'],
|
|
59
|
+
dark: background.subtle.dark
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
},
|
|
63
|
+
tertiary: {
|
|
64
|
+
hover: {
|
|
65
|
+
DEFAULT: background.subtle.DEFAULT,
|
|
66
|
+
dark: background.subtle.dark
|
|
67
|
+
},
|
|
68
|
+
focus: {
|
|
69
|
+
DEFAULT: background.DEFAULT,
|
|
70
|
+
dark: colors.blue['900']
|
|
71
|
+
},
|
|
72
|
+
selected: {
|
|
73
|
+
DEFAULT: colors.grey['100'],
|
|
74
|
+
dark: background.subtle.dark
|
|
75
|
+
}
|
|
76
|
+
},
|
|
77
|
+
success: {
|
|
78
|
+
DEFAULT: colors.green['600'],
|
|
79
|
+
hover: {
|
|
80
|
+
DEFAULT: colors.green['700']
|
|
81
|
+
},
|
|
82
|
+
focus: {
|
|
83
|
+
DEFAULT: colors.green['800']
|
|
84
|
+
},
|
|
85
|
+
disabled: {
|
|
86
|
+
DEFAULT: colors.grey['50'],
|
|
87
|
+
dark: background.subtle.dark
|
|
88
|
+
},
|
|
89
|
+
selected: {
|
|
90
|
+
DEFAULT: colors.grey['100'],
|
|
91
|
+
dark: background.subtle.dark
|
|
92
|
+
}
|
|
93
|
+
},
|
|
94
|
+
danger: {
|
|
95
|
+
DEFAULT: feedback.error.DEFAULT,
|
|
96
|
+
hover: {
|
|
97
|
+
DEFAULT: colors.red['700']
|
|
98
|
+
},
|
|
99
|
+
focus: {
|
|
100
|
+
DEFAULT: colors.red['800']
|
|
101
|
+
},
|
|
102
|
+
disabled: {
|
|
103
|
+
DEFAULT: colors.grey['50'],
|
|
104
|
+
dark: background.subtle.dark
|
|
105
|
+
},
|
|
106
|
+
selected: {
|
|
107
|
+
DEFAULT: colors.grey['100'],
|
|
108
|
+
dark: background.subtle.dark
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
};
|
|
112
|
+
//# sourceMappingURL=button.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"button.js","sourceRoot":"","sources":["../../../src/colors/button.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAClC,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAA;AACpC,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAA;AAC5C,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAA;AACpC,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAA;AAExC,MAAM,CAAC,MAAM,MAAM,GAAG;IACpB,OAAO,EAAE;QACP,OAAO,EAAE,MAAM,CAAC,OAAO;QACvB,IAAI,EAAE,MAAM,CAAC,IAAI;QACjB,KAAK,EAAE;YACL,OAAO,EAAE,MAAM,CAAC,KAAK,CA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,KAAK,CAAC;SAC3B;QACD,KAAK,EAAE;YACL,OAAO,EAAE,MAAM,CAAC,GAAG,CAAC,KAAK,CAAC;SAC3B;QACD,QAAQ,EAAE;YACR,OAAO,EAAE,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC;YAC1B,IAAI,EAAE,UAAU,CAAC,MAAM,CAAC,IAAI;SAC7B;QACD,QAAQ,EAAE;YACR,OAAO,EAAE,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC;YAC3B,IAAI,EAAE,UAAU,CAAC,MAAM,CAAC,IAAI;SAC7B;KACF;CACF,CAAA"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { colors } from "./base.js";
|
|
2
|
+
/**
|
|
3
|
+
* Feedback colours named for the role they play rather than the hue they wear,
|
|
4
|
+
* so a control reaches for them by what it means, not what it looks like.
|
|
5
|
+
*
|
|
6
|
+
* `success`, `warning`, `danger` and `error` map to the green, yellow, orange
|
|
7
|
+
* and red ramps respectively. Renaming them spells the utility the variant asks
|
|
8
|
+
* for (`border-feedback-success`, `text-feedback-error`) instead of one that
|
|
9
|
+
* only describes the swatch under it.
|
|
10
|
+
*/
|
|
11
|
+
export const feedback = {
|
|
12
|
+
success: {
|
|
13
|
+
DEFAULT: colors.green['500'],
|
|
14
|
+
dark: colors.green['300']
|
|
15
|
+
},
|
|
16
|
+
warning: {
|
|
17
|
+
DEFAULT: colors.yellow['300'],
|
|
18
|
+
dark: colors.yellow['300']
|
|
19
|
+
},
|
|
20
|
+
danger: {
|
|
21
|
+
DEFAULT: colors.orange['400'],
|
|
22
|
+
dark: colors.orange['300']
|
|
23
|
+
},
|
|
24
|
+
error: {
|
|
25
|
+
DEFAULT: colors.red['700'],
|
|
26
|
+
dark: colors.red['300']
|
|
27
|
+
}
|
|
28
|
+
};
|
|
29
|
+
//# sourceMappingURL=feedback.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"feedback.js","sourceRoot":"","sources":["../../../src/colors/feedback.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAElC;;;;;;;;GAQG;AACH,MAAM,CAAC,MAAM,QAAQ,GAAG;IACtB,OAAO,EAAE;QACP,OAAO,EAAE,MAAM,CAAC,KAAK,CAAC,KAAK,CAAC;QAC5B,IAAI,EAAE,MAAM,CAAC,KAAK,CAAC,KAAK,CAAC;KAC1B;IACD,OAAO,EAAE;QACP,OAAO,EAAE,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC;QAC7B,IAAI,EAAE,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC;KAC3B;IACD,MAAM,EAAE;QACN,OAAO,EAAE,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC;QAC7B,IAAI,EAAE,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC;KAC3B;IACD,KAAK,EAAE;QACL,OAAO,EAAE,MAAM,CAAC,GAAG,CAAC,KAAK,CAAC;QAC1B,IAAI,EAAE,MAAM,CAAC,GAAG,CAAC,KAAK,CAAC;KACxB;CACF,CAAA"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { colors } from "./base.js";
|
|
2
|
+
/**
|
|
3
|
+
* Text colours.
|
|
4
|
+
*
|
|
5
|
+
* `DEFAULT` and `muted` are the body-text tokens: both clear WCAG AA's 4.5:1
|
|
6
|
+
* on `background`, `background-alt` and `background-subtle`, in both modes
|
|
7
|
+
* (`background-inverse` takes `inverse`). `muted` sits at
|
|
8
|
+
* `grey-600` rather than `grey-500` because `grey-500` on `background-alt`
|
|
9
|
+
* (`grey-100`) is 4.39:1 — the pair `SelectTrigger` renders for its
|
|
10
|
+
* placeholder, and `Pagination` for its page numbers.
|
|
11
|
+
*
|
|
12
|
+
* `subtle` is not a body-text token. At `grey-500` it clears 4.5:1 on
|
|
13
|
+
* `background` (4.83:1) and `background-subtle` (4.63:1) but not on
|
|
14
|
+
* `background-alt` (4.39:1), and its dark half is 2.13:1 on
|
|
15
|
+
* `background-alt-dark`. Darkening it again would land it on `grey-600` and
|
|
16
|
+
* collapse it into `muted`, so it stays where it is and is scoped to the uses
|
|
17
|
+
* 1.4.3 exempts or that only owe 3:1 under 1.4.11: disabled control text
|
|
18
|
+
* (Button, ButtonGroup, Chip), Switch's track, and StepsIndicator's dots. Text
|
|
19
|
+
* that a user reads takes `muted`.
|
|
20
|
+
*/
|
|
21
|
+
export const foreground = {
|
|
22
|
+
DEFAULT: colors.grey['900'],
|
|
23
|
+
dark: '#FFF',
|
|
24
|
+
muted: {
|
|
25
|
+
DEFAULT: colors.grey['600'],
|
|
26
|
+
dark: colors.grey['300']
|
|
27
|
+
},
|
|
28
|
+
subtle: {
|
|
29
|
+
DEFAULT: colors.grey['500'],
|
|
30
|
+
dark: colors.grey['500']
|
|
31
|
+
},
|
|
32
|
+
inverse: {
|
|
33
|
+
DEFAULT: '#FFF',
|
|
34
|
+
dark: colors.grey['900']
|
|
35
|
+
}
|
|
36
|
+
};
|
|
37
|
+
//# sourceMappingURL=foreground.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"foreground.js","sourceRoot":"","sources":["../../../src/colors/foreground.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAElC;;;;;;;;;;;;;;;;;;GAkBG;AACH,MAAM,CAAC,MAAM,UAAU,GAAG;IACxB,OAAO,EAAE,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC;IAC3B,IAAI,EAAE,MAAM;IACZ,KAAK,EAAE;QACL,OAAO,EAAE,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC;QAC3B,IAAI,EAAE,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC;KACzB;IACD,MAAM,EAAE;QACN,OAAO,EAAE,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC;QAC3B,IAAI,EAAE,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC;KACzB;IACD,OAAO,EAAE;QACP,OAAO,EAAE,MAAM;QACf,IAAI,EAAE,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC;KACzB;CACF,CAAA"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { colors } from "./base.js";
|
|
2
|
+
import { foreground } from "./foreground.js";
|
|
3
|
+
import { background } from "./background.js";
|
|
4
|
+
import { button } from "./button.js";
|
|
5
|
+
import { accent } from "./accent.js";
|
|
6
|
+
import { border } from "./border.js";
|
|
7
|
+
import { feedback } from "./feedback.js";
|
|
8
|
+
export default Object.assign({ transparent: 'transparent', current: 'currentColor', primary: colors.brandMidnight, secondary: colors.brandGreen, foreground: foreground, background: background, accent: accent, border: border, feedback: feedback, button: button, white: {
|
|
9
|
+
DEFAULT: '#fff'
|
|
10
|
+
}, black: {
|
|
11
|
+
DEFAULT: '#000'
|
|
12
|
+
} }, colors);
|
|
13
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/colors/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAClC,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAA;AAC5C,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAA;AAC5C,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAA;AACpC,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAA;AACpC,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAA;AACpC,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAA;AAExC,+BACE,WAAW,EAAE,aAAa,EAC1B,OAAO,EAAE,cAAc,EACvB,OAAO,EAAE,MAAM,CAAC,aAAa,EAC7B,SAAS,EAAE,MAAM,CAAC,UAAU,EAC5B,UAAU,EAAE,UAAU,EACtB,UAAU,EAAE,UAAU,EACtB,MAAM,EAAE,MAAM,EACd,MAAM,EAAE,MAAM,EACd,QAAQ,EAAE,QAAQ,EAClB,MAAM,EAAE,MAAM,EACd,KAAK,EAAE;QACL,OAAO,EAAE,MAAM;KAChB,EACD,KAAK,EAAE;QACL,OAAO,EAAE,MAAM;KAChB,IACE,MAAM,EACV"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{ "type": "module" }
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Base styles Quantum adds on top of Tailwind's preflight.
|
|
3
|
+
*
|
|
4
|
+
* v3's preflight carried `button, [role="button"] { cursor: pointer }`. v4
|
|
5
|
+
* dropped that rule — its preflight declares no `cursor` on buttons at all — so
|
|
6
|
+
* buttons fall back to the UA default and every one of them becomes an arrow on
|
|
7
|
+
* upgrade. Only `Button` and `Switch` set the cursor themselves (`Link` does
|
|
8
|
+
* too, but on an `<a>`); the other eighteen render sites in `src/` — Chip,
|
|
9
|
+
* Pagination, Password, Input, StepsIndicator, Modal, Checkbox, Radio, Select's
|
|
10
|
+
* trigger, Popover, Tooltip and Calendar's day and nav buttons — do not.
|
|
11
|
+
* Several have no reachable `className` hook, so this is the fix the v4 upgrade
|
|
12
|
+
* guide recommends rather than a class on each one.
|
|
13
|
+
*
|
|
14
|
+
* It must stay in a cascade layer. `button:not(:disabled)` is specificity
|
|
15
|
+
* (0,1,1) and `.cursor-default` is (0,1,0), so unlayered it would outrank the
|
|
16
|
+
* utility and take the arrow away from Accordion's trigger, which sets
|
|
17
|
+
* `cursor-default` deliberately. Registered through `addBase` precisely so
|
|
18
|
+
* Tailwind puts it in `base`, below `utilities`.
|
|
19
|
+
*
|
|
20
|
+
* Kept as a plain object with no imports so both `scripts/theme-css.ts` (which
|
|
21
|
+
* renders it into the `@layer base` block of `src/quantum.css`, reaching
|
|
22
|
+
* `dist/global.css` and the Storybook preview) and `src/tailwind-plugin.ts`
|
|
23
|
+
* (which reaches consumers' own Tailwind builds through `addBase`) can register
|
|
24
|
+
* it without importing each other.
|
|
25
|
+
*/
|
|
26
|
+
export default {
|
|
27
|
+
'button:not(:disabled), [role="button"]:not(:disabled)': {
|
|
28
|
+
cursor: 'pointer'
|
|
29
|
+
}
|
|
30
|
+
};
|
|
31
|
+
//# sourceMappingURL=tailwind-base.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tailwind-base.js","sourceRoot":"","sources":["../../src/tailwind-base.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,eAAe;IACb,uDAAuD,EAAE;QACvD,MAAM,EAAE,SAAS;KAClB;CACF,CAAA"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import plugin from 'tailwindcss/plugin';
|
|
2
|
+
import baseStyles from "./tailwind-base.js";
|
|
3
|
+
import quantumTheme from "./theme.js";
|
|
4
|
+
/**
|
|
5
|
+
* Supplies the Quantum design tokens (colors, shadows, fonts, stroke widths and
|
|
6
|
+
* animations) to a consuming Tailwind build.
|
|
7
|
+
*
|
|
8
|
+
* Quantum's own stylesheets get the same tokens from the native `@theme` block
|
|
9
|
+
* in `src/quantum.css`, but a consumer on any of the README's Tailwind routes
|
|
10
|
+
* has no entrypoint of ours to import — they load this plugin from their own
|
|
11
|
+
* CSS or JS config — so the tokens have to be reachable as a JS object too.
|
|
12
|
+
* Both are rendered from `src/theme.ts`, and `__tests__/theme-css.test.ts`
|
|
13
|
+
* fails if they disagree.
|
|
14
|
+
*
|
|
15
|
+
* Tailwind v4 replaced the `content` array with source detection, so this plugin
|
|
16
|
+
* does not register Quantum's own files for scanning. Consumers must point at
|
|
17
|
+
* the package themselves — see the "Tailwind setup" section of the README.
|
|
18
|
+
*
|
|
19
|
+
* The base styles are registered here for the same reason: a consumer using
|
|
20
|
+
* `@plugin` or `plugins: [quantumPlugin]` never imports `dist/global.css`, so
|
|
21
|
+
* the `@layer base` block in `src/quantum.css` would not reach them. `addBase`
|
|
22
|
+
* is what puts them in the `base` layer, below `utilities`.
|
|
23
|
+
*/
|
|
24
|
+
export default plugin(({ addBase }) => {
|
|
25
|
+
addBase(baseStyles);
|
|
26
|
+
}, {
|
|
27
|
+
theme: Object.assign({}, quantumTheme)
|
|
28
|
+
});
|
|
29
|
+
//# sourceMappingURL=tailwind-plugin.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tailwind-plugin.js","sourceRoot":"","sources":["../../src/tailwind-plugin.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,oBAAoB,CAAA;AACvC,OAAO,UAAU,MAAM,oBAAoB,CAAA;AAC3C,OAAO,YAAY,MAAM,YAAY,CAAA;AAErC;;;;;;;;;;;;;;;;;;;GAmBG;AACH,eAAe,MAAM,CACnB,CAAC,EAAE,OAAO,EAAE,EAAE,EAAE;IACd,OAAO,CAAC,UAAU,CAAC,CAAA;AACrB,CAAC,EACD;IACE,KAAK,oBACA,YAAY,CAChB;CACF,CACF,CAAA"}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import defaultTheme from 'tailwindcss/defaultTheme';
|
|
2
|
+
import animations from "./animations/index.js";
|
|
3
|
+
import colors from "./colors/index.js";
|
|
4
|
+
/**
|
|
5
|
+
* The Quantum design tokens, in Tailwind's JS theme shape.
|
|
6
|
+
*
|
|
7
|
+
* This is the source of truth for the token *values*. Two consumers read it:
|
|
8
|
+
*
|
|
9
|
+
* - `scripts/theme-css.ts` renders it into the native v4 `@theme` block committed at
|
|
10
|
+
* `src/quantum.css`, which is what `src/global.css` and `.storybook/global.css`
|
|
11
|
+
* compile against. `__tests__/theme-css.test.ts` fails if the committed CSS
|
|
12
|
+
* drifts from this object; `npm run build:theme` regenerates it.
|
|
13
|
+
* - `src/tailwind-plugin.ts` hands it to consumers whose Tailwind build loads a
|
|
14
|
+
* JS plugin, where there is no CSS entrypoint of ours to carry an `@theme`.
|
|
15
|
+
*
|
|
16
|
+
* It cannot be CSS-only: `src/colors` is re-exported from the package root, so
|
|
17
|
+
* the token objects are public API regardless of what the stylesheet does.
|
|
18
|
+
*
|
|
19
|
+
* `colors`, `boxShadow`, `fontFamily` and `strokeWidth` sit outside `extend`, so
|
|
20
|
+
* they *replace* Tailwind's defaults rather than merging with them. `@theme`
|
|
21
|
+
* merges by default, which is why `scripts/theme-css.ts` emits a `--<namespace>-*:
|
|
22
|
+
* initial` reset for each of these four before listing the tokens.
|
|
23
|
+
*/
|
|
24
|
+
export default {
|
|
25
|
+
colors,
|
|
26
|
+
boxShadow: {
|
|
27
|
+
sm: '0px 1px 2px 0px rgba(0, 0, 0, 0.05)',
|
|
28
|
+
DEFAULT: '0px 1px 2px -1px rgba(0, 0, 0, 0.05)',
|
|
29
|
+
md: '0px 2px 4px -2px rgba(0, 0, 0, 0.05)',
|
|
30
|
+
lg: '0px 4px 6px 0px rgba(0, 0, 0, 0.05)',
|
|
31
|
+
xl: '0px 20px 25px -5px rgba(0, 0, 0, 0.05)',
|
|
32
|
+
'2xl': '0px 25px 50px -12px rgba(0, 0, 0, 0.05)',
|
|
33
|
+
blue: '0px 0px 0px 4px rgb(118,169,250)',
|
|
34
|
+
red: '0px 0px 0px 4px rgb(249,128,128)',
|
|
35
|
+
green: '0px 0px 0px 4px rgb(49,196,141,1)',
|
|
36
|
+
brandGreen: '0px 0px 0px 4px #03e5a4',
|
|
37
|
+
brandGreen10: '0px 0px 0px 4px #e5fcf5',
|
|
38
|
+
none: '0px 0px'
|
|
39
|
+
},
|
|
40
|
+
fontFamily: {
|
|
41
|
+
sans: ["'Inter'", ...defaultTheme.fontFamily.sans]
|
|
42
|
+
},
|
|
43
|
+
strokeWidth: {
|
|
44
|
+
0: '0px',
|
|
45
|
+
1: '1px',
|
|
46
|
+
2: '2px',
|
|
47
|
+
3: '4px',
|
|
48
|
+
4: '6px'
|
|
49
|
+
},
|
|
50
|
+
extend: {
|
|
51
|
+
keyframes: animations.keyframes,
|
|
52
|
+
animation: animations.animation
|
|
53
|
+
}
|
|
54
|
+
};
|
|
55
|
+
//# sourceMappingURL=theme.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"theme.js","sourceRoot":"","sources":["../../src/theme.ts"],"names":[],"mappings":"AAAA,OAAO,YAAY,MAAM,0BAA0B,CAAA;AACnD,OAAO,UAAU,MAAM,uBAAuB,CAAA;AAC9C,OAAO,MAAM,MAAM,mBAAmB,CAAA;AAEtC;;;;;;;;;;;;;;;;;;;GAmBG;AACH,eAAe;IACb,MAAM;IACN,SAAS,EAAE;QACT,EAAE,EAAE,qCAAqC;QACzC,OAAO,EAAE,sCAAsC;QAC/C,EAAE,EAAE,sCAAsC;QAC1C,EAAE,EAAE,qCAAqC;QACzC,EAAE,EAAE,wCAAwC;QAC5C,KAAK,EAAE,yCAAyC;QAChD,IAAI,EAAE,kCAAkC;QACxC,GAAG,EAAE,kCAAkC;QACvC,KAAK,EAAE,mCAAmC;QAC1C,UAAU,EAAE,yBAAyB;QACrC,YAAY,EAAE,yBAAyB;QACvC,IAAI,EAAE,SAAS;KAChB;IACD,UAAU,EAAE;QACV,IAAI,EAAE,CAAC,SAAS,EAAE,GAAG,YAAY,CAAC,UAAU,CAAC,IAAI,CAAC;KACnD;IACD,WAAW,EAAE;QACX,CAAC,EAAE,KAAK;QACR,CAAC,EAAE,KAAK;QACR,CAAC,EAAE,KAAK;QACR,CAAC,EAAE,KAAK;QACR,CAAC,EAAE,KAAK;KACT;IACD,MAAM,EAAE;QACN,SAAS,EAAE,UAAU,CAAC,SAAS;QAC/B,SAAS,EAAE,UAAU,CAAC,SAAS;KAChC;CACF,CAAA"}
|