@watermarkinsights/ripple 3.12.0 → 3.13.0-9

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 (176) hide show
  1. package/dist/cjs/{chartFunctions-44ae2eee.js → chartFunctions-34fdd3ce.js} +1 -1
  2. package/dist/cjs/{functions-1a67b971.js → functions-120449cf.js} +245 -32
  3. package/dist/cjs/{global-122fc638.js → global-1d1d0ab3.js} +7 -5
  4. package/dist/cjs/loader.cjs.js +2 -2
  5. package/dist/cjs/priv-chart-popover.cjs.entry.js +1 -1
  6. package/dist/cjs/priv-datepicker.cjs.entry.js +1 -1
  7. package/dist/cjs/ripple.cjs.js +2 -2
  8. package/dist/cjs/wm-action-menu_2.cjs.entry.js +1 -1
  9. package/dist/cjs/wm-button.cjs.entry.js +50 -38
  10. package/dist/cjs/wm-chart.cjs.entry.js +2 -2
  11. package/dist/cjs/wm-datepicker.cjs.entry.js +1 -1
  12. package/dist/cjs/wm-input.cjs.entry.js +1 -1
  13. package/dist/cjs/wm-modal-footer.cjs.entry.js +1 -1
  14. package/dist/cjs/wm-modal-header.cjs.entry.js +1 -1
  15. package/dist/cjs/wm-modal.cjs.entry.js +1 -1
  16. package/dist/cjs/wm-navigation_3.cjs.entry.js +1 -1
  17. package/dist/cjs/wm-navigator.cjs.entry.js +1 -1
  18. package/dist/cjs/wm-network-uploader.cjs.entry.js +6 -4
  19. package/dist/cjs/wm-option_2.cjs.entry.js +345 -122
  20. package/dist/cjs/wm-pagination.cjs.entry.js +1 -1
  21. package/dist/cjs/wm-progress-indicator_3.cjs.entry.js +2 -2
  22. package/dist/cjs/wm-search.cjs.entry.js +1 -1
  23. package/dist/cjs/wm-snackbar.cjs.entry.js +1 -1
  24. package/dist/cjs/wm-tab-item_3.cjs.entry.js +1 -1
  25. package/dist/cjs/wm-tag-input.cjs.entry.js +1 -1
  26. package/dist/cjs/wm-timepicker.cjs.entry.js +1 -1
  27. package/dist/cjs/wm-toggletip.cjs.entry.js +4 -4
  28. package/dist/cjs/wm-uploader.cjs.entry.js +9 -11
  29. package/dist/collection/components/wm-button/wm-button.css +1 -0
  30. package/dist/collection/components/wm-button/wm-button.js +50 -40
  31. package/dist/collection/components/wm-modal/wm-modal-footer.js +1 -1
  32. package/dist/collection/components/wm-option/wm-option.css +12 -0
  33. package/dist/collection/components/wm-option/wm-option.js +34 -29
  34. package/dist/collection/components/wm-select/wm-select.css +76 -23
  35. package/dist/collection/components/wm-select/wm-select.js +385 -125
  36. package/dist/collection/components/wm-toggletip/wm-toggletip.js +5 -5
  37. package/dist/collection/components/wm-uploader/wm-network-uploader/wm-network-uploader.css +0 -3
  38. package/dist/collection/components/wm-uploader/wm-network-uploader/wm-network-uploader.js +4 -2
  39. package/dist/collection/components/wm-uploader/wm-uploader.css +1 -5
  40. package/dist/collection/components/wm-uploader/wm-uploader.js +7 -9
  41. package/dist/collection/global/__mocks__/functions.js +9 -0
  42. package/dist/collection/global/functions.js +1 -28
  43. package/dist/collection/global/global.js +6 -4
  44. package/dist/esm/{chartFunctions-8fa800a6.js → chartFunctions-20f05eb5.js} +1 -1
  45. package/dist/esm/{functions-61c7bb1f.js → functions-036af8dc.js} +245 -32
  46. package/dist/esm/{global-5902ef31.js → global-590c515d.js} +7 -5
  47. package/dist/esm/loader.js +2 -2
  48. package/dist/esm/priv-chart-popover.entry.js +1 -1
  49. package/dist/esm/priv-datepicker.entry.js +1 -1
  50. package/dist/esm/ripple.js +2 -2
  51. package/dist/esm/wm-action-menu_2.entry.js +1 -1
  52. package/dist/esm/wm-button.entry.js +51 -39
  53. package/dist/esm/wm-chart.entry.js +2 -2
  54. package/dist/esm/wm-datepicker.entry.js +1 -1
  55. package/dist/esm/wm-input.entry.js +1 -1
  56. package/dist/esm/wm-modal-footer.entry.js +1 -1
  57. package/dist/esm/wm-modal-header.entry.js +1 -1
  58. package/dist/esm/wm-modal.entry.js +1 -1
  59. package/dist/esm/wm-navigation_3.entry.js +1 -1
  60. package/dist/esm/wm-navigator.entry.js +1 -1
  61. package/dist/esm/wm-network-uploader.entry.js +6 -4
  62. package/dist/esm/wm-option_2.entry.js +345 -122
  63. package/dist/esm/wm-pagination.entry.js +1 -1
  64. package/dist/esm/wm-progress-indicator_3.entry.js +2 -2
  65. package/dist/esm/wm-search.entry.js +1 -1
  66. package/dist/esm/wm-snackbar.entry.js +1 -1
  67. package/dist/esm/wm-tab-item_3.entry.js +1 -1
  68. package/dist/esm/wm-tag-input.entry.js +1 -1
  69. package/dist/esm/wm-timepicker.entry.js +1 -1
  70. package/dist/esm/wm-toggletip.entry.js +4 -4
  71. package/dist/esm/wm-uploader.entry.js +9 -11
  72. package/dist/esm-es5/{chartFunctions-8fa800a6.js → chartFunctions-20f05eb5.js} +1 -1
  73. package/dist/esm-es5/{functions-61c7bb1f.js → functions-036af8dc.js} +2 -2
  74. package/dist/esm-es5/global-590c515d.js +1 -0
  75. package/dist/esm-es5/loader.js +1 -1
  76. package/dist/esm-es5/priv-chart-popover.entry.js +1 -1
  77. package/dist/esm-es5/priv-datepicker.entry.js +1 -1
  78. package/dist/esm-es5/ripple.js +1 -1
  79. package/dist/esm-es5/wm-action-menu_2.entry.js +1 -1
  80. package/dist/esm-es5/wm-button.entry.js +1 -1
  81. package/dist/esm-es5/wm-chart.entry.js +1 -1
  82. package/dist/esm-es5/wm-datepicker.entry.js +1 -1
  83. package/dist/esm-es5/wm-input.entry.js +1 -1
  84. package/dist/esm-es5/wm-modal-footer.entry.js +1 -1
  85. package/dist/esm-es5/wm-modal-header.entry.js +1 -1
  86. package/dist/esm-es5/wm-modal.entry.js +1 -1
  87. package/dist/esm-es5/wm-navigation_3.entry.js +1 -1
  88. package/dist/esm-es5/wm-navigator.entry.js +1 -1
  89. package/dist/esm-es5/wm-network-uploader.entry.js +1 -1
  90. package/dist/esm-es5/wm-option_2.entry.js +1 -1
  91. package/dist/esm-es5/wm-pagination.entry.js +1 -1
  92. package/dist/esm-es5/wm-progress-indicator_3.entry.js +1 -1
  93. package/dist/esm-es5/wm-search.entry.js +1 -1
  94. package/dist/esm-es5/wm-snackbar.entry.js +1 -1
  95. package/dist/esm-es5/wm-tab-item_3.entry.js +1 -1
  96. package/dist/esm-es5/wm-tag-input.entry.js +1 -1
  97. package/dist/esm-es5/wm-timepicker.entry.js +1 -1
  98. package/dist/esm-es5/wm-toggletip.entry.js +1 -1
  99. package/dist/esm-es5/wm-uploader.entry.js +1 -1
  100. package/dist/ripple/{p-28bf6a2e.system.js → p-04d8b674.system.js} +1 -1
  101. package/dist/ripple/{p-d3ed8b65.system.entry.js → p-04e44b30.system.entry.js} +1 -1
  102. package/dist/ripple/{p-fdc4a599.system.entry.js → p-0556279c.system.entry.js} +1 -1
  103. package/dist/ripple/{p-1242752c.system.entry.js → p-06adbeb9.system.entry.js} +1 -1
  104. package/dist/ripple/{p-42aa51fe.system.entry.js → p-0e9ccc6f.system.entry.js} +1 -1
  105. package/dist/ripple/{p-520b0f54.entry.js → p-17ceb8c1.entry.js} +1 -1
  106. package/dist/ripple/{p-8caae464.entry.js → p-1887286e.entry.js} +1 -1
  107. package/dist/ripple/{p-c873b490.system.entry.js → p-1ccd994d.system.entry.js} +1 -1
  108. package/dist/ripple/p-1d795f42.entry.js +1 -0
  109. package/dist/ripple/p-2996bfe6.entry.js +1 -0
  110. package/dist/ripple/{p-30745db6.entry.js → p-2f860b24.entry.js} +1 -1
  111. package/dist/ripple/p-3489b502.js +1 -0
  112. package/dist/ripple/{p-cd4fda75.entry.js → p-3680b55d.entry.js} +1 -1
  113. package/dist/ripple/p-3745c620.system.js +1 -0
  114. package/dist/ripple/{p-f12a510f.entry.js → p-3a1d6fc4.entry.js} +1 -1
  115. package/dist/ripple/p-42337590.entry.js +1 -0
  116. package/dist/ripple/{p-68155230.system.entry.js → p-49fd7ede.system.entry.js} +1 -1
  117. package/dist/ripple/{p-8aa9f811.js → p-4ecd3430.js} +1 -1
  118. package/dist/ripple/{p-5471864e.system.entry.js → p-62eac2d6.system.entry.js} +1 -1
  119. package/dist/ripple/{p-5e041c35.entry.js → p-6aa6a818.entry.js} +1 -1
  120. package/dist/ripple/{p-487f7419.system.entry.js → p-6bf5cbf4.system.entry.js} +1 -1
  121. package/dist/ripple/{p-e180001c.system.entry.js → p-7173b0a7.system.entry.js} +1 -1
  122. package/dist/ripple/p-726c979a.system.js +15 -0
  123. package/dist/ripple/{p-eacd33cc.system.entry.js → p-752da0fb.system.entry.js} +1 -1
  124. package/dist/ripple/{p-f36b74bf.entry.js → p-7ae1a630.entry.js} +1 -1
  125. package/dist/ripple/{p-8d347cd5.entry.js → p-7ecbf258.entry.js} +1 -1
  126. package/dist/ripple/{p-75ef731b.system.entry.js → p-7ef6a7cf.system.entry.js} +1 -1
  127. package/dist/ripple/p-8612829b.system.entry.js +1 -0
  128. package/dist/ripple/{p-398b2486.system.entry.js → p-895f5ec5.system.entry.js} +1 -1
  129. package/dist/ripple/{p-d3603def.entry.js → p-8de546e8.entry.js} +1 -1
  130. package/dist/ripple/{p-35cfcf9f.entry.js → p-93dee724.entry.js} +1 -1
  131. package/dist/ripple/{p-0f33461d.entry.js → p-97c2b06f.entry.js} +1 -1
  132. package/dist/ripple/{p-9f12284b.system.entry.js → p-995ba16f.system.entry.js} +1 -1
  133. package/dist/ripple/p-9c92c93f.entry.js +1 -0
  134. package/dist/ripple/p-9e09d7a1.entry.js +1 -0
  135. package/dist/ripple/{p-f0656464.entry.js → p-a04ba6c8.entry.js} +1 -1
  136. package/dist/ripple/{p-44035b02.system.entry.js → p-af3ce4fc.system.entry.js} +1 -1
  137. package/dist/ripple/p-bbcafbd6.system.entry.js +1 -0
  138. package/dist/ripple/{p-eee347b4.system.entry.js → p-c1443a0e.system.entry.js} +1 -1
  139. package/dist/ripple/{p-212aac05.system.entry.js → p-ca383a43.system.entry.js} +1 -1
  140. package/dist/ripple/{p-ca2fbd1b.system.js → p-cc247ee1.system.js} +1 -1
  141. package/dist/ripple/{p-73d66b0a.system.entry.js → p-cd3d74d1.system.entry.js} +1 -1
  142. package/dist/ripple/p-d1ac96e1.system.entry.js +1 -0
  143. package/dist/ripple/{p-3f1d8211.system.entry.js → p-d48c56c7.system.entry.js} +1 -1
  144. package/dist/ripple/{p-15b1c11b.js → p-de3367ee.js} +2 -2
  145. package/dist/ripple/{p-e748e22b.entry.js → p-e083fca6.entry.js} +1 -1
  146. package/dist/ripple/{p-3e6498ea.system.entry.js → p-e4439bc3.system.entry.js} +1 -1
  147. package/dist/ripple/{p-e49b9a96.entry.js → p-e524d462.entry.js} +1 -1
  148. package/dist/ripple/{p-92226595.entry.js → p-e8d39f68.entry.js} +1 -1
  149. package/dist/ripple/{p-00fa3d4b.entry.js → p-ed91be1a.entry.js} +1 -1
  150. package/dist/ripple/{p-d81a4e7c.system.entry.js → p-f23b3986.system.entry.js} +1 -1
  151. package/dist/ripple/{p-e75e75e0.entry.js → p-fda61e7e.entry.js} +1 -1
  152. package/dist/ripple/p-fe952112.entry.js +1 -0
  153. package/dist/ripple/ripple.esm.js +1 -1
  154. package/dist/ripple/ripple.js +1 -1
  155. package/dist/types/components/wm-button/wm-button.d.ts +4 -4
  156. package/dist/types/components/wm-option/wm-option.d.ts +5 -2
  157. package/dist/types/components/wm-select/wm-select.d.ts +39 -12
  158. package/dist/types/components/wm-toggletip/wm-toggletip.d.ts +2 -2
  159. package/dist/types/components.d.ts +10 -6
  160. package/dist/types/global/__mocks__/functions.d.ts +1 -0
  161. package/dist/types/global/functions.d.ts +2 -2
  162. package/dist/types/global/interfaces.d.ts +1 -1
  163. package/package.json +1 -1
  164. package/dist/esm-es5/global-5902ef31.js +0 -1
  165. package/dist/ripple/p-1b058a44.entry.js +0 -1
  166. package/dist/ripple/p-2077203e.system.js +0 -1
  167. package/dist/ripple/p-379b125b.entry.js +0 -1
  168. package/dist/ripple/p-49bf0b81.js +0 -1
  169. package/dist/ripple/p-584fef7f.system.entry.js +0 -1
  170. package/dist/ripple/p-72eb5064.system.entry.js +0 -1
  171. package/dist/ripple/p-76ca7498.system.js +0 -15
  172. package/dist/ripple/p-9fe64cec.entry.js +0 -1
  173. package/dist/ripple/p-a82d37d8.entry.js +0 -1
  174. package/dist/ripple/p-ac2485a6.system.entry.js +0 -1
  175. package/dist/ripple/p-ba168596.entry.js +0 -1
  176. package/dist/ripple/p-ed657559.entry.js +0 -1
@@ -1 +1 @@
1
- import{r as t,c as e,h as i,f as s,g as o}from"./p-b3c71506.js";import{i as a,l as r,u as n}from"./p-15b1c11b.js";let h=class{constructor(s){t(this,s),this.cellTriggered=e(this,"cellTriggered",7),this.toggleButtonClicked=e(this,"toggleButtonClicked",7),this.popupClosed=e(this,"popupClosed",7),this.popupBlurred=e(this,"popupBlurred",7),this.disabled=!1,this.isExpanded=!1,this.view="day",this.date=new Date,this.selectedYear=this.date.getUTCFullYear(),this.selectedMonth=this.date.getUTCMonth()+1,this.selectedDay=this.date.getUTCDate(),this.monthInFocus=this.selectedMonth,this.yearInFocus=this.selectedYear,this.dayInFocus=this.selectedDay,this.monthNumInFocus=this.selectedMonth,this.parentId="",this.isTabbing=!1,this.popupClicked=!0,this.buttonClicked=!0,this.prevClicked=!0,this.nextClicked=!0,this.openUp=!1,this.calendar_months=[a.formatMessage({id:"date.january",defaultMessage:"January",description:"Month of the year"}),a.formatMessage({id:"date.february",defaultMessage:"February",description:"Month of the year"}),a.formatMessage({id:"date.march",defaultMessage:"March",description:"Month of the year"}),a.formatMessage({id:"date.april",defaultMessage:"April",description:"Month of the year"}),a.formatMessage({id:"date.may",defaultMessage:"May",description:"Month of the year"}),a.formatMessage({id:"date.june",defaultMessage:"June",description:"Month of the year"}),a.formatMessage({id:"date.july",defaultMessage:"July",description:"Month of the year"}),a.formatMessage({id:"date.august",defaultMessage:"August",description:"Month of the year"}),a.formatMessage({id:"date.september",defaultMessage:"September",description:"Month of the year"}),a.formatMessage({id:"date.october",defaultMessage:"October",description:"Month of the year"}),a.formatMessage({id:"date.november",defaultMessage:"November",description:"Month of the year"}),a.formatMessage({id:"date.december",defaultMessage:"December",description:"Month of the year"})],this.weekdays=[a.formatMessage({id:"date.sunday",defaultMessage:"Sunday"}),a.formatMessage({id:"date.monday",defaultMessage:"Monday"}),a.formatMessage({id:"date.tuesday",defaultMessage:"Tuesday"}),a.formatMessage({id:"date.wednesday",defaultMessage:"Wednesday"}),a.formatMessage({id:"date.thursday",defaultMessage:"Thursday"}),a.formatMessage({id:"date.friday",defaultMessage:"Friday"}),a.formatMessage({id:"date.saturday",defaultMessage:"Saturday"})],this.renderCalendarDate=(t,e)=>{let s=this.removeZeroes(String(t[1])),o=this.removeZeroes(String(t[2])),r=s===this.monthInFocus?"current-month":"";const n=t[0]+t[1]+t[2],h=this.isDateToday(t);return i("div",{role:"gridcell",id:`cell-${n}-${this.parentId}`,class:`date-cell ${r}`,"aria-selected":!1,"aria-label":`${h?`${a.formatMessage({id:"date.today",defaultMessage:"today",description:"calendar button"})}, `:""}${this.weekdays[e]}, ${this.calendar_months[s-1]} ${o}, ${t[0]}`,onClick:t=>{this.handleTriggeredDate(t.target)},onKeyDown:t=>this.trapFocusEnd(t),"data-month":t[1],"data-year":t[0],onBlur:t=>t.stopPropagation()},o)}}handleKey(t){switch(this.prevClicked=!1,this.nextClicked=!1,t.key){case"Enter":t.preventDefault(),!t.target.id.includes("popup-title")&&t.target.click();break;case"Escape":t.preventDefault(),this.isExpanded&&(t.stopPropagation(),this.closePopup(!0));break;case"PageUp":t.preventDefault(),this.backOneMonth();break;case"PageDown":t.preventDefault(),this.forwardOneMonth();break;case"Home":t.preventDefault(),this.unfocusCell(),this.dayInFocus=1,s(this.el);break;case"End":t.preventDefault(),this.unfocusCell(),this.dayInFocus=this.getMonthDays(this.monthInFocus,this.yearInFocus),s(this.el);break;case"ArrowLeft":if(t.preventDefault(),"day"===this.view)if(this.unfocusCell(),1===this.dayInFocus){const t=this.getPreviousMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=t.month,this.yearInFocus=t.year,this.dayInFocus=this.getMonthDays(this.monthInFocus,this.yearInFocus)}else this.dayInFocus-=1;else this.unfocusMonth(),0===this.monthNumInFocus?this.monthNumInFocus=11:this.monthNumInFocus-=1;break;case"ArrowRight":if(t.preventDefault(),"day"===this.view)if(this.unfocusCell(),this.dayInFocus===this.getMonthDays(this.monthInFocus,this.yearInFocus)){const t=this.getNextMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=t.month,this.yearInFocus=t.year,this.dayInFocus=1}else this.dayInFocus+=1;else this.unfocusMonth(),11===this.monthNumInFocus?this.monthNumInFocus=0:this.monthNumInFocus+=1;break;case"ArrowUp":if(t.preventDefault(),"day"===this.view)if(this.unfocusCell(),this.dayInFocus<8){const t=this.getPreviousMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=t.month,this.yearInFocus=t.year;const e=7-this.dayInFocus;this.dayInFocus=this.getMonthDays(this.monthInFocus,this.yearInFocus)-e}else this.dayInFocus-=7;else this.unfocusMonth(),this.monthNumInFocus<3?this.monthNumInFocus+=9:this.monthNumInFocus-=3;break;case"ArrowDown":if(t.preventDefault(),this.isExpanded)if("day"===this.view){if(!(document.activeElement.shadowRoot||document).activeElement.classList.contains("date-cell")){this.focusCell();break}this.unfocusCell();const t=this.getMonthDays(this.monthInFocus,this.yearInFocus)-7;if(this.dayInFocus>t){const e=this.getNextMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=e.month,this.yearInFocus=e.year,this.dayInFocus=this.dayInFocus-t}else this.dayInFocus+=7}else{const t=(document.activeElement.shadowRoot||document).activeElement;if("BUTTON"===t.tagName||t.id.includes("popup-title-year")){this.focusMonth();break}this.unfocusMonth(),this.monthNumInFocus>8?this.monthNumInFocus-=9:this.monthNumInFocus+=3}else this.openPopup()}}toggleTabbingOn(t){["Tab","ArrowUp","ArrowDown","ArrowLeft","ArrowRight","Enter"].includes(t.key)&&(this.isTabbing=!0)}toggleTabbingOff(){this.isTabbing=!1}blurHandler(t){this.popupClicked||this.buttonClicked||!this.isExpanded||(this.closePopup(),this.popupBlurred.emit({relatedTarget:t.target})),this.popupClicked=!1,this.buttonClicked=!1}handleBlurOnWindow(t){this.isExpanded&&(this.closePopup(),this.popupBlurred.emit({relatedTarget:t.target}))}componentDidUpdate(){this.handleSelectedDate(),this.isExpanded&&(this.prevClicked?this.prevButton.focus():this.nextClicked?this.nextButton.focus():"day"===this.view?this.focusCell():this.focusMonth())}componentDidLoad(){this.handleSelectedDate(),this.setDateValuesForView()}zeroPad(t,e){return String.prototype.padStart||(String.prototype.padStart=function(t,e){return(t-=this.length)>e.length&&(e+=e.repeat(t/e.length)),e.slice(0,t)+String(this)}),`${t.toString()}`.padStart(e,"0")}removeZeroes(t){return+t<10?+t.slice(1):+t}isDateToday(t){const e=new Date;return[e.getFullYear().toString(),(e.getMonth()+1).toString(),e.getDate().toString()].reduce(((e,i,s)=>e&&this.removeZeroes(t[s]).toString()===i),!0)}togglePopup(){this.isExpanded?this.closePopup():this.openPopup(),this.buttonClicked=!0}closePopup(t=!1){this.isExpanded=!1,this.popupEl.classList.remove("open"),window.setTimeout((()=>{this.popupEl.style.visibility="hidden"}),250),"day"===this.view&&this.unfocusCell(),this.monthInFocus=this.selectedMonth,this.yearInFocus=this.selectedYear,this.dayInFocus=this.selectedDay,this.changeView("day"),t&&this.buttonEl.focus()}openPopup(){this.panelPosition(),this.setDateValuesForView(),this.prevClicked=!1,this.nextClicked=!1,this.popupEl.style.visibility="visible",window.requestAnimationFrame((()=>{this.popupEl.classList.add("open")})),this.isExpanded=!0,this.focusCell()}getMonthDays(t,e){return 2===t?e%4==0?29:28:[4,6,9,11].includes(t)?30:31}getMonthFirstDay(t,e){return+new Date(e,t-1,1,12,0,0).getDay()+1}getPreviousMonth(t,e){return{month:t>1?t-1:12,year:t>1?e:e-1}}getNextMonth(t,e){return{month:t<12?t+1:1,year:t<12?e:e+1}}getCalendarDates(t,e){const i=this.getMonthDays(t,e),s=this.getMonthFirstDay(t,e)-1;let o=42-(s+i);o=o>6?o-7:o;const{month:a,year:r}=this.getPreviousMonth(t,e),{month:n,year:h}=this.getNextMonth(t,e),d=this.getMonthDays(a,r);return[...[...new Array(s).fill("1")].map(((t,e)=>{const i=e+1+(d-s);return[r.toString(),this.zeroPad(a,2),this.zeroPad(i,2)]})),...[...new Array(i).fill("1")].map(((i,s)=>{const o=s+1;return[e.toString(),this.zeroPad(t,2),this.zeroPad(o,2)]})),...[...new Array(o).fill("1")].map(((t,e)=>{const i=e+1;return[h.toString(),this.zeroPad(n,2),this.zeroPad(i,2)]}))]}forwardOneMonth(){this.unfocusCell();const t=this.getNextMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=t.month,this.yearInFocus=t.year;const e=this.getMonthDays(this.monthInFocus,this.yearInFocus);this.dayInFocus>this.getMonthDays(this.monthInFocus,this.yearInFocus)&&(this.dayInFocus=e),this.updateLiveRegion(`Displaying ${this.calendar_months[this.monthInFocus-1]}, ${this.yearInFocus}`)}backOneMonth(){this.unfocusCell();const t=this.getPreviousMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=t.month,this.yearInFocus=t.year;const e=this.getMonthDays(this.monthInFocus,this.yearInFocus);this.dayInFocus>this.getMonthDays(this.monthInFocus,this.yearInFocus)&&(this.dayInFocus=e),this.updateLiveRegion(`Viewing ${this.calendar_months[this.monthInFocus-1]}, ${this.yearInFocus}`)}handleTriggeredDate(t){this.cellTriggered.emit(t),this.closePopup(!0)}handleSelectedDate(){this.selectedDate&&this.selectedDate.removeAttribute("aria-selected"),this.selectedDate=this.getCellById(this.selectedYear,this.selectedMonth,this.selectedDay),this.selectedDate&&this.selectedDate.setAttribute("aria-selected","true")}getCellById(t,e,i){const s=t+this.zeroPad(e,2)+this.zeroPad(i,2);return this.el.querySelector(`#cell-${s}-${this.parentId}`)}unfocusCell(){this.getCellById(this.yearInFocus,this.monthInFocus,this.dayInFocus).tabIndex=-1}focusCell(){const t=this.getMonthDays(this.monthInFocus,this.yearInFocus);this.dayInFocus=this.dayInFocus>t?t:this.dayInFocus;const e=this.getCellById(this.yearInFocus,this.monthInFocus,this.dayInFocus);e&&(e.tabIndex=0,e.focus())}unfocusMonth(){this.el.querySelector(`#month-${this.monthNumInFocus}-${this.parentId}`).tabIndex=-1}focusMonth(){const t=this.el.querySelector(`#month-${this.monthNumInFocus}-${this.parentId}`);t.tabIndex=0,t.focus()}trapFocusLeft(t){t.shiftKey&&"Tab"===t.key&&(t.preventDefault(),this.focusCellInView())}trapFocusEnd(t){t.shiftKey||"Tab"!==t.key||(t.preventDefault(),this.prevButton.focus())}trapFocusRight(t){t.shiftKey||"Tab"!==t.key||(t.preventDefault(),this.focusCellInView())}focusCellInView(){"day"===this.view?this.focusCell():this.focusMonth()}toggleBusyAttribute(t){this.el.querySelector("#wm-container").setAttribute("aria-busy",t)}setDateValuesForView(){this.selectedYear=this.date.getUTCFullYear(),this.selectedMonth=this.date.getUTCMonth()+1,this.selectedDay=this.date.getUTCDate(),this.monthInFocus=this.selectedMonth,this.yearInFocus=this.selectedYear,this.dayInFocus=this.selectedDay,this.monthNumInFocus=this.selectedMonth-1}updateLiveRegion(t){this.el.querySelector("#live-region").innerHTML=t}panelPosition(){let t=document.getElementById(this.parentId);const e=t.shadowRoot.querySelector(".label-wrapper").clientHeight;this.openUp=r(t,this.popupEl,e),n(t,336)?(this.popupEl.style.left="0",this.popupEl.style.right="auto"):(this.popupEl.style.right="0",this.popupEl.style.left="auto")}changeView(t){this.view=t,this.monthNumInFocus=this.monthInFocus-1}renderMonths(t,e){return i("div",{id:`month-${e}-${this.parentId}`,class:"month "+(this.selectedMonth-1===e?"selected":""),role:"gridcell",tabindex:e+1===this.monthInFocus?0:-1,onKeyDown:t=>this.trapFocusEnd(t),onBlur:t=>t.stopPropagation(),onClick:()=>{this.monthInFocus=e+1,this.changeView("day")}},t)}render(){const t=this.getCalendarDates(this.monthInFocus,this.yearInFocus);return i("div",{class:"container",id:"wm-container"},i("button",{disabled:this.disabled,onClick:this.togglePopup.bind(this),"aria-describedby":`date-input-${this.parentId}`,ref:t=>this.buttonEl=t,"aria-expanded":`${this.isExpanded}`,class:"toggle",id:`toggle-${this.parentId}`},i("span",{class:"calendar",title:a.formatMessage({id:"date.calendarView",defaultMessage:"Calendar View",description:"Calendar button"})})),i("div",{class:`popup ${this.view}-view ${this.openUp?"expand-upwards":""} ${this.isTabbing?"user-is-tabbing":""}`,id:`popup-${this.parentId}`,ref:t=>this.popupEl=t,onClick:()=>this.popupClicked=!0,role:"application","aria-describedby":"application"},"day"===this.view?i("div",{class:"day-view"},i("div",{class:"calendar-header"},i("button",{onClick:()=>{this.prevClicked=!0,this.popupClicked=!0,this.backOneMonth()},onKeyDown:t=>this.trapFocusLeft(t),ref:t=>this.prevButton=t,class:"arw-btn","aria-label":a.formatMessage({id:"date.selectPreviousMonth",defaultMessage:"Select previous month",description:"Calendar button"})},i("span",{class:"mdi"},"")),i("div",{id:`popup-title-month-${this.parentId}`,class:"title-box",tabindex:0,role:"button",onKeyDown:t=>{"Enter"!==t.key&&" "!==t.key||(t.preventDefault(),this.changeView("month"))},onClick:this.changeView.bind(this,"month"),"aria-label":`${a.formatMessage({id:"date.currentMonth",defaultMessage:"current month",description:"Calendar button"})}: ${this.calendar_months[this.monthInFocus-1]}\n ${this.yearInFocus}.`,"aria-describedby":"month-title"},i("span",{class:"title","aria-hidden":"true"},this.calendar_months[this.monthInFocus-1]," ",this.yearInFocus)),i("button",{onClick:()=>{this.nextClicked=!0,this.popupClicked=!0,this.forwardOneMonth()},onKeyDown:t=>this.trapFocusRight(t),"aria-label":a.formatMessage({id:"date.selectNextMonth",defaultMessage:"Select next month",description:"Calendar button"}),ref:t=>this.nextButton=t,class:"arw-btn"},i("span",{class:"mdi"},""))),i("div",{"aria-labelledby":`popup-title-month-${this.parentId}`,role:"grid",class:"date-grid"},i("div",{role:"rowgroup",class:"date-header"},i("div",{role:"row",class:"header-row"},i("div",{role:"columnheader",class:"header-cell"},i("span",null,a.formatMessage({id:"date.su",defaultMessage:"Su",description:"Abbreviated day of the week"}))),i("div",{role:"columnheader",class:"header-cell"},i("span",null,a.formatMessage({id:"date.mo",defaultMessage:"Mo",description:"Abbreviated day of the week"}))),i("div",{role:"columnheader",class:"header-cell"},i("span",null,a.formatMessage({id:"date.tu",defaultMessage:"Tu",description:"Abbreviated day of the week"}))),i("div",{role:"columnheader",class:"header-cell"},i("span",null,a.formatMessage({id:"date.we",defaultMessage:"We",description:"Abbreviated day of the week"}))),i("div",{role:"columnheader",class:"header-cell"},i("span",null,a.formatMessage({id:"date.th",defaultMessage:"Th",description:"Abbreviated day of the week"}))),i("div",{role:"columnheader",class:"header-cell"},i("span",null,a.formatMessage({id:"date.fr",defaultMessage:"Fr",description:"Abbreviated day of the week"}))),i("div",{role:"columnheader",class:"header-cell"},i("span",null,a.formatMessage({id:"date.sa",defaultMessage:"Sa",description:"Abbreviated day of the week"}))))),i("div",{role:"rowgroup"},i("div",{role:"row",class:"date-row"},t.slice(0,7).map(((t,e)=>this.renderCalendarDate(t,e)))),i("div",{role:"row"},t.slice(7,14).map(((t,e)=>this.renderCalendarDate(t,e)))),i("div",{role:"row"},t.slice(14,21).map(((t,e)=>this.renderCalendarDate(t,e)))),i("div",{role:"row"},t.slice(21,28).map(((t,e)=>this.renderCalendarDate(t,e)))),i("div",{role:"row"},t.slice(28,35).map(((t,e)=>this.renderCalendarDate(t,e)))),t.length>35?i("div",{role:"row"},t.slice(35).map(((t,e)=>this.renderCalendarDate(t,e)))):""))):i("div",{class:"month-view"},i("div",{class:"calendar-header"},i("button",{onClick:()=>{this.prevClicked=!0,this.popupClicked=!0,this.yearInFocus-=1,this.updateLiveRegion(`${this.yearInFocus} selected.`)},onKeyDown:t=>this.trapFocusLeft(t),"aria-label":a.formatMessage({id:"date.selectPreviousYear",defaultMessage:"Select previous year",description:"Calendar button"}),ref:t=>this.prevButton=t,class:"arw-btn"},i("span",{class:"mdi"},"")),i("div",{id:`popup-title-year-${this.parentId}`,tabindex:0,class:"title-box year",role:"button",onClick:this.changeView.bind(this,"day"),onKeyDown:t=>{"Enter"!==t.key&&" "!==t.key||(t.preventDefault(),this.changeView("day"))},"aria-labelledby":"year-title"},i("span",{class:"title"},this.yearInFocus)),i("button",{onClick:()=>{this.nextClicked=!0,this.popupClicked=!0,this.yearInFocus+=1,this.updateLiveRegion(`${this.yearInFocus} selected.`)},"aria-label":a.formatMessage({id:"date.selectNextYear",defaultMessage:"Select next year",description:"Calendar button"}),onKeyDown:t=>this.trapFocusRight(t),ref:t=>this.nextButton=t,class:"arw-btn"},i("span",{class:"mdi"},""))),i("div",{"aria-labelledby":`popup-title-year-${this.parentId}`,role:"grid",class:"months"},i("div",{role:"row",class:"month-row"},this.calendar_months.slice(0,3).map(((t,e)=>this.renderMonths(t,e)))),i("div",{role:"row",class:"month-row"},this.calendar_months.slice(3,6).map(((t,e)=>this.renderMonths(t,e+3)))),i("div",{role:"row",class:"month-row"},this.calendar_months.slice(6,9).map(((t,e)=>this.renderMonths(t,e+6)))),i("div",{role:"row",class:"month-row"},this.calendar_months.slice(9).map(((t,e)=>this.renderMonths(t,e+9))))))),this.isExpanded&&i("div",{id:"live-region","aria-live":"polite","aria-relevant":"text",class:"sr-only"}),i("div",{id:"month-title",class:"sr-only"},a.formatMessage({id:"date.selectMonth",defaultMessage:"Activate to select a month.",description:"Calendar button"})),i("div",{id:"year-title",class:"sr-only"},a.formatMessage({id:"date.selectYear",defaultMessage:"Activate to select a year.",description:"Calendar button"})),i("div",{id:"application",class:"sr-only"},a.formatMessage({id:"date.instructions",defaultMessage:"Use arrows to select a date in the table. Tab left or right to buttons for selecting previous month, next month, or the month selection table."})))}get el(){return o(this)}};h.style='.toggle{all:unset;cursor:pointer;padding:0 0.375rem;height:2.375rem;border:none;-moz-border-top-right-radius:3px;-webkit-border-top-right-radius:3px;border-top-right-radius:3px;-moz-border-bottom-right-radius:3px;-webkit-border-bottom-right-radius:3px;border-bottom-right-radius:3px;-moz-border-top-left-radius:0;-webkit-border-top-left-radius:0;border-top-left-radius:0;-moz-border-bottom-left-radius:0;-webkit-border-bottom-left-radius:0;border-bottom-left-radius:0;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;background-color:#fff}.toggle:disabled{pointer-events:none;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;background-color:rgba(74, 74, 74, 0.05)}.toggle:disabled .calendar::after{color:#7b7b7b}.toggle:hover{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;background:#e6e6e6}.toggle:hover .calendar::after{color:#575195}[dir=RTL] .toggle{right:auto;left:0}.toggle span::after{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f0ed";font-size:1.5rem;color:#575195;padding:0;line-height:2.5rem}.toggle:focus{outline:none}.toggle::-moz-focus-inner{border:0}.user-is-tabbing .toggle:focus{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}.user-is-tabbing .toggle:focus::-moz-focus-inner{border:0}.popup{visibility:hidden;font-family:inherit;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;-webkit-box-shadow:0px 4px 15px 0px rgba(0, 0, 0, 0.2);-moz-box-shadow:0px 4px 15px 0px rgba(0, 0, 0, 0.2);box-shadow:0px 4px 15px 0px rgba(0, 0, 0, 0.2);width:21rem;z-index:10;position:absolute;left:0;top:40px;min-height:21.0625rem;-webkit-transition:-webkit-transform 0.25s ease;transition:-webkit-transform 0.25s ease;transition:transform 0.25s ease;transition:transform 0.25s ease, -webkit-transform 0.25s ease;-webkit-transform-origin:center top;transform-origin:center top;-webkit-transform:scale(1, 0);transform:scale(1, 0);background-color:#fff}.popup.open{-webkit-transform:scale(1, 1);transform:scale(1, 1)}.popup.expand-upwards{top:auto;bottom:2.375rem;-webkit-transform-origin:center bottom;transform-origin:center bottom}.popup .calendar-header{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;-webkit-justify-content:space-between;justify-content:space-between;position:relative;padding:0.9375rem 0.25rem}.popup .calendar-header .title-box{height:2.625rem;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;border:1px solid;font-weight:500;font-size:0.875rem;background:transparent;cursor:pointer;display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-align:center;align-items:center;padding:0 0.375rem 0 0.75rem;border-color:#575195;color:#575195}.popup .calendar-header .title-box:after{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f140";padding-left:0.75rem}.popup .calendar-header .title-box.year:after{content:"\\f143"}.popup .calendar-header .title-box::-moz-focus-inner{border:0}.popup .calendar-header .title-box:focus{outline:none}.popup .calendar-header .arw-btn{cursor:pointer;-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;border-radius:50%;width:2.75rem;height:2.75rem;border:none;color:#575195;background:transparent;padding:0;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;line-height:2.75rem}.popup .calendar-header .arw-btn .mdi{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-size:1.5rem;font-weight:normal;line-height:2.75rem}.popup .calendar-header .arw-btn .mdi:hover{background-color:#efeef1}.popup .calendar-header .arw-btn:focus{outline:none}.popup .calendar-header .arw-btn:active{-ms-transform:scale(0.9, 0.9);-webkit-transform:scale(0.9, 0.9);-moz-transform:scale(0.9, 0.9);transform:scale(0.9, 0.9);background-color:#d7d6d9}.popup .day-view{min-width:100%}.popup .day-view .date-grid{width:100%;text-align:center;border-collapse:collapse;margin-bottom:0.4375rem;color:#757575}.popup .day-view .date-grid .date-row:first-child .date-cell{margin-top:0.125rem}.popup .day-view .date-grid .date-header{background-color:#eeedf4}.popup .day-view .date-grid .header-cell{height:2.0625rem;line-height:2.0625rem;width:2.75rem;margin:0 calc((14.28% - 44px) / 2);padding:0;display:inline-block;font-size:0.8125rem;font-weight:bold;color:#4a4a4a;border:none}.popup .day-view .date-grid .date-cell{cursor:pointer;display:inline-block;padding:0;-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;border-radius:50%;height:2.75rem;width:2.75rem;margin:0 calc((14.28% - 44px) / 2);font-size:0.875rem;font-weight:500;line-height:2.75rem}.popup .day-view .date-grid .date-cell:focus{outline:none}.popup .day-view .date-grid .date-cell:hover{background-color:#efeef1}.popup .day-view .date-grid .date-cell:active{background-color:#575195;color:#ffffff}.popup .day-view .date-grid .date-cell.current-month{color:#4a4a4a}.popup .day-view .date-grid .date-cell.current-month[aria-selected=true]{background-color:#575195;color:#ffffff}.popup .month-view .months{border-top:2px solid;border-top-color:#eeedf4;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap}.popup .month-view .month-row{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;-webkit-justify-content:space-between;justify-content:space-between;width:100%;border-bottom:2px solid;border-bottom-color:#eeedf4}.popup .month-view .month{cursor:pointer;text-align:center;width:100%;height:4rem;line-height:4rem;font-weight:500;color:#575195}.popup .month-view .month:not(:last-child){border-right:2px solid;border-right-color:#eeedf4}.popup .month-view .month:focus{outline:none}.popup .month-view .month:hover{background-color:#efeef1}.popup .month-view .month:active,.popup .month-view .month.selected{background-color:#575195;color:#ffffff}.popup.user-is-tabbing button:focus,.popup.user-is-tabbing .title-box:focus,.popup.user-is-tabbing .date-cell:focus,.popup.user-is-tabbing .month:focus{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;border:none;z-index:11}.popup.user-is-tabbing button:focus::-moz-focus-inner,.popup.user-is-tabbing .title-box:focus::-moz-focus-inner,.popup.user-is-tabbing .date-cell:focus::-moz-focus-inner,.popup.user-is-tabbing .month:focus::-moz-focus-inner{border:0}.sr-only{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}';export{h as priv_datepicker}
1
+ import{r as t,c as e,h as i,f as s,g as o}from"./p-b3c71506.js";import{i as a,l as r,u as n}from"./p-de3367ee.js";let h=class{constructor(s){t(this,s),this.cellTriggered=e(this,"cellTriggered",7),this.toggleButtonClicked=e(this,"toggleButtonClicked",7),this.popupClosed=e(this,"popupClosed",7),this.popupBlurred=e(this,"popupBlurred",7),this.disabled=!1,this.isExpanded=!1,this.view="day",this.date=new Date,this.selectedYear=this.date.getUTCFullYear(),this.selectedMonth=this.date.getUTCMonth()+1,this.selectedDay=this.date.getUTCDate(),this.monthInFocus=this.selectedMonth,this.yearInFocus=this.selectedYear,this.dayInFocus=this.selectedDay,this.monthNumInFocus=this.selectedMonth,this.parentId="",this.isTabbing=!1,this.popupClicked=!0,this.buttonClicked=!0,this.prevClicked=!0,this.nextClicked=!0,this.openUp=!1,this.calendar_months=[a.formatMessage({id:"date.january",defaultMessage:"January",description:"Month of the year"}),a.formatMessage({id:"date.february",defaultMessage:"February",description:"Month of the year"}),a.formatMessage({id:"date.march",defaultMessage:"March",description:"Month of the year"}),a.formatMessage({id:"date.april",defaultMessage:"April",description:"Month of the year"}),a.formatMessage({id:"date.may",defaultMessage:"May",description:"Month of the year"}),a.formatMessage({id:"date.june",defaultMessage:"June",description:"Month of the year"}),a.formatMessage({id:"date.july",defaultMessage:"July",description:"Month of the year"}),a.formatMessage({id:"date.august",defaultMessage:"August",description:"Month of the year"}),a.formatMessage({id:"date.september",defaultMessage:"September",description:"Month of the year"}),a.formatMessage({id:"date.october",defaultMessage:"October",description:"Month of the year"}),a.formatMessage({id:"date.november",defaultMessage:"November",description:"Month of the year"}),a.formatMessage({id:"date.december",defaultMessage:"December",description:"Month of the year"})],this.weekdays=[a.formatMessage({id:"date.sunday",defaultMessage:"Sunday"}),a.formatMessage({id:"date.monday",defaultMessage:"Monday"}),a.formatMessage({id:"date.tuesday",defaultMessage:"Tuesday"}),a.formatMessage({id:"date.wednesday",defaultMessage:"Wednesday"}),a.formatMessage({id:"date.thursday",defaultMessage:"Thursday"}),a.formatMessage({id:"date.friday",defaultMessage:"Friday"}),a.formatMessage({id:"date.saturday",defaultMessage:"Saturday"})],this.renderCalendarDate=(t,e)=>{let s=this.removeZeroes(String(t[1])),o=this.removeZeroes(String(t[2])),r=s===this.monthInFocus?"current-month":"";const n=t[0]+t[1]+t[2],h=this.isDateToday(t);return i("div",{role:"gridcell",id:`cell-${n}-${this.parentId}`,class:`date-cell ${r}`,"aria-selected":!1,"aria-label":`${h?`${a.formatMessage({id:"date.today",defaultMessage:"today",description:"calendar button"})}, `:""}${this.weekdays[e]}, ${this.calendar_months[s-1]} ${o}, ${t[0]}`,onClick:t=>{this.handleTriggeredDate(t.target)},onKeyDown:t=>this.trapFocusEnd(t),"data-month":t[1],"data-year":t[0],onBlur:t=>t.stopPropagation()},o)}}handleKey(t){switch(this.prevClicked=!1,this.nextClicked=!1,t.key){case"Enter":t.preventDefault(),!t.target.id.includes("popup-title")&&t.target.click();break;case"Escape":t.preventDefault(),this.isExpanded&&(t.stopPropagation(),this.closePopup(!0));break;case"PageUp":t.preventDefault(),this.backOneMonth();break;case"PageDown":t.preventDefault(),this.forwardOneMonth();break;case"Home":t.preventDefault(),this.unfocusCell(),this.dayInFocus=1,s(this.el);break;case"End":t.preventDefault(),this.unfocusCell(),this.dayInFocus=this.getMonthDays(this.monthInFocus,this.yearInFocus),s(this.el);break;case"ArrowLeft":if(t.preventDefault(),"day"===this.view)if(this.unfocusCell(),1===this.dayInFocus){const t=this.getPreviousMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=t.month,this.yearInFocus=t.year,this.dayInFocus=this.getMonthDays(this.monthInFocus,this.yearInFocus)}else this.dayInFocus-=1;else this.unfocusMonth(),0===this.monthNumInFocus?this.monthNumInFocus=11:this.monthNumInFocus-=1;break;case"ArrowRight":if(t.preventDefault(),"day"===this.view)if(this.unfocusCell(),this.dayInFocus===this.getMonthDays(this.monthInFocus,this.yearInFocus)){const t=this.getNextMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=t.month,this.yearInFocus=t.year,this.dayInFocus=1}else this.dayInFocus+=1;else this.unfocusMonth(),11===this.monthNumInFocus?this.monthNumInFocus=0:this.monthNumInFocus+=1;break;case"ArrowUp":if(t.preventDefault(),"day"===this.view)if(this.unfocusCell(),this.dayInFocus<8){const t=this.getPreviousMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=t.month,this.yearInFocus=t.year;const e=7-this.dayInFocus;this.dayInFocus=this.getMonthDays(this.monthInFocus,this.yearInFocus)-e}else this.dayInFocus-=7;else this.unfocusMonth(),this.monthNumInFocus<3?this.monthNumInFocus+=9:this.monthNumInFocus-=3;break;case"ArrowDown":if(t.preventDefault(),this.isExpanded)if("day"===this.view){if(!(document.activeElement.shadowRoot||document).activeElement.classList.contains("date-cell")){this.focusCell();break}this.unfocusCell();const t=this.getMonthDays(this.monthInFocus,this.yearInFocus)-7;if(this.dayInFocus>t){const e=this.getNextMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=e.month,this.yearInFocus=e.year,this.dayInFocus=this.dayInFocus-t}else this.dayInFocus+=7}else{const t=(document.activeElement.shadowRoot||document).activeElement;if("BUTTON"===t.tagName||t.id.includes("popup-title-year")){this.focusMonth();break}this.unfocusMonth(),this.monthNumInFocus>8?this.monthNumInFocus-=9:this.monthNumInFocus+=3}else this.openPopup()}}toggleTabbingOn(t){["Tab","ArrowUp","ArrowDown","ArrowLeft","ArrowRight","Enter"].includes(t.key)&&(this.isTabbing=!0)}toggleTabbingOff(){this.isTabbing=!1}blurHandler(t){this.popupClicked||this.buttonClicked||!this.isExpanded||(this.closePopup(),this.popupBlurred.emit({relatedTarget:t.target})),this.popupClicked=!1,this.buttonClicked=!1}handleBlurOnWindow(t){this.isExpanded&&(this.closePopup(),this.popupBlurred.emit({relatedTarget:t.target}))}componentDidUpdate(){this.handleSelectedDate(),this.isExpanded&&(this.prevClicked?this.prevButton.focus():this.nextClicked?this.nextButton.focus():"day"===this.view?this.focusCell():this.focusMonth())}componentDidLoad(){this.handleSelectedDate(),this.setDateValuesForView()}zeroPad(t,e){return String.prototype.padStart||(String.prototype.padStart=function(t,e){return(t-=this.length)>e.length&&(e+=e.repeat(t/e.length)),e.slice(0,t)+String(this)}),`${t.toString()}`.padStart(e,"0")}removeZeroes(t){return+t<10?+t.slice(1):+t}isDateToday(t){const e=new Date;return[e.getFullYear().toString(),(e.getMonth()+1).toString(),e.getDate().toString()].reduce(((e,i,s)=>e&&this.removeZeroes(t[s]).toString()===i),!0)}togglePopup(){this.isExpanded?this.closePopup():this.openPopup(),this.buttonClicked=!0}closePopup(t=!1){this.isExpanded=!1,this.popupEl.classList.remove("open"),window.setTimeout((()=>{this.popupEl.style.visibility="hidden"}),250),"day"===this.view&&this.unfocusCell(),this.monthInFocus=this.selectedMonth,this.yearInFocus=this.selectedYear,this.dayInFocus=this.selectedDay,this.changeView("day"),t&&this.buttonEl.focus()}openPopup(){this.panelPosition(),this.setDateValuesForView(),this.prevClicked=!1,this.nextClicked=!1,this.popupEl.style.visibility="visible",window.requestAnimationFrame((()=>{this.popupEl.classList.add("open")})),this.isExpanded=!0,this.focusCell()}getMonthDays(t,e){return 2===t?e%4==0?29:28:[4,6,9,11].includes(t)?30:31}getMonthFirstDay(t,e){return+new Date(e,t-1,1,12,0,0).getDay()+1}getPreviousMonth(t,e){return{month:t>1?t-1:12,year:t>1?e:e-1}}getNextMonth(t,e){return{month:t<12?t+1:1,year:t<12?e:e+1}}getCalendarDates(t,e){const i=this.getMonthDays(t,e),s=this.getMonthFirstDay(t,e)-1;let o=42-(s+i);o=o>6?o-7:o;const{month:a,year:r}=this.getPreviousMonth(t,e),{month:n,year:h}=this.getNextMonth(t,e),d=this.getMonthDays(a,r);return[...[...new Array(s).fill("1")].map(((t,e)=>{const i=e+1+(d-s);return[r.toString(),this.zeroPad(a,2),this.zeroPad(i,2)]})),...[...new Array(i).fill("1")].map(((i,s)=>{const o=s+1;return[e.toString(),this.zeroPad(t,2),this.zeroPad(o,2)]})),...[...new Array(o).fill("1")].map(((t,e)=>{const i=e+1;return[h.toString(),this.zeroPad(n,2),this.zeroPad(i,2)]}))]}forwardOneMonth(){this.unfocusCell();const t=this.getNextMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=t.month,this.yearInFocus=t.year;const e=this.getMonthDays(this.monthInFocus,this.yearInFocus);this.dayInFocus>this.getMonthDays(this.monthInFocus,this.yearInFocus)&&(this.dayInFocus=e),this.updateLiveRegion(`Displaying ${this.calendar_months[this.monthInFocus-1]}, ${this.yearInFocus}`)}backOneMonth(){this.unfocusCell();const t=this.getPreviousMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=t.month,this.yearInFocus=t.year;const e=this.getMonthDays(this.monthInFocus,this.yearInFocus);this.dayInFocus>this.getMonthDays(this.monthInFocus,this.yearInFocus)&&(this.dayInFocus=e),this.updateLiveRegion(`Viewing ${this.calendar_months[this.monthInFocus-1]}, ${this.yearInFocus}`)}handleTriggeredDate(t){this.cellTriggered.emit(t),this.closePopup(!0)}handleSelectedDate(){this.selectedDate&&this.selectedDate.removeAttribute("aria-selected"),this.selectedDate=this.getCellById(this.selectedYear,this.selectedMonth,this.selectedDay),this.selectedDate&&this.selectedDate.setAttribute("aria-selected","true")}getCellById(t,e,i){const s=t+this.zeroPad(e,2)+this.zeroPad(i,2);return this.el.querySelector(`#cell-${s}-${this.parentId}`)}unfocusCell(){this.getCellById(this.yearInFocus,this.monthInFocus,this.dayInFocus).tabIndex=-1}focusCell(){const t=this.getMonthDays(this.monthInFocus,this.yearInFocus);this.dayInFocus=this.dayInFocus>t?t:this.dayInFocus;const e=this.getCellById(this.yearInFocus,this.monthInFocus,this.dayInFocus);e&&(e.tabIndex=0,e.focus())}unfocusMonth(){this.el.querySelector(`#month-${this.monthNumInFocus}-${this.parentId}`).tabIndex=-1}focusMonth(){const t=this.el.querySelector(`#month-${this.monthNumInFocus}-${this.parentId}`);t.tabIndex=0,t.focus()}trapFocusLeft(t){t.shiftKey&&"Tab"===t.key&&(t.preventDefault(),this.focusCellInView())}trapFocusEnd(t){t.shiftKey||"Tab"!==t.key||(t.preventDefault(),this.prevButton.focus())}trapFocusRight(t){t.shiftKey||"Tab"!==t.key||(t.preventDefault(),this.focusCellInView())}focusCellInView(){"day"===this.view?this.focusCell():this.focusMonth()}toggleBusyAttribute(t){this.el.querySelector("#wm-container").setAttribute("aria-busy",t)}setDateValuesForView(){this.selectedYear=this.date.getUTCFullYear(),this.selectedMonth=this.date.getUTCMonth()+1,this.selectedDay=this.date.getUTCDate(),this.monthInFocus=this.selectedMonth,this.yearInFocus=this.selectedYear,this.dayInFocus=this.selectedDay,this.monthNumInFocus=this.selectedMonth-1}updateLiveRegion(t){this.el.querySelector("#live-region").innerHTML=t}panelPosition(){let t=document.getElementById(this.parentId);const e=t.shadowRoot.querySelector(".label-wrapper").clientHeight;this.openUp=r(t,this.popupEl,e),n(t,336)?(this.popupEl.style.left="0",this.popupEl.style.right="auto"):(this.popupEl.style.right="0",this.popupEl.style.left="auto")}changeView(t){this.view=t,this.monthNumInFocus=this.monthInFocus-1}renderMonths(t,e){return i("div",{id:`month-${e}-${this.parentId}`,class:"month "+(this.selectedMonth-1===e?"selected":""),role:"gridcell",tabindex:e+1===this.monthInFocus?0:-1,onKeyDown:t=>this.trapFocusEnd(t),onBlur:t=>t.stopPropagation(),onClick:()=>{this.monthInFocus=e+1,this.changeView("day")}},t)}render(){const t=this.getCalendarDates(this.monthInFocus,this.yearInFocus);return i("div",{class:"container",id:"wm-container"},i("button",{disabled:this.disabled,onClick:this.togglePopup.bind(this),"aria-describedby":`date-input-${this.parentId}`,ref:t=>this.buttonEl=t,"aria-expanded":`${this.isExpanded}`,class:"toggle",id:`toggle-${this.parentId}`},i("span",{class:"calendar",title:a.formatMessage({id:"date.calendarView",defaultMessage:"Calendar View",description:"Calendar button"})})),i("div",{class:`popup ${this.view}-view ${this.openUp?"expand-upwards":""} ${this.isTabbing?"user-is-tabbing":""}`,id:`popup-${this.parentId}`,ref:t=>this.popupEl=t,onClick:()=>this.popupClicked=!0,role:"application","aria-describedby":"application"},"day"===this.view?i("div",{class:"day-view"},i("div",{class:"calendar-header"},i("button",{onClick:()=>{this.prevClicked=!0,this.popupClicked=!0,this.backOneMonth()},onKeyDown:t=>this.trapFocusLeft(t),ref:t=>this.prevButton=t,class:"arw-btn","aria-label":a.formatMessage({id:"date.selectPreviousMonth",defaultMessage:"Select previous month",description:"Calendar button"})},i("span",{class:"mdi"},"")),i("div",{id:`popup-title-month-${this.parentId}`,class:"title-box",tabindex:0,role:"button",onKeyDown:t=>{"Enter"!==t.key&&" "!==t.key||(t.preventDefault(),this.changeView("month"))},onClick:this.changeView.bind(this,"month"),"aria-label":`${a.formatMessage({id:"date.currentMonth",defaultMessage:"current month",description:"Calendar button"})}: ${this.calendar_months[this.monthInFocus-1]}\n ${this.yearInFocus}.`,"aria-describedby":"month-title"},i("span",{class:"title","aria-hidden":"true"},this.calendar_months[this.monthInFocus-1]," ",this.yearInFocus)),i("button",{onClick:()=>{this.nextClicked=!0,this.popupClicked=!0,this.forwardOneMonth()},onKeyDown:t=>this.trapFocusRight(t),"aria-label":a.formatMessage({id:"date.selectNextMonth",defaultMessage:"Select next month",description:"Calendar button"}),ref:t=>this.nextButton=t,class:"arw-btn"},i("span",{class:"mdi"},""))),i("div",{"aria-labelledby":`popup-title-month-${this.parentId}`,role:"grid",class:"date-grid"},i("div",{role:"rowgroup",class:"date-header"},i("div",{role:"row",class:"header-row"},i("div",{role:"columnheader",class:"header-cell"},i("span",null,a.formatMessage({id:"date.su",defaultMessage:"Su",description:"Abbreviated day of the week"}))),i("div",{role:"columnheader",class:"header-cell"},i("span",null,a.formatMessage({id:"date.mo",defaultMessage:"Mo",description:"Abbreviated day of the week"}))),i("div",{role:"columnheader",class:"header-cell"},i("span",null,a.formatMessage({id:"date.tu",defaultMessage:"Tu",description:"Abbreviated day of the week"}))),i("div",{role:"columnheader",class:"header-cell"},i("span",null,a.formatMessage({id:"date.we",defaultMessage:"We",description:"Abbreviated day of the week"}))),i("div",{role:"columnheader",class:"header-cell"},i("span",null,a.formatMessage({id:"date.th",defaultMessage:"Th",description:"Abbreviated day of the week"}))),i("div",{role:"columnheader",class:"header-cell"},i("span",null,a.formatMessage({id:"date.fr",defaultMessage:"Fr",description:"Abbreviated day of the week"}))),i("div",{role:"columnheader",class:"header-cell"},i("span",null,a.formatMessage({id:"date.sa",defaultMessage:"Sa",description:"Abbreviated day of the week"}))))),i("div",{role:"rowgroup"},i("div",{role:"row",class:"date-row"},t.slice(0,7).map(((t,e)=>this.renderCalendarDate(t,e)))),i("div",{role:"row"},t.slice(7,14).map(((t,e)=>this.renderCalendarDate(t,e)))),i("div",{role:"row"},t.slice(14,21).map(((t,e)=>this.renderCalendarDate(t,e)))),i("div",{role:"row"},t.slice(21,28).map(((t,e)=>this.renderCalendarDate(t,e)))),i("div",{role:"row"},t.slice(28,35).map(((t,e)=>this.renderCalendarDate(t,e)))),t.length>35?i("div",{role:"row"},t.slice(35).map(((t,e)=>this.renderCalendarDate(t,e)))):""))):i("div",{class:"month-view"},i("div",{class:"calendar-header"},i("button",{onClick:()=>{this.prevClicked=!0,this.popupClicked=!0,this.yearInFocus-=1,this.updateLiveRegion(`${this.yearInFocus} selected.`)},onKeyDown:t=>this.trapFocusLeft(t),"aria-label":a.formatMessage({id:"date.selectPreviousYear",defaultMessage:"Select previous year",description:"Calendar button"}),ref:t=>this.prevButton=t,class:"arw-btn"},i("span",{class:"mdi"},"")),i("div",{id:`popup-title-year-${this.parentId}`,tabindex:0,class:"title-box year",role:"button",onClick:this.changeView.bind(this,"day"),onKeyDown:t=>{"Enter"!==t.key&&" "!==t.key||(t.preventDefault(),this.changeView("day"))},"aria-labelledby":"year-title"},i("span",{class:"title"},this.yearInFocus)),i("button",{onClick:()=>{this.nextClicked=!0,this.popupClicked=!0,this.yearInFocus+=1,this.updateLiveRegion(`${this.yearInFocus} selected.`)},"aria-label":a.formatMessage({id:"date.selectNextYear",defaultMessage:"Select next year",description:"Calendar button"}),onKeyDown:t=>this.trapFocusRight(t),ref:t=>this.nextButton=t,class:"arw-btn"},i("span",{class:"mdi"},""))),i("div",{"aria-labelledby":`popup-title-year-${this.parentId}`,role:"grid",class:"months"},i("div",{role:"row",class:"month-row"},this.calendar_months.slice(0,3).map(((t,e)=>this.renderMonths(t,e)))),i("div",{role:"row",class:"month-row"},this.calendar_months.slice(3,6).map(((t,e)=>this.renderMonths(t,e+3)))),i("div",{role:"row",class:"month-row"},this.calendar_months.slice(6,9).map(((t,e)=>this.renderMonths(t,e+6)))),i("div",{role:"row",class:"month-row"},this.calendar_months.slice(9).map(((t,e)=>this.renderMonths(t,e+9))))))),this.isExpanded&&i("div",{id:"live-region","aria-live":"polite","aria-relevant":"text",class:"sr-only"}),i("div",{id:"month-title",class:"sr-only"},a.formatMessage({id:"date.selectMonth",defaultMessage:"Activate to select a month.",description:"Calendar button"})),i("div",{id:"year-title",class:"sr-only"},a.formatMessage({id:"date.selectYear",defaultMessage:"Activate to select a year.",description:"Calendar button"})),i("div",{id:"application",class:"sr-only"},a.formatMessage({id:"date.instructions",defaultMessage:"Use arrows to select a date in the table. Tab left or right to buttons for selecting previous month, next month, or the month selection table."})))}get el(){return o(this)}};h.style='.toggle{all:unset;cursor:pointer;padding:0 0.375rem;height:2.375rem;border:none;-moz-border-top-right-radius:3px;-webkit-border-top-right-radius:3px;border-top-right-radius:3px;-moz-border-bottom-right-radius:3px;-webkit-border-bottom-right-radius:3px;border-bottom-right-radius:3px;-moz-border-top-left-radius:0;-webkit-border-top-left-radius:0;border-top-left-radius:0;-moz-border-bottom-left-radius:0;-webkit-border-bottom-left-radius:0;border-bottom-left-radius:0;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;background-color:#fff}.toggle:disabled{pointer-events:none;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;background-color:rgba(74, 74, 74, 0.05)}.toggle:disabled .calendar::after{color:#7b7b7b}.toggle:hover{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;background:#e6e6e6}.toggle:hover .calendar::after{color:#575195}[dir=RTL] .toggle{right:auto;left:0}.toggle span::after{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f0ed";font-size:1.5rem;color:#575195;padding:0;line-height:2.5rem}.toggle:focus{outline:none}.toggle::-moz-focus-inner{border:0}.user-is-tabbing .toggle:focus{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}.user-is-tabbing .toggle:focus::-moz-focus-inner{border:0}.popup{visibility:hidden;font-family:inherit;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;-webkit-box-shadow:0px 4px 15px 0px rgba(0, 0, 0, 0.2);-moz-box-shadow:0px 4px 15px 0px rgba(0, 0, 0, 0.2);box-shadow:0px 4px 15px 0px rgba(0, 0, 0, 0.2);width:21rem;z-index:10;position:absolute;left:0;top:40px;min-height:21.0625rem;-webkit-transition:-webkit-transform 0.25s ease;transition:-webkit-transform 0.25s ease;transition:transform 0.25s ease;transition:transform 0.25s ease, -webkit-transform 0.25s ease;-webkit-transform-origin:center top;transform-origin:center top;-webkit-transform:scale(1, 0);transform:scale(1, 0);background-color:#fff}.popup.open{-webkit-transform:scale(1, 1);transform:scale(1, 1)}.popup.expand-upwards{top:auto;bottom:2.375rem;-webkit-transform-origin:center bottom;transform-origin:center bottom}.popup .calendar-header{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;-webkit-justify-content:space-between;justify-content:space-between;position:relative;padding:0.9375rem 0.25rem}.popup .calendar-header .title-box{height:2.625rem;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;border:1px solid;font-weight:500;font-size:0.875rem;background:transparent;cursor:pointer;display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-align:center;align-items:center;padding:0 0.375rem 0 0.75rem;border-color:#575195;color:#575195}.popup .calendar-header .title-box:after{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f140";padding-left:0.75rem}.popup .calendar-header .title-box.year:after{content:"\\f143"}.popup .calendar-header .title-box::-moz-focus-inner{border:0}.popup .calendar-header .title-box:focus{outline:none}.popup .calendar-header .arw-btn{cursor:pointer;-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;border-radius:50%;width:2.75rem;height:2.75rem;border:none;color:#575195;background:transparent;padding:0;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;line-height:2.75rem}.popup .calendar-header .arw-btn .mdi{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-size:1.5rem;font-weight:normal;line-height:2.75rem}.popup .calendar-header .arw-btn .mdi:hover{background-color:#efeef1}.popup .calendar-header .arw-btn:focus{outline:none}.popup .calendar-header .arw-btn:active{-ms-transform:scale(0.9, 0.9);-webkit-transform:scale(0.9, 0.9);-moz-transform:scale(0.9, 0.9);transform:scale(0.9, 0.9);background-color:#d7d6d9}.popup .day-view{min-width:100%}.popup .day-view .date-grid{width:100%;text-align:center;border-collapse:collapse;margin-bottom:0.4375rem;color:#757575}.popup .day-view .date-grid .date-row:first-child .date-cell{margin-top:0.125rem}.popup .day-view .date-grid .date-header{background-color:#eeedf4}.popup .day-view .date-grid .header-cell{height:2.0625rem;line-height:2.0625rem;width:2.75rem;margin:0 calc((14.28% - 44px) / 2);padding:0;display:inline-block;font-size:0.8125rem;font-weight:bold;color:#4a4a4a;border:none}.popup .day-view .date-grid .date-cell{cursor:pointer;display:inline-block;padding:0;-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;border-radius:50%;height:2.75rem;width:2.75rem;margin:0 calc((14.28% - 44px) / 2);font-size:0.875rem;font-weight:500;line-height:2.75rem}.popup .day-view .date-grid .date-cell:focus{outline:none}.popup .day-view .date-grid .date-cell:hover{background-color:#efeef1}.popup .day-view .date-grid .date-cell:active{background-color:#575195;color:#ffffff}.popup .day-view .date-grid .date-cell.current-month{color:#4a4a4a}.popup .day-view .date-grid .date-cell.current-month[aria-selected=true]{background-color:#575195;color:#ffffff}.popup .month-view .months{border-top:2px solid;border-top-color:#eeedf4;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap}.popup .month-view .month-row{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;-webkit-justify-content:space-between;justify-content:space-between;width:100%;border-bottom:2px solid;border-bottom-color:#eeedf4}.popup .month-view .month{cursor:pointer;text-align:center;width:100%;height:4rem;line-height:4rem;font-weight:500;color:#575195}.popup .month-view .month:not(:last-child){border-right:2px solid;border-right-color:#eeedf4}.popup .month-view .month:focus{outline:none}.popup .month-view .month:hover{background-color:#efeef1}.popup .month-view .month:active,.popup .month-view .month.selected{background-color:#575195;color:#ffffff}.popup.user-is-tabbing button:focus,.popup.user-is-tabbing .title-box:focus,.popup.user-is-tabbing .date-cell:focus,.popup.user-is-tabbing .month:focus{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;border:none;z-index:11}.popup.user-is-tabbing button:focus::-moz-focus-inner,.popup.user-is-tabbing .title-box:focus::-moz-focus-inner,.popup.user-is-tabbing .date-cell:focus::-moz-focus-inner,.popup.user-is-tabbing .month:focus::-moz-focus-inner{border:0}.sr-only{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}';export{h as priv_datepicker}
@@ -1 +1 @@
1
- import{r as t,c as i,h as e,H as s,g as a,f as o}from"./p-b3c71506.js";import{d as n,g as r}from"./p-15b1c11b.js";let h=class{constructor(e){t(this,e),this.wmTabSelected=i(this,"wmTabSelected",7),this.tabSelected=i(this,"tabSelected",7),this.keydownOnTabItem=i(this,"keydownOnTabItem",7),this.tabItemLoaded=i(this,"tabItemLoaded",7),this.selected=!1,this.show=!0,this.tabId="",this.tabClicked=t=>{t.preventDefault(),this.wmTabSelected.emit({tabId:this.tabId}),this.tabSelected.emit({tabId:this.tabId})},this.tabPressed=t=>{const i=t.key;"Enter"===i||" "===i?(t.preventDefault(),this.wmTabSelected.emit({tabId:this.tabId}),this.tabSelected.emit({tabId:this.tabId})):i.includes("Arrow")&&(t.preventDefault(),this.keydownOnTabItem.emit({tabItem:this.el,key:t.key}))}}get parentTabList(){return this.el.parentElement}toggleTabbingOn(){this.linkEl&&this.linkEl.classList.add("user-is-tabbing")}toggleTabbingOff(){this.linkEl&&this.linkEl.classList.remove("user-is-tabbing")}componentWillLoad(){this.el.focus=function(){const t=this.shadowRoot.querySelector("a");t&&t.focus()}}componentDidLoad(){this.tabItemLoaded.emit()}render(){let t=this.show?"":"hide ";t+=this.parentTabList&&"dark"==this.parentTabList.customBackground?"dark":"";let i={};const a=this.parentTabList&&this.parentTabList.customPadding;if(a){const t=2*parseInt(a,10)||0,e=a.split(/([0-9]+)/).pop();i={"padding-left":this.parentTabList.customPadding,"padding-right":this.parentTabList.customPadding,"background-size":`calc(100% - ${t}${e}) 3px`}}return e(s,{role:"presentation"},e("li",{class:"tab-item",role:"presentation"},e("a",{class:`tab ${t}`,style:i,role:"tab",ref:t=>this.linkEl=t,onClick:this.tabClicked,id:`tab-link-${this.tabId}`,onKeyDown:t=>this.tabPressed(t),"aria-selected":this.selected?"true":"false",tabindex:this.selected?0:-1},e("slot",null))))}get el(){return a(this)}};h.style=":host{font-family:inherit;display:inline-block}:host *{-webkit-box-sizing:border-box;box-sizing:border-box}:host .tab-item{list-style-type:none;height:100%;display:inline-block}:host .tab-item .tab{-webkit-border-radius:0;-moz-border-radius:0;-ms-border-radius:0;border-radius:0;color:#575195;text-decoration:none;letter-spacing:0.7px;font-size:0.875rem;font-weight:500;opacity:1;position:relative;text-transform:uppercase;display:inline-block;height:3.3333333333em;line-height:3.3333333333em;padding-right:1.5rem;padding-left:1.5rem}:host .tab-item .tab[aria-selected=true]{font-weight:700;opacity:1;background:-webkit-gradient(linear, left top, left bottom, from(currentColor), to(currentColor)) bottom/0 0 no-repeat;background:linear-gradient(currentColor, currentColor) bottom/0 0 no-repeat;background-size:calc(100% - 50px) 3px}:host .tab-item .tab[aria-selected=true].dark{color:#fff}:host .tab-item .tab,:host .tab-item .tab:hover,:host .tab-item .tab:active{outline:none}:host .tab-item .tab:focus{outline:none}:host .tab-item .tab.dark:not([aria-selected=true]){opacity:0.8;color:#fff}:host .tab-item .tab.user-is-tabbing:focus:not(:active){outline:none;-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}:host .tab-item .tab.user-is-tabbing:focus:not(:active)::-moz-focus-inner{border:0}:host.hide{display:none}";let b=class{constructor(e){t(this,e),this.wmTabSelected=i(this,"wmTabSelected",7),this.tabSelected=i(this,"tabSelected",7),this.controllerEnabled=!1,this.getSelectedTabItem=()=>this.tabItems.filter((t=>t.selected))[0],this.debouncedSetLayout=n((()=>{this.listWidth||this.setListWidth(),o(this.el)}),250)}get menuLayout(){return!!this.listWidth&&this.el.offsetWidth<this.listWidth-24}get tabItems(){return Array.from(this.el.querySelectorAll("wm-tab-item"))}getLinkEl(t){return t.shadowRoot.querySelector("a")}get panels(){const t=Array.from(document.querySelectorAll("wm-tab-panel")),i=this.tabItems.map((t=>t.tabId));return t.filter((t=>i.includes(t.tabId)))}getPanel(t){return this.panels.find((i=>i.tabId===t))}setListWidth(){let t=this.tabItems.reduce(((t,i)=>t+i.offsetWidth),0);this.listWidth=t&&t>0?t:this.listWidth}setSelected(t){if(this.tabItems.map((i=>i.selected=i.tabId===t)),1===this.panels.length&&this.tabItems.length>1){const t=this.getSelectedTabItem();this.setAttributesOnPanel(this.panels[0],t),this.panels[0].active=!0}else this.panels.map((i=>i.active=i.tabId===t))}showItems(){this.tabItems.map((t=>t.show=!0))}hideItems(){this.tabItems.map((t=>t.show=!1))}componentWillLoad(){this.el.focus=function(){const t=Array.from(this.querySelectorAll("wm-tab-item")).filter((t=>t.selected))[0];t&&t.focus()}}componentDidLoad(){this.setLayout(),this.setSelected(this.selectedTab||this.tabItems[0].tabId)}tabItemLoaded(t){this.setAriaOnPanelAndTab(t.target)}setAriaOnPanelAndTab(t){const i=this.getPanel(t.tabId);i?(this.setAttributesOnPanel(i,t),this.setAttributesOnTab(t,i)):1===this.panels.length&&this.setAttributesOnTab(t,this.panels[0])}setAttributesOnTab(t,i){const e=this.getLinkEl(t);e&&(e.setAttribute("aria-controls",i.id),e.setAttribute("href",`#${i.id}`))}removeAttributesOnTab(t){const i=this.getLinkEl(t);i&&(i.removeAttribute("aria-controls"),i.removeAttribute("href"))}setAttributesOnPanel(t,i){const e=this.getLinkEl(i);e&&(t.setAttribute("aria-labelledby",e.id),t.setAttribute("tab-id",i.tabId))}handleTabSelected(t){this.controllerEnabled&&this.setSelected(t.detail.tabId)}handleKeydown(t){const i=t.detail.key,e=this.tabItems.indexOf(t.detail.tabItem);"ArrowLeft"!==i&&"ArrowRight"!==i||this.handleLeftRightArrow(e,i),"ArrowDown"!==i&&"ArrowUp"!==i||this.handleUpDownArrow(i)}handleLeftRightArrow(t,i){i&&(t="ArrowLeft"===i?t-1:t+1),t<0?t=this.tabItems.length-1:t===this.tabItems.length&&(t=0),this.getLinkEl(this.tabItems[t]).focus()}handleUpDownArrow(t){if("ArrowDown"===t&&this.selectedTab){const t=this.getPanel(this.selectedTab);t&&t.focus()}}setLayout(){this.debouncedSetLayout()}renderMenuOrTabs(){if(this.menuLayout)return this.hideItems(),e("wm-select",{label:"Tab Selection","label-position":"none"},this.renderOptions());{this.showItems();let t={};return this.customPadding&&(t={"margin-left":"-"+this.customPadding}),e("ul",{class:`tabcontainer ${this.customBackground||""}`,style:t,role:"tablist"},e("slot",null))}}renderOptions(){return this.tabItems.map((t=>e("wm-option",{id:`tab-link-${t.tabId}`,selected:t.tabId===this.selectedTab,onClick:i=>{i.preventDefault(),this.wmTabSelected.emit({tabId:t.tabId}),this.tabSelected.emit({tabId:t.tabId})}},t.textContent)))}render(){return e(s,{class:this.menuLayout?"menu":""},this.renderMenuOrTabs())}get el(){return a(this)}static get watchers(){return{selectedTab:["setSelected"]}}};b.style=":host,wm-tab-list{position:relative;white-space:nowrap;height:100%;display:block}:host *,wm-tab-list *{-webkit-box-sizing:border-box;box-sizing:border-box}:host .tabcontainer,wm-tab-list .tabcontainer{margin:0;margin-left:-24px;width:100%;height:4.0625rem;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-align:center;align-items:center;padding:0}:host .tabcontainer.dark,wm-tab-list .tabcontainer.dark{background:#353b48;margin:0}:host wm-select,wm-tab-list wm-select{padding:0.375rem 0}";let l=class{constructor(e){t(this,e),this.tabPanelLoaded=i(this,"tabPanelLoaded",7),this.active=!1,this.tabId=""}componentWillLoad(){!this.el.id&&this.el.setAttribute("id",r())}componentDidLoad(){this.tabPanelLoaded.emit({tabId:this.tabId})}toggleTabbingOn(){this.el.classList.add("user-is-tabbing")}toggleTabbingOff(){this.el.classList.remove("user-is-tabbing")}render(){return e(s,{role:"tabpanel","aria-hidden":this.active?"false":"true",class:{"tab-hidden":!this.active},onBlur:()=>this.el.tabIndex=-1,tabIndex:-1})}get el(){return a(this)}};l.style="wm-tab-panel{visibility:inherit}wm-tab-panel.tab-hidden{display:none}wm-tab-panel:active{outline:none}wm-tab-panel:focus{outline:none}wm-tab-panel.user-is-tabbing:focus{outline:-webkit-focus-ring-color auto 5px}";export{h as wm_tab_item,b as wm_tab_list,l as wm_tab_panel}
1
+ import{r as t,c as i,h as e,H as s,g as a,f as o}from"./p-b3c71506.js";import{d as n,g as r}from"./p-de3367ee.js";let h=class{constructor(e){t(this,e),this.wmTabSelected=i(this,"wmTabSelected",7),this.tabSelected=i(this,"tabSelected",7),this.keydownOnTabItem=i(this,"keydownOnTabItem",7),this.tabItemLoaded=i(this,"tabItemLoaded",7),this.selected=!1,this.show=!0,this.tabId="",this.tabClicked=t=>{t.preventDefault(),this.wmTabSelected.emit({tabId:this.tabId}),this.tabSelected.emit({tabId:this.tabId})},this.tabPressed=t=>{const i=t.key;"Enter"===i||" "===i?(t.preventDefault(),this.wmTabSelected.emit({tabId:this.tabId}),this.tabSelected.emit({tabId:this.tabId})):i.includes("Arrow")&&(t.preventDefault(),this.keydownOnTabItem.emit({tabItem:this.el,key:t.key}))}}get parentTabList(){return this.el.parentElement}toggleTabbingOn(){this.linkEl&&this.linkEl.classList.add("user-is-tabbing")}toggleTabbingOff(){this.linkEl&&this.linkEl.classList.remove("user-is-tabbing")}componentWillLoad(){this.el.focus=function(){const t=this.shadowRoot.querySelector("a");t&&t.focus()}}componentDidLoad(){this.tabItemLoaded.emit()}render(){let t=this.show?"":"hide ";t+=this.parentTabList&&"dark"==this.parentTabList.customBackground?"dark":"";let i={};const a=this.parentTabList&&this.parentTabList.customPadding;if(a){const t=2*parseInt(a,10)||0,e=a.split(/([0-9]+)/).pop();i={"padding-left":this.parentTabList.customPadding,"padding-right":this.parentTabList.customPadding,"background-size":`calc(100% - ${t}${e}) 3px`}}return e(s,{role:"presentation"},e("li",{class:"tab-item",role:"presentation"},e("a",{class:`tab ${t}`,style:i,role:"tab",ref:t=>this.linkEl=t,onClick:this.tabClicked,id:`tab-link-${this.tabId}`,onKeyDown:t=>this.tabPressed(t),"aria-selected":this.selected?"true":"false",tabindex:this.selected?0:-1},e("slot",null))))}get el(){return a(this)}};h.style=":host{font-family:inherit;display:inline-block}:host *{-webkit-box-sizing:border-box;box-sizing:border-box}:host .tab-item{list-style-type:none;height:100%;display:inline-block}:host .tab-item .tab{-webkit-border-radius:0;-moz-border-radius:0;-ms-border-radius:0;border-radius:0;color:#575195;text-decoration:none;letter-spacing:0.7px;font-size:0.875rem;font-weight:500;opacity:1;position:relative;text-transform:uppercase;display:inline-block;height:3.3333333333em;line-height:3.3333333333em;padding-right:1.5rem;padding-left:1.5rem}:host .tab-item .tab[aria-selected=true]{font-weight:700;opacity:1;background:-webkit-gradient(linear, left top, left bottom, from(currentColor), to(currentColor)) bottom/0 0 no-repeat;background:linear-gradient(currentColor, currentColor) bottom/0 0 no-repeat;background-size:calc(100% - 50px) 3px}:host .tab-item .tab[aria-selected=true].dark{color:#fff}:host .tab-item .tab,:host .tab-item .tab:hover,:host .tab-item .tab:active{outline:none}:host .tab-item .tab:focus{outline:none}:host .tab-item .tab.dark:not([aria-selected=true]){opacity:0.8;color:#fff}:host .tab-item .tab.user-is-tabbing:focus:not(:active){outline:none;-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}:host .tab-item .tab.user-is-tabbing:focus:not(:active)::-moz-focus-inner{border:0}:host.hide{display:none}";let b=class{constructor(e){t(this,e),this.wmTabSelected=i(this,"wmTabSelected",7),this.tabSelected=i(this,"tabSelected",7),this.controllerEnabled=!1,this.getSelectedTabItem=()=>this.tabItems.filter((t=>t.selected))[0],this.debouncedSetLayout=n((()=>{this.listWidth||this.setListWidth(),o(this.el)}),250)}get menuLayout(){return!!this.listWidth&&this.el.offsetWidth<this.listWidth-24}get tabItems(){return Array.from(this.el.querySelectorAll("wm-tab-item"))}getLinkEl(t){return t.shadowRoot.querySelector("a")}get panels(){const t=Array.from(document.querySelectorAll("wm-tab-panel")),i=this.tabItems.map((t=>t.tabId));return t.filter((t=>i.includes(t.tabId)))}getPanel(t){return this.panels.find((i=>i.tabId===t))}setListWidth(){let t=this.tabItems.reduce(((t,i)=>t+i.offsetWidth),0);this.listWidth=t&&t>0?t:this.listWidth}setSelected(t){if(this.tabItems.map((i=>i.selected=i.tabId===t)),1===this.panels.length&&this.tabItems.length>1){const t=this.getSelectedTabItem();this.setAttributesOnPanel(this.panels[0],t),this.panels[0].active=!0}else this.panels.map((i=>i.active=i.tabId===t))}showItems(){this.tabItems.map((t=>t.show=!0))}hideItems(){this.tabItems.map((t=>t.show=!1))}componentWillLoad(){this.el.focus=function(){const t=Array.from(this.querySelectorAll("wm-tab-item")).filter((t=>t.selected))[0];t&&t.focus()}}componentDidLoad(){this.setLayout(),this.setSelected(this.selectedTab||this.tabItems[0].tabId)}tabItemLoaded(t){this.setAriaOnPanelAndTab(t.target)}setAriaOnPanelAndTab(t){const i=this.getPanel(t.tabId);i?(this.setAttributesOnPanel(i,t),this.setAttributesOnTab(t,i)):1===this.panels.length&&this.setAttributesOnTab(t,this.panels[0])}setAttributesOnTab(t,i){const e=this.getLinkEl(t);e&&(e.setAttribute("aria-controls",i.id),e.setAttribute("href",`#${i.id}`))}removeAttributesOnTab(t){const i=this.getLinkEl(t);i&&(i.removeAttribute("aria-controls"),i.removeAttribute("href"))}setAttributesOnPanel(t,i){const e=this.getLinkEl(i);e&&(t.setAttribute("aria-labelledby",e.id),t.setAttribute("tab-id",i.tabId))}handleTabSelected(t){this.controllerEnabled&&this.setSelected(t.detail.tabId)}handleKeydown(t){const i=t.detail.key,e=this.tabItems.indexOf(t.detail.tabItem);"ArrowLeft"!==i&&"ArrowRight"!==i||this.handleLeftRightArrow(e,i),"ArrowDown"!==i&&"ArrowUp"!==i||this.handleUpDownArrow(i)}handleLeftRightArrow(t,i){i&&(t="ArrowLeft"===i?t-1:t+1),t<0?t=this.tabItems.length-1:t===this.tabItems.length&&(t=0),this.getLinkEl(this.tabItems[t]).focus()}handleUpDownArrow(t){if("ArrowDown"===t&&this.selectedTab){const t=this.getPanel(this.selectedTab);t&&t.focus()}}setLayout(){this.debouncedSetLayout()}renderMenuOrTabs(){if(this.menuLayout)return this.hideItems(),e("wm-select",{label:"Tab Selection","label-position":"none"},this.renderOptions());{this.showItems();let t={};return this.customPadding&&(t={"margin-left":"-"+this.customPadding}),e("ul",{class:`tabcontainer ${this.customBackground||""}`,style:t,role:"tablist"},e("slot",null))}}renderOptions(){return this.tabItems.map((t=>e("wm-option",{id:`tab-link-${t.tabId}`,selected:t.tabId===this.selectedTab,onClick:i=>{i.preventDefault(),this.wmTabSelected.emit({tabId:t.tabId}),this.tabSelected.emit({tabId:t.tabId})}},t.textContent)))}render(){return e(s,{class:this.menuLayout?"menu":""},this.renderMenuOrTabs())}get el(){return a(this)}static get watchers(){return{selectedTab:["setSelected"]}}};b.style=":host,wm-tab-list{position:relative;white-space:nowrap;height:100%;display:block}:host *,wm-tab-list *{-webkit-box-sizing:border-box;box-sizing:border-box}:host .tabcontainer,wm-tab-list .tabcontainer{margin:0;margin-left:-24px;width:100%;height:4.0625rem;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-align:center;align-items:center;padding:0}:host .tabcontainer.dark,wm-tab-list .tabcontainer.dark{background:#353b48;margin:0}:host wm-select,wm-tab-list wm-select{padding:0.375rem 0}";let l=class{constructor(e){t(this,e),this.tabPanelLoaded=i(this,"tabPanelLoaded",7),this.active=!1,this.tabId=""}componentWillLoad(){!this.el.id&&this.el.setAttribute("id",r())}componentDidLoad(){this.tabPanelLoaded.emit({tabId:this.tabId})}toggleTabbingOn(){this.el.classList.add("user-is-tabbing")}toggleTabbingOff(){this.el.classList.remove("user-is-tabbing")}render(){return e(s,{role:"tabpanel","aria-hidden":this.active?"false":"true",class:{"tab-hidden":!this.active},onBlur:()=>this.el.tabIndex=-1,tabIndex:-1})}get el(){return a(this)}};l.style="wm-tab-panel{visibility:inherit}wm-tab-panel.tab-hidden{display:none}wm-tab-panel:active{outline:none}wm-tab-panel:focus{outline:none}wm-tab-panel.user-is-tabbing:focus{outline:-webkit-focus-ring-color auto 5px}";export{h as wm_tab_item,b as wm_tab_list,l as wm_tab_panel}
@@ -1 +1 @@
1
- import{r,f as e,h as p,H as o,g as t,c as n}from"./p-b3c71506.js";import{g as a,i as s,d as i}from"./p-15b1c11b.js";import{t as m,h as c,g as w,a as l,b as g,r as h,c as d,e as b}from"./p-8aa9f811.js";let u=class{constructor(e){r(this,e),this.showLegend=!0,this.isTabbing=!1,this.userIsNavigating=!1,this.uid=a(),this.slicesData=[],this.chartLabelMessage=s.formatMessage({id:"chart.interactiveChart",defaultMessage:"Interactive chart. Use arrow keys to browse elements, press Tab to exit."})}get popoverEl(){return this.el.shadowRoot.querySelector("priv-chart-popover")}get sliceEls(){return Array.from(this.el.shadowRoot.querySelectorAll(".segment"))}get chartData(){return this.mode?m[this.mode]:void 0}get ariaLabelText(){let r=`${this.label}, ${this.chartLabelMessage}`;return this.subinfo&&(r+=` ${this.subinfo}`),r}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}handleKeydown(r){c.call(this,r)}componentWillLoad(){this.label||console.error("For accessibility purposes, you must provide a label for the chart. See https://components.watermarkinsights.com/chart for more information."),2!==this.el.children.length&&console.warn("wm-progress-indicator component must have 2 wm-progress-slice children."),this.el.parentElement.addEventListener("wmProgressMonitorModeChange",(r=>this.mode=r.detail))}async handleSliceUpdate(){await w.call(this,this.mode),e(this.el)}handleModeUpdate(){this.mode&&w.call(this,this.mode)}renderBarOrDoughnut(){return this.total>0&&"bar"===this.mode?l.call(this,this.mode):g.call(this,this.mode)}render(){return p(o,{role:"application","aria-label":this.ariaLabelText,tabindex:"0",onBlur:()=>b.call(this)},p("div",{class:`component-wrapper ${this.mode} ${this.isTabbing&&!this.userIsNavigating?"user-is-tabbing":""}`},p("label",{class:"label",id:`label-${this.uid}`,htmlFor:`graphic-${this.uid}`},p("span",{class:"label-text"},this.label),this.subinfo?p("span",{class:"subinfo"},this.subinfo):""),"bar"===this.mode?h.call(this):"",this.mode&&this.renderBarOrDoughnut(),"doughnut"===this.mode?h.call(this):"",p("priv-chart-popover",{class:this.isTabbing?"user-is-tabbing":""}),"doughnut"===this.mode?d.call(this):""))}get el(){return t(this)}static get watchers(){return{mode:["handleModeUpdate"]}}};u.style=":host .component-wrapper,wm-progress-indicator .component-wrapper{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-align:center;align-items:center;font-size:0.875rem;position:relative;}:host .component-wrapper .label,wm-progress-indicator .component-wrapper .label{display:block;margin:0;padding-bottom:0.25rem;font-weight:500;position:relative}:host .component-wrapper .label .subinfo,wm-progress-indicator .component-wrapper .label .subinfo{display:block;font-weight:normal;font-style:italic;bottom:0.25rem;width:100%;color:#6b6b6b}:host .component-wrapper .legend-wrapper,wm-progress-indicator .component-wrapper .legend-wrapper{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;text-align:center}:host .component-wrapper .legend-wrapper .legend,wm-progress-indicator .component-wrapper .legend-wrapper .legend{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-wrap:wrap;flex-wrap:wrap;text-align:center;padding-top:0.25rem;padding-bottom:0.75rem;-webkit-box-sizing:border-box;box-sizing:border-box}:host .component-wrapper .legend-wrapper .legend.--top,wm-progress-indicator .component-wrapper .legend-wrapper .legend.--top{margin-top:-0.75rem}:host .component-wrapper .legend-wrapper .legend.--top .legend-item,wm-progress-indicator .component-wrapper .legend-wrapper .legend.--top .legend-item{padding-top:0.75rem}:host .component-wrapper .legend-wrapper .legend.--top .legend-color,wm-progress-indicator .component-wrapper .legend-wrapper .legend.--top .legend-color{top:0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom,wm-progress-indicator .component-wrapper .legend-wrapper .legend.--bottom{margin-bottom:-0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom .legend-item,wm-progress-indicator .component-wrapper .legend-wrapper .legend.--bottom .legend-item{padding-bottom:0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom .legend-color,wm-progress-indicator .component-wrapper .legend-wrapper .legend.--bottom .legend-color{top:-0.75rem}:host .component-wrapper .legend-wrapper .legend .legend-item,wm-progress-indicator .component-wrapper .legend-wrapper .legend .legend-item{position:relative}:host .component-wrapper .legend-wrapper .legend .legend-item:not(:last-of-type),wm-progress-indicator .component-wrapper .legend-wrapper .legend .legend-item:not(:last-of-type){padding-right:1.25rem}:host .component-wrapper .legend-wrapper .legend .legend-text,wm-progress-indicator .component-wrapper .legend-wrapper .legend .legend-text{padding-left:1rem;line-height:1}:host .component-wrapper .legend-wrapper .legend .legend-color,wm-progress-indicator .component-wrapper .legend-wrapper .legend .legend-color{position:absolute;left:0;bottom:0;margin:auto;width:0.6875rem;height:0.6875rem}:host .component-wrapper .legend-wrapper .cluster-warning,wm-progress-indicator .component-wrapper .legend-wrapper .cluster-warning{font-size:0.75rem;font-style:italic;max-width:100%}:host .component-wrapper .doughnut-svg,wm-progress-indicator .component-wrapper .doughnut-svg,:host .component-wrapper .inner-bar-wrapper,wm-progress-indicator .component-wrapper .inner-bar-wrapper{overflow:visible}:host .component-wrapper .bar-wrapper,wm-progress-indicator .component-wrapper .bar-wrapper{-ms-flex-positive:1;flex-grow:1;width:100%}:host .component-wrapper .bar-wrapper .inner-bar-wrapper,wm-progress-indicator .component-wrapper .bar-wrapper .inner-bar-wrapper{width:100%}:host .component-wrapper .bar-wrapper .inner-bar-wrapper .values,wm-progress-indicator .component-wrapper .bar-wrapper .inner-bar-wrapper .values{display:-ms-flexbox;display:flex}:host .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper,wm-progress-indicator .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper{display:-ms-flexbox;display:flex}:host .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper .bar-segment,wm-progress-indicator .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper .bar-segment{height:30px;cursor:pointer}:host .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper .bar-segment:not(.zero):not(:last-of-type),wm-progress-indicator .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper .bar-segment:not(.zero):not(:last-of-type){margin-right:2px}:host .component-wrapper .doughnut-wrapper,wm-progress-indicator .component-wrapper .doughnut-wrapper{-webkit-border-radius:4px;-moz-border-radius:4px;-ms-border-radius:4px;border-radius:4px}:host .component-wrapper .doughnut-wrapper .doughnut-segment,wm-progress-indicator .component-wrapper .doughnut-wrapper .doughnut-segment{cursor:pointer}:host .component-wrapper .value,wm-progress-indicator .component-wrapper .value{display:inline-block;text-align:center}:host .component-wrapper .value:not(:last-of-type),wm-progress-indicator .component-wrapper .value:not(:last-of-type){margin-right:2px}:host .component-wrapper path:active,wm-progress-indicator .component-wrapper path:active,:host .component-wrapper path:hover,wm-progress-indicator .component-wrapper path:hover,:host .component-wrapper path:focus,wm-progress-indicator .component-wrapper path:focus,:host .component-wrapper .bar-segment:active,wm-progress-indicator .component-wrapper .bar-segment:active,:host .component-wrapper .bar-segment:hover,wm-progress-indicator .component-wrapper .bar-segment:hover,:host .component-wrapper .bar-segment:focus,wm-progress-indicator .component-wrapper .bar-segment:focus{outline:none}:host .component-wrapper .bar-segment:active.bar-segment,wm-progress-indicator .component-wrapper .bar-segment:active.bar-segment,:host .component-wrapper .bar-segment:hover.bar-segment,wm-progress-indicator .component-wrapper .bar-segment:hover.bar-segment,:host .component-wrapper .bar-segment:focus.bar-segment,wm-progress-indicator .component-wrapper .bar-segment:focus.bar-segment{-webkit-box-shadow:0px 0px 6px #333;-moz-box-shadow:0px 0px 6px #333;box-shadow:0px 0px 6px #333}:host .component-wrapper path:active.doughnut-segment,wm-progress-indicator .component-wrapper path:active.doughnut-segment,:host .component-wrapper path:hover.doughnut-segment,wm-progress-indicator .component-wrapper path:hover.doughnut-segment,:host .component-wrapper path:focus.doughnut-segment,wm-progress-indicator .component-wrapper path:focus.doughnut-segment,:host .component-wrapper .bar-segment:active.doughnut-segment,wm-progress-indicator .component-wrapper .bar-segment:active.doughnut-segment,:host .component-wrapper .bar-segment:hover.doughnut-segment,wm-progress-indicator .component-wrapper .bar-segment:hover.doughnut-segment,:host .component-wrapper .bar-segment:focus.doughnut-segment,wm-progress-indicator .component-wrapper .bar-segment:focus.doughnut-segment{-webkit-filter:url(#wmHoverDropShadow);filter:url(#wmHoverDropShadow)}:host .component-wrapper path::-moz-focus-inner,wm-progress-indicator .component-wrapper path::-moz-focus-inner,:host .component-wrapper .bar-segment::-moz-focus-inner,wm-progress-indicator .component-wrapper .bar-segment::-moz-focus-inner{border:0;outline:none}:host .component-wrapper.doughnut,wm-progress-indicator .component-wrapper.doughnut{width:300px}:host .component-wrapper.doughnut1 label,wm-progress-indicator .component-wrapper.doughnut1 label,:host .component-wrapper.doughnut1 .label-text,wm-progress-indicator .component-wrapper.doughnut1 .label-text,:host .component-wrapper.doughnut2 label,wm-progress-indicator .component-wrapper.doughnut2 label,:host .component-wrapper.doughnut2 .label-text,wm-progress-indicator .component-wrapper.doughnut2 .label-text,:host .component-wrapper.doughnut3 label,wm-progress-indicator .component-wrapper.doughnut3 label,:host .component-wrapper.doughnut3 .label-text,wm-progress-indicator .component-wrapper.doughnut3 .label-text{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}:host .component-wrapper.doughnut0,wm-progress-indicator .component-wrapper.doughnut0,:host .component-wrapper.doughnut,wm-progress-indicator .component-wrapper.doughnut{-ms-flex-align:center;align-items:center}:host .component-wrapper.doughnut0 label,wm-progress-indicator .component-wrapper.doughnut0 label,:host .component-wrapper.doughnut label,wm-progress-indicator .component-wrapper.doughnut label{text-align:center;width:100%;padding-bottom:1.5rem}:host .component-wrapper.doughnut0 label .subinfo,wm-progress-indicator .component-wrapper.doughnut0 label .subinfo,:host .component-wrapper.doughnut label .subinfo,wm-progress-indicator .component-wrapper.doughnut label .subinfo{position:absolute}:host .component-wrapper.doughnut0 .legend,wm-progress-indicator .component-wrapper.doughnut0 .legend,:host .component-wrapper.doughnut .legend,wm-progress-indicator .component-wrapper.doughnut .legend{display:-ms-flexbox;display:flex}:host .component-wrapper.doughnut0 .completion-message,wm-progress-indicator .component-wrapper.doughnut0 .completion-message,:host .component-wrapper.doughnut .completion-message,wm-progress-indicator .component-wrapper.doughnut .completion-message{padding-top:0.625rem}:host .component-wrapper.bar1,wm-progress-indicator .component-wrapper.bar1,:host .component-wrapper.bar,wm-progress-indicator .component-wrapper.bar{padding:1.25rem;-ms-flex-align:start;align-items:flex-start}:host .component-wrapper.bar1 label,wm-progress-indicator .component-wrapper.bar1 label,:host .component-wrapper.bar label,wm-progress-indicator .component-wrapper.bar label{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}:host .component-wrapper.bar1 label .subinfo,wm-progress-indicator .component-wrapper.bar1 label .subinfo,:host .component-wrapper.bar label .subinfo,wm-progress-indicator .component-wrapper.bar label .subinfo{position:initial}:host .component-wrapper.bar1 .legend,wm-progress-indicator .component-wrapper.bar1 .legend,:host .component-wrapper.bar .legend,wm-progress-indicator .component-wrapper.bar .legend{display:none}:host .component-wrapper.bar1 .chart-wrapper,wm-progress-indicator .component-wrapper.bar1 .chart-wrapper,:host .component-wrapper.bar .chart-wrapper,wm-progress-indicator .component-wrapper.bar .chart-wrapper{display:-ms-flexbox;display:flex}:host .component-wrapper.bar1 .chart-wrapper .single-perc,wm-progress-indicator .component-wrapper.bar1 .chart-wrapper .single-perc,:host .component-wrapper.bar .chart-wrapper .single-perc,wm-progress-indicator .component-wrapper.bar .chart-wrapper .single-perc{width:4rem;-ms-flex:none;flex:none;display:-ms-flexbox;display:flex;height:30px;-ms-flex-align:center;align-items:center}:host .component-wrapper.bar1 .chart-wrapper .inner-bar-wrapper,wm-progress-indicator .component-wrapper.bar1 .chart-wrapper .inner-bar-wrapper,:host .component-wrapper.bar .chart-wrapper .inner-bar-wrapper,wm-progress-indicator .component-wrapper.bar .chart-wrapper .inner-bar-wrapper{-ms-flex:1;flex:1}:host .component-wrapper.bar1 .chart-wrapper .completion-message,wm-progress-indicator .component-wrapper.bar1 .chart-wrapper .completion-message,:host .component-wrapper.bar .chart-wrapper .completion-message,wm-progress-indicator .component-wrapper.bar .chart-wrapper .completion-message{width:100%;text-align:right;margin-top:0.25rem}@media screen and (min-width: 768px){:host .component-wrapper.bar1,wm-progress-indicator .component-wrapper.bar1,:host .component-wrapper.bar,wm-progress-indicator .component-wrapper.bar{-ms-flex-direction:row;flex-direction:row}:host .component-wrapper.bar1 label,wm-progress-indicator .component-wrapper.bar1 label,:host .component-wrapper.bar label,wm-progress-indicator .component-wrapper.bar label{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;min-height:30px;width:12rem;text-align:left;padding-right:1.25rem;padding-bottom:0;-ms-flex:none;flex:none}:host .component-wrapper.bar1 .bar-wrapper,wm-progress-indicator .component-wrapper.bar1 .bar-wrapper,:host .component-wrapper.bar .bar-wrapper,wm-progress-indicator .component-wrapper.bar .bar-wrapper{-ms-flex-direction:row-reverse;flex-direction:row-reverse}:host .component-wrapper.bar1 .bar-wrapper .single-perc,wm-progress-indicator .component-wrapper.bar1 .bar-wrapper .single-perc,:host .component-wrapper.bar .bar-wrapper .single-perc,wm-progress-indicator .component-wrapper.bar .bar-wrapper .single-perc{text-align:center;padding-left:0.5rem;-ms-flex-pack:center;justify-content:center}}:host .component-wrapper.bar2,wm-progress-indicator .component-wrapper.bar2,:host .component-wrapper.bar3,wm-progress-indicator .component-wrapper.bar3,:host .component-wrapper.bar4,wm-progress-indicator .component-wrapper.bar4,:host .component-wrapper.bar5,wm-progress-indicator .component-wrapper.bar5{-ms-flex-align:start;align-items:flex-start}:host .component-wrapper.bar2 .inner-bar-wrapper,wm-progress-indicator .component-wrapper.bar2 .inner-bar-wrapper,:host .component-wrapper.bar4 .inner-bar-wrapper,wm-progress-indicator .component-wrapper.bar4 .inner-bar-wrapper,:host .component-wrapper.bar5 .inner-bar-wrapper,wm-progress-indicator .component-wrapper.bar5 .inner-bar-wrapper{height:30px;margin-bottom:0}:host .component-wrapper.bar2 .inner-bar-wrapper.show-values,wm-progress-indicator .component-wrapper.bar2 .inner-bar-wrapper.show-values,:host .component-wrapper.bar4 .inner-bar-wrapper.show-values,wm-progress-indicator .component-wrapper.bar4 .inner-bar-wrapper.show-values,:host .component-wrapper.bar5 .inner-bar-wrapper.show-values,wm-progress-indicator .component-wrapper.bar5 .inner-bar-wrapper.show-values{height:60px;margin-top:0}:host .component-wrapper.bar3 .legend,wm-progress-indicator .component-wrapper.bar3 .legend{padding-bottom:1.25rem}:host .component-wrapper.bar3 .chart-wrapper,wm-progress-indicator .component-wrapper.bar3 .chart-wrapper{position:relative;height:100px}:host .component-wrapper.bar3 .chart-wrapper .inner-bar-wrapper,wm-progress-indicator .component-wrapper.bar3 .chart-wrapper .inner-bar-wrapper{position:absolute;top:35px;left:0;right:0;bottom:0;height:30px}:host .component-wrapper.bar3 .chart-wrapper .inner-bar-wrapper text,wm-progress-indicator .component-wrapper.bar3 .chart-wrapper .inner-bar-wrapper text{fill:#4a4a4a}:host .component-wrapper.bar3 .chart-wrapper .axis,wm-progress-indicator .component-wrapper.bar3 .chart-wrapper .axis{position:absolute;top:0;left:0;height:90px;width:100%;overflow:visible;-webkit-transform:translateY(90px);transform:translateY(90px)}:host .component-wrapper.bar3 .chart-wrapper .axis line,wm-progress-indicator .component-wrapper.bar3 .chart-wrapper .axis line{stroke:#eeedf4;stroke-width:1px}:host .component-wrapper.bar3 .chart-wrapper .axis text,wm-progress-indicator .component-wrapper.bar3 .chart-wrapper .axis text{-webkit-transform:translate(4px, 24px);transform:translate(4px, 24px);text-anchor:middle}:host .component-wrapper.left-label,wm-progress-indicator .component-wrapper.left-label{-ms-flex-direction:row;flex-direction:row}:host .component-wrapper.left-label .label,wm-progress-indicator .component-wrapper.left-label .label{width:12rem;padding-right:1.25rem;-ms-flex:none;flex:none;-ms-flex-item-align:end;align-self:flex-end;min-height:30px;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}:host(:focus){outline:none}:host(:focus) .component-wrapper.user-is-tabbing .bar-segments-wrapper,:host(:focus) .component-wrapper.user-is-tabbing .doughnut-wrapper{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}:host(:focus) .component-wrapper.user-is-tabbing .bar-segments-wrapper::-moz-focus-inner,:host(:focus) .component-wrapper.user-is-tabbing .doughnut-wrapper::-moz-focus-inner{border:0}";let x=class{constructor(p){r(this,p),this.wmProgressMonitorModeChange=n(this,"wmProgressMonitorModeChange",7),this.doughnutWidth=300,this.modeInitialized=!1,this.debouncedUpdate=i((()=>e(this.el)),50)}get parsedBreakpoint(){const r=this.parseToNum(this.breakpoint?this.breakpoint:this.el.children.length);return r>=20?r:r*this.doughnutWidth}get mode(){return this.el.clientWidth>this.parsedBreakpoint?"doughnut":"bar"}componentWillLoad(){new ResizeObserver((()=>this.debouncedUpdate())).observe(this.el)}componentDidLoad(){this.wmProgressMonitorModeChange.emit(this.mode),this.modeInitialized=!0}componentWillUpdate(){this.prevMode!==this.mode&&this.wmProgressMonitorModeChange.emit(this.mode),this.prevMode=this.mode}parseToNum(r){const e=r.toString().replace("px","");return parseInt(e)}render(){return p(o,{class:"doughnut"===this.mode?"row":"column"},this.modeInitialized&&p("slot",null))}get el(){return t(this)}};x.style=":host,wm-progress-monitor{display:-ms-flexbox;display:flex}:host(.row){-ms-flex-direction:row;flex-direction:row}:host(.column){-ms-flex-direction:column;flex-direction:column}";let f=class{constructor(e){r(this,e),this.wmProgressSliceUpdated=n(this,"wmProgressSliceUpdated",7)}componentDidUpdate(){this.wmProgressSliceUpdated.emit()}};export{u as wm_progress_indicator,x as wm_progress_monitor,f as wm_progress_slice}
1
+ import{r,f as e,h as p,H as o,g as t,c as n}from"./p-b3c71506.js";import{g as a,i as s,d as i}from"./p-de3367ee.js";import{t as m,h as c,g as w,a as l,b as g,r as h,c as d,e as b}from"./p-4ecd3430.js";let u=class{constructor(e){r(this,e),this.showLegend=!0,this.isTabbing=!1,this.userIsNavigating=!1,this.uid=a(),this.slicesData=[],this.chartLabelMessage=s.formatMessage({id:"chart.interactiveChart",defaultMessage:"Interactive chart. Use arrow keys to browse elements, press Tab to exit."})}get popoverEl(){return this.el.shadowRoot.querySelector("priv-chart-popover")}get sliceEls(){return Array.from(this.el.shadowRoot.querySelectorAll(".segment"))}get chartData(){return this.mode?m[this.mode]:void 0}get ariaLabelText(){let r=`${this.label}, ${this.chartLabelMessage}`;return this.subinfo&&(r+=` ${this.subinfo}`),r}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}handleKeydown(r){c.call(this,r)}componentWillLoad(){this.label||console.error("For accessibility purposes, you must provide a label for the chart. See https://components.watermarkinsights.com/chart for more information."),2!==this.el.children.length&&console.warn("wm-progress-indicator component must have 2 wm-progress-slice children."),this.el.parentElement.addEventListener("wmProgressMonitorModeChange",(r=>this.mode=r.detail))}async handleSliceUpdate(){await w.call(this,this.mode),e(this.el)}handleModeUpdate(){this.mode&&w.call(this,this.mode)}renderBarOrDoughnut(){return this.total>0&&"bar"===this.mode?l.call(this,this.mode):g.call(this,this.mode)}render(){return p(o,{role:"application","aria-label":this.ariaLabelText,tabindex:"0",onBlur:()=>b.call(this)},p("div",{class:`component-wrapper ${this.mode} ${this.isTabbing&&!this.userIsNavigating?"user-is-tabbing":""}`},p("label",{class:"label",id:`label-${this.uid}`,htmlFor:`graphic-${this.uid}`},p("span",{class:"label-text"},this.label),this.subinfo?p("span",{class:"subinfo"},this.subinfo):""),"bar"===this.mode?h.call(this):"",this.mode&&this.renderBarOrDoughnut(),"doughnut"===this.mode?h.call(this):"",p("priv-chart-popover",{class:this.isTabbing?"user-is-tabbing":""}),"doughnut"===this.mode?d.call(this):""))}get el(){return t(this)}static get watchers(){return{mode:["handleModeUpdate"]}}};u.style=":host .component-wrapper,wm-progress-indicator .component-wrapper{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-align:center;align-items:center;font-size:0.875rem;position:relative;}:host .component-wrapper .label,wm-progress-indicator .component-wrapper .label{display:block;margin:0;padding-bottom:0.25rem;font-weight:500;position:relative}:host .component-wrapper .label .subinfo,wm-progress-indicator .component-wrapper .label .subinfo{display:block;font-weight:normal;font-style:italic;bottom:0.25rem;width:100%;color:#6b6b6b}:host .component-wrapper .legend-wrapper,wm-progress-indicator .component-wrapper .legend-wrapper{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;text-align:center}:host .component-wrapper .legend-wrapper .legend,wm-progress-indicator .component-wrapper .legend-wrapper .legend{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-wrap:wrap;flex-wrap:wrap;text-align:center;padding-top:0.25rem;padding-bottom:0.75rem;-webkit-box-sizing:border-box;box-sizing:border-box}:host .component-wrapper .legend-wrapper .legend.--top,wm-progress-indicator .component-wrapper .legend-wrapper .legend.--top{margin-top:-0.75rem}:host .component-wrapper .legend-wrapper .legend.--top .legend-item,wm-progress-indicator .component-wrapper .legend-wrapper .legend.--top .legend-item{padding-top:0.75rem}:host .component-wrapper .legend-wrapper .legend.--top .legend-color,wm-progress-indicator .component-wrapper .legend-wrapper .legend.--top .legend-color{top:0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom,wm-progress-indicator .component-wrapper .legend-wrapper .legend.--bottom{margin-bottom:-0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom .legend-item,wm-progress-indicator .component-wrapper .legend-wrapper .legend.--bottom .legend-item{padding-bottom:0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom .legend-color,wm-progress-indicator .component-wrapper .legend-wrapper .legend.--bottom .legend-color{top:-0.75rem}:host .component-wrapper .legend-wrapper .legend .legend-item,wm-progress-indicator .component-wrapper .legend-wrapper .legend .legend-item{position:relative}:host .component-wrapper .legend-wrapper .legend .legend-item:not(:last-of-type),wm-progress-indicator .component-wrapper .legend-wrapper .legend .legend-item:not(:last-of-type){padding-right:1.25rem}:host .component-wrapper .legend-wrapper .legend .legend-text,wm-progress-indicator .component-wrapper .legend-wrapper .legend .legend-text{padding-left:1rem;line-height:1}:host .component-wrapper .legend-wrapper .legend .legend-color,wm-progress-indicator .component-wrapper .legend-wrapper .legend .legend-color{position:absolute;left:0;bottom:0;margin:auto;width:0.6875rem;height:0.6875rem}:host .component-wrapper .legend-wrapper .cluster-warning,wm-progress-indicator .component-wrapper .legend-wrapper .cluster-warning{font-size:0.75rem;font-style:italic;max-width:100%}:host .component-wrapper .doughnut-svg,wm-progress-indicator .component-wrapper .doughnut-svg,:host .component-wrapper .inner-bar-wrapper,wm-progress-indicator .component-wrapper .inner-bar-wrapper{overflow:visible}:host .component-wrapper .bar-wrapper,wm-progress-indicator .component-wrapper .bar-wrapper{-ms-flex-positive:1;flex-grow:1;width:100%}:host .component-wrapper .bar-wrapper .inner-bar-wrapper,wm-progress-indicator .component-wrapper .bar-wrapper .inner-bar-wrapper{width:100%}:host .component-wrapper .bar-wrapper .inner-bar-wrapper .values,wm-progress-indicator .component-wrapper .bar-wrapper .inner-bar-wrapper .values{display:-ms-flexbox;display:flex}:host .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper,wm-progress-indicator .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper{display:-ms-flexbox;display:flex}:host .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper .bar-segment,wm-progress-indicator .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper .bar-segment{height:30px;cursor:pointer}:host .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper .bar-segment:not(.zero):not(:last-of-type),wm-progress-indicator .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper .bar-segment:not(.zero):not(:last-of-type){margin-right:2px}:host .component-wrapper .doughnut-wrapper,wm-progress-indicator .component-wrapper .doughnut-wrapper{-webkit-border-radius:4px;-moz-border-radius:4px;-ms-border-radius:4px;border-radius:4px}:host .component-wrapper .doughnut-wrapper .doughnut-segment,wm-progress-indicator .component-wrapper .doughnut-wrapper .doughnut-segment{cursor:pointer}:host .component-wrapper .value,wm-progress-indicator .component-wrapper .value{display:inline-block;text-align:center}:host .component-wrapper .value:not(:last-of-type),wm-progress-indicator .component-wrapper .value:not(:last-of-type){margin-right:2px}:host .component-wrapper path:active,wm-progress-indicator .component-wrapper path:active,:host .component-wrapper path:hover,wm-progress-indicator .component-wrapper path:hover,:host .component-wrapper path:focus,wm-progress-indicator .component-wrapper path:focus,:host .component-wrapper .bar-segment:active,wm-progress-indicator .component-wrapper .bar-segment:active,:host .component-wrapper .bar-segment:hover,wm-progress-indicator .component-wrapper .bar-segment:hover,:host .component-wrapper .bar-segment:focus,wm-progress-indicator .component-wrapper .bar-segment:focus{outline:none}:host .component-wrapper .bar-segment:active.bar-segment,wm-progress-indicator .component-wrapper .bar-segment:active.bar-segment,:host .component-wrapper .bar-segment:hover.bar-segment,wm-progress-indicator .component-wrapper .bar-segment:hover.bar-segment,:host .component-wrapper .bar-segment:focus.bar-segment,wm-progress-indicator .component-wrapper .bar-segment:focus.bar-segment{-webkit-box-shadow:0px 0px 6px #333;-moz-box-shadow:0px 0px 6px #333;box-shadow:0px 0px 6px #333}:host .component-wrapper path:active.doughnut-segment,wm-progress-indicator .component-wrapper path:active.doughnut-segment,:host .component-wrapper path:hover.doughnut-segment,wm-progress-indicator .component-wrapper path:hover.doughnut-segment,:host .component-wrapper path:focus.doughnut-segment,wm-progress-indicator .component-wrapper path:focus.doughnut-segment,:host .component-wrapper .bar-segment:active.doughnut-segment,wm-progress-indicator .component-wrapper .bar-segment:active.doughnut-segment,:host .component-wrapper .bar-segment:hover.doughnut-segment,wm-progress-indicator .component-wrapper .bar-segment:hover.doughnut-segment,:host .component-wrapper .bar-segment:focus.doughnut-segment,wm-progress-indicator .component-wrapper .bar-segment:focus.doughnut-segment{-webkit-filter:url(#wmHoverDropShadow);filter:url(#wmHoverDropShadow)}:host .component-wrapper path::-moz-focus-inner,wm-progress-indicator .component-wrapper path::-moz-focus-inner,:host .component-wrapper .bar-segment::-moz-focus-inner,wm-progress-indicator .component-wrapper .bar-segment::-moz-focus-inner{border:0;outline:none}:host .component-wrapper.doughnut,wm-progress-indicator .component-wrapper.doughnut{width:300px}:host .component-wrapper.doughnut1 label,wm-progress-indicator .component-wrapper.doughnut1 label,:host .component-wrapper.doughnut1 .label-text,wm-progress-indicator .component-wrapper.doughnut1 .label-text,:host .component-wrapper.doughnut2 label,wm-progress-indicator .component-wrapper.doughnut2 label,:host .component-wrapper.doughnut2 .label-text,wm-progress-indicator .component-wrapper.doughnut2 .label-text,:host .component-wrapper.doughnut3 label,wm-progress-indicator .component-wrapper.doughnut3 label,:host .component-wrapper.doughnut3 .label-text,wm-progress-indicator .component-wrapper.doughnut3 .label-text{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}:host .component-wrapper.doughnut0,wm-progress-indicator .component-wrapper.doughnut0,:host .component-wrapper.doughnut,wm-progress-indicator .component-wrapper.doughnut{-ms-flex-align:center;align-items:center}:host .component-wrapper.doughnut0 label,wm-progress-indicator .component-wrapper.doughnut0 label,:host .component-wrapper.doughnut label,wm-progress-indicator .component-wrapper.doughnut label{text-align:center;width:100%;padding-bottom:1.5rem}:host .component-wrapper.doughnut0 label .subinfo,wm-progress-indicator .component-wrapper.doughnut0 label .subinfo,:host .component-wrapper.doughnut label .subinfo,wm-progress-indicator .component-wrapper.doughnut label .subinfo{position:absolute}:host .component-wrapper.doughnut0 .legend,wm-progress-indicator .component-wrapper.doughnut0 .legend,:host .component-wrapper.doughnut .legend,wm-progress-indicator .component-wrapper.doughnut .legend{display:-ms-flexbox;display:flex}:host .component-wrapper.doughnut0 .completion-message,wm-progress-indicator .component-wrapper.doughnut0 .completion-message,:host .component-wrapper.doughnut .completion-message,wm-progress-indicator .component-wrapper.doughnut .completion-message{padding-top:0.625rem}:host .component-wrapper.bar1,wm-progress-indicator .component-wrapper.bar1,:host .component-wrapper.bar,wm-progress-indicator .component-wrapper.bar{padding:1.25rem;-ms-flex-align:start;align-items:flex-start}:host .component-wrapper.bar1 label,wm-progress-indicator .component-wrapper.bar1 label,:host .component-wrapper.bar label,wm-progress-indicator .component-wrapper.bar label{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}:host .component-wrapper.bar1 label .subinfo,wm-progress-indicator .component-wrapper.bar1 label .subinfo,:host .component-wrapper.bar label .subinfo,wm-progress-indicator .component-wrapper.bar label .subinfo{position:initial}:host .component-wrapper.bar1 .legend,wm-progress-indicator .component-wrapper.bar1 .legend,:host .component-wrapper.bar .legend,wm-progress-indicator .component-wrapper.bar .legend{display:none}:host .component-wrapper.bar1 .chart-wrapper,wm-progress-indicator .component-wrapper.bar1 .chart-wrapper,:host .component-wrapper.bar .chart-wrapper,wm-progress-indicator .component-wrapper.bar .chart-wrapper{display:-ms-flexbox;display:flex}:host .component-wrapper.bar1 .chart-wrapper .single-perc,wm-progress-indicator .component-wrapper.bar1 .chart-wrapper .single-perc,:host .component-wrapper.bar .chart-wrapper .single-perc,wm-progress-indicator .component-wrapper.bar .chart-wrapper .single-perc{width:4rem;-ms-flex:none;flex:none;display:-ms-flexbox;display:flex;height:30px;-ms-flex-align:center;align-items:center}:host .component-wrapper.bar1 .chart-wrapper .inner-bar-wrapper,wm-progress-indicator .component-wrapper.bar1 .chart-wrapper .inner-bar-wrapper,:host .component-wrapper.bar .chart-wrapper .inner-bar-wrapper,wm-progress-indicator .component-wrapper.bar .chart-wrapper .inner-bar-wrapper{-ms-flex:1;flex:1}:host .component-wrapper.bar1 .chart-wrapper .completion-message,wm-progress-indicator .component-wrapper.bar1 .chart-wrapper .completion-message,:host .component-wrapper.bar .chart-wrapper .completion-message,wm-progress-indicator .component-wrapper.bar .chart-wrapper .completion-message{width:100%;text-align:right;margin-top:0.25rem}@media screen and (min-width: 768px){:host .component-wrapper.bar1,wm-progress-indicator .component-wrapper.bar1,:host .component-wrapper.bar,wm-progress-indicator .component-wrapper.bar{-ms-flex-direction:row;flex-direction:row}:host .component-wrapper.bar1 label,wm-progress-indicator .component-wrapper.bar1 label,:host .component-wrapper.bar label,wm-progress-indicator .component-wrapper.bar label{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;min-height:30px;width:12rem;text-align:left;padding-right:1.25rem;padding-bottom:0;-ms-flex:none;flex:none}:host .component-wrapper.bar1 .bar-wrapper,wm-progress-indicator .component-wrapper.bar1 .bar-wrapper,:host .component-wrapper.bar .bar-wrapper,wm-progress-indicator .component-wrapper.bar .bar-wrapper{-ms-flex-direction:row-reverse;flex-direction:row-reverse}:host .component-wrapper.bar1 .bar-wrapper .single-perc,wm-progress-indicator .component-wrapper.bar1 .bar-wrapper .single-perc,:host .component-wrapper.bar .bar-wrapper .single-perc,wm-progress-indicator .component-wrapper.bar .bar-wrapper .single-perc{text-align:center;padding-left:0.5rem;-ms-flex-pack:center;justify-content:center}}:host .component-wrapper.bar2,wm-progress-indicator .component-wrapper.bar2,:host .component-wrapper.bar3,wm-progress-indicator .component-wrapper.bar3,:host .component-wrapper.bar4,wm-progress-indicator .component-wrapper.bar4,:host .component-wrapper.bar5,wm-progress-indicator .component-wrapper.bar5{-ms-flex-align:start;align-items:flex-start}:host .component-wrapper.bar2 .inner-bar-wrapper,wm-progress-indicator .component-wrapper.bar2 .inner-bar-wrapper,:host .component-wrapper.bar4 .inner-bar-wrapper,wm-progress-indicator .component-wrapper.bar4 .inner-bar-wrapper,:host .component-wrapper.bar5 .inner-bar-wrapper,wm-progress-indicator .component-wrapper.bar5 .inner-bar-wrapper{height:30px;margin-bottom:0}:host .component-wrapper.bar2 .inner-bar-wrapper.show-values,wm-progress-indicator .component-wrapper.bar2 .inner-bar-wrapper.show-values,:host .component-wrapper.bar4 .inner-bar-wrapper.show-values,wm-progress-indicator .component-wrapper.bar4 .inner-bar-wrapper.show-values,:host .component-wrapper.bar5 .inner-bar-wrapper.show-values,wm-progress-indicator .component-wrapper.bar5 .inner-bar-wrapper.show-values{height:60px;margin-top:0}:host .component-wrapper.bar3 .legend,wm-progress-indicator .component-wrapper.bar3 .legend{padding-bottom:1.25rem}:host .component-wrapper.bar3 .chart-wrapper,wm-progress-indicator .component-wrapper.bar3 .chart-wrapper{position:relative;height:100px}:host .component-wrapper.bar3 .chart-wrapper .inner-bar-wrapper,wm-progress-indicator .component-wrapper.bar3 .chart-wrapper .inner-bar-wrapper{position:absolute;top:35px;left:0;right:0;bottom:0;height:30px}:host .component-wrapper.bar3 .chart-wrapper .inner-bar-wrapper text,wm-progress-indicator .component-wrapper.bar3 .chart-wrapper .inner-bar-wrapper text{fill:#4a4a4a}:host .component-wrapper.bar3 .chart-wrapper .axis,wm-progress-indicator .component-wrapper.bar3 .chart-wrapper .axis{position:absolute;top:0;left:0;height:90px;width:100%;overflow:visible;-webkit-transform:translateY(90px);transform:translateY(90px)}:host .component-wrapper.bar3 .chart-wrapper .axis line,wm-progress-indicator .component-wrapper.bar3 .chart-wrapper .axis line{stroke:#eeedf4;stroke-width:1px}:host .component-wrapper.bar3 .chart-wrapper .axis text,wm-progress-indicator .component-wrapper.bar3 .chart-wrapper .axis text{-webkit-transform:translate(4px, 24px);transform:translate(4px, 24px);text-anchor:middle}:host .component-wrapper.left-label,wm-progress-indicator .component-wrapper.left-label{-ms-flex-direction:row;flex-direction:row}:host .component-wrapper.left-label .label,wm-progress-indicator .component-wrapper.left-label .label{width:12rem;padding-right:1.25rem;-ms-flex:none;flex:none;-ms-flex-item-align:end;align-self:flex-end;min-height:30px;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}:host(:focus){outline:none}:host(:focus) .component-wrapper.user-is-tabbing .bar-segments-wrapper,:host(:focus) .component-wrapper.user-is-tabbing .doughnut-wrapper{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}:host(:focus) .component-wrapper.user-is-tabbing .bar-segments-wrapper::-moz-focus-inner,:host(:focus) .component-wrapper.user-is-tabbing .doughnut-wrapper::-moz-focus-inner{border:0}";let x=class{constructor(p){r(this,p),this.wmProgressMonitorModeChange=n(this,"wmProgressMonitorModeChange",7),this.doughnutWidth=300,this.modeInitialized=!1,this.debouncedUpdate=i((()=>e(this.el)),50)}get parsedBreakpoint(){const r=this.parseToNum(this.breakpoint?this.breakpoint:this.el.children.length);return r>=20?r:r*this.doughnutWidth}get mode(){return this.el.clientWidth>this.parsedBreakpoint?"doughnut":"bar"}componentWillLoad(){new ResizeObserver((()=>this.debouncedUpdate())).observe(this.el)}componentDidLoad(){this.wmProgressMonitorModeChange.emit(this.mode),this.modeInitialized=!0}componentWillUpdate(){this.prevMode!==this.mode&&this.wmProgressMonitorModeChange.emit(this.mode),this.prevMode=this.mode}parseToNum(r){const e=r.toString().replace("px","");return parseInt(e)}render(){return p(o,{class:"doughnut"===this.mode?"row":"column"},this.modeInitialized&&p("slot",null))}get el(){return t(this)}};x.style=":host,wm-progress-monitor{display:-ms-flexbox;display:flex}:host(.row){-ms-flex-direction:row;flex-direction:row}:host(.column){-ms-flex-direction:column;flex-direction:column}";let f=class{constructor(e){r(this,e),this.wmProgressSliceUpdated=n(this,"wmProgressSliceUpdated",7)}componentDidUpdate(){this.wmProgressSliceUpdated.emit()}};export{u as wm_progress_indicator,x as wm_progress_monitor,f as wm_progress_slice}
@@ -1 +1 @@
1
- var __spreadArray=this&&this.__spreadArray||function(e,t,o){if(o||arguments.length===2)for(var a=0,n=t.length,s;a<n;a++){if(s||!(a in t)){if(!s)s=Array.prototype.slice.call(t,0,a);s[a]=t[a]}}return e.concat(s||Array.prototype.slice.call(t))};System.register(["./p-a0c3ef16.system.js","./p-76ca7498.system.js"],(function(e){"use strict";var t,o,a,n,s,i,r,d;return{setters:[function(e){t=e.r;o=e.c;a=e.h;n=e.f;s=e.g},function(e){i=e.i;r=e.l;d=e.u}],execute:function(){var c='.toggle{all:unset;cursor:pointer;padding:0 0.375rem;height:2.375rem;border:none;-moz-border-top-right-radius:3px;-webkit-border-top-right-radius:3px;border-top-right-radius:3px;-moz-border-bottom-right-radius:3px;-webkit-border-bottom-right-radius:3px;border-bottom-right-radius:3px;-moz-border-top-left-radius:0;-webkit-border-top-left-radius:0;border-top-left-radius:0;-moz-border-bottom-left-radius:0;-webkit-border-bottom-left-radius:0;border-bottom-left-radius:0;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;background-color:#fff}.toggle:disabled{pointer-events:none;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;background-color:rgba(74, 74, 74, 0.05)}.toggle:disabled .calendar::after{color:#7b7b7b}.toggle:hover{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;background:#e6e6e6}.toggle:hover .calendar::after{color:#575195}[dir=RTL] .toggle{right:auto;left:0}.toggle span::after{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f0ed";font-size:1.5rem;color:#575195;padding:0;line-height:2.5rem}.toggle:focus{outline:none}.toggle::-moz-focus-inner{border:0}.user-is-tabbing .toggle:focus{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}.user-is-tabbing .toggle:focus::-moz-focus-inner{border:0}.popup{visibility:hidden;font-family:inherit;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;-webkit-box-shadow:0px 4px 15px 0px rgba(0, 0, 0, 0.2);-moz-box-shadow:0px 4px 15px 0px rgba(0, 0, 0, 0.2);box-shadow:0px 4px 15px 0px rgba(0, 0, 0, 0.2);width:21rem;z-index:10;position:absolute;left:0;top:40px;min-height:21.0625rem;-webkit-transition:-webkit-transform 0.25s ease;transition:-webkit-transform 0.25s ease;transition:transform 0.25s ease;transition:transform 0.25s ease, -webkit-transform 0.25s ease;-webkit-transform-origin:center top;transform-origin:center top;-webkit-transform:scale(1, 0);transform:scale(1, 0);background-color:#fff}.popup.open{-webkit-transform:scale(1, 1);transform:scale(1, 1)}.popup.expand-upwards{top:auto;bottom:2.375rem;-webkit-transform-origin:center bottom;transform-origin:center bottom}.popup .calendar-header{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;-webkit-justify-content:space-between;justify-content:space-between;position:relative;padding:0.9375rem 0.25rem}.popup .calendar-header .title-box{height:2.625rem;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;border:1px solid;font-weight:500;font-size:0.875rem;background:transparent;cursor:pointer;display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-align:center;align-items:center;padding:0 0.375rem 0 0.75rem;border-color:#575195;color:#575195}.popup .calendar-header .title-box:after{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f140";padding-left:0.75rem}.popup .calendar-header .title-box.year:after{content:"\\f143"}.popup .calendar-header .title-box::-moz-focus-inner{border:0}.popup .calendar-header .title-box:focus{outline:none}.popup .calendar-header .arw-btn{cursor:pointer;-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;border-radius:50%;width:2.75rem;height:2.75rem;border:none;color:#575195;background:transparent;padding:0;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;line-height:2.75rem}.popup .calendar-header .arw-btn .mdi{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-size:1.5rem;font-weight:normal;line-height:2.75rem}.popup .calendar-header .arw-btn .mdi:hover{background-color:#efeef1}.popup .calendar-header .arw-btn:focus{outline:none}.popup .calendar-header .arw-btn:active{-ms-transform:scale(0.9, 0.9);-webkit-transform:scale(0.9, 0.9);-moz-transform:scale(0.9, 0.9);transform:scale(0.9, 0.9);background-color:#d7d6d9}.popup .day-view{min-width:100%}.popup .day-view .date-grid{width:100%;text-align:center;border-collapse:collapse;margin-bottom:0.4375rem;color:#757575}.popup .day-view .date-grid .date-row:first-child .date-cell{margin-top:0.125rem}.popup .day-view .date-grid .date-header{background-color:#eeedf4}.popup .day-view .date-grid .header-cell{height:2.0625rem;line-height:2.0625rem;width:2.75rem;margin:0 calc((14.28% - 44px) / 2);padding:0;display:inline-block;font-size:0.8125rem;font-weight:bold;color:#4a4a4a;border:none}.popup .day-view .date-grid .date-cell{cursor:pointer;display:inline-block;padding:0;-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;border-radius:50%;height:2.75rem;width:2.75rem;margin:0 calc((14.28% - 44px) / 2);font-size:0.875rem;font-weight:500;line-height:2.75rem}.popup .day-view .date-grid .date-cell:focus{outline:none}.popup .day-view .date-grid .date-cell:hover{background-color:#efeef1}.popup .day-view .date-grid .date-cell:active{background-color:#575195;color:#ffffff}.popup .day-view .date-grid .date-cell.current-month{color:#4a4a4a}.popup .day-view .date-grid .date-cell.current-month[aria-selected=true]{background-color:#575195;color:#ffffff}.popup .month-view .months{border-top:2px solid;border-top-color:#eeedf4;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap}.popup .month-view .month-row{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;-webkit-justify-content:space-between;justify-content:space-between;width:100%;border-bottom:2px solid;border-bottom-color:#eeedf4}.popup .month-view .month{cursor:pointer;text-align:center;width:100%;height:4rem;line-height:4rem;font-weight:500;color:#575195}.popup .month-view .month:not(:last-child){border-right:2px solid;border-right-color:#eeedf4}.popup .month-view .month:focus{outline:none}.popup .month-view .month:hover{background-color:#efeef1}.popup .month-view .month:active,.popup .month-view .month.selected{background-color:#575195;color:#ffffff}.popup.user-is-tabbing button:focus,.popup.user-is-tabbing .title-box:focus,.popup.user-is-tabbing .date-cell:focus,.popup.user-is-tabbing .month:focus{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;border:none;z-index:11}.popup.user-is-tabbing button:focus::-moz-focus-inner,.popup.user-is-tabbing .title-box:focus::-moz-focus-inner,.popup.user-is-tabbing .date-cell:focus::-moz-focus-inner,.popup.user-is-tabbing .month:focus::-moz-focus-inner{border:0}.sr-only{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}';var l=e("priv_datepicker",function(){function e(e){var n=this;t(this,e);this.cellTriggered=o(this,"cellTriggered",7);this.toggleButtonClicked=o(this,"toggleButtonClicked",7);this.popupClosed=o(this,"popupClosed",7);this.popupBlurred=o(this,"popupBlurred",7);this.disabled=false;this.isExpanded=false;this.view="day";this.date=new Date;this.selectedYear=this.date.getUTCFullYear();this.selectedMonth=this.date.getUTCMonth()+1;this.selectedDay=this.date.getUTCDate();this.monthInFocus=this.selectedMonth;this.yearInFocus=this.selectedYear;this.dayInFocus=this.selectedDay;this.monthNumInFocus=this.selectedMonth;this.parentId="";this.isTabbing=false;this.popupClicked=true;this.buttonClicked=true;this.prevClicked=true;this.nextClicked=true;this.openUp=false;this.calendar_months=[i.formatMessage({id:"date.january",defaultMessage:"January",description:"Month of the year"}),i.formatMessage({id:"date.february",defaultMessage:"February",description:"Month of the year"}),i.formatMessage({id:"date.march",defaultMessage:"March",description:"Month of the year"}),i.formatMessage({id:"date.april",defaultMessage:"April",description:"Month of the year"}),i.formatMessage({id:"date.may",defaultMessage:"May",description:"Month of the year"}),i.formatMessage({id:"date.june",defaultMessage:"June",description:"Month of the year"}),i.formatMessage({id:"date.july",defaultMessage:"July",description:"Month of the year"}),i.formatMessage({id:"date.august",defaultMessage:"August",description:"Month of the year"}),i.formatMessage({id:"date.september",defaultMessage:"September",description:"Month of the year"}),i.formatMessage({id:"date.october",defaultMessage:"October",description:"Month of the year"}),i.formatMessage({id:"date.november",defaultMessage:"November",description:"Month of the year"}),i.formatMessage({id:"date.december",defaultMessage:"December",description:"Month of the year"})];this.weekdays=[i.formatMessage({id:"date.sunday",defaultMessage:"Sunday"}),i.formatMessage({id:"date.monday",defaultMessage:"Monday"}),i.formatMessage({id:"date.tuesday",defaultMessage:"Tuesday"}),i.formatMessage({id:"date.wednesday",defaultMessage:"Wednesday"}),i.formatMessage({id:"date.thursday",defaultMessage:"Thursday"}),i.formatMessage({id:"date.friday",defaultMessage:"Friday"}),i.formatMessage({id:"date.saturday",defaultMessage:"Saturday"})];this.renderCalendarDate=function(e,t){var o=n.removeZeroes(String(e[1]));var s=n.removeZeroes(String(e[2]));var r=o===n.monthInFocus?"current-month":"";var d=e[0]+e[1]+e[2];var c=n.isDateToday(e);return a("div",{role:"gridcell",id:"cell-".concat(d,"-").concat(n.parentId),class:"date-cell ".concat(r),"aria-selected":false,"aria-label":"".concat(c?"".concat(i.formatMessage({id:"date.today",defaultMessage:"today",description:"calendar button"}),", "):"").concat(n.weekdays[t],", ").concat(n.calendar_months[o-1]," ").concat(s,", ").concat(e[0]),onClick:function(e){n.handleTriggeredDate(e.target)},onKeyDown:function(e){return n.trapFocusEnd(e)},"data-month":e[1],"data-year":e[0],onBlur:function(e){return e.stopPropagation()}},s)}}e.prototype.handleKey=function(e){this.prevClicked=false;this.nextClicked=false;switch(e.key){case"Enter":e.preventDefault();!e.target.id.includes("popup-title")&&e.target.click();break;case"Escape":e.preventDefault();if(this.isExpanded){e.stopPropagation();this.closePopup(true)}break;case"PageUp":e.preventDefault();this.backOneMonth();break;case"PageDown":e.preventDefault();this.forwardOneMonth();break;case"Home":e.preventDefault();this.unfocusCell();this.dayInFocus=1;n(this.el);break;case"End":e.preventDefault();this.unfocusCell();this.dayInFocus=this.getMonthDays(this.monthInFocus,this.yearInFocus);n(this.el);break;case"ArrowLeft":e.preventDefault();if(this.view==="day"){this.unfocusCell();if(this.dayInFocus===1){var t=this.getPreviousMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=t.month;this.yearInFocus=t.year;this.dayInFocus=this.getMonthDays(this.monthInFocus,this.yearInFocus)}else{this.dayInFocus-=1}}else{this.unfocusMonth();if(this.monthNumInFocus===0){this.monthNumInFocus=11}else{this.monthNumInFocus-=1}}break;case"ArrowRight":e.preventDefault();if(this.view==="day"){this.unfocusCell();if(this.dayInFocus===this.getMonthDays(this.monthInFocus,this.yearInFocus)){var t=this.getNextMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=t.month;this.yearInFocus=t.year;this.dayInFocus=1}else{this.dayInFocus+=1}}else{this.unfocusMonth();if(this.monthNumInFocus===11){this.monthNumInFocus=0}else{this.monthNumInFocus+=1}}break;case"ArrowUp":e.preventDefault();if(this.view==="day"){this.unfocusCell();if(this.dayInFocus<8){var t=this.getPreviousMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=t.month;this.yearInFocus=t.year;var o=7-this.dayInFocus;this.dayInFocus=this.getMonthDays(this.monthInFocus,this.yearInFocus)-o}else{this.dayInFocus-=7}}else{this.unfocusMonth();if(this.monthNumInFocus<3){this.monthNumInFocus+=9}else{this.monthNumInFocus-=3}}break;case"ArrowDown":e.preventDefault();if(!this.isExpanded){this.openPopup()}else{if(this.view==="day"){if(!(document.activeElement.shadowRoot||document).activeElement.classList.contains("date-cell")){this.focusCell();break}this.unfocusCell();var a=this.getMonthDays(this.monthInFocus,this.yearInFocus)-7;if(this.dayInFocus>a){var t=this.getNextMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=t.month;this.yearInFocus=t.year;this.dayInFocus=this.dayInFocus-a}else{this.dayInFocus+=7}}else{var s=(document.activeElement.shadowRoot||document).activeElement;if(s.tagName==="BUTTON"||s.id.includes("popup-title-year")){this.focusMonth();break}this.unfocusMonth();if(this.monthNumInFocus>8){this.monthNumInFocus-=9}else{this.monthNumInFocus+=3}}}break}};e.prototype.toggleTabbingOn=function(e){var t=["Tab","ArrowUp","ArrowDown","ArrowLeft","ArrowRight","Enter"];if(t.includes(e.key)){this.isTabbing=true}};e.prototype.toggleTabbingOff=function(){this.isTabbing=false};e.prototype.blurHandler=function(e){if(!this.popupClicked&&!this.buttonClicked&&this.isExpanded){this.closePopup();this.popupBlurred.emit({relatedTarget:e.target})}this.popupClicked=false;this.buttonClicked=false};e.prototype.handleBlurOnWindow=function(e){if(this.isExpanded){this.closePopup();this.popupBlurred.emit({relatedTarget:e.target})}};e.prototype.componentDidUpdate=function(){this.handleSelectedDate();if(this.isExpanded){this.prevClicked?this.prevButton.focus():this.nextClicked?this.nextButton.focus():this.view==="day"?this.focusCell():this.focusMonth()}};e.prototype.componentDidLoad=function(){this.handleSelectedDate();this.setDateValuesForView()};e.prototype.zeroPad=function(e,t){if(!String.prototype.padStart){String.prototype.padStart=function e(t,o){t=t-this.length;if(t>o.length){o+=o.repeat(t/o.length)}return o.slice(0,t)+String(this)}}return"".concat(e.toString()).padStart(t,"0")};e.prototype.removeZeroes=function(e){return+e<10?+e.slice(1):+e};e.prototype.isDateToday=function(e){var t=this;var o=new Date;var a=[o.getFullYear().toString(),(o.getMonth()+1).toString(),o.getDate().toString()];return a.reduce((function(o,a,n){return o&&t.removeZeroes(e[n]).toString()===a}),true)};e.prototype.togglePopup=function(){this.isExpanded?this.closePopup():this.openPopup();this.buttonClicked=true};e.prototype.closePopup=function(e){var t=this;if(e===void 0){e=false}this.isExpanded=false;this.popupEl.classList.remove("open");window.setTimeout((function(){t.popupEl.style.visibility="hidden"}),250);if(this.view==="day"){this.unfocusCell()}this.monthInFocus=this.selectedMonth;this.yearInFocus=this.selectedYear;this.dayInFocus=this.selectedDay;this.changeView("day");if(e){this.buttonEl.focus()}};e.prototype.openPopup=function(){var e=this;this.panelPosition();this.setDateValuesForView();this.prevClicked=false;this.nextClicked=false;this.popupEl.style.visibility="visible";window.requestAnimationFrame((function(){e.popupEl.classList.add("open")}));this.isExpanded=true;this.focusCell()};e.prototype.getMonthDays=function(e,t){var o=[4,6,9,11];var a=t%4===0;return e===2?a?29:28:o.includes(e)?30:31};e.prototype.getMonthFirstDay=function(e,t){return+new Date(t,e-1,1,12,0,0).getDay()+1};e.prototype.getPreviousMonth=function(e,t){var o=e>1?e-1:12;var a=e>1?t:t-1;return{month:o,year:a}};e.prototype.getNextMonth=function(e,t){var o=e<12?e+1:1;var a=e<12?t:t+1;return{month:o,year:a}};e.prototype.getCalendarDates=function(e,t){var o=this;var a=this.getMonthDays(e,t);var n=this.getMonthFirstDay(e,t);var s=n-1;var i=42-(s+a);i=i>6?i-7:i;var r=this.getPreviousMonth(e,t),d=r.month,c=r.year;var l=this.getNextMonth(e,t),u=l.month,h=l.year;var p=this.getMonthDays(d,c);var f=__spreadArray([],new Array(s).fill("1"),true).map((function(e,t){var a=t+1+(p-s);return[c.toString(),o.zeroPad(d,2),o.zeroPad(a,2)]}));var m=__spreadArray([],new Array(a).fill("1"),true).map((function(a,n){var s=n+1;return[t.toString(),o.zeroPad(e,2),o.zeroPad(s,2)]}));var g=__spreadArray([],new Array(i).fill("1"),true).map((function(e,t){var a=t+1;return[h.toString(),o.zeroPad(u,2),o.zeroPad(a,2)]}));return __spreadArray(__spreadArray(__spreadArray([],f,true),m,true),g,true)};e.prototype.forwardOneMonth=function(){this.unfocusCell();var e=this.getNextMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=e.month;this.yearInFocus=e.year;var t=this.getMonthDays(this.monthInFocus,this.yearInFocus);if(this.dayInFocus>this.getMonthDays(this.monthInFocus,this.yearInFocus)){this.dayInFocus=t}this.updateLiveRegion("Displaying ".concat(this.calendar_months[this.monthInFocus-1],", ").concat(this.yearInFocus))};e.prototype.backOneMonth=function(){this.unfocusCell();var e=this.getPreviousMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=e.month;this.yearInFocus=e.year;var t=this.getMonthDays(this.monthInFocus,this.yearInFocus);if(this.dayInFocus>this.getMonthDays(this.monthInFocus,this.yearInFocus)){this.dayInFocus=t}this.updateLiveRegion("Viewing ".concat(this.calendar_months[this.monthInFocus-1],", ").concat(this.yearInFocus))};e.prototype.handleTriggeredDate=function(e){this.cellTriggered.emit(e);this.closePopup(true)};e.prototype.handleSelectedDate=function(){if(this.selectedDate){this.selectedDate.removeAttribute("aria-selected")}this.selectedDate=this.getCellById(this.selectedYear,this.selectedMonth,this.selectedDay);if(this.selectedDate){this.selectedDate.setAttribute("aria-selected","true")}};e.prototype.getCellById=function(e,t,o){var a=e+this.zeroPad(t,2)+this.zeroPad(o,2);return this.el.querySelector("#cell-".concat(a,"-").concat(this.parentId))};e.prototype.unfocusCell=function(){var e=this.getCellById(this.yearInFocus,this.monthInFocus,this.dayInFocus);e.tabIndex=-1};e.prototype.focusCell=function(){var e=this.getMonthDays(this.monthInFocus,this.yearInFocus);this.dayInFocus=this.dayInFocus>e?e:this.dayInFocus;var t=this.getCellById(this.yearInFocus,this.monthInFocus,this.dayInFocus);if(t){t.tabIndex=0;t.focus()}};e.prototype.unfocusMonth=function(){var e=this.el.querySelector("#month-".concat(this.monthNumInFocus,"-").concat(this.parentId));e.tabIndex=-1};e.prototype.focusMonth=function(){var e=this.el.querySelector("#month-".concat(this.monthNumInFocus,"-").concat(this.parentId));e.tabIndex=0;e.focus()};e.prototype.trapFocusLeft=function(e){if(e.shiftKey&&e.key==="Tab"){e.preventDefault();this.focusCellInView()}};e.prototype.trapFocusEnd=function(e){if(!e.shiftKey&&e.key==="Tab"){e.preventDefault();this.prevButton.focus()}};e.prototype.trapFocusRight=function(e){if(!e.shiftKey&&e.key==="Tab"){e.preventDefault();this.focusCellInView()}};e.prototype.focusCellInView=function(){if(this.view==="day"){this.focusCell()}else{this.focusMonth()}};e.prototype.toggleBusyAttribute=function(e){this.el.querySelector("#wm-container").setAttribute("aria-busy",e)};e.prototype.setDateValuesForView=function(){this.selectedYear=this.date.getUTCFullYear();this.selectedMonth=this.date.getUTCMonth()+1;this.selectedDay=this.date.getUTCDate();this.monthInFocus=this.selectedMonth;this.yearInFocus=this.selectedYear;this.dayInFocus=this.selectedDay;this.monthNumInFocus=this.selectedMonth-1};e.prototype.updateLiveRegion=function(e){var t=this.el.querySelector("#live-region");t.innerHTML=e};e.prototype.panelPosition=function(){var e=document.getElementById(this.parentId);var t=e.shadowRoot.querySelector(".label-wrapper").clientHeight;this.openUp=r(e,this.popupEl,t);if(d(e,336)){this.popupEl.style.left="0";this.popupEl.style.right="auto"}else{this.popupEl.style.right="0";this.popupEl.style.left="auto"}};e.prototype.changeView=function(e){this.view=e;this.monthNumInFocus=this.monthInFocus-1};e.prototype.renderMonths=function(e,t){var o=this;return a("div",{id:"month-".concat(t,"-").concat(this.parentId),class:"month ".concat(this.selectedMonth-1===t?"selected":""),role:"gridcell",tabindex:t+1===this.monthInFocus?0:-1,onKeyDown:function(e){return o.trapFocusEnd(e)},onBlur:function(e){return e.stopPropagation()},onClick:function(){o.monthInFocus=t+1;o.changeView("day")}},e)};e.prototype.render=function(){var e=this;var t=this.getCalendarDates(this.monthInFocus,this.yearInFocus);return a("div",{class:"container",id:"wm-container"},a("button",{disabled:this.disabled,onClick:this.togglePopup.bind(this),"aria-describedby":"date-input-".concat(this.parentId),ref:function(t){return e.buttonEl=t},"aria-expanded":"".concat(this.isExpanded),class:"toggle",id:"toggle-".concat(this.parentId)},a("span",{class:"calendar",title:i.formatMessage({id:"date.calendarView",defaultMessage:"Calendar View",description:"Calendar button"})})),a("div",{class:"popup ".concat(this.view,"-view ").concat(this.openUp?"expand-upwards":""," ").concat(this.isTabbing?"user-is-tabbing":""),id:"popup-".concat(this.parentId),ref:function(t){return e.popupEl=t},onClick:function(){return e.popupClicked=true},role:"application","aria-describedby":"application"},this.view==="day"?a("div",{class:"day-view"},a("div",{class:"calendar-header"},a("button",{onClick:function(){e.prevClicked=true;e.popupClicked=true;e.backOneMonth()},onKeyDown:function(t){return e.trapFocusLeft(t)},ref:function(t){return e.prevButton=t},class:"arw-btn","aria-label":i.formatMessage({id:"date.selectPreviousMonth",defaultMessage:"Select previous month",description:"Calendar button"})},a("span",{class:"mdi"},"")),a("div",{id:"popup-title-month-".concat(this.parentId),class:"title-box",tabindex:0,role:"button",onKeyDown:function(t){if(t.key==="Enter"||t.key===" "){t.preventDefault();e.changeView("month")}},onClick:this.changeView.bind(this,"month"),"aria-label":"".concat(i.formatMessage({id:"date.currentMonth",defaultMessage:"current month",description:"Calendar button"}),": ").concat(this.calendar_months[this.monthInFocus-1],"\n ").concat(this.yearInFocus,"."),"aria-describedby":"month-title"},a("span",{class:"title","aria-hidden":"true"},this.calendar_months[this.monthInFocus-1]," ",this.yearInFocus)),a("button",{onClick:function(){e.nextClicked=true;e.popupClicked=true;e.forwardOneMonth()},onKeyDown:function(t){return e.trapFocusRight(t)},"aria-label":i.formatMessage({id:"date.selectNextMonth",defaultMessage:"Select next month",description:"Calendar button"}),ref:function(t){return e.nextButton=t},class:"arw-btn"},a("span",{class:"mdi"},""))),a("div",{"aria-labelledby":"popup-title-month-".concat(this.parentId),role:"grid",class:"date-grid"},a("div",{role:"rowgroup",class:"date-header"},a("div",{role:"row",class:"header-row"},a("div",{role:"columnheader",class:"header-cell"},a("span",null,i.formatMessage({id:"date.su",defaultMessage:"Su",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,i.formatMessage({id:"date.mo",defaultMessage:"Mo",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,i.formatMessage({id:"date.tu",defaultMessage:"Tu",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,i.formatMessage({id:"date.we",defaultMessage:"We",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,i.formatMessage({id:"date.th",defaultMessage:"Th",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,i.formatMessage({id:"date.fr",defaultMessage:"Fr",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,i.formatMessage({id:"date.sa",defaultMessage:"Sa",description:"Abbreviated day of the week"}))))),a("div",{role:"rowgroup"},a("div",{role:"row",class:"date-row"},t.slice(0,7).map((function(t,o){return e.renderCalendarDate(t,o)}))),a("div",{role:"row"},t.slice(7,14).map((function(t,o){return e.renderCalendarDate(t,o)}))),a("div",{role:"row"},t.slice(14,21).map((function(t,o){return e.renderCalendarDate(t,o)}))),a("div",{role:"row"},t.slice(21,28).map((function(t,o){return e.renderCalendarDate(t,o)}))),a("div",{role:"row"},t.slice(28,35).map((function(t,o){return e.renderCalendarDate(t,o)}))),t.length>35?a("div",{role:"row"},t.slice(35).map((function(t,o){return e.renderCalendarDate(t,o)}))):""))):a("div",{class:"month-view"},a("div",{class:"calendar-header"},a("button",{onClick:function(){e.prevClicked=true;e.popupClicked=true;e.yearInFocus-=1;e.updateLiveRegion("".concat(e.yearInFocus," selected."))},onKeyDown:function(t){return e.trapFocusLeft(t)},"aria-label":i.formatMessage({id:"date.selectPreviousYear",defaultMessage:"Select previous year",description:"Calendar button"}),ref:function(t){return e.prevButton=t},class:"arw-btn"},a("span",{class:"mdi"},"")),a("div",{id:"popup-title-year-".concat(this.parentId),tabindex:0,class:"title-box year",role:"button",onClick:this.changeView.bind(this,"day"),onKeyDown:function(t){if(t.key==="Enter"||t.key===" "){t.preventDefault();e.changeView("day")}},"aria-labelledby":"year-title"},a("span",{class:"title"},this.yearInFocus)),a("button",{onClick:function(){e.nextClicked=true;e.popupClicked=true;e.yearInFocus+=1;e.updateLiveRegion("".concat(e.yearInFocus," selected."))},"aria-label":i.formatMessage({id:"date.selectNextYear",defaultMessage:"Select next year",description:"Calendar button"}),onKeyDown:function(t){return e.trapFocusRight(t)},ref:function(t){return e.nextButton=t},class:"arw-btn"},a("span",{class:"mdi"},""))),a("div",{"aria-labelledby":"popup-title-year-".concat(this.parentId),role:"grid",class:"months"},a("div",{role:"row",class:"month-row"},this.calendar_months.slice(0,3).map((function(t,o){return e.renderMonths(t,o)}))),a("div",{role:"row",class:"month-row"},this.calendar_months.slice(3,6).map((function(t,o){return e.renderMonths(t,o+3)}))),a("div",{role:"row",class:"month-row"},this.calendar_months.slice(6,9).map((function(t,o){return e.renderMonths(t,o+6)}))),a("div",{role:"row",class:"month-row"},this.calendar_months.slice(9).map((function(t,o){return e.renderMonths(t,o+9)})))))),this.isExpanded&&a("div",{id:"live-region","aria-live":"polite","aria-relevant":"text",class:"sr-only"}),a("div",{id:"month-title",class:"sr-only"},i.formatMessage({id:"date.selectMonth",defaultMessage:"Activate to select a month.",description:"Calendar button"})),a("div",{id:"year-title",class:"sr-only"},i.formatMessage({id:"date.selectYear",defaultMessage:"Activate to select a year.",description:"Calendar button"})),a("div",{id:"application",class:"sr-only"},i.formatMessage({id:"date.instructions",defaultMessage:"Use arrows to select a date in the table. Tab left or right to buttons for selecting previous month, next month, or the month selection table."})))};Object.defineProperty(e.prototype,"el",{get:function(){return s(this)},enumerable:false,configurable:true});return e}());l.style=c}}}));
1
+ var __spreadArray=this&&this.__spreadArray||function(e,t,o){if(o||arguments.length===2)for(var a=0,n=t.length,s;a<n;a++){if(s||!(a in t)){if(!s)s=Array.prototype.slice.call(t,0,a);s[a]=t[a]}}return e.concat(s||Array.prototype.slice.call(t))};System.register(["./p-a0c3ef16.system.js","./p-726c979a.system.js"],(function(e){"use strict";var t,o,a,n,s,i,r,d;return{setters:[function(e){t=e.r;o=e.c;a=e.h;n=e.f;s=e.g},function(e){i=e.i;r=e.l;d=e.u}],execute:function(){var c='.toggle{all:unset;cursor:pointer;padding:0 0.375rem;height:2.375rem;border:none;-moz-border-top-right-radius:3px;-webkit-border-top-right-radius:3px;border-top-right-radius:3px;-moz-border-bottom-right-radius:3px;-webkit-border-bottom-right-radius:3px;border-bottom-right-radius:3px;-moz-border-top-left-radius:0;-webkit-border-top-left-radius:0;border-top-left-radius:0;-moz-border-bottom-left-radius:0;-webkit-border-bottom-left-radius:0;border-bottom-left-radius:0;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;background-color:#fff}.toggle:disabled{pointer-events:none;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;background-color:rgba(74, 74, 74, 0.05)}.toggle:disabled .calendar::after{color:#7b7b7b}.toggle:hover{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;background:#e6e6e6}.toggle:hover .calendar::after{color:#575195}[dir=RTL] .toggle{right:auto;left:0}.toggle span::after{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f0ed";font-size:1.5rem;color:#575195;padding:0;line-height:2.5rem}.toggle:focus{outline:none}.toggle::-moz-focus-inner{border:0}.user-is-tabbing .toggle:focus{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}.user-is-tabbing .toggle:focus::-moz-focus-inner{border:0}.popup{visibility:hidden;font-family:inherit;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;-webkit-box-shadow:0px 4px 15px 0px rgba(0, 0, 0, 0.2);-moz-box-shadow:0px 4px 15px 0px rgba(0, 0, 0, 0.2);box-shadow:0px 4px 15px 0px rgba(0, 0, 0, 0.2);width:21rem;z-index:10;position:absolute;left:0;top:40px;min-height:21.0625rem;-webkit-transition:-webkit-transform 0.25s ease;transition:-webkit-transform 0.25s ease;transition:transform 0.25s ease;transition:transform 0.25s ease, -webkit-transform 0.25s ease;-webkit-transform-origin:center top;transform-origin:center top;-webkit-transform:scale(1, 0);transform:scale(1, 0);background-color:#fff}.popup.open{-webkit-transform:scale(1, 1);transform:scale(1, 1)}.popup.expand-upwards{top:auto;bottom:2.375rem;-webkit-transform-origin:center bottom;transform-origin:center bottom}.popup .calendar-header{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;-webkit-justify-content:space-between;justify-content:space-between;position:relative;padding:0.9375rem 0.25rem}.popup .calendar-header .title-box{height:2.625rem;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;border:1px solid;font-weight:500;font-size:0.875rem;background:transparent;cursor:pointer;display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-align:center;align-items:center;padding:0 0.375rem 0 0.75rem;border-color:#575195;color:#575195}.popup .calendar-header .title-box:after{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f140";padding-left:0.75rem}.popup .calendar-header .title-box.year:after{content:"\\f143"}.popup .calendar-header .title-box::-moz-focus-inner{border:0}.popup .calendar-header .title-box:focus{outline:none}.popup .calendar-header .arw-btn{cursor:pointer;-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;border-radius:50%;width:2.75rem;height:2.75rem;border:none;color:#575195;background:transparent;padding:0;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;line-height:2.75rem}.popup .calendar-header .arw-btn .mdi{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-size:1.5rem;font-weight:normal;line-height:2.75rem}.popup .calendar-header .arw-btn .mdi:hover{background-color:#efeef1}.popup .calendar-header .arw-btn:focus{outline:none}.popup .calendar-header .arw-btn:active{-ms-transform:scale(0.9, 0.9);-webkit-transform:scale(0.9, 0.9);-moz-transform:scale(0.9, 0.9);transform:scale(0.9, 0.9);background-color:#d7d6d9}.popup .day-view{min-width:100%}.popup .day-view .date-grid{width:100%;text-align:center;border-collapse:collapse;margin-bottom:0.4375rem;color:#757575}.popup .day-view .date-grid .date-row:first-child .date-cell{margin-top:0.125rem}.popup .day-view .date-grid .date-header{background-color:#eeedf4}.popup .day-view .date-grid .header-cell{height:2.0625rem;line-height:2.0625rem;width:2.75rem;margin:0 calc((14.28% - 44px) / 2);padding:0;display:inline-block;font-size:0.8125rem;font-weight:bold;color:#4a4a4a;border:none}.popup .day-view .date-grid .date-cell{cursor:pointer;display:inline-block;padding:0;-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;border-radius:50%;height:2.75rem;width:2.75rem;margin:0 calc((14.28% - 44px) / 2);font-size:0.875rem;font-weight:500;line-height:2.75rem}.popup .day-view .date-grid .date-cell:focus{outline:none}.popup .day-view .date-grid .date-cell:hover{background-color:#efeef1}.popup .day-view .date-grid .date-cell:active{background-color:#575195;color:#ffffff}.popup .day-view .date-grid .date-cell.current-month{color:#4a4a4a}.popup .day-view .date-grid .date-cell.current-month[aria-selected=true]{background-color:#575195;color:#ffffff}.popup .month-view .months{border-top:2px solid;border-top-color:#eeedf4;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap}.popup .month-view .month-row{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;-webkit-justify-content:space-between;justify-content:space-between;width:100%;border-bottom:2px solid;border-bottom-color:#eeedf4}.popup .month-view .month{cursor:pointer;text-align:center;width:100%;height:4rem;line-height:4rem;font-weight:500;color:#575195}.popup .month-view .month:not(:last-child){border-right:2px solid;border-right-color:#eeedf4}.popup .month-view .month:focus{outline:none}.popup .month-view .month:hover{background-color:#efeef1}.popup .month-view .month:active,.popup .month-view .month.selected{background-color:#575195;color:#ffffff}.popup.user-is-tabbing button:focus,.popup.user-is-tabbing .title-box:focus,.popup.user-is-tabbing .date-cell:focus,.popup.user-is-tabbing .month:focus{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;border:none;z-index:11}.popup.user-is-tabbing button:focus::-moz-focus-inner,.popup.user-is-tabbing .title-box:focus::-moz-focus-inner,.popup.user-is-tabbing .date-cell:focus::-moz-focus-inner,.popup.user-is-tabbing .month:focus::-moz-focus-inner{border:0}.sr-only{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}';var l=e("priv_datepicker",function(){function e(e){var n=this;t(this,e);this.cellTriggered=o(this,"cellTriggered",7);this.toggleButtonClicked=o(this,"toggleButtonClicked",7);this.popupClosed=o(this,"popupClosed",7);this.popupBlurred=o(this,"popupBlurred",7);this.disabled=false;this.isExpanded=false;this.view="day";this.date=new Date;this.selectedYear=this.date.getUTCFullYear();this.selectedMonth=this.date.getUTCMonth()+1;this.selectedDay=this.date.getUTCDate();this.monthInFocus=this.selectedMonth;this.yearInFocus=this.selectedYear;this.dayInFocus=this.selectedDay;this.monthNumInFocus=this.selectedMonth;this.parentId="";this.isTabbing=false;this.popupClicked=true;this.buttonClicked=true;this.prevClicked=true;this.nextClicked=true;this.openUp=false;this.calendar_months=[i.formatMessage({id:"date.january",defaultMessage:"January",description:"Month of the year"}),i.formatMessage({id:"date.february",defaultMessage:"February",description:"Month of the year"}),i.formatMessage({id:"date.march",defaultMessage:"March",description:"Month of the year"}),i.formatMessage({id:"date.april",defaultMessage:"April",description:"Month of the year"}),i.formatMessage({id:"date.may",defaultMessage:"May",description:"Month of the year"}),i.formatMessage({id:"date.june",defaultMessage:"June",description:"Month of the year"}),i.formatMessage({id:"date.july",defaultMessage:"July",description:"Month of the year"}),i.formatMessage({id:"date.august",defaultMessage:"August",description:"Month of the year"}),i.formatMessage({id:"date.september",defaultMessage:"September",description:"Month of the year"}),i.formatMessage({id:"date.october",defaultMessage:"October",description:"Month of the year"}),i.formatMessage({id:"date.november",defaultMessage:"November",description:"Month of the year"}),i.formatMessage({id:"date.december",defaultMessage:"December",description:"Month of the year"})];this.weekdays=[i.formatMessage({id:"date.sunday",defaultMessage:"Sunday"}),i.formatMessage({id:"date.monday",defaultMessage:"Monday"}),i.formatMessage({id:"date.tuesday",defaultMessage:"Tuesday"}),i.formatMessage({id:"date.wednesday",defaultMessage:"Wednesday"}),i.formatMessage({id:"date.thursday",defaultMessage:"Thursday"}),i.formatMessage({id:"date.friday",defaultMessage:"Friday"}),i.formatMessage({id:"date.saturday",defaultMessage:"Saturday"})];this.renderCalendarDate=function(e,t){var o=n.removeZeroes(String(e[1]));var s=n.removeZeroes(String(e[2]));var r=o===n.monthInFocus?"current-month":"";var d=e[0]+e[1]+e[2];var c=n.isDateToday(e);return a("div",{role:"gridcell",id:"cell-".concat(d,"-").concat(n.parentId),class:"date-cell ".concat(r),"aria-selected":false,"aria-label":"".concat(c?"".concat(i.formatMessage({id:"date.today",defaultMessage:"today",description:"calendar button"}),", "):"").concat(n.weekdays[t],", ").concat(n.calendar_months[o-1]," ").concat(s,", ").concat(e[0]),onClick:function(e){n.handleTriggeredDate(e.target)},onKeyDown:function(e){return n.trapFocusEnd(e)},"data-month":e[1],"data-year":e[0],onBlur:function(e){return e.stopPropagation()}},s)}}e.prototype.handleKey=function(e){this.prevClicked=false;this.nextClicked=false;switch(e.key){case"Enter":e.preventDefault();!e.target.id.includes("popup-title")&&e.target.click();break;case"Escape":e.preventDefault();if(this.isExpanded){e.stopPropagation();this.closePopup(true)}break;case"PageUp":e.preventDefault();this.backOneMonth();break;case"PageDown":e.preventDefault();this.forwardOneMonth();break;case"Home":e.preventDefault();this.unfocusCell();this.dayInFocus=1;n(this.el);break;case"End":e.preventDefault();this.unfocusCell();this.dayInFocus=this.getMonthDays(this.monthInFocus,this.yearInFocus);n(this.el);break;case"ArrowLeft":e.preventDefault();if(this.view==="day"){this.unfocusCell();if(this.dayInFocus===1){var t=this.getPreviousMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=t.month;this.yearInFocus=t.year;this.dayInFocus=this.getMonthDays(this.monthInFocus,this.yearInFocus)}else{this.dayInFocus-=1}}else{this.unfocusMonth();if(this.monthNumInFocus===0){this.monthNumInFocus=11}else{this.monthNumInFocus-=1}}break;case"ArrowRight":e.preventDefault();if(this.view==="day"){this.unfocusCell();if(this.dayInFocus===this.getMonthDays(this.monthInFocus,this.yearInFocus)){var t=this.getNextMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=t.month;this.yearInFocus=t.year;this.dayInFocus=1}else{this.dayInFocus+=1}}else{this.unfocusMonth();if(this.monthNumInFocus===11){this.monthNumInFocus=0}else{this.monthNumInFocus+=1}}break;case"ArrowUp":e.preventDefault();if(this.view==="day"){this.unfocusCell();if(this.dayInFocus<8){var t=this.getPreviousMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=t.month;this.yearInFocus=t.year;var o=7-this.dayInFocus;this.dayInFocus=this.getMonthDays(this.monthInFocus,this.yearInFocus)-o}else{this.dayInFocus-=7}}else{this.unfocusMonth();if(this.monthNumInFocus<3){this.monthNumInFocus+=9}else{this.monthNumInFocus-=3}}break;case"ArrowDown":e.preventDefault();if(!this.isExpanded){this.openPopup()}else{if(this.view==="day"){if(!(document.activeElement.shadowRoot||document).activeElement.classList.contains("date-cell")){this.focusCell();break}this.unfocusCell();var a=this.getMonthDays(this.monthInFocus,this.yearInFocus)-7;if(this.dayInFocus>a){var t=this.getNextMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=t.month;this.yearInFocus=t.year;this.dayInFocus=this.dayInFocus-a}else{this.dayInFocus+=7}}else{var s=(document.activeElement.shadowRoot||document).activeElement;if(s.tagName==="BUTTON"||s.id.includes("popup-title-year")){this.focusMonth();break}this.unfocusMonth();if(this.monthNumInFocus>8){this.monthNumInFocus-=9}else{this.monthNumInFocus+=3}}}break}};e.prototype.toggleTabbingOn=function(e){var t=["Tab","ArrowUp","ArrowDown","ArrowLeft","ArrowRight","Enter"];if(t.includes(e.key)){this.isTabbing=true}};e.prototype.toggleTabbingOff=function(){this.isTabbing=false};e.prototype.blurHandler=function(e){if(!this.popupClicked&&!this.buttonClicked&&this.isExpanded){this.closePopup();this.popupBlurred.emit({relatedTarget:e.target})}this.popupClicked=false;this.buttonClicked=false};e.prototype.handleBlurOnWindow=function(e){if(this.isExpanded){this.closePopup();this.popupBlurred.emit({relatedTarget:e.target})}};e.prototype.componentDidUpdate=function(){this.handleSelectedDate();if(this.isExpanded){this.prevClicked?this.prevButton.focus():this.nextClicked?this.nextButton.focus():this.view==="day"?this.focusCell():this.focusMonth()}};e.prototype.componentDidLoad=function(){this.handleSelectedDate();this.setDateValuesForView()};e.prototype.zeroPad=function(e,t){if(!String.prototype.padStart){String.prototype.padStart=function e(t,o){t=t-this.length;if(t>o.length){o+=o.repeat(t/o.length)}return o.slice(0,t)+String(this)}}return"".concat(e.toString()).padStart(t,"0")};e.prototype.removeZeroes=function(e){return+e<10?+e.slice(1):+e};e.prototype.isDateToday=function(e){var t=this;var o=new Date;var a=[o.getFullYear().toString(),(o.getMonth()+1).toString(),o.getDate().toString()];return a.reduce((function(o,a,n){return o&&t.removeZeroes(e[n]).toString()===a}),true)};e.prototype.togglePopup=function(){this.isExpanded?this.closePopup():this.openPopup();this.buttonClicked=true};e.prototype.closePopup=function(e){var t=this;if(e===void 0){e=false}this.isExpanded=false;this.popupEl.classList.remove("open");window.setTimeout((function(){t.popupEl.style.visibility="hidden"}),250);if(this.view==="day"){this.unfocusCell()}this.monthInFocus=this.selectedMonth;this.yearInFocus=this.selectedYear;this.dayInFocus=this.selectedDay;this.changeView("day");if(e){this.buttonEl.focus()}};e.prototype.openPopup=function(){var e=this;this.panelPosition();this.setDateValuesForView();this.prevClicked=false;this.nextClicked=false;this.popupEl.style.visibility="visible";window.requestAnimationFrame((function(){e.popupEl.classList.add("open")}));this.isExpanded=true;this.focusCell()};e.prototype.getMonthDays=function(e,t){var o=[4,6,9,11];var a=t%4===0;return e===2?a?29:28:o.includes(e)?30:31};e.prototype.getMonthFirstDay=function(e,t){return+new Date(t,e-1,1,12,0,0).getDay()+1};e.prototype.getPreviousMonth=function(e,t){var o=e>1?e-1:12;var a=e>1?t:t-1;return{month:o,year:a}};e.prototype.getNextMonth=function(e,t){var o=e<12?e+1:1;var a=e<12?t:t+1;return{month:o,year:a}};e.prototype.getCalendarDates=function(e,t){var o=this;var a=this.getMonthDays(e,t);var n=this.getMonthFirstDay(e,t);var s=n-1;var i=42-(s+a);i=i>6?i-7:i;var r=this.getPreviousMonth(e,t),d=r.month,c=r.year;var l=this.getNextMonth(e,t),u=l.month,h=l.year;var p=this.getMonthDays(d,c);var f=__spreadArray([],new Array(s).fill("1"),true).map((function(e,t){var a=t+1+(p-s);return[c.toString(),o.zeroPad(d,2),o.zeroPad(a,2)]}));var m=__spreadArray([],new Array(a).fill("1"),true).map((function(a,n){var s=n+1;return[t.toString(),o.zeroPad(e,2),o.zeroPad(s,2)]}));var g=__spreadArray([],new Array(i).fill("1"),true).map((function(e,t){var a=t+1;return[h.toString(),o.zeroPad(u,2),o.zeroPad(a,2)]}));return __spreadArray(__spreadArray(__spreadArray([],f,true),m,true),g,true)};e.prototype.forwardOneMonth=function(){this.unfocusCell();var e=this.getNextMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=e.month;this.yearInFocus=e.year;var t=this.getMonthDays(this.monthInFocus,this.yearInFocus);if(this.dayInFocus>this.getMonthDays(this.monthInFocus,this.yearInFocus)){this.dayInFocus=t}this.updateLiveRegion("Displaying ".concat(this.calendar_months[this.monthInFocus-1],", ").concat(this.yearInFocus))};e.prototype.backOneMonth=function(){this.unfocusCell();var e=this.getPreviousMonth(this.monthInFocus,this.yearInFocus);this.monthInFocus=e.month;this.yearInFocus=e.year;var t=this.getMonthDays(this.monthInFocus,this.yearInFocus);if(this.dayInFocus>this.getMonthDays(this.monthInFocus,this.yearInFocus)){this.dayInFocus=t}this.updateLiveRegion("Viewing ".concat(this.calendar_months[this.monthInFocus-1],", ").concat(this.yearInFocus))};e.prototype.handleTriggeredDate=function(e){this.cellTriggered.emit(e);this.closePopup(true)};e.prototype.handleSelectedDate=function(){if(this.selectedDate){this.selectedDate.removeAttribute("aria-selected")}this.selectedDate=this.getCellById(this.selectedYear,this.selectedMonth,this.selectedDay);if(this.selectedDate){this.selectedDate.setAttribute("aria-selected","true")}};e.prototype.getCellById=function(e,t,o){var a=e+this.zeroPad(t,2)+this.zeroPad(o,2);return this.el.querySelector("#cell-".concat(a,"-").concat(this.parentId))};e.prototype.unfocusCell=function(){var e=this.getCellById(this.yearInFocus,this.monthInFocus,this.dayInFocus);e.tabIndex=-1};e.prototype.focusCell=function(){var e=this.getMonthDays(this.monthInFocus,this.yearInFocus);this.dayInFocus=this.dayInFocus>e?e:this.dayInFocus;var t=this.getCellById(this.yearInFocus,this.monthInFocus,this.dayInFocus);if(t){t.tabIndex=0;t.focus()}};e.prototype.unfocusMonth=function(){var e=this.el.querySelector("#month-".concat(this.monthNumInFocus,"-").concat(this.parentId));e.tabIndex=-1};e.prototype.focusMonth=function(){var e=this.el.querySelector("#month-".concat(this.monthNumInFocus,"-").concat(this.parentId));e.tabIndex=0;e.focus()};e.prototype.trapFocusLeft=function(e){if(e.shiftKey&&e.key==="Tab"){e.preventDefault();this.focusCellInView()}};e.prototype.trapFocusEnd=function(e){if(!e.shiftKey&&e.key==="Tab"){e.preventDefault();this.prevButton.focus()}};e.prototype.trapFocusRight=function(e){if(!e.shiftKey&&e.key==="Tab"){e.preventDefault();this.focusCellInView()}};e.prototype.focusCellInView=function(){if(this.view==="day"){this.focusCell()}else{this.focusMonth()}};e.prototype.toggleBusyAttribute=function(e){this.el.querySelector("#wm-container").setAttribute("aria-busy",e)};e.prototype.setDateValuesForView=function(){this.selectedYear=this.date.getUTCFullYear();this.selectedMonth=this.date.getUTCMonth()+1;this.selectedDay=this.date.getUTCDate();this.monthInFocus=this.selectedMonth;this.yearInFocus=this.selectedYear;this.dayInFocus=this.selectedDay;this.monthNumInFocus=this.selectedMonth-1};e.prototype.updateLiveRegion=function(e){var t=this.el.querySelector("#live-region");t.innerHTML=e};e.prototype.panelPosition=function(){var e=document.getElementById(this.parentId);var t=e.shadowRoot.querySelector(".label-wrapper").clientHeight;this.openUp=r(e,this.popupEl,t);if(d(e,336)){this.popupEl.style.left="0";this.popupEl.style.right="auto"}else{this.popupEl.style.right="0";this.popupEl.style.left="auto"}};e.prototype.changeView=function(e){this.view=e;this.monthNumInFocus=this.monthInFocus-1};e.prototype.renderMonths=function(e,t){var o=this;return a("div",{id:"month-".concat(t,"-").concat(this.parentId),class:"month ".concat(this.selectedMonth-1===t?"selected":""),role:"gridcell",tabindex:t+1===this.monthInFocus?0:-1,onKeyDown:function(e){return o.trapFocusEnd(e)},onBlur:function(e){return e.stopPropagation()},onClick:function(){o.monthInFocus=t+1;o.changeView("day")}},e)};e.prototype.render=function(){var e=this;var t=this.getCalendarDates(this.monthInFocus,this.yearInFocus);return a("div",{class:"container",id:"wm-container"},a("button",{disabled:this.disabled,onClick:this.togglePopup.bind(this),"aria-describedby":"date-input-".concat(this.parentId),ref:function(t){return e.buttonEl=t},"aria-expanded":"".concat(this.isExpanded),class:"toggle",id:"toggle-".concat(this.parentId)},a("span",{class:"calendar",title:i.formatMessage({id:"date.calendarView",defaultMessage:"Calendar View",description:"Calendar button"})})),a("div",{class:"popup ".concat(this.view,"-view ").concat(this.openUp?"expand-upwards":""," ").concat(this.isTabbing?"user-is-tabbing":""),id:"popup-".concat(this.parentId),ref:function(t){return e.popupEl=t},onClick:function(){return e.popupClicked=true},role:"application","aria-describedby":"application"},this.view==="day"?a("div",{class:"day-view"},a("div",{class:"calendar-header"},a("button",{onClick:function(){e.prevClicked=true;e.popupClicked=true;e.backOneMonth()},onKeyDown:function(t){return e.trapFocusLeft(t)},ref:function(t){return e.prevButton=t},class:"arw-btn","aria-label":i.formatMessage({id:"date.selectPreviousMonth",defaultMessage:"Select previous month",description:"Calendar button"})},a("span",{class:"mdi"},"")),a("div",{id:"popup-title-month-".concat(this.parentId),class:"title-box",tabindex:0,role:"button",onKeyDown:function(t){if(t.key==="Enter"||t.key===" "){t.preventDefault();e.changeView("month")}},onClick:this.changeView.bind(this,"month"),"aria-label":"".concat(i.formatMessage({id:"date.currentMonth",defaultMessage:"current month",description:"Calendar button"}),": ").concat(this.calendar_months[this.monthInFocus-1],"\n ").concat(this.yearInFocus,"."),"aria-describedby":"month-title"},a("span",{class:"title","aria-hidden":"true"},this.calendar_months[this.monthInFocus-1]," ",this.yearInFocus)),a("button",{onClick:function(){e.nextClicked=true;e.popupClicked=true;e.forwardOneMonth()},onKeyDown:function(t){return e.trapFocusRight(t)},"aria-label":i.formatMessage({id:"date.selectNextMonth",defaultMessage:"Select next month",description:"Calendar button"}),ref:function(t){return e.nextButton=t},class:"arw-btn"},a("span",{class:"mdi"},""))),a("div",{"aria-labelledby":"popup-title-month-".concat(this.parentId),role:"grid",class:"date-grid"},a("div",{role:"rowgroup",class:"date-header"},a("div",{role:"row",class:"header-row"},a("div",{role:"columnheader",class:"header-cell"},a("span",null,i.formatMessage({id:"date.su",defaultMessage:"Su",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,i.formatMessage({id:"date.mo",defaultMessage:"Mo",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,i.formatMessage({id:"date.tu",defaultMessage:"Tu",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,i.formatMessage({id:"date.we",defaultMessage:"We",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,i.formatMessage({id:"date.th",defaultMessage:"Th",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,i.formatMessage({id:"date.fr",defaultMessage:"Fr",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,i.formatMessage({id:"date.sa",defaultMessage:"Sa",description:"Abbreviated day of the week"}))))),a("div",{role:"rowgroup"},a("div",{role:"row",class:"date-row"},t.slice(0,7).map((function(t,o){return e.renderCalendarDate(t,o)}))),a("div",{role:"row"},t.slice(7,14).map((function(t,o){return e.renderCalendarDate(t,o)}))),a("div",{role:"row"},t.slice(14,21).map((function(t,o){return e.renderCalendarDate(t,o)}))),a("div",{role:"row"},t.slice(21,28).map((function(t,o){return e.renderCalendarDate(t,o)}))),a("div",{role:"row"},t.slice(28,35).map((function(t,o){return e.renderCalendarDate(t,o)}))),t.length>35?a("div",{role:"row"},t.slice(35).map((function(t,o){return e.renderCalendarDate(t,o)}))):""))):a("div",{class:"month-view"},a("div",{class:"calendar-header"},a("button",{onClick:function(){e.prevClicked=true;e.popupClicked=true;e.yearInFocus-=1;e.updateLiveRegion("".concat(e.yearInFocus," selected."))},onKeyDown:function(t){return e.trapFocusLeft(t)},"aria-label":i.formatMessage({id:"date.selectPreviousYear",defaultMessage:"Select previous year",description:"Calendar button"}),ref:function(t){return e.prevButton=t},class:"arw-btn"},a("span",{class:"mdi"},"")),a("div",{id:"popup-title-year-".concat(this.parentId),tabindex:0,class:"title-box year",role:"button",onClick:this.changeView.bind(this,"day"),onKeyDown:function(t){if(t.key==="Enter"||t.key===" "){t.preventDefault();e.changeView("day")}},"aria-labelledby":"year-title"},a("span",{class:"title"},this.yearInFocus)),a("button",{onClick:function(){e.nextClicked=true;e.popupClicked=true;e.yearInFocus+=1;e.updateLiveRegion("".concat(e.yearInFocus," selected."))},"aria-label":i.formatMessage({id:"date.selectNextYear",defaultMessage:"Select next year",description:"Calendar button"}),onKeyDown:function(t){return e.trapFocusRight(t)},ref:function(t){return e.nextButton=t},class:"arw-btn"},a("span",{class:"mdi"},""))),a("div",{"aria-labelledby":"popup-title-year-".concat(this.parentId),role:"grid",class:"months"},a("div",{role:"row",class:"month-row"},this.calendar_months.slice(0,3).map((function(t,o){return e.renderMonths(t,o)}))),a("div",{role:"row",class:"month-row"},this.calendar_months.slice(3,6).map((function(t,o){return e.renderMonths(t,o+3)}))),a("div",{role:"row",class:"month-row"},this.calendar_months.slice(6,9).map((function(t,o){return e.renderMonths(t,o+6)}))),a("div",{role:"row",class:"month-row"},this.calendar_months.slice(9).map((function(t,o){return e.renderMonths(t,o+9)})))))),this.isExpanded&&a("div",{id:"live-region","aria-live":"polite","aria-relevant":"text",class:"sr-only"}),a("div",{id:"month-title",class:"sr-only"},i.formatMessage({id:"date.selectMonth",defaultMessage:"Activate to select a month.",description:"Calendar button"})),a("div",{id:"year-title",class:"sr-only"},i.formatMessage({id:"date.selectYear",defaultMessage:"Activate to select a year.",description:"Calendar button"})),a("div",{id:"application",class:"sr-only"},i.formatMessage({id:"date.instructions",defaultMessage:"Use arrows to select a date in the table. Tab left or right to buttons for selecting previous month, next month, or the month selection table."})))};Object.defineProperty(e.prototype,"el",{get:function(){return s(this)},enumerable:false,configurable:true});return e}());l.style=c}}}));
@@ -0,0 +1 @@
1
+ import{r as t,h as o,H as n,g as e}from"./p-b3c71506.js";import{g as i}from"./p-43f1298b.js";import{g as a,t as s,a as r}from"./p-de3367ee.js";let b=class{constructor(o){t(this,o),this.disabled=!1,this.buttonType=null,this.buttonStyle=null,this.tooltipPosition="bottom-right",this.permanentlyDelete=!1,this.textWrap=!0,this.tooltipVisible=!1,this.isTabbing=!1,this.btnPos={old:{},new:{}},this.id=a(),this.ariaPopup=!1}get isDisabled(){return s(this.disabled)}get tempButtonType(){return this.buttonType||this.buttonStyle||"secondary"}get isTruncated(){return!!this.buttonEl&&this.buttonEl.offsetWidth<this.buttonEl.scrollWidth}get hasTooltip(){return"icononly"===this.tempButtonType||"navigational"===this.tempButtonType||this.isTruncated}get tooltipEl(){return document.getElementById("wm-tooltip")}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}handleScroll(){this.tooltipVisible&&this.hideTooltip()}validateType(t){["primary","secondary","textonly","icononly","navigational","selectoronly","pairpositive","pairnegative"].includes(t)||(this.buttonType="secondary"),this.validateIcon()}validateDeprecatedType(t){["primary","secondary","textonly","icononly","navigational","selectoronly"].includes(t)||(this.buttonStyle="secondary"),this.validateIcon()}updateIcon(){this.icon=i(this.icon)}validateIcon(){switch(this.tempButtonType){case"icononly":case"navigational":this.icon||console.error("wm-button should have a valid 'icon' property when button-type is set to 'icononly' or 'navigational'."),this.tooltip||console.error("wm-button should have a valid 'tooltip' property when button-type is set to 'icononly' or 'navigational'.");break;case"pairpositive":this.icon="f12c";break;case"pairnegative":this.icon="f739"}}handleKeydown(t){switch(t.key){case"Enter":t.preventDefault(),this.isDisabled||this.el.click()}}componentWillLoad(){this.buttonStyle&&console.warn("wm-button: button-style has been deprecated as of v3.1.0. Please use button-type instead."),this.validateType(this.tempButtonType),this.el.focus=function(){this.disabled||(this.shadowRoot.querySelector("button").focus(),requestAnimationFrame((()=>{this.tooltipVisible=!1})))},this.icon&&(this.icon=this.icon=i(this.icon))}componentDidLoad(){document.body.classList.contains("wmcl-user-is-tabbing")&&this.toggleTabbingOn(),this.ariaPopup=!!this.el.getAttribute("aria-haspopup"),this.btnPos.new=this.buttonEl.getBoundingClientRect()}showTooltip(){if(this.hasTooltip){this.tooltipEl.textContent=this.isTruncated?this.el.textContent:this.tooltip;const t=r(this.tooltipPosition,this.buttonEl,this.tooltipEl);this.btnPos.old={};const o=this.tooltipEl.getBoundingClientRect();this.tooltipEl.style.transitionDelay="500ms",this.tooltipEl.style.opacity="1",setTimeout((()=>{this.tooltipVisible=!0,this.positionTooltip(t,o)}),50)}}positionTooltip(t,o){if(this.tooltipVisible&&window.requestAnimationFrame((()=>this.positionTooltip(t,o))),this.btnPos.new=this.buttonEl.getBoundingClientRect(),this.btnPos.new.top!=this.btnPos.old.top||this.btnPos.new.left!=this.btnPos.old.left){let n=this.btnPos.new.top+(this.btnPos.new.height-o.height)/2,e=this.btnPos.new.left+(this.btnPos.new.width-o.width)/2;t.includes("top")&&(n=this.btnPos.new.top-o.height-8),t.includes("bottom")&&(n=this.btnPos.new.bottom+8),t.includes("left")&&(e=this.btnPos.new.left-o.width-8),t.includes("right")&&(e=this.btnPos.new.right+8),e=Math.max(e,24),this.tooltipEl.style.setProperty("--wmTooltipTop",n+"px"),this.tooltipEl.style.setProperty("--wmTooltipLeft",e+"px"),this.btnPos.old=this.btnPos.new}}hideTooltip(){this.hasTooltip&&(this.tooltipEl.style.transitionDelay="0s",this.tooltipEl.style.opacity="0",this.tooltipVisible=!1)}showTooltipForKeyboardUsers(){this.isTabbing&&this.showTooltip()}getClasses(){let t="wm-button";return t+=this.permanentlyDelete?" -permanentlydelete":"",t+=this.tempButtonType?" -"+this.tempButtonType:" -secondary",t+=this.textWrap?"":" nowrap",t+=this.isTabbing?" user-is-tabbing":"",t+=this.isTruncated?" -truncated":"",t+="dark"===this.customBackground?" dark":"",t}getAriaLabel(){return"icononly"===this.tempButtonType||"navigational"===this.tempButtonType?this.labelForIdenticalButtons||this.tooltip:this.labelForIdenticalButtons?this.labelForIdenticalButtons:void 0}render(){return o(n,{class:this.isDisabled?"button-disabled":""},o("button",{id:this.id,class:`${this.getClasses()}`,disabled:this.isDisabled,ref:t=>this.buttonEl=t,"aria-label":this.getAriaLabel(),"aria-hasPopup":this.ariaPopup?"menu":null,onMouseEnter:()=>this.showTooltip(),onMouseLeave:()=>this.hideTooltip(),onFocus:()=>this.showTooltipForKeyboardUsers(),onBlur:()=>this.hideTooltip(),onClick:()=>this.hideTooltip()},this.icon&&o("span",{class:"mdi",style:this.iconSize?{fontSize:this.iconSize}:{}},String.fromCodePoint(parseInt(`0x${this.icon}`))),o("span",{class:"button-text"},o("slot",null))))}get el(){return e(this)}static get watchers(){return{buttonType:["validateType"],buttonStyle:["validateDeprecatedType"],icon:["updateIcon"]}}};b.style=':host .wm-button,wm-button .wm-button{-ms-transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1), border 500ms cubic-bezier(0.4, 0, 0.2, 1);-webkit-transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1), border 500ms cubic-bezier(0.4, 0, 0.2, 1);-moz-transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1), border 500ms cubic-bezier(0.4, 0, 0.2, 1);transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1), border 500ms cubic-bezier(0.4, 0, 0.2, 1);-webkit-border-radius:5px;-moz-border-radius:5px;-ms-border-radius:5px;border-radius:5px;width:inherit;border:2px solid #575195;color:#575195;font-family:inherit;font-size:0.75rem;font-weight:700;height:2.75rem;padding:0 1.3333333333em;cursor:pointer;position:relative;background:#fff;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;text-decoration:none;text-transform:uppercase;letter-spacing:0.01875rem;overflow-wrap:break-word;word-wrap:break-word;word-break:break-word;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}@media screen and (min-width: 48rem){:host .wm-button,wm-button .wm-button{height:3.3333333333em}}:host .wm-button.nowrap,wm-button .wm-button.nowrap{display:inline-block;width:100%;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}:host .wm-button:focus,wm-button .wm-button:focus{outline:none;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}:host .wm-button::-moz-focus-inner,wm-button .wm-button::-moz-focus-inner{border:0;outline:none}:host .wm-button.user-is-tabbing:focus:not(:disabled):not(.disabled) :host .wm-button.-textonly .button-text,wm-button .wm-button.user-is-tabbing:focus:not(:disabled):not(.disabled) :host .wm-button.-textonly .button-text,:host .wm-button.user-is-tabbing:focus:not(:disabled):not(.disabled) wm-button .wm-button.-textonly .button-text,wm-button .wm-button.user-is-tabbing:focus:not(:disabled):not(.disabled) wm-button .wm-button.-textonly .button-text{background:-webkit-gradient(linear, left top, right top, color-stop(66%, #3862e9), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #3862e9 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1em;border-radius:0;line-height:normal}:host .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled),wm-button .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled){-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}:host .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark),wm-button .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark){-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}:host .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark)::-moz-focus-inner,wm-button .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark)::-moz-focus-inner{border:0}:host .wm-button.dark:not(.-textonly):not(:disabled):not(.disabled),wm-button .wm-button.dark:not(.-textonly):not(:disabled):not(.disabled){background:transparent;border:2px solid #fff;color:#fff}:host .wm-button.dark:not(.-textonly):not(:disabled):not(.disabled):hover,wm-button .wm-button.dark:not(.-textonly):not(:disabled):not(.disabled):hover{color:#575195;background:#e6e6e6;border:2px solid #e6e6e6}:host .wm-button.dark.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled).dark,wm-button .wm-button.dark.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled).dark{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #c6b4e3;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #c6b4e3;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #c6b4e3;outline:none}:host .wm-button:active:not(:disabled):not(.disabled):not(.-textonly):not(.-actionbutton):not(.displayedoption),wm-button .wm-button:active:not(:disabled):not(.disabled):not(.-textonly):not(.-actionbutton):not(.displayedoption){-ms-transform:scale(0.9, 0.9);-webkit-transform:scale(0.9, 0.9);-moz-transform:scale(0.9, 0.9);transform:scale(0.9, 0.9)}:host .wm-button .mdi,wm-button .wm-button .mdi{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}:host .wm-button:not(.-icononly):not(.-navigational) .mdi,wm-button .wm-button:not(.-icononly):not(.-navigational) .mdi{margin-right:0.3125rem}:host .wm-button[dir=RTL] :not(.-icononly) .mdi,wm-button .wm-button[dir=RTL] :not(.-icononly) .mdi{margin-left:0.3125rem;margin-right:0}:host .wm-button.-primary:not(.-textonly),wm-button .wm-button.-primary:not(.-textonly){background:#575195;color:#fff}:host .wm-button.-primary:not(.-textonly):not(:focus),wm-button .wm-button.-primary:not(.-textonly):not(:focus){-webkit-box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);-moz-box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2)}:host .wm-button.-primary:not(.-textonly):hover:not(:disabled):not(.disabled),wm-button .wm-button.-primary:not(.-textonly):hover:not(:disabled):not(.disabled){background:#464177}:host .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled),wm-button .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled){color:#575195;background:#fff;border:2px solid #fff}:host .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled):hover,wm-button .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled):hover{color:#575195;background:#e6e6e6;border:2px solid #e6e6e6}:host .wm-button.-secondary:hover:not(:disabled):not(.disabled),wm-button .wm-button.-secondary:hover:not(:disabled):not(.disabled),:host .wm-button.-icononly:hover:not(:disabled):not(.disabled),wm-button .wm-button.-icononly:hover:not(:disabled):not(.disabled){background:#464177;color:#fff}:host .wm-button.-textonly,wm-button .wm-button.-textonly{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;display:inline-block;letter-spacing:0;text-transform:none;text-align:initial;font-size:0.875rem;border:none;background:transparent;padding-left:0;padding-right:0;height:auto;border-radius:0;line-height:1}:host .wm-button.-textonly+.-textonly,wm-button .wm-button.-textonly+.-textonly{margin-left:0.3125rem}:host .wm-button.-textonly:focus,wm-button .wm-button.-textonly:focus{outline:none}:host .wm-button.-textonly::-moz-focus-inner,wm-button .wm-button.-textonly::-moz-focus-inner{border:0;outline:none}:host .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled) .button-text,wm-button .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled) .button-text{background:-webkit-gradient(linear, left top, right top, color-stop(66%, #3862e9), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #3862e9 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1em;border-radius:0;line-height:normal}:host .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled).dark .button-text,wm-button .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled).dark .button-text{background:-webkit-gradient(linear, left top, right top, color-stop(66%, #fff), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #fff 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1em;border-radius:0;line-height:normal}:host .wm-button.-textonly.small,wm-button .wm-button.-textonly.small{font-size:0.625rem}:host .wm-button.-textonly:hover:not(:disabled):not(.disabled):not(.-permanentlydelete),wm-button .wm-button.-textonly:hover:not(:disabled):not(.disabled):not(.-permanentlydelete){text-decoration:underline}:host .wm-button.-textonly.-permanentlydelete,wm-button .wm-button.-textonly.-permanentlydelete{color:#c0392b}:host .wm-button.-textonly.-permanentlydelete:hover:not(:disabled):not(.disabled):not(.dark),wm-button .wm-button.-textonly.-permanentlydelete:hover:not(:disabled):not(.disabled):not(.dark){text-decoration:underline;color:#c0392b !important}:host .wm-button.-textonly.dark,wm-button .wm-button.-textonly.dark{color:#fff}:host .wm-button.-textonly.dark:hover:not(:disabled):not(.disabled),wm-button .wm-button.-textonly.dark:hover:not(:disabled):not(.disabled){text-decoration:underline;color:#fff !important}:host .wm-button.-icononly,wm-button .wm-button.-icononly,:host .wm-button.-navigational,wm-button .wm-button.-navigational{-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;border-radius:50%;font-size:1rem;padding:0;height:auto;line-height:1;min-width:2.75rem;min-height:2.75rem;text-align:center;letter-spacing:normal}:host .wm-button.-icononly:not(:focus),wm-button .wm-button.-icononly:not(:focus),:host .wm-button.-navigational:not(:focus),wm-button .wm-button.-navigational:not(:focus){-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}@media screen and (min-width: 48rem){:host .wm-button.-icononly,wm-button .wm-button.-icononly,:host .wm-button.-navigational,wm-button .wm-button.-navigational{min-width:2.5rem;min-height:2.5rem}}:host .wm-button.-icononly,wm-button .wm-button.-icononly{border-width:1px !important}:host .wm-button.-icononly:before,wm-button .wm-button.-icononly:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}:host .wm-button.-navigational,wm-button .wm-button.-navigational{border:none !important;background-color:transparent}:host .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled),wm-button .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled){color:#575195}:host .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled):hover,wm-button .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled):hover,:host .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled).selected,wm-button .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled).selected{background-color:#d7d6d9}:host .wm-button.-navigational:before,wm-button .wm-button.-navigational:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}:host .wm-button.-permanentlydelete:not(.-textonly),wm-button .wm-button.-permanentlydelete:not(.-textonly){background:#c0392b;border-color:#c0392b;color:#fff}:host .wm-button.-permanentlydelete:not(.-textonly):hover:not(:disabled):not(.disabled):not(.dark),wm-button .wm-button.-permanentlydelete:not(.-textonly):hover:not(:disabled):not(.disabled):not(.dark){background:#9a2e22;border-color:#9a2e22}:host .wm-button.-pairnegative,wm-button .wm-button.-pairnegative{background:#cc4c3e;border-color:#cc4c3e;color:#fff}:host .wm-button.-pairnegative:hover:not(:disabled):not(.disabled),wm-button .wm-button.-pairnegative:hover:not(:disabled):not(.disabled){background:#a33d32;border-color:#a33d32}:host .wm-button.-pairpositive,wm-button .wm-button.-pairpositive{background:#15868d;border-color:#15868d;color:#fff}:host .wm-button.-pairpositive:hover:not(:disabled):not(.disabled),wm-button .wm-button.-pairpositive:hover:not(:disabled):not(.disabled){background:#116b71;border-color:#116b71}:host .wm-button.-selectoronly,wm-button .wm-button.-selectoronly{-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;display:block;background:transparent;border:1px solid #575195;border-radius:3px 3px 3px 3px;height:2.75rem;min-width:11.4375rem;padding:0 1.875rem 0 0.9375rem;line-height:normal;font-family:inherit;color:#575195;font-weight:500;font-size:0.875rem;text-transform:none;letter-spacing:0.01875rem;text-align:left}@media screen and (min-width: 48rem){:host .wm-button.-selectoronly,wm-button .wm-button.-selectoronly{height:2.5rem}}:host .wm-button.-selectoronly:before,wm-button .wm-button.-selectoronly:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f140";position:absolute;right:0.5625rem;top:50%;-webkit-transform:translateY(-50%);transform:translateY(-50%);pointer-events:none}:host .wm-button.-selectoronly:hover:not(:disabled):not(.disabled),wm-button .wm-button.-selectoronly:hover:not(:disabled):not(.disabled){background:transparent;text-decoration:none}:host .wm-button.-selectoronly:active,wm-button .wm-button.-selectoronly:active{-ms-transform:scale(1, 1) !important;-webkit-transform:scale(1, 1) !important;transform:scale(1, 1) !important}:host .wm-button.-selectoronly::-moz-focus-inner,wm-button .wm-button.-selectoronly::-moz-focus-inner{border:0}:host .wm-button.-selectoronly .overflowcontrol,wm-button .wm-button.-selectoronly .overflowcontrol{display:block;white-space:nowrap;text-overflow:ellipsis;overflow:visible}:host .wm-button:disabled,wm-button .wm-button:disabled,:host .wm-button.disabled,wm-button .wm-button.disabled{background:inherit;border-color:#737373;color:#737373;cursor:default;pointer-events:none}:host .wm-button:disabled.-primary,wm-button .wm-button:disabled.-primary,:host .wm-button:disabled.-permanentlydelete,wm-button .wm-button:disabled.-permanentlydelete,:host .wm-button:disabled.-pairnegative,wm-button .wm-button:disabled.-pairnegative,:host .wm-button:disabled.-pairpositive,wm-button .wm-button:disabled.-pairpositive,:host .wm-button.disabled.-primary,wm-button .wm-button.disabled.-primary,:host .wm-button.disabled.-permanentlydelete,wm-button .wm-button.disabled.-permanentlydelete,:host .wm-button.disabled.-pairnegative,wm-button .wm-button.disabled.-pairnegative,:host .wm-button.disabled.-pairpositive,wm-button .wm-button.disabled.-pairpositive{background:#737373;color:#fff;border-color:#737373}:host .wm-button:disabled.-secondary,wm-button .wm-button:disabled.-secondary,:host .wm-button.disabled.-secondary,wm-button .wm-button.disabled.-secondary{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}:host .wm-button:disabled.-selectoronly,wm-button .wm-button:disabled.-selectoronly,:host .wm-button.disabled.-selectoronly,wm-button .wm-button.disabled.-selectoronly{color:#737373}:host .wm-button:disabled.-textonly,wm-button .wm-button:disabled.-textonly,:host .wm-button.disabled.-textonly,wm-button .wm-button.disabled.-textonly{color:#6b6b6b;background:transparent}:host .wm-button:disabled.dark.-secondary:not(.-permanentlydelete),wm-button .wm-button:disabled.dark.-secondary:not(.-permanentlydelete),:host .wm-button:disabled.dark.-textonly,wm-button .wm-button:disabled.dark.-textonly,:host .wm-button:disabled.dark.-navigational,wm-button .wm-button:disabled.dark.-navigational,:host .wm-button:disabled.dark.-icononly,wm-button .wm-button:disabled.dark.-icononly,:host .wm-button.disabled.dark.-secondary:not(.-permanentlydelete),wm-button .wm-button.disabled.dark.-secondary:not(.-permanentlydelete),:host .wm-button.disabled.dark.-textonly,wm-button .wm-button.disabled.dark.-textonly,:host .wm-button.disabled.dark.-navigational,wm-button .wm-button.disabled.dark.-navigational,:host .wm-button.disabled.dark.-icononly,wm-button .wm-button.disabled.dark.-icononly{color:#b5b5b5;border-color:#b5b5b5}:host .wm-button:disabled.dark.-primary,wm-button .wm-button:disabled.dark.-primary,:host .wm-button:disabled.dark.-permanentlydelete:not(.-textonly),wm-button .wm-button:disabled.dark.-permanentlydelete:not(.-textonly),:host .wm-button.disabled.dark.-primary,wm-button .wm-button.disabled.dark.-primary,:host .wm-button.disabled.dark.-permanentlydelete:not(.-textonly),wm-button .wm-button.disabled.dark.-permanentlydelete:not(.-textonly){background:#a6a6a6;border-color:#a6a6a6;color:#353b48}:host a.wm-button,wm-button a.wm-button,:host label.wm-button,wm-button label.wm-button{height:auto;padding-top:0.75rem;padding-bottom:0.75rem}:host([disabled]),:host(.button-disabled){pointer-events:none}:host([disabled=false]){pointer-events:initial}:host,wm-button{display:inline-block;width:-webkit-fit-content;width:-moz-fit-content;width:fit-content;position:relative;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}:host .sr-only,wm-button .sr-only{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}';export{b as wm_button}
@@ -0,0 +1 @@
1
+ import{r as t,c as e,f as o,h as n,H as i,g as r}from"./p-b3c71506.js";import{g as a,p as s,a as l,d}from"./p-fd8070fb.js";import{g as b,i as m,p as u}from"./p-de3367ee.js";let w=class{constructor(o){t(this,o),this.wmNetworkUploaderFilesChanged=e(this,"wmNetworkUploaderFilesChanged",7),this.isTabbing=!1,this.fileList=[],this.inProgressList=[],this.errorList=[],this.snackbar=[],this.fileTypes="pdf txt log xml doc docx xls xlsx ppt pptx gif jpg jpeg png csv",this.maxSize=100,this.sortBy="date",this.inputId=b()}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}handleUploadProgress(t){if(this.inProgressList.map((e=>{e.name===t.detail.file_name&&(e.progress=t.detail.progress,o(this.el))})),100===t.detail.progress&&(this.numFilesInProgress-=1),!this.srProgress&&this.numFilesInProgress){const t=this.numFilesInProgress;this.srProgress=setInterval((()=>{const e=this.inProgressList.reduce(((t,e)=>e.progress?t+e.progress:t),0);this.liveRegion&&(this.liveRegion.innerHTML=m.formatMessage({id:"uploader.uploadProgress",defaultMessage:"Upload progress: {percentage}%"},{percentage:Math.floor(e/t)}))}),5e3)}}handleFinishedSnack(t){this.snackbar=this.snackbar.filter((e=>e.id!==t.detail.id))}setMaxSize(){this.maxSize=this.maxSize>100?100:this.maxSize}uploadNotifications(t,e){if(e>0&&0===t){setTimeout((()=>{this.notif=null}),2e4);const t=m.formatMessage({id:"uploader.finishedUploading",defaultMessage:"Finished uploading"});this.notif={id:5,message:t},this.liveRegion&&(this.liveRegion.innerHTML=t),this.numFilesInProgress=null,clearInterval(this.srProgress),o(this.el)}else if(t>0&&t!=e){const e=m.formatMessage({id:"uploader.filesUploading",defaultMessage:"{num, plural, one {1 file uploading} other {# files uploading}}"},{num:t});this.notif={id:6,message:e},this.liveRegion&&(this.liveRegion.innerHTML=e),o(this.el)}}emitFileListEvent(){this.wmNetworkUploaderFilesChanged.emit(this.fileList)}formatDate(t,e,o){const n=Date.parse(t);if(!e.match(/^[a-zA-Z]*(-[a-zA-Z0-9]*)*$/g))return t;try{Intl.getCanonicalLocales(e)}catch(t){e="en-us"}if(n){const t=new Date(n);return`${t.getFullYear()}/${("0"+(t.getMonth()+1)).substr(-2)}/${("0"+t.getDate()).substr(-2)} ${t.toLocaleTimeString([e,"en-us"],{timeZone:o,hour:"numeric",minute:"numeric"})}`}return t}isValidSize(t){return t/1024/1024<=this.maxSize}isDuplicate(t){return this.fileList.find((e=>e.file_name===t))}isEmpty(){return!this.fileList.length&&!this.inProgressList.length&&!this.errorList.length}get isDisabled(){const t=!!this.maxFiles&&this.fileList.length>=this.maxFiles;if(this.notif)1===this.notif.id&&(t||(this.notif=null));else if(t){const t=m.formatMessage({id:"uploader.fileUploadLimit",defaultMessage:"Upload unsuccessful because file selection would exceed the maximum number of files",description:"Message displayed when trying to upload too many files"});this.notif={id:1,message:t},this.liveRegion&&(this.liveRegion.innerHTML=t)}else this.notif=null;return t||this.numFilesInProgress>0}purgeProgressList(t){this.inProgressList=this.inProgressList.filter((e=>100!==e.progress&&e.name!==t.file_name))}getExistingFiles(){a(this.getPath).then((t=>{t.map((t=>this.purgeProgressList(t))),"name"===this.sortBy&&t.sort(((t,e)=>t.file_name.localeCompare(e.file_name))),this.fileList=t})).catch((t=>{console.error(t)}))}clearErrors(){this.errorList=[],this.notif=null}handleFiles(t){const e=Array.from(t.target.files),n=this.fileTypes.split(" ").join(", ");if(this.maxFiles&&this.fileList.length+e.length>this.maxFiles){const t=m.formatMessage({id:"uploader.fileUploadExceeded",defaultMessage:"The number of selected files exceeds the limit."});this.notif={id:2,message:t},this.liveRegion&&(this.liveRegion.innerHTML=t)}else e&&e.map((t=>{if(u(t,this.fileTypes))if(this.isValidSize(t.size))if(this.isDuplicate(t.name)){const e={file_name:t.name,message:m.formatMessage({id:"uploader.duplicateName",defaultMessage:"A file with this name already exists."})};this.errorList.push(e)}else this.inProgressList.push(t);else{const e={file_name:t.name,message:m.formatMessage({id:"uploader.fileTooLarge",defaultMessage:"The selected file is too large. Maximum file size is {size}Mb"},{size:this.maxSize})};this.errorList.push(e)}else{const e={file_name:t.name,message:m.formatMessage({id:"uploader.invalidFileType",defaultMessage:"The file type is invalid. Accepted types: {validTypes}"},{validTypes:n})};this.errorList.push(e)}o(this.el)})),this.inProgressList.length>0&&(this.numFilesInProgress=this.inProgressList.length,this.inProgressList.map(((t,e)=>{this.uploadFile(t,e)})));t.target.value=""}uploadFile(t,e){a(this.requestUploadPath+e.toString()).then((async e=>{const o=JSON.parse(this.associatedData),n=Object.assign(Object.assign({},o),{file_name:t.name,mime_type:t.type,file_path:e.path,document_uuid:e.guid});await s(e.url,t,(e=>{const o=new CustomEvent("wmUploadProgress",{detail:{file_name:t.name,progress:e.lengthComputable&&0!==e.total?e.loaded/e.total*100:0}});this.el.dispatchEvent(o)})),await l(this.uploadPath,n),this.getExistingFiles()})).catch((t=>{this.numFilesInProgress=null,this.inProgressList=[],this.notif={id:3,message:m.formatMessage({id:"global.genericError",defaultMessage:"An error occurred. Please try again."})},console.error(t)}))}downloadFile(t,e){this.clearErrors(),l(this.requestDownloadPath,{file_path:e,file_uuid:t}).then((t=>{window.location.assign(t.url)})).catch((t=>{console.error(t)}))}deleteFile(t){this.clearErrors(),this.snackbar.push({message:m.formatMessage({id:"uploader.fileDeleted",defaultMessage:"{fileName} was deleted."},{fileName:t.file_name}),id:t.uuid,link:""}),this.fileList=this.fileList.filter((e=>e.uuid!==t.uuid)),d(`${this.deletePath}/${t.uuid}`).catch((e=>{this.notif={id:4,message:m.formatMessage({id:"uploader.fileNotDeleted",defaultMessage:"{fileName} could not be deleted."},{fileName:t.file_name})},this.getExistingFiles(),console.error(e)}))}componentWillLoad(){if(!this.getPath)throw new Error("wm-network-uploader: get-path is a required prop");if(!this.requestUploadPath)throw new Error("wm-network-uploader: request-upload-path is a required prop");if(!this.uploadPath)throw new Error("wm-network-uploader: upload-path is a required prop");if(!this.requestDownloadPath)throw new Error("wm-network-uploader: request-download-path is a required prop");if(!this.deletePath)throw new Error("wm-network-uploader: delete-path is a required prop");if(!this.buttonText)throw new Error("wm-network-uploader: button-text is a required prop");if(!this.emptyStateText)throw new Error("wm-network-uploader: empty-state-text is a required prop");if(!this.associatedData)throw new Error("wm-network-uploader: associated-data is a required prop");this.setMaxSize(),this.clearErrors()}componentDidLoad(){this.getExistingFiles(),document.body.classList.contains("wmcl-user-is-tabbing")&&this.toggleTabbingOn()}uploadButtonOnClick(t){if(this.isDisabled){if(t.preventDefault(),this.liveRegion){const t=!!this.maxFiles&&this.fileList.length>=this.maxFiles;let e="";this.numFilesInProgress>0?e=m.formatMessage({id:"uploader.waitToUpload",defaultMessage:"Please wait for current upload to complete before uploading new files.",description:"Message for screen reader users"}):t&&(e=m.formatMessage({id:"uploader.fileUploadLimit",defaultMessage:"Upload unsuccessful because file selection would exceed the maximum number of files",description:"Message displayed when trying to upload too many files"})),e&&(this.liveRegion.innerHTML="",new Promise((t=>{setTimeout((()=>{t("")}),500)})).then((()=>this.liveRegion.innerHTML=e)))}}else this.clearErrors()}renderUploadSvg(){return n("svg",{class:"upload-file",width:"91",height:"84",viewBox:"0 0 91 84"},n("path",{transform:"rotate(-180.000000) translate(-452, -255.5)",fill:"#eae8ec",d:"M361,249.681818 L361,197.318182 C361,194.118182 365.555061,191.5 371.122358,191.5 L391.316463,191.5 L391.286495,200.562515 L369.871211,200.600292 L369.885404,200.622146 L369.886423,246.655947 L443.657038,246.840767 L443.657038,200.622146 L421.683537,200.622146 L421.683537,191.5 L441.978865,191.5 C447.546162,191.5 452,194.118182 452,197.318182 L452,249.681818 C452,252.881818 447.546162,255.5 441.978865,255.5 L371.122358,255.5 C365.504449,255.5 361,252.881818 361,249.681818 Z M391.5,207 L406,221 L420.5,207 L409.625,207 L409.625,172 L402.375,172 L402.375,207 L391.5,207 Z"}))}renderIcon(){return this.icon&&n("span",{class:"mdi "+(this.icon&&"f066"===this.icon?"rotate":"")},String.fromCodePoint(parseInt(`0x${this.icon}`)))}renderNotif(){return this.notif?n("span",{class:"notif"},this.notif.message):""}renderUploadButton(t){return n("div",{class:"notif-wrapper"},n("input",{name:this.inputId,id:this.inputId,class:"sr-only",type:"file",multiple:!0,onClick:t=>this.uploadButtonOnClick(t),onChange:t=>this.handleFiles(t)}),n("label",{htmlFor:this.inputId,class:`wm-button ${t}${this.isTabbing?" user-is-tabbing":""}`},this.renderIcon(),this.buttonText),this.renderNotif())}renderWithItems(){return n("div",null,n("div",{class:"header"},n("div",{class:"descr"},n("slot",null)),this.renderUploadButton(this.isDisabled?"disabled":"")),this.renderErrorList(),this.renderInProgressList(),this.renderFileList())}renderEmptyState(){return n("div",null,n("div",{class:"header"},n("div",{class:"descr"},n("slot",null))),n("div",{class:"empty-block"},this.renderUploadSvg(),n("div",{class:"empty-message"},this.emptyStateText),this.renderUploadButton("-primary empty-button")))}renderErrorList(){if(this.errorList.length){if(this.liveRegion){let t=this.errorList.reduce((function(t,e){return t+`${e.file_name}: ${e.message} `}),"");this.liveRegion.innerHTML=t}return n("ul",{class:"error-list"},this.errorList.map((t=>n("li",null,n("div",{class:"file --error"},n("div",{class:"file-info"},n("span",{class:"filename"},t.file_name))),n("div",{class:"error-message"},t.message)))))}}renderInProgressList(){return n("ul",{class:"inprogress-list"},this.inProgressList.map((t=>n("li",null,n("div",{class:"file --progress"},n("div",{class:"progress",style:{background:`linear-gradient(to right, rgba(67, 126, 142, 1) ${t.progress}%, transparent ${t.progress}%)`}}),n("div",{class:"file-info"},n("span",{class:"filename"},t.name," ",n("span",{class:"sr-only"},"uploading"))))))))}renderFile(t){return n("li",null,n("div",{class:"file --saved"},n("div",{class:"file-info"},n("span",{class:"filename"},t.file_name),n("span",{class:"filedate"},this.formatDate(t.updated_at,m.locale,Intl.DateTimeFormat().resolvedOptions().timeZone))),n("div",{class:"file-controls"},n("wm-button",{class:"download-button","button-type":"icononly",tooltip:"download","label-for-identical-buttons":`download ${t.file_name}`,icon:"f1da",onClick:()=>this.downloadFile(t.uuid,t.file_path)}),n("wm-button",{class:"delete-button","button-type":"icononly",tooltip:"remove","label-for-identical-buttons":`remove ${t.file_name}`,icon:"f1c0",onClick:()=>this.deleteFile(t)}))))}renderFileList(){return n("ul",{class:"file-list"},this.fileList.map((t=>this.renderFile(t))))}render(){return n(i,null,this.isEmpty()?this.renderEmptyState():this.renderWithItems(),n("wm-snackbar",{notifications:JSON.stringify(this.snackbar)}),n("div",{ref:t=>this.liveRegion=t,class:"live-region sr-only","aria-live":"assertive","aria-atomic":"true"}))}get el(){return r(this)}static get watchers(){return{maxSize:["setMaxSize"],numFilesInProgress:["uploadNotifications"],fileList:["emitFileListEvent"]}}};w.style=':host .wm-button,wm-network-uploader .wm-button{-ms-transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1), border 500ms cubic-bezier(0.4, 0, 0.2, 1);-webkit-transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1), border 500ms cubic-bezier(0.4, 0, 0.2, 1);-moz-transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1), border 500ms cubic-bezier(0.4, 0, 0.2, 1);transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1), border 500ms cubic-bezier(0.4, 0, 0.2, 1);-webkit-border-radius:5px;-moz-border-radius:5px;-ms-border-radius:5px;border-radius:5px;width:inherit;border:2px solid #575195;color:#575195;font-family:inherit;font-size:0.75rem;font-weight:700;height:2.75rem;padding:0 1.3333333333em;cursor:pointer;position:relative;background:#fff;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;text-decoration:none;text-transform:uppercase;letter-spacing:0.01875rem;overflow-wrap:break-word;word-wrap:break-word;word-break:break-word;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}@media screen and (min-width: 48rem){:host .wm-button,wm-network-uploader .wm-button{height:3.3333333333em}}:host .wm-button.nowrap,wm-network-uploader .wm-button.nowrap{display:inline-block;width:100%;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}:host .wm-button:focus,wm-network-uploader .wm-button:focus{outline:none;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}:host .wm-button::-moz-focus-inner,wm-network-uploader .wm-button::-moz-focus-inner{border:0;outline:none}:host .wm-button.user-is-tabbing:focus:not(:disabled):not(.disabled) :host .wm-button.-textonly .button-text,wm-network-uploader .wm-button.user-is-tabbing:focus:not(:disabled):not(.disabled) :host .wm-button.-textonly .button-text,:host .wm-button.user-is-tabbing:focus:not(:disabled):not(.disabled) wm-network-uploader .wm-button.-textonly .button-text,wm-network-uploader .wm-button.user-is-tabbing:focus:not(:disabled):not(.disabled) wm-network-uploader .wm-button.-textonly .button-text{background:-webkit-gradient(linear, left top, right top, color-stop(66%, #3862e9), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #3862e9 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1em;border-radius:0;line-height:normal}:host .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled),wm-network-uploader .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled){-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}:host .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark),wm-network-uploader .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark){-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}:host .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark)::-moz-focus-inner,wm-network-uploader .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark)::-moz-focus-inner{border:0}:host .wm-button.dark:not(.-textonly):not(:disabled):not(.disabled),wm-network-uploader .wm-button.dark:not(.-textonly):not(:disabled):not(.disabled){background:transparent;border:2px solid #fff;color:#fff}:host .wm-button.dark:not(.-textonly):not(:disabled):not(.disabled):hover,wm-network-uploader .wm-button.dark:not(.-textonly):not(:disabled):not(.disabled):hover{color:#575195;background:#e6e6e6;border:2px solid #e6e6e6}:host .wm-button.dark.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled).dark,wm-network-uploader .wm-button.dark.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled).dark{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #c6b4e3;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #c6b4e3;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #c6b4e3;outline:none}:host .wm-button:active:not(:disabled):not(.disabled):not(.-textonly):not(.-actionbutton):not(.displayedoption),wm-network-uploader .wm-button:active:not(:disabled):not(.disabled):not(.-textonly):not(.-actionbutton):not(.displayedoption){-ms-transform:scale(0.9, 0.9);-webkit-transform:scale(0.9, 0.9);-moz-transform:scale(0.9, 0.9);transform:scale(0.9, 0.9)}:host .wm-button .mdi,wm-network-uploader .wm-button .mdi{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}:host .wm-button:not(.-icononly):not(.-navigational) .mdi,wm-network-uploader .wm-button:not(.-icononly):not(.-navigational) .mdi{margin-right:0.3125rem}:host .wm-button[dir=RTL] :not(.-icononly) .mdi,wm-network-uploader .wm-button[dir=RTL] :not(.-icononly) .mdi{margin-left:0.3125rem;margin-right:0}:host .wm-button.-primary:not(.-textonly),wm-network-uploader .wm-button.-primary:not(.-textonly){background:#575195;color:#fff}:host .wm-button.-primary:not(.-textonly):not(:focus),wm-network-uploader .wm-button.-primary:not(.-textonly):not(:focus){-webkit-box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);-moz-box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2)}:host .wm-button.-primary:not(.-textonly):hover:not(:disabled):not(.disabled),wm-network-uploader .wm-button.-primary:not(.-textonly):hover:not(:disabled):not(.disabled){background:#464177}:host .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled),wm-network-uploader .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled){color:#575195;background:#fff;border:2px solid #fff}:host .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled):hover,wm-network-uploader .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled):hover{color:#575195;background:#e6e6e6;border:2px solid #e6e6e6}:host .wm-button.-secondary:hover:not(:disabled):not(.disabled),wm-network-uploader .wm-button.-secondary:hover:not(:disabled):not(.disabled),:host .wm-button.-icononly:hover:not(:disabled):not(.disabled),wm-network-uploader .wm-button.-icononly:hover:not(:disabled):not(.disabled){background:#464177;color:#fff}:host .wm-button.-textonly,wm-network-uploader .wm-button.-textonly{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;display:inline-block;letter-spacing:0;text-transform:none;text-align:initial;font-size:0.875rem;border:none;background:transparent;padding-left:0;padding-right:0;height:auto;border-radius:0;line-height:1}:host .wm-button.-textonly+.-textonly,wm-network-uploader .wm-button.-textonly+.-textonly{margin-left:0.3125rem}:host .wm-button.-textonly:focus,wm-network-uploader .wm-button.-textonly:focus{outline:none}:host .wm-button.-textonly::-moz-focus-inner,wm-network-uploader .wm-button.-textonly::-moz-focus-inner{border:0;outline:none}:host .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled) .button-text,wm-network-uploader .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled) .button-text{background:-webkit-gradient(linear, left top, right top, color-stop(66%, #3862e9), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #3862e9 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1em;border-radius:0;line-height:normal}:host .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled).dark .button-text,wm-network-uploader .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled).dark .button-text{background:-webkit-gradient(linear, left top, right top, color-stop(66%, #fff), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #fff 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1em;border-radius:0;line-height:normal}:host .wm-button.-textonly.small,wm-network-uploader .wm-button.-textonly.small{font-size:0.625rem}:host .wm-button.-textonly:hover:not(:disabled):not(.disabled):not(.-permanentlydelete),wm-network-uploader .wm-button.-textonly:hover:not(:disabled):not(.disabled):not(.-permanentlydelete){text-decoration:underline}:host .wm-button.-textonly.-permanentlydelete,wm-network-uploader .wm-button.-textonly.-permanentlydelete{color:#c0392b}:host .wm-button.-textonly.-permanentlydelete:hover:not(:disabled):not(.disabled):not(.dark),wm-network-uploader .wm-button.-textonly.-permanentlydelete:hover:not(:disabled):not(.disabled):not(.dark){text-decoration:underline;color:#c0392b !important}:host .wm-button.-textonly.dark,wm-network-uploader .wm-button.-textonly.dark{color:#fff}:host .wm-button.-textonly.dark:hover:not(:disabled):not(.disabled),wm-network-uploader .wm-button.-textonly.dark:hover:not(:disabled):not(.disabled){text-decoration:underline;color:#fff !important}:host .wm-button.-icononly,wm-network-uploader .wm-button.-icononly,:host .wm-button.-navigational,wm-network-uploader .wm-button.-navigational{-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;border-radius:50%;font-size:1rem;padding:0;height:auto;line-height:1;min-width:2.75rem;min-height:2.75rem;text-align:center;letter-spacing:normal}:host .wm-button.-icononly:not(:focus),wm-network-uploader .wm-button.-icononly:not(:focus),:host .wm-button.-navigational:not(:focus),wm-network-uploader .wm-button.-navigational:not(:focus){-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}@media screen and (min-width: 48rem){:host .wm-button.-icononly,wm-network-uploader .wm-button.-icononly,:host .wm-button.-navigational,wm-network-uploader .wm-button.-navigational{min-width:2.5rem;min-height:2.5rem}}:host .wm-button.-icononly,wm-network-uploader .wm-button.-icononly{border-width:1px !important}:host .wm-button.-icononly:before,wm-network-uploader .wm-button.-icononly:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}:host .wm-button.-navigational,wm-network-uploader .wm-button.-navigational{border:none !important;background-color:transparent}:host .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled),wm-network-uploader .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled){color:#575195}:host .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled):hover,wm-network-uploader .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled):hover,:host .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled).selected,wm-network-uploader .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled).selected{background-color:#d7d6d9}:host .wm-button.-navigational:before,wm-network-uploader .wm-button.-navigational:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}:host .wm-button.-permanentlydelete:not(.-textonly),wm-network-uploader .wm-button.-permanentlydelete:not(.-textonly){background:#c0392b;border-color:#c0392b;color:#fff}:host .wm-button.-permanentlydelete:not(.-textonly):hover:not(:disabled):not(.disabled):not(.dark),wm-network-uploader .wm-button.-permanentlydelete:not(.-textonly):hover:not(:disabled):not(.disabled):not(.dark){background:#9a2e22;border-color:#9a2e22}:host .wm-button.-pairnegative,wm-network-uploader .wm-button.-pairnegative{background:#cc4c3e;border-color:#cc4c3e;color:#fff}:host .wm-button.-pairnegative:hover:not(:disabled):not(.disabled),wm-network-uploader .wm-button.-pairnegative:hover:not(:disabled):not(.disabled){background:#a33d32;border-color:#a33d32}:host .wm-button.-pairpositive,wm-network-uploader .wm-button.-pairpositive{background:#15868d;border-color:#15868d;color:#fff}:host .wm-button.-pairpositive:hover:not(:disabled):not(.disabled),wm-network-uploader .wm-button.-pairpositive:hover:not(:disabled):not(.disabled){background:#116b71;border-color:#116b71}:host .wm-button.-selectoronly,wm-network-uploader .wm-button.-selectoronly{-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;display:block;background:transparent;border:1px solid #575195;border-radius:3px 3px 3px 3px;height:2.75rem;min-width:11.4375rem;padding:0 1.875rem 0 0.9375rem;line-height:normal;font-family:inherit;color:#575195;font-weight:500;font-size:0.875rem;text-transform:none;letter-spacing:0.01875rem;text-align:left}@media screen and (min-width: 48rem){:host .wm-button.-selectoronly,wm-network-uploader .wm-button.-selectoronly{height:2.5rem}}:host .wm-button.-selectoronly:before,wm-network-uploader .wm-button.-selectoronly:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f140";position:absolute;right:0.5625rem;top:50%;-webkit-transform:translateY(-50%);transform:translateY(-50%);pointer-events:none}:host .wm-button.-selectoronly:hover:not(:disabled):not(.disabled),wm-network-uploader .wm-button.-selectoronly:hover:not(:disabled):not(.disabled){background:transparent;text-decoration:none}:host .wm-button.-selectoronly:active,wm-network-uploader .wm-button.-selectoronly:active{-ms-transform:scale(1, 1) !important;-webkit-transform:scale(1, 1) !important;transform:scale(1, 1) !important}:host .wm-button.-selectoronly::-moz-focus-inner,wm-network-uploader .wm-button.-selectoronly::-moz-focus-inner{border:0}:host .wm-button.-selectoronly .overflowcontrol,wm-network-uploader .wm-button.-selectoronly .overflowcontrol{display:block;white-space:nowrap;text-overflow:ellipsis;overflow:visible}:host .wm-button:disabled,wm-network-uploader .wm-button:disabled,:host .wm-button.disabled,wm-network-uploader .wm-button.disabled{background:inherit;border-color:#737373;color:#737373;cursor:default;pointer-events:none}:host .wm-button:disabled.-primary,wm-network-uploader .wm-button:disabled.-primary,:host .wm-button:disabled.-permanentlydelete,wm-network-uploader .wm-button:disabled.-permanentlydelete,:host .wm-button:disabled.-pairnegative,wm-network-uploader .wm-button:disabled.-pairnegative,:host .wm-button:disabled.-pairpositive,wm-network-uploader .wm-button:disabled.-pairpositive,:host .wm-button.disabled.-primary,wm-network-uploader .wm-button.disabled.-primary,:host .wm-button.disabled.-permanentlydelete,wm-network-uploader .wm-button.disabled.-permanentlydelete,:host .wm-button.disabled.-pairnegative,wm-network-uploader .wm-button.disabled.-pairnegative,:host .wm-button.disabled.-pairpositive,wm-network-uploader .wm-button.disabled.-pairpositive{background:#737373;color:#fff;border-color:#737373}:host .wm-button:disabled.-secondary,wm-network-uploader .wm-button:disabled.-secondary,:host .wm-button.disabled.-secondary,wm-network-uploader .wm-button.disabled.-secondary{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}:host .wm-button:disabled.-selectoronly,wm-network-uploader .wm-button:disabled.-selectoronly,:host .wm-button.disabled.-selectoronly,wm-network-uploader .wm-button.disabled.-selectoronly{color:#737373}:host .wm-button:disabled.-textonly,wm-network-uploader .wm-button:disabled.-textonly,:host .wm-button.disabled.-textonly,wm-network-uploader .wm-button.disabled.-textonly{color:#6b6b6b;background:transparent}:host .wm-button:disabled.dark.-secondary:not(.-permanentlydelete),wm-network-uploader .wm-button:disabled.dark.-secondary:not(.-permanentlydelete),:host .wm-button:disabled.dark.-textonly,wm-network-uploader .wm-button:disabled.dark.-textonly,:host .wm-button:disabled.dark.-navigational,wm-network-uploader .wm-button:disabled.dark.-navigational,:host .wm-button:disabled.dark.-icononly,wm-network-uploader .wm-button:disabled.dark.-icononly,:host .wm-button.disabled.dark.-secondary:not(.-permanentlydelete),wm-network-uploader .wm-button.disabled.dark.-secondary:not(.-permanentlydelete),:host .wm-button.disabled.dark.-textonly,wm-network-uploader .wm-button.disabled.dark.-textonly,:host .wm-button.disabled.dark.-navigational,wm-network-uploader .wm-button.disabled.dark.-navigational,:host .wm-button.disabled.dark.-icononly,wm-network-uploader .wm-button.disabled.dark.-icononly{color:#b5b5b5;border-color:#b5b5b5}:host .wm-button:disabled.dark.-primary,wm-network-uploader .wm-button:disabled.dark.-primary,:host .wm-button:disabled.dark.-permanentlydelete:not(.-textonly),wm-network-uploader .wm-button:disabled.dark.-permanentlydelete:not(.-textonly),:host .wm-button.disabled.dark.-primary,wm-network-uploader .wm-button.disabled.dark.-primary,:host .wm-button.disabled.dark.-permanentlydelete:not(.-textonly),wm-network-uploader .wm-button.disabled.dark.-permanentlydelete:not(.-textonly){background:#a6a6a6;border-color:#a6a6a6;color:#353b48}:host a.wm-button,wm-network-uploader a.wm-button,:host label.wm-button,wm-network-uploader label.wm-button{height:auto;padding-top:0.75rem;padding-bottom:0.75rem}:host,wm-network-uploader{width:100%;position:relative}:host[dir=RTL] .mdi,wm-network-uploader[dir=RTL] .mdi{margin-left:0.3125rem;margin-right:0}:host input:focus+.wm-button.user-is-tabbing,wm-network-uploader input:focus+.wm-button.user-is-tabbing{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e !important;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e !important;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e !important}:host *,wm-network-uploader *{-webkit-box-sizing:border-box;box-sizing:border-box}.sr-only{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}.header{position:relative;display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-wrap:wrap;flex-wrap:wrap}.header .notif-wrapper{-ms-flex-align:end;align-items:flex-end}.notif-wrapper{display:-ms-flexbox;display:flex;-ms-flex-align:start;align-items:flex-start;height:-moz-fit-content;height:-webkit-fit-content;height:fit-content;-ms-flex-direction:column;flex-direction:column;-ms-flex-align:center;align-items:center}.notif-wrapper .notif{font-size:0.875rem;font-style:italic;margin-top:0.25rem}@media (max-width: 60.9375rem){.descr{margin-bottom:0.5rem}.notif-wrapper{margin-bottom:1rem}.header .notif-wrapper{-ms-flex-align:start;align-items:flex-start}}.file-info{white-space:nowrap;text-overflow:ellipsis;overflow:hidden}.file-info+.file-controls{-ms-flex:none;flex:none;margin-left:1rem}.empty-block{margin:5rem auto;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-align:center;align-items:center}.empty-block .upload-file{margin-bottom:1.875rem}.empty-block .empty-message{font-size:1.5rem;margin-bottom:0.4375rem}.empty-block .notif-wrapper{-ms-flex-pack:center;justify-content:center}.empty-block .notif-wrapper .wm-button{width:auto}ul{list-style:none;padding:0;width:100%}ul li{font-size:0.875rem}ul li .file{-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;position:relative;height:3.75rem;padding:0.5rem 1.25rem;background:#f4f4f4;border:1px solid #6b6b6b;display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-align:center;align-items:center}ul li .file+.file{margin-top:1.25rem}ul li .file .filename{font-weight:500}ul li .file .filedate{margin-left:3.75rem;font-weight:normal;font-style:italic}ul li .file wm-button+wm-button{margin-left:1rem}ul.file-list .file.--saved,ul.inprogress-list .file{margin-bottom:1.625rem}ul .progress{position:absolute;left:0;top:0;right:0;height:8px}ul.error-list li{margin-bottom:1.25rem;color:#c0392b}ul.error-list li .file{border:1px solid #c0392b;background-color:#f5ebea;height:3.75rem}ul .error-message{padding-top:0.25rem;font-style:italic}';export{w as wm_network_uploader}