diff --git a/app/components/Chart/SplitSparkline.vue b/app/components/Chart/SplitSparkline.vue new file mode 100644 index 0000000000..f3c5537e8e --- /dev/null +++ b/app/components/Chart/SplitSparkline.vue @@ -0,0 +1,254 @@ + + + diff --git a/app/components/Package/TrendsChart.vue b/app/components/Package/TrendsChart.vue index 21bddcf2f7..005583283e 100644 --- a/app/components/Package/TrendsChart.vue +++ b/app/components/Package/TrendsChart.vue @@ -1622,6 +1622,15 @@ watch(selectedMetric, value => { if (!isMounted.value) return loadMetric(value) }) + +// Sparkline charts (a11y alternative display for multi series) +const chartLayout = usePermalink<'combined' | 'split'>('layout', 'combined') +const isSparklineLayout = computed({ + get: () => chartLayout.value === 'split', + set: (v: boolean) => { + chartLayout.value = v ? 'split' : 'combined' + }, +})