Merge branch 'hj/2.7.1-fixes' into shigusegubu-themes3
This commit is contained in:
commit
f8b0af62b2
57 changed files with 82 additions and 59 deletions
|
|
@ -122,6 +122,7 @@ const setSettings = async ({ apiConfig, staticConfig, store }) => {
|
|||
store.dispatch('setInstanceOption', { name, value: config[name] })
|
||||
}
|
||||
|
||||
copyInstanceOption('theme')
|
||||
copyInstanceOption('nsfwCensorImage')
|
||||
copyInstanceOption('background')
|
||||
copyInstanceOption('hidePostStats')
|
||||
|
|
|
|||
|
|
@ -150,7 +150,9 @@ const EmojiPicker = {
|
|||
},
|
||||
showPicker () {
|
||||
this.$refs.popover.showPopover()
|
||||
this.onShowing()
|
||||
this.$nextTick(() => {
|
||||
this.onShowing()
|
||||
})
|
||||
},
|
||||
hidePicker () {
|
||||
this.$refs.popover.hidePopover()
|
||||
|
|
|
|||
|
|
@ -89,6 +89,7 @@
|
|||
class="emoji-groups"
|
||||
:class="groupsScrolledClass"
|
||||
:min-item-size="minItemSize"
|
||||
:buffer="minItemSize"
|
||||
:items="emojiItems"
|
||||
:emit-update="true"
|
||||
@update="onScroll"
|
||||
|
|
|
|||
|
|
@ -300,7 +300,7 @@
|
|||
opacity: 0.2;
|
||||
}
|
||||
|
||||
.preview-container {
|
||||
.theme-preview-container {
|
||||
pointer-events: none;
|
||||
zoom: 0.5;
|
||||
border: none;
|
||||
|
|
|
|||
|
|
@ -145,6 +145,10 @@ const defaultState = {
|
|||
quotingAvailable: false,
|
||||
groupActorAvailable: false,
|
||||
|
||||
// Emoji stuff
|
||||
standardEmojiList: null,
|
||||
standardEmojiGroupList: null,
|
||||
|
||||
// Html stuff
|
||||
instanceSpecificPanelContent: '',
|
||||
tos: '',
|
||||
|
|
@ -246,15 +250,21 @@ const instance = {
|
|||
}, {})
|
||||
},
|
||||
standardEmojiList (state) {
|
||||
return SORTED_EMOJI_GROUP_IDS
|
||||
.map(groupId => (state.emoji[groupId] || []).map(k => injectAnnotations(k, state.unicodeEmojiAnnotations)))
|
||||
.reduce((a, b) => a.concat(b), [])
|
||||
if (!state.standardEmojiList) {
|
||||
state.standardEmojiList = SORTED_EMOJI_GROUP_IDS
|
||||
.map(groupId => (state.emoji[groupId] || []).map(k => injectAnnotations(k, state.unicodeEmojiAnnotations)))
|
||||
.reduce((a, b) => a.concat(b), [])
|
||||
}
|
||||
return state.standardEmojiList
|
||||
},
|
||||
standardEmojiGroupList (state) {
|
||||
return SORTED_EMOJI_GROUP_IDS.map(groupId => ({
|
||||
id: groupId,
|
||||
emojis: (state.emoji[groupId] || []).map(k => injectAnnotations(k, state.unicodeEmojiAnnotations))
|
||||
}))
|
||||
if (!state.standardEmojiGroupList) {
|
||||
state.standardEmojiGroupList = SORTED_EMOJI_GROUP_IDS.map(groupId => ({
|
||||
id: groupId,
|
||||
emojis: (state.emoji[groupId] || []).map(k => injectAnnotations(k, state.unicodeEmojiAnnotations))
|
||||
}))
|
||||
}
|
||||
return state.standardEmojiGroupList
|
||||
},
|
||||
instanceDomain (state) {
|
||||
return new URL(state.server).hostname
|
||||
|
|
@ -364,6 +374,8 @@ const instance = {
|
|||
// should have been "pack" field, that would be more useful
|
||||
}).sort(byPackThenByName)
|
||||
commit('setInstanceOption', { name: 'customEmoji', value: emoji })
|
||||
state.standardEmojiGroupList = null
|
||||
state.standardEmojiList = null
|
||||
} else {
|
||||
throw (res)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -351,6 +351,7 @@ export const convertTheme2To3 = (data) => {
|
|||
newRules.push({ ...rule, parent: { component: 'Notification' } })
|
||||
}
|
||||
if (key === 'buttonPressed') {
|
||||
console.log(key)
|
||||
newRules.push({ ...rule, state: ['toggled'] })
|
||||
newRules.push({ ...rule, state: ['toggled', 'focus'] })
|
||||
newRules.push({ ...rule, state: ['pressed', 'focus'] })
|
||||
|
|
@ -418,7 +419,6 @@ export const convertTheme2To3 = (data) => {
|
|||
case 'Border':
|
||||
newRule.parent = rule
|
||||
newRule.directives.textColor = data.colors[key]
|
||||
newRule.directives.textAuto = 'no-auto'
|
||||
variantArray = parts.slice(0, -1)
|
||||
break
|
||||
default:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue