mirror of
https://github.com/nextcloud/server.git
synced 2026-03-31 06:36:18 -04:00
Fix font change preview update
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com> Signed-off-by: nextcloud-command <nextcloud-command@users.noreply.github.com>
This commit is contained in:
parent
1c60ff5936
commit
eb8d1ff6da
4 changed files with 10 additions and 5 deletions
|
|
@ -124,11 +124,16 @@ export default {
|
|||
|
||||
updateBodyAttributes() {
|
||||
const enabledThemesIDs = this.themes.filter(theme => theme.enabled === true).map(theme => theme.id)
|
||||
const enabledFontsIDs = this.fonts.filter(font => font.enabled === true).map(font => font.id)
|
||||
|
||||
this.themes.forEach(theme => {
|
||||
document.body.toggleAttribute(`data-theme-${theme.id}`, theme.enabled)
|
||||
})
|
||||
this.fonts.forEach(font => {
|
||||
document.body.toggleAttribute(`data-theme-${font.id}`, font.enabled)
|
||||
})
|
||||
|
||||
document.body.setAttribute('data-themes', enabledThemesIDs.join(','))
|
||||
document.body.setAttribute('data-themes', [...enabledThemesIDs, ...enabledFontsIDs].join(','))
|
||||
},
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -67,7 +67,7 @@ export default {
|
|||
return this.selected
|
||||
},
|
||||
set(checked) {
|
||||
console.debug('Selecting theme', this.theme, checked)
|
||||
console.debug('Changed theme', this.theme.id, checked)
|
||||
|
||||
// If this is a radio, we can only enable
|
||||
if (!this.unique) {
|
||||
|
|
|
|||
4
dist/theming-theming-settings.js
vendored
4
dist/theming-theming-settings.js
vendored
File diff suppressed because one or more lines are too long
2
dist/theming-theming-settings.js.map
vendored
2
dist/theming-theming-settings.js.map
vendored
File diff suppressed because one or more lines are too long
Loading…
Reference in a new issue