1
0
Fork 0
mirror of synced 2024-10-01 09:38:55 +13:00

Bug fixes for logo and binding validation. Random fix for a button actions issue found while testing

This commit is contained in:
Dean 2023-02-02 12:49:26 +00:00
parent c2f883e781
commit 73f3fc41cb
3 changed files with 10 additions and 2 deletions

View file

@ -22,6 +22,7 @@
const dispatch = createEventDispatcher()
let bindingDrawer
let valid = true
$: readableValue = runtimeToReadableBinding(bindings, value)
$: tempValue = readableValue
@ -76,12 +77,15 @@
<svelte:fragment slot="description">
Add the objects on the left to enrich your text.
</svelte:fragment>
<Button cta slot="buttons" on:click={handleClose}>Save</Button>
<Button cta slot="buttons" on:click={handleClose} disabled={!valid}>
Save
</Button>
<svelte:component
this={panel}
slot="body"
value={readableValue}
close={handleClose}
bind:valid
on:change={event => (tempValue = event.detail)}
{bindings}
{allowJS}

View file

@ -118,6 +118,10 @@
const getAllBindings = (bindings, eventContextBindings, actions) => {
let allBindings = eventContextBindings.concat(bindings)
if (!actions) {
return []
}
// Ensure bindings are generated for all "update state" action keys
actions
.filter(action => {

View file

@ -267,7 +267,7 @@ export async function publicSettings(ctx: Ctx) {
// enrich the logo url
// empty url means deleted
if (config.config.logoUrl !== "") {
if (config.config.logoUrl && config.config.logoUrl !== "") {
config.config.logoUrl = objectStore.getGlobalFileUrl(
"settings",
"logoUrl",