@nebula.js/sn-funnel-chart 1.11.0 → 1.13.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/api-specifications/properties.json +2 -2
- package/core/esm/index.js +4 -4
- package/dist/sn-funnel-chart.js +5 -5
- package/dist/sn-funnel-chart.systemjs.js +2 -2
- package/package.json +1 -1
- package/sn-funnel-chart-ext/dist/sn-funnel-chart.js +5 -5
- package/sn-funnel-chart-ext/sn-funnel-chart.qext +1 -1
package/core/esm/index.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* @nebula.js/sn-funnel-chart v1.
|
|
2
|
+
* @nebula.js/sn-funnel-chart v1.13.0
|
|
3
3
|
* Copyright (c) 2026 QlikTech International AB
|
|
4
4
|
* Released under the MIT license.
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
-
import e from"picasso.js";import t from"picasso-plugin-q";import{useElement as n,useSelections as r,useModel as i,useApp as o,useTranslator as a,useOptions as l,useState as s,useEffect as u,useStaleLayout as c,useTheme as d,useConstraints as f,useRect as p,usePlugins as h,useAppLayout as m,usePromise as g,onTakeSnapshot as v}from"@nebula.js/stardust";var y={Common_Measures:{id:"Common.Measures",locale:{"de-DE":"Kennzahlen","en-US":"Measures","es-ES":"Medidas","fr-FR":"Mesures","it-IT":"Misure","ja-JP":"メジャー","ko-KR":"측정값","nl-NL":"Metingen","pl-PL":"Miary","pt-BR":"Medidas","ru-RU":"Меры","sv-SE":"Mått","tr-TR":"Hesaplamalar","zh-CN":"度量","zh-TW":"量值"}},Object_ChartTooltip_ColorExpression:{id:"Object.ChartTooltip.ColorExpression",locale:{"de-DE":"Farbformel","en-US":"Color expression","es-ES":"Expresión de color","fr-FR":"Expression de couleur","it-IT":"Espressione colore","ja-JP":"カラー表現","ko-KR":"색상 표현식","nl-NL":"Kleuruitdrukking","pl-PL":"Wyrażenie koloru","pt-BR":"Expressão de cor","ru-RU":"Выражение для цвета","sv-SE":"Färguttryck","tr-TR":"Renk ifadesi","zh-CN":"颜色表达式","zh-TW":"色彩運算式"}},Object_ChartTooltip_NMore:{id:"Object.ChartTooltip.NMore",locale:{"de-DE":"+{0} mehr","en-US":"+{0} more","es-ES":"+{0} más","fr-FR":"+{0} plus","it-IT":"+{0} altre","ja-JP":"さらに +{0}","ko-KR":"{0} 이상","nl-NL":"+{0} meer","pl-PL":"Jeszcze {0}","pt-BR":"+{0} mais","ru-RU":"Еще +{0}","sv-SE":"Fler än {0} ytterligare","tr-TR":"+{0} daha","zh-CN":"+{0} 以上","zh-TW":"其他 +{0} 個"}},Object_ChartTooltip_sumOfNegatives:{id:"Object.ChartTooltip.sumOfNegatives",locale:{"de-DE":"Summe negativer Werte","en-US":"Sum of negatives","es-ES":"Suma de negativos","fr-FR":"Somme des valeurs négatives","it-IT":"Somma valori negativi","ja-JP":"負の合計","ko-KR":"음수 합계","nl-NL":"Som negatieven","pl-PL":"Suma ujemnych","pt-BR":"Soma de negativos","ru-RU":"Сумма отрицательных значений","sv-SE":"Summan av negativa","tr-TR":"Negatif değerlerin toplamı","zh-CN":"负值总和","zh-TW":"負數總和"}},Object_ChartTooltip_sumOfPositives:{id:"Object.ChartTooltip.sumOfPositives",locale:{"de-DE":"Summe positiver Werte","en-US":"Sum of positives","es-ES":"Suma de positivos","fr-FR":"Sommes des valeurs positives","it-IT":"Somma valori positivi","ja-JP":"正の合計","ko-KR":"양수 합계","nl-NL":"Som positieven","pl-PL":"Suma dodatnich","pt-BR":"Soma de positivos","ru-RU":"Сумма положительных значений","sv-SE":"Summan av positiva","tr-TR":"Pozitif değerlerin toplamı","zh-CN":"正值总和","zh-TW":"正數總和"}},Object_Disclaimer_DataRangeIncludingZero:{id:"Object.Disclaimer.DataRangeIncludingZero",locale:{"de-DE":"Die logarithmische Skala wurde durch die lineare Skala ersetzt, weil der Datenbereich NULL enthält.","en-US":"The logarithmic scale has been replaced by a linear scale because the data range includes zero.","es-ES":"La escala logarítmica ha sido reemplazada por una escala lineal porque el rango de datos incluye cero.","fr-FR":"L'échelle logarithmique a été remplacée par une échelle linéaire, car la plage de données comprend la valeur zéro.","it-IT":"La scala logaritmica è stata sostituita da una scala lineare perché l'intervallo di dati include zero.","ja-JP":"データ範囲にゼロが含まれるため、Log スケールは Linear スケールで置換されています。","ko-KR":"데이터 범위에 0이 포함되어 있으므로 로그 눈금이 선형 눈금으로 바뀌었습니다.","nl-NL":"De logaritmische schaal is vervangen door een lineaire schaal omdat het gegevensbereik nullen bevat.","pl-PL":"Skala logarytmiczna została zastąpiona liniową, ponieważ zakres danych zawiera zero.","pt-BR":"A escala logarítmica foi substituída por uma escala linear, pois o intervalo de dados inclui zero.","ru-RU":"Логарифмический масштаб заменен линейным масштабом, поскольку диапазон данных включает ноль.","sv-SE":"Den logaritmiska skalan har ersatts av en linjär skala eftersom dataintervallet innehåller värdet noll.","tr-TR":"Veri aralığı sıfır değerini içerdiğinden, logaritmik ölçek yerine doğrusal ölçek kullanıldı.","zh-CN":"对数刻度已替换为线性刻度,因为该数据范围包括零。","zh-TW":"對數刻度已遭線性刻度取代,因為資料範圍包含零。"}},Object_Disclaimer_LimitedData:{id:"Object.Disclaimer.LimitedData",locale:{"de-DE":"Zurzeit wird nur ein beschränkter Datensatz angezeigt.","en-US":"Currently showing a limited data set.","es-ES":"Mostrando actualmente un conjunto limitado de datos.","fr-FR":"Affichage d'un ensemble de données limité pour l'instant.","it-IT":"Attualmente viene visualizzata una serie di dati limitata.","ja-JP":"現在、限定的なデータ セットを表示しています。","ko-KR":"현재 제한된 데이터 집합을 표시하고 있습니다.","nl-NL":"Momenteel wordt een beperkte gegevensverzameling getoond.","pl-PL":"Aktualnie przedstawiany jest ograniczony zestaw danych.","pt-BR":"Mostrando um conjunto de dados limitado.","ru-RU":"В настоящее время отображается ограниченный набор данных.","sv-SE":"Just nu visas en begränsad datauppsättning.","tr-TR":"Şu anda sınırlı bir veri kümesi gösteriliyor.","zh-CN":"当前正显示有限的数据集。","zh-TW":"目前顯示的是有限的資料集。"}},Object_Disclaimer_NegativeOrZeroValues:{id:"Object.Disclaimer.NegativeOrZeroValues",locale:{"de-DE":"Die in den Datensätzen enthaltenen negativen oder 0-Werte können nicht in diesem Diagramm dargestellt werden.","en-US":"The data set contains negative or zero values that cannot be shown in this chart.","es-ES":"El conjunto de datos contiene valores cero o negativos que no se pueden mostrar en este gráfico.","fr-FR":"L'ensemble de données contient des valeurs négatives ou égales à zéro impossibles à afficher dans ce graphique.","it-IT":"La serie di dati contiene valori negativi o uguali a zero che non possono essere visualizzati in questo grafico.","ja-JP":"データ セットには、本チャートに表示できない負の値またはゼロ値が含まれています。","ko-KR":"데이터 집합에 해당 차트에 표시할 수 없는 음수 값 또는 zero 값이 포함되어 있습니다.","nl-NL":"De gegevensverzameling bevat negatieve waarden of nulwaarden die niet kunnen worden weergegeven in deze diagram.","pl-PL":"Zestaw danych zawiera wartości ujemne lub zerowe, których nie można przedstawić w tym wykresie.","pt-BR":"O conjunto de dados contém valores negativos ou iguais a zero que não podem ser mostrados neste gráfico.","ru-RU":"Набор данных содержит отрицательные или нулевые значения, которые невозможно показать в этой диаграмме.","sv-SE":"Datauppsättningen innehåller negativa värden eller nollvärden som inte kan visas i detta diagram.","tr-TR":"Veri kümesi, bu grafikte gösterilemeyen negatif veya sıfır değerlerini içeriyor.","zh-CN":"数据集中包含无法在此图表中显示的负值或零值。","zh-TW":"資料集包含無法在此圖表中顯示的負值或零值。"}},Object_Disclaimer_NegativeValues:{id:"Object.Disclaimer.NegativeValues",locale:{"de-DE":"Die in den Datensätzen enthaltenen negativen Werte können nicht in diesem Diagramm dargestellt werden.","en-US":"The data set contains negative values that cannot be shown in this chart.","es-ES":"El conjunto de datos contiene valores negativos que no se pueden mostrar en este gráfico.","fr-FR":"Le jeu de données contient des valeurs négatives impossibles à afficher dans ce graphique.","it-IT":"Il set di dati contiene valori negativi che non possono essere visualizzati in questo grafico.","ja-JP":"このチャートには表示できない負の値がデータ セットに含まれています。","ko-KR":"데이터 집합에 해당 차트에 표시할 수 없는 음수 값이 포함되어 있습니다.","nl-NL":"De gegevensverzameling bevat negatieve waarden die niet kunnen worden weergegeven in dit diagram.","pl-PL":"Zestaw danych zawiera wartości ujemne, których nie można przedstawić na tym wykresie.","pt-BR":"O conjunto de dados contém valores negativos que não podem ser mostrados neste gráfico.","ru-RU":"Набор данных содержит отрицательные значения, которые нельзя отобразить на этой диаграмме.","sv-SE":"Datauppsättningen innehåller negativa värden som inte kan visas i det här diagrammet.","tr-TR":"Veri kümesi, bu grafikte gösterilemeyen negatif değerleri içeriyor.","zh-CN":"数据集包含无法在此图表中显示的负值。","zh-TW":"資料集包含無法在此圖表中顯示的負值。"}},Object_Disclaimer_NoDataExist:{id:"Object.Disclaimer.NoDataExist",locale:{"de-DE":"Die Auswahlen haben für dieses Diagramm keine Daten generiert.","en-US":"The selections generated no data for this chart.","es-ES":"Las selecciones no han generado datos para este gráfico.","fr-FR":"Les sélections n'ont pas généré de données pour ce graphique.","it-IT":"Le selezioni non hanno generato dati per questo grafico.","ja-JP":"このチャートには選択からデータが生成されませんでした。","ko-KR":"선택 내용으로 이 차트에 대한 데이터가 생성되지 않았습니다.","nl-NL":"De selecties hebben geen gegevens voor de diagram gegenereerd.","pl-PL":"Wymiary nie spowodowały wygenerowania danych dla tego wykresu.","pt-BR":"As seleções não geraram dados para este gráfico.","ru-RU":"В результате выборок данные для этой диаграммы не созданы.","sv-SE":"Urvalen genererade inga data för detta diagram.","tr-TR":"Seçimler bu grafik için hiç veri oluşturmadı.","zh-CN":"选择未生成此图表的数据。","zh-TW":"此選項無法產生任何適用於此圖表的資料。"}},Object_Disclaimer_OnlyNanColor:{id:"Object.Disclaimer.OnlyNanColor",locale:{"de-DE":"Die verwendeten Daten für die Farbgebung dieser Visualisierung enthalten undefinierte Werte.","en-US":"The data used to color this visualization only contains undefined values.","es-ES":"Los datos utilizados para colorear esta visualización solo contienen valores indefinidos.","fr-FR":"Les données utilisées pour colorer cette visualisation ne comportent que des valeurs non définies.","it-IT":"I dati utilizzati per colorare questa visualizzazione contengono solo valori non definiti.","ja-JP":"このビジュアライゼーションの色の割り当てに使用したデータには、未定義の値が含まれています。","ko-KR":"이 시각화에 색을 지정하는 데 사용된 데이터에는 정의되지 않은 값만 포함되어 있습니다.","nl-NL":"De gegevens die worden gebruikt om deze visualisatie kleur te geven bevatten uitsluitend ongedefinieerde waarden.","pl-PL":"Dane używane do kolorowania tej wizualizacji zawierają wyłącznie niezdefiniowane wartości.","pt-BR":"Os dados usados para colorir esse visualização contém somente valores indefinidos.","ru-RU":"Данные, используемые для выбора цвета визуализации, содержат только неопределенные значения.","sv-SE":"Data som används för att färgsätta denna visualisering innehåller enbart odefinierade värden.","tr-TR":"Bu görselleştirmeyi renklendirmek için kullanılan veriler yalnızca tanımlanmamış değerler içeriyor.","zh-CN":"用于将该可视化着色的数据仅包含未定义的值。","zh-TW":"用以定義此視覺化的色彩的資料只包含未定義的值。"}},Object_Disclaimer_OnlyNanData:{id:"Object.Disclaimer.OnlyNanData",locale:{"de-DE":"Das Diagramm wird nicht angezeigt, da es nur nicht definierte Werte enthält.","en-US":"The chart is not displayed because it contains only undefined values.","es-ES":"El gráfico no se muestra porque solo contiene valores indefinidos.","fr-FR":"Le graphique n'est pas affiché, car il contient uniquement des valeurs non définies.","it-IT":"Il grafico non è visualizzato poiché contiene solo valori non definiti.","ja-JP":"未定義の値しか含まれていないため、チャートは表示されていません。","ko-KR":"정의되지 않은 값만 포함되어 있으므로 차트가 표시되지 않습니다.","nl-NL":"De diagram wordt niet weergegeven omdat deze alleen ongedefinieerde waarden bevat.","pl-PL":"Wykres nie jest wyświetlany, ponieważ zawiera wyłącznie wartości niezdefiniowane.","pt-BR":"O gráfico não foi exibido, porque contém apenas valores não definidos.","ru-RU":"Диаграмма не отображается, поскольку она содержит только неопределенные значения.","sv-SE":"Diagrammet visas inte eftersom det enbart innehåller odefinierade värden.","tr-TR":"Yalnızca tanımsız değerleri içermesi nedeniyle grafik görüntülenmiyor.","zh-CN":"未显示图表,因为它仅包含未定义的值。","zh-TW":"系統不會顯示圖表,因為該圖表僅包含未定義的值。"}},Object_Disclaimer_OnlyNegativeOrZeroValues:{id:"Object.Disclaimer.OnlyNegativeOrZeroValues",locale:{"de-DE":"Das Diagramm wird nicht angezeigt, da es nur negative oder 0-Werte enthält.","en-US":"The chart is not displayed because it contains only negative or zero values.","es-ES":"El gráfico no se muestra porque solo contiene valores negativos o valores cero.","fr-FR":"Le graphique n'est pas affiché, car il contient uniquement des valeurs négatives ou égales à zéro.","it-IT":"Il grafico non viene visualizzato poiché contiene solo valori negativi o uguali a zero.","ja-JP":"チャートは負の値またはゼロ値しか含まれていないため、表示されていません。","ko-KR":"음수 또는 zero 값만 포함되어 있으므로 차트가 표시되지 않습니다.","nl-NL":"De diagram wordt niet weergegeven omdat deze alleen negatieve waarden of nulwaarden bevat.","pl-PL":"Wykres nie jest wyświetlany, ponieważ zawiera wyłącznie wartości ujemne lub zerowe.","pt-BR":"O gráfico não foi exibido, porque contém apenas valores negativos ou zero.","ru-RU":"Диаграмма не отображается, поскольку она содержит только отрицательные или нулевые значения.","sv-SE":"Diagrammet visas inte eftersom det enbart innehåller negativa värden eller nollvärden","tr-TR":"Yalnızca negatif veya sıfır değerlerini içermesi nedeniyle grafik görüntülenmiyor.","zh-CN":"未显示图表,因为它仅包含负值或零值。","zh-TW":"系統不會顯示圖表,因為該圖表僅包含負值或零值。"}},Object_Disclaimer_OnlyNegativeValues:{id:"Object.Disclaimer.OnlyNegativeValues",locale:{"de-DE":"Das Diagramm wird nicht angezeigt, da es nur negative oder Werte enthält.","en-US":"The chart is not displayed because it contains only negative values.","es-ES":"El gráfico no se muestra porque solo contiene valores negativos.","fr-FR":"Le graphique n'est pas affiché, car il contient uniquement des valeurs négatives.","it-IT":"Il grafico non viene visualizzato poiché contiene solo valori negativi.","ja-JP":"負の値しか含まれていないため、チャートは表示されていません。","ko-KR":"음수 값만 포함되어 있으므로 차트가 표시되지 않습니다.","nl-NL":"Het diagram wordt niet weergegeven omdat deze alleen negatieve waarden bevat.","pl-PL":"Wykres nie jest wyświetlany, ponieważ zawiera wyłącznie wartości ujemne.","pt-BR":"O gráfico não é exibido porque contém apenas valores negativos.","ru-RU":"Диаграмма не отображается, поскольку она содержит только отрицательные значения.","sv-SE":"Diagrammet visas inte eftersom det endast innehåller negativa värden.","tr-TR":"Yalnızca negatif değerleri içermesi nedeniyle grafik görüntülenmiyor.","zh-CN":"未显示图表,因为它仅包含负值。","zh-TW":"系統不會顯示圖表,因為該圖表僅包含負值。"}},Object_ErrorMessage_MissingDimension:{id:"Object.ErrorMessage.MissingDimension",locale:{"de-DE":"Dimension nicht gefunden","en-US":"Dimension not found","es-ES":"No se ha encontrado la dimensión","fr-FR":"Dimension introuvable","it-IT":"Dimensione non trovata","ja-JP":"軸が見つかりません","ko-KR":"차원을 찾지 못했습니다.","nl-NL":"Dimensie niet gevonden","pl-PL":"Wymiar nie został znaleziony","pt-BR":"Dimensão não encontrada","ru-RU":"Измерение не найдено","sv-SE":"Dimensionen hittades inte","tr-TR":"Boyut bulunamadı","zh-CN":"未找到维度","zh-TW":"找不到維度"}},Object_ErrorMessage_MissingMeasure:{id:"Object.ErrorMessage.MissingMeasure",locale:{"de-DE":"Kennzahl nicht gefunden","en-US":"Measure not found","es-ES":"No se ha encontrado la medida","fr-FR":"Mesure introuvable","it-IT":"Misura non trovata","ja-JP":"メジャーが見つかりません","ko-KR":"측정값을 찾지 못했습니다.","nl-NL":"Meting niet gevonden","pl-PL":"Miara nie została znaleziona","pt-BR":"Medida não encontrada","ru-RU":"Мера не найдена","sv-SE":"Måttet hittades inte","tr-TR":"Hesaplama bulunamadı","zh-CN":"未找到度量","zh-TW":"找不到量值"}},Tooltip_ToggleOffLassoSelection:{id:"Tooltip.ToggleOffLassoSelection",locale:{"de-DE":"Lasso-Auswahl deaktivieren","en-US":"Turn off lasso selection","es-ES":"Desactivar la selección de contorno","fr-FR":"Désactiver la sélection au lasso","it-IT":"Disattiva selezione lazo","ja-JP":"囲み選択をオフにする","ko-KR":"올가미 선택 끄기","nl-NL":"Lassoselectie uitschakelen","pl-PL":"Wyłącz zaznaczenie lasso","pt-BR":"Desativar seleção de laço","ru-RU":"Выключить выбор лассо","sv-SE":"Stäng av lassourval","tr-TR":"Serbest seçimi kapat","zh-CN":"关闭套索选择方法","zh-TW":"關閉套索選取"}},Tooltip_ToggleOnLassoSelection:{id:"Tooltip.ToggleOnLassoSelection",locale:{"de-DE":"Lasso-Auswahl aktivieren","en-US":"Turn on lasso selection","es-ES":"Activar la selección de contorno","fr-FR":"Activer la sélection au lasso","it-IT":"Attiva selezione lazo","ja-JP":"囲み選択をオンにする","ko-KR":"올가미 선택 켜기","nl-NL":"Lassoselectie inschakelen","pl-PL":"Włącz zaznaczenie lasso","pt-BR":"Ativar seleção de laço","ru-RU":"Включить выбор лассо","sv-SE":"Slå på lassourval","tr-TR":"Serbest seçimi aç","zh-CN":"开启套索选择方法","zh-TW":"開啟套索選取"}},Tooltip_dimensions_cyclic:{id:"Tooltip.dimensions.cyclic",locale:{"de-DE":"Zyklische Dimension","en-US":"Cyclic dimension","es-ES":"Dimensión cíclica","fr-FR":"Dimension cyclique","it-IT":"Dimensione ciclica","ja-JP":"サイクリック軸","ko-KR":"순환 차원","nl-NL":"Cyclische dimensie","pl-PL":"Wymiar cykliczny","pt-BR":"Dimensão cíclica","ru-RU":"Циклическое измерение","sv-SE":"Cyklisk dimension","tr-TR":"Döngüsel boyut","zh-CN":"循环维度","zh-TW":"循環維度"}},Tooltip_dimensions_drilldown:{id:"Tooltip.dimensions.drilldown",locale:{"de-DE":"Drilldown-Dimension","en-US":"Drill-down dimension","es-ES":"Dimensión jerárquica","fr-FR":"Descendre dans la hiérarchie de la dimension","it-IT":"Dimensione di drill-down","ja-JP":"軸のドリルダウン","ko-KR":"드릴다운 차원","nl-NL":"Drill-downdimensie","pl-PL":"Wymiar hierarchiczny","pt-BR":"Dimensão da hierarquia","ru-RU":"Детализированное измерение","sv-SE":"Hierarkisk dimension","tr-TR":"Detaya inme boyutu","zh-CN":"下钻维度","zh-TW":"向下探查維度"}},Tooltip_selections_locked:{id:"Tooltip.selections.locked",locale:{"de-DE":"Auswahlen sind für diese Dimension gesperrt","en-US":"Selections on this dimension are locked","es-ES":"Las selecciones de esta dimensión están bloqueadas.","fr-FR":"Sélections verrouillées pour cette dimension","it-IT":"Le selezioni in questa dimensione sono bloccate","ja-JP":"この軸での選択はロックされています","ko-KR":"이 차원의 선택은 잠겨 있습니다.","nl-NL":"Selecties voor deze dimensie zijn vergrendeld","pl-PL":"Wybory dotyczące tego wymiaru są zablokowane","pt-BR":"Seleções estão bloqueadas nesta dimensão","ru-RU":"Выборки для данного измерения заблокированы","sv-SE":"Urval i den här dimensionen är låsta","tr-TR":"Bu boyuttaki seçimler kilitli","zh-CN":"相关维度的选择已锁定","zh-TW":"已鎖定此維度上的選項"}},Visualizations_Descriptions_Bars:{id:"Visualizations.Descriptions.Bars",locale:{"de-DE":"Balken","en-US":"Bars","es-ES":"Barras","fr-FR":"Barres","it-IT":"Barre","ja-JP":"棒","ko-KR":"막대","nl-NL":"Staven","pl-PL":"Słupki","pt-BR":"Barras","ru-RU":"Полосы","sv-SE":"Staplar","tr-TR":"Çubuklar","zh-CN":"条形","zh-TW":"長條"}},Visualizations_Descriptions_HeightLine:{id:"Visualizations.Descriptions.HeightLine",locale:{"de-DE":"Linienhöhe","en-US":"Height of line","es-ES":"Altura de línea","fr-FR":"Hauteur de ligne","it-IT":"Altezza della linea","ja-JP":"線の高さ","ko-KR":"선 높이","nl-NL":"Hoogte van lijn","pl-PL":"Wysokość linii","pt-BR":"Altura da linha","ru-RU":"Высота линии","sv-SE":"Linjens höjd","tr-TR":"Çizgi yüksekliği","zh-CN":"线高度","zh-TW":"折線高度"}},Visualizations_Descriptions_LengthBars:{id:"Visualizations.Descriptions.LengthBars",locale:{"de-DE":"Balkenlänge","en-US":"Length of bars","es-ES":"Longitud de barras","fr-FR":"Longueur des barres","it-IT":"Lunghezza delle barre","ja-JP":"棒の長さ","ko-KR":"막대 길이","nl-NL":"Lengte van staven","pl-PL":"Długość słupków","pt-BR":"Comprimento das barras","ru-RU":"Длина полос","sv-SE":"Staplarnas längd","tr-TR":"Çubuk uzunluğu","zh-CN":"条形长度","zh-TW":"長條長度"}},properties_dataPoints_labelmode_share:{id:"properties.dataPoints.labelmode.share",locale:{"de-DE":"Freigeben","en-US":"Share","es-ES":"Compartir","fr-FR":"Partage","it-IT":"Condividi","ja-JP":"共有","ko-KR":"공유","nl-NL":"Delen","pl-PL":"Udostępnij","pt-BR":"Compartilhar","ru-RU":"Совместное использование","sv-SE":"Dela","tr-TR":"Paylaş","zh-CN":"共享","zh-TW":"共用"}},properties_trendlines_types_average:{id:"properties.trendlines.types.average",locale:{"de-DE":"Durchschnitt","en-US":"Average","es-ES":"Media","fr-FR":"Moyenne","it-IT":"Media","ja-JP":"平均値","ko-KR":"평균","nl-NL":"Gemiddelde","pl-PL":"Średnia","pt-BR":"Média","ru-RU":"Среднее","sv-SE":"Medel","tr-TR":"Ortalama","zh-CN":"平均值","zh-TW":"平均值"}},properties_trendlines_types_exponential:{id:"properties.trendlines.types.exponential",locale:{"de-DE":"Exponentiell","en-US":"Exponential","es-ES":"Exponencial","fr-FR":"Exponentiel","it-IT":"Esponenziale","ja-JP":"指数","ko-KR":"지수","nl-NL":"Exponentieel","pl-PL":"Wykładnicze","pt-BR":"Exponencial","ru-RU":"Экспоненциальный","sv-SE":"Exponentiell","tr-TR":"Üstel","zh-CN":"指数","zh-TW":"指數"}},properties_trendlines_types_linear:{id:"properties.trendlines.types.linear",locale:{"de-DE":"Linear","en-US":"Linear","es-ES":"Lineal","fr-FR":"Linéaire","it-IT":"Lineare","ja-JP":"線形","ko-KR":"선형","nl-NL":"Lineair","pl-PL":"Liniowe","pt-BR":"Linear","ru-RU":"Линейный","sv-SE":"Linjär","tr-TR":"Doğrusal","zh-CN":"线性","zh-TW":"線性"}},properties_trendlines_types_logarithmic:{id:"properties.trendlines.types.logarithmic",locale:{"de-DE":"Logarithmisch","en-US":"Logarithmic","es-ES":"Logarítmica","fr-FR":"Logarithmique","it-IT":"Logaritmica","ja-JP":"対数","ko-KR":"로그","nl-NL":"Logaritmisch","pl-PL":"Logarytmiczne","pt-BR":"Logarítmico","ru-RU":"Логарифмический","sv-SE":"Logaritmisk","tr-TR":"Logaritmik","zh-CN":"对数","zh-TW":"對數"}},properties_trendlines_types_polynomial2:{id:"properties.trendlines.types.polynomial2",locale:{"de-DE":"Polynom zweiten Grades","en-US":"Second degree polynomial","es-ES":"Polinómica de segundo grado","fr-FR":"Polynomial du 2ème degré","it-IT":"Polinomio di secondo grado","ja-JP":"2 番目の角度の多項式近似","ko-KR":"2차 다항식","nl-NL":"Tweedegraadspolynoom","pl-PL":"Wielomianowe drugiego stopnia","pt-BR":"Polinômio de segundo grau","ru-RU":"Полиномиальный второй степени","sv-SE":"Polynomial, andra graden","tr-TR":"İkinci derece polinom","zh-CN":"二次多项式","zh-TW":"第二度多項式"}},properties_trendlines_types_polynomial3:{id:"properties.trendlines.types.polynomial3",locale:{"de-DE":"Polynom dritten Grades","en-US":"Third degree polynomial","es-ES":"Polinómica de tercer grado","fr-FR":"Polynomial du 3ème degré","it-IT":"Polinomio di terzo grado","ja-JP":"3 番目の角度の多項式近似","ko-KR":"3차 다항식","nl-NL":"Derdegraadspolynoom","pl-PL":"Wielomianowe trzeciego stopnia","pt-BR":"Polinômio de terceiro grau","ru-RU":"Полиномиальный третьей степени","sv-SE":"Polynomial, tredje graden","tr-TR":"Üçüncü derece polinom","zh-CN":"三次多项式","zh-TW":"第三度多項式"}},properties_trendlines_types_polynomial4:{id:"properties.trendlines.types.polynomial4",locale:{"de-DE":"Polynom vierten Grades","en-US":"Fourth degree polynomial","es-ES":"Polinómica de cuarto grado","fr-FR":"Polynomial du 4ème degré","it-IT":"Polinomio di quarto grado","ja-JP":"4 番目の角度の多項式近似","ko-KR":"4차 다항식","nl-NL":"Vierdegraadspolynoom","pl-PL":"Wielomianowe czwartego stopnia","pt-BR":"Polinômio de quarto grau","ru-RU":"Полиномиальный четвертой степени","sv-SE":"Polynomial, fjärde graden","tr-TR":"Dördüncü derece polinom","zh-CN":"四次多项式","zh-TW":"第四度多項式"}},properties_trendlines_types_power:{id:"properties.trendlines.types.power",locale:{"de-DE":"Potenz","en-US":"Power","es-ES":"Potencia","fr-FR":"Puissance","it-IT":"Potenza","ja-JP":"累乗","ko-KR":"거듭제곱","nl-NL":"Macht","pl-PL":"Potęgowe","pt-BR":"Potência","ru-RU":"Степенной","sv-SE":"Potens","tr-TR":"Üs","zh-CN":"幂","zh-TW":"乘冪"}}};const b={fill:"steelblue",num:1},x=.9,w=150,q=(e,t,n)=>{let r=0,i=0,o=0,a={},l=0;if("labelCenter"===e)r=t.bottomLeft.x,i=t.topRight.y,o=t.bottomRight.x-t.bottomLeft.x,l=t.bottomRight.y-t.topRight.y,a={share:n.share,fill:n.fill};else{const e=180/Math.PI*Math.atan((t.bottomRight.y-t.topRight.y)/(t.topRight.x-t.bottomRight.x));r=e<15&&e>=0?t.topRight.x:e>-15&&e<0?t.bottomRight.x:e<-15?(t.bottomRight.x-t.topRight.x)/2+t.topRight.x+15:(t.topRight.x-t.bottomRight.x)/2+t.bottomRight.x+15,i=t.topRight.y,o=t.width-r,l=t.bottomRight.y-t.topRight.y,a={fill:n.fill}}return{tag:e,type:"rect",x:r,y:i,width:o,height:l,data:n.data,desc:a,fill:"none"}},D=(e,t)=>{const n=(e=>{const t=(e=>{let t=0;return e.forEach(e=>{e.num>t&&(t=e.num)}),t})(e);let n=0;return e.slice().reverse().map(e=>{const r={datum:e,s:n/t,e:e.num/t};return n=e.num,r}).reverse()})(e),r=t.width*x,i=t.height*x,o=(t.width-r)/2,a=(t.height-i)/2,l=r-(r>w&&i>w?100:0),s=(i-1*(n.length-1))/n.length,u=[];return n.forEach((e,r)=>{const i=(c=e.e,d=r<n.length-1?e.s:e.e,[.5-.5*c,.5+.5*c,.5+.5*d,.5-.5*d]).map(e=>Math.round(e*l+o));var c,d;const f=s*r+1*r+a,p={bottomRight:{x:i[2],y:Math.round(f+s)},bottomLeft:{x:i[3],y:Math.round(f+s)},topRight:{x:i[1],y:Math.round(f)},topLeft:{x:i[0],y:Math.round(f)},width:t.width},h=`M${p.topLeft.x},${p.topLeft.y} L${p.topRight.x},${p.topRight.y} ${p.bottomRight.x},${p.bottomRight.y} ${p.bottomLeft.x},${p.bottomLeft.y}Z`;u.push({tag:"section",type:"path",d:h,data:e.datum.data,fill:e.datum.fill});const m={share:e.e,fill:e.datum.fill,data:e.datum.data};s>12&&(p.bottomRight.x-p.bottomLeft.x>32&&u.push(q("labelCenter",p,m)),u.push(q("labelLeft",p,m)))}),u},S=(e,t,n,r)=>(r-e)/r*(t-n)+n,k=(e,t,n)=>{const r=e.filter(e=>"NaN"!==e.num&&e.num>0),i=r.length,o=n.width*x,a=n.height*x,l=Math.round((n.width-o)/2),s=Math.round((n.height-a)/2),u=o-(o>w&&a>w?100:0),c=a-1*(i-1),d=[],f=r[0].data.num.value;let p=s;return r.forEach((e,r)=>{const i=t[r]*c,o=Math.round(S(p-s,u,.2*u,a)/2),h=Math.round(S(p-s+i,u,.2*u,a)/2),m=l+Math.round(u/2),g={bottomRight:{x:m+h,y:Math.round(p+i)},bottomLeft:{x:m-h,y:Math.round(p+i)},topRight:{x:m+o,y:p},topLeft:{x:m-o,y:p},width:n.width},v=`M${g.topLeft.x},${g.topLeft.y} L${g.topRight.x},${g.topRight.y} ${g.bottomRight.x},${g.bottomRight.y} ${g.bottomLeft.x},${g.bottomLeft.y}Z`;d.push({tag:"section",type:"path",d:v,data:e.data,fill:e.fill});const y={share:e.data.num.value/f,fill:e.fill,data:e.data};i>2&&(g.bottomRight.x-g.bottomLeft.x>32&&d.push(q("labelCenter",g,y)),d.push(q("labelLeft",g,y))),p+=i+1}),d},C=(e,t,n)=>{const r=e.filter(e=>"NaN"!==e.num&&e.num>0);if(r&&r.length>0)switch(t){case"WIDTH":default:return D(r,n);case"ORDER":return k(r,r.map(()=>1/r.length),n);case"HEIGHT":return k(r,(e=>{const t=e.reduce((e,t)=>e+t.data.num.value,0);return e.map(e=>e.data.num.value/t)})(r),n);case"AREA":return k(r,((e,t,n)=>{const r=e.reduce((e,t)=>e+t.data.num.value,0),i=t.width*x,o=t.height*x,a=i*n,l=o*(i+a)/2,s=(i-a)/2/o,u=[];let c=0;for(let t=e.length-1;t>=0;t--){const n=e[t].data.num.value/r,i=2*s*c+a,d=-i/(2*s)+Math.sqrt(i*i/(4*s*s)+n*l/s);u[t]=d/o,c+=d}return u})(r,n,.2),n)}return[]};var M={require:["resolver"],defaultSettings:{settings:{},data:{},style:{item:"$shape"}},render({data:e}){const t=this.resolver.resolve({data:e,defaults:{...b,...this.style.item},settings:this.settings.settings});return C(t.items,this.settings.settings.mode,this.rect)}};const I={version:"1.11.0",color:{auto:!0,autoMinMax:!0,byDimDef:void 0,byMeasureDef:void 0,colorExpression:void 0,dimensionScheme:"12",expressionIsColor:!0,expressionLabel:"",measureMin:void 0,measureMax:void 0,measureScheme:"sg",mode:"primary",paletteColor:{index:6},persistent:!1,reverseScheme:!1,singleColor:void 0,useBaseColors:"off",useDimColVal:!0,useMeasureGradient:!0},dataPoint:{auto:!0,labelMode:"share"},footnote:"",funnel:{mode:"WIDTH"},qHyperCubeDef:{qDimensions:[],qMeasures:[],qInterColumnSortOrder:[],qInitialDataFetch:[{qWidth:2,qHeight:5e3}],qSuppressMissing:!0,qSuppressZero:!1},showDimensionTitle:!0,showTitles:!0,subtitle:"",title:""};function N(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function O(e,t,n,r,i,o,a){try{var l=e[o](a),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(r,i)}function E(e){return function(){var t=this,n=arguments;return new Promise(function(r,i){var o=e.apply(t,n);function a(e){O(o,r,i,a,l,"next",e)}function l(e){O(o,r,i,a,l,"throw",e)}a(void 0)})}}function R(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function T(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function L(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?T(Object(n),!0).forEach(function(t){R(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):T(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function z(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;n[r]=e[r]}return n}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],-1===t.indexOf(n)&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function P(){
|
|
7
|
+
import e from"picasso.js";import t from"picasso-plugin-q";import{useElement as n,useSelections as r,useModel as i,useApp as o,useTranslator as a,useOptions as l,useState as s,useEffect as u,useStaleLayout as c,useTheme as d,useConstraints as f,useRect as p,usePlugins as h,useAppLayout as m,usePromise as g,onTakeSnapshot as v}from"@nebula.js/stardust";var y={Common_Measures:{id:"Common.Measures",locale:{"de-DE":"Kennzahlen","en-US":"Measures","es-ES":"Medidas","fr-FR":"Mesures","it-IT":"Misure","ja-JP":"メジャー","ko-KR":"측정값","nl-NL":"Metingen","pl-PL":"Miary","pt-BR":"Medidas","ru-RU":"Меры","sv-SE":"Mått","tr-TR":"Hesaplamalar","zh-CN":"度量","zh-TW":"量值"}},Object_ChartTooltip_ColorExpression:{id:"Object.ChartTooltip.ColorExpression",locale:{"de-DE":"Farbformel","en-US":"Color expression","es-ES":"Expresión de color","fr-FR":"Expression de couleur","it-IT":"Espressione colore","ja-JP":"カラー表現","ko-KR":"색상 표현식","nl-NL":"Kleuruitdrukking","pl-PL":"Wyrażenie koloru","pt-BR":"Expressão de cor","ru-RU":"Выражение для цвета","sv-SE":"Färguttryck","tr-TR":"Renk ifadesi","zh-CN":"颜色表达式","zh-TW":"色彩運算式"}},Object_ChartTooltip_NMore:{id:"Object.ChartTooltip.NMore",locale:{"de-DE":"+{0} mehr","en-US":"+{0} more","es-ES":"+{0} más","fr-FR":"+{0} plus","it-IT":"+{0} altre","ja-JP":"さらに +{0}","ko-KR":"{0} 이상","nl-NL":"+{0} meer","pl-PL":"Jeszcze {0}","pt-BR":"+{0} mais","ru-RU":"Еще +{0}","sv-SE":"Fler än {0} ytterligare","tr-TR":"+{0} daha","zh-CN":"+{0} 以上","zh-TW":"其他 +{0} 個"}},Object_ChartTooltip_sumOfNegatives:{id:"Object.ChartTooltip.sumOfNegatives",locale:{"de-DE":"Summe negativer Werte","en-US":"Sum of negatives","es-ES":"Suma de negativos","fr-FR":"Somme des valeurs négatives","it-IT":"Somma valori negativi","ja-JP":"負の合計","ko-KR":"음수 합계","nl-NL":"Som negatieven","pl-PL":"Suma ujemnych","pt-BR":"Soma de negativos","ru-RU":"Сумма отрицательных значений","sv-SE":"Summan av negativa","tr-TR":"Negatif değerlerin toplamı","zh-CN":"负值总和","zh-TW":"負數總和"}},Object_ChartTooltip_sumOfPositives:{id:"Object.ChartTooltip.sumOfPositives",locale:{"de-DE":"Summe positiver Werte","en-US":"Sum of positives","es-ES":"Suma de positivos","fr-FR":"Sommes des valeurs positives","it-IT":"Somma valori positivi","ja-JP":"正の合計","ko-KR":"양수 합계","nl-NL":"Som positieven","pl-PL":"Suma dodatnich","pt-BR":"Soma de positivos","ru-RU":"Сумма положительных значений","sv-SE":"Summan av positiva","tr-TR":"Pozitif değerlerin toplamı","zh-CN":"正值总和","zh-TW":"正數總和"}},Object_Disclaimer_DataRangeIncludingZero:{id:"Object.Disclaimer.DataRangeIncludingZero",locale:{"de-DE":"Die logarithmische Skala wurde durch die lineare Skala ersetzt, weil der Datenbereich NULL enthält.","en-US":"The logarithmic scale has been replaced by a linear scale because the data range includes zero.","es-ES":"La escala logarítmica ha sido reemplazada por una escala lineal porque el rango de datos incluye cero.","fr-FR":"L'échelle logarithmique a été remplacée par une échelle linéaire, car la plage de données comprend la valeur zéro.","it-IT":"La scala logaritmica è stata sostituita da una scala lineare perché l'intervallo di dati include zero.","ja-JP":"データ範囲にゼロが含まれるため、Log スケールは Linear スケールで置換されています。","ko-KR":"데이터 범위에 0이 포함되어 있으므로 로그 눈금이 선형 눈금으로 바뀌었습니다.","nl-NL":"De logaritmische schaal is vervangen door een lineaire schaal omdat het gegevensbereik nullen bevat.","pl-PL":"Skala logarytmiczna została zastąpiona liniową, ponieważ zakres danych zawiera zero.","pt-BR":"A escala logarítmica foi substituída por uma escala linear, pois o intervalo de dados inclui zero.","ru-RU":"Логарифмический масштаб заменен линейным масштабом, поскольку диапазон данных включает ноль.","sv-SE":"Den logaritmiska skalan har ersatts av en linjär skala eftersom dataintervallet innehåller värdet noll.","tr-TR":"Veri aralığı sıfır değerini içerdiğinden, logaritmik ölçek yerine doğrusal ölçek kullanıldı.","zh-CN":"对数刻度已替换为线性刻度,因为该数据范围包括零。","zh-TW":"對數刻度已遭線性刻度取代,因為資料範圍包含零。"}},Object_Disclaimer_LimitedData:{id:"Object.Disclaimer.LimitedData",locale:{"de-DE":"Zurzeit wird nur ein beschränkter Datensatz angezeigt.","en-US":"Currently showing a limited data set.","es-ES":"Mostrando actualmente un conjunto limitado de datos.","fr-FR":"Affichage d'un ensemble de données limité pour l'instant.","it-IT":"Attualmente viene visualizzata una serie di dati limitata.","ja-JP":"現在、限定的なデータ セットを表示しています。","ko-KR":"현재 제한된 데이터 집합을 표시하고 있습니다.","nl-NL":"Momenteel wordt een beperkte gegevensverzameling getoond.","pl-PL":"Aktualnie przedstawiany jest ograniczony zestaw danych.","pt-BR":"Mostrando um conjunto de dados limitado.","ru-RU":"В настоящее время отображается ограниченный набор данных.","sv-SE":"Just nu visas en begränsad datauppsättning.","tr-TR":"Şu anda sınırlı bir veri kümesi gösteriliyor.","zh-CN":"当前正显示有限的数据集。","zh-TW":"目前顯示的是有限的資料集。"}},Object_Disclaimer_NegativeOrZeroValues:{id:"Object.Disclaimer.NegativeOrZeroValues",locale:{"de-DE":"Die in den Datensätzen enthaltenen negativen oder 0-Werte können nicht in diesem Diagramm dargestellt werden.","en-US":"The data set contains negative or zero values that cannot be shown in this chart.","es-ES":"El conjunto de datos contiene valores cero o negativos que no se pueden mostrar en este gráfico.","fr-FR":"L'ensemble de données contient des valeurs négatives ou égales à zéro impossibles à afficher dans ce graphique.","it-IT":"La serie di dati contiene valori negativi o uguali a zero che non possono essere visualizzati in questo grafico.","ja-JP":"データ セットには、本チャートに表示できない負の値またはゼロ値が含まれています。","ko-KR":"데이터 집합에 해당 차트에 표시할 수 없는 음수 값 또는 zero 값이 포함되어 있습니다.","nl-NL":"De gegevensverzameling bevat negatieve waarden of nulwaarden die niet kunnen worden weergegeven in deze diagram.","pl-PL":"Zestaw danych zawiera wartości ujemne lub zerowe, których nie można przedstawić w tym wykresie.","pt-BR":"O conjunto de dados contém valores negativos ou iguais a zero que não podem ser mostrados neste gráfico.","ru-RU":"Набор данных содержит отрицательные или нулевые значения, которые невозможно показать в этой диаграмме.","sv-SE":"Datauppsättningen innehåller negativa värden eller nollvärden som inte kan visas i detta diagram.","tr-TR":"Veri kümesi, bu grafikte gösterilemeyen negatif veya sıfır değerlerini içeriyor.","zh-CN":"数据集中包含无法在此图表中显示的负值或零值。","zh-TW":"資料集包含無法在此圖表中顯示的負值或零值。"}},Object_Disclaimer_NegativeValues:{id:"Object.Disclaimer.NegativeValues",locale:{"de-DE":"Die in den Datensätzen enthaltenen negativen Werte können nicht in diesem Diagramm dargestellt werden.","en-US":"The data set contains negative values that cannot be shown in this chart.","es-ES":"El conjunto de datos contiene valores negativos que no se pueden mostrar en este gráfico.","fr-FR":"Le jeu de données contient des valeurs négatives impossibles à afficher dans ce graphique.","it-IT":"Il set di dati contiene valori negativi che non possono essere visualizzati in questo grafico.","ja-JP":"このチャートには表示できない負の値がデータ セットに含まれています。","ko-KR":"데이터 집합에 해당 차트에 표시할 수 없는 음수 값이 포함되어 있습니다.","nl-NL":"De gegevensverzameling bevat negatieve waarden die niet kunnen worden weergegeven in dit diagram.","pl-PL":"Zestaw danych zawiera wartości ujemne, których nie można przedstawić na tym wykresie.","pt-BR":"O conjunto de dados contém valores negativos que não podem ser mostrados neste gráfico.","ru-RU":"Набор данных содержит отрицательные значения, которые нельзя отобразить на этой диаграмме.","sv-SE":"Datauppsättningen innehåller negativa värden som inte kan visas i det här diagrammet.","tr-TR":"Veri kümesi, bu grafikte gösterilemeyen negatif değerleri içeriyor.","zh-CN":"数据集包含无法在此图表中显示的负值。","zh-TW":"資料集包含無法在此圖表中顯示的負值。"}},Object_Disclaimer_NoDataExist:{id:"Object.Disclaimer.NoDataExist",locale:{"de-DE":"Die Auswahlen haben für dieses Diagramm keine Daten generiert.","en-US":"The selections generated no data for this chart.","es-ES":"Las selecciones no han generado datos para este gráfico.","fr-FR":"Les sélections n'ont pas généré de données pour ce graphique.","it-IT":"Le selezioni non hanno generato dati per questo grafico.","ja-JP":"このチャートには選択からデータが生成されませんでした。","ko-KR":"선택 내용으로 이 차트에 대한 데이터가 생성되지 않았습니다.","nl-NL":"De selecties hebben geen gegevens voor de diagram gegenereerd.","pl-PL":"Wymiary nie spowodowały wygenerowania danych dla tego wykresu.","pt-BR":"As seleções não geraram dados para este gráfico.","ru-RU":"В результате выборок данные для этой диаграммы не созданы.","sv-SE":"Urvalen genererade inga data för detta diagram.","tr-TR":"Seçimler bu grafik için hiç veri oluşturmadı.","zh-CN":"选择未生成此图表的数据。","zh-TW":"此選項無法產生任何適用於此圖表的資料。"}},Object_Disclaimer_OnlyNanColor:{id:"Object.Disclaimer.OnlyNanColor",locale:{"de-DE":"Die verwendeten Daten für die Farbgebung dieser Visualisierung enthalten undefinierte Werte.","en-US":"The data used to color this visualization only contains undefined values.","es-ES":"Los datos utilizados para colorear esta visualización solo contienen valores indefinidos.","fr-FR":"Les données utilisées pour colorer cette visualisation ne comportent que des valeurs non définies.","it-IT":"I dati utilizzati per colorare questa visualizzazione contengono solo valori non definiti.","ja-JP":"このビジュアライゼーションの色の割り当てに使用したデータには、未定義の値が含まれています。","ko-KR":"이 시각화에 색을 지정하는 데 사용된 데이터에는 정의되지 않은 값만 포함되어 있습니다.","nl-NL":"De gegevens die worden gebruikt om deze visualisatie kleur te geven bevatten uitsluitend ongedefinieerde waarden.","pl-PL":"Dane używane do kolorowania tej wizualizacji zawierają wyłącznie niezdefiniowane wartości.","pt-BR":"Os dados usados para colorir esse visualização contém somente valores indefinidos.","ru-RU":"Данные, используемые для выбора цвета визуализации, содержат только неопределенные значения.","sv-SE":"Data som används för att färgsätta denna visualisering innehåller enbart odefinierade värden.","tr-TR":"Bu görselleştirmeyi renklendirmek için kullanılan veriler yalnızca tanımlanmamış değerler içeriyor.","zh-CN":"用于将该可视化着色的数据仅包含未定义的值。","zh-TW":"用以定義此視覺化的色彩的資料只包含未定義的值。"}},Object_Disclaimer_OnlyNanData:{id:"Object.Disclaimer.OnlyNanData",locale:{"de-DE":"Das Diagramm wird nicht angezeigt, da es nur nicht definierte Werte enthält.","en-US":"The chart is not displayed because it contains only undefined values.","es-ES":"El gráfico no se muestra porque solo contiene valores indefinidos.","fr-FR":"Le graphique n'est pas affiché, car il contient uniquement des valeurs non définies.","it-IT":"Il grafico non è visualizzato poiché contiene solo valori non definiti.","ja-JP":"未定義の値しか含まれていないため、チャートは表示されていません。","ko-KR":"정의되지 않은 값만 포함되어 있으므로 차트가 표시되지 않습니다.","nl-NL":"De diagram wordt niet weergegeven omdat deze alleen ongedefinieerde waarden bevat.","pl-PL":"Wykres nie jest wyświetlany, ponieważ zawiera wyłącznie wartości niezdefiniowane.","pt-BR":"O gráfico não foi exibido, porque contém apenas valores não definidos.","ru-RU":"Диаграмма не отображается, поскольку она содержит только неопределенные значения.","sv-SE":"Diagrammet visas inte eftersom det enbart innehåller odefinierade värden.","tr-TR":"Yalnızca tanımsız değerleri içermesi nedeniyle grafik görüntülenmiyor.","zh-CN":"未显示图表,因为它仅包含未定义的值。","zh-TW":"系統不會顯示圖表,因為該圖表僅包含未定義的值。"}},Object_Disclaimer_OnlyNegativeOrZeroValues:{id:"Object.Disclaimer.OnlyNegativeOrZeroValues",locale:{"de-DE":"Das Diagramm wird nicht angezeigt, da es nur negative oder 0-Werte enthält.","en-US":"The chart is not displayed because it contains only negative or zero values.","es-ES":"El gráfico no se muestra porque solo contiene valores negativos o valores cero.","fr-FR":"Le graphique n'est pas affiché, car il contient uniquement des valeurs négatives ou égales à zéro.","it-IT":"Il grafico non viene visualizzato poiché contiene solo valori negativi o uguali a zero.","ja-JP":"チャートは負の値またはゼロ値しか含まれていないため、表示されていません。","ko-KR":"음수 또는 zero 값만 포함되어 있으므로 차트가 표시되지 않습니다.","nl-NL":"De diagram wordt niet weergegeven omdat deze alleen negatieve waarden of nulwaarden bevat.","pl-PL":"Wykres nie jest wyświetlany, ponieważ zawiera wyłącznie wartości ujemne lub zerowe.","pt-BR":"O gráfico não foi exibido, porque contém apenas valores negativos ou zero.","ru-RU":"Диаграмма не отображается, поскольку она содержит только отрицательные или нулевые значения.","sv-SE":"Diagrammet visas inte eftersom det enbart innehåller negativa värden eller nollvärden","tr-TR":"Yalnızca negatif veya sıfır değerlerini içermesi nedeniyle grafik görüntülenmiyor.","zh-CN":"未显示图表,因为它仅包含负值或零值。","zh-TW":"系統不會顯示圖表,因為該圖表僅包含負值或零值。"}},Object_Disclaimer_OnlyNegativeValues:{id:"Object.Disclaimer.OnlyNegativeValues",locale:{"de-DE":"Das Diagramm wird nicht angezeigt, da es nur negative oder Werte enthält.","en-US":"The chart is not displayed because it contains only negative values.","es-ES":"El gráfico no se muestra porque solo contiene valores negativos.","fr-FR":"Le graphique n'est pas affiché, car il contient uniquement des valeurs négatives.","it-IT":"Il grafico non viene visualizzato poiché contiene solo valori negativi.","ja-JP":"負の値しか含まれていないため、チャートは表示されていません。","ko-KR":"음수 값만 포함되어 있으므로 차트가 표시되지 않습니다.","nl-NL":"Het diagram wordt niet weergegeven omdat deze alleen negatieve waarden bevat.","pl-PL":"Wykres nie jest wyświetlany, ponieważ zawiera wyłącznie wartości ujemne.","pt-BR":"O gráfico não é exibido porque contém apenas valores negativos.","ru-RU":"Диаграмма не отображается, поскольку она содержит только отрицательные значения.","sv-SE":"Diagrammet visas inte eftersom det endast innehåller negativa värden.","tr-TR":"Yalnızca negatif değerleri içermesi nedeniyle grafik görüntülenmiyor.","zh-CN":"未显示图表,因为它仅包含负值。","zh-TW":"系統不會顯示圖表,因為該圖表僅包含負值。"}},Object_ErrorMessage_MissingDimension:{id:"Object.ErrorMessage.MissingDimension",locale:{"de-DE":"Dimension nicht gefunden","en-US":"Dimension not found","es-ES":"No se ha encontrado la dimensión","fr-FR":"Dimension introuvable","it-IT":"Dimensione non trovata","ja-JP":"軸が見つかりません","ko-KR":"차원을 찾지 못했습니다.","nl-NL":"Dimensie niet gevonden","pl-PL":"Wymiar nie został znaleziony","pt-BR":"Dimensão não encontrada","ru-RU":"Измерение не найдено","sv-SE":"Dimensionen hittades inte","tr-TR":"Boyut bulunamadı","zh-CN":"未找到维度","zh-TW":"找不到維度"}},Object_ErrorMessage_MissingMeasure:{id:"Object.ErrorMessage.MissingMeasure",locale:{"de-DE":"Kennzahl nicht gefunden","en-US":"Measure not found","es-ES":"No se ha encontrado la medida","fr-FR":"Mesure introuvable","it-IT":"Misura non trovata","ja-JP":"メジャーが見つかりません","ko-KR":"측정값을 찾지 못했습니다.","nl-NL":"Meting niet gevonden","pl-PL":"Miara nie została znaleziona","pt-BR":"Medida não encontrada","ru-RU":"Мера не найдена","sv-SE":"Måttet hittades inte","tr-TR":"Hesaplama bulunamadı","zh-CN":"未找到度量","zh-TW":"找不到量值"}},Tooltip_ToggleOffLassoSelection:{id:"Tooltip.ToggleOffLassoSelection",locale:{"de-DE":"Lasso-Auswahl deaktivieren","en-US":"Turn off lasso selection","es-ES":"Desactivar la selección de contorno","fr-FR":"Désactiver la sélection au lasso","it-IT":"Disattiva selezione lazo","ja-JP":"囲み選択をオフにする","ko-KR":"올가미 선택 끄기","nl-NL":"Lassoselectie uitschakelen","pl-PL":"Wyłącz zaznaczenie lasso","pt-BR":"Desativar seleção de laço","ru-RU":"Выключить выбор лассо","sv-SE":"Stäng av lassourval","tr-TR":"Serbest seçimi kapat","zh-CN":"关闭套索选择方法","zh-TW":"關閉套索選取"}},Tooltip_ToggleOnLassoSelection:{id:"Tooltip.ToggleOnLassoSelection",locale:{"de-DE":"Lasso-Auswahl aktivieren","en-US":"Turn on lasso selection","es-ES":"Activar la selección de contorno","fr-FR":"Activer la sélection au lasso","it-IT":"Attiva selezione lazo","ja-JP":"囲み選択をオンにする","ko-KR":"올가미 선택 켜기","nl-NL":"Lassoselectie inschakelen","pl-PL":"Włącz zaznaczenie lasso","pt-BR":"Ativar seleção de laço","ru-RU":"Включить выбор лассо","sv-SE":"Slå på lassourval","tr-TR":"Serbest seçimi aç","zh-CN":"开启套索选择方法","zh-TW":"開啟套索選取"}},Tooltip_dimensions_cyclic:{id:"Tooltip.dimensions.cyclic",locale:{"de-DE":"Zyklische Dimension","en-US":"Cyclic dimension","es-ES":"Dimensión cíclica","fr-FR":"Dimension cyclique","it-IT":"Dimensione ciclica","ja-JP":"サイクリック軸","ko-KR":"순환 차원","nl-NL":"Cyclische dimensie","pl-PL":"Wymiar cykliczny","pt-BR":"Dimensão cíclica","ru-RU":"Циклическое измерение","sv-SE":"Cyklisk dimension","tr-TR":"Döngüsel boyut","zh-CN":"循环维度","zh-TW":"循環維度"}},Tooltip_dimensions_drilldown:{id:"Tooltip.dimensions.drilldown",locale:{"de-DE":"Drilldown-Dimension","en-US":"Drill-down dimension","es-ES":"Dimensión jerárquica","fr-FR":"Descendre dans la hiérarchie de la dimension","it-IT":"Dimensione di drill-down","ja-JP":"軸のドリルダウン","ko-KR":"드릴다운 차원","nl-NL":"Drill-downdimensie","pl-PL":"Wymiar hierarchiczny","pt-BR":"Dimensão da hierarquia","ru-RU":"Детализированное измерение","sv-SE":"Hierarkisk dimension","tr-TR":"Detaya inme boyutu","zh-CN":"下钻维度","zh-TW":"向下探查維度"}},Tooltip_selections_locked:{id:"Tooltip.selections.locked",locale:{"de-DE":"Auswahlen sind für diese Dimension gesperrt","en-US":"Selections on this dimension are locked","es-ES":"Las selecciones de esta dimensión están bloqueadas.","fr-FR":"Sélections verrouillées pour cette dimension","it-IT":"Le selezioni in questa dimensione sono bloccate","ja-JP":"この軸での選択はロックされています","ko-KR":"이 차원의 선택은 잠겨 있습니다.","nl-NL":"Selecties voor deze dimensie zijn vergrendeld","pl-PL":"Wybory dotyczące tego wymiaru są zablokowane","pt-BR":"Seleções estão bloqueadas nesta dimensão","ru-RU":"Выборки для данного измерения заблокированы","sv-SE":"Urval i den här dimensionen är låsta","tr-TR":"Bu boyuttaki seçimler kilitli","zh-CN":"相关维度的选择已锁定","zh-TW":"已鎖定此維度上的選項"}},Visualizations_Descriptions_Bars:{id:"Visualizations.Descriptions.Bars",locale:{"de-DE":"Balken","en-US":"Bars","es-ES":"Barras","fr-FR":"Barres","it-IT":"Barre","ja-JP":"棒","ko-KR":"막대","nl-NL":"Staven","pl-PL":"Słupki","pt-BR":"Barras","ru-RU":"Полосы","sv-SE":"Staplar","tr-TR":"Çubuklar","zh-CN":"条形","zh-TW":"長條"}},Visualizations_Descriptions_Group:{id:"Visualizations.Descriptions.Group",locale:{"de-DE":"Gruppe","en-US":"Group","es-ES":"Grupo","fr-FR":"Groupe","it-IT":"Gruppo","ja-JP":"グループ","ko-KR":"그룹","nl-NL":"Groep","pl-PL":"Grupa","pt-BR":"Grupo","ru-RU":"Группа","sv-SE":"Grupp","tr-TR":"Grup","zh-CN":"组","zh-TW":"群組"}},Visualizations_Descriptions_HeightLine:{id:"Visualizations.Descriptions.HeightLine",locale:{"de-DE":"Linienhöhe","en-US":"Height of line","es-ES":"Altura de línea","fr-FR":"Hauteur de ligne","it-IT":"Altezza della linea","ja-JP":"線の高さ","ko-KR":"선 높이","nl-NL":"Hoogte van lijn","pl-PL":"Wysokość linii","pt-BR":"Altura da linha","ru-RU":"Высота линии","sv-SE":"Linjens höjd","tr-TR":"Çizgi yüksekliği","zh-CN":"线高度","zh-TW":"折線高度"}},Visualizations_Descriptions_LengthBars:{id:"Visualizations.Descriptions.LengthBars",locale:{"de-DE":"Balkenlänge","en-US":"Length of bars","es-ES":"Longitud de barras","fr-FR":"Longueur des barres","it-IT":"Lunghezza delle barre","ja-JP":"棒の長さ","ko-KR":"막대 길이","nl-NL":"Lengte van staven","pl-PL":"Długość słupków","pt-BR":"Comprimento das barras","ru-RU":"Длина полос","sv-SE":"Staplarnas längd","tr-TR":"Çubuk uzunluğu","zh-CN":"条形长度","zh-TW":"長條長度"}},properties_dataPoints_labelmode_share:{id:"properties.dataPoints.labelmode.share",locale:{"de-DE":"Freigeben","en-US":"Share","es-ES":"Compartir","fr-FR":"Partage","it-IT":"Condividi","ja-JP":"共有","ko-KR":"공유","nl-NL":"Delen","pl-PL":"Udostępnij","pt-BR":"Compartilhar","ru-RU":"Совместное использование","sv-SE":"Dela","tr-TR":"Paylaş","zh-CN":"共享","zh-TW":"共用"}},properties_trendlines_types_average:{id:"properties.trendlines.types.average",locale:{"de-DE":"Durchschnitt","en-US":"Average","es-ES":"Media","fr-FR":"Moyenne","it-IT":"Media","ja-JP":"平均値","ko-KR":"평균","nl-NL":"Gemiddelde","pl-PL":"Średnia","pt-BR":"Média","ru-RU":"Среднее","sv-SE":"Medel","tr-TR":"Ortalama","zh-CN":"平均值","zh-TW":"平均值"}},properties_trendlines_types_exponential:{id:"properties.trendlines.types.exponential",locale:{"de-DE":"Exponentiell","en-US":"Exponential","es-ES":"Exponencial","fr-FR":"Exponentiel","it-IT":"Esponenziale","ja-JP":"指数","ko-KR":"지수","nl-NL":"Exponentieel","pl-PL":"Wykładnicze","pt-BR":"Exponencial","ru-RU":"Экспоненциальный","sv-SE":"Exponentiell","tr-TR":"Üstel","zh-CN":"指数","zh-TW":"指數"}},properties_trendlines_types_linear:{id:"properties.trendlines.types.linear",locale:{"de-DE":"Linear","en-US":"Linear","es-ES":"Lineal","fr-FR":"Linéaire","it-IT":"Lineare","ja-JP":"線形","ko-KR":"선형","nl-NL":"Lineair","pl-PL":"Liniowe","pt-BR":"Linear","ru-RU":"Линейный","sv-SE":"Linjär","tr-TR":"Doğrusal","zh-CN":"线性","zh-TW":"線性"}},properties_trendlines_types_logarithmic:{id:"properties.trendlines.types.logarithmic",locale:{"de-DE":"Logarithmisch","en-US":"Logarithmic","es-ES":"Logarítmica","fr-FR":"Logarithmique","it-IT":"Logaritmica","ja-JP":"対数","ko-KR":"로그","nl-NL":"Logaritmisch","pl-PL":"Logarytmiczne","pt-BR":"Logarítmico","ru-RU":"Логарифмический","sv-SE":"Logaritmisk","tr-TR":"Logaritmik","zh-CN":"对数","zh-TW":"對數"}},properties_trendlines_types_polynomial2:{id:"properties.trendlines.types.polynomial2",locale:{"de-DE":"Polynom zweiten Grades","en-US":"Second degree polynomial","es-ES":"Polinómica de segundo grado","fr-FR":"Polynomial du 2ème degré","it-IT":"Polinomio di secondo grado","ja-JP":"2 番目の角度の多項式近似","ko-KR":"2차 다항식","nl-NL":"Tweedegraadspolynoom","pl-PL":"Wielomianowe drugiego stopnia","pt-BR":"Polinômio de segundo grau","ru-RU":"Полиномиальный второй степени","sv-SE":"Polynomial, andra graden","tr-TR":"İkinci derece polinom","zh-CN":"二次多项式","zh-TW":"第二度多項式"}},properties_trendlines_types_polynomial3:{id:"properties.trendlines.types.polynomial3",locale:{"de-DE":"Polynom dritten Grades","en-US":"Third degree polynomial","es-ES":"Polinómica de tercer grado","fr-FR":"Polynomial du 3ème degré","it-IT":"Polinomio di terzo grado","ja-JP":"3 番目の角度の多項式近似","ko-KR":"3차 다항식","nl-NL":"Derdegraadspolynoom","pl-PL":"Wielomianowe trzeciego stopnia","pt-BR":"Polinômio de terceiro grau","ru-RU":"Полиномиальный третьей степени","sv-SE":"Polynomial, tredje graden","tr-TR":"Üçüncü derece polinom","zh-CN":"三次多项式","zh-TW":"第三度多項式"}},properties_trendlines_types_polynomial4:{id:"properties.trendlines.types.polynomial4",locale:{"de-DE":"Polynom vierten Grades","en-US":"Fourth degree polynomial","es-ES":"Polinómica de cuarto grado","fr-FR":"Polynomial du 4ème degré","it-IT":"Polinomio di quarto grado","ja-JP":"4 番目の角度の多項式近似","ko-KR":"4차 다항식","nl-NL":"Vierdegraadspolynoom","pl-PL":"Wielomianowe czwartego stopnia","pt-BR":"Polinômio de quarto grau","ru-RU":"Полиномиальный четвертой степени","sv-SE":"Polynomial, fjärde graden","tr-TR":"Dördüncü derece polinom","zh-CN":"四次多项式","zh-TW":"第四度多項式"}},properties_trendlines_types_power:{id:"properties.trendlines.types.power",locale:{"de-DE":"Potenz","en-US":"Power","es-ES":"Potencia","fr-FR":"Puissance","it-IT":"Potenza","ja-JP":"累乗","ko-KR":"거듭제곱","nl-NL":"Macht","pl-PL":"Potęgowe","pt-BR":"Potência","ru-RU":"Степенной","sv-SE":"Potens","tr-TR":"Üs","zh-CN":"幂","zh-TW":"乘冪"}}};const b={fill:"steelblue",num:1},x=.9,w=150,q=(e,t,n)=>{let r=0,i=0,o=0,a={},l=0;if("labelCenter"===e)r=t.bottomLeft.x,i=t.topRight.y,o=t.bottomRight.x-t.bottomLeft.x,l=t.bottomRight.y-t.topRight.y,a={share:n.share,fill:n.fill};else{const e=180/Math.PI*Math.atan((t.bottomRight.y-t.topRight.y)/(t.topRight.x-t.bottomRight.x));r=e<15&&e>=0?t.topRight.x:e>-15&&e<0?t.bottomRight.x:e<-15?(t.bottomRight.x-t.topRight.x)/2+t.topRight.x+15:(t.topRight.x-t.bottomRight.x)/2+t.bottomRight.x+15,i=t.topRight.y,o=t.width-r,l=t.bottomRight.y-t.topRight.y,a={fill:n.fill}}return{tag:e,type:"rect",x:r,y:i,width:o,height:l,data:n.data,desc:a,fill:"none"}},D=(e,t)=>{const n=(e=>{const t=(e=>{let t=0;return e.forEach(e=>{e.num>t&&(t=e.num)}),t})(e);let n=0;return e.slice().reverse().map(e=>{const r={datum:e,s:n/t,e:e.num/t};return n=e.num,r}).reverse()})(e),r=t.width*x,i=t.height*x,o=(t.width-r)/2,a=(t.height-i)/2,l=r-(r>w&&i>w?100:0),s=(i-1*(n.length-1))/n.length,u=[];return n.forEach((e,r)=>{const i=(c=e.e,d=r<n.length-1?e.s:e.e,[.5-.5*c,.5+.5*c,.5+.5*d,.5-.5*d]).map(e=>Math.round(e*l+o));var c,d;const f=s*r+1*r+a,p={bottomRight:{x:i[2],y:Math.round(f+s)},bottomLeft:{x:i[3],y:Math.round(f+s)},topRight:{x:i[1],y:Math.round(f)},topLeft:{x:i[0],y:Math.round(f)},width:t.width},h=`M${p.topLeft.x},${p.topLeft.y} L${p.topRight.x},${p.topRight.y} ${p.bottomRight.x},${p.bottomRight.y} ${p.bottomLeft.x},${p.bottomLeft.y}Z`;u.push({tag:"section",type:"path",d:h,data:e.datum.data,fill:e.datum.fill});const m={share:e.e,fill:e.datum.fill,data:e.datum.data};s>12&&(p.bottomRight.x-p.bottomLeft.x>32&&u.push(q("labelCenter",p,m)),u.push(q("labelLeft",p,m)))}),u},S=(e,t,n,r)=>(r-e)/r*(t-n)+n,k=(e,t,n)=>{const r=e.filter(e=>"NaN"!==e.num&&e.num>0),i=r.length,o=n.width*x,a=n.height*x,l=Math.round((n.width-o)/2),s=Math.round((n.height-a)/2),u=o-(o>w&&a>w?100:0),c=a-1*(i-1),d=[],f=r[0].data.num.value;let p=s;return r.forEach((e,r)=>{const i=t[r]*c,o=Math.round(S(p-s,u,.2*u,a)/2),h=Math.round(S(p-s+i,u,.2*u,a)/2),m=l+Math.round(u/2),g={bottomRight:{x:m+h,y:Math.round(p+i)},bottomLeft:{x:m-h,y:Math.round(p+i)},topRight:{x:m+o,y:p},topLeft:{x:m-o,y:p},width:n.width},v=`M${g.topLeft.x},${g.topLeft.y} L${g.topRight.x},${g.topRight.y} ${g.bottomRight.x},${g.bottomRight.y} ${g.bottomLeft.x},${g.bottomLeft.y}Z`;d.push({tag:"section",type:"path",d:v,data:e.data,fill:e.fill});const y={share:e.data.num.value/f,fill:e.fill,data:e.data};i>2&&(g.bottomRight.x-g.bottomLeft.x>32&&d.push(q("labelCenter",g,y)),d.push(q("labelLeft",g,y))),p+=i+1}),d},C=(e,t,n)=>{const r=e.filter(e=>"NaN"!==e.num&&e.num>0);if(r&&r.length>0)switch(t){case"WIDTH":default:return D(r,n);case"ORDER":return k(r,r.map(()=>1/r.length),n);case"HEIGHT":return k(r,(e=>{const t=e.reduce((e,t)=>e+t.data.num.value,0);return e.map(e=>e.data.num.value/t)})(r),n);case"AREA":return k(r,((e,t,n)=>{const r=e.reduce((e,t)=>e+t.data.num.value,0),i=t.width*x,o=t.height*x,a=i*n,l=o*(i+a)/2,s=(i-a)/2/o,u=[];let c=0;for(let t=e.length-1;t>=0;t--){const n=e[t].data.num.value/r,i=2*s*c+a,d=-i/(2*s)+Math.sqrt(i*i/(4*s*s)+n*l/s);u[t]=d/o,c+=d}return u})(r,n,.2),n)}return[]};var M={require:["resolver"],defaultSettings:{settings:{},data:{},style:{item:"$shape"}},render({data:e}){const t=this.resolver.resolve({data:e,defaults:{...b,...this.style.item},settings:this.settings.settings});return C(t.items,this.settings.settings.mode,this.rect)}};const I={version:"1.13.0",color:{auto:!0,autoMinMax:!0,byDimDef:void 0,byMeasureDef:void 0,colorExpression:void 0,dimensionScheme:"12",expressionIsColor:!0,expressionLabel:"",measureMin:void 0,measureMax:void 0,measureScheme:"sg",mode:"primary",paletteColor:{index:6},persistent:!1,reverseScheme:!1,singleColor:void 0,useBaseColors:"off",useDimColVal:!0,useMeasureGradient:!0},dataPoint:{auto:!0,labelMode:"share"},footnote:"",funnel:{mode:"WIDTH"},qHyperCubeDef:{qDimensions:[],qMeasures:[],qInterColumnSortOrder:[],qInitialDataFetch:[{qWidth:2,qHeight:5e3}],qSuppressMissing:!0,qSuppressZero:!1},showDimensionTitle:!0,showTitles:!0,subtitle:"",title:""};function N(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function E(e,t,n,r,i,o,a){try{var l=e[o](a),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(r,i)}function O(e){return function(){var t=this,n=arguments;return new Promise(function(r,i){var o=e.apply(t,n);function a(e){E(o,r,i,a,l,"next",e)}function l(e){E(o,r,i,a,l,"throw",e)}a(void 0)})}}function R(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function T(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function z(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?T(Object(n),!0).forEach(function(t){R(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):T(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function L(e,t){if(null==e)return{};var n,r,i=function(e,t){if(null==e)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;n[r]=e[r]}return n}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],-1===t.indexOf(n)&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function P(){
|
|
8
8
|
/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */
|
|
9
|
-
var e,t,n="function"==typeof Symbol?Symbol:{},r=n.iterator||"@@iterator",i=n.toStringTag||"@@toStringTag";function o(n,r,i,o){var s=r&&r.prototype instanceof l?r:l,u=Object.create(s.prototype);return j(u,"_invoke",function(n,r,i){var o,l,s,u=0,c=i||[],d=!1,f={p:0,n:0,v:e,a:p,f:p.bind(e,4),d:function(t,n){return o=t,l=0,s=e,f.n=n,a}};function p(n,r){for(l=n,s=r,t=0;!d&&u&&!i&&t<c.length;t++){var i,o=c[t],p=f.p,h=o[2];n>3?(i=h===r)&&(s=o[(l=o[4])?5:(l=3,3)],o[4]=o[5]=e):o[0]<=p&&((i=n<2&&p<o[1])?(l=0,f.v=r,f.n=o[1]):p<h&&(i=n<3||o[0]>r||r>h)&&(o[4]=n,o[5]=r,f.n=h,l=0))}if(i||n>1)return a;throw d=!0,r}return function(i,c,h){if(u>1)throw TypeError("Generator is already running");for(d&&1===c&&p(c,h),l=c,s=h;(t=l<2?e:s)||!d;){o||(l?l<3?(l>1&&(f.n=-1),p(l,s)):f.n=s:f.v=s);try{if(u=2,o){if(l||(i="next"),t=o[i]){if(!(t=t.call(o,s)))throw TypeError("iterator result is not an object");if(!t.done)return t;s=t.value,l<2&&(l=0)}else 1===l&&(t=o.return)&&t.call(o),l<2&&(s=TypeError("The iterator does not provide a '"+i+"' method"),l=1);o=e}else if((t=(d=f.n<0)?s:n.call(r,f))!==a)break}catch(t){o=e,l=1,s=t}finally{u=1}}return{value:t,done:d}}}(n,i,o),!0),u}var a={};function l(){}function s(){}function u(){}t=Object.getPrototypeOf;var c=[][r]?t(t([][r]())):(j(t={},r,function(){return this}),t),d=u.prototype=l.prototype=Object.create(c);function f(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,u):(e.__proto__=u,j(e,i,"GeneratorFunction")),e.prototype=Object.create(d),e}return s.prototype=u,j(d,"constructor",u),j(u,"constructor",s),s.displayName="GeneratorFunction",j(u,i,"GeneratorFunction"),j(d),j(d,i,"Generator"),j(d,r,function(){return this}),j(d,"toString",function(){return"[object Generator]"}),(P=function(){return{w:o,m:f}})()}function j(e,t,n,r){var i=Object.defineProperty;try{i({},"",{})}catch(e){i=0}j=function(e,t,n,r){function o(t,n){j(e,t,function(e){return this._invoke(t,n,e)})}t?i?i(e,t,{value:n,enumerable:!r,configurable:!r,writable:!r}):e[t]=n:(o("next",0),o("throw",1),o("return",2))},j(e,t,n,r)}function A(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,o,a,l=[],s=!0,u=!1;try{if(o=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=o.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){u=!0,i=e}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw i}}return l}}(e,t)||$(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function F(e){return function(e){if(Array.isArray(e))return N(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||$(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function _(e){return _="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_(e)}function $(e,t){if(e){if("string"==typeof e)return N(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?N(e,t):void 0}}var H,B="top",U="top-right",V="right",W="bottom-right",K="bottom",J="bottom-left",Y="left",G="top-left";R(R(R(R(R(R(R(R(R(R(H={},"equal-equal",[B,K]),"equal-higher",[K,W]),"equal-lower",[B,U]),"equal-void",[B,K]),"higher-equal",[Y,J,B,U]),"higher-higher-acute",[K,J,Y,U]),"higher-higher-obtuse",[K,B]),"higher-lower-negative",[B,U,V]),"higher-lower-positive",[K,J,Y]),"higher-void",[B]),R(R(R(R(R(R(R(R(R(R(H,"lower-equal",[B]),"lower-higher-negative",[B,G]),"lower-higher-positive",[W]),"lower-lower-acute",[B,G,Y,U,V]),"lower-lower-obtuse",[B,K]),"lower-void",[B]),"void-equal",[B]),"void-higher",[B,K]),"void-lower",[B,K,Y]),"void-void",[B]),R(H,"unclassified",[B,K,V,Y,U,W,J,G]);var Z=["American Typewriter, serif","Andalé Mono, monospace","Arial Black, sans-serif","Arial, sans-serif","Bradley Hand, cursive","Brush Script MT, cursive","Comic Sans MS, cursive","Courier, monospace","Didot, serif","Georgia, serif","Impact, sans-serif","Lucida Console, monospace","Luminari, fantasy","Monaco, monospace","QlikView Sans, sans-serif","Source Sans Pro, sans-serif","Tahoma, sans-serif","Times New Roman, serif","Trebuchet MS, sans-serif","Verdana, sans-serif"],X=["Abril Fatface, serif","Bangers, fantasy","Bebas Neue, sans serif","EB Garamond, serif","Fredoka One, fantasy","Graduate, fantasy","Gravitas One, serif","Indie Flower, fantasy","Inter, sans-serif","Lobster, fantasy","Montserrat, sans-serif","Nixie One, sans-serif","Noto Sans, sans-serif","Open Sans, sans-serif","PT Serif, serif","Pacifico, cursive","Permanent Marker, fantasy","QlikView Sans, sans-serif","Raleway, sans-serif","Rammetto One, fantasy","Roboto, sans-serif","Source Sans Pro, sans-serif","Titan One, fantasy","Yanone Kaffeesatz, sans-serif"];var Q=function(e){return{value:e,label:e.charAt(0).toUpperCase()+e.slice(1),groupHeader:!1,disabled:!1,styles:{fontFamily:e}}};function ee(e){var t=e.theme,n=e.translator,r=e.defaultValue,i=e.flags,o=[],a=t.getStyle("","","fontFamilies");return Array.isArray(a)&&a.length?o.push.apply(o,F(new Set([r].concat(F(a.map(function(e){return e.split(",").map(function(e){return e.trim()}).map(function(e){return e.replace(/\s+/g," ").trim()}).filter(Boolean).join(", ")})))))):o.push(r),[{value:"ThemeHeader",label:n.get("properties.themeFonts"),metaText:n.get("properties.theme"),groupHeader:!0}].concat(F(o.map(function(e){return Q(e)})),[{value:"DefaultHeader",label:n.get("properties.allFonts"),metaText:n.get("properties.default"),groupHeader:!0}],F(function(e){return null!=e&&e.isEnabled("PS_20852_WYSIWYG_FONT_SUPPORT")?X:Z}(i).map(function(e){return Q(e)})))}function te(e){var t=e.theme,n=e.translator,r=e.id,i=e.path,o=e.flags,a=function(){return t.getStyle(r,i,"fontFamily")};return{getDefaultValue:function(){return a()},getOptions:function(){return ee({theme:t,translator:n,defaultValue:a(),flags:o})}}}var ne=["10px","11px","12px","13px","14px","15px","16px","17px","18px","19px","20px","21px","22px","23px","24px"],re=function(e){return{value:e,label:e,groupHeader:!1,disabled:!1}};function ie(e){var t=e.theme,n=e.translator,r=e.id,i=e.path,o=function(){return t.getStyle(r,i,"fontSize")};return{getDefaultValue:function(){return o()},getOptions:function(){return function(e){var t=e.translator,n=e.defaultValue,r=[],i=e.theme.getStyle("","","fontSizes");return Array.isArray(i)&&i.length?r.push.apply(r,F(new Set([n].concat(F(i))))):r.push(n),[{value:"ThemeHeader",label:t.get("properties.themeFontSizes"),metaText:t.get("properties.theme"),groupHeader:!0}].concat(F(r.map(function(e){return re(e)})),[{value:"DefaultHeader",label:t.get("properties.allFontSizes"),metaText:t.get("properties.default"),groupHeader:!0}],F(ne.map(function(e){return re(e)})))}({theme:t,translator:n,defaultValue:o()})}}}function oe(e){var t=e.theme,n=e.translator,r=e.id,i=e.path;return{fontFamily:te({theme:t,translator:n,id:r,path:i,flags:e.flags}),fontSize:ie({theme:t,translator:n,id:r,path:i})}}var ae,le,se=["__proto__","constructor"],ue=function(e){if(se.some(function(t){return e.includes(t)}))throw new Error("font-resolver: Forbidden property.")};var ce,de=function(){if(le)return ae;le=1;var e=Object.prototype.hasOwnProperty,t=Object.prototype.toString,n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=function(e){return"function"==typeof Array.isArray?Array.isArray(e):"[object Array]"===t.call(e)},o=function(n){if(!n||"[object Object]"!==t.call(n))return!1;var r,i=e.call(n,"constructor"),o=n.constructor&&n.constructor.prototype&&e.call(n.constructor.prototype,"isPrototypeOf");if(n.constructor&&!i&&!o)return!1;for(r in n);return void 0===r||e.call(n,r)},a=function(e,t){n&&"__proto__"===t.name?n(e,t.name,{enumerable:!0,configurable:!0,value:t.newValue,writable:!0}):e[t.name]=t.newValue},l=function(t,n){if("__proto__"===n){if(!e.call(t,n))return;if(r)return r(t,n).value}return t[n]};return ae=function e(){var t,n,r,s,u,c,d=arguments[0],f=1,p=arguments.length,h=!1;for("boolean"==typeof d&&(h=d,d=arguments[1]||{},f=2),(null==d||"object"!=typeof d&&"function"!=typeof d)&&(d={});f<p;++f)if(null!=(t=arguments[f]))for(n in t)r=l(d,n),d!==(s=l(t,n))&&(h&&s&&(o(s)||(u=i(s)))?(u?(u=!1,c=r&&i(r)?r:[]):c=r&&o(r)?r:{},a(d,{name:n,newValue:e(h,c,s)})):void 0!==s&&a(d,{name:n,newValue:s}));return d},ae}(),fe=(ce=de)&&ce.__esModule&&Object.prototype.hasOwnProperty.call(ce,"default")?ce.default:ce;function pe(e,t){return{range:function(e){var n=e.resources,r=e.data,i=n.theme.palette("categorical",0===t?r.items.length:t);return r.items.map(function(e){return i[e.value%i.length]})},valueAccessor:e.value}}function he(e,t){return{range:function(e){var n=e.resources,r=e.data,i=n.theme.palette("categorical",0===t?r.items.length:t);return r.items.map(function(e){return i[e.row.value%i.length]})},valueAccessor:e.value}}function me(e,t,n,r,i){var o,a,l=i.byRow,s=i.byElemNo;if(r&&(t.input.persistent||e.hc.qDimensionInfo.length>1||void 0===n.activeDimensionIndex&&e.hc.qSize.qcy>((null===(a=(o=e.hc).qDataPages[0]||o.qStackedDataPages[0])||void 0===a?void 0:a.qArea.qHeight)||0)))return s(r,r.raw().qCardinal);if(r){var u=t.pic.extract({field:r.key(),trackBy:r.value}).length;return l(r,u)}return{}}function ge(e,t){var n=e.hc.qDimensionInfo,r=t.input.byDimDef||{activeDimensionIndex:n.length-1};if(r.activeDimensionIndex>=0){var i=n[r.activeDimensionIndex];r=i.coloring&&i.coloring.colorMapRef?{type:"libraryItem",key:i.coloring.colorMapRef,activeDimensionIndex:r.activeDimensionIndex}:{activeDimensionIndex:r.activeDimensionIndex}}return r}function ve(e,t){var n;return t.activeDimensionIndex>=0?n=e.pic.fields().filter(function(e){return"dimension"===e.type()})[t.activeDimensionIndex]:"libraryItem"===t.type?!1===(n=t.key?e.pic.field(function(e){return e.raw().colorMapRef===t.key}):void 0)&&(n=e.pic.field(function(e){return"colorByAlternative"===e.raw().id})):"expression"===t.type&&(n=e.pic.field(function(e){return"colorByAlternative"===e.raw().id})),n}function ye(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function be(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function xe(){}var we=1/.7,qe="\\s*([+-]?\\d+)\\s*",De="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Se="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",ke=/^#([0-9a-f]{3,8})$/,Ce=new RegExp(`^rgb\\(${qe},${qe},${qe}\\)$`),Me=new RegExp(`^rgb\\(${Se},${Se},${Se}\\)$`),Ie=new RegExp(`^rgba\\(${qe},${qe},${qe},${De}\\)$`),Ne=new RegExp(`^rgba\\(${Se},${Se},${Se},${De}\\)$`),Oe=new RegExp(`^hsl\\(${De},${Se},${Se}\\)$`),Ee=new RegExp(`^hsla\\(${De},${Se},${Se},${De}\\)$`),Re={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 Te(){return this.rgb().formatHex()}function Le(){return this.rgb().formatRgb()}function ze(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=ke.exec(e))?(n=t[1].length,t=parseInt(t[1],16),6===n?Pe(t):3===n?new _e(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===n?je(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===n?je(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=Ce.exec(e))?new _e(t[1],t[2],t[3],1):(t=Me.exec(e))?new _e(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=Ie.exec(e))?je(t[1],t[2],t[3],t[4]):(t=Ne.exec(e))?je(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=Oe.exec(e))?We(t[1],t[2]/100,t[3]/100,1):(t=Ee.exec(e))?We(t[1],t[2]/100,t[3]/100,t[4]):Re.hasOwnProperty(e)?Pe(Re[e]):"transparent"===e?new _e(NaN,NaN,NaN,0):null}function Pe(e){return new _e(e>>16&255,e>>8&255,255&e,1)}function je(e,t,n,r){return r<=0&&(e=t=n=NaN),new _e(e,t,n,r)}function Ae(e){return e instanceof xe||(e=ze(e)),e?new _e((e=e.rgb()).r,e.g,e.b,e.opacity):new _e}function Fe(e,t,n,r){return 1===arguments.length?Ae(e):new _e(e,t,n,null==r?1:r)}function _e(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}function $e(){return`#${Ve(this.r)}${Ve(this.g)}${Ve(this.b)}`}function He(){const e=Be(this.opacity);return`${1===e?"rgb(":"rgba("}${Ue(this.r)}, ${Ue(this.g)}, ${Ue(this.b)}${1===e?")":`, ${e})`}`}function Be(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Ue(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Ve(e){return((e=Ue(e))<16?"0":"")+e.toString(16)}function We(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new Je(e,t,n,r)}function Ke(e){if(e instanceof Je)return new Je(e.h,e.s,e.l,e.opacity);if(e instanceof xe||(e=ze(e)),!e)return new Je;if(e instanceof Je)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,l=o-i,s=(o+i)/2;return l?(a=t===o?(n-r)/l+6*(n<r):n===o?(r-t)/l+2:(t-n)/l+4,l/=s<.5?o+i:2-o-i,a*=60):l=s>0&&s<1?0:a,new Je(a,l,s,e.opacity)}function Je(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function Ye(e){return(e=(e||0)%360)<0?e+360:e}function Ge(e){return Math.max(0,Math.min(1,e||0))}function Ze(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}ye(xe,ze,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Te,formatHex:Te,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return Ke(this).formatHsl()},formatRgb:Le,toString:Le}),ye(_e,Fe,be(xe,{brighter(e){return e=null==e?we:Math.pow(we,e),new _e(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=null==e?.7:Math.pow(.7,e),new _e(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new _e(Ue(this.r),Ue(this.g),Ue(this.b),Be(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:$e,formatHex:$e,formatHex8:function(){return`#${Ve(this.r)}${Ve(this.g)}${Ve(this.b)}${Ve(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:He,toString:He})),ye(Je,function(e,t,n,r){return 1===arguments.length?Ke(e):new Je(e,t,n,null==r?1:r)},be(xe,{brighter(e){return e=null==e?we:Math.pow(we,e),new Je(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=null==e?.7:Math.pow(.7,e),new Je(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 _e(Ze(e>=240?e-240:e+120,i,r),Ze(e,i,r),Ze(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new Je(Ye(this.h),Ge(this.s),Ge(this.l),Be(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=Be(this.opacity);return`${1===e?"hsl(":"hsla("}${Ye(this.h)}, ${100*Ge(this.s)}%, ${100*Ge(this.l)}%${1===e?")":`, ${e})`}`}}));const Xe=Math.PI/180,Qe=180/Math.PI,et=4/29,tt=6/29,nt=3*tt*tt;function rt(e){if(e instanceof it)return new it(e.l,e.a,e.b,e.opacity);if(e instanceof ut)return ct(e);e instanceof _e||(e=Ae(e));var t,n,r=st(e.r),i=st(e.g),o=st(e.b),a=ot((.2225045*r+.7168786*i+.0606169*o)/1);return r===i&&i===o?t=n=a:(t=ot((.4360747*r+.3850649*i+.1430804*o)/.96422),n=ot((.0139322*r+.0971045*i+.7141733*o)/.82521)),new it(116*a-16,500*(t-a),200*(a-n),e.opacity)}function it(e,t,n,r){this.l=+e,this.a=+t,this.b=+n,this.opacity=+r}function ot(e){return e>.008856451679035631?Math.pow(e,1/3):e/nt+et}function at(e){return e>tt?e*e*e:nt*(e-et)}function lt(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function st(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function ut(e,t,n,r){this.h=+e,this.c=+t,this.l=+n,this.opacity=+r}function ct(e){if(isNaN(e.h))return new it(e.l,0,0,e.opacity);var t=e.h*Xe;return new it(e.l,Math.cos(t)*e.c,Math.sin(t)*e.c,e.opacity)}ye(it,function(e,t,n,r){return 1===arguments.length?rt(e):new it(e,t,n,null==r?1:r)},be(xe,{brighter(e){return new it(this.l+18*(null==e?1:e),this.a,this.b,this.opacity)},darker(e){return new it(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 _e(lt(3.1338561*(t=.96422*at(t))-1.6168667*(e=1*at(e))-.4906146*(n=.82521*at(n))),lt(-.9787684*t+1.9161415*e+.033454*n),lt(.0719453*t-.2289914*e+1.4052427*n),this.opacity)}})),ye(ut,function(e,t,n,r){return 1===arguments.length?function(e){if(e instanceof ut)return new ut(e.h,e.c,e.l,e.opacity);if(e instanceof it||(e=rt(e)),0===e.a&&0===e.b)return new ut(NaN,0<e.l&&e.l<100?0:NaN,e.l,e.opacity);var t=Math.atan2(e.b,e.a)*Qe;return new ut(t<0?t+360:t,Math.sqrt(e.a*e.a+e.b*e.b),e.l,e.opacity)}(e):new ut(e,t,n,null==r?1:r)},be(xe,{brighter(e){return new ut(this.h,this.c,this.l+18*(null==e?1:e),this.opacity)},darker(e){return new ut(this.h,this.c,this.l-18*(null==e?1:e),this.opacity)},rgb(){return ct(this).rgb()}}));var dt=e=>()=>e;function ft(e,t){var n=t-e;return n?function(e,t){return function(n){return e+n*t}}(e,n):dt(isNaN(e)?t:e)}var pt=function e(t){var n=function(e){return 1==(e=+e)?ft: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):dt(isNaN(t)?n:t)}}(t);function r(e,t){var r=n((e=Fe(e)).r,(t=Fe(t)).r),i=n(e.g,t.g),o=n(e.b,t.b),a=ft(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),ht=/^class(-pyramid)?/,mt=function(e,t,n,r){var i=void 0!==n.min?n.min:r.min(),o=void 0!==n.max?n.max:r.max(),a=i,l=o,s=t.limits,u={},c="percent"===t.limitType?s.map(function(e){return i+(o-i)*e}):s,d=t.colors.map(function(t){return e.resolveUIColor(t)});if(i=Math.min.apply(Math,[i].concat(F(c))),o=Math.max.apply(Math,[o].concat(F(c))),u.min=i,u.max=o,t.breakTypes&&-1===t.breakTypes.indexOf(!0))u.type="categorical",Object.assign(u,function(e){var t=e.min,n=e.max,r=e.limits,i=e.range,o=[],a=[];if(r.length)if(r[r.length-1]<t)a.push(t,n),o.push(i[i.length-1],i[i.length-1],i[i.length-1]);else if(r[0]>n)a.push(t,n),o.push(i[0],i[0],i[0]);else{if(r[0]>t)a.push(t),o.push(i[0]);else{a.push(t);for(var l=0;l<r.length;l++)if(t<r[l]){o.push(i[l]);break}}for(var s=0;s<r.length;s++)t<r[s]&&r[s]<n&&(a.push(r[s]),o.push(i[s]));if(r[r.length-1]<n)a.push(n),o.push(i[r.length]),o.push(i[r.length]);else{a.push(n);for(var u=0;u<r.length;u++)if(r[u]>n){o.push(i[u]),o.push(i[u]);break}}}else o.push(i[0]);return{min:t,max:n,range:o,domain:a}}({min:"percent"===t.limitType?i:a,max:"percent"===t.limitType?o:l,range:d,limits:"percent"===t.limitType?c:s}));else if(t.breakTypes){var f=t.breakTypes;u.type="continuous",u.domain=[i],u.range=[d[0]];for(var p=0;p<c.length;p+=1)if(f[p]){var h=d[p],m=d[p+1],g=pt(h,m)(.5);u.range.push(g),u.domain.push(c[p]),p<c.length-1&&f[p+1]&&(u.range.push(d[p+1]),u.domain.push((c[p]+c[p+1])/2))}else u.range.push(d[p]),u.range.push(d[p+1]),u.domain.push(c[p]),u.domain.push(c[p]+Math.min(1e-6,(o-i)/1e6));u.range.push(d[d.length-1]),u.domain.push(o)}else u.domain=c,u.range=d;return u};function gt(e,t,n,r,i){var o,a,l,s=0,u=[],c=(e-t)/(r+1);if(0===c)return 1;for(o=0;o<n.length;o+=1)a=.99*(n[o]-t),l=n[o]>e?Math.floor(e/c):n[o]<t?0:Math.floor(a/c),Number.isNaN(l)||(u[l]?u[l]+=1:u[l]=1);for(o=0;o<u.length;o+=1)u[o]&&(s+=1);return s<=r||s>=i?Math.max(s,r):gt(e,t,n,r+1,i)}var vt=function(e,t,n,r){var i,o,a=t.theme,l=t.hc,s=r.f,u={mode:"field",fieldType:"measure",field:s?s.key():void 0,reverse:n.input.reverseScheme||!1,type:"continuous",range:function(e){return e.resources.theme.palette("quant")}},c=[],d=!0;if(s){if(Number.isNaN(+s.min())||Number.isNaN(+s.max()))return{invalid:!0};(d=!("S"===(i=n.pic.raw()).qMode&&(i.qDataPages[0]&&i.qSize.qcy>i.qDataPages[0].qArea.qHeight||!i.qDataPages.length&&i.qSize.qcy>0)||"K"===i.qMode&&i.qStackedDataPages[0]&&i.qSize.qcy>i.qStackedDataPages[0].qArea.qHeight||"T"===i.qMode&&i.qSize.qcy>i.qTreeDataPages[0].qGroupSize))&&(c=n.pic.extract({field:0,props:{num:{field:s.key()},exclude:{fields:l.qDimensionInfo.map(function(e,t){return{field:"qDimensionInfo/".concat(t)}}),value:function(e){return Math.min.apply(Math,F(e))<0}}}}).filter(function(e){return e.value>=0&&!e.exclude.value}).map(function(e){return e.num.value}).filter(function(e){return"number"==typeof e}))}if(!1===n.input.autoMinMax){if(u.min=n.input.measureMin,u.max=n.input.measureMax,u.max<u.min)return{invalid:!0}}else if(s&&!d)u.min=s.min(),u.max=s.max();else if(s){if(!c.length)return{invalid:!0};u.min=Math.min.apply(Math,F(c)),u.max=Math.max.apply(Math,F(c))}if(n.input.measureScheme&&(u.palettes={quant:n.input.measureScheme}),a){var f=a.getDataColorScales().filter(function(e){return e.key===n.input.measureScheme})[0];u.type=f&&ht.test(f.type)?"categorical":"continuous","categorical"===u.type&&(o=f.colors.some(function(e){return Array.isArray(e)})?Math.max.apply(Math,F(f.colors.map(function(e){return e?e.length:0}))):f.colors.length)}if("categorical"===u.type){for(var p=d?gt(u.max,u.min,c,1,o):o,h=(u.max-u.min)/p,m=[],g=0;g<p+1;g+=1)m.push(u.min+h*g);u.domain=m,u.range=function(e){for(var t=e.resources.theme.palette("quant",p),n=Math.max(1,Math.floor(t.length/p)),r=[],i=0;i<p;i+=1)r.push(t[i*n]);return[r[0]].concat(r,[r[r.length-1]])}}return u};function yt(e,t){var n;return t.activeMeasureIndex>=0?n=e.pic.fields().filter(function(e){return"measure"===e.type()})[t.activeMeasureIndex]:"libraryItem"===t.type?n=e.pic.field(function(e){return e.raw().colorMapRef===t.key&&void 0!==t.key}):"expression"===t.type&&(n=e.pic.field(function(e){return"colorByAlternative"===e.raw().id})),n||(n=e.pic.field(function(e){return void 0!==e.raw().matchMeasure}))&&(n=e.pic.fields().filter(function(e){return"measure"===e.type()})[n.raw().matchMeasure]),n}function bt(e){e.measureOverrides.every(function(e){return!e})&&(e.measureOverrides=null)}function xt(e,t){for(var n=(null==t?void 0:t.domain)||[],r=(null==t?void 0:t.range)||[],i=[],o=0;o<e.length;++o){var a=e[o];if("constant"===(null==a?void 0:a.mode)){var l=n.indexOf(o);-1===l?(n.push(o),r.push(a.primary)):r[l]=a.primary,e[o]=null}else if(a){i.push(o);var s=n.indexOf(o);-1!==s&&(n.splice(s,1),r.splice(s,1))}}return{domain:n,range:r,exclude:i}}function wt(e,t,n,r){var i,o=function(e,t,n,r){if(t.input&&!t.input.auto){if("byMeasure"===t.input.mode)return function(e,t,n){var r=t.theme,i=t.hc,o=(arguments.length>3&&void 0!==arguments[3]?arguments[3]:{}).getCField,a=void 0===o?yt:o,l=n.input.byMeasureDef||{activeMeasureIndex:0},s=a(n,l),u=vt(0,{theme:r,hc:i},n,{f:s});if(u.invalid)return u;"expression"===l.type&&(l.activeMeasureIndex<0||void 0===l.activeMeasureIndex)&&(u.label=l.label,s&&"color.altLabel"===s.raw().labelExpRef&&(u.label=n.input.altLabel)),!u.label&&s&&(u.label=s.title());var c=l.activeMeasureIndex>=0?s:null;if(!c&&s&&void 0!==s.raw().matchMeasure&&s.raw().matchMeasure>-1&&(c=n.pic.fields().filter(function(e){return"measure"===e.type()})[s.raw().matchMeasure]),n.input.useMeasureGradient&&"libraryItem"===l.type)if(c){var d=c.raw().coloring;d&&d.gradient&&fe(u,mt(e,d.gradient,u,c))}else u.auxiliary=l;return u}(e,n,t);if("byDimension"===t.input.mode)return function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=r.getCDef,o=void 0===i?ge:i,a=r.getCByField,l=void 0===a?ve:a,s=r.getPersistence,u=void 0===s?me:s,c=o(t,n),d=l(n,c),f=d?d.raw():{},p=n&&n.pic?n.pic.raw():{};if(f.qError||f.qSize&&0===f.qSize.qcy&&!p.qHasOtherValues)return{invalid:!0};var h={mode:"field",fieldType:"dimension",type:"categorical",field:d?d.key():void 0,isFieldLocked:f.qLocked};return("expression"===c.type||c.activeDimensionIndex<0)&&(h.label=c.label,"color.altLabel"===f.labelExpRef&&(h.label=n.input.altLabel)),!h.label&&d&&(h.label=d.title()),n.input.dimensionScheme&&(h.palettes={categorical:n.input.dimensionScheme}),n.input.useDimColVal&&"libraryItem"===c.type&&(h.auxiliary=c),fe(h,u(t,n,c,d,{byRow:he,byElemNo:pe})),h}(e,n,t);if("byExpression"===t.input.mode)return function(e,t,n,r){var i=t.hc,o=t.theme,a=t.translator,l=n.pic.field(function(e){return"colorByExpression"===e.raw().id});if(!l||!l.raw().qFallbackTitle&&!n.input.colorExpression||!(Number.isFinite(l.raw().qMin)&&Number.isFinite(l.raw().qMax)||n.input.expressionIsColor))return{mode:"constant",type:"constant",primary:r.nil};if(n.input.expressionIsColor)return{mode:"field",fieldType:"expression",field:l?l.key():void 0,type:"color"};var s=vt(0,{hc:i,theme:o},n,{f:l});return s.invalid||(s.label=n.input.expressionLabel||a.get("Object.ChartTooltip.ColorExpression")),s}(0,n,t,r);if("byMultiple"===t.input.mode||"primary"===t.input.mode)return function(e,t,n,r){var i=t.hc,o=t.theme,a=t.translator,l=n.input.useBaseColors;if(("byMultiple"===n.input.mode||"primary"===n.input.mode&&"measure"===n.input.useBaseColors)&&i.qMeasureInfo.length>1&&(l="measure"),"measure"===l){var s=[],u=[];"measure"===n.input.useBaseColors&&i.qMeasureInfo.forEach(function(t,n){if(t.baseColor||t.coloring&&t.coloring.baseColor){s.push(n);var i=e.resolveUIColor(t.baseColor||t.coloring.baseColor);"none"===i?u.push(r.primary):u.push(i)}});var c=n.input.dimensionScheme?{categorical:n.input.dimensionScheme}:void 0,d=o?o.getDataColorPalettes()[0]:void 0;return"measure"===n.input.useBaseColors&&d&&(c={categorical:d.key}),{mode:"measure",type:"categorical",palettes:c,label:a?a.get("Common.Measures"):void 0,explicit:s.length?{domain:s,range:u}:void 0}}if("dimension"===l){var f=[],p=[];return i.qDimensionInfo.forEach(function(t,n){if(t.baseColor||t.coloring&&t.coloring.baseColor){f.push(n);var i=e.resolveUIColor(t.baseColor||t.coloring.baseColor);"none"===i?p.push(r.primary):p.push(i)}}),{mode:"dimension",type:"categorical",field:f.length?f[0]:void 0,explicit:f.length?{domain:f,range:p}:void 0}}var h=r.primary;if(void 0!==n.input.paletteColor)n.input.paletteColor&&(h=e.resolveUIColor(n.input.paletteColor));else{var m=n.input.singleColor;"number"!=typeof m||Number.isNaN(m)||(h=["#b0afae","#7b7a78","#545352","#4477aa","#7db8da","#b6d7ea","#46c646","#f93f17","#ffcf02","#276e27","#ffffff","#000000"][m])}return{mode:"constant",type:"constant",primary:h}}(e,n,t,r)}return{}}(e,t,n,r);return null!==(i=t.input)&&void 0!==i&&i.measureOverrides?(o.measureOverrides=t.input.measureOverrides.map(function(n,i){return function(e){var t,n=e.cm,r=e.defaults,i=e.index,o=e.input,a=e.pic;if(!o||!o.on)return null;var l=null!==(t=o.mode)&&void 0!==t?t:"primary";return"primary"===l?function(e,t,n){var r=n.primary;return void 0!==t.paletteColor&&t.paletteColor&&(r=e.resolveUIColor(t.paletteColor)),L(L({},n),{},{mode:"constant",type:"constant",primary:r})}(n,o,r):"byExpression"===l?function(e,t,n){var r="qMeasureInfo/".concat(e,"/"),i=t.field(function(e){return e.id().startsWith(r)&&"colorByMeasureExpression"===e.raw().id}),o=i;return L(L({},n),{},o?{mode:"field",fieldType:"expression",field:i?i.key():void 0,type:"color"}:{mode:"constant",type:"constant",primary:n.nil})}(i,a,r):null}({cm:e,input:n,defaults:r,index:i,pic:t.pic})}),function(e,t){var n,r,i,o=t.translator;if(bt(e),1===(null===(n=e.measureOverrides)||void 0===n?void 0:n.length))return e.measureOverrides[0];if("measure"===e.mode&&e.measureOverrides&&(e.explicit=xt(e.measureOverrides,e.explicit),bt(e)),null!==(r=e.measureOverrides)&&void 0!==r&&r.every(function(e){return"constant"===(null==e?void 0:e.mode)})){var a={mode:"measure",type:"categorical",label:null==o?void 0:o.get("Common.Measures")};return a.explicit=xt(e.measureOverrides),a}return null!==(i=e.measureOverrides)&&void 0!==i&&i.every(function(e){return e})?{invalid:!0,measureOverrides:e.measureOverrides}:e}(o,n)):o}var qt=function(e,t){var n=e.fieldType,r={};if(t)if("measure"===n){var i=t.coloring;i&&(r.measureGradient=i.gradient)}else if("dimension"===n){var o=t[0],a=t[1];o&&(r.legendDataPage=o),a&&(r.dimValsData=a.colorMap)}return r},Dt=function(e){throw e.isHandled=!0,e};function St(e){return function(t){return"object"===_(t.datum[e])?t.datum[e].value:void 0}}function kt(e){return"object"===_(e.datum.isNull)?e.datum.isNull.value:-2===e.datum.value}function Ct(e){return-3===e.datum.value}var Mt={COLOR:void 0,FONT_SIZE:"16px",FONT_FAMILY:"'Source Sans Pro', 'Arial', 'sans-serif'"},It={COLOR:void 0,FONT_SIZE:void 0,FONT_FAMILY:"'Source Sans Pro', 'Arial', 'sans-serif'"};function Nt(e){var t=e.theme,n=e.key,r=e.styleOverrides,i={title:{color:Mt.COLOR,fontSize:Mt.FONT_SIZE,fontFamily:Mt.FONT_FAMILY},label:{color:It.COLOR,fontSize:It.FONT_SIZE,fontFamily:It.FONT_FAMILY}};if(!t&&!r)return i;var o=r||{},a=o.title,l=o.label,s=function(e){var t=e.theme,n=e.key;return function(e,r,i,o){return void 0!==e?e:t?t.getStyle(n,r,i):o}}({theme:t,key:n});return i.title.color=s(null==a?void 0:a.color,"legend.title","color",Mt.COLOR),i.title.fontSize=s(null==a?void 0:a.fontSize,"legend.title","fontSize",Mt.FONT_SIZE),i.title.fontFamily=s(null==a?void 0:a.fontFamily,"legend.title","fontFamily",Mt.FONT_FAMILY),i.label.color=s(null==l?void 0:l.color,"legend.label","color",It.COLOR),i.label.fontSize=s(null==l?void 0:l.fontSize,"legend.label","fontSize",It.FONT_SIZE),i.label.fontFamily=s(null==l?void 0:l.fontFamily,"legend.label","fontFamily",It.FONT_FAMILY),i}var Ot=function(e,t,n){var r=e&&e.dock||void 0;if("auto"!==r)return r||"right";if(t){var i=t.element.getBoundingClientRect();if(i.height>i.width)return"bottom"}return n?"left":"right"},Et=function(e,t,n){return!(n.invalid||"color"===n.type||"measure"===n.mode&&t.qMeasureInfo.length<=1||"dimension"===n.mode)&&("function"==typeof e.show?e.show():!1!==e.show)};function Rt(e,t){var n=e.styleReference,r=e.styleOverrides,i=e.chart,o=e.rtl,a=t.legendProps,l=t.coloring,s=t.theme,u=t.hc,c=Nt({theme:s,key:n,styleOverrides:r});return{layout:{minimumLayoutMode:"MEDIUM",dock:Ot(a,i,o)},show:"function"==typeof a.show?function(){return Et(a,u,l)}:Et(a,u,l),renderer:"svg",mounted:function(e){e.childNodes[0].style.pointerEvents="none",e.style.overflow="hidden"},settings:{title:{show:!1!==a.showTitle,wordBreak:"break-word",maxLines:2,lineHeight:1.2,text:l.label||"",fill:c.title.color,fontSize:c.title.fontSize,fontFamily:c.title.fontFamily}}}}function Tt(e,t,n){var r=[],i=[],o=function(e,t,n){return"categorical"===t.coloring.type?function(e,t,n){var r=Rt(e,t);if(!r.show)return!1;var i,o=e.key,a=e.styleReference,l=e.styleOverrides,s=e.viewState,u=e.rtl,c=e.settings,d=e.style,f=t.scaleKey,p=t.theme,h=t.scales,m=Nt({theme:p,key:a,styleOverrides:l}),g=r.layout.dock,v="left"===g||"right"===g?{maxLines:2,wordBreak:"break-word"}:{},y={up:"M13.6,11 L2.4,11 C2.28954305,11 2.2,10.9104569 2.2,10.8 C2.2,10.756726 2.21403557,10.7146192 2.24,10.68 L7.84,3.21333333 C7.90627417,3.12496777 8.03163444,3.10705916 8.12,3.17333333 C8.13516113,3.18470418 8.14862915,3.1981722 8.16,3.21333333 L13.76,10.68 C13.8262742,10.7683656 13.8083656,10.8937258 13.72,10.96 C13.6853808,10.9859644 13.643274,11 13.6,11 Z",down:"M2.4,4 L13.6,4 C13.7104569,4 13.8,4.08954305 13.8,4.2 C13.8,4.24327404 13.7859644,4.28538077 13.76,4.32 L8.16,11.7866667 C8.09372583,11.8750322 7.96836556,11.8929408 7.88,11.8266667 C7.86483887,11.8152958 7.85137085,11.8018278 7.84,11.7866667 L2.24,4.32 C2.17372583,4.23163444 2.19163444,4.10627417 2.28,4.04 C2.31461923,4.01403557 2.35672596,4 2.4,4 Z",left:"M11,2.4 L11,13.6 C11,13.7104569 10.9104569,13.8 10.8,13.8 C10.756726,13.8 10.7146192,13.7859644 10.68,13.76 L3.21333333,8.16 C3.12496777,8.09372583 3.10705916,7.96836556 3.17333333,7.88 C3.18470418,7.86483887 3.1981722,7.85137085 3.21333333,7.84 L10.68,2.24 C10.7683656,2.17372583 10.8937258,2.19163444 10.96,2.28 C10.9859644,2.31461923 11,2.35672596 11,2.4 Z",right:"M4,13.6 L4,2.4 C4,2.28954305 4.08954305,2.2 4.2,2.2 C4.24327404,2.2 4.28538077,2.21403557 4.32,2.24 L11.7866667,7.84 C11.8750322,7.90627417 11.8929408,8.03163444 11.8266667,8.12 C11.8152958,8.13516113 11.8018278,8.14862915 11.7866667,8.16 L4.32,13.76 C4.23163444,13.8262742 4.10627417,13.8083656 4.04,13.72 C4.01403557,13.6853808 4,13.643274 4,13.6 Z"};"dimension"===t.coloring.fieldType&&(i=function(e){return e.datum.value>=0||-3===e.datum.value});var b="".concat(f,"Legend");return fe(!0,r,{type:"legend-cat",key:"".concat(o,"-cat"),scale:b in h?b:f,settings:{layout:{scrollOffset:function(){return s?s.get("legendScrollOffset"):void 0},size:-1!==["top","bottom"].indexOf(r.layout.dock)?2:1,direction:u?"rtl":"ltr",horizontal:20},item:{show:i,label:L({fill:m.label.color,fontSize:m.label.fontSize,fontFamily:m.label.fontFamily},v)},navigation:{disabled:n,button:{content:function(e,t){var n=t.direction;return e("i",{style:{"pointer-events":"none",fontSize:"12px",display:"inline-block",fontStyle:"normal",lineHeight:"0",textAlign:"center",textTransform:"none",verticalAlign:"-0.125em",textRendering:"optimizelegibility",margin:"0px"}},[e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 16 16",fill:"currentColor"},[e("path",{d:y[n]})])])}}}},brush:{consume:[{context:"selection",data:["",o],style:{inactive:{opacity:.3}}}]}},{settings:c,style:d})}(e,t,n):"continuous"===t.coloring.type&&function(e,t){var n,r=e.key,i=e.styleReference,o=e.styleOverrides,a=e.rtl,l=e.settings,s=e.style,u=t.scaleKey,c=t.theme,d="".concat(u,"Range"),f=Rt(e,t);if(!f.show)return!1;var p=Nt({theme:c,key:i,styleOverrides:o}),h=f.layout.dock,m="right"===h||"left"===h,g=null===(n=t.scales)||void 0===n?void 0:n[d];return m&&g&&(g.invert=!0),fe(!0,f,{type:"legend-seq",key:"".concat(r,"-seq"),settings:{fill:u,major:d,length:1,tick:{fill:p.label.color,fontSize:p.label.fontSize,fontFamily:p.label.fontFamily},title:{anchor:!a||"top"!==f.layout.dock&&"bottom"!==f.layout.dock?void 0:"right",padding:parseFloat(f.settings.title.fontSize)||16}}},{settings:l,style:s})}(e,t)}(e,t,n&&n.navigationDisabled);return r.push(o),o&&"legend-cat"===o.type&&(i.push(function(e){var t=e.key,n=e.requireFailure,r=e.recognizeWith,i=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).actions;return{key:"event:tap-".concat(t),type:"Tap",requireFailure:n,recognizeWith:r,options:{event:"legendtap",interval:10,pointers:1,enable:function(e,n){var r;if(!n)return!0;if(null!=i&&null!==(r=i.interact)&&void 0!==r&&r.enabled&&!i.interact.enabled())return!1;if(!this.chart.componentsFromPoint({x:n.center.x,y:n.center.y}).some(function(e){return e.key==="".concat(t,"-cat")}))return!1;var o=n.srcEvent.target;return!!(o&&o.hasAttribute("data-action")&&o.hasAttribute("data-component-key"))||!(!o||!o.childNodes[0]||"BUTTON"!==o.childNodes[0].nodeName)}},events:{legendtap:function(e){e.preventDefault();var t=e.srcEvent.target;t&&t.hasAttribute("data-action")&&t.hasAttribute("data-component-key")&&this.chart.component(t.getAttribute("data-component-key")).emit(t.getAttribute("data-action"))}}}}(e,n)),i.push(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.eventName,n=e.key,r=e.requireFailure,i=e.recognizeWith,o=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).actions;return{key:"event:pan-".concat(n),type:"Pan",requireFailure:r,recognizeWith:i,options:{event:t,pointers:1,threshold:10,enable:function(e,r){var i;return this.started===t||!r||!(null!=o&&null!==(i=o.interact)&&void 0!==i&&i.enabled&&!o.interact.enabled())&&this.chart.componentsFromPoint({x:r.center.x,y:r.center.y}).some(function(e){return e.key==="".concat(n,"-cat")})}},events:R(R(R({},"".concat(t,"start"),function(e){e.preventDefault(),this.started!==t&&(this.started=t,this.chart.component("".concat(n,"-cat")).emit("panstart",e))}),"".concat(t,"move"),function(e){e.preventDefault(),this.chart.component("".concat(n,"-cat")).emit("panmove",e)}),"".concat(t,"end"),function(e){e.preventDefault(),this.chart.component("".concat(n,"-cat")).emit("panend",e),this.started=!1})}}(e,n))),{interactions:i,components:r}}function Lt(e){var t=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.auto,n=function(e){var t=L({hc:null,colorProps:null,layout:null,theme:null},e),n={},r={auto:function(){return{mode:"primary"}},getDimensionColorMap:function(){return Promise.reject()},getMeasure:function(){return Promise.reject()},getAttributeDimension:function(){return Promise.reject()}},i={auto:function(e){return e?(r.auto=e,i):r.auto},getDimensionColorMap:function(e){return e?(r.getDimensionColorMap=e,i):r.getDimensionColorMap},getAttributeDimension:function(e){return e?(r.getAttributeDimension=e,i):r.getAttributeDimension},getMeasure:function(e){return e?(r.getMeasure=e,i):r.getMeasure},set:function(e){var i;if(!e.colorProps)throw new Error('Missing "colorProps"');if(fe(t,e),(n={pic:t.picasso.data("q")({data:t.hc,config:{localeInfo:t.localeInfo}}),input:t.colorProps}).input.auto){var o=r.auto(e.layout);n.input=fe(!0,{},n.input,o,{auto:!1});var a=t.theme?t.theme.getDataColorPalettes():[];a[0]&&(n.input.dimensionScheme=a[0].key);var l=0;n.input.byDimDef&&+n.input.byDimDef.activeDimensionIndex>=0&&(l=+n.input.byDimDef.activeDimensionIndex),t.hc&&t.hc.qDimensionInfo[l]&&t.hc.qDimensionInfo[l].coloring&&t.hc.qDimensionInfo[l].coloring.colorMapRef&&n.input.byDimDef&&(n.input.byDimDef.type="libraryItem",n.input.byDimDef.key=t.hc.qDimensionInfo[l].coloring.colorMapRef)}null!==(i=n.input.measureOverrides)&&void 0!==i&&i.every(function(e){return!e||!e.on})&&(n.input=fe(!1,{},n.input,{measureOverrides:null}))},palettes:function(){if(!n.palettes){var e=t.theme,r=[];(e&&e.getDataColorPickerPalettes()||[]).forEach(function(e){r.push({key:"ui",colors:e.colors})}),n.palettes=r}return n.palettes},getAuxiliaryData:function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"/qHyperCubeDef";if(!e.auxiliary&&!/qAttrDimInfo/.test(e.field))return Promise.resolve();var i=(e.auxiliary||{}).key;if("measure"===e.fieldType)return r.getMeasure(i,t).catch(function(){});if("dimension"===e.fieldType){var o="".concat(n,"/").concat(e.field).replace("qDimensionInfo","qDimensions").replace("qAttrDimInfo","qAttributeDimensions");return Promise.all([/qAttrDimInfo/.test(e.field)?r.getAttributeDimension(o,t).catch(function(){}):Promise.resolve(),i?r.getDimensionColorMap(i,t).catch(function(){}):Promise.resolve()])}return Promise.resolve()},getAuxiliarySettings:function(e,r){var i=this;return e.auxiliary||/qAttrDimInfo/.test(e.field)?(this.palettes(),this.getAuxiliaryData(e,r).then(function(r){if(!r)return{};if("measure"===e.fieldType){if(r.coloring&&r.coloring.gradient){var o=n.pic.field(e.field);return mt(i,r.coloring.gradient,e,o)}return{}}if("dimension"===e.fieldType){var a={nil:e.nil,others:e.others},l=r[0],s=r[1]?r[1].colorMap:null;if(l){var u=t.picasso.data("q")({data:{qDimensionInfo:[n.pic.field(e.field).raw(),n.pic.field(e.field).raw()],qMeasureInfo:[],qDataPages:l,qInterColumnSortOrder:[0,1],qMode:"S"}});a.legendDataset=u}return s?function(e,t,n,r){var i=r.external,o=r.field,a=L({},e);fe(a,pe(o,o.raw().qCardinal));var l=i.theme?i.theme.getDataColorPalettes()[0]:null;return t.nul&&(a.nil=n.resolveUIColor(t.nul)),t.oth&&(a.others=n.resolveUIColor(t.oth)),t.usePal?(a.palettes={categorical:t.pal},l&&!t.pal&&(a.palettes.categorical=l.key,fe(a,pe(o)))):!1===t.autoFill&&t.single?a.range=[n.resolveUIColor(t.single)]:t.autoFill&&(l&&(a.palettes={categorical:l.key}),fe(a,pe(o))),t.colors&&t.colors.length&&(a.explicit=function(e,t,n){for(var r={},i=0;i<e.length;i+=1)r[e[i].value]=e[i].baseColor;var o=[];return{domain:function(e){var i=e.data,a=[];o=[];for(var l=0;l<i.items.length;l++){var s=i.items[l],u=(s.text||s).label;r[u]&&-1===a.indexOf(s.value)&&(a.push(s.value),o.push(t.resolveUIColor(r[u])))}return a.push(-3,-2),o.push(n.others),o.push(n.nil),a},range:function(){return o}}}(t.colors,n,a)),a}(a,s,i,{external:t,field:n.pic.field(e.field)}):a}return{}})):Promise.resolve()},resolveUIColor:function(e){if(e.index<0||void 0===e.index)return e.color;if(void 0===n.uiPalette&&(n.uiPalette=this.palettes().filter(function(e){return"ui"===e.key})[0]||!1),!n.uiPalette)return e.color;var t="none"===n.uiPalette.colors[0]?e.index:e.index-1;return void 0===n.uiPalette.colors[t]?e.color:n.uiPalette.colors[t]},settings:function(){if(this.palettes(),!n.settings){var e={primary:"steelblue",others:"#aaa",nil:"#ddd"},r=t.theme;r&&(e=L(L({},e),r.getDataColorSpecials())),n.settings=fe(e,wt(this,n,t,e))}return n.settings}};return i}(e.resources).auto(t||function(){return{mode:"byDimension",persistent:!1,useDimColVal:!0,byDimDef:{activeDimensionIndex:0,type:"expression",label:""}}}).getDimensionColorMap(function(e,t){return function(e,t){var n=t.layout,r=t.app;return n&&n.snapshotData?n.snapshotData.content&&n.snapshotData.content.chartData&&n.snapshotData.content.chartData.dimValsData?Promise.resolve({colorMap:n.snapshotData.content.chartData.dimValsData}):Promise.reject():r&&r.getObject?r.getObject("ColorMapModel_".concat(e)).then(function(e){return e.getLayout()}):Promise.reject()}(e,{layout:t.layout,app:t.app})}).getMeasure(function(e,t){return function(e,t){var n=t.layout,r=t.app;return n&&n.snapshotData?n.snapshotData.content&&n.snapshotData.content.chartData&&n.snapshotData.content.chartData.measureGradient?Promise.resolve({coloring:{gradient:n.snapshotData.content.chartData.measureGradient}}):Promise.reject():r&&r.getMeasure?r.getMeasure(e).then(function(e){return e.getMeasure()}):Promise.reject()}(e,{layout:t.layout,app:t.app})}).getAttributeDimension(function(e,t){return function(e,t){var n=t.layout,r=t.model,i=t.app;return n&&n.snapshotData?n.snapshotData.content&&n.snapshotData.content.chartData&&n.snapshotData.content.chartData.legendDataPage?Promise.resolve(n.snapshotData.content.chartData.legendDataPage):Promise.reject():r&&r.session&&i?r.getHyperCubeData(e,[{qHeight:100,qLeft:0,qTop:0,qWidth:2}]).catch(Dt):Promise.reject()}(e,{layout:t.layout,model:t.model,app:t.app})});return n.getSnapshotData=qt,n}({resources:e}),n={},r={},i=function(e){return r.settings||(e||console.warn("settings() called before auxiliarySettings()"),r.settings=t.settings()),r.settings},o={config:function(i){if(n=L({},i),r={},!n.key)throw new Error("Missing key");t.set(L(L({},e),n))},auto:function(e){return e?(t.auto(e),o):t.auto()},getAuxiliarySettings:function(e){return r.auxiliarySettings?Promise.resolve(r.auxiliarySettings):t.getAuxiliarySettings(i(!0),e).then(function(e){return r.auxiliarySettings=e||{},r.settings=L(L({},r.settings),r.auxiliarySettings),r.scales=void 0,r.color=void 0,r.auxiliarySettings})},getAuxiliaryData:function(){return t.getAuxiliaryData(i())},getSnapshotData:function(e){var n=i();return t.getAuxiliaryData(n,e).then(function(e){return t.getSnapshotData(n,e)})},resolveUIColor:function(e){return t.resolveUIColor(e)},settings:function(){var e=i();return{mode:e.mode,type:e.type,label:e.label,field:e.field,fieldType:e.fieldType,nil:e.nil,others:e.others,primary:e.primary}},settingsForMeasure:function(e){var t;return(null===(t=i().measureOverrides)||void 0===t?void 0:t[e])||this.settings()},isSelectionLocked:function(e){var t=e.isMeasureSelectionLocked;return function(e,t){var n=t.isMeasureSelectionLocked;return"field"!==e.mode||("dimension"===e.fieldType?e.isFieldLocked:"measure"!==e.fieldType||n)}(i(),{isMeasureSelectionLocked:t})},palettes:function(){return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.colorProps,n=e.coloring,r=e.theme,i=[];if(n&&n.palettes&&r){var o=n.palettes.categorical||t.dimensionScheme,a=r.getDataColorPalettes().filter(function(e){return e.key===o})[0]||r.getDataColorPalettes()[0];o&&a&&i.push({key:"categorical",colors:a.colors});var l=n.palettes.metric||t.measureScheme,s=r.getDataColorScales().filter(function(e){return e.key===l})[0]||r.getDataColorScales()[0];if(s){var u=s.colors[0]?s.colors:[[]].concat(F(s.colors.slice(1)));u=Array.isArray(u[0])?u.map(function(e){return e.slice().reverse()}):u.slice().reverse(),i.push({key:"quant",colors:u})}}return i}({coloring:i(),colorProps:n.colorProps,theme:n.theme})},scales:function(){return r.scales=r.scales||function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.hc,n=e.coloring,r=e.rtl,i=e.key,o=e.source,a=e.picasso,l={},s=i;if(n){var u={override:!0,domain:n.explicit&&"function"==typeof n.explicit.domain?n.explicit.domain:[].concat(F((n.explicit||{}).domain||[]),[-3,-2]),range:n.explicit&&"function"==typeof n.explicit.range?n.explicit.range:[].concat(F((n.explicit||{}).range||[]),[n.others,n.nil])};if("field"===n.mode){if("dimension"===n.fieldType){var c,d=function(e){var t=e.hc,n=e.source,r=e.coloring,i={data:{extract:[{source:"dummy",field:0,filter:function(){return i.expando=t.qDataPages[0]?t.qDataPages[0].qArea.qTop:0,!1}},{source:n,field:r.field,trackBy:r.valueAccessor,reduce:"first",props:{row:{reduce:function(){return i.expando++}},text:{value:function(e){return e.qText},reduce:"first"}}}]},expando:0};return i}({hc:t,source:o,coloring:n}).data;if(n.legendDataset){var f=0,p={};a.data("q")({data:t}).extract({field:n.field,trackBy:n.valueAccessor,reduce:function(e){var t=e[0];return p[t]=f++,e[0]}}),c={source:"attrDim",extract:{field:"qDimensionInfo/0",filter:function(e){return e.qElemNumber>=0},props:{row:{value:function(e){return p[e.qElemNumber]}}}}}}var h={data:d,range:n.range,domain:n.domain,explicit:u,type:"categorical-color",label:function(e){return e.datum.text&&e.datum.text.value?e.datum.text.value:e.datum.label}};l[s]=h,c&&(l["".concat(s,"Legend")]=L(L({},h),{},{data:c})),t&&t.qHasOtherValues&&c&&((c||h.data).amend=[{label:t.qDimensionInfo[0].othersLabel,source:{key:"qHyperCube",field:"qDimensionInfo/0"},row:{value:-3},value:-3}])}else if("measure"===n.fieldType){var m={data:{field:n.field},min:n.min,max:n.max};l[s]=fe({},m,{type:"categorical"===n.type?"threshold-color":"sequential-color",range:n.range,domain:n.domain,invert:n.reverse}),"sequential-color"===l[s].type&&(l["".concat(s,"Range")]=fe({},m,{invert:!!r}))}else if("color"!==n.type)throw new Error("UNUSED FIELD")}else if("dimension"===n.mode){var g={data:t.qDimensionInfo.map(function(e,t){return t}),label:function(e){return t.qDimensionInfo[e.datum.value].qFallbackTitle},explicit:u,type:"categorical-color"};l[s]=g}else if("measure"===n.mode){var v={data:t.qMeasureInfo.map(function(e,t){return t}).filter(function(e){var t;return!(null!==(t=n.explicit)&&void 0!==t&&null!==(t=t.exclude)&&void 0!==t&&t.includes(e))}),label:function(e){return t.qMeasureInfo[e.datum.value].qFallbackTitle},explicit:u,type:"categorical-color"};l[s]=v}}return l}({hc:n.hc,coloring:i(),key:n.key,source:n.source,picasso:e.picasso}),r.scales},color:function(){return r.color=r.color||function(e){var t=e.coloring,n=e.scales,r=e.key,i=St(r),o=St("".concat(r,"IsAnOther")),a=function(e,t){var r=e.fieldType,a=e.invalid,l=e.mode,s=e.nil,u=e.others,c=e.primary,d=e.type;return a?function(e){return Ct(e)||o(e)?u:s}:n[t]?function(e){return Ct(e)?u:kt(e)||-2===i(e)&&"dimension"===r||"NaN"===i(e)?s:o(e)?u:e.resources.scale(t)(i(e))||u}:"constant"===l?function(e){return Ct(e)||o(e)?u:kt(e)?s:c}:"color"===d?function(e){return Ct(e)||o(e)?u:kt(e)?s:i(e)||u}:null},l=a(t,r);if(t.measureOverrides){var s=St("".concat(r,"MeasureIdx")),u=t.measureOverrides.map(function(e){return e&&a(e)});return function(e){var t=s(e);return u[t]?u[t](e):l(e)}}return l}({coloring:i(),scales:this.scales(),key:n.key}),r.color},datumProps:function(e){return function(e){var t,n,r=e.hc,i=e.coloring,o=e.scales,a=e.key,l=e.addMeasureIx,s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,u=a,c=i.nil;"field"===i.mode&&i.field?t=i.field:o[a]&&"field"===i.mode&&(t=o[a].data.field||i.field),t?(n={field:t,reduce:"first"},"color"===i.type&&(n.value=function(e){return"NaN"!==e.qNum?function(e){return"rgba(".concat([(16711680&e)>>16,(65280&e)>>8,255&e,((4278190080&e)>>>24)/255].join(","),")")}(e.qNum):e.qText&&ze(e.qText)?e.qText:c})):"dimension"===i.mode?n=void 0!==i.field?i.field:r.qDimensionInfo.length-1:"measure"===i.mode&&(n=s);var d=R({},u,n);return r.qDimensionInfo.length>1&&(d["".concat(u,"IsAnOther")]={fields:r.qDimensionInfo.map(function(e,t){return{field:"qDimensionInfo/".concat(t)}}),value:function(e){return-1!==e.indexOf(-3)}}),l&&(d["".concat(u,"MeasureIdx")]=s),d}({coloring:this.settingsForMeasure(e),scales:this.scales(),key:n.key,hc:n.hc,addMeasureIx:i().measureOverrides},e)},data:function(){var e=i(),t={key:"dummy",data:[["field"],["a"]]};return e.legendDataset?[t,{type:"q",key:"attrDim",data:e.legendDataset.raw(),config:{localeInfo:n.localeInfo}}]:[t]},legend:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.eventName,r=e.key,o=e.viewState,a=e.chart,l=e.rtl,s=e.styleReference,u=void 0===s?"object.legend":s,c=e.styleOverrides,d=e.settings,f=void 0===d?{}:d,p=e.style,h=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return Tt({eventName:t,key:r,rtl:l,viewState:o,chart:a,styleReference:u,styleOverrides:c,settings:f,style:void 0===p?{}:p},{legendProps:n.legendProps,scaleKey:n.key,coloring:i(),theme:n.theme,hc:n.hc,scales:this.scales()},h)}};return o}var zt=function(e){return e.baseColor||e.coloring&&e.coloring.baseColor};function Pt(e){var t=e.qHyperCube,n=t.qDimensionInfo,r=t.qMeasureInfo,i=n.some(zt),o=r.some(zt),a=e.color.useBaseColors;return"measure"===a&&!o||"dimension"===a&&!i?"off":a}var jt=function(e){return e.baseColor||e.coloring&&e.coloring.baseColor};function At(e){var t,n=e.qHyperCube.qDimensionInfo.some(jt),r=e.qHyperCube.qMeasureInfo.some(jt),i=n?"dimension":void 0;return{mode:"primary",useBaseColors:null!==(t=null!=i?i:r?"measure":void 0)&&void 0!==t?t:"off",paletteColor:null}}var Ft=function(){};function _t(e){var t,n,r,i,o=e.picasso,a=e.model,l=e.app,s=e.translator,u=e.layoutService,c=void 0===u?void 0:u,d=e.createConfig,f=void 0===d?Ft:d,p=e.config,h=void 0===p?{}:p,m=e.custom,g=void 0===m?{}:m,v=h.localeInfo,y=h.key,b=h.theme,x=void 0===b?void 0:b,w=h.auto,q=void 0===w?void 0:w,D=h.definitionPath,S=null==c||null===(t=c.getLayout)||void 0===t?void 0:t.call(c),k={theme:x,key:y,localeInfo:v,layout:S,hc:null==c||null===(n=c.getHyperCube)||void 0===n?void 0:n.call(c),legendProps:null==c||null===(r=c.getLayoutValue)||void 0===r?void 0:r.call(c,"legend"),colorProps:L(L({},null==c||null===(i=c.getLayoutValue)||void 0===i?void 0:i.call(c,"color")),{},{useBaseColors:S?Pt(S):void 0})},C=Lt({picasso:o,model:a,app:l,translator:s,auto:q});!1!==q&&C.auto(function(e){return q?q({layout:e,defaultAuto:At}):At(e)});var M=!1,I={getColor:function(){return C.color()},getPaletteColor:function(e){var t=e.index,n=e.color;return C.resolveUIColor({index:t,color:n})},getData:function(){return C.data()},getDatumProps:function(e){return C.datumProps(e)},getSnapshotData:function(){return C.getSnapshotData(D)},getSettingsForMeasure:function(e){return C.settingsForMeasure(e)},getSettings:function(){return C.settings()},getLegend:function(e,t){return C.legend(e,t)},getScales:function(){return C.scales()},getPalettes:function(){return C.palettes()},isSelectionLocked:function(e){var t=e.isMeasureSelectionLocked;return C.isSelectionLocked({isMeasureSelectionLocked:t})},isInitialized:function(){return M},custom:L({},g),initialize:function(){var e=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}).createConfig,t=(void 0===e?f:e)({getUseBaseColors:Pt}),n=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return L(L(L({},e),t),{},{colorProps:L(L({},e.colorProps),t.colorProps||{})})}(k,t);return C.config(n),C.getAuxiliarySettings(D).then(function(){M=!0})}};return I}var $t="center",Ht="bottom";function Bt(e,t,n){if(void 0===e||void 0===t)return n;for(var r=t.split("."),i=e,o=0;o<r.length;++o){var a=r[o];if(void 0===i[a])return n;i=i[a]}return i}[{key:"NoDataExist",alignment:$t,condition:function(e){var t=e.layoutService;if(!t)return!1;var n=t.meta.size;return n.x*n.y==0}},{key:"OnlyNanDataMeasure",translationKey:"OnlyNanData",alignment:$t,condition:function(e){var t=e.layoutService;return!!t&&t.getHyperCubeValue("qMeasureInfo").every(function(e){return"NaN"===e.qMin&&"NaN"===e.qMax})}},{key:"OnlyNanDataDimensionContinuous",translationKey:"OnlyNanData",alignment:$t,condition:function(e){var t=e.layoutService;if(!t)return!1;if(!t.meta.isContinuous)return!1;var n=t.getHyperCubeValue("qDimensionInfo.0");return n&&(n.qMax<n.qMin||"NaN"===n.qMax)}},{key:"OnlyNegativeOrZeroValues",alignment:$t},{key:"DataRangeIncludingZero",alignment:Ht},{key:"LimitedData",alignment:Ht},{key:"NegativeOrZeroValues",alignment:Ht}].reduce(function(e,t){return e[t.key]=t,e},{});var Ut=["__proto__","constructor"];function Vt(e,t,n){if(void 0!==e&&void 0!==t){var r=t.split("."),i=r[r.length-1];if(!Ut.some(function(e){return r.includes(e)})){for(var o=e,a=0;a<r.length-1;++a){var l=r[a];void 0===o[l]&&(o[l]=Number.isNaN(+r[a+1])?{}:[]),o=o[l]}void 0!==n?o[i]=n:delete o[i]}}}function Wt(e){var t=e.originalArray,n=e.newArray,r=e.matchKey;return Array.isArray(t)&&t.length?(n.forEach(function(e){var n=-1;t.some(function(t,i){return t[r]&&t[r]===e[r]&&(n=i),n}),n>-1?t[n]=e:t.push(e)}),t):n}function Kt(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Jt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Yt(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Jt(Object(n),!0).forEach(function(t){Kt(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Jt(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var Gt=Object.prototype.hasOwnProperty,Zt=Object.prototype.toString,Xt=Object.defineProperty,Qt=Object.getOwnPropertyDescriptor,en=function(e){return"function"==typeof Array.isArray?Array.isArray(e):"[object Array]"===Zt.call(e)},tn=function(e){if(!e||"[object Object]"!==Zt.call(e))return!1;var t,n=Gt.call(e,"constructor"),r=e.constructor&&e.constructor.prototype&&Gt.call(e.constructor.prototype,"isPrototypeOf");if(e.constructor&&!n&&!r)return!1;for(t in e);return void 0===t||Gt.call(e,t)},nn=function(e,t){Xt&&"__proto__"===t.name?Xt(e,t.name,{enumerable:!0,configurable:!0,value:t.newValue,writable:!0}):e[t.name]=t.newValue},rn=function(e,t){if("__proto__"===t){if(!Gt.call(e,t))return;if(Qt)return Qt(e,t).value}return e[t]},on=function e(){var t,n,r,i,o,a,l=arguments[0],s=1,u=arguments.length,c=!1;for("boolean"==typeof l&&(c=l,l=arguments[1]||{},s=2),(null==l||"object"!=typeof l&&"function"!=typeof l)&&(l={});s<u;++s)if(null!=(t=arguments[s]))for(n in t)r=rn(l,n),l!==(i=rn(t,n))&&(c&&i&&(tn(i)||(o=en(i)))?(o?(o=!1,a=r&&en(r)?r:[]):a=r&&tn(r)?r:{},nn(l,{name:n,newValue:e(c,a,i)})):void 0!==i&&nn(l,{name:n,newValue:i}));return l};function an(e,t,n,r){if(!e)return-1;const i=n.cache,o=e.origin?e.origin():null;o&&(e=o);let a=i.fields.indexOf(e),l=-1,s=-1;if(-1===a)for(let t=0;t<i.wrappedFields.length;t++)if(s=i.wrappedFields[t].attrDims.map(e=>e.instance).indexOf(e),l=i.wrappedFields[t].attrExps.map(e=>e.instance).indexOf(e),-1!==s||-1!==l){a=t;break}if(Array.isArray(r)&&r.some((e,t)=>e!==t)){const e=r.indexOf(a);-1!==e&&(a=e)}return a-=t.qArea.qLeft,a<0||a>=t.qArea.qWidth?-1:s>=0?e=>e[a].qAttrDims.qValues[s]:l>=0?e=>e[a].qAttrExps.qValues[l]:e=>e[a]}function ln(e,t,n){let{key:r}=n;const i={value:"function"==typeof e.value?e.value(t):void 0!==e.value?e.value:t};return i.label="function"==typeof e.label?e.label(t):void 0!==e.label?String(e.label):String(i.value),e.field&&(i.source={key:r,field:e.field.key()}),i}function sn(e){let{cache:t,f:n,mainCell:r,p:i,page:o,rowIdx:a,row:l,sourceKey:s,target:u,targetProp:c,columnOrder:d}=e,f=r;if(i.field&&i.field!==n){const e=an(i.field,o,{cache:t},d);if(-1===e)return;f=on({qRow:a},e(l))}u[c]=ln(i,f,{key:s})}function un(e,t,n,r){const i=Array.isArray(e)?e:[e];let o=[];for(let e=0;e<i.length;e++)if(void 0!==i[e].field){const a=t.raw(),l=t.key(),s="object"==typeof i[e].field?i[e].field:t.field(i[e].field),{props:u,main:c}=r.normalizeConfig(i[e],t),d=Object.keys(u),f=!!i[e].trackBy,p=typeof i[e].trackBy,h={},m=[],g=[];for(let t=0;t<a.qDataPages.length;t++){const o=an(s,a.qDataPages[t],{cache:n},a.qColumnOrder);if(-1!==o)for(let v=0;v<a.qDataPages[t].qMatrix.length;v++){const y=a.qDataPages[t].qArea.qTop+v,b=on({qRow:y},o(a.qDataPages[t].qMatrix[v])),x=ln(c,b,{key:l});if(!c.filter||c.filter(b)){for(let e=0;e<d.length;e++){const r=u[d[e]];let i=r.fields||[r];r.fields&&(x[d[e]]=[]);for(let o=0;o<i.length;o++)sn({cache:n,f:s,mainCell:b,p:i[o],prop:d[e],page:a.qDataPages[t],rowIdx:y,row:a.qDataPages[t].qMatrix[v],sourceKey:l,target:r.fields?x[d[e]]:x,targetProp:r.fields?o:d[e],columnOrder:a.qColumnOrder});if(r.fields){const t=x[d[e]].map(e=>e.value),n=x[d[e]].map(e=>e.label);x[d[e]]={value:"function"==typeof r.value?r.value(t):void 0!==r.value?r.value:t,label:"function"==typeof r.label?r.label(n):void 0!==r.label?String(r.label):String(x[d[e]].value)}}}f&&r.track({cfg:i[e],itemData:b,obj:x,target:m,tracker:h,trackType:p}),g.push(x)}}}const v=f?r.collect(m,{main:c,propsArr:d,props:u}):g;o=[...o,...v]}return o}function cn(e){var t=0,n=e.children,r=n&&n.length;if(r)for(;--r>=0;)t+=n[r].value;else t=1;e.value=t}function dn(e,t){e instanceof Map?(e=[void 0,e],void 0===t&&(t=pn)):void 0===t&&(t=fn);for(var n,r,i,o,a,l=new gn(e),s=[l];n=s.pop();)if((i=t(n.data))&&(a=(i=Array.from(i)).length))for(n.children=i,o=a-1;o>=0;--o)s.push(r=i[o]=new gn(i[o])),r.parent=n,r.depth=n.depth+1;return l.eachBefore(mn)}function fn(e){return e.children}function pn(e){return Array.isArray(e)?e[1]:null}function hn(e){void 0!==e.data.value&&(e.value=e.data.value),e.data=e.data.data}function mn(e){var t=0;do{e.height=t}while((e=e.parent)&&e.height<++t)}function gn(e){this.data=e,this.depth=this.height=0,this.parent=null}function vn(e){return null==e?null:function(e){if("function"!=typeof e)throw new Error;return e}(e)}gn.prototype=dn.prototype={constructor:gn,count:function(){return this.eachAfter(cn)},each:function(e,t){let n=-1;for(const r of this)e.call(t,r,++n,this);return this},eachAfter:function(e,t){for(var n,r,i,o=this,a=[o],l=[],s=-1;o=a.pop();)if(l.push(o),n=o.children)for(r=0,i=n.length;r<i;++r)a.push(n[r]);for(;o=l.pop();)e.call(t,o,++s,this);return this},eachBefore:function(e,t){for(var n,r,i=this,o=[i],a=-1;i=o.pop();)if(e.call(t,i,++a,this),n=i.children)for(r=n.length-1;r>=0;--r)o.push(n[r]);return this},find:function(e,t){let n=-1;for(const r of this)if(e.call(t,r,++n,this))return r},sum:function(e){return this.eachAfter(function(t){for(var n=+e(t.data)||0,r=t.children,i=r&&r.length;--i>=0;)n+=r[i].value;t.value=n})},sort:function(e){return this.eachBefore(function(t){t.children&&t.children.sort(e)})},path:function(e){for(var t=this,n=function(e,t){if(e===t)return e;var n=e.ancestors(),r=t.ancestors(),i=null;for(e=n.pop(),t=r.pop();e===t;)i=e,e=n.pop(),t=r.pop();return i}(t,e),r=[t];t!==n;)t=t.parent,r.push(t);for(var i=r.length;e!==n;)r.splice(i,0,e),e=e.parent;return r},ancestors:function(){for(var e=this,t=[e];e=e.parent;)t.push(e);return t},descendants:function(){return Array.from(this)},leaves:function(){var e=[];return this.eachBefore(function(t){t.children||e.push(t)}),e},links:function(){var e=this,t=[];return e.each(function(n){n!==e&&t.push({source:n.parent,target:n})}),t},copy:function(){return dn(this).eachBefore(hn)},[Symbol.iterator]:function*(){var e,t,n,r,i=this,o=[i];do{for(e=o.reverse(),o=[];i=e.pop();)if(yield i,t=i.children)for(n=0,r=t.length;n<r;++n)o.push(t[n])}while(o.length)}};var yn={depth:-1},bn={},xn={};function wn(e){return e.id}function qn(e){return e.parentId}function Dn(e){let t=e.length;if(t<2)return"";for(;--t>1&&!Sn(e,t););return e.slice(0,t)}function Sn(e,t){if("/"===e[t]){let n=0;for(;t>0&&"\\"===e[--t];)++n;if(!(1&n))return!0}return!1}function kn(e,t){"/"===e.charAt(0)&&(e=e.substring(1));const n=e.split("/");let r,i=t;for(let e=0;e<n.length;e++){if("*"===n[e]&&Array.isArray(i)){const t=[];r=n.slice(e+1).join("/");for(let e=0;e<i.length;e++){let n=kn(r,i[e]);Array.isArray(n)?t.push(...n):t.push(n)}return t}if(!n[e]&&Array.isArray(i)){const t=new Array(i.length);r=n.slice(e+1).join("/");for(let e=0;e<i.length;e++)t[e]=kn(r,i[e]);return t}n[e]in i&&(i=i[n[e]])}return i}function Cn(e,t,n){let r=[];if(!e||!e.length)return r;if(t<=0){const t=n>=0?[e[n]]:e;r=[...r,...t]}else for(let i=0;i<e.length;i++)e[i].children&&e[i].children.length&&(r=[...r,...Cn(e[i].children,t-1,n)]);return r}function Mn(e,t,n){if(e===t)return e=>e;if(e>t){const n=Math.max(0,Math.min(100,e-t));return e=>{let t=e;for(let e=0;e<n;++e)t=t.parent;return t}}if(t>e){const r=Math.max(0,Math.min(100,t-e));return e=>Cn(e.children,r-1,n)}return!1}const In=/^qDimensionInfo(?:\/(\d+))?/,Nn=/^\/?qMeasureInfo\/(\d+)/,On=/\/qAttrExprInfo\/(\d+)/,En=/\/qAttrDimInfo\/(\d+)/;function Rn(e){return(e.qColumnOrder&&e.qColumnOrder.length?e.qColumnOrder:e.qDimensionInfo.map((e,t)=>t)).filter(t=>t<e.qDimensionInfo.length)}function Tn(e,t){let{cube:n}=t;if(!e)return-1;let r=e.origin&&e.origin()?e.origin().key():e.key(),i=!1,o=-1,a=-1,l=-1,s=-1,u=-1,c=-1,d=r;const f=n.qEffectiveInterColumnSortOrder,p=Rn(n);return In.test(d)&&(i=!0,o=+In.exec(d)[1],d=r.replace(In,"")),Nn.test(d)&&("K"===n.qMode?u=+Nn.exec(d)[1]:f&&-1!==f.indexOf(-1)?(u=+Nn.exec(d)[1],c=0):c=+Nn.exec(d)[1],d=d.replace(Nn,"")),d&&(En.exec(d)?l=+En.exec(d)[1]:On.exec(d)&&(a=+On.exec(d)[1])),s=i?"S"===n.qMode?p[o]:f?f.indexOf(o):o:f&&-1!==f.indexOf(-1)?f.indexOf(-1):n.qDimensionInfo.length-("K"===n.qMode?0:1),{fieldDepth:s+1,pseudoMeasureIndex:u,measureIdx:c,attrDimIdx:l,attrIdx:a}}function Ln(e,t){let n,r,i=Mn(e.fieldDepth,t.fieldDepth,t.pseudoMeasureIndex);return n=t.measureIdx>=0?e=>e.data.qValues[t.measureIdx]:e=>e.data,t.attrDimIdx>=0?r=e=>{var n;return null==e||null===(n=e.qAttrDims)||void 0===n?void 0:n.qValues[t.attrDimIdx]}:t.attrIdx>=0&&(r=e=>{var n;return null==e||null===(n=e.qAttrExps)||void 0===n?void 0:n.qValues[t.attrIdx]}),{nodeFn:i,attrFn:r,valueFn:n}}function zn(e,t,n){let{key:r}=n;const i={value:"function"==typeof e.value?e.value(t):void 0!==e.value?e.value:t};return i.label="function"==typeof e.label?e.label(t):void 0!==e.label?String(e.label):String(i.value),e.field&&(i.source={key:r,field:e.field.key()}),i}function Pn(e){let{propsArr:t,props:n,item:r,itemData:i,ret:o,sourceKey:a}=e;for(let e=0;e<t.length;e++){const l=n[t[e]],s=l.fields||[l];let u,c;l.fields&&(u=[],c=[]);for(let n=0;n<s.length;n++){const d=s[n];let f,p,h,m,g,v;if("primitive"===d.type?(h=d.value,v=String(d.value)):("function"==typeof d.value&&(f=e=>d.value(e,r)),"function"==typeof d.label&&(p=e=>d.label(e,r)),d.accessor?(m=d.accessor(r),Array.isArray(m)?(g=m.map(d.valueAccessor),d.attrAccessor&&(g=g.map(d.attrAccessor)),f&&(h=g.map(f),f=null),p&&(v=g.map(p),p=null),h=d.reduce?d.reduce(h):h,v=d.reduceLabel?d.reduceLabel(v,h):String(h)):(h=d.attrAccessor?d.attrAccessor(d.valueAccessor(m)):d.valueAccessor(m),v=h)):(h=i,v=i)),l.fields){const e=f?f(h):h;u.push(e),c.push(p&&null!=v?p(v):null!=v?v:String(e))}else{const n=f?f(h):h;o[t[e]]={value:n,label:p?p(v):null!=v?v:String(n)},d.field&&(o[t[e]].source={field:d.field.key(),key:a})}}u&&(o[t[e]]={value:"function"==typeof l.value?l.value(u,r):u,label:"function"==typeof l.label?l.label(c,r):c})}}const jn=(e,t,n)=>{const r="K"===e.qMode?"/qStackedDataPages/*/qData":"/qTreeDataPages/*",i="K"===e.qMode?"qSubNodes":"qNodes",o=kn(r,e);return o&&o[0]?(t.tree=dn(o[0],n.children||(e=>e[i])),t.tree):null};function An(e){const t=e.raw().qDataPages.length?e.raw().qDataPages[0].qMatrix:[],n=function(e){const t=e.raw().qColumnOrder,n=e.fields();return t&&t.length===n.length?t:n.map((e,t)=>t)}(e),r=e.fields(),i=e.fields().filter(e=>"dimension"===e.type()).map(e=>n.indexOf(r.indexOf(e))),o=e.fields().filter(e=>"measure"===e.type()).map(e=>n.indexOf(r.indexOf(e))),a={__root:{__id:"__root",qValues:[]}};for(let e=0;e<t.length;e++){const n=t[e];let r="__root",s=!1;for(let e=0;e<i.length;e++){var l;const t=n[i[e]],o="".concat(r,"__").concat(null!==(l=t.qElemNumber)&&void 0!==l?l:t.qElemNo);a[o]||(a[o]=Yt({__id:o,__parent:r,qValues:[]},t),s=!0),r=o}if(s)for(let e=0;e<o.length;e++){const t=n[o[e]];a[r].qValues.push(t)}}const s=Object.keys(a).map(e=>a[e]);return function(){var e,t=wn,n=qn;function r(r){var i,o,a,l,s,u,c,d,f=Array.from(r),p=t,h=n,m=new Map;if(null!=e){const t=f.map((t,n)=>function(e){let t=(e=`${e}`).length;return Sn(e,t-1)&&!Sn(e,t-2)&&(e=e.slice(0,-1)),"/"===e[0]?e:`/${e}`}(e(t,n,r))),n=t.map(Dn),i=new Set(t).add("");for(const e of n)i.has(e)||(i.add(e),t.push(e),n.push(Dn(e)),f.push(xn));p=(e,n)=>t[n],h=(e,t)=>n[t]}for(a=0,i=f.length;a<i;++a)o=f[a],u=f[a]=new gn(o),null!=(c=p(o,a,r))&&(c+="")&&(d=u.id=c,m.set(d,m.has(d)?bn:u)),null!=(c=h(o,a,r))&&(c+="")&&(u.parent=c);for(a=0;a<i;++a)if(c=(u=f[a]).parent){if(!(s=m.get(c)))throw new Error("missing: "+c);if(s===bn)throw new Error("ambiguous: "+c);s.children?s.children.push(u):s.children=[u],u.parent=s}else{if(l)throw new Error("multiple roots");l=u}if(!l)throw new Error("no root");if(null!=e){for(;l.data===xn&&1===l.children.length;)l=l.children[0],--i;for(let e=f.length-1;e>=0&&(u=f[e]).data===xn;--e)u.data=null}if(l.parent=yn,l.eachBefore(function(e){e.depth=e.parent.depth+1,--i}).eachBefore(mn),l.parent=null,i>0)throw new Error("cycle");return l}return r.id=function(e){return arguments.length?(t=vn(e),r):t},r.parentId=function(e){return arguments.length?(n=vn(e),r):n},r.path=function(t){return arguments.length?(e=vn(t),r):e},r}().id(e=>e.__id).parentId(e=>e.__parent)(s)}const Fn=e=>{let{propsArr:t,props:n,cube:r,cache:i,itemDepthObject:o,f:a}=e;for(let e=0;e<t.length;e++){const i=n[t[e]],l=i.fields?i.fields:[i];for(let e=0;e<l.length;e++){const t=l[e];if(t.field!==a){const e=Ln(o,Tn(t.field,{cube:r}));t.accessor=e.nodeFn,t.valueAccessor=e.valueFn,t.attrAccessor=e.attrFn}}}};function _n(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0,r=arguments.length>3?arguments[3]:void 0;const i=t.raw(),o=t.key(),a="S"===i.qMode?An(t):jn(i,n,e);if(!a)return null;const l=a.height,s=[];for(let o=0;o<=l;o++){let a=null;if(o>0)if("S"===i.qMode){let e=Rn(i)[o-1];a=n.fields[e]}else{let e=i.qEffectiveInterColumnSortOrder[o-1];o>i.qEffectiveInterColumnSortOrder.length&&(e=i.qDimensionInfo.length),a=n.fields[e]}const{props:l,main:u}=r.normalizeConfig(Yt(Yt({},e),{},{field:a?a.key():void 0}),t),c=Object.keys(l);s[o]={propsArr:c,props:l,main:u};const d=a?Tn(a,{cube:i}):{fieldDepth:0};Fn({propsArr:c,props:l,cube:i,cache:n,itemDepthObject:d,f:a})}const u=a.copy().descendants(),c=a.descendants();for(let e=0;e<c.length;e++){const t=s[c[e].depth].propsArr,n=s[c[e].depth].props,r=s[c[e].depth].main,i=u[e],a=i.data,l=zn(r,a,{key:o});Pn({propsArr:t,props:n,item:i,itemData:a,ret:l,sourceKey:o}),c[e].data=l}return a}function $n(e,t,n,r){const i=Array.isArray(e)?e:[e];let o=[];for(let a=0;a<i.length;a++)if(void 0!==i[a].field){const l=t.raw(),s=t.key();if(!jn(l,n,e))continue;const u="object"==typeof i[a].field?i[a].field:t.field(i[a].field),{props:c,main:d}=r.normalizeConfig(i[a],t),f=Object.keys(c),p=Tn(u,{cube:l}),{nodeFn:h,attrFn:m,valueFn:g}=Ln({fieldDepth:0},p);Fn({propsArr:f,props:c,cube:l,cache:n,itemDepthObject:p,f:u});const v=!!i[a].trackBy,y=typeof i[a].trackBy,b={},x=[],w=h(n.tree),q=[];for(let e=0;e<w.length;e++){const t=w[e],n=m?m(g(t)):g(t);if(d.filter&&!d.filter(n))continue;const o=zn(d,n,{key:s});Pn({propsArr:f,props:c,item:t,itemData:n,ret:o,sourceKey:s}),v&&r.track({cfg:i[a],itemData:n,obj:o,target:x,tracker:b,trackType:y}),q.push(o)}const D=v?r.collect(x,{main:d,propsArr:f,props:c}):q;o=[...o,...D]}return o}var Hn,Bn,Un=(Hn=function(e){
|
|
9
|
+
var e,t,n="function"==typeof Symbol?Symbol:{},r=n.iterator||"@@iterator",i=n.toStringTag||"@@toStringTag";function o(n,r,i,o){var s=r&&r.prototype instanceof l?r:l,u=Object.create(s.prototype);return j(u,"_invoke",function(n,r,i){var o,l,s,u=0,c=i||[],d=!1,f={p:0,n:0,v:e,a:p,f:p.bind(e,4),d:function(t,n){return o=t,l=0,s=e,f.n=n,a}};function p(n,r){for(l=n,s=r,t=0;!d&&u&&!i&&t<c.length;t++){var i,o=c[t],p=f.p,h=o[2];n>3?(i=h===r)&&(s=o[(l=o[4])?5:(l=3,3)],o[4]=o[5]=e):o[0]<=p&&((i=n<2&&p<o[1])?(l=0,f.v=r,f.n=o[1]):p<h&&(i=n<3||o[0]>r||r>h)&&(o[4]=n,o[5]=r,f.n=h,l=0))}if(i||n>1)return a;throw d=!0,r}return function(i,c,h){if(u>1)throw TypeError("Generator is already running");for(d&&1===c&&p(c,h),l=c,s=h;(t=l<2?e:s)||!d;){o||(l?l<3?(l>1&&(f.n=-1),p(l,s)):f.n=s:f.v=s);try{if(u=2,o){if(l||(i="next"),t=o[i]){if(!(t=t.call(o,s)))throw TypeError("iterator result is not an object");if(!t.done)return t;s=t.value,l<2&&(l=0)}else 1===l&&(t=o.return)&&t.call(o),l<2&&(s=TypeError("The iterator does not provide a '"+i+"' method"),l=1);o=e}else if((t=(d=f.n<0)?s:n.call(r,f))!==a)break}catch(t){o=e,l=1,s=t}finally{u=1}}return{value:t,done:d}}}(n,i,o),!0),u}var a={};function l(){}function s(){}function u(){}t=Object.getPrototypeOf;var c=[][r]?t(t([][r]())):(j(t={},r,function(){return this}),t),d=u.prototype=l.prototype=Object.create(c);function f(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,u):(e.__proto__=u,j(e,i,"GeneratorFunction")),e.prototype=Object.create(d),e}return s.prototype=u,j(d,"constructor",u),j(u,"constructor",s),s.displayName="GeneratorFunction",j(u,i,"GeneratorFunction"),j(d),j(d,i,"Generator"),j(d,r,function(){return this}),j(d,"toString",function(){return"[object Generator]"}),(P=function(){return{w:o,m:f}})()}function j(e,t,n,r){var i=Object.defineProperty;try{i({},"",{})}catch(e){i=0}j=function(e,t,n,r){function o(t,n){j(e,t,function(e){return this._invoke(t,n,e)})}t?i?i(e,t,{value:n,enumerable:!r,configurable:!r,writable:!r}):e[t]=n:(o("next",0),o("throw",1),o("return",2))},j(e,t,n,r)}function A(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,i,o,a,l=[],s=!0,u=!1;try{if(o=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=o.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){u=!0,i=e}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw i}}return l}}(e,t)||$(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function F(e){return function(e){if(Array.isArray(e))return N(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||$(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function _(e){return _="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_(e)}function $(e,t){if(e){if("string"==typeof e)return N(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?N(e,t):void 0}}var H,B="top",U="top-right",V="right",W="bottom-right",K="bottom",J="bottom-left",G="left",Y="top-left";R(R(R(R(R(R(R(R(R(R(H={},"equal-equal",[B,K]),"equal-higher",[K,W]),"equal-lower",[B,U]),"equal-void",[B,K]),"higher-equal",[G,J,B,U]),"higher-higher-acute",[K,J,G,U]),"higher-higher-obtuse",[K,B]),"higher-lower-negative",[B,U,V]),"higher-lower-positive",[K,J,G]),"higher-void",[B]),R(R(R(R(R(R(R(R(R(R(H,"lower-equal",[B]),"lower-higher-negative",[B,Y]),"lower-higher-positive",[W]),"lower-lower-acute",[B,Y,G,U,V]),"lower-lower-obtuse",[B,K]),"lower-void",[B]),"void-equal",[B]),"void-higher",[B,K]),"void-lower",[B,K,G]),"void-void",[B]),R(H,"unclassified",[B,K,V,G,U,W,J,Y]);var Z="object",X=["American Typewriter, serif","Andalé Mono, monospace","Arial Black, sans-serif","Arial, sans-serif","Bradley Hand, cursive","Brush Script MT, cursive","Comic Sans MS, cursive","Courier, monospace","Didot, serif","Georgia, serif","Impact, sans-serif","Lucida Console, monospace","Luminari, fantasy","Monaco, monospace","QlikView Sans, sans-serif","Source Sans Pro, sans-serif","Tahoma, sans-serif","Times New Roman, serif","Trebuchet MS, sans-serif","Verdana, sans-serif"],Q=["Abril Fatface, serif","Bangers, fantasy","Bebas Neue, sans serif","EB Garamond, serif","Fredoka One, fantasy","Graduate, fantasy","Gravitas One, serif","Indie Flower, fantasy","Inter, sans-serif","Lobster, fantasy","Montserrat, sans-serif","Nixie One, sans-serif","Noto Sans, sans-serif","Open Sans, sans-serif","PT Serif, serif","Pacifico, cursive","Permanent Marker, fantasy","QlikView Sans, sans-serif","Raleway, sans-serif","Rammetto One, fantasy","Roboto, sans-serif","Source Sans Pro, sans-serif","Titan One, fantasy","Yanone Kaffeesatz, sans-serif"];var ee=function(e){return{value:e,label:e.charAt(0).toUpperCase()+e.slice(1),groupHeader:!1,disabled:!1,styles:{fontFamily:e}}};function te(e){var t=e.theme,n=e.translator,r=e.defaultValue,i=e.flags,o=[],a=t.getStyle("","","fontFamilies");return Array.isArray(a)&&a.length?o.push.apply(o,F(new Set([r].concat(F(a.map(function(e){return e.split(",").map(function(e){return e.trim()}).map(function(e){return e.replace(/\s+/g," ").trim()}).filter(Boolean).join(", ")})))))):o.push(r),[{value:"ThemeHeader",label:n.get("properties.themeFonts"),metaText:n.get("properties.theme"),groupHeader:!0}].concat(F(o.map(function(e){return ee(e)})),[{value:"DefaultHeader",label:n.get("properties.allFonts"),metaText:n.get("properties.default"),groupHeader:!0}],F(function(e){return null!=e&&e.isEnabled("PS_20852_WYSIWYG_FONT_SUPPORT")?Q:X}(i).map(function(e){return ee(e)})))}function ne(e){var t=e.theme,n=e.translator,r=e.id,i=e.path,o=e.flags,a=function(){return t.getStyle(r,i,"fontFamily")};return{getDefaultValue:function(){return a()},getOptions:function(){return te({theme:t,translator:n,defaultValue:a(),flags:o})}}}var re=["10px","11px","12px","13px","14px","15px","16px","17px","18px","19px","20px","21px","22px","23px","24px"],ie=function(e){return{value:e,label:e,groupHeader:!1,disabled:!1}};function oe(e){var t=e.theme,n=e.translator,r=e.id,i=e.path,o=function(){return t.getStyle(r,i,"fontSize")};return{getDefaultValue:function(){return o()},getOptions:function(){return function(e){var t=e.translator,n=e.defaultValue,r=[],i=e.theme.getStyle("","","fontSizes");return Array.isArray(i)&&i.length?r.push.apply(r,F(new Set([n].concat(F(i))))):r.push(n),[{value:"ThemeHeader",label:t.get("properties.themeFontSizes"),metaText:t.get("properties.theme"),groupHeader:!0}].concat(F(r.map(function(e){return ie(e)})),[{value:"DefaultHeader",label:t.get("properties.allFontSizes"),metaText:t.get("properties.default"),groupHeader:!0}],F(re.map(function(e){return ie(e)})))}({theme:t,translator:n,defaultValue:o()})}}}function ae(e){var t=e.theme,n=e.translator,r=e.id,i=e.path;return{fontFamily:ne({theme:t,translator:n,id:r,path:i,flags:e.flags}),fontSize:oe({theme:t,translator:n,id:r,path:i})}}var le,se,ue=["__proto__","constructor"],ce=function(e){if(ue.some(function(t){return e.includes(t)}))throw new Error("font-resolver: Forbidden property.")};var de,fe=function(){if(se)return le;se=1;var e=Object.prototype.hasOwnProperty,t=Object.prototype.toString,n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=function(e){return"function"==typeof Array.isArray?Array.isArray(e):"[object Array]"===t.call(e)},o=function(n){if(!n||"[object Object]"!==t.call(n))return!1;var r,i=e.call(n,"constructor"),o=n.constructor&&n.constructor.prototype&&e.call(n.constructor.prototype,"isPrototypeOf");if(n.constructor&&!i&&!o)return!1;for(r in n);return void 0===r||e.call(n,r)},a=function(e,t){n&&"__proto__"===t.name?n(e,t.name,{enumerable:!0,configurable:!0,value:t.newValue,writable:!0}):e[t.name]=t.newValue},l=function(t,n){if("__proto__"===n){if(!e.call(t,n))return;if(r)return r(t,n).value}return t[n]};return le=function e(){var t,n,r,s,u,c,d=arguments[0],f=1,p=arguments.length,h=!1;for("boolean"==typeof d&&(h=d,d=arguments[1]||{},f=2),(null==d||"object"!=typeof d&&"function"!=typeof d)&&(d={});f<p;++f)if(null!=(t=arguments[f]))for(n in t)r=l(d,n),d!==(s=l(t,n))&&(h&&s&&(o(s)||(u=i(s)))?(u?(u=!1,c=r&&i(r)?r:[]):c=r&&o(r)?r:{},a(d,{name:n,newValue:e(h,c,s)})):void 0!==s&&a(d,{name:n,newValue:s}));return d},le}(),pe=(de=fe)&&de.__esModule&&Object.prototype.hasOwnProperty.call(de,"default")?de.default:de;function he(e,t){return{range:function(e){var n=e.resources,r=e.data,i=n.theme.palette("categorical",0===t?r.items.length:t);return r.items.map(function(e){return i[e.value%i.length]})},valueAccessor:e.value}}function me(e,t){return{range:function(e){var n=e.resources,r=e.data,i=n.theme.palette("categorical",0===t?r.items.length:t);return r.items.map(function(e){return i[e.row.value%i.length]})},valueAccessor:e.value}}function ge(e,t,n,r,i){var o,a,l=i.byRow,s=i.byElemNo;if(r&&(t.input.persistent||e.hc.qDimensionInfo.length>1||void 0===n.activeDimensionIndex&&e.hc.qSize.qcy>((null===(a=(o=e.hc).qDataPages[0]||o.qStackedDataPages[0])||void 0===a?void 0:a.qArea.qHeight)||0)))return s(r,r.raw().qCardinal);if(r){var u=t.pic.extract({field:r.key(),trackBy:r.value}).length;return l(r,u)}return{}}function ve(e,t){var n=e.hc.qDimensionInfo,r=t.input.byDimDef||{activeDimensionIndex:n.length-1};if(r.activeDimensionIndex>=0){var i=n[r.activeDimensionIndex];r=i.coloring&&i.coloring.colorMapRef?{type:"libraryItem",key:i.coloring.colorMapRef,activeDimensionIndex:r.activeDimensionIndex}:{activeDimensionIndex:r.activeDimensionIndex}}return r}function ye(e,t){var n;return t.activeDimensionIndex>=0?n=e.pic.fields().filter(function(e){return"dimension"===e.type()})[t.activeDimensionIndex]:"libraryItem"===t.type?!1===(n=t.key?e.pic.field(function(e){return e.raw().colorMapRef===t.key}):void 0)&&(n=e.pic.field(function(e){return"colorByAlternative"===e.raw().id})):"expression"===t.type&&(n=e.pic.field(function(e){return"colorByAlternative"===e.raw().id})),n}function be(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function xe(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function we(){}var qe=.7,De=1/qe,Se="\\s*([+-]?\\d+)\\s*",ke="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Ce="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",Me=/^#([0-9a-f]{3,8})$/,Ie=new RegExp(`^rgb\\(${Se},${Se},${Se}\\)$`),Ne=new RegExp(`^rgb\\(${Ce},${Ce},${Ce}\\)$`),Ee=new RegExp(`^rgba\\(${Se},${Se},${Se},${ke}\\)$`),Oe=new RegExp(`^rgba\\(${Ce},${Ce},${Ce},${ke}\\)$`),Re=new RegExp(`^hsl\\(${ke},${Ce},${Ce}\\)$`),Te=new RegExp(`^hsla\\(${ke},${Ce},${Ce},${ke}\\)$`),ze={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 Le(){return this.rgb().formatHex()}function Pe(){return this.rgb().formatRgb()}function je(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=Me.exec(e))?(n=t[1].length,t=parseInt(t[1],16),6===n?Ae(t):3===n?new He(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===n?Fe(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===n?Fe(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=Ie.exec(e))?new He(t[1],t[2],t[3],1):(t=Ne.exec(e))?new He(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=Ee.exec(e))?Fe(t[1],t[2],t[3],t[4]):(t=Oe.exec(e))?Fe(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=Re.exec(e))?Je(t[1],t[2]/100,t[3]/100,1):(t=Te.exec(e))?Je(t[1],t[2]/100,t[3]/100,t[4]):ze.hasOwnProperty(e)?Ae(ze[e]):"transparent"===e?new He(NaN,NaN,NaN,0):null}function Ae(e){return new He(e>>16&255,e>>8&255,255&e,1)}function Fe(e,t,n,r){return r<=0&&(e=t=n=NaN),new He(e,t,n,r)}function _e(e){return e instanceof we||(e=je(e)),e?new He((e=e.rgb()).r,e.g,e.b,e.opacity):new He}function $e(e,t,n,r){return 1===arguments.length?_e(e):new He(e,t,n,null==r?1:r)}function He(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}function Be(){return`#${Ke(this.r)}${Ke(this.g)}${Ke(this.b)}`}function Ue(){const e=Ve(this.opacity);return`${1===e?"rgb(":"rgba("}${We(this.r)}, ${We(this.g)}, ${We(this.b)}${1===e?")":`, ${e})`}`}function Ve(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function We(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Ke(e){return((e=We(e))<16?"0":"")+e.toString(16)}function Je(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new Ye(e,t,n,r)}function Ge(e){if(e instanceof Ye)return new Ye(e.h,e.s,e.l,e.opacity);if(e instanceof we||(e=je(e)),!e)return new Ye;if(e instanceof Ye)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,l=o-i,s=(o+i)/2;return l?(a=t===o?(n-r)/l+6*(n<r):n===o?(r-t)/l+2:(t-n)/l+4,l/=s<.5?o+i:2-o-i,a*=60):l=s>0&&s<1?0:a,new Ye(a,l,s,e.opacity)}function Ye(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function Ze(e){return(e=(e||0)%360)<0?e+360:e}function Xe(e){return Math.max(0,Math.min(1,e||0))}function Qe(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}be(we,je,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Le,formatHex:Le,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return Ge(this).formatHsl()},formatRgb:Pe,toString:Pe}),be(He,$e,xe(we,{brighter(e){return e=null==e?De:Math.pow(De,e),new He(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=null==e?qe:Math.pow(qe,e),new He(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new He(We(this.r),We(this.g),We(this.b),Ve(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:Be,formatHex:Be,formatHex8:function(){return`#${Ke(this.r)}${Ke(this.g)}${Ke(this.b)}${Ke(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:Ue,toString:Ue})),be(Ye,function(e,t,n,r){return 1===arguments.length?Ge(e):new Ye(e,t,n,null==r?1:r)},xe(we,{brighter(e){return e=null==e?De:Math.pow(De,e),new Ye(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=null==e?qe:Math.pow(qe,e),new Ye(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 He(Qe(e>=240?e-240:e+120,i,r),Qe(e,i,r),Qe(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new Ye(Ze(this.h),Xe(this.s),Xe(this.l),Ve(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=Ve(this.opacity);return`${1===e?"hsl(":"hsla("}${Ze(this.h)}, ${100*Xe(this.s)}%, ${100*Xe(this.l)}%${1===e?")":`, ${e})`}`}}));const et=Math.PI/180,tt=180/Math.PI,nt=.96422,rt=.82521,it=4/29,ot=6/29,at=3*ot*ot,lt=ot*ot*ot;function st(e){if(e instanceof ut)return new ut(e.l,e.a,e.b,e.opacity);if(e instanceof ht)return mt(e);e instanceof He||(e=_e(e));var t,n,r=pt(e.r),i=pt(e.g),o=pt(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)/nt),n=ct((.0139322*r+.0971045*i+.7141733*o)/rt)),new ut(116*a-16,500*(t-a),200*(a-n),e.opacity)}function ut(e,t,n,r){this.l=+e,this.a=+t,this.b=+n,this.opacity=+r}function ct(e){return e>lt?Math.pow(e,1/3):e/at+it}function dt(e){return e>ot?e*e*e:at*(e-it)}function ft(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function pt(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function ht(e,t,n,r){this.h=+e,this.c=+t,this.l=+n,this.opacity=+r}function mt(e){if(isNaN(e.h))return new ut(e.l,0,0,e.opacity);var t=e.h*et;return new ut(e.l,Math.cos(t)*e.c,Math.sin(t)*e.c,e.opacity)}be(ut,function(e,t,n,r){return 1===arguments.length?st(e):new ut(e,t,n,null==r?1:r)},xe(we,{brighter(e){return new ut(this.l+18*(null==e?1:e),this.a,this.b,this.opacity)},darker(e){return new ut(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 He(ft(3.1338561*(t=nt*dt(t))-1.6168667*(e=1*dt(e))-.4906146*(n=rt*dt(n))),ft(-.9787684*t+1.9161415*e+.033454*n),ft(.0719453*t-.2289914*e+1.4052427*n),this.opacity)}})),be(ht,function(e,t,n,r){return 1===arguments.length?function(e){if(e instanceof ht)return new ht(e.h,e.c,e.l,e.opacity);if(e instanceof ut||(e=st(e)),0===e.a&&0===e.b)return new ht(NaN,0<e.l&&e.l<100?0:NaN,e.l,e.opacity);var t=Math.atan2(e.b,e.a)*tt;return new ht(t<0?t+360:t,Math.sqrt(e.a*e.a+e.b*e.b),e.l,e.opacity)}(e):new ht(e,t,n,null==r?1:r)},xe(we,{brighter(e){return new ht(this.h,this.c,this.l+18*(null==e?1:e),this.opacity)},darker(e){return new ht(this.h,this.c,this.l-18*(null==e?1:e),this.opacity)},rgb(){return mt(this).rgb()}}));var gt=e=>()=>e;function vt(e,t){var n=t-e;return n?function(e,t){return function(n){return e+n*t}}(e,n):gt(isNaN(e)?t:e)}var yt=function e(t){var n=function(e){return 1===(e=+e)?vt: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):gt(isNaN(t)?n:t)}}(t);function r(e,t){var r=n((e=$e(e)).r,(t=$e(t)).r),i=n(e.g,t.g),o=n(e.b,t.b),a=vt(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),bt=/^class(-pyramid)?/,xt=function(e,t,n,r){var i=void 0!==n.min?n.min:r.min(),o=void 0!==n.max?n.max:r.max(),a=i,l=o,s=t.limits,u={},c="percent"===t.limitType?s.map(function(e){return i+(o-i)*e}):s,d=t.colors.map(function(t){return e.resolveUIColor(t)});if(i=Math.min.apply(Math,[i].concat(F(c))),o=Math.max.apply(Math,[o].concat(F(c))),u.min=i,u.max=o,t.breakTypes&&-1===t.breakTypes.indexOf(!0))u.type="categorical",Object.assign(u,function(e){var t=e.min,n=e.max,r=e.limits,i=e.range,o=[],a=[];if(r.length)if(r[r.length-1]<t)a.push(t,n),o.push(i[i.length-1],i[i.length-1],i[i.length-1]);else if(r[0]>n)a.push(t,n),o.push(i[0],i[0],i[0]);else{if(r[0]>t)a.push(t),o.push(i[0]);else{a.push(t);for(var l=0;l<r.length;l++)if(t<r[l]){o.push(i[l]);break}}for(var s=0;s<r.length;s++)t<r[s]&&r[s]<n&&(a.push(r[s]),o.push(i[s]));if(r[r.length-1]<n)a.push(n),o.push(i[r.length]),o.push(i[r.length]);else{a.push(n);for(var u=0;u<r.length;u++)if(r[u]>n){o.push(i[u]),o.push(i[u]);break}}}else o.push(i[0]);return{min:t,max:n,range:o,domain:a}}({min:"percent"===t.limitType?i:a,max:"percent"===t.limitType?o:l,range:d,limits:"percent"===t.limitType?c:s}));else if(t.breakTypes){var f=t.breakTypes;u.type="continuous",u.domain=[i],u.range=[d[0]];for(var p=0;p<c.length;p+=1)if(f[p]){var h=d[p],m=d[p+1],g=yt(h,m)(.5);u.range.push(g),u.domain.push(c[p]),p<c.length-1&&f[p+1]&&(u.range.push(d[p+1]),u.domain.push((c[p]+c[p+1])/2))}else u.range.push(d[p]),u.range.push(d[p+1]),u.domain.push(c[p]),u.domain.push(c[p]+Math.min(1e-6,(o-i)/1e6));u.range.push(d[d.length-1]),u.domain.push(o)}else u.domain=c,u.range=d;return u};function wt(e,t,n,r,i){var o,a,l,s=0,u=[],c=(e-t)/(r+1);if(0===c)return 1;for(o=0;o<n.length;o+=1)a=.99*(n[o]-t),l=n[o]>e?Math.floor(e/c):n[o]<t?0:Math.floor(a/c),Number.isNaN(l)||(u[l]?u[l]+=1:u[l]=1);for(o=0;o<u.length;o+=1)u[o]&&(s+=1);return s<=r||s>=i?Math.max(s,r):wt(e,t,n,r+1,i)}var qt=function(e,t,n,r){var i,o,a=t.theme,l=t.hc,s=r.f,u={mode:"field",fieldType:"measure",field:s?s.key():void 0,reverse:n.input.reverseScheme||!1,type:"continuous",range:function(e){return e.resources.theme.palette("quant")}},c=[],d=!0;if(s){if(Number.isNaN(+s.min())||Number.isNaN(+s.max()))return{invalid:!0};(d=!("S"===(i=n.pic.raw()).qMode&&(i.qDataPages[0]&&i.qSize.qcy>i.qDataPages[0].qArea.qHeight||!i.qDataPages.length&&i.qSize.qcy>0)||"K"===i.qMode&&i.qStackedDataPages[0]&&i.qSize.qcy>i.qStackedDataPages[0].qArea.qHeight||"T"===i.qMode&&i.qSize.qcy>i.qTreeDataPages[0].qGroupSize))&&(c=n.pic.extract({field:0,props:{num:{field:s.key()},exclude:{fields:l.qDimensionInfo.map(function(e,t){return{field:"qDimensionInfo/".concat(t)}}),value:function(e){return Math.min.apply(Math,F(e))<0}}}}).filter(function(e){return e.value>=0&&!e.exclude.value}).map(function(e){return e.num.value}).filter(function(e){return"number"==typeof e}))}if(!1===n.input.autoMinMax){if(u.min=n.input.measureMin,u.max=n.input.measureMax,u.max<u.min)return{invalid:!0}}else if(s&&!d)u.min=s.min(),u.max=s.max();else if(s){if(!c.length)return{invalid:!0};u.min=Math.min.apply(Math,F(c)),u.max=Math.max.apply(Math,F(c))}if(n.input.measureScheme&&(u.palettes={quant:n.input.measureScheme}),a){var f=a.getDataColorScales().filter(function(e){return e.key===n.input.measureScheme})[0];u.type=f&&bt.test(f.type)?"categorical":"continuous","categorical"===u.type&&(o=f.colors.some(function(e){return Array.isArray(e)})?Math.max.apply(Math,F(f.colors.map(function(e){return e?e.length:0}))):f.colors.length)}if("categorical"===u.type){for(var p=d?wt(u.max,u.min,c,1,o):o,h=(u.max-u.min)/p,m=[],g=0;g<p+1;g+=1)m.push(u.min+h*g);u.domain=m,u.range=function(e){for(var t=e.resources.theme.palette("quant",p),n=Math.max(1,Math.floor(t.length/p)),r=[],i=0;i<p;i+=1)r.push(t[i*n]);return[r[0]].concat(r,[r[r.length-1]])}}return u};function Dt(e,t){var n;return t.activeMeasureIndex>=0?n=e.pic.fields().filter(function(e){return"measure"===e.type()})[t.activeMeasureIndex]:"libraryItem"===t.type?n=e.pic.field(function(e){return e.raw().colorMapRef===t.key&&void 0!==t.key}):"expression"===t.type&&(n=e.pic.field(function(e){return"colorByAlternative"===e.raw().id})),n||(n=e.pic.field(function(e){return void 0!==e.raw().matchMeasure}))&&(n=e.pic.fields().filter(function(e){return"measure"===e.type()})[n.raw().matchMeasure]),n}function St(e){e.measureOverrides.every(function(e){return!e})&&(e.measureOverrides=null)}function kt(e,t){for(var n=(null==t?void 0:t.domain)||[],r=(null==t?void 0:t.range)||[],i=[],o=0;o<e.length;++o){var a=e[o];if("constant"===(null==a?void 0:a.mode)){var l=n.indexOf(o);-1===l?(n.push(o),r.push(a.primary)):r[l]=a.primary,e[o]=null}else if(a){i.push(o);var s=n.indexOf(o);-1!==s&&(n.splice(s,1),r.splice(s,1))}}return{domain:n,range:r,exclude:i}}function Ct(e,t,n,r){var i,o=function(e,t,n,r){if(t.input&&!t.input.auto){if("byMeasure"===t.input.mode)return function(e,t,n){var r=t.theme,i=t.hc,o=(arguments.length>3&&void 0!==arguments[3]?arguments[3]:{}).getCField,a=void 0===o?Dt:o,l=n.input.byMeasureDef||{activeMeasureIndex:0},s=a(n,l),u=qt(0,{theme:r,hc:i},n,{f:s});if(u.invalid)return u;"expression"===l.type&&(l.activeMeasureIndex<0||void 0===l.activeMeasureIndex)&&(u.label=l.label,s&&"color.altLabel"===s.raw().labelExpRef&&(u.label=n.input.altLabel)),!u.label&&s&&(u.label=s.title());var c=l.activeMeasureIndex>=0?s:null;if(!c&&s&&void 0!==s.raw().matchMeasure&&s.raw().matchMeasure>-1&&(c=n.pic.fields().filter(function(e){return"measure"===e.type()})[s.raw().matchMeasure]),n.input.useMeasureGradient&&"libraryItem"===l.type)if(c){var d=c.raw().coloring;d&&d.gradient&&pe(u,xt(e,d.gradient,u,c))}else u.auxiliary=l;return u}(e,n,t);if("byDimension"===t.input.mode)return function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=r.getCDef,o=void 0===i?ve:i,a=r.getCByField,l=void 0===a?ye:a,s=r.getPersistence,u=void 0===s?ge:s,c=o(t,n),d=l(n,c),f=d?d.raw():{},p=n&&n.pic?n.pic.raw():{};if(f.qError||f.qSize&&0===f.qSize.qcy&&!p.qHasOtherValues)return{invalid:!0};var h={mode:"field",fieldType:"dimension",type:"categorical",field:d?d.key():void 0,isFieldLocked:f.qLocked};return("expression"===c.type||c.activeDimensionIndex<0)&&(h.label=c.label,"color.altLabel"===f.labelExpRef&&(h.label=n.input.altLabel)),!h.label&&d&&(h.label=d.title()),n.input.dimensionScheme&&(h.palettes={categorical:n.input.dimensionScheme}),n.input.useDimColVal&&"libraryItem"===c.type&&(h.auxiliary=c),pe(h,u(t,n,c,d,{byRow:me,byElemNo:he})),h}(e,n,t);if("byExpression"===t.input.mode)return function(e,t,n,r){var i=t.hc,o=t.theme,a=t.translator,l=n.pic.field(function(e){return"colorByExpression"===e.raw().id});if(!l||!l.raw().qFallbackTitle&&!n.input.colorExpression||!(Number.isFinite(l.raw().qMin)&&Number.isFinite(l.raw().qMax)||n.input.expressionIsColor))return{mode:"constant",type:"constant",primary:r.nil};if(n.input.expressionIsColor)return{mode:"field",fieldType:"expression",field:l?l.key():void 0,type:"color"};var s=qt(0,{hc:i,theme:o},n,{f:l});return s.invalid||(s.label=n.input.expressionLabel||a.get("Object.ChartTooltip.ColorExpression")),s}(0,n,t,r);if("byMultiple"===t.input.mode||"primary"===t.input.mode)return function(e,t,n,r){var i=t.hc,o=t.theme,a=t.translator,l=n.input.useBaseColors;if(("byMultiple"===n.input.mode||"primary"===n.input.mode&&"measure"===n.input.useBaseColors)&&i.qMeasureInfo.length>1&&(l="measure"),"measure"===l){var s=[],u=[];"measure"===n.input.useBaseColors&&i.qMeasureInfo.forEach(function(t,n){if(t.baseColor||t.coloring&&t.coloring.baseColor){s.push(n);var i=e.resolveUIColor(t.baseColor||t.coloring.baseColor);"none"===i?u.push(r.primary):u.push(i)}});var c=n.input.dimensionScheme?{categorical:n.input.dimensionScheme}:void 0,d=o?o.getDataColorPalettes()[0]:void 0;return"measure"===n.input.useBaseColors&&d&&(c={categorical:d.key}),{mode:"measure",type:"categorical",palettes:c,label:a?a.get("Common.Measures"):void 0,explicit:s.length?{domain:s,range:u}:void 0}}if("dimension"===l){var f=[],p=[];return i.qDimensionInfo.forEach(function(t,n){if(t.baseColor||t.coloring&&t.coloring.baseColor){f.push(n);var i=e.resolveUIColor(t.baseColor||t.coloring.baseColor);"none"===i?p.push(r.primary):p.push(i)}}),{mode:"dimension",type:"categorical",field:f.length?f[0]:void 0,explicit:f.length?{domain:f,range:p}:void 0}}var h=r.primary;if(void 0!==n.input.paletteColor)n.input.paletteColor&&(h=e.resolveUIColor(n.input.paletteColor));else{var m=n.input.singleColor;"number"!=typeof m||Number.isNaN(m)||(h=["#b0afae","#7b7a78","#545352","#4477aa","#7db8da","#b6d7ea","#46c646","#f93f17","#ffcf02","#276e27","#ffffff","#000000"][m])}return{mode:"constant",type:"constant",primary:h}}(e,n,t,r)}return{}}(e,t,n,r);return null!==(i=t.input)&&void 0!==i&&i.measureOverrides?(o.measureOverrides=t.input.measureOverrides.map(function(n,i){return function(e){var t,n=e.cm,r=e.defaults,i=e.index,o=e.input,a=e.pic;if(!o||!o.on)return null;var l=null!==(t=o.mode)&&void 0!==t?t:"primary";return"primary"===l?function(e,t,n){var r=n.primary;return void 0!==t.paletteColor&&t.paletteColor&&(r=e.resolveUIColor(t.paletteColor)),z(z({},n),{},{mode:"constant",type:"constant",primary:r})}(n,o,r):"byExpression"===l?function(e,t,n){var r="qMeasureInfo/".concat(e,"/"),i=t.field(function(e){return e.id().startsWith(r)&&"colorByMeasureExpression"===e.raw().id}),o=i;return z(z({},n),{},o?{mode:"field",fieldType:"expression",field:i?i.key():void 0,type:"color"}:{mode:"constant",type:"constant",primary:n.nil})}(i,a,r):null}({cm:e,input:n,defaults:r,index:i,pic:t.pic})}),function(e,t){var n,r,i,o=t.translator;if(St(e),1===(null===(n=e.measureOverrides)||void 0===n?void 0:n.length))return e.measureOverrides[0];if("measure"===e.mode&&e.measureOverrides&&(e.explicit=kt(e.measureOverrides,e.explicit),St(e)),null!==(r=e.measureOverrides)&&void 0!==r&&r.every(function(e){return"constant"===(null==e?void 0:e.mode)})){var a={mode:"measure",type:"categorical",label:null==o?void 0:o.get("Common.Measures")};return a.explicit=kt(e.measureOverrides),a}return null!==(i=e.measureOverrides)&&void 0!==i&&i.every(function(e){return e})?{invalid:!0,measureOverrides:e.measureOverrides}:e}(o,n)):o}var Mt=function(e,t){var n=e.fieldType,r={};if(t)if("measure"===n){var i=t.coloring;i&&(r.measureGradient=i.gradient)}else if("dimension"===n){var o=t[0],a=t[1];o&&(r.legendDataPage=o),a&&(r.dimValsData=a.colorMap)}return r},It=function(e){throw e.isHandled=!0,e};function Nt(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.auto,n=function(e){var t=z({hc:null,colorProps:null,layout:null,theme:null},e),n={},r={auto:function(){return{mode:"primary"}},getDimensionColorMap:function(){return Promise.reject()},getMeasure:function(){return Promise.reject()},getAttributeDimension:function(){return Promise.reject()}},i={auto:function(e){return e?(r.auto=e,i):r.auto},getDimensionColorMap:function(e){return e?(r.getDimensionColorMap=e,i):r.getDimensionColorMap},getAttributeDimension:function(e){return e?(r.getAttributeDimension=e,i):r.getAttributeDimension},getMeasure:function(e){return e?(r.getMeasure=e,i):r.getMeasure},set:function(e){var i;if(!e.colorProps)throw new Error('Missing "colorProps"');if(pe(t,e),(n={pic:t.picasso.data("q")({data:t.hc,config:{localeInfo:t.localeInfo}}),input:t.colorProps}).input.auto){var o=r.auto(e.layout);n.input=pe(!0,{},n.input,o,{auto:!1});var a=t.theme?t.theme.getDataColorPalettes():[];a[0]&&(n.input.dimensionScheme=a[0].key);var l=0;n.input.byDimDef&&+n.input.byDimDef.activeDimensionIndex>=0&&(l=+n.input.byDimDef.activeDimensionIndex),t.hc&&t.hc.qDimensionInfo[l]&&t.hc.qDimensionInfo[l].coloring&&t.hc.qDimensionInfo[l].coloring.colorMapRef&&n.input.byDimDef&&(n.input.byDimDef.type="libraryItem",n.input.byDimDef.key=t.hc.qDimensionInfo[l].coloring.colorMapRef)}null!==(i=n.input.measureOverrides)&&void 0!==i&&i.every(function(e){return!e||!e.on})&&(n.input=pe(!1,{},n.input,{measureOverrides:null}))},palettes:function(){if(!n.palettes){var e=t.theme,r=[];(e&&e.getDataColorPickerPalettes()||[]).forEach(function(e){r.push({key:"ui",colors:e.colors})}),n.palettes=r}return n.palettes},getAuxiliaryData:function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"/qHyperCubeDef";if(!e.auxiliary&&!/qAttrDimInfo/.test(e.field))return Promise.resolve();var i=(e.auxiliary||{}).key;if("measure"===e.fieldType)return r.getMeasure(i,t).catch(function(){});if("dimension"===e.fieldType){var o="".concat(n,"/").concat(e.field).replace("qDimensionInfo","qDimensions").replace("qAttrDimInfo","qAttributeDimensions");return Promise.all([/qAttrDimInfo/.test(e.field)?r.getAttributeDimension(o,t).catch(function(){}):Promise.resolve(),i?r.getDimensionColorMap(i,t).catch(function(){}):Promise.resolve()])}return Promise.resolve()},getAuxiliarySettings:function(e,r){var i=this;return e.auxiliary||/qAttrDimInfo/.test(e.field)?(this.palettes(),this.getAuxiliaryData(e,r).then(function(r){if(!r)return{};if("measure"===e.fieldType){if(r.coloring&&r.coloring.gradient){var o=n.pic.field(e.field);return xt(i,r.coloring.gradient,e,o)}return{}}if("dimension"===e.fieldType){var a={nil:e.nil,others:e.others},l=r[0],s=r[1]?r[1].colorMap:null;if(l){var u=t.picasso.data("q")({data:{qDimensionInfo:[n.pic.field(e.field).raw(),n.pic.field(e.field).raw()],qMeasureInfo:[],qDataPages:l,qInterColumnSortOrder:[0,1],qMode:"S"}});a.legendDataset=u}return s?function(e,t,n,r){var i=r.external,o=r.field,a=z({},e);pe(a,he(o,o.raw().qCardinal));var l=i.theme?i.theme.getDataColorPalettes()[0]:null;return t.nul&&(a.nil=n.resolveUIColor(t.nul)),t.oth&&(a.others=n.resolveUIColor(t.oth)),t.usePal?(a.palettes={categorical:t.pal},l&&!t.pal&&(a.palettes.categorical=l.key,pe(a,he(o)))):!1===t.autoFill&&t.single?a.range=[n.resolveUIColor(t.single)]:t.autoFill&&(l&&(a.palettes={categorical:l.key}),pe(a,he(o))),t.colors&&t.colors.length&&(a.explicit=function(e,t,n){for(var r={},i=0;i<e.length;i+=1)r[e[i].value]=e[i].baseColor;var o=[];return{domain:function(e){var i=e.data,a=[];o=[];for(var l=0;l<i.items.length;l++){var s=i.items[l],u=(s.text||s).label;r[u]&&-1===a.indexOf(s.value)&&(a.push(s.value),o.push(t.resolveUIColor(r[u])))}return a.push(-3,-2),o.push(n.others),o.push(n.nil),a},range:function(){return o}}}(t.colors,n,a)),a}(a,s,i,{external:t,field:n.pic.field(e.field)}):a}return{}})):Promise.resolve()},resolveUIColor:function(e){if(e.index<0||void 0===e.index)return e.color;if(void 0===n.uiPalette&&(n.uiPalette=this.palettes().filter(function(e){return"ui"===e.key})[0]||!1),!n.uiPalette)return e.color;var t="none"===n.uiPalette.colors[0]?e.index:e.index-1;return void 0===n.uiPalette.colors[t]?e.color:n.uiPalette.colors[t]},settings:function(){if(this.palettes(),!n.settings){var e={primary:"steelblue",others:"#aaa",nil:"#ddd"},r=t.theme;r&&(e=z(z({},e),r.getDataColorSpecials())),n.settings=pe(e,Ct(this,n,t,e))}return n.settings}};return i}(e.resources).auto(t||function(){return{mode:"byDimension",persistent:!1,useDimColVal:!0,byDimDef:{activeDimensionIndex:0,type:"expression",label:""}}}).getDimensionColorMap(function(e,t){return function(e,t){var n=t.layout,r=t.app;return n&&n.snapshotData?n.snapshotData.content&&n.snapshotData.content.chartData&&n.snapshotData.content.chartData.dimValsData?Promise.resolve({colorMap:n.snapshotData.content.chartData.dimValsData}):Promise.reject():r&&r.getObject?r.getObject("ColorMapModel_".concat(e)).then(function(e){return e.getLayout()}):Promise.reject()}(e,{layout:t.layout,app:t.app})}).getMeasure(function(e,t){return function(e,t){var n=t.layout,r=t.app;return n&&n.snapshotData?n.snapshotData.content&&n.snapshotData.content.chartData&&n.snapshotData.content.chartData.measureGradient?Promise.resolve({coloring:{gradient:n.snapshotData.content.chartData.measureGradient}}):Promise.reject():r&&r.getMeasure?r.getMeasure(e).then(function(e){return e.getMeasure()}):Promise.reject()}(e,{layout:t.layout,app:t.app})}).getAttributeDimension(function(e,t){return function(e,t){var n=t.layout,r=t.model,i=t.app;return n&&n.snapshotData?n.snapshotData.content&&n.snapshotData.content.chartData&&n.snapshotData.content.chartData.legendDataPage?Promise.resolve(n.snapshotData.content.chartData.legendDataPage):Promise.reject():r&&r.session&&i?r.getHyperCubeData(e,[{qHeight:100,qLeft:0,qTop:0,qWidth:2}]).catch(It):Promise.reject()}(e,{layout:t.layout,model:t.model,app:t.app})});return n.getSnapshotData=Mt,n}function Et(e){return function(t){return"object"===_(t.datum[e])?t.datum[e].value:void 0}}function Ot(e){return"object"===_(e.datum.isNull)?e.datum.isNull.value:-2===e.datum.value}function Rt(e){return-3===e.datum.value}var Tt={COLOR:void 0,FONT_SIZE:"16px",FONT_FAMILY:"'Source Sans Pro', 'Arial', 'sans-serif'"},zt={COLOR:void 0,FONT_SIZE:void 0,FONT_FAMILY:"'Source Sans Pro', 'Arial', 'sans-serif'"},Lt="legend.title",Pt="legend.label";function jt(e){var t=e.theme,n=e.key,r=e.styleOverrides,i={title:{color:Tt.COLOR,fontSize:Tt.FONT_SIZE,fontFamily:Tt.FONT_FAMILY},label:{color:zt.COLOR,fontSize:zt.FONT_SIZE,fontFamily:zt.FONT_FAMILY}};if(!t&&!r)return i;var o=r||{},a=o.title,l=o.label,s=function(e){var t=e.theme,n=e.key;return function(e,r,i,o){return void 0!==e?e:t?t.getStyle(n,r,i):o}}({theme:t,key:n});return i.title.color=s(null==a?void 0:a.color,Lt,"color",Tt.COLOR),i.title.fontSize=s(null==a?void 0:a.fontSize,Lt,"fontSize",Tt.FONT_SIZE),i.title.fontFamily=s(null==a?void 0:a.fontFamily,Lt,"fontFamily",Tt.FONT_FAMILY),i.label.color=s(null==l?void 0:l.color,Pt,"color",zt.COLOR),i.label.fontSize=s(null==l?void 0:l.fontSize,Pt,"fontSize",zt.FONT_SIZE),i.label.fontFamily=s(null==l?void 0:l.fontFamily,Pt,"fontFamily",zt.FONT_FAMILY),i}var At=function(e,t,n){var r=e&&e.dock||void 0;if("auto"!==r)return r||"right";if(t){var i=t.element.getBoundingClientRect();if(i.height>i.width)return"bottom"}return n?"left":"right"},Ft=function(e,t,n){return!(n.invalid||"color"===n.type||"measure"===n.mode&&t.qMeasureInfo.length<=1||"dimension"===n.mode)&&("function"==typeof e.show?e.show():!1!==e.show)};function _t(e,t){var n=e.styleReference,r=e.styleOverrides,i=e.chart,o=e.rtl,a=t.legendProps,l=t.coloring,s=t.theme,u=t.hc,c=jt({theme:s,key:n,styleOverrides:r});return{layout:{minimumLayoutMode:"MEDIUM",dock:At(a,i,o)},show:"function"==typeof a.show?function(){return Ft(a,u,l)}:Ft(a,u,l),renderer:"svg",mounted:function(e){e.childNodes[0].style.pointerEvents="none",e.style.overflow="hidden"},settings:{title:{show:!1!==a.showTitle,wordBreak:"break-word",maxLines:2,lineHeight:1.2,text:l.label||"",fill:c.title.color,fontSize:c.title.fontSize,fontFamily:c.title.fontFamily}}}}function $t(e,t,n){var r=[],i=[],o=function(e,t,n){return"categorical"===t.coloring.type?function(e,t,n){var r=_t(e,t);if(!r.show)return!1;var i,o=e.key,a=e.styleReference,l=e.styleOverrides,s=e.viewState,u=e.rtl,c=e.settings,d=e.style,f=t.scaleKey,p=t.theme,h=t.scales,m=jt({theme:p,key:a,styleOverrides:l}),g=r.layout.dock,v="left"===g||"right"===g?{maxLines:2,wordBreak:"break-word"}:{},y={up:"M13.6,11 L2.4,11 C2.28954305,11 2.2,10.9104569 2.2,10.8 C2.2,10.756726 2.21403557,10.7146192 2.24,10.68 L7.84,3.21333333 C7.90627417,3.12496777 8.03163444,3.10705916 8.12,3.17333333 C8.13516113,3.18470418 8.14862915,3.1981722 8.16,3.21333333 L13.76,10.68 C13.8262742,10.7683656 13.8083656,10.8937258 13.72,10.96 C13.6853808,10.9859644 13.643274,11 13.6,11 Z",down:"M2.4,4 L13.6,4 C13.7104569,4 13.8,4.08954305 13.8,4.2 C13.8,4.24327404 13.7859644,4.28538077 13.76,4.32 L8.16,11.7866667 C8.09372583,11.8750322 7.96836556,11.8929408 7.88,11.8266667 C7.86483887,11.8152958 7.85137085,11.8018278 7.84,11.7866667 L2.24,4.32 C2.17372583,4.23163444 2.19163444,4.10627417 2.28,4.04 C2.31461923,4.01403557 2.35672596,4 2.4,4 Z",left:"M11,2.4 L11,13.6 C11,13.7104569 10.9104569,13.8 10.8,13.8 C10.756726,13.8 10.7146192,13.7859644 10.68,13.76 L3.21333333,8.16 C3.12496777,8.09372583 3.10705916,7.96836556 3.17333333,7.88 C3.18470418,7.86483887 3.1981722,7.85137085 3.21333333,7.84 L10.68,2.24 C10.7683656,2.17372583 10.8937258,2.19163444 10.96,2.28 C10.9859644,2.31461923 11,2.35672596 11,2.4 Z",right:"M4,13.6 L4,2.4 C4,2.28954305 4.08954305,2.2 4.2,2.2 C4.24327404,2.2 4.28538077,2.21403557 4.32,2.24 L11.7866667,7.84 C11.8750322,7.90627417 11.8929408,8.03163444 11.8266667,8.12 C11.8152958,8.13516113 11.8018278,8.14862915 11.7866667,8.16 L4.32,13.76 C4.23163444,13.8262742 4.10627417,13.8083656 4.04,13.72 C4.01403557,13.6853808 4,13.643274 4,13.6 Z"};"dimension"===t.coloring.fieldType&&(i=function(e){return e.datum.value>=0||-3===e.datum.value});var b="".concat(f,"Legend");return pe(!0,r,{type:"legend-cat",key:"".concat(o,"-cat"),scale:b in h?b:f,settings:{layout:{scrollOffset:function(){return s?s.get("legendScrollOffset"):void 0},size:-1!==["top","bottom"].indexOf(r.layout.dock)?2:1,direction:u?"rtl":"ltr",horizontal:20},item:{show:i,label:z({fill:m.label.color,fontSize:m.label.fontSize,fontFamily:m.label.fontFamily},v)},navigation:{disabled:n,button:{content:function(e,t){var n=t.direction;return e("i",{style:{"pointer-events":"none",fontSize:"12px",display:"inline-block",fontStyle:"normal",lineHeight:"0",textAlign:"center",textTransform:"none",verticalAlign:"-0.125em",textRendering:"optimizelegibility",margin:"0px"}},[e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 16 16",fill:"currentColor"},[e("path",{d:y[n]})])])}}}},brush:{consume:[{context:"selection",data:["",o],style:{inactive:{opacity:.3}}}]}},{settings:c,style:d})}(e,t,n):"continuous"===t.coloring.type&&function(e,t){var n,r=e.key,i=e.styleReference,o=e.styleOverrides,a=e.rtl,l=e.settings,s=e.style,u=t.scaleKey,c=t.theme,d="".concat(u,"Range"),f=_t(e,t);if(!f.show)return!1;var p=jt({theme:c,key:i,styleOverrides:o}),h=f.layout.dock,m="right"===h||"left"===h,g=null===(n=t.scales)||void 0===n?void 0:n[d];return m&&g&&(g.invert=!0),pe(!0,f,{type:"legend-seq",key:"".concat(r,"-seq"),settings:{fill:u,major:d,length:1,tick:{fill:p.label.color,fontSize:p.label.fontSize,fontFamily:p.label.fontFamily},title:{anchor:!a||"top"!==f.layout.dock&&"bottom"!==f.layout.dock?void 0:"right",padding:parseFloat(f.settings.title.fontSize)||16}}},{settings:l,style:s})}(e,t)}(e,t,n&&n.navigationDisabled);return r.push(o),o&&"legend-cat"===o.type&&(i.push(function(e){var t=e.key,n=e.requireFailure,r=e.recognizeWith,i=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).actions;return{key:"event:tap-".concat(t),type:"Tap",requireFailure:n,recognizeWith:r,options:{event:"legendtap",interval:10,pointers:1,enable:function(e,n){var r;if(!n)return!0;if(null!=i&&null!==(r=i.interact)&&void 0!==r&&r.enabled&&!i.interact.enabled())return!1;if(!this.chart.componentsFromPoint({x:n.center.x,y:n.center.y}).some(function(e){return e.key==="".concat(t,"-cat")}))return!1;var o=n.srcEvent.target;return!!(o&&o.hasAttribute("data-action")&&o.hasAttribute("data-component-key"))||!(!o||!o.childNodes[0]||"BUTTON"!==o.childNodes[0].nodeName)}},events:{legendtap:function(e){e.preventDefault();var t=e.srcEvent.target;t&&t.hasAttribute("data-action")&&t.hasAttribute("data-component-key")&&this.chart.component(t.getAttribute("data-component-key")).emit(t.getAttribute("data-action"))}}}}(e,n)),i.push(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.eventName,n=e.key,r=e.requireFailure,i=e.recognizeWith,o=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).actions;return{key:"event:pan-".concat(n),type:"Pan",requireFailure:r,recognizeWith:i,options:{event:t,pointers:1,threshold:10,enable:function(e,r){var i;return this.started===t||!r||!(null!=o&&null!==(i=o.interact)&&void 0!==i&&i.enabled&&!o.interact.enabled())&&this.chart.componentsFromPoint({x:r.center.x,y:r.center.y}).some(function(e){return e.key==="".concat(n,"-cat")})}},events:R(R(R({},"".concat(t,"start"),function(e){e.preventDefault(),this.started!==t&&(this.started=t,this.chart.component("".concat(n,"-cat")).emit("panstart",e))}),"".concat(t,"move"),function(e){e.preventDefault(),this.chart.component("".concat(n,"-cat")).emit("panmove",e)}),"".concat(t,"end"),function(e){e.preventDefault(),this.chart.component("".concat(n,"-cat")).emit("panend",e),this.started=!1})}}(e,n))),{interactions:i,components:r}}function Ht(e){var t=Nt({resources:e}),n={},r={},i=function(e){return r.settings||(e||console.warn("settings() called before auxiliarySettings()"),r.settings=t.settings()),r.settings},o={config:function(i){if(n=z({},i),r={},!n.key)throw new Error("Missing key");t.set(z(z({},e),n))},auto:function(e){return e?(t.auto(e),o):t.auto()},getAuxiliarySettings:function(e){return r.auxiliarySettings?Promise.resolve(r.auxiliarySettings):t.getAuxiliarySettings(i(!0),e).then(function(e){return r.auxiliarySettings=e||{},r.settings=z(z({},r.settings),r.auxiliarySettings),r.scales=void 0,r.color=void 0,r.auxiliarySettings})},getAuxiliaryData:function(){return t.getAuxiliaryData(i())},getSnapshotData:function(e){var n=i();return t.getAuxiliaryData(n,e).then(function(e){return t.getSnapshotData(n,e)})},resolveUIColor:function(e){return t.resolveUIColor(e)},settings:function(){var e=i();return{mode:e.mode,type:e.type,label:e.label,field:e.field,fieldType:e.fieldType,nil:e.nil,others:e.others,primary:e.primary}},settingsForMeasure:function(e){var t;return(null===(t=i().measureOverrides)||void 0===t?void 0:t[e])||this.settings()},isSelectionLocked:function(e){var t=e.isMeasureSelectionLocked;return function(e,t){var n=t.isMeasureSelectionLocked;return"field"!==e.mode||("dimension"===e.fieldType?e.isFieldLocked:"measure"!==e.fieldType||n)}(i(),{isMeasureSelectionLocked:t})},palettes:function(){return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.colorProps,n=e.coloring,r=e.theme,i=[];if(n&&n.palettes&&r){var o=n.palettes.categorical||t.dimensionScheme,a=r.getDataColorPalettes().filter(function(e){return e.key===o})[0]||r.getDataColorPalettes()[0];o&&a&&i.push({key:"categorical",colors:a.colors});var l=n.palettes.metric||t.measureScheme,s=r.getDataColorScales().filter(function(e){return e.key===l})[0]||r.getDataColorScales()[0];if(s){var u=s.colors[0]?s.colors:[[]].concat(F(s.colors.slice(1)));u=Array.isArray(u[0])?u.map(function(e){return e.slice().reverse()}):u.slice().reverse(),i.push({key:"quant",colors:u})}}return i}({coloring:i(),colorProps:n.colorProps,theme:n.theme})},scales:function(){return r.scales=r.scales||function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.hc,n=e.coloring,r=e.rtl,i=e.key,o=e.source,a=e.picasso,l={},s=i;if(n){var u={override:!0,domain:n.explicit&&"function"==typeof n.explicit.domain?n.explicit.domain:[].concat(F((n.explicit||{}).domain||[]),[-3,-2]),range:n.explicit&&"function"==typeof n.explicit.range?n.explicit.range:[].concat(F((n.explicit||{}).range||[]),[n.others,n.nil])};if("field"===n.mode){if("dimension"===n.fieldType){var c,d=function(e){var t=e.hc,n=e.coloring,r={data:{extract:[{source:"dummy",field:0,filter:function(){return r.expando=t.qDataPages[0]?t.qDataPages[0].qArea.qTop:0,!1}},{source:e.source,field:n.field,trackBy:n.valueAccessor,reduce:"first",props:{row:{reduce:function(){return r.expando++}},text:{value:function(e){return e.qText},reduce:"first"}}}]},expando:0};return r}({hc:t,source:o,coloring:n}),f=d.data;if(n.legendDataset){var p=0,h={};a.data("q")({data:t}).extract({field:n.field,trackBy:n.valueAccessor,reduce:function(e){var t=e[0];return h[t]=p++,e[0]}}),c={source:"attrDim",extract:{field:"qDimensionInfo/0",filter:function(e){return e.qElemNumber>=0},props:{row:{value:function(e){return h[e.qElemNumber]}}}}}}var m={data:f,range:n.range,domain:n.domain,explicit:u,type:"categorical-color",label:function(e){return e.datum.text&&e.datum.text.value?e.datum.text.value:e.datum.label}};l[s]=m,c&&(l["".concat(s,"Legend")]=z(z({},m),{},{data:c})),t&&t.qHasOtherValues&&c&&((c||m.data).amend=[{label:t.qDimensionInfo[0].othersLabel,source:{key:"qHyperCube",field:"qDimensionInfo/0"},row:{value:-3},value:-3}])}else if("measure"===n.fieldType){var g={data:{field:n.field},min:n.min,max:n.max};l[s]=pe({},g,{type:"categorical"===n.type?"threshold-color":"sequential-color",range:n.range,domain:n.domain,invert:n.reverse}),"sequential-color"===l[s].type&&(l["".concat(s,"Range")]=pe({},g,{invert:!!r}))}else if("color"!==n.type)throw new Error("UNUSED FIELD")}else if("dimension"===n.mode){var v={data:t.qDimensionInfo.map(function(e,t){return t}),label:function(e){return t.qDimensionInfo[e.datum.value].qFallbackTitle},explicit:u,type:"categorical-color"};l[s]=v}else if("measure"===n.mode){var y={data:t.qMeasureInfo.map(function(e,t){return t}).filter(function(e){var t;return!(null!==(t=n.explicit)&&void 0!==t&&null!==(t=t.exclude)&&void 0!==t&&t.includes(e))}),label:function(e){return t.qMeasureInfo[e.datum.value].qFallbackTitle},explicit:u,type:"categorical-color"};l[s]=y}}return l}({hc:n.hc,coloring:i(),key:n.key,source:n.source,picasso:e.picasso}),r.scales},color:function(){return r.color=r.color||function(e){var t=e.coloring,n=e.scales,r=e.key,i=Et(r),o=Et("".concat(r,"IsAnOther")),a=function(e,t){var r=e.fieldType,a=e.invalid,l=e.mode,s=e.nil,u=e.others,c=e.primary,d=e.type;return a?function(e){return Rt(e)||o(e)?u:s}:n[t]?function(e){return Rt(e)?u:Ot(e)||-2===i(e)&&"dimension"===r||"NaN"===i(e)?s:o(e)?u:e.resources.scale(t)(i(e))||u}:"constant"===l?function(e){return Rt(e)||o(e)?u:Ot(e)?s:c}:"color"===d?function(e){return Rt(e)||o(e)?u:Ot(e)?s:i(e)||u}:null},l=a(t,r);if(t.measureOverrides){var s=Et("".concat(r,"MeasureIdx")),u=t.measureOverrides.map(function(e){return e&&a(e)});return function(e){var t=s(e);return u[t]?u[t](e):l(e)}}return l}({coloring:i(),scales:this.scales(),key:n.key}),r.color},datumProps:function(e){return function(e){var t,n,r=e.hc,i=e.coloring,o=e.scales,a=e.key,l=e.addMeasureIx,s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,u=a,c=i.nil;"field"===i.mode&&i.field?t=i.field:o[a]&&"field"===i.mode&&(t=o[a].data.field||i.field),t?(n={field:t,reduce:"first"},"color"===i.type&&(n.value=function(e){return"NaN"!==e.qNum?(t=e.qNum,"rgba(".concat([(16711680&t)>>16,(65280&t)>>8,255&t,((4278190080&t)>>>24)/255].join(","),")")):e.qText&&je(e.qText)?e.qText:c;var t})):"dimension"===i.mode?n=void 0!==i.field?i.field:r.qDimensionInfo.length-1:"measure"===i.mode&&(n=s);var d=R({},u,n);return r.qDimensionInfo.length>1&&(d["".concat(u,"IsAnOther")]={fields:r.qDimensionInfo.map(function(e,t){return{field:"qDimensionInfo/".concat(t)}}),value:function(e){return-1!==e.indexOf(-3)}}),l&&(d["".concat(u,"MeasureIdx")]=s),d}({coloring:this.settingsForMeasure(e),scales:this.scales(),key:n.key,hc:n.hc,addMeasureIx:i().measureOverrides},e)},data:function(){var e=i(),t={key:"dummy",data:[["field"],["a"]]};return e.legendDataset?[t,{type:"q",key:"attrDim",data:e.legendDataset.raw(),config:{localeInfo:n.localeInfo}}]:[t]},legend:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.eventName,r=e.key,o=e.viewState,a=e.chart,l=e.rtl,s=e.styleReference,u=void 0===s?"object.legend":s,c=e.styleOverrides,d=e.settings,f=void 0===d?{}:d,p=e.style,h=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return $t({eventName:t,key:r,rtl:l,viewState:o,chart:a,styleReference:u,styleOverrides:c,settings:f,style:void 0===p?{}:p},{legendProps:n.legendProps,scaleKey:n.key,coloring:i(),theme:n.theme,hc:n.hc,scales:this.scales()},h)}};return o}var Bt=function(e){return e.baseColor||e.coloring&&e.coloring.baseColor};function Ut(e){var t=e.qHyperCube,n=t.qDimensionInfo,r=t.qMeasureInfo,i=n.some(Bt),o=r.some(Bt),a=e.color.useBaseColors;return"measure"===a&&!o||"dimension"===a&&!i?"off":a}var Vt=function(e){return e.baseColor||e.coloring&&e.coloring.baseColor};function Wt(e){var t,n=e.qHyperCube.qDimensionInfo.some(Vt),r=e.qHyperCube.qMeasureInfo.some(Vt),i=n?"dimension":void 0;return{mode:"primary",useBaseColors:null!==(t=null!=i?i:r?"measure":void 0)&&void 0!==t?t:"off",paletteColor:null}}var Kt=function(){};var Jt="center",Gt="bottom";function Yt(e,t,n){if(void 0===e||void 0===t)return n;for(var r=t.split("."),i=e,o=0;o<r.length;++o){var a=r[o];if(void 0===i[a])return n;i=i[a]}return i}[{key:"NoDataExist",alignment:Jt,condition:function(e){var t=e.layoutService;if(!t)return!1;var n=t.meta.size;return n.x*n.y===0}},{key:"OnlyNanDataMeasure",translationKey:"OnlyNanData",alignment:Jt,condition:function(e){var t=e.layoutService;return!!t&&t.getHyperCubeValue("qMeasureInfo").every(function(e){return"NaN"===e.qMin&&"NaN"===e.qMax})}},{key:"OnlyNanDataDimensionContinuous",translationKey:"OnlyNanData",alignment:Jt,condition:function(e){var t=e.layoutService;if(!t)return!1;if(!t.meta.isContinuous)return!1;var n=t.getHyperCubeValue("qDimensionInfo.0");return n&&(n.qMax<n.qMin||"NaN"===n.qMax)}},{key:"OnlyNegativeOrZeroValues",alignment:Jt},{key:"DataRangeIncludingZero",alignment:Gt},{key:"LimitedData",alignment:Gt},{key:"NegativeOrZeroValues",alignment:Gt}].reduce(function(e,t){return e[t.key]=t,e},{});var Zt=["__proto__","constructor"];function Xt(e,t,n){if(void 0!==e&&void 0!==t){var r=t.split("."),i=r[r.length-1];if(!Zt.some(function(e){return r.includes(e)})){for(var o=e,a=0;a<r.length-1;++a){var l=r[a];void 0===o[l]&&(o[l]=Number.isNaN(+r[a+1])?{}:[]),o=o[l]}void 0!==n?o[i]=n:delete o[i]}}}function Qt(e){var t=e.originalArray,n=e.newArray,r=e.matchKey;return Array.isArray(t)&&t.length?(n.forEach(function(e){var n=-1;t.some(function(t,i){return t[r]&&t[r]===e[r]&&(n=i),n}),n>-1?t[n]=e:t.push(e)}),t):n}function en(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function tn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function nn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?tn(Object(n),!0).forEach(function(t){en(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):tn(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var rn=Object.prototype.hasOwnProperty,on=Object.prototype.toString,an=Object.defineProperty,ln=Object.getOwnPropertyDescriptor,sn=function(e){return"function"==typeof Array.isArray?Array.isArray(e):"[object Array]"===on.call(e)},un=function(e){if(!e||"[object Object]"!==on.call(e))return!1;var t,n=rn.call(e,"constructor"),r=e.constructor&&e.constructor.prototype&&rn.call(e.constructor.prototype,"isPrototypeOf");if(e.constructor&&!n&&!r)return!1;for(t in e);return void 0===t||rn.call(e,t)},cn=function(e,t){an&&"__proto__"===t.name?an(e,t.name,{enumerable:!0,configurable:!0,value:t.newValue,writable:!0}):e[t.name]=t.newValue},dn=function(e,t){if("__proto__"===t){if(!rn.call(e,t))return;if(ln)return ln(e,t).value}return e[t]},fn=function e(){var t,n,r,i,o,a,l=arguments[0],s=1,u=arguments.length,c=!1;for("boolean"==typeof l&&(c=l,l=arguments[1]||{},s=2),(null==l||"object"!=typeof l&&"function"!=typeof l)&&(l={});s<u;++s)if(null!=(t=arguments[s]))for(n in t)r=dn(l,n),l!==(i=dn(t,n))&&(c&&i&&(un(i)||(o=sn(i)))?(o?(o=!1,a=r&&sn(r)?r:[]):a=r&&un(r)?r:{},cn(l,{name:n,newValue:e(c,a,i)})):void 0!==i&&cn(l,{name:n,newValue:i}));return l};function pn(e,t,n,r){if(!e)return-1;const i=n.cache,o=e.origin?e.origin():null;o&&(e=o);let a=i.fields.indexOf(e),l=-1,s=-1;if(-1===a)for(let t=0;t<i.wrappedFields.length;t++)if(s=i.wrappedFields[t].attrDims.map(e=>e.instance).indexOf(e),l=i.wrappedFields[t].attrExps.map(e=>e.instance).indexOf(e),-1!==s||-1!==l){a=t;break}if(Array.isArray(r)&&r.some((e,t)=>e!==t)){const e=r.indexOf(a);-1!==e&&(a=e)}return a-=t.qArea.qLeft,a<0||a>=t.qArea.qWidth?-1:s>=0?e=>e[a].qAttrDims.qValues[s]:l>=0?e=>e[a].qAttrExps.qValues[l]:e=>e[a]}function hn(e,t,n){let{key:r}=n;const i={value:"function"==typeof e.value?e.value(t):void 0!==e.value?e.value:t};return i.label="function"==typeof e.label?e.label(t):void 0!==e.label?String(e.label):String(i.value),e.field&&(i.source={key:r,field:e.field.key()}),i}function mn(e){let{cache:t,f:n,mainCell:r,p:i,page:o,rowIdx:a,row:l,sourceKey:s,target:u,targetProp:c,columnOrder:d}=e,f=r;if(i.field&&i.field!==n){const e=pn(i.field,o,{cache:t},d);if(-1===e)return;f=fn({qRow:a},e(l))}u[c]=hn(i,f,{key:s})}function gn(e,t,n,r){const i=Array.isArray(e)?e:[e];let o=[];for(let e=0;e<i.length;e++)if(void 0!==i[e].field){const a=t.raw(),l=t.key(),s="object"==typeof i[e].field?i[e].field:t.field(i[e].field),{props:u,main:c}=r.normalizeConfig(i[e],t),d=Object.keys(u),f=!!i[e].trackBy,p=typeof i[e].trackBy,h={},m=[],g=[];for(let t=0;t<a.qDataPages.length;t++){const o=pn(s,a.qDataPages[t],{cache:n},a.qColumnOrder);if(-1!==o)for(let v=0;v<a.qDataPages[t].qMatrix.length;v++){const y=a.qDataPages[t].qArea.qTop+v,b=fn({qRow:y},o(a.qDataPages[t].qMatrix[v])),x=hn(c,b,{key:l});if(!c.filter||c.filter(b)){for(let e=0;e<d.length;e++){const r=u[d[e]];let i=r.fields||[r];r.fields&&(x[d[e]]=[]);for(let o=0;o<i.length;o++)mn({cache:n,f:s,mainCell:b,p:i[o],prop:d[e],page:a.qDataPages[t],rowIdx:y,row:a.qDataPages[t].qMatrix[v],sourceKey:l,target:r.fields?x[d[e]]:x,targetProp:r.fields?o:d[e],columnOrder:a.qColumnOrder});if(r.fields){const t=x[d[e]].map(e=>e.value),n=x[d[e]].map(e=>e.label);x[d[e]]={value:"function"==typeof r.value?r.value(t):void 0!==r.value?r.value:t,label:"function"==typeof r.label?r.label(n):void 0!==r.label?String(r.label):String(x[d[e]].value)}}}f&&r.track({cfg:i[e],itemData:b,obj:x,target:m,tracker:h,trackType:p}),g.push(x)}}}const v=f?r.collect(m,{main:c,propsArr:d,props:u}):g;o=[...o,...v]}return o}function vn(e){var t=0,n=e.children,r=n&&n.length;if(r)for(;--r>=0;)t+=n[r].value;else t=1;e.value=t}function yn(e,t){e instanceof Map?(e=[void 0,e],void 0===t&&(t=xn)):void 0===t&&(t=bn);for(var n,r,i,o,a,l=new Dn(e),s=[l];n=s.pop();)if((i=t(n.data))&&(a=(i=Array.from(i)).length))for(n.children=i,o=a-1;o>=0;--o)s.push(r=i[o]=new Dn(i[o])),r.parent=n,r.depth=n.depth+1;return l.eachBefore(qn)}function bn(e){return e.children}function xn(e){return Array.isArray(e)?e[1]:null}function wn(e){void 0!==e.data.value&&(e.value=e.data.value),e.data=e.data.data}function qn(e){var t=0;do{e.height=t}while((e=e.parent)&&e.height<++t)}function Dn(e){this.data=e,this.depth=this.height=0,this.parent=null}function Sn(e){return null==e?null:function(e){if("function"!=typeof e)throw new Error;return e}(e)}Dn.prototype=yn.prototype={constructor:Dn,count:function(){return this.eachAfter(vn)},each:function(e,t){let n=-1;for(const r of this)e.call(t,r,++n,this);return this},eachAfter:function(e,t){for(var n,r,i,o=this,a=[o],l=[],s=-1;o=a.pop();)if(l.push(o),n=o.children)for(r=0,i=n.length;r<i;++r)a.push(n[r]);for(;o=l.pop();)e.call(t,o,++s,this);return this},eachBefore:function(e,t){for(var n,r,i=this,o=[i],a=-1;i=o.pop();)if(e.call(t,i,++a,this),n=i.children)for(r=n.length-1;r>=0;--r)o.push(n[r]);return this},find:function(e,t){let n=-1;for(const r of this)if(e.call(t,r,++n,this))return r},sum:function(e){return this.eachAfter(function(t){for(var n=+e(t.data)||0,r=t.children,i=r&&r.length;--i>=0;)n+=r[i].value;t.value=n})},sort:function(e){return this.eachBefore(function(t){t.children&&t.children.sort(e)})},path:function(e){for(var t=this,n=function(e,t){if(e===t)return e;var n=e.ancestors(),r=t.ancestors(),i=null;for(e=n.pop(),t=r.pop();e===t;)i=e,e=n.pop(),t=r.pop();return i}(t,e),r=[t];t!==n;)t=t.parent,r.push(t);for(var i=r.length;e!==n;)r.splice(i,0,e),e=e.parent;return r},ancestors:function(){for(var e=this,t=[e];e=e.parent;)t.push(e);return t},descendants:function(){return Array.from(this)},leaves:function(){var e=[];return this.eachBefore(function(t){t.children||e.push(t)}),e},links:function(){var e=this,t=[];return e.each(function(n){n!==e&&t.push({source:n.parent,target:n})}),t},copy:function(){return yn(this).eachBefore(wn)},[Symbol.iterator]:function*(){var e,t,n,r,i=this,o=[i];do{for(e=o.reverse(),o=[];i=e.pop();)if(yield i,t=i.children)for(n=0,r=t.length;n<r;++n)o.push(t[n])}while(o.length)}};var kn={depth:-1},Cn={},Mn={};function In(e){return e.id}function Nn(e){return e.parentId}function En(e){let t=e.length;if(t<2)return"";for(;--t>1&&!On(e,t););return e.slice(0,t)}function On(e,t){if("/"===e[t]){let n=0;for(;t>0&&"\\"===e[--t];)++n;if(!(1&n))return!0}return!1}function Rn(e,t){"/"===e.charAt(0)&&(e=e.substring(1));const n=e.split("/");let r,i=t;for(let e=0;e<n.length;e++){if("*"===n[e]&&Array.isArray(i)){const t=[];r=n.slice(e+1).join("/");for(let e=0;e<i.length;e++){let n=Rn(r,i[e]);Array.isArray(n)?t.push(...n):t.push(n)}return t}if(!n[e]&&Array.isArray(i)){const t=new Array(i.length);r=n.slice(e+1).join("/");for(let e=0;e<i.length;e++)t[e]=Rn(r,i[e]);return t}n[e]in i&&(i=i[n[e]])}return i}function Tn(e,t,n){let r=[];if(!e||!e.length)return r;if(t<=0){const t=n>=0?[e[n]]:e;r=[...r,...t]}else for(let i=0;i<e.length;i++)e[i].children&&e[i].children.length&&(r=[...r,...Tn(e[i].children,t-1,n)]);return r}function zn(e,t,n){if(e===t)return e=>e;if(e>t){const n=Math.max(0,Math.min(100,e-t));return e=>{let t=e;for(let e=0;e<n;++e)t=t.parent;return t}}if(t>e){const r=Math.max(0,Math.min(100,t-e));return e=>Tn(e.children,r-1,n)}return!1}const Ln=/^qDimensionInfo(?:\/(\d+))?/,Pn=/^\/?qMeasureInfo\/(\d+)/,jn=/\/qAttrExprInfo\/(\d+)/,An=/\/qAttrDimInfo\/(\d+)/;function Fn(e){return(e.qColumnOrder&&e.qColumnOrder.length?e.qColumnOrder:e.qDimensionInfo.map((e,t)=>t)).filter(t=>t<e.qDimensionInfo.length)}function _n(e,t){let{cube:n}=t;if(!e)return-1;let r=e.origin&&e.origin()?e.origin().key():e.key(),i=!1,o=-1,a=-1,l=-1,s=-1,u=-1,c=-1,d=r;const f=n.qEffectiveInterColumnSortOrder,p=Fn(n);return Ln.test(d)&&(i=!0,o=+Ln.exec(d)[1],d=r.replace(Ln,"")),Pn.test(d)&&("K"===n.qMode?u=+Pn.exec(d)[1]:f&&-1!==f.indexOf(-1)?(u=+Pn.exec(d)[1],c=0):c=+Pn.exec(d)[1],d=d.replace(Pn,"")),d&&(An.exec(d)?l=+An.exec(d)[1]:jn.exec(d)&&(a=+jn.exec(d)[1])),s=i?"S"===n.qMode?p[o]:f?f.indexOf(o):o:f&&-1!==f.indexOf(-1)?f.indexOf(-1):n.qDimensionInfo.length-("K"===n.qMode?0:1),{fieldDepth:s+1,pseudoMeasureIndex:u,measureIdx:c,attrDimIdx:l,attrIdx:a}}function $n(e,t){let n,r,i=zn(e.fieldDepth,t.fieldDepth,t.pseudoMeasureIndex);return n=t.measureIdx>=0?e=>e.data.qValues[t.measureIdx]:e=>e.data,t.attrDimIdx>=0?r=e=>{var n;return null==e||null===(n=e.qAttrDims)||void 0===n?void 0:n.qValues[t.attrDimIdx]}:t.attrIdx>=0&&(r=e=>{var n;return null==e||null===(n=e.qAttrExps)||void 0===n?void 0:n.qValues[t.attrIdx]}),{nodeFn:i,attrFn:r,valueFn:n}}function Hn(e,t,n){let{key:r}=n;const i={value:"function"==typeof e.value?e.value(t):void 0!==e.value?e.value:t};return i.label="function"==typeof e.label?e.label(t):void 0!==e.label?String(e.label):String(i.value),e.field&&(i.source={key:r,field:e.field.key()}),i}function Bn(e){let{propsArr:t,props:n,item:r,itemData:i,ret:o,sourceKey:a}=e;for(let e=0;e<t.length;e++){const l=n[t[e]],s=l.fields||[l];let u,c;l.fields&&(u=[],c=[]);for(let n=0;n<s.length;n++){const d=s[n];let f,p,h,m,g,v;if("primitive"===d.type?(h=d.value,v=String(d.value)):("function"==typeof d.value&&(f=e=>d.value(e,r)),"function"==typeof d.label&&(p=e=>d.label(e,r)),d.accessor?(m=d.accessor(r),Array.isArray(m)?(g=m.map(d.valueAccessor),d.attrAccessor&&(g=g.map(d.attrAccessor)),f&&(h=g.map(f),f=null),p&&(v=g.map(p),p=null),h=d.reduce?d.reduce(h):h,v=d.reduceLabel?d.reduceLabel(v,h):String(h)):(h=d.attrAccessor?d.attrAccessor(d.valueAccessor(m)):d.valueAccessor(m),v=h)):(h=i,v=i)),l.fields){const e=f?f(h):h;u.push(e),c.push(p&&null!=v?p(v):null!=v?v:String(e))}else{const n=f?f(h):h;o[t[e]]={value:n,label:p?p(v):null!=v?v:String(n)},d.field&&(o[t[e]].source={field:d.field.key(),key:a})}}u&&(o[t[e]]={value:"function"==typeof l.value?l.value(u,r):u,label:"function"==typeof l.label?l.label(c,r):c})}}const Un=(e,t,n)=>{const r="K"===e.qMode?"/qStackedDataPages/*/qData":"/qTreeDataPages/*",i="K"===e.qMode?"qSubNodes":"qNodes",o=Rn(r,e);return o&&o[0]?(t.tree=yn(o[0],n.children||(e=>e[i])),t.tree):null},Vn=e=>{let{propsArr:t,props:n,cube:r,cache:i,itemDepthObject:o,f:a}=e;for(let e=0;e<t.length;e++){const i=n[t[e]],l=i.fields?i.fields:[i];for(let e=0;e<l.length;e++){const t=l[e];if(t.field!==a){const e=$n(o,_n(t.field,{cube:r}));t.accessor=e.nodeFn,t.valueAccessor=e.valueFn,t.attrAccessor=e.attrFn}}}};function Wn(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0,r=arguments.length>3?arguments[3]:void 0;const i=t.raw(),o=t.key(),a="S"===i.qMode?function(e){const t=e.raw().qDataPages.length?e.raw().qDataPages[0].qMatrix:[],n=function(e){const t=e.raw().qColumnOrder,n=e.fields();return t&&t.length===n.length?t:n.map((e,t)=>t)}(e),r=e.fields(),i=e.fields().filter(e=>"dimension"===e.type()).map(e=>n.indexOf(r.indexOf(e))),o=e.fields().filter(e=>"measure"===e.type()).map(e=>n.indexOf(r.indexOf(e))),a={__root:{__id:"__root",qValues:[]}};for(let e=0;e<t.length;e++){const n=t[e];let r="__root",s=!1;for(let e=0;e<i.length;e++){var l;const t=n[i[e]],o="".concat(r,"__").concat(null!==(l=t.qElemNumber)&&void 0!==l?l:t.qElemNo);a[o]||(a[o]=nn({__id:o,__parent:r,qValues:[]},t),s=!0),r=o}if(s)for(let e=0;e<o.length;e++){const t=n[o[e]];a[r].qValues.push(t)}}const s=Object.keys(a).map(e=>a[e]);return function(){var e,t=In,n=Nn;function r(r){var i,o,a,l,s,u,c,d,f=Array.from(r),p=t,h=n,m=new Map;if(null!=e){const t=f.map((t,n)=>function(e){let t=(e=`${e}`).length;return On(e,t-1)&&!On(e,t-2)&&(e=e.slice(0,-1)),"/"===e[0]?e:`/${e}`}(e(t,n,r))),n=t.map(En),i=new Set(t).add("");for(const e of n)i.has(e)||(i.add(e),t.push(e),n.push(En(e)),f.push(Mn));p=(e,n)=>t[n],h=(e,t)=>n[t]}for(a=0,i=f.length;a<i;++a)o=f[a],u=f[a]=new Dn(o),null!=(c=p(o,a,r))&&(c+="")&&(d=u.id=c,m.set(d,m.has(d)?Cn:u)),null!=(c=h(o,a,r))&&(c+="")&&(u.parent=c);for(a=0;a<i;++a)if(c=(u=f[a]).parent){if(!(s=m.get(c)))throw new Error("missing: "+c);if(s===Cn)throw new Error("ambiguous: "+c);s.children?s.children.push(u):s.children=[u],u.parent=s}else{if(l)throw new Error("multiple roots");l=u}if(!l)throw new Error("no root");if(null!=e){for(;l.data===Mn&&1===l.children.length;)l=l.children[0],--i;for(let e=f.length-1;e>=0&&(u=f[e]).data===Mn;--e)u.data=null}if(l.parent=kn,l.eachBefore(function(e){e.depth=e.parent.depth+1,--i}).eachBefore(qn),l.parent=null,i>0)throw new Error("cycle");return l}return r.id=function(e){return arguments.length?(t=Sn(e),r):t},r.parentId=function(e){return arguments.length?(n=Sn(e),r):n},r.path=function(t){return arguments.length?(e=Sn(t),r):e},r}().id(e=>e.__id).parentId(e=>e.__parent)(s)}(t):Un(i,n,e);if(!a)return null;const l=a.height,s=[];for(let o=0;o<=l;o++){let a=null;if(o>0)if("S"===i.qMode){let e=Fn(i)[o-1];a=n.fields[e]}else{let e=i.qEffectiveInterColumnSortOrder[o-1];o>i.qEffectiveInterColumnSortOrder.length&&(e=i.qDimensionInfo.length),a=n.fields[e]}const{props:l,main:u}=r.normalizeConfig(nn(nn({},e),{},{field:a?a.key():void 0}),t),c=Object.keys(l);s[o]={propsArr:c,props:l,main:u};const d=a?_n(a,{cube:i}):{fieldDepth:0};Vn({propsArr:c,props:l,cube:i,cache:n,itemDepthObject:d,f:a})}const u=a.copy().descendants(),c=a.descendants();for(let e=0;e<c.length;e++){const t=s[c[e].depth].propsArr,n=s[c[e].depth].props,r=s[c[e].depth].main,i=u[e],a=i.data,l=Hn(r,a,{key:o});Bn({propsArr:t,props:n,item:i,itemData:a,ret:l,sourceKey:o}),c[e].data=l}return a}function Kn(e,t,n,r){const i=Array.isArray(e)?e:[e];let o=[];for(let a=0;a<i.length;a++)if(void 0!==i[a].field){const l=t.raw(),s=t.key();if(!Un(l,n,e))continue;const u="object"==typeof i[a].field?i[a].field:t.field(i[a].field),{props:c,main:d}=r.normalizeConfig(i[a],t),f=Object.keys(c),p=_n(u,{cube:l}),{nodeFn:h,attrFn:m,valueFn:g}=$n({fieldDepth:0},p);Vn({propsArr:f,props:c,cube:l,cache:n,itemDepthObject:p,f:u});const v=!!i[a].trackBy,y=typeof i[a].trackBy,b={},x=[],w=h(n.tree),q=[];for(let e=0;e<w.length;e++){const t=w[e],n=m?m(g(t)):g(t);if(d.filter&&!d.filter(n))continue;const o=Hn(d,n,{key:s});Bn({propsArr:f,props:c,item:t,itemData:n,ret:o,sourceKey:s}),v&&r.track({cfg:i[a],itemData:n,obj:o,target:x,tracker:b,trackType:y}),q.push(o)}const D=v?r.collect(x,{main:d,propsArr:f,props:c}):q;o=[...o,...D]}return o}var Jn,Gn,Yn=(Jn=function(e){
|
|
10
10
|
/*! javascript-number-formatter - v1.1.11 - http://mottie.github.com/javascript-number-formatter/ * © ecava */
|
|
11
|
-
e.exports=function(e,t){if(!e||isNaN(+t))return t;var n,r,i,o,a,l,s,u,c,d,f=e.length,p=e.search(/[0-9\-\+#]/),h=p>0?e.substring(0,p):"",m=e.split("").reverse().join(""),g=m.search(/[0-9\-\+#]/),v=f-g,y=e.substring(v,v+1),b=v+("."===y||","===y?1:0),x=g>0?e.substring(b,f):"";if(n=(t="-"===(e=e.substring(p,b)).charAt(0)?-t:+t)<0?t=-t:0,i=(r=e.match(/[^\d\-\+#]/g))&&r[r.length-1]||".",o=r&&r[1]&&r[0]||",",e=e.split(i),t=+(t=t.toFixed(e[1]&&e[1].length))+"",l=e[1]&&e[1].lastIndexOf("0"),(!(u=t.split("."))[1]||u[1]&&u[1].length<=l)&&(t=(+t).toFixed(l+1)),c=e[0].split(o),e[0]=c.join(""),(a=e[0]&&e[0].indexOf("0"))>-1)for(;u[0].length<e[0].length-a;)u[0]="0"+u[0];else 0==+u[0]&&(u[0]="");if((t=t.split("."))[0]=u[0],s=c[1]&&c[c.length-1].length){for(m="",v=(d=t[0]).length%s,f=d.length,b=0;b<f;b++)m+=d.charAt(b),!((b-v+1)%s)&&b<f-s&&(m+=o);t[0]=m}return t[1]=e[1]&&t[1]?i+t[1]:"","0"!==(r=t.join(""))&&""!==r||(n=!1),h+(n?"-":"")+r+x}},Hn(Bn={exports:{}}),Bn.exports);function Vn(e){return e.replace(/[-[\]/{}()*+?.\\^$|]/g,"\\$&")}const Wn={3:"k",6:"M",9:"G",12:"T",15:"P",18:"E",21:"Z",24:"Y","-3":"m","-6":"μ","-9":"n","-12":"p","-15":"f","-18":"a","-21":"z","-24":"y"},Kn=/%\)?$/,Jn=/^\(r(0[2-9]|[12]\d|3[0-6])\)/i,Yn=/^\(oct\)/i,Gn=/^\(dec\)/i,Zn=/^\(hex\)/i,Xn=/^\(bin\)/i,Qn=/^\(rom\)/i,er=/^(\(rom\)|\(bin\)|\(hex\)|\(dec\)|\(oct\)|\(r(0[2-9]|[12]\d|3[0-6])\))/i,tr=/#|0/g;function nr(e,t,n,r){return e=e.toString(t),n[1]===n[1].toUpperCase()&&(e=e.toUpperCase()),e.length-e.indexOf(".")>10&&(e=e.slice(0,e.indexOf(".")+11)),e.replace(".",r||".")}function rr(e,t,n){const r=Vn(e);return n?r:new RegExp(r||"",t)}function ir(e,t,n,r){let i,o,a,l,s,u,c,d,f,p=e.pattern;var h,m;r&&(e.abbreviate=!0),h=t,(m=n)&&(m=Vn(m)),h&&(h=Vn(h)),f=new RegExp("(?:[#0]+".concat(h,")?[#0]+(?:").concat(m,"[#0]+)?")),a=p.match(f),a=a?a[0]:"",l=a?p.substr(0,p.indexOf(a)):p,s=a?p.substring(p.indexOf(a)+a.length):"",a||(a=p?"#":"##########"),t&&t===n&&(i=a.split(n),o=i.pop(),a=i.join("")+n+o,t=""),u=t,t=/,/.test(n)?"¤":",",u&&(a=a.replace(rr(u,"g"),t)),c=n,n=".",c&&(a=a.replace(rr(c,"g"),n)),d=a.match(/#/g),d=d?d.length:0;const g=p.split(c);let v;g[1]&&(v=g[1].match(tr)),e.prefix=l||"",e.postfix=s||"",e.pattern=p,e.maxPrecision=v?v.length:2,e.percentage=Kn.test(p),e.numericPattern=a||"",e.numericRegex=new RegExp("".concat(rr(t,null,!0),"|").concat(rr(n,null,!0)),"g"),e.groupTemp=u,e.decTemp=c,e.t=t,e.d=n,e.temp=d}class or{constructor(e,t,n,r,i){this.localeInfo=e,this.pattern=t,this.thousandDelimiter=n||",",this.decimalDelimiter=r||".",this.type=i||"numeric",this.patternSeparator=";",this.abbreviations=function(e,t){if(!e||!e.qNumericalAbbreviation)return Wn;const n={};return e.qNumericalAbbreviation.split(t).forEach(e=>{let t=e.split(":");2===t.length&&(n[t[0]]=t[1])}),n}(e,this.patternSeparator),this.prepare()}clone(){const e=new or(this.localeInfo,this.pattern,this.thousandDelimiter,this.decimalDelimiter,this.type);return e.subtype=this.subtype,e}format(e,t,n,r){return this.prepare(t,n,r),this.formatValue(e)}prepare(e,t,n){let r;if(void 0===e&&(e=this.pattern),void 0===t&&(t=this.thousandDelimiter),void 0===n&&(n=this.decimalDelimiter),!e)return void(this._prepared={pattern:!1});this._prepared={positive:{d:n,t:t,abbreviate:!1,isFunctional:!1,prefix:"",postfix:""},negative:{d:n,t:t,abbreviate:!1,isFunctional:!1,prefix:"",postfix:""},zero:{d:n,t:t,abbreviate:!1,isFunctional:!1,prefix:"",postfix:""}},r=this._prepared,e=e.split(this.patternSeparator),r.positive.pattern=e[0],r.negative.pattern=e[1],r.zero.pattern=e[2],er.test(e[0])&&(r.positive.isFunctional=!0),e[1]?er.test(e[1])&&(r.negative.isFunctional=!0):r.negative=!1,e[2]?er.test(e[2])&&(r.zero.isFunctional=!0):r.zero=!1;const i="U"===this.type;r.positive.isFunctional||ir(r.positive,t,n,i),r.negative&&!r.negative.isFunctional&&ir(r.negative,t,n,i),r.zero&&!r.zero.isFunctional&&ir(r.zero,t,n,i)}formatValue(e){let t,n,r,i,o,a,l,s,u,c=this._prepared,d="",f="",p=e;if(isNaN(e))return"".concat(p);if(e=+e,!1===c.pattern)return e.toString();if(0===e&&c.zero)return c=c.zero,c.pattern;if(e<0&&c.negative?(c=c.negative,e=-e):c=c.positive,o=c.d,a=c.t,c.isFunctional)e=function(e,t,n){let r;return Jn.test(t)?e=nr(e,Number(/\d{2}/.exec(t)[0]),t,n):Yn.test(t)?e=nr(e,8,t,n):Gn.test(t)?e=nr(e,10,t,n):Zn.test(t)?e=nr(e,16,t,n):Xn.test(t)?e=nr(e,2,t,n):Qn.test(t)&&(r="",e<0&&(r="-",e=-e),0===(e=Math.floor(e))?e="0":e<=5e5?(e=function(e,t){let n,r="",i=Number(String(e).slice(-3)),o=(e-i)/1e3,a=[0,1,4,5,9,10,40,50,90,100,400,500,900].reverse(),l=["0","I","IV","V","IX","X","XL","L","XC","C","CD","D","CM"].reverse();for(;i>0;)for(n=0;n<a.length;n++)if(a[n]<=i){r+=l[n],i-=a[n];break}for(n=0;n<o;n++)r="M".concat(r);return t[1]!==t[1].toUpperCase()&&(r=r.toLowerCase()),r}(e,t),e=r+e):e=t+r+e.toExponential(0)),e}(e,c.pattern,o);else{if(c.percentage&&(e*=100),c.abbreviate){const t=Object.keys(this.abbreviations).map(e=>parseInt(e,10)).sort((e,t)=>e-t);let r,i,o=t[0];for(l=0,n=Number(Number(e).toExponential().split("e")[1]);o<=n&&l<t.length;)l++,o=t[l];l>0&&(r=t[l-1]),r&&n>0&&r>0?i=r:(n<0&&r<0||!r)&&(o<0&&o-n<=c.maxPrecision?i=o:r<=n&&!(o>0&&-n<=c.maxPrecision)&&(i=r)),i&&(d=this.abbreviations[i],e/=10**i)}if(r=Math.abs(e),t=c.temp,s=c.numericPattern,u=s.split(o)[1],"I"===this.type&&(e=Math.round(e)),i=e,u||"#"!==s.slice(-1)[0])if(r>=1e15||r>0&&r<=1e-14)e=r?r.toExponential(15).replace(/\.?0+(?=e)/,""):"0";else{const t=Number((e+1e-15*(e<0?-1:1)).toFixed(Math.min(20,u?u.length:0)).split(".")[0]);let n=s.split(o)[0];if(n+=o,e=Un(n,t)||"0",u){const t=Math.max(0,Math.min(14,u.length)),n=u.replace(/#+$/,"").length;let i=("I"===this.type?0:r%1+1e-15).toFixed(t).slice(2).replace(/0+$/,"");for(l=i.length;l<n;l++)i+="0";i&&(e+=o+i)}else 0===t&&(i=0)}else if(r>=10**t||r<1||r<1e-4)0===e?e="0":r<1e-4||r>=1e20?(e=(e=i.toExponential(Math.max(1,Math.min(14,t))-1)).replace(/\.?0+(?=e)/,""),f=""):(e=e.toPrecision(Math.max(1,Math.min(14,t)))).indexOf(".")>=0&&(e=(e=e.replace(e.indexOf("e")<0?/0+$/:/\.?0+(?=e)/,"")).replace(".",o));else{for(s+=o,t=Math.max(0,Math.min(20,t-Math.ceil(Math.log(r)/Math.log(10)))),l=0;l<t;l++)s+="#";e=Un(s,e)}e=e.replace(c.numericRegex,e=>e===a?c.groupTemp:e===o?c.decTemp:""),i<0&&!/^-/.test(e)&&(e="-".concat(e))}return c.prefix+e+f+d+c.postfix}static getStaticFormatter(){return{prepare(){},formatValue:e=>"".concat(e)}}}function ar(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const{size:n=5e3,multipleArguments:r=!1,toKey:i=e=>e}=t;let o,a,l=Object.create(null),s=Object.create(null),u=0,c=0;return o=r?function(){return a=i(...arguments),o.has(a)?o.get(a):o.set(a,e(...arguments))}:t=>(a=i(t),o.has(a)?o.get(a):o.set(a,e(t))),o.set=(e,t)=>(u>=n&&(delete l[s[c]],delete s[c],u--,c++),l[e]=t,s[u]=e,u++,t),o.get=e=>l[e],o.has=e=>e in l,o.clear=()=>{l=Object.create(null),s=Object.create(null),u=0,c=0},o.size=()=>u,o}function lr(e,t,n,r,i){const o=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return new or(...t)}(i,e,t,n,r),a=ar(o.formatValue.bind(o),{toKey:e=>isNaN(e)?e:+e});function l(e){return a(e)}return l.format=function(e,t,n,r){return a.clear(),o.format(t,e,n,r)},l.pattern=function(e){return e&&(a.clear(),o.pattern=e,o.prepare()),o.pattern},l}const sr="D",ur="T",cr="TS",dr=["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],fr=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"],pr=["January","February","March","April","May","June","July","August","September","October","November","December"],hr=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function mr(e,t){for(let n=e.length;n<t;n++)e="0".concat(e);return e}function gr(e){let t=e.toString().split(".");return t[1]?(t=Number("0.".concat(t[1])),t):0}class vr{constructor(e,t,n){const r=e||{};r.qCalendarStrings||(r.qCalendarStrings={qLongDayNames:dr,qDayNames:fr,qLongMonthNames:pr,qMonthNames:hr}),this.localeInfo=r,this.locale_days=r.qCalendarStrings.qLongDayNames.slice(),this.locale_days_abbr=r.qCalendarStrings.qDayNames.slice(),this.locale_months=r.qCalendarStrings.qLongMonthNames.slice(),this.locale_months_abbr=r.qCalendarStrings.qMonthNames.slice(),t||(t={[ur]:r.qTimeFmt||"hh:mm:ss",[sr]:r.qDateFmt||"YYYY-MM-DD",[cr]:r.qTimestampFmt||"YYYY-MM-DD hh:mm:ss"}[n]),this.pattern=t}clone(){const e=new vr(this.localeInfo,this.pattern);return e.subtype=this.subtype,e}format(e,t){t||(t=this.pattern?this.pattern:"YYYY-MM-DD hh:mm:ss"),t=t.replace(/\[.+]|\[|]/g,"");const n=/t+/gi.test(t);let r;e instanceof Date?r=function(e,t){let n=e.getUTCHours(),r=e.getUTCDay()-1;return t&&(n%=12,n||(n=12)),r<0&&(r=6),{year:e.getUTCFullYear(),month:e.getUTCMonth(),day:r,date:e.getUTCDate(),h:n,m:e.getUTCMinutes(),s:e.getUTCSeconds(),f:e.getUTCMilliseconds(),t:e.getUTCHours()>=12?"pm":"am"}}(e,n):(e<0&&(e=-e,t="-".concat(t)),r=function(e,t){let n,r=function(e){const t=e,n=24*gr(t),r=60*gr(n),i=60*gr(r),o=1e3*gr(i);return{d:Math.floor(t),h:Math.floor(n),m:Math.floor(r),s:Math.floor(i),f:Math.round(o)}}(e),i=r.d,o=r.h,a=r.m,l=r.s,s=r.f,u=0;/w+|t+/gi.test(t)&&(n=new Date(Date.UTC(1899,11,30+Math.floor(e),0,0,Math.round(86400*(e-Math.floor(e))))),isNaN(n.getTime())&&(n=null)),/D+/gi.test(t)||(o+=24*i),/h+/gi.test(t)||(a+=60*o),/m+/gi.test(t)||(l+=60*a),/w+/gi.test(t)&&(u=n?n.getDay()-1:0,u<0&&(u=6));let c="";return n&&(c=n.getUTCHours()>=12?"pm":"am"),{year:0,month:0,day:u,date:i,h:o,m:a,s:l,f:s,t:c}}(e,t));const i=(o=this,a=r,{"Y+|y+":{Y:"".concat(Number("".concat(a.year).slice(-2))),YY:mr("".concat(a.year).slice(-2),2),YYY:mr("".concat(a.year).slice(-3),3),def:e=>mr("".concat(a.year),e.length)},"M+":{M:a.month+1,MM:mr("".concat(a.month+1),2),MMM:o.locale_months_abbr[a.month],def:o.locale_months[a.month]},"W+|w+":{W:a.day,WW:mr("".concat(a.day),2),WWW:o.locale_days_abbr[a.day],def:o.locale_days[a.day]},"D+|d+":{D:a.date,def:e=>mr("".concat(a.date),e.length)},"h+|H+":{h:a.h,def:e=>mr("".concat(a.h),e.length)},"m+":{m:a.m,def:e=>mr("".concat(a.m),e.length)},"s+|S+":{s:a.s,def:e=>mr("".concat(a.s),e.length)},"f+|F+":{def(e){let t="".concat(a.f),n=e.length-t.length;if(n>0)for(let e=0;e<n;e++)t+="0";else n<0&&(t=t.slice(0,e.length));return t}},"t{1,2}|T{1,2}":{def(e){let t=a.t;return e[0].toUpperCase()===e[0]&&(t=t.toUpperCase()),t=t.slice(0,e.length),t}}});var o,a;const l=[];for(const e in i)Object.prototype.hasOwnProperty.call(i,e)&&l.push(e);const s=new RegExp(l.join("|"),"g");return t.replace(s,e=>{let t,n,r;for(n in i)if(Object.prototype.hasOwnProperty.call(i,n)&&(t=new RegExp(n),t.test(e)))break;if(!t)return"";for(const t in i[n])if(t===e||t.toLowerCase()===e){r=i[n][t],void 0===r&&(r=i[n][t.toLowerCase()]);break}return void 0===r&&(r=i[n].def),"function"==typeof r&&(r=r(e)),r})}}function yr(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return new vr(...t)}function br(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"TS",n=yr(arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,e,t),r=ar(n.format.bind(n),{toKey:e=>"object"==typeof e&&"function"==typeof e.getTime?e.getTime():e});function i(e){return"IV"!==t?function(e){return new Date(Date.UTC(1899,11,30+Math.floor(e),0,0,0,Math.round(864e5*(e-Math.floor(e)))))}(e):e}function o(e){return e=i(e),r(e)}return o.format=function(e,t){return r.clear(),t=i(t),n.format(t,e)},o.locale=function(i){return n=yr(i,e,t),r=ar(n.format.bind(n),{toKey:e=>"object"==typeof e?e.getTime():e}),this},o.qtype=function(e){return void 0!==e&&(t=e,r.clear()),t},o}function xr(){let e,{meta:t,id:n,key:r,localeInfo:i,fieldExtractor:o,value:a,type:l,sourceField:s}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const u=a||("dimension"===l?e=>null==e?void 0:e.qElemNo:e=>null==e?void 0:e.qValue),c="dimension"===l?"first":"avg",d=function(e,t){if(e&&e.qNumFormat&&-1!==["D","T","TS","IV"].indexOf(e.qNumFormat.qType))return br(e.qNumFormat.qFmt,e.qNumFormat.qType,t);let n="#",r=t&&void 0!==t.qThousandSep?t.qThousandSep:",",i=t&&void 0!==t.qDecimalSep?t.qDecimalSep:".",o="U",a=e&&!!e.qIsAutoFormat;return e&&e.qNumFormat?(n=e.qNumFormat.qFmt||n,r=e.qNumFormat.qThou||r,i=e.qNumFormat.qDec||i,o=e.qNumFormat.qType||o,a=a&&-1===["M"].indexOf(e.qNumFormat.qType)):a=!0,(a||"U"===o)&&(n="#".concat(i,"##"),o="U"),lr(n,r,i,o,t)}(t,i),f="dimension"===l?"first":(e,t)=>d(t),p={id:()=>n,key:()=>r,raw:()=>t,title:()=>t.qFallbackTitle||t.label,type:()=>l,origin:()=>s,items:()=>(e||(e=o(p)),e),min:()=>t.qMin,max:()=>t.qMax,value:u,label:e=>(null==e?void 0:e.qText)||"",reduce:c,reduceLabel:f,formatter:()=>d,tags:()=>t.qTags};return p}function wr(e,t,n,r,i){return(t[e]||[]).map((t,o)=>{const a="".concat(r?"".concat(r,"/"):"").concat(e,"/").concat(o),l={instance:xr(on({id:"".concat(n?"".concat(n,"/"):"").concat(a),key:a,meta:t},i))};return l.attrDims=wr("qAttrDimInfo",t,n,a,on({},i,{value:e=>null==e?void 0:e.qElemNo,type:"dimension"})),l.attrExps=wr("qAttrExprInfo",t,n,a,on({},i,{value:e=>null==e?void 0:e.qNum,type:"measure"})),l.measures=wr("qMeasureInfo",t,n,a,on({},i,{value:e=>null==e?void 0:e.qValue,type:"measure"})),l})}function qr(){let{key:e,data:t,config:n={}}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const r={fields:[],wrappedFields:[],allFields:[],virtualFields:[]},i=t;if(!i)throw new Error('Missing "data" input');if(!i.qDimensionInfo)throw new Error('The "data" input is not recognized as a hypercube');const o=qr.util,a={cache:r,cube:i,localeInfo:n.localeInfo,fieldExtractor:null,pages:null,hierarchy:()=>null,virtualFields:n.virtualFields},l={key:()=>e,raw:()=>i,field:e=>function(e,t){let{cache:n}=t;if("number"==typeof e)return n.fields[e];const r=n.allFields;if("function"==typeof e){for(let t=0;t<r.length;t++)if(e(r[t]))return r[t];return!1}if("string"==typeof e){for(let t=0;t<r.length;t++)if(r[t].key()===e||r[t].title()===e)return r[t]}else if(e&&-1!==r.indexOf(e))return e;throw Error("Field not found: ".concat(e))}(e,a),fields:()=>r.fields.slice(),extract:e=>a.extractor(e,l,r,o),hierarchy:e=>a.hierarchy(e,l,r,o),_cache:()=>r};"K"===i.qMode||"T"===i.qMode||!i.qMode&&i.qNodesOnDim?(a.extractor=$n,a.hierarchy=_n,a.pages="K"===i.qMode?i.qStackedDataPages:i.qTreeDataPages):"S"===i.qMode?(a.extractor=un,a.pages=i.qDataPages,a.hierarchy=_n):a.extractor=()=>[],a.fieldExtractor=e=>a.extractor({field:e},l,r,o);const s="S"===i.qMode?e=>e.qElemNumber:void 0,u="S"===i.qMode?e=>e.qNum:void 0;r.wrappedFields.push(...wr("qDimensionInfo",i,e,"",on({},a,{value:s,type:"dimension"}))),r.wrappedFields.push(...wr("qMeasureInfo",i,e,"",on({},a,{value:u,type:"measure"}))),r.fields=r.wrappedFields.map(e=>e.instance);const c=e=>{e.forEach(e=>{r.allFields.push(e.instance),c(e.measures),c(e.attrDims),c(e.attrExps)})};return c(r.wrappedFields),(n.virtualFields||[]).forEach(t=>{const n=l.field(t.from),i=xr(Yt({meta:n.raw(),id:"".concat(e,"/").concat(t.key),sourceField:n,fieldExtractor:e=>a.extractor({field:e},l,r,o),key:t.key,type:n.type(),localeInfo:a.localeInfo,value:n.value},t.override||{}));r.virtualFields.push(i)}),r.allFields.push(...r.virtualFields),l}const Dr=[["qHyperCube","qHyperCubeDef"],["qTreeData","qTreeDataDef"],["qDimensionInfo","qDimensions"],["qMeasureInfo","qMeasures"],["qAttrDimInfo","qAttributeDimensions"],["qAttrExprInfo","qAttributeExpressions"]],Sr=/\/qDimensionInfo(?:\/(\d+))?/,kr=/\/qMeasureInfo\/(\d+)/,Cr=/\/qAttrDimInfo\/(\d+)(?:\/(\d+))?/,Mr=/\/qAttrExprInfo\/(\d+)/,Ir=/\/?qHyperCube/,Nr=/\/?qTreeData/,Or=e=>"".concat(e.substr(0,e.indexOf("/qHyperCubeDef")+14)),Er=e=>"".concat(e.substr(0,e.indexOf("/qTreeDataDef")+13));function Rr(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0;const r=t.byCells,i=t.primarySource,o=[],a={},l=e.isActive();let s=!1;return e.brushes().forEach(e=>{const t=function(e,t){let n=e,r=-1,i=-1,o="",a=e=>e;Ir.test(e)?(o="".concat(n.substr(0,n.indexOf("qHyperCube")+10)),a=Or):Nr.test(e)&&(o="".concat(n.substr(0,n.indexOf("qTreeData")+9)),a=Er);let l=!0;if(Sr.test(e)&&(r=+Sr.exec(e)[1]),kr.test(e)&&(i=+kr.exec(e)[1]),Cr.test(e)){i=-1,r=0;const e=+Cr.exec(n)[2];isNaN(e)||(r=e,n=n.replace(/\/\d+$/,"")),l=!1}if(Mr.test(e)){const e=i;if(t){i=0;const a=kn(o,t);i+=(a.qMeasureInfo||[]).length,r>-1?(i=a.qDimensionInfo.slice(0,r).reduce((e,t)=>e+t.qAttrExprInfo.length,i),r=-1):(i=a.qDimensionInfo.reduce((e,t)=>e+t.qAttrExprInfo.length,i),i=a.qMeasureInfo.slice(0,e).reduce((e,t)=>e+t.qAttrExprInfo.length,i)),i+=+Mr.exec(n)[1]}else r>-1?(r=-1,i=+Mr.exec(n)[1]):i+=+Mr.exec(n)[1]+1}return Dr.forEach(e=>{let[t,r]=e;n=n.replace(t,r)}),l&&(n=a(n)),n&&"/"!==n[0]&&(n="/".concat(n)),{measureIdx:i,dimensionIdx:r,path:n}}(e.id,n);if("range"===e.type&&t.measureIdx>-1&&t.dimensionIdx>-1){const n=e.brush.ranges();n.length&&(s=!0,a.multiRangeSelectTreeDataValues||(a.multiRangeSelectTreeDataValues={path:t.path,ranges:[]}),n.forEach(e=>a.multiRangeSelectTreeDataValues.ranges.push({qMeasureIx:t.measureIdx,qDimensionIx:t.dimensionIdx,qRange:{qMin:e.min,qMax:e.max,qMinInclEq:!0,qMaxInclEq:!0}})))}else{if("range"===e.type&&t.measureIdx>-1){const n=e.brush.ranges();n.length&&(s=!0,a.rangeSelectHyperCubeValues||(a.rangeSelectHyperCubeValues={path:t.path,ranges:[]}),n.forEach(e=>a.rangeSelectHyperCubeValues.ranges.push({qMeasureIx:t.measureIdx,qRange:{qMin:e.min,qMax:e.max,qMinInclEq:!0,qMaxInclEq:!0}})))}if("range"===e.type&&t.dimensionIdx>-1){const n=e.brush.ranges();n.length&&(s=!0,a.selectHyperCubeContinuousRange||(a.selectHyperCubeContinuousRange={path:t.path,ranges:[]}),n.forEach(e=>a.selectHyperCubeContinuousRange.ranges.push({qDimIx:t.dimensionIdx,qRange:{qMin:e.min,qMax:e.max,qMinInclEq:!0,qMaxInclEq:!1}})))}if("value"===e.type&&t.dimensionIdx>-1)if(r)if(n&&n.qHyperCube&&("P"===n.qHyperCube.qMode||"T"===n.qHyperCube.qMode||"K"===n.qHyperCube.qMode)){const r=n.qHyperCube,o=r.qNoOfLeftDims,l=r.qEffectiveInterColumnSortOrder.indexOf(t.dimensionIdx);if(a.selectPivotCells||(a.selectPivotCells={path:t.path,cells:[]}),e.id===i||!i){const n=e.brush.values().map(e=>+e).filter(e=>!isNaN(e));(0===o||l>=o)&&o>-1?n.forEach(e=>{a.selectPivotCells.cells.push({qType:"T",qCol:e,qRow:l-o})}):n.forEach(e=>{a.selectPivotCells.cells.push({qType:"L",qCol:t.dimensionIdx,qRow:e})}),s=!!a.selectPivotCells.cells.length}}else a.selectHyperCubeCells||(a.selectHyperCubeCells={path:t.path,cols:[]}),a.selectHyperCubeCells.cols.push(t.dimensionIdx),e.id!==i&&(i||a.selectHyperCubeCells.values)||(a.selectHyperCubeCells.values=e.brush.values().map(e=>+e).filter(e=>!isNaN(e)),s=!!a.selectHyperCubeCells.values.length);else{const n=e.brush.values().map(e=>+e).filter(e=>!isNaN(e));s=!!n.length,o.push({params:[t.path,t.dimensionIdx,n,!1],method:"selectHyperCubeValues"})}}}),!s&&l?[{method:"resetMadeSelections",params:[]}]:(a.rangeSelectHyperCubeValues&&o.push({method:"rangeSelectHyperCubeValues",params:[a.rangeSelectHyperCubeValues.path,a.rangeSelectHyperCubeValues.ranges,[],null===(u=t.orMode)||void 0===u||u]}),a.selectHyperCubeContinuousRange&&o.push({method:"selectHyperCubeContinuousRange",params:[a.selectHyperCubeContinuousRange.path,a.selectHyperCubeContinuousRange.ranges]}),a.selectHyperCubeCells&&o.push({method:"selectHyperCubeCells",params:[a.selectHyperCubeCells.path,a.selectHyperCubeCells.values,a.selectHyperCubeCells.cols]}),a.selectPivotCells&&o.push({method:"selectPivotCells",params:[a.selectPivotCells.path,a.selectPivotCells.cells]}),a.multiRangeSelectTreeDataValues&&o.push({method:"multiRangeSelectTreeDataValues",params:[a.multiRangeSelectTreeDataValues.path,a.multiRangeSelectTreeDataValues.ranges]}),o);var u}function Tr(e){qr.util=e.data("matrix").util,e.data("q",qr),e.formatter("q-number",lr),e.formatter("q-time",br)}function Lr(e){var t=Bt(e.layout||{},e.path.split("/").join("."));if(!t)return!1;var n=t.qIsOneAndOnlyOne;return void 0!==n&&n}function zr(e){var t=e.brush,n=e.colorField,r=e.legendAlias,i=e.useLegendCube,o=void 0!==i&&i;!n||/qAttrDimInfo/.test(n)?(t.removeKeyAlias("attrDim/qDimensionInfo/0"),r&&t.removeKeyAlias(r),t.addKeyAlias("attrDim/qDimensionInfo/0","qHyperCube/".concat(n))):o&&t.addKeyAlias(r,"qHyperCube/".concat(n))}Tr.qBrushHelper=Rr,Tr.selections=Rr;var Pr="Shift";var jr=function(e,t){return t[e]?jr(e+1,t):e},Ar=function(e,t){var n=t.reduce(function(e,t){return e[t]=!0,e},{});return e.reduce(function(e,t,r){var i=jr(r,n);return n[i]=!0,e[r]=i,e},{})};function Fr(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.layout,n=e.filtered,r=void 0===n?{}:n,i=(null==t?void 0:t.qHyperCube)||{},o=i.qDimensionInfo,a=void 0===o?[]:o,l=i.qMeasureInfo,s=void 0===l?[]:l;return{dimensions:Ar(a,r.dimensions||[]),measures:Ar(s,r.measures||[])}}function _r(e){var t=e.selection,n=e.fieldMap,r=t.method,i=t.params;if("selectHyperCubeValues"===r){var o=n.dimensions[i[1]];void 0!==o&&(i[1]=o)}return"selectHyperCubeContinuousRange"===r&&i[1].forEach(function(e){var t=n.dimensions[e.qDimIx];void 0!==t&&(e.qDimIx=t)}),t}var $r=[],Hr=0,Br=function(e){var t=$r.filter(function(e){var t;return null===(t=e.selections)||void 0===t?void 0:t.isActive()});t.length&&("Enter"===e.key?t.forEach(function(e){return e.selections.confirm()}):"Escape"!==e.key&&"Esc"!==e.key||t.forEach(function(e){return e.selections.cancel()}))};function Ur(e){var t=e.chart,n=e.document,r=e.selectionInfo,i=e.eventName,o=e.componentName,a=e.brushName,l=void 0===a?"selection":a,s=e.emit,u=void 0===s?"rangeClear":s,c=r.event===i,d=n.querySelector("[data-key='".concat(o,"-edge-0']"));if(c||!d)return!1;var f=t.component(o);return!!f&&(f.emit(u),"string"==typeof l&&t.brush(l).clear(),f)}var Vr=["chart","document","selections","selectionInfo"],Wr=function(e){e.chart,e.document,e.selections,e.selectionInfo;var t=z(e,Vr);t.clearDiscrete(),t.clearContinuous(),t.clearMinor(),t.clearRange(),t.clearTap(),t.clearLegend()};function Kr(e){var t,n=e.lasso;null!=n&&null!==(t=n.active)&&void 0!==t&&t.call(n)&&(null==n||n.action(!1))}function Jr(e){var t,n=e.chart,r=e.selectionInfo,i=e.selectionActions,o=e.actions,a=void 0===o?{}:o,l=e.selections,s=e.selectionEvents;if(!1===i||!1===s)return function(){};var u=i.reset,c=void 0===u?Kr:u,d=i.clear,f=!1!==d&&function(e){var t=e.clear,n=void 0===t?Wr:t,r=e.selections,i=e.selectionInfo,o=e.chart;return function(){var e=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}).cleared,t={selections:r,selectionInfo:i,chart:o,document:document,cleared:e};return n(L({clearDiscrete:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return function(e){var t=e.selectionInfo,n=e.chart,r=e.document,i=e.eventName,o=void 0===i?"discreteRange":i,a=e.componentName,l=void 0===a?"discrete-range-brush":a,s=e.cleared;return Ur({selectionInfo:t,chart:n,document:r,eventName:void 0!==s&&s?void 0:o,componentName:l,emit:"areaClear",brushName:e.brushName})}(L(L({},t),e))},clearContinuous:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return function(e){var t=e.selectionInfo,n=e.chart,r=e.document,i=e.eventName,o=void 0===i?"continuousRange":i,a=e.componentName,l=void 0===a?"continuous-range-brush":a,s=e.cleared;return Ur({selectionInfo:t,chart:n,document:r,eventName:void 0!==s&&s?void 0:o,componentName:l,brushName:e.brushName})}(L(L({},t),e))},clearMinor:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return function(e){var t=e.selectionInfo,n=e.chart,r=e.document,i=e.componentName,o=void 0===i?"minor-range-brush":i,a=e.eventName,l=void 0===a?"minorRange":a,s=e.cleared,u=void 0!==s&&s,c=e.brushName,d=Ur({selectionInfo:t,chart:n,document:r,eventName:u?void 0:l,componentName:o,brushName:void 0!==c&&c});if(d){var f=d.settings.settings,p=f.scale,h=f.brush,m=n.scale(p).data().fields.map(function(e){return e.id()}),g=n.brush(h),v=g.brushes().filter(function(e){return"range"===e.type&&m.some(function(t){return t===e.id})});g&&v.length&&v.forEach(function(e){g.removeRanges(e.brush.ranges().map(function(t){return{key:e.id,range:t}}))})}}(L(L({},t),e))},clearRange:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return function(e){var t=e.selectionInfo,n=e.chart,r=e.document,i=e.selections,o=e.eventName,a=void 0===o?"xAxis":o,l=e.cleared;Ur({selectionInfo:t,chart:n,document:r,eventName:void 0!==l&&l?void 0:a,componentName:"".concat(a,"-range-brush"),emit:"areaClear",brushName:!1})&&i.clear()}(L(L({},t),e))},clearTap:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return function(e){var t=e.chart,n=e.selectionInfo,r=e.selections,i=e.events,o=void 0===i?["tap"]:i,a=e.brushNames,l=void 0===a?[]:a;if(n&&o.includes(n.event)){var s=n.currentComponent;n.previousComponent!==s&&(r.clear(),l.forEach(function(e){return t.brush(e).end()}))}}(L(L({},t),e))},clearLegend:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return function(e){var t=e.selectionInfo,n=e.chart,r=e.document,i=e.selections,o=e.eventName,a=void 0===o?"legendRange":o,l=e.componentName,s=void 0===l?"legend-range-brush":l,u=e.cleared,c=void 0!==u&&u,d=e.brushName;Ur({selectionInfo:t,chart:n,document:r,eventName:c?void 0:a,componentName:s,brushName:void 0!==d&&d})&&i.clear()}(L(L({},t),e))}},t))}}({clear:d,selections:l,selectionInfo:r,chart:n}),p=function(e){var t=e.chart,n=e.actions,r=e.reset,i=e.clear,o=!1,a={deactivated:function(e){var t=(n||{}).lasso;r({e:e,lasso:void 0!==t&&t})},canceled:function(e){var o=(n||{}).lasso;r({e:e,lasso:void 0!==o&&o}),i({e:e,chart:t,document:document})},cleared:function(e){o||(o=!0,i({e:e,chart:t,document:document,cleared:!0}),o=!1)}};return!1===r&&delete a.deactivated,!1===i&&delete a.cleared,!1===r&&!1===i&&delete a.canceled,a}({chart:n,clear:f,reset:c,actions:a}),h={};Object.entries(p).forEach(function(e){var t=A(e,2),n=t[0],r=t[1];h[n]=function(e,t){return t?function(n){return t({event:n,defaultFunc:e})}:e}(r,s[n])});var m=function(e){var t=e.selectionEvents,n=e.selections,r=e.selectionInfo,i=e.clear,o=e.chart,a=e.document,l=t.start,s={selections:n,selectionInfo:r,chart:o,document:a},u=function(e){return Object.assign(r,e||{})},c=function(e){var t=e.event,n=e.components;return function(){return function(e){var t=e.selectionInfo,n=e.clear,r=e.event,i=e.components,o=void 0===i?[]:i;(0,e.setSelectionInfo)(L(L({},void 0===t?{}:t),{},{event:r,components:o.map(function(e){return e.key}).filter(Boolean)})),n()}({event:t,components:n,clear:i,selectionInfo:r,setSelectionInfo:u})}};return"function"==typeof l?function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];l(L(L({defaultFunc:c({event:e,components:t}),setSelectionInfo:u,clear:i},s),{},{event:e,components:t}))}:function(e){c({event:e,components:arguments.length>1&&void 0!==arguments[1]?arguments[1]:[]})()}}({selectionEvents:s,selections:l,selectionInfo:r,clear:f,chart:n,document:document});return null==a||null===(t=a.select)||void 0===t||t.on("start",m),Object.entries(h).forEach(function(e){var t=A(e,2),n=t[0],r=t[1];null==l||l.on(n,r)}),function(){var e;null==a||null===(e=a.select)||void 0===e||e.removeListener("start",m),Object.entries(h).forEach(function(e){var t=A(e,2),n=t[0],r=t[1];null==l||l.removeListener(n,r)})}}var Yr=[{key:"qHyperCube/qDimensionInfo/0:numeric",includeMax:!1}];function Gr(e){var t=e.chart,n=e.actions,r=e.selections,i=e.picassoQ,o=e.config,a=o.allowSimultaneous,l=void 0!==a&&a,s=o.majorScale,u=void 0===s?void 0:s,c=o.selectionActions,d=void 0===c?{}:c,f=d.clear,p=d.reset,h=o.selectionEvents,m=void 0===h?{deactivated:void 0,canceled:void 0,cleared:void 0,start:void 0}:h,g=o.brushEvents,v=void 0===g?{}:g,y=o.brushName,b=void 0===y?"selection":y,x=o.brushMaxListeners,w=void 0===x?20:x,q=o.brushRanges,D=void 0!==q&&q,S=o.interceptors,k=void 0===S?{}:S,C=o.selectionsFn,M=void 0===C?i.selections:C,I=t.brush(b);if("number"==typeof w&&I.setMaxListeners(w),D){var N=!0===D?Yr:D;I.configure({ranges:N})}var O={canSelect:!0,getIsSelectionLocked:!1,isInnerDimensionLocked:!1,lockedDimensions:[],singleSelectIndex:0,selectionInfo:{colorField:void 0,components:[],event:void 0,currentComponent:void 0,previousComponent:void 0}},E=function(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=t.selections,r=t.brush,i=t.majorScale,o=t.actions,a=t.selectionsFn,l=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).path,s=void 0===l?"/qHyperCubeDef":l;if(!n)return{layout:function(){},filteredFields:function(){},allowSimultaneous:function(){},release:function(){}};var u=++Hr,c=null,d={dimensions:[],measures:[]},f=[],p={};n.on=n.on.bind(n),n.isActive=n.isActive.bind(n),n.addListener=n.addListener.bind(n),n.removeListener=n.removeListener.bind(n);var h=function(e){var t=e.brush,n=e.getConfig;return{interceptor:function(e){var r=t.brushes(),i=n(),o=i.allowSimultaneous,a=i.layout,l=void 0===a?{}:a;r.forEach(function(n){var r,i,a;("range"===n.type||null!==(r=e[0])&&void 0!==r&&r.key&&(null===(i=e[0])||void 0===i?void 0:i.key)!==n.id&&0!==o.indexOf(null===(a=e[0])||void 0===a?void 0:a.key))&&t.clear([])});var s=e.filter(function(e){return-2!==e.value});if(s.length>1){var u=function(e){var t=e.layout,n=void 0===t?{}:t,r=e.values,i=void 0===r?[]:r;if(null==i||!i.length)return[];var o=Array.from(new Set(i.map(function(e){return e.key}))),a=[];return o.forEach(function(e){var t=Lr({layout:n,path:e}),r=i.filter(function(t){return t.key===e}),o=t?[r.pop()]:r;a.push.apply(a,F(o))}),a.filter(Boolean)}({layout:l,values:s});return u}return s},rangeInterceptor:function(e){var r=t.brushes(),i=n().allowSimultaneous;return r.filter(function(e){return"value"===e.type}).length?(t.clear([]),e):(r.forEach(function(n){var r=n.id===e[0].key||i.includes(n.id)&&i.includes(e[0].key);"range"!==n.type||r||t.clear([])}),e)}}}({brush:r,getConfig:function(){return{layout:c,allowSimultaneous:f}}}),m=h.rangeInterceptor,g=h.interceptor;r.intercept("set-ranges",m),r.intercept("toggle-ranges",m),r.intercept("toggle-values",g),r.intercept("set-values",g),r.intercept("add-values",g),r.on("start",function(){return n.begin(s)});var v={activate:function(){},deactivated:function(){return r.end()},cleared:function(){return r.clear()},canceled:function(){return r.end()}};!function(e,t){Object.keys(t).forEach(function(n){e.on(n,t[n])})}(n,v);var y=null==i||null===(e=i.max)||void 0===e?void 0:e.call(i);return null!=o&&o.select?(o.select.on("start",function(){var e;r.start(),"function"==typeof o.select.getBrushOptions&&(p=(e=o.select).getBrushOptions.apply(e,arguments))}),o.select.on("end",function(){var e=a(r,p,c),t=Fr({layout:c,filtered:d});e.forEach(function(e){var r=_r({selection:e,fieldMap:t});(function(e,t,n){if(t&&void 0!==n&&"selectHyperCubeContinuousRange"===e.method){var r=e.params;if(r&&r[1]&&r[1][0]){var i=r[1][0],o=i.qDimIx,a=i.qRange;"undefined"!==o&&a&&!1===a.qMaxInclEq&&a.qMax>=n&&(a.qMaxInclEq=!0)}}})(r,o.select.brushSelectionIncludeMax,y),n.select(r)})})):r.on("update",function(){var e=a(r,p,c),t=Fr({layout:c,filtered:d});e.forEach(function(e){n.select(_r({selection:e,fieldMap:t}))})}),0===$r.length&&document.addEventListener("keyup",Br),$r.push({key:u,selections:n}),{layout:function(e){c=e},filteredFields:function(e){d=e},allowSimultaneous:function(e){f=e},release:function(){c=null;var e=$r.indexOf($r.filter(function(e){return e.key===u})[0]);-1!==e&&$r.splice(e,1),$r.length||document.removeEventListener("keyup",Br),function(e,t){Object.keys(t).forEach(function(n){e.removeListener(n,t[n])})}(n,v)}}}({brush:I,majorScale:u,actions:n,selections:r,picassoQ:i,selectionsFn:M});!function(e){var t=e.brush,n=e.interceptors,r=void 0===n?{}:n;Object.entries(r).forEach(function(e){var n=A(e,2),r=n[0],i=n[1];(Array.isArray(i)?i:[i]).forEach(function(e){t.intercept(r,e)})})}({brush:I,interceptors:k});var R=function(e){var t=e.chart,n=e.selectionActions,r=e.brush,i=e.actions,o=e.selectionInfo,a=e.selections,l=e.selectionEvents,s=function(e){var t=e.brush,n=e.chart,r=e.selectionInfo,i=e.brushEvents,o=void 0===i?{}:i,a=Object.entries(o).map(function(e){var i=A(e,2),o=i[0],a=i[1],l=function(){return a({chart:n,selectionInfo:r})};return t.on(o,l),[o,l]});return function(){a.forEach(function(e){var n=A(e,2),r=n[0],i=n[1];t.removeListener(r,i)})}}({brush:r,chart:t,selectionInfo:o,brushEvents:e.brushEvents}),u=Jr({chart:t,selectionInfo:o,selectionActions:n,actions:i,selections:a,selectionEvents:l}),c=function(e){var t=e.actions;if(null==t||!t.lasso)return function(){};var n=!1,r=function(e){n||e.key!==Pr||(t.lasso.action(!0),n=!0)},i=function(e){e.key===Pr&&(t.lasso.action(!1),n=!1)};return document.addEventListener("keydown",r),document.addEventListener("keyup",i),function(){document.removeEventListener("keydown",r),document.removeEventListener("keyup",i)}}({actions:i});return function(){s(),u(),c()}}({chart:t,brush:I,actions:n,selections:r,selectionInfo:O.selectionInfo,selectionActions:{clear:f,reset:p},selectionEvents:m,brushEvents:v});if(l){var T=!0===l?F(Array(15)).map(function(e,t){return"qHyperCube/qMeasureInfo/".concat(t)}):l;E.allowSimultaneous(T)}return{unbindEvents:R,state:O,picassoSelections:E,brush:I}}var Zr=["colorField","useLegendCube"];function Xr(e){var t=e.chart,n=e.selections,r=e.actions,i=void 0!==r&&r,o=e.config,a=void 0===o?{}:o,l=Gr({chart:t,actions:i,selections:n,picassoQ:Tr,config:a}),s=l.unbindEvents,u=l.state,c=l.picassoSelections,d=l.brush,f=a.custom,p=void 0===f?{}:f,h=a.legendAlias,m=void 0===h?void 0:h,g=a.setBrushAliases,v=void 0===g?zr:g;return{getIsDimensionLocked:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;return u.lockedDimensions[e]},getIsSelectionLocked:function(){var e,t,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return null!==(e=null==n||null===(t=n.isLocked)||void 0===t?void 0:t.call(n))&&void 0!==e?e:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];if(null==e||!e.length)return!1;var t=e.filter(function(e){return"object"===_(e.data)&&Array.isArray(e.data.fields)}).every(function(e){return e.data.fields.every(function(e){var t=e.raw();return!(!t.qLocked&&t.qCardinal)})});return t}(r)},getIsSingleSelect:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:u.singleSelectIndex;return u.singleSelectDimensions[e]},getCanSelect:function(){return u.canSelect},getSelectionsObject:function(){return n},getSelectionInfo:function(){return u.selectionInfo},setLayout:function(e){var t=function(e){var t,n,r,i=e.selections,o=e.picassoSelections,a=e.layout,l={lockedDimensions:[],singleSelectDimensions:[]};null!=i&&null!==(t=i.isModal)&&void 0!==t&&t.call(i)&&i.confirm(),o.layout(a);var s=(null!==(n=null==a?void 0:a.qHyperCube)&&void 0!==n?n:{}).qDimensionInfo,u=void 0===s?[]:s;return l.lockedDimensions=u.map(function(e){return!!e.qLocked}),l.singleSelectDimensions=u.map(function(e,t){return Lr({layout:a,path:"qHyperCube/qDimensionInfo/".concat(t)})}),l.singleSelectIndex=function(e){var t,n=((null==e?void 0:e.qHyperCube)||{}).qDimensionInfo,r=void 0===n?[]:n,i=r.map(function(e,t){var n;return!(e.qLocked||(null===(n=e.qCardinalities)||void 0===n?void 0:n.qHypercubeCardinal)<=1)&&t}).filter(function(e){return"number"==typeof e});return null!==(t=i[0])&&void 0!==t?t:Math.max(r.length-1,0)}(a),l.canSelect=0===u.length||u.some(function(e){return!e.qLocked}),l.dimensionLocked=!(null===(r=u[0])||void 0===r||!r.qLocked),l}({selections:n,picassoSelections:c,layout:e});Object.assign(u,t)},setFilteredFields:function(e){c.filteredFields(e)},setBrushAliases:function(e){var t=e.colorField,n=e.useLegendCube,r=void 0!==n&&n,i=z(e,Zr),o=L({useLegendCube:r,colorField:t,brush:d,legendAlias:m},i);v(L(L({},o),{},{defaultFunc:function(){return zr(o)}}))},destroy:function(){s(),c.release()},custom:L({},p)}}var Qr="'Source Sans Pro', 'Arial', 'sans-serif'",ei="#333333",ti="#595959",ni="#737373",ri="#cccccc",ii="#e6e6e6";function oi(e){var t={};return[].concat(F(e),F([["","","color"],["object","","fontFamily"],["object","axis.label.name","color",ti],["object","axis.label.name","fontFamily",Qr],["object","axis.label.name","fontSize","12px"],["object","axis.line.major","color",ri],["object","axis.line.minor","color",ii],["object","axis.title","color"],["object","axis.title","fontFamily",Qr],["object","axis.title","fontSize","13px"],["object","grid.line.highContrast","color",ii],["object","grid.line.major","color",ri],["object","grid.line.minor","color",ii],["object","label.value","color",ti],["object","label.value","fontFamily",Qr],["object","label.value","fontSize","12px"],[!1,"label.value","darkColor",ti],[!1,"label.value","lightColor",ii],["object","outOfRange","color","#999"],["object","legend.title","color",ei],["object","legend.title","fontFamily",Qr],["object","legend.title","fontSize","15px"],["object","legend.label","color",ti],["object","legend.label","fontFamily",Qr],["object","legend.label","fontSize","13px"],["object","referenceLine.label.name","color",ei],["object","referenceLine.label.name","fontFamily",Qr],["object","referenceLine.label.name","fontSize","12px"],["object","referenceLine.outOfBounds","color",ii],["object","referenceLine.outOfBounds","fontFamily",Qr],["object","referenceLine.outOfBounds","fontSize","12px"],["object","referenceLine.outOfBounds","backgroundColor",ni,function(e){return"transparent"===e?ni:e}]])).reduce(function(e,n){var r="".concat(n[0],"-").concat(n[1],"-").concat(n[2],"}");return t[r]||(t[r]=!0,e.push(n)),e},[]).sort(function(e,t){return(e[0].split?e[0].split(".").length:0)-(t[0].split?t[0].split(".").length:0)})}var ai=function(e){return e};function li(e){var t=e.theme,n=e.id,r=e.transform,i=e.extend,o=e.matrix,a={},l=r.reduce(function(e,t){var n=A(t,2),r=n[0],i=n[1];return e[r]=i,e},{});return o.forEach(function(e){var r=A(e,5),i=r[0],o=r[1],s=r[2],u=r[3],c=r[4],d=void 0===c?function(e){return e}:c,f=function(e){var t=e.theme,n=e.base,r=e.path,i=e.attribute,o=e.defaultValue,a=void 0===o?void 0:o;if(!t||!1===n)return a;var l=t.getStyle(n,r,i);return void 0===l?a:l}({theme:t,base:"object"===i&&n?"".concat("object",".").concat(n):i,path:o,attribute:s,defaultValue:u}),p=(l["".concat(o,".").concat(s)]||ai)(d(f));Vt(a,[o,s].filter(Boolean).join("."),p)}),i.forEach(function(e){var t=A(e,2),n=t[0],r=t[1];Vt(a,n,r)}),a}function si(e,t,n){const r=`${e}.fontFamily`,i=`${e}.fontSize`;return{fontFamilyItem:{component:"dropdown",ref:r,options:()=>t.getOptions(r),defaultValue:()=>t.getDefaultValue(r)},fontWrapperItem:{component:"inline-wrapper",items:{fontSizeItem:{component:"dropdown",ref:i,options:()=>t.getOptions(i),defaultValue:()=>t.getDefaultValue(i)},fontColorItem:{component:"color-picker",width:!1,ref:`${e}.color`,defaultValue:()=>({color:n.getStyle("object.funnelChart",e,"color")})}}}}}function ui(e,t,n){const r=function(e){var t=e.theme,n=e.translator,r=e.config,i=void 0===r?{}:r,o=e.flags,a=function(e){var t=e.config,n=void 0===t?{}:t,r=n.id,i=n.paths;return{id:void 0===r?"object":"".concat("object",".").concat(r),paths:Array.isArray(i)?i:[]}}({config:i}),l=a.id,s=a.paths,u={};s.forEach(function(e){var r=e.split(".");ue(r);for(var i=u,a=0;a<r.length;a++){var s=r[a];a===r.length-1?i[s]=oe({theme:t,translator:n,id:l,path:e,flags:o}):void 0===i[s]&&(i[s]={}),i=i[s]}});var c=function(e){var t=e.split(".");ue(t);for(var n=u,r=0;r<t.length;r++){var i=t[r];if(void 0===n[i])throw new Error("font-resolver: Path '".concat(e,"' could not be resolved."));n=n[i]}return n};return u.getDefaultValue=function(e){return c(e).getDefaultValue()},u.getOptions=function(e){return c(e).getOptions()},u}({theme:e,translator:n,flags:t,config:{id:"funnelChart",paths:["axis.title","axis.label.name","label.value"]}});return{component:"styling-panel",show:!0,chartType:"funnelchart",translation:"LayerStyleEditor.component.styling",chartTitle:"Object.FunnelChart",subtitle:"LayerStyleEditor.component.styling",useGeneral:!0,useBackground:!0,items:{axisTitleSection:{component:"panel-section",label:"Dimension title",items:{dimensionTitleItems:{component:"items",ref:"components",key:"axis",items:si("axis.title",r,e)}}},labelNameSection:{component:"panel-section",label:"Dimension value label",items:{dimensionTitleItems:{component:"items",ref:"components",key:"axis",items:si("axis.label.name",r,e)}}},labelValueSection:{component:"panel-section",label:"Value Label",items:{labelItems:{component:"items",ref:"components",key:"label",items:{...si("label.value",r,e),contrastColor:{component:"checkbox",type:"boolean",ref:"label.value.useContrastColor",translation:"properties.dataPoints.valuelabel.contrast",defaultValue:!0}}}}}}}}const ci={uses:"sorting"},di=(e,t,n)=>{const r=n?.sense?.theme;return{uses:"settings",items:{presentation:{type:"items",label:"Presentation",grouped:!0,items:{funnelStyling:ui(r,t,e),funnelmode:{ref:"funnel.mode",label:"Funnel Mode",type:"string",component:"dropdown",options:[{value:"AREA",label:"Area"},{value:"HEIGHT",label:"Height"},{value:"WIDTH",label:"Width"},{value:"ORDER",label:"Ordering"}],defaultValue:"WIDTH"},dimensionTitle:{ref:"showDimensionTitle",type:"boolean",component:"switch",label:"Dimension title",defaultValue:!0,options:[{value:!0,label:"Auto"},{value:!1,label:"Off"}]},valuesAuto:{ref:"dataPoint.auto",type:"boolean",label:"Value labels",component:"switch",defaultValue:!0,options:[{value:!0,label:"Auto"},{value:!1,label:"Custom"}]},labelMode:{ref:"dataPoint.labelMode",type:"string",component:"dropdown",options:[{value:"none",label:"None"},{value:"share",label:"Share"},{value:"value",label:"Values"}],defaultValue:"share",show:e=>!e.dataPoint.auto}}},colorsAndLegend:{uses:"colorsAndLegend",translation:"Colors",items:{colors:{items:{colorByLabel:{show:!1},expressionLabel:{show:!1}}},legend:{show:!1}}}}}},fi={uses:"data",items:{dimensions:{uses:"dimensions",items:{others:{items:{suppressOther:{defaultValue:!0,show:!1}}}},disabledRef:""},measures:{uses:"measures",disabledRef:""}}};function pi({translator:e,flags:t,anything:n}){return{type:"items",component:"accordion",items:{data:fi,sorting:ci,settings:di(e,t,n)}}}function hi(e){return{definition:pi(e),support:{export:!0,exportData:!0,snapshot:!0,viewData:!1},importProperties:null,exportProperties:null}}const mi=[{path:"/qHyperCubeDef",dimensions:{min:1,max:1,description:()=>"Segments"},measures:{min:1,max:1,description(e){switch(e.funnel.mode){case"WIDTH":return"Width";case"AREA":return"Area";case"HEIGHT":return"Height";case"ORDER":return"Order";default:return""}},added(e,t){2===t.qHyperCubeDef.qInterColumnSortOrder.length&&1!==t.qHyperCubeDef.qInterColumnSortOrder[0]&&(t.qHyperCubeDef.qInterColumnSortOrder=[1,0])}}}];function gi(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var vi,yi;var bi=function(){if(yi)return vi;yi=1;var e=Object.prototype.hasOwnProperty,t=Object.prototype.toString,n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=function(e){return"function"==typeof Array.isArray?Array.isArray(e):"[object Array]"===t.call(e)},o=function(n){if(!n||"[object Object]"!==t.call(n))return!1;var r,i=e.call(n,"constructor"),o=n.constructor&&n.constructor.prototype&&e.call(n.constructor.prototype,"isPrototypeOf");if(n.constructor&&!i&&!o)return!1;for(r in n);return void 0===r||e.call(n,r)},a=function(e,t){n&&"__proto__"===t.name?n(e,t.name,{enumerable:!0,configurable:!0,value:t.newValue,writable:!0}):e[t.name]=t.newValue},l=function(t,n){if("__proto__"===n){if(!e.call(t,n))return;if(r)return r(t,n).value}return t[n]};return vi=function e(){var t,n,r,s,u,c,d=arguments[0],f=1,p=arguments.length,h=!1;for("boolean"==typeof d&&(h=d,d=arguments[1]||{},f=2),(null==d||"object"!=typeof d&&"function"!=typeof d)&&(d={});f<p;++f)if(null!=(t=arguments[f]))for(n in t)r=l(d,n),d!==(s=l(t,n))&&(h&&s&&(o(s)||(u=i(s)))?(u?(u=!1,c=r&&i(r)?r:[]):c=r&&o(r)?r:{},a(d,{name:n,newValue:e(h,c,s)})):void 0!==s&&a(d,{name:n,newValue:s}));return d},vi}(),xi=gi(bi),wi={dataRelatedPropertiesPaths:["qHyperCube.qGrandTotalRow","qHyperCube.qHasOtherValues","qHyperCube.qSize","qHyperCube.qDimensionInfo[].qAttrDimInfo","qHyperCube.qDimensionInfo[].qAttrExprInfo","qHyperCube.qDimensionInfo[].qCardinalities","qHyperCube.qDimensionInfo[].qMax","qHyperCube.qDimensionInfo[].qMin","qHyperCube.qDimensionInfo[].qStateCounts","qHyperCube.qMeasureInfo[].qApprMaxGlyphCount","qHyperCube.qMeasureInfo[].qAttrExprInfo","qHyperCube.qMeasureInfo[].qMax","qHyperCube.qMeasureInfo[].qMin","qHyperCube.qMeasureInfo[].qTrendLines","qHyperCube.qTreeNodesOnDim","qSelectionInfo","plugins[].validMeasureValue","plugins[].labelBackgroundColor","plugins[].labelColor","plugins[].hasBackground","plugins[].maxLabelWidth","plugins[].points[].validMeasureValue","plugins[].points[].labelBackgroundColor","plugins[].points[].labelColor","plugins[].points[].hasBackground","plugins[].points[].maxLabelWidth"]};function qi(e){const{qHyperCube:t,...n}=e,{qAxisData:r,qDataPages:i,qStackedDataPages:o,qTreeDataPages:a,...l}=t,s=xi(!0,{},{...n,qHyperCube:{...l}}),{dataRelatedPropertiesPaths:u}=wi;function c(e,t){const n=t.indexOf("[]");if(-1===n)return void(void 0!==Bt(e,t)&&Vt(e,t,void 0));const r=t.substring(0,n),i=t.substring(n+2),o=i.startsWith(".")?i.substring(1):i;Bt(e,r,[]).forEach(e=>{o&&c(e,o)})}return u.forEach(e=>{c(s,e)}),s}var Di={axes:{trackBy:function({isTime:e,isContinuous:t,isMeasure:n,isMajor:r}){return i=>{if(e||t||n){if("line"===i.type)return i.tickValue??"axis";if("text"===i.type)return`${i.tickValue} ${i.text}`;if("container"===i.type){const e=i.children.filter(e=>"text"===e.type).map(e=>e.text);return`${i.data.value} ${e.join("")}`}return Math.random()}if(r){if("line"===i.type&&void 0===i.tickValue)return"axis";const e=i.transform&&i.transform.match(/rotate/gi)?"rotated":"horizontal";return`${i.data.group?`${i.data.group.value} `:""}${i.data.value} ${i.text} ${e}`}return Math.random()}},compensateForLayoutChanges:function({isMeasure:e,isTime:t,isContinuous:n,isHorizontal:r,dock:i}){return({currentNodes:o,currentRect:a,previousRect:l})=>{const s=a.x-l.x,u=a.y-l.y,c=a.width-l.width,d=a.height-l.height;e?("left"===i&&o.forEach(e=>{"line"===e.type?(e.x1+=c,e.x2+=c):"text"===e.type&&(e.x+=c)}),"left"!==i&&"right"!==i||o.forEach(e=>{"line"===e.type&&(e.x1===e.x2?(e.y1=a.y,e.y2=e.y1+a.height):(Math.round(e.y1)<a.y||e.y1>a.y+a.height)&&(e.strokeWidth=0)),"text"===e.type&&(e.y<a.y||e.y>a.y+a.height)&&(e.fontSize="1px","#"===e.fill?.[0]&&(e.fill=`${e.fill.slice(0,1)}00${e.fill.slice(1)}`))}),"top"!==i&&"bottom"!==i||o.forEach(e=>{"line"===e.type&&(e.y1===e.y2?(e.x1=a.x,e.x2=e.x1+a.width):(Math.round(e.x1)<a.x||e.x1>a.x+a.width)&&(e.strokeWidth=0)),"text"===e.type&&(e.x<a.x||e.x>a.x+a.width)&&(e.fontSize="1px","#"===e.fill?.[0]&&(e.fill=`${e.fill.slice(0,1)}00${e.fill.slice(1)}`))})):t?o.forEach(e=>{"line"===e.type?e.y1===e.y2?e.x2+=c:e.x1===e.x2&&(e.x1-=s,e.x2-=s):"text"===e.type&&(e.x-=s)}):n||r?o.forEach(e=>{"line"===e.type&&e.y1===e.y2&&(e.x1+=s,e.x2+=s+c)}):o.forEach(e=>{"line"===e.type&&e.x1===e.x2&&(e.y1+=u,e.y2+=u+d)})}}},bars:{trackBy:function(e){return e.data.typeIndex?`${e.data.value} ${e.data.typeIndex.value}`:e.data.measureIndex?`${e.data.value} ${e.data.measureIndex.value}`:e.data.group?`${e.data.value} ${e.data.group.value}`:e.data.stack?`${e.data.value} ${e.data.stack.value}`:`${e.data.value}`},compensateForLayoutChanges:function({currentNodes:e,currentRect:t,previousRect:n}){const r=t.x-n.x,i=t.y-n.y;0===r&&0===i||e.forEach(e=>{e.children&&e.children.length>0&&e.children.forEach(e=>{void 0!==e.x&&void 0!==e.y?(e.x-=r,e.y-=i):e.transform=`translate(${-r}, ${-i})`})})}},barOobs:{compensateForLayoutChanges:function({currentNodes:e,currentRect:t,previousRect:n}){const r=t.x-n.x;0===t.y-n.y&&0===r||e.forEach(e=>{e.children&&e.children.length>0&&e.children.forEach(e=>{e.opacity=0})})}},labels:{trackBy:function(e){if("rect"===e.type)return"-3"===e.data?Math.random():`${e.type} ${e.data} ${e.rotation}`;const t=e.transform&&e.transform.match(/rotate/gi)?"rotated":"horizontal";return`${e.type} ${e.data} ${e.text} ${t}`},compensateForLayoutChanges:function({currentNodes:e,currentRect:t,previousRect:n}){const r=t.x-n.x,i=t.y-n.y;0===r&&0===i||e.forEach(e=>{e.transform&&e.transform.match(/rotate\(-90/gi)?(e.x+=i,e.y-=r):(e.x-=r,e.y-=i)})},linkData:function(e){return e.data.measureIndex?`${e.data.value} ${e.data.measureIndex.value}`:e.data.group?`${e.data.value} ${e.data.group.value}`:e.data.stack?`${e.data.value} ${e.data.stack.value}`:`${e.data.value}`}},lines:{trackBy:function(e){return"line"===e.type?e.value??Math.random():"path"===e.type?`${e.generatorType} ${e.layerObj.id} ${e.data.source.key}`:Math.random()},compensateForLayoutChanges:function({currentNodes:e,currentRect:t,previousRect:n}){const r=t.x-n.x,i=t.y-n.y;e.forEach(e=>{if(void 0!==e.x1&&void 0!==e.y1)e.y1===e.y2?(e.x2=e.x1+t.width,e.y1-=i,e.y2-=i):e.x1===e.x2&&(e.y2=e.y1+t.height,e.x1-=r,e.x2-=r);else{const t="x"===e.major.p?r/e.major.size:i/e.major.size,n="y"===e.minor.p?i/e.minor.size:r/e.minor.size;e.points.forEach(e=>{e.modified||(e.major-=t,e.minor-=n,e.minor0-=n,e.modified=!0)})}})}},lineOobs:{compensateForLayoutChanges:function({currentNodes:e,currentRect:t,previousRect:n}){const r=t.x-n.x;0===t.y-n.y&&0===r||e.forEach(e=>{e.opacity=0})}},markers:{trackBy:function(e){return e.data.line?`${e.data.line.value} ${e.data.major.value}`:`${e.data.major.value}`},compensateForLayoutChanges:function({currentNodes:e,currentRect:t,previousRect:n}){const r=t.x-n.x,i=t.y-n.y;0===r&&0===i||e.forEach(e=>{switch(e.type){case"circle":e.cx-=r,e.cy-=i;break;case"rect":e.x-=r,e.y-=i;break;case"path":e.transform=`translate(${-r}, ${-i})`}})}},points:{trackBy:function(e){return e.data.line?`${e.data.line.value} ${e.data.major.value}`:`${e.data.major.value}`},compensateForLayoutChanges:function({currentNodes:e,currentRect:t,previousRect:n}){const r=t.x-n.x,i=t.y-n.y;0===r&&0===i||e.forEach(e=>{"image"===e.type?(e.x-=r,e.y-=i):(e.cx-=r,e.cy-=i)})}},refLineLabels:{trackBy:function(e){if(void 0!==e.value){if("rect"===e.type)return`${e.value}`;if("text"===e.type)return`${e.value} ${e.text}`}return Math.random()},compensateForLayoutChanges:function({currentNodes:e,currentRect:t,previousRect:n}){const r=t.x-n.x,i=t.y-n.y,o=t.width-n.width,a=t.height-n.height;let l=-r,s=-i;e.forEach(e=>{switch(e.dock){case"right":r>0&&(l=t.width);break;case"left":o<0&&(l=-n.width);break;case"top":a<0&&(s=-n.height);break;case"bottom":i>0&&(s=t.height)}switch(e.type){case"text":case"rect":e.x+=l,e.y+=s;break;case"circle":e.cx+=l,e.cy+=s;break;case"path":e.transform=`translate(${l}, ${s})`}})}},shadowBars:{trackBy:function(){return Math.random()}},cacheProperties:function({viewCache:e,layout:t}){const n=qi(t);e.set("dataIndependentProperties",JSON.stringify(n))},propertiesHaveChanged:function({viewCache:e,layout:t}){const n=qi(t);return e.get("dataIndependentProperties")!==JSON.stringify(n)},nonUpdatingNode:{trackBy:function(){return Math.random()}}};function Si(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function ki(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function Ci(){}[["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}]].forEach(([e,{width:t,height:n}])=>{});var Mi=.7,Ii=1/Mi,Ni="\\s*([+-]?\\d+)\\s*",Oi="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Ei="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",Ri=/^#([0-9a-f]{3,8})$/,Ti=new RegExp(`^rgb\\(${Ni},${Ni},${Ni}\\)$`),Li=new RegExp(`^rgb\\(${Ei},${Ei},${Ei}\\)$`),zi=new RegExp(`^rgba\\(${Ni},${Ni},${Ni},${Oi}\\)$`),Pi=new RegExp(`^rgba\\(${Ei},${Ei},${Ei},${Oi}\\)$`),ji=new RegExp(`^hsl\\(${Oi},${Ei},${Ei}\\)$`),Ai=new RegExp(`^hsla\\(${Oi},${Ei},${Ei},${Oi}\\)$`),Fi={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 _i(){return this.rgb().formatHex()}function $i(){return this.rgb().formatRgb()}function Hi(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=Ri.exec(e))?(n=t[1].length,t=parseInt(t[1],16),6===n?Bi(t):3===n?new Wi(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===n?Ui(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===n?Ui(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=Ti.exec(e))?new Wi(t[1],t[2],t[3],1):(t=Li.exec(e))?new Wi(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=zi.exec(e))?Ui(t[1],t[2],t[3],t[4]):(t=Pi.exec(e))?Ui(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=ji.exec(e))?Xi(t[1],t[2]/100,t[3]/100,1):(t=Ai.exec(e))?Xi(t[1],t[2]/100,t[3]/100,t[4]):Fi.hasOwnProperty(e)?Bi(Fi[e]):"transparent"===e?new Wi(NaN,NaN,NaN,0):null}function Bi(e){return new Wi(e>>16&255,e>>8&255,255&e,1)}function Ui(e,t,n,r){return r<=0&&(e=t=n=NaN),new Wi(e,t,n,r)}function Vi(e){return e instanceof Ci||(e=Hi(e)),e?new Wi((e=e.rgb()).r,e.g,e.b,e.opacity):new Wi}function Wi(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}function Ki(){return`#${Zi(this.r)}${Zi(this.g)}${Zi(this.b)}`}function Ji(){const e=Yi(this.opacity);return`${1===e?"rgb(":"rgba("}${Gi(this.r)}, ${Gi(this.g)}, ${Gi(this.b)}${1===e?")":`, ${e})`}`}function Yi(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Gi(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Zi(e){return((e=Gi(e))<16?"0":"")+e.toString(16)}function Xi(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new eo(e,t,n,r)}function Qi(e){if(e instanceof eo)return new eo(e.h,e.s,e.l,e.opacity);if(e instanceof Ci||(e=Hi(e)),!e)return new eo;if(e instanceof eo)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,l=o-i,s=(o+i)/2;return l?(a=t===o?(n-r)/l+6*(n<r):n===o?(r-t)/l+2:(t-n)/l+4,l/=s<.5?o+i:2-o-i,a*=60):l=s>0&&s<1?0:a,new eo(a,l,s,e.opacity)}function eo(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function to(e){return(e=(e||0)%360)<0?e+360:e}function no(e){return Math.max(0,Math.min(1,e||0))}function ro(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}Si(Ci,Hi,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:_i,formatHex:_i,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return Qi(this).formatHsl()},formatRgb:$i,toString:$i}),Si(Wi,function(e,t,n,r){return 1===arguments.length?Vi(e):new Wi(e,t,n,null==r?1:r)},ki(Ci,{brighter(e){return e=null==e?Ii:Math.pow(Ii,e),new Wi(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=null==e?Mi:Math.pow(Mi,e),new Wi(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new Wi(Gi(this.r),Gi(this.g),Gi(this.b),Yi(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:Ki,formatHex:Ki,formatHex8:function(){return`#${Zi(this.r)}${Zi(this.g)}${Zi(this.b)}${Zi(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:Ji,toString:Ji})),Si(eo,function(e,t,n,r){return 1===arguments.length?Qi(e):new eo(e,t,n,null==r?1:r)},ki(Ci,{brighter(e){return e=null==e?Ii:Math.pow(Ii,e),new eo(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=null==e?Mi:Math.pow(Mi,e),new eo(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 Wi(ro(e>=240?e-240:e+120,i,r),ro(e,i,r),ro(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new eo(to(this.h),no(this.s),no(this.l),Yi(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=Yi(this.opacity);return`${1===e?"hsl(":"hsla("}${to(this.h)}, ${100*no(this.s)}%, ${100*no(this.l)}%${1===e?")":`, ${e})`}`}}));const io=Math.PI/180,oo=180/Math.PI,ao=.96422,lo=.82521,so=4/29,uo=6/29,co=3*uo*uo,fo=uo*uo*uo;function po(e){if(e instanceof ho)return new ho(e.l,e.a,e.b,e.opacity);if(e instanceof xo)return wo(e);e instanceof Wi||(e=Vi(e));var t,n,r=yo(e.r),i=yo(e.g),o=yo(e.b),a=mo((.2225045*r+.7168786*i+.0606169*o)/1);return r===i&&i===o?t=n=a:(t=mo((.4360747*r+.3850649*i+.1430804*o)/ao),n=mo((.0139322*r+.0971045*i+.7141733*o)/lo)),new ho(116*a-16,500*(t-a),200*(a-n),e.opacity)}function ho(e,t,n,r){this.l=+e,this.a=+t,this.b=+n,this.opacity=+r}function mo(e){return e>fo?Math.pow(e,1/3):e/co+so}function go(e){return e>uo?e*e*e:co*(e-so)}function vo(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function yo(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function bo(e,t,n,r){return 1===arguments.length?function(e){if(e instanceof xo)return new xo(e.h,e.c,e.l,e.opacity);if(e instanceof ho||(e=po(e)),0===e.a&&0===e.b)return new xo(NaN,0<e.l&&e.l<100?0:NaN,e.l,e.opacity);var t=Math.atan2(e.b,e.a)*oo;return new xo(t<0?t+360:t,Math.sqrt(e.a*e.a+e.b*e.b),e.l,e.opacity)}(e):new xo(e,t,n,null==r?1:r)}function xo(e,t,n,r){this.h=+e,this.c=+t,this.l=+n,this.opacity=+r}function wo(e){if(isNaN(e.h))return new ho(e.l,0,0,e.opacity);var t=e.h*io;return new ho(e.l,Math.cos(t)*e.c,Math.sin(t)*e.c,e.opacity)}Si(ho,function(e,t,n,r){return 1===arguments.length?po(e):new ho(e,t,n,null==r?1:r)},ki(Ci,{brighter(e){return new ho(this.l+18*(null==e?1:e),this.a,this.b,this.opacity)},darker(e){return new ho(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 Wi(vo(3.1338561*(t=ao*go(t))-1.6168667*(e=1*go(e))-.4906146*(n=lo*go(n))),vo(-.9787684*t+1.9161415*e+.033454*n),vo(.0719453*t-.2289914*e+1.4052427*n),this.opacity)}})),Si(xo,bo,ki(Ci,{brighter(e){return new xo(this.h,this.c,this.l+18*(null==e?1:e),this.opacity)},darker(e){return new xo(this.h,this.c,this.l-18*(null==e?1:e),this.opacity)},rgb(){return wo(this).rgb()}}));var qo,Do,So={isDark:function(e){return bo(e).l<70}};function ko(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}1===(qo=ko).length&&(Do=qo,qo=function(e,t){return ko(Do(e),t)});var Co="$";function Mo(){}function Io(e,t){var n=new Mo;if(e instanceof Mo)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 No(){}Mo.prototype=Io.prototype={constructor:Mo,has:function(e){return Co+e in this},get:function(e){return this[Co+e]},set:function(e,t){return this[Co+e]=t,this},remove:function(e){var t=Co+e;return t in this&&delete this[t]},clear:function(){for(var e in this)e[0]===Co&&delete this[e]},keys:function(){var e=[];for(var t in this)t[0]===Co&&e.push(t.slice(1));return e},values:function(){var e=[];for(var t in this)t[0]===Co&&e.push(this[t]);return e},entries:function(){var e=[];for(var t in this)t[0]===Co&&e.push({key:t.slice(1),value:this[t]});return e},size:function(){var e=0;for(var t in this)t[0]===Co&&++e;return e},empty:function(){for(var e in this)if(e[0]===Co)return!1;return!0},each:function(e){for(var t in this)t[0]===Co&&e(this[t],t.slice(1),this)}};var Oo=Io.prototype;No.prototype={constructor:No,has:Oo.has,add:function(e){return this[Co+(e+="")]=e,this},remove:Oo.remove,clear:Oo.clear,values:Oo.keys,size:Oo.size,empty:Oo.empty,each:Oo.each},xi.bind(null,!0);const Eo=[[2,4,6],[2,4],[3]],Ro=[,[,,[[1,2]],[[1,2,3],[1,3]],[[1,2,4],[1,4]],[[1,2,4],[1,5]],[[1,2,4,6],[2,4,6],[1,3,6],[1,6]],[[1,2,4,6],[2,4,6],[1,3,6],[1,7]],[[1,2,4,8],[2,4,8],[1,8]],[[1,2,4,8],[2,4,8],[1,3,9],[1,9]],[[1,2,4,6,10],[1,2,4,10],[1,3,10],[3,10],[1,10]]],[,,,[[2,3]],[[2,3,4],[2,4]],[[2,3,4],[2,4],[2,5]],[[2,4,6],[2,6]],[[2,4,6],[2,6],[2,7]],[[2,4,8],[2,8]],[[2,4,8],[2,8],[2,9]],[[2,4,6,10],[2,4,10],[5,10],[3,10]]],[,,,,[[3,4]],[[3,4,5],[3,5]],[[3,4,5,6],[3,6]],[[3,4,5,6],[3,5,7],[3,7]],[[3,4,5,6,8],[3,5,7],[4,8],[3,8]],[[3,4,5,6,8],[3,4,6,9],[3,4,6,8],[3,6,9],[4,8],[3,9]],[[4,6,10],[5,10],[3,10]]],[,,,,,[[4,5]],[[4,5,6],[4,6]],[[4,5,6,7],[4,5,6],[4,6]],[[4,5,6,7,8],[4,5,6,7],[4,6,8],[4,8]],[[4,5,6,7,8],[4,6,9],[4,6,8],[4,8]],[[4,6,10],[5,7,9],[5,10],[4,10]]],[,,,,,,[[5,6]],[[5,6,7],[5,7]],[[5,6,7,8],[5,6,7],[6,8]],[[5,6,7,8,9],[5,6,7,8],[5,7,9],[5,9]],[[6,8,10],[5,10]]],[,,,,,,,[[6,7]],[[6,7,8],[6,8]],[[6,7,8,9],[6,7,8],[6,9]],[[6,7,8,9,10],[6,8,10],[6,10]]],[,,,,,,,,[[7,8]],[[7,8,9],[7,9]],[[7,8,9,10],[8,10],[7,10],[7,9]]],[,,,,,,,,,[[8,9]],[[8,9,10],[8,10]]],[,,,,,,,,,,[[9,10]]]];function To(e,t,n){const r=e?e.length:0;let i,o=void 0===t?Number.MAX_VALUE:e[0]/t;for(i=1;i<r;i++)o=Math.min(o,e[i]/e[i-1]);void 0!==n&&(o=Math.min(o,n/e[r-1])),e.splice(0,0,o)}function Lo(e,t,n){let r;const i=e?e.length:0;for(r=0;r<i;r++)To(e[r],t,n)}function zo(){return/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)?void 0:"svg"}!function(){let e,t;for(Lo(Eo,1,10),e=0;e<Ro.length;e++)if(Ro[e])for(t=0;t<Ro[e].length;t++)Array.isArray(Ro[e][t])&&Lo(Ro[e][t])}();var Po=class e{constructor(e,t){this._key=e,this._value=t}getKey(){return this._key}getValue(){return this._value}equals(t){return t instanceof e&&(this._key===t._key&&this._value===t._value)}static newInstanceIfNeeded(){let t,n,r=arguments[0];return"string"==typeof arguments[1]?(t=arguments[1],n=r.length):(n=arguments[1],t=arguments[2]),t&&r?(r.length>n&&(r=r.substr(0,n)),new e(r,t)):null}},jo=class e{setValue(e){this._nextMap=null,this._value=e}getNextNode(e){return this._nextMap?this._nextMap[e]:null}put(t,n,r){let i,o;if(t.length===n)return o=this._value,this.setValue(r),o;const a=t.charAt(n);return this._nextMap?(i=this._nextMap[a],i||(i=new e,this._nextMap[a]=i)):(this._nextMap={},i=new e,this._nextMap[a]=i),i.put(t,n+1,r)}get(e,t){if(e.length<=t)return this._value;const n=this.getNextNode(e.charAt(t));return n?n.get(e,t+1):null}getLongestMatch(e,t){if(e.length<=t)return Po.newInstanceIfNeeded(e,this._value);const n=this.getNextNode(e.charAt(t));if(!n)return Po.newInstanceIfNeeded(e,t,this._value);const r=n.getLongestMatch(e,t+1);return r||Po.newInstanceIfNeeded(e,t,this._value)}},Ao=class{constructor(){this.clear()}getLongestMatch(e){return this.root&&e?this.root.getLongestMatch(e,0):null}getMaxKeyLength(){return this.maxKeyLen}clear(){this.root=null,this.maxKeyLen=0,this.size=0}put(e,t){this.root||(this.root=new jo);const n=this.root.put(e,0,t);return n||(e.length>this.maxKeyLen&&(this.maxKeyLen=e.length),this.size++,null)}};(()=>{const e=[],t=[],n=new Ao;let r,i,o;for(r in e["""]="34",e["&"]="38",e["<"]="60",e[">"]="62",e[" "]="160",e["¡"]="161",e["¢"]="162",e["£"]="163",e["¤"]="164",e["¥"]="165",e["¦"]="166",e["§"]="167",e["¨"]="168",e["©"]="169",e["ª"]="170",e["«"]="171",e["¬"]="172",e["­"]="173",e["®"]="174",e["¯"]="175",e["°"]="176",e["±"]="177",e["²"]="178",e["³"]="179",e["´"]="180",e["µ"]="181",e["¶"]="182",e["·"]="183",e["¸"]="184",e["¹"]="185",e["º"]="186",e["»"]="187",e["¼"]="188",e["½"]="189",e["¾"]="190",e["¿"]="191",e["À"]="192",e["Á"]="193",e["Â"]="194",e["Ã"]="195",e["Ä"]="196",e["Å"]="197",e["Æ"]="198",e["Ç"]="199",e["È"]="200",e["É"]="201",e["Ê"]="202",e["Ë"]="203",e["Ì"]="204",e["Í"]="205",e["Î"]="206",e["Ï"]="207",e["Ð"]="208",e["Ñ"]="209",e["Ò"]="210",e["Ó"]="211",e["Ô"]="212",e["Õ"]="213",e["Ö"]="214",e["×"]="215",e["Ø"]="216",e["Ù"]="217",e["Ú"]="218",e["Û"]="219",e["Ü"]="220",e["Ý"]="221",e["Þ"]="222",e["ß"]="223",e["à"]="224",e["á"]="225",e["â"]="226",e["ã"]="227",e["ä"]="228",e["å"]="229",e["æ"]="230",e["ç"]="231",e["è"]="232",e["é"]="233",e["ê"]="234",e["ë"]="235",e["ì"]="236",e["í"]="237",e["î"]="238",e["ï"]="239",e["ð"]="240",e["ñ"]="241",e["ò"]="242",e["ó"]="243",e["ô"]="244",e["õ"]="245",e["ö"]="246",e["÷"]="247",e["ø"]="248",e["ù"]="249",e["ú"]="250",e["û"]="251",e["ü"]="252",e["ý"]="253",e["þ"]="254",e["ÿ"]="255",e["&OElig"]="338",e["&oelig"]="339",e["&Scaron"]="352",e["&scaron"]="353",e["&Yuml"]="376",e["&fnof"]="402",e["&circ"]="710",e["&tilde"]="732",e["&Alpha"]="913",e["&Beta"]="914",e["&Gamma"]="915",e["&Delta"]="916",e["&Epsilon"]="917",e["&Zeta"]="918",e["&Eta"]="919",e["&Theta"]="920",e["&Iota"]="921",e["&Kappa"]="922",e["&Lambda"]="923",e["&Mu"]="924",e["&Nu"]="925",e["&Xi"]="926",e["&Omicron"]="927",e["&Pi"]="928",e["&Rho"]="929",e["&Sigma"]="931",e["&Tau"]="932",e["&Upsilon"]="933",e["&Phi"]="934",e["&Chi"]="935",e["&Psi"]="936",e["&Omega"]="937",e["&alpha"]="945",e["&beta"]="946",e["&gamma"]="947",e["&delta"]="948",e["&epsilon"]="949",e["&zeta"]="950",e["&eta"]="951",e["&theta"]="952",e["&iota"]="953",e["&kappa"]="954",e["&lambda"]="955",e["&mu"]="956",e["&nu"]="957",e["&xi"]="958",e["&omicron"]="959",e["&pi"]="960",e["&rho"]="961",e["&sigmaf"]="962",e["&sigma"]="963",e["&tau"]="964",e["&upsilon"]="965",e["&phi"]="966",e["&chi"]="967",e["&psi"]="968",e["&omega"]="969",e["&thetasym"]="977",e["&upsih"]="978",e["&piv"]="982",e["&ensp"]="8194",e["&emsp"]="8195",e["&thinsp"]="8201",e["&zwnj"]="8204",e["&zwj"]="8205",e["&lrm"]="8206",e["&rlm"]="8207",e["&ndash"]="8211",e["&mdash"]="8212",e["&lsquo"]="8216",e["&rsquo"]="8217",e["&sbquo"]="8218",e["&ldquo"]="8220",e["&rdquo"]="8221",e["&bdquo"]="8222",e["&dagger"]="8224",e["&Dagger"]="8225",e["&bull"]="8226",e["&hellip"]="8230",e["&permil"]="8240",e["&prime"]="8242",e["&Prime"]="8243",e["&lsaquo"]="8249",e["&rsaquo"]="8250",e["&oline"]="8254",e["&frasl"]="8260",e["&euro"]="8364",e["&image"]="8365",e["&weierp"]="8472",e["&real"]="8476",e["&trade"]="8482",e["&alefsym"]="8501",e["&larr"]="8592",e["&uarr"]="8593",e["&rarr"]="8594",e["&darr"]="8595",e["&harr"]="8596",e["&crarr"]="8629",e["&lArr"]="8656",e["&uArr"]="8657",e["&rArr"]="8658",e["&dArr"]="8659",e["&hArr"]="8660",e["&forall"]="8704",e["&part"]="8706",e["&exist"]="8707",e["&empty"]="8709",e["&nabla"]="8711",e["&isin"]="8712",e["¬in"]="8713",e["&ni"]="8715",e["&prod"]="8719",e["&sum"]="8721",e["&minus"]="8722",e["&lowast"]="8727",e["&radic"]="8730",e["&prop"]="8733",e["&infin"]="8734",e["&ang"]="8736",e["&and"]="8743",e["&or"]="8744",e["&cap"]="8745",e["&cup"]="8746",e["&int"]="8747",e["&there4"]="8756",e["&sim"]="8764",e["&cong"]="8773",e["&asymp"]="8776",e["&ne"]="8800",e["&equiv"]="8801",e["&le"]="8804",e["&ge"]="8805",e["&sub"]="8834",e["&sup"]="8835",e["&nsub"]="8836",e["&sube"]="8838",e["&supe"]="8839",e["&oplus"]="8853",e["&otimes"]="8855",e["&perp"]="8869",e["&sdot"]="8901",e["&lceil"]="8968",e["&rceil"]="8969",e["&lfloor"]="8970",e["&rfloor"]="8971",e["&lang"]="9001",e["&rang"]="9002",e["&loz"]="9674",e["&spades"]="9824",e["&clubs"]="9827",e["&hearts"]="9829",e["&diams"]="9830",e)"function"!=typeof e[r]&&e.hasOwnProperty(r)&&(t[e[r]]=r);for(i in t)"function"!=typeof t[i]&&t.hasOwnProperty(i)&&(o=t[i].toLowerCase().substr(1),n.put(o,String.fromCharCode(i)))})(),"undefined"!=typeof document&&document.createElement("div");for(let e=0;e<255;e++)e>=48&&e<=57||e>=65&&e<=90||e>=97&&e<=122||e.toString(16);function Fo(e){const t=e.node.desc&&e.node.desc.share;return t?e.formatter("share")(t):""}function _o(e){return e.formatter("num")(e.node.data.num.value)}function $o({data:e}){return e?e.label:""}function Ho(e){if(e.dataPoint.auto)return Fo;switch(e.dataPoint.labelMode){case"share":default:return Fo;case"value":return _o;case"none":return null}}function Bo(e,t,n,r){const i=r.axis.label.getStyle(),o=r.label.value.getStyle(),a=t.getStyles().label.value;return{type:"labels",key:"funnel-labels",renderer:zo(),layout:{displayOrder:2},settings:{sources:[{component:"fun",selector:".labelLeft",strategy:{type:"rows",settings:{align:0,fill:i.fill,fontSize:parseInt(i.fontSize,10),fontFamily:i.fontFamily,labels:[{label:$o}],linkData:e=>`${e.data.value} ${$o(e)}`}}},{component:"fun",selector:".labelCenter",strategy:{type:"rows",settings:{align:.5,fill:o.useContrastColor?({node:e})=>(e=>So.isDark(e.desc.fill)?a.lightColor:a.darkColor)(e):o.fill,fontSize:parseInt(o.fontSize,10),fontFamily:o.fontFamily,labels:[{label:Ho(e)}],linkData:t=>"none"===e.dataPoint.labelMode?Math.random():`${t.data.value} ${Ho(e)(t)}`}}}]},animations:{enabled:n,trackBy:e=>e.data}}}function Uo(e,t){if(!e.showDimensionTitle||!e.qHyperCube.qDimensionInfo[0].qFallbackTitle)return!1;const n=e.qHyperCube.qDimensionInfo[0].qFallbackTitle,r=t.axis.title.getStyle();return{type:"text",key:"dimension-title",renderer:zo(),text:n,layout:{dock:"top"},style:{text:{fill:r.fill,fontSize:r.fontSize,fontFamily:r.fontFamily}}}}function Vo({picasso:e}){const t=c(),y=d(),b=f(),x=p(),w=h(),q=m().qLocaleInfo,[D,S,k,C]=function({picasso:e}){const t=n(),c=r(),d=i(),f=o(),p=a(),h=l(),[m,g]=s(),[v,y]=s(),[b,x]=s(),[w,q]=s();return u(()=>{const n=_t({picasso:e,model:d,app:f,translator:p,config:{auto:!1,key:"fill"}});t.style.overflow="hidden";const r=e({renderer:{prio:[h.renderer||"svg"]}}).chart({element:t,data:[],settings:{}}),i=Xr({chart:r,selections:c,config:{selectionActions:!1}});return x(i),y(n),g(r),q(function(){var e={};return{get:function(t){return e[t]},set:function(t,n){return e[t]=n,n},has:function(t){return t in e},remove:function(t){delete e[t]},empty:function(){e={}}}}()),()=>{i.destroy(),r.destroy()}},[]),[m,v,b,w]}({picasso:e}),M=l(),I=()=>{const e=D.element.clientWidth!==C.get("width")||D.element.clientHeight!==C.get("height");return!1!==M.chartAnimations&&!e&&!Di.propertiesHaveChanged({viewCache:C,layout:t})},[N]=g(()=>{if(!S)return Promise.resolve();const n=function(e){return{layout:e,keys:{SCALE:{FILL:"fill"},COMPONENT:{FUNNEL:"fun",FUNNEL_LABELS:"funnel-labels",DIMENSION_TITLE:"dimension-title"}}}}(t),r=function(e){var t=e.picassoInstance,n=e.plugins,r=e.pluginArgs,i=void 0===r?{}:r,o={initialized:!1,definitions:[]};return{initialize:function(){return E(P().m(function e(){var r,a,l,s;return P().w(function(e){for(;;)switch(e.n){case 0:if(!o.initialized){e.n=1;break}return e.a(2);case 1:return a=Promise.all(n.filter(function(e){return"custom-component"===e.info.type}).map(function(){var e=E(P().m(function e(n){var r;return P().w(function(e){for(;;)switch(e.n){case 0:if(n.info.componentName){e.n=1;break}throw new Error("plugin-service: Custom component is missing componentName");case 1:return e.n=2,n.fn(L({},i));case 2:if("object"===_(r=e.v)){e.n=3;break}throw new Error("plugin-service: Custom component needs to be an object");case 3:t.component(n.info.componentName,r);case 4:return e.a(2)}},e)}));return function(t){return e.apply(this,arguments)}}())),l=Promise.all(n.filter(function(e){return"component-definition"===e.info.type}).map(function(e){return e.fn(L({},i))})),e.n=2,Promise.all([a,l]);case 2:s=e.v,o.initialized=!0,(r=o.definitions).push.apply(r,F(s[1]));case 3:return e.a(2)}},e)}))()},extendComponents:function(e){return o.initialized?(o.definitions.filter(Boolean).forEach(function(t){var n=A(e.filter(function(e){return e.key&&e.key===t.key}),1)[0];if(n){var r=fe(!0,{},n.brush);fe(!0,n,t),t.brush&&(n.brush=function(e,t){return"object"===_(e)&&Object.keys(e).length?(Array.isArray(t.consume)&&(e.consume=Wt({originalArray:e.consume,newArray:t.consume,matchKey:"context"})),Array.isArray(t.trigger)&&(e.trigger=Wt({originalArray:e.trigger,newArray:t.trigger,matchKey:"on"})),e):t}(r,t.brush))}else e.push(t)}),e):e}}}({picassoInstance:e,plugins:w,pluginArgs:n});return Promise.all([S.initialize({createConfig:({getUseBaseColors:e})=>({theme:y,colorProps:{...t.color,useBaseColors:e(t)},layout:t,hc:t.qHyperCube})}),r.initialize()]).then(()=>r)},[t,S]);u(()=>{if(!D||!S||!N)return;const e=[{type:"q",key:"qHyperCube",data:t.qHyperCube,config:{localeInfo:q}},...S.getData()],n=function(e){var t=e.theme,n=e.config,r=void 0===n?{}:n,i=r.id,o=r.resolve,a=void 0===o?[]:o,l=r.transform,s=void 0===l?[]:l,u=r.extend,c=void 0===u?[]:u,d={theme:t,matrix:oi(a),styles:void 0};return d.styles=li({theme:t,id:i,transform:s,extend:c,matrix:d.matrix}),{getStyles:function(){return d.styles},getTheme:function(){return d.theme},setTheme:function(e){d.theme=e,d.styles=li({theme:e,id:i,transform:s,extend:c,matrix:d.matrix})}}}({theme:y,config:{id:"funnelChart"}}),r=function({layout:e,themeService:t}){const n=t.getStyles(),r=t=>e.components?.find(e=>e.key===t)??void 0;return{axis:{title:{getStyle:()=>({fontFamily:r("axis")?.axis?.title?.fontFamily??n.axis.title.fontFamily,fontSize:r("axis")?.axis?.title?.fontSize??n.axis.title.fontSize,fill:r("axis")?.axis?.title?.color?.color??n.axis.title.color})},label:{getStyle:()=>({fontSize:r("axis")?.axis?.label?.name?.fontSize??n.axis.label.name.fontSize,fontFamily:r("axis")?.axis?.label?.name?.fontFamily??n.axis.label.name.fontFamily,fill:r("axis")?.axis?.label?.name?.color?.color??n.axis.label.name.color})}},label:{value:{getStyle:()=>({fontSize:r("label")?.label?.value?.fontSize??n.label.value.fontSize,fontFamily:r("label")?.label?.value?.fontFamily??n.label.value.fontFamily,fill:r("label")?.label?.value?.color?.color??n.label.value.color,useContrastColor:r("label")?.label?.value?.useContrastColor??!0})}}}}({layout:t,themeService:n}),i=function({layout:e,constraints:t,colorService:n,themeService:r,styleModel:i,pluginService:o,animationsEnabled:a}){const l=function(e){return{...e.getScales()}}(n),s=n.getPalettes(),u=function({layout:e,constraints:t,colorService:n,animationsEnabled:r}){const i=n.getDatumProps(),o=n.getColor();return{type:"funnel",key:"fun",data:{extract:{field:"qDimensionInfo/0",props:{num:{field:"qMeasureInfo/0"},...i}}},brush:t.select||t.active?{}:{trigger:[{contexts:["selection"],data:[""]}],consume:[{context:"selection",filter:e=>"section"===e.tag,style:{inactive:{opacity:.3}}}]},settings:{num:{ref:"num"},fill:o,mode:e.funnel.mode},animations:{enabled:r,isMainComponent:!0,trackBy:e=>`${e.tag}: ${e.data.value}`}}}({layout:e,constraints:t,colorService:n,animationsEnabled:a}),c=[u,Bo(e,r,a,i),Uo(e,i)];return{palettes:s,scales:l,components:o.extendComponents(c),formatters:{share:{type:"d3-number",format:".1%"},num:{data:{field:"qMeasureInfo/0"}}}}}({layout:t,constraints:b,colorService:S,themeService:n,styleModel:r,pluginService:N,animationsEnabled:I});D.update({data:e,settings:i}),C.set("width",D.element.clientWidth),C.set("height",D.element.clientHeight),Di.cacheProperties({viewCache:C,layout:t})},[D,S,y.name(),N,b]),u(()=>{D&&(D.update(),C.set("width",D.element.clientWidth),C.set("height",D.element.clientHeight))},[x.width,x.height]),u(()=>{k&&k.setLayout(t)},[t]),v(e=>S.getSnapshotData().then(t=>(e.snapshotData=e.snapshotData||{},e.snapshotData.content=e.snapshotData.content||{},e.snapshotData.content.chartData=t,e)).catch(()=>e))}function Wo(n){!function(e){if(e&&e.get&&e.add){const t="Object.Disclaimer.LimitedData";if(e.get(t)!==t)return;Object.keys(y).forEach(t=>{e.add(y[t])})}}(n.translator);const r=e();return r.use(t),r.component("funnel",M),{ext:hi(n),qae:{properties:{initial:I},data:{targets:mi}},component(){Vo({picasso:r})}}}export{Wo as default};
|
|
11
|
+
e.exports=function(e,t){if(!e||isNaN(+t))return t;var n,r,i,o,a,l,s,u,c,d,f=e.length,p=e.search(/[0-9\-\+#]/),h=p>0?e.substring(0,p):"",m=e.split("").reverse().join(""),g=m.search(/[0-9\-\+#]/),v=f-g,y=e.substring(v,v+1),b=v+("."===y||","===y?1:0),x=g>0?e.substring(b,f):"";if(n=(t="-"===(e=e.substring(p,b)).charAt(0)?-t:+t)<0?t=-t:0,i=(r=e.match(/[^\d\-\+#]/g))&&r[r.length-1]||".",o=r&&r[1]&&r[0]||",",e=e.split(i),t=+(t=t.toFixed(e[1]&&e[1].length))+"",l=e[1]&&e[1].lastIndexOf("0"),(!(u=t.split("."))[1]||u[1]&&u[1].length<=l)&&(t=(+t).toFixed(l+1)),c=e[0].split(o),e[0]=c.join(""),(a=e[0]&&e[0].indexOf("0"))>-1)for(;u[0].length<e[0].length-a;)u[0]="0"+u[0];else 0===+u[0]&&(u[0]="");if((t=t.split("."))[0]=u[0],s=c[1]&&c[c.length-1].length){for(m="",v=(d=t[0]).length%s,f=d.length,b=0;b<f;b++)m+=d.charAt(b),!((b-v+1)%s)&&b<f-s&&(m+=o);t[0]=m}return t[1]=e[1]&&t[1]?i+t[1]:"","0"!==(r=t.join(""))&&""!==r||(n=!1),h+(n?"-":"")+r+x}},Jn(Gn={exports:{}}),Gn.exports);function Zn(e){return e.replace(/[-[\]/{}()*+?.\\^$|]/g,"\\$&")}const Xn={3:"k",6:"M",9:"G",12:"T",15:"P",18:"E",21:"Z",24:"Y","-3":"m","-6":"μ","-9":"n","-12":"p","-15":"f","-18":"a","-21":"z","-24":"y"},Qn=/%\)?$/,er=/^\(r(0[2-9]|[12]\d|3[0-6])\)/i,tr=/^\(oct\)/i,nr=/^\(dec\)/i,rr=/^\(hex\)/i,ir=/^\(bin\)/i,or=/^\(rom\)/i,ar=/^(\(rom\)|\(bin\)|\(hex\)|\(dec\)|\(oct\)|\(r(0[2-9]|[12]\d|3[0-6])\))/i,lr=/#|0/g;function sr(e,t,n,r){return e=e.toString(t),n[1]===n[1].toUpperCase()&&(e=e.toUpperCase()),e.length-e.indexOf(".")>10&&(e=e.slice(0,e.indexOf(".")+11)),e.replace(".",r||".")}function ur(e,t,n){const r=Zn(e);return n?r:new RegExp(r||"",t)}function cr(e,t,n,r){let i,o,a,l,s,u,c,d,f,p=e.pattern;var h,m;r&&(e.abbreviate=!0),h=t,(m=n)&&(m=Zn(m)),h&&(h=Zn(h)),f=new RegExp("(?:[#0]+".concat(h,")?[#0]+(?:").concat(m,"[#0]+)?")),a=p.match(f),a=a?a[0]:"",l=a?p.substr(0,p.indexOf(a)):p,s=a?p.substring(p.indexOf(a)+a.length):"",a||(a=p?"#":"##########"),t&&t===n&&(i=a.split(n),o=i.pop(),a=i.join("")+n+o,t=""),u=t,t=/,/.test(n)?"¤":",",u&&(a=a.replace(ur(u,"g"),t)),c=n,n=".",c&&(a=a.replace(ur(c,"g"),n)),d=a.match(/#/g),d=d?d.length:0;const g=p.split(c);let v;g[1]&&(v=g[1].match(lr)),e.prefix=l||"",e.postfix=s||"",e.pattern=p,e.maxPrecision=v?v.length:2,e.percentage=Qn.test(p),e.numericPattern=a||"",e.numericRegex=new RegExp("".concat(ur(t,null,!0),"|").concat(ur(n,null,!0)),"g"),e.groupTemp=u,e.decTemp=c,e.t=t,e.d=n,e.temp=d}class dr{constructor(e,t,n,r,i){this.localeInfo=e,this.pattern=t,this.thousandDelimiter=n||",",this.decimalDelimiter=r||".",this.type=i||"numeric",this.patternSeparator=";",this.abbreviations=function(e,t){if(!e||!e.qNumericalAbbreviation)return Xn;const n={};return e.qNumericalAbbreviation.split(t).forEach(e=>{let t=e.split(":");2===t.length&&(n[t[0]]=t[1])}),n}(e,this.patternSeparator),this.prepare()}clone(){const e=new dr(this.localeInfo,this.pattern,this.thousandDelimiter,this.decimalDelimiter,this.type);return e.subtype=this.subtype,e}format(e,t,n,r){return this.prepare(t,n,r),this.formatValue(e)}prepare(e,t,n){let r;if(void 0===e&&(e=this.pattern),void 0===t&&(t=this.thousandDelimiter),void 0===n&&(n=this.decimalDelimiter),!e)return void(this._prepared={pattern:!1});this._prepared={positive:{d:n,t:t,abbreviate:!1,isFunctional:!1,prefix:"",postfix:""},negative:{d:n,t:t,abbreviate:!1,isFunctional:!1,prefix:"",postfix:""},zero:{d:n,t:t,abbreviate:!1,isFunctional:!1,prefix:"",postfix:""}},r=this._prepared,e=e.split(this.patternSeparator),r.positive.pattern=e[0],r.negative.pattern=e[1],r.zero.pattern=e[2],ar.test(e[0])&&(r.positive.isFunctional=!0),e[1]?ar.test(e[1])&&(r.negative.isFunctional=!0):r.negative=!1,e[2]?ar.test(e[2])&&(r.zero.isFunctional=!0):r.zero=!1;const i="U"===this.type;r.positive.isFunctional||cr(r.positive,t,n,i),r.negative&&!r.negative.isFunctional&&cr(r.negative,t,n,i),r.zero&&!r.zero.isFunctional&&cr(r.zero,t,n,i)}formatValue(e){let t,n,r,i,o,a,l,s,u,c=this._prepared,d="",f="",p=e;if(isNaN(e))return"".concat(p);if(e=+e,!1===c.pattern)return e.toString();if(0===e&&c.zero)return c=c.zero,c.pattern;if(e<0&&c.negative?(c=c.negative,e=-e):c=c.positive,o=c.d,a=c.t,c.isFunctional)e=function(e,t,n){let r;return er.test(t)?e=sr(e,Number(/\d{2}/.exec(t)[0]),t,n):tr.test(t)?e=sr(e,8,t,n):nr.test(t)?e=sr(e,10,t,n):rr.test(t)?e=sr(e,16,t,n):ir.test(t)?e=sr(e,2,t,n):or.test(t)&&(r="",e<0&&(r="-",e=-e),0===(e=Math.floor(e))?e="0":e<=5e5?(e=function(e,t){let n,r="",i=Number(String(e).slice(-3)),o=(e-i)/1e3,a=[0,1,4,5,9,10,40,50,90,100,400,500,900].reverse(),l=["0","I","IV","V","IX","X","XL","L","XC","C","CD","D","CM"].reverse();for(;i>0;)for(n=0;n<a.length;n++)if(a[n]<=i){r+=l[n],i-=a[n];break}for(n=0;n<o;n++)r="M".concat(r);return t[1]!==t[1].toUpperCase()&&(r=r.toLowerCase()),r}(e,t),e=r+e):e=t+r+e.toExponential(0)),e}(e,c.pattern,o);else{if(c.percentage&&(e*=100),c.abbreviate){const t=Object.keys(this.abbreviations).map(e=>parseInt(e,10)).sort((e,t)=>e-t);let r,i,o=t[0];for(l=0,n=Number(Number(e).toExponential().split("e")[1]);o<=n&&l<t.length;)l++,o=t[l];l>0&&(r=t[l-1]),r&&n>0&&r>0?i=r:(n<0&&r<0||!r)&&(o<0&&o-n<=c.maxPrecision?i=o:r<=n&&!(o>0&&-n<=c.maxPrecision)&&(i=r)),i&&(d=this.abbreviations[i],e/=10**i)}if(r=Math.abs(e),t=c.temp,s=c.numericPattern,u=s.split(o)[1],"I"===this.type&&(e=Math.round(e)),i=e,u||"#"!==s.slice(-1)[0])if(r>=1e15||r>0&&r<=1e-14)e=r?r.toExponential(15).replace(/\.?0+(?=e)/,""):"0";else{const t=Number((e+1e-15*(e<0?-1:1)).toFixed(Math.min(20,u?u.length:0)).split(".")[0]);let n=s.split(o)[0];if(n+=o,e=Yn(n,t)||"0",u){const t=Math.max(0,Math.min(14,u.length)),n=u.replace(/#+$/,"").length;let i=("I"===this.type?0:r%1+1e-15).toFixed(t).slice(2).replace(/0+$/,"");for(l=i.length;l<n;l++)i+="0";i&&(e+=o+i)}else 0===t&&(i=0)}else if(r>=10**t||r<1||r<1e-4)0===e?e="0":r<1e-4||r>=1e20?(e=(e=i.toExponential(Math.max(1,Math.min(14,t))-1)).replace(/\.?0+(?=e)/,""),f=""):(e=e.toPrecision(Math.max(1,Math.min(14,t)))).indexOf(".")>=0&&(e=(e=e.replace(e.indexOf("e")<0?/0+$/:/\.?0+(?=e)/,"")).replace(".",o));else{for(s+=o,t=Math.max(0,Math.min(20,t-Math.ceil(Math.log(r)/Math.log(10)))),l=0;l<t;l++)s+="#";e=Yn(s,e)}e=e.replace(c.numericRegex,e=>e===a?c.groupTemp:e===o?c.decTemp:""),i<0&&!/^-/.test(e)&&(e="-".concat(e))}return c.prefix+e+f+d+c.postfix}static getStaticFormatter(){return{prepare(){},formatValue:e=>"".concat(e)}}}function fr(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const{size:n=5e3,multipleArguments:r=!1,toKey:i=e=>e}=t;let o,a,l=Object.create(null),s=Object.create(null),u=0,c=0;return o=r?function(){return a=i(...arguments),o.has(a)?o.get(a):o.set(a,e(...arguments))}:t=>(a=i(t),o.has(a)?o.get(a):o.set(a,e(t))),o.set=(e,t)=>(u>=n&&(delete l[s[c]],delete s[c],u--,c++),l[e]=t,s[u]=e,u++,t),o.get=e=>l[e],o.has=e=>e in l,o.clear=()=>{l=Object.create(null),s=Object.create(null),u=0,c=0},o.size=()=>u,o}function pr(e,t,n,r,i){const o=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return new dr(...t)}(i,e,t,n,r),a=fr(o.formatValue.bind(o),{toKey:e=>isNaN(e)?e:+e});function l(e){return a(e)}return l.format=function(e,t,n,r){return a.clear(),o.format(t,e,n,r)},l.pattern=function(e){return e&&(a.clear(),o.pattern=e,o.prepare()),o.pattern},l}const hr="D",mr="T",gr="TS",vr=["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],yr=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"],br=["January","February","March","April","May","June","July","August","September","October","November","December"],xr=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function wr(e,t){for(let n=e.length;n<t;n++)e="0".concat(e);return e}function qr(e){let t=e.toString().split(".");return t[1]?(t=Number("0.".concat(t[1])),t):0}class Dr{constructor(e,t,n){const r=e||{};r.qCalendarStrings||(r.qCalendarStrings={qLongDayNames:vr,qDayNames:yr,qLongMonthNames:br,qMonthNames:xr}),this.localeInfo=r,this.locale_days=r.qCalendarStrings.qLongDayNames.slice(),this.locale_days_abbr=r.qCalendarStrings.qDayNames.slice(),this.locale_months=r.qCalendarStrings.qLongMonthNames.slice(),this.locale_months_abbr=r.qCalendarStrings.qMonthNames.slice(),t||(t={[mr]:r.qTimeFmt||"hh:mm:ss",[hr]:r.qDateFmt||"YYYY-MM-DD",[gr]:r.qTimestampFmt||"YYYY-MM-DD hh:mm:ss"}[n]),this.pattern=t}clone(){const e=new Dr(this.localeInfo,this.pattern);return e.subtype=this.subtype,e}format(e,t){t||(t=this.pattern?this.pattern:"YYYY-MM-DD hh:mm:ss"),t=t.replace(/\[.+]|\[|]/g,"");const n=/t+/gi.test(t);let r;e instanceof Date?r=function(e,t){let n=e.getUTCHours(),r=e.getUTCDay()-1;return t&&(n%=12,n||(n=12)),r<0&&(r=6),{year:e.getUTCFullYear(),month:e.getUTCMonth(),day:r,date:e.getUTCDate(),h:n,m:e.getUTCMinutes(),s:e.getUTCSeconds(),f:e.getUTCMilliseconds(),t:e.getUTCHours()>=12?"pm":"am"}}(e,n):(e<0&&(e=-e,t="-".concat(t)),r=function(e,t){let n,r=function(e){const t=e,n=24*qr(t),r=60*qr(n),i=60*qr(r),o=1e3*qr(i);return{d:Math.floor(t),h:Math.floor(n),m:Math.floor(r),s:Math.floor(i),f:Math.round(o)}}(e),i=r.d,o=r.h,a=r.m,l=r.s,s=r.f,u=0;/w+|t+/gi.test(t)&&(n=new Date(Date.UTC(1899,11,30+Math.floor(e),0,0,Math.round(86400*(e-Math.floor(e))))),isNaN(n.getTime())&&(n=null)),/D+/gi.test(t)||(o+=24*i),/h+/gi.test(t)||(a+=60*o),/m+/gi.test(t)||(l+=60*a),/w+/gi.test(t)&&(u=n?n.getDay()-1:0,u<0&&(u=6));let c="";return n&&(c=n.getUTCHours()>=12?"pm":"am"),{year:0,month:0,day:u,date:i,h:o,m:a,s:l,f:s,t:c}}(e,t));const i=(o=this,a=r,{"Y+|y+":{Y:"".concat(Number("".concat(a.year).slice(-2))),YY:wr("".concat(a.year).slice(-2),2),YYY:wr("".concat(a.year).slice(-3),3),def:e=>wr("".concat(a.year),e.length)},"M+":{M:a.month+1,MM:wr("".concat(a.month+1),2),MMM:o.locale_months_abbr[a.month],def:o.locale_months[a.month]},"W+|w+":{W:a.day,WW:wr("".concat(a.day),2),WWW:o.locale_days_abbr[a.day],def:o.locale_days[a.day]},"D+|d+":{D:a.date,def:e=>wr("".concat(a.date),e.length)},"h+|H+":{h:a.h,def:e=>wr("".concat(a.h),e.length)},"m+":{m:a.m,def:e=>wr("".concat(a.m),e.length)},"s+|S+":{s:a.s,def:e=>wr("".concat(a.s),e.length)},"f+|F+":{def(e){let t="".concat(a.f),n=e.length-t.length;if(n>0)for(let e=0;e<n;e++)t+="0";else n<0&&(t=t.slice(0,e.length));return t}},"t{1,2}|T{1,2}":{def(e){let t=a.t;return e[0].toUpperCase()===e[0]&&(t=t.toUpperCase()),t=t.slice(0,e.length),t}}});var o,a;const l=[];for(const e in i)Object.prototype.hasOwnProperty.call(i,e)&&l.push(e);const s=new RegExp(l.join("|"),"g");return t.replace(s,e=>{let t,n,r;for(n in i)if(Object.prototype.hasOwnProperty.call(i,n)&&(t=new RegExp(n),t.test(e)))break;if(!t)return"";for(const t in i[n])if(t===e||t.toLowerCase()===e){r=i[n][t],void 0===r&&(r=i[n][t.toLowerCase()]);break}return void 0===r&&(r=i[n].def),"function"==typeof r&&(r=r(e)),r})}}function Sr(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return new Dr(...t)}function kr(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"TS",n=Sr(arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,e,t),r=fr(n.format.bind(n),{toKey:e=>"object"==typeof e&&"function"==typeof e.getTime?e.getTime():e});function i(e){return"IV"!==t?function(e){return new Date(Date.UTC(1899,11,30+Math.floor(e),0,0,0,Math.round(864e5*(e-Math.floor(e)))))}(e):e}function o(e){return e=i(e),r(e)}return o.format=function(e,t){return r.clear(),t=i(t),n.format(t,e)},o.locale=function(i){return n=Sr(i,e,t),r=fr(n.format.bind(n),{toKey:e=>"object"==typeof e?e.getTime():e}),this},o.qtype=function(e){return void 0!==e&&(t=e,r.clear()),t},o}function Cr(){let e,{meta:t,id:n,key:r,localeInfo:i,fieldExtractor:o,value:a,type:l,sourceField:s}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const u=a||("dimension"===l?e=>null==e?void 0:e.qElemNo:e=>null==e?void 0:e.qValue),c="dimension"===l?"first":"avg",d=function(e,t){if(e&&e.qNumFormat&&-1!==["D","T","TS","IV"].indexOf(e.qNumFormat.qType))return kr(e.qNumFormat.qFmt,e.qNumFormat.qType,t);let n="#",r=t&&void 0!==t.qThousandSep?t.qThousandSep:",",i=t&&void 0!==t.qDecimalSep?t.qDecimalSep:".",o="U",a=e&&!!e.qIsAutoFormat;return e&&e.qNumFormat?(n=e.qNumFormat.qFmt||n,r=e.qNumFormat.qThou||r,i=e.qNumFormat.qDec||i,o=e.qNumFormat.qType||o,a=a&&-1===["M"].indexOf(e.qNumFormat.qType)):a=!0,(a||"U"===o)&&(n="#".concat(i,"##"),o="U"),pr(n,r,i,o,t)}(t,i),f={id:()=>n,key:()=>r,raw:()=>t,title:()=>t.qFallbackTitle||t.label,type:()=>l,origin:()=>s,items:()=>(e||(e=o(f)),e),min:()=>t.qMin,max:()=>t.qMax,value:u,label:e=>(null==e?void 0:e.qText)||"",reduce:c,reduceLabel:"dimension"===l?"first":(e,t)=>d(t),formatter:()=>d,tags:()=>t.qTags};return f}function Mr(e,t,n,r,i){return(t[e]||[]).map((t,o)=>{const a="".concat(r?"".concat(r,"/"):"").concat(e,"/").concat(o),l={instance:Cr(fn({id:"".concat(n?"".concat(n,"/"):"").concat(a),key:a,meta:t},i))};return l.attrDims=Mr("qAttrDimInfo",t,n,a,fn({},i,{value:e=>null==e?void 0:e.qElemNo,type:"dimension"})),l.attrExps=Mr("qAttrExprInfo",t,n,a,fn({},i,{value:e=>null==e?void 0:e.qNum,type:"measure"})),l.measures=Mr("qMeasureInfo",t,n,a,fn({},i,{value:e=>null==e?void 0:e.qValue,type:"measure"})),l})}function Ir(){let{key:e,data:t,config:n={}}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const r={fields:[],wrappedFields:[],allFields:[],virtualFields:[]},i=t;if(!i)throw new Error('Missing "data" input');if(!i.qDimensionInfo)throw new Error('The "data" input is not recognized as a hypercube');const o=Ir.util,a={cache:r,cube:i,localeInfo:n.localeInfo,fieldExtractor:null,pages:null,hierarchy:()=>null,virtualFields:n.virtualFields},l={key:()=>e,raw:()=>i,field:e=>function(e,t){let{cache:n}=t;if("number"==typeof e)return n.fields[e];const r=n.allFields;if("function"==typeof e){for(let t=0;t<r.length;t++)if(e(r[t]))return r[t];return!1}if("string"==typeof e){for(let t=0;t<r.length;t++)if(r[t].key()===e||r[t].title()===e)return r[t]}else if(e&&-1!==r.indexOf(e))return e;throw Error("Field not found: ".concat(e))}(e,a),fields:()=>r.fields.slice(),extract:e=>a.extractor(e,l,r,o),hierarchy:e=>a.hierarchy(e,l,r,o),_cache:()=>r};"K"===i.qMode||"T"===i.qMode||!i.qMode&&i.qNodesOnDim?(a.extractor=Kn,a.hierarchy=Wn,a.pages="K"===i.qMode?i.qStackedDataPages:i.qTreeDataPages):"S"===i.qMode?(a.extractor=gn,a.pages=i.qDataPages,a.hierarchy=Wn):a.extractor=()=>[],a.fieldExtractor=e=>a.extractor({field:e},l,r,o);const s="S"===i.qMode?e=>e.qElemNumber:void 0,u="S"===i.qMode?e=>e.qNum:void 0;r.wrappedFields.push(...Mr("qDimensionInfo",i,e,"",fn({},a,{value:s,type:"dimension"}))),r.wrappedFields.push(...Mr("qMeasureInfo",i,e,"",fn({},a,{value:u,type:"measure"}))),r.fields=r.wrappedFields.map(e=>e.instance);const c=e=>{e.forEach(e=>{r.allFields.push(e.instance),c(e.measures),c(e.attrDims),c(e.attrExps)})};return c(r.wrappedFields),(n.virtualFields||[]).forEach(t=>{const n=l.field(t.from),i=Cr(nn({meta:n.raw(),id:"".concat(e,"/").concat(t.key),sourceField:n,fieldExtractor:e=>a.extractor({field:e},l,r,o),key:t.key,type:n.type(),localeInfo:a.localeInfo,value:n.value},t.override||{}));r.virtualFields.push(i)}),r.allFields.push(...r.virtualFields),l}const Nr=[["qHyperCube","qHyperCubeDef"],["qTreeData","qTreeDataDef"],["qDimensionInfo","qDimensions"],["qMeasureInfo","qMeasures"],["qAttrDimInfo","qAttributeDimensions"],["qAttrExprInfo","qAttributeExpressions"]],Er=/\/qDimensionInfo(?:\/(\d+))?/,Or=/\/qMeasureInfo\/(\d+)/,Rr=/\/qAttrDimInfo\/(\d+)(?:\/(\d+))?/,Tr=/\/qAttrExprInfo\/(\d+)/,zr=/\/?qHyperCube/,Lr=/\/?qTreeData/,Pr=e=>"".concat(e.substr(0,e.indexOf("/qHyperCubeDef")+14)),jr=e=>"".concat(e.substr(0,e.indexOf("/qTreeDataDef")+13));function Ar(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0;const r=t.byCells,i=t.primarySource,o=[],a={},l=e.isActive();let s=!1;return e.brushes().forEach(e=>{const t=function(e,t){let n=e,r=-1,i=-1,o="",a=e=>e;zr.test(e)?(o="".concat(n.substr(0,n.indexOf("qHyperCube")+10)),a=Pr):Lr.test(e)&&(o="".concat(n.substr(0,n.indexOf("qTreeData")+9)),a=jr);let l=!0;if(Er.test(e)&&(r=+Er.exec(e)[1]),Or.test(e)&&(i=+Or.exec(e)[1]),Rr.test(e)){i=-1,r=0;const e=+Rr.exec(n)[2];isNaN(e)||(r=e,n=n.replace(/\/\d+$/,"")),l=!1}if(Tr.test(e)){const e=i;if(t){i=0;const a=Rn(o,t);i+=(a.qMeasureInfo||[]).length,r>-1?(i=a.qDimensionInfo.slice(0,r).reduce((e,t)=>e+t.qAttrExprInfo.length,i),r=-1):(i=a.qDimensionInfo.reduce((e,t)=>e+t.qAttrExprInfo.length,i),i=a.qMeasureInfo.slice(0,e).reduce((e,t)=>e+t.qAttrExprInfo.length,i)),i+=+Tr.exec(n)[1]}else r>-1?(r=-1,i=+Tr.exec(n)[1]):i+=+Tr.exec(n)[1]+1}return Nr.forEach(e=>{let[t,r]=e;n=n.replace(t,r)}),l&&(n=a(n)),n&&"/"!==n[0]&&(n="/".concat(n)),{measureIdx:i,dimensionIdx:r,path:n}}(e.id,n);if("range"===e.type&&t.measureIdx>-1&&t.dimensionIdx>-1){const n=e.brush.ranges();n.length&&(s=!0,a.multiRangeSelectTreeDataValues||(a.multiRangeSelectTreeDataValues={path:t.path,ranges:[]}),n.forEach(e=>a.multiRangeSelectTreeDataValues.ranges.push({qMeasureIx:t.measureIdx,qDimensionIx:t.dimensionIdx,qRange:{qMin:e.min,qMax:e.max,qMinInclEq:!0,qMaxInclEq:!0}})))}else{if("range"===e.type&&t.measureIdx>-1){const n=e.brush.ranges();n.length&&(s=!0,a.rangeSelectHyperCubeValues||(a.rangeSelectHyperCubeValues={path:t.path,ranges:[]}),n.forEach(e=>a.rangeSelectHyperCubeValues.ranges.push({qMeasureIx:t.measureIdx,qRange:{qMin:e.min,qMax:e.max,qMinInclEq:!0,qMaxInclEq:!0}})))}if("range"===e.type&&t.dimensionIdx>-1){const n=e.brush.ranges();n.length&&(s=!0,a.selectHyperCubeContinuousRange||(a.selectHyperCubeContinuousRange={path:t.path,ranges:[]}),n.forEach(e=>a.selectHyperCubeContinuousRange.ranges.push({qDimIx:t.dimensionIdx,qRange:{qMin:e.min,qMax:e.max,qMinInclEq:!0,qMaxInclEq:!1}})))}if("value"===e.type&&t.dimensionIdx>-1)if(r)if(n&&n.qHyperCube&&("P"===n.qHyperCube.qMode||"T"===n.qHyperCube.qMode||"K"===n.qHyperCube.qMode)){const r=n.qHyperCube,o=r.qNoOfLeftDims,l=r.qEffectiveInterColumnSortOrder.indexOf(t.dimensionIdx);if(a.selectPivotCells||(a.selectPivotCells={path:t.path,cells:[]}),e.id===i||!i){const n=e.brush.values().map(e=>+e).filter(e=>!isNaN(e));(0===o||l>=o)&&o>-1?n.forEach(e=>{a.selectPivotCells.cells.push({qType:"T",qCol:e,qRow:l-o})}):n.forEach(e=>{a.selectPivotCells.cells.push({qType:"L",qCol:t.dimensionIdx,qRow:e})}),s=!!a.selectPivotCells.cells.length}}else a.selectHyperCubeCells||(a.selectHyperCubeCells={path:t.path,cols:[]}),a.selectHyperCubeCells.cols.push(t.dimensionIdx),e.id!==i&&(i||a.selectHyperCubeCells.values)||(a.selectHyperCubeCells.values=e.brush.values().map(e=>+e).filter(e=>!isNaN(e)),s=!!a.selectHyperCubeCells.values.length);else{const n=e.brush.values().map(e=>+e).filter(e=>!isNaN(e));s=!!n.length,o.push({params:[t.path,t.dimensionIdx,n,!1],method:"selectHyperCubeValues"})}}}),!s&&l?[{method:"resetMadeSelections",params:[]}]:(a.rangeSelectHyperCubeValues&&o.push({method:"rangeSelectHyperCubeValues",params:[a.rangeSelectHyperCubeValues.path,a.rangeSelectHyperCubeValues.ranges,[],null===(u=t.orMode)||void 0===u||u]}),a.selectHyperCubeContinuousRange&&o.push({method:"selectHyperCubeContinuousRange",params:[a.selectHyperCubeContinuousRange.path,a.selectHyperCubeContinuousRange.ranges]}),a.selectHyperCubeCells&&o.push({method:"selectHyperCubeCells",params:[a.selectHyperCubeCells.path,a.selectHyperCubeCells.values,a.selectHyperCubeCells.cols]}),a.selectPivotCells&&o.push({method:"selectPivotCells",params:[a.selectPivotCells.path,a.selectPivotCells.cells]}),a.multiRangeSelectTreeDataValues&&o.push({method:"multiRangeSelectTreeDataValues",params:[a.multiRangeSelectTreeDataValues.path,a.multiRangeSelectTreeDataValues.ranges]}),o);var u}function Fr(e){Ir.util=e.data("matrix").util,e.data("q",Ir),e.formatter("q-number",pr),e.formatter("q-time",kr)}function _r(e){var t=Yt(e.layout||{},e.path.split("/").join("."));if(!t)return!1;var n=t.qIsOneAndOnlyOne;return void 0!==n&&n}function $r(e){var t=e.brush,n=e.colorField,r=e.legendAlias,i=e.useLegendCube,o=void 0!==i&&i;!n||/qAttrDimInfo/.test(n)?(t.removeKeyAlias("attrDim/qDimensionInfo/0"),r&&t.removeKeyAlias(r),t.addKeyAlias("attrDim/qDimensionInfo/0","qHyperCube/".concat(n))):o&&t.addKeyAlias(r,"qHyperCube/".concat(n))}Fr.qBrushHelper=Ar,Fr.selections=Ar;var Hr="Shift";var Br=function(e,t){return t[e]?Br(e+1,t):e},Ur=function(e,t){var n=t.reduce(function(e,t){return e[t]=!0,e},{});return e.reduce(function(e,t,r){var i=Br(r,n);return n[i]=!0,e[r]=i,e},{})};function Vr(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.layout,n=e.filtered,r=void 0===n?{}:n,i=(null==t?void 0:t.qHyperCube)||{},o=i.qDimensionInfo,a=void 0===o?[]:o,l=i.qMeasureInfo,s=void 0===l?[]:l;return{dimensions:Ur(a,r.dimensions||[]),measures:Ur(s,r.measures||[])}}function Wr(e){var t=e.selection,n=e.fieldMap,r=t.method,i=t.params;if("selectHyperCubeValues"===r){var o=n.dimensions[i[1]];void 0!==o&&(i[1]=o)}return"selectHyperCubeContinuousRange"===r&&i[1].forEach(function(e){var t=n.dimensions[e.qDimIx];void 0!==t&&(e.qDimIx=t)}),t}var Kr=[],Jr=0,Gr=function(e){var t=Kr.filter(function(e){var t;return null===(t=e.selections)||void 0===t?void 0:t.isActive()});t.length&&("Enter"===e.key?t.forEach(function(e){return e.selections.confirm()}):"Escape"!==e.key&&"Esc"!==e.key||t.forEach(function(e){return e.selections.cancel()}))};function Yr(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=t.selections,r=t.brush,i=t.majorScale,o=t.actions,a=t.selectionsFn,l=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).path,s=void 0===l?"/qHyperCubeDef":l;if(!n)return{layout:function(){},filteredFields:function(){},allowSimultaneous:function(){},release:function(){}};var u=++Jr,c=null,d={dimensions:[],measures:[]},f=[],p={};n.on=n.on.bind(n),n.isActive=n.isActive.bind(n),n.addListener=n.addListener.bind(n),n.removeListener=n.removeListener.bind(n);var h=function(e){var t=e.brush,n=e.getConfig;return{interceptor:function(e){var r=t.brushes(),i=n(),o=i.allowSimultaneous,a=i.layout,l=void 0===a?{}:a;r.forEach(function(n){var r,i,a;("range"===n.type||null!==(r=e[0])&&void 0!==r&&r.key&&(null===(i=e[0])||void 0===i?void 0:i.key)!==n.id&&0!==o.indexOf(null===(a=e[0])||void 0===a?void 0:a.key))&&t.clear([])});var s=e.filter(function(e){return-2!==e.value});if(s.length>1){var u=function(e){var t=e.layout,n=void 0===t?{}:t,r=e.values,i=void 0===r?[]:r;if(null==i||!i.length)return[];var o=Array.from(new Set(i.map(function(e){return e.key}))),a=[];return o.forEach(function(e){var t=_r({layout:n,path:e}),r=i.filter(function(t){return t.key===e}),o=t?[r.pop()]:r;a.push.apply(a,F(o))}),a.filter(Boolean)}({layout:l,values:s});return u}return s},rangeInterceptor:function(e){var r=t.brushes(),i=n().allowSimultaneous;return r.filter(function(e){return"value"===e.type}).length?(t.clear([]),e):(r.forEach(function(n){var r=n.id===e[0].key||i.includes(n.id)&&i.includes(e[0].key);"range"!==n.type||r||t.clear([])}),e)}}}({brush:r,getConfig:function(){return{layout:c,allowSimultaneous:f}}}),m=h.rangeInterceptor,g=h.interceptor;r.intercept("set-ranges",m),r.intercept("toggle-ranges",m),r.intercept("toggle-values",g),r.intercept("set-values",g),r.intercept("add-values",g),r.on("start",function(){return n.begin(s)});var v,y,b={activate:function(){},deactivated:function(){return r.end()},cleared:function(){return r.clear()},canceled:function(){return r.end()}};v=n,y=b,Object.keys(y).forEach(function(e){v.on(e,y[e])});var x=null==i||null===(e=i.max)||void 0===e?void 0:e.call(i);return null!=o&&o.select?(o.select.on("start",function(){var e;r.start(),"function"==typeof o.select.getBrushOptions&&(p=(e=o.select).getBrushOptions.apply(e,arguments))}),o.select.on("end",function(){var e=a(r,p,c),t=Vr({layout:c,filtered:d});e.forEach(function(e){var r=Wr({selection:e,fieldMap:t});!function(e,t,n){if(t&&void 0!==n&&"selectHyperCubeContinuousRange"===e.method){var r=e.params;if(r&&r[1]&&r[1][0]){var i=r[1][0],o=i.qDimIx,a=i.qRange;"undefined"!==o&&a&&!1===a.qMaxInclEq&&a.qMax>=n&&(a.qMaxInclEq=!0)}}}(r,o.select.brushSelectionIncludeMax,x),n.select(r)})})):r.on("update",function(){var e=a(r,p,c),t=Vr({layout:c,filtered:d});e.forEach(function(e){n.select(Wr({selection:e,fieldMap:t}))})}),0===Kr.length&&document.addEventListener("keyup",Gr),Kr.push({key:u,selections:n}),{layout:function(e){c=e},filteredFields:function(e){d=e},allowSimultaneous:function(e){f=e},release:function(){c=null;var e=Kr.indexOf(Kr.filter(function(e){return e.key===u})[0]);-1!==e&&Kr.splice(e,1),Kr.length||document.removeEventListener("keyup",Gr),function(e,t){Object.keys(t).forEach(function(n){e.removeListener(n,t[n])})}(n,b)}}}function Zr(e){var t=e.chart,n=e.document,r=e.selectionInfo,i=e.eventName,o=e.componentName,a=e.brushName,l=void 0===a?"selection":a,s=e.emit,u=void 0===s?"rangeClear":s,c=r.event===i,d=n.querySelector("[data-key='".concat(o,"-edge-0']"));if(c||!d)return!1;var f=t.component(o);return!!f&&(f.emit(u),"string"==typeof l&&t.brush(l).clear(),f)}var Xr=["chart","document","selections","selectionInfo"],Qr=function(e){e.chart,e.document,e.selections,e.selectionInfo;var t=L(e,Xr);t.clearDiscrete(),t.clearContinuous(),t.clearMinor(),t.clearRange(),t.clearTap(),t.clearLegend()};function ei(e){var t,n=e.lasso;null!=n&&null!==(t=n.active)&&void 0!==t&&t.call(n)&&(null==n||n.action(!1))}function ti(e){var t,n=e.chart,r=e.selectionInfo,i=e.selectionActions,o=e.actions,a=void 0===o?{}:o,l=e.selections,s=e.selectionEvents;if(!1===i||!1===s)return function(){};var u=i.reset,c=void 0===u?ei:u,d=i.clear,f=!1!==d&&function(e){var t=e.clear,n=void 0===t?Qr:t,r=e.selections,i=e.selectionInfo,o=e.chart;return function(){var e=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}).cleared,t={selections:r,selectionInfo:i,chart:o,document:document,cleared:e};return n(z({clearDiscrete:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return function(e){var t=e.selectionInfo,n=e.chart,r=e.document,i=e.eventName,o=void 0===i?"discreteRange":i,a=e.componentName,l=void 0===a?"discrete-range-brush":a,s=e.cleared;return Zr({selectionInfo:t,chart:n,document:r,eventName:void 0!==s&&s?void 0:o,componentName:l,emit:"areaClear",brushName:e.brushName})}(z(z({},t),e))},clearContinuous:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return function(e){var t=e.selectionInfo,n=e.chart,r=e.document,i=e.eventName,o=void 0===i?"continuousRange":i,a=e.componentName,l=void 0===a?"continuous-range-brush":a,s=e.cleared;return Zr({selectionInfo:t,chart:n,document:r,eventName:void 0!==s&&s?void 0:o,componentName:l,brushName:e.brushName})}(z(z({},t),e))},clearMinor:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return function(e){var t=e.selectionInfo,n=e.chart,r=e.document,i=e.componentName,o=void 0===i?"minor-range-brush":i,a=e.eventName,l=void 0===a?"minorRange":a,s=e.cleared,u=void 0!==s&&s,c=e.brushName,d=Zr({selectionInfo:t,chart:n,document:r,eventName:u?void 0:l,componentName:o,brushName:void 0!==c&&c});if(d){var f=d.settings.settings,p=f.scale,h=f.brush,m=n.scale(p).data().fields.map(function(e){return e.id()}),g=n.brush(h),v=g.brushes().filter(function(e){return"range"===e.type&&m.some(function(t){return t===e.id})});g&&v.length&&v.forEach(function(e){g.removeRanges(e.brush.ranges().map(function(t){return{key:e.id,range:t}}))})}}(z(z({},t),e))},clearRange:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return function(e){var t=e.selectionInfo,n=e.chart,r=e.document,i=e.selections,o=e.eventName,a=void 0===o?"xAxis":o,l=e.cleared;Zr({selectionInfo:t,chart:n,document:r,eventName:void 0!==l&&l?void 0:a,componentName:"".concat(a,"-range-brush"),emit:"areaClear",brushName:!1})&&i.clear()}(z(z({},t),e))},clearTap:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return function(e){var t=e.chart,n=e.selectionInfo,r=e.selections,i=e.events,o=void 0===i?["tap"]:i,a=e.brushNames,l=void 0===a?[]:a;if(n&&o.includes(n.event)){var s=n.currentComponent;n.previousComponent!==s&&(r.clear(),l.forEach(function(e){return t.brush(e).end()}))}}(z(z({},t),e))},clearLegend:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return function(e){var t=e.selectionInfo,n=e.chart,r=e.document,i=e.selections,o=e.eventName,a=void 0===o?"legendRange":o,l=e.componentName,s=void 0===l?"legend-range-brush":l,u=e.cleared,c=void 0!==u&&u,d=e.brushName;Zr({selectionInfo:t,chart:n,document:r,eventName:c?void 0:a,componentName:s,brushName:void 0!==d&&d})&&i.clear()}(z(z({},t),e))}},t))}}({clear:d,selections:l,selectionInfo:r,chart:n}),p=function(e){var t=e.chart,n=e.actions,r=e.reset,i=e.clear,o=!1,a={deactivated:function(e){var t=(n||{}).lasso;r({e:e,lasso:void 0!==t&&t})},canceled:function(e){var o=(n||{}).lasso;r({e:e,lasso:void 0!==o&&o}),i({e:e,chart:t,document:document})},cleared:function(e){o||(o=!0,i({e:e,chart:t,document:document,cleared:!0}),o=!1)}};return!1===r&&delete a.deactivated,!1===i&&delete a.cleared,!1===r&&!1===i&&delete a.canceled,a}({chart:n,clear:f,reset:c,actions:a}),h={};Object.entries(p).forEach(function(e){var t=A(e,2),n=t[0],r=t[1];h[n]=function(e,t){return t?function(n){return t({event:n,defaultFunc:e})}:e}(r,s[n])});var m=function(e){var t=e.selectionEvents,n=e.selections,r=e.selectionInfo,i=e.clear,o=e.chart,a=e.document,l=t.start,s={selections:n,selectionInfo:r,chart:o,document:a},u=function(e){return Object.assign(r,e||{})},c=function(e){var t=e.event,n=e.components;return function(){return function(e){var t=e.selectionInfo,n=e.clear,r=e.event,i=e.components,o=void 0===i?[]:i;(0,e.setSelectionInfo)(z(z({},void 0===t?{}:t),{},{event:r,components:o.map(function(e){return e.key}).filter(Boolean)})),n()}({event:t,components:n,clear:i,selectionInfo:r,setSelectionInfo:u})}};return"function"==typeof l?function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];l(z(z({defaultFunc:c({event:e,components:t}),setSelectionInfo:u,clear:i},s),{},{event:e,components:t}))}:function(e){c({event:e,components:arguments.length>1&&void 0!==arguments[1]?arguments[1]:[]})()}}({selectionEvents:s,selections:l,selectionInfo:r,clear:f,chart:n,document:document});return null==a||null===(t=a.select)||void 0===t||t.on("start",m),Object.entries(h).forEach(function(e){var t=A(e,2),n=t[0],r=t[1];null==l||l.on(n,r)}),function(){var e;null==a||null===(e=a.select)||void 0===e||e.removeListener("start",m),Object.entries(h).forEach(function(e){var t=A(e,2),n=t[0],r=t[1];null==l||l.removeListener(n,r)})}}var ni=[{key:"qHyperCube/qDimensionInfo/0:numeric",includeMax:!1}];function ri(e){var t=e.chart,n=e.actions,r=e.selections,i=e.picassoQ,o=e.config,a=o.allowSimultaneous,l=void 0!==a&&a,s=o.majorScale,u=void 0===s?void 0:s,c=o.selectionActions,d=void 0===c?{}:c,f=d.clear,p=d.reset,h=o.selectionEvents,m=void 0===h?{deactivated:void 0,canceled:void 0,cleared:void 0,start:void 0}:h,g=o.brushEvents,v=void 0===g?{}:g,y=o.brushName,b=void 0===y?"selection":y,x=o.brushMaxListeners,w=void 0===x?20:x,q=o.brushRanges,D=void 0!==q&&q,S=o.interceptors,k=void 0===S?{}:S,C=o.selectionsFn,M=void 0===C?i.selections:C,I=t.brush(b);if("number"==typeof w&&I.setMaxListeners(w),D){var N=!0===D?ni:D;I.configure({ranges:N})}var E={canSelect:!0,getIsSelectionLocked:!1,isInnerDimensionLocked:!1,lockedDimensions:[],singleSelectIndex:0,selectionInfo:{colorField:void 0,components:[],event:void 0,currentComponent:void 0,previousComponent:void 0}},O=Yr({brush:I,majorScale:u,actions:n,selections:r,picassoQ:i,selectionsFn:M});!function(e){var t=e.brush,n=e.interceptors,r=void 0===n?{}:n;Object.entries(r).forEach(function(e){var n=A(e,2),r=n[0],i=n[1];(Array.isArray(i)?i:[i]).forEach(function(e){t.intercept(r,e)})})}({brush:I,interceptors:k});var R=function(e){var t=e.chart,n=e.selectionActions,r=e.brush,i=e.actions,o=e.selectionInfo,a=e.selections,l=e.selectionEvents,s=function(e){var t=e.brush,n=e.chart,r=e.selectionInfo,i=e.brushEvents,o=void 0===i?{}:i,a=Object.entries(o).map(function(e){var i=A(e,2),o=i[0],a=i[1],l=function(){return a({chart:n,selectionInfo:r})};return t.on(o,l),[o,l]});return function(){a.forEach(function(e){var n=A(e,2),r=n[0],i=n[1];t.removeListener(r,i)})}}({brush:r,chart:t,selectionInfo:o,brushEvents:e.brushEvents}),u=ti({chart:t,selectionInfo:o,selectionActions:n,actions:i,selections:a,selectionEvents:l}),c=function(e){var t=e.actions;if(null==t||!t.lasso)return function(){};var n=!1,r=function(e){n||e.key!==Hr||(t.lasso.action(!0),n=!0)},i=function(e){e.key===Hr&&(t.lasso.action(!1),n=!1)};return document.addEventListener("keydown",r),document.addEventListener("keyup",i),function(){document.removeEventListener("keydown",r),document.removeEventListener("keyup",i)}}({actions:i});return function(){s(),u(),c()}}({chart:t,brush:I,actions:n,selections:r,selectionInfo:E.selectionInfo,selectionActions:{clear:f,reset:p},selectionEvents:m,brushEvents:v});if(l){var T=!0===l?F(Array(15)).map(function(e,t){return"qHyperCube/qMeasureInfo/".concat(t)}):l;O.allowSimultaneous(T)}return{unbindEvents:R,state:E,picassoSelections:O,brush:I}}var ii=["colorField","useLegendCube"];function oi(e){var t=e.chart,n=e.selections,r=e.actions,i=void 0!==r&&r,o=e.config,a=void 0===o?{}:o,l=ri({chart:t,actions:i,selections:n,picassoQ:Fr,config:a}),s=l.unbindEvents,u=l.state,c=l.picassoSelections,d=l.brush,f=a.custom,p=void 0===f?{}:f,h=a.legendAlias,m=void 0===h?void 0:h,g=a.setBrushAliases,v=void 0===g?$r:g;return{getIsDimensionLocked:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;return u.lockedDimensions[e]},getIsSelectionLocked:function(){var e,t,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return null!==(e=null==n||null===(t=n.isLocked)||void 0===t?void 0:t.call(n))&&void 0!==e?e:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return!(null==e||!e.length)&&e.filter(function(e){return"object"===_(e.data)&&Array.isArray(e.data.fields)}).every(function(e){return e.data.fields.every(function(e){var t=e.raw();return!(!t.qLocked&&t.qCardinal)})})}(r)},getIsSingleSelect:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:u.singleSelectIndex;return u.singleSelectDimensions[e]},getCanSelect:function(){return u.canSelect},getSelectionsObject:function(){return n},getSelectionInfo:function(){return u.selectionInfo},setLayout:function(e){var t=function(e){var t,n,r,i=e.selections,o=e.picassoSelections,a=e.layout,l={lockedDimensions:[],singleSelectDimensions:[]};null!=i&&null!==(t=i.isModal)&&void 0!==t&&t.call(i)&&i.confirm(),o.layout(a);var s=(null!==(n=null==a?void 0:a.qHyperCube)&&void 0!==n?n:{}).qDimensionInfo,u=void 0===s?[]:s;return l.lockedDimensions=u.map(function(e){return!!e.qLocked}),l.singleSelectDimensions=u.map(function(e,t){return _r({layout:a,path:"qHyperCube/qDimensionInfo/".concat(t)})}),l.singleSelectIndex=function(e){var t,n=((null==e?void 0:e.qHyperCube)||{}).qDimensionInfo,r=void 0===n?[]:n,i=r.map(function(e,t){var n;return!(e.qLocked||(null===(n=e.qCardinalities)||void 0===n?void 0:n.qHypercubeCardinal)<=1)&&t}).filter(function(e){return"number"==typeof e});return null!==(t=i[0])&&void 0!==t?t:Math.max(r.length-1,0)}(a),l.canSelect=0===u.length||u.some(function(e){return!e.qLocked}),l.dimensionLocked=!(null===(r=u[0])||void 0===r||!r.qLocked),l}({selections:n,picassoSelections:c,layout:e});Object.assign(u,t)},setFilteredFields:function(e){c.filteredFields(e)},setBrushAliases:function(e){var t=e.colorField,n=e.useLegendCube,r=void 0!==n&&n,i=L(e,ii),o=z({useLegendCube:r,colorField:t,brush:d,legendAlias:m},i);v(z(z({},o),{},{defaultFunc:function(){return $r(o)}}))},destroy:function(){s(),c.release()},custom:z({},p)}}var ai="'Source Sans Pro', 'Arial', 'sans-serif'",li="#333333",si="#595959",ui="#737373",ci="#cccccc",di="#e6e6e6";function fi(e){var t={};return[].concat(F(e),F([["","","color"],["object","","fontFamily"],["object","axis.label.name","color",si],["object","axis.label.name","fontFamily",ai],["object","axis.label.name","fontSize","12px"],["object","axis.line.major","color",ci],["object","axis.line.minor","color",di],["object","axis.title","color"],["object","axis.title","fontFamily",ai],["object","axis.title","fontSize","13px"],["object","grid.line.highContrast","color",di],["object","grid.line.major","color",ci],["object","grid.line.minor","color",di],["object","label.value","color",si],["object","label.value","fontFamily",ai],["object","label.value","fontSize","12px"],[!1,"label.value","darkColor",si],[!1,"label.value","lightColor",di],["object","outOfRange","color","#999"],["object","legend.title","color",li],["object","legend.title","fontFamily",ai],["object","legend.title","fontSize","15px"],["object","legend.label","color",si],["object","legend.label","fontFamily",ai],["object","legend.label","fontSize","13px"],["object","referenceLine.label.name","color",li],["object","referenceLine.label.name","fontFamily",ai],["object","referenceLine.label.name","fontSize","12px"],["object","referenceLine.outOfBounds","color",di],["object","referenceLine.outOfBounds","fontFamily",ai],["object","referenceLine.outOfBounds","fontSize","12px"],["object","referenceLine.outOfBounds","backgroundColor",ui,function(e){return"transparent"===e?ui:e}]])).reduce(function(e,n){var r="".concat(n[0],"-").concat(n[1],"-").concat(n[2],"}");return t[r]||(t[r]=!0,e.push(n)),e},[]).sort(function(e,t){return(e[0].split?e[0].split(".").length:0)-(t[0].split?t[0].split(".").length:0)})}var pi="object",hi=function(e){return e};function mi(e){var t=e.theme,n=e.id,r=e.transform,i=e.extend,o=e.matrix,a={},l=r.reduce(function(e,t){var n=A(t,2),r=n[0],i=n[1];return e[r]=i,e},{});return o.forEach(function(e){var r=A(e,5),i=r[0],o=r[1],s=r[2],u=r[3],c=r[4],d=void 0===c?function(e){return e}:c,f=function(e){var t=e.theme,n=e.base,r=e.path,i=e.attribute,o=e.defaultValue,a=void 0===o?void 0:o;if(!t||!1===n)return a;var l=t.getStyle(n,r,i);return void 0===l?a:l}({theme:t,base:i===pi&&n?"".concat(pi,".").concat(n):i,path:o,attribute:s,defaultValue:u}),p=(l["".concat(o,".").concat(s)]||hi)(d(f));Xt(a,[o,s].filter(Boolean).join("."),p)}),i.forEach(function(e){var t=A(e,2),n=t[0],r=t[1];Xt(a,n,r)}),a}function gi(e,t,n){const r=`${e}.fontFamily`,i=`${e}.fontSize`;return{fontFamilyItem:{component:"dropdown",ref:r,options:()=>t.getOptions(r),defaultValue:()=>t.getDefaultValue(r)},fontWrapperItem:{component:"inline-wrapper",items:{fontSizeItem:{component:"dropdown",ref:i,options:()=>t.getOptions(i),defaultValue:()=>t.getDefaultValue(i)},fontColorItem:{component:"color-picker",width:!1,ref:`${e}.color`,defaultValue:()=>({color:n.getStyle("object.funnelChart",e,"color")})}}}}}function vi(e,t,n){const r=function(e){var t=e.theme,n=e.translator,r=e.config,i=void 0===r?{}:r,o=e.flags,a=function(e){var t=e.config,n=void 0===t?{}:t,r=n.id,i=n.paths;return{id:void 0===r?Z:"".concat(Z,".").concat(r),paths:Array.isArray(i)?i:[]}}({config:i}),l=a.id,s=a.paths,u={};s.forEach(function(e){var r=e.split(".");ce(r);for(var i=u,a=0;a<r.length;a++){var s=r[a];a===r.length-1?i[s]=ae({theme:t,translator:n,id:l,path:e,flags:o}):void 0===i[s]&&(i[s]={}),i=i[s]}});var c=function(e){var t=e.split(".");ce(t);for(var n=u,r=0;r<t.length;r++){var i=t[r];if(void 0===n[i])throw new Error("font-resolver: Path '".concat(e,"' could not be resolved."));n=n[i]}return n};return u.getDefaultValue=function(e){return c(e).getDefaultValue()},u.getOptions=function(e){return c(e).getOptions()},u}({theme:e,translator:n,flags:t,config:{id:"funnelChart",paths:["axis.title","axis.label.name","label.value"]}});return{component:"styling-panel",show:!0,chartType:"funnelchart",translation:"LayerStyleEditor.component.styling",chartTitle:"Object.FunnelChart",subtitle:"LayerStyleEditor.component.styling",useGeneral:!0,useBackground:!0,items:{axisTitleSection:{component:"panel-section",label:"Dimension title",items:{dimensionTitleItems:{component:"items",ref:"components",key:"axis",items:gi("axis.title",r,e)}}},labelNameSection:{component:"panel-section",label:"Dimension value label",items:{dimensionTitleItems:{component:"items",ref:"components",key:"axis",items:gi("axis.label.name",r,e)}}},labelValueSection:{component:"panel-section",label:"Value Label",items:{labelItems:{component:"items",ref:"components",key:"label",items:{...gi("label.value",r,e),contrastColor:{component:"checkbox",type:"boolean",ref:"label.value.useContrastColor",translation:"properties.dataPoints.valuelabel.contrast",defaultValue:!0}}}}}}}}const yi={uses:"sorting"},bi=(e,t,n)=>{const r=n?.sense?.theme;return{uses:"settings",items:{presentation:{type:"items",label:"Presentation",grouped:!0,items:{funnelStyling:vi(r,t,e),funnelmode:{ref:"funnel.mode",label:"Funnel Mode",type:"string",component:"dropdown",options:[{value:"AREA",label:"Area"},{value:"HEIGHT",label:"Height"},{value:"WIDTH",label:"Width"},{value:"ORDER",label:"Ordering"}],defaultValue:"WIDTH"},dimensionTitle:{ref:"showDimensionTitle",type:"boolean",component:"switch",label:"Dimension title",defaultValue:!0,options:[{value:!0,label:"Auto"},{value:!1,label:"Off"}]},valuesAuto:{ref:"dataPoint.auto",type:"boolean",label:"Value labels",component:"switch",defaultValue:!0,options:[{value:!0,label:"Auto"},{value:!1,label:"Custom"}]},labelMode:{ref:"dataPoint.labelMode",type:"string",component:"dropdown",options:[{value:"none",label:"None"},{value:"share",label:"Share"},{value:"value",label:"Values"}],defaultValue:"share",show:e=>!e.dataPoint.auto}}},colorsAndLegend:{uses:"colorsAndLegend",translation:"Colors",items:{colors:{items:{colorByLabel:{show:!1},expressionLabel:{show:!1}}},legend:{show:!1}}}}}},xi={uses:"data",items:{dimensions:{uses:"dimensions",items:{others:{items:{suppressOther:{defaultValue:!0,show:!1}}}},disabledRef:""},measures:{uses:"measures",disabledRef:""}}};function wi({translator:e,flags:t,anything:n}){return{type:"items",component:"accordion",items:{data:xi,sorting:yi,settings:bi(e,t,n)}}}function qi(e){return{definition:wi(e),support:{export:!0,exportData:!0,snapshot:!0,viewData:!1},importProperties:null,exportProperties:null}}const Di=[{path:"/qHyperCubeDef",dimensions:{min:1,max:1,description:()=>"Segments"},measures:{min:1,max:1,description(e){switch(e.funnel.mode){case"WIDTH":return"Width";case"AREA":return"Area";case"HEIGHT":return"Height";case"ORDER":return"Order";default:return""}},added(e,t){2===t.qHyperCubeDef.qInterColumnSortOrder.length&&1!==t.qHyperCubeDef.qInterColumnSortOrder[0]&&(t.qHyperCubeDef.qInterColumnSortOrder=[1,0])}}}];function Si(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var ki,Ci;var Mi=function(){if(Ci)return ki;Ci=1;var e=Object.prototype.hasOwnProperty,t=Object.prototype.toString,n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=function(e){return"function"==typeof Array.isArray?Array.isArray(e):"[object Array]"===t.call(e)},o=function(n){if(!n||"[object Object]"!==t.call(n))return!1;var r,i=e.call(n,"constructor"),o=n.constructor&&n.constructor.prototype&&e.call(n.constructor.prototype,"isPrototypeOf");if(n.constructor&&!i&&!o)return!1;for(r in n);return void 0===r||e.call(n,r)},a=function(e,t){n&&"__proto__"===t.name?n(e,t.name,{enumerable:!0,configurable:!0,value:t.newValue,writable:!0}):e[t.name]=t.newValue},l=function(t,n){if("__proto__"===n){if(!e.call(t,n))return;if(r)return r(t,n).value}return t[n]};return ki=function e(){var t,n,r,s,u,c,d=arguments[0],f=1,p=arguments.length,h=!1;for("boolean"==typeof d&&(h=d,d=arguments[1]||{},f=2),(null==d||"object"!=typeof d&&"function"!=typeof d)&&(d={});f<p;++f)if(null!=(t=arguments[f]))for(n in t)r=l(d,n),d!==(s=l(t,n))&&(h&&s&&(o(s)||(u=i(s)))?(u?(u=!1,c=r&&i(r)?r:[]):c=r&&o(r)?r:{},a(d,{name:n,newValue:e(h,c,s)})):void 0!==s&&a(d,{name:n,newValue:s}));return d},ki}(),Ii=Si(Mi),Ni={dataRelatedPropertiesPaths:["qHyperCube.qGrandTotalRow","qHyperCube.qHasOtherValues","qHyperCube.qSize","qHyperCube.qDimensionInfo[].qAttrDimInfo","qHyperCube.qDimensionInfo[].qAttrExprInfo","qHyperCube.qDimensionInfo[].qCardinalities","qHyperCube.qDimensionInfo[].qMax","qHyperCube.qDimensionInfo[].qMin","qHyperCube.qDimensionInfo[].qStateCounts","qHyperCube.qMeasureInfo[].qApprMaxGlyphCount","qHyperCube.qMeasureInfo[].qAttrExprInfo","qHyperCube.qMeasureInfo[].qMax","qHyperCube.qMeasureInfo[].qMin","qHyperCube.qMeasureInfo[].qTrendLines","qHyperCube.qTreeNodesOnDim","qSelectionInfo","plugins[].validMeasureValue","plugins[].labelBackgroundColor","plugins[].labelColor","plugins[].hasBackground","plugins[].maxLabelWidth","plugins[].points[].validMeasureValue","plugins[].points[].labelBackgroundColor","plugins[].points[].labelColor","plugins[].points[].hasBackground","plugins[].points[].maxLabelWidth"]};function Ei(e){const{qHyperCube:t,...n}=e,{qAxisData:r,qDataPages:i,qStackedDataPages:o,qTreeDataPages:a,...l}=t,s=Ii(!0,{},{...n,qHyperCube:{...l}}),{dataRelatedPropertiesPaths:u}=Ni;function c(e,t){const n=t.indexOf("[]");if(-1===n)return void(void 0!==Yt(e,t)&&Xt(e,t,void 0));const r=t.substring(0,n),i=t.substring(n+2),o=i.startsWith(".")?i.substring(1):i;Yt(e,r,[]).forEach(e=>{o&&c(e,o)})}return u.forEach(e=>{c(s,e)}),s}var Oi={axes:{trackBy:function({isTime:e,isContinuous:t,isMeasure:n,isMajor:r}){return i=>{if(e||t||n){if("line"===i.type)return i.tickValue??"axis";if("text"===i.type)return`${i.tickValue} ${i.text}`;if("container"===i.type){const e=i.children.filter(e=>"text"===e.type).map(e=>e.text);return`${i.data.value} ${e.join("")}`}return Math.random()}if(r){if("line"===i.type&&void 0===i.tickValue)return"axis";const e=i.transform&&i.transform.match(/rotate/gi)?"rotated":"horizontal";return`${i.data.group?`${i.data.group.value} `:""}${i.data.value} ${i.text} ${e}`}return Math.random()}},compensateForLayoutChanges:function({isMeasure:e,isTime:t,isContinuous:n,isHorizontal:r,dock:i}){return({currentNodes:o,currentRect:a,previousRect:l})=>{const s=a.x-l.x,u=a.y-l.y,c=a.width-l.width,d=a.height-l.height;e?("left"===i&&o.forEach(e=>{"line"===e.type?(e.x1+=c,e.x2+=c):"text"===e.type&&(e.x+=c)}),"left"!==i&&"right"!==i||o.forEach(e=>{"line"===e.type&&(e.x1===e.x2?(e.y1=a.y,e.y2=e.y1+a.height):(Math.round(e.y1)<a.y||e.y1>a.y+a.height)&&(e.strokeWidth=0)),"text"===e.type&&(e.y<a.y||e.y>a.y+a.height)&&(e.fontSize="1px","#"===e.fill?.[0]&&(e.fill=`${e.fill.slice(0,1)}00${e.fill.slice(1)}`))}),"top"!==i&&"bottom"!==i||o.forEach(e=>{"line"===e.type&&(e.y1===e.y2?(e.x1=a.x,e.x2=e.x1+a.width):(Math.round(e.x1)<a.x||e.x1>a.x+a.width)&&(e.strokeWidth=0)),"text"===e.type&&(e.x<a.x||e.x>a.x+a.width)&&(e.fontSize="1px","#"===e.fill?.[0]&&(e.fill=`${e.fill.slice(0,1)}00${e.fill.slice(1)}`))})):t?o.forEach(e=>{"line"===e.type?e.y1===e.y2?e.x2+=c:e.x1===e.x2&&(e.x1-=s,e.x2-=s):"text"===e.type&&(e.x-=s)}):n||r?o.forEach(e=>{"line"===e.type&&e.y1===e.y2&&(e.x1+=s,e.x2+=s+c)}):o.forEach(e=>{"line"===e.type&&e.x1===e.x2&&(e.y1+=u,e.y2+=u+d)})}}},bars:{trackBy:function(e){return e.data.typeIndex?`${e.data.value} ${e.data.typeIndex.value}`:e.data.measureIndex?`${e.data.value} ${e.data.measureIndex.value}`:e.data.group?`${e.data.value} ${e.data.group.value}`:e.data.stack?`${e.data.value} ${e.data.stack.value}`:`${e.data.value}`},compensateForLayoutChanges:function({currentNodes:e,currentRect:t,previousRect:n}){const r=t.x-n.x,i=t.y-n.y;0===r&&0===i||e.forEach(e=>{e.children&&e.children.length>0&&e.children.forEach(e=>{void 0!==e.x&&void 0!==e.y?(e.x-=r,e.y-=i):e.transform=`translate(${-r}, ${-i})`})})}},barOobs:{compensateForLayoutChanges:function({currentNodes:e,currentRect:t,previousRect:n}){const r=t.x-n.x;0===t.y-n.y&&0===r||e.forEach(e=>{e.children&&e.children.length>0&&e.children.forEach(e=>{e.opacity=0})})}},labels:{trackBy:function(e){if("rect"===e.type)return"-3"===e.data?Math.random():`${e.type} ${e.data} ${e.rotation}`;const t=e.transform&&e.transform.match(/rotate/gi)?"rotated":"horizontal";return`${e.type} ${e.data} ${e.text} ${t}`},compensateForLayoutChanges:function({currentNodes:e,currentRect:t,previousRect:n}){const r=t.x-n.x,i=t.y-n.y;0===r&&0===i||e.forEach(e=>{e.transform&&e.transform.match(/rotate\(-90/gi)?(e.x+=i,e.y-=r):(e.x-=r,e.y-=i)})},linkData:function(e){return e.data.measureIndex?`${e.data.value} ${e.data.measureIndex.value}`:e.data.group?`${e.data.value} ${e.data.group.value}`:e.data.stack?`${e.data.value} ${e.data.stack.value}`:`${e.data.value}`}},lines:{trackBy:function(e){return"line"===e.type?e.value??Math.random():"path"===e.type?`${e.generatorType} ${e.layerObj.id} ${e.data.source.key}`:Math.random()},compensateForLayoutChanges:function({currentNodes:e,currentRect:t,previousRect:n}){const r=t.x-n.x,i=t.y-n.y;e.forEach(e=>{if(void 0!==e.x1&&void 0!==e.y1)e.y1===e.y2?(e.x2=e.x1+t.width,e.y1-=i,e.y2-=i):e.x1===e.x2&&(e.y2=e.y1+t.height,e.x1-=r,e.x2-=r);else{const t="x"===e.major.p?r/e.major.size:i/e.major.size,n="y"===e.minor.p?i/e.minor.size:r/e.minor.size;e.points.forEach(e=>{e.modified||(e.major-=t,e.minor-=n,e.minor0-=n,e.modified=!0)})}})}},lineOobs:{compensateForLayoutChanges:function({currentNodes:e,currentRect:t,previousRect:n}){const r=t.x-n.x;0===t.y-n.y&&0===r||e.forEach(e=>{e.opacity=0})}},markers:{trackBy:function(e){return e.data.line?`${e.data.line.value} ${e.data.major.value}`:`${e.data.major.value}`},compensateForLayoutChanges:function({currentNodes:e,currentRect:t,previousRect:n}){const r=t.x-n.x,i=t.y-n.y;0===r&&0===i||e.forEach(e=>{switch(e.type){case"circle":e.cx-=r,e.cy-=i;break;case"rect":e.x-=r,e.y-=i;break;case"path":e.transform=`translate(${-r}, ${-i})`}})}},points:{trackBy:function(e){return e.data.line?`${e.data.line.value} ${e.data.major.value}`:`${e.data.major.value}`},compensateForLayoutChanges:function({currentNodes:e,currentRect:t,previousRect:n}){const r=t.x-n.x,i=t.y-n.y;0===r&&0===i||e.forEach(e=>{"image"===e.type?(e.x-=r,e.y-=i):(e.cx-=r,e.cy-=i)})}},refLineLabels:{trackBy:function(e){if(void 0!==e.value){if("rect"===e.type)return`${e.value}`;if("text"===e.type)return`${e.value} ${e.text}`}return Math.random()},compensateForLayoutChanges:function({currentNodes:e,currentRect:t,previousRect:n}){const r=t.x-n.x,i=t.y-n.y,o=t.width-n.width,a=t.height-n.height;let l=-r,s=-i;e.forEach(e=>{switch(e.dock){case"right":r>0&&(l=t.width);break;case"left":o<0&&(l=-n.width);break;case"top":a<0&&(s=-n.height);break;case"bottom":i>0&&(s=t.height)}switch(e.type){case"text":case"rect":e.x+=l,e.y+=s;break;case"circle":e.cx+=l,e.cy+=s;break;case"path":e.transform=`translate(${l}, ${s})`}})}},shadowBars:{trackBy:function(){return Math.random()}},cacheProperties:function({viewCache:e,layout:t}){const n=Ei(t);e.set("dataIndependentProperties",JSON.stringify(n))},propertiesHaveChanged:function({viewCache:e,layout:t}){const n=Ei(t);return e.get("dataIndependentProperties")!==JSON.stringify(n)},nonUpdatingNode:{trackBy:function(){return Math.random()}}};function Ri(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function Ti(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function zi(){}[["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}]].forEach(([e,{width:t,height:n}])=>{});var Li=.7,Pi=1/Li,ji="\\s*([+-]?\\d+)\\s*",Ai="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Fi="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",_i=/^#([0-9a-f]{3,8})$/,$i=new RegExp(`^rgb\\(${ji},${ji},${ji}\\)$`),Hi=new RegExp(`^rgb\\(${Fi},${Fi},${Fi}\\)$`),Bi=new RegExp(`^rgba\\(${ji},${ji},${ji},${Ai}\\)$`),Ui=new RegExp(`^rgba\\(${Fi},${Fi},${Fi},${Ai}\\)$`),Vi=new RegExp(`^hsl\\(${Ai},${Fi},${Fi}\\)$`),Wi=new RegExp(`^hsla\\(${Ai},${Fi},${Fi},${Ai}\\)$`),Ki={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 Ji(){return this.rgb().formatHex()}function Gi(){return this.rgb().formatRgb()}function Yi(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=_i.exec(e))?(n=t[1].length,t=parseInt(t[1],16),6===n?Zi(t):3===n?new eo(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===n?Xi(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===n?Xi(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=$i.exec(e))?new eo(t[1],t[2],t[3],1):(t=Hi.exec(e))?new eo(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=Bi.exec(e))?Xi(t[1],t[2],t[3],t[4]):(t=Ui.exec(e))?Xi(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=Vi.exec(e))?ao(t[1],t[2]/100,t[3]/100,1):(t=Wi.exec(e))?ao(t[1],t[2]/100,t[3]/100,t[4]):Ki.hasOwnProperty(e)?Zi(Ki[e]):"transparent"===e?new eo(NaN,NaN,NaN,0):null}function Zi(e){return new eo(e>>16&255,e>>8&255,255&e,1)}function Xi(e,t,n,r){return r<=0&&(e=t=n=NaN),new eo(e,t,n,r)}function Qi(e){return e instanceof zi||(e=Yi(e)),e?new eo((e=e.rgb()).r,e.g,e.b,e.opacity):new eo}function eo(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}function to(){return`#${oo(this.r)}${oo(this.g)}${oo(this.b)}`}function no(){const e=ro(this.opacity);return`${1===e?"rgb(":"rgba("}${io(this.r)}, ${io(this.g)}, ${io(this.b)}${1===e?")":`, ${e})`}`}function ro(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function io(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function oo(e){return((e=io(e))<16?"0":"")+e.toString(16)}function ao(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new so(e,t,n,r)}function lo(e){if(e instanceof so)return new so(e.h,e.s,e.l,e.opacity);if(e instanceof zi||(e=Yi(e)),!e)return new so;if(e instanceof so)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,l=o-i,s=(o+i)/2;return l?(a=t===o?(n-r)/l+6*(n<r):n===o?(r-t)/l+2:(t-n)/l+4,l/=s<.5?o+i:2-o-i,a*=60):l=s>0&&s<1?0:a,new so(a,l,s,e.opacity)}function so(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function uo(e){return(e=(e||0)%360)<0?e+360:e}function co(e){return Math.max(0,Math.min(1,e||0))}function fo(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}Ri(zi,Yi,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Ji,formatHex:Ji,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return lo(this).formatHsl()},formatRgb:Gi,toString:Gi}),Ri(eo,function(e,t,n,r){return 1===arguments.length?Qi(e):new eo(e,t,n,null==r?1:r)},Ti(zi,{brighter(e){return e=null==e?Pi:Math.pow(Pi,e),new eo(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=null==e?Li:Math.pow(Li,e),new eo(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new eo(io(this.r),io(this.g),io(this.b),ro(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:to,formatHex:to,formatHex8:function(){return`#${oo(this.r)}${oo(this.g)}${oo(this.b)}${oo(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:no,toString:no})),Ri(so,function(e,t,n,r){return 1===arguments.length?lo(e):new so(e,t,n,null==r?1:r)},Ti(zi,{brighter(e){return e=null==e?Pi:Math.pow(Pi,e),new so(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=null==e?Li:Math.pow(Li,e),new so(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 eo(fo(e>=240?e-240:e+120,i,r),fo(e,i,r),fo(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new so(uo(this.h),co(this.s),co(this.l),ro(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=ro(this.opacity);return`${1===e?"hsl(":"hsla("}${uo(this.h)}, ${100*co(this.s)}%, ${100*co(this.l)}%${1===e?")":`, ${e})`}`}}));const po=Math.PI/180,ho=180/Math.PI,mo=.96422,go=.82521,vo=4/29,yo=6/29,bo=3*yo*yo,xo=yo*yo*yo;function wo(e){if(e instanceof qo)return new qo(e.l,e.a,e.b,e.opacity);if(e instanceof Io)return No(e);e instanceof eo||(e=Qi(e));var t,n,r=Co(e.r),i=Co(e.g),o=Co(e.b),a=Do((.2225045*r+.7168786*i+.0606169*o)/1);return r===i&&i===o?t=n=a:(t=Do((.4360747*r+.3850649*i+.1430804*o)/mo),n=Do((.0139322*r+.0971045*i+.7141733*o)/go)),new qo(116*a-16,500*(t-a),200*(a-n),e.opacity)}function qo(e,t,n,r){this.l=+e,this.a=+t,this.b=+n,this.opacity=+r}function Do(e){return e>xo?Math.pow(e,1/3):e/bo+vo}function So(e){return e>yo?e*e*e:bo*(e-vo)}function ko(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function Co(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function Mo(e,t,n,r){return 1===arguments.length?function(e){if(e instanceof Io)return new Io(e.h,e.c,e.l,e.opacity);if(e instanceof qo||(e=wo(e)),0===e.a&&0===e.b)return new Io(NaN,0<e.l&&e.l<100?0:NaN,e.l,e.opacity);var t=Math.atan2(e.b,e.a)*ho;return new Io(t<0?t+360:t,Math.sqrt(e.a*e.a+e.b*e.b),e.l,e.opacity)}(e):new Io(e,t,n,null==r?1:r)}function Io(e,t,n,r){this.h=+e,this.c=+t,this.l=+n,this.opacity=+r}function No(e){if(isNaN(e.h))return new qo(e.l,0,0,e.opacity);var t=e.h*po;return new qo(e.l,Math.cos(t)*e.c,Math.sin(t)*e.c,e.opacity)}Ri(qo,function(e,t,n,r){return 1===arguments.length?wo(e):new qo(e,t,n,null==r?1:r)},Ti(zi,{brighter(e){return new qo(this.l+18*(null==e?1:e),this.a,this.b,this.opacity)},darker(e){return new qo(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 eo(ko(3.1338561*(t=mo*So(t))-1.6168667*(e=1*So(e))-.4906146*(n=go*So(n))),ko(-.9787684*t+1.9161415*e+.033454*n),ko(.0719453*t-.2289914*e+1.4052427*n),this.opacity)}})),Ri(Io,Mo,Ti(zi,{brighter(e){return new Io(this.h,this.c,this.l+18*(null==e?1:e),this.opacity)},darker(e){return new Io(this.h,this.c,this.l-18*(null==e?1:e),this.opacity)},rgb(){return No(this).rgb()}}));var Eo,Oo,Ro={isDark:function(e){return Mo(e).l<70}};function To(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}1===(Eo=To).length&&(Oo=Eo,Eo=function(e,t){return To(Oo(e),t)});var zo="$";function Lo(){}function Po(e,t){var n=new Lo;if(e instanceof Lo)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 jo(){}Lo.prototype=Po.prototype={constructor:Lo,has:function(e){return zo+e in this},get:function(e){return this[zo+e]},set:function(e,t){return this[zo+e]=t,this},remove:function(e){var t=zo+e;return t in this&&delete this[t]},clear:function(){for(var e in this)e[0]===zo&&delete this[e]},keys:function(){var e=[];for(var t in this)t[0]===zo&&e.push(t.slice(1));return e},values:function(){var e=[];for(var t in this)t[0]===zo&&e.push(this[t]);return e},entries:function(){var e=[];for(var t in this)t[0]===zo&&e.push({key:t.slice(1),value:this[t]});return e},size:function(){var e=0;for(var t in this)t[0]===zo&&++e;return e},empty:function(){for(var e in this)if(e[0]===zo)return!1;return!0},each:function(e){for(var t in this)t[0]===zo&&e(this[t],t.slice(1),this)}};var Ao=Po.prototype;jo.prototype={constructor:jo,has:Ao.has,add:function(e){return this[zo+(e+="")]=e,this},remove:Ao.remove,clear:Ao.clear,values:Ao.keys,size:Ao.size,empty:Ao.empty,each:Ao.each},Ii.bind(null,!0);const Fo=[[2,4,6],[2,4],[3]],_o=[,[,,[[1,2]],[[1,2,3],[1,3]],[[1,2,4],[1,4]],[[1,2,4],[1,5]],[[1,2,4,6],[2,4,6],[1,3,6],[1,6]],[[1,2,4,6],[2,4,6],[1,3,6],[1,7]],[[1,2,4,8],[2,4,8],[1,8]],[[1,2,4,8],[2,4,8],[1,3,9],[1,9]],[[1,2,4,6,10],[1,2,4,10],[1,3,10],[3,10],[1,10]]],[,,,[[2,3]],[[2,3,4],[2,4]],[[2,3,4],[2,4],[2,5]],[[2,4,6],[2,6]],[[2,4,6],[2,6],[2,7]],[[2,4,8],[2,8]],[[2,4,8],[2,8],[2,9]],[[2,4,6,10],[2,4,10],[5,10],[3,10]]],[,,,,[[3,4]],[[3,4,5],[3,5]],[[3,4,5,6],[3,6]],[[3,4,5,6],[3,5,7],[3,7]],[[3,4,5,6,8],[3,5,7],[4,8],[3,8]],[[3,4,5,6,8],[3,4,6,9],[3,4,6,8],[3,6,9],[4,8],[3,9]],[[4,6,10],[5,10],[3,10]]],[,,,,,[[4,5]],[[4,5,6],[4,6]],[[4,5,6,7],[4,5,6],[4,6]],[[4,5,6,7,8],[4,5,6,7],[4,6,8],[4,8]],[[4,5,6,7,8],[4,6,9],[4,6,8],[4,8]],[[4,6,10],[5,7,9],[5,10],[4,10]]],[,,,,,,[[5,6]],[[5,6,7],[5,7]],[[5,6,7,8],[5,6,7],[6,8]],[[5,6,7,8,9],[5,6,7,8],[5,7,9],[5,9]],[[6,8,10],[5,10]]],[,,,,,,,[[6,7]],[[6,7,8],[6,8]],[[6,7,8,9],[6,7,8],[6,9]],[[6,7,8,9,10],[6,8,10],[6,10]]],[,,,,,,,,[[7,8]],[[7,8,9],[7,9]],[[7,8,9,10],[8,10],[7,10],[7,9]]],[,,,,,,,,,[[8,9]],[[8,9,10],[8,10]]],[,,,,,,,,,,[[9,10]]]];function $o(e,t,n){const r=e?e.length:0;let i,o=void 0===t?Number.MAX_VALUE:e[0]/t;for(i=1;i<r;i++)o=Math.min(o,e[i]/e[i-1]);void 0!==n&&(o=Math.min(o,n/e[r-1])),e.splice(0,0,o)}function Ho(e,t,n){let r;const i=e?e.length:0;for(r=0;r<i;r++)$o(e[r],t,n)}function Bo(){return/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)?void 0:"svg"}!function(){let e,t;for(Ho(Fo,1,10),e=0;e<_o.length;e++)if(_o[e])for(t=0;t<_o[e].length;t++)Array.isArray(_o[e][t])&&Ho(_o[e][t])}();var Uo=class e{constructor(e,t){this._key=e,this._value=t}getKey(){return this._key}getValue(){return this._value}equals(t){return t instanceof e&&(this._key===t._key&&this._value===t._value)}static newInstanceIfNeeded(){let t,n,r=arguments[0];return"string"==typeof arguments[1]?(t=arguments[1],n=r.length):(n=arguments[1],t=arguments[2]),t&&r?(r.length>n&&(r=r.substr(0,n)),new e(r,t)):null}},Vo=class e{setValue(e){this._nextMap=null,this._value=e}getNextNode(e){return this._nextMap?this._nextMap[e]:null}put(t,n,r){let i,o;if(t.length===n)return o=this._value,this.setValue(r),o;const a=t.charAt(n);return this._nextMap?(i=this._nextMap[a],i||(i=new e,this._nextMap[a]=i)):(this._nextMap={},i=new e,this._nextMap[a]=i),i.put(t,n+1,r)}get(e,t){if(e.length<=t)return this._value;const n=this.getNextNode(e.charAt(t));return n?n.get(e,t+1):null}getLongestMatch(e,t){if(e.length<=t)return Uo.newInstanceIfNeeded(e,this._value);const n=this.getNextNode(e.charAt(t));if(!n)return Uo.newInstanceIfNeeded(e,t,this._value);const r=n.getLongestMatch(e,t+1);return r||Uo.newInstanceIfNeeded(e,t,this._value)}},Wo=class{constructor(){this.clear()}getLongestMatch(e){return this.root&&e?this.root.getLongestMatch(e,0):null}getMaxKeyLength(){return this.maxKeyLen}clear(){this.root=null,this.maxKeyLen=0,this.size=0}put(e,t){this.root||(this.root=new Vo);const n=this.root.put(e,0,t);return n||(e.length>this.maxKeyLen&&(this.maxKeyLen=e.length),this.size++,null)}};(()=>{const e=[],t=[],n=new Wo;let r,i,o;for(r in e["""]="34",e["&"]="38",e["<"]="60",e[">"]="62",e[" "]="160",e["¡"]="161",e["¢"]="162",e["£"]="163",e["¤"]="164",e["¥"]="165",e["¦"]="166",e["§"]="167",e["¨"]="168",e["©"]="169",e["ª"]="170",e["«"]="171",e["¬"]="172",e["­"]="173",e["®"]="174",e["¯"]="175",e["°"]="176",e["±"]="177",e["²"]="178",e["³"]="179",e["´"]="180",e["µ"]="181",e["¶"]="182",e["·"]="183",e["¸"]="184",e["¹"]="185",e["º"]="186",e["»"]="187",e["¼"]="188",e["½"]="189",e["¾"]="190",e["¿"]="191",e["À"]="192",e["Á"]="193",e["Â"]="194",e["Ã"]="195",e["Ä"]="196",e["Å"]="197",e["Æ"]="198",e["Ç"]="199",e["È"]="200",e["É"]="201",e["Ê"]="202",e["Ë"]="203",e["Ì"]="204",e["Í"]="205",e["Î"]="206",e["Ï"]="207",e["Ð"]="208",e["Ñ"]="209",e["Ò"]="210",e["Ó"]="211",e["Ô"]="212",e["Õ"]="213",e["Ö"]="214",e["×"]="215",e["Ø"]="216",e["Ù"]="217",e["Ú"]="218",e["Û"]="219",e["Ü"]="220",e["Ý"]="221",e["Þ"]="222",e["ß"]="223",e["à"]="224",e["á"]="225",e["â"]="226",e["ã"]="227",e["ä"]="228",e["å"]="229",e["æ"]="230",e["ç"]="231",e["è"]="232",e["é"]="233",e["ê"]="234",e["ë"]="235",e["ì"]="236",e["í"]="237",e["î"]="238",e["ï"]="239",e["ð"]="240",e["ñ"]="241",e["ò"]="242",e["ó"]="243",e["ô"]="244",e["õ"]="245",e["ö"]="246",e["÷"]="247",e["ø"]="248",e["ù"]="249",e["ú"]="250",e["û"]="251",e["ü"]="252",e["ý"]="253",e["þ"]="254",e["ÿ"]="255",e["&OElig"]="338",e["&oelig"]="339",e["&Scaron"]="352",e["&scaron"]="353",e["&Yuml"]="376",e["&fnof"]="402",e["&circ"]="710",e["&tilde"]="732",e["&Alpha"]="913",e["&Beta"]="914",e["&Gamma"]="915",e["&Delta"]="916",e["&Epsilon"]="917",e["&Zeta"]="918",e["&Eta"]="919",e["&Theta"]="920",e["&Iota"]="921",e["&Kappa"]="922",e["&Lambda"]="923",e["&Mu"]="924",e["&Nu"]="925",e["&Xi"]="926",e["&Omicron"]="927",e["&Pi"]="928",e["&Rho"]="929",e["&Sigma"]="931",e["&Tau"]="932",e["&Upsilon"]="933",e["&Phi"]="934",e["&Chi"]="935",e["&Psi"]="936",e["&Omega"]="937",e["&alpha"]="945",e["&beta"]="946",e["&gamma"]="947",e["&delta"]="948",e["&epsilon"]="949",e["&zeta"]="950",e["&eta"]="951",e["&theta"]="952",e["&iota"]="953",e["&kappa"]="954",e["&lambda"]="955",e["&mu"]="956",e["&nu"]="957",e["&xi"]="958",e["&omicron"]="959",e["&pi"]="960",e["&rho"]="961",e["&sigmaf"]="962",e["&sigma"]="963",e["&tau"]="964",e["&upsilon"]="965",e["&phi"]="966",e["&chi"]="967",e["&psi"]="968",e["&omega"]="969",e["&thetasym"]="977",e["&upsih"]="978",e["&piv"]="982",e["&ensp"]="8194",e["&emsp"]="8195",e["&thinsp"]="8201",e["&zwnj"]="8204",e["&zwj"]="8205",e["&lrm"]="8206",e["&rlm"]="8207",e["&ndash"]="8211",e["&mdash"]="8212",e["&lsquo"]="8216",e["&rsquo"]="8217",e["&sbquo"]="8218",e["&ldquo"]="8220",e["&rdquo"]="8221",e["&bdquo"]="8222",e["&dagger"]="8224",e["&Dagger"]="8225",e["&bull"]="8226",e["&hellip"]="8230",e["&permil"]="8240",e["&prime"]="8242",e["&Prime"]="8243",e["&lsaquo"]="8249",e["&rsaquo"]="8250",e["&oline"]="8254",e["&frasl"]="8260",e["&euro"]="8364",e["&image"]="8365",e["&weierp"]="8472",e["&real"]="8476",e["&trade"]="8482",e["&alefsym"]="8501",e["&larr"]="8592",e["&uarr"]="8593",e["&rarr"]="8594",e["&darr"]="8595",e["&harr"]="8596",e["&crarr"]="8629",e["&lArr"]="8656",e["&uArr"]="8657",e["&rArr"]="8658",e["&dArr"]="8659",e["&hArr"]="8660",e["&forall"]="8704",e["&part"]="8706",e["&exist"]="8707",e["&empty"]="8709",e["&nabla"]="8711",e["&isin"]="8712",e["¬in"]="8713",e["&ni"]="8715",e["&prod"]="8719",e["&sum"]="8721",e["&minus"]="8722",e["&lowast"]="8727",e["&radic"]="8730",e["&prop"]="8733",e["&infin"]="8734",e["&ang"]="8736",e["&and"]="8743",e["&or"]="8744",e["&cap"]="8745",e["&cup"]="8746",e["&int"]="8747",e["&there4"]="8756",e["&sim"]="8764",e["&cong"]="8773",e["&asymp"]="8776",e["&ne"]="8800",e["&equiv"]="8801",e["&le"]="8804",e["&ge"]="8805",e["&sub"]="8834",e["&sup"]="8835",e["&nsub"]="8836",e["&sube"]="8838",e["&supe"]="8839",e["&oplus"]="8853",e["&otimes"]="8855",e["&perp"]="8869",e["&sdot"]="8901",e["&lceil"]="8968",e["&rceil"]="8969",e["&lfloor"]="8970",e["&rfloor"]="8971",e["&lang"]="9001",e["&rang"]="9002",e["&loz"]="9674",e["&spades"]="9824",e["&clubs"]="9827",e["&hearts"]="9829",e["&diams"]="9830",e)"function"!=typeof e[r]&&e.hasOwnProperty(r)&&(t[e[r]]=r);for(i in t)"function"!=typeof t[i]&&t.hasOwnProperty(i)&&(o=t[i].toLowerCase().substr(1),n.put(o,String.fromCharCode(i)))})(),"undefined"!=typeof document&&document.createElement("div");for(let e=0;e<255;e++)e>=48&&e<=57||e>=65&&e<=90||e>=97&&e<=122||e.toString(16);function Ko(e){const t=e.node.desc&&e.node.desc.share;return t?e.formatter("share")(t):""}function Jo(e){return e.formatter("num")(e.node.data.num.value)}function Go({data:e}){return e?e.label:""}function Yo(e){if(e.dataPoint.auto)return Ko;switch(e.dataPoint.labelMode){case"share":default:return Ko;case"value":return Jo;case"none":return null}}function Zo(e,t,n,r){const i=r.axis.label.getStyle(),o=r.label.value.getStyle(),a=t.getStyles().label.value;return{type:"labels",key:"funnel-labels",renderer:Bo(),layout:{displayOrder:2},settings:{sources:[{component:"fun",selector:".labelLeft",strategy:{type:"rows",settings:{align:0,fill:i.fill,fontSize:parseInt(i.fontSize,10),fontFamily:i.fontFamily,labels:[{label:Go}],linkData:e=>`${e.data.value} ${Go(e)}`}}},{component:"fun",selector:".labelCenter",strategy:{type:"rows",settings:{align:.5,fill:o.useContrastColor?({node:e})=>(e=>Ro.isDark(e.desc.fill)?a.lightColor:a.darkColor)(e):o.fill,fontSize:parseInt(o.fontSize,10),fontFamily:o.fontFamily,labels:[{label:Yo(e)}],linkData:t=>"none"===e.dataPoint.labelMode?Math.random():`${t.data.value} ${Yo(e)(t)}`}}}]},animations:{enabled:n,trackBy:e=>e.data}}}function Xo(e,t){if(!e.showDimensionTitle||!e.qHyperCube.qDimensionInfo[0].qFallbackTitle)return!1;const n=e.qHyperCube.qDimensionInfo[0].qFallbackTitle,r=t.axis.title.getStyle();return{type:"text",key:"dimension-title",renderer:Bo(),text:n,layout:{dock:"top"},style:{text:{fill:r.fill,fontSize:r.fontSize,fontFamily:r.fontFamily}}}}function Qo({picasso:e}){const t=n(),c=r(),d=i(),f=o(),p=a(),h=l(),[m,g]=s(),[v,y]=s(),[b,x]=s(),[w,q]=s();return u(()=>{const n=function(e){var t,n,r,i,o=e.picasso,a=e.model,l=e.app,s=e.translator,u=e.layoutService,c=void 0===u?void 0:u,d=e.createConfig,f=void 0===d?Kt:d,p=e.config,h=void 0===p?{}:p,m=e.custom,g=void 0===m?{}:m,v=h.localeInfo,y=h.key,b=h.theme,x=void 0===b?void 0:b,w=h.auto,q=void 0===w?void 0:w,D=h.definitionPath,S=null==c||null===(t=c.getLayout)||void 0===t?void 0:t.call(c),k={theme:x,key:y,localeInfo:v,layout:S,hc:null==c||null===(n=c.getHyperCube)||void 0===n?void 0:n.call(c),legendProps:null==c||null===(r=c.getLayoutValue)||void 0===r?void 0:r.call(c,"legend"),colorProps:z(z({},null==c||null===(i=c.getLayoutValue)||void 0===i?void 0:i.call(c,"color")),{},{useBaseColors:S?Ut(S):void 0})},C=Ht({picasso:o,model:a,app:l,translator:s,auto:q});!1!==q&&C.auto(function(e){return q?q({layout:e,defaultAuto:Wt}):Wt(e)});var M=!1,I={getColor:function(){return C.color()},getPaletteColor:function(e){var t=e.index,n=e.color;return C.resolveUIColor({index:t,color:n})},getData:function(){return C.data()},getDatumProps:function(e){return C.datumProps(e)},getSnapshotData:function(){return C.getSnapshotData(D)},getSettingsForMeasure:function(e){return C.settingsForMeasure(e)},getSettings:function(){return C.settings()},getLegend:function(e,t){return C.legend(e,t)},getScales:function(){return C.scales()},getPalettes:function(){return C.palettes()},isSelectionLocked:function(e){var t=e.isMeasureSelectionLocked;return C.isSelectionLocked({isMeasureSelectionLocked:t})},isInitialized:function(){return M},custom:z({},g),initialize:function(){var e=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}).createConfig,t=(void 0===e?f:e)({getUseBaseColors:Ut}),n=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return z(z(z({},e),t),{},{colorProps:z(z({},e.colorProps),t.colorProps||{})})}(k,t);return C.config(n),C.getAuxiliarySettings(D).then(function(){M=!0})}};return I}({picasso:e,model:d,app:f,translator:p,config:{auto:!1,key:"fill"}});t.style.overflow="hidden";const r=e({renderer:{prio:[h.renderer||"svg"]}}).chart({element:t,data:[],settings:{}}),i=oi({chart:r,selections:c,config:{selectionActions:!1}});return x(i),y(n),g(r),q(function(){var e={};return{get:function(t){return e[t]},set:function(t,n){return e[t]=n,n},has:function(t){return t in e},remove:function(t){delete e[t]},empty:function(){e={}}}}()),()=>{i.destroy(),r.destroy()}},[]),[m,v,b,w]}function ea({picasso:e}){const t=c(),n=d(),r=f(),i=p(),o=h(),a=m().qLocaleInfo,[s,y,b,x]=Qo({picasso:e}),w=l(),q=()=>{const e=s.element.clientWidth!==x.get("width")||s.element.clientHeight!==x.get("height");return!1!==w.chartAnimations&&!e&&!Oi.propertiesHaveChanged({viewCache:x,layout:t})},[D]=g(()=>{if(!y)return Promise.resolve();const r=function(e){return{layout:e,keys:{SCALE:{FILL:"fill"},COMPONENT:{FUNNEL:"fun",FUNNEL_LABELS:"funnel-labels",DIMENSION_TITLE:"dimension-title"}}}}(t),i=function(e){var t=e.picassoInstance,n=e.plugins,r=e.pluginArgs,i=void 0===r?{}:r,o={initialized:!1,definitions:[]};return{initialize:function(){return O(P().m(function e(){var r,a,l,s;return P().w(function(e){for(;;)switch(e.n){case 0:if(!o.initialized){e.n=1;break}return e.a(2);case 1:return a=Promise.all(n.filter(function(e){return"custom-component"===e.info.type}).map(function(){var e=O(P().m(function e(n){var r;return P().w(function(e){for(;;)switch(e.n){case 0:if(n.info.componentName){e.n=1;break}throw new Error("plugin-service: Custom component is missing componentName");case 1:return e.n=2,n.fn(z({},i));case 2:if("object"===_(r=e.v)){e.n=3;break}throw new Error("plugin-service: Custom component needs to be an object");case 3:t.component(n.info.componentName,r);case 4:return e.a(2)}},e)}));return function(t){return e.apply(this,arguments)}}())),l=Promise.all(n.filter(function(e){return"component-definition"===e.info.type}).map(function(e){return e.fn(z({},i))})),e.n=2,Promise.all([a,l]);case 2:s=e.v,o.initialized=!0,(r=o.definitions).push.apply(r,F(s[1]));case 3:return e.a(2)}},e)}))()},extendComponents:function(e){return o.initialized?(o.definitions.filter(Boolean).forEach(function(t){var n=A(e.filter(function(e){return e.key&&e.key===t.key}),1)[0];if(n){var r=pe(!0,{},n.brush);pe(!0,n,t),t.brush&&(n.brush=function(e,t){return"object"===_(e)&&Object.keys(e).length?(Array.isArray(t.consume)&&(e.consume=Qt({originalArray:e.consume,newArray:t.consume,matchKey:"context"})),Array.isArray(t.trigger)&&(e.trigger=Qt({originalArray:e.trigger,newArray:t.trigger,matchKey:"on"})),e):t}(r,t.brush))}else e.push(t)}),e):e}}}({picassoInstance:e,plugins:o,pluginArgs:r});return Promise.all([y.initialize({createConfig:({getUseBaseColors:e})=>({theme:n,colorProps:{...t.color,useBaseColors:e(t)},layout:t,hc:t.qHyperCube})}),i.initialize()]).then(()=>i)},[t,y]);u(()=>{if(!s||!y||!D)return;const e=[{type:"q",key:"qHyperCube",data:t.qHyperCube,config:{localeInfo:a}},...y.getData()],i=function(e){var t=e.theme,n=e.config,r=void 0===n?{}:n,i=r.id,o=r.resolve,a=void 0===o?[]:o,l=r.transform,s=void 0===l?[]:l,u=r.extend,c=void 0===u?[]:u,d={theme:t,matrix:fi(a),styles:void 0};return d.styles=mi({theme:t,id:i,transform:s,extend:c,matrix:d.matrix}),{getStyles:function(){return d.styles},getTheme:function(){return d.theme},setTheme:function(e){d.theme=e,d.styles=mi({theme:e,id:i,transform:s,extend:c,matrix:d.matrix})}}}({theme:n,config:{id:"funnelChart"}}),o=function({layout:e,themeService:t}){const n=t.getStyles(),r=t=>e.components?.find(e=>e.key===t)??void 0;return{axis:{title:{getStyle:()=>({fontFamily:r("axis")?.axis?.title?.fontFamily??n.axis.title.fontFamily,fontSize:r("axis")?.axis?.title?.fontSize??n.axis.title.fontSize,fill:r("axis")?.axis?.title?.color?.color??n.axis.title.color})},label:{getStyle:()=>({fontSize:r("axis")?.axis?.label?.name?.fontSize??n.axis.label.name.fontSize,fontFamily:r("axis")?.axis?.label?.name?.fontFamily??n.axis.label.name.fontFamily,fill:r("axis")?.axis?.label?.name?.color?.color??n.axis.label.name.color})}},label:{value:{getStyle:()=>({fontSize:r("label")?.label?.value?.fontSize??n.label.value.fontSize,fontFamily:r("label")?.label?.value?.fontFamily??n.label.value.fontFamily,fill:r("label")?.label?.value?.color?.color??n.label.value.color,useContrastColor:r("label")?.label?.value?.useContrastColor??!0})}}}}({layout:t,themeService:i}),l=function({layout:e,constraints:t,colorService:n,themeService:r,styleModel:i,pluginService:o,animationsEnabled:a}){const l=function(e){return{...e.getScales()}}(n),s=n.getPalettes(),u=function({layout:e,constraints:t,colorService:n,animationsEnabled:r}){const i=n.getDatumProps(),o=n.getColor();return{type:"funnel",key:"fun",data:{extract:{field:"qDimensionInfo/0",props:{num:{field:"qMeasureInfo/0"},...i}}},brush:t.select||t.active?{}:{trigger:[{contexts:["selection"],data:[""]}],consume:[{context:"selection",filter:e=>"section"===e.tag,style:{inactive:{opacity:.3}}}]},settings:{num:{ref:"num"},fill:o,mode:e.funnel.mode},animations:{enabled:r,isMainComponent:!0,trackBy:e=>`${e.tag}: ${e.data.value}`}}}({layout:e,constraints:t,colorService:n,animationsEnabled:a}),c=[u,Zo(e,r,a,i),Xo(e,i)];return{palettes:s,scales:l,components:o.extendComponents(c),formatters:{share:{type:"d3-number",format:".1%"},num:{data:{field:"qMeasureInfo/0"}}}}}({layout:t,constraints:r,colorService:y,themeService:i,styleModel:o,pluginService:D,animationsEnabled:q});s.update({data:e,settings:l}),x.set("width",s.element.clientWidth),x.set("height",s.element.clientHeight),Oi.cacheProperties({viewCache:x,layout:t})},[s,y,n.name(),D,r]),u(()=>{s&&(s.update(),x.set("width",s.element.clientWidth),x.set("height",s.element.clientHeight))},[i.width,i.height]),u(()=>{b&&b.setLayout(t)},[t]),v(e=>y.getSnapshotData().then(t=>(e.snapshotData=e.snapshotData||{},e.snapshotData.content=e.snapshotData.content||{},e.snapshotData.content.chartData=t,e)).catch(()=>e))}function ta(n){!function(e){if(e&&e.get&&e.add){const t="Object.Disclaimer.LimitedData";if(e.get(t)!==t)return;Object.keys(y).forEach(t=>{e.add(y[t])})}}(n.translator);const r=e();return r.use(t),r.component("funnel",M),{ext:qi(n),qae:{properties:{initial:I},data:{targets:Di}},component(){ea({picasso:r})}}}export{ta as default};
|