From 3d2cd9cc0bf7810d5584b399f840353eb852aaf1 Mon Sep 17 00:00:00 2001 From: Andrew Kingston Date: Tue, 7 Nov 2023 14:22:09 +0000 Subject: [PATCH] Use explicit svelte store 'get' when clicking buttons in grids --- packages/client/src/components/app/GridBlock.svelte | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/client/src/components/app/GridBlock.svelte b/packages/client/src/components/app/GridBlock.svelte index 847f1e0768..801e1a4d0a 100644 --- a/packages/client/src/components/app/GridBlock.svelte +++ b/packages/client/src/components/app/GridBlock.svelte @@ -56,7 +56,7 @@ // We add a fake context binding in here, which allows us to pretend // that the grid provides a "schema" binding - that lets us use the // clicked row in things like save row actions - const enrichedContext = { ...get(context), [$component.id]: row } + const enrichedContext = { ...get(context), [get(component).id]: row } const fn = enrichButtonActions(settings.onClick, enrichedContext) return await fn?.({ row }) },