@svgrid/enterprise 3.0.1 → 3.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/SvFormulaBar.svelte +606 -0
- package/dist/SvFormulaBar.svelte.d.ts +62 -0
- package/dist/SvPivotDesigner.svelte +65 -14
- package/dist/SvRibbonIcon.svelte +46 -0
- package/dist/SvRibbonIcon.svelte.d.ts +17 -0
- package/dist/SvSchemaChart.svelte +4 -2
- package/dist/SvSheet.svelte +4114 -0
- package/dist/SvSheet.svelte.d.ts +142 -0
- package/dist/SvSheetComment.svelte +98 -0
- package/dist/SvSheetComment.svelte.d.ts +22 -0
- package/dist/SvSheetConditionalFormat.svelte +162 -0
- package/dist/SvSheetConditionalFormat.svelte.d.ts +14 -0
- package/dist/SvSheetDataValidation.svelte +249 -0
- package/dist/SvSheetDataValidation.svelte.d.ts +14 -0
- package/dist/SvSheetFilterMenu.svelte +217 -0
- package/dist/SvSheetFilterMenu.svelte.d.ts +17 -0
- package/dist/SvSheetFindReplace.svelte +132 -0
- package/dist/SvSheetFindReplace.svelte.d.ts +10 -0
- package/dist/SvSheetFormatCells.svelte +421 -0
- package/dist/SvSheetFormatCells.svelte.d.ts +17 -0
- package/dist/SvSheetGoalSeek.svelte +144 -0
- package/dist/SvSheetGoalSeek.svelte.d.ts +12 -0
- package/dist/SvSheetInsertFunction.svelte +147 -0
- package/dist/SvSheetInsertFunction.svelte.d.ts +8 -0
- package/dist/SvSheetListPicker.svelte +89 -0
- package/dist/SvSheetListPicker.svelte.d.ts +16 -0
- package/dist/SvSheetManageRules.svelte +185 -0
- package/dist/SvSheetManageRules.svelte.d.ts +16 -0
- package/dist/SvSheetNameManager.svelte +225 -0
- package/dist/SvSheetNameManager.svelte.d.ts +11 -0
- package/dist/SvSheetPasteSpecial.svelte +105 -0
- package/dist/SvSheetPasteSpecial.svelte.d.ts +12 -0
- package/dist/SvSheetRemoveDuplicates.svelte +149 -0
- package/dist/SvSheetRemoveDuplicates.svelte.d.ts +12 -0
- package/dist/SvSheetRibbon.svelte +1201 -0
- package/dist/SvSheetRibbon.svelte.d.ts +34 -0
- package/dist/SvSheetSizeDialog.svelte +58 -0
- package/dist/SvSheetSizeDialog.svelte.d.ts +11 -0
- package/dist/SvSheetTabs.svelte +441 -0
- package/dist/SvSheetTabs.svelte.d.ts +36 -0
- package/dist/SvSheetTabs.test-harness.svelte.d.ts +17 -0
- package/dist/SvSheetTabs.test-harness.svelte.js +22 -0
- package/dist/SvSheetTextToColumns.svelte +172 -0
- package/dist/SvSheetTextToColumns.svelte.d.ts +13 -0
- package/dist/SvSheetValidationAlert.svelte +83 -0
- package/dist/SvSheetValidationAlert.svelte.d.ts +15 -0
- package/dist/cdn/svgrid-enterprise.svelte-external.js +18997 -5396
- package/dist/designer/assets/GridMenus-BlsvL_aU.js +8 -0
- package/dist/designer/assets/SvChartMenu-BYO9cYdy.css +1 -0
- package/dist/designer/assets/SvChartMenu-D9hEeHar.js +1 -0
- package/dist/designer/assets/SvDateRangeInput-BBRzrQeg.js +1 -0
- package/dist/designer/assets/SvDateTimePicker-DARvKUL2.js +1 -0
- package/dist/designer/assets/SvGridCellEditor-C7uQXYds.js +4 -0
- package/dist/designer/assets/SvGridChart-B8j1SSy3.js +3 -0
- package/dist/designer/assets/SvGridChart-BgLuPO7I.css +1 -0
- package/dist/designer/assets/SvGridChartBuilder-08YWWeqY.css +1 -0
- package/dist/designer/assets/SvGridChartBuilder-kvyIU_Rl.js +1 -0
- package/dist/designer/assets/SvGridChartPanel-4Pc8y5yO.css +1 -0
- package/dist/designer/assets/SvGridChartPanel-pT6ITc2P.js +4 -0
- package/dist/designer/assets/{SvGridChartView-DUc-1RUf.css → SvGridChartView-7msfnWZT.css} +1 -1
- package/dist/designer/assets/SvGridChartView-bg281UA1.js +1 -0
- package/dist/designer/assets/SvListBox-BDS66lmZ.js +110 -0
- package/dist/designer/assets/SvMenuList-DJ47ba1h.css +1 -0
- package/dist/designer/assets/SvMenuList-Dgq2D5VN.js +1 -0
- package/dist/designer/assets/SvTabs-DKmwb5p1.css +1 -0
- package/dist/designer/assets/SvTabs-UFCMTHXS.js +1 -0
- package/dist/designer/assets/chart-cIPUsbM5.js +1 -0
- package/dist/designer/assets/chart-export-B6bkQ3X8.js +11 -0
- package/dist/designer/assets/chart-export-pdf-BbA28-gt.js +11 -0
- package/dist/designer/assets/chart-panel-messages-DtTxpBUU.js +1 -0
- package/dist/designer/assets/chart-summary-Czu_5epb.js +1 -0
- package/dist/designer/assets/chart-trend-D5I5VEe8.js +1 -0
- package/dist/designer/assets/chart-validate-BMqM-qkF.js +1 -0
- package/dist/designer/assets/column-resize-BYDzR1Ve.js +1 -0
- package/dist/designer/assets/date-format-B8JbEtIG.js +1 -0
- package/dist/designer/assets/date-format-DKS-z0xS.css +1 -0
- package/dist/designer/assets/editor-contract-Bpoa7A5g.js +1 -0
- package/dist/designer/assets/focus-trap-CAreAhlU.js +1 -0
- package/dist/designer/assets/index-CMFgAoVV.css +1 -0
- package/dist/designer/assets/{index-C_a9Cj8Y.js → index-DwU7CAMm.js} +291 -290
- package/dist/designer/assets/list-option-BP_dWS66.js +1 -0
- package/dist/designer/assets/row-resize-DLktcqUK.js +1 -0
- package/dist/designer/assets/src-CITpcm6b.js +1 -0
- package/dist/designer/assets/src-EdI3Xqds.js +58 -0
- package/dist/designer/index.html +23 -14
- package/dist/export-pdf.d.ts +89 -0
- package/dist/export-pdf.js +130 -0
- package/dist/export.js +17 -10
- package/dist/index.d.ts +64 -1
- package/dist/index.js +68 -1
- package/dist/install.js +5 -0
- package/dist/node/studio.js +64 -2
- package/dist/pivot-chart.d.ts +25 -1
- package/dist/pivot-chart.js +25 -69
- package/dist/sheet/address.d.ts +43 -0
- package/dist/sheet/address.js +81 -0
- package/dist/sheet/ast.d.ts +94 -0
- package/dist/sheet/ast.js +56 -0
- package/dist/sheet/auto-filter.d.ts +66 -0
- package/dist/sheet/auto-filter.js +147 -0
- package/dist/sheet/autocomplete.d.ts +42 -0
- package/dist/sheet/autocomplete.js +162 -0
- package/dist/sheet/coerce.d.ts +31 -0
- package/dist/sheet/coerce.js +122 -0
- package/dist/sheet/commands.d.ts +89 -0
- package/dist/sheet/commands.js +230 -0
- package/dist/sheet/comments.d.ts +29 -0
- package/dist/sheet/comments.js +73 -0
- package/dist/sheet/conditional-formats.d.ts +144 -0
- package/dist/sheet/conditional-formats.js +316 -0
- package/dist/sheet/deps.d.ts +60 -0
- package/dist/sheet/deps.js +199 -0
- package/dist/sheet/document.d.ts +150 -0
- package/dist/sheet/document.js +264 -0
- package/dist/sheet/edit-keys.d.ts +14 -0
- package/dist/sheet/edit-keys.js +40 -0
- package/dist/sheet/entry.d.ts +31 -0
- package/dist/sheet/entry.js +76 -0
- package/dist/sheet/evaluate.d.ts +61 -0
- package/dist/sheet/evaluate.js +337 -0
- package/dist/sheet/find-replace.d.ts +62 -0
- package/dist/sheet/find-replace.js +152 -0
- package/dist/sheet/format-store.d.ts +99 -0
- package/dist/sheet/format-store.js +233 -0
- package/dist/sheet/freeze.d.ts +54 -0
- package/dist/sheet/freeze.js +58 -0
- package/dist/sheet/function-catalog.d.ts +10 -0
- package/dist/sheet/function-catalog.js +94 -0
- package/dist/sheet/functions.d.ts +28 -0
- package/dist/sheet/functions.js +362 -0
- package/dist/sheet/goal-seek.d.ts +73 -0
- package/dist/sheet/goal-seek.js +153 -0
- package/dist/sheet/index.d.ts +53 -0
- package/dist/sheet/index.js +53 -0
- package/dist/sheet/merges.d.ts +71 -0
- package/dist/sheet/merges.js +137 -0
- package/dist/sheet/names.d.ts +31 -0
- package/dist/sheet/names.js +87 -0
- package/dist/sheet/navigate.d.ts +52 -0
- package/dist/sheet/navigate.js +135 -0
- package/dist/sheet/number-format.d.ts +63 -0
- package/dist/sheet/number-format.js +508 -0
- package/dist/sheet/palette.d.ts +19 -0
- package/dist/sheet/palette.js +84 -0
- package/dist/sheet/parse.d.ts +13 -0
- package/dist/sheet/parse.js +108 -0
- package/dist/sheet/paste-special.d.ts +164 -0
- package/dist/sheet/paste-special.js +592 -0
- package/dist/sheet/protection.d.ts +21 -0
- package/dist/sheet/protection.js +48 -0
- package/dist/sheet/rects.d.ts +45 -0
- package/dist/sheet/rects.js +112 -0
- package/dist/sheet/refs.d.ts +82 -0
- package/dist/sheet/refs.js +266 -0
- package/dist/sheet/ribbon-icons.d.ts +31 -0
- package/dist/sheet/ribbon-icons.js +350 -0
- package/dist/sheet/ribbon.d.ts +173 -0
- package/dist/sheet/ribbon.js +753 -0
- package/dist/sheet/shortcuts.d.ts +164 -0
- package/dist/sheet/shortcuts.js +623 -0
- package/dist/sheet/structure.d.ts +87 -0
- package/dist/sheet/structure.js +166 -0
- package/dist/sheet/tables.d.ts +70 -0
- package/dist/sheet/tables.js +147 -0
- package/dist/sheet/tokenize.d.ts +54 -0
- package/dist/sheet/tokenize.js +304 -0
- package/dist/sheet/transforms.d.ts +76 -0
- package/dist/sheet/transforms.js +154 -0
- package/dist/sheet/validation.d.ts +92 -0
- package/dist/sheet/validation.js +241 -0
- package/dist/sheet/workbook.d.ts +72 -0
- package/dist/sheet/workbook.js +409 -0
- package/dist/sheet-enable.d.ts +6 -0
- package/dist/sheet-enable.js +46 -0
- package/dist/studio/ui-components.generated.js +63 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +9 -4
- package/dist/designer/assets/GridMenus-B1JtIN21.js +0 -8
- package/dist/designer/assets/SvDateRangeInput-CjO7nn_x.js +0 -1
- package/dist/designer/assets/SvDateTimePicker-ByBD_ov6.js +0 -1
- package/dist/designer/assets/SvField-YDLipR6O.css +0 -1
- package/dist/designer/assets/SvField-cj1PFNgZ.js +0 -1
- package/dist/designer/assets/SvGridCellEditor-0W1L2hJ1.js +0 -2
- package/dist/designer/assets/SvGridChart-DBOR4xcz.js +0 -2
- package/dist/designer/assets/SvGridChart-fkMWeh1J.css +0 -1
- package/dist/designer/assets/SvGridChartPanel-symrhNnR.js +0 -11
- package/dist/designer/assets/SvGridChartView-BmRxq6mU.js +0 -1
- package/dist/designer/assets/SvListBox-1oUF6Iav.js +0 -110
- package/dist/designer/assets/chart-DXFganU8.js +0 -1
- package/dist/designer/assets/column-resize-C_inr5zT.js +0 -1
- package/dist/designer/assets/date-format-DGagAqRc.css +0 -1
- package/dist/designer/assets/date-format-onlYDsrY.js +0 -1
- package/dist/designer/assets/easing-zaypKrr0.js +0 -3
- package/dist/designer/assets/index-k2stW6L8.css +0 -1
- package/dist/designer/assets/row-resize-B0FWHcNr.js +0 -1
- package/dist/designer/assets/src-D9p27OGC.js +0 -58
|
@@ -523,17 +523,52 @@
|
|
|
523
523
|
let view = $state<'table' | 'chart'>(defaultView === 'chart' && chartable ? 'chart' : 'table')
|
|
524
524
|
let chartType = $state<ChartType>('bar')
|
|
525
525
|
let chartStacked = $state(false)
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
526
|
+
let chartStacked100 = $state(false)
|
|
527
|
+
let chartHorizontal = $state(false)
|
|
528
|
+
// Every shape a pivot's categories + series can take, grouped the way the
|
|
529
|
+
// grid panel groups them. The ones missing (scatter, gauge, box plot,
|
|
530
|
+
// histogram, ranges, bullet, candles) read rows one by one.
|
|
531
|
+
const CHART_TYPES: Array<{ value: ChartType; label: string; group: string }> = [
|
|
532
|
+
{ value: 'bar', label: 'Bar', group: 'Compare' },
|
|
533
|
+
{ value: 'line', label: 'Line', group: 'Compare' },
|
|
534
|
+
{ value: 'area', label: 'Area', group: 'Compare' },
|
|
535
|
+
{ value: 'lollipop', label: 'Lollipop', group: 'Compare' },
|
|
536
|
+
{ value: 'pareto', label: 'Pareto', group: 'Compare' },
|
|
537
|
+
{ value: 'radial-column', label: 'Radial column', group: 'Compare' },
|
|
538
|
+
{ value: 'radial-bar', label: 'Radial bar', group: 'Compare' },
|
|
539
|
+
{ value: 'nightingale', label: 'Nightingale', group: 'Compare' },
|
|
540
|
+
{ value: 'pie', label: 'Pie', group: 'Part of a whole' },
|
|
541
|
+
{ value: 'funnel', label: 'Funnel', group: 'Flow' },
|
|
542
|
+
{ value: 'waterfall', label: 'Waterfall', group: 'Flow' },
|
|
543
|
+
{ value: 'radar', label: 'Radar', group: 'Distribution' },
|
|
544
|
+
{ value: 'heatmap', label: 'Heat map', group: 'Distribution' },
|
|
545
|
+
{ value: 'stream', label: 'Stream', group: 'Over time' },
|
|
531
546
|
]
|
|
532
|
-
const
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
547
|
+
const CHART_GROUPS = [...new Set(CHART_TYPES.map((t) => t.group))]
|
|
548
|
+
const STACKABLE: ChartType[] = ['bar', 'line', 'area', 'radial-column']
|
|
549
|
+
// The measures' formats travel to the chart when they agree; a layout
|
|
550
|
+
// mixing a currency and a count formats plainly rather than putting a "$"
|
|
551
|
+
// on the count. The chip's own format wins over the field's.
|
|
552
|
+
const chartFormat = $derived.by(() => {
|
|
553
|
+
const formats = layout.values.map((v) => v.format ?? fields.find((f) => f.field === v.field)?.format)
|
|
554
|
+
const first = formats[0]
|
|
555
|
+
if (!first) return undefined
|
|
556
|
+
const same = formats.every((f) => f && f.type === first.type && (f.type !== 'currency' || (f as { currency?: string }).currency === (first as { currency?: string }).currency))
|
|
557
|
+
return same ? first : undefined
|
|
558
|
+
})
|
|
559
|
+
const chartSpec = $derived.by(() => {
|
|
560
|
+
if (!pivot || !chartable || view !== 'chart') return null
|
|
561
|
+
const spec = pivotToChartSpec(pivot, {
|
|
562
|
+
type: chartType,
|
|
563
|
+
stacked: chartStacked && STACKABLE.includes(chartType),
|
|
564
|
+
stacked100: chartStacked100 && (chartType === 'bar' || chartType === 'area'),
|
|
565
|
+
format: chartFormat,
|
|
566
|
+
})
|
|
567
|
+
if (chartHorizontal && chartType === 'bar') spec.orientation = 'horizontal'
|
|
568
|
+
// A stream is a stacked area on a wiggle baseline; the box has nothing to add.
|
|
569
|
+
if (chartType === 'stream') { spec.stacked = true; spec.stackOffset = 'wiggle' }
|
|
570
|
+
return spec
|
|
571
|
+
})
|
|
537
572
|
|
|
538
573
|
// ---- Expand / collapse (when `expandable` is on) ------------------
|
|
539
574
|
// We hold a `collapsed` set of pivot row ids; descendants of a
|
|
@@ -810,15 +845,29 @@
|
|
|
810
845
|
</div>
|
|
811
846
|
{#if view === 'chart'}
|
|
812
847
|
<label class="pvd-toggle">
|
|
813
|
-
<select class="pvd-select" value={chartType} onchange={(e) => (chartType = e.currentTarget.value as ChartType)}>
|
|
814
|
-
{#each
|
|
848
|
+
<select class="pvd-select" aria-label="Chart type" value={chartType} onchange={(e) => (chartType = e.currentTarget.value as ChartType)}>
|
|
849
|
+
{#each CHART_GROUPS as g (g)}
|
|
850
|
+
<optgroup label={g}>
|
|
851
|
+
{#each CHART_TYPES.filter((t) => t.group === g) as t (t.value)}<option value={t.value}>{t.label}</option>{/each}
|
|
852
|
+
</optgroup>
|
|
853
|
+
{/each}
|
|
815
854
|
</select>
|
|
816
855
|
</label>
|
|
817
|
-
{#if chartType
|
|
856
|
+
{#if STACKABLE.includes(chartType)}
|
|
818
857
|
<label class="pvd-toggle">
|
|
819
858
|
<input type="checkbox" checked={chartStacked} onchange={(e) => (chartStacked = e.currentTarget.checked)} /> Stacked
|
|
820
859
|
</label>
|
|
821
860
|
{/if}
|
|
861
|
+
{#if chartType === 'bar' || chartType === 'area'}
|
|
862
|
+
<label class="pvd-toggle">
|
|
863
|
+
<input type="checkbox" checked={chartStacked100} onchange={(e) => (chartStacked100 = e.currentTarget.checked)} /> 100%
|
|
864
|
+
</label>
|
|
865
|
+
{/if}
|
|
866
|
+
{#if chartType === 'bar'}
|
|
867
|
+
<label class="pvd-toggle">
|
|
868
|
+
<input type="checkbox" checked={chartHorizontal} onchange={(e) => (chartHorizontal = e.currentTarget.checked)} /> Horizontal
|
|
869
|
+
</label>
|
|
870
|
+
{/if}
|
|
822
871
|
{/if}
|
|
823
872
|
{/if}
|
|
824
873
|
<div class="pvd-spacer"></div>
|
|
@@ -1264,7 +1313,9 @@
|
|
|
1264
1313
|
/>
|
|
1265
1314
|
{:else if pivot && chartable && view === 'chart'}
|
|
1266
1315
|
{#if chartSpec && chartSpec.series.length}
|
|
1267
|
-
|
|
1316
|
+
<!-- The chart's own toolbar (PNG / SVG / PDF / print / copy) and the
|
|
1317
|
+
spoken summary, at the pane's size. -->
|
|
1318
|
+
<div class="pvd-chart"><SvGridChart spec={chartSpec} interactive legend="bottom" toolbar describe autosize /></div>
|
|
1268
1319
|
{:else}
|
|
1269
1320
|
<div class="pvd-empty pvd-grid-empty">Add a measure and a row / column field to chart the pivot.</div>
|
|
1270
1321
|
{/if}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
/**
|
|
3
|
+
* One ribbon icon, by name, at any size.
|
|
4
|
+
*
|
|
5
|
+
* The paths live in `sheet/ribbon-icons.ts` on a 16-unit grid; the SVG
|
|
6
|
+
* scales them, so a large button gets the same drawing at 32px without a
|
|
7
|
+
* second set. Everything is drawn in `currentColor`: the icon is the
|
|
8
|
+
* colour of the text around it, black on a light ribbon and white on a
|
|
9
|
+
* dark one, and nothing in the set carries a colour of its own.
|
|
10
|
+
*/
|
|
11
|
+
import { RIBBON_ICONS, type RibbonIconName } from './sheet/ribbon-icons'
|
|
12
|
+
|
|
13
|
+
let { name, size = 16 }: { name: RibbonIconName; size?: number } = $props()
|
|
14
|
+
|
|
15
|
+
const paths = $derived(RIBBON_ICONS[name] ?? [])
|
|
16
|
+
</script>
|
|
17
|
+
|
|
18
|
+
<svg
|
|
19
|
+
class="sv-ribbon-icon"
|
|
20
|
+
width={size}
|
|
21
|
+
height={size}
|
|
22
|
+
viewBox="0 0 16 16"
|
|
23
|
+
fill="none"
|
|
24
|
+
stroke="currentColor"
|
|
25
|
+
stroke-width="1.4"
|
|
26
|
+
stroke-linecap="round"
|
|
27
|
+
stroke-linejoin="round"
|
|
28
|
+
aria-hidden="true"
|
|
29
|
+
focusable="false"
|
|
30
|
+
>
|
|
31
|
+
{#each paths as path, i (i)}
|
|
32
|
+
<path
|
|
33
|
+
d={path.d}
|
|
34
|
+
fill={path.fill ? 'currentColor' : 'none'}
|
|
35
|
+
stroke-width={path.width}
|
|
36
|
+
stroke-dasharray={path.dash}
|
|
37
|
+
/>
|
|
38
|
+
{/each}
|
|
39
|
+
</svg>
|
|
40
|
+
|
|
41
|
+
<style>
|
|
42
|
+
.sv-ribbon-icon {
|
|
43
|
+
display: block;
|
|
44
|
+
flex: 0 0 auto;
|
|
45
|
+
}
|
|
46
|
+
</style>
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* One ribbon icon, by name, at any size.
|
|
3
|
+
*
|
|
4
|
+
* The paths live in `sheet/ribbon-icons.ts` on a 16-unit grid; the SVG
|
|
5
|
+
* scales them, so a large button gets the same drawing at 32px without a
|
|
6
|
+
* second set. Everything is drawn in `currentColor`: the icon is the
|
|
7
|
+
* colour of the text around it, black on a light ribbon and white on a
|
|
8
|
+
* dark one, and nothing in the set carries a colour of its own.
|
|
9
|
+
*/
|
|
10
|
+
import { type RibbonIconName } from './sheet/ribbon-icons.js';
|
|
11
|
+
type $$ComponentProps = {
|
|
12
|
+
name: RibbonIconName;
|
|
13
|
+
size?: number;
|
|
14
|
+
};
|
|
15
|
+
declare const SvRibbonIcon: import("svelte").Component<$$ComponentProps, {}, "">;
|
|
16
|
+
type SvRibbonIcon = ReturnType<typeof SvRibbonIcon>;
|
|
17
|
+
export default SvRibbonIcon;
|
|
@@ -144,9 +144,11 @@
|
|
|
144
144
|
const typeOptions = [
|
|
145
145
|
{ value: 'bar', label: 'Bar' }, { value: 'pie', label: 'Pie' }, { value: 'line', label: 'Line' }, { value: 'area', label: 'Area' },
|
|
146
146
|
{ value: 'radar', label: 'Radar' }, { value: 'funnel', label: 'Funnel' }, { value: 'waterfall', label: 'Waterfall' }, { value: 'treemap', label: 'Treemap' },
|
|
147
|
+
{ value: 'lollipop', label: 'Lollipop' }, { value: 'pareto', label: 'Pareto' }, { value: 'sunburst', label: 'Sunburst' },
|
|
148
|
+
{ value: 'radial-bar', label: 'Radial bar' }, { value: 'radial-column', label: 'Radial column' }, { value: 'nightingale', label: 'Nightingale' },
|
|
147
149
|
]
|
|
148
150
|
// Cartesian types get x/y axis titles; radial / area-partition types don't.
|
|
149
|
-
const CARTESIAN_TYPES = new Set<ChartType>(['bar', 'line', 'area', 'waterfall'])
|
|
151
|
+
const CARTESIAN_TYPES = new Set<ChartType>(['bar', 'line', 'area', 'waterfall', 'lollipop', 'pareto'])
|
|
150
152
|
|
|
151
153
|
// Per-category colors from the dimension's enum options (status/stage/etc), in
|
|
152
154
|
// bucket order, so a pie's slices match the grid's badge colors.
|
|
@@ -173,7 +175,7 @@
|
|
|
173
175
|
if (ctype === 'pie') s.innerRadius = 0.6
|
|
174
176
|
// Treemap reads a tree, not a category/series pair - build a flat one from
|
|
175
177
|
// the same buckets (each dimension value is a leaf sized by the measure).
|
|
176
|
-
if (ctype === 'treemap') s.treemap = { name: measureLabel, children: buckets.map((b) => ({ name: b.category, value: b.value })) }
|
|
178
|
+
if (ctype === 'treemap' || ctype === 'sunburst') s.treemap = { name: measureLabel, children: buckets.map((b) => ({ name: b.category, value: b.value })) }
|
|
177
179
|
if (CARTESIAN_TYPES.has(ctype)) {
|
|
178
180
|
s.xAxisTitle = labelOf(dim)
|
|
179
181
|
s.yAxisTitle = measureLabel
|