enhance(client): add ads page

This commit is contained in:
syuilo
2023-03-18 14:30:16 +09:00
parent 8571c692ba
commit 7699b49d33
4 changed files with 37 additions and 3 deletions

View File

@@ -0,0 +1,25 @@
<template>
<MkStickyContainer>
<template #header><MkPageHeader/></template>
<MkSpacer :content-max="500">
<div class="_gaps">
<MkAd v-for="ad in instance.ads" :key="ad.id" :specify="ad"/>
</div>
</MkSpacer>
</MkStickyContainer>
</template>
<script lang="ts" setup>
import { computed, watch } from 'vue';
import * as os from '@/os';
import { definePageMetadata } from '@/scripts/page-metadata';
import { i18n } from '@/i18n';
import { instance } from '@/instance';
definePageMetadata({
title: i18n.ts.ads,
icon: 'ti ti-ad',
});
</script>

View File

@@ -197,6 +197,9 @@ export const routes = [{
}, {
path: '/about-misskey',
component: page(() => import('./pages/about-misskey.vue')),
}, {
path: '/ads',
component: page(() => import('./pages/ads.vue')),
}, {
path: '/theme-editor',
component: page(() => import('./pages/theme-editor.vue')),

View File

@@ -29,6 +29,11 @@ export function openInstanceMenu(ev: MouseEvent) {
icon: 'ti ti-chart-line',
to: '/about#charts',
}, null, {
type: 'link',
text: i18n.ts.ads,
icon: 'ti ti-ad',
to: '/ads',
}, {
type: 'parent',
text: i18n.ts.tools,
icon: 'ti ti-tool',