This repository has been archived on 2024-07-22. You can view files and clone it, but cannot push or open issues or pull requests.
Zaimki/routes/calendar.vue

52 lines
1.3 KiB
Vue
Raw Normal View History

2021-08-14 01:42:49 -07:00
<template>
<div v-if="year">
2021-08-30 02:36:57 -07:00
<CommunityNav/>
2021-08-14 01:42:49 -07:00
<h2>
<Icon v="calendar-star"/>
<T>calendar.headerLong</T> <small class="text-muted">({{year.year}})</small>
2021-08-14 01:42:49 -07:00
</h2>
<CalendarBanner v-if="year.isCurrent()"/>
2021-08-14 01:42:49 -07:00
<section class="row">
<div v-for="i in 12" class="col-12 col-sm-6 col-lg-4 py-3">
<h3 class="text-center"><T>calendar.months.{{i}}</T></h3>
<Calendar :year="year" :month="i" :mark="today" tooltips/>
2021-08-14 01:42:49 -07:00
</div>
</section>
<CalendarExtra/>
2021-08-18 11:19:24 -07:00
2021-08-14 01:42:49 -07:00
<Support/>
2021-08-18 11:19:24 -07:00
2021-08-14 01:42:49 -07:00
<section>
<Share :title="$t('calendar.header')"/>
</section>
</div>
<NotFound v-else/>
2021-08-14 01:42:49 -07:00
</template>
<script>
import { head } from "../src/helpers";
import { calendar } from '../src/calendar/calendar';
import { Day } from '../src/calendar/helpers';
2021-08-14 01:42:49 -07:00
export default {
data() {
return {
year: this.$route.params.year
? calendar.getYear(this.$route.params.year)
: calendar.getCurrentYear(),
today: Day.today(),
2021-08-14 01:42:49 -07:00
}
},
head() {
return head({
title: this.$t('calendar.headerLong'),
2021-09-18 08:12:34 -07:00
banner: `calendar/overview.png`,
2021-08-14 01:42:49 -07:00
});
},
};
</script>