File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11<script setup lang="ts">
2- import { VueUiSparkline } from ' vue-data-ui/vue-ui-sparkline'
3- import { VueUiPatternSeed } from ' vue-data-ui/vue-ui-pattern-seed'
4- import { useCssVariables } from ' ~/composables/useColors'
52import {
3+ VueUiSparkline ,
64 type VueUiSparklineConfig ,
75 type VueUiSparklineDatasetItem ,
8- type VueUiXyDatasetItem ,
9- } from ' vue-data-ui'
6+ } from ' vue-data-ui/vue-ui-sparkline'
7+ import { VueUiPatternSeed } from ' vue-data-ui/vue-ui-pattern-seed'
8+ import { useCssVariables } from ' ~/composables/useColors'
9+ import type { VueUiXyDatasetItem } from ' vue-data-ui/vue-ui-xy'
1010import { getPalette , lightenColor } from ' vue-data-ui/utils'
1111import { CHART_PATTERN_CONFIG } from ' ~/utils/charts'
1212
@@ -233,9 +233,10 @@ const configs = computed(() => {
233233 {{ applyEllipsis(dataset?.[i]?.name ?? '', 27) }}
234234 </div >
235235 <VueUiSparkline
236+ v-if =" datasets[i]"
236237 :key =" `${i}_${step}`"
237238 :config
238- :dataset =" datasets?. [i]"
239+ :dataset =" datasets[i]"
239240 :selectedIndex
240241 @hoverIndex =" hoverIndex"
241242 >
Original file line number Diff line number Diff line change 11<script setup lang="ts">
22import { ref , computed } from ' vue'
3- import { VueUiHorizontalBar } from ' vue-data-ui/vue-ui-horizontal-bar'
3+ import {
4+ VueUiHorizontalBar ,
5+ type VueUiHorizontalBarConfig ,
6+ type VueUiHorizontalBarDatasetItem ,
7+ } from ' vue-data-ui/vue-ui-horizontal-bar'
48import { VueUiPatternSeed } from ' vue-data-ui/vue-ui-pattern-seed'
5- import type { VueUiHorizontalBarConfig , VueUiHorizontalBarDatasetItem } from ' vue-data-ui'
69import { getFrameworkColor , isListedFramework } from ' ~/utils/frameworks'
710import { createPatternDef } from ' vue-data-ui/utils'
811import { drawSmallNpmxLogoAndTaglineWatermark } from ' ~/composables/useChartWatermark'
Original file line number Diff line number Diff line change 11<script setup lang="ts">
22import { SelectField } from ' #components'
33import { ref , computed } from ' vue'
4- import type { FormatterParams , VueUiScatterConfig , VueUiScatterDatasetItem } from ' vue-data-ui'
5- import { VueUiScatter } from ' vue-data-ui/vue-ui-scatter'
4+ import {
5+ VueUiScatter ,
6+ type VueUiScatterConfig ,
7+ type VueUiScatterDatasetItem ,
8+ } from ' vue-data-ui/vue-ui-scatter'
69import { buildCompareScatterChartDataset } from ' ~/utils/compare-scatter-chart'
710import { loadFile , copyAltTextForCompareScatterChart } from ' ~/utils/charts'
811
@@ -210,7 +213,7 @@ const config = computed<VueUiScatterConfig>(() => {
210213 color: colors .value .fgSubtle ,
211214 offsetY: 10 ,
212215 fontSize: 14 ,
213- formatter : ( args : FormatterParams ) => {
216+ formatter : args => {
214217 return formatters .value .x !(args .value )
215218 },
216219 },
@@ -231,7 +234,7 @@ const config = computed<VueUiScatterConfig>(() => {
231234 labels: {
232235 color: colors .value .fgSubtle ,
233236 fontSize: 14 ,
234- formatter : ( args : FormatterParams ) => {
237+ formatter : args => {
235238 return formatters .value .y !(args .value )
236239 },
237240 },
Original file line number Diff line number Diff line change 11<script setup lang="ts">
2- import type { Theme as VueDataUiTheme , VueUiXyConfig , VueUiXyDatasetItem } from ' vue-data-ui'
3- import { VueUiXy } from ' vue-data-ui/vue-ui-xy'
2+ import type { Theme as VueDataUiTheme } from ' vue-data-ui'
3+ import { VueUiXy , type VueUiXyConfig , type VueUiXyDatasetItem } from ' vue-data-ui/vue-ui-xy'
44import { useDebounceFn , useElementSize , useTimeoutFn } from ' @vueuse/core'
55import { useCssVariables } from ' ~/composables/useColors'
66import { OKLCH_NEUTRAL_FALLBACK , transparentizeOklch , lightenOklch } from ' ~/utils/colors'
@@ -1077,7 +1077,7 @@ const normalisedDataset = computed(() => {
10771077 const lastDateMs = chartData .value .dates .at (- 1 ) ?? 0
10781078 const isAbsoluteMetric = selectedMetric .value === ' contributors'
10791079
1080- return chartData .value .dataset ? .map (d => {
1080+ return ( chartData .value .dataset || []) .map (d => {
10811081 const series = applyDataPipeline (
10821082 d .series .map (v => v ?? 0 ),
10831083 {
Original file line number Diff line number Diff line change 11<script setup lang="ts">
2- import { VueUiXy } from ' vue-data-ui/vue-ui-xy'
3- import { type VueUiXyDatasetItem , type VueUiXyConfig } from ' vue-data-ui'
2+ import { VueUiXy , type VueUiXyDatasetItem , type VueUiXyConfig } from ' vue-data-ui/vue-ui-xy'
43import { useElementSize } from ' @vueuse/core'
54import { useCssVariables } from ' ~/composables/useColors'
65import { OKLCH_NEUTRAL_FALLBACK , transparentizeOklch , lightenHex } from ' ~/utils/colors'
Original file line number Diff line number Diff line change 11<script setup lang="ts">
2- import { VueUiSparkline } from ' vue-data-ui/vue-ui-sparkline'
2+ import {
3+ VueUiSparkline ,
4+ type VueUiSparklineConfig ,
5+ type VueUiSparklineDatasetItem ,
6+ } from ' vue-data-ui/vue-ui-sparkline'
37import { useCssVariables } from ' ~/composables/useColors'
48import type { WeeklyDataPoint } from ' ~/types/chart'
59import { applyDataCorrection } from ' ~/utils/chart-data-correction'
610import { OKLCH_NEUTRAL_FALLBACK , lightenOklch } from ' ~/utils/colors'
711import { applyBlocklistCorrection } from ' ~/utils/download-anomalies'
812import type { RepoRef } from ' #shared/utils/git-providers'
9- import type { VueUiSparklineConfig , VueUiSparklineDatasetItem } from ' vue-data-ui'
1013import { onKeyDown } from ' @vueuse/core'
1114
1215import (' vue-data-ui/style.css' )
You can’t perform that action at this time.
0 commit comments