@sk-web-gui/core 0.1.23 → 0.1.26
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 +2 -2
- package/src/components/accordion.js +5 -1
- package/src/components/alert.js +2 -2
- package/src/components/badge.js +1 -1
- package/src/components/breadcrumb.js +2 -2
- package/src/components/button.js +3 -3
- package/src/components/calendar.js +81 -0
- package/src/components/card.js +2 -2
- package/src/components/checkbox.js +2 -2
- package/src/components/code.js +1 -1
- package/src/components/cookie-consent.js +4 -0
- package/src/components/forms.js +14 -6
- package/src/components/kbd.js +2 -2
- package/src/components/link.js +5 -10
- package/src/components/message.js +11 -17
- package/src/components/notification.js +2 -2
- package/src/components/pagination.js +3 -3
- package/src/components/radio.js +2 -2
- package/src/components/switch.js +10 -0
- package/src/components/tag.js +5 -5
- package/src/components/user-menu.js +2 -2
- package/src/components/zebratable.js +6 -2
- package/src/index.js +5 -11
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sk-web-gui/core",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.26",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"main": "src/index.js",
|
|
6
6
|
"files": [
|
|
@@ -31,5 +31,5 @@
|
|
|
31
31
|
"postcss-import": "^14.0.2",
|
|
32
32
|
"tailwindcss": "^2.2.4"
|
|
33
33
|
},
|
|
34
|
-
"gitHead": "
|
|
34
|
+
"gitHead": "52b6dd676c9ab6d2ab1b6de1fd130de9a19353dc"
|
|
35
35
|
}
|
package/src/components/alert.js
CHANGED
|
@@ -2,7 +2,7 @@ function alertSubtle(colors) {
|
|
|
2
2
|
return {
|
|
3
3
|
".alert-subtle": {
|
|
4
4
|
"@apply border rounded-base": {},
|
|
5
|
-
"@apply text-
|
|
5
|
+
"@apply text-body": {},
|
|
6
6
|
|
|
7
7
|
...colors.reduce(
|
|
8
8
|
(styles, color) => ({
|
|
@@ -47,7 +47,7 @@ function alertLeftAccent(colors) {
|
|
|
47
47
|
return {
|
|
48
48
|
".alert-left-accent": {
|
|
49
49
|
"@apply border-l-2 rounded-none": {},
|
|
50
|
-
"@apply text-
|
|
50
|
+
"@apply text-body": {},
|
|
51
51
|
|
|
52
52
|
...colors.reduce(
|
|
53
53
|
(styles, color) => ({
|
package/src/components/badge.js
CHANGED
|
@@ -3,7 +3,7 @@ module.exports = Badge = (colors) => ({
|
|
|
3
3
|
"@apply inline-block text-xs font-medium leading-4 text-center whitespace-nowrap": {},
|
|
4
4
|
|
|
5
5
|
"&-light": {
|
|
6
|
-
"@apply text-
|
|
6
|
+
"@apply text-body bg-neutral-200 border border-transparent": {},
|
|
7
7
|
"@apply dark:text-neutral-100 dark:bg-neutral-700": {},
|
|
8
8
|
|
|
9
9
|
...colors.reduce(
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
module.exports = Breadcrumb = () => ({
|
|
2
2
|
".breadcrumb": {
|
|
3
|
-
"@apply relative": {},
|
|
3
|
+
"@apply text-body relative": {},
|
|
4
4
|
|
|
5
5
|
"&-item": {
|
|
6
6
|
"@apply inline-flex items-center whitespace-nowrap": {},
|
|
7
7
|
},
|
|
8
8
|
|
|
9
9
|
"&-separator": {
|
|
10
|
-
"@apply mx-2
|
|
10
|
+
"@apply mx-2": {},
|
|
11
11
|
},
|
|
12
12
|
},
|
|
13
13
|
});
|
package/src/components/button.js
CHANGED
|
@@ -73,7 +73,7 @@ function buttonOutline(colors) {
|
|
|
73
73
|
return {
|
|
74
74
|
"&-outline": {
|
|
75
75
|
"@apply border border-neutral-200": {},
|
|
76
|
-
"@apply text-
|
|
76
|
+
"@apply text-body bg-transparent": {},
|
|
77
77
|
/* hover */
|
|
78
78
|
"@apply hover:bg-neutral-100 hover:border-neutral-300": {},
|
|
79
79
|
/* focus */
|
|
@@ -129,7 +129,7 @@ function buttonOutline(colors) {
|
|
|
129
129
|
function buttonGhost(colors) {
|
|
130
130
|
return {
|
|
131
131
|
"&-ghost": {
|
|
132
|
-
"@apply text-
|
|
132
|
+
"@apply text-body bg-transparent": {},
|
|
133
133
|
"@apply hover:bg-neutral-100": {},
|
|
134
134
|
/* focus */
|
|
135
135
|
"@apply focus-visible:z-base": {},
|
|
@@ -171,7 +171,7 @@ function buttonLight(colors) {
|
|
|
171
171
|
"&-light": {
|
|
172
172
|
"@apply shadow-sm": {},
|
|
173
173
|
"@apply border border-transparent": {},
|
|
174
|
-
"@apply text-
|
|
174
|
+
"@apply text-body bg-neutral-100": {},
|
|
175
175
|
/* hover */
|
|
176
176
|
"@apply hover:bg-neutral-200": {},
|
|
177
177
|
/* focus */
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
module.exports = Calendar = () => ({
|
|
2
|
+
|
|
3
|
+
// Month row
|
|
4
|
+
".MuiCalendarPicker-root > div:first-of-type": {
|
|
5
|
+
"@apply ml-2 -mr-2 px-10": {},
|
|
6
|
+
},
|
|
7
|
+
|
|
8
|
+
// Month
|
|
9
|
+
".MuiCalendarPicker-root > div:first-of-type > div": {
|
|
10
|
+
"@apply font-bold text-base text-body": {},
|
|
11
|
+
},
|
|
12
|
+
|
|
13
|
+
// Arrow switchers
|
|
14
|
+
".MuiCalendarPicker-root > div:first-of-type .MuiButtonBase-root .MuiSvgIcon-root": {
|
|
15
|
+
"@apply text-body text-lg": {},
|
|
16
|
+
},
|
|
17
|
+
".MuiCalendarPicker-root > div:first-of-type .MuiButtonBase-root": {
|
|
18
|
+
"@apply border-solid border border-transparent focus:text-transparent hover:text-transparent focus:bg-transparent hover:bg-transparent focus:border-primary hover:border-primary": {},
|
|
19
|
+
},
|
|
20
|
+
".MuiCalendarPicker-root > div:first-of-type .MuiButtonBase-root": {
|
|
21
|
+
"@apply border-solid border border-transparent focus:text-transparent hover:text-transparent focus:bg-transparent hover:bg-transparent focus:border-primary hover:border-primary": {},
|
|
22
|
+
},
|
|
23
|
+
// Arrow spacer
|
|
24
|
+
".MuiCalendarPicker-root .MuiPickersArrowSwitcher-spacer": {
|
|
25
|
+
"@apply w-11": {},
|
|
26
|
+
},
|
|
27
|
+
// Disabled arrow
|
|
28
|
+
".MuiCalendarPicker-root > div:first-of-type .MuiButtonBase-root[disabled] .MuiSvgIcon-root": {
|
|
29
|
+
"@apply text-gray-stroke": {},
|
|
30
|
+
},
|
|
31
|
+
|
|
32
|
+
// Weekdays
|
|
33
|
+
".MuiCalendarPicker-root div > div:first-of-type > .MuiTypography-root": {
|
|
34
|
+
"@apply font-bold text-body text-base":{},
|
|
35
|
+
},
|
|
36
|
+
|
|
37
|
+
// Days-Grid
|
|
38
|
+
".MuiCalendarPicker-root > div:last-of-type > div:last-of-type": {
|
|
39
|
+
"@apply min-h-min pb-6":{},
|
|
40
|
+
},
|
|
41
|
+
|
|
42
|
+
// Day picking
|
|
43
|
+
".MuiCalendarPicker-root .MuiPickersDay-root": {
|
|
44
|
+
"@apply text-base":{},
|
|
45
|
+
},
|
|
46
|
+
".MuiCalendarPicker-root .Mui-disabled": {
|
|
47
|
+
"@apply text-gray-stroke":{},
|
|
48
|
+
},
|
|
49
|
+
|
|
50
|
+
// Day picked
|
|
51
|
+
".MuiCalendarPicker-root .MuiButtonBase-root.MuiPickersDay-root.Mui-selected": {
|
|
52
|
+
"@apply bg-background-one text-body focus-visible:bg-background-one hover:bg-background-one focus:bg-background-one": {},
|
|
53
|
+
},
|
|
54
|
+
|
|
55
|
+
// Day hovered
|
|
56
|
+
".MuiCalendarPicker-root .MuiPickersDay-root, .MuiCalendarPicker-root .MuiPickersDay-root.MuiPickersDay-today": {
|
|
57
|
+
"@apply border-primary border-solid focus-visible:border hover:bg-transparent focus:bg-transparent hover:border": {},
|
|
58
|
+
},
|
|
59
|
+
|
|
60
|
+
// today
|
|
61
|
+
".MuiCalendarPicker-root .MuiPickersDay-root.MuiPickersDay-today": {
|
|
62
|
+
"@apply border-0 hover:border":{},
|
|
63
|
+
},
|
|
64
|
+
|
|
65
|
+
".calendar": {
|
|
66
|
+
// Input field
|
|
67
|
+
".datepicker-input": {
|
|
68
|
+
"@apply relative": {},
|
|
69
|
+
},
|
|
70
|
+
|
|
71
|
+
".datepicker-input input": {
|
|
72
|
+
"@apply pl-20 cursor-pointer":{},
|
|
73
|
+
},
|
|
74
|
+
|
|
75
|
+
".datepicker-input-icon": {
|
|
76
|
+
"@apply pointer-events-none absolute m-6 top-0 left-0 text-xl fill-body":{},
|
|
77
|
+
},
|
|
78
|
+
},
|
|
79
|
+
|
|
80
|
+
|
|
81
|
+
});
|
package/src/components/card.js
CHANGED
|
@@ -21,7 +21,7 @@ module.exports = Card = () => ({
|
|
|
21
21
|
"@apply hover:shadow-xl hover:cursor-pointer": {},
|
|
22
22
|
},
|
|
23
23
|
|
|
24
|
-
// "@apply bg-neutral-200 border border-neutral-100 text-
|
|
24
|
+
// "@apply bg-neutral-200 border border-neutral-100 text-body": {},
|
|
25
25
|
// dark
|
|
26
26
|
//"@apply dark:bg-neutral-700 dark:border-neutral-600 dark:text-neutral-300": {},
|
|
27
27
|
},
|
|
@@ -33,7 +33,7 @@ module.exports = Card = () => ({
|
|
|
33
33
|
},
|
|
34
34
|
|
|
35
35
|
".card-body": {
|
|
36
|
-
"@apply p-8": {},
|
|
36
|
+
"@apply text-body p-8": {},
|
|
37
37
|
},
|
|
38
38
|
|
|
39
39
|
".card-image": {
|
|
@@ -101,12 +101,12 @@ module.exports = Checkbox = (colors, theme) => ({
|
|
|
101
101
|
backgroundColor: "#ECECEC",
|
|
102
102
|
//"@apply disabled:bg-gray-stroke": {},
|
|
103
103
|
//"@apply disabled:shadow-none disabled:border-neutral-300 disabled:bg-neutral-300 disabled:hover:text-neutral-300": {},
|
|
104
|
-
//"@apply dark:disabled:border-transparent dark:disabled:bg-
|
|
104
|
+
//"@apply dark:disabled:border-transparent dark:disabled:bg-white/20 dark:disabled:hover:text-white/20": {},
|
|
105
105
|
},
|
|
106
106
|
|
|
107
107
|
// label
|
|
108
108
|
"&-label": {
|
|
109
|
-
"@apply select-none text-sm": {},
|
|
109
|
+
"@apply text-body select-none text-sm": {},
|
|
110
110
|
marginLeft: "0.8rem",
|
|
111
111
|
//"@apply text-black": {},
|
|
112
112
|
// dark colors
|
package/src/components/code.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
module.exports = Code = () => ({
|
|
2
2
|
".code": {
|
|
3
3
|
"@apply inline-flex justify-center items-center capitalize text-xs rounded-sm font-mono break-all": {},
|
|
4
|
-
"@apply bg-neutral-200 border border-neutral-100 text-
|
|
4
|
+
"@apply bg-neutral-200 border border-neutral-100 text-body": {},
|
|
5
5
|
// dark
|
|
6
6
|
"@apply dark:bg-neutral-700 dark:border-neutral-600 dark:text-neutral-300": {},
|
|
7
7
|
padding: "2px 3px 1px",
|
|
@@ -4,6 +4,10 @@ module.exports = CookieConsent = () => ({
|
|
|
4
4
|
|
|
5
5
|
"&-close-btn": {
|
|
6
6
|
"@apply cursor-pointer hover:text-primary-active absolute right-8 top-6 border border-transparent focus-visible:border-black flex self-center": {},
|
|
7
|
+
|
|
8
|
+
"&-icon": {
|
|
9
|
+
"@apply !text-2xl": {}
|
|
10
|
+
},
|
|
7
11
|
},
|
|
8
12
|
|
|
9
13
|
"&-content-wrapper": {
|
package/src/components/forms.js
CHANGED
|
@@ -73,8 +73,8 @@ function fieldSolid(colors) {
|
|
|
73
73
|
},
|
|
74
74
|
"focus-visible:ring-4": {},
|
|
75
75
|
/* dark mode */
|
|
76
|
-
"@apply dark:text-neutral-100 dark:bg-
|
|
77
|
-
"@apply dark:hover:bg-
|
|
76
|
+
"@apply dark:text-neutral-100 dark:bg-white/50": {},
|
|
77
|
+
"@apply dark:hover:bg-white/100": {},
|
|
78
78
|
".dark &[aria-invalid=true]": {
|
|
79
79
|
"--tw-border-opacity": "1",
|
|
80
80
|
borderColor: "rgba(248, 113, 113, var(--tw-border-opacity))",
|
|
@@ -110,7 +110,7 @@ function formControl() {
|
|
|
110
110
|
"@apply w-full relative": {},
|
|
111
111
|
},
|
|
112
112
|
".form-helper-text": {
|
|
113
|
-
"@apply mt-1.5 leading-none text-gray dark:text-
|
|
113
|
+
"@apply mt-1.5 leading-none text-gray dark:text-white/60": {},
|
|
114
114
|
},
|
|
115
115
|
".form-error-message": {
|
|
116
116
|
"@apply mt-1.5 leading-none flex items-center text-sm": {},
|
|
@@ -169,7 +169,7 @@ function formInputGroup() {
|
|
|
169
169
|
"@apply text-neutral-600 bg-neutral-50": {},
|
|
170
170
|
// dark colors
|
|
171
171
|
"@apply dark:border-neutral-700": {},
|
|
172
|
-
"@apply dark:text-neutral-100 dark:bg-
|
|
172
|
+
"@apply dark:text-neutral-100 dark:bg-white/30": {},
|
|
173
173
|
|
|
174
174
|
"&-sm": {
|
|
175
175
|
"@apply px-3 text-xs": {},
|
|
@@ -224,7 +224,7 @@ module.exports = Forms = (colors) => ({
|
|
|
224
224
|
"@apply disabled:bg-gray-lighter": {},
|
|
225
225
|
//"@apply disabled:shadow-none disabled:cursor-not-allowed disabled:opacity-60": {},
|
|
226
226
|
//"@apply disabled:border-neutral-200 disabled:bg-neutral-200": {},
|
|
227
|
-
//"@apply dark:disabled:border-transparent dark:disabled:bg-
|
|
227
|
+
//"@apply dark:disabled:border-transparent dark:disabled:bg-white/20": {},
|
|
228
228
|
},
|
|
229
229
|
|
|
230
230
|
// variants
|
|
@@ -242,7 +242,15 @@ module.exports = Forms = (colors) => ({
|
|
|
242
242
|
},
|
|
243
243
|
|
|
244
244
|
".form-select": {
|
|
245
|
-
//"@apply
|
|
245
|
+
// "@apply ":{}
|
|
246
|
+
|
|
247
|
+
"&-option": {
|
|
248
|
+
"@apply rounded-none cursor-default hover:text-white focus-visible:text-white hover:bg-primary focus-visible:bg-primary": {},
|
|
249
|
+
|
|
250
|
+
"&.active": {
|
|
251
|
+
"@apply bg-primary text-white": {},
|
|
252
|
+
}
|
|
253
|
+
}
|
|
246
254
|
},
|
|
247
255
|
|
|
248
256
|
...formInputGroup(),
|
package/src/components/kbd.js
CHANGED
|
@@ -2,8 +2,8 @@ module.exports = Kbd = () => ({
|
|
|
2
2
|
".kbd": {
|
|
3
3
|
"@apply inline-flex justify-center items-center capitalize text-xs p-1 rounded h-5 whitespace-nowrap font-sans": {},
|
|
4
4
|
"minWidth": "1.25rem",
|
|
5
|
-
"@apply bg-blackAlpha-100 text-
|
|
5
|
+
"@apply bg-blackAlpha-100 text-body": {},
|
|
6
6
|
// dark
|
|
7
|
-
"@apply dark:bg-
|
|
7
|
+
"@apply dark:bg-white/30 dark:text-neutral-300": {},
|
|
8
8
|
},
|
|
9
9
|
});
|
package/src/components/link.js
CHANGED
|
@@ -6,16 +6,11 @@ module.exports = Link = () => ({
|
|
|
6
6
|
|
|
7
7
|
"@apply hover:text-primary-active": {},
|
|
8
8
|
|
|
9
|
-
"
|
|
10
|
-
"
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
content: "'launch'",
|
|
15
|
-
lineHeight: "1",
|
|
16
|
-
marginLeft: ".25em",
|
|
17
|
-
verticalAlign: "text-top",
|
|
18
|
-
},
|
|
9
|
+
"&-external-icon": {
|
|
10
|
+
fontSize: "0.875em !important",
|
|
11
|
+
lineHeight: "1",
|
|
12
|
+
marginLeft: ".25em",
|
|
13
|
+
verticalAlign: "text-top",
|
|
19
14
|
},
|
|
20
15
|
|
|
21
16
|
"&-disabled": {
|
|
@@ -1,47 +1,41 @@
|
|
|
1
1
|
module.exports = Message = () => ({
|
|
2
2
|
".message": {
|
|
3
3
|
"@apply max-w-2xl flex items-center font-bold text-sm sm:text-base px-6 py-6 m-2 shadow-lg w-max break-words": {},
|
|
4
|
-
"@apply text-
|
|
4
|
+
"@apply text-body bg-white border-l-4": {},
|
|
5
5
|
// dark
|
|
6
6
|
"@apply dark:text-neutral-100 dark:bg-neutral-700 dark:border-neutral-600": {},
|
|
7
|
-
"minWidth": "520px",
|
|
8
|
-
"width": "520px",
|
|
9
7
|
|
|
10
8
|
"&-text": {
|
|
11
9
|
"@apply text-left flex-grow": {},
|
|
12
10
|
},
|
|
13
11
|
|
|
14
12
|
"&-info": {
|
|
15
|
-
"
|
|
16
|
-
"borderColor": "rgba(59, 130, 246, var(--tw-text-opacity))",
|
|
13
|
+
"@apply border-info": {},
|
|
17
14
|
|
|
18
15
|
".message-icon": {
|
|
19
|
-
"
|
|
16
|
+
"@apply text-info": {},
|
|
20
17
|
},
|
|
21
18
|
|
|
22
19
|
},
|
|
23
20
|
"&-success": {
|
|
24
|
-
"
|
|
25
|
-
"borderColor": "rgba(34, 197, 94, var(--tw-text-opacity))",
|
|
21
|
+
"@apply border-success": {},
|
|
26
22
|
|
|
27
23
|
".message-icon": {
|
|
28
|
-
"
|
|
24
|
+
"@apply text-success": {},
|
|
29
25
|
},
|
|
30
26
|
},
|
|
31
27
|
"&-error": {
|
|
32
|
-
"
|
|
33
|
-
"borderColor": "rgba(239, 68, 68, var(--tw-text-opacity))",
|
|
28
|
+
"@apply border-error": {},
|
|
34
29
|
|
|
35
30
|
".message-icon": {
|
|
36
|
-
"
|
|
31
|
+
"@apply text-error": {},
|
|
37
32
|
},
|
|
38
33
|
},
|
|
39
34
|
"&-warning": {
|
|
40
|
-
"
|
|
41
|
-
"borderColor": "rgba(234, 179, 8, var(--tw-text-opacity))",
|
|
35
|
+
"@apply border-warning": {},
|
|
42
36
|
|
|
43
37
|
".message-icon": {
|
|
44
|
-
"
|
|
38
|
+
"@apply text-warning": {},
|
|
45
39
|
},
|
|
46
40
|
},
|
|
47
41
|
},
|
|
@@ -51,14 +45,14 @@ module.exports = Message = () => ({
|
|
|
51
45
|
},
|
|
52
46
|
|
|
53
47
|
".message-close-button": {
|
|
54
|
-
"@apply border-transparent flex items-center justify-center transition-all duration-150 rounded-full outline-none cursor-base": {},
|
|
48
|
+
"@apply text-body border-transparent flex items-center justify-center transition-all duration-150 rounded-full outline-none cursor-base": {},
|
|
55
49
|
fontSize: "1.2em",
|
|
56
50
|
padding: "0.36em",
|
|
57
51
|
marginLeft: "0.25em",
|
|
58
52
|
marginRight: "-0.55em",
|
|
59
53
|
|
|
60
54
|
"&-icon": {
|
|
61
|
-
|
|
55
|
+
"@apply !text-xl": {},
|
|
62
56
|
},
|
|
63
57
|
|
|
64
58
|
"&-disabled": {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
module.exports = Notification = () => ({
|
|
2
2
|
".notification": {
|
|
3
3
|
"@apply relative flex p-4 text-sm w-96 m-2 max-w-full rounded-base shadow-sm sm:max-w-md": {},
|
|
4
|
-
"@apply text-
|
|
4
|
+
"@apply text-body bg-white border border-neutral-200": {},
|
|
5
5
|
// dark
|
|
6
6
|
"@apply dark:text-neutral-100 dark:bg-neutral-700 dark:border-neutral-600": {},
|
|
7
7
|
},
|
|
@@ -49,7 +49,7 @@ module.exports = Notification = () => ({
|
|
|
49
49
|
},
|
|
50
50
|
|
|
51
51
|
"&-close-button": {
|
|
52
|
-
"@apply cursor-base text-neutral-700 hover:text-
|
|
52
|
+
"@apply cursor-base text-neutral-700 hover:text-body": {},
|
|
53
53
|
"@apply dark:text-neutral-400 dark:hover:text-neutral-100": {},
|
|
54
54
|
},
|
|
55
55
|
},
|
|
@@ -29,7 +29,7 @@ module.exports = Pagination = () => ({
|
|
|
29
29
|
},
|
|
30
30
|
|
|
31
31
|
"&-prevNextButton": {
|
|
32
|
-
"@apply ml-4 inline-flex items-center sm:w-auto inline-flex flex-row leading-none":
|
|
32
|
+
"@apply text-body ml-4 inline-flex items-center sm:w-auto inline-flex flex-row leading-none":
|
|
33
33
|
{},
|
|
34
34
|
|
|
35
35
|
"&[data-reverse=true]": {
|
|
@@ -57,8 +57,8 @@ module.exports = Pagination = () => ({
|
|
|
57
57
|
"&-icon": {
|
|
58
58
|
"@apply m-1 align-text-bottom leading-none flex items-center": {},
|
|
59
59
|
|
|
60
|
-
".
|
|
61
|
-
fontSize: "
|
|
60
|
+
".MuiSvgIcon-root": {
|
|
61
|
+
fontSize: "1em",
|
|
62
62
|
},
|
|
63
63
|
},
|
|
64
64
|
},
|
package/src/components/radio.js
CHANGED
|
@@ -73,13 +73,13 @@ module.exports = Radio = (colors) => ({
|
|
|
73
73
|
// disabled
|
|
74
74
|
"&-disabled": {
|
|
75
75
|
"@apply disabled:shadow-none disabled:border-neutral-300 disabled:bg-neutral-300 disabled:hover:text-neutral-300": {},
|
|
76
|
-
"@apply dark:disabled:border-transparent dark:disabled:bg-
|
|
76
|
+
"@apply dark:disabled:border-transparent dark:disabled:bg-white/20 dark:disabled:hover:text-white/20": {},
|
|
77
77
|
},
|
|
78
78
|
|
|
79
79
|
// label
|
|
80
80
|
"&-label": {
|
|
81
81
|
"@apply ml-2 select-none text-sm": {},
|
|
82
|
-
"@apply text-
|
|
82
|
+
"@apply text-body": {},
|
|
83
83
|
// dark colors
|
|
84
84
|
"@apply dark:text-neutral-100": {},
|
|
85
85
|
|
package/src/components/switch.js
CHANGED
|
@@ -1,6 +1,16 @@
|
|
|
1
1
|
module.exports = Switch = (colors) => ({
|
|
2
2
|
".form-switch-label": {
|
|
3
3
|
"@apply inline-block align-middle": {},
|
|
4
|
+
|
|
5
|
+
"&[type='hidden']": {
|
|
6
|
+
"@apply hidden": {},
|
|
7
|
+
|
|
8
|
+
".form-switch": {
|
|
9
|
+
"@apply hidden": {},
|
|
10
|
+
},
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
|
|
4
14
|
},
|
|
5
15
|
".form-switch": {
|
|
6
16
|
"@apply rounded-full p-0.5 cursor-base focus:outline-none": {},
|
package/src/components/tag.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
function tagOutline(colors) {
|
|
2
2
|
return {
|
|
3
3
|
".tag-outline": {
|
|
4
|
-
"@apply border bg-transparent border-gray-stroke text-
|
|
4
|
+
"@apply border bg-transparent border-gray-stroke text-body": {},
|
|
5
5
|
|
|
6
6
|
"&[href]": {
|
|
7
7
|
[`@apply hover:border-hover hover:text-white hover:bg-hover`]: {},
|
|
@@ -24,7 +24,7 @@ function tagSolid(colors) {
|
|
|
24
24
|
},
|
|
25
25
|
|
|
26
26
|
".tag-close-button": {
|
|
27
|
-
"@apply text-white": {}
|
|
27
|
+
"@apply text-white hover:text-body": {}
|
|
28
28
|
},
|
|
29
29
|
},
|
|
30
30
|
};
|
|
@@ -33,7 +33,7 @@ function tagSolid(colors) {
|
|
|
33
33
|
function tagLight(colors) {
|
|
34
34
|
return {
|
|
35
35
|
".tag-light": {
|
|
36
|
-
"@apply border border-transparent text-
|
|
36
|
+
"@apply border border-transparent text-body": {},
|
|
37
37
|
|
|
38
38
|
"&[href]": {
|
|
39
39
|
[`@apply hover:border-hover`]: {},
|
|
@@ -78,14 +78,14 @@ module.exports = Tag = (colors) => ({
|
|
|
78
78
|
...tagLight(colors),
|
|
79
79
|
|
|
80
80
|
".tag-close-button": {
|
|
81
|
-
"@apply border-transparent flex items-center justify-center transition-all duration-150 rounded-full outline-none cursor-base": {},
|
|
81
|
+
"@apply text-body border-transparent flex items-center justify-center transition-all duration-150 rounded-full outline-none cursor-base": {},
|
|
82
82
|
fontSize: "1em",
|
|
83
83
|
padding: "0.36em",
|
|
84
84
|
marginLeft: "0.25em",
|
|
85
85
|
marginRight: "-0.55em",
|
|
86
86
|
|
|
87
87
|
"&-icon": {
|
|
88
|
-
fontSize: "1em"
|
|
88
|
+
fontSize: "1em !important"
|
|
89
89
|
},
|
|
90
90
|
|
|
91
91
|
"&-disabled": {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
module.exports = UserMenu = (colors) => ({
|
|
2
2
|
".usermenu": {
|
|
3
3
|
// "@apply mx-sm mt-sm mb-0 px-md py-0 divide-y divide-y-2 divide-gray-300 bg-white border-2 border-white border-solid rounded":
|
|
4
|
-
"@apply drop-shadow-none shadow-none filter-none": {},
|
|
4
|
+
"@apply text-body drop-shadow-none shadow-none filter-none": {},
|
|
5
5
|
// "@apply ": {},
|
|
6
6
|
"&-is-open": {
|
|
7
7
|
// "@apply border-2 border-gray-300 border-solid rounded": {},
|
|
@@ -14,7 +14,7 @@ module.exports = UserMenu = (colors) => ({
|
|
|
14
14
|
},
|
|
15
15
|
},
|
|
16
16
|
"&-item": {
|
|
17
|
-
"@apply block px-lg py-md lg:px-md lg:py-sm w-full cursor-pointer text-
|
|
17
|
+
"@apply block px-lg py-md lg:px-md lg:py-sm w-full cursor-pointer text-body no-underline": {},
|
|
18
18
|
"&.active": {
|
|
19
19
|
"@apply bg-hover text-white no-underline": {},
|
|
20
20
|
},
|
|
@@ -23,6 +23,10 @@ module.exports = ZebraTable = () => ({
|
|
|
23
23
|
|
|
24
24
|
"&-icon": {
|
|
25
25
|
"@apply inline-flex pl-sm": {},
|
|
26
|
+
|
|
27
|
+
".MuiSvgIcon-root": {
|
|
28
|
+
"@apply !text-lg": {},
|
|
29
|
+
},
|
|
26
30
|
|
|
27
31
|
|
|
28
32
|
"&-sort": {
|
|
@@ -38,7 +42,7 @@ module.exports = ZebraTable = () => ({
|
|
|
38
42
|
},
|
|
39
43
|
|
|
40
44
|
"&-more": {
|
|
41
|
-
"@apply text-gray
|
|
45
|
+
"@apply text-gray": {},
|
|
42
46
|
},
|
|
43
47
|
},
|
|
44
48
|
},
|
|
@@ -48,7 +52,7 @@ module.exports = ZebraTable = () => ({
|
|
|
48
52
|
},
|
|
49
53
|
|
|
50
54
|
"&-tbody": {
|
|
51
|
-
"@apply lg:bg-white": {},
|
|
55
|
+
"@apply text-body lg:bg-white": {},
|
|
52
56
|
|
|
53
57
|
"&-tr": {
|
|
54
58
|
"@apply transition-all bg-white lg:even:bg-white lg:odd:bg-gray-100 px-md py-md md:px-lg md:py-lg my-lg first-of-type:mt-0 block shadow-md lg:shadow-none lg:table-row lg:my-0 lg:py-0 lg:px-lg": {},
|
package/src/index.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
const plugin = require("tailwindcss/plugin");
|
|
2
2
|
|
|
3
|
-
const colors = require("
|
|
3
|
+
// const colors = require("/colors");
|
|
4
|
+
const { colors } = require("@sk-web-gui/theme");
|
|
4
5
|
const withOpacity = require("./with-opacity");
|
|
5
6
|
// components
|
|
6
7
|
const Alert = require("./components/alert");
|
|
@@ -10,6 +11,7 @@ const ButtonGroup = require("./components/button-group");
|
|
|
10
11
|
const Checkbox = require("./components/checkbox");
|
|
11
12
|
const Dot = require("./components/dot");
|
|
12
13
|
const Forms = require("./components/forms");
|
|
14
|
+
const Calendar = require("./components/calendar");
|
|
13
15
|
const IconButton = require("./components/icon-button");
|
|
14
16
|
const Icon = require("./components/icon");
|
|
15
17
|
const Link = require("./components/link");
|
|
@@ -41,6 +43,7 @@ const components = [
|
|
|
41
43
|
Checkbox,
|
|
42
44
|
Dot,
|
|
43
45
|
Forms,
|
|
46
|
+
Calendar,
|
|
44
47
|
IconButton,
|
|
45
48
|
Icon,
|
|
46
49
|
Link,
|
|
@@ -141,16 +144,7 @@ module.exports = plugin.withOptions(
|
|
|
141
144
|
extend: {
|
|
142
145
|
colors: {
|
|
143
146
|
...colors,
|
|
144
|
-
|
|
145
|
-
DEFAULT: "#4b4b4b",
|
|
146
|
-
stroke: "#939393",
|
|
147
|
-
middle: "#ECECEC",
|
|
148
|
-
light: "#F4F4F4",
|
|
149
|
-
lighter: "#F9F9F9",
|
|
150
|
-
},
|
|
151
|
-
hover: {
|
|
152
|
-
DEFAULT: "#2B76B0",
|
|
153
|
-
},
|
|
147
|
+
current: 'currentColor',
|
|
154
148
|
},
|
|
155
149
|
cursor: {
|
|
156
150
|
base: "var(--vc-cursor)",
|