🔥 Remove no-longer needed prop attrs

This commit is contained in:
Alicia Sykes 2021-10-30 13:23:54 +01:00
parent 6f3570eed2
commit 513b1cd955
4 changed files with 11 additions and 13 deletions

View File

@ -3,7 +3,7 @@
<TabItem :name="$t('config.main-tab')" class="main-tab"> <TabItem :name="$t('config.main-tab')" class="main-tab">
<div class="main-options-container"> <div class="main-options-container">
<div class="config-buttons"> <div class="config-buttons">
<h2>Configuration Options</h2> <h2>{{ $t('config.heading') }}</h2>
<a class="hyperlink-wrapper" @click="openExportConfigModal()"> <a class="hyperlink-wrapper" @click="openExportConfigModal()">
<button class="config-button center"> <button class="config-button center">
<DownloadIcon class="button-icon"/> <DownloadIcon class="button-icon"/>
@ -52,13 +52,13 @@
<RebuildApp /> <RebuildApp />
</TabItem> </TabItem>
<TabItem :name="$t('config.edit-config-tab')"> <TabItem :name="$t('config.edit-config-tab')">
<JsonEditor :config="config" /> <JsonEditor />
</TabItem> </TabItem>
<TabItem :name="$t('cloud-sync.title')"> <TabItem :name="$t('cloud-sync.title')">
<CloudBackupRestore :config="config" /> <CloudBackupRestore />
</TabItem> </TabItem>
<TabItem :name="$t('config.custom-css-tab')"> <TabItem :name="$t('config.custom-css-tab')">
<CustomCssEditor :config="config" /> <CustomCssEditor />
</TabItem> </TabItem>
</Tabs> </Tabs>
</template> </template>
@ -68,6 +68,7 @@
import JsonToYaml from '@/utils/JsonToYaml'; import JsonToYaml from '@/utils/JsonToYaml';
import { localStorageKeys, modalNames } from '@/utils/defaults'; import { localStorageKeys, modalNames } from '@/utils/defaults';
import { getUsersLanguage } from '@/utils/ConfigHelpers'; import { getUsersLanguage } from '@/utils/ConfigHelpers';
import StoreKeys from '@/utils/StoreMutations';
import JsonEditor from '@/components/Configuration/JsonEditor'; import JsonEditor from '@/components/Configuration/JsonEditor';
import CustomCssEditor from '@/components/Configuration/CustomCss'; import CustomCssEditor from '@/components/Configuration/CustomCss';
import CloudBackupRestore from '@/components/Configuration/CloudBackupRestore'; import CloudBackupRestore from '@/components/Configuration/CloudBackupRestore';
@ -139,15 +140,13 @@ export default {
}, },
/* Checks that the user is sure, then resets site-wide local storage, and reloads page */ /* Checks that the user is sure, then resets site-wide local storage, and reloads page */
resetLocalSettings() { resetLocalSettings() {
const msg = `${this.$t('config.reset-config-msg-l1') const msg = `${this.$t('config.reset-config-msg-l1')} `
}${this.$t('config.reset-config-msg-l2')}\n\n${this.$t('config.reset-config-msg-l3')}`; + `${this.$t('config.reset-config-msg-l2')}\n\n${this.$t('config.reset-config-msg-l3')}`;
const isTheUserSure = confirm(msg); // eslint-disable-line no-alert, no-restricted-globals const isTheUserSure = confirm(msg); // eslint-disable-line no-alert, no-restricted-globals
if (isTheUserSure) { if (isTheUserSure) {
localStorage.clear(); localStorage.clear();
this.$toasted.show(this.$t('config.data-cleared-msg')); this.$toasted.show(this.$t('config.data-cleared-msg'));
setTimeout(() => { this.$store.dispatch(StoreKeys.INITIALIZE_CONFIG);
location.reload(true); // eslint-disable-line no-restricted-globals
}, 1900);
} }
}, },
getLanguage() { getLanguage() {

View File

@ -365,7 +365,7 @@ export default {
height: 2rem; height: 2rem;
} }
&.add-new { &.add-new {
border-style: dashed !important; border: 2px dashed var(--primary) !important;
} }
} }

View File

@ -6,8 +6,7 @@
/> />
<div class="options-outer"> <div class="options-outer">
<div :class="`options-container ${!settingsVisible ? 'hide' : ''}`"> <div :class="`options-container ${!settingsVisible ? 'hide' : ''}`">
<ThemeSelector :externalThemes="externalThemes" <ThemeSelector />
:confTheme="getInitialTheme()" :userThemes="getUserThemes()" />
<LayoutSelector :displayLayout="displayLayout" @layoutUpdated="updateDisplayLayout"/> <LayoutSelector :displayLayout="displayLayout" @layoutUpdated="updateDisplayLayout"/>
<ItemSizeSelector :iconSize="iconSize" @iconSizeUpdated="updateIconSize" /> <ItemSizeSelector :iconSize="iconSize" @iconSizeUpdated="updateIconSize" />
<ConfigLauncher /> <ConfigLauncher />

View File

@ -184,7 +184,7 @@ export default {
findSingleSection: (allSections, sectionTitle) => { findSingleSection: (allSections, sectionTitle) => {
if (!sectionTitle) return undefined; if (!sectionTitle) return undefined;
let sectionToReturn; let sectionToReturn;
const parse = (section) => section.replace(' ', '-').toLowerCase().trim(); const parse = (section) => section.replaceAll(' ', '-').toLowerCase().trim();
allSections.forEach((section) => { allSections.forEach((section) => {
if (parse(sectionTitle) === parse(section.name)) { if (parse(sectionTitle) === parse(section.name)) {
sectionToReturn = [section]; sectionToReturn = [section];