@watermarkinsights/ripple 3.37.0 → 3.38.0

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 (157) hide show
  1. package/dist/cjs/{chartFunctions-4d828b26.js → chartFunctions-5441fbec.js} +1 -1
  2. package/dist/cjs/{functions-0c27162e.js → functions-500629f8.js} +1 -1
  3. package/dist/cjs/{global-a2ca8069.js → global-b0628445.js} +1 -1
  4. package/dist/cjs/{intl-022a42a1.js → intl-821d2be2.js} +1 -1
  5. package/dist/cjs/loader.cjs.js +2 -2
  6. package/dist/cjs/priv-chart-popover.cjs.entry.js +1 -1
  7. package/dist/cjs/priv-datepicker.cjs.entry.js +1 -1
  8. package/dist/cjs/ripple.cjs.js +2 -2
  9. package/dist/cjs/wm-action-menu_2.cjs.entry.js +1 -1
  10. package/dist/cjs/wm-button.cjs.entry.js +1 -1
  11. package/dist/cjs/wm-chart.cjs.entry.js +3 -3
  12. package/dist/cjs/wm-datepicker.cjs.entry.js +1 -1
  13. package/dist/cjs/wm-file.cjs.entry.js +1 -1
  14. package/dist/cjs/wm-input.cjs.entry.js +2 -2
  15. package/dist/cjs/wm-line-chart.cjs.entry.js +3 -3
  16. package/dist/cjs/wm-modal-header.cjs.entry.js +2 -2
  17. package/dist/cjs/wm-modal.cjs.entry.js +2 -2
  18. package/dist/cjs/wm-navigation_3.cjs.entry.js +2 -2
  19. package/dist/cjs/wm-navigator.cjs.entry.js +1 -1
  20. package/dist/cjs/wm-network-uploader.cjs.entry.js +2 -2
  21. package/dist/cjs/wm-option_2.cjs.entry.js +2 -2
  22. package/dist/cjs/wm-pagination.cjs.entry.js +1 -1
  23. package/dist/cjs/wm-progress-indicator_3.cjs.entry.js +2 -2
  24. package/dist/cjs/wm-search.cjs.entry.js +2 -2
  25. package/dist/cjs/wm-snackbar.cjs.entry.js +2 -2
  26. package/dist/cjs/wm-tab-item_3.cjs.entry.js +1 -1
  27. package/dist/cjs/wm-tag-input.cjs.entry.js +2 -2
  28. package/dist/cjs/wm-timepicker.cjs.entry.js +1 -1
  29. package/dist/cjs/wm-toggletip.cjs.entry.js +1 -1
  30. package/dist/cjs/wm-uploader.cjs.entry.js +2 -2
  31. package/dist/collection/collection-manifest.json +1 -1
  32. package/dist/collection/components/wm-modal/wm-modal.css +1 -0
  33. package/dist/collection/components/wm-tag-input/wm-tag-input.js +1 -1
  34. package/dist/esm/{chartFunctions-f4f3252e.js → chartFunctions-73e3dec2.js} +1 -1
  35. package/dist/esm/{functions-d52b728c.js → functions-25f9ef6d.js} +1 -1
  36. package/dist/esm/{global-06801d00.js → global-9d3664e6.js} +1 -1
  37. package/dist/esm/{intl-9809c77c.js → intl-c3678c68.js} +1 -1
  38. package/dist/esm/loader.js +2 -2
  39. package/dist/esm/priv-chart-popover.entry.js +1 -1
  40. package/dist/esm/priv-datepicker.entry.js +1 -1
  41. package/dist/esm/ripple.js +2 -2
  42. package/dist/esm/wm-action-menu_2.entry.js +1 -1
  43. package/dist/esm/wm-button.entry.js +1 -1
  44. package/dist/esm/wm-chart.entry.js +3 -3
  45. package/dist/esm/wm-datepicker.entry.js +1 -1
  46. package/dist/esm/wm-file.entry.js +1 -1
  47. package/dist/esm/wm-input.entry.js +2 -2
  48. package/dist/esm/wm-line-chart.entry.js +3 -3
  49. package/dist/esm/wm-modal-header.entry.js +2 -2
  50. package/dist/esm/wm-modal.entry.js +2 -2
  51. package/dist/esm/wm-navigation_3.entry.js +2 -2
  52. package/dist/esm/wm-navigator.entry.js +1 -1
  53. package/dist/esm/wm-network-uploader.entry.js +2 -2
  54. package/dist/esm/wm-option_2.entry.js +2 -2
  55. package/dist/esm/wm-pagination.entry.js +1 -1
  56. package/dist/esm/wm-progress-indicator_3.entry.js +2 -2
  57. package/dist/esm/wm-search.entry.js +2 -2
  58. package/dist/esm/wm-snackbar.entry.js +2 -2
  59. package/dist/esm/wm-tab-item_3.entry.js +1 -1
  60. package/dist/esm/wm-tag-input.entry.js +2 -2
  61. package/dist/esm/wm-timepicker.entry.js +1 -1
  62. package/dist/esm/wm-toggletip.entry.js +1 -1
  63. package/dist/esm/wm-uploader.entry.js +2 -2
  64. package/dist/esm-es5/{chartFunctions-f4f3252e.js → chartFunctions-73e3dec2.js} +1 -1
  65. package/dist/esm-es5/{functions-d52b728c.js → functions-25f9ef6d.js} +1 -1
  66. package/dist/esm-es5/{global-06801d00.js → global-9d3664e6.js} +1 -1
  67. package/dist/esm-es5/{intl-9809c77c.js → intl-c3678c68.js} +1 -1
  68. package/dist/esm-es5/loader.js +1 -1
  69. package/dist/esm-es5/priv-chart-popover.entry.js +1 -1
  70. package/dist/esm-es5/priv-datepicker.entry.js +1 -1
  71. package/dist/esm-es5/ripple.js +1 -1
  72. package/dist/esm-es5/wm-action-menu_2.entry.js +1 -1
  73. package/dist/esm-es5/wm-button.entry.js +1 -1
  74. package/dist/esm-es5/wm-chart.entry.js +1 -1
  75. package/dist/esm-es5/wm-datepicker.entry.js +1 -1
  76. package/dist/esm-es5/wm-file.entry.js +1 -1
  77. package/dist/esm-es5/wm-input.entry.js +1 -1
  78. package/dist/esm-es5/wm-line-chart.entry.js +1 -1
  79. package/dist/esm-es5/wm-modal-header.entry.js +1 -1
  80. package/dist/esm-es5/wm-modal.entry.js +1 -1
  81. package/dist/esm-es5/wm-navigation_3.entry.js +1 -1
  82. package/dist/esm-es5/wm-navigator.entry.js +1 -1
  83. package/dist/esm-es5/wm-network-uploader.entry.js +1 -1
  84. package/dist/esm-es5/wm-option_2.entry.js +1 -1
  85. package/dist/esm-es5/wm-pagination.entry.js +1 -1
  86. package/dist/esm-es5/wm-progress-indicator_3.entry.js +1 -1
  87. package/dist/esm-es5/wm-search.entry.js +1 -1
  88. package/dist/esm-es5/wm-snackbar.entry.js +1 -1
  89. package/dist/esm-es5/wm-tab-item_3.entry.js +1 -1
  90. package/dist/esm-es5/wm-tag-input.entry.js +1 -1
  91. package/dist/esm-es5/wm-timepicker.entry.js +1 -1
  92. package/dist/esm-es5/wm-toggletip.entry.js +1 -1
  93. package/dist/esm-es5/wm-uploader.entry.js +1 -1
  94. package/dist/ripple/{p-dd01929e.system.entry.js → p-0259d353.system.entry.js} +1 -1
  95. package/dist/ripple/{p-c1857a16.entry.js → p-0afff679.entry.js} +1 -1
  96. package/dist/ripple/{p-5d592297.system.entry.js → p-0b0f8667.system.entry.js} +1 -1
  97. package/dist/ripple/{p-84e55d9e.entry.js → p-0ed2b6df.entry.js} +1 -1
  98. package/dist/ripple/{p-b982a342.entry.js → p-0ef2737d.entry.js} +1 -1
  99. package/dist/ripple/{p-adf76148.entry.js → p-11b91d75.entry.js} +1 -1
  100. package/dist/ripple/{p-ba31d982.system.js → p-161d5e7c.system.js} +1 -1
  101. package/dist/ripple/{p-24d9f6fe.entry.js → p-1841a3a5.entry.js} +1 -1
  102. package/dist/ripple/{p-8f273c5b.system.entry.js → p-1d62ea4d.system.entry.js} +1 -1
  103. package/dist/ripple/{p-f9539737.system.entry.js → p-2570ec1f.system.entry.js} +1 -1
  104. package/dist/ripple/{p-50623da2.entry.js → p-26985b84.entry.js} +1 -1
  105. package/dist/ripple/{p-20df08be.system.entry.js → p-2d2d30a5.system.entry.js} +1 -1
  106. package/dist/ripple/{p-e882a31f.system.entry.js → p-323e5fff.system.entry.js} +1 -1
  107. package/dist/ripple/{p-5e55eb56.system.js → p-32d973fa.system.js} +1 -1
  108. package/dist/ripple/{p-fbb44f76.system.entry.js → p-426ba254.system.entry.js} +1 -1
  109. package/dist/ripple/{p-cab12cec.system.entry.js → p-45376571.system.entry.js} +1 -1
  110. package/dist/ripple/{p-725c757a.entry.js → p-4a3f88f8.entry.js} +1 -1
  111. package/dist/ripple/{p-c3915cfe.system.entry.js → p-5257b743.system.entry.js} +1 -1
  112. package/dist/ripple/{p-06871476.entry.js → p-56298c7d.entry.js} +1 -1
  113. package/dist/ripple/{p-fea4bc00.entry.js → p-5fbec5ff.entry.js} +1 -1
  114. package/dist/ripple/{p-11763c02.entry.js → p-631a011f.entry.js} +1 -1
  115. package/dist/ripple/{p-364753eb.js → p-653943d0.js} +1 -1
  116. package/dist/ripple/{p-7f722888.entry.js → p-6a2b7449.entry.js} +1 -1
  117. package/dist/ripple/{p-5c1b2132.system.entry.js → p-6ca3c1c0.system.entry.js} +1 -1
  118. package/dist/ripple/{p-9e29176c.entry.js → p-6cef908c.entry.js} +1 -1
  119. package/dist/ripple/{p-3b50511c.system.entry.js → p-6dd460d3.system.entry.js} +1 -1
  120. package/dist/ripple/{p-2ebac749.entry.js → p-73bd2015.entry.js} +1 -1
  121. package/dist/ripple/{p-27efb4d0.system.js → p-7471439a.system.js} +1 -1
  122. package/dist/ripple/{p-d72b00a0.entry.js → p-86bd1f20.entry.js} +1 -1
  123. package/dist/ripple/{p-25c1bd67.system.entry.js → p-8debafc6.system.entry.js} +1 -1
  124. package/dist/ripple/{p-cd7cc5c6.js → p-8e001d5e.js} +1 -1
  125. package/dist/ripple/p-96625959.system.entry.js +1 -0
  126. package/dist/ripple/{p-185c3645.entry.js → p-98488132.entry.js} +1 -1
  127. package/dist/ripple/{p-74a92541.system.entry.js → p-98b6e5da.system.entry.js} +1 -1
  128. package/dist/ripple/{p-fd354e00.system.js → p-9e5a95f9.system.js} +1 -1
  129. package/dist/ripple/{p-39e17683.system.js → p-a0ab477c.system.js} +1 -1
  130. package/dist/ripple/{p-2acf8af1.system.entry.js → p-a6f28b0b.system.entry.js} +1 -1
  131. package/dist/ripple/{p-26031cd0.system.entry.js → p-ae20ba70.system.entry.js} +1 -1
  132. package/dist/ripple/{p-9cb8f41b.entry.js → p-b8580615.entry.js} +1 -1
  133. package/dist/ripple/{p-d8de670a.system.entry.js → p-b91e3f86.system.entry.js} +1 -1
  134. package/dist/ripple/{p-80ca72ff.system.entry.js → p-ba6a3364.system.entry.js} +1 -1
  135. package/dist/ripple/{p-e0f270e2.system.entry.js → p-bbffc0d1.system.entry.js} +1 -1
  136. package/dist/ripple/{p-fcdd9e03.system.entry.js → p-bedd750c.system.entry.js} +1 -1
  137. package/dist/ripple/{p-89bf36c8.system.entry.js → p-ca265cea.system.entry.js} +1 -1
  138. package/dist/ripple/{p-da01c531.entry.js → p-cbe31120.entry.js} +1 -1
  139. package/dist/ripple/{p-42aeb9bb.js → p-d3accb39.js} +1 -1
  140. package/dist/ripple/{p-3ec4ae19.entry.js → p-d3f4e391.entry.js} +1 -1
  141. package/dist/ripple/{p-ae97bf6c.system.entry.js → p-e6038b0f.system.entry.js} +1 -1
  142. package/dist/ripple/{p-697ba13b.entry.js → p-e9a21714.entry.js} +1 -1
  143. package/dist/ripple/{p-ed3e41ed.entry.js → p-e9e2e4c4.entry.js} +1 -1
  144. package/dist/ripple/{p-aae11e37.system.entry.js → p-f0b5cc80.system.entry.js} +1 -1
  145. package/dist/ripple/{p-ff888d78.js → p-f0d87250.js} +1 -1
  146. package/dist/ripple/{p-fd91cd58.entry.js → p-f1fae497.entry.js} +1 -1
  147. package/dist/ripple/{p-53f5e969.system.entry.js → p-f8512877.system.entry.js} +1 -1
  148. package/dist/ripple/{p-4b59b16a.entry.js → p-f8654cb1.entry.js} +1 -1
  149. package/dist/ripple/{p-198f596b.entry.js → p-f8b58321.entry.js} +1 -1
  150. package/dist/ripple/{p-535e7286.entry.js → p-fa641a36.entry.js} +1 -1
  151. package/dist/ripple/ripple.esm.js +1 -1
  152. package/dist/ripple/ripple.js +1 -1
  153. package/package.json +1 -1
  154. package/dist/ripple/p-50be6128.system.entry.js +0 -1
  155. package/dist/types/components/wm-tag-input/wm-tag-input-row/wm-tag-input-row.d.ts +0 -11
  156. package/dist/types/components/wm-tag-input/wm-tag-input.d.ts +0 -138
  157. package/dist/types/components/wm-uploader/wm-network-uploader/wm-network-uploader.d.ts +0 -85
@@ -1 +1 @@
1
- var __awaiter=this&&this.__awaiter||function(t,e,r,a){function n(t){return t instanceof r?t:new r((function(e){e(t)}))}return new(r||(r=Promise))((function(r,i){function s(t){try{l(a.next(t))}catch(t){i(t)}}function o(t){try{l(a["throw"](t))}catch(t){i(t)}}function l(t){t.done?r(t.value):n(t.value).then(s,o)}l((a=a.apply(t,e||[])).next())}))};var __generator=this&&this.__generator||function(t,e){var r={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},a,n,i,s;return s={next:o(0),throw:o(1),return:o(2)},typeof Symbol==="function"&&(s[Symbol.iterator]=function(){return this}),s;function o(t){return function(e){return l([t,e])}}function l(o){if(a)throw new TypeError("Generator is already executing.");while(s&&(s=0,o[0]&&(r=0)),r)try{if(a=1,n&&(i=o[0]&2?n["return"]:o[0]?n["throw"]||((i=n["return"])&&i.call(n),0):n.next)&&!(i=i.call(n,o[1])).done)return i;if(n=0,i)o=[o[0]&2,i.value];switch(o[0]){case 0:case 1:i=o;break;case 4:r.label++;return{value:o[1],done:false};case 5:r.label++;n=o[1];o=[0];continue;case 7:o=r.ops.pop();r.trys.pop();continue;default:if(!(i=r.trys,i=i.length>0&&i[i.length-1])&&(o[0]===6||o[0]===2)){r=0;continue}if(o[0]===3&&(!i||o[1]>i[0]&&o[1]<i[3])){r.label=o[1];break}if(o[0]===6&&r.label<i[1]){r.label=i[1];i=o;break}if(i&&r.label<i[2]){r.label=i[2];r.ops.push(o);break}if(i[2])r.ops.pop();r.trys.pop();continue}o=e.call(t,r)}catch(t){o=[6,t];n=0}finally{a=i=0}if(o[0]&5)throw o[1];return{value:o[0]?o[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(t,e,r){if(r||arguments.length===2)for(var a=0,n=e.length,i;a<n;a++){if(i||!(a in e)){if(!i)i=Array.prototype.slice.call(e,0,a);i[a]=e[a]}}return t.concat(i||Array.prototype.slice.call(e))};System.register(["./p-30bf24f8.system.js","./p-5e55eb56.system.js"],(function(t){"use strict";var e,r,a,n,i,s;return{setters:[function(t){e=t.h},function(t){r=t.i;a=t.c;n=t.f;i=t.e;s=t.d}],execute:function(){t({b:f,c:N,d:L,e:P,f:U,g:B,h:M,i:H,j:X,k:A,l:q,m:d,n:x,r:K});var o={salmon:"#ff5f4e",cyan:"#19a1a9",forest:"#088000",sleet:"#7f97ad",midnight:"#2e1b46",lavender:"#8b86ca",periwinkle:"#575195",gray:"#6b6b6b"};var l=t("a",{doughnut:{size:155,colors:[o.forest,o.gray],thickness:.73,padding:25,category:"doughnut"},doughnut0:{size:155,colors:[o.forest,o.gray],thickness:.73,padding:25,category:"doughnut"},doughnut1:{size:130,colors:[o.lavender,o.midnight,o.gray],thickness:.5,padding:90,category:"doughnut"},doughnut2:{size:130,colors:[o.cyan,o.salmon,o.gray],thickness:.5,padding:90,category:"doughnut"},doughnut2b:{size:130,colors:[o.periwinkle,o.cyan,o.salmon,o.gray],thickness:.5,padding:90,category:"doughnut"},doughnut3:{size:130,colors:[o.lavender,o.midnight,"#0089e4",o.forest,"#ea8500","#d54f41","#146ca9"],thickness:.5,padding:90,category:"doughnut"},bar:{size:350,colors:[o.forest,o.gray],padding:0,category:"stackedBar"},bar1:{size:350,colors:[o.forest,o.gray],padding:0,category:"stackedBar"},bar2:{size:400,colors:[o.gray,o.periwinkle,o.cyan,o.salmon],padding:0,category:"stackedBar"},bar2b:{size:400,colors:[o.gray,o.periwinkle,o.midnight,o.cyan,o.salmon],padding:0,category:"stackedBar"},bar3:{size:300,colors:["#0d696e",o.cyan,"#8e4129",o.salmon],padding:0,category:"stackedBar"},bar4:{size:400,colors:[o.salmon,o.cyan,o.periwinkle],padding:0,category:"stackedBar"},bar5:{size:400,colors:[o.gray,o.lavender,o.midnight,"#0089e4",o.forest,"#ea8500","#d54f41","#146ca9"],padding:0,category:"stackedBar"},bar6:{size:400,colors:[o.lavender],padding:0,category:"simpleBar"},bar7:{size:400,colors:[o.periwinkle,o.cyan,o.salmon,o.gray],padding:0,category:"simpleBar"}});function c(t){return t==="percentage"||t==="amount"?"show-values":""}var u=r.formatMessage({id:"chart.hiddenValues",defaultMessage:"Values are not shown when too close to each other.",description:"Text displayed when a chart has some values hidden"});var h=r.formatMessage({id:"chart.clickToSeeDetails",defaultMessage:"Click or use arrow keys to see details.",description:"Text displayed, guiding user to interact to see more details."});function d(t){return t>999||t<-999?Math.round(t/100)/10+"K":t}function f(t,e,r){return r?Math.round(t*100/e):Math.round(t*1e4/e)/100}function p(t,e){return t*360/e}function v(t){return parseFloat((Math.floor(t*100)/100).toFixed(2))}function g(t,e,r,a){var n=v(t+t*e*Math.cos(Math.PI*r/180));var i=v(t+t*e*Math.sin(Math.PI*r/180));if(a!==undefined){var s=v(t+t*e*Math.cos(Math.PI*a/180));var o=v(t+t*e*Math.sin(Math.PI*a/180));return{x1:n,y1:i,x2:s,y2:o}}return{x:n,y:i}}function m(t,e,r,a,n){var i=v(n/2*t);return"A ".concat(i,", ").concat(i," 0 ").concat(e," ").concat(v(r),", ").concat(v(a))}function b(t,e,r,a,n){var i=(t-e)*(n-a)/(r-e)+a;return i<a?a:i>n?n:i}function y(t){return b(t,300,900,70,150)}function w(t){return Math.round(t/y(t))}function x(t,e){var r=t/e;var a=Math.pow(10,Math.floor(Math.log10(r)));var n=r/a;var i;if(n>5){i=10*a}else if(n>3){i=5*a}else if(n>2){i=3*a}else if(n>1.5){i=2*a}else if(n>1){i=1.5*a}else{i=a}return i}function k(t){if(this.popoverEl&&this.popoverEl.open&&t.key==="Enter"){var e=this.popoverEl.querySelector("button");e&&e.click()}}function E(t,e){if(this.popoverEl&&!this.isTabbing){e.coords={x:t.clientX,y:t.clientY};z.call(this,e)}}function D(t,e){if(this.popoverEl&&this.isTabbing){e.coords=a(t.target);z.call(this,e)}}function M(t){switch(t.key){case"ArrowUp":case"ArrowLeft":t.preventDefault();this.isTabbing=true;_.call(this);break;case"ArrowRight":case"ArrowDown":t.preventDefault();this.isTabbing=true;T.call(this);break;case"Tab":A.call(this);break;case"Escape":this.popoverEl.open=false;this.userIsNavigating=false;break}}function z(t){var e=this;if(!!this.popoverEl&&!!t.title&&!!t.text){this.popoverEl.popoverTitle=t.title;this.popoverEl.popoverText=t.text;this.popoverEl.buttonText=t.buttonText;this.popoverEl.coords=t.coords;this.popoverEl.sliceRef=t.sliceRef;window.setTimeout((function(){if(e.popoverEl){e.popoverEl.open=true}}),30);var r=s((function(){return __awaiter(e,void 0,void 0,(function(){return __generator(this,(function(t){this.popoverEl.open=false;return[2]}))}))}),10);document.addEventListener("scroll",(function(){r()}));var a=n(this.el);if(!!a){a.addEventListener("scroll",(function(){r()}))}}}function T(){var t=i(document.activeElement);var e=(this.sliceEls.indexOf(t)+1)%this.sliceEls.length;C.call(this,e)}function _(){if(this.sliceEls){var t=i(document.activeElement);var e=this.sliceEls.indexOf(t);if(e===-1){e=0}else if(e===0){e=this.sliceEls.length-1}else{e-=1}C.call(this,e)}}function C(t){var e=this;if(this.sliceEls&&this.el){this.userIsNavigating=true;if(this.popoverEl){this.popoverEl.open=false}this.componentWrapperEl.tabIndex=-1;this.el.focusable=false;this.sliceEls.map((function(t){t.tabIndex=-1;t.focusable=false}));this.sliceEls[t].tabIndex=0;this.sliceEls[t].focusable=true;this.sliceEls[t].focus();window.setTimeout((function(){if(e.popoverEl){e.popoverEl.open=true}}),10)}}function A(){var t=this;this.sliceEls&&this.sliceEls.map((function(t){t.tabIndex=-1;t.focusable=false}));this.userIsNavigating=false;window.setTimeout((function(){t.componentWrapperEl.tabIndex=0;t.el.focusable=true;if(t.popoverEl){t.popoverEl.open=false}}),100)}function B(t){return __awaiter(this,void 0,void 0,(function(){var e,r;var a=this;return __generator(this,(function(n){this.slicesDetails=[];e=0;r=Array.from(this.el.children);this.total=r.reduce((function(t,e){return t+=parseInt(e.getAttribute("amount")||"0")}),0);r.forEach((function(r,n){var i=parseInt(r.getAttribute("amount")||"0");var s=f(i,a.total,true);var c=n;if(t==="bar5"){c=a.notStartedColor?n:n+1}if(t==="bar6"){c=0}var u=l[t].colors[c];var h={amount:i,perc:s,legend:r.getAttribute("legend"),color:u||o.gray,offset:e,id:"".concat(a.uid,"-").concat(n+1),title:r.getAttribute("popover-title"),text:r.getAttribute("popover-text"),buttonText:r.getAttribute("popover-button-text"),sliceRef:r,inSmallCluster:false};e+=i;a.slicesDetails.push(h)}));return[2]}))}))}function I(t,e){var r=__spreadArray([],t,true).sort((function(t,e){return t.amount===e.amount?0:t.amount>e.amount?-1:1}));var a=0;r.forEach((function(t,n){var i=r[n===0?r.length-1:n-1];var s=r[n===r.length-1?0:n+1];var o=f(i.amount,e,true);var l=f(s.amount,e,true);t.offset=a;a+=t.amount;t.inSmallCluster=S(o,t.perc,t.amount,l)}));return r}function S(t,e,r,a){var n=e<4;var i=t<5;var s=a<5;var o=n&&(i||s);var l=e===0&&r>0;if(l&&(a<8||t<8)){o=true}return o}function F(t,e,r){var a=p(e,this.total)-90;var n=t/this.total*360;var i=a+n;var s=n>180?"1 1":"0 1";var o=n>180?"1 0":"0 0";var l=this.chartDetails.size/2;var c=this.chartDetails.thickness;var u=1;var h=r==="doughnut0"||r==="doughnut";var d=1.5;var f=h?2.25:3;if(n===360){i-=.01}var v=g(l,u,a+d,i);var b=g(l,c,a+f,i);var y="M ".concat(v.x1,", ").concat(v.y1," ");var w=m(u,s,v.x2,v.y2,this.chartDetails.size);var x=" L ".concat(b.x2,", ").concat(b.y2," ");var k=m(c,o,b.x1,b.y1,this.chartDetails.size);return y+w+x+k+" z"}function P(){var t=r.formatMessage({id:"chart.instructions",defaultMessage:"Use arrow keys to browse elements, press Tab to exit.",description:"For screen readers only, instructions on how to interact with the chart component"});return e("div",{id:"chart-instructions"},t)}function V(){return e("defs",null,e("filter",{id:"wmHoverDropShadow"},e("feGaussianBlur",{stdDeviation:"3"}),e("feOffset",{result:"offsetblur"}),e("feFlood",{"flood-color":"#333"}),e("feComposite",{operator:"in",in2:"offsetblur"}),e("feMerge",null,e("feMergeNode",null),e("feMergeNode",{in:"SourceGraphic"}))))}function L(t){var r=this;var a=this.chartDetails.size+this.chartDetails.padding;var n=t==="doughnut0"||t==="doughnut";var i=n?this.slicesDetails:I(this.slicesDetails,this.total);return e("div",{class:"chart-wrapper doughnut-wrapper"},e("svg",{width:a+"px",height:a+"px",id:"graphic-".concat(this.uid),class:"doughnut-svg"},V(),i.map((function(e){return R.call(r,e,t)})),n?e("text",{class:"value",x:"50%",y:"50%","font-size":"1.5rem","font-weight":"500","text-anchor":"middle","dominant-baseline":"middle"},f(i[0].amount,this.total,true)+"%"):e("g",{transform:"translate(".concat(this.chartDetails.padding/2,", ").concat(this.chartDetails.padding/2,")"),"text-anchor":"middle","dominant-baseline":"middle"},i.map((function(t){return t.amount>0&&!t.inSmallCluster?W.call(r,t):""})))))}function R(t,r){var a=this;return e("g",{transform:"translate(".concat(this.chartDetails.padding/2,", ").concat(this.chartDetails.padding/2,")")},e("path",{id:t.id,class:"segment doughnut-segment",fill:t.amount?t.color:"transparent",d:F.call(this,t.amount,t.offset,r),onClick:function(e){return E.call(a,e,t)},onFocus:function(e){return D.call(a,e,t)},onKeyDown:function(t){return k.call(a,t)},role:"img","aria-label":t.legend}))}function W(t){var r=p(t.offset+t.amount/2,this.total);var a=g(this.chartDetails.size/2,1.4,r-90),n=a.x,i=a.y;return e("text",{class:"value",x:n+"px",y:i+"px"},"".concat(t.perc>0?t.perc:"<1","%"))}function N(t){var r=this;var a=t==="bar1"||t==="bar";return e("div",{class:"chart-wrapper bar-wrapper"},a?e("div",{class:"single-perc"},f(this.slicesDetails[0].amount,this.total,true)+"%"):"",this.chartType==="bar3"&&this.drawAxis(),e("div",{class:"inner-stacked-bar-wrapper ".concat(c(this.tempValueFormat))},!a?e("div",{class:"values"},this.slicesDetails.map((function(t,e){return r.renderBarText(t,e)}))):"",e("div",{class:"stacked-bar-segments-wrapper"},this.slicesDetails.map((function(t,e){return G.call(r,t,e)}))),a?H.call(this):""))}function G(t,r){var a=this;var n=r!==this.slicesDetails.length-1;var i="calc(".concat(f(t.amount,this.total,false),"%").concat(n?" - 2px":"",")");return e("div",{class:"segment stacked-bar-segment ".concat(f(t.amount,this.total,false)===0?"zero":""),style:{backgroundColor:t.color,width:i},onClick:function(e){return E.call(a,e,t)},onFocus:function(e){return D.call(a,e,t)},onKeyDown:function(t){return k.call(a,t)}},e("span",{class:"sr-only"},t.legend))}function K(t){var r=this;var a=this.slicesDetails.map((function(t){return t.amount})).reduce((function(t,e){return t>e?t:e}));var n=parseInt(getComputedStyle(this.el).getPropertyValue("--labelWidth"),10);var i=48;var s=this.el.getBoundingClientRect().width;var o=s-n-i;var l=w(o);var u=x(a,l);var h=l*u;var f=Math.floor((h-a)/u);l-=f;this.el.style.setProperty("--backgroundSize",100/l+"%");this.el.style.setProperty("--labelWidth",this.labelWidth);if(t==="bar7"&&!this.showBarLegend){this.el.style.setProperty("--labelWidth","0px")}var p=[];this.slicesDetails.forEach((function(e){e.legend&&p.push(j(e.legend,r.showBarLegend,t));p.push(O.call(r,e,u,l,a))}));var v=[];for(var g=1;g<=l;g++){var m=d(g*u);v.push(e("div",{class:"tick"},e("span",null,m)))}var b=t==="bar6"&&this.showGrid&&this.el.getBoundingClientRect().width>300;return e("div",{class:"chart-wrapper simple-bar-wrapper"},e("div",{class:"chart ".concat(c(this.tempValueFormat))},b&&e("div",{class:"gridlines"}),e("div",{class:"rows"},p)),b&&e("div",{class:"x-axis","aria-hidden":"true"},e("div",{class:"zero"},e("span",null,"0")),v))}function j(t,r,a){var n=a==="bar7"&&!r?" hidden":"";return e("label",{class:"label".concat(n)},t)}function O(t,r,a,n){var i=this;var s=this.currentChartType==="bar6"?r*a:n;var o=f(t.amount,s,false);var l=o?o+"%":"1px";var c=d(t.amount);var u=this.tempValueFormat==="amount"?c:"";if(this.currentChartType==="bar6"&&this.tempValueFormat==="percentage"){u=t.amount+"%"}else if(this.currentChartType==="bar7"&&this.tempValueFormat==="percentage"){u=(this.total===0?"0":f(t.amount,this.total,true))+"%"}return e("div",{class:"bar segment",style:{backgroundColor:t.color,width:l},onClick:function(e){return E.call(i,e,t)},onFocus:function(e){return D.call(i,e,t)},onKeyDown:function(t){return k.call(i,t)}},e("div",{class:"value"},u))}function U(t){if(this.showLegend){var r=!this.chartDetails.isBar&&this.slicesDetails.reduce((function(t,e){return t=e.inSmallCluster?true:t}),false);return e("div",{class:"legend-wrapper"},e("div",{class:"legend ".concat(t," ").concat(this.mode==="bar"?"--top":"--bottom"),"aria-hidden":"true"},this.slicesDetails.map((function(t){if(!!t.amount||!!t.legend){return q({key:t.legend,color:t.color})}}))),r&&X())}}function q(t){return e("div",{class:"legend-item"},e("div",{class:"legend-color",style:{backgroundColor:t.color}}),e("div",{class:"legend-text"},t.key))}function H(){if(this.completionMessage){return e("div",{class:"completion-message"},this.completionMessage)}}function X(){return e("div",{class:"hidden-values-warning"},u,e("br",null),h)}}}}));
1
+ var __awaiter=this&&this.__awaiter||function(t,e,r,a){function n(t){return t instanceof r?t:new r((function(e){e(t)}))}return new(r||(r=Promise))((function(r,i){function s(t){try{l(a.next(t))}catch(t){i(t)}}function o(t){try{l(a["throw"](t))}catch(t){i(t)}}function l(t){t.done?r(t.value):n(t.value).then(s,o)}l((a=a.apply(t,e||[])).next())}))};var __generator=this&&this.__generator||function(t,e){var r={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},a,n,i,s;return s={next:o(0),throw:o(1),return:o(2)},typeof Symbol==="function"&&(s[Symbol.iterator]=function(){return this}),s;function o(t){return function(e){return l([t,e])}}function l(o){if(a)throw new TypeError("Generator is already executing.");while(s&&(s=0,o[0]&&(r=0)),r)try{if(a=1,n&&(i=o[0]&2?n["return"]:o[0]?n["throw"]||((i=n["return"])&&i.call(n),0):n.next)&&!(i=i.call(n,o[1])).done)return i;if(n=0,i)o=[o[0]&2,i.value];switch(o[0]){case 0:case 1:i=o;break;case 4:r.label++;return{value:o[1],done:false};case 5:r.label++;n=o[1];o=[0];continue;case 7:o=r.ops.pop();r.trys.pop();continue;default:if(!(i=r.trys,i=i.length>0&&i[i.length-1])&&(o[0]===6||o[0]===2)){r=0;continue}if(o[0]===3&&(!i||o[1]>i[0]&&o[1]<i[3])){r.label=o[1];break}if(o[0]===6&&r.label<i[1]){r.label=i[1];i=o;break}if(i&&r.label<i[2]){r.label=i[2];r.ops.push(o);break}if(i[2])r.ops.pop();r.trys.pop();continue}o=e.call(t,r)}catch(t){o=[6,t];n=0}finally{a=i=0}if(o[0]&5)throw o[1];return{value:o[0]?o[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(t,e,r){if(r||arguments.length===2)for(var a=0,n=e.length,i;a<n;a++){if(i||!(a in e)){if(!i)i=Array.prototype.slice.call(e,0,a);i[a]=e[a]}}return t.concat(i||Array.prototype.slice.call(e))};System.register(["./p-30bf24f8.system.js","./p-32d973fa.system.js"],(function(t){"use strict";var e,r,a,n,i,s;return{setters:[function(t){e=t.h},function(t){r=t.i;a=t.c;n=t.f;i=t.e;s=t.d}],execute:function(){t({b:f,c:N,d:L,e:P,f:U,g:B,h:M,i:H,j:X,k:A,l:q,m:d,n:x,r:K});var o={salmon:"#ff5f4e",cyan:"#19a1a9",forest:"#088000",sleet:"#7f97ad",midnight:"#2e1b46",lavender:"#8b86ca",periwinkle:"#575195",gray:"#6b6b6b"};var l=t("a",{doughnut:{size:155,colors:[o.forest,o.gray],thickness:.73,padding:25,category:"doughnut"},doughnut0:{size:155,colors:[o.forest,o.gray],thickness:.73,padding:25,category:"doughnut"},doughnut1:{size:130,colors:[o.lavender,o.midnight,o.gray],thickness:.5,padding:90,category:"doughnut"},doughnut2:{size:130,colors:[o.cyan,o.salmon,o.gray],thickness:.5,padding:90,category:"doughnut"},doughnut2b:{size:130,colors:[o.periwinkle,o.cyan,o.salmon,o.gray],thickness:.5,padding:90,category:"doughnut"},doughnut3:{size:130,colors:[o.lavender,o.midnight,"#0089e4",o.forest,"#ea8500","#d54f41","#146ca9"],thickness:.5,padding:90,category:"doughnut"},bar:{size:350,colors:[o.forest,o.gray],padding:0,category:"stackedBar"},bar1:{size:350,colors:[o.forest,o.gray],padding:0,category:"stackedBar"},bar2:{size:400,colors:[o.gray,o.periwinkle,o.cyan,o.salmon],padding:0,category:"stackedBar"},bar2b:{size:400,colors:[o.gray,o.periwinkle,o.midnight,o.cyan,o.salmon],padding:0,category:"stackedBar"},bar3:{size:300,colors:["#0d696e",o.cyan,"#8e4129",o.salmon],padding:0,category:"stackedBar"},bar4:{size:400,colors:[o.salmon,o.cyan,o.periwinkle],padding:0,category:"stackedBar"},bar5:{size:400,colors:[o.gray,o.lavender,o.midnight,"#0089e4",o.forest,"#ea8500","#d54f41","#146ca9"],padding:0,category:"stackedBar"},bar6:{size:400,colors:[o.lavender],padding:0,category:"simpleBar"},bar7:{size:400,colors:[o.periwinkle,o.cyan,o.salmon,o.gray],padding:0,category:"simpleBar"}});function c(t){return t==="percentage"||t==="amount"?"show-values":""}var u=r.formatMessage({id:"chart.hiddenValues",defaultMessage:"Values are not shown when too close to each other.",description:"Text displayed when a chart has some values hidden"});var h=r.formatMessage({id:"chart.clickToSeeDetails",defaultMessage:"Click or use arrow keys to see details.",description:"Text displayed, guiding user to interact to see more details."});function d(t){return t>999||t<-999?Math.round(t/100)/10+"K":t}function f(t,e,r){return r?Math.round(t*100/e):Math.round(t*1e4/e)/100}function p(t,e){return t*360/e}function v(t){return parseFloat((Math.floor(t*100)/100).toFixed(2))}function g(t,e,r,a){var n=v(t+t*e*Math.cos(Math.PI*r/180));var i=v(t+t*e*Math.sin(Math.PI*r/180));if(a!==undefined){var s=v(t+t*e*Math.cos(Math.PI*a/180));var o=v(t+t*e*Math.sin(Math.PI*a/180));return{x1:n,y1:i,x2:s,y2:o}}return{x:n,y:i}}function m(t,e,r,a,n){var i=v(n/2*t);return"A ".concat(i,", ").concat(i," 0 ").concat(e," ").concat(v(r),", ").concat(v(a))}function b(t,e,r,a,n){var i=(t-e)*(n-a)/(r-e)+a;return i<a?a:i>n?n:i}function y(t){return b(t,300,900,70,150)}function w(t){return Math.round(t/y(t))}function x(t,e){var r=t/e;var a=Math.pow(10,Math.floor(Math.log10(r)));var n=r/a;var i;if(n>5){i=10*a}else if(n>3){i=5*a}else if(n>2){i=3*a}else if(n>1.5){i=2*a}else if(n>1){i=1.5*a}else{i=a}return i}function k(t){if(this.popoverEl&&this.popoverEl.open&&t.key==="Enter"){var e=this.popoverEl.querySelector("button");e&&e.click()}}function E(t,e){if(this.popoverEl&&!this.isTabbing){e.coords={x:t.clientX,y:t.clientY};z.call(this,e)}}function D(t,e){if(this.popoverEl&&this.isTabbing){e.coords=a(t.target);z.call(this,e)}}function M(t){switch(t.key){case"ArrowUp":case"ArrowLeft":t.preventDefault();this.isTabbing=true;_.call(this);break;case"ArrowRight":case"ArrowDown":t.preventDefault();this.isTabbing=true;T.call(this);break;case"Tab":A.call(this);break;case"Escape":this.popoverEl.open=false;this.userIsNavigating=false;break}}function z(t){var e=this;if(!!this.popoverEl&&!!t.title&&!!t.text){this.popoverEl.popoverTitle=t.title;this.popoverEl.popoverText=t.text;this.popoverEl.buttonText=t.buttonText;this.popoverEl.coords=t.coords;this.popoverEl.sliceRef=t.sliceRef;window.setTimeout((function(){if(e.popoverEl){e.popoverEl.open=true}}),30);var r=s((function(){return __awaiter(e,void 0,void 0,(function(){return __generator(this,(function(t){this.popoverEl.open=false;return[2]}))}))}),10);document.addEventListener("scroll",(function(){r()}));var a=n(this.el);if(!!a){a.addEventListener("scroll",(function(){r()}))}}}function T(){var t=i(document.activeElement);var e=(this.sliceEls.indexOf(t)+1)%this.sliceEls.length;C.call(this,e)}function _(){if(this.sliceEls){var t=i(document.activeElement);var e=this.sliceEls.indexOf(t);if(e===-1){e=0}else if(e===0){e=this.sliceEls.length-1}else{e-=1}C.call(this,e)}}function C(t){var e=this;if(this.sliceEls&&this.el){this.userIsNavigating=true;if(this.popoverEl){this.popoverEl.open=false}this.componentWrapperEl.tabIndex=-1;this.el.focusable=false;this.sliceEls.map((function(t){t.tabIndex=-1;t.focusable=false}));this.sliceEls[t].tabIndex=0;this.sliceEls[t].focusable=true;this.sliceEls[t].focus();window.setTimeout((function(){if(e.popoverEl){e.popoverEl.open=true}}),10)}}function A(){var t=this;this.sliceEls&&this.sliceEls.map((function(t){t.tabIndex=-1;t.focusable=false}));this.userIsNavigating=false;window.setTimeout((function(){t.componentWrapperEl.tabIndex=0;t.el.focusable=true;if(t.popoverEl){t.popoverEl.open=false}}),100)}function B(t){return __awaiter(this,void 0,void 0,(function(){var e,r;var a=this;return __generator(this,(function(n){this.slicesDetails=[];e=0;r=Array.from(this.el.children);this.total=r.reduce((function(t,e){return t+=parseInt(e.getAttribute("amount")||"0")}),0);r.forEach((function(r,n){var i=parseInt(r.getAttribute("amount")||"0");var s=f(i,a.total,true);var c=n;if(t==="bar5"){c=a.notStartedColor?n:n+1}if(t==="bar6"){c=0}var u=l[t].colors[c];var h={amount:i,perc:s,legend:r.getAttribute("legend"),color:u||o.gray,offset:e,id:"".concat(a.uid,"-").concat(n+1),title:r.getAttribute("popover-title"),text:r.getAttribute("popover-text"),buttonText:r.getAttribute("popover-button-text"),sliceRef:r,inSmallCluster:false};e+=i;a.slicesDetails.push(h)}));return[2]}))}))}function I(t,e){var r=__spreadArray([],t,true).sort((function(t,e){return t.amount===e.amount?0:t.amount>e.amount?-1:1}));var a=0;r.forEach((function(t,n){var i=r[n===0?r.length-1:n-1];var s=r[n===r.length-1?0:n+1];var o=f(i.amount,e,true);var l=f(s.amount,e,true);t.offset=a;a+=t.amount;t.inSmallCluster=S(o,t.perc,t.amount,l)}));return r}function S(t,e,r,a){var n=e<4;var i=t<5;var s=a<5;var o=n&&(i||s);var l=e===0&&r>0;if(l&&(a<8||t<8)){o=true}return o}function F(t,e,r){var a=p(e,this.total)-90;var n=t/this.total*360;var i=a+n;var s=n>180?"1 1":"0 1";var o=n>180?"1 0":"0 0";var l=this.chartDetails.size/2;var c=this.chartDetails.thickness;var u=1;var h=r==="doughnut0"||r==="doughnut";var d=1.5;var f=h?2.25:3;if(n===360){i-=.01}var v=g(l,u,a+d,i);var b=g(l,c,a+f,i);var y="M ".concat(v.x1,", ").concat(v.y1," ");var w=m(u,s,v.x2,v.y2,this.chartDetails.size);var x=" L ".concat(b.x2,", ").concat(b.y2," ");var k=m(c,o,b.x1,b.y1,this.chartDetails.size);return y+w+x+k+" z"}function P(){var t=r.formatMessage({id:"chart.instructions",defaultMessage:"Use arrow keys to browse elements, press Tab to exit.",description:"For screen readers only, instructions on how to interact with the chart component"});return e("div",{id:"chart-instructions"},t)}function V(){return e("defs",null,e("filter",{id:"wmHoverDropShadow"},e("feGaussianBlur",{stdDeviation:"3"}),e("feOffset",{result:"offsetblur"}),e("feFlood",{"flood-color":"#333"}),e("feComposite",{operator:"in",in2:"offsetblur"}),e("feMerge",null,e("feMergeNode",null),e("feMergeNode",{in:"SourceGraphic"}))))}function L(t){var r=this;var a=this.chartDetails.size+this.chartDetails.padding;var n=t==="doughnut0"||t==="doughnut";var i=n?this.slicesDetails:I(this.slicesDetails,this.total);return e("div",{class:"chart-wrapper doughnut-wrapper"},e("svg",{width:a+"px",height:a+"px",id:"graphic-".concat(this.uid),class:"doughnut-svg"},V(),i.map((function(e){return R.call(r,e,t)})),n?e("text",{class:"value",x:"50%",y:"50%","font-size":"1.5rem","font-weight":"500","text-anchor":"middle","dominant-baseline":"middle"},f(i[0].amount,this.total,true)+"%"):e("g",{transform:"translate(".concat(this.chartDetails.padding/2,", ").concat(this.chartDetails.padding/2,")"),"text-anchor":"middle","dominant-baseline":"middle"},i.map((function(t){return t.amount>0&&!t.inSmallCluster?W.call(r,t):""})))))}function R(t,r){var a=this;return e("g",{transform:"translate(".concat(this.chartDetails.padding/2,", ").concat(this.chartDetails.padding/2,")")},e("path",{id:t.id,class:"segment doughnut-segment",fill:t.amount?t.color:"transparent",d:F.call(this,t.amount,t.offset,r),onClick:function(e){return E.call(a,e,t)},onFocus:function(e){return D.call(a,e,t)},onKeyDown:function(t){return k.call(a,t)},role:"img","aria-label":t.legend}))}function W(t){var r=p(t.offset+t.amount/2,this.total);var a=g(this.chartDetails.size/2,1.4,r-90),n=a.x,i=a.y;return e("text",{class:"value",x:n+"px",y:i+"px"},"".concat(t.perc>0?t.perc:"<1","%"))}function N(t){var r=this;var a=t==="bar1"||t==="bar";return e("div",{class:"chart-wrapper bar-wrapper"},a?e("div",{class:"single-perc"},f(this.slicesDetails[0].amount,this.total,true)+"%"):"",this.chartType==="bar3"&&this.drawAxis(),e("div",{class:"inner-stacked-bar-wrapper ".concat(c(this.tempValueFormat))},!a?e("div",{class:"values"},this.slicesDetails.map((function(t,e){return r.renderBarText(t,e)}))):"",e("div",{class:"stacked-bar-segments-wrapper"},this.slicesDetails.map((function(t,e){return G.call(r,t,e)}))),a?H.call(this):""))}function G(t,r){var a=this;var n=r!==this.slicesDetails.length-1;var i="calc(".concat(f(t.amount,this.total,false),"%").concat(n?" - 2px":"",")");return e("div",{class:"segment stacked-bar-segment ".concat(f(t.amount,this.total,false)===0?"zero":""),style:{backgroundColor:t.color,width:i},onClick:function(e){return E.call(a,e,t)},onFocus:function(e){return D.call(a,e,t)},onKeyDown:function(t){return k.call(a,t)}},e("span",{class:"sr-only"},t.legend))}function K(t){var r=this;var a=this.slicesDetails.map((function(t){return t.amount})).reduce((function(t,e){return t>e?t:e}));var n=parseInt(getComputedStyle(this.el).getPropertyValue("--labelWidth"),10);var i=48;var s=this.el.getBoundingClientRect().width;var o=s-n-i;var l=w(o);var u=x(a,l);var h=l*u;var f=Math.floor((h-a)/u);l-=f;this.el.style.setProperty("--backgroundSize",100/l+"%");this.el.style.setProperty("--labelWidth",this.labelWidth);if(t==="bar7"&&!this.showBarLegend){this.el.style.setProperty("--labelWidth","0px")}var p=[];this.slicesDetails.forEach((function(e){e.legend&&p.push(j(e.legend,r.showBarLegend,t));p.push(O.call(r,e,u,l,a))}));var v=[];for(var g=1;g<=l;g++){var m=d(g*u);v.push(e("div",{class:"tick"},e("span",null,m)))}var b=t==="bar6"&&this.showGrid&&this.el.getBoundingClientRect().width>300;return e("div",{class:"chart-wrapper simple-bar-wrapper"},e("div",{class:"chart ".concat(c(this.tempValueFormat))},b&&e("div",{class:"gridlines"}),e("div",{class:"rows"},p)),b&&e("div",{class:"x-axis","aria-hidden":"true"},e("div",{class:"zero"},e("span",null,"0")),v))}function j(t,r,a){var n=a==="bar7"&&!r?" hidden":"";return e("label",{class:"label".concat(n)},t)}function O(t,r,a,n){var i=this;var s=this.currentChartType==="bar6"?r*a:n;var o=f(t.amount,s,false);var l=o?o+"%":"1px";var c=d(t.amount);var u=this.tempValueFormat==="amount"?c:"";if(this.currentChartType==="bar6"&&this.tempValueFormat==="percentage"){u=t.amount+"%"}else if(this.currentChartType==="bar7"&&this.tempValueFormat==="percentage"){u=(this.total===0?"0":f(t.amount,this.total,true))+"%"}return e("div",{class:"bar segment",style:{backgroundColor:t.color,width:l},onClick:function(e){return E.call(i,e,t)},onFocus:function(e){return D.call(i,e,t)},onKeyDown:function(t){return k.call(i,t)}},e("div",{class:"value"},u))}function U(t){if(this.showLegend){var r=!this.chartDetails.isBar&&this.slicesDetails.reduce((function(t,e){return t=e.inSmallCluster?true:t}),false);return e("div",{class:"legend-wrapper"},e("div",{class:"legend ".concat(t," ").concat(this.mode==="bar"?"--top":"--bottom"),"aria-hidden":"true"},this.slicesDetails.map((function(t){if(!!t.amount||!!t.legend){return q({key:t.legend,color:t.color})}}))),r&&X())}}function q(t){return e("div",{class:"legend-item"},e("div",{class:"legend-color",style:{backgroundColor:t.color}}),e("div",{class:"legend-text"},t.key))}function H(){if(this.completionMessage){return e("div",{class:"completion-message"},this.completionMessage)}}function X(){return e("div",{class:"hidden-values-warning"},u,e("br",null),h)}}}}));
@@ -1 +1 @@
1
- import{r as t,c as s,h as e,H as i,g as o}from"./p-b5bedd63.js";import{t as r,i as n,a}from"./p-ff888d78.js";import{g as h}from"./p-cd7cc5c6.js";const l=class{constructor(e){t(this,e),this.wmSearchBrowseResults=s(this,"wmSearchBrowseResults",7),this.wmBrowseSearchResults=s(this,"wmBrowseSearchResults",7),this.wmSearchValueChanged=s(this,"wmSearchValueChanged",7),this.wrapperEl=null,this.linkEl=null,this.searchType="basic",this.disabled=!1,this.placeholder="",this.label="",this.numResults=0,this.value="",this.isTabbing=!1,this.highlightedId="",this.highlightedName=null,this.highlightedNum=0,this.previousBlurredValue="",this.parentModal=void 0,this.announcement=""}get isDisabled(){return r(this.disabled)}get resultCount(){let t="";const s=n.formatMessage({id:"search.resultsFound",defaultMessage:"{numResults, plural, =0 {No results} one {1 result} other {# results}} found"},{numResults:this.numResults}),e=n.formatMessage({id:"search.xOfYResults",defaultMessage:"{numResults, plural, =0 {No results found} other {{current} of {numResults} results}}"},{numResults:this.numResults,current:this.highlightedNum});return"basic"===this.searchType?t=s:"find"===this.searchType&&(t=e),t}toggleTabbingOn(){this.isTabbing=!0,this.linkEl&&this.linkEl.classList.remove("sr-only"),this.linkEl&&this.linkEl.classList.add("show-for-tabbers")}toggleTabbingOff(){this.isTabbing=!1,this.linkEl&&this.linkEl.classList.add("sr-only"),this.linkEl&&this.linkEl.classList.remove("show-for-tabbers")}componentWillLoad(){""===this.placeholder&&console.error("You must set the placeholder property for the wm-search component."),""===this.label&&console.error("You must set the label property for the wm-search component."),this.hookToModal(),a(this.el,this.isDisabled)}hookToModal(){let t=this.el;for(;t;)"WM-MODAL"===t.tagName&&(this.parentModal=t),t=t.parentElement;this.parentModal&&["wmCloseTriggered","wmPrimaryTriggered","wmSecondaryTriggered"].map((t=>{this.parentModal.addEventListener(t,(()=>{this.updateValue("")}))}))}async updateValue(t){this.value=t,this.resetHighlightCountToStart()}handleNumResultsUpdate(){this.resetHighlightCountToStart(),this.value&&this.announceChanges()}handleDisabledChange(){a(this.el,this.isDisabled)}resetHighlightCountToStart(){"find"===this.searchType&&(this.highlightedNum=this.numResults?1:0)}announce(t){this.resultsLiveRegion.textContent===t&&(t+=" "),this.announcement=t}announceChanges(){window.requestAnimationFrame((()=>{let t=this.resultCount;"find"===this.searchType&&this.highlightedName&&(t+=`, ${this.highlightedName}`),this.announce(t)}))}changeHighlightedNum(t){this.numResults&&(this.highlightedNum=t<1?this.numResults:t>this.numResults?1:t,this.wmSearchBrowseResults.emit({position:this.highlightedNum}),this.wmBrowseSearchResults.emit({position:this.highlightedNum}),this.announceChanges())}addFocusStyle(){this.wrapperEl&&this.wrapperEl.classList.add("focus")}removeFocusStyle(){this.wrapperEl&&this.wrapperEl.classList.remove("focus")}handleBlur(){this.removeFocusStyle(),this.previousBlurredValue!==this.value&&this.wmSearchValueChanged.emit({value:this.value}),this.previousBlurredValue=this.value}renderResultsAndBrowseButtons(){return e("div",{class:"wm-find-elements"},e("div",{id:"results-display",class:"results"},this.resultCount),e("div",{class:"wm-button-collection"},e("wm-button",{"button-type":"icononly",icon:"f05d",tooltip:h.previous,"tooltip-position":"bottom",onClick:()=>this.changeHighlightedNum(this.highlightedNum-1),disabled:this.isDisabled||this.numResults<2,"label-for-identical-buttons":n.formatMessage({id:"search.previousResult",defaultMessage:"Press to hear previous matching result"})}),e("wm-button",{"button-type":"icononly",icon:"f045",tooltip:h.next,"tooltip-position":"bottom",onClick:()=>this.changeHighlightedNum(this.highlightedNum+1),disabled:this.isDisabled||this.numResults<2,"label-for-identical-buttons":n.formatMessage({id:"search.nextResult",defaultMessage:"Press to hear next matching result"})})))}renderJumpToLink(){return this.numResults&&this.highlightedId?e("a",{ref:t=>this.linkEl=t,href:`#${this.highlightedId}`,class:"sr-only"},n.formatMessage({id:"search.jumpToResult",defaultMessage:"Jump to search result in list"})):null}render(){return e(i,null,e("div",{id:"wm-search-wrapper",class:`wm-search-wrapper ${this.searchType}`,ref:t=>this.wrapperEl=t},e("input",{disabled:this.isDisabled,id:"wm-search-input",placeholder:this.placeholder,"aria-label":`${this.label?this.label+". ":""}${n.formatMessage({id:"search.typeToFilterResults",defaultMessage:"Type to filter the results"})}`,onInput:t=>this.updateValue(t.target.value),onFocus:()=>this.addFocusStyle(),onBlur:()=>this.handleBlur(),"aria-autocomplete":"none",autocomplete:"off",value:this.value}),e("span",{class:"mdi search-icon"},String.fromCodePoint(parseInt("0xf349"))),"find"===this.searchType&&this.renderResultsAndBrowseButtons(),e("div",{id:"wm-search-live",class:"sr-only","aria-live":"polite","aria-atomic":"true",ref:t=>this.resultsLiveRegion=t},this.announcement)),"find"===this.searchType&&this.renderJumpToLink())}static get delegatesFocus(){return!0}get el(){return o(this)}static get watchers(){return{numResults:["handleNumResultsUpdate"],disabled:["handleDisabledChange"]}}};l.style=':host{--wmcolor-search-background:var(--wmcolor-input-background);--wmcolor-search-border:var(--wmcolor-input-border);--wmcolor-search-jump-text-focus:var(--wmcolor-interactive-focus-textonly);--wmcolor-search-jump-text:var(--wmcolor-button-text-textonly);width:100%;font-size:0.875rem}:host *{-webkit-box-sizing:border-box;box-sizing:border-box}:host .wm-search-wrapper{border-radius:3px;position:relative;border:1px solid var(--wmcolor-search-border);display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-align:center;align-items:center}:host .wm-search-wrapper .search-icon{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.12rem;position:absolute;left:0.4375rem}:host .wm-search-wrapper input{border:none;height:40px;padding:0 1.75rem;background:var(--wmcolor-search-background);overflow:visible;width:100%;-ms-flex:1;flex:1;font-family:inherit}:host .wm-search-wrapper input:focus{outline:none}:host .wm-search-wrapper.focus{-webkit-box-shadow:0 0 0 1px var(--wmcolor-input-border-focus);-moz-box-shadow:0 0 0 1px var(--wmcolor-input-border-focus);box-shadow:0 0 0 1px var(--wmcolor-input-border-focus);outline:none;border-color:var(--wmcolor-input-border-focus)}:host .find{min-height:3rem}:host .find input{padding:16px 8px 16px 28px}:host .find .wm-find-elements{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:start;justify-content:flex-start;padding-right:16px}:host .find .wm-find-elements wm-button+wm-button{margin-left:0.25rem}:host .find .wm-find-elements .results{margin-right:0.5rem;font-style:italic}:host .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}:host .show-for-tabbers{all:unset;color:var(--wmcolor-search-jump-text);text-decoration:none;font-weight:500;font-size:0.875rem;margin:10px 0}:host .show-for-tabbers:hover{background:-webkit-gradient(linear, left top, left bottom, from(var(--wmcolor-search-jump-text)), to(var(--wmcolor-search-jump-text))) no-repeat;background:linear-gradient(var(--wmcolor-search-jump-text), var(--wmcolor-search-jump-text)) no-repeat;background-size:100% 1px;background-position:0 1.2em;padding-bottom:0.2em}:host .show-for-tabbers:focus{outline:none;background:-webkit-gradient(linear, left top, right top, color-stop(66%, var(--wmcolor-search-jump-text-focus)), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, var(--wmcolor-search-jump-text-focus) 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1.2em;padding-bottom:0.2em}';export{l as wm_search}
1
+ import{r as t,c as s,h as e,H as i,g as o}from"./p-b5bedd63.js";import{t as r,i as n,a}from"./p-f0d87250.js";import{g as h}from"./p-8e001d5e.js";const l=class{constructor(e){t(this,e),this.wmSearchBrowseResults=s(this,"wmSearchBrowseResults",7),this.wmBrowseSearchResults=s(this,"wmBrowseSearchResults",7),this.wmSearchValueChanged=s(this,"wmSearchValueChanged",7),this.wrapperEl=null,this.linkEl=null,this.searchType="basic",this.disabled=!1,this.placeholder="",this.label="",this.numResults=0,this.value="",this.isTabbing=!1,this.highlightedId="",this.highlightedName=null,this.highlightedNum=0,this.previousBlurredValue="",this.parentModal=void 0,this.announcement=""}get isDisabled(){return r(this.disabled)}get resultCount(){let t="";const s=n.formatMessage({id:"search.resultsFound",defaultMessage:"{numResults, plural, =0 {No results} one {1 result} other {# results}} found"},{numResults:this.numResults}),e=n.formatMessage({id:"search.xOfYResults",defaultMessage:"{numResults, plural, =0 {No results found} other {{current} of {numResults} results}}"},{numResults:this.numResults,current:this.highlightedNum});return"basic"===this.searchType?t=s:"find"===this.searchType&&(t=e),t}toggleTabbingOn(){this.isTabbing=!0,this.linkEl&&this.linkEl.classList.remove("sr-only"),this.linkEl&&this.linkEl.classList.add("show-for-tabbers")}toggleTabbingOff(){this.isTabbing=!1,this.linkEl&&this.linkEl.classList.add("sr-only"),this.linkEl&&this.linkEl.classList.remove("show-for-tabbers")}componentWillLoad(){""===this.placeholder&&console.error("You must set the placeholder property for the wm-search component."),""===this.label&&console.error("You must set the label property for the wm-search component."),this.hookToModal(),a(this.el,this.isDisabled)}hookToModal(){let t=this.el;for(;t;)"WM-MODAL"===t.tagName&&(this.parentModal=t),t=t.parentElement;this.parentModal&&["wmCloseTriggered","wmPrimaryTriggered","wmSecondaryTriggered"].map((t=>{this.parentModal.addEventListener(t,(()=>{this.updateValue("")}))}))}async updateValue(t){this.value=t,this.resetHighlightCountToStart()}handleNumResultsUpdate(){this.resetHighlightCountToStart(),this.value&&this.announceChanges()}handleDisabledChange(){a(this.el,this.isDisabled)}resetHighlightCountToStart(){"find"===this.searchType&&(this.highlightedNum=this.numResults?1:0)}announce(t){this.resultsLiveRegion.textContent===t&&(t+=" "),this.announcement=t}announceChanges(){window.requestAnimationFrame((()=>{let t=this.resultCount;"find"===this.searchType&&this.highlightedName&&(t+=`, ${this.highlightedName}`),this.announce(t)}))}changeHighlightedNum(t){this.numResults&&(this.highlightedNum=t<1?this.numResults:t>this.numResults?1:t,this.wmSearchBrowseResults.emit({position:this.highlightedNum}),this.wmBrowseSearchResults.emit({position:this.highlightedNum}),this.announceChanges())}addFocusStyle(){this.wrapperEl&&this.wrapperEl.classList.add("focus")}removeFocusStyle(){this.wrapperEl&&this.wrapperEl.classList.remove("focus")}handleBlur(){this.removeFocusStyle(),this.previousBlurredValue!==this.value&&this.wmSearchValueChanged.emit({value:this.value}),this.previousBlurredValue=this.value}renderResultsAndBrowseButtons(){return e("div",{class:"wm-find-elements"},e("div",{id:"results-display",class:"results"},this.resultCount),e("div",{class:"wm-button-collection"},e("wm-button",{"button-type":"icononly",icon:"f05d",tooltip:h.previous,"tooltip-position":"bottom",onClick:()=>this.changeHighlightedNum(this.highlightedNum-1),disabled:this.isDisabled||this.numResults<2,"label-for-identical-buttons":n.formatMessage({id:"search.previousResult",defaultMessage:"Press to hear previous matching result"})}),e("wm-button",{"button-type":"icononly",icon:"f045",tooltip:h.next,"tooltip-position":"bottom",onClick:()=>this.changeHighlightedNum(this.highlightedNum+1),disabled:this.isDisabled||this.numResults<2,"label-for-identical-buttons":n.formatMessage({id:"search.nextResult",defaultMessage:"Press to hear next matching result"})})))}renderJumpToLink(){return this.numResults&&this.highlightedId?e("a",{ref:t=>this.linkEl=t,href:`#${this.highlightedId}`,class:"sr-only"},n.formatMessage({id:"search.jumpToResult",defaultMessage:"Jump to search result in list"})):null}render(){return e(i,null,e("div",{id:"wm-search-wrapper",class:`wm-search-wrapper ${this.searchType}`,ref:t=>this.wrapperEl=t},e("input",{disabled:this.isDisabled,id:"wm-search-input",placeholder:this.placeholder,"aria-label":`${this.label?this.label+". ":""}${n.formatMessage({id:"search.typeToFilterResults",defaultMessage:"Type to filter the results"})}`,onInput:t=>this.updateValue(t.target.value),onFocus:()=>this.addFocusStyle(),onBlur:()=>this.handleBlur(),"aria-autocomplete":"none",autocomplete:"off",value:this.value}),e("span",{class:"mdi search-icon"},String.fromCodePoint(parseInt("0xf349"))),"find"===this.searchType&&this.renderResultsAndBrowseButtons(),e("div",{id:"wm-search-live",class:"sr-only","aria-live":"polite","aria-atomic":"true",ref:t=>this.resultsLiveRegion=t},this.announcement)),"find"===this.searchType&&this.renderJumpToLink())}static get delegatesFocus(){return!0}get el(){return o(this)}static get watchers(){return{numResults:["handleNumResultsUpdate"],disabled:["handleDisabledChange"]}}};l.style=':host{--wmcolor-search-background:var(--wmcolor-input-background);--wmcolor-search-border:var(--wmcolor-input-border);--wmcolor-search-jump-text-focus:var(--wmcolor-interactive-focus-textonly);--wmcolor-search-jump-text:var(--wmcolor-button-text-textonly);width:100%;font-size:0.875rem}:host *{-webkit-box-sizing:border-box;box-sizing:border-box}:host .wm-search-wrapper{border-radius:3px;position:relative;border:1px solid var(--wmcolor-search-border);display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-align:center;align-items:center}:host .wm-search-wrapper .search-icon{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.12rem;position:absolute;left:0.4375rem}:host .wm-search-wrapper input{border:none;height:40px;padding:0 1.75rem;background:var(--wmcolor-search-background);overflow:visible;width:100%;-ms-flex:1;flex:1;font-family:inherit}:host .wm-search-wrapper input:focus{outline:none}:host .wm-search-wrapper.focus{-webkit-box-shadow:0 0 0 1px var(--wmcolor-input-border-focus);-moz-box-shadow:0 0 0 1px var(--wmcolor-input-border-focus);box-shadow:0 0 0 1px var(--wmcolor-input-border-focus);outline:none;border-color:var(--wmcolor-input-border-focus)}:host .find{min-height:3rem}:host .find input{padding:16px 8px 16px 28px}:host .find .wm-find-elements{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:start;justify-content:flex-start;padding-right:16px}:host .find .wm-find-elements wm-button+wm-button{margin-left:0.25rem}:host .find .wm-find-elements .results{margin-right:0.5rem;font-style:italic}:host .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}:host .show-for-tabbers{all:unset;color:var(--wmcolor-search-jump-text);text-decoration:none;font-weight:500;font-size:0.875rem;margin:10px 0}:host .show-for-tabbers:hover{background:-webkit-gradient(linear, left top, left bottom, from(var(--wmcolor-search-jump-text)), to(var(--wmcolor-search-jump-text))) no-repeat;background:linear-gradient(var(--wmcolor-search-jump-text), var(--wmcolor-search-jump-text)) no-repeat;background-size:100% 1px;background-position:0 1.2em;padding-bottom:0.2em}:host .show-for-tabbers:focus{outline:none;background:-webkit-gradient(linear, left top, right top, color-stop(66%, var(--wmcolor-search-jump-text-focus)), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, var(--wmcolor-search-jump-text-focus) 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1.2em;padding-bottom:0.2em}';export{l as wm_search}
@@ -1 +1 @@
1
- System.register(["./p-30bf24f8.system.js","./p-5e55eb56.system.js","./p-27efb4d0.system.js"],(function(e){"use strict";var t,r,i,a,n,o,s,l,p,h,d,u;return{setters:[function(e){t=e.r;r=e.c;i=e.h;a=e.H;n=e.g},function(e){o=e.i;s=e.t;l=e.g;p=e.a;h=e.b;d=e.j},function(e){u=e.g}],execute:function(){var c=':host{font-family:inherit;width:100%}:host *{-webkit-box-sizing:border-box;box-sizing:border-box}:host .wrapper{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;font-size:0.875rem}:host .wrapper .label{display:block;line-height:normal;font-weight:600;white-space:nowrap;margin-bottom:0.25rem}:host .wrapper .label .required{color:var(--wmcolor-text-required)}:host .wrapper.label-left{-ms-flex-direction:row;flex-direction:row}:host .wrapper.label-left .label-wrapper{line-height:2.5rem}:host .wrapper.label-left .label-wrapper .label{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;min-height:2.5rem;white-space:normal;margin-bottom:0;margin-right:0.75rem}:host .wrapper.label-none label{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 .wrapper.invalid .label{color:var(--wmcolor-text-error)}:host .wrapper.invalid .label: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:"\\f026";margin-left:0.3125rem}[dir=RTL] :host .wrapper.invalid .label:after{margin-left:0;margin-right:0.3125rem}:host .wrapper.rtl.label-left .label{margin-right:0;margin-left:0.75rem}:host .wrapper .inner-wrapper{width:100%}:host .wrapper .text-after-wrapper{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-wrap:wrap;flex-wrap:wrap;gap:8px}:host .wrapper .text-after{-ms-flex:0 1 fit-content;flex:0 1 fit-content}:host .wrapper .inputfield-wrapper{height:2.5rem;min-width:6.25rem;border:1px solid var(--wmcolor-input-border);-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;display:-ms-flexbox;display:flex}:host .wrapper .inputfield-wrapper.disabled{background-color:var(--wmcolor-input-background-disabled);color:var(--wmcolor-input-text-disabled)}:host .wrapper .inputfield-wrapper.disabled .symbol{background:none}:host .wrapper .symbol{display:-ms-flexbox;display:flex;background-color:var(--wmcolor-input-unit-background);-ms-flex:0 0 44px;flex:0 0 44px;padding-inline:8px;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center}:host .wrapper .character-count{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;min-width:5rem;background-color:var(--wmcolor-input-charcount-background);font-size:0.875rem;font-weight:500;-ms-flex-item-align:stretch;align-self:stretch}:host .wrapper input{-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;border:none;font-family:inherit;font-size:0.875rem;height:100%;-ms-flex:1;flex:1;padding:0.75rem 1rem;width:100%}:host .wrapper input:focus{outline:none}:host .wrapper input[type=number]{padding-right:0}:host .wrapper .info{font-style:italic;line-height:100%;margin:4px 0}:host .wrapper.invalid .inputfield-wrapper{-webkit-box-shadow:0 0 0 1px var(--wmcolor-input-border-error);-moz-box-shadow:0 0 0 1px var(--wmcolor-input-border-error);box-shadow:0 0 0 1px var(--wmcolor-input-border-error);border-color:var(--wmcolor-input-border-error)}:host .wrapper.invalid .error-message{display:block;font-style:italic;color:var(--wmcolor-text-error);font-size:0.875rem;margin-top:0.25rem;line-height:100%}:host .wrapper:focus .inputfield-wrapper,:host .wrapper.focus .inputfield-wrapper{-webkit-box-shadow:0 0 0 1px var(--wmcolor-input-border-focus);-moz-box-shadow:0 0 0 1px var(--wmcolor-input-border-focus);box-shadow:0 0 0 1px var(--wmcolor-input-border-focus);outline:none;border-color:var(--wmcolor-input-border-focus)}:host .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 f=e("wm_input",function(){function e(e){t(this,e);this.wmInputValueChanged=r(this,"wmInputValueChanged",7);this.uid="";this.previousBlurredValue="";this.numberErrorMessage=o.formatMessage({id:"input.numberError",defaultMessage:"Please enter a valid number."});this.label=undefined;this.labelPosition="top";this.value="";this.disabled=false;this.info=undefined;this.inputWidth="";this.placeholder="";this.requiredField=false;this.requiredFieldMessage=undefined;this.errorMessage=undefined;this.characterLimit=undefined;this.symbolBefore=undefined;this.symbolAfter=undefined;this.textAfter=undefined;this.preventValidation=undefined;this.type="text";this.step=1;this.min=undefined;this.max=undefined;this.isSubmit=false;this.announcement="";this.displayedErrorMessage=""}e.prototype.getInputWidth=function(){return this.inputWidth?{width:this.inputWidth}:{flex:"1"}};Object.defineProperty(e.prototype,"charCount",{get:function(){return this.value.length},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"isDisabled",{get:function(){return s(this.disabled)},enumerable:false,configurable:true});e.prototype.componentWillLoad=function(){this.uid=this.el.id?this.el.id:l();if(!this.label){console.error("wm-input requires the label property")}p(this.el,this.isDisabled)};e.prototype.componentDidLoad=function(){if(this.value){this.inputEl.value=this.value;this.previousBlurredValue=this.inputEl.value}};e.prototype.handleErrorMessage=function(e){this.displayedErrorMessage=e};e.prototype.handleDisabledChange=function(){p(this.el,this.isDisabled)};e.prototype.handleKeyDown=function(e){var t=e.ctrlKey||e.metaKey||e.altKey;var r=/^.$/.test(e.key)&&!t;var i=r&&this.characterLimit&&this.inputEl.value.length>=this.characterLimit;if(i){this.announce(this.generateCharacterLimitWarning(this.charCount,this.characterLimit))}if(e.key==="Enter"){this.isSubmit&&h(this.el.closest("form"))}};e.prototype.handleBlur=function(e){if(this.value!==this.previousBlurredValue){this.wmInputValueChanged.emit({value:this.value})}this.previousBlurredValue=this.value;var t=this.preventValidation&&d(e,this.preventValidation);if(!t){this.displayedErrorMessage=this.validate()}this.inputWrapperEl.classList.remove("focus")};e.prototype.handleInput=function(e){this.value=e.target.value;if(this.characterLimit&&this.charCount>=this.characterLimit-5){this.announce(this.generateCharacterLimitWarning(this.charCount,this.characterLimit))}};e.prototype.handleFocus=function(){this.inputWrapperEl.classList.add("focus")};e.prototype.validate=function(){var e=[this.validateNumber.bind(this),this.validateRequired.bind(this)];if(this.errorMessage){return this.errorMessage}else{return e.reduce((function(e,t){return e?e:t()}),"")}};e.prototype.validateRequired=function(){var e=this.requiredFieldMessage||u.requiredError;return this.requiredField&&this.value===""?e:""};e.prototype.validateNumber=function(){return this.type==="number"&&this.inputEl.validity.badInput?this.numberErrorMessage:""};e.prototype.announce=function(e){if(this.liveRegionEl.textContent===e){e+=" "}this.announcement=e};e.prototype.generateCharacterLimitWarning=function(e,t){var r=u.getCharactersEntered(e,t);if(e>=t){r+=" ".concat(u.characterLimitReached)}return r};e.prototype.descriptors=function(){return this.symbolBefore||this.symbolAfter||this.textAfter?"symbol-before-".concat(this.uid," inputfield-").concat(this.uid," symbol-after-").concat(this.uid," text-after-").concat(this.uid," info-").concat(this.uid," error-").concat(this.uid):"info-".concat(this.uid," error-").concat(this.uid)};e.prototype.renderErrorMessage=function(){return this.errorMessage||this.displayedErrorMessage};e.prototype.render=function(){var e=this;return i(a,{id:this.uid},i("div",{class:"wrapper label-".concat(this.labelPosition," ").concat(this.errorMessage||this.displayedErrorMessage?"invalid":""),ref:function(t){return e.inputWrapperEl=t}},i("div",{class:"label-wrapper"},i("label",{htmlFor:"inputfield-".concat(this.uid),class:"label"},this.label,this.characterLimit&&i("span",{class:"sr-only"}," ",u.getCharacterLimit(this.characterLimit)),this.requiredField&&i("span",{class:"required","aria-hidden":"true"},"*"))),i("div",{class:"inner-wrapper"},i("div",{class:"text-after-wrapper"},i("div",{class:"inputfield-wrapper ".concat(this.isDisabled?"disabled":""),style:this.getInputWidth()},this.symbolBefore&&i("span",{class:"symbol",id:"symbol-before-".concat(this.uid)},this.symbolBefore),i("input",{ref:function(t){return e.inputEl=t},id:"inputfield-".concat(this.uid),disabled:this.isDisabled,"aria-describedby":this.descriptors(),onInput:function(t){return e.handleInput(t)},onKeyDown:function(t){return e.handleKeyDown(t)},onBlur:function(t){return e.handleBlur(t)},onFocus:this.handleFocus.bind(this),placeholder:this.placeholder,autocomplete:"off","aria-required":this.requiredField?"true":null,maxLength:this.characterLimit||undefined,type:this.type,step:this.step,max:this.max,min:this.min}),this.symbolAfter&&i("span",{class:"symbol",id:"symbol-after-".concat(this.uid)},this.symbolAfter),this.characterLimit&&typeof this.characterLimit==="number"?i("div",{class:"character-count"},this.charCount,"/",this.characterLimit):""),this.textAfter&&i("span",{class:"text-after",id:"text-after-".concat(this.uid)},this.textAfter)),this.info&&i("div",{id:"info-".concat(this.uid),class:"info"},this.info),i("div",{id:"error-".concat(this.uid),"aria-live":"assertive",class:"error-message","aria-atomic":"true"},this.renderErrorMessage()),i("div",{class:"sr-only","aria-live":"polite","aria-atomic":"true",ref:function(t){return e.liveRegionEl=t}},this.announcement))))};Object.defineProperty(e,"delegatesFocus",{get:function(){return true},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"el",{get:function(){return n(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{errorMessage:["handleErrorMessage"],disabled:["handleDisabledChange"]}},enumerable:false,configurable:true});return e}());f.style=c}}}));
1
+ System.register(["./p-30bf24f8.system.js","./p-32d973fa.system.js","./p-7471439a.system.js"],(function(e){"use strict";var t,r,i,a,n,o,s,l,p,h,d,u;return{setters:[function(e){t=e.r;r=e.c;i=e.h;a=e.H;n=e.g},function(e){o=e.i;s=e.t;l=e.g;p=e.a;h=e.b;d=e.j},function(e){u=e.g}],execute:function(){var c=':host{font-family:inherit;width:100%}:host *{-webkit-box-sizing:border-box;box-sizing:border-box}:host .wrapper{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;font-size:0.875rem}:host .wrapper .label{display:block;line-height:normal;font-weight:600;white-space:nowrap;margin-bottom:0.25rem}:host .wrapper .label .required{color:var(--wmcolor-text-required)}:host .wrapper.label-left{-ms-flex-direction:row;flex-direction:row}:host .wrapper.label-left .label-wrapper{line-height:2.5rem}:host .wrapper.label-left .label-wrapper .label{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;min-height:2.5rem;white-space:normal;margin-bottom:0;margin-right:0.75rem}:host .wrapper.label-none label{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 .wrapper.invalid .label{color:var(--wmcolor-text-error)}:host .wrapper.invalid .label: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:"\\f026";margin-left:0.3125rem}[dir=RTL] :host .wrapper.invalid .label:after{margin-left:0;margin-right:0.3125rem}:host .wrapper.rtl.label-left .label{margin-right:0;margin-left:0.75rem}:host .wrapper .inner-wrapper{width:100%}:host .wrapper .text-after-wrapper{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-wrap:wrap;flex-wrap:wrap;gap:8px}:host .wrapper .text-after{-ms-flex:0 1 fit-content;flex:0 1 fit-content}:host .wrapper .inputfield-wrapper{height:2.5rem;min-width:6.25rem;border:1px solid var(--wmcolor-input-border);-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;display:-ms-flexbox;display:flex}:host .wrapper .inputfield-wrapper.disabled{background-color:var(--wmcolor-input-background-disabled);color:var(--wmcolor-input-text-disabled)}:host .wrapper .inputfield-wrapper.disabled .symbol{background:none}:host .wrapper .symbol{display:-ms-flexbox;display:flex;background-color:var(--wmcolor-input-unit-background);-ms-flex:0 0 44px;flex:0 0 44px;padding-inline:8px;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center}:host .wrapper .character-count{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;min-width:5rem;background-color:var(--wmcolor-input-charcount-background);font-size:0.875rem;font-weight:500;-ms-flex-item-align:stretch;align-self:stretch}:host .wrapper input{-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;border:none;font-family:inherit;font-size:0.875rem;height:100%;-ms-flex:1;flex:1;padding:0.75rem 1rem;width:100%}:host .wrapper input:focus{outline:none}:host .wrapper input[type=number]{padding-right:0}:host .wrapper .info{font-style:italic;line-height:100%;margin:4px 0}:host .wrapper.invalid .inputfield-wrapper{-webkit-box-shadow:0 0 0 1px var(--wmcolor-input-border-error);-moz-box-shadow:0 0 0 1px var(--wmcolor-input-border-error);box-shadow:0 0 0 1px var(--wmcolor-input-border-error);border-color:var(--wmcolor-input-border-error)}:host .wrapper.invalid .error-message{display:block;font-style:italic;color:var(--wmcolor-text-error);font-size:0.875rem;margin-top:0.25rem;line-height:100%}:host .wrapper:focus .inputfield-wrapper,:host .wrapper.focus .inputfield-wrapper{-webkit-box-shadow:0 0 0 1px var(--wmcolor-input-border-focus);-moz-box-shadow:0 0 0 1px var(--wmcolor-input-border-focus);box-shadow:0 0 0 1px var(--wmcolor-input-border-focus);outline:none;border-color:var(--wmcolor-input-border-focus)}:host .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 f=e("wm_input",function(){function e(e){t(this,e);this.wmInputValueChanged=r(this,"wmInputValueChanged",7);this.uid="";this.previousBlurredValue="";this.numberErrorMessage=o.formatMessage({id:"input.numberError",defaultMessage:"Please enter a valid number."});this.label=undefined;this.labelPosition="top";this.value="";this.disabled=false;this.info=undefined;this.inputWidth="";this.placeholder="";this.requiredField=false;this.requiredFieldMessage=undefined;this.errorMessage=undefined;this.characterLimit=undefined;this.symbolBefore=undefined;this.symbolAfter=undefined;this.textAfter=undefined;this.preventValidation=undefined;this.type="text";this.step=1;this.min=undefined;this.max=undefined;this.isSubmit=false;this.announcement="";this.displayedErrorMessage=""}e.prototype.getInputWidth=function(){return this.inputWidth?{width:this.inputWidth}:{flex:"1"}};Object.defineProperty(e.prototype,"charCount",{get:function(){return this.value.length},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"isDisabled",{get:function(){return s(this.disabled)},enumerable:false,configurable:true});e.prototype.componentWillLoad=function(){this.uid=this.el.id?this.el.id:l();if(!this.label){console.error("wm-input requires the label property")}p(this.el,this.isDisabled)};e.prototype.componentDidLoad=function(){if(this.value){this.inputEl.value=this.value;this.previousBlurredValue=this.inputEl.value}};e.prototype.handleErrorMessage=function(e){this.displayedErrorMessage=e};e.prototype.handleDisabledChange=function(){p(this.el,this.isDisabled)};e.prototype.handleKeyDown=function(e){var t=e.ctrlKey||e.metaKey||e.altKey;var r=/^.$/.test(e.key)&&!t;var i=r&&this.characterLimit&&this.inputEl.value.length>=this.characterLimit;if(i){this.announce(this.generateCharacterLimitWarning(this.charCount,this.characterLimit))}if(e.key==="Enter"){this.isSubmit&&h(this.el.closest("form"))}};e.prototype.handleBlur=function(e){if(this.value!==this.previousBlurredValue){this.wmInputValueChanged.emit({value:this.value})}this.previousBlurredValue=this.value;var t=this.preventValidation&&d(e,this.preventValidation);if(!t){this.displayedErrorMessage=this.validate()}this.inputWrapperEl.classList.remove("focus")};e.prototype.handleInput=function(e){this.value=e.target.value;if(this.characterLimit&&this.charCount>=this.characterLimit-5){this.announce(this.generateCharacterLimitWarning(this.charCount,this.characterLimit))}};e.prototype.handleFocus=function(){this.inputWrapperEl.classList.add("focus")};e.prototype.validate=function(){var e=[this.validateNumber.bind(this),this.validateRequired.bind(this)];if(this.errorMessage){return this.errorMessage}else{return e.reduce((function(e,t){return e?e:t()}),"")}};e.prototype.validateRequired=function(){var e=this.requiredFieldMessage||u.requiredError;return this.requiredField&&this.value===""?e:""};e.prototype.validateNumber=function(){return this.type==="number"&&this.inputEl.validity.badInput?this.numberErrorMessage:""};e.prototype.announce=function(e){if(this.liveRegionEl.textContent===e){e+=" "}this.announcement=e};e.prototype.generateCharacterLimitWarning=function(e,t){var r=u.getCharactersEntered(e,t);if(e>=t){r+=" ".concat(u.characterLimitReached)}return r};e.prototype.descriptors=function(){return this.symbolBefore||this.symbolAfter||this.textAfter?"symbol-before-".concat(this.uid," inputfield-").concat(this.uid," symbol-after-").concat(this.uid," text-after-").concat(this.uid," info-").concat(this.uid," error-").concat(this.uid):"info-".concat(this.uid," error-").concat(this.uid)};e.prototype.renderErrorMessage=function(){return this.errorMessage||this.displayedErrorMessage};e.prototype.render=function(){var e=this;return i(a,{id:this.uid},i("div",{class:"wrapper label-".concat(this.labelPosition," ").concat(this.errorMessage||this.displayedErrorMessage?"invalid":""),ref:function(t){return e.inputWrapperEl=t}},i("div",{class:"label-wrapper"},i("label",{htmlFor:"inputfield-".concat(this.uid),class:"label"},this.label,this.characterLimit&&i("span",{class:"sr-only"}," ",u.getCharacterLimit(this.characterLimit)),this.requiredField&&i("span",{class:"required","aria-hidden":"true"},"*"))),i("div",{class:"inner-wrapper"},i("div",{class:"text-after-wrapper"},i("div",{class:"inputfield-wrapper ".concat(this.isDisabled?"disabled":""),style:this.getInputWidth()},this.symbolBefore&&i("span",{class:"symbol",id:"symbol-before-".concat(this.uid)},this.symbolBefore),i("input",{ref:function(t){return e.inputEl=t},id:"inputfield-".concat(this.uid),disabled:this.isDisabled,"aria-describedby":this.descriptors(),onInput:function(t){return e.handleInput(t)},onKeyDown:function(t){return e.handleKeyDown(t)},onBlur:function(t){return e.handleBlur(t)},onFocus:this.handleFocus.bind(this),placeholder:this.placeholder,autocomplete:"off","aria-required":this.requiredField?"true":null,maxLength:this.characterLimit||undefined,type:this.type,step:this.step,max:this.max,min:this.min}),this.symbolAfter&&i("span",{class:"symbol",id:"symbol-after-".concat(this.uid)},this.symbolAfter),this.characterLimit&&typeof this.characterLimit==="number"?i("div",{class:"character-count"},this.charCount,"/",this.characterLimit):""),this.textAfter&&i("span",{class:"text-after",id:"text-after-".concat(this.uid)},this.textAfter)),this.info&&i("div",{id:"info-".concat(this.uid),class:"info"},this.info),i("div",{id:"error-".concat(this.uid),"aria-live":"assertive",class:"error-message","aria-atomic":"true"},this.renderErrorMessage()),i("div",{class:"sr-only","aria-live":"polite","aria-atomic":"true",ref:function(t){return e.liveRegionEl=t}},this.announcement))))};Object.defineProperty(e,"delegatesFocus",{get:function(){return true},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"el",{get:function(){return n(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{errorMessage:["handleErrorMessage"],disabled:["handleDisabledChange"]}},enumerable:false,configurable:true});return e}());f.style=c}}}));
@@ -1 +1 @@
1
- var __spreadArray=this&&this.__spreadArray||function(e,t,o){if(o||arguments.length===2)for(var a=0,r=t.length,i;a<r;a++){if(i||!(a in t)){if(!i)i=Array.prototype.slice.call(t,0,a);i[a]=t[a]}}return e.concat(i||Array.prototype.slice.call(t))};System.register(["./p-30bf24f8.system.js","./p-5e55eb56.system.js"],(function(e){"use strict";var t,o,a,r,i,n,s,c;return{setters:[function(e){t=e.r;o=e.c;a=e.h;r=e.f;i=e.g},function(e){n=e.i;s=e.o;c=e.E}],execute:function(){var d='.toggle{all:unset;cursor:pointer;padding:0 0.375rem;height:2.375rem;background-color:var(--wmcolor-datepicker-toggle-background);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}.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:var(--wmcolor-datepicker-toggle-icon);padding:0;line-height:2.5rem}.toggle:hover{-webkit-box-shadow:none;box-shadow:none;background:var(--wmcolor-datepicker-toggle-background-hover)}.toggle:disabled{pointer-events:none;-webkit-box-shadow:none;box-shadow:none;background-color:var(--wmcolor-datepicker-toggle-background-disabled)}.toggle:disabled .calendar::after{color:var(--wmcolor-datepicker-toggle-icon-disabled)}[dir=RTL] .toggle{right:auto;left:0}.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 var(--wmcolor-interactive-focus);-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 var(--wmcolor-interactive-focus);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 var(--wmcolor-interactive-focus)}.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);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:var(--wmcolor-datepicker-background)}.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:var(--wmcolor-datepicker-selector-background);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:var(--wmcolor-datepicker-selector-border);color:var(--wmcolor-datepicker-selector-text)}.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;font-size:1.12rem}.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:var(--wmcolor-datepicker-navigation-text);background:var(--wmcolor-datepicker-navigation-background);padding:0;-webkit-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:hover{background-color:var(--wmcolor-datepicker-navigation-background-hover)}.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)}.popup .day-view{min-width:100%}.popup .day-view .date-grid{width:100%;text-align:center;border-collapse:collapse;margin-bottom:0.4375rem;color:var(--wmcolor-datepicker-day-text-outside)}.popup .day-view .date-grid .date-row:first-child .date-cell{margin-top:0.125rem}.popup .day-view .date-grid .date-header{background-color:var(--wmcolor-datepicker-weekdays-background)}.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:var(--wmcolor-datepicker-weekdays-text);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:var(--wmcolor-datepicker-day-background-hover)}.popup .day-view .date-grid .date-cell.current-month{color:var(--wmcolor-datepicker-day-text)}.popup .day-view .date-grid .date-cell.current-month[aria-selected=true]{background-color:var(--wmcolor-datepicker-day-background-selected);color:var(--wmcolor-datepicker-day-text-selected)}.popup .day-view .date-grid .date-cell:active{background-color:var(--wmcolor-datepicker-day-background-selected);color:var(--wmcolor-datepicker-day-text-selected)}.popup .month-view .months{border-top:2px solid;border-top-color:var(--wmcolor-datepicker-month-border);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:var(--wmcolor-datepicker-month-border)}.popup .month-view .month{cursor:pointer;text-align:center;width:100%;height:4rem;line-height:4rem;font-weight:500;color:var(--wmcolor-datepicker-month-text)}.popup .month-view .month:not(:last-child){border-right:2px solid;border-right-color:var(--wmcolor-datepicker-month-border)}.popup .month-view .month:focus{outline:none}.popup .month-view .month:hover{border-right-color:transparent;background-color:var(--wmcolor-datepicker-month-background-hover)}.popup .month-view .month:active,.popup .month-view .month.selected{background-color:var(--wmcolor-datepicker-month-background-selected);color:var(--wmcolor-datepicker-month-text-selected)}.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 var(--wmcolor-interactive-focus);-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 var(--wmcolor-interactive-focus);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 var(--wmcolor-interactive-focus);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 r=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.popupClicked=true;this.buttonClicked=true;this.prevClicked=true;this.nextClicked=true;this.openUp=false;this.calendar_months=[n.formatMessage({id:"date.january",defaultMessage:"January",description:"Month of the year"}),n.formatMessage({id:"date.february",defaultMessage:"February",description:"Month of the year"}),n.formatMessage({id:"date.march",defaultMessage:"March",description:"Month of the year"}),n.formatMessage({id:"date.april",defaultMessage:"April",description:"Month of the year"}),n.formatMessage({id:"date.may",defaultMessage:"May",description:"Month of the year"}),n.formatMessage({id:"date.june",defaultMessage:"June",description:"Month of the year"}),n.formatMessage({id:"date.july",defaultMessage:"July",description:"Month of the year"}),n.formatMessage({id:"date.august",defaultMessage:"August",description:"Month of the year"}),n.formatMessage({id:"date.september",defaultMessage:"September",description:"Month of the year"}),n.formatMessage({id:"date.october",defaultMessage:"October",description:"Month of the year"}),n.formatMessage({id:"date.november",defaultMessage:"November",description:"Month of the year"}),n.formatMessage({id:"date.december",defaultMessage:"December",description:"Month of the year"})];this.weekdays=[n.formatMessage({id:"date.sunday",defaultMessage:"Sunday"}),n.formatMessage({id:"date.monday",defaultMessage:"Monday"}),n.formatMessage({id:"date.tuesday",defaultMessage:"Tuesday"}),n.formatMessage({id:"date.wednesday",defaultMessage:"Wednesday"}),n.formatMessage({id:"date.thursday",defaultMessage:"Thursday"}),n.formatMessage({id:"date.friday",defaultMessage:"Friday"}),n.formatMessage({id:"date.saturday",defaultMessage:"Saturday"})];this.renderCalendarDate=function(e,t){var o=r.removeZeroes(String(e[1]));var i=r.removeZeroes(String(e[2]));var s=o===r.monthInFocus?"current-month":"";var c=e[0]+e[1]+e[2];var d=r.isDateToday(e);return a("div",{role:"gridcell",id:"cell-".concat(c,"-").concat(r.parentId),class:"date-cell ".concat(s),"aria-selected":false,"aria-label":"".concat(d?"".concat(n.formatMessage({id:"date.today",defaultMessage:"today",description:"calendar button"}),", "):"").concat(r.weekdays[t],", ").concat(r.calendar_months[o-1]," ").concat(i,", ").concat(e[0]),onClick:function(e){r.handleTriggeredDate(e.target)},onKeyDown:function(e){return r.trapFocusEnd(e)},"data-month":e[1],"data-year":e[0],onBlur:function(e){return e.stopPropagation()}},i)};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}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;r(this.el);break;case"End":e.preventDefault();this.unfocusCell();this.dayInFocus=this.getMonthDays(this.monthInFocus,this.yearInFocus);r(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 i=(document.activeElement.shadowRoot||document).activeElement;if(i.tagName==="BUTTON"||i.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,r){return o&&t.removeZeroes(e[r]).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 r=this.getMonthFirstDay(e,t);var i=r-1;var n=42-(i+a);n=n>6?n-7:n;var s=this.getPreviousMonth(e,t),c=s.month,d=s.year;var l=this.getNextMonth(e,t),u=l.month,h=l.year;var p=this.getMonthDays(c,d);var f=__spreadArray([],new Array(i).fill("1"),true).map((function(e,t){var a=t+1+(p-i);return[d.toString(),o.zeroPad(c,2),o.zeroPad(a,2)]}));var m=__spreadArray([],new Array(a).fill("1"),true).map((function(a,r){var i=r+1;return[t.toString(),o.zeroPad(e,2),o.zeroPad(i,2)]}));var g=__spreadArray([],new Array(n).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=s(e,this.popupEl.clientHeight,t);if(c(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:n.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":n.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(n.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":n.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,n.formatMessage({id:"date.su",defaultMessage:"Su",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,n.formatMessage({id:"date.mo",defaultMessage:"Mo",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,n.formatMessage({id:"date.tu",defaultMessage:"Tu",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,n.formatMessage({id:"date.we",defaultMessage:"We",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,n.formatMessage({id:"date.th",defaultMessage:"Th",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,n.formatMessage({id:"date.fr",defaultMessage:"Fr",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,n.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":n.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":n.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"},n.formatMessage({id:"date.selectMonth",defaultMessage:"Activate to select a month.",description:"Calendar button"})),a("div",{id:"year-title",class:"sr-only"},n.formatMessage({id:"date.selectYear",defaultMessage:"Activate to select a year.",description:"Calendar button"})),a("div",{id:"application",class:"sr-only"},n.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 i(this)},enumerable:false,configurable:true});return e}());l.style=d}}}));
1
+ var __spreadArray=this&&this.__spreadArray||function(e,t,o){if(o||arguments.length===2)for(var a=0,r=t.length,i;a<r;a++){if(i||!(a in t)){if(!i)i=Array.prototype.slice.call(t,0,a);i[a]=t[a]}}return e.concat(i||Array.prototype.slice.call(t))};System.register(["./p-30bf24f8.system.js","./p-32d973fa.system.js"],(function(e){"use strict";var t,o,a,r,i,n,s,c;return{setters:[function(e){t=e.r;o=e.c;a=e.h;r=e.f;i=e.g},function(e){n=e.i;s=e.o;c=e.E}],execute:function(){var d='.toggle{all:unset;cursor:pointer;padding:0 0.375rem;height:2.375rem;background-color:var(--wmcolor-datepicker-toggle-background);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}.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:var(--wmcolor-datepicker-toggle-icon);padding:0;line-height:2.5rem}.toggle:hover{-webkit-box-shadow:none;box-shadow:none;background:var(--wmcolor-datepicker-toggle-background-hover)}.toggle:disabled{pointer-events:none;-webkit-box-shadow:none;box-shadow:none;background-color:var(--wmcolor-datepicker-toggle-background-disabled)}.toggle:disabled .calendar::after{color:var(--wmcolor-datepicker-toggle-icon-disabled)}[dir=RTL] .toggle{right:auto;left:0}.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 var(--wmcolor-interactive-focus);-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 var(--wmcolor-interactive-focus);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 var(--wmcolor-interactive-focus)}.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);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:var(--wmcolor-datepicker-background)}.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:var(--wmcolor-datepicker-selector-background);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:var(--wmcolor-datepicker-selector-border);color:var(--wmcolor-datepicker-selector-text)}.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;font-size:1.12rem}.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:var(--wmcolor-datepicker-navigation-text);background:var(--wmcolor-datepicker-navigation-background);padding:0;-webkit-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:hover{background-color:var(--wmcolor-datepicker-navigation-background-hover)}.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)}.popup .day-view{min-width:100%}.popup .day-view .date-grid{width:100%;text-align:center;border-collapse:collapse;margin-bottom:0.4375rem;color:var(--wmcolor-datepicker-day-text-outside)}.popup .day-view .date-grid .date-row:first-child .date-cell{margin-top:0.125rem}.popup .day-view .date-grid .date-header{background-color:var(--wmcolor-datepicker-weekdays-background)}.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:var(--wmcolor-datepicker-weekdays-text);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:var(--wmcolor-datepicker-day-background-hover)}.popup .day-view .date-grid .date-cell.current-month{color:var(--wmcolor-datepicker-day-text)}.popup .day-view .date-grid .date-cell.current-month[aria-selected=true]{background-color:var(--wmcolor-datepicker-day-background-selected);color:var(--wmcolor-datepicker-day-text-selected)}.popup .day-view .date-grid .date-cell:active{background-color:var(--wmcolor-datepicker-day-background-selected);color:var(--wmcolor-datepicker-day-text-selected)}.popup .month-view .months{border-top:2px solid;border-top-color:var(--wmcolor-datepicker-month-border);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:var(--wmcolor-datepicker-month-border)}.popup .month-view .month{cursor:pointer;text-align:center;width:100%;height:4rem;line-height:4rem;font-weight:500;color:var(--wmcolor-datepicker-month-text)}.popup .month-view .month:not(:last-child){border-right:2px solid;border-right-color:var(--wmcolor-datepicker-month-border)}.popup .month-view .month:focus{outline:none}.popup .month-view .month:hover{border-right-color:transparent;background-color:var(--wmcolor-datepicker-month-background-hover)}.popup .month-view .month:active,.popup .month-view .month.selected{background-color:var(--wmcolor-datepicker-month-background-selected);color:var(--wmcolor-datepicker-month-text-selected)}.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 var(--wmcolor-interactive-focus);-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 var(--wmcolor-interactive-focus);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 var(--wmcolor-interactive-focus);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 r=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.popupClicked=true;this.buttonClicked=true;this.prevClicked=true;this.nextClicked=true;this.openUp=false;this.calendar_months=[n.formatMessage({id:"date.january",defaultMessage:"January",description:"Month of the year"}),n.formatMessage({id:"date.february",defaultMessage:"February",description:"Month of the year"}),n.formatMessage({id:"date.march",defaultMessage:"March",description:"Month of the year"}),n.formatMessage({id:"date.april",defaultMessage:"April",description:"Month of the year"}),n.formatMessage({id:"date.may",defaultMessage:"May",description:"Month of the year"}),n.formatMessage({id:"date.june",defaultMessage:"June",description:"Month of the year"}),n.formatMessage({id:"date.july",defaultMessage:"July",description:"Month of the year"}),n.formatMessage({id:"date.august",defaultMessage:"August",description:"Month of the year"}),n.formatMessage({id:"date.september",defaultMessage:"September",description:"Month of the year"}),n.formatMessage({id:"date.october",defaultMessage:"October",description:"Month of the year"}),n.formatMessage({id:"date.november",defaultMessage:"November",description:"Month of the year"}),n.formatMessage({id:"date.december",defaultMessage:"December",description:"Month of the year"})];this.weekdays=[n.formatMessage({id:"date.sunday",defaultMessage:"Sunday"}),n.formatMessage({id:"date.monday",defaultMessage:"Monday"}),n.formatMessage({id:"date.tuesday",defaultMessage:"Tuesday"}),n.formatMessage({id:"date.wednesday",defaultMessage:"Wednesday"}),n.formatMessage({id:"date.thursday",defaultMessage:"Thursday"}),n.formatMessage({id:"date.friday",defaultMessage:"Friday"}),n.formatMessage({id:"date.saturday",defaultMessage:"Saturday"})];this.renderCalendarDate=function(e,t){var o=r.removeZeroes(String(e[1]));var i=r.removeZeroes(String(e[2]));var s=o===r.monthInFocus?"current-month":"";var c=e[0]+e[1]+e[2];var d=r.isDateToday(e);return a("div",{role:"gridcell",id:"cell-".concat(c,"-").concat(r.parentId),class:"date-cell ".concat(s),"aria-selected":false,"aria-label":"".concat(d?"".concat(n.formatMessage({id:"date.today",defaultMessage:"today",description:"calendar button"}),", "):"").concat(r.weekdays[t],", ").concat(r.calendar_months[o-1]," ").concat(i,", ").concat(e[0]),onClick:function(e){r.handleTriggeredDate(e.target)},onKeyDown:function(e){return r.trapFocusEnd(e)},"data-month":e[1],"data-year":e[0],onBlur:function(e){return e.stopPropagation()}},i)};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}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;r(this.el);break;case"End":e.preventDefault();this.unfocusCell();this.dayInFocus=this.getMonthDays(this.monthInFocus,this.yearInFocus);r(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 i=(document.activeElement.shadowRoot||document).activeElement;if(i.tagName==="BUTTON"||i.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,r){return o&&t.removeZeroes(e[r]).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 r=this.getMonthFirstDay(e,t);var i=r-1;var n=42-(i+a);n=n>6?n-7:n;var s=this.getPreviousMonth(e,t),c=s.month,d=s.year;var l=this.getNextMonth(e,t),u=l.month,h=l.year;var p=this.getMonthDays(c,d);var f=__spreadArray([],new Array(i).fill("1"),true).map((function(e,t){var a=t+1+(p-i);return[d.toString(),o.zeroPad(c,2),o.zeroPad(a,2)]}));var m=__spreadArray([],new Array(a).fill("1"),true).map((function(a,r){var i=r+1;return[t.toString(),o.zeroPad(e,2),o.zeroPad(i,2)]}));var g=__spreadArray([],new Array(n).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=s(e,this.popupEl.clientHeight,t);if(c(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:n.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":n.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(n.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":n.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,n.formatMessage({id:"date.su",defaultMessage:"Su",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,n.formatMessage({id:"date.mo",defaultMessage:"Mo",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,n.formatMessage({id:"date.tu",defaultMessage:"Tu",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,n.formatMessage({id:"date.we",defaultMessage:"We",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,n.formatMessage({id:"date.th",defaultMessage:"Th",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,n.formatMessage({id:"date.fr",defaultMessage:"Fr",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,n.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":n.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":n.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"},n.formatMessage({id:"date.selectMonth",defaultMessage:"Activate to select a month.",description:"Calendar button"})),a("div",{id:"year-title",class:"sr-only"},n.formatMessage({id:"date.selectYear",defaultMessage:"Activate to select a year.",description:"Calendar button"})),a("div",{id:"application",class:"sr-only"},n.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 i(this)},enumerable:false,configurable:true});return e}());l.style=d}}}));
@@ -1 +1 @@
1
- import{r as t,c as i,h as o,H as e,g as a,f as n}from"./p-b5bedd63.js";import{i as s,z as r,h as c,s as l}from"./p-ff888d78.js";import{g as h}from"./p-cd7cc5c6.js";const g=class{constructor(o){t(this,o),this.wmNavigationStateChanged=i(this,"wmNavigationStateChanged",7),this.mainNavigationMessage=s.formatMessage({id:"navigation.mainNavigation",defaultMessage:"Main",description:"Label describing the site navigation, for screen reader users"}),this.throttledRerender=r((()=>n(this.el)),50),this.open=!1,this.isTabbing=!1}get isCollapsible(){return window.innerWidth<1024}get ariaExpanded(){return this.isCollapsible?this.open.toString():void 0}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}closeOnEscape(t){"Escape"===t.key&&(this.open=!1)}handleWindowResize(){this.throttledRerender()}handleHamburgerClicked(){this.open=!this.open}handleClickOnItem(){this.open=!1}handleStateChange(){this.isCollapsible&&(this.wmNavigationStateChanged.emit(),this.open?this.expand():this.collapse())}componentWillLoad(){document.body.classList.contains("wmcl-user-is-tabbing")&&this.toggleTabbingOn(),this.el.focus=()=>{const t=this.open?this.el.shadowRoot.querySelector(".toggle"):document.querySelector("wm-navigation-hamburger"),i=this.el.querySelector("wm-navigation-item");this.isCollapsible?t.focus():i.focus()},this.isCollapsible&&this.open&&(this.wmNavigationStateChanged.emit(),this.expand())}redirectFocusFromBody(t){"BODY"!==document.activeElement.tagName||t.relatedTarget||this.el.focus()}expand(){document.body.tabIndex=0,document.body.addEventListener("focus",this.redirectFocusFromBody.bind(this),!0),setTimeout((()=>this.toggleEl.focus()),250)}collapse(){document.body.tabIndex=-1,document.body.removeEventListener("focus",this.redirectFocusFromBody.bind(this));const t=document.querySelector("wm-navigation-hamburger");t&&t.focus()}focusLastItem(){const t=this.el.querySelectorAll("wm-navigation-item");Array.from(t).pop().focus()}renderOverlay(){return o("div",{class:"overlay",onClick:()=>{this.open=!1}})}render(){return o(e,{role:"navigation","aria-expanded":this.ariaExpanded,"aria-label":this.mainNavigationMessage},this.open?this.renderOverlay():"",this.isCollapsible&&o("div",{class:"trapfocus",tabindex:this.open?0:void 0,onFocus:()=>this.focusLastItem()}),o("div",{class:"tray"},o("div",{class:"toggle-wrapper"},o("wm-button",{ref:t=>this.toggleEl=t,class:"toggle "+(this.isTabbing?"user-is-tabbing":""),"button-type":"navigational",icon:this.open?"f156":"f35c","icon-size":"2rem",tooltip:this.open?h.close:h.open,"tooltip-position":"right",tabIndex:this.open?void 0:-1,onClick:()=>{this.open=!this.open}})),o("ul",{class:"navlist"},o("slot",null))),this.isCollapsible&&o("div",{class:"trapfocus",tabindex:this.open?0:void 0,onFocus:()=>this.toggleEl.focus()}))}static get delegatesFocus(){return!0}get el(){return a(this)}static get watchers(){return{open:["handleStateChange"]}}};g.style=":host{--wmcolor-navigation-background-hover:var(--wmcolor-interactive-background-hover);--wmcolor-navigation-background-selected:var(--wmcolor-background-selected);--wmcolor-navigation-background:var(--wmcolor-background);--wmcolor-navigation-border-selected:var(--wmcolor-interactive);--wmcolor-navigation-focus:var(--wmcolor-interactive-focus);--wmcolor-navigation-icon-selected:var(--wmcolor-interactive);--wmcolor-navigation-icon:var(--wmcolor-text);--wmcolor-navigation-text-selected:var(--wmcolor-interactive);z-index:10}:host([aria-expanded=true]){z-index:5000}.tray{-webkit-box-shadow:0 0 14px 0 rgba(0, 0, 0, 0.14);-moz-box-shadow:0 0 14px 0 rgba(0, 0, 0, 0.14);box-shadow:0 0 14px 0 rgba(0, 0, 0, 0.14);display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;width:7.5625rem;background-color:var(--wmcolor-navigation-background);overflow-x:hidden;overflow-y:auto;-webkit-overflow-scrolling:touch;font-size:0.875rem;height:100%}.navlist{margin:0;padding:0}.toggle-wrapper{display:none}@media screen and (max-width: 1023px){.tray{-ms-transition:transform 0.33s ease;-webkit-transition:transform 0.33s ease;-moz-transition:transform 0.33s ease;-webkit-transition:-webkit-transform 0.33s ease;transition:-webkit-transform 0.33s ease;transition:transform 0.33s ease;transition:transform 0.33s ease, -webkit-transform 0.33s ease;position:fixed;top:0;bottom:0;left:0;-webkit-transform:translateX(-100%);transform:translateX(-100%)}.tray ul{visibility:hidden}.tray .toggle-wrapper{display:inline-block;min-height:5rem;width:100%;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center}:host([aria-expanded=true]) .tray{-webkit-transform:translateX(0);transform:translateX(0)}:host([aria-expanded=true]) .tray ul{visibility:visible}.overlay{width:100vw;height:100vh;max-width:none;max-height:none;position:fixed !important;top:0;bottom:0;left:0;right:0;-webkit-transform:translate(0%, 0%);transform:translate(0%, 0%);background-color:rgba(25, 25, 25, 0.4);-ms-transition:opacity 0.5s ease-out;-webkit-transition:opacity 0.5s ease-out;-moz-transition:opacity 0.5s ease-out;transition:opacity 0.5s ease-out}}";const d=class{constructor(o){t(this,o),this.wmNavigationHamburgerClicked=i(this,"wmNavigationHamburgerClicked",7),this.showNavMessage=s.formatMessage({id:"navigation.showNavigation",defaultMessage:"Show navigation",description:"For user interface element opening a navigation menu"}),this.navId=void 0,this.isTabbing=!1,this.open=!1}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}handleNavigationStateChanged(t){this.open=t.target.open}componentWillLoad(){document.body.classList.contains("wmcl-user-is-tabbing")&&this.toggleTabbingOn(),this.navId||console.error("wm-navigation-hamburger: nav-id is a required prop")}handleClick(){c(),this.wmNavigationHamburgerClicked.emit()}render(){return o(e,{class:"hamburger "+(this.open?"nav-open":"nav-closed")},o("button",{class:this.isTabbing?"user-is-tabbing":void 0,"aria-expanded":this.open,"aria-controls":this.navId,"aria-label":this.showNavMessage,onMouseEnter:()=>l("right",this.el,this.showNavMessage),onMouseLeave:()=>c(),onFocus:()=>this.isTabbing&&l("right",this.el,this.showNavMessage),onBlur:()=>c(),onClick:()=>this.handleClick()},o("span",{class:"icon"})))}static get delegatesFocus(){return!0}get el(){return a(this)}};d.style='button{--wmcolor-navigation-hamburger-background-hover:var(--wmcolor-interactive-background-hover);--wmcolor-navigation-hamburger-icon:var(--wmcolor-interactive);display:none;width:100%;height:100%;border:none;-webkit-box-shadow:none;box-shadow:none;-webkit-transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1);transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1);background-color:transparent;outline:none;padding:0}button.user-is-tabbing: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 var(--wmcolor-interactive-focus);-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 var(--wmcolor-interactive-focus);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 var(--wmcolor-interactive-focus)}button.user-is-tabbing:focus::-moz-focus-inner{border:0}button:hover{background-color:var(--wmcolor-navigation-hamburger-background-hover)}.icon: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:"\\f35c";font-size:1.5rem;color:var(--wmcolor-navigation-hamburger-icon)}@media screen and (max-width: 1023px){:host{width:3.75rem;height:3.75rem}button{display:initial}}';const m=class{constructor(o){t(this,o),this.wmNavigationItemClicked=i(this,"wmNavigationItemClicked",7),this.href=void 0,this.text=void 0,this.active=void 0,this.isTabbing=!1}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}componentWillLoad(){document.body.classList.contains("wmcl-user-is-tabbing")&&this.toggleTabbingOn()}render(){return o(e,{role:"listitem"},o("a",{class:`link ${this.active?"active":""} ${this.isTabbing?"user-is-tabbing":""}`,href:this.href,onClick:()=>this.wmNavigationItemClicked.emit()},o("div",{class:"icon","aria-hidden":"true"},o("slot",null)),o("div",{class:"text"},this.text)))}static get delegatesFocus(){return!0}get el(){return a(this)}};m.style='.link{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:center;justify-content:center;color:inherit;text-decoration:none;min-height:4.5rem;text-align:center;padding:1.25rem 0.5rem;font-weight:500;outline:none;position:relative;background:var(--wmcolor-navigation-background)}.link:hover{background-color:var(--wmcolor-navigation-background-hover)}.link .icon{font-size:1.375rem;color:var(--wmcolor-navigation-icon)}.link .text{font-size:0.875rem}.link.user-is-tabbing:focus{-webkit-box-shadow:inset 0 2px 2px 0 rgba(244, 243, 246, 0.2), inset 0 2px 2px 0 rgba(0, 0, 0, 0.1), inset 0 0 4px 3px var(--wmcolor-navigation-focus);box-shadow:inset 0 2px 2px 0 rgba(244, 243, 246, 0.2), inset 0 2px 2px 0 rgba(0, 0, 0, 0.1), inset 0 0 4px 3px var(--wmcolor-navigation-focus)}.link.active{background-color:var(--wmcolor-navigation-background-selected)}.link.active:before{content:"";background-color:var(--wmcolor-navigation-border-selected);position:absolute;height:100%;width:5px;left:0}.link.active .text{color:var(--wmcolor-navigation-text-selected)}.link.active .icon{color:var(--wmcolor-navigation-icon-selected)}';export{g as wm_navigation,d as wm_navigation_hamburger,m as wm_navigation_item}
1
+ import{r as t,c as i,h as o,H as e,g as a,f as n}from"./p-b5bedd63.js";import{i as s,z as r,h as c,s as l}from"./p-f0d87250.js";import{g as h}from"./p-8e001d5e.js";const g=class{constructor(o){t(this,o),this.wmNavigationStateChanged=i(this,"wmNavigationStateChanged",7),this.mainNavigationMessage=s.formatMessage({id:"navigation.mainNavigation",defaultMessage:"Main",description:"Label describing the site navigation, for screen reader users"}),this.throttledRerender=r((()=>n(this.el)),50),this.open=!1,this.isTabbing=!1}get isCollapsible(){return window.innerWidth<1024}get ariaExpanded(){return this.isCollapsible?this.open.toString():void 0}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}closeOnEscape(t){"Escape"===t.key&&(this.open=!1)}handleWindowResize(){this.throttledRerender()}handleHamburgerClicked(){this.open=!this.open}handleClickOnItem(){this.open=!1}handleStateChange(){this.isCollapsible&&(this.wmNavigationStateChanged.emit(),this.open?this.expand():this.collapse())}componentWillLoad(){document.body.classList.contains("wmcl-user-is-tabbing")&&this.toggleTabbingOn(),this.el.focus=()=>{const t=this.open?this.el.shadowRoot.querySelector(".toggle"):document.querySelector("wm-navigation-hamburger"),i=this.el.querySelector("wm-navigation-item");this.isCollapsible?t.focus():i.focus()},this.isCollapsible&&this.open&&(this.wmNavigationStateChanged.emit(),this.expand())}redirectFocusFromBody(t){"BODY"!==document.activeElement.tagName||t.relatedTarget||this.el.focus()}expand(){document.body.tabIndex=0,document.body.addEventListener("focus",this.redirectFocusFromBody.bind(this),!0),setTimeout((()=>this.toggleEl.focus()),250)}collapse(){document.body.tabIndex=-1,document.body.removeEventListener("focus",this.redirectFocusFromBody.bind(this));const t=document.querySelector("wm-navigation-hamburger");t&&t.focus()}focusLastItem(){const t=this.el.querySelectorAll("wm-navigation-item");Array.from(t).pop().focus()}renderOverlay(){return o("div",{class:"overlay",onClick:()=>{this.open=!1}})}render(){return o(e,{role:"navigation","aria-expanded":this.ariaExpanded,"aria-label":this.mainNavigationMessage},this.open?this.renderOverlay():"",this.isCollapsible&&o("div",{class:"trapfocus",tabindex:this.open?0:void 0,onFocus:()=>this.focusLastItem()}),o("div",{class:"tray"},o("div",{class:"toggle-wrapper"},o("wm-button",{ref:t=>this.toggleEl=t,class:"toggle "+(this.isTabbing?"user-is-tabbing":""),"button-type":"navigational",icon:this.open?"f156":"f35c","icon-size":"2rem",tooltip:this.open?h.close:h.open,"tooltip-position":"right",tabIndex:this.open?void 0:-1,onClick:()=>{this.open=!this.open}})),o("ul",{class:"navlist"},o("slot",null))),this.isCollapsible&&o("div",{class:"trapfocus",tabindex:this.open?0:void 0,onFocus:()=>this.toggleEl.focus()}))}static get delegatesFocus(){return!0}get el(){return a(this)}static get watchers(){return{open:["handleStateChange"]}}};g.style=":host{--wmcolor-navigation-background-hover:var(--wmcolor-interactive-background-hover);--wmcolor-navigation-background-selected:var(--wmcolor-background-selected);--wmcolor-navigation-background:var(--wmcolor-background);--wmcolor-navigation-border-selected:var(--wmcolor-interactive);--wmcolor-navigation-focus:var(--wmcolor-interactive-focus);--wmcolor-navigation-icon-selected:var(--wmcolor-interactive);--wmcolor-navigation-icon:var(--wmcolor-text);--wmcolor-navigation-text-selected:var(--wmcolor-interactive);z-index:10}:host([aria-expanded=true]){z-index:5000}.tray{-webkit-box-shadow:0 0 14px 0 rgba(0, 0, 0, 0.14);-moz-box-shadow:0 0 14px 0 rgba(0, 0, 0, 0.14);box-shadow:0 0 14px 0 rgba(0, 0, 0, 0.14);display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;width:7.5625rem;background-color:var(--wmcolor-navigation-background);overflow-x:hidden;overflow-y:auto;-webkit-overflow-scrolling:touch;font-size:0.875rem;height:100%}.navlist{margin:0;padding:0}.toggle-wrapper{display:none}@media screen and (max-width: 1023px){.tray{-ms-transition:transform 0.33s ease;-webkit-transition:transform 0.33s ease;-moz-transition:transform 0.33s ease;-webkit-transition:-webkit-transform 0.33s ease;transition:-webkit-transform 0.33s ease;transition:transform 0.33s ease;transition:transform 0.33s ease, -webkit-transform 0.33s ease;position:fixed;top:0;bottom:0;left:0;-webkit-transform:translateX(-100%);transform:translateX(-100%)}.tray ul{visibility:hidden}.tray .toggle-wrapper{display:inline-block;min-height:5rem;width:100%;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center}:host([aria-expanded=true]) .tray{-webkit-transform:translateX(0);transform:translateX(0)}:host([aria-expanded=true]) .tray ul{visibility:visible}.overlay{width:100vw;height:100vh;max-width:none;max-height:none;position:fixed !important;top:0;bottom:0;left:0;right:0;-webkit-transform:translate(0%, 0%);transform:translate(0%, 0%);background-color:rgba(25, 25, 25, 0.4);-ms-transition:opacity 0.5s ease-out;-webkit-transition:opacity 0.5s ease-out;-moz-transition:opacity 0.5s ease-out;transition:opacity 0.5s ease-out}}";const d=class{constructor(o){t(this,o),this.wmNavigationHamburgerClicked=i(this,"wmNavigationHamburgerClicked",7),this.showNavMessage=s.formatMessage({id:"navigation.showNavigation",defaultMessage:"Show navigation",description:"For user interface element opening a navigation menu"}),this.navId=void 0,this.isTabbing=!1,this.open=!1}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}handleNavigationStateChanged(t){this.open=t.target.open}componentWillLoad(){document.body.classList.contains("wmcl-user-is-tabbing")&&this.toggleTabbingOn(),this.navId||console.error("wm-navigation-hamburger: nav-id is a required prop")}handleClick(){c(),this.wmNavigationHamburgerClicked.emit()}render(){return o(e,{class:"hamburger "+(this.open?"nav-open":"nav-closed")},o("button",{class:this.isTabbing?"user-is-tabbing":void 0,"aria-expanded":this.open,"aria-controls":this.navId,"aria-label":this.showNavMessage,onMouseEnter:()=>l("right",this.el,this.showNavMessage),onMouseLeave:()=>c(),onFocus:()=>this.isTabbing&&l("right",this.el,this.showNavMessage),onBlur:()=>c(),onClick:()=>this.handleClick()},o("span",{class:"icon"})))}static get delegatesFocus(){return!0}get el(){return a(this)}};d.style='button{--wmcolor-navigation-hamburger-background-hover:var(--wmcolor-interactive-background-hover);--wmcolor-navigation-hamburger-icon:var(--wmcolor-interactive);display:none;width:100%;height:100%;border:none;-webkit-box-shadow:none;box-shadow:none;-webkit-transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1);transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1);background-color:transparent;outline:none;padding:0}button.user-is-tabbing: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 var(--wmcolor-interactive-focus);-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 var(--wmcolor-interactive-focus);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 var(--wmcolor-interactive-focus)}button.user-is-tabbing:focus::-moz-focus-inner{border:0}button:hover{background-color:var(--wmcolor-navigation-hamburger-background-hover)}.icon: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:"\\f35c";font-size:1.5rem;color:var(--wmcolor-navigation-hamburger-icon)}@media screen and (max-width: 1023px){:host{width:3.75rem;height:3.75rem}button{display:initial}}';const m=class{constructor(o){t(this,o),this.wmNavigationItemClicked=i(this,"wmNavigationItemClicked",7),this.href=void 0,this.text=void 0,this.active=void 0,this.isTabbing=!1}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}componentWillLoad(){document.body.classList.contains("wmcl-user-is-tabbing")&&this.toggleTabbingOn()}render(){return o(e,{role:"listitem"},o("a",{class:`link ${this.active?"active":""} ${this.isTabbing?"user-is-tabbing":""}`,href:this.href,onClick:()=>this.wmNavigationItemClicked.emit()},o("div",{class:"icon","aria-hidden":"true"},o("slot",null)),o("div",{class:"text"},this.text)))}static get delegatesFocus(){return!0}get el(){return a(this)}};m.style='.link{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:center;justify-content:center;color:inherit;text-decoration:none;min-height:4.5rem;text-align:center;padding:1.25rem 0.5rem;font-weight:500;outline:none;position:relative;background:var(--wmcolor-navigation-background)}.link:hover{background-color:var(--wmcolor-navigation-background-hover)}.link .icon{font-size:1.375rem;color:var(--wmcolor-navigation-icon)}.link .text{font-size:0.875rem}.link.user-is-tabbing:focus{-webkit-box-shadow:inset 0 2px 2px 0 rgba(244, 243, 246, 0.2), inset 0 2px 2px 0 rgba(0, 0, 0, 0.1), inset 0 0 4px 3px var(--wmcolor-navigation-focus);box-shadow:inset 0 2px 2px 0 rgba(244, 243, 246, 0.2), inset 0 2px 2px 0 rgba(0, 0, 0, 0.1), inset 0 0 4px 3px var(--wmcolor-navigation-focus)}.link.active{background-color:var(--wmcolor-navigation-background-selected)}.link.active:before{content:"";background-color:var(--wmcolor-navigation-border-selected);position:absolute;height:100%;width:5px;left:0}.link.active .text{color:var(--wmcolor-navigation-text-selected)}.link.active .icon{color:var(--wmcolor-navigation-icon-selected)}';export{g as wm_navigation,d as wm_navigation_hamburger,m as wm_navigation_item}
@@ -1 +1 @@
1
- var __awaiter=this&&this.__awaiter||function(e,t,r,i){function o(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,s){function n(e){try{l(i.next(e))}catch(e){s(e)}}function a(e){try{l(i["throw"](e))}catch(e){s(e)}}function l(e){e.done?r(e.value):o(e.value).then(n,a)}l((i=i.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var r={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},i,o,s,n;return n={next:a(0),throw:a(1),return:a(2)},typeof Symbol==="function"&&(n[Symbol.iterator]=function(){return this}),n;function a(e){return function(t){return l([e,t])}}function l(a){if(i)throw new TypeError("Generator is already executing.");while(n&&(n=0,a[0]&&(r=0)),r)try{if(i=1,o&&(s=a[0]&2?o["return"]:a[0]?o["throw"]||((s=o["return"])&&s.call(o),0):o.next)&&!(s=s.call(o,a[1])).done)return s;if(o=0,s)a=[a[0]&2,s.value];switch(a[0]){case 0:case 1:s=a;break;case 4:r.label++;return{value:a[1],done:false};case 5:r.label++;o=a[1];a=[0];continue;case 7:a=r.ops.pop();r.trys.pop();continue;default:if(!(s=r.trys,s=s.length>0&&s[s.length-1])&&(a[0]===6||a[0]===2)){r=0;continue}if(a[0]===3&&(!s||a[1]>s[0]&&a[1]<s[3])){r.label=a[1];break}if(a[0]===6&&r.label<s[1]){r.label=s[1];s=a;break}if(s&&r.label<s[2]){r.label=s[2];r.ops.push(a);break}if(s[2])r.ops.pop();r.trys.pop();continue}a=t.call(e,r)}catch(e){a=[6,e];o=0}finally{i=s=0}if(a[0]&5)throw a[1];return{value:a[0]?a[1]:void 0,done:true}}};System.register(["./p-30bf24f8.system.js","./p-5e55eb56.system.js","./p-27efb4d0.system.js"],(function(e){"use strict";var t,r,i,o,s,n,a,l,u;return{setters:[function(e){t=e.r;r=e.c;i=e.h;o=e.H;s=e.g},function(e){n=e.t;a=e.i;l=e.a},function(e){u=e.g}],execute:function(){var h=':host{--wmcolor-search-background:var(--wmcolor-input-background);--wmcolor-search-border:var(--wmcolor-input-border);--wmcolor-search-jump-text-focus:var(--wmcolor-interactive-focus-textonly);--wmcolor-search-jump-text:var(--wmcolor-button-text-textonly);width:100%;font-size:0.875rem}:host *{-webkit-box-sizing:border-box;box-sizing:border-box}:host .wm-search-wrapper{border-radius:3px;position:relative;border:1px solid var(--wmcolor-search-border);display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-align:center;align-items:center}:host .wm-search-wrapper .search-icon{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.12rem;position:absolute;left:0.4375rem}:host .wm-search-wrapper input{border:none;height:40px;padding:0 1.75rem;background:var(--wmcolor-search-background);overflow:visible;width:100%;-ms-flex:1;flex:1;font-family:inherit}:host .wm-search-wrapper input:focus{outline:none}:host .wm-search-wrapper.focus{-webkit-box-shadow:0 0 0 1px var(--wmcolor-input-border-focus);-moz-box-shadow:0 0 0 1px var(--wmcolor-input-border-focus);box-shadow:0 0 0 1px var(--wmcolor-input-border-focus);outline:none;border-color:var(--wmcolor-input-border-focus)}:host .find{min-height:3rem}:host .find input{padding:16px 8px 16px 28px}:host .find .wm-find-elements{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:start;justify-content:flex-start;padding-right:16px}:host .find .wm-find-elements wm-button+wm-button{margin-left:0.25rem}:host .find .wm-find-elements .results{margin-right:0.5rem;font-style:italic}:host .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}:host .show-for-tabbers{all:unset;color:var(--wmcolor-search-jump-text);text-decoration:none;font-weight:500;font-size:0.875rem;margin:10px 0}:host .show-for-tabbers:hover{background:-webkit-gradient(linear, left top, left bottom, from(var(--wmcolor-search-jump-text)), to(var(--wmcolor-search-jump-text))) no-repeat;background:linear-gradient(var(--wmcolor-search-jump-text), var(--wmcolor-search-jump-text)) no-repeat;background-size:100% 1px;background-position:0 1.2em;padding-bottom:0.2em}:host .show-for-tabbers:focus{outline:none;background:-webkit-gradient(linear, left top, right top, color-stop(66%, var(--wmcolor-search-jump-text-focus)), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, var(--wmcolor-search-jump-text-focus) 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1.2em;padding-bottom:0.2em}';var c=e("wm_search",function(){function e(e){t(this,e);this.wmSearchBrowseResults=r(this,"wmSearchBrowseResults",7);this.wmBrowseSearchResults=r(this,"wmBrowseSearchResults",7);this.wmSearchValueChanged=r(this,"wmSearchValueChanged",7);this.wrapperEl=null;this.linkEl=null;this.searchType="basic";this.disabled=false;this.placeholder="";this.label="";this.numResults=0;this.value="";this.isTabbing=false;this.highlightedId="";this.highlightedName=null;this.highlightedNum=0;this.previousBlurredValue="";this.parentModal=undefined;this.announcement=""}Object.defineProperty(e.prototype,"isDisabled",{get:function(){return n(this.disabled)},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"resultCount",{get:function(){var e="";var t=a.formatMessage({id:"search.resultsFound",defaultMessage:"{numResults, plural, =0 {No results} one {1 result} other {# results}} found"},{numResults:this.numResults});var r=a.formatMessage({id:"search.xOfYResults",defaultMessage:"{numResults, plural, =0 {No results found} other {{current} of {numResults} results}}"},{numResults:this.numResults,current:this.highlightedNum});if(this.searchType==="basic"){e=t}else if(this.searchType==="find"){e=r}return e},enumerable:false,configurable:true});e.prototype.toggleTabbingOn=function(){this.isTabbing=true;this.linkEl&&this.linkEl.classList.remove("sr-only");this.linkEl&&this.linkEl.classList.add("show-for-tabbers")};e.prototype.toggleTabbingOff=function(){this.isTabbing=false;this.linkEl&&this.linkEl.classList.add("sr-only");this.linkEl&&this.linkEl.classList.remove("show-for-tabbers")};e.prototype.componentWillLoad=function(){if(this.placeholder===""){console.error("You must set the placeholder property for the wm-search component.")}if(this.label===""){console.error("You must set the label property for the wm-search component.")}this.hookToModal();l(this.el,this.isDisabled)};e.prototype.hookToModal=function(){var e=this;var t=this.el;while(!!t){if(t.tagName==="WM-MODAL"){this.parentModal=t}t=t.parentElement}if(this.parentModal){var r=["wmCloseTriggered","wmPrimaryTriggered","wmSecondaryTriggered"];r.map((function(t){e.parentModal.addEventListener(t,(function(){e.updateValue("")}))}))}};e.prototype.updateValue=function(e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.value=e;this.resetHighlightCountToStart();return[2]}))}))};e.prototype.handleNumResultsUpdate=function(){this.resetHighlightCountToStart();if(this.value){this.announceChanges()}};e.prototype.handleDisabledChange=function(){l(this.el,this.isDisabled)};e.prototype.resetHighlightCountToStart=function(){if(this.searchType==="find"){this.highlightedNum=this.numResults?1:0}};e.prototype.announce=function(e){if(this.resultsLiveRegion.textContent===e){e+=" "}this.announcement=e};e.prototype.announceChanges=function(){var e=this;window.requestAnimationFrame((function(){var t=e.resultCount;if(e.searchType==="find"&&e.highlightedName){t+=", ".concat(e.highlightedName)}e.announce(t)}))};e.prototype.changeHighlightedNum=function(e){if(this.numResults){if(e<1){this.highlightedNum=this.numResults}else if(e>this.numResults){this.highlightedNum=1}else{this.highlightedNum=e}this.wmSearchBrowseResults.emit({position:this.highlightedNum});this.wmBrowseSearchResults.emit({position:this.highlightedNum});this.announceChanges()}};e.prototype.addFocusStyle=function(){if(this.wrapperEl){this.wrapperEl.classList.add("focus")}};e.prototype.removeFocusStyle=function(){if(this.wrapperEl){this.wrapperEl.classList.remove("focus")}};e.prototype.handleBlur=function(){this.removeFocusStyle();if(this.previousBlurredValue!==this.value){this.wmSearchValueChanged.emit({value:this.value})}this.previousBlurredValue=this.value};e.prototype.renderResultsAndBrowseButtons=function(){var e=this;return i("div",{class:"wm-find-elements"},i("div",{id:"results-display",class:"results"},this.resultCount),i("div",{class:"wm-button-collection"},i("wm-button",{"button-type":"icononly",icon:"f05d",tooltip:u.previous,"tooltip-position":"bottom",onClick:function(){return e.changeHighlightedNum(e.highlightedNum-1)},disabled:this.isDisabled||this.numResults<2,"label-for-identical-buttons":a.formatMessage({id:"search.previousResult",defaultMessage:"Press to hear previous matching result"})}),i("wm-button",{"button-type":"icononly",icon:"f045",tooltip:u.next,"tooltip-position":"bottom",onClick:function(){return e.changeHighlightedNum(e.highlightedNum+1)},disabled:this.isDisabled||this.numResults<2,"label-for-identical-buttons":a.formatMessage({id:"search.nextResult",defaultMessage:"Press to hear next matching result"})})))};e.prototype.renderJumpToLink=function(){var e=this;if(this.numResults&&this.highlightedId){return i("a",{ref:function(t){return e.linkEl=t},href:"#".concat(this.highlightedId),class:"sr-only"},a.formatMessage({id:"search.jumpToResult",defaultMessage:"Jump to search result in list"}))}else{return null}};e.prototype.render=function(){var e=this;return i(o,null,i("div",{id:"wm-search-wrapper",class:"wm-search-wrapper ".concat(this.searchType),ref:function(t){return e.wrapperEl=t}},i("input",{disabled:this.isDisabled,id:"wm-search-input",placeholder:this.placeholder,"aria-label":"".concat(this.label?this.label+". ":"").concat(a.formatMessage({id:"search.typeToFilterResults",defaultMessage:"Type to filter the results"})),onInput:function(t){return e.updateValue(t.target.value)},onFocus:function(){return e.addFocusStyle()},onBlur:function(){return e.handleBlur()},"aria-autocomplete":"none",autocomplete:"off",value:this.value}),i("span",{class:"mdi search-icon"},String.fromCodePoint(parseInt("0xf349"))),this.searchType==="find"&&this.renderResultsAndBrowseButtons(),i("div",{id:"wm-search-live",class:"sr-only","aria-live":"polite","aria-atomic":"true",ref:function(t){return e.resultsLiveRegion=t}},this.announcement)),this.searchType==="find"&&this.renderJumpToLink())};Object.defineProperty(e,"delegatesFocus",{get:function(){return true},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"el",{get:function(){return s(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{numResults:["handleNumResultsUpdate"],disabled:["handleDisabledChange"]}},enumerable:false,configurable:true});return e}());c.style=h}}}));
1
+ var __awaiter=this&&this.__awaiter||function(e,t,r,i){function o(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,s){function n(e){try{l(i.next(e))}catch(e){s(e)}}function a(e){try{l(i["throw"](e))}catch(e){s(e)}}function l(e){e.done?r(e.value):o(e.value).then(n,a)}l((i=i.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var r={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},i,o,s,n;return n={next:a(0),throw:a(1),return:a(2)},typeof Symbol==="function"&&(n[Symbol.iterator]=function(){return this}),n;function a(e){return function(t){return l([e,t])}}function l(a){if(i)throw new TypeError("Generator is already executing.");while(n&&(n=0,a[0]&&(r=0)),r)try{if(i=1,o&&(s=a[0]&2?o["return"]:a[0]?o["throw"]||((s=o["return"])&&s.call(o),0):o.next)&&!(s=s.call(o,a[1])).done)return s;if(o=0,s)a=[a[0]&2,s.value];switch(a[0]){case 0:case 1:s=a;break;case 4:r.label++;return{value:a[1],done:false};case 5:r.label++;o=a[1];a=[0];continue;case 7:a=r.ops.pop();r.trys.pop();continue;default:if(!(s=r.trys,s=s.length>0&&s[s.length-1])&&(a[0]===6||a[0]===2)){r=0;continue}if(a[0]===3&&(!s||a[1]>s[0]&&a[1]<s[3])){r.label=a[1];break}if(a[0]===6&&r.label<s[1]){r.label=s[1];s=a;break}if(s&&r.label<s[2]){r.label=s[2];r.ops.push(a);break}if(s[2])r.ops.pop();r.trys.pop();continue}a=t.call(e,r)}catch(e){a=[6,e];o=0}finally{i=s=0}if(a[0]&5)throw a[1];return{value:a[0]?a[1]:void 0,done:true}}};System.register(["./p-30bf24f8.system.js","./p-32d973fa.system.js","./p-7471439a.system.js"],(function(e){"use strict";var t,r,i,o,s,n,a,l,u;return{setters:[function(e){t=e.r;r=e.c;i=e.h;o=e.H;s=e.g},function(e){n=e.t;a=e.i;l=e.a},function(e){u=e.g}],execute:function(){var h=':host{--wmcolor-search-background:var(--wmcolor-input-background);--wmcolor-search-border:var(--wmcolor-input-border);--wmcolor-search-jump-text-focus:var(--wmcolor-interactive-focus-textonly);--wmcolor-search-jump-text:var(--wmcolor-button-text-textonly);width:100%;font-size:0.875rem}:host *{-webkit-box-sizing:border-box;box-sizing:border-box}:host .wm-search-wrapper{border-radius:3px;position:relative;border:1px solid var(--wmcolor-search-border);display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-align:center;align-items:center}:host .wm-search-wrapper .search-icon{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.12rem;position:absolute;left:0.4375rem}:host .wm-search-wrapper input{border:none;height:40px;padding:0 1.75rem;background:var(--wmcolor-search-background);overflow:visible;width:100%;-ms-flex:1;flex:1;font-family:inherit}:host .wm-search-wrapper input:focus{outline:none}:host .wm-search-wrapper.focus{-webkit-box-shadow:0 0 0 1px var(--wmcolor-input-border-focus);-moz-box-shadow:0 0 0 1px var(--wmcolor-input-border-focus);box-shadow:0 0 0 1px var(--wmcolor-input-border-focus);outline:none;border-color:var(--wmcolor-input-border-focus)}:host .find{min-height:3rem}:host .find input{padding:16px 8px 16px 28px}:host .find .wm-find-elements{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:start;justify-content:flex-start;padding-right:16px}:host .find .wm-find-elements wm-button+wm-button{margin-left:0.25rem}:host .find .wm-find-elements .results{margin-right:0.5rem;font-style:italic}:host .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}:host .show-for-tabbers{all:unset;color:var(--wmcolor-search-jump-text);text-decoration:none;font-weight:500;font-size:0.875rem;margin:10px 0}:host .show-for-tabbers:hover{background:-webkit-gradient(linear, left top, left bottom, from(var(--wmcolor-search-jump-text)), to(var(--wmcolor-search-jump-text))) no-repeat;background:linear-gradient(var(--wmcolor-search-jump-text), var(--wmcolor-search-jump-text)) no-repeat;background-size:100% 1px;background-position:0 1.2em;padding-bottom:0.2em}:host .show-for-tabbers:focus{outline:none;background:-webkit-gradient(linear, left top, right top, color-stop(66%, var(--wmcolor-search-jump-text-focus)), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, var(--wmcolor-search-jump-text-focus) 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1.2em;padding-bottom:0.2em}';var c=e("wm_search",function(){function e(e){t(this,e);this.wmSearchBrowseResults=r(this,"wmSearchBrowseResults",7);this.wmBrowseSearchResults=r(this,"wmBrowseSearchResults",7);this.wmSearchValueChanged=r(this,"wmSearchValueChanged",7);this.wrapperEl=null;this.linkEl=null;this.searchType="basic";this.disabled=false;this.placeholder="";this.label="";this.numResults=0;this.value="";this.isTabbing=false;this.highlightedId="";this.highlightedName=null;this.highlightedNum=0;this.previousBlurredValue="";this.parentModal=undefined;this.announcement=""}Object.defineProperty(e.prototype,"isDisabled",{get:function(){return n(this.disabled)},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"resultCount",{get:function(){var e="";var t=a.formatMessage({id:"search.resultsFound",defaultMessage:"{numResults, plural, =0 {No results} one {1 result} other {# results}} found"},{numResults:this.numResults});var r=a.formatMessage({id:"search.xOfYResults",defaultMessage:"{numResults, plural, =0 {No results found} other {{current} of {numResults} results}}"},{numResults:this.numResults,current:this.highlightedNum});if(this.searchType==="basic"){e=t}else if(this.searchType==="find"){e=r}return e},enumerable:false,configurable:true});e.prototype.toggleTabbingOn=function(){this.isTabbing=true;this.linkEl&&this.linkEl.classList.remove("sr-only");this.linkEl&&this.linkEl.classList.add("show-for-tabbers")};e.prototype.toggleTabbingOff=function(){this.isTabbing=false;this.linkEl&&this.linkEl.classList.add("sr-only");this.linkEl&&this.linkEl.classList.remove("show-for-tabbers")};e.prototype.componentWillLoad=function(){if(this.placeholder===""){console.error("You must set the placeholder property for the wm-search component.")}if(this.label===""){console.error("You must set the label property for the wm-search component.")}this.hookToModal();l(this.el,this.isDisabled)};e.prototype.hookToModal=function(){var e=this;var t=this.el;while(!!t){if(t.tagName==="WM-MODAL"){this.parentModal=t}t=t.parentElement}if(this.parentModal){var r=["wmCloseTriggered","wmPrimaryTriggered","wmSecondaryTriggered"];r.map((function(t){e.parentModal.addEventListener(t,(function(){e.updateValue("")}))}))}};e.prototype.updateValue=function(e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.value=e;this.resetHighlightCountToStart();return[2]}))}))};e.prototype.handleNumResultsUpdate=function(){this.resetHighlightCountToStart();if(this.value){this.announceChanges()}};e.prototype.handleDisabledChange=function(){l(this.el,this.isDisabled)};e.prototype.resetHighlightCountToStart=function(){if(this.searchType==="find"){this.highlightedNum=this.numResults?1:0}};e.prototype.announce=function(e){if(this.resultsLiveRegion.textContent===e){e+=" "}this.announcement=e};e.prototype.announceChanges=function(){var e=this;window.requestAnimationFrame((function(){var t=e.resultCount;if(e.searchType==="find"&&e.highlightedName){t+=", ".concat(e.highlightedName)}e.announce(t)}))};e.prototype.changeHighlightedNum=function(e){if(this.numResults){if(e<1){this.highlightedNum=this.numResults}else if(e>this.numResults){this.highlightedNum=1}else{this.highlightedNum=e}this.wmSearchBrowseResults.emit({position:this.highlightedNum});this.wmBrowseSearchResults.emit({position:this.highlightedNum});this.announceChanges()}};e.prototype.addFocusStyle=function(){if(this.wrapperEl){this.wrapperEl.classList.add("focus")}};e.prototype.removeFocusStyle=function(){if(this.wrapperEl){this.wrapperEl.classList.remove("focus")}};e.prototype.handleBlur=function(){this.removeFocusStyle();if(this.previousBlurredValue!==this.value){this.wmSearchValueChanged.emit({value:this.value})}this.previousBlurredValue=this.value};e.prototype.renderResultsAndBrowseButtons=function(){var e=this;return i("div",{class:"wm-find-elements"},i("div",{id:"results-display",class:"results"},this.resultCount),i("div",{class:"wm-button-collection"},i("wm-button",{"button-type":"icononly",icon:"f05d",tooltip:u.previous,"tooltip-position":"bottom",onClick:function(){return e.changeHighlightedNum(e.highlightedNum-1)},disabled:this.isDisabled||this.numResults<2,"label-for-identical-buttons":a.formatMessage({id:"search.previousResult",defaultMessage:"Press to hear previous matching result"})}),i("wm-button",{"button-type":"icononly",icon:"f045",tooltip:u.next,"tooltip-position":"bottom",onClick:function(){return e.changeHighlightedNum(e.highlightedNum+1)},disabled:this.isDisabled||this.numResults<2,"label-for-identical-buttons":a.formatMessage({id:"search.nextResult",defaultMessage:"Press to hear next matching result"})})))};e.prototype.renderJumpToLink=function(){var e=this;if(this.numResults&&this.highlightedId){return i("a",{ref:function(t){return e.linkEl=t},href:"#".concat(this.highlightedId),class:"sr-only"},a.formatMessage({id:"search.jumpToResult",defaultMessage:"Jump to search result in list"}))}else{return null}};e.prototype.render=function(){var e=this;return i(o,null,i("div",{id:"wm-search-wrapper",class:"wm-search-wrapper ".concat(this.searchType),ref:function(t){return e.wrapperEl=t}},i("input",{disabled:this.isDisabled,id:"wm-search-input",placeholder:this.placeholder,"aria-label":"".concat(this.label?this.label+". ":"").concat(a.formatMessage({id:"search.typeToFilterResults",defaultMessage:"Type to filter the results"})),onInput:function(t){return e.updateValue(t.target.value)},onFocus:function(){return e.addFocusStyle()},onBlur:function(){return e.handleBlur()},"aria-autocomplete":"none",autocomplete:"off",value:this.value}),i("span",{class:"mdi search-icon"},String.fromCodePoint(parseInt("0xf349"))),this.searchType==="find"&&this.renderResultsAndBrowseButtons(),i("div",{id:"wm-search-live",class:"sr-only","aria-live":"polite","aria-atomic":"true",ref:function(t){return e.resultsLiveRegion=t}},this.announcement)),this.searchType==="find"&&this.renderJumpToLink())};Object.defineProperty(e,"delegatesFocus",{get:function(){return true},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"el",{get:function(){return s(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{numResults:["handleNumResultsUpdate"],disabled:["handleDisabledChange"]}},enumerable:false,configurable:true});return e}());c.style=h}}}));
@@ -1 +1 @@
1
- System.register(["./p-30bf24f8.system.js","./p-5e55eb56.system.js"],(function(t){"use strict";var e,i,n,a,o,r,s,l;return{setters:[function(t){e=t.r;i=t.c;n=t.h;a=t.H;o=t.g;r=t.f},function(t){s=t.d;l=t.g}],execute:function(){var b=":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:var(--wmcolor-tab-text);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:var(--wmcolor-tab-text-ondark)}: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:var(--wmcolor-tab-text-ondark)}: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 var(--wmcolor-interactive-focus);-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 var(--wmcolor-interactive-focus);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 var(--wmcolor-interactive-focus)}:host .tab-item .tab.user-is-tabbing:focus:not(:active)::-moz-focus-inner{border:0}:host .tab-item .tab.user-is-tabbing:focus:not(:active).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 var(--wmcolor-interactive-focus-ondark);-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 var(--wmcolor-interactive-focus-ondark);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 var(--wmcolor-interactive-focus-ondark);outline:none}:host.hide{display:none}";var c=t("wm_tab_item",function(){function t(t){var n=this;e(this,t);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.tabClicked=function(t){t.preventDefault();n.wmTabSelected.emit({tabId:n.tabId});n.tabSelected.emit({tabId:n.tabId})};this.tabPressed=function(t){var e=t.key;if(e==="Enter"||e===" "){t.preventDefault();n.wmTabSelected.emit({tabId:n.tabId});n.tabSelected.emit({tabId:n.tabId})}else if(e.includes("Arrow")){t.preventDefault();n.keydownOnTabItem.emit({tabItem:n.el,key:t.key})}};this.selected=false;this.show=true;this.tabId=""}Object.defineProperty(t.prototype,"parentTabList",{get:function(){return this.el.parentElement},enumerable:false,configurable:true});t.prototype.toggleTabbingOn=function(){this.linkEl&&this.linkEl.classList.add("user-is-tabbing")};t.prototype.toggleTabbingOff=function(){this.linkEl&&this.linkEl.classList.remove("user-is-tabbing")};t.prototype.componentDidLoad=function(){this.tabItemLoaded.emit()};t.prototype.render=function(){var t=this;var e=this.show?"":"hide ";e+=this.parentTabList&&this.parentTabList.customBackground=="dark"?"dark":"";var i={};var o=this.parentTabList&&this.parentTabList.customPadding;if(o){var r=parseInt(o,10)*2||0;var s=o.split(/([0-9]+)/).pop();i={"padding-left":this.parentTabList.customPadding,"padding-right":this.parentTabList.customPadding,"background-size":"calc(100% - ".concat(r).concat(s,") 3px")}}return n(a,{role:"presentation"},n("li",{class:"tab-item",role:"presentation"},n("a",{class:"tab ".concat(e),style:i,role:"tab",ref:function(e){return t.linkEl=e},onClick:this.tabClicked,id:"tab-link-".concat(this.tabId),onKeyDown:function(e){return t.tabPressed(e)},"aria-selected":this.selected?"true":"false",tabindex:this.selected?0:-1},n("slot",null))))};Object.defineProperty(t,"delegatesFocus",{get:function(){return true},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"el",{get:function(){return o(this)},enumerable:false,configurable:true});return t}());c.style=b;var d=":host{--wmcolor-tab-background:var(--wmcolor-background-transparent);--wmcolor-tab-background-dark:var(--wmcolor-background-dark);--wmcolor-tab-text-ondark:var(--wmcolor-interactive-ondark);--wmcolor-tab-text:var(--wmcolor-interactive);position:relative;white-space:nowrap;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;display:block}:host *{-webkit-box-sizing:border-box;box-sizing:border-box}:host .tabcontainer{background:var(--wmcolor-tab-background);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{background:var(--wmcolor-tab-background-dark);margin:0}:host wm-select{padding:0.375rem 0}";var u=t("wm_tab_list",function(){function t(t){var n=this;e(this,t);this.wmTabSelected=i(this,"wmTabSelected",7);this.tabSelected=i(this,"tabSelected",7);this.debouncedSetLayout=s((function(){if(!n.listWidth){n.setListWidth()}r(n.el)}),250);this.customBackground=undefined;this.customPadding=undefined;this.selectedTab=undefined;this.controllerEnabled=false}Object.defineProperty(t.prototype,"menuLayout",{get:function(){if(this.listWidth){return this.el.offsetWidth<this.listWidth-24}else{return false}},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"tabItems",{get:function(){return Array.from(this.el.querySelectorAll("wm-tab-item"))},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"selectedTabItem",{get:function(){return this.tabItems.filter((function(t){return t.selected}))[0]},enumerable:false,configurable:true});t.prototype.getLinkEl=function(t){return t.shadowRoot.querySelector("a")};Object.defineProperty(t.prototype,"panels",{get:function(){var t=Array.from(document.querySelectorAll("wm-tab-panel"));var e=this.tabItems.map((function(t){return t.tabId}));return t.filter((function(t){return e.includes(t.tabId)}))},enumerable:false,configurable:true});t.prototype.getPanel=function(t){return this.panels.find((function(e){return e.tabId===t}))};t.prototype.setListWidth=function(){var t=this.tabItems.reduce((function(t,e){return t+e.offsetWidth}),0);this.listWidth=t&&t>0?t:this.listWidth};t.prototype.setSelected=function(t){this.tabItems.map((function(e){return e.selected=e.tabId===t}));var e=this.panels.length===1&&this.tabItems.length>1;if(e){this.setAttributesOnPanel(this.panels[0],this.selectedTabItem);this.panels[0].active=true}else{this.panels.map((function(e){return e.active=e.tabId===t}))}};t.prototype.showItems=function(){this.tabItems.map((function(t){return t.show=true}))};t.prototype.hideItems=function(){this.tabItems.map((function(t){return t.show=false}))};t.prototype.componentWillLoad=function(){var t=this;this.el.focus=function(){t.selectedTabItem&&t.selectedTabItem.focus()}};t.prototype.componentDidLoad=function(){this.setLayout();var t=this.selectedTab||this.tabItems[0].tabId;this.setSelected(t)};t.prototype.tabItemLoaded=function(t){this.setAriaOnPanelAndTab(t.target)};t.prototype.setAriaOnPanelAndTab=function(t){var e=this.getPanel(t.tabId);if(!e){if(this.panels.length===1){this.setAttributesOnTab(t,this.panels[0])}}else{this.setAttributesOnPanel(e,t);this.setAttributesOnTab(t,e)}};t.prototype.setAttributesOnTab=function(t,e){var i=this.getLinkEl(t);if(i){i.setAttribute("aria-controls",e.id);i.setAttribute("href","#".concat(e.id))}};t.prototype.removeAttributesOnTab=function(t){var e=this.getLinkEl(t);if(e){e.removeAttribute("aria-controls");e.removeAttribute("href")}};t.prototype.setAttributesOnPanel=function(t,e){var i=this.getLinkEl(e);if(i){t.setAttribute("aria-labelledby",i.id);t.setAttribute("tab-id",e.tabId)}};t.prototype.handleTabSelected=function(t){if(this.controllerEnabled){this.setSelected(t.detail.tabId)}};t.prototype.handleKeydown=function(t){var e=t.detail.key;var i=this.tabItems.indexOf(t.detail.tabItem);if(e==="ArrowLeft"||e==="ArrowRight"){this.handleLeftRightArrow(i,e)}};t.prototype.handleLeftRightArrow=function(t,e){if(e){t=e==="ArrowLeft"?t-1:t+1}if(t<0){t=this.tabItems.length-1}else if(t===this.tabItems.length){t=0}var i=this.tabItems[t];this.getLinkEl(i).focus()};t.prototype.setLayout=function(){this.debouncedSetLayout()};t.prototype.renderMenuOrTabs=function(){if(this.menuLayout){this.hideItems();return n("wm-select",{label:"Tab Selection","label-position":"none"},this.renderOptions())}else{this.showItems();var t={};if(this.customPadding){t={"margin-left":"-"+this.customPadding}}return n("ul",{class:"tabcontainer ".concat(this.customBackground||""),style:t,role:"tablist"},n("slot",null))}};t.prototype.renderOptions=function(){var t=this;return this.tabItems.map((function(e){return n("wm-option",{id:"tab-link-".concat(e.tabId),selected:e.tabId===t.selectedTab,onClick:function(i){i.preventDefault();t.wmTabSelected.emit({tabId:e.tabId});t.tabSelected.emit({tabId:e.tabId})}},e.textContent)}))};t.prototype.render=function(){return n(a,{class:this.menuLayout?"menu":""},this.renderMenuOrTabs())};Object.defineProperty(t,"delegatesFocus",{get:function(){return true},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"el",{get:function(){return o(this)},enumerable:false,configurable:true});Object.defineProperty(t,"watchers",{get:function(){return{selectedTab:["setSelected"]}},enumerable:false,configurable:true});return t}());u.style=d;var p="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}";var h=t("wm_tab_panel",function(){function t(t){e(this,t);this.tabPanelLoaded=i(this,"tabPanelLoaded",7);this.active=false;this.tabId=""}t.prototype.componentWillLoad=function(){!this.el.id&&this.el.setAttribute("id",l())};t.prototype.componentDidLoad=function(){this.tabPanelLoaded.emit({tabId:this.tabId})};t.prototype.toggleTabbingOn=function(){this.el.classList.add("user-is-tabbing")};t.prototype.toggleTabbingOff=function(){this.el.classList.remove("user-is-tabbing")};t.prototype.render=function(){return n(a,{role:"tabpanel",class:{"tab-hidden":!this.active}})};Object.defineProperty(t.prototype,"el",{get:function(){return o(this)},enumerable:false,configurable:true});return t}());h.style=p}}}));
1
+ System.register(["./p-30bf24f8.system.js","./p-32d973fa.system.js"],(function(t){"use strict";var e,i,n,a,o,r,s,l;return{setters:[function(t){e=t.r;i=t.c;n=t.h;a=t.H;o=t.g;r=t.f},function(t){s=t.d;l=t.g}],execute:function(){var b=":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:var(--wmcolor-tab-text);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:var(--wmcolor-tab-text-ondark)}: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:var(--wmcolor-tab-text-ondark)}: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 var(--wmcolor-interactive-focus);-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 var(--wmcolor-interactive-focus);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 var(--wmcolor-interactive-focus)}:host .tab-item .tab.user-is-tabbing:focus:not(:active)::-moz-focus-inner{border:0}:host .tab-item .tab.user-is-tabbing:focus:not(:active).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 var(--wmcolor-interactive-focus-ondark);-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 var(--wmcolor-interactive-focus-ondark);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 var(--wmcolor-interactive-focus-ondark);outline:none}:host.hide{display:none}";var c=t("wm_tab_item",function(){function t(t){var n=this;e(this,t);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.tabClicked=function(t){t.preventDefault();n.wmTabSelected.emit({tabId:n.tabId});n.tabSelected.emit({tabId:n.tabId})};this.tabPressed=function(t){var e=t.key;if(e==="Enter"||e===" "){t.preventDefault();n.wmTabSelected.emit({tabId:n.tabId});n.tabSelected.emit({tabId:n.tabId})}else if(e.includes("Arrow")){t.preventDefault();n.keydownOnTabItem.emit({tabItem:n.el,key:t.key})}};this.selected=false;this.show=true;this.tabId=""}Object.defineProperty(t.prototype,"parentTabList",{get:function(){return this.el.parentElement},enumerable:false,configurable:true});t.prototype.toggleTabbingOn=function(){this.linkEl&&this.linkEl.classList.add("user-is-tabbing")};t.prototype.toggleTabbingOff=function(){this.linkEl&&this.linkEl.classList.remove("user-is-tabbing")};t.prototype.componentDidLoad=function(){this.tabItemLoaded.emit()};t.prototype.render=function(){var t=this;var e=this.show?"":"hide ";e+=this.parentTabList&&this.parentTabList.customBackground=="dark"?"dark":"";var i={};var o=this.parentTabList&&this.parentTabList.customPadding;if(o){var r=parseInt(o,10)*2||0;var s=o.split(/([0-9]+)/).pop();i={"padding-left":this.parentTabList.customPadding,"padding-right":this.parentTabList.customPadding,"background-size":"calc(100% - ".concat(r).concat(s,") 3px")}}return n(a,{role:"presentation"},n("li",{class:"tab-item",role:"presentation"},n("a",{class:"tab ".concat(e),style:i,role:"tab",ref:function(e){return t.linkEl=e},onClick:this.tabClicked,id:"tab-link-".concat(this.tabId),onKeyDown:function(e){return t.tabPressed(e)},"aria-selected":this.selected?"true":"false",tabindex:this.selected?0:-1},n("slot",null))))};Object.defineProperty(t,"delegatesFocus",{get:function(){return true},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"el",{get:function(){return o(this)},enumerable:false,configurable:true});return t}());c.style=b;var d=":host{--wmcolor-tab-background:var(--wmcolor-background-transparent);--wmcolor-tab-background-dark:var(--wmcolor-background-dark);--wmcolor-tab-text-ondark:var(--wmcolor-interactive-ondark);--wmcolor-tab-text:var(--wmcolor-interactive);position:relative;white-space:nowrap;height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;display:block}:host *{-webkit-box-sizing:border-box;box-sizing:border-box}:host .tabcontainer{background:var(--wmcolor-tab-background);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{background:var(--wmcolor-tab-background-dark);margin:0}:host wm-select{padding:0.375rem 0}";var u=t("wm_tab_list",function(){function t(t){var n=this;e(this,t);this.wmTabSelected=i(this,"wmTabSelected",7);this.tabSelected=i(this,"tabSelected",7);this.debouncedSetLayout=s((function(){if(!n.listWidth){n.setListWidth()}r(n.el)}),250);this.customBackground=undefined;this.customPadding=undefined;this.selectedTab=undefined;this.controllerEnabled=false}Object.defineProperty(t.prototype,"menuLayout",{get:function(){if(this.listWidth){return this.el.offsetWidth<this.listWidth-24}else{return false}},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"tabItems",{get:function(){return Array.from(this.el.querySelectorAll("wm-tab-item"))},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"selectedTabItem",{get:function(){return this.tabItems.filter((function(t){return t.selected}))[0]},enumerable:false,configurable:true});t.prototype.getLinkEl=function(t){return t.shadowRoot.querySelector("a")};Object.defineProperty(t.prototype,"panels",{get:function(){var t=Array.from(document.querySelectorAll("wm-tab-panel"));var e=this.tabItems.map((function(t){return t.tabId}));return t.filter((function(t){return e.includes(t.tabId)}))},enumerable:false,configurable:true});t.prototype.getPanel=function(t){return this.panels.find((function(e){return e.tabId===t}))};t.prototype.setListWidth=function(){var t=this.tabItems.reduce((function(t,e){return t+e.offsetWidth}),0);this.listWidth=t&&t>0?t:this.listWidth};t.prototype.setSelected=function(t){this.tabItems.map((function(e){return e.selected=e.tabId===t}));var e=this.panels.length===1&&this.tabItems.length>1;if(e){this.setAttributesOnPanel(this.panels[0],this.selectedTabItem);this.panels[0].active=true}else{this.panels.map((function(e){return e.active=e.tabId===t}))}};t.prototype.showItems=function(){this.tabItems.map((function(t){return t.show=true}))};t.prototype.hideItems=function(){this.tabItems.map((function(t){return t.show=false}))};t.prototype.componentWillLoad=function(){var t=this;this.el.focus=function(){t.selectedTabItem&&t.selectedTabItem.focus()}};t.prototype.componentDidLoad=function(){this.setLayout();var t=this.selectedTab||this.tabItems[0].tabId;this.setSelected(t)};t.prototype.tabItemLoaded=function(t){this.setAriaOnPanelAndTab(t.target)};t.prototype.setAriaOnPanelAndTab=function(t){var e=this.getPanel(t.tabId);if(!e){if(this.panels.length===1){this.setAttributesOnTab(t,this.panels[0])}}else{this.setAttributesOnPanel(e,t);this.setAttributesOnTab(t,e)}};t.prototype.setAttributesOnTab=function(t,e){var i=this.getLinkEl(t);if(i){i.setAttribute("aria-controls",e.id);i.setAttribute("href","#".concat(e.id))}};t.prototype.removeAttributesOnTab=function(t){var e=this.getLinkEl(t);if(e){e.removeAttribute("aria-controls");e.removeAttribute("href")}};t.prototype.setAttributesOnPanel=function(t,e){var i=this.getLinkEl(e);if(i){t.setAttribute("aria-labelledby",i.id);t.setAttribute("tab-id",e.tabId)}};t.prototype.handleTabSelected=function(t){if(this.controllerEnabled){this.setSelected(t.detail.tabId)}};t.prototype.handleKeydown=function(t){var e=t.detail.key;var i=this.tabItems.indexOf(t.detail.tabItem);if(e==="ArrowLeft"||e==="ArrowRight"){this.handleLeftRightArrow(i,e)}};t.prototype.handleLeftRightArrow=function(t,e){if(e){t=e==="ArrowLeft"?t-1:t+1}if(t<0){t=this.tabItems.length-1}else if(t===this.tabItems.length){t=0}var i=this.tabItems[t];this.getLinkEl(i).focus()};t.prototype.setLayout=function(){this.debouncedSetLayout()};t.prototype.renderMenuOrTabs=function(){if(this.menuLayout){this.hideItems();return n("wm-select",{label:"Tab Selection","label-position":"none"},this.renderOptions())}else{this.showItems();var t={};if(this.customPadding){t={"margin-left":"-"+this.customPadding}}return n("ul",{class:"tabcontainer ".concat(this.customBackground||""),style:t,role:"tablist"},n("slot",null))}};t.prototype.renderOptions=function(){var t=this;return this.tabItems.map((function(e){return n("wm-option",{id:"tab-link-".concat(e.tabId),selected:e.tabId===t.selectedTab,onClick:function(i){i.preventDefault();t.wmTabSelected.emit({tabId:e.tabId});t.tabSelected.emit({tabId:e.tabId})}},e.textContent)}))};t.prototype.render=function(){return n(a,{class:this.menuLayout?"menu":""},this.renderMenuOrTabs())};Object.defineProperty(t,"delegatesFocus",{get:function(){return true},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"el",{get:function(){return o(this)},enumerable:false,configurable:true});Object.defineProperty(t,"watchers",{get:function(){return{selectedTab:["setSelected"]}},enumerable:false,configurable:true});return t}());u.style=d;var p="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}";var h=t("wm_tab_panel",function(){function t(t){e(this,t);this.tabPanelLoaded=i(this,"tabPanelLoaded",7);this.active=false;this.tabId=""}t.prototype.componentWillLoad=function(){!this.el.id&&this.el.setAttribute("id",l())};t.prototype.componentDidLoad=function(){this.tabPanelLoaded.emit({tabId:this.tabId})};t.prototype.toggleTabbingOn=function(){this.el.classList.add("user-is-tabbing")};t.prototype.toggleTabbingOff=function(){this.el.classList.remove("user-is-tabbing")};t.prototype.render=function(){return n(a,{role:"tabpanel",class:{"tab-hidden":!this.active}})};Object.defineProperty(t.prototype,"el",{get:function(){return o(this)},enumerable:false,configurable:true});return t}());h.style=p}}}));