summaryrefslogtreecommitdiff
path: root/src/client/app/common/views/components/instance.vue
diff options
context:
space:
mode:
authorsyuilo <syuilotan@yahoo.co.jp>2018-09-23 19:55:15 +0900
committersyuilo <syuilotan@yahoo.co.jp>2018-09-23 19:55:15 +0900
commita2e2d5ba776bc27c31a3fd3cd45f563975f764bc (patch)
treea1d7a36ef2306352313365de40edbb65f2cf6599 /src/client/app/common/views/components/instance.vue
parent8.59.0 (diff)
downloadmisskey-a2e2d5ba776bc27c31a3fd3cd45f563975f764bc.tar.gz
misskey-a2e2d5ba776bc27c31a3fd3cd45f563975f764bc.tar.bz2
misskey-a2e2d5ba776bc27c31a3fd3cd45f563975f764bc.zip
非ログイン時のユーザーページにインスタンスの紹介を表示するように
Diffstat (limited to 'src/client/app/common/views/components/instance.vue')
-rw-r--r--src/client/app/common/views/components/instance.vue57
1 files changed, 57 insertions, 0 deletions
diff --git a/src/client/app/common/views/components/instance.vue b/src/client/app/common/views/components/instance.vue
new file mode 100644
index 0000000000..14c6664eff
--- /dev/null
+++ b/src/client/app/common/views/components/instance.vue
@@ -0,0 +1,57 @@
+<template>
+<div class="nhasjydimbopojusarffqjyktglcuxjy" v-if="meta">
+ <div class="banner" :style="{ backgroundImage: meta.bannerUrl ? `url(${meta.bannerUrl})` : null }"></div>
+
+ <h1>{{ meta.name }}</h1>
+ <p v-html="meta.description || '%i18n:common.about%'"></p>
+ <router-link to="/">%i18n:@start%</router-link>
+</div>
+</template>
+
+<script lang="ts">
+import Vue from 'vue';
+
+export default Vue.extend({
+ data() {
+ return {
+ meta: null
+ }
+ },
+ created() {
+ (this as any).os.getMeta().then(meta => {
+ this.meta = meta;
+ });
+ }
+});
+</script>
+
+<style lang="stylus" scoped>
+root(isDark)
+ color isDark ? #fff : #5b646f
+ background isDark ? #21242f : #fff
+ text-align center
+
+ > .banner
+ height 100px
+ background-position center
+ background-size cover
+
+ > h1
+ margin 16px
+ font-size 16px
+
+ > p
+ margin 16px
+ font-size 14px
+
+ > a
+ display block
+ padding-bottom 16px
+
+.nhasjydimbopojusarffqjyktglcuxjy[data-darkmode]
+ root(true)
+
+.nhasjydimbopojusarffqjyktglcuxjy:not([data-darkmode])
+ root(false)
+
+</style>