Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CSCFC4EMSCR-599 Fix mapping table rendering for all schema formats pull request to develop #231

Merged
merged 4 commits into from
Nov 13, 2024

Conversation

masillan
Copy link
Member

Aded root element as parent class to path in SHACL format where mapped element is the child of root element. Returning label / name of mapped element, if format is not SHACL, Xsd ,Csv Jsonschema, Enum or Mscr.

…dded root element as parent class to path in SHACL format where mapped element is the child of root element. Returning label / name of mapped element, if format is not SHACL, Xsd ,Csv Jsonschema, Enum or Mscr.
@masillan masillan self-assigned this Nov 11, 2024
Copy link

@maariaw maariaw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't test separately, since @jkesanie said it looked good. I commented on just a couple formatting things, but it might be best if you just fixed all of the formatting at some point later, after we get your automatic lint checker to work.

@@ -376,18 +376,11 @@ function returnPath(id: string, label: string, schemaFormat: Format | undefined,
}
}
return returnString;
} else {

let className = '';
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Leftover unreachable code

className = id.substring(id?.lastIndexOf('/') + 1, label.lastIndexOf('#')) + ':';
let itemName = id.substring(id.lastIndexOf('#') + 1);
returnString = className + itemName;
}
} else if (schemaFormat === Format.Shacl) {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check the indentation, seems like this whole block might have one extra indentation, since it should be level with the original if-statement.

@masillan masillan merged commit 1ce8bce into develop Nov 13, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants