@atlaskit/tokens 0.9.1 → 0.9.2
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/CHANGELOG.md +6 -0
- package/babel-plugin/package.json +3 -0
- package/dist/cjs/artifacts/palettes-raw.js +1983 -0
- package/dist/cjs/artifacts/tokens-raw/atlassian-dark.js +374 -0
- package/dist/cjs/artifacts/tokens-raw/atlassian-light.js +374 -0
- package/dist/cjs/entry-points/palettes-raw.js +15 -0
- package/dist/cjs/entry-points/token-ids.js +1 -1
- package/dist/cjs/get-token.js +1 -1
- package/dist/cjs/tokens/default/deprecated/deprecated.js +187 -0
- package/dist/cjs/tokens/palette.js +232 -116
- package/dist/cjs/utils/color-detection.js +129 -0
- package/dist/cjs/{token-ids.js → utils/token-ids.js} +1 -1
- package/dist/cjs/version.json +1 -1
- package/dist/es2019/artifacts/palettes-raw.js +1976 -0
- package/dist/es2019/artifacts/tokens-raw/atlassian-dark.js +374 -0
- package/dist/es2019/artifacts/tokens-raw/atlassian-light.js +374 -0
- package/dist/es2019/entry-points/palettes-raw.js +1 -0
- package/dist/es2019/entry-points/token-ids.js +1 -1
- package/dist/es2019/get-token.js +1 -1
- package/dist/es2019/tokens/default/deprecated/deprecated.js +187 -0
- package/dist/es2019/tokens/palette.js +232 -116
- package/dist/es2019/utils/color-detection.js +101 -0
- package/dist/es2019/{token-ids.js → utils/token-ids.js} +1 -1
- package/dist/es2019/version.json +1 -1
- package/dist/esm/artifacts/palettes-raw.js +1976 -0
- package/dist/esm/artifacts/tokens-raw/atlassian-dark.js +374 -0
- package/dist/esm/artifacts/tokens-raw/atlassian-light.js +374 -0
- package/dist/esm/entry-points/palettes-raw.js +1 -0
- package/dist/esm/entry-points/token-ids.js +1 -1
- package/dist/esm/get-token.js +1 -1
- package/dist/esm/tokens/default/deprecated/deprecated.js +187 -0
- package/dist/esm/tokens/palette.js +232 -116
- package/dist/esm/utils/color-detection.js +104 -0
- package/dist/esm/{token-ids.js → utils/token-ids.js} +1 -1
- package/dist/esm/version.json +1 -1
- package/dist/types/artifacts/palettes-raw.d.ts +19 -0
- package/dist/types/artifacts/tokens-raw/atlassian-dark.d.ts +43 -0
- package/dist/types/artifacts/tokens-raw/atlassian-light.d.ts +43 -0
- package/dist/types/entry-points/palettes-raw.d.ts +1 -0
- package/dist/types/entry-points/token-ids.d.ts +1 -1
- package/dist/types/types.d.ts +22 -7
- package/dist/types/utils/color-detection.d.ts +38 -0
- package/dist/types/{token-ids.d.ts → utils/token-ids.d.ts} +0 -0
- package/package.json +13 -3
- package/palettes-raw/package.json +10 -0
- package/rename-mapping/package.json +3 -0
- package/token-ids/package.json +3 -0
- package/token-names/package.json +3 -0
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
import { token } from '../index';
|
|
2
|
+
export var hexToRGBAValues = function hexToRGBAValues(hex) {
|
|
3
|
+
var hexColor = hex.replace('#', '');
|
|
4
|
+
return {
|
|
5
|
+
r: parseInt(hexColor.slice(0, 2), 16),
|
|
6
|
+
g: parseInt(hexColor.slice(2, 4), 16),
|
|
7
|
+
b: parseInt(hexColor.slice(4, 6), 16),
|
|
8
|
+
a: parseFloat((parseInt(hexColor.slice(6, 8), 16) / 255).toFixed(2))
|
|
9
|
+
};
|
|
10
|
+
};
|
|
11
|
+
export var hexToRGBA = function hexToRGBA(hex) {
|
|
12
|
+
var _hexToRGBAValues = hexToRGBAValues(hex),
|
|
13
|
+
r = _hexToRGBAValues.r,
|
|
14
|
+
g = _hexToRGBAValues.g,
|
|
15
|
+
b = _hexToRGBAValues.b,
|
|
16
|
+
a = _hexToRGBAValues.a;
|
|
17
|
+
|
|
18
|
+
return "rgb".concat(a ? 'a' : '', "(").concat(r, ",").concat(g, ",").concat(b).concat(a ? ",".concat(a) : '', ")");
|
|
19
|
+
};
|
|
20
|
+
export var getLuminance = function getLuminance(_ref) {
|
|
21
|
+
var r = _ref.r,
|
|
22
|
+
g = _ref.g,
|
|
23
|
+
b = _ref.b;
|
|
24
|
+
return (r * 299 + g * 587 + b * 114) / 1000;
|
|
25
|
+
};
|
|
26
|
+
/**
|
|
27
|
+
* Returns an accessible hard-coded text color based on the color contrast with
|
|
28
|
+
* the background.
|
|
29
|
+
*
|
|
30
|
+
* @param hex - The Hex color code of the background
|
|
31
|
+
* @param [opts.hardcodedSurface] - If set, a design token will be returned instead
|
|
32
|
+
* of a hard-coded color. This is to support more transparent backgrounds
|
|
33
|
+
* to allow the text to invert colors depending on the current theme's surface color.
|
|
34
|
+
*/
|
|
35
|
+
|
|
36
|
+
export var getTextColorForBackground = function getTextColorForBackground(hex, opts) {
|
|
37
|
+
var _hexToRGBAValues2 = hexToRGBAValues(hex),
|
|
38
|
+
r = _hexToRGBAValues2.r,
|
|
39
|
+
g = _hexToRGBAValues2.g,
|
|
40
|
+
b = _hexToRGBAValues2.b,
|
|
41
|
+
a = _hexToRGBAValues2.a;
|
|
42
|
+
|
|
43
|
+
var lum = getLuminance({
|
|
44
|
+
r: r,
|
|
45
|
+
g: g,
|
|
46
|
+
b: b
|
|
47
|
+
});
|
|
48
|
+
var alphaLimit = 0.42;
|
|
49
|
+
var alphaConditionsPerSurface = {
|
|
50
|
+
light: a < alphaLimit,
|
|
51
|
+
dark: a > alphaLimit
|
|
52
|
+
};
|
|
53
|
+
var alphaLimitExceeded = (opts === null || opts === void 0 ? void 0 : opts.hardcodedSurface) && alphaConditionsPerSurface[opts.hardcodedSurface];
|
|
54
|
+
|
|
55
|
+
if (!(opts !== null && opts !== void 0 && opts.hardcodedSurface) && a < alphaLimit) {
|
|
56
|
+
// This color is transparent, so the text will mainly cast onto the surface behind.
|
|
57
|
+
// Needs to use tokens otherwise Dark mode would cause black text on black surface
|
|
58
|
+
return token('color.text', 'black');
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
return lum > 150 && !a || a && alphaLimitExceeded ? 'black' : 'white';
|
|
62
|
+
};
|
|
63
|
+
/**
|
|
64
|
+
* Returns a border if determined to be required based on the color contrast with
|
|
65
|
+
* the background.
|
|
66
|
+
*
|
|
67
|
+
* @param hex - The Hex color code of the background
|
|
68
|
+
*/
|
|
69
|
+
|
|
70
|
+
export var getBorderForBackground = function getBorderForBackground(hex) {
|
|
71
|
+
var _hexToRGBAValues3 = hexToRGBAValues(hex),
|
|
72
|
+
r = _hexToRGBAValues3.r,
|
|
73
|
+
g = _hexToRGBAValues3.g,
|
|
74
|
+
b = _hexToRGBAValues3.b,
|
|
75
|
+
a = _hexToRGBAValues3.a;
|
|
76
|
+
|
|
77
|
+
var lum = getLuminance({
|
|
78
|
+
r: r,
|
|
79
|
+
g: g,
|
|
80
|
+
b: b
|
|
81
|
+
});
|
|
82
|
+
return lum > 240 || a < 0.2 ? "1px solid ".concat(token('color.border', '#091E4224')) : undefined;
|
|
83
|
+
};
|
|
84
|
+
/**
|
|
85
|
+
* Returns a box shadow formatted for CSS from a ShadowToken raw value.
|
|
86
|
+
*
|
|
87
|
+
* @param rawShadow - ShadowToken raw value
|
|
88
|
+
*/
|
|
89
|
+
|
|
90
|
+
export var getBoxShadow = function getBoxShadow(rawShadow) {
|
|
91
|
+
return rawShadow.map(function (_ref2) {
|
|
92
|
+
var radius = _ref2.radius,
|
|
93
|
+
offset = _ref2.offset,
|
|
94
|
+
color = _ref2.color,
|
|
95
|
+
opacity = _ref2.opacity;
|
|
96
|
+
|
|
97
|
+
var _hexToRGBAValues4 = hexToRGBAValues(color),
|
|
98
|
+
r = _hexToRGBAValues4.r,
|
|
99
|
+
g = _hexToRGBAValues4.g,
|
|
100
|
+
b = _hexToRGBAValues4.b;
|
|
101
|
+
|
|
102
|
+
return "".concat(offset.x, "px ").concat(offset.y, "px ").concat(radius, "px rgba(").concat(r, ", ").concat(g, ", ").concat(b, ", ").concat(opacity, ")");
|
|
103
|
+
}).join(',');
|
|
104
|
+
};
|
package/dist/esm/version.json
CHANGED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
declare const tokens: {
|
|
2
|
+
value: string;
|
|
3
|
+
attributes: {
|
|
4
|
+
group: string;
|
|
5
|
+
category: string;
|
|
6
|
+
};
|
|
7
|
+
filePath: string;
|
|
8
|
+
isSource: boolean;
|
|
9
|
+
original: {
|
|
10
|
+
value: string;
|
|
11
|
+
attributes: {
|
|
12
|
+
group: string;
|
|
13
|
+
category: string;
|
|
14
|
+
};
|
|
15
|
+
};
|
|
16
|
+
name: string;
|
|
17
|
+
path: string[];
|
|
18
|
+
}[];
|
|
19
|
+
export default tokens;
|
|
@@ -4,6 +4,8 @@ declare const tokens: ({
|
|
|
4
4
|
state: string;
|
|
5
5
|
introduced: string;
|
|
6
6
|
description: string;
|
|
7
|
+
deprecated?: undefined;
|
|
8
|
+
deleted?: undefined;
|
|
7
9
|
replacement?: undefined;
|
|
8
10
|
};
|
|
9
11
|
value: string;
|
|
@@ -15,6 +17,8 @@ declare const tokens: ({
|
|
|
15
17
|
state: string;
|
|
16
18
|
introduced: string;
|
|
17
19
|
description: string;
|
|
20
|
+
deprecated?: undefined;
|
|
21
|
+
deleted?: undefined;
|
|
18
22
|
replacement?: undefined;
|
|
19
23
|
};
|
|
20
24
|
value: string;
|
|
@@ -26,6 +30,8 @@ declare const tokens: ({
|
|
|
26
30
|
group: string;
|
|
27
31
|
state: string;
|
|
28
32
|
introduced: string;
|
|
33
|
+
deprecated: string;
|
|
34
|
+
deleted: string;
|
|
29
35
|
replacement: string;
|
|
30
36
|
description: string;
|
|
31
37
|
};
|
|
@@ -37,6 +43,8 @@ declare const tokens: ({
|
|
|
37
43
|
group: string;
|
|
38
44
|
state: string;
|
|
39
45
|
introduced: string;
|
|
46
|
+
deprecated: string;
|
|
47
|
+
deleted: string;
|
|
40
48
|
replacement: string;
|
|
41
49
|
description: string;
|
|
42
50
|
};
|
|
@@ -49,6 +57,35 @@ declare const tokens: ({
|
|
|
49
57
|
group: string;
|
|
50
58
|
state: string;
|
|
51
59
|
introduced: string;
|
|
60
|
+
deprecated: string;
|
|
61
|
+
replacement: string;
|
|
62
|
+
description: string;
|
|
63
|
+
deleted?: undefined;
|
|
64
|
+
};
|
|
65
|
+
value: string;
|
|
66
|
+
filePath: string;
|
|
67
|
+
isSource: boolean;
|
|
68
|
+
original: {
|
|
69
|
+
attributes: {
|
|
70
|
+
group: string;
|
|
71
|
+
state: string;
|
|
72
|
+
introduced: string;
|
|
73
|
+
deprecated: string;
|
|
74
|
+
replacement: string;
|
|
75
|
+
description: string;
|
|
76
|
+
deleted?: undefined;
|
|
77
|
+
};
|
|
78
|
+
value: string;
|
|
79
|
+
};
|
|
80
|
+
name: string;
|
|
81
|
+
path: string[];
|
|
82
|
+
} | {
|
|
83
|
+
attributes: {
|
|
84
|
+
group: string;
|
|
85
|
+
state: string;
|
|
86
|
+
introduced: string;
|
|
87
|
+
deprecated: string;
|
|
88
|
+
deleted: string;
|
|
52
89
|
replacement: string;
|
|
53
90
|
description: string;
|
|
54
91
|
};
|
|
@@ -80,6 +117,8 @@ declare const tokens: ({
|
|
|
80
117
|
group: string;
|
|
81
118
|
state: string;
|
|
82
119
|
introduced: string;
|
|
120
|
+
deprecated: string;
|
|
121
|
+
deleted: string;
|
|
83
122
|
replacement: string;
|
|
84
123
|
description: string;
|
|
85
124
|
};
|
|
@@ -113,6 +152,8 @@ declare const tokens: ({
|
|
|
113
152
|
state: string;
|
|
114
153
|
introduced: string;
|
|
115
154
|
description: string;
|
|
155
|
+
deprecated?: undefined;
|
|
156
|
+
deleted?: undefined;
|
|
116
157
|
replacement?: undefined;
|
|
117
158
|
};
|
|
118
159
|
value: ({
|
|
@@ -144,6 +185,8 @@ declare const tokens: ({
|
|
|
144
185
|
state: string;
|
|
145
186
|
introduced: string;
|
|
146
187
|
description: string;
|
|
188
|
+
deprecated?: undefined;
|
|
189
|
+
deleted?: undefined;
|
|
147
190
|
replacement?: undefined;
|
|
148
191
|
};
|
|
149
192
|
value: ({
|
|
@@ -4,6 +4,8 @@ declare const tokens: ({
|
|
|
4
4
|
state: string;
|
|
5
5
|
introduced: string;
|
|
6
6
|
description: string;
|
|
7
|
+
deprecated?: undefined;
|
|
8
|
+
deleted?: undefined;
|
|
7
9
|
replacement?: undefined;
|
|
8
10
|
};
|
|
9
11
|
value: string;
|
|
@@ -15,6 +17,8 @@ declare const tokens: ({
|
|
|
15
17
|
state: string;
|
|
16
18
|
introduced: string;
|
|
17
19
|
description: string;
|
|
20
|
+
deprecated?: undefined;
|
|
21
|
+
deleted?: undefined;
|
|
18
22
|
replacement?: undefined;
|
|
19
23
|
};
|
|
20
24
|
value: string;
|
|
@@ -26,6 +30,8 @@ declare const tokens: ({
|
|
|
26
30
|
group: string;
|
|
27
31
|
state: string;
|
|
28
32
|
introduced: string;
|
|
33
|
+
deprecated: string;
|
|
34
|
+
deleted: string;
|
|
29
35
|
replacement: string;
|
|
30
36
|
description: string;
|
|
31
37
|
};
|
|
@@ -37,6 +43,8 @@ declare const tokens: ({
|
|
|
37
43
|
group: string;
|
|
38
44
|
state: string;
|
|
39
45
|
introduced: string;
|
|
46
|
+
deprecated: string;
|
|
47
|
+
deleted: string;
|
|
40
48
|
replacement: string;
|
|
41
49
|
description: string;
|
|
42
50
|
};
|
|
@@ -49,6 +57,35 @@ declare const tokens: ({
|
|
|
49
57
|
group: string;
|
|
50
58
|
state: string;
|
|
51
59
|
introduced: string;
|
|
60
|
+
deprecated: string;
|
|
61
|
+
replacement: string;
|
|
62
|
+
description: string;
|
|
63
|
+
deleted?: undefined;
|
|
64
|
+
};
|
|
65
|
+
value: string;
|
|
66
|
+
filePath: string;
|
|
67
|
+
isSource: boolean;
|
|
68
|
+
original: {
|
|
69
|
+
attributes: {
|
|
70
|
+
group: string;
|
|
71
|
+
state: string;
|
|
72
|
+
introduced: string;
|
|
73
|
+
deprecated: string;
|
|
74
|
+
replacement: string;
|
|
75
|
+
description: string;
|
|
76
|
+
deleted?: undefined;
|
|
77
|
+
};
|
|
78
|
+
value: string;
|
|
79
|
+
};
|
|
80
|
+
name: string;
|
|
81
|
+
path: string[];
|
|
82
|
+
} | {
|
|
83
|
+
attributes: {
|
|
84
|
+
group: string;
|
|
85
|
+
state: string;
|
|
86
|
+
introduced: string;
|
|
87
|
+
deprecated: string;
|
|
88
|
+
deleted: string;
|
|
52
89
|
replacement: string;
|
|
53
90
|
description: string;
|
|
54
91
|
};
|
|
@@ -68,6 +105,8 @@ declare const tokens: ({
|
|
|
68
105
|
group: string;
|
|
69
106
|
state: string;
|
|
70
107
|
introduced: string;
|
|
108
|
+
deprecated: string;
|
|
109
|
+
deleted: string;
|
|
71
110
|
replacement: string;
|
|
72
111
|
description: string;
|
|
73
112
|
};
|
|
@@ -89,6 +128,8 @@ declare const tokens: ({
|
|
|
89
128
|
state: string;
|
|
90
129
|
introduced: string;
|
|
91
130
|
description: string;
|
|
131
|
+
deprecated?: undefined;
|
|
132
|
+
deleted?: undefined;
|
|
92
133
|
replacement?: undefined;
|
|
93
134
|
};
|
|
94
135
|
value: {
|
|
@@ -108,6 +149,8 @@ declare const tokens: ({
|
|
|
108
149
|
state: string;
|
|
109
150
|
introduced: string;
|
|
110
151
|
description: string;
|
|
152
|
+
deprecated?: undefined;
|
|
153
|
+
deleted?: undefined;
|
|
111
154
|
replacement?: undefined;
|
|
112
155
|
};
|
|
113
156
|
value: {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from '../artifacts/palettes-raw';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { getCSSCustomProperty, getTokenId, getFullyQualifiedTokenId, } from '../token-ids';
|
|
1
|
+
export { getCSSCustomProperty, getTokenId, getFullyQualifiedTokenId, } from '../utils/token-ids';
|
package/dist/types/types.d.ts
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import { InternalTokenIds } from './artifacts/types-internal';
|
|
2
2
|
export declare type Groups = 'raw' | 'paint' | 'shadow' | 'palette';
|
|
3
|
-
export declare type
|
|
4
|
-
export declare type
|
|
5
|
-
export declare type
|
|
3
|
+
export declare type ActiveTokenState = 'active';
|
|
4
|
+
export declare type DeprecatedTokenState = 'deprecated';
|
|
5
|
+
export declare type DeletedTokenState = 'deleted';
|
|
6
|
+
export declare type TokenState = ActiveTokenState | DeprecatedTokenState | DeletedTokenState;
|
|
6
7
|
export declare type Replacement = InternalTokenIds | InternalTokenIds[];
|
|
8
|
+
export declare type PaletteCategory = 'blue' | 'purple' | 'red' | 'magenta' | 'orange' | 'yellow' | 'green' | 'teal' | 'light neutral' | 'dark neutral';
|
|
7
9
|
export interface Token<TValue, Group extends Groups> {
|
|
8
10
|
value: TValue;
|
|
9
11
|
attributes: {
|
|
@@ -28,16 +30,24 @@ export interface BaseToken<TValue, Group extends Groups> extends Token<TValue, G
|
|
|
28
30
|
*/
|
|
29
31
|
export interface DesignToken<TValue, Group extends Groups> extends Token<TValue, Group> {
|
|
30
32
|
attributes: {
|
|
33
|
+
state: ActiveTokenState;
|
|
31
34
|
group: Group;
|
|
32
35
|
description: string;
|
|
33
|
-
state: ActiveTokenStates;
|
|
34
36
|
introduced: string;
|
|
35
|
-
replacement?: undefined;
|
|
36
37
|
} | {
|
|
38
|
+
state: DeprecatedTokenState;
|
|
37
39
|
group: Group;
|
|
38
40
|
description: string;
|
|
39
|
-
state: ReplacedTokenStates;
|
|
40
41
|
introduced: string;
|
|
42
|
+
deprecated: string;
|
|
43
|
+
replacement?: Replacement;
|
|
44
|
+
} | {
|
|
45
|
+
state: DeletedTokenState;
|
|
46
|
+
group: Group;
|
|
47
|
+
description: string;
|
|
48
|
+
introduced: string;
|
|
49
|
+
deprecated: string;
|
|
50
|
+
deleted: string;
|
|
41
51
|
replacement?: Replacement;
|
|
42
52
|
};
|
|
43
53
|
}
|
|
@@ -50,7 +60,12 @@ declare type DeepOmit<T extends any, K extends PropertyKey> = Omit<{
|
|
|
50
60
|
}, K>;
|
|
51
61
|
export declare type ValueSchema<Schema extends object> = DeepOmit<Schema, 'attributes'>;
|
|
52
62
|
export declare type AttributeSchema<Schema extends object> = DeepOmit<Schema, 'value'>;
|
|
53
|
-
export
|
|
63
|
+
export interface PaletteToken extends BaseToken<string, 'palette'> {
|
|
64
|
+
attributes: {
|
|
65
|
+
group: 'palette';
|
|
66
|
+
category: PaletteCategory;
|
|
67
|
+
};
|
|
68
|
+
}
|
|
54
69
|
export declare type ColorPalette = keyof PaletteColorTokenSchema['color']['palette'];
|
|
55
70
|
export declare type PaintToken<Value extends string = ColorPalette> = DesignToken<Value, 'paint'>;
|
|
56
71
|
export declare type ShadowToken<Value extends string = ColorPalette> = DesignToken<Array<{
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { ShadowToken } from '../types';
|
|
2
|
+
export declare const hexToRGBAValues: (hex: string) => {
|
|
3
|
+
r: number;
|
|
4
|
+
g: number;
|
|
5
|
+
b: number;
|
|
6
|
+
a: number;
|
|
7
|
+
};
|
|
8
|
+
export declare const hexToRGBA: (hex: string) => string;
|
|
9
|
+
export declare const getLuminance: ({ r, g, b, }: {
|
|
10
|
+
r: number;
|
|
11
|
+
b: number;
|
|
12
|
+
g: number;
|
|
13
|
+
}) => number;
|
|
14
|
+
/**
|
|
15
|
+
* Returns an accessible hard-coded text color based on the color contrast with
|
|
16
|
+
* the background.
|
|
17
|
+
*
|
|
18
|
+
* @param hex - The Hex color code of the background
|
|
19
|
+
* @param [opts.hardcodedSurface] - If set, a design token will be returned instead
|
|
20
|
+
* of a hard-coded color. This is to support more transparent backgrounds
|
|
21
|
+
* to allow the text to invert colors depending on the current theme's surface color.
|
|
22
|
+
*/
|
|
23
|
+
export declare const getTextColorForBackground: (hex: string, opts?: {
|
|
24
|
+
hardcodedSurface?: "light" | "dark" | undefined;
|
|
25
|
+
} | undefined) => string;
|
|
26
|
+
/**
|
|
27
|
+
* Returns a border if determined to be required based on the color contrast with
|
|
28
|
+
* the background.
|
|
29
|
+
*
|
|
30
|
+
* @param hex - The Hex color code of the background
|
|
31
|
+
*/
|
|
32
|
+
export declare const getBorderForBackground: (hex: string) => string | undefined;
|
|
33
|
+
/**
|
|
34
|
+
* Returns a box shadow formatted for CSS from a ShadowToken raw value.
|
|
35
|
+
*
|
|
36
|
+
* @param rawShadow - ShadowToken raw value
|
|
37
|
+
*/
|
|
38
|
+
export declare const getBoxShadow: (rawShadow: ShadowToken['value']) => string;
|
|
File without changes
|
package/package.json
CHANGED
|
@@ -1,15 +1,18 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/tokens",
|
|
3
|
-
"version": "0.9.
|
|
3
|
+
"version": "0.9.2",
|
|
4
4
|
"author": "Atlassian Pty Ltd",
|
|
5
|
-
"description": "
|
|
5
|
+
"description": "Design tokens are the single source of truth to name and store design decisions.",
|
|
6
6
|
"license": "Apache-2.0",
|
|
7
7
|
"publishConfig": {
|
|
8
8
|
"registry": "https://registry.npmjs.org/"
|
|
9
9
|
},
|
|
10
10
|
"atlassian": {
|
|
11
11
|
"team": "Design System Team",
|
|
12
|
-
"releaseModel": "scheduled"
|
|
12
|
+
"releaseModel": "scheduled",
|
|
13
|
+
"website": {
|
|
14
|
+
"name": "Design tokens"
|
|
15
|
+
}
|
|
13
16
|
},
|
|
14
17
|
"repository": "https://bitbucket.org/atlassian/atlassian-frontend",
|
|
15
18
|
"main": "dist/cjs/index.js",
|
|
@@ -22,6 +25,7 @@
|
|
|
22
25
|
"atlaskit:src": "src/index.tsx",
|
|
23
26
|
"af:exports": {
|
|
24
27
|
".": "./src/index.tsx",
|
|
28
|
+
"./palettes-raw": "./src/entry-points/palettes-raw.tsx",
|
|
25
29
|
"./token-ids": "./src/entry-points/token-ids.tsx",
|
|
26
30
|
"./token-names": "./src/entry-points/token-names.tsx",
|
|
27
31
|
"./rename-mapping": "./src/entry-points/rename-mapping.tsx",
|
|
@@ -41,8 +45,12 @@
|
|
|
41
45
|
"@babel/types": "^7.15.0"
|
|
42
46
|
},
|
|
43
47
|
"devDependencies": {
|
|
48
|
+
"@atlaskit/badge": "^15.0.11",
|
|
44
49
|
"@atlaskit/button": "^16.3.0",
|
|
45
50
|
"@atlaskit/code": "^14.3.0",
|
|
51
|
+
"@atlaskit/docs": "^9.0.10",
|
|
52
|
+
"@atlaskit/dropdown-menu": "^11.1.3",
|
|
53
|
+
"@atlaskit/empty-state": "^7.3.9",
|
|
46
54
|
"@atlaskit/focus-ring": "^1.0.0",
|
|
47
55
|
"@atlaskit/heading": "^0.1.8",
|
|
48
56
|
"@atlaskit/icon": "^21.10.2",
|
|
@@ -53,6 +61,7 @@
|
|
|
53
61
|
"@atlaskit/textfield": "^5.1.5",
|
|
54
62
|
"@atlaskit/theme": "^12.1.2",
|
|
55
63
|
"@atlaskit/toggle": "^12.4.2",
|
|
64
|
+
"@atlaskit/tooltip": "^17.5.7",
|
|
56
65
|
"@atlassian/atlassian-frontend-prettier-config-1.0.1": "npm:@atlassian/atlassian-frontend-prettier-config@1.0.1",
|
|
57
66
|
"@babel/core": "^7.12.3",
|
|
58
67
|
"@emotion/core": "^10.0.9",
|
|
@@ -77,5 +86,6 @@
|
|
|
77
86
|
"styling": "emotion"
|
|
78
87
|
}
|
|
79
88
|
},
|
|
89
|
+
"homepage": "https://atlassian.design/",
|
|
80
90
|
"prettier": "@atlassian/atlassian-frontend-prettier-config-1.0.1"
|
|
81
91
|
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@atlaskit/tokens/palettes-raw",
|
|
3
|
+
"main": "../dist/cjs/entry-points/palettes-raw.js",
|
|
4
|
+
"module": "../dist/esm/entry-points/palettes-raw.js",
|
|
5
|
+
"module:es2019": "../dist/es2019/entry-points/palettes-raw.js",
|
|
6
|
+
"sideEffects": [
|
|
7
|
+
"**/*.css"
|
|
8
|
+
],
|
|
9
|
+
"types": "../dist/types/entry-points/palettes-raw.d.ts"
|
|
10
|
+
}
|
|
@@ -3,5 +3,8 @@
|
|
|
3
3
|
"main": "../dist/cjs/entry-points/rename-mapping.js",
|
|
4
4
|
"module": "../dist/esm/entry-points/rename-mapping.js",
|
|
5
5
|
"module:es2019": "../dist/es2019/entry-points/rename-mapping.js",
|
|
6
|
+
"sideEffects": [
|
|
7
|
+
"**/*.css"
|
|
8
|
+
],
|
|
6
9
|
"types": "../dist/types/entry-points/rename-mapping.d.ts"
|
|
7
10
|
}
|
package/token-ids/package.json
CHANGED
package/token-names/package.json
CHANGED
|
@@ -3,5 +3,8 @@
|
|
|
3
3
|
"main": "../dist/cjs/entry-points/token-names.js",
|
|
4
4
|
"module": "../dist/esm/entry-points/token-names.js",
|
|
5
5
|
"module:es2019": "../dist/es2019/entry-points/token-names.js",
|
|
6
|
+
"sideEffects": [
|
|
7
|
+
"**/*.css"
|
|
8
|
+
],
|
|
6
9
|
"types": "../dist/types/entry-points/token-names.d.ts"
|
|
7
10
|
}
|