Add value for 'value' binding when editing table columns to improve live eval
This commit is contained in:
parent
35d64322ae
commit
53cd48e866
|
@ -8,6 +8,7 @@
|
|||
export let allowJS = false
|
||||
export let allowHelpers = true
|
||||
export let autofocusEditor = false
|
||||
export let context = null
|
||||
|
||||
$: enrichedBindings = enrichBindings(bindings)
|
||||
|
||||
|
@ -27,7 +28,7 @@
|
|||
|
||||
<BindingPanel
|
||||
bindings={enrichedBindings}
|
||||
context={$previewStore.selectedComponentContext}
|
||||
context={{ ...$previewStore.selectedComponentContext, ...context }}
|
||||
snippets={$snippets}
|
||||
{value}
|
||||
{allowJS}
|
||||
|
|
|
@ -7,10 +7,13 @@
|
|||
Layout,
|
||||
Label,
|
||||
} from "@budibase/bbui"
|
||||
import { themeStore } from "stores/builder"
|
||||
import { themeStore, previewStore } from "stores/builder"
|
||||
import DrawerBindableInput from "components/common/bindings/DrawerBindableInput.svelte"
|
||||
|
||||
export let column
|
||||
|
||||
$: columnValue =
|
||||
$previewStore.selectedComponentContext?.eventContext?.row?.[column.name]
|
||||
</script>
|
||||
|
||||
<DrawerContent>
|
||||
|
@ -41,6 +44,9 @@
|
|||
icon: "TableColumnMerge",
|
||||
},
|
||||
]}
|
||||
context={{
|
||||
value: columnValue,
|
||||
}}
|
||||
/>
|
||||
<Layout noPadding gap="XS">
|
||||
<Label>Background color</Label>
|
||||
|
|
Loading…
Reference in New Issue