@watermarkinsights/ripple 5.4.0 → 5.5.0-2

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 (86) hide show
  1. package/dist/cjs/{chartFunctions-ef57119f.js → chartFunctions-ce6c7c16.js} +20 -21
  2. package/dist/cjs/{global-4ff34a0e.js → global-835ecb61.js} +1 -1
  3. package/dist/cjs/loader.cjs.js +1 -1
  4. package/dist/cjs/priv-calendar.cjs.entry.js +13 -9
  5. package/dist/cjs/priv-navigator-item.cjs.entry.js +1 -1
  6. package/dist/cjs/ripple.cjs.js +1 -1
  7. package/dist/cjs/wm-chart.cjs.entry.js +3 -12
  8. package/dist/cjs/wm-date-range.cjs.entry.js +5 -1
  9. package/dist/cjs/wm-datepicker.cjs.entry.js +5 -1
  10. package/dist/cjs/wm-line-chart.cjs.entry.js +1 -1
  11. package/dist/cjs/wm-navigator.cjs.entry.js +12 -16
  12. package/dist/cjs/wm-progress-indicator_3.cjs.entry.js +2 -2
  13. package/dist/collection/components/charts/chartFunctions.js +20 -21
  14. package/dist/collection/components/charts/wm-chart/wm-chart.css +4 -5
  15. package/dist/collection/components/charts/wm-chart/wm-chart.js +2 -11
  16. package/dist/collection/components/charts/wm-progress-monitor/wm-progress-indicator.css +4 -5
  17. package/dist/collection/components/datepickers/priv-calendar/priv-calendar.js +17 -9
  18. package/dist/collection/components/datepickers/wm-date-range.js +5 -1
  19. package/dist/collection/components/datepickers/wm-datepicker.js +5 -1
  20. package/dist/collection/components/wm-navigator/priv-navigator-item/priv-navigator-item.css +3 -3
  21. package/dist/collection/components/wm-navigator/wm-navigator.css +1 -0
  22. package/dist/collection/components/wm-navigator/wm-navigator.js +13 -17
  23. package/dist/esm/{chartFunctions-d3fd6e7c.js → chartFunctions-0ebf83f3.js} +20 -21
  24. package/dist/esm/{global-588c6343.js → global-ec8d6686.js} +1 -1
  25. package/dist/esm/loader.js +1 -1
  26. package/dist/esm/priv-calendar.entry.js +13 -9
  27. package/dist/esm/priv-navigator-item.entry.js +1 -1
  28. package/dist/esm/ripple.js +1 -1
  29. package/dist/esm/wm-chart.entry.js +3 -12
  30. package/dist/esm/wm-date-range.entry.js +5 -1
  31. package/dist/esm/wm-datepicker.entry.js +5 -1
  32. package/dist/esm/wm-line-chart.entry.js +1 -1
  33. package/dist/esm/wm-navigator.entry.js +12 -16
  34. package/dist/esm/wm-progress-indicator_3.entry.js +2 -2
  35. package/dist/esm-es5/chartFunctions-0ebf83f3.js +1 -0
  36. package/dist/esm-es5/global-ec8d6686.js +1 -0
  37. package/dist/esm-es5/loader.js +1 -1
  38. package/dist/esm-es5/priv-calendar.entry.js +1 -1
  39. package/dist/esm-es5/priv-navigator-item.entry.js +1 -1
  40. package/dist/esm-es5/ripple.js +1 -1
  41. package/dist/esm-es5/wm-chart.entry.js +1 -1
  42. package/dist/esm-es5/wm-date-range.entry.js +1 -1
  43. package/dist/esm-es5/wm-datepicker.entry.js +1 -1
  44. package/dist/esm-es5/wm-line-chart.entry.js +1 -1
  45. package/dist/esm-es5/wm-navigator.entry.js +1 -1
  46. package/dist/esm-es5/wm-progress-indicator_3.entry.js +1 -1
  47. package/dist/ripple/p-011477e2.entry.js +1 -0
  48. package/dist/ripple/p-021ff5fa.system.entry.js +1 -0
  49. package/dist/ripple/p-204bdd73.entry.js +1 -0
  50. package/dist/ripple/{p-e7a64841.system.entry.js → p-28b70082.system.entry.js} +1 -1
  51. package/dist/ripple/p-361f6e59.system.js +1 -0
  52. package/dist/ripple/p-3b8b1b44.system.entry.js +1 -0
  53. package/dist/ripple/{p-f67fd802.system.entry.js → p-4a6854d3.system.entry.js} +1 -1
  54. package/dist/ripple/{p-e3de5bbd.system.entry.js → p-4c8db09c.system.entry.js} +1 -1
  55. package/dist/ripple/{p-0aa17cac.entry.js → p-4d0b1890.entry.js} +1 -1
  56. package/dist/ripple/p-5d0e2006.system.entry.js +1 -0
  57. package/dist/ripple/{p-763a01bc.system.js → p-811d5a9f.system.js} +1 -1
  58. package/dist/ripple/p-825bd63b.entry.js +1 -0
  59. package/dist/ripple/p-99dd083d.system.js +1 -0
  60. package/dist/ripple/p-a27d2177.entry.js +1 -0
  61. package/dist/ripple/p-ab0e197b.js +1 -0
  62. package/dist/ripple/{p-591918a4.entry.js → p-ade3d9a9.entry.js} +1 -1
  63. package/dist/ripple/p-c47811a2.entry.js +1 -0
  64. package/dist/ripple/{p-9a3e656a.entry.js → p-dbc112a6.entry.js} +1 -1
  65. package/dist/ripple/p-e3241417.system.entry.js +1 -0
  66. package/dist/ripple/p-f92bd0c1.js +1 -0
  67. package/dist/ripple/{p-49b7970e.system.entry.js → p-fd0aae67.system.entry.js} +1 -1
  68. package/dist/ripple/ripple.esm.js +1 -1
  69. package/dist/ripple/ripple.js +1 -1
  70. package/dist/types/global/interfaces.d.ts +1 -1
  71. package/package.json +1 -1
  72. package/dist/esm-es5/chartFunctions-d3fd6e7c.js +0 -1
  73. package/dist/esm-es5/global-588c6343.js +0 -1
  74. package/dist/ripple/p-0f0466c6.js +0 -1
  75. package/dist/ripple/p-2be33eb4.system.js +0 -1
  76. package/dist/ripple/p-3183bba8.entry.js +0 -1
  77. package/dist/ripple/p-4bacf5a7.system.entry.js +0 -1
  78. package/dist/ripple/p-5c10e2ae.entry.js +0 -1
  79. package/dist/ripple/p-75ba63ba.entry.js +0 -1
  80. package/dist/ripple/p-97aaa344.system.js +0 -1
  81. package/dist/ripple/p-bee9a5dc.js +0 -1
  82. package/dist/ripple/p-c91b10f3.system.entry.js +0 -1
  83. package/dist/ripple/p-cc4a429b.entry.js +0 -1
  84. package/dist/ripple/p-d86bd773.entry.js +0 -1
  85. package/dist/ripple/p-f4210450.system.entry.js +0 -1
  86. package/dist/ripple/p-fe8d02c3.system.entry.js +0 -1
@@ -115,7 +115,7 @@ DOMTokenList
115
115
  var resourcesUrl = scriptElm ? scriptElm.getAttribute('data-resources-url') || scriptElm.src : '';
116
116
  var start = function() {
117
117
  // if src is not present then origin is "null", and new URL() throws TypeError: Failed to construct 'URL': Invalid base URL
118
- var url = new URL('./p-763a01bc.system.js', new URL(resourcesUrl, window.location.origin !== 'null' ? window.location.origin : undefined));
118
+ var url = new URL('./p-811d5a9f.system.js', new URL(resourcesUrl, window.location.origin !== 'null' ? window.location.origin : undefined));
119
119
  System.import(url.href);
120
120
  };
121
121
 
@@ -61,7 +61,7 @@ export type ChartDetails = {
61
61
  padding: number;
62
62
  category: "doughnut" | "stackedBar" | "simpleBar";
63
63
  };
64
- export type ChartType = "doughnut" | "bar" | "doughnut1" | "doughnut2" | "doughnut2b" | "doughnut3" | "bar2" | "bar2b" | "bar3" | "bar4" | "bar5" | "bar6" | "bar7";
64
+ export type ChartType = "doughnut" | "bar" | "doughnut1" | "doughnut2" | "doughnut3" | "bar2" | "bar3" | "bar4" | "bar5" | "bar6" | "bar7";
65
65
  export type LegendItem = {
66
66
  key: string;
67
67
  color: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@watermarkinsights/ripple",
3
- "version": "5.4.0",
3
+ "version": "5.5.0-2",
4
4
  "description": "Ripple Component Library",
5
5
  "license": "MIT",
6
6
  "module": "dist/index.js",
@@ -1 +0,0 @@
1
- var __awaiter=this&&this.__awaiter||function(e,t,r,n){function a(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,i){function s(e){try{c(n.next(e))}catch(e){i(e)}}function o(e){try{c(n["throw"](e))}catch(e){i(e)}}function c(e){e.done?r(e.value):a(e.value).then(s,o)}c((n=n.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var r={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,a,i,s;return s={next:o(0),throw:o(1),return:o(2)},typeof Symbol==="function"&&(s[Symbol.iterator]=function(){return this}),s;function o(e){return function(t){return c([e,t])}}function c(o){if(n)throw new TypeError("Generator is already executing.");while(s&&(s=0,o[0]&&(r=0)),r)try{if(n=1,a&&(i=o[0]&2?a["return"]:o[0]?a["throw"]||((i=a["return"])&&i.call(a),0):a.next)&&!(i=i.call(a,o[1])).done)return i;if(a=0,i)o=[o[0]&2,i.value];switch(o[0]){case 0:case 1:i=o;break;case 4:r.label++;return{value:o[1],done:false};case 5:r.label++;a=o[1];o=[0];continue;case 7:o=r.ops.pop();r.trys.pop();continue;default:if(!(i=r.trys,i=i.length>0&&i[i.length-1])&&(o[0]===6||o[0]===2)){r=0;continue}if(o[0]===3&&(!i||o[1]>i[0]&&o[1]<i[3])){r.label=o[1];break}if(o[0]===6&&r.label<i[1]){r.label=i[1];i=o;break}if(i&&r.label<i[2]){r.label=i[2];r.ops.push(o);break}if(i[2])r.ops.pop();r.trys.pop();continue}o=t.call(e,r)}catch(e){o=[6,e];a=0}finally{n=i=0}if(o[0]&5)throw o[1];return{value:o[0]?o[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(e,t,r){if(r||arguments.length===2)for(var n=0,a=t.length,i;n<a;n++){if(i||!(n in t)){if(!i)i=Array.prototype.slice.call(t,0,n);i[n]=t[n]}}return e.concat(i||Array.prototype.slice.call(t))};import{h}from"./index-558b5a82.js";import{i as intl,c as safeMultiplyFloat,e as getPosition,f as checkForActiveElInShadow}from"./functions-46843ea0.js";var colors={salmon:"#ff5f4e",cyan:"#19a1a9",forest:"#088000",sleet:"#7f97ad",midnight:"#2e1b46",lavender:"#8b86ca",periwinkle:"#575195",gray:"#6b6b6b"};var allChartsDetails={doughnut:{size:155,colors:[colors.forest,colors.gray],thickness:.73,padding:25,category:"doughnut"},doughnut1:{size:130,colors:[colors.lavender,colors.midnight,colors.gray],thickness:.5,padding:90,category:"doughnut"},doughnut2:{size:130,colors:[colors.cyan,colors.salmon,colors.gray],thickness:.5,padding:90,category:"doughnut"},doughnut2b:{size:130,colors:[colors.periwinkle,colors.cyan,colors.salmon,colors.gray],thickness:.5,padding:90,category:"doughnut"},doughnut3:{size:130,colors:[colors.lavender,colors.midnight,"#0089e4",colors.forest,"#ea8500","#d54f41","#146ca9"],thickness:.5,padding:90,category:"doughnut"},bar:{size:350,colors:[colors.forest,colors.gray],padding:0,category:"stackedBar"},bar2:{size:400,colors:[colors.gray,colors.periwinkle,colors.cyan,colors.salmon],padding:0,category:"stackedBar"},bar2b:{size:400,colors:[colors.gray,colors.periwinkle,colors.midnight,colors.cyan,colors.salmon],padding:0,category:"stackedBar"},bar3:{size:300,colors:["#0d696e",colors.cyan,"#8e4129",colors.salmon],padding:0,category:"stackedBar"},bar4:{size:400,colors:[colors.salmon,colors.cyan,colors.periwinkle],padding:0,category:"stackedBar"},bar5:{size:400,colors:[colors.gray,colors.lavender,colors.midnight,"#0089e4",colors.forest,"#ea8500","#d54f41","#146ca9"],padding:0,category:"stackedBar"},bar6:{size:400,colors:[colors.lavender],padding:0,category:"simpleBar"},bar7:{size:400,colors:[colors.periwinkle,colors.cyan,colors.salmon,colors.gray],padding:0,category:"simpleBar"}};function showValue(e){return e==="percentage"||e==="amount"?"show-values":""}var textHiddenMessage=intl.formatMessage({id:"chart.hiddenValues",defaultMessage:"Values are hidden when too close together.",description:"Text displayed when a chart has some values hidden"});var seeDetailsMessage=intl.formatMessage({id:"chart.clickToSeeDetails",defaultMessage:"Click or use arrow keys to see details.",description:"Text displayed, guiding user to interact to see more details."});function abbrNumber(e){return e>999||e<-999?Math.round(e/100)/10+"K":e}function amountToPercent(e,t,r){return r?Math.round(e*100/t):Math.round(e*1e4/t)/100}function amountToDegree(e,t){return e*360/t}function toFixed(e){return parseFloat((Math.floor(e*100)/100).toFixed(2))}function polarToCartesian(e,t,r,n){var a=toFixed(e+e*t*Math.cos(Math.PI*r/180));var i=toFixed(e+e*t*Math.sin(Math.PI*r/180));if(n!==undefined){var s=toFixed(e+e*t*Math.cos(Math.PI*n/180));var o=toFixed(e+e*t*Math.sin(Math.PI*n/180));return{x1:a,y1:i,x2:s,y2:o}}return{x:a,y:i}}function getArc(e,t,r,n,a){var i=toFixed(a/2*e);return"A ".concat(i,", ").concat(i," 0 ").concat(t," ").concat(toFixed(r),", ").concat(toFixed(n))}function scale(e,t,r,n,a){var i=(e-t)*(a-n)/(r-t)+n;return i<n?n:i>a?a:i}function minSpacing(e){return scale(e,300,900,70,150)}function getMaxTicks(e){return Math.round(e/minSpacing(e))}function getInterval(e,t){var r=e/t;var n=Math.pow(10,Math.floor(Math.log10(r)));var a=r/n;var i;if(a>5){i=10*n}else if(a>3){i=5*n}else if(a>2){i=3*n}else if(a>1.5){i=2*n}else if(a>1){i=1.5*n}else{i=n}return i}function handleSliceKeyDown(e){if(this.popoverEl&&this.popoverEl.open&&e.key==="Enter"){var t=this.popoverEl.querySelector("button");t&&t.click()}}function handleSliceClick(e,t){if(this.popoverEl&&!this.isTabbing){t.coords={x:e.clientX,y:e.clientY};openPopover(this.popoverEl,t);highlightSegmentInfo(Array.from(this.el.shadowRoot.querySelectorAll("[data-segmentindex")),t)}}function handleSliceFocus(e,t){if(this.popoverEl&&this.isTabbing){this.focusedSliceId=t.id;t.coords=getPosition(e.target);t.coords.x=t.coords.x+30;t.coords.y=t.coords.y+30;openPopover(this.popoverEl,t);highlightSegmentInfo(Array.from(this.el.shadowRoot.querySelectorAll("[data-segmentindex")),t)}}function handleChartKeydown(e){switch(e.key){case"ArrowUp":case"ArrowLeft":e.preventDefault();this.isTabbing=true;focusPrevious.call(this);break;case"ArrowRight":case"ArrowDown":e.preventDefault();this.isTabbing=true;focusNext.call(this);break;case"Tab":exitChart.call(this);break;case"Escape":this.popoverEl.open=false;this.userIsNavigating=false;break}}function openPopover(e,t){e.open=false;if(t.title&&t.text){e.sliceDetails=Object.assign({},t);window.setTimeout((function(){return e.open=true}),30)}}function focusNext(){var e=checkForActiveElInShadow(document.activeElement);var t=(this.sliceEls.indexOf(e)+1)%this.sliceEls.length;focusSlice.call(this,t)}function focusPrevious(){if(this.sliceEls){var e=checkForActiveElInShadow(document.activeElement);var t=this.sliceEls.indexOf(e);if(t===-1){t=0}else if(t===0){t=this.sliceEls.length-1}else{t-=1}focusSlice.call(this,t)}}function focusSlice(e){var t=this;if(this.sliceEls&&this.el){this.userIsNavigating=true;this.componentWrapperEl.tabIndex=-1;this.el.focusable=false;this.sliceEls.map((function(e){e.tabIndex=-1;e.focusable=false}));this.sliceEls[e].tabIndex=0;this.sliceEls[e].focusable=true;this.sliceEls[e].focus();this.focusedSliceId=this.sliceEls[e].id;window.setTimeout((function(){if(t.popoverEl){t.popoverEl.open=true}}),10)}}function exitChart(){var e=this;this.focusedSliceId=undefined;this.sliceEls&&this.sliceEls.map((function(e){e.tabIndex=-1;e.focusable=false}));this.userIsNavigating=false;window.setTimeout((function(){e.componentWrapperEl.tabIndex=0;e.el.focusable=true;if(e.popoverEl){e.popoverEl.open=false}}),100)}function getDetails(e){return __awaiter(this,void 0,void 0,(function(){var t,r,n;var a=this;return __generator(this,(function(i){this.slicesDetails=[];t=0;r=Array.from(this.el.children);this.total=r.reduce((function(e,t){return e+=parseInt(t.getAttribute("amount")||"0")}),0);n=allChartsDetails[e].colors;if(e==="bar3"&&r.length===2){n=[n[1],n[3]]}r.forEach((function(r,i){var s=parseInt(r.getAttribute("amount")||"0");var o=amountToPercent(s,a.total,true);var c=i;if(e==="bar5"){c=a.notStartedColor?i:i+1}if(e==="bar6"){c=0}var u={amount:s,perc:o,legend:r.getAttribute("legend"),color:n[c]||colors.gray,offset:t,id:"".concat(a.uid,"-").concat(i+1),title:r.getAttribute("popover-title"),text:r.getAttribute("popover-text"),buttonText:r.getAttribute("popover-button-text"),sliceRef:r,inSmallCluster:false,index:i};t+=s;a.slicesDetails.push(u)}));return[2]}))}))}function sortSlicesDetails(e,t){var r=__spreadArray([],e,true).sort((function(e,t){return e.amount===t.amount?0:e.amount>t.amount?-1:1}));var n=0;r.filter((function(e){return e.amount>0})).forEach((function(e,a){var i=r[a===0?r.length-1:a-1];var s=r[a===r.length-1?0:a+1];var o=amountToPercent(i.amount,t,true);var c=amountToPercent(s.amount,t,true);var u=e.perc===0?8:5;var h=e.perc<4;var l=o<u;var d=c<u;var f=h&&(l||d);e.inSmallCluster=f;e.offset=n;n+=e.amount}));return r}function getPathData(e,t,r){var n=amountToDegree(t,this.total)-90;var a=e/this.total*360;var i=n+a;var s=a>180?"1 1":"0 1";var o=a>180?"1 0":"0 0";var c=this.chartDetails.size/2;var u=this.chartDetails.thickness;var h=1;var l=r==="doughnut";var d=1.5;var f=l?2.25:3;if(a===360){i-=.01}var v=polarToCartesian(c,h,n+d,i);var g=polarToCartesian(c,u,n+f,i);var p="M ".concat(v.x1,", ").concat(v.y1," ");var m=getArc(h,s,v.x2,v.y2,this.chartDetails.size);var b=" L ".concat(g.x2,", ").concat(g.y2," ");var x=getArc(u,o,g.x1,g.y1,this.chartDetails.size);return p+m+b+x+" z"}function renderInstructionsText(){var e=intl.formatMessage({id:"chart.instructions",defaultMessage:"Use arrow keys to browse elements, press Tab to exit.",description:"For screen readers only, instructions on how to interact with the chart component"});return h("div",{id:"chart-instructions"},e)}function renderFilter(){return h("defs",null,h("filter",{id:"wmHoverDropShadow"},h("feGaussianBlur",{stdDeviation:"3"}),h("feOffset",{result:"offsetblur"}),h("feFlood",{"flood-color":"#333"}),h("feComposite",{operator:"in",in2:"offsetblur"}),h("feMerge",null,h("feMergeNode",null),h("feMergeNode",{in:"SourceGraphic"}))))}function applyMinimumAngle(e,t,r){var n=t.map((function(e){return amountToDegree(e.amount,r)}));var a=n.some((function(t){return t!==0&&t<e}));if(a){var i=n.map((function(t){return t==0?t:Math.max(t,e)}));var s=i.reduce((function(t,r){return t+(r>e&&r!==0?r:0)}),0);var o=i.reduce((function(t,r){return t+(r>e&&r!==0?0:r)}),0);var c=360-o;var u=s-c;var h=u/c;var l=i.map((function(t){return t>e?t-h*t:t==0?0:e}));var d=0;t=t.map((function(e,t){var n=l[t]/360*r;var a=d;d+=n;return Object.assign(Object.assign({},e),{amount:n,offset:a})}))}return t}function renderDoughnut(e){var t=this;var r=this.chartDetails.size+this.chartDetails.padding;var n=e==="doughnut";var a=n?this.slicesDetails:sortSlicesDetails(this.slicesDetails,this.total);a=applyMinimumAngle(7,a,this.total);return h("div",{class:"chart-wrapper doughnut-wrapper"},h("svg",{width:r+"px",height:r+"px",id:"graphic-".concat(this.uid),class:"doughnut-svg"},renderFilter(),a.map((function(r){return renderPath.call(t,r,e)})),renderFocusOutline.call(this),n?h("text",{class:"value",x:"50%",y:"50%","font-size":"1.5rem","font-weight":"500","text-anchor":"middle","dominant-baseline":"middle"},amountToPercent(a[0].amount,this.total,true)+"%"):h("g",{transform:"translate(".concat(this.chartDetails.padding/2,", ").concat(this.chartDetails.padding/2,")"),"text-anchor":"middle","dominant-baseline":"middle"},a.map((function(e){return e.amount>0&&!e.inSmallCluster?renderDoughnutText.call(t,e):""})))))}function highlightSegmentInfo(e,t){e.forEach((function(e){if(e.dataset.segmentindex&&parseInt(e.dataset.segmentindex)!==t.index){e.classList.add("faded")}else{e.classList.remove("faded")}}))}function removeSegmentInfoHighlight(e){e.forEach((function(e){e.classList.remove("faded")}))}function renderPath(e,t){var r=this;var n=amountToPercent(e.amount,this.total,true)+"%";return!isNaN(e.amount)&&h("g",{transform:"translate(".concat(this.chartDetails.padding/2,", ").concat(this.chartDetails.padding/2,")")},h("path",{id:e.id,class:"segment doughnut-segment",fill:e.amount?e.color:"transparent",d:getPathData.call(this,e.amount,e.offset,t),onClick:function(t){return handleSliceClick.call(r,t,e)},onFocus:function(t){return handleSliceFocus.call(r,t,e)},onKeyDown:function(e){return handleSliceKeyDown.call(r,e)},role:"img","aria-label":"".concat(e.legend,", ").concat(n),"data-segmentindex":e.index}))}function renderFocusOutline(){return this.isTabbing?h("g",{transform:"translate(".concat(this.chartDetails.padding/2,", ").concat(this.chartDetails.padding/2,")")},h("use",{tabindex:-1,id:"kfbg1",xlinkHref:"#".concat(this.focusedSliceId)}),h("use",{tabindex:-1,id:"kfstroke",xlinkHref:"#".concat(this.focusedSliceId)}),h("use",{tabindex:-1,id:"kfbg2",xlinkHref:"#".concat(this.focusedSliceId)})):""}function renderDoughnutText(e){var t=amountToDegree(e.offset+e.amount/2,this.total);var r=polarToCartesian(this.chartDetails.size/2,1.4,t-90),n=r.x,a=r.y;return h("text",{class:"value",x:n+"px",y:a+"px","data-segmentindex":e.index},"".concat(e.perc>0?e.perc:"<1","%"))}function renderStackedBar(e){var t=this;var r=e==="bar";var n=this.el.shadowRoot.querySelectorAll(".value");if(n.length>0){requestAnimationFrame((function(){var e=[];var r=4;var a=false;n.forEach((function(t){t.classList.remove("hidden");var n=parseInt(t.dataset.value);if(e.length>0&&n!=0){var i=t.getBoundingClientRect().left-r;e.forEach((function(e){var r=parseInt(e.dataset.value);var s=e.getBoundingClientRect().right>i;if(s){var o=n<r?t:e;o.classList.add("hidden");a=true}}))}if(!t.classList.contains("hidden")&&n>0){e.push(t)}}));(t.isBar||t.isDoughnut)&&t.showHiddenValuesMessage(a)}))}return h("div",{class:"chart-wrapper bar-wrapper"},r?h("div",{class:"single-perc"},amountToPercent(this.slicesDetails[0].amount,this.total,true)+"%"):"",this.chartType==="bar3"&&this.drawAxis(),h("div",{class:"inner-stacked-bar-wrapper ".concat(showValue(this.valueFormat))},!r?h("div",{class:"values"},this.slicesDetails.map((function(e){return t.renderBarText(e,5)}))):"",h("div",{class:"stacked-bar-segments-wrapper"},this.slicesDetails.map((function(e){return renderStackedBarSegment.call(t,e,5)}))),r?renderCompletionMessage.call(this):""))}function renderStackedBarSegment(e,t){var r=this;var n=amountToPercent(e.amount,this.total,false);var a=this.el.shadowRoot.querySelector(".stacked-bar-segments-wrapper");var i=a?a.offsetWidth:this.el.offsetWidth;var s=n/100*i>=t;var o=s||e.amount==0?"".concat(n,"%"):"".concat(t,"px");var c="";if(this.valueFormat=="percentage"){c="".concat(amountToPercent(e.amount,this.total,true)," %")}else if(this.valueFormat=="amount"){c=e.amount.toString()}return h("div",{class:"segment stacked-bar-segment ".concat(amountToPercent(e.amount,this.total,false)===0?"zero":""," ").concat(s?"":"fixed-width"),style:{backgroundColor:e.color,width:o},onClick:function(t){return handleSliceClick.call(r,t,e)},onFocus:function(t){return handleSliceFocus.call(r,t,e)},onKeyDown:function(e){return handleSliceKeyDown.call(r,e)},"data-segmentindex":e.index},h("span",{class:"sr-only"},"".concat(e.legend," ").concat(c)))}function renderSimpleBar(e){var t=this;var r=this.slicesDetails.map((function(e){return e.amount})).reduce((function(e,t){return e>t?e:t}));var n=parseInt(getComputedStyle(this.el).getPropertyValue("--labelWidth"),10);var a=48;var i=this.el.getBoundingClientRect().width;var s=i-n-a;var o=getMaxTicks(s);var c=getInterval(r,o);var u=o*c;var l=Math.floor((u-r)/c);o-=l;this.el.style.setProperty("--backgroundSize",100/o+"%");this.el.style.setProperty("--labelWidth",this.labelWidth);if(e==="bar7"&&!this.showBarLegend){this.el.style.setProperty("--labelWidth","0px")}var d=[];this.slicesDetails.forEach((function(n){n.legend&&d.push(renderSimpleBarLegend(n.legend,t.showBarLegend,e));d.push(renderSimpleBarItem.call(t,n,c,o,r))}));var f=[];for(var v=1;v<=o;v++){var g=abbrNumber(safeMultiplyFloat(v,c));f.push(h("div",{class:"tick"},h("span",null,g)))}var p=e==="bar6"&&this.showGrid&&this.el.getBoundingClientRect().width>300;return h("div",{class:"chart-wrapper simple-bar-wrapper"},h("div",{class:"chart ".concat(showValue(this.valueFormat))},p&&h("div",{class:"gridlines"}),h("div",{class:"rows"},d)),p&&h("div",{class:"x-axis","aria-hidden":"true"},h("div",{class:"zero"},h("span",null,"0")),f))}function renderSimpleBarLegend(e,t,r){var n=r==="bar7"&&!t?" hidden":"";return h("label",{class:"label".concat(n)},e)}function renderSimpleBarItem(e,t,r,n){var a=this;var i=this.currentChartType==="bar6"?t*r:n;var s=amountToPercent(e.amount,i,false);var o=s?s+"%":"1px";var c=abbrNumber(e.amount);var u=this.valueFormat==="amount"?c:"";if(this.currentChartType==="bar6"&&this.valueFormat==="percentage"){u=e.amount+"%"}else if(this.currentChartType==="bar7"&&this.valueFormat==="percentage"){u=(this.total===0?"0":amountToPercent(e.amount,this.total,true))+"%"}return h("div",{class:"bar segment",style:{backgroundColor:e.color,width:o},onClick:function(t){return handleSliceClick.call(a,t,e)},onFocus:function(t){return handleSliceFocus.call(a,t,e)},onKeyDown:function(e){return handleSliceKeyDown.call(a,e)},"data-segmentindex":e.index},h("div",{class:"value"},u))}function renderLegend(e){var t=this;if(this.showLegend){var r=this.slicesDetails.reduce((function(e,t){return e=t.inSmallCluster?true:e}),false);this.isDoughnut&&this.showHiddenValuesMessage(r);return h("div",{class:"legend-wrapper"},h("div",{class:"legend ".concat(e," ").concat(this.mode==="bar"?"--top":"--bottom"),"aria-hidden":"true"},this.slicesDetails.map((function(e){var r=t.printModeFormat=="amount"?"".concat(e.amount,"/").concat(t.total):"".concat(amountToPercent(e.amount,t.total,true),"%");if(!!e.amount||!!e.legend){return renderLegendItem.call(t,{key:e.legend,color:e.color},r,e)}}))),this.isDoughnut&&!this.printMode&&renderHiddenValuesMessage())}}function renderLegendItem(e,t,r){var n=this;if(t===void 0){t=""}if(r===void 0){r=null}var a=function(e){if(r){r.coords={x:e.clientX,y:e.clientY};openPopover(n.popoverEl,r);highlightSegmentInfo(Array.from(n.el.shadowRoot.querySelectorAll("[data-segmentindex")),r)}};return h("div",{class:"legend-item",onClick:function(e){return a(e)},"data-segmentindex":r?r.index:null},h("div",{class:"legend-color",style:{backgroundColor:e.color}}),h("div",{class:"legend-text"},e.key,t&&h("span",{class:"print-value ".concat(this.printMode?"force-visible":"")},": ",t)))}function renderCompletionMessage(){if(this.completionMessage){return h("div",{class:"completion-message"},this.completionMessage)}}function renderHiddenValuesMessage(){return h("div",{class:"hidden-values-warning hidden"},textHiddenMessage,h("br",null),seeDetailsMessage)}export{allChartsDetails as a,renderSimpleBar as b,renderStackedBar as c,renderDoughnut as d,renderInstructionsText as e,renderLegend as f,getDetails as g,handleChartKeydown as h,renderHiddenValuesMessage as i,exitChart as j,amountToPercent as k,renderCompletionMessage as l,renderLegendItem as m,abbrNumber as n,getInterval as o,removeSegmentInfoHighlight as r};
@@ -1 +0,0 @@
1
- var version="5.4.0";if(window.navigator.plugins.length>0){console.log("Ripple component library",version)}function wmComponentKeys(o){if(o.key=="Tab"){var n=new Event("wmUserIsTabbing");window.dispatchEvent(n);document.querySelector("body").classList.add("wmcl-user-is-tabbing")}if(o.key=="ArrowLeft"||o.key=="ArrowUp"||o.key=="ArrowRight"||o.key=="ArrowDown"){var n=new Event("wmUserIsKeying");window.dispatchEvent(n);document.querySelector("body").classList.add("wmcl-user-is-keying")}}function wmComponentMouseDownOnce(){var o=new Event("wmUserIsNotTabbing");window.dispatchEvent(o);document.querySelector("body").classList.remove("wmcl-user-is-tabbing");document.querySelector("body").classList.remove("wmcl-user-is-keying")}window.addEventListener("keydown",wmComponentKeys);window.addEventListener("mousedown",wmComponentMouseDownOnce);var tooltipContainer=document.createElement("div");tooltipContainer.id="wm-tooltip-container";var tooltipEl=document.createElement("div");tooltipEl.id="wm-tooltip";tooltipEl.classList.add("wm-tooltip");tooltipEl.setAttribute("popover","manual");tooltipEl.setAttribute("aria-hidden","true");var tooltipStyles=document.createElement("style");tooltipStyles.textContent="\n.wm-tooltip {\n position: fixed;\n overflow: hidden;\n pointer-events: none;\n line-height: normal;\n font-family: inherit;\n font-size: 0.875rem;\n text-transform: none;\n font-weight: normal;\n background: var(--wmcolor-tooltip-background);\n color: var(--wmcolor-tooltip-text);\n z-index: 999999;\n max-width: var(--wmTooltipMaxWidth, 13.75rem);\n margin-right: 1.5rem;\n padding: 0.375rem;\n transition-property: opacity;\n transition-delay: 0s;\n opacity: 0;\n inset: unset;\n top: 0;\n left: 0;\n transform: translateZ(0);\n will-change: transform;\n transform: translate(var(--wmTooltipLeft), var(--wmTooltipTop));\n border: none;\n}\n\n.wm-tooltip:popover-open {\n opacity: 0;\n}\n\n.wm-tooltip.show {\n transition-delay: 500ms;\n opacity: 1;\n}\n";document.head.appendChild(tooltipStyles);tooltipContainer.appendChild(tooltipEl);document.querySelector("body").appendChild(tooltipContainer);
@@ -1 +0,0 @@
1
- import{h as t}from"./p-568c595f.js";import{i as s,c as i,e,f as n}from"./p-e995f7f0.js";const a="#ff5f4e",r="#19a1a9",o="#088000",h="#2e1b46",c="#8b86ca",d="#575195",l="#6b6b6b",u={doughnut:{size:155,colors:[o,l],thickness:.73,padding:25,category:"doughnut"},doughnut1:{size:130,colors:[c,h,l],thickness:.5,padding:90,category:"doughnut"},doughnut2:{size:130,colors:[r,a,l],thickness:.5,padding:90,category:"doughnut"},doughnut2b:{size:130,colors:[d,r,a,l],thickness:.5,padding:90,category:"doughnut"},doughnut3:{size:130,colors:[c,h,"#0089e4",o,"#ea8500","#d54f41","#146ca9"],thickness:.5,padding:90,category:"doughnut"},bar:{size:350,colors:[o,l],padding:0,category:"stackedBar"},bar2:{size:400,colors:[l,d,r,a],padding:0,category:"stackedBar"},bar2b:{size:400,colors:[l,d,h,r,a],padding:0,category:"stackedBar"},bar3:{size:300,colors:["#0d696e",r,"#8e4129",a],padding:0,category:"stackedBar"},bar4:{size:400,colors:[a,r,d],padding:0,category:"stackedBar"},bar5:{size:400,colors:[l,c,h,"#0089e4",o,"#ea8500","#d54f41","#146ca9"],padding:0,category:"stackedBar"},bar6:{size:400,colors:[c],padding:0,category:"simpleBar"},bar7:{size:400,colors:[d,r,a,l],padding:0,category:"simpleBar"}};function f(t){return"percentage"===t||"amount"===t?"show-values":""}const g=s.formatMessage({id:"chart.hiddenValues",defaultMessage:"Values are hidden when too close together.",description:"Text displayed when a chart has some values hidden"}),p=s.formatMessage({id:"chart.clickToSeeDetails",defaultMessage:"Click or use arrow keys to see details.",description:"Text displayed, guiding user to interact to see more details."});function b(t){return t>999||t<-999?Math.round(t/100)/10+"K":t}function m(t,s,i){return i?Math.round(100*t/s):Math.round(1e4*t/s)/100}function v(t,s){return 360*t/s}function x(t){return parseFloat((Math.floor(100*t)/100).toFixed(2))}function w(t,s,i,e){var n=x(t+t*s*Math.cos(Math.PI*i/180)),a=x(t+t*s*Math.sin(Math.PI*i/180));return void 0!==e?{x1:n,y1:a,x2:x(t+t*s*Math.cos(Math.PI*e/180)),y2:x(t+t*s*Math.sin(Math.PI*e/180))}:{x:n,y:a}}function k(t,s,i,e,n){var a=x(n/2*t);return`A ${a}, ${a} 0 ${s} ${x(i)}, ${x(e)}`}function y(t,s){const i=t/s,e=10**Math.floor(Math.log10(i)),n=i/e;let a;return a=n>5?10*e:n>3?5*e:n>2?3*e:n>1.5?2*e:n>1?1.5*e:e,a}function $(t){if(this.popoverEl&&this.popoverEl.open&&"Enter"===t.key){const t=this.popoverEl.querySelector("button");t&&t.click()}}function M(t,s){this.popoverEl&&!this.isTabbing&&(s.coords={x:t.clientX,y:t.clientY},A(this.popoverEl,s),K(Array.from(this.el.shadowRoot.querySelectorAll("[data-segmentindex")),s))}function z(t,s){this.popoverEl&&this.isTabbing&&(this.focusedSliceId=s.id,s.coords=e(t.target),s.coords.x=s.coords.x+30,s.coords.y=s.coords.y+30,A(this.popoverEl,s),K(Array.from(this.el.shadowRoot.querySelectorAll("[data-segmentindex")),s))}function C(t){switch(t.key){case"ArrowUp":case"ArrowLeft":t.preventDefault(),this.isTabbing=!0,D.call(this);break;case"ArrowRight":case"ArrowDown":t.preventDefault(),this.isTabbing=!0,B.call(this);break;case"Tab":j.call(this);break;case"Escape":this.popoverEl.open=!1,this.userIsNavigating=!1}}function A(t,s){t.open=!1,s.title&&s.text&&(t.sliceDetails=Object.assign({},s),window.setTimeout((()=>t.open=!0),30))}function B(){const t=n(document.activeElement),s=(this.sliceEls.indexOf(t)+1)%this.sliceEls.length;F.call(this,s)}function D(){if(this.sliceEls){const t=n(document.activeElement);let s=this.sliceEls.indexOf(t);-1===s?s=0:0===s?s=this.sliceEls.length-1:s-=1,F.call(this,s)}}function F(t){this.sliceEls&&this.el&&(this.userIsNavigating=!0,this.componentWrapperEl.tabIndex=-1,this.el.focusable=!1,this.sliceEls.map((t=>{t.tabIndex=-1,t.focusable=!1})),this.sliceEls[t].tabIndex=0,this.sliceEls[t].focusable=!0,this.sliceEls[t].focus(),this.focusedSliceId=this.sliceEls[t].id,window.setTimeout((()=>{this.popoverEl&&(this.popoverEl.open=!0)}),10))}function j(){this.focusedSliceId=void 0,this.sliceEls&&this.sliceEls.map((t=>{t.tabIndex=-1,t.focusable=!1})),this.userIsNavigating=!1,window.setTimeout((()=>{this.componentWrapperEl.tabIndex=0,this.el.focusable=!0,this.popoverEl&&(this.popoverEl.open=!1)}),100)}async function I(t){this.slicesDetails=[];let s=0;const i=Array.from(this.el.children);this.total=i.reduce(((t,s)=>t+parseInt(s.getAttribute("amount")||"0")),0);let e=u[t].colors;"bar3"===t&&2===i.length&&(e=[e[1],e[3]]),i.forEach(((i,n)=>{const a=parseInt(i.getAttribute("amount")||"0"),r=m(a,this.total,!0);let o=n;"bar5"===t&&(o=this.notStartedColor?n:n+1),"bar6"===t&&(o=0);const h={amount:a,perc:r,legend:i.getAttribute("legend"),color:e[o]||l,offset:s,id:`${this.uid}-${n+1}`,title:i.getAttribute("popover-title"),text:i.getAttribute("popover-text"),buttonText:i.getAttribute("popover-button-text"),sliceRef:i,inSmallCluster:!1,index:n};s+=a,this.slicesDetails.push(h)}))}function S(t,s,i){const e=v(s,this.total)-90,n=t/this.total*360;let a=e+n;const r=n>180?"1 1":"0 1",o=n>180?"1 0":"0 0",h=this.chartDetails.size/2,c=this.chartDetails.thickness,d="doughnut"===i?2.25:3;360===n&&(a-=.01);const l=w(h,1,e+1.5,a),u=w(h,c,e+d,a);return`M ${l.x1}, ${l.y1} `+k(1,r,l.x2,l.y2,this.chartDetails.size)+` L ${u.x2}, ${u.y2} `+k(c,o,u.x1,u.y1,this.chartDetails.size)+" z"}function T(){const i=s.formatMessage({id:"chart.instructions",defaultMessage:"Use arrow keys to browse elements, press Tab to exit.",description:"For screen readers only, instructions on how to interact with the chart component"});return t("div",{id:"chart-instructions"},i)}function H(s){const i=this.chartDetails.size+this.chartDetails.padding,e="doughnut"===s;let n=e?this.slicesDetails:function(t,s){let i=[...t].sort(((t,s)=>t.amount===s.amount?0:t.amount>s.amount?-1:1)),e=0;return i.filter((t=>t.amount>0)).forEach(((t,n)=>{const a=i[n===i.length-1?0:n+1],r=m(i[0===n?i.length-1:n-1].amount,s,!0),o=m(a.amount,s,!0),h=0===t.perc?8:5;t.inSmallCluster=t.perc<4&&(r<h||o<h),t.offset=e,e+=t.amount})),i}(this.slicesDetails,this.total);return n=function(t,s,i){const e=s.map((t=>v(t.amount,i)));if(e.some((t=>0!==t&&t<7))){const t=e.map((t=>0==t?t:Math.max(t,7))),n=t.reduce(((t,s)=>t+(s>7&&0!==s?s:0)),0),a=360-t.reduce(((t,s)=>t+(s>7&&0!==s?0:s)),0),r=(n-a)/a,o=t.map((t=>t>7?t-r*t:0==t?0:7));let h=0;s=s.map(((t,s)=>{const e=o[s]/360*i,n=h;return h+=e,Object.assign(Object.assign({},t),{amount:e,offset:n})}))}return s}(0,n,this.total),t("div",{class:"chart-wrapper doughnut-wrapper"},t("svg",{width:i+"px",height:i+"px",id:`graphic-${this.uid}`,class:"doughnut-svg"},t("defs",null,t("filter",{id:"wmHoverDropShadow"},t("feGaussianBlur",{stdDeviation:"3"}),t("feOffset",{result:"offsetblur"}),t("feFlood",{"flood-color":"#333"}),t("feComposite",{operator:"in",in2:"offsetblur"}),t("feMerge",null,t("feMergeNode",null),t("feMergeNode",{in:"SourceGraphic"})))),n.map((t=>O.call(this,t,s))),W.call(this),e?t("text",{class:"value",x:"50%",y:"50%","font-size":"1.5rem","font-weight":"500","text-anchor":"middle","dominant-baseline":"middle"},m(n[0].amount,this.total,!0)+"%"):t("g",{transform:`translate(${this.chartDetails.padding/2}, ${this.chartDetails.padding/2})`,"text-anchor":"middle","dominant-baseline":"middle"},n.map((t=>t.amount>0&&!t.inSmallCluster?E.call(this,t):"")))))}function K(t,s){t.forEach((t=>{t.dataset.segmentindex&&parseInt(t.dataset.segmentindex)!==s.index?t.classList.add("faded"):t.classList.remove("faded")}))}function N(t){t.forEach((t=>{t.classList.remove("faded")}))}function O(s,i){const e=m(s.amount,this.total,!0)+"%";return!isNaN(s.amount)&&t("g",{transform:`translate(${this.chartDetails.padding/2}, ${this.chartDetails.padding/2})`},t("path",{id:s.id,class:"segment doughnut-segment",fill:s.amount?s.color:"transparent",d:S.call(this,s.amount,s.offset,i),onClick:t=>M.call(this,t,s),onFocus:t=>z.call(this,t,s),onKeyDown:t=>$.call(this,t),role:"img","aria-label":`${s.legend}, ${e}`,"data-segmentindex":s.index}))}function W(){return this.isTabbing?t("g",{transform:`translate(${this.chartDetails.padding/2}, ${this.chartDetails.padding/2})`},t("use",{tabindex:-1,id:"kfbg1",xlinkHref:`#${this.focusedSliceId}`}),t("use",{tabindex:-1,id:"kfstroke",xlinkHref:`#${this.focusedSliceId}`}),t("use",{tabindex:-1,id:"kfbg2",xlinkHref:`#${this.focusedSliceId}`})):""}function E(s){const i=v(s.offset+s.amount/2,this.total);let{x:e,y:n}=w(this.chartDetails.size/2,1.4,i-90);return t("text",{class:"value",x:e+"px",y:n+"px","data-segmentindex":s.index},`${s.perc>0?s.perc:"<1"}%`)}function G(s){const i="bar"===s,e=this.el.shadowRoot.querySelectorAll(".value");return e.length>0&&requestAnimationFrame((()=>{let t=[],s=!1;e.forEach((i=>{i.classList.remove("hidden");const e=parseInt(i.dataset.value);if(t.length>0&&0!=e){const n=i.getBoundingClientRect().left-4;t.forEach((t=>{const a=parseInt(t.dataset.value);t.getBoundingClientRect().right>n&&((e<a?i:t).classList.add("hidden"),s=!0)}))}!i.classList.contains("hidden")&&e>0&&t.push(i)})),(this.isBar||this.isDoughnut)&&this.showHiddenValuesMessage(s)})),t("div",{class:"chart-wrapper bar-wrapper"},i?t("div",{class:"single-perc"},m(this.slicesDetails[0].amount,this.total,!0)+"%"):"","bar3"===this.chartType&&this.drawAxis(),t("div",{class:`inner-stacked-bar-wrapper ${f(this.valueFormat)}`},i?"":t("div",{class:"values"},this.slicesDetails.map((t=>this.renderBarText(t,5)))),t("div",{class:"stacked-bar-segments-wrapper"},this.slicesDetails.map((t=>L.call(this,t,5)))),i?J.call(this):""))}function L(s,i){const e=m(s.amount,this.total,!1),n=this.el.shadowRoot.querySelector(".stacked-bar-segments-wrapper"),a=e/100*(n?n.offsetWidth:this.el.offsetWidth)>=i,r=a||0==s.amount?`${e}%`:`${i}px`;let o="";return"percentage"==this.valueFormat?o=`${m(s.amount,this.total,!0)} %`:"amount"==this.valueFormat&&(o=s.amount.toString()),t("div",{class:`segment stacked-bar-segment ${0===m(s.amount,this.total,!1)?"zero":""} ${a?"":"fixed-width"}`,style:{backgroundColor:s.color,width:r},onClick:t=>M.call(this,t,s),onFocus:t=>z.call(this,t,s),onKeyDown:t=>$.call(this,t),"data-segmentindex":s.index},t("span",{class:"sr-only"},`${s.legend} ${o}`))}function R(s){const e=this.slicesDetails.map((t=>t.amount)).reduce(((t,s)=>t>s?t:s)),n=parseInt(getComputedStyle(this.el).getPropertyValue("--labelWidth"),10);let a=(r=this.el.getBoundingClientRect().width-n-48,Math.round(r/function(t){return function(t){let s=80*(t-300)/600+70;return s<70?70:s>150?150:s}(t)}(r)));var r;let o=y(e,a);const h=Math.floor((a*o-e)/o);a-=h,this.el.style.setProperty("--backgroundSize",100/a+"%"),this.el.style.setProperty("--labelWidth",this.labelWidth),"bar7"!==s||this.showBarLegend||this.el.style.setProperty("--labelWidth","0px");const c=[];this.slicesDetails.forEach((i=>{i.legend&&c.push(function(s,i,e){return t("label",{class:`label${"bar7"!==e||i?"":" hidden"}`},s)}(i.legend,this.showBarLegend,s)),c.push(U.call(this,i,o,a,e))}));const d=[];for(let s=1;s<=a;s++){const e=b(i(s,o));d.push(t("div",{class:"tick"},t("span",null,e)))}const l="bar6"===s&&this.showGrid&&this.el.getBoundingClientRect().width>300;return t("div",{class:"chart-wrapper simple-bar-wrapper"},t("div",{class:`chart ${f(this.valueFormat)}`},l&&t("div",{class:"gridlines"}),t("div",{class:"rows"},c)),l&&t("div",{class:"x-axis","aria-hidden":"true"},t("div",{class:"zero"},t("span",null,"0")),d))}function U(s,i,e,n){const a=m(s.amount,"bar6"===this.currentChartType?i*e:n,!1),r=a?a+"%":"1px",o=b(s.amount);let h="amount"===this.valueFormat?o:"";return"bar6"===this.currentChartType&&"percentage"===this.valueFormat?h=s.amount+"%":"bar7"===this.currentChartType&&"percentage"===this.valueFormat&&(h=(0===this.total?"0":m(s.amount,this.total,!0))+"%"),t("div",{class:"bar segment",style:{backgroundColor:s.color,width:r},onClick:t=>M.call(this,t,s),onFocus:t=>z.call(this,t,s),onKeyDown:t=>$.call(this,t),"data-segmentindex":s.index},t("div",{class:"value"},h))}function V(s){if(this.showLegend){const i=this.slicesDetails.reduce(((t,s)=>!!s.inSmallCluster||t),!1);return this.isDoughnut&&this.showHiddenValuesMessage(i),t("div",{class:"legend-wrapper"},t("div",{class:`legend ${s} ${"bar"===this.mode?"--top":"--bottom"}`,"aria-hidden":"true"},this.slicesDetails.map((t=>{const s="amount"==this.printModeFormat?`${t.amount}/${this.total}`:`${m(t.amount,this.total,!0)}%`;if(t.amount||t.legend)return q.call(this,{key:t.legend,color:t.color},s,t)}))),this.isDoughnut&&!this.printMode&&P())}}function q(s,i="",e=null){const n=t=>{e&&(e.coords={x:t.clientX,y:t.clientY},A(this.popoverEl,e),K(Array.from(this.el.shadowRoot.querySelectorAll("[data-segmentindex")),e))};return t("div",{class:"legend-item",onClick:t=>n(t),"data-segmentindex":e?e.index:null},t("div",{class:"legend-color",style:{backgroundColor:s.color}}),t("div",{class:"legend-text"},s.key,i&&t("span",{class:"print-value "+(this.printMode?"force-visible":"")},": ",i)))}function J(){if(this.completionMessage)return t("div",{class:"completion-message"},this.completionMessage)}function P(){return t("div",{class:"hidden-values-warning hidden"},g,t("br",null),p)}export{u as a,R as b,G as c,H as d,T as e,V as f,I as g,C as h,P as i,j,m as k,J as l,q as m,b as n,y as o,N as r}
@@ -1 +0,0 @@
1
- System.register([],(function(){"use strict";return{execute:function(){var n="5.4.0";if(window.navigator.plugins.length>0){console.log("Ripple component library",n)}function o(n){if(n.key=="Tab"){var o=new Event("wmUserIsTabbing");window.dispatchEvent(o);document.querySelector("body").classList.add("wmcl-user-is-tabbing")}if(n.key=="ArrowLeft"||n.key=="ArrowUp"||n.key=="ArrowRight"||n.key=="ArrowDown"){var o=new Event("wmUserIsKeying");window.dispatchEvent(o);document.querySelector("body").classList.add("wmcl-user-is-keying")}}function t(){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")}window.addEventListener("keydown",o);window.addEventListener("mousedown",t);var e=document.createElement("div");e.id="wm-tooltip-container";var i=document.createElement("div");i.id="wm-tooltip";i.classList.add("wm-tooltip");i.setAttribute("popover","manual");i.setAttribute("aria-hidden","true");var r=document.createElement("style");r.textContent="\n.wm-tooltip {\n position: fixed;\n overflow: hidden;\n pointer-events: none;\n line-height: normal;\n font-family: inherit;\n font-size: 0.875rem;\n text-transform: none;\n font-weight: normal;\n background: var(--wmcolor-tooltip-background);\n color: var(--wmcolor-tooltip-text);\n z-index: 999999;\n max-width: var(--wmTooltipMaxWidth, 13.75rem);\n margin-right: 1.5rem;\n padding: 0.375rem;\n transition-property: opacity;\n transition-delay: 0s;\n opacity: 0;\n inset: unset;\n top: 0;\n left: 0;\n transform: translateZ(0);\n will-change: transform;\n transform: translate(var(--wmTooltipLeft), var(--wmTooltipTop));\n border: none;\n}\n\n.wm-tooltip:popover-open {\n opacity: 0;\n}\n\n.wm-tooltip.show {\n transition-delay: 500ms;\n opacity: 1;\n}\n";document.head.appendChild(r);e.appendChild(i);document.querySelector("body").appendChild(e)}}}));
@@ -1 +0,0 @@
1
- import{r as e,c as t,h as r,H as a,g as i}from"./p-568c595f.js";import{t as o,j as n,a as s,k as l,l as p,i as d}from"./p-e995f7f0.js";const c=class{constructor(r){e(this,r),this.wmDatepickerDateSelected=t(this,"wmDatepickerDateSelected",7),this.wmDatepickerInputBlurred=t(this,"wmDatepickerInputBlurred",7),this.openUp=!1,this.popupClicked=!1,this.toggleButtonClicked=!1,this.value="",this.disabled=!1,this.dateFormat="mm/dd/yyyy",this.errorMessage=void 0,this.labelPosition="top",this.label="",this.requiredField=!1,this.preselected=void 0,this.isExpanded=!1}get isDisabled(){return o(this.disabled)}get calendarDate(){let e=n(new Date);const t={"mm/dd/yyyy":"US","dd/mm/yyyy":"INT","yyyy/mm/dd":"ISO"};return this.value&&t[this.dateFormat]&&this.isValidIsoInternal(this.reformatDateInternal(t[this.dateFormat],"ISO",this.value))?e=this.reformatDateInternal(t[this.dateFormat],"ISO",this.value):this.preselected&&(e=this.preselected),e}handleDisabledChange(){s(this.el,this.isDisabled)}updateValue(){this.inputEl.value=this.value?this.value:""}announceError(){this.errorMessage&&setTimeout((()=>this.announce(this.errorMessage)),100)}togglePopup(){this.isExpanded?this.closePopup():this.openPopup(),this.toggleButtonClicked=!0}closePopup(e=!1){this.isExpanded=!1,this.calEl.view="day",this.calEl.view="day",this.popupEl.classList.remove("open"),window.setTimeout((()=>{this.popupEl.style.visibility="hidden"}),250),e&&this.toggleEl.focus()}openPopup(){this.openUp=l(this.el,this.popupEl.clientHeight,this.labelWrapperEl.clientHeight),p(this.el,336)?(this.popupEl.style.left="0",this.popupEl.style.right="auto"):(this.popupEl.style.right="0",this.popupEl.style.left="auto"),this.popupEl.style.visibility="visible",window.requestAnimationFrame((()=>{this.popupEl.classList.add("open")})),this.isExpanded=!0,this.calEl.focusDate=this.calendarDate,this.calEl.startDate=this.calendarDate,this.calEl.focusCell()}handleInput(e){this.value=e.target.value}handleInputBlur(){this.dpWrapperEl.classList.remove("focus"),this.wmDatepickerInputBlurred.emit()}handleInputFocus(){this.dpWrapperEl.classList.add("focus")}handleInputChange(){const e=new CustomEvent("change");this.el.dispatchEvent(e)}handleKey(e){"Escape"===e.key&&(e.preventDefault(),e.stopPropagation(),this.closePopup(!0))}blurHandler(){this.popupClicked||this.toggleButtonClicked||!this.isExpanded||this.closePopup(),this.popupClicked=!1,this.toggleButtonClicked=!1}handleBlurOnWindow(){this.isExpanded&&this.closePopup()}handleCellTriggered(e){let t=e.detail.cell,r=t.getAttribute("data-year")+"-"+t.getAttribute("data-month")+"-"+t.textContent.padStart(2,"0");this.wmDatepickerDateSelected.emit({date:r});const a=new CustomEvent("input");this.el.dispatchEvent(a);const i=new CustomEvent("change");this.el.dispatchEvent(i),this.closePopup(!0)}async reformatDate(e,t,r){return this.reformatDateInternal(e,t,r)}reformatDateInternal(e,t,r){if(!r)return"";if(!/^(\d{1}|\d{2}|\d{4})[\-\.\/]\d{1,2}[\-\.\/](\d{1}|\d{2}|\d{4})$/.test(r))return r;{const a=r.replace(/[\-\.]/gi,"/").split("/");switch(t){case"US":return a[1].padStart(2,"0")+"/"+a[2].padStart(2,"0")+"/"+a[0].padStart(4,"20");case"INT":return a[2].padStart(2,"0")+"/"+a[1].padStart(2,"0")+"/"+a[0].padStart(4,"20");case"ISO":if("US"===e)return a[2].padStart(4,"20")+"-"+a[0].padStart(2,"0")+"-"+a[1].padStart(2,"0");if("INT"===e)return a[2].padStart(4,"20")+"-"+a[1].padStart(2,"0")+"-"+a[0].padStart(2,"0");if("ISO"===e)return a[0].padStart(4,"20")+"-"+a[1].padStart(2,"0")+"-"+a[2].padStart(2,"0");default:return a.join("/")}}}async isValidIso(e){return this.isValidIsoInternal(e)}isValidIsoInternal(e){if(e&&/^\d\d\d\d[-]\d\d[-]\d\d$/.test(e)){const t=e.split("-"),r=parseInt(t[2],10),a=parseInt(t[1],10),i=parseInt(t[0],10);if(i<1e3||i>3e3||0==a||a>12)return!1;let o=[31,28,31,30,31,30,31,31,30,31,30,31];return(i%400==0||i%100!=0&&i%4==0)&&(o[1]=29),r>0&&r<=o[a-1]}return!1}componentWillLoad(){""===this.label&&console.error("You must include a label prop for the datepicker input (for accessibility reasons), even if the label position is none."),s(this.el,this.isDisabled)}componentDidLoad(){this.calEl.addEventListener("click",(()=>{this.popupClicked=!0}))}announce(e){this.liveRegionEl.textContent===e&&(e+=" "),this.liveRegionEl.textContent=e}render(){return r(a,{"aria-busy":"false",class:this.errorMessage?"invalid":""},r("div",{ref:e=>this.dpWrapperEl=e,class:`wrapper label-${this.labelPosition} ${this.errorMessage?"invalid":""}`},r("div",{class:"label-wrapper",ref:e=>this.labelWrapperEl=e},"none"!==this.labelPosition&&r("label",{id:"datepickerLabel",htmlFor:"date-input",class:"label",title:`${this.label} (${this.dateFormat})`},this.label,this.requiredField&&r("span",{"aria-hidden":"true",class:"required"},"*"))),r("div",null,r("div",{class:"single-wrapper input"},r("input",{disabled:this.isDisabled,type:"text",id:"single-date-input",class:"date-input",name:"date",placeholder:this.dateFormat,value:this.value,onFocus:()=>this.handleInputFocus(),onInput:e=>this.handleInput(e),onBlur:()=>this.handleInputBlur(),onChange:()=>this.handleInputChange(),ref:e=>this.inputEl=e,"aria-describedby":"error","aria-label":this.label,"aria-required":this.requiredField?"true":null}),r("div",{class:"container",id:"wm-container"},r("button",{disabled:this.disabled,onClick:this.togglePopup.bind(this),"aria-describedby":"date-input",ref:e=>this.toggleEl=e,"aria-expanded":`${this.isExpanded}`,class:"toggle",id:"toggle"},r("span",{class:"calendar",title:d.formatMessage({id:"date.calendarView",defaultMessage:"Calendar View",description:"Calendar button"})})),r("div",{class:`popup-wrapper ${this.calEl&&this.calEl.view}-view ${this.openUp?"expand-upwards":""}`,id:"popup-wrapper",ref:e=>this.popupEl=e,onClick:()=>this.popupClicked=!0},r("div",{tabIndex:0,onFocus:()=>this.calEl.focusLastFocusable()}),r("priv-calendar",{ref:e=>this.calEl=e,startDate:this.calendarDate,focusDate:this.calendarDate,class:"inside"}),r("div",{tabIndex:0,onFocus:()=>this.calEl.focusFirstFocusable()})),r("div",{id:"live-region","aria-live":"polite","aria-relevant":"text",class:"sr-only"}),r("div",{id:"month-title",class:"sr-only"},d.formatMessage({id:"date.selectMonth",defaultMessage:"Activate to select a month.",description:"Calendar button"})),r("div",{id:"year-title",class:"sr-only"},d.formatMessage({id:"date.selectYear",defaultMessage:"Activate to select a year.",description:"Calendar button"})))),r("div",{id:"error",class:"error"},this.errorMessage),r("div",{ref:e=>this.liveRegionEl=e,class:"sr-only","aria-live":"polite","aria-atomic":"true"}))))}static get delegatesFocus(){return!0}get el(){return i(this)}static get watchers(){return{disabled:["handleDisabledChange"],value:["updateValue"],errorMessage:["announceError"]}}};c.style=':host{--wmcolor-datepicker-background:var(--wmcolor-background);--wmcolor-datepicker-day-background-hover:var(--wmcolor-interactive-background-hover);--wmcolor-datepicker-day-background-selected:var(--wmcolor-interactive);--wmcolor-datepicker-day-text-outside:var(--wmcolor-interactive-disabled);--wmcolor-datepicker-day-text-selected:var(--wmcolor-interactive-text-selected);--wmcolor-datepicker-day-text:var(--wmcolor-text);--wmcolor-datepicker-input-background-disabled:var(--wmcolor-input-background-disabled);--wmcolor-datepicker-input-background:var(--wmcolor-input-background);--wmcolor-datepicker-input-border:var(--wmcolor-input-border);--wmcolor-datepicker-input-text-disabled:var(--wmcolor-input-text-disabled);--wmcolor-datepicker-input-text:var(--wmcolor-input-text);--wmcolor-datepicker-month-background-hover:var(--wmcolor-interactive-background-hover);--wmcolor-datepicker-month-background-selected:var(--wmcolor-interactive);--wmcolor-datepicker-month-background:var(--wmcolor-text);--wmcolor-datepicker-month-border:var(--wmcolor-border-light);--wmcolor-datepicker-month-text-selected:var(--wmcolor-text-ondark);--wmcolor-datepicker-month-text:var(--wmcolor-interactive);--wmcolor-datepicker-navigation-background-hover:var(--wmcolor-button-background-navigational-hover);--wmcolor-datepicker-navigation-background:var(--wmcolor-button-background-navigational);--wmcolor-datepicker-navigation-text:var(--wmcolor-button-icon-navigational);--wmcolor-datepicker-selector-background:var(--wmcolor-button-background-secondary);--wmcolor-datepicker-selector-border:var(--wmcolor-button-border-secondary);--wmcolor-datepicker-selector-text:var(--wmcolor-button-text-secondary);--wmcolor-datepicker-toggle-background-disabled:var(--wmcolor-input-background-disabled);--wmcolor-datepicker-toggle-background-hover:var(--wmcolor-interactive-background-hover);--wmcolor-datepicker-toggle-background:var(--wmcolor-input-background);--wmcolor-datepicker-toggle-icon-disabled:var(--wmcolor-interactive-disabled);--wmcolor-datepicker-toggle-icon:var(--wmcolor-interactive);--wmcolor-datepicker-weekdays-background:var(--wmcolor-table-header-background);--wmcolor-datepicker-weekdays-text:var(--wmcolor-text);font-family:inherit}:host *{-webkit-box-sizing:border-box;box-sizing:border-box}:host .wrapper{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;font-size:0.875rem}:host .wrapper .label{display:block;line-height:normal;font-weight:600;white-space:nowrap;margin-bottom:0.25rem}:host .wrapper .label .required{color:var(--wmcolor-text-required)}:host .wrapper.label-left{-ms-flex-direction:row;flex-direction:row}:host .wrapper.label-left .label-wrapper{line-height:2.5rem}:host .wrapper.label-left .label-wrapper .label{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;min-height:2.5rem;white-space:normal;margin-bottom:0;margin-right:0.75rem}:host .wrapper.label-none label{position:absolute !important;width:1px !important;height:1px !important;padding:0 !important;border:0 !important;overflow:hidden !important;clip:rect(0, 0, 0, 0) !important;-webkit-clip-path:inset(50%) !important;clip-path:inset(50%) !important;white-space:nowrap !important;margin:-1px !important}:host .wrapper.invalid .label{color:var(--wmcolor-text-error)}:host .wrapper.invalid .label:after{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f026";margin-left:0.3125rem}[dir=RTL] :host .wrapper.invalid .label:after{margin-left:0;margin-right:0.3125rem}:host .wrapper.rtl.label-left .label{margin-right:0;margin-left:0.75rem}:host .wrapper{position:relative}:host .wrapper .single-wrapper,:host .wrapper .range-wrapper{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:justify;justify-content:space-between;position:relative}:host .wrapper .date-input{border-radius:3px;color:var(--wmcolor-datepicker-input-text);font-size:0.875rem;padding:0.625rem 0.9375rem 0.5rem;min-width:0;-ms-flex:1;flex:1;margin:0;background-color:var(--wmcolor-datepicker-input-background)}:host .wrapper .date-input:disabled{background-color:var(--wmcolor-datepicker-input-background-disabled);color:var(--wmcolor-datepicker-input-text-disabled)}:host .wrapper .date-input:focus{outline:none}:host .wrapper .input{height:2.5rem;border:1px solid var(--wmcolor-datepicker-input-border);-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;max-width:236px;}:host .wrapper #single-date-input{height:100%;border:none;border-radius:3px;-webkit-margin-end:3px;margin-inline-end:3px}:host .wrapper .range-wrapper{max-width:257px;display:grid;grid-template-rows:minmax(21px, 1fr) 38px;grid-template-columns:120px 17px 120px;grid-template-areas:"start-label-wrapper . end-label-wrapper" "start-date-input hyphen end-date-input"}:host .wrapper .range-wrapper #start-label-wrapper{grid-area:start-label-wrapper}:host .wrapper .range-wrapper #end-label-wrapper{grid-area:end-label-wrapper}:host .wrapper .range-wrapper #start-date-input{grid-area:start-date-input}:host .wrapper .range-wrapper #hyphen{grid-area:hyphen}:host .wrapper .range-wrapper #end-date-input{grid-area:end-date-input}:host .wrapper .range-wrapper .label{text-wrap:wrap}:host .wrapper .range-wrapper.cal{max-width:305px;-webkit-column-gap:4px;-moz-column-gap:4px;column-gap:4px;grid-template-columns:120px 17px 120px 36px;grid-template-areas:"start-label-wrapper . end-label-wrapper ." "start-date-input hyphen end-date-input toggle-wrapper"}:host .wrapper .range-wrapper.cal #toggle-wrapper{grid-area:toggle-wrapper}:host .wrapper #start-date-input,:host .wrapper #end-date-input{max-width:120px}:host .wrapper #start-date-input:focus,:host .wrapper #end-date-input:focus{outline:2px solid var(--wmcolor-input-border-focus);border-color:var(--wmcolor-input-border-focus)}:host .wrapper.invalid .input,:host .wrapper .date-input.invalid{-webkit-box-shadow:0 0 0 1px var(--wmcolor-input-border-error);-moz-box-shadow:0 0 0 1px var(--wmcolor-input-border-error);box-shadow:0 0 0 1px var(--wmcolor-input-border-error);border-color:var(--wmcolor-input-border-error)}:host .wrapper .error{display:block;font-style:italic;color:var(--wmcolor-text-error);font-size:0.875rem;margin-bottom:4px;top:100%;left:0}:host .wrapper .error:not(:empty){margin-top:0.25rem}:host .wrapper.focus #single-date-input{outline:2px solid var(--wmcolor-input-border-focus);border-color:var(--wmcolor-input-border-focus)}.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{c as wm_datepicker}
@@ -1 +0,0 @@
1
- var __awaiter=this&&this.__awaiter||function(e,t,r,o){function n(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,a){function p(e){try{s(o.next(e))}catch(e){a(e)}}function i(e){try{s(o["throw"](e))}catch(e){a(e)}}function s(e){e.done?r(e.value):n(e.value).then(p,i)}s((o=o.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var r={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},o,n,a,p;return p={next:i(0),throw:i(1),return:i(2)},typeof Symbol==="function"&&(p[Symbol.iterator]=function(){return this}),p;function i(e){return function(t){return s([e,t])}}function s(i){if(o)throw new TypeError("Generator is already executing.");while(p&&(p=0,i[0]&&(r=0)),r)try{if(o=1,n&&(a=i[0]&2?n["return"]:i[0]?n["throw"]||((a=n["return"])&&a.call(n),0):n.next)&&!(a=a.call(n,i[1])).done)return a;if(n=0,a)i=[i[0]&2,a.value];switch(i[0]){case 0:case 1:a=i;break;case 4:r.label++;return{value:i[1],done:false};case 5:r.label++;n=i[1];i=[0];continue;case 7:i=r.ops.pop();r.trys.pop();continue;default:if(!(a=r.trys,a=a.length>0&&a[a.length-1])&&(i[0]===6||i[0]===2)){r=0;continue}if(i[0]===3&&(!a||i[1]>a[0]&&i[1]<a[3])){r.label=i[1];break}if(i[0]===6&&r.label<a[1]){r.label=a[1];a=i;break}if(a&&r.label<a[2]){r.label=a[2];r.ops.push(i);break}if(a[2])r.ops.pop();r.trys.pop();continue}i=t.call(e,r)}catch(e){i=[6,e];n=0}finally{o=a=0}if(i[0]&5)throw i[1];return{value:i[0]?i[1]:void 0,done:true}}};System.register(["./p-ab8d78cc.system.js","./p-34b5830f.system.js","./p-97aaa344.system.js","./p-1ac66a15.system.js"],(function(e){"use strict";var t,r,o,n,a,p,i,s,l,c,h,m,d,b,w,u,f,g,x,v;return{setters:[function(e){t=e.r;r=e.f;o=e.h;n=e.H;a=e.g},function(e){p=e.g;i=e.d},function(e){s=e.a;l=e.h;c=e.g;h=e.r;m=e.b;d=e.c;b=e.d;w=e.e;u=e.f;f=e.i;g=e.j;x=e.k},function(e){v=e.c}],execute:function(){var k=":host{--wmcolor-chart-label-text-negative:var(--wmcolor-text-negative);--wmcolor-chart-label-text-positive:var(--wmcolor-text-positive);--wmcolor-chart-label-text:var(--wmcolor-text);--wmcolor-chart-subinfo-text:var(--wmcolor-text);--wmcolor-chart-value-text:var(--wmcolor-text);display:block}:host .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;outline:none;}:host .component-wrapper:focus-visible{outline:3px solid var(--wmcolor-interactive-focus);outline-offset:2px}:host .component-wrapper .label{display:block;margin:0;padding-bottom:0.25rem;font-weight:600;position:relative}:host .component-wrapper .label .subinfo{display:block;font-weight:normal;font-style:italic;bottom:0.25rem;width:100%;color:var(--wmcolor-chart-subinfo-text)}:host .component-wrapper .label.custom-width{width:var(--custom-label-width)}:host .component-wrapper .label.--none{display:none}:host .component-wrapper .doughnut-svg,:host .component-wrapper .inner-stacked-bar-wrapper{overflow:visible}:host .component-wrapper .bar-wrapper{-ms-flex-positive:1;flex-grow:1;width:100%}:host .component-wrapper .bar-wrapper .inner-stacked-bar-wrapper{width:100%}:host .component-wrapper .bar-wrapper .inner-stacked-bar-wrapper .values{display:-ms-flexbox;display:flex;gap:2px;margin-bottom:8px}:host .component-wrapper .bar-wrapper .inner-stacked-bar-wrapper .stacked-bar-segments-wrapper{display:-ms-flexbox;display:flex;gap:2px}:host .component-wrapper .bar-wrapper .inner-stacked-bar-wrapper .stacked-bar-segments-wrapper .stacked-bar-segment{height:30px;cursor:pointer}:host .component-wrapper .segment{print-color-adjust:exact;-webkit-print-color-adjust:exact}:host .component-wrapper .segment.fixed-width{-ms-flex-negative:0;flex-shrink:0}:host .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{cursor:pointer}:host .component-wrapper .value-wrapper{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center}:host .component-wrapper .value-wrapper .fixed-width{-ms-flex-negative:0;flex-shrink:0}:host .component-wrapper .value-wrapper .value.hidden{visibility:hidden}:host .component-wrapper .faded{opacity:0.3}:host .component-wrapper path:active,:host .component-wrapper path:hover,:host .component-wrapper path:focus,:host .component-wrapper .stacked-bar-segment:active,:host .component-wrapper .stacked-bar-segment:hover,:host .component-wrapper .stacked-bar-segment:focus{outline:none}:host .component-wrapper .stacked-bar-segment:active.stacked-bar-segment:not(:focus-visible),:host .component-wrapper .stacked-bar-segment:hover.stacked-bar-segment:not(:focus-visible),:host .component-wrapper .stacked-bar-segment:focus.stacked-bar-segment:not(:focus-visible){-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:not(:focus-visible),:host .component-wrapper path:hover.doughnut-segment:not(:focus-visible),:host .component-wrapper path:focus.doughnut-segment:not(:focus-visible),:host .component-wrapper .stacked-bar-segment:active.doughnut-segment:not(:focus-visible),:host .component-wrapper .stacked-bar-segment:hover.doughnut-segment:not(:focus-visible),:host .component-wrapper .stacked-bar-segment:focus.doughnut-segment:not(:focus-visible){-webkit-filter:url(#wmHoverDropShadow);filter:url(#wmHoverDropShadow)}:host .component-wrapper path::-moz-focus-inner,:host .component-wrapper .stacked-bar-segment::-moz-focus-inner{border:0;outline:none}:host .component-wrapper .stacked-bar-segment:focus-visible{outline:3px solid var(--wmcolor-interactive-focus);outline-offset:2px;-webkit-box-shadow:0 0 0 7px white;box-shadow:0 0 0 7px white;z-index:1}:host .component-wrapper #kfbg1{stroke:white;stroke-width:10px}:host .component-wrapper #kfstroke{stroke:var(--wmcolor-interactive-focus);stroke-width:6px}:host .component-wrapper #kfbg2{stroke:white;stroke-width:2px}:host .component-wrapper.doughnut{width:300px}:host .component-wrapper.doughnut1 label,:host .component-wrapper.doughnut1 .label-text,:host .component-wrapper.doughnut2 label,:host .component-wrapper.doughnut2 .label-text,:host .component-wrapper.doughnut2b label,:host .component-wrapper.doughnut2b .label-text,:host .component-wrapper.doughnut3 label,:host .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.doughnut{-ms-flex-align:center;align-items:center}:host .component-wrapper.doughnut label{text-align:center;width:100%;padding-bottom:1.5rem}:host .component-wrapper.doughnut label .subinfo{position:absolute}:host .component-wrapper.doughnut .completion-message{padding-top:0.625rem}:host .component-wrapper.bar{-ms-flex-align:start;align-items:flex-start}:host .component-wrapper.bar label{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}:host .component-wrapper.bar label .subinfo{position:initial}:host .component-wrapper.bar .chart-wrapper{display:-ms-flexbox;display:flex}:host .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.bar .chart-wrapper .inner-stacked-bar-wrapper{-ms-flex:1;flex:1}:host .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.bar{-ms-flex-direction:row;flex-direction:row}:host .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.bar .bar-wrapper{-ms-flex-direction:row-reverse;flex-direction:row-reverse}:host .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,:host .component-wrapper.bar2b,:host .component-wrapper.bar3,:host .component-wrapper.bar4,:host .component-wrapper.bar5{-ms-flex-align:start;align-items:flex-start}:host .component-wrapper.bar2b .inner-stacked-bar-wrapper,:host .component-wrapper.bar4 .inner-stacked-bar-wrapper,:host .component-wrapper.bar5 .inner-stacked-bar-wrapper{height:30px;margin-bottom:0}:host .component-wrapper.bar2b .inner-stacked-bar-wrapper.show-values,:host .component-wrapper.bar4 .inner-stacked-bar-wrapper.show-values,:host .component-wrapper.bar5 .inner-stacked-bar-wrapper.show-values{height:60px;margin-top:0}:host .component-wrapper.bar3 .chart-wrapper{position:relative;height:100px}:host .component-wrapper.bar3 .chart-wrapper .inner-stacked-bar-wrapper{position:absolute;top:35px;left:0;right:0;bottom:0;height:30px}:host .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{stroke:var(--wmcolor-chart-gridline);stroke-width:1px}:host .component-wrapper.bar3 .chart-wrapper .axis text{-webkit-transform:translate(4px, 24px);transform:translate(4px, 24px);text-anchor:middle}:host .component-wrapper.bar3 .hidden-values-warning{margin-top:1.25rem}:host .component-wrapper.bar6,:host .component-wrapper.bar7{--chartPadding:48px;-ms-flex-align:start;align-items:flex-start}:host .component-wrapper.bar6 .chart-wrapper,:host .component-wrapper.bar7 .chart-wrapper{width:100%}:host .component-wrapper.bar6 .chart,:host .component-wrapper.bar7 .chart{position:relative;padding-right:var(--chartPadding)}:host .component-wrapper.bar6 .gridlines,:host .component-wrapper.bar7 .gridlines{position:absolute;left:var(--labelWidth);right:var(--chartPadding);top:0;bottom:0;background-image:linear-gradient(90deg, var(--wmcolor-chart-gridline) 1px, transparent 1px);background-position:-1px;border-left:1px solid var(--wmcolor-chart-gridline);border-bottom:1px solid var(--wmcolor-chart-gridline);background-size:var(--backgroundSize)}:host .component-wrapper.bar6 .rows,:host .component-wrapper.bar7 .rows{display:grid;grid-template-columns:var(--labelWidth) auto;grid-auto-rows:minmax(30px, 1fr);-ms-flex-align:center;align-items:center;position:relative;z-index:1}:host .component-wrapper.bar6 .rows .label,:host .component-wrapper.bar7 .rows .label{font-weight:400;padding:0 0.75rem 0 0;text-align:right;margin:0.75rem 0}:host .component-wrapper.bar6 .rows .label.hidden,:host .component-wrapper.bar7 .rows .label.hidden{visibility:hidden;white-space:nowrap}:host .component-wrapper.bar6 .bar,:host .component-wrapper.bar7 .bar{height:30px;position:relative}:host .component-wrapper.bar6 .bar .value,:host .component-wrapper.bar7 .bar .value{position:absolute;top:50%;right:-0.5rem;-webkit-transform:translate(100%, -50%);transform:translate(100%, -50%)}:host .component-wrapper.bar6 .x-axis,:host .component-wrapper.bar7 .x-axis{margin-left:var(--labelWidth);margin-right:var(--chartPadding);display:-ms-flexbox;display:flex;postion:relative}:host .component-wrapper.bar6 .tick,:host .component-wrapper.bar7 .tick{-ms-flex:1;flex:1;text-align:right}:host .component-wrapper.bar6 .tick span,:host .component-wrapper.bar7 .tick span{-webkit-transform:translateX(50%);transform:translateX(50%);display:inline-block}:host .component-wrapper.bar6 .zero,:host .component-wrapper.bar7 .zero{position:absolute;-webkit-transform:translateX(-50%);transform:translateX(-50%)}:host .component-wrapper.bar6 .bar:active,:host .component-wrapper.bar6 .bar:hover,:host .component-wrapper.bar6 .bar:focus,:host .component-wrapper.bar7 .bar:active,:host .component-wrapper.bar7 .bar:hover,:host .component-wrapper.bar7 .bar:focus{outline:none}:host .component-wrapper.bar6 .bar:active.bar:not(:focus-visible),:host .component-wrapper.bar6 .bar:hover.bar:not(:focus-visible),:host .component-wrapper.bar6 .bar:focus.bar:not(:focus-visible),:host .component-wrapper.bar7 .bar:active.bar:not(:focus-visible),:host .component-wrapper.bar7 .bar:hover.bar:not(:focus-visible),:host .component-wrapper.bar7 .bar:focus.bar:not(:focus-visible){-webkit-box-shadow:0px 0px 6px #333;-moz-box-shadow:0px 0px 6px #333;box-shadow:0px 0px 6px #333}:host .component-wrapper.bar6 .bar:focus-visible,:host .component-wrapper.bar7 .bar:focus-visible{outline:3px solid var(--wmcolor-interactive-focus);outline-offset:2px;-webkit-box-shadow:0 0 0 7px white;box-shadow:0 0 0 7px white;z-index:1}:host .component-wrapper.left-label{-ms-flex-direction:row;flex-direction:row}:host .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 .component-wrapper .hidden-values-warning{font-size:0.75rem;font-style:italic;max-width:100%}:host .component-wrapper .hidden-values-warning.hidden{display:none}@media print{:host .component-wrapper .hidden-values-warning{display:none}}:host #chart-instructions{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 .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{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.bar6{display:none}:host .component-wrapper .legend-wrapper .legend.--top{margin-top:-0.75rem}:host .component-wrapper .legend-wrapper .legend.--top .legend-item{padding-top:0.75rem}:host .component-wrapper .legend-wrapper .legend.--top .legend-color{top:0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom{margin-bottom:-0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom .legend-item{padding-bottom:0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom .legend-color{top:-0.75rem}:host .component-wrapper .legend-wrapper .legend .legend-item{position:relative}:host .component-wrapper .legend-wrapper .legend .legend-item.faded{opacity:0.3}:host .component-wrapper .legend-wrapper .legend .legend-item:not(:last-of-type){padding-right:1.25rem}:host .component-wrapper .legend-wrapper .legend .legend-text{font-size:0.875rem;padding-left:1rem;line-height:1}:host .component-wrapper .legend-wrapper .legend .legend-color{position:absolute;left:0;bottom:0;margin:auto;width:0.6875rem;height:0.6875rem;print-color-adjust:exact;-webkit-print-color-adjust:exact}:host .component-wrapper .legend-wrapper .legend .print-value{display:none}:host .component-wrapper .legend-wrapper .legend .print-value.force-visible{display:unset}@media print{:host .component-wrapper .legend-wrapper .legend .print-value{display:unset}}:host .component-wrapper .legend-wrapper .legend.bar3{padding-bottom:1.25rem}";var y=e("wm_chart",function(){function e(e){var o=this;t(this,e);this.uid=p();this.slicesDetails=[];this.debouncedSliceUpdate=i((function(){return __awaiter(o,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return[4,c.call(this,this.currentChartType)];case 1:e.sent();r(this.el);return[2]}}))}))}),100);this.chartType="doughnut1";this.label=undefined;this.labelWidth="150px";this.subinfo=undefined;this.valueFormat="none";this.showGrid=true;this.showLegend=true;this.showBarLegend=false;this.notStartedColor=false;this.printMode=false;this.printModeFormat="amount";this.labelPosition="top";this.isTabbing=false;this.userIsNavigating=false;this.focusedSliceId=undefined}Object.defineProperty(e.prototype,"popoverEl",{get:function(){return this.el.shadowRoot.querySelector("priv-chart-popover")},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"sliceEls",{get:function(){return Array.from(this.el.shadowRoot.querySelectorAll(".segment"))},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"currentChartType",{get:function(){var e=this.chartType;if(this.chartType==="doughnut2"&&this.el.children.length>3){e="doughnut2b"}else if(this.chartType==="bar2"&&this.el.children.length>4){e="bar2b"}return e},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"chartDetails",{get:function(){return s[this.currentChartType]},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"ariaLabelText",{get:function(){var e="".concat(this.label);if(this.subinfo){e+=" ".concat(this.subinfo)}return e},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"isDoughnut",{get:function(){return this.chartDetails.category==="doughnut"},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"isStackedBar",{get:function(){return this.chartDetails.category==="stackedBar"},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"isSimpleBar",{get:function(){return this.chartDetails.category==="simpleBar"},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"isBar",{get:function(){return this.isStackedBar||this.isSimpleBar},enumerable:false,configurable:true});e.prototype.toggleTabbingOn=function(){this.isTabbing=true};e.prototype.toggleTabbingOff=function(){this.isTabbing=false};e.prototype.handleKeydown=function(e){l.call(this,e)};e.prototype.showHiddenValuesMessage=function(e){var t=this;var r=this.el.shadowRoot.querySelector(".hidden-values-warning");if(r){e?r.classList.remove("hidden"):r.classList.add("hidden")}else{requestAnimationFrame((function(){return t.showHiddenValuesMessage(e)}))}};e.prototype.componentWillLoad=function(){return __awaiter(this,void 0,void 0,(function(){var e;var t=this;return __generator(this,(function(o){switch(o.label){case 0: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.")}return[4,c.call(this,this.currentChartType)];case 1:o.sent();if(!this.isDoughnut){e=new ResizeObserver((function(){r(t.el)}));e.observe(this.el)}return[2]}}))}))};e.prototype.handleSliceUpdate=function(){this.debouncedSliceUpdate()};e.prototype.handlePopoverOpenChanged=function(e){var t=e.detail;if(!t){var r=Array.from(this.el.shadowRoot.querySelectorAll("[data-segmentindex]"));h(r)}};e.prototype.renderBarText=function(e,t){var r;if(this.valueFormat==="percentage"){r=e.perc===0&&e.amount>0?"<1%":"".concat(e.perc,"%")}else if(this.valueFormat==="amount"){r=e.amount}var n=x(e.amount,this.total,false);var a=this.el.offsetWidth;var p=n/100*a>=t;var i=p||e.amount==0?"".concat(n,"%"):"".concat(t,"px");return o("div",{class:"value-wrapper ".concat(p?"":"fixed-width"),style:{width:i}},o("span",{class:"value","data-value":e.amount,"data-segmentindex":e.index},e.amount>0&&r))};e.prototype.drawAxis=function(){if(this.currentChartType==="bar3"){return o("svg",{class:"axis"},o("line",{x1:"0",x2:"100%",y1:"0",y2:"0"}),o("line",{x1:"0",x2:"0",y1:"0",y2:"-85px"}),o("line",{class:"tick",x1:"0.5",x2:"0.5",y1:"0",y2:"6"}),o("text",{x:"0.5",y:"-6"},"0%"),o("line",{class:"tick",x1:"100%",x2:"100%",y1:"0",y2:"6"}),o("text",{x:"100%",y:"-6"},"100%"))}};e.prototype.renderChart=function(){if(this.isSimpleBar){return m.call(this,this.currentChartType)}else if(this.isStackedBar&&this.total>0){return d.call(this,this.currentChartType)}else if(this.isDoughnut&&this.total>0){return b.call(this,this.currentChartType)}};e.prototype.render=function(){var e=this;return o(n,{onBlur:function(){return g.call(e)}},o("div",{ref:function(t){return e.componentWrapperEl=t},class:"component-wrapper ".concat(this.currentChartType," ").concat(this.isTabbing&&!this.userIsNavigating?"user-is-tabbing":""," ").concat(this.labelPosition==="left"&&this.currentChartType==="bar4"?"left-label":""),role:"application","aria-label":this.ariaLabelText,tabindex:0,"aria-roledescription":v.interactiveChart,"aria-describedby":"chart-instructions"},o("label",{id:"label-".concat(this.uid),class:"label --".concat(this.labelPosition),htmlFor:"graphic-".concat(this.uid)},o("span",{class:"label-text"},this.label),this.subinfo?o("span",{class:"subinfo"},this.subinfo):""),this.isBar&&u.call(this,this.currentChartType),this.renderChart(),this.isDoughnut&&u.call(this,this.currentChartType),o("priv-chart-popover",{class:this.isTabbing?"user-is-tabbing":"",onIntChartPopoverOpenChanged:function(t){return e.handlePopoverOpenChanged(t)}}),this.isBar&&!this.printMode&&f()),w())};Object.defineProperty(e,"delegatesFocus",{get:function(){return true},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"el",{get:function(){return a(this)},enumerable:false,configurable:true});return e}());y.style=k}}}));
@@ -1 +0,0 @@
1
- import{r as e,f as t,h as r,H as o,g as a}from"./p-568c595f.js";import{g as n,d as p}from"./p-e995f7f0.js";import{a as s,h as i,g as l,r as h,b as c,c as m,d,e as w,f as b,i as g,j as x,k as u}from"./p-0f0466c6.js";import{c as f}from"./p-d79fdf0b.js";const v=class{constructor(r){e(this,r),this.uid=n(),this.slicesDetails=[],this.debouncedSliceUpdate=p((async()=>{await l.call(this,this.currentChartType),t(this.el)}),100),this.chartType="doughnut1",this.label=void 0,this.labelWidth="150px",this.subinfo=void 0,this.valueFormat="none",this.showGrid=!0,this.showLegend=!0,this.showBarLegend=!1,this.notStartedColor=!1,this.printMode=!1,this.printModeFormat="amount",this.labelPosition="top",this.isTabbing=!1,this.userIsNavigating=!1,this.focusedSliceId=void 0}get popoverEl(){return this.el.shadowRoot.querySelector("priv-chart-popover")}get sliceEls(){return Array.from(this.el.shadowRoot.querySelectorAll(".segment"))}get currentChartType(){let e=this.chartType;return"doughnut2"===this.chartType&&this.el.children.length>3?e="doughnut2b":"bar2"===this.chartType&&this.el.children.length>4&&(e="bar2b"),e}get chartDetails(){return s[this.currentChartType]}get ariaLabelText(){let e=`${this.label}`;return this.subinfo&&(e+=` ${this.subinfo}`),e}get isDoughnut(){return"doughnut"===this.chartDetails.category}get isStackedBar(){return"stackedBar"===this.chartDetails.category}get isSimpleBar(){return"simpleBar"===this.chartDetails.category}get isBar(){return this.isStackedBar||this.isSimpleBar}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}handleKeydown(e){i.call(this,e)}showHiddenValuesMessage(e){const t=this.el.shadowRoot.querySelector(".hidden-values-warning");t?e?t.classList.remove("hidden"):t.classList.add("hidden"):requestAnimationFrame((()=>this.showHiddenValuesMessage(e)))}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.");await l.call(this,this.currentChartType),this.isDoughnut||new ResizeObserver((()=>{t(this.el)})).observe(this.el)}handleSliceUpdate(){this.debouncedSliceUpdate()}handlePopoverOpenChanged(e){if(!e.detail){const e=Array.from(this.el.shadowRoot.querySelectorAll("[data-segmentindex]"));h(e)}}renderBarText(e,t){let o;"percentage"===this.valueFormat?o=0===e.perc&&e.amount>0?"<1%":`${e.perc}%`:"amount"===this.valueFormat&&(o=e.amount);const a=u(e.amount,this.total,!1),n=a/100*this.el.offsetWidth>=t;return r("div",{class:"value-wrapper "+(n?"":"fixed-width"),style:{width:n||0==e.amount?`${a}%`:`${t}px`}},r("span",{class:"value","data-value":e.amount,"data-segmentindex":e.index},e.amount>0&&o))}drawAxis(){if("bar3"===this.currentChartType)return r("svg",{class:"axis"},r("line",{x1:"0",x2:"100%",y1:"0",y2:"0"}),r("line",{x1:"0",x2:"0",y1:"0",y2:"-85px"}),r("line",{class:"tick",x1:"0.5",x2:"0.5",y1:"0",y2:"6"}),r("text",{x:"0.5",y:"-6"},"0%"),r("line",{class:"tick",x1:"100%",x2:"100%",y1:"0",y2:"6"}),r("text",{x:"100%",y:"-6"},"100%"))}renderChart(){return this.isSimpleBar?c.call(this,this.currentChartType):this.isStackedBar&&this.total>0?m.call(this,this.currentChartType):this.isDoughnut&&this.total>0?d.call(this,this.currentChartType):void 0}render(){return r(o,{onBlur:()=>x.call(this)},r("div",{ref:e=>this.componentWrapperEl=e,class:`component-wrapper ${this.currentChartType} ${this.isTabbing&&!this.userIsNavigating?"user-is-tabbing":""} ${"left"===this.labelPosition&&"bar4"===this.currentChartType?"left-label":""}`,role:"application","aria-label":this.ariaLabelText,tabindex:0,"aria-roledescription":f.interactiveChart,"aria-describedby":"chart-instructions"},r("label",{id:`label-${this.uid}`,class:`label --${this.labelPosition}`,htmlFor:`graphic-${this.uid}`},r("span",{class:"label-text"},this.label),this.subinfo?r("span",{class:"subinfo"},this.subinfo):""),this.isBar&&b.call(this,this.currentChartType),this.renderChart(),this.isDoughnut&&b.call(this,this.currentChartType),r("priv-chart-popover",{class:this.isTabbing?"user-is-tabbing":"",onIntChartPopoverOpenChanged:e=>this.handlePopoverOpenChanged(e)}),this.isBar&&!this.printMode&&g()),w())}static get delegatesFocus(){return!0}get el(){return a(this)}};v.style=":host{--wmcolor-chart-label-text-negative:var(--wmcolor-text-negative);--wmcolor-chart-label-text-positive:var(--wmcolor-text-positive);--wmcolor-chart-label-text:var(--wmcolor-text);--wmcolor-chart-subinfo-text:var(--wmcolor-text);--wmcolor-chart-value-text:var(--wmcolor-text);display:block}:host .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;outline:none;}:host .component-wrapper:focus-visible{outline:3px solid var(--wmcolor-interactive-focus);outline-offset:2px}:host .component-wrapper .label{display:block;margin:0;padding-bottom:0.25rem;font-weight:600;position:relative}:host .component-wrapper .label .subinfo{display:block;font-weight:normal;font-style:italic;bottom:0.25rem;width:100%;color:var(--wmcolor-chart-subinfo-text)}:host .component-wrapper .label.custom-width{width:var(--custom-label-width)}:host .component-wrapper .label.--none{display:none}:host .component-wrapper .doughnut-svg,:host .component-wrapper .inner-stacked-bar-wrapper{overflow:visible}:host .component-wrapper .bar-wrapper{-ms-flex-positive:1;flex-grow:1;width:100%}:host .component-wrapper .bar-wrapper .inner-stacked-bar-wrapper{width:100%}:host .component-wrapper .bar-wrapper .inner-stacked-bar-wrapper .values{display:-ms-flexbox;display:flex;gap:2px;margin-bottom:8px}:host .component-wrapper .bar-wrapper .inner-stacked-bar-wrapper .stacked-bar-segments-wrapper{display:-ms-flexbox;display:flex;gap:2px}:host .component-wrapper .bar-wrapper .inner-stacked-bar-wrapper .stacked-bar-segments-wrapper .stacked-bar-segment{height:30px;cursor:pointer}:host .component-wrapper .segment{print-color-adjust:exact;-webkit-print-color-adjust:exact}:host .component-wrapper .segment.fixed-width{-ms-flex-negative:0;flex-shrink:0}:host .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{cursor:pointer}:host .component-wrapper .value-wrapper{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center}:host .component-wrapper .value-wrapper .fixed-width{-ms-flex-negative:0;flex-shrink:0}:host .component-wrapper .value-wrapper .value.hidden{visibility:hidden}:host .component-wrapper .faded{opacity:0.3}:host .component-wrapper path:active,:host .component-wrapper path:hover,:host .component-wrapper path:focus,:host .component-wrapper .stacked-bar-segment:active,:host .component-wrapper .stacked-bar-segment:hover,:host .component-wrapper .stacked-bar-segment:focus{outline:none}:host .component-wrapper .stacked-bar-segment:active.stacked-bar-segment:not(:focus-visible),:host .component-wrapper .stacked-bar-segment:hover.stacked-bar-segment:not(:focus-visible),:host .component-wrapper .stacked-bar-segment:focus.stacked-bar-segment:not(:focus-visible){-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:not(:focus-visible),:host .component-wrapper path:hover.doughnut-segment:not(:focus-visible),:host .component-wrapper path:focus.doughnut-segment:not(:focus-visible),:host .component-wrapper .stacked-bar-segment:active.doughnut-segment:not(:focus-visible),:host .component-wrapper .stacked-bar-segment:hover.doughnut-segment:not(:focus-visible),:host .component-wrapper .stacked-bar-segment:focus.doughnut-segment:not(:focus-visible){-webkit-filter:url(#wmHoverDropShadow);filter:url(#wmHoverDropShadow)}:host .component-wrapper path::-moz-focus-inner,:host .component-wrapper .stacked-bar-segment::-moz-focus-inner{border:0;outline:none}:host .component-wrapper .stacked-bar-segment:focus-visible{outline:3px solid var(--wmcolor-interactive-focus);outline-offset:2px;-webkit-box-shadow:0 0 0 7px white;box-shadow:0 0 0 7px white;z-index:1}:host .component-wrapper #kfbg1{stroke:white;stroke-width:10px}:host .component-wrapper #kfstroke{stroke:var(--wmcolor-interactive-focus);stroke-width:6px}:host .component-wrapper #kfbg2{stroke:white;stroke-width:2px}:host .component-wrapper.doughnut{width:300px}:host .component-wrapper.doughnut1 label,:host .component-wrapper.doughnut1 .label-text,:host .component-wrapper.doughnut2 label,:host .component-wrapper.doughnut2 .label-text,:host .component-wrapper.doughnut2b label,:host .component-wrapper.doughnut2b .label-text,:host .component-wrapper.doughnut3 label,:host .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.doughnut{-ms-flex-align:center;align-items:center}:host .component-wrapper.doughnut label{text-align:center;width:100%;padding-bottom:1.5rem}:host .component-wrapper.doughnut label .subinfo{position:absolute}:host .component-wrapper.doughnut .completion-message{padding-top:0.625rem}:host .component-wrapper.bar{-ms-flex-align:start;align-items:flex-start}:host .component-wrapper.bar label{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}:host .component-wrapper.bar label .subinfo{position:initial}:host .component-wrapper.bar .chart-wrapper{display:-ms-flexbox;display:flex}:host .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.bar .chart-wrapper .inner-stacked-bar-wrapper{-ms-flex:1;flex:1}:host .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.bar{-ms-flex-direction:row;flex-direction:row}:host .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.bar .bar-wrapper{-ms-flex-direction:row-reverse;flex-direction:row-reverse}:host .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,:host .component-wrapper.bar2b,:host .component-wrapper.bar3,:host .component-wrapper.bar4,:host .component-wrapper.bar5{-ms-flex-align:start;align-items:flex-start}:host .component-wrapper.bar2b .inner-stacked-bar-wrapper,:host .component-wrapper.bar4 .inner-stacked-bar-wrapper,:host .component-wrapper.bar5 .inner-stacked-bar-wrapper{height:30px;margin-bottom:0}:host .component-wrapper.bar2b .inner-stacked-bar-wrapper.show-values,:host .component-wrapper.bar4 .inner-stacked-bar-wrapper.show-values,:host .component-wrapper.bar5 .inner-stacked-bar-wrapper.show-values{height:60px;margin-top:0}:host .component-wrapper.bar3 .chart-wrapper{position:relative;height:100px}:host .component-wrapper.bar3 .chart-wrapper .inner-stacked-bar-wrapper{position:absolute;top:35px;left:0;right:0;bottom:0;height:30px}:host .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{stroke:var(--wmcolor-chart-gridline);stroke-width:1px}:host .component-wrapper.bar3 .chart-wrapper .axis text{-webkit-transform:translate(4px, 24px);transform:translate(4px, 24px);text-anchor:middle}:host .component-wrapper.bar3 .hidden-values-warning{margin-top:1.25rem}:host .component-wrapper.bar6,:host .component-wrapper.bar7{--chartPadding:48px;-ms-flex-align:start;align-items:flex-start}:host .component-wrapper.bar6 .chart-wrapper,:host .component-wrapper.bar7 .chart-wrapper{width:100%}:host .component-wrapper.bar6 .chart,:host .component-wrapper.bar7 .chart{position:relative;padding-right:var(--chartPadding)}:host .component-wrapper.bar6 .gridlines,:host .component-wrapper.bar7 .gridlines{position:absolute;left:var(--labelWidth);right:var(--chartPadding);top:0;bottom:0;background-image:linear-gradient(90deg, var(--wmcolor-chart-gridline) 1px, transparent 1px);background-position:-1px;border-left:1px solid var(--wmcolor-chart-gridline);border-bottom:1px solid var(--wmcolor-chart-gridline);background-size:var(--backgroundSize)}:host .component-wrapper.bar6 .rows,:host .component-wrapper.bar7 .rows{display:grid;grid-template-columns:var(--labelWidth) auto;grid-auto-rows:minmax(30px, 1fr);-ms-flex-align:center;align-items:center;position:relative;z-index:1}:host .component-wrapper.bar6 .rows .label,:host .component-wrapper.bar7 .rows .label{font-weight:400;padding:0 0.75rem 0 0;text-align:right;margin:0.75rem 0}:host .component-wrapper.bar6 .rows .label.hidden,:host .component-wrapper.bar7 .rows .label.hidden{visibility:hidden;white-space:nowrap}:host .component-wrapper.bar6 .bar,:host .component-wrapper.bar7 .bar{height:30px;position:relative}:host .component-wrapper.bar6 .bar .value,:host .component-wrapper.bar7 .bar .value{position:absolute;top:50%;right:-0.5rem;-webkit-transform:translate(100%, -50%);transform:translate(100%, -50%)}:host .component-wrapper.bar6 .x-axis,:host .component-wrapper.bar7 .x-axis{margin-left:var(--labelWidth);margin-right:var(--chartPadding);display:-ms-flexbox;display:flex;postion:relative}:host .component-wrapper.bar6 .tick,:host .component-wrapper.bar7 .tick{-ms-flex:1;flex:1;text-align:right}:host .component-wrapper.bar6 .tick span,:host .component-wrapper.bar7 .tick span{-webkit-transform:translateX(50%);transform:translateX(50%);display:inline-block}:host .component-wrapper.bar6 .zero,:host .component-wrapper.bar7 .zero{position:absolute;-webkit-transform:translateX(-50%);transform:translateX(-50%)}:host .component-wrapper.bar6 .bar:active,:host .component-wrapper.bar6 .bar:hover,:host .component-wrapper.bar6 .bar:focus,:host .component-wrapper.bar7 .bar:active,:host .component-wrapper.bar7 .bar:hover,:host .component-wrapper.bar7 .bar:focus{outline:none}:host .component-wrapper.bar6 .bar:active.bar:not(:focus-visible),:host .component-wrapper.bar6 .bar:hover.bar:not(:focus-visible),:host .component-wrapper.bar6 .bar:focus.bar:not(:focus-visible),:host .component-wrapper.bar7 .bar:active.bar:not(:focus-visible),:host .component-wrapper.bar7 .bar:hover.bar:not(:focus-visible),:host .component-wrapper.bar7 .bar:focus.bar:not(:focus-visible){-webkit-box-shadow:0px 0px 6px #333;-moz-box-shadow:0px 0px 6px #333;box-shadow:0px 0px 6px #333}:host .component-wrapper.bar6 .bar:focus-visible,:host .component-wrapper.bar7 .bar:focus-visible{outline:3px solid var(--wmcolor-interactive-focus);outline-offset:2px;-webkit-box-shadow:0 0 0 7px white;box-shadow:0 0 0 7px white;z-index:1}:host .component-wrapper.left-label{-ms-flex-direction:row;flex-direction:row}:host .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 .component-wrapper .hidden-values-warning{font-size:0.75rem;font-style:italic;max-width:100%}:host .component-wrapper .hidden-values-warning.hidden{display:none}@media print{:host .component-wrapper .hidden-values-warning{display:none}}:host #chart-instructions{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 .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{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.bar6{display:none}:host .component-wrapper .legend-wrapper .legend.--top{margin-top:-0.75rem}:host .component-wrapper .legend-wrapper .legend.--top .legend-item{padding-top:0.75rem}:host .component-wrapper .legend-wrapper .legend.--top .legend-color{top:0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom{margin-bottom:-0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom .legend-item{padding-bottom:0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom .legend-color{top:-0.75rem}:host .component-wrapper .legend-wrapper .legend .legend-item{position:relative}:host .component-wrapper .legend-wrapper .legend .legend-item.faded{opacity:0.3}:host .component-wrapper .legend-wrapper .legend .legend-item:not(:last-of-type){padding-right:1.25rem}:host .component-wrapper .legend-wrapper .legend .legend-text{font-size:0.875rem;padding-left:1rem;line-height:1}:host .component-wrapper .legend-wrapper .legend .legend-color{position:absolute;left:0;bottom:0;margin:auto;width:0.6875rem;height:0.6875rem;print-color-adjust:exact;-webkit-print-color-adjust:exact}:host .component-wrapper .legend-wrapper .legend .print-value{display:none}:host .component-wrapper .legend-wrapper .legend .print-value.force-visible{display:unset}@media print{:host .component-wrapper .legend-wrapper .legend .print-value{display:unset}}:host .component-wrapper .legend-wrapper .legend.bar3{padding-bottom:1.25rem}";export{v as wm_chart}
@@ -1 +0,0 @@
1
- import{r as e,c as r,h as a,H as t,g as i}from"./p-568c595f.js";import{i as o,B as n,I as d,J as p,C as s,K as l}from"./p-e995f7f0.js";const c=class{constructor(t){e(this,t),this.cellTriggered=r(this,"cellTriggered",7),this.cellHovered=r(this,"cellHovered",7),this.outOfCal=r(this,"outOfCal",7),this.popupBlurred=r(this,"popupBlurred",7),this.dateFocus=r(this,"dateFocus",7),this.today=this.dateToISO(new Date),this.calType="single",this.calName="",this.calInstructions=o.formatMessage({id:"date.instructions",defaultMessage:"Use arrows to select a date in the table. Tab left or right to buttons for selecting previous month, next month, or the month selection table."}),this._focus={year:{asString:()=>n.year.asString(this.focusDate),asInt:()=>n.year.asInt(this.focusDate),set:e=>{const r=this._focus.month.asInt(),a=this._focus.day.asInt();this.focusDate=d(e,r,a)},increase:e=>{const r=n.year.increase(this.focusDate,e);this.focusDate=r},decrease:e=>{const r=n.year.decrease(this.focusDate,e);this.focusDate=r}},month:{asString:()=>n.month.asString(this.focusDate),asInt:()=>n.month.asInt(this.focusDate),set:e=>{const r=this._focus.year.asInt(),a=this._focus.day.asInt();this.focusDate=d(r,e,a)},increase:e=>{const r=n.month.increase(this.focusDate,e);this.focusDate=r},decrease:e=>{const r=n.month.decrease(this.focusDate,e);this.focusDate=r}},day:{asString:()=>n.day.asString(this.focusDate),asInt:()=>n.day.asInt(this.focusDate),set:e=>{const r=this._focus.year.asInt(),a=this._focus.month.asInt();e=-1===e?l(a,r):e,this.focusDate=d(r,a,e)},increase:e=>{const r=n.day.increase(this.focusDate,e);this.focusDate=r},decrease:e=>{const r=n.day.decrease(this.focusDate,e);this.focusDate=r}}},this.monthButtonFocus={set:e=>{const r=Array.from(this.el.querySelectorAll(".month")),a=r.filter((e=>e.classList.contains("focused")))[0];a.classList.remove("selected"),a.tabIndex=-1,r[e-1].classList.add("selected"),r[e-1].tabIndex=0,r[e-1].focus()},increase:e=>{const r=Array.from(this.el.querySelectorAll(".month")),a=r.filter((e=>e.classList.contains("focused")))[0],t=r.indexOf(a),i=(t+e)%12;i<t&&this._focus.year.increase(1),a.classList.remove("focused"),a.tabIndex=-1,r[i].classList.add("focused"),r[i].tabIndex=0,r[i].focus()},decrease:e=>{const r=Array.from(this.el.querySelectorAll(".month")),a=r.filter((e=>e.classList.contains("focused")))[0],t=r.indexOf(a);let i=t+24;i=(i-e)%12,i>t&&this._focus.year.decrease(1),a.classList.remove("focused"),a.tabIndex=-1,r[i].classList.add("focused"),r[i].tabIndex=0,r[i].focus()}},this.renderCalendarDate=(e,r,t,i)=>{if("placeholder"===e)return a("div",{role:"gridcell"});const d=n.month.asInt(e),c=n.day.asInt(e),g=n.year.asInt(e),h=t&&t===e;let w=h?"true":"false";const u=["date-cell"],v=e===this.focusDate,b=e===this.today;if(b&&u.push("today"),"range"===this.calType){const r=t&&i&&i===e&&t<i;w=r?"true":w;const a=1===c,o=c===l(d,g),n=this.isInRange(e),p=this.isInRangePreview(e),s=!i&&t&&this.hoverDate&&e===this.hoverDate,v=s&&this.hoverDate<t,b=s&&this.hoverDate>t;a&&u.push("first-of-month"),o&&u.push("last-of-month"),h&&u.push(p&&!r&&this.hoverDate&&this.hoverDate<t?"range-end":"range-start"),r&&u.push("range-end"),n&&u.push("in-range"),p&&u.push("in-range preview"),v&&u.push("preview-start"),b&&u.push("preview-end")}const m=u.join(" ");return a("div",{role:"gridcell",id:`cell-${e}`,class:m,"aria-selected":w,"aria-label":`${b?`${o.formatMessage({id:"date.today",defaultMessage:"today",description:"calendar button"})}, `:""}${p[r]}, ${s[d-1]} ${c}, ${g}`,onClick:e=>{this.handleDateClick(e.target)},onMouseOver:()=>this.cellHovered.emit(e),"data-month":n.month.asString(e),"data-year":n.year.asString(e),onBlur:e=>e.stopPropagation(),tabIndex:v?0:-1},c)},this.disabled=!1,this.view="day",this.focusDate=this.today,this.startDate=void 0,this.endDate=void 0,this.hoverDate=void 0}setCalName(){const e=this.el.parentElement.querySelectorAll("priv-calendar");let r;r=o.formatMessage(1===e.length?{id:"date.calName",defaultMessage:"Calendar. "}:e[0]===this.el?{id:"date.firstCalName",defaultMessage:"First calendar. "}:{id:"date.secondCalName",defaultMessage:"Second calendar. "}),this.calName=r}setCalType(){const e=this.el.parentElement.querySelectorAll("priv-calendar");this.calType=1===e.length?"single":"range"}componentWillLoad(){this.setCalName(),this.setCalType()}handleFocusDate(e,r){if("day"===this.view){const a=this.getCell(r);a&&(a.tabIndex=-1);const t=this.getCell(e);t&&(t.tabIndex=0)}else{const a=this.el.querySelector(`#month-${n.month.asInt(r)}`);a&&(a.tabIndex=-1);const t=this.el.querySelector(`#month-${n.month.asInt(e)}`);t&&(t.tabIndex=0)}this.dateFocus.emit()}get otherCalEl(){const e=this.el.parentElement.querySelectorAll("priv-calendar");let r;return 2===e.length&&(r=e[0]===this.el?e[1]:e[0]),r}get headerButtonEls(){return Array.from(this.el.querySelectorAll(".header-btn"))}handleKey(e){switch(e.key){case" ":case"Enter":e.preventDefault(),!e.target.id.includes("popup-title")&&e.target.click();break;case"PageUp":e.preventDefault(),"day"===this.view?(this._focus.month.decrease(1),this.focusCell()):this._focus.year.decrease(1);break;case"PageDown":e.preventDefault(),"day"===this.view?(this._focus.month.increase(1),this.focusCell()):this._focus.year.increase(1);break;case"Home":e.preventDefault(),"day"===this.view?(this._focus.day.set(1),this.focusCell()):this.monthButtonFocus.set(1);break;case"End":e.preventDefault(),"day"===this.view?(this._focus.day.set(-1),this.focusCell()):this.monthButtonFocus.set(12);break;case"ArrowLeft":e.preventDefault(),"day"===this.view?(this._focus.day.decrease(1),this.focusCell()):this.monthButtonFocus.decrease(1);break;case"ArrowRight":e.preventDefault(),"day"===this.view?(this._focus.day.increase(1),this.focusCell()):this.monthButtonFocus.increase(1);break;case"ArrowUp":e.preventDefault(),"day"===this.view?(this._focus.day.decrease(7),this.focusCell()):this.monthButtonFocus.decrease(3);break;case"ArrowDown":if(e.preventDefault(),"day"===this.view){if(!(document.activeElement.shadowRoot||document).activeElement.classList.contains("date-cell")){this.focusCell();break}this._focus.day.increase(7),this.focusCell()}else{if((document.activeElement.shadowRoot||document).activeElement.classList.contains("header-btn")){const e=`#month-${this._focus.month.asInt()}`,r=this.el.querySelector(e);r.tabIndex=0,r.focus();break}this.monthButtonFocus.increase(3)}}}handleDateClick(e){this.cellTriggered.emit({cal:this.el,cell:e})}removeZeroes(e){return+e<10?+e.slice(1):+e}dateToISO(e){return[e.getUTCFullYear().toString().padStart(4,"0"),(e.getUTCMonth()+1).toString().padStart(2,"0"),e.getUTCDate().toString().padStart(2,"0")].join("-")}isInRange(e){if(this.otherCalEl){const r=this.startDate||this.otherCalEl.startDate,a=this.endDate||this.otherCalEl.endDate;if(r&&a)return r<=e&&e<=a}return!1}isInRangePreview(e){if(this.otherCalEl){const r=this.startDate||this.otherCalEl.startDate,a=this.endDate||this.otherCalEl.endDate;if(r&&a)return!1;if(r&&this.hoverDate){if(this.hoverDate>r)return r<=e&&e<=this.hoverDate;if(this.hoverDate<r)return this.hoverDate<=e&&e<=r}else if(a&&this.hoverDate){if(this.hoverDate<a)return this.hoverDate<=e&&e<=a;if(this.hoverDate>a)return a<=e&&e<=this.hoverDate}}return!1}getMonthFirstDay(e,r){return+new Date(r,e-1,1,12,0,0).getDay()+1}getCalendarDates(e){const r=n.month.asInt(e),a=n.year.asInt(e),t=l(r,a),i=[...new Array(t).fill(void 0)].map(((e,t)=>d(a,r,t+1))),o=this.getMonthFirstDay(r,a)-1;let p=42-(o+t);return p=p>6?p-7:p,[...o>0?new Array(o).fill("placeholder"):[],...i,...p>0?new Array(p).fill("placeholder"):[]]}getCell(e){return this.el.querySelector(`#cell-${e}`)}async focusFirstFocusable(){this.prevBtnEl.focus()}async focusLastFocusable(){this.focusCell()}async focusCell(){requestAnimationFrame((()=>{const e=l(this._focus.month.asInt(),this._focus.year.asInt());this._focus.day.asInt()>e&&this._focus.day.set(e);const r=this.getCell(this.focusDate);r&&(r.tabIndex=0,r.focus()),"day"==this.view&&this.cellHovered.emit(this.focusDate)}))}toggleBusyAttribute(e){this.el.querySelector("#wm-container").setAttribute("aria-busy",e)}renderMonth(e,r){return a("button",{id:`month-${r+1}`,class:"month "+(this._focus.month.asInt()===r+1?"selected focused":""),role:"gridcell",tabindex:r+1===this._focus.month.asInt()?0:-1,onBlur:e=>e.stopPropagation(),onClick:()=>{this._focus.month.set(r+1),this.view="day",this.focusCell()}},e)}renderDayView(){const e=this.getCalendarDates(this.focusDate),r=this.startDate||this.otherCalEl&&this.otherCalEl.startDate,t=this.endDate||this.otherCalEl&&this.otherCalEl.endDate;return a("div",{class:"popup day-view"},a("div",{class:"calendar-header"},a("button",{onClick:()=>{this._focus.month.decrease(1)},class:"header-btn arw-btn",ref:e=>this.prevBtnEl=e,"aria-label":o.formatMessage({id:"date.selectPreviousMonth",defaultMessage:"Select previous month",description:"Calendar button"})},a("span",{class:"mdi"},"")),a("div",{id:"popup-title-month",class:"header-btn title-box",tabindex:"0",role:"button",onKeyDown:e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),this.view="month")},onClick:()=>this.view="month","aria-label":`${o.formatMessage({id:"date.currentMonth",defaultMessage:"current month",description:"Calendar button"})}: ${s[this._focus.month.asInt()-1]}\n ${this._focus.year.asString()}.`,"aria-describedby":"month-title"},a("span",{class:"title","aria-hidden":"true"},s[this._focus.month.asInt()-1]," ",this._focus.year.asString())),a("button",{onClick:()=>{this._focus.month.increase(1)},"aria-label":o.formatMessage({id:"date.selectNextMonth",defaultMessage:"Select next month",description:"Calendar button"}),class:"header-btn arw-btn"},a("span",{class:"mdi"},""))),a("div",{"aria-labelledby":"popup-title-month",role:"grid",class:"date-grid"},a("div",{role:"rowgroup",class:"date-header"},a("div",{role:"row",class:"header-row"},a("div",{role:"columnheader",class:"header-cell"},a("span",null,o.formatMessage({id:"date.su",defaultMessage:"Su",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,o.formatMessage({id:"date.mo",defaultMessage:"Mo",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,o.formatMessage({id:"date.tu",defaultMessage:"Tu",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,o.formatMessage({id:"date.we",defaultMessage:"We",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,o.formatMessage({id:"date.th",defaultMessage:"Th",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,o.formatMessage({id:"date.fr",defaultMessage:"Fr",description:"Abbreviated day of the week"}))),a("div",{role:"columnheader",class:"header-cell"},a("span",null,o.formatMessage({id:"date.sa",defaultMessage:"Sa",description:"Abbreviated day of the week"}))))),a("div",{role:"rowgroup"},a("div",{role:"row",class:"date-row"},e.slice(0,7).map(((e,a)=>this.renderCalendarDate(e,a,r,t)))),a("div",{role:"row"},e.slice(7,14).map(((e,a)=>this.renderCalendarDate(e,a,r,t)))),a("div",{role:"row"},e.slice(14,21).map(((e,a)=>this.renderCalendarDate(e,a,r,t)))),a("div",{role:"row"},e.slice(21,28).map(((e,a)=>this.renderCalendarDate(e,a,r,t)))),a("div",{role:"row"},e.slice(28,35).map(((e,a)=>this.renderCalendarDate(e,a,r,t)))),e.length>35?a("div",{role:"row"},e.slice(35).map(((e,a)=>this.renderCalendarDate(e,a,r,t)))):"")))}renderMonthView(){return a("div",{class:"month-view"},a("div",{class:"calendar-header"},a("button",{onClick:()=>{this._focus.year.decrease(1)},"aria-label":o.formatMessage({id:"date.selectPreviousYear",defaultMessage:"Select previous year",description:"Calendar button"}),class:"header-btn arw-btn",ref:e=>this.prevBtnEl=e},a("span",{class:"mdi"},"")),a("div",{id:"popup-title-year",tabindex:"0",class:"header-btn title-box year",role:"button",onClick:()=>this.view="day",onKeyDown:e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),this.view="day")},"aria-labelledby":"year-title"},a("span",{class:"title"},this._focus.year.asString())),a("button",{onClick:()=>{this._focus.year.increase(1)},"aria-label":o.formatMessage({id:"date.selectNextYear",defaultMessage:"Select next year",description:"Calendar button"}),class:"header-btn arw-btn"},a("span",{class:"mdi"},""))),a("div",{"aria-labelledby":"popup-title-year",role:"grid",class:"months"},a("div",{role:"row",class:"month-row"},s.slice(0,3).map(((e,r)=>this.renderMonth(e,r)))),a("div",{role:"row",class:"month-row"},s.slice(3,6).map(((e,r)=>this.renderMonth(e,r+3)))),a("div",{role:"row",class:"month-row"},s.slice(6,9).map(((e,r)=>this.renderMonth(e,r+6)))),a("div",{role:"row",class:"month-row"},s.slice(9).map(((e,r)=>this.renderMonth(e,r+9))))))}render(){return a(t,{onMouseOut:e=>{this.el.parentElement.contains(e.toElement)||this.outOfCal.emit()},role:"application","aria-describedby":"application"},"day"===this.view?this.renderDayView():this.renderMonthView(),a("div",{id:"application",class:"sr-only"},this.calName,this.calInstructions))}get el(){return i(this)}static get watchers(){return{focusDate:["handleFocusDate"]}}};c.style=':host{--wmcolor-calendar-border:var(--wmcolor-border);--wmcolor-calendar-day-border-hover:var(--wmcolor-border-focus);--wmcolor-calendar-range-background:var(--wmcolor-interactive-background-hover);--wmcolor-datepicker-range-background-hover:var(--wmcolor-datepicker-day-background-hover);--wmcolor-datepicker-range-background-selected:var(--wmcolor-background-selected);--range-start-svg:url(\'data:image/svg+xml,<svg width="44" height="44" viewBox="0 0 44 44" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M0 6C0 2.68629 2.68629 0 6 0H28.8457C31.0777 0 33.1251 1.23886 34.1607 3.21596L42.5417 19.216C43.455 20.9596 43.455 23.0404 42.5417 24.784L34.1607 40.784C33.1251 42.7611 31.0777 44 28.8458 44H6C2.68629 44 0 41.3137 0 38V6Z" fill="%23575195"/></svg>\');--range-end-svg:url(\'data:image/svg+xml,<svg width="44" height="44" viewBox="0 0 44 44" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M44 6C44 2.68629 41.3137 0 38 0H15.1543C12.9223 0 10.8749 1.23886 9.83926 3.21596L1.45831 19.216C0.544956 20.9596 0.54496 23.0404 1.45831 24.784L9.83926 40.784C10.8749 42.7611 12.9223 44 15.1542 44H38C41.3137 44 44 41.3137 44 38V6Z" fill="%23575195"/></svg>\');--range-background-selected:linear-gradient(\n transparent,\n transparent 5px,\n var(--wmcolor-datepicker-range-background-selected) 5px,\n var(--wmcolor-datepicker-range-background-selected) 39px,\n transparent 39px\n );--range-background-hover:linear-gradient(\n transparent,\n transparent 5px,\n var(--wmcolor-datepicker-range-background-hover) 5px,\n var(--wmcolor-datepicker-range-background-hover) 39px,\n transparent 39px\n )}:host priv-calendar+priv-calendar{-webkit-border-start:1px solid var(--wmcolor-calendar-border);border-inline-start:1px solid var(--wmcolor-calendar-border)}.toggle{all:unset;cursor:pointer;padding:0 0.375rem;height:2.375rem;background-color:var(--wmcolor-datepicker-toggle-background);border:none;border-radius:3px}.toggle span::after{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f0ed";font-size:1.5rem;color:var(--wmcolor-datepicker-toggle-icon);padding:0;line-height:2.5rem}.toggle:hover{-webkit-box-shadow:none;box-shadow:none;background:var(--wmcolor-datepicker-toggle-background-hover)}.toggle:disabled{pointer-events:none;-webkit-box-shadow:none;box-shadow:none;background-color:var(--wmcolor-datepicker-toggle-background-disabled)}.toggle:disabled .calendar::after{color:var(--wmcolor-datepicker-toggle-icon-disabled)}[dir=RTL] .toggle{right:auto;left:0}.toggle::-moz-focus-inner{border:0}.toggle:focus-visible{outline:3px solid var(--wmcolor-interactive-focus);outline-offset:0}.toggle:focus-visible:not(:active){border:none;z-index:11}.inside .toggle{border-top-left-radius:0;border-bottom-left-radius:0;border-start-start-radius:0;border-end-start-radius:0}.popup-wrapper{visibility:hidden;font-family:inherit;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;-webkit-box-shadow:0px 4px 15px 0px rgba(0, 0, 0, 0.2);box-shadow:0px 4px 15px 0px rgba(0, 0, 0, 0.2);z-index:10;position:absolute;left:0;top:calc(100% + 2px);min-height:21.0625rem;-webkit-transition:-webkit-transform 0.25s ease;transition:-webkit-transform 0.25s ease;transition:transform 0.25s ease;transition:transform 0.25s ease, -webkit-transform 0.25s ease;-webkit-transform-origin:center top;transform-origin:center top;-webkit-transform:scale(1, 0);transform:scale(1, 0);background-color:var(--wmcolor-datepicker-background)}.popup-wrapper.start{border:2px solid cyan}.popup-wrapper.end{left:247px !important;border:2px solid teal}.popup-wrapper.open{-webkit-transform:scale(1, 1);transform:scale(1, 1)}.popup-wrapper.expand-upwards{top:auto;bottom:2.375rem;-webkit-transform-origin:center bottom;transform-origin:center bottom}.popup-wrapper .calendar-header{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;-webkit-justify-content:space-between;justify-content:space-between;position:relative;padding:0.9375rem 0.25rem}.popup-wrapper .calendar-header .title-box{height:2.625rem;-webkit-border-radius:3px;-moz-border-radius:3px;-ms-border-radius:3px;border-radius:3px;border:1px solid;font-weight:500;font-size:0.875rem;background:var(--wmcolor-datepicker-selector-background);cursor:pointer;display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-align:center;align-items:center;padding:0 0.375rem 0 0.75rem;border-color:var(--wmcolor-datepicker-selector-border);color:var(--wmcolor-datepicker-selector-text)}.popup-wrapper .calendar-header .title-box:after{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:"\\f140";padding-left:0.75rem;font-size:1.12rem}.popup-wrapper .calendar-header .title-box.year:after{content:"\\f143"}.popup-wrapper .calendar-header .title-box::-moz-focus-inner{border:0}.popup-wrapper .calendar-header .arw-btn{cursor:pointer;-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;border-radius:50%;width:2.75rem;height:2.75rem;border:none;color:var(--wmcolor-datepicker-navigation-text);background:var(--wmcolor-datepicker-navigation-background);padding:0;-webkit-box-shadow:none;box-shadow:none;line-height:2.75rem}.popup-wrapper .calendar-header .arw-btn .mdi{display:inline-block;font:normal normal normal 24px/1 "Material Design Icons";font-size:inherit;text-rendering:auto;line-height:inherit;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-size:1.5rem;font-weight:normal;line-height:2.75rem}.popup-wrapper .calendar-header .arw-btn:hover{background-color:var(--wmcolor-datepicker-navigation-background-hover)}.popup-wrapper .calendar-header .arw-btn:active{-ms-transform:scale(0.9, 0.9);-webkit-transform:scale(0.9, 0.9);-moz-transform:scale(0.9, 0.9);transform:scale(0.9, 0.9)}.popup-wrapper .separator{min-width:1px;background:var(--wm-color-border)}.popup-wrapper .day-view{min-width:21rem}.popup-wrapper .day-view .date-grid{width:100%;text-align:center;border-collapse:collapse;margin-bottom:0.4375rem;color:var(--wmcolor-datepicker-day-text)}.popup-wrapper .day-view .date-grid div[role=row]{display:-ms-flexbox;display:flex;-ms-flex-pack:distribute;justify-content:space-around;padding-inline:0.875rem}.popup-wrapper .day-view .date-grid div[role=row]:not(.header-row){height:2.75rem}.popup-wrapper .day-view .date-grid .date-header{background-color:var(--wmcolor-datepicker-weekdays-background)}.popup-wrapper .day-view .date-grid .header-cell{height:2.0625rem;line-height:2.0625rem;width:2.75rem;margin:0 calc((14.28% - 44px) / 2);padding:0;display:inline-block;font-size:0.8125rem;font-weight:bold;color:var(--wmcolor-datepicker-weekdays-text);border:none}.popup-wrapper .day-view .date-grid [role=gridcell]{padding:0;-webkit-border-radius:50%;-moz-border-radius:50%;-ms-border-radius:50%;border-radius:50%;aspect-ratio:1;font-size:0.875rem;font-weight:500;position:relative;display:-ms-flexbox;display:flex;-ms-flex:1 0 2.75rem;flex:1 0 2.75rem;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center}.popup-wrapper .day-view .date-grid .date-cell{cursor:pointer}.popup-wrapper .day-view .date-grid .date-cell:hover{background-color:var(--wmcolor-datepicker-day-background-hover)}.popup-wrapper .day-view .date-grid .date-cell[aria-selected=true]{background-color:var(--wmcolor-datepicker-day-background-selected);color:var(--wmcolor-datepicker-day-text-selected)}.popup-wrapper .day-view .date-grid .date-cell.in-range{background:var(--range-background-selected);border-radius:0}.popup-wrapper .day-view .date-grid .date-cell.in-range.range-start:not(.preview):hover{background-repeat:no-repeat;background-position:center, center left 17px}.popup-wrapper .day-view .date-grid .date-cell.in-range.range-end:not(.preview):hover{background-position:center, center right 17px;background-repeat:no-repeat}.popup-wrapper .day-view .date-grid .date-cell.in-range:not(.preview):hover{background-image:radial-gradient(#dbd9ef 20px, transparent 21px), var(--range-background-selected);color:var(--wmcolor-datepicker-day-text)}.popup-wrapper .day-view .date-grid .date-cell.in-range.preview{position:relative;background-image:var(--range-background-hover)}.popup-wrapper .day-view .date-grid .date-cell.in-range.preview:last-child:not(.preview-start,.preview-end,.range-start,.range-end),.popup-wrapper .day-view .date-grid .date-cell.in-range.preview:last-of-type:not(.preview-start,.preview-end,.range-start,.range-end),.popup-wrapper .day-view .date-grid .date-cell.in-range.preview:first-child:not(.preview-start,.preview-end,.range-start,.range-end),.popup-wrapper .day-view .date-grid .date-cell.in-range.preview:first-of-type:not(.preview-start,.preview-end,.range-start,.range-end),.popup-wrapper .day-view .date-grid .date-cell.in-range.preview.last-of-month:not(.preview-start,.preview-end,.range-start,.range-end),.popup-wrapper .day-view .date-grid .date-cell.in-range.preview.first-of-month:not(.preview-start,.preview-end,.range-start,.range-end){background-image:radial-gradient(var(--wmcolor-datepicker-range-background-hover) 16px, transparent 17px), var(--range-background-hover);background-repeat:no-repeat}.popup-wrapper .day-view .date-grid .date-cell.in-range.preview:first-child:not(.preview-start,.preview-end,.range-start,.range-end),.popup-wrapper .day-view .date-grid .date-cell.in-range.preview:first-of-type:not(.preview-start,.preview-end,.range-start,.range-end),.popup-wrapper .day-view .date-grid .date-cell.in-range.preview.first-of-month:not(.preview-start,.preview-end,.range-start,.range-end){background-position:center left -5px, center left 17px}.popup-wrapper .day-view .date-grid .date-cell.in-range.preview:last-child:not(.preview-start,.preview-end,.range-start,.range-end),.popup-wrapper .day-view .date-grid .date-cell.in-range.preview:last-of-type:not(.preview-start,.preview-end,.range-start,.range-end),.popup-wrapper .day-view .date-grid .date-cell.in-range.preview.last-of-month:not(.preview-start,.preview-end,.range-start,.range-end){background-position:center right -5px, center right 17px}.popup-wrapper .day-view .date-grid .date-cell.in-range.preview.last-of-month:first-child:not(.preview-start,.preview-end){background-image:radial-gradient(var(--wmcolor-datepicker-range-background-hover) 16px, transparent 17px), radial-gradient(var(--wmcolor-datepicker-range-background-hover) 16px, transparent 17px), linear-gradient(transparent, transparent 15px, var(--wmcolor-datepicker-range-background-hover) 15px, var(--wmcolor-datepicker-range-background-hover) 29px, transparent 29px);background-position:center left -5px, center right -5px, center;background-size:auto, auto, 9px}.popup-wrapper .day-view .date-grid .date-cell.in-range.preview-start:last-child,.popup-wrapper .day-view .date-grid .date-cell.in-range.preview-end:first-child{background-image:radial-gradient(var(--wmcolor-datepicker-range-background-hover) 17px, var(--wmcolor-calendar-day-border-hover) 18px, var(--wmcolor-calendar-day-border-hover) 20px, transparent 21px)}.popup-wrapper .day-view .date-grid .date-cell.in-range.preview-start{background-position:center, center left 17px;background-repeat:no-repeat}.popup-wrapper .day-view .date-grid .date-cell.in-range.preview-start:first-child{background-position:center, center left 17px;background-repeat:no-repeat}.popup-wrapper .day-view .date-grid .date-cell.in-range.preview-end{background-position:center, center right 17px;background-repeat:no-repeat}.popup-wrapper .day-view .date-grid .date-cell.in-range.preview-end:last-child{background-position:center, center right 17px;background-repeat:no-repeat}.popup-wrapper .day-view .date-grid .date-cell.in-range.preview-end,.popup-wrapper .day-view .date-grid .date-cell.in-range.preview-start{background-image:radial-gradient(var(--wmcolor-datepicker-range-background-hover) 17px, var(--wmcolor-calendar-day-border-hover) 18px, var(--wmcolor-calendar-day-border-hover) 20px, transparent 21px), var(--range-background-hover)}.popup-wrapper .day-view .date-grid .date-cell.in-range.preview-end:focus-visible,.popup-wrapper .day-view .date-grid .date-cell.in-range.preview-start:focus-visible{outline:none;border:none}.popup-wrapper .day-view .date-grid .date-cell.in-range:first-of-type:not(.preview-start,.preview-end,.range-start,.range-end),.popup-wrapper .day-view .date-grid .date-cell.in-range:first-child:not(.preview-start,.preview-end,.range-start,.range-end),.popup-wrapper .day-view .date-grid .date-cell.in-range.first-of-month:not(.preview-start,.preview-end,.range-start,.range-end){background-image:radial-gradient(var(--wmcolor-datepicker-range-background-selected) 16px, transparent 17px), var(--range-background-selected);background-position:-5px center, center left 17px;background-repeat:no-repeat}.popup-wrapper .day-view .date-grid .date-cell.in-range:first-of-type:not(.preview-start,.preview-end,.range-start,.range-end):hover,.popup-wrapper .day-view .date-grid .date-cell.in-range:first-child:not(.preview-start,.preview-end,.range-start,.range-end):hover,.popup-wrapper .day-view .date-grid .date-cell.in-range.first-of-month:not(.preview-start,.preview-end,.range-start,.range-end):hover{background-image:radial-gradient(#dbd9ef 20px, transparent 21px), radial-gradient(var(--wmcolor-datepicker-range-background-selected) 16px, transparent 17px), var(--range-background-selected);background-position:center, -5px center, center left 17px;background-repeat:no-repeat}.popup-wrapper .day-view .date-grid .date-cell.in-range.range-start:last-child:hover,.popup-wrapper .day-view .date-grid .date-cell.in-range.range-end:first-child:hover{background:radial-gradient(#dbd9ef 20px, transparent 21px);background-position:center}.popup-wrapper .day-view .date-grid .date-cell.in-range:last-of-type:not(.range-start,.range-end,.preview),.popup-wrapper .day-view .date-grid .date-cell.in-range:last-child:not(.range-start,.range-end,.preview),.popup-wrapper .day-view .date-grid .date-cell.in-range.last-of-month:not(.range-start,.range-end,.preview){background:radial-gradient(var(--wmcolor-datepicker-range-background-selected) 16px, transparent 17px), var(--range-background-selected);background-position:5px center, center right 17px;background-repeat:no-repeat}.popup-wrapper .day-view .date-grid .date-cell.in-range:last-of-type:not(.range-start,.range-end,.preview-start,.preview-end):hover,.popup-wrapper .day-view .date-grid .date-cell.in-range:last-child:not(.range-start,.range-end,.preview-start,.preview-end):hover,.popup-wrapper .day-view .date-grid .date-cell.in-range.last-of-month:not(.range-start,.range-end,.preview-start,.preview-end):hover{background-image:radial-gradient(#dbd9ef 20px, transparent 21px), radial-gradient(var(--wmcolor-datepicker-range-background-selected) 16px, transparent 17px), var(--range-background-selected);background-position:center, 5px center, center right 17px;background-repeat:no-repeat}.popup-wrapper .day-view .date-grid .date-cell.today:after{content:"";display:block;position:absolute;inset:auto 0 6px 0;width:6px;aspect-ratio:1;border-radius:50%;justify-self:center;background-color:var(--wmcolor-datepicker-day-background-selected);margin:auto}.popup-wrapper .day-view .date-grid .date-cell.range-start,.popup-wrapper .day-view .date-grid .date-cell.range-end{border-radius:0;margin:0;outline:none;font-weight:600;color:var(--wmcolor-datepicker-day-text-selected)}.popup-wrapper .day-view .date-grid .date-cell.range-start:focus-visible,.popup-wrapper .day-view .date-grid .date-cell.range-end:focus-visible{outline:3px solid var(--wmcolor-interactive-focus);outline-offset:-2px;border:none;z-index:11}.popup-wrapper .day-view .date-grid .date-cell.range-start:focus-visible[aria-selected=true],.popup-wrapper .day-view .date-grid .date-cell.range-end:focus-visible[aria-selected=true]{outline-offset:2px}.popup-wrapper .day-view .date-grid .date-cell.range-start{background-image:var(--range-start-svg);-webkit-padding-end:2px;padding-inline-end:2px;background-color:transparent}.popup-wrapper .day-view .date-grid .date-cell.range-start.in-range:not(:hover,:last-of-type,:last-child){background-image:var(--range-start-svg), var(--range-background-selected);border-radius:0}.popup-wrapper .day-view .date-grid .date-cell.range-start.in-range.preview:not(:last-of-type,:last-child){background-image:var(--range-start-svg), var(--range-background-hover)}.popup-wrapper .day-view .date-grid .date-cell.range-end{background-image:var(--range-end-svg);-webkit-padding-start:2px;padding-inline-start:2px;background-color:transparent}.popup-wrapper .day-view .date-grid .date-cell.range-end.in-range:not(:hover,:first-of-type,:first-child){background-image:var(--range-end-svg), var(--range-background-selected);border-radius:0}.popup-wrapper .day-view .date-grid .date-cell.range-end.in-range.preview:not(:first-of-type,:first-child){background-image:var(--range-end-svg), var(--range-background-hover)}.popup-wrapper .day-view .date-grid .date-cell.range-start.range-end{background:var(--wmcolor-datepicker-day-background-selected);border-radius:50%;padding-inline:0;margin:1px;-ms-flex-preferred-size:42px;flex-basis:42px}.popup-wrapper .month-view .months{border-top:2px solid;border-top-color:var(--wmcolor-datepicker-month-border);display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap}.popup-wrapper .month-view .month-row{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;-webkit-justify-content:space-between;justify-content:space-between;width:100%;border-bottom:2px solid;border-bottom-color:var(--wmcolor-datepicker-month-border)}.popup-wrapper .month-view .month{border:none;background:white;cursor:pointer;width:7rem;height:4rem;line-height:4rem;font-family:inherit;font-weight:500;color:var(--wmcolor-datepicker-month-text)}.popup-wrapper .month-view .month:not(:last-child){border-right:2px solid;border-right-color:var(--wmcolor-datepicker-month-border)}.popup-wrapper .month-view .month:hover{border-right-color:transparent;background-color:var(--wmcolor-datepicker-month-background-hover)}.popup-wrapper .month-view .month:active,.popup-wrapper .month-view .month.selected{background-color:var(--wmcolor-datepicker-month-background-selected);color:var(--wmcolor-datepicker-month-text-selected)}.popup-wrapper button:focus-visible:not(.preview-start,.preview-end),.popup-wrapper .title-box:focus-visible:not(.preview-start,.preview-end),.popup-wrapper .month.focused:focus-visible:not(.preview-start,.preview-end),.popup-wrapper .date-cell:focus-visible:not(.preview-start,.preview-end){outline:3px solid var(--wmcolor-interactive-focus);outline-offset:-2px;border:none;z-index:11}.popup-wrapper button:focus-visible:not(.preview-start,.preview-end)[aria-selected=true],.popup-wrapper .title-box:focus-visible:not(.preview-start,.preview-end)[aria-selected=true],.popup-wrapper .month.focused:focus-visible:not(.preview-start,.preview-end)[aria-selected=true],.popup-wrapper .date-cell:focus-visible:not(.preview-start,.preview-end)[aria-selected=true]{outline-offset:2px}.popup-range{display:-ms-flexbox;display:flex}.popup{width:21rem}.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{c as priv_calendar}
@@ -1 +0,0 @@
1
- var __awaiter=this&&this.__awaiter||function(t,r,e,n){function i(t){return t instanceof e?t:new e((function(r){r(t)}))}return new(e||(e=Promise))((function(e,a){function s(t){try{u(n.next(t))}catch(t){a(t)}}function o(t){try{u(n["throw"](t))}catch(t){a(t)}}function u(t){t.done?e(t.value):i(t.value).then(s,o)}u((n=n.apply(t,r||[])).next())}))};var __generator=this&&this.__generator||function(t,r){var e={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,i,a,s;return s={next:o(0),throw:o(1),return:o(2)},typeof Symbol==="function"&&(s[Symbol.iterator]=function(){return this}),s;function o(t){return function(r){return u([t,r])}}function u(o){if(n)throw new TypeError("Generator is already executing.");while(s&&(s=0,o[0]&&(e=0)),e)try{if(n=1,i&&(a=o[0]&2?i["return"]:o[0]?i["throw"]||((a=i["return"])&&a.call(i),0):i.next)&&!(a=a.call(i,o[1])).done)return a;if(i=0,a)o=[o[0]&2,a.value];switch(o[0]){case 0:case 1:a=o;break;case 4:e.label++;return{value:o[1],done:false};case 5:e.label++;i=o[1];o=[0];continue;case 7:o=e.ops.pop();e.trys.pop();continue;default:if(!(a=e.trys,a=a.length>0&&a[a.length-1])&&(o[0]===6||o[0]===2)){e=0;continue}if(o[0]===3&&(!a||o[1]>a[0]&&o[1]<a[3])){e.label=o[1];break}if(o[0]===6&&e.label<a[1]){e.label=a[1];a=o;break}if(a&&e.label<a[2]){e.label=a[2];e.ops.push(o);break}if(a[2])e.ops.pop();e.trys.pop();continue}o=r.call(t,e)}catch(t){o=[6,t];i=0}finally{n=a=0}if(o[0]&5)throw o[1];return{value:o[0]?o[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(t,r,e){if(e||arguments.length===2)for(var n=0,i=r.length,a;n<i;n++){if(a||!(n in r)){if(!a)a=Array.prototype.slice.call(r,0,n);a[n]=r[n]}}return t.concat(a||Array.prototype.slice.call(r))};System.register(["./p-ab8d78cc.system.js","./p-34b5830f.system.js"],(function(t){"use strict";var r,e,n,i,a;return{setters:[function(t){r=t.h},function(t){e=t.i;n=t.c;i=t.e;a=t.f}],execute:function(){t({b:U,c:L,d:K,e:j,f:P,g:D,h:z,i:X,j:S,k:d,l:Q,m:J,n:f,o:w,r:O});var s={salmon:"#ff5f4e",cyan:"#19a1a9",forest:"#088000",sleet:"#7f97ad",midnight:"#2e1b46",lavender:"#8b86ca",periwinkle:"#575195",gray:"#6b6b6b"};var o=t("a",{doughnut:{size:155,colors:[s.forest,s.gray],thickness:.73,padding:25,category:"doughnut"},doughnut1:{size:130,colors:[s.lavender,s.midnight,s.gray],thickness:.5,padding:90,category:"doughnut"},doughnut2:{size:130,colors:[s.cyan,s.salmon,s.gray],thickness:.5,padding:90,category:"doughnut"},doughnut2b:{size:130,colors:[s.periwinkle,s.cyan,s.salmon,s.gray],thickness:.5,padding:90,category:"doughnut"},doughnut3:{size:130,colors:[s.lavender,s.midnight,"#0089e4",s.forest,"#ea8500","#d54f41","#146ca9"],thickness:.5,padding:90,category:"doughnut"},bar:{size:350,colors:[s.forest,s.gray],padding:0,category:"stackedBar"},bar2:{size:400,colors:[s.gray,s.periwinkle,s.cyan,s.salmon],padding:0,category:"stackedBar"},bar2b:{size:400,colors:[s.gray,s.periwinkle,s.midnight,s.cyan,s.salmon],padding:0,category:"stackedBar"},bar3:{size:300,colors:["#0d696e",s.cyan,"#8e4129",s.salmon],padding:0,category:"stackedBar"},bar4:{size:400,colors:[s.salmon,s.cyan,s.periwinkle],padding:0,category:"stackedBar"},bar5:{size:400,colors:[s.gray,s.lavender,s.midnight,"#0089e4",s.forest,"#ea8500","#d54f41","#146ca9"],padding:0,category:"stackedBar"},bar6:{size:400,colors:[s.lavender],padding:0,category:"simpleBar"},bar7:{size:400,colors:[s.periwinkle,s.cyan,s.salmon,s.gray],padding:0,category:"simpleBar"}});function u(t){return t==="percentage"||t==="amount"?"show-values":""}var c=e.formatMessage({id:"chart.hiddenValues",defaultMessage:"Values are hidden when too close together.",description:"Text displayed when a chart has some values hidden"});var h=e.formatMessage({id:"chart.clickToSeeDetails",defaultMessage:"Click or use arrow keys to see details.",description:"Text displayed, guiding user to interact to see more details."});function f(t){return t>999||t<-999?Math.round(t/100)/10+"K":t}function d(t,r,e){return e?Math.round(t*100/r):Math.round(t*1e4/r)/100}function l(t,r){return t*360/r}function v(t){return parseFloat((Math.floor(t*100)/100).toFixed(2))}function g(t,r,e,n){var i=v(t+t*r*Math.cos(Math.PI*e/180));var a=v(t+t*r*Math.sin(Math.PI*e/180));if(n!==undefined){var s=v(t+t*r*Math.cos(Math.PI*n/180));var o=v(t+t*r*Math.sin(Math.PI*n/180));return{x1:i,y1:a,x2:s,y2:o}}return{x:i,y:a}}function p(t,r,e,n,i){var a=v(i/2*t);return"A ".concat(a,", ").concat(a," 0 ").concat(r," ").concat(v(e),", ").concat(v(n))}function b(t,r,e,n,i){var a=(t-r)*(i-n)/(e-r)+n;return a<n?n:a>i?i:a}function m(t){return b(t,300,900,70,150)}function y(t){return Math.round(t/m(t))}function w(t,r){var e=t/r;var n=Math.pow(10,Math.floor(Math.log10(e)));var i=e/n;var a;if(i>5){a=10*n}else if(i>3){a=5*n}else if(i>2){a=3*n}else if(i>1.5){a=2*n}else if(i>1){a=1.5*n}else{a=n}return a}function x(t){if(this.popoverEl&&this.popoverEl.open&&t.key==="Enter"){var r=this.popoverEl.querySelector("button");r&&r.click()}}function k(t,r){if(this.popoverEl&&!this.isTabbing){r.coords={x:t.clientX,y:t.clientY};A(this.popoverEl,r);N(Array.from(this.el.shadowRoot.querySelectorAll("[data-segmentindex")),r)}}function M(t,r){if(this.popoverEl&&this.isTabbing){this.focusedSliceId=r.id;r.coords=i(t.target);r.coords.x=r.coords.x+30;r.coords.y=r.coords.y+30;A(this.popoverEl,r);N(Array.from(this.el.shadowRoot.querySelectorAll("[data-segmentindex")),r)}}function z(t){switch(t.key){case"ArrowUp":case"ArrowLeft":t.preventDefault();this.isTabbing=true;C.call(this);break;case"ArrowRight":case"ArrowDown":t.preventDefault();this.isTabbing=true;_.call(this);break;case"Tab":S.call(this);break;case"Escape":this.popoverEl.open=false;this.userIsNavigating=false;break}}function A(t,r){t.open=false;if(r.title&&r.text){t.sliceDetails=Object.assign({},r);window.setTimeout((function(){return t.open=true}),30)}}function _(){var t=a(document.activeElement);var r=(this.sliceEls.indexOf(t)+1)%this.sliceEls.length;B.call(this,r)}function C(){if(this.sliceEls){var t=a(document.activeElement);var r=this.sliceEls.indexOf(t);if(r===-1){r=0}else if(r===0){r=this.sliceEls.length-1}else{r-=1}B.call(this,r)}}function B(t){var r=this;if(this.sliceEls&&this.el){this.userIsNavigating=true;this.componentWrapperEl.tabIndex=-1;this.el.focusable=false;this.sliceEls.map((function(t){t.tabIndex=-1;t.focusable=false}));this.sliceEls[t].tabIndex=0;this.sliceEls[t].focusable=true;this.sliceEls[t].focus();this.focusedSliceId=this.sliceEls[t].id;window.setTimeout((function(){if(r.popoverEl){r.popoverEl.open=true}}),10)}}function S(){var t=this;this.focusedSliceId=undefined;this.sliceEls&&this.sliceEls.map((function(t){t.tabIndex=-1;t.focusable=false}));this.userIsNavigating=false;window.setTimeout((function(){t.componentWrapperEl.tabIndex=0;t.el.focusable=true;if(t.popoverEl){t.popoverEl.open=false}}),100)}function D(t){return __awaiter(this,void 0,void 0,(function(){var r,e,n;var i=this;return __generator(this,(function(a){this.slicesDetails=[];r=0;e=Array.from(this.el.children);this.total=e.reduce((function(t,r){return t+=parseInt(r.getAttribute("amount")||"0")}),0);n=o[t].colors;if(t==="bar3"&&e.length===2){n=[n[1],n[3]]}e.forEach((function(e,a){var o=parseInt(e.getAttribute("amount")||"0");var u=d(o,i.total,true);var c=a;if(t==="bar5"){c=i.notStartedColor?a:a+1}if(t==="bar6"){c=0}var h={amount:o,perc:u,legend:e.getAttribute("legend"),color:n[c]||s.gray,offset:r,id:"".concat(i.uid,"-").concat(a+1),title:e.getAttribute("popover-title"),text:e.getAttribute("popover-text"),buttonText:e.getAttribute("popover-button-text"),sliceRef:e,inSmallCluster:false,index:a};r+=o;i.slicesDetails.push(h)}));return[2]}))}))}function F(t,r){var e=__spreadArray([],t,true).sort((function(t,r){return t.amount===r.amount?0:t.amount>r.amount?-1:1}));var n=0;e.filter((function(t){return t.amount>0})).forEach((function(t,i){var a=e[i===0?e.length-1:i-1];var s=e[i===e.length-1?0:i+1];var o=d(a.amount,r,true);var u=d(s.amount,r,true);var c=t.perc===0?8:5;var h=t.perc<4;var f=o<c;var l=u<c;var v=h&&(f||l);t.inSmallCluster=v;t.offset=n;n+=t.amount}));return e}function T(t,r,e){var n=l(r,this.total)-90;var i=t/this.total*360;var a=n+i;var s=i>180?"1 1":"0 1";var o=i>180?"1 0":"0 0";var u=this.chartDetails.size/2;var c=this.chartDetails.thickness;var h=1;var f=e==="doughnut";var d=1.5;var v=f?2.25:3;if(i===360){a-=.01}var b=g(u,h,n+d,a);var m=g(u,c,n+v,a);var y="M ".concat(b.x1,", ").concat(b.y1," ");var w=p(h,s,b.x2,b.y2,this.chartDetails.size);var x=" L ".concat(m.x2,", ").concat(m.y2," ");var k=p(c,o,m.x1,m.y1,this.chartDetails.size);return y+w+x+k+" z"}function j(){var t=e.formatMessage({id:"chart.instructions",defaultMessage:"Use arrow keys to browse elements, press Tab to exit.",description:"For screen readers only, instructions on how to interact with the chart component"});return r("div",{id:"chart-instructions"},t)}function I(){return r("defs",null,r("filter",{id:"wmHoverDropShadow"},r("feGaussianBlur",{stdDeviation:"3"}),r("feOffset",{result:"offsetblur"}),r("feFlood",{"flood-color":"#333"}),r("feComposite",{operator:"in",in2:"offsetblur"}),r("feMerge",null,r("feMergeNode",null),r("feMergeNode",{in:"SourceGraphic"}))))}function H(t,r,e){var n=r.map((function(t){return l(t.amount,e)}));var i=n.some((function(r){return r!==0&&r<t}));if(i){var a=n.map((function(r){return r==0?r:Math.max(r,t)}));var s=a.reduce((function(r,e){return r+(e>t&&e!==0?e:0)}),0);var o=a.reduce((function(r,e){return r+(e>t&&e!==0?0:e)}),0);var u=360-o;var c=s-u;var h=c/u;var f=a.map((function(r){return r>t?r-h*r:r==0?0:t}));var d=0;r=r.map((function(t,r){var n=f[r]/360*e;var i=d;d+=n;return Object.assign(Object.assign({},t),{amount:n,offset:i})}))}return r}function K(t){var e=this;var n=this.chartDetails.size+this.chartDetails.padding;var i=t==="doughnut";var a=i?this.slicesDetails:F(this.slicesDetails,this.total);a=H(7,a,this.total);return r("div",{class:"chart-wrapper doughnut-wrapper"},r("svg",{width:n+"px",height:n+"px",id:"graphic-".concat(this.uid),class:"doughnut-svg"},I(),a.map((function(r){return E.call(e,r,t)})),G.call(this),i?r("text",{class:"value",x:"50%",y:"50%","font-size":"1.5rem","font-weight":"500","text-anchor":"middle","dominant-baseline":"middle"},d(a[0].amount,this.total,true)+"%"):r("g",{transform:"translate(".concat(this.chartDetails.padding/2,", ").concat(this.chartDetails.padding/2,")"),"text-anchor":"middle","dominant-baseline":"middle"},a.map((function(t){return t.amount>0&&!t.inSmallCluster?W.call(e,t):""})))))}function N(t,r){t.forEach((function(t){if(t.dataset.segmentindex&&parseInt(t.dataset.segmentindex)!==r.index){t.classList.add("faded")}else{t.classList.remove("faded")}}))}function O(t){t.forEach((function(t){t.classList.remove("faded")}))}function E(t,e){var n=this;var i=d(t.amount,this.total,true)+"%";return!isNaN(t.amount)&&r("g",{transform:"translate(".concat(this.chartDetails.padding/2,", ").concat(this.chartDetails.padding/2,")")},r("path",{id:t.id,class:"segment doughnut-segment",fill:t.amount?t.color:"transparent",d:T.call(this,t.amount,t.offset,e),onClick:function(r){return k.call(n,r,t)},onFocus:function(r){return M.call(n,r,t)},onKeyDown:function(t){return x.call(n,t)},role:"img","aria-label":"".concat(t.legend,", ").concat(i),"data-segmentindex":t.index}))}function G(){return this.isTabbing?r("g",{transform:"translate(".concat(this.chartDetails.padding/2,", ").concat(this.chartDetails.padding/2,")")},r("use",{tabindex:-1,id:"kfbg1",xlinkHref:"#".concat(this.focusedSliceId)}),r("use",{tabindex:-1,id:"kfstroke",xlinkHref:"#".concat(this.focusedSliceId)}),r("use",{tabindex:-1,id:"kfbg2",xlinkHref:"#".concat(this.focusedSliceId)})):""}function W(t){var e=l(t.offset+t.amount/2,this.total);var n=g(this.chartDetails.size/2,1.4,e-90),i=n.x,a=n.y;return r("text",{class:"value",x:i+"px",y:a+"px","data-segmentindex":t.index},"".concat(t.perc>0?t.perc:"<1","%"))}function L(t){var e=this;var n=t==="bar";var i=this.el.shadowRoot.querySelectorAll(".value");if(i.length>0){requestAnimationFrame((function(){var t=[];var r=4;var n=false;i.forEach((function(e){e.classList.remove("hidden");var i=parseInt(e.dataset.value);if(t.length>0&&i!=0){var a=e.getBoundingClientRect().left-r;t.forEach((function(t){var r=parseInt(t.dataset.value);var s=t.getBoundingClientRect().right>a;if(s){var o=i<r?e:t;o.classList.add("hidden");n=true}}))}if(!e.classList.contains("hidden")&&i>0){t.push(e)}}));(e.isBar||e.isDoughnut)&&e.showHiddenValuesMessage(n)}))}return r("div",{class:"chart-wrapper bar-wrapper"},n?r("div",{class:"single-perc"},d(this.slicesDetails[0].amount,this.total,true)+"%"):"",this.chartType==="bar3"&&this.drawAxis(),r("div",{class:"inner-stacked-bar-wrapper ".concat(u(this.valueFormat))},!n?r("div",{class:"values"},this.slicesDetails.map((function(t){return e.renderBarText(t,5)}))):"",r("div",{class:"stacked-bar-segments-wrapper"},this.slicesDetails.map((function(t){return R.call(e,t,5)}))),n?Q.call(this):""))}function R(t,e){var n=this;var i=d(t.amount,this.total,false);var a=this.el.shadowRoot.querySelector(".stacked-bar-segments-wrapper");var s=a?a.offsetWidth:this.el.offsetWidth;var o=i/100*s>=e;var u=o||t.amount==0?"".concat(i,"%"):"".concat(e,"px");var c="";if(this.valueFormat=="percentage"){c="".concat(d(t.amount,this.total,true)," %")}else if(this.valueFormat=="amount"){c=t.amount.toString()}return r("div",{class:"segment stacked-bar-segment ".concat(d(t.amount,this.total,false)===0?"zero":""," ").concat(o?"":"fixed-width"),style:{backgroundColor:t.color,width:u},onClick:function(r){return k.call(n,r,t)},onFocus:function(r){return M.call(n,r,t)},onKeyDown:function(t){return x.call(n,t)},"data-segmentindex":t.index},r("span",{class:"sr-only"},"".concat(t.legend," ").concat(c)))}function U(t){var e=this;var i=this.slicesDetails.map((function(t){return t.amount})).reduce((function(t,r){return t>r?t:r}));var a=parseInt(getComputedStyle(this.el).getPropertyValue("--labelWidth"),10);var s=48;var o=this.el.getBoundingClientRect().width;var c=o-a-s;var h=y(c);var d=w(i,h);var l=h*d;var v=Math.floor((l-i)/d);h-=v;this.el.style.setProperty("--backgroundSize",100/h+"%");this.el.style.setProperty("--labelWidth",this.labelWidth);if(t==="bar7"&&!this.showBarLegend){this.el.style.setProperty("--labelWidth","0px")}var g=[];this.slicesDetails.forEach((function(r){r.legend&&g.push(V(r.legend,e.showBarLegend,t));g.push(q.call(e,r,d,h,i))}));var p=[];for(var b=1;b<=h;b++){var m=f(n(b,d));p.push(r("div",{class:"tick"},r("span",null,m)))}var x=t==="bar6"&&this.showGrid&&this.el.getBoundingClientRect().width>300;return r("div",{class:"chart-wrapper simple-bar-wrapper"},r("div",{class:"chart ".concat(u(this.valueFormat))},x&&r("div",{class:"gridlines"}),r("div",{class:"rows"},g)),x&&r("div",{class:"x-axis","aria-hidden":"true"},r("div",{class:"zero"},r("span",null,"0")),p))}function V(t,e,n){var i=n==="bar7"&&!e?" hidden":"";return r("label",{class:"label".concat(i)},t)}function q(t,e,n,i){var a=this;var s=this.currentChartType==="bar6"?e*n:i;var o=d(t.amount,s,false);var u=o?o+"%":"1px";var c=f(t.amount);var h=this.valueFormat==="amount"?c:"";if(this.currentChartType==="bar6"&&this.valueFormat==="percentage"){h=t.amount+"%"}else if(this.currentChartType==="bar7"&&this.valueFormat==="percentage"){h=(this.total===0?"0":d(t.amount,this.total,true))+"%"}return r("div",{class:"bar segment",style:{backgroundColor:t.color,width:u},onClick:function(r){return k.call(a,r,t)},onFocus:function(r){return M.call(a,r,t)},onKeyDown:function(t){return x.call(a,t)},"data-segmentindex":t.index},r("div",{class:"value"},h))}function P(t){var e=this;if(this.showLegend){var n=this.slicesDetails.reduce((function(t,r){return t=r.inSmallCluster?true:t}),false);this.isDoughnut&&this.showHiddenValuesMessage(n);return r("div",{class:"legend-wrapper"},r("div",{class:"legend ".concat(t," ").concat(this.mode==="bar"?"--top":"--bottom"),"aria-hidden":"true"},this.slicesDetails.map((function(t){var r=e.printModeFormat=="amount"?"".concat(t.amount,"/").concat(e.total):"".concat(d(t.amount,e.total,true),"%");if(!!t.amount||!!t.legend){return J.call(e,{key:t.legend,color:t.color},r,t)}}))),this.isDoughnut&&!this.printMode&&X())}}function J(t,e,n){var i=this;if(e===void 0){e=""}if(n===void 0){n=null}var a=function(t){if(n){n.coords={x:t.clientX,y:t.clientY};A(i.popoverEl,n);N(Array.from(i.el.shadowRoot.querySelectorAll("[data-segmentindex")),n)}};return r("div",{class:"legend-item",onClick:function(t){return a(t)},"data-segmentindex":n?n.index:null},r("div",{class:"legend-color",style:{backgroundColor:t.color}}),r("div",{class:"legend-text"},t.key,e&&r("span",{class:"print-value ".concat(this.printMode?"force-visible":"")},": ",e)))}function Q(){if(this.completionMessage){return r("div",{class:"completion-message"},this.completionMessage)}}function X(){return r("div",{class:"hidden-values-warning hidden"},c,r("br",null),h)}}}}));
@@ -1 +0,0 @@
1
- window.navigator.plugins.length>0&&console.log("Ripple component library","5.4.0"),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.classList.add("wm-tooltip"),o.setAttribute("popover","manual"),o.setAttribute("aria-hidden","true");const t=document.createElement("style");t.textContent="\n.wm-tooltip {\n position: fixed;\n overflow: hidden;\n pointer-events: none;\n line-height: normal;\n font-family: inherit;\n font-size: 0.875rem;\n text-transform: none;\n font-weight: normal;\n background: var(--wmcolor-tooltip-background);\n color: var(--wmcolor-tooltip-text);\n z-index: 999999;\n max-width: var(--wmTooltipMaxWidth, 13.75rem);\n margin-right: 1.5rem;\n padding: 0.375rem;\n transition-property: opacity;\n transition-delay: 0s;\n opacity: 0;\n inset: unset;\n top: 0;\n left: 0;\n transform: translateZ(0);\n will-change: transform;\n transform: translate(var(--wmTooltipLeft), var(--wmTooltipTop));\n border: none;\n}\n\n.wm-tooltip:popover-open {\n opacity: 0;\n}\n\n.wm-tooltip.show {\n transition-delay: 500ms;\n opacity: 1;\n}\n",document.head.appendChild(t),n.appendChild(o),document.querySelector("body").appendChild(n);
@@ -1 +0,0 @@
1
- System.register(["./p-ab8d78cc.system.js"],(function(t){"use strict";var o,e,r,n;return{setters:[function(t){o=t.r;e=t.c;r=t.h;n=t.g}],execute:function(){var i=":host{list-style:none;border-bottom:1px solid var(--wmcolor-navigator-item-border);width:100%;display:block;cursor:pointer}:host .navoption{color:var(--wmcolor-navigator-item-text);padding:0.9375rem 1.25rem;background:var(--wmcolor-navigator-item-background);font-size:0.875rem}:host .navoption.selected,:host .navoption:hover{background:var(--wmcolor-navigator-item-background-hover)}:host .navoption.focused:not(.selected){background:var(--wmcolor-navigator-item-background-focus);opacity:1}";var a=t("priv_navigator_item",function(){function t(t){o(this,t);this.keydownOnNavItem=e(this,"keydownOnNavItem",7);this.selected=false;this.focused=false;this.link=""}t.prototype.handleKeyDown=function(t){var o=t.key;var e=this.el;if(o!=="Tab"){t.preventDefault()}this.keydownOnNavItem.emit({navItem:e,key:o})};t.prototype.render=function(){var t=this.selected?"selected":"";var o=this.focused?"focused":"";return r("div",{class:"navoption ".concat(t," ").concat(o)},r("slot",null))};Object.defineProperty(t.prototype,"el",{get:function(){return n(this)},enumerable:false,configurable:true});return t}());a.style=i}}}));
@@ -1 +0,0 @@
1
- import{r as t,c as r,h as i,H as s,g as a}from"./p-568c595f.js";import{a as o}from"./p-2732bddd.js";import{n as e,o as n,i as h}from"./p-e995f7f0.js";const c=class{constructor(i){t(this,i),this.wmNavigatorLogout=r(this,"wmNavigatorLogout",7),this.retrievedInfo=!this.loadFromUserinfo,this.parsedProducts=[],this.openRight=!1,this.userName=void 0,this.email=void 0,this.authType=1,this.connectionName=void 0,this.logoutUrl=void 0,this.products=void 0,this.loadFromUserinfo=!1,this.isOpen=!1,this.itemIndexToFocus=0}isSafeUrl(t){let r=!1;return["digitalmeasures\\.com","evalkit\\.info","evaluationkit\\.com","evaluationkit\\.info","lat_ams\\.com","livetext\\.com","smartcatalogiq\\.com","smartcatalogiq\\.net","smartcatalogiq\\.us","taskstream\\.com","vialivetext\\.com","watermarkinsights\\.com"].forEach((i=>{t&&t.match(`^https://(.*.)?${i}(/.*)?$`)&&(r=!0)})),r}async componentWillLoad(){this.userName||console.error("wm-navigator: user-name is a required property."),await this.parseData(),this.setFocusIndex()}async parseData(){this.loadFromUserinfo?await(async()=>{const t=await fetch("/platform/navigator/userinfo");if(t&&t.ok)return await t.json();throw new Error(t.statusText)})().then((t=>{this.email=t.email,this.currentProductId=t.current_product_id,this.parsedProducts=this.productKeysToCamelCase(t.products),this.logoutUrl=this.logoutUrl?this.logoutUrl:t.logout_url,this.connectionName=this.connectionName?this.connectionName:t.connection_name,this.email&&this.currentProductId&&(this.retrievedInfo=!0)})).catch((t=>{console.error(t)})):(this.currentProductId=o(this.el),this.products&&(this.parsedProducts="string"==typeof this.products?JSON.parse(this.products):this.products,this.parsedProducts=this.productKeysToCamelCase(this.parsedProducts))),this.parsedProducts.sort(((t,r)=>t.name<r.name?-1:1))}productKeysToCamelCase(t){return t.map((t=>{const r=Object.keys(t);let i={};return r.forEach((r=>{i[e(r)]=t[r]})),i}))}setFocusIndex(){if(this.parsedProducts.length>1){const t=this.getProduct(this.currentProductId);t&&(this.itemIndexToFocus=this.parsedProducts.indexOf(t))}}handleKeys(t){switch(t.key){case"Escape":t.preventDefault(),this.closeMenu();break;case"ArrowDown":case"ArrowUp":t.preventDefault(),this.isOpen||(this.itemIndexToFocus=n(this.itemIndexToFocus,t.key,this.navigatorItems.length),this.openMenu())}}handleKeydown(t){const r=t.detail.key,i=t.detail.navItem;switch(r){case"Tab":this.closeMenu(!1);break;case"Enter":case" ":i.click();break;case"ArrowDown":case"ArrowUp":const t=this.itemIndexToFocus;this.itemIndexToFocus=n(this.itemIndexToFocus,r,this.navigatorItems.length),this.focusItem(),this.unfocusItem(t)}}handleClick(t){t.target!==this.el&&!this.el.contains(t.target)&&this.isOpen&&this.closeMenu(!1)}handleButtonClick(){this.isOpen?this.closeMenu():this.openMenu()}openMenu(){if(this.wrapperEl){const t=this.wrapperEl.clientWidth,r=this.el.getBoundingClientRect().left,i=document.documentElement.clientWidth-this.el.getBoundingClientRect().right;this.openRight=t>r&&i>r}this.isOpen=!0,this.focusItem()}closeMenu(t=!0){this.isOpen=!1,window.requestAnimationFrame((()=>{this.unfocusItem(this.itemIndexToFocus),this.setFocusIndex(),t&&this.buttonFocusHandler()}))}focusItem(){const t=this.navigatorItems[this.itemIndexToFocus];t.tabIndex=0,t.focused=!0,window.requestAnimationFrame((()=>t.focus()))}unfocusItem(t){const r=this.navigatorItems[t];r.tabIndex=-1,r.focused=!1}buttonFocusHandler(){this.el.shadowRoot.querySelector("priv-navigator-button").shadowRoot.querySelector("button").focus()}renderUserInfo(){return i("div",{class:"user",id:"wm-nav-user","aria-label":h.formatMessage({id:"navigator.userinfoLabel",defaultMessage:"for {name}, email {email}"},{name:this.userName,email:this.email})},i("p",null,this.userName),i("p",null,this.email))}setAltText(){return h.formatMessage(this.parsedProducts.length>1?{id:"navigator.userinfoAndProductNavigator",defaultMessage:"User information and product navigator"}:{id:"navigator.userinfo",defaultMessage:"User information"})}renderHeading(){return i("h2",null,h.formatMessage({id:"navigator.watermarkApps",defaultMessage:"Watermark Apps",description:"Applications made by Watermark Insights"}))}renderList(){return i("ul",{role:"listbox","aria-label":`${h.formatMessage({id:"navigator.WatermarkAppNavigation",defaultMessage:"Watermark App Navigation",description:"list of applications by Watermark Insights"})}`,"aria-describedby":"wm-nav-user"},this.parsedProducts.length>1&&this.renderProductOptions(),this.renderLogoutOption())}renderProductOptions(){return this.parsedProducts.map((t=>{let r,s,a,o;if(r=t.name,s=t.iconUrl,o=this.setProductOnClick(t.id),r&&s)return a=this.currentProductId===t.id,i("priv-navigator-item",{selected:a,id:t.id,onClick:o,role:"option","aria-label":r},i("img",{src:s,alt:r}))}))}setProductOnClick(t){const r=this.getProduct(t);if(this.currentProductId===t)return()=>{};if(r){if(this.loadFromUserinfo||2===this.authType){const t=r.linkUrl;return this.isSafeUrl(t)?()=>window.location.href=t:void console.error(`"${t}" is not a safe url`)}if(3===this.authType){const t=this.connectionName?`/?connection_name=${this.connectionName}`:"",i=r.samlLinkUrl;return this.isSafeUrl(i)?()=>window.location.href=i+t:void console.error(`"${i}" is not a safe url`)}}}renderLogoutOption(){return i("priv-navigator-item",{class:"logout",selected:!(this.parsedProducts.length>1),id:"nav-logout",onClick:this.setLogoutOnclick(),role:"option"},i("span",{class:"logout"},h.formatMessage({id:"navigator.logout",defaultMessage:"Log Out"})))}setLogoutOnclick(){return()=>{this.wmNavigatorLogout.emit();const t=this.logoutUrl;this.isSafeUrl(t)?window.location.href=t:console.error(`"${t}" is not a safe url`)}}get navigatorItems(){return Array.from(this.el.shadowRoot.querySelectorAll("priv-navigator-item"))}getProduct(t){return this.parsedProducts.find((r=>r.id===t))}render(){return this.retrievedInfo?i(s,null,i("priv-navigator-button",{expanded:this.isOpen,altText:this.setAltText()}),i("div",{class:`wrapper ${this.isOpen?"":"hide"} ${this.openRight?"right":""}`,ref:t=>this.wrapperEl=t},this.renderUserInfo(),this.parsedProducts.length>1&&this.renderHeading(),this.renderList())):""}static get delegatesFocus(){return!0}get el(){return a(this)}static get watchers(){return{products:["parseData"]}}};c.style=":host{--wmcolor-navigator-background:var(--wmcolor-background);--wmcolor-navigator-header-background:var(--wmcolor-brand-dark);--wmcolor-navigator-header-text:var(--wmcolor-text-ondark);--wmcolor-navigator-item-background-focus:var(--wmcolor-interactive-background-focus);--wmcolor-navigator-item-background-hover:var(--wmcolor-interactive-background-hover);--wmcolor-navigator-item-background:var(--wmcolor-background);--wmcolor-navigator-item-border:var(--wmcolor-border);--wmcolor-navigator-item-text:var(--wmcolor-text);--wmcolor-navigator-user-background:var(--wmcolor-background-readonly);min-width:0;position:relative;display:inline-block}:host .wrapper{overflow:auto;font-size:1.125rem;min-width:13.125rem;width:auto;max-height:80vh;text-align:left;position:absolute;z-index:50;top:100%;right:20px;left:auto;background:var(--wmcolor-navigator-background);letter-spacing:normal;-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-origin:center top;-webkit-transform-origin:center top;-moz-transform-origin:center top;transform-origin:center top;-ms-transform:scale(1, 1);-webkit-transform:scale(1, 1);-moz-transform:scale(1, 1);transform:scale(1, 1)}:host .wrapper .user{background:var(--wmcolor-navigator-user-background);padding:0.625rem 1.25rem;font-size:0.875rem}:host .wrapper .user p{margin:0}:host .wrapper .user p:first-child{font-weight:700;text-transform:capitalize}:host .wrapper h2{background:var(--wmcolor-navigator-header-background);color:var(--wmcolor-navigator-header-text);font-weight:700;margin:0;padding:0.625rem 1.25rem;font-size:0.875rem}:host .wrapper [role=listbox]{list-style:none;margin:0;padding-left:0}:host .wrapper.hide{-ms-transform:scale(1, 0);-webkit-transform:scale(1, 0);-moz-transform:scale(1, 0);transform:scale(1, 0)}:host .wrapper.right{right:auto;left:20px}:host img{-webkit-transform:scale(0.8);transform:scale(0.8);-webkit-transform-origin:left center;transform-origin:left center;display:block}:host .logout{text-align:center;text-transform:capitalize}priv-navigator-item:focus{outline:none}";export{c as wm_navigator}
@@ -1 +0,0 @@
1
- import{r as e,f as t,h as r,H as o,g as n,c as a}from"./p-568c595f.js";import{g as p,d as s,i,x as l}from"./p-e995f7f0.js";import{a as h,h as c,g as m,r as d,c as w,d as g,e as b,f as x,l as u,j as f,m as v}from"./p-0f0466c6.js";const k=class{constructor(r){e(this,r),this.uid=p(),this.slicesDetails=[],this.barLabelsWidth=this.el.parentElement.barLabelsWidth,this.debouncedUpdate=s((async()=>{t(this.el)}),10),this.label=void 0,this.subinfo=void 0,this.completionMessage=void 0,this.showLegend=!0,this.printMode=!1,this.printModeFormat="amount",this.isTabbing=!1,this.mode=void 0,this.userIsNavigating=!1,this.focusedSliceId=void 0}get popoverEl(){return this.el.shadowRoot.querySelector("priv-chart-popover")}get sliceEls(){return Array.from(this.el.shadowRoot.querySelectorAll(".segment"))}get chartDetails(){return this.mode?h[this.mode]:void 0}get ariaLabelText(){let e=`${this.label}`;return this.subinfo&&(e+=` ${this.subinfo}`),e}get chartRoleDescription(){return i.formatMessage({id:"chart.roleDescription",defaultMessage:"Interactive chart",description:"For screen readers only, a description clarifying the role of the chart widget"})}toggleTabbingOn(){this.isTabbing=!0}toggleTabbingOff(){this.isTabbing=!1}handleKeydown(e){c.call(this,e)}componentWillLoad(){this.label||console.error("For accessibility purposes, you must provide a label for the chart. See https://components.watermarkinsights.com/chart for more information."),2!==this.el.children.length&&console.warn("wm-progress-indicator component must have 2 wm-progress-slice children."),this.el.parentElement.addEventListener("wmProgressMonitorModeChange",(e=>this.mode=e.detail)),new ResizeObserver((()=>this.debouncedUpdate())).observe(this.el)}async handleSliceUpdate(){await m.call(this,this.mode),t(this.el)}handleModeUpdate(){this.mode&&m.call(this,this.mode)}handlePopoverOpenChanged(e){if(!e.detail){const e=Array.from(this.el.shadowRoot.querySelectorAll("[data-segmentindex]"));d(e)}}renderBarOrDoughnut(){return this.total>0&&"bar"===this.mode?w.call(this,this.mode):g.call(this,this.mode)}render(){return r(o,{onBlur:()=>f.call(this)},r("div",{ref:e=>this.componentWrapperEl=e,class:`component-wrapper ${this.mode} ${this.isTabbing&&!this.userIsNavigating?"user-is-tabbing":""}`,role:"application","aria-label":this.ariaLabelText,tabindex:"0","aria-roledescription":this.chartRoleDescription,"aria-describedby":"chart-instructions"},r("label",{id:`label-${this.uid}`,class:"label "+(this.barLabelsWidth&&"bar"===this.mode?"custom-width":""),style:{"--custom-label-width":this.barLabelsWidth},htmlFor:`graphic-${this.uid}`},r("span",{class:"label-text"},this.label),this.subinfo?r("span",{class:"subinfo"},this.subinfo):""),this.mode&&this.renderBarOrDoughnut(),"doughnut"===this.mode?x.call(this,this.mode):"",r("priv-chart-popover",{class:this.isTabbing?"user-is-tabbing":"",onIntChartPopoverOpenChanged:e=>this.handlePopoverOpenChanged(e)}),"doughnut"===this.mode?u.call(this):""),b())}static get delegatesFocus(){return!0}get el(){return n(this)}static get watchers(){return{mode:["handleModeUpdate"]}}};k.style=":host{--wmcolor-chart-label-text-negative:var(--wmcolor-text-negative);--wmcolor-chart-label-text-positive:var(--wmcolor-text-positive);--wmcolor-chart-label-text:var(--wmcolor-text);--wmcolor-chart-subinfo-text:var(--wmcolor-text);--wmcolor-chart-value-text:var(--wmcolor-text);display:block}:host .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;outline:none;}:host .component-wrapper:focus-visible{outline:3px solid var(--wmcolor-interactive-focus);outline-offset:2px}:host .component-wrapper .label{display:block;margin:0;padding-bottom:0.25rem;font-weight:600;position:relative}:host .component-wrapper .label .subinfo{display:block;font-weight:normal;font-style:italic;bottom:0.25rem;width:100%;color:var(--wmcolor-chart-subinfo-text)}:host .component-wrapper .label.custom-width{width:var(--custom-label-width)}:host .component-wrapper .label.--none{display:none}:host .component-wrapper .doughnut-svg,:host .component-wrapper .inner-stacked-bar-wrapper{overflow:visible}:host .component-wrapper .bar-wrapper{-ms-flex-positive:1;flex-grow:1;width:100%}:host .component-wrapper .bar-wrapper .inner-stacked-bar-wrapper{width:100%}:host .component-wrapper .bar-wrapper .inner-stacked-bar-wrapper .values{display:-ms-flexbox;display:flex;gap:2px;margin-bottom:8px}:host .component-wrapper .bar-wrapper .inner-stacked-bar-wrapper .stacked-bar-segments-wrapper{display:-ms-flexbox;display:flex;gap:2px}:host .component-wrapper .bar-wrapper .inner-stacked-bar-wrapper .stacked-bar-segments-wrapper .stacked-bar-segment{height:30px;cursor:pointer}:host .component-wrapper .segment{print-color-adjust:exact;-webkit-print-color-adjust:exact}:host .component-wrapper .segment.fixed-width{-ms-flex-negative:0;flex-shrink:0}:host .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{cursor:pointer}:host .component-wrapper .value-wrapper{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center}:host .component-wrapper .value-wrapper .fixed-width{-ms-flex-negative:0;flex-shrink:0}:host .component-wrapper .value-wrapper .value.hidden{visibility:hidden}:host .component-wrapper .faded{opacity:0.3}:host .component-wrapper path:active,:host .component-wrapper path:hover,:host .component-wrapper path:focus,:host .component-wrapper .stacked-bar-segment:active,:host .component-wrapper .stacked-bar-segment:hover,:host .component-wrapper .stacked-bar-segment:focus{outline:none}:host .component-wrapper .stacked-bar-segment:active.stacked-bar-segment:not(:focus-visible),:host .component-wrapper .stacked-bar-segment:hover.stacked-bar-segment:not(:focus-visible),:host .component-wrapper .stacked-bar-segment:focus.stacked-bar-segment:not(:focus-visible){-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:not(:focus-visible),:host .component-wrapper path:hover.doughnut-segment:not(:focus-visible),:host .component-wrapper path:focus.doughnut-segment:not(:focus-visible),:host .component-wrapper .stacked-bar-segment:active.doughnut-segment:not(:focus-visible),:host .component-wrapper .stacked-bar-segment:hover.doughnut-segment:not(:focus-visible),:host .component-wrapper .stacked-bar-segment:focus.doughnut-segment:not(:focus-visible){-webkit-filter:url(#wmHoverDropShadow);filter:url(#wmHoverDropShadow)}:host .component-wrapper path::-moz-focus-inner,:host .component-wrapper .stacked-bar-segment::-moz-focus-inner{border:0;outline:none}:host .component-wrapper .stacked-bar-segment:focus-visible{outline:3px solid var(--wmcolor-interactive-focus);outline-offset:2px;-webkit-box-shadow:0 0 0 7px white;box-shadow:0 0 0 7px white;z-index:1}:host .component-wrapper #kfbg1{stroke:white;stroke-width:10px}:host .component-wrapper #kfstroke{stroke:var(--wmcolor-interactive-focus);stroke-width:6px}:host .component-wrapper #kfbg2{stroke:white;stroke-width:2px}:host .component-wrapper.doughnut{width:300px}:host .component-wrapper.doughnut1 label,:host .component-wrapper.doughnut1 .label-text,:host .component-wrapper.doughnut2 label,:host .component-wrapper.doughnut2 .label-text,:host .component-wrapper.doughnut2b label,:host .component-wrapper.doughnut2b .label-text,:host .component-wrapper.doughnut3 label,:host .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.doughnut{-ms-flex-align:center;align-items:center}:host .component-wrapper.doughnut label{text-align:center;width:100%;padding-bottom:1.5rem}:host .component-wrapper.doughnut label .subinfo{position:absolute}:host .component-wrapper.doughnut .completion-message{padding-top:0.625rem}:host .component-wrapper.bar{-ms-flex-align:start;align-items:flex-start}:host .component-wrapper.bar label{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}:host .component-wrapper.bar label .subinfo{position:initial}:host .component-wrapper.bar .chart-wrapper{display:-ms-flexbox;display:flex}:host .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.bar .chart-wrapper .inner-stacked-bar-wrapper{-ms-flex:1;flex:1}:host .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.bar{-ms-flex-direction:row;flex-direction:row}:host .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.bar .bar-wrapper{-ms-flex-direction:row-reverse;flex-direction:row-reverse}:host .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,:host .component-wrapper.bar2b,:host .component-wrapper.bar3,:host .component-wrapper.bar4,:host .component-wrapper.bar5{-ms-flex-align:start;align-items:flex-start}:host .component-wrapper.bar2b .inner-stacked-bar-wrapper,:host .component-wrapper.bar4 .inner-stacked-bar-wrapper,:host .component-wrapper.bar5 .inner-stacked-bar-wrapper{height:30px;margin-bottom:0}:host .component-wrapper.bar2b .inner-stacked-bar-wrapper.show-values,:host .component-wrapper.bar4 .inner-stacked-bar-wrapper.show-values,:host .component-wrapper.bar5 .inner-stacked-bar-wrapper.show-values{height:60px;margin-top:0}:host .component-wrapper.bar3 .chart-wrapper{position:relative;height:100px}:host .component-wrapper.bar3 .chart-wrapper .inner-stacked-bar-wrapper{position:absolute;top:35px;left:0;right:0;bottom:0;height:30px}:host .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{stroke:var(--wmcolor-chart-gridline);stroke-width:1px}:host .component-wrapper.bar3 .chart-wrapper .axis text{-webkit-transform:translate(4px, 24px);transform:translate(4px, 24px);text-anchor:middle}:host .component-wrapper.bar3 .hidden-values-warning{margin-top:1.25rem}:host .component-wrapper.bar6,:host .component-wrapper.bar7{--chartPadding:48px;-ms-flex-align:start;align-items:flex-start}:host .component-wrapper.bar6 .chart-wrapper,:host .component-wrapper.bar7 .chart-wrapper{width:100%}:host .component-wrapper.bar6 .chart,:host .component-wrapper.bar7 .chart{position:relative;padding-right:var(--chartPadding)}:host .component-wrapper.bar6 .gridlines,:host .component-wrapper.bar7 .gridlines{position:absolute;left:var(--labelWidth);right:var(--chartPadding);top:0;bottom:0;background-image:linear-gradient(90deg, var(--wmcolor-chart-gridline) 1px, transparent 1px);background-position:-1px;border-left:1px solid var(--wmcolor-chart-gridline);border-bottom:1px solid var(--wmcolor-chart-gridline);background-size:var(--backgroundSize)}:host .component-wrapper.bar6 .rows,:host .component-wrapper.bar7 .rows{display:grid;grid-template-columns:var(--labelWidth) auto;grid-auto-rows:minmax(30px, 1fr);-ms-flex-align:center;align-items:center;position:relative;z-index:1}:host .component-wrapper.bar6 .rows .label,:host .component-wrapper.bar7 .rows .label{font-weight:400;padding:0 0.75rem 0 0;text-align:right;margin:0.75rem 0}:host .component-wrapper.bar6 .rows .label.hidden,:host .component-wrapper.bar7 .rows .label.hidden{visibility:hidden;white-space:nowrap}:host .component-wrapper.bar6 .bar,:host .component-wrapper.bar7 .bar{height:30px;position:relative}:host .component-wrapper.bar6 .bar .value,:host .component-wrapper.bar7 .bar .value{position:absolute;top:50%;right:-0.5rem;-webkit-transform:translate(100%, -50%);transform:translate(100%, -50%)}:host .component-wrapper.bar6 .x-axis,:host .component-wrapper.bar7 .x-axis{margin-left:var(--labelWidth);margin-right:var(--chartPadding);display:-ms-flexbox;display:flex;postion:relative}:host .component-wrapper.bar6 .tick,:host .component-wrapper.bar7 .tick{-ms-flex:1;flex:1;text-align:right}:host .component-wrapper.bar6 .tick span,:host .component-wrapper.bar7 .tick span{-webkit-transform:translateX(50%);transform:translateX(50%);display:inline-block}:host .component-wrapper.bar6 .zero,:host .component-wrapper.bar7 .zero{position:absolute;-webkit-transform:translateX(-50%);transform:translateX(-50%)}:host .component-wrapper.bar6 .bar:active,:host .component-wrapper.bar6 .bar:hover,:host .component-wrapper.bar6 .bar:focus,:host .component-wrapper.bar7 .bar:active,:host .component-wrapper.bar7 .bar:hover,:host .component-wrapper.bar7 .bar:focus{outline:none}:host .component-wrapper.bar6 .bar:active.bar:not(:focus-visible),:host .component-wrapper.bar6 .bar:hover.bar:not(:focus-visible),:host .component-wrapper.bar6 .bar:focus.bar:not(:focus-visible),:host .component-wrapper.bar7 .bar:active.bar:not(:focus-visible),:host .component-wrapper.bar7 .bar:hover.bar:not(:focus-visible),:host .component-wrapper.bar7 .bar:focus.bar:not(:focus-visible){-webkit-box-shadow:0px 0px 6px #333;-moz-box-shadow:0px 0px 6px #333;box-shadow:0px 0px 6px #333}:host .component-wrapper.bar6 .bar:focus-visible,:host .component-wrapper.bar7 .bar:focus-visible{outline:3px solid var(--wmcolor-interactive-focus);outline-offset:2px;-webkit-box-shadow:0 0 0 7px white;box-shadow:0 0 0 7px white;z-index:1}:host .component-wrapper.left-label{-ms-flex-direction:row;flex-direction:row}:host .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 .component-wrapper .hidden-values-warning{font-size:0.75rem;font-style:italic;max-width:100%}:host .component-wrapper .hidden-values-warning.hidden{display:none}@media print{:host .component-wrapper .hidden-values-warning{display:none}}:host #chart-instructions{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 .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{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.bar6{display:none}:host .component-wrapper .legend-wrapper .legend.--top{margin-top:-0.75rem}:host .component-wrapper .legend-wrapper .legend.--top .legend-item{padding-top:0.75rem}:host .component-wrapper .legend-wrapper .legend.--top .legend-color{top:0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom{margin-bottom:-0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom .legend-item{padding-bottom:0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom .legend-color{top:-0.75rem}:host .component-wrapper .legend-wrapper .legend .legend-item{position:relative}:host .component-wrapper .legend-wrapper .legend .legend-item.faded{opacity:0.3}:host .component-wrapper .legend-wrapper .legend .legend-item:not(:last-of-type){padding-right:1.25rem}:host .component-wrapper .legend-wrapper .legend .legend-text{font-size:0.875rem;padding-left:1rem;line-height:1}:host .component-wrapper .legend-wrapper .legend .legend-color{position:absolute;left:0;bottom:0;margin:auto;width:0.6875rem;height:0.6875rem;print-color-adjust:exact;-webkit-print-color-adjust:exact}:host .component-wrapper .legend-wrapper .legend .print-value{display:none}:host .component-wrapper .legend-wrapper .legend .print-value.force-visible{display:unset}@media print{:host .component-wrapper .legend-wrapper .legend .print-value{display:unset}}:host .component-wrapper .legend-wrapper .legend.bar3{padding-bottom:1.25rem}";const y=class{constructor(r){e(this,r),this.wmProgressMonitorModeChange=a(this,"wmProgressMonitorModeChange",7),this.doughnutWidth=300,this.modeInitialized=!1,this.debouncedUpdate=s((()=>t(this.el)),50),this.breakpoint=void 0,this.groupLegend=void 0,this.barLabelsWidth=void 0}get parsedBreakpoint(){const e=this.parseToNum(this.breakpoint?this.breakpoint:this.el.children.length);return e>=20?e:e*this.doughnutWidth}get mode(){return this.el.clientWidth>this.parsedBreakpoint?"doughnut":"bar"}get isBar(){return!1}get isDoughnut(){return!1}componentWillLoad(){new ResizeObserver((()=>this.debouncedUpdate())).observe(this.el)}componentDidLoad(){this.wmProgressMonitorModeChange.emit(this.mode),this.modeInitialized=!0}componentWillUpdate(){this.prevMode!==this.mode&&this.wmProgressMonitorModeChange.emit(this.mode),this.prevMode=this.mode}parseToNum(e){const t=e.toString().replace("px","");return parseInt(t)}renderLegend(){const e=l(this.groupLegend),t=h.bar.colors;return r("div",{class:"legend-wrapper"},r("div",{class:"legend"},e.map(((e,r)=>v.call(this,{key:e,color:t[r]})))))}render(){return r(o,{class:"doughnut"===this.mode?"row":"column"},this.modeInitialized&&this.groupLegend&&"bar"===this.mode&&this.renderLegend(),this.modeInitialized&&r("slot",null))}static get delegatesFocus(){return!0}get el(){return n(this)}};y.style=":host .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 .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 .legend-wrapper .legend.bar6{display:none}:host .legend-wrapper .legend.--top{margin-top:-0.75rem}:host .legend-wrapper .legend.--top .legend-item{padding-top:0.75rem}:host .legend-wrapper .legend.--top .legend-color{top:0.75rem}:host .legend-wrapper .legend.--bottom{margin-bottom:-0.75rem}:host .legend-wrapper .legend.--bottom .legend-item{padding-bottom:0.75rem}:host .legend-wrapper .legend.--bottom .legend-color{top:-0.75rem}:host .legend-wrapper .legend .legend-item{position:relative}:host .legend-wrapper .legend .legend-item.faded{opacity:0.3}:host .legend-wrapper .legend .legend-item:not(:last-of-type){padding-right:1.25rem}:host .legend-wrapper .legend .legend-text{font-size:0.875rem;padding-left:1rem;line-height:1}:host .legend-wrapper .legend .legend-color{position:absolute;left:0;bottom:0;margin:auto;width:0.6875rem;height:0.6875rem;print-color-adjust:exact;-webkit-print-color-adjust:exact}:host .legend-wrapper .legend .print-value{display:none}:host .legend-wrapper .legend .print-value.force-visible{display:unset}@media print{:host .legend-wrapper .legend .print-value{display:unset}}:host .legend-wrapper .legend.bar3{padding-bottom:1.25rem}:host{display:-ms-flexbox;display:flex}:host .legend-wrapper{-ms-flex-align:start;align-items:flex-start}:host(.row){-ms-flex-direction:row;flex-direction:row}:host(.column){-ms-flex-direction:column;flex-direction:column}:host(.column) .legend-wrapper{margin-bottom:2rem}:host(.column) .legend-wrapper .legend{padding-bottom:0}:host(.column) ::slotted(wm-progress-indicator:not(:last-of-type)){margin-bottom:2.5rem}";const z=class{constructor(t){e(this,t),this.wmProgressSliceUpdated=a(this,"wmProgressSliceUpdated",7),this.legend=void 0,this.amount=void 0,this.popoverTitle=void 0,this.popoverText=void 0,this.popoverButtonText=void 0}componentDidUpdate(){this.wmProgressSliceUpdated.emit()}};export{k as wm_progress_indicator,y as wm_progress_monitor,z as wm_progress_slice}
@@ -1 +0,0 @@
1
- var __awaiter=this&&this.__awaiter||function(e,t,r,o){function n(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,a){function i(e){try{s(o.next(e))}catch(e){a(e)}}function p(e){try{s(o["throw"](e))}catch(e){a(e)}}function s(e){e.done?r(e.value):n(e.value).then(i,p)}s((o=o.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var r={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},o,n,a,i;return i={next:p(0),throw:p(1),return:p(2)},typeof Symbol==="function"&&(i[Symbol.iterator]=function(){return this}),i;function p(e){return function(t){return s([e,t])}}function s(p){if(o)throw new TypeError("Generator is already executing.");while(i&&(i=0,p[0]&&(r=0)),r)try{if(o=1,n&&(a=p[0]&2?n["return"]:p[0]?n["throw"]||((a=n["return"])&&a.call(n),0):n.next)&&!(a=a.call(n,p[1])).done)return a;if(n=0,a)p=[p[0]&2,a.value];switch(p[0]){case 0:case 1:a=p;break;case 4:r.label++;return{value:p[1],done:false};case 5:r.label++;n=p[1];p=[0];continue;case 7:p=r.ops.pop();r.trys.pop();continue;default:if(!(a=r.trys,a=a.length>0&&a[a.length-1])&&(p[0]===6||p[0]===2)){r=0;continue}if(p[0]===3&&(!a||p[1]>a[0]&&p[1]<a[3])){r.label=p[1];break}if(p[0]===6&&r.label<a[1]){r.label=a[1];a=p;break}if(a&&r.label<a[2]){r.label=a[2];r.ops.push(p);break}if(a[2])r.ops.pop();r.trys.pop();continue}p=t.call(e,r)}catch(e){p=[6,e];n=0}finally{o=a=0}if(p[0]&5)throw p[1];return{value:p[0]?p[1]:void 0,done:true}}};System.register(["./p-ab8d78cc.system.js","./p-34b5830f.system.js","./p-97aaa344.system.js"],(function(e){"use strict";var t,r,o,n,a,i,p,s,l,c,h,m,d,u,b,w,g,f,x,v,k;return{setters:[function(e){t=e.r;r=e.f;o=e.h;n=e.H;a=e.g;i=e.c},function(e){p=e.g;s=e.d;l=e.i;c=e.x},function(e){h=e.a;m=e.h;d=e.g;u=e.r;b=e.c;w=e.d;g=e.e;f=e.f;x=e.l;v=e.j;k=e.m}],execute:function(){var y=":host{--wmcolor-chart-label-text-negative:var(--wmcolor-text-negative);--wmcolor-chart-label-text-positive:var(--wmcolor-text-positive);--wmcolor-chart-label-text:var(--wmcolor-text);--wmcolor-chart-subinfo-text:var(--wmcolor-text);--wmcolor-chart-value-text:var(--wmcolor-text);display:block}:host .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;outline:none;}:host .component-wrapper:focus-visible{outline:3px solid var(--wmcolor-interactive-focus);outline-offset:2px}:host .component-wrapper .label{display:block;margin:0;padding-bottom:0.25rem;font-weight:600;position:relative}:host .component-wrapper .label .subinfo{display:block;font-weight:normal;font-style:italic;bottom:0.25rem;width:100%;color:var(--wmcolor-chart-subinfo-text)}:host .component-wrapper .label.custom-width{width:var(--custom-label-width)}:host .component-wrapper .label.--none{display:none}:host .component-wrapper .doughnut-svg,:host .component-wrapper .inner-stacked-bar-wrapper{overflow:visible}:host .component-wrapper .bar-wrapper{-ms-flex-positive:1;flex-grow:1;width:100%}:host .component-wrapper .bar-wrapper .inner-stacked-bar-wrapper{width:100%}:host .component-wrapper .bar-wrapper .inner-stacked-bar-wrapper .values{display:-ms-flexbox;display:flex;gap:2px;margin-bottom:8px}:host .component-wrapper .bar-wrapper .inner-stacked-bar-wrapper .stacked-bar-segments-wrapper{display:-ms-flexbox;display:flex;gap:2px}:host .component-wrapper .bar-wrapper .inner-stacked-bar-wrapper .stacked-bar-segments-wrapper .stacked-bar-segment{height:30px;cursor:pointer}:host .component-wrapper .segment{print-color-adjust:exact;-webkit-print-color-adjust:exact}:host .component-wrapper .segment.fixed-width{-ms-flex-negative:0;flex-shrink:0}:host .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{cursor:pointer}:host .component-wrapper .value-wrapper{display:-ms-flexbox;display:flex;-ms-flex-pack:center;justify-content:center}:host .component-wrapper .value-wrapper .fixed-width{-ms-flex-negative:0;flex-shrink:0}:host .component-wrapper .value-wrapper .value.hidden{visibility:hidden}:host .component-wrapper .faded{opacity:0.3}:host .component-wrapper path:active,:host .component-wrapper path:hover,:host .component-wrapper path:focus,:host .component-wrapper .stacked-bar-segment:active,:host .component-wrapper .stacked-bar-segment:hover,:host .component-wrapper .stacked-bar-segment:focus{outline:none}:host .component-wrapper .stacked-bar-segment:active.stacked-bar-segment:not(:focus-visible),:host .component-wrapper .stacked-bar-segment:hover.stacked-bar-segment:not(:focus-visible),:host .component-wrapper .stacked-bar-segment:focus.stacked-bar-segment:not(:focus-visible){-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:not(:focus-visible),:host .component-wrapper path:hover.doughnut-segment:not(:focus-visible),:host .component-wrapper path:focus.doughnut-segment:not(:focus-visible),:host .component-wrapper .stacked-bar-segment:active.doughnut-segment:not(:focus-visible),:host .component-wrapper .stacked-bar-segment:hover.doughnut-segment:not(:focus-visible),:host .component-wrapper .stacked-bar-segment:focus.doughnut-segment:not(:focus-visible){-webkit-filter:url(#wmHoverDropShadow);filter:url(#wmHoverDropShadow)}:host .component-wrapper path::-moz-focus-inner,:host .component-wrapper .stacked-bar-segment::-moz-focus-inner{border:0;outline:none}:host .component-wrapper .stacked-bar-segment:focus-visible{outline:3px solid var(--wmcolor-interactive-focus);outline-offset:2px;-webkit-box-shadow:0 0 0 7px white;box-shadow:0 0 0 7px white;z-index:1}:host .component-wrapper #kfbg1{stroke:white;stroke-width:10px}:host .component-wrapper #kfstroke{stroke:var(--wmcolor-interactive-focus);stroke-width:6px}:host .component-wrapper #kfbg2{stroke:white;stroke-width:2px}:host .component-wrapper.doughnut{width:300px}:host .component-wrapper.doughnut1 label,:host .component-wrapper.doughnut1 .label-text,:host .component-wrapper.doughnut2 label,:host .component-wrapper.doughnut2 .label-text,:host .component-wrapper.doughnut2b label,:host .component-wrapper.doughnut2b .label-text,:host .component-wrapper.doughnut3 label,:host .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.doughnut{-ms-flex-align:center;align-items:center}:host .component-wrapper.doughnut label{text-align:center;width:100%;padding-bottom:1.5rem}:host .component-wrapper.doughnut label .subinfo{position:absolute}:host .component-wrapper.doughnut .completion-message{padding-top:0.625rem}:host .component-wrapper.bar{-ms-flex-align:start;align-items:flex-start}:host .component-wrapper.bar label{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}:host .component-wrapper.bar label .subinfo{position:initial}:host .component-wrapper.bar .chart-wrapper{display:-ms-flexbox;display:flex}:host .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.bar .chart-wrapper .inner-stacked-bar-wrapper{-ms-flex:1;flex:1}:host .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.bar{-ms-flex-direction:row;flex-direction:row}:host .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.bar .bar-wrapper{-ms-flex-direction:row-reverse;flex-direction:row-reverse}:host .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,:host .component-wrapper.bar2b,:host .component-wrapper.bar3,:host .component-wrapper.bar4,:host .component-wrapper.bar5{-ms-flex-align:start;align-items:flex-start}:host .component-wrapper.bar2b .inner-stacked-bar-wrapper,:host .component-wrapper.bar4 .inner-stacked-bar-wrapper,:host .component-wrapper.bar5 .inner-stacked-bar-wrapper{height:30px;margin-bottom:0}:host .component-wrapper.bar2b .inner-stacked-bar-wrapper.show-values,:host .component-wrapper.bar4 .inner-stacked-bar-wrapper.show-values,:host .component-wrapper.bar5 .inner-stacked-bar-wrapper.show-values{height:60px;margin-top:0}:host .component-wrapper.bar3 .chart-wrapper{position:relative;height:100px}:host .component-wrapper.bar3 .chart-wrapper .inner-stacked-bar-wrapper{position:absolute;top:35px;left:0;right:0;bottom:0;height:30px}:host .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{stroke:var(--wmcolor-chart-gridline);stroke-width:1px}:host .component-wrapper.bar3 .chart-wrapper .axis text{-webkit-transform:translate(4px, 24px);transform:translate(4px, 24px);text-anchor:middle}:host .component-wrapper.bar3 .hidden-values-warning{margin-top:1.25rem}:host .component-wrapper.bar6,:host .component-wrapper.bar7{--chartPadding:48px;-ms-flex-align:start;align-items:flex-start}:host .component-wrapper.bar6 .chart-wrapper,:host .component-wrapper.bar7 .chart-wrapper{width:100%}:host .component-wrapper.bar6 .chart,:host .component-wrapper.bar7 .chart{position:relative;padding-right:var(--chartPadding)}:host .component-wrapper.bar6 .gridlines,:host .component-wrapper.bar7 .gridlines{position:absolute;left:var(--labelWidth);right:var(--chartPadding);top:0;bottom:0;background-image:linear-gradient(90deg, var(--wmcolor-chart-gridline) 1px, transparent 1px);background-position:-1px;border-left:1px solid var(--wmcolor-chart-gridline);border-bottom:1px solid var(--wmcolor-chart-gridline);background-size:var(--backgroundSize)}:host .component-wrapper.bar6 .rows,:host .component-wrapper.bar7 .rows{display:grid;grid-template-columns:var(--labelWidth) auto;grid-auto-rows:minmax(30px, 1fr);-ms-flex-align:center;align-items:center;position:relative;z-index:1}:host .component-wrapper.bar6 .rows .label,:host .component-wrapper.bar7 .rows .label{font-weight:400;padding:0 0.75rem 0 0;text-align:right;margin:0.75rem 0}:host .component-wrapper.bar6 .rows .label.hidden,:host .component-wrapper.bar7 .rows .label.hidden{visibility:hidden;white-space:nowrap}:host .component-wrapper.bar6 .bar,:host .component-wrapper.bar7 .bar{height:30px;position:relative}:host .component-wrapper.bar6 .bar .value,:host .component-wrapper.bar7 .bar .value{position:absolute;top:50%;right:-0.5rem;-webkit-transform:translate(100%, -50%);transform:translate(100%, -50%)}:host .component-wrapper.bar6 .x-axis,:host .component-wrapper.bar7 .x-axis{margin-left:var(--labelWidth);margin-right:var(--chartPadding);display:-ms-flexbox;display:flex;postion:relative}:host .component-wrapper.bar6 .tick,:host .component-wrapper.bar7 .tick{-ms-flex:1;flex:1;text-align:right}:host .component-wrapper.bar6 .tick span,:host .component-wrapper.bar7 .tick span{-webkit-transform:translateX(50%);transform:translateX(50%);display:inline-block}:host .component-wrapper.bar6 .zero,:host .component-wrapper.bar7 .zero{position:absolute;-webkit-transform:translateX(-50%);transform:translateX(-50%)}:host .component-wrapper.bar6 .bar:active,:host .component-wrapper.bar6 .bar:hover,:host .component-wrapper.bar6 .bar:focus,:host .component-wrapper.bar7 .bar:active,:host .component-wrapper.bar7 .bar:hover,:host .component-wrapper.bar7 .bar:focus{outline:none}:host .component-wrapper.bar6 .bar:active.bar:not(:focus-visible),:host .component-wrapper.bar6 .bar:hover.bar:not(:focus-visible),:host .component-wrapper.bar6 .bar:focus.bar:not(:focus-visible),:host .component-wrapper.bar7 .bar:active.bar:not(:focus-visible),:host .component-wrapper.bar7 .bar:hover.bar:not(:focus-visible),:host .component-wrapper.bar7 .bar:focus.bar:not(:focus-visible){-webkit-box-shadow:0px 0px 6px #333;-moz-box-shadow:0px 0px 6px #333;box-shadow:0px 0px 6px #333}:host .component-wrapper.bar6 .bar:focus-visible,:host .component-wrapper.bar7 .bar:focus-visible{outline:3px solid var(--wmcolor-interactive-focus);outline-offset:2px;-webkit-box-shadow:0 0 0 7px white;box-shadow:0 0 0 7px white;z-index:1}:host .component-wrapper.left-label{-ms-flex-direction:row;flex-direction:row}:host .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 .component-wrapper .hidden-values-warning{font-size:0.75rem;font-style:italic;max-width:100%}:host .component-wrapper .hidden-values-warning.hidden{display:none}@media print{:host .component-wrapper .hidden-values-warning{display:none}}:host #chart-instructions{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 .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{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.bar6{display:none}:host .component-wrapper .legend-wrapper .legend.--top{margin-top:-0.75rem}:host .component-wrapper .legend-wrapper .legend.--top .legend-item{padding-top:0.75rem}:host .component-wrapper .legend-wrapper .legend.--top .legend-color{top:0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom{margin-bottom:-0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom .legend-item{padding-bottom:0.75rem}:host .component-wrapper .legend-wrapper .legend.--bottom .legend-color{top:-0.75rem}:host .component-wrapper .legend-wrapper .legend .legend-item{position:relative}:host .component-wrapper .legend-wrapper .legend .legend-item.faded{opacity:0.3}:host .component-wrapper .legend-wrapper .legend .legend-item:not(:last-of-type){padding-right:1.25rem}:host .component-wrapper .legend-wrapper .legend .legend-text{font-size:0.875rem;padding-left:1rem;line-height:1}:host .component-wrapper .legend-wrapper .legend .legend-color{position:absolute;left:0;bottom:0;margin:auto;width:0.6875rem;height:0.6875rem;print-color-adjust:exact;-webkit-print-color-adjust:exact}:host .component-wrapper .legend-wrapper .legend .print-value{display:none}:host .component-wrapper .legend-wrapper .legend .print-value.force-visible{display:unset}@media print{:host .component-wrapper .legend-wrapper .legend .print-value{display:unset}}:host .component-wrapper .legend-wrapper .legend.bar3{padding-bottom:1.25rem}";var j=e("wm_progress_indicator",function(){function e(e){var o=this;t(this,e);this.uid=p();this.slicesDetails=[];this.barLabelsWidth=this.el.parentElement.barLabelsWidth;this.debouncedUpdate=s((function(){return __awaiter(o,void 0,void 0,(function(){return __generator(this,(function(e){r(this.el);return[2]}))}))}),10);this.label=undefined;this.subinfo=undefined;this.completionMessage=undefined;this.showLegend=true;this.printMode=false;this.printModeFormat="amount";this.isTabbing=false;this.mode=undefined;this.userIsNavigating=false;this.focusedSliceId=undefined}Object.defineProperty(e.prototype,"popoverEl",{get:function(){return this.el.shadowRoot.querySelector("priv-chart-popover")},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"sliceEls",{get:function(){return Array.from(this.el.shadowRoot.querySelectorAll(".segment"))},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"chartDetails",{get:function(){return this.mode?h[this.mode]:undefined},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"ariaLabelText",{get:function(){var e="".concat(this.label);if(this.subinfo){e+=" ".concat(this.subinfo)}return e},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"chartRoleDescription",{get:function(){return l.formatMessage({id:"chart.roleDescription",defaultMessage:"Interactive chart",description:"For screen readers only, a description clarifying the role of the chart widget"})},enumerable:false,configurable:true});e.prototype.toggleTabbingOn=function(){this.isTabbing=true};e.prototype.toggleTabbingOff=function(){this.isTabbing=false};e.prototype.handleKeydown=function(e){m.call(this,e)};e.prototype.componentWillLoad=function(){var e=this;if(!this.label){console.error("For accessibility purposes, you must provide a label for the chart. See https://components.watermarkinsights.com/chart for more information.")}if(this.el.children.length!==2){console.warn("wm-progress-indicator component must have 2 wm-progress-slice children.")}this.el.parentElement.addEventListener("wmProgressMonitorModeChange",(function(t){return e.mode=t.detail}));var t=new ResizeObserver((function(){return e.debouncedUpdate()}));t.observe(this.el)};e.prototype.handleSliceUpdate=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:return[4,d.call(this,this.mode)];case 1:e.sent();r(this.el);return[2]}}))}))};e.prototype.handleModeUpdate=function(){if(this.mode){d.call(this,this.mode)}};e.prototype.handlePopoverOpenChanged=function(e){var t=e.detail;if(!t){var r=Array.from(this.el.shadowRoot.querySelectorAll("[data-segmentindex]"));u(r)}};e.prototype.renderBarOrDoughnut=function(){if(this.total>0&&this.mode==="bar"){return b.call(this,this.mode)}else{return w.call(this,this.mode)}};e.prototype.render=function(){var e=this;return o(n,{onBlur:function(){return v.call(e)}},o("div",{ref:function(t){return e.componentWrapperEl=t},class:"component-wrapper ".concat(this.mode," ").concat(this.isTabbing&&!this.userIsNavigating?"user-is-tabbing":""),role:"application","aria-label":this.ariaLabelText,tabindex:"0","aria-roledescription":this.chartRoleDescription,"aria-describedby":"chart-instructions"},o("label",{id:"label-".concat(this.uid),class:"label ".concat(this.barLabelsWidth&&this.mode==="bar"?"custom-width":""),style:{"--custom-label-width":this.barLabelsWidth},htmlFor:"graphic-".concat(this.uid)},o("span",{class:"label-text"},this.label),this.subinfo?o("span",{class:"subinfo"},this.subinfo):""),this.mode&&this.renderBarOrDoughnut(),this.mode==="doughnut"?f.call(this,this.mode):"",o("priv-chart-popover",{class:this.isTabbing?"user-is-tabbing":"",onIntChartPopoverOpenChanged:function(t){return e.handlePopoverOpenChanged(t)}}),this.mode==="doughnut"?x.call(this):""),g())};Object.defineProperty(e,"delegatesFocus",{get:function(){return true},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"el",{get:function(){return a(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{mode:["handleModeUpdate"]}},enumerable:false,configurable:true});return e}());j.style=y;var z=":host .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 .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 .legend-wrapper .legend.bar6{display:none}:host .legend-wrapper .legend.--top{margin-top:-0.75rem}:host .legend-wrapper .legend.--top .legend-item{padding-top:0.75rem}:host .legend-wrapper .legend.--top .legend-color{top:0.75rem}:host .legend-wrapper .legend.--bottom{margin-bottom:-0.75rem}:host .legend-wrapper .legend.--bottom .legend-item{padding-bottom:0.75rem}:host .legend-wrapper .legend.--bottom .legend-color{top:-0.75rem}:host .legend-wrapper .legend .legend-item{position:relative}:host .legend-wrapper .legend .legend-item.faded{opacity:0.3}:host .legend-wrapper .legend .legend-item:not(:last-of-type){padding-right:1.25rem}:host .legend-wrapper .legend .legend-text{font-size:0.875rem;padding-left:1rem;line-height:1}:host .legend-wrapper .legend .legend-color{position:absolute;left:0;bottom:0;margin:auto;width:0.6875rem;height:0.6875rem;print-color-adjust:exact;-webkit-print-color-adjust:exact}:host .legend-wrapper .legend .print-value{display:none}:host .legend-wrapper .legend .print-value.force-visible{display:unset}@media print{:host .legend-wrapper .legend .print-value{display:unset}}:host .legend-wrapper .legend.bar3{padding-bottom:1.25rem}:host{display:-ms-flexbox;display:flex}:host .legend-wrapper{-ms-flex-align:start;align-items:flex-start}:host(.row){-ms-flex-direction:row;flex-direction:row}:host(.column){-ms-flex-direction:column;flex-direction:column}:host(.column) .legend-wrapper{margin-bottom:2rem}:host(.column) .legend-wrapper .legend{padding-bottom:0}:host(.column) ::slotted(wm-progress-indicator:not(:last-of-type)){margin-bottom:2.5rem}";var _=e("wm_progress_monitor",function(){function e(e){var o=this;t(this,e);this.wmProgressMonitorModeChange=i(this,"wmProgressMonitorModeChange",7);this.doughnutWidth=300;this.modeInitialized=false;this.debouncedUpdate=s((function(){return r(o.el)}),50);this.breakpoint=undefined;this.groupLegend=undefined;this.barLabelsWidth=undefined}Object.defineProperty(e.prototype,"parsedBreakpoint",{get:function(){var e=this.parseToNum(this.breakpoint?this.breakpoint:this.el.children.length);var t=e>=20?e:e*this.doughnutWidth;return t},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"mode",{get:function(){return this.el.clientWidth>this.parsedBreakpoint?"doughnut":"bar"},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"isBar",{get:function(){return false},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"isDoughnut",{get:function(){return false},enumerable:false,configurable:true});e.prototype.componentWillLoad=function(){var e=this;var t=new ResizeObserver((function(){return e.debouncedUpdate()}));t.observe(this.el)};e.prototype.componentDidLoad=function(){this.wmProgressMonitorModeChange.emit(this.mode);this.modeInitialized=true};e.prototype.componentWillUpdate=function(){if(this.prevMode!==this.mode){this.wmProgressMonitorModeChange.emit(this.mode)}this.prevMode=this.mode};e.prototype.parseToNum=function(e){var t=e.toString();var r=t.replace("px","");return parseInt(r)};e.prototype.renderLegend=function(){var e=this;var t=c(this.groupLegend);var r=h.bar.colors;return o("div",{class:"legend-wrapper"},o("div",{class:"legend"},t.map((function(t,o){var n={key:t,color:r[o]};return k.call(e,n)}))))};e.prototype.render=function(){return o(n,{class:this.mode==="doughnut"?"row":"column"},this.modeInitialized&&this.groupLegend&&this.mode==="bar"&&this.renderLegend(),this.modeInitialized&&o("slot",null))};Object.defineProperty(e,"delegatesFocus",{get:function(){return true},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"el",{get:function(){return a(this)},enumerable:false,configurable:true});return e}());_.style=z;var O=e("wm_progress_slice",function(){function e(e){t(this,e);this.wmProgressSliceUpdated=i(this,"wmProgressSliceUpdated",7);this.legend=undefined;this.amount=undefined;this.popoverTitle=undefined;this.popoverText=undefined;this.popoverButtonText=undefined}e.prototype.componentDidUpdate=function(){this.wmProgressSliceUpdated.emit()};return e}())}}}));