Merge branch 'develop' into sw-notification-action
This commit is contained in:
@@ -48,15 +48,7 @@ export default defineComponent({
|
||||
render() {
|
||||
if (this.items.length === 0) return;
|
||||
|
||||
return h(this.$store.state.animation ? TransitionGroup : 'div', this.$store.state.animation ? {
|
||||
class: 'sqadhkmv' + (this.noGap ? ' noGap _block' : ''),
|
||||
name: 'list',
|
||||
tag: 'div',
|
||||
'data-direction': this.direction,
|
||||
'data-reversed': this.reversed ? 'true' : 'false',
|
||||
} : {
|
||||
class: 'sqadhkmv' + (this.noGap ? ' noGap _block' : ''),
|
||||
}, this.items.map((item, i) => {
|
||||
const renderChildren = () => this.items.map((item, i) => {
|
||||
const el = this.$slots.default({
|
||||
item: item
|
||||
})[0];
|
||||
@@ -98,7 +90,19 @@ export default defineComponent({
|
||||
return el;
|
||||
}
|
||||
}
|
||||
}));
|
||||
});
|
||||
|
||||
return h(this.$store.state.animation ? TransitionGroup : 'div', this.$store.state.animation ? {
|
||||
class: 'sqadhkmv' + (this.noGap ? ' noGap _block' : ''),
|
||||
name: 'list',
|
||||
tag: 'div',
|
||||
'data-direction': this.direction,
|
||||
'data-reversed': this.reversed ? 'true' : 'false',
|
||||
} : {
|
||||
class: 'sqadhkmv' + (this.noGap ? ' noGap _block' : ''),
|
||||
}, {
|
||||
default: renderChildren
|
||||
});
|
||||
},
|
||||
});
|
||||
</script>
|
||||
|
||||
@@ -114,7 +114,7 @@ export default defineComponent({
|
||||
if (this.selectMode) {
|
||||
this.$emit('chosen', this.file);
|
||||
} else {
|
||||
os.modalMenu(this.getMenu(), ev.currentTarget || ev.target);
|
||||
os.popupMenu(this.getMenu(), ev.currentTarget || ev.target);
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
@@ -629,7 +629,7 @@ export default defineComponent({
|
||||
},
|
||||
|
||||
showMenu(ev) {
|
||||
os.modalMenu(this.getMenu(), ev.currentTarget || ev.target);
|
||||
os.popupMenu(this.getMenu(), ev.currentTarget || ev.target);
|
||||
},
|
||||
|
||||
onContextmenu(ev) {
|
||||
|
||||
@@ -1,17 +1,17 @@
|
||||
<template>
|
||||
<MkModal ref="modal" :manual-showing="manualShowing" :src="src" :front="true" @click="$refs.modal.close()" @opening="opening" @close="$emit('close')" @closed="$emit('closed')">
|
||||
<MkEmojiPicker :show-pinned="showPinned" :as-reaction-picker="asReactionPicker" @chosen="chosen" ref="picker"/>
|
||||
</MkModal>
|
||||
<MkPopup ref="popup" :manual-showing="manualShowing" :src="src" :front="true" @click="$refs.popup.close()" @opening="opening" @close="$emit('close')" @closed="$emit('closed')" #default="{point}">
|
||||
<MkEmojiPicker class="ryghynhb _popup _shadow" :class="{ pointer: point === 'top' }" :show-pinned="showPinned" :as-reaction-picker="asReactionPicker" @chosen="chosen" ref="picker"/>
|
||||
</MkPopup>
|
||||
</template>
|
||||
|
||||
<script lang="ts">
|
||||
import { defineComponent, markRaw } from 'vue';
|
||||
import MkModal from '@client/components/ui/modal.vue';
|
||||
import MkPopup from '@client/components/ui/popup.vue';
|
||||
import MkEmojiPicker from '@client/components/emoji-picker.vue';
|
||||
|
||||
export default defineComponent({
|
||||
components: {
|
||||
MkModal,
|
||||
MkPopup,
|
||||
MkEmojiPicker,
|
||||
},
|
||||
|
||||
@@ -33,7 +33,7 @@ export default defineComponent({
|
||||
},
|
||||
},
|
||||
|
||||
emits: ['done', 'closed'],
|
||||
emits: ['done', 'close', 'closed'],
|
||||
|
||||
data() {
|
||||
return {
|
||||
@@ -44,7 +44,7 @@ export default defineComponent({
|
||||
methods: {
|
||||
chosen(emoji: any) {
|
||||
this.$emit('done', emoji);
|
||||
this.$refs.modal.close();
|
||||
this.$refs.popup.close();
|
||||
},
|
||||
|
||||
opening() {
|
||||
@@ -56,145 +56,20 @@ export default defineComponent({
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.omfetrab {
|
||||
$pad: 8px;
|
||||
--eachSize: 40px;
|
||||
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
contain: content;
|
||||
|
||||
&.big {
|
||||
--eachSize: 44px;
|
||||
}
|
||||
|
||||
&.w1 {
|
||||
width: calc((var(--eachSize) * 5) + (#{$pad} * 2));
|
||||
}
|
||||
|
||||
&.w2 {
|
||||
width: calc((var(--eachSize) * 6) + (#{$pad} * 2));
|
||||
}
|
||||
|
||||
&.w3 {
|
||||
width: calc((var(--eachSize) * 7) + (#{$pad} * 2));
|
||||
}
|
||||
|
||||
&.h1 {
|
||||
--height: calc((var(--eachSize) * 4) + (#{$pad} * 2));
|
||||
}
|
||||
|
||||
&.h2 {
|
||||
--height: calc((var(--eachSize) * 6) + (#{$pad} * 2));
|
||||
}
|
||||
|
||||
&.h3 {
|
||||
--height: calc((var(--eachSize) * 8) + (#{$pad} * 2));
|
||||
}
|
||||
|
||||
> .search {
|
||||
width: 100%;
|
||||
padding: 12px;
|
||||
box-sizing: border-box;
|
||||
font-size: 1em;
|
||||
outline: none;
|
||||
border: none;
|
||||
background: transparent;
|
||||
color: var(--fg);
|
||||
|
||||
&:not(.filled) {
|
||||
order: 1;
|
||||
z-index: 2;
|
||||
box-shadow: 0px -1px 0 0px var(--divider);
|
||||
}
|
||||
}
|
||||
|
||||
> .emojis {
|
||||
height: var(--height);
|
||||
overflow-y: auto;
|
||||
overflow-x: hidden;
|
||||
|
||||
scrollbar-width: none;
|
||||
|
||||
&::-webkit-scrollbar {
|
||||
display: none;
|
||||
}
|
||||
|
||||
> .index {
|
||||
min-height: var(--height);
|
||||
position: relative;
|
||||
border-bottom: solid 0.5px var(--divider);
|
||||
|
||||
> .arrow {
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
padding: 16px 0;
|
||||
text-align: center;
|
||||
opacity: 0.5;
|
||||
pointer-events: none;
|
||||
}
|
||||
}
|
||||
|
||||
section {
|
||||
> header {
|
||||
position: sticky;
|
||||
top: 0;
|
||||
left: 0;
|
||||
z-index: 1;
|
||||
padding: 8px;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
> div {
|
||||
padding: $pad;
|
||||
|
||||
> button {
|
||||
position: relative;
|
||||
padding: 0;
|
||||
width: var(--eachSize);
|
||||
height: var(--eachSize);
|
||||
border-radius: 4px;
|
||||
|
||||
&:focus {
|
||||
outline: solid 2px var(--focus);
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
&:hover {
|
||||
background: rgba(0, 0, 0, 0.05);
|
||||
}
|
||||
|
||||
&:active {
|
||||
background: var(--accent);
|
||||
box-shadow: inset 0 0.15em 0.3em rgba(27, 31, 35, 0.15);
|
||||
}
|
||||
|
||||
> * {
|
||||
font-size: 24px;
|
||||
height: 1.25em;
|
||||
vertical-align: -.25em;
|
||||
pointer-events: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&.result {
|
||||
border-bottom: solid 0.5px var(--divider);
|
||||
|
||||
&:empty {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
&.unicode {
|
||||
min-height: 384px;
|
||||
}
|
||||
|
||||
&.custom {
|
||||
min-height: 64px;
|
||||
}
|
||||
.ryghynhb {
|
||||
&.pointer {
|
||||
&:before {
|
||||
--size: 8px;
|
||||
content: '';
|
||||
display: block;
|
||||
position: absolute;
|
||||
top: calc(0px - (var(--size) * 2));
|
||||
left: 0;
|
||||
right: 0;
|
||||
width: 0;
|
||||
margin: auto;
|
||||
border: solid var(--size) transparent;
|
||||
border-bottom-color: var(--popup);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<div class="omfetrab _popup" :class="['w' + width, 'h' + height, { big }]">
|
||||
<div class="omfetrab" :class="['w' + width, 'h' + height, { big }]">
|
||||
<input ref="search" class="search" data-prevent-emoji-insert :class="{ filled: q != null && q != '' }" v-model.trim="q" :placeholder="$ts.search" @paste.stop="paste" @keyup.enter="done()">
|
||||
<div class="emojis" ref="emojis">
|
||||
<section class="result">
|
||||
@@ -346,7 +346,6 @@ export default defineComponent({
|
||||
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
contain: content;
|
||||
|
||||
&.big {
|
||||
--eachSize: 44px;
|
||||
|
||||
@@ -32,8 +32,8 @@
|
||||
margin: -8px calc(var(--formXPadding) * -1) 0 calc(var(--formXPadding) * -1);
|
||||
padding: 8px calc(var(--formContentHMargin) + var(--formXPadding)) 8px calc(var(--formContentHMargin) + var(--formXPadding));
|
||||
background: var(--X17);
|
||||
-webkit-backdrop-filter: blur(10px);
|
||||
backdrop-filter: blur(10px);
|
||||
-webkit-backdrop-filter: var(--blur, blur(10px));
|
||||
backdrop-filter: var(--blur, blur(10px));
|
||||
}
|
||||
|
||||
._themeChanging_ ._formLabel {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<MkModal ref="modal" @click="$emit('click')" @closed="$emit('closed')">
|
||||
<div class="hrmcaedk _popup _narrow_" :style="{ width: `${width}px`, height: (height ? `min(${height}px, 100%)` : '100%') }">
|
||||
<div class="hrmcaedk _window _narrow_" :style="{ width: `${width}px`, height: (height ? `min(${height}px, 100%)` : '100%') }">
|
||||
<div class="header" @contextmenu="onContextmenu">
|
||||
<span class="title">
|
||||
<XHeader :info="pageInfo" :back-button="history.length > 0" @back="back()" :close-button="true" @close="$refs.modal.close()"/>
|
||||
|
||||
@@ -454,7 +454,7 @@ export default defineComponent({
|
||||
renote(viaKeyboard = false) {
|
||||
pleaseLogin();
|
||||
this.blur();
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: this.$ts.renote,
|
||||
icon: 'fas fa-retweet',
|
||||
action: () => {
|
||||
@@ -743,14 +743,14 @@ export default defineComponent({
|
||||
},
|
||||
|
||||
menu(viaKeyboard = false) {
|
||||
os.modalMenu(this.getMenu(), this.$refs.menuButton, {
|
||||
os.popupMenu(this.getMenu(), this.$refs.menuButton, {
|
||||
viaKeyboard
|
||||
}).then(this.focus);
|
||||
},
|
||||
|
||||
showRenoteMenu(viaKeyboard = false) {
|
||||
if (!this.isMyRenote) return;
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: this.$ts.unrenote,
|
||||
icon: 'fas fa-trash-alt',
|
||||
danger: true,
|
||||
@@ -794,7 +794,7 @@ export default defineComponent({
|
||||
|
||||
async clip() {
|
||||
const clips = await os.api('clips/list');
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
icon: 'fas fa-plus',
|
||||
text: this.$ts.createNew,
|
||||
action: async () => {
|
||||
|
||||
@@ -429,7 +429,7 @@ export default defineComponent({
|
||||
renote(viaKeyboard = false) {
|
||||
pleaseLogin();
|
||||
this.blur();
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: this.$ts.renote,
|
||||
icon: 'fas fa-retweet',
|
||||
action: () => {
|
||||
@@ -718,14 +718,14 @@ export default defineComponent({
|
||||
},
|
||||
|
||||
menu(viaKeyboard = false) {
|
||||
os.modalMenu(this.getMenu(), this.$refs.menuButton, {
|
||||
os.popupMenu(this.getMenu(), this.$refs.menuButton, {
|
||||
viaKeyboard
|
||||
}).then(this.focus);
|
||||
},
|
||||
|
||||
showRenoteMenu(viaKeyboard = false) {
|
||||
if (!this.isMyRenote) return;
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: this.$ts.unrenote,
|
||||
icon: 'fas fa-trash-alt',
|
||||
danger: true,
|
||||
@@ -769,7 +769,7 @@ export default defineComponent({
|
||||
|
||||
async clip() {
|
||||
const clips = await os.api('clips/list');
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
icon: 'fas fa-plus',
|
||||
text: this.$ts.createNew,
|
||||
action: async () => {
|
||||
|
||||
@@ -5,8 +5,7 @@
|
||||
</p>
|
||||
<ul ref="choices">
|
||||
<li v-for="(choice, i) in choices" :key="i">
|
||||
<MkInput class="input" :model-value="choice" @update:modelValue="onInput(i, $event)">
|
||||
<template #label>{{ $t('_poll.choiceN', { n: i + 1 }) }}</template>
|
||||
<MkInput class="input" :model-value="choice" @update:modelValue="onInput(i, $event)" :placeholder="$t('_poll.choiceN', { n: i + 1 })">
|
||||
</MkInput>
|
||||
<button @click="remove(i)" class="_button">
|
||||
<i class="fas fa-times"></i>
|
||||
|
||||
@@ -112,7 +112,7 @@ export default defineComponent({
|
||||
|
||||
showFileMenu(file, ev: MouseEvent) {
|
||||
if (this.menu) return;
|
||||
this.menu = os.modalMenu([{
|
||||
this.menu = os.popupMenu([{
|
||||
text: this.$ts.renameFile,
|
||||
icon: 'fas fa-i-cursor',
|
||||
action: () => { this.rename(file) }
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
<button class="_button" @click="togglePoll" :class="{ active: poll }" v-tooltip="$ts.poll"><i class="fas fa-poll-h"></i></button>
|
||||
<button class="_button" @click="useCw = !useCw" :class="{ active: useCw }" v-tooltip="$ts.useCw"><i class="fas fa-eye-slash"></i></button>
|
||||
<button class="_button" @click="insertMention" v-tooltip="$ts.mention"><i class="fas fa-at"></i></button>
|
||||
<button class="_button" @click="withHashtags = !withHashtags" v-tooltip="$ts.hashtags"><i class="fas fa-hashtag"></i></button>
|
||||
<button class="_button" @click="withHashtags = !withHashtags" :class="{ active: withHashtags }" v-tooltip="$ts.hashtags"><i class="fas fa-hashtag"></i></button>
|
||||
<button class="_button" @click="insertEmoji" v-tooltip="$ts.emoji"><i class="fas fa-laugh-squint"></i></button>
|
||||
<button class="_button" @click="showActions" v-tooltip="$ts.plugin" v-if="postFormActions.length > 0"><i class="fas fa-plug"></i></button>
|
||||
</footer>
|
||||
@@ -641,7 +641,7 @@ export default defineComponent({
|
||||
viaMobile: isMobile
|
||||
};
|
||||
|
||||
if (this.withHashtags) {
|
||||
if (this.withHashtags && this.hashtags && this.hashtags.trim() !== '') {
|
||||
const hashtags = this.hashtags.trim().split(' ').map(x => x.startsWith('#') ? x : '#' + x).join(' ');
|
||||
data.text = data.text ? `${data.text} ${hashtags}` : hashtags;
|
||||
}
|
||||
@@ -690,7 +690,7 @@ export default defineComponent({
|
||||
},
|
||||
|
||||
showActions(ev) {
|
||||
os.modalMenu(postFormActions.map(action => ({
|
||||
os.popupMenu(postFormActions.map(action => ({
|
||||
text: action.title,
|
||||
action: () => {
|
||||
action.handler({
|
||||
|
||||
@@ -170,7 +170,7 @@ export default defineComponent({
|
||||
}
|
||||
|
||||
> span {
|
||||
color: #fff;
|
||||
color: var(--fgOnAccent);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -93,7 +93,7 @@ export default defineComponent({
|
||||
},
|
||||
|
||||
async openMenu(ev) {
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
type: 'label',
|
||||
text: 'Fruits'
|
||||
}, {
|
||||
|
||||
@@ -3,13 +3,11 @@
|
||||
<div class="auth _section">
|
||||
<div class="avatar" :style="{ backgroundImage: user ? `url('${ user.avatarUrl }')` : null }" v-show="withAvatar"></div>
|
||||
<div class="normal-signin" v-if="!totpLogin">
|
||||
<MkInput v-model="username" type="text" pattern="^[a-zA-Z0-9_]+$" spellcheck="false" autofocus required @update:modelValue="onUsernameChange">
|
||||
<template #label>{{ $ts.username }}</template>
|
||||
<MkInput v-model="username" :placeholder="$ts.username" type="text" pattern="^[a-zA-Z0-9_]+$" spellcheck="false" autofocus required @update:modelValue="onUsernameChange">
|
||||
<template #prefix>@</template>
|
||||
<template #suffix>@{{ host }}</template>
|
||||
</MkInput>
|
||||
<MkInput v-model="password" type="password" :with-password-toggle="true" v-if="!user || user && !user.usePasswordLessLogin" required>
|
||||
<template #label>{{ $ts.password }}</template>
|
||||
<MkInput v-model="password" :placeholder="$ts.password" type="password" :with-password-toggle="true" v-if="!user || user && !user.usePasswordLessLogin" required>
|
||||
<template #prefix><i class="fas fa-lock"></i></template>
|
||||
<template #caption><button class="_textButton" @click="resetPassword" type="button">{{ $ts.forgotPassword }}</button></template>
|
||||
</MkInput>
|
||||
|
||||
@@ -115,7 +115,7 @@ export default defineComponent({
|
||||
z-index: 1; // 他コンポーネントのbox-shadowに隠されないようにするため
|
||||
display: block;
|
||||
min-width: 100px;
|
||||
width: min-content;
|
||||
width: max-content;
|
||||
padding: 8px 14px;
|
||||
text-align: center;
|
||||
font-weight: normal;
|
||||
@@ -127,6 +127,7 @@ export default defineComponent({
|
||||
border-radius: 999px;
|
||||
overflow: hidden;
|
||||
box-sizing: border-box;
|
||||
transition: background 0.1s ease;
|
||||
|
||||
&:not(:disabled):hover {
|
||||
background: var(--buttonHoverBg);
|
||||
@@ -142,7 +143,7 @@ export default defineComponent({
|
||||
|
||||
&.primary {
|
||||
font-weight: bold;
|
||||
color: #fff !important;
|
||||
color: var(--fgOnAccent) !important;
|
||||
background: var(--accent);
|
||||
|
||||
&:not(:disabled):hover {
|
||||
@@ -176,17 +177,8 @@ export default defineComponent({
|
||||
}
|
||||
|
||||
&:focus {
|
||||
&:after {
|
||||
content: "";
|
||||
pointer-events: none;
|
||||
position: absolute;
|
||||
top: -5px;
|
||||
right: -5px;
|
||||
bottom: -5px;
|
||||
left: -5px;
|
||||
border: 2px solid var(--accentAlpha03);
|
||||
border-radius: 10px;
|
||||
}
|
||||
outline: solid 2px var(--focus);
|
||||
outline-offset: 2px;
|
||||
}
|
||||
|
||||
&.inline + .bghgjjyj {
|
||||
|
||||
@@ -102,8 +102,8 @@ export default defineComponent({
|
||||
background: var(--panel);
|
||||
/* TODO panelの半透明バージョンをプログラマティックに作りたい
|
||||
background: var(--X17);
|
||||
-webkit-backdrop-filter: blur(8px);
|
||||
backdrop-filter: blur(20px);
|
||||
-webkit-backdrop-filter: var(--blur, blur(8px));
|
||||
backdrop-filter: var(--blur, blur(20px));
|
||||
*/
|
||||
|
||||
> .title {
|
||||
|
||||
@@ -210,8 +210,7 @@ export default defineComponent({
|
||||
|
||||
> .label {
|
||||
font-size: 0.85em;
|
||||
padding: 0 0 6px 6px;
|
||||
font-weight: bold;
|
||||
padding: 0 0 8px 12px;
|
||||
user-select: none;
|
||||
|
||||
&:empty {
|
||||
@@ -221,7 +220,7 @@ export default defineComponent({
|
||||
|
||||
> .caption {
|
||||
font-size: 0.8em;
|
||||
padding: 6px 0 0 6px;
|
||||
padding: 8px 0 0 12px;
|
||||
color: var(--fgTransparentWeak);
|
||||
|
||||
&:empty {
|
||||
@@ -251,6 +250,7 @@ export default defineComponent({
|
||||
outline: none;
|
||||
box-shadow: none;
|
||||
box-sizing: border-box;
|
||||
transition: border-color 0.1s ease-out;
|
||||
|
||||
&:hover {
|
||||
border-color: var(--inputBorderHover);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<div class="rrevdjwt" :class="{ left: align === 'left' }"
|
||||
<div class="rrevdjwt" :class="{ left: align === 'left', pointer: point === 'top' }"
|
||||
ref="items"
|
||||
@contextmenu.self="e => e.preventDefault()"
|
||||
v-hotkey="keymap"
|
||||
@@ -58,7 +58,11 @@ export default defineComponent({
|
||||
align: {
|
||||
type: String,
|
||||
requried: false
|
||||
}
|
||||
},
|
||||
point: {
|
||||
type: String,
|
||||
requried: false
|
||||
},
|
||||
},
|
||||
emits: ['close'],
|
||||
data() {
|
||||
@@ -137,6 +141,22 @@ export default defineComponent({
|
||||
.rrevdjwt {
|
||||
padding: 8px 0;
|
||||
|
||||
&.pointer {
|
||||
&:before {
|
||||
--size: 8px;
|
||||
content: '';
|
||||
display: block;
|
||||
position: absolute;
|
||||
top: calc(0px - (var(--size) * 2));
|
||||
left: 0;
|
||||
right: 0;
|
||||
width: 0;
|
||||
margin: auto;
|
||||
border: solid var(--size) transparent;
|
||||
border-bottom-color: var(--popup);
|
||||
}
|
||||
}
|
||||
|
||||
&.left {
|
||||
> .item {
|
||||
text-align: left;
|
||||
@@ -171,13 +191,13 @@ export default defineComponent({
|
||||
}
|
||||
|
||||
&:hover {
|
||||
color: #fff;
|
||||
color: var(--fgOnAccent);
|
||||
background: var(--accent);
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
&:active {
|
||||
color: #fff;
|
||||
color: var(--fgOnAccent);
|
||||
background: var(--accentDarken);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<MkModal ref="modal" @click="$emit('click')" @closed="$emit('closed')">
|
||||
<div class="ebkgoccj _popup _narrow_" @keydown="onKeydown" :style="{ width: `${width}px`, height: scroll ? (height ? `${height}px` : null) : (height ? `min(${height}px, 100%)` : '100%') }">
|
||||
<div class="ebkgoccj _window _narrow_" @keydown="onKeydown" :style="{ width: `${width}px`, height: scroll ? (height ? `${height}px` : null) : (height ? `min(${height}px, 100%)` : '100%') }">
|
||||
<div class="header">
|
||||
<button class="_button" v-if="withOkButton" @click="$emit('close')"><i class="fas fa-times"></i></button>
|
||||
<span class="title">
|
||||
|
||||
@@ -1,19 +1,20 @@
|
||||
<template>
|
||||
<MkModal ref="modal" :src="src" @click="$refs.modal.close()" @closed="$emit('closed')">
|
||||
<MkMenu :items="items" :align="align" @close="$refs.modal.close()" class="_popup"/>
|
||||
</MkModal>
|
||||
<MkPopup ref="popup" :src="src" @closed="$emit('closed')" #default="{point}">
|
||||
<MkMenu :items="items" :align="align" :point="point" @close="$refs.popup.close()" class="_popup _shadow"/>
|
||||
</MkPopup>
|
||||
</template>
|
||||
|
||||
<script lang="ts">
|
||||
import { defineComponent } from 'vue';
|
||||
import MkModal from './modal.vue';
|
||||
import MkPopup from './popup.vue';
|
||||
import MkMenu from './menu.vue';
|
||||
|
||||
export default defineComponent({
|
||||
components: {
|
||||
MkModal,
|
||||
MkPopup,
|
||||
MkMenu,
|
||||
},
|
||||
|
||||
props: {
|
||||
items: {
|
||||
type: Array,
|
||||
@@ -31,17 +32,7 @@ export default defineComponent({
|
||||
required: false
|
||||
},
|
||||
},
|
||||
emits: ['closed'],
|
||||
computed: {
|
||||
keymap(): any {
|
||||
return {
|
||||
'esc': () => this.$refs.modal.close(),
|
||||
};
|
||||
},
|
||||
},
|
||||
|
||||
emits: ['close', 'closed'],
|
||||
});
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
|
||||
</style>
|
||||
216
src/client/components/ui/popup.vue
Normal file
216
src/client/components/ui/popup.vue
Normal file
@@ -0,0 +1,216 @@
|
||||
<template>
|
||||
<transition :name="$store.state.animation ? 'popup-menu' : ''" :duration="$store.state.animation ? 300 : 0" appear @after-leave="onClosed" @enter="$emit('opening')" @after-enter="childRendered">
|
||||
<div v-show="manualShowing != null ? manualShowing : showing" class="ccczpooj" :class="{ front, fixed, top: position === 'top' }" ref="content" :style="{ pointerEvents: (manualShowing != null ? manualShowing : showing) ? 'auto' : 'none', '--transformOrigin': transformOrigin }">
|
||||
<slot :point="point"></slot>
|
||||
</div>
|
||||
</transition>
|
||||
</template>
|
||||
|
||||
<script lang="ts">
|
||||
import { defineComponent, PropType } from 'vue';
|
||||
|
||||
function getFixedContainer(el: Element | null): Element | null {
|
||||
if (el == null || el.tagName === 'BODY') return null;
|
||||
const position = window.getComputedStyle(el).getPropertyValue('position');
|
||||
if (position === 'fixed') {
|
||||
return el;
|
||||
} else {
|
||||
return getFixedContainer(el.parentElement);
|
||||
}
|
||||
}
|
||||
|
||||
export default defineComponent({
|
||||
props: {
|
||||
manualShowing: {
|
||||
type: Boolean,
|
||||
required: false,
|
||||
default: null,
|
||||
},
|
||||
srcCenter: {
|
||||
type: Boolean,
|
||||
required: false
|
||||
},
|
||||
src: {
|
||||
type: Object as PropType<HTMLElement>,
|
||||
required: false,
|
||||
},
|
||||
position: {
|
||||
required: false
|
||||
},
|
||||
front: {
|
||||
type: Boolean,
|
||||
required: false,
|
||||
default: false,
|
||||
}
|
||||
},
|
||||
|
||||
emits: ['opening', 'click', 'esc', 'close', 'closed'],
|
||||
|
||||
data() {
|
||||
return {
|
||||
showing: true,
|
||||
fixed: false,
|
||||
transformOrigin: 'center',
|
||||
contentClicking: false,
|
||||
point: null,
|
||||
};
|
||||
},
|
||||
|
||||
mounted() {
|
||||
this.$watch('src', () => {
|
||||
if (this.src) {
|
||||
this.src.style.pointerEvents = 'none';
|
||||
}
|
||||
this.fixed = getFixedContainer(this.src) != null;
|
||||
this.$nextTick(() => {
|
||||
this.align();
|
||||
});
|
||||
}, { immediate: true });
|
||||
|
||||
this.$nextTick(() => {
|
||||
const popover = this.$refs.content as any;
|
||||
new ResizeObserver((entries, observer) => {
|
||||
this.align();
|
||||
}).observe(popover);
|
||||
});
|
||||
|
||||
document.addEventListener('mousedown', this.onDocumentClick, { passive: true });
|
||||
},
|
||||
|
||||
beforeUnmount() {
|
||||
document.removeEventListener('mousedown', this.onDocumentClick);
|
||||
},
|
||||
|
||||
methods: {
|
||||
align() {
|
||||
if (this.src == null) return;
|
||||
|
||||
const popover = this.$refs.content as any;
|
||||
|
||||
if (popover == null) return;
|
||||
|
||||
const rect = this.src.getBoundingClientRect();
|
||||
|
||||
const width = popover.offsetWidth;
|
||||
const height = popover.offsetHeight;
|
||||
|
||||
let left;
|
||||
let top;
|
||||
|
||||
if (this.srcCenter) {
|
||||
const x = rect.left + (this.fixed ? 0 : window.pageXOffset) + (this.src.offsetWidth / 2);
|
||||
const y = rect.top + (this.fixed ? 0 : window.pageYOffset) + (this.src.offsetHeight / 2);
|
||||
left = (x - (width / 2));
|
||||
top = (y - (height / 2));
|
||||
} else {
|
||||
const x = rect.left + (this.fixed ? 0 : window.pageXOffset) + (this.src.offsetWidth / 2);
|
||||
const y = rect.top + (this.fixed ? 0 : window.pageYOffset) + this.src.offsetHeight;
|
||||
left = (x - (width / 2));
|
||||
top = y;
|
||||
}
|
||||
|
||||
if (this.fixed) {
|
||||
if (left + width > window.innerWidth) {
|
||||
left = window.innerWidth - width;
|
||||
}
|
||||
|
||||
if (top + height > window.innerHeight) {
|
||||
top = window.innerHeight - height;
|
||||
}
|
||||
} else {
|
||||
if (left + width - window.pageXOffset > window.innerWidth) {
|
||||
left = window.innerWidth - width + window.pageXOffset - 1;
|
||||
}
|
||||
|
||||
if (top + height - window.pageYOffset > window.innerHeight) {
|
||||
top = window.innerHeight - height + window.pageYOffset - 1;
|
||||
}
|
||||
}
|
||||
|
||||
if (top < 0) {
|
||||
top = 0;
|
||||
}
|
||||
|
||||
if (left < 0) {
|
||||
left = 0;
|
||||
}
|
||||
|
||||
if (top > rect.top + (this.fixed ? 0 : window.pageYOffset)) {
|
||||
this.point = 'top';
|
||||
this.transformOrigin = 'center top';
|
||||
} else {
|
||||
this.point = null;
|
||||
this.transformOrigin = 'center';
|
||||
}
|
||||
|
||||
popover.style.left = left + 'px';
|
||||
popover.style.top = top + 'px';
|
||||
},
|
||||
|
||||
childRendered() {
|
||||
// モーダルコンテンツにマウスボタンが押され、コンテンツ外でマウスボタンが離されたときにモーダルバックグラウンドクリックと判定させないためにマウスイベントを監視しフラグ管理する
|
||||
const content = this.$refs.content.children[0];
|
||||
content.addEventListener('mousedown', e => {
|
||||
this.contentClicking = true;
|
||||
window.addEventListener('mouseup', e => {
|
||||
// click イベントより先に mouseup イベントが発生するかもしれないのでちょっと待つ
|
||||
setTimeout(() => {
|
||||
this.contentClicking = false;
|
||||
}, 100);
|
||||
}, { passive: true, once: true });
|
||||
}, { passive: true });
|
||||
},
|
||||
|
||||
close() {
|
||||
if (this.src) this.src.style.pointerEvents = 'auto';
|
||||
this.showing = false;
|
||||
this.$emit('close');
|
||||
},
|
||||
|
||||
onClosed() {
|
||||
this.$emit('closed');
|
||||
},
|
||||
|
||||
onDocumentClick(ev) {
|
||||
const flyoutElement = this.$refs.content;
|
||||
let targetElement = ev.target;
|
||||
do {
|
||||
if (targetElement === flyoutElement) {
|
||||
return;
|
||||
}
|
||||
targetElement = targetElement.parentNode;
|
||||
} while (targetElement);
|
||||
this.close();
|
||||
}
|
||||
}
|
||||
});
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.popup-menu-enter-active {
|
||||
transform-origin: var(--transformOrigin);
|
||||
transition: opacity 0.2s cubic-bezier(0, 0, 0.2, 1), transform 0.2s cubic-bezier(0, 0, 0.2, 1) !important;
|
||||
}
|
||||
.popup-menu-leave-active {
|
||||
transform-origin: var(--transformOrigin);
|
||||
transition: opacity 0.2s cubic-bezier(0.4, 0, 1, 1), transform 0.2s cubic-bezier(0.4, 0, 1, 1) !important;
|
||||
}
|
||||
.popup-menu-enter-from, .popup-menu-leave-to {
|
||||
pointer-events: none;
|
||||
opacity: 0;
|
||||
transform: scale(0.9);
|
||||
}
|
||||
|
||||
.ccczpooj {
|
||||
position: absolute;
|
||||
z-index: 10000;
|
||||
|
||||
&.fixed {
|
||||
position: fixed;
|
||||
}
|
||||
|
||||
&.front {
|
||||
z-index: 20000;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -155,8 +155,7 @@ export default defineComponent({
|
||||
|
||||
> .label {
|
||||
font-size: 0.85em;
|
||||
padding: 0 0 6px 6px;
|
||||
font-weight: bold;
|
||||
padding: 0 0 8px 12px;
|
||||
user-select: none;
|
||||
|
||||
&:empty {
|
||||
@@ -166,7 +165,7 @@ export default defineComponent({
|
||||
|
||||
> .caption {
|
||||
font-size: 0.8em;
|
||||
padding: 6px 0 0 6px;
|
||||
padding: 8px 0 0 12px;
|
||||
color: var(--fgTransparentWeak);
|
||||
|
||||
&:empty {
|
||||
@@ -197,6 +196,7 @@ export default defineComponent({
|
||||
box-shadow: none;
|
||||
box-sizing: border-box;
|
||||
cursor: pointer;
|
||||
transition: border-color 0.1s ease-out;
|
||||
|
||||
&:hover {
|
||||
border-color: var(--inputBorderHover);
|
||||
|
||||
@@ -176,8 +176,7 @@ export default defineComponent({
|
||||
|
||||
> .label {
|
||||
font-size: 0.85em;
|
||||
padding: 0 0 6px 6px;
|
||||
font-weight: bold;
|
||||
padding: 0 0 8px 12px;
|
||||
user-select: none;
|
||||
|
||||
&:empty {
|
||||
@@ -187,7 +186,7 @@ export default defineComponent({
|
||||
|
||||
> .caption {
|
||||
font-size: 0.8em;
|
||||
padding: 6px 0 0 6px;
|
||||
padding: 8px 0 0 12px;
|
||||
color: var(--fgTransparentWeak);
|
||||
|
||||
&:empty {
|
||||
@@ -218,6 +217,7 @@ export default defineComponent({
|
||||
outline: none;
|
||||
box-shadow: none;
|
||||
box-sizing: border-box;
|
||||
transition: border-color 0.1s ease-out;
|
||||
|
||||
&:hover {
|
||||
border-color: var(--inputBorderHover);
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<transition :name="$store.state.animation ? 'window' : ''" appear @after-leave="$emit('closed')">
|
||||
<div class="ebkgocck" :class="{ front }" v-if="showing">
|
||||
<div class="body _popup _shadow _narrow_" @mousedown="onBodyMousedown" @keydown="onKeydown">
|
||||
<div class="body _window _shadow _narrow_" @mousedown="onBodyMousedown" @keydown="onKeydown">
|
||||
<div class="header" :class="{ mini }" @contextmenu.prevent.stop="onContextmenu">
|
||||
<button v-if="closeButton" class="_button" @click="close()"><i class="fas fa-times"></i></button>
|
||||
|
||||
@@ -416,6 +416,7 @@ export default defineComponent({
|
||||
flex-shrink: 0;
|
||||
user-select: none;
|
||||
height: var(--height);
|
||||
border-bottom: solid 1px var(--divider);
|
||||
|
||||
> ::v-deep(button) {
|
||||
height: var(--height);
|
||||
|
||||
@@ -18,12 +18,12 @@
|
||||
<div class="customize-container">
|
||||
<button class="config _button" @click.prevent.stop="configWidget(element.id)"><i class="fas fa-cog"></i></button>
|
||||
<button class="remove _button" @click.prevent.stop="removeWidget(element)"><i class="fas fa-times"></i></button>
|
||||
<component :is="`mkw-${element.name}`" :widget="element" :setting-callback="setting => settings[element.id] = setting" :column="column" @updateProps="updateWidget(element.id, $event)"/>
|
||||
<component :is="`mkw-${element.name}`" :widget="element" :setting-callback="setting => settings[element.id] = setting" @updateProps="updateWidget(element.id, $event)"/>
|
||||
</div>
|
||||
</template>
|
||||
</XDraggable>
|
||||
</template>
|
||||
<component v-else class="widget" v-for="widget in widgets" :is="`mkw-${widget.name}`" :key="widget.id" :widget="widget" :column="column" @updateProps="updateWidget(widget.id, $event)"/>
|
||||
<component v-else class="widget" v-for="widget in widgets" :is="`mkw-${widget.name}`" :key="widget.id" :widget="widget" @updateProps="updateWidget(widget.id, $event)"/>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -272,6 +272,14 @@ watch(defaultStore.reactiveState.useBlurEffectForModal, v => {
|
||||
document.documentElement.style.setProperty('--modalBgFilter', v ? 'blur(4px)' : 'none');
|
||||
}, { immediate: true });
|
||||
|
||||
watch(defaultStore.reactiveState.useBlurEffect, v => {
|
||||
if (v) {
|
||||
document.documentElement.style.removeProperty('--blur');
|
||||
} else {
|
||||
document.documentElement.style.setProperty('--blur', 'none');
|
||||
}
|
||||
}, { immediate: true });
|
||||
|
||||
let reloadDialogShowing = false;
|
||||
stream.on('_disconnected_', async () => {
|
||||
if (defaultStore.state.serverDisconnectedBehavior === 'reload') {
|
||||
|
||||
@@ -143,7 +143,7 @@ export const menuDef = {
|
||||
title: 'switchUi',
|
||||
icon: 'fas fa-columns',
|
||||
action: (ev) => {
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: i18n.locale.default,
|
||||
action: () => {
|
||||
localStorage.setItem('ui', 'default');
|
||||
|
||||
@@ -368,10 +368,10 @@ export async function openEmojiPicker(src?: HTMLElement, opts, initialTextarea:
|
||||
});
|
||||
}
|
||||
|
||||
export function modalMenu(items: any[], src?: HTMLElement, options?: { align?: string; viaKeyboard?: boolean }) {
|
||||
export function popupMenu(items: any[], src?: HTMLElement, options?: { align?: string; viaKeyboard?: boolean }) {
|
||||
return new Promise((resolve, reject) => {
|
||||
let dispose;
|
||||
popup(import('@client/components/ui/modal-menu.vue'), {
|
||||
popup(import('@client/components/ui/popup-menu.vue'), {
|
||||
items,
|
||||
src,
|
||||
align: options?.align,
|
||||
|
||||
@@ -68,40 +68,58 @@ import * as symbols from '@client/symbols';
|
||||
const patrons = [
|
||||
'Satsuki Yanagi',
|
||||
'noellabo',
|
||||
'Gargron',
|
||||
'Atsuko Tominaga',
|
||||
'mametsuko',
|
||||
'AureoleArk',
|
||||
'Gargron',
|
||||
'Nokotaro Takeda',
|
||||
'Suji Yan',
|
||||
'Hekovic',
|
||||
'Gitmo Life Services',
|
||||
'nenohi',
|
||||
'naga_rus',
|
||||
'Melilot',
|
||||
'Hekovic',
|
||||
'Nokotaro Takeda',
|
||||
'dansup',
|
||||
'nenohi',
|
||||
'motcha',
|
||||
'nanami kan',
|
||||
'Eduardo Quiros',
|
||||
'Peter G.',
|
||||
'YUKIMOCHI',
|
||||
'Efertone',
|
||||
'makokunsan',
|
||||
'oi_yekssim',
|
||||
'nanami kan',
|
||||
'motcha',
|
||||
'dansup',
|
||||
'Quinton Macejkovic',
|
||||
'YUKIMOCHI',
|
||||
'mewl hayabusa',
|
||||
'makokunsan',
|
||||
'Peter G.',
|
||||
'Nesakko',
|
||||
'regtan',
|
||||
'見当かなみ',
|
||||
'natalie',
|
||||
'Jerry',
|
||||
'takimura',
|
||||
'sikyosyounin',
|
||||
'weepjp',
|
||||
'mydarkstar',
|
||||
'Nesakko',
|
||||
'YuzuRyo61',
|
||||
'sheeta.s',
|
||||
'osapon',
|
||||
'YuzuRyo61',
|
||||
'wara',
|
||||
'mkatze',
|
||||
'kiritan',
|
||||
'CG',
|
||||
'nafuchoco',
|
||||
'Takumi Sugita',
|
||||
'chidori ninokura',
|
||||
'mydarkstar',
|
||||
'kiritan',
|
||||
'kabo2468y',
|
||||
'weepjp',
|
||||
'Liaizon Wakest',
|
||||
'Steffen K9',
|
||||
'Roujo',
|
||||
'uroco @99',
|
||||
'totokoro',
|
||||
'public_yusuke',
|
||||
'wara',
|
||||
'S Y',
|
||||
'Denshi',
|
||||
'Osushimaru',
|
||||
'Liaizon Wakest',
|
||||
'吴浥',
|
||||
'DignifiedSilence',
|
||||
't_w',
|
||||
];
|
||||
|
||||
export default defineComponent({
|
||||
|
||||
@@ -272,7 +272,7 @@ export default defineComponent({
|
||||
|
||||
showTypeMenu(e: MouseEvent) {
|
||||
return new Promise<ThemeValue>((resolve) => {
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: this.$ts._theme.defaultValue,
|
||||
action: () => resolve(null),
|
||||
}, {
|
||||
|
||||
@@ -152,8 +152,8 @@ export default defineComponent({
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
-webkit-backdrop-filter: blur(16px);
|
||||
backdrop-filter: blur(16px);
|
||||
-webkit-backdrop-filter: var(--blur, blur(16px));
|
||||
backdrop-filter: var(--blur, blur(16px));
|
||||
background: rgba(0, 0, 0, 0.3);
|
||||
}
|
||||
|
||||
|
||||
@@ -79,7 +79,7 @@ export default defineComponent({
|
||||
|
||||
methods: {
|
||||
menu(ev) {
|
||||
os.modalMenu([this.isOwned ? {
|
||||
os.popupMenu([this.isOwned ? {
|
||||
icon: 'fas fa-pencil-alt',
|
||||
text: this.$ts.edit,
|
||||
action: async () => {
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
<div class="body" v-html="body"></div>
|
||||
<div class="footer">
|
||||
<MkLink :url="`https://github.com/misskey-dev/misskey/blob/master/src/docs/${lang}/${doc}.md`" class="at">{{ $ts.docSource }}</MkLink>
|
||||
<p v-if="lang !== 'ja-JP'">{{ $ts.translateWarn }}</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -115,7 +116,7 @@ export default defineComponent({
|
||||
line-height: 1.5;
|
||||
|
||||
&.max-width_500px {
|
||||
padding: 16px;
|
||||
padding: 24px;
|
||||
}
|
||||
|
||||
> .main {
|
||||
|
||||
@@ -80,7 +80,7 @@ export default defineComponent({
|
||||
|
||||
methods: {
|
||||
menu(emoji, ev) {
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
type: 'label',
|
||||
text: ':' + emoji.name + ':',
|
||||
}, {
|
||||
|
||||
@@ -228,6 +228,7 @@ export default defineComponent({
|
||||
> .footer {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
font-size: 0.9em;
|
||||
|
||||
> .status {
|
||||
&.suspended {
|
||||
@@ -249,7 +250,6 @@ export default defineComponent({
|
||||
|
||||
> .right {
|
||||
margin-left: auto;
|
||||
font-size: 0.9em;
|
||||
|
||||
> .latestStatus {
|
||||
border: solid 1px var(--divider);
|
||||
|
||||
@@ -14,6 +14,8 @@
|
||||
</FormKeyValueView>
|
||||
</FormGroup>
|
||||
|
||||
<FormButton v-if="$i.isAdmin || $i.isModerator" @click="info" primary>{{ $ts.settings }}</FormButton>
|
||||
|
||||
<FormTextarea readonly :value="instance.description">
|
||||
<span>{{ $ts.description }}</span>
|
||||
</FormTextarea>
|
||||
@@ -147,6 +149,7 @@ import * as os from '@client/os';
|
||||
import number from '@client/filters/number';
|
||||
import bytes from '@client/filters/bytes';
|
||||
import * as symbols from '@client/symbols';
|
||||
import MkInstanceInfo from '@client/pages/instance/instance.vue';
|
||||
|
||||
const chartLimit = 90;
|
||||
const sum = (...arr) => arr.reduce((r, a) => r.map((b, i) => a[i] + b));
|
||||
@@ -440,6 +443,12 @@ export default defineComponent({
|
||||
}]
|
||||
};
|
||||
},
|
||||
|
||||
info() {
|
||||
os.popup(MkInstanceInfo, {
|
||||
instance: this.instance
|
||||
}, {}, 'closed');
|
||||
}
|
||||
}
|
||||
});
|
||||
</script>
|
||||
|
||||
@@ -146,7 +146,7 @@ export default defineComponent({
|
||||
},
|
||||
|
||||
remoteMenu(emoji, ev) {
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
type: 'label',
|
||||
text: ':' + emoji.name + ':',
|
||||
}, {
|
||||
|
||||
@@ -167,7 +167,7 @@ export default defineComponent({
|
||||
};
|
||||
|
||||
const lookup = (ev) => {
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: i18n.locale.user,
|
||||
icon: 'fas fa-user',
|
||||
action: () => {
|
||||
|
||||
@@ -116,7 +116,7 @@ export default defineComponent({
|
||||
},
|
||||
|
||||
start(ev) {
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: this.$ts.messagingWithUser,
|
||||
icon: 'fas fa-user',
|
||||
action: () => { this.startUser() }
|
||||
|
||||
@@ -320,7 +320,7 @@ const Component = defineComponent({
|
||||
menu(ev) {
|
||||
const path = this.groupId ? `/my/messaging/group/${this.groupId}` : `/my/messaging/${this.userAcct}`;
|
||||
|
||||
os.modalMenu([this.inWindow ? undefined : {
|
||||
os.popupMenu([this.inWindow ? undefined : {
|
||||
text: this.$ts.openInWindow,
|
||||
icon: 'fas fa-window-maximize',
|
||||
action: () => {
|
||||
|
||||
@@ -333,8 +333,8 @@ export default defineComponent({
|
||||
top: var(--stickyTop, 0px);
|
||||
padding: 16px;
|
||||
font-weight: bold;
|
||||
-webkit-backdrop-filter: blur(10px);
|
||||
backdrop-filter: blur(10px);
|
||||
-webkit-backdrop-filter: var(--blur, blur(10px));
|
||||
backdrop-filter: var(--blur, blur(10px));
|
||||
background-color: var(--X16);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,11 +1,12 @@
|
||||
<template>
|
||||
<div class="qkcjvfiv _section">
|
||||
<div class="qkcjvfiv">
|
||||
<MkButton @click="create" primary class="add"><i class="fas fa-plus"></i> {{ $ts.createList }}</MkButton>
|
||||
|
||||
<MkPagination :pagination="pagination" #default="{items}" class="lists _content" ref="list">
|
||||
<div class="list _panel" v-for="(list, i) in items" :key="list.id">
|
||||
<MkA :to="`/my/lists/${ list.id }`">{{ list.name }}</MkA>
|
||||
</div>
|
||||
<MkA v-for="list in items" :key="list.id" class="list _panel" :to="`/my/lists/${ list.id }`">
|
||||
<div class="name">{{ list.name }}</div>
|
||||
<MkAvatars :user-ids="list.userIds"/>
|
||||
</MkA>
|
||||
</MkPagination>
|
||||
</div>
|
||||
</template>
|
||||
@@ -14,6 +15,7 @@
|
||||
import { defineComponent } from 'vue';
|
||||
import MkPagination from '@client/components/ui/pagination.vue';
|
||||
import MkButton from '@client/components/ui/button.vue';
|
||||
import MkAvatars from '@client/components/avatars.vue';
|
||||
import * as os from '@client/os';
|
||||
import * as symbols from '@client/symbols';
|
||||
|
||||
@@ -21,6 +23,7 @@ export default defineComponent({
|
||||
components: {
|
||||
MkPagination,
|
||||
MkButton,
|
||||
MkAvatars,
|
||||
},
|
||||
|
||||
data() {
|
||||
@@ -57,14 +60,27 @@ export default defineComponent({
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.qkcjvfiv {
|
||||
padding: 16px;
|
||||
|
||||
> .add {
|
||||
margin: 0 auto var(--margin) auto;
|
||||
}
|
||||
|
||||
> .lists {
|
||||
> .list {
|
||||
display: flex;
|
||||
display: block;
|
||||
padding: 16px;
|
||||
border: solid 1px var(--divider);
|
||||
border-radius: 6px;
|
||||
|
||||
&:hover {
|
||||
border: solid 1px var(--accent);
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
> .name {
|
||||
margin-bottom: 4px;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -64,7 +64,7 @@ export default defineComponent({
|
||||
|
||||
methods: {
|
||||
menu(account, ev) {
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: this.$ts.switch,
|
||||
icon: 'fas fa-exchange-alt',
|
||||
action: () => this.switchAccount(account),
|
||||
@@ -77,7 +77,7 @@ export default defineComponent({
|
||||
},
|
||||
|
||||
addAccount(ev) {
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: this.$ts.existingAccount,
|
||||
action: () => { this.addExistingAccount(); },
|
||||
}, {
|
||||
|
||||
@@ -33,6 +33,7 @@
|
||||
<template #label>{{ $ts.appearance }}</template>
|
||||
<FormSwitch v-model:value="disableAnimatedMfm">{{ $ts.disableAnimatedMfm }}</FormSwitch>
|
||||
<FormSwitch v-model:value="reduceAnimation">{{ $ts.reduceUiAnimation }}</FormSwitch>
|
||||
<FormSwitch v-model:value="useBlurEffect">{{ $ts.useBlurEffect }}</FormSwitch>
|
||||
<FormSwitch v-model:value="useBlurEffectForModal">{{ $ts.useBlurEffectForModal }}</FormSwitch>
|
||||
<FormSwitch v-model:value="showGapBetweenNotesInTimeline">{{ $ts.showGapBetweenNotesInTimeline }}</FormSwitch>
|
||||
<FormSwitch v-model:value="loadRawImages">{{ $ts.loadRawImages }}</FormSwitch>
|
||||
@@ -132,6 +133,7 @@ export default defineComponent({
|
||||
serverDisconnectedBehavior: defaultStore.makeGetterSetter('serverDisconnectedBehavior'),
|
||||
reduceAnimation: defaultStore.makeGetterSetter('animation', v => !v, v => !v),
|
||||
useBlurEffectForModal: defaultStore.makeGetterSetter('useBlurEffectForModal'),
|
||||
useBlurEffect: defaultStore.makeGetterSetter('useBlurEffect'),
|
||||
showGapBetweenNotesInTimeline: defaultStore.makeGetterSetter('showGapBetweenNotesInTimeline'),
|
||||
disableAnimatedMfm: defaultStore.makeGetterSetter('animatedMfm', v => !v, v => !v),
|
||||
useOsNativeEmojis: defaultStore.makeGetterSetter('useOsNativeEmojis'),
|
||||
|
||||
@@ -94,7 +94,7 @@ export default defineComponent({
|
||||
},
|
||||
|
||||
remove(reaction, ev) {
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: this.$ts.remove,
|
||||
action: () => {
|
||||
this.reactions = this.reactions.filter(x => x !== reaction)
|
||||
|
||||
@@ -147,7 +147,7 @@ export default defineComponent({
|
||||
this.saveSrc();
|
||||
}
|
||||
}));
|
||||
os.modalMenu(items, ev.currentTarget || ev.target);
|
||||
os.popupMenu(items, ev.currentTarget || ev.target);
|
||||
},
|
||||
|
||||
async chooseAntenna(ev) {
|
||||
@@ -161,7 +161,7 @@ export default defineComponent({
|
||||
this.saveSrc();
|
||||
}
|
||||
}));
|
||||
os.modalMenu(items, ev.currentTarget || ev.target);
|
||||
os.popupMenu(items, ev.currentTarget || ev.target);
|
||||
},
|
||||
|
||||
async chooseChannel(ev) {
|
||||
@@ -177,7 +177,7 @@ export default defineComponent({
|
||||
this.$router.push(`/channels/${channel.id}`);
|
||||
}
|
||||
}));
|
||||
os.modalMenu(items, ev.currentTarget || ev.target);
|
||||
os.popupMenu(items, ev.currentTarget || ev.target);
|
||||
},
|
||||
|
||||
saveSrc() {
|
||||
|
||||
@@ -338,7 +338,7 @@ export default defineComponent({
|
||||
},
|
||||
|
||||
menu(ev) {
|
||||
os.modalMenu(getUserMenu(this.user), ev.currentTarget || ev.target);
|
||||
os.popupMenu(getUserMenu(this.user), ev.currentTarget || ev.target);
|
||||
},
|
||||
|
||||
parallaxLoop() {
|
||||
@@ -613,8 +613,8 @@ export default defineComponent({
|
||||
position: absolute;
|
||||
top: 12px;
|
||||
right: 12px;
|
||||
-webkit-backdrop-filter: blur(8px);
|
||||
backdrop-filter: blur(8px);
|
||||
-webkit-backdrop-filter: var(--blur, blur(8px));
|
||||
backdrop-filter: var(--blur, blur(8px));
|
||||
background: rgba(0, 0, 0, 0.2);
|
||||
padding: 8px;
|
||||
border-radius: 24px;
|
||||
|
||||
@@ -117,7 +117,7 @@ export default defineComponent({
|
||||
},
|
||||
|
||||
showMenu(ev) {
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: this.$t('aboutX', { x: instanceName }),
|
||||
icon: 'fas fa-info-circle',
|
||||
action: () => {
|
||||
@@ -260,6 +260,7 @@ export default defineComponent({
|
||||
display: block;
|
||||
margin: 0;
|
||||
padding: 32px 32px 24px 32px;
|
||||
font-size: 1.5em;
|
||||
|
||||
> .logo {
|
||||
vertical-align: bottom;
|
||||
|
||||
@@ -101,7 +101,7 @@ export default defineComponent({
|
||||
},
|
||||
|
||||
showMenu(ev) {
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: this.$t('aboutX', { x: instanceName }),
|
||||
icon: 'fas fa-info-circle',
|
||||
action: () => {
|
||||
|
||||
@@ -121,7 +121,7 @@ export default defineComponent({
|
||||
},
|
||||
|
||||
showMenu(ev) {
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: this.$t('aboutX', { x: instanceName }),
|
||||
icon: 'fas fa-info-circle',
|
||||
action: () => {
|
||||
|
||||
@@ -201,7 +201,11 @@ export default (opts) => ({
|
||||
if (isBottom) {
|
||||
// オーバーフローしたら古いアイテムは捨てる
|
||||
if (this.items.length >= opts.displayLimit) {
|
||||
this.items = this.items.slice(-opts.displayLimit);
|
||||
// このやり方だとVue 3.2以降アニメーションが動かなくなる
|
||||
//this.items = this.items.slice(-opts.displayLimit);
|
||||
while (this.items.length >= opts.displayLimit) {
|
||||
this.items.shift();
|
||||
}
|
||||
this.more = true;
|
||||
}
|
||||
}
|
||||
@@ -216,7 +220,11 @@ export default (opts) => ({
|
||||
|
||||
// オーバーフローしたら古いアイテムは捨てる
|
||||
if (this.items.length >= opts.displayLimit) {
|
||||
this.items = this.items.slice(0, opts.displayLimit);
|
||||
// このやり方だとVue 3.2以降アニメーションが動かなくなる
|
||||
//this.items = this.items.slice(0, opts.displayLimit);
|
||||
while (this.items.length >= opts.displayLimit) {
|
||||
this.items.pop();
|
||||
}
|
||||
this.more = true;
|
||||
}
|
||||
} else {
|
||||
|
||||
@@ -69,7 +69,7 @@ export function selectFile(src: any, label: string | null, multiple = false) {
|
||||
});
|
||||
};
|
||||
|
||||
os.modalMenu([label ? {
|
||||
os.popupMenu([label ? {
|
||||
text: label,
|
||||
type: 'label'
|
||||
} : undefined, {
|
||||
|
||||
@@ -23,6 +23,7 @@ export const builtinThemes = [
|
||||
require('@client/themes/d-dark.json5'),
|
||||
require('@client/themes/d-persimmon.json5'),
|
||||
require('@client/themes/d-astro.json5'),
|
||||
require('@client/themes/d-future.json5'),
|
||||
require('@client/themes/d-black.json5'),
|
||||
] as Theme[];
|
||||
|
||||
|
||||
@@ -142,6 +142,10 @@ export const defaultStore = markRaw(new Storage('base', {
|
||||
where: 'device',
|
||||
default: true
|
||||
},
|
||||
useBlurEffect: {
|
||||
where: 'device',
|
||||
default: false
|
||||
},
|
||||
showFixedPostForm: {
|
||||
where: 'device',
|
||||
default: false
|
||||
|
||||
@@ -189,7 +189,7 @@ hr {
|
||||
|
||||
._buttonPrimary {
|
||||
@extend ._button;
|
||||
color: #fff;
|
||||
color: var(--fgOnAccent);
|
||||
background: var(--accent);
|
||||
|
||||
&:not(:disabled):hover {
|
||||
@@ -318,12 +318,18 @@ hr {
|
||||
}
|
||||
}
|
||||
|
||||
._popup {
|
||||
._window {
|
||||
background: var(--panel);
|
||||
border-radius: var(--radius);
|
||||
contain: content;
|
||||
}
|
||||
|
||||
._popup {
|
||||
background: var(--popup);
|
||||
border-radius: var(--radius);
|
||||
contain: layout; // ふき出しがボックスから飛び出て表示されるようなデザインをする場合もあるので paint は contain することができない
|
||||
}
|
||||
|
||||
._root {
|
||||
box-sizing: border-box;
|
||||
margin: var(--root-margin, 32px) auto;
|
||||
@@ -398,8 +404,8 @@ hr {
|
||||
|
||||
._acrylic {
|
||||
background: var(--acrylicPanel);
|
||||
-webkit-backdrop-filter: blur(15px);
|
||||
backdrop-filter: blur(15px);
|
||||
-webkit-backdrop-filter: var(--blur, blur(15px));
|
||||
backdrop-filter: var(--blur, blur(15px));
|
||||
}
|
||||
|
||||
._inputSplit {
|
||||
|
||||
@@ -19,6 +19,7 @@
|
||||
fgTransparentWeak: ':alpha<0.75<@fg',
|
||||
fgTransparent: ':alpha<0.5<@fg',
|
||||
fgHighlighted: ':lighten<3<@fg',
|
||||
fgOnAccent: '#fff',
|
||||
divider: 'rgba(255, 255, 255, 0.1)',
|
||||
indicator: '@accent',
|
||||
panel: ':lighten<3<@bg',
|
||||
@@ -28,6 +29,7 @@
|
||||
panelHeaderDivider: 'rgba(0, 0, 0, 0)',
|
||||
panelBorder: '" solid 1px var(--divider)',
|
||||
acrylicPanel: ':alpha<0.5<@panel',
|
||||
popup: ':lighten<3<@panel',
|
||||
shadow: 'rgba(0, 0, 0, 0.3)',
|
||||
header: ':alpha<0.7<@panel',
|
||||
navBg: '@panel',
|
||||
|
||||
@@ -19,6 +19,7 @@
|
||||
fgTransparentWeak: ':alpha<0.75<@fg',
|
||||
fgTransparent: ':alpha<0.5<@fg',
|
||||
fgHighlighted: ':darken<3<@fg',
|
||||
fgOnAccent: '#fff',
|
||||
divider: 'rgba(0, 0, 0, 0.1)',
|
||||
indicator: '@accent',
|
||||
panel: ':lighten<3<@bg',
|
||||
@@ -28,6 +29,7 @@
|
||||
panelHeaderDivider: 'rgba(0, 0, 0, 0)',
|
||||
panelBorder: '" solid 1px var(--divider)',
|
||||
acrylicPanel: ':alpha<0.5<@panel',
|
||||
popup: ':lighten<3<@panel',
|
||||
shadow: 'rgba(0, 0, 0, 0.1)',
|
||||
header: ':alpha<0.7<@panel',
|
||||
navBg: '@panel',
|
||||
|
||||
25
src/client/themes/d-future.json5
Normal file
25
src/client/themes/d-future.json5
Normal file
@@ -0,0 +1,25 @@
|
||||
{
|
||||
id: '32a637ef-b47a-4775-bb7b-bacbb823f865',
|
||||
|
||||
name: 'Mi Future',
|
||||
author: 'syuilo',
|
||||
|
||||
base: 'dark',
|
||||
|
||||
props: {
|
||||
accent: '#63e2b7',
|
||||
bg: '#101014',
|
||||
fg: '#D5D5D6',
|
||||
fgHighlighted: '#fff',
|
||||
fgOnAccent: '#000',
|
||||
divider: 'rgba(255, 255, 255, 0.1)',
|
||||
panel: '#18181c',
|
||||
panelHeaderBg: '@panel',
|
||||
panelHeaderDivider: '@divider',
|
||||
renote: '@accent',
|
||||
mention: '#f2c97d',
|
||||
mentionMe: '@accent',
|
||||
hashtag: '#70c0e8',
|
||||
link: '#e88080',
|
||||
},
|
||||
}
|
||||
@@ -31,7 +31,7 @@
|
||||
|
||||
<script lang="ts">
|
||||
import { defineComponent } from 'vue';
|
||||
import { modalMenu } from '@client/os';
|
||||
import { popupMenu } from '@client/os';
|
||||
import { url } from '@client/config';
|
||||
|
||||
export default defineComponent({
|
||||
@@ -121,7 +121,7 @@ export default defineComponent({
|
||||
if (menu.length > 0) menu.push(null);
|
||||
menu = menu.concat(this.menu);
|
||||
}
|
||||
modalMenu(menu, ev.currentTarget || ev.target);
|
||||
popupMenu(menu, ev.currentTarget || ev.target);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
@@ -150,7 +150,7 @@ export default defineComponent({
|
||||
});
|
||||
}));
|
||||
|
||||
os.modalMenu([...[{
|
||||
os.popupMenu([...[{
|
||||
type: 'link',
|
||||
text: this.$ts.profile,
|
||||
to: `/@${ this.$i.username }`,
|
||||
@@ -159,7 +159,7 @@ export default defineComponent({
|
||||
icon: 'fas fa-plus',
|
||||
text: this.$ts.addAccount,
|
||||
action: () => {
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: this.$ts.existingAccount,
|
||||
action: () => { this.addAccount(); },
|
||||
}, {
|
||||
@@ -374,8 +374,8 @@ export default defineComponent({
|
||||
padding-top: 8px;
|
||||
padding-bottom: 8px;
|
||||
background: var(--X14);
|
||||
-webkit-backdrop-filter: blur(8px);
|
||||
backdrop-filter: blur(8px);
|
||||
-webkit-backdrop-filter: var(--blur, blur(8px));
|
||||
backdrop-filter: var(--blur, blur(8px));
|
||||
}
|
||||
|
||||
&:first-child {
|
||||
|
||||
@@ -55,7 +55,7 @@
|
||||
<MkA to="/my/favorites" class="item"><i class="fas fa-star icon"></i>{{ $ts.favorites }}</MkA>
|
||||
</div>
|
||||
</div>
|
||||
<MkAd class="a" prefer="square"/>
|
||||
<MkAd class="a" :prefer="['square']"/>
|
||||
</div>
|
||||
<footer class="footer">
|
||||
<div class="left">
|
||||
@@ -373,8 +373,8 @@ export default defineComponent({
|
||||
position: sticky;
|
||||
top: 0;
|
||||
background: var(--X17);
|
||||
-webkit-backdrop-filter: blur(8px);
|
||||
backdrop-filter: blur(8px);
|
||||
-webkit-backdrop-filter: var(--blur, blur(8px));
|
||||
backdrop-filter: var(--blur, blur(8px));
|
||||
z-index: 1;
|
||||
color: var(--fgTransparentWeak);
|
||||
|
||||
|
||||
@@ -432,7 +432,7 @@ export default defineComponent({
|
||||
pleaseLogin();
|
||||
this.operating = true;
|
||||
this.blur();
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: this.$ts.renote,
|
||||
icon: 'fas fa-retweet',
|
||||
action: () => {
|
||||
@@ -726,7 +726,7 @@ export default defineComponent({
|
||||
|
||||
menu(viaKeyboard = false) {
|
||||
this.operating = true;
|
||||
os.modalMenu(this.getMenu(), this.$refs.menuButton, {
|
||||
os.popupMenu(this.getMenu(), this.$refs.menuButton, {
|
||||
viaKeyboard
|
||||
}).then(() => {
|
||||
this.operating = false;
|
||||
@@ -736,7 +736,7 @@ export default defineComponent({
|
||||
|
||||
showRenoteMenu(viaKeyboard = false) {
|
||||
if (!this.isMyRenote) return;
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: this.$ts.unrenote,
|
||||
icon: 'fas fa-trash-alt',
|
||||
danger: true,
|
||||
@@ -780,7 +780,7 @@ export default defineComponent({
|
||||
|
||||
async clip() {
|
||||
const clips = await os.api('clips/list');
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
icon: 'fas fa-plus',
|
||||
text: this.$ts.createNew,
|
||||
action: async () => {
|
||||
|
||||
@@ -178,7 +178,7 @@ export default defineComponent({
|
||||
},
|
||||
|
||||
openChannelMenu(ev) {
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: this.$ts.copyUrl,
|
||||
icon: 'fas fa-link',
|
||||
action: () => {
|
||||
|
||||
@@ -593,7 +593,7 @@ export default defineComponent({
|
||||
},
|
||||
|
||||
showActions(ev) {
|
||||
os.modalMenu(postFormActions.map(action => ({
|
||||
os.popupMenu(postFormActions.map(action => ({
|
||||
text: action.title,
|
||||
action: () => {
|
||||
action.handler({
|
||||
|
||||
@@ -130,8 +130,8 @@ export default defineComponent({
|
||||
width: 100%;
|
||||
font-weight: bold;
|
||||
//background-color: var(--panel);
|
||||
-webkit-backdrop-filter: blur(32px);
|
||||
backdrop-filter: blur(32px);
|
||||
-webkit-backdrop-filter: var(--blur, blur(32px));
|
||||
backdrop-filter: var(--blur, blur(32px));
|
||||
background-color: var(--header);
|
||||
border-bottom: solid 0.5px var(--divider);
|
||||
box-sizing: border-box;
|
||||
|
||||
@@ -305,8 +305,8 @@ export default defineComponent({
|
||||
|
||||
&.naked {
|
||||
background: var(--acrylicBg) !important;
|
||||
-webkit-backdrop-filter: blur(10px);
|
||||
backdrop-filter: blur(10px);
|
||||
-webkit-backdrop-filter: var(--blur, blur(10px));
|
||||
backdrop-filter: var(--blur, blur(10px));
|
||||
|
||||
> header {
|
||||
background: transparent;
|
||||
|
||||
@@ -116,7 +116,7 @@ export default defineComponent({
|
||||
});
|
||||
}));
|
||||
|
||||
os.modalMenu([...[{
|
||||
os.popupMenu([...[{
|
||||
type: 'link',
|
||||
text: this.$ts.profile,
|
||||
to: `/@${ this.$i.username }`,
|
||||
@@ -125,7 +125,7 @@ export default defineComponent({
|
||||
icon: 'fas fa-plus',
|
||||
text: this.$ts.addAccount,
|
||||
action: () => {
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: this.$ts.existingAccount,
|
||||
action: () => { this.addAccount(); },
|
||||
}, {
|
||||
|
||||
@@ -138,8 +138,8 @@ export default defineComponent({
|
||||
text-align: center;
|
||||
font-weight: bold;
|
||||
//background-color: var(--panel);
|
||||
-webkit-backdrop-filter: blur(32px);
|
||||
backdrop-filter: blur(32px);
|
||||
-webkit-backdrop-filter: var(--blur, blur(32px));
|
||||
backdrop-filter: var(--blur, blur(32px));
|
||||
background-color: var(--header);
|
||||
|
||||
> ._button {
|
||||
|
||||
@@ -136,7 +136,7 @@ export default defineComponent({
|
||||
});
|
||||
}));
|
||||
|
||||
os.modalMenu([...[{
|
||||
os.popupMenu([...[{
|
||||
type: 'link',
|
||||
text: this.$ts.profile,
|
||||
to: `/@${ this.$i.username }`,
|
||||
@@ -145,7 +145,7 @@ export default defineComponent({
|
||||
icon: 'fas fa-plus',
|
||||
text: this.$ts.addAccount,
|
||||
action: () => {
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: this.$ts.existingAccount,
|
||||
action: () => { this.addAccount(); },
|
||||
}, {
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<main class="main _panel" @contextmenu.stop="onContextmenu">
|
||||
<main class="main" @contextmenu.stop="onContextmenu">
|
||||
<header class="header" @click="onHeaderClick">
|
||||
<XHeader :info="pageInfo" :back-button="true" @back="back()"/>
|
||||
</header>
|
||||
@@ -240,7 +240,7 @@ export default defineComponent({
|
||||
|
||||
&.wallpaper {
|
||||
background: var(--wallpaperOverlay);
|
||||
//backdrop-filter: blur(4px);
|
||||
//backdrop-filter: var(--blur, blur(4px));
|
||||
}
|
||||
|
||||
&.isMobile {
|
||||
@@ -292,7 +292,10 @@ export default defineComponent({
|
||||
width: 750px;
|
||||
margin: 0 16px 0 0;
|
||||
background: var(--panel);
|
||||
border-left: solid 1px var(--divider);
|
||||
border-right: solid 1px var(--divider);
|
||||
border-radius: 0;
|
||||
overflow: clip;
|
||||
--margin: 12px;
|
||||
|
||||
> .header {
|
||||
@@ -300,8 +303,8 @@ export default defineComponent({
|
||||
z-index: 1000;
|
||||
top: var(--globalHeaderHeight, 0px);
|
||||
height: $header-height;
|
||||
-webkit-backdrop-filter: blur(32px);
|
||||
backdrop-filter: blur(32px);
|
||||
-webkit-backdrop-filter: var(--blur, blur(32px));
|
||||
backdrop-filter: var(--blur, blur(32px));
|
||||
background-color: var(--header);
|
||||
border-bottom: solid 0.5px var(--divider);
|
||||
}
|
||||
@@ -343,6 +346,7 @@ export default defineComponent({
|
||||
|
||||
> .main {
|
||||
margin-top: 0;
|
||||
border: solid 1px var(--divider);
|
||||
border-radius: var(--radius);
|
||||
}
|
||||
|
||||
@@ -376,8 +380,8 @@ export default defineComponent({
|
||||
display: flex;
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
-webkit-backdrop-filter: blur(32px);
|
||||
backdrop-filter: blur(32px);
|
||||
-webkit-backdrop-filter: var(--blur, blur(32px));
|
||||
backdrop-filter: var(--blur, blur(32px));
|
||||
background-color: var(--header);
|
||||
border-top: solid 0.5px var(--divider);
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<div class="ddiqwdnk">
|
||||
<XWidgets class="widgets" :edit="editMode" :widgets="$store.reactiveState.widgets.value.filter(w => w.place === place)" @add-widget="addWidget" @remove-widget="removeWidget" @update-widget="updateWidget" @update-widgets="updateWidgets" @exit="editMode = false"/>
|
||||
<MkAd class="a" prefer="square"/>
|
||||
<MkAd class="a" :prefer="['square']"/>
|
||||
|
||||
<button v-if="editMode" @click="editMode = false" class="_textButton edit" style="font-size: 0.9em;"><i class="fas fa-check"></i> {{ $ts.editWidgetsExit }}</button>
|
||||
<button v-else @click="editMode = true" class="_textButton edit" style="font-size: 0.9em;"><i class="fas fa-pencil-alt"></i> {{ $ts.editWidgets }}</button>
|
||||
|
||||
@@ -250,7 +250,7 @@ export default defineComponent({
|
||||
|
||||
&.wallpaper {
|
||||
background: var(--wallpaperOverlay);
|
||||
//backdrop-filter: blur(4px);
|
||||
//backdrop-filter: var(--blur, blur(4px));
|
||||
}
|
||||
|
||||
> .contents {
|
||||
@@ -269,8 +269,8 @@ export default defineComponent({
|
||||
text-align: center;
|
||||
font-weight: bold;
|
||||
//background-color: var(--panel);
|
||||
-webkit-backdrop-filter: blur(32px);
|
||||
backdrop-filter: blur(32px);
|
||||
-webkit-backdrop-filter: var(--blur, blur(32px));
|
||||
backdrop-filter: var(--blur, blur(32px));
|
||||
background-color: var(--header);
|
||||
//border-bottom: solid 0.5px var(--divider);
|
||||
user-select: none;
|
||||
@@ -341,8 +341,8 @@ export default defineComponent({
|
||||
display: flex;
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
-webkit-backdrop-filter: blur(32px);
|
||||
backdrop-filter: blur(32px);
|
||||
-webkit-backdrop-filter: var(--blur, blur(32px));
|
||||
backdrop-filter: var(--blur, blur(32px));
|
||||
background-color: var(--header);
|
||||
|
||||
&:not(.navHidden) {
|
||||
|
||||
@@ -90,8 +90,8 @@ export default defineComponent({
|
||||
left: 0;
|
||||
z-index: 1000;
|
||||
line-height: $height;
|
||||
-webkit-backdrop-filter: blur(32px);
|
||||
backdrop-filter: blur(32px);
|
||||
-webkit-backdrop-filter: var(--blur, blur(32px));
|
||||
backdrop-filter: var(--blur, blur(32px));
|
||||
background-color: var(--X16);
|
||||
|
||||
> .wide {
|
||||
|
||||
@@ -122,8 +122,8 @@ export default defineComponent({
|
||||
background: rgba(0, 0, 0, 0.3);
|
||||
|
||||
&.transparent {
|
||||
-webkit-backdrop-filter: blur(12px);
|
||||
backdrop-filter: blur(12px);
|
||||
-webkit-backdrop-filter: var(--blur, blur(12px));
|
||||
backdrop-filter: var(--blur, blur(12px));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -140,8 +140,8 @@ export default defineComponent({
|
||||
margin: 0 auto;
|
||||
|
||||
> .panel {
|
||||
-webkit-backdrop-filter: blur(8px);
|
||||
backdrop-filter: blur(8px);
|
||||
-webkit-backdrop-filter: var(--blur, blur(8px));
|
||||
backdrop-filter: var(--blur, blur(8px));
|
||||
background: rgba(0, 0, 0, 0.5);
|
||||
border-radius: var(--radius);
|
||||
|
||||
|
||||
@@ -89,8 +89,8 @@ export default defineComponent({
|
||||
line-height: $header-height;
|
||||
text-align: center;
|
||||
//background-color: var(--panel);
|
||||
-webkit-backdrop-filter: blur(32px);
|
||||
backdrop-filter: blur(32px);
|
||||
-webkit-backdrop-filter: var(--blur, blur(32px));
|
||||
backdrop-filter: var(--blur, blur(32px));
|
||||
background-color: var(--header);
|
||||
border-bottom: solid 0.5px var(--divider);
|
||||
}
|
||||
|
||||
@@ -86,7 +86,7 @@ export default defineComponent({
|
||||
this.setSrc('list');
|
||||
}
|
||||
}));
|
||||
os.modalMenu([{
|
||||
os.popupMenu([{
|
||||
text: this.$ts._timelines.home,
|
||||
icon: 'fas fa-home',
|
||||
action: () => { this.setSrc('home') }
|
||||
|
||||
Reference in New Issue
Block a user