baseui 0.0.0-next-e19fc5fd2 → 0.0.0-next-ff0c2b52d
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/checkbox/styled-components.js +2 -6
- package/package.json +1 -1
- package/tag/constants.d.ts +31 -5
- package/tag/constants.js +18 -11
- package/tag/deprecated-styles.d.ts +119 -0
- package/tag/deprecated-styles.js +179 -0
- package/tag/index.d.ts +1 -1
- package/tag/index.js +15 -1
- package/tag/styled-components.js +199 -230
- package/tag/tag.js +10 -4
- package/tag/types.d.ts +16 -11
- package/themes/dark-theme/color-semantic-tokens.js +93 -0
- package/themes/light-theme/color-semantic-tokens.js +93 -0
|
@@ -285,13 +285,9 @@ const Toggle = exports.Toggle = (0, _styles.styled)('div', props => {
|
|
|
285
285
|
Toggle.displayName = "Toggle";
|
|
286
286
|
Toggle.displayName = 'Toggle';
|
|
287
287
|
const ToggleTrack = exports.ToggleTrack = (0, _styles.styled)('div', props => {
|
|
288
|
-
|
|
289
|
-
if (props.$disabled) {
|
|
290
|
-
backgroundColor = props.$theme.colors.toggleTrackFillDisabled;
|
|
291
|
-
} else if (props.$error && props.$checked) {
|
|
292
|
-
backgroundColor = props.$theme.colors.tickFillError;
|
|
293
|
-
}
|
|
288
|
+
const backgroundColor = props.$disabled ? props.$theme.colors.toggleTrackFillDisabled : props.$theme.colors.toggleTrackFill;
|
|
294
289
|
return {
|
|
290
|
+
flex: '0 0 auto',
|
|
295
291
|
alignItems: 'center',
|
|
296
292
|
backgroundColor,
|
|
297
293
|
borderTopLeftRadius: '7px',
|
package/package.json
CHANGED
package/tag/constants.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
export declare const SIZE: {
|
|
2
|
+
readonly xSmall: "xSmall";
|
|
2
3
|
readonly small: "small";
|
|
3
4
|
readonly medium: "medium";
|
|
4
5
|
readonly large: "large";
|
|
@@ -7,8 +8,7 @@ export declare const HIERARCHY: Readonly<{
|
|
|
7
8
|
readonly primary: "primary";
|
|
8
9
|
readonly secondary: "secondary";
|
|
9
10
|
}>;
|
|
10
|
-
export declare const
|
|
11
|
-
readonly custom: "custom";
|
|
11
|
+
export declare const DEPRECATED_KIND: Readonly<{
|
|
12
12
|
readonly neutral: "neutral";
|
|
13
13
|
readonly primary: "primary";
|
|
14
14
|
readonly accent: "accent";
|
|
@@ -16,13 +16,39 @@ export declare const KIND: {
|
|
|
16
16
|
readonly warning: "warning";
|
|
17
17
|
readonly negative: "negative";
|
|
18
18
|
readonly black: "black";
|
|
19
|
-
readonly
|
|
20
|
-
|
|
19
|
+
readonly brown: "brown";
|
|
20
|
+
}>;
|
|
21
|
+
export declare const SUPPORTED_KIND: Readonly<{
|
|
22
|
+
readonly custom: "custom";
|
|
23
|
+
readonly gray: "gray";
|
|
21
24
|
readonly red: "red";
|
|
25
|
+
readonly orange: "orange";
|
|
22
26
|
readonly yellow: "yellow";
|
|
27
|
+
readonly green: "green";
|
|
28
|
+
readonly blue: "blue";
|
|
29
|
+
readonly purple: "purple";
|
|
30
|
+
readonly magenta: "magenta";
|
|
31
|
+
readonly teal: "teal";
|
|
32
|
+
readonly lime: "lime";
|
|
33
|
+
}>;
|
|
34
|
+
export declare const KIND: {
|
|
35
|
+
readonly custom: "custom";
|
|
36
|
+
readonly gray: "gray";
|
|
37
|
+
readonly red: "red";
|
|
23
38
|
readonly orange: "orange";
|
|
39
|
+
readonly yellow: "yellow";
|
|
40
|
+
readonly green: "green";
|
|
41
|
+
readonly blue: "blue";
|
|
24
42
|
readonly purple: "purple";
|
|
25
|
-
readonly
|
|
43
|
+
readonly magenta: "magenta";
|
|
26
44
|
readonly teal: "teal";
|
|
27
45
|
readonly lime: "lime";
|
|
46
|
+
readonly neutral: "neutral";
|
|
47
|
+
readonly primary: "primary";
|
|
48
|
+
readonly accent: "accent";
|
|
49
|
+
readonly positive: "positive";
|
|
50
|
+
readonly warning: "warning";
|
|
51
|
+
readonly negative: "negative";
|
|
52
|
+
readonly black: "black";
|
|
53
|
+
readonly brown: "brown";
|
|
28
54
|
};
|
package/tag/constants.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.SIZE = exports.KIND = exports.HIERARCHY = void 0;
|
|
6
|
+
exports.SUPPORTED_KIND = exports.SIZE = exports.KIND = exports.HIERARCHY = exports.DEPRECATED_KIND = void 0;
|
|
7
7
|
/*
|
|
8
8
|
Copyright (c) Uber Technologies, Inc.
|
|
9
9
|
|
|
@@ -11,6 +11,7 @@ This source code is licensed under the MIT license found in the
|
|
|
11
11
|
LICENSE file in the root directory of this source tree.
|
|
12
12
|
*/
|
|
13
13
|
const SIZE = exports.SIZE = {
|
|
14
|
+
xSmall: 'xSmall',
|
|
14
15
|
small: 'small',
|
|
15
16
|
medium: 'medium',
|
|
16
17
|
large: 'large'
|
|
@@ -19,26 +20,32 @@ const HIERARCHY = exports.HIERARCHY = Object.freeze({
|
|
|
19
20
|
primary: 'primary',
|
|
20
21
|
secondary: 'secondary'
|
|
21
22
|
});
|
|
22
|
-
|
|
23
|
-
// todo: dynamic identity map generation
|
|
24
|
-
const KIND = exports.KIND = {
|
|
25
|
-
custom: 'custom',
|
|
26
|
-
// semantic
|
|
23
|
+
const DEPRECATED_KIND = exports.DEPRECATED_KIND = Object.freeze({
|
|
27
24
|
neutral: 'neutral',
|
|
28
25
|
primary: 'primary',
|
|
29
26
|
accent: 'accent',
|
|
30
27
|
positive: 'positive',
|
|
31
28
|
warning: 'warning',
|
|
32
29
|
negative: 'negative',
|
|
33
|
-
// primitive
|
|
34
30
|
black: 'black',
|
|
35
|
-
|
|
36
|
-
|
|
31
|
+
brown: 'brown'
|
|
32
|
+
});
|
|
33
|
+
const SUPPORTED_KIND = exports.SUPPORTED_KIND = Object.freeze({
|
|
34
|
+
custom: 'custom',
|
|
35
|
+
gray: 'gray',
|
|
37
36
|
red: 'red',
|
|
38
|
-
yellow: 'yellow',
|
|
39
37
|
orange: 'orange',
|
|
38
|
+
yellow: 'yellow',
|
|
39
|
+
green: 'green',
|
|
40
|
+
blue: 'blue',
|
|
40
41
|
purple: 'purple',
|
|
41
|
-
|
|
42
|
+
magenta: 'magenta',
|
|
42
43
|
teal: 'teal',
|
|
43
44
|
lime: 'lime'
|
|
45
|
+
});
|
|
46
|
+
|
|
47
|
+
// todo: dynamic identity map generation
|
|
48
|
+
const KIND = exports.KIND = {
|
|
49
|
+
...DEPRECATED_KIND,
|
|
50
|
+
...SUPPORTED_KIND
|
|
44
51
|
};
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
export declare const deprecatedNeutralColorStates: {
|
|
2
|
+
disabled: (theme: any, color: any) => {
|
|
3
|
+
color: any;
|
|
4
|
+
backgroundColor: any;
|
|
5
|
+
borderColor: any;
|
|
6
|
+
};
|
|
7
|
+
primary: (theme: any, color: any) => {
|
|
8
|
+
color: any;
|
|
9
|
+
backgroundColor: any;
|
|
10
|
+
borderColor: any;
|
|
11
|
+
};
|
|
12
|
+
secondary: (theme: any, color: any) => {
|
|
13
|
+
color: any;
|
|
14
|
+
backgroundColor: any;
|
|
15
|
+
borderColor: any;
|
|
16
|
+
};
|
|
17
|
+
};
|
|
18
|
+
export declare const deprecatedPrimaryColorStates: {
|
|
19
|
+
disabled: (theme: any, color: any) => {
|
|
20
|
+
color: any;
|
|
21
|
+
backgroundColor: any;
|
|
22
|
+
borderColor: any;
|
|
23
|
+
};
|
|
24
|
+
primary: (theme: any, color: any) => {
|
|
25
|
+
color: any;
|
|
26
|
+
backgroundColor: any;
|
|
27
|
+
borderColor: any;
|
|
28
|
+
};
|
|
29
|
+
secondary: (theme: any, color: any) => {
|
|
30
|
+
color: any;
|
|
31
|
+
backgroundColor: any;
|
|
32
|
+
borderColor: any;
|
|
33
|
+
};
|
|
34
|
+
};
|
|
35
|
+
export declare const deprecatedBlueColorStates: {
|
|
36
|
+
disabled: (theme: any, color: any) => {
|
|
37
|
+
color: any;
|
|
38
|
+
backgroundColor: any;
|
|
39
|
+
borderColor: any;
|
|
40
|
+
};
|
|
41
|
+
primary: (theme: any, color: any) => {
|
|
42
|
+
color: any;
|
|
43
|
+
backgroundColor: any;
|
|
44
|
+
borderColor: any;
|
|
45
|
+
};
|
|
46
|
+
secondary: (theme: any, color: any) => {
|
|
47
|
+
color: any;
|
|
48
|
+
backgroundColor: any;
|
|
49
|
+
borderColor: any;
|
|
50
|
+
};
|
|
51
|
+
};
|
|
52
|
+
export declare const deprecatedGreenColorStates: {
|
|
53
|
+
disabled: (theme: any, color: any) => {
|
|
54
|
+
color: any;
|
|
55
|
+
backgroundColor: any;
|
|
56
|
+
borderColor: any;
|
|
57
|
+
};
|
|
58
|
+
primary: (theme: any, color: any) => {
|
|
59
|
+
color: any;
|
|
60
|
+
backgroundColor: any;
|
|
61
|
+
borderColor: any;
|
|
62
|
+
};
|
|
63
|
+
secondary: (theme: any, color: any) => {
|
|
64
|
+
color: any;
|
|
65
|
+
backgroundColor: any;
|
|
66
|
+
borderColor: any;
|
|
67
|
+
};
|
|
68
|
+
};
|
|
69
|
+
export declare const deprecatedYellowColorStates: {
|
|
70
|
+
disabled: (theme: any, color: any) => {
|
|
71
|
+
color: any;
|
|
72
|
+
backgroundColor: any;
|
|
73
|
+
borderColor: any;
|
|
74
|
+
};
|
|
75
|
+
primary: (theme: any, color: any) => {
|
|
76
|
+
color: any;
|
|
77
|
+
backgroundColor: any;
|
|
78
|
+
borderColor: any;
|
|
79
|
+
};
|
|
80
|
+
secondary: (theme: any, color: any) => {
|
|
81
|
+
color: any;
|
|
82
|
+
backgroundColor: any;
|
|
83
|
+
borderColor: any;
|
|
84
|
+
};
|
|
85
|
+
};
|
|
86
|
+
export declare const deprecatedRedColorStates: {
|
|
87
|
+
disabled: (theme: any, color: any) => {
|
|
88
|
+
color: any;
|
|
89
|
+
backgroundColor: any;
|
|
90
|
+
borderColor: any;
|
|
91
|
+
};
|
|
92
|
+
primary: (theme: any, color: any) => {
|
|
93
|
+
color: any;
|
|
94
|
+
backgroundColor: any;
|
|
95
|
+
borderColor: any;
|
|
96
|
+
};
|
|
97
|
+
secondary: (theme: any, color: any) => {
|
|
98
|
+
color: any;
|
|
99
|
+
backgroundColor: any;
|
|
100
|
+
borderColor: any;
|
|
101
|
+
};
|
|
102
|
+
};
|
|
103
|
+
export declare const deprecatedBrownColorStates: {
|
|
104
|
+
disabled: (theme: any, color: any) => {
|
|
105
|
+
color: any;
|
|
106
|
+
backgroundColor: any;
|
|
107
|
+
borderColor: any;
|
|
108
|
+
};
|
|
109
|
+
primary: (theme: any, color: any) => {
|
|
110
|
+
color: any;
|
|
111
|
+
backgroundColor: any;
|
|
112
|
+
borderColor: any;
|
|
113
|
+
};
|
|
114
|
+
secondary: (theme: any, color: any) => {
|
|
115
|
+
color: any;
|
|
116
|
+
backgroundColor: any;
|
|
117
|
+
borderColor: any;
|
|
118
|
+
};
|
|
119
|
+
};
|
|
@@ -0,0 +1,179 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.deprecatedYellowColorStates = exports.deprecatedRedColorStates = exports.deprecatedPrimaryColorStates = exports.deprecatedNeutralColorStates = exports.deprecatedGreenColorStates = exports.deprecatedBrownColorStates = exports.deprecatedBlueColorStates = void 0;
|
|
7
|
+
// Note: all the styles exported from this file are deprecated and won't be maintained going forward.
|
|
8
|
+
// They are kept here for backward compatibility reasons only.
|
|
9
|
+
|
|
10
|
+
const COLOR_STATE = {
|
|
11
|
+
disabled: 'disabled',
|
|
12
|
+
primary: 'primary',
|
|
13
|
+
secondary: 'secondary'
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
// Probably best to bake this into the theme once we hit our next major.
|
|
17
|
+
// @ts-ignore
|
|
18
|
+
const pick = (theme, light, dark) => theme.name && theme.name.includes('dark') ? dark : light;
|
|
19
|
+
const deprecatedNeutralColorStates = exports.deprecatedNeutralColorStates = {
|
|
20
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
21
|
+
// @ts-ignore
|
|
22
|
+
[COLOR_STATE.disabled]: (theme, color) => ({
|
|
23
|
+
color: theme.colors.tagNeutralFontDisabled,
|
|
24
|
+
backgroundColor: pick(theme, theme.colors.gray50, theme.colors.gray100Dark),
|
|
25
|
+
borderColor: null
|
|
26
|
+
}),
|
|
27
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
28
|
+
// @ts-ignore
|
|
29
|
+
[COLOR_STATE.primary]: (theme, color) => ({
|
|
30
|
+
color: theme.colors.tagNeutralSolidFont,
|
|
31
|
+
backgroundColor: theme.colors.tagNeutralSolidBackground,
|
|
32
|
+
borderColor: null
|
|
33
|
+
}),
|
|
34
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
35
|
+
// @ts-ignore
|
|
36
|
+
[COLOR_STATE.secondary]: (theme, color) => ({
|
|
37
|
+
color: theme.colors.tagNeutralOutlinedFont,
|
|
38
|
+
backgroundColor: theme.colors.tagNeutralOutlinedBackground,
|
|
39
|
+
borderColor: null
|
|
40
|
+
})
|
|
41
|
+
};
|
|
42
|
+
const deprecatedPrimaryColorStates = exports.deprecatedPrimaryColorStates = {
|
|
43
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
44
|
+
// @ts-ignore
|
|
45
|
+
[COLOR_STATE.disabled]: (theme, color) => ({
|
|
46
|
+
color: theme.colors.tagPrimaryFontDisabled,
|
|
47
|
+
backgroundColor: pick(theme, theme.colors.gray50, theme.colors.gray100Dark),
|
|
48
|
+
borderColor: null
|
|
49
|
+
}),
|
|
50
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
51
|
+
// @ts-ignore
|
|
52
|
+
[COLOR_STATE.primary]: (theme, color) => ({
|
|
53
|
+
color: theme.colors.tagPrimarySolidFont,
|
|
54
|
+
backgroundColor: theme.colors.tagPrimarySolidBackground,
|
|
55
|
+
borderColor: null
|
|
56
|
+
}),
|
|
57
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
58
|
+
// @ts-ignore
|
|
59
|
+
[COLOR_STATE.secondary]: (theme, color) => ({
|
|
60
|
+
color: theme.colors.tagPrimaryOutlinedFont,
|
|
61
|
+
backgroundColor: theme.colors.tagPrimaryOutlinedBackground,
|
|
62
|
+
borderColor: null
|
|
63
|
+
})
|
|
64
|
+
};
|
|
65
|
+
const deprecatedBlueColorStates = exports.deprecatedBlueColorStates = {
|
|
66
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
67
|
+
// @ts-ignore
|
|
68
|
+
[COLOR_STATE.disabled]: (theme, color) => ({
|
|
69
|
+
color: theme.colors.tagAccentFontDisabled,
|
|
70
|
+
backgroundColor: pick(theme, theme.colors.blue50, theme.colors.blue100Dark),
|
|
71
|
+
borderColor: null
|
|
72
|
+
}),
|
|
73
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
74
|
+
// @ts-ignore
|
|
75
|
+
[COLOR_STATE.primary]: (theme, color) => ({
|
|
76
|
+
color: theme.colors.tagAccentSolidFont,
|
|
77
|
+
backgroundColor: theme.colors.tagAccentSolidBackground,
|
|
78
|
+
borderColor: null
|
|
79
|
+
}),
|
|
80
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
81
|
+
// @ts-ignore
|
|
82
|
+
[COLOR_STATE.secondary]: (theme, color) => ({
|
|
83
|
+
color: theme.colors.tagAccentOutlinedFont,
|
|
84
|
+
backgroundColor: theme.colors.tagAccentOutlinedBackground,
|
|
85
|
+
borderColor: null
|
|
86
|
+
})
|
|
87
|
+
};
|
|
88
|
+
const deprecatedGreenColorStates = exports.deprecatedGreenColorStates = {
|
|
89
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
90
|
+
// @ts-ignore
|
|
91
|
+
[COLOR_STATE.disabled]: (theme, color) => ({
|
|
92
|
+
color: theme.colors.tagPositiveFontDisabled,
|
|
93
|
+
backgroundColor: pick(theme, theme.colors.green50, theme.colors.green100Dark),
|
|
94
|
+
borderColor: null
|
|
95
|
+
}),
|
|
96
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
97
|
+
// @ts-ignore
|
|
98
|
+
[COLOR_STATE.primary]: (theme, color) => ({
|
|
99
|
+
color: theme.colors.tagPositiveSolidFont,
|
|
100
|
+
backgroundColor: theme.colors.tagPositiveSolidBackground,
|
|
101
|
+
borderColor: null
|
|
102
|
+
}),
|
|
103
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
104
|
+
// @ts-ignore
|
|
105
|
+
[COLOR_STATE.secondary]: (theme, color) => ({
|
|
106
|
+
color: theme.colors.tagPositiveOutlinedFont,
|
|
107
|
+
backgroundColor: theme.colors.tagPositiveOutlinedBackground,
|
|
108
|
+
borderColor: null
|
|
109
|
+
})
|
|
110
|
+
};
|
|
111
|
+
const deprecatedYellowColorStates = exports.deprecatedYellowColorStates = {
|
|
112
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
113
|
+
// @ts-ignore
|
|
114
|
+
[COLOR_STATE.disabled]: (theme, color) => ({
|
|
115
|
+
color: theme.colors.tagWarningFontDisabled,
|
|
116
|
+
backgroundColor: pick(theme, theme.colors.yellow50, theme.colors.yellow100Dark),
|
|
117
|
+
borderColor: null
|
|
118
|
+
}),
|
|
119
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
120
|
+
// @ts-ignore
|
|
121
|
+
[COLOR_STATE.primary]: (theme, color) => ({
|
|
122
|
+
color: theme.colors.tagWarningSolidFont,
|
|
123
|
+
backgroundColor: theme.colors.tagWarningSolidBackground,
|
|
124
|
+
borderColor: null
|
|
125
|
+
}),
|
|
126
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
127
|
+
// @ts-ignore
|
|
128
|
+
[COLOR_STATE.secondary]: (theme, color) => ({
|
|
129
|
+
color: theme.colors.tagWarningOutlinedFont,
|
|
130
|
+
backgroundColor: theme.colors.tagWarningOutlinedBackground,
|
|
131
|
+
borderColor: null
|
|
132
|
+
})
|
|
133
|
+
};
|
|
134
|
+
const deprecatedRedColorStates = exports.deprecatedRedColorStates = {
|
|
135
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
136
|
+
// @ts-ignore
|
|
137
|
+
[COLOR_STATE.disabled]: (theme, color) => ({
|
|
138
|
+
color: theme.colors.tagNegativeFontDisabled,
|
|
139
|
+
backgroundColor: pick(theme, theme.colors.red50, theme.colors.red100Dark),
|
|
140
|
+
borderColor: null
|
|
141
|
+
}),
|
|
142
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
143
|
+
// @ts-ignore
|
|
144
|
+
[COLOR_STATE.primary]: (theme, color) => ({
|
|
145
|
+
color: theme.colors.tagNegativeSolidFont,
|
|
146
|
+
backgroundColor: theme.colors.tagNegativeSolidBackground,
|
|
147
|
+
borderColor: null
|
|
148
|
+
}),
|
|
149
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
150
|
+
// @ts-ignore
|
|
151
|
+
[COLOR_STATE.secondary]: (theme, color) => ({
|
|
152
|
+
color: theme.colors.tagNegativeOutlinedFont,
|
|
153
|
+
backgroundColor: theme.colors.tagNegativeOutlinedBackground,
|
|
154
|
+
borderColor: null
|
|
155
|
+
})
|
|
156
|
+
};
|
|
157
|
+
const deprecatedBrownColorStates = exports.deprecatedBrownColorStates = {
|
|
158
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
159
|
+
// @ts-ignore
|
|
160
|
+
[COLOR_STATE.disabled]: (theme, color) => ({
|
|
161
|
+
color: pick(theme, theme.colors.amber200, theme.colors.amber400Dark),
|
|
162
|
+
backgroundColor: null,
|
|
163
|
+
borderColor: null
|
|
164
|
+
}),
|
|
165
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
166
|
+
// @ts-ignore
|
|
167
|
+
[COLOR_STATE.primary]: (theme, color) => ({
|
|
168
|
+
color: pick(theme, theme.colors.white, theme.colors.gray900Dark),
|
|
169
|
+
backgroundColor: pick(theme, theme.colors.amber600, theme.colors.amber400Dark),
|
|
170
|
+
borderColor: null
|
|
171
|
+
}),
|
|
172
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
173
|
+
// @ts-ignore
|
|
174
|
+
[COLOR_STATE.secondary]: (theme, color) => ({
|
|
175
|
+
color: pick(theme, theme.colors.amber600, theme.colors.amber600Dark),
|
|
176
|
+
backgroundColor: null,
|
|
177
|
+
borderColor: null
|
|
178
|
+
})
|
|
179
|
+
};
|
package/tag/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
export { default as Tag } from './tag';
|
|
2
2
|
export { Root as StyledRoot, Action as StyledAction, Text as StyledText, } from './styled-components';
|
|
3
|
-
export { KIND, HIERARCHY, SIZE } from './constants';
|
|
3
|
+
export { KIND, HIERARCHY, SIZE, SUPPORTED_KIND, DEPRECATED_KIND } from './constants';
|
|
4
4
|
export * from './types';
|
package/tag/index.js
CHANGED
|
@@ -10,8 +10,16 @@ var _exportNames = {
|
|
|
10
10
|
StyledText: true,
|
|
11
11
|
KIND: true,
|
|
12
12
|
HIERARCHY: true,
|
|
13
|
-
SIZE: true
|
|
13
|
+
SIZE: true,
|
|
14
|
+
SUPPORTED_KIND: true,
|
|
15
|
+
DEPRECATED_KIND: true
|
|
14
16
|
};
|
|
17
|
+
Object.defineProperty(exports, "DEPRECATED_KIND", {
|
|
18
|
+
enumerable: true,
|
|
19
|
+
get: function () {
|
|
20
|
+
return _constants.DEPRECATED_KIND;
|
|
21
|
+
}
|
|
22
|
+
});
|
|
15
23
|
Object.defineProperty(exports, "HIERARCHY", {
|
|
16
24
|
enumerable: true,
|
|
17
25
|
get: function () {
|
|
@@ -30,6 +38,12 @@ Object.defineProperty(exports, "SIZE", {
|
|
|
30
38
|
return _constants.SIZE;
|
|
31
39
|
}
|
|
32
40
|
});
|
|
41
|
+
Object.defineProperty(exports, "SUPPORTED_KIND", {
|
|
42
|
+
enumerable: true,
|
|
43
|
+
get: function () {
|
|
44
|
+
return _constants.SUPPORTED_KIND;
|
|
45
|
+
}
|
|
46
|
+
});
|
|
33
47
|
Object.defineProperty(exports, "StyledAction", {
|
|
34
48
|
enumerable: true,
|
|
35
49
|
get: function () {
|