Added basic year view

This commit is contained in:
Alexis
2024-04-25 16:17:12 +02:00
parent cb1bd20b5b
commit 7c5de2654e
10 changed files with 110 additions and 19 deletions

View File

@@ -1,28 +1,30 @@
<script lang="ts" setup>
import { useCalendar } from '@/stores/CalendarStore'
import { computed } from 'vue'
import CalendarMenu from './CalendarMenu.vue'
import Century from './state/Century.vue'
import Decade from './state/Decade.vue'
import Monthly from './state/Monthly.vue'
import Year from './state/Year.vue'
import MonthlyLayout from './state/monthly/Layout.vue'
import CenturyLayout from './state/centennially/Layout.vue'
import DecadeLayout from './state/decennially/Layout.vue'
import YearLayout from './state/yearly/Layout.vue'
const { currentConfig } = useCalendar()
const currentViewComponent = computed(() => {
switch (currentConfig.viewType) {
case 'month':
return Monthly
return MonthlyLayout
case 'year':
return Year
return YearLayout
case 'decade':
return Decade
return DecadeLayout
case 'century':
default:
return Century
return CenturyLayout
}
})
</script>