5.0.0
This release adds new functionality around expanding and collapsing related entities in Network Graph related components. We've moved the @senzing/sdk-graph-components to the scope of this package for easier maintenance and installation(now you just need this package instead of two). We're also adding the Why Not component that can be embedded between two or more entities to generate a report to show why two entities/records did not resolve.
2022-07-07.10-56-17.mp4
Added
- The
SzWhyEntitiesComparisonComponentadded for doing WHY comparison between entities. Adds the ability to run "Why Not" Reports from within the context of the search results and graph. - The following input parameters added to
SzSearchResultsComponent:showWhyComparisonButtonenables a multi-select button behavior for search results that when clicked allows a user to click to toggle selection of an entity in the results then click the button to show a WHY NOT report for differences between those two entities.
- The follwing getters and setters added to
SzEntityDetailComponentshowGraphContextMenuenables the built-in context menu for entity nodes on the graph embedded in the entity detail component.showGraphLinkContextMenuenables the built-in context menu for relationship lines/labels on the graph embedded in the entity detail component.graphMatchKeyTokenSelectionScopepossible values are "CORE" and "EXTRANEOUS". core sets the scope of match key token filtering to just entities directly related to the focused/primary entity of the graph. defaults toEXTRANEOUS.
- The following Event Emitters added to
SzEntityDetailComponentgraphRelationshipContextMenuClickis emitted when a user right clicks on relationship lines/labels in the embedded graph component.graphRelationshipClickis emitted when a user clicks on relationship lines/labels in the embedded graph component.
- The following properties added to
SzGraphComponentand are inheirited bySzStandaloneGraphComponentandSzEntityDetailGraphComponent.matchKeyTokenSelectionScopepossible values are "CORE" and "EXTRANEOUS". core sets the scope of match key token filtering to just entities directly related to the focused/primary entity of the graph. defaults toEXTRANEOUS.
- The following methods added to
SzGraphComponentand are inheirited bySzStandaloneGraphComponentandSzEntityDetailGraphComponent.canRemoveNode(entityId: SzEntityIdentifier)returns boolean if an entity on canvas can be removed(root nodes, and primary query nodes cannot).canExpandNode(entityId: SzEntityIdentifier)returns boolean if a node has hidden related entities that can be shown on canvas.removeNode(entityId: SzEntityIdentifier)removes a single node and any directly related nodescollapseNode(entityId: SzEntityIdentifier)hide all visible(expanded) entities related to a specific entity that are themselves not related to any other visible entities.expandNode(entityId: SzEntityIdentifier)show any entities that are related to a specific entity that are currently not on the canvas.
- The following event emitters added to
SzGraphComponentrelationshipContextMenuClickis emitted when a user right clicks on relationship lines/labels in the embedded graph component.relationshipClickis emitted when a user clicks on relationship lines/labels in the embedded graph component.
- The following methods added to
SzEntityDetailComponentisGraphEntityRemovable(entityId: SzEntityIdentifier)can a specific entity node be removed from canvas.showGraphEntityRelationships(entityId: SzEntityIdentifier)show any entities that are related to a specific entity that are currently not on the canvas.hideGraphEntityRelationships(entityId: SzEntityIdentifier)hide all visible(expanded) entities related to a specific entity that are themselves not related to any other visible entities.hideGraphEntity(entityId: SzEntityIdentifier)remove single node and any directly related nodes that are only related to the entity specified.
SzRelationshipNetworkComponentmoved from@senzing/sdk-graph-componentsSzRelationshipNetworkInputComponentmoved from@senzing/sdk-graph-componentsSzRelationshipNetworkLookupComponentmoved from@senzing/sdk-graph-componentsSzRelationshipPathComponentmoved from@senzing/sdk-graph-components- The following methods added to
SzRelationshipNetworkComponentcanExpandNodedoes a node have hidden related nodes that can be displayed.expandNodeshow all hidden nodes related to the node specified.canRemoveNodecan a node be removed.removeNoderemoves a single node, all it's related and/or both.centercenters the graph viewport.addExistingNodeDataused for data merge/transform operation.addLinksToNodeDataused for data merge/transform operation.asEntityNetworkDatagets the state of graph nodes/links asEntityNetworkDataonLinkClickwhen a user clicks on a relationship link line or label.onLinkDblClickwhen a user double clicks on a relationship link line or label.onLinkContextClickwhen a user right clicks on a relationship link line or label.getNodeByIdQueryreturns a D3.Selection of the node that matches the entity id provided.getNodesByIdQueryreturns a D3.Selection of the nodes that match the entity ids provided.getHiddenNodeIdsreturn an array of entity ids for nodes that exist on canvas but are not currently visible.updateHiddenRelationshipCountsupdate the relationship count bubble inside a entity node with the value from numberRelatedHidden.getRelatedNodesByIdQueryreturns a D3.Selection of nodes that match the entity ids providedupdateIsHiddenForLinksensure that a link node(line) is not visible if one of the connected nodes is not visiblegetEntityNodeClassget the css classes as a space separate string to apply to an entity node.getEntityLinkClassget the css classes as a space separate string to apply to an entity link node(line).getEntityLinkLabelClassget the css classes as a space separate string to apply to an entity link node.expandCollapseToggletoggles the collapsed or expanded nodes related to a nodeupdateHasCollapsedRelationshipsafter a collapse or expand event all of the nodes on canvas's properties related to collapse/expand must be updated in order to calculate whether or not a node still has hidden related entities.
- The following event emitters added to
SzRelationshipNetworkComponentrelationshipClickwhen a user clicks on a relationship link line or label.relationshipDblClickwhen a user double clicks on a relationship link line or label.relationshipContextMenuClickwhen a user right clicks on a relationship link line or label.onDataUpdatedwhen new data is added to the store representing the state of the graph this event is emitted with the result ofasEntityNetworkData()onShowRelatedEntitiesevent emitted when the user expands or collapses a entity nodes related nodes.onHideRelatedEntitiesevent emitted when the user expands or collapses a entity nodes related nodes.
- Major refactoring around the draw mechanism inside
SzRelationshipNetworkComponent.addSvg()method reorganized or rewritten. The following subroutines added:getNodeVisibilityClassreturns a array with the string ofsz-node-state-hiddenif node is supposed to be hidden. (used for css queries)setNodePositionsAsCircletakes a selection of entity nodes and places their X,Y positions on an arc path(circle) around a central point.applyPositionToNodestakes the X/Y values set on a node's data property and converts them to CSS transform propertiesupdateLinksForNodeswhen a node(s) position has changed this sub is called to keep the end of the link path attached to the node being movedattachEventListenersToNodesattach internal handlers for things like click, drag, mouseover events to a selection of nodes so handlers are called.stopEventListenersForNodesremove event handers for a selection of nodesattachEventListenersToLinksattach internal handlers for things like click, drag, mouseover events to a selection of nodes so handlers are called.polarToCartesiandependency for drawing concentric ringsdescribeArcdependency for drawing concentric ringscircleCoorddependency for drawing concentric ringsgetRingSchemaForNodesgets a object describing a ring based drawing layout for nodesdrawNodesInRingstakes a collection of entities and lays them out in increasing diameter along rings around an X and Y origin.drawLinksdraws the links between entity nodes on svg canvasdrawNodesdraws the entity nodes on svg canvasonExpandCollapseClickevent handler for when a node's expand or collapsed glyph is clicked on.
SzRelationshipNetworkComponent.onNodeContextClickadded the following to thecontextMenuClickevent emitter so the context menu could be positioned correctly.eventPageXthe x position on the page non-relative that the event occurred at.eventPageYthe y position on the page non-relative that the event occurred at.
SzRelationshipNetworkComponent.contextMenuClickeventPageXthe x position on the page non-relative that the event occurred at.eventPageYthe y position on the page non-relative that the event occurred at.
Removed
- The following methods have been removed from
SzRelationshipNetworkComponentonSimulationCyclegravity simulation has been removed in favor or concentric ring algorithm.unlockForcePositiongravity simulation has been removed in favor or concentric ring algorithm.lockForcePositiongravity simulation has been removed in favor or concentric ring algorithm.fadeused to highlight directly related nodes by changing the opacity of all unrelated nodeslinkfadeused to highlight directly related nodes by changing the opacity of all unrelated nodesonNodeDragEndedno longer needed
Modified
_graphIdsproperty onSzGraphComponenttype changed fromnumber[]toSzEntityIdentifier[]graphIdsproperty getter and setter onSzGraphComponenttype changed fromnumber[]toSzEntityIdentifier[]reloadmethod inSzGraphComponentparameter type changed tostring | number | SzEntityIdentifier | SzEntityIdentifier[]- Major refactoring around the draw mechanism inside
SzRelationshipNetworkComponent. Almost all of the routiines inaddSvgmethod reorganized or rewritten. The following subroutines addedonNodeContextClickadded the following to thecontextMenuClickevent emmitter so the context menu could be positioned correctly.eventPageXthe x position on the page non-relative that the event occurred at.eventPageYthe y position on the page non-relative that the event occurred at.
contextMenuClickeventPageXthe x position on the page non-relative that the event occurred at.eventPageYthe y position on the page non-relative that the event occurred at.
relevant tickets: #280 #299 #302 #304 #307 #310 #311 #313 #315 #319 #321