@bolttech/atoms-date-input 0.1.0 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,5 +1,18 @@
1
- import { jsxs, jsx } from 'react/jsx-runtime';
2
- import r, { useRef, useDebugValue, createElement as createElement$1, useContext, forwardRef, useReducer, useEffect } from 'react';
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var jsxRuntime = require('react/jsx-runtime');
6
+ var react = require('react');
7
+ var styled = require('styled-components');
8
+ var uiUtils = require('@bolttech/ui-utils');
9
+ var reactDom = require('react-dom');
10
+ var moleculesCalendar = require('@bolttech/molecules-calendar');
11
+ var atomsIcon = require('@bolttech/atoms-icon');
12
+
13
+ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
14
+
15
+ var styled__default = /*#__PURE__*/_interopDefaultLegacy(styled);
3
16
 
4
17
  var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
5
18
 
@@ -87,7 +100,7 @@ var check = function (it) {
87
100
  };
88
101
 
89
102
  // https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
90
- var global$b =
103
+ var globalThis_1 =
91
104
  // eslint-disable-next-line es/no-global-this -- safe
92
105
  check(typeof globalThis == 'object' && globalThis) ||
93
106
  check(typeof window == 'object' && window) ||
@@ -100,30 +113,30 @@ var global$b =
100
113
 
101
114
  var sharedStore = {exports: {}};
102
115
 
103
- var global$a = global$b;
116
+ var globalThis$c = globalThis_1;
104
117
 
105
118
  // eslint-disable-next-line es/no-object-defineproperty -- safe
106
119
  var defineProperty$5 = Object.defineProperty;
107
120
 
108
121
  var defineGlobalProperty$3 = function (key, value) {
109
122
  try {
110
- defineProperty$5(global$a, key, { value: value, configurable: true, writable: true });
123
+ defineProperty$5(globalThis$c, key, { value: value, configurable: true, writable: true });
111
124
  } catch (error) {
112
- global$a[key] = value;
125
+ globalThis$c[key] = value;
113
126
  } return value;
114
127
  };
115
128
 
116
- var globalThis$1 = global$b;
129
+ var globalThis$b = globalThis_1;
117
130
  var defineGlobalProperty$2 = defineGlobalProperty$3;
118
131
 
119
132
  var SHARED = '__core-js_shared__';
120
- var store$3 = sharedStore.exports = globalThis$1[SHARED] || defineGlobalProperty$2(SHARED, {});
133
+ var store$3 = sharedStore.exports = globalThis$b[SHARED] || defineGlobalProperty$2(SHARED, {});
121
134
 
122
135
  (store$3.versions || (store$3.versions = [])).push({
123
- version: '3.37.1',
136
+ version: '3.39.0',
124
137
  mode: 'global',
125
138
  copyright: '© 2014-2024 Denis Pushkarev (zloirock.ru)',
126
- license: 'https://github.com/zloirock/core-js/blob/v3.37.1/LICENSE',
139
+ license: 'https://github.com/zloirock/core-js/blob/v3.39.0/LICENSE',
127
140
  source: 'https://github.com/zloirock/core-js'
128
141
  });
129
142
 
@@ -165,42 +178,47 @@ var uid$2 = function (key) {
165
178
  return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString(++id + postfix, 36);
166
179
  };
167
180
 
168
- var engineUserAgent = typeof navigator != 'undefined' && String(navigator.userAgent) || '';
181
+ var globalThis$a = globalThis_1;
169
182
 
170
- var global$9 = global$b;
171
- var userAgent = engineUserAgent;
183
+ var navigator = globalThis$a.navigator;
184
+ var userAgent$1 = navigator && navigator.userAgent;
172
185
 
173
- var process$1 = global$9.process;
174
- var Deno = global$9.Deno;
175
- var versions = process$1 && process$1.versions || Deno && Deno.version;
186
+ var environmentUserAgent = userAgent$1 ? String(userAgent$1) : '';
187
+
188
+ var globalThis$9 = globalThis_1;
189
+ var userAgent = environmentUserAgent;
190
+
191
+ var process = globalThis$9.process;
192
+ var Deno = globalThis$9.Deno;
193
+ var versions = process && process.versions || Deno && Deno.version;
176
194
  var v8 = versions && versions.v8;
177
- var match$1, version;
195
+ var match, version;
178
196
 
179
197
  if (v8) {
180
- match$1 = v8.split('.');
198
+ match = v8.split('.');
181
199
  // in old Chrome, versions of V8 isn't V8 = Chrome / 10
182
200
  // but their correct versions are not interesting for us
183
- version = match$1[0] > 0 && match$1[0] < 4 ? 1 : +(match$1[0] + match$1[1]);
201
+ version = match[0] > 0 && match[0] < 4 ? 1 : +(match[0] + match[1]);
184
202
  }
185
203
 
186
204
  // BrowserFS NodeJS `process` polyfill incorrectly set `.v8` to `0.0`
187
205
  // so check `userAgent` even if `.v8` exists, but 0
188
206
  if (!version && userAgent) {
189
- match$1 = userAgent.match(/Edge\/(\d+)/);
190
- if (!match$1 || match$1[1] >= 74) {
191
- match$1 = userAgent.match(/Chrome\/(\d+)/);
192
- if (match$1) version = +match$1[1];
207
+ match = userAgent.match(/Edge\/(\d+)/);
208
+ if (!match || match[1] >= 74) {
209
+ match = userAgent.match(/Chrome\/(\d+)/);
210
+ if (match) version = +match[1];
193
211
  }
194
212
  }
195
213
 
196
- var engineV8Version = version;
214
+ var environmentV8Version = version;
197
215
 
198
216
  /* eslint-disable es/no-symbol -- required for testing */
199
- var V8_VERSION = engineV8Version;
217
+ var V8_VERSION = environmentV8Version;
200
218
  var fails$8 = fails$b;
201
- var global$8 = global$b;
219
+ var globalThis$8 = globalThis_1;
202
220
 
203
- var $String$4 = global$8.String;
221
+ var $String$4 = globalThis$8.String;
204
222
 
205
223
  // eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing
206
224
  var symbolConstructorDetection = !!Object.getOwnPropertySymbols && !fails$8(function () {
@@ -217,18 +235,18 @@ var symbolConstructorDetection = !!Object.getOwnPropertySymbols && !fails$8(func
217
235
  /* eslint-disable es/no-symbol -- required for testing */
218
236
  var NATIVE_SYMBOL$1 = symbolConstructorDetection;
219
237
 
220
- var useSymbolAsUid = NATIVE_SYMBOL$1
221
- && !Symbol.sham
222
- && typeof Symbol.iterator == 'symbol';
238
+ var useSymbolAsUid = NATIVE_SYMBOL$1 &&
239
+ !Symbol.sham &&
240
+ typeof Symbol.iterator == 'symbol';
223
241
 
224
- var global$7 = global$b;
242
+ var globalThis$7 = globalThis_1;
225
243
  var shared$2 = shared$3;
226
244
  var hasOwn$8 = hasOwnProperty_1;
227
245
  var uid$1 = uid$2;
228
246
  var NATIVE_SYMBOL = symbolConstructorDetection;
229
247
  var USE_SYMBOL_AS_UID$1 = useSymbolAsUid;
230
248
 
231
- var Symbol$1 = global$7.Symbol;
249
+ var Symbol$1 = globalThis$7.Symbol;
232
250
  var WellKnownSymbolsStore = shared$2('wks');
233
251
  var createWellKnownSymbol = USE_SYMBOL_AS_UID$1 ? Symbol$1['for'] || Symbol$1 : Symbol$1 && Symbol$1.withoutSetter || uid$1;
234
252
 
@@ -294,10 +312,10 @@ var v8PrototypeDefineBug = DESCRIPTORS$9 && fails$6(function () {
294
312
 
295
313
  var objectDefineProperty = {};
296
314
 
297
- var global$6 = global$b;
315
+ var globalThis$6 = globalThis_1;
298
316
  var isObject$6 = isObject$8;
299
317
 
300
- var document$1 = global$6.document;
318
+ var document$1 = globalThis$6.document;
301
319
  // typeof document.createElement is 'object' in old IE
302
320
  var EXISTS$1 = isObject$6(document$1) && isObject$6(document$1.createElement);
303
321
 
@@ -325,7 +343,7 @@ var functionCall = NATIVE_BIND ? call$5.bind(call$5) : function () {
325
343
  return call$5.apply(call$5, arguments);
326
344
  };
327
345
 
328
- var global$5 = global$b;
346
+ var globalThis$5 = globalThis_1;
329
347
  var isCallable$b = isCallable$d;
330
348
 
331
349
  var aFunction = function (argument) {
@@ -333,7 +351,7 @@ var aFunction = function (argument) {
333
351
  };
334
352
 
335
353
  var getBuiltIn$3 = function (namespace, method) {
336
- return arguments.length < 2 ? aFunction(global$5[namespace]) : global$5[namespace] && global$5[namespace][method];
354
+ return arguments.length < 2 ? aFunction(globalThis$5[namespace]) : globalThis$5[namespace] && globalThis$5[namespace][method];
337
355
  };
338
356
 
339
357
  var uncurryThis$6 = functionUncurryThis;
@@ -672,7 +690,8 @@ var NullProtoObjectViaActiveX = function (activeXDocument) {
672
690
  activeXDocument.write(scriptTag(''));
673
691
  activeXDocument.close();
674
692
  var temp = activeXDocument.parentWindow.Object;
675
- activeXDocument = null; // avoid memory leak
693
+ // eslint-disable-next-line no-useless-assignment -- avoid memory leak
694
+ activeXDocument = null;
676
695
  return temp;
677
696
  };
678
697
 
@@ -753,10 +772,10 @@ var addToUnscopables$1 = function (key) {
753
772
 
754
773
  var iterators = {};
755
774
 
756
- var global$4 = global$b;
775
+ var globalThis$4 = globalThis_1;
757
776
  var isCallable$7 = isCallable$d;
758
777
 
759
- var WeakMap$1 = global$4.WeakMap;
778
+ var WeakMap$1 = globalThis$4.WeakMap;
760
779
 
761
780
  var weakMapBasicDetection = isCallable$7(WeakMap$1) && /native code/.test(String(WeakMap$1));
762
781
 
@@ -781,7 +800,7 @@ var createNonEnumerableProperty$4 = DESCRIPTORS$5 ? function (object, key, value
781
800
  };
782
801
 
783
802
  var NATIVE_WEAK_MAP = weakMapBasicDetection;
784
- var global$3 = global$b;
803
+ var globalThis$3 = globalThis_1;
785
804
  var isObject$3 = isObject$8;
786
805
  var createNonEnumerableProperty$3 = createNonEnumerableProperty$4;
787
806
  var hasOwn$6 = hasOwnProperty_1;
@@ -790,8 +809,8 @@ var sharedKey$1 = sharedKey$3;
790
809
  var hiddenKeys$1 = hiddenKeys$4;
791
810
 
792
811
  var OBJECT_ALREADY_INITIALIZED = 'Object already initialized';
793
- var TypeError$1 = global$3.TypeError;
794
- var WeakMap = global$3.WeakMap;
812
+ var TypeError$1 = globalThis$3.TypeError;
813
+ var WeakMap = globalThis$3.WeakMap;
795
814
  var set, get, has;
796
815
 
797
816
  var enforce = function (it) {
@@ -942,7 +961,7 @@ var $String$1 = String;
942
961
  // eslint-disable-next-line es/no-object-defineproperty -- safe
943
962
  var defineProperty$3 = Object.defineProperty;
944
963
  var stringSlice = uncurryThis$3(''.slice);
945
- var replace$1 = uncurryThis$3(''.replace);
964
+ var replace = uncurryThis$3(''.replace);
946
965
  var join = uncurryThis$3([].join);
947
966
 
948
967
  var CONFIGURABLE_LENGTH = DESCRIPTORS$2 && !fails$4(function () {
@@ -953,7 +972,7 @@ var TEMPLATE = String(String).split('String');
953
972
 
954
973
  var makeBuiltIn$1 = makeBuiltIn$2.exports = function (value, name, options) {
955
974
  if (stringSlice($String$1(name), 0, 7) === 'Symbol(') {
956
- name = '[' + replace$1($String$1(name), /^Symbol\(([^)]*)\).*$/, '$1') + ']';
975
+ name = '[' + replace($String$1(name), /^Symbol\(([^)]*)\).*$/, '$1') + ']';
957
976
  }
958
977
  if (options && options.getter) name = 'get ' + name;
959
978
  if (options && options.setter) name = 'set ' + name;
@@ -1084,7 +1103,7 @@ var POLYFILL = isForced$1.POLYFILL = 'P';
1084
1103
 
1085
1104
  var isForced_1 = isForced$1;
1086
1105
 
1087
- var global$2 = global$b;
1106
+ var globalThis$2 = globalThis_1;
1088
1107
  var getOwnPropertyDescriptor = objectGetOwnPropertyDescriptor.f;
1089
1108
  var createNonEnumerableProperty$2 = createNonEnumerableProperty$4;
1090
1109
  var defineBuiltIn$2 = defineBuiltIn$3;
@@ -1113,11 +1132,11 @@ var _export = function (options, source) {
1113
1132
  var STATIC = options.stat;
1114
1133
  var FORCED, target, key, targetProperty, sourceProperty, descriptor;
1115
1134
  if (GLOBAL) {
1116
- target = global$2;
1135
+ target = globalThis$2;
1117
1136
  } else if (STATIC) {
1118
- target = global$2[TARGET] || defineGlobalProperty(TARGET, {});
1137
+ target = globalThis$2[TARGET] || defineGlobalProperty(TARGET, {});
1119
1138
  } else {
1120
- target = global$2[TARGET] && global$2[TARGET].prototype;
1139
+ target = globalThis$2[TARGET] && globalThis$2[TARGET].prototype;
1121
1140
  }
1122
1141
  if (target) for (key in source) {
1123
1142
  sourceProperty = source[key];
@@ -1300,7 +1319,7 @@ var objectSetPrototypeOf = Object.setPrototypeOf || ('__proto__' in {} ? functio
1300
1319
  };
1301
1320
  }() : undefined);
1302
1321
 
1303
- var $$2 = _export;
1322
+ var $$1 = _export;
1304
1323
  var call$1 = functionCall;
1305
1324
  var FunctionName = functionName;
1306
1325
  var isCallable = isCallable$d;
@@ -1388,7 +1407,7 @@ var iteratorDefine = function (Iterable, NAME, IteratorConstructor, next, DEFAUL
1388
1407
  if (BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME || !(KEY in IterablePrototype)) {
1389
1408
  defineBuiltIn(IterablePrototype, KEY, methods[KEY]);
1390
1409
  }
1391
- } else $$2({ target: NAME, proto: true, forced: BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME }, methods);
1410
+ } else $$1({ target: NAME, proto: true, forced: BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME }, methods);
1392
1411
  }
1393
1412
 
1394
1413
  // define iterator
@@ -1443,7 +1462,7 @@ var es_array_iterator = defineIterator(Array, 'Array', function (iterated, kind)
1443
1462
  var target = state.target;
1444
1463
  var index = state.index++;
1445
1464
  if (!target || index >= target.length) {
1446
- state.target = undefined;
1465
+ state.target = null;
1447
1466
  return createIterResultObject(undefined, true);
1448
1467
  }
1449
1468
  switch (state.kind) {
@@ -1524,14 +1543,14 @@ var objectAssign = !$assign || fails(function () {
1524
1543
  } return T;
1525
1544
  } : $assign;
1526
1545
 
1527
- var $$1 = _export;
1528
- var assign$1 = objectAssign;
1546
+ var $ = _export;
1547
+ var assign = objectAssign;
1529
1548
 
1530
1549
  // `Object.assign` method
1531
1550
  // https://tc39.es/ecma262/#sec-object.assign
1532
1551
  // eslint-disable-next-line es/no-object-assign -- required for testing
1533
- $$1({ target: 'Object', stat: true, arity: 2, forced: Object.assign !== assign$1 }, {
1534
- assign: assign$1
1552
+ $({ target: 'Object', stat: true, arity: 2, forced: Object.assign !== assign }, {
1553
+ assign: assign
1535
1554
  });
1536
1555
 
1537
1556
  // iterable DOM collections
@@ -1578,7 +1597,7 @@ var DOMTokenListPrototype$1 = classList && classList.constructor && classList.co
1578
1597
 
1579
1598
  var domTokenListPrototype = DOMTokenListPrototype$1 === Object.prototype ? undefined : DOMTokenListPrototype$1;
1580
1599
 
1581
- var global$1 = global$b;
1600
+ var globalThis$1 = globalThis_1;
1582
1601
  var DOMIterables = domIterables;
1583
1602
  var DOMTokenListPrototype = domTokenListPrototype;
1584
1603
  var ArrayIteratorMethods = es_array_iterator;
@@ -1610,927 +1629,11 @@ var handlePrototype = function (CollectionPrototype, COLLECTION_NAME) {
1610
1629
  };
1611
1630
 
1612
1631
  for (var COLLECTION_NAME in DOMIterables) {
1613
- handlePrototype(global$1[COLLECTION_NAME] && global$1[COLLECTION_NAME].prototype, COLLECTION_NAME);
1632
+ handlePrototype(globalThis$1[COLLECTION_NAME] && globalThis$1[COLLECTION_NAME].prototype, COLLECTION_NAME);
1614
1633
  }
1615
1634
 
1616
1635
  handlePrototype(DOMTokenListPrototype, 'DOMTokenList');
1617
1636
 
1618
- /******************************************************************************
1619
- Copyright (c) Microsoft Corporation.
1620
-
1621
- Permission to use, copy, modify, and/or distribute this software for any
1622
- purpose with or without fee is hereby granted.
1623
-
1624
- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
1625
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
1626
- AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
1627
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
1628
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
1629
- OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
1630
- PERFORMANCE OF THIS SOFTWARE.
1631
- ***************************************************************************** */
1632
-
1633
- var __assign = function() {
1634
- __assign = Object.assign || function __assign(t) {
1635
- for (var s, i = 1, n = arguments.length; i < n; i++) {
1636
- s = arguments[i];
1637
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
1638
- }
1639
- return t;
1640
- };
1641
- return __assign.apply(this, arguments);
1642
- };
1643
-
1644
- function __spreadArray(to, from, pack) {
1645
- if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
1646
- if (ar || !(i in from)) {
1647
- if (!ar) ar = Array.prototype.slice.call(from, 0, i);
1648
- ar[i] = from[i];
1649
- }
1650
- }
1651
- return to.concat(ar || Array.prototype.slice.call(from));
1652
- }
1653
-
1654
- typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
1655
- var e = new Error(message);
1656
- return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
1657
- };
1658
-
1659
- function memoize(fn) {
1660
- var cache = Object.create(null);
1661
- return function (arg) {
1662
- if (cache[arg] === undefined) cache[arg] = fn(arg);
1663
- return cache[arg];
1664
- };
1665
- }
1666
-
1667
- 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|disableRemotePlayback|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
1668
-
1669
- var isPropValid = /* #__PURE__ */memoize(function (prop) {
1670
- return reactPropsRegex.test(prop) || prop.charCodeAt(0) === 111
1671
- /* o */
1672
- && prop.charCodeAt(1) === 110
1673
- /* n */
1674
- && prop.charCodeAt(2) < 91;
1675
- }
1676
- /* Z+1 */
1677
- );
1678
-
1679
- var MS = '-ms-';
1680
- var MOZ = '-moz-';
1681
- var WEBKIT = '-webkit-';
1682
-
1683
- var COMMENT = 'comm';
1684
- var RULESET = 'rule';
1685
- var DECLARATION = 'decl';
1686
- var IMPORT = '@import';
1687
- var KEYFRAMES = '@keyframes';
1688
- var LAYER = '@layer';
1689
-
1690
- /**
1691
- * @param {number}
1692
- * @return {number}
1693
- */
1694
- var abs = Math.abs;
1695
-
1696
- /**
1697
- * @param {number}
1698
- * @return {string}
1699
- */
1700
- var from = String.fromCharCode;
1701
-
1702
- /**
1703
- * @param {object}
1704
- * @return {object}
1705
- */
1706
- var assign = Object.assign;
1707
-
1708
- /**
1709
- * @param {string} value
1710
- * @param {number} length
1711
- * @return {number}
1712
- */
1713
- function hash (value, length) {
1714
- return charat(value, 0) ^ 45 ? (((((((length << 2) ^ charat(value, 0)) << 2) ^ charat(value, 1)) << 2) ^ charat(value, 2)) << 2) ^ charat(value, 3) : 0
1715
- }
1716
-
1717
- /**
1718
- * @param {string} value
1719
- * @return {string}
1720
- */
1721
- function trim (value) {
1722
- return value.trim()
1723
- }
1724
-
1725
- /**
1726
- * @param {string} value
1727
- * @param {RegExp} pattern
1728
- * @return {string?}
1729
- */
1730
- function match (value, pattern) {
1731
- return (value = pattern.exec(value)) ? value[0] : value
1732
- }
1733
-
1734
- /**
1735
- * @param {string} value
1736
- * @param {(string|RegExp)} pattern
1737
- * @param {string} replacement
1738
- * @return {string}
1739
- */
1740
- function replace (value, pattern, replacement) {
1741
- return value.replace(pattern, replacement)
1742
- }
1743
-
1744
- /**
1745
- * @param {string} value
1746
- * @param {string} search
1747
- * @param {number} position
1748
- * @return {number}
1749
- */
1750
- function indexof (value, search, position) {
1751
- return value.indexOf(search, position)
1752
- }
1753
-
1754
- /**
1755
- * @param {string} value
1756
- * @param {number} index
1757
- * @return {number}
1758
- */
1759
- function charat (value, index) {
1760
- return value.charCodeAt(index) | 0
1761
- }
1762
-
1763
- /**
1764
- * @param {string} value
1765
- * @param {number} begin
1766
- * @param {number} end
1767
- * @return {string}
1768
- */
1769
- function substr (value, begin, end) {
1770
- return value.slice(begin, end)
1771
- }
1772
-
1773
- /**
1774
- * @param {string} value
1775
- * @return {number}
1776
- */
1777
- function strlen (value) {
1778
- return value.length
1779
- }
1780
-
1781
- /**
1782
- * @param {any[]} value
1783
- * @return {number}
1784
- */
1785
- function sizeof (value) {
1786
- return value.length
1787
- }
1788
-
1789
- /**
1790
- * @param {any} value
1791
- * @param {any[]} array
1792
- * @return {any}
1793
- */
1794
- function append (value, array) {
1795
- return array.push(value), value
1796
- }
1797
-
1798
- /**
1799
- * @param {string[]} array
1800
- * @param {function} callback
1801
- * @return {string}
1802
- */
1803
- function combine (array, callback) {
1804
- return array.map(callback).join('')
1805
- }
1806
-
1807
- /**
1808
- * @param {string[]} array
1809
- * @param {RegExp} pattern
1810
- * @return {string[]}
1811
- */
1812
- function filter (array, pattern) {
1813
- return array.filter(function (value) { return !match(value, pattern) })
1814
- }
1815
-
1816
- var line = 1;
1817
- var column = 1;
1818
- var length = 0;
1819
- var position = 0;
1820
- var character = 0;
1821
- var characters = '';
1822
-
1823
- /**
1824
- * @param {string} value
1825
- * @param {object | null} root
1826
- * @param {object | null} parent
1827
- * @param {string} type
1828
- * @param {string[] | string} props
1829
- * @param {object[] | string} children
1830
- * @param {object[]} siblings
1831
- * @param {number} length
1832
- */
1833
- function node (value, root, parent, type, props, children, length, siblings) {
1834
- return {value: value, root: root, parent: parent, type: type, props: props, children: children, line: line, column: column, length: length, return: '', siblings: siblings}
1835
- }
1836
-
1837
- /**
1838
- * @param {object} root
1839
- * @param {object} props
1840
- * @return {object}
1841
- */
1842
- function copy (root, props) {
1843
- return assign(node('', null, null, '', null, null, 0, root.siblings), root, {length: -root.length}, props)
1844
- }
1845
-
1846
- /**
1847
- * @param {object} root
1848
- */
1849
- function lift (root) {
1850
- while (root.root)
1851
- root = copy(root.root, {children: [root]});
1852
-
1853
- append(root, root.siblings);
1854
- }
1855
-
1856
- /**
1857
- * @return {number}
1858
- */
1859
- function char () {
1860
- return character
1861
- }
1862
-
1863
- /**
1864
- * @return {number}
1865
- */
1866
- function prev () {
1867
- character = position > 0 ? charat(characters, --position) : 0;
1868
-
1869
- if (column--, character === 10)
1870
- column = 1, line--;
1871
-
1872
- return character
1873
- }
1874
-
1875
- /**
1876
- * @return {number}
1877
- */
1878
- function next () {
1879
- character = position < length ? charat(characters, position++) : 0;
1880
-
1881
- if (column++, character === 10)
1882
- column = 1, line++;
1883
-
1884
- return character
1885
- }
1886
-
1887
- /**
1888
- * @return {number}
1889
- */
1890
- function peek () {
1891
- return charat(characters, position)
1892
- }
1893
-
1894
- /**
1895
- * @return {number}
1896
- */
1897
- function caret () {
1898
- return position
1899
- }
1900
-
1901
- /**
1902
- * @param {number} begin
1903
- * @param {number} end
1904
- * @return {string}
1905
- */
1906
- function slice (begin, end) {
1907
- return substr(characters, begin, end)
1908
- }
1909
-
1910
- /**
1911
- * @param {number} type
1912
- * @return {number}
1913
- */
1914
- function token (type) {
1915
- switch (type) {
1916
- // \0 \t \n \r \s whitespace token
1917
- case 0: case 9: case 10: case 13: case 32:
1918
- return 5
1919
- // ! + , / > @ ~ isolate token
1920
- case 33: case 43: case 44: case 47: case 62: case 64: case 126:
1921
- // ; { } breakpoint token
1922
- case 59: case 123: case 125:
1923
- return 4
1924
- // : accompanied token
1925
- case 58:
1926
- return 3
1927
- // " ' ( [ opening delimit token
1928
- case 34: case 39: case 40: case 91:
1929
- return 2
1930
- // ) ] closing delimit token
1931
- case 41: case 93:
1932
- return 1
1933
- }
1934
-
1935
- return 0
1936
- }
1937
-
1938
- /**
1939
- * @param {string} value
1940
- * @return {any[]}
1941
- */
1942
- function alloc (value) {
1943
- return line = column = 1, length = strlen(characters = value), position = 0, []
1944
- }
1945
-
1946
- /**
1947
- * @param {any} value
1948
- * @return {any}
1949
- */
1950
- function dealloc (value) {
1951
- return characters = '', value
1952
- }
1953
-
1954
- /**
1955
- * @param {number} type
1956
- * @return {string}
1957
- */
1958
- function delimit (type) {
1959
- return trim(slice(position - 1, delimiter(type === 91 ? type + 2 : type === 40 ? type + 1 : type)))
1960
- }
1961
-
1962
- /**
1963
- * @param {number} type
1964
- * @return {string}
1965
- */
1966
- function whitespace (type) {
1967
- while (character = peek())
1968
- if (character < 33)
1969
- next();
1970
- else
1971
- break
1972
-
1973
- return token(type) > 2 || token(character) > 3 ? '' : ' '
1974
- }
1975
-
1976
- /**
1977
- * @param {number} index
1978
- * @param {number} count
1979
- * @return {string}
1980
- */
1981
- function escaping (index, count) {
1982
- while (--count && next())
1983
- // not 0-9 A-F a-f
1984
- if (character < 48 || character > 102 || (character > 57 && character < 65) || (character > 70 && character < 97))
1985
- break
1986
-
1987
- return slice(index, caret() + (count < 6 && peek() == 32 && next() == 32))
1988
- }
1989
-
1990
- /**
1991
- * @param {number} type
1992
- * @return {number}
1993
- */
1994
- function delimiter (type) {
1995
- while (next())
1996
- switch (character) {
1997
- // ] ) " '
1998
- case type:
1999
- return position
2000
- // " '
2001
- case 34: case 39:
2002
- if (type !== 34 && type !== 39)
2003
- delimiter(character);
2004
- break
2005
- // (
2006
- case 40:
2007
- if (type === 41)
2008
- delimiter(type);
2009
- break
2010
- // \
2011
- case 92:
2012
- next();
2013
- break
2014
- }
2015
-
2016
- return position
2017
- }
2018
-
2019
- /**
2020
- * @param {number} type
2021
- * @param {number} index
2022
- * @return {number}
2023
- */
2024
- function commenter (type, index) {
2025
- while (next())
2026
- // //
2027
- if (type + character === 47 + 10)
2028
- break
2029
- // /*
2030
- else if (type + character === 42 + 42 && peek() === 47)
2031
- break
2032
-
2033
- return '/*' + slice(index, position - 1) + '*' + from(type === 47 ? type : next())
2034
- }
2035
-
2036
- /**
2037
- * @param {number} index
2038
- * @return {string}
2039
- */
2040
- function identifier (index) {
2041
- while (!token(peek()))
2042
- next();
2043
-
2044
- return slice(index, position)
2045
- }
2046
-
2047
- /**
2048
- * @param {string} value
2049
- * @return {object[]}
2050
- */
2051
- function compile (value) {
2052
- return dealloc(parse('', null, null, null, [''], value = alloc(value), 0, [0], value))
2053
- }
2054
-
2055
- /**
2056
- * @param {string} value
2057
- * @param {object} root
2058
- * @param {object?} parent
2059
- * @param {string[]} rule
2060
- * @param {string[]} rules
2061
- * @param {string[]} rulesets
2062
- * @param {number[]} pseudo
2063
- * @param {number[]} points
2064
- * @param {string[]} declarations
2065
- * @return {object}
2066
- */
2067
- function parse (value, root, parent, rule, rules, rulesets, pseudo, points, declarations) {
2068
- var index = 0;
2069
- var offset = 0;
2070
- var length = pseudo;
2071
- var atrule = 0;
2072
- var property = 0;
2073
- var previous = 0;
2074
- var variable = 1;
2075
- var scanning = 1;
2076
- var ampersand = 1;
2077
- var character = 0;
2078
- var type = '';
2079
- var props = rules;
2080
- var children = rulesets;
2081
- var reference = rule;
2082
- var characters = type;
2083
-
2084
- while (scanning)
2085
- switch (previous = character, character = next()) {
2086
- // (
2087
- case 40:
2088
- if (previous != 108 && charat(characters, length - 1) == 58) {
2089
- if (indexof(characters += replace(delimit(character), '&', '&\f'), '&\f', abs(index ? points[index - 1] : 0)) != -1)
2090
- ampersand = -1;
2091
- break
2092
- }
2093
- // " ' [
2094
- case 34: case 39: case 91:
2095
- characters += delimit(character);
2096
- break
2097
- // \t \n \r \s
2098
- case 9: case 10: case 13: case 32:
2099
- characters += whitespace(previous);
2100
- break
2101
- // \
2102
- case 92:
2103
- characters += escaping(caret() - 1, 7);
2104
- continue
2105
- // /
2106
- case 47:
2107
- switch (peek()) {
2108
- case 42: case 47:
2109
- append(comment(commenter(next(), caret()), root, parent, declarations), declarations);
2110
- break
2111
- default:
2112
- characters += '/';
2113
- }
2114
- break
2115
- // {
2116
- case 123 * variable:
2117
- points[index++] = strlen(characters) * ampersand;
2118
- // } ; \0
2119
- case 125 * variable: case 59: case 0:
2120
- switch (character) {
2121
- // \0 }
2122
- case 0: case 125: scanning = 0;
2123
- // ;
2124
- case 59 + offset: if (ampersand == -1) characters = replace(characters, /\f/g, '');
2125
- if (property > 0 && (strlen(characters) - length))
2126
- append(property > 32 ? declaration(characters + ';', rule, parent, length - 1, declarations) : declaration(replace(characters, ' ', '') + ';', rule, parent, length - 2, declarations), declarations);
2127
- break
2128
- // @ ;
2129
- case 59: characters += ';';
2130
- // { rule/at-rule
2131
- default:
2132
- append(reference = ruleset(characters, root, parent, index, offset, rules, points, type, props = [], children = [], length, rulesets), rulesets);
2133
-
2134
- if (character === 123)
2135
- if (offset === 0)
2136
- parse(characters, root, reference, reference, props, rulesets, length, points, children);
2137
- else
2138
- switch (atrule === 99 && charat(characters, 3) === 110 ? 100 : atrule) {
2139
- // d l m s
2140
- case 100: case 108: case 109: case 115:
2141
- parse(value, reference, reference, rule && append(ruleset(value, reference, reference, 0, 0, rules, points, type, rules, props = [], length, children), children), rules, children, length, points, rule ? props : children);
2142
- break
2143
- default:
2144
- parse(characters, reference, reference, reference, [''], children, 0, points, children);
2145
- }
2146
- }
2147
-
2148
- index = offset = property = 0, variable = ampersand = 1, type = characters = '', length = pseudo;
2149
- break
2150
- // :
2151
- case 58:
2152
- length = 1 + strlen(characters), property = previous;
2153
- default:
2154
- if (variable < 1)
2155
- if (character == 123)
2156
- --variable;
2157
- else if (character == 125 && variable++ == 0 && prev() == 125)
2158
- continue
2159
-
2160
- switch (characters += from(character), character * variable) {
2161
- // &
2162
- case 38:
2163
- ampersand = offset > 0 ? 1 : (characters += '\f', -1);
2164
- break
2165
- // ,
2166
- case 44:
2167
- points[index++] = (strlen(characters) - 1) * ampersand, ampersand = 1;
2168
- break
2169
- // @
2170
- case 64:
2171
- // -
2172
- if (peek() === 45)
2173
- characters += delimit(next());
2174
-
2175
- atrule = peek(), offset = length = strlen(type = characters += identifier(caret())), character++;
2176
- break
2177
- // -
2178
- case 45:
2179
- if (previous === 45 && strlen(characters) == 2)
2180
- variable = 0;
2181
- }
2182
- }
2183
-
2184
- return rulesets
2185
- }
2186
-
2187
- /**
2188
- * @param {string} value
2189
- * @param {object} root
2190
- * @param {object?} parent
2191
- * @param {number} index
2192
- * @param {number} offset
2193
- * @param {string[]} rules
2194
- * @param {number[]} points
2195
- * @param {string} type
2196
- * @param {string[]} props
2197
- * @param {string[]} children
2198
- * @param {number} length
2199
- * @param {object[]} siblings
2200
- * @return {object}
2201
- */
2202
- function ruleset (value, root, parent, index, offset, rules, points, type, props, children, length, siblings) {
2203
- var post = offset - 1;
2204
- var rule = offset === 0 ? rules : [''];
2205
- var size = sizeof(rule);
2206
-
2207
- for (var i = 0, j = 0, k = 0; i < index; ++i)
2208
- for (var x = 0, y = substr(value, post + 1, post = abs(j = points[i])), z = value; x < size; ++x)
2209
- if (z = trim(j > 0 ? rule[x] + ' ' + y : replace(y, /&\f/g, rule[x])))
2210
- props[k++] = z;
2211
-
2212
- return node(value, root, parent, offset === 0 ? RULESET : type, props, children, length, siblings)
2213
- }
2214
-
2215
- /**
2216
- * @param {number} value
2217
- * @param {object} root
2218
- * @param {object?} parent
2219
- * @param {object[]} siblings
2220
- * @return {object}
2221
- */
2222
- function comment (value, root, parent, siblings) {
2223
- return node(value, root, parent, COMMENT, from(char()), substr(value, 2, -2), 0, siblings)
2224
- }
2225
-
2226
- /**
2227
- * @param {string} value
2228
- * @param {object} root
2229
- * @param {object?} parent
2230
- * @param {number} length
2231
- * @param {object[]} siblings
2232
- * @return {object}
2233
- */
2234
- function declaration (value, root, parent, length, siblings) {
2235
- return node(value, root, parent, DECLARATION, substr(value, 0, length), substr(value, length + 1, -1), length, siblings)
2236
- }
2237
-
2238
- /**
2239
- * @param {string} value
2240
- * @param {number} length
2241
- * @param {object[]} children
2242
- * @return {string}
2243
- */
2244
- function prefix (value, length, children) {
2245
- switch (hash(value, length)) {
2246
- // color-adjust
2247
- case 5103:
2248
- return WEBKIT + 'print-' + value + value
2249
- // animation, animation-(delay|direction|duration|fill-mode|iteration-count|name|play-state|timing-function)
2250
- case 5737: case 4201: case 3177: case 3433: case 1641: case 4457: case 2921:
2251
- // text-decoration, filter, clip-path, backface-visibility, column, box-decoration-break
2252
- case 5572: case 6356: case 5844: case 3191: case 6645: case 3005:
2253
- // mask, mask-image, mask-(mode|clip|size), mask-(repeat|origin), mask-position, mask-composite,
2254
- case 6391: case 5879: case 5623: case 6135: case 4599: case 4855:
2255
- // background-clip, columns, column-(count|fill|gap|rule|rule-color|rule-style|rule-width|span|width)
2256
- case 4215: case 6389: case 5109: case 5365: case 5621: case 3829:
2257
- return WEBKIT + value + value
2258
- // tab-size
2259
- case 4789:
2260
- return MOZ + value + value
2261
- // appearance, user-select, transform, hyphens, text-size-adjust
2262
- case 5349: case 4246: case 4810: case 6968: case 2756:
2263
- return WEBKIT + value + MOZ + value + MS + value + value
2264
- // writing-mode
2265
- case 5936:
2266
- switch (charat(value, length + 11)) {
2267
- // vertical-l(r)
2268
- case 114:
2269
- return WEBKIT + value + MS + replace(value, /[svh]\w+-[tblr]{2}/, 'tb') + value
2270
- // vertical-r(l)
2271
- case 108:
2272
- return WEBKIT + value + MS + replace(value, /[svh]\w+-[tblr]{2}/, 'tb-rl') + value
2273
- // horizontal(-)tb
2274
- case 45:
2275
- return WEBKIT + value + MS + replace(value, /[svh]\w+-[tblr]{2}/, 'lr') + value
2276
- // default: fallthrough to below
2277
- }
2278
- // flex, flex-direction, scroll-snap-type, writing-mode
2279
- case 6828: case 4268: case 2903:
2280
- return WEBKIT + value + MS + value + value
2281
- // order
2282
- case 6165:
2283
- return WEBKIT + value + MS + 'flex-' + value + value
2284
- // align-items
2285
- case 5187:
2286
- return WEBKIT + value + replace(value, /(\w+).+(:[^]+)/, WEBKIT + 'box-$1$2' + MS + 'flex-$1$2') + value
2287
- // align-self
2288
- case 5443:
2289
- return WEBKIT + value + MS + 'flex-item-' + replace(value, /flex-|-self/g, '') + (!match(value, /flex-|baseline/) ? MS + 'grid-row-' + replace(value, /flex-|-self/g, '') : '') + value
2290
- // align-content
2291
- case 4675:
2292
- return WEBKIT + value + MS + 'flex-line-pack' + replace(value, /align-content|flex-|-self/g, '') + value
2293
- // flex-shrink
2294
- case 5548:
2295
- return WEBKIT + value + MS + replace(value, 'shrink', 'negative') + value
2296
- // flex-basis
2297
- case 5292:
2298
- return WEBKIT + value + MS + replace(value, 'basis', 'preferred-size') + value
2299
- // flex-grow
2300
- case 6060:
2301
- return WEBKIT + 'box-' + replace(value, '-grow', '') + WEBKIT + value + MS + replace(value, 'grow', 'positive') + value
2302
- // transition
2303
- case 4554:
2304
- return WEBKIT + replace(value, /([^-])(transform)/g, '$1' + WEBKIT + '$2') + value
2305
- // cursor
2306
- case 6187:
2307
- return replace(replace(replace(value, /(zoom-|grab)/, WEBKIT + '$1'), /(image-set)/, WEBKIT + '$1'), value, '') + value
2308
- // background, background-image
2309
- case 5495: case 3959:
2310
- return replace(value, /(image-set\([^]*)/, WEBKIT + '$1' + '$`$1')
2311
- // justify-content
2312
- case 4968:
2313
- return replace(replace(value, /(.+:)(flex-)?(.*)/, WEBKIT + 'box-pack:$3' + MS + 'flex-pack:$3'), /s.+-b[^;]+/, 'justify') + WEBKIT + value + value
2314
- // justify-self
2315
- case 4200:
2316
- if (!match(value, /flex-|baseline/)) return MS + 'grid-column-align' + substr(value, length) + value
2317
- break
2318
- // grid-template-(columns|rows)
2319
- case 2592: case 3360:
2320
- return MS + replace(value, 'template-', '') + value
2321
- // grid-(row|column)-start
2322
- case 4384: case 3616:
2323
- if (children && children.some(function (element, index) { return length = index, match(element.props, /grid-\w+-end/) })) {
2324
- return ~indexof(value + (children = children[length].value), 'span', 0) ? value : (MS + replace(value, '-start', '') + value + MS + 'grid-row-span:' + (~indexof(children, 'span', 0) ? match(children, /\d+/) : +match(children, /\d+/) - +match(value, /\d+/)) + ';')
2325
- }
2326
- return MS + replace(value, '-start', '') + value
2327
- // grid-(row|column)-end
2328
- case 4896: case 4128:
2329
- return (children && children.some(function (element) { return match(element.props, /grid-\w+-start/) })) ? value : MS + replace(replace(value, '-end', '-span'), 'span ', '') + value
2330
- // (margin|padding)-inline-(start|end)
2331
- case 4095: case 3583: case 4068: case 2532:
2332
- return replace(value, /(.+)-inline(.+)/, WEBKIT + '$1$2') + value
2333
- // (min|max)?(width|height|inline-size|block-size)
2334
- case 8116: case 7059: case 5753: case 5535:
2335
- case 5445: case 5701: case 4933: case 4677:
2336
- case 5533: case 5789: case 5021: case 4765:
2337
- // stretch, max-content, min-content, fill-available
2338
- if (strlen(value) - 1 - length > 6)
2339
- switch (charat(value, length + 1)) {
2340
- // (m)ax-content, (m)in-content
2341
- case 109:
2342
- // -
2343
- if (charat(value, length + 4) !== 45)
2344
- break
2345
- // (f)ill-available, (f)it-content
2346
- case 102:
2347
- return replace(value, /(.+:)(.+)-([^]+)/, '$1' + WEBKIT + '$2-$3' + '$1' + MOZ + (charat(value, length + 3) == 108 ? '$3' : '$2-$3')) + value
2348
- // (s)tretch
2349
- case 115:
2350
- return ~indexof(value, 'stretch', 0) ? prefix(replace(value, 'stretch', 'fill-available'), length, children) + value : value
2351
- }
2352
- break
2353
- // grid-(column|row)
2354
- case 5152: case 5920:
2355
- return replace(value, /(.+?):(\d+)(\s*\/\s*(span)?\s*(\d+))?(.*)/, function (_, a, b, c, d, e, f) { return (MS + a + ':' + b + f) + (c ? (MS + a + '-span:' + (d ? e : +e - +b)) + f : '') + value })
2356
- // position: sticky
2357
- case 4949:
2358
- // stick(y)?
2359
- if (charat(value, length + 6) === 121)
2360
- return replace(value, ':', ':' + WEBKIT) + value
2361
- break
2362
- // display: (flex|inline-flex|grid|inline-grid)
2363
- case 6444:
2364
- switch (charat(value, charat(value, 14) === 45 ? 18 : 11)) {
2365
- // (inline-)?fle(x)
2366
- case 120:
2367
- return replace(value, /(.+:)([^;\s!]+)(;|(\s+)?!.+)?/, '$1' + WEBKIT + (charat(value, 14) === 45 ? 'inline-' : '') + 'box$3' + '$1' + WEBKIT + '$2$3' + '$1' + MS + '$2box$3') + value
2368
- // (inline-)?gri(d)
2369
- case 100:
2370
- return replace(value, ':', ':' + MS) + value
2371
- }
2372
- break
2373
- // scroll-margin, scroll-margin-(top|right|bottom|left)
2374
- case 5719: case 2647: case 2135: case 3927: case 2391:
2375
- return replace(value, 'scroll-', 'scroll-snap-') + value
2376
- }
2377
-
2378
- return value
2379
- }
2380
-
2381
- /**
2382
- * @param {object[]} children
2383
- * @param {function} callback
2384
- * @return {string}
2385
- */
2386
- function serialize (children, callback) {
2387
- var output = '';
2388
-
2389
- for (var i = 0; i < children.length; i++)
2390
- output += callback(children[i], i, children, callback) || '';
2391
-
2392
- return output
2393
- }
2394
-
2395
- /**
2396
- * @param {object} element
2397
- * @param {number} index
2398
- * @param {object[]} children
2399
- * @param {function} callback
2400
- * @return {string}
2401
- */
2402
- function stringify (element, index, children, callback) {
2403
- switch (element.type) {
2404
- case LAYER: if (element.children.length) break
2405
- case IMPORT: case DECLARATION: return element.return = element.return || element.value
2406
- case COMMENT: return ''
2407
- case KEYFRAMES: return element.return = element.value + '{' + serialize(element.children, callback) + '}'
2408
- case RULESET: if (!strlen(element.value = element.props.join(','))) return ''
2409
- }
2410
-
2411
- return strlen(children = serialize(element.children, callback)) ? element.return = element.value + '{' + children + '}' : ''
2412
- }
2413
-
2414
- /**
2415
- * @param {function[]} collection
2416
- * @return {function}
2417
- */
2418
- function middleware (collection) {
2419
- var length = sizeof(collection);
2420
-
2421
- return function (element, index, children, callback) {
2422
- var output = '';
2423
-
2424
- for (var i = 0; i < length; i++)
2425
- output += collection[i](element, index, children, callback) || '';
2426
-
2427
- return output
2428
- }
2429
- }
2430
-
2431
- /**
2432
- * @param {function} callback
2433
- * @return {function}
2434
- */
2435
- function rulesheet (callback) {
2436
- return function (element) {
2437
- if (!element.root)
2438
- if (element = element.return)
2439
- callback(element);
2440
- }
2441
- }
2442
-
2443
- /**
2444
- * @param {object} element
2445
- * @param {number} index
2446
- * @param {object[]} children
2447
- * @param {function} callback
2448
- */
2449
- function prefixer (element, index, children, callback) {
2450
- if (element.length > -1)
2451
- if (!element.return)
2452
- switch (element.type) {
2453
- case DECLARATION: element.return = prefix(element.value, element.length, children);
2454
- return
2455
- case KEYFRAMES:
2456
- return serialize([copy(element, {value: replace(element.value, '@', '@' + WEBKIT)})], callback)
2457
- case RULESET:
2458
- if (element.length)
2459
- return combine(children = element.props, function (value) {
2460
- switch (match(value, callback = /(::plac\w+|:read-\w+)/)) {
2461
- // :read-(only|write)
2462
- case ':read-only': case ':read-write':
2463
- lift(copy(element, {props: [replace(value, /:(read-\w+)/, ':' + MOZ + '$1')]}));
2464
- lift(copy(element, {props: [value]}));
2465
- assign(element, {props: filter(children, callback)});
2466
- break
2467
- // :placeholder
2468
- case '::placeholder':
2469
- lift(copy(element, {props: [replace(value, /:(plac\w+)/, ':' + WEBKIT + 'input-$1')]}));
2470
- lift(copy(element, {props: [replace(value, /:(plac\w+)/, ':' + MOZ + '$1')]}));
2471
- lift(copy(element, {props: [replace(value, /:(plac\w+)/, MS + 'input-$1')]}));
2472
- lift(copy(element, {props: [value]}));
2473
- assign(element, {props: filter(children, callback)});
2474
- break
2475
- }
2476
-
2477
- return ''
2478
- })
2479
- }
2480
- }
2481
-
2482
- var unitlessKeys = {
2483
- animationIterationCount: 1,
2484
- aspectRatio: 1,
2485
- borderImageOutset: 1,
2486
- borderImageSlice: 1,
2487
- borderImageWidth: 1,
2488
- boxFlex: 1,
2489
- boxFlexGroup: 1,
2490
- boxOrdinalGroup: 1,
2491
- columnCount: 1,
2492
- columns: 1,
2493
- flex: 1,
2494
- flexGrow: 1,
2495
- flexPositive: 1,
2496
- flexShrink: 1,
2497
- flexNegative: 1,
2498
- flexOrder: 1,
2499
- gridRow: 1,
2500
- gridRowEnd: 1,
2501
- gridRowSpan: 1,
2502
- gridRowStart: 1,
2503
- gridColumn: 1,
2504
- gridColumnEnd: 1,
2505
- gridColumnSpan: 1,
2506
- gridColumnStart: 1,
2507
- msGridRow: 1,
2508
- msGridRowSpan: 1,
2509
- msGridColumn: 1,
2510
- msGridColumnSpan: 1,
2511
- fontWeight: 1,
2512
- lineHeight: 1,
2513
- opacity: 1,
2514
- order: 1,
2515
- orphans: 1,
2516
- tabSize: 1,
2517
- widows: 1,
2518
- zIndex: 1,
2519
- zoom: 1,
2520
- WebkitLineClamp: 1,
2521
- // SVG-related properties
2522
- fillOpacity: 1,
2523
- floodOpacity: 1,
2524
- stopOpacity: 1,
2525
- strokeDasharray: 1,
2526
- strokeDashoffset: 1,
2527
- strokeMiterlimit: 1,
2528
- strokeOpacity: 1,
2529
- strokeWidth: 1
2530
- };
2531
-
2532
- var f="undefined"!=typeof process&&void 0!==process.env&&(process.env.REACT_APP_SC_ATTR||process.env.SC_ATTR)||"data-styled",m="active",y="data-styled-version",v="6.1.13",g="/*!sc*/\n",S="undefined"!=typeof window&&"HTMLElement"in window,w=Boolean("boolean"==typeof SC_DISABLE_SPEEDY?SC_DISABLE_SPEEDY:"undefined"!=typeof process&&void 0!==process.env&&void 0!==process.env.REACT_APP_SC_DISABLE_SPEEDY&&""!==process.env.REACT_APP_SC_DISABLE_SPEEDY?"false"!==process.env.REACT_APP_SC_DISABLE_SPEEDY&&process.env.REACT_APP_SC_DISABLE_SPEEDY:"undefined"!=typeof process&&void 0!==process.env&&void 0!==process.env.SC_DISABLE_SPEEDY&&""!==process.env.SC_DISABLE_SPEEDY?"false"!==process.env.SC_DISABLE_SPEEDY&&process.env.SC_DISABLE_SPEEDY:"production"!==process.env.NODE_ENV),E=/invalid hook call/i,N=new Set,P=function(t,n){if("production"!==process.env.NODE_ENV){var r=n?' with the id of "'.concat(n,'"'):"",s="The component ".concat(t).concat(r," has been created dynamically.\n")+"You may see this warning because you've called styled inside another component.\nTo resolve this only create new StyledComponents outside of any render method and function component.",i=console.error;try{var a=!0;console.error=function(t){for(var n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];E.test(t)?(a=!1,N.delete(s)):i.apply(void 0,__spreadArray([t],n,!1));},useRef(),a&&!N.has(s)&&(console.warn(s),N.add(s));}catch(e){E.test(e.message)&&N.delete(s);}finally{console.error=i;}}},_$1=Object.freeze([]),C=Object.freeze({});function I(e,t,n){return void 0===n&&(n=C),e.theme!==n.theme&&e.theme||t||n.theme}var A=new Set(["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","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","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","tr","track","u","ul","use","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","marker","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"]),O=/[!"#$%&'()*+,./:;<=>?@[\\\]^`{|}~-]+/g,D=/(^-|-$)/g;function R(e){return e.replace(O,"-").replace(D,"")}var T=/(a)(d)/gi,k=52,j=function(e){return String.fromCharCode(e+(e>25?39:97))};function x(e){var t,n="";for(t=Math.abs(e);t>k;t=t/k|0)n=j(t%k)+n;return (j(t%k)+n).replace(T,"$1-$2")}var V,F=5381,M=function(e,t){for(var n=t.length;n;)e=33*e^t.charCodeAt(--n);return e},z=function(e){return M(F,e)};function $(e){return x(z(e)>>>0)}function B(e){return "production"!==process.env.NODE_ENV&&"string"==typeof e&&e||e.displayName||e.name||"Component"}function L(e){return "string"==typeof e&&("production"===process.env.NODE_ENV||e.charAt(0)===e.charAt(0).toLowerCase())}var G="function"==typeof Symbol&&Symbol.for,Y=G?Symbol.for("react.memo"):60115,q=G?Symbol.for("react.forward_ref"):60112,W={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},H={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},U={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},J=((V={})[q]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},V[Y]=U,V);function X(e){return ("type"in(t=e)&&t.type.$$typeof)===Y?U:"$$typeof"in e?J[e.$$typeof]:W;var t;}var Z=Object.defineProperty,K=Object.getOwnPropertyNames,Q=Object.getOwnPropertySymbols,ee=Object.getOwnPropertyDescriptor,te=Object.getPrototypeOf,ne=Object.prototype;function re(e,t,n){if("string"!=typeof t){if(ne){var r=te(t);r&&r!==ne&&re(e,r,n);}var o=K(t);Q&&(o=o.concat(Q(t)));for(var s=X(e),i=X(t),a=0;a<o.length;++a){var c=o[a];if(!(c in H||n&&n[c]||i&&c in i||s&&c in s)){var l=ee(t,c);try{Z(e,c,l);}catch(e){}}}}return e}function oe(e){return "function"==typeof e}function se(e){return "object"==typeof e&&"styledComponentId"in e}function ie(e,t){return e&&t?"".concat(e," ").concat(t):e||t||""}function ae(e,t){if(0===e.length)return "";for(var n=e[0],r=1;r<e.length;r++)n+=t?t+e[r]:e[r];return n}function ce(e){return null!==e&&"object"==typeof e&&e.constructor.name===Object.name&&!("props"in e&&e.$$typeof)}function le(e,t,n){if(void 0===n&&(n=!1),!n&&!ce(e)&&!Array.isArray(e))return t;if(Array.isArray(t))for(var r=0;r<t.length;r++)e[r]=le(e[r],t[r]);else if(ce(t))for(var r in t)e[r]=le(e[r],t[r]);return e}function ue(e,t){Object.defineProperty(e,"toString",{value:t});}var pe="production"!==process.env.NODE_ENV?{1:"Cannot create styled-component for component: %s.\n\n",2:"Can't collect styles once you've consumed a `ServerStyleSheet`'s styles! `ServerStyleSheet` is a one off instance for each server-side render cycle.\n\n- Are you trying to reuse it across renders?\n- Are you accidentally calling collectStyles twice?\n\n",3:"Streaming SSR is only supported in a Node.js environment; Please do not try to call this method in the browser.\n\n",4:"The `StyleSheetManager` expects a valid target or sheet prop!\n\n- Does this error occur on the client and is your target falsy?\n- Does this error occur on the server and is the sheet falsy?\n\n",5:"The clone method cannot be used on the client!\n\n- Are you running in a client-like environment on the server?\n- Are you trying to run SSR on the client?\n\n",6:"Trying to insert a new style tag, but the given Node is unmounted!\n\n- Are you using a custom target that isn't mounted?\n- Does your document not have a valid head element?\n- Have you accidentally removed a style tag manually?\n\n",7:'ThemeProvider: Please return an object from your "theme" prop function, e.g.\n\n```js\ntheme={() => ({})}\n```\n\n',8:'ThemeProvider: Please make your "theme" prop an object.\n\n',9:"Missing document `<head>`\n\n",10:"Cannot find a StyleSheet instance. Usually this happens if there are multiple copies of styled-components loaded at once. Check out this issue for how to troubleshoot and fix the common cases where this situation can happen: https://github.com/styled-components/styled-components/issues/1941#issuecomment-417862021\n\n",11:"_This error was replaced with a dev-time warning, it will be deleted for v4 final._ [createGlobalStyle] received children which will not be rendered. Please use the component without passing children elements.\n\n",12:"It seems you are interpolating a keyframe declaration (%s) into an untagged string. This was supported in styled-components v3, but is not longer supported in v4 as keyframes are now injected on-demand. Please wrap your string in the css\\`\\` helper which ensures the styles are injected correctly. See https://www.styled-components.com/docs/api#css\n\n",13:"%s is not a styled component and cannot be referred to via component selector. See https://www.styled-components.com/docs/advanced#referring-to-other-components for more details.\n\n",14:'ThemeProvider: "theme" prop is required.\n\n',15:"A stylis plugin has been supplied that is not named. We need a name for each plugin to be able to prevent styling collisions between different stylis configurations within the same app. Before you pass your plugin to `<StyleSheetManager stylisPlugins={[]}>`, please make sure each plugin is uniquely-named, e.g.\n\n```js\nObject.defineProperty(importedPlugin, 'name', { value: 'some-unique-name' });\n```\n\n",16:"Reached the limit of how many styled components may be created at group %s.\nYou may only create up to 1,073,741,824 components. If you're creating components dynamically,\nas for instance in your render method then you may be running into this limitation.\n\n",17:"CSSStyleSheet could not be found on HTMLStyleElement.\nHas styled-components' style tag been unmounted or altered by another script?\n",18:"ThemeProvider: Please make sure your useTheme hook is within a `<ThemeProvider>`"}:{};function de(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n=e[0],r=[],o=1,s=e.length;o<s;o+=1)r.push(e[o]);return r.forEach(function(e){n=n.replace(/%[a-z]/,e);}),n}function he(t){for(var n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];return "production"===process.env.NODE_ENV?new Error("An error occurred. See https://github.com/styled-components/styled-components/blob/main/packages/styled-components/src/utils/errors.md#".concat(t," for more information.").concat(n.length>0?" Args: ".concat(n.join(", ")):"")):new Error(de.apply(void 0,__spreadArray([pe[t]],n,!1)).trim())}var fe=function(){function e(e){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=e;}return e.prototype.indexOfGroup=function(e){for(var t=0,n=0;n<e;n++)t+=this.groupSizes[n];return t},e.prototype.insertRules=function(e,t){if(e>=this.groupSizes.length){for(var n=this.groupSizes,r=n.length,o=r;e>=o;)if((o<<=1)<0)throw he(16,"".concat(e));this.groupSizes=new Uint32Array(o),this.groupSizes.set(n),this.length=o;for(var s=r;s<o;s++)this.groupSizes[s]=0;}for(var i=this.indexOfGroup(e+1),a=(s=0,t.length);s<a;s++)this.tag.insertRule(i,t[s])&&(this.groupSizes[e]++,i++);},e.prototype.clearGroup=function(e){if(e<this.length){var t=this.groupSizes[e],n=this.indexOfGroup(e),r=n+t;this.groupSizes[e]=0;for(var o=n;o<r;o++)this.tag.deleteRule(n);}},e.prototype.getGroup=function(e){var t="";if(e>=this.length||0===this.groupSizes[e])return t;for(var n=this.groupSizes[e],r=this.indexOfGroup(e),o=r+n,s=r;s<o;s++)t+="".concat(this.tag.getRule(s)).concat(g);return t},e}(),me=1<<30,ye=new Map,ve=new Map,ge=1,Se=function(e){if(ye.has(e))return ye.get(e);for(;ve.has(ge);)ge++;var t=ge++;if("production"!==process.env.NODE_ENV&&((0|t)<0||t>me))throw he(16,"".concat(t));return ye.set(e,t),ve.set(t,e),t},we=function(e,t){ge=t+1,ye.set(e,t),ve.set(t,e);},be="style[".concat(f,"][").concat(y,'="').concat(v,'"]'),Ee=new RegExp("^".concat(f,'\\.g(\\d+)\\[id="([\\w\\d-]+)"\\].*?"([^"]*)')),Ne=function(e,t,n){for(var r,o=n.split(","),s=0,i=o.length;s<i;s++)(r=o[s])&&e.registerName(t,r);},Pe=function(e,t){for(var n,r=(null!==(n=t.textContent)&&void 0!==n?n:"").split(g),o=[],s=0,i=r.length;s<i;s++){var a=r[s].trim();if(a){var c=a.match(Ee);if(c){var l=0|parseInt(c[1],10),u=c[2];0!==l&&(we(u,l),Ne(e,u,c[3]),e.getTag().insertRules(l,o)),o.length=0;}else o.push(a);}}},_e=function(e){for(var t=document.querySelectorAll(be),n=0,r=t.length;n<r;n++){var o=t[n];o&&o.getAttribute(f)!==m&&(Pe(e,o),o.parentNode&&o.parentNode.removeChild(o));}};function Ce(){return "undefined"!=typeof __webpack_nonce__?__webpack_nonce__:null}var Ie=function(e){var t=document.head,n=e||t,r=document.createElement("style"),o=function(e){var t=Array.from(e.querySelectorAll("style[".concat(f,"]")));return t[t.length-1]}(n),s=void 0!==o?o.nextSibling:null;r.setAttribute(f,m),r.setAttribute(y,v);var i=Ce();return i&&r.setAttribute("nonce",i),n.insertBefore(r,s),r},Ae=function(){function e(e){this.element=Ie(e),this.element.appendChild(document.createTextNode("")),this.sheet=function(e){if(e.sheet)return e.sheet;for(var t=document.styleSheets,n=0,r=t.length;n<r;n++){var o=t[n];if(o.ownerNode===e)return o}throw he(17)}(this.element),this.length=0;}return e.prototype.insertRule=function(e,t){try{return this.sheet.insertRule(t,e),this.length++,!0}catch(e){return !1}},e.prototype.deleteRule=function(e){this.sheet.deleteRule(e),this.length--;},e.prototype.getRule=function(e){var t=this.sheet.cssRules[e];return t&&t.cssText?t.cssText:""},e}(),Oe=function(){function e(e){this.element=Ie(e),this.nodes=this.element.childNodes,this.length=0;}return e.prototype.insertRule=function(e,t){if(e<=this.length&&e>=0){var n=document.createTextNode(t);return this.element.insertBefore(n,this.nodes[e]||null),this.length++,!0}return !1},e.prototype.deleteRule=function(e){this.element.removeChild(this.nodes[e]),this.length--;},e.prototype.getRule=function(e){return e<this.length?this.nodes[e].textContent:""},e}(),De=function(){function e(e){this.rules=[],this.length=0;}return e.prototype.insertRule=function(e,t){return e<=this.length&&(this.rules.splice(e,0,t),this.length++,!0)},e.prototype.deleteRule=function(e){this.rules.splice(e,1),this.length--;},e.prototype.getRule=function(e){return e<this.length?this.rules[e]:""},e}(),Re=S,Te={isServer:!S,useCSSOMInjection:!w},ke=function(){function e(e,n,r){void 0===e&&(e=C),void 0===n&&(n={});var o=this;this.options=__assign(__assign({},Te),e),this.gs=n,this.names=new Map(r),this.server=!!e.isServer,!this.server&&S&&Re&&(Re=!1,_e(this)),ue(this,function(){return function(e){for(var t=e.getTag(),n=t.length,r="",o=function(n){var o=function(e){return ve.get(e)}(n);if(void 0===o)return "continue";var s=e.names.get(o),i=t.getGroup(n);if(void 0===s||!s.size||0===i.length)return "continue";var a="".concat(f,".g").concat(n,'[id="').concat(o,'"]'),c="";void 0!==s&&s.forEach(function(e){e.length>0&&(c+="".concat(e,","));}),r+="".concat(i).concat(a,'{content:"').concat(c,'"}').concat(g);},s=0;s<n;s++)o(s);return r}(o)});}return e.registerId=function(e){return Se(e)},e.prototype.rehydrate=function(){!this.server&&S&&_e(this);},e.prototype.reconstructWithOptions=function(n,r){return void 0===r&&(r=!0),new e(__assign(__assign({},this.options),n),this.gs,r&&this.names||void 0)},e.prototype.allocateGSInstance=function(e){return this.gs[e]=(this.gs[e]||0)+1},e.prototype.getTag=function(){return this.tag||(this.tag=(e=function(e){var t=e.useCSSOMInjection,n=e.target;return e.isServer?new De(n):t?new Ae(n):new Oe(n)}(this.options),new fe(e)));var e;},e.prototype.hasNameForId=function(e,t){return this.names.has(e)&&this.names.get(e).has(t)},e.prototype.registerName=function(e,t){if(Se(e),this.names.has(e))this.names.get(e).add(t);else {var n=new Set;n.add(t),this.names.set(e,n);}},e.prototype.insertRules=function(e,t,n){this.registerName(e,t),this.getTag().insertRules(Se(e),n);},e.prototype.clearNames=function(e){this.names.has(e)&&this.names.get(e).clear();},e.prototype.clearRules=function(e){this.getTag().clearGroup(Se(e)),this.clearNames(e);},e.prototype.clearTag=function(){this.tag=void 0;},e}(),je=/&/g,xe=/^\s*\/\/.*$/gm;function Ve(e,t){return e.map(function(e){return "rule"===e.type&&(e.value="".concat(t," ").concat(e.value),e.value=e.value.replaceAll(",",",".concat(t," ")),e.props=e.props.map(function(e){return "".concat(t," ").concat(e)})),Array.isArray(e.children)&&"@keyframes"!==e.type&&(e.children=Ve(e.children,t)),e})}function Fe(e){var t,n,r,o=void 0===e?C:e,s=o.options,i=void 0===s?C:s,a=o.plugins,c=void 0===a?_$1:a,l=function(e,r,o){return o.startsWith(n)&&o.endsWith(n)&&o.replaceAll(n,"").length>0?".".concat(t):e},u=c.slice();u.push(function(e){e.type===RULESET&&e.value.includes("&")&&(e.props[0]=e.props[0].replace(je,n).replace(r,l));}),i.prefix&&u.push(prefixer),u.push(stringify);var p=function(e,o,s,a){void 0===o&&(o=""),void 0===s&&(s=""),void 0===a&&(a="&"),t=a,n=o,r=new RegExp("\\".concat(n,"\\b"),"g");var c=e.replace(xe,""),l=compile(s||o?"".concat(s," ").concat(o," { ").concat(c," }"):c);i.namespace&&(l=Ve(l,i.namespace));var p=[];return serialize(l,middleware(u.concat(rulesheet(function(e){return p.push(e)})))),p};return p.hash=c.length?c.reduce(function(e,t){return t.name||he(15),M(e,t.name)},F).toString():"",p}var Me=new ke,ze=Fe(),$e=r.createContext({shouldForwardProp:void 0,styleSheet:Me,stylis:ze});$e.Consumer;r.createContext(void 0);function Ge(){return useContext($e)}var qe=function(){function e(e,t){var n=this;this.inject=function(e,t){void 0===t&&(t=ze);var r=n.name+t.hash;e.hasNameForId(n.id,r)||e.insertRules(n.id,r,t(n.rules,r,"@keyframes"));},this.name=e,this.id="sc-keyframes-".concat(e),this.rules=t,ue(this,function(){throw he(12,String(n.name))});}return e.prototype.getName=function(e){return void 0===e&&(e=ze),this.name+e.hash},e}(),We=function(e){return e>="A"&&e<="Z"};function He(e){for(var t="",n=0;n<e.length;n++){var r=e[n];if(1===n&&"-"===r&&"-"===e[0])return e;We(r)?t+="-"+r.toLowerCase():t+=r;}return t.startsWith("ms-")?"-"+t:t}var Ue=function(e){return null==e||!1===e||""===e},Je=function(t){var n,r,o=[];for(var s in t){var i=t[s];t.hasOwnProperty(s)&&!Ue(i)&&(Array.isArray(i)&&i.isCss||oe(i)?o.push("".concat(He(s),":"),i,";"):ce(i)?o.push.apply(o,__spreadArray(__spreadArray(["".concat(s," {")],Je(i),!1),["}"],!1)):o.push("".concat(He(s),": ").concat((n=s,null==(r=i)||"boolean"==typeof r||""===r?"":"number"!=typeof r||0===r||n in unitlessKeys||n.startsWith("--")?String(r).trim():"".concat(r,"px")),";")));}return o};function Xe(e,t,n,r){if(Ue(e))return [];if(se(e))return [".".concat(e.styledComponentId)];if(oe(e)){if(!oe(s=e)||s.prototype&&s.prototype.isReactComponent||!t)return [e];var o=e(t);return "production"===process.env.NODE_ENV||"object"!=typeof o||Array.isArray(o)||o instanceof qe||ce(o)||null===o||console.error("".concat(B(e)," is not a styled component and cannot be referred to via component selector. See https://www.styled-components.com/docs/advanced#referring-to-other-components for more details.")),Xe(o,t,n,r)}var s;return e instanceof qe?n?(e.inject(n,r),[e.getName(r)]):[e]:ce(e)?Je(e):Array.isArray(e)?Array.prototype.concat.apply(_$1,e.map(function(e){return Xe(e,t,n,r)})):[e.toString()]}function Ze(e){for(var t=0;t<e.length;t+=1){var n=e[t];if(oe(n)&&!se(n))return !1}return !0}var Ke=z(v),Qe=function(){function e(e,t,n){this.rules=e,this.staticRulesId="",this.isStatic="production"===process.env.NODE_ENV&&(void 0===n||n.isStatic)&&Ze(e),this.componentId=t,this.baseHash=M(Ke,t),this.baseStyle=n,ke.registerId(t);}return e.prototype.generateAndInjectStyles=function(e,t,n){var r=this.baseStyle?this.baseStyle.generateAndInjectStyles(e,t,n):"";if(this.isStatic&&!n.hash)if(this.staticRulesId&&t.hasNameForId(this.componentId,this.staticRulesId))r=ie(r,this.staticRulesId);else {var o=ae(Xe(this.rules,e,t,n)),s=x(M(this.baseHash,o)>>>0);if(!t.hasNameForId(this.componentId,s)){var i=n(o,".".concat(s),void 0,this.componentId);t.insertRules(this.componentId,s,i);}r=ie(r,s),this.staticRulesId=s;}else {for(var a=M(this.baseHash,n.hash),c="",l=0;l<this.rules.length;l++){var u=this.rules[l];if("string"==typeof u)c+=u,"production"!==process.env.NODE_ENV&&(a=M(a,u));else if(u){var p=ae(Xe(u,e,t,n));a=M(a,p+l),c+=p;}}if(c){var d=x(a>>>0);t.hasNameForId(this.componentId,d)||t.insertRules(this.componentId,d,n(c,".".concat(d),void 0,this.componentId)),r=ie(r,d);}}return r},e}(),et=r.createContext(void 0);et.Consumer;var ot={},st=new Set;function it(e,o,s){var i=se(e),a=e,c=!L(e),p=o.attrs,d=void 0===p?_$1:p,h=o.componentId,f=void 0===h?function(e,t){var n="string"!=typeof e?"sc":R(e);ot[n]=(ot[n]||0)+1;var r="".concat(n,"-").concat($(v+n+ot[n]));return t?"".concat(t,"-").concat(r):r}(o.displayName,o.parentComponentId):h,m=o.displayName,y=void 0===m?function(e){return L(e)?"styled.".concat(e):"Styled(".concat(B(e),")")}(e):m,g=o.displayName&&o.componentId?"".concat(R(o.displayName),"-").concat(o.componentId):o.componentId||f,S=i&&a.attrs?a.attrs.concat(d).filter(Boolean):d,w=o.shouldForwardProp;if(i&&a.shouldForwardProp){var b=a.shouldForwardProp;if(o.shouldForwardProp){var E=o.shouldForwardProp;w=function(e,t){return b(e,t)&&E(e,t)};}else w=b;}var N=new Qe(s,g,i?a.componentStyle:void 0);function O(e,o){return function(e,o,s){var i=e.attrs,a=e.componentStyle,c=e.defaultProps,p=e.foldedComponentIds,d=e.styledComponentId,h=e.target,f=r.useContext(et),m=Ge(),y=e.shouldForwardProp||m.shouldForwardProp;"production"!==process.env.NODE_ENV&&useDebugValue(d);var v=I(o,f,c)||C,g=function(e,n,r){for(var o,s=__assign(__assign({},n),{className:void 0,theme:r}),i=0;i<e.length;i+=1){var a=oe(o=e[i])?o(s):o;for(var c in a)s[c]="className"===c?ie(s[c],a[c]):"style"===c?__assign(__assign({},s[c]),a[c]):a[c];}return n.className&&(s.className=ie(s.className,n.className)),s}(i,o,v),S=g.as||h,w={};for(var b in g)void 0===g[b]||"$"===b[0]||"as"===b||"theme"===b&&g.theme===v||("forwardedAs"===b?w.as=g.forwardedAs:y&&!y(b,S)||(w[b]=g[b],y||"development"!==process.env.NODE_ENV||isPropValid(b)||st.has(b)||!A.has(S)||(st.add(b),console.warn('styled-components: it looks like an unknown prop "'.concat(b,'" is being sent through to the DOM, which will likely trigger a React console error. If you would like automatic filtering of unknown props, you can opt-into that behavior via `<StyleSheetManager shouldForwardProp={...}>` (connect an API like `@emotion/is-prop-valid`) or consider using transient props (`$` prefix for automatic filtering.)')))));var E=function(e,t){var n=Ge(),r=e.generateAndInjectStyles(t,n.styleSheet,n.stylis);return "production"!==process.env.NODE_ENV&&useDebugValue(r),r}(a,g);"production"!==process.env.NODE_ENV&&e.warnTooManyClasses&&e.warnTooManyClasses(E);var N=ie(p,d);return E&&(N+=" "+E),g.className&&(N+=" "+g.className),w[L(S)&&!A.has(S)?"class":"className"]=N,w.ref=s,createElement$1(S,w)}(D,e,o)}O.displayName=y;var D=r.forwardRef(O);return D.attrs=S,D.componentStyle=N,D.displayName=y,D.shouldForwardProp=w,D.foldedComponentIds=i?ie(a.foldedComponentIds,a.styledComponentId):"",D.styledComponentId=g,D.target=i?a.target:e,Object.defineProperty(D,"defaultProps",{get:function(){return this._foldedDefaultProps},set:function(e){this._foldedDefaultProps=i?function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];for(var r=0,o=t;r<o.length;r++)le(e,o[r],!0);return e}({},a.defaultProps,e):e;}}),"production"!==process.env.NODE_ENV&&(P(y,g),D.warnTooManyClasses=function(e,t){var n={},r=!1;return function(o){if(!r&&(n[o]=!0,Object.keys(n).length>=200)){var s=t?' with the id of "'.concat(t,'"'):"";console.warn("Over ".concat(200," classes were generated for component ").concat(e).concat(s,".\n")+"Consider using the attrs method, together with a style object for frequently changed styles.\nExample:\n const Component = styled.div.attrs(props => ({\n style: {\n background: props.background,\n },\n }))`width: 100%;`\n\n <Component />"),r=!0,n={};}}}(y,g)),ue(D,function(){return ".".concat(D.styledComponentId)}),c&&re(D,e,{attrs:!0,componentStyle:!0,displayName:!0,foldedComponentIds:!0,shouldForwardProp:!0,styledComponentId:!0,target:!0}),D}function at(e,t){for(var n=[e[0]],r=0,o=t.length;r<o;r+=1)n.push(t[r],e[r+1]);return n}var ct=function(e){return Object.assign(e,{isCss:!0})};function lt(t){for(var n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];if(oe(t)||ce(t))return ct(Xe(at(_$1,__spreadArray([t],n,!0))));var o=t;return 0===n.length&&1===o.length&&"string"==typeof o[0]?Xe(o):ct(Xe(at(o,n)))}function ut(n,r,o){if(void 0===o&&(o=C),!r)throw he(1,r);var s=function(t){for(var s=[],i=1;i<arguments.length;i++)s[i-1]=arguments[i];return n(r,o,lt.apply(void 0,__spreadArray([t],s,!1)))};return s.attrs=function(e){return ut(n,r,__assign(__assign({},o),{attrs:Array.prototype.concat(o.attrs,e).filter(Boolean)}))},s.withConfig=function(e){return ut(n,r,__assign(__assign({},o),e))},s}var pt=function(e){return ut(it,e)},dt=pt;A.forEach(function(e){dt[e]=pt(e);});"production"!==process.env.NODE_ENV&&"undefined"!=typeof navigator&&"ReactNative"===navigator.product&&console.warn("It looks like you've imported 'styled-components' on React Native.\nPerhaps you're looking to import 'styled-components/native'?\nRead more about this at https://www.styled-components.com/docs/basics#react-native");var wt="__sc-".concat(f,"__");"production"!==process.env.NODE_ENV&&"test"!==process.env.NODE_ENV&&"undefined"!=typeof window&&(window[wt]||(window[wt]=0),1===window[wt]&&console.warn("It looks like there are several instances of 'styled-components' initialized in this application. This may cause dynamic styles to not render properly, errors during the rehydration process, a missing theme prop, and makes your application bigger without good reason.\n\nSee https://s-c.sh/2BAXzed for more info."),window[wt]+=1);
2533
-
2534
1637
  let _ = t => t,
2535
1638
  _t,
2536
1639
  _t2,
@@ -2544,13 +1647,17 @@ let _ = t => t,
2544
1647
  _t10,
2545
1648
  _t11,
2546
1649
  _t12,
2547
- _t13;
2548
- const Label = dt.label(_t || (_t = _`
1650
+ _t13,
1651
+ _t14,
1652
+ _t15,
1653
+ _t16,
1654
+ _t17;
1655
+ const Label = styled__default["default"].label(_t || (_t = _`
2549
1656
  ${0}
2550
1657
  `), ({
2551
1658
  $required,
2552
1659
  $variant
2553
- }) => $required && lt(_t2 || (_t2 = _`
1660
+ }) => $required && styled.css(_t2 || (_t2 = _`
2554
1661
  &::after {
2555
1662
  content: '*';
2556
1663
  margin-left: ${0};
@@ -2561,7 +1668,8 @@ const Label = dt.label(_t || (_t = _`
2561
1668
  }) => theme.components.input.requiredGap, ({
2562
1669
  theme
2563
1670
  }) => theme.components.input[$variant].text.color.required.default));
2564
- const InputWrapper = dt.div(_t3 || (_t3 = _`
1671
+ const InputWrapper = styled__default["default"].div(_t3 || (_t3 = _`
1672
+ position: relative;
2565
1673
  display: flex;
2566
1674
  flex-direction: column;
2567
1675
  font-weight: ${0};
@@ -2585,7 +1693,7 @@ const InputWrapper = dt.div(_t3 || (_t3 = _`
2585
1693
  }) => theme.components.input[$variant].text.color.fieldLabel.default, ({
2586
1694
  disabled,
2587
1695
  $variant
2588
- }) => disabled && lt(_t4 || (_t4 = _`
1696
+ }) => disabled && styled.css(_t4 || (_t4 = _`
2589
1697
  pointer-events: none;
2590
1698
  ${0}, ${0}::after, ${0}, ${0}::placeholder {
2591
1699
  color: ${0};
@@ -2601,9 +1709,10 @@ const InputWrapper = dt.div(_t3 || (_t3 = _`
2601
1709
  }) => theme.components.input[$variant].text.color.fieldLabel.disable, Icon, ({
2602
1710
  theme
2603
1711
  }) => theme.components.input[$variant].icon.color.disable));
2604
- const Container = dt.div(_t5 || (_t5 = _`
1712
+ const Container = styled__default["default"].div(_t5 || (_t5 = _`
2605
1713
  display: flex;
2606
1714
  flex: 1;
1715
+ align-items: center;
2607
1716
  padding: ${0};
2608
1717
  background-color: ${0};
2609
1718
  margin-bottom: ${0};
@@ -2644,7 +1753,7 @@ const Container = dt.div(_t5 || (_t5 = _`
2644
1753
  $variant
2645
1754
  }) => theme.components.input[$variant].text.color.fieldLabel.focus, ({
2646
1755
  $variant
2647
- }) => $variant === 'border' && lt(_t6 || (_t6 = _`
1756
+ }) => $variant === 'border' && styled.css(_t6 || (_t6 = _`
2648
1757
  background-color: ${0};
2649
1758
  outline: ${0};
2650
1759
  `), ({
@@ -2654,7 +1763,7 @@ const Container = dt.div(_t5 || (_t5 = _`
2654
1763
  }) => `1px solid ${theme.components.input[$variant].container.border.default}`), ({
2655
1764
  $hasValue,
2656
1765
  $variant
2657
- }) => $hasValue && lt(_t7 || (_t7 = _`
1766
+ }) => $hasValue && styled.css(_t7 || (_t7 = _`
2658
1767
  ${0} {
2659
1768
  color: ${0};
2660
1769
  }
@@ -2663,7 +1772,7 @@ const Container = dt.div(_t5 || (_t5 = _`
2663
1772
  }) => theme.components.input[$variant].text.color.fieldLabel.filled), ({
2664
1773
  $hasError,
2665
1774
  $variant
2666
- }) => $hasError && lt(_t8 || (_t8 = _`
1775
+ }) => $hasError && styled.css(_t8 || (_t8 = _`
2667
1776
  outline: ${0};
2668
1777
  `), ({
2669
1778
  theme
@@ -2671,14 +1780,14 @@ const Container = dt.div(_t5 || (_t5 = _`
2671
1780
  $hasError,
2672
1781
  $hasValue,
2673
1782
  $variant
2674
- }) => $hasError && $hasValue && lt(_t9 || (_t9 = _`
1783
+ }) => $hasError && $hasValue && styled.css(_t9 || (_t9 = _`
2675
1784
  ${0} {
2676
1785
  color: ${0};
2677
1786
  }
2678
1787
  `), Label, ({
2679
1788
  theme
2680
1789
  }) => theme.components.input[$variant].text.color.fieldLabel.errorFilled));
2681
- const LeftContainer = dt.div(_t10 || (_t10 = _`
1790
+ const LeftContainer = styled__default["default"].div(_t10 || (_t10 = _`
2682
1791
  display: flex;
2683
1792
  flex-direction: ${0};
2684
1793
  flex: 1;
@@ -2722,7 +1831,7 @@ const LeftContainer = dt.div(_t10 || (_t10 = _`
2722
1831
  left: 79px;
2723
1832
  }
2724
1833
  `);
2725
- const Input = dt.input(_t11 || (_t11 = _`
1834
+ const Input = styled__default["default"].input(_t11 || (_t11 = _`
2726
1835
  border: none;
2727
1836
  background-color: inherit;
2728
1837
  opacity: 1;
@@ -2768,7 +1877,7 @@ const Input = dt.input(_t11 || (_t11 = _`
2768
1877
  theme,
2769
1878
  $variant
2770
1879
  }) => theme.components.input[$variant].text.color.inputPlaceholder.default);
2771
- const Icon = dt.div(_t12 || (_t12 = _`
1880
+ const Icon = styled__default["default"].div(_t12 || (_t12 = _`
2772
1881
  display: flex;
2773
1882
  margin: auto 0;
2774
1883
  cursor: pointer;
@@ -2781,7 +1890,7 @@ const Icon = dt.div(_t12 || (_t12 = _`
2781
1890
  $hasError,
2782
1891
  $variant
2783
1892
  }) => $hasError ? theme.components.input[$variant].icon.color.error : theme.components.input[$variant].icon.color.default);
2784
- const Error$1 = dt.span(_t13 || (_t13 = _`
1893
+ const Error = styled__default["default"].span(_t13 || (_t13 = _`
2785
1894
  color: ${0};
2786
1895
  font-weight: ${0};
2787
1896
  line-height: ${0};
@@ -2802,8 +1911,44 @@ const Error$1 = dt.span(_t13 || (_t13 = _`
2802
1911
  }) => theme.components.input.error.letterSpacing, ({
2803
1912
  theme
2804
1913
  }) => theme.components.input.paddingHorizontal);
1914
+ const OpenAnimation = styled.keyframes(_t14 || (_t14 = _`
1915
+ 100% { opacity: 1; }
1916
+ `));
1917
+ styled__default["default"].div(_t15 || (_t15 = _`
1918
+ position: relative;
1919
+
1920
+ ${0}
1921
+ `), ({
1922
+ disabled
1923
+ }) => disabled && styled.css(_t16 || (_t16 = _`
1924
+ pointer-events: none;
1925
+ `)));
1926
+ const CalendarContainer = styled__default["default"].div(_t17 || (_t17 = _`
1927
+ position: absolute;
1928
+ z-index: 2;
1929
+ left: 0;
1930
+ animation-delay: 1ms;
1931
+ animation-duration: 250ms;
1932
+ animation-fill-mode: forwards;
1933
+ animation-name: ${0};
1934
+ animation-timing-function: ease-in-out;
1935
+ opacity: 0;
1936
+
1937
+ &.top {
1938
+ transform: translateY(-100%);
1939
+ top: -${0};
1940
+ }
2805
1941
 
2806
- const DateInput = /*#__PURE__*/forwardRef(({
1942
+ &.bottom {
1943
+ top: ${0};
1944
+ }
1945
+ `), OpenAnimation, ({
1946
+ theme
1947
+ }) => theme.components.input.borderWidth.default, ({
1948
+ theme
1949
+ }) => `calc(100% + ${theme.components.input.borderWidth.default})`);
1950
+
1951
+ const DateInput = /*#__PURE__*/react.forwardRef(({
2807
1952
  id: _id = 'date-of-birth-input-id',
2808
1953
  dataTestId: _dataTestId = 'date-of-birth-input-test-id',
2809
1954
  variant: _variant = 'grey',
@@ -2812,17 +1957,31 @@ const DateInput = /*#__PURE__*/forwardRef(({
2812
1957
  required,
2813
1958
  disabled,
2814
1959
  value,
1960
+ min,
1961
+ max,
1962
+ locale,
1963
+ cancel,
1964
+ confirm,
1965
+ showDatepicker,
2815
1966
  onChange,
2816
1967
  onBlur
2817
1968
  }, ref) => {
2818
- const [, forceUpdate] = useReducer(x => x + 1, 0);
2819
- const day = useRef(value ? String(value).substring(0, 2) : '');
2820
- const month = useRef(value ? String(value).substring(3, 5) : '');
2821
- const year = useRef(value ? String(value).substring(6, 10) : '');
1969
+ const [, forceUpdate] = react.useReducer(x => x + 1, 0);
1970
+ const calendarRef = react.useRef(null);
1971
+ const containerRef = react.useRef(null);
1972
+ const dayInputRef = react.useRef(null);
1973
+ const day = react.useRef(value ? String(value).substring(0, 2) : '');
1974
+ const month = react.useRef(value ? String(value).substring(3, 5) : '');
1975
+ const year = react.useRef(value ? String(value).substring(6, 10) : '');
1976
+ const [isCalendarOpen, setIsCalendarOpen] = react.useState(false);
1977
+ const {
1978
+ addOpenPositionClass
1979
+ } = uiUtils.useOpenPosition(calendarRef, containerRef, ['top', 'bottom'], 'bottom');
2822
1980
  const updateDate = e => {
1981
+ const value = !year.current && !month.current && !day.current ? '' : `${year.current}-${month.current}-${day.current}`;
2823
1982
  onChange && onChange(Object.assign(Object.assign({}, e), {
2824
1983
  target: Object.assign(Object.assign({}, e.target), {
2825
- value: `${year.current}-${month.current}-${day.current}`
1984
+ value
2826
1985
  })
2827
1986
  }));
2828
1987
  };
@@ -2855,88 +2014,158 @@ const DateInput = /*#__PURE__*/forwardRef(({
2855
2014
  // @ts-ignore
2856
2015
  onBlur(`${year.current}-${month.current}-${day.current}`);
2857
2016
  };
2017
+ const handleFocus = () => {
2018
+ setIsCalendarOpen(false);
2019
+ };
2858
2020
  const handleNextInput = next => {
2859
2021
  const input = document.getElementById(`${_id}-input-${next}`);
2860
2022
  input === null || input === void 0 ? void 0 : input.focus();
2861
2023
  };
2862
- useEffect(() => {
2024
+ const handleCancel = react.useCallback(() => {
2025
+ setIsCalendarOpen(false);
2026
+ }, []);
2027
+ const handleConfirm = react.useCallback(date => {
2028
+ setInputValue(date);
2029
+ setIsCalendarOpen(false);
2030
+ updateDate({});
2031
+ }, [onChange]);
2032
+ react.useEffect(() => {
2863
2033
  if (!value || typeof value !== 'string') return;
2034
+ setInputValue(value);
2035
+ }, [value]);
2036
+ const setInputValue = value => {
2864
2037
  const [yearValue, monthValue, dayValue] = value.split('-');
2865
- day.current = dayValue;
2866
- month.current = monthValue;
2867
- year.current = yearValue;
2038
+ day.current = dayValue || '';
2039
+ month.current = monthValue || '';
2040
+ year.current = yearValue || '';
2868
2041
  forceUpdate();
2869
- }, [value]);
2870
- return jsxs(InputWrapper, {
2042
+ };
2043
+ const onClickIcon = () => {
2044
+ var _a;
2045
+ reactDom.flushSync(() => {
2046
+ var _a, _b;
2047
+ if (disabled) return;
2048
+ if (isCalendarOpen) {
2049
+ (_a = dayInputRef === null || dayInputRef === void 0 ? void 0 : dayInputRef.current) === null || _a === void 0 ? void 0 : _a.blur();
2050
+ }
2051
+ setIsCalendarOpen(!isCalendarOpen);
2052
+ (_b = dayInputRef === null || dayInputRef === void 0 ? void 0 : dayInputRef.current) === null || _b === void 0 ? void 0 : _b.blur();
2053
+ });
2054
+ if (!isCalendarOpen) {
2055
+ (_a = calendarRef === null || calendarRef === void 0 ? void 0 : calendarRef.current) === null || _a === void 0 ? void 0 : _a.focus({
2056
+ preventScroll: true
2057
+ });
2058
+ }
2059
+ addOpenPositionClass();
2060
+ };
2061
+ const onBlurCalendar = event => {
2062
+ var _a;
2063
+ if (!((_a = calendarRef === null || calendarRef === void 0 ? void 0 : calendarRef.current) === null || _a === void 0 ? void 0 : _a.contains(event.relatedTarget)) || !event.relatedTarget) {
2064
+ setIsCalendarOpen(false);
2065
+ }
2066
+ };
2067
+ return jsxRuntime.jsxs(InputWrapper, {
2871
2068
  disabled: !!disabled,
2872
2069
  "data-testid": _dataTestId,
2873
2070
  "$variant": _variant,
2874
2071
  ref: ref,
2875
- children: [jsx(Container, {
2072
+ children: [jsxRuntime.jsxs(Container, {
2876
2073
  id: `${_id}-container`,
2877
2074
  "data-testid": `${_dataTestId}-container`,
2075
+ ref: containerRef,
2878
2076
  "$hasError": !!errorMessage,
2879
2077
  "$hasValue": !!value && value !== '',
2880
2078
  "$variant": _variant,
2881
- children: jsxs(LeftContainer, {
2079
+ children: [jsxRuntime.jsxs(LeftContainer, {
2882
2080
  "$before": false,
2883
- children: [label && jsx(Label, {
2081
+ children: [label && jsxRuntime.jsx(Label, {
2884
2082
  id: `${_id}-label`,
2885
2083
  "data-testid": `${_dataTestId}-label`,
2886
2084
  htmlFor: `${_id}-input`,
2887
2085
  "$required": !!required,
2888
2086
  "$variant": _variant,
2889
2087
  children: label
2890
- }), jsxs(LeftContainer, {
2891
- "$direction": 'row',
2088
+ }), jsxRuntime.jsxs(LeftContainer, {
2089
+ "$direction": "row",
2892
2090
  "$variant": _variant,
2893
2091
  "$before": true,
2894
- children: [jsx(Input, {
2092
+ children: [jsxRuntime.jsx(Input, {
2093
+ ref: dayInputRef,
2895
2094
  id: `${_id}-input-day`,
2896
2095
  "data-testid": `${_dataTestId}-input-day`,
2897
- type: 'number',
2096
+ type: "number",
2898
2097
  pattern: "[0-9]*",
2899
2098
  disabled: disabled,
2900
2099
  value: day.current,
2901
2100
  required: required,
2902
2101
  "$variant": _variant,
2903
- "$width": '40px',
2904
- placeholder: 'DD',
2102
+ "$width": "40px",
2103
+ placeholder: "DD",
2905
2104
  onChange: handleDayChange,
2906
2105
  onBlur: handleBlur,
2106
+ onFocus: handleFocus,
2907
2107
  maxLength: 2
2908
- }), jsx(Input, {
2108
+ }), jsxRuntime.jsx(Input, {
2909
2109
  id: `${_id}-input-month`,
2910
2110
  "data-testid": `${_dataTestId}-input-month`,
2911
- type: 'number',
2111
+ type: "number",
2912
2112
  pattern: "[0-9]*",
2913
2113
  disabled: disabled,
2914
2114
  value: month.current,
2915
2115
  required: required,
2916
2116
  "$variant": _variant,
2917
- "$width": '43px',
2918
- placeholder: 'MM',
2117
+ "$width": "43px",
2118
+ placeholder: "MM",
2919
2119
  onChange: handleMonthChange,
2920
2120
  onBlur: handleBlur,
2121
+ onFocus: handleFocus,
2921
2122
  maxLength: 2
2922
- }), jsx(Input, {
2123
+ }), jsxRuntime.jsx(Input, {
2923
2124
  id: `${_id}-input-year`,
2924
2125
  "data-testid": `${_dataTestId}-input-year`,
2925
- type: 'number',
2126
+ type: "number",
2926
2127
  pattern: "[0-9]*",
2927
2128
  disabled: disabled,
2928
2129
  value: year.current,
2929
2130
  required: required,
2930
2131
  "$variant": _variant,
2931
- "$width": '60px',
2932
- placeholder: 'YYYY',
2132
+ "$width": "60px",
2133
+ placeholder: "YYYY",
2933
2134
  onChange: handleYearChange,
2934
2135
  onBlur: handleBlur,
2136
+ onFocus: handleFocus,
2935
2137
  maxLength: 4
2936
2138
  })]
2937
2139
  })]
2140
+ }), showDatepicker && jsxRuntime.jsx(Icon, {
2141
+ id: `${_id}-icon`,
2142
+ "data-testid": `${_dataTestId}-button-icon`,
2143
+ onClick: onClickIcon,
2144
+ "$hasError": !!errorMessage,
2145
+ "$variant": _variant,
2146
+ children: jsxRuntime.jsx(atomsIcon.Icon, {
2147
+ "data-testid": `${_dataTestId}-icon`,
2148
+ icon: 'calendar_month'
2149
+ })
2150
+ })]
2151
+ }), isCalendarOpen && jsxRuntime.jsx(CalendarContainer, {
2152
+ ref: calendarRef,
2153
+ onClick: event => event.stopPropagation(),
2154
+ tabIndex: 1,
2155
+ onBlur: onBlurCalendar,
2156
+ children: jsxRuntime.jsx(moleculesCalendar.Calendar, {
2157
+ id: `${_id}-calendar`,
2158
+ dataTestId: `${_dataTestId}-calendar`,
2159
+ locale: locale,
2160
+ min: min,
2161
+ max: max,
2162
+ value: value,
2163
+ cancel: cancel,
2164
+ confirm: confirm,
2165
+ onCancel: handleCancel,
2166
+ onChange: handleConfirm
2938
2167
  })
2939
- }), !!errorMessage && jsx(Error$1, {
2168
+ }), !!errorMessage && jsxRuntime.jsx(Error, {
2940
2169
  id: `${_id}-error`,
2941
2170
  "datatest-id": `${_dataTestId}-error`,
2942
2171
  "$variant": _variant,
@@ -2946,4 +2175,4 @@ const DateInput = /*#__PURE__*/forwardRef(({
2946
2175
  });
2947
2176
  DateInput.displayName = 'DateInput';
2948
2177
 
2949
- export { DateInput };
2178
+ exports.DateInput = DateInput;