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
@@ -1,6 +1,6 @@
1
1
  import { r as registerInstance, h, a as getElement, c as createEvent, H as Host } from './index-9d550804.js';
2
2
  import { A as App, N as Notice } from './Notice-966edc54.js';
3
- import { T as Trigger, M as Message } from './Trigger-c637fedf.js';
3
+ import { T as Trigger, M as Message } from './Trigger-d7b181ec.js';
4
4
 
5
5
  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}";
6
6
 
@@ -16543,27 +16543,27 @@ exports.CurrencyCode = void 0;
16543
16543
 
16544
16544
  var _Date$1 = createCommonjsModule(function (module, exports) {
16545
16545
  Object.defineProperty(exports, "__esModule", { value: true });
16546
- exports.IsoDate = void 0;
16547
- (function (IsoDate) {
16546
+ exports.Date = void 0;
16547
+ (function (Date) {
16548
16548
  function is(value) {
16549
16549
  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));
16550
16550
  }
16551
- IsoDate.is = is;
16551
+ Date.is = is;
16552
16552
  function parse(value, time) {
16553
- return new Date(value + (time !== null && time !== void 0 ? time : "T12:00:00.000Z"));
16553
+ return new globalThis.Date(value + (time !== null && time !== void 0 ? time : "T12:00:00.000Z"));
16554
16554
  }
16555
- IsoDate.parse = parse;
16555
+ Date.parse = parse;
16556
16556
  function create(value) {
16557
16557
  return value.toISOString().substring(0, 10);
16558
16558
  }
16559
- IsoDate.create = create;
16559
+ Date.create = create;
16560
16560
  function now() {
16561
- return create(new Date());
16561
+ return create(new globalThis.Date());
16562
16562
  }
16563
- IsoDate.now = now;
16563
+ Date.now = now;
16564
16564
  function localize(value, locale) {
16565
- const localeString = locale ? locale : Intl.DateTimeFormat().resolvedOptions().locale;
16566
- const localeOptions = {
16565
+ return (is(value) ? parse(value) : value)
16566
+ .toLocaleString(locale ? locale : Intl.DateTimeFormat().resolvedOptions().locale, {
16567
16567
  year: "numeric",
16568
16568
  month: "2-digit",
16569
16569
  day: "2-digit",
@@ -16571,11 +16571,82 @@ exports.IsoDate = void 0;
16571
16571
  minute: "2-digit",
16572
16572
  second: "2-digit",
16573
16573
  timeZone: Intl.DateTimeFormat().resolvedOptions().timeZone,
16574
- };
16575
- return (is(value) ? parse(value) : value).toLocaleString(localeString, localeOptions).substring(0, 10);
16574
+ })
16575
+ .substring(0, 10);
16576
+ }
16577
+ Date.localize = localize;
16578
+ function next(date, days = 1) {
16579
+ let result;
16580
+ if (typeof days == "number") {
16581
+ const r = parse(date);
16582
+ r.setDate(r.getDate() + days);
16583
+ result = Date.create(r);
16584
+ }
16585
+ else {
16586
+ result = date;
16587
+ if (days.years)
16588
+ result = nextYear(result, days.years);
16589
+ if (days.months)
16590
+ result = nextMonth(result, days.months);
16591
+ if (days.days)
16592
+ result = next(result, days.days);
16593
+ }
16594
+ return result;
16595
+ }
16596
+ Date.next = next;
16597
+ function previous(date, days = 1) {
16598
+ let result;
16599
+ if (typeof days == "number") {
16600
+ const r = parse(date);
16601
+ r.setDate(r.getDate() - days);
16602
+ result = Date.create(r);
16603
+ }
16604
+ else {
16605
+ result = date;
16606
+ if (days.years)
16607
+ result = previousYear(result, days.years);
16608
+ if (days.months)
16609
+ result = previousMonth(result, days.months);
16610
+ if (days.days)
16611
+ result = previous(result, days.days);
16612
+ }
16613
+ return result;
16614
+ }
16615
+ Date.previous = previous;
16616
+ function nextMonth(date, months = 1) {
16617
+ const result = parse(date);
16618
+ result.setMonth(result.getMonth() + months);
16619
+ return Date.create(result);
16620
+ }
16621
+ Date.nextMonth = nextMonth;
16622
+ function previousMonth(date, months = 1) {
16623
+ return nextMonth(date, -months);
16624
+ }
16625
+ Date.previousMonth = previousMonth;
16626
+ function nextYear(date, years = 1) {
16627
+ const result = parse(date);
16628
+ result.setFullYear(result.getFullYear() + years);
16629
+ return Date.create(result);
16630
+ }
16631
+ Date.nextYear = nextYear;
16632
+ function previousYear(date, years = 1) {
16633
+ return nextYear(date, -years);
16634
+ }
16635
+ Date.previousYear = previousYear;
16636
+ function firstOfMonth(date) {
16637
+ const result = parse(date);
16638
+ result.setDate(1);
16639
+ return Date.create(result);
16576
16640
  }
16577
- IsoDate.localize = localize;
16578
- })(exports.IsoDate || (exports.IsoDate = {}));
16641
+ Date.firstOfMonth = firstOfMonth;
16642
+ function lastOfMonth(date) {
16643
+ const result = parse(date);
16644
+ result.setMonth(result.getMonth() + 1);
16645
+ result.setDate(-1);
16646
+ return Date.create(result);
16647
+ }
16648
+ Date.lastOfMonth = lastOfMonth;
16649
+ })(exports.Date || (exports.Date = {}));
16579
16650
  //# sourceMappingURL=Date.js.map
16580
16651
  });
16581
16652
 
@@ -16602,7 +16673,7 @@ exports.DateTime = void 0;
16602
16673
  DateTime.now = now;
16603
16674
  function localize(value, locale) {
16604
16675
  const localeString = locale ? locale : Intl.DateTimeFormat().resolvedOptions().locale;
16605
- const localeOptions = {
16676
+ return (is(value) ? parse(value) : value).toLocaleString(localeString, {
16606
16677
  year: "numeric",
16607
16678
  month: "2-digit",
16608
16679
  day: "2-digit",
@@ -16610,8 +16681,7 @@ exports.DateTime = void 0;
16610
16681
  minute: "2-digit",
16611
16682
  second: "2-digit",
16612
16683
  timeZone: Intl.DateTimeFormat().resolvedOptions().timeZone,
16613
- };
16614
- return (is(value) ? parse(value) : value).toLocaleString(localeString, localeOptions);
16684
+ });
16615
16685
  }
16616
16686
  DateTime.localize = localize;
16617
16687
  })(exports.DateTime || (exports.DateTime = {}));
@@ -18358,7 +18428,7 @@ Object.defineProperty(exports, "Currency", { enumerable: true, get: function ()
18358
18428
 
18359
18429
  Object.defineProperty(exports, "CurrencyCode", { enumerable: true, get: function () { return CurrencyCode_1$2.CurrencyCode; } });
18360
18430
 
18361
- Object.defineProperty(exports, "Date", { enumerable: true, get: function () { return _Date$1.IsoDate; } });
18431
+ Object.defineProperty(exports, "Date", { enumerable: true, get: function () { return _Date$1.Date; } });
18362
18432
 
18363
18433
  Object.defineProperty(exports, "DateTime", { enumerable: true, get: function () { return DateTime_1$2.DateTime; } });
18364
18434
 
@@ -18382,7 +18452,8 @@ function month(date) {
18382
18452
  d.setDate(day++);
18383
18453
  r.push(dist$4.Date.create(d));
18384
18454
  }
18385
- result.push(r);
18455
+ if (row < 5 || dist$4.Date.firstOfMonth(r[0]) == dist$4.Date.firstOfMonth(date))
18456
+ result.push(r);
18386
18457
  }
18387
18458
  return result;
18388
18459
  }
@@ -18427,7 +18498,7 @@ function years(current) {
18427
18498
  return result;
18428
18499
  }
18429
18500
 
18430
- 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))}";
18501
+ 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))}";
18431
18502
 
18432
18503
  const Calendar = class {
18433
18504
  constructor(hostRef) {
@@ -18452,7 +18523,7 @@ const Calendar = class {
18452
18523
  event.stopPropagation();
18453
18524
  } }),
18454
18525
  h("table", null, h("thead", null, h("tr", null, weekdays().map(day => (h("th", null, day))))), month((_b = this.month) !== null && _b !== void 0 ? _b : this.value).map(week => (h("tr", null, week.map(date => {
18455
- var _a, _b;
18526
+ var _a, _b, _c;
18456
18527
  return (h("td", { tabindex: 1, onClick: () => {
18457
18528
  this.valueChanged.emit((this.value = date));
18458
18529
  this.clickCounter += 1;
@@ -18465,9 +18536,9 @@ const Calendar = class {
18465
18536
  this.start = date;
18466
18537
  }
18467
18538
  }, class: (date == this.value ? ["selected"] : [])
18468
- .concat(...(date == dist$4.Date.now() ? ["today"] : []), date == this.value ? ["selected"] : [], this.doubleInput
18469
- ? dist$4.Date.parse(date) >= dist$4.Date.parse((_a = this.start) !== null && _a !== void 0 ? _a : "") &&
18470
- dist$4.Date.parse(date) <= dist$4.Date.parse((_b = this.end) !== null && _b !== void 0 ? _b : "")
18539
+ .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
18540
+ ? dist$4.Date.parse(date) >= dist$4.Date.parse((_b = this.start) !== null && _b !== void 0 ? _b : "") &&
18541
+ dist$4.Date.parse(date) <= dist$4.Date.parse((_c = this.end) !== null && _c !== void 0 ? _c : "")
18471
18542
  ? ["dateRange"]
18472
18543
  : []
18473
18544
  : "")
@@ -32357,7 +32428,7 @@ exports.CallingCode = void 0;
32357
32428
  value == "+44" ||
32358
32429
  value == "+224" ||
32359
32430
  value == "+245" ||
32360
- value == "+595" ||
32431
+ value == "+592" ||
32361
32432
  value == "+509" ||
32362
32433
  value == "+379" ||
32363
32434
  value == "+504" ||
@@ -32536,7 +32607,7 @@ exports.CallingCode = void 0;
32536
32607
  })(exports.CallingCode || (exports.CallingCode = {}));
32537
32608
  const callingCodetoAlpha2 = {
32538
32609
  "+93": "AF",
32539
- "+358": ["AX", "FI"],
32610
+ "+358": ["FI", "AX"],
32540
32611
  "+355": "AL",
32541
32612
  "+213": "DZ",
32542
32613
  "+1684": "AS",
@@ -32573,7 +32644,7 @@ const callingCodetoAlpha2 = {
32573
32644
  "+257": "BI",
32574
32645
  "+855": "KH",
32575
32646
  "+237": "CM",
32576
- "+1": ["CA", "US"],
32647
+ "+1": ["US", "CA"],
32577
32648
  "+238": "CV",
32578
32649
  "+345": "KY",
32579
32650
  "+236": "CF",
@@ -32620,10 +32691,11 @@ const callingCodetoAlpha2 = {
32620
32691
  "+590": ["GP", "BL", "MF"],
32621
32692
  "+1671": "GU",
32622
32693
  "+502": "GT",
32623
- "+44": ["GG", "GB", "IM", "JE"],
32694
+ "+44": ["GB", "JE", "IM", "GG"],
32624
32695
  "+224": "GN",
32625
32696
  "+245": "GW",
32626
- "+595": ["GY", "PY"],
32697
+ "+592": "GY",
32698
+ "+595": "PY",
32627
32699
  "+509": "HT",
32628
32700
  "+379": "VA",
32629
32701
  "+504": "HN",
@@ -32668,7 +32740,7 @@ const callingCodetoAlpha2 = {
32668
32740
  "+596": "MQ",
32669
32741
  "+222": "MR",
32670
32742
  "+230": "MU",
32671
- "+262": ["YT", "RE"],
32743
+ "+262": ["RE", "YT"],
32672
32744
  "+52": "MX",
32673
32745
  "+691": "FM",
32674
32746
  "+373": "MD",
@@ -32856,7 +32928,7 @@ const alpha2toCallingCode = {
32856
32928
  GG: "+44",
32857
32929
  GN: "+224",
32858
32930
  GW: "+245",
32859
- GY: "+595",
32931
+ GY: "+592",
32860
32932
  HT: "+509",
32861
32933
  VA: "+379",
32862
32934
  HN: "+504",
@@ -33015,264 +33087,302 @@ var Alpha2_1 = createCommonjsModule(function (module, exports) {
33015
33087
  Object.defineProperty(exports, "__esModule", { value: true });
33016
33088
  exports.Alpha2 = void 0;
33017
33089
  (function (Alpha2) {
33090
+ Alpha2.types = [
33091
+ "AF",
33092
+ "AX",
33093
+ "AL",
33094
+ "DZ",
33095
+ "AS",
33096
+ "AD",
33097
+ "AO",
33098
+ "AI",
33099
+ "AQ",
33100
+ "AG",
33101
+ "AR",
33102
+ "AM",
33103
+ "AW",
33104
+ "AU",
33105
+ "AT",
33106
+ "AZ",
33107
+ "BS",
33108
+ "BH",
33109
+ "BD",
33110
+ "BB",
33111
+ "BY",
33112
+ "BE",
33113
+ "BZ",
33114
+ "BJ",
33115
+ "BM",
33116
+ "BT",
33117
+ "BO",
33118
+ "BQ",
33119
+ "BA",
33120
+ "BW",
33121
+ "BV",
33122
+ "BR",
33123
+ "IO",
33124
+ "BN",
33125
+ "BG",
33126
+ "BF",
33127
+ "BI",
33128
+ "CV",
33129
+ "KH",
33130
+ "CM",
33131
+ "CA",
33132
+ "KY",
33133
+ "CF",
33134
+ "TD",
33135
+ "CL",
33136
+ "CN",
33137
+ "CX",
33138
+ "CC",
33139
+ "CO",
33140
+ "KM",
33141
+ "CG",
33142
+ "CD",
33143
+ "CK",
33144
+ "CR",
33145
+ "CI",
33146
+ "HR",
33147
+ "CU",
33148
+ "CW",
33149
+ "CY",
33150
+ "CZ",
33151
+ "DK",
33152
+ "DJ",
33153
+ "DM",
33154
+ "DO",
33155
+ "EC",
33156
+ "EG",
33157
+ "SV",
33158
+ "GQ",
33159
+ "ER",
33160
+ "EE",
33161
+ "SZ",
33162
+ "ET",
33163
+ "FK",
33164
+ "FO",
33165
+ "FJ",
33166
+ "FI",
33167
+ "FR",
33168
+ "GF",
33169
+ "PF",
33170
+ "TF",
33171
+ "GA",
33172
+ "GM",
33173
+ "GE",
33174
+ "DE",
33175
+ "GH",
33176
+ "GI",
33177
+ "GR",
33178
+ "GL",
33179
+ "GD",
33180
+ "GP",
33181
+ "GU",
33182
+ "GT",
33183
+ "GG",
33184
+ "GN",
33185
+ "GW",
33186
+ "GY",
33187
+ "HT",
33188
+ "HM",
33189
+ "VA",
33190
+ "HN",
33191
+ "HK",
33192
+ "HU",
33193
+ "IS",
33194
+ "IN",
33195
+ "ID",
33196
+ "IR",
33197
+ "IQ",
33198
+ "IE",
33199
+ "IM",
33200
+ "IL",
33201
+ "IT",
33202
+ "JM",
33203
+ "JP",
33204
+ "JE",
33205
+ "JO",
33206
+ "KZ",
33207
+ "KE",
33208
+ "KI",
33209
+ "KP",
33210
+ "KR",
33211
+ "KW",
33212
+ "KG",
33213
+ "LA",
33214
+ "LV",
33215
+ "LB",
33216
+ "LS",
33217
+ "LR",
33218
+ "LY",
33219
+ "LI",
33220
+ "LT",
33221
+ "LU",
33222
+ "MO",
33223
+ "MG",
33224
+ "MW",
33225
+ "MY",
33226
+ "MV",
33227
+ "ML",
33228
+ "MT",
33229
+ "MH",
33230
+ "MQ",
33231
+ "MR",
33232
+ "MU",
33233
+ "YT",
33234
+ "MX",
33235
+ "FM",
33236
+ "MD",
33237
+ "MC",
33238
+ "MN",
33239
+ "ME",
33240
+ "MS",
33241
+ "MA",
33242
+ "MZ",
33243
+ "MM",
33244
+ "NA",
33245
+ "NR",
33246
+ "NP",
33247
+ "NL",
33248
+ "NC",
33249
+ "NZ",
33250
+ "NI",
33251
+ "NE",
33252
+ "NG",
33253
+ "NU",
33254
+ "NF",
33255
+ "MK",
33256
+ "MP",
33257
+ "NO",
33258
+ "OM",
33259
+ "PK",
33260
+ "PW",
33261
+ "PS",
33262
+ "PA",
33263
+ "PG",
33264
+ "PY",
33265
+ "PE",
33266
+ "PH",
33267
+ "PN",
33268
+ "PL",
33269
+ "PT",
33270
+ "PR",
33271
+ "QA",
33272
+ "RE",
33273
+ "RO",
33274
+ "RU",
33275
+ "RW",
33276
+ "BL",
33277
+ "SH",
33278
+ "KN",
33279
+ "LC",
33280
+ "MF",
33281
+ "PM",
33282
+ "VC",
33283
+ "WS",
33284
+ "SM",
33285
+ "ST",
33286
+ "SA",
33287
+ "SN",
33288
+ "RS",
33289
+ "SC",
33290
+ "SL",
33291
+ "SG",
33292
+ "SX",
33293
+ "SK",
33294
+ "SI",
33295
+ "SB",
33296
+ "SO",
33297
+ "ZA",
33298
+ "GS",
33299
+ "SS",
33300
+ "ES",
33301
+ "LK",
33302
+ "SD",
33303
+ "SR",
33304
+ "SJ",
33305
+ "SE",
33306
+ "CH",
33307
+ "SY",
33308
+ "TW",
33309
+ "TJ",
33310
+ "TZ",
33311
+ "TH",
33312
+ "TL",
33313
+ "TG",
33314
+ "TK",
33315
+ "TO",
33316
+ "TT",
33317
+ "TN",
33318
+ "TR",
33319
+ "TM",
33320
+ "TC",
33321
+ "TV",
33322
+ "UG",
33323
+ "UA",
33324
+ "AE",
33325
+ "GB",
33326
+ "US",
33327
+ "UM",
33328
+ "UY",
33329
+ "UZ",
33330
+ "VU",
33331
+ "VE",
33332
+ "VN",
33333
+ "VG",
33334
+ "VI",
33335
+ "WF",
33336
+ "EH",
33337
+ "YE",
33338
+ "ZM",
33339
+ "ZW",
33340
+ ];
33018
33341
  function is(value) {
33019
- return (typeof value == "string" &&
33020
- value.length == 2 &&
33021
- (value == "AF" ||
33022
- value == "AX" ||
33023
- value == "AL" ||
33024
- value == "DZ" ||
33025
- value == "AS" ||
33026
- value == "AD" ||
33027
- value == "AO" ||
33028
- value == "AI" ||
33029
- value == "AQ" ||
33030
- value == "AG" ||
33031
- value == "AR" ||
33032
- value == "AM" ||
33033
- value == "AW" ||
33034
- value == "AU" ||
33035
- value == "AT" ||
33036
- value == "AZ" ||
33037
- value == "BS" ||
33038
- value == "BH" ||
33039
- value == "BD" ||
33040
- value == "BB" ||
33041
- value == "BY" ||
33042
- value == "BE" ||
33043
- value == "BZ" ||
33044
- value == "BJ" ||
33045
- value == "BM" ||
33046
- value == "BT" ||
33047
- value == "BO" ||
33048
- value == "BQ" ||
33049
- value == "BA" ||
33050
- value == "BW" ||
33051
- value == "BV" ||
33052
- value == "BR" ||
33053
- value == "IO" ||
33054
- value == "BN" ||
33055
- value == "BG" ||
33056
- value == "BF" ||
33057
- value == "BI" ||
33058
- value == "CV" ||
33059
- value == "KH" ||
33060
- value == "CM" ||
33061
- value == "CA" ||
33062
- value == "KY" ||
33063
- value == "CF" ||
33064
- value == "TD" ||
33065
- value == "CL" ||
33066
- value == "CN" ||
33067
- value == "CX" ||
33068
- value == "CC" ||
33069
- value == "CO" ||
33070
- value == "KM" ||
33071
- value == "CG" ||
33072
- value == "CD" ||
33073
- value == "CK" ||
33074
- value == "CR" ||
33075
- value == "CI" ||
33076
- value == "HR" ||
33077
- value == "CU" ||
33078
- value == "CW" ||
33079
- value == "CY" ||
33080
- value == "CZ" ||
33081
- value == "DK" ||
33082
- value == "DJ" ||
33083
- value == "DM" ||
33084
- value == "DO" ||
33085
- value == "EC" ||
33086
- value == "EG" ||
33087
- value == "SV" ||
33088
- value == "GQ" ||
33089
- value == "ER" ||
33090
- value == "EE" ||
33091
- value == "SZ" ||
33092
- value == "ET" ||
33093
- value == "FK" ||
33094
- value == "FO" ||
33095
- value == "FJ" ||
33096
- value == "FI" ||
33097
- value == "FR" ||
33098
- value == "GF" ||
33099
- value == "PF" ||
33100
- value == "TF" ||
33101
- value == "GA" ||
33102
- value == "GM" ||
33103
- value == "GE" ||
33104
- value == "DE" ||
33105
- value == "GH" ||
33106
- value == "GI" ||
33107
- value == "GR" ||
33108
- value == "GL" ||
33109
- value == "GD" ||
33110
- value == "GP" ||
33111
- value == "GU" ||
33112
- value == "GT" ||
33113
- value == "GG" ||
33114
- value == "GN" ||
33115
- value == "GW" ||
33116
- value == "GY" ||
33117
- value == "HT" ||
33118
- value == "HM" ||
33119
- value == "VA" ||
33120
- value == "HN" ||
33121
- value == "HK" ||
33122
- value == "HU" ||
33123
- value == "IS" ||
33124
- value == "IN" ||
33125
- value == "ID" ||
33126
- value == "IR" ||
33127
- value == "IQ" ||
33128
- value == "IE" ||
33129
- value == "IM" ||
33130
- value == "IL" ||
33131
- value == "IT" ||
33132
- value == "JM" ||
33133
- value == "JP" ||
33134
- value == "JE" ||
33135
- value == "JO" ||
33136
- value == "KZ" ||
33137
- value == "KE" ||
33138
- value == "KI" ||
33139
- value == "KP" ||
33140
- value == "KR" ||
33141
- value == "KW" ||
33142
- value == "KG" ||
33143
- value == "LA" ||
33144
- value == "LV" ||
33145
- value == "LB" ||
33146
- value == "LS" ||
33147
- value == "LR" ||
33148
- value == "LY" ||
33149
- value == "LI" ||
33150
- value == "LT" ||
33151
- value == "LU" ||
33152
- value == "MO" ||
33153
- value == "MG" ||
33154
- value == "MW" ||
33155
- value == "MY" ||
33156
- value == "MV" ||
33157
- value == "ML" ||
33158
- value == "MT" ||
33159
- value == "MH" ||
33160
- value == "MQ" ||
33161
- value == "MR" ||
33162
- value == "MU" ||
33163
- value == "YT" ||
33164
- value == "MX" ||
33165
- value == "FM" ||
33166
- value == "MD" ||
33167
- value == "MC" ||
33168
- value == "MN" ||
33169
- value == "ME" ||
33170
- value == "MS" ||
33171
- value == "MA" ||
33172
- value == "MZ" ||
33173
- value == "MM" ||
33174
- value == "NA" ||
33175
- value == "NR" ||
33176
- value == "NP" ||
33177
- value == "NL" ||
33178
- value == "NC" ||
33179
- value == "NZ" ||
33180
- value == "NI" ||
33181
- value == "NE" ||
33182
- value == "NG" ||
33183
- value == "NU" ||
33184
- value == "NF" ||
33185
- value == "MK" ||
33186
- value == "MP" ||
33187
- value == "NO" ||
33188
- value == "OM" ||
33189
- value == "PK" ||
33190
- value == "PW" ||
33191
- value == "PS" ||
33192
- value == "PA" ||
33193
- value == "PG" ||
33194
- value == "PY" ||
33195
- value == "PE" ||
33196
- value == "PH" ||
33197
- value == "PN" ||
33198
- value == "PL" ||
33199
- value == "PT" ||
33200
- value == "PR" ||
33201
- value == "QA" ||
33202
- value == "RE" ||
33203
- value == "RO" ||
33204
- value == "RU" ||
33205
- value == "RW" ||
33206
- value == "BL" ||
33207
- value == "SH" ||
33208
- value == "KN" ||
33209
- value == "LC" ||
33210
- value == "MF" ||
33211
- value == "PM" ||
33212
- value == "VC" ||
33213
- value == "WS" ||
33214
- value == "SM" ||
33215
- value == "ST" ||
33216
- value == "SA" ||
33217
- value == "SN" ||
33218
- value == "RS" ||
33219
- value == "SC" ||
33220
- value == "SL" ||
33221
- value == "SG" ||
33222
- value == "SX" ||
33223
- value == "SK" ||
33224
- value == "SI" ||
33225
- value == "SB" ||
33226
- value == "SO" ||
33227
- value == "ZA" ||
33228
- value == "GS" ||
33229
- value == "SS" ||
33230
- value == "ES" ||
33231
- value == "LK" ||
33232
- value == "SD" ||
33233
- value == "SR" ||
33234
- value == "SJ" ||
33235
- value == "SE" ||
33236
- value == "CH" ||
33237
- value == "SY" ||
33238
- value == "TW" ||
33239
- value == "TJ" ||
33240
- value == "TZ" ||
33241
- value == "TH" ||
33242
- value == "TL" ||
33243
- value == "TG" ||
33244
- value == "TK" ||
33245
- value == "TO" ||
33246
- value == "TT" ||
33247
- value == "TN" ||
33248
- value == "TR" ||
33249
- value == "TM" ||
33250
- value == "TC" ||
33251
- value == "TV" ||
33252
- value == "UG" ||
33253
- value == "UA" ||
33254
- value == "AE" ||
33255
- value == "GB" ||
33256
- value == "US" ||
33257
- value == "UM" ||
33258
- value == "UY" ||
33259
- value == "UZ" ||
33260
- value == "VU" ||
33261
- value == "VE" ||
33262
- value == "VN" ||
33263
- value == "VG" ||
33264
- value == "VI" ||
33265
- value == "WF" ||
33266
- value == "EH" ||
33267
- value == "YE" ||
33268
- value == "ZM" ||
33269
- value == "ZW"));
33342
+ return Alpha2.types.includes(value);
33270
33343
  }
33271
33344
  Alpha2.is = is;
33272
33345
  function from(country) {
33273
33346
  return typeof country == "number" ? numericToAlpha2[country.toString()] : alpha3ToAlpha2[country];
33274
33347
  }
33275
33348
  Alpha2.from = from;
33349
+ function isEEA(country) {
33350
+ return [
33351
+ "AL",
33352
+ "AT",
33353
+ "BA",
33354
+ "BE",
33355
+ "BG",
33356
+ "CH",
33357
+ "CY",
33358
+ "DE",
33359
+ "DK",
33360
+ "EE",
33361
+ "ES",
33362
+ "FI",
33363
+ "FR",
33364
+ "GB",
33365
+ "GR",
33366
+ "HR",
33367
+ "HU",
33368
+ "IE",
33369
+ "IS",
33370
+ "IT",
33371
+ "LT",
33372
+ "LV",
33373
+ "MK",
33374
+ "MT",
33375
+ "NL",
33376
+ "NO",
33377
+ "PL",
33378
+ "PT",
33379
+ "RO",
33380
+ "RS",
33381
+ "SE",
33382
+ "SI",
33383
+ ].includes(country);
33384
+ }
33385
+ Alpha2.isEEA = isEEA;
33276
33386
  })(exports.Alpha2 || (exports.Alpha2 = {}));
33277
33387
  const numericToAlpha2 = {
33278
33388
  "4": "AF",
@@ -47492,187 +47602,189 @@ var Currency_1 = createCommonjsModule(function (module, exports) {
47492
47602
  Object.defineProperty(exports, "__esModule", { value: true });
47493
47603
  exports.Currency = void 0;
47494
47604
  (function (Currency) {
47605
+ Currency.types = [
47606
+ "AED",
47607
+ "AFN",
47608
+ "ALL",
47609
+ "AMD",
47610
+ "ANG",
47611
+ "AOA",
47612
+ "ARS",
47613
+ "AUD",
47614
+ "AWG",
47615
+ "AZN",
47616
+ "BAM",
47617
+ "BBD",
47618
+ "BDT",
47619
+ "BGN",
47620
+ "BHD",
47621
+ "BIF",
47622
+ "BMD",
47623
+ "BND",
47624
+ "BOB",
47625
+ "BOV",
47626
+ "BRL",
47627
+ "BSD",
47628
+ "BTN",
47629
+ "BWP",
47630
+ "BYN",
47631
+ "BZD",
47632
+ "CAD",
47633
+ "CDF",
47634
+ "CHE",
47635
+ "CHF",
47636
+ "CHW",
47637
+ "CLF",
47638
+ "CLP",
47639
+ "CNY",
47640
+ "COP",
47641
+ "COU",
47642
+ "CRC",
47643
+ "CUC",
47644
+ "CUP",
47645
+ "CVE",
47646
+ "CZK",
47647
+ "DJF",
47648
+ "DKK",
47649
+ "DOP",
47650
+ "DZD",
47651
+ "EGP",
47652
+ "ERN",
47653
+ "ETB",
47654
+ "EUR",
47655
+ "FJD",
47656
+ "FKP",
47657
+ "GBP",
47658
+ "GEL",
47659
+ "GHS",
47660
+ "GIP",
47661
+ "GMD",
47662
+ "GNF",
47663
+ "GTQ",
47664
+ "GYD",
47665
+ "HKD",
47666
+ "HNL",
47667
+ "HRK",
47668
+ "HTG",
47669
+ "HUF",
47670
+ "IDR",
47671
+ "ILS",
47672
+ "INR",
47673
+ "IQD",
47674
+ "IRR",
47675
+ "ISK",
47676
+ "JMD",
47677
+ "JOD",
47678
+ "JPY",
47679
+ "KES",
47680
+ "KGS",
47681
+ "KHR",
47682
+ "KMF",
47683
+ "KPW",
47684
+ "KRW",
47685
+ "KWD",
47686
+ "KYD",
47687
+ "KZT",
47688
+ "LAK",
47689
+ "LBP",
47690
+ "LKR",
47691
+ "LRD",
47692
+ "LSL",
47693
+ "LYD",
47694
+ "MAD",
47695
+ "MDL",
47696
+ "MGA",
47697
+ "MKD",
47698
+ "MMK",
47699
+ "MNT",
47700
+ "MOP",
47701
+ "MRU",
47702
+ "MUR",
47703
+ "MVR",
47704
+ "MWK",
47705
+ "MXN",
47706
+ "MXV",
47707
+ "MYR",
47708
+ "MZN",
47709
+ "NAD",
47710
+ "NGN",
47711
+ "NIO",
47712
+ "NOK",
47713
+ "NPR",
47714
+ "NZD",
47715
+ "OMR",
47716
+ "PAB",
47717
+ "PEN",
47718
+ "PGK",
47719
+ "PHP",
47720
+ "PKR",
47721
+ "PLN",
47722
+ "PYG",
47723
+ "QAR",
47724
+ "RON",
47725
+ "RSD",
47726
+ "RUB",
47727
+ "RWF",
47728
+ "SAR",
47729
+ "SBD",
47730
+ "SCR",
47731
+ "SDG",
47732
+ "SEK",
47733
+ "SGD",
47734
+ "SHP",
47735
+ "SLL",
47736
+ "SOS",
47737
+ "SRD",
47738
+ "SSP",
47739
+ "STN",
47740
+ "SVC",
47741
+ "SYP",
47742
+ "SZL",
47743
+ "THB",
47744
+ "TJS",
47745
+ "TMT",
47746
+ "TND",
47747
+ "TOP",
47748
+ "TRY",
47749
+ "TTD",
47750
+ "TWD",
47751
+ "TZS",
47752
+ "UAH",
47753
+ "UGX",
47754
+ "USD",
47755
+ "USN",
47756
+ "UYI",
47757
+ "UYU",
47758
+ "UYW",
47759
+ "UZS",
47760
+ "VES",
47761
+ "VND",
47762
+ "VUV",
47763
+ "WST",
47764
+ "XAF",
47765
+ "XAG",
47766
+ "XAU",
47767
+ "XBA",
47768
+ "XBB",
47769
+ "XBC",
47770
+ "XBD",
47771
+ "XCD",
47772
+ "XDR",
47773
+ "XOF",
47774
+ "XPD",
47775
+ "XPF",
47776
+ "XPT",
47777
+ "XSU",
47778
+ "XTS",
47779
+ "XUA",
47780
+ "XXX",
47781
+ "YER",
47782
+ "ZAR",
47783
+ "ZMW",
47784
+ "ZWL",
47785
+ ];
47495
47786
  function is(currency) {
47496
- return (typeof currency == "string" &&
47497
- (currency == "AED" ||
47498
- currency == "AFN" ||
47499
- currency == "ALL" ||
47500
- currency == "AMD" ||
47501
- currency == "ANG" ||
47502
- currency == "AOA" ||
47503
- currency == "ARS" ||
47504
- currency == "AUD" ||
47505
- currency == "AWG" ||
47506
- currency == "AZN" ||
47507
- currency == "BAM" ||
47508
- currency == "BBD" ||
47509
- currency == "BDT" ||
47510
- currency == "BGN" ||
47511
- currency == "BHD" ||
47512
- currency == "BIF" ||
47513
- currency == "BMD" ||
47514
- currency == "BND" ||
47515
- currency == "BOB" ||
47516
- currency == "BOV" ||
47517
- currency == "BRL" ||
47518
- currency == "BSD" ||
47519
- currency == "BTN" ||
47520
- currency == "BWP" ||
47521
- currency == "BYN" ||
47522
- currency == "BZD" ||
47523
- currency == "CAD" ||
47524
- currency == "CDF" ||
47525
- currency == "CHE" ||
47526
- currency == "CHF" ||
47527
- currency == "CHW" ||
47528
- currency == "CLF" ||
47529
- currency == "CLP" ||
47530
- currency == "CNY" ||
47531
- currency == "COP" ||
47532
- currency == "COU" ||
47533
- currency == "CRC" ||
47534
- currency == "CUC" ||
47535
- currency == "CUP" ||
47536
- currency == "CVE" ||
47537
- currency == "CZK" ||
47538
- currency == "DJF" ||
47539
- currency == "DKK" ||
47540
- currency == "DOP" ||
47541
- currency == "DZD" ||
47542
- currency == "EGP" ||
47543
- currency == "ERN" ||
47544
- currency == "ETB" ||
47545
- currency == "EUR" ||
47546
- currency == "FJD" ||
47547
- currency == "FKP" ||
47548
- currency == "GBP" ||
47549
- currency == "GEL" ||
47550
- currency == "GHS" ||
47551
- currency == "GIP" ||
47552
- currency == "GMD" ||
47553
- currency == "GNF" ||
47554
- currency == "GTQ" ||
47555
- currency == "GYD" ||
47556
- currency == "HKD" ||
47557
- currency == "HNL" ||
47558
- currency == "HRK" ||
47559
- currency == "HTG" ||
47560
- currency == "HUF" ||
47561
- currency == "IDR" ||
47562
- currency == "ILS" ||
47563
- currency == "INR" ||
47564
- currency == "IQD" ||
47565
- currency == "IRR" ||
47566
- currency == "ISK" ||
47567
- currency == "JMD" ||
47568
- currency == "JOD" ||
47569
- currency == "JPY" ||
47570
- currency == "KES" ||
47571
- currency == "KGS" ||
47572
- currency == "KHR" ||
47573
- currency == "KMF" ||
47574
- currency == "KPW" ||
47575
- currency == "KRW" ||
47576
- currency == "KWD" ||
47577
- currency == "KYD" ||
47578
- currency == "KZT" ||
47579
- currency == "LAK" ||
47580
- currency == "LBP" ||
47581
- currency == "LKR" ||
47582
- currency == "LRD" ||
47583
- currency == "LSL" ||
47584
- currency == "LYD" ||
47585
- currency == "MAD" ||
47586
- currency == "MDL" ||
47587
- currency == "MGA" ||
47588
- currency == "MKD" ||
47589
- currency == "MMK" ||
47590
- currency == "MNT" ||
47591
- currency == "MOP" ||
47592
- currency == "MRU" ||
47593
- currency == "MUR" ||
47594
- currency == "MVR" ||
47595
- currency == "MWK" ||
47596
- currency == "MXN" ||
47597
- currency == "MXV" ||
47598
- currency == "MYR" ||
47599
- currency == "MZN" ||
47600
- currency == "NAD" ||
47601
- currency == "NGN" ||
47602
- currency == "NIO" ||
47603
- currency == "NOK" ||
47604
- currency == "NPR" ||
47605
- currency == "NZD" ||
47606
- currency == "OMR" ||
47607
- currency == "PAB" ||
47608
- currency == "PEN" ||
47609
- currency == "PGK" ||
47610
- currency == "PHP" ||
47611
- currency == "PKR" ||
47612
- currency == "PLN" ||
47613
- currency == "PYG" ||
47614
- currency == "QAR" ||
47615
- currency == "RON" ||
47616
- currency == "RSD" ||
47617
- currency == "RUB" ||
47618
- currency == "RWF" ||
47619
- currency == "SAR" ||
47620
- currency == "SBD" ||
47621
- currency == "SCR" ||
47622
- currency == "SDG" ||
47623
- currency == "SEK" ||
47624
- currency == "SGD" ||
47625
- currency == "SHP" ||
47626
- currency == "SLL" ||
47627
- currency == "SOS" ||
47628
- currency == "SRD" ||
47629
- currency == "SSP" ||
47630
- currency == "STN" ||
47631
- currency == "SVC" ||
47632
- currency == "SYP" ||
47633
- currency == "SZL" ||
47634
- currency == "THB" ||
47635
- currency == "TJS" ||
47636
- currency == "TMT" ||
47637
- currency == "TND" ||
47638
- currency == "TOP" ||
47639
- currency == "TRY" ||
47640
- currency == "TTD" ||
47641
- currency == "TWD" ||
47642
- currency == "TZS" ||
47643
- currency == "UAH" ||
47644
- currency == "UGX" ||
47645
- currency == "USD" ||
47646
- currency == "USN" ||
47647
- currency == "UYI" ||
47648
- currency == "UYU" ||
47649
- currency == "UYW" ||
47650
- currency == "UZS" ||
47651
- currency == "VES" ||
47652
- currency == "VND" ||
47653
- currency == "VUV" ||
47654
- currency == "WST" ||
47655
- currency == "XAF" ||
47656
- currency == "XAG" ||
47657
- currency == "XAU" ||
47658
- currency == "XBA" ||
47659
- currency == "XBB" ||
47660
- currency == "XBC" ||
47661
- currency == "XBD" ||
47662
- currency == "XCD" ||
47663
- currency == "XDR" ||
47664
- currency == "XOF" ||
47665
- currency == "XPD" ||
47666
- currency == "XPF" ||
47667
- currency == "XPT" ||
47668
- currency == "XSU" ||
47669
- currency == "XTS" ||
47670
- currency == "XUA" ||
47671
- currency == "XXX" ||
47672
- currency == "YER" ||
47673
- currency == "ZAR" ||
47674
- currency == "ZMW" ||
47675
- currency == "ZWL"));
47787
+ return Currency.types.includes(currency);
47676
47788
  }
47677
47789
  Currency.is = is;
47678
47790
  function from(currencyCode) {
@@ -47859,6 +47971,12 @@ exports.Currency = void 0;
47859
47971
  }[currencyCode];
47860
47972
  }
47861
47973
  Currency.from = from;
47974
+ function round(value, currency) {
47975
+ var _a;
47976
+ const factor = Math.pow(10, (_a = decimalDigits(currency)) !== null && _a !== void 0 ? _a : 2);
47977
+ return Math.round((value + Number.EPSILON) * factor) / factor;
47978
+ }
47979
+ Currency.round = round;
47862
47980
  function decimalDigits(currency) {
47863
47981
  return {
47864
47982
  AED: 2,
@@ -48051,187 +48169,189 @@ var CurrencyCode_1 = createCommonjsModule(function (module, exports) {
48051
48169
  Object.defineProperty(exports, "__esModule", { value: true });
48052
48170
  exports.CurrencyCode = void 0;
48053
48171
  (function (CurrencyCode) {
48172
+ CurrencyCode.types = [
48173
+ "008",
48174
+ "012",
48175
+ "032",
48176
+ "036",
48177
+ "044",
48178
+ "048",
48179
+ "050",
48180
+ "051",
48181
+ "052",
48182
+ "060",
48183
+ "064",
48184
+ "068",
48185
+ "072",
48186
+ "084",
48187
+ "090",
48188
+ "096",
48189
+ "104",
48190
+ "108",
48191
+ "116",
48192
+ "124",
48193
+ "132",
48194
+ "136",
48195
+ "144",
48196
+ "152",
48197
+ "156",
48198
+ "170",
48199
+ "174",
48200
+ "188",
48201
+ "191",
48202
+ "192",
48203
+ "203",
48204
+ "208",
48205
+ "214",
48206
+ "222",
48207
+ "230",
48208
+ "232",
48209
+ "238",
48210
+ "242",
48211
+ "262",
48212
+ "270",
48213
+ "292",
48214
+ "320",
48215
+ "324",
48216
+ "328",
48217
+ "332",
48218
+ "340",
48219
+ "344",
48220
+ "348",
48221
+ "352",
48222
+ "356",
48223
+ "360",
48224
+ "364",
48225
+ "368",
48226
+ "376",
48227
+ "388",
48228
+ "392",
48229
+ "398",
48230
+ "400",
48231
+ "404",
48232
+ "408",
48233
+ "410",
48234
+ "414",
48235
+ "417",
48236
+ "418",
48237
+ "422",
48238
+ "426",
48239
+ "430",
48240
+ "434",
48241
+ "446",
48242
+ "454",
48243
+ "458",
48244
+ "462",
48245
+ "480",
48246
+ "484",
48247
+ "496",
48248
+ "498",
48249
+ "504",
48250
+ "512",
48251
+ "516",
48252
+ "524",
48253
+ "532",
48254
+ "533",
48255
+ "548",
48256
+ "554",
48257
+ "558",
48258
+ "566",
48259
+ "578",
48260
+ "586",
48261
+ "590",
48262
+ "598",
48263
+ "600",
48264
+ "604",
48265
+ "608",
48266
+ "634",
48267
+ "643",
48268
+ "646",
48269
+ "654",
48270
+ "682",
48271
+ "690",
48272
+ "694",
48273
+ "702",
48274
+ "704",
48275
+ "706",
48276
+ "710",
48277
+ "728",
48278
+ "748",
48279
+ "752",
48280
+ "756",
48281
+ "760",
48282
+ "764",
48283
+ "776",
48284
+ "780",
48285
+ "784",
48286
+ "788",
48287
+ "800",
48288
+ "807",
48289
+ "818",
48290
+ "826",
48291
+ "834",
48292
+ "840",
48293
+ "858",
48294
+ "860",
48295
+ "882",
48296
+ "886",
48297
+ "901",
48298
+ "927",
48299
+ "928",
48300
+ "929",
48301
+ "930",
48302
+ "931",
48303
+ "932",
48304
+ "933",
48305
+ "934",
48306
+ "936",
48307
+ "938",
48308
+ "940",
48309
+ "941",
48310
+ "943",
48311
+ "944",
48312
+ "946",
48313
+ "947",
48314
+ "948",
48315
+ "949",
48316
+ "950",
48317
+ "951",
48318
+ "952",
48319
+ "953",
48320
+ "955",
48321
+ "956",
48322
+ "957",
48323
+ "958",
48324
+ "959",
48325
+ "960",
48326
+ "961",
48327
+ "962",
48328
+ "963",
48329
+ "964",
48330
+ "965",
48331
+ "967",
48332
+ "968",
48333
+ "969",
48334
+ "970",
48335
+ "971",
48336
+ "972",
48337
+ "973",
48338
+ "975",
48339
+ "976",
48340
+ "977",
48341
+ "978",
48342
+ "979",
48343
+ "980",
48344
+ "981",
48345
+ "984",
48346
+ "985",
48347
+ "986",
48348
+ "990",
48349
+ "994",
48350
+ "997",
48351
+ "999",
48352
+ ];
48054
48353
  function is(value) {
48055
- return (typeof value == "string" &&
48056
- (value == "008" ||
48057
- value == "012" ||
48058
- value == "032" ||
48059
- value == "036" ||
48060
- value == "044" ||
48061
- value == "048" ||
48062
- value == "050" ||
48063
- value == "051" ||
48064
- value == "052" ||
48065
- value == "060" ||
48066
- value == "064" ||
48067
- value == "068" ||
48068
- value == "072" ||
48069
- value == "084" ||
48070
- value == "090" ||
48071
- value == "096" ||
48072
- value == "104" ||
48073
- value == "108" ||
48074
- value == "116" ||
48075
- value == "124" ||
48076
- value == "132" ||
48077
- value == "136" ||
48078
- value == "144" ||
48079
- value == "152" ||
48080
- value == "156" ||
48081
- value == "170" ||
48082
- value == "174" ||
48083
- value == "188" ||
48084
- value == "191" ||
48085
- value == "192" ||
48086
- value == "203" ||
48087
- value == "208" ||
48088
- value == "214" ||
48089
- value == "222" ||
48090
- value == "230" ||
48091
- value == "232" ||
48092
- value == "238" ||
48093
- value == "242" ||
48094
- value == "262" ||
48095
- value == "270" ||
48096
- value == "292" ||
48097
- value == "320" ||
48098
- value == "324" ||
48099
- value == "328" ||
48100
- value == "332" ||
48101
- value == "340" ||
48102
- value == "344" ||
48103
- value == "348" ||
48104
- value == "352" ||
48105
- value == "356" ||
48106
- value == "360" ||
48107
- value == "364" ||
48108
- value == "368" ||
48109
- value == "376" ||
48110
- value == "388" ||
48111
- value == "392" ||
48112
- value == "398" ||
48113
- value == "400" ||
48114
- value == "404" ||
48115
- value == "408" ||
48116
- value == "410" ||
48117
- value == "414" ||
48118
- value == "417" ||
48119
- value == "418" ||
48120
- value == "422" ||
48121
- value == "426" ||
48122
- value == "430" ||
48123
- value == "434" ||
48124
- value == "446" ||
48125
- value == "454" ||
48126
- value == "458" ||
48127
- value == "462" ||
48128
- value == "480" ||
48129
- value == "484" ||
48130
- value == "496" ||
48131
- value == "498" ||
48132
- value == "504" ||
48133
- value == "512" ||
48134
- value == "516" ||
48135
- value == "524" ||
48136
- value == "532" ||
48137
- value == "533" ||
48138
- value == "548" ||
48139
- value == "554" ||
48140
- value == "558" ||
48141
- value == "566" ||
48142
- value == "578" ||
48143
- value == "586" ||
48144
- value == "590" ||
48145
- value == "598" ||
48146
- value == "600" ||
48147
- value == "604" ||
48148
- value == "608" ||
48149
- value == "634" ||
48150
- value == "643" ||
48151
- value == "646" ||
48152
- value == "654" ||
48153
- value == "682" ||
48154
- value == "690" ||
48155
- value == "694" ||
48156
- value == "702" ||
48157
- value == "704" ||
48158
- value == "706" ||
48159
- value == "710" ||
48160
- value == "728" ||
48161
- value == "748" ||
48162
- value == "752" ||
48163
- value == "756" ||
48164
- value == "760" ||
48165
- value == "764" ||
48166
- value == "776" ||
48167
- value == "780" ||
48168
- value == "784" ||
48169
- value == "788" ||
48170
- value == "800" ||
48171
- value == "807" ||
48172
- value == "818" ||
48173
- value == "826" ||
48174
- value == "834" ||
48175
- value == "840" ||
48176
- value == "858" ||
48177
- value == "860" ||
48178
- value == "882" ||
48179
- value == "886" ||
48180
- value == "901" ||
48181
- value == "927" ||
48182
- value == "928" ||
48183
- value == "929" ||
48184
- value == "930" ||
48185
- value == "931" ||
48186
- value == "932" ||
48187
- value == "933" ||
48188
- value == "934" ||
48189
- value == "936" ||
48190
- value == "938" ||
48191
- value == "940" ||
48192
- value == "941" ||
48193
- value == "943" ||
48194
- value == "944" ||
48195
- value == "946" ||
48196
- value == "947" ||
48197
- value == "948" ||
48198
- value == "949" ||
48199
- value == "950" ||
48200
- value == "951" ||
48201
- value == "952" ||
48202
- value == "953" ||
48203
- value == "955" ||
48204
- value == "956" ||
48205
- value == "957" ||
48206
- value == "958" ||
48207
- value == "959" ||
48208
- value == "960" ||
48209
- value == "961" ||
48210
- value == "962" ||
48211
- value == "963" ||
48212
- value == "964" ||
48213
- value == "965" ||
48214
- value == "967" ||
48215
- value == "968" ||
48216
- value == "969" ||
48217
- value == "970" ||
48218
- value == "971" ||
48219
- value == "972" ||
48220
- value == "973" ||
48221
- value == "975" ||
48222
- value == "976" ||
48223
- value == "977" ||
48224
- value == "978" ||
48225
- value == "979" ||
48226
- value == "980" ||
48227
- value == "981" ||
48228
- value == "984" ||
48229
- value == "985" ||
48230
- value == "986" ||
48231
- value == "990" ||
48232
- value == "994" ||
48233
- value == "997" ||
48234
- value == "999"));
48354
+ return CurrencyCode.types.includes(value);
48235
48355
  }
48236
48356
  CurrencyCode.is = is;
48237
48357
  function from(currency) {
@@ -48608,27 +48728,27 @@ exports.CurrencyCode = void 0;
48608
48728
 
48609
48729
  var _Date = createCommonjsModule(function (module, exports) {
48610
48730
  Object.defineProperty(exports, "__esModule", { value: true });
48611
- exports.IsoDate = void 0;
48612
- (function (IsoDate) {
48731
+ exports.Date = void 0;
48732
+ (function (Date) {
48613
48733
  function is(value) {
48614
48734
  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));
48615
48735
  }
48616
- IsoDate.is = is;
48736
+ Date.is = is;
48617
48737
  function parse(value, time) {
48618
- return new Date(value + (time !== null && time !== void 0 ? time : "T12:00:00.000Z"));
48738
+ return new globalThis.Date(value + (time !== null && time !== void 0 ? time : "T12:00:00.000Z"));
48619
48739
  }
48620
- IsoDate.parse = parse;
48740
+ Date.parse = parse;
48621
48741
  function create(value) {
48622
48742
  return value.toISOString().substring(0, 10);
48623
48743
  }
48624
- IsoDate.create = create;
48744
+ Date.create = create;
48625
48745
  function now() {
48626
- return create(new Date());
48746
+ return create(new globalThis.Date());
48627
48747
  }
48628
- IsoDate.now = now;
48748
+ Date.now = now;
48629
48749
  function localize(value, locale) {
48630
- const localeString = locale ? locale : Intl.DateTimeFormat().resolvedOptions().locale;
48631
- const localeOptions = {
48750
+ return (is(value) ? parse(value) : value)
48751
+ .toLocaleString(locale ? locale : Intl.DateTimeFormat().resolvedOptions().locale, {
48632
48752
  year: "numeric",
48633
48753
  month: "2-digit",
48634
48754
  day: "2-digit",
@@ -48636,14 +48756,121 @@ exports.IsoDate = void 0;
48636
48756
  minute: "2-digit",
48637
48757
  second: "2-digit",
48638
48758
  timeZone: Intl.DateTimeFormat().resolvedOptions().timeZone,
48639
- };
48640
- return (is(value) ? parse(value) : value).toLocaleString(localeString, localeOptions).substring(0, 10);
48759
+ })
48760
+ .substring(0, 10);
48761
+ }
48762
+ Date.localize = localize;
48763
+ function next(date, days = 1) {
48764
+ let result;
48765
+ if (typeof days == "number") {
48766
+ const r = parse(date);
48767
+ r.setDate(r.getDate() + days);
48768
+ result = Date.create(r);
48769
+ }
48770
+ else {
48771
+ result = date;
48772
+ if (days.years)
48773
+ result = nextYear(result, days.years);
48774
+ if (days.months)
48775
+ result = nextMonth(result, days.months);
48776
+ if (days.days)
48777
+ result = next(result, days.days);
48778
+ }
48779
+ return result;
48780
+ }
48781
+ Date.next = next;
48782
+ function previous(date, days = 1) {
48783
+ let result;
48784
+ if (typeof days == "number") {
48785
+ const r = parse(date);
48786
+ r.setDate(r.getDate() - days);
48787
+ result = Date.create(r);
48788
+ }
48789
+ else {
48790
+ result = date;
48791
+ if (days.years)
48792
+ result = previousYear(result, days.years);
48793
+ if (days.months)
48794
+ result = previousMonth(result, days.months);
48795
+ if (days.days)
48796
+ result = previous(result, days.days);
48797
+ }
48798
+ return result;
48799
+ }
48800
+ Date.previous = previous;
48801
+ function nextMonth(date, months = 1) {
48802
+ const result = parse(date);
48803
+ result.setMonth(result.getMonth() + months);
48804
+ return Date.create(result);
48641
48805
  }
48642
- IsoDate.localize = localize;
48643
- })(exports.IsoDate || (exports.IsoDate = {}));
48806
+ Date.nextMonth = nextMonth;
48807
+ function previousMonth(date, months = 1) {
48808
+ return nextMonth(date, -months);
48809
+ }
48810
+ Date.previousMonth = previousMonth;
48811
+ function nextYear(date, years = 1) {
48812
+ const result = parse(date);
48813
+ result.setFullYear(result.getFullYear() + years);
48814
+ return Date.create(result);
48815
+ }
48816
+ Date.nextYear = nextYear;
48817
+ function previousYear(date, years = 1) {
48818
+ return nextYear(date, -years);
48819
+ }
48820
+ Date.previousYear = previousYear;
48821
+ function firstOfMonth(date) {
48822
+ const result = parse(date);
48823
+ result.setDate(1);
48824
+ return Date.create(result);
48825
+ }
48826
+ Date.firstOfMonth = firstOfMonth;
48827
+ function lastOfMonth(date) {
48828
+ const result = parse(date);
48829
+ result.setMonth(result.getMonth() + 1);
48830
+ result.setDate(-1);
48831
+ return Date.create(result);
48832
+ }
48833
+ Date.lastOfMonth = lastOfMonth;
48834
+ })(exports.Date || (exports.Date = {}));
48644
48835
  //# sourceMappingURL=Date.js.map
48645
48836
  });
48646
48837
 
48838
+ var DateRange_1 = createCommonjsModule(function (module, exports) {
48839
+ Object.defineProperty(exports, "__esModule", { value: true });
48840
+ exports.DateRange = void 0;
48841
+ (function (DateRange) {
48842
+ function is(value) {
48843
+ return typeof value == "object" && _Date.Date.is(value.start) && _Date.Date.is(value.end);
48844
+ }
48845
+ DateRange.is = is;
48846
+ function create(start, end) {
48847
+ return !_Date.Date.is(end)
48848
+ ? create(start, _Date.Date.next(start, end))
48849
+ : start <= end
48850
+ ? { start, end }
48851
+ : { start: end, end: start };
48852
+ }
48853
+ DateRange.create = create;
48854
+ })(exports.DateRange || (exports.DateRange = {}));
48855
+ //# sourceMappingURL=DateRange.js.map
48856
+ });
48857
+
48858
+ var DateSpan_1 = createCommonjsModule(function (module, exports) {
48859
+ Object.defineProperty(exports, "__esModule", { value: true });
48860
+ exports.DateSpan = void 0;
48861
+ (function (DateSpan) {
48862
+ function is(value) {
48863
+ return (typeof value == "object" &&
48864
+ (typeof value.years == "number" || value.years == undefined) &&
48865
+ (typeof value.months == "number" || value.months == undefined) &&
48866
+ (typeof value.days == "number" || value.days == undefined) &&
48867
+ (typeof value.years == "number" || typeof value.months == "number" || typeof value.days == "number"));
48868
+ }
48869
+ DateSpan.is = is;
48870
+ })(exports.DateSpan || (exports.DateSpan = {}));
48871
+ //# sourceMappingURL=DateSpan.js.map
48872
+ });
48873
+
48647
48874
  var DateTime_1 = createCommonjsModule(function (module, exports) {
48648
48875
  Object.defineProperty(exports, "__esModule", { value: true });
48649
48876
  exports.DateTime = void 0;
@@ -48667,7 +48894,7 @@ exports.DateTime = void 0;
48667
48894
  DateTime.now = now;
48668
48895
  function localize(value, locale) {
48669
48896
  const localeString = locale ? locale : Intl.DateTimeFormat().resolvedOptions().locale;
48670
- const localeOptions = {
48897
+ return (is(value) ? parse(value) : value).toLocaleString(localeString, {
48671
48898
  year: "numeric",
48672
48899
  month: "2-digit",
48673
48900
  day: "2-digit",
@@ -48675,8 +48902,7 @@ exports.DateTime = void 0;
48675
48902
  minute: "2-digit",
48676
48903
  second: "2-digit",
48677
48904
  timeZone: Intl.DateTimeFormat().resolvedOptions().timeZone,
48678
- };
48679
- return (is(value) ? parse(value) : value).toLocaleString(localeString, localeOptions);
48905
+ });
48680
48906
  }
48681
48907
  DateTime.localize = localize;
48682
48908
  })(exports.DateTime || (exports.DateTime = {}));
@@ -50413,7 +50639,7 @@ var __importStar = (commonjsGlobal && commonjsGlobal.__importStar) || function (
50413
50639
  return result;
50414
50640
  };
50415
50641
  Object.defineProperty(exports, "__esModule", { value: true });
50416
- exports.Locale = exports.Language = exports.Encoding = exports.DateTime = exports.Date = exports.CurrencyCode = exports.Currency = exports.CountryCode = exports.CallingCode = void 0;
50642
+ exports.Locale = exports.Language = exports.Encoding = exports.DateTime = exports.Date = exports.DateSpan = exports.DateRange = exports.CurrencyCode = exports.Currency = exports.CountryCode = exports.CallingCode = void 0;
50417
50643
 
50418
50644
  Object.defineProperty(exports, "CallingCode", { enumerable: true, get: function () { return CallingCode_1.CallingCode; } });
50419
50645
  const CountryCode$1 = __importStar(CountryCode);
@@ -50423,7 +50649,11 @@ Object.defineProperty(exports, "Currency", { enumerable: true, get: function ()
50423
50649
 
50424
50650
  Object.defineProperty(exports, "CurrencyCode", { enumerable: true, get: function () { return CurrencyCode_1.CurrencyCode; } });
50425
50651
 
50426
- Object.defineProperty(exports, "Date", { enumerable: true, get: function () { return _Date.IsoDate; } });
50652
+ Object.defineProperty(exports, "Date", { enumerable: true, get: function () { return _Date.Date; } });
50653
+
50654
+ Object.defineProperty(exports, "DateRange", { enumerable: true, get: function () { return DateRange_1.DateRange; } });
50655
+
50656
+ Object.defineProperty(exports, "DateSpan", { enumerable: true, get: function () { return DateSpan_1.DateSpan; } });
50427
50657
 
50428
50658
  Object.defineProperty(exports, "DateTime", { enumerable: true, get: function () { return DateTime_1.DateTime; } });
50429
50659
 
@@ -51306,9 +51536,7 @@ const SmoothlyDisplayAmount = class {
51306
51536
  format(amount) {
51307
51537
  const digitsPerGroup = 3;
51308
51538
  const defaultDecimals = 2;
51309
- const maxDecimals = (dist$4.Currency.decimalDigits(this.currency)
51310
- ? dist$4.Currency.decimalDigits(this.currency)
51311
- : defaultDecimals);
51539
+ const maxDecimals = (dist$4.Currency.decimalDigits(this.currency) ? dist$4.Currency.decimalDigits(this.currency) : defaultDecimals);
51312
51540
  let beforeSeparator = amount.length;
51313
51541
  let separator;
51314
51542
  let result = amount;
@@ -52030,7 +52258,7 @@ const SmoothlyInput = class {
52030
52258
  end: backend.selectionEnd != undefined ? backend.selectionEnd : backend.value.length,
52031
52259
  direction: backend.selectionDirection ? backend.selectionDirection : "none",
52032
52260
  } });
52033
- if ((!(event.ctrlKey && event.key == "v") && event.key.length == 1) ||
52261
+ if ((!((event.ctrlKey || event.metaKey) && event.key == "v") && event.key.length == 1) ||
52034
52262
  event.key == "ArrowLeft" ||
52035
52263
  event.key == "ArrowRight" ||
52036
52264
  event.key == "Delete" ||
@@ -52169,7 +52397,7 @@ const SmoothlyInputDemo = class {
52169
52397
  }
52170
52398
  };
52171
52399
 
52172
- 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}";
52400
+ 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}";
52173
52401
 
52174
52402
  const MonthSelector = class {
52175
52403
  constructor(hostRef) {
@@ -52179,21 +52407,21 @@ const MonthSelector = class {
52179
52407
  onValueChanged(next) {
52180
52408
  this.valueChanged.emit(next);
52181
52409
  }
52410
+ adjustMonth(delta) {
52411
+ var _a;
52412
+ const date = dist$4.Date.parse((_a = this.value) !== null && _a !== void 0 ? _a : dist$4.Date.now());
52413
+ date.setMonth(date.getMonth() + delta);
52414
+ this.value = dist$4.Date.create(date);
52415
+ }
52182
52416
  render() {
52183
52417
  var _a, _b;
52184
52418
  return [
52185
- h("button", { onClick: () => this.adjustMonth(-1) }, h("smoothly-icon", { name: "chevron-back-outline", size: "small" })),
52419
+ h("div", { onClick: () => this.adjustMonth(-1) }, h("smoothly-icon", { name: "chevron-back-outline", size: "small" })),
52186
52420
  h("smoothly-selector", { onSelected: (e) => (this.value = e.detail) }, years((_a = this.value) !== null && _a !== void 0 ? _a : dist$4.Date.now()).map(year => (h("smoothly-item", { value: year.date, selected: year.selected }, year.name)))),
52187
52421
  h("smoothly-selector", { onSelected: (e) => (this.value = e.detail) }, months((_b = this.value) !== null && _b !== void 0 ? _b : dist$4.Date.now()).map(month => (h("smoothly-item", { value: month.date, selected: month.selected }, month.name)))),
52188
- h("button", { onClick: () => this.adjustMonth(1) }, h("smoothly-icon", { name: "chevron-forward-outline", size: "small" })),
52422
+ h("div", { onClick: () => this.adjustMonth(1) }, h("smoothly-icon", { name: "chevron-forward-outline", size: "small" })),
52189
52423
  ];
52190
52424
  }
52191
- adjustMonth(delta) {
52192
- var _a;
52193
- const date = dist$4.Date.parse((_a = this.value) !== null && _a !== void 0 ? _a : dist$4.Date.now());
52194
- date.setMonth(date.getMonth() + delta);
52195
- this.value = dist$4.Date.create(date);
52196
- }
52197
52425
  static get watchers() { return {
52198
52426
  "value": ["onValueChanged"]
52199
52427
  }; }
@@ -52480,14 +52708,11 @@ const SmoothlyPicker = class {
52480
52708
  : this.select(option);
52481
52709
  }
52482
52710
  clearSelection() {
52483
- var _a;
52484
52711
  this.selections = [];
52485
52712
  this.inputElement.focus();
52486
52713
  this.keepFocusOnReRender = true;
52487
- (_a = this.options) === null || _a === void 0 ? void 0 : _a.forEach(option => (option.description = ""));
52488
52714
  }
52489
52715
  unselect(selection) {
52490
- var _a;
52491
52716
  const index = this.selections.map(selection => selection.value).indexOf(selection.value);
52492
52717
  if (index != -1) {
52493
52718
  this.selections = [
@@ -52496,12 +52721,8 @@ const SmoothlyPicker = class {
52496
52721
  ];
52497
52722
  this.keepFocusOnReRender = true;
52498
52723
  }
52499
- const optionIndex = (_a = this.options) === null || _a === void 0 ? void 0 : _a.map(s => s.value).indexOf(selection.value);
52500
- if (optionIndex != -1)
52501
- this.options[optionIndex].description = "";
52502
52724
  }
52503
52725
  select(selection) {
52504
- var _a;
52505
52726
  const isNewSelection = this.selections.reduce((acc, current) => acc && current.value != selection.value, true);
52506
52727
  if (isNewSelection)
52507
52728
  this.selections = this.multiple ? [...this.selections, selection] : [selection];
@@ -52509,8 +52730,6 @@ const SmoothlyPicker = class {
52509
52730
  this.filterOptions();
52510
52731
  this.keepFocusOnReRender = true;
52511
52732
  this.isOpen = this.multiple;
52512
- (_a = this.options) === null || _a === void 0 ? void 0 : _a.forEach(option => (option.description =
52513
- option.value == selection.value ? this.getCheckHtml() : this.multiple ? option.description : ""));
52514
52733
  }
52515
52734
  toggleHighlighted() {
52516
52735
  var _a;
@@ -52570,14 +52789,18 @@ const SmoothlyPicker = class {
52570
52789
  "--max-height": (_a = this.maxHeight) !== null && _a !== void 0 ? _a : "inherit",
52571
52790
  "--label-display": this.labelSetting == "hide" ? "none" : "absolute",
52572
52791
  };
52573
- return (h(Host, { style: cssVariables, "has-selection": this.selections.length > 0, "is-open": this.isOpen ? "" : undefined, onMouseDown: (e) => e.preventDefault(), onClick: () => this.onClick() }, h("div", null, h("label", null, this.label), 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) })), 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: [
52574
- {
52575
- value: "select-none",
52576
- name: this.selectNoneName,
52577
- description: this.selections.length == 0 ? this.getCheckHtml() : "",
52578
- },
52579
- ...((_b = this.options) !== null && _b !== void 0 ? _b : []),
52580
- ] })));
52792
+ this.options.forEach(o => {
52793
+ o.description = this.selections.map(s => s.value).includes(o.value) ? this.getCheckHtml() : "";
52794
+ });
52795
+ const options = [
52796
+ {
52797
+ value: "select-none",
52798
+ name: this.selectNoneName,
52799
+ description: this.selections.length == 0 ? this.getCheckHtml() : "",
52800
+ },
52801
+ ...((_b = this.options) !== null && _b !== void 0 ? _b : []),
52802
+ ];
52803
+ return (h(Host, { style: cssVariables, "has-selection": this.selections.length > 0, "is-open": this.isOpen ? "" : undefined, onMouseDown: (e) => e.preventDefault(), onClick: () => this.onClick() }, h("div", null, h("label", null, this.label), 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) })), 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 })));
52581
52804
  }
52582
52805
  get element() { return getElement(this); }
52583
52806
  static get watchers() { return {
@@ -52657,7 +52880,7 @@ const SmoothlySelect = class {
52657
52880
  }
52658
52881
  optionSelected() {
52659
52882
  if (this.selectElement)
52660
- this.selectionChanged.emit({ identifier: this.identifier, value: this.value = this.selectElement.value });
52883
+ this.selectionChanged.emit({ identifier: this.identifier, value: (this.value = this.selectElement.value) });
52661
52884
  }
52662
52885
  componentDidLoad() {
52663
52886
  var _a;
@@ -53021,7 +53244,7 @@ const TableHeader = class {
53021
53244
  onClick(event) {
53022
53245
  this.sort.emit({
53023
53246
  property: this.name,
53024
- direction: this.sortDirection = this.sortDirection == "ascending" ? "descending" : "ascending",
53247
+ direction: (this.sortDirection = this.sortDirection == "ascending" ? "descending" : "ascending"),
53025
53248
  });
53026
53249
  console.log("sort", this.name, this.sortDirection);
53027
53250
  event.preventDefault();