smoothly 0.1.67 → 0.1.71

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (83) hide show
  1. package/dist/cjs/{Trigger-ea33b682.js → Trigger-74bd1ee8.js} +16 -0
  2. package/dist/cjs/{generate-5e7cd3f7.js → generate-7f7f7d99.js} +3 -2
  3. package/dist/cjs/{index-896ac706.js → index-7c9d0102.js} +806 -638
  4. package/dist/cjs/{index-2a5f8661.js → index-c973259c.js} +16 -0
  5. package/dist/cjs/{index-b8688617.js → index-e37f73fe.js} +89 -19
  6. package/dist/cjs/index.cjs.js +1 -1
  7. package/dist/cjs/smoothly-accordion_43.cjs.entry.js +917 -694
  8. package/dist/cjs/smoothly-calendar.cjs.entry.js +7 -7
  9. package/dist/cjs/smoothly-dialog.cjs.entry.js +1 -1
  10. package/dist/cjs/smoothly-display-amount.cjs.entry.js +2 -4
  11. package/dist/cjs/smoothly-display-demo.cjs.entry.js +1 -1
  12. package/dist/cjs/smoothly-display.cjs.entry.js +1 -1
  13. package/dist/cjs/smoothly-frame.cjs.entry.js +1 -1
  14. package/dist/cjs/smoothly-input-date-range.cjs.entry.js +1 -1
  15. package/dist/cjs/smoothly-input-date.cjs.entry.js +1 -1
  16. package/dist/cjs/smoothly-input-month.cjs.entry.js +11 -11
  17. package/dist/cjs/smoothly-input.cjs.entry.js +2 -2
  18. package/dist/cjs/smoothly-picker.cjs.entry.js +12 -17
  19. package/dist/cjs/smoothly-select.cjs.entry.js +1 -1
  20. package/dist/cjs/smoothly-table-header.cjs.entry.js +1 -1
  21. package/dist/cjs/smoothly-trigger-sink.cjs.entry.js +1 -1
  22. package/dist/cjs/smoothly-trigger-source.cjs.entry.js +1 -1
  23. package/dist/collection/components/calendar/generate.js +2 -1
  24. package/dist/collection/components/calendar/index.js +4 -4
  25. package/dist/collection/components/calendar/style.css +29 -11
  26. package/dist/collection/components/display-amount/index.js +1 -3
  27. package/dist/collection/components/input/index.js +1 -1
  28. package/dist/collection/components/input-month/index.js +8 -8
  29. package/dist/collection/components/input-month/style.css +0 -6
  30. package/dist/collection/components/picker/index.js +12 -17
  31. package/dist/collection/components/select/index.js +1 -1
  32. package/dist/collection/components/table/header/index.js +1 -1
  33. package/dist/custom-elements/index.js +943 -695
  34. package/dist/esm/{Trigger-c637fedf.js → Trigger-d7b181ec.js} +16 -0
  35. package/dist/esm/{generate-fc812e0f.js → generate-7090dc14.js} +3 -2
  36. package/dist/{smoothly/index-a7e44b28.js → esm/index-01fedb5b.js} +806 -638
  37. package/dist/esm/{index-046ba252.js → index-13251390.js} +89 -19
  38. package/dist/{smoothly/index-71e3ce99.js → esm/index-531e2f06.js} +16 -0
  39. package/dist/esm/index.js +1 -1
  40. package/dist/esm/smoothly-accordion_43.entry.js +917 -694
  41. package/dist/esm/smoothly-calendar.entry.js +7 -7
  42. package/dist/esm/smoothly-dialog.entry.js +1 -1
  43. package/dist/esm/smoothly-display-amount.entry.js +2 -4
  44. package/dist/esm/smoothly-display-demo.entry.js +1 -1
  45. package/dist/esm/smoothly-display.entry.js +1 -1
  46. package/dist/esm/smoothly-frame.entry.js +1 -1
  47. package/dist/esm/smoothly-input-date-range.entry.js +1 -1
  48. package/dist/esm/smoothly-input-date.entry.js +1 -1
  49. package/dist/esm/smoothly-input-month.entry.js +11 -11
  50. package/dist/esm/smoothly-input.entry.js +2 -2
  51. package/dist/esm/smoothly-picker.entry.js +12 -17
  52. package/dist/esm/smoothly-select.entry.js +1 -1
  53. package/dist/esm/smoothly-table-header.entry.js +1 -1
  54. package/dist/esm/smoothly-trigger-sink.entry.js +1 -1
  55. package/dist/esm/smoothly-trigger-source.entry.js +1 -1
  56. package/dist/smoothly/{generate-fc812e0f.js → generate-7090dc14.js} +3 -2
  57. package/dist/{esm/index-a7e44b28.js → smoothly/index-01fedb5b.js} +806 -638
  58. package/dist/smoothly/{index-046ba252.js → index-13251390.js} +89 -19
  59. package/dist/{esm/index-71e3ce99.js → smoothly/index-531e2f06.js} +16 -0
  60. package/dist/smoothly/index.esm.js +1 -1
  61. package/dist/smoothly/p-2cda1784.js +1 -0
  62. package/dist/smoothly/{p-24d838b1.entry.js → p-89fe12b0.entry.js} +1 -1
  63. package/dist/smoothly/p-c107b623.entry.js +1 -0
  64. package/dist/smoothly/{p-77f6d4bf.entry.js → p-e79800d9.entry.js} +1 -1
  65. package/dist/smoothly/smoothly-calendar.entry.js +7 -7
  66. package/dist/smoothly/smoothly-dialog.entry.js +1 -1
  67. package/dist/smoothly/smoothly-display-amount.entry.js +2 -4
  68. package/dist/smoothly/smoothly-display-demo.entry.js +1 -1
  69. package/dist/smoothly/smoothly-display.entry.js +1 -1
  70. package/dist/smoothly/smoothly-frame.entry.js +1 -1
  71. package/dist/smoothly/smoothly-input-date-range.entry.js +1 -1
  72. package/dist/smoothly/smoothly-input-date.entry.js +1 -1
  73. package/dist/smoothly/smoothly-input-month.entry.js +11 -11
  74. package/dist/smoothly/smoothly-input.entry.js +2 -2
  75. package/dist/smoothly/smoothly-picker.entry.js +12 -17
  76. package/dist/smoothly/smoothly-select.entry.js +1 -1
  77. package/dist/smoothly/smoothly-table-header.entry.js +1 -1
  78. package/dist/smoothly/smoothly-trigger-sink.entry.js +1 -1
  79. package/dist/smoothly/smoothly-trigger-source.entry.js +1 -1
  80. package/dist/types/components/input-month/index.d.ts +1 -1
  81. package/package.json +5 -5
  82. package/dist/smoothly/p-08ef34d4.js +0 -1
  83. package/dist/smoothly/p-bee6330e.entry.js +0 -1
@@ -4,7 +4,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  const index = require('./index-5537d93a.js');
6
6
  const Notice = require('./Notice-e43922ea.js');
7
- const Trigger = require('./Trigger-ea33b682.js');
7
+ const Trigger = require('./Trigger-74bd1ee8.js');
8
8
 
9
9
  const styleCss$z = "smoothly-accordion-item.sc-smoothly-accordion{border:1px solid rgb(var(--smoothly-dark-color));border-bottom:none}smoothly-accordion-item.sc-smoothly-accordion:first-of-type{border-top-left-radius:4px;border-top-right-radius:4px;margin-top:0.4em}smoothly-accordion-item.sc-smoothly-accordion:last-of-type{border-bottom-left-radius:4px;border-bottom-right-radius:4px;border-bottom:1px solid rgb(var(--smoothly-dark-color));margin-bottom:0.6em}smoothly-accordion-item[open].sc-smoothly-accordion{border-color:rgb(var(--smoothly-primary-color));border-bottom:1px solid rgb(var(--smoothly-primary-color))}smoothly-accordion-item[open].sc-smoothly-accordion+smoothly-accordion-item.sc-smoothly-accordion{border-top:none}";
10
10
 
@@ -16547,27 +16547,27 @@ exports.CurrencyCode = void 0;
16547
16547
 
16548
16548
  var _Date$1 = createCommonjsModule(function (module, exports) {
16549
16549
  Object.defineProperty(exports, "__esModule", { value: true });
16550
- exports.IsoDate = void 0;
16551
- (function (IsoDate) {
16550
+ exports.Date = void 0;
16551
+ (function (Date) {
16552
16552
  function is(value) {
16553
16553
  return (typeof value == "string" && /^(\d{4}-[01]\d-[0-3]\d)|(\d{4}-[01]\d-[0-3]\d)|(\d{4}-[01]\d-[0-3]\d)$/.test(value));
16554
16554
  }
16555
- IsoDate.is = is;
16555
+ Date.is = is;
16556
16556
  function parse(value, time) {
16557
- return new Date(value + (time !== null && time !== void 0 ? time : "T12:00:00.000Z"));
16557
+ return new globalThis.Date(value + (time !== null && time !== void 0 ? time : "T12:00:00.000Z"));
16558
16558
  }
16559
- IsoDate.parse = parse;
16559
+ Date.parse = parse;
16560
16560
  function create(value) {
16561
16561
  return value.toISOString().substring(0, 10);
16562
16562
  }
16563
- IsoDate.create = create;
16563
+ Date.create = create;
16564
16564
  function now() {
16565
- return create(new Date());
16565
+ return create(new globalThis.Date());
16566
16566
  }
16567
- IsoDate.now = now;
16567
+ Date.now = now;
16568
16568
  function localize(value, locale) {
16569
- const localeString = locale ? locale : Intl.DateTimeFormat().resolvedOptions().locale;
16570
- const localeOptions = {
16569
+ return (is(value) ? parse(value) : value)
16570
+ .toLocaleString(locale ? locale : Intl.DateTimeFormat().resolvedOptions().locale, {
16571
16571
  year: "numeric",
16572
16572
  month: "2-digit",
16573
16573
  day: "2-digit",
@@ -16575,11 +16575,82 @@ exports.IsoDate = void 0;
16575
16575
  minute: "2-digit",
16576
16576
  second: "2-digit",
16577
16577
  timeZone: Intl.DateTimeFormat().resolvedOptions().timeZone,
16578
- };
16579
- return (is(value) ? parse(value) : value).toLocaleString(localeString, localeOptions).substring(0, 10);
16578
+ })
16579
+ .substring(0, 10);
16580
+ }
16581
+ Date.localize = localize;
16582
+ function next(date, days = 1) {
16583
+ let result;
16584
+ if (typeof days == "number") {
16585
+ const r = parse(date);
16586
+ r.setDate(r.getDate() + days);
16587
+ result = Date.create(r);
16588
+ }
16589
+ else {
16590
+ result = date;
16591
+ if (days.years)
16592
+ result = nextYear(result, days.years);
16593
+ if (days.months)
16594
+ result = nextMonth(result, days.months);
16595
+ if (days.days)
16596
+ result = next(result, days.days);
16597
+ }
16598
+ return result;
16599
+ }
16600
+ Date.next = next;
16601
+ function previous(date, days = 1) {
16602
+ let result;
16603
+ if (typeof days == "number") {
16604
+ const r = parse(date);
16605
+ r.setDate(r.getDate() - days);
16606
+ result = Date.create(r);
16607
+ }
16608
+ else {
16609
+ result = date;
16610
+ if (days.years)
16611
+ result = previousYear(result, days.years);
16612
+ if (days.months)
16613
+ result = previousMonth(result, days.months);
16614
+ if (days.days)
16615
+ result = previous(result, days.days);
16616
+ }
16617
+ return result;
16618
+ }
16619
+ Date.previous = previous;
16620
+ function nextMonth(date, months = 1) {
16621
+ const result = parse(date);
16622
+ result.setMonth(result.getMonth() + months);
16623
+ return Date.create(result);
16624
+ }
16625
+ Date.nextMonth = nextMonth;
16626
+ function previousMonth(date, months = 1) {
16627
+ return nextMonth(date, -months);
16628
+ }
16629
+ Date.previousMonth = previousMonth;
16630
+ function nextYear(date, years = 1) {
16631
+ const result = parse(date);
16632
+ result.setFullYear(result.getFullYear() + years);
16633
+ return Date.create(result);
16634
+ }
16635
+ Date.nextYear = nextYear;
16636
+ function previousYear(date, years = 1) {
16637
+ return nextYear(date, -years);
16638
+ }
16639
+ Date.previousYear = previousYear;
16640
+ function firstOfMonth(date) {
16641
+ const result = parse(date);
16642
+ result.setDate(1);
16643
+ return Date.create(result);
16580
16644
  }
16581
- IsoDate.localize = localize;
16582
- })(exports.IsoDate || (exports.IsoDate = {}));
16645
+ Date.firstOfMonth = firstOfMonth;
16646
+ function lastOfMonth(date) {
16647
+ const result = parse(date);
16648
+ result.setMonth(result.getMonth() + 1);
16649
+ result.setDate(-1);
16650
+ return Date.create(result);
16651
+ }
16652
+ Date.lastOfMonth = lastOfMonth;
16653
+ })(exports.Date || (exports.Date = {}));
16583
16654
  //# sourceMappingURL=Date.js.map
16584
16655
  });
16585
16656
 
@@ -16606,7 +16677,7 @@ exports.DateTime = void 0;
16606
16677
  DateTime.now = now;
16607
16678
  function localize(value, locale) {
16608
16679
  const localeString = locale ? locale : Intl.DateTimeFormat().resolvedOptions().locale;
16609
- const localeOptions = {
16680
+ return (is(value) ? parse(value) : value).toLocaleString(localeString, {
16610
16681
  year: "numeric",
16611
16682
  month: "2-digit",
16612
16683
  day: "2-digit",
@@ -16614,8 +16685,7 @@ exports.DateTime = void 0;
16614
16685
  minute: "2-digit",
16615
16686
  second: "2-digit",
16616
16687
  timeZone: Intl.DateTimeFormat().resolvedOptions().timeZone,
16617
- };
16618
- return (is(value) ? parse(value) : value).toLocaleString(localeString, localeOptions);
16688
+ });
16619
16689
  }
16620
16690
  DateTime.localize = localize;
16621
16691
  })(exports.DateTime || (exports.DateTime = {}));
@@ -18362,7 +18432,7 @@ Object.defineProperty(exports, "Currency", { enumerable: true, get: function ()
18362
18432
 
18363
18433
  Object.defineProperty(exports, "CurrencyCode", { enumerable: true, get: function () { return CurrencyCode_1$2.CurrencyCode; } });
18364
18434
 
18365
- Object.defineProperty(exports, "Date", { enumerable: true, get: function () { return _Date$1.IsoDate; } });
18435
+ Object.defineProperty(exports, "Date", { enumerable: true, get: function () { return _Date$1.Date; } });
18366
18436
 
18367
18437
  Object.defineProperty(exports, "DateTime", { enumerable: true, get: function () { return DateTime_1$2.DateTime; } });
18368
18438
 
@@ -18386,7 +18456,8 @@ function month(date) {
18386
18456
  d.setDate(day++);
18387
18457
  r.push(dist$4.Date.create(d));
18388
18458
  }
18389
- result.push(r);
18459
+ if (row < 5 || dist$4.Date.firstOfMonth(r[0]) == dist$4.Date.firstOfMonth(date))
18460
+ result.push(r);
18390
18461
  }
18391
18462
  return result;
18392
18463
  }
@@ -18431,7 +18502,7 @@ function years(current) {
18431
18502
  return result;
18432
18503
  }
18433
18504
 
18434
- const styleCss$w = ".sc-smoothly-calendar-h{display:block}.sc-smoothly-calendar-h>smoothly-input-month.sc-smoothly-calendar{width:calc(100% - 1em);padding:.5em .5em 0 .5em}th.sc-smoothly-calendar,td.sc-smoothly-calendar{text-align:center;padding:.5em;min-width:2em;background-color:rgb(var(--smoothly-default-shade))}td.sc-smoothly-calendar:nth-child(6),td.sc-smoothly-calendar:nth-child(7){color:rgb(var(--smoothly-light-shade))}td.sc-smoothly-calendar:not(.selected):hover{color:rgb(var(--smoothly-primary-contrast));background:rgb(var(--smoothly-primary-tint))}td.selected.sc-smoothly-calendar{color:rgb(var(--smoothly-primary-contrast));background:rgb(var(--smoothly-primary-color))}td.sc-smoothly-calendar:not(.selected,.dateRange).sc-smoothly-calendar:not(:hover).today{background:rgb(var(--smoothly-dark-tint));color:rgb(var(--smoothly-dark-contrast))}td.dateRange.sc-smoothly-calendar{color:rgb(var(--smoothly-primary-contrast));background:rgb(var(--smoothly-primary-tint))}";
18505
+ const styleCss$w = ".sc-smoothly-calendar-h{display:block;--other-month-opacity:0.5}.sc-smoothly-calendar-h>smoothly-input-month.sc-smoothly-calendar{width:calc(100% - 1em);padding:0.5em 0.5em 0 0.5em}th.sc-smoothly-calendar,td.sc-smoothly-calendar{text-align:center;padding:0.5em;min-width:2em;background-color:rgb(var(--smoothly-default-shade));cursor:pointer;user-select:none}td.currentMonth.sc-smoothly-calendar{color:rgb(var(--smoothly-default-contrast))}td.sc-smoothly-calendar:not(.currentMonth){color:rgba(var(--smoothly-default-contrast), var(--other-month-opacity))}td.sc-smoothly-calendar:nth-child(6):not(.currentMonth).selected,td.sc-smoothly-calendar:nth-child(6):not(.currentMonth).dateRange,td.sc-smoothly-calendar:nth-child(7):not(.currentMonth).selected,td.sc-smoothly-calendar:nth-child(7):not(.currentMonth).dateRange{color:rgba(var(--smoothly-default-contrast))}td.sc-smoothly-calendar:nth-child(6),td.sc-smoothly-calendar:nth-child(7){color:rgb(var(--smoothly-danger-tint))}td.sc-smoothly-calendar:nth-child(6):not(.currentMonth),td.sc-smoothly-calendar:nth-child(7):not(.currentMonth){color:rgba(var(--smoothly-danger-tint), var(--other-month-opacity))}td.sc-smoothly-calendar:not(.selected):hover{color:rgb(var(--smoothly-primary-contrast));background:rgb(var(--smoothly-primary-tint))}td.selected.sc-smoothly-calendar{color:rgb(var(--smoothly-primary-contrast));background:rgb(var(--smoothly-primary-color))}td.sc-smoothly-calendar:not(.selected,.dateRange).sc-smoothly-calendar:not(:hover).today{background:rgb(var(--smoothly-dark-tint));color:rgb(var(--smoothly-dark-contrast))}td.dateRange.sc-smoothly-calendar{color:rgb(var(--smoothly-primary-contrast));background:rgb(var(--smoothly-primary-tint))}";
18435
18506
 
18436
18507
  const Calendar = class {
18437
18508
  constructor(hostRef) {
@@ -18456,7 +18527,7 @@ const Calendar = class {
18456
18527
  event.stopPropagation();
18457
18528
  } }),
18458
18529
  index.h("table", null, index.h("thead", null, index.h("tr", null, weekdays().map(day => (index.h("th", null, day))))), month((_b = this.month) !== null && _b !== void 0 ? _b : this.value).map(week => (index.h("tr", null, week.map(date => {
18459
- var _a, _b;
18530
+ var _a, _b, _c;
18460
18531
  return (index.h("td", { tabindex: 1, onClick: () => {
18461
18532
  this.valueChanged.emit((this.value = date));
18462
18533
  this.clickCounter += 1;
@@ -18469,9 +18540,9 @@ const Calendar = class {
18469
18540
  this.start = date;
18470
18541
  }
18471
18542
  }, class: (date == this.value ? ["selected"] : [])
18472
- .concat(...(date == dist$4.Date.now() ? ["today"] : []), date == this.value ? ["selected"] : [], this.doubleInput
18473
- ? dist$4.Date.parse(date) >= dist$4.Date.parse((_a = this.start) !== null && _a !== void 0 ? _a : "") &&
18474
- dist$4.Date.parse(date) <= dist$4.Date.parse((_b = this.end) !== null && _b !== void 0 ? _b : "")
18543
+ .concat(...(date == dist$4.Date.now() ? ["today"] : []), dist$4.Date.firstOfMonth((_a = this.month) !== null && _a !== void 0 ? _a : this.value) == dist$4.Date.firstOfMonth(date) ? ["currentMonth"] : [], this.doubleInput
18544
+ ? dist$4.Date.parse(date) >= dist$4.Date.parse((_b = this.start) !== null && _b !== void 0 ? _b : "") &&
18545
+ dist$4.Date.parse(date) <= dist$4.Date.parse((_c = this.end) !== null && _c !== void 0 ? _c : "")
18475
18546
  ? ["dateRange"]
18476
18547
  : []
18477
18548
  : "")
@@ -32361,7 +32432,7 @@ exports.CallingCode = void 0;
32361
32432
  value == "+44" ||
32362
32433
  value == "+224" ||
32363
32434
  value == "+245" ||
32364
- value == "+595" ||
32435
+ value == "+592" ||
32365
32436
  value == "+509" ||
32366
32437
  value == "+379" ||
32367
32438
  value == "+504" ||
@@ -32540,7 +32611,7 @@ exports.CallingCode = void 0;
32540
32611
  })(exports.CallingCode || (exports.CallingCode = {}));
32541
32612
  const callingCodetoAlpha2 = {
32542
32613
  "+93": "AF",
32543
- "+358": ["AX", "FI"],
32614
+ "+358": ["FI", "AX"],
32544
32615
  "+355": "AL",
32545
32616
  "+213": "DZ",
32546
32617
  "+1684": "AS",
@@ -32577,7 +32648,7 @@ const callingCodetoAlpha2 = {
32577
32648
  "+257": "BI",
32578
32649
  "+855": "KH",
32579
32650
  "+237": "CM",
32580
- "+1": ["CA", "US"],
32651
+ "+1": ["US", "CA"],
32581
32652
  "+238": "CV",
32582
32653
  "+345": "KY",
32583
32654
  "+236": "CF",
@@ -32624,10 +32695,11 @@ const callingCodetoAlpha2 = {
32624
32695
  "+590": ["GP", "BL", "MF"],
32625
32696
  "+1671": "GU",
32626
32697
  "+502": "GT",
32627
- "+44": ["GG", "GB", "IM", "JE"],
32698
+ "+44": ["GB", "JE", "IM", "GG"],
32628
32699
  "+224": "GN",
32629
32700
  "+245": "GW",
32630
- "+595": ["GY", "PY"],
32701
+ "+592": "GY",
32702
+ "+595": "PY",
32631
32703
  "+509": "HT",
32632
32704
  "+379": "VA",
32633
32705
  "+504": "HN",
@@ -32672,7 +32744,7 @@ const callingCodetoAlpha2 = {
32672
32744
  "+596": "MQ",
32673
32745
  "+222": "MR",
32674
32746
  "+230": "MU",
32675
- "+262": ["YT", "RE"],
32747
+ "+262": ["RE", "YT"],
32676
32748
  "+52": "MX",
32677
32749
  "+691": "FM",
32678
32750
  "+373": "MD",
@@ -32860,7 +32932,7 @@ const alpha2toCallingCode = {
32860
32932
  GG: "+44",
32861
32933
  GN: "+224",
32862
32934
  GW: "+245",
32863
- GY: "+595",
32935
+ GY: "+592",
32864
32936
  HT: "+509",
32865
32937
  VA: "+379",
32866
32938
  HN: "+504",
@@ -33019,264 +33091,302 @@ var Alpha2_1 = createCommonjsModule(function (module, exports) {
33019
33091
  Object.defineProperty(exports, "__esModule", { value: true });
33020
33092
  exports.Alpha2 = void 0;
33021
33093
  (function (Alpha2) {
33094
+ Alpha2.types = [
33095
+ "AF",
33096
+ "AX",
33097
+ "AL",
33098
+ "DZ",
33099
+ "AS",
33100
+ "AD",
33101
+ "AO",
33102
+ "AI",
33103
+ "AQ",
33104
+ "AG",
33105
+ "AR",
33106
+ "AM",
33107
+ "AW",
33108
+ "AU",
33109
+ "AT",
33110
+ "AZ",
33111
+ "BS",
33112
+ "BH",
33113
+ "BD",
33114
+ "BB",
33115
+ "BY",
33116
+ "BE",
33117
+ "BZ",
33118
+ "BJ",
33119
+ "BM",
33120
+ "BT",
33121
+ "BO",
33122
+ "BQ",
33123
+ "BA",
33124
+ "BW",
33125
+ "BV",
33126
+ "BR",
33127
+ "IO",
33128
+ "BN",
33129
+ "BG",
33130
+ "BF",
33131
+ "BI",
33132
+ "CV",
33133
+ "KH",
33134
+ "CM",
33135
+ "CA",
33136
+ "KY",
33137
+ "CF",
33138
+ "TD",
33139
+ "CL",
33140
+ "CN",
33141
+ "CX",
33142
+ "CC",
33143
+ "CO",
33144
+ "KM",
33145
+ "CG",
33146
+ "CD",
33147
+ "CK",
33148
+ "CR",
33149
+ "CI",
33150
+ "HR",
33151
+ "CU",
33152
+ "CW",
33153
+ "CY",
33154
+ "CZ",
33155
+ "DK",
33156
+ "DJ",
33157
+ "DM",
33158
+ "DO",
33159
+ "EC",
33160
+ "EG",
33161
+ "SV",
33162
+ "GQ",
33163
+ "ER",
33164
+ "EE",
33165
+ "SZ",
33166
+ "ET",
33167
+ "FK",
33168
+ "FO",
33169
+ "FJ",
33170
+ "FI",
33171
+ "FR",
33172
+ "GF",
33173
+ "PF",
33174
+ "TF",
33175
+ "GA",
33176
+ "GM",
33177
+ "GE",
33178
+ "DE",
33179
+ "GH",
33180
+ "GI",
33181
+ "GR",
33182
+ "GL",
33183
+ "GD",
33184
+ "GP",
33185
+ "GU",
33186
+ "GT",
33187
+ "GG",
33188
+ "GN",
33189
+ "GW",
33190
+ "GY",
33191
+ "HT",
33192
+ "HM",
33193
+ "VA",
33194
+ "HN",
33195
+ "HK",
33196
+ "HU",
33197
+ "IS",
33198
+ "IN",
33199
+ "ID",
33200
+ "IR",
33201
+ "IQ",
33202
+ "IE",
33203
+ "IM",
33204
+ "IL",
33205
+ "IT",
33206
+ "JM",
33207
+ "JP",
33208
+ "JE",
33209
+ "JO",
33210
+ "KZ",
33211
+ "KE",
33212
+ "KI",
33213
+ "KP",
33214
+ "KR",
33215
+ "KW",
33216
+ "KG",
33217
+ "LA",
33218
+ "LV",
33219
+ "LB",
33220
+ "LS",
33221
+ "LR",
33222
+ "LY",
33223
+ "LI",
33224
+ "LT",
33225
+ "LU",
33226
+ "MO",
33227
+ "MG",
33228
+ "MW",
33229
+ "MY",
33230
+ "MV",
33231
+ "ML",
33232
+ "MT",
33233
+ "MH",
33234
+ "MQ",
33235
+ "MR",
33236
+ "MU",
33237
+ "YT",
33238
+ "MX",
33239
+ "FM",
33240
+ "MD",
33241
+ "MC",
33242
+ "MN",
33243
+ "ME",
33244
+ "MS",
33245
+ "MA",
33246
+ "MZ",
33247
+ "MM",
33248
+ "NA",
33249
+ "NR",
33250
+ "NP",
33251
+ "NL",
33252
+ "NC",
33253
+ "NZ",
33254
+ "NI",
33255
+ "NE",
33256
+ "NG",
33257
+ "NU",
33258
+ "NF",
33259
+ "MK",
33260
+ "MP",
33261
+ "NO",
33262
+ "OM",
33263
+ "PK",
33264
+ "PW",
33265
+ "PS",
33266
+ "PA",
33267
+ "PG",
33268
+ "PY",
33269
+ "PE",
33270
+ "PH",
33271
+ "PN",
33272
+ "PL",
33273
+ "PT",
33274
+ "PR",
33275
+ "QA",
33276
+ "RE",
33277
+ "RO",
33278
+ "RU",
33279
+ "RW",
33280
+ "BL",
33281
+ "SH",
33282
+ "KN",
33283
+ "LC",
33284
+ "MF",
33285
+ "PM",
33286
+ "VC",
33287
+ "WS",
33288
+ "SM",
33289
+ "ST",
33290
+ "SA",
33291
+ "SN",
33292
+ "RS",
33293
+ "SC",
33294
+ "SL",
33295
+ "SG",
33296
+ "SX",
33297
+ "SK",
33298
+ "SI",
33299
+ "SB",
33300
+ "SO",
33301
+ "ZA",
33302
+ "GS",
33303
+ "SS",
33304
+ "ES",
33305
+ "LK",
33306
+ "SD",
33307
+ "SR",
33308
+ "SJ",
33309
+ "SE",
33310
+ "CH",
33311
+ "SY",
33312
+ "TW",
33313
+ "TJ",
33314
+ "TZ",
33315
+ "TH",
33316
+ "TL",
33317
+ "TG",
33318
+ "TK",
33319
+ "TO",
33320
+ "TT",
33321
+ "TN",
33322
+ "TR",
33323
+ "TM",
33324
+ "TC",
33325
+ "TV",
33326
+ "UG",
33327
+ "UA",
33328
+ "AE",
33329
+ "GB",
33330
+ "US",
33331
+ "UM",
33332
+ "UY",
33333
+ "UZ",
33334
+ "VU",
33335
+ "VE",
33336
+ "VN",
33337
+ "VG",
33338
+ "VI",
33339
+ "WF",
33340
+ "EH",
33341
+ "YE",
33342
+ "ZM",
33343
+ "ZW",
33344
+ ];
33022
33345
  function is(value) {
33023
- return (typeof value == "string" &&
33024
- value.length == 2 &&
33025
- (value == "AF" ||
33026
- value == "AX" ||
33027
- value == "AL" ||
33028
- value == "DZ" ||
33029
- value == "AS" ||
33030
- value == "AD" ||
33031
- value == "AO" ||
33032
- value == "AI" ||
33033
- value == "AQ" ||
33034
- value == "AG" ||
33035
- value == "AR" ||
33036
- value == "AM" ||
33037
- value == "AW" ||
33038
- value == "AU" ||
33039
- value == "AT" ||
33040
- value == "AZ" ||
33041
- value == "BS" ||
33042
- value == "BH" ||
33043
- value == "BD" ||
33044
- value == "BB" ||
33045
- value == "BY" ||
33046
- value == "BE" ||
33047
- value == "BZ" ||
33048
- value == "BJ" ||
33049
- value == "BM" ||
33050
- value == "BT" ||
33051
- value == "BO" ||
33052
- value == "BQ" ||
33053
- value == "BA" ||
33054
- value == "BW" ||
33055
- value == "BV" ||
33056
- value == "BR" ||
33057
- value == "IO" ||
33058
- value == "BN" ||
33059
- value == "BG" ||
33060
- value == "BF" ||
33061
- value == "BI" ||
33062
- value == "CV" ||
33063
- value == "KH" ||
33064
- value == "CM" ||
33065
- value == "CA" ||
33066
- value == "KY" ||
33067
- value == "CF" ||
33068
- value == "TD" ||
33069
- value == "CL" ||
33070
- value == "CN" ||
33071
- value == "CX" ||
33072
- value == "CC" ||
33073
- value == "CO" ||
33074
- value == "KM" ||
33075
- value == "CG" ||
33076
- value == "CD" ||
33077
- value == "CK" ||
33078
- value == "CR" ||
33079
- value == "CI" ||
33080
- value == "HR" ||
33081
- value == "CU" ||
33082
- value == "CW" ||
33083
- value == "CY" ||
33084
- value == "CZ" ||
33085
- value == "DK" ||
33086
- value == "DJ" ||
33087
- value == "DM" ||
33088
- value == "DO" ||
33089
- value == "EC" ||
33090
- value == "EG" ||
33091
- value == "SV" ||
33092
- value == "GQ" ||
33093
- value == "ER" ||
33094
- value == "EE" ||
33095
- value == "SZ" ||
33096
- value == "ET" ||
33097
- value == "FK" ||
33098
- value == "FO" ||
33099
- value == "FJ" ||
33100
- value == "FI" ||
33101
- value == "FR" ||
33102
- value == "GF" ||
33103
- value == "PF" ||
33104
- value == "TF" ||
33105
- value == "GA" ||
33106
- value == "GM" ||
33107
- value == "GE" ||
33108
- value == "DE" ||
33109
- value == "GH" ||
33110
- value == "GI" ||
33111
- value == "GR" ||
33112
- value == "GL" ||
33113
- value == "GD" ||
33114
- value == "GP" ||
33115
- value == "GU" ||
33116
- value == "GT" ||
33117
- value == "GG" ||
33118
- value == "GN" ||
33119
- value == "GW" ||
33120
- value == "GY" ||
33121
- value == "HT" ||
33122
- value == "HM" ||
33123
- value == "VA" ||
33124
- value == "HN" ||
33125
- value == "HK" ||
33126
- value == "HU" ||
33127
- value == "IS" ||
33128
- value == "IN" ||
33129
- value == "ID" ||
33130
- value == "IR" ||
33131
- value == "IQ" ||
33132
- value == "IE" ||
33133
- value == "IM" ||
33134
- value == "IL" ||
33135
- value == "IT" ||
33136
- value == "JM" ||
33137
- value == "JP" ||
33138
- value == "JE" ||
33139
- value == "JO" ||
33140
- value == "KZ" ||
33141
- value == "KE" ||
33142
- value == "KI" ||
33143
- value == "KP" ||
33144
- value == "KR" ||
33145
- value == "KW" ||
33146
- value == "KG" ||
33147
- value == "LA" ||
33148
- value == "LV" ||
33149
- value == "LB" ||
33150
- value == "LS" ||
33151
- value == "LR" ||
33152
- value == "LY" ||
33153
- value == "LI" ||
33154
- value == "LT" ||
33155
- value == "LU" ||
33156
- value == "MO" ||
33157
- value == "MG" ||
33158
- value == "MW" ||
33159
- value == "MY" ||
33160
- value == "MV" ||
33161
- value == "ML" ||
33162
- value == "MT" ||
33163
- value == "MH" ||
33164
- value == "MQ" ||
33165
- value == "MR" ||
33166
- value == "MU" ||
33167
- value == "YT" ||
33168
- value == "MX" ||
33169
- value == "FM" ||
33170
- value == "MD" ||
33171
- value == "MC" ||
33172
- value == "MN" ||
33173
- value == "ME" ||
33174
- value == "MS" ||
33175
- value == "MA" ||
33176
- value == "MZ" ||
33177
- value == "MM" ||
33178
- value == "NA" ||
33179
- value == "NR" ||
33180
- value == "NP" ||
33181
- value == "NL" ||
33182
- value == "NC" ||
33183
- value == "NZ" ||
33184
- value == "NI" ||
33185
- value == "NE" ||
33186
- value == "NG" ||
33187
- value == "NU" ||
33188
- value == "NF" ||
33189
- value == "MK" ||
33190
- value == "MP" ||
33191
- value == "NO" ||
33192
- value == "OM" ||
33193
- value == "PK" ||
33194
- value == "PW" ||
33195
- value == "PS" ||
33196
- value == "PA" ||
33197
- value == "PG" ||
33198
- value == "PY" ||
33199
- value == "PE" ||
33200
- value == "PH" ||
33201
- value == "PN" ||
33202
- value == "PL" ||
33203
- value == "PT" ||
33204
- value == "PR" ||
33205
- value == "QA" ||
33206
- value == "RE" ||
33207
- value == "RO" ||
33208
- value == "RU" ||
33209
- value == "RW" ||
33210
- value == "BL" ||
33211
- value == "SH" ||
33212
- value == "KN" ||
33213
- value == "LC" ||
33214
- value == "MF" ||
33215
- value == "PM" ||
33216
- value == "VC" ||
33217
- value == "WS" ||
33218
- value == "SM" ||
33219
- value == "ST" ||
33220
- value == "SA" ||
33221
- value == "SN" ||
33222
- value == "RS" ||
33223
- value == "SC" ||
33224
- value == "SL" ||
33225
- value == "SG" ||
33226
- value == "SX" ||
33227
- value == "SK" ||
33228
- value == "SI" ||
33229
- value == "SB" ||
33230
- value == "SO" ||
33231
- value == "ZA" ||
33232
- value == "GS" ||
33233
- value == "SS" ||
33234
- value == "ES" ||
33235
- value == "LK" ||
33236
- value == "SD" ||
33237
- value == "SR" ||
33238
- value == "SJ" ||
33239
- value == "SE" ||
33240
- value == "CH" ||
33241
- value == "SY" ||
33242
- value == "TW" ||
33243
- value == "TJ" ||
33244
- value == "TZ" ||
33245
- value == "TH" ||
33246
- value == "TL" ||
33247
- value == "TG" ||
33248
- value == "TK" ||
33249
- value == "TO" ||
33250
- value == "TT" ||
33251
- value == "TN" ||
33252
- value == "TR" ||
33253
- value == "TM" ||
33254
- value == "TC" ||
33255
- value == "TV" ||
33256
- value == "UG" ||
33257
- value == "UA" ||
33258
- value == "AE" ||
33259
- value == "GB" ||
33260
- value == "US" ||
33261
- value == "UM" ||
33262
- value == "UY" ||
33263
- value == "UZ" ||
33264
- value == "VU" ||
33265
- value == "VE" ||
33266
- value == "VN" ||
33267
- value == "VG" ||
33268
- value == "VI" ||
33269
- value == "WF" ||
33270
- value == "EH" ||
33271
- value == "YE" ||
33272
- value == "ZM" ||
33273
- value == "ZW"));
33346
+ return Alpha2.types.includes(value);
33274
33347
  }
33275
33348
  Alpha2.is = is;
33276
33349
  function from(country) {
33277
33350
  return typeof country == "number" ? numericToAlpha2[country.toString()] : alpha3ToAlpha2[country];
33278
33351
  }
33279
33352
  Alpha2.from = from;
33353
+ function isEEA(country) {
33354
+ return [
33355
+ "AL",
33356
+ "AT",
33357
+ "BA",
33358
+ "BE",
33359
+ "BG",
33360
+ "CH",
33361
+ "CY",
33362
+ "DE",
33363
+ "DK",
33364
+ "EE",
33365
+ "ES",
33366
+ "FI",
33367
+ "FR",
33368
+ "GB",
33369
+ "GR",
33370
+ "HR",
33371
+ "HU",
33372
+ "IE",
33373
+ "IS",
33374
+ "IT",
33375
+ "LT",
33376
+ "LV",
33377
+ "MK",
33378
+ "MT",
33379
+ "NL",
33380
+ "NO",
33381
+ "PL",
33382
+ "PT",
33383
+ "RO",
33384
+ "RS",
33385
+ "SE",
33386
+ "SI",
33387
+ ].includes(country);
33388
+ }
33389
+ Alpha2.isEEA = isEEA;
33280
33390
  })(exports.Alpha2 || (exports.Alpha2 = {}));
33281
33391
  const numericToAlpha2 = {
33282
33392
  "4": "AF",
@@ -47496,187 +47606,189 @@ var Currency_1 = createCommonjsModule(function (module, exports) {
47496
47606
  Object.defineProperty(exports, "__esModule", { value: true });
47497
47607
  exports.Currency = void 0;
47498
47608
  (function (Currency) {
47609
+ Currency.types = [
47610
+ "AED",
47611
+ "AFN",
47612
+ "ALL",
47613
+ "AMD",
47614
+ "ANG",
47615
+ "AOA",
47616
+ "ARS",
47617
+ "AUD",
47618
+ "AWG",
47619
+ "AZN",
47620
+ "BAM",
47621
+ "BBD",
47622
+ "BDT",
47623
+ "BGN",
47624
+ "BHD",
47625
+ "BIF",
47626
+ "BMD",
47627
+ "BND",
47628
+ "BOB",
47629
+ "BOV",
47630
+ "BRL",
47631
+ "BSD",
47632
+ "BTN",
47633
+ "BWP",
47634
+ "BYN",
47635
+ "BZD",
47636
+ "CAD",
47637
+ "CDF",
47638
+ "CHE",
47639
+ "CHF",
47640
+ "CHW",
47641
+ "CLF",
47642
+ "CLP",
47643
+ "CNY",
47644
+ "COP",
47645
+ "COU",
47646
+ "CRC",
47647
+ "CUC",
47648
+ "CUP",
47649
+ "CVE",
47650
+ "CZK",
47651
+ "DJF",
47652
+ "DKK",
47653
+ "DOP",
47654
+ "DZD",
47655
+ "EGP",
47656
+ "ERN",
47657
+ "ETB",
47658
+ "EUR",
47659
+ "FJD",
47660
+ "FKP",
47661
+ "GBP",
47662
+ "GEL",
47663
+ "GHS",
47664
+ "GIP",
47665
+ "GMD",
47666
+ "GNF",
47667
+ "GTQ",
47668
+ "GYD",
47669
+ "HKD",
47670
+ "HNL",
47671
+ "HRK",
47672
+ "HTG",
47673
+ "HUF",
47674
+ "IDR",
47675
+ "ILS",
47676
+ "INR",
47677
+ "IQD",
47678
+ "IRR",
47679
+ "ISK",
47680
+ "JMD",
47681
+ "JOD",
47682
+ "JPY",
47683
+ "KES",
47684
+ "KGS",
47685
+ "KHR",
47686
+ "KMF",
47687
+ "KPW",
47688
+ "KRW",
47689
+ "KWD",
47690
+ "KYD",
47691
+ "KZT",
47692
+ "LAK",
47693
+ "LBP",
47694
+ "LKR",
47695
+ "LRD",
47696
+ "LSL",
47697
+ "LYD",
47698
+ "MAD",
47699
+ "MDL",
47700
+ "MGA",
47701
+ "MKD",
47702
+ "MMK",
47703
+ "MNT",
47704
+ "MOP",
47705
+ "MRU",
47706
+ "MUR",
47707
+ "MVR",
47708
+ "MWK",
47709
+ "MXN",
47710
+ "MXV",
47711
+ "MYR",
47712
+ "MZN",
47713
+ "NAD",
47714
+ "NGN",
47715
+ "NIO",
47716
+ "NOK",
47717
+ "NPR",
47718
+ "NZD",
47719
+ "OMR",
47720
+ "PAB",
47721
+ "PEN",
47722
+ "PGK",
47723
+ "PHP",
47724
+ "PKR",
47725
+ "PLN",
47726
+ "PYG",
47727
+ "QAR",
47728
+ "RON",
47729
+ "RSD",
47730
+ "RUB",
47731
+ "RWF",
47732
+ "SAR",
47733
+ "SBD",
47734
+ "SCR",
47735
+ "SDG",
47736
+ "SEK",
47737
+ "SGD",
47738
+ "SHP",
47739
+ "SLL",
47740
+ "SOS",
47741
+ "SRD",
47742
+ "SSP",
47743
+ "STN",
47744
+ "SVC",
47745
+ "SYP",
47746
+ "SZL",
47747
+ "THB",
47748
+ "TJS",
47749
+ "TMT",
47750
+ "TND",
47751
+ "TOP",
47752
+ "TRY",
47753
+ "TTD",
47754
+ "TWD",
47755
+ "TZS",
47756
+ "UAH",
47757
+ "UGX",
47758
+ "USD",
47759
+ "USN",
47760
+ "UYI",
47761
+ "UYU",
47762
+ "UYW",
47763
+ "UZS",
47764
+ "VES",
47765
+ "VND",
47766
+ "VUV",
47767
+ "WST",
47768
+ "XAF",
47769
+ "XAG",
47770
+ "XAU",
47771
+ "XBA",
47772
+ "XBB",
47773
+ "XBC",
47774
+ "XBD",
47775
+ "XCD",
47776
+ "XDR",
47777
+ "XOF",
47778
+ "XPD",
47779
+ "XPF",
47780
+ "XPT",
47781
+ "XSU",
47782
+ "XTS",
47783
+ "XUA",
47784
+ "XXX",
47785
+ "YER",
47786
+ "ZAR",
47787
+ "ZMW",
47788
+ "ZWL",
47789
+ ];
47499
47790
  function is(currency) {
47500
- return (typeof currency == "string" &&
47501
- (currency == "AED" ||
47502
- currency == "AFN" ||
47503
- currency == "ALL" ||
47504
- currency == "AMD" ||
47505
- currency == "ANG" ||
47506
- currency == "AOA" ||
47507
- currency == "ARS" ||
47508
- currency == "AUD" ||
47509
- currency == "AWG" ||
47510
- currency == "AZN" ||
47511
- currency == "BAM" ||
47512
- currency == "BBD" ||
47513
- currency == "BDT" ||
47514
- currency == "BGN" ||
47515
- currency == "BHD" ||
47516
- currency == "BIF" ||
47517
- currency == "BMD" ||
47518
- currency == "BND" ||
47519
- currency == "BOB" ||
47520
- currency == "BOV" ||
47521
- currency == "BRL" ||
47522
- currency == "BSD" ||
47523
- currency == "BTN" ||
47524
- currency == "BWP" ||
47525
- currency == "BYN" ||
47526
- currency == "BZD" ||
47527
- currency == "CAD" ||
47528
- currency == "CDF" ||
47529
- currency == "CHE" ||
47530
- currency == "CHF" ||
47531
- currency == "CHW" ||
47532
- currency == "CLF" ||
47533
- currency == "CLP" ||
47534
- currency == "CNY" ||
47535
- currency == "COP" ||
47536
- currency == "COU" ||
47537
- currency == "CRC" ||
47538
- currency == "CUC" ||
47539
- currency == "CUP" ||
47540
- currency == "CVE" ||
47541
- currency == "CZK" ||
47542
- currency == "DJF" ||
47543
- currency == "DKK" ||
47544
- currency == "DOP" ||
47545
- currency == "DZD" ||
47546
- currency == "EGP" ||
47547
- currency == "ERN" ||
47548
- currency == "ETB" ||
47549
- currency == "EUR" ||
47550
- currency == "FJD" ||
47551
- currency == "FKP" ||
47552
- currency == "GBP" ||
47553
- currency == "GEL" ||
47554
- currency == "GHS" ||
47555
- currency == "GIP" ||
47556
- currency == "GMD" ||
47557
- currency == "GNF" ||
47558
- currency == "GTQ" ||
47559
- currency == "GYD" ||
47560
- currency == "HKD" ||
47561
- currency == "HNL" ||
47562
- currency == "HRK" ||
47563
- currency == "HTG" ||
47564
- currency == "HUF" ||
47565
- currency == "IDR" ||
47566
- currency == "ILS" ||
47567
- currency == "INR" ||
47568
- currency == "IQD" ||
47569
- currency == "IRR" ||
47570
- currency == "ISK" ||
47571
- currency == "JMD" ||
47572
- currency == "JOD" ||
47573
- currency == "JPY" ||
47574
- currency == "KES" ||
47575
- currency == "KGS" ||
47576
- currency == "KHR" ||
47577
- currency == "KMF" ||
47578
- currency == "KPW" ||
47579
- currency == "KRW" ||
47580
- currency == "KWD" ||
47581
- currency == "KYD" ||
47582
- currency == "KZT" ||
47583
- currency == "LAK" ||
47584
- currency == "LBP" ||
47585
- currency == "LKR" ||
47586
- currency == "LRD" ||
47587
- currency == "LSL" ||
47588
- currency == "LYD" ||
47589
- currency == "MAD" ||
47590
- currency == "MDL" ||
47591
- currency == "MGA" ||
47592
- currency == "MKD" ||
47593
- currency == "MMK" ||
47594
- currency == "MNT" ||
47595
- currency == "MOP" ||
47596
- currency == "MRU" ||
47597
- currency == "MUR" ||
47598
- currency == "MVR" ||
47599
- currency == "MWK" ||
47600
- currency == "MXN" ||
47601
- currency == "MXV" ||
47602
- currency == "MYR" ||
47603
- currency == "MZN" ||
47604
- currency == "NAD" ||
47605
- currency == "NGN" ||
47606
- currency == "NIO" ||
47607
- currency == "NOK" ||
47608
- currency == "NPR" ||
47609
- currency == "NZD" ||
47610
- currency == "OMR" ||
47611
- currency == "PAB" ||
47612
- currency == "PEN" ||
47613
- currency == "PGK" ||
47614
- currency == "PHP" ||
47615
- currency == "PKR" ||
47616
- currency == "PLN" ||
47617
- currency == "PYG" ||
47618
- currency == "QAR" ||
47619
- currency == "RON" ||
47620
- currency == "RSD" ||
47621
- currency == "RUB" ||
47622
- currency == "RWF" ||
47623
- currency == "SAR" ||
47624
- currency == "SBD" ||
47625
- currency == "SCR" ||
47626
- currency == "SDG" ||
47627
- currency == "SEK" ||
47628
- currency == "SGD" ||
47629
- currency == "SHP" ||
47630
- currency == "SLL" ||
47631
- currency == "SOS" ||
47632
- currency == "SRD" ||
47633
- currency == "SSP" ||
47634
- currency == "STN" ||
47635
- currency == "SVC" ||
47636
- currency == "SYP" ||
47637
- currency == "SZL" ||
47638
- currency == "THB" ||
47639
- currency == "TJS" ||
47640
- currency == "TMT" ||
47641
- currency == "TND" ||
47642
- currency == "TOP" ||
47643
- currency == "TRY" ||
47644
- currency == "TTD" ||
47645
- currency == "TWD" ||
47646
- currency == "TZS" ||
47647
- currency == "UAH" ||
47648
- currency == "UGX" ||
47649
- currency == "USD" ||
47650
- currency == "USN" ||
47651
- currency == "UYI" ||
47652
- currency == "UYU" ||
47653
- currency == "UYW" ||
47654
- currency == "UZS" ||
47655
- currency == "VES" ||
47656
- currency == "VND" ||
47657
- currency == "VUV" ||
47658
- currency == "WST" ||
47659
- currency == "XAF" ||
47660
- currency == "XAG" ||
47661
- currency == "XAU" ||
47662
- currency == "XBA" ||
47663
- currency == "XBB" ||
47664
- currency == "XBC" ||
47665
- currency == "XBD" ||
47666
- currency == "XCD" ||
47667
- currency == "XDR" ||
47668
- currency == "XOF" ||
47669
- currency == "XPD" ||
47670
- currency == "XPF" ||
47671
- currency == "XPT" ||
47672
- currency == "XSU" ||
47673
- currency == "XTS" ||
47674
- currency == "XUA" ||
47675
- currency == "XXX" ||
47676
- currency == "YER" ||
47677
- currency == "ZAR" ||
47678
- currency == "ZMW" ||
47679
- currency == "ZWL"));
47791
+ return Currency.types.includes(currency);
47680
47792
  }
47681
47793
  Currency.is = is;
47682
47794
  function from(currencyCode) {
@@ -47863,6 +47975,12 @@ exports.Currency = void 0;
47863
47975
  }[currencyCode];
47864
47976
  }
47865
47977
  Currency.from = from;
47978
+ function round(value, currency) {
47979
+ var _a;
47980
+ const factor = Math.pow(10, (_a = decimalDigits(currency)) !== null && _a !== void 0 ? _a : 2);
47981
+ return Math.round((value + Number.EPSILON) * factor) / factor;
47982
+ }
47983
+ Currency.round = round;
47866
47984
  function decimalDigits(currency) {
47867
47985
  return {
47868
47986
  AED: 2,
@@ -48055,187 +48173,189 @@ var CurrencyCode_1 = createCommonjsModule(function (module, exports) {
48055
48173
  Object.defineProperty(exports, "__esModule", { value: true });
48056
48174
  exports.CurrencyCode = void 0;
48057
48175
  (function (CurrencyCode) {
48176
+ CurrencyCode.types = [
48177
+ "008",
48178
+ "012",
48179
+ "032",
48180
+ "036",
48181
+ "044",
48182
+ "048",
48183
+ "050",
48184
+ "051",
48185
+ "052",
48186
+ "060",
48187
+ "064",
48188
+ "068",
48189
+ "072",
48190
+ "084",
48191
+ "090",
48192
+ "096",
48193
+ "104",
48194
+ "108",
48195
+ "116",
48196
+ "124",
48197
+ "132",
48198
+ "136",
48199
+ "144",
48200
+ "152",
48201
+ "156",
48202
+ "170",
48203
+ "174",
48204
+ "188",
48205
+ "191",
48206
+ "192",
48207
+ "203",
48208
+ "208",
48209
+ "214",
48210
+ "222",
48211
+ "230",
48212
+ "232",
48213
+ "238",
48214
+ "242",
48215
+ "262",
48216
+ "270",
48217
+ "292",
48218
+ "320",
48219
+ "324",
48220
+ "328",
48221
+ "332",
48222
+ "340",
48223
+ "344",
48224
+ "348",
48225
+ "352",
48226
+ "356",
48227
+ "360",
48228
+ "364",
48229
+ "368",
48230
+ "376",
48231
+ "388",
48232
+ "392",
48233
+ "398",
48234
+ "400",
48235
+ "404",
48236
+ "408",
48237
+ "410",
48238
+ "414",
48239
+ "417",
48240
+ "418",
48241
+ "422",
48242
+ "426",
48243
+ "430",
48244
+ "434",
48245
+ "446",
48246
+ "454",
48247
+ "458",
48248
+ "462",
48249
+ "480",
48250
+ "484",
48251
+ "496",
48252
+ "498",
48253
+ "504",
48254
+ "512",
48255
+ "516",
48256
+ "524",
48257
+ "532",
48258
+ "533",
48259
+ "548",
48260
+ "554",
48261
+ "558",
48262
+ "566",
48263
+ "578",
48264
+ "586",
48265
+ "590",
48266
+ "598",
48267
+ "600",
48268
+ "604",
48269
+ "608",
48270
+ "634",
48271
+ "643",
48272
+ "646",
48273
+ "654",
48274
+ "682",
48275
+ "690",
48276
+ "694",
48277
+ "702",
48278
+ "704",
48279
+ "706",
48280
+ "710",
48281
+ "728",
48282
+ "748",
48283
+ "752",
48284
+ "756",
48285
+ "760",
48286
+ "764",
48287
+ "776",
48288
+ "780",
48289
+ "784",
48290
+ "788",
48291
+ "800",
48292
+ "807",
48293
+ "818",
48294
+ "826",
48295
+ "834",
48296
+ "840",
48297
+ "858",
48298
+ "860",
48299
+ "882",
48300
+ "886",
48301
+ "901",
48302
+ "927",
48303
+ "928",
48304
+ "929",
48305
+ "930",
48306
+ "931",
48307
+ "932",
48308
+ "933",
48309
+ "934",
48310
+ "936",
48311
+ "938",
48312
+ "940",
48313
+ "941",
48314
+ "943",
48315
+ "944",
48316
+ "946",
48317
+ "947",
48318
+ "948",
48319
+ "949",
48320
+ "950",
48321
+ "951",
48322
+ "952",
48323
+ "953",
48324
+ "955",
48325
+ "956",
48326
+ "957",
48327
+ "958",
48328
+ "959",
48329
+ "960",
48330
+ "961",
48331
+ "962",
48332
+ "963",
48333
+ "964",
48334
+ "965",
48335
+ "967",
48336
+ "968",
48337
+ "969",
48338
+ "970",
48339
+ "971",
48340
+ "972",
48341
+ "973",
48342
+ "975",
48343
+ "976",
48344
+ "977",
48345
+ "978",
48346
+ "979",
48347
+ "980",
48348
+ "981",
48349
+ "984",
48350
+ "985",
48351
+ "986",
48352
+ "990",
48353
+ "994",
48354
+ "997",
48355
+ "999",
48356
+ ];
48058
48357
  function is(value) {
48059
- return (typeof value == "string" &&
48060
- (value == "008" ||
48061
- value == "012" ||
48062
- value == "032" ||
48063
- value == "036" ||
48064
- value == "044" ||
48065
- value == "048" ||
48066
- value == "050" ||
48067
- value == "051" ||
48068
- value == "052" ||
48069
- value == "060" ||
48070
- value == "064" ||
48071
- value == "068" ||
48072
- value == "072" ||
48073
- value == "084" ||
48074
- value == "090" ||
48075
- value == "096" ||
48076
- value == "104" ||
48077
- value == "108" ||
48078
- value == "116" ||
48079
- value == "124" ||
48080
- value == "132" ||
48081
- value == "136" ||
48082
- value == "144" ||
48083
- value == "152" ||
48084
- value == "156" ||
48085
- value == "170" ||
48086
- value == "174" ||
48087
- value == "188" ||
48088
- value == "191" ||
48089
- value == "192" ||
48090
- value == "203" ||
48091
- value == "208" ||
48092
- value == "214" ||
48093
- value == "222" ||
48094
- value == "230" ||
48095
- value == "232" ||
48096
- value == "238" ||
48097
- value == "242" ||
48098
- value == "262" ||
48099
- value == "270" ||
48100
- value == "292" ||
48101
- value == "320" ||
48102
- value == "324" ||
48103
- value == "328" ||
48104
- value == "332" ||
48105
- value == "340" ||
48106
- value == "344" ||
48107
- value == "348" ||
48108
- value == "352" ||
48109
- value == "356" ||
48110
- value == "360" ||
48111
- value == "364" ||
48112
- value == "368" ||
48113
- value == "376" ||
48114
- value == "388" ||
48115
- value == "392" ||
48116
- value == "398" ||
48117
- value == "400" ||
48118
- value == "404" ||
48119
- value == "408" ||
48120
- value == "410" ||
48121
- value == "414" ||
48122
- value == "417" ||
48123
- value == "418" ||
48124
- value == "422" ||
48125
- value == "426" ||
48126
- value == "430" ||
48127
- value == "434" ||
48128
- value == "446" ||
48129
- value == "454" ||
48130
- value == "458" ||
48131
- value == "462" ||
48132
- value == "480" ||
48133
- value == "484" ||
48134
- value == "496" ||
48135
- value == "498" ||
48136
- value == "504" ||
48137
- value == "512" ||
48138
- value == "516" ||
48139
- value == "524" ||
48140
- value == "532" ||
48141
- value == "533" ||
48142
- value == "548" ||
48143
- value == "554" ||
48144
- value == "558" ||
48145
- value == "566" ||
48146
- value == "578" ||
48147
- value == "586" ||
48148
- value == "590" ||
48149
- value == "598" ||
48150
- value == "600" ||
48151
- value == "604" ||
48152
- value == "608" ||
48153
- value == "634" ||
48154
- value == "643" ||
48155
- value == "646" ||
48156
- value == "654" ||
48157
- value == "682" ||
48158
- value == "690" ||
48159
- value == "694" ||
48160
- value == "702" ||
48161
- value == "704" ||
48162
- value == "706" ||
48163
- value == "710" ||
48164
- value == "728" ||
48165
- value == "748" ||
48166
- value == "752" ||
48167
- value == "756" ||
48168
- value == "760" ||
48169
- value == "764" ||
48170
- value == "776" ||
48171
- value == "780" ||
48172
- value == "784" ||
48173
- value == "788" ||
48174
- value == "800" ||
48175
- value == "807" ||
48176
- value == "818" ||
48177
- value == "826" ||
48178
- value == "834" ||
48179
- value == "840" ||
48180
- value == "858" ||
48181
- value == "860" ||
48182
- value == "882" ||
48183
- value == "886" ||
48184
- value == "901" ||
48185
- value == "927" ||
48186
- value == "928" ||
48187
- value == "929" ||
48188
- value == "930" ||
48189
- value == "931" ||
48190
- value == "932" ||
48191
- value == "933" ||
48192
- value == "934" ||
48193
- value == "936" ||
48194
- value == "938" ||
48195
- value == "940" ||
48196
- value == "941" ||
48197
- value == "943" ||
48198
- value == "944" ||
48199
- value == "946" ||
48200
- value == "947" ||
48201
- value == "948" ||
48202
- value == "949" ||
48203
- value == "950" ||
48204
- value == "951" ||
48205
- value == "952" ||
48206
- value == "953" ||
48207
- value == "955" ||
48208
- value == "956" ||
48209
- value == "957" ||
48210
- value == "958" ||
48211
- value == "959" ||
48212
- value == "960" ||
48213
- value == "961" ||
48214
- value == "962" ||
48215
- value == "963" ||
48216
- value == "964" ||
48217
- value == "965" ||
48218
- value == "967" ||
48219
- value == "968" ||
48220
- value == "969" ||
48221
- value == "970" ||
48222
- value == "971" ||
48223
- value == "972" ||
48224
- value == "973" ||
48225
- value == "975" ||
48226
- value == "976" ||
48227
- value == "977" ||
48228
- value == "978" ||
48229
- value == "979" ||
48230
- value == "980" ||
48231
- value == "981" ||
48232
- value == "984" ||
48233
- value == "985" ||
48234
- value == "986" ||
48235
- value == "990" ||
48236
- value == "994" ||
48237
- value == "997" ||
48238
- value == "999"));
48358
+ return CurrencyCode.types.includes(value);
48239
48359
  }
48240
48360
  CurrencyCode.is = is;
48241
48361
  function from(currency) {
@@ -48612,27 +48732,27 @@ exports.CurrencyCode = void 0;
48612
48732
 
48613
48733
  var _Date = createCommonjsModule(function (module, exports) {
48614
48734
  Object.defineProperty(exports, "__esModule", { value: true });
48615
- exports.IsoDate = void 0;
48616
- (function (IsoDate) {
48735
+ exports.Date = void 0;
48736
+ (function (Date) {
48617
48737
  function is(value) {
48618
48738
  return (typeof value == "string" && /^(\d{4}-[01]\d-[0-3]\d)|(\d{4}-[01]\d-[0-3]\d)|(\d{4}-[01]\d-[0-3]\d)$/.test(value));
48619
48739
  }
48620
- IsoDate.is = is;
48740
+ Date.is = is;
48621
48741
  function parse(value, time) {
48622
- return new Date(value + (time !== null && time !== void 0 ? time : "T12:00:00.000Z"));
48742
+ return new globalThis.Date(value + (time !== null && time !== void 0 ? time : "T12:00:00.000Z"));
48623
48743
  }
48624
- IsoDate.parse = parse;
48744
+ Date.parse = parse;
48625
48745
  function create(value) {
48626
48746
  return value.toISOString().substring(0, 10);
48627
48747
  }
48628
- IsoDate.create = create;
48748
+ Date.create = create;
48629
48749
  function now() {
48630
- return create(new Date());
48750
+ return create(new globalThis.Date());
48631
48751
  }
48632
- IsoDate.now = now;
48752
+ Date.now = now;
48633
48753
  function localize(value, locale) {
48634
- const localeString = locale ? locale : Intl.DateTimeFormat().resolvedOptions().locale;
48635
- const localeOptions = {
48754
+ return (is(value) ? parse(value) : value)
48755
+ .toLocaleString(locale ? locale : Intl.DateTimeFormat().resolvedOptions().locale, {
48636
48756
  year: "numeric",
48637
48757
  month: "2-digit",
48638
48758
  day: "2-digit",
@@ -48640,14 +48760,121 @@ exports.IsoDate = void 0;
48640
48760
  minute: "2-digit",
48641
48761
  second: "2-digit",
48642
48762
  timeZone: Intl.DateTimeFormat().resolvedOptions().timeZone,
48643
- };
48644
- return (is(value) ? parse(value) : value).toLocaleString(localeString, localeOptions).substring(0, 10);
48763
+ })
48764
+ .substring(0, 10);
48765
+ }
48766
+ Date.localize = localize;
48767
+ function next(date, days = 1) {
48768
+ let result;
48769
+ if (typeof days == "number") {
48770
+ const r = parse(date);
48771
+ r.setDate(r.getDate() + days);
48772
+ result = Date.create(r);
48773
+ }
48774
+ else {
48775
+ result = date;
48776
+ if (days.years)
48777
+ result = nextYear(result, days.years);
48778
+ if (days.months)
48779
+ result = nextMonth(result, days.months);
48780
+ if (days.days)
48781
+ result = next(result, days.days);
48782
+ }
48783
+ return result;
48784
+ }
48785
+ Date.next = next;
48786
+ function previous(date, days = 1) {
48787
+ let result;
48788
+ if (typeof days == "number") {
48789
+ const r = parse(date);
48790
+ r.setDate(r.getDate() - days);
48791
+ result = Date.create(r);
48792
+ }
48793
+ else {
48794
+ result = date;
48795
+ if (days.years)
48796
+ result = previousYear(result, days.years);
48797
+ if (days.months)
48798
+ result = previousMonth(result, days.months);
48799
+ if (days.days)
48800
+ result = previous(result, days.days);
48801
+ }
48802
+ return result;
48803
+ }
48804
+ Date.previous = previous;
48805
+ function nextMonth(date, months = 1) {
48806
+ const result = parse(date);
48807
+ result.setMonth(result.getMonth() + months);
48808
+ return Date.create(result);
48645
48809
  }
48646
- IsoDate.localize = localize;
48647
- })(exports.IsoDate || (exports.IsoDate = {}));
48810
+ Date.nextMonth = nextMonth;
48811
+ function previousMonth(date, months = 1) {
48812
+ return nextMonth(date, -months);
48813
+ }
48814
+ Date.previousMonth = previousMonth;
48815
+ function nextYear(date, years = 1) {
48816
+ const result = parse(date);
48817
+ result.setFullYear(result.getFullYear() + years);
48818
+ return Date.create(result);
48819
+ }
48820
+ Date.nextYear = nextYear;
48821
+ function previousYear(date, years = 1) {
48822
+ return nextYear(date, -years);
48823
+ }
48824
+ Date.previousYear = previousYear;
48825
+ function firstOfMonth(date) {
48826
+ const result = parse(date);
48827
+ result.setDate(1);
48828
+ return Date.create(result);
48829
+ }
48830
+ Date.firstOfMonth = firstOfMonth;
48831
+ function lastOfMonth(date) {
48832
+ const result = parse(date);
48833
+ result.setMonth(result.getMonth() + 1);
48834
+ result.setDate(-1);
48835
+ return Date.create(result);
48836
+ }
48837
+ Date.lastOfMonth = lastOfMonth;
48838
+ })(exports.Date || (exports.Date = {}));
48648
48839
  //# sourceMappingURL=Date.js.map
48649
48840
  });
48650
48841
 
48842
+ var DateRange_1 = createCommonjsModule(function (module, exports) {
48843
+ Object.defineProperty(exports, "__esModule", { value: true });
48844
+ exports.DateRange = void 0;
48845
+ (function (DateRange) {
48846
+ function is(value) {
48847
+ return typeof value == "object" && _Date.Date.is(value.start) && _Date.Date.is(value.end);
48848
+ }
48849
+ DateRange.is = is;
48850
+ function create(start, end) {
48851
+ return !_Date.Date.is(end)
48852
+ ? create(start, _Date.Date.next(start, end))
48853
+ : start <= end
48854
+ ? { start, end }
48855
+ : { start: end, end: start };
48856
+ }
48857
+ DateRange.create = create;
48858
+ })(exports.DateRange || (exports.DateRange = {}));
48859
+ //# sourceMappingURL=DateRange.js.map
48860
+ });
48861
+
48862
+ var DateSpan_1 = createCommonjsModule(function (module, exports) {
48863
+ Object.defineProperty(exports, "__esModule", { value: true });
48864
+ exports.DateSpan = void 0;
48865
+ (function (DateSpan) {
48866
+ function is(value) {
48867
+ return (typeof value == "object" &&
48868
+ (typeof value.years == "number" || value.years == undefined) &&
48869
+ (typeof value.months == "number" || value.months == undefined) &&
48870
+ (typeof value.days == "number" || value.days == undefined) &&
48871
+ (typeof value.years == "number" || typeof value.months == "number" || typeof value.days == "number"));
48872
+ }
48873
+ DateSpan.is = is;
48874
+ })(exports.DateSpan || (exports.DateSpan = {}));
48875
+ //# sourceMappingURL=DateSpan.js.map
48876
+ });
48877
+
48651
48878
  var DateTime_1 = createCommonjsModule(function (module, exports) {
48652
48879
  Object.defineProperty(exports, "__esModule", { value: true });
48653
48880
  exports.DateTime = void 0;
@@ -48671,7 +48898,7 @@ exports.DateTime = void 0;
48671
48898
  DateTime.now = now;
48672
48899
  function localize(value, locale) {
48673
48900
  const localeString = locale ? locale : Intl.DateTimeFormat().resolvedOptions().locale;
48674
- const localeOptions = {
48901
+ return (is(value) ? parse(value) : value).toLocaleString(localeString, {
48675
48902
  year: "numeric",
48676
48903
  month: "2-digit",
48677
48904
  day: "2-digit",
@@ -48679,8 +48906,7 @@ exports.DateTime = void 0;
48679
48906
  minute: "2-digit",
48680
48907
  second: "2-digit",
48681
48908
  timeZone: Intl.DateTimeFormat().resolvedOptions().timeZone,
48682
- };
48683
- return (is(value) ? parse(value) : value).toLocaleString(localeString, localeOptions);
48909
+ });
48684
48910
  }
48685
48911
  DateTime.localize = localize;
48686
48912
  })(exports.DateTime || (exports.DateTime = {}));
@@ -50417,7 +50643,7 @@ var __importStar = (commonjsGlobal && commonjsGlobal.__importStar) || function (
50417
50643
  return result;
50418
50644
  };
50419
50645
  Object.defineProperty(exports, "__esModule", { value: true });
50420
- exports.Locale = exports.Language = exports.Encoding = exports.DateTime = exports.Date = exports.CurrencyCode = exports.Currency = exports.CountryCode = exports.CallingCode = void 0;
50646
+ exports.Locale = exports.Language = exports.Encoding = exports.DateTime = exports.Date = exports.DateSpan = exports.DateRange = exports.CurrencyCode = exports.Currency = exports.CountryCode = exports.CallingCode = void 0;
50421
50647
 
50422
50648
  Object.defineProperty(exports, "CallingCode", { enumerable: true, get: function () { return CallingCode_1.CallingCode; } });
50423
50649
  const CountryCode$1 = __importStar(CountryCode);
@@ -50427,7 +50653,11 @@ Object.defineProperty(exports, "Currency", { enumerable: true, get: function ()
50427
50653
 
50428
50654
  Object.defineProperty(exports, "CurrencyCode", { enumerable: true, get: function () { return CurrencyCode_1.CurrencyCode; } });
50429
50655
 
50430
- Object.defineProperty(exports, "Date", { enumerable: true, get: function () { return _Date.IsoDate; } });
50656
+ Object.defineProperty(exports, "Date", { enumerable: true, get: function () { return _Date.Date; } });
50657
+
50658
+ Object.defineProperty(exports, "DateRange", { enumerable: true, get: function () { return DateRange_1.DateRange; } });
50659
+
50660
+ Object.defineProperty(exports, "DateSpan", { enumerable: true, get: function () { return DateSpan_1.DateSpan; } });
50431
50661
 
50432
50662
  Object.defineProperty(exports, "DateTime", { enumerable: true, get: function () { return DateTime_1.DateTime; } });
50433
50663
 
@@ -51310,9 +51540,7 @@ const SmoothlyDisplayAmount = class {
51310
51540
  format(amount) {
51311
51541
  const digitsPerGroup = 3;
51312
51542
  const defaultDecimals = 2;
51313
- const maxDecimals = (dist$4.Currency.decimalDigits(this.currency)
51314
- ? dist$4.Currency.decimalDigits(this.currency)
51315
- : defaultDecimals);
51543
+ const maxDecimals = (dist$4.Currency.decimalDigits(this.currency) ? dist$4.Currency.decimalDigits(this.currency) : defaultDecimals);
51316
51544
  let beforeSeparator = amount.length;
51317
51545
  let separator;
51318
51546
  let result = amount;
@@ -52034,7 +52262,7 @@ const SmoothlyInput = class {
52034
52262
  end: backend.selectionEnd != undefined ? backend.selectionEnd : backend.value.length,
52035
52263
  direction: backend.selectionDirection ? backend.selectionDirection : "none",
52036
52264
  } });
52037
- if ((!(event.ctrlKey && event.key == "v") && event.key.length == 1) ||
52265
+ if ((!((event.ctrlKey || event.metaKey) && event.key == "v") && event.key.length == 1) ||
52038
52266
  event.key == "ArrowLeft" ||
52039
52267
  event.key == "ArrowRight" ||
52040
52268
  event.key == "Delete" ||
@@ -52173,7 +52401,7 @@ const SmoothlyInputDemo = class {
52173
52401
  }
52174
52402
  };
52175
52403
 
52176
- const styleCss$k = ".sc-smoothly-input-month-h{display:flex;justify-content:space-between;font-size:large}button.sc-smoothly-input-month{border:none;background:none;cursor:pointer;font-size:large}smoothly-icon.sc-smoothly-input-month{font-size:smaller}";
52404
+ const styleCss$k = ".sc-smoothly-input-month-h{display:flex;justify-content:space-between;font-size:large}smoothly-icon.sc-smoothly-input-month{font-size:smaller}";
52177
52405
 
52178
52406
  const MonthSelector = class {
52179
52407
  constructor(hostRef) {
@@ -52183,21 +52411,21 @@ const MonthSelector = class {
52183
52411
  onValueChanged(next) {
52184
52412
  this.valueChanged.emit(next);
52185
52413
  }
52414
+ adjustMonth(delta) {
52415
+ var _a;
52416
+ const date = dist$4.Date.parse((_a = this.value) !== null && _a !== void 0 ? _a : dist$4.Date.now());
52417
+ date.setMonth(date.getMonth() + delta);
52418
+ this.value = dist$4.Date.create(date);
52419
+ }
52186
52420
  render() {
52187
52421
  var _a, _b;
52188
52422
  return [
52189
- index.h("button", { onClick: () => this.adjustMonth(-1) }, index.h("smoothly-icon", { name: "chevron-back-outline", size: "small" })),
52423
+ index.h("div", { onClick: () => this.adjustMonth(-1) }, index.h("smoothly-icon", { name: "chevron-back-outline", size: "small" })),
52190
52424
  index.h("smoothly-selector", { onSelected: (e) => (this.value = e.detail) }, years((_a = this.value) !== null && _a !== void 0 ? _a : dist$4.Date.now()).map(year => (index.h("smoothly-item", { value: year.date, selected: year.selected }, year.name)))),
52191
52425
  index.h("smoothly-selector", { onSelected: (e) => (this.value = e.detail) }, months((_b = this.value) !== null && _b !== void 0 ? _b : dist$4.Date.now()).map(month => (index.h("smoothly-item", { value: month.date, selected: month.selected }, month.name)))),
52192
- index.h("button", { onClick: () => this.adjustMonth(1) }, index.h("smoothly-icon", { name: "chevron-forward-outline", size: "small" })),
52426
+ index.h("div", { onClick: () => this.adjustMonth(1) }, index.h("smoothly-icon", { name: "chevron-forward-outline", size: "small" })),
52193
52427
  ];
52194
52428
  }
52195
- adjustMonth(delta) {
52196
- var _a;
52197
- const date = dist$4.Date.parse((_a = this.value) !== null && _a !== void 0 ? _a : dist$4.Date.now());
52198
- date.setMonth(date.getMonth() + delta);
52199
- this.value = dist$4.Date.create(date);
52200
- }
52201
52429
  static get watchers() { return {
52202
52430
  "value": ["onValueChanged"]
52203
52431
  }; }
@@ -52484,14 +52712,11 @@ const SmoothlyPicker = class {
52484
52712
  : this.select(option);
52485
52713
  }
52486
52714
  clearSelection() {
52487
- var _a;
52488
52715
  this.selections = [];
52489
52716
  this.inputElement.focus();
52490
52717
  this.keepFocusOnReRender = true;
52491
- (_a = this.options) === null || _a === void 0 ? void 0 : _a.forEach(option => (option.description = ""));
52492
52718
  }
52493
52719
  unselect(selection) {
52494
- var _a;
52495
52720
  const index = this.selections.map(selection => selection.value).indexOf(selection.value);
52496
52721
  if (index != -1) {
52497
52722
  this.selections = [
@@ -52500,12 +52725,8 @@ const SmoothlyPicker = class {
52500
52725
  ];
52501
52726
  this.keepFocusOnReRender = true;
52502
52727
  }
52503
- const optionIndex = (_a = this.options) === null || _a === void 0 ? void 0 : _a.map(s => s.value).indexOf(selection.value);
52504
- if (optionIndex != -1)
52505
- this.options[optionIndex].description = "";
52506
52728
  }
52507
52729
  select(selection) {
52508
- var _a;
52509
52730
  const isNewSelection = this.selections.reduce((acc, current) => acc && current.value != selection.value, true);
52510
52731
  if (isNewSelection)
52511
52732
  this.selections = this.multiple ? [...this.selections, selection] : [selection];
@@ -52513,8 +52734,6 @@ const SmoothlyPicker = class {
52513
52734
  this.filterOptions();
52514
52735
  this.keepFocusOnReRender = true;
52515
52736
  this.isOpen = this.multiple;
52516
- (_a = this.options) === null || _a === void 0 ? void 0 : _a.forEach(option => (option.description =
52517
- option.value == selection.value ? this.getCheckHtml() : this.multiple ? option.description : ""));
52518
52737
  }
52519
52738
  toggleHighlighted() {
52520
52739
  var _a;
@@ -52574,14 +52793,18 @@ const SmoothlyPicker = class {
52574
52793
  "--max-height": (_a = this.maxHeight) !== null && _a !== void 0 ? _a : "inherit",
52575
52794
  "--label-display": this.labelSetting == "hide" ? "none" : "absolute",
52576
52795
  };
52577
- return (index.h(index.Host, { style: cssVariables, "has-selection": this.selections.length > 0, "is-open": this.isOpen ? "" : undefined, onMouseDown: (e) => e.preventDefault(), onClick: () => this.onClick() }, index.h("div", null, index.h("label", null, this.label), index.h("input", { type: "text", ref: (el) => (this.inputElement = el ? el : this.inputElement), onFocus: () => this.highlightDefault(), onBlur: () => this.onBlur(), placeholder: this.selections.map(selection => selection.name).join(", "), onKeyDown: e => this.onKeyDown(e), onInput: (e) => this.onInput(e) })), index.h("smoothly-menu-options", { style: { width: "100%" }, optionStyle: Object.assign({ padding: "0 1em", height: "2.5em" }, this.optionStyle), order: false, emptyMenuLabel: this.emptyMenuLabel, "max-menu-height": this.maxMenuHeight, ref: (el) => (this.menuElement = el !== null && el !== void 0 ? el : this.menuElement), onClick: e => e.stopPropagation(), resetHighlightOnOptionsChange: false, options: [
52578
- {
52579
- value: "select-none",
52580
- name: this.selectNoneName,
52581
- description: this.selections.length == 0 ? this.getCheckHtml() : "",
52582
- },
52583
- ...((_b = this.options) !== null && _b !== void 0 ? _b : []),
52584
- ] })));
52796
+ this.options.forEach(o => {
52797
+ o.description = this.selections.map(s => s.value).includes(o.value) ? this.getCheckHtml() : "";
52798
+ });
52799
+ const options = [
52800
+ {
52801
+ value: "select-none",
52802
+ name: this.selectNoneName,
52803
+ description: this.selections.length == 0 ? this.getCheckHtml() : "",
52804
+ },
52805
+ ...((_b = this.options) !== null && _b !== void 0 ? _b : []),
52806
+ ];
52807
+ return (index.h(index.Host, { style: cssVariables, "has-selection": this.selections.length > 0, "is-open": this.isOpen ? "" : undefined, onMouseDown: (e) => e.preventDefault(), onClick: () => this.onClick() }, index.h("div", null, index.h("label", null, this.label), index.h("input", { type: "text", ref: (el) => (this.inputElement = el ? el : this.inputElement), onFocus: () => this.highlightDefault(), onBlur: () => this.onBlur(), placeholder: this.selections.map(selection => selection.name).join(", "), onKeyDown: e => this.onKeyDown(e), onInput: (e) => this.onInput(e) })), index.h("smoothly-menu-options", { style: { width: "100%" }, optionStyle: Object.assign({ padding: "0 1em", height: "2.5em" }, this.optionStyle), order: false, emptyMenuLabel: this.emptyMenuLabel, "max-menu-height": this.maxMenuHeight, ref: (el) => (this.menuElement = el !== null && el !== void 0 ? el : this.menuElement), onClick: e => e.stopPropagation(), resetHighlightOnOptionsChange: false, options: options })));
52585
52808
  }
52586
52809
  get element() { return index.getElement(this); }
52587
52810
  static get watchers() { return {
@@ -52661,7 +52884,7 @@ const SmoothlySelect = class {
52661
52884
  }
52662
52885
  optionSelected() {
52663
52886
  if (this.selectElement)
52664
- this.selectionChanged.emit({ identifier: this.identifier, value: this.value = this.selectElement.value });
52887
+ this.selectionChanged.emit({ identifier: this.identifier, value: (this.value = this.selectElement.value) });
52665
52888
  }
52666
52889
  componentDidLoad() {
52667
52890
  var _a;
@@ -53025,7 +53248,7 @@ const TableHeader = class {
53025
53248
  onClick(event) {
53026
53249
  this.sort.emit({
53027
53250
  property: this.name,
53028
- direction: this.sortDirection = this.sortDirection == "ascending" ? "descending" : "ascending",
53251
+ direction: (this.sortDirection = this.sortDirection == "ascending" ? "descending" : "ascending"),
53029
53252
  });
53030
53253
  console.log("sort", this.name, this.sortDirection);
53031
53254
  event.preventDefault();