Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
e7b3e23
chore: bump vue-data-ui from 3.20.11 to 3.21.0
graphieros Jun 1, 2026
b1c5c93
chore: add translations
graphieros Jun 1, 2026
5b403c4
feat: add download charts static svg embedding
graphieros Jun 1, 2026
a5ff26b
fix: show embed for downloads only
graphieros Jun 1, 2026
0102f47
Merge branch 'main' into 2811-endpoint-to-embed-downloads-chart
graphieros Jun 1, 2026
ad0d079
fix: dynamic translation key
graphieros Jun 1, 2026
b50c1bf
Merge branch '2811-endpoint-to-embed-downloads-chart' of https://gith…
graphieros Jun 1, 2026
2c73931
fix: add missing mock
graphieros Jun 1, 2026
64cc83c
fix lock
graphieros Jun 1, 2026
c33d153
fix: guard browser api in loadFile
graphieros Jun 1, 2026
8977b8f
fix: add missing import, a11y fixes
graphieros Jun 1, 2026
c8925be
fix: add missing teardown
graphieros Jun 1, 2026
88e4670
fix: translation
graphieros Jun 1, 2026
e0f98e9
fix: guard loadFile for non DOM environments
graphieros Jun 1, 2026
daefa98
fix: remove happy dom env
graphieros Jun 1, 2026
fe8e5b4
fix: avoid DOM types in shared utils
graphieros Jun 1, 2026
edb543a
fix: loadFile type
graphieros Jun 1, 2026
4eb1548
fix: better guards
graphieros Jun 1, 2026
4dcc35c
fix: try defineEventHandler
graphieros Jun 1, 2026
5f62dc1
fix: restore defineCachedEventHandler
graphieros Jun 1, 2026
b969711
fix: use downloadFileLink utility
graphieros Jun 1, 2026
f9f242a
fix: add route rule
graphieros Jun 1, 2026
914aea2
fix: improve route rule
graphieros Jun 1, 2026
f0ef4a4
Merge branch 'main' into 2811-endpoint-to-embed-downloads-chart
graphieros Jun 1, 2026
a740e1f
Merge branch 'main' into 2811-endpoint-to-embed-downloads-chart
graphieros Jun 2, 2026
5dd8e96
fix: move logic to separate file & test
graphieros Jun 2, 2026
f7b8d96
Merge branch '2811-endpoint-to-embed-downloads-chart' of https://gith…
graphieros Jun 2, 2026
3bbf7bc
Merge branch 'main' into 2811-endpoint-to-embed-downloads-chart
graphieros Jun 2, 2026
23b32a1
fix: rename api file
graphieros Jun 2, 2026
6af55bf
fix: use top level import
graphieros Jun 2, 2026
71b9bf9
Fix: remove faulty import
graphieros Jun 2, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions app/components/Compare/FacetBarChart.vue
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ import { getFrameworkColor, isListedFramework } from '~/utils/frameworks'
import { createPatternDef } from 'vue-data-ui/utils'
import { drawSmallNpmxLogoAndTaglineWatermark } from '~/composables/useChartWatermark'
import { useColors } from '~/composables/useColors'
import { downloadFileLink } from '~/utils/download'

import {
loadFile,
insertLineBreaks,
sanitise,
applyEllipsis,
Expand Down Expand Up @@ -130,13 +130,13 @@ const config = computed<VueUiHorizontalBarConfig>(() => {
img: args => {
const imageUri = args?.imageUri
if (!imageUri) return
loadFile(imageUri, buildExportFilename('png'))
downloadFileLink(imageUri, buildExportFilename('png'))
},
svg: args => {
const blob = args?.blob
if (!blob) return
const url = URL.createObjectURL(blob)
loadFile(url, buildExportFilename('svg'))
downloadFileLink(url, buildExportFilename('svg'))
URL.revokeObjectURL(url)
},
altCopy: ({ dataset: dst, config: cfg }) => {
Expand Down
7 changes: 4 additions & 3 deletions app/components/Compare/FacetScatterChart.vue
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,9 @@ import {
type VueUiScatterSeries,
} from 'vue-data-ui/vue-ui-scatter'
import { buildCompareScatterChartDataset } from '~/utils/compare-scatter-chart'
import { loadFile, copyAltTextForCompareScatterChart } from '~/utils/charts'
import { copyAltTextForCompareScatterChart } from '~/utils/charts'
import { useColors } from '~/composables/useColors'
import { downloadFileLink } from '~/utils/download'

import('vue-data-ui/style.css')

Expand Down Expand Up @@ -138,13 +139,13 @@ const config = computed<VueUiScatterConfig>(() => {
img: args => {
const imageUri = args?.imageUri
if (!imageUri) return
loadFile(imageUri, buildExportFilename('png'))
downloadFileLink(imageUri, buildExportFilename('png'))
},
svg: args => {
const blob = args?.blob
if (!blob) return
const url = URL.createObjectURL(blob)
loadFile(url, buildExportFilename('svg'))
downloadFileLink(url, buildExportFilename('svg'))
URL.revokeObjectURL(url)
},
altCopy: ({ dataset: dst, config: cfg }) => {
Expand Down
8 changes: 4 additions & 4 deletions app/components/Package/TimelineChart.vue
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ import {
} from 'vue-data-ui/vue-ui-xy'
import {
sanitise,
loadFile,
applyEllipsis,
copyAltTextForTimelineChart,
type EnrichedTimelineSizeCacheEntry,
Expand All @@ -21,6 +20,7 @@ import { drawSmallNpmxLogoAndTaglineWatermark } from '~/composables/useChartWate
import { useChartTooltipPosition } from '~/composables/useChartTooltipPosition'
import { useColors } from '~/composables/useColors'
import { parseStableVersion } from '~/utils/versions'
import { downloadFileLink } from '~/utils/download'

import('vue-data-ui/style.css')

Expand Down Expand Up @@ -375,7 +375,7 @@ const config = computed<VueUiXyConfig>(() => {
img: args => {
const imageUri = args?.imageUri
if (!imageUri) return
loadFile(imageUri, buildExportFilename('png'))
downloadFileLink(imageUri, buildExportFilename('png'))
},
csv: csvStr => {
if (!csvStr) return
Expand All @@ -392,14 +392,14 @@ const config = computed<VueUiXyConfig>(() => {
.replaceAll(`\n${multilineDateTemplate}`, ` ${multilineDateTemplate}`),
])
const url = URL.createObjectURL(blob)
loadFile(url, buildExportFilename('csv'))
downloadFileLink(url, buildExportFilename('csv'))
URL.revokeObjectURL(url)
},
svg: args => {
const blob = args?.blob
if (!blob) return
const url = URL.createObjectURL(blob)
loadFile(url, buildExportFilename('svg'))
downloadFileLink(url, buildExportFilename('svg'))
URL.revokeObjectURL(url)
},
altCopy: () =>
Expand Down
Loading
Loading