mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-19 16:02:15 +00:00
default value for hasConfig is false and the emit update for the URL dashboard widget and only loads the config component if the dashboard widget actually has a config
This commit is contained in:
@@ -12,7 +12,7 @@ export default {
|
||||
widget: null,
|
||||
tmpConfig: {},
|
||||
isLoading: false,
|
||||
hasConfig: true,
|
||||
hasConfig: false,
|
||||
sharedData: null,
|
||||
}),
|
||||
emits: [
|
||||
@@ -117,10 +117,10 @@ export default {
|
||||
</div>
|
||||
</div>
|
||||
<div v-if="ready" class="card-body overflow-hidden">
|
||||
<component :is="component" v-model:shared-data="sharedData" :config="arguments" :width="width" :height="height" @setConfig="setConfig" @change="changeConfigManually"></component>
|
||||
<component :is="component" v-model:shared-data="sharedData" :config="arguments" :width="width" :height="height" @setConfig="setConfig" @change="changeConfigManually"></component>
|
||||
</div>
|
||||
<div v-else class="card-body overflow-hidden text-center d-flex flex-column justify-content-center"><i class="fa-solid fa-spinner fa-pulse fa-3x"></i></div>
|
||||
<bs-modal ref="config">
|
||||
<bs-modal v-if="hasConfig" ref="config">
|
||||
<template v-slot:title>
|
||||
{{ widget ? 'Config for ' + widget.setup.name : '' }}
|
||||
</template>
|
||||
|
||||
@@ -71,6 +71,10 @@ export default {
|
||||
async mounted() {
|
||||
await this.fetchBookmarks();
|
||||
},
|
||||
created()
|
||||
{
|
||||
this.$emit('setConfig', true);
|
||||
},
|
||||
template: /*html*/ `
|
||||
<div class="widgets-url w-100 h-100">
|
||||
<div v-if="configMode">
|
||||
|
||||
Reference in New Issue
Block a user