@firecms/core 3.0.0-canary.226 → 3.0.0-canary.228

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.
@@ -9,6 +9,10 @@ export type EntityCollectionViewProps<M extends Record<string, any>> = {
9
9
  * It defaults to the collection path if not provided.
10
10
  */
11
11
  fullPath?: string;
12
+ /**
13
+ * Full path using navigation ids.
14
+ */
15
+ fullIdPath?: string;
12
16
  /**
13
17
  * If this is a subcollection, specify the parent collection ids.
14
18
  */
@@ -19,6 +19,10 @@ export type OnTabChangeParams<M extends Record<string, any>> = {
19
19
  };
20
20
  export interface EntityEditViewProps<M extends Record<string, any>> {
21
21
  path: string;
22
+ /**
23
+ * The navigation path to the entity.
24
+ */
25
+ fullIdPath?: string;
22
26
  collection: EntityCollection<M>;
23
27
  entityId?: string;
24
28
  databaseId?: string;
@@ -37,7 +41,7 @@ export interface EntityEditViewProps<M extends Record<string, any>> {
37
41
  * an entity is opened.
38
42
  */
39
43
  export declare function EntityEditView<M extends Record<string, any>, USER extends User>({ entityId, ...props }: EntityEditViewProps<M>): import("react/jsx-runtime").JSX.Element;
40
- export declare function EntityEditViewInner<M extends Record<string, any>>({ path, entityId, selectedTab: selectedTabProp, collection, parentCollectionIds, onValuesModified, onSaved, onTabChange, entity, cachedDirtyValues, dataLoading, layout, barActions, status, setStatus, formProps, canEdit }: EntityEditViewProps<M> & {
44
+ export declare function EntityEditViewInner<M extends Record<string, any>>({ path, fullIdPath, entityId, selectedTab: selectedTabProp, collection, parentCollectionIds, onValuesModified, onSaved, onTabChange, entity, cachedDirtyValues, dataLoading, layout, barActions, status, setStatus, formProps, canEdit }: EntityEditViewProps<M> & {
41
45
  entity?: Entity<M>;
42
46
  cachedDirtyValues?: Partial<M>;
43
47
  dataLoading: boolean;
package/dist/index.es.js CHANGED
@@ -149,6 +149,7 @@ function navigateToEntity({
149
149
  entityId,
150
150
  copy,
151
151
  path,
152
+ fullIdPath,
152
153
  selectedTab,
153
154
  sideEntityController,
154
155
  onClose,
@@ -157,7 +158,8 @@ function navigateToEntity({
157
158
  if (openEntityMode === "side_panel") {
158
159
  sideEntityController.open({
159
160
  entityId,
160
- path,
161
+ path: fullIdPath ?? path,
162
+ // fullIdPath,
161
163
  copy,
162
164
  selectedTab,
163
165
  collection,
@@ -165,7 +167,7 @@ function navigateToEntity({
165
167
  onClose
166
168
  });
167
169
  } else {
168
- let to = navigation.buildUrlCollectionPath(entityId ? `${path}/${entityId}` : path);
170
+ let to = navigation.buildUrlCollectionPath(entityId ? `${fullIdPath ?? path}/${entityId}` : fullIdPath ?? path);
169
171
  if (entityId && selectedTab) {
170
172
  to += `/${selectedTab}`;
171
173
  }
@@ -12253,7 +12255,7 @@ const editEntityAction = {
12253
12255
  if (collection) {
12254
12256
  addRecentId(collection.id, entity.id);
12255
12257
  }
12256
- const path = collection?.collectionGroup ? entity.path : fullPath ?? entity.path;
12258
+ const path = collection?.collectionGroup ? collection.id : fullPath ?? collection?.id ?? entity.path;
12257
12259
  const defaultSelectedView = resolveDefaultSelectedView(collection ? collection.defaultSelectedView : void 0, {
12258
12260
  status: "existing",
12259
12261
  entityId: entity.id
@@ -12263,6 +12265,7 @@ const editEntityAction = {
12263
12265
  collection,
12264
12266
  entityId: entity.id,
12265
12267
  path,
12268
+ fullIdPath: path,
12266
12269
  sideEntityController: context.sideEntityController,
12267
12270
  onClose: () => unhighlightEntity?.(entity),
12268
12271
  navigation: context.navigation,
@@ -12289,12 +12292,13 @@ const copyEntityAction = {
12289
12292
  path: entity.path,
12290
12293
  entityId: entity.id
12291
12294
  });
12292
- const path = collection?.collectionGroup ? entity.path : fullPath ?? entity.path;
12295
+ const path = collection?.collectionGroup ? collection.id : fullPath ?? collection?.id ?? entity.path;
12293
12296
  navigateToEntity({
12294
12297
  openEntityMode,
12295
12298
  collection,
12296
12299
  entityId: entity.id,
12297
12300
  path,
12301
+ fullIdPath: path,
12298
12302
  copy: true,
12299
12303
  sideEntityController: context.sideEntityController,
12300
12304
  onClose: () => unhighlightEntity?.(entity),
@@ -18462,6 +18466,7 @@ function createCacheKey(fullPath, filters) {
18462
18466
  const DEFAULT_ENTITY_OPEN_MODE = "side_panel";
18463
18467
  const EntityCollectionView = React__default.memo(function EntityCollectionView2({
18464
18468
  fullPath: fullPathProp,
18469
+ fullIdPath,
18465
18470
  parentCollectionIds,
18466
18471
  isSubCollection,
18467
18472
  className,
@@ -18470,11 +18475,7 @@ const EntityCollectionView = React__default.memo(function EntityCollectionView2(
18470
18475
  }) {
18471
18476
  const context = useFireCMSContext();
18472
18477
  const navigation = useNavigationController();
18473
- const fullPath = (fullPathProp ? navigation.resolveIdsFrom(fullPathProp) : void 0) ?? collectionProp.path;
18474
- console.log("aaa", {
18475
- fullPathProp,
18476
- fullPath
18477
- });
18478
+ const fullPath = fullPathProp ?? collectionProp.path;
18478
18479
  const dataSource = useDataSource();
18479
18480
  const sideEntityController = useSideEntityController();
18480
18481
  const authController = useAuthController();
@@ -18545,6 +18546,7 @@ const EntityCollectionView = React__default.memo(function EntityCollectionView2(
18545
18546
  navigateToEntity({
18546
18547
  navigation,
18547
18548
  path,
18549
+ fullIdPath,
18548
18550
  sideEntityController,
18549
18551
  openEntityMode,
18550
18552
  collection: collection_1,
@@ -18561,6 +18563,7 @@ const EntityCollectionView = React__default.memo(function EntityCollectionView2(
18561
18563
  collection: collection_2,
18562
18564
  entityId: void 0,
18563
18565
  path: fullPath,
18566
+ fullIdPath,
18564
18567
  sideEntityController,
18565
18568
  navigation,
18566
18569
  onClose: unselectNavigatedEntity
@@ -18696,6 +18699,7 @@ const EntityCollectionView = React__default.memo(function EntityCollectionView2(
18696
18699
  entityId: entity_3.id,
18697
18700
  selectedTab: subcollection.id ?? subcollection.path,
18698
18701
  path: fullPath,
18702
+ fullIdPath,
18699
18703
  navigation,
18700
18704
  sideEntityController
18701
18705
  });
@@ -18751,7 +18755,7 @@ const EntityCollectionView = React__default.memo(function EntityCollectionView2(
18751
18755
  entity: entity_6,
18752
18756
  customEntityActions: collection.entityActions
18753
18757
  });
18754
- return /* @__PURE__ */ jsx(EntityCollectionRowActions, { entity: entity_6, width: width_0, frozen, isSelected, selectionEnabled, size: size_0, highlightEntity: setHighlightedEntity, unhighlightEntity: unselectNavigatedEntity, collection, fullPath, actions: actions_0, hideId: collection?.hideIdFromCollection, onCollectionChange: updateLastDeleteTimestamp, selectionController: usedSelectionController, openEntityMode });
18758
+ return /* @__PURE__ */ jsx(EntityCollectionRowActions, { entity: entity_6, width: width_0, frozen, isSelected, selectionEnabled, size: size_0, highlightEntity: setHighlightedEntity, unhighlightEntity: unselectNavigatedEntity, collection, fullPath: fullIdPath ?? fullPath, actions: actions_0, hideId: collection?.hideIdFromCollection, onCollectionChange: updateLastDeleteTimestamp, selectionController: usedSelectionController, openEntityMode });
18755
18759
  }, [updateLastDeleteTimestamp, usedSelectionController]);
18756
18760
  const title = /* @__PURE__ */ jsx(Popover, { open: popOverOpen, onOpenChange: setPopOverOpen, enabled: Boolean(collection.description), trigger: /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-start", children: [
18757
18761
  /* @__PURE__ */ jsx(Typography, { variant: "subtitle1", className: `leading-none truncate max-w-[160px] lg:max-w-[240px] ${collection.description ? "cursor-pointer" : "cursor-auto"}`, onClick: collection.description ? (e_2) => {
@@ -18793,7 +18797,7 @@ const EntityCollectionView = React__default.memo(function EntityCollectionView2(
18793
18797
  /* @__PURE__ */ jsx(AddIcon, {}),
18794
18798
  "Create your first entity"
18795
18799
  ] })
18796
- ] }) : /* @__PURE__ */ jsx(Typography, { variant: "label", children: "No results with the applied filter/sort" }), hoverRow, inlineEditing: checkInlineEditing(), AdditionalHeaderWidget: buildAdditionalHeaderWidget, AddColumnComponent: addColumnComponentInternal, getIdColumnWidth, additionalIDHeaderWidget: /* @__PURE__ */ jsx(EntityIdHeaderWidget, { path: fullPath, collection }), openEntityMode }, `collection_table_${fullPath}`),
18800
+ ] }) : /* @__PURE__ */ jsx(Typography, { variant: "label", children: "No results with the applied filter/sort" }), hoverRow, inlineEditing: checkInlineEditing(), AdditionalHeaderWidget: buildAdditionalHeaderWidget, AddColumnComponent: addColumnComponentInternal, getIdColumnWidth, additionalIDHeaderWidget: /* @__PURE__ */ jsx(EntityIdHeaderWidget, { path: fullPath, fullIdPath: fullIdPath ?? fullPath, collection }), openEntityMode }, `collection_table_${fullPath}`),
18797
18801
  popupCell && /* @__PURE__ */ jsx(PopupFormField, { open: Boolean(popupCell), onClose: onPopupClose, cellRect: popupCell?.cellRect, propertyKey: popupCell?.propertyKey, collection, entityId: popupCell.entityId, tableKey: tableKey.current, customFieldValidator: uniqueFieldValidator, path: resolvedFullPath, onCellValueChange: onValueChange, container: containerRef.current }, `popup_form_${popupCell?.propertyKey}_${popupCell?.entityId}`),
18798
18802
  deleteEntityClicked && /* @__PURE__ */ jsx(DeleteEntityDialog, { entityOrEntitiesToDelete: deleteEntityClicked, path: fullPath, collection, callbacks: collection.callbacks, open: Boolean(deleteEntityClicked), onEntityDelete: internalOnEntityDelete, onMultipleEntitiesDelete: internalOnMultipleEntitiesDelete, onClose: () => setDeleteEntityClicked(void 0) })
18799
18803
  ] });
@@ -18852,10 +18856,11 @@ function buildPropertyWidthOverwrite(key, width) {
18852
18856
  };
18853
18857
  }
18854
18858
  function EntityIdHeaderWidget(t0) {
18855
- const $ = c(40);
18859
+ const $ = c(42);
18856
18860
  const {
18857
18861
  collection,
18858
- path
18862
+ path,
18863
+ fullIdPath
18859
18864
  } = t0;
18860
18865
  const navigation = useNavigationController();
18861
18866
  const [openPopup, setOpenPopup] = React__default.useState(false);
@@ -18884,7 +18889,7 @@ function EntityIdHeaderWidget(t0) {
18884
18889
  t4 = $[3];
18885
18890
  }
18886
18891
  let t5;
18887
- if ($[4] !== collection || $[5] !== navigation || $[6] !== openEntityMode || $[7] !== path || $[8] !== searchString || $[9] !== sideEntityController) {
18892
+ if ($[4] !== collection || $[5] !== fullIdPath || $[6] !== navigation || $[7] !== openEntityMode || $[8] !== path || $[9] !== searchString || $[10] !== sideEntityController) {
18888
18893
  t5 = (e) => {
18889
18894
  e.preventDefault();
18890
18895
  if (!searchString) {
@@ -18898,77 +18903,79 @@ function EntityIdHeaderWidget(t0) {
18898
18903
  collection,
18899
18904
  entityId,
18900
18905
  path,
18906
+ fullIdPath,
18901
18907
  sideEntityController,
18902
18908
  navigation
18903
18909
  });
18904
18910
  };
18905
18911
  $[4] = collection;
18906
- $[5] = navigation;
18907
- $[6] = openEntityMode;
18908
- $[7] = path;
18909
- $[8] = searchString;
18910
- $[9] = sideEntityController;
18911
- $[10] = t5;
18912
+ $[5] = fullIdPath;
18913
+ $[6] = navigation;
18914
+ $[7] = openEntityMode;
18915
+ $[8] = path;
18916
+ $[9] = searchString;
18917
+ $[10] = sideEntityController;
18918
+ $[11] = t5;
18912
18919
  } else {
18913
- t5 = $[10];
18920
+ t5 = $[11];
18914
18921
  }
18915
18922
  let t6;
18916
- if ($[11] === Symbol.for("react.memo_cache_sentinel")) {
18923
+ if ($[12] === Symbol.for("react.memo_cache_sentinel")) {
18917
18924
  t6 = (e_0) => {
18918
18925
  setSearchString(e_0.target.value);
18919
18926
  };
18920
- $[11] = t6;
18927
+ $[12] = t6;
18921
18928
  } else {
18922
- t6 = $[11];
18929
+ t6 = $[12];
18923
18930
  }
18924
18931
  let t7;
18925
- if ($[12] !== openPopup || $[13] !== searchString) {
18932
+ if ($[13] !== openPopup || $[14] !== searchString) {
18926
18933
  t7 = /* @__PURE__ */ jsx("input", { autoFocus: openPopup, placeholder: "Find entity by ID", onChange: t6, value: searchString, className: "rounded-lg bg-white dark:bg-surface-800 flex-grow bg-transparent outline-none p-2 " + focusedDisabled });
18927
- $[12] = openPopup;
18928
- $[13] = searchString;
18929
- $[14] = t7;
18934
+ $[13] = openPopup;
18935
+ $[14] = searchString;
18936
+ $[15] = t7;
18930
18937
  } else {
18931
- t7 = $[14];
18938
+ t7 = $[15];
18932
18939
  }
18933
18940
  const t8 = !searchString.trim();
18934
18941
  let t9;
18935
- if ($[15] === Symbol.for("react.memo_cache_sentinel")) {
18942
+ if ($[16] === Symbol.for("react.memo_cache_sentinel")) {
18936
18943
  t9 = /* @__PURE__ */ jsx(KeyboardTabIcon, {});
18937
- $[15] = t9;
18944
+ $[16] = t9;
18938
18945
  } else {
18939
- t9 = $[15];
18946
+ t9 = $[16];
18940
18947
  }
18941
18948
  let t10;
18942
- if ($[16] !== t8) {
18949
+ if ($[17] !== t8) {
18943
18950
  t10 = /* @__PURE__ */ jsx(Button, { variant: "text", disabled: t8, type: "submit", children: t9 });
18944
- $[16] = t8;
18945
- $[17] = t10;
18951
+ $[17] = t8;
18952
+ $[18] = t10;
18946
18953
  } else {
18947
- t10 = $[17];
18954
+ t10 = $[18];
18948
18955
  }
18949
18956
  let t11;
18950
- if ($[18] !== t10 || $[19] !== t7) {
18957
+ if ($[19] !== t10 || $[20] !== t7) {
18951
18958
  t11 = /* @__PURE__ */ jsxs("div", { className: "flex p-2 w-full gap-2", children: [
18952
18959
  t7,
18953
18960
  t10
18954
18961
  ] });
18955
- $[18] = t10;
18956
- $[19] = t7;
18957
- $[20] = t11;
18962
+ $[19] = t10;
18963
+ $[20] = t7;
18964
+ $[21] = t11;
18958
18965
  } else {
18959
- t11 = $[20];
18966
+ t11 = $[21];
18960
18967
  }
18961
18968
  let t12;
18962
- if ($[21] !== t11 || $[22] !== t5) {
18969
+ if ($[22] !== t11 || $[23] !== t5) {
18963
18970
  t12 = /* @__PURE__ */ jsx("form", { noValidate: true, onSubmit: t5, className: "w-96 max-w-full", children: t11 });
18964
- $[21] = t11;
18965
- $[22] = t5;
18966
- $[23] = t12;
18971
+ $[22] = t11;
18972
+ $[23] = t5;
18973
+ $[24] = t12;
18967
18974
  } else {
18968
- t12 = $[23];
18975
+ t12 = $[24];
18969
18976
  }
18970
18977
  let t13;
18971
- if ($[24] !== collection || $[25] !== navigation || $[26] !== openEntityMode || $[27] !== path || $[28] !== recentIds || $[29] !== sideEntityController) {
18978
+ if ($[25] !== collection || $[26] !== fullIdPath || $[27] !== navigation || $[28] !== openEntityMode || $[29] !== path || $[30] !== recentIds || $[31] !== sideEntityController) {
18972
18979
  t13 = recentIds && recentIds.length > 0 && /* @__PURE__ */ jsx("div", { className: "flex flex-col gap-2 p-2", children: recentIds.map((id) => /* @__PURE__ */ jsx(ReferencePreview, { reference: new EntityReference(id, path), hover: true, onClick: () => {
18973
18980
  setOpenPopup(false);
18974
18981
  navigateToEntity({
@@ -18976,49 +18983,51 @@ function EntityIdHeaderWidget(t0) {
18976
18983
  collection,
18977
18984
  entityId: id,
18978
18985
  path,
18986
+ fullIdPath,
18979
18987
  sideEntityController,
18980
18988
  navigation
18981
18989
  });
18982
18990
  }, includeEntityLink: false, size: "small" }, id)) });
18983
- $[24] = collection;
18984
- $[25] = navigation;
18985
- $[26] = openEntityMode;
18986
- $[27] = path;
18987
- $[28] = recentIds;
18988
- $[29] = sideEntityController;
18989
- $[30] = t13;
18991
+ $[25] = collection;
18992
+ $[26] = fullIdPath;
18993
+ $[27] = navigation;
18994
+ $[28] = openEntityMode;
18995
+ $[29] = path;
18996
+ $[30] = recentIds;
18997
+ $[31] = sideEntityController;
18998
+ $[32] = t13;
18990
18999
  } else {
18991
- t13 = $[30];
19000
+ t13 = $[32];
18992
19001
  }
18993
19002
  let t14;
18994
- if ($[31] !== t12 || $[32] !== t13) {
19003
+ if ($[33] !== t12 || $[34] !== t13) {
18995
19004
  t14 = /* @__PURE__ */ jsxs("div", { className: t4, children: [
18996
19005
  t12,
18997
19006
  t13
18998
19007
  ] });
18999
- $[31] = t12;
19000
- $[32] = t13;
19001
- $[33] = t14;
19008
+ $[33] = t12;
19009
+ $[34] = t13;
19010
+ $[35] = t14;
19002
19011
  } else {
19003
- t14 = $[33];
19012
+ t14 = $[35];
19004
19013
  }
19005
19014
  let t15;
19006
- if ($[34] !== openPopup || $[35] !== t14) {
19015
+ if ($[36] !== openPopup || $[37] !== t14) {
19007
19016
  t15 = /* @__PURE__ */ jsx(Popover, { open: openPopup, onOpenChange: setOpenPopup, sideOffset: 0, align: "start", alignOffset: -117, trigger: t3, children: t14 });
19008
- $[34] = openPopup;
19009
- $[35] = t14;
19010
- $[36] = t15;
19017
+ $[36] = openPopup;
19018
+ $[37] = t14;
19019
+ $[38] = t15;
19011
19020
  } else {
19012
- t15 = $[36];
19021
+ t15 = $[38];
19013
19022
  }
19014
19023
  let t16;
19015
- if ($[37] !== t15 || $[38] !== t2) {
19024
+ if ($[39] !== t15 || $[40] !== t2) {
19016
19025
  t16 = /* @__PURE__ */ jsx(Tooltip, { title: t2, asChild: false, children: t15 });
19017
- $[37] = t15;
19018
- $[38] = t2;
19019
- $[39] = t16;
19026
+ $[39] = t15;
19027
+ $[40] = t2;
19028
+ $[41] = t16;
19020
19029
  } else {
19021
- t16 = $[39];
19030
+ t16 = $[41];
19022
19031
  }
19023
19032
  return t16;
19024
19033
  }
@@ -21274,6 +21283,7 @@ function EntityEditView({
21274
21283
  }
21275
21284
  function EntityEditViewInner({
21276
21285
  path,
21286
+ fullIdPath,
21277
21287
  entityId,
21278
21288
  selectedTab: selectedTabProp,
21279
21289
  collection,
@@ -21371,18 +21381,19 @@ function EntityEditViewInner({
21371
21381
  }), role: "tabpanel", children: /* @__PURE__ */ jsx(ErrorBoundary, { children: /* @__PURE__ */ jsx(EntityJsonPreview, { values: formContext?.values ?? entity?.values ?? {} }) }) }, "json_view");
21372
21382
  const subCollectionsViews = subcollections && subcollections.map((subcollection) => {
21373
21383
  const subcollectionId = subcollection.id ?? subcollection.path;
21374
- const fullPath = usedEntity ? `${path}/${usedEntity?.id}/${removeInitialAndTrailingSlashes(subcollectionId)}` : void 0;
21384
+ const newFullPath = usedEntity ? `${path}/${usedEntity?.id}/${removeInitialAndTrailingSlashes(subcollectionId)}` : void 0;
21385
+ const newFullIdPath = fullIdPath ? `${fullIdPath}/${usedEntity?.id}/${removeInitialAndTrailingSlashes(subcollectionId)}` : void 0;
21375
21386
  if (selectedTab !== subcollectionId) return null;
21376
21387
  return /* @__PURE__ */ jsxs("div", { className: "relative flex-1 h-full overflow-auto w-full", role: "tabpanel", children: [
21377
21388
  globalLoading && /* @__PURE__ */ jsx(CircularProgressCenter, {}),
21378
- !globalLoading && (usedEntity && fullPath ? /* @__PURE__ */ jsx(EntityCollectionView, { fullPath, parentCollectionIds: [...parentCollectionIds, collection.id], isSubCollection: true, updateUrl: false, ...subcollection, openEntityMode: layout }) : /* @__PURE__ */ jsx("div", { className: "flex items-center justify-center w-full h-full p-3", children: /* @__PURE__ */ jsx(Typography, { variant: "label", children: "You need to save your entity before adding additional collections" }) }))
21389
+ !globalLoading && (usedEntity && newFullPath ? /* @__PURE__ */ jsx(EntityCollectionView, { fullPath: newFullPath, fullIdPath: newFullIdPath, parentCollectionIds: [...parentCollectionIds, collection.id], isSubCollection: true, updateUrl: false, ...subcollection, openEntityMode: layout }) : /* @__PURE__ */ jsx("div", { className: "flex items-center justify-center w-full h-full p-3", children: /* @__PURE__ */ jsx(Typography, { variant: "label", children: "You need to save your entity before adding additional collections" }) }))
21379
21390
  ] }, `subcol_${subcollectionId}`);
21380
21391
  }).filter(Boolean);
21381
21392
  const onSideTabClick = (value_0) => {
21382
21393
  setSelectedTab(value_0);
21383
21394
  if (status === "existing") {
21384
21395
  onTabChange?.({
21385
- path,
21396
+ path: fullIdPath ?? path,
21386
21397
  entityId,
21387
21398
  selectedTab: value_0 === MAIN_TAB_VALUE ? void 0 : value_0,
21388
21399
  collection
@@ -21699,6 +21710,7 @@ function buildSidePanelsFromUrl(path, collections, newFlag) {
21699
21710
  if (navigationEntry.type === "entity") {
21700
21711
  sidePanel = {
21701
21712
  path: navigationEntry.path,
21713
+ // fullIdPath: navigationEntry.path,
21702
21714
  entityId: navigationEntry.entityId,
21703
21715
  copy: false,
21704
21716
  width: navigationEntry.parentCollection?.sideDialogWidth
@@ -21716,6 +21728,7 @@ function buildSidePanelsFromUrl(path, collections, newFlag) {
21716
21728
  if (newFlag) {
21717
21729
  sidePanel = {
21718
21730
  path: lastCollectionPath,
21731
+ // fullIdPath: lastCollectionPath,
21719
21732
  copy: false
21720
21733
  };
21721
21734
  }
@@ -21724,10 +21737,8 @@ function buildSidePanelsFromUrl(path, collections, newFlag) {
21724
21737
  const propsToSidePanel = (props, buildUrlCollectionPath, resolveIdsFrom, smallLayout, customizationController, authController) => {
21725
21738
  const collectionPath = removeInitialAndTrailingSlashes(props.path);
21726
21739
  const newPath = props.entityId ? buildUrlCollectionPath(`${collectionPath}/${props.entityId}${props.selectedTab ? "/" + props.selectedTab : ""}#${SIDE_URL_HASH}`) : buildUrlCollectionPath(`${collectionPath}#${NEW_URL_HASH}`);
21727
- const resolvedPath = resolveIdsFrom(props.path);
21728
21740
  const resolvedPanelProps = {
21729
21741
  ...props,
21730
- path: resolvedPath,
21731
21742
  formProps: props.formProps
21732
21743
  };
21733
21744
  const entityViewWidth = getEntityViewWidth(props, smallLayout, customizationController, authController);
@@ -23229,7 +23240,7 @@ function FireCMSRoute() {
23229
23240
  } else {
23230
23241
  t8 = $[27];
23231
23242
  }
23232
- t62 = /* @__PURE__ */ jsx(EntityCollectionView, { isSubCollection: false, parentCollectionIds: t8, fullPath: collection_0.id, updateUrl: true, ...collection_0, Actions: toArray(collection_0.Actions) }, `collection_view_${collection_0.id ?? collection_0.path}`);
23243
+ t62 = /* @__PURE__ */ jsx(EntityCollectionView, { fullIdPath: collection_0.id, isSubCollection: false, parentCollectionIds: t8, fullPath: collection_0.id, updateUrl: true, ...collection_0, Actions: toArray(collection_0.Actions) }, `collection_view_${collection_0.id ?? collection_0.path}`);
23233
23244
  }
23234
23245
  $[23] = navigation;
23235
23246
  $[24] = navigationEntries;
@@ -23318,9 +23329,10 @@ function EntityFullScreenRoute({
23318
23329
  return /* @__PURE__ */ jsx(NotFoundPage, {});
23319
23330
  }
23320
23331
  const collection = isNew ? lastCollectionEntry.collection : lastEntityEntry.parentCollection;
23321
- const collectionPath = navigation.resolveIdsFrom(isNew ? lastCollectionEntry.path : lastEntityEntry.path);
23332
+ const fullIdPath = isNew ? lastCollectionEntry.path : lastEntityEntry.path;
23333
+ const collectionPath = navigation.resolveIdsFrom(fullIdPath);
23322
23334
  return /* @__PURE__ */ jsxs(Fragment, { children: [
23323
- /* @__PURE__ */ jsx(EntityEditView, { entityId: isNew ? void 0 : entityId, collection, layout: "full_screen", path: collectionPath, copy: isCopy, selectedTab: selectedTab ?? void 0, onValuesModified: (modified) => blocked.current = modified, onSaved: (params) => {
23335
+ /* @__PURE__ */ jsx(EntityEditView, { entityId: isNew ? void 0 : entityId, fullIdPath, collection, layout: "full_screen", path: collectionPath, copy: isCopy, selectedTab: selectedTab ?? void 0, onValuesModified: (modified) => blocked.current = modified, onSaved: (params) => {
23324
23336
  const newSelectedTab = params.selectedTab;
23325
23337
  const newEntityId = params.entityId;
23326
23338
  if (newSelectedTab) {