Skip to content

Commit

Permalink
CSCFC4EMSCR-585 Rename node property elementPath to rootPathIds
Browse files Browse the repository at this point in the history
  • Loading branch information
maariaw committed Dec 11, 2024
1 parent 995160d commit 86d6bac
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion mscr-ui/src/common/components/schema-info/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ export default function SchemaInfo(props: {
nodeIds.forEach((nodeId) => {
const nodes = nodeIdToNodeDictionary[nodeId];
nodes.map((node) => {
idsOnPath = idsOnPath.concat(node.elementPath);
idsOnPath = idsOnPath.concat(node.rootPathIds);
});
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ let treeIndex = 0;

function createRenderTree(
input: any,
elementPath: string[],
rootPathIds: string[],
definitions: any,
idToNodeDictionary: { [key: string]: RenderTree[] },
) {
Expand All @@ -16,7 +16,7 @@ function createRenderTree(
visualTreeId: treeIndex.toString(),
id: obj.toString(),
properties: definitions[obj],
elementPath: [...elementPath, obj.toString()],
rootPathIds: [...rootPathIds, obj.toString()],
children: [],
uri: definitions[obj]['@id'],
};
Expand All @@ -28,7 +28,7 @@ function createRenderTree(
// HAS CHILDREN, OTHERWISE IS LEAF
newNode.children = createRenderTree(
input[obj],
newNode.elementPath,
newNode.rootPathIds,
definitions,
idToNodeDictionary,
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ export interface RenderTree {
visualTreeId: string;
id: string;
properties: any;
elementPath: string[];
rootPathIds: string[];
children: RenderTree[];
uri: string;
}
Expand Down
2 changes: 1 addition & 1 deletion mscr-ui/src/modules/crosswalk-editor/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export default function CrosswalkEditor({
const isEditModeActive = useSelector(selectIsEditContentActive());

const emptyTreeSelection: RenderTree = {
elementPath: [],
rootPathIds: [],
name: '',
id: '',
visualTreeId: '',
Expand Down

0 comments on commit 86d6bac

Please sign in to comment.