@nebula.js/sn-bar-chart
Version:
Bar chart supernova
7 lines (6 loc) • 622 kB
JavaScript
/*
* @nebula.js/sn-bar-chart v1.37.2
* Copyright (c) 2025 QlikTech International AB
* Released under the MIT license.
*/
import e from"picasso.js";import t from"picasso-plugin-q";import n from"picasso-plugin-hammer";import r from"hammerjs";import i from"react";import{ListItemText as o,ListItemIcon as a,ListItem as s,Divider as l,Popover as u,List as c,styled as d,Button as m}from"@material-ui/core";import{makeStyles as f,createStyles as p,createGenerateClassName as h,StylesProvider as g,ThemeProvider as y}from"@material-ui/styles";import v from"react-dom";import{styled as b,Button as x,ListItemButton as q,ListItemIcon as S,Divider as M,createTheme as D,SvgIcon as C,ThemeProvider as w}from"@mui/material";import{useTranslator as L,useEmbed as E,useTheme as N,useState as O,useDeviceType as T,useAppLayout as k,useEffect as A,useElement as I,useOptions as P,useLayout as R,useAction as F,useStaleLayout as z,useModel as H,useApp as j,usePlugins as B,useSelections as V,useConstraints as _,useRect as U,usePromise as $,onTakeSnapshot as W,useImperativeHandle as K,useRenderState as G}from"@nebula.js/stardust";function Y(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var X=Object.prototype.hasOwnProperty,J=Object.prototype.toString,Z=Object.defineProperty,Q=Object.getOwnPropertyDescriptor,ee=function(e){return"function"==typeof Array.isArray?Array.isArray(e):"[object Array]"===J.call(e)},te=function(e){if(!e||"[object Object]"!==J.call(e))return!1;var t,n=X.call(e,"constructor"),r=e.constructor&&e.constructor.prototype&&X.call(e.constructor.prototype,"isPrototypeOf");if(e.constructor&&!n&&!r)return!1;for(t in e);return void 0===t||X.call(e,t)},ne=function(e,t){Z&&"__proto__"===t.name?Z(e,t.name,{enumerable:!0,configurable:!0,value:t.newValue,writable:!0}):e[t.name]=t.newValue},re=function(e,t){if("__proto__"===t){if(!X.call(e,t))return;if(Q)return Q(e,t).value}return e[t]},ie=function e(){var t,n,r,i,o,a,s=arguments[0],l=1,u=arguments.length,c=!1;for("boolean"==typeof s&&(c=s,s=arguments[1]||{},l=2),(null==s||"object"!=typeof s&&"function"!=typeof s)&&(s={});l<u;++l)if(null!=(t=arguments[l]))for(n in t)r=re(s,n),s!==(i=re(t,n))&&(c&&i&&(te(i)||(o=ee(i)))?(o?(o=!1,a=r&&ee(r)?r:[]):a=r&&te(r)?r:{},ne(s,{name:n,newValue:e(c,a,i)})):void 0!==i&&ne(s,{name:n,newValue:i}));return s},oe=Y(ie);const ae=[["FULL",{width:550,height:450}],["MEDIUM",{width:400,height:220}],["SMALL",{width:300,height:150}],["XSMALL",{width:150,height:75}],["SPARK",{width:0,height:0}]],se={};ae.forEach((([e,{width:t,height:n}])=>{se[e]={width:t,height:n}}));const le={getLayoutModes:()=>se,getLayoutMode(e,t){let n;for(n=0;n<ae.length;++n)if(e>=ae[n][1].width&&t>=ae[n][1].height)return ae[n][0];return"SPARK"}};function ue(e,t){return{layoutModes:le.getLayoutModes(),center:void 0!==t.minCenterRatio?{minWidthRatio:t.minCenterRatio,minHeightRatio:t.minCenterRatio}:void 0,logicalSize:t.logicalSize?{align:.5,preserveAspectRatio:!0,...t.logicalSize}:void 0}}const ce=["$date","$timestamp","$time"],de=["D","TS","T"],me={hasTimeTag:e=>!!(e&&e.qTags&&e.qTags.some((e=>ce.some((t=>t===e))))),hasUnknownFormat:e=>!(!e||!e.qNumFormat||"U"!==e.qNumFormat.qType),hasTimeFormat:e=>!!(e&&e.qNumFormat&&de.some((t=>t===e.qNumFormat.qType))),isTimeDimension:(e,t)=>!!(e&&t&&(me.hasTimeTag(t)&&me.hasUnknownFormat(t)||me.hasTimeFormat(t))),isTime:(e,t)=>!!(t&&t.qHyperCube.qDimensionInfo&&t.qHyperCube.qDimensionInfo.length)&&(e&&me.isTimeDimension(e,t.qHyperCube.qDimensionInfo.filter((e=>{var t;return 7005!==(null===(t=e.qError)||void 0===t?void 0:t.qErrorCode)}))[0])),canBeContinuousDimension(e){if(!e)return!1;const t=e.qTags||[];return!(!e.qContinuousAxes||!t.some((e=>"$numeric"===e)))},canBeContinuous(e){var t,n;const r=null==e||null===(t=e.qHyperCube)||void 0===t||null===(t=t.qDimensionInfo)||void 0===t?void 0:t.filter((e=>{var t;return 7005!==(null===(t=e.qError)||void 0===t?void 0:t.qErrorCode)}));return!((null!==(n=null==r?void 0:r.length)&&void 0!==n?n:0)<1)&&me.canBeContinuousDimension(r[0])},maxNumberOfLines:12},fe=/^[A-Z][A-z0-9_]*$/i,pe={getChar(e){let t=e,n=-1;return t>9?(n=65+t-10,n>90&&(n+=6)):t=`${t}`.charCodeAt(0),[48,111,79,105,73,108].indexOf(n)>-1?this.getChar(t+1):String.fromCharCode(n)},base62(e){const t=this.getChar(e%62),n=Math.floor(e/62);return n>0?this.base62(n)+t:t},id(){return this.base62(Math.round(99e11*Math.random()+1e11)).replace(/\W/g,"")}},he={setValue:(e,t,n)=>{if(!t)return!1;const r=t.split("."),i=r[r.length-1];let o,a=e;for(o=0;o<r.length-1;++o)void 0===a[r[o]]&&(a[r[o]]=Number.isNaN(+r[o+1])?{}:[]),a=a[r[o]];if(void 0!==n){const e=a[i];return a[i]=n,{updated:n,previous:e}}return delete a[i],!1},getValue:(e,t,n)=>{const r=t.split(".");let i,o=e;if(void 0===o)return n;for(i=0;i<r.length;++i){if(void 0===o[r[i]])return n;o=o[r[i]]}return o},moveArrayElement:(e,t,n)=>{if(n>=e.length){let t=n-e.length;for(;1+t--;)e.push(void 0)}e.splice(n,0,e.splice(t,1)[0])},escapeField:e=>{let t;return t=!e||"]"===e||fe.test(e)?e:`[${e.replace(/\]/g,"]]")}]`,t},deleteUndefinedProperties:e=>{Object.keys(e).forEach((t=>{void 0===e[t]&&delete e[t]}))},generateId:()=>pe.id(),shouldUseFormat:e=>!e.isCustomFormatted&&(e.qIsAutoFormat||"U"===e.qNumFormat.qType)},ge=e=>he.getValue(e,"qHyperCube.qDimensionInfo",[]),ye=e=>he.getValue(e,"qHyperCube.qMeasureInfo",[]),ve=e=>he.getValue(e,"barGrouping.grouping"),be={continuous:(e,t=!1)=>!!me.canBeContinuous(e)&&(he.getValue(e,"dimensionAxis.continuousAuto")?"function"==typeof t?t():t:!!e.preferContinuousAxis),dimensionless:e=>!ge(e).length,grouped(e){return!this.dimensionless(e)&&"grouped"===ve(e)&&(ge(e).length>1||ye(e).length>1)&&!this.continuous(e)},groupedByDimension(e){return this.grouped(e)&&ge(e).length>1&&1===ye(e).length},groupedByMeasure(e){return this.grouped(e)&&1===ge(e).length&&ye(e).length>1},stacked(e){return(!this.dimensionless(e)&&"grouped"!==ve(e)&&"butterfly"!==ve(e)||this.continuous(e))&&(ge(e).length>1||ye(e).length>1)},stackedByDimension(e){return this.stacked(e)&&ge(e).length>1&&1===ye(e).length},stackedByMeasure(e){return this.stacked(e)&&1===ge(e).length&&ye(e).length>1},simple:e=>0===ge(e).length||1===ge(e).length&&1===ye(e).length,snapshot:e=>!!he.getValue(e,"snapshotData")};function xe(e,t){const n=e.component(t);return n&&n._DO_NOT_USE_getInfo&&n._DO_NOT_USE_getInfo().offset}const qe=e=>{throw e.isHandled=!0,e};const Se={getDockValue:e=>"near"===e||"left"===e||"top"===e?0:1,getOppositeDock(e){switch(e){case"left":return"right";case"right":return"left";case"top":return"bottom";case"bottom":return"top";case"near":default:return"far";case"far":return"near"}},getHorizontalDock:e=>"near"===e||"left"===e?"left":"right",getVerticalDock:e=>"near"===e||"bottom"===e?"bottom":"top",getDock:(e,t,n)=>"vertical"===e||"y"===e?Se.getVerticalDock(t):n?Se.getOppositeDock(Se.getHorizontalDock(t)):Se.getHorizontalDock(t),getInvertedOrientation:e=>"vertical"===e?"horizontal":"vertical",getMinorScaleAxis:e=>"vertical"===e?"y":"x",getMajorScaleAxis:e=>"vertical"===e?"x":"y",getAlignment:(e,t)=>"vertical"===e?"near"===t||"bottom"===t?1:0:"near"===t||"left"===t?0:1,getMeasureScaleInvert:(e,t)=>"vertical"===e||t,getDimensionScaleInvert:(e,t)=>"horizontal"===e&&t,getSize:(e,{width:t,height:n})=>"vertical"===e?t:n};var Me=(e,t)=>{if("function"==typeof t.defaultValue)return t.defaultValue();if(void 0!==t.defaultValue)return t.defaultValue;if(Array.isArray(t.options))return t.options[0].value;switch(e){case"array":return[];case"string":return"";case"integer":case"number":return 0;case"boolean":return!1;default:return null}};const De=166/26,Ce=12/11,we={stringWidthOverMWidth:e=>(12*Math.min(e,3)+Math.max(e-3,0)*De)/11,getCharacterRatios(e){if(!e)return{latin:0,cjk:0};let t=e.match(/[\u4E00-\u9FFF]/g),n=e.match(/[\u3040-\u309F]/g),r=e.match(/[\u30A0-\u30FF]/g);t=t?t.length:0,n=n?n.length:0,r=r?r.length:0;const i=t+n+r;return{latin:e.length-i,cjk:i}},getTotalCharacterRatios(e,t,n="qText"){if(!e)return{latinRatio:1,cjkRatio:0};const r={latin:0,cjk:0};let i;void 0===t?e.forEach((e=>{i=we.getCharacterRatios(e[n]),r.latin+=i.latin,r.cjk+=i.cjk})):e.forEach((e=>{i=we.getCharacterRatios(e[t][n]),r.latin+=i.latin,r.cjk+=i.cjk}));const o=Math.max(1,r.latin+r.cjk);return r.latinRatio=r.latin/o,r.cjkRatio=r.cjk/o,r},getAdjustedMaxGlyphCount(e,t,n,r="qText"){const i=we.getTotalCharacterRatios(t,n,r),o=i.latinRatio*e,a=i.cjkRatio*e;return Math.ceil(we.stringWidthOverMWidth(o)+a*Ce)}},Le="#la-vie-tooltip";function Ee(){if(!document.querySelector(Le)){const e=document.createElement("div");e.id="la-vie-tooltip",e.style.overflow="hidden",e.style.position="fixed",e.style.pointerEvents="none",e.style.left="0px",e.style.top="0px",e.style.width="100%",e.style.height="100%",e.style.zIndex=1020,document.body.appendChild(e)}}function Ne({key:e="tooltip",rtl:t}){return{show:!0,key:e,type:"tooltip",layout:{displayOrder:3},beforeMount(){Ee()},beforeUpdate(){Ee()},destroyed(){!function(){const e=document.querySelector(Le);e&&e.parentElement&&e.childElementCount<1&&e.parentElement.removeChild(e)}()},settings:{appendTo:()=>document.querySelector(Le),content:({h:e,data:t,style:n})=>t[0].map((t=>e("tr",{},function(e,{h:t,style:n}){return e.map((e=>{const r={style:{...n.cell||{},...e.style||{}},class:e.class};return e.colspan&&(r.colspan=e.colspan),t("td",r,e.content)}))}(t,{h:e,style:n})))),direction:t?"rtl":"ltr"},style:{arrow:{color:"#404040"},content:{display:"table","border-spacing":"4px",background:"rgba(64, 64, 64, 0.9)",opacity:"1",fontSize:"13px",fontFamily:'"Source Sans Pro", "Arial", "sans-serif"',"empty-cells":"show"},cell:{"max-width":"180px","word-break":"break-word","word-wrap":"break-word","overflow-wrap":"break-word",hyphens:"auto"}}}}const Oe=new RegExp("[A-Za-zªµºÀ-ÖØ-öø-ʸʻ-ˁː-ˑˠ-ˤˮͰ-ͳͶ-ͽΆΈ-ϵϷ-҂Ҋ-։ः-हऻऽ-ीॉ-ौॎ-ॐक़-ॡ।-ॿং-হঽ-ীে-ৌৎ-ৡ০-ৱ৴-৺ਃ-ਹਾ-ੀਖ਼-੯ੲ-ੴઃ-હઽ-ીૉ-ૌૐ-ૡ૦-૯ଂ-ହଽ-ାୀେ-ୌୗ-ୡ୦-୷ஃ-ிு-ௌௐ-௲ఁ-ఽు-ౄౘ-ౡ౦-౯౿-ಹಽ-ೋೕ-ೡ೦-ീെ-ൌൎ-ൡ൦-ෆා-ෑෘ-ะา-ำเ-ๆ๏-ະາ-ຳຽ-ໆ໐-༗༚-༴༶༸༾-ཬཿ྅ྈ-ྌ྾-࿅࿇-ာေးျ-ြဿ-ၗၚ-ၝၡ-ၰၵ-ႁႃ-ႄႇ-ႌႎ-ႜ႞-ፚ፠-ᎏᎠ-Ᏼᐁ-ᙿᚁ-ᚚᚠ-ᜑᜠ-ᜱ᜵-ᝑᝠ-ᝰក-ាើ-ៅះ-ៈ។-៚ៜ០-៩᠐-ᢨᢪ-ᤜᤣ-ᤦᤩ-ᤱᤳ-ᤸ᥆-᧚ᨀ-ᨖᨙ-ᩕᩗᩡᩣ-ᩤᩭ-ᩲ᪀-᪭ᬄ-ᬳᬵᬻᬽ-ᭁᭃ-᭪᭴-᭼ᮂ-ᮡᮦ-ᮧ᮪-ᯥᯧᯪ-ᯬᯮ᯲-ᰫᰴ-ᰵ᰻-᱿᳓᳡ᳩ-ᳬᳮ-ᶿḀ-ᾼιῂ-ῌῐ-Ίῠ-Ῥῲ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕℙ-ℝℤΩℨK-ℭℯ-ℹℼ-ℿⅅ-ⅉⅎ-⅏Ⅰ-ↈ⌶-⍺⎕⒜-ⓩ⚬⠀-⣿Ⰰ-ⳤⳫ-ⳮⴀ-⵰ⶀ-ⷞ々-〇〡-〩〱-〵〸-〼ぁ-ゖゝ-ゟァ-ヺー-ㆺㇰ-㈜㈠-㉏㉠-㉻㉿-㊰㋀-㋋㋐-㍶㍻-㏝㏠-㏾㐀-䶵一-ꒌꓐ-ꘌꘐ-ꙮꚀ-ꛯ꛲-꛷Ꜣ-ꞇ꞉-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠤꠧ꠰-꠷ꡀ-ꡳꢀ-ꣃ꣎-꣙ꣲ-ꤥ꤮-ꥆꥒ-ꥼꦃ-ꦲꦴ-ꦵꦺ-ꦻꦽ-ꨨꨯ-ꨰꨳ-ꨴꩀ-ꩂꩄ-ꩋꩍ-ꪯꪱꪵ-ꪶꪹ-ꪽꫀꫂ-ꯤꯦ-ꯧꯩ-꯬꯰-ﬗA-Za-zヲ-ᅵ]"),Te=new RegExp("[־׀׃׆א-״߀-ߪߴ-ߵߺ-ࠕࠚࠤࠨ࠰-ࡘ࡞יִײַ-ﬨשׁ-ﭏ]"),ke=new RegExp("[؈؋؍؛-ي٭-ٯٱ-ەۥ-ۦۮ-ۯۺ-܍ܐܒ-ܯݍ-ޥޱﭐ-ﴽﵐ-﷼ﹰ-ﻼ]"),Ae={lrm:String.fromCharCode(8206),rlm:String.fromCharCode(8207),isLtrChar:e=>Oe.test(e),isRtlChar:e=>Te.test(e)||ke.test(e),detectTextDirection(e){const t=e?e.length:0;let n,r;for(n=0;n<t;n++){if(r=e[n],Ae.isLtrChar(r))return"ltr";if(Ae.isRtlChar(r))return"rtl"}return"ltr"}},Ie={getColorSymbol:(e,t)=>e.h("div",{style:{display:"inline-block",width:"10px",height:"10px","background-color":t.color.fill,margin:"0 8px"}}),getNodeFillColor:e=>e.attrs&&void 0!==e.attrs.fill?e.attrs.fill:e.children&&e.children[0]&&e.children[0].attrs&&void 0!==e.children[0].attrs.fill?e.children[0].attrs.fill:void 0,getColor(e,t,n){const r=t.data,i=e.resources.formatter,o=e.resources.dataset,a={};if(n.coloring.label&&(a.label=`${n.coloring.label}`),"color"!==n.coloring.type&&r.fillTooltip){const e=i("fill"),t="measure"===n.coloring.fieldType;if(a.value=t&&e?e(r.fillTooltip.value):r.fillTooltip.label?r.fillTooltip.label:r.fillTooltip.value,!n.coloring.label){const e=o(r.fillTooltip.source.key).field(r.fillTooltip.source.field).title();a.label=`${e}`}}return a.fill=void 0===r._fillColor?Ie.getNodeFillColor(t):r._fillColor,a},getMeasure:(e,t)=>({label:`${e(t.source.key).field(t.source.field).title()}`,value:""===t.label||"NaN"===t.label?"-":t.label,field:t.source.field}),hideColorRow:(e,t)=>void 0===e.color.value||e.measures.some((e=>e.field===t.coloring.field)),getTitleRow(e,t){const n=Ae.detectTextDirection(e.title);return[{content:e.title,style:{"font-weight":"bold","text-align":t?"right":"left",direction:n},colspan:2},{}]},getDescriptionRow(e,t){const n=Ae.detectTextDirection(e.value);return[{content:e.value,style:{"text-align":t?"right":"left",direction:n},colspan:2},{}]},getNMoreRow(e,t,n){const r=t?t.get("Object.ChartTooltip.NMore",e):`+${e} more`;return[{content:r,style:{"font-weight":"bold","text-align":n?"right":"left",direction:Ae.detectTextDirection(r)},colspan:2},{}]},getSeparatorRow:()=>[{content:"",style:{"background-image":"linear-gradient(transparent 8px, rgba(255, 255, 255, 0.4) 8px, rgba(255, 255, 255, 0.4) 9.2px, transparent 9.2px)",height:"17px"},colspan:2},{}],getColorRow(e,t,n){const r=Ae.detectTextDirection(t.color.label),i=n?[":",t.color.label]:[t.color.label,":"],o=Ae.detectTextDirection(t.color.value);return[{content:i,style:{"text-align":n?"right":"left",direction:r}},{content:n?[t.color.value,Ie.getColorSymbol(e,t)]:[Ie.getColorSymbol(e,t),t.color.value],style:{"text-align":n?"left":"right",direction:o,"vertical-align":"middle"}}]},getMeasureRow(e,t,n,r,i=!1){const o=Ae.detectTextDirection(e.label),a=r?[":",e.label]:[e.label,":"],s=Ae.detectTextDirection(e.value);let l;return l=i?r?[e.value,Ie.getColorSymbol(t,n)]:[Ie.getColorSymbol(t,n),e.value]:[e.value],[{content:a,style:{"text-align":r?"right":"left",direction:o}},{content:l,style:{"text-align":r?"left":"right",direction:s,"vertical-align":"middle"}}]}};function Pe(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function Re(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function Fe(){}var ze=.7,He=1/ze,je="\\s*([+-]?\\d+)\\s*",Be="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Ve="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",_e=/^#([0-9a-f]{3,8})$/,Ue=new RegExp(`^rgb\\(${je},${je},${je}\\)$`),$e=new RegExp(`^rgb\\(${Ve},${Ve},${Ve}\\)$`),We=new RegExp(`^rgba\\(${je},${je},${je},${Be}\\)$`),Ke=new RegExp(`^rgba\\(${Ve},${Ve},${Ve},${Be}\\)$`),Ge=new RegExp(`^hsl\\(${Be},${Ve},${Ve}\\)$`),Ye=new RegExp(`^hsla\\(${Be},${Ve},${Ve},${Be}\\)$`),Xe={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function Je(){return this.rgb().formatHex()}function Ze(){return this.rgb().formatRgb()}function Qe(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=_e.exec(e))?(n=t[1].length,t=parseInt(t[1],16),6===n?et(t):3===n?new rt(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===n?tt(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===n?tt(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|240&t,((15&t)<<4|15&t)/255):null):(t=Ue.exec(e))?new rt(t[1],t[2],t[3],1):(t=$e.exec(e))?new rt(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=We.exec(e))?tt(t[1],t[2],t[3],t[4]):(t=Ke.exec(e))?tt(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=Ge.exec(e))?ut(t[1],t[2]/100,t[3]/100,1):(t=Ye.exec(e))?ut(t[1],t[2]/100,t[3]/100,t[4]):Xe.hasOwnProperty(e)?et(Xe[e]):"transparent"===e?new rt(NaN,NaN,NaN,0):null}function et(e){return new rt(e>>16&255,e>>8&255,255&e,1)}function tt(e,t,n,r){return r<=0&&(e=t=n=NaN),new rt(e,t,n,r)}function nt(e){return e instanceof Fe||(e=Qe(e)),e?new rt((e=e.rgb()).r,e.g,e.b,e.opacity):new rt}function rt(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}function it(){return`#${lt(this.r)}${lt(this.g)}${lt(this.b)}`}function ot(){const e=at(this.opacity);return`${1===e?"rgb(":"rgba("}${st(this.r)}, ${st(this.g)}, ${st(this.b)}${1===e?")":`, ${e})`}`}function at(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function st(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function lt(e){return((e=st(e))<16?"0":"")+e.toString(16)}function ut(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new dt(e,t,n,r)}function ct(e){if(e instanceof dt)return new dt(e.h,e.s,e.l,e.opacity);if(e instanceof Fe||(e=Qe(e)),!e)return new dt;if(e instanceof dt)return e;var t=(e=e.rgb()).r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),o=Math.max(t,n,r),a=NaN,s=o-i,l=(o+i)/2;return s?(a=t===o?(n-r)/s+6*(n<r):n===o?(r-t)/s+2:(t-n)/s+4,s/=l<.5?o+i:2-o-i,a*=60):s=l>0&&l<1?0:a,new dt(a,s,l,e.opacity)}function dt(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function mt(e){return(e=(e||0)%360)<0?e+360:e}function ft(e){return Math.max(0,Math.min(1,e||0))}function pt(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}Pe(Fe,Qe,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Je,formatHex:Je,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return ct(this).formatHsl()},formatRgb:Ze,toString:Ze}),Pe(rt,(function(e,t,n,r){return 1===arguments.length?nt(e):new rt(e,t,n,null==r?1:r)}),Re(Fe,{brighter(e){return e=null==e?He:Math.pow(He,e),new rt(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=null==e?ze:Math.pow(ze,e),new rt(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new rt(st(this.r),st(this.g),st(this.b),at(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:it,formatHex:it,formatHex8:function(){return`#${lt(this.r)}${lt(this.g)}${lt(this.b)}${lt(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:ot,toString:ot})),Pe(dt,(function(e,t,n,r){return 1===arguments.length?ct(e):new dt(e,t,n,null==r?1:r)}),Re(Fe,{brighter(e){return e=null==e?He:Math.pow(He,e),new dt(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=null==e?ze:Math.pow(ze,e),new dt(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,i=2*n-r;return new rt(pt(e>=240?e-240:e+120,i,r),pt(e,i,r),pt(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new dt(mt(this.h),ft(this.s),ft(this.l),at(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=at(this.opacity);return`${1===e?"hsl(":"hsla("}${mt(this.h)}, ${100*ft(this.s)}%, ${100*ft(this.l)}%${1===e?")":`, ${e})`}`}}));const ht=Math.PI/180,gt=180/Math.PI,yt=.96422,vt=.82521,bt=4/29,xt=6/29,qt=3*xt*xt,St=xt*xt*xt;function Mt(e){if(e instanceof Dt)return new Dt(e.l,e.a,e.b,e.opacity);if(e instanceof Ot)return Tt(e);e instanceof rt||(e=nt(e));var t,n,r=Et(e.r),i=Et(e.g),o=Et(e.b),a=Ct((.2225045*r+.7168786*i+.0606169*o)/1);return r===i&&i===o?t=n=a:(t=Ct((.4360747*r+.3850649*i+.1430804*o)/yt),n=Ct((.0139322*r+.0971045*i+.7141733*o)/vt)),new Dt(116*a-16,500*(t-a),200*(a-n),e.opacity)}function Dt(e,t,n,r){this.l=+e,this.a=+t,this.b=+n,this.opacity=+r}function Ct(e){return e>St?Math.pow(e,1/3):e/qt+bt}function wt(e){return e>xt?e*e*e:qt*(e-bt)}function Lt(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function Et(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function Nt(e,t,n,r){return 1===arguments.length?function(e){if(e instanceof Ot)return new Ot(e.h,e.c,e.l,e.opacity);if(e instanceof Dt||(e=Mt(e)),0===e.a&&0===e.b)return new Ot(NaN,0<e.l&&e.l<100?0:NaN,e.l,e.opacity);var t=Math.atan2(e.b,e.a)*gt;return new Ot(t<0?t+360:t,Math.sqrt(e.a*e.a+e.b*e.b),e.l,e.opacity)}(e):new Ot(e,t,n,null==r?1:r)}function Ot(e,t,n,r){this.h=+e,this.c=+t,this.l=+n,this.opacity=+r}function Tt(e){if(isNaN(e.h))return new Dt(e.l,0,0,e.opacity);var t=e.h*ht;return new Dt(e.l,Math.cos(t)*e.c,Math.sin(t)*e.c,e.opacity)}Pe(Dt,(function(e,t,n,r){return 1===arguments.length?Mt(e):new Dt(e,t,n,null==r?1:r)}),Re(Fe,{brighter(e){return new Dt(this.l+18*(null==e?1:e),this.a,this.b,this.opacity)},darker(e){return new Dt(this.l-18*(null==e?1:e),this.a,this.b,this.opacity)},rgb(){var e=(this.l+16)/116,t=isNaN(this.a)?e:e+this.a/500,n=isNaN(this.b)?e:e-this.b/200;return new rt(Lt(3.1338561*(t=yt*wt(t))-1.6168667*(e=1*wt(e))-.4906146*(n=vt*wt(n))),Lt(-.9787684*t+1.9161415*e+.033454*n),Lt(.0719453*t-.2289914*e+1.4052427*n),this.opacity)}})),Pe(Ot,Nt,Re(Fe,{brighter(e){return new Ot(this.h,this.c,this.l+18*(null==e?1:e),this.opacity)},darker(e){return new Ot(this.h,this.c,this.l-18*(null==e?1:e),this.opacity)},rgb(){return Tt(this).rgb()}}));var kt={isDark:function(e){return Nt(e).l<70}};function At(e){const t=e.qDef;!0===t.autoSort&&t.qSortCriterias.forEach((e=>{e.qSortByNumeric=1,e.qSortByAscii=1}))}function It(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function Pt(e){var t;return 1===e.length&&(t=e,e=function(e,n){return It(t(e),n)}),{left:function(t,n,r,i){for(null==r&&(r=0),null==i&&(i=t.length);r<i;){var o=r+i>>>1;e(t[o],n)<0?r=o+1:i=o}return r},right:function(t,n,r,i){for(null==r&&(r=0),null==i&&(i=t.length);r<i;){var o=r+i>>>1;e(t[o],n)>0?i=o:r=o+1}return r}}}var Rt=Pt(It).right,Ft=Math.sqrt(50),zt=Math.sqrt(10),Ht=Math.sqrt(2);function jt(e,t,n){var r=(t-e)/Math.max(0,n),i=Math.floor(Math.log(r)/Math.LN10),o=r/Math.pow(10,i);return i>=0?(o>=Ft?10:o>=zt?5:o>=Ht?2:1)*Math.pow(10,i):-Math.pow(10,-i)/(o>=Ft?10:o>=zt?5:o>=Ht?2:1)}function Bt(e,t,n){var r=Math.abs(t-e)/Math.max(0,n),i=Math.pow(10,Math.floor(Math.log(r)/Math.LN10)),o=r/i;return o>=Ft?i*=10:o>=zt?i*=5:o>=Ht&&(i*=2),t<e?-i:i}function Vt(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e)}return this}var _t="$";function Ut(){}function $t(e,t){var n=new Ut;if(e instanceof Ut)e.each((function(e,t){n.set(t,e)}));else if(Array.isArray(e)){var r,i=-1,o=e.length;if(null==t)for(;++i<o;)n.set(i,e[i]);else for(;++i<o;)n.set(t(r=e[i],i,e),r)}else if(e)for(var a in e)n.set(a,e[a]);return n}function Wt(){}Ut.prototype=$t.prototype={constructor:Ut,has:function(e){return _t+e in this},get:function(e){return this[_t+e]},set:function(e,t){return this[_t+e]=t,this},remove:function(e){var t=_t+e;return t in this&&delete this[t]},clear:function(){for(var e in this)e[0]===_t&&delete this[e]},keys:function(){var e=[];for(var t in this)t[0]===_t&&e.push(t.slice(1));return e},values:function(){var e=[];for(var t in this)t[0]===_t&&e.push(this[t]);return e},entries:function(){var e=[];for(var t in this)t[0]===_t&&e.push({key:t.slice(1),value:this[t]});return e},size:function(){var e=0;for(var t in this)t[0]===_t&&++e;return e},empty:function(){for(var e in this)if(e[0]===_t)return!1;return!0},each:function(e){for(var t in this)t[0]===_t&&e(this[t],t.slice(1),this)}};var Kt=$t.prototype;Wt.prototype={constructor:Wt,has:Kt.has,add:function(e){return this[_t+(e+="")]=e,this},remove:Kt.remove,clear:Kt.clear,values:Kt.keys,size:Kt.size,empty:Kt.empty,each:Kt.each};var Gt=Array.prototype,Yt=Gt.map,Xt=Gt.slice;function Jt(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function Zt(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function Qt(){}var en=.7,tn=1/en,nn="\\s*([+-]?\\d+)\\s*",rn="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",on="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",an=/^#([0-9a-f]{3,8})$/,sn=new RegExp("^rgb\\("+[nn,nn,nn]+"\\)$"),ln=new RegExp("^rgb\\("+[on,on,on]+"\\)$"),un=new RegExp("^rgba\\("+[nn,nn,nn,rn]+"\\)$"),cn=new RegExp("^rgba\\("+[on,on,on,rn]+"\\)$"),dn=new RegExp("^hsl\\("+[rn,on,on]+"\\)$"),mn=new RegExp("^hsla\\("+[rn,on,on,rn]+"\\)$"),fn={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function pn(){return this.rgb().formatHex()}function hn(){return this.rgb().formatRgb()}function gn(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=an.exec(e))?(n=t[1].length,t=parseInt(t[1],16),6===n?yn(t):3===n?new xn(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===n?vn(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===n?vn(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|240&t,((15&t)<<4|15&t)/255):null):(t=sn.exec(e))?new xn(t[1],t[2],t[3],1):(t=ln.exec(e))?new xn(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=un.exec(e))?vn(t[1],t[2],t[3],t[4]):(t=cn.exec(e))?vn(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=dn.exec(e))?Dn(t[1],t[2]/100,t[3]/100,1):(t=mn.exec(e))?Dn(t[1],t[2]/100,t[3]/100,t[4]):fn.hasOwnProperty(e)?yn(fn[e]):"transparent"===e?new xn(NaN,NaN,NaN,0):null}function yn(e){return new xn(e>>16&255,e>>8&255,255&e,1)}function vn(e,t,n,r){return r<=0&&(e=t=n=NaN),new xn(e,t,n,r)}function bn(e,t,n,r){return 1===arguments.length?((i=e)instanceof Qt||(i=gn(i)),i?new xn((i=i.rgb()).r,i.g,i.b,i.opacity):new xn):new xn(e,t,n,null==r?1:r);var i}function xn(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}function qn(){return"#"+Mn(this.r)+Mn(this.g)+Mn(this.b)}function Sn(){var e=this.opacity;return(1===(e=isNaN(e)?1:Math.max(0,Math.min(1,e)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===e?")":", "+e+")")}function Mn(e){return((e=Math.max(0,Math.min(255,Math.round(e)||0)))<16?"0":"")+e.toString(16)}function Dn(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new wn(e,t,n,r)}function Cn(e){if(e instanceof wn)return new wn(e.h,e.s,e.l,e.opacity);if(e instanceof Qt||(e=gn(e)),!e)return new wn;if(e instanceof wn)return e;var t=(e=e.rgb()).r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),o=Math.max(t,n,r),a=NaN,s=o-i,l=(o+i)/2;return s?(a=t===o?(n-r)/s+6*(n<r):n===o?(r-t)/s+2:(t-n)/s+4,s/=l<.5?o+i:2-o-i,a*=60):s=l>0&&l<1?0:a,new wn(a,s,l,e.opacity)}function wn(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function Ln(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}function En(e){return function(){return e}}function Nn(e){return 1==(e=+e)?On:function(t,n){return n-t?function(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}(t,n,e):En(isNaN(t)?n:t)}}function On(e,t){var n=t-e;return n?function(e,t){return function(n){return e+n*t}}(e,n):En(isNaN(e)?t:e)}Jt(Qt,gn,{copy:function(e){return Object.assign(new this.constructor,this,e)},displayable:function(){return this.rgb().displayable()},hex:pn,formatHex:pn,formatHsl:function(){return Cn(this).formatHsl()},formatRgb:hn,toString:hn}),Jt(xn,bn,Zt(Qt,{brighter:function(e){return e=null==e?tn:Math.pow(tn,e),new xn(this.r*e,this.g*e,this.b*e,this.opacity)},darker:function(e){return e=null==e?en:Math.pow(en,e),new xn(this.r*e,this.g*e,this.b*e,this.opacity)},rgb:function(){return this},displayable:function(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:qn,formatHex:qn,formatRgb:Sn,toString:Sn})),Jt(wn,(function(e,t,n,r){return 1===arguments.length?Cn(e):new wn(e,t,n,null==r?1:r)}),Zt(Qt,{brighter:function(e){return e=null==e?tn:Math.pow(tn,e),new wn(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=null==e?en:Math.pow(en,e),new wn(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,i=2*n-r;return new xn(Ln(e>=240?e-240:e+120,i,r),Ln(e,i,r),Ln(e<120?e+240:e-120,i,r),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var e=this.opacity;return(1===(e=isNaN(e)?1:Math.max(0,Math.min(1,e)))?"hsl(":"hsla(")+(this.h||0)+", "+100*(this.s||0)+"%, "+100*(this.l||0)+"%"+(1===e?")":", "+e+")")}}));var Tn=function e(t){var n=Nn(t);function r(e,t){var r=n((e=bn(e)).r,(t=bn(t)).r),i=n(e.g,t.g),o=n(e.b,t.b),a=On(e.opacity,t.opacity);return function(t){return e.r=r(t),e.g=i(t),e.b=o(t),e.opacity=a(t),e+""}}return r.gamma=e,r}(1);function kn(e,t){t||(t=[]);var n,r=e?Math.min(t.length,e.length):0,i=t.slice();return function(o){for(n=0;n<r;++n)i[n]=e[n]*(1-o)+t[n]*o;return i}}function An(e,t){var n,r=t?t.length:0,i=e?Math.min(r,e.length):0,o=new Array(i),a=new Array(r);for(n=0;n<i;++n)o[n]=jn(e[n],t[n]);for(;n<r;++n)a[n]=t[n];return function(e){for(n=0;n<i;++n)a[n]=o[n](e);return a}}function In(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function Pn(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function Rn(e,t){var n,r={},i={};for(n in null!==e&&"object"==typeof e||(e={}),null!==t&&"object"==typeof t||(t={}),t)n in e?r[n]=jn(e[n],t[n]):i[n]=t[n];return function(e){for(n in r)i[n]=r[n](e);return i}}var Fn=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,zn=new RegExp(Fn.source,"g");function Hn(e,t){var n,r,i,o=Fn.lastIndex=zn.lastIndex=0,a=-1,s=[],l=[];for(e+="",t+="";(n=Fn.exec(e))&&(r=zn.exec(t));)(i=r.index)>o&&(i=t.slice(o,i),s[a]?s[a]+=i:s[++a]=i),(n=n[0])===(r=r[0])?s[a]?s[a]+=r:s[++a]=r:(s[++a]=null,l.push({i:a,x:Pn(n,r)})),o=zn.lastIndex;return o<t.length&&(i=t.slice(o),s[a]?s[a]+=i:s[++a]=i),s.length<2?l[0]?function(e){return function(t){return e(t)+""}}(l[0].x):function(e){return function(){return e}}(t):(t=l.length,function(e){for(var n,r=0;r<t;++r)s[(n=l[r]).i]=n.x(e);return s.join("")})}function jn(e,t){var n,r=typeof t;return null==t||"boolean"===r?En(t):("number"===r?Pn:"string"===r?(n=gn(t))?(t=n,Tn):Hn:t instanceof gn?Tn:t instanceof Date?In:function(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}(t)?kn:Array.isArray(t)?An:"function"!=typeof t.valueOf&&"function"!=typeof t.toString||isNaN(t)?Rn:Pn)(e,t)}function Bn(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}function Vn(e){return+e}var _n=[0,1];function Un(e){return e}function $n(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:function(e){return function(){return e}}(isNaN(t)?NaN:.5)}function Wn(e){var t,n=e[0],r=e[e.length-1];return n>r&&(t=n,n=r,r=t),function(e){return Math.max(n,Math.min(r,e))}}function Kn(e,t,n){var r=e[0],i=e[1],o=t[0],a=t[1];return i<r?(r=$n(i,r),o=n(a,o)):(r=$n(r,i),o=n(o,a)),function(e){return o(r(e))}}function Gn(e,t,n){var r=Math.min(e.length,t.length)-1,i=new Array(r),o=new Array(r),a=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++a<r;)i[a]=$n(e[a],e[a+1]),o[a]=n(t[a],t[a+1]);return function(t){var n=Rt(e,t,1,r)-1;return o[n](i[n](t))}}function Yn(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function Xn(e,t){return function(){var e,t,n,r,i,o,a=_n,s=_n,l=jn,u=Un;function c(){return r=Math.min(a.length,s.length)>2?Gn:Kn,i=o=null,d}function d(t){return isNaN(t=+t)?n:(i||(i=r(a.map(e),s,l)))(e(u(t)))}return d.invert=function(n){return u(t((o||(o=r(s,a.map(e),Pn)))(n)))},d.domain=function(e){return arguments.length?(a=Yt.call(e,Vn),u===Un||(u=Wn(a)),c()):a.slice()},d.range=function(e){return arguments.length?(s=Xt.call(e),c()):s.slice()},d.rangeRound=function(e){return s=Xt.call(e),l=Bn,c()},d.clamp=function(e){return arguments.length?(u=e?Wn(a):Un,d):u!==Un},d.interpolate=function(e){return arguments.length?(l=e,c()):l},d.unknown=function(e){return arguments.length?(n=e,d):n},function(n,r){return e=n,t=r,c()}}()(e,t)}function Jn(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function Zn(e){return(e=Jn(Math.abs(e)))?e[1]:NaN}var Qn,er=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function tr(e){if(!(t=er.exec(e)))throw new Error("invalid format: "+e);var t;return new nr({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}function nr(e){this.fill=void 0===e.fill?" ":e.fill+"",this.align=void 0===e.align?">":e.align+"",this.sign=void 0===e.sign?"-":e.sign+"",this.symbol=void 0===e.symbol?"":e.symbol+"",this.zero=!!e.zero,this.width=void 0===e.width?void 0:+e.width,this.comma=!!e.comma,this.precision=void 0===e.precision?void 0:+e.precision,this.trim=!!e.trim,this.type=void 0===e.type?"":e.type+""}function rr(e,t){var n=Jn(e,t);if(!n)return e+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}tr.prototype=nr.prototype,nr.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};var ir={"%":function(e,t){return(100*e).toFixed(t)},b:function(e){return Math.round(e).toString(2)},c:function(e){return e+""},d:function(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)},e:function(e,t){return e.toExponential(t)},f:function(e,t){return e.toFixed(t)},g:function(e,t){return e.toPrecision(t)},o:function(e){return Math.round(e).toString(8)},p:function(e,t){return rr(100*e,t)},r:rr,s:function(e,t){var n=Jn(e,t);if(!n)return e+"";var r=n[0],i=n[1],o=i-(Qn=3*Math.max(-8,Math.min(8,Math.floor(i/3))))+1,a=r.length;return o===a?r:o>a?r+new Array(o-a+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+Jn(e,Math.max(0,t+o-1))[0]},X:function(e){return Math.round(e).toString(16).toUpperCase()},x:function(e){return Math.round(e).toString(16)}};function or(e){return e}var ar,sr,lr,ur=Array.prototype.map,cr=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function dr(e){var t,n,r=void 0===e.grouping||void 0===e.thousands?or:(t=ur.call(e.grouping,Number),n=e.thousands+"",function(e,r){for(var i=e.length,o=[],a=0,s=t[0],l=0;i>0&&s>0&&(l+s+1>r&&(s=Math.max(1,r-l)),o.push(e.substring(i-=s,i+s)),!((l+=s+1)>r));)s=t[a=(a+1)%t.length];return o.reverse().join(n)}),i=void 0===e.currency?"":e.currency[0]+"",o=void 0===e.currency?"":e.currency[1]+"",a=e.decimal+"",s=void 0===e.numerals?or:function(e){return function(t){return t.replace(/[0-9]/g,(function(t){return e[+t]}))}}(ur.call(e.numerals,String)),l=void 0===e.percent?"%":e.percent+"",u=e.minus+"",c=void 0===e.nan?"NaN":e.nan+"";function d(e){var t=(e=tr(e)).fill,n=e.align,d=e.sign,m=e.symbol,f=e.zero,p=e.width,h=e.comma,g=e.precision,y=e.trim,v=e.type;"n"===v?(h=!0,v="g"):ir[v]||(void 0===g&&(g=12),y=!0,v="g"),(f||"0"===t&&"="===n)&&(f=!0,t="0",n="=");var b="$"===m?i:"#"===m&&/[boxX]/.test(v)?"0"+v.toLowerCase():"",x="$"===m?o:/[%p]/.test(v)?l:"",q=ir[v],S=/[defgprs%]/.test(v);function M(e){var i,o,l,m=b,M=x;if("c"===v)M=q(e)+M,e="";else{var D=(e=+e)<0||1/e<0;if(e=isNaN(e)?c:q(Math.abs(e),g),y&&(e=function(e){e:for(var t,n=e.length,r=1,i=-1;r<n;++r)switch(e[r]){case".":i=t=r;break;case"0":0===i&&(i=r),t=r;break;default:if(!+e[r])break e;i>0&&(i=0)}return i>0?e.slice(0,i)+e.slice(t+1):e}(e)),D&&0==+e&&"+"!==d&&(D=!1),m=(D?"("===d?d:u:"-"===d||"("===d?"":d)+m,M=("s"===v?cr[8+Qn/3]:"")+M+(D&&"("===d?")":""),S)for(i=-1,o=e.length;++i<o;)if(48>(l=e.charCodeAt(i))||l>57){M=(46===l?a+e.slice(i+1):e.slice(i))+M,e=e.slice(0,i);break}}h&&!f&&(e=r(e,1/0));var C=m.length+e.length+M.length,w=C<p?new Array(p-C+1).join(t):"";switch(h&&f&&(e=r(w+e,w.length?p-M.length:1/0),w=""),n){case"<":e=m+e+M+w;break;case"=":e=m+w+e+M;break;case"^":e=w.slice(0,C=w.length>>1)+m+e+M+w.slice(C);break;default:e=w+m+e+M}return s(e)}return g=void 0===g?6:/[gprs]/.test(v)?Math.max(1,Math.min(21,g)):Math.max(0,Math.min(20,g)),M.toString=function(){return e+""},M}return{format:d,formatPrefix:function(e,t){var n=d(((e=tr(e)).type="f",e)),r=3*Math.max(-8,Math.min(8,Math.floor(Zn(t)/3))),i=Math.pow(10,-r),o=cr[8+r/3];return function(e){return n(i*e)+o}}}}function mr(e,t,n,r){var i,o=Bt(e,t,n);switch((r=tr(null==r?",f":r)).type){case"s":var a=Math.max(Math.abs(e),Math.abs(t));return null!=r.precision||isNaN(i=function(e,t){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(Zn(t)/3)))-Zn(Math.abs(e)))}(o,a))||(r.precision=i),lr(r,a);case"":case"e":case"g":case"p":case"r":null!=r.precision||isNaN(i=function(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,Zn(t)-Zn(e))+1}(o,Math.max(Math.abs(e),Math.abs(t))))||(r.precision=i-("e"===r.type));break;case"f":case"%":null!=r.precision||isNaN(i=function(e){return Math.max(0,-Zn(Math.abs(e)))}(o))||(r.precision=i-2*("%"===r.type))}return sr(r)}function fr(e){var t=e.domain;return e.ticks=function(e){var n=t();return function(e,t,n){var r,i,o,a,s=-1;if(n=+n,(e=+e)==(t=+t)&&n>0)return[e];if((r=t<e)&&(i=e,e=t,t=i),0===(a=jt(e,t,n))||!isFinite(a))return[];if(a>0)for(e=Math.ceil(e/a),t=Math.floor(t/a),o=new Array(i=Math.ceil(t-e+1));++s<i;)o[s]=(e+s)*a;else for(e=Math.floor(e*a),t=Math.ceil(t*a),o=new Array(i=Math.ceil(e-t+1));++s<i;)o[s]=(e-s)/a;return r&&o.reverse(),o}(n[0],n[n.length-1],null==e?10:e)},e.tickFormat=function(e,n){var r=t();return mr(r[0],r[r.length-1],null==e?10:e,n)},e.nice=function(n){null==n&&(n=10);var r,i=t(),o=0,a=i.length-1,s=i[o],l=i[a];return l<s&&(r=s,s=l,l=r,r=o,o=a,a=r),(r=jt(s,l,n))>0?r=jt(s=Math.floor(s/r)*r,l=Math.ceil(l/r)*r,n):r<0&&(r=jt(s=Math.ceil(s*r)/r,l=Math.floor(l*r)/r,n)),r>0?(i[o]=Math.floor(s/r)*r,i[a]=Math.ceil(l/r)*r,t(i)):r<0&&(i[o]=Math.ceil(s*r)/r,i[a]=Math.floor(l*r)/r,t(i)),e},e}function pr(){var e=Xn(Un,Un);return e.copy=function(){return Yn(e,pr())},Vt.apply(e,arguments),fr(e)}ar=dr({decimal:".",thousands:",",grouping:[3],currency:["$",""],minus:"-"}),sr=ar.format,lr=ar.formatPrefix;var hr=new Date,gr=new Date;function yr(e,t,n,r){function i(t){return e(t=0===arguments.length?new Date:new Date(+t)),t}return i.floor=function(t){return e(t=new Date(+t)),t},i.ceil=function(n){return e(n=new Date(n-1)),t(n,1),e(n),n},i.round=function(e){var t=i(e),n=i.ceil(e);return e-t<n-e?t:n},i.offset=function(e,n){return t(e=new Date(+e),null==n?1:Math.floor(n)),e},i.range=function(n,r,o){var a,s=[];if(n=i.ceil(n),o=null==o?1:Math.floor(o),!(n<r&&o>0))return s;do{s.push(a=new Date(+n)),t(n,o),e(n)}while(a<n&&n<r);return s},i.filter=function(n){return yr((function(t){if(t>=t)for(;e(t),!n(t);)t.setTime(t-1)}),(function(e,r){if(e>=e)if(r<0)for(;++r<=0;)for(;t(e,-1),!n(e););else for(;--r>=0;)for(;t(e,1),!n(e););}))},n&&(i.count=function(t,r){return hr.setTime(+t),gr.setTime(+r),e(hr),e(gr),Math.floor(n(hr,gr))},i.every=function(e){return e=Math.floor(e),isFinite(e)&&e>0?e>1?i.filter(r?function(t){return r(t)%e==0}:function(t){return i.count(0,t)%e==0}):i:null}),i}var vr=yr((function(){}),(function(e,t){e.setTime(+e+t)}),(function(e,t){return t-e}));vr.every=function(e){return e=Math.floor(e),isFinite(e)&&e>0?e>1?yr((function(t){t.setTime(Math.floor(t/e)*e)}),(function(t,n){t.setTime(+t+n*e)}),(function(t,n){return(n-t)/e})):vr:null},vr.range;var br=6e4,xr=36e5,qr=864e5,Sr=6048e5,Mr=yr((function(e){e.setTime(e-e.getMilliseconds())}),(function(e,t){e.setTime(+e+1e3*t)}),(function(e,t){return(t-e)/1e3}),(function(e){return e.getUTCSeconds()}));Mr.range;var Dr=yr((function(e){e.setHours(0,0,0,0)}),(function(e,t){e.setDate(e.getDate()+t)}),(function(e,t){return(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*br)/qr}),(function(e){return e.getDate()-1}));function Cr(e){return yr((function(t){t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)}),(function(e,t){e.setDate(e.getDate()+7*t)}),(function(e,t){return(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*br)/Sr}))}Dr.range;var wr=Cr(0),Lr=Cr(1),Er=Cr(2),Nr=Cr(3),Or=Cr(4),Tr=Cr(5),kr=Cr(6);wr.range,Lr.range,Er.range,Nr.range,Or.range,Tr.range,kr.range;var Ar=yr((function(e){e.setMonth(0,1),e.setHours(0,0,0,0)}),(function(e,t){e.setFullYear(e.getFullYear()+t)}),(function(e,t){return t.getFullYear()-e.getFullYear()}),(function(e){return e.getFullYear()}));Ar.every=function(e){return isFinite(e=Math.floor(e))&&e>0?yr((function(t){t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)}),(function(t,n){t.setFullYear(t.getFullYear()+n*e)})):null},Ar.range;var Ir=yr((function(e){e.setUTCSeconds(0,0)}),(function(e,t){e.setTime(+e+t*br)}),(function(e,t){return(t-e)/br}),(function(e){return e.getUTCMinutes()}));Ir.range;var Pr=yr((function(e){e.setUTCMinutes(0,0,0)}),(function(e,t){e.setTime(+e+t*xr)}),(function(e,t){return(t-e)/xr}),(function(e){return e.getUTCHours()}));Pr.range;var Rr=yr((function(e){e.setUTCHours(0,0,0,0)}),(function(e,t){e.setUTCDate(e.getUTCDate()+t)}),(function(e,t){return(t-e)/qr}),(function(e){return e.getUTCDate()-1}));function Fr(e){return yr((function(t){t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)}),(function(e,t){e.setUTCDate(e.getUTCDate()+7*t)}),(function(e,t){return(t-e)/Sr}))}Rr.range;var zr=Fr(0),Hr=Fr(1),jr=Fr(2),Br=Fr(3),Vr=Fr(4),_r=Fr(5),Ur=Fr(6);zr.range,Hr.range,jr.range,Br.range,Vr.range,_r.range,Ur.range;var $r=yr((function(e){e.setUTCDate(1),e.setUTCHours(0,0,0,0)}),(function(e,t){e.setUTCMonth(e.getUTCMonth()+t)}),(function(e,t){return t.getUTCMonth()-e.getUTCMonth()+12*(t.getUTCFullYear()-e.getUTCFullYear())}),(function(e){return e.getUTCMonth()}));$r.range;var Wr=yr((function(e){e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)}),(function(e,t){e.setUTCFullYear(e.getUTCFullYear()+t)}),(function(e,t){return t.getUTCFullYear()-e.getUTCFullYear()}),(function(e){return e.getUTCFullYear()}));function Kr(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function Gr(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function Yr(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}Wr.every=function(e){return isFinite(e=Math.floor(e))&&e>0?yr((function(t){t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)}),(function(t,n){t.setUTCFullYear(t.getUTCFullYear()+n*e)})):null},Wr.range;var Xr,Jr,Zr={"-":"",_:" ",0:"0"},Qr=/^\s*\d+/,ei=/^%/,ti=/[\\^$*+?|[\]().{}]/g;function ni(e,t,n){var r=e<0?"-":"",i=(r?-e:e)+"",o=i.length;return r+(o<n?new Array(n-o+1).join(t)+i:i)}function ri(e){return e.replace(ti,"\\$&")}function ii(e){return new RegExp("^(?:"+e.map(ri).join("|")+")","i")}function oi(e){for(var t={},n=-1,r=e.length;++n<r;)t[e[n].toLowerCase()]=n;return t}function ai(e,t,n){var r=Qr.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function si(e,t,n){var r=Qr.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function li(e,t,n){var r=Qr.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function ui(e,t,n){var r=Qr.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function ci(e,t,n){var r=Qr.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function di(e,t,n){var r=Qr.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function mi(e,t,n){var r=Qr.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function fi(e,t,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return r?(e.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function pi(e,t,n){var r=Qr.exec(t.slice(n,n+1));return r?(e.q=3*r[0]-3,n+r[0].length):-1}function hi(e,t,n){var r=Qr.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function gi(e,t,n){var r=Qr.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function yi(e,t,n){var r=Qr.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function vi(e,t,n){var r=Qr.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function bi(e,t,n){var r=Qr.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function xi(e,t,n){var r=Qr.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function qi(e,t,n){var r=Qr.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function Si(e,t,n){var r=Qr.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function Mi(e,t,n){var r=ei.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function Di(e,t,n){var r=Qr.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function Ci(e,t,n){var r=Qr.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function wi(e,t){return ni(e.getDate(),t,2)}function Li(e,t){return ni(e.getHours(),t,2)}function Ei(e,t){return ni(e.getHours()%12||12,t,2)}function Ni(e,t){return ni(1+Dr.count(Ar(e),e),t,3)}function Oi(e,t){return ni(e.getMilliseconds(),t,3)}function Ti(e,t){return Oi(e,t)+"000"}function ki(e,t){return ni(e.getMonth()+1,t,2)}function Ai(e,t){return ni(e.getMinutes(),t,2)}function Ii(e,t){return ni(e.getSeconds(),t,2)}function Pi(e){var t=e.getDay();return 0===t?7:t}function Ri(e,t){return ni(wr.count(Ar(e)-1,e),t,2)}function Fi(e){var t=e.getDay();return t>=4||0===t?Or(e):Or.ceil(e)}function zi(e,t){return e=Fi(e),ni(Or.count(Ar(e),e)+(4===Ar(e).getDay()),t,2)}function Hi(e){return e.getDay()}function ji(e,t){return ni(Lr.count(Ar(e)-1,e),t,2)}function Bi(e,t){return ni(e.getFullYear()%100,t,2)}function Vi(e,t){return ni((e=Fi(e)).getFullYear()%100,t,2)}function _i(e,t){return ni(e.getFullYear()%1e4,t,4)}function Ui(e,t){var n=e.getDay();return ni((e=n>=4||0===n?Or(e):Or.ceil(e)).getFullYear()%1e4,t,4)}function $i(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+ni(t/60|0,"0",2)+ni(t%60,"0",2)}function Wi(e,t){return ni(e.getUTCDate(),t,2)}function Ki(e,t){return ni(e.getUTCHours(),t,2)}function Gi(e,t){return ni(e.getUTCHours()%12||12,t