Merge branch 'small-fixes-and-improvements' into shigusegubu-themes3
This commit is contained in:
commit
0b70a14dec
23 changed files with 110 additions and 95 deletions
|
|
@ -36,7 +36,6 @@ export default function () {
|
|||
const warning = warnings[i]
|
||||
console.warn(' ' + warning)
|
||||
}
|
||||
console.warn()
|
||||
process.exit(1)
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -28,10 +28,10 @@
|
|||
>
|
||||
<user-panel />
|
||||
<template v-if="layoutType !== 'mobile'">
|
||||
<nav-panel />
|
||||
<instance-specific-panel v-if="showInstanceSpecificPanel" />
|
||||
<features-panel v-if="!currentUser && showFeaturesPanel" />
|
||||
<who-to-follow-panel v-if="currentUser && suggestionsEnabled" />
|
||||
<NavPanel />
|
||||
<InstanceSpecificPanel v-if="showInstanceSpecificPanel" />
|
||||
<FeaturesPanel v-if="!currentUser && showFeaturesPanel" />
|
||||
<WhoToFollowPanel v-if="currentUser && suggestionsEnabled" />
|
||||
<div id="notifs-sidebar" />
|
||||
</template>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -152,8 +152,10 @@ const getStaticConfig = async () => {
|
|||
throw res
|
||||
}
|
||||
} catch (error) {
|
||||
console.warn('Failed to load static/config.json, continuing without it.')
|
||||
console.warn(error)
|
||||
console.warn(
|
||||
'Failed to load static/config.json, continuing without it.',
|
||||
error,
|
||||
)
|
||||
return {}
|
||||
}
|
||||
}
|
||||
|
|
@ -442,8 +444,7 @@ const getNodeInfo = async ({ store }) => {
|
|||
throw res
|
||||
}
|
||||
} catch (e) {
|
||||
console.warn('Could not load nodeinfo')
|
||||
console.warn(e)
|
||||
console.warn('Could not load nodeinfo', e)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -333,7 +333,6 @@ const EmojiInput = {
|
|||
if (!this.pickerShown) {
|
||||
this.scrollIntoView()
|
||||
this.$refs.picker.showPicker()
|
||||
this.$refs.picker.startEmojiLoad()
|
||||
} else {
|
||||
this.$refs.picker.hidePicker()
|
||||
}
|
||||
|
|
|
|||
|
|
@ -11,3 +11,9 @@
|
|||
</template>
|
||||
|
||||
<script src="./instance_specific_panel.js"></script>
|
||||
|
||||
<style lang="scss">
|
||||
.instance-specific-panel .panel-body {
|
||||
border-radius: var(--roundness);
|
||||
}
|
||||
</style>
|
||||
|
|
|
|||
|
|
@ -42,7 +42,6 @@
|
|||
</tab-switcher>
|
||||
<Notifications
|
||||
ref="notifications"
|
||||
:no-heading="true"
|
||||
:no-extra="true"
|
||||
:minimal-mode="true"
|
||||
:filter-mode="filterMode"
|
||||
|
|
|
|||
|
|
@ -48,6 +48,7 @@
|
|||
img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
max-height: 10em;
|
||||
object-fit: cover;
|
||||
border-radius: var(--roundness);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@
|
|||
type="text"
|
||||
:placeholder="$t('polls.option')"
|
||||
:maxlength="maxLength"
|
||||
@change="updatePollToParent"
|
||||
@keydown.enter.stop.prevent="nextOption(index)"
|
||||
>
|
||||
</div>
|
||||
|
|
@ -50,7 +49,6 @@
|
|||
v-model="pollType"
|
||||
class="poll-type-select"
|
||||
unstyled="true"
|
||||
@change="updatePollToParent"
|
||||
>
|
||||
<option value="single">
|
||||
{{ $t('polls.single_choice') }}
|
||||
|
|
|
|||
|
|
@ -133,6 +133,7 @@
|
|||
&.suboptions {
|
||||
margin-left: 2em;
|
||||
border-top: 1px dotted var(--border);
|
||||
border-bottom: 1px dotted var(--border);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -50,6 +50,16 @@
|
|||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<BooleanSetting path="userCardHidePersonalMarks">
|
||||
{{ $t('settings.user_card_hide_personal_marks') }}
|
||||
</BooleanSetting>
|
||||
</li>
|
||||
<li v-if="shoutAvailable">
|
||||
<BooleanSetting path="hideShoutbox">
|
||||
{{ $t('settings.hide_shoutbox') }}
|
||||
</BooleanSetting>
|
||||
</li>
|
||||
</ul>
|
||||
<h3>{{ $t('settings.attachments') }}</h3>
|
||||
<ul class="setting-list">
|
||||
|
|
@ -77,16 +87,6 @@
|
|||
{{ $t('settings.hide_attachments_in_convo') }}
|
||||
</BooleanSetting>
|
||||
</li>
|
||||
<li>
|
||||
<BooleanSetting path="userCardHidePersonalMarks">
|
||||
{{ $t('settings.user_card_hide_personal_marks') }}
|
||||
</BooleanSetting>
|
||||
</li>
|
||||
<li v-if="shoutAvailable">
|
||||
<BooleanSetting path="hideShoutbox">
|
||||
{{ $t('settings.hide_shoutbox') }}
|
||||
</BooleanSetting>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -117,7 +117,6 @@
|
|||
:key="column"
|
||||
:local="true"
|
||||
:path="column + 'ColumnWidth'"
|
||||
:units="horizontalUnits"
|
||||
expert="1"
|
||||
>
|
||||
{{ $t('settings.column_sizes_' + column) }}
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@ import BooleanSetting from '../helpers/boolean_setting.vue'
|
|||
import ChoiceSetting from '../helpers/choice_setting.vue'
|
||||
import IntegerSetting from '../helpers/integer_setting.vue'
|
||||
import SharedComputedObject from '../helpers/shared_computed_object.js'
|
||||
import UnitSetting from '../helpers/unit_setting.vue'
|
||||
|
||||
import { useLocalConfigStore } from 'src/stores/local_config.js'
|
||||
import { useSyncConfigStore } from 'src/stores/sync_config.js'
|
||||
|
|
@ -62,6 +63,7 @@ const PostsTab = {
|
|||
ChoiceSetting,
|
||||
IntegerSetting,
|
||||
FontControl,
|
||||
UnitSetting,
|
||||
},
|
||||
computed: {
|
||||
...SharedComputedObject(),
|
||||
|
|
|
|||
|
|
@ -492,7 +492,7 @@ export default {
|
|||
try {
|
||||
return deserializeShadow(shadow)
|
||||
} catch (e) {
|
||||
console.warn(e)
|
||||
console.warn('Failed to deserialize shadow', e)
|
||||
return shadow
|
||||
}
|
||||
}
|
||||
|
|
@ -652,7 +652,7 @@ export default {
|
|||
return rgb2hex(computedColor)
|
||||
}
|
||||
} catch (e) {
|
||||
console.warn(e)
|
||||
console.warn('failed to get computed color', e)
|
||||
}
|
||||
return null
|
||||
}
|
||||
|
|
|
|||
|
|
@ -125,7 +125,7 @@ export default {
|
|||
if (computedColor) return rgb2hex(computedColor)
|
||||
return null
|
||||
} catch (e) {
|
||||
console.warn(e)
|
||||
console.warn('Failed to get fallback color', e)
|
||||
return null
|
||||
}
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@ import StatusBookmarkFolderMenu from 'src/components/status_bookmark_folder_menu
|
|||
|
||||
import { useInstanceStore } from 'src/stores/instance.js'
|
||||
import { useInstanceCapabilitiesStore } from 'src/stores/instance_capabilities.js'
|
||||
import { useMergedConfigStore } from 'src/stores/merged_config.js'
|
||||
|
||||
import { library } from '@fortawesome/fontawesome-svg-core'
|
||||
import {
|
||||
|
|
@ -96,6 +97,9 @@ export default {
|
|||
return !useInstanceCapabilitiesStore()
|
||||
.pleromaCustomEmojiReactionsAvailable
|
||||
},
|
||||
hidePostStats() {
|
||||
return useMergedConfigStore().mergedConfig.hidePostStats
|
||||
},
|
||||
buttonInnerClass() {
|
||||
return [
|
||||
this.button.name + '-button',
|
||||
|
|
|
|||
|
|
@ -59,7 +59,7 @@
|
|||
/>
|
||||
</component>
|
||||
<span
|
||||
v-if="button.counter?.(funcArg) > 0"
|
||||
v-if="!hidePostStats && button.counter?.(funcArg) > 0"
|
||||
class="action-counter"
|
||||
>
|
||||
{{ button.counter?.(funcArg) }}
|
||||
|
|
|
|||
|
|
@ -403,6 +403,12 @@ export default {
|
|||
allowNonSquareEmoji() {
|
||||
return this.mergedConfig.nonSquareEmoji
|
||||
},
|
||||
hideUserStats() {
|
||||
return this.mergedConfig.hideUserStats
|
||||
},
|
||||
hideRemarks() {
|
||||
return this.mergedConfig.userCardHidePersonalMarks
|
||||
},
|
||||
...mapState(useMergedConfigStore, ['mergedConfig']),
|
||||
},
|
||||
methods: {
|
||||
|
|
|
|||
|
|
@ -304,7 +304,7 @@
|
|||
</div>
|
||||
</div>
|
||||
<div
|
||||
v-if="!editable && loggedIn && isOtherUser && (hasNote || !hideBio) && !userCardHidePersonalMarks"
|
||||
v-if="!editable && loggedIn && isOtherUser && (hasNote || !hideBio) && !hideRemarks"
|
||||
class="personal-marks"
|
||||
>
|
||||
<UserNote
|
||||
|
|
|
|||
|
|
@ -10,4 +10,15 @@
|
|||
.footer-left-checkbox {
|
||||
width: max-content;
|
||||
}
|
||||
|
||||
.expirationTime {
|
||||
display: inline-flex;
|
||||
white-space: nowrap;
|
||||
padding: 0.5em;
|
||||
}
|
||||
|
||||
.dialog-modal-content .checkbox {
|
||||
vertical-align: middle;
|
||||
padding: 0.5em;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -11,48 +11,50 @@
|
|||
<p>
|
||||
{{ $t(isMute ? 'user_card.expire_mute_message' : 'user_card.expire_block_message', [user.screen_name]) }}
|
||||
</p>
|
||||
<p>
|
||||
<div>
|
||||
{{ $t('user_card.expire_in') }}
|
||||
<input
|
||||
id="userFilterExpires"
|
||||
v-model="expiration"
|
||||
class="input input-expire-in"
|
||||
:class="{ disabled: forever }"
|
||||
:disabled="forever"
|
||||
min="1"
|
||||
type="number"
|
||||
>
|
||||
<Select
|
||||
id="userFilterExpiresUnit"
|
||||
v-model="expirationUnit"
|
||||
class="input unit-input unstyled"
|
||||
:disabled="forever"
|
||||
>
|
||||
<option
|
||||
key="s"
|
||||
value="s"
|
||||
<span class="expirationTime">
|
||||
<input
|
||||
id="userFilterExpires"
|
||||
v-model="expiration"
|
||||
class="input input-expire-in"
|
||||
:class="{ disabled: forever }"
|
||||
:disabled="forever"
|
||||
min="1"
|
||||
type="number"
|
||||
>
|
||||
{{ $t('time.unit.seconds_suffix') }}
|
||||
</option>
|
||||
<option
|
||||
key="m"
|
||||
value="m"
|
||||
<Select
|
||||
id="userFilterExpiresUnit"
|
||||
v-model="expirationUnit"
|
||||
class="input unit-input unstyled"
|
||||
:disabled="forever"
|
||||
>
|
||||
{{ $t('time.unit.minutes_suffix') }}
|
||||
</option>
|
||||
<option
|
||||
key="h"
|
||||
value="h"
|
||||
>
|
||||
{{ $t('time.unit.hours_suffix') }}
|
||||
</option>
|
||||
<option
|
||||
key="d"
|
||||
value="d"
|
||||
>
|
||||
{{ $t('time.unit.days_suffix') }}
|
||||
</option>
|
||||
</Select>
|
||||
<option
|
||||
key="s"
|
||||
value="s"
|
||||
>
|
||||
{{ $t('time.unit.seconds_suffix') }}
|
||||
</option>
|
||||
<option
|
||||
key="m"
|
||||
value="m"
|
||||
>
|
||||
{{ $t('time.unit.minutes_suffix') }}
|
||||
</option>
|
||||
<option
|
||||
key="h"
|
||||
value="h"
|
||||
>
|
||||
{{ $t('time.unit.hours_suffix') }}
|
||||
</option>
|
||||
<option
|
||||
key="d"
|
||||
value="d"
|
||||
>
|
||||
{{ $t('time.unit.days_suffix') }}
|
||||
</option>
|
||||
</Select>
|
||||
</span>
|
||||
|
||||
{{ $t('user_card.mute_or') }}
|
||||
|
||||
|
|
@ -64,7 +66,7 @@
|
|||
>
|
||||
{{ $t('user_card.mute_block_never') }}
|
||||
</Checkbox>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<template #footerLeft>
|
||||
<div class="footer-left-checkbox">
|
||||
|
|
|
|||
|
|
@ -348,8 +348,7 @@ const addNewStatuses = (
|
|||
// NOOP, it is known status but we don't do anything about it for now
|
||||
},
|
||||
default: (unknown) => {
|
||||
console.warn('unknown status type')
|
||||
console.warn(unknown)
|
||||
console.warn('unknown status type', unknown)
|
||||
},
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -99,12 +99,16 @@ export const findColor = (color, { dynamicVars, staticVars }) => {
|
|||
const staticVar = staticVars[variableSlot]
|
||||
const dynamicVar = dynamicVars[variableSlot]
|
||||
if (!staticVar && !dynamicVar) {
|
||||
console.warn(dynamicVars, variableSlot, dynamicVars[variableSlot])
|
||||
console.warn(`Couldn't find variable "${variableSlot}", falling back to magenta. Variables are:
|
||||
console.warn(
|
||||
`Couldn't find variable "${variableSlot}", falling back to magenta. Variables are:
|
||||
Static:
|
||||
${JSON.stringify(staticVars, null, 2)}
|
||||
Dynamic:
|
||||
${JSON.stringify(dynamicVars, null, 2)}`)
|
||||
${JSON.stringify(dynamicVars, null, 2)}`,
|
||||
dynamicVars,
|
||||
variableSlot,
|
||||
dynamicVars[variableSlot],
|
||||
)
|
||||
}
|
||||
targetColor = convert(staticVar ?? dynamicVar ?? '#FF00FF').rgb
|
||||
}
|
||||
|
|
|
|||
|
|
@ -146,11 +146,7 @@ describe('Gallery', () => {
|
|||
{ items: [{ type: 'image' }] },
|
||||
{ audio: true, items: [{ type: 'audio' }] },
|
||||
{
|
||||
items: [
|
||||
{ type: 'image' },
|
||||
{ type: 'image' },
|
||||
{ type: 'image' },
|
||||
],
|
||||
items: [{ type: 'image' }, { type: 'image' }, { type: 'image' }],
|
||||
},
|
||||
])
|
||||
})
|
||||
|
|
@ -251,31 +247,19 @@ describe('Gallery', () => {
|
|||
|
||||
expect(Gallery.computed.rows.call(local)).to.eql([
|
||||
{
|
||||
items: [
|
||||
{ type: 'image' },
|
||||
{ type: 'image' },
|
||||
],
|
||||
items: [{ type: 'image' }, { type: 'image' }],
|
||||
},
|
||||
{
|
||||
items: [
|
||||
{ type: 'image' },
|
||||
{ type: 'image' },
|
||||
],
|
||||
items: [{ type: 'image' }, { type: 'image' }],
|
||||
},
|
||||
{ audio: true, items: [{ type: 'audio' }] },
|
||||
{ items: [{ type: 'image' }] },
|
||||
{ audio: true, items: [{ type: 'audio' }] },
|
||||
{
|
||||
items: [
|
||||
{ type: 'image' },
|
||||
{ type: 'image' },
|
||||
],
|
||||
items: [{ type: 'image' }, { type: 'image' }],
|
||||
},
|
||||
{
|
||||
items: [
|
||||
{ type: 'image' },
|
||||
{ type: 'image' },
|
||||
],
|
||||
items: [{ type: 'image' }, { type: 'image' }],
|
||||
},
|
||||
])
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue