@polymarket-developers/clob-client 1.0.7

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.
Files changed (48) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/LICENSE +21 -0
  3. package/README.md +78 -0
  4. package/cache/LICENSE +21 -0
  5. package/cache/README.md +62 -0
  6. package/cache/dist/declarations/src/index.d.ts +2 -0
  7. package/cache/dist/declarations/types/index.d.ts +45 -0
  8. package/cache/dist/emotion-cache.browser.cjs.default.js +1 -0
  9. package/cache/dist/emotion-cache.browser.cjs.js +471 -0
  10. package/cache/dist/emotion-cache.browser.cjs.mjs +2 -0
  11. package/cache/dist/emotion-cache.browser.development.cjs.default.js +1 -0
  12. package/cache/dist/emotion-cache.browser.development.cjs.js +616 -0
  13. package/cache/dist/emotion-cache.browser.development.cjs.mjs +2 -0
  14. package/cache/dist/emotion-cache.browser.development.esm.js +612 -0
  15. package/cache/dist/emotion-cache.browser.esm.js +467 -0
  16. package/cache/dist/emotion-cache.cjs.d.mts +3 -0
  17. package/cache/dist/emotion-cache.cjs.d.ts +3 -0
  18. package/cache/dist/emotion-cache.cjs.default.d.ts +1 -0
  19. package/cache/dist/emotion-cache.cjs.default.js +1 -0
  20. package/cache/dist/emotion-cache.cjs.js +565 -0
  21. package/cache/dist/emotion-cache.cjs.mjs +2 -0
  22. package/cache/dist/emotion-cache.development.cjs.default.js +1 -0
  23. package/cache/dist/emotion-cache.development.cjs.js +714 -0
  24. package/cache/dist/emotion-cache.development.cjs.mjs +2 -0
  25. package/cache/dist/emotion-cache.development.edge-light.cjs.default.js +1 -0
  26. package/cache/dist/emotion-cache.development.edge-light.cjs.js +621 -0
  27. package/cache/dist/emotion-cache.development.edge-light.cjs.mjs +2 -0
  28. package/cache/dist/emotion-cache.development.edge-light.esm.js +612 -0
  29. package/cache/dist/emotion-cache.development.esm.js +705 -0
  30. package/cache/dist/emotion-cache.edge-light.cjs.default.js +1 -0
  31. package/cache/dist/emotion-cache.edge-light.cjs.js +490 -0
  32. package/cache/dist/emotion-cache.edge-light.cjs.mjs +2 -0
  33. package/cache/dist/emotion-cache.edge-light.esm.js +481 -0
  34. package/cache/dist/emotion-cache.esm.js +556 -0
  35. package/cache/package.json +100 -0
  36. package/cache/src/conditions/false.js +1 -0
  37. package/cache/src/conditions/is-browser.js +1 -0
  38. package/cache/src/conditions/true.js +1 -0
  39. package/cache/src/index.d.ts +2 -0
  40. package/cache/src/index.js +257 -0
  41. package/cache/src/prefixer.js +340 -0
  42. package/cache/src/stylis-plugins.js +269 -0
  43. package/cache/src/types.js +26 -0
  44. package/cache/types/index.d.ts +45 -0
  45. package/index.d.ts +63 -0
  46. package/index.js +204 -0
  47. package/package.json +27 -0
  48. package/utils.js +15 -0
@@ -0,0 +1,616 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var sheet = require('@emotion/sheet');
6
+ var stylis = require('stylis');
7
+ require('@emotion/weak-memoize');
8
+ require('@emotion/memoize');
9
+
10
+ var identifierWithPointTracking = function identifierWithPointTracking(begin, points, index) {
11
+ var previous = 0;
12
+ var character = 0;
13
+
14
+ while (true) {
15
+ previous = character;
16
+ character = stylis.peek(); // &\f
17
+
18
+ if (previous === 38 && character === 12) {
19
+ points[index] = 1;
20
+ }
21
+
22
+ if (stylis.token(character)) {
23
+ break;
24
+ }
25
+
26
+ stylis.next();
27
+ }
28
+
29
+ return stylis.slice(begin, stylis.position);
30
+ };
31
+
32
+ var toRules = function toRules(parsed, points) {
33
+ // pretend we've started with a comma
34
+ var index = -1;
35
+ var character = 44;
36
+
37
+ do {
38
+ switch (stylis.token(character)) {
39
+ case 0:
40
+ // &\f
41
+ if (character === 38 && stylis.peek() === 12) {
42
+ // this is not 100% correct, we don't account for literal sequences here - like for example quoted strings
43
+ // stylis inserts \f after & to know when & where it should replace this sequence with the context selector
44
+ // and when it should just concatenate the outer and inner selectors
45
+ // it's very unlikely for this sequence to actually appear in a different context, so we just leverage this fact here
46
+ points[index] = 1;
47
+ }
48
+
49
+ parsed[index] += identifierWithPointTracking(stylis.position - 1, points, index);
50
+ break;
51
+
52
+ case 2:
53
+ parsed[index] += stylis.delimit(character);
54
+ break;
55
+
56
+ case 4:
57
+ // comma
58
+ if (character === 44) {
59
+ // colon
60
+ parsed[++index] = stylis.peek() === 58 ? '&\f' : '';
61
+ points[index] = parsed[index].length;
62
+ break;
63
+ }
64
+
65
+ // fallthrough
66
+
67
+ default:
68
+ parsed[index] += stylis.from(character);
69
+ }
70
+ } while (character = stylis.next());
71
+
72
+ return parsed;
73
+ };
74
+
75
+ var getRules = function getRules(value, points) {
76
+ return stylis.dealloc(toRules(stylis.alloc(value), points));
77
+ }; // WeakSet would be more appropriate, but only WeakMap is supported in IE11
78
+
79
+
80
+ var fixedElements = /* #__PURE__ */new WeakMap();
81
+ var compat = function compat(element) {
82
+ if (element.type !== 'rule' || !element.parent || // positive .length indicates that this rule contains pseudo
83
+ // negative .length indicates that this rule has been already prefixed
84
+ element.length < 1) {
85
+ return;
86
+ }
87
+
88
+ var value = element.value,
89
+ parent = element.parent;
90
+ var isImplicitRule = element.column === parent.column && element.line === parent.line;
91
+
92
+ while (parent.type !== 'rule') {
93
+ parent = parent.parent;
94
+ if (!parent) return;
95
+ } // short-circuit for the simplest case
96
+
97
+
98
+ if (element.props.length === 1 && value.charCodeAt(0) !== 58
99
+ /* colon */
100
+ && !fixedElements.get(parent)) {
101
+ return;
102
+ } // if this is an implicitly inserted rule (the one eagerly inserted at the each new nested level)
103
+ // then the props has already been manipulated beforehand as they that array is shared between it and its "rule parent"
104
+
105
+
106
+ if (isImplicitRule) {
107
+ return;
108
+ }
109
+
110
+ fixedElements.set(element, true);
111
+ var points = [];
112
+ var rules = getRules(value, points);
113
+ var parentRules = parent.props;
114
+
115
+ for (var i = 0, k = 0; i < rules.length; i++) {
116
+ for (var j = 0; j < parentRules.length; j++, k++) {
117
+ element.props[k] = points[i] ? rules[i].replace(/&\f/g, parentRules[j]) : parentRules[j] + " " + rules[i];
118
+ }
119
+ }
120
+ };
121
+ var removeLabel = function removeLabel(element) {
122
+ if (element.type === 'decl') {
123
+ var value = element.value;
124
+
125
+ if ( // charcode for l
126
+ value.charCodeAt(0) === 108 && // charcode for b
127
+ value.charCodeAt(2) === 98) {
128
+ // this ignores label
129
+ element["return"] = '';
130
+ element.value = '';
131
+ }
132
+ }
133
+ };
134
+ var ignoreFlag = 'emotion-disable-server-rendering-unsafe-selector-warning-please-do-not-use-this-the-warning-exists-for-a-reason';
135
+
136
+ var isIgnoringComment = function isIgnoringComment(element) {
137
+ return element.type === 'comm' && element.children.indexOf(ignoreFlag) > -1;
138
+ };
139
+
140
+ var createUnsafeSelectorsAlarm = function createUnsafeSelectorsAlarm(cache) {
141
+ return function (element, index, children) {
142
+ if (element.type !== 'rule' || cache.compat) return;
143
+ var unsafePseudoClasses = element.value.match(/(:first|:nth|:nth-last)-child/g);
144
+
145
+ if (unsafePseudoClasses) {
146
+ var isNested = !!element.parent; // in nested rules comments become children of the "auto-inserted" rule and that's always the `element.parent`
147
+ //
148
+ // considering this input:
149
+ // .a {
150
+ // .b /* comm */ {}
151
+ // color: hotpink;
152
+ // }
153
+ // we get output corresponding to this:
154
+ // .a {
155
+ // & {
156
+ // /* comm */
157
+ // color: hotpink;
158
+ // }
159
+ // .b {}
160
+ // }
161
+
162
+ var commentContainer = isNested ? element.parent.children : // global rule at the root level
163
+ children;
164
+
165
+ for (var i = commentContainer.length - 1; i >= 0; i--) {
166
+ var node = commentContainer[i];
167
+
168
+ if (node.line < element.line) {
169
+ break;
170
+ } // it is quite weird but comments are *usually* put at `column: element.column - 1`
171
+ // so we seek *from the end* for the node that is earlier than the rule's `element` and check that
172
+ // this will also match inputs like this:
173
+ // .a {
174
+ // /* comm */
175
+ // .b {}
176
+ // }
177
+ //
178
+ // but that is fine
179
+ //
180
+ // it would be the easiest to change the placement of the comment to be the first child of the rule:
181
+ // .a {
182
+ // .b { /* comm */ }
183
+ // }
184
+ // with such inputs we wouldn't have to search for the comment at all
185
+ // TODO: consider changing this comment placement in the next major version
186
+
187
+
188
+ if (node.column < element.column) {
189
+ if (isIgnoringComment(node)) {
190
+ return;
191
+ }
192
+
193
+ break;
194
+ }
195
+ }
196
+
197
+ unsafePseudoClasses.forEach(function (unsafePseudoClass) {
198
+ console.error("The pseudo class \"" + unsafePseudoClass + "\" is potentially unsafe when doing server-side rendering. Try changing it to \"" + unsafePseudoClass.split('-child')[0] + "-of-type\".");
199
+ });
200
+ }
201
+ };
202
+ };
203
+
204
+ var isImportRule = function isImportRule(element) {
205
+ return element.type.charCodeAt(1) === 105 && element.type.charCodeAt(0) === 64;
206
+ };
207
+
208
+ var isPrependedWithRegularRules = function isPrependedWithRegularRules(index, children) {
209
+ for (var i = index - 1; i >= 0; i--) {
210
+ if (!isImportRule(children[i])) {
211
+ return true;
212
+ }
213
+ }
214
+
215
+ return false;
216
+ }; // use this to remove incorrect elements from further processing
217
+ // so they don't get handed to the `sheet` (or anything else)
218
+ // as that could potentially lead to additional logs which in turn could be overhelming to the user
219
+
220
+
221
+ var nullifyElement = function nullifyElement(element) {
222
+ element.type = '';
223
+ element.value = '';
224
+ element["return"] = '';
225
+ element.children = '';
226
+ element.props = '';
227
+ };
228
+
229
+ var incorrectImportAlarm = function incorrectImportAlarm(element, index, children) {
230
+ if (!isImportRule(element)) {
231
+ return;
232
+ }
233
+
234
+ if (element.parent) {
235
+ console.error("`@import` rules can't be nested inside other rules. Please move it to the top level and put it before regular rules. Keep in mind that they can only be used within global styles.");
236
+ nullifyElement(element);
237
+ } else if (isPrependedWithRegularRules(index, children)) {
238
+ console.error("`@import` rules can't be after other rules. Please put your `@import` rules before your other rules.");
239
+ nullifyElement(element);
240
+ }
241
+ };
242
+
243
+ /* eslint-disable no-fallthrough */
244
+
245
+ function prefix(value, length) {
246
+ switch (stylis.hash(value, length)) {
247
+ // color-adjust
248
+ case 5103:
249
+ return stylis.WEBKIT + 'print-' + value + value;
250
+ // animation, animation-(delay|direction|duration|fill-mode|iteration-count|name|play-state|timing-function)
251
+
252
+ case 5737:
253
+ case 4201:
254
+ case 3177:
255
+ case 3433:
256
+ case 1641:
257
+ case 4457:
258
+ case 2921: // text-decoration, filter, clip-path, backface-visibility, column, box-decoration-break
259
+
260
+ case 5572:
261
+ case 6356:
262
+ case 5844:
263
+ case 3191:
264
+ case 6645:
265
+ case 3005: // mask, mask-image, mask-(mode|clip|size), mask-(repeat|origin), mask-position, mask-composite,
266
+
267
+ case 6391:
268
+ case 5879:
269
+ case 5623:
270
+ case 6135:
271
+ case 4599:
272
+ case 4855: // background-clip, columns, column-(count|fill|gap|rule|rule-color|rule-style|rule-width|span|width)
273
+
274
+ case 4215:
275
+ case 6389:
276
+ case 5109:
277
+ case 5365:
278
+ case 5621:
279
+ case 3829:
280
+ return stylis.WEBKIT + value + value;
281
+ // appearance, user-select, transform, hyphens, text-size-adjust
282
+
283
+ case 5349:
284
+ case 4246:
285
+ case 4810:
286
+ case 6968:
287
+ case 2756:
288
+ return stylis.WEBKIT + value + stylis.MOZ + value + stylis.MS + value + value;
289
+ // flex, flex-direction
290
+
291
+ case 6828:
292
+ case 4268:
293
+ return stylis.WEBKIT + value + stylis.MS + value + value;
294
+ // order
295
+
296
+ case 6165:
297
+ return stylis.WEBKIT + value + stylis.MS + 'flex-' + value + value;
298
+ // align-items
299
+
300
+ case 5187:
301
+ return stylis.WEBKIT + value + stylis.replace(value, /(\w+).+(:[^]+)/, stylis.WEBKIT + 'box-$1$2' + stylis.MS + 'flex-$1$2') + value;
302
+ // align-self
303
+
304
+ case 5443:
305
+ return stylis.WEBKIT + value + stylis.MS + 'flex-item-' + stylis.replace(value, /flex-|-self/, '') + value;
306
+ // align-content
307
+
308
+ case 4675:
309
+ return stylis.WEBKIT + value + stylis.MS + 'flex-line-pack' + stylis.replace(value, /align-content|flex-|-self/, '') + value;
310
+ // flex-shrink
311
+
312
+ case 5548:
313
+ return stylis.WEBKIT + value + stylis.MS + stylis.replace(value, 'shrink', 'negative') + value;
314
+ // flex-basis
315
+
316
+ case 5292:
317
+ return stylis.WEBKIT + value + stylis.MS + stylis.replace(value, 'basis', 'preferred-size') + value;
318
+ // flex-grow
319
+
320
+ case 6060:
321
+ return stylis.WEBKIT + 'box-' + stylis.replace(value, '-grow', '') + stylis.WEBKIT + value + stylis.MS + stylis.replace(value, 'grow', 'positive') + value;
322
+ // transition
323
+
324
+ case 4554:
325
+ return stylis.WEBKIT + stylis.replace(value, /([^-])(transform)/g, '$1' + stylis.WEBKIT + '$2') + value;
326
+ // cursor
327
+
328
+ case 6187:
329
+ return stylis.replace(stylis.replace(stylis.replace(value, /(zoom-|grab)/, stylis.WEBKIT + '$1'), /(image-set)/, stylis.WEBKIT + '$1'), value, '') + value;
330
+ // background, background-image
331
+
332
+ case 5495:
333
+ case 3959:
334
+ return stylis.replace(value, /(image-set\([^]*)/, stylis.WEBKIT + '$1' + '$`$1');
335
+ // justify-content
336
+
337
+ case 4968:
338
+ return stylis.replace(stylis.replace(value, /(.+:)(flex-)?(.*)/, stylis.WEBKIT + 'box-pack:$3' + stylis.MS + 'flex-pack:$3'), /s.+-b[^;]+/, 'justify') + stylis.WEBKIT + value + value;
339
+ // (margin|padding)-inline-(start|end)
340
+
341
+ case 4095:
342
+ case 3583:
343
+ case 4068:
344
+ case 2532:
345
+ return stylis.replace(value, /(.+)-inline(.+)/, stylis.WEBKIT + '$1$2') + value;
346
+ // (min|max)?(width|height|inline-size|block-size)
347
+
348
+ case 8116:
349
+ case 7059:
350
+ case 5753:
351
+ case 5535:
352
+ case 5445:
353
+ case 5701:
354
+ case 4933:
355
+ case 4677:
356
+ case 5533:
357
+ case 5789:
358
+ case 5021:
359
+ case 4765:
360
+ // stretch, max-content, min-content, fill-available
361
+ if (stylis.strlen(value) - 1 - length > 6) switch (stylis.charat(value, length + 1)) {
362
+ // (m)ax-content, (m)in-content
363
+ case 109:
364
+ // -
365
+ if (stylis.charat(value, length + 4) !== 45) break;
366
+ // (f)ill-available, (f)it-content
367
+
368
+ case 102:
369
+ return stylis.replace(value, /(.+:)(.+)-([^]+)/, '$1' + stylis.WEBKIT + '$2-$3' + '$1' + stylis.MOZ + (stylis.charat(value, length + 3) == 108 ? '$3' : '$2-$3')) + value;
370
+ // (s)tretch
371
+
372
+ case 115:
373
+ return ~stylis.indexof(value, 'stretch') ? prefix(stylis.replace(value, 'stretch', 'fill-available'), length) + value : value;
374
+ }
375
+ break;
376
+ // position: sticky
377
+
378
+ case 4949:
379
+ // (s)ticky?
380
+ if (stylis.charat(value, length + 1) !== 115) break;
381
+ // display: (flex|inline-flex)
382
+
383
+ case 6444:
384
+ switch (stylis.charat(value, stylis.strlen(value) - 3 - (~stylis.indexof(value, '!important') && 10))) {
385
+ // stic(k)y
386
+ case 107:
387
+ return stylis.replace(value, ':', ':' + stylis.WEBKIT) + value;
388
+ // (inline-)?fl(e)x
389
+
390
+ case 101:
391
+ return stylis.replace(value, /(.+:)([^;!]+)(;|!.+)?/, '$1' + stylis.WEBKIT + (stylis.charat(value, 14) === 45 ? 'inline-' : '') + 'box$3' + '$1' + stylis.WEBKIT + '$2$3' + '$1' + stylis.MS + '$2box$3') + value;
392
+ }
393
+
394
+ break;
395
+ // writing-mode
396
+
397
+ case 5936:
398
+ switch (stylis.charat(value, length + 11)) {
399
+ // vertical-l(r)
400
+ case 114:
401
+ return stylis.WEBKIT + value + stylis.MS + stylis.replace(value, /[svh]\w+-[tblr]{2}/, 'tb') + value;
402
+ // vertical-r(l)
403
+
404
+ case 108:
405
+ return stylis.WEBKIT + value + stylis.MS + stylis.replace(value, /[svh]\w+-[tblr]{2}/, 'tb-rl') + value;
406
+ // horizontal(-)tb
407
+
408
+ case 45:
409
+ return stylis.WEBKIT + value + stylis.MS + stylis.replace(value, /[svh]\w+-[tblr]{2}/, 'lr') + value;
410
+ }
411
+
412
+ return stylis.WEBKIT + value + stylis.MS + value + value;
413
+ }
414
+
415
+ return value;
416
+ }
417
+
418
+ var prefixer = function prefixer(element, index, children, callback) {
419
+ if (element.length > -1) if (!element["return"]) switch (element.type) {
420
+ case stylis.DECLARATION:
421
+ element["return"] = prefix(element.value, element.length);
422
+ break;
423
+
424
+ case stylis.KEYFRAMES:
425
+ return stylis.serialize([stylis.copy(element, {
426
+ value: stylis.replace(element.value, '@', '@' + stylis.WEBKIT)
427
+ })], callback);
428
+
429
+ case stylis.RULESET:
430
+ if (element.length) return stylis.combine(element.props, function (value) {
431
+ switch (stylis.match(value, /(::plac\w+|:read-\w+)/)) {
432
+ // :read-(only|write)
433
+ case ':read-only':
434
+ case ':read-write':
435
+ return stylis.serialize([stylis.copy(element, {
436
+ props: [stylis.replace(value, /:(read-\w+)/, ':' + stylis.MOZ + '$1')]
437
+ })], callback);
438
+ // :placeholder
439
+
440
+ case '::placeholder':
441
+ return stylis.serialize([stylis.copy(element, {
442
+ props: [stylis.replace(value, /:(plac\w+)/, ':' + stylis.WEBKIT + 'input-$1')]
443
+ }), stylis.copy(element, {
444
+ props: [stylis.replace(value, /:(plac\w+)/, ':' + stylis.MOZ + '$1')]
445
+ }), stylis.copy(element, {
446
+ props: [stylis.replace(value, /:(plac\w+)/, stylis.MS + 'input-$1')]
447
+ })], callback);
448
+ }
449
+
450
+ return '';
451
+ });
452
+ }
453
+ };
454
+
455
+ var defaultStylisPlugins = [prefixer];
456
+
457
+ var createCache = function
458
+ /*: EmotionCache */
459
+ createCache(options
460
+ /*: Options */
461
+ ) {
462
+ var key = options.key;
463
+
464
+ if (!key) {
465
+ throw new Error("You have to configure `key` for your cache. Please make sure it's unique (and not equal to 'css') as it's used for linking styles to your cache.\n" + "If multiple caches share the same key they might \"fight\" for each other's style elements.");
466
+ }
467
+
468
+ if (key === 'css') {
469
+ var ssrStyles = document.querySelectorAll("style[data-emotion]:not([data-s])"); // get SSRed styles out of the way of React's hydration
470
+ // document.head is a safe place to move them to(though note document.head is not necessarily the last place they will be)
471
+ // note this very very intentionally targets all style elements regardless of the key to ensure
472
+ // that creating a cache works inside of render of a React component
473
+
474
+ Array.prototype.forEach.call(ssrStyles, function (node
475
+ /*: HTMLStyleElement */
476
+ ) {
477
+ // we want to only move elements which have a space in the data-emotion attribute value
478
+ // because that indicates that it is an Emotion 11 server-side rendered style elements
479
+ // while we will already ignore Emotion 11 client-side inserted styles because of the :not([data-s]) part in the selector
480
+ // Emotion 10 client-side inserted styles did not have data-s (but importantly did not have a space in their data-emotion attributes)
481
+ // so checking for the space ensures that loading Emotion 11 after Emotion 10 has inserted some styles
482
+ // will not result in the Emotion 10 styles being destroyed
483
+ var dataEmotionAttribute = node.getAttribute('data-emotion');
484
+
485
+ if (dataEmotionAttribute.indexOf(' ') === -1) {
486
+ return;
487
+ }
488
+
489
+ document.head.appendChild(node);
490
+ node.setAttribute('data-s', '');
491
+ });
492
+ }
493
+
494
+ var stylisPlugins = options.stylisPlugins || defaultStylisPlugins;
495
+
496
+ {
497
+ if (/[^a-z-]/.test(key)) {
498
+ throw new Error("Emotion key must only contain lower case alphabetical characters and - but \"" + key + "\" was passed");
499
+ }
500
+ }
501
+
502
+ var inserted = {};
503
+ var container;
504
+ /* : Node */
505
+
506
+ var nodesToHydrate = [];
507
+
508
+ {
509
+ container = options.container || document.head;
510
+ Array.prototype.forEach.call( // this means we will ignore elements which don't have a space in them which
511
+ // means that the style elements we're looking at are only Emotion 11 server-rendered style elements
512
+ document.querySelectorAll("style[data-emotion^=\"" + key + " \"]"), function (node
513
+ /*: HTMLStyleElement */
514
+ ) {
515
+ var attrib = node.getAttribute("data-emotion").split(' ');
516
+
517
+ for (var i = 1; i < attrib.length; i++) {
518
+ inserted[attrib[i]] = true;
519
+ }
520
+
521
+ nodesToHydrate.push(node);
522
+ });
523
+ }
524
+
525
+ var _insert;
526
+ /*: (
527
+ selector: string,
528
+ serialized: SerializedStyles,
529
+ sheet: StyleSheet,
530
+ shouldCache: boolean
531
+ ) => string | void */
532
+
533
+
534
+ var omnipresentPlugins = [compat, removeLabel];
535
+
536
+ {
537
+ omnipresentPlugins.push(createUnsafeSelectorsAlarm({
538
+ get compat() {
539
+ return cache.compat;
540
+ }
541
+
542
+ }), incorrectImportAlarm);
543
+ }
544
+
545
+ {
546
+ var currentSheet;
547
+ var finalizingPlugins = [stylis.stringify, function (element) {
548
+ if (!element.root) {
549
+ if (element["return"]) {
550
+ currentSheet.insert(element["return"]);
551
+ } else if (element.value && element.type !== stylis.COMMENT) {
552
+ // insert empty rule in non-production environments
553
+ // so @emotion/jest can grab `key` from the (JS)DOM for caches without any rules inserted yet
554
+ currentSheet.insert(element.value + "{}");
555
+ }
556
+ }
557
+ } ];
558
+ var serializer = stylis.middleware(omnipresentPlugins.concat(stylisPlugins, finalizingPlugins));
559
+
560
+ var stylis$1 = function stylis$1(styles) {
561
+ return stylis.serialize(stylis.compile(styles), serializer);
562
+ };
563
+
564
+ _insert = function
565
+ /*: void */
566
+ insert(selector
567
+ /*: string */
568
+ , serialized
569
+ /*: SerializedStyles */
570
+ , sheet
571
+ /*: StyleSheet */
572
+ , shouldCache
573
+ /*: boolean */
574
+ ) {
575
+ currentSheet = sheet;
576
+
577
+ if (serialized.map !== undefined) {
578
+ currentSheet = {
579
+ insert: function insert(rule
580
+ /*: string */
581
+ ) {
582
+ sheet.insert(rule + serialized.map);
583
+ }
584
+ };
585
+ }
586
+
587
+ stylis$1(selector ? selector + "{" + serialized.styles + "}" : serialized.styles);
588
+
589
+ if (shouldCache) {
590
+ cache.inserted[serialized.name] = true;
591
+ }
592
+ };
593
+ }
594
+
595
+ var cache
596
+ /*: EmotionCache */
597
+ = {
598
+ key: key,
599
+ sheet: new sheet.StyleSheet({
600
+ key: key,
601
+ container: container,
602
+ nonce: options.nonce,
603
+ speedy: options.speedy,
604
+ prepend: options.prepend,
605
+ insertionPoint: options.insertionPoint
606
+ }),
607
+ nonce: options.nonce,
608
+ inserted: inserted,
609
+ registered: {},
610
+ insert: _insert
611
+ };
612
+ cache.sheet.hydrate(nodesToHydrate);
613
+ return cache;
614
+ };
615
+
616
+ exports["default"] = createCache;
@@ -0,0 +1,2 @@
1
+ import "./emotion-cache.browser.development.cjs.js";
2
+ export { _default as default } from "./emotion-cache.browser.development.cjs.default.js";