@elementor/editor-components 4.2.0-beta2 → 4.3.0-1001

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -2543,12 +2543,12 @@ async function getDocumentsMap(ids, cache) {
2543
2543
 
2544
2544
  // src/store/actions/load-components-overridable-props.ts
2545
2545
  import { __dispatch as dispatch3, __getState as getState6 } from "@elementor/store";
2546
- async function loadComponentsOverridableProps(componentIds) {
2547
- const unloadedIds = componentIds.filter((id) => !selectIsOverridablePropsLoaded(getState6(), id));
2548
- if (!unloadedIds.length) {
2546
+ async function loadComponentsOverridableProps(componentIds, { force = false } = {}) {
2547
+ const idsToLoad = force ? componentIds : componentIds.filter((id) => !selectIsOverridablePropsLoaded(getState6(), id));
2548
+ if (!idsToLoad.length) {
2549
2549
  return;
2550
2550
  }
2551
- const { data } = await apiClient.getOverridableProps(unloadedIds);
2551
+ const { data } = await apiClient.getOverridableProps(idsToLoad);
2552
2552
  dispatch3(slice.actions.loadOverridableProps(data));
2553
2553
  }
2554
2554
 
@@ -2625,6 +2625,7 @@ async function switchToComponent(componentId, componentInstanceId, element) {
2625
2625
  setAsInitial: false,
2626
2626
  shouldScroll: false
2627
2627
  });
2628
+ await loadComponentsOverridableProps([componentId], { force: true });
2628
2629
  const currentDocumentContainer = getCurrentDocumentContainer();
2629
2630
  const topLevelElement = currentDocumentContainer?.children?.[0];
2630
2631
  if (topLevelElement) {