@watermarkinsights/ripple 5.21.0-alpha.1 → 5.21.0-alpha.3

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 (80) hide show
  1. package/dist/cjs/{app-globals-84a1a262.js → app-globals-b999e811.js} +1 -1
  2. package/dist/cjs/loader.cjs.js +1 -1
  3. package/dist/cjs/priv-calendar.cjs.entry.js +10 -10
  4. package/dist/cjs/ripple.cjs.js +1 -1
  5. package/dist/cjs/wm-date-range.cjs.entry.js +10 -6
  6. package/dist/cjs/wm-datepicker.cjs.entry.js +10 -6
  7. package/dist/cjs/wm-input.cjs.entry.js +1 -1
  8. package/dist/cjs/wm-nested-select.cjs.entry.js +1 -1
  9. package/dist/cjs/wm-option_2.cjs.entry.js +1 -1
  10. package/dist/cjs/wm-tag-input.cjs.entry.js +1 -1
  11. package/dist/cjs/wm-textarea.cjs.entry.js +1 -1
  12. package/dist/cjs/wm-timepicker.cjs.entry.js +1 -1
  13. package/dist/cjs/wm-uploader.cjs.entry.js +1 -1
  14. package/dist/collection/components/datepickers/datepicker.css +1 -1
  15. package/dist/collection/components/datepickers/priv-calendar/priv-calendar.css +7 -10
  16. package/dist/collection/components/datepickers/priv-calendar/priv-calendar.js +9 -9
  17. package/dist/collection/components/datepickers/wm-date-range.js +9 -5
  18. package/dist/collection/components/datepickers/wm-datepicker.js +10 -6
  19. package/dist/collection/components/selects/wm-nested-select/wm-nested-select.css +1 -1
  20. package/dist/collection/components/selects/wm-select/wm-select.css +1 -1
  21. package/dist/collection/components/wm-input/wm-input.css +1 -1
  22. package/dist/collection/components/wm-tag-input/wm-tag-input.css +1 -1
  23. package/dist/collection/components/wm-textarea/wm-textarea.css +1 -1
  24. package/dist/collection/components/wm-timepicker/wm-timepicker.css +1 -1
  25. package/dist/collection/components/wm-uploader/wm-uploader.css +1 -1
  26. package/dist/esm/{app-globals-1505b33c.js → app-globals-3da2b209.js} +1 -1
  27. package/dist/esm/loader.js +1 -1
  28. package/dist/esm/priv-calendar.entry.js +10 -10
  29. package/dist/esm/ripple.js +1 -1
  30. package/dist/esm/wm-date-range.entry.js +10 -6
  31. package/dist/esm/wm-datepicker.entry.js +10 -6
  32. package/dist/esm/wm-input.entry.js +1 -1
  33. package/dist/esm/wm-nested-select.entry.js +1 -1
  34. package/dist/esm/wm-option_2.entry.js +1 -1
  35. package/dist/esm/wm-tag-input.entry.js +1 -1
  36. package/dist/esm/wm-textarea.entry.js +1 -1
  37. package/dist/esm/wm-timepicker.entry.js +1 -1
  38. package/dist/esm/wm-uploader.entry.js +1 -1
  39. package/dist/esm-es5/{app-globals-1505b33c.js → app-globals-3da2b209.js} +1 -1
  40. package/dist/esm-es5/loader.js +1 -1
  41. package/dist/esm-es5/priv-calendar.entry.js +1 -1
  42. package/dist/esm-es5/ripple.js +1 -1
  43. package/dist/esm-es5/wm-date-range.entry.js +1 -1
  44. package/dist/esm-es5/wm-datepicker.entry.js +1 -1
  45. package/dist/esm-es5/wm-input.entry.js +1 -1
  46. package/dist/esm-es5/wm-nested-select.entry.js +1 -1
  47. package/dist/esm-es5/wm-option_2.entry.js +1 -1
  48. package/dist/esm-es5/wm-tag-input.entry.js +1 -1
  49. package/dist/esm-es5/wm-textarea.entry.js +1 -1
  50. package/dist/esm-es5/wm-timepicker.entry.js +1 -1
  51. package/dist/esm-es5/wm-uploader.entry.js +1 -1
  52. package/dist/ripple/p-22cbfae3.entry.js +1 -0
  53. package/dist/ripple/{p-736dc15d.system.entry.js → p-2e6a00b8.system.entry.js} +1 -1
  54. package/dist/ripple/{p-321d4148.system.entry.js → p-466e929a.system.entry.js} +1 -1
  55. package/dist/ripple/{p-99a2a45c.entry.js → p-52809f00.entry.js} +1 -1
  56. package/dist/ripple/{p-65ba88b7.system.js → p-5c11ded6.system.js} +1 -1
  57. package/dist/ripple/{p-0460b298.entry.js → p-5f54cc72.entry.js} +1 -1
  58. package/dist/ripple/{p-61f780ab.entry.js → p-6324b988.entry.js} +1 -1
  59. package/dist/ripple/{p-0a47f460.entry.js → p-6eeec16f.entry.js} +1 -1
  60. package/dist/ripple/{p-dab72fca.system.entry.js → p-7176d77c.system.entry.js} +1 -1
  61. package/dist/ripple/{p-73d1ec58.js → p-73f5e414.js} +1 -1
  62. package/dist/ripple/{p-3b9ddb71.system.entry.js → p-822d0762.system.entry.js} +1 -1
  63. package/dist/ripple/{p-140d1765.system.entry.js → p-87e4a0d5.system.entry.js} +1 -1
  64. package/dist/ripple/p-8a14c33d.entry.js +1 -0
  65. package/dist/ripple/{p-020e58d2.system.entry.js → p-8f6aa68c.system.entry.js} +1 -1
  66. package/dist/ripple/{p-e9d745e1.system.js → p-9a0ebc18.system.js} +1 -1
  67. package/dist/ripple/{p-4086d2f2.system.entry.js → p-a2646792.system.entry.js} +1 -1
  68. package/dist/ripple/{p-eb68ec38.entry.js → p-a76fd8bc.entry.js} +1 -1
  69. package/dist/ripple/{p-3ef56754.system.entry.js → p-b1b9f0de.system.entry.js} +1 -1
  70. package/dist/ripple/p-be4f76b4.entry.js +1 -0
  71. package/dist/ripple/{p-21361a84.entry.js → p-cc1ab21b.entry.js} +1 -1
  72. package/dist/ripple/{p-7a68fd88.system.entry.js → p-e9e069bb.system.entry.js} +1 -1
  73. package/dist/ripple/{p-5e15c72a.system.entry.js → p-ee423b70.system.entry.js} +1 -1
  74. package/dist/ripple/{p-742451fa.entry.js → p-f7543de4.entry.js} +1 -1
  75. package/dist/ripple/ripple.esm.js +1 -1
  76. package/dist/ripple/ripple.js +1 -1
  77. package/package.json +2 -2
  78. package/dist/ripple/p-8e59cec0.entry.js +0 -1
  79. package/dist/ripple/p-9f27c966.entry.js +0 -1
  80. package/dist/ripple/p-ef3a4568.entry.js +0 -1
@@ -1277,13 +1277,16 @@
1277
1277
  flex-basis: 42px;
1278
1278
  }
1279
1279
  .popup-wrapper .month-view .months {
1280
- border-top: 2px solid;
1281
- border-top-color: var(--wmcolor-datepicker-month-border);
1282
1280
  display: -webkit-box;
1283
1281
  display: -webkit-flex;
1284
1282
  display: -ms-flexbox;
1285
1283
  display: flex;
1286
1284
  flex-wrap: wrap;
1285
+ gap: 0.125rem;
1286
+ background-color: var(--wmcolor-datepicker-month-border);
1287
+ border-top: 0.125rem solid;
1288
+ border-bottom: 0.125rem solid;
1289
+ border-color: transparent;
1287
1290
  }
1288
1291
  .popup-wrapper .month-view .month-row {
1289
1292
  display: -webkit-box;
@@ -1295,8 +1298,7 @@
1295
1298
  -webkit-justify-content: space-between;
1296
1299
  justify-content: space-between;
1297
1300
  width: 100%;
1298
- border-bottom: 2px solid;
1299
- border-bottom-color: var(--wmcolor-datepicker-month-border);
1301
+ gap: 0.125rem;
1300
1302
  }
1301
1303
  .popup-wrapper .month-view .month {
1302
1304
  border: none;
@@ -1309,12 +1311,7 @@
1309
1311
  font-weight: 500;
1310
1312
  color: var(--wmcolor-datepicker-month-text);
1311
1313
  }
1312
- .popup-wrapper .month-view .month:not(:last-child) {
1313
- border-right: 2px solid;
1314
- border-right-color: var(--wmcolor-datepicker-month-border);
1315
- }
1316
1314
  .popup-wrapper .month-view .month:hover {
1317
- border-right-color: transparent;
1318
1315
  background-color: var(--wmcolor-datepicker-month-background-hover);
1319
1316
  }
1320
1317
  .popup-wrapper .month-view .month:active, .popup-wrapper .month-view .month.selected {
@@ -1326,8 +1323,8 @@
1326
1323
  .popup-wrapper .date-cell:focus-visible:not(.preview-start, .preview-end) {
1327
1324
  outline: 3px solid var(--wmcolor-interactive-focus);
1328
1325
  outline-offset: -2px;
1329
- border: none;
1330
1326
  z-index: 11;
1327
+ box-shadow: inset 0 0 0 4px #ffffff;
1331
1328
  }
1332
1329
  .popup-wrapper button:focus-visible:not(.preview-start, .preview-end)[aria-selected=true],
1333
1330
  .popup-wrapper .month.focused:focus-visible:not(.preview-start, .preview-end)[aria-selected=true],
@@ -176,7 +176,7 @@ export class PrivCalendar {
176
176
  classesArr.push("preview-end");
177
177
  }
178
178
  const classes = classesArr.join(" ");
179
- return (h("div", { role: "gridcell", id: `cell-${date}`, class: classes, "aria-selected": selected, "aria-label": `${isToday
179
+ return (h("div", { role: "gridcell", id: `cell-${date}-${this.uid}`, class: classes, "aria-selected": selected, "aria-label": `${isToday
180
180
  ? `${intl.formatMessage({
181
181
  id: "date.today",
182
182
  defaultMessage: "today",
@@ -237,10 +237,10 @@ export class PrivCalendar {
237
237
  newCell.tabIndex = 0;
238
238
  }
239
239
  else {
240
- const oldMonthEl = this.el.querySelector(`#month-${dateFind.month.asInt(oldVal)}`);
240
+ const oldMonthEl = this.el.querySelector(`#month-${dateFind.month.asInt(oldVal)}-${this.uid}`);
241
241
  if (oldMonthEl)
242
242
  oldMonthEl.tabIndex = -1;
243
- const newMonthEl = this.el.querySelector(`#month-${dateFind.month.asInt(newVal)}`);
243
+ const newMonthEl = this.el.querySelector(`#month-${dateFind.month.asInt(newVal)}-${this.uid}`);
244
244
  if (newMonthEl)
245
245
  newMonthEl.tabIndex = 0;
246
246
  //monthToFocus.focus();
@@ -447,7 +447,7 @@ export class PrivCalendar {
447
447
  return [...cellsBefore, ...dates, ...cellsAfter];
448
448
  }
449
449
  getCell(date) {
450
- return this.el.querySelector(`#cell-${date}`);
450
+ return this.el.querySelector(`#cell-${date}-${this.uid}`);
451
451
  }
452
452
  async focusFirstFocusable() {
453
453
  this.prevBtnEl.focus();
@@ -484,7 +484,7 @@ export class PrivCalendar {
484
484
  this.el.querySelector("#wm-container").setAttribute("aria-busy", state);
485
485
  }
486
486
  renderMonth(month, index) {
487
- return (h("button", { id: `month-${index + 1}`, class: `month ${this._focus.month.asInt() === index + 1 ? "selected focused" : ""}`, role: "gridcell", tabindex: index + 1 === this._focus.month.asInt() ? 0 : -1, onBlur: (ev) => ev.stopPropagation(), onClick: () => {
487
+ return (h("button", { id: `month-${index + 1}-${this.uid}`, class: `month ${this._focus.month.asInt() === index + 1 ? "selected focused" : ""}`, role: "gridcell", tabindex: index + 1 === this._focus.month.asInt() ? 0 : -1, onBlur: (ev) => ev.stopPropagation(), onClick: () => {
488
488
  this._focus.month.set(index + 1);
489
489
  this.view = "day";
490
490
  this.focusCell();
@@ -500,14 +500,14 @@ export class PrivCalendar {
500
500
  else if (this.view == "month") {
501
501
  this._focus.year.decrease(1);
502
502
  }
503
- }, class: "header-btn arw-btn", ref: (el) => (this.prevBtnEl = el), "aria-label": previousButtonLabel, onMouseOver: () => showTooltip("right", this.prevBtnEl, previousButtonLabel), onMouseLeave: () => hideTooltip(), onFocus: () => showTooltip("right", this.prevBtnEl, previousButtonLabel), onBlur: () => hideTooltip() }, h("span", { class: "svg-icon svg-previous" })), h("span", { class: "header-title" }, calendar_months[this._focus.month.asInt() - 1], " ", this._focus.year.asString()), this.renderToggleButton(), h("button", { onClick: () => {
503
+ }, class: "header-btn arw-btn", ref: (el) => (this.prevBtnEl = el), "aria-label": previousButtonLabel, onMouseOver: () => showTooltip("right", this.prevBtnEl, previousButtonLabel), onMouseLeave: () => hideTooltip(), onFocus: () => showTooltip("right", this.prevBtnEl, previousButtonLabel), onBlur: () => hideTooltip() }, h("span", { class: "svg-icon svg-previous" })), h("span", { class: "header-title" }, calendar_months[this._focus.month.asInt() - 1], " ", this._focus.year.asString()), h("button", { onClick: () => {
504
504
  if (this.view == "day") {
505
505
  this._focus.month.increase(1);
506
506
  }
507
507
  else if (this.view == "month") {
508
508
  this._focus.year.increase(1);
509
509
  }
510
- }, "aria-label": nextButtonLabel, class: "header-btn arw-btn", ref: (el) => (this.nextBtnEl = el), onMouseOver: () => showTooltip("right", this.nextBtnEl, nextButtonLabel), onMouseLeave: () => hideTooltip(), onFocus: () => showTooltip("right", this.nextBtnEl, nextButtonLabel), onBlur: () => hideTooltip() }, h("span", { class: "svg-icon svg-next" }))));
510
+ }, "aria-label": nextButtonLabel, class: "header-btn arw-btn", ref: (el) => (this.nextBtnEl = el), onMouseOver: () => showTooltip("right", this.nextBtnEl, nextButtonLabel), onMouseLeave: () => hideTooltip(), onFocus: () => showTooltip("right", this.nextBtnEl, nextButtonLabel), onBlur: () => hideTooltip() }, h("span", { class: "svg-icon svg-next" })), this.renderToggleButton()));
511
511
  }
512
512
  renderToggleButton() {
513
513
  return (h("div", { class: "toggle-button" }, h("div", { class: "input-wrapper left" }, h("input", { type: "radio", id: `month-radio-${this.uid}`, "aria-label": intl.formatMessage({
@@ -567,11 +567,11 @@ export class PrivCalendar {
567
567
  return (h("div", { class: "month-view" }, h("div", { "aria-labelledby": "popup-title-year", role: "grid", class: "months" }, h("div", { role: "row", class: "month-row" }, calendar_months.slice(0, 3).map((month, index) => this.renderMonth(month, index))), h("div", { role: "row", class: "month-row" }, calendar_months.slice(3, 6).map((month, index) => this.renderMonth(month, index + 3))), h("div", { role: "row", class: "month-row" }, calendar_months.slice(6, 9).map((month, index) => this.renderMonth(month, index + 6))), h("div", { role: "row", class: "month-row" }, calendar_months.slice(9).map((month, index) => this.renderMonth(month, index + 9))))));
568
568
  }
569
569
  render() {
570
- return (h(Host, { key: '5ac1252b33ef3a43fecf9c3221938389cf1d3681', onMouseOut: (ev) => {
570
+ return (h(Host, { key: '3787997230f2db89ba8e051b757d986a1b41f51d', onMouseOut: (ev) => {
571
571
  // @ts-ignore
572
572
  if (!this.el.parentElement.contains(ev.toElement))
573
573
  this.outOfCal.emit();
574
- }, role: "application", "aria-describedby": "application" }, h("div", { key: 'e92179ff0e073bb0713728d6781ac4d040543169', class: `popup ${this.view}-view` }, this.renderHeader(), this.view === "day" ? this.renderDayView() : this.renderMonthView()), h("div", { key: 'c16391c078271ae7fef7fdb55ac268b746d06124', id: "application", class: "sr-only" }, this.calName, this.calInstructions)));
574
+ }, role: "application", "aria-describedby": `application-${this.uid}` }, h("div", { key: 'c82e165ff59c7e1fb5f955410c8db3d7c604c285', class: `popup ${this.view}-view` }, this.renderHeader(), this.view === "day" ? this.renderDayView() : this.renderMonthView()), h("div", { key: '2e5e1276ed683f6893bec62dd461cc250b61a7b8', id: `application-${this.uid}`, class: "sr-only" }, this.calName, this.calInstructions)));
575
575
  }
576
576
  static get is() { return "priv-calendar"; }
577
577
  static get originalStyleUrls() {
@@ -176,6 +176,10 @@ export class DateRange {
176
176
  }
177
177
  }
178
178
  }
179
+ window.setTimeout(() => {
180
+ // ensure focused element is visible if popup opens below the fold
181
+ this.startCalEl.scrollIntoView({ behavior: "smooth", block: "nearest" });
182
+ }, 250);
179
183
  }
180
184
  handleFocus() {
181
185
  this.wrapperEl.classList.add("focus");
@@ -440,23 +444,23 @@ export class DateRange {
440
444
  }
441
445
  }
442
446
  render() {
443
- return (h(Host, { key: 'e15e7d0122385b7038ab66267c6bd97a0484403e', "aria-busy": "false" }, h("div", { key: '1074c893c309a965181575e65ddab158e7b34661', ref: (d) => (this.wrapperEl = d), class: "wrapper" }, h("div", { key: '318998d9218b262a13c2842a03c8e493f889b327', class: `range-wrapper ${this.calWidth <= this.availSpace ? "cal" : ""}` }, h("div", { key: 'e2df44669d920d0fa287d3020a0ad29485cd03d7', class: "label-wrapper", id: "start-label-wrapper" }, h("label", { key: '34bdc1d6844cfca7b50c79c7dd2f7115889665a2', ref: (e) => (this.labelEl = e), id: "startlabel", htmlFor: "start-date-input", class: "label", title: `${this.labelStart} (${this.dateFormat})` }, this.labelStart, this.requiredField && (h("span", { key: '50d76500d1ddd31478ec3a1fb737fca8a2957e24', "aria-hidden": "true", class: "required" }, "*")))), h("div", { key: 'e7d8fcb4399881832d7a37042aee7a820512e2f0', class: "label-wrapper", id: "end-label-wrapper" }, h("label", { key: '86b127ee4ecc42fca26521bf19777553c55bdc79', id: "endlabel", htmlFor: "end-date-input", class: "label", title: `${this.labelEnd} (${this.dateFormat})` }, this.labelEnd, this.requiredField && (h("span", { key: '14ccfb0e9fee57f645112e1925b47e6697852f76', "aria-hidden": "true", class: "required" }, "*")))), h("input", { key: '4fbee8adcdd045ff543c530dcce96b8e1c812561', disabled: this._disabled, type: "text", id: "start-date-input", class: `date-input input ${this.invalidStart ? "invalid" : ""}`, name: "start-date", placeholder: this.dateFormat, value: this.valueStart, onFocus: () => this.handleFocus(), onInput: (ev) => this.handleStartInput(ev), onBlur: () => this.handleStartInputBlur(), ref: (input) => (this.startInputEl = input), "aria-describedby": "error", "aria-label": this.labelStart, "aria-required": this.requiredField ? "true" : null }), h("div", { key: '8532a1ee3ab5ed0eb678e0626d15ed59a30b159d', id: "hyphen" }, "\u00A0-\u00A0"), h("input", { key: '5083b4873f884f26221b756f1ab2b39f359aecdd', disabled: this._disabled, type: "text", id: "end-date-input", class: `date-input input ${this.invalidEnd ? "invalid" : ""}`, name: "end-date", placeholder: this.dateFormat, value: this.valueEnd, onFocus: () => this.handleFocus(), onInput: (ev) => this.handleEndInput(ev), onBlur: () => this.handleEndInputBlur(), ref: (input) => (this.endInputEl = input), "aria-describedby": "error", "aria-label": this.labelEnd, "aria-required": this.requiredField ? "true" : null }), h("div", { key: '4c6fefec380fae6c6964e10bc2e6eeae1dbb560a', class: "toggle-wrapper", id: "toggle-wrapper" }, this.calWidth <= this.availSpace && (h("button", { key: 'dd11cd572ddf6ce4c44af9bdffc6a129174ede8b', disabled: this.disabled, onClick: this.togglePopup.bind(this), "aria-describedby": "start-date-input end-date-input", "aria-label": intl.formatMessage({
447
+ return (h(Host, { key: '3ef7ed01702cd08cb88153b157c05870f357b83d', "aria-busy": "false" }, h("div", { key: 'a26ffe7e83d668c81c361a2baf5111d338074f4f', ref: (d) => (this.wrapperEl = d), class: "wrapper" }, h("div", { key: '5110a41705760e61460ae63222d33983f50cbbcc', class: `range-wrapper ${this.calWidth <= this.availSpace ? "cal" : ""}` }, h("div", { key: 'cd73ac4cd1156a08f8433cd5172c308e73f468e5', class: "label-wrapper", id: "start-label-wrapper" }, h("label", { key: '7fa4734f43aecd6a5cb73d93c1162fd5783ad2ac', ref: (e) => (this.labelEl = e), id: "startlabel", htmlFor: "start-date-input", class: "label", title: `${this.labelStart} (${this.dateFormat})` }, this.labelStart, this.requiredField && (h("span", { key: 'be4ad3de3b7b1fa8b1f20ae86502e661d5561f9c', "aria-hidden": "true", class: "required" }, "*")))), h("div", { key: '274e44b68f05bdc28ab25836ee5162876ba2dc37', class: "label-wrapper", id: "end-label-wrapper" }, h("label", { key: '439389958522c3245d79cf03ad3f8abf621adfdd', id: "endlabel", htmlFor: "end-date-input", class: "label", title: `${this.labelEnd} (${this.dateFormat})` }, this.labelEnd, this.requiredField && (h("span", { key: '20a1a75cfc195d9503d7f079d56435f3ac7a3ce2', "aria-hidden": "true", class: "required" }, "*")))), h("input", { key: 'c850bd46e4835f8878e2c7d39fe930e38917671c', disabled: this._disabled, type: "text", id: "start-date-input", class: `date-input input ${this.invalidStart ? "invalid" : ""}`, name: "start-date", placeholder: this.dateFormat, value: this.valueStart, onFocus: () => this.handleFocus(), onInput: (ev) => this.handleStartInput(ev), onBlur: () => this.handleStartInputBlur(), ref: (input) => (this.startInputEl = input), "aria-describedby": "error", "aria-label": this.labelStart, "aria-required": this.requiredField ? "true" : null }), h("div", { key: '4cb1a5498a6378b08915563e628f45367892fe4d', id: "hyphen" }, "\u00A0-\u00A0"), h("input", { key: 'a321356204252e7c57dff7b3b392f44d6d0b9cf3', disabled: this._disabled, type: "text", id: "end-date-input", class: `date-input input ${this.invalidEnd ? "invalid" : ""}`, name: "end-date", placeholder: this.dateFormat, value: this.valueEnd, onFocus: () => this.handleFocus(), onInput: (ev) => this.handleEndInput(ev), onBlur: () => this.handleEndInputBlur(), ref: (input) => (this.endInputEl = input), "aria-describedby": "error", "aria-label": this.labelEnd, "aria-required": this.requiredField ? "true" : null }), h("div", { key: 'f6be34dda1f360b99a3708545a151c004b479635', class: "toggle-wrapper", id: "toggle-wrapper" }, this.calWidth <= this.availSpace && (h("button", { key: '5af514ad9b7fd30f5e83ebe83fd35890fdb53ee5', disabled: this.disabled, onClick: this.togglePopup.bind(this), "aria-describedby": "start-date-input end-date-input", "aria-label": intl.formatMessage({
444
448
  id: "date.selectRange",
445
449
  defaultMessage: "Select range",
446
450
  description: "Button text for screen readers.",
447
- }), ref: (el) => (this.toggleEl = el), "aria-expanded": `${this.isExpanded}`, class: "toggle", id: "toggle" }, h("span", { key: '4539c027127c567bfd09039e63975e849dd96fae', class: "svg-icon svg-date" }), h("span", { key: '0fcd41cd2415908975cc8b8f7cebd4bd47f01d3e', class: "calendar", title: intl.formatMessage({
451
+ }), ref: (el) => (this.toggleEl = el), "aria-expanded": `${this.isExpanded}`, class: "toggle", id: "toggle" }, h("span", { key: 'ed9caf670fd667a9959363834c1accebfb0b82cb', class: "svg-icon svg-date" }), h("span", { key: '10bc0a7086071adad12d6cbe5c5c92a82260a619', class: "calendar", title: intl.formatMessage({
448
452
  id: "date.calendarView",
449
453
  defaultMessage: "Calendar View",
450
454
  description: "Calendar button",
451
- }) })))), this.renderCalendars()), h("div", { key: '96d2b3a31aafb89abdbd80e58ecc0efab1a582c4' }, h("div", { key: '75a3aca3bd7ef18924b81f47ab017eef108c10df', id: "live-region", "aria-live": "polite", "aria-relevant": "text", class: "sr-only" }), h("div", { key: 'f7af6d97177bdf7cef6516950eee49e242826e06', id: "month-title", class: "sr-only" }, intl.formatMessage({
455
+ }) })))), this.renderCalendars()), h("div", { key: '6bcacc7025eef282cacfdc9c8ba44c88d01dfb3c' }, h("div", { key: '45942b8f722908db886d39fe23c7ae2e9c39eca5', id: "live-region", "aria-live": "polite", "aria-relevant": "text", class: "sr-only" }), h("div", { key: 'f3613e50ea33148b7027b2fbb9147f8eee2c98a5', id: "month-title", class: "sr-only" }, intl.formatMessage({
452
456
  id: "date.selectMonth",
453
457
  defaultMessage: "Activate to select a month.",
454
458
  description: "Calendar button",
455
- })), h("div", { key: 'aab9385f49a28dc1306e59451234a9a7368aca4d', id: "year-title", class: "sr-only" }, intl.formatMessage({
459
+ })), h("div", { key: 'ca798dd858d872a87852078781058699e3ebc5f6', id: "year-title", class: "sr-only" }, intl.formatMessage({
456
460
  id: "date.selectYear",
457
461
  defaultMessage: "Activate to select a year.",
458
462
  description: "Calendar button",
459
- }))), h("div", { key: '21c76d46ebc51dbfd8b2658512f7e6f7ef4f4ae7', id: "error", class: "error" }, this.errorMessage), h("div", { key: '0312341364d0cf20c63be7f38724b64b13ffd424', ref: (el) => (this.liveRegionEl = el), class: "sr-only", "aria-live": "polite", "aria-atomic": "true" }))));
463
+ }))), h("div", { key: 'e77548bc61a4d4c9bf0b0985694aa298383caf3e', id: "error", class: "error" }, this.errorMessage), h("div", { key: 'ec8b80ac48c0c65cfa7be019dc242e8fa7901332', ref: (el) => (this.liveRegionEl = el), class: "sr-only", "aria-live": "polite", "aria-atomic": "true" }))));
460
464
  }
461
465
  static get is() { return "wm-date-range"; }
462
466
  static get encapsulation() { return "shadow"; }
@@ -1,5 +1,5 @@
1
1
  import { h, Host } from "@stencil/core";
2
- import { intl, toBool, handleDisabledAttribute, hasRoomRight, shouldOpenUp, dateToISO, showTooltip, hideTooltip, findAllScrollableParents, debounce } from "../../global/functions";
2
+ import { intl, toBool, handleDisabledAttribute, hasRoomRight, shouldOpenUp, dateToISO, showTooltip, hideTooltip, findAllScrollableParents, debounce, } from "../../global/functions";
3
3
  export class DatePicker {
4
4
  constructor() {
5
5
  this.openUp = false;
@@ -95,6 +95,10 @@ export class DatePicker {
95
95
  this.calEl.focusDate = this.calendarDate;
96
96
  this.calEl.startDate = this.calendarDate;
97
97
  this.calEl.focusCell();
98
+ window.setTimeout(() => {
99
+ // ensure focused element is visible if popup opens below the fold
100
+ this.calEl.scrollIntoView({ behavior: "smooth", block: "nearest" });
101
+ }, 250);
98
102
  }
99
103
  handleInput(ev) {
100
104
  // keep component's value in sync with input's value
@@ -240,23 +244,23 @@ export class DatePicker {
240
244
  this.liveRegionEl.textContent = message;
241
245
  }
242
246
  render() {
243
- return (h(Host, { key: '3c8895164cdab98f5ecbf5bfdbaad38d37fe9a62', "aria-busy": "false", class: `${this.errorMessage ? "invalid" : ""}` }, h("div", { key: '9ea9a8570ecc5fcdc0ebf6adb6a266199c809ee7', ref: (d) => (this.dpWrapperEl = d), class: `wrapper label-${this.labelPosition} ${this.errorMessage ? "invalid" : ""}` }, h("div", { key: '6375fe774de6a4caf93a7ba25745c02b0ec0ba57', class: "label-wrapper", ref: (e) => (this.labelWrapperEl = e) }, this.labelPosition !== "none" && (h("label", { key: 'b83dc110a272f295447cd0d48e2b9147d53fbb8d', id: "datepickerLabel", htmlFor: "date-input", class: "label", title: `${this.label} (${this.dateFormat})`, onMouseEnter: (ev) => this.handleLabelMouseEnter(ev), onMouseLeave: () => hideTooltip() }, this.label)), this.labelPosition !== "none" && this.requiredField && (h("div", { key: '6518e85a7c9ac42309cdd47b74d6bfa8014b7540', "aria-hidden": "true", class: "required" }, "*"))), h("div", { key: 'd38f3a0672cabd82b946c2b28c56130983279b18' }, h("div", { key: 'c80b4383962d36bb2a4740886b9044095ba8beaa', class: "single-wrapper input" }, h("input", { key: '52c6aed0fcf11c86855876156c5391667337c3f4', disabled: this.isDisabled, type: "text", id: "single-date-input", class: "date-input", name: "date", placeholder: this.dateFormat, value: this.value, onFocus: () => this.handleInputFocus(), onInput: (ev) => this.handleInput(ev), onBlur: () => this.handleInputBlur(), onChange: () => this.handleInputChange(), ref: (input) => (this.inputEl = input), "aria-describedby": "error", "aria-label": this.label, "aria-required": this.requiredField ? "true" : null }), h("div", { key: '85b5cf801ba5db08d0e3196b037aa2c1453365cc', ref: (el) => (this.buttonContainerEl = el), class: "container", id: "wm-container" }, h("button", { key: '33f8a6090fe54b4ef47aad312045582a1ae58ed8', disabled: this.disabled, onClick: this.togglePopup.bind(this), "aria-label": intl.formatMessage({
247
+ return (h(Host, { key: 'e708a7b702e16ab896628a40da86ab055f470239', "aria-busy": "false", class: `${this.errorMessage ? "invalid" : ""}` }, h("div", { key: '95a725cba2a6584498d6b4bdd06528b6f503b0e6', ref: (d) => (this.dpWrapperEl = d), class: `wrapper label-${this.labelPosition} ${this.errorMessage ? "invalid" : ""}` }, h("div", { key: 'd9c06fd00f24195c975098879221347aa3d15bf4', class: "label-wrapper", ref: (e) => (this.labelWrapperEl = e) }, this.labelPosition !== "none" && (h("label", { key: 'a0415f77ff7b905e046b683c0f812207b33cd9b5', id: "datepickerLabel", htmlFor: "date-input", class: "label", title: `${this.label} (${this.dateFormat})`, onMouseEnter: (ev) => this.handleLabelMouseEnter(ev), onMouseLeave: () => hideTooltip() }, this.label)), this.labelPosition !== "none" && this.requiredField && (h("div", { key: 'f9f5b2dffd291ad9ef8efa549cbe188cdd91ab46', "aria-hidden": "true", class: "required" }, "*"))), h("div", { key: '5de094b2394f9517aafbf2a354e08b8d28812d54' }, h("div", { key: '2db3f838409242080ca11817e6e7edd74cd63f5f', class: "single-wrapper input" }, h("input", { key: 'cf2d4bee304b2c8fe8f0ed17265d94a8e0c7f750', disabled: this.isDisabled, type: "text", id: "single-date-input", class: "date-input", name: "date", placeholder: this.dateFormat, value: this.value, onFocus: () => this.handleInputFocus(), onInput: (ev) => this.handleInput(ev), onBlur: () => this.handleInputBlur(), onChange: () => this.handleInputChange(), ref: (input) => (this.inputEl = input), "aria-describedby": "error", "aria-label": this.label, "aria-required": this.requiredField ? "true" : null }), h("div", { key: '95a4200f59d4e590440ca26e1778a07e65cad511', ref: (el) => (this.buttonContainerEl = el), class: "container", id: "wm-container" }, h("button", { key: 'fef2ff2c96d6f4acabaeeb41f777268ccbbdafbb', disabled: this.disabled, onClick: this.togglePopup.bind(this), "aria-label": intl.formatMessage({
244
248
  id: "date.selectDate",
245
249
  defaultMessage: "Select date",
246
250
  description: "Button text for screen readers.",
247
- }), "aria-describedby": "single-date-input", ref: (el) => (this.toggleEl = el), "aria-expanded": `${this.isExpanded}`, class: "toggle", id: "toggle" }, h("span", { key: '491cb3be198abee09df7ec1fe34bdda86ddf6707', class: "svg-icon svg-date" }), h("span", { key: 'b2deeff0a5822ca585fdc3e3ed9ad7d5f7996bcc', class: "calendar", title: intl.formatMessage({
251
+ }), "aria-describedby": "single-date-input", ref: (el) => (this.toggleEl = el), "aria-expanded": `${this.isExpanded}`, class: "toggle", id: "toggle" }, h("span", { key: '8840e4a6e51836b8202e886c996c40450dff54f4', class: "svg-icon svg-date" }), h("span", { key: 'ae9853231c111e69b1fb5bc2da1ad1338a8ddff6', class: "calendar", title: intl.formatMessage({
248
252
  id: "date.calendarView",
249
253
  defaultMessage: "Calendar View",
250
254
  description: "Calendar button",
251
- }) })), h("div", { key: 'c7d1d49397c09c8f55bcb5a5a8fcf29736f6acd0', class: `popup-wrapper ${this.calEl && this.calEl.view}-view ${this.openUp ? "expand-upwards" : ""}`, id: "popup-wrapper", ref: (el) => (this.popupEl = el), onClick: () => (this.popupClicked = true) }, h("div", { key: '958d2a839b22ccfbc8eee7d09c463444214446f3', tabIndex: 0, onFocus: () => this.calEl.focusLastFocusable() }), h("priv-calendar", { key: '404503eaa6347dc47abb6aec0b283ed069d7cfaf', ref: (el) => (this.calEl = el), startDate: this.calendarDate, focusDate: this.calendarDate, class: "inside" }), h("div", { key: '20dfe5daec72956d0257efa8ed7eeb0aded77e61', tabIndex: 0, onFocus: () => this.calEl.focusFirstFocusable() })), h("div", { key: '02b0a0ce577a19de3388b1d0e0d31701a1c20d69', id: "live-region", "aria-live": "polite", "aria-relevant": "text", class: "sr-only" }), h("div", { key: 'e037e76fb31b373ac5001fcd0665e10971e41ed4', id: "month-title", class: "sr-only" }, intl.formatMessage({
255
+ }) })), h("div", { key: '7fa85ff7fb7c8c0ef74792afbfa4963c748c6faf', class: `popup-wrapper ${this.calEl && this.calEl.view}-view ${this.openUp ? "expand-upwards" : ""}`, id: "popup-wrapper", ref: (el) => (this.popupEl = el), onClick: () => (this.popupClicked = true) }, h("div", { key: 'fb71ae8319b5867b521ff45b983c8dd92368a5ff', tabIndex: 0, onFocus: () => this.calEl.focusLastFocusable() }), h("priv-calendar", { key: 'b5d831730977c2f23013b5173bfe4819e870c7fd', ref: (el) => (this.calEl = el), startDate: this.calendarDate, focusDate: this.calendarDate, class: "inside" }), h("div", { key: 'e988546871ed5520f8ba1c175b144afef8e8a3da', tabIndex: 0, onFocus: () => this.calEl.focusFirstFocusable() })), h("div", { key: 'ed118033c782ffdf40f2cec2d014215bbf8b7f8f', id: "live-region", "aria-live": "polite", "aria-relevant": "text", class: "sr-only" }), h("div", { key: '5ccca72007a577bf6c7652dcce65c38c7d6142c6', id: "month-title", class: "sr-only" }, intl.formatMessage({
252
256
  id: "date.selectMonth",
253
257
  defaultMessage: "Activate to select a month.",
254
258
  description: "Calendar button",
255
- })), h("div", { key: 'f95a9f2c09f9338484bfdc61ca1719ce1d0a0bc5', id: "year-title", class: "sr-only" }, intl.formatMessage({
259
+ })), h("div", { key: 'cd0f6ae54b21dff099969f83699670e324919d45', id: "year-title", class: "sr-only" }, intl.formatMessage({
256
260
  id: "date.selectYear",
257
261
  defaultMessage: "Activate to select a year.",
258
262
  description: "Calendar button",
259
- })))), h("div", { key: '70885563a2af8a58e00927c6a8b9d505013c6b12', id: "error", class: "error" }, this.errorMessage), h("div", { key: '9679d419ba88cbed56fadc161ee2c18a1d733b81', ref: (el) => (this.liveRegionEl = el), class: "sr-only", "aria-live": "polite", "aria-atomic": "true" })))));
263
+ })))), h("div", { key: '66b8fe166a802681107b0546ec615ffaa4d6e280', id: "error", class: "error" }, this.errorMessage), h("div", { key: '71fdd1819720a5b6f91d25c37f2b1011ead21c3d', ref: (el) => (this.liveRegionEl = el), class: "sr-only", "aria-live": "polite", "aria-atomic": "true" })))));
260
264
  }
261
265
  static get is() { return "wm-datepicker"; }
262
266
  static get encapsulation() { return "shadow"; }
@@ -922,7 +922,7 @@
922
922
  white-space: normal;
923
923
  margin-bottom: 0;
924
924
  }
925
- .wrapper.label-none label {
925
+ .wrapper.label-none .label-wrapper label {
926
926
  position: absolute !important;
927
927
  width: 1px !important;
928
928
  height: 1px !important;
@@ -938,7 +938,7 @@
938
938
  white-space: normal;
939
939
  margin-bottom: 0;
940
940
  }
941
- .wrapper.label-none label {
941
+ .wrapper.label-none .label-wrapper label {
942
942
  position: absolute !important;
943
943
  width: 1px !important;
944
944
  height: 1px !important;
@@ -917,7 +917,7 @@
917
917
  white-space: normal;
918
918
  margin-bottom: 0;
919
919
  }
920
- :host .wrapper.label-none label {
920
+ :host .wrapper.label-none .label-wrapper label {
921
921
  position: absolute !important;
922
922
  width: 1px !important;
923
923
  height: 1px !important;
@@ -938,7 +938,7 @@
938
938
  white-space: normal;
939
939
  margin-bottom: 0;
940
940
  }
941
- :host .wrapper.label-none label {
941
+ :host .wrapper.label-none .label-wrapper label {
942
942
  position: absolute !important;
943
943
  width: 1px !important;
944
944
  height: 1px !important;
@@ -912,7 +912,7 @@
912
912
  white-space: normal;
913
913
  margin-bottom: 0;
914
914
  }
915
- :host .wrapper.label-none label {
915
+ :host .wrapper.label-none .label-wrapper label {
916
916
  position: absolute !important;
917
917
  width: 1px !important;
918
918
  height: 1px !important;
@@ -917,7 +917,7 @@
917
917
  white-space: normal;
918
918
  margin-bottom: 0;
919
919
  }
920
- :host .wrapper.label-none label {
920
+ :host .wrapper.label-none .label-wrapper label {
921
921
  position: absolute !important;
922
922
  width: 1px !important;
923
923
  height: 1px !important;
@@ -1682,7 +1682,7 @@
1682
1682
  white-space: normal;
1683
1683
  margin-bottom: 0;
1684
1684
  }
1685
- .wrapper.label-none label {
1685
+ .wrapper.label-none .label-wrapper label {
1686
1686
  position: absolute !important;
1687
1687
  width: 1px !important;
1688
1688
  height: 1px !important;
@@ -1,6 +1,6 @@
1
1
  import './index-130e07bb.js';
2
2
 
3
- const version = "5.21.0-alpha.1";
3
+ const version = "5.21.0-alpha.3";
4
4
 
5
5
  // PRINT RIPPLE VERSION IN CONSOLE
6
6
  // test envs return 0 for plugin.length
@@ -1,6 +1,6 @@
1
1
  import { b as bootstrapLazy } from './index-130e07bb.js';
2
2
  export { s as setNonce } from './index-130e07bb.js';
3
- import { g as globalScripts } from './app-globals-1505b33c.js';
3
+ import { g as globalScripts } from './app-globals-3da2b209.js';
4
4
 
5
5
  const defineCustomElements = async (win, options) => {
6
6
  if (typeof window === 'undefined') return undefined;