- Issue created by @wim leers
Extracted from #3512385-5: Changes to code components are not visible in A) preview-on-hover, B) global regions until published ā :
ā ļø AFAICT this also affects the component preview upon hovering the list of available components:
ComponentSourceInterface::renderComponent()
with isPreview: TRUE
in ComponentSourceInterface::getClientSideInfo()
diff --git a/src/Plugin/ExperienceBuilder/ComponentSource/BlockComponent.php b/src/Plugin/ExperienceBuilder/ComponentSource/BlockComponent.php
index 4fbac989c..adb573f8d 100644
--- a/src/Plugin/ExperienceBuilder/ComponentSource/BlockComponent.php
+++ b/src/Plugin/ExperienceBuilder/ComponentSource/BlockComponent.php
@@ -302,7 +302,7 @@ final class BlockComponent extends ComponentSourceBase implements ContainerFacto
return ['build' => []];
}
- return ['build' => $this->renderComponent([], $component->uuid())];
+ return ['build' => $this->renderComponent([], $component->uuid(), TRUE)];
}
/**
diff --git a/src/Plugin/ExperienceBuilder/ComponentSource/GeneratedFieldExplicitInputUxComponentSourceBase.php b/src/Plugin/ExperienceBuilder/ComponentSource/GeneratedFieldExplicitInputUxComponentSourceBase.php
index c55528b5b..39653166a 100644
--- a/src/Plugin/ExperienceBuilder/ComponentSource/GeneratedFieldExplicitInputUxComponentSourceBase.php
+++ b/src/Plugin/ExperienceBuilder/ComponentSource/GeneratedFieldExplicitInputUxComponentSourceBase.php
@@ -603,7 +603,7 @@ abstract class GeneratedFieldExplicitInputUxComponentSourceBase extends Componen
return [
'source' => (string) $this->getSourceLabel(),
- 'build' => $this->renderComponent([self::EXPLICIT_INPUT_NAME => $default_props_for_default_markup], $component->uuid()),
+ 'build' => $this->renderComponent([self::EXPLICIT_INPUT_NAME => $default_props_for_default_markup], $component->uuid(), TRUE),
// Additional data only needed for SDCs.
// @todo UI does not use any other metadata - should `slots` move to top level?
'metadata' => ['slots' => $this->getSlotDefinitions()],
Component hover (instantaneously, aka without refreshing) shows the auto-saved (draft) version of a code component.Changes to code components are not visible in global regions until published
Active
0.0
Internal HTTP API