2022-07-01 09:33:47 -05:00
|
|
|
<template>
|
|
|
|
<MkSpacer :content-max="800">
|
2022-07-03 00:43:28 -05:00
|
|
|
<MkTab v-model="tab" style="margin-bottom: var(--margin);">
|
2022-07-01 09:42:03 -05:00
|
|
|
<option value="notes">{{ i18n.ts.notes }}</option>
|
|
|
|
<option value="polls">{{ i18n.ts.poll }}</option>
|
|
|
|
</MkTab>
|
2023-02-21 20:00:34 -06:00
|
|
|
<MkNotes v-if="tab === 'notes'" :pagination="paginationForNotes"/>
|
|
|
|
<MkNotes v-else-if="tab === 'polls'" :pagination="paginationForPolls"/>
|
2022-07-01 09:33:47 -05:00
|
|
|
</MkSpacer>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script lang="ts" setup>
|
2023-02-21 20:00:34 -06:00
|
|
|
import MkNotes from '@/components/MkNotes.vue';
|
2022-08-30 10:24:33 -05:00
|
|
|
import MkTab from '@/components/MkTab.vue';
|
2022-07-01 09:33:47 -05:00
|
|
|
import { i18n } from '@/i18n';
|
|
|
|
|
2022-07-01 09:42:03 -05:00
|
|
|
const paginationForNotes = {
|
2022-07-01 09:33:47 -05:00
|
|
|
endpoint: 'notes/featured' as const,
|
|
|
|
limit: 10,
|
|
|
|
offsetMode: true,
|
|
|
|
};
|
2022-07-01 09:42:03 -05:00
|
|
|
|
|
|
|
const paginationForPolls = {
|
|
|
|
endpoint: 'notes/polls/recommendation' as const,
|
|
|
|
limit: 10,
|
|
|
|
offsetMode: true,
|
|
|
|
};
|
|
|
|
|
|
|
|
let tab = $ref('notes');
|
2022-07-01 09:33:47 -05:00
|
|
|
</script>
|