2021-02-14 07:26:07 -06:00
|
|
|
<template>
|
|
|
|
<div class="mk-app" @contextmenu.self.prevent="onContextmenu">
|
|
|
|
<XSidebar ref="menu" class="menu" :default-hidden="true"/>
|
|
|
|
|
|
|
|
<div class="nav">
|
|
|
|
<header class="header">
|
|
|
|
<div class="left">
|
|
|
|
<button class="_button account" @click="openAccountMenu">
|
2021-02-16 03:21:44 -06:00
|
|
|
<MkAvatar :user="$i" class="avatar"/><!--<MkAcct class="text" :user="$i"/>-->
|
2021-02-14 07:26:07 -06:00
|
|
|
</button>
|
|
|
|
</div>
|
|
|
|
<div class="right">
|
2021-02-16 03:21:44 -06:00
|
|
|
<MkA class="item" to="/my/messaging"><Fa class="icon" :icon="faComments"/><i v-if="$i.hasUnreadMessagingMessage"><Fa :icon="faCircle"/></i></MkA>
|
|
|
|
<MkA class="item" to="/my/messages"><Fa class="icon" :icon="faEnvelope"/><i v-if="$i.hasUnreadSpecifiedNotes"><Fa :icon="faCircle"/></i></MkA>
|
|
|
|
<MkA class="item" to="/my/mentions"><Fa class="icon" :icon="faAt"/><i v-if="$i.hasUnreadMentions"><Fa :icon="faCircle"/></i></MkA>
|
|
|
|
<MkA class="item" to="/my/notifications"><Fa class="icon" :icon="faBell"/><i v-if="$i.hasUnreadNotification"><Fa :icon="faCircle"/></i></MkA>
|
2021-02-14 07:26:07 -06:00
|
|
|
</div>
|
|
|
|
</header>
|
|
|
|
<div class="body">
|
|
|
|
<div class="container">
|
|
|
|
<div class="header">{{ $ts.timeline }}</div>
|
|
|
|
<div class="body">
|
|
|
|
<MkA to="/timeline/home" class="item" :class="{ active: tl === 'home' }"><Fa :icon="faHome" class="icon"/>{{ $ts._timelines.home }}</MkA>
|
2021-02-16 03:21:44 -06:00
|
|
|
<MkA to="/timeline/local" class="item" :class="{ active: tl === 'local' }"><Fa :icon="faComments" class="icon"/>{{ $ts._timelines.local }}</MkA>
|
|
|
|
<MkA to="/timeline/social" class="item" :class="{ active: tl === 'social' }"><Fa :icon="faShareAlt" class="icon"/>{{ $ts._timelines.social }}</MkA>
|
|
|
|
<MkA to="/timeline/global" class="item" :class="{ active: tl === 'global' }"><Fa :icon="faGlobe" class="icon"/>{{ $ts._timelines.global }}</MkA>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="container" v-if="followedChannels">
|
|
|
|
<div class="header">{{ $ts.channel }} ({{ $ts.following }})<button class="_button add" @click="addChannel"><Fa :icon="faPlus"/></button></div>
|
|
|
|
<div class="body">
|
|
|
|
<MkA v-for="channel in followedChannels" :key="channel.id" :to="`/channels/${ channel.id }`" class="item" :class="{ active: tl === `channel:${ channel.id }`, read: !channel.hasUnreadNote }"><Fa :icon="faSatelliteDish" class="icon"/>{{ channel.name }}</MkA>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="container" v-if="featuredChannels">
|
|
|
|
<div class="header">{{ $ts.channel }}<button class="_button add" @click="addChannel"><Fa :icon="faPlus"/></button></div>
|
|
|
|
<div class="body">
|
|
|
|
<MkA v-for="channel in featuredChannels" :key="channel.id" :to="`/channels/${ channel.id }`" class="item" :class="{ active: tl === `channel:${ channel.id }` }"><Fa :icon="faSatelliteDish" class="icon"/>{{ channel.name }}</MkA>
|
2021-02-14 07:26:07 -06:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="container" v-if="lists">
|
2021-02-16 03:21:44 -06:00
|
|
|
<div class="header">{{ $ts.lists }}<button class="_button add" @click="addList"><Fa :icon="faPlus"/></button></div>
|
2021-02-14 07:26:07 -06:00
|
|
|
<div class="body">
|
|
|
|
<MkA v-for="list in lists" :key="list.id" :to="`/my/list/${ list.id }`" class="item" :class="{ active: tl === `list:${ list.id }` }"><Fa :icon="faListUl" class="icon"/>{{ list.name }}</MkA>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="container" v-if="antennas">
|
2021-02-16 03:21:44 -06:00
|
|
|
<div class="header">{{ $ts.antennas }}<button class="_button add" @click="addAntenna"><Fa :icon="faPlus"/></button></div>
|
2021-02-14 07:26:07 -06:00
|
|
|
<div class="body">
|
|
|
|
<MkA v-for="antenna in antennas" :key="antenna.id" :to="`/my/antenna/${ antenna.id }`" class="item" :class="{ active: tl === `antenna:${ antenna.id }` }"><Fa :icon="faSatellite" class="icon"/>{{ antenna.name }}</MkA>
|
|
|
|
</div>
|
|
|
|
</div>
|
2021-02-16 03:21:44 -06:00
|
|
|
<div class="container">
|
2021-02-14 07:26:07 -06:00
|
|
|
<div class="body">
|
2021-02-16 03:21:44 -06:00
|
|
|
<MkA to="/my/favorites" class="item"><Fa :icon="faStar" class="icon"/>{{ $ts.favorites }}</MkA>
|
2021-02-14 07:26:07 -06:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<footer class="footer">
|
|
|
|
<div class="left">
|
|
|
|
<button class="_button menu" @click="showMenu">
|
2021-02-16 03:21:44 -06:00
|
|
|
<Fa class="icon" :icon="faBars"/>
|
2021-02-14 07:26:07 -06:00
|
|
|
</button>
|
|
|
|
</div>
|
|
|
|
<div class="right">
|
2021-02-16 03:21:44 -06:00
|
|
|
<button class="_button item search" @click="search">
|
|
|
|
<Fa :icon="faSearch"/>
|
|
|
|
</button>
|
|
|
|
<MkA class="item" to="/settings"><Fa class="icon" :icon="faCog"/></MkA>
|
2021-02-14 07:26:07 -06:00
|
|
|
</div>
|
|
|
|
</footer>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<main class="main" @contextmenu.stop="onContextmenu">
|
|
|
|
<header class="header" ref="header" @click="onHeaderClick">
|
2021-02-15 02:17:19 -06:00
|
|
|
<div class="left">
|
|
|
|
<template v-if="tl === 'home'">
|
|
|
|
<Fa :icon="faHome" class="icon"/>
|
|
|
|
<div class="title">{{ $ts._timelines.home }}</div>
|
|
|
|
</template>
|
|
|
|
<template v-else-if="tl === 'local'">
|
2021-02-16 03:21:44 -06:00
|
|
|
<Fa :icon="faComments" class="icon"/>
|
2021-02-15 02:17:19 -06:00
|
|
|
<div class="title">{{ $ts._timelines.local }}</div>
|
|
|
|
</template>
|
|
|
|
<template v-else-if="tl === 'social'">
|
|
|
|
<Fa :icon="faShareAlt" class="icon"/>
|
|
|
|
<div class="title">{{ $ts._timelines.social }}</div>
|
|
|
|
</template>
|
|
|
|
<template v-else-if="tl === 'global'">
|
2021-02-16 03:21:44 -06:00
|
|
|
<Fa :icon="faGlobe" class="icon"/>
|
2021-02-15 02:17:19 -06:00
|
|
|
<div class="title">{{ $ts._timelines.global }}</div>
|
|
|
|
</template>
|
2021-02-15 06:00:37 -06:00
|
|
|
<template v-else-if="tl.startsWith('channel:')">
|
|
|
|
<Fa :icon="faSatelliteDish" class="icon"/>
|
2021-02-15 22:13:42 -06:00
|
|
|
<div class="title" v-if="currentChannel">{{ currentChannel.name }}<div class="description">{{ currentChannel.description }}</div></div>
|
2021-02-15 06:00:37 -06:00
|
|
|
</template>
|
2021-02-14 07:26:07 -06:00
|
|
|
</div>
|
2021-02-15 02:17:19 -06:00
|
|
|
|
|
|
|
<div class="right">
|
2021-02-15 22:13:42 -06:00
|
|
|
<XHeaderClock class="clock"/>
|
2021-02-16 03:21:44 -06:00
|
|
|
<button class="_button button search" @click="search">
|
|
|
|
<Fa :icon="faSearch"/>
|
|
|
|
</button>
|
2021-02-15 22:13:42 -06:00
|
|
|
<button class="_button button follow" v-if="tl.startsWith('channel:') && currentChannel" :class="{ followed: currentChannel.isFollowing }" @click="toggleChannelFollow">
|
|
|
|
<Fa v-if="currentChannel.isFollowing" :icon="faStar"/>
|
|
|
|
<Fa v-else :icon="farStar"/>
|
|
|
|
</button>
|
2021-02-16 03:21:44 -06:00
|
|
|
<button class="_button button menu" v-if="tl.startsWith('channel:') && currentChannel" @click="openChannelMenu">
|
|
|
|
<Fa :icon="faEllipsisH"/>
|
2021-02-15 06:00:37 -06:00
|
|
|
</button>
|
2021-02-14 07:26:07 -06:00
|
|
|
</div>
|
|
|
|
</header>
|
|
|
|
<div class="body">
|
|
|
|
<XTimeline v-if="tl.startsWith('channel:')" src="channel" :key="tl" :channel="tl.replace('channel:', '')"/>
|
|
|
|
<XTimeline v-else :src="tl" :key="tl"/>
|
|
|
|
</div>
|
|
|
|
<footer class="footer">
|
|
|
|
<XPostForm v-if="tl.startsWith('channel:')" :key="tl" :channel="tl.replace('channel:', '')"/>
|
|
|
|
<XPostForm v-else/>
|
|
|
|
</footer>
|
|
|
|
</main>
|
|
|
|
|
|
|
|
<XSide class="side" ref="side"/>
|
|
|
|
|
|
|
|
<XCommon/>
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script lang="ts">
|
|
|
|
import { defineComponent, defineAsyncComponent } from 'vue';
|
2021-02-16 03:21:44 -06:00
|
|
|
import { faLayerGroup, faBars, faHome, faCircle, faWindowMaximize, faColumns, faPencilAlt, faShareAlt, faSatelliteDish, faListUl, faSatellite, faCog, faSearch, faPlus, faStar, faAt, faLink, faEllipsisH, faGlobe } from '@fortawesome/free-solid-svg-icons';
|
|
|
|
import { faBell, faStar as farStar, faEnvelope, faComments } from '@fortawesome/free-regular-svg-icons';
|
|
|
|
import { instanceName, url } from '@/config';
|
2021-02-14 07:26:07 -06:00
|
|
|
import XSidebar from '@/components/sidebar.vue';
|
|
|
|
import XCommon from '../_common_/common.vue';
|
|
|
|
import XSide from './side.vue';
|
|
|
|
import XTimeline from './timeline.vue';
|
|
|
|
import XPostForm from './post-form.vue';
|
2021-02-15 02:17:19 -06:00
|
|
|
import XHeaderClock from './header-clock.vue';
|
2021-02-14 07:26:07 -06:00
|
|
|
import * as os from '@/os';
|
2021-02-15 22:13:42 -06:00
|
|
|
import { router } from '@/router';
|
2021-02-14 07:26:07 -06:00
|
|
|
import { sidebarDef } from '@/sidebar';
|
2021-02-15 22:13:42 -06:00
|
|
|
import { search } from '@/scripts/search';
|
2021-02-16 03:21:44 -06:00
|
|
|
import copyToClipboard from '@/scripts/copy-to-clipboard';
|
2021-02-14 07:26:07 -06:00
|
|
|
|
|
|
|
export default defineComponent({
|
|
|
|
components: {
|
|
|
|
XCommon,
|
|
|
|
XSidebar,
|
|
|
|
XSide, // NOTE: dynamic importするとAsyncComponentWrapperが間に入るせいでref取得できなくて面倒になる
|
|
|
|
XTimeline,
|
|
|
|
XPostForm,
|
2021-02-15 02:17:19 -06:00
|
|
|
XHeaderClock,
|
2021-02-14 07:26:07 -06:00
|
|
|
},
|
|
|
|
|
|
|
|
provide() {
|
|
|
|
return {
|
|
|
|
navHook: (path) => {
|
|
|
|
switch (path) {
|
|
|
|
case '/timeline/home': this.tl = 'home'; return;
|
|
|
|
case '/timeline/local': this.tl = 'local'; return;
|
|
|
|
case '/timeline/social': this.tl = 'social'; return;
|
|
|
|
case '/timeline/global': this.tl = 'global'; return;
|
|
|
|
|
|
|
|
default:
|
|
|
|
if (path.startsWith('/channels/')) {
|
|
|
|
this.tl = `channel:${ path.replace('/channels/', '') }`;
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
//os.pageWindow(path);
|
|
|
|
this.$refs.side.navigate(path);
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
},
|
|
|
|
sideViewHook: (path) => {
|
|
|
|
this.$refs.side.navigate(path);
|
|
|
|
}
|
|
|
|
};
|
|
|
|
},
|
|
|
|
|
|
|
|
data() {
|
|
|
|
return {
|
|
|
|
tl: 'home',
|
|
|
|
lists: null,
|
|
|
|
antennas: null,
|
|
|
|
followedChannels: null,
|
|
|
|
featuredChannels: null,
|
2021-02-15 06:00:37 -06:00
|
|
|
currentChannel: null,
|
2021-02-14 07:26:07 -06:00
|
|
|
menuDef: sidebarDef,
|
2021-02-16 03:21:44 -06:00
|
|
|
faLayerGroup, faBars, faBell, faHome, faCircle, faPencilAlt, faShareAlt, faSatelliteDish, faListUl, faSatellite, faCog, faSearch, faPlus, faStar, farStar, faAt, faLink, faEllipsisH, faGlobe, faComments, faEnvelope,
|
2021-02-14 07:26:07 -06:00
|
|
|
};
|
|
|
|
},
|
|
|
|
|
|
|
|
created() {
|
2021-02-15 22:13:42 -06:00
|
|
|
router.beforeEach((to, from) => {
|
|
|
|
this.$refs.side.navigate(to.fullPath);
|
|
|
|
// search?q=foo のようなクエリを受け取れるようにするため、return falseはできない
|
|
|
|
//return false;
|
|
|
|
});
|
|
|
|
|
2021-02-14 07:26:07 -06:00
|
|
|
os.api('users/lists/list').then(lists => {
|
|
|
|
this.lists = lists;
|
|
|
|
});
|
|
|
|
|
|
|
|
os.api('antennas/list').then(antennas => {
|
|
|
|
this.antennas = antennas;
|
|
|
|
});
|
|
|
|
|
|
|
|
os.api('channels/followed').then(channels => {
|
|
|
|
this.followedChannels = channels;
|
|
|
|
});
|
|
|
|
|
|
|
|
os.api('channels/featured').then(channels => {
|
|
|
|
this.featuredChannels = channels;
|
|
|
|
});
|
2021-02-15 06:00:37 -06:00
|
|
|
|
|
|
|
this.$watch('tl', () => {
|
|
|
|
if (this.tl.startsWith('channel:')) {
|
|
|
|
os.api('channels/show', { channelId: this.tl.replace('channel:', '') }).then(channel => {
|
|
|
|
this.currentChannel = channel;
|
|
|
|
});
|
|
|
|
}
|
|
|
|
}, { immediate: true });
|
2021-02-14 07:26:07 -06:00
|
|
|
},
|
|
|
|
|
|
|
|
methods: {
|
|
|
|
showMenu() {
|
|
|
|
this.$refs.menu.show();
|
|
|
|
},
|
|
|
|
|
|
|
|
post() {
|
|
|
|
os.post();
|
|
|
|
},
|
|
|
|
|
2021-02-15 22:13:42 -06:00
|
|
|
search() {
|
|
|
|
search();
|
|
|
|
},
|
|
|
|
|
2021-02-14 07:26:07 -06:00
|
|
|
top() {
|
|
|
|
window.scroll({ top: 0, behavior: 'smooth' });
|
|
|
|
},
|
|
|
|
|
2021-02-15 22:13:42 -06:00
|
|
|
async toggleChannelFollow() {
|
|
|
|
if (this.currentChannel.isFollowing) {
|
|
|
|
await os.apiWithDialog('channels/unfollow', {
|
|
|
|
channelId: this.currentChannel.id
|
|
|
|
});
|
|
|
|
this.currentChannel.isFollowing = false;
|
|
|
|
} else {
|
|
|
|
await os.apiWithDialog('channels/follow', {
|
|
|
|
channelId: this.currentChannel.id
|
|
|
|
});
|
|
|
|
this.currentChannel.isFollowing = true;
|
|
|
|
}
|
|
|
|
},
|
|
|
|
|
2021-02-16 03:21:44 -06:00
|
|
|
openChannelMenu(ev) {
|
|
|
|
os.modalMenu([{
|
|
|
|
text: this.$ts.copyUrl,
|
|
|
|
icon: faLink,
|
|
|
|
action: () => {
|
|
|
|
copyToClipboard(`${url}/channels/${this.currentChannel.id}`);
|
|
|
|
}
|
|
|
|
}], ev.currentTarget || ev.target);
|
|
|
|
},
|
|
|
|
|
2021-02-14 07:26:07 -06:00
|
|
|
onTransition() {
|
|
|
|
if (window._scroll) window._scroll();
|
|
|
|
},
|
|
|
|
|
|
|
|
onHeaderClick() {
|
|
|
|
window.scroll({ top: 0, behavior: 'smooth' });
|
|
|
|
},
|
|
|
|
|
|
|
|
onContextmenu(e) {
|
|
|
|
const isLink = (el: HTMLElement) => {
|
|
|
|
if (el.tagName === 'A') return true;
|
|
|
|
if (el.parentElement) {
|
|
|
|
return isLink(el.parentElement);
|
|
|
|
}
|
|
|
|
};
|
|
|
|
if (isLink(e.target)) return;
|
|
|
|
if (['INPUT', 'TEXTAREA'].includes(e.target.tagName) || e.target.attributes['contenteditable']) return;
|
|
|
|
if (window.getSelection().toString() !== '') return;
|
|
|
|
const path = this.$route.path;
|
|
|
|
os.contextMenu([{
|
|
|
|
type: 'label',
|
|
|
|
text: path,
|
|
|
|
}, {
|
|
|
|
icon: faColumns,
|
|
|
|
text: this.$ts.openInSideView,
|
|
|
|
action: () => {
|
|
|
|
this.$refs.side.navigate(path);
|
|
|
|
}
|
|
|
|
}, {
|
|
|
|
icon: faWindowMaximize,
|
|
|
|
text: this.$ts.openInWindow,
|
|
|
|
action: () => {
|
|
|
|
os.pageWindow(path);
|
|
|
|
}
|
|
|
|
}], e);
|
|
|
|
},
|
|
|
|
}
|
|
|
|
});
|
|
|
|
</script>
|
|
|
|
|
|
|
|
<style lang="scss" scoped>
|
|
|
|
.mk-app {
|
|
|
|
$header-height: 54px; // TODO: どこかに集約したい
|
|
|
|
$ui-font-size: 1em; // TODO: どこかに集約したい
|
|
|
|
|
|
|
|
// ほんとは単に 100vh と書きたいところだが... https://css-tricks.com/the-trick-to-viewport-units-on-mobile/
|
|
|
|
min-height: calc(var(--vh, 1vh) * 100);
|
|
|
|
box-sizing: border-box;
|
|
|
|
display: flex;
|
|
|
|
|
|
|
|
> .nav {
|
|
|
|
display: flex;
|
|
|
|
flex-direction: column;
|
|
|
|
width: 250px;
|
|
|
|
height: 100vh;
|
|
|
|
border-right: solid 1px var(--divider);
|
|
|
|
|
|
|
|
> .header, > .footer {
|
|
|
|
$padding: 8px;
|
|
|
|
display: flex;
|
2021-02-16 03:21:44 -06:00
|
|
|
align-items: center;
|
2021-02-14 07:26:07 -06:00
|
|
|
z-index: 1000;
|
|
|
|
height: $header-height;
|
|
|
|
padding: $padding;
|
|
|
|
box-sizing: border-box;
|
|
|
|
user-select: none;
|
|
|
|
|
|
|
|
&.header {
|
|
|
|
border-bottom: solid 1px var(--divider);
|
|
|
|
}
|
|
|
|
|
|
|
|
&.footer {
|
|
|
|
border-top: solid 1px var(--divider);
|
|
|
|
}
|
|
|
|
|
2021-02-15 02:17:19 -06:00
|
|
|
> .left, > .right {
|
|
|
|
> .item, > .menu {
|
2021-02-16 03:21:44 -06:00
|
|
|
display: inline-block;
|
|
|
|
vertical-align: middle;
|
2021-02-14 07:26:07 -06:00
|
|
|
height: ($header-height - ($padding * 2));
|
|
|
|
width: ($header-height - ($padding * 2));
|
|
|
|
box-sizing: border-box;
|
2021-02-14 07:52:45 -06:00
|
|
|
//opacity: 0.6;
|
|
|
|
position: relative;
|
2021-02-16 03:21:44 -06:00
|
|
|
border-radius: 5px;
|
|
|
|
|
|
|
|
&:hover {
|
|
|
|
background: rgba(0, 0, 0, 0.05);
|
|
|
|
}
|
|
|
|
|
|
|
|
> .icon {
|
|
|
|
position: absolute;
|
|
|
|
top: 0;
|
|
|
|
left: 0;
|
|
|
|
right: 0;
|
|
|
|
bottom: 0;
|
|
|
|
margin: auto;
|
|
|
|
}
|
2021-02-14 07:52:45 -06:00
|
|
|
|
|
|
|
> i {
|
|
|
|
position: absolute;
|
|
|
|
top: 8px;
|
|
|
|
right: 8px;
|
|
|
|
color: var(--indicator);
|
|
|
|
font-size: 8px;
|
|
|
|
line-height: 8px;
|
|
|
|
animation: blink 1s infinite;
|
|
|
|
}
|
2021-02-14 07:26:07 -06:00
|
|
|
}
|
|
|
|
}
|
2021-02-15 02:17:19 -06:00
|
|
|
|
|
|
|
> .left {
|
2021-02-16 03:21:44 -06:00
|
|
|
flex: 1;
|
|
|
|
min-width: 0;
|
|
|
|
|
2021-02-15 02:17:19 -06:00
|
|
|
> .account {
|
|
|
|
display: flex;
|
|
|
|
align-items: center;
|
|
|
|
padding: 0 8px;
|
|
|
|
|
|
|
|
> .avatar {
|
|
|
|
width: 26px;
|
|
|
|
height: 26px;
|
|
|
|
margin-right: 8px;
|
|
|
|
}
|
2021-02-16 03:21:44 -06:00
|
|
|
|
|
|
|
> .text {
|
|
|
|
white-space: nowrap;
|
|
|
|
overflow: hidden;
|
|
|
|
text-overflow: ellipsis;
|
|
|
|
font-size: 0.9em;
|
|
|
|
}
|
2021-02-15 02:17:19 -06:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
> .right {
|
|
|
|
margin-left: auto;
|
|
|
|
}
|
2021-02-14 07:26:07 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
> .body {
|
|
|
|
flex: 1;
|
|
|
|
min-width: 0;
|
2021-02-15 06:00:37 -06:00
|
|
|
padding: 8px 0;
|
2021-02-14 07:26:07 -06:00
|
|
|
overflow: auto;
|
|
|
|
|
|
|
|
> .container {
|
|
|
|
& + .container {
|
|
|
|
margin-top: 16px;
|
|
|
|
}
|
|
|
|
|
|
|
|
> .header {
|
2021-02-15 06:00:37 -06:00
|
|
|
display: flex;
|
2021-02-14 07:26:07 -06:00
|
|
|
font-size: 0.9em;
|
|
|
|
padding: 8px 16px;
|
|
|
|
opacity: 0.7;
|
2021-02-15 06:00:37 -06:00
|
|
|
|
|
|
|
> .add {
|
|
|
|
margin-left: auto;
|
|
|
|
}
|
2021-02-14 07:26:07 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
> .body {
|
|
|
|
padding: 0 8px;
|
|
|
|
|
|
|
|
> .item {
|
|
|
|
display: block;
|
|
|
|
padding: 6px 8px;
|
|
|
|
border-radius: 4px;
|
|
|
|
|
|
|
|
&:hover {
|
|
|
|
text-decoration: none;
|
|
|
|
background: rgba(0, 0, 0, 0.05);
|
|
|
|
}
|
|
|
|
|
|
|
|
&.active, &.active:hover {
|
|
|
|
background: var(--accent);
|
|
|
|
color: #fff;
|
|
|
|
}
|
|
|
|
|
|
|
|
&.read {
|
|
|
|
opacity: 0.5;
|
|
|
|
}
|
|
|
|
|
|
|
|
> .icon {
|
2021-02-15 06:00:37 -06:00
|
|
|
margin-right: 8px;
|
2021-02-14 07:26:07 -06:00
|
|
|
opacity: 0.6;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
> .main {
|
|
|
|
display: flex;
|
|
|
|
flex: 1;
|
|
|
|
flex-direction: column;
|
|
|
|
min-width: 0;
|
|
|
|
height: 100vh;
|
|
|
|
position: relative;
|
|
|
|
background: var(--panel);
|
|
|
|
|
|
|
|
> .header {
|
|
|
|
$padding: 8px;
|
2021-02-15 02:17:19 -06:00
|
|
|
display: flex;
|
2021-02-14 07:26:07 -06:00
|
|
|
z-index: 1000;
|
|
|
|
height: $header-height;
|
|
|
|
padding: $padding;
|
|
|
|
box-sizing: border-box;
|
2021-02-14 07:54:28 -06:00
|
|
|
background-color: var(--panel);
|
2021-02-14 07:26:07 -06:00
|
|
|
border-bottom: solid 1px var(--divider);
|
|
|
|
user-select: none;
|
|
|
|
|
2021-02-15 02:17:19 -06:00
|
|
|
> .left {
|
2021-02-14 07:26:07 -06:00
|
|
|
display: flex;
|
2021-02-15 22:13:42 -06:00
|
|
|
align-items: center;
|
2021-02-15 06:00:37 -06:00
|
|
|
flex: 1;
|
|
|
|
min-width: 0;
|
2021-02-14 07:26:07 -06:00
|
|
|
|
|
|
|
> .icon {
|
|
|
|
height: ($header-height - ($padding * 2));
|
|
|
|
width: ($header-height - ($padding * 2));
|
|
|
|
padding: 10px;
|
|
|
|
box-sizing: border-box;
|
|
|
|
margin-right: 4px;
|
|
|
|
opacity: 0.6;
|
|
|
|
}
|
2021-02-15 06:00:37 -06:00
|
|
|
|
2021-02-15 22:13:42 -06:00
|
|
|
> .title {
|
2021-02-15 06:00:37 -06:00
|
|
|
overflow: hidden;
|
|
|
|
text-overflow: ellipsis;
|
|
|
|
white-space: nowrap;
|
|
|
|
min-width: 0;
|
|
|
|
font-weight: bold;
|
|
|
|
|
2021-02-15 22:13:42 -06:00
|
|
|
> .description {
|
|
|
|
opacity: 0.6;
|
|
|
|
font-size: 0.8em;
|
2021-02-16 03:21:44 -06:00
|
|
|
font-weight: normal;
|
2021-02-15 22:13:42 -06:00
|
|
|
white-space: nowrap;
|
|
|
|
overflow: hidden;
|
|
|
|
text-overflow: ellipsis;
|
|
|
|
}
|
2021-02-15 06:00:37 -06:00
|
|
|
}
|
2021-02-14 07:26:07 -06:00
|
|
|
}
|
2021-02-15 02:17:19 -06:00
|
|
|
|
|
|
|
> .right {
|
2021-02-15 06:00:37 -06:00
|
|
|
display: flex;
|
2021-02-15 22:13:42 -06:00
|
|
|
align-items: center;
|
2021-02-15 06:00:37 -06:00
|
|
|
min-width: 0;
|
2021-02-15 02:17:19 -06:00
|
|
|
margin-left: auto;
|
2021-02-15 06:00:37 -06:00
|
|
|
padding-left: 8px;
|
|
|
|
|
2021-02-15 22:13:42 -06:00
|
|
|
> .clock {
|
2021-02-16 03:21:44 -06:00
|
|
|
margin-right: 16px;
|
2021-02-15 22:13:42 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
> .button {
|
2021-02-15 06:00:37 -06:00
|
|
|
height: ($header-height - ($padding * 2));
|
|
|
|
width: ($header-height - ($padding * 2));
|
|
|
|
box-sizing: border-box;
|
|
|
|
position: relative;
|
|
|
|
border-radius: 5px;
|
|
|
|
|
|
|
|
&:hover {
|
|
|
|
background: rgba(0, 0, 0, 0.05);
|
|
|
|
}
|
2021-02-15 22:13:42 -06:00
|
|
|
|
|
|
|
&.follow.followed {
|
|
|
|
color: var(--accent);
|
|
|
|
}
|
2021-02-15 06:00:37 -06:00
|
|
|
}
|
2021-02-15 02:17:19 -06:00
|
|
|
}
|
2021-02-14 07:26:07 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
> .footer {
|
2021-02-15 02:17:19 -06:00
|
|
|
padding: 0 16px 16px 16px;
|
2021-02-14 07:26:07 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
> .body {
|
|
|
|
flex: 1;
|
|
|
|
min-width: 0;
|
|
|
|
overflow: auto;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
> .side {
|
|
|
|
border-left: solid 1px var(--divider);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
</style>
|