@reshape-biotech/design-system 0.0.22 → 0.0.23
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/dist/tailwind-safelist.d.ts +14 -0
- package/dist/tailwind-safelist.js +148 -0
- package/package.json +2 -2
- package/dist/tailwind-safelist.txt +0 -142
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export const textColors: string[];
|
|
2
|
+
export const iconColors: string[];
|
|
3
|
+
export const backgroundColors: string[];
|
|
4
|
+
export const borders: string[];
|
|
5
|
+
export const shadows: string[];
|
|
6
|
+
export const textSizes: string[];
|
|
7
|
+
export const fonts: string[];
|
|
8
|
+
export const badges: string[];
|
|
9
|
+
export const tooltips: string[];
|
|
10
|
+
export const sizes: string[];
|
|
11
|
+
export const display: string[];
|
|
12
|
+
export const rounded: string[];
|
|
13
|
+
export const tables: string[];
|
|
14
|
+
export const safelist: string[];
|
|
@@ -0,0 +1,148 @@
|
|
|
1
|
+
// Used to safelist classnames so we can add styles dynamic.
|
|
2
|
+
// This should include all the values used in the design system.
|
|
3
|
+
// Read more here: https://daisyui.com/blog/most-common-mistake-when-using-tailwind-css/
|
|
4
|
+
|
|
5
|
+
export const textColors = [
|
|
6
|
+
'text-primary',
|
|
7
|
+
'text-primary-inverse',
|
|
8
|
+
'text-secondary',
|
|
9
|
+
'text-secondary-inverse',
|
|
10
|
+
'text-tertiary',
|
|
11
|
+
'text-tertiary-inverse',
|
|
12
|
+
'text-accent',
|
|
13
|
+
'text-success',
|
|
14
|
+
'text-warning',
|
|
15
|
+
'text-danger'
|
|
16
|
+
];
|
|
17
|
+
|
|
18
|
+
export const iconColors = [
|
|
19
|
+
'text-icon-primary',
|
|
20
|
+
'text-icon-primary-inverse',
|
|
21
|
+
'text-icon-secondary',
|
|
22
|
+
'text-icon-tertiary',
|
|
23
|
+
'text-icon-accent',
|
|
24
|
+
'text-icon-success',
|
|
25
|
+
'text-icon-warning',
|
|
26
|
+
'text-icon-danger',
|
|
27
|
+
'text-icon-blue',
|
|
28
|
+
'text-icon-orange',
|
|
29
|
+
'text-icon-sky'
|
|
30
|
+
];
|
|
31
|
+
|
|
32
|
+
export const backgroundColors = [
|
|
33
|
+
'bg-surface',
|
|
34
|
+
'bg-surface-secondary',
|
|
35
|
+
'bg-base',
|
|
36
|
+
'bg-base-inverse',
|
|
37
|
+
'bg-neutral',
|
|
38
|
+
'bg-neutral-hover',
|
|
39
|
+
'bg-neutral-darker',
|
|
40
|
+
'bg-neutral-darker-hover',
|
|
41
|
+
'bg-neutral-inverse',
|
|
42
|
+
'bg-neutral-inverse-hover',
|
|
43
|
+
'bg-accent',
|
|
44
|
+
'bg-accent-hover',
|
|
45
|
+
'bg-accent-inverse',
|
|
46
|
+
'bg-accent-inverse-hover',
|
|
47
|
+
'bg-success',
|
|
48
|
+
'bg-success-hover',
|
|
49
|
+
'bg-success-inverse',
|
|
50
|
+
'bg-success-inverse-hover',
|
|
51
|
+
'bg-warning',
|
|
52
|
+
'bg-warning-hover',
|
|
53
|
+
'bg-warning-inverse',
|
|
54
|
+
'bg-warning-inverse-hover',
|
|
55
|
+
'bg-danger',
|
|
56
|
+
'bg-danger-hover',
|
|
57
|
+
'bg-danger-inverse',
|
|
58
|
+
'bg-danger-inverse-hover',
|
|
59
|
+
'bg-blue',
|
|
60
|
+
'bg-blue-hover',
|
|
61
|
+
'bg-orange',
|
|
62
|
+
'bg-orange-hover',
|
|
63
|
+
'bg-orange-inverse',
|
|
64
|
+
'bg-orange-inverse-hover',
|
|
65
|
+
'bg-sky',
|
|
66
|
+
'bg-sky-hover',
|
|
67
|
+
'bg-sky-inverse',
|
|
68
|
+
'bg-sky-inverse-hover'
|
|
69
|
+
];
|
|
70
|
+
|
|
71
|
+
export const borders = [
|
|
72
|
+
'border-static',
|
|
73
|
+
'border-interactive',
|
|
74
|
+
'border-hover',
|
|
75
|
+
'border-focus',
|
|
76
|
+
'border-danger'
|
|
77
|
+
];
|
|
78
|
+
|
|
79
|
+
export const shadows = [
|
|
80
|
+
'shadow',
|
|
81
|
+
'shadow-none',
|
|
82
|
+
'shadow-field',
|
|
83
|
+
'shadow-nav',
|
|
84
|
+
'shadow-calendar',
|
|
85
|
+
'shadow-container',
|
|
86
|
+
'shadow-panel',
|
|
87
|
+
'shadow-outline',
|
|
88
|
+
'shadow-focus'
|
|
89
|
+
];
|
|
90
|
+
|
|
91
|
+
export const textSizes = [
|
|
92
|
+
'text-xxs',
|
|
93
|
+
'text-xs',
|
|
94
|
+
'text-sm',
|
|
95
|
+
'text-md',
|
|
96
|
+
'text-lg',
|
|
97
|
+
'text-xl',
|
|
98
|
+
'text-2xl',
|
|
99
|
+
'text-3xl',
|
|
100
|
+
'text-4xl'
|
|
101
|
+
];
|
|
102
|
+
|
|
103
|
+
export const fonts = ['font-medium', 'font-semibold', 'font-bold'];
|
|
104
|
+
|
|
105
|
+
export const badges = [
|
|
106
|
+
'badge-neutral',
|
|
107
|
+
'badge-success',
|
|
108
|
+
'badge-warning',
|
|
109
|
+
'badge-progress',
|
|
110
|
+
'badge-error',
|
|
111
|
+
'badge-md',
|
|
112
|
+
'badge-sm'
|
|
113
|
+
];
|
|
114
|
+
|
|
115
|
+
export const tooltips = ['tooltip-top', 'tooltip-right', 'tooltip-bottom', 'tooltip-left'];
|
|
116
|
+
|
|
117
|
+
export const sizes = ['h-5', 'w-5', 'min-w-5', 'h-7', 'w-7', 'min-w-7'];
|
|
118
|
+
|
|
119
|
+
export const display = [
|
|
120
|
+
'flex',
|
|
121
|
+
'items-center',
|
|
122
|
+
'justify-center',
|
|
123
|
+
'flex-row',
|
|
124
|
+
'flex-col',
|
|
125
|
+
'px-2',
|
|
126
|
+
'py-1'
|
|
127
|
+
];
|
|
128
|
+
|
|
129
|
+
export const rounded = ['rounded-full', 'rounded'];
|
|
130
|
+
|
|
131
|
+
export const tables = ['table-fixed', 'table-auto'];
|
|
132
|
+
|
|
133
|
+
// Export all arrays as a single safelist
|
|
134
|
+
export const safelist = [
|
|
135
|
+
...textColors,
|
|
136
|
+
...iconColors,
|
|
137
|
+
...backgroundColors,
|
|
138
|
+
...borders,
|
|
139
|
+
...shadows,
|
|
140
|
+
...textSizes,
|
|
141
|
+
...fonts,
|
|
142
|
+
...badges,
|
|
143
|
+
...tooltips,
|
|
144
|
+
...sizes,
|
|
145
|
+
...display,
|
|
146
|
+
...rounded,
|
|
147
|
+
...tables
|
|
148
|
+
];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@reshape-biotech/design-system",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.23",
|
|
4
4
|
"scripts": {
|
|
5
5
|
"dev": "vite dev",
|
|
6
6
|
"build": "vite build && npm run package",
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
"./tokens": "./dist/tokens.js",
|
|
38
38
|
"./styles": "./dist/app.css",
|
|
39
39
|
"./tailwind": "./dist/tailwind.preset.js",
|
|
40
|
-
"./tailwind-safelist": "./dist/tailwind-safelist.
|
|
40
|
+
"./tailwind-safelist": "./dist/tailwind-safelist.js"
|
|
41
41
|
},
|
|
42
42
|
"peerDependencies": {
|
|
43
43
|
"svelte": "^5.0.0",
|
|
@@ -1,142 +0,0 @@
|
|
|
1
|
-
// Used to safelist classnames so we can add styles dynamic.
|
|
2
|
-
// This should include all the values used in the design system.
|
|
3
|
-
// Read more here: https://daisyui.com/blog/most-common-mistake-when-using-tailwind-css/
|
|
4
|
-
|
|
5
|
-
// Text colors
|
|
6
|
-
text-primary
|
|
7
|
-
text-primary-inverse
|
|
8
|
-
text-secondary
|
|
9
|
-
text-secondary-inverse
|
|
10
|
-
text-tertiary
|
|
11
|
-
text-tertiary-inverse
|
|
12
|
-
text-accent
|
|
13
|
-
text-success
|
|
14
|
-
text-warning
|
|
15
|
-
text-danger
|
|
16
|
-
|
|
17
|
-
// Icons
|
|
18
|
-
text-icon-primary
|
|
19
|
-
text-icon-primary-inverse
|
|
20
|
-
text-icon-secondary
|
|
21
|
-
text-icon-tertiary
|
|
22
|
-
text-icon-accent
|
|
23
|
-
text-icon-success
|
|
24
|
-
text-icon-warning
|
|
25
|
-
text-icon-danger
|
|
26
|
-
text-icon-blue
|
|
27
|
-
text-icon-orange
|
|
28
|
-
text-icon-sky
|
|
29
|
-
|
|
30
|
-
// Background colors
|
|
31
|
-
bg-surface
|
|
32
|
-
bg-surface-secondary
|
|
33
|
-
bg-base
|
|
34
|
-
bg-base-inverse
|
|
35
|
-
bg-neutral
|
|
36
|
-
bg-neutral-hover
|
|
37
|
-
bg-neutral-darker
|
|
38
|
-
bg-neutral-darker-hover
|
|
39
|
-
bg-neutral-inverse
|
|
40
|
-
bg-neutral-inverse-hover
|
|
41
|
-
bg-accent
|
|
42
|
-
bg-accent-hover
|
|
43
|
-
bg-accent-inverse
|
|
44
|
-
bg-accent-inverse-hover
|
|
45
|
-
bg-success
|
|
46
|
-
bg-success-hover
|
|
47
|
-
bg-success-inverse
|
|
48
|
-
bg-success-inverse-hover
|
|
49
|
-
bg-warning
|
|
50
|
-
bg-warning-hover
|
|
51
|
-
bg-warning-inverse
|
|
52
|
-
bg-warning-inverse-hover
|
|
53
|
-
bg-danger
|
|
54
|
-
bg-danger-hover
|
|
55
|
-
bg-danger-inverse
|
|
56
|
-
bg-danger-inverse-hover
|
|
57
|
-
bg-blue
|
|
58
|
-
bg-blue-hover
|
|
59
|
-
bg-orange
|
|
60
|
-
bg-orange-hover
|
|
61
|
-
bg-orange-inverse
|
|
62
|
-
bg-orange-inverse-hover
|
|
63
|
-
bg-sky
|
|
64
|
-
bg-sky-hover
|
|
65
|
-
bg-sky-inverse
|
|
66
|
-
bg-sky-inverse-hover
|
|
67
|
-
|
|
68
|
-
// Borders
|
|
69
|
-
border-static
|
|
70
|
-
border-interactive
|
|
71
|
-
border-hover
|
|
72
|
-
border-focus
|
|
73
|
-
border-danger
|
|
74
|
-
|
|
75
|
-
// Shadows
|
|
76
|
-
shadow
|
|
77
|
-
shadow-none
|
|
78
|
-
shadow-field
|
|
79
|
-
shadow-nav
|
|
80
|
-
shadow-calendar
|
|
81
|
-
shadow-container
|
|
82
|
-
shadow-panel
|
|
83
|
-
shadow-outline
|
|
84
|
-
shadow-focus
|
|
85
|
-
|
|
86
|
-
// Text Sizes
|
|
87
|
-
text-xxs
|
|
88
|
-
text-xs
|
|
89
|
-
text-sm
|
|
90
|
-
text-md
|
|
91
|
-
text-lg
|
|
92
|
-
text-xl
|
|
93
|
-
text-2xl
|
|
94
|
-
text-3xl
|
|
95
|
-
text-4xl
|
|
96
|
-
|
|
97
|
-
// Fonts
|
|
98
|
-
font-medium
|
|
99
|
-
font-semibold
|
|
100
|
-
font-bold
|
|
101
|
-
|
|
102
|
-
// Default tailwind classes. We need these to preload them, in case we use them in the design system. Only add classes that are used in the design system.
|
|
103
|
-
// Component custom styles
|
|
104
|
-
// badge style classnames
|
|
105
|
-
badge-neutral
|
|
106
|
-
badge-success
|
|
107
|
-
badge-warning
|
|
108
|
-
badge-progress
|
|
109
|
-
badge-error
|
|
110
|
-
badge-md
|
|
111
|
-
badge-sm
|
|
112
|
-
|
|
113
|
-
// Tooltips
|
|
114
|
-
tooltip-top
|
|
115
|
-
tooltip-right
|
|
116
|
-
tooltip-bottom
|
|
117
|
-
tooltip-left
|
|
118
|
-
|
|
119
|
-
// Sizes
|
|
120
|
-
h-5
|
|
121
|
-
w-5
|
|
122
|
-
min-w-5
|
|
123
|
-
h-7
|
|
124
|
-
w-7
|
|
125
|
-
min-w-7
|
|
126
|
-
|
|
127
|
-
// Display values
|
|
128
|
-
flex
|
|
129
|
-
items-center
|
|
130
|
-
justify-center
|
|
131
|
-
flex-row
|
|
132
|
-
flex-col
|
|
133
|
-
px-2
|
|
134
|
-
py-1
|
|
135
|
-
|
|
136
|
-
// Rounded values
|
|
137
|
-
rounded-full
|
|
138
|
-
rounded
|
|
139
|
-
|
|
140
|
-
// Tables
|
|
141
|
-
table-fixed
|
|
142
|
-
table-auto
|