@groupeactual/ui-kit 0.3.6 → 0.3.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.
package/dist/cjs/index.js CHANGED
@@ -4,8 +4,6 @@ Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  var jsxRuntime = require('react/jsx-runtime');
6
6
  var React = require('react');
7
- var emStyled = require('@emotion/styled');
8
- var react = require('@emotion/react');
9
7
 
10
8
  function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
11
9
 
@@ -29,7 +27,6 @@ function _interopNamespace(e) {
29
27
 
30
28
  var React__namespace = /*#__PURE__*/_interopNamespace(React);
31
29
  var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
32
- var emStyled__default = /*#__PURE__*/_interopDefaultLegacy(emStyled);
33
30
 
34
31
  /******************************************************************************
35
32
  Copyright (c) Microsoft Corporation.
@@ -233,9 +230,1373 @@ function _objectWithoutPropertiesLoose(source, excluded) {
233
230
  return target;
234
231
  }
235
232
 
236
- var propTypes = {exports: {}};
233
+ function memoize$1(fn) {
234
+ var cache = Object.create(null);
235
+ return function (arg) {
236
+ if (cache[arg] === undefined) cache[arg] = fn(arg);
237
+ return cache[arg];
238
+ };
239
+ }
240
+
241
+ var reactPropsRegex = /^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|enterKeyHint|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/; // https://esbench.com/bench/5bfee68a4cd7e6009ef61d23
242
+
243
+ var isPropValid = /* #__PURE__ */memoize$1(function (prop) {
244
+ return reactPropsRegex.test(prop) || prop.charCodeAt(0) === 111
245
+ /* o */
246
+ && prop.charCodeAt(1) === 110
247
+ /* n */
248
+ && prop.charCodeAt(2) < 91;
249
+ }
250
+ /* Z+1 */
251
+ );
252
+
253
+ /*
254
+
255
+ Based off glamor's StyleSheet, thanks Sunil ❤️
256
+
257
+ high performance StyleSheet for css-in-js systems
258
+
259
+ - uses multiple style tags behind the scenes for millions of rules
260
+ - uses `insertRule` for appending in production for *much* faster performance
261
+
262
+ // usage
263
+
264
+ import { StyleSheet } from '@emotion/sheet'
265
+
266
+ let styleSheet = new StyleSheet({ key: '', container: document.head })
267
+
268
+ styleSheet.insert('#box { border: 1px solid red; }')
269
+ - appends a css rule into the stylesheet
270
+
271
+ styleSheet.flush()
272
+ - empties the stylesheet of all its contents
273
+
274
+ */
275
+ // $FlowFixMe
276
+ function sheetForTag(tag) {
277
+ if (tag.sheet) {
278
+ // $FlowFixMe
279
+ return tag.sheet;
280
+ } // this weirdness brought to you by firefox
281
+
282
+ /* istanbul ignore next */
283
+
284
+
285
+ for (var i = 0; i < document.styleSheets.length; i++) {
286
+ if (document.styleSheets[i].ownerNode === tag) {
287
+ // $FlowFixMe
288
+ return document.styleSheets[i];
289
+ }
290
+ }
291
+ }
292
+
293
+ function createStyleElement(options) {
294
+ var tag = document.createElement('style');
295
+ tag.setAttribute('data-emotion', options.key);
296
+
297
+ if (options.nonce !== undefined) {
298
+ tag.setAttribute('nonce', options.nonce);
299
+ }
300
+
301
+ tag.appendChild(document.createTextNode(''));
302
+ tag.setAttribute('data-s', '');
303
+ return tag;
304
+ }
305
+
306
+ var StyleSheet = /*#__PURE__*/function () {
307
+ // Using Node instead of HTMLElement since container may be a ShadowRoot
308
+ function StyleSheet(options) {
309
+ var _this = this;
310
+
311
+ this._insertTag = function (tag) {
312
+ var before;
313
+
314
+ if (_this.tags.length === 0) {
315
+ if (_this.insertionPoint) {
316
+ before = _this.insertionPoint.nextSibling;
317
+ } else if (_this.prepend) {
318
+ before = _this.container.firstChild;
319
+ } else {
320
+ before = _this.before;
321
+ }
322
+ } else {
323
+ before = _this.tags[_this.tags.length - 1].nextSibling;
324
+ }
325
+
326
+ _this.container.insertBefore(tag, before);
327
+
328
+ _this.tags.push(tag);
329
+ };
330
+
331
+ this.isSpeedy = options.speedy === undefined ? process.env.NODE_ENV === 'production' : options.speedy;
332
+ this.tags = [];
333
+ this.ctr = 0;
334
+ this.nonce = options.nonce; // key is the value of the data-emotion attribute, it's used to identify different sheets
335
+
336
+ this.key = options.key;
337
+ this.container = options.container;
338
+ this.prepend = options.prepend;
339
+ this.insertionPoint = options.insertionPoint;
340
+ this.before = null;
341
+ }
342
+
343
+ var _proto = StyleSheet.prototype;
344
+
345
+ _proto.hydrate = function hydrate(nodes) {
346
+ nodes.forEach(this._insertTag);
347
+ };
348
+
349
+ _proto.insert = function insert(rule) {
350
+ // the max length is how many rules we have per style tag, it's 65000 in speedy mode
351
+ // it's 1 in dev because we insert source maps that map a single rule to a location
352
+ // and you can only have one source map per style tag
353
+ if (this.ctr % (this.isSpeedy ? 65000 : 1) === 0) {
354
+ this._insertTag(createStyleElement(this));
355
+ }
356
+
357
+ var tag = this.tags[this.tags.length - 1];
358
+
359
+ if (process.env.NODE_ENV !== 'production') {
360
+ var isImportRule = rule.charCodeAt(0) === 64 && rule.charCodeAt(1) === 105;
361
+
362
+ if (isImportRule && this._alreadyInsertedOrderInsensitiveRule) {
363
+ // this would only cause problem in speedy mode
364
+ // but we don't want enabling speedy to affect the observable behavior
365
+ // so we report this error at all times
366
+ console.error("You're attempting to insert the following rule:\n" + rule + '\n\n`@import` rules must be before all other types of rules in a stylesheet but other rules have already been inserted. Please ensure that `@import` rules are before all other rules.');
367
+ }
368
+ this._alreadyInsertedOrderInsensitiveRule = this._alreadyInsertedOrderInsensitiveRule || !isImportRule;
369
+ }
370
+
371
+ if (this.isSpeedy) {
372
+ var sheet = sheetForTag(tag);
373
+
374
+ try {
375
+ // this is the ultrafast version, works across browsers
376
+ // the big drawback is that the css won't be editable in devtools
377
+ sheet.insertRule(rule, sheet.cssRules.length);
378
+ } catch (e) {
379
+ if (process.env.NODE_ENV !== 'production' && !/:(-moz-placeholder|-moz-focus-inner|-moz-focusring|-ms-input-placeholder|-moz-read-write|-moz-read-only|-ms-clear){/.test(rule)) {
380
+ console.error("There was a problem inserting the following rule: \"" + rule + "\"", e);
381
+ }
382
+ }
383
+ } else {
384
+ tag.appendChild(document.createTextNode(rule));
385
+ }
386
+
387
+ this.ctr++;
388
+ };
389
+
390
+ _proto.flush = function flush() {
391
+ // $FlowFixMe
392
+ this.tags.forEach(function (tag) {
393
+ return tag.parentNode && tag.parentNode.removeChild(tag);
394
+ });
395
+ this.tags = [];
396
+ this.ctr = 0;
397
+
398
+ if (process.env.NODE_ENV !== 'production') {
399
+ this._alreadyInsertedOrderInsensitiveRule = false;
400
+ }
401
+ };
402
+
403
+ return StyleSheet;
404
+ }();
405
+
406
+ var MS = '-ms-';
407
+ var MOZ = '-moz-';
408
+ var WEBKIT = '-webkit-';
409
+
410
+ var COMMENT = 'comm';
411
+ var RULESET = 'rule';
412
+ var DECLARATION = 'decl';
413
+ var IMPORT = '@import';
414
+ var KEYFRAMES = '@keyframes';
415
+
416
+ /**
417
+ * @param {number}
418
+ * @return {number}
419
+ */
420
+ var abs = Math.abs;
421
+
422
+ /**
423
+ * @param {number}
424
+ * @return {string}
425
+ */
426
+ var from = String.fromCharCode;
427
+
428
+ /**
429
+ * @param {object}
430
+ * @return {object}
431
+ */
432
+ var assign$1 = Object.assign;
433
+
434
+ /**
435
+ * @param {string} value
436
+ * @param {number} length
437
+ * @return {number}
438
+ */
439
+ function hash (value, length) {
440
+ return (((((((length << 2) ^ charat(value, 0)) << 2) ^ charat(value, 1)) << 2) ^ charat(value, 2)) << 2) ^ charat(value, 3)
441
+ }
442
+
443
+ /**
444
+ * @param {string} value
445
+ * @return {string}
446
+ */
447
+ function trim (value) {
448
+ return value.trim()
449
+ }
450
+
451
+ /**
452
+ * @param {string} value
453
+ * @param {RegExp} pattern
454
+ * @return {string?}
455
+ */
456
+ function match (value, pattern) {
457
+ return (value = pattern.exec(value)) ? value[0] : value
458
+ }
459
+
460
+ /**
461
+ * @param {string} value
462
+ * @param {(string|RegExp)} pattern
463
+ * @param {string} replacement
464
+ * @return {string}
465
+ */
466
+ function replace (value, pattern, replacement) {
467
+ return value.replace(pattern, replacement)
468
+ }
469
+
470
+ /**
471
+ * @param {string} value
472
+ * @param {string} search
473
+ * @return {number}
474
+ */
475
+ function indexof (value, search) {
476
+ return value.indexOf(search)
477
+ }
478
+
479
+ /**
480
+ * @param {string} value
481
+ * @param {number} index
482
+ * @return {number}
483
+ */
484
+ function charat (value, index) {
485
+ return value.charCodeAt(index) | 0
486
+ }
487
+
488
+ /**
489
+ * @param {string} value
490
+ * @param {number} begin
491
+ * @param {number} end
492
+ * @return {string}
493
+ */
494
+ function substr (value, begin, end) {
495
+ return value.slice(begin, end)
496
+ }
497
+
498
+ /**
499
+ * @param {string} value
500
+ * @return {number}
501
+ */
502
+ function strlen (value) {
503
+ return value.length
504
+ }
505
+
506
+ /**
507
+ * @param {any[]} value
508
+ * @return {number}
509
+ */
510
+ function sizeof (value) {
511
+ return value.length
512
+ }
513
+
514
+ /**
515
+ * @param {any} value
516
+ * @param {any[]} array
517
+ * @return {any}
518
+ */
519
+ function append (value, array) {
520
+ return array.push(value), value
521
+ }
522
+
523
+ /**
524
+ * @param {string[]} array
525
+ * @param {function} callback
526
+ * @return {string}
527
+ */
528
+ function combine (array, callback) {
529
+ return array.map(callback).join('')
530
+ }
531
+
532
+ var line = 1;
533
+ var column = 1;
534
+ var length = 0;
535
+ var position$1 = 0;
536
+ var character = 0;
537
+ var characters = '';
538
+
539
+ /**
540
+ * @param {string} value
541
+ * @param {object | null} root
542
+ * @param {object | null} parent
543
+ * @param {string} type
544
+ * @param {string[] | string} props
545
+ * @param {object[] | string} children
546
+ * @param {number} length
547
+ */
548
+ function node (value, root, parent, type, props, children, length) {
549
+ return {value: value, root: root, parent: parent, type: type, props: props, children: children, line: line, column: column, length: length, return: ''}
550
+ }
551
+
552
+ /**
553
+ * @param {object} root
554
+ * @param {object} props
555
+ * @return {object}
556
+ */
557
+ function copy (root, props) {
558
+ return assign$1(node('', null, null, '', null, null, 0), root, {length: -root.length}, props)
559
+ }
560
+
561
+ /**
562
+ * @return {number}
563
+ */
564
+ function char () {
565
+ return character
566
+ }
567
+
568
+ /**
569
+ * @return {number}
570
+ */
571
+ function prev () {
572
+ character = position$1 > 0 ? charat(characters, --position$1) : 0;
573
+
574
+ if (column--, character === 10)
575
+ column = 1, line--;
576
+
577
+ return character
578
+ }
579
+
580
+ /**
581
+ * @return {number}
582
+ */
583
+ function next () {
584
+ character = position$1 < length ? charat(characters, position$1++) : 0;
585
+
586
+ if (column++, character === 10)
587
+ column = 1, line++;
588
+
589
+ return character
590
+ }
591
+
592
+ /**
593
+ * @return {number}
594
+ */
595
+ function peek () {
596
+ return charat(characters, position$1)
597
+ }
598
+
599
+ /**
600
+ * @return {number}
601
+ */
602
+ function caret () {
603
+ return position$1
604
+ }
605
+
606
+ /**
607
+ * @param {number} begin
608
+ * @param {number} end
609
+ * @return {string}
610
+ */
611
+ function slice (begin, end) {
612
+ return substr(characters, begin, end)
613
+ }
614
+
615
+ /**
616
+ * @param {number} type
617
+ * @return {number}
618
+ */
619
+ function token (type) {
620
+ switch (type) {
621
+ // \0 \t \n \r \s whitespace token
622
+ case 0: case 9: case 10: case 13: case 32:
623
+ return 5
624
+ // ! + , / > @ ~ isolate token
625
+ case 33: case 43: case 44: case 47: case 62: case 64: case 126:
626
+ // ; { } breakpoint token
627
+ case 59: case 123: case 125:
628
+ return 4
629
+ // : accompanied token
630
+ case 58:
631
+ return 3
632
+ // " ' ( [ opening delimit token
633
+ case 34: case 39: case 40: case 91:
634
+ return 2
635
+ // ) ] closing delimit token
636
+ case 41: case 93:
637
+ return 1
638
+ }
639
+
640
+ return 0
641
+ }
642
+
643
+ /**
644
+ * @param {string} value
645
+ * @return {any[]}
646
+ */
647
+ function alloc (value) {
648
+ return line = column = 1, length = strlen(characters = value), position$1 = 0, []
649
+ }
650
+
651
+ /**
652
+ * @param {any} value
653
+ * @return {any}
654
+ */
655
+ function dealloc (value) {
656
+ return characters = '', value
657
+ }
658
+
659
+ /**
660
+ * @param {number} type
661
+ * @return {string}
662
+ */
663
+ function delimit (type) {
664
+ return trim(slice(position$1 - 1, delimiter(type === 91 ? type + 2 : type === 40 ? type + 1 : type)))
665
+ }
666
+
667
+ /**
668
+ * @param {number} type
669
+ * @return {string}
670
+ */
671
+ function whitespace (type) {
672
+ while (character = peek())
673
+ if (character < 33)
674
+ next();
675
+ else
676
+ break
677
+
678
+ return token(type) > 2 || token(character) > 3 ? '' : ' '
679
+ }
680
+
681
+ /**
682
+ * @param {number} index
683
+ * @param {number} count
684
+ * @return {string}
685
+ */
686
+ function escaping (index, count) {
687
+ while (--count && next())
688
+ // not 0-9 A-F a-f
689
+ if (character < 48 || character > 102 || (character > 57 && character < 65) || (character > 70 && character < 97))
690
+ break
691
+
692
+ return slice(index, caret() + (count < 6 && peek() == 32 && next() == 32))
693
+ }
694
+
695
+ /**
696
+ * @param {number} type
697
+ * @return {number}
698
+ */
699
+ function delimiter (type) {
700
+ while (next())
701
+ switch (character) {
702
+ // ] ) " '
703
+ case type:
704
+ return position$1
705
+ // " '
706
+ case 34: case 39:
707
+ if (type !== 34 && type !== 39)
708
+ delimiter(character);
709
+ break
710
+ // (
711
+ case 40:
712
+ if (type === 41)
713
+ delimiter(type);
714
+ break
715
+ // \
716
+ case 92:
717
+ next();
718
+ break
719
+ }
720
+
721
+ return position$1
722
+ }
723
+
724
+ /**
725
+ * @param {number} type
726
+ * @param {number} index
727
+ * @return {number}
728
+ */
729
+ function commenter (type, index) {
730
+ while (next())
731
+ // //
732
+ if (type + character === 47 + 10)
733
+ break
734
+ // /*
735
+ else if (type + character === 42 + 42 && peek() === 47)
736
+ break
737
+
738
+ return '/*' + slice(index, position$1 - 1) + '*' + from(type === 47 ? type : next())
739
+ }
740
+
741
+ /**
742
+ * @param {number} index
743
+ * @return {string}
744
+ */
745
+ function identifier (index) {
746
+ while (!token(peek()))
747
+ next();
748
+
749
+ return slice(index, position$1)
750
+ }
751
+
752
+ /**
753
+ * @param {string} value
754
+ * @return {object[]}
755
+ */
756
+ function compile (value) {
757
+ return dealloc(parse('', null, null, null, [''], value = alloc(value), 0, [0], value))
758
+ }
759
+
760
+ /**
761
+ * @param {string} value
762
+ * @param {object} root
763
+ * @param {object?} parent
764
+ * @param {string[]} rule
765
+ * @param {string[]} rules
766
+ * @param {string[]} rulesets
767
+ * @param {number[]} pseudo
768
+ * @param {number[]} points
769
+ * @param {string[]} declarations
770
+ * @return {object}
771
+ */
772
+ function parse (value, root, parent, rule, rules, rulesets, pseudo, points, declarations) {
773
+ var index = 0;
774
+ var offset = 0;
775
+ var length = pseudo;
776
+ var atrule = 0;
777
+ var property = 0;
778
+ var previous = 0;
779
+ var variable = 1;
780
+ var scanning = 1;
781
+ var ampersand = 1;
782
+ var character = 0;
783
+ var type = '';
784
+ var props = rules;
785
+ var children = rulesets;
786
+ var reference = rule;
787
+ var characters = type;
788
+
789
+ while (scanning)
790
+ switch (previous = character, character = next()) {
791
+ // (
792
+ case 40:
793
+ if (previous != 108 && characters.charCodeAt(length - 1) == 58) {
794
+ if (indexof(characters += replace(delimit(character), '&', '&\f'), '&\f') != -1)
795
+ ampersand = -1;
796
+ break
797
+ }
798
+ // " ' [
799
+ case 34: case 39: case 91:
800
+ characters += delimit(character);
801
+ break
802
+ // \t \n \r \s
803
+ case 9: case 10: case 13: case 32:
804
+ characters += whitespace(previous);
805
+ break
806
+ // \
807
+ case 92:
808
+ characters += escaping(caret() - 1, 7);
809
+ continue
810
+ // /
811
+ case 47:
812
+ switch (peek()) {
813
+ case 42: case 47:
814
+ append(comment(commenter(next(), caret()), root, parent), declarations);
815
+ break
816
+ default:
817
+ characters += '/';
818
+ }
819
+ break
820
+ // {
821
+ case 123 * variable:
822
+ points[index++] = strlen(characters) * ampersand;
823
+ // } ; \0
824
+ case 125 * variable: case 59: case 0:
825
+ switch (character) {
826
+ // \0 }
827
+ case 0: case 125: scanning = 0;
828
+ // ;
829
+ case 59 + offset:
830
+ if (property > 0 && (strlen(characters) - length))
831
+ append(property > 32 ? declaration(characters + ';', rule, parent, length - 1) : declaration(replace(characters, ' ', '') + ';', rule, parent, length - 2), declarations);
832
+ break
833
+ // @ ;
834
+ case 59: characters += ';';
835
+ // { rule/at-rule
836
+ default:
837
+ append(reference = ruleset(characters, root, parent, index, offset, rules, points, type, props = [], children = [], length), rulesets);
838
+
839
+ if (character === 123)
840
+ if (offset === 0)
841
+ parse(characters, root, reference, reference, props, rulesets, length, points, children);
842
+ else
843
+ switch (atrule) {
844
+ // d m s
845
+ case 100: case 109: case 115:
846
+ parse(value, reference, reference, rule && append(ruleset(value, reference, reference, 0, 0, rules, points, type, rules, props = [], length), children), rules, children, length, points, rule ? props : children);
847
+ break
848
+ default:
849
+ parse(characters, reference, reference, reference, [''], children, 0, points, children);
850
+ }
851
+ }
852
+
853
+ index = offset = property = 0, variable = ampersand = 1, type = characters = '', length = pseudo;
854
+ break
855
+ // :
856
+ case 58:
857
+ length = 1 + strlen(characters), property = previous;
858
+ default:
859
+ if (variable < 1)
860
+ if (character == 123)
861
+ --variable;
862
+ else if (character == 125 && variable++ == 0 && prev() == 125)
863
+ continue
864
+
865
+ switch (characters += from(character), character * variable) {
866
+ // &
867
+ case 38:
868
+ ampersand = offset > 0 ? 1 : (characters += '\f', -1);
869
+ break
870
+ // ,
871
+ case 44:
872
+ points[index++] = (strlen(characters) - 1) * ampersand, ampersand = 1;
873
+ break
874
+ // @
875
+ case 64:
876
+ // -
877
+ if (peek() === 45)
878
+ characters += delimit(next());
879
+
880
+ atrule = peek(), offset = length = strlen(type = characters += identifier(caret())), character++;
881
+ break
882
+ // -
883
+ case 45:
884
+ if (previous === 45 && strlen(characters) == 2)
885
+ variable = 0;
886
+ }
887
+ }
888
+
889
+ return rulesets
890
+ }
891
+
892
+ /**
893
+ * @param {string} value
894
+ * @param {object} root
895
+ * @param {object?} parent
896
+ * @param {number} index
897
+ * @param {number} offset
898
+ * @param {string[]} rules
899
+ * @param {number[]} points
900
+ * @param {string} type
901
+ * @param {string[]} props
902
+ * @param {string[]} children
903
+ * @param {number} length
904
+ * @return {object}
905
+ */
906
+ function ruleset (value, root, parent, index, offset, rules, points, type, props, children, length) {
907
+ var post = offset - 1;
908
+ var rule = offset === 0 ? rules : [''];
909
+ var size = sizeof(rule);
910
+
911
+ for (var i = 0, j = 0, k = 0; i < index; ++i)
912
+ for (var x = 0, y = substr(value, post + 1, post = abs(j = points[i])), z = value; x < size; ++x)
913
+ if (z = trim(j > 0 ? rule[x] + ' ' + y : replace(y, /&\f/g, rule[x])))
914
+ props[k++] = z;
915
+
916
+ return node(value, root, parent, offset === 0 ? RULESET : type, props, children, length)
917
+ }
918
+
919
+ /**
920
+ * @param {number} value
921
+ * @param {object} root
922
+ * @param {object?} parent
923
+ * @return {object}
924
+ */
925
+ function comment (value, root, parent) {
926
+ return node(value, root, parent, COMMENT, from(char()), substr(value, 2, -2), 0)
927
+ }
928
+
929
+ /**
930
+ * @param {string} value
931
+ * @param {object} root
932
+ * @param {object?} parent
933
+ * @param {number} length
934
+ * @return {object}
935
+ */
936
+ function declaration (value, root, parent, length) {
937
+ return node(value, root, parent, DECLARATION, substr(value, 0, length), substr(value, length + 1, -1), length)
938
+ }
939
+
940
+ /**
941
+ * @param {string} value
942
+ * @param {number} length
943
+ * @return {string}
944
+ */
945
+ function prefix (value, length) {
946
+ switch (hash(value, length)) {
947
+ // color-adjust
948
+ case 5103:
949
+ return WEBKIT + 'print-' + value + value
950
+ // animation, animation-(delay|direction|duration|fill-mode|iteration-count|name|play-state|timing-function)
951
+ case 5737: case 4201: case 3177: case 3433: case 1641: case 4457: case 2921:
952
+ // text-decoration, filter, clip-path, backface-visibility, column, box-decoration-break
953
+ case 5572: case 6356: case 5844: case 3191: case 6645: case 3005:
954
+ // mask, mask-image, mask-(mode|clip|size), mask-(repeat|origin), mask-position, mask-composite,
955
+ case 6391: case 5879: case 5623: case 6135: case 4599: case 4855:
956
+ // background-clip, columns, column-(count|fill|gap|rule|rule-color|rule-style|rule-width|span|width)
957
+ case 4215: case 6389: case 5109: case 5365: case 5621: case 3829:
958
+ return WEBKIT + value + value
959
+ // appearance, user-select, transform, hyphens, text-size-adjust
960
+ case 5349: case 4246: case 4810: case 6968: case 2756:
961
+ return WEBKIT + value + MOZ + value + MS + value + value
962
+ // flex, flex-direction
963
+ case 6828: case 4268:
964
+ return WEBKIT + value + MS + value + value
965
+ // order
966
+ case 6165:
967
+ return WEBKIT + value + MS + 'flex-' + value + value
968
+ // align-items
969
+ case 5187:
970
+ return WEBKIT + value + replace(value, /(\w+).+(:[^]+)/, WEBKIT + 'box-$1$2' + MS + 'flex-$1$2') + value
971
+ // align-self
972
+ case 5443:
973
+ return WEBKIT + value + MS + 'flex-item-' + replace(value, /flex-|-self/, '') + value
974
+ // align-content
975
+ case 4675:
976
+ return WEBKIT + value + MS + 'flex-line-pack' + replace(value, /align-content|flex-|-self/, '') + value
977
+ // flex-shrink
978
+ case 5548:
979
+ return WEBKIT + value + MS + replace(value, 'shrink', 'negative') + value
980
+ // flex-basis
981
+ case 5292:
982
+ return WEBKIT + value + MS + replace(value, 'basis', 'preferred-size') + value
983
+ // flex-grow
984
+ case 6060:
985
+ return WEBKIT + 'box-' + replace(value, '-grow', '') + WEBKIT + value + MS + replace(value, 'grow', 'positive') + value
986
+ // transition
987
+ case 4554:
988
+ return WEBKIT + replace(value, /([^-])(transform)/g, '$1' + WEBKIT + '$2') + value
989
+ // cursor
990
+ case 6187:
991
+ return replace(replace(replace(value, /(zoom-|grab)/, WEBKIT + '$1'), /(image-set)/, WEBKIT + '$1'), value, '') + value
992
+ // background, background-image
993
+ case 5495: case 3959:
994
+ return replace(value, /(image-set\([^]*)/, WEBKIT + '$1' + '$`$1')
995
+ // justify-content
996
+ case 4968:
997
+ return replace(replace(value, /(.+:)(flex-)?(.*)/, WEBKIT + 'box-pack:$3' + MS + 'flex-pack:$3'), /s.+-b[^;]+/, 'justify') + WEBKIT + value + value
998
+ // (margin|padding)-inline-(start|end)
999
+ case 4095: case 3583: case 4068: case 2532:
1000
+ return replace(value, /(.+)-inline(.+)/, WEBKIT + '$1$2') + value
1001
+ // (min|max)?(width|height|inline-size|block-size)
1002
+ case 8116: case 7059: case 5753: case 5535:
1003
+ case 5445: case 5701: case 4933: case 4677:
1004
+ case 5533: case 5789: case 5021: case 4765:
1005
+ // stretch, max-content, min-content, fill-available
1006
+ if (strlen(value) - 1 - length > 6)
1007
+ switch (charat(value, length + 1)) {
1008
+ // (m)ax-content, (m)in-content
1009
+ case 109:
1010
+ // -
1011
+ if (charat(value, length + 4) !== 45)
1012
+ break
1013
+ // (f)ill-available, (f)it-content
1014
+ case 102:
1015
+ return replace(value, /(.+:)(.+)-([^]+)/, '$1' + WEBKIT + '$2-$3' + '$1' + MOZ + (charat(value, length + 3) == 108 ? '$3' : '$2-$3')) + value
1016
+ // (s)tretch
1017
+ case 115:
1018
+ return ~indexof(value, 'stretch') ? prefix(replace(value, 'stretch', 'fill-available'), length) + value : value
1019
+ }
1020
+ break
1021
+ // position: sticky
1022
+ case 4949:
1023
+ // (s)ticky?
1024
+ if (charat(value, length + 1) !== 115)
1025
+ break
1026
+ // display: (flex|inline-flex)
1027
+ case 6444:
1028
+ switch (charat(value, strlen(value) - 3 - (~indexof(value, '!important') && 10))) {
1029
+ // stic(k)y
1030
+ case 107:
1031
+ return replace(value, ':', ':' + WEBKIT) + value
1032
+ // (inline-)?fl(e)x
1033
+ case 101:
1034
+ return replace(value, /(.+:)([^;!]+)(;|!.+)?/, '$1' + WEBKIT + (charat(value, 14) === 45 ? 'inline-' : '') + 'box$3' + '$1' + WEBKIT + '$2$3' + '$1' + MS + '$2box$3') + value
1035
+ }
1036
+ break
1037
+ // writing-mode
1038
+ case 5936:
1039
+ switch (charat(value, length + 11)) {
1040
+ // vertical-l(r)
1041
+ case 114:
1042
+ return WEBKIT + value + MS + replace(value, /[svh]\w+-[tblr]{2}/, 'tb') + value
1043
+ // vertical-r(l)
1044
+ case 108:
1045
+ return WEBKIT + value + MS + replace(value, /[svh]\w+-[tblr]{2}/, 'tb-rl') + value
1046
+ // horizontal(-)tb
1047
+ case 45:
1048
+ return WEBKIT + value + MS + replace(value, /[svh]\w+-[tblr]{2}/, 'lr') + value
1049
+ }
1050
+
1051
+ return WEBKIT + value + MS + value + value
1052
+ }
1053
+
1054
+ return value
1055
+ }
1056
+
1057
+ /**
1058
+ * @param {object[]} children
1059
+ * @param {function} callback
1060
+ * @return {string}
1061
+ */
1062
+ function serialize (children, callback) {
1063
+ var output = '';
1064
+ var length = sizeof(children);
1065
+
1066
+ for (var i = 0; i < length; i++)
1067
+ output += callback(children[i], i, children, callback) || '';
1068
+
1069
+ return output
1070
+ }
1071
+
1072
+ /**
1073
+ * @param {object} element
1074
+ * @param {number} index
1075
+ * @param {object[]} children
1076
+ * @param {function} callback
1077
+ * @return {string}
1078
+ */
1079
+ function stringify (element, index, children, callback) {
1080
+ switch (element.type) {
1081
+ case IMPORT: case DECLARATION: return element.return = element.return || element.value
1082
+ case COMMENT: return ''
1083
+ case KEYFRAMES: return element.return = element.value + '{' + serialize(element.children, callback) + '}'
1084
+ case RULESET: element.value = element.props.join(',');
1085
+ }
1086
+
1087
+ return strlen(children = serialize(element.children, callback)) ? element.return = element.value + '{' + children + '}' : ''
1088
+ }
1089
+
1090
+ /**
1091
+ * @param {function[]} collection
1092
+ * @return {function}
1093
+ */
1094
+ function middleware (collection) {
1095
+ var length = sizeof(collection);
1096
+
1097
+ return function (element, index, children, callback) {
1098
+ var output = '';
1099
+
1100
+ for (var i = 0; i < length; i++)
1101
+ output += collection[i](element, index, children, callback) || '';
1102
+
1103
+ return output
1104
+ }
1105
+ }
1106
+
1107
+ /**
1108
+ * @param {function} callback
1109
+ * @return {function}
1110
+ */
1111
+ function rulesheet (callback) {
1112
+ return function (element) {
1113
+ if (!element.root)
1114
+ if (element = element.return)
1115
+ callback(element);
1116
+ }
1117
+ }
1118
+
1119
+ /**
1120
+ * @param {object} element
1121
+ * @param {number} index
1122
+ * @param {object[]} children
1123
+ * @param {function} callback
1124
+ */
1125
+ function prefixer (element, index, children, callback) {
1126
+ if (element.length > -1)
1127
+ if (!element.return)
1128
+ switch (element.type) {
1129
+ case DECLARATION: element.return = prefix(element.value, element.length);
1130
+ break
1131
+ case KEYFRAMES:
1132
+ return serialize([copy(element, {value: replace(element.value, '@', '@' + WEBKIT)})], callback)
1133
+ case RULESET:
1134
+ if (element.length)
1135
+ return combine(element.props, function (value) {
1136
+ switch (match(value, /(::plac\w+|:read-\w+)/)) {
1137
+ // :read-(only|write)
1138
+ case ':read-only': case ':read-write':
1139
+ return serialize([copy(element, {props: [replace(value, /:(read-\w+)/, ':' + MOZ + '$1')]})], callback)
1140
+ // :placeholder
1141
+ case '::placeholder':
1142
+ return serialize([
1143
+ copy(element, {props: [replace(value, /:(plac\w+)/, ':' + WEBKIT + 'input-$1')]}),
1144
+ copy(element, {props: [replace(value, /:(plac\w+)/, ':' + MOZ + '$1')]}),
1145
+ copy(element, {props: [replace(value, /:(plac\w+)/, MS + 'input-$1')]})
1146
+ ], callback)
1147
+ }
1148
+
1149
+ return ''
1150
+ })
1151
+ }
1152
+ }
1153
+
1154
+ var weakMemoize = function weakMemoize(func) {
1155
+ // $FlowFixMe flow doesn't include all non-primitive types as allowed for weakmaps
1156
+ var cache = new WeakMap();
1157
+ return function (arg) {
1158
+ if (cache.has(arg)) {
1159
+ // $FlowFixMe
1160
+ return cache.get(arg);
1161
+ }
1162
+
1163
+ var ret = func(arg);
1164
+ cache.set(arg, ret);
1165
+ return ret;
1166
+ };
1167
+ };
1168
+
1169
+ var identifierWithPointTracking = function identifierWithPointTracking(begin, points, index) {
1170
+ var previous = 0;
1171
+ var character = 0;
1172
+
1173
+ while (true) {
1174
+ previous = character;
1175
+ character = peek(); // &\f
1176
+
1177
+ if (previous === 38 && character === 12) {
1178
+ points[index] = 1;
1179
+ }
1180
+
1181
+ if (token(character)) {
1182
+ break;
1183
+ }
1184
+
1185
+ next();
1186
+ }
1187
+
1188
+ return slice(begin, position$1);
1189
+ };
1190
+
1191
+ var toRules = function toRules(parsed, points) {
1192
+ // pretend we've started with a comma
1193
+ var index = -1;
1194
+ var character = 44;
1195
+
1196
+ do {
1197
+ switch (token(character)) {
1198
+ case 0:
1199
+ // &\f
1200
+ if (character === 38 && peek() === 12) {
1201
+ // this is not 100% correct, we don't account for literal sequences here - like for example quoted strings
1202
+ // stylis inserts \f after & to know when & where it should replace this sequence with the context selector
1203
+ // and when it should just concatenate the outer and inner selectors
1204
+ // it's very unlikely for this sequence to actually appear in a different context, so we just leverage this fact here
1205
+ points[index] = 1;
1206
+ }
1207
+
1208
+ parsed[index] += identifierWithPointTracking(position$1 - 1, points, index);
1209
+ break;
1210
+
1211
+ case 2:
1212
+ parsed[index] += delimit(character);
1213
+ break;
1214
+
1215
+ case 4:
1216
+ // comma
1217
+ if (character === 44) {
1218
+ // colon
1219
+ parsed[++index] = peek() === 58 ? '&\f' : '';
1220
+ points[index] = parsed[index].length;
1221
+ break;
1222
+ }
1223
+
1224
+ // fallthrough
1225
+
1226
+ default:
1227
+ parsed[index] += from(character);
1228
+ }
1229
+ } while (character = next());
1230
+
1231
+ return parsed;
1232
+ };
1233
+
1234
+ var getRules = function getRules(value, points) {
1235
+ return dealloc(toRules(alloc(value), points));
1236
+ }; // WeakSet would be more appropriate, but only WeakMap is supported in IE11
1237
+
1238
+
1239
+ var fixedElements = /* #__PURE__ */new WeakMap();
1240
+ var compat = function compat(element) {
1241
+ if (element.type !== 'rule' || !element.parent || // positive .length indicates that this rule contains pseudo
1242
+ // negative .length indicates that this rule has been already prefixed
1243
+ element.length < 1) {
1244
+ return;
1245
+ }
1246
+
1247
+ var value = element.value,
1248
+ parent = element.parent;
1249
+ var isImplicitRule = element.column === parent.column && element.line === parent.line;
1250
+
1251
+ while (parent.type !== 'rule') {
1252
+ parent = parent.parent;
1253
+ if (!parent) return;
1254
+ } // short-circuit for the simplest case
1255
+
1256
+
1257
+ if (element.props.length === 1 && value.charCodeAt(0) !== 58
1258
+ /* colon */
1259
+ && !fixedElements.get(parent)) {
1260
+ return;
1261
+ } // if this is an implicitly inserted rule (the one eagerly inserted at the each new nested level)
1262
+ // then the props has already been manipulated beforehand as they that array is shared between it and its "rule parent"
1263
+
1264
+
1265
+ if (isImplicitRule) {
1266
+ return;
1267
+ }
1268
+
1269
+ fixedElements.set(element, true);
1270
+ var points = [];
1271
+ var rules = getRules(value, points);
1272
+ var parentRules = parent.props;
1273
+
1274
+ for (var i = 0, k = 0; i < rules.length; i++) {
1275
+ for (var j = 0; j < parentRules.length; j++, k++) {
1276
+ element.props[k] = points[i] ? rules[i].replace(/&\f/g, parentRules[j]) : parentRules[j] + " " + rules[i];
1277
+ }
1278
+ }
1279
+ };
1280
+ var removeLabel = function removeLabel(element) {
1281
+ if (element.type === 'decl') {
1282
+ var value = element.value;
1283
+
1284
+ if ( // charcode for l
1285
+ value.charCodeAt(0) === 108 && // charcode for b
1286
+ value.charCodeAt(2) === 98) {
1287
+ // this ignores label
1288
+ element["return"] = '';
1289
+ element.value = '';
1290
+ }
1291
+ }
1292
+ };
1293
+ var ignoreFlag = 'emotion-disable-server-rendering-unsafe-selector-warning-please-do-not-use-this-the-warning-exists-for-a-reason';
1294
+
1295
+ var isIgnoringComment = function isIgnoringComment(element) {
1296
+ return element.type === 'comm' && element.children.indexOf(ignoreFlag) > -1;
1297
+ };
1298
+
1299
+ var createUnsafeSelectorsAlarm = function createUnsafeSelectorsAlarm(cache) {
1300
+ return function (element, index, children) {
1301
+ if (element.type !== 'rule' || cache.compat) return;
1302
+ var unsafePseudoClasses = element.value.match(/(:first|:nth|:nth-last)-child/g);
1303
+
1304
+ if (unsafePseudoClasses) {
1305
+ var isNested = element.parent === children[0]; // in nested rules comments become children of the "auto-inserted" rule
1306
+ //
1307
+ // considering this input:
1308
+ // .a {
1309
+ // .b /* comm */ {}
1310
+ // color: hotpink;
1311
+ // }
1312
+ // we get output corresponding to this:
1313
+ // .a {
1314
+ // & {
1315
+ // /* comm */
1316
+ // color: hotpink;
1317
+ // }
1318
+ // .b {}
1319
+ // }
1320
+
1321
+ var commentContainer = isNested ? children[0].children : // global rule at the root level
1322
+ children;
1323
+
1324
+ for (var i = commentContainer.length - 1; i >= 0; i--) {
1325
+ var node = commentContainer[i];
1326
+
1327
+ if (node.line < element.line) {
1328
+ break;
1329
+ } // it is quite weird but comments are *usually* put at `column: element.column - 1`
1330
+ // so we seek *from the end* for the node that is earlier than the rule's `element` and check that
1331
+ // this will also match inputs like this:
1332
+ // .a {
1333
+ // /* comm */
1334
+ // .b {}
1335
+ // }
1336
+ //
1337
+ // but that is fine
1338
+ //
1339
+ // it would be the easiest to change the placement of the comment to be the first child of the rule:
1340
+ // .a {
1341
+ // .b { /* comm */ }
1342
+ // }
1343
+ // with such inputs we wouldn't have to search for the comment at all
1344
+ // TODO: consider changing this comment placement in the next major version
1345
+
1346
+
1347
+ if (node.column < element.column) {
1348
+ if (isIgnoringComment(node)) {
1349
+ return;
1350
+ }
1351
+
1352
+ break;
1353
+ }
1354
+ }
1355
+
1356
+ unsafePseudoClasses.forEach(function (unsafePseudoClass) {
1357
+ console.error("The pseudo class \"" + unsafePseudoClass + "\" is potentially unsafe when doing server-side rendering. Try changing it to \"" + unsafePseudoClass.split('-child')[0] + "-of-type\".");
1358
+ });
1359
+ }
1360
+ };
1361
+ };
1362
+
1363
+ var isImportRule = function isImportRule(element) {
1364
+ return element.type.charCodeAt(1) === 105 && element.type.charCodeAt(0) === 64;
1365
+ };
1366
+
1367
+ var isPrependedWithRegularRules = function isPrependedWithRegularRules(index, children) {
1368
+ for (var i = index - 1; i >= 0; i--) {
1369
+ if (!isImportRule(children[i])) {
1370
+ return true;
1371
+ }
1372
+ }
1373
+
1374
+ return false;
1375
+ }; // use this to remove incorrect elements from further processing
1376
+ // so they don't get handed to the `sheet` (or anything else)
1377
+ // as that could potentially lead to additional logs which in turn could be overhelming to the user
1378
+
1379
+
1380
+ var nullifyElement = function nullifyElement(element) {
1381
+ element.type = '';
1382
+ element.value = '';
1383
+ element["return"] = '';
1384
+ element.children = '';
1385
+ element.props = '';
1386
+ };
1387
+
1388
+ var incorrectImportAlarm = function incorrectImportAlarm(element, index, children) {
1389
+ if (!isImportRule(element)) {
1390
+ return;
1391
+ }
1392
+
1393
+ if (element.parent) {
1394
+ 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.");
1395
+ nullifyElement(element);
1396
+ } else if (isPrependedWithRegularRules(index, children)) {
1397
+ console.error("`@import` rules can't be after other rules. Please put your `@import` rules before your other rules.");
1398
+ nullifyElement(element);
1399
+ }
1400
+ };
1401
+
1402
+ var isBrowser$5 = typeof document !== 'undefined';
1403
+ var getServerStylisCache = isBrowser$5 ? undefined : weakMemoize(function () {
1404
+ return memoize$1(function () {
1405
+ var cache = {};
1406
+ return function (name) {
1407
+ return cache[name];
1408
+ };
1409
+ });
1410
+ });
1411
+ var defaultStylisPlugins = [prefixer];
1412
+
1413
+ var createCache = function createCache(options) {
1414
+ var key = options.key;
1415
+
1416
+ if (process.env.NODE_ENV !== 'production' && !key) {
1417
+ 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.");
1418
+ }
1419
+
1420
+ if (isBrowser$5 && key === 'css') {
1421
+ var ssrStyles = document.querySelectorAll("style[data-emotion]:not([data-s])"); // get SSRed styles out of the way of React's hydration
1422
+ // document.head is a safe place to move them to(though note document.head is not necessarily the last place they will be)
1423
+ // note this very very intentionally targets all style elements regardless of the key to ensure
1424
+ // that creating a cache works inside of render of a React component
1425
+
1426
+ Array.prototype.forEach.call(ssrStyles, function (node) {
1427
+ // we want to only move elements which have a space in the data-emotion attribute value
1428
+ // because that indicates that it is an Emotion 11 server-side rendered style elements
1429
+ // while we will already ignore Emotion 11 client-side inserted styles because of the :not([data-s]) part in the selector
1430
+ // Emotion 10 client-side inserted styles did not have data-s (but importantly did not have a space in their data-emotion attributes)
1431
+ // so checking for the space ensures that loading Emotion 11 after Emotion 10 has inserted some styles
1432
+ // will not result in the Emotion 10 styles being destroyed
1433
+ var dataEmotionAttribute = node.getAttribute('data-emotion');
1434
+
1435
+ if (dataEmotionAttribute.indexOf(' ') === -1) {
1436
+ return;
1437
+ }
1438
+ document.head.appendChild(node);
1439
+ node.setAttribute('data-s', '');
1440
+ });
1441
+ }
1442
+
1443
+ var stylisPlugins = options.stylisPlugins || defaultStylisPlugins;
1444
+
1445
+ if (process.env.NODE_ENV !== 'production') {
1446
+ // $FlowFixMe
1447
+ if (/[^a-z-]/.test(key)) {
1448
+ throw new Error("Emotion key must only contain lower case alphabetical characters and - but \"" + key + "\" was passed");
1449
+ }
1450
+ }
1451
+
1452
+ var inserted = {};
1453
+ var container;
1454
+ var nodesToHydrate = [];
1455
+
1456
+ if (isBrowser$5) {
1457
+ container = options.container || document.head;
1458
+ Array.prototype.forEach.call( // this means we will ignore elements which don't have a space in them which
1459
+ // means that the style elements we're looking at are only Emotion 11 server-rendered style elements
1460
+ document.querySelectorAll("style[data-emotion^=\"" + key + " \"]"), function (node) {
1461
+ var attrib = node.getAttribute("data-emotion").split(' '); // $FlowFixMe
1462
+
1463
+ for (var i = 1; i < attrib.length; i++) {
1464
+ inserted[attrib[i]] = true;
1465
+ }
1466
+
1467
+ nodesToHydrate.push(node);
1468
+ });
1469
+ }
1470
+
1471
+ var _insert;
1472
+
1473
+ var omnipresentPlugins = [compat, removeLabel];
1474
+
1475
+ if (process.env.NODE_ENV !== 'production') {
1476
+ omnipresentPlugins.push(createUnsafeSelectorsAlarm({
1477
+ get compat() {
1478
+ return cache.compat;
1479
+ }
1480
+
1481
+ }), incorrectImportAlarm);
1482
+ }
1483
+
1484
+ if (isBrowser$5) {
1485
+ var currentSheet;
1486
+ var finalizingPlugins = [stringify, process.env.NODE_ENV !== 'production' ? function (element) {
1487
+ if (!element.root) {
1488
+ if (element["return"]) {
1489
+ currentSheet.insert(element["return"]);
1490
+ } else if (element.value && element.type !== COMMENT) {
1491
+ // insert empty rule in non-production environments
1492
+ // so @emotion/jest can grab `key` from the (JS)DOM for caches without any rules inserted yet
1493
+ currentSheet.insert(element.value + "{}");
1494
+ }
1495
+ }
1496
+ } : rulesheet(function (rule) {
1497
+ currentSheet.insert(rule);
1498
+ })];
1499
+ var serializer = middleware(omnipresentPlugins.concat(stylisPlugins, finalizingPlugins));
1500
+
1501
+ var stylis = function stylis(styles) {
1502
+ return serialize(compile(styles), serializer);
1503
+ };
1504
+
1505
+ _insert = function insert(selector, serialized, sheet, shouldCache) {
1506
+ currentSheet = sheet;
1507
+
1508
+ if (process.env.NODE_ENV !== 'production' && serialized.map !== undefined) {
1509
+ currentSheet = {
1510
+ insert: function insert(rule) {
1511
+ sheet.insert(rule + serialized.map);
1512
+ }
1513
+ };
1514
+ }
1515
+
1516
+ stylis(selector ? selector + "{" + serialized.styles + "}" : serialized.styles);
1517
+
1518
+ if (shouldCache) {
1519
+ cache.inserted[serialized.name] = true;
1520
+ }
1521
+ };
1522
+ } else {
1523
+ var _finalizingPlugins = [stringify];
1524
+
1525
+ var _serializer = middleware(omnipresentPlugins.concat(stylisPlugins, _finalizingPlugins));
1526
+
1527
+ var _stylis = function _stylis(styles) {
1528
+ return serialize(compile(styles), _serializer);
1529
+ }; // $FlowFixMe
1530
+
1531
+
1532
+ var serverStylisCache = getServerStylisCache(stylisPlugins)(key);
1533
+
1534
+ var getRules = function getRules(selector, serialized) {
1535
+ var name = serialized.name;
1536
+
1537
+ if (serverStylisCache[name] === undefined) {
1538
+ serverStylisCache[name] = _stylis(selector ? selector + "{" + serialized.styles + "}" : serialized.styles);
1539
+ }
1540
+
1541
+ return serverStylisCache[name];
1542
+ };
1543
+
1544
+ _insert = function _insert(selector, serialized, sheet, shouldCache) {
1545
+ var name = serialized.name;
1546
+ var rules = getRules(selector, serialized);
1547
+
1548
+ if (cache.compat === undefined) {
1549
+ // in regular mode, we don't set the styles on the inserted cache
1550
+ // since we don't need to and that would be wasting memory
1551
+ // we return them so that they are rendered in a style tag
1552
+ if (shouldCache) {
1553
+ cache.inserted[name] = true;
1554
+ }
1555
+
1556
+ if ( // using === development instead of !== production
1557
+ // because if people do ssr in tests, the source maps showing up would be annoying
1558
+ process.env.NODE_ENV === 'development' && serialized.map !== undefined) {
1559
+ return rules + serialized.map;
1560
+ }
1561
+
1562
+ return rules;
1563
+ } else {
1564
+ // in compat mode, we put the styles on the inserted cache so
1565
+ // that emotion-server can pull out the styles
1566
+ // except when we don't want to cache it which was in Global but now
1567
+ // is nowhere but we don't want to do a major right now
1568
+ // and just in case we're going to leave the case here
1569
+ // it's also not affecting client side bundle size
1570
+ // so it's really not a big deal
1571
+ if (shouldCache) {
1572
+ cache.inserted[name] = rules;
1573
+ } else {
1574
+ return rules;
1575
+ }
1576
+ }
1577
+ };
1578
+ }
237
1579
 
238
- var reactIs$1 = {exports: {}};
1580
+ var cache = {
1581
+ key: key,
1582
+ sheet: new StyleSheet({
1583
+ key: key,
1584
+ container: container,
1585
+ nonce: options.nonce,
1586
+ speedy: options.speedy,
1587
+ prepend: options.prepend,
1588
+ insertionPoint: options.insertionPoint
1589
+ }),
1590
+ nonce: options.nonce,
1591
+ inserted: inserted,
1592
+ registered: {},
1593
+ insert: _insert
1594
+ };
1595
+ cache.sheet.hydrate(nodesToHydrate);
1596
+ return cache;
1597
+ };
1598
+
1599
+ var reactIs$2 = {exports: {}};
239
1600
 
240
1601
  var reactIs_production_min$1 = {};
241
1602
 
@@ -436,11 +1797,1263 @@ reactIs_development$1.typeOf = typeOf;
436
1797
  }
437
1798
 
438
1799
  if (process.env.NODE_ENV === 'production') {
439
- reactIs$1.exports = reactIs_production_min$1;
1800
+ reactIs$2.exports = reactIs_production_min$1;
440
1801
  } else {
441
- reactIs$1.exports = reactIs_development$1;
1802
+ reactIs$2.exports = reactIs_development$1;
1803
+ }
1804
+
1805
+ var reactIs$1 = reactIs$2.exports;
1806
+ var FORWARD_REF_STATICS = {
1807
+ '$$typeof': true,
1808
+ render: true,
1809
+ defaultProps: true,
1810
+ displayName: true,
1811
+ propTypes: true
1812
+ };
1813
+ var MEMO_STATICS = {
1814
+ '$$typeof': true,
1815
+ compare: true,
1816
+ defaultProps: true,
1817
+ displayName: true,
1818
+ propTypes: true,
1819
+ type: true
1820
+ };
1821
+ var TYPE_STATICS = {};
1822
+ TYPE_STATICS[reactIs$1.ForwardRef] = FORWARD_REF_STATICS;
1823
+ TYPE_STATICS[reactIs$1.Memo] = MEMO_STATICS;
1824
+
1825
+ var isBrowser$4 = typeof document !== 'undefined';
1826
+ function getRegisteredStyles(registered, registeredStyles, classNames) {
1827
+ var rawClassName = '';
1828
+ classNames.split(' ').forEach(function (className) {
1829
+ if (registered[className] !== undefined) {
1830
+ registeredStyles.push(registered[className] + ";");
1831
+ } else {
1832
+ rawClassName += className + " ";
1833
+ }
1834
+ });
1835
+ return rawClassName;
1836
+ }
1837
+ var registerStyles = function registerStyles(cache, serialized, isStringTag) {
1838
+ var className = cache.key + "-" + serialized.name;
1839
+
1840
+ if ( // we only need to add the styles to the registered cache if the
1841
+ // class name could be used further down
1842
+ // the tree but if it's a string tag, we know it won't
1843
+ // so we don't have to add it to registered cache.
1844
+ // this improves memory usage since we can avoid storing the whole style string
1845
+ (isStringTag === false || // we need to always store it if we're in compat mode and
1846
+ // in node since emotion-server relies on whether a style is in
1847
+ // the registered cache to know whether a style is global or not
1848
+ // also, note that this check will be dead code eliminated in the browser
1849
+ isBrowser$4 === false && cache.compat !== undefined) && cache.registered[className] === undefined) {
1850
+ cache.registered[className] = serialized.styles;
1851
+ }
1852
+ };
1853
+ var insertStyles = function insertStyles(cache, serialized, isStringTag) {
1854
+ registerStyles(cache, serialized, isStringTag);
1855
+ var className = cache.key + "-" + serialized.name;
1856
+
1857
+ if (cache.inserted[serialized.name] === undefined) {
1858
+ var stylesForSSR = '';
1859
+ var current = serialized;
1860
+
1861
+ do {
1862
+ var maybeStyles = cache.insert(serialized === current ? "." + className : '', current, cache.sheet, true);
1863
+
1864
+ if (!isBrowser$4 && maybeStyles !== undefined) {
1865
+ stylesForSSR += maybeStyles;
1866
+ }
1867
+
1868
+ current = current.next;
1869
+ } while (current !== undefined);
1870
+
1871
+ if (!isBrowser$4 && stylesForSSR.length !== 0) {
1872
+ return stylesForSSR;
1873
+ }
1874
+ }
1875
+ };
1876
+
1877
+ /* eslint-disable */
1878
+ // Inspired by https://github.com/garycourt/murmurhash-js
1879
+ // Ported from https://github.com/aappleby/smhasher/blob/61a0530f28277f2e850bfc39600ce61d02b518de/src/MurmurHash2.cpp#L37-L86
1880
+ function murmur2(str) {
1881
+ // 'm' and 'r' are mixing constants generated offline.
1882
+ // They're not really 'magic', they just happen to work well.
1883
+ // const m = 0x5bd1e995;
1884
+ // const r = 24;
1885
+ // Initialize the hash
1886
+ var h = 0; // Mix 4 bytes at a time into the hash
1887
+
1888
+ var k,
1889
+ i = 0,
1890
+ len = str.length;
1891
+
1892
+ for (; len >= 4; ++i, len -= 4) {
1893
+ k = str.charCodeAt(i) & 0xff | (str.charCodeAt(++i) & 0xff) << 8 | (str.charCodeAt(++i) & 0xff) << 16 | (str.charCodeAt(++i) & 0xff) << 24;
1894
+ k =
1895
+ /* Math.imul(k, m): */
1896
+ (k & 0xffff) * 0x5bd1e995 + ((k >>> 16) * 0xe995 << 16);
1897
+ k ^=
1898
+ /* k >>> r: */
1899
+ k >>> 24;
1900
+ h =
1901
+ /* Math.imul(k, m): */
1902
+ (k & 0xffff) * 0x5bd1e995 + ((k >>> 16) * 0xe995 << 16) ^
1903
+ /* Math.imul(h, m): */
1904
+ (h & 0xffff) * 0x5bd1e995 + ((h >>> 16) * 0xe995 << 16);
1905
+ } // Handle the last few bytes of the input array
1906
+
1907
+
1908
+ switch (len) {
1909
+ case 3:
1910
+ h ^= (str.charCodeAt(i + 2) & 0xff) << 16;
1911
+
1912
+ case 2:
1913
+ h ^= (str.charCodeAt(i + 1) & 0xff) << 8;
1914
+
1915
+ case 1:
1916
+ h ^= str.charCodeAt(i) & 0xff;
1917
+ h =
1918
+ /* Math.imul(h, m): */
1919
+ (h & 0xffff) * 0x5bd1e995 + ((h >>> 16) * 0xe995 << 16);
1920
+ } // Do a few final mixes of the hash to ensure the last few
1921
+ // bytes are well-incorporated.
1922
+
1923
+
1924
+ h ^= h >>> 13;
1925
+ h =
1926
+ /* Math.imul(h, m): */
1927
+ (h & 0xffff) * 0x5bd1e995 + ((h >>> 16) * 0xe995 << 16);
1928
+ return ((h ^ h >>> 15) >>> 0).toString(36);
1929
+ }
1930
+
1931
+ var unitlessKeys = {
1932
+ animationIterationCount: 1,
1933
+ borderImageOutset: 1,
1934
+ borderImageSlice: 1,
1935
+ borderImageWidth: 1,
1936
+ boxFlex: 1,
1937
+ boxFlexGroup: 1,
1938
+ boxOrdinalGroup: 1,
1939
+ columnCount: 1,
1940
+ columns: 1,
1941
+ flex: 1,
1942
+ flexGrow: 1,
1943
+ flexPositive: 1,
1944
+ flexShrink: 1,
1945
+ flexNegative: 1,
1946
+ flexOrder: 1,
1947
+ gridRow: 1,
1948
+ gridRowEnd: 1,
1949
+ gridRowSpan: 1,
1950
+ gridRowStart: 1,
1951
+ gridColumn: 1,
1952
+ gridColumnEnd: 1,
1953
+ gridColumnSpan: 1,
1954
+ gridColumnStart: 1,
1955
+ msGridRow: 1,
1956
+ msGridRowSpan: 1,
1957
+ msGridColumn: 1,
1958
+ msGridColumnSpan: 1,
1959
+ fontWeight: 1,
1960
+ lineHeight: 1,
1961
+ opacity: 1,
1962
+ order: 1,
1963
+ orphans: 1,
1964
+ tabSize: 1,
1965
+ widows: 1,
1966
+ zIndex: 1,
1967
+ zoom: 1,
1968
+ WebkitLineClamp: 1,
1969
+ // SVG-related properties
1970
+ fillOpacity: 1,
1971
+ floodOpacity: 1,
1972
+ stopOpacity: 1,
1973
+ strokeDasharray: 1,
1974
+ strokeDashoffset: 1,
1975
+ strokeMiterlimit: 1,
1976
+ strokeOpacity: 1,
1977
+ strokeWidth: 1
1978
+ };
1979
+
1980
+ var ILLEGAL_ESCAPE_SEQUENCE_ERROR$1 = "You have illegal escape sequence in your template literal, most likely inside content's property value.\nBecause you write your CSS inside a JavaScript string you actually have to do double escaping, so for example \"content: '\\00d7';\" should become \"content: '\\\\00d7';\".\nYou can read more about this here:\nhttps://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_literals#ES2018_revision_of_illegal_escape_sequences";
1981
+ var UNDEFINED_AS_OBJECT_KEY_ERROR = "You have passed in falsy value as style object's key (can happen when in example you pass unexported component as computed key).";
1982
+ var hyphenateRegex = /[A-Z]|^ms/g;
1983
+ var animationRegex = /_EMO_([^_]+?)_([^]*?)_EMO_/g;
1984
+
1985
+ var isCustomProperty = function isCustomProperty(property) {
1986
+ return property.charCodeAt(1) === 45;
1987
+ };
1988
+
1989
+ var isProcessableValue = function isProcessableValue(value) {
1990
+ return value != null && typeof value !== 'boolean';
1991
+ };
1992
+
1993
+ var processStyleName = /* #__PURE__ */memoize$1(function (styleName) {
1994
+ return isCustomProperty(styleName) ? styleName : styleName.replace(hyphenateRegex, '-$&').toLowerCase();
1995
+ });
1996
+
1997
+ var processStyleValue = function processStyleValue(key, value) {
1998
+ switch (key) {
1999
+ case 'animation':
2000
+ case 'animationName':
2001
+ {
2002
+ if (typeof value === 'string') {
2003
+ return value.replace(animationRegex, function (match, p1, p2) {
2004
+ cursor = {
2005
+ name: p1,
2006
+ styles: p2,
2007
+ next: cursor
2008
+ };
2009
+ return p1;
2010
+ });
2011
+ }
2012
+ }
2013
+ }
2014
+
2015
+ if (unitlessKeys[key] !== 1 && !isCustomProperty(key) && typeof value === 'number' && value !== 0) {
2016
+ return value + 'px';
2017
+ }
2018
+
2019
+ return value;
2020
+ };
2021
+
2022
+ if (process.env.NODE_ENV !== 'production') {
2023
+ var contentValuePattern = /(var|attr|counters?|url|(((repeating-)?(linear|radial))|conic)-gradient)\(|(no-)?(open|close)-quote/;
2024
+ var contentValues = ['normal', 'none', 'initial', 'inherit', 'unset'];
2025
+ var oldProcessStyleValue = processStyleValue;
2026
+ var msPattern = /^-ms-/;
2027
+ var hyphenPattern = /-(.)/g;
2028
+ var hyphenatedCache = {};
2029
+
2030
+ processStyleValue = function processStyleValue(key, value) {
2031
+ if (key === 'content') {
2032
+ if (typeof value !== 'string' || contentValues.indexOf(value) === -1 && !contentValuePattern.test(value) && (value.charAt(0) !== value.charAt(value.length - 1) || value.charAt(0) !== '"' && value.charAt(0) !== "'")) {
2033
+ throw new Error("You seem to be using a value for 'content' without quotes, try replacing it with `content: '\"" + value + "\"'`");
2034
+ }
2035
+ }
2036
+
2037
+ var processed = oldProcessStyleValue(key, value);
2038
+
2039
+ if (processed !== '' && !isCustomProperty(key) && key.indexOf('-') !== -1 && hyphenatedCache[key] === undefined) {
2040
+ hyphenatedCache[key] = true;
2041
+ console.error("Using kebab-case for css properties in objects is not supported. Did you mean " + key.replace(msPattern, 'ms-').replace(hyphenPattern, function (str, _char) {
2042
+ return _char.toUpperCase();
2043
+ }) + "?");
2044
+ }
2045
+
2046
+ return processed;
2047
+ };
442
2048
  }
443
2049
 
2050
+ var noComponentSelectorMessage = 'Component selectors can only be used in conjunction with ' + '@emotion/babel-plugin, the swc Emotion plugin, or another Emotion-aware ' + 'compiler transform.';
2051
+
2052
+ function handleInterpolation(mergedProps, registered, interpolation) {
2053
+ if (interpolation == null) {
2054
+ return '';
2055
+ }
2056
+
2057
+ if (interpolation.__emotion_styles !== undefined) {
2058
+ if (process.env.NODE_ENV !== 'production' && interpolation.toString() === 'NO_COMPONENT_SELECTOR') {
2059
+ throw new Error(noComponentSelectorMessage);
2060
+ }
2061
+
2062
+ return interpolation;
2063
+ }
2064
+
2065
+ switch (typeof interpolation) {
2066
+ case 'boolean':
2067
+ {
2068
+ return '';
2069
+ }
2070
+
2071
+ case 'object':
2072
+ {
2073
+ if (interpolation.anim === 1) {
2074
+ cursor = {
2075
+ name: interpolation.name,
2076
+ styles: interpolation.styles,
2077
+ next: cursor
2078
+ };
2079
+ return interpolation.name;
2080
+ }
2081
+
2082
+ if (interpolation.styles !== undefined) {
2083
+ var next = interpolation.next;
2084
+
2085
+ if (next !== undefined) {
2086
+ // not the most efficient thing ever but this is a pretty rare case
2087
+ // and there will be very few iterations of this generally
2088
+ while (next !== undefined) {
2089
+ cursor = {
2090
+ name: next.name,
2091
+ styles: next.styles,
2092
+ next: cursor
2093
+ };
2094
+ next = next.next;
2095
+ }
2096
+ }
2097
+
2098
+ var styles = interpolation.styles + ";";
2099
+
2100
+ if (process.env.NODE_ENV !== 'production' && interpolation.map !== undefined) {
2101
+ styles += interpolation.map;
2102
+ }
2103
+
2104
+ return styles;
2105
+ }
2106
+
2107
+ return createStringFromObject(mergedProps, registered, interpolation);
2108
+ }
2109
+
2110
+ case 'function':
2111
+ {
2112
+ if (mergedProps !== undefined) {
2113
+ var previousCursor = cursor;
2114
+ var result = interpolation(mergedProps);
2115
+ cursor = previousCursor;
2116
+ return handleInterpolation(mergedProps, registered, result);
2117
+ } else if (process.env.NODE_ENV !== 'production') {
2118
+ console.error('Functions that are interpolated in css calls will be stringified.\n' + 'If you want to have a css call based on props, create a function that returns a css call like this\n' + 'let dynamicStyle = (props) => css`color: ${props.color}`\n' + 'It can be called directly with props or interpolated in a styled call like this\n' + "let SomeComponent = styled('div')`${dynamicStyle}`");
2119
+ }
2120
+
2121
+ break;
2122
+ }
2123
+
2124
+ case 'string':
2125
+ if (process.env.NODE_ENV !== 'production') {
2126
+ var matched = [];
2127
+ var replaced = interpolation.replace(animationRegex, function (match, p1, p2) {
2128
+ var fakeVarName = "animation" + matched.length;
2129
+ matched.push("const " + fakeVarName + " = keyframes`" + p2.replace(/^@keyframes animation-\w+/, '') + "`");
2130
+ return "${" + fakeVarName + "}";
2131
+ });
2132
+
2133
+ if (matched.length) {
2134
+ console.error('`keyframes` output got interpolated into plain string, please wrap it with `css`.\n\n' + 'Instead of doing this:\n\n' + [].concat(matched, ["`" + replaced + "`"]).join('\n') + '\n\nYou should wrap it with `css` like this:\n\n' + ("css`" + replaced + "`"));
2135
+ }
2136
+ }
2137
+
2138
+ break;
2139
+ } // finalize string values (regular strings and functions interpolated into css calls)
2140
+
2141
+
2142
+ if (registered == null) {
2143
+ return interpolation;
2144
+ }
2145
+
2146
+ var cached = registered[interpolation];
2147
+ return cached !== undefined ? cached : interpolation;
2148
+ }
2149
+
2150
+ function createStringFromObject(mergedProps, registered, obj) {
2151
+ var string = '';
2152
+
2153
+ if (Array.isArray(obj)) {
2154
+ for (var i = 0; i < obj.length; i++) {
2155
+ string += handleInterpolation(mergedProps, registered, obj[i]) + ";";
2156
+ }
2157
+ } else {
2158
+ for (var _key in obj) {
2159
+ var value = obj[_key];
2160
+
2161
+ if (typeof value !== 'object') {
2162
+ if (registered != null && registered[value] !== undefined) {
2163
+ string += _key + "{" + registered[value] + "}";
2164
+ } else if (isProcessableValue(value)) {
2165
+ string += processStyleName(_key) + ":" + processStyleValue(_key, value) + ";";
2166
+ }
2167
+ } else {
2168
+ if (_key === 'NO_COMPONENT_SELECTOR' && process.env.NODE_ENV !== 'production') {
2169
+ throw new Error(noComponentSelectorMessage);
2170
+ }
2171
+
2172
+ if (Array.isArray(value) && typeof value[0] === 'string' && (registered == null || registered[value[0]] === undefined)) {
2173
+ for (var _i = 0; _i < value.length; _i++) {
2174
+ if (isProcessableValue(value[_i])) {
2175
+ string += processStyleName(_key) + ":" + processStyleValue(_key, value[_i]) + ";";
2176
+ }
2177
+ }
2178
+ } else {
2179
+ var interpolated = handleInterpolation(mergedProps, registered, value);
2180
+
2181
+ switch (_key) {
2182
+ case 'animation':
2183
+ case 'animationName':
2184
+ {
2185
+ string += processStyleName(_key) + ":" + interpolated + ";";
2186
+ break;
2187
+ }
2188
+
2189
+ default:
2190
+ {
2191
+ if (process.env.NODE_ENV !== 'production' && _key === 'undefined') {
2192
+ console.error(UNDEFINED_AS_OBJECT_KEY_ERROR);
2193
+ }
2194
+
2195
+ string += _key + "{" + interpolated + "}";
2196
+ }
2197
+ }
2198
+ }
2199
+ }
2200
+ }
2201
+ }
2202
+
2203
+ return string;
2204
+ }
2205
+
2206
+ var labelPattern = /label:\s*([^\s;\n{]+)\s*(;|$)/g;
2207
+ var sourceMapPattern;
2208
+
2209
+ if (process.env.NODE_ENV !== 'production') {
2210
+ sourceMapPattern = /\/\*#\ssourceMappingURL=data:application\/json;\S+\s+\*\//g;
2211
+ } // this is the cursor for keyframes
2212
+ // keyframes are stored on the SerializedStyles object as a linked list
2213
+
2214
+
2215
+ var cursor;
2216
+ var serializeStyles = function serializeStyles(args, registered, mergedProps) {
2217
+ if (args.length === 1 && typeof args[0] === 'object' && args[0] !== null && args[0].styles !== undefined) {
2218
+ return args[0];
2219
+ }
2220
+
2221
+ var stringMode = true;
2222
+ var styles = '';
2223
+ cursor = undefined;
2224
+ var strings = args[0];
2225
+
2226
+ if (strings == null || strings.raw === undefined) {
2227
+ stringMode = false;
2228
+ styles += handleInterpolation(mergedProps, registered, strings);
2229
+ } else {
2230
+ if (process.env.NODE_ENV !== 'production' && strings[0] === undefined) {
2231
+ console.error(ILLEGAL_ESCAPE_SEQUENCE_ERROR$1);
2232
+ }
2233
+
2234
+ styles += strings[0];
2235
+ } // we start at 1 since we've already handled the first arg
2236
+
2237
+
2238
+ for (var i = 1; i < args.length; i++) {
2239
+ styles += handleInterpolation(mergedProps, registered, args[i]);
2240
+
2241
+ if (stringMode) {
2242
+ if (process.env.NODE_ENV !== 'production' && strings[i] === undefined) {
2243
+ console.error(ILLEGAL_ESCAPE_SEQUENCE_ERROR$1);
2244
+ }
2245
+
2246
+ styles += strings[i];
2247
+ }
2248
+ }
2249
+
2250
+ var sourceMap;
2251
+
2252
+ if (process.env.NODE_ENV !== 'production') {
2253
+ styles = styles.replace(sourceMapPattern, function (match) {
2254
+ sourceMap = match;
2255
+ return '';
2256
+ });
2257
+ } // using a global regex with .exec is stateful so lastIndex has to be reset each time
2258
+
2259
+
2260
+ labelPattern.lastIndex = 0;
2261
+ var identifierName = '';
2262
+ var match; // https://esbench.com/bench/5b809c2cf2949800a0f61fb5
2263
+
2264
+ while ((match = labelPattern.exec(styles)) !== null) {
2265
+ identifierName += '-' + // $FlowFixMe we know it's not null
2266
+ match[1];
2267
+ }
2268
+
2269
+ var name = murmur2(styles) + identifierName;
2270
+
2271
+ if (process.env.NODE_ENV !== 'production') {
2272
+ // $FlowFixMe SerializedStyles type doesn't have toString property (and we don't want to add it)
2273
+ return {
2274
+ name: name,
2275
+ styles: styles,
2276
+ map: sourceMap,
2277
+ next: cursor,
2278
+ toString: function toString() {
2279
+ return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop).";
2280
+ }
2281
+ };
2282
+ }
2283
+
2284
+ return {
2285
+ name: name,
2286
+ styles: styles,
2287
+ next: cursor
2288
+ };
2289
+ };
2290
+
2291
+ var isBrowser$3 = typeof document !== 'undefined';
2292
+
2293
+ var syncFallback = function syncFallback(create) {
2294
+ return create();
2295
+ };
2296
+
2297
+ var useInsertionEffect = React__namespace['useInsertion' + 'Effect'] ? React__namespace['useInsertion' + 'Effect'] : false;
2298
+ var useInsertionEffectAlwaysWithSyncFallback = !isBrowser$3 ? syncFallback : useInsertionEffect || syncFallback;
2299
+ var useInsertionEffectWithLayoutFallback = useInsertionEffect || React.useLayoutEffect;
2300
+
2301
+ var isBrowser$2 = typeof document !== 'undefined';
2302
+ var hasOwnProperty$1 = {}.hasOwnProperty;
2303
+
2304
+ var EmotionCacheContext = /* #__PURE__ */React.createContext( // we're doing this to avoid preconstruct's dead code elimination in this one case
2305
+ // because this module is primarily intended for the browser and node
2306
+ // but it's also required in react native and similar environments sometimes
2307
+ // and we could have a special build just for that
2308
+ // but this is much easier and the native packages
2309
+ // might use a different theme context in the future anyway
2310
+ typeof HTMLElement !== 'undefined' ? /* #__PURE__ */createCache({
2311
+ key: 'css'
2312
+ }) : null);
2313
+
2314
+ if (process.env.NODE_ENV !== 'production') {
2315
+ EmotionCacheContext.displayName = 'EmotionCacheContext';
2316
+ }
2317
+
2318
+ EmotionCacheContext.Provider;
2319
+
2320
+ var withEmotionCache = function withEmotionCache(func) {
2321
+ // $FlowFixMe
2322
+ return /*#__PURE__*/React.forwardRef(function (props, ref) {
2323
+ // the cache will never be null in the browser
2324
+ var cache = React.useContext(EmotionCacheContext);
2325
+ return func(props, cache, ref);
2326
+ });
2327
+ };
2328
+
2329
+ if (!isBrowser$2) {
2330
+ withEmotionCache = function withEmotionCache(func) {
2331
+ return function (props) {
2332
+ var cache = React.useContext(EmotionCacheContext);
2333
+
2334
+ if (cache === null) {
2335
+ // yes, we're potentially creating this on every render
2336
+ // it doesn't actually matter though since it's only on the server
2337
+ // so there will only every be a single render
2338
+ // that could change in the future because of suspense and etc. but for now,
2339
+ // this works and i don't want to optimise for a future thing that we aren't sure about
2340
+ cache = createCache({
2341
+ key: 'css'
2342
+ });
2343
+ return /*#__PURE__*/React.createElement(EmotionCacheContext.Provider, {
2344
+ value: cache
2345
+ }, func(props, cache));
2346
+ } else {
2347
+ return func(props, cache);
2348
+ }
2349
+ };
2350
+ };
2351
+ }
2352
+
2353
+ var ThemeContext$2 = /* #__PURE__ */React.createContext({});
2354
+
2355
+ if (process.env.NODE_ENV !== 'production') {
2356
+ ThemeContext$2.displayName = 'EmotionThemeContext';
2357
+ }
2358
+
2359
+ var typePropName = '__EMOTION_TYPE_PLEASE_DO_NOT_USE__';
2360
+ var labelPropName = '__EMOTION_LABEL_PLEASE_DO_NOT_USE__';
2361
+
2362
+ var Insertion$2 = function Insertion(_ref) {
2363
+ var cache = _ref.cache,
2364
+ serialized = _ref.serialized,
2365
+ isStringTag = _ref.isStringTag;
2366
+ registerStyles(cache, serialized, isStringTag);
2367
+ var rules = useInsertionEffectAlwaysWithSyncFallback(function () {
2368
+ return insertStyles(cache, serialized, isStringTag);
2369
+ });
2370
+
2371
+ if (!isBrowser$2 && rules !== undefined) {
2372
+ var _ref2;
2373
+
2374
+ var serializedNames = serialized.name;
2375
+ var next = serialized.next;
2376
+
2377
+ while (next !== undefined) {
2378
+ serializedNames += ' ' + next.name;
2379
+ next = next.next;
2380
+ }
2381
+
2382
+ return /*#__PURE__*/React.createElement("style", (_ref2 = {}, _ref2["data-emotion"] = cache.key + " " + serializedNames, _ref2.dangerouslySetInnerHTML = {
2383
+ __html: rules
2384
+ }, _ref2.nonce = cache.sheet.nonce, _ref2));
2385
+ }
2386
+
2387
+ return null;
2388
+ };
2389
+
2390
+ var Emotion = /* #__PURE__ */withEmotionCache(function (props, cache, ref) {
2391
+ var cssProp = props.css; // so that using `css` from `emotion` and passing the result to the css prop works
2392
+ // not passing the registered cache to serializeStyles because it would
2393
+ // make certain babel optimisations not possible
2394
+
2395
+ if (typeof cssProp === 'string' && cache.registered[cssProp] !== undefined) {
2396
+ cssProp = cache.registered[cssProp];
2397
+ }
2398
+
2399
+ var WrappedComponent = props[typePropName];
2400
+ var registeredStyles = [cssProp];
2401
+ var className = '';
2402
+
2403
+ if (typeof props.className === 'string') {
2404
+ className = getRegisteredStyles(cache.registered, registeredStyles, props.className);
2405
+ } else if (props.className != null) {
2406
+ className = props.className + " ";
2407
+ }
2408
+
2409
+ var serialized = serializeStyles(registeredStyles, undefined, React.useContext(ThemeContext$2));
2410
+
2411
+ if (process.env.NODE_ENV !== 'production' && serialized.name.indexOf('-') === -1) {
2412
+ var labelFromStack = props[labelPropName];
2413
+
2414
+ if (labelFromStack) {
2415
+ serialized = serializeStyles([serialized, 'label:' + labelFromStack + ';']);
2416
+ }
2417
+ }
2418
+
2419
+ className += cache.key + "-" + serialized.name;
2420
+ var newProps = {};
2421
+
2422
+ for (var key in props) {
2423
+ if (hasOwnProperty$1.call(props, key) && key !== 'css' && key !== typePropName && (process.env.NODE_ENV === 'production' || key !== labelPropName)) {
2424
+ newProps[key] = props[key];
2425
+ }
2426
+ }
2427
+
2428
+ newProps.ref = ref;
2429
+ newProps.className = className;
2430
+ return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Insertion$2, {
2431
+ cache: cache,
2432
+ serialized: serialized,
2433
+ isStringTag: typeof WrappedComponent === 'string'
2434
+ }), /*#__PURE__*/React.createElement(WrappedComponent, newProps));
2435
+ });
2436
+
2437
+ if (process.env.NODE_ENV !== 'production') {
2438
+ Emotion.displayName = 'EmotionCssPropInternal';
2439
+ }
2440
+
2441
+ var pkg = {
2442
+ name: "@emotion/react",
2443
+ version: "11.10.4",
2444
+ main: "dist/emotion-react.cjs.js",
2445
+ module: "dist/emotion-react.esm.js",
2446
+ browser: {
2447
+ "./dist/emotion-react.esm.js": "./dist/emotion-react.browser.esm.js"
2448
+ },
2449
+ exports: {
2450
+ ".": {
2451
+ module: {
2452
+ worker: "./dist/emotion-react.worker.esm.js",
2453
+ browser: "./dist/emotion-react.browser.esm.js",
2454
+ "default": "./dist/emotion-react.esm.js"
2455
+ },
2456
+ "default": "./dist/emotion-react.cjs.js"
2457
+ },
2458
+ "./jsx-runtime": {
2459
+ module: {
2460
+ worker: "./jsx-runtime/dist/emotion-react-jsx-runtime.worker.esm.js",
2461
+ browser: "./jsx-runtime/dist/emotion-react-jsx-runtime.browser.esm.js",
2462
+ "default": "./jsx-runtime/dist/emotion-react-jsx-runtime.esm.js"
2463
+ },
2464
+ "default": "./jsx-runtime/dist/emotion-react-jsx-runtime.cjs.js"
2465
+ },
2466
+ "./_isolated-hnrs": {
2467
+ module: {
2468
+ worker: "./_isolated-hnrs/dist/emotion-react-_isolated-hnrs.worker.esm.js",
2469
+ browser: "./_isolated-hnrs/dist/emotion-react-_isolated-hnrs.browser.esm.js",
2470
+ "default": "./_isolated-hnrs/dist/emotion-react-_isolated-hnrs.esm.js"
2471
+ },
2472
+ "default": "./_isolated-hnrs/dist/emotion-react-_isolated-hnrs.cjs.js"
2473
+ },
2474
+ "./jsx-dev-runtime": {
2475
+ module: {
2476
+ worker: "./jsx-dev-runtime/dist/emotion-react-jsx-dev-runtime.worker.esm.js",
2477
+ browser: "./jsx-dev-runtime/dist/emotion-react-jsx-dev-runtime.browser.esm.js",
2478
+ "default": "./jsx-dev-runtime/dist/emotion-react-jsx-dev-runtime.esm.js"
2479
+ },
2480
+ "default": "./jsx-dev-runtime/dist/emotion-react-jsx-dev-runtime.cjs.js"
2481
+ },
2482
+ "./package.json": "./package.json",
2483
+ "./types/css-prop": "./types/css-prop.d.ts",
2484
+ "./macro": "./macro.js"
2485
+ },
2486
+ types: "types/index.d.ts",
2487
+ files: [
2488
+ "src",
2489
+ "dist",
2490
+ "jsx-runtime",
2491
+ "jsx-dev-runtime",
2492
+ "_isolated-hnrs",
2493
+ "types/*.d.ts",
2494
+ "macro.js",
2495
+ "macro.d.ts",
2496
+ "macro.js.flow"
2497
+ ],
2498
+ sideEffects: false,
2499
+ author: "Emotion Contributors",
2500
+ license: "MIT",
2501
+ scripts: {
2502
+ "test:typescript": "dtslint types"
2503
+ },
2504
+ dependencies: {
2505
+ "@babel/runtime": "^7.18.3",
2506
+ "@emotion/babel-plugin": "^11.10.0",
2507
+ "@emotion/cache": "^11.10.0",
2508
+ "@emotion/serialize": "^1.1.0",
2509
+ "@emotion/use-insertion-effect-with-fallbacks": "^1.0.0",
2510
+ "@emotion/utils": "^1.2.0",
2511
+ "@emotion/weak-memoize": "^0.3.0",
2512
+ "hoist-non-react-statics": "^3.3.1"
2513
+ },
2514
+ peerDependencies: {
2515
+ "@babel/core": "^7.0.0",
2516
+ react: ">=16.8.0"
2517
+ },
2518
+ peerDependenciesMeta: {
2519
+ "@babel/core": {
2520
+ optional: true
2521
+ },
2522
+ "@types/react": {
2523
+ optional: true
2524
+ }
2525
+ },
2526
+ devDependencies: {
2527
+ "@babel/core": "^7.18.5",
2528
+ "@definitelytyped/dtslint": "0.0.112",
2529
+ "@emotion/css": "11.10.0",
2530
+ "@emotion/css-prettifier": "1.1.0",
2531
+ "@emotion/server": "11.10.0",
2532
+ "@emotion/styled": "11.10.4",
2533
+ "html-tag-names": "^1.1.2",
2534
+ react: "16.14.0",
2535
+ "svg-tag-names": "^1.1.1",
2536
+ typescript: "^4.5.5"
2537
+ },
2538
+ repository: "https://github.com/emotion-js/emotion/tree/main/packages/react",
2539
+ publishConfig: {
2540
+ access: "public"
2541
+ },
2542
+ "umd:main": "dist/emotion-react.umd.min.js",
2543
+ preconstruct: {
2544
+ entrypoints: [
2545
+ "./index.js",
2546
+ "./jsx-runtime.js",
2547
+ "./jsx-dev-runtime.js",
2548
+ "./_isolated-hnrs.js"
2549
+ ],
2550
+ umdName: "emotionReact",
2551
+ exports: {
2552
+ envConditions: [
2553
+ "browser",
2554
+ "worker"
2555
+ ],
2556
+ extra: {
2557
+ "./types/css-prop": "./types/css-prop.d.ts",
2558
+ "./macro": "./macro.js"
2559
+ }
2560
+ }
2561
+ }
2562
+ };
2563
+
2564
+ var warnedAboutCssPropForGlobal = false; // maintain place over rerenders.
2565
+ // initial render from browser, insertBefore context.sheet.tags[0] or if a style hasn't been inserted there yet, appendChild
2566
+ // initial client-side render from SSR, use place of hydrating tag
2567
+
2568
+ var Global = /* #__PURE__ */withEmotionCache(function (props, cache) {
2569
+ if (process.env.NODE_ENV !== 'production' && !warnedAboutCssPropForGlobal && ( // check for className as well since the user is
2570
+ // probably using the custom createElement which
2571
+ // means it will be turned into a className prop
2572
+ // $FlowFixMe I don't really want to add it to the type since it shouldn't be used
2573
+ props.className || props.css)) {
2574
+ console.error("It looks like you're using the css prop on Global, did you mean to use the styles prop instead?");
2575
+ warnedAboutCssPropForGlobal = true;
2576
+ }
2577
+
2578
+ var styles = props.styles;
2579
+ var serialized = serializeStyles([styles], undefined, React.useContext(ThemeContext$2));
2580
+
2581
+ if (!isBrowser$2) {
2582
+ var _ref;
2583
+
2584
+ var serializedNames = serialized.name;
2585
+ var serializedStyles = serialized.styles;
2586
+ var next = serialized.next;
2587
+
2588
+ while (next !== undefined) {
2589
+ serializedNames += ' ' + next.name;
2590
+ serializedStyles += next.styles;
2591
+ next = next.next;
2592
+ }
2593
+
2594
+ var shouldCache = cache.compat === true;
2595
+ var rules = cache.insert("", {
2596
+ name: serializedNames,
2597
+ styles: serializedStyles
2598
+ }, cache.sheet, shouldCache);
2599
+
2600
+ if (shouldCache) {
2601
+ return null;
2602
+ }
2603
+
2604
+ return /*#__PURE__*/React.createElement("style", (_ref = {}, _ref["data-emotion"] = cache.key + "-global " + serializedNames, _ref.dangerouslySetInnerHTML = {
2605
+ __html: rules
2606
+ }, _ref.nonce = cache.sheet.nonce, _ref));
2607
+ } // yes, i know these hooks are used conditionally
2608
+ // but it is based on a constant that will never change at runtime
2609
+ // it's effectively like having two implementations and switching them out
2610
+ // so it's not actually breaking anything
2611
+
2612
+
2613
+ var sheetRef = React.useRef();
2614
+ useInsertionEffectWithLayoutFallback(function () {
2615
+ var key = cache.key + "-global"; // use case of https://github.com/emotion-js/emotion/issues/2675
2616
+
2617
+ var sheet = new cache.sheet.constructor({
2618
+ key: key,
2619
+ nonce: cache.sheet.nonce,
2620
+ container: cache.sheet.container,
2621
+ speedy: cache.sheet.isSpeedy
2622
+ });
2623
+ var rehydrating = false; // $FlowFixMe
2624
+
2625
+ var node = document.querySelector("style[data-emotion=\"" + key + " " + serialized.name + "\"]");
2626
+
2627
+ if (cache.sheet.tags.length) {
2628
+ sheet.before = cache.sheet.tags[0];
2629
+ }
2630
+
2631
+ if (node !== null) {
2632
+ rehydrating = true; // clear the hash so this node won't be recognizable as rehydratable by other <Global/>s
2633
+
2634
+ node.setAttribute('data-emotion', key);
2635
+ sheet.hydrate([node]);
2636
+ }
2637
+
2638
+ sheetRef.current = [sheet, rehydrating];
2639
+ return function () {
2640
+ sheet.flush();
2641
+ };
2642
+ }, [cache]);
2643
+ useInsertionEffectWithLayoutFallback(function () {
2644
+ var sheetRefCurrent = sheetRef.current;
2645
+ var sheet = sheetRefCurrent[0],
2646
+ rehydrating = sheetRefCurrent[1];
2647
+
2648
+ if (rehydrating) {
2649
+ sheetRefCurrent[1] = false;
2650
+ return;
2651
+ }
2652
+
2653
+ if (serialized.next !== undefined) {
2654
+ // insert keyframes
2655
+ insertStyles(cache, serialized.next, true);
2656
+ }
2657
+
2658
+ if (sheet.tags.length) {
2659
+ // if this doesn't exist then it will be null so the style element will be appended
2660
+ var element = sheet.tags[sheet.tags.length - 1].nextElementSibling;
2661
+ sheet.before = element;
2662
+ sheet.flush();
2663
+ }
2664
+
2665
+ cache.insert("", serialized, sheet, false);
2666
+ }, [cache, serialized.name]);
2667
+ return null;
2668
+ });
2669
+
2670
+ if (process.env.NODE_ENV !== 'production') {
2671
+ Global.displayName = 'EmotionGlobal';
2672
+ }
2673
+
2674
+ function css() {
2675
+ for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
2676
+ args[_key] = arguments[_key];
2677
+ }
2678
+
2679
+ return serializeStyles(args);
2680
+ }
2681
+
2682
+ var keyframes = function keyframes() {
2683
+ var insertable = css.apply(void 0, arguments);
2684
+ var name = "animation-" + insertable.name; // $FlowFixMe
2685
+
2686
+ return {
2687
+ name: name,
2688
+ styles: "@keyframes " + name + "{" + insertable.styles + "}",
2689
+ anim: 1,
2690
+ toString: function toString() {
2691
+ return "_EMO_" + this.name + "_" + this.styles + "_EMO_";
2692
+ }
2693
+ };
2694
+ };
2695
+
2696
+ var classnames = function classnames(args) {
2697
+ var len = args.length;
2698
+ var i = 0;
2699
+ var cls = '';
2700
+
2701
+ for (; i < len; i++) {
2702
+ var arg = args[i];
2703
+ if (arg == null) continue;
2704
+ var toAdd = void 0;
2705
+
2706
+ switch (typeof arg) {
2707
+ case 'boolean':
2708
+ break;
2709
+
2710
+ case 'object':
2711
+ {
2712
+ if (Array.isArray(arg)) {
2713
+ toAdd = classnames(arg);
2714
+ } else {
2715
+ if (process.env.NODE_ENV !== 'production' && arg.styles !== undefined && arg.name !== undefined) {
2716
+ console.error('You have passed styles created with `css` from `@emotion/react` package to the `cx`.\n' + '`cx` is meant to compose class names (strings) so you should convert those styles to a class name by passing them to the `css` received from <ClassNames/> component.');
2717
+ }
2718
+
2719
+ toAdd = '';
2720
+
2721
+ for (var k in arg) {
2722
+ if (arg[k] && k) {
2723
+ toAdd && (toAdd += ' ');
2724
+ toAdd += k;
2725
+ }
2726
+ }
2727
+ }
2728
+
2729
+ break;
2730
+ }
2731
+
2732
+ default:
2733
+ {
2734
+ toAdd = arg;
2735
+ }
2736
+ }
2737
+
2738
+ if (toAdd) {
2739
+ cls && (cls += ' ');
2740
+ cls += toAdd;
2741
+ }
2742
+ }
2743
+
2744
+ return cls;
2745
+ };
2746
+
2747
+ function merge$1(registered, css, className) {
2748
+ var registeredStyles = [];
2749
+ var rawClassName = getRegisteredStyles(registered, registeredStyles, className);
2750
+
2751
+ if (registeredStyles.length < 2) {
2752
+ return className;
2753
+ }
2754
+
2755
+ return rawClassName + css(registeredStyles);
2756
+ }
2757
+
2758
+ var Insertion$1 = function Insertion(_ref) {
2759
+ var cache = _ref.cache,
2760
+ serializedArr = _ref.serializedArr;
2761
+ var rules = useInsertionEffectAlwaysWithSyncFallback(function () {
2762
+ var rules = '';
2763
+
2764
+ for (var i = 0; i < serializedArr.length; i++) {
2765
+ var res = insertStyles(cache, serializedArr[i], false);
2766
+
2767
+ if (!isBrowser$2 && res !== undefined) {
2768
+ rules += res;
2769
+ }
2770
+ }
2771
+
2772
+ if (!isBrowser$2) {
2773
+ return rules;
2774
+ }
2775
+ });
2776
+
2777
+ if (!isBrowser$2 && rules.length !== 0) {
2778
+ var _ref2;
2779
+
2780
+ return /*#__PURE__*/React.createElement("style", (_ref2 = {}, _ref2["data-emotion"] = cache.key + " " + serializedArr.map(function (serialized) {
2781
+ return serialized.name;
2782
+ }).join(' '), _ref2.dangerouslySetInnerHTML = {
2783
+ __html: rules
2784
+ }, _ref2.nonce = cache.sheet.nonce, _ref2));
2785
+ }
2786
+
2787
+ return null;
2788
+ };
2789
+
2790
+ var ClassNames = /* #__PURE__ */withEmotionCache(function (props, cache) {
2791
+ var hasRendered = false;
2792
+ var serializedArr = [];
2793
+
2794
+ var css = function css() {
2795
+ if (hasRendered && process.env.NODE_ENV !== 'production') {
2796
+ throw new Error('css can only be used during render');
2797
+ }
2798
+
2799
+ for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
2800
+ args[_key] = arguments[_key];
2801
+ }
2802
+
2803
+ var serialized = serializeStyles(args, cache.registered);
2804
+ serializedArr.push(serialized); // registration has to happen here as the result of this might get consumed by `cx`
2805
+
2806
+ registerStyles(cache, serialized, false);
2807
+ return cache.key + "-" + serialized.name;
2808
+ };
2809
+
2810
+ var cx = function cx() {
2811
+ if (hasRendered && process.env.NODE_ENV !== 'production') {
2812
+ throw new Error('cx can only be used during render');
2813
+ }
2814
+
2815
+ for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
2816
+ args[_key2] = arguments[_key2];
2817
+ }
2818
+
2819
+ return merge$1(cache.registered, css, classnames(args));
2820
+ };
2821
+
2822
+ var content = {
2823
+ css: css,
2824
+ cx: cx,
2825
+ theme: React.useContext(ThemeContext$2)
2826
+ };
2827
+ var ele = props.children(content);
2828
+ hasRendered = true;
2829
+ return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Insertion$1, {
2830
+ cache: cache,
2831
+ serializedArr: serializedArr
2832
+ }), ele);
2833
+ });
2834
+
2835
+ if (process.env.NODE_ENV !== 'production') {
2836
+ ClassNames.displayName = 'EmotionClassNames';
2837
+ }
2838
+
2839
+ if (process.env.NODE_ENV !== 'production') {
2840
+ var isBrowser$1 = typeof document !== 'undefined'; // #1727 for some reason Jest evaluates modules twice if some consuming module gets mocked with jest.mock
2841
+
2842
+ var isJest = typeof jest !== 'undefined';
2843
+
2844
+ if (isBrowser$1 && !isJest) {
2845
+ // globalThis has wide browser support - https://caniuse.com/?search=globalThis, Node.js 12 and later
2846
+ var globalContext = // $FlowIgnore
2847
+ typeof globalThis !== 'undefined' ? globalThis // eslint-disable-line no-undef
2848
+ : isBrowser$1 ? window : global;
2849
+ var globalKey = "__EMOTION_REACT_" + pkg.version.split('.')[0] + "__";
2850
+
2851
+ if (globalContext[globalKey]) {
2852
+ console.warn('You are loading @emotion/react when it is already loaded. Running ' + 'multiple instances may cause problems. This can happen if multiple ' + 'versions are used, or if multiple builds of the same version are ' + 'used.');
2853
+ }
2854
+
2855
+ globalContext[globalKey] = true;
2856
+ }
2857
+ }
2858
+
2859
+ var testOmitPropsOnStringTag = isPropValid;
2860
+
2861
+ var testOmitPropsOnComponent = function testOmitPropsOnComponent(key) {
2862
+ return key !== 'theme';
2863
+ };
2864
+
2865
+ var getDefaultShouldForwardProp = function getDefaultShouldForwardProp(tag) {
2866
+ return typeof tag === 'string' && // 96 is one less than the char code
2867
+ // for "a" so this is checking that
2868
+ // it's a lowercase character
2869
+ tag.charCodeAt(0) > 96 ? testOmitPropsOnStringTag : testOmitPropsOnComponent;
2870
+ };
2871
+ var composeShouldForwardProps = function composeShouldForwardProps(tag, options, isReal) {
2872
+ var shouldForwardProp;
2873
+
2874
+ if (options) {
2875
+ var optionsShouldForwardProp = options.shouldForwardProp;
2876
+ shouldForwardProp = tag.__emotion_forwardProp && optionsShouldForwardProp ? function (propName) {
2877
+ return tag.__emotion_forwardProp(propName) && optionsShouldForwardProp(propName);
2878
+ } : optionsShouldForwardProp;
2879
+ }
2880
+
2881
+ if (typeof shouldForwardProp !== 'function' && isReal) {
2882
+ shouldForwardProp = tag.__emotion_forwardProp;
2883
+ }
2884
+
2885
+ return shouldForwardProp;
2886
+ };
2887
+
2888
+ var ILLEGAL_ESCAPE_SEQUENCE_ERROR = "You have illegal escape sequence in your template literal, most likely inside content's property value.\nBecause you write your CSS inside a JavaScript string you actually have to do double escaping, so for example \"content: '\\00d7';\" should become \"content: '\\\\00d7';\".\nYou can read more about this here:\nhttps://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_literals#ES2018_revision_of_illegal_escape_sequences";
2889
+ var isBrowser = typeof document !== 'undefined';
2890
+
2891
+ var Insertion = function Insertion(_ref) {
2892
+ var cache = _ref.cache,
2893
+ serialized = _ref.serialized,
2894
+ isStringTag = _ref.isStringTag;
2895
+ registerStyles(cache, serialized, isStringTag);
2896
+ var rules = useInsertionEffectAlwaysWithSyncFallback(function () {
2897
+ return insertStyles(cache, serialized, isStringTag);
2898
+ });
2899
+
2900
+ if (!isBrowser && rules !== undefined) {
2901
+ var _ref2;
2902
+
2903
+ var serializedNames = serialized.name;
2904
+ var next = serialized.next;
2905
+
2906
+ while (next !== undefined) {
2907
+ serializedNames += ' ' + next.name;
2908
+ next = next.next;
2909
+ }
2910
+
2911
+ return /*#__PURE__*/React.createElement("style", (_ref2 = {}, _ref2["data-emotion"] = cache.key + " " + serializedNames, _ref2.dangerouslySetInnerHTML = {
2912
+ __html: rules
2913
+ }, _ref2.nonce = cache.sheet.nonce, _ref2));
2914
+ }
2915
+
2916
+ return null;
2917
+ };
2918
+
2919
+ var createStyled$1 = function createStyled(tag, options) {
2920
+ if (process.env.NODE_ENV !== 'production') {
2921
+ if (tag === undefined) {
2922
+ throw new Error('You are trying to create a styled element with an undefined component.\nYou may have forgotten to import it.');
2923
+ }
2924
+ }
2925
+
2926
+ var isReal = tag.__emotion_real === tag;
2927
+ var baseTag = isReal && tag.__emotion_base || tag;
2928
+ var identifierName;
2929
+ var targetClassName;
2930
+
2931
+ if (options !== undefined) {
2932
+ identifierName = options.label;
2933
+ targetClassName = options.target;
2934
+ }
2935
+
2936
+ var shouldForwardProp = composeShouldForwardProps(tag, options, isReal);
2937
+ var defaultShouldForwardProp = shouldForwardProp || getDefaultShouldForwardProp(baseTag);
2938
+ var shouldUseAs = !defaultShouldForwardProp('as');
2939
+ return function () {
2940
+ var args = arguments;
2941
+ var styles = isReal && tag.__emotion_styles !== undefined ? tag.__emotion_styles.slice(0) : [];
2942
+
2943
+ if (identifierName !== undefined) {
2944
+ styles.push("label:" + identifierName + ";");
2945
+ }
2946
+
2947
+ if (args[0] == null || args[0].raw === undefined) {
2948
+ styles.push.apply(styles, args);
2949
+ } else {
2950
+ if (process.env.NODE_ENV !== 'production' && args[0][0] === undefined) {
2951
+ console.error(ILLEGAL_ESCAPE_SEQUENCE_ERROR);
2952
+ }
2953
+
2954
+ styles.push(args[0][0]);
2955
+ var len = args.length;
2956
+ var i = 1;
2957
+
2958
+ for (; i < len; i++) {
2959
+ if (process.env.NODE_ENV !== 'production' && args[0][i] === undefined) {
2960
+ console.error(ILLEGAL_ESCAPE_SEQUENCE_ERROR);
2961
+ }
2962
+
2963
+ styles.push(args[i], args[0][i]);
2964
+ }
2965
+ } // $FlowFixMe: we need to cast StatelessFunctionalComponent to our PrivateStyledComponent class
2966
+
2967
+
2968
+ var Styled = withEmotionCache(function (props, cache, ref) {
2969
+ var FinalTag = shouldUseAs && props.as || baseTag;
2970
+ var className = '';
2971
+ var classInterpolations = [];
2972
+ var mergedProps = props;
2973
+
2974
+ if (props.theme == null) {
2975
+ mergedProps = {};
2976
+
2977
+ for (var key in props) {
2978
+ mergedProps[key] = props[key];
2979
+ }
2980
+
2981
+ mergedProps.theme = React.useContext(ThemeContext$2);
2982
+ }
2983
+
2984
+ if (typeof props.className === 'string') {
2985
+ className = getRegisteredStyles(cache.registered, classInterpolations, props.className);
2986
+ } else if (props.className != null) {
2987
+ className = props.className + " ";
2988
+ }
2989
+
2990
+ var serialized = serializeStyles(styles.concat(classInterpolations), cache.registered, mergedProps);
2991
+ className += cache.key + "-" + serialized.name;
2992
+
2993
+ if (targetClassName !== undefined) {
2994
+ className += " " + targetClassName;
2995
+ }
2996
+
2997
+ var finalShouldForwardProp = shouldUseAs && shouldForwardProp === undefined ? getDefaultShouldForwardProp(FinalTag) : defaultShouldForwardProp;
2998
+ var newProps = {};
2999
+
3000
+ for (var _key in props) {
3001
+ if (shouldUseAs && _key === 'as') continue;
3002
+
3003
+ if ( // $FlowFixMe
3004
+ finalShouldForwardProp(_key)) {
3005
+ newProps[_key] = props[_key];
3006
+ }
3007
+ }
3008
+
3009
+ newProps.className = className;
3010
+ newProps.ref = ref;
3011
+ return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Insertion, {
3012
+ cache: cache,
3013
+ serialized: serialized,
3014
+ isStringTag: typeof FinalTag === 'string'
3015
+ }), /*#__PURE__*/React.createElement(FinalTag, newProps));
3016
+ });
3017
+ Styled.displayName = identifierName !== undefined ? identifierName : "Styled(" + (typeof baseTag === 'string' ? baseTag : baseTag.displayName || baseTag.name || 'Component') + ")";
3018
+ Styled.defaultProps = tag.defaultProps;
3019
+ Styled.__emotion_real = Styled;
3020
+ Styled.__emotion_base = baseTag;
3021
+ Styled.__emotion_styles = styles;
3022
+ Styled.__emotion_forwardProp = shouldForwardProp;
3023
+ Object.defineProperty(Styled, 'toString', {
3024
+ value: function value() {
3025
+ if (targetClassName === undefined && process.env.NODE_ENV !== 'production') {
3026
+ return 'NO_COMPONENT_SELECTOR';
3027
+ } // $FlowFixMe: coerce undefined to string
3028
+
3029
+
3030
+ return "." + targetClassName;
3031
+ }
3032
+ });
3033
+
3034
+ Styled.withComponent = function (nextTag, nextOptions) {
3035
+ return createStyled(nextTag, _extends({}, options, nextOptions, {
3036
+ shouldForwardProp: composeShouldForwardProps(Styled, nextOptions, true)
3037
+ })).apply(void 0, styles);
3038
+ };
3039
+
3040
+ return Styled;
3041
+ };
3042
+ };
3043
+
3044
+ var tags = ['a', 'abbr', 'address', 'area', 'article', 'aside', 'audio', 'b', 'base', 'bdi', 'bdo', 'big', 'blockquote', 'body', 'br', 'button', 'canvas', 'caption', 'cite', 'code', 'col', 'colgroup', 'data', 'datalist', 'dd', 'del', 'details', 'dfn', 'dialog', 'div', 'dl', 'dt', 'em', 'embed', 'fieldset', 'figcaption', 'figure', 'footer', 'form', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6', 'head', 'header', 'hgroup', 'hr', 'html', 'i', 'iframe', 'img', 'input', 'ins', 'kbd', 'keygen', 'label', 'legend', 'li', 'link', 'main', 'map', 'mark', 'marquee', 'menu', 'menuitem', 'meta', 'meter', 'nav', 'noscript', 'object', 'ol', 'optgroup', 'option', 'output', 'p', 'param', 'picture', 'pre', 'progress', 'q', 'rp', 'rt', 'ruby', 's', 'samp', 'script', 'section', 'select', 'small', 'source', 'span', 'strong', 'style', 'sub', 'summary', 'sup', 'table', 'tbody', 'td', 'textarea', 'tfoot', 'th', 'thead', 'time', 'title', 'tr', 'track', 'u', 'ul', 'var', 'video', 'wbr', // SVG
3045
+ 'circle', 'clipPath', 'defs', 'ellipse', 'foreignObject', 'g', 'image', 'line', 'linearGradient', 'mask', 'path', 'pattern', 'polygon', 'polyline', 'radialGradient', 'rect', 'stop', 'svg', 'text', 'tspan'];
3046
+
3047
+ var newStyled = createStyled$1.bind();
3048
+ tags.forEach(function (tagName) {
3049
+ // $FlowFixMe: we can ignore this because its exposed type is defined by the CreateStyled type
3050
+ newStyled[tagName] = newStyled(tagName);
3051
+ });
3052
+
3053
+ var emStyled = newStyled;
3054
+
3055
+ var propTypes = {exports: {}};
3056
+
444
3057
  /*
445
3058
  object-assign
446
3059
  (c) Sindre Sorhus
@@ -652,7 +3265,7 @@ var checkPropTypes_1 = checkPropTypes$1;
652
3265
  * LICENSE file in the root directory of this source tree.
653
3266
  */
654
3267
 
655
- var ReactIs$1 = reactIs$1.exports;
3268
+ var ReactIs$1 = reactIs$2.exports;
656
3269
  var assign = objectAssign;
657
3270
 
658
3271
  var ReactPropTypesSecret$1 = ReactPropTypesSecret_1;
@@ -1324,7 +3937,7 @@ var factoryWithThrowingShims = function() {
1324
3937
  */
1325
3938
 
1326
3939
  if (process.env.NODE_ENV !== 'production') {
1327
- var ReactIs = reactIs$1.exports;
3940
+ var ReactIs = reactIs$2.exports;
1328
3941
 
1329
3942
  // By explicitly using `prop-types` you are opting into new development behavior.
1330
3943
  // http://fb.me/prop-types-in-prod
@@ -1348,7 +3961,7 @@ function GlobalStyles$1(props) {
1348
3961
  defaultTheme = {}
1349
3962
  } = props;
1350
3963
  const globalStyles = typeof styles === 'function' ? themeInput => styles(isEmpty$4(themeInput) ? defaultTheme : themeInput) : styles;
1351
- return /*#__PURE__*/jsxRuntime.jsx(react.Global, {
3964
+ return /*#__PURE__*/jsxRuntime.jsx(Global, {
1352
3965
  styles: globalStyles
1353
3966
  });
1354
3967
  }
@@ -1363,7 +3976,7 @@ process.env.NODE_ENV !== "production" ? GlobalStyles$1.propTypes = {
1363
3976
  * LICENSE file in the root directory of this source tree.
1364
3977
  */
1365
3978
  function styled$2(tag, options) {
1366
- const stylesFactory = emStyled__default["default"](tag, options);
3979
+ const stylesFactory = emStyled(tag, options);
1367
3980
 
1368
3981
  if (process.env.NODE_ENV !== 'production') {
1369
3982
  return (...styles) => {
@@ -4181,7 +6794,7 @@ function lighten(color, coefficient) {
4181
6794
 
4182
6795
  function InnerThemeProvider(props) {
4183
6796
  const theme = useTheme$1();
4184
- return /*#__PURE__*/jsxRuntime.jsx(react.ThemeContext.Provider, {
6797
+ return /*#__PURE__*/jsxRuntime.jsx(ThemeContext$2.Provider, {
4185
6798
  value: typeof theme === 'object' ? theme : {},
4186
6799
  children: props.children
4187
6800
  });
@@ -39565,7 +42178,7 @@ let _ = t => t,
39565
42178
  _t4;
39566
42179
  const DURATION = 550;
39567
42180
  const DELAY_RIPPLE = 80;
39568
- const enterKeyframe = react.keyframes(_t || (_t = _`
42181
+ const enterKeyframe = keyframes(_t || (_t = _`
39569
42182
  0% {
39570
42183
  transform: scale(0);
39571
42184
  opacity: 0.1;
@@ -39576,7 +42189,7 @@ const enterKeyframe = react.keyframes(_t || (_t = _`
39576
42189
  opacity: 0.3;
39577
42190
  }
39578
42191
  `));
39579
- const exitKeyframe = react.keyframes(_t2 || (_t2 = _`
42192
+ const exitKeyframe = keyframes(_t2 || (_t2 = _`
39580
42193
  0% {
39581
42194
  opacity: 1;
39582
42195
  }
@@ -39585,7 +42198,7 @@ const exitKeyframe = react.keyframes(_t2 || (_t2 = _`
39585
42198
  opacity: 0;
39586
42199
  }
39587
42200
  `));
39588
- const pulsateKeyframe = react.keyframes(_t3 || (_t3 = _`
42201
+ const pulsateKeyframe = keyframes(_t3 || (_t3 = _`
39589
42202
  0% {
39590
42203
  transform: scale(1);
39591
42204
  }