diff options
| author | Xeltica <7106976+Xeltica@users.noreply.github.com> | 2020-11-07 12:31:23 +0900 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-11-07 12:31:23 +0900 |
| commit | 1fcfd8e64573f8437be0aacd4187284b356e4625 (patch) | |
| tree | 3cdca523662cdc2e8829f1b3d809d2682ef60bd8 /src/client | |
| parent | Improve usability (diff) | |
| download | misskey-1fcfd8e64573f8437be0aacd4187284b356e4625.tar.gz misskey-1fcfd8e64573f8437be0aacd4187284b356e4625.tar.bz2 misskey-1fcfd8e64573f8437be0aacd4187284b356e4625.zip | |
ヘッダーに表示されるタブのインジケーターを実装 (#6803)
* Implemente indicators on headers
* 微調整
Diffstat (limited to 'src/client')
| -rw-r--r-- | src/client/ui/_common_/header.vue | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/src/client/ui/_common_/header.vue b/src/client/ui/_common_/header.vue index af7f1c2b6a..87a5621902 100644 --- a/src/client/ui/_common_/header.vue +++ b/src/client/ui/_common_/header.vue @@ -9,6 +9,7 @@ <div class="title" v-for="tab in info.tabs" :key="tab.id" :class="{ _button: tab.onClick, selected: tab.selected }" @click.stop="tab.onClick" v-tooltip="tab.tooltip"> <Fa v-if="tab.icon" :icon="tab.icon" :key="tab.icon" class="icon"/> <span v-if="tab.title" class="text">{{ tab.title }}</span> + <Fa class="indicator" v-if="tab.indicate" :icon="faCircle"/> </div> </template> <template v-else> @@ -27,7 +28,7 @@ <script lang="ts"> import { defineComponent } from 'vue'; -import { faChevronLeft } from '@fortawesome/free-solid-svg-icons'; +import { faChevronLeft, faCircle } from '@fortawesome/free-solid-svg-icons'; export default defineComponent({ props: { @@ -45,7 +46,7 @@ export default defineComponent({ return { canBack: false, height: 0, - faChevronLeft + faChevronLeft, faCircle }; }, @@ -131,6 +132,17 @@ export default defineComponent({ overflow: hidden; text-overflow: ellipsis; padding: 0 16px; + position: relative; + + > .indicator { + position: absolute; + top: initial; + right: 8px; + top: 8px; + color: var(--indicator); + font-size: 12px; + animation: blink 1s infinite; + } > .icon + .text { margin-left: 8px; |