Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
export function isResizeable(element: SModelElement): element is SParentElement & BoundsAware {
return element.hasFeature(resizeFeature) && isBoundsAware(element) && isSelectable(element) && element instanceof SParentElement;
}
export function isResizable(element: SModelElement): element is SParentElement & Resizable {
return isBoundsAware(element) && isSelectable(element) && element instanceof SParentElement && element.hasFeature(resizeFeature);
}
export function isSelected(element: SModelElement | undefined): element is SModelElement & Selectable {
return isNotUndefined(element) && isSelectable(element) && element.selected;
}
const deleteElementIds = Array.from(element.root.index.all().filter(e => isDeletable(e) && isSelectable(e) && e.selected)
.filter(e => e.id !== e.root.id).map(e => e.id));
.filter(element => isSelectable(element) && element.selected)
.forEach(element => {
const selected = toArray(element.root.index.all().filter(e => isSelectable(e) && e.selected)).map(e => e.id);
return [new ShowDiagramUIExtensionAction(CommandPalette.ID, selected)];