@rocket.chat/css-in-js 0.6.3-dev.46 → 0.6.3-dev.460
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/LICENSE +1 -1
- package/README.md +54 -94
- package/dist/index.d.ts +5 -0
- package/dist/index.js +1 -968
- package/dist/index.js.map +1 -1
- package/dist/index.module.js +2 -0
- package/dist/index.module.js.map +1 -0
- package/dist/index.umd.js +2 -0
- package/dist/index.umd.js.map +1 -0
- package/dist/names.d.ts +3 -0
- package/dist/sheet.d.ts +8 -0
- package/dist/tags.d.ts +30 -0
- package/dist/transpile.d.ts +11 -0
- package/package.json +41 -32
- package/CHANGELOG.md +0 -86
- package/dist/index.mjs +0 -960
- package/dist/index.mjs.map +0 -1
package/dist/index.mjs
DELETED
|
@@ -1,960 +0,0 @@
|
|
|
1
|
-
function _typeof(obj) {
|
|
2
|
-
"@babel/helpers - typeof";
|
|
3
|
-
|
|
4
|
-
if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
|
|
5
|
-
_typeof = function (obj) {
|
|
6
|
-
return typeof obj;
|
|
7
|
-
};
|
|
8
|
-
} else {
|
|
9
|
-
_typeof = function (obj) {
|
|
10
|
-
return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
11
|
-
};
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
return _typeof(obj);
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
function _slicedToArray(arr, i) {
|
|
18
|
-
return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest();
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
function _toConsumableArray(arr) {
|
|
22
|
-
return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread();
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
function _arrayWithoutHoles(arr) {
|
|
26
|
-
if (Array.isArray(arr)) return _arrayLikeToArray(arr);
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
function _arrayWithHoles(arr) {
|
|
30
|
-
if (Array.isArray(arr)) return arr;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
function _iterableToArray(iter) {
|
|
34
|
-
if (typeof Symbol !== "undefined" && Symbol.iterator in Object(iter)) return Array.from(iter);
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
function _iterableToArrayLimit(arr, i) {
|
|
38
|
-
if (typeof Symbol === "undefined" || !(Symbol.iterator in Object(arr))) return;
|
|
39
|
-
var _arr = [];
|
|
40
|
-
var _n = true;
|
|
41
|
-
var _d = false;
|
|
42
|
-
var _e = undefined;
|
|
43
|
-
|
|
44
|
-
try {
|
|
45
|
-
for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) {
|
|
46
|
-
_arr.push(_s.value);
|
|
47
|
-
|
|
48
|
-
if (i && _arr.length === i) break;
|
|
49
|
-
}
|
|
50
|
-
} catch (err) {
|
|
51
|
-
_d = true;
|
|
52
|
-
_e = err;
|
|
53
|
-
} finally {
|
|
54
|
-
try {
|
|
55
|
-
if (!_n && _i["return"] != null) _i["return"]();
|
|
56
|
-
} finally {
|
|
57
|
-
if (_d) throw _e;
|
|
58
|
-
}
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
return _arr;
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
function _unsupportedIterableToArray(o, minLen) {
|
|
65
|
-
if (!o) return;
|
|
66
|
-
if (typeof o === "string") return _arrayLikeToArray(o, minLen);
|
|
67
|
-
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
68
|
-
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
69
|
-
if (n === "Map" || n === "Set") return Array.from(n);
|
|
70
|
-
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
function _arrayLikeToArray(arr, len) {
|
|
74
|
-
if (len == null || len > arr.length) len = arr.length;
|
|
75
|
-
|
|
76
|
-
for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
|
|
77
|
-
|
|
78
|
-
return arr2;
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
function _nonIterableSpread() {
|
|
82
|
-
throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
function _nonIterableRest() {
|
|
86
|
-
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
/* eslint-disable */
|
|
90
|
-
// Inspired by https://github.com/garycourt/murmurhash-js
|
|
91
|
-
// Ported from https://github.com/aappleby/smhasher/blob/61a0530f28277f2e850bfc39600ce61d02b518de/src/MurmurHash2.cpp#L37-L86
|
|
92
|
-
function murmur2(str) {
|
|
93
|
-
// 'm' and 'r' are mixing constants generated offline.
|
|
94
|
-
// They're not really 'magic', they just happen to work well.
|
|
95
|
-
// const m = 0x5bd1e995;
|
|
96
|
-
// const r = 24;
|
|
97
|
-
// Initialize the hash
|
|
98
|
-
var h = 0; // Mix 4 bytes at a time into the hash
|
|
99
|
-
|
|
100
|
-
var k,
|
|
101
|
-
i = 0,
|
|
102
|
-
len = str.length;
|
|
103
|
-
|
|
104
|
-
for (; len >= 4; ++i, len -= 4) {
|
|
105
|
-
k = str.charCodeAt(i) & 0xff | (str.charCodeAt(++i) & 0xff) << 8 | (str.charCodeAt(++i) & 0xff) << 16 | (str.charCodeAt(++i) & 0xff) << 24;
|
|
106
|
-
k =
|
|
107
|
-
/* Math.imul(k, m): */
|
|
108
|
-
(k & 0xffff) * 0x5bd1e995 + ((k >>> 16) * 0xe995 << 16);
|
|
109
|
-
k ^=
|
|
110
|
-
/* k >>> r: */
|
|
111
|
-
k >>> 24;
|
|
112
|
-
h =
|
|
113
|
-
/* Math.imul(k, m): */
|
|
114
|
-
(k & 0xffff) * 0x5bd1e995 + ((k >>> 16) * 0xe995 << 16) ^
|
|
115
|
-
/* Math.imul(h, m): */
|
|
116
|
-
(h & 0xffff) * 0x5bd1e995 + ((h >>> 16) * 0xe995 << 16);
|
|
117
|
-
} // Handle the last few bytes of the input array
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
switch (len) {
|
|
121
|
-
case 3:
|
|
122
|
-
h ^= (str.charCodeAt(i + 2) & 0xff) << 16;
|
|
123
|
-
|
|
124
|
-
case 2:
|
|
125
|
-
h ^= (str.charCodeAt(i + 1) & 0xff) << 8;
|
|
126
|
-
|
|
127
|
-
case 1:
|
|
128
|
-
h ^= str.charCodeAt(i) & 0xff;
|
|
129
|
-
h =
|
|
130
|
-
/* Math.imul(h, m): */
|
|
131
|
-
(h & 0xffff) * 0x5bd1e995 + ((h >>> 16) * 0xe995 << 16);
|
|
132
|
-
} // Do a few final mixes of the hash to ensure the last few
|
|
133
|
-
// bytes are well-incorporated.
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
h ^= h >>> 13;
|
|
137
|
-
h =
|
|
138
|
-
/* Math.imul(h, m): */
|
|
139
|
-
(h & 0xffff) * 0x5bd1e995 + ((h >>> 16) * 0xe995 << 16);
|
|
140
|
-
return ((h ^ h >>> 15) >>> 0).toString(36);
|
|
141
|
-
}
|
|
142
|
-
|
|
143
|
-
/**
|
|
144
|
-
* Creates a pair of selector and escaped selector for a CSS Modules content.
|
|
145
|
-
*
|
|
146
|
-
* @returns a pair of selectors in the format `rcx-@<content hash>`; the second element is escaped
|
|
147
|
-
* for use in CSS content
|
|
148
|
-
*/
|
|
149
|
-
|
|
150
|
-
var createSelector = function createSelector(content) {
|
|
151
|
-
var contentHash = murmur2(content);
|
|
152
|
-
return ["rcx-@".concat(contentHash), "rcx-\\@".concat(contentHash)];
|
|
153
|
-
};
|
|
154
|
-
|
|
155
|
-
var createReplacementsMapping = function createReplacementsMapping() {
|
|
156
|
-
var rules = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
|
|
157
|
-
return function (value) {
|
|
158
|
-
if (value === 0) {
|
|
159
|
-
return '0';
|
|
160
|
-
}
|
|
161
|
-
|
|
162
|
-
if (!value) {
|
|
163
|
-
return '';
|
|
164
|
-
}
|
|
165
|
-
|
|
166
|
-
if (typeof value === 'function') {
|
|
167
|
-
return value(rules);
|
|
168
|
-
}
|
|
169
|
-
|
|
170
|
-
return String(value);
|
|
171
|
-
};
|
|
172
|
-
};
|
|
173
|
-
/**
|
|
174
|
-
* Template string tag to declare CSS content chunks.
|
|
175
|
-
*
|
|
176
|
-
* @return a callback to render the CSS content
|
|
177
|
-
*/
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
var css = function css(slices) {
|
|
181
|
-
for (var _len = arguments.length, values = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
|
182
|
-
values[_key - 1] = arguments[_key];
|
|
183
|
-
}
|
|
184
|
-
|
|
185
|
-
return function () {
|
|
186
|
-
var rules = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
|
|
187
|
-
var replacements = values.map(createReplacementsMapping(rules));
|
|
188
|
-
return String.raw.apply(String, [slices].concat(_toConsumableArray(replacements)));
|
|
189
|
-
};
|
|
190
|
-
};
|
|
191
|
-
/**
|
|
192
|
-
* Template string tag to declare CSS `@keyframe` at-rules.
|
|
193
|
-
*
|
|
194
|
-
* @return a callback to render the CSS at-rule content
|
|
195
|
-
*/
|
|
196
|
-
|
|
197
|
-
var keyframes = function keyframes(slices) {
|
|
198
|
-
for (var _len2 = arguments.length, values = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
|
|
199
|
-
values[_key2 - 1] = arguments[_key2];
|
|
200
|
-
}
|
|
201
|
-
|
|
202
|
-
return function () {
|
|
203
|
-
var rules = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
|
|
204
|
-
var replacements = values.map(createReplacementsMapping(rules));
|
|
205
|
-
var content = String.raw.apply(String, [slices].concat(_toConsumableArray(replacements)));
|
|
206
|
-
|
|
207
|
-
var _createSelector = createSelector(content),
|
|
208
|
-
_createSelector2 = _slicedToArray(_createSelector, 2),
|
|
209
|
-
encodedAnimationName = _createSelector2[1];
|
|
210
|
-
|
|
211
|
-
rules.push("@keyframes ".concat(encodedAnimationName, "{").concat(content, "}"));
|
|
212
|
-
return encodedAnimationName;
|
|
213
|
-
};
|
|
214
|
-
};
|
|
215
|
-
|
|
216
|
-
var styleTagId = 'rcx-styles';
|
|
217
|
-
var styleTag;
|
|
218
|
-
|
|
219
|
-
var getStyleTag = function getStyleTag() {
|
|
220
|
-
if (!styleTag) {
|
|
221
|
-
styleTag = document.getElementById(styleTagId) || document.createElement('style');
|
|
222
|
-
styleTag.id = styleTagId;
|
|
223
|
-
styleTag.appendChild(document.createTextNode(''));
|
|
224
|
-
|
|
225
|
-
if (document.head) {
|
|
226
|
-
document.head.appendChild(styleTag);
|
|
227
|
-
}
|
|
228
|
-
}
|
|
229
|
-
/* ::
|
|
230
|
-
if (!(styleTag instanceof HTMLStyleElement)) {
|
|
231
|
-
throw new Error();
|
|
232
|
-
}
|
|
233
|
-
*/
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
return styleTag;
|
|
237
|
-
};
|
|
238
|
-
|
|
239
|
-
var styleSheet;
|
|
240
|
-
|
|
241
|
-
var getStyleSheet = function getStyleSheet() {
|
|
242
|
-
if (!styleSheet) {
|
|
243
|
-
var _styleTag = getStyleTag();
|
|
244
|
-
|
|
245
|
-
styleSheet = _styleTag.sheet || Array.from(document.styleSheets).find(function (_ref) {
|
|
246
|
-
var ownerNode = _ref.ownerNode;
|
|
247
|
-
return ownerNode === _styleTag;
|
|
248
|
-
});
|
|
249
|
-
}
|
|
250
|
-
/* ::
|
|
251
|
-
if (!(styleSheet instanceof CSSStyleSheet)) {
|
|
252
|
-
throw new Error();
|
|
253
|
-
}
|
|
254
|
-
*/
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
return styleSheet;
|
|
258
|
-
};
|
|
259
|
-
|
|
260
|
-
var attachRulesIntoTag = function attachRulesIntoTag(rules) {
|
|
261
|
-
var styleTag = getStyleTag();
|
|
262
|
-
var textNode = document.createTextNode(rules);
|
|
263
|
-
styleTag.appendChild(textNode);
|
|
264
|
-
return function () {
|
|
265
|
-
return textNode.remove();
|
|
266
|
-
};
|
|
267
|
-
};
|
|
268
|
-
|
|
269
|
-
var attachRulesIntoSheet = function attachRulesIntoSheet(rules) {
|
|
270
|
-
var styleSheet = getStyleSheet();
|
|
271
|
-
var index = styleSheet.insertRule("@media all{".concat(rules, "}"), styleSheet.cssRules.length);
|
|
272
|
-
var insertedRule = styleSheet.cssRules[index];
|
|
273
|
-
|
|
274
|
-
var findPredicate = function findPredicate(cssRule) {
|
|
275
|
-
return cssRule === insertedRule;
|
|
276
|
-
};
|
|
277
|
-
|
|
278
|
-
return function () {
|
|
279
|
-
var index = Array.prototype.findIndex.call(styleSheet.cssRules, findPredicate);
|
|
280
|
-
styleSheet.deleteRule(index);
|
|
281
|
-
};
|
|
282
|
-
};
|
|
283
|
-
/**
|
|
284
|
-
* Imediately attaches CSS rules into the style sheet.
|
|
285
|
-
*
|
|
286
|
-
* @return a callback to detach the rules
|
|
287
|
-
*/
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
var attachRules = function attachRules(rules) {
|
|
291
|
-
if (process.env.NODE_ENV === 'production' && !!CSSStyleSheet.prototype.insertRule) {
|
|
292
|
-
return attachRulesIntoSheet(rules);
|
|
293
|
-
}
|
|
294
|
-
|
|
295
|
-
return attachRulesIntoTag(rules);
|
|
296
|
-
};
|
|
297
|
-
var references = {};
|
|
298
|
-
/**
|
|
299
|
-
* References CSS rules into the style sheet.
|
|
300
|
-
*
|
|
301
|
-
* Each time this function is called with the same rules a internal reference counter for it
|
|
302
|
-
* is incremented; when the unreference callback returned by this function is called, the reference
|
|
303
|
-
* counter is decremented. If the counter reaches zero references, the rules are detached from
|
|
304
|
-
* style sheet.
|
|
305
|
-
*
|
|
306
|
-
* @return a callback to unreference the rules
|
|
307
|
-
*/
|
|
308
|
-
|
|
309
|
-
var referenceRules = function referenceRules(rules) {
|
|
310
|
-
if (!rules) {
|
|
311
|
-
return function () {};
|
|
312
|
-
}
|
|
313
|
-
|
|
314
|
-
var reference = references[rules] || {
|
|
315
|
-
count: 0
|
|
316
|
-
};
|
|
317
|
-
references[rules] = reference;
|
|
318
|
-
|
|
319
|
-
if (reference.count === 0) {
|
|
320
|
-
reference.detachRules = attachRules(rules);
|
|
321
|
-
}
|
|
322
|
-
|
|
323
|
-
++reference.count;
|
|
324
|
-
return function () {
|
|
325
|
-
--reference.count;
|
|
326
|
-
|
|
327
|
-
if (reference.count === 0) {
|
|
328
|
-
(0, reference.detachRules)();
|
|
329
|
-
}
|
|
330
|
-
};
|
|
331
|
-
};
|
|
332
|
-
|
|
333
|
-
function stylis_min(W) {
|
|
334
|
-
function M(d, c, e, h, a) {
|
|
335
|
-
for (var m = 0, b = 0, v = 0, n = 0, q, g, x = 0, K = 0, k, u = k = q = 0, l = 0, r = 0, I = 0, t = 0, B = e.length, J = B - 1, y, f = '', p = '', F = '', G = '', C; l < B;) {
|
|
336
|
-
g = e.charCodeAt(l);
|
|
337
|
-
l === J && 0 !== b + n + v + m && (0 !== b && (g = 47 === b ? 10 : 47), n = v = m = 0, B++, J++);
|
|
338
|
-
|
|
339
|
-
if (0 === b + n + v + m) {
|
|
340
|
-
if (l === J && (0 < r && (f = f.replace(N, '')), 0 < f.trim().length)) {
|
|
341
|
-
switch (g) {
|
|
342
|
-
case 32:
|
|
343
|
-
case 9:
|
|
344
|
-
case 59:
|
|
345
|
-
case 13:
|
|
346
|
-
case 10:
|
|
347
|
-
break;
|
|
348
|
-
|
|
349
|
-
default:
|
|
350
|
-
f += e.charAt(l);
|
|
351
|
-
}
|
|
352
|
-
|
|
353
|
-
g = 59;
|
|
354
|
-
}
|
|
355
|
-
|
|
356
|
-
switch (g) {
|
|
357
|
-
case 123:
|
|
358
|
-
f = f.trim();
|
|
359
|
-
q = f.charCodeAt(0);
|
|
360
|
-
k = 1;
|
|
361
|
-
|
|
362
|
-
for (t = ++l; l < B;) {
|
|
363
|
-
switch (g = e.charCodeAt(l)) {
|
|
364
|
-
case 123:
|
|
365
|
-
k++;
|
|
366
|
-
break;
|
|
367
|
-
|
|
368
|
-
case 125:
|
|
369
|
-
k--;
|
|
370
|
-
break;
|
|
371
|
-
|
|
372
|
-
case 47:
|
|
373
|
-
switch (g = e.charCodeAt(l + 1)) {
|
|
374
|
-
case 42:
|
|
375
|
-
case 47:
|
|
376
|
-
a: {
|
|
377
|
-
for (u = l + 1; u < J; ++u) {
|
|
378
|
-
switch (e.charCodeAt(u)) {
|
|
379
|
-
case 47:
|
|
380
|
-
if (42 === g && 42 === e.charCodeAt(u - 1) && l + 2 !== u) {
|
|
381
|
-
l = u + 1;
|
|
382
|
-
break a;
|
|
383
|
-
}
|
|
384
|
-
|
|
385
|
-
break;
|
|
386
|
-
|
|
387
|
-
case 10:
|
|
388
|
-
if (47 === g) {
|
|
389
|
-
l = u + 1;
|
|
390
|
-
break a;
|
|
391
|
-
}
|
|
392
|
-
|
|
393
|
-
}
|
|
394
|
-
}
|
|
395
|
-
|
|
396
|
-
l = u;
|
|
397
|
-
}
|
|
398
|
-
|
|
399
|
-
}
|
|
400
|
-
|
|
401
|
-
break;
|
|
402
|
-
|
|
403
|
-
case 91:
|
|
404
|
-
g++;
|
|
405
|
-
|
|
406
|
-
case 40:
|
|
407
|
-
g++;
|
|
408
|
-
|
|
409
|
-
case 34:
|
|
410
|
-
case 39:
|
|
411
|
-
for (; l++ < J && e.charCodeAt(l) !== g;) {}
|
|
412
|
-
|
|
413
|
-
}
|
|
414
|
-
|
|
415
|
-
if (0 === k) break;
|
|
416
|
-
l++;
|
|
417
|
-
}
|
|
418
|
-
|
|
419
|
-
k = e.substring(t, l);
|
|
420
|
-
0 === q && (q = (f = f.replace(ca, '').trim()).charCodeAt(0));
|
|
421
|
-
|
|
422
|
-
switch (q) {
|
|
423
|
-
case 64:
|
|
424
|
-
0 < r && (f = f.replace(N, ''));
|
|
425
|
-
g = f.charCodeAt(1);
|
|
426
|
-
|
|
427
|
-
switch (g) {
|
|
428
|
-
case 100:
|
|
429
|
-
case 109:
|
|
430
|
-
case 115:
|
|
431
|
-
case 45:
|
|
432
|
-
r = c;
|
|
433
|
-
break;
|
|
434
|
-
|
|
435
|
-
default:
|
|
436
|
-
r = O;
|
|
437
|
-
}
|
|
438
|
-
|
|
439
|
-
k = M(c, r, k, g, a + 1);
|
|
440
|
-
t = k.length;
|
|
441
|
-
0 < A && (r = X(O, f, I), C = H(3, k, r, c, D, z, t, g, a, h), f = r.join(''), void 0 !== C && 0 === (t = (k = C.trim()).length) && (g = 0, k = ''));
|
|
442
|
-
if (0 < t) switch (g) {
|
|
443
|
-
case 115:
|
|
444
|
-
f = f.replace(da, ea);
|
|
445
|
-
|
|
446
|
-
case 100:
|
|
447
|
-
case 109:
|
|
448
|
-
case 45:
|
|
449
|
-
k = f + '{' + k + '}';
|
|
450
|
-
break;
|
|
451
|
-
|
|
452
|
-
case 107:
|
|
453
|
-
f = f.replace(fa, '$1 $2');
|
|
454
|
-
k = f + '{' + k + '}';
|
|
455
|
-
k = 1 === w || 2 === w && L('@' + k, 3) ? '@-webkit-' + k + '@' + k : '@' + k;
|
|
456
|
-
break;
|
|
457
|
-
|
|
458
|
-
default:
|
|
459
|
-
k = f + k, 112 === h && (k = (p += k, ''));
|
|
460
|
-
} else k = '';
|
|
461
|
-
break;
|
|
462
|
-
|
|
463
|
-
default:
|
|
464
|
-
k = M(c, X(c, f, I), k, h, a + 1);
|
|
465
|
-
}
|
|
466
|
-
|
|
467
|
-
F += k;
|
|
468
|
-
k = I = r = u = q = 0;
|
|
469
|
-
f = '';
|
|
470
|
-
g = e.charCodeAt(++l);
|
|
471
|
-
break;
|
|
472
|
-
|
|
473
|
-
case 125:
|
|
474
|
-
case 59:
|
|
475
|
-
f = (0 < r ? f.replace(N, '') : f).trim();
|
|
476
|
-
if (1 < (t = f.length)) switch (0 === u && (q = f.charCodeAt(0), 45 === q || 96 < q && 123 > q) && (t = (f = f.replace(' ', ':')).length), 0 < A && void 0 !== (C = H(1, f, c, d, D, z, p.length, h, a, h)) && 0 === (t = (f = C.trim()).length) && (f = '\x00\x00'), q = f.charCodeAt(0), g = f.charCodeAt(1), q) {
|
|
477
|
-
case 0:
|
|
478
|
-
break;
|
|
479
|
-
|
|
480
|
-
case 64:
|
|
481
|
-
if (105 === g || 99 === g) {
|
|
482
|
-
G += f + e.charAt(l);
|
|
483
|
-
break;
|
|
484
|
-
}
|
|
485
|
-
|
|
486
|
-
default:
|
|
487
|
-
58 !== f.charCodeAt(t - 1) && (p += P(f, q, g, f.charCodeAt(2)));
|
|
488
|
-
}
|
|
489
|
-
I = r = u = q = 0;
|
|
490
|
-
f = '';
|
|
491
|
-
g = e.charCodeAt(++l);
|
|
492
|
-
}
|
|
493
|
-
}
|
|
494
|
-
|
|
495
|
-
switch (g) {
|
|
496
|
-
case 13:
|
|
497
|
-
case 10:
|
|
498
|
-
47 === b ? b = 0 : 0 === 1 + q && 107 !== h && 0 < f.length && (r = 1, f += '\x00');
|
|
499
|
-
0 < A * Y && H(0, f, c, d, D, z, p.length, h, a, h);
|
|
500
|
-
z = 1;
|
|
501
|
-
D++;
|
|
502
|
-
break;
|
|
503
|
-
|
|
504
|
-
case 59:
|
|
505
|
-
case 125:
|
|
506
|
-
if (0 === b + n + v + m) {
|
|
507
|
-
z++;
|
|
508
|
-
break;
|
|
509
|
-
}
|
|
510
|
-
|
|
511
|
-
default:
|
|
512
|
-
z++;
|
|
513
|
-
y = e.charAt(l);
|
|
514
|
-
|
|
515
|
-
switch (g) {
|
|
516
|
-
case 9:
|
|
517
|
-
case 32:
|
|
518
|
-
if (0 === n + m + b) switch (x) {
|
|
519
|
-
case 44:
|
|
520
|
-
case 58:
|
|
521
|
-
case 9:
|
|
522
|
-
case 32:
|
|
523
|
-
y = '';
|
|
524
|
-
break;
|
|
525
|
-
|
|
526
|
-
default:
|
|
527
|
-
32 !== g && (y = ' ');
|
|
528
|
-
}
|
|
529
|
-
break;
|
|
530
|
-
|
|
531
|
-
case 0:
|
|
532
|
-
y = '\\0';
|
|
533
|
-
break;
|
|
534
|
-
|
|
535
|
-
case 12:
|
|
536
|
-
y = '\\f';
|
|
537
|
-
break;
|
|
538
|
-
|
|
539
|
-
case 11:
|
|
540
|
-
y = '\\v';
|
|
541
|
-
break;
|
|
542
|
-
|
|
543
|
-
case 38:
|
|
544
|
-
0 === n + b + m && (r = I = 1, y = '\f' + y);
|
|
545
|
-
break;
|
|
546
|
-
|
|
547
|
-
case 108:
|
|
548
|
-
if (0 === n + b + m + E && 0 < u) switch (l - u) {
|
|
549
|
-
case 2:
|
|
550
|
-
112 === x && 58 === e.charCodeAt(l - 3) && (E = x);
|
|
551
|
-
|
|
552
|
-
case 8:
|
|
553
|
-
111 === K && (E = K);
|
|
554
|
-
}
|
|
555
|
-
break;
|
|
556
|
-
|
|
557
|
-
case 58:
|
|
558
|
-
0 === n + b + m && (u = l);
|
|
559
|
-
break;
|
|
560
|
-
|
|
561
|
-
case 44:
|
|
562
|
-
0 === b + v + n + m && (r = 1, y += '\r');
|
|
563
|
-
break;
|
|
564
|
-
|
|
565
|
-
case 34:
|
|
566
|
-
case 39:
|
|
567
|
-
0 === b && (n = n === g ? 0 : 0 === n ? g : n);
|
|
568
|
-
break;
|
|
569
|
-
|
|
570
|
-
case 91:
|
|
571
|
-
0 === n + b + v && m++;
|
|
572
|
-
break;
|
|
573
|
-
|
|
574
|
-
case 93:
|
|
575
|
-
0 === n + b + v && m--;
|
|
576
|
-
break;
|
|
577
|
-
|
|
578
|
-
case 41:
|
|
579
|
-
0 === n + b + m && v--;
|
|
580
|
-
break;
|
|
581
|
-
|
|
582
|
-
case 40:
|
|
583
|
-
if (0 === n + b + m) {
|
|
584
|
-
if (0 === q) switch (2 * x + 3 * K) {
|
|
585
|
-
case 533:
|
|
586
|
-
break;
|
|
587
|
-
|
|
588
|
-
default:
|
|
589
|
-
q = 1;
|
|
590
|
-
}
|
|
591
|
-
v++;
|
|
592
|
-
}
|
|
593
|
-
|
|
594
|
-
break;
|
|
595
|
-
|
|
596
|
-
case 64:
|
|
597
|
-
0 === b + v + n + m + u + k && (k = 1);
|
|
598
|
-
break;
|
|
599
|
-
|
|
600
|
-
case 42:
|
|
601
|
-
case 47:
|
|
602
|
-
if (!(0 < n + m + v)) switch (b) {
|
|
603
|
-
case 0:
|
|
604
|
-
switch (2 * g + 3 * e.charCodeAt(l + 1)) {
|
|
605
|
-
case 235:
|
|
606
|
-
b = 47;
|
|
607
|
-
break;
|
|
608
|
-
|
|
609
|
-
case 220:
|
|
610
|
-
t = l, b = 42;
|
|
611
|
-
}
|
|
612
|
-
|
|
613
|
-
break;
|
|
614
|
-
|
|
615
|
-
case 42:
|
|
616
|
-
47 === g && 42 === x && t + 2 !== l && (33 === e.charCodeAt(t + 2) && (p += e.substring(t, l + 1)), y = '', b = 0);
|
|
617
|
-
}
|
|
618
|
-
}
|
|
619
|
-
|
|
620
|
-
0 === b && (f += y);
|
|
621
|
-
}
|
|
622
|
-
|
|
623
|
-
K = x;
|
|
624
|
-
x = g;
|
|
625
|
-
l++;
|
|
626
|
-
}
|
|
627
|
-
|
|
628
|
-
t = p.length;
|
|
629
|
-
|
|
630
|
-
if (0 < t) {
|
|
631
|
-
r = c;
|
|
632
|
-
if (0 < A && (C = H(2, p, r, d, D, z, t, h, a, h), void 0 !== C && 0 === (p = C).length)) return G + p + F;
|
|
633
|
-
p = r.join(',') + '{' + p + '}';
|
|
634
|
-
|
|
635
|
-
if (0 !== w * E) {
|
|
636
|
-
2 !== w || L(p, 2) || (E = 0);
|
|
637
|
-
|
|
638
|
-
switch (E) {
|
|
639
|
-
case 111:
|
|
640
|
-
p = p.replace(ha, ':-moz-$1') + p;
|
|
641
|
-
break;
|
|
642
|
-
|
|
643
|
-
case 112:
|
|
644
|
-
p = p.replace(Q, '::-webkit-input-$1') + p.replace(Q, '::-moz-$1') + p.replace(Q, ':-ms-input-$1') + p;
|
|
645
|
-
}
|
|
646
|
-
|
|
647
|
-
E = 0;
|
|
648
|
-
}
|
|
649
|
-
}
|
|
650
|
-
|
|
651
|
-
return G + p + F;
|
|
652
|
-
}
|
|
653
|
-
|
|
654
|
-
function X(d, c, e) {
|
|
655
|
-
var h = c.trim().split(ia);
|
|
656
|
-
c = h;
|
|
657
|
-
var a = h.length,
|
|
658
|
-
m = d.length;
|
|
659
|
-
|
|
660
|
-
switch (m) {
|
|
661
|
-
case 0:
|
|
662
|
-
case 1:
|
|
663
|
-
var b = 0;
|
|
664
|
-
|
|
665
|
-
for (d = 0 === m ? '' : d[0] + ' '; b < a; ++b) {
|
|
666
|
-
c[b] = Z(d, c[b], e).trim();
|
|
667
|
-
}
|
|
668
|
-
|
|
669
|
-
break;
|
|
670
|
-
|
|
671
|
-
default:
|
|
672
|
-
var v = b = 0;
|
|
673
|
-
|
|
674
|
-
for (c = []; b < a; ++b) {
|
|
675
|
-
for (var n = 0; n < m; ++n) {
|
|
676
|
-
c[v++] = Z(d[n] + ' ', h[b], e).trim();
|
|
677
|
-
}
|
|
678
|
-
}
|
|
679
|
-
|
|
680
|
-
}
|
|
681
|
-
|
|
682
|
-
return c;
|
|
683
|
-
}
|
|
684
|
-
|
|
685
|
-
function Z(d, c, e) {
|
|
686
|
-
var h = c.charCodeAt(0);
|
|
687
|
-
33 > h && (h = (c = c.trim()).charCodeAt(0));
|
|
688
|
-
|
|
689
|
-
switch (h) {
|
|
690
|
-
case 38:
|
|
691
|
-
return c.replace(F, '$1' + d.trim());
|
|
692
|
-
|
|
693
|
-
case 58:
|
|
694
|
-
return d.trim() + c.replace(F, '$1' + d.trim());
|
|
695
|
-
|
|
696
|
-
default:
|
|
697
|
-
if (0 < 1 * e && 0 < c.indexOf('\f')) return c.replace(F, (58 === d.charCodeAt(0) ? '' : '$1') + d.trim());
|
|
698
|
-
}
|
|
699
|
-
|
|
700
|
-
return d + c;
|
|
701
|
-
}
|
|
702
|
-
|
|
703
|
-
function P(d, c, e, h) {
|
|
704
|
-
var a = d + ';',
|
|
705
|
-
m = 2 * c + 3 * e + 4 * h;
|
|
706
|
-
|
|
707
|
-
if (944 === m) {
|
|
708
|
-
d = a.indexOf(':', 9) + 1;
|
|
709
|
-
var b = a.substring(d, a.length - 1).trim();
|
|
710
|
-
b = a.substring(0, d).trim() + b + ';';
|
|
711
|
-
return 1 === w || 2 === w && L(b, 1) ? '-webkit-' + b + b : b;
|
|
712
|
-
}
|
|
713
|
-
|
|
714
|
-
if (0 === w || 2 === w && !L(a, 1)) return a;
|
|
715
|
-
|
|
716
|
-
switch (m) {
|
|
717
|
-
case 1015:
|
|
718
|
-
return 97 === a.charCodeAt(10) ? '-webkit-' + a + a : a;
|
|
719
|
-
|
|
720
|
-
case 951:
|
|
721
|
-
return 116 === a.charCodeAt(3) ? '-webkit-' + a + a : a;
|
|
722
|
-
|
|
723
|
-
case 963:
|
|
724
|
-
return 110 === a.charCodeAt(5) ? '-webkit-' + a + a : a;
|
|
725
|
-
|
|
726
|
-
case 1009:
|
|
727
|
-
if (100 !== a.charCodeAt(4)) break;
|
|
728
|
-
|
|
729
|
-
case 969:
|
|
730
|
-
case 942:
|
|
731
|
-
return '-webkit-' + a + a;
|
|
732
|
-
|
|
733
|
-
case 978:
|
|
734
|
-
return '-webkit-' + a + '-moz-' + a + a;
|
|
735
|
-
|
|
736
|
-
case 1019:
|
|
737
|
-
case 983:
|
|
738
|
-
return '-webkit-' + a + '-moz-' + a + '-ms-' + a + a;
|
|
739
|
-
|
|
740
|
-
case 883:
|
|
741
|
-
if (45 === a.charCodeAt(8)) return '-webkit-' + a + a;
|
|
742
|
-
if (0 < a.indexOf('image-set(', 11)) return a.replace(ja, '$1-webkit-$2') + a;
|
|
743
|
-
break;
|
|
744
|
-
|
|
745
|
-
case 932:
|
|
746
|
-
if (45 === a.charCodeAt(4)) switch (a.charCodeAt(5)) {
|
|
747
|
-
case 103:
|
|
748
|
-
return '-webkit-box-' + a.replace('-grow', '') + '-webkit-' + a + '-ms-' + a.replace('grow', 'positive') + a;
|
|
749
|
-
|
|
750
|
-
case 115:
|
|
751
|
-
return '-webkit-' + a + '-ms-' + a.replace('shrink', 'negative') + a;
|
|
752
|
-
|
|
753
|
-
case 98:
|
|
754
|
-
return '-webkit-' + a + '-ms-' + a.replace('basis', 'preferred-size') + a;
|
|
755
|
-
}
|
|
756
|
-
return '-webkit-' + a + '-ms-' + a + a;
|
|
757
|
-
|
|
758
|
-
case 964:
|
|
759
|
-
return '-webkit-' + a + '-ms-flex-' + a + a;
|
|
760
|
-
|
|
761
|
-
case 1023:
|
|
762
|
-
if (99 !== a.charCodeAt(8)) break;
|
|
763
|
-
b = a.substring(a.indexOf(':', 15)).replace('flex-', '').replace('space-between', 'justify');
|
|
764
|
-
return '-webkit-box-pack' + b + '-webkit-' + a + '-ms-flex-pack' + b + a;
|
|
765
|
-
|
|
766
|
-
case 1005:
|
|
767
|
-
return ka.test(a) ? a.replace(aa, ':-webkit-') + a.replace(aa, ':-moz-') + a : a;
|
|
768
|
-
|
|
769
|
-
case 1e3:
|
|
770
|
-
b = a.substring(13).trim();
|
|
771
|
-
c = b.indexOf('-') + 1;
|
|
772
|
-
|
|
773
|
-
switch (b.charCodeAt(0) + b.charCodeAt(c)) {
|
|
774
|
-
case 226:
|
|
775
|
-
b = a.replace(G, 'tb');
|
|
776
|
-
break;
|
|
777
|
-
|
|
778
|
-
case 232:
|
|
779
|
-
b = a.replace(G, 'tb-rl');
|
|
780
|
-
break;
|
|
781
|
-
|
|
782
|
-
case 220:
|
|
783
|
-
b = a.replace(G, 'lr');
|
|
784
|
-
break;
|
|
785
|
-
|
|
786
|
-
default:
|
|
787
|
-
return a;
|
|
788
|
-
}
|
|
789
|
-
|
|
790
|
-
return '-webkit-' + a + '-ms-' + b + a;
|
|
791
|
-
|
|
792
|
-
case 1017:
|
|
793
|
-
if (-1 === a.indexOf('sticky', 9)) break;
|
|
794
|
-
|
|
795
|
-
case 975:
|
|
796
|
-
c = (a = d).length - 10;
|
|
797
|
-
b = (33 === a.charCodeAt(c) ? a.substring(0, c) : a).substring(d.indexOf(':', 7) + 1).trim();
|
|
798
|
-
|
|
799
|
-
switch (m = b.charCodeAt(0) + (b.charCodeAt(7) | 0)) {
|
|
800
|
-
case 203:
|
|
801
|
-
if (111 > b.charCodeAt(8)) break;
|
|
802
|
-
|
|
803
|
-
case 115:
|
|
804
|
-
a = a.replace(b, '-webkit-' + b) + ';' + a;
|
|
805
|
-
break;
|
|
806
|
-
|
|
807
|
-
case 207:
|
|
808
|
-
case 102:
|
|
809
|
-
a = a.replace(b, '-webkit-' + (102 < m ? 'inline-' : '') + 'box') + ';' + a.replace(b, '-webkit-' + b) + ';' + a.replace(b, '-ms-' + b + 'box') + ';' + a;
|
|
810
|
-
}
|
|
811
|
-
|
|
812
|
-
return a + ';';
|
|
813
|
-
|
|
814
|
-
case 938:
|
|
815
|
-
if (45 === a.charCodeAt(5)) switch (a.charCodeAt(6)) {
|
|
816
|
-
case 105:
|
|
817
|
-
return b = a.replace('-items', ''), '-webkit-' + a + '-webkit-box-' + b + '-ms-flex-' + b + a;
|
|
818
|
-
|
|
819
|
-
case 115:
|
|
820
|
-
return '-webkit-' + a + '-ms-flex-item-' + a.replace(ba, '') + a;
|
|
821
|
-
|
|
822
|
-
default:
|
|
823
|
-
return '-webkit-' + a + '-ms-flex-line-pack' + a.replace('align-content', '').replace(ba, '') + a;
|
|
824
|
-
}
|
|
825
|
-
break;
|
|
826
|
-
|
|
827
|
-
case 973:
|
|
828
|
-
case 989:
|
|
829
|
-
if (45 !== a.charCodeAt(3) || 122 === a.charCodeAt(4)) break;
|
|
830
|
-
|
|
831
|
-
case 931:
|
|
832
|
-
case 953:
|
|
833
|
-
if (!0 === la.test(d)) return 115 === (b = d.substring(d.indexOf(':') + 1)).charCodeAt(0) ? P(d.replace('stretch', 'fill-available'), c, e, h).replace(':fill-available', ':stretch') : a.replace(b, '-webkit-' + b) + a.replace(b, '-moz-' + b.replace('fill-', '')) + a;
|
|
834
|
-
break;
|
|
835
|
-
|
|
836
|
-
case 962:
|
|
837
|
-
if (a = '-webkit-' + a + (102 === a.charCodeAt(5) ? '-ms-' + a : '') + a, 211 === e + h && 105 === a.charCodeAt(13) && 0 < a.indexOf('transform', 10)) return a.substring(0, a.indexOf(';', 27) + 1).replace(ma, '$1-webkit-$2') + a;
|
|
838
|
-
}
|
|
839
|
-
|
|
840
|
-
return a;
|
|
841
|
-
}
|
|
842
|
-
|
|
843
|
-
function L(d, c) {
|
|
844
|
-
var e = d.indexOf(1 === c ? ':' : '{'),
|
|
845
|
-
h = d.substring(0, 3 !== c ? e : 10);
|
|
846
|
-
e = d.substring(e + 1, d.length - 1);
|
|
847
|
-
return R(2 !== c ? h : h.replace(na, '$1'), e, c);
|
|
848
|
-
}
|
|
849
|
-
|
|
850
|
-
function ea(d, c) {
|
|
851
|
-
var e = P(c, c.charCodeAt(0), c.charCodeAt(1), c.charCodeAt(2));
|
|
852
|
-
return e !== c + ';' ? e.replace(oa, ' or ($1)').substring(4) : '(' + c + ')';
|
|
853
|
-
}
|
|
854
|
-
|
|
855
|
-
function H(d, c, e, h, a, m, b, v, n, q) {
|
|
856
|
-
for (var g = 0, x = c, w; g < A; ++g) {
|
|
857
|
-
switch (w = S[g].call(B, d, x, e, h, a, m, b, v, n, q)) {
|
|
858
|
-
case void 0:
|
|
859
|
-
case !1:
|
|
860
|
-
case !0:
|
|
861
|
-
case null:
|
|
862
|
-
break;
|
|
863
|
-
|
|
864
|
-
default:
|
|
865
|
-
x = w;
|
|
866
|
-
}
|
|
867
|
-
}
|
|
868
|
-
|
|
869
|
-
if (x !== c) return x;
|
|
870
|
-
}
|
|
871
|
-
|
|
872
|
-
function T(d) {
|
|
873
|
-
switch (d) {
|
|
874
|
-
case void 0:
|
|
875
|
-
case null:
|
|
876
|
-
A = S.length = 0;
|
|
877
|
-
break;
|
|
878
|
-
|
|
879
|
-
default:
|
|
880
|
-
if ('function' === typeof d) S[A++] = d;else if ('object' === _typeof(d)) for (var c = 0, e = d.length; c < e; ++c) {
|
|
881
|
-
T(d[c]);
|
|
882
|
-
} else Y = !!d | 0;
|
|
883
|
-
}
|
|
884
|
-
|
|
885
|
-
return T;
|
|
886
|
-
}
|
|
887
|
-
|
|
888
|
-
function U(d) {
|
|
889
|
-
d = d.prefix;
|
|
890
|
-
void 0 !== d && (R = null, d ? 'function' !== typeof d ? w = 1 : (w = 2, R = d) : w = 0);
|
|
891
|
-
return U;
|
|
892
|
-
}
|
|
893
|
-
|
|
894
|
-
function B(d, c) {
|
|
895
|
-
var e = d;
|
|
896
|
-
33 > e.charCodeAt(0) && (e = e.trim());
|
|
897
|
-
V = e;
|
|
898
|
-
e = [V];
|
|
899
|
-
|
|
900
|
-
if (0 < A) {
|
|
901
|
-
var h = H(-1, c, e, e, D, z, 0, 0, 0, 0);
|
|
902
|
-
void 0 !== h && 'string' === typeof h && (c = h);
|
|
903
|
-
}
|
|
904
|
-
|
|
905
|
-
var a = M(O, e, c, 0, 0);
|
|
906
|
-
0 < A && (h = H(-2, a, e, e, D, z, a.length, 0, 0, 0), void 0 !== h && (a = h));
|
|
907
|
-
V = '';
|
|
908
|
-
E = 0;
|
|
909
|
-
z = D = 1;
|
|
910
|
-
return a;
|
|
911
|
-
}
|
|
912
|
-
|
|
913
|
-
var ca = /^\0+/g,
|
|
914
|
-
N = /[\0\r\f]/g,
|
|
915
|
-
aa = /: */g,
|
|
916
|
-
ka = /zoo|gra/,
|
|
917
|
-
ma = /([,: ])(transform)/g,
|
|
918
|
-
ia = /,\r+?/g,
|
|
919
|
-
F = /([\t\r\n ])*\f?&/g,
|
|
920
|
-
fa = /@(k\w+)\s*(\S*)\s*/,
|
|
921
|
-
Q = /::(place)/g,
|
|
922
|
-
ha = /:(read-only)/g,
|
|
923
|
-
G = /[svh]\w+-[tblr]{2}/,
|
|
924
|
-
da = /\(\s*(.*)\s*\)/g,
|
|
925
|
-
oa = /([\s\S]*?);/g,
|
|
926
|
-
ba = /-self|flex-/g,
|
|
927
|
-
na = /[^]*?(:[rp][el]a[\w-]+)[^]*/,
|
|
928
|
-
la = /stretch|:\s*\w+\-(?:conte|avail)/,
|
|
929
|
-
ja = /([^-])(image-set\()/,
|
|
930
|
-
z = 1,
|
|
931
|
-
D = 1,
|
|
932
|
-
E = 0,
|
|
933
|
-
w = 1,
|
|
934
|
-
O = [],
|
|
935
|
-
S = [],
|
|
936
|
-
A = 0,
|
|
937
|
-
R = null,
|
|
938
|
-
Y = 0,
|
|
939
|
-
V = '';
|
|
940
|
-
B.use = T;
|
|
941
|
-
B.set = U;
|
|
942
|
-
void 0 !== W && U(W);
|
|
943
|
-
return B;
|
|
944
|
-
}
|
|
945
|
-
|
|
946
|
-
var stylisInstance;
|
|
947
|
-
/**
|
|
948
|
-
* Transpiles CSS Modules content to CSS rules.
|
|
949
|
-
*/
|
|
950
|
-
|
|
951
|
-
var transpile = function transpile(selector, content) {
|
|
952
|
-
if (!stylisInstance) {
|
|
953
|
-
stylisInstance = new stylis_min();
|
|
954
|
-
}
|
|
955
|
-
|
|
956
|
-
return stylisInstance(selector, content);
|
|
957
|
-
};
|
|
958
|
-
|
|
959
|
-
export { attachRules, createSelector, css, keyframes, referenceRules, transpile };
|
|
960
|
-
//# sourceMappingURL=index.mjs.map
|