diff --git a/src/components/editor.vue b/src/components/editor.vue index f7b0bb4a..835ddcfa 100644 --- a/src/components/editor.vue +++ b/src/components/editor.vue @@ -189,7 +189,7 @@
- +
{ return new Promise((resolve, reject) => { + if (this.uuid === undefined || this.uuid === '') { + Message.error(this.$t('editor.warning.mustEnterUuid')); + this.loadStatus = 'waiting'; + reject(); + return; + } // Create a new AbortController for each fetch attempt // as they get 'used up' after each successful abort() call this.controller = new AbortController(); @@ -925,10 +941,9 @@ export default class MetadataEditorV extends Vue { if (res.status === 404) { // Version not found. if (version === 'latest') { - Message.error(this.$t('editor.warning.uuidNotFound', this.uuid)); + Message.error(this.$t('editor.warning.uuidNotFound', { uuid: this.uuid })); } else { Message.error(this.$t('editor.editMetadata.message.error.noRequestedVersion')); - this.loadStatus = 'loaded'; } this.error = true; this.loadStatus = 'waiting'; @@ -994,19 +1009,21 @@ export default class MetadataEditorV extends Vue { // Note: This part probably doesn't need an manual abort() trigger to kill on load cancel, // as the history should be much smaller and quicker to fetch than the config - if (this.uuid === undefined) Message.error(this.$t('editor.warning.mustEnterUuid')); + if (this.uuid === undefined || this.uuid === '') { + return; + } this.loadStatus = 'loading'; const user = useUserStore().userProfile.userName || 'Guest'; fetch(this.apiUrl + `/history/${this.uuid}`, { headers: { user } }).then((res: Response) => { if (res.status === 404) { // Product not found. - Message.error(`The requested UUID '${this.uuid ?? ''}' does not exist.`); + this.loadStatus = 'waiting'; } else { res.json().then((json) => { this.storylineHistory = json; + this.loadStatus = 'loaded'; }); } - this.loadStatus = 'loaded'; }); } @@ -1807,11 +1824,14 @@ $font-list: 'Segoe UI', system-ui, ui-sans-serif, Tahoma, Geneva, Verdana, sans- .vfm__content button { border-radius: 3px; padding: 5px 12px; - margin: 0px 10px; font-weight: 600; transition-duration: 0.2s; } + .vfm__content button:focus { + transition-duration: 0.075s; + } + .vfm__content button:hover:enabled { background-color: #dbdbdb; color: black; diff --git a/src/components/slide-toc.vue b/src/components/slide-toc.vue index d2c5bcda..5d743252 100644 --- a/src/components/slide-toc.vue +++ b/src/components/slide-toc.vue @@ -8,7 +8,7 @@

-