@watermarkinsights/ripple 3.12.0 → 3.13.0-9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (176) hide show
  1. package/dist/cjs/{chartFunctions-44ae2eee.js → chartFunctions-34fdd3ce.js} +1 -1
  2. package/dist/cjs/{functions-1a67b971.js → functions-120449cf.js} +245 -32
  3. package/dist/cjs/{global-122fc638.js → global-1d1d0ab3.js} +7 -5
  4. package/dist/cjs/loader.cjs.js +2 -2
  5. package/dist/cjs/priv-chart-popover.cjs.entry.js +1 -1
  6. package/dist/cjs/priv-datepicker.cjs.entry.js +1 -1
  7. package/dist/cjs/ripple.cjs.js +2 -2
  8. package/dist/cjs/wm-action-menu_2.cjs.entry.js +1 -1
  9. package/dist/cjs/wm-button.cjs.entry.js +50 -38
  10. package/dist/cjs/wm-chart.cjs.entry.js +2 -2
  11. package/dist/cjs/wm-datepicker.cjs.entry.js +1 -1
  12. package/dist/cjs/wm-input.cjs.entry.js +1 -1
  13. package/dist/cjs/wm-modal-footer.cjs.entry.js +1 -1
  14. package/dist/cjs/wm-modal-header.cjs.entry.js +1 -1
  15. package/dist/cjs/wm-modal.cjs.entry.js +1 -1
  16. package/dist/cjs/wm-navigation_3.cjs.entry.js +1 -1
  17. package/dist/cjs/wm-navigator.cjs.entry.js +1 -1
  18. package/dist/cjs/wm-network-uploader.cjs.entry.js +6 -4
  19. package/dist/cjs/wm-option_2.cjs.entry.js +345 -122
  20. package/dist/cjs/wm-pagination.cjs.entry.js +1 -1
  21. package/dist/cjs/wm-progress-indicator_3.cjs.entry.js +2 -2
  22. package/dist/cjs/wm-search.cjs.entry.js +1 -1
  23. package/dist/cjs/wm-snackbar.cjs.entry.js +1 -1
  24. package/dist/cjs/wm-tab-item_3.cjs.entry.js +1 -1
  25. package/dist/cjs/wm-tag-input.cjs.entry.js +1 -1
  26. package/dist/cjs/wm-timepicker.cjs.entry.js +1 -1
  27. package/dist/cjs/wm-toggletip.cjs.entry.js +4 -4
  28. package/dist/cjs/wm-uploader.cjs.entry.js +9 -11
  29. package/dist/collection/components/wm-button/wm-button.css +1 -0
  30. package/dist/collection/components/wm-button/wm-button.js +50 -40
  31. package/dist/collection/components/wm-modal/wm-modal-footer.js +1 -1
  32. package/dist/collection/components/wm-option/wm-option.css +12 -0
  33. package/dist/collection/components/wm-option/wm-option.js +34 -29
  34. package/dist/collection/components/wm-select/wm-select.css +76 -23
  35. package/dist/collection/components/wm-select/wm-select.js +385 -125
  36. package/dist/collection/components/wm-toggletip/wm-toggletip.js +5 -5
  37. package/dist/collection/components/wm-uploader/wm-network-uploader/wm-network-uploader.css +0 -3
  38. package/dist/collection/components/wm-uploader/wm-network-uploader/wm-network-uploader.js +4 -2
  39. package/dist/collection/components/wm-uploader/wm-uploader.css +1 -5
  40. package/dist/collection/components/wm-uploader/wm-uploader.js +7 -9
  41. package/dist/collection/global/__mocks__/functions.js +9 -0
  42. package/dist/collection/global/functions.js +1 -28
  43. package/dist/collection/global/global.js +6 -4
  44. package/dist/esm/{chartFunctions-8fa800a6.js → chartFunctions-20f05eb5.js} +1 -1
  45. package/dist/esm/{functions-61c7bb1f.js → functions-036af8dc.js} +245 -32
  46. package/dist/esm/{global-5902ef31.js → global-590c515d.js} +7 -5
  47. package/dist/esm/loader.js +2 -2
  48. package/dist/esm/priv-chart-popover.entry.js +1 -1
  49. package/dist/esm/priv-datepicker.entry.js +1 -1
  50. package/dist/esm/ripple.js +2 -2
  51. package/dist/esm/wm-action-menu_2.entry.js +1 -1
  52. package/dist/esm/wm-button.entry.js +51 -39
  53. package/dist/esm/wm-chart.entry.js +2 -2
  54. package/dist/esm/wm-datepicker.entry.js +1 -1
  55. package/dist/esm/wm-input.entry.js +1 -1
  56. package/dist/esm/wm-modal-footer.entry.js +1 -1
  57. package/dist/esm/wm-modal-header.entry.js +1 -1
  58. package/dist/esm/wm-modal.entry.js +1 -1
  59. package/dist/esm/wm-navigation_3.entry.js +1 -1
  60. package/dist/esm/wm-navigator.entry.js +1 -1
  61. package/dist/esm/wm-network-uploader.entry.js +6 -4
  62. package/dist/esm/wm-option_2.entry.js +345 -122
  63. package/dist/esm/wm-pagination.entry.js +1 -1
  64. package/dist/esm/wm-progress-indicator_3.entry.js +2 -2
  65. package/dist/esm/wm-search.entry.js +1 -1
  66. package/dist/esm/wm-snackbar.entry.js +1 -1
  67. package/dist/esm/wm-tab-item_3.entry.js +1 -1
  68. package/dist/esm/wm-tag-input.entry.js +1 -1
  69. package/dist/esm/wm-timepicker.entry.js +1 -1
  70. package/dist/esm/wm-toggletip.entry.js +4 -4
  71. package/dist/esm/wm-uploader.entry.js +9 -11
  72. package/dist/esm-es5/{chartFunctions-8fa800a6.js → chartFunctions-20f05eb5.js} +1 -1
  73. package/dist/esm-es5/{functions-61c7bb1f.js → functions-036af8dc.js} +2 -2
  74. package/dist/esm-es5/global-590c515d.js +1 -0
  75. package/dist/esm-es5/loader.js +1 -1
  76. package/dist/esm-es5/priv-chart-popover.entry.js +1 -1
  77. package/dist/esm-es5/priv-datepicker.entry.js +1 -1
  78. package/dist/esm-es5/ripple.js +1 -1
  79. package/dist/esm-es5/wm-action-menu_2.entry.js +1 -1
  80. package/dist/esm-es5/wm-button.entry.js +1 -1
  81. package/dist/esm-es5/wm-chart.entry.js +1 -1
  82. package/dist/esm-es5/wm-datepicker.entry.js +1 -1
  83. package/dist/esm-es5/wm-input.entry.js +1 -1
  84. package/dist/esm-es5/wm-modal-footer.entry.js +1 -1
  85. package/dist/esm-es5/wm-modal-header.entry.js +1 -1
  86. package/dist/esm-es5/wm-modal.entry.js +1 -1
  87. package/dist/esm-es5/wm-navigation_3.entry.js +1 -1
  88. package/dist/esm-es5/wm-navigator.entry.js +1 -1
  89. package/dist/esm-es5/wm-network-uploader.entry.js +1 -1
  90. package/dist/esm-es5/wm-option_2.entry.js +1 -1
  91. package/dist/esm-es5/wm-pagination.entry.js +1 -1
  92. package/dist/esm-es5/wm-progress-indicator_3.entry.js +1 -1
  93. package/dist/esm-es5/wm-search.entry.js +1 -1
  94. package/dist/esm-es5/wm-snackbar.entry.js +1 -1
  95. package/dist/esm-es5/wm-tab-item_3.entry.js +1 -1
  96. package/dist/esm-es5/wm-tag-input.entry.js +1 -1
  97. package/dist/esm-es5/wm-timepicker.entry.js +1 -1
  98. package/dist/esm-es5/wm-toggletip.entry.js +1 -1
  99. package/dist/esm-es5/wm-uploader.entry.js +1 -1
  100. package/dist/ripple/{p-28bf6a2e.system.js → p-04d8b674.system.js} +1 -1
  101. package/dist/ripple/{p-d3ed8b65.system.entry.js → p-04e44b30.system.entry.js} +1 -1
  102. package/dist/ripple/{p-fdc4a599.system.entry.js → p-0556279c.system.entry.js} +1 -1
  103. package/dist/ripple/{p-1242752c.system.entry.js → p-06adbeb9.system.entry.js} +1 -1
  104. package/dist/ripple/{p-42aa51fe.system.entry.js → p-0e9ccc6f.system.entry.js} +1 -1
  105. package/dist/ripple/{p-520b0f54.entry.js → p-17ceb8c1.entry.js} +1 -1
  106. package/dist/ripple/{p-8caae464.entry.js → p-1887286e.entry.js} +1 -1
  107. package/dist/ripple/{p-c873b490.system.entry.js → p-1ccd994d.system.entry.js} +1 -1
  108. package/dist/ripple/p-1d795f42.entry.js +1 -0
  109. package/dist/ripple/p-2996bfe6.entry.js +1 -0
  110. package/dist/ripple/{p-30745db6.entry.js → p-2f860b24.entry.js} +1 -1
  111. package/dist/ripple/p-3489b502.js +1 -0
  112. package/dist/ripple/{p-cd4fda75.entry.js → p-3680b55d.entry.js} +1 -1
  113. package/dist/ripple/p-3745c620.system.js +1 -0
  114. package/dist/ripple/{p-f12a510f.entry.js → p-3a1d6fc4.entry.js} +1 -1
  115. package/dist/ripple/p-42337590.entry.js +1 -0
  116. package/dist/ripple/{p-68155230.system.entry.js → p-49fd7ede.system.entry.js} +1 -1
  117. package/dist/ripple/{p-8aa9f811.js → p-4ecd3430.js} +1 -1
  118. package/dist/ripple/{p-5471864e.system.entry.js → p-62eac2d6.system.entry.js} +1 -1
  119. package/dist/ripple/{p-5e041c35.entry.js → p-6aa6a818.entry.js} +1 -1
  120. package/dist/ripple/{p-487f7419.system.entry.js → p-6bf5cbf4.system.entry.js} +1 -1
  121. package/dist/ripple/{p-e180001c.system.entry.js → p-7173b0a7.system.entry.js} +1 -1
  122. package/dist/ripple/p-726c979a.system.js +15 -0
  123. package/dist/ripple/{p-eacd33cc.system.entry.js → p-752da0fb.system.entry.js} +1 -1
  124. package/dist/ripple/{p-f36b74bf.entry.js → p-7ae1a630.entry.js} +1 -1
  125. package/dist/ripple/{p-8d347cd5.entry.js → p-7ecbf258.entry.js} +1 -1
  126. package/dist/ripple/{p-75ef731b.system.entry.js → p-7ef6a7cf.system.entry.js} +1 -1
  127. package/dist/ripple/p-8612829b.system.entry.js +1 -0
  128. package/dist/ripple/{p-398b2486.system.entry.js → p-895f5ec5.system.entry.js} +1 -1
  129. package/dist/ripple/{p-d3603def.entry.js → p-8de546e8.entry.js} +1 -1
  130. package/dist/ripple/{p-35cfcf9f.entry.js → p-93dee724.entry.js} +1 -1
  131. package/dist/ripple/{p-0f33461d.entry.js → p-97c2b06f.entry.js} +1 -1
  132. package/dist/ripple/{p-9f12284b.system.entry.js → p-995ba16f.system.entry.js} +1 -1
  133. package/dist/ripple/p-9c92c93f.entry.js +1 -0
  134. package/dist/ripple/p-9e09d7a1.entry.js +1 -0
  135. package/dist/ripple/{p-f0656464.entry.js → p-a04ba6c8.entry.js} +1 -1
  136. package/dist/ripple/{p-44035b02.system.entry.js → p-af3ce4fc.system.entry.js} +1 -1
  137. package/dist/ripple/p-bbcafbd6.system.entry.js +1 -0
  138. package/dist/ripple/{p-eee347b4.system.entry.js → p-c1443a0e.system.entry.js} +1 -1
  139. package/dist/ripple/{p-212aac05.system.entry.js → p-ca383a43.system.entry.js} +1 -1
  140. package/dist/ripple/{p-ca2fbd1b.system.js → p-cc247ee1.system.js} +1 -1
  141. package/dist/ripple/{p-73d66b0a.system.entry.js → p-cd3d74d1.system.entry.js} +1 -1
  142. package/dist/ripple/p-d1ac96e1.system.entry.js +1 -0
  143. package/dist/ripple/{p-3f1d8211.system.entry.js → p-d48c56c7.system.entry.js} +1 -1
  144. package/dist/ripple/{p-15b1c11b.js → p-de3367ee.js} +2 -2
  145. package/dist/ripple/{p-e748e22b.entry.js → p-e083fca6.entry.js} +1 -1
  146. package/dist/ripple/{p-3e6498ea.system.entry.js → p-e4439bc3.system.entry.js} +1 -1
  147. package/dist/ripple/{p-e49b9a96.entry.js → p-e524d462.entry.js} +1 -1
  148. package/dist/ripple/{p-92226595.entry.js → p-e8d39f68.entry.js} +1 -1
  149. package/dist/ripple/{p-00fa3d4b.entry.js → p-ed91be1a.entry.js} +1 -1
  150. package/dist/ripple/{p-d81a4e7c.system.entry.js → p-f23b3986.system.entry.js} +1 -1
  151. package/dist/ripple/{p-e75e75e0.entry.js → p-fda61e7e.entry.js} +1 -1
  152. package/dist/ripple/p-fe952112.entry.js +1 -0
  153. package/dist/ripple/ripple.esm.js +1 -1
  154. package/dist/ripple/ripple.js +1 -1
  155. package/dist/types/components/wm-button/wm-button.d.ts +4 -4
  156. package/dist/types/components/wm-option/wm-option.d.ts +5 -2
  157. package/dist/types/components/wm-select/wm-select.d.ts +39 -12
  158. package/dist/types/components/wm-toggletip/wm-toggletip.d.ts +2 -2
  159. package/dist/types/components.d.ts +10 -6
  160. package/dist/types/global/__mocks__/functions.d.ts +1 -0
  161. package/dist/types/global/functions.d.ts +2 -2
  162. package/dist/types/global/interfaces.d.ts +1 -1
  163. package/package.json +1 -1
  164. package/dist/esm-es5/global-5902ef31.js +0 -1
  165. package/dist/ripple/p-1b058a44.entry.js +0 -1
  166. package/dist/ripple/p-2077203e.system.js +0 -1
  167. package/dist/ripple/p-379b125b.entry.js +0 -1
  168. package/dist/ripple/p-49bf0b81.js +0 -1
  169. package/dist/ripple/p-584fef7f.system.entry.js +0 -1
  170. package/dist/ripple/p-72eb5064.system.entry.js +0 -1
  171. package/dist/ripple/p-76ca7498.system.js +0 -15
  172. package/dist/ripple/p-9fe64cec.entry.js +0 -1
  173. package/dist/ripple/p-a82d37d8.entry.js +0 -1
  174. package/dist/ripple/p-ac2485a6.system.entry.js +0 -1
  175. package/dist/ripple/p-ba168596.entry.js +0 -1
  176. package/dist/ripple/p-ed657559.entry.js +0 -1
@@ -1 +1 @@
1
- System.register(["./p-a0c3ef16.system.js","./p-76ca7498.system.js"],(function(t){"use strict";var e,i,o,a,r,n,s,l,p;return{setters:[function(t){e=t.r;i=t.c;o=t.h;a=t.H;r=t.g},function(t){n=t.g;s=t.i;l=t.d;p=t.l}],execute:function(){var d=':host,wm-tag-input{font-family:inherit;width:100%}:host *,wm-tag-input *{-webkit-box-sizing:border-box;box-sizing:border-box;font-size:14px}:host .wrapper,wm-tag-input .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,wm-tag-input .wrapper .label{display:block;line-height:normal;font-weight:600;white-space:nowrap;margin-bottom:0.25rem}:host .wrapper .label .required,wm-tag-input .wrapper .label .required{color:#c0392b}:host .wrapper.label-left,wm-tag-input .wrapper.label-left{-ms-flex-direction:row;flex-direction:row}:host .wrapper.label-left .label-wrapper,wm-tag-input .wrapper.label-left .label-wrapper{line-height:2.5rem}:host .wrapper.label-left .label-wrapper .label,wm-tag-input .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,wm-tag-input .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,wm-tag-input .wrapper.invalid .label{color:#c0392b}:host .wrapper.invalid .label:after,wm-tag-input .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,[dir=RTL] wm-tag-input .wrapper.invalid .label:after{margin-left:0;margin-right:0.3125rem}:host .wrapper.rtl.label-left .label,wm-tag-input .wrapper.rtl.label-left .label{margin-right:0;margin-left:0.75rem}:host .wrapper,wm-tag-input .wrapper{width:100%;position:relative}:host .field-wrapper,wm-tag-input .field-wrapper{position:relative;width:100%;min-height:2.5rem;border:1px solid #4a4a4a;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px}:host .field-wrapper.focused,wm-tag-input .field-wrapper.focused{-webkit-box-shadow:0 0 0 1px #20cbd4;-moz-box-shadow:0 0 0 1px #20cbd4;box-shadow:0 0 0 1px #20cbd4;outline:none;border-color:#20cbd4}:host .character-count,wm-tag-input .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:rgba(74, 74, 74, 0.05);font-size:0.875rem;font-weight:500;-ms-flex-item-align:stretch;align-self:stretch}:host .tags-and-input-wrapper,wm-tag-input .tags-and-input-wrapper{position:relative;width:100%;padding:0.5rem 0.25rem;margin-bottom:-0.5rem}:host .upper-row,wm-tag-input .upper-row{width:100%;display:-ms-flexbox;display:flex;-ms-flex:1;flex:1;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-align:center;align-items:center}:host .lower-row,wm-tag-input .lower-row{width:100%;border-radius:0 0 3px 3px}:host #max-tags,wm-tag-input #max-tags{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;height:1.875rem;background-color:#6b6b6b;padding:0.5rem 1rem;color:white;font-size:0.875rem}:host .tag-area,wm-tag-input .tag-area{display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;margin:0;padding:0}:host .tag-area:focus,wm-tag-input .tag-area:focus{outline:none}:host .tag-area [role=option],wm-tag-input .tag-area [role=option]{display:-ms-inline-flexbox;display:inline-flex;-ms-flex-align:center;align-items:center;height:1.75rem;list-style:none;color:#4a4a4a;background-color:rgba(3, 0, 0, 0.1);padding:0.5rem 0.625rem;margin-bottom:0.5rem;margin-right:0.25rem;margin-left:0.25rem;-webkit-transition:background-color 0.3s cubic-bezier(0.4, 0, 0.2, 1);transition:background-color 0.3s cubic-bezier(0.4, 0, 0.2, 1);white-space:pre}:host .tag-area [role=option].highlight,wm-tag-input .tag-area [role=option].highlight{-webkit-animation:fadeIn 1s;animation:fadeIn 1s}@-webkit-keyframes fadeIn{0%{background-color:rgba(3, 0, 0, 0.1)}50%{background-color:#c8dfcc}100%{background-color:rgba(3, 0, 0, 0.1)}}@keyframes fadeIn{0%{background-color:rgba(3, 0, 0, 0.1)}50%{background-color:#c8dfcc}100%{background-color:rgba(3, 0, 0, 0.1)}}:host .tag-area [role=option].focused,wm-tag-input .tag-area [role=option].focused{background-color:#d1d1d1}:host .tag-area [role=option] .remove-btn,wm-tag-input .tag-area [role=option] .remove-btn{display:-ms-inline-flexbox;display:inline-flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;height:1.25rem;width:1.25rem;border:1px solid #575195;color:#575195;border-radius:50%;padding:0;margin-left:0.5rem;cursor:pointer;-webkit-transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1);transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1)}:host .tag-area [role=option] .remove-btn:hover,wm-tag-input .tag-area [role=option] .remove-btn:hover{color:white;background-color:#575195}:host .tag-area [role=option] .remove-btn:before,wm-tag-input .tag-area [role=option] .remove-btn: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:"\\f156"}:host input,wm-tag-input input{font-family:inherit;border:none;height:1.75rem;padding:0;margin-bottom:0.5rem;margin-right:0.25rem;padding-left:0.5rem;right:0px}:host input.hidden,wm-tag-input input.hidden{display:none}:host input:focus,wm-tag-input input:focus{outline:none}:host .dropdown-wrapper,wm-tag-input .dropdown-wrapper{margin:0;padding:0;-webkit-box-shadow:0 4px 15px 0 rgba(0, 0, 0, 0.2);-moz-box-shadow:0 4px 15px 0 rgba(0, 0, 0, 0.2);box-shadow:0 4px 15px 0 rgba(0, 0, 0, 0.2);-ms-transition:transform 0.25s ease;-webkit-transition:transform 0.25s ease;-moz-transition:transform 0.25s ease;-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;-ms-transform:scale(1, 0);-webkit-transform:scale(1, 0);-moz-transform:scale(1, 0);transform:scale(1, 0);-ms-transform-origin:center top;-webkit-transform-origin:center top;-moz-transform-origin:center top;transform-origin:center top;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;position:absolute;top:calc(100% + 2px);right:0;background:#fff;z-index:100;width:100%;font-size:0.875rem}:host .dropdown-wrapper .dropdown,wm-tag-input .dropdown-wrapper .dropdown{-webkit-overflow-scrolling:touch;overflow:auto;max-height:12.5rem;margin:0;padding:0}:host .dropdown-wrapper.open,wm-tag-input .dropdown-wrapper.open{-ms-transform:scale(1, 1);-webkit-transform:scale(1, 1);-moz-transform:scale(1, 1);transform:scale(1, 1)}:host .dropdown-wrapper.upwards,wm-tag-input .dropdown-wrapper.upwards{top:unset;bottom:calc(100% + 2px);-ms-transform-origin:center bottom;-webkit-transform-origin:center bottom;-moz-transform-origin:center bottom;transform-origin:center bottom}:host .dropdown-wrapper li,:host .dropdown-wrapper div,wm-tag-input .dropdown-wrapper li,wm-tag-input .dropdown-wrapper div{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;padding:0 1rem;background:#fff;list-style:none;height:2.6875rem;white-space:pre}:host .dropdown-wrapper li[role=option],:host .dropdown-wrapper li.add-new-btn,:host .dropdown-wrapper div[role=option],:host .dropdown-wrapper div.add-new-btn,wm-tag-input .dropdown-wrapper li[role=option],wm-tag-input .dropdown-wrapper li.add-new-btn,wm-tag-input .dropdown-wrapper div[role=option],wm-tag-input .dropdown-wrapper div.add-new-btn{cursor:pointer;color:#575195;font-weight:bold;width:100%;border:none}:host .dropdown-wrapper li[role=option][aria-selected=true],:host .dropdown-wrapper li.add-new-btn[aria-selected=true],:host .dropdown-wrapper div[role=option][aria-selected=true],:host .dropdown-wrapper div.add-new-btn[aria-selected=true],wm-tag-input .dropdown-wrapper li[role=option][aria-selected=true],wm-tag-input .dropdown-wrapper li.add-new-btn[aria-selected=true],wm-tag-input .dropdown-wrapper div[role=option][aria-selected=true],wm-tag-input .dropdown-wrapper div.add-new-btn[aria-selected=true]{color:#6b6b6b;font-style:italic;font-weight:normal;cursor:unset}:host .dropdown-wrapper li[role=option]:hover:not([aria-selected=true]),:host .dropdown-wrapper li[role=option].focused,:host .dropdown-wrapper li.add-new-btn:hover:not([aria-selected=true]),:host .dropdown-wrapper li.add-new-btn.focused,:host .dropdown-wrapper div[role=option]:hover:not([aria-selected=true]),:host .dropdown-wrapper div[role=option].focused,:host .dropdown-wrapper div.add-new-btn:hover:not([aria-selected=true]),:host .dropdown-wrapper div.add-new-btn.focused,wm-tag-input .dropdown-wrapper li[role=option]:hover:not([aria-selected=true]),wm-tag-input .dropdown-wrapper li[role=option].focused,wm-tag-input .dropdown-wrapper li.add-new-btn:hover:not([aria-selected=true]),wm-tag-input .dropdown-wrapper li.add-new-btn.focused,wm-tag-input .dropdown-wrapper div[role=option]:hover:not([aria-selected=true]),wm-tag-input .dropdown-wrapper div[role=option].focused,wm-tag-input .dropdown-wrapper div.add-new-btn:hover:not([aria-selected=true]),wm-tag-input .dropdown-wrapper div.add-new-btn.focused{outline:none;background:#f4f4f4}:host .dropdown-wrapper li.help-text,:host .dropdown-wrapper div.help-text,wm-tag-input .dropdown-wrapper li.help-text,wm-tag-input .dropdown-wrapper div.help-text{color:#4a4a4a;min-height:2.6875rem;padding-top:0.25rem;padding-bottom:0.25rem}:host .dropdown-wrapper li:not(:last-child),:host .dropdown-wrapper div:not(:last-child),wm-tag-input .dropdown-wrapper li:not(:last-child),wm-tag-input .dropdown-wrapper div:not(:last-child){border-bottom:2px solid rgba(46, 27, 70, 0.05)}:host .info-text,wm-tag-input .info-text{font-style:italic;margin-top:0.25rem}:host .sr-only,wm-tag-input .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 c=t("wm_tag_input",function(){function t(t){var o=this;e(this,t);this.wmTagInputChanged=i(this,"wmTagInputChanged",7);this.labelPosition="top";this.options="";this.selectedTags="";this.addNew=true;this.characterLimit=50;this.uid=this.el.id?this.el.id:n();this.openUp=false;this.isExpanded=false;this.tagsList=this.csvToArray(this.selectedTags);this.optionsList=this.csvToArray(this.options);this.charCount=0;this.liveRegionMessage="";this.tagAreaInstructions=s.formatMessage({id:"tagInput.tagAreaInstructions",defaultMessage:"tag selection. Press Backspace or Delete to remove a tag."});this.maxTagsReachedMessage=s.formatMessage({id:"tagInput.maxTagsReached",defaultMessage:"The maximum amount of tags has been reached, no additional tags can be added."});this.debouncedResize=l((function(){o.positionInput()}),30)}Object.defineProperty(t.prototype,"focusedElement",{get:function(){return this.el.shadowRoot.activeElement},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"listItemEls",{get:function(){return Array.from(this.dropdownEl.querySelectorAll("li"))},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"tagEls",{get:function(){return Array.from(this.tagAreaEl.querySelectorAll(".tag"))},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"optionEls",{get:function(){return Array.from(this.dropdownEl.querySelectorAll(".option"))},enumerable:false,configurable:true});t.prototype.generateTagAddedMessage=function(t){return s.formatMessage({id:"tagInput.tagAdded",defaultMessage:"{tagName} added.",description:"A confirmation for adding a tag."},{tagName:t})};t.prototype.generateTagAlreadyAddedMessage=function(t){return s.formatMessage({id:"tagInput.tagAlreadyAdded",defaultMessage:"{tagName} has already been added.",description:"An alert for adding a tag that is already present."},{tagName:t})};t.prototype.generateTagCounterMessage=function(t,e){return s.formatMessage({id:"tagInput.tagsAddedCounter",defaultMessage:"Tags added: {x, number}/{y, number}",description:"For the user to understand how close they are to the tag limit."},{x:t,y:e})};t.prototype.generateCharacterLimitLabel=function(t){return s.formatMessage({id:"global.characterLimit",defaultMessage:"{limit, number} characters allowed.",description:"for screen readers"},{limit:t})};t.prototype.componentWillLoad=function(){if(!this.placeholder){this.placeholder=this.createPlaceholderDefault(this.addNew,!!this.options)}if(!this.label){console.error("wm-tag-input must have a label property")}this.el.focus=function(){if(this.selectedTags){this.shadowRoot.querySelector("ul.tag-area").focus()}else{this.shadowRoot.querySelector("input").focus()}};this.consolidateSelectedTags()};t.prototype.componentDidLoad=function(){this.tagEls.forEach((function(t){return t.classList.remove("highlight")}))};t.prototype.componentDidRender=function(){this.positionInput()};t.prototype.consolidateSelectedTags=function(){var t=this;this.tagsList.forEach((function(e){if(!t.includesCaseInsensitive(t.optionsList,e)){t.options+="".concat(t.options.length>0?",":"").concat(e)}}));this.optionsList=this.csvToArray(this.options)};t.prototype.createPlaceholderDefault=function(t,e){var i=s.formatMessage({id:"tagInput.placeholderAddAndSearch",defaultMessage:"Add or search for a tag",description:"Placeholder text. Use imperative"});var o=s.formatMessage({id:"tagInput.placeholderSearch",defaultMessage:"Search and select a tag",description:"Placeholder text. Use imperative"});var a=s.formatMessage({id:"tagInput.placeholderAdd",defaultMessage:"Add a new tag",description:"Placeholder text. Use imperative"});var r="";if(t&&e){r=i}else if(!t&&e){r=o}else if(t){r=a}return r};t.prototype.reflectSelectedTags=function(){this.selectedTags=this.listToCSV(this.tagsList);this.wmTagInputChanged.emit({value:this.tagsList})};t.prototype.closeIfNotElOrChild=function(t){var e=t.target!==this.el&&!this.el.shadowRoot.contains(t.target);if(e&&this.isExpanded){this.closeDropdown()}};t.prototype.handleResize=function(){this.debouncedResize()};t.prototype.handleInputKeyDown=function(t){if(/^.$/.test(t.key)&&this.inputEl.value.length>=this.characterLimit){this.announceCharacterLimitWarning(this.inputEl.value.length,this.characterLimit)}t.stopPropagation();switch(t.key){case"Enter":case",":t.preventDefault();this.submitInput(this.addNew,this.inputEl.value.trim());break;case"ArrowDown":t.preventDefault();this.handleInputArrowDown();break;case"ArrowUp":t.preventDefault();this.handleInputArrowUp();break;case"Escape":if(this.isExpanded){this.closeDropdown()}break;case"ArrowLeft":case"Backspace":this.handleInputBackspace();break}};t.prototype.handleInputChanged=function(t){this.charCount=t.length;if(this.charCount>=this.characterLimit-5){this.announceCharacterLimitWarning(this.charCount,this.characterLimit)}this.announceExistingOptions();if(!this.isExpanded){this.openDropdown()}};t.prototype.submitInput=function(t,e){var i=e.match(/\S/);if(t&&i){this.tagsList=this.addTag(e);this.optionsList=this.addOption(e);this.resetInput();if(this.maxTags&&this.tagsList.length>=this.maxTags){this.tagAreaEl.focus()}}};t.prototype.handleInputArrowDown=function(){if(this.isExpanded){this.moveDownListItem()}else{this.openDropdown()}};t.prototype.handleInputArrowUp=function(){if(this.isExpanded){this.moveUpListItem()}else{this.openDropdown()}};t.prototype.handleInputBackspace=function(){var t=this;if(this.inputEl.value===""&&this.tagsList.length>0){window.requestAnimationFrame((function(){t.tagAreaEl.focus();t.focusTag(t.tagEls[t.tagEls.length-1])}))}};t.prototype.handleListItemKeyDown=function(t){var e=t.target;switch(t.key){case"Enter":case" ":t.preventDefault();e.click();break;case"ArrowDown":t.preventDefault();this.moveDownListItem();break;case"ArrowUp":t.preventDefault();this.moveUpListItem();break;case"Escape":if(this.focusedElement!==this.inputEl){this.inputEl.focus()}else{this.closeDropdown()}break}};t.prototype.handleListItemClick=function(t){var e=t.target;var i=e.dataset.option.trim()||"";if(this.includesCaseInsensitive(this.tagsList,i)){this.announce(this.generateTagAlreadyAddedMessage(i))}else{this.announce(this.generateTagAddedMessage(i));this.resetInput();this.tagsList=this.addTag(i);this.optionsList=this.addOption(i);this.focusedListItem=null;var o=this.maxTags&&this.tagsList.length>=this.maxTags?this.tagAreaEl:this.inputEl;o.focus()}};t.prototype.handleTagAreaKeyDown=function(t){switch(t.key){case"ArrowLeft":case"ArrowUp":t.preventDefault();this.moveLeftTag();break;case"ArrowRight":case"ArrowDown":t.preventDefault();this.moveRightTag();break;case"Backspace":case"Delete":this.handleTagAreaDelete();break}};t.prototype.handleTagAreaDelete=function(){if(this.focusedTag&&this.focusedTag.dataset.tag){this.removeTag(this.focusedTag.dataset.tag);if(this.tagsList.length===0){this.inputEl.focus()}else if(this.focusedTag===this.tagEls[this.tagEls.length-1]){this.focusedTag=this.tagEls[this.tagEls.length-2];this.focusTag(this.focusedTag)}}};t.prototype.handleBlur=function(t,e){var i=t.relatedTarget!==e&&!this.el.shadowRoot.contains(t.relatedTarget);if(i){this.closeDropdown();this.fieldWrapperEl.classList.remove("focused")}};t.prototype.handleTagAreaFocus=function(){this.closeDropdown();if(!this.focusedTag){this.focusedTag=this.tagEls[0]}this.focusTag(this.focusedTag)};t.prototype.handleRemoveButtonClick=function(t){this.moveLeftTag();this.removeTag(t)};t.prototype.moveDownListItem=function(){if(this.listItemEls.length>0){var t=this.listItemEls[0];if(!this.focusedListItem){this.focusListItem(t)}else if(this.focusedListItem.nextElementSibling){this.focusListItem(this.focusedListItem.nextElementSibling)}else{this.focusListItem(t)}}};t.prototype.moveUpListItem=function(){if(this.listItemEls.length>0){var t=this.listItemEls[this.listItemEls.length-1];if(!this.focusedListItem){this.focusListItem(t)}else if(this.focusedListItem.previousElementSibling){this.focusListItem(this.focusedListItem.previousElementSibling)}else{this.focusedListItem=null;this.inputEl.focus()}}};t.prototype.moveLeftTag=function(){var t=this.tagEls[this.tagEls.length-1];if(this.focusedTag&&this.tagEls.includes(this.focusedTag.previousElementSibling)){this.focusedTag=this.focusedTag.previousElementSibling}else{this.focusedTag=t}this.focusTag(this.focusedTag)};t.prototype.moveRightTag=function(){var t=this.tagEls[0];if(this.focusedTag&&this.tagEls.includes(this.focusedTag.nextElementSibling)){this.focusedTag=this.focusedTag.nextElementSibling}else{this.focusedTag=t}this.focusTag(this.focusedTag)};t.prototype.addOption=function(t){var e=this.optionsList;var i=this.includesCaseInsensitive(this.optionsList,t);if(!i){e=e.concat(t)}return e};t.prototype.removeOption=function(t){this.optionsList=this.filterCaseInsensitive(this.optionsList,t)};t.prototype.addTag=function(t){var e=this.tagsList;var i=this.includesCaseInsensitive(this.tagsList,t);var o=this.optionsList.filter((function(e){return e.toLowerCase()===t.toLowerCase()}))[0];if(!i){this.announce(this.generateTagAddedMessage(t));e=e.concat(o||t)}return e};t.prototype.removeTag=function(t){var e=s.formatMessage({id:"tagInput.tagRemoved",defaultMessage:"{tag} removed"},{tag:t});this.announce(e);this.tagsList=this.filterCaseInsensitive(this.tagsList,t);var i=this.csvToArray(this.options);if(this.includesCaseInsensitive(this.optionsList,t)&&!this.includesCaseInsensitive(i,t)){this.removeOption(t)}};t.prototype.focusListItem=function(t){this.focusedListItem=t;t.focus()};t.prototype.focusTag=function(t){this.focusedTag=t;this.tagAreaEl.setAttribute("aria-activedescendant",this.focusedTag.id)};t.prototype.clearTagFocus=function(){this.tagAreaEl.removeAttribute("aria-activedescendant");this.focusedTag=null};t.prototype.openDropdown=function(){this.openUp=p(this.el,this.dropdownEl,this.el.clientHeight,-2);this.isExpanded=true};t.prototype.closeDropdown=function(){this.focusedListItem=null;this.isExpanded=false};t.prototype.clearListItemFocus=function(){this.focusedListItem=null;this.listItemEls.forEach((function(t){t.tabIndex=-1;t.classList.remove("focused")}))};t.prototype.resetInput=function(){this.charCount=0;this.inputEl.value=""};t.prototype.announce=function(t){if(this.liveRegionEl.textContent===t){t+=" "}this.liveRegionMessage=t};t.prototype.announceExistingOptions=function(){var t=this;window.requestAnimationFrame((function(){var e=s.formatMessage({id:"tagInput.existingOptions",defaultMessage:"{num, plural, one {1 existing option.} other {# existing options.}}"},{num:t.optionEls.length});if(t.optionEls.length>0){t.announce(e)}}))};t.prototype.announceCharacterLimitWarning=function(t,e){var i=s.formatMessage({id:"global.charactersEntered",defaultMessage:"{x, number} of {y, number} characters entered.",description:"for screen readers"},{x:t,y:e});var o=s.formatMessage({id:"global.characterLimitReached",defaultMessage:"No additional characters will be entered.",description:"for screen readers"});this.announce("".concat(i).concat(t>=e?" "+o:""))};t.prototype.positionInput=function(){var t=this.tagEls[this.tagEls.length-1];this.inputEl.style.position="static";this.inputEl.style.width="100%";if(t){var e=this.tagAreaEl.getBoundingClientRect().right-t.getBoundingClientRect().right;if(e>=150){this.inputEl.style.position="absolute";this.inputEl.style.top=t.offsetTop.toString()+"px";this.inputEl.style.width=(this.tagAreaEl.getBoundingClientRect().right-t.getBoundingClientRect().right-8).toString()+"px"}}};t.prototype.listToCSV=function(t){return t.join(",")};t.prototype.csvToArray=function(t){return t?t.split(/, ?/):[]};t.prototype.includesCaseInsensitive=function(t,e){var i=t.map((function(t){return t.toLowerCase()}));return i.includes(e.toLowerCase())};t.prototype.filterCaseInsensitive=function(t,e){return t.filter((function(t){return t.toLowerCase()!==e.toLowerCase()}))};t.prototype.sortCaseInsensitive=function(t){return t.sort((function(t,e){t=t.toLowerCase();e=e.toLowerCase();return t>e?1:t<e?-1:0}))};t.prototype.renderTags=function(){var t=this;return this.tagsList.map((function(e,i){var a="tag".concat(i+1);return o("li",{id:a,class:"tag highlight ".concat(t.focusedTag&&t.focusedTag.id===a?"focused":""),"data-tag":e,role:"option"},e,o("button",{class:"remove-btn",tabIndex:-1,onClick:function(){return t.handleRemoveButtonClick(e)}}))}))};t.prototype.renderListItems=function(t){var e=this;t=this.sortCaseInsensitive(t);if(this.inputEl&&this.inputEl.value){t=this.optionsList.filter((function(t){return t.toLowerCase().includes(e.inputEl.value.toLowerCase())}))}return t.map((function(t,i){var a="option".concat(i+1);var r=e.focusedListItem&&e.focusedListItem.id===a;var n=e.includesCaseInsensitive(e.tagsList,t);return o("li",{class:"option ".concat(r?"focused":""),role:"option",id:a,"data-option":t,tabIndex:r?0:-1,"aria-selected":n?"true":"false","aria-disabled":n?"true":"false",onKeyDown:function(t){return e.handleListItemKeyDown(t)},onBlur:function(t){return e.handleBlur(t,e.el)},onClick:function(t){return e.handleListItemClick(t)}},t)}))};t.prototype.renderAddNewButton=function(){var t=this;var e=this.inputEl.value.match(/\S/);var i=this.includesCaseInsensitive(this.optionsList,this.inputEl.value.trim());if(this.addNew&&e&&!i){var a="add-new-btn";var r=this.focusedListItem&&this.focusedListItem.id===a;return o("li",{role:"option",class:"add-new-btn ".concat(r?"focused":""),id:a,"data-option":this.inputEl.value,onKeyDown:function(e){return t.handleListItemKeyDown(e)},onBlur:function(e){return t.handleBlur(e,t.el)},onClick:function(e){return t.handleListItemClick(e)},tabIndex:r?0:-1},'Add "'.concat(this.inputEl.value.trim(),'"'))}else return""};t.prototype.renderHelpText=function(){var t=s.formatMessage({id:"tagInput.helpTextCanSelect",defaultMessage:"Search and select a tag.",description:"Placeholder text. Use imperative"});var e=s.formatMessage({id:"tagInput.helpTextEditable",defaultMessage:"Press the Enter or Comma key to add a new tag.",description:"Placeholder text. Use imperative"});var i="";if(this.optionsList.length>0){i+=t}if(this.addNew){i+=" "+e}return i};t.prototype.renderTagCounter=function(){if(this.maxTags){return o("div",{class:"lower-row"},o("div",{id:"max-tags"},this.generateTagCounterMessage(this.tagsList.length,this.maxTags),this.tagsList.length>=this.maxTags&&o("span",{class:"sr-only"},this.maxTagsReachedMessage)))}};t.prototype.render=function(){var t=this;var e=this.focusedElement&&(this.focusedElement===this.inputEl||this.focusedElement===this.tagAreaEl||this.focusedElement.classList.contains("add-new-btn")||this.optionsList.length>0&&this.listItemEls.includes(this.focusedElement));return o(a,{id:this.uid},o("div",{class:"wrapper label-".concat(this.labelPosition)},o("div",{class:"label-wrapper"},o("label",{class:"label",htmlFor:"input".concat(this.uid)},this.label)),o("div",{class:"field-wrapper ".concat(e?"focused":""),ref:function(e){return t.fieldWrapperEl=e}},o("div",{class:"upper-row"},o("div",{class:"tags-and-input-wrapper"},o("ul",{ref:function(e){return t.tagAreaEl=e},class:"tag-area",role:"listbox","aria-orientation":"horizontal","aria-label":"".concat(this.label," ").concat(this.tagsList.length>0?this.tagAreaInstructions:""),tabindex:this.tagsList.length>0?0:-1,"aria-describedby":"info max-tags",onFocus:function(){return t.handleTagAreaFocus()},onBlur:function(e){t.clearTagFocus();t.handleBlur(e,t.el)},onKeyDown:function(e){return t.handleTagAreaKeyDown(e)}},this.renderTags()),o("input",{id:"input".concat(this.uid),class:this.maxTags&&this.tagsList.length>=this.maxTags?"hidden":"",role:"combobox",ref:function(e){return t.inputEl=e},autocomplete:"off","aria-controls":"dropdown","aria-describedby":"help-text","aria-label":"".concat(this.label," ").concat(this.generateCharacterLimitLabel(this.characterLimit)),"aria-expanded":this.isExpanded?"true":"false",placeholder:this.placeholder,maxLength:this.characterLimit,onInput:function(){return t.handleInputChanged(t.inputEl.value)},onBlur:function(e){t.handleBlur(e,t.el)},onFocus:function(){t.openDropdown();t.clearListItemFocus()},onKeyDown:function(e){return t.handleInputKeyDown(e)}})),o("div",{class:"character-count"},this.charCount,"/",this.characterLimit)),this.renderTagCounter(),o("div",{class:"dropdown-wrapper ".concat(this.isExpanded?"open":""," ").concat(this.openUp?"upwards":""),ref:function(e){return t.dropdownEl=e}},o("div",{id:"help-text",class:"help-text"},this.renderHelpText()),o("ul",{class:"dropdown",id:"dropdown",role:"listbox","aria-multiselectable":"true","aria-expanded":this.isExpanded?"true":false,"aria-label":this.label,tabindex:-1},this.inputEl&&this.renderAddNewButton(),this.renderListItems(this.optionsList)))),this.info?o("div",{id:"info",class:"info-text"},this.info):"",o("div",{class:"sr-only","aria-live":"assertive",ref:function(e){return t.liveRegionEl=e},"aria-atomic":"true"},this.liveRegionMessage)))};Object.defineProperty(t.prototype,"el",{get:function(){return r(this)},enumerable:false,configurable:true});Object.defineProperty(t,"watchers",{get:function(){return{tagsList:["reflectSelectedTags"]}},enumerable:false,configurable:true});return t}());c.style=d}}}));
1
+ System.register(["./p-a0c3ef16.system.js","./p-726c979a.system.js"],(function(t){"use strict";var e,i,o,a,r,n,s,l,p;return{setters:[function(t){e=t.r;i=t.c;o=t.h;a=t.H;r=t.g},function(t){n=t.g;s=t.i;l=t.d;p=t.l}],execute:function(){var d=':host,wm-tag-input{font-family:inherit;width:100%}:host *,wm-tag-input *{-webkit-box-sizing:border-box;box-sizing:border-box;font-size:14px}:host .wrapper,wm-tag-input .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,wm-tag-input .wrapper .label{display:block;line-height:normal;font-weight:600;white-space:nowrap;margin-bottom:0.25rem}:host .wrapper .label .required,wm-tag-input .wrapper .label .required{color:#c0392b}:host .wrapper.label-left,wm-tag-input .wrapper.label-left{-ms-flex-direction:row;flex-direction:row}:host .wrapper.label-left .label-wrapper,wm-tag-input .wrapper.label-left .label-wrapper{line-height:2.5rem}:host .wrapper.label-left .label-wrapper .label,wm-tag-input .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,wm-tag-input .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,wm-tag-input .wrapper.invalid .label{color:#c0392b}:host .wrapper.invalid .label:after,wm-tag-input .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,[dir=RTL] wm-tag-input .wrapper.invalid .label:after{margin-left:0;margin-right:0.3125rem}:host .wrapper.rtl.label-left .label,wm-tag-input .wrapper.rtl.label-left .label{margin-right:0;margin-left:0.75rem}:host .wrapper,wm-tag-input .wrapper{width:100%;position:relative}:host .field-wrapper,wm-tag-input .field-wrapper{position:relative;width:100%;min-height:2.5rem;border:1px solid #4a4a4a;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px}:host .field-wrapper.focused,wm-tag-input .field-wrapper.focused{-webkit-box-shadow:0 0 0 1px #20cbd4;-moz-box-shadow:0 0 0 1px #20cbd4;box-shadow:0 0 0 1px #20cbd4;outline:none;border-color:#20cbd4}:host .character-count,wm-tag-input .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:rgba(74, 74, 74, 0.05);font-size:0.875rem;font-weight:500;-ms-flex-item-align:stretch;align-self:stretch}:host .tags-and-input-wrapper,wm-tag-input .tags-and-input-wrapper{position:relative;width:100%;padding:0.5rem 0.25rem;margin-bottom:-0.5rem}:host .upper-row,wm-tag-input .upper-row{width:100%;display:-ms-flexbox;display:flex;-ms-flex:1;flex:1;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-align:center;align-items:center}:host .lower-row,wm-tag-input .lower-row{width:100%;border-radius:0 0 3px 3px}:host #max-tags,wm-tag-input #max-tags{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;height:1.875rem;background-color:#6b6b6b;padding:0.5rem 1rem;color:white;font-size:0.875rem}:host .tag-area,wm-tag-input .tag-area{display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;margin:0;padding:0}:host .tag-area:focus,wm-tag-input .tag-area:focus{outline:none}:host .tag-area [role=option],wm-tag-input .tag-area [role=option]{display:-ms-inline-flexbox;display:inline-flex;-ms-flex-align:center;align-items:center;height:1.75rem;list-style:none;color:#4a4a4a;background-color:rgba(3, 0, 0, 0.1);padding:0.5rem 0.625rem;margin-bottom:0.5rem;margin-right:0.25rem;margin-left:0.25rem;-webkit-transition:background-color 0.3s cubic-bezier(0.4, 0, 0.2, 1);transition:background-color 0.3s cubic-bezier(0.4, 0, 0.2, 1);white-space:pre}:host .tag-area [role=option].highlight,wm-tag-input .tag-area [role=option].highlight{-webkit-animation:fadeIn 1s;animation:fadeIn 1s}@-webkit-keyframes fadeIn{0%{background-color:rgba(3, 0, 0, 0.1)}50%{background-color:#c8dfcc}100%{background-color:rgba(3, 0, 0, 0.1)}}@keyframes fadeIn{0%{background-color:rgba(3, 0, 0, 0.1)}50%{background-color:#c8dfcc}100%{background-color:rgba(3, 0, 0, 0.1)}}:host .tag-area [role=option].focused,wm-tag-input .tag-area [role=option].focused{background-color:#d1d1d1}:host .tag-area [role=option] .remove-btn,wm-tag-input .tag-area [role=option] .remove-btn{display:-ms-inline-flexbox;display:inline-flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;height:1.25rem;width:1.25rem;border:1px solid #575195;color:#575195;border-radius:50%;padding:0;margin-left:0.5rem;cursor:pointer;-webkit-transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1);transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1)}:host .tag-area [role=option] .remove-btn:hover,wm-tag-input .tag-area [role=option] .remove-btn:hover{color:white;background-color:#575195}:host .tag-area [role=option] .remove-btn:before,wm-tag-input .tag-area [role=option] .remove-btn: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:"\\f156"}:host input,wm-tag-input input{font-family:inherit;border:none;height:1.75rem;padding:0;margin-bottom:0.5rem;margin-right:0.25rem;padding-left:0.5rem;right:0px}:host input.hidden,wm-tag-input input.hidden{display:none}:host input:focus,wm-tag-input input:focus{outline:none}:host .dropdown-wrapper,wm-tag-input .dropdown-wrapper{margin:0;padding:0;-webkit-box-shadow:0 4px 15px 0 rgba(0, 0, 0, 0.2);-moz-box-shadow:0 4px 15px 0 rgba(0, 0, 0, 0.2);box-shadow:0 4px 15px 0 rgba(0, 0, 0, 0.2);-ms-transition:transform 0.25s ease;-webkit-transition:transform 0.25s ease;-moz-transition:transform 0.25s ease;-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;-ms-transform:scale(1, 0);-webkit-transform:scale(1, 0);-moz-transform:scale(1, 0);transform:scale(1, 0);-ms-transform-origin:center top;-webkit-transform-origin:center top;-moz-transform-origin:center top;transform-origin:center top;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;position:absolute;top:calc(100% + 2px);right:0;background:#fff;z-index:100;width:100%;font-size:0.875rem}:host .dropdown-wrapper .dropdown,wm-tag-input .dropdown-wrapper .dropdown{-webkit-overflow-scrolling:touch;overflow:auto;max-height:12.5rem;margin:0;padding:0}:host .dropdown-wrapper.open,wm-tag-input .dropdown-wrapper.open{-ms-transform:scale(1, 1);-webkit-transform:scale(1, 1);-moz-transform:scale(1, 1);transform:scale(1, 1)}:host .dropdown-wrapper.upwards,wm-tag-input .dropdown-wrapper.upwards{top:unset;bottom:calc(100% + 2px);-ms-transform-origin:center bottom;-webkit-transform-origin:center bottom;-moz-transform-origin:center bottom;transform-origin:center bottom}:host .dropdown-wrapper li,:host .dropdown-wrapper div,wm-tag-input .dropdown-wrapper li,wm-tag-input .dropdown-wrapper div{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;padding:0 1rem;background:#fff;list-style:none;height:2.6875rem;white-space:pre}:host .dropdown-wrapper li[role=option],:host .dropdown-wrapper li.add-new-btn,:host .dropdown-wrapper div[role=option],:host .dropdown-wrapper div.add-new-btn,wm-tag-input .dropdown-wrapper li[role=option],wm-tag-input .dropdown-wrapper li.add-new-btn,wm-tag-input .dropdown-wrapper div[role=option],wm-tag-input .dropdown-wrapper div.add-new-btn{cursor:pointer;color:#575195;font-weight:bold;width:100%;border:none}:host .dropdown-wrapper li[role=option][aria-selected=true],:host .dropdown-wrapper li.add-new-btn[aria-selected=true],:host .dropdown-wrapper div[role=option][aria-selected=true],:host .dropdown-wrapper div.add-new-btn[aria-selected=true],wm-tag-input .dropdown-wrapper li[role=option][aria-selected=true],wm-tag-input .dropdown-wrapper li.add-new-btn[aria-selected=true],wm-tag-input .dropdown-wrapper div[role=option][aria-selected=true],wm-tag-input .dropdown-wrapper div.add-new-btn[aria-selected=true]{color:#6b6b6b;font-style:italic;font-weight:normal;cursor:unset}:host .dropdown-wrapper li[role=option]:hover:not([aria-selected=true]),:host .dropdown-wrapper li[role=option].focused,:host .dropdown-wrapper li.add-new-btn:hover:not([aria-selected=true]),:host .dropdown-wrapper li.add-new-btn.focused,:host .dropdown-wrapper div[role=option]:hover:not([aria-selected=true]),:host .dropdown-wrapper div[role=option].focused,:host .dropdown-wrapper div.add-new-btn:hover:not([aria-selected=true]),:host .dropdown-wrapper div.add-new-btn.focused,wm-tag-input .dropdown-wrapper li[role=option]:hover:not([aria-selected=true]),wm-tag-input .dropdown-wrapper li[role=option].focused,wm-tag-input .dropdown-wrapper li.add-new-btn:hover:not([aria-selected=true]),wm-tag-input .dropdown-wrapper li.add-new-btn.focused,wm-tag-input .dropdown-wrapper div[role=option]:hover:not([aria-selected=true]),wm-tag-input .dropdown-wrapper div[role=option].focused,wm-tag-input .dropdown-wrapper div.add-new-btn:hover:not([aria-selected=true]),wm-tag-input .dropdown-wrapper div.add-new-btn.focused{outline:none;background:#f4f4f4}:host .dropdown-wrapper li.help-text,:host .dropdown-wrapper div.help-text,wm-tag-input .dropdown-wrapper li.help-text,wm-tag-input .dropdown-wrapper div.help-text{color:#4a4a4a;min-height:2.6875rem;padding-top:0.25rem;padding-bottom:0.25rem}:host .dropdown-wrapper li:not(:last-child),:host .dropdown-wrapper div:not(:last-child),wm-tag-input .dropdown-wrapper li:not(:last-child),wm-tag-input .dropdown-wrapper div:not(:last-child){border-bottom:2px solid rgba(46, 27, 70, 0.05)}:host .info-text,wm-tag-input .info-text{font-style:italic;margin-top:0.25rem}:host .sr-only,wm-tag-input .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 c=t("wm_tag_input",function(){function t(t){var o=this;e(this,t);this.wmTagInputChanged=i(this,"wmTagInputChanged",7);this.labelPosition="top";this.options="";this.selectedTags="";this.addNew=true;this.characterLimit=50;this.uid=this.el.id?this.el.id:n();this.openUp=false;this.isExpanded=false;this.tagsList=this.csvToArray(this.selectedTags);this.optionsList=this.csvToArray(this.options);this.charCount=0;this.liveRegionMessage="";this.tagAreaInstructions=s.formatMessage({id:"tagInput.tagAreaInstructions",defaultMessage:"tag selection. Press Backspace or Delete to remove a tag."});this.maxTagsReachedMessage=s.formatMessage({id:"tagInput.maxTagsReached",defaultMessage:"The maximum amount of tags has been reached, no additional tags can be added."});this.debouncedResize=l((function(){o.positionInput()}),30)}Object.defineProperty(t.prototype,"focusedElement",{get:function(){return this.el.shadowRoot.activeElement},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"listItemEls",{get:function(){return Array.from(this.dropdownEl.querySelectorAll("li"))},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"tagEls",{get:function(){return Array.from(this.tagAreaEl.querySelectorAll(".tag"))},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"optionEls",{get:function(){return Array.from(this.dropdownEl.querySelectorAll(".option"))},enumerable:false,configurable:true});t.prototype.generateTagAddedMessage=function(t){return s.formatMessage({id:"tagInput.tagAdded",defaultMessage:"{tagName} added.",description:"A confirmation for adding a tag."},{tagName:t})};t.prototype.generateTagAlreadyAddedMessage=function(t){return s.formatMessage({id:"tagInput.tagAlreadyAdded",defaultMessage:"{tagName} has already been added.",description:"An alert for adding a tag that is already present."},{tagName:t})};t.prototype.generateTagCounterMessage=function(t,e){return s.formatMessage({id:"tagInput.tagsAddedCounter",defaultMessage:"Tags added: {x, number}/{y, number}",description:"For the user to understand how close they are to the tag limit."},{x:t,y:e})};t.prototype.generateCharacterLimitLabel=function(t){return s.formatMessage({id:"global.characterLimit",defaultMessage:"{limit, number} characters allowed.",description:"for screen readers"},{limit:t})};t.prototype.componentWillLoad=function(){if(!this.placeholder){this.placeholder=this.createPlaceholderDefault(this.addNew,!!this.options)}if(!this.label){console.error("wm-tag-input must have a label property")}this.el.focus=function(){if(this.selectedTags){this.shadowRoot.querySelector("ul.tag-area").focus()}else{this.shadowRoot.querySelector("input").focus()}};this.consolidateSelectedTags()};t.prototype.componentDidLoad=function(){this.tagEls.forEach((function(t){return t.classList.remove("highlight")}))};t.prototype.componentDidRender=function(){this.positionInput()};t.prototype.consolidateSelectedTags=function(){var t=this;this.tagsList.forEach((function(e){if(!t.includesCaseInsensitive(t.optionsList,e)){t.options+="".concat(t.options.length>0?",":"").concat(e)}}));this.optionsList=this.csvToArray(this.options)};t.prototype.createPlaceholderDefault=function(t,e){var i=s.formatMessage({id:"tagInput.placeholderAddAndSearch",defaultMessage:"Add or search for a tag",description:"Placeholder text. Use imperative"});var o=s.formatMessage({id:"tagInput.placeholderSearch",defaultMessage:"Search and select a tag",description:"Placeholder text. Use imperative"});var a=s.formatMessage({id:"tagInput.placeholderAdd",defaultMessage:"Add a new tag",description:"Placeholder text. Use imperative"});var r="";if(t&&e){r=i}else if(!t&&e){r=o}else if(t){r=a}return r};t.prototype.reflectSelectedTags=function(){this.selectedTags=this.listToCSV(this.tagsList);this.wmTagInputChanged.emit({value:this.tagsList})};t.prototype.closeIfNotElOrChild=function(t){var e=t.target!==this.el&&!this.el.shadowRoot.contains(t.target);if(e&&this.isExpanded){this.closeDropdown()}};t.prototype.handleResize=function(){this.debouncedResize()};t.prototype.handleInputKeyDown=function(t){if(/^.$/.test(t.key)&&this.inputEl.value.length>=this.characterLimit){this.announceCharacterLimitWarning(this.inputEl.value.length,this.characterLimit)}t.stopPropagation();switch(t.key){case"Enter":case",":t.preventDefault();this.submitInput(this.addNew,this.inputEl.value.trim());break;case"ArrowDown":t.preventDefault();this.handleInputArrowDown();break;case"ArrowUp":t.preventDefault();this.handleInputArrowUp();break;case"Escape":if(this.isExpanded){this.closeDropdown()}break;case"ArrowLeft":case"Backspace":this.handleInputBackspace();break}};t.prototype.handleInputChanged=function(t){this.charCount=t.length;if(this.charCount>=this.characterLimit-5){this.announceCharacterLimitWarning(this.charCount,this.characterLimit)}this.announceExistingOptions();if(!this.isExpanded){this.openDropdown()}};t.prototype.submitInput=function(t,e){var i=e.match(/\S/);if(t&&i){this.tagsList=this.addTag(e);this.optionsList=this.addOption(e);this.resetInput();if(this.maxTags&&this.tagsList.length>=this.maxTags){this.tagAreaEl.focus()}}};t.prototype.handleInputArrowDown=function(){if(this.isExpanded){this.moveDownListItem()}else{this.openDropdown()}};t.prototype.handleInputArrowUp=function(){if(this.isExpanded){this.moveUpListItem()}else{this.openDropdown()}};t.prototype.handleInputBackspace=function(){var t=this;if(this.inputEl.value===""&&this.tagsList.length>0){window.requestAnimationFrame((function(){t.tagAreaEl.focus();t.focusTag(t.tagEls[t.tagEls.length-1])}))}};t.prototype.handleListItemKeyDown=function(t){var e=t.target;switch(t.key){case"Enter":case" ":t.preventDefault();e.click();break;case"ArrowDown":t.preventDefault();this.moveDownListItem();break;case"ArrowUp":t.preventDefault();this.moveUpListItem();break;case"Escape":if(this.focusedElement!==this.inputEl){this.inputEl.focus()}else{this.closeDropdown()}break}};t.prototype.handleListItemClick=function(t){var e=t.target;var i=e.dataset.option.trim()||"";if(this.includesCaseInsensitive(this.tagsList,i)){this.announce(this.generateTagAlreadyAddedMessage(i))}else{this.announce(this.generateTagAddedMessage(i));this.resetInput();this.tagsList=this.addTag(i);this.optionsList=this.addOption(i);this.focusedListItem=null;var o=this.maxTags&&this.tagsList.length>=this.maxTags?this.tagAreaEl:this.inputEl;o.focus()}};t.prototype.handleTagAreaKeyDown=function(t){switch(t.key){case"ArrowLeft":case"ArrowUp":t.preventDefault();this.moveLeftTag();break;case"ArrowRight":case"ArrowDown":t.preventDefault();this.moveRightTag();break;case"Backspace":case"Delete":this.handleTagAreaDelete();break}};t.prototype.handleTagAreaDelete=function(){if(this.focusedTag&&this.focusedTag.dataset.tag){this.removeTag(this.focusedTag.dataset.tag);if(this.tagsList.length===0){this.inputEl.focus()}else if(this.focusedTag===this.tagEls[this.tagEls.length-1]){this.focusedTag=this.tagEls[this.tagEls.length-2];this.focusTag(this.focusedTag)}}};t.prototype.handleBlur=function(t,e){var i=t.relatedTarget!==e&&!this.el.shadowRoot.contains(t.relatedTarget);if(i){this.closeDropdown();this.fieldWrapperEl.classList.remove("focused")}};t.prototype.handleTagAreaFocus=function(){this.closeDropdown();if(!this.focusedTag){this.focusedTag=this.tagEls[0]}this.focusTag(this.focusedTag)};t.prototype.handleRemoveButtonClick=function(t){this.moveLeftTag();this.removeTag(t)};t.prototype.moveDownListItem=function(){if(this.listItemEls.length>0){var t=this.listItemEls[0];if(!this.focusedListItem){this.focusListItem(t)}else if(this.focusedListItem.nextElementSibling){this.focusListItem(this.focusedListItem.nextElementSibling)}else{this.focusListItem(t)}}};t.prototype.moveUpListItem=function(){if(this.listItemEls.length>0){var t=this.listItemEls[this.listItemEls.length-1];if(!this.focusedListItem){this.focusListItem(t)}else if(this.focusedListItem.previousElementSibling){this.focusListItem(this.focusedListItem.previousElementSibling)}else{this.focusedListItem=null;this.inputEl.focus()}}};t.prototype.moveLeftTag=function(){var t=this.tagEls[this.tagEls.length-1];if(this.focusedTag&&this.tagEls.includes(this.focusedTag.previousElementSibling)){this.focusedTag=this.focusedTag.previousElementSibling}else{this.focusedTag=t}this.focusTag(this.focusedTag)};t.prototype.moveRightTag=function(){var t=this.tagEls[0];if(this.focusedTag&&this.tagEls.includes(this.focusedTag.nextElementSibling)){this.focusedTag=this.focusedTag.nextElementSibling}else{this.focusedTag=t}this.focusTag(this.focusedTag)};t.prototype.addOption=function(t){var e=this.optionsList;var i=this.includesCaseInsensitive(this.optionsList,t);if(!i){e=e.concat(t)}return e};t.prototype.removeOption=function(t){this.optionsList=this.filterCaseInsensitive(this.optionsList,t)};t.prototype.addTag=function(t){var e=this.tagsList;var i=this.includesCaseInsensitive(this.tagsList,t);var o=this.optionsList.filter((function(e){return e.toLowerCase()===t.toLowerCase()}))[0];if(!i){this.announce(this.generateTagAddedMessage(t));e=e.concat(o||t)}return e};t.prototype.removeTag=function(t){var e=s.formatMessage({id:"tagInput.tagRemoved",defaultMessage:"{tag} removed"},{tag:t});this.announce(e);this.tagsList=this.filterCaseInsensitive(this.tagsList,t);var i=this.csvToArray(this.options);if(this.includesCaseInsensitive(this.optionsList,t)&&!this.includesCaseInsensitive(i,t)){this.removeOption(t)}};t.prototype.focusListItem=function(t){this.focusedListItem=t;t.focus()};t.prototype.focusTag=function(t){this.focusedTag=t;this.tagAreaEl.setAttribute("aria-activedescendant",this.focusedTag.id)};t.prototype.clearTagFocus=function(){this.tagAreaEl.removeAttribute("aria-activedescendant");this.focusedTag=null};t.prototype.openDropdown=function(){this.openUp=p(this.el,this.dropdownEl,this.el.clientHeight,-2);this.isExpanded=true};t.prototype.closeDropdown=function(){this.focusedListItem=null;this.isExpanded=false};t.prototype.clearListItemFocus=function(){this.focusedListItem=null;this.listItemEls.forEach((function(t){t.tabIndex=-1;t.classList.remove("focused")}))};t.prototype.resetInput=function(){this.charCount=0;this.inputEl.value=""};t.prototype.announce=function(t){if(this.liveRegionEl.textContent===t){t+=" "}this.liveRegionMessage=t};t.prototype.announceExistingOptions=function(){var t=this;window.requestAnimationFrame((function(){var e=s.formatMessage({id:"tagInput.existingOptions",defaultMessage:"{num, plural, one {1 existing option.} other {# existing options.}}"},{num:t.optionEls.length});if(t.optionEls.length>0){t.announce(e)}}))};t.prototype.announceCharacterLimitWarning=function(t,e){var i=s.formatMessage({id:"global.charactersEntered",defaultMessage:"{x, number} of {y, number} characters entered.",description:"for screen readers"},{x:t,y:e});var o=s.formatMessage({id:"global.characterLimitReached",defaultMessage:"No additional characters will be entered.",description:"for screen readers"});this.announce("".concat(i).concat(t>=e?" "+o:""))};t.prototype.positionInput=function(){var t=this.tagEls[this.tagEls.length-1];this.inputEl.style.position="static";this.inputEl.style.width="100%";if(t){var e=this.tagAreaEl.getBoundingClientRect().right-t.getBoundingClientRect().right;if(e>=150){this.inputEl.style.position="absolute";this.inputEl.style.top=t.offsetTop.toString()+"px";this.inputEl.style.width=(this.tagAreaEl.getBoundingClientRect().right-t.getBoundingClientRect().right-8).toString()+"px"}}};t.prototype.listToCSV=function(t){return t.join(",")};t.prototype.csvToArray=function(t){return t?t.split(/, ?/):[]};t.prototype.includesCaseInsensitive=function(t,e){var i=t.map((function(t){return t.toLowerCase()}));return i.includes(e.toLowerCase())};t.prototype.filterCaseInsensitive=function(t,e){return t.filter((function(t){return t.toLowerCase()!==e.toLowerCase()}))};t.prototype.sortCaseInsensitive=function(t){return t.sort((function(t,e){t=t.toLowerCase();e=e.toLowerCase();return t>e?1:t<e?-1:0}))};t.prototype.renderTags=function(){var t=this;return this.tagsList.map((function(e,i){var a="tag".concat(i+1);return o("li",{id:a,class:"tag highlight ".concat(t.focusedTag&&t.focusedTag.id===a?"focused":""),"data-tag":e,role:"option"},e,o("button",{class:"remove-btn",tabIndex:-1,onClick:function(){return t.handleRemoveButtonClick(e)}}))}))};t.prototype.renderListItems=function(t){var e=this;t=this.sortCaseInsensitive(t);if(this.inputEl&&this.inputEl.value){t=this.optionsList.filter((function(t){return t.toLowerCase().includes(e.inputEl.value.toLowerCase())}))}return t.map((function(t,i){var a="option".concat(i+1);var r=e.focusedListItem&&e.focusedListItem.id===a;var n=e.includesCaseInsensitive(e.tagsList,t);return o("li",{class:"option ".concat(r?"focused":""),role:"option",id:a,"data-option":t,tabIndex:r?0:-1,"aria-selected":n?"true":"false","aria-disabled":n?"true":"false",onKeyDown:function(t){return e.handleListItemKeyDown(t)},onBlur:function(t){return e.handleBlur(t,e.el)},onClick:function(t){return e.handleListItemClick(t)}},t)}))};t.prototype.renderAddNewButton=function(){var t=this;var e=this.inputEl.value.match(/\S/);var i=this.includesCaseInsensitive(this.optionsList,this.inputEl.value.trim());if(this.addNew&&e&&!i){var a="add-new-btn";var r=this.focusedListItem&&this.focusedListItem.id===a;return o("li",{role:"option",class:"add-new-btn ".concat(r?"focused":""),id:a,"data-option":this.inputEl.value,onKeyDown:function(e){return t.handleListItemKeyDown(e)},onBlur:function(e){return t.handleBlur(e,t.el)},onClick:function(e){return t.handleListItemClick(e)},tabIndex:r?0:-1},'Add "'.concat(this.inputEl.value.trim(),'"'))}else return""};t.prototype.renderHelpText=function(){var t=s.formatMessage({id:"tagInput.helpTextCanSelect",defaultMessage:"Search and select a tag.",description:"Placeholder text. Use imperative"});var e=s.formatMessage({id:"tagInput.helpTextEditable",defaultMessage:"Press the Enter or Comma key to add a new tag.",description:"Placeholder text. Use imperative"});var i="";if(this.optionsList.length>0){i+=t}if(this.addNew){i+=" "+e}return i};t.prototype.renderTagCounter=function(){if(this.maxTags){return o("div",{class:"lower-row"},o("div",{id:"max-tags"},this.generateTagCounterMessage(this.tagsList.length,this.maxTags),this.tagsList.length>=this.maxTags&&o("span",{class:"sr-only"},this.maxTagsReachedMessage)))}};t.prototype.render=function(){var t=this;var e=this.focusedElement&&(this.focusedElement===this.inputEl||this.focusedElement===this.tagAreaEl||this.focusedElement.classList.contains("add-new-btn")||this.optionsList.length>0&&this.listItemEls.includes(this.focusedElement));return o(a,{id:this.uid},o("div",{class:"wrapper label-".concat(this.labelPosition)},o("div",{class:"label-wrapper"},o("label",{class:"label",htmlFor:"input".concat(this.uid)},this.label)),o("div",{class:"field-wrapper ".concat(e?"focused":""),ref:function(e){return t.fieldWrapperEl=e}},o("div",{class:"upper-row"},o("div",{class:"tags-and-input-wrapper"},o("ul",{ref:function(e){return t.tagAreaEl=e},class:"tag-area",role:"listbox","aria-orientation":"horizontal","aria-label":"".concat(this.label," ").concat(this.tagsList.length>0?this.tagAreaInstructions:""),tabindex:this.tagsList.length>0?0:-1,"aria-describedby":"info max-tags",onFocus:function(){return t.handleTagAreaFocus()},onBlur:function(e){t.clearTagFocus();t.handleBlur(e,t.el)},onKeyDown:function(e){return t.handleTagAreaKeyDown(e)}},this.renderTags()),o("input",{id:"input".concat(this.uid),class:this.maxTags&&this.tagsList.length>=this.maxTags?"hidden":"",role:"combobox",ref:function(e){return t.inputEl=e},autocomplete:"off","aria-controls":"dropdown","aria-describedby":"help-text","aria-label":"".concat(this.label," ").concat(this.generateCharacterLimitLabel(this.characterLimit)),"aria-expanded":this.isExpanded?"true":"false",placeholder:this.placeholder,maxLength:this.characterLimit,onInput:function(){return t.handleInputChanged(t.inputEl.value)},onBlur:function(e){t.handleBlur(e,t.el)},onFocus:function(){t.openDropdown();t.clearListItemFocus()},onKeyDown:function(e){return t.handleInputKeyDown(e)}})),o("div",{class:"character-count"},this.charCount,"/",this.characterLimit)),this.renderTagCounter(),o("div",{class:"dropdown-wrapper ".concat(this.isExpanded?"open":""," ").concat(this.openUp?"upwards":""),ref:function(e){return t.dropdownEl=e}},o("div",{id:"help-text",class:"help-text"},this.renderHelpText()),o("ul",{class:"dropdown",id:"dropdown",role:"listbox","aria-multiselectable":"true","aria-expanded":this.isExpanded?"true":false,"aria-label":this.label,tabindex:-1},this.inputEl&&this.renderAddNewButton(),this.renderListItems(this.optionsList)))),this.info?o("div",{id:"info",class:"info-text"},this.info):"",o("div",{class:"sr-only","aria-live":"assertive",ref:function(e){return t.liveRegionEl=e},"aria-atomic":"true"},this.liveRegionMessage)))};Object.defineProperty(t.prototype,"el",{get:function(){return r(this)},enumerable:false,configurable:true});Object.defineProperty(t,"watchers",{get:function(){return{tagsList:["reflectSelectedTags"]}},enumerable:false,configurable:true});return t}());c.style=d}}}));
@@ -1 +1 @@
1
- import{r as t,c as s,h as e,H as i,g as r}from"./p-b3c71506.js";import{i as o}from"./p-15b1c11b.js";let n=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.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.resultsLiveRegion=null,this.wrapperEl=null,this.linkEl=null}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.el.focus=function(){this.disabled||(this.shadowRoot.querySelector("#wm-search-input").focus(),this.shadowRoot.querySelector("#wm-search-wrapper").classList.add("focus"))},""===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()}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()}resetHighlightCountToStart(){"find"===this.searchType&&(this.highlightedNum=this.numResults?1:0)}componentDidRender(){this.announceChanges()}announceChanges(){let t=this.getResultsMessage();"find"===this.searchType&&this.highlightedName&&(t+=`, ${this.highlightedName}`),this.resultsLiveRegion&&(this.resultsLiveRegion.innerHTML=""),window.requestAnimationFrame((()=>this.resultsLiveRegion&&(this.resultsLiveRegion.innerHTML=t)))}getResultsMessage(){return this.value?"basic"===this.searchType?o.formatMessage({id:"search.resultsFound",defaultMessage:"{numResults, plural, =0 {No results} one {1 result} other {# results}} found"},{numResults:this.numResults}):o.formatMessage({id:"search.xOfYResults",defaultMessage:"{numResults, plural, =0 {No results found} other {{current} of {numResults} results}}"},{numResults:this.numResults,current:this.highlightedNum}):""}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}))}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.getResultsMessage()),e("div",{class:"wm-button-collection"},e("wm-button",{"button-type":"icononly",icon:"f05d",tooltip:o.formatMessage({id:"global.previous",description:"button text",defaultMessage:"previous"}),"tooltip-position":"bottom",onClick:()=>this.changeHighlightedNum(this.highlightedNum-1),disabled:this.disabled||this.numResults<2,"label-for-identical-buttons":o.formatMessage({id:"search.previousResult",defaultMessage:"Press to hear previous matching result"})}),e("wm-button",{"button-type":"icononly",icon:"f045",tooltip:o.formatMessage({id:"global.next",description:"button text",defaultMessage:"next"}),"tooltip-position":"bottom",onClick:()=>this.changeHighlightedNum(this.highlightedNum+1),disabled:this.disabled||this.numResults<2,"label-for-identical-buttons":o.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"},o.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.disabled,id:"wm-search-input",placeholder:this.placeholder,"aria-label":`${this.label?this.label+". ":""}${o.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})),"find"===this.searchType&&this.renderJumpToLink())}get el(){return r(this)}static get watchers(){return{numResults:["resetHighlightCountToStart"]}}};n.style=':host,wm-search{width:100%;font-size:0.875rem}:host *,wm-search *{-webkit-box-sizing:border-box;box-sizing:border-box}:host .wm-search-wrapper,wm-search .wm-search-wrapper{border-radius:3px;position:relative;border:1px solid rgba(35, 35, 35, 0.6);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,wm-search .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.0625rem;position:absolute;left:0.4375rem}:host .wm-search-wrapper input,wm-search .wm-search-wrapper input{border:none;height:40px;padding:0 1.75rem;background:transparent;overflow:visible;width:100%;-ms-flex:1;flex:1;font-family:inherit}:host .wm-search-wrapper input:focus,wm-search .wm-search-wrapper input:focus{outline:none}:host .wm-search-wrapper.focus,wm-search .wm-search-wrapper.focus{-webkit-box-shadow:0 0 0 1px #20cbd4;box-shadow:0 0 0 1px #20cbd4;border-color:#20cbd4;border-radius:3px}:host .find,wm-search .find{min-height:3rem}:host .find input,wm-search .find input{padding:16px 8px 16px 28px}:host .find .wm-find-elements,wm-search .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,wm-search .find .wm-find-elements wm-button+wm-button{margin-left:0.25rem}:host .find .wm-find-elements .results,wm-search .find .wm-find-elements .results{margin-right:0.5rem;font-style:italic}:host .sr-only,wm-search .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,wm-search .show-for-tabbers{all:unset;color:#575195;text-decoration:none;font-weight:500;font-size:0.875rem;margin:10px 0}:host .show-for-tabbers:hover,wm-search .show-for-tabbers:hover{background:-webkit-gradient(linear, left top, left bottom, from(#575195), to(#575195)) no-repeat;background:linear-gradient(#575195, #575195) no-repeat;background-size:100% 1px;background-position:0 1.2em;padding-bottom:0.2em}:host .show-for-tabbers:focus,wm-search .show-for-tabbers:focus{outline:none;background:-webkit-gradient(linear, left top, right top, color-stop(66%, #3862e9), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #3862e9 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1.2em;padding-bottom:0.2em}';export{n as wm_search}
1
+ import{r as t,c as s,h as e,H as i,g as r}from"./p-b3c71506.js";import{i as o}from"./p-de3367ee.js";let n=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.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.resultsLiveRegion=null,this.wrapperEl=null,this.linkEl=null}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.el.focus=function(){this.disabled||(this.shadowRoot.querySelector("#wm-search-input").focus(),this.shadowRoot.querySelector("#wm-search-wrapper").classList.add("focus"))},""===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()}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()}resetHighlightCountToStart(){"find"===this.searchType&&(this.highlightedNum=this.numResults?1:0)}componentDidRender(){this.announceChanges()}announceChanges(){let t=this.getResultsMessage();"find"===this.searchType&&this.highlightedName&&(t+=`, ${this.highlightedName}`),this.resultsLiveRegion&&(this.resultsLiveRegion.innerHTML=""),window.requestAnimationFrame((()=>this.resultsLiveRegion&&(this.resultsLiveRegion.innerHTML=t)))}getResultsMessage(){return this.value?"basic"===this.searchType?o.formatMessage({id:"search.resultsFound",defaultMessage:"{numResults, plural, =0 {No results} one {1 result} other {# results}} found"},{numResults:this.numResults}):o.formatMessage({id:"search.xOfYResults",defaultMessage:"{numResults, plural, =0 {No results found} other {{current} of {numResults} results}}"},{numResults:this.numResults,current:this.highlightedNum}):""}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}))}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.getResultsMessage()),e("div",{class:"wm-button-collection"},e("wm-button",{"button-type":"icononly",icon:"f05d",tooltip:o.formatMessage({id:"global.previous",description:"button text",defaultMessage:"previous"}),"tooltip-position":"bottom",onClick:()=>this.changeHighlightedNum(this.highlightedNum-1),disabled:this.disabled||this.numResults<2,"label-for-identical-buttons":o.formatMessage({id:"search.previousResult",defaultMessage:"Press to hear previous matching result"})}),e("wm-button",{"button-type":"icononly",icon:"f045",tooltip:o.formatMessage({id:"global.next",description:"button text",defaultMessage:"next"}),"tooltip-position":"bottom",onClick:()=>this.changeHighlightedNum(this.highlightedNum+1),disabled:this.disabled||this.numResults<2,"label-for-identical-buttons":o.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"},o.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.disabled,id:"wm-search-input",placeholder:this.placeholder,"aria-label":`${this.label?this.label+". ":""}${o.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})),"find"===this.searchType&&this.renderJumpToLink())}get el(){return r(this)}static get watchers(){return{numResults:["resetHighlightCountToStart"]}}};n.style=':host,wm-search{width:100%;font-size:0.875rem}:host *,wm-search *{-webkit-box-sizing:border-box;box-sizing:border-box}:host .wm-search-wrapper,wm-search .wm-search-wrapper{border-radius:3px;position:relative;border:1px solid rgba(35, 35, 35, 0.6);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,wm-search .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.0625rem;position:absolute;left:0.4375rem}:host .wm-search-wrapper input,wm-search .wm-search-wrapper input{border:none;height:40px;padding:0 1.75rem;background:transparent;overflow:visible;width:100%;-ms-flex:1;flex:1;font-family:inherit}:host .wm-search-wrapper input:focus,wm-search .wm-search-wrapper input:focus{outline:none}:host .wm-search-wrapper.focus,wm-search .wm-search-wrapper.focus{-webkit-box-shadow:0 0 0 1px #20cbd4;box-shadow:0 0 0 1px #20cbd4;border-color:#20cbd4;border-radius:3px}:host .find,wm-search .find{min-height:3rem}:host .find input,wm-search .find input{padding:16px 8px 16px 28px}:host .find .wm-find-elements,wm-search .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,wm-search .find .wm-find-elements wm-button+wm-button{margin-left:0.25rem}:host .find .wm-find-elements .results,wm-search .find .wm-find-elements .results{margin-right:0.5rem;font-style:italic}:host .sr-only,wm-search .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,wm-search .show-for-tabbers{all:unset;color:#575195;text-decoration:none;font-weight:500;font-size:0.875rem;margin:10px 0}:host .show-for-tabbers:hover,wm-search .show-for-tabbers:hover{background:-webkit-gradient(linear, left top, left bottom, from(#575195), to(#575195)) no-repeat;background:linear-gradient(#575195, #575195) no-repeat;background-size:100% 1px;background-position:0 1.2em;padding-bottom:0.2em}:host .show-for-tabbers:focus,wm-search .show-for-tabbers:focus{outline:none;background:-webkit-gradient(linear, left top, right top, color-stop(66%, #3862e9), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #3862e9 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1.2em;padding-bottom:0.2em}';export{n as wm_search}
@@ -1 +1 @@
1
- import{r as e,f as r,h as p,H as t,g as a}from"./p-b3c71506.js";import{g as n,i as o,d as m}from"./p-15b1c11b.js";import{g as s,t as w,h as c,r as h,a as i,b as l,c as b,e as g,d}from"./p-8aa9f811.js";let u=class{constructor(p){e(this,p),this.chartType="doughnut1",this.showLegend=!0,this.notStartedColor=!1,this.labelPosition="top",this.isTabbing=!1,this.userIsNavigating=!1,this.uid=n(),this.slicesData=[],this.chartLabelMessage=o.formatMessage({id:"chart.interactiveChart",defaultMessage:"Interactive chart. Use arrow keys to browse elements, press Tab to exit."}),this.debouncedResize=m((async()=>{await s.call(this,this.currentChartType),r(this.el)}),10),this.debouncedSliceUpdate=m((async()=>{await s.call(this,this.currentChartType),r(this.el)}),100)}get tempValueFormat(){return this.valueFormat||this.showValues||"none"}get hybridType(){return window.innerWidth>1340?"doughnut0":"bar1"}get popoverEl(){return this.el.shadowRoot.querySelector("priv-chart-popover")}get sliceEls(){return Array.from(this.el.shadowRoot.querySelectorAll(".segment"))}get currentChartType(){return"hybrid"===this.chartType?this.hybridType:this.chartType}get chartData(){return w[this.currentChartType]}get ariaLabelText(){let e=`${this.label}, ${this.chartLabelMessage}`;return this.subinfo&&(e+=` ${this.subinfo}`),e}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}handleKeydown(e){c.call(this,e)}handleResize(){"hybrid"===this.chartType&&this.debouncedResize()}async componentWillLoad(){if(!this.label)throw new Error("For accessibility purposes, you must provide a label for the chart. See https://components.watermarkinsights.com/chart for more information.");this.showValues&&console.warn("wm-chart: show-values has been deprecated as of v3.1.0. Please use value-format instead."),await s.call(this,this.currentChartType)}handleSliceUpdate(){this.debouncedSliceUpdate()}renderBarText(e,r){let t;if("percentage"===this.tempValueFormat)t=e.perc+"%";else{if("amount"!==this.tempValueFormat)return;t=e.amount}return p("span",{class:"value",style:{width:`calc(${d(e.amount,this.total,!1)}%\n ${r!==this.slicesData.length-1?" - 2px":""}`}},t)}drawAxis(){if("bar3"===this.currentChartType)return p("svg",{class:"axis"},p("line",{x1:"0",x2:"100%",y1:"0",y2:"0"}),p("line",{x1:"0",x2:"0",y1:"0",y2:"-85px"}),p("line",{class:"tick",x1:"0.5",x2:"0.5",y1:"0",y2:"6"}),p("text",{x:"0.5",y:"-6"},"0%"),p("line",{class:"tick",x1:"100%",x2:"100%",y1:"0",y2:"6"}),p("text",{x:"100%",y:"-6"},"100%"))}render(){return p(t,{role:"application","aria-label":this.ariaLabelText,tabindex:"0",onBlur:()=>g.call(this)},p("div",{class:`component-wrapper ${this.currentChartType} ${this.isTabbing&&!this.userIsNavigating?"user-is-tabbing":""} ${"left"===this.labelPosition&&"bar4"===this.chartType?"left-label":""}`},p("label",{class:"label",id:`label-${this.uid}`,htmlFor:`graphic-${this.uid}`},p("span",{class:"label-text"},this.label),this.subinfo?p("span",{class:"subinfo"},this.subinfo):""),this.chartData.isBar?h.call(this):"",this.total>0&&this.chartData.isBar?i.call(this,this.currentChartType):l.call(this,this.currentChartType),this.chartData.isBar?"":h.call(this),p("priv-chart-popover",{class:this.isTabbing?"user-is-tabbing":""}),"doughnut0"===this.currentChartType?b.call(this):""))}get el(){return a(this)}};u.style=":host .component-wrapper,wm-chart .component-wrapper{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-align:center;align-items:center;font-size:0.875rem;position:relative;}:host .component-wrapper .label,wm-chart .component-wrapper .label{display:block;margin:0;padding-bottom:0.25rem;font-weight:500;position:relative}:host .component-wrapper .label .subinfo,wm-chart .component-wrapper .label .subinfo{display:block;font-weight:normal;font-style:italic;bottom:0.25rem;width:100%;color:#6b6b6b}:host .component-wrapper .legend-wrapper,wm-chart .component-wrapper .legend-wrapper{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;text-align:center}:host .component-wrapper .legend-wrapper .legend,wm-chart .component-wrapper .legend-wrapper .legend{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-wrap:wrap;flex-wrap:wrap;text-align:center;padding-top:0.25rem;padding-bottom:0.75rem;-webkit-box-sizing:border-box;box-sizing:border-box}:host .component-wrapper .legend-wrapper .legend.--top,wm-chart .component-wrapper .legend-wrapper .legend.--top{margin-top:-0.75rem}:host .component-wrapper .legend-wrapper .legend.--top .legend-item,wm-chart .component-wrapper .legend-wrapper .legend.--top .legend-item{padding-top:0.75rem}:host .component-wrapper .legend-wrapper .legend.--top .legend-color,wm-chart .component-wrapper .legend-wrapper .legend.--top .legend-color{top:0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom,wm-chart .component-wrapper .legend-wrapper .legend.--bottom{margin-bottom:-0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom .legend-item,wm-chart .component-wrapper .legend-wrapper .legend.--bottom .legend-item{padding-bottom:0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom .legend-color,wm-chart .component-wrapper .legend-wrapper .legend.--bottom .legend-color{top:-0.75rem}:host .component-wrapper .legend-wrapper .legend .legend-item,wm-chart .component-wrapper .legend-wrapper .legend .legend-item{position:relative}:host .component-wrapper .legend-wrapper .legend .legend-item:not(:last-of-type),wm-chart .component-wrapper .legend-wrapper .legend .legend-item:not(:last-of-type){padding-right:1.25rem}:host .component-wrapper .legend-wrapper .legend .legend-text,wm-chart .component-wrapper .legend-wrapper .legend .legend-text{padding-left:1rem;line-height:1}:host .component-wrapper .legend-wrapper .legend .legend-color,wm-chart .component-wrapper .legend-wrapper .legend .legend-color{position:absolute;left:0;bottom:0;margin:auto;width:0.6875rem;height:0.6875rem}:host .component-wrapper .legend-wrapper .cluster-warning,wm-chart .component-wrapper .legend-wrapper .cluster-warning{font-size:0.75rem;font-style:italic;max-width:100%}:host .component-wrapper .doughnut-svg,wm-chart .component-wrapper .doughnut-svg,:host .component-wrapper .inner-bar-wrapper,wm-chart .component-wrapper .inner-bar-wrapper{overflow:visible}:host .component-wrapper .bar-wrapper,wm-chart .component-wrapper .bar-wrapper{-ms-flex-positive:1;flex-grow:1;width:100%}:host .component-wrapper .bar-wrapper .inner-bar-wrapper,wm-chart .component-wrapper .bar-wrapper .inner-bar-wrapper{width:100%}:host .component-wrapper .bar-wrapper .inner-bar-wrapper .values,wm-chart .component-wrapper .bar-wrapper .inner-bar-wrapper .values{display:-ms-flexbox;display:flex}:host .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper,wm-chart .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper{display:-ms-flexbox;display:flex}:host .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper .bar-segment,wm-chart .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper .bar-segment{height:30px;cursor:pointer}:host .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper .bar-segment:not(.zero):not(:last-of-type),wm-chart .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper .bar-segment:not(.zero):not(:last-of-type){margin-right:2px}:host .component-wrapper .doughnut-wrapper,wm-chart .component-wrapper .doughnut-wrapper{-webkit-border-radius:4px;-moz-border-radius:4px;-ms-border-radius:4px;border-radius:4px}:host .component-wrapper .doughnut-wrapper .doughnut-segment,wm-chart .component-wrapper .doughnut-wrapper .doughnut-segment{cursor:pointer}:host .component-wrapper .value,wm-chart .component-wrapper .value{display:inline-block;text-align:center}:host .component-wrapper .value:not(:last-of-type),wm-chart .component-wrapper .value:not(:last-of-type){margin-right:2px}:host .component-wrapper path:active,wm-chart .component-wrapper path:active,:host .component-wrapper path:hover,wm-chart .component-wrapper path:hover,:host .component-wrapper path:focus,wm-chart .component-wrapper path:focus,:host .component-wrapper .bar-segment:active,wm-chart .component-wrapper .bar-segment:active,:host .component-wrapper .bar-segment:hover,wm-chart .component-wrapper .bar-segment:hover,:host .component-wrapper .bar-segment:focus,wm-chart .component-wrapper .bar-segment:focus{outline:none}:host .component-wrapper .bar-segment:active.bar-segment,wm-chart .component-wrapper .bar-segment:active.bar-segment,:host .component-wrapper .bar-segment:hover.bar-segment,wm-chart .component-wrapper .bar-segment:hover.bar-segment,:host .component-wrapper .bar-segment:focus.bar-segment,wm-chart .component-wrapper .bar-segment:focus.bar-segment{-webkit-box-shadow:0px 0px 6px #333;-moz-box-shadow:0px 0px 6px #333;box-shadow:0px 0px 6px #333}:host .component-wrapper path:active.doughnut-segment,wm-chart .component-wrapper path:active.doughnut-segment,:host .component-wrapper path:hover.doughnut-segment,wm-chart .component-wrapper path:hover.doughnut-segment,:host .component-wrapper path:focus.doughnut-segment,wm-chart .component-wrapper path:focus.doughnut-segment,:host .component-wrapper .bar-segment:active.doughnut-segment,wm-chart .component-wrapper .bar-segment:active.doughnut-segment,:host .component-wrapper .bar-segment:hover.doughnut-segment,wm-chart .component-wrapper .bar-segment:hover.doughnut-segment,:host .component-wrapper .bar-segment:focus.doughnut-segment,wm-chart .component-wrapper .bar-segment:focus.doughnut-segment{-webkit-filter:url(#wmHoverDropShadow);filter:url(#wmHoverDropShadow)}:host .component-wrapper path::-moz-focus-inner,wm-chart .component-wrapper path::-moz-focus-inner,:host .component-wrapper .bar-segment::-moz-focus-inner,wm-chart .component-wrapper .bar-segment::-moz-focus-inner{border:0;outline:none}:host .component-wrapper.doughnut,wm-chart .component-wrapper.doughnut{width:300px}:host .component-wrapper.doughnut1 label,wm-chart .component-wrapper.doughnut1 label,:host .component-wrapper.doughnut1 .label-text,wm-chart .component-wrapper.doughnut1 .label-text,:host .component-wrapper.doughnut2 label,wm-chart .component-wrapper.doughnut2 label,:host .component-wrapper.doughnut2 .label-text,wm-chart .component-wrapper.doughnut2 .label-text,:host .component-wrapper.doughnut3 label,wm-chart .component-wrapper.doughnut3 label,:host .component-wrapper.doughnut3 .label-text,wm-chart .component-wrapper.doughnut3 .label-text{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}:host .component-wrapper.doughnut0,wm-chart .component-wrapper.doughnut0,:host .component-wrapper.doughnut,wm-chart .component-wrapper.doughnut{-ms-flex-align:center;align-items:center}:host .component-wrapper.doughnut0 label,wm-chart .component-wrapper.doughnut0 label,:host .component-wrapper.doughnut label,wm-chart .component-wrapper.doughnut label{text-align:center;width:100%;padding-bottom:1.5rem}:host .component-wrapper.doughnut0 label .subinfo,wm-chart .component-wrapper.doughnut0 label .subinfo,:host .component-wrapper.doughnut label .subinfo,wm-chart .component-wrapper.doughnut label .subinfo{position:absolute}:host .component-wrapper.doughnut0 .legend,wm-chart .component-wrapper.doughnut0 .legend,:host .component-wrapper.doughnut .legend,wm-chart .component-wrapper.doughnut .legend{display:-ms-flexbox;display:flex}:host .component-wrapper.doughnut0 .completion-message,wm-chart .component-wrapper.doughnut0 .completion-message,:host .component-wrapper.doughnut .completion-message,wm-chart .component-wrapper.doughnut .completion-message{padding-top:0.625rem}:host .component-wrapper.bar1,wm-chart .component-wrapper.bar1,:host .component-wrapper.bar,wm-chart .component-wrapper.bar{padding:1.25rem;-ms-flex-align:start;align-items:flex-start}:host .component-wrapper.bar1 label,wm-chart .component-wrapper.bar1 label,:host .component-wrapper.bar label,wm-chart .component-wrapper.bar label{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}:host .component-wrapper.bar1 label .subinfo,wm-chart .component-wrapper.bar1 label .subinfo,:host .component-wrapper.bar label .subinfo,wm-chart .component-wrapper.bar label .subinfo{position:initial}:host .component-wrapper.bar1 .legend,wm-chart .component-wrapper.bar1 .legend,:host .component-wrapper.bar .legend,wm-chart .component-wrapper.bar .legend{display:none}:host .component-wrapper.bar1 .chart-wrapper,wm-chart .component-wrapper.bar1 .chart-wrapper,:host .component-wrapper.bar .chart-wrapper,wm-chart .component-wrapper.bar .chart-wrapper{display:-ms-flexbox;display:flex}:host .component-wrapper.bar1 .chart-wrapper .single-perc,wm-chart .component-wrapper.bar1 .chart-wrapper .single-perc,:host .component-wrapper.bar .chart-wrapper .single-perc,wm-chart .component-wrapper.bar .chart-wrapper .single-perc{width:4rem;-ms-flex:none;flex:none;display:-ms-flexbox;display:flex;height:30px;-ms-flex-align:center;align-items:center}:host .component-wrapper.bar1 .chart-wrapper .inner-bar-wrapper,wm-chart .component-wrapper.bar1 .chart-wrapper .inner-bar-wrapper,:host .component-wrapper.bar .chart-wrapper .inner-bar-wrapper,wm-chart .component-wrapper.bar .chart-wrapper .inner-bar-wrapper{-ms-flex:1;flex:1}:host .component-wrapper.bar1 .chart-wrapper .completion-message,wm-chart .component-wrapper.bar1 .chart-wrapper .completion-message,:host .component-wrapper.bar .chart-wrapper .completion-message,wm-chart .component-wrapper.bar .chart-wrapper .completion-message{width:100%;text-align:right;margin-top:0.25rem}@media screen and (min-width: 768px){:host .component-wrapper.bar1,wm-chart .component-wrapper.bar1,:host .component-wrapper.bar,wm-chart .component-wrapper.bar{-ms-flex-direction:row;flex-direction:row}:host .component-wrapper.bar1 label,wm-chart .component-wrapper.bar1 label,:host .component-wrapper.bar label,wm-chart .component-wrapper.bar label{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;min-height:30px;width:12rem;text-align:left;padding-right:1.25rem;padding-bottom:0;-ms-flex:none;flex:none}:host .component-wrapper.bar1 .bar-wrapper,wm-chart .component-wrapper.bar1 .bar-wrapper,:host .component-wrapper.bar .bar-wrapper,wm-chart .component-wrapper.bar .bar-wrapper{-ms-flex-direction:row-reverse;flex-direction:row-reverse}:host .component-wrapper.bar1 .bar-wrapper .single-perc,wm-chart .component-wrapper.bar1 .bar-wrapper .single-perc,:host .component-wrapper.bar .bar-wrapper .single-perc,wm-chart .component-wrapper.bar .bar-wrapper .single-perc{text-align:center;padding-left:0.5rem;-ms-flex-pack:center;justify-content:center}}:host .component-wrapper.bar2,wm-chart .component-wrapper.bar2,:host .component-wrapper.bar3,wm-chart .component-wrapper.bar3,:host .component-wrapper.bar4,wm-chart .component-wrapper.bar4,:host .component-wrapper.bar5,wm-chart .component-wrapper.bar5{-ms-flex-align:start;align-items:flex-start}:host .component-wrapper.bar2 .inner-bar-wrapper,wm-chart .component-wrapper.bar2 .inner-bar-wrapper,:host .component-wrapper.bar4 .inner-bar-wrapper,wm-chart .component-wrapper.bar4 .inner-bar-wrapper,:host .component-wrapper.bar5 .inner-bar-wrapper,wm-chart .component-wrapper.bar5 .inner-bar-wrapper{height:30px;margin-bottom:0}:host .component-wrapper.bar2 .inner-bar-wrapper.show-values,wm-chart .component-wrapper.bar2 .inner-bar-wrapper.show-values,:host .component-wrapper.bar4 .inner-bar-wrapper.show-values,wm-chart .component-wrapper.bar4 .inner-bar-wrapper.show-values,:host .component-wrapper.bar5 .inner-bar-wrapper.show-values,wm-chart .component-wrapper.bar5 .inner-bar-wrapper.show-values{height:60px;margin-top:0}:host .component-wrapper.bar3 .legend,wm-chart .component-wrapper.bar3 .legend{padding-bottom:1.25rem}:host .component-wrapper.bar3 .chart-wrapper,wm-chart .component-wrapper.bar3 .chart-wrapper{position:relative;height:100px}:host .component-wrapper.bar3 .chart-wrapper .inner-bar-wrapper,wm-chart .component-wrapper.bar3 .chart-wrapper .inner-bar-wrapper{position:absolute;top:35px;left:0;right:0;bottom:0;height:30px}:host .component-wrapper.bar3 .chart-wrapper .inner-bar-wrapper text,wm-chart .component-wrapper.bar3 .chart-wrapper .inner-bar-wrapper text{fill:#4a4a4a}:host .component-wrapper.bar3 .chart-wrapper .axis,wm-chart .component-wrapper.bar3 .chart-wrapper .axis{position:absolute;top:0;left:0;height:90px;width:100%;overflow:visible;-webkit-transform:translateY(90px);transform:translateY(90px)}:host .component-wrapper.bar3 .chart-wrapper .axis line,wm-chart .component-wrapper.bar3 .chart-wrapper .axis line{stroke:#eeedf4;stroke-width:1px}:host .component-wrapper.bar3 .chart-wrapper .axis text,wm-chart .component-wrapper.bar3 .chart-wrapper .axis text{-webkit-transform:translate(4px, 24px);transform:translate(4px, 24px);text-anchor:middle}:host .component-wrapper.left-label,wm-chart .component-wrapper.left-label{-ms-flex-direction:row;flex-direction:row}:host .component-wrapper.left-label .label,wm-chart .component-wrapper.left-label .label{width:12rem;padding-right:1.25rem;-ms-flex:none;flex:none;-ms-flex-item-align:end;align-self:flex-end;min-height:30px;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}:host(:focus){outline:none}:host(:focus) .component-wrapper.user-is-tabbing .bar-segments-wrapper,:host(:focus) .component-wrapper.user-is-tabbing .doughnut-wrapper{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}:host(:focus) .component-wrapper.user-is-tabbing .bar-segments-wrapper::-moz-focus-inner,:host(:focus) .component-wrapper.user-is-tabbing .doughnut-wrapper::-moz-focus-inner{border:0}";export{u as wm_chart}
1
+ import{r as e,f as r,h as p,H as t,g as a}from"./p-b3c71506.js";import{g as n,i as o,d as m}from"./p-de3367ee.js";import{g as s,t as w,h as c,r as h,a as i,b as l,c as b,e as g,d}from"./p-4ecd3430.js";let u=class{constructor(p){e(this,p),this.chartType="doughnut1",this.showLegend=!0,this.notStartedColor=!1,this.labelPosition="top",this.isTabbing=!1,this.userIsNavigating=!1,this.uid=n(),this.slicesData=[],this.chartLabelMessage=o.formatMessage({id:"chart.interactiveChart",defaultMessage:"Interactive chart. Use arrow keys to browse elements, press Tab to exit."}),this.debouncedResize=m((async()=>{await s.call(this,this.currentChartType),r(this.el)}),10),this.debouncedSliceUpdate=m((async()=>{await s.call(this,this.currentChartType),r(this.el)}),100)}get tempValueFormat(){return this.valueFormat||this.showValues||"none"}get hybridType(){return window.innerWidth>1340?"doughnut0":"bar1"}get popoverEl(){return this.el.shadowRoot.querySelector("priv-chart-popover")}get sliceEls(){return Array.from(this.el.shadowRoot.querySelectorAll(".segment"))}get currentChartType(){return"hybrid"===this.chartType?this.hybridType:this.chartType}get chartData(){return w[this.currentChartType]}get ariaLabelText(){let e=`${this.label}, ${this.chartLabelMessage}`;return this.subinfo&&(e+=` ${this.subinfo}`),e}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}handleKeydown(e){c.call(this,e)}handleResize(){"hybrid"===this.chartType&&this.debouncedResize()}async componentWillLoad(){if(!this.label)throw new Error("For accessibility purposes, you must provide a label for the chart. See https://components.watermarkinsights.com/chart for more information.");this.showValues&&console.warn("wm-chart: show-values has been deprecated as of v3.1.0. Please use value-format instead."),await s.call(this,this.currentChartType)}handleSliceUpdate(){this.debouncedSliceUpdate()}renderBarText(e,r){let t;if("percentage"===this.tempValueFormat)t=e.perc+"%";else{if("amount"!==this.tempValueFormat)return;t=e.amount}return p("span",{class:"value",style:{width:`calc(${d(e.amount,this.total,!1)}%\n ${r!==this.slicesData.length-1?" - 2px":""}`}},t)}drawAxis(){if("bar3"===this.currentChartType)return p("svg",{class:"axis"},p("line",{x1:"0",x2:"100%",y1:"0",y2:"0"}),p("line",{x1:"0",x2:"0",y1:"0",y2:"-85px"}),p("line",{class:"tick",x1:"0.5",x2:"0.5",y1:"0",y2:"6"}),p("text",{x:"0.5",y:"-6"},"0%"),p("line",{class:"tick",x1:"100%",x2:"100%",y1:"0",y2:"6"}),p("text",{x:"100%",y:"-6"},"100%"))}render(){return p(t,{role:"application","aria-label":this.ariaLabelText,tabindex:"0",onBlur:()=>g.call(this)},p("div",{class:`component-wrapper ${this.currentChartType} ${this.isTabbing&&!this.userIsNavigating?"user-is-tabbing":""} ${"left"===this.labelPosition&&"bar4"===this.chartType?"left-label":""}`},p("label",{class:"label",id:`label-${this.uid}`,htmlFor:`graphic-${this.uid}`},p("span",{class:"label-text"},this.label),this.subinfo?p("span",{class:"subinfo"},this.subinfo):""),this.chartData.isBar?h.call(this):"",this.total>0&&this.chartData.isBar?i.call(this,this.currentChartType):l.call(this,this.currentChartType),this.chartData.isBar?"":h.call(this),p("priv-chart-popover",{class:this.isTabbing?"user-is-tabbing":""}),"doughnut0"===this.currentChartType?b.call(this):""))}get el(){return a(this)}};u.style=":host .component-wrapper,wm-chart .component-wrapper{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-align:center;align-items:center;font-size:0.875rem;position:relative;}:host .component-wrapper .label,wm-chart .component-wrapper .label{display:block;margin:0;padding-bottom:0.25rem;font-weight:500;position:relative}:host .component-wrapper .label .subinfo,wm-chart .component-wrapper .label .subinfo{display:block;font-weight:normal;font-style:italic;bottom:0.25rem;width:100%;color:#6b6b6b}:host .component-wrapper .legend-wrapper,wm-chart .component-wrapper .legend-wrapper{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;text-align:center}:host .component-wrapper .legend-wrapper .legend,wm-chart .component-wrapper .legend-wrapper .legend{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-wrap:wrap;flex-wrap:wrap;text-align:center;padding-top:0.25rem;padding-bottom:0.75rem;-webkit-box-sizing:border-box;box-sizing:border-box}:host .component-wrapper .legend-wrapper .legend.--top,wm-chart .component-wrapper .legend-wrapper .legend.--top{margin-top:-0.75rem}:host .component-wrapper .legend-wrapper .legend.--top .legend-item,wm-chart .component-wrapper .legend-wrapper .legend.--top .legend-item{padding-top:0.75rem}:host .component-wrapper .legend-wrapper .legend.--top .legend-color,wm-chart .component-wrapper .legend-wrapper .legend.--top .legend-color{top:0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom,wm-chart .component-wrapper .legend-wrapper .legend.--bottom{margin-bottom:-0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom .legend-item,wm-chart .component-wrapper .legend-wrapper .legend.--bottom .legend-item{padding-bottom:0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom .legend-color,wm-chart .component-wrapper .legend-wrapper .legend.--bottom .legend-color{top:-0.75rem}:host .component-wrapper .legend-wrapper .legend .legend-item,wm-chart .component-wrapper .legend-wrapper .legend .legend-item{position:relative}:host .component-wrapper .legend-wrapper .legend .legend-item:not(:last-of-type),wm-chart .component-wrapper .legend-wrapper .legend .legend-item:not(:last-of-type){padding-right:1.25rem}:host .component-wrapper .legend-wrapper .legend .legend-text,wm-chart .component-wrapper .legend-wrapper .legend .legend-text{padding-left:1rem;line-height:1}:host .component-wrapper .legend-wrapper .legend .legend-color,wm-chart .component-wrapper .legend-wrapper .legend .legend-color{position:absolute;left:0;bottom:0;margin:auto;width:0.6875rem;height:0.6875rem}:host .component-wrapper .legend-wrapper .cluster-warning,wm-chart .component-wrapper .legend-wrapper .cluster-warning{font-size:0.75rem;font-style:italic;max-width:100%}:host .component-wrapper .doughnut-svg,wm-chart .component-wrapper .doughnut-svg,:host .component-wrapper .inner-bar-wrapper,wm-chart .component-wrapper .inner-bar-wrapper{overflow:visible}:host .component-wrapper .bar-wrapper,wm-chart .component-wrapper .bar-wrapper{-ms-flex-positive:1;flex-grow:1;width:100%}:host .component-wrapper .bar-wrapper .inner-bar-wrapper,wm-chart .component-wrapper .bar-wrapper .inner-bar-wrapper{width:100%}:host .component-wrapper .bar-wrapper .inner-bar-wrapper .values,wm-chart .component-wrapper .bar-wrapper .inner-bar-wrapper .values{display:-ms-flexbox;display:flex}:host .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper,wm-chart .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper{display:-ms-flexbox;display:flex}:host .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper .bar-segment,wm-chart .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper .bar-segment{height:30px;cursor:pointer}:host .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper .bar-segment:not(.zero):not(:last-of-type),wm-chart .component-wrapper .bar-wrapper .inner-bar-wrapper .bar-segments-wrapper .bar-segment:not(.zero):not(:last-of-type){margin-right:2px}:host .component-wrapper .doughnut-wrapper,wm-chart .component-wrapper .doughnut-wrapper{-webkit-border-radius:4px;-moz-border-radius:4px;-ms-border-radius:4px;border-radius:4px}:host .component-wrapper .doughnut-wrapper .doughnut-segment,wm-chart .component-wrapper .doughnut-wrapper .doughnut-segment{cursor:pointer}:host .component-wrapper .value,wm-chart .component-wrapper .value{display:inline-block;text-align:center}:host .component-wrapper .value:not(:last-of-type),wm-chart .component-wrapper .value:not(:last-of-type){margin-right:2px}:host .component-wrapper path:active,wm-chart .component-wrapper path:active,:host .component-wrapper path:hover,wm-chart .component-wrapper path:hover,:host .component-wrapper path:focus,wm-chart .component-wrapper path:focus,:host .component-wrapper .bar-segment:active,wm-chart .component-wrapper .bar-segment:active,:host .component-wrapper .bar-segment:hover,wm-chart .component-wrapper .bar-segment:hover,:host .component-wrapper .bar-segment:focus,wm-chart .component-wrapper .bar-segment:focus{outline:none}:host .component-wrapper .bar-segment:active.bar-segment,wm-chart .component-wrapper .bar-segment:active.bar-segment,:host .component-wrapper .bar-segment:hover.bar-segment,wm-chart .component-wrapper .bar-segment:hover.bar-segment,:host .component-wrapper .bar-segment:focus.bar-segment,wm-chart .component-wrapper .bar-segment:focus.bar-segment{-webkit-box-shadow:0px 0px 6px #333;-moz-box-shadow:0px 0px 6px #333;box-shadow:0px 0px 6px #333}:host .component-wrapper path:active.doughnut-segment,wm-chart .component-wrapper path:active.doughnut-segment,:host .component-wrapper path:hover.doughnut-segment,wm-chart .component-wrapper path:hover.doughnut-segment,:host .component-wrapper path:focus.doughnut-segment,wm-chart .component-wrapper path:focus.doughnut-segment,:host .component-wrapper .bar-segment:active.doughnut-segment,wm-chart .component-wrapper .bar-segment:active.doughnut-segment,:host .component-wrapper .bar-segment:hover.doughnut-segment,wm-chart .component-wrapper .bar-segment:hover.doughnut-segment,:host .component-wrapper .bar-segment:focus.doughnut-segment,wm-chart .component-wrapper .bar-segment:focus.doughnut-segment{-webkit-filter:url(#wmHoverDropShadow);filter:url(#wmHoverDropShadow)}:host .component-wrapper path::-moz-focus-inner,wm-chart .component-wrapper path::-moz-focus-inner,:host .component-wrapper .bar-segment::-moz-focus-inner,wm-chart .component-wrapper .bar-segment::-moz-focus-inner{border:0;outline:none}:host .component-wrapper.doughnut,wm-chart .component-wrapper.doughnut{width:300px}:host .component-wrapper.doughnut1 label,wm-chart .component-wrapper.doughnut1 label,:host .component-wrapper.doughnut1 .label-text,wm-chart .component-wrapper.doughnut1 .label-text,:host .component-wrapper.doughnut2 label,wm-chart .component-wrapper.doughnut2 label,:host .component-wrapper.doughnut2 .label-text,wm-chart .component-wrapper.doughnut2 .label-text,:host .component-wrapper.doughnut3 label,wm-chart .component-wrapper.doughnut3 label,:host .component-wrapper.doughnut3 .label-text,wm-chart .component-wrapper.doughnut3 .label-text{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}:host .component-wrapper.doughnut0,wm-chart .component-wrapper.doughnut0,:host .component-wrapper.doughnut,wm-chart .component-wrapper.doughnut{-ms-flex-align:center;align-items:center}:host .component-wrapper.doughnut0 label,wm-chart .component-wrapper.doughnut0 label,:host .component-wrapper.doughnut label,wm-chart .component-wrapper.doughnut label{text-align:center;width:100%;padding-bottom:1.5rem}:host .component-wrapper.doughnut0 label .subinfo,wm-chart .component-wrapper.doughnut0 label .subinfo,:host .component-wrapper.doughnut label .subinfo,wm-chart .component-wrapper.doughnut label .subinfo{position:absolute}:host .component-wrapper.doughnut0 .legend,wm-chart .component-wrapper.doughnut0 .legend,:host .component-wrapper.doughnut .legend,wm-chart .component-wrapper.doughnut .legend{display:-ms-flexbox;display:flex}:host .component-wrapper.doughnut0 .completion-message,wm-chart .component-wrapper.doughnut0 .completion-message,:host .component-wrapper.doughnut .completion-message,wm-chart .component-wrapper.doughnut .completion-message{padding-top:0.625rem}:host .component-wrapper.bar1,wm-chart .component-wrapper.bar1,:host .component-wrapper.bar,wm-chart .component-wrapper.bar{padding:1.25rem;-ms-flex-align:start;align-items:flex-start}:host .component-wrapper.bar1 label,wm-chart .component-wrapper.bar1 label,:host .component-wrapper.bar label,wm-chart .component-wrapper.bar label{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}:host .component-wrapper.bar1 label .subinfo,wm-chart .component-wrapper.bar1 label .subinfo,:host .component-wrapper.bar label .subinfo,wm-chart .component-wrapper.bar label .subinfo{position:initial}:host .component-wrapper.bar1 .legend,wm-chart .component-wrapper.bar1 .legend,:host .component-wrapper.bar .legend,wm-chart .component-wrapper.bar .legend{display:none}:host .component-wrapper.bar1 .chart-wrapper,wm-chart .component-wrapper.bar1 .chart-wrapper,:host .component-wrapper.bar .chart-wrapper,wm-chart .component-wrapper.bar .chart-wrapper{display:-ms-flexbox;display:flex}:host .component-wrapper.bar1 .chart-wrapper .single-perc,wm-chart .component-wrapper.bar1 .chart-wrapper .single-perc,:host .component-wrapper.bar .chart-wrapper .single-perc,wm-chart .component-wrapper.bar .chart-wrapper .single-perc{width:4rem;-ms-flex:none;flex:none;display:-ms-flexbox;display:flex;height:30px;-ms-flex-align:center;align-items:center}:host .component-wrapper.bar1 .chart-wrapper .inner-bar-wrapper,wm-chart .component-wrapper.bar1 .chart-wrapper .inner-bar-wrapper,:host .component-wrapper.bar .chart-wrapper .inner-bar-wrapper,wm-chart .component-wrapper.bar .chart-wrapper .inner-bar-wrapper{-ms-flex:1;flex:1}:host .component-wrapper.bar1 .chart-wrapper .completion-message,wm-chart .component-wrapper.bar1 .chart-wrapper .completion-message,:host .component-wrapper.bar .chart-wrapper .completion-message,wm-chart .component-wrapper.bar .chart-wrapper .completion-message{width:100%;text-align:right;margin-top:0.25rem}@media screen and (min-width: 768px){:host .component-wrapper.bar1,wm-chart .component-wrapper.bar1,:host .component-wrapper.bar,wm-chart .component-wrapper.bar{-ms-flex-direction:row;flex-direction:row}:host .component-wrapper.bar1 label,wm-chart .component-wrapper.bar1 label,:host .component-wrapper.bar label,wm-chart .component-wrapper.bar label{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;min-height:30px;width:12rem;text-align:left;padding-right:1.25rem;padding-bottom:0;-ms-flex:none;flex:none}:host .component-wrapper.bar1 .bar-wrapper,wm-chart .component-wrapper.bar1 .bar-wrapper,:host .component-wrapper.bar .bar-wrapper,wm-chart .component-wrapper.bar .bar-wrapper{-ms-flex-direction:row-reverse;flex-direction:row-reverse}:host .component-wrapper.bar1 .bar-wrapper .single-perc,wm-chart .component-wrapper.bar1 .bar-wrapper .single-perc,:host .component-wrapper.bar .bar-wrapper .single-perc,wm-chart .component-wrapper.bar .bar-wrapper .single-perc{text-align:center;padding-left:0.5rem;-ms-flex-pack:center;justify-content:center}}:host .component-wrapper.bar2,wm-chart .component-wrapper.bar2,:host .component-wrapper.bar3,wm-chart .component-wrapper.bar3,:host .component-wrapper.bar4,wm-chart .component-wrapper.bar4,:host .component-wrapper.bar5,wm-chart .component-wrapper.bar5{-ms-flex-align:start;align-items:flex-start}:host .component-wrapper.bar2 .inner-bar-wrapper,wm-chart .component-wrapper.bar2 .inner-bar-wrapper,:host .component-wrapper.bar4 .inner-bar-wrapper,wm-chart .component-wrapper.bar4 .inner-bar-wrapper,:host .component-wrapper.bar5 .inner-bar-wrapper,wm-chart .component-wrapper.bar5 .inner-bar-wrapper{height:30px;margin-bottom:0}:host .component-wrapper.bar2 .inner-bar-wrapper.show-values,wm-chart .component-wrapper.bar2 .inner-bar-wrapper.show-values,:host .component-wrapper.bar4 .inner-bar-wrapper.show-values,wm-chart .component-wrapper.bar4 .inner-bar-wrapper.show-values,:host .component-wrapper.bar5 .inner-bar-wrapper.show-values,wm-chart .component-wrapper.bar5 .inner-bar-wrapper.show-values{height:60px;margin-top:0}:host .component-wrapper.bar3 .legend,wm-chart .component-wrapper.bar3 .legend{padding-bottom:1.25rem}:host .component-wrapper.bar3 .chart-wrapper,wm-chart .component-wrapper.bar3 .chart-wrapper{position:relative;height:100px}:host .component-wrapper.bar3 .chart-wrapper .inner-bar-wrapper,wm-chart .component-wrapper.bar3 .chart-wrapper .inner-bar-wrapper{position:absolute;top:35px;left:0;right:0;bottom:0;height:30px}:host .component-wrapper.bar3 .chart-wrapper .inner-bar-wrapper text,wm-chart .component-wrapper.bar3 .chart-wrapper .inner-bar-wrapper text{fill:#4a4a4a}:host .component-wrapper.bar3 .chart-wrapper .axis,wm-chart .component-wrapper.bar3 .chart-wrapper .axis{position:absolute;top:0;left:0;height:90px;width:100%;overflow:visible;-webkit-transform:translateY(90px);transform:translateY(90px)}:host .component-wrapper.bar3 .chart-wrapper .axis line,wm-chart .component-wrapper.bar3 .chart-wrapper .axis line{stroke:#eeedf4;stroke-width:1px}:host .component-wrapper.bar3 .chart-wrapper .axis text,wm-chart .component-wrapper.bar3 .chart-wrapper .axis text{-webkit-transform:translate(4px, 24px);transform:translate(4px, 24px);text-anchor:middle}:host .component-wrapper.left-label,wm-chart .component-wrapper.left-label{-ms-flex-direction:row;flex-direction:row}:host .component-wrapper.left-label .label,wm-chart .component-wrapper.left-label .label{width:12rem;padding-right:1.25rem;-ms-flex:none;flex:none;-ms-flex-item-align:end;align-self:flex-end;min-height:30px;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}:host(:focus){outline:none}:host(:focus) .component-wrapper.user-is-tabbing .bar-segments-wrapper,:host(:focus) .component-wrapper.user-is-tabbing .doughnut-wrapper{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}:host(:focus) .component-wrapper.user-is-tabbing .bar-segments-wrapper::-moz-focus-inner,:host(:focus) .component-wrapper.user-is-tabbing .doughnut-wrapper::-moz-focus-inner{border:0}";export{u as wm_chart}
@@ -1 +1 @@
1
- System.register(["./p-a0c3ef16.system.js","./p-76ca7498.system.js"],(function(e){"use strict";var r,t,i,a,n,o,s,l;return{setters:[function(e){r=e.r;t=e.c;i=e.h;a=e.H;n=e.g},function(e){o=e.i;s=e.g;l=e.e}],execute:function(){var p=':host,wm-input{font-family:inherit;width:100%}:host *,wm-input *{-webkit-box-sizing:border-box;box-sizing:border-box}:host .wrapper,wm-input .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,wm-input .wrapper .label{display:block;line-height:normal;font-weight:600;white-space:nowrap;margin-bottom:0.25rem}:host .wrapper .label .required,wm-input .wrapper .label .required{color:#c0392b}:host .wrapper.label-left,wm-input .wrapper.label-left{-ms-flex-direction:row;flex-direction:row}:host .wrapper.label-left .label-wrapper,wm-input .wrapper.label-left .label-wrapper{line-height:2.5rem}:host .wrapper.label-left .label-wrapper .label,wm-input .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,wm-input .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,wm-input .wrapper.invalid .label{color:#c0392b}:host .wrapper.invalid .label:after,wm-input .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,[dir=RTL] wm-input .wrapper.invalid .label:after{margin-left:0;margin-right:0.3125rem}:host .wrapper.rtl.label-left .label,wm-input .wrapper.rtl.label-left .label{margin-right:0;margin-left:0.75rem}:host .wrapper .inner-wrapper,wm-input .wrapper .inner-wrapper{width:100%}:host .wrapper .inputfield-wrapper,wm-input .wrapper .inputfield-wrapper{height:2.5rem;border:1px solid #4a4a4a;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;display:-ms-flexbox;display:flex}:host .wrapper .character-count,wm-input .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:rgba(74, 74, 74, 0.05);font-size:0.875rem;font-weight:500;-ms-flex-item-align:stretch;align-self:stretch}:host .wrapper input,wm-input .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:disabled,wm-input .wrapper input:disabled{background-color:#f0f0f0;color:#737373}:host .wrapper input:focus,wm-input .wrapper input:focus{outline:none}:host .wrapper .info,wm-input .wrapper .info{font-style:italic;line-height:100%;margin:4px 0}:host .wrapper.invalid .inputfield-wrapper,wm-input .wrapper.invalid .inputfield-wrapper{-webkit-box-shadow:0 0 0 1px #c0392b;-moz-box-shadow:0 0 0 1px #c0392b;box-shadow:0 0 0 1px #c0392b;border-color:#c0392b}:host .wrapper.invalid .error-message,wm-input .wrapper.invalid .error-message{color:#c0392b;margin:4px 0;display:block;font-style:italic;line-height:100%}:host .wrapper:focus .inputfield-wrapper,:host .wrapper.focus .inputfield-wrapper,wm-input .wrapper:focus .inputfield-wrapper,wm-input .wrapper.focus .inputfield-wrapper{-webkit-box-shadow:0 0 0 1px #20cbd4;-moz-box-shadow:0 0 0 1px #20cbd4;box-shadow:0 0 0 1px #20cbd4;outline:none;border-color:#20cbd4}:host .sr-only,wm-input .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 u=e("wm_input",function(){function e(e){r(this,e);this.wmInputValueChanged=t(this,"wmInputValueChanged",7);this.labelPosition="top";this.value="";this.disabled=false;this.placeholder="";this.requiredField=false;this.type="text";this.step=1;this.announcement="";this.displayedErrorMessage="";this.uid="";this.previousBlurredValue="";this.requiredErrorMessage=o.formatMessage({id:"global.requiredError",defaultMessage:"This field is required."});this.numberErrorMessage=o.formatMessage({id:"input.numberError",defaultMessage:"Please enter a valid number."})}Object.defineProperty(e.prototype,"charCount",{get:function(){return this.value.length},enumerable:false,configurable:true});e.prototype.componentWillLoad=function(){this.uid=this.el.id?this.el.id:s();this.el.focus=function(){if(!this.disabled){this.shadowRoot.querySelector("input").focus()}};if(!this.label){console.error("wm-input requires the label property")}};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.handleKeyDown=function(e){var r=e.ctrlKey||e.metaKey||e.altKey;var t=/^.$/.test(e.key)&&!r;var i=t&&this.characterLimit&&this.inputEl.value.length>=this.characterLimit;if(i){this.announce(this.generateCharacterLimitWarning(this.charCount,this.characterLimit))}};e.prototype.handleBlur=function(e){if(this.value!==this.previousBlurredValue){this.wmInputValueChanged.emit({value:this.value})}this.previousBlurredValue=this.value;var r=this.preventValidation&&l(e,this.preventValidation);if(!r){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,r){return e?e:r()}),"")}};e.prototype.validateRequired=function(){return this.requiredField&&this.value===""?this.requiredErrorMessage:""};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,r){var t=o.formatMessage({id:"global.charactersEntered",defaultMessage:"{x, number} of {y, number} characters entered.",description:"for screen readers"},{x:e,y:r});var i=o.formatMessage({id:"global.characterLimitReached",defaultMessage:"No additional characters will be entered.",description:"for screen readers"});return"".concat(t).concat(e>=r?" "+i:"")};e.prototype.generateCharacterLimitLabel=function(e){return o.formatMessage({id:"global.characterLimit",defaultMessage:"{limit, number} characters allowed.",description:"for screen readers"},{limit:e})};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(r){return e.inputWrapperEl=r}},i("div",{class:"label-wrapper"},this.labelPosition!=="none"&&i("label",{htmlFor:"inputfield-".concat(this.uid),class:"label"},this.label,this.requiredField&&i("span",{class:"required","aria-hidden":"true"},"*"))),i("div",{class:"inner-wrapper"},i("div",{class:"inputfield-wrapper"},i("input",{ref:function(r){return e.inputEl=r},id:"inputfield-".concat(this.uid),disabled:this.disabled,"aria-label":"".concat(this.label).concat(this.characterLimit?" "+this.generateCharacterLimitLabel(this.characterLimit):""),"aria-describedby":"info-".concat(this.uid," error-").concat(this.uid),onInput:function(r){return e.handleInput(r)},onKeyDown:function(r){return e.handleKeyDown(r)},onBlur:function(r){return e.handleBlur(r)},onFocus:this.handleFocus.bind(this),placeholder:this.placeholder,autocomplete:"off",required:this.requiredField,maxLength:this.characterLimit||undefined,type:this.type,step:this.step,max:this.max,min:this.min}),this.characterLimit&&typeof this.characterLimit==="number"?i("div",{class:"character-count"},this.charCount,"/",this.characterLimit):""),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(r){return e.liveRegionEl=r}},this.announcement))))};Object.defineProperty(e.prototype,"el",{get:function(){return n(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{errorMessage:["handleErrorMessage"]}},enumerable:false,configurable:true});return e}());u.style=p}}}));
1
+ System.register(["./p-a0c3ef16.system.js","./p-726c979a.system.js"],(function(e){"use strict";var r,t,i,a,n,o,s,l;return{setters:[function(e){r=e.r;t=e.c;i=e.h;a=e.H;n=e.g},function(e){o=e.i;s=e.g;l=e.e}],execute:function(){var p=':host,wm-input{font-family:inherit;width:100%}:host *,wm-input *{-webkit-box-sizing:border-box;box-sizing:border-box}:host .wrapper,wm-input .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,wm-input .wrapper .label{display:block;line-height:normal;font-weight:600;white-space:nowrap;margin-bottom:0.25rem}:host .wrapper .label .required,wm-input .wrapper .label .required{color:#c0392b}:host .wrapper.label-left,wm-input .wrapper.label-left{-ms-flex-direction:row;flex-direction:row}:host .wrapper.label-left .label-wrapper,wm-input .wrapper.label-left .label-wrapper{line-height:2.5rem}:host .wrapper.label-left .label-wrapper .label,wm-input .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,wm-input .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,wm-input .wrapper.invalid .label{color:#c0392b}:host .wrapper.invalid .label:after,wm-input .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,[dir=RTL] wm-input .wrapper.invalid .label:after{margin-left:0;margin-right:0.3125rem}:host .wrapper.rtl.label-left .label,wm-input .wrapper.rtl.label-left .label{margin-right:0;margin-left:0.75rem}:host .wrapper .inner-wrapper,wm-input .wrapper .inner-wrapper{width:100%}:host .wrapper .inputfield-wrapper,wm-input .wrapper .inputfield-wrapper{height:2.5rem;border:1px solid #4a4a4a;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;display:-ms-flexbox;display:flex}:host .wrapper .character-count,wm-input .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:rgba(74, 74, 74, 0.05);font-size:0.875rem;font-weight:500;-ms-flex-item-align:stretch;align-self:stretch}:host .wrapper input,wm-input .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:disabled,wm-input .wrapper input:disabled{background-color:#f0f0f0;color:#737373}:host .wrapper input:focus,wm-input .wrapper input:focus{outline:none}:host .wrapper .info,wm-input .wrapper .info{font-style:italic;line-height:100%;margin:4px 0}:host .wrapper.invalid .inputfield-wrapper,wm-input .wrapper.invalid .inputfield-wrapper{-webkit-box-shadow:0 0 0 1px #c0392b;-moz-box-shadow:0 0 0 1px #c0392b;box-shadow:0 0 0 1px #c0392b;border-color:#c0392b}:host .wrapper.invalid .error-message,wm-input .wrapper.invalid .error-message{color:#c0392b;margin:4px 0;display:block;font-style:italic;line-height:100%}:host .wrapper:focus .inputfield-wrapper,:host .wrapper.focus .inputfield-wrapper,wm-input .wrapper:focus .inputfield-wrapper,wm-input .wrapper.focus .inputfield-wrapper{-webkit-box-shadow:0 0 0 1px #20cbd4;-moz-box-shadow:0 0 0 1px #20cbd4;box-shadow:0 0 0 1px #20cbd4;outline:none;border-color:#20cbd4}:host .sr-only,wm-input .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 u=e("wm_input",function(){function e(e){r(this,e);this.wmInputValueChanged=t(this,"wmInputValueChanged",7);this.labelPosition="top";this.value="";this.disabled=false;this.placeholder="";this.requiredField=false;this.type="text";this.step=1;this.announcement="";this.displayedErrorMessage="";this.uid="";this.previousBlurredValue="";this.requiredErrorMessage=o.formatMessage({id:"global.requiredError",defaultMessage:"This field is required."});this.numberErrorMessage=o.formatMessage({id:"input.numberError",defaultMessage:"Please enter a valid number."})}Object.defineProperty(e.prototype,"charCount",{get:function(){return this.value.length},enumerable:false,configurable:true});e.prototype.componentWillLoad=function(){this.uid=this.el.id?this.el.id:s();this.el.focus=function(){if(!this.disabled){this.shadowRoot.querySelector("input").focus()}};if(!this.label){console.error("wm-input requires the label property")}};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.handleKeyDown=function(e){var r=e.ctrlKey||e.metaKey||e.altKey;var t=/^.$/.test(e.key)&&!r;var i=t&&this.characterLimit&&this.inputEl.value.length>=this.characterLimit;if(i){this.announce(this.generateCharacterLimitWarning(this.charCount,this.characterLimit))}};e.prototype.handleBlur=function(e){if(this.value!==this.previousBlurredValue){this.wmInputValueChanged.emit({value:this.value})}this.previousBlurredValue=this.value;var r=this.preventValidation&&l(e,this.preventValidation);if(!r){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,r){return e?e:r()}),"")}};e.prototype.validateRequired=function(){return this.requiredField&&this.value===""?this.requiredErrorMessage:""};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,r){var t=o.formatMessage({id:"global.charactersEntered",defaultMessage:"{x, number} of {y, number} characters entered.",description:"for screen readers"},{x:e,y:r});var i=o.formatMessage({id:"global.characterLimitReached",defaultMessage:"No additional characters will be entered.",description:"for screen readers"});return"".concat(t).concat(e>=r?" "+i:"")};e.prototype.generateCharacterLimitLabel=function(e){return o.formatMessage({id:"global.characterLimit",defaultMessage:"{limit, number} characters allowed.",description:"for screen readers"},{limit:e})};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(r){return e.inputWrapperEl=r}},i("div",{class:"label-wrapper"},this.labelPosition!=="none"&&i("label",{htmlFor:"inputfield-".concat(this.uid),class:"label"},this.label,this.requiredField&&i("span",{class:"required","aria-hidden":"true"},"*"))),i("div",{class:"inner-wrapper"},i("div",{class:"inputfield-wrapper"},i("input",{ref:function(r){return e.inputEl=r},id:"inputfield-".concat(this.uid),disabled:this.disabled,"aria-label":"".concat(this.label).concat(this.characterLimit?" "+this.generateCharacterLimitLabel(this.characterLimit):""),"aria-describedby":"info-".concat(this.uid," error-").concat(this.uid),onInput:function(r){return e.handleInput(r)},onKeyDown:function(r){return e.handleKeyDown(r)},onBlur:function(r){return e.handleBlur(r)},onFocus:this.handleFocus.bind(this),placeholder:this.placeholder,autocomplete:"off",required:this.requiredField,maxLength:this.characterLimit||undefined,type:this.type,step:this.step,max:this.max,min:this.min}),this.characterLimit&&typeof this.characterLimit==="number"?i("div",{class:"character-count"},this.charCount,"/",this.characterLimit):""),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(r){return e.liveRegionEl=r}},this.announcement))))};Object.defineProperty(e.prototype,"el",{get:function(){return n(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{errorMessage:["handleErrorMessage"]}},enumerable:false,configurable:true});return e}());u.style=p}}}));
@@ -0,0 +1 @@
1
+ import{r as t,h as e,g as i}from"./p-b3c71506.js";let o=class{constructor(e){t(this,e),this.secondaryText="",this.primaryText="",this.infoText="",this.primaryActionDisabled=!1,this.deleteStyle=!1}componentWillLoad(){this.uid=this.el.parentElement.uid,this.el.parentElement.addEventListener("focusLastElement",(()=>{this.lastElement.focus()}))}emitParentPrimaryEvent(){this.el.parentElement.emitPrimaryEvent()}emitParentSecondaryEvent(){this.el.parentElement.emitSecondaryEvent()}render(){return e("div",{class:"wm-wrapper "+(this.infoText?" footer-text":"")},e("div",{class:"wm-info","aria-live":"polite"},this.infoText),e("div",{class:"wm-button-collection"},this.secondaryText&&e("wm-button",{onClick:()=>this.emitParentSecondaryEvent(),id:`wm-secondary-${this.uid}`,ref:t=>this.primaryActionDisabled?this.lastElement=t:null},this.secondaryText),e("wm-button",{"button-type":this.deleteStyle?"secondary":"primary","permanently-delete":this.deleteStyle,onClick:()=>this.emitParentPrimaryEvent(),disabled:this.primaryActionDisabled,id:`wm-primary-${this.uid}`,ref:t=>this.primaryActionDisabled?null:this.lastElement=t},this.primaryText)))}get el(){return i(this)}};o.style="wm-modal-footer{-webkit-border-radius:0px 0px 5px 5px;-moz-border-radius:0px 0px 5px 5px;-ms-border-radius:0px 0px 5px 5px;border-radius:0px 0px 5px 5px;margin-top:-1px}wm-modal-footer .wm-wrapper{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;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center}@media only screen and (max-width: 650px){wm-modal-footer .wm-wrapper.footer-text{-ms-flex-direction:column;flex-direction:column;-ms-flex-align:start;align-items:flex-start}}wm-modal-footer .wm-wrapper wm-button+wm-button{margin-left:1rem}wm-modal-footer .wm-wrapper .wm-info{font-size:0.875rem;font-style:italic}@media only screen and (max-width: 650px){wm-modal-footer .wm-wrapper .wm-info{padding-bottom:0.625rem}}wm-modal-footer .wm-wrapper .wm-info:focus{outline:none}";export{o as wm_modal_footer}
@@ -0,0 +1 @@
1
+ import{r as t,c as e,f as o,h as i,H as n,g as r}from"./p-b3c71506.js";import{g as s,d as a,i as l,p as d}from"./p-de3367ee.js";let m=class{constructor(i){t(this,i),this.wmUploaderFilesSelected=e(this,"wmUploaderFilesSelected",7),this.wmFilesSelected=e(this,"wmFilesSelected",7),this.wmUploaderDeleteFile=e(this,"wmUploaderDeleteFile",7),this.wmDeleteFile=e(this,"wmDeleteFile",7),this.wmUploaderDownloadFile=e(this,"wmUploaderDownloadFile",7),this.wmDownloadFile=e(this,"wmDownloadFile",7),this.wmUploaderPreviewFile=e(this,"wmUploaderPreviewFile",7),this.fileTypes="pdf txt log xml doc docx xls xlsx ppt pptx gif jpg jpeg png csv",this.defaultMaxSize=100,this.maxSize=this.defaultMaxSize,this.sortBy="date",this.showInfo="time",this.fileList=[],this.filesToUpload=[],this.isTabbing=!1,this.errorList=[],this.isCondensed=!1,this.inputId=s(),this.debouncedResize=a((()=>{this.isCondensed=this.el.clientWidth<500,o(this.el)}),50)}get tooltipEl(){return document.getElementById("wm-tooltip")}get uploadButtonEl(){return this.el.shadowRoot.querySelector(`#${this.inputId}`)}get tempUploaderType(){return this.type||this.uploaderType}get chMeasure(){return this.el.shadowRoot.querySelector(".ch-measure").clientWidth}get fileLimitReached(){return this.maxFiles&&this.fileList.length>=this.maxFiles}get fileUploadLimitMessage(){return l.formatMessage({id:"uploader.fileUploadLimit",defaultMessage:"Upload unsuccessful because file selection would exceed the maximum number of files",description:"Message displayed when trying to upload too many files"})}get fileCountMessage(){return l.formatMessage({id:"uploader.fileCount",defaultMessage:"{x} of {y} Files",description:"A count of the number of files currently uploaded"},{x:this.fileList.length,y:this.maxFiles})}get maxSizeMessage(){return l.formatMessage({id:"uploader.maxSize",defaultMessage:"Maximum file size {maxSize}MB",description:"An indicator of the maximum file size the uploader allows"},{maxSize:this.maxSize})}get acceptedFileTypesMessage(){const t="."+this.fileTypes.split(" ").join(", .");return l.formatMessage({id:"uploader.acceptedFileTypes",defaultMessage:"Accepted file {amount, plural, =1 {type} other {types}}: {fileTypes}"},{fileTypes:t,amount:this.fileTypes.split(" ").length})}get previewActionMessage(){return l.formatMessage({id:"uploader.previewAction",defaultMessage:"Preview File",description:"Label of a button that triggers a file to be previewed"})}get downloadActionMessage(){return l.formatMessage({id:"uploader.downloadAction",defaultMessage:"Download File",description:"Label of a button that triggers a file to be downloaded"})}get deleteActionMessage(){return l.formatMessage({id:"uploader.deleteAction",defaultMessage:"Delete File",description:"Label of a button that triggers a file to be delete"})}get clearButtonText(){return l.formatMessage({id:"uploader.clearErrorText",defaultMessage:"Clear",description:"Text for a button used to clear an error"})}get actionMenuLabel(){return l.formatMessage({id:"uploader.actionMenuLabel",defaultMessage:"Actions",description:"Label of a button that opens a menu of file actions"})}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}handleUploadProgress(t){if(this.fileList.map((e=>{e.id===t.detail.id&&(e.progress=t.detail.progress,o(this.el))})),100===t.detail.progress&&(this.numFilesInProgress-=1),!this.srProgress&&this.numFilesInProgress){const t=this.numFilesInProgress;this.srProgress=setInterval((()=>{const e=this.fileList.reduce(((t,e)=>e.progress?t+e.progress:t),0);this.liveRegion&&(this.liveRegion.innerHTML=l.formatMessage({id:"uploader.uploadProgress",defaultMessage:"Upload progress: {percentage}%"},{percentage:Math.floor(e/t)}))}),5e3)}}parseFiles(){if(this.files){if("string"!=typeof this.files)throw new Error("Attribute 'files' should be a string");{const t=JSON.parse(this.files);if("object"!=typeof t)throw new Error("could not parse string passed to files attribute");this.fileList=t}}}parseRejectedFiles(){if(this.rejectedFiles){if("string"!=typeof this.files)throw new Error("Attribute 'rejected-files' should be a string");{const t=JSON.parse(this.rejectedFiles);if("object"!=typeof t)throw new Error("could not parse string passed to errors attribute");this.errorList=t}}}setMaxSize(){this.maxSize=this.maxSize>this.defaultMaxSize?this.defaultMaxSize:this.maxSize}uploadNotifications(t,e){if(e>0&&0===t){setTimeout((()=>{this.notif=null}),2e4);const t=l.formatMessage({id:"uploader.finishedUploading",defaultMessage:"Finished uploading"});this.notif={id:5,message:t,isError:!1},this.liveRegion&&(this.liveRegion.innerHTML=t),this.numFilesInProgress=null,clearInterval(this.srProgress),o(this.el)}else if(t>0&&t!=e){const e=l.formatMessage({id:"uploader.filesUploading",defaultMessage:"{num, plural, one {1 file uploading} other {# files uploading}}"},{num:t});this.notif={id:6,message:e,isError:!1},this.liveRegion&&(this.liveRegion.innerHTML=e),o(this.el)}}isValidSize(t){return this.convertBytes(t,"MB").size<=this.maxSize}convertBytes(t,e){const o=["bytes","KB","MB","GB","TB"];let i=0,n="number"==typeof t?t:parseInt(t);if(e)for(;o.indexOf(e)>i;)n/=1024,i++;else for(;n>1e3;)n/=1024,i++;return{size:n,unit:o[i]}}isDuplicate(t){return this.fileList.find((e=>(e.type?e.name+"."+e.type:e.name)===t))}isEmpty(){return!this.fileList.length&&!this.errorList.length}get isDisabled(){if(this.notif)1===this.notif.id&&(this.fileLimitReached||(this.notif=null));else if(this.fileLimitReached){const t=this.fileUploadLimitMessage;this.notif={id:1,message:t,isError:!0},this.liveRegion&&(this.liveRegion.innerHTML=t)}else this.notif=null;return this.fileLimitReached||this.numFilesInProgress>0}isItemUploading(t){return t.hasOwnProperty("progress")&&t.progress<100}clearError(t){this.errorList=this.errorList.filter((e=>e.name!=t)),this.notif=null}clearErrors(){this.errorList=[],this.notif=null}handleFiles(t){this.filesToUpload=[];const e=this.fileTypes.split(" ").join(", "),o=Array.from(t.target.files);if(this.maxFiles&&this.fileList.length+o.length>this.maxFiles){const t=l.formatMessage({id:"uploader.fileUploadExceeded",defaultMessage:"The number of selected files exceeds the limit."});this.notif={id:2,message:t,isError:!0},this.liveRegion&&(this.liveRegion.innerHTML=t)}else o&&o.map((t=>{if(d(t,this.fileTypes))if(0===t.size){const e={name:t.name,message:l.formatMessage({id:"uploader.zeroFileSize",defaultMessage:"The file must be more than 0 bytes",description:"Error message when user attempts to upload a file of no size"})};this.errorList.push(e)}else if(this.isValidSize(t.size))if(this.isDuplicate(t.name)){const e={name:t.name,message:l.formatMessage({id:"uploader.duplicateName",defaultMessage:"A file with this name already exists."})};this.errorList.push(e)}else this.filesToUpload.push(t);else{const e={name:t.name,message:l.formatMessage({id:"uploader.fileTooLarge",defaultMessage:"The selected file is too large. Maximum file size is {size}Mb"},{size:this.maxSize})};this.errorList.push(e)}else{const o={name:t.name,message:l.formatMessage({id:"uploader.invalidFileType",defaultMessage:"The file type is invalid. Accepted types: {validTypes}"},{validTypes:e})};this.errorList.push(o)}})),this.filesToUpload.length>0&&(this.numFilesInProgress=this.filesToUpload.length,this.wmUploaderFilesSelected.emit(this.filesToUpload),this.wmFilesSelected.emit(this.filesToUpload));t.target.value=""}previewFile(t){this.clearErrors(),this.wmUploaderPreviewFile.emit(t.id)}downloadFile(t){this.clearErrors(),this.wmUploaderDownloadFile.emit(t.id),this.wmDownloadFile.emit(t.id)}deleteFile(t){this.clearErrors(),o(this.el),this.wmUploaderDeleteFile.emit(t.id),this.wmDeleteFile.emit(t.id)}componentWillLoad(){if(!this.buttonText)throw new Error("wm-uploader: button-text is a required prop");if(this.type&&console.warn("wm-uploader: type has been deprecated as of v3.1.0. Please use uploader-type instead."),"1"===this.tempUploaderType&&!this.emptyStateText)throw new Error("wm-uploader: empty-state-text is a required prop");new ResizeObserver((()=>this.debouncedResize())).observe(this.el),this.setMaxSize(),this.parseFiles(),this.clearErrors(),this.parseRejectedFiles()}componentDidLoad(){document.body.classList.contains("wmcl-user-is-tabbing")&&this.toggleTabbingOn()}showTooltip(t,e){this.tooltipEl.textContent=e,this.positionTooltip("bottom",t,this.tooltipEl),this.tooltipEl.style.transitionDelay="500ms",this.tooltipEl.style.opacity="1"}hideTooltip(){this.tooltipEl.style.transitionDelay="0s",this.tooltipEl.style.opacity="0"}positionTooltip(t,e,o){const i=o.getBoundingClientRect().height,n=o.getBoundingClientRect().width,r=(e.getBoundingClientRect().height-i)/2,s=(e.getBoundingClientRect().width-n)/2;let a=e.getBoundingClientRect().top+r,l=e.getBoundingClientRect().left+s;t.includes("top")&&(a=e.getBoundingClientRect().top-i-8),t.includes("bottom")&&(a=e.getBoundingClientRect().bottom+8),t.includes("left")&&(l=e.getBoundingClientRect().left-n-8),t.includes("right")&&(l=e.getBoundingClientRect().right+8),l=Math.max(l,24),o.style.top=(a/16).toString()+"rem",o.style.left=(l/16).toString()+"rem"}uploadButtonOnClick(t){if(this.isDisabled){if(t.preventDefault(),this.liveRegion){let t="";this.numFilesInProgress>0?t=l.formatMessage({id:"uploader.waitToUpload",defaultMessage:"Please wait for current upload to complete before uploading new files.",description:"Message for screen reader users"}):this.fileLimitReached&&(t=this.fileUploadLimitMessage),t&&(this.liveRegion.innerHTML="",new Promise((t=>{setTimeout((()=>{t("")}),500)})).then((()=>this.liveRegion.innerHTML=t)))}}else this.clearErrors()}renderUploadSvg(){return i("svg",{class:"upload-file",width:"91",height:"84",viewBox:"0 0 91 84"},i("path",{transform:"rotate(-180.000000) translate(-452, -255.5)",fill:"#eae8ec",d:"M361,249.681818 L361,197.318182 C361,194.118182 365.555061,191.5 371.122358,191.5 L391.316463,191.5 L391.286495,200.562515 L369.871211,200.600292 L369.885404,200.622146 L369.886423,246.655947 L443.657038,246.840767 L443.657038,200.622146 L421.683537,200.622146 L421.683537,191.5 L441.978865,191.5 C447.546162,191.5 452,194.118182 452,197.318182 L452,249.681818 C452,252.881818 447.546162,255.5 441.978865,255.5 L371.122358,255.5 C365.504449,255.5 361,252.881818 361,249.681818 Z M391.5,207 L406,221 L420.5,207 L409.625,207 L409.625,172 L402.375,172 L402.375,207 L391.5,207 Z"}))}renderIcon(){return this.icon&&i("span",{class:"mdi "+(this.icon&&"f066"===this.icon?"rotate":"")},String.fromCodePoint(parseInt(`0x${this.icon}`)))}renderInfo(){return this.info&&"2"===this.tempUploaderType?i("span",{class:"info"},this.info):""}renderNotif(){return this.notif?i("div",{class:"notif "+(this.notif.isError?"error":"")},this.notif.message):""}renderUploadButton(t){return i("div",{class:"info-wrapper"},i("input",{name:this.inputId,id:this.inputId,class:"sr-only","aria-describedby":"file-count max-size accepted-types",type:"file",multiple:!0,onClick:t=>this.uploadButtonOnClick(t),onChange:t=>this.handleFiles(t)}),i("label",{htmlFor:this.inputId,class:`wm-button ${t}${this.isTabbing?" user-is-tabbing":""}`},this.renderIcon(),this.buttonText),this.renderInfo())}renderEmptyState(){return i("div",{class:"empty-block"},this.renderUploadSvg(),i("div",{class:"empty-message"},this.emptyStateText),this.renderUploadButton("-primary empty-button"),this.renderNotif())}renderFileName(t,e){return i("div",{class:"left-group"},i("div",{class:"name-wrapper"},i("span",{class:"filename","data-filename":t,onMouseEnter:e=>this.handleFilenameMouseEnter(e,t),onMouseLeave:()=>this.hideTooltip()}),e&&i("span",{class:"sr-only"},"uploading"),i("div",{class:"sr-only ch-measure"})))}renderErrorList(){if(this.errorList.length){if(this.liveRegion){let t=this.errorList.reduce((function(t,e){return t+`${e.name}: ${e.message} `}),"");this.liveRegion.innerHTML=t}return i("ul",{class:"error-list"},this.errorList.map((t=>{const e=l.formatMessage({id:"uploader.clearErrorLabel",defaultMessage:"Clear {fileName} error",description:"Label for a button used to clear an error, including filename"},{fileName:t.name});return i("li",null,i("div",{class:"file --error"},this.renderFileName(t.name,!1),i("wm-button",{"permanently-delete":!0,"button-type":"textonly","label-for-identical-buttons":e,onClick:()=>{this.clearError(t.name),this.uploadButtonEl.focus()}},this.clearButtonText)),i("div",{class:"error-message"},t.message))})))}}renderFileInProgress(t){const e=t.type?`${t.name}.${t.type}`:t.name;return i("li",null,i("div",{class:"file --progress"},i("div",{class:"progress",style:{background:`linear-gradient(to right, rgba(67, 126, 142, 1) ${t.progress}%, transparent ${t.progress}%)`}}),this.renderFileName(e,this.isItemUploading(t))))}renderFile(t){const e=t.type?`${t.name}.${t.type}`:t.name,o=t.fileActions&&1===t.fileActions.split(" ").length,n=!this.tempUploaderType&&this.isCondensed&&!o,r=!this.tempUploaderType&&!this.isCondensed;return i("li",{class:`${this.isCondensed?"condensed":""} ${this.tempUploaderType||100!==t.progress&&"100"!==t.progress?"":"checked"}`},i("div",{class:"file --saved"},this.renderFileName(e,this.isItemUploading(t)),i("div",{class:"right-group"},r&&this.renderFileInfo(t),n?this.renderActionMenu(t):this.renderFileActions(t))))}handleFilenameMouseEnter(t,e){t.target.textContent.includes("...")&&this.showTooltip(t.target,e)}componentDidRender(){this.el.shadowRoot.querySelectorAll(".file").forEach((t=>this.truncateFileName(t)))}truncateFileName(t){const e=t.querySelector(".left-group").getBoundingClientRect().left,o=t.querySelector(".right-group"),i=o?o.getBoundingClientRect().left:t.getBoundingClientRect().right-20,n=t.querySelector(".filename"),r=i-e;let s=n.dataset.filename;if(!(r>s.length*this.chMeasure)){const t=s.slice(s.lastIndexOf(".")),e=Math.floor(r/this.chMeasure);let o=Math.max(2,e-(6+t.length));const i=s.slice(0,o),n=s.slice(s.indexOf(t)-3,s.length);s=`${i.trim()}...${n.trim()}`}n.textContent=s}renderFileActions(t){const e=t.fileActions||"download delete",o=i("wm-button",{class:"preview-button","button-type":"icononly",tooltip:"Preview","tooltip-position":"bottom","label-for-identical-buttons":`preview ${t.name}`,icon:"f208",onClick:()=>this.previewFile(t)}),n=i("wm-button",{class:"download-button","button-type":"icononly",tooltip:"Download","tooltip-position":"bottom","label-for-identical-buttons":`download ${t.name}`,icon:"f1da",onClick:()=>this.downloadFile(t)}),r=i("wm-button",{class:"delete-button","button-type":"icononly",tooltip:"Delete","tooltip-position":"bottom","label-for-identical-buttons":`delete ${t.name}`,icon:"f1c0",onClick:()=>this.deleteFile(t)});return i("div",{class:"file-controls"},e.includes("preview")&&o,e.includes("download")&&n,e.includes("delete")&&r)}renderActionMenu(t){const e=t.fileActions||"download delete",o=i("wm-menuitem",{icon:"f208",onClick:()=>this.previewFile(t)},this.previewActionMessage),n=i("wm-menuitem",{icon:"f1da",onClick:()=>this.downloadFile(t)},this.downloadActionMessage),r=i("wm-menuitem",{icon:"f1c0",onClick:()=>this.deleteFile(t)},this.deleteActionMessage);return i("wm-action-menu",{"action-menu-type":"icon",tooltip:this.actionMenuLabel,"tooltip-position":"bottom","label-for-identical-buttons":`${t.name} ${this.actionMenuLabel}`},e.includes("preview")&&o,e.includes("download")&&n,e.includes("delete")&&r)}renderFileInfo(t){let e;if("time"===this.showInfo){const o=new Date(Date.parse(t.lastUpdated)),n=o.getDate(),r=o.getMonth()+1,s=o.getFullYear(),a=o.toLocaleTimeString("en-us",{hour:"numeric",minute:"2-digit"});e=i("div",{class:"file-info"},`${r}/${n}/${s} ${a}`)}else if("size"===this.showInfo&&t.size){const o=this.convertBytes(t.size);e=i("div",{class:"file-info"},`${o.size.toFixed(0)} ${o.unit}`)}return e}renderFileList(){if(this.fileList)return this.fileList.sort("name"===this.sortBy?(t,e)=>t.name.localeCompare(e.name):(t,e)=>Date.parse(t.lastUpdated)-Date.parse(e.lastUpdated)),i("div",null,i("ul",{class:"inprogress-list"},this.fileList.filter((t=>this.isItemUploading(t))).map((t=>this.renderFileInProgress(t)))),i("ul",{class:"file-list"},this.fileList.filter((t=>!this.isItemUploading(t))).map((t=>this.renderFile(t)))))}legacyRenderHeader(){return i("div",{class:"header "+(this.tempUploaderType?`type${this.tempUploaderType}`:"")},i("div",{class:"slot-wrapper"},i("slot",null),i("div",{class:"notif-wrapper "+(this.tempUploaderType?`type${this.tempUploaderType}`:"")},this.renderUploadButton("-secondary "+(this.isDisabled?"disabled":"")),this.renderNotif())))}renderHeader(){return i("div",{class:"header "+(this.tempUploaderType?`type${this.tempUploaderType}`:"")},i("div",{class:"notif-wrapper "+(this.tempUploaderType?`type${this.tempUploaderType}`:"")},this.renderUploadButton("-secondary "+(this.isDisabled?"disabled":"")),this.renderRequirements()),i("div",{id:"accepted-types",class:"accepted-types"},this.acceptedFileTypesMessage),this.renderNotif())}renderRequirements(){return i("div",{class:"requirements"},this.maxFiles&&i("span",{id:"file-count"},this.fileCountMessage),this.maxSize!==this.defaultMaxSize&&i("span",{id:"max-size"},this.maxSizeMessage))}renderFooter(){return i("div",{class:"footer"},i("div",{class:"notif-wrapper "+(this.tempUploaderType?`type${this.tempUploaderType}`:"")},i("div",{class:"filecount-wrapper"},i("div",{class:"filecount"},l.formatMessage({id:"uploader.filesAdded",defaultMessage:"{numFiles, plural, one {1 file added} other {# files added}}"},{numFiles:this.fileList.length})),this.renderUploadButton("-primary "+(this.isDisabled?"disabled":""))),this.renderNotif()))}renderWithItems(){const t=this.fileList.filter((t=>t.progress===("number"==typeof t.progress?100:"100"))).length>0;return i("div",null,!this.tempUploaderType&&this.renderHeader(),"2"===this.tempUploaderType&&this.legacyRenderHeader(),i("div",{class:`list-container type${this.tempUploaderType} ${!this.tempUploaderType&&t?"checkmark-spacer":""}`},this.renderErrorList(),this.renderFileList()),"1"===this.tempUploaderType&&this.renderFooter())}render(){return i(n,null,this.isEmpty()&&"1"===this.tempUploaderType?this.renderEmptyState():this.renderWithItems(),i("div",{ref:t=>this.liveRegion=t,class:"live-region sr-only","aria-live":"assertive","aria-atomic":"true"}))}get el(){return r(this)}static get watchers(){return{files:["parseFiles"],rejectedFiles:["parseRejectedFiles"],maxSize:["setMaxSize"],numFilesInProgress:["uploadNotifications"]}}};m.style=':host .wm-button,wm-uploader .wm-button{-ms-transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1), border 500ms cubic-bezier(0.4, 0, 0.2, 1);-webkit-transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1), border 500ms cubic-bezier(0.4, 0, 0.2, 1);-moz-transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1), border 500ms cubic-bezier(0.4, 0, 0.2, 1);transition:background-color 500ms cubic-bezier(0.4, 0, 0.2, 1), color 500ms cubic-bezier(0.4, 0, 0.2, 1), border 500ms cubic-bezier(0.4, 0, 0.2, 1);-webkit-border-radius:5px;-moz-border-radius:5px;-ms-border-radius:5px;border-radius:5px;width:inherit;border:2px solid #575195;color:#575195;font-family:inherit;font-size:0.75rem;font-weight:700;height:2.75rem;padding:0 1.3333333333em;cursor:pointer;position:relative;background:#fff;display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center;-ms-flex-align:center;align-items:center;text-decoration:none;text-transform:uppercase;letter-spacing:0.01875rem;overflow-wrap:break-word;word-wrap:break-word;word-break:break-word;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}@media screen and (min-width: 48rem){:host .wm-button,wm-uploader .wm-button{height:3.3333333333em}}:host .wm-button.nowrap,wm-uploader .wm-button.nowrap{display:inline-block;width:100%;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}:host .wm-button:focus,wm-uploader .wm-button:focus{outline:none;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}:host .wm-button::-moz-focus-inner,wm-uploader .wm-button::-moz-focus-inner{border:0;outline:none}:host .wm-button.user-is-tabbing:focus:not(:disabled):not(.disabled) :host .wm-button.-textonly .button-text,wm-uploader .wm-button.user-is-tabbing:focus:not(:disabled):not(.disabled) :host .wm-button.-textonly .button-text,:host .wm-button.user-is-tabbing:focus:not(:disabled):not(.disabled) wm-uploader .wm-button.-textonly .button-text,wm-uploader .wm-button.user-is-tabbing:focus:not(:disabled):not(.disabled) wm-uploader .wm-button.-textonly .button-text{background:-webkit-gradient(linear, left top, right top, color-stop(66%, #3862e9), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #3862e9 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1em;border-radius:0;line-height:normal}:host .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled),wm-uploader .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled){-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}:host .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark),wm-uploader .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark){-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}:host .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark)::-moz-focus-inner,wm-uploader .wm-button.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled):not(.dark)::-moz-focus-inner{border:0}:host .wm-button.dark:not(.-textonly):not(:disabled):not(.disabled),wm-uploader .wm-button.dark:not(.-textonly):not(:disabled):not(.disabled){background:transparent;border:2px solid #fff;color:#fff}:host .wm-button.dark:not(.-textonly):not(:disabled):not(.disabled):hover,wm-uploader .wm-button.dark:not(.-textonly):not(:disabled):not(.disabled):hover{color:#575195;background:#e6e6e6;border:2px solid #e6e6e6}:host .wm-button.dark.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled).dark,wm-uploader .wm-button.dark.user-is-tabbing:focus:not(.-textonly):not(:disabled):not(.disabled).dark{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #c6b4e3;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #c6b4e3;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #c6b4e3;outline:none}:host .wm-button:active:not(:disabled):not(.disabled):not(.-textonly):not(.-actionbutton):not(.displayedoption),wm-uploader .wm-button:active:not(:disabled):not(.disabled):not(.-textonly):not(.-actionbutton):not(.displayedoption){-ms-transform:scale(0.9, 0.9);-webkit-transform:scale(0.9, 0.9);-moz-transform:scale(0.9, 0.9);transform:scale(0.9, 0.9)}:host .wm-button .mdi,wm-uploader .wm-button .mdi{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}:host .wm-button:not(.-icononly):not(.-navigational) .mdi,wm-uploader .wm-button:not(.-icononly):not(.-navigational) .mdi{margin-right:0.3125rem}:host .wm-button[dir=RTL] :not(.-icononly) .mdi,wm-uploader .wm-button[dir=RTL] :not(.-icononly) .mdi{margin-left:0.3125rem;margin-right:0}:host .wm-button.-primary:not(.-textonly),wm-uploader .wm-button.-primary:not(.-textonly){background:#575195;color:#fff}:host .wm-button.-primary:not(.-textonly):not(:focus),wm-uploader .wm-button.-primary:not(.-textonly):not(:focus){-webkit-box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);-moz-box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2)}:host .wm-button.-primary:not(.-textonly):hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-primary:not(.-textonly):hover:not(:disabled):not(.disabled){background:#464177}:host .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled),wm-uploader .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled){color:#575195;background:#fff;border:2px solid #fff}:host .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled):hover,wm-uploader .wm-button.-primary:not(.-textonly).dark:not(:disabled):not(.disabled):hover{color:#575195;background:#e6e6e6;border:2px solid #e6e6e6}:host .wm-button.-secondary:hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-secondary:hover:not(:disabled):not(.disabled),:host .wm-button.-icononly:hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-icononly:hover:not(:disabled):not(.disabled){background:#464177;color:#fff}:host .wm-button.-textonly,wm-uploader .wm-button.-textonly{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;display:inline-block;letter-spacing:0;text-transform:none;text-align:initial;font-size:0.875rem;border:none;background:transparent;padding-left:0;padding-right:0;height:auto;border-radius:0;line-height:1}:host .wm-button.-textonly+.-textonly,wm-uploader .wm-button.-textonly+.-textonly{margin-left:0.3125rem}:host .wm-button.-textonly:focus,wm-uploader .wm-button.-textonly:focus{outline:none}:host .wm-button.-textonly::-moz-focus-inner,wm-uploader .wm-button.-textonly::-moz-focus-inner{border:0;outline:none}:host .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled) .button-text,wm-uploader .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled) .button-text{background:-webkit-gradient(linear, left top, right top, color-stop(66%, #3862e9), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #3862e9 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1em;border-radius:0;line-height:normal}:host .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled).dark .button-text,wm-uploader .wm-button.-textonly.user-is-tabbing:focus:not(:disabled):not(.disabled).dark .button-text{background:-webkit-gradient(linear, left top, right top, color-stop(66%, #fff), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #fff 66%, transparent 0) repeat-x;background-size:6px 3px;background-position:0 1em;border-radius:0;line-height:normal}:host .wm-button.-textonly.small,wm-uploader .wm-button.-textonly.small{font-size:0.625rem}:host .wm-button.-textonly:hover:not(:disabled):not(.disabled):not(.-permanentlydelete),wm-uploader .wm-button.-textonly:hover:not(:disabled):not(.disabled):not(.-permanentlydelete){text-decoration:underline}:host .wm-button.-textonly.-permanentlydelete,wm-uploader .wm-button.-textonly.-permanentlydelete{color:#c0392b}:host .wm-button.-textonly.-permanentlydelete:hover:not(:disabled):not(.disabled):not(.dark),wm-uploader .wm-button.-textonly.-permanentlydelete:hover:not(:disabled):not(.disabled):not(.dark){text-decoration:underline;color:#c0392b !important}:host .wm-button.-textonly.dark,wm-uploader .wm-button.-textonly.dark{color:#fff}:host .wm-button.-textonly.dark:hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-textonly.dark:hover:not(:disabled):not(.disabled){text-decoration:underline;color:#fff !important}:host .wm-button.-icononly,wm-uploader .wm-button.-icononly,:host .wm-button.-navigational,wm-uploader .wm-button.-navigational{-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;border-radius:50%;font-size:1rem;padding:0;height:auto;line-height:1;min-width:2.75rem;min-height:2.75rem;text-align:center;letter-spacing:normal}:host .wm-button.-icononly:not(:focus),wm-uploader .wm-button.-icononly:not(:focus),:host .wm-button.-navigational:not(:focus),wm-uploader .wm-button.-navigational:not(:focus){-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}@media screen and (min-width: 48rem){:host .wm-button.-icononly,wm-uploader .wm-button.-icononly,:host .wm-button.-navigational,wm-uploader .wm-button.-navigational{min-width:2.5rem;min-height:2.5rem}}:host .wm-button.-icononly,wm-uploader .wm-button.-icononly{border-width:1px !important}:host .wm-button.-icononly:before,wm-uploader .wm-button.-icononly:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}:host .wm-button.-navigational,wm-uploader .wm-button.-navigational{border:none !important;background-color:transparent}:host .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled),wm-uploader .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled){color:#575195}:host .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled):hover,wm-uploader .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled):hover,:host .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled).selected,wm-uploader .wm-button.-navigational:not(.dark):not(:disabled):not(.disabled).selected{background-color:#d7d6d9}:host .wm-button.-navigational:before,wm-uploader .wm-button.-navigational:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}:host .wm-button.-permanentlydelete:not(.-textonly),wm-uploader .wm-button.-permanentlydelete:not(.-textonly){background:#c0392b;border-color:#c0392b;color:#fff}:host .wm-button.-permanentlydelete:not(.-textonly):hover:not(:disabled):not(.disabled):not(.dark),wm-uploader .wm-button.-permanentlydelete:not(.-textonly):hover:not(:disabled):not(.disabled):not(.dark){background:#9a2e22;border-color:#9a2e22}:host .wm-button.-pairnegative,wm-uploader .wm-button.-pairnegative{background:#cc4c3e;border-color:#cc4c3e;color:#fff}:host .wm-button.-pairnegative:hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-pairnegative:hover:not(:disabled):not(.disabled){background:#a33d32;border-color:#a33d32}:host .wm-button.-pairpositive,wm-uploader .wm-button.-pairpositive{background:#15868d;border-color:#15868d;color:#fff}:host .wm-button.-pairpositive:hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-pairpositive:hover:not(:disabled):not(.disabled){background:#116b71;border-color:#116b71}:host .wm-button.-selectoronly,wm-uploader .wm-button.-selectoronly{-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;display:block;background:transparent;border:1px solid #575195;border-radius:3px 3px 3px 3px;height:2.75rem;min-width:11.4375rem;padding:0 1.875rem 0 0.9375rem;line-height:normal;font-family:inherit;color:#575195;font-weight:500;font-size:0.875rem;text-transform:none;letter-spacing:0.01875rem;text-align:left}@media screen and (min-width: 48rem){:host .wm-button.-selectoronly,wm-uploader .wm-button.-selectoronly{height:2.5rem}}:host .wm-button.-selectoronly:before,wm-uploader .wm-button.-selectoronly:before{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f140";position:absolute;right:0.5625rem;top:50%;-webkit-transform:translateY(-50%);transform:translateY(-50%);pointer-events:none}:host .wm-button.-selectoronly:hover:not(:disabled):not(.disabled),wm-uploader .wm-button.-selectoronly:hover:not(:disabled):not(.disabled){background:transparent;text-decoration:none}:host .wm-button.-selectoronly:active,wm-uploader .wm-button.-selectoronly:active{-ms-transform:scale(1, 1) !important;-webkit-transform:scale(1, 1) !important;transform:scale(1, 1) !important}:host .wm-button.-selectoronly::-moz-focus-inner,wm-uploader .wm-button.-selectoronly::-moz-focus-inner{border:0}:host .wm-button.-selectoronly .overflowcontrol,wm-uploader .wm-button.-selectoronly .overflowcontrol{display:block;white-space:nowrap;text-overflow:ellipsis;overflow:visible}:host .wm-button:disabled,wm-uploader .wm-button:disabled,:host .wm-button.disabled,wm-uploader .wm-button.disabled{background:inherit;border-color:#737373;color:#737373;cursor:default;pointer-events:none}:host .wm-button:disabled.-primary,wm-uploader .wm-button:disabled.-primary,:host .wm-button:disabled.-permanentlydelete,wm-uploader .wm-button:disabled.-permanentlydelete,:host .wm-button:disabled.-pairnegative,wm-uploader .wm-button:disabled.-pairnegative,:host .wm-button:disabled.-pairpositive,wm-uploader .wm-button:disabled.-pairpositive,:host .wm-button.disabled.-primary,wm-uploader .wm-button.disabled.-primary,:host .wm-button.disabled.-permanentlydelete,wm-uploader .wm-button.disabled.-permanentlydelete,:host .wm-button.disabled.-pairnegative,wm-uploader .wm-button.disabled.-pairnegative,:host .wm-button.disabled.-pairpositive,wm-uploader .wm-button.disabled.-pairpositive{background:#737373;color:#fff;border-color:#737373}:host .wm-button:disabled.-secondary,wm-uploader .wm-button:disabled.-secondary,:host .wm-button.disabled.-secondary,wm-uploader .wm-button.disabled.-secondary{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}:host .wm-button:disabled.-selectoronly,wm-uploader .wm-button:disabled.-selectoronly,:host .wm-button.disabled.-selectoronly,wm-uploader .wm-button.disabled.-selectoronly{color:#737373}:host .wm-button:disabled.-textonly,wm-uploader .wm-button:disabled.-textonly,:host .wm-button.disabled.-textonly,wm-uploader .wm-button.disabled.-textonly{color:#6b6b6b;background:transparent}:host .wm-button:disabled.dark.-secondary:not(.-permanentlydelete),wm-uploader .wm-button:disabled.dark.-secondary:not(.-permanentlydelete),:host .wm-button:disabled.dark.-textonly,wm-uploader .wm-button:disabled.dark.-textonly,:host .wm-button:disabled.dark.-navigational,wm-uploader .wm-button:disabled.dark.-navigational,:host .wm-button:disabled.dark.-icononly,wm-uploader .wm-button:disabled.dark.-icononly,:host .wm-button.disabled.dark.-secondary:not(.-permanentlydelete),wm-uploader .wm-button.disabled.dark.-secondary:not(.-permanentlydelete),:host .wm-button.disabled.dark.-textonly,wm-uploader .wm-button.disabled.dark.-textonly,:host .wm-button.disabled.dark.-navigational,wm-uploader .wm-button.disabled.dark.-navigational,:host .wm-button.disabled.dark.-icononly,wm-uploader .wm-button.disabled.dark.-icononly{color:#b5b5b5;border-color:#b5b5b5}:host .wm-button:disabled.dark.-primary,wm-uploader .wm-button:disabled.dark.-primary,:host .wm-button:disabled.dark.-permanentlydelete:not(.-textonly),wm-uploader .wm-button:disabled.dark.-permanentlydelete:not(.-textonly),:host .wm-button.disabled.dark.-primary,wm-uploader .wm-button.disabled.dark.-primary,:host .wm-button.disabled.dark.-permanentlydelete:not(.-textonly),wm-uploader .wm-button.disabled.dark.-permanentlydelete:not(.-textonly){background:#a6a6a6;border-color:#a6a6a6;color:#353b48}:host a.wm-button,wm-uploader a.wm-button,:host label.wm-button,wm-uploader label.wm-button{height:auto;padding-top:0.75rem;padding-bottom:0.75rem}:host,wm-uploader{width:100%;height:100%;display:block;position:relative;max-width:1140px}:host[dir=RTL] .mdi,wm-uploader[dir=RTL] .mdi{margin-left:0.3125rem;margin-right:0}:host input:focus+.wm-button.user-is-tabbing,wm-uploader input:focus+.wm-button.user-is-tabbing{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e !important;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e !important;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e !important}:host *,wm-uploader *{-webkit-box-sizing:border-box;box-sizing:border-box}.wm-button.disabled{pointer-events:initial !important}.sr-only{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}.header{margin-bottom:2.5rem}.header.type1,.header.type2{margin-bottom:1rem}.header .slot-wrapper{display:-ms-flexbox;display:flex;-ms-flex-pack:start;justify-content:flex-start;-ms-flex-align:start;align-items:flex-start}.header .info-wrapper{-ms-flex-align:center;align-items:center}.header .info-wrapper .info{font-size:0.875rem;margin-left:1rem}.header .accepted-types{font-size:0.875rem}.header .requirements{font-size:0.875rem;margin-left:1rem}.footer{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-align:end;align-items:flex-end;padding:0.9375rem 1.875rem}.footer .notif-wrapper{-ms-flex-align:end;align-items:flex-end}.footer .filecount-wrapper{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}.footer .filecount-wrapper .filecount{font-size:0.875rem;margin-right:1rem}.notif-wrapper{position:relative;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;margin-bottom:0.75rem}.notif-wrapper.type1,.notif-wrapper.type2{-ms-flex-direction:column;flex-direction:column;margin-bottom:1rem}.notif-wrapper .requirements{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}.notif{padding-top:0.25rem;font-size:0.875rem;font-style:italic}.notif.error{color:#c0392b}.info-wrapper{position:relative;display:-ms-flexbox;display:flex}.name-wrapper{overflow:hidden}.name-wrapper+.file-controls{-ms-flex:none;flex:none;margin-left:1rem}.empty-block{margin:5rem auto;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-align:center;align-items:center}.empty-block .upload-file{margin-bottom:1.875rem}.empty-block .empty-message{font-size:0.875rem;margin-bottom:0.4375rem}.empty-block .empty-message.large{font-size:1.5rem}.empty-block .info-wrapper{-ms-flex-pack:center;justify-content:center;width:100%}.empty-block .info-wrapper .wm-button{width:auto}.list-container{overflow-y:unset}.list-container.checkmark-spacer{margin-right:2.75rem}.list-container.type1,.list-container.type2{overflow-y:auto}.list-container.type1 ul,.list-container.type2 ul{margin:revert}.list-container.type1 .file-list li,.list-container.type1 .inprogress-list li,.list-container.type2 .file-list li,.list-container.type2 .inprogress-list li{margin-bottom:1.625rem}.list-container.type1 .error-list li,.list-container.type2 .error-list li{margin-bottom:1.25rem}.list-container.type1{padding:0 1.875rem;height:16.25rem}ul{list-style:none;padding:0;width:100%;margin:0}ul li{position:relative;font-size:0.875rem;margin-bottom:0.5rem}ul li .file{min-width:300px;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;position:relative;height:3.5rem;padding:0.5rem 1.25rem;background:#f4f4f4;border:1px solid #6b6b6b;display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-align:center;align-items:center}ul li .file+.file{margin-top:1.25rem}ul li .file .filename{white-space:nowrap}ul li .file .left-group{overflow:hidden}ul li .file .right-group{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;padding-left:5rem}ul li .file .right-group .file-controls{display:-ms-flexbox;display:flex}ul li .file .right-group .file-info{white-space:nowrap;margin-right:1rem}ul li .file wm-button+wm-button{margin-left:1rem}ul li.condensed .right-group{padding-left:2.5rem}ul li.checked .file: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:"\\f133";position:absolute;right:-44px;color:#088000;font-size:28px;line-height:1}ul .progress{position:absolute;left:0;top:0;right:0;height:8px}ul.file-list li,ul.inprogress-list li{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}ul.file-list li .file,ul.inprogress-list li .file{-ms-flex:1;flex:1}ul.error-list li{margin-bottom:0.5rem}ul.error-list li .file{border:1px solid #c0392b;background-color:#f5ebea;height:3.75rem}ul.error-list li .error-message{color:#c0392b;padding-top:0.25rem;font-style:italic}.ch-measure{width:1ch !important}';export{m as wm_uploader}
@@ -1 +1 @@
1
- import{r as t,c as e,h as a,g as n}from"./p-b3c71506.js";import{d as i}from"./p-15b1c11b.js";let s=class{constructor(a){t(this,a),this.wmPaginationPageClicked=e(this,"wmPaginationPageClicked",7),this.pageClicked=e(this,"pageClicked",7),this.focusCurrentPage=e(this,"focusCurrentPage",7),this.currentPage=1,this.totalItems=void 0,this.itemsPerPage=void 0,this.value=1,this.isLargeViewport=window.innerWidth>600,this.isTabbing=!1,this.srAnnouncement="",this.totalPages=0,this.debouncedResize=i((()=>{this.isLargeViewport=window.innerWidth>600}),250),this.getMiddlePageNums=()=>{let t;return t=this.currentPage<4?[2,3,4]:this.currentPage>this.totalPages-3?[this.totalPages-3,this.totalPages-2,this.totalPages-1]:[this.currentPage-1,this.currentPage,this.currentPage+1],t}}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}maintainFocusOnNumberChange(t){window.requestAnimationFrame((()=>{switch(t){case"previous":1===this.currentPage&&this.el.shadowRoot.querySelector("button#wm-1").focus();break;case"next":this.currentPage===this.totalPages&&this.el.shadowRoot.querySelector(`button#wm-${this.totalPages}`).focus();break;case"prev-arrow":1===this.currentPage&&this.el.shadowRoot.querySelector("#next-arw").focus();break;case"next-arrow":this.currentPage===this.totalPages&&this.el.shadowRoot.querySelector("#previous-arw").focus();break;case"page":this.el.shadowRoot.querySelector(`button#wm-${this.currentPage}`).focus();default:return}}))}handleResize(){this.debouncedResize()}calculateTotalPages(){this.totalPages=Math.ceil(this.totalItems/this.itemsPerPage)}componentWillLoad(){if(!this.totalItems||!this.itemsPerPage||!this.currentPage)throw new Error("Please check the required attributes");this.calculateTotalPages(),document.body.classList.contains("wmcl-user-is-tabbing")&&this.toggleTabbingOn()}updatePageDisplayed(t){this.value=t,this.wmPaginationPageClicked.emit(),this.pageClicked.emit(),this.srAnnouncement=`Current page, ${this.currentPage}. ${this.getCurrentPagesInView()}`}displayShortPagination(){let t=[];for(let e=1;e<=this.totalPages;e++)t.push(this.displayPageNumber(e));return t}displayLongPagination(){return[this.displayPageNumber(1),this.currentPage>3&&this.displayEllipsis(),...this.getMiddlePageNums().map((t=>this.displayPageNumber(t))),this.currentPage+2<this.totalPages&&this.displayEllipsis(),this.displayPageNumber(this.totalPages)]}displayPageNumber(t){return a("button",{id:`wm-${t}`,class:"paginationbtn",onClick:()=>{this.currentPage=t,this.updatePageDisplayed(t),this.maintainFocusOnNumberChange("page")},value:t,"aria-label":this.currentPage!==t?`Go to page ${t}`:"","aria-current":this.currentPage===t?"page":void 0},t)}displayEllipsis(){return a("span",{class:"ellipsis"},"...")}getCurrentPagesInView(){let t=this.itemsPerPage*this.currentPage;const e=t-this.itemsPerPage+1;return t>this.totalItems&&(t=this.totalItems),"Viewing "+(e===t?`${e}`:`${e}–${t} of ${this.totalItems}`)}renderLarge(){return a("div",{class:"largescreen"},a("div",{class:"pageview"},this.getCurrentPagesInView()),a("div",{class:"pagebtncontainer "+(this.isTabbing?"user-is-tabbing":"")},a("button",{id:"previous",class:"paginationbtn previousbtn",onClick:()=>{this.currentPage=this.currentPage-1,this.updatePageDisplayed(this.currentPage),this.maintainFocusOnNumberChange("previous")},disabled:1===this.currentPage,"aria-label":"Go to previous page","aria-controls":"status"},"Previous"),this.totalPages<6?this.displayShortPagination():this.displayLongPagination(),a("button",{id:"next",class:"paginationbtn nextbtn",onClick:()=>{this.currentPage=this.currentPage+1,this.updatePageDisplayed(this.currentPage),this.maintainFocusOnNumberChange("next")},disabled:this.currentPage===this.totalPages,"aria-label":"Go to next page","aria-controls":"status"},"Next")))}renderSmall(){return a("div",{class:"smallscreen"},a("div",{class:"pagebtncontainer "+(this.isTabbing?"user-is-tabbing":"")},a("button",{id:"wm-1-arw",class:"paginationbtn",onClick:()=>{this.currentPage=1,this.updatePageDisplayed(1),this.maintainFocusOnNumberChange("prev-arrow")},value:1,"aria-current":1===this.currentPage?"page":void 0,"aria-label":"Go to page 1","aria-controls":"status",disabled:1===this.currentPage},a("svg",{width:"16",height:"12",xmlns:"http://www.w3.org/2000/svg"},a("path",{d:"M7.41 10.59L2.83 6l4.58-4.59L6 0 0 6l6 6zM15.41 10.59L10.83 6l4.58-4.59L14 0 8 6l6 6z"}))),a("button",{id:"previous-arw",class:"paginationbtn previousbtn",onClick:()=>{this.currentPage-=1,this.updatePageDisplayed(this.currentPage),this.maintainFocusOnNumberChange("prev-arrow")},disabled:1===this.currentPage,"aria-label":"Go to previous page"},a("svg",{width:"8",height:"12",xmlns:"http://www.w3.org/2000/svg"},a("path",{d:"M7.41 10.59L2.83 6l4.58-4.59L6 0 0 6l6 6z"}))),"Page ",this.currentPage," of ",this.totalPages,a("button",{id:"next-arw",class:"paginationbtn nextbtn",onClick:()=>{this.currentPage+=1,this.updatePageDisplayed(this.currentPage),this.maintainFocusOnNumberChange("next-arrow")},disabled:this.currentPage===this.totalPages,"aria-label":"Go to next page"},a("svg",{width:"8",height:"12",xmlns:"http://www.w3.org/2000/svg"},a("path",{d:"M.59 10.59L5.17 6 .59 1.41 2 0l6 6-6 6z"}))),a("button",{id:`wm-${this.totalPages}-arw`,class:"paginationbtn",onClick:()=>{this.currentPage=this.totalPages,this.updatePageDisplayed(this.totalPages),this.maintainFocusOnNumberChange("next-arrow")},value:this.totalPages,"aria-current":this.currentPage===this.totalPages?"page":void 0,"aria-label":`Go to last page, page ${this.totalPages}`,"aria-controls":"status",disabled:this.currentPage===this.totalPages},a("svg",{width:"17",height:"12",xmlns:"http://www.w3.org/2000/svg"},a("path",{d:"M.59 10.59L5.17 6 .59 1.41 2 0l6 6-6 6zM9.59 10.59L14.17 6 9.59 1.41 11 0l6 6-6 6z"})))))}render(){return this.totalItems>this.itemsPerPage&&a("nav",{"aria-label":`Pagination Navigation. ${this.getCurrentPagesInView()}. Current page, ${this.currentPage}.`},this.isLargeViewport?this.renderLarge():this.renderSmall(),a("div",{id:"status",class:"sr-only","aria-live":"polite","aria-relevant":"text","aria-atomic":"true"},this.srAnnouncement))}get el(){return n(this)}static get watchers(){return{totalItems:["calculateTotalPages"],itemsPerPage:["calculateTotalPages"]}}};s.style='nav .largescreen,nav .smallscreen{margin-bottom:0.625rem;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:flex-end;-ms-flex-pack:flex-end;-webkit-justify-content:flex-end;justify-content:flex-end;font-size:0.875rem}nav .largescreen .pageview,nav .smallscreen .pageview{font-size:0.875rem;margin:0 0.625rem}nav .largescreen .paginationbtn,nav .smallscreen .paginationbtn{position:relative;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;-ms-transition:none;-webkit-transition:none;-moz-transition:none;transition:none;border:none;color:#575195;background-color:transparent;margin:0;padding:0;height:2.5rem;width:2.5rem;font-family:inherit;letter-spacing:0.3px;font-size:0.875rem;font-weight:500;cursor:pointer;text-transform:none}nav .largescreen .paginationbtn svg *,nav .smallscreen .paginationbtn svg *{fill:#565397}nav .largescreen .paginationbtn:hover:not([aria-current=page]):not([disabled]),nav .smallscreen .paginationbtn:hover:not([aria-current=page]):not([disabled]){text-decoration:underline}nav .largescreen .paginationbtn:focus,nav .smallscreen .paginationbtn:focus{outline:none}nav .largescreen .paginationbtn::-moz-focus-inner,nav .smallscreen .paginationbtn::-moz-focus-inner{border:0;outline:none}nav .largescreen .paginationbtn[disabled],nav .smallscreen .paginationbtn[disabled]{color:#9f9f9f;pointer-events:none}nav .largescreen .paginationbtn[disabled] svg *,nav .smallscreen .paginationbtn[disabled] svg *{fill:#9f9f9f}nav .largescreen .previousbtn,nav .smallscreen .previousbtn{margin-right:0.625rem;width:auto !important}nav .largescreen .nextbtn,nav .smallscreen .nextbtn{margin-left:0.625rem;margin-right:0;width:auto !important}nav .largescreen .previousbtn,nav .largescreen .nextbtn,nav .smallscreen .previousbtn,nav .smallscreen .nextbtn{-ms-transition:none;-webkit-transition:none;-moz-transition:none;transition:none}nav .largescreen .ellipsis,nav .smallscreen .ellipsis{display:inline-block;width:2.5rem;text-align:center}nav .largescreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]),nav .smallscreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]){-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}nav .largescreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]):before,nav .smallscreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]):before{position:absolute;content:"";height:auto;width:16px;top:0;bottom:0;left:12px;right:0;background:-webkit-gradient(linear, left top, right top, color-stop(66%, #3862e9), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #3862e9 66%, transparent 0) repeat-x;background-size:6px 2px;background-position:0 2em;border-radius:0;line-height:normal}nav .largescreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).previousbtn:focus:before,nav .smallscreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).previousbtn:focus:before{left:0 !important}nav .largescreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).nextbtn:focus:before,nav .smallscreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).nextbtn:focus:before{left:0 !important}nav .largescreen .pagebtncontainer.user-is-tabbing [aria-current=page]:focus,nav .smallscreen .pagebtncontainer.user-is-tabbing [aria-current=page]:focus{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}nav .largescreen .pagebtncontainer.user-is-tabbing [aria-current=page]:focus::-moz-focus-inner,nav .smallscreen .pagebtncontainer.user-is-tabbing [aria-current=page]:focus::-moz-focus-inner{border:0}nav .largescreen .user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).previousbtn:focus:before{width:56px !important}nav .largescreen .user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).nextbtn:focus:before{width:32px !important}nav .largescreen .paginationbtn[aria-current=page]{-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;border-radius:50%;-webkit-box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);-moz-box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);background-color:#575195;color:#fff}nav .largescreen .paginationbtn[aria-current=page]:hover{-webkit-box-shadow:0 4px 2px 0 rgba(87, 81, 149, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.2);-moz-box-shadow:0 4px 2px 0 rgba(87, 81, 149, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.2);box-shadow:0 4px 2px 0 rgba(87, 81, 149, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.2);background:#4e4986}.sr-only{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}';export{s as wm_pagination}
1
+ import{r as t,c as e,h as a,g as n}from"./p-b3c71506.js";import{d as i}from"./p-de3367ee.js";let s=class{constructor(a){t(this,a),this.wmPaginationPageClicked=e(this,"wmPaginationPageClicked",7),this.pageClicked=e(this,"pageClicked",7),this.focusCurrentPage=e(this,"focusCurrentPage",7),this.currentPage=1,this.totalItems=void 0,this.itemsPerPage=void 0,this.value=1,this.isLargeViewport=window.innerWidth>600,this.isTabbing=!1,this.srAnnouncement="",this.totalPages=0,this.debouncedResize=i((()=>{this.isLargeViewport=window.innerWidth>600}),250),this.getMiddlePageNums=()=>{let t;return t=this.currentPage<4?[2,3,4]:this.currentPage>this.totalPages-3?[this.totalPages-3,this.totalPages-2,this.totalPages-1]:[this.currentPage-1,this.currentPage,this.currentPage+1],t}}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}maintainFocusOnNumberChange(t){window.requestAnimationFrame((()=>{switch(t){case"previous":1===this.currentPage&&this.el.shadowRoot.querySelector("button#wm-1").focus();break;case"next":this.currentPage===this.totalPages&&this.el.shadowRoot.querySelector(`button#wm-${this.totalPages}`).focus();break;case"prev-arrow":1===this.currentPage&&this.el.shadowRoot.querySelector("#next-arw").focus();break;case"next-arrow":this.currentPage===this.totalPages&&this.el.shadowRoot.querySelector("#previous-arw").focus();break;case"page":this.el.shadowRoot.querySelector(`button#wm-${this.currentPage}`).focus();default:return}}))}handleResize(){this.debouncedResize()}calculateTotalPages(){this.totalPages=Math.ceil(this.totalItems/this.itemsPerPage)}componentWillLoad(){if(!this.totalItems||!this.itemsPerPage||!this.currentPage)throw new Error("Please check the required attributes");this.calculateTotalPages(),document.body.classList.contains("wmcl-user-is-tabbing")&&this.toggleTabbingOn()}updatePageDisplayed(t){this.value=t,this.wmPaginationPageClicked.emit(),this.pageClicked.emit(),this.srAnnouncement=`Current page, ${this.currentPage}. ${this.getCurrentPagesInView()}`}displayShortPagination(){let t=[];for(let e=1;e<=this.totalPages;e++)t.push(this.displayPageNumber(e));return t}displayLongPagination(){return[this.displayPageNumber(1),this.currentPage>3&&this.displayEllipsis(),...this.getMiddlePageNums().map((t=>this.displayPageNumber(t))),this.currentPage+2<this.totalPages&&this.displayEllipsis(),this.displayPageNumber(this.totalPages)]}displayPageNumber(t){return a("button",{id:`wm-${t}`,class:"paginationbtn",onClick:()=>{this.currentPage=t,this.updatePageDisplayed(t),this.maintainFocusOnNumberChange("page")},value:t,"aria-label":this.currentPage!==t?`Go to page ${t}`:"","aria-current":this.currentPage===t?"page":void 0},t)}displayEllipsis(){return a("span",{class:"ellipsis"},"...")}getCurrentPagesInView(){let t=this.itemsPerPage*this.currentPage;const e=t-this.itemsPerPage+1;return t>this.totalItems&&(t=this.totalItems),"Viewing "+(e===t?`${e}`:`${e}–${t} of ${this.totalItems}`)}renderLarge(){return a("div",{class:"largescreen"},a("div",{class:"pageview"},this.getCurrentPagesInView()),a("div",{class:"pagebtncontainer "+(this.isTabbing?"user-is-tabbing":"")},a("button",{id:"previous",class:"paginationbtn previousbtn",onClick:()=>{this.currentPage=this.currentPage-1,this.updatePageDisplayed(this.currentPage),this.maintainFocusOnNumberChange("previous")},disabled:1===this.currentPage,"aria-label":"Go to previous page","aria-controls":"status"},"Previous"),this.totalPages<6?this.displayShortPagination():this.displayLongPagination(),a("button",{id:"next",class:"paginationbtn nextbtn",onClick:()=>{this.currentPage=this.currentPage+1,this.updatePageDisplayed(this.currentPage),this.maintainFocusOnNumberChange("next")},disabled:this.currentPage===this.totalPages,"aria-label":"Go to next page","aria-controls":"status"},"Next")))}renderSmall(){return a("div",{class:"smallscreen"},a("div",{class:"pagebtncontainer "+(this.isTabbing?"user-is-tabbing":"")},a("button",{id:"wm-1-arw",class:"paginationbtn",onClick:()=>{this.currentPage=1,this.updatePageDisplayed(1),this.maintainFocusOnNumberChange("prev-arrow")},value:1,"aria-current":1===this.currentPage?"page":void 0,"aria-label":"Go to page 1","aria-controls":"status",disabled:1===this.currentPage},a("svg",{width:"16",height:"12",xmlns:"http://www.w3.org/2000/svg"},a("path",{d:"M7.41 10.59L2.83 6l4.58-4.59L6 0 0 6l6 6zM15.41 10.59L10.83 6l4.58-4.59L14 0 8 6l6 6z"}))),a("button",{id:"previous-arw",class:"paginationbtn previousbtn",onClick:()=>{this.currentPage-=1,this.updatePageDisplayed(this.currentPage),this.maintainFocusOnNumberChange("prev-arrow")},disabled:1===this.currentPage,"aria-label":"Go to previous page"},a("svg",{width:"8",height:"12",xmlns:"http://www.w3.org/2000/svg"},a("path",{d:"M7.41 10.59L2.83 6l4.58-4.59L6 0 0 6l6 6z"}))),"Page ",this.currentPage," of ",this.totalPages,a("button",{id:"next-arw",class:"paginationbtn nextbtn",onClick:()=>{this.currentPage+=1,this.updatePageDisplayed(this.currentPage),this.maintainFocusOnNumberChange("next-arrow")},disabled:this.currentPage===this.totalPages,"aria-label":"Go to next page"},a("svg",{width:"8",height:"12",xmlns:"http://www.w3.org/2000/svg"},a("path",{d:"M.59 10.59L5.17 6 .59 1.41 2 0l6 6-6 6z"}))),a("button",{id:`wm-${this.totalPages}-arw`,class:"paginationbtn",onClick:()=>{this.currentPage=this.totalPages,this.updatePageDisplayed(this.totalPages),this.maintainFocusOnNumberChange("next-arrow")},value:this.totalPages,"aria-current":this.currentPage===this.totalPages?"page":void 0,"aria-label":`Go to last page, page ${this.totalPages}`,"aria-controls":"status",disabled:this.currentPage===this.totalPages},a("svg",{width:"17",height:"12",xmlns:"http://www.w3.org/2000/svg"},a("path",{d:"M.59 10.59L5.17 6 .59 1.41 2 0l6 6-6 6zM9.59 10.59L14.17 6 9.59 1.41 11 0l6 6-6 6z"})))))}render(){return this.totalItems>this.itemsPerPage&&a("nav",{"aria-label":`Pagination Navigation. ${this.getCurrentPagesInView()}. Current page, ${this.currentPage}.`},this.isLargeViewport?this.renderLarge():this.renderSmall(),a("div",{id:"status",class:"sr-only","aria-live":"polite","aria-relevant":"text","aria-atomic":"true"},this.srAnnouncement))}get el(){return n(this)}static get watchers(){return{totalItems:["calculateTotalPages"],itemsPerPage:["calculateTotalPages"]}}};s.style='nav .largescreen,nav .smallscreen{margin-bottom:0.625rem;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:flex-end;-ms-flex-pack:flex-end;-webkit-justify-content:flex-end;justify-content:flex-end;font-size:0.875rem}nav .largescreen .pageview,nav .smallscreen .pageview{font-size:0.875rem;margin:0 0.625rem}nav .largescreen .paginationbtn,nav .smallscreen .paginationbtn{position:relative;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;-ms-transition:none;-webkit-transition:none;-moz-transition:none;transition:none;border:none;color:#575195;background-color:transparent;margin:0;padding:0;height:2.5rem;width:2.5rem;font-family:inherit;letter-spacing:0.3px;font-size:0.875rem;font-weight:500;cursor:pointer;text-transform:none}nav .largescreen .paginationbtn svg *,nav .smallscreen .paginationbtn svg *{fill:#565397}nav .largescreen .paginationbtn:hover:not([aria-current=page]):not([disabled]),nav .smallscreen .paginationbtn:hover:not([aria-current=page]):not([disabled]){text-decoration:underline}nav .largescreen .paginationbtn:focus,nav .smallscreen .paginationbtn:focus{outline:none}nav .largescreen .paginationbtn::-moz-focus-inner,nav .smallscreen .paginationbtn::-moz-focus-inner{border:0;outline:none}nav .largescreen .paginationbtn[disabled],nav .smallscreen .paginationbtn[disabled]{color:#9f9f9f;pointer-events:none}nav .largescreen .paginationbtn[disabled] svg *,nav .smallscreen .paginationbtn[disabled] svg *{fill:#9f9f9f}nav .largescreen .previousbtn,nav .smallscreen .previousbtn{margin-right:0.625rem;width:auto !important}nav .largescreen .nextbtn,nav .smallscreen .nextbtn{margin-left:0.625rem;margin-right:0;width:auto !important}nav .largescreen .previousbtn,nav .largescreen .nextbtn,nav .smallscreen .previousbtn,nav .smallscreen .nextbtn{-ms-transition:none;-webkit-transition:none;-moz-transition:none;transition:none}nav .largescreen .ellipsis,nav .smallscreen .ellipsis{display:inline-block;width:2.5rem;text-align:center}nav .largescreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]),nav .smallscreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]){-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}nav .largescreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]):before,nav .smallscreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]):before{position:absolute;content:"";height:auto;width:16px;top:0;bottom:0;left:12px;right:0;background:-webkit-gradient(linear, left top, right top, color-stop(66%, #3862e9), color-stop(0, transparent)) repeat-x;background:linear-gradient(90deg, #3862e9 66%, transparent 0) repeat-x;background-size:6px 2px;background-position:0 2em;border-radius:0;line-height:normal}nav .largescreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).previousbtn:focus:before,nav .smallscreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).previousbtn:focus:before{left:0 !important}nav .largescreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).nextbtn:focus:before,nav .smallscreen .pagebtncontainer.user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).nextbtn:focus:before{left:0 !important}nav .largescreen .pagebtncontainer.user-is-tabbing [aria-current=page]:focus,nav .smallscreen .pagebtncontainer.user-is-tabbing [aria-current=page]:focus{-webkit-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;-moz-box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e;box-shadow:0 2px 2px 0 rgba(244, 243, 246, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.1), 0 0 4px 3px #61279e}nav .largescreen .pagebtncontainer.user-is-tabbing [aria-current=page]:focus::-moz-focus-inner,nav .smallscreen .pagebtncontainer.user-is-tabbing [aria-current=page]:focus::-moz-focus-inner{border:0}nav .largescreen .user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).previousbtn:focus:before{width:56px !important}nav .largescreen .user-is-tabbing :focus:not(.-disabled):not([aria-current=page]).nextbtn:focus:before{width:32px !important}nav .largescreen .paginationbtn[aria-current=page]{-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;border-radius:50%;-webkit-box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);-moz-box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);box-shadow:0 2px 2px 0 rgba(87, 81, 149, 0.12), 0 2px 2px 0 rgba(0, 0, 0, 0.2);background-color:#575195;color:#fff}nav .largescreen .paginationbtn[aria-current=page]:hover{-webkit-box-shadow:0 4px 2px 0 rgba(87, 81, 149, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.2);-moz-box-shadow:0 4px 2px 0 rgba(87, 81, 149, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.2);box-shadow:0 4px 2px 0 rgba(87, 81, 149, 0.2), 0 2px 2px 0 rgba(0, 0, 0, 0.2);background:#4e4986}.sr-only{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}';export{s as wm_pagination}
@@ -0,0 +1 @@
1
+ window.navigator.plugins.length>0&&console.log("Ripple component library","3.13.0-9"),window.addEventListener("keydown",(function(n){if("Tab"==n.key){var o=new Event("wmUserIsTabbing");window.dispatchEvent(o),document.querySelector("body").classList.add("wmcl-user-is-tabbing")}"ArrowLeft"!=n.key&&"ArrowUp"!=n.key&&"ArrowRight"!=n.key&&"ArrowDown"!=n.key||(o=new Event("wmUserIsKeying"),window.dispatchEvent(o),document.querySelector("body").classList.add("wmcl-user-is-keying"))})),window.addEventListener("mousedown",(function(){var n=new Event("wmUserIsNotTabbing");window.dispatchEvent(n),document.querySelector("body").classList.remove("wmcl-user-is-tabbing"),document.querySelector("body").classList.remove("wmcl-user-is-keying")}));const n=document.createElement("div");n.id="wm-tooltip-container";const o=document.createElement("div");o.id="wm-tooltip",o.setAttribute("aria-hidden","true"),o.style.position="fixed",o.style.overflow="hidden",o.style.pointerEvents="none",o.style.lineHeight="normal",o.style.fontFamily="inherit",o.style.fontSize="0.875rem",o.style.textTransform="none",o.style.fontWeight="normal",o.style.background="black",o.style.color="#fff",o.style.zIndex="999999",o.style.maxWidth="13.75rem",o.style.marginRight="1.5rem",o.style.padding="0.375rem",o.style.transitionProperty="opacity",o.style.transitionDelay="opacity",o.style.opacity="0",o.style.top="0",o.style.left="0",o.style.transform="translateZ(0)",o.style.willChange="transform",o.style.transform="translate(var(--wmTooltipLeft), var(--wmTooltipTop))",n.appendChild(o),document.querySelector("body").appendChild(n);