1
0
mirror of https://github.com/misskey-dev/misskey.git synced 2026-05-02 22:35:53 +02:00

refactor(frontend): ID生成処理を統一

This commit is contained in:
syuilo
2025-06-03 07:37:08 +09:00
parent 3bc81522c6
commit 93d17aff6c
16 changed files with 35 additions and 20 deletions

View File

@@ -52,6 +52,7 @@ import type { SuggestionType } from '@/utility/autocomplete.js';
import MkButton from '@/components/MkButton.vue';
import { i18n } from '@/i18n.js';
import { Autocomplete } from '@/utility/autocomplete.js';
import { genId } from '@/utility/id.js';
const props = defineProps<{
modelValue: string | number | null;
@@ -87,7 +88,7 @@ const emit = defineEmits<{
const { modelValue, type, autofocus } = toRefs(props);
const v = ref(modelValue.value);
const id = Math.random().toString(); // TODO: uuid?
const id = genId();
const focused = ref(false);
const changed = ref(false);
const invalid = ref(false);