1
0
mirror of https://github.com/misskey-dev/misskey.git synced 2026-05-02 16:45:54 +02:00

refactor(frontend): Formまわりの型強化 (#16260)

* refactor(frontend): Formまわりの型強化

* fix

* avoid non-null assertion and add null check for safety

* refactor

* avoid non-null assertion and add null check for safety

* Update clip.vue

---------

Co-authored-by: syuilo <4439005+syuilo@users.noreply.github.com>
This commit is contained in:
かっこかり
2025-07-06 19:36:11 +09:00
committed by GitHub
parent c2a01551a7
commit a8abb03d17
45 changed files with 344 additions and 239 deletions

View File

@@ -5,7 +5,7 @@ SPDX-License-Identifier: AGPL-3.0-only
<template>
<div class="_panel">
<div :class="$style.container" :style="{ backgroundImage: instance.bannerUrl ? `url(${ instance.bannerUrl })` : null }">
<div :class="$style.container" :style="{ backgroundImage: instance.bannerUrl ? `url(${ instance.bannerUrl })` : undefined }">
<div :class="$style.iconContainer">
<img :src="instance.iconUrl ?? instance.faviconUrl ?? '/favicon.ico'" alt="" :class="$style.icon"/>
</div>
@@ -22,14 +22,14 @@ SPDX-License-Identifier: AGPL-3.0-only
<script lang="ts" setup>
import { useWidgetPropsManager } from './widget.js';
import type { WidgetComponentEmits, WidgetComponentExpose, WidgetComponentProps } from './widget.js';
import type { GetFormResultType } from '@/utility/form.js';
import type { FormWithDefault, GetFormResultType } from '@/utility/form.js';
import { host } from '@@/js/config.js';
import { instance } from '@/instance.js';
const name = 'instanceInfo';
const widgetPropsDef = {
};
} satisfies FormWithDefault;
type WidgetProps = GetFormResultType<typeof widgetPropsDef>;