Skip to content

Commit

Permalink
feat: use deferred teleport, update old comments
Browse files Browse the repository at this point in the history
Signed-off-by: Fernando Fernández <ferferga@hotmail.com>
  • Loading branch information
ferferga committed Sep 6, 2024
1 parent 669a347 commit 6c7263a
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 7 deletions.
3 changes: 0 additions & 3 deletions frontend/src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,6 @@
</template>

<script setup lang="ts">
/**
* TODO: Remove j-transition classes from this file once https://github.com/vuejs/core/issues/5148 is fixed
*/
import { shallowRef, type Component as VueComponent, onMounted } from 'vue';
import type { RouteMeta } from 'vue-router';
import DefaultLayout from '@/layouts/default.vue';
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/components/Playback/PlayerElement.vue
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
<template v-if="mediaElementType">
<Teleport
:to="videoContainerRef"
:disabled="!videoContainerRef">
:disabled="!videoContainerRef"
defer>
<Component
:is="mediaElementType"
v-show="mediaElementType === 'video' && videoContainerRef"
Expand Down
8 changes: 5 additions & 3 deletions frontend/src/components/lib/JApp.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
<template>
<Teleport to="head">
<!-- eslint-disable @intlify/vue-i18n/no-raw-text -->
<Teleport
to="head"
defer>
<!-- eslint-disable @intlify/vue-i18n/no-raw-text vue/require-component-is -->
<component
is="style"
data-jellyfin-css-vars>
Expand All @@ -11,7 +13,7 @@
--j-background-color: rgb(var(--v-theme-background));
}
</component>
<!-- eslint-enable @intlify/vue-i18n/no-raw-text -->
<!-- eslint-enable @intlify/vue-i18n/no-raw-text vue/require-component-is -->
</Teleport>
<slot />
</template>
Expand Down
3 changes: 3 additions & 0 deletions frontend/src/components/lib/JView.vue
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@
</template>

<script setup lang="ts">
/**
* TODO: Remove j-transition classes from this file once https://github.com/vuejs/core/issues/5148 is fixed
*/
import type { Component } from 'vue';
defineProps<{
Expand Down

0 comments on commit 6c7263a

Please sign in to comment.