@neo4j-ndl/react-graph 1.2.44 → 1.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/cjs/graph-visualization-buttons.js +1 -3
- package/lib/cjs/graph-visualization-buttons.js.map +1 -1
- package/lib/cjs/graph-visualization-context.js.map +1 -1
- package/lib/cjs/graph-visualization.js +7 -5
- package/lib/cjs/graph-visualization.js.map +1 -1
- package/lib/cjs/index.js.map +1 -1
- package/lib/cjs/sidepanel-components/details-panel.js +5 -11
- package/lib/cjs/sidepanel-components/details-panel.js.map +1 -1
- package/lib/cjs/sidepanel-components/graph-label-wrapper.js +40 -0
- package/lib/cjs/sidepanel-components/graph-label-wrapper.js.map +1 -0
- package/lib/cjs/sidepanel-components/overview-panel.js +3 -12
- package/lib/cjs/sidepanel-components/overview-panel.js.map +1 -1
- package/lib/cjs/stories/graph-visualization-rule-based-styling-advanced.story.js +247 -0
- package/lib/cjs/stories/graph-visualization-rule-based-styling-advanced.story.js.map +1 -0
- package/lib/cjs/stories/graph-visualization-rule-based-styling.story.js +79 -0
- package/lib/cjs/stories/graph-visualization-rule-based-styling.story.js.map +1 -0
- package/lib/cjs/stories/graph-visualization-simple-styling.story.js +57 -0
- package/lib/cjs/stories/graph-visualization-simple-styling.story.js.map +1 -0
- package/lib/cjs/stories/index.js +23 -10
- package/lib/cjs/stories/index.js.map +1 -1
- package/lib/cjs/stories/story-data.js +906 -3
- package/lib/cjs/stories/story-data.js.map +1 -1
- package/lib/cjs/styling/compile-graph-styles.js +22 -21
- package/lib/cjs/styling/compile-graph-styles.js.map +1 -1
- package/lib/cjs/styling/create-vis-data-structures.js +126 -0
- package/lib/cjs/styling/create-vis-data-structures.js.map +1 -0
- package/lib/cjs/styling/use-graph-data.js +35 -0
- package/lib/cjs/styling/use-graph-data.js.map +1 -0
- package/lib/cjs/utils.js +23 -9
- package/lib/cjs/utils.js.map +1 -1
- package/lib/esm/graph-visualization-buttons.js +1 -3
- package/lib/esm/graph-visualization-buttons.js.map +1 -1
- package/lib/esm/graph-visualization-context.js.map +1 -1
- package/lib/esm/graph-visualization.js +7 -5
- package/lib/esm/graph-visualization.js.map +1 -1
- package/lib/esm/index.js.map +1 -1
- package/lib/esm/sidepanel-components/details-panel.js +6 -12
- package/lib/esm/sidepanel-components/details-panel.js.map +1 -1
- package/lib/esm/sidepanel-components/graph-label-wrapper.js +33 -0
- package/lib/esm/sidepanel-components/graph-label-wrapper.js.map +1 -0
- package/lib/esm/sidepanel-components/overview-panel.js +4 -13
- package/lib/esm/sidepanel-components/overview-panel.js.map +1 -1
- package/lib/esm/stories/graph-visualization-rule-based-styling-advanced.story.js +244 -0
- package/lib/esm/stories/graph-visualization-rule-based-styling-advanced.story.js.map +1 -0
- package/lib/esm/stories/graph-visualization-rule-based-styling.story.js +76 -0
- package/lib/esm/stories/graph-visualization-rule-based-styling.story.js.map +1 -0
- package/lib/esm/stories/graph-visualization-simple-styling.story.js +54 -0
- package/lib/esm/stories/graph-visualization-simple-styling.story.js.map +1 -0
- package/lib/esm/stories/index.js +18 -8
- package/lib/esm/stories/index.js.map +1 -1
- package/lib/esm/stories/story-data.js +905 -2
- package/lib/esm/stories/story-data.js.map +1 -1
- package/lib/esm/styling/compile-graph-styles.js +22 -21
- package/lib/esm/styling/compile-graph-styles.js.map +1 -1
- package/lib/esm/styling/create-vis-data-structures.js +122 -0
- package/lib/esm/styling/create-vis-data-structures.js.map +1 -0
- package/lib/esm/styling/use-graph-data.js +32 -0
- package/lib/esm/styling/use-graph-data.js.map +1 -0
- package/lib/esm/utils.js +20 -8
- package/lib/esm/utils.js.map +1 -1
- package/lib/types/graph-visualization-buttons.d.ts.map +1 -1
- package/lib/types/graph-visualization-context.d.ts +15 -9
- package/lib/types/graph-visualization-context.d.ts.map +1 -1
- package/lib/types/graph-visualization.d.ts +8 -1
- package/lib/types/graph-visualization.d.ts.map +1 -1
- package/lib/types/index.d.ts +2 -1
- package/lib/types/index.d.ts.map +1 -1
- package/lib/types/sidepanel-components/details-panel.d.ts.map +1 -1
- package/lib/types/{map-to-nvl-graph.d.ts → sidepanel-components/graph-label-wrapper.d.ts} +10 -17
- package/lib/types/sidepanel-components/graph-label-wrapper.d.ts.map +1 -0
- package/lib/types/sidepanel-components/overview-panel.d.ts.map +1 -1
- package/lib/types/stories/graph-visualization-rule-based-styling-advanced.story.d.ts +33 -0
- package/lib/types/stories/graph-visualization-rule-based-styling-advanced.story.d.ts.map +1 -0
- package/lib/types/stories/graph-visualization-rule-based-styling.story.d.ts +25 -0
- package/lib/types/stories/graph-visualization-rule-based-styling.story.d.ts.map +1 -0
- package/lib/types/stories/graph-visualization-simple-styling.story.d.ts +25 -0
- package/lib/types/stories/graph-visualization-simple-styling.story.d.ts.map +1 -0
- package/lib/types/stories/index.d.ts +7 -1
- package/lib/types/stories/index.d.ts.map +1 -1
- package/lib/types/stories/story-data.d.ts +4 -0
- package/lib/types/stories/story-data.d.ts.map +1 -1
- package/lib/types/styling/compile-graph-styles.d.ts +2 -5
- package/lib/types/styling/compile-graph-styles.d.ts.map +1 -1
- package/lib/types/styling/create-vis-data-structures.d.ts +28 -0
- package/lib/types/styling/create-vis-data-structures.d.ts.map +1 -0
- package/lib/types/styling/style-types.d.ts +2 -2
- package/lib/types/styling/use-graph-data.d.ts +28 -0
- package/lib/types/styling/use-graph-data.d.ts.map +1 -0
- package/lib/types/utils.d.ts +5 -3
- package/lib/types/utils.d.ts.map +1 -1
- package/package.json +1 -1
- package/lib/cjs/map-to-nvl-graph.js +0 -167
- package/lib/cjs/map-to-nvl-graph.js.map +0 -1
- package/lib/esm/map-to-nvl-graph.js +0 -162
- package/lib/esm/map-to-nvl-graph.js.map +0 -1
- package/lib/types/map-to-nvl-graph.d.ts.map +0 -1
package/lib/esm/utils.js
CHANGED
|
@@ -34,27 +34,39 @@ export const searchProperties = (properties, text) => {
|
|
|
34
34
|
}
|
|
35
35
|
return false;
|
|
36
36
|
};
|
|
37
|
-
export const searchNodes = (
|
|
37
|
+
export const searchNodes = (graph, text) => {
|
|
38
38
|
const q = text.toLowerCase();
|
|
39
|
-
return nodes
|
|
39
|
+
return graph.nodes
|
|
40
40
|
.filter((node) => {
|
|
41
41
|
var _a;
|
|
42
|
-
|
|
42
|
+
const data = graph.nodeData[node.id];
|
|
43
|
+
if (data === undefined) {
|
|
44
|
+
return false;
|
|
45
|
+
}
|
|
46
|
+
if ((_a = data.labelsSorted) === null || _a === void 0 ? void 0 : _a.some((l) => l.toLowerCase().includes(q))) {
|
|
43
47
|
return true;
|
|
44
48
|
}
|
|
45
|
-
return searchProperties(
|
|
49
|
+
return searchProperties(data.properties, q);
|
|
46
50
|
})
|
|
47
51
|
.map((node) => node.id);
|
|
48
52
|
};
|
|
49
|
-
export const searchRels = (
|
|
53
|
+
export const searchRels = (graph, text) => {
|
|
50
54
|
const q = text.toLowerCase();
|
|
51
|
-
return rels
|
|
55
|
+
return graph.rels
|
|
52
56
|
.filter((rel) => {
|
|
53
|
-
|
|
57
|
+
const data = graph.relData[rel.id];
|
|
58
|
+
if (data === undefined) {
|
|
59
|
+
return false;
|
|
60
|
+
}
|
|
61
|
+
if (data.type.toLowerCase().includes(q)) {
|
|
54
62
|
return true;
|
|
55
63
|
}
|
|
56
|
-
return searchProperties(
|
|
64
|
+
return searchProperties(data.properties, q);
|
|
57
65
|
})
|
|
58
66
|
.map((rel) => rel.id);
|
|
59
67
|
};
|
|
68
|
+
export const removeLicenseHeader = (source) => {
|
|
69
|
+
return source.replace(/^\/\*[\s\S]*?\*\/\s*/, '');
|
|
70
|
+
};
|
|
71
|
+
export const sortAlphabetically = (a = '', b = '') => a.toLowerCase().localeCompare(b.toLowerCase());
|
|
60
72
|
//# sourceMappingURL=utils.js.map
|
package/lib/esm/utils.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../../src/utils.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG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AE,CAAC;IAE7B,OAAO,KAAK,CAAC,IAAI;SACd,MAAM,CAAC,CAAC,GAAG,EAAE,EAAE;QACd,MAAM,IAAI,GAAG,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;QACnC,IAAI,IAAI,KAAK,SAAS,EAAE,CAAC;YACvB,OAAO,KAAK,CAAC;QACf,CAAC;QAED,IAAI,IAAI,CAAC,IAAI,CAAC,WAAW,EAAE,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,CAAC;YACxC,OAAO,IAAI,CAAC;QACd,CAAC;QAED,OAAO,gBAAgB,CAAC,IAAI,CAAC,UAAU,EAAE,CAAC,CAAC,CAAC;IAC9C,CAAC,CAAC;SACD,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;AAC1B,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,MAAc,EAAU,EAAE;IAC5D,OAAO,MAAM,CAAC,OAAO,CAAC,sBAAsB,EAAE,EAAE,CAAC,CAAC;AACpD,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,kBAAkB,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,EAAE,EAAE,EAAE,CACnD,CAAC,CAAC,WAAW,EAAE,CAAC,aAAa,CAAC,CAAC,CAAC,WAAW,EAAE,CAAC,CAAC","sourcesContent":["/**\n *\n * Copyright (c) \"Neo4j\"\n * Neo4j Sweden AB [http://neo4j.com]\n *\n * This file is part of Neo4j.\n *\n * Neo4j is free software: you can redistribute it and/or modify\n * it under the terms of the GNU General Public License as published by\n * the Free Software Foundation, either version 3 of the License, or\n * (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU General Public License for more details.\n *\n * You should have received a copy of the GNU General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n */\n\nimport { type NvlGraph } from './graph-visualization-context';\n\nexport const isMac = navigator.userAgent.includes('Mac');\n\nconst uniq = (arr: string[]) => [...new Set(arr)];\n\nexport const xor = (a: string[], b: string[]) =>\n uniq([...a, ...b].filter((id) => !a.includes(id) || !b.includes(id)));\n\nexport const mapValues = <T, R>(\n obj: Record<string, T>,\n fn: (value: T) => R,\n): Record<string, R> =>\n Object.fromEntries(\n Object.entries(obj).map(([key, value]) => [key, fn(value)]),\n );\n\nexport const searchProperties = (\n properties: Record<string, { stringified: string }>,\n text: string,\n): boolean => {\n for (const [propName, propValue] of Object.entries(properties)) {\n const isNameMatch = propName.toLowerCase().includes(text);\n const raw = propValue?.stringified ?? '';\n const isValueMatch = raw.toLowerCase().includes(text);\n\n if (isNameMatch || isValueMatch) {\n return true;\n }\n }\n\n return false;\n};\n\nexport const searchNodes = (graph: NvlGraph, text: string): string[] => {\n const q = text.toLowerCase();\n\n return graph.nodes\n .filter((node) => {\n const data = graph.nodeData[node.id];\n if (data === undefined) {\n return false;\n }\n\n if (data.labelsSorted?.some((l) => l.toLowerCase().includes(q))) {\n return true;\n }\n\n return searchProperties(data.properties, q);\n })\n .map((node) => node.id);\n};\n\nexport const searchRels = (graph: NvlGraph, text: string): string[] => {\n const q = text.toLowerCase();\n\n return graph.rels\n .filter((rel) => {\n const data = graph.relData[rel.id];\n if (data === undefined) {\n return false;\n }\n\n if (data.type.toLowerCase().includes(q)) {\n return true;\n }\n\n return searchProperties(data.properties, q);\n })\n .map((rel) => rel.id);\n};\n\nexport const removeLicenseHeader = (source: string): string => {\n return source.replace(/^\\/\\*[\\s\\S]*?\\*\\/\\s*/, '');\n};\n\nexport const sortAlphabetically = (a = '', b = '') =>\n a.toLowerCase().localeCompare(b.toLowerCase());\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"graph-visualization-buttons.d.ts","sourceRoot":"","sources":["../../src/graph-visualization-buttons.tsx"],"names":[],"mapp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AOjC,6BAA6B,GAAG;IACjC,aAAa,CAAC,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,IAAI,CAAC,CAAC,WAAW,CAAC,CAAC;IAC/D,cAAc,CAAC,EAAE,OAAO,CAAC,mBAAmB,CAAC,CAAC;CAC/C,4CA2CA,CAAC"}
|
|
@@ -20,6 +20,7 @@
|
|
|
20
20
|
*/
|
|
21
21
|
import type NVL from '@neo4j-nvl/base';
|
|
22
22
|
import { type Layout, type Node, type Relationship } from '@neo4j-nvl/base';
|
|
23
|
+
import { type CompiledStyleRules } from './styling/compile-graph-styles';
|
|
23
24
|
export type GraphSelection = {
|
|
24
25
|
nodeIds: string[];
|
|
25
26
|
relationshipIds: string[];
|
|
@@ -34,20 +35,25 @@ export type Sidepanel = {
|
|
|
34
35
|
};
|
|
35
36
|
export type NvlGraph = {
|
|
36
37
|
nodes: Node[];
|
|
38
|
+
nodeData: Record<string, NodeData>;
|
|
37
39
|
rels: Relationship[];
|
|
38
|
-
|
|
40
|
+
relData: Record<string, RelData>;
|
|
41
|
+
};
|
|
42
|
+
export type ColorCount = {
|
|
43
|
+
color: string;
|
|
44
|
+
count: number;
|
|
39
45
|
};
|
|
40
46
|
export type GraphItemMetaData = {
|
|
41
47
|
totalCount: number;
|
|
42
|
-
|
|
48
|
+
/** Distribution of colors across all elements with this label/type, sorted descending by count. */
|
|
49
|
+
colorDistribution: ColorCount[];
|
|
43
50
|
};
|
|
44
|
-
export type
|
|
45
|
-
nodes: Record<string, NodeData>;
|
|
46
|
-
relationships: Record<string, RelData>;
|
|
51
|
+
export type MetadataLookupTable = {
|
|
47
52
|
labels: string[];
|
|
48
|
-
types: string[];
|
|
49
53
|
labelMetaData: Record<string, GraphItemMetaData>;
|
|
50
|
-
|
|
54
|
+
reltypes: string[];
|
|
55
|
+
reltypeMetaData: Record<string, GraphItemMetaData>;
|
|
56
|
+
hasMultipleColors: boolean;
|
|
51
57
|
};
|
|
52
58
|
export type PortableProperty = {
|
|
53
59
|
stringified: string;
|
|
@@ -56,13 +62,11 @@ export type PortableProperty = {
|
|
|
56
62
|
export type NodeData = {
|
|
57
63
|
labelsSorted: string[];
|
|
58
64
|
properties: Record<string, PortableProperty>;
|
|
59
|
-
color: string;
|
|
60
65
|
id: string;
|
|
61
66
|
};
|
|
62
67
|
export type RelData = {
|
|
63
68
|
type: string;
|
|
64
69
|
properties: Record<string, PortableProperty>;
|
|
65
|
-
color: string;
|
|
66
70
|
id: string;
|
|
67
71
|
};
|
|
68
72
|
export type NeoNode = Node & {
|
|
@@ -87,6 +91,8 @@ export type GraphVisualizationContextData = {
|
|
|
87
91
|
interactionMode: InteractionMode;
|
|
88
92
|
nvlGraph: NvlGraph;
|
|
89
93
|
selected: GraphSelection;
|
|
94
|
+
metadataLookup: MetadataLookupTable;
|
|
95
|
+
compiledStyleRules: CompiledStyleRules;
|
|
90
96
|
layout: Layout;
|
|
91
97
|
setLayout?: (layout: Layout) => void;
|
|
92
98
|
portalTarget?: HTMLElement | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"graph-visualization-context.d.ts","sourceRoot":"","sources":["../../src/graph-visualization-context.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,KAAK,GAAG,MAAM,iBAAiB,CAAC;AACvC,OAAO,EAAE,KAAK,MAAM,EAAE,KAAK,IAAI,EAAE,KAAK,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAG5E,MAAM,MAAM,cAAc,GAAG;IAAE,OAAO,EAAE,MAAM,EAAE,CAAC;IAAC,eAAe,EAAE,MAAM,EAAE,CAAA;CAAE,CAAC;AAC9E,MAAM,MAAM,SAAS,GAAG;IACtB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,eAAe,EAAE,OAAO,CAAC;IACzB,kBAAkB,CAAC,EAAE,CAAC,eAAe,EAAE,OAAO,KAAK,IAAI,CAAC;IACxD,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,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AAC;AAEF;;;;;GAKG;AACH,MAAM,MAAM,6BAA6B,GAAG;IAC1C,WAAW,EAAE,KAAK,CAAC,gBAAgB,CAAC,GAAG,GAAG,IAAI,CAAC,CAAC;IAChD,SAAS,EAAE,SAAS,GAAG,IAAI,CAAC;IAC5B,OAAO,EAAE,OAAO,CAAC;IACjB,UAAU,CAAC,EAAE,CAAC,OAAO,EAAE,OAAO,KAAK,IAAI,CAAC;IACxC,eAAe,EAAE,eAAe,CAAC;IACjC,QAAQ,EAAE,QAAQ,CAAC;IACnB,QAAQ,EAAE,cAAc,CAAC;IACzB,cAAc,EAAE,mBAAmB,CAAC;IACpC,kBAAkB,EAAE,kBAAkB,CAAC;IACvC,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;IACrC,YAAY,CAAC,EAAE,WAAW,GAAG,IAAI,CAAC;CACnC,CAAC;AAEF,eAAO,MAAM,yBAAyB,oEAE1B,CAAC;AAEb;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,eAAO,MAAM,4BAA4B,qCAQxC,CAAC;AAEF,MAAM,MAAM,OAAO,GAAG,QAAQ,GAAG,KAAK,GAAG,OAAO,CAAC;AAEjD,MAAM,MAAM,eAAe,GACvB,QAAQ,GACR,MAAM,GACN,WAAW,GACX,KAAK,GACL,MAAM,GACN,MAAM,CAAC"}
|
|
@@ -23,6 +23,7 @@ import { type Layout } from '@neo4j-nvl/base';
|
|
|
23
23
|
import { type InteractiveNvlWrapperProps } from '@neo4j-nvl/react';
|
|
24
24
|
import React from 'react';
|
|
25
25
|
import { type Gesture, type GraphSelection, type InteractionMode, type NeoNode, type NeoRel, type Sidepanel } from './graph-visualization-context';
|
|
26
|
+
import { type StyleRule } from './styling/style-types';
|
|
26
27
|
export declare const DEFAULT_NVL_OPTIONS: {
|
|
27
28
|
disableTelemetry: boolean;
|
|
28
29
|
disableWebGL: boolean;
|
|
@@ -39,6 +40,12 @@ export type GraphVisualizationProps<T extends React.ElementType = 'div'> = {
|
|
|
39
40
|
topRightIsland?: React.ReactNode;
|
|
40
41
|
className?: string;
|
|
41
42
|
style?: React.CSSProperties;
|
|
43
|
+
/**
|
|
44
|
+
* Optional style rules to apply to graph elements.
|
|
45
|
+
* Consumer-set `color` on individual `NeoNode`/`NeoRel` objects takes precedence over rules.
|
|
46
|
+
* Compared by reference — memoize the array to avoid recompiling on every render.
|
|
47
|
+
*/
|
|
48
|
+
nvlStyleRules?: StyleRule[];
|
|
42
49
|
gesture?: Gesture;
|
|
43
50
|
setGesture?: (gesture: Gesture) => void;
|
|
44
51
|
selected?: GraphSelection;
|
|
@@ -114,7 +121,7 @@ export type GraphVisualizationProps<T extends React.ElementType = 'div'> = {
|
|
|
114
121
|
*
|
|
115
122
|
* @alpha
|
|
116
123
|
*/
|
|
117
|
-
export declare function GraphVisualization<T extends React.ElementType = 'div'>({ nvlRef: rawNvlRef, nvlCallbacks, nvlOptions, sidepanel: rawSidepanel, nodes: rawNodes, rels: rawRels, highlightedNodeIds, highlightedRelationshipIds, topLeftIsland, topRightIsland, bottomLeftIsland, bottomRightIsland, gesture, setGesture, layout: rawLayout, setLayout: rawSetLayout, portalTarget, selected: rawSelected, setSelected: rawSetSelected, interactionMode: rawInteractionMode, setInteractionMode: rawSetInteractionMode, mouseEventCallbacks, className, style, htmlAttributes, ref, as, ...restProps }: GraphVisualizationProps<T>): import("react/jsx-runtime").JSX.Element;
|
|
124
|
+
export declare function GraphVisualization<T extends React.ElementType = 'div'>({ nvlRef: rawNvlRef, nvlCallbacks, nvlOptions, sidepanel: rawSidepanel, nodes: rawNodes, rels: rawRels, highlightedNodeIds, highlightedRelationshipIds, topLeftIsland, topRightIsland, bottomLeftIsland, bottomRightIsland, gesture, setGesture, layout: rawLayout, setLayout: rawSetLayout, portalTarget, selected: rawSelected, setSelected: rawSetSelected, interactionMode: rawInteractionMode, setInteractionMode: rawSetInteractionMode, mouseEventCallbacks, className, style, htmlAttributes, ref, as, nvlStyleRules: styleRules, ...restProps }: GraphVisualizationProps<T>): import("react/jsx-runtime").JSX.Element;
|
|
118
125
|
export declare namespace GraphVisualization {
|
|
119
126
|
var ZoomInButton: ({ className, style, htmlAttributes, tooltipPlacement, }: {
|
|
120
127
|
tooltipPlacement?: import("@floating-ui/react").Placement | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"graph-visualization.d.ts","sourceRoot":"","sources":["../../src/graph-visualization.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAIH,OAAO,KAAK,GAAG,MAAM,iBAAiB,CAAC;AACvC,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,iBAAiB,CAAC;AAC9C,OAAO,EAEL,KAAK,0BAA0B,EAChC,MAAM,kBAAkB,CAAC;AAE1B,OAAO,KAA8C,MAAM,OAAO,CAAC;AAenE,OAAO,EACL,KAAK,OAAO,EACZ,KAAK,cAAc,EAEnB,KAAK,eAAe,EACpB,KAAK,OAAO,EACZ,KAAK,MAAM,
|
|
1
|
+
{"version":3,"file":"graph-visualization.d.ts","sourceRoot":"","sources":["../../src/graph-visualization.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAIH,OAAO,KAAK,GAAG,MAAM,iBAAiB,CAAC;AACvC,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,iBAAiB,CAAC;AAC9C,OAAO,EAEL,KAAK,0BAA0B,EAChC,MAAM,kBAAkB,CAAC;AAE1B,OAAO,KAA8C,MAAM,OAAO,CAAC;AAenE,OAAO,EACL,KAAK,OAAO,EACZ,KAAK,cAAc,EAEnB,KAAK,eAAe,EACpB,KAAK,OAAO,EACZ,KAAK,MAAM,EACX,KAAK,SAAS,EACf,MAAM,+BAA+B,CAAC;AAGvC,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,uBAAuB,CAAC;AA0BvD,eAAO,MAAM,mBAAmB;;;;;;CAM/B,CAA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AAE,KAAK,CAAC,qBAAqB,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC;IAC5C,cAAc,CAAC,EAAE,KAAK,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC;CAC1C,GAAG,0BAA0B,CAAC;AAE/B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAyDG;AACH,wBAAgB,kBAAkB,CAAC,CAAC,SAAS,KAAK,CAAC,WAAW,GAAG,KAAK,EAAE,EACtE,MAAM,EAAE,SAAS,EACjB,YAAY,EACZ,UAAU,EACV,SAAS,EAAE,YAAY,EACvB,KAAK,EAAE,QAAQ,EACf,IAAI,EAAE,OAAO,EACb,kBAAkB,EAClB,0BAA0B,EAC1B,aAAgD,EAChD,cAAkD,EAClD,gBAAsD,EACtD,iBAAwD,EACxD,OAAkB,EAClB,UAAU,EACV,MAAM,EAAE,SAAS,EACjB,SAAS,EAAE,YAAY,EACvB,YAAY,EACZ,QAAQ,EAAE,WAAW,EACrB,WAAW,EAAE,cAAc,EAC3B,eAAe,EAAE,kBAAkB,EACnC,kBAAkB,EAAE,qBAAqB,EACzC,mBAAwB,EACxB,SAAS,EACT,KAAK,EACL,cAAc,EACd,GAAG,EACH,EAAE,EACF,aAAa,EAAE,UAAU,EACzB,GAAG,SAAS,EACb,EAAE,uBAAuB,CAAC,CAAC,CAAC,2CAyK5B;yBAvMe,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;qBA6TjB,CAAC;qBAEC,CAAC;;;;;;;;;qBAsBonC,CAAC;sBAAkE,CAAC"}
|
package/lib/types/index.d.ts
CHANGED
|
@@ -19,5 +19,6 @@
|
|
|
19
19
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
20
20
|
*/
|
|
21
21
|
export { GraphVisualization } from './graph-visualization';
|
|
22
|
-
export { useGraphVisualizationContext, type
|
|
22
|
+
export { useGraphVisualizationContext, type ColorCount, type Gesture, type GraphItemMetaData, type GraphSelection, type GraphVisualizationContextData, type InteractionMode, type MetadataLookupTable, type NeoNode, type NeoRel, type NodeData, type NvlGraph, type PortableProperty, type RelData, type Sidepanel, } from './graph-visualization-context';
|
|
23
|
+
export { type StyleRule } from './styling/style-types';
|
|
23
24
|
//# sourceMappingURL=index.d.ts.map
|
package/lib/types/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAC3D,OAAO,EACL,4BAA4B,EAC5B,KAAK,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAC3D,OAAO,EACL,4BAA4B,EAC5B,KAAK,UAAU,EACf,KAAK,OAAO,EACZ,KAAK,iBAAiB,EACtB,KAAK,cAAc,EACnB,KAAK,6BAA6B,EAClC,KAAK,eAAe,EACpB,KAAK,mBAAmB,EACxB,KAAK,OAAO,EACZ,KAAK,MAAM,EACX,KAAK,QAAQ,EACb,KAAK,QAAQ,EACb,KAAK,gBAAgB,EACrB,KAAK,OAAO,EACZ,KAAK,SAAS,GACf,MAAM,+BAA+B,CAAC;AACvC,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,uBAAuB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"details-panel.d.ts","sourceRoot":"","sources":["../../../src/sidepanel-components/details-panel.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;
|
|
1
|
+
{"version":3,"file":"details-panel.d.ts","sourceRoot":"","sources":["../../../src/sidepanel-components/details-panel.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAcH,KAAK,gBAAgB,GAAG;IACtB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB,CAAC;AAMF,eAAO,MAAM,YAAY,GAAI,eAAqB,gBAAgB,mDAiGjE,CAAC"}
|
|
@@ -18,21 +18,14 @@
|
|
|
18
18
|
* You should have received a copy of the GNU General Public License
|
|
19
19
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
20
20
|
*/
|
|
21
|
-
import { type
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
} | {
|
|
29
|
-
type: 'property';
|
|
30
|
-
captionKey: string;
|
|
31
|
-
captionSize?: number;
|
|
21
|
+
import { type GraphItemMetaData } from '../graph-visualization-context';
|
|
22
|
+
type GraphLabelWrapperProps = {
|
|
23
|
+
label: string;
|
|
24
|
+
type: 'node' | 'relationship';
|
|
25
|
+
metaData: GraphItemMetaData | undefined;
|
|
26
|
+
tabIndex?: number;
|
|
27
|
+
showCount?: boolean;
|
|
32
28
|
};
|
|
33
|
-
export declare const
|
|
34
|
-
export
|
|
35
|
-
|
|
36
|
-
export declare function getDefaultCaptionKey(options: CaptionOption[]): CaptionOption | undefined;
|
|
37
|
-
export declare function mapToNvlGraph(rawNodes: NeoNode[], rawRels: NeoRel[]): NvlGraph;
|
|
38
|
-
//# sourceMappingURL=map-to-nvl-graph.d.ts.map
|
|
29
|
+
export declare const GraphLabelWrapper: ({ label, type, metaData, tabIndex, showCount, }: GraphLabelWrapperProps) => import("react/jsx-runtime").JSX.Element;
|
|
30
|
+
export {};
|
|
31
|
+
//# sourceMappingURL=graph-label-wrapper.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"graph-label-wrapper.d.ts","sourceRoot":"","sources":["../../../src/sidepanel-components/graph-label-wrapper.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAKH,OAAO,EAAE,KAAK,iBAAiB,EAAE,MAAM,gCAAgC,CAAC;AAExE,KAAK,sBAAsB,GAAG;IAC5B,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,GAAG,cAAc,CAAC;IAC9B,QAAQ,EAAE,iBAAiB,GAAG,SAAS,CAAC;IACxC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB,CAAC;AAEF,eAAO,MAAM,iBAAiB,GAAI,iDAM/B,sBAAsB,4CAsBxB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"overview-panel.d.ts","sourceRoot":"","sources":["../../../src/sidepanel-components/overview-panel.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;
|
|
1
|
+
{"version":3,"file":"overview-panel.d.ts","sourceRoot":"","sources":["../../../src/sidepanel-components/overview-panel.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAWH,eAAO,MAAM,aAAa,+CAkEzB,CAAC"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
*
|
|
3
|
+
* Copyright (c) "Neo4j"
|
|
4
|
+
* Neo4j Sweden AB [http://neo4j.com]
|
|
5
|
+
*
|
|
6
|
+
* This file is part of Neo4j.
|
|
7
|
+
*
|
|
8
|
+
* Neo4j is free software: you can redistribute it and/or modify
|
|
9
|
+
* it under the terms of the GNU General Public License as published by
|
|
10
|
+
* the Free Software Foundation, either version 3 of the License, or
|
|
11
|
+
* (at your option) any later version.
|
|
12
|
+
*
|
|
13
|
+
* This program is distributed in the hope that it will be useful,
|
|
14
|
+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
15
|
+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
16
|
+
* GNU General Public License for more details.
|
|
17
|
+
*
|
|
18
|
+
* You should have received a copy of the GNU General Public License
|
|
19
|
+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
20
|
+
*/
|
|
21
|
+
import { type StyleRule } from '../styling/style-types';
|
|
22
|
+
export declare const defaultNodeRules: StyleRule[];
|
|
23
|
+
export declare const trainerRules: StyleRule[];
|
|
24
|
+
export declare const pokemonRules: StyleRule[];
|
|
25
|
+
export declare const typeRules: StyleRule[];
|
|
26
|
+
export declare const gymRules: StyleRule[];
|
|
27
|
+
export declare const battledRelRules: StyleRule[];
|
|
28
|
+
export declare const caughtRelRules: StyleRule[];
|
|
29
|
+
export declare const evolvesToRelRules: StyleRule[];
|
|
30
|
+
export declare const advancedStyleRules: StyleRule[];
|
|
31
|
+
declare const Component: () => import("react/jsx-runtime").JSX.Element;
|
|
32
|
+
export default Component;
|
|
33
|
+
//# sourceMappingURL=graph-visualization-rule-based-styling-advanced.story.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"graph-visualization-rule-based-styling-advanced.story.d.ts","sourceRoot":"","sources":["../../../src/stories/graph-visualization-rule-based-styling-advanced.story.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAGH,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,wBAAwB,CAAC;AAGxD,eAAO,MAAM,gBAAgB,EAAE,SAAS,EAKvC,CAAC;AAEF,eAAO,MAAM,YAAY,EAAE,SAAS,EA+BnC,CAAC;AAEF,eAAO,MAAM,YAAY,EAAE,SAAS,EAsEnC,CAAC;AAEF,eAAO,MAAM,SAAS,EAAE,SAAS,EAahC,CAAC;AAEF,eAAO,MAAM,QAAQ,EAAE,SAAS,EAa/B,CAAC;AAEF,eAAO,MAAM,eAAe,EAAE,SAAS,EAqBtC,CAAC;AAEF,eAAO,MAAM,cAAc,EAAE,SAAS,EAarC,CAAC;AAEF,eAAO,MAAM,iBAAiB,EAAE,SAAS,EAgCxC,CAAC;AAEF,eAAO,MAAM,kBAAkB,EAAE,SAAS,EASzC,CAAC;AAEF,QAAA,MAAM,SAAS,+CAWd,CAAC;AAEF,eAAe,SAAS,CAAC"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/**
|
|
2
|
+
*
|
|
3
|
+
* Copyright (c) "Neo4j"
|
|
4
|
+
* Neo4j Sweden AB [http://neo4j.com]
|
|
5
|
+
*
|
|
6
|
+
* This file is part of Neo4j.
|
|
7
|
+
*
|
|
8
|
+
* Neo4j is free software: you can redistribute it and/or modify
|
|
9
|
+
* it under the terms of the GNU General Public License as published by
|
|
10
|
+
* the Free Software Foundation, either version 3 of the License, or
|
|
11
|
+
* (at your option) any later version.
|
|
12
|
+
*
|
|
13
|
+
* This program is distributed in the hope that it will be useful,
|
|
14
|
+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
15
|
+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
16
|
+
* GNU General Public License for more details.
|
|
17
|
+
*
|
|
18
|
+
* You should have received a copy of the GNU General Public License
|
|
19
|
+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
20
|
+
*/
|
|
21
|
+
import { type StyleRule } from '../styling/style-types';
|
|
22
|
+
export declare const styleRules: StyleRule[];
|
|
23
|
+
declare const Component: () => import("react/jsx-runtime").JSX.Element;
|
|
24
|
+
export default Component;
|
|
25
|
+
//# sourceMappingURL=graph-visualization-rule-based-styling.story.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"graph-visualization-rule-based-styling.story.d.ts","sourceRoot":"","sources":["../../../src/stories/graph-visualization-rule-based-styling.story.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAGH,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,wBAAwB,CAAC;AAGxD,eAAO,MAAM,UAAU,EAAE,SAAS,EA+CjC,CAAC;AAEF,QAAA,MAAM,SAAS,+CAWd,CAAC;AAEF,eAAe,SAAS,CAAC"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/**
|
|
2
|
+
*
|
|
3
|
+
* Copyright (c) "Neo4j"
|
|
4
|
+
* Neo4j Sweden AB [http://neo4j.com]
|
|
5
|
+
*
|
|
6
|
+
* This file is part of Neo4j.
|
|
7
|
+
*
|
|
8
|
+
* Neo4j is free software: you can redistribute it and/or modify
|
|
9
|
+
* it under the terms of the GNU General Public License as published by
|
|
10
|
+
* the Free Software Foundation, either version 3 of the License, or
|
|
11
|
+
* (at your option) any later version.
|
|
12
|
+
*
|
|
13
|
+
* This program is distributed in the hope that it will be useful,
|
|
14
|
+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
15
|
+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
16
|
+
* GNU General Public License for more details.
|
|
17
|
+
*
|
|
18
|
+
* You should have received a copy of the GNU General Public License
|
|
19
|
+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
20
|
+
*/
|
|
21
|
+
import { type StyleRule } from '../styling/style-types';
|
|
22
|
+
export declare const simpleStyleRules: StyleRule[];
|
|
23
|
+
declare const Component: () => import("react/jsx-runtime").JSX.Element;
|
|
24
|
+
export default Component;
|
|
25
|
+
//# sourceMappingURL=graph-visualization-simple-styling.story.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"graph-visualization-simple-styling.story.d.ts","sourceRoot":"","sources":["../../../src/stories/graph-visualization-simple-styling.story.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAGH,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,wBAAwB,CAAC;AAGxD,eAAO,MAAM,gBAAgB,EAAE,SAAS,EAyBvC,CAAC;AAEF,QAAA,MAAM,SAAS,+CAWd,CAAC;AAEF,eAAe,SAAS,CAAC"}
|
|
@@ -22,14 +22,20 @@ export { default as GraphVisualizationBarebones } from './graph-visualization-ba
|
|
|
22
22
|
export { default as GraphVisualizationCustom } from './graph-visualization-custom.story';
|
|
23
23
|
export { default as GraphVisualizationDefault } from './graph-visualization-default.story';
|
|
24
24
|
export { default as GraphVisualizationHighlighting } from './graph-visualization-highlighting.story';
|
|
25
|
-
export { default as GraphVisualizationSearch } from './graph-visualization-search.story';
|
|
26
25
|
export { default as GraphVisualizationMaximalist } from './graph-visualization-maximalist.story';
|
|
26
|
+
export { default as GraphVisualizationRuleBasedStylingAdvanced } from './graph-visualization-rule-based-styling-advanced.story';
|
|
27
|
+
export { default as GraphVisualizationRuleBasedStyling } from './graph-visualization-rule-based-styling.story';
|
|
28
|
+
export { default as GraphVisualizationSearch } from './graph-visualization-search.story';
|
|
29
|
+
export { default as GraphVisualizationSimpleStyling } from './graph-visualization-simple-styling.story';
|
|
27
30
|
export { default as PreviewGraphVisualization } from './preview-graph-visualization.story';
|
|
28
31
|
export declare const GraphVisualizationDefaultSrc: string;
|
|
29
32
|
export declare const GraphVisualizationBarebonesSrc: string;
|
|
30
33
|
export declare const GraphVisualizationMaximalistSrc: string;
|
|
31
34
|
export declare const GraphVisualizationCustomSrc: string;
|
|
32
35
|
export declare const GraphVisualizationHighlightingSrc: string;
|
|
36
|
+
export declare const GraphVisualizationSimpleStylingSrc: string;
|
|
37
|
+
export declare const GraphVisualizationRuleBasedStylingSrc: string;
|
|
33
38
|
export declare const GraphVisualizationSearchSrc: string;
|
|
39
|
+
export declare const GraphVisualizationRuleBasedStylingAdvancedSrc: string;
|
|
34
40
|
export declare const PreviewGraphVisualizationSrc: string;
|
|
35
41
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/stories/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,OAAO,IAAI,2BAA2B,EAAE,MAAM,uCAAuC,CAAC;AAC/F,OAAO,EAAE,OAAO,IAAI,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,eAAO,MAAM,kCAAkC,QAE9C,CAAC;AAEF,eAAO,MAAM,qCAAqC,QAEjD,CAAC;AAEF,eAAO,MAAM,2BAA2B,QAEvC,CAAC;AAEF,eAAO,MAAM,6CAA6C,QACa,CAAC;AAExE,eAAO,MAAM,4BAA4B,QAExC,CAAC"}
|
|
@@ -23,5 +23,9 @@ export declare const StoryGraph: {
|
|
|
23
23
|
nodes: NeoNode[];
|
|
24
24
|
rels: NeoRel[];
|
|
25
25
|
};
|
|
26
|
+
export declare const advancedStoryGraph: {
|
|
27
|
+
nodes: NeoNode[];
|
|
28
|
+
rels: NeoRel[];
|
|
29
|
+
};
|
|
26
30
|
export declare const containerClasses = "n-w-full n-border-neutral-border-weak n-mx-2 n-rounded-lg n-border";
|
|
27
31
|
//# sourceMappingURL=story-data.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"story-data.d.ts","sourceRoot":"","sources":["../../../src/stories/story-data.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,KAAK,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,gCAAgC,CAAC;AAE3E,eAAO,MAAM,UAAU,EAAE;IAAE,KAAK,EAAE,OAAO,EAAE,CAAC;IAAC,IAAI,EAAE,MAAM,EAAE,CAAA;
|
|
1
|
+
{"version":3,"file":"story-data.d.ts","sourceRoot":"","sources":["../../../src/stories/story-data.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,KAAK,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,gCAAgC,CAAC;AAE3E,eAAO,MAAM,UAAU,EAAE;IAAE,KAAK,EAAE,OAAO,EAAE,CAAC;IAAC,IAAI,EAAE,MAAM,EAAE,CAAA;CA2E1D,CAAC;AAEF,eAAO,MAAM,kBAAkB,EAAE;IAAE,KAAK,EAAE,OAAO,EAAE,CAAC;IAAC,IAAI,EAAE,MAAM,EAAE,CAAA;CA03BlE,CAAC;AAEF,eAAO,MAAM,gBAAgB,uEACyC,CAAC"}
|
|
@@ -27,14 +27,11 @@ type StyleMatchers = {
|
|
|
27
27
|
rulesByType: Map<string, StyleRule[]>;
|
|
28
28
|
};
|
|
29
29
|
export type CompiledStyleRules = {
|
|
30
|
-
byType:
|
|
30
|
+
byType: (type: string) => (rel: RelData) => EvaluatedNvlRelationshipStyle;
|
|
31
31
|
styleMatchers: StyleMatchers;
|
|
32
32
|
byLabelSet: (node: NodeData) => EvaluatedNvlNodeStyle;
|
|
33
33
|
};
|
|
34
34
|
export declare const DEFAULT_REL_COLOR: string;
|
|
35
|
-
export declare function compileStyleRules(
|
|
36
|
-
reltypes: string[];
|
|
37
|
-
styleRules: StyleRule[] | null | undefined;
|
|
38
|
-
}): CompiledStyleRules;
|
|
35
|
+
export declare function compileStyleRules(styleRules: StyleRule[] | null | undefined): CompiledStyleRules;
|
|
39
36
|
export {};
|
|
40
37
|
//# sourceMappingURL=compile-graph-styles.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"compile-graph-styles.d.ts","sourceRoot":"","sources":["../../../src/styling/compile-graph-styles.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAKH,OAAO,EACL,KAAK,QAAQ,EAEb,KAAK,OAAO,EACb,MAAM,gCAAgC,CAAC;AACxC,OAAO,EAGL,KAAK,qBAAqB,EAC1B,KAAK,6BAA6B,EAElC,KAAK,SAAS,EAGf,MAAM,eAAe,CAAC;AAEvB,KAAK,aAAa,GAAG;IACnB,gBAAgB,EAAE,SAAS,EAAE,CAAC;IAC9B,kBAAkB,EAAE,SAAS,EAAE,CAAC;IAChC,YAAY,EAAE,GAAG,CAAC,MAAM,EAAE,SAAS,EAAE,CAAC,CAAC;IACvC,WAAW,EAAE,GAAG,CAAC,MAAM,EAAE,SAAS,EAAE,CAAC,CAAC;CACvC,CAAC;AAgdF,MAAM,MAAM,kBAAkB,GAAG;IAC/B,MAAM,EAAE,
|
|
1
|
+
{"version":3,"file":"compile-graph-styles.d.ts","sourceRoot":"","sources":["../../../src/styling/compile-graph-styles.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAKH,OAAO,EACL,KAAK,QAAQ,EAEb,KAAK,OAAO,EACb,MAAM,gCAAgC,CAAC;AACxC,OAAO,EAGL,KAAK,qBAAqB,EAC1B,KAAK,6BAA6B,EAElC,KAAK,SAAS,EAGf,MAAM,eAAe,CAAC;AAEvB,KAAK,aAAa,GAAG;IACnB,gBAAgB,EAAE,SAAS,EAAE,CAAC;IAC9B,kBAAkB,EAAE,SAAS,EAAE,CAAC;IAChC,YAAY,EAAE,GAAG,CAAC,MAAM,EAAE,SAAS,EAAE,CAAC,CAAC;IACvC,WAAW,EAAE,GAAG,CAAC,MAAM,EAAE,SAAS,EAAE,CAAC,CAAC;CACvC,CAAC;AAgdF,MAAM,MAAM,kBAAkB,GAAG;IAC/B,MAAM,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,CAAC,GAAG,EAAE,OAAO,KAAK,6BAA6B,CAAC;IAC1E,aAAa,EAAE,aAAa,CAAC;IAC7B,UAAU,EAAE,CAAC,IAAI,EAAE,QAAQ,KAAK,qBAAqB,CAAC;CACvD,CAAC;AAEF,eAAO,MAAM,iBAAiB,QAA+B,CAAC;AAiF9D,wBAAgB,iBAAiB,CAC/B,UAAU,EAAE,SAAS,EAAE,GAAG,IAAI,GAAG,SAAS,GACzC,kBAAkB,CAyBpB"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
*
|
|
3
|
+
* Copyright (c) "Neo4j"
|
|
4
|
+
* Neo4j Sweden AB [http://neo4j.com]
|
|
5
|
+
*
|
|
6
|
+
* This file is part of Neo4j.
|
|
7
|
+
*
|
|
8
|
+
* Neo4j is free software: you can redistribute it and/or modify
|
|
9
|
+
* it under the terms of the GNU General Public License as published by
|
|
10
|
+
* the Free Software Foundation, either version 3 of the License, or
|
|
11
|
+
* (at your option) any later version.
|
|
12
|
+
*
|
|
13
|
+
* This program is distributed in the hope that it will be useful,
|
|
14
|
+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
15
|
+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
16
|
+
* GNU General Public License for more details.
|
|
17
|
+
*
|
|
18
|
+
* You should have received a copy of the GNU General Public License
|
|
19
|
+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
20
|
+
*/
|
|
21
|
+
import type { MetadataLookupTable, NeoNode, NeoRel, NvlGraph } from '../graph-visualization-context';
|
|
22
|
+
import type { CompiledStyleRules } from './compile-graph-styles';
|
|
23
|
+
export declare const NO_LABEL = "(no label)";
|
|
24
|
+
export declare function createVisualizationDataStructures(rawNodes: NeoNode[], rawRels: NeoRel[], compiledStyleRules: CompiledStyleRules): {
|
|
25
|
+
styledGraph: NvlGraph;
|
|
26
|
+
metadataLookup: MetadataLookupTable;
|
|
27
|
+
};
|
|
28
|
+
//# sourceMappingURL=create-vis-data-structures.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create-vis-data-structures.d.ts","sourceRoot":"","sources":["../../../src/styling/create-vis-data-structures.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,KAAK,EAGV,mBAAmB,EACnB,OAAO,EACP,MAAM,EAEN,QAAQ,EAET,MAAM,gCAAgC,CAAC;AAExC,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAC;AAEjE,eAAO,MAAM,QAAQ,eAAe,CAAC;AAUrC,wBAAgB,iCAAiC,CAC/C,QAAQ,EAAE,OAAO,EAAE,EACnB,OAAO,EAAE,MAAM,EAAE,EACjB,kBAAkB,EAAE,kBAAkB,GACrC;IACD,WAAW,EAAE,QAAQ,CAAC;IACtB,cAAc,EAAE,mBAAmB,CAAC;CACrC,CA6HA"}
|
|
@@ -99,9 +99,9 @@ export declare const NvlCaptionSchema: z.ZodObject<{
|
|
|
99
99
|
export type Caption = z.infer<typeof NvlCaptionSchema>;
|
|
100
100
|
export declare const StyleSchema: z.ZodObject<{
|
|
101
101
|
captionAlign: z.ZodOptional<z.ZodEnum<{
|
|
102
|
-
center: "center";
|
|
103
102
|
top: "top";
|
|
104
103
|
bottom: "bottom";
|
|
104
|
+
center: "center";
|
|
105
105
|
}>>;
|
|
106
106
|
captionSize: z.ZodOptional<z.ZodNumber>;
|
|
107
107
|
captions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
@@ -135,9 +135,9 @@ export declare const StyleRuleSchema: z.ZodObject<{
|
|
|
135
135
|
where: z.ZodOptional<z.ZodType<Where, unknown, z.core.$ZodTypeInternals<Where, unknown>>>;
|
|
136
136
|
apply: z.ZodObject<{
|
|
137
137
|
captionAlign: z.ZodOptional<z.ZodEnum<{
|
|
138
|
-
center: "center";
|
|
139
138
|
top: "top";
|
|
140
139
|
bottom: "bottom";
|
|
140
|
+
center: "center";
|
|
141
141
|
}>>;
|
|
142
142
|
captionSize: z.ZodOptional<z.ZodNumber>;
|
|
143
143
|
captions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
*
|
|
3
|
+
* Copyright (c) "Neo4j"
|
|
4
|
+
* Neo4j Sweden AB [http://neo4j.com]
|
|
5
|
+
*
|
|
6
|
+
* This file is part of Neo4j.
|
|
7
|
+
*
|
|
8
|
+
* Neo4j is free software: you can redistribute it and/or modify
|
|
9
|
+
* it under the terms of the GNU General Public License as published by
|
|
10
|
+
* the Free Software Foundation, either version 3 of the License, or
|
|
11
|
+
* (at your option) any later version.
|
|
12
|
+
*
|
|
13
|
+
* This program is distributed in the hope that it will be useful,
|
|
14
|
+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
15
|
+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
16
|
+
* GNU General Public License for more details.
|
|
17
|
+
*
|
|
18
|
+
* You should have received a copy of the GNU General Public License
|
|
19
|
+
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
20
|
+
*/
|
|
21
|
+
import type { NeoNode, NeoRel } from '../graph-visualization-context';
|
|
22
|
+
import type { StyleRule } from './style-types';
|
|
23
|
+
export declare function useGraphData(rawNodes: NeoNode[], rawRels: NeoRel[], styleRules?: StyleRule[]): {
|
|
24
|
+
styledGraph: import("..").NvlGraph;
|
|
25
|
+
metadataLookup: import("..").MetadataLookupTable;
|
|
26
|
+
compiledStyleRules: import("./compile-graph-styles").CompiledStyleRules;
|
|
27
|
+
};
|
|
28
|
+
//# sourceMappingURL=use-graph-data.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-graph-data.d.ts","sourceRoot":"","sources":["../../../src/styling/use-graph-data.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAIH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,gCAAgC,CAAC;AAGtE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAE/C,wBAAgB,YAAY,CAC1B,QAAQ,EAAE,OAAO,EAAE,EACnB,OAAO,EAAE,MAAM,EAAE,EACjB,UAAU,CAAC,EAAE,SAAS,EAAE;;;;EAiBzB"}
|
package/lib/types/utils.d.ts
CHANGED
|
@@ -18,13 +18,15 @@
|
|
|
18
18
|
* You should have received a copy of the GNU General Public License
|
|
19
19
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
20
20
|
*/
|
|
21
|
-
import { type
|
|
21
|
+
import { type NvlGraph } from './graph-visualization-context';
|
|
22
22
|
export declare const isMac: boolean;
|
|
23
23
|
export declare const xor: (a: string[], b: string[]) => string[];
|
|
24
24
|
export declare const mapValues: <T, R>(obj: Record<string, T>, fn: (value: T) => R) => Record<string, R>;
|
|
25
25
|
export declare const searchProperties: (properties: Record<string, {
|
|
26
26
|
stringified: string;
|
|
27
27
|
}>, text: string) => boolean;
|
|
28
|
-
export declare const searchNodes: (
|
|
29
|
-
export declare const searchRels: (
|
|
28
|
+
export declare const searchNodes: (graph: NvlGraph, text: string) => string[];
|
|
29
|
+
export declare const searchRels: (graph: NvlGraph, text: string) => string[];
|
|
30
|
+
export declare const removeLicenseHeader: (source: string) => string;
|
|
31
|
+
export declare const sortAlphabetically: (a?: string, b?: string) => number;
|
|
30
32
|
//# sourceMappingURL=utils.d.ts.map
|
package/lib/types/utils.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/utils.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,KAAK,QAAQ,EAAE,
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/utils.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,KAAK,QAAQ,EAAE,MAAM,+BAA+B,CAAC;AAE9D,eAAO,MAAM,KAAK,SAAsC,CAAC;AAIzD,eAAO,MAAM,GAAG,GAAI,GAAG,MAAM,EAAE,EAAE,GAAG,MAAM,EAAE,aAC2B,CAAC;AAExE,eAAO,MAAM,SAAS,GAAI,CAAC,EAAE,CAAC,EAC5B,KAAK,MAAM,CAAC,MAAM,EAAE,CAAC,CAAC,EACtB,IAAI,CAAC,KAAK,EAAE,CAAC,KAAK,CAAC,KAClB,MAAM,CAAC,MAAM,EAAE,CAAC,CAGhB,CAAC;AAEJ,eAAO,MAAM,gBAAgB,GAC3B,YAAY,MAAM,CAAC,MAAM,EAAE;IAAE,WAAW,EAAE,MAAM,CAAA;CAAE,CAAC,EACnD,MAAM,MAAM,KACX,OAYF,CAAC;AAEF,eAAO,MAAM,WAAW,GAAI,OAAO,QAAQ,EAAE,MAAM,MAAM,KAAG,MAAM,EAiBjE,CAAC;AAEF,eAAO,MAAM,UAAU,GAAI,OAAO,QAAQ,EAAE,MAAM,MAAM,KAAG,MAAM,EAiBhE,CAAC;AAEF,eAAO,MAAM,mBAAmB,GAAI,QAAQ,MAAM,KAAG,MAEpD,CAAC;AAEF,eAAO,MAAM,kBAAkB,GAAI,UAAM,EAAE,UAAM,WACD,CAAC"}
|