Skip to content

Commit

Permalink
⬆️ Apply nuxt 4 compatibility mode (#2850)
Browse files Browse the repository at this point in the history
  • Loading branch information
moisout authored Jun 16, 2024
1 parent 9af3f91 commit 3c67d94
Show file tree
Hide file tree
Showing 237 changed files with 566 additions and 644 deletions.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
12 changes: 6 additions & 6 deletions client/components/About.vue → client/app/components/About.vue
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<script setup lang="ts">
import { description, version } from '@/../package.json';
import BadgeButton from '@/components/buttons/BadgeButton.vue';
import { description, version } from '~~/../package.json';
import BadgeButton from '~/components/buttons/BadgeButton.vue';
import { commit, abbreviated_commit, subject } from '@/buildMetadata.json';
import { useMessagesStore } from '@/store/messages';
import { commit, abbreviated_commit, subject } from '~~/buildMetadata.json';
import { useMessagesStore } from '~/store/messages';
defineEmits<{
(e: 'close'): void;
Expand All @@ -28,7 +28,7 @@ const copyCommitHash = () => {
<VTIcon v-ripple name="mdi:close" class="close-icon" @click.stop="$emit('close')" />
<h1>About</h1>
<div class="logo-about">
<img class="logo-about-img" src="@/assets/icon.svg" alt="ViewTube" />
<img class="logo-about-img" src="~/assets/icon.svg" alt="ViewTube" />
</div>
<h2>{{ description }}</h2>
<div class="last-commit">
Expand Down Expand Up @@ -60,7 +60,7 @@ const copyCommitHash = () => {
<div class="external-service links">
<img
class="external-service-image"
src="@/assets/icons/sponsorblock.png"
src="~/assets/icons/sponsorblock.png"
alt="Sponsorblock icon"
/>
<p>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<script setup lang="ts">
import BadgeButton from '@/components/buttons/BadgeButton.vue';
import { useMessagesStore } from '@/store/messages';
import BadgeButton from '~/components/buttons/BadgeButton.vue';
import { useMessagesStore } from '~/store/messages';
import type { ApiDto } from '@viewtube/shared';
const props = defineProps<{
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<span>View</span>
<span class="logo-colored">Tube</span>
</h1>
<img class="logo-small" src="@/assets/icon.svg" alt="ViewTube" />
<img class="logo-small" src="~/assets/icon.svg" alt="ViewTube" />
</nuxt-link>
</template>

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<script setup lang="ts">
import ThemeSelector from '@/components/themes/ThemeSelector.vue';
import SwitchButton from '@/components/buttons/SwitchButton.vue';
import MultiOptionButton from '@/components/buttons/MultiOptionButton.vue';
import Dropdown from '@/components/filter/Dropdown.vue';
import '@/assets/styles/popup.scss';
import { type SegmentOption, useSettingsStore } from '@/store/settings';
import ThemeSelector from '~/components/themes/ThemeSelector.vue';
import SwitchButton from '~/components/buttons/SwitchButton.vue';
import MultiOptionButton from '~/components/buttons/MultiOptionButton.vue';
import Dropdown from '~/components/filter/Dropdown.vue';
import '~/assets/styles/popup.scss';
import { type SegmentOption, useSettingsStore } from '~/store/settings';
import CheckBox from '~/components/form/CheckBox.vue';
import BadgeButton from './buttons/BadgeButton.vue';
Expand Down Expand Up @@ -114,7 +114,7 @@ function resetSponsorBlockUrl() {
<h2>
<img
class="sponsorblock-image"
src="@/assets/icons/sponsorblock.png"
src="~/assets/icons/sponsorblock.png"
alt="Sponsorblock icon"
/>Block ads and annoyances
</h2>
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script setup lang="ts">
import BadgeButton from '@/components/buttons/BadgeButton.vue';
import BadgeButton from '~/components/buttons/BadgeButton.vue';
const { data, pending, refresh } = useGetBlockedVideos();
const videoIdToAdd = ref(null);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script setup lang="ts">
import { useMessagesStore } from '@/store/messages';
import { useMessagesStore } from '~/store/messages';
const username = ref('');
const password = ref('');
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script setup lang="ts">
import BadgeButton from '@/components/buttons/BadgeButton.vue';
import BadgeButton from '~/components/buttons/BadgeButton.vue';
const { data, refresh, pending } = useGetAdminInfo();
</script>

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script setup lang="ts">
import BadgeButton from '@/components/buttons/BadgeButton.vue';
import BadgeButton from '~/components/buttons/BadgeButton.vue';
import dayjs from 'dayjs';
const { data, error, pending, refresh } = useGetLogs();
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@
</template>

<script lang="ts">
import { useMessagesStore } from '@/store/messages';
import { useUserStore } from '@/store/user';
import { useMessagesStore } from '~/store/messages';
import { useUserStore } from '~/store/user';
import type { ApiDto } from '@viewtube/shared';
export default defineComponent({
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script setup lang="ts">
import SubscribeButton from '@/components/buttons/SubscribeButton.vue';
import SubscribeButton from '~/components/buttons/SubscribeButton.vue';
import humanNumber from 'human-number';
import type { ApiDto } from '@viewtube/shared';
Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ defineProps<{
<template>
<div class="channel-page-error-container">
<div class="channel-page-error">
<img class="channel-page-icon" src="@/assets/icon-error.svg" alt="Viewtube broken logo" />
<img class="channel-page-icon" src="~/assets/icon-error.svg" alt="Viewtube broken logo" />
</div>
<p class="error-message">{{ errorMessage }}</p>
</div>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script setup lang="ts">
import VideoEntry from '@/components/list/VideoEntry.vue';
import VideoEntry from '~/components/list/VideoEntry.vue';
import type { ApiDto } from '@viewtube/shared';
type ShelfType = {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script setup lang="ts">
import PlaylistEntry from '@/components/list/PlaylistEntry.vue';
import PlaylistEntry from '~/components/list/PlaylistEntry.vue';
type ShelfItemType = {
title: string;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<script setup lang="ts">
import VideoEntry from '@/components/list/VideoEntry.vue';
import PlaylistEntry from '@/components/list/PlaylistEntry.vue';
import MultiOptionButton from '@/components/buttons/MultiOptionButton.vue';
import BadgeButton from '@/components/buttons/BadgeButton.vue';
import VideoEntry from '~/components/list/VideoEntry.vue';
import PlaylistEntry from '~/components/list/PlaylistEntry.vue';
import MultiOptionButton from '~/components/buttons/MultiOptionButton.vue';
import BadgeButton from '~/components/buttons/BadgeButton.vue';
import type { ApiDto } from '@viewtube/shared';
const props = withDefaults(
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<script setup lang="ts">
import { useMessagesStore } from '@/store/messages';
import { useMessagesStore } from '~/store/messages';
import RelatedChannels from '../RelatedChannels.vue';
import BadgeButton from '@/components/buttons/BadgeButton.vue';
import BadgeButton from '~/components/buttons/BadgeButton.vue';
const route = useRoute();
const messagesStore = useMessagesStore();
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<script setup lang="ts">
import { useMessagesStore } from '@/store/messages';
import BadgeButton from '@/components/buttons/BadgeButton.vue';
import { useMessagesStore } from '~/store/messages';
import BadgeButton from '~/components/buttons/BadgeButton.vue';
const route = useRoute();
const messagesStore = useMessagesStore();
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<script setup lang="ts">
import dayjs from 'dayjs';
import RelatedChannels from '@/components/channel/RelatedChannels.vue';
import BadgeButton from '@/components/buttons/BadgeButton.vue';
import RelatedChannels from '~/components/channel/RelatedChannels.vue';
import BadgeButton from '~/components/buttons/BadgeButton.vue';
const route = useRoute();
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ const currentSponsorBlockSegmentColor = computed(() => {
:class="{ visible: currentSponsorBlockSegmentCategory }"
class="preview-info-element sponsorblock"
>
<img class="sponsorblock-icon" src="@/assets/icons/sponsorblock.png" />
<img class="sponsorblock-icon" src="~/assets/icons/sponsorblock.png" />
<span class="info-text">{{ currentSponsorBlockSegmentCategory?.text ?? '' }}</span>
</div>
</div>
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script setup lang="ts">
import { useSettingsStore } from '@/store/settings';
import { useSettingsStore } from '~/store/settings';
const props = defineProps<{
uiState: UiState;
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@
</template>

<script lang="ts">
import InformationHint from '@/components/hints/InformationHint.vue';
import FormInput from '@/components/form/FormInput.vue';
import SubmitButton from '@/components/form/SubmitButton.vue';
import Spinner from '@/components/Spinner.vue';
import { useMessagesStore } from '@/store/messages';
import { useUserStore } from '@/store/user';
import InformationHint from '~/components/hints/InformationHint.vue';
import FormInput from '~/components/form/FormInput.vue';
import SubmitButton from '~/components/form/SubmitButton.vue';
import Spinner from '~/components/Spinner.vue';
import { useMessagesStore } from '~/store/messages';
import { useUserStore } from '~/store/user';
export default defineComponent({
name: 'LoginForm',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,12 @@
</template>

<script lang="ts">
import FormInput from '@/components/form/FormInput.vue';
import SubmitButton from '@/components/form/SubmitButton.vue';
import Spinner from '@/components/Spinner.vue';
import '@/assets/styles/popup.scss';
import { useMessagesStore } from '@/store/messages';
import { useUserStore } from '@/store/user';
import FormInput from '~/components/form/FormInput.vue';
import SubmitButton from '~/components/form/SubmitButton.vue';
import Spinner from '~/components/Spinner.vue';
import '~/assets/styles/popup.scss';
import { useMessagesStore } from '~/store/messages';
import { useUserStore } from '~/store/user';
export default defineComponent({
name: 'PasswordChangeForm',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<script setup lang="ts">
import FormInput from '@/components/form/FormInput.vue';
import InformationHint from '@/components/hints/InformationHint.vue';
import SubmitButton from '@/components/form/SubmitButton.vue';
import Spinner from '@/components/Spinner.vue';
import { useMessagesStore } from '@/store/messages';
import { useUserStore } from '@/store/user';
import { useCaptchaStore } from '@/store/captcha';
import FormInput from '~/components/form/FormInput.vue';
import InformationHint from '~/components/hints/InformationHint.vue';
import SubmitButton from '~/components/form/SubmitButton.vue';
import Spinner from '~/components/Spinner.vue';
import { useMessagesStore } from '~/store/messages';
import { useUserStore } from '~/store/user';
import { useCaptchaStore } from '~/store/captcha';
const props = defineProps<{
complete?: () => void;
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<script setup lang="ts">
import Logo from '@/components/Logo.vue';
import MainSearchBox from '@/components/MainSearchBox.vue';
import UserMenu from '@/components/header/UserMenu.vue';
import { useSettingsStore } from '@/store/settings';
import { useUserStore } from '@/store/user';
import Logo from '~/components/Logo.vue';
import MainSearchBox from '~/components/MainSearchBox.vue';
import UserMenu from '~/components/header/UserMenu.vue';
import { useSettingsStore } from '~/store/settings';
import { useUserStore } from '~/store/user';
const settingsStore = useSettingsStore();
const userStore = useUserStore();
const route = useRoute();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -150,10 +150,10 @@
<script lang="ts">
import LoginForm from '../form/LoginForm.vue';
import RegisterForm from '../form/RegisterForm.vue';
import Settings from '@/components/Settings.vue';
import About from '@/components/About.vue';
import { useUserStore } from '@/store/user';
import { usePopupStore } from '@/store/popup';
import Settings from '~/components/Settings.vue';
import About from '~/components/About.vue';
import { useUserStore } from '~/store/user';
import { usePopupStore } from '~/store/popup';
export default defineComponent({
name: 'UserMenu',
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<script setup lang="ts">
import humanizeDuration from 'humanize-duration';
import BadgeButton from '@/components/buttons/BadgeButton.vue';
import BadgeButton from '~/components/buttons/BadgeButton.vue';
import type { ApiDto } from '@viewtube/shared';
import { useMessagesStore } from '@/store/messages';
import { useMessagesStore } from '~/store/messages';
defineProps<{
historyVideos: ApiDto<'HistoryResponseDto'>['videos'];
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<script setup lang="ts">
import BadgeButton from '@/components/buttons/BadgeButton.vue';
import VideoEntry from '@/components/list/VideoEntry.vue';
import { useSettingsStore } from '@/store/settings';
import BadgeButton from '~/components/buttons/BadgeButton.vue';
import VideoEntry from '~/components/list/VideoEntry.vue';
import { useSettingsStore } from '~/store/settings';
const settingsStore = useSettingsStore();
const { data: subscriptions, pending: subscriptionsLoading } = useGetUserSubscriptions({
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<script setup lang="ts">
import VideoEntry from '@/components/list/VideoEntry.vue';
import BadgeButton from '@/components/buttons/BadgeButton.vue';
import { useUserStore } from '@/store/user';
import VideoEntry from '~/components/list/VideoEntry.vue';
import BadgeButton from '~/components/buttons/BadgeButton.vue';
import { useUserStore } from '~/store/user';
const props = defineProps<{
videos: any[];
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script setup lang="ts">
import { useLoadingVideoInfoStore } from '@/store/loadingVideoInfo';
import { useLoadingVideoInfoStore } from '~/store/loadingVideoInfo';
import dayjs from 'dayjs';
type VideoType = {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<script setup lang="ts">
import type { MessageType } from '@/types/MessageType';
import { useMessagesStore } from '@/store/messages';
import type { MessageType } from '~/types/MessageType';
import { useMessagesStore } from '~/store/messages';
const props = defineProps<{
message: MessageType;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<script setup lang="ts">
import MessageBox from '@/components/message/MessageBox.vue';
import { useMessagesStore } from '@/store/messages';
import MessageBox from '~/components/message/MessageBox.vue';
import { useMessagesStore } from '~/store/messages';
const messagesStore = useMessagesStore();
</script>
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script setup lang="ts">
import BadgeButton from '@/components/buttons/BadgeButton.vue';
import BadgeButton from '~/components/buttons/BadgeButton.vue';
const props = defineProps<{ currentPage: number; pageCount: number }>();
const maxNumber = ref(6);
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script setup lang="ts">
import BadgeButton from '@/components/buttons/BadgeButton.vue';
import BadgeButton from '~/components/buttons/BadgeButton.vue';
const props = defineProps<{
title: string;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

<script lang="ts">
import * as QRCode from 'qrcode';
import '@/assets/styles/popup.scss';
import '~/assets/styles/popup.scss';
export default defineComponent({
name: 'QrPopUp',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<script setup lang="ts">
import CheckBox from '@/components/form/CheckBox.vue';
import BadgeButton from '@/components/buttons/BadgeButton.vue';
import FileButton from '@/components/form/FileButton.vue';
import Spinner from '@/components/Spinner.vue';
import '@/assets/styles/popup.scss';
import CheckBox from '~/components/form/CheckBox.vue';
import BadgeButton from '~/components/buttons/BadgeButton.vue';
import FileButton from '~/components/form/FileButton.vue';
import Spinner from '~/components/Spinner.vue';
import '~/assets/styles/popup.scss';
class ChannelDto {
author: string;
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script setup lang="ts">
import BadgeButton from '@/components/buttons/BadgeButton.vue';
import BadgeButton from '~/components/buttons/BadgeButton.vue';
defineProps<{
refinements: string[];
}>();
Expand Down
Loading

0 comments on commit 3c67d94

Please sign in to comment.