@atlaskit/code 14.3.0 → 14.3.3
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 +23 -0
- package/__perf__/default.tsx +1 -1
- package/codemods/__tests__/14.0.0-lite-mode/14.0.0-lite-mode.ts +10 -10
- package/codemods/__tests__/14.0.0-lite-mode/remove-language.ts +6 -6
- package/codemods/__tests__/14.0.0-lite-mode/text-to-child.ts +10 -10
- package/dist/cjs/bidi-warning/bidi-warning-decorator.js +1 -1
- package/dist/cjs/bidi-warning/ui/index.js +3 -1
- package/dist/cjs/bidi-warning/ui/styled.js +4 -3
- package/dist/cjs/code.js +6 -4
- package/dist/cjs/index.js +6 -6
- package/dist/cjs/internal/hooks/use-highlight.js +2 -2
- package/dist/cjs/internal/theme/constants.js +1 -1
- package/dist/cjs/internal/theme/get-theme.js +99 -99
- package/dist/cjs/internal/theme/styles.js +4 -3
- package/dist/cjs/react-syntax-highlighter-bidi-warning-renderer.js +4 -4
- package/dist/cjs/version.json +1 -1
- package/dist/es2019/bidi-warning/ui/styled.js +4 -3
- package/dist/es2019/internal/theme/get-theme.js +96 -96
- package/dist/es2019/internal/theme/styles.js +1 -0
- package/dist/es2019/version.json +1 -1
- package/dist/esm/bidi-warning/ui/index.js +2 -1
- package/dist/esm/bidi-warning/ui/styled.js +4 -3
- package/dist/esm/code.js +4 -2
- package/dist/esm/internal/hooks/use-highlight.js +2 -2
- package/dist/esm/internal/theme/get-theme.js +98 -98
- package/dist/esm/internal/theme/styles.js +3 -2
- package/dist/esm/react-syntax-highlighter-bidi-warning-renderer.js +2 -2
- package/dist/esm/version.json +1 -1
- package/dist/types/bidi-warning/ui/index.d.ts +1 -0
- package/package.json +10 -9
|
@@ -7,7 +7,7 @@ var _typeof = require("@babel/runtime/helpers/typeof");
|
|
|
7
7
|
Object.defineProperty(exports, "__esModule", {
|
|
8
8
|
value: true
|
|
9
9
|
});
|
|
10
|
-
exports.
|
|
10
|
+
exports.getColorPalette = exports.getBaseTheme = exports.defaultBaseTheme = exports.default = void 0;
|
|
11
11
|
|
|
12
12
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
13
13
|
|
|
@@ -23,9 +23,9 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
|
|
|
23
23
|
|
|
24
24
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
25
25
|
|
|
26
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object);
|
|
26
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
27
27
|
|
|
28
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
28
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2.default)(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
29
29
|
|
|
30
30
|
// Hardcoded values have been used due to the current color palette not having any
|
|
31
31
|
// accessible color options for Teal and Yellow and +20A
|
|
@@ -38,26 +38,26 @@ var getBaseTheme = function getBaseTheme(theme) {
|
|
|
38
38
|
fontFamily: (0, _constants.codeFontFamily)(),
|
|
39
39
|
fontFamilyItalic: "SFMono-MediumItalic, ".concat((0, _constants.codeFontFamily)()),
|
|
40
40
|
backgroundColor: (0, _components.themed)({
|
|
41
|
-
light: colors.N20,
|
|
42
|
-
dark: colors.DN50
|
|
41
|
+
light: "var(--ds-background-neutral, ".concat(colors.N20, ")"),
|
|
42
|
+
dark: "var(--ds-background-neutral, ".concat(colors.DN50, ")")
|
|
43
43
|
})({
|
|
44
44
|
theme: theme
|
|
45
45
|
}),
|
|
46
46
|
textColor: (0, _components.themed)({
|
|
47
|
-
light: colors.N800,
|
|
48
|
-
dark: colors.DN800
|
|
47
|
+
light: "var(--ds-text, ".concat(colors.N800, ")"),
|
|
48
|
+
dark: "var(--ds-text, ".concat(colors.DN800, ")")
|
|
49
49
|
})({
|
|
50
50
|
theme: theme
|
|
51
51
|
}),
|
|
52
52
|
lineNumberColor: (0, _components.themed)({
|
|
53
|
-
light: colors.N400,
|
|
54
|
-
dark: colors.DN400
|
|
53
|
+
light: "var(--ds-text-subtlest, ".concat(colors.N400, ")"),
|
|
54
|
+
dark: "var(--ds-text-subtlest, ".concat(colors.DN400, ")")
|
|
55
55
|
})({
|
|
56
56
|
theme: theme
|
|
57
57
|
}),
|
|
58
58
|
lineNumberBgColor: (0, _components.themed)({
|
|
59
|
-
light: colors.N30,
|
|
60
|
-
dark: colors.DN20
|
|
59
|
+
light: "var(--ds-background-neutral, ".concat(colors.N30, ")"),
|
|
60
|
+
dark: "var(--ds-background-neutral, ".concat(colors.DN20, ")")
|
|
61
61
|
})({
|
|
62
62
|
theme: theme
|
|
63
63
|
})
|
|
@@ -75,180 +75,180 @@ var getColorPalette = (0, _memoizeOne.default)(function (theme) {
|
|
|
75
75
|
};
|
|
76
76
|
return {
|
|
77
77
|
highlightedLineBgColor: (0, _components.themed)({
|
|
78
|
-
light: colors.N30,
|
|
79
|
-
dark: PLUS20
|
|
78
|
+
light: "var(--ds-background-neutral, ".concat(colors.N30, ")"),
|
|
79
|
+
dark: "var(--ds-background-neutral, ".concat(PLUS20, ")")
|
|
80
80
|
})(akTheme),
|
|
81
81
|
highlightedLineBorderColor: (0, _components.themed)({
|
|
82
|
-
light: colors.B200,
|
|
83
|
-
dark: colors.B100
|
|
82
|
+
light: "var(--ds-border-focused, ".concat(colors.B200, ")"),
|
|
83
|
+
dark: "var(--ds-border-focused, ".concat(colors.B100, ")")
|
|
84
84
|
})(akTheme),
|
|
85
85
|
substringColor: (0, _components.themed)({
|
|
86
|
-
light: colors.N400,
|
|
87
|
-
dark: colors.DN400
|
|
86
|
+
light: "var(--ds-text-subtlest, ".concat(colors.N400, ")"),
|
|
87
|
+
dark: "var(--ds-text-subtlest, ".concat(colors.DN400, ")")
|
|
88
88
|
})(akTheme),
|
|
89
89
|
keywordColor: (0, _components.themed)({
|
|
90
|
-
light: colors.B400,
|
|
91
|
-
dark: colors.B75
|
|
90
|
+
light: "var(--ds-text-accent-blue, ".concat(colors.B400, ")"),
|
|
91
|
+
dark: "var(--ds-text-accent-blue, ".concat(colors.B75, ")")
|
|
92
92
|
})(akTheme),
|
|
93
93
|
attributeColor: (0, _components.themed)({
|
|
94
|
-
light: T800,
|
|
95
|
-
dark: colors.T200
|
|
94
|
+
light: "var(--ds-text-accent-teal, ".concat(T800, ")"),
|
|
95
|
+
dark: "var(--ds-text-accent-teal, ".concat(colors.T200, ")")
|
|
96
96
|
})(akTheme),
|
|
97
97
|
selectorTagColor: (0, _components.themed)({
|
|
98
|
-
light: colors.B400,
|
|
99
|
-
dark: colors.B75
|
|
98
|
+
light: "var(--ds-text-accent-blue, ".concat(colors.B400, ")"),
|
|
99
|
+
dark: "var(--ds-text-accent-blue, ".concat(colors.B75, ")")
|
|
100
100
|
})(akTheme),
|
|
101
101
|
docTagColor: (0, _components.themed)({
|
|
102
|
-
light: Y1100,
|
|
103
|
-
dark: colors.Y300
|
|
102
|
+
light: "var(--ds-text-accent-yellow, ".concat(Y1100, ")"),
|
|
103
|
+
dark: "var(--ds-text-accent-yellow, ".concat(colors.Y300, ")")
|
|
104
104
|
})(akTheme),
|
|
105
105
|
nameColor: (0, _components.themed)({
|
|
106
|
-
light: colors.B400,
|
|
107
|
-
dark: colors.B75
|
|
106
|
+
light: "var(--ds-text-accent-blue, ".concat(colors.B400, ")"),
|
|
107
|
+
dark: "var(--ds-text-accent-blue, ".concat(colors.B75, ")")
|
|
108
108
|
})(akTheme),
|
|
109
109
|
builtInColor: (0, _components.themed)({
|
|
110
|
-
light: colors.B400,
|
|
111
|
-
dark: colors.B75
|
|
110
|
+
light: "var(--ds-text-accent-blue, ".concat(colors.B400, ")"),
|
|
111
|
+
dark: "var(--ds-text-accent-blue, ".concat(colors.B75, ")")
|
|
112
112
|
})(akTheme),
|
|
113
113
|
literalColor: (0, _components.themed)({
|
|
114
|
-
light: colors.B400,
|
|
115
|
-
dark: colors.B75
|
|
114
|
+
light: "var(--ds-text-accent-blue, ".concat(colors.B400, ")"),
|
|
115
|
+
dark: "var(--ds-text-accent-blue, ".concat(colors.B75, ")")
|
|
116
116
|
})(akTheme),
|
|
117
117
|
bulletColor: (0, _components.themed)({
|
|
118
|
-
light: colors.B400,
|
|
119
|
-
dark: colors.B75
|
|
118
|
+
light: "var(--ds-text-accent-blue, ".concat(colors.B400, ")"),
|
|
119
|
+
dark: "var(--ds-text-accent-blue, ".concat(colors.B75, ")")
|
|
120
120
|
})(akTheme),
|
|
121
121
|
codeColor: (0, _components.themed)({
|
|
122
|
-
light: colors.B400,
|
|
123
|
-
dark: colors.B75
|
|
122
|
+
light: "var(--ds-text-accent-blue, ".concat(colors.B400, ")"),
|
|
123
|
+
dark: "var(--ds-text-accent-blue, ".concat(colors.B75, ")")
|
|
124
124
|
})(akTheme),
|
|
125
125
|
regexpColor: (0, _components.themed)({
|
|
126
|
-
light: T800,
|
|
127
|
-
dark: colors.T200
|
|
126
|
+
light: "var(--ds-text-accent-teal, ".concat(T800, ")"),
|
|
127
|
+
dark: "var(--ds-text-accent-teal, ".concat(colors.T200, ")")
|
|
128
128
|
})(akTheme),
|
|
129
129
|
symbolColor: (0, _components.themed)({
|
|
130
|
-
light: T800,
|
|
131
|
-
dark: colors.T200
|
|
130
|
+
light: "var(--ds-text-accent-teal, ".concat(T800, ")"),
|
|
131
|
+
dark: "var(--ds-text-accent-teal, ".concat(colors.T200, ")")
|
|
132
132
|
})(akTheme),
|
|
133
133
|
variableColor: (0, _components.themed)({
|
|
134
|
-
light: T800,
|
|
135
|
-
dark: colors.T200
|
|
134
|
+
light: "var(--ds-text-accent-teal, ".concat(T800, ")"),
|
|
135
|
+
dark: "var(--ds-text-accent-teal, ".concat(colors.T200, ")")
|
|
136
136
|
})(akTheme),
|
|
137
137
|
templateVariableColor: (0, _components.themed)({
|
|
138
|
-
light: T800,
|
|
139
|
-
dark: colors.T200
|
|
138
|
+
light: "var(--ds-text-accent-teal, ".concat(T800, ")"),
|
|
139
|
+
dark: "var(--ds-text-accent-teal, ".concat(colors.T200, ")")
|
|
140
140
|
})(akTheme),
|
|
141
141
|
linkColor: (0, _components.themed)({
|
|
142
|
-
light: colors.P300,
|
|
143
|
-
dark: colors.P75
|
|
142
|
+
light: "var(--ds-text-accent-purple, ".concat(colors.P300, ")"),
|
|
143
|
+
dark: "var(--ds-text-accent-purple, ".concat(colors.P75, ")")
|
|
144
144
|
})(akTheme),
|
|
145
145
|
selectorAttributeColor: (0, _components.themed)({
|
|
146
|
-
light: T800,
|
|
147
|
-
dark: colors.T200
|
|
146
|
+
light: "var(--ds-text-accent-teal, ".concat(T800, ")"),
|
|
147
|
+
dark: "var(--ds-text-accent-teal, ".concat(colors.T200, ")")
|
|
148
148
|
})(akTheme),
|
|
149
149
|
selectorPseudoColor: (0, _components.themed)({
|
|
150
|
-
light: T800,
|
|
151
|
-
dark: colors.T200
|
|
150
|
+
light: "var(--ds-text-accent-teal, ".concat(T800, ")"),
|
|
151
|
+
dark: "var(--ds-text-accent-teal, ".concat(colors.T200, ")")
|
|
152
152
|
})(akTheme),
|
|
153
153
|
typeColor: (0, _components.themed)({
|
|
154
|
-
light: T800,
|
|
155
|
-
dark: colors.T100
|
|
154
|
+
light: "var(--ds-text-accent-teal, ".concat(T800, ")"),
|
|
155
|
+
dark: "var(--ds-text-accent-teal, ".concat(colors.T100, ")")
|
|
156
156
|
})(akTheme),
|
|
157
157
|
stringColor: (0, _components.themed)({
|
|
158
|
-
light: colors.G500,
|
|
159
|
-
dark: colors.G200
|
|
158
|
+
light: "var(--ds-text-accent-green, ".concat(colors.G500, ")"),
|
|
159
|
+
dark: "var(--ds-text-accent-green, ".concat(colors.G200, ")")
|
|
160
160
|
})(akTheme),
|
|
161
161
|
selectorIdColor: (0, _components.themed)({
|
|
162
|
-
light: T800,
|
|
163
|
-
dark: colors.T100
|
|
162
|
+
light: "var(--ds-text-accent-teal, ".concat(T800, ")"),
|
|
163
|
+
dark: "var(--ds-text-accent-teal, ".concat(colors.T100, ")")
|
|
164
164
|
})(akTheme),
|
|
165
165
|
selectorClassColor: (0, _components.themed)({
|
|
166
|
-
light: T800,
|
|
167
|
-
dark: colors.T100
|
|
166
|
+
light: "var(--ds-text-accent-teal, ".concat(T800, ")"),
|
|
167
|
+
dark: "var(--ds-text-accent-teal, ".concat(colors.T100, ")")
|
|
168
168
|
})(akTheme),
|
|
169
169
|
quoteColor: (0, _components.themed)({
|
|
170
|
-
light: T800,
|
|
171
|
-
dark: colors.T100
|
|
170
|
+
light: "var(--ds-text-accent-teal, ".concat(T800, ")"),
|
|
171
|
+
dark: "var(--ds-text-accent-teal, ".concat(colors.T100, ")")
|
|
172
172
|
})(akTheme),
|
|
173
173
|
templateTagColor: (0, _components.themed)({
|
|
174
|
-
light: T800,
|
|
175
|
-
dark: colors.T100
|
|
174
|
+
light: "var(--ds-text-accent-teal, ".concat(T800, ")"),
|
|
175
|
+
dark: "var(--ds-text-accent-teal, ".concat(colors.T100, ")")
|
|
176
176
|
})(akTheme),
|
|
177
177
|
titleColor: (0, _components.themed)({
|
|
178
|
-
light: colors.P300,
|
|
179
|
-
dark: colors.P75
|
|
178
|
+
light: "var(--ds-text-accent-purple, ".concat(colors.P300, ")"),
|
|
179
|
+
dark: "var(--ds-text-accent-purple, ".concat(colors.P75, ")")
|
|
180
180
|
})(akTheme),
|
|
181
181
|
sectionColor: (0, _components.themed)({
|
|
182
|
-
light: colors.P300,
|
|
183
|
-
dark: colors.P75
|
|
182
|
+
light: "var(--ds-text-accent-purple, ".concat(colors.P300, ")"),
|
|
183
|
+
dark: "var(--ds-text-accent-purple, ".concat(colors.P75, ")")
|
|
184
184
|
})(akTheme),
|
|
185
185
|
commentColor: (0, _components.themed)({
|
|
186
|
-
light: colors.N400,
|
|
187
|
-
dark: colors.DN400
|
|
186
|
+
light: "var(--ds-text-subtlest, ".concat(colors.N400, ")"),
|
|
187
|
+
dark: "var(--ds-text-subtlest, ".concat(colors.DN400, ")")
|
|
188
188
|
})(akTheme),
|
|
189
189
|
metaKeywordColor: (0, _components.themed)({
|
|
190
|
-
light: colors.G500,
|
|
191
|
-
dark: colors.G200
|
|
190
|
+
light: "var(--ds-text-accent-green, ".concat(colors.G500, ")"),
|
|
191
|
+
dark: "var(--ds-text-accent-green, ".concat(colors.G200, ")")
|
|
192
192
|
})(akTheme),
|
|
193
193
|
metaColor: (0, _components.themed)({
|
|
194
|
-
light: colors.N400,
|
|
195
|
-
dark: colors.DN400
|
|
194
|
+
light: "var(--ds-text-subtlest, ".concat(colors.N400, ")"),
|
|
195
|
+
dark: "var(--ds-text-subtlest, ".concat(colors.DN400, ")")
|
|
196
196
|
})(akTheme),
|
|
197
197
|
functionColor: (0, _components.themed)({
|
|
198
|
-
light: colors.N800,
|
|
199
|
-
dark: colors.DN800
|
|
198
|
+
light: "var(--ds-text, ".concat(colors.N800, ")"),
|
|
199
|
+
dark: "var(--ds-text, ".concat(colors.DN800, ")")
|
|
200
200
|
})(akTheme),
|
|
201
201
|
numberColor: (0, _components.themed)({
|
|
202
|
-
light: colors.B400,
|
|
203
|
-
dark: colors.B75
|
|
202
|
+
light: "var(--ds-text-accent-blue, ".concat(colors.B400, ")"),
|
|
203
|
+
dark: "var(--ds-text-accent-blue, ".concat(colors.B75, ")")
|
|
204
204
|
})(akTheme),
|
|
205
205
|
prologColor: (0, _components.themed)({
|
|
206
|
-
light: colors.B400,
|
|
207
|
-
dark: colors.B75
|
|
206
|
+
light: "var(--ds-text-accent-blue, ".concat(colors.B400, ")"),
|
|
207
|
+
dark: "var(--ds-text-accent-blue, ".concat(colors.B75, ")")
|
|
208
208
|
})(akTheme),
|
|
209
209
|
cdataColor: (0, _components.themed)({
|
|
210
|
-
light: colors.N400,
|
|
211
|
-
dark: colors.B75
|
|
210
|
+
light: "var(--ds-text-subtlest, ".concat(colors.N400, ")"),
|
|
211
|
+
dark: "var(--ds-text-subtlest, ".concat(colors.B75, ")")
|
|
212
212
|
})(akTheme),
|
|
213
213
|
punctuationColor: (0, _components.themed)({
|
|
214
|
-
light: colors.N800,
|
|
215
|
-
dark: colors.DN800
|
|
214
|
+
light: "var(--ds-text, ".concat(colors.N800, ")"),
|
|
215
|
+
dark: "var(--ds-text, ".concat(colors.DN800, ")")
|
|
216
216
|
})(akTheme),
|
|
217
217
|
propertyColor: (0, _components.themed)({
|
|
218
|
-
light: colors.P300,
|
|
219
|
-
dark: colors.P75
|
|
218
|
+
light: "var(--ds-text-accent-purple, ".concat(colors.P300, ")"),
|
|
219
|
+
dark: "var(--ds-text-accent-purple, ".concat(colors.P75, ")")
|
|
220
220
|
})(akTheme),
|
|
221
221
|
constantColor: (0, _components.themed)({
|
|
222
|
-
light: T800,
|
|
223
|
-
dark: colors.T100
|
|
222
|
+
light: "var(--ds-text-accent-teal, ".concat(T800, ")"),
|
|
223
|
+
dark: "var(--ds-text-accent-teal, ".concat(colors.T100, ")")
|
|
224
224
|
})(akTheme),
|
|
225
225
|
booleanColor: (0, _components.themed)({
|
|
226
|
-
light: colors.
|
|
227
|
-
dark: colors.B75
|
|
226
|
+
light: "var(--ds-text-accent-blue, ".concat(colors.B400, ")"),
|
|
227
|
+
dark: "var(--ds-text-accent-blue, ".concat(colors.B75, ")")
|
|
228
228
|
})(akTheme),
|
|
229
229
|
charColor: (0, _components.themed)({
|
|
230
|
-
light: colors.N800,
|
|
231
|
-
dark: colors.DN800
|
|
230
|
+
light: "var(--ds-text, ".concat(colors.N800, ")"),
|
|
231
|
+
dark: "var(--ds-text, ".concat(colors.DN800, ")")
|
|
232
232
|
})(akTheme),
|
|
233
233
|
insertedColor: (0, _components.themed)({
|
|
234
|
-
light: colors.G500,
|
|
235
|
-
dark: colors.B75
|
|
234
|
+
light: "var(--ds-text-accent-green, ".concat(colors.G500, ")"),
|
|
235
|
+
dark: "var(--ds-text-accent-green, ".concat(colors.B75, ")")
|
|
236
236
|
})(akTheme),
|
|
237
237
|
deletedColor: (0, _components.themed)({
|
|
238
|
-
light: colors.R500,
|
|
239
|
-
dark: colors.B75
|
|
238
|
+
light: "var(--ds-text-accent-red, ".concat(colors.R500, ")"),
|
|
239
|
+
dark: "var(--ds-text-accent-red, ".concat(colors.B75, ")")
|
|
240
240
|
})(akTheme),
|
|
241
241
|
operatorColor: (0, _components.themed)({
|
|
242
|
-
light: colors.N800,
|
|
243
|
-
dark: colors.B75
|
|
242
|
+
light: "var(--ds-text, ".concat(colors.N800, ")"),
|
|
243
|
+
dark: "var(--ds-text, ".concat(colors.B75, ")")
|
|
244
244
|
})(akTheme),
|
|
245
245
|
atruleColor: (0, _components.themed)({
|
|
246
|
-
light: colors.G500,
|
|
247
|
-
dark: colors.G200
|
|
246
|
+
light: "var(--ds-text-accent-green, ".concat(colors.G500, ")"),
|
|
247
|
+
dark: "var(--ds-text-accent-green, ".concat(colors.G200, ")")
|
|
248
248
|
})(akTheme),
|
|
249
249
|
importantColor: (0, _components.themed)({
|
|
250
|
-
light: Y1100,
|
|
251
|
-
dark: colors.Y300
|
|
250
|
+
light: "var(--ds-text-accent-yellow, ".concat(Y1100, ")"),
|
|
251
|
+
dark: "var(--ds-text-accent-yellow, ".concat(colors.Y300, ")")
|
|
252
252
|
})(akTheme)
|
|
253
253
|
};
|
|
254
254
|
});
|
|
@@ -5,7 +5,7 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", {
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
|
-
exports.
|
|
8
|
+
exports.getLineNumWidth = exports.getCodeStyles = exports.getCodeBlockTheme = exports.getCodeBlockStyles = exports.getBaseCodeStyles = void 0;
|
|
9
9
|
|
|
10
10
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
11
11
|
|
|
@@ -15,9 +15,9 @@ var _constants2 = require("./constants");
|
|
|
15
15
|
|
|
16
16
|
var _getTheme = require("./get-theme");
|
|
17
17
|
|
|
18
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object);
|
|
18
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
19
19
|
|
|
20
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
20
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2.default)(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
21
21
|
|
|
22
22
|
var getLineNumWidth = function getLineNumWidth(numLines) {
|
|
23
23
|
if (!numLines) {
|
|
@@ -250,6 +250,7 @@ var getCodeBlockStyles = function getCodeBlockStyles(theme) {
|
|
|
250
250
|
},
|
|
251
251
|
'& [data-ds--code--row--highlight]': {
|
|
252
252
|
background: "".concat(theme.highlightedLineBgColor),
|
|
253
|
+
// eslint-disable-next-line @atlaskit/design-system/use-visually-hidden
|
|
253
254
|
'&::before, &::after': {
|
|
254
255
|
clipPath: 'inset(100%)',
|
|
255
256
|
clip: 'rect(1px, 1px, 1px, 1px)',
|
|
@@ -6,9 +6,9 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
8
|
exports.createBidiWarningRenderer = createBidiWarningRenderer;
|
|
9
|
-
exports.createStyleObject = createStyleObject;
|
|
10
|
-
exports.createClassNameString = createClassNameString;
|
|
11
9
|
exports.createChildren = createChildren;
|
|
10
|
+
exports.createClassNameString = createClassNameString;
|
|
11
|
+
exports.createStyleObject = createStyleObject;
|
|
12
12
|
|
|
13
13
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
14
14
|
|
|
@@ -20,9 +20,9 @@ var _bidiWarning = _interopRequireDefault(require("./bidi-warning"));
|
|
|
20
20
|
|
|
21
21
|
var _bidiWarningDecorator = _interopRequireDefault(require("./bidi-warning/bidi-warning-decorator"));
|
|
22
22
|
|
|
23
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object);
|
|
23
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
24
24
|
|
|
25
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
25
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2.default)(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
26
26
|
|
|
27
27
|
function createBidiWarningRenderer(codeBidiWarningConfig) {
|
|
28
28
|
return function bidiWarningRenderer(_ref) {
|
package/dist/cjs/version.json
CHANGED
|
@@ -17,7 +17,7 @@ const decoration = css({
|
|
|
17
17
|
padding: '0 4px',
|
|
18
18
|
fontSize: '14px',
|
|
19
19
|
lineHeight: '18px',
|
|
20
|
-
background: Y75
|
|
20
|
+
background: `var(--ds-background-warning, ${Y75})`,
|
|
21
21
|
|
|
22
22
|
/**
|
|
23
23
|
* Ensures the decoration receives pointer events when it occurs with
|
|
@@ -29,11 +29,12 @@ const decoration = css({
|
|
|
29
29
|
content: '"<"attr(data-bidi-character-code)">"',
|
|
30
30
|
// This color is Y800 which is not yet rolled out
|
|
31
31
|
// https://hello.atlassian.net/wiki/spaces/~tswan/pages/1366555782?focusedCommentId=1370387374#comment-1370387374
|
|
32
|
-
color:
|
|
32
|
+
color: "var(--ds-text-warning, #7F5F01)",
|
|
33
33
|
fontStyle: 'normal'
|
|
34
34
|
},
|
|
35
35
|
':hover:before': {
|
|
36
|
-
color:
|
|
36
|
+
color: "var(--ds-text-warning, #533F04)",
|
|
37
|
+
background: `var(--ds-background-warning-hovered, ${Y75})`
|
|
37
38
|
}
|
|
38
39
|
});
|
|
39
40
|
export function Decorator({
|