fix: use proper computed for available views list
This commit is contained in:
parent
26d02d5593
commit
e67fc7fb7e
1 changed files with 10 additions and 5 deletions
|
@ -146,10 +146,10 @@
|
||||||
<div class="select">
|
<div class="select">
|
||||||
<select v-model="selectedView[s.id]">
|
<select v-model="selectedView[s.id]">
|
||||||
<option
|
<option
|
||||||
v-for="v in availableViews"
|
v-for="(v, k) in availableViews"
|
||||||
:value="v"
|
:value="k"
|
||||||
:key="v">
|
:key="k">
|
||||||
{{ $t('list.' + v + '.title') }}
|
{{ v }}
|
||||||
</option>
|
</option>
|
||||||
</select>
|
</select>
|
||||||
</div>
|
</div>
|
||||||
|
@ -228,7 +228,12 @@ type SelectedViewMapper = Record<IList['id'], ListView>
|
||||||
|
|
||||||
const selectedView = ref<SelectedViewMapper>({})
|
const selectedView = ref<SelectedViewMapper>({})
|
||||||
|
|
||||||
const availableViews = computed(() => Object.values(LIST_VIEWS))
|
const availableViews = computed<Record<ListView, string>>(() => ({
|
||||||
|
list: t('list.list.title'),
|
||||||
|
gantt: t('list.gantt.title'),
|
||||||
|
table: t('list.table.title'),
|
||||||
|
kanban: t('list.kanban.title'),
|
||||||
|
}))
|
||||||
|
|
||||||
const copy = useCopyToClipboard()
|
const copy = useCopyToClipboard()
|
||||||
watch(
|
watch(
|
||||||
|
|
Loading…
Reference in a new issue