fix: deckのタイムライン選択画面で今指定されているタイムラインがデフォルトで選択されない問題
This commit is contained in:
parent
38491f418c
commit
640f42f8ef
|
@ -67,7 +67,7 @@ async function setAntenna() {
|
||||||
})),
|
})),
|
||||||
} : undefined),
|
} : undefined),
|
||||||
],
|
],
|
||||||
default: props.column.antennaId,
|
default: antennas.find(x => x.id === props.column.antennaId),
|
||||||
});
|
});
|
||||||
if (canceled || antenna == null) return;
|
if (canceled || antenna == null) return;
|
||||||
|
|
||||||
|
|
|
@ -67,7 +67,7 @@ async function setChannel() {
|
||||||
items: channels.map(x => ({
|
items: channels.map(x => ({
|
||||||
value: x, text: x.name,
|
value: x, text: x.name,
|
||||||
})),
|
})),
|
||||||
default: props.column.channelId,
|
default: channels.find(x => x.id === props.column.channelId),
|
||||||
});
|
});
|
||||||
if (canceled || chosenChannel == null) return;
|
if (canceled || chosenChannel == null) return;
|
||||||
updateColumn(props.column.id, {
|
updateColumn(props.column.id, {
|
||||||
|
|
|
@ -74,7 +74,7 @@ async function setList() {
|
||||||
})),
|
})),
|
||||||
} : undefined),
|
} : undefined),
|
||||||
],
|
],
|
||||||
default: props.column.listId,
|
default: lists.find(x => x.id === props.column.listId),
|
||||||
});
|
});
|
||||||
if (canceled || list == null) return;
|
if (canceled || list == null) return;
|
||||||
|
|
||||||
|
|
|
@ -59,7 +59,7 @@ async function setRole() {
|
||||||
items: roles.map(x => ({
|
items: roles.map(x => ({
|
||||||
value: x, text: x.name,
|
value: x, text: x.name,
|
||||||
})),
|
})),
|
||||||
default: props.column.roleId,
|
default: roles.find(x => x.id === props.column.roleId),
|
||||||
});
|
});
|
||||||
if (canceled || role == null) return;
|
if (canceled || role == null) return;
|
||||||
updateColumn(props.column.id, {
|
updateColumn(props.column.id, {
|
||||||
|
|
|
@ -33,7 +33,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import { onMounted, watch, ref, useTemplateRef, computed } from 'vue';
|
import { onMounted, watch, ref, useTemplateRef, computed } from 'vue';
|
||||||
import XColumn from './column.vue';
|
import XColumn from './column.vue';
|
||||||
import type { Column } from '@/deck.js';
|
import { type Column, columns } from '@/deck.js';
|
||||||
import type { MenuItem } from '@/types/menu.js';
|
import type { MenuItem } from '@/types/menu.js';
|
||||||
import type { SoundStore } from '@/preferences/def.js';
|
import type { SoundStore } from '@/preferences/def.js';
|
||||||
import { removeColumn, updateColumn } from '@/deck.js';
|
import { removeColumn, updateColumn } from '@/deck.js';
|
||||||
|
@ -102,6 +102,7 @@ async function setType() {
|
||||||
}, {
|
}, {
|
||||||
value: 'global' as const, text: i18n.ts._timelines.global,
|
value: 'global' as const, text: i18n.ts._timelines.global,
|
||||||
}],
|
}],
|
||||||
|
default: props.column.tl,
|
||||||
});
|
});
|
||||||
if (canceled) {
|
if (canceled) {
|
||||||
if (props.column.tl == null) {
|
if (props.column.tl == null) {
|
||||||
|
|
Loading…
Reference in New Issue