--fix
This commit is contained in:
parent
0cbfcb99a9
commit
fddb531ed2
20
src/App.vue
20
src/App.vue
@ -15,8 +15,12 @@
|
|||||||
class="app-layout container"
|
class="app-layout container"
|
||||||
:class="classes"
|
:class="classes"
|
||||||
>
|
>
|
||||||
<div class="underlay"/>
|
<div class="underlay" />
|
||||||
<div id="sidebar" class="column -scrollable" :class="{ '-show-scrollbar': showScrollbars }">
|
<div
|
||||||
|
id="sidebar"
|
||||||
|
class="column -scrollable"
|
||||||
|
:class="{ '-show-scrollbar': showScrollbars }"
|
||||||
|
>
|
||||||
<user-panel />
|
<user-panel />
|
||||||
<template v-if="layoutType !== 'mobile'">
|
<template v-if="layoutType !== 'mobile'">
|
||||||
<nav-panel />
|
<nav-panel />
|
||||||
@ -26,7 +30,11 @@
|
|||||||
<div id="notifs-sidebar" />
|
<div id="notifs-sidebar" />
|
||||||
</template>
|
</template>
|
||||||
</div>
|
</div>
|
||||||
<div id="main-scroller" class="column main" :class="{ '-full-height': isChats }">
|
<div
|
||||||
|
id="main-scroller"
|
||||||
|
class="column main"
|
||||||
|
:class="{ '-full-height': isChats }"
|
||||||
|
>
|
||||||
<div
|
<div
|
||||||
v-if="!currentUser"
|
v-if="!currentUser"
|
||||||
class="login-hint panel panel-default"
|
class="login-hint panel panel-default"
|
||||||
@ -40,7 +48,11 @@
|
|||||||
</div>
|
</div>
|
||||||
<router-view />
|
<router-view />
|
||||||
</div>
|
</div>
|
||||||
<div id="notifs-column" class="column -scrollable" :class="{ '-show-scrollbar': showScrollbars }"/>
|
<div
|
||||||
|
id="notifs-column"
|
||||||
|
class="column -scrollable"
|
||||||
|
:class="{ '-show-scrollbar': showScrollbars }"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
<MediaModal />
|
<MediaModal />
|
||||||
<shout-panel
|
<shout-panel
|
||||||
|
@ -156,7 +156,7 @@ const setSettings = async ({ apiConfig, staticConfig, store }) => {
|
|||||||
copyInstanceOption('hideSitename')
|
copyInstanceOption('hideSitename')
|
||||||
copyInstanceOption('sidebarRight')
|
copyInstanceOption('sidebarRight')
|
||||||
|
|
||||||
return store.dispatch('setTheme', config['theme'])
|
return store.dispatch('setTheme', config.theme)
|
||||||
}
|
}
|
||||||
|
|
||||||
const getTOS = async ({ store }) => {
|
const getTOS = async ({ store }) => {
|
||||||
@ -197,7 +197,7 @@ const getStickers = async ({ store }) => {
|
|||||||
const stickers = (await Promise.all(
|
const stickers = (await Promise.all(
|
||||||
Object.entries(values).map(async ([name, path]) => {
|
Object.entries(values).map(async ([name, path]) => {
|
||||||
const resPack = await window.fetch(path + 'pack.json')
|
const resPack = await window.fetch(path + 'pack.json')
|
||||||
var meta = {}
|
let meta = {}
|
||||||
if (resPack.ok) {
|
if (resPack.ok) {
|
||||||
meta = await resPack.json()
|
meta = await resPack.json()
|
||||||
}
|
}
|
||||||
|
@ -31,7 +31,8 @@ export default (store) => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
let routes = [
|
let routes = [
|
||||||
{ name: 'root',
|
{
|
||||||
|
name: 'root',
|
||||||
path: '/',
|
path: '/',
|
||||||
redirect: _to => {
|
redirect: _to => {
|
||||||
return (store.state.users.currentUser
|
return (store.state.users.currentUser
|
||||||
@ -45,12 +46,14 @@ export default (store) => {
|
|||||||
{ name: 'tag-timeline', path: '/tag/:tag', component: TagTimeline },
|
{ name: 'tag-timeline', path: '/tag/:tag', component: TagTimeline },
|
||||||
{ name: 'bookmarks', path: '/bookmarks', component: BookmarkTimeline },
|
{ name: 'bookmarks', path: '/bookmarks', component: BookmarkTimeline },
|
||||||
{ name: 'conversation', path: '/notice/:id', component: ConversationPage, meta: { dontScroll: true } },
|
{ name: 'conversation', path: '/notice/:id', component: ConversationPage, meta: { dontScroll: true } },
|
||||||
{ name: 'remote-user-profile-acct',
|
{
|
||||||
|
name: 'remote-user-profile-acct',
|
||||||
path: '/remote-users/:_(@)?:username([^/@]+)@:hostname([^/@]+)',
|
path: '/remote-users/:_(@)?:username([^/@]+)@:hostname([^/@]+)',
|
||||||
component: RemoteUserResolver,
|
component: RemoteUserResolver,
|
||||||
beforeEnter: validateAuthenticatedRoute
|
beforeEnter: validateAuthenticatedRoute
|
||||||
},
|
},
|
||||||
{ name: 'remote-user-profile',
|
{
|
||||||
|
name: 'remote-user-profile',
|
||||||
path: '/remote-users/:hostname/:username',
|
path: '/remote-users/:hostname/:username',
|
||||||
component: RemoteUserResolver,
|
component: RemoteUserResolver,
|
||||||
beforeEnter: validateAuthenticatedRoute
|
beforeEnter: validateAuthenticatedRoute
|
||||||
|
@ -8,7 +8,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./about.js" ></script>
|
<script src="./about.js"></script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
</style>
|
</style>
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
:bound-to="{ x: 'container' }"
|
:bound-to="{ x: 'container' }"
|
||||||
remove-padding
|
remove-padding
|
||||||
>
|
>
|
||||||
<template v-slot:content>
|
<template #content>
|
||||||
<div class="dropdown-menu">
|
<div class="dropdown-menu">
|
||||||
<template v-if="relationship.following">
|
<template v-if="relationship.following">
|
||||||
<button
|
<button
|
||||||
@ -57,7 +57,7 @@
|
|||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:trigger>
|
<template #trigger>
|
||||||
<button class="button-unstyled ellipsis-button">
|
<button class="button-unstyled ellipsis-button">
|
||||||
<FAIcon
|
<FAIcon
|
||||||
class="icon"
|
class="icon"
|
||||||
|
@ -14,7 +14,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./avatar_list.js" ></script>
|
<script src="./avatar_list.js"></script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
@import '../../_variables.scss';
|
@import '../../_variables.scss';
|
||||||
|
@ -1,10 +1,13 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="basic-user-card">
|
<div class="basic-user-card">
|
||||||
<router-link @click.prevent :to="userProfileLink(user)">
|
<router-link
|
||||||
|
:to="userProfileLink(user)"
|
||||||
|
@click.prevent
|
||||||
|
>
|
||||||
<UserPopover
|
<UserPopover
|
||||||
:userId="user.id"
|
:user-id="user.id"
|
||||||
:overlayCenters="true"
|
:overlay-centers="true"
|
||||||
overlayCentersSelector=".avatar"
|
overlay-centers-selector=".avatar"
|
||||||
>
|
>
|
||||||
<UserAvatar
|
<UserAvatar
|
||||||
class="user-avatar avatar"
|
class="user-avatar avatar"
|
||||||
|
@ -107,7 +107,7 @@ const Chat = {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
'$route': function () {
|
$route: function () {
|
||||||
this.startFetching()
|
this.startFetching()
|
||||||
},
|
},
|
||||||
mastoUserSocketStatus (newValue) {
|
mastoUserSocketStatus (newValue) {
|
||||||
|
@ -23,7 +23,7 @@
|
|||||||
class="timeline"
|
class="timeline"
|
||||||
>
|
>
|
||||||
<List :items="sortedChatList">
|
<List :items="sortedChatList">
|
||||||
<template v-slot:item="{item}">
|
<template #item="{item}">
|
||||||
<ChatListItem
|
<ChatListItem
|
||||||
:key="item.id"
|
:key="item.id"
|
||||||
:compact="false"
|
:compact="false"
|
||||||
|
@ -16,7 +16,7 @@
|
|||||||
>
|
>
|
||||||
<UserPopover
|
<UserPopover
|
||||||
v-if="chatViewItem.isHead"
|
v-if="chatViewItem.isHead"
|
||||||
:userId="author.id"
|
:user-id="author.id"
|
||||||
>
|
>
|
||||||
<UserAvatar
|
<UserAvatar
|
||||||
:compact="true"
|
:compact="true"
|
||||||
@ -50,7 +50,7 @@
|
|||||||
@show="menuOpened = true"
|
@show="menuOpened = true"
|
||||||
@close="menuOpened = false"
|
@close="menuOpened = false"
|
||||||
>
|
>
|
||||||
<template v-slot:content>
|
<template #content>
|
||||||
<div class="dropdown-menu">
|
<div class="dropdown-menu">
|
||||||
<button
|
<button
|
||||||
class="button-default dropdown-item dropdown-item-icon"
|
class="button-default dropdown-item dropdown-item-icon"
|
||||||
@ -60,7 +60,7 @@
|
|||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:trigger>
|
<template #trigger>
|
||||||
<button
|
<button
|
||||||
class="button-default menu-icon"
|
class="button-default menu-icon"
|
||||||
:title="$t('chats.more')"
|
:title="$t('chats.more')"
|
||||||
@ -75,7 +75,7 @@
|
|||||||
:status="messageForStatusContent"
|
:status="messageForStatusContent"
|
||||||
:full-content="true"
|
:full-content="true"
|
||||||
>
|
>
|
||||||
<template v-slot:footer>
|
<template #footer>
|
||||||
<span
|
<span
|
||||||
class="created-at"
|
class="created-at"
|
||||||
>
|
>
|
||||||
@ -96,7 +96,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./chat_message.js" ></script>
|
<script src="./chat_message.js"></script>
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
@import './chat_message.scss';
|
@import './chat_message.scss';
|
||||||
|
|
||||||
|
@ -4,9 +4,9 @@
|
|||||||
:title="title"
|
:title="title"
|
||||||
>
|
>
|
||||||
<UserPopover
|
<UserPopover
|
||||||
class="avatar-container"
|
|
||||||
v-if="withAvatar && user"
|
v-if="withAvatar && user"
|
||||||
:userId="user.id"
|
class="avatar-container"
|
||||||
|
:user-id="user.id"
|
||||||
>
|
>
|
||||||
<UserAvatar
|
<UserAvatar
|
||||||
class="titlebar-avatar"
|
class="titlebar-avatar"
|
||||||
|
@ -22,12 +22,12 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
emits: ['update:modelValue'],
|
|
||||||
props: [
|
props: [
|
||||||
'modelValue',
|
'modelValue',
|
||||||
'indeterminate',
|
'indeterminate',
|
||||||
'disabled'
|
'disabled'
|
||||||
]
|
],
|
||||||
|
emits: ['update:modelValue']
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
@ -46,7 +46,6 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<style lang="scss" src="./color_input.scss"></style>
|
|
||||||
<script>
|
<script>
|
||||||
import Checkbox from '../checkbox/checkbox.vue'
|
import Checkbox from '../checkbox/checkbox.vue'
|
||||||
import { hex2rgb } from '../../services/color_convert/color_convert.js'
|
import { hex2rgb } from '../../services/color_convert/color_convert.js'
|
||||||
@ -108,6 +107,7 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
<style lang="scss" src="./color_input.scss"></style>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
.color-control {
|
.color-control {
|
||||||
|
@ -271,7 +271,7 @@ const conversation = {
|
|||||||
result[irid] = result[irid] || []
|
result[irid] = result[irid] || []
|
||||||
result[irid].push({
|
result[irid].push({
|
||||||
name: `#${i}`,
|
name: `#${i}`,
|
||||||
id: id
|
id
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
i++
|
i++
|
||||||
|
@ -31,8 +31,8 @@
|
|||||||
keypath="status.show_all_conversation_with_icon"
|
keypath="status.show_all_conversation_with_icon"
|
||||||
tag="button"
|
tag="button"
|
||||||
class="button-unstyled -link"
|
class="button-unstyled -link"
|
||||||
@click.prevent="diveToTopLevel"
|
|
||||||
scope="global"
|
scope="global"
|
||||||
|
@click.prevent="diveToTopLevel"
|
||||||
>
|
>
|
||||||
<template #icon>
|
<template #icon>
|
||||||
<FAIcon
|
<FAIcon
|
||||||
|
@ -46,21 +46,25 @@ export default {
|
|||||||
enableMask () { return this.supportsMask && this.$store.state.instance.logoMask },
|
enableMask () { return this.supportsMask && this.$store.state.instance.logoMask },
|
||||||
logoStyle () {
|
logoStyle () {
|
||||||
return {
|
return {
|
||||||
'visibility': this.enableMask ? 'hidden' : 'visible'
|
visibility: this.enableMask ? 'hidden' : 'visible'
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
logoMaskStyle () {
|
logoMaskStyle () {
|
||||||
return this.enableMask ? {
|
return this.enableMask
|
||||||
|
? {
|
||||||
'mask-image': `url(${this.$store.state.instance.logo})`
|
'mask-image': `url(${this.$store.state.instance.logo})`
|
||||||
} : {
|
}
|
||||||
|
: {
|
||||||
'background-color': this.enableMask ? '' : 'transparent'
|
'background-color': this.enableMask ? '' : 'transparent'
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
logoBgStyle () {
|
logoBgStyle () {
|
||||||
return Object.assign({
|
return Object.assign({
|
||||||
'margin': `${this.$store.state.instance.logoMargin} 0`,
|
margin: `${this.$store.state.instance.logoMargin} 0`,
|
||||||
opacity: this.searchBarHidden ? 1 : 0
|
opacity: this.searchBarHidden ? 1 : 0
|
||||||
}, this.enableMask ? {} : {
|
}, this.enableMask
|
||||||
|
? {}
|
||||||
|
: {
|
||||||
'background-color': this.enableMask ? '' : 'transparent'
|
'background-color': this.enableMask ? '' : 'transparent'
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
@ -9,7 +9,7 @@
|
|||||||
class="btn button-default"
|
class="btn button-default"
|
||||||
>
|
>
|
||||||
{{ $t('domain_mute_card.unmute') }}
|
{{ $t('domain_mute_card.unmute') }}
|
||||||
<template v-slot:progress>
|
<template #progress>
|
||||||
{{ $t('domain_mute_card.unmute_progress') }}
|
{{ $t('domain_mute_card.unmute_progress') }}
|
||||||
</template>
|
</template>
|
||||||
</ProgressButton>
|
</ProgressButton>
|
||||||
@ -19,7 +19,7 @@
|
|||||||
class="btn button-default"
|
class="btn button-default"
|
||||||
>
|
>
|
||||||
{{ $t('domain_mute_card.mute') }}
|
{{ $t('domain_mute_card.mute') }}
|
||||||
<template v-slot:progress>
|
<template #progress>
|
||||||
{{ $t('domain_mute_card.mute_progress') }}
|
{{ $t('domain_mute_card.mute_progress') }}
|
||||||
</template>
|
</template>
|
||||||
</ProgressButton>
|
</ProgressButton>
|
||||||
|
@ -321,7 +321,7 @@ const EmojiInput = {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
scrollIntoView () {
|
scrollIntoView () {
|
||||||
const rootRef = this.$refs['picker'].$el
|
const rootRef = this.$refs.picker.$el
|
||||||
/* Scroller is either `window` (replies in TL), sidebar (main post form,
|
/* Scroller is either `window` (replies in TL), sidebar (main post form,
|
||||||
* replies in notifs) or mobile post form. Note that getting and setting
|
* replies in notifs) or mobile post form. Note that getting and setting
|
||||||
* scroll is different for `Window` and `Element`s
|
* scroll is different for `Window` and `Element`s
|
||||||
|
@ -25,7 +25,7 @@ const filterByKeyword = (list, keyword = '') => {
|
|||||||
if (keyword === '') return list
|
if (keyword === '') return list
|
||||||
|
|
||||||
const keywordLowercase = keyword.toLowerCase()
|
const keywordLowercase = keyword.toLowerCase()
|
||||||
let orderedEmojiList = []
|
const orderedEmojiList = []
|
||||||
for (const emoji of list) {
|
for (const emoji of list) {
|
||||||
const indexOfKeyword = emoji.displayText.toLowerCase().indexOf(keywordLowercase)
|
const indexOfKeyword = emoji.displayText.toLowerCase().indexOf(keywordLowercase)
|
||||||
if (indexOfKeyword > -1) {
|
if (indexOfKeyword > -1) {
|
||||||
|
@ -26,7 +26,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./emoji_reactions.js" ></script>
|
<script src="./emoji_reactions.js"></script>
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
@import '../../_variables.scss';
|
@import '../../_variables.scss';
|
||||||
|
|
||||||
|
@ -25,7 +25,7 @@ library.add(
|
|||||||
)
|
)
|
||||||
|
|
||||||
const ExtraButtons = {
|
const ExtraButtons = {
|
||||||
props: [ 'status' ],
|
props: ['status'],
|
||||||
components: { Popover },
|
components: { Popover },
|
||||||
methods: {
|
methods: {
|
||||||
deleteStatus () {
|
deleteStatus () {
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
:bound-to="{ x: 'container' }"
|
:bound-to="{ x: 'container' }"
|
||||||
remove-padding
|
remove-padding
|
||||||
>
|
>
|
||||||
<template v-slot:content="{close}">
|
<template #content="{close}">
|
||||||
<div class="dropdown-menu">
|
<div class="dropdown-menu">
|
||||||
<button
|
<button
|
||||||
v-if="canMute && !status.thread_muted"
|
v-if="canMute && !status.thread_muted"
|
||||||
@ -120,7 +120,7 @@
|
|||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:trigger>
|
<template #trigger>
|
||||||
<span class="button-unstyled popover-trigger">
|
<span class="button-unstyled popover-trigger">
|
||||||
<FAIcon
|
<FAIcon
|
||||||
class="fa-scale-110 fa-old-padding"
|
class="fa-scale-110 fa-old-padding"
|
||||||
@ -131,7 +131,7 @@
|
|||||||
</Popover>
|
</Popover>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./extra_buttons.js" ></script>
|
<script src="./extra_buttons.js"></script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
@import '../../_variables.scss';
|
@import '../../_variables.scss';
|
||||||
|
@ -29,7 +29,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./favorite_button.js" ></script>
|
<script src="./favorite_button.js"></script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
@import '../../_variables.scss';
|
@import '../../_variables.scss';
|
||||||
|
@ -32,7 +32,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./features_panel.js" ></script>
|
<script src="./features_panel.js"></script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
.features-panel li {
|
.features-panel li {
|
||||||
|
@ -11,7 +11,7 @@ library.add(
|
|||||||
)
|
)
|
||||||
|
|
||||||
const Flash = {
|
const Flash = {
|
||||||
props: [ 'src' ],
|
props: ['src'],
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
player: false, // can be true, "hidden", false. hidden = element exists
|
player: false, // can be true, "hidden", false. hidden = element exists
|
||||||
|
@ -47,7 +47,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./font_control.js" ></script>
|
<script src="./font_control.js"></script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
@import '../../_variables.scss';
|
@import '../../_variables.scss';
|
||||||
|
@ -14,6 +14,6 @@
|
|||||||
</span>
|
</span>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./hashtag_link.js"/>
|
<script src="./hashtag_link.js" />
|
||||||
|
|
||||||
<style lang="scss" src="./hashtag_link.scss"/>
|
<style lang="scss" src="./hashtag_link.scss" />
|
||||||
|
@ -95,7 +95,7 @@ const ImageCropper = {
|
|||||||
const fileInput = this.$refs.input
|
const fileInput = this.$refs.input
|
||||||
if (fileInput.files != null && fileInput.files[0] != null) {
|
if (fileInput.files != null && fileInput.files[0] != null) {
|
||||||
this.file = fileInput.files[0]
|
this.file = fileInput.files[0]
|
||||||
let reader = new window.FileReader()
|
const reader = new window.FileReader()
|
||||||
reader.onload = (e) => {
|
reader.onload = (e) => {
|
||||||
this.dataUrl = e.target.result
|
this.dataUrl = e.target.result
|
||||||
this.$emit('open')
|
this.$emit('open')
|
||||||
|
@ -10,4 +10,4 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./instance_specific_panel.js" ></script>
|
<script src="./instance_specific_panel.js"></script>
|
||||||
|
@ -12,7 +12,7 @@ const Interactions = {
|
|||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
allowFollowingMove: this.$store.state.users.currentUser.allow_following_move,
|
allowFollowingMove: this.$store.state.users.currentUser.allow_following_move,
|
||||||
filterMode: tabModeDict['mentions']
|
filterMode: tabModeDict.mentions
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
@ -25,6 +25,7 @@ import Select from '../select/select.vue'
|
|||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
|
// eslint-disable-next-line vue/no-reserved-component-names
|
||||||
Select
|
Select
|
||||||
},
|
},
|
||||||
props: {
|
props: {
|
||||||
|
@ -83,7 +83,7 @@ const LoginForm = {
|
|||||||
},
|
},
|
||||||
clearError () { this.error = false },
|
clearError () { this.error = false },
|
||||||
focusOnPasswordInput () {
|
focusOnPasswordInput () {
|
||||||
let passwordInput = this.$refs.passwordInput
|
const passwordInput = this.$refs.passwordInput
|
||||||
passwordInput.focus()
|
passwordInput.focus()
|
||||||
passwordInput.setSelectionRange(0, passwordInput.value.length)
|
passwordInput.setSelectionRange(0, passwordInput.value.length)
|
||||||
}
|
}
|
||||||
|
@ -90,7 +90,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./login_form.js" ></script>
|
<script src="./login_form.js"></script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
@import '../../_variables.scss';
|
@import '../../_variables.scss';
|
||||||
|
@ -42,7 +42,8 @@ const mediaUpload = {
|
|||||||
.then((fileData) => {
|
.then((fileData) => {
|
||||||
self.$emit('uploaded', fileData)
|
self.$emit('uploaded', fileData)
|
||||||
self.decreaseUploadCount()
|
self.decreaseUploadCount()
|
||||||
}, (error) => { // eslint-disable-line handle-callback-err
|
}, (error) => {
|
||||||
|
console.error('Error uploading file', error)
|
||||||
self.$emit('upload-failed', 'default')
|
self.$emit('upload-failed', 'default')
|
||||||
self.decreaseUploadCount()
|
self.decreaseUploadCount()
|
||||||
})
|
})
|
||||||
@ -73,7 +74,7 @@ const mediaUpload = {
|
|||||||
'disabled'
|
'disabled'
|
||||||
],
|
],
|
||||||
watch: {
|
watch: {
|
||||||
'dropFiles': function (fileInfos) {
|
dropFiles: function (fileInfos) {
|
||||||
if (!this.uploading) {
|
if (!this.uploading) {
|
||||||
this.multiUpload(fileInfos)
|
this.multiUpload(fileInfos)
|
||||||
}
|
}
|
||||||
|
@ -26,7 +26,7 @@
|
|||||||
</label>
|
</label>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./media_upload.js" ></script>
|
<script src="./media_upload.js"></script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
@import '../../_variables.scss';
|
@import '../../_variables.scss';
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
/><!-- eslint-enable vue/no-v-html -->
|
/><!-- eslint-enable vue/no-v-html -->
|
||||||
<UserPopover
|
<UserPopover
|
||||||
v-else
|
v-else
|
||||||
:userId="user.id"
|
:user-id="user.id"
|
||||||
:disabled="!shouldShowTooltip"
|
:disabled="!shouldShowTooltip"
|
||||||
>
|
>
|
||||||
<span
|
<span
|
||||||
@ -54,7 +54,10 @@
|
|||||||
:class="{ '-you': shouldBoldenYou }"
|
:class="{ '-you': shouldBoldenYou }"
|
||||||
> {{ ' ' + $t('status.you') }}</span>
|
> {{ ' ' + $t('status.you') }}</span>
|
||||||
<!-- eslint-enable vue/no-v-html -->
|
<!-- eslint-enable vue/no-v-html -->
|
||||||
</a><span class="full" ref="full">
|
</a><span
|
||||||
|
ref="full"
|
||||||
|
class="full"
|
||||||
|
>
|
||||||
<!-- eslint-disable vue/no-v-html -->
|
<!-- eslint-disable vue/no-v-html -->
|
||||||
@<span v-html="userName" /><span v-html="'@' + serverName" />
|
@<span v-html="userName" /><span v-html="'@' + serverName" />
|
||||||
<!-- eslint-enable vue/no-v-html -->
|
<!-- eslint-enable vue/no-v-html -->
|
||||||
@ -64,6 +67,6 @@
|
|||||||
</span>
|
</span>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./mention_link.js"/>
|
<script src="./mention_link.js" />
|
||||||
|
|
||||||
<style lang="scss" src="./mention_link.scss"/>
|
<style lang="scss" src="./mention_link.scss" />
|
||||||
|
@ -36,5 +36,5 @@
|
|||||||
</span>
|
</span>
|
||||||
</span>
|
</span>
|
||||||
</template>
|
</template>
|
||||||
<script src="./mentions_line.js" ></script>
|
<script src="./mentions_line.js"></script>
|
||||||
<style lang="scss" src="./mentions_line.scss" />
|
<style lang="scss" src="./mentions_line.scss" />
|
||||||
|
@ -69,4 +69,4 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script src="./recovery_form.js" ></script>
|
<script src="./recovery_form.js"></script>
|
||||||
|
@ -67,11 +67,10 @@
|
|||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
<div
|
<div
|
||||||
class="mobile-notifications"
|
|
||||||
id="mobile-notifications"
|
id="mobile-notifications"
|
||||||
|
class="mobile-notifications"
|
||||||
@scroll="onScroll"
|
@scroll="onScroll"
|
||||||
>
|
/>
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
<SideDrawer
|
<SideDrawer
|
||||||
ref="sideDrawer"
|
ref="sideDrawer"
|
||||||
|
@ -12,6 +12,9 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
|
provide: {
|
||||||
|
popoversZLayer: 'modals'
|
||||||
|
},
|
||||||
props: {
|
props: {
|
||||||
isOpen: {
|
isOpen: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
@ -22,14 +25,11 @@ export default {
|
|||||||
default: false
|
default: false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
provide: {
|
|
||||||
popoversZLayer: 'modals'
|
|
||||||
},
|
|
||||||
computed: {
|
computed: {
|
||||||
classes () {
|
classes () {
|
||||||
return {
|
return {
|
||||||
'modal-background': !this.noBackground,
|
'modal-background': !this.noBackground,
|
||||||
'open': this.isOpen
|
open: this.isOpen
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -8,7 +8,7 @@
|
|||||||
@show="setToggled(true)"
|
@show="setToggled(true)"
|
||||||
@close="setToggled(false)"
|
@close="setToggled(false)"
|
||||||
>
|
>
|
||||||
<template v-slot:content>
|
<template #content>
|
||||||
<div class="dropdown-menu">
|
<div class="dropdown-menu">
|
||||||
<span v-if="user.is_local">
|
<span v-if="user.is_local">
|
||||||
<button
|
<button
|
||||||
@ -122,7 +122,7 @@
|
|||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:trigger>
|
<template #trigger>
|
||||||
<button
|
<button
|
||||||
class="btn button-default btn-block moderation-tools-button"
|
class="btn button-default btn-block moderation-tools-button"
|
||||||
:class="{ toggled }"
|
:class="{ toggled }"
|
||||||
@ -137,11 +137,11 @@
|
|||||||
v-if="showDeleteUserDialog"
|
v-if="showDeleteUserDialog"
|
||||||
:on-cancel="deleteUserDialog.bind(this, false)"
|
:on-cancel="deleteUserDialog.bind(this, false)"
|
||||||
>
|
>
|
||||||
<template v-slot:header>
|
<template #header>
|
||||||
{{ $t('user_card.admin_menu.delete_user') }}
|
{{ $t('user_card.admin_menu.delete_user') }}
|
||||||
</template>
|
</template>
|
||||||
<p>{{ $t('user_card.admin_menu.delete_user_confirmation') }}</p>
|
<p>{{ $t('user_card.admin_menu.delete_user_confirmation') }}</p>
|
||||||
<template v-slot:footer>
|
<template #footer>
|
||||||
<button
|
<button
|
||||||
class="btn button-default"
|
class="btn button-default"
|
||||||
@click="deleteUserDialog(false)"
|
@click="deleteUserDialog(false)"
|
||||||
|
@ -9,10 +9,10 @@ import { get } from 'lodash'
|
|||||||
*/
|
*/
|
||||||
const toInstanceReasonObject = (instances, info, key) => {
|
const toInstanceReasonObject = (instances, info, key) => {
|
||||||
return instances.map(instance => {
|
return instances.map(instance => {
|
||||||
if (info[key] && info[key][instance] && info[key][instance]['reason']) {
|
if (info[key] && info[key][instance] && info[key][instance].reason) {
|
||||||
return { instance: instance, reason: info[key][instance]['reason'] }
|
return { instance, reason: info[key][instance].reason }
|
||||||
}
|
}
|
||||||
return { instance: instance, reason: '' }
|
return { instance, reason: '' }
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -90,7 +90,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./nav_panel.js" ></script>
|
<script src="./nav_panel.js"></script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
@import '../../_variables.scss';
|
@import '../../_variables.scss';
|
||||||
|
@ -40,7 +40,7 @@ const Notification = {
|
|||||||
unmuted: false
|
unmuted: false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
props: [ 'notification' ],
|
props: ['notification'],
|
||||||
components: {
|
components: {
|
||||||
StatusContent,
|
StatusContent,
|
||||||
UserAvatar,
|
UserAvatar,
|
||||||
|
@ -37,8 +37,8 @@
|
|||||||
@click.prevent
|
@click.prevent
|
||||||
>
|
>
|
||||||
<UserPopover
|
<UserPopover
|
||||||
:userId="notification.from_profile.id"
|
:user-id="notification.from_profile.id"
|
||||||
:overlayCenters="true"
|
:overlay-centers="true"
|
||||||
>
|
>
|
||||||
<UserAvatar
|
<UserAvatar
|
||||||
class="post-avatar"
|
class="post-avatar"
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
placement="bottom"
|
placement="bottom"
|
||||||
:bound-to="{ x: 'container' }"
|
:bound-to="{ x: 'container' }"
|
||||||
>
|
>
|
||||||
<template v-slot:content>
|
<template #content>
|
||||||
<div class="dropdown-menu">
|
<div class="dropdown-menu">
|
||||||
<button
|
<button
|
||||||
class="button-default dropdown-item"
|
class="button-default dropdown-item"
|
||||||
@ -72,7 +72,7 @@
|
|||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:trigger>
|
<template #trigger>
|
||||||
<button class="filter-trigger-button button-unstyled">
|
<button class="filter-trigger-button button-unstyled">
|
||||||
<FAIcon icon="filter" />
|
<FAIcon icon="filter" />
|
||||||
</button>
|
</button>
|
||||||
|
@ -1,5 +1,8 @@
|
|||||||
<template>
|
<template>
|
||||||
<teleport :disabled="minimalMode || disableTeleport" :to="teleportTarget">
|
<teleport
|
||||||
|
:disabled="minimalMode || disableTeleport"
|
||||||
|
:to="teleportTarget"
|
||||||
|
>
|
||||||
<div
|
<div
|
||||||
:class="{ minimal: minimalMode }"
|
:class="{ minimal: minimalMode }"
|
||||||
class="Notifications"
|
class="Notifications"
|
||||||
|
@ -104,18 +104,22 @@ const Popover = {
|
|||||||
|
|
||||||
// What are the screen bounds for the popover? Viewport vs container
|
// What are the screen bounds for the popover? Viewport vs container
|
||||||
// when using viewport, using default margin values to dodge the navbar
|
// when using viewport, using default margin values to dodge the navbar
|
||||||
const xBounds = this.boundTo && this.boundTo.x === 'container' ? {
|
const xBounds = this.boundTo && this.boundTo.x === 'container'
|
||||||
|
? {
|
||||||
min: parentScreenBox.left + (margin.left || 0),
|
min: parentScreenBox.left + (margin.left || 0),
|
||||||
max: parentScreenBox.right - (margin.right || 0)
|
max: parentScreenBox.right - (margin.right || 0)
|
||||||
} : {
|
}
|
||||||
|
: {
|
||||||
min: 0 + (margin.left || 10),
|
min: 0 + (margin.left || 10),
|
||||||
max: window.innerWidth - (margin.right || 10)
|
max: window.innerWidth - (margin.right || 10)
|
||||||
}
|
}
|
||||||
|
|
||||||
const yBounds = this.boundTo && this.boundTo.y === 'container' ? {
|
const yBounds = this.boundTo && this.boundTo.y === 'container'
|
||||||
|
? {
|
||||||
min: parentScreenBox.top + (margin.top || 0),
|
min: parentScreenBox.top + (margin.top || 0),
|
||||||
max: parentScreenBox.bottom - (margin.bottom || 0)
|
max: parentScreenBox.bottom - (margin.bottom || 0)
|
||||||
} : {
|
}
|
||||||
|
: {
|
||||||
min: 0 + (margin.top || 50),
|
min: 0 + (margin.top || 50),
|
||||||
max: window.innerHeight - (margin.bottom || 5)
|
max: window.innerHeight - (margin.bottom || 5)
|
||||||
}
|
}
|
||||||
|
@ -41,7 +41,7 @@ const buildMentionsString = ({ user, attentions = [] }, currentUser) => {
|
|||||||
allAttentions = uniqBy(allAttentions, 'id')
|
allAttentions = uniqBy(allAttentions, 'id')
|
||||||
allAttentions = reject(allAttentions, { id: currentUser.id })
|
allAttentions = reject(allAttentions, { id: currentUser.id })
|
||||||
|
|
||||||
let mentions = map(allAttentions, (attention) => {
|
const mentions = map(allAttentions, (attention) => {
|
||||||
return `@${attention.screen_name}`
|
return `@${attention.screen_name}`
|
||||||
})
|
})
|
||||||
|
|
||||||
@ -242,7 +242,7 @@ const PostStatusForm = {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
'newStatus': {
|
newStatus: {
|
||||||
deep: true,
|
deep: true,
|
||||||
handler () {
|
handler () {
|
||||||
this.statusChanged()
|
this.statusChanged()
|
||||||
@ -273,7 +273,7 @@ const PostStatusForm = {
|
|||||||
this.$refs.textarea.focus()
|
this.$refs.textarea.focus()
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
let el = this.$el.querySelector('textarea')
|
const el = this.$el.querySelector('textarea')
|
||||||
el.style.height = 'auto'
|
el.style.height = 'auto'
|
||||||
el.style.height = undefined
|
el.style.height = undefined
|
||||||
this.error = null
|
this.error = null
|
||||||
@ -392,7 +392,7 @@ const PostStatusForm = {
|
|||||||
this.$emit('resize', { delayed: true })
|
this.$emit('resize', { delayed: true })
|
||||||
},
|
},
|
||||||
removeMediaFile (fileInfo) {
|
removeMediaFile (fileInfo) {
|
||||||
let index = this.newStatus.files.indexOf(fileInfo)
|
const index = this.newStatus.files.indexOf(fileInfo)
|
||||||
this.newStatus.files.splice(index, 1)
|
this.newStatus.files.splice(index, 1)
|
||||||
this.$emit('resize')
|
this.$emit('resize')
|
||||||
},
|
},
|
||||||
@ -462,7 +462,7 @@ const PostStatusForm = {
|
|||||||
},
|
},
|
||||||
onEmojiInputInput (e) {
|
onEmojiInputInput (e) {
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.resize(this.$refs['textarea'])
|
this.resize(this.$refs.textarea)
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
resize (e) {
|
resize (e) {
|
||||||
@ -477,8 +477,8 @@ const PostStatusForm = {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
const formRef = this.$refs['form']
|
const formRef = this.$refs.form
|
||||||
const bottomRef = this.$refs['bottom']
|
const bottomRef = this.$refs.bottom
|
||||||
/* Scroller is either `window` (replies in TL), sidebar (main post form,
|
/* Scroller is either `window` (replies in TL), sidebar (main post form,
|
||||||
* replies in notifs) or mobile post form. Note that getting and setting
|
* replies in notifs) or mobile post form. Note that getting and setting
|
||||||
* scroll is different for `Window` and `Element`s
|
* scroll is different for `Window` and `Element`s
|
||||||
@ -564,7 +564,7 @@ const PostStatusForm = {
|
|||||||
this.$refs['emoji-input'].resize()
|
this.$refs['emoji-input'].resize()
|
||||||
},
|
},
|
||||||
showEmojiPicker () {
|
showEmojiPicker () {
|
||||||
this.$refs['textarea'].focus()
|
this.$refs.textarea.focus()
|
||||||
this.$refs['emoji-input'].triggerShowPicker()
|
this.$refs['emoji-input'].triggerShowPicker()
|
||||||
},
|
},
|
||||||
clearError () {
|
clearError () {
|
||||||
|
@ -45,7 +45,7 @@ const ReactButton = {
|
|||||||
emojis () {
|
emojis () {
|
||||||
if (this.filterWord !== '') {
|
if (this.filterWord !== '') {
|
||||||
const filterWordLowercase = trim(this.filterWord.toLowerCase())
|
const filterWordLowercase = trim(this.filterWord.toLowerCase())
|
||||||
let orderedEmojiList = []
|
const orderedEmojiList = []
|
||||||
for (const emoji of this.$store.state.instance.emoji) {
|
for (const emoji of this.$store.state.instance.emoji) {
|
||||||
if (emoji.replacement === this.filterWord) return [emoji]
|
if (emoji.replacement === this.filterWord) return [emoji]
|
||||||
|
|
||||||
|
@ -9,13 +9,13 @@
|
|||||||
popover-class="ReactButton popover-default"
|
popover-class="ReactButton popover-default"
|
||||||
@show="focusInput"
|
@show="focusInput"
|
||||||
>
|
>
|
||||||
<template v-slot:content="{close}">
|
<template #content="{close}">
|
||||||
<div class="reaction-picker-filter">
|
<div class="reaction-picker-filter">
|
||||||
<input
|
<input
|
||||||
v-model="filterWord"
|
v-model="filterWord"
|
||||||
@input="$event.target.composing = false"
|
|
||||||
size="1"
|
size="1"
|
||||||
:placeholder="$t('emoji.search_emoji')"
|
:placeholder="$t('emoji.search_emoji')"
|
||||||
|
@input="$event.target.composing = false"
|
||||||
>
|
>
|
||||||
</div>
|
</div>
|
||||||
<div class="reaction-picker">
|
<div class="reaction-picker">
|
||||||
@ -41,7 +41,7 @@
|
|||||||
<div class="reaction-bottom-fader" />
|
<div class="reaction-bottom-fader" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:trigger>
|
<template #trigger>
|
||||||
<span
|
<span
|
||||||
class="button-unstyled popover-trigger"
|
class="button-unstyled popover-trigger"
|
||||||
:title="$t('tool_tip.add_reaction')"
|
:title="$t('tool_tip.add_reaction')"
|
||||||
@ -55,7 +55,7 @@
|
|||||||
</Popover>
|
</Popover>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./react_button.js" ></script>
|
<script src="./react_button.js"></script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
@import '../../_variables.scss';
|
@import '../../_variables.scss';
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
export default {
|
export default {
|
||||||
props: [ 'user' ],
|
props: ['user'],
|
||||||
computed: {
|
computed: {
|
||||||
subscribeUrl () {
|
subscribeUrl () {
|
||||||
// eslint-disable-next-line no-undef
|
// eslint-disable-next-line no-undef
|
||||||
|
@ -36,7 +36,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./retweet_button.js" ></script>
|
<script src="./retweet_button.js"></script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
@import '../../_variables.scss';
|
@import '../../_variables.scss';
|
||||||
|
@ -16,7 +16,7 @@ const SearchBar = {
|
|||||||
error: false
|
error: false
|
||||||
}),
|
}),
|
||||||
watch: {
|
watch: {
|
||||||
'$route': function (route) {
|
$route: function (route) {
|
||||||
if (route.name === 'search') {
|
if (route.name === 'search') {
|
||||||
this.searchTerm = route.query.query
|
this.searchTerm = route.query.query
|
||||||
}
|
}
|
||||||
|
@ -24,7 +24,7 @@
|
|||||||
:items="items"
|
:items="items"
|
||||||
:get-key="getKey"
|
:get-key="getKey"
|
||||||
>
|
>
|
||||||
<template v-slot:item="{item}">
|
<template #item="{item}">
|
||||||
<div
|
<div
|
||||||
class="selectable-list-item-inner"
|
class="selectable-list-item-inner"
|
||||||
:class="{ 'selectable-list-item-selected-inner': isSelected(item) }"
|
:class="{ 'selectable-list-item-selected-inner': isSelected(item) }"
|
||||||
@ -41,7 +41,7 @@
|
|||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:empty>
|
<template #empty>
|
||||||
<slot name="empty" />
|
<slot name="empty" />
|
||||||
</template>
|
</template>
|
||||||
</List>
|
</List>
|
||||||
|
@ -6,14 +6,14 @@
|
|||||||
<Popover
|
<Popover
|
||||||
trigger="hover"
|
trigger="hover"
|
||||||
>
|
>
|
||||||
<template v-slot:trigger>
|
<template #trigger>
|
||||||
|
|
||||||
<FAIcon
|
<FAIcon
|
||||||
icon="wrench"
|
icon="wrench"
|
||||||
:aria-label="$t('settings.setting_changed')"
|
:aria-label="$t('settings.setting_changed')"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:content>
|
<template #content>
|
||||||
<div class="modified-tooltip">
|
<div class="modified-tooltip">
|
||||||
{{ $t('settings.setting_changed') }}
|
{{ $t('settings.setting_changed') }}
|
||||||
</div>
|
</div>
|
||||||
|
@ -6,14 +6,14 @@
|
|||||||
<Popover
|
<Popover
|
||||||
trigger="hover"
|
trigger="hover"
|
||||||
>
|
>
|
||||||
<template v-slot:trigger>
|
<template #trigger>
|
||||||
|
|
||||||
<FAIcon
|
<FAIcon
|
||||||
icon="server"
|
icon="server"
|
||||||
:aria-label="$t('settings.setting_server_side')"
|
:aria-label="$t('settings.setting_server_side')"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:content>
|
<template #content>
|
||||||
<div class="serverside-tooltip">
|
<div class="serverside-tooltip">
|
||||||
{{ $t('settings.setting_server_side') }}
|
{{ $t('settings.setting_server_side') }}
|
||||||
</div>
|
</div>
|
||||||
|
@ -53,7 +53,7 @@
|
|||||||
:bound-to="{ x: 'container' }"
|
:bound-to="{ x: 'container' }"
|
||||||
remove-padding
|
remove-padding
|
||||||
>
|
>
|
||||||
<template v-slot:trigger>
|
<template #trigger>
|
||||||
<button
|
<button
|
||||||
class="btn button-default"
|
class="btn button-default"
|
||||||
:title="$t('general.close')"
|
:title="$t('general.close')"
|
||||||
@ -65,7 +65,7 @@
|
|||||||
/>
|
/>
|
||||||
</button>
|
</button>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:content="{close}">
|
<template #content="{close}">
|
||||||
<div class="dropdown-menu">
|
<div class="dropdown-menu">
|
||||||
<button
|
<button
|
||||||
class="button-default dropdown-item dropdown-item-icon"
|
class="button-default dropdown-item dropdown-item-icon"
|
||||||
|
@ -75,12 +75,18 @@
|
|||||||
</BooleanSetting>
|
</BooleanSetting>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<BooleanSetting path="userPopoverZoom" expert="1">
|
<BooleanSetting
|
||||||
|
path="userPopoverZoom"
|
||||||
|
expert="1"
|
||||||
|
>
|
||||||
{{ $t('settings.user_popover_avatar_zoom') }}
|
{{ $t('settings.user_popover_avatar_zoom') }}
|
||||||
</BooleanSetting>
|
</BooleanSetting>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<BooleanSetting path="userPopoverOverlay" expert="1">
|
<BooleanSetting
|
||||||
|
path="userPopoverOverlay"
|
||||||
|
expert="1"
|
||||||
|
>
|
||||||
{{ $t('settings.user_popover_avatar_overlay') }}
|
{{ $t('settings.user_popover_avatar_overlay') }}
|
||||||
</BooleanSetting>
|
</BooleanSetting>
|
||||||
</li>
|
</li>
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
:query="queryUserIds"
|
:query="queryUserIds"
|
||||||
:placeholder="$t('settings.search_user_to_block')"
|
:placeholder="$t('settings.search_user_to_block')"
|
||||||
>
|
>
|
||||||
<template v-slot="row">
|
<template #default="row">
|
||||||
<BlockCard
|
<BlockCard
|
||||||
:user-id="row.item"
|
:user-id="row.item"
|
||||||
/>
|
/>
|
||||||
@ -21,7 +21,7 @@
|
|||||||
:refresh="true"
|
:refresh="true"
|
||||||
:get-key="i => i"
|
:get-key="i => i"
|
||||||
>
|
>
|
||||||
<template v-slot:header="{selected}">
|
<template #header="{selected}">
|
||||||
<div class="bulk-actions">
|
<div class="bulk-actions">
|
||||||
<ProgressButton
|
<ProgressButton
|
||||||
v-if="selected.length > 0"
|
v-if="selected.length > 0"
|
||||||
@ -29,7 +29,7 @@
|
|||||||
:click="() => blockUsers(selected)"
|
:click="() => blockUsers(selected)"
|
||||||
>
|
>
|
||||||
{{ $t('user_card.block') }}
|
{{ $t('user_card.block') }}
|
||||||
<template v-slot:progress>
|
<template #progress>
|
||||||
{{ $t('user_card.block_progress') }}
|
{{ $t('user_card.block_progress') }}
|
||||||
</template>
|
</template>
|
||||||
</ProgressButton>
|
</ProgressButton>
|
||||||
@ -39,16 +39,16 @@
|
|||||||
:click="() => unblockUsers(selected)"
|
:click="() => unblockUsers(selected)"
|
||||||
>
|
>
|
||||||
{{ $t('user_card.unblock') }}
|
{{ $t('user_card.unblock') }}
|
||||||
<template v-slot:progress>
|
<template #progress>
|
||||||
{{ $t('user_card.unblock_progress') }}
|
{{ $t('user_card.unblock_progress') }}
|
||||||
</template>
|
</template>
|
||||||
</ProgressButton>
|
</ProgressButton>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:item="{item}">
|
<template #item="{item}">
|
||||||
<BlockCard :user-id="item" />
|
<BlockCard :user-id="item" />
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:empty>
|
<template #empty>
|
||||||
{{ $t('settings.no_blocks') }}
|
{{ $t('settings.no_blocks') }}
|
||||||
</template>
|
</template>
|
||||||
</BlockList>
|
</BlockList>
|
||||||
@ -63,7 +63,7 @@
|
|||||||
:query="queryUserIds"
|
:query="queryUserIds"
|
||||||
:placeholder="$t('settings.search_user_to_mute')"
|
:placeholder="$t('settings.search_user_to_mute')"
|
||||||
>
|
>
|
||||||
<template v-slot="row">
|
<template #default="row">
|
||||||
<MuteCard
|
<MuteCard
|
||||||
:user-id="row.item"
|
:user-id="row.item"
|
||||||
/>
|
/>
|
||||||
@ -74,7 +74,7 @@
|
|||||||
:refresh="true"
|
:refresh="true"
|
||||||
:get-key="i => i"
|
:get-key="i => i"
|
||||||
>
|
>
|
||||||
<template v-slot:header="{selected}">
|
<template #header="{selected}">
|
||||||
<div class="bulk-actions">
|
<div class="bulk-actions">
|
||||||
<ProgressButton
|
<ProgressButton
|
||||||
v-if="selected.length > 0"
|
v-if="selected.length > 0"
|
||||||
@ -82,7 +82,7 @@
|
|||||||
:click="() => muteUsers(selected)"
|
:click="() => muteUsers(selected)"
|
||||||
>
|
>
|
||||||
{{ $t('user_card.mute') }}
|
{{ $t('user_card.mute') }}
|
||||||
<template v-slot:progress>
|
<template #progress>
|
||||||
{{ $t('user_card.mute_progress') }}
|
{{ $t('user_card.mute_progress') }}
|
||||||
</template>
|
</template>
|
||||||
</ProgressButton>
|
</ProgressButton>
|
||||||
@ -92,16 +92,16 @@
|
|||||||
:click="() => unmuteUsers(selected)"
|
:click="() => unmuteUsers(selected)"
|
||||||
>
|
>
|
||||||
{{ $t('user_card.unmute') }}
|
{{ $t('user_card.unmute') }}
|
||||||
<template v-slot:progress>
|
<template #progress>
|
||||||
{{ $t('user_card.unmute_progress') }}
|
{{ $t('user_card.unmute_progress') }}
|
||||||
</template>
|
</template>
|
||||||
</ProgressButton>
|
</ProgressButton>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:item="{item}">
|
<template #item="{item}">
|
||||||
<MuteCard :user-id="item" />
|
<MuteCard :user-id="item" />
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:empty>
|
<template #empty>
|
||||||
{{ $t('settings.no_mutes') }}
|
{{ $t('settings.no_mutes') }}
|
||||||
</template>
|
</template>
|
||||||
</MuteList>
|
</MuteList>
|
||||||
@ -114,7 +114,7 @@
|
|||||||
:query="queryKnownDomains"
|
:query="queryKnownDomains"
|
||||||
:placeholder="$t('settings.type_domains_to_mute')"
|
:placeholder="$t('settings.type_domains_to_mute')"
|
||||||
>
|
>
|
||||||
<template v-slot="row">
|
<template #default="row">
|
||||||
<DomainMuteCard
|
<DomainMuteCard
|
||||||
:domain="row.item"
|
:domain="row.item"
|
||||||
/>
|
/>
|
||||||
@ -125,7 +125,7 @@
|
|||||||
:refresh="true"
|
:refresh="true"
|
||||||
:get-key="i => i"
|
:get-key="i => i"
|
||||||
>
|
>
|
||||||
<template v-slot:header="{selected}">
|
<template #header="{selected}">
|
||||||
<div class="bulk-actions">
|
<div class="bulk-actions">
|
||||||
<ProgressButton
|
<ProgressButton
|
||||||
v-if="selected.length > 0"
|
v-if="selected.length > 0"
|
||||||
@ -133,16 +133,16 @@
|
|||||||
:click="() => unmuteDomains(selected)"
|
:click="() => unmuteDomains(selected)"
|
||||||
>
|
>
|
||||||
{{ $t('domain_mute_card.unmute') }}
|
{{ $t('domain_mute_card.unmute') }}
|
||||||
<template v-slot:progress>
|
<template #progress>
|
||||||
{{ $t('domain_mute_card.unmute_progress') }}
|
{{ $t('domain_mute_card.unmute_progress') }}
|
||||||
</template>
|
</template>
|
||||||
</ProgressButton>
|
</ProgressButton>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:item="{item}">
|
<template #item="{item}">
|
||||||
<DomainMuteCard :domain="item" />
|
<DomainMuteCard :domain="item" />
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:empty>
|
<template #empty>
|
||||||
{{ $t('settings.no_mutes') }}
|
{{ $t('settings.no_mutes') }}
|
||||||
</template>
|
</template>
|
||||||
</DomainMuteList>
|
</DomainMuteList>
|
||||||
|
@ -71,10 +71,12 @@ const ProfileTab = {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
emojiSuggestor () {
|
emojiSuggestor () {
|
||||||
return suggestor({ emoji: [
|
return suggestor({
|
||||||
|
emoji: [
|
||||||
...this.$store.state.instance.emoji,
|
...this.$store.state.instance.emoji,
|
||||||
...this.$store.state.instance.customEmoji
|
...this.$store.state.instance.customEmoji
|
||||||
] })
|
]
|
||||||
|
})
|
||||||
},
|
},
|
||||||
userSuggestor () {
|
userSuggestor () {
|
||||||
return suggestor({ store: this.$store })
|
return suggestor({ store: this.$store })
|
||||||
|
@ -117,8 +117,8 @@
|
|||||||
<button
|
<button
|
||||||
v-if="!isDefaultAvatar && pickAvatarBtnVisible"
|
v-if="!isDefaultAvatar && pickAvatarBtnVisible"
|
||||||
:title="$t('settings.reset_avatar')"
|
:title="$t('settings.reset_avatar')"
|
||||||
@click="resetAvatar"
|
|
||||||
class="button-unstyled reset-button"
|
class="button-unstyled reset-button"
|
||||||
|
@click="resetAvatar"
|
||||||
>
|
>
|
||||||
<FAIcon
|
<FAIcon
|
||||||
icon="times"
|
icon="times"
|
||||||
|
@ -32,8 +32,8 @@ const Mfa = {
|
|||||||
components: {
|
components: {
|
||||||
'recovery-codes': RecoveryCodes,
|
'recovery-codes': RecoveryCodes,
|
||||||
'totp-item': TOTP,
|
'totp-item': TOTP,
|
||||||
'qrcode': VueQrcode,
|
qrcode: VueQrcode,
|
||||||
'confirm': Confirm
|
confirm: Confirm
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
canSetupOTP () {
|
canSetupOTP () {
|
||||||
@ -139,7 +139,7 @@ const Mfa = {
|
|||||||
|
|
||||||
// fetch settings from server
|
// fetch settings from server
|
||||||
async fetchSettings () {
|
async fetchSettings () {
|
||||||
let result = await this.backendInteractor.settingsMFA()
|
const result = await this.backendInteractor.settingsMFA()
|
||||||
if (result.error) return
|
if (result.error) return
|
||||||
this.settings = result.settings
|
this.settings = result.settings
|
||||||
this.settings.available = true
|
this.settings.available = true
|
||||||
|
@ -10,7 +10,7 @@ export default {
|
|||||||
inProgress: false // progress peform request to disable otp method
|
inProgress: false // progress peform request to disable otp method
|
||||||
}),
|
}),
|
||||||
components: {
|
components: {
|
||||||
'confirm': Confirm
|
confirm: Confirm
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
isActivated () {
|
isActivated () {
|
||||||
|
@ -13,7 +13,7 @@ const SecurityTab = {
|
|||||||
deletingAccount: false,
|
deletingAccount: false,
|
||||||
deleteAccountConfirmPasswordInput: '',
|
deleteAccountConfirmPasswordInput: '',
|
||||||
deleteAccountError: false,
|
deleteAccountError: false,
|
||||||
changePasswordInputs: [ '', '', '' ],
|
changePasswordInputs: ['', '', ''],
|
||||||
changedPassword: false,
|
changedPassword: false,
|
||||||
changePasswordError: false,
|
changePasswordError: false,
|
||||||
moveAccountTarget: '',
|
moveAccountTarget: '',
|
||||||
|
@ -29,7 +29,10 @@
|
|||||||
{{ $t('settings.style.preview.content') }}
|
{{ $t('settings.style.preview.content') }}
|
||||||
</h4>
|
</h4>
|
||||||
|
|
||||||
<i18n-t scope="global" keypath="settings.style.preview.text">
|
<i18n-t
|
||||||
|
scope="global"
|
||||||
|
keypath="settings.style.preview.text"
|
||||||
|
>
|
||||||
<code style="font-family: var(--postCodeFont)">
|
<code style="font-family: var(--postCodeFont)">
|
||||||
{{ $t('settings.style.preview.mono') }}
|
{{ $t('settings.style.preview.mono') }}
|
||||||
</code>
|
</code>
|
||||||
|
@ -95,11 +95,11 @@ export default {
|
|||||||
|
|
||||||
...Object.keys(SLOT_INHERITANCE)
|
...Object.keys(SLOT_INHERITANCE)
|
||||||
.map(key => [key, ''])
|
.map(key => [key, ''])
|
||||||
.reduce((acc, [key, val]) => ({ ...acc, [ key + 'ColorLocal' ]: val }), {}),
|
.reduce((acc, [key, val]) => ({ ...acc, [key + 'ColorLocal']: val }), {}),
|
||||||
|
|
||||||
...Object.keys(OPACITIES)
|
...Object.keys(OPACITIES)
|
||||||
.map(key => [key, ''])
|
.map(key => [key, ''])
|
||||||
.reduce((acc, [key, val]) => ({ ...acc, [ key + 'OpacityLocal' ]: val }), {}),
|
.reduce((acc, [key, val]) => ({ ...acc, [key + 'OpacityLocal']: val }), {}),
|
||||||
|
|
||||||
shadowSelected: undefined,
|
shadowSelected: undefined,
|
||||||
shadowsLocal: {},
|
shadowsLocal: {},
|
||||||
@ -212,12 +212,12 @@ export default {
|
|||||||
currentColors () {
|
currentColors () {
|
||||||
return Object.keys(SLOT_INHERITANCE)
|
return Object.keys(SLOT_INHERITANCE)
|
||||||
.map(key => [key, this[key + 'ColorLocal']])
|
.map(key => [key, this[key + 'ColorLocal']])
|
||||||
.reduce((acc, [key, val]) => ({ ...acc, [ key ]: val }), {})
|
.reduce((acc, [key, val]) => ({ ...acc, [key]: val }), {})
|
||||||
},
|
},
|
||||||
currentOpacity () {
|
currentOpacity () {
|
||||||
return Object.keys(OPACITIES)
|
return Object.keys(OPACITIES)
|
||||||
.map(key => [key, this[key + 'OpacityLocal']])
|
.map(key => [key, this[key + 'OpacityLocal']])
|
||||||
.reduce((acc, [key, val]) => ({ ...acc, [ key ]: val }), {})
|
.reduce((acc, [key, val]) => ({ ...acc, [key]: val }), {})
|
||||||
},
|
},
|
||||||
currentRadii () {
|
currentRadii () {
|
||||||
return {
|
return {
|
||||||
|
@ -112,9 +112,11 @@ export default {
|
|||||||
return hex2rgb(this.selected.color)
|
return hex2rgb(this.selected.color)
|
||||||
},
|
},
|
||||||
style () {
|
style () {
|
||||||
return this.ready ? {
|
return this.ready
|
||||||
|
? {
|
||||||
boxShadow: getCssShadow(this.fallback)
|
boxShadow: getCssShadow(this.fallback)
|
||||||
} : {}
|
}
|
||||||
|
: {}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -215,7 +215,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./shadow_control.js" ></script>
|
<script src="./shadow_control.js"></script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
@import '../../_variables.scss';
|
@import '../../_variables.scss';
|
||||||
|
@ -11,7 +11,7 @@ library.add(
|
|||||||
)
|
)
|
||||||
|
|
||||||
const shoutPanel = {
|
const shoutPanel = {
|
||||||
props: [ 'floating' ],
|
props: ['floating'],
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
currentMessage: '',
|
currentMessage: '',
|
||||||
|
@ -32,7 +32,7 @@ library.add(
|
|||||||
)
|
)
|
||||||
|
|
||||||
const SideDrawer = {
|
const SideDrawer = {
|
||||||
props: [ 'logout' ],
|
props: ['logout'],
|
||||||
data: () => ({
|
data: () => ({
|
||||||
closed: true,
|
closed: true,
|
||||||
closeGesture: undefined
|
closeGesture: undefined
|
||||||
|
@ -204,7 +204,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./side_drawer.js" ></script>
|
<script src="./side_drawer.js"></script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
@import '../../_variables.scss';
|
@import '../../_variables.scss';
|
||||||
|
@ -17,8 +17,8 @@ const StaffPanel = {
|
|||||||
const groupedStaffAccounts = groupBy(staffAccounts, 'role')
|
const groupedStaffAccounts = groupBy(staffAccounts, 'role')
|
||||||
|
|
||||||
return [
|
return [
|
||||||
{ role: 'admin', users: groupedStaffAccounts['admin'] },
|
{ role: 'admin', users: groupedStaffAccounts.admin },
|
||||||
{ role: 'moderator', users: groupedStaffAccounts['moderator'] }
|
{ role: 'moderator', users: groupedStaffAccounts.moderator }
|
||||||
].filter(group => group.users)
|
].filter(group => group.users)
|
||||||
},
|
},
|
||||||
...mapGetters([
|
...mapGetters([
|
||||||
|
@ -24,7 +24,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./staff_panel.js" ></script>
|
<script src="./staff_panel.js"></script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
|
|
||||||
|
@ -448,7 +448,7 @@ const Status = {
|
|||||||
scrollIfHighlighted (highlightId) {
|
scrollIfHighlighted (highlightId) {
|
||||||
const id = highlightId
|
const id = highlightId
|
||||||
if (this.status.id === id) {
|
if (this.status.id === id) {
|
||||||
let rect = this.$el.getBoundingClientRect()
|
const rect = this.$el.getBoundingClientRect()
|
||||||
if (rect.top < 100) {
|
if (rect.top < 100) {
|
||||||
// Post is above screen, match its top to screen top
|
// Post is above screen, match its top to screen top
|
||||||
window.scrollBy(0, rect.top - 100)
|
window.scrollBy(0, rect.top - 100)
|
||||||
@ -463,7 +463,7 @@ const Status = {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
'highlight': function (id) {
|
highlight: function (id) {
|
||||||
this.scrollIfHighlighted(id)
|
this.scrollIfHighlighted(id)
|
||||||
},
|
},
|
||||||
'status.repeat_num': function (num) {
|
'status.repeat_num': function (num) {
|
||||||
@ -478,7 +478,7 @@ const Status = {
|
|||||||
this.$store.dispatch('fetchFavs', this.status.id)
|
this.$store.dispatch('fetchFavs', this.status.id)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
'isSuspendable': function (val) {
|
isSuspendable: function (val) {
|
||||||
this.suspendable = val
|
this.suspendable = val
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -122,10 +122,13 @@
|
|||||||
v-if="!noHeading"
|
v-if="!noHeading"
|
||||||
class="left-side"
|
class="left-side"
|
||||||
>
|
>
|
||||||
<a :href="$router.resolve(userProfileLink).href" @click.prevent>
|
<a
|
||||||
|
:href="$router.resolve(userProfileLink).href"
|
||||||
|
@click.prevent
|
||||||
|
>
|
||||||
<UserPopover
|
<UserPopover
|
||||||
:userId="status.user.id"
|
:user-id="status.user.id"
|
||||||
:overlayCenters="true"
|
:overlay-centers="true"
|
||||||
>
|
>
|
||||||
<UserAvatar
|
<UserAvatar
|
||||||
class="post-avatar"
|
class="post-avatar"
|
||||||
@ -488,6 +491,6 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./status.js" ></script>
|
<script src="./status.js"></script>
|
||||||
|
|
||||||
<style src="./status.scss" lang="scss"></style>
|
<style src="./status.scss" lang="scss"></style>
|
||||||
|
@ -96,5 +96,5 @@
|
|||||||
<slot v-if="!hideSubjectStatus" />
|
<slot v-if="!hideSubjectStatus" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script src="./status_body.js" ></script>
|
<script src="./status_body.js"></script>
|
||||||
<style lang="scss" src="./status_body.scss" />
|
<style lang="scss" src="./status_body.scss" />
|
||||||
|
@ -56,7 +56,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./status_content.js" ></script>
|
<script src="./status_content.js"></script>
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
.StatusContent {
|
.StatusContent {
|
||||||
flex: 1;
|
flex: 1;
|
||||||
|
@ -1,16 +1,16 @@
|
|||||||
<template>
|
<template>
|
||||||
<Popover
|
<Popover
|
||||||
|
ref="popover"
|
||||||
trigger="hover"
|
trigger="hover"
|
||||||
:stay-on-click="true"
|
:stay-on-click="true"
|
||||||
popover-class="popover-default status-popover"
|
popover-class="popover-default status-popover"
|
||||||
:bound-to="{ x: 'container' }"
|
:bound-to="{ x: 'container' }"
|
||||||
@show="enter"
|
@show="enter"
|
||||||
ref="popover"
|
|
||||||
>
|
>
|
||||||
<template v-slot:trigger>
|
<template #trigger>
|
||||||
<slot />
|
<slot />
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:content>
|
<template #content>
|
||||||
<Status
|
<Status
|
||||||
v-if="status"
|
v-if="status"
|
||||||
:is-preview="true"
|
:is-preview="true"
|
||||||
@ -37,7 +37,7 @@
|
|||||||
</Popover>
|
</Popover>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./status_popover.js" ></script>
|
<script src="./status_popover.js"></script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
@import '../../_variables.scss';
|
@import '../../_variables.scss';
|
||||||
|
@ -31,8 +31,8 @@ const StickerPicker = {
|
|||||||
fetch(sticker)
|
fetch(sticker)
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
res.blob().then((blob) => {
|
res.blob().then((blob) => {
|
||||||
var file = new File([blob], name, { mimetype: 'image/png' })
|
const file = new File([blob], name, { mimetype: 'image/png' })
|
||||||
var formData = new FormData()
|
const formData = new FormData()
|
||||||
formData.append('file', file)
|
formData.append('file', file)
|
||||||
statusPosterService.uploadMedia({ store, formData })
|
statusPosterService.uploadMedia({ store, formData })
|
||||||
.then((fileData) => {
|
.then((fileData) => {
|
||||||
|
@ -13,7 +13,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./terms_of_service_panel.js" ></script>
|
<script src="./terms_of_service_panel.js"></script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
.tos-content {
|
.tos-content {
|
||||||
|
@ -46,7 +46,10 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div :class="classes.footer">
|
<div :class="classes.footer">
|
||||||
<teleport :to="footerSlipgate" :disabled="!embedded || !footerSlipgate">
|
<teleport
|
||||||
|
:to="footerSlipgate"
|
||||||
|
:disabled="!embedded || !footerSlipgate"
|
||||||
|
>
|
||||||
<div
|
<div
|
||||||
v-if="count===0"
|
v-if="count===0"
|
||||||
class="new-status-notification text-center faint"
|
class="new-status-notification text-center faint"
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
class="TimelineQuickSettings"
|
class="TimelineQuickSettings"
|
||||||
:bound-to="{ x: 'container' }"
|
:bound-to="{ x: 'container' }"
|
||||||
>
|
>
|
||||||
<template v-slot:content>
|
<template #content>
|
||||||
<div class="dropdown-menu">
|
<div class="dropdown-menu">
|
||||||
<div v-if="loggedIn">
|
<div v-if="loggedIn">
|
||||||
<button
|
<button
|
||||||
@ -80,7 +80,7 @@
|
|||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:trigger>
|
<template #trigger>
|
||||||
<button class="button-unstyled">
|
<button class="button-unstyled">
|
||||||
<FAIcon icon="filter" />
|
<FAIcon icon="filter" />
|
||||||
</button>
|
</button>
|
||||||
|
@ -11,9 +11,9 @@ library.add(faChevronDown)
|
|||||||
// because nav panel benefits from the same information.
|
// because nav panel benefits from the same information.
|
||||||
export const timelineNames = () => {
|
export const timelineNames = () => {
|
||||||
return {
|
return {
|
||||||
'friends': 'nav.home_timeline',
|
friends: 'nav.home_timeline',
|
||||||
'bookmarks': 'nav.bookmarks',
|
bookmarks: 'nav.bookmarks',
|
||||||
'dms': 'nav.dms',
|
dms: 'nav.dms',
|
||||||
'public-timeline': 'nav.public_tl',
|
'public-timeline': 'nav.public_tl',
|
||||||
'public-external-timeline': 'nav.twkn'
|
'public-external-timeline': 'nav.twkn'
|
||||||
}
|
}
|
||||||
|
@ -9,10 +9,10 @@
|
|||||||
@show="openMenu"
|
@show="openMenu"
|
||||||
@close="() => isOpen = false"
|
@close="() => isOpen = false"
|
||||||
>
|
>
|
||||||
<template v-slot:content>
|
<template #content>
|
||||||
<TimelineMenuContent />
|
<TimelineMenuContent />
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:trigger>
|
<template #trigger>
|
||||||
<span class="button-unstyled title timeline-menu-title">
|
<span class="button-unstyled title timeline-menu-title">
|
||||||
<span class="timeline-title">{{ timelineName() }}</span>
|
<span class="timeline-title">{{ timelineName() }}</span>
|
||||||
<span>
|
<span>
|
||||||
@ -30,7 +30,7 @@
|
|||||||
</Popover>
|
</Popover>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./timeline_menu.js" ></script>
|
<script src="./timeline_menu.js"></script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
@import '../../_variables.scss';
|
@import '../../_variables.scss';
|
||||||
|
@ -63,4 +63,4 @@
|
|||||||
</ul>
|
</ul>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./timeline_menu_content.js" ></script>
|
<script src="./timeline_menu_content.js"></script>
|
||||||
|
@ -67,7 +67,7 @@ export default {
|
|||||||
style () {
|
style () {
|
||||||
return {
|
return {
|
||||||
backgroundImage: [
|
backgroundImage: [
|
||||||
`linear-gradient(to bottom, var(--profileTint), var(--profileTint))`,
|
'linear-gradient(to bottom, var(--profileTint), var(--profileTint))',
|
||||||
`url(${this.user.cover_photo})`
|
`url(${this.user.cover_photo})`
|
||||||
].join(', ')
|
].join(', ')
|
||||||
}
|
}
|
||||||
|
@ -29,10 +29,10 @@
|
|||||||
</a>
|
</a>
|
||||||
<UserAvatar
|
<UserAvatar
|
||||||
v-else-if="typeof avatarAction === 'function'"
|
v-else-if="typeof avatarAction === 'function'"
|
||||||
@click="avatarAction"
|
|
||||||
class="user-info-avatar"
|
class="user-info-avatar"
|
||||||
:better-shadow="betterShadow"
|
:better-shadow="betterShadow"
|
||||||
:user="user"
|
:user="user"
|
||||||
|
@click="avatarAction"
|
||||||
/>
|
/>
|
||||||
<router-link
|
<router-link
|
||||||
v-else
|
v-else
|
||||||
|
@ -4,10 +4,10 @@
|
|||||||
placement="top"
|
placement="top"
|
||||||
:offset="{ y: 5 }"
|
:offset="{ y: 5 }"
|
||||||
>
|
>
|
||||||
<template v-slot:trigger>
|
<template #trigger>
|
||||||
<slot />
|
<slot />
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:content>
|
<template #content>
|
||||||
<div class="user-list-popover">
|
<div class="user-list-popover">
|
||||||
<template v-if="users.length">
|
<template v-if="users.length">
|
||||||
<div
|
<div
|
||||||
@ -45,7 +45,7 @@
|
|||||||
</Popover>
|
</Popover>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./user_list_popover.js" ></script>
|
<script src="./user_list_popover.js"></script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
@import '../../_variables.scss';
|
@import '../../_variables.scss';
|
||||||
|
@ -1,15 +1,15 @@
|
|||||||
<template>
|
<template>
|
||||||
<Popover
|
<Popover
|
||||||
trigger="click"
|
trigger="click"
|
||||||
popover-class="popover-default user-popover"
|
popover-class="popover-default user-popover"
|
||||||
:overlay-centers-selector="overlayCentersSelector || '.user-info .Avatar'"
|
:overlay-centers-selector="overlayCentersSelector || '.user-info .Avatar'"
|
||||||
:overlay-centers="overlayCenters && userPopoverOverlay"
|
:overlay-centers="overlayCenters && userPopoverOverlay"
|
||||||
:disabled="disabled"
|
:disabled="disabled"
|
||||||
>
|
>
|
||||||
<template v-slot:trigger>
|
<template #trigger>
|
||||||
<slot />
|
<slot />
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:content={close}>
|
<template #content="{close}">
|
||||||
<UserCard
|
<UserCard
|
||||||
class="user-popover"
|
class="user-popover"
|
||||||
:user-id="userId"
|
:user-id="userId"
|
||||||
@ -18,10 +18,10 @@
|
|||||||
:on-close="close"
|
:on-close="close"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
</Popover>
|
</Popover>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./user_popover.js" ></script>
|
<script src="./user_popover.js"></script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
@import '../../_variables.scss';
|
@import '../../_variables.scss';
|
||||||
|
@ -56,7 +56,7 @@
|
|||||||
:user-id="userId"
|
:user-id="userId"
|
||||||
:pinned-status-ids="user.pinnedStatusIds"
|
:pinned-status-ids="user.pinnedStatusIds"
|
||||||
:in-profile="true"
|
:in-profile="true"
|
||||||
:footerSlipgate="footerRef"
|
:footer-slipgate="footerRef"
|
||||||
/>
|
/>
|
||||||
<div
|
<div
|
||||||
v-if="followsTabVisible"
|
v-if="followsTabVisible"
|
||||||
@ -65,7 +65,7 @@
|
|||||||
:disabled="!user.friends_count"
|
:disabled="!user.friends_count"
|
||||||
>
|
>
|
||||||
<FriendList :user-id="userId">
|
<FriendList :user-id="userId">
|
||||||
<template v-slot:item="{item}">
|
<template #item="{item}">
|
||||||
<FollowCard :user="item" />
|
<FollowCard :user="item" />
|
||||||
</template>
|
</template>
|
||||||
</FriendList>
|
</FriendList>
|
||||||
@ -77,7 +77,7 @@
|
|||||||
:disabled="!user.followers_count"
|
:disabled="!user.followers_count"
|
||||||
>
|
>
|
||||||
<FollowerList :user-id="userId">
|
<FollowerList :user-id="userId">
|
||||||
<template v-slot:item="{item}">
|
<template #item="{item}">
|
||||||
<FollowCard
|
<FollowCard
|
||||||
:user="item"
|
:user="item"
|
||||||
:no-follows-you="isUs"
|
:no-follows-you="isUs"
|
||||||
@ -95,7 +95,7 @@
|
|||||||
:timeline="media"
|
:timeline="media"
|
||||||
:user-id="userId"
|
:user-id="userId"
|
||||||
:in-profile="true"
|
:in-profile="true"
|
||||||
:footerSlipgate="footerRef"
|
:footer-slipgate="footerRef"
|
||||||
/>
|
/>
|
||||||
<Timeline
|
<Timeline
|
||||||
v-if="isUs"
|
v-if="isUs"
|
||||||
@ -107,10 +107,13 @@
|
|||||||
timeline-name="favorites"
|
timeline-name="favorites"
|
||||||
:timeline="favorites"
|
:timeline="favorites"
|
||||||
:in-profile="true"
|
:in-profile="true"
|
||||||
:footerSlipgate="footerRef"
|
:footer-slipgate="footerRef"
|
||||||
/>
|
/>
|
||||||
</tab-switcher>
|
</tab-switcher>
|
||||||
<div class="panel-footer" :ref="setFooterRef"></div>
|
<div
|
||||||
|
:ref="setFooterRef"
|
||||||
|
class="panel-footer"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
<div
|
<div
|
||||||
v-else
|
v-else
|
||||||
|
@ -45,7 +45,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="user-reporting-panel-right">
|
<div class="user-reporting-panel-right">
|
||||||
<List :items="statuses">
|
<List :items="statuses">
|
||||||
<template v-slot:item="{item}">
|
<template #item="{item}">
|
||||||
<div class="status-fadein user-reporting-panel-sitem">
|
<div class="status-fadein user-reporting-panel-sitem">
|
||||||
<Status
|
<Status
|
||||||
:in-conversation="false"
|
:in-conversation="false"
|
||||||
|
@ -28,7 +28,7 @@ const WhoToFollow = {
|
|||||||
getWhoToFollow () {
|
getWhoToFollow () {
|
||||||
const credentials = this.$store.state.users.currentUser.credentials
|
const credentials = this.$store.state.users.currentUser.credentials
|
||||||
if (credentials) {
|
if (credentials) {
|
||||||
apiService.suggestions({ credentials: credentials })
|
apiService.suggestions({ credentials })
|
||||||
.then((reply) => {
|
.then((reply) => {
|
||||||
this.showWhoToFollow(reply)
|
this.showWhoToFollow(reply)
|
||||||
})
|
})
|
||||||
|
@ -6,9 +6,9 @@ function showWhoToFollow (panel, reply) {
|
|||||||
const shuffled = shuffle(reply)
|
const shuffled = shuffle(reply)
|
||||||
|
|
||||||
panel.usersToFollow.forEach((toFollow, index) => {
|
panel.usersToFollow.forEach((toFollow, index) => {
|
||||||
let user = shuffled[index]
|
const user = shuffled[index]
|
||||||
let img = user.avatar || this.$store.state.instance.defaultAvatar
|
const img = user.avatar || this.$store.state.instance.defaultAvatar
|
||||||
let name = user.acct
|
const name = user.acct
|
||||||
|
|
||||||
toFollow.img = img
|
toFollow.img = img
|
||||||
toFollow.name = name
|
toFollow.name = name
|
||||||
@ -24,12 +24,12 @@ function showWhoToFollow (panel, reply) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function getWhoToFollow (panel) {
|
function getWhoToFollow (panel) {
|
||||||
var credentials = panel.$store.state.users.currentUser.credentials
|
const credentials = panel.$store.state.users.currentUser.credentials
|
||||||
if (credentials) {
|
if (credentials) {
|
||||||
panel.usersToFollow.forEach(toFollow => {
|
panel.usersToFollow.forEach(toFollow => {
|
||||||
toFollow.name = 'Loading...'
|
toFollow.name = 'Loading...'
|
||||||
})
|
})
|
||||||
apiService.suggestions({ credentials: credentials })
|
apiService.suggestions({ credentials })
|
||||||
.then((reply) => {
|
.then((reply) => {
|
||||||
showWhoToFollow(panel, reply)
|
showWhoToFollow(panel, reply)
|
||||||
})
|
})
|
||||||
|
@ -27,7 +27,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script src="./who_to_follow_panel.js" ></script>
|
<script src="./who_to_follow_panel.js"></script>
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
.who-to-follow * {
|
.who-to-follow * {
|
||||||
|
@ -46,7 +46,7 @@ const messages = {
|
|||||||
},
|
},
|
||||||
setLanguage: async (i18n, language) => {
|
setLanguage: async (i18n, language) => {
|
||||||
if (loaders[language]) {
|
if (loaders[language]) {
|
||||||
let messages = await loaders[language]()
|
const messages = await loaders[language]()
|
||||||
i18n.setLocaleMessage(language, messages.default)
|
i18n.setLocaleMessage(language, messages.default)
|
||||||
}
|
}
|
||||||
i18n.locale = language
|
i18n.locale = language
|
||||||
|
@ -3,8 +3,8 @@
|
|||||||
// meant to be used to load the partial i18n we need for
|
// meant to be used to load the partial i18n we need for
|
||||||
// the service worker.
|
// the service worker.
|
||||||
module.exports = function (source) {
|
module.exports = function (source) {
|
||||||
var object = JSON.parse(source)
|
const object = JSON.parse(source)
|
||||||
var smol = {
|
const smol = {
|
||||||
notifications: object.notifications || {}
|
notifications: object.notifications || {}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -5,7 +5,9 @@ import { each, get, set, cloneDeep } from 'lodash'
|
|||||||
let loaded = false
|
let loaded = false
|
||||||
|
|
||||||
const defaultReducer = (state, paths) => (
|
const defaultReducer = (state, paths) => (
|
||||||
paths.length === 0 ? state : paths.reduce((substate, path) => {
|
paths.length === 0
|
||||||
|
? state
|
||||||
|
: paths.reduce((substate, path) => {
|
||||||
set(substate, path, get(state, path))
|
set(substate, path, get(state, path))
|
||||||
return substate
|
return substate
|
||||||
}, {})
|
}, {})
|
||||||
@ -30,7 +32,7 @@ export default function createPersistedState ({
|
|||||||
key = 'vuex-lz',
|
key = 'vuex-lz',
|
||||||
paths = [],
|
paths = [],
|
||||||
getState = (key, storage) => {
|
getState = (key, storage) => {
|
||||||
let value = storage.getItem(key)
|
const value = storage.getItem(key)
|
||||||
return value
|
return value
|
||||||
},
|
},
|
||||||
setState = (key, state, storage) => {
|
setState = (key, state, storage) => {
|
||||||
|
@ -233,7 +233,7 @@ const api = {
|
|||||||
|
|
||||||
// Follow requests
|
// Follow requests
|
||||||
startFetchingFollowRequests (store) {
|
startFetchingFollowRequests (store) {
|
||||||
if (store.state.fetchers['followRequests']) return
|
if (store.state.fetchers.followRequests) return
|
||||||
const fetcher = store.state.backendInteractor.startFetchingFollowRequests({ store })
|
const fetcher = store.state.backendInteractor.startFetchingFollowRequests({ store })
|
||||||
|
|
||||||
store.commit('addFetcher', { fetcherName: 'followRequests', fetcher })
|
store.commit('addFetcher', { fetcherName: 'followRequests', fetcher })
|
||||||
@ -244,7 +244,7 @@ const api = {
|
|||||||
store.commit('removeFetcher', { fetcherName: 'followRequests', fetcher })
|
store.commit('removeFetcher', { fetcherName: 'followRequests', fetcher })
|
||||||
},
|
},
|
||||||
removeFollowRequest (store, request) {
|
removeFollowRequest (store, request) {
|
||||||
let requests = store.state.followRequests.filter((it) => it !== request)
|
const requests = store.state.followRequests.filter((it) => it !== request)
|
||||||
store.commit('setFollowRequests', requests)
|
store.commit('setFollowRequests', requests)
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -147,7 +147,7 @@ const config = {
|
|||||||
const knownKeys = new Set(Object.keys(defaultState))
|
const knownKeys = new Set(Object.keys(defaultState))
|
||||||
const presentKeys = new Set(Object.keys(data))
|
const presentKeys = new Set(Object.keys(data))
|
||||||
const intersection = new Set()
|
const intersection = new Set()
|
||||||
for (let elem of presentKeys) {
|
for (const elem of presentKeys) {
|
||||||
if (knownKeys.has(elem)) {
|
if (knownKeys.has(elem)) {
|
||||||
intersection.add(elem)
|
intersection.add(elem)
|
||||||
}
|
}
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user