@graphty/graphty-element / session / Selector
Type Alias: Selector ​
Selector = {
match:"expression";where:Query; } | {match:"has";path:Path; } | {edges?: readonlyEdgeId[];match:"ids";nodes?: readonlyNodeId[]; } | {match:"top";n:number;path:Path; } | {match:"everything"; } | {match:"member";of:Scope; }
Defined in: graphty-element/src/catalog/types.ts:625
What a layer matches. Spelled out rather than implied, so it is greppable and lintable.
OPEN UNION: kinds may be added in a minor release; handle unknown kinds.
Union Members ​
Type Literal ​
{ match: "expression"; where: Query; }
Type Literal ​
{ match: "has"; path: Path; }
Type Literal ​
{ edges?: readonly EdgeId[]; match: "ids"; nodes?: readonly NodeId[]; }
Type Literal ​
{ match: "top"; n: number; path: Path; }
The top n elements by one run field (results.<run>.<field>), cut only between tie groups: a group of equal values is painted whole, and only when all of it fits inside n. See TopRanking for the policy.
Type Literal ​
{ match: "everything"; }
Type Literal ​
{ match: "member"; of: Scope; }
The members of a scope, usually a kept set: { match: "member", of: { set: id } }. The layer follows the set: a redefinition repaints exactly the elements that moved. A removed set paints from its kept record, so removing a set never blanks a layer; a scope that cannot be evaluated paints nothing and never throws.