Skip to content

Commit 186d92a

Browse files
committed
refactor: use js chunk for css
1 parent aea4196 commit 186d92a

3 files changed

Lines changed: 6 additions & 6 deletions

File tree

app/components/Package/TrendsChart.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@ import { applyDataCorrection } from '~/utils/chart-data-correction'
2222
import { applyBlocklistCorrection, getAnomaliesForPackages } from '~/utils/download-anomalies'
2323
import { copyAltTextForTrendLineChart } from '~/utils/charts'
2424
25+
import('vue-data-ui/style.css')
26+
2527
const props = withDefaults(
2628
defineProps<{
2729
// For single package downloads history
@@ -2181,8 +2183,6 @@ watch(selectedMetric, value => {
21812183
</template>
21822184

21832185
<style>
2184-
@import 'vue-data-ui/style.css';
2185-
21862186
.vue-ui-pen-and-paper-actions {
21872187
background: var(--bg-elevated) !important;
21882188
}

app/components/Package/VersionDistribution.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ import {
1111
import TooltipApp from '~/components/Tooltip/App.vue'
1212
import { copyAltTextForVersionsBarChart } from '~/utils/charts'
1313
14+
import('vue-data-ui/style.css')
15+
1416
const props = defineProps<{
1517
packageName: string
1618
inModal?: boolean
@@ -672,8 +674,6 @@ const chartConfig = computed<VueUiXyConfig>(() => {
672674
</style>
673675

674676
<style>
675-
@import 'vue-data-ui/style.css';
676-
677677
/* Override default placement of the refresh button to have it to the minimap's side */
678678
@media screen and (min-width: 767px) {
679679
#version-distribution .vue-data-ui-refresh-button {

app/components/Package/WeeklyDownloadStats.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ import type { RepoRef } from '#shared/utils/git-providers'
99
import type { VueUiSparklineConfig, VueUiSparklineDatasetItem } from 'vue-data-ui'
1010
import { onKeyDown } from '@vueuse/core'
1111
12+
import('vue-data-ui/style.css')
13+
1214
const props = defineProps<{
1315
packageName: string
1416
createdIso: string | null
@@ -498,8 +500,6 @@ const config = computed<VueUiSparklineConfig>(() => {
498500
</style>
499501

500502
<style>
501-
@import 'vue-data-ui/style.css';
502-
503503
/** Overrides */
504504
.vue-ui-sparkline-title span {
505505
padding: 0 !important;

0 commit comments

Comments
 (0)