@iamproperty/components 5.7.1-beta6 → 6.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/css/components/barchart.component.css +1 -1
- package/assets/css/components/barchart.component.css.map +1 -1
- package/assets/css/components/charts.module.css +1 -1
- package/assets/css/components/charts.module.css.map +1 -1
- package/assets/js/components/_global.js +32 -0
- package/assets/js/components/accordion/accordion.component.min.js +1 -1
- package/assets/js/components/actionbar/actionbar.component.min.js +1 -1
- package/assets/js/components/address-lookup/address-lookup.component.min.js +1 -1
- package/assets/js/components/applied-filters/applied-filters.component.min.js +1 -1
- package/assets/js/components/barchart/barchart.component.js +6 -7
- package/assets/js/components/barchart/barchart.component.min.js +4 -4
- package/assets/js/components/barchart/barchart.component.min.js.map +1 -1
- package/assets/js/components/card/card.component.js +1 -1
- package/assets/js/components/card/card.component.min.js +2 -2
- package/assets/js/components/card/card.component.min.js.map +1 -1
- package/assets/js/components/carousel/carousel.component.min.js +1 -1
- package/assets/js/components/collapsible-side/collapsible-side.component.min.js +1 -1
- package/assets/js/components/fileupload/fileupload.component.min.js +1 -1
- package/assets/js/components/filterlist/filterlist.component.min.js +1 -1
- package/assets/js/components/header/header.component.min.js +1 -1
- package/assets/js/components/inline-edit/inline-edit.component.min.js +1 -1
- package/assets/js/components/marketing/marketing.component.min.js +1 -1
- package/assets/js/components/multiselect/multiselect.component.min.js +1 -1
- package/assets/js/components/nav/nav.component.min.js +1 -1
- package/assets/js/components/notification/notification.component.min.js +1 -1
- package/assets/js/components/pagination/pagination.component.min.js +1 -1
- package/assets/js/components/search/search.component.min.js +1 -1
- package/assets/js/components/slider/slider.component.min.js +1 -1
- package/assets/js/components/table/table.component.min.js +1 -1
- package/assets/js/components/tabs/tabs.component.min.js +1 -1
- package/assets/js/dynamic.min.js +1 -1
- package/assets/js/modules/chart.module.js +25 -60
- package/assets/js/scripts.bundle.js +2 -2
- package/assets/js/scripts.bundle.js.map +1 -1
- package/assets/js/scripts.bundle.min.js +2 -2
- package/assets/js/scripts.bundle.min.js.map +1 -1
- package/assets/js/tests/chart.spec.js +57 -0
- package/assets/sass/components/charts.module.scss +13 -4
- package/assets/ts/components/_global.ts +40 -0
- package/assets/ts/components/barchart/barchart.component.ts +7 -17
- package/assets/ts/components/card/card.component.ts +1 -1
- package/assets/ts/modules/chart.module.ts +25 -74
- package/assets/ts/tests/chart.spec.ts +77 -0
- package/dist/components.es.js +11 -11
- package/dist/components.umd.js +12 -12
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
:host{--chart-colour-1-set: var(--chart-colour-1,#BEE8F8);--chart-colour-2-set: var(--chart-colour-2,#A6DCC7);--chart-colour-3-set: var(--chart-colour-3,#FAD0DA);--chart-colour-4-set: var(--chart-colour-4,#AFCCF2);--chart-colour-5-set: var(--chart-colour-5,#FFD2B4);--chart-colour-6-set: var(--chart-colour-6,#CDF0F2);--chart-colour-7-set: var(--chart-colour-7,#FFABC2);--chart-colour-8-set: var(--chart-colour-8,#DCEAF2);--chart-colour-9-set: var(--chart-colour-9,#EEBCB3);--chart-colour-10-set: var(--chart-colour-10,#F0BDFF);--chart-colour-1-hover: var(--chart-colour-1,#B6DEED);--chart-colour-2-hover: var(--chart-colour-2,#98CBB7);--chart-colour-3-hover: var(--chart-colour-3,#EFC8D1);--chart-colour-4-hover: var(--chart-colour-4,#A6C1E5);--chart-colour-5-hover: var(--chart-colour-5,#F4CAAF);--chart-colour-6-hover: var(--chart-colour-6,#C2E3E5);--chart-colour-7-hover: var(--chart-colour-7,#F5A2B9);--chart-colour-8-hover: var(--chart-colour-8,#CFDCE3);--chart-colour-9-hover: var(--chart-colour-9,#E3B2A9);--chart-colour-10-hover: var(--chart-colour-10,#E3B2F2);--chart-colour-success: #D2F0C9!important;--chart-colour-success-hover: #8AD873!important;--chart-colour-danger: #F5C2C7!important;--chart-colour-danger-hover: #f5c2e7!important;--chart-colour-warning: #FFD280!important;--chart-colour-warning-hover: #FFB020!important}.chart__key .key:nth-child(10n-9),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-8){--chart-colour: var(--chart-colour-1-set);--chart-colour-hover: var(--chart-colour-1-hover)}.chart__key .key:nth-child(10n-8),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-7){--chart-colour: var(--chart-colour-2-set);--chart-colour-hover: var(--chart-colour-2-hover)}.chart__key .key:nth-child(10n-7),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-6){--chart-colour: var(--chart-colour-3-set);--chart-colour-hover: var(--chart-colour-3-hover)}.chart__key .key:nth-child(10n-6),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-5){--chart-colour: var(--chart-colour-4-set);--chart-colour-hover: var(--chart-colour-4-hover)}.chart__key .key:nth-child(10n-5),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-4){--chart-colour: var(--chart-colour-5-set);--chart-colour-hover: var(--chart-colour-5-hover)}.chart__key .key:nth-child(10n-4),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-3){--chart-colour: var(--chart-colour-6-set);--chart-colour-hover: var(--chart-colour-6-hover)}.chart__key .key:nth-child(10n-3),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-2){--chart-colour: var(--chart-colour-7-set);--chart-colour-hover: var(--chart-colour-7-hover)}.chart__key .key:nth-child(10n-2),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-1){--chart-colour: var(--chart-colour-8-set);--chart-colour-hover: var(--chart-colour-8-hover)}.chart__key .key:nth-child(10n-1),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-0){--chart-colour: var(--chart-colour-9-set);--chart-colour-hover: var(--chart-colour-9-hover)}::slotted(table){display:none !important}:host{container-type:inline-size;margin-bottom:2rem;display:block}.chart__outer{display:flex;flex-direction:column;font-weight:var(--chart-font-weight, bold);color:var(--chart-text-color, black);--body-colour-set: var(--body-colour, Canvas);--text-colour-set: var(--text-colour, black);--chart-height-set: var(--chart-height, 7.5rem);--chart-height-lg-set: var(--chart-height-lg, 12.5rem);--chart-height-resp: var(--chart-height-set);--index-below: -1;--index-base: 0;--index-focus: 2;--index-above: 10;--index-floating: 100;--index-menu: 200;--index-overlay: 1000;--key-label-width: 100%;--label-size: 0.75rem;--pie-size: calc(50% - 1.4rem);--line-thickness: 1px;--yaxis-width: auto;--yaxis-point-display: block;--yaxis-last-point-transform: translate(0,-50%);--bar-gap: min(10%, 0.75rem)}.chart__outer>*{display:block;order:2}.chart__outer tbody{--chart-direction: 360deg;--chart-day-bg-pos: 100% calc(var(--single-day) * 7) }@container (min-width: 23.4375em){.chart__outer :has(tr:nth-child(5) td:nth-child(4)),.chart__outer :has(tr:nth-child(10)){--yaxis-width: 0;--yaxis-point-display: none;--yaxis-last-point-transform: translate(0,-100%);--bar-gap: 0}.chart__outer .chart__wrapper{--chart-height-resp: var(--chart-height-lg-set);--pie-size: calc(33.333% - 1.4rem);--line-thickness: 0.8px;--yaxis-width: auto;--yaxis-point-display: block;--yaxis-last-point-transform: translate(0,-50%)}}@container (min-width: 48em){.chart__outer :has(tr:nth-child(10)){--bar-gap: 0}.chart__outer .chart__wrapper{--label-size: 0.875rem;--pie-size: calc(25% - 1.5rem);--line-thickness: 0.5px}}.chart__outer .chart__spacer span{opacity:0}.chart__outer>input[type=checkbox]{opacity:0;position:absolute;pointer-events:none;bottom:50%;left:50%}.chart__key{padding:0 0 0 0;margin-bottom:1.5rem;display:flex;overflow:auto;scroll-snap-type:x mandatory;scroll-padding:.75rem;gap:.5rem}.chart__key:has(label:first-child:last-child){display:var(--single-key-display, none)}.chart__key .key{margin:0}.chart__key .key:before{content:"";height:.8em;width:.8em;margin-right:.3em;background-color:var(--chart-colour);display:inline-block;border-radius:var(--key-border-radius, 4px)}.chart__key .key[data-label=Min],.chart__key .key[data-label=Max]{display:none}.chart__key .key .chart__total{display:none}.chart__outer>input[type=checkbox]:nth-of-type(1):not(:checked)~.chart__key .key:nth-of-type(1){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(2):not(:checked)~.chart__key .key:nth-of-type(2){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(3):not(:checked)~.chart__key .key:nth-of-type(3){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(4):not(:checked)~.chart__key .key:nth-of-type(4){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(5):not(:checked)~.chart__key .key:nth-of-type(5){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(6):not(:checked)~.chart__key .key:nth-of-type(6){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(7):not(:checked)~.chart__key .key:nth-of-type(7){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(8):not(:checked)~.chart__key .key:nth-of-type(8){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(9):not(:checked)~.chart__key .key:nth-of-type(9){opacity:.25}:host([data-yaxis]){--yaxis-display: flex}.chart__yaxis{display:var(--yaxis-display, none);flex-direction:column-reverse;width:var(--yaxis-width)}.chart__yaxis .axis__point{bottom:var(--percent);position:relative;height:0;white-space:nowrap}.chart__yaxis .axis__point:not(:last-child){display:var(--yaxis-point-display)}.chart__yaxis .axis__point span{display:block;transform:translate(0, -50%);padding-right:.25rem;text-align:right;font-weight:var(--chart-yaxis-fw, normal);font-size:var(--chart-yaxis-fs, 0.75rem);color:var(--colour-body)}.chart__yaxis .axis__point:last-child span{transform:var(--yaxis-last-point-transform)}.chart__xaxis{margin-bottom:1rem;display:flex;flex-direction:column-reverse;width:100%;position:absolute;left:0;bottom:-1rem}.chart__xaxis .axis__point{left:var(--percent);width:1px;position:absolute;height:0;white-space:nowrap}.chart__xaxis .axis__point span{display:block;transform:translate(-50%, 0%);text-align:center;font-size:var(--label-size);position:absolute;left:50%}.chart__guidelines{position:absolute;top:0;left:0;width:100%;height:100%;display:flex;flex-direction:column-reverse;pointer-events:none}.chart__guidelines .guideline{bottom:var(--percent);position:absolute;right:0;width:100%;height:0px;margin-bottom:-1px;border-bottom:1px dashed #eee;pointer-events:none;z-index:var(--index-below)}.chart__guidelines .guideline:not(.guideline--target) span{display:none}.chart__guidelines .guideline--target{border-bottom:1px dashed #000;z-index:var(--index-above);text-shadow:1px solid #fff;overflow:visible}.chart__guidelines .guideline--target span{position:absolute;bottom:0;font-size:var(--label-size);text-shadow:1px 1px 2px #fff;background:rgba(255,255,255,.6)}.chart__guidelines [data-value="0"]{border-bottom:1px solid var(--colour-primary)}.chart__guidelines [data-value="0"]:not(:first-child){border-bottom:1px dashed var(--colour-primary)}.chart__wrapper{display:block;display:flex;flex-direction:row;position:relative}.chart__wrapper .chart{position:relative;flex-grow:1}.chart__wrapper table{display:block;width:100% !important;padding-top:var(--chart-height-resp);position:relative;margin-bottom:0;overflow:visible}.chart__wrapper table thead{display:none}.chart__wrapper table tbody{display:flex;position:absolute;width:100%;height:100%;top:0;left:0;flex-direction:row;border:none}.chart__wrapper table tbody tr{display:flex;flex-direction:row;justify-content:var(--chart-bar-alignment, center);align-items:flex-end;border:none;width:100%;height:100%;position:relative;padding:0 2px;gap:var(--bar-gap)}.chart__wrapper table tbody tr td{font-weight:inherit}.chart__wrapper table tbody tr td:first-child{position:absolute;top:100%;left:0%;width:fit-content;padding:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:var(--label-size);text-align:center}@container (min-width: 48em){.chart__wrapper table tbody tr td:first-child{display:block}}.chart__wrapper table tbody tr td:first-child button{all:unset;cursor:pointer}.chart__wrapper table tbody tr td[data-label=Min],.chart__wrapper table tbody tr td[data-label=Max]{display:none}.chart__wrapper table tbody tr:first-child td:first-child,.chart__wrapper table tbody tr:last-child td:first-child{display:block}.chart__wrapper table tbody tr td:not(:first-child){height:100%;height:var(--percent, 0%);bottom:var(--bottom, 0%);width:100%;max-width:7.5rem;position:relative;padding:0;background:var(--chart-colour);border-top-right-radius:4px;border-top-left-radius:4px}@media screen and (prefers-color-scheme: dark){.chart__wrapper table tbody tr td:not(:first-child){background:color-mix(in oklab, var(--chart-colour), black 20%)}}.chart__wrapper table tbody tr td:not(:first-child):hover{background:var(--chart-colour-hover)}.chart__wrapper table tbody tr td:not(:first-child):has(span:empty),.chart__wrapper table tbody tr td:not(:first-child):empty{display:none}.chart__wrapper table tbody tr td:not(:first-child)[data-label]:before{display:none}.chart__wrapper table tbody tr td:not(:first-child) span{position:absolute;top:var(--cursor-y, 50%);left:var(--cursor-x, 50%);font-size:var(--label-size);line-height:1.2;transform:translate(-50%, 0);background:var(--chart-details-bg, var(--colour-canvas-2, Canvas));opacity:0;pointer-events:none;padding:.5rem;border-radius:.5rem;margin-bottom:.25rem;white-space:pre;text-align:left;box-shadow:var(--chart-details-shadow, 0 0.125rem 0.75rem rgba(0, 0, 0, 0.25));transform:translate(-50%, -100%)}.chart__wrapper table tbody tr td:not(:first-child) span::before{content:attr(data-group) "\a"}.chart__wrapper table tbody tr td:not(:first-child) span[data-label]::before{content:attr(data-group) "\a" attr(data-label) "\a"}.chart__wrapper table tbody tr td:not(:first-child):hover span{opacity:1;z-index:var(--index-above)}.chart__wrapper table tbody tr td:first-child[data-label]:before{display:none}@container (min-width: 48em){.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr td:first-child,.chart__wrapper table tbody:has(tr:nth-child(10)) tr td:first-child{display:none}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:first-child td:first-child,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:first-child td:first-child{left:0%;transform:translate(0, 0);display:block;text-align:left}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:last-child td:first-child,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:last-child td:first-child{left:100%;transform:translate(-100%, 0);display:block;text-align:right}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:first-child td:not(:first-child) span,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:first-child td:not(:first-child) span{left:-20%;transform:translate(0%, 0);text-align:left}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:last-child td:not(:first-child) span,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:last-child td:not(:first-child) span{left:120%;transform:translate(-100%, 0);text-align:right}}@container (min-width: 23.4375em){.chart__wrapper table tbody:has(tr:nth-child(25)) tr td:first-child{display:none !important}.chart__wrapper table tbody:has(tr:nth-child(25)) tr:is(:first-child,:nth-child(2n+1)) td:first-child{display:block !important}.chart__wrapper table tbody:has(tr:nth-child(50)) tr:is(:first-child,:nth-child(2n+1)) td:first-child,.chart__wrapper table tbody:has(tr:nth-child(50)) tr td:first-child{display:none !important}.chart__wrapper table tbody:has(tr:nth-child(50)) tr:is(:first-child,:nth-child(10n+1)) td:first-child{display:block !important}.chart__wrapper table tbody:has(tr:nth-child(100)) tr:is(:first-child,:nth-child(10n+1)) td:first-child,.chart__wrapper table tbody:has(tr:nth-child(100)) tr td:first-child{display:none !important}.chart__wrapper table tbody:has(tr:nth-child(100)) tr:is(:first-child,:nth-child(20n+1)) td:first-child{display:block !important}}:host(.chart-colour--success) td,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--success,.chart-colour--success td{--chart-colour: var(--chart-colour-success)!important}:host(.chart-colour--success) td:hover,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--success:hover,.chart-colour--success td:hover{--chart-colour-hover: var(--chart-colour-success-hover)!important}:host(.chart-colour--danger) td,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--danger,.chart-colour--danger,.chart-colour--danger td{--chart-colour: var(--chart-colour-danger)!important}:host(.chart-colour--danger) td:hover,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--danger:hover,.chart-colour--danger:hover,.chart-colour--danger td:hover{--chart-colour-hover: var(--chart-colour-danger-hover)!important}:host(.chart-colour--warning) td,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--warning,.chart-colour--warning,.chart-colour--warning td{--chart-colour: var(--chart-colour-warning)!important}:host(.chart-colour--warning) td:hover,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--warning:hover,.chart-colour--warning:hover,.chart-colour--warning td:hover{--chart-colour-hover: var(--chart-colour-warning-hover)!important}.chart__outer>input[type=checkbox]:nth-of-type(1):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(2){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(2):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(3){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(3):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(4){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(4):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(5){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(5):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(6){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(6):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(7){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(7):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(8){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(8):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(9){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(9):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(10){display:none;opacity:0}:host(.chart--horizontal) .chart__outer tbody{--chart-direction: 90deg;--chart-day-bg-pos: calc(var(--single-day) * 7) 100%;--bar-gap: 0}:host(.chart--horizontal) .chart__outer .chart__guidelines{position:absolute}:host(.chart--horizontal) .chart__outer .chart__guidelines .guideline{bottom:auto;left:var(--percent);height:100%;border-left:1px dashed #eee;width:0}:host(.chart--horizontal) .chart__outer .chart__guidelines .guideline span{display:block;font-size:var(--label-size);position:absolute;top:100%;transform:translate(-50%, 0.2em);opacity:1}:host(.chart--horizontal) .chart__outer .chart__yaxis{display:none}:host(.chart--horizontal) .chart__outer table{padding-top:0}:host(.chart--horizontal) .chart__outer table tbody{flex-direction:column;position:relative}:host(.chart--horizontal) .chart__outer table tbody tr{flex-direction:column;align-items:flex-start;margin-bottom:.5rem;padding:0}:host(.chart--horizontal) .chart__outer table tbody tr td{height:var(--bar-height, 1.5rem);bottom:0;left:var(--bottom, 0%);width:var(--comparison, var(--percent));max-width:100%;border-top-left-radius:0;border-bottom-right-radius:4px}:host(.chart--horizontal) .chart__outer table tbody tr td:first-child{position:static;transform:none;display:block !important;height:var(--bar-height, 1.5rem);line-height:var(--bar-height, 1.5rem);max-width:var(--xaxis-max-width, none)}:host(.chart--horizontal) .chart__outer table tbody tr td:first-child>*:not([popover]){max-width:100%;text-overflow:ellipsis;overflow:hidden}:host(.chart--horizontal) .chart__outer .chart__wrapper[data-longest-label]:before{display:block;content:attr(data-longest-label);font-size:var(--label-size);padding-right:.5em;opacity:0;pointer-events:none;white-space:nowrap;width:var(--xaxis-max-width, none)}:host(.chart--horizontal) .chart__outer:has(td .tooltip) .chart__wrapper[data-longest-label]:before{padding-right:2em;width:calc(var(--xaxis-max-width, none) - 1rem)}:host(.chart--horizontal) .chart__outer .chart__wrapper[data-longest-label] table tbody tr td:first-child{position:absolute;display:block !important;max-height:1.5rem;z-index:var(--index-above);top:0%;left:auto !important;right:100% !important;padding-right:.5em;width:fit-content}:host(.chart--horizontal) .chart__outer .chart__spacer span{display:none !important}:host(.chart--stacked) .chart__wrapper table tbody tr{--bar-gap: 0;flex-direction:column-reverse;justify-content:flex-start;align-items:center}:host(.chart--stacked) .chart__wrapper table tbody tr td{border-radius:0 !important}:host(.chart--stacked.chart--horizontal) .chart__wrapper table tbody tr{flex-direction:row}:host(.chart--stacked.chart--horizontal) .chart__wrapper table tbody tr::after{content:attr(data-numeric);position:absolute;opacity:1 !important;bottom:100%;left:50%;transform:translate(-50%, 0);display:block !important;height:fit-content;margin:0;bottom:50%;left:calc(var(--percent) + .5rem);transform:translate(0, 50%)}:host(.chart--stacked.chart--horizontal) .chart__wrapper table tbody tr td:after{content:none}.chart--animate.animating.inview{--animation-left: 2s}.chart--animate.animating.inview table tbody tr td:not(:first-child){transition:height 2s ease-out,width 2s ease-out,bottom 2s ease-out,left var(--animation-left) ease-out;transition-delay:calc(var(--row-index)*.1s)}.chart--animate:not(.inview) table tbody tr td:not(:first-child){--bottom: var(--min-bottom, 0%)!important;--percent: 0%!important;--axis: 0%!important;--comparison: 0%!important}.chart--animate.animating table tbody tr td:not(:first-child){overflow:hidden}:host(.chart--display-data) table tbody tr td:not(:first-child):after{content:attr(data-value);position:absolute;opacity:1 !important;bottom:100%;left:50%;transform:translate(-50%, 0);display:block !important;height:fit-content;margin:0}:host(.chart--display-data.chart--horizontal) table tbody tr td:not(:first-child):after{bottom:50%;left:calc(100% + .5rem);transform:translate(0, 50%)}:host(.chart--display-data.chart--horizontal) .chart__wrapper[data-longest-value]:after{display:block;content:attr(data-longest-value);font-size:var(--label-size);padding-left:.5em;opacity:0;pointer-events:none;white-space:nowrap}:host(.chart--display-data.chart--fit-content:not(.chart--horizontal)) .chart__outer{padding-top:1rem}:host(.chart--fit-content:not(.chart--horizontal)){width:100%;display:block}:host(.chart--fit-content:not(.chart--horizontal)) .chart__wrapper{width:fit-content}:host(.chart--fit-content:not(.chart--horizontal)) table{width:fit-content !important;padding-top:0;height:var(--chart-height-resp, 7.5rem)}:host(.chart--fit-content:not(.chart--horizontal)) tbody{position:relative}:host(.chart--fit-content:not(.chart--horizontal)) [part=group]{min-width:fit-content;width:fit-content;max-width:fit-content;padding-right:var(--fc-group-width, 1rem)}:host(.chart--fit-content:not(.chart--horizontal)) [part=value]{min-width:var(--fc-value-width, 0.75rem);width:var(--fc-value-width, 0.75rem);max-width:var(--fc-value-width, 0.75rem)}:host(.chart--fit-content:not(.chart--horizontal).chart--no-scale){--fc-group-width: 1.375rem;--fc-value-width: 1.5rem}:host(.chart--fit-content:not(.chart--horizontal).chart--no-scale) table{height:var(--chart-height-lg-set, 7.5rem)}@container (min-width: 23.4375em){.chart__wrapper{--fc-group-width: 1.375rem;--fc-value-width: 1.5rem}}button.tooltip:after{content:"?";margin-left:.25rem;display:inline-block;border:1px solid currentColor}.tooltip__content[popover]{z-index:var(--index-floating);background:var(--colour-primary);color:var(--colour-white);padding:1.5rem;border-radius:.5rem;box-shadow:0px 2px 9px rgba(0,0,0,.11);white-space:normal;position:fixed;border:none;margin:0;box-sizing:border-box;inset-area:bottom center;overflow:visible;width:calc(anchor-size(width) + var(--container-padding-x) + var(--container-padding-x) + 1.5rem) !important}.tooltip__content[popover]::after{content:"";position:absolute;bottom:100%;left:50%;margin-left:-0.25rem;border-width:.5rem;border-style:solid;border-color:rgba(0,0,0,0) rgba(0,0,0,0) var(--colour-primary) rgba(0,0,0,0);margin-bottom:-1px}/*# sourceMappingURL=barchart.component.css.map */
|
|
1
|
+
:host{--chart-colour-1-set: var(--chart-colour-1,#BEE8F8);--chart-colour-2-set: var(--chart-colour-2,#A6DCC7);--chart-colour-3-set: var(--chart-colour-3,#FAD0DA);--chart-colour-4-set: var(--chart-colour-4,#AFCCF2);--chart-colour-5-set: var(--chart-colour-5,#FFD2B4);--chart-colour-6-set: var(--chart-colour-6,#CDF0F2);--chart-colour-7-set: var(--chart-colour-7,#FFABC2);--chart-colour-8-set: var(--chart-colour-8,#DCEAF2);--chart-colour-9-set: var(--chart-colour-9,#EEBCB3);--chart-colour-10-set: var(--chart-colour-10,#F0BDFF);--chart-colour-1-hover: var(--chart-colour-1,#B6DEED);--chart-colour-2-hover: var(--chart-colour-2,#98CBB7);--chart-colour-3-hover: var(--chart-colour-3,#EFC8D1);--chart-colour-4-hover: var(--chart-colour-4,#A6C1E5);--chart-colour-5-hover: var(--chart-colour-5,#F4CAAF);--chart-colour-6-hover: var(--chart-colour-6,#C2E3E5);--chart-colour-7-hover: var(--chart-colour-7,#F5A2B9);--chart-colour-8-hover: var(--chart-colour-8,#CFDCE3);--chart-colour-9-hover: var(--chart-colour-9,#E3B2A9);--chart-colour-10-hover: var(--chart-colour-10,#E3B2F2);--chart-colour-success: #D2F0C9!important;--chart-colour-success-hover: #8AD873!important;--chart-colour-danger: #F5C2C7!important;--chart-colour-danger-hover: #f5c2e7!important;--chart-colour-warning: #FFD280!important;--chart-colour-warning-hover: #FFB020!important}.chart__key .key:nth-child(10n-9),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-8){--chart-colour: var(--chart-colour-1-set);--chart-colour-hover: var(--chart-colour-1-hover)}.chart__key .key:nth-child(10n-8),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-7){--chart-colour: var(--chart-colour-2-set);--chart-colour-hover: var(--chart-colour-2-hover)}.chart__key .key:nth-child(10n-7),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-6){--chart-colour: var(--chart-colour-3-set);--chart-colour-hover: var(--chart-colour-3-hover)}.chart__key .key:nth-child(10n-6),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-5){--chart-colour: var(--chart-colour-4-set);--chart-colour-hover: var(--chart-colour-4-hover)}.chart__key .key:nth-child(10n-5),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-4){--chart-colour: var(--chart-colour-5-set);--chart-colour-hover: var(--chart-colour-5-hover)}.chart__key .key:nth-child(10n-4),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-3){--chart-colour: var(--chart-colour-6-set);--chart-colour-hover: var(--chart-colour-6-hover)}.chart__key .key:nth-child(10n-3),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-2){--chart-colour: var(--chart-colour-7-set);--chart-colour-hover: var(--chart-colour-7-hover)}.chart__key .key:nth-child(10n-2),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-1){--chart-colour: var(--chart-colour-8-set);--chart-colour-hover: var(--chart-colour-8-hover)}.chart__key .key:nth-child(10n-1),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-0){--chart-colour: var(--chart-colour-9-set);--chart-colour-hover: var(--chart-colour-9-hover)}::slotted(table){display:none !important}:host{container-type:inline-size;margin-bottom:2rem;display:block}.chart__outer{display:flex;flex-direction:column;position:relative;font-weight:var(--chart-font-weight, bold);color:var(--chart-text-color, black);--body-colour-set: var(--body-colour, Canvas);--text-colour-set: var(--text-colour, black);--chart-height-set: var(--chart-height, 7.5rem);--chart-height-lg-set: var(--chart-height-lg, 12.5rem);--chart-height-resp: var(--chart-height-set);--index-below: -1;--index-base: 0;--index-focus: 2;--index-above: 10;--index-floating: 100;--index-menu: 200;--index-overlay: 1000;--key-label-width: 100%;--label-size: 0.75rem;--pie-size: calc(50% - 1.4rem);--line-thickness: 1px;--yaxis-width: auto;--yaxis-point-display: block;--yaxis-last-point-transform: translate(0,-50%);--bar-gap: min(10%, 0.75rem)}.chart__outer>*{display:block;order:2}.chart__outer tbody{--chart-direction: 360deg;--chart-day-bg-pos: 100% calc(var(--single-day) * 7) }@container (min-width: 23.4375em){.chart__outer :has(tr:nth-child(5) td:nth-child(4)),.chart__outer :has(tr:nth-child(10)){--yaxis-width: 0;--yaxis-point-display: none;--yaxis-last-point-transform: translate(0,-100%);--bar-gap: 0}.chart__outer .chart__wrapper{--chart-height-resp: var(--chart-height-lg-set);--pie-size: calc(33.333% - 1.4rem);--line-thickness: 0.8px;--yaxis-width: auto;--yaxis-point-display: block;--yaxis-last-point-transform: translate(0,-50%)}}@container (min-width: 48em){.chart__outer :has(tr:nth-child(10)){--bar-gap: 0}.chart__outer .chart__wrapper{--label-size: 0.875rem;--pie-size: calc(25% - 1.5rem);--line-thickness: 0.5px}}.chart__outer .chart__spacer span{opacity:0}.chart__outer>input[type=checkbox]{opacity:0;position:absolute;pointer-events:none;bottom:50%;left:50%}.chart__key{padding:0 0 0 0;margin-bottom:1.5rem;display:flex;overflow:auto;scroll-snap-type:x mandatory;scroll-padding:.75rem;gap:.5rem}.chart__key:has(label:first-child:last-child){display:var(--single-key-display, none)}.chart__key .key{margin:0}.chart__key .key:before{content:"";height:.8em;width:.8em;margin-right:.3em;background-color:var(--chart-colour);display:inline-block;border-radius:var(--key-border-radius, 4px)}.chart__key .key[data-label=Min],.chart__key .key[data-label=Max]{display:none}.chart__key .key .chart__total{display:none}.chart__outer input[type=checkbox]:focus:nth-child(1)~.chart__key .key:nth-child(1){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(2)~.chart__key .key:nth-child(2){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(3)~.chart__key .key:nth-child(3){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(4)~.chart__key .key:nth-child(4){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(5)~.chart__key .key:nth-child(5){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(6)~.chart__key .key:nth-child(6){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(7)~.chart__key .key:nth-child(7){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(8)~.chart__key .key:nth-child(8){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(9)~.chart__key .key:nth-child(9){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer>input[type=checkbox]:nth-of-type(1):not(:checked)~.chart__key .key:nth-of-type(1){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(2):not(:checked)~.chart__key .key:nth-of-type(2){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(3):not(:checked)~.chart__key .key:nth-of-type(3){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(4):not(:checked)~.chart__key .key:nth-of-type(4){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(5):not(:checked)~.chart__key .key:nth-of-type(5){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(6):not(:checked)~.chart__key .key:nth-of-type(6){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(7):not(:checked)~.chart__key .key:nth-of-type(7){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(8):not(:checked)~.chart__key .key:nth-of-type(8){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(9):not(:checked)~.chart__key .key:nth-of-type(9){opacity:.25}:host([data-yaxis]){--yaxis-display: flex}.chart__yaxis{display:var(--yaxis-display, none);flex-direction:column-reverse;width:var(--yaxis-width)}.chart__yaxis .axis__point{bottom:var(--percent);position:relative;height:0;white-space:nowrap}.chart__yaxis .axis__point:not(:last-child){display:var(--yaxis-point-display)}.chart__yaxis .axis__point span{display:block;transform:translate(0, -50%);padding-right:.25rem;text-align:right;font-weight:var(--chart-yaxis-fw, normal);font-size:var(--chart-yaxis-fs, 0.75rem);color:var(--colour-body)}.chart__yaxis .axis__point:last-child span{transform:var(--yaxis-last-point-transform)}.chart__xaxis{margin-bottom:1rem;display:flex;flex-direction:column-reverse;width:100%;position:absolute;left:0;bottom:-1rem}.chart__xaxis .axis__point{left:var(--percent);width:1px;position:absolute;height:0;white-space:nowrap}.chart__xaxis .axis__point span{display:block;transform:translate(-50%, 0%);text-align:center;font-size:var(--label-size);position:absolute;left:50%}.chart__guidelines{position:absolute;top:0;left:0;width:100%;height:100%;display:flex;flex-direction:column-reverse;pointer-events:none}.chart__guidelines .guideline{bottom:var(--percent);position:absolute;right:0;width:100%;height:0px;margin-bottom:-1px;border-bottom:1px dashed #eee;pointer-events:none;z-index:var(--index-below)}.chart__guidelines .guideline:not(.guideline--target) span{display:none}.chart__guidelines .guideline--target{border-bottom:1px dashed #000;z-index:var(--index-above);text-shadow:1px solid #fff;overflow:visible}.chart__guidelines .guideline--target span{position:absolute;bottom:0;font-size:var(--label-size);text-shadow:1px 1px 2px #fff;background:rgba(255,255,255,.6)}.chart__guidelines [data-value="0"]{border-bottom:1px solid var(--colour-primary)}.chart__guidelines [data-value="0"]:not(:first-child){border-bottom:1px dashed var(--colour-primary)}.chart__wrapper{display:block;display:flex;flex-direction:row;position:relative}.chart__wrapper .chart{position:relative;flex-grow:1}.chart__wrapper table{display:block;width:100% !important;padding-top:var(--chart-height-resp);position:relative;margin-bottom:0;overflow:visible}.chart__wrapper table thead{display:none}.chart__wrapper table tbody{display:flex;position:absolute;width:100%;height:100%;top:0;left:0;flex-direction:row;border:none}.chart__wrapper table tbody tr{display:flex;flex-direction:row;justify-content:var(--chart-bar-alignment, left);align-items:flex-end;border:none;width:100%;height:100%;position:relative;padding:0 2px;gap:var(--bar-gap)}.chart__wrapper table tbody tr td{font-weight:inherit}.chart__wrapper table tbody tr td:first-child{position:absolute;top:100%;left:0%;width:fit-content;padding:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:var(--label-size);text-align:center}@container (min-width: 48em){.chart__wrapper table tbody tr td:first-child{display:block}}.chart__wrapper table tbody tr td:first-child button{all:unset;cursor:pointer}.chart__wrapper table tbody tr td[data-label=Min],.chart__wrapper table tbody tr td[data-label=Max]{display:none}.chart__wrapper table tbody tr:first-child td:first-child,.chart__wrapper table tbody tr:last-child td:first-child{display:block}.chart__wrapper table tbody tr td:not(:first-child){height:100%;height:var(--percent, 0%);bottom:var(--bottom, 0%);width:100%;max-width:7.5rem;position:relative;padding:0;background:var(--chart-colour);border-top-right-radius:4px;border-top-left-radius:4px}@media screen and (prefers-color-scheme: dark){.chart__wrapper table tbody tr td:not(:first-child){background:color-mix(in oklab, var(--chart-colour), black 20%)}}.chart__wrapper table tbody tr td:not(:first-child):hover{background:var(--chart-colour-hover)}.chart__wrapper table tbody tr td:not(:first-child):has(span:empty),.chart__wrapper table tbody tr td:not(:first-child):empty{display:none}.chart__wrapper table tbody tr td:not(:first-child)[data-label]:before{display:none}.chart__wrapper table tbody tr td:not(:first-child) span{position:absolute;top:var(--cursor-y, 50%);left:var(--cursor-x, 50%);font-size:var(--label-size);line-height:1.2;transform:translate(-50%, 0);background:var(--chart-details-bg, var(--colour-canvas-2, Canvas));opacity:0;pointer-events:none;padding:.5rem;border-radius:.5rem;margin-bottom:.25rem;white-space:pre;text-align:left;box-shadow:var(--chart-details-shadow, 0 0.125rem 0.75rem rgba(0, 0, 0, 0.25));transform:translate(-50%, -100%)}.chart__wrapper table tbody tr td:not(:first-child) span::before{content:attr(data-group) "\a"}.chart__wrapper table tbody tr td:not(:first-child) span[data-label]::before{content:attr(data-group) "\a" attr(data-label) "\a"}.chart__wrapper table tbody tr td:not(:first-child):hover span{opacity:1;z-index:var(--index-above)}.chart__wrapper table tbody tr td:first-child[data-label]:before{display:none}@container (min-width: 48em){.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr td:first-child,.chart__wrapper table tbody:has(tr:nth-child(10)) tr td:first-child{display:none}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:first-child td:first-child,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:first-child td:first-child{left:0%;transform:translate(0, 0);display:block;text-align:left}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:last-child td:first-child,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:last-child td:first-child{left:100%;transform:translate(-100%, 0);display:block;text-align:right}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:first-child td:not(:first-child) span,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:first-child td:not(:first-child) span{left:-20%;transform:translate(0%, 0);text-align:left}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:last-child td:not(:first-child) span,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:last-child td:not(:first-child) span{left:120%;transform:translate(-100%, 0);text-align:right}}@container (min-width: 23.4375em){.chart__wrapper table tbody:has(tr:nth-child(25)) tr td:first-child{display:none !important}.chart__wrapper table tbody:has(tr:nth-child(25)) tr:is(:first-child,:nth-child(2n+1)) td:first-child{display:block !important}.chart__wrapper table tbody:has(tr:nth-child(50)) tr:is(:first-child,:nth-child(2n+1)) td:first-child,.chart__wrapper table tbody:has(tr:nth-child(50)) tr td:first-child{display:none !important}.chart__wrapper table tbody:has(tr:nth-child(50)) tr:is(:first-child,:nth-child(10n+1)) td:first-child{display:block !important}.chart__wrapper table tbody:has(tr:nth-child(100)) tr:is(:first-child,:nth-child(10n+1)) td:first-child,.chart__wrapper table tbody:has(tr:nth-child(100)) tr td:first-child{display:none !important}.chart__wrapper table tbody:has(tr:nth-child(100)) tr:is(:first-child,:nth-child(20n+1)) td:first-child{display:block !important}}:host(.chart-colour--success) td,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--success,.chart-colour--success td{--chart-colour: var(--chart-colour-success)!important}:host(.chart-colour--success) td:hover,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--success:hover,.chart-colour--success td:hover{--chart-colour-hover: var(--chart-colour-success-hover)!important}:host(.chart-colour--danger) td,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--danger,.chart-colour--danger,.chart-colour--danger td{--chart-colour: var(--chart-colour-danger)!important}:host(.chart-colour--danger) td:hover,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--danger:hover,.chart-colour--danger:hover,.chart-colour--danger td:hover{--chart-colour-hover: var(--chart-colour-danger-hover)!important}:host(.chart-colour--warning) td,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--warning,.chart-colour--warning,.chart-colour--warning td{--chart-colour: var(--chart-colour-warning)!important}:host(.chart-colour--warning) td:hover,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--warning:hover,.chart-colour--warning:hover,.chart-colour--warning td:hover{--chart-colour-hover: var(--chart-colour-warning-hover)!important}.chart__outer>input[type=checkbox]:nth-of-type(1):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(2){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(2):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(3){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(3):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(4){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(4):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(5){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(5):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(6){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(6):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(7){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(7):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(8){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(8):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(9){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(9):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(10){display:none;opacity:0}:host(.chart--horizontal) .chart__outer tbody{--chart-direction: 90deg;--chart-day-bg-pos: calc(var(--single-day) * 7) 100%;--bar-gap: 0}:host(.chart--horizontal) .chart__outer .chart__guidelines{position:absolute}:host(.chart--horizontal) .chart__outer .chart__guidelines .guideline{bottom:auto;left:var(--percent);height:100%;border-left:1px dashed #eee;width:0}:host(.chart--horizontal) .chart__outer .chart__guidelines .guideline span{display:block;font-size:var(--label-size);position:absolute;top:100%;transform:translate(-50%, 0.2em);opacity:1}:host(.chart--horizontal) .chart__outer .chart__yaxis{display:none}:host(.chart--horizontal) .chart__outer table{padding-top:0}:host(.chart--horizontal) .chart__outer table tbody{flex-direction:column;position:relative}:host(.chart--horizontal) .chart__outer table tbody tr{flex-direction:column;align-items:flex-start;margin-bottom:.5rem;padding:0}:host(.chart--horizontal) .chart__outer table tbody tr td{height:var(--bar-height, 1.5rem);bottom:0;left:var(--bottom, 0%);width:var(--comparison, var(--percent));max-width:100%;border-top-left-radius:0;border-bottom-right-radius:4px}:host(.chart--horizontal) .chart__outer table tbody tr td:first-child{position:static;transform:none;display:block !important;height:var(--bar-height, 1.5rem);line-height:var(--bar-height, 1.5rem);max-width:var(--xaxis-max-width, none)}:host(.chart--horizontal) .chart__outer table tbody tr td:first-child>*:not([popover]){max-width:100%;text-overflow:ellipsis;overflow:hidden}:host(.chart--horizontal) .chart__outer .chart__wrapper[data-longest-label]:before{display:block;content:attr(data-longest-label);font-size:var(--label-size);padding-right:.5em;opacity:0;pointer-events:none;white-space:nowrap;width:var(--xaxis-max-width, none)}:host(.chart--horizontal) .chart__outer:has(td .tooltip) .chart__wrapper[data-longest-label]:before{padding-right:2em;width:calc(var(--xaxis-max-width, none) - 1rem)}:host(.chart--horizontal) .chart__outer .chart__wrapper[data-longest-label] table tbody tr td:first-child{position:absolute;display:block !important;max-height:1.5rem;z-index:var(--index-above);top:0%;left:auto !important;right:100% !important;padding-right:.5em;width:fit-content}:host(.chart--horizontal) .chart__outer .chart__spacer span{display:none !important}:host(.chart--stacked) .chart__wrapper table tbody tr{--bar-gap: 0;flex-direction:column-reverse;justify-content:flex-start;align-items:center}:host(.chart--stacked) .chart__wrapper table tbody tr td{border-radius:0 !important}:host(.chart--stacked.chart--horizontal) .chart__wrapper table tbody tr{flex-direction:row}:host(.chart--stacked.chart--horizontal) .chart__wrapper table tbody tr::after{content:attr(data-numeric);position:absolute;opacity:1 !important;bottom:100%;left:50%;transform:translate(-50%, 0);display:block !important;height:fit-content;margin:0;bottom:50%;left:calc(var(--percent) + .5rem);transform:translate(0, 50%)}:host(.chart--stacked.chart--horizontal) .chart__wrapper table tbody tr td:after{content:none}.chart--animate.animating.inview{--animation-left: 2s}.chart--animate.animating.inview table tbody tr td:not(:first-child){transition:height 2s ease-out,width 2s ease-out,bottom 2s ease-out,left var(--animation-left) ease-out;transition-delay:calc(var(--row-index)*.1s)}.chart--animate:not(.inview) table tbody tr td:not(:first-child){--bottom: var(--min-bottom, 0%)!important;--percent: 0%!important;--axis: 0%!important;--comparison: 0%!important}.chart--animate.animating table tbody tr td:not(:first-child){overflow:hidden}:host(.chart--display-data) table tbody tr td:not(:first-child):after{content:attr(data-value);position:absolute;opacity:1 !important;bottom:100%;left:50%;transform:translate(-50%, 0);display:block !important;height:fit-content;margin:0}:host(.chart--display-data.chart--horizontal) table tbody tr td:not(:first-child):after{bottom:50%;left:calc(100% + .5rem);transform:translate(0, 50%)}:host(.chart--display-data.chart--horizontal) .chart__wrapper[data-longest-value]:after{display:block;content:attr(data-longest-value);font-size:var(--label-size);padding-left:.5em;opacity:0;pointer-events:none;white-space:nowrap}:host(.chart--display-data.chart--fit-content:not(.chart--horizontal)) .chart__outer{padding-top:1rem}:host(.chart--fit-content:not(.chart--horizontal)){width:100%;display:block}:host(.chart--fit-content:not(.chart--horizontal)) .chart__wrapper{width:fit-content}:host(.chart--fit-content:not(.chart--horizontal)) table{width:fit-content !important;padding-top:0;height:var(--chart-height-resp, 7.5rem)}:host(.chart--fit-content:not(.chart--horizontal)) tbody{position:relative}:host(.chart--fit-content:not(.chart--horizontal)) [part=group]{min-width:fit-content;width:fit-content;max-width:fit-content;padding-right:var(--fc-group-width, 1rem)}:host(.chart--fit-content:not(.chart--horizontal)) [part=value]{min-width:var(--fc-value-width, 0.75rem);width:var(--fc-value-width, 0.75rem);max-width:var(--fc-value-width, 0.75rem)}:host(.chart--fit-content:not(.chart--horizontal).chart--no-scale){--fc-group-width: 1.375rem;--fc-value-width: 1.5rem}:host(.chart--fit-content:not(.chart--horizontal).chart--no-scale) table{height:var(--chart-height-lg-set, 7.5rem)}@container (min-width: 23.4375em){.chart__wrapper{--fc-group-width: 1.375rem;--fc-value-width: 1.5rem}}button.tooltip:after{content:"?";margin-left:.25rem;display:inline-block;border:1px solid currentColor}.tooltip__content[popover]{z-index:var(--index-floating);background:var(--colour-primary);color:var(--colour-white);padding:1.5rem;border-radius:.5rem;box-shadow:0px 2px 9px rgba(0,0,0,.11);white-space:normal;position:fixed;border:none;margin:0;box-sizing:border-box;inset-area:bottom center;overflow:visible;width:calc(anchor-size(width) + var(--container-padding-x) + var(--container-padding-x) + 1.5rem) !important}.tooltip__content[popover]::after{content:"";position:absolute;bottom:100%;left:50%;margin-left:-0.25rem;border-width:.5rem;border-style:solid;border-color:rgba(0,0,0,0) rgba(0,0,0,0) var(--colour-primary) rgba(0,0,0,0);margin-bottom:-1px}/*# sourceMappingURL=barchart.component.css.map */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sourceRoot":"","sources":["../../sass/components/charts.module.scss","../../sass/components/barchart.component.scss"],"names":[],"mappings":"AA0DA,MAGI,0gBAGA,8hBAGF,0CACA,gDACA,yCACA,+CACA,0CACA,gDAKA,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDASJ,iBACE,wBAEF,MACE,2BACA,mBACA,cAEF,cAEE,aACA,
|
|
1
|
+
{"version":3,"sourceRoot":"","sources":["../../sass/components/charts.module.scss","../../sass/components/barchart.component.scss"],"names":[],"mappings":"AA0DA,MAGI,0gBAGA,8hBAGF,0CACA,gDACA,yCACA,+CACA,0CACA,gDAKA,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDASJ,iBACE,wBAEF,MACE,2BACA,mBACA,cAEF,cAEE,aACA,sBACA,kBACA,2CACA,qCASA,8CACA,6CAEA,gDACA,uDAEA,6CAUA,kBACA,gBACA,iBACA,kBACA,sBACA,kBACA,sBACA,wBACA,sBACA,+BACA,sBACA,oBACA,6BACA,gDACA,6BApCA,gBACE,cACA,QAYF,oBACE,0BACA,sDAsBF,kCAEE,yFAGE,iBACA,4BACA,iDACA,aAGF,8BACE,gDACA,mCACA,wBACA,oBACA,6BACA,iDAIJ,6BACE,qCAEE,aAGF,8BAEE,uBACA,+BACA,yBAIJ,kCACE,UAOJ,mCACE,UACA,kBACA,oBACA,WACA,SAGF,YAEE,gBACA,qBACA,aACA,cACA,6BACA,sBAEA,UAEA,8CACE,wCAGF,iBACE,SAEA,wBACE,WACA,YACA,WACA,kBACA,qCACA,qBACA,4CAGF,kEAEE,aAGF,+BACE,aAOJ,oFACE,wDACA,oEAFF,oFACE,wDACA,oEAFF,oFACE,wDACA,oEAFF,oFACE,wDACA,oEAFF,oFACE,wDACA,oEAFF,oFACE,wDACA,oEAFF,oFACE,wDACA,oEAFF,oFACE,wDACA,oEAFF,oFACE,wDACA,oEAcF,gGACE,YADF,gGACE,YADF,gGACE,YADF,gGACE,YADF,gGACE,YADF,gGACE,YADF,gGACE,YADF,gGACE,YADF,gGACE,YAMJ,oBAEE,sBAGF,cAEE,mCACA,8BACA,yBAEA,2BAEE,sBACA,kBACA,SACA,mBAEA,4CACE,mCAGF,gCACE,cACA,6BACA,qBACA,iBAEA,0CACA,yCACA,yBAGF,2CAEE,4CAON,cACE,mBACA,aACA,8BACA,WACA,kBACA,OACA,aAEA,2BAEE,oBACA,UACA,kBACA,SACA,mBAEA,gCACE,cACA,8BACA,kBACA,4BACA,kBACA,SAON,mBAEE,kBACA,MACA,OACA,WACA,YACA,aACA,8BACA,oBAEA,8BAEE,sBACA,kBACA,QACA,WACA,WACA,mBACA,8BACA,oBACA,2BAGA,2DACE,aAIJ,sCAEE,8BACA,2BACA,2BACA,iBAEA,2CACE,kBACA,SACA,4BACA,6BACA,gCAIJ,oCACE,8CAEA,sDAEE,+CAON,gBAEE,cACA,aACA,mBACA,kBAEA,uBAEE,kBACA,YAGF,sBACE,cACA,sBACA,qCACA,kBACA,gBACA,iBAEA,4BACE,aAGF,4BAEE,aACA,kBACA,WACA,YACA,MACA,OACA,mBACA,YAGF,+BACE,aACA,mBACA,iDACA,qBACA,YACA,WACA,YACA,kBACA,cACA,mBAEA,kCACE,oBAGF,8CACE,kBACA,SACA,QACA,kBACA,UACA,mBACA,gBACA,uBACA,4BACA,kBAEA,6BAZF,8CAcI,eAGF,qDACE,UACA,eAIJ,oGAEE,aAGF,mHAGE,cAGF,oDACE,YACA,0BACA,yBACA,WACA,iBACA,kBACA,UACA,+BAOA,4BACA,2BANA,+CAVF,oDAYI,gEAMF,0DACE,qCAGF,8HAEE,aAGF,uEACE,aAGF,yDACE,kBACA,yBACA,0BACA,4BACA,gBACA,6BACA,mEACA,UACA,oBACA,cACA,oBACA,qBAEA,gBACA,gBACA,+EACA,iCAGA,iEACE,8BAEF,6EACE,oDAIJ,+DACE,UACA,2BAMF,iEACE,aAMN,6BAII,uJACE,aAGF,+KAEE,QACA,0BACA,cACA,gBAEF,6KAEE,UACA,8BACA,cACA,iBAGF,qMAEE,UACA,2BACA,gBAGF,mMAEE,UACA,8BACA,kBAKN,kCAGI,oEACE,wBAGF,sGACE,yBAMF,0KAEE,wBAGF,uGACE,yBAMF,6KAEE,wBAGF,wGACE,0BASV,oKAGE,sDAEA,sLACE,kEAIJ,uLAIE,qDAEA,+MACE,iEAIJ,2LAIE,sDAEA,mNACE,kECtoBF,iIACE,aACA,UAFF,iIACE,aACA,UAFF,iIACE,aACA,UAFF,iIACE,aACA,UAFF,iIACE,aACA,UAFF,iIACE,aACA,UAFF,iIACE,aACA,UAFF,iIACE,aACA,UAFF,kIACE,aACA,UAQF,8CACE,yBACF,qDACA,aAGA,2DACE,kBAEA,sEACE,YACA,oBACA,YACA,4BACA,QAEA,2EACE,cACA,4BACA,kBACA,SACA,iCACA,UAKN,sDAEE,aAGF,8CAEE,cAGF,oDAEE,sBACA,kBAGF,uDACE,sBACA,uBACA,oBACA,UAEA,0DAEE,iCACA,SACA,uBACA,wCACA,eACA,yBACA,+BAGF,sEACE,gBACA,eACA,yBACA,iCACA,sCACA,uCAEA,uFACE,eACA,uBACA,gBAKN,mFACE,cACA,iCACA,4BACA,mBACA,UACA,oBACA,mBAEA,mCAGF,oGAEE,kBACA,gDAGF,0GAEI,kBAEA,yBACA,kBACA,2BACA,OACA,qBACA,sBACA,mBACA,kBAIJ,4DACE,wBAQF,sDACE,aACA,8BACA,2BACA,mBAEA,yDACE,2BAIN,wEAEE,mBAEA,+EACE,2BACA,kBACA,qBACA,YACA,SACA,6BACA,yBACA,mBACA,SACA,WACA,kCACA,4BAGF,iFACE,aAOJ,iCAEE,qBAEA,qEAEE,uGACA,4CAMF,iEACE,0CACA,wBACA,qBACA,2BAMF,8DACE,gBAaE,sEAEE,yBAGA,kBACA,qBAEA,YACA,SAEA,6BAEA,yBACA,mBAEA,SAWJ,wFAEE,WACA,wBACA,4BAKJ,wFACE,cACA,iCACA,4BACA,kBACA,UACA,oBACA,mBAKF,qFACE,iBAMJ,mDAEE,WACA,cAEA,mEACE,kBAGF,yDACE,6BACA,cACA,wCAGF,yDACE,kBAGF,gEACE,sBACA,kBACA,sBACA,0CAGF,gEACE,yCACA,qCACA,yCAIJ,mEACE,2BACA,yBAEA,yEACE,0CAQF,kCAHF,gBAII,2BACA,0BAUF,qBAEE,YACA,mBACA,qBACA,8BAKJ,2BAGE,8BACA,iCACA,0BACA,eAEA,oBACA,uCAGA,mBAIA,eAGA,YACA,SACA,sBAOE,yBAGF,iBAEA,6GAEA,kCACE,WACA,kBACA,YACA,SACA,qBACA,mBACA,mBACA,6EACA","file":"barchart.component.css"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
:host{--chart-colour-1-set: var(--chart-colour-1,#BEE8F8);--chart-colour-2-set: var(--chart-colour-2,#A6DCC7);--chart-colour-3-set: var(--chart-colour-3,#FAD0DA);--chart-colour-4-set: var(--chart-colour-4,#AFCCF2);--chart-colour-5-set: var(--chart-colour-5,#FFD2B4);--chart-colour-6-set: var(--chart-colour-6,#CDF0F2);--chart-colour-7-set: var(--chart-colour-7,#FFABC2);--chart-colour-8-set: var(--chart-colour-8,#DCEAF2);--chart-colour-9-set: var(--chart-colour-9,#EEBCB3);--chart-colour-10-set: var(--chart-colour-10,#F0BDFF);--chart-colour-1-hover: var(--chart-colour-1,#B6DEED);--chart-colour-2-hover: var(--chart-colour-2,#98CBB7);--chart-colour-3-hover: var(--chart-colour-3,#EFC8D1);--chart-colour-4-hover: var(--chart-colour-4,#A6C1E5);--chart-colour-5-hover: var(--chart-colour-5,#F4CAAF);--chart-colour-6-hover: var(--chart-colour-6,#C2E3E5);--chart-colour-7-hover: var(--chart-colour-7,#F5A2B9);--chart-colour-8-hover: var(--chart-colour-8,#CFDCE3);--chart-colour-9-hover: var(--chart-colour-9,#E3B2A9);--chart-colour-10-hover: var(--chart-colour-10,#E3B2F2);--chart-colour-success: #D2F0C9!important;--chart-colour-success-hover: #8AD873!important;--chart-colour-danger: #F5C2C7!important;--chart-colour-danger-hover: #f5c2e7!important;--chart-colour-warning: #FFD280!important;--chart-colour-warning-hover: #FFB020!important}.chart__key .key:nth-child(10n-9),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-8){--chart-colour: var(--chart-colour-1-set);--chart-colour-hover: var(--chart-colour-1-hover)}.chart__key .key:nth-child(10n-8),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-7){--chart-colour: var(--chart-colour-2-set);--chart-colour-hover: var(--chart-colour-2-hover)}.chart__key .key:nth-child(10n-7),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-6){--chart-colour: var(--chart-colour-3-set);--chart-colour-hover: var(--chart-colour-3-hover)}.chart__key .key:nth-child(10n-6),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-5){--chart-colour: var(--chart-colour-4-set);--chart-colour-hover: var(--chart-colour-4-hover)}.chart__key .key:nth-child(10n-5),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-4){--chart-colour: var(--chart-colour-5-set);--chart-colour-hover: var(--chart-colour-5-hover)}.chart__key .key:nth-child(10n-4),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-3){--chart-colour: var(--chart-colour-6-set);--chart-colour-hover: var(--chart-colour-6-hover)}.chart__key .key:nth-child(10n-3),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-2){--chart-colour: var(--chart-colour-7-set);--chart-colour-hover: var(--chart-colour-7-hover)}.chart__key .key:nth-child(10n-2),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-1){--chart-colour: var(--chart-colour-8-set);--chart-colour-hover: var(--chart-colour-8-hover)}.chart__key .key:nth-child(10n-1),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-0){--chart-colour: var(--chart-colour-9-set);--chart-colour-hover: var(--chart-colour-9-hover)}::slotted(table){display:none !important}:host{container-type:inline-size;margin-bottom:2rem;display:block}.chart__outer{display:flex;flex-direction:column;font-weight:var(--chart-font-weight, bold);color:var(--chart-text-color, black);--body-colour-set: var(--body-colour, Canvas);--text-colour-set: var(--text-colour, black);--chart-height-set: var(--chart-height, 7.5rem);--chart-height-lg-set: var(--chart-height-lg, 12.5rem);--chart-height-resp: var(--chart-height-set);--index-below: -1;--index-base: 0;--index-focus: 2;--index-above: 10;--index-floating: 100;--index-menu: 200;--index-overlay: 1000;--key-label-width: 100%;--label-size: 0.75rem;--pie-size: calc(50% - 1.4rem);--line-thickness: 1px;--yaxis-width: auto;--yaxis-point-display: block;--yaxis-last-point-transform: translate(0,-50%);--bar-gap: min(10%, 0.75rem)}.chart__outer>*{display:block;order:2}.chart__outer tbody{--chart-direction: 360deg;--chart-day-bg-pos: 100% calc(var(--single-day) * 7) }@container (min-width: 23.4375em){.chart__outer :has(tr:nth-child(5) td:nth-child(4)),.chart__outer :has(tr:nth-child(10)){--yaxis-width: 0;--yaxis-point-display: none;--yaxis-last-point-transform: translate(0,-100%);--bar-gap: 0}.chart__outer .chart__wrapper{--chart-height-resp: var(--chart-height-lg-set);--pie-size: calc(33.333% - 1.4rem);--line-thickness: 0.8px;--yaxis-width: auto;--yaxis-point-display: block;--yaxis-last-point-transform: translate(0,-50%)}}@container (min-width: 48em){.chart__outer :has(tr:nth-child(10)){--bar-gap: 0}.chart__outer .chart__wrapper{--label-size: 0.875rem;--pie-size: calc(25% - 1.5rem);--line-thickness: 0.5px}}.chart__outer .chart__spacer span{opacity:0}.chart__outer>input[type=checkbox]{opacity:0;position:absolute;pointer-events:none;bottom:50%;left:50%}.chart__key{padding:0 0 0 0;margin-bottom:1.5rem;display:flex;overflow:auto;scroll-snap-type:x mandatory;scroll-padding:.75rem;gap:.5rem}.chart__key:has(label:first-child:last-child){display:var(--single-key-display, none)}.chart__key .key{margin:0}.chart__key .key:before{content:"";height:.8em;width:.8em;margin-right:.3em;background-color:var(--chart-colour);display:inline-block;border-radius:var(--key-border-radius, 4px)}.chart__key .key[data-label=Min],.chart__key .key[data-label=Max]{display:none}.chart__key .key .chart__total{display:none}.chart__outer>input[type=checkbox]:nth-of-type(1):not(:checked)~.chart__key .key:nth-of-type(1){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(2):not(:checked)~.chart__key .key:nth-of-type(2){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(3):not(:checked)~.chart__key .key:nth-of-type(3){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(4):not(:checked)~.chart__key .key:nth-of-type(4){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(5):not(:checked)~.chart__key .key:nth-of-type(5){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(6):not(:checked)~.chart__key .key:nth-of-type(6){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(7):not(:checked)~.chart__key .key:nth-of-type(7){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(8):not(:checked)~.chart__key .key:nth-of-type(8){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(9):not(:checked)~.chart__key .key:nth-of-type(9){opacity:.25}:host([data-yaxis]){--yaxis-display: flex}.chart__yaxis{display:var(--yaxis-display, none);flex-direction:column-reverse;width:var(--yaxis-width)}.chart__yaxis .axis__point{bottom:var(--percent);position:relative;height:0;white-space:nowrap}.chart__yaxis .axis__point:not(:last-child){display:var(--yaxis-point-display)}.chart__yaxis .axis__point span{display:block;transform:translate(0, -50%);padding-right:.25rem;text-align:right;font-weight:var(--chart-yaxis-fw, normal);font-size:var(--chart-yaxis-fs, 0.75rem);color:var(--colour-body)}.chart__yaxis .axis__point:last-child span{transform:var(--yaxis-last-point-transform)}.chart__xaxis{margin-bottom:1rem;display:flex;flex-direction:column-reverse;width:100%;position:absolute;left:0;bottom:-1rem}.chart__xaxis .axis__point{left:var(--percent);width:1px;position:absolute;height:0;white-space:nowrap}.chart__xaxis .axis__point span{display:block;transform:translate(-50%, 0%);text-align:center;font-size:var(--label-size);position:absolute;left:50%}.chart__guidelines{position:absolute;top:0;left:0;width:100%;height:100%;display:flex;flex-direction:column-reverse;pointer-events:none}.chart__guidelines .guideline{bottom:var(--percent);position:absolute;right:0;width:100%;height:0px;margin-bottom:-1px;border-bottom:1px dashed #eee;pointer-events:none;z-index:var(--index-below)}.chart__guidelines .guideline:not(.guideline--target) span{display:none}.chart__guidelines .guideline--target{border-bottom:1px dashed #000;z-index:var(--index-above);text-shadow:1px solid #fff;overflow:visible}.chart__guidelines .guideline--target span{position:absolute;bottom:0;font-size:var(--label-size);text-shadow:1px 1px 2px #fff;background:rgba(255,255,255,.6)}.chart__guidelines [data-value="0"]{border-bottom:1px solid var(--colour-primary)}.chart__guidelines [data-value="0"]:not(:first-child){border-bottom:1px dashed var(--colour-primary)}.chart__wrapper{display:block;display:flex;flex-direction:row;position:relative}.chart__wrapper .chart{position:relative;flex-grow:1}.chart__wrapper table{display:block;width:100% !important;padding-top:var(--chart-height-resp);position:relative;margin-bottom:0;overflow:visible}.chart__wrapper table thead{display:none}.chart__wrapper table tbody{display:flex;position:absolute;width:100%;height:100%;top:0;left:0;flex-direction:row;border:none}.chart__wrapper table tbody tr{display:flex;flex-direction:row;justify-content:var(--chart-bar-alignment, center);align-items:flex-end;border:none;width:100%;height:100%;position:relative;padding:0 2px;gap:var(--bar-gap)}.chart__wrapper table tbody tr td{font-weight:inherit}.chart__wrapper table tbody tr td:first-child{position:absolute;top:100%;left:0%;width:fit-content;padding:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:var(--label-size);text-align:center}@container (min-width: 48em){.chart__wrapper table tbody tr td:first-child{display:block}}.chart__wrapper table tbody tr td:first-child button{all:unset;cursor:pointer}.chart__wrapper table tbody tr td[data-label=Min],.chart__wrapper table tbody tr td[data-label=Max]{display:none}.chart__wrapper table tbody tr:first-child td:first-child,.chart__wrapper table tbody tr:last-child td:first-child{display:block}.chart__wrapper table tbody tr td:not(:first-child){height:100%;height:var(--percent, 0%);bottom:var(--bottom, 0%);width:100%;max-width:7.5rem;position:relative;padding:0;background:var(--chart-colour);border-top-right-radius:4px;border-top-left-radius:4px}@media screen and (prefers-color-scheme: dark){.chart__wrapper table tbody tr td:not(:first-child){background:color-mix(in oklab, var(--chart-colour), black 20%)}}.chart__wrapper table tbody tr td:not(:first-child):hover{background:var(--chart-colour-hover)}.chart__wrapper table tbody tr td:not(:first-child):has(span:empty),.chart__wrapper table tbody tr td:not(:first-child):empty{display:none}.chart__wrapper table tbody tr td:not(:first-child)[data-label]:before{display:none}.chart__wrapper table tbody tr td:not(:first-child) span{position:absolute;top:var(--cursor-y, 50%);left:var(--cursor-x, 50%);font-size:var(--label-size);line-height:1.2;transform:translate(-50%, 0);background:var(--chart-details-bg, var(--colour-canvas-2, Canvas));opacity:0;pointer-events:none;padding:.5rem;border-radius:.5rem;margin-bottom:.25rem;white-space:pre;text-align:left;box-shadow:var(--chart-details-shadow, 0 0.125rem 0.75rem rgba(0, 0, 0, 0.25));transform:translate(-50%, -100%)}.chart__wrapper table tbody tr td:not(:first-child) span::before{content:attr(data-group) "\a"}.chart__wrapper table tbody tr td:not(:first-child) span[data-label]::before{content:attr(data-group) "\a" attr(data-label) "\a"}.chart__wrapper table tbody tr td:not(:first-child):hover span{opacity:1;z-index:var(--index-above)}.chart__wrapper table tbody tr td:first-child[data-label]:before{display:none}@container (min-width: 48em){.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr td:first-child,.chart__wrapper table tbody:has(tr:nth-child(10)) tr td:first-child{display:none}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:first-child td:first-child,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:first-child td:first-child{left:0%;transform:translate(0, 0);display:block;text-align:left}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:last-child td:first-child,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:last-child td:first-child{left:100%;transform:translate(-100%, 0);display:block;text-align:right}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:first-child td:not(:first-child) span,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:first-child td:not(:first-child) span{left:-20%;transform:translate(0%, 0);text-align:left}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:last-child td:not(:first-child) span,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:last-child td:not(:first-child) span{left:120%;transform:translate(-100%, 0);text-align:right}}@container (min-width: 23.4375em){.chart__wrapper table tbody:has(tr:nth-child(25)) tr td:first-child{display:none !important}.chart__wrapper table tbody:has(tr:nth-child(25)) tr:is(:first-child,:nth-child(2n+1)) td:first-child{display:block !important}.chart__wrapper table tbody:has(tr:nth-child(50)) tr:is(:first-child,:nth-child(2n+1)) td:first-child,.chart__wrapper table tbody:has(tr:nth-child(50)) tr td:first-child{display:none !important}.chart__wrapper table tbody:has(tr:nth-child(50)) tr:is(:first-child,:nth-child(10n+1)) td:first-child{display:block !important}.chart__wrapper table tbody:has(tr:nth-child(100)) tr:is(:first-child,:nth-child(10n+1)) td:first-child,.chart__wrapper table tbody:has(tr:nth-child(100)) tr td:first-child{display:none !important}.chart__wrapper table tbody:has(tr:nth-child(100)) tr:is(:first-child,:nth-child(20n+1)) td:first-child{display:block !important}}:host(.chart-colour--success) td,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--success,.chart-colour--success td{--chart-colour: var(--chart-colour-success)!important}:host(.chart-colour--success) td:hover,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--success:hover,.chart-colour--success td:hover{--chart-colour-hover: var(--chart-colour-success-hover)!important}:host(.chart-colour--danger) td,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--danger,.chart-colour--danger,.chart-colour--danger td{--chart-colour: var(--chart-colour-danger)!important}:host(.chart-colour--danger) td:hover,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--danger:hover,.chart-colour--danger:hover,.chart-colour--danger td:hover{--chart-colour-hover: var(--chart-colour-danger-hover)!important}:host(.chart-colour--warning) td,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--warning,.chart-colour--warning,.chart-colour--warning td{--chart-colour: var(--chart-colour-warning)!important}:host(.chart-colour--warning) td:hover,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--warning:hover,.chart-colour--warning:hover,.chart-colour--warning td:hover{--chart-colour-hover: var(--chart-colour-warning-hover)!important}/*# sourceMappingURL=charts.module.css.map */
|
|
1
|
+
:host{--chart-colour-1-set: var(--chart-colour-1,#BEE8F8);--chart-colour-2-set: var(--chart-colour-2,#A6DCC7);--chart-colour-3-set: var(--chart-colour-3,#FAD0DA);--chart-colour-4-set: var(--chart-colour-4,#AFCCF2);--chart-colour-5-set: var(--chart-colour-5,#FFD2B4);--chart-colour-6-set: var(--chart-colour-6,#CDF0F2);--chart-colour-7-set: var(--chart-colour-7,#FFABC2);--chart-colour-8-set: var(--chart-colour-8,#DCEAF2);--chart-colour-9-set: var(--chart-colour-9,#EEBCB3);--chart-colour-10-set: var(--chart-colour-10,#F0BDFF);--chart-colour-1-hover: var(--chart-colour-1,#B6DEED);--chart-colour-2-hover: var(--chart-colour-2,#98CBB7);--chart-colour-3-hover: var(--chart-colour-3,#EFC8D1);--chart-colour-4-hover: var(--chart-colour-4,#A6C1E5);--chart-colour-5-hover: var(--chart-colour-5,#F4CAAF);--chart-colour-6-hover: var(--chart-colour-6,#C2E3E5);--chart-colour-7-hover: var(--chart-colour-7,#F5A2B9);--chart-colour-8-hover: var(--chart-colour-8,#CFDCE3);--chart-colour-9-hover: var(--chart-colour-9,#E3B2A9);--chart-colour-10-hover: var(--chart-colour-10,#E3B2F2);--chart-colour-success: #D2F0C9!important;--chart-colour-success-hover: #8AD873!important;--chart-colour-danger: #F5C2C7!important;--chart-colour-danger-hover: #f5c2e7!important;--chart-colour-warning: #FFD280!important;--chart-colour-warning-hover: #FFB020!important}.chart__key .key:nth-child(10n-9),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-8){--chart-colour: var(--chart-colour-1-set);--chart-colour-hover: var(--chart-colour-1-hover)}.chart__key .key:nth-child(10n-8),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-7){--chart-colour: var(--chart-colour-2-set);--chart-colour-hover: var(--chart-colour-2-hover)}.chart__key .key:nth-child(10n-7),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-6){--chart-colour: var(--chart-colour-3-set);--chart-colour-hover: var(--chart-colour-3-hover)}.chart__key .key:nth-child(10n-6),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-5){--chart-colour: var(--chart-colour-4-set);--chart-colour-hover: var(--chart-colour-4-hover)}.chart__key .key:nth-child(10n-5),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-4){--chart-colour: var(--chart-colour-5-set);--chart-colour-hover: var(--chart-colour-5-hover)}.chart__key .key:nth-child(10n-4),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-3){--chart-colour: var(--chart-colour-6-set);--chart-colour-hover: var(--chart-colour-6-hover)}.chart__key .key:nth-child(10n-3),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-2){--chart-colour: var(--chart-colour-7-set);--chart-colour-hover: var(--chart-colour-7-hover)}.chart__key .key:nth-child(10n-2),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-1){--chart-colour: var(--chart-colour-8-set);--chart-colour-hover: var(--chart-colour-8-hover)}.chart__key .key:nth-child(10n-1),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-0){--chart-colour: var(--chart-colour-9-set);--chart-colour-hover: var(--chart-colour-9-hover)}::slotted(table){display:none !important}:host{container-type:inline-size;margin-bottom:2rem;display:block}.chart__outer{display:flex;flex-direction:column;position:relative;font-weight:var(--chart-font-weight, bold);color:var(--chart-text-color, black);--body-colour-set: var(--body-colour, Canvas);--text-colour-set: var(--text-colour, black);--chart-height-set: var(--chart-height, 7.5rem);--chart-height-lg-set: var(--chart-height-lg, 12.5rem);--chart-height-resp: var(--chart-height-set);--index-below: -1;--index-base: 0;--index-focus: 2;--index-above: 10;--index-floating: 100;--index-menu: 200;--index-overlay: 1000;--key-label-width: 100%;--label-size: 0.75rem;--pie-size: calc(50% - 1.4rem);--line-thickness: 1px;--yaxis-width: auto;--yaxis-point-display: block;--yaxis-last-point-transform: translate(0,-50%);--bar-gap: min(10%, 0.75rem)}.chart__outer>*{display:block;order:2}.chart__outer tbody{--chart-direction: 360deg;--chart-day-bg-pos: 100% calc(var(--single-day) * 7) }@container (min-width: 23.4375em){.chart__outer :has(tr:nth-child(5) td:nth-child(4)),.chart__outer :has(tr:nth-child(10)){--yaxis-width: 0;--yaxis-point-display: none;--yaxis-last-point-transform: translate(0,-100%);--bar-gap: 0}.chart__outer .chart__wrapper{--chart-height-resp: var(--chart-height-lg-set);--pie-size: calc(33.333% - 1.4rem);--line-thickness: 0.8px;--yaxis-width: auto;--yaxis-point-display: block;--yaxis-last-point-transform: translate(0,-50%)}}@container (min-width: 48em){.chart__outer :has(tr:nth-child(10)){--bar-gap: 0}.chart__outer .chart__wrapper{--label-size: 0.875rem;--pie-size: calc(25% - 1.5rem);--line-thickness: 0.5px}}.chart__outer .chart__spacer span{opacity:0}.chart__outer>input[type=checkbox]{opacity:0;position:absolute;pointer-events:none;bottom:50%;left:50%}.chart__key{padding:0 0 0 0;margin-bottom:1.5rem;display:flex;overflow:auto;scroll-snap-type:x mandatory;scroll-padding:.75rem;gap:.5rem}.chart__key:has(label:first-child:last-child){display:var(--single-key-display, none)}.chart__key .key{margin:0}.chart__key .key:before{content:"";height:.8em;width:.8em;margin-right:.3em;background-color:var(--chart-colour);display:inline-block;border-radius:var(--key-border-radius, 4px)}.chart__key .key[data-label=Min],.chart__key .key[data-label=Max]{display:none}.chart__key .key .chart__total{display:none}.chart__outer input[type=checkbox]:focus:nth-child(1)~.chart__key .key:nth-child(1){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(2)~.chart__key .key:nth-child(2){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(3)~.chart__key .key:nth-child(3){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(4)~.chart__key .key:nth-child(4){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(5)~.chart__key .key:nth-child(5){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(6)~.chart__key .key:nth-child(6){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(7)~.chart__key .key:nth-child(7){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(8)~.chart__key .key:nth-child(8){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(9)~.chart__key .key:nth-child(9){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer>input[type=checkbox]:nth-of-type(1):not(:checked)~.chart__key .key:nth-of-type(1){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(2):not(:checked)~.chart__key .key:nth-of-type(2){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(3):not(:checked)~.chart__key .key:nth-of-type(3){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(4):not(:checked)~.chart__key .key:nth-of-type(4){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(5):not(:checked)~.chart__key .key:nth-of-type(5){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(6):not(:checked)~.chart__key .key:nth-of-type(6){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(7):not(:checked)~.chart__key .key:nth-of-type(7){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(8):not(:checked)~.chart__key .key:nth-of-type(8){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(9):not(:checked)~.chart__key .key:nth-of-type(9){opacity:.25}:host([data-yaxis]){--yaxis-display: flex}.chart__yaxis{display:var(--yaxis-display, none);flex-direction:column-reverse;width:var(--yaxis-width)}.chart__yaxis .axis__point{bottom:var(--percent);position:relative;height:0;white-space:nowrap}.chart__yaxis .axis__point:not(:last-child){display:var(--yaxis-point-display)}.chart__yaxis .axis__point span{display:block;transform:translate(0, -50%);padding-right:.25rem;text-align:right;font-weight:var(--chart-yaxis-fw, normal);font-size:var(--chart-yaxis-fs, 0.75rem);color:var(--colour-body)}.chart__yaxis .axis__point:last-child span{transform:var(--yaxis-last-point-transform)}.chart__xaxis{margin-bottom:1rem;display:flex;flex-direction:column-reverse;width:100%;position:absolute;left:0;bottom:-1rem}.chart__xaxis .axis__point{left:var(--percent);width:1px;position:absolute;height:0;white-space:nowrap}.chart__xaxis .axis__point span{display:block;transform:translate(-50%, 0%);text-align:center;font-size:var(--label-size);position:absolute;left:50%}.chart__guidelines{position:absolute;top:0;left:0;width:100%;height:100%;display:flex;flex-direction:column-reverse;pointer-events:none}.chart__guidelines .guideline{bottom:var(--percent);position:absolute;right:0;width:100%;height:0px;margin-bottom:-1px;border-bottom:1px dashed #eee;pointer-events:none;z-index:var(--index-below)}.chart__guidelines .guideline:not(.guideline--target) span{display:none}.chart__guidelines .guideline--target{border-bottom:1px dashed #000;z-index:var(--index-above);text-shadow:1px solid #fff;overflow:visible}.chart__guidelines .guideline--target span{position:absolute;bottom:0;font-size:var(--label-size);text-shadow:1px 1px 2px #fff;background:rgba(255,255,255,.6)}.chart__guidelines [data-value="0"]{border-bottom:1px solid var(--colour-primary)}.chart__guidelines [data-value="0"]:not(:first-child){border-bottom:1px dashed var(--colour-primary)}.chart__wrapper{display:block;display:flex;flex-direction:row;position:relative}.chart__wrapper .chart{position:relative;flex-grow:1}.chart__wrapper table{display:block;width:100% !important;padding-top:var(--chart-height-resp);position:relative;margin-bottom:0;overflow:visible}.chart__wrapper table thead{display:none}.chart__wrapper table tbody{display:flex;position:absolute;width:100%;height:100%;top:0;left:0;flex-direction:row;border:none}.chart__wrapper table tbody tr{display:flex;flex-direction:row;justify-content:var(--chart-bar-alignment, left);align-items:flex-end;border:none;width:100%;height:100%;position:relative;padding:0 2px;gap:var(--bar-gap)}.chart__wrapper table tbody tr td{font-weight:inherit}.chart__wrapper table tbody tr td:first-child{position:absolute;top:100%;left:0%;width:fit-content;padding:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:var(--label-size);text-align:center}@container (min-width: 48em){.chart__wrapper table tbody tr td:first-child{display:block}}.chart__wrapper table tbody tr td:first-child button{all:unset;cursor:pointer}.chart__wrapper table tbody tr td[data-label=Min],.chart__wrapper table tbody tr td[data-label=Max]{display:none}.chart__wrapper table tbody tr:first-child td:first-child,.chart__wrapper table tbody tr:last-child td:first-child{display:block}.chart__wrapper table tbody tr td:not(:first-child){height:100%;height:var(--percent, 0%);bottom:var(--bottom, 0%);width:100%;max-width:7.5rem;position:relative;padding:0;background:var(--chart-colour);border-top-right-radius:4px;border-top-left-radius:4px}@media screen and (prefers-color-scheme: dark){.chart__wrapper table tbody tr td:not(:first-child){background:color-mix(in oklab, var(--chart-colour), black 20%)}}.chart__wrapper table tbody tr td:not(:first-child):hover{background:var(--chart-colour-hover)}.chart__wrapper table tbody tr td:not(:first-child):has(span:empty),.chart__wrapper table tbody tr td:not(:first-child):empty{display:none}.chart__wrapper table tbody tr td:not(:first-child)[data-label]:before{display:none}.chart__wrapper table tbody tr td:not(:first-child) span{position:absolute;top:var(--cursor-y, 50%);left:var(--cursor-x, 50%);font-size:var(--label-size);line-height:1.2;transform:translate(-50%, 0);background:var(--chart-details-bg, var(--colour-canvas-2, Canvas));opacity:0;pointer-events:none;padding:.5rem;border-radius:.5rem;margin-bottom:.25rem;white-space:pre;text-align:left;box-shadow:var(--chart-details-shadow, 0 0.125rem 0.75rem rgba(0, 0, 0, 0.25));transform:translate(-50%, -100%)}.chart__wrapper table tbody tr td:not(:first-child) span::before{content:attr(data-group) "\a"}.chart__wrapper table tbody tr td:not(:first-child) span[data-label]::before{content:attr(data-group) "\a" attr(data-label) "\a"}.chart__wrapper table tbody tr td:not(:first-child):hover span{opacity:1;z-index:var(--index-above)}.chart__wrapper table tbody tr td:first-child[data-label]:before{display:none}@container (min-width: 48em){.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr td:first-child,.chart__wrapper table tbody:has(tr:nth-child(10)) tr td:first-child{display:none}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:first-child td:first-child,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:first-child td:first-child{left:0%;transform:translate(0, 0);display:block;text-align:left}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:last-child td:first-child,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:last-child td:first-child{left:100%;transform:translate(-100%, 0);display:block;text-align:right}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:first-child td:not(:first-child) span,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:first-child td:not(:first-child) span{left:-20%;transform:translate(0%, 0);text-align:left}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:last-child td:not(:first-child) span,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:last-child td:not(:first-child) span{left:120%;transform:translate(-100%, 0);text-align:right}}@container (min-width: 23.4375em){.chart__wrapper table tbody:has(tr:nth-child(25)) tr td:first-child{display:none !important}.chart__wrapper table tbody:has(tr:nth-child(25)) tr:is(:first-child,:nth-child(2n+1)) td:first-child{display:block !important}.chart__wrapper table tbody:has(tr:nth-child(50)) tr:is(:first-child,:nth-child(2n+1)) td:first-child,.chart__wrapper table tbody:has(tr:nth-child(50)) tr td:first-child{display:none !important}.chart__wrapper table tbody:has(tr:nth-child(50)) tr:is(:first-child,:nth-child(10n+1)) td:first-child{display:block !important}.chart__wrapper table tbody:has(tr:nth-child(100)) tr:is(:first-child,:nth-child(10n+1)) td:first-child,.chart__wrapper table tbody:has(tr:nth-child(100)) tr td:first-child{display:none !important}.chart__wrapper table tbody:has(tr:nth-child(100)) tr:is(:first-child,:nth-child(20n+1)) td:first-child{display:block !important}}:host(.chart-colour--success) td,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--success,.chart-colour--success td{--chart-colour: var(--chart-colour-success)!important}:host(.chart-colour--success) td:hover,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--success:hover,.chart-colour--success td:hover{--chart-colour-hover: var(--chart-colour-success-hover)!important}:host(.chart-colour--danger) td,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--danger,.chart-colour--danger,.chart-colour--danger td{--chart-colour: var(--chart-colour-danger)!important}:host(.chart-colour--danger) td:hover,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--danger:hover,.chart-colour--danger:hover,.chart-colour--danger td:hover{--chart-colour-hover: var(--chart-colour-danger-hover)!important}:host(.chart-colour--warning) td,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--warning,.chart-colour--warning,.chart-colour--warning td{--chart-colour: var(--chart-colour-warning)!important}:host(.chart-colour--warning) td:hover,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--warning:hover,.chart-colour--warning:hover,.chart-colour--warning td:hover{--chart-colour-hover: var(--chart-colour-warning-hover)!important}/*# sourceMappingURL=charts.module.css.map */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sourceRoot":"","sources":["../../sass/components/charts.module.scss"],"names":[],"mappings":"AA0DA,MAGI,0gBAGA,8hBAGF,0CACA,gDACA,yCACA,+CACA,0CACA,gDAKA,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDASJ,iBACE,wBAEF,MACE,2BACA,mBACA,cAEF,cAEE,aACA,
|
|
1
|
+
{"version":3,"sourceRoot":"","sources":["../../sass/components/charts.module.scss"],"names":[],"mappings":"AA0DA,MAGI,0gBAGA,8hBAGF,0CACA,gDACA,yCACA,+CACA,0CACA,gDAKA,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDAJF,qGAGE,0CACA,kDASJ,iBACE,wBAEF,MACE,2BACA,mBACA,cAEF,cAEE,aACA,sBACA,kBACA,2CACA,qCASA,8CACA,6CAEA,gDACA,uDAEA,6CAUA,kBACA,gBACA,iBACA,kBACA,sBACA,kBACA,sBACA,wBACA,sBACA,+BACA,sBACA,oBACA,6BACA,gDACA,6BApCA,gBACE,cACA,QAYF,oBACE,0BACA,sDAsBF,kCAEE,yFAGE,iBACA,4BACA,iDACA,aAGF,8BACE,gDACA,mCACA,wBACA,oBACA,6BACA,iDAIJ,6BACE,qCAEE,aAGF,8BAEE,uBACA,+BACA,yBAIJ,kCACE,UAOJ,mCACE,UACA,kBACA,oBACA,WACA,SAGF,YAEE,gBACA,qBACA,aACA,cACA,6BACA,sBAEA,UAEA,8CACE,wCAGF,iBACE,SAEA,wBACE,WACA,YACA,WACA,kBACA,qCACA,qBACA,4CAGF,kEAEE,aAGF,+BACE,aAOJ,oFACE,wDACA,oEAFF,oFACE,wDACA,oEAFF,oFACE,wDACA,oEAFF,oFACE,wDACA,oEAFF,oFACE,wDACA,oEAFF,oFACE,wDACA,oEAFF,oFACE,wDACA,oEAFF,oFACE,wDACA,oEAFF,oFACE,wDACA,oEAcF,gGACE,YADF,gGACE,YADF,gGACE,YADF,gGACE,YADF,gGACE,YADF,gGACE,YADF,gGACE,YADF,gGACE,YADF,gGACE,YAMJ,oBAEE,sBAGF,cAEE,mCACA,8BACA,yBAEA,2BAEE,sBACA,kBACA,SACA,mBAEA,4CACE,mCAGF,gCACE,cACA,6BACA,qBACA,iBAEA,0CACA,yCACA,yBAGF,2CAEE,4CAON,cACE,mBACA,aACA,8BACA,WACA,kBACA,OACA,aAEA,2BAEE,oBACA,UACA,kBACA,SACA,mBAEA,gCACE,cACA,8BACA,kBACA,4BACA,kBACA,SAON,mBAEE,kBACA,MACA,OACA,WACA,YACA,aACA,8BACA,oBAEA,8BAEE,sBACA,kBACA,QACA,WACA,WACA,mBACA,8BACA,oBACA,2BAGA,2DACE,aAIJ,sCAEE,8BACA,2BACA,2BACA,iBAEA,2CACE,kBACA,SACA,4BACA,6BACA,gCAIJ,oCACE,8CAEA,sDAEE,+CAON,gBAEE,cACA,aACA,mBACA,kBAEA,uBAEE,kBACA,YAGF,sBACE,cACA,sBACA,qCACA,kBACA,gBACA,iBAEA,4BACE,aAGF,4BAEE,aACA,kBACA,WACA,YACA,MACA,OACA,mBACA,YAGF,+BACE,aACA,mBACA,iDACA,qBACA,YACA,WACA,YACA,kBACA,cACA,mBAEA,kCACE,oBAGF,8CACE,kBACA,SACA,QACA,kBACA,UACA,mBACA,gBACA,uBACA,4BACA,kBAEA,6BAZF,8CAcI,eAGF,qDACE,UACA,eAIJ,oGAEE,aAGF,mHAGE,cAGF,oDACE,YACA,0BACA,yBACA,WACA,iBACA,kBACA,UACA,+BAOA,4BACA,2BANA,+CAVF,oDAYI,gEAMF,0DACE,qCAGF,8HAEE,aAGF,uEACE,aAGF,yDACE,kBACA,yBACA,0BACA,4BACA,gBACA,6BACA,mEACA,UACA,oBACA,cACA,oBACA,qBAEA,gBACA,gBACA,+EACA,iCAGA,iEACE,8BAEF,6EACE,oDAIJ,+DACE,UACA,2BAMF,iEACE,aAMN,6BAII,uJACE,aAGF,+KAEE,QACA,0BACA,cACA,gBAEF,6KAEE,UACA,8BACA,cACA,iBAGF,qMAEE,UACA,2BACA,gBAGF,mMAEE,UACA,8BACA,kBAKN,kCAGI,oEACE,wBAGF,sGACE,yBAMF,0KAEE,wBAGF,uGACE,yBAMF,6KAEE,wBAGF,wGACE,0BASV,oKAGE,sDAEA,sLACE,kEAIJ,uLAIE,qDAEA,+MACE,iEAIJ,2LAIE,sDAEA,mNACE","file":"charts.module.css"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
// @ts-nocheck
|
|
2
|
+
export const trackComponentRegistered = (componentName) => {
|
|
3
|
+
// Data layer Web component created
|
|
4
|
+
window.dataLayer = window.dataLayer || [];
|
|
5
|
+
window.dataLayer.push({
|
|
6
|
+
"event": "customElementRegistered",
|
|
7
|
+
"element": componentName
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
export const trackComponent = (component, componentName, trackEvents) => {
|
|
11
|
+
// Data layer Web component created
|
|
12
|
+
window.dataLayer = window.dataLayer || [];
|
|
13
|
+
window.dataLayer.push({
|
|
14
|
+
"event": "customElementAdded",
|
|
15
|
+
"element": componentName
|
|
16
|
+
});
|
|
17
|
+
trackEvents.forEach((eventName) => {
|
|
18
|
+
component.addEventListener(eventName, function (event) {
|
|
19
|
+
let eventDetails = {
|
|
20
|
+
"event": eventName,
|
|
21
|
+
"element": componentName,
|
|
22
|
+
"target": event.target
|
|
23
|
+
};
|
|
24
|
+
Object.keys(event.detail).forEach((eventKey) => {
|
|
25
|
+
const eventDetail = event.detail[eventKey];
|
|
26
|
+
eventDetails[eventKey] = eventDetail;
|
|
27
|
+
});
|
|
28
|
+
window.dataLayer.push(eventDetails);
|
|
29
|
+
});
|
|
30
|
+
});
|
|
31
|
+
return true;
|
|
32
|
+
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* iamKey
|
|
2
|
+
* iamKey v6.0.0
|
|
3
3
|
* Copyright 2022-2024 iamproperty
|
|
4
4
|
*/window.dataLayer=window.dataLayer||[],window.dataLayer.push({event:"customElementRegistered",element:"accordion"});class s extends HTMLElement{constructor(){super(),this.attachShadow({mode:"open"});const o=document.body.hasAttribute("data-assets-location")?document.body.getAttribute("data-assets-location"):"/assets",t=document.body.hasAttribute("data-core-css")?document.body.getAttribute("data-core-css"):`${o}/css/core.min.css`,e=document.createElement("template");e.innerHTML=`
|
|
5
5
|
<style>
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* iamKey
|
|
2
|
+
* iamKey v6.0.0
|
|
3
3
|
* Copyright 2022-2024 iamproperty
|
|
4
4
|
*/const _=function(i){typeof window.player<"u"&&typeof window.player.pauseVideo=="function"&&window.player.pauseVideo();var a=i.getAttribute("data-id"),c=i.getAttribute("id");if(typeof c>"u"||c==null){var l=String.fromCharCode(65+Math.floor(Math.random()*26));c=l+Date.now(),i.setAttribute("id",c)}function o(){window.player=new YT.Player(c,{height:"100%",width:"100%",videoId:a,playerVars:{modestbranding:1,playsinline:1,rel:0,showinfo:0},events:{onReady:p,onStateChange:e}})}o();function p(r){r.target.playVideo()}var t=!1;function e(r){if(r.data==YT.PlayerState.PLAYING&&!t){var s=document.getElementById(c);s.classList.add("player-ready"),t=!0}}},k=i=>(Array.from(i.querySelectorAll("dialog[open]")).forEach((a,c)=>{a.closest(".dialog__wrapper")||(a.removeAttribute("open"),a.showModal(),a.focus(),v(a))}),i.addEventListener("click",a=>{if(a.target.tagName=="IAM-ACTIONBAR")return!1;if(a&&a.target instanceof HTMLElement&&a.target.closest("[data-modal]")){const o=a.target.closest("[data-modal]"),p=o.hasAttribute("data-modal")?o.getAttribute("data-modal"):o.getAttribute("data-filter"),t=document.querySelector(`dialog#${p}`);v(t),t.showModal(),t.focus();let e=t.offsetWidth;t.setAttribute("style",`max-width: ${e}px;`),Array.from(t.querySelectorAll("[data-duplicate]")).forEach((r,s)=>{const m=r.getAttribute("data-duplicate"),b=document.getElementById(m);if(r.checked!=b.checked){r.checked=b.checked;let u=new Event("change");r.dispatchEvent(u)}}),window.dataLayer=window.dataLayer||[],window.dataLayer.push({event:"openModal",id:p})}if(a&&a.target instanceof HTMLElement&&a.target.closest("button.dialog__close")){const o=a.target.closest("dialog[open]");a.preventDefault(),o.close(),Array.from(document.querySelectorAll(".dialog__wrapper > button")).forEach((t,e)=>{t.classList.remove("active")});let p=new CustomEvent("dialog-closed",{bubbles:!0,cancelable:!0,detail:{modalId:o.id}});a.target.dispatchEvent(p),window.dataLayer=window.dataLayer||[],window.dataLayer.push({event:"closeModal",id:o.getAttribute("id")})}if(a&&a.target instanceof HTMLElement&&a.target.closest('button[formmethod="dialog"]')){const o=a.target.closest("dialog[open]");Array.from(document.querySelectorAll(".dialog__wrapper > button")).forEach((p,t)=>{p.classList.remove("active")}),window.dataLayer=window.dataLayer||[],window.dataLayer.push({event:"closeModal",id:o.getAttribute("id")})}if(a&&a.target instanceof HTMLElement&&a.target.closest("dialog[open]")){let o=a.target.closest("dialog[open]");var c=window.getComputedStyle(o);if(c.display==="contents"&&(o=o.parentNode.closest("dialog[open]")),!o.classList.contains("dialog--transactional")&&!o.classList.contains("dialog--acknowledgement")){const p=o.getBoundingClientRect();(a.clientX<p.left||a.clientX>p.right||a.clientY<p.top||a.clientY>p.bottom)&&(a.target.closest("dialog *")||o.close(),window.dataLayer=window.dataLayer||[],window.dataLayer.push({event:"closeModal",id:o.getAttribute("id")}))}}if(a&&a.target instanceof HTMLElement&&a.target.closest(".dialog__wrapper > button")){a.stopPropagation();let o=a.target.closest(".dialog__wrapper > button"),p=o.parentNode,t="openPopover",e=p.querySelector(":scope > dialog");if(document.querySelector("*:not([data-keep-open]) > dialog[open]")&&document.querySelector("*:not([data-keep-open]) > dialog[open]")!=e&&o.closest("dialog[open]")!=document.querySelector("*:not([data-keep-open]) > dialog[open]")&&document.querySelector("*:not([data-keep-open]) > dialog[open]").close(),Array.from(document.querySelectorAll(".dialog__wrapper > button")).forEach((b,u)=>{b.removeAttribute("aria-expanded")}),e.hasAttribute("open"))e.close(),t="closePopover",e.removeAttribute("style"),o.removeAttribute("aria-expanded");else{e.show(),o.setAttribute("aria-expanded",!0);var l=o.getBoundingClientRect();let b=l.top,u=l.left;if(o.closest("iam-table")){let n=o.closest("iam-table").parentNode.getBoundingClientRect();b-=n.top,u-=n.left}e.classList.contains("dialog--fix")&&e.setAttribute("style",`position:fixed;top: ${b}px; left: ${u}px; margin: 3rem 0 0 0;`)}let r=e.getBoundingClientRect(),s=r.bottom-window.scrollY,m=window.innerHeight-window.scrollY;if(s>m){let b=e.hasAttribute("style")?e.getAttribute("style")+" ":"";e.setAttribute("style",b+"transform: translate(0, calc(-100% - 4rem))"),r=e.getBoundingClientRect(),r.top-window.scrollY<100&&e.removeAttribute("style")}window.dataLayer=window.dataLayer||[],window.dataLayer.push({event:t,id:o.textContent})}a&&a.target instanceof HTMLElement&&!a.target.closest("dialog[open]")&&!a.target.closest(".dialog__wrapper > button")&&(document.querySelector(".dialog__wrapper:not([data-keep-open]) > dialog[open]")&&document.querySelector(".dialog__wrapper:not([data-keep-open]) > dialog[open]").close(),Array.from(document.querySelectorAll(".dialog__wrapper:not([data-keep-open]) > button")).forEach((o,p)=>{o.removeAttribute("aria-expanded")}))}),null),v=i=>{let a=i.querySelector(".youtube-embed a");if(a&&_(a),i.classList.contains("dialog--multi")&&!i.querySelector(":scope > .steps")&&L(i),!i.querySelector(":scope .mh-lg")&&!i.classList.contains("dialog--multi")){i.innerHTML=`<div class="mh-lg">${i.innerHTML}</div>`;let c=i.querySelector(".mh-lg"),l=i.querySelector(".mh-lg :is(.h1,.h2,.h3,.h4,.h5,.h6)");if(l){let o=l.previousSibling;c.before(l),o&&l.before(o)}}i.querySelector(":scope > button:first-child")||i.insertAdjacentHTML("afterbegin",'<button class="dialog__close">Close</button>')},L=i=>{let a="",c=Array.from(i.querySelectorAll("fieldset[data-title]")),l=i.querySelector("form");c.forEach((t,e)=>{a+=`<button data-title="${t.getAttribute("data-title")}" type="button" class="${e==0?"active":""}" tabindex="-1">${t.getAttribute("data-title")}</button>`;const r=document.createElement("div");if(r.classList.add("btn--wrapper"),t.appendChild(r),e!=0&&(r.innerHTML+=`<button data-title="${c[e-1].getAttribute("data-title")}" class="btn btn-secondary mb-0" data-previous type="button">Previous</button>`),e!=c.length-1&&(r.innerHTML+=`<button data-title="${c[e+1].getAttribute("data-title")}" class="btn btn-primary mb-0" data-next type="button">Next</button>`),e==c.length-1)if(l&&l.querySelector(':scope > button[type="submit"]')){let s=l.querySelector(':scope > button[type="submit"]');s.classList.add("mb-0"),r.insertAdjacentElement("beforeend",s)}else r.innerHTML+=`<button data-title="${c[e].getAttribute("data-title")}" class="btn btn-primary mb-0" data-next type="submit">Submit</button>`}),i.insertAdjacentHTML("afterbegin",`<div class="steps bg-primary">${a}</div>`);let o=Array.from(i.querySelectorAll("fieldset.was-validated"));for(let t=0;t<o.length;t++){let e=o[t],r=e.getAttribute("data-title");if(e.querySelector(".is-invalid")){Array.from(i.querySelectorAll(`[data-title="${r}"]`)).forEach((s,m)=>{s.classList.add("active")});break}else Array.from(i.querySelectorAll(`[data-title="${r}"]`)).forEach((s,m)=>{s.classList.add("valid")})}i.addEventListener("invalid",function(){return function(t){t.preventDefault()}}(),!0);function p(t){const e=i.querySelector("fieldset.active")?i.querySelector("fieldset.active"):i.querySelector("fieldset[data-title]"),r=e.getAttribute("data-title");let s=!0;if(e.classList.add("was-validated"),Array.from(e.querySelectorAll("input")).forEach((u,n)=>{u.checkValidity()||(s=!1)}),s?Array.from(i.querySelectorAll(`[data-title="${r}"]`)).forEach((u,n)=>{u.classList.add("valid")}):Array.from(i.querySelectorAll(`[data-title="${r}"]`)).forEach((u,n)=>{u.classList.remove("valid")}),s||!t.hasAttribute("data-next")){const u=i.querySelector(`fieldset[data-title="${t.getAttribute("data-title")}"]`),n=i.querySelector(`.steps button[data-title="${t.getAttribute("data-title")}"]`);Array.from(i.querySelectorAll("button")).forEach((g,y)=>{g.classList.remove("active")}),Array.from(i.querySelectorAll("fieldset")).forEach((g,y)=>{g.classList.remove("active")}),n.classList.add("active"),u.classList.add("active")}let m=Array.from(i.querySelectorAll("fieldset")).length,b=Array.from(i.querySelectorAll("fieldset.valid")).length;i.style.setProperty("--progress",`${b/(m-1)*100}%`)}i.addEventListener("keydown",t=>{if(t&&t.target instanceof HTMLElement&&t.target.closest("button")){const e=t.target.closest("button");t.keyCode==13&&e.getAttribute("type")!="submit"&&(t.preventDefault(),p(e))}t&&t.target instanceof HTMLElement&&t.target.closest("input")&&(t.target.closest("input").classList.remove("is-invalid"),t.keyCode==13&&t.preventDefault())}),i.addEventListener("click",t=>{if(t&&t.target instanceof HTMLElement&&t.target.closest('button[type="submit"]'))t.target.closest("form").classList.add("was-validated");else if(t&&t.target instanceof HTMLElement&&t.target.closest("button[data-title]")){const e=t.target.closest("button[data-title]");p(e)}return null})};window.dataLayer=window.dataLayer||[],window.dataLayer.push({event:"customElementRegistered",element:"action bar"});function A(i,a){i&&a=="all"?(i.querySelector("input").indeterminate=!1,i.querySelector("input").checked=!0,i.querySelector("label").textContent="Select all"):i&&a==0?(i.querySelector("input").indeterminate=!1,i.querySelector("input").checked=!1,i.querySelector("label").textContent="Select all"):i&&a?(i.querySelector("input").indeterminate=!0,i.querySelector("input").checked=!1,i.querySelector("label").textContent=`${a} item${a>1?"s":""} selected`):i&&(i.querySelector("input").checked=!1,i.querySelector("input").indeterminate=!1,i.querySelector("label").textContent="Select all")}class S extends HTMLElement{constructor(){super(),this.attachShadow({mode:"open"});const a=document.body.hasAttribute("data-assets-location")?document.body.getAttribute("data-assets-location"):"/assets",c=document.body.hasAttribute("data-core-css")?document.body.getAttribute("data-core-css"):`${a}/css/core.min.css`,l=document.createElement("template");l.innerHTML=`
|
|
5
5
|
<style>
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* iamKey
|
|
2
|
+
* iamKey v6.0.0
|
|
3
3
|
* Copyright 2022-2024 iamproperty
|
|
4
4
|
*/import x from"js-cookie";var g=function(S,h,a,o){function l(c){return c instanceof a?c:new a(function(u){u(c)})}return new(a||(a=Promise))(function(c,u){function b(d){try{m(o.next(d))}catch(f){u(f)}}function v(d){try{m(o.throw(d))}catch(f){u(f)}}function m(d){d.done?c(d.value):l(d.value).then(b,v)}m((o=o.apply(S,h||[])).next())})};window.dataLayer=window.dataLayer||[],window.dataLayer.push({event:"customElementRegistered",element:"Address Lookup"});class j extends HTMLElement{constructor(){super(),this.attachShadow({mode:"open"});const h=document.body.hasAttribute("data-assets-location")?document.body.getAttribute("data-assets-location"):"/assets",a=document.body.hasAttribute("data-core-css")?document.body.getAttribute("data-core-css"):`${h}/css/core.min.css`,o=document.createElement("template");o.innerHTML=`
|
|
5
5
|
<style>
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* iamKey
|
|
2
|
+
* iamKey v6.0.0
|
|
3
3
|
* Copyright 2022-2024 iamproperty
|
|
4
4
|
*/function A(r,i){function d(e,t,s=!0){let f=!1,l=t.getAttribute("name");if(!l)return!1;l.includes("[]")&&(l=l.replace("[]",`[${t.value}]`));let a=e.querySelector(`[data-name="${l}"]`);a&&t.getAttribute("type")=="checkbox"&&(f=!t.checked);let h=t.getAttribute("data-filter-text");if(a||(a=document.createElement("button"),e.appendChild(a)),a.setAttribute("type","button"),a.classList.add("filter"),a.classList.add("tag"),s&&a.classList.add("tag--not-set"),a.setAttribute("data-name",l),a.innerHTML=h.replace("$value",t.value),(!t.value||f)&&a.remove(),t.parentNode.closest("[data-filter-text]")){let m=t.parentNode.closest("[data-filter-text]"),o=!0;if(l="",m.querySelectorAll("input").forEach((u,c)=>{let p=u.getAttribute("name");if(l+=`${c!=0?",":""}${p}`,e.querySelector(`[data-name="${p}"]`)&&e.querySelector(`[data-name="${p}"]`).remove(),u.value){let n=document.createElement("button");n.setAttribute("type","button"),n.classList.add("filter"),n.classList.add("tag"),s&&a.classList.add("tag--not-set"),n.setAttribute("data-name",p),n.innerHTML=h.replace("$value",u.value),e.appendChild(n)}else o=!1}),e.querySelector(`[data-name="${l}"]`)&&e.querySelector(`[data-name="${l}"]`).remove(),o){let u=m.getAttribute("data-filter-text");m.querySelectorAll("input").forEach((p,n)=>{let y=p.getAttribute("name");e.querySelector(`[data-name="${y}"]`)&&e.querySelector(`[data-name="${y}"]`).remove(),u=u.replace(`$${n+1}`,p.value)});let c=document.createElement("button");c.setAttribute("type","button"),c.classList.add("filter"),c.classList.add("tag"),s&&a.classList.add("tag--not-set"),c.setAttribute("data-name",l),c.innerHTML=u,e.appendChild(c)}}}Array.from(r.querySelectorAll('input[type="checkbox"]:checked, input:not([type="checkbox"]):not([type="radio"])')).forEach((e,t)=>{d(i,e,!1)});let b=r.closest("dialog");b&&new MutationObserver(function(t){t[0].attributeName=="open"&&Array.from(r.querySelectorAll('input[type="checkbox"]:checked, input:not([type="checkbox"]):not([type="radio"])')).forEach((s,f)=>{d(i,s,!1)})}).observe(b,{attributes:!0}),r.addEventListener("tags-set",function(e){i.innerHTML="",Array.from(r.querySelectorAll('input[type="checkbox"]:checked, input:not([type="checkbox"]):not([type="radio"])')).forEach((t,s)=>{d(i,t,!1)})}),Array.from(r.querySelectorAll('input[type="checkbox"]:checked, input:not([type="checkbox"]):not([type="radio"])')).forEach((e,t)=>{e.addEventListener("change",function(s){r.hasAttribute("data-keep-same")||d(i,e),s.stopPropagation()})}),r.addEventListener("change",function(e){if(e&&e.target instanceof HTMLElement&&e.target.closest("input[data-filter-text]")){let t=e.target.closest("input[data-filter-text]");r.hasAttribute("data-keep-same")||d(i,t)}}),i.addEventListener("click",function(e){if(e&&e.target instanceof HTMLElement&&e.target.closest(".filter")){let f=e.target.closest(".filter"),l=f.getAttribute("data-name").split(",");for(var t=0;t<l.length;t++){let a=l[t],h=`[name="${a}"]`;a.match(/\[(.*)\]/)&&(a.replace(/\[(.*)\]/,"[]"),h=`[value="${a.replace(/.*\[(.*)\]/,"$1")}"]`);let m=r.querySelectorAll(h);for(var s=0;s<m.length;s++){let o=m[s];if(o.getAttribute("type")!="radio"&&o.getAttribute("type")!="checkbox"){o.value="";var e=new Event("force");r.hasAttribute("data-nosubmit")||o.closest("form").dispatchEvent(e)}else{o.checked=!1;var e=new Event("force");r.hasAttribute("data-nosubmit")||o.closest("form").dispatchEvent(e)}}}f.remove()}},!1)}window.dataLayer=window.dataLayer||[],window.dataLayer.push({event:"customElementRegistered",element:"Applied Filters"});class g extends HTMLElement{constructor(){super(),this.attachShadow({mode:"open"});const i=document.body.hasAttribute("data-assets-location")?document.body.getAttribute("data-assets-location"):"/assets",d=document.body.hasAttribute("data-core-css")?document.body.getAttribute("data-core-css"):`${i}/css/core.min.css`;let b=this.classList.toString();const e=document.createElement("template");e.innerHTML=`
|
|
5
5
|
<style>
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// @ts-nocheck
|
|
2
2
|
import { addClasses, setupChart, setEventListener, setEventObservers, setLongestLabel, setLongestValue, createTooltips } from "../../modules/chart.module.js";
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
import { trackComponent, trackComponentRegistered } from "../_global.js";
|
|
4
|
+
trackComponentRegistered("iam-barchart");
|
|
5
5
|
class iamBarChart extends HTMLElement {
|
|
6
6
|
constructor() {
|
|
7
7
|
super();
|
|
@@ -32,16 +32,14 @@ class iamBarChart extends HTMLElement {
|
|
|
32
32
|
const clonedTable = orginalTable.cloneNode(true);
|
|
33
33
|
const chart = this.shadowRoot.querySelector('.chart');
|
|
34
34
|
const chartOuter = this.shadowRoot.querySelector('.chart__outer');
|
|
35
|
+
const barCount = chart.querySelectorAll('td:not(:first-child)').length;
|
|
35
36
|
chart.appendChild(clonedTable);
|
|
36
37
|
addClasses(chartComponent, chartOuter);
|
|
37
|
-
|
|
38
|
-
if (barCount < 10) {
|
|
38
|
+
if (barCount <= 10) {
|
|
39
39
|
chartComponent.classList.add('chart--fit-content');
|
|
40
|
-
//chartComponent.classList.add('chart--display-data');
|
|
41
40
|
}
|
|
42
|
-
if (barCount
|
|
41
|
+
if (barCount <= 5) {
|
|
43
42
|
chartComponent.classList.add('chart--no-scale');
|
|
44
|
-
//chartComponent.classList.add('chart--display-data');
|
|
45
43
|
}
|
|
46
44
|
setupChart(chartComponent, chartOuter, clonedTable);
|
|
47
45
|
setEventObservers(chartComponent, chartOuter);
|
|
@@ -49,6 +47,7 @@ class iamBarChart extends HTMLElement {
|
|
|
49
47
|
setLongestLabel(chartOuter);
|
|
50
48
|
setLongestValue(chartOuter);
|
|
51
49
|
createTooltips(chartOuter);
|
|
50
|
+
trackComponent(chartComponent, "iam-barchart", ['view-change']);
|
|
52
51
|
}
|
|
53
52
|
attributeChangedCallback(attrName, oldVal, newVal) {
|
|
54
53
|
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* iamKey
|
|
2
|
+
* iamKey v6.0.0
|
|
3
3
|
* Copyright 2022-2024 iamproperty
|
|
4
|
-
*/const
|
|
4
|
+
*/const x=(e,t)=>{for(let a=1;a<=10;a++){if(e.hasAttribute(`data-colour-${a}`)){let i=e.getAttribute(`data-colour-${a}`);e.style.setProperty(`--chart-colour-${a}`,`var(--chart-colour-${i})`),e.style.setProperty(`--chart-colour-${a}-hover`,`var(--chart-colour-${i}-hover)`)}Array.from(t.querySelectorAll(`[data-colour-${a}]`)).forEach(i=>{let r=i.getAttribute(`data-colour-${a}`);i.style.setProperty(`--chart-colour-${a}-set`,`var(--chart-colour-${r})`),i.style.setProperty(`--chart-colour-${a}-hover`,`var(--chart-colour-${r}-hover)`)})}return!0},u=(e,t,a)=>{const i=t.querySelector(".chart__key");i.innerHTML="";const r=t.querySelector(".chart__guidelines");r.innerHTML="";const o=t.querySelector(".chart__yaxis");o.innerHTML="",Array.from(t.querySelectorAll(':scope > input[type="checkbox"],:scope > input[type="radio"]')).map(n=>{n.remove()});let{xaxis:c}=d(e);return _(e,a),S(t,a,i),q(e,r),M(e,o),c&&F(t),!0},k=function(e,t){let a=t.querySelector(".chart");a.addEventListener("mousemove",c=>{if(c&&c.target instanceof HTMLElement&&c.target.closest("td:not(:first-child")){var n=c.target.closest("td:not(:first-child").getBoundingClientRect();let s=c.clientX-n.left,l=c.clientY-n.top;a.setAttribute("style",`--cursor-x: ${s}px; --cursor-y: ${l}px;`)}});let i=t.querySelectorAll("label");Array.from(i).forEach(c=>{t.querySelector(`input#${c.getAttribute("for")}`).checked?c.setAttribute("part","key-checked"):c.setAttribute("part","key-unchecked")});let r=e.querySelector("table"),o=t.querySelector("table");t.addEventListener("change",function(c){let n=c.target;const h=new CustomEvent("view-change",{detail:{"data-dataset":n.getAttribute("data-dataset"),label:n.getAttribute("data-label"),checked:n.checked}});e.dispatchEvent(h),Array.from(i).forEach(s=>{var l;!((l=t.querySelector(`input#${s.getAttribute("for")}`))===null||l===void 0)&&l.checked?s.setAttribute("part","key-checked"):s.setAttribute("part","key-unchecked")}),o.innerHTML=r.innerHTML,_(e,o)})},A=function(e,t){let a=e.querySelector("table"),i=t.querySelector("table");const r=(h,s)=>{s.disconnect(),n.disconnect();for(const l of h)(l.attributeName=="class"||l.type==="attributes"||l.type==="attributes")&&(i.innerHTML=a.innerHTML,u(e,t,i));s.observe(a,{characterData:!0,subtree:!0}),n.observe(e,{attributes:!0})},o=(h,s)=>{s.disconnect(),n.disconnect();for(const l of h)(l.type=="characterData"||l.type=="childList"&&l.addedNodes.length)&&(i.innerHTML=a.innerHTML,u(e,t,i));s.observe(a,{characterData:!0,subtree:!0}),n.observe(e,{attributes:!0})};let c=new MutationObserver(o),n=new MutationObserver(r);return c.observe(a,{characterData:!0,subtree:!0}),n.observe(e,{attributes:!0}),!0},d=function(e){let t=e.shadowRoot.querySelector(".chart__wrapper table"),a=e.hasAttribute("data-min")?e.getAttribute("data-min"):0,i=e.hasAttribute("data-max")?e.getAttribute("data-max"):z(e,t),r=e.hasAttribute("data-yaxis")?e.getAttribute("data-yaxis").split(","):[],o=e.hasAttribute("data-guidelines")?e.getAttribute("data-guidelines").split(","):[],c=e.hasAttribute("data-xaxis")?e.getAttribute("data-xaxis").split(","):null;return{min:a,max:i,yaxis:r,xaxis:c,guidelines:o}};function z(e,t){const a=e.classList.contains("chart--stacked")?"tbody tr":"tbody td:not(:first-child)";let i=Array.from(t.querySelectorAll(a)).map(o=>o.getAttribute("data-numeric")),r=Math.max(...i);return Math.ceil(r)}const b=function(e,t,a,i){let r=String(e);r=r.replace("\xA3",""),r=r.replace("%",""),r=r.replace(",",""),r=Number.parseFloat(r);let o=(r-t)/(a-t)*100,c=o,n=0;return i&&i!=0&&(n=(i-t)/(a-t)*100),t<0&&(n=Math.abs(t/(a-t)*100),r<0?(o=n-o,n=n-o,c=n):(o=o-n,c=o+n)),{percent:o,axis:c,bottom:n}},_=function(e,t){Array.from(t.querySelectorAll("tbody tr")).forEach(r=>{let o=0;Array.from(r.querySelectorAll("td:not(:first-child)")).forEach(c=>{let n=parseFloat(c.textContent.replace("\xA3","").replace("%","").replace(",",""));c.setAttribute("data-numeric",n),c.setAttribute("data-value",c.textContent),getComputedStyle(c).display!="none"&&(o+=n)}),r.setAttribute("data-numeric",o)});let{min:a,max:i}=d(e);Array.from(t.querySelectorAll("tbody tr")).forEach((r,o)=>{let c=r.querySelector("td:first-child, th:first-child")?r.querySelector("td:first-child, th:first-child").textContent:"";r.setAttribute("part","group");let n=(r.getAttribute("data-numeric")-a)/(i-a)*100;r.style.setProperty("--percent",`${n}%`),Array.from(r.querySelectorAll("td:not([data-label])")).forEach((l,p)=>{p==0?l.setAttribute("part","xaxis-label"):l.setAttribute("part","value"),r.querySelectorAll("td").length>2&&l.setAttribute("data-label",t.querySelectorAll("thead th")[p].textContent)});let h=r.hasAttribute("data-min")?r.getAttribute("data-min"):a,s=r.hasAttribute("data-max")?r.getAttribute("data-max"):i;if(h<0){let l=Math.abs(h/(s-h)*100);e.setAttribute("style",`--min-bottom: ${l}%;`)}r.style.setProperty("--row-index",o+1),Array.from(r.querySelectorAll('td[data-numeric]:not([data-label="Min"]):not([data-label="Max"]):not(:first-child)')).forEach(l=>{if(getComputedStyle(l).display=="none")return;const f=l.innerHTML,v=Number.parseFloat(l.getAttribute("data-numeric")),m=Number.parseFloat(l.getAttribute("data-start"));if(l.querySelector("span[data-group]")||(l.innerHTML=`<span data-group="${c}" ${l.hasAttribute("data-label")?`data-label="${l.getAttribute("data-label")}"`:""} part="popover">${f}</span>`),!l.hasAttribute("style")){let{percent:y,bottom:g,axis:w}=b(v,h,s,m);l.setAttribute("data-percent",y),l.setAttribute("style",`--bottom:${g}%;--percent:${y}%;--axis:${w}%;`)}})})},C=function(e){let t=e.querySelector(".chart__wrapper"),a=e.querySelector(".chart__spacer span"),i=e.querySelector(".chart table"),r="";Array.from(i.querySelectorAll("tbody tr td:first-child")).forEach(o=>{typeof o.textContent<"u"&&o.textContent.length>r.length&&(r=o.textContent)}),t.setAttribute("data-longest-label",r),a.innerHTML=r},$=function(e){let t=e.querySelector(".chart__wrapper"),a=e.querySelector(".chart table"),i="";Array.from(a.querySelectorAll("tbody tr td:not(:first-child) span")).forEach(r=>{typeof r.textContent<"u"&&r.textContent.length>i.length&&(i=r.textContent)}),t.setAttribute("data-longest-value",i)},S=function(e,t,a){const i=`chart-${Date.now()+(Math.floor(Math.random()*100)+1)}`;let r,o=Array.from(t.querySelectorAll("thead th"));return o.forEach((c,n)=>{n!=0&&(r=L(i,n,c.textContent,a,e,r)),n==50&&(o.length=n+1)}),!0};function L(e,t,a,i,r,o){let c=document.createElement("input");c.setAttribute("name",`${e}-dataset-${t}`),c.setAttribute("id",`${e}-dataset-${t}`),c.setAttribute("data-dataset",`${t}`),c.setAttribute("data-label",`${a}`),c.checked=!0,c.setAttribute("type","checkbox"),t==1?r.prepend(c):r.insertBefore(c,o.nextSibling),o=c;let n=document.createElement("label");return n.setAttribute("class","key btn btn-action"),n.setAttribute("for",`${e}-dataset-${t}`),n.setAttribute("data-label",`${a}`),n.setAttribute("part","key"),n.innerHTML=`${a}`,i.append(n),o}const q=function(e,t){let{min:a,max:i,yaxis:r,guidelines:o}=d(e);o.length||(o=r),t.innerHTML="";for(var c=0;c<o.length;c++){let n=parseFloat(o[c].replace("\xA3","").replace("%","").replace(",","")),{axis:h}=b(n,a,i);t.innerHTML+=`<div class="guideline" style="--percent:${h}%;">${r.indexOf(o[c])!=-1?`<span>${o[c]}</span>`:""}</div>`}},M=function(e,t){let{min:a,max:i,yaxis:r}=d(e);t.innerHTML="";for(var o=0;o<r.length;o++){let c=parseFloat(r[o].replace("\xA3","").replace("%","")),{axis:n}=b(c,a,i);t.innerHTML+=`<div class="axis__point" style="--percent:${n}%;"><span>${r[o]}</span></div>`}},F=function(e){const t=e.querySelector(".chart");let a=e.querySelector(".chart__xaxis");a||(a=document.createElement("div"),a.setAttribute("class","chart__xaxis")),t.prepend(a)},T=function(e){const t=e.querySelectorAll("thead th[title], tbody th[title]:first-child, tbody td[title]:first-child");Array.from(t).forEach(a=>{let i=`tooltip-${Date.now()}-${Math.floor(Math.random()*100)}`;a.innerHTML=`<button class="tooltip" popovertarget="${i}" part="tooltip" style="anchor-name: --${i};">${a.textContent}</button><span id="${i}" style="position-anchor: --${i};" popover part="tooltip__content" class="tooltip__content">${a.getAttribute("title")}</span>`})},D=e=>{window.dataLayer=window.dataLayer||[],window.dataLayer.push({event:"customElementRegistered",element:e})},H=(e,t,a)=>(window.dataLayer=window.dataLayer||[],window.dataLayer.push({event:"customElementAdded",element:t}),a.forEach(i=>{e.addEventListener(i,function(r){let o={event:i,element:t,target:r.target};Object.keys(r.detail).forEach(c=>{const n=r.detail[c];o[c]=n}),window.dataLayer.push(o)})}),!0);D("iam-barchart");class E extends HTMLElement{constructor(){super(),this.attachShadow({mode:"open"}),document.body.hasAttribute("data-assets-location")&&document.body.getAttribute("data-assets-location");const t=document.createElement("template");t.innerHTML=`
|
|
5
5
|
<style>
|
|
6
|
-
:host{--chart-colour-1-set: var(--chart-colour-1,#BEE8F8);--chart-colour-2-set: var(--chart-colour-2,#A6DCC7);--chart-colour-3-set: var(--chart-colour-3,#FAD0DA);--chart-colour-4-set: var(--chart-colour-4,#AFCCF2);--chart-colour-5-set: var(--chart-colour-5,#FFD2B4);--chart-colour-6-set: var(--chart-colour-6,#CDF0F2);--chart-colour-7-set: var(--chart-colour-7,#FFABC2);--chart-colour-8-set: var(--chart-colour-8,#DCEAF2);--chart-colour-9-set: var(--chart-colour-9,#EEBCB3);--chart-colour-10-set: var(--chart-colour-10,#F0BDFF);--chart-colour-1-hover: var(--chart-colour-1,#B6DEED);--chart-colour-2-hover: var(--chart-colour-2,#98CBB7);--chart-colour-3-hover: var(--chart-colour-3,#EFC8D1);--chart-colour-4-hover: var(--chart-colour-4,#A6C1E5);--chart-colour-5-hover: var(--chart-colour-5,#F4CAAF);--chart-colour-6-hover: var(--chart-colour-6,#C2E3E5);--chart-colour-7-hover: var(--chart-colour-7,#F5A2B9);--chart-colour-8-hover: var(--chart-colour-8,#CFDCE3);--chart-colour-9-hover: var(--chart-colour-9,#E3B2A9);--chart-colour-10-hover: var(--chart-colour-10,#E3B2F2);--chart-colour-success: #D2F0C9!important;--chart-colour-success-hover: #8AD873!important;--chart-colour-danger: #F5C2C7!important;--chart-colour-danger-hover: #f5c2e7!important;--chart-colour-warning: #FFD280!important;--chart-colour-warning-hover: #FFB020!important}.chart__key .key:nth-child(10n-9),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-8){--chart-colour: var(--chart-colour-1-set);--chart-colour-hover: var(--chart-colour-1-hover)}.chart__key .key:nth-child(10n-8),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-7){--chart-colour: var(--chart-colour-2-set);--chart-colour-hover: var(--chart-colour-2-hover)}.chart__key .key:nth-child(10n-7),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-6){--chart-colour: var(--chart-colour-3-set);--chart-colour-hover: var(--chart-colour-3-hover)}.chart__key .key:nth-child(10n-6),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-5){--chart-colour: var(--chart-colour-4-set);--chart-colour-hover: var(--chart-colour-4-hover)}.chart__key .key:nth-child(10n-5),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-4){--chart-colour: var(--chart-colour-5-set);--chart-colour-hover: var(--chart-colour-5-hover)}.chart__key .key:nth-child(10n-4),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-3){--chart-colour: var(--chart-colour-6-set);--chart-colour-hover: var(--chart-colour-6-hover)}.chart__key .key:nth-child(10n-3),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-2){--chart-colour: var(--chart-colour-7-set);--chart-colour-hover: var(--chart-colour-7-hover)}.chart__key .key:nth-child(10n-2),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-1){--chart-colour: var(--chart-colour-8-set);--chart-colour-hover: var(--chart-colour-8-hover)}.chart__key .key:nth-child(10n-1),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-0){--chart-colour: var(--chart-colour-9-set);--chart-colour-hover: var(--chart-colour-9-hover)}::slotted(table){display:none !important}:host{container-type:inline-size;margin-bottom:2rem;display:block}.chart__outer{display:flex;flex-direction:column;font-weight:var(--chart-font-weight, bold);color:var(--chart-text-color, black);--body-colour-set: var(--body-colour, Canvas);--text-colour-set: var(--text-colour, black);--chart-height-set: var(--chart-height, 7.5rem);--chart-height-lg-set: var(--chart-height-lg, 12.5rem);--chart-height-resp: var(--chart-height-set);--index-below: -1;--index-base: 0;--index-focus: 2;--index-above: 10;--index-floating: 100;--index-menu: 200;--index-overlay: 1000;--key-label-width: 100%;--label-size: 0.75rem;--pie-size: calc(50% - 1.4rem);--line-thickness: 1px;--yaxis-width: auto;--yaxis-point-display: block;--yaxis-last-point-transform: translate(0,-50%);--bar-gap: min(10%, 0.75rem)}.chart__outer>*{display:block;order:2}.chart__outer tbody{--chart-direction: 360deg;--chart-day-bg-pos: 100% calc(var(--single-day) * 7) }@container (min-width: 23.4375em){.chart__outer :has(tr:nth-child(5) td:nth-child(4)),.chart__outer :has(tr:nth-child(10)){--yaxis-width: 0;--yaxis-point-display: none;--yaxis-last-point-transform: translate(0,-100%);--bar-gap: 0}.chart__outer .chart__wrapper{--chart-height-resp: var(--chart-height-lg-set);--pie-size: calc(33.333% - 1.4rem);--line-thickness: 0.8px;--yaxis-width: auto;--yaxis-point-display: block;--yaxis-last-point-transform: translate(0,-50%)}}@container (min-width: 48em){.chart__outer :has(tr:nth-child(10)){--bar-gap: 0}.chart__outer .chart__wrapper{--label-size: 0.875rem;--pie-size: calc(25% - 1.5rem);--line-thickness: 0.5px}}.chart__outer .chart__spacer span{opacity:0}.chart__outer>input[type=checkbox]{opacity:0;position:absolute;pointer-events:none;bottom:50%;left:50%}.chart__key{padding:0 0 0 0;margin-bottom:1.5rem;display:flex;overflow:auto;scroll-snap-type:x mandatory;scroll-padding:.75rem;gap:.5rem}.chart__key:has(label:first-child:last-child){display:var(--single-key-display, none)}.chart__key .key{margin:0}.chart__key .key:before{content:"";height:.8em;width:.8em;margin-right:.3em;background-color:var(--chart-colour);display:inline-block;border-radius:var(--key-border-radius, 4px)}.chart__key .key[data-label=Min],.chart__key .key[data-label=Max]{display:none}.chart__key .key .chart__total{display:none}.chart__outer>input[type=checkbox]:nth-of-type(1):not(:checked)~.chart__key .key:nth-of-type(1){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(2):not(:checked)~.chart__key .key:nth-of-type(2){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(3):not(:checked)~.chart__key .key:nth-of-type(3){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(4):not(:checked)~.chart__key .key:nth-of-type(4){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(5):not(:checked)~.chart__key .key:nth-of-type(5){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(6):not(:checked)~.chart__key .key:nth-of-type(6){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(7):not(:checked)~.chart__key .key:nth-of-type(7){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(8):not(:checked)~.chart__key .key:nth-of-type(8){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(9):not(:checked)~.chart__key .key:nth-of-type(9){opacity:.25}:host([data-yaxis]){--yaxis-display: flex}.chart__yaxis{display:var(--yaxis-display, none);flex-direction:column-reverse;width:var(--yaxis-width)}.chart__yaxis .axis__point{bottom:var(--percent);position:relative;height:0;white-space:nowrap}.chart__yaxis .axis__point:not(:last-child){display:var(--yaxis-point-display)}.chart__yaxis .axis__point span{display:block;transform:translate(0, -50%);padding-right:.25rem;text-align:right;font-weight:var(--chart-yaxis-fw, normal);font-size:var(--chart-yaxis-fs, 0.75rem);color:var(--colour-body)}.chart__yaxis .axis__point:last-child span{transform:var(--yaxis-last-point-transform)}.chart__xaxis{margin-bottom:1rem;display:flex;flex-direction:column-reverse;width:100%;position:absolute;left:0;bottom:-1rem}.chart__xaxis .axis__point{left:var(--percent);width:1px;position:absolute;height:0;white-space:nowrap}.chart__xaxis .axis__point span{display:block;transform:translate(-50%, 0%);text-align:center;font-size:var(--label-size);position:absolute;left:50%}.chart__guidelines{position:absolute;top:0;left:0;width:100%;height:100%;display:flex;flex-direction:column-reverse;pointer-events:none}.chart__guidelines .guideline{bottom:var(--percent);position:absolute;right:0;width:100%;height:0px;margin-bottom:-1px;border-bottom:1px dashed #eee;pointer-events:none;z-index:var(--index-below)}.chart__guidelines .guideline:not(.guideline--target) span{display:none}.chart__guidelines .guideline--target{border-bottom:1px dashed #000;z-index:var(--index-above);text-shadow:1px solid #fff;overflow:visible}.chart__guidelines .guideline--target span{position:absolute;bottom:0;font-size:var(--label-size);text-shadow:1px 1px 2px #fff;background:rgba(255,255,255,.6)}.chart__guidelines [data-value="0"]{border-bottom:1px solid var(--colour-primary)}.chart__guidelines [data-value="0"]:not(:first-child){border-bottom:1px dashed var(--colour-primary)}.chart__wrapper{display:block;display:flex;flex-direction:row;position:relative}.chart__wrapper .chart{position:relative;flex-grow:1}.chart__wrapper table{display:block;width:100% !important;padding-top:var(--chart-height-resp);position:relative;margin-bottom:0;overflow:visible}.chart__wrapper table thead{display:none}.chart__wrapper table tbody{display:flex;position:absolute;width:100%;height:100%;top:0;left:0;flex-direction:row;border:none}.chart__wrapper table tbody tr{display:flex;flex-direction:row;justify-content:var(--chart-bar-alignment, center);align-items:flex-end;border:none;width:100%;height:100%;position:relative;padding:0 2px;gap:var(--bar-gap)}.chart__wrapper table tbody tr td{font-weight:inherit}.chart__wrapper table tbody tr td:first-child{position:absolute;top:100%;left:0%;width:fit-content;padding:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:var(--label-size);text-align:center}@container (min-width: 48em){.chart__wrapper table tbody tr td:first-child{display:block}}.chart__wrapper table tbody tr td:first-child button{all:unset;cursor:pointer}.chart__wrapper table tbody tr td[data-label=Min],.chart__wrapper table tbody tr td[data-label=Max]{display:none}.chart__wrapper table tbody tr:first-child td:first-child,.chart__wrapper table tbody tr:last-child td:first-child{display:block}.chart__wrapper table tbody tr td:not(:first-child){height:100%;height:var(--percent, 0%);bottom:var(--bottom, 0%);width:100%;max-width:7.5rem;position:relative;padding:0;background:var(--chart-colour);border-top-right-radius:4px;border-top-left-radius:4px}@media screen and (prefers-color-scheme: dark){.chart__wrapper table tbody tr td:not(:first-child){background:color-mix(in oklab, var(--chart-colour), black 20%)}}.chart__wrapper table tbody tr td:not(:first-child):hover{background:var(--chart-colour-hover)}.chart__wrapper table tbody tr td:not(:first-child):has(span:empty),.chart__wrapper table tbody tr td:not(:first-child):empty{display:none}.chart__wrapper table tbody tr td:not(:first-child)[data-label]:before{display:none}.chart__wrapper table tbody tr td:not(:first-child) span{position:absolute;top:var(--cursor-y, 50%);left:var(--cursor-x, 50%);font-size:var(--label-size);line-height:1.2;transform:translate(-50%, 0);background:var(--chart-details-bg, var(--colour-canvas-2, Canvas));opacity:0;pointer-events:none;padding:.5rem;border-radius:.5rem;margin-bottom:.25rem;white-space:pre;text-align:left;box-shadow:var(--chart-details-shadow, 0 0.125rem 0.75rem rgba(0, 0, 0, 0.25));transform:translate(-50%, -100%)}.chart__wrapper table tbody tr td:not(:first-child) span::before{content:attr(data-group) "\\a"}.chart__wrapper table tbody tr td:not(:first-child) span[data-label]::before{content:attr(data-group) "\\a" attr(data-label) "\\a"}.chart__wrapper table tbody tr td:not(:first-child):hover span{opacity:1;z-index:var(--index-above)}.chart__wrapper table tbody tr td:first-child[data-label]:before{display:none}@container (min-width: 48em){.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr td:first-child,.chart__wrapper table tbody:has(tr:nth-child(10)) tr td:first-child{display:none}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:first-child td:first-child,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:first-child td:first-child{left:0%;transform:translate(0, 0);display:block;text-align:left}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:last-child td:first-child,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:last-child td:first-child{left:100%;transform:translate(-100%, 0);display:block;text-align:right}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:first-child td:not(:first-child) span,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:first-child td:not(:first-child) span{left:-20%;transform:translate(0%, 0);text-align:left}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:last-child td:not(:first-child) span,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:last-child td:not(:first-child) span{left:120%;transform:translate(-100%, 0);text-align:right}}@container (min-width: 23.4375em){.chart__wrapper table tbody:has(tr:nth-child(25)) tr td:first-child{display:none !important}.chart__wrapper table tbody:has(tr:nth-child(25)) tr:is(:first-child,:nth-child(2n+1)) td:first-child{display:block !important}.chart__wrapper table tbody:has(tr:nth-child(50)) tr:is(:first-child,:nth-child(2n+1)) td:first-child,.chart__wrapper table tbody:has(tr:nth-child(50)) tr td:first-child{display:none !important}.chart__wrapper table tbody:has(tr:nth-child(50)) tr:is(:first-child,:nth-child(10n+1)) td:first-child{display:block !important}.chart__wrapper table tbody:has(tr:nth-child(100)) tr:is(:first-child,:nth-child(10n+1)) td:first-child,.chart__wrapper table tbody:has(tr:nth-child(100)) tr td:first-child{display:none !important}.chart__wrapper table tbody:has(tr:nth-child(100)) tr:is(:first-child,:nth-child(20n+1)) td:first-child{display:block !important}}:host(.chart-colour--success) td,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--success,.chart-colour--success td{--chart-colour: var(--chart-colour-success)!important}:host(.chart-colour--success) td:hover,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--success:hover,.chart-colour--success td:hover{--chart-colour-hover: var(--chart-colour-success-hover)!important}:host(.chart-colour--danger) td,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--danger,.chart-colour--danger,.chart-colour--danger td{--chart-colour: var(--chart-colour-danger)!important}:host(.chart-colour--danger) td:hover,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--danger:hover,.chart-colour--danger:hover,.chart-colour--danger td:hover{--chart-colour-hover: var(--chart-colour-danger-hover)!important}:host(.chart-colour--warning) td,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--warning,.chart-colour--warning,.chart-colour--warning td{--chart-colour: var(--chart-colour-warning)!important}:host(.chart-colour--warning) td:hover,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--warning:hover,.chart-colour--warning:hover,.chart-colour--warning td:hover{--chart-colour-hover: var(--chart-colour-warning-hover)!important}.chart__outer>input[type=checkbox]:nth-of-type(1):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(2){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(2):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(3){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(3):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(4){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(4):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(5){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(5):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(6){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(6):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(7){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(7):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(8){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(8):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(9){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(9):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(10){display:none;opacity:0}:host(.chart--horizontal) .chart__outer tbody{--chart-direction: 90deg;--chart-day-bg-pos: calc(var(--single-day) * 7) 100%;--bar-gap: 0}:host(.chart--horizontal) .chart__outer .chart__guidelines{position:absolute}:host(.chart--horizontal) .chart__outer .chart__guidelines .guideline{bottom:auto;left:var(--percent);height:100%;border-left:1px dashed #eee;width:0}:host(.chart--horizontal) .chart__outer .chart__guidelines .guideline span{display:block;font-size:var(--label-size);position:absolute;top:100%;transform:translate(-50%, 0.2em);opacity:1}:host(.chart--horizontal) .chart__outer .chart__yaxis{display:none}:host(.chart--horizontal) .chart__outer table{padding-top:0}:host(.chart--horizontal) .chart__outer table tbody{flex-direction:column;position:relative}:host(.chart--horizontal) .chart__outer table tbody tr{flex-direction:column;align-items:flex-start;margin-bottom:.5rem;padding:0}:host(.chart--horizontal) .chart__outer table tbody tr td{height:var(--bar-height, 1.5rem);bottom:0;left:var(--bottom, 0%);width:var(--comparison, var(--percent));max-width:100%;border-top-left-radius:0;border-bottom-right-radius:4px}:host(.chart--horizontal) .chart__outer table tbody tr td:first-child{position:static;transform:none;display:block !important;height:var(--bar-height, 1.5rem);line-height:var(--bar-height, 1.5rem);max-width:var(--xaxis-max-width, none)}:host(.chart--horizontal) .chart__outer table tbody tr td:first-child>*:not([popover]){max-width:100%;text-overflow:ellipsis;overflow:hidden}:host(.chart--horizontal) .chart__outer .chart__wrapper[data-longest-label]:before{display:block;content:attr(data-longest-label);font-size:var(--label-size);padding-right:.5em;opacity:0;pointer-events:none;white-space:nowrap;width:var(--xaxis-max-width, none)}:host(.chart--horizontal) .chart__outer:has(td .tooltip) .chart__wrapper[data-longest-label]:before{padding-right:2em;width:calc(var(--xaxis-max-width, none) - 1rem)}:host(.chart--horizontal) .chart__outer .chart__wrapper[data-longest-label] table tbody tr td:first-child{position:absolute;display:block !important;max-height:1.5rem;z-index:var(--index-above);top:0%;left:auto !important;right:100% !important;padding-right:.5em;width:fit-content}:host(.chart--horizontal) .chart__outer .chart__spacer span{display:none !important}:host(.chart--stacked) .chart__wrapper table tbody tr{--bar-gap: 0;flex-direction:column-reverse;justify-content:flex-start;align-items:center}:host(.chart--stacked) .chart__wrapper table tbody tr td{border-radius:0 !important}:host(.chart--stacked.chart--horizontal) .chart__wrapper table tbody tr{flex-direction:row}:host(.chart--stacked.chart--horizontal) .chart__wrapper table tbody tr::after{content:attr(data-numeric);position:absolute;opacity:1 !important;bottom:100%;left:50%;transform:translate(-50%, 0);display:block !important;height:fit-content;margin:0;bottom:50%;left:calc(var(--percent) + .5rem);transform:translate(0, 50%)}:host(.chart--stacked.chart--horizontal) .chart__wrapper table tbody tr td:after{content:none}.chart--animate.animating.inview{--animation-left: 2s}.chart--animate.animating.inview table tbody tr td:not(:first-child){transition:height 2s ease-out,width 2s ease-out,bottom 2s ease-out,left var(--animation-left) ease-out;transition-delay:calc(var(--row-index)*.1s)}.chart--animate:not(.inview) table tbody tr td:not(:first-child){--bottom: var(--min-bottom, 0%)!important;--percent: 0%!important;--axis: 0%!important;--comparison: 0%!important}.chart--animate.animating table tbody tr td:not(:first-child){overflow:hidden}:host(.chart--display-data) table tbody tr td:not(:first-child):after{content:attr(data-value);position:absolute;opacity:1 !important;bottom:100%;left:50%;transform:translate(-50%, 0);display:block !important;height:fit-content;margin:0}:host(.chart--display-data.chart--horizontal) table tbody tr td:not(:first-child):after{bottom:50%;left:calc(100% + .5rem);transform:translate(0, 50%)}:host(.chart--display-data.chart--horizontal) .chart__wrapper[data-longest-value]:after{display:block;content:attr(data-longest-value);font-size:var(--label-size);padding-left:.5em;opacity:0;pointer-events:none;white-space:nowrap}:host(.chart--display-data.chart--fit-content:not(.chart--horizontal)) .chart__outer{padding-top:1rem}:host(.chart--fit-content:not(.chart--horizontal)){width:100%;display:block}:host(.chart--fit-content:not(.chart--horizontal)) .chart__wrapper{width:fit-content}:host(.chart--fit-content:not(.chart--horizontal)) table{width:fit-content !important;padding-top:0;height:var(--chart-height-resp, 7.5rem)}:host(.chart--fit-content:not(.chart--horizontal)) tbody{position:relative}:host(.chart--fit-content:not(.chart--horizontal)) [part=group]{min-width:fit-content;width:fit-content;max-width:fit-content;padding-right:var(--fc-group-width, 1rem)}:host(.chart--fit-content:not(.chart--horizontal)) [part=value]{min-width:var(--fc-value-width, 0.75rem);width:var(--fc-value-width, 0.75rem);max-width:var(--fc-value-width, 0.75rem)}:host(.chart--fit-content:not(.chart--horizontal).chart--no-scale){--fc-group-width: 1.375rem;--fc-value-width: 1.5rem}:host(.chart--fit-content:not(.chart--horizontal).chart--no-scale) table{height:var(--chart-height-lg-set, 7.5rem)}@container (min-width: 23.4375em){.chart__wrapper{--fc-group-width: 1.375rem;--fc-value-width: 1.5rem}}button.tooltip:after{content:"?";margin-left:.25rem;display:inline-block;border:1px solid currentColor}.tooltip__content[popover]{z-index:var(--index-floating);background:var(--colour-primary);color:var(--colour-white);padding:1.5rem;border-radius:.5rem;box-shadow:0px 2px 9px rgba(0,0,0,.11);white-space:normal;position:fixed;border:none;margin:0;box-sizing:border-box;inset-area:bottom center;overflow:visible;width:calc(anchor-size(width) + var(--container-padding-x) + var(--container-padding-x) + 1.5rem) !important}.tooltip__content[popover]::after{content:"";position:absolute;bottom:100%;left:50%;margin-left:-0.25rem;border-width:.5rem;border-style:solid;border-color:rgba(0,0,0,0) rgba(0,0,0,0) var(--colour-primary) rgba(0,0,0,0);margin-bottom:-1px}/*# sourceMappingURL=assets/css/components/barchart.component.css.map */
|
|
6
|
+
:host{--chart-colour-1-set: var(--chart-colour-1,#BEE8F8);--chart-colour-2-set: var(--chart-colour-2,#A6DCC7);--chart-colour-3-set: var(--chart-colour-3,#FAD0DA);--chart-colour-4-set: var(--chart-colour-4,#AFCCF2);--chart-colour-5-set: var(--chart-colour-5,#FFD2B4);--chart-colour-6-set: var(--chart-colour-6,#CDF0F2);--chart-colour-7-set: var(--chart-colour-7,#FFABC2);--chart-colour-8-set: var(--chart-colour-8,#DCEAF2);--chart-colour-9-set: var(--chart-colour-9,#EEBCB3);--chart-colour-10-set: var(--chart-colour-10,#F0BDFF);--chart-colour-1-hover: var(--chart-colour-1,#B6DEED);--chart-colour-2-hover: var(--chart-colour-2,#98CBB7);--chart-colour-3-hover: var(--chart-colour-3,#EFC8D1);--chart-colour-4-hover: var(--chart-colour-4,#A6C1E5);--chart-colour-5-hover: var(--chart-colour-5,#F4CAAF);--chart-colour-6-hover: var(--chart-colour-6,#C2E3E5);--chart-colour-7-hover: var(--chart-colour-7,#F5A2B9);--chart-colour-8-hover: var(--chart-colour-8,#CFDCE3);--chart-colour-9-hover: var(--chart-colour-9,#E3B2A9);--chart-colour-10-hover: var(--chart-colour-10,#E3B2F2);--chart-colour-success: #D2F0C9!important;--chart-colour-success-hover: #8AD873!important;--chart-colour-danger: #F5C2C7!important;--chart-colour-danger-hover: #f5c2e7!important;--chart-colour-warning: #FFD280!important;--chart-colour-warning-hover: #FFB020!important}.chart__key .key:nth-child(10n-9),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-8){--chart-colour: var(--chart-colour-1-set);--chart-colour-hover: var(--chart-colour-1-hover)}.chart__key .key:nth-child(10n-8),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-7){--chart-colour: var(--chart-colour-2-set);--chart-colour-hover: var(--chart-colour-2-hover)}.chart__key .key:nth-child(10n-7),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-6){--chart-colour: var(--chart-colour-3-set);--chart-colour-hover: var(--chart-colour-3-hover)}.chart__key .key:nth-child(10n-6),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-5){--chart-colour: var(--chart-colour-4-set);--chart-colour-hover: var(--chart-colour-4-hover)}.chart__key .key:nth-child(10n-5),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-4){--chart-colour: var(--chart-colour-5-set);--chart-colour-hover: var(--chart-colour-5-hover)}.chart__key .key:nth-child(10n-4),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-3){--chart-colour: var(--chart-colour-6-set);--chart-colour-hover: var(--chart-colour-6-hover)}.chart__key .key:nth-child(10n-3),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-2){--chart-colour: var(--chart-colour-7-set);--chart-colour-hover: var(--chart-colour-7-hover)}.chart__key .key:nth-child(10n-2),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-1){--chart-colour: var(--chart-colour-8-set);--chart-colour-hover: var(--chart-colour-8-hover)}.chart__key .key:nth-child(10n-1),.chart__outer table tbody tr td:not(:first-child):nth-child(10n-0){--chart-colour: var(--chart-colour-9-set);--chart-colour-hover: var(--chart-colour-9-hover)}::slotted(table){display:none !important}:host{container-type:inline-size;margin-bottom:2rem;display:block}.chart__outer{display:flex;flex-direction:column;position:relative;font-weight:var(--chart-font-weight, bold);color:var(--chart-text-color, black);--body-colour-set: var(--body-colour, Canvas);--text-colour-set: var(--text-colour, black);--chart-height-set: var(--chart-height, 7.5rem);--chart-height-lg-set: var(--chart-height-lg, 12.5rem);--chart-height-resp: var(--chart-height-set);--index-below: -1;--index-base: 0;--index-focus: 2;--index-above: 10;--index-floating: 100;--index-menu: 200;--index-overlay: 1000;--key-label-width: 100%;--label-size: 0.75rem;--pie-size: calc(50% - 1.4rem);--line-thickness: 1px;--yaxis-width: auto;--yaxis-point-display: block;--yaxis-last-point-transform: translate(0,-50%);--bar-gap: min(10%, 0.75rem)}.chart__outer>*{display:block;order:2}.chart__outer tbody{--chart-direction: 360deg;--chart-day-bg-pos: 100% calc(var(--single-day) * 7) }@container (min-width: 23.4375em){.chart__outer :has(tr:nth-child(5) td:nth-child(4)),.chart__outer :has(tr:nth-child(10)){--yaxis-width: 0;--yaxis-point-display: none;--yaxis-last-point-transform: translate(0,-100%);--bar-gap: 0}.chart__outer .chart__wrapper{--chart-height-resp: var(--chart-height-lg-set);--pie-size: calc(33.333% - 1.4rem);--line-thickness: 0.8px;--yaxis-width: auto;--yaxis-point-display: block;--yaxis-last-point-transform: translate(0,-50%)}}@container (min-width: 48em){.chart__outer :has(tr:nth-child(10)){--bar-gap: 0}.chart__outer .chart__wrapper{--label-size: 0.875rem;--pie-size: calc(25% - 1.5rem);--line-thickness: 0.5px}}.chart__outer .chart__spacer span{opacity:0}.chart__outer>input[type=checkbox]{opacity:0;position:absolute;pointer-events:none;bottom:50%;left:50%}.chart__key{padding:0 0 0 0;margin-bottom:1.5rem;display:flex;overflow:auto;scroll-snap-type:x mandatory;scroll-padding:.75rem;gap:.5rem}.chart__key:has(label:first-child:last-child){display:var(--single-key-display, none)}.chart__key .key{margin:0}.chart__key .key:before{content:"";height:.8em;width:.8em;margin-right:.3em;background-color:var(--chart-colour);display:inline-block;border-radius:var(--key-border-radius, 4px)}.chart__key .key[data-label=Min],.chart__key .key[data-label=Max]{display:none}.chart__key .key .chart__total{display:none}.chart__outer input[type=checkbox]:focus:nth-child(1)~.chart__key .key:nth-child(1){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(2)~.chart__key .key:nth-child(2){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(3)~.chart__key .key:nth-child(3){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(4)~.chart__key .key:nth-child(4){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(5)~.chart__key .key:nth-child(5){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(6)~.chart__key .key:nth-child(6){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(7)~.chart__key .key:nth-child(7){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(8)~.chart__key .key:nth-child(8){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer input[type=checkbox]:focus:nth-child(9)~.chart__key .key:nth-child(9){background:var(--colour-btn-action-hover-bg) !important;border:var(--btn-border-width) solid var(--colour-muted) !important}.chart__outer>input[type=checkbox]:nth-of-type(1):not(:checked)~.chart__key .key:nth-of-type(1){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(2):not(:checked)~.chart__key .key:nth-of-type(2){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(3):not(:checked)~.chart__key .key:nth-of-type(3){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(4):not(:checked)~.chart__key .key:nth-of-type(4){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(5):not(:checked)~.chart__key .key:nth-of-type(5){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(6):not(:checked)~.chart__key .key:nth-of-type(6){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(7):not(:checked)~.chart__key .key:nth-of-type(7){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(8):not(:checked)~.chart__key .key:nth-of-type(8){opacity:.25}.chart__outer>input[type=checkbox]:nth-of-type(9):not(:checked)~.chart__key .key:nth-of-type(9){opacity:.25}:host([data-yaxis]){--yaxis-display: flex}.chart__yaxis{display:var(--yaxis-display, none);flex-direction:column-reverse;width:var(--yaxis-width)}.chart__yaxis .axis__point{bottom:var(--percent);position:relative;height:0;white-space:nowrap}.chart__yaxis .axis__point:not(:last-child){display:var(--yaxis-point-display)}.chart__yaxis .axis__point span{display:block;transform:translate(0, -50%);padding-right:.25rem;text-align:right;font-weight:var(--chart-yaxis-fw, normal);font-size:var(--chart-yaxis-fs, 0.75rem);color:var(--colour-body)}.chart__yaxis .axis__point:last-child span{transform:var(--yaxis-last-point-transform)}.chart__xaxis{margin-bottom:1rem;display:flex;flex-direction:column-reverse;width:100%;position:absolute;left:0;bottom:-1rem}.chart__xaxis .axis__point{left:var(--percent);width:1px;position:absolute;height:0;white-space:nowrap}.chart__xaxis .axis__point span{display:block;transform:translate(-50%, 0%);text-align:center;font-size:var(--label-size);position:absolute;left:50%}.chart__guidelines{position:absolute;top:0;left:0;width:100%;height:100%;display:flex;flex-direction:column-reverse;pointer-events:none}.chart__guidelines .guideline{bottom:var(--percent);position:absolute;right:0;width:100%;height:0px;margin-bottom:-1px;border-bottom:1px dashed #eee;pointer-events:none;z-index:var(--index-below)}.chart__guidelines .guideline:not(.guideline--target) span{display:none}.chart__guidelines .guideline--target{border-bottom:1px dashed #000;z-index:var(--index-above);text-shadow:1px solid #fff;overflow:visible}.chart__guidelines .guideline--target span{position:absolute;bottom:0;font-size:var(--label-size);text-shadow:1px 1px 2px #fff;background:rgba(255,255,255,.6)}.chart__guidelines [data-value="0"]{border-bottom:1px solid var(--colour-primary)}.chart__guidelines [data-value="0"]:not(:first-child){border-bottom:1px dashed var(--colour-primary)}.chart__wrapper{display:block;display:flex;flex-direction:row;position:relative}.chart__wrapper .chart{position:relative;flex-grow:1}.chart__wrapper table{display:block;width:100% !important;padding-top:var(--chart-height-resp);position:relative;margin-bottom:0;overflow:visible}.chart__wrapper table thead{display:none}.chart__wrapper table tbody{display:flex;position:absolute;width:100%;height:100%;top:0;left:0;flex-direction:row;border:none}.chart__wrapper table tbody tr{display:flex;flex-direction:row;justify-content:var(--chart-bar-alignment, left);align-items:flex-end;border:none;width:100%;height:100%;position:relative;padding:0 2px;gap:var(--bar-gap)}.chart__wrapper table tbody tr td{font-weight:inherit}.chart__wrapper table tbody tr td:first-child{position:absolute;top:100%;left:0%;width:fit-content;padding:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:var(--label-size);text-align:center}@container (min-width: 48em){.chart__wrapper table tbody tr td:first-child{display:block}}.chart__wrapper table tbody tr td:first-child button{all:unset;cursor:pointer}.chart__wrapper table tbody tr td[data-label=Min],.chart__wrapper table tbody tr td[data-label=Max]{display:none}.chart__wrapper table tbody tr:first-child td:first-child,.chart__wrapper table tbody tr:last-child td:first-child{display:block}.chart__wrapper table tbody tr td:not(:first-child){height:100%;height:var(--percent, 0%);bottom:var(--bottom, 0%);width:100%;max-width:7.5rem;position:relative;padding:0;background:var(--chart-colour);border-top-right-radius:4px;border-top-left-radius:4px}@media screen and (prefers-color-scheme: dark){.chart__wrapper table tbody tr td:not(:first-child){background:color-mix(in oklab, var(--chart-colour), black 20%)}}.chart__wrapper table tbody tr td:not(:first-child):hover{background:var(--chart-colour-hover)}.chart__wrapper table tbody tr td:not(:first-child):has(span:empty),.chart__wrapper table tbody tr td:not(:first-child):empty{display:none}.chart__wrapper table tbody tr td:not(:first-child)[data-label]:before{display:none}.chart__wrapper table tbody tr td:not(:first-child) span{position:absolute;top:var(--cursor-y, 50%);left:var(--cursor-x, 50%);font-size:var(--label-size);line-height:1.2;transform:translate(-50%, 0);background:var(--chart-details-bg, var(--colour-canvas-2, Canvas));opacity:0;pointer-events:none;padding:.5rem;border-radius:.5rem;margin-bottom:.25rem;white-space:pre;text-align:left;box-shadow:var(--chart-details-shadow, 0 0.125rem 0.75rem rgba(0, 0, 0, 0.25));transform:translate(-50%, -100%)}.chart__wrapper table tbody tr td:not(:first-child) span::before{content:attr(data-group) "\\a"}.chart__wrapper table tbody tr td:not(:first-child) span[data-label]::before{content:attr(data-group) "\\a" attr(data-label) "\\a"}.chart__wrapper table tbody tr td:not(:first-child):hover span{opacity:1;z-index:var(--index-above)}.chart__wrapper table tbody tr td:first-child[data-label]:before{display:none}@container (min-width: 48em){.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr td:first-child,.chart__wrapper table tbody:has(tr:nth-child(10)) tr td:first-child{display:none}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:first-child td:first-child,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:first-child td:first-child{left:0%;transform:translate(0, 0);display:block;text-align:left}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:last-child td:first-child,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:last-child td:first-child{left:100%;transform:translate(-100%, 0);display:block;text-align:right}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:first-child td:not(:first-child) span,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:first-child td:not(:first-child) span{left:-20%;transform:translate(0%, 0);text-align:left}.chart__wrapper table tbody:has(tr:nth-child(5) td:nth-child(4)) tr:last-child td:not(:first-child) span,.chart__wrapper table tbody:has(tr:nth-child(10)) tr:last-child td:not(:first-child) span{left:120%;transform:translate(-100%, 0);text-align:right}}@container (min-width: 23.4375em){.chart__wrapper table tbody:has(tr:nth-child(25)) tr td:first-child{display:none !important}.chart__wrapper table tbody:has(tr:nth-child(25)) tr:is(:first-child,:nth-child(2n+1)) td:first-child{display:block !important}.chart__wrapper table tbody:has(tr:nth-child(50)) tr:is(:first-child,:nth-child(2n+1)) td:first-child,.chart__wrapper table tbody:has(tr:nth-child(50)) tr td:first-child{display:none !important}.chart__wrapper table tbody:has(tr:nth-child(50)) tr:is(:first-child,:nth-child(10n+1)) td:first-child{display:block !important}.chart__wrapper table tbody:has(tr:nth-child(100)) tr:is(:first-child,:nth-child(10n+1)) td:first-child,.chart__wrapper table tbody:has(tr:nth-child(100)) tr td:first-child{display:none !important}.chart__wrapper table tbody:has(tr:nth-child(100)) tr:is(:first-child,:nth-child(20n+1)) td:first-child{display:block !important}}:host(.chart-colour--success) td,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--success,.chart-colour--success td{--chart-colour: var(--chart-colour-success)!important}:host(.chart-colour--success) td:hover,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--success:hover,.chart-colour--success td:hover{--chart-colour-hover: var(--chart-colour-success-hover)!important}:host(.chart-colour--danger) td,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--danger,.chart-colour--danger,.chart-colour--danger td{--chart-colour: var(--chart-colour-danger)!important}:host(.chart-colour--danger) td:hover,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--danger:hover,.chart-colour--danger:hover,.chart-colour--danger td:hover{--chart-colour-hover: var(--chart-colour-danger-hover)!important}:host(.chart-colour--warning) td,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--warning,.chart-colour--warning,.chart-colour--warning td{--chart-colour: var(--chart-colour-warning)!important}:host(.chart-colour--warning) td:hover,:host(:is(.chart-colour--success,.chart-colour--danger,.chart-colour--wraning)) td.chart-colour--warning:hover,.chart-colour--warning:hover,.chart-colour--warning td:hover{--chart-colour-hover: var(--chart-colour-warning-hover)!important}.chart__outer>input[type=checkbox]:nth-of-type(1):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(2){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(2):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(3){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(3):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(4){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(4):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(5){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(5):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(6){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(6):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(7){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(7):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(8){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(8):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(9){display:none;opacity:0}.chart__outer>input[type=checkbox]:nth-of-type(9):not(:checked)~.chart__wrapper table tbody tr td:not(:first-child):nth-child(10){display:none;opacity:0}:host(.chart--horizontal) .chart__outer tbody{--chart-direction: 90deg;--chart-day-bg-pos: calc(var(--single-day) * 7) 100%;--bar-gap: 0}:host(.chart--horizontal) .chart__outer .chart__guidelines{position:absolute}:host(.chart--horizontal) .chart__outer .chart__guidelines .guideline{bottom:auto;left:var(--percent);height:100%;border-left:1px dashed #eee;width:0}:host(.chart--horizontal) .chart__outer .chart__guidelines .guideline span{display:block;font-size:var(--label-size);position:absolute;top:100%;transform:translate(-50%, 0.2em);opacity:1}:host(.chart--horizontal) .chart__outer .chart__yaxis{display:none}:host(.chart--horizontal) .chart__outer table{padding-top:0}:host(.chart--horizontal) .chart__outer table tbody{flex-direction:column;position:relative}:host(.chart--horizontal) .chart__outer table tbody tr{flex-direction:column;align-items:flex-start;margin-bottom:.5rem;padding:0}:host(.chart--horizontal) .chart__outer table tbody tr td{height:var(--bar-height, 1.5rem);bottom:0;left:var(--bottom, 0%);width:var(--comparison, var(--percent));max-width:100%;border-top-left-radius:0;border-bottom-right-radius:4px}:host(.chart--horizontal) .chart__outer table tbody tr td:first-child{position:static;transform:none;display:block !important;height:var(--bar-height, 1.5rem);line-height:var(--bar-height, 1.5rem);max-width:var(--xaxis-max-width, none)}:host(.chart--horizontal) .chart__outer table tbody tr td:first-child>*:not([popover]){max-width:100%;text-overflow:ellipsis;overflow:hidden}:host(.chart--horizontal) .chart__outer .chart__wrapper[data-longest-label]:before{display:block;content:attr(data-longest-label);font-size:var(--label-size);padding-right:.5em;opacity:0;pointer-events:none;white-space:nowrap;width:var(--xaxis-max-width, none)}:host(.chart--horizontal) .chart__outer:has(td .tooltip) .chart__wrapper[data-longest-label]:before{padding-right:2em;width:calc(var(--xaxis-max-width, none) - 1rem)}:host(.chart--horizontal) .chart__outer .chart__wrapper[data-longest-label] table tbody tr td:first-child{position:absolute;display:block !important;max-height:1.5rem;z-index:var(--index-above);top:0%;left:auto !important;right:100% !important;padding-right:.5em;width:fit-content}:host(.chart--horizontal) .chart__outer .chart__spacer span{display:none !important}:host(.chart--stacked) .chart__wrapper table tbody tr{--bar-gap: 0;flex-direction:column-reverse;justify-content:flex-start;align-items:center}:host(.chart--stacked) .chart__wrapper table tbody tr td{border-radius:0 !important}:host(.chart--stacked.chart--horizontal) .chart__wrapper table tbody tr{flex-direction:row}:host(.chart--stacked.chart--horizontal) .chart__wrapper table tbody tr::after{content:attr(data-numeric);position:absolute;opacity:1 !important;bottom:100%;left:50%;transform:translate(-50%, 0);display:block !important;height:fit-content;margin:0;bottom:50%;left:calc(var(--percent) + .5rem);transform:translate(0, 50%)}:host(.chart--stacked.chart--horizontal) .chart__wrapper table tbody tr td:after{content:none}.chart--animate.animating.inview{--animation-left: 2s}.chart--animate.animating.inview table tbody tr td:not(:first-child){transition:height 2s ease-out,width 2s ease-out,bottom 2s ease-out,left var(--animation-left) ease-out;transition-delay:calc(var(--row-index)*.1s)}.chart--animate:not(.inview) table tbody tr td:not(:first-child){--bottom: var(--min-bottom, 0%)!important;--percent: 0%!important;--axis: 0%!important;--comparison: 0%!important}.chart--animate.animating table tbody tr td:not(:first-child){overflow:hidden}:host(.chart--display-data) table tbody tr td:not(:first-child):after{content:attr(data-value);position:absolute;opacity:1 !important;bottom:100%;left:50%;transform:translate(-50%, 0);display:block !important;height:fit-content;margin:0}:host(.chart--display-data.chart--horizontal) table tbody tr td:not(:first-child):after{bottom:50%;left:calc(100% + .5rem);transform:translate(0, 50%)}:host(.chart--display-data.chart--horizontal) .chart__wrapper[data-longest-value]:after{display:block;content:attr(data-longest-value);font-size:var(--label-size);padding-left:.5em;opacity:0;pointer-events:none;white-space:nowrap}:host(.chart--display-data.chart--fit-content:not(.chart--horizontal)) .chart__outer{padding-top:1rem}:host(.chart--fit-content:not(.chart--horizontal)){width:100%;display:block}:host(.chart--fit-content:not(.chart--horizontal)) .chart__wrapper{width:fit-content}:host(.chart--fit-content:not(.chart--horizontal)) table{width:fit-content !important;padding-top:0;height:var(--chart-height-resp, 7.5rem)}:host(.chart--fit-content:not(.chart--horizontal)) tbody{position:relative}:host(.chart--fit-content:not(.chart--horizontal)) [part=group]{min-width:fit-content;width:fit-content;max-width:fit-content;padding-right:var(--fc-group-width, 1rem)}:host(.chart--fit-content:not(.chart--horizontal)) [part=value]{min-width:var(--fc-value-width, 0.75rem);width:var(--fc-value-width, 0.75rem);max-width:var(--fc-value-width, 0.75rem)}:host(.chart--fit-content:not(.chart--horizontal).chart--no-scale){--fc-group-width: 1.375rem;--fc-value-width: 1.5rem}:host(.chart--fit-content:not(.chart--horizontal).chart--no-scale) table{height:var(--chart-height-lg-set, 7.5rem)}@container (min-width: 23.4375em){.chart__wrapper{--fc-group-width: 1.375rem;--fc-value-width: 1.5rem}}button.tooltip:after{content:"?";margin-left:.25rem;display:inline-block;border:1px solid currentColor}.tooltip__content[popover]{z-index:var(--index-floating);background:var(--colour-primary);color:var(--colour-white);padding:1.5rem;border-radius:.5rem;box-shadow:0px 2px 9px rgba(0,0,0,.11);white-space:normal;position:fixed;border:none;margin:0;box-sizing:border-box;inset-area:bottom center;overflow:visible;width:calc(anchor-size(width) + var(--container-padding-x) + var(--container-padding-x) + 1.5rem) !important}.tooltip__content[popover]::after{content:"";position:absolute;bottom:100%;left:50%;margin-left:-0.25rem;border-width:.5rem;border-style:solid;border-color:rgba(0,0,0,0) rgba(0,0,0,0) var(--colour-primary) rgba(0,0,0,0);margin-bottom:-1px}/*# sourceMappingURL=assets/css/components/barchart.component.css.map */
|
|
7
7
|
|
|
8
8
|
</style>
|
|
9
9
|
<div class="chart__outer" part="outer">
|
|
@@ -15,5 +15,5 @@
|
|
|
15
15
|
</div>
|
|
16
16
|
</div>
|
|
17
17
|
<div class="chart__spacer"><span part="spacer"></span</div>
|
|
18
|
-
</div>`,this.shadowRoot.appendChild(
|
|
18
|
+
</div>`,this.shadowRoot.appendChild(t.content.cloneNode(!0))}connectedCallback(){const t=this,i=this.querySelector("table").cloneNode(!0),r=this.shadowRoot.querySelector(".chart"),o=this.shadowRoot.querySelector(".chart__outer"),c=r.querySelectorAll("td:not(:first-child)").length;r.appendChild(i),x(t,o),c<=10&&t.classList.add("chart--fit-content"),c<=5&&t.classList.add("chart--no-scale"),u(t,o,i),A(t,o),k(t,o),C(o),$(o),T(o),H(t,"iam-barchart",["view-change"])}attributeChangedCallback(t,a,i){}}export{E as default};
|
|
19
19
|
//# sourceMappingURL=barchart.component.min.js.map
|