diff --git a/packages/client/src/components/Block.svelte b/packages/client/src/components/Block.svelte index 05d92f208c..75474dfd6f 100644 --- a/packages/client/src/components/Block.svelte +++ b/packages/client/src/components/Block.svelte @@ -67,6 +67,9 @@ // any depth id: $component.id, + // Name can be used down the tree in placeholders + name: $component.name, + // We register block components with their raw props so that we can eject // blocks later on registerComponent: registerBlockComponent, diff --git a/packages/client/src/components/app/Placeholder.svelte b/packages/client/src/components/app/Placeholder.svelte index 203071e0b1..54553cb934 100644 --- a/packages/client/src/components/app/Placeholder.svelte +++ b/packages/client/src/components/app/Placeholder.svelte @@ -3,13 +3,14 @@ const { builderStore } = getContext("sdk") const component = getContext("component") + const block = getContext("block") export let text {#if $builderStore.inBuilder}
- {text || $component.name || "Placeholder"} + {text || block?.name || $component.name || "Placeholder"}
{/if}