fix(front): [WIP] use generated types to make the CI (`lint:tsc`) happy
This commit is contained in:
parent
13b3e7dc3d
commit
d8a7c033eb
|
@ -148,6 +148,8 @@ const { to: upload } = useModal('upload')
|
||||||
stack
|
stack
|
||||||
main
|
main
|
||||||
>
|
>
|
||||||
|
<!-- TODO: Find out why lint:tsc doesn't like `onClick` while language server does -->
|
||||||
|
<!-- @vue-ignore -->
|
||||||
<Header
|
<Header
|
||||||
page-heading
|
page-heading
|
||||||
:h1="t('components.library.Podcasts.header.browse')"
|
:h1="t('components.library.Podcasts.header.browse')"
|
||||||
|
|
|
@ -152,6 +152,8 @@ const trackDetails: {
|
||||||
stack
|
stack
|
||||||
style="flex: 1; gap: 0;"
|
style="flex: 1; gap: 0;"
|
||||||
>
|
>
|
||||||
|
<!-- TODO: Find out why lint:tsc doesn't like `to` while language server does -->
|
||||||
|
<!-- @vue-ignore -->
|
||||||
<Section
|
<Section
|
||||||
align-left
|
align-left
|
||||||
h2="Release Details"
|
h2="Release Details"
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import type { Notification, LibraryFollow, UserFollow } from '~/types'
|
import type { Notification, LibraryFollow } from '~/types'
|
||||||
|
import type { components } from '~/types/generated'
|
||||||
|
|
||||||
import { computed, ref, watchEffect, watch } from 'vue'
|
import { computed, ref, watchEffect, watch } from 'vue'
|
||||||
import { useI18n } from 'vue-i18n'
|
import { useI18n } from 'vue-i18n'
|
||||||
|
@ -64,7 +65,8 @@ const notificationData = computed(() => {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (activity.object && activity.object.type === 'federation.Actor') {
|
if (activity.object && activity.object.type === 'federation.Actor') {
|
||||||
const userFollow = activity.related_object as UserFollow
|
// TODO: Correctly type `activity` instead of coercing the field:
|
||||||
|
const userFollow = activity.related_object as components["schemas"]["Follow"]
|
||||||
const detailUrl = { name: 'profile.full', params: { username: activity.actor.preferred_username, domain: activity.actor.domain } }
|
const detailUrl = { name: 'profile.full', params: { username: activity.actor.preferred_username, domain: activity.actor.domain } }
|
||||||
|
|
||||||
if (activity.related_object?.approved === null) {
|
if (activity.related_object?.approved === null) {
|
||||||
|
|
|
@ -6755,6 +6755,10 @@ export interface components {
|
||||||
/** Format: uuid */
|
/** Format: uuid */
|
||||||
channel: string;
|
channel: string;
|
||||||
};
|
};
|
||||||
|
LanguageItem: {
|
||||||
|
value: string;
|
||||||
|
label: string;
|
||||||
|
};
|
||||||
Library: {
|
Library: {
|
||||||
/** Format: uri */
|
/** Format: uri */
|
||||||
fid: string;
|
fid: string;
|
||||||
|
@ -7651,6 +7655,10 @@ export interface components {
|
||||||
MetadataUsageFavorite: {
|
MetadataUsageFavorite: {
|
||||||
readonly tracks: components["schemas"]["TotalCount"];
|
readonly tracks: components["schemas"]["TotalCount"];
|
||||||
};
|
};
|
||||||
|
MetedataChoices: {
|
||||||
|
language: components["schemas"]["LanguageItem"][];
|
||||||
|
itunes_category: components["schemas"]["iTunesCategoryItem"][];
|
||||||
|
};
|
||||||
ModerationTarget: {
|
ModerationTarget: {
|
||||||
type: components["schemas"]["ModerationTargetTypeEnum"];
|
type: components["schemas"]["ModerationTargetTypeEnum"];
|
||||||
id: string;
|
id: string;
|
||||||
|
@ -8977,6 +8985,11 @@ export interface components {
|
||||||
VerifyEmailRequest: {
|
VerifyEmailRequest: {
|
||||||
key: string;
|
key: string;
|
||||||
};
|
};
|
||||||
|
iTunesCategoryItem: {
|
||||||
|
value: string;
|
||||||
|
label: string;
|
||||||
|
children: string;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
responses: never;
|
responses: never;
|
||||||
parameters: never;
|
parameters: never;
|
||||||
|
@ -10266,7 +10279,7 @@ export interface operations {
|
||||||
[name: string]: unknown;
|
[name: string]: unknown;
|
||||||
};
|
};
|
||||||
content: {
|
content: {
|
||||||
"application/json": components["schemas"]["Channel"];
|
"application/json": components["schemas"]["MetedataChoices"];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
@ -17225,7 +17238,7 @@ export interface operations {
|
||||||
[name: string]: unknown;
|
[name: string]: unknown;
|
||||||
};
|
};
|
||||||
content: {
|
content: {
|
||||||
"application/json": components["schemas"]["Channel"];
|
"application/json": components["schemas"]["MetedataChoices"];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue