@kortexya/nodus 0.1.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/LICENSE +37 -0
- package/README.md +60 -0
- package/__vite-plugin-wasm-helper-1Aiokjk5.js +24 -0
- package/assets/hypergraphWorker-DV0aFI3L.js +1 -0
- package/assets/layoutWorker-DwDJwbgr.js +285 -0
- package/assets/nodus_wasm-C0vDfO5K.js +1 -0
- package/chunk-DmhlhrBa.js +11 -0
- package/nodus.src.bundle.js +33577 -0
- package/nodus_render_wasm-Bs6hlsx-.js +2617 -0
- package/nodus_wasm-DKYQVSUZ.js +2789 -0
- package/package.json +61 -0
- package/types/Nodus.d.ts +100 -0
- package/types/algorithms/concentric/index.d.ts +29 -0
- package/types/algorithms/concentricFactory.d.ts +43 -0
- package/types/algorithms/force/Alea.d.ts +13 -0
- package/types/algorithms/force/BVH.d.ts +35 -0
- package/types/algorithms/force/LayoutData.d.ts +40 -0
- package/types/algorithms/force/Packing.d.ts +31 -0
- package/types/algorithms/force/Physics.d.ts +61 -0
- package/types/algorithms/force/SEC.d.ts +14 -0
- package/types/algorithms/force/Topology.d.ts +3 -0
- package/types/algorithms/force/index.d.ts +54 -0
- package/types/algorithms/force-gpu/ParticleSystem.d.ts +45 -0
- package/types/algorithms/force-gpu/Settings.d.ts +60 -0
- package/types/algorithms/force-gpu/Simulation.d.ts +7 -0
- package/types/algorithms/force-gpu/getGlContext.d.ts +10 -0
- package/types/algorithms/force-gpu/gpuLayout.d.ts +14 -0
- package/types/algorithms/force-gpu/index.d.ts +2 -0
- package/types/algorithms/force-gpu/kernels/index.d.ts +176 -0
- package/types/algorithms/force-gpu/kernels/utils.d.ts +31 -0
- package/types/algorithms/force-gpu/shaders/aabb.d.ts +2 -0
- package/types/algorithms/force-gpu/shaders/bhExpand.d.ts +2 -0
- package/types/algorithms/force-gpu/shaders/bhTranslate.d.ts +2 -0
- package/types/algorithms/force-gpu/shaders/cellLookup.d.ts +2 -0
- package/types/algorithms/force-gpu/shaders/index.d.ts +9 -0
- package/types/algorithms/force-gpu/shaders/integrate.d.ts +2 -0
- package/types/algorithms/force-gpu/shaders/morton.d.ts +2 -0
- package/types/algorithms/force-gpu/shaders/sortIntervals.d.ts +2 -0
- package/types/algorithms/force-gpu/shaders/sortKeys.d.ts +2 -0
- package/types/algorithms/force-gpu/shaders/types.d.ts +10 -0
- package/types/algorithms/force-gpu/webgl/helpers.d.ts +24 -0
- package/types/algorithms/force-gpu/webgl/index.d.ts +4 -0
- package/types/algorithms/force-gpu/webgl/program.d.ts +15 -0
- package/types/algorithms/forceFactory.d.ts +55 -0
- package/types/algorithms/forceLinkFactory.d.ts +40 -0
- package/types/algorithms/grid/index.d.ts +26 -0
- package/types/algorithms/gridFactory.d.ts +30 -0
- package/types/algorithms/hierarchical/index.d.ts +80 -0
- package/types/algorithms/hierarchical/sugiyama.d.ts +144 -0
- package/types/algorithms/hierarchicalFactory.d.ts +49 -0
- package/types/algorithms/index.d.ts +13 -0
- package/types/algorithms/radial/index.d.ts +33 -0
- package/types/algorithms/radialFactory.d.ts +54 -0
- package/types/algorithms/sequential/index.d.ts +37 -0
- package/types/algorithms/sequentialFactory.d.ts +37 -0
- package/types/core/Edge.d.ts +67 -0
- package/types/core/EdgeList.d.ts +86 -0
- package/types/core/Node.d.ts +89 -0
- package/types/core/NodeList.d.ts +105 -0
- package/types/core/Transformation.d.ts +108 -0
- package/types/core/enums.d.ts +16 -0
- package/types/geometry/BoundingBox.d.ts +41 -0
- package/types/geometry/index.d.ts +276 -0
- package/types/geometry/types.d.ts +27 -0
- package/types/hypergraph/Hypergraph.d.ts +74 -0
- package/types/hypergraph/KoenigGraph.d.ts +29 -0
- package/types/hypergraph/Simplifier.d.ts +39 -0
- package/types/hypergraph/Statistics.d.ts +55 -0
- package/types/hypergraph/forbidden/StrangledHyperedge.d.ts +12 -0
- package/types/hypergraph/forbidden/StrangledVertex.d.ts +16 -0
- package/types/hypergraph/forbidden/ThreeAdjacentCluster2.d.ts +10 -0
- package/types/hypergraph/forbidden/TwoAdjacentCluster3.d.ts +14 -0
- package/types/hypergraph/forbidden/index.d.ts +22 -0
- package/types/hypergraph/index.d.ts +21 -0
- package/types/hypergraph/layout/Adam.d.ts +12 -0
- package/types/hypergraph/layout/Energy.d.ts +55 -0
- package/types/hypergraph/layout/LBFGS.d.ts +32 -0
- package/types/hypergraph/layout/Optimizer.d.ts +60 -0
- package/types/hypergraph/layout/Reverser.d.ts +42 -0
- package/types/hypergraph/operations/AtomicOperation.d.ts +54 -0
- package/types/hypergraph/operations/HyperedgeMerger.d.ts +30 -0
- package/types/hypergraph/operations/HyperedgeRemoval.d.ts +27 -0
- package/types/hypergraph/operations/VertexMerger.d.ts +32 -0
- package/types/hypergraph/operations/VertexRemoval.d.ts +30 -0
- package/types/hypergraph/operations/index.d.ts +19 -0
- package/types/hypergraph/osfkb/adapter.d.ts +315 -0
- package/types/hypergraph/render/Interaction.d.ts +40 -0
- package/types/hypergraph/render/PolygonRenderer.d.ts +50 -0
- package/types/hypergraph/render/SVGPolygonRenderer.d.ts +7 -0
- package/types/hypergraph/types.d.ts +170 -0
- package/types/index.d.ts +21 -0
- package/types/internals/Algorithms.d.ts +68 -0
- package/types/internals/AlgorithmsPrimitives.d.ts +18 -0
- package/types/internals/Animations.d.ts +39 -0
- package/types/internals/AttributePathPrimitives.d.ts +2 -0
- package/types/internals/Brand.d.ts +22 -0
- package/types/internals/Camera.d.ts +115 -0
- package/types/internals/CameraInteractions.d.ts +15 -0
- package/types/internals/CameraInteractionsPrimitives.d.ts +18 -0
- package/types/internals/Captor.d.ts +56 -0
- package/types/internals/CaptorPrimitives.d.ts +9 -0
- package/types/internals/ClassModule.d.ts +42 -0
- package/types/internals/ConnectNodes.d.ts +23 -0
- package/types/internals/CurvatureManager.d.ts +14 -0
- package/types/internals/DataModule.d.ts +29 -0
- package/types/internals/Disabled.d.ts +27 -0
- package/types/internals/DomModule.d.ts +87 -0
- package/types/internals/DragModule.d.ts +14 -0
- package/types/internals/ElementSet.d.ts +17 -0
- package/types/internals/EventsModule.d.ts +41 -0
- package/types/internals/FlexArray.d.ts +54 -0
- package/types/internals/Geo.d.ts +127 -0
- package/types/internals/Graph.d.ts +109 -0
- package/types/internals/Graphics.d.ts +112 -0
- package/types/internals/GraphicsEngine.d.ts +96 -0
- package/types/internals/Hover.d.ts +32 -0
- package/types/internals/Hypergraph.d.ts +112 -0
- package/types/internals/IndexList.d.ts +28 -0
- package/types/internals/IndividualAttributes.d.ts +27 -0
- package/types/internals/Interactions.d.ts +45 -0
- package/types/internals/Keyboard.d.ts +25 -0
- package/types/internals/LabelManager.d.ts +56 -0
- package/types/internals/Lasso.d.ts +22 -0
- package/types/internals/Layers.d.ts +79 -0
- package/types/internals/LayersPrimitives.d.ts +5 -0
- package/types/internals/Layouts.d.ts +35 -0
- package/types/internals/LayoutsInternal.d.ts +37 -0
- package/types/internals/LayoutsPrimitives.d.ts +23 -0
- package/types/internals/Legend.d.ts +33 -0
- package/types/internals/LegendPrimitives.d.ts +3 -0
- package/types/internals/Locate.d.ts +43 -0
- package/types/internals/LocatePrimitives.d.ts +20 -0
- package/types/internals/MappingManager.d.ts +27 -0
- package/types/internals/MappingPrimitives.d.ts +29 -0
- package/types/internals/Module.d.ts +23 -0
- package/types/internals/Mouse.d.ts +42 -0
- package/types/internals/NodusModules.d.ts +99 -0
- package/types/internals/PositionModule.d.ts +10 -0
- package/types/internals/PulseModule.d.ts +29 -0
- package/types/internals/Quadtree.d.ts +100 -0
- package/types/internals/RectangleSelect.d.ts +18 -0
- package/types/internals/Resizing.d.ts +48 -0
- package/types/internals/Rewiring.d.ts +64 -0
- package/types/internals/SchemaWatchPrimitives.d.ts +75 -0
- package/types/internals/Selection.d.ts +52 -0
- package/types/internals/SelectionModule.d.ts +27 -0
- package/types/internals/Settings.d.ts +20 -0
- package/types/internals/Snapping.d.ts +54 -0
- package/types/internals/Spatial.d.ts +50 -0
- package/types/internals/SpatialPrimitives.d.ts +75 -0
- package/types/internals/Storage.d.ts +46 -0
- package/types/internals/StyleRulesModule.d.ts +21 -0
- package/types/internals/Synchronizer.d.ts +17 -0
- package/types/internals/Tooltip.d.ts +25 -0
- package/types/internals/TooltipPrimitives.d.ts +21 -0
- package/types/internals/Topology.d.ts +50 -0
- package/types/internals/Touch.d.ts +16 -0
- package/types/internals/Transformations.d.ts +36 -0
- package/types/internals/VirtualMouse.d.ts +52 -0
- package/types/internals/WasmHGrid.d.ts +25 -0
- package/types/internals/WatcherModule.d.ts +25 -0
- package/types/internals/Workers.d.ts +79 -0
- package/types/internals/algorithmExports.d.ts +333 -0
- package/types/internals/algorithmHelpers.d.ts +36 -0
- package/types/internals/attributes/AttributesManager.d.ts +216 -0
- package/types/internals/attributes/ElementAttributesManager.d.ts +119 -0
- package/types/internals/attributes/attributeHelpers.d.ts +70 -0
- package/types/internals/attributes/flexArrayFactories.d.ts +277 -0
- package/types/internals/easing.d.ts +15 -0
- package/types/internals/helpers.d.ts +79 -0
- package/types/internals/hypergraphWorker.d.ts +37 -0
- package/types/internals/hypergraphWorkerHost.d.ts +40 -0
- package/types/internals/labels/SpatialGrid.d.ts +29 -0
- package/types/internals/labels/fillEdgeTexts.d.ts +25 -0
- package/types/internals/labels/fillNodeTexts.d.ts +24 -0
- package/types/internals/labels/helpers.d.ts +180 -0
- package/types/internals/layoutWorker.d.ts +21 -0
- package/types/internals/rendering/BoundariesManager.d.ts +53 -0
- package/types/internals/rendering/Buffer2.d.ts +91 -0
- package/types/internals/rendering/BufferList.d.ts +86 -0
- package/types/internals/rendering/CpuRenderer.d.ts +128 -0
- package/types/internals/rendering/EasingManager.d.ts +40 -0
- package/types/internals/rendering/EdgeDrawer.d.ts +54 -0
- package/types/internals/rendering/ElementGroup.d.ts +66 -0
- package/types/internals/rendering/MemoryManager.d.ts +71 -0
- package/types/internals/rendering/NodeDrawer.d.ts +49 -0
- package/types/internals/rendering/PatternManager.d.ts +29 -0
- package/types/internals/rendering/RENDER_MAPPING.d.ts +5 -0
- package/types/internals/rendering/RendererBase.d.ts +127 -0
- package/types/internals/rendering/ShapeManager.d.ts +46 -0
- package/types/internals/rendering/TextManager.d.ts +112 -0
- package/types/internals/rendering/canvasHelpers.d.ts +5 -0
- package/types/internals/rendering/constants.d.ts +125 -0
- package/types/internals/rendering/curveHelpers.d.ts +96 -0
- package/types/internals/rendering/drawerHelpers.d.ts +32 -0
- package/types/internals/rendering/float16.d.ts +25 -0
- package/types/internals/rendering/hitDetection.d.ts +89 -0
- package/types/internals/rendering/loadGraph.d.ts +103 -0
- package/types/internals/rendering/objectInfo.d.ts +46 -0
- package/types/internals/rendering/packing.d.ts +46 -0
- package/types/internals/rendering/shapeHelpers.d.ts +26 -0
- package/types/internals/rendering/types.d.ts +143 -0
- package/types/internals/renderingBinaryPrimitives.d.ts +110 -0
- package/types/internals/utilsExports.d.ts +408 -0
- package/types/internals/wasmBackend.d.ts +38 -0
- package/types/internals/wasmColumns.d.ts +61 -0
- package/types/internals/wasmInit.d.ts +1 -0
- package/types/modules/APIModule.d.ts +8 -0
- package/types/modules/AlgorithmsAPI.d.ts +15 -0
- package/types/modules/BrandAPI.d.ts +6 -0
- package/types/modules/CaptorAPI.d.ts +9 -0
- package/types/modules/ClassesAPI.d.ts +9 -0
- package/types/modules/DebugAPI.d.ts +18 -0
- package/types/modules/DisabledAPI.d.ts +11 -0
- package/types/modules/DomAPI.d.ts +9 -0
- package/types/modules/EventsAPI.d.ts +16 -0
- package/types/modules/ExportAPI.d.ts +23 -0
- package/types/modules/GeneratorsAPI.d.ts +12 -0
- package/types/modules/GeoAPI.d.ts +20 -0
- package/types/modules/GraphAPI.d.ts +26 -0
- package/types/modules/GraphicsAPI.d.ts +8 -0
- package/types/modules/HypergraphAPI.d.ts +71 -0
- package/types/modules/KeyboardAPI.d.ts +6 -0
- package/types/modules/LayersAPI.d.ts +7 -0
- package/types/modules/LayoutsAPI.d.ts +25 -0
- package/types/modules/LegendAPI.d.ts +9 -0
- package/types/modules/MouseAPI.d.ts +16 -0
- package/types/modules/ParseAPI.d.ts +83 -0
- package/types/modules/RulesAPI.d.ts +7 -0
- package/types/modules/SchemaAPI.d.ts +9 -0
- package/types/modules/SelectionAPI.d.ts +12 -0
- package/types/modules/SettingsAPI.d.ts +9 -0
- package/types/modules/StylesAPI.d.ts +64 -0
- package/types/modules/ToolsAPI.d.ts +68 -0
- package/types/modules/TransformationsAPI.d.ts +30 -0
- package/types/modules/ViewAPI.d.ts +52 -0
- package/types/publicTypes.d.ts +56 -0
- package/types/renderers/CanvasRenderer.d.ts +86 -0
- package/types/renderers/Renderer.d.ts +13 -0
- package/types/renderers/SVGRenderer.d.ts +57 -0
- package/types/renderers/WasmGraphRenderer.d.ts +118 -0
- package/types/renderers/WasmRendererAdapter.d.ts +38 -0
- package/types/tools/ConnectNodesAPI.d.ts +42 -0
- package/types/tools/LassoAPI.d.ts +78 -0
- package/types/tools/RectangleSelectAPI.d.ts +51 -0
- package/types/tools/ResizingAPI.d.ts +62 -0
- package/types/tools/RewiringAPI.d.ts +78 -0
- package/types/tools/SnappingAPI.d.ts +71 -0
- package/types/tools/ToolsAPI.d.ts +46 -0
- package/types/tools/TooltipAPI.d.ts +141 -0
- package/types/transformations/TransformationsEngine.d.ts +602 -0
- package/types/utils/index.d.ts +6 -0
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* DebugAPI — debug utilities.
|
|
3
|
+
* Binary: `DebugAPI = class extends APIModule { constructor(){ super(...arguments), this.wait=..., ... } }`
|
|
4
|
+
*/
|
|
5
|
+
import { APIModule } from './APIModule';
|
|
6
|
+
export declare class DebugAPI extends APIModule {
|
|
7
|
+
wait: (ms: number) => Promise<void>;
|
|
8
|
+
initRandomGraph: (opts?: any) => Promise<void>;
|
|
9
|
+
initGrid: (count: number) => Promise<void>;
|
|
10
|
+
initLine: (vertical?: boolean) => any;
|
|
11
|
+
initSingleNode: () => any;
|
|
12
|
+
initContinuousRenderLoop: (opts?: any) => void;
|
|
13
|
+
appendToBody: () => void;
|
|
14
|
+
loadFile: (url: string) => Promise<void>;
|
|
15
|
+
enableLasso: () => void;
|
|
16
|
+
randomizeGraph: () => void;
|
|
17
|
+
constructor(nodus: any);
|
|
18
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* DisabledAPI mixin — merged into Nodus via applyMixins.
|
|
3
|
+
* Binary: `DisabledAPI = class { getDisabledNodes(){...} ... }`
|
|
4
|
+
*/
|
|
5
|
+
export declare class DisabledAPI<ND = any, ED = any> {
|
|
6
|
+
modules: any;
|
|
7
|
+
getDisabledNodes(): any;
|
|
8
|
+
getEnabledNodes(): any;
|
|
9
|
+
getDisabledEdges(): any;
|
|
10
|
+
getEnabledEdges(): any;
|
|
11
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* DomAPI mixin — merged into Nodus via applyMixins.
|
|
3
|
+
* Binary: `DomAPI = class { setContainer(e){...} getContainer(){...} }`
|
|
4
|
+
*/
|
|
5
|
+
export declare class DomAPI {
|
|
6
|
+
modules: any;
|
|
7
|
+
setContainer(container: HTMLElement | string): void;
|
|
8
|
+
getContainer(): HTMLElement | null;
|
|
9
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* EventsAPI — public events module.
|
|
3
|
+
* Binary: `EventsAPI = class extends APIModule { constructor(){...} on(e,t){...} off(e){...} onKeyPress(e,t){...} }`
|
|
4
|
+
*/
|
|
5
|
+
import { APIModule } from './APIModule';
|
|
6
|
+
export declare class EventsAPI extends APIModule {
|
|
7
|
+
constructor(nodus: any);
|
|
8
|
+
once: (event: string, handler: Function) => this;
|
|
9
|
+
onNodesClassAdded: (event: any, handler: any) => any;
|
|
10
|
+
onNodesClassRemoved: (event: any, handler: any) => any;
|
|
11
|
+
onEdgesClassAdded: (event: any, handler: any) => any;
|
|
12
|
+
onEdgesClassRemoved: (event: any, handler: any) => any;
|
|
13
|
+
on(event: string, handler: Function): this;
|
|
14
|
+
off(event: string): this;
|
|
15
|
+
onKeyPress(key: string, handler: Function): any;
|
|
16
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ExportsAPI — exports the current graph in a variety of formats.
|
|
3
|
+
*
|
|
4
|
+
* Extends APIModule and exposes one method per supported format (csv, xlsx,
|
|
5
|
+
* gexf, graphml, json, svg, png, jpg, tiff, gif). Each method delegates to the
|
|
6
|
+
* optional `exports` module when it is available, and otherwise falls back to a
|
|
7
|
+
* lightweight built-in serializer.
|
|
8
|
+
*/
|
|
9
|
+
import { APIModule } from './APIModule';
|
|
10
|
+
export declare class ExportsAPI extends APIModule {
|
|
11
|
+
csv: (opts?: any) => Promise<any>;
|
|
12
|
+
xlsx: (opts?: any) => Promise<any>;
|
|
13
|
+
gexf: (opts?: any) => Promise<any>;
|
|
14
|
+
graphml: (opts?: any) => Promise<any>;
|
|
15
|
+
json: (opts?: any) => Promise<any>;
|
|
16
|
+
svg: (opts?: any) => Promise<any>;
|
|
17
|
+
png: (opts?: any) => Promise<any>;
|
|
18
|
+
jpg: (opts?: any) => Promise<any>;
|
|
19
|
+
tiff: (opts?: any) => Promise<any>;
|
|
20
|
+
gif: (opts?: any) => Promise<any>;
|
|
21
|
+
constructor(nodus: any);
|
|
22
|
+
}
|
|
23
|
+
export { ExportsAPI as ExportAPI };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { APIModule } from './APIModule';
|
|
2
|
+
export declare class GeneratorsAPI extends APIModule {
|
|
3
|
+
balancedTree: (opts?: any) => Promise<any>;
|
|
4
|
+
barabasiAlbert: (opts?: any) => Promise<any>;
|
|
5
|
+
erdosRenyi: (opts?: any) => Promise<any>;
|
|
6
|
+
flower: (opts?: any) => Promise<any>;
|
|
7
|
+
grid: (opts?: any) => Promise<any>;
|
|
8
|
+
path: (opts?: any) => Promise<any>;
|
|
9
|
+
random: (opts?: any) => Promise<any>;
|
|
10
|
+
randomTree: (opts?: any) => Promise<any>;
|
|
11
|
+
constructor(nodus: any);
|
|
12
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { APIModule } from './APIModule';
|
|
2
|
+
export declare class GeoAPI extends APIModule {
|
|
3
|
+
enable: (opts?: any) => any;
|
|
4
|
+
disable: (opts?: any) => any;
|
|
5
|
+
toggle: (opts?: any) => any;
|
|
6
|
+
setOptions: (opts: any) => any;
|
|
7
|
+
getOptions: () => any;
|
|
8
|
+
getMap: () => any;
|
|
9
|
+
enabled: () => boolean;
|
|
10
|
+
getCenter: () => any;
|
|
11
|
+
getView: () => any;
|
|
12
|
+
getZoom: () => number;
|
|
13
|
+
setZoom: (zoom: number) => any;
|
|
14
|
+
setView: (lat: number, lng: number, zoom?: number) => any;
|
|
15
|
+
setCenter: (coords: any, opts?: any) => any;
|
|
16
|
+
getUnprojectedCoordinates: () => any;
|
|
17
|
+
resetCoordinates: () => any;
|
|
18
|
+
runLayout: (opts?: any) => any;
|
|
19
|
+
constructor(nodus: any);
|
|
20
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GraphAPI mixin — merged into Nodus via applyMixins.
|
|
3
|
+
* Binary: `GraphAPI = class { addNodes(e,t){...} ... }`
|
|
4
|
+
*/
|
|
5
|
+
export declare class GraphAPI {
|
|
6
|
+
modules: any;
|
|
7
|
+
addNodes(elements: any, opts?: any): any;
|
|
8
|
+
addEdges(elements: any, opts?: any): any;
|
|
9
|
+
addNode(element: any, opts?: any): any;
|
|
10
|
+
addEdge(element: any, opts?: any): any;
|
|
11
|
+
removeNodes(elements: any, opts?: any): Promise<void>;
|
|
12
|
+
removeEdges(elements: any, opts?: any): Promise<void>;
|
|
13
|
+
removeNode(element: any, opts?: any): Promise<void>;
|
|
14
|
+
removeEdge(element: any, opts?: any): Promise<void>;
|
|
15
|
+
getNodes(filter?: any): any;
|
|
16
|
+
getEdges(filter?: any): any;
|
|
17
|
+
getNode(id: any): any;
|
|
18
|
+
getEdge(id: any): any;
|
|
19
|
+
clearGraph(): void;
|
|
20
|
+
setGraph(graph: any, opts?: any): any;
|
|
21
|
+
addGraph(graph: any, opts?: any): any;
|
|
22
|
+
createNodeList(): any;
|
|
23
|
+
createEdgeList(): any;
|
|
24
|
+
getConnectedComponents(opts?: any): any;
|
|
25
|
+
getConnectedComponentByNode(nodeId: any, opts?: any): any;
|
|
26
|
+
}
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Public façade for the hypergraph subsystem (Oliver et al., TVCG 2023).
|
|
3
|
+
*
|
|
4
|
+
* Usage:
|
|
5
|
+
* nodus.hypergraph
|
|
6
|
+
* .setData({ vertices, hyperedges })
|
|
7
|
+
* .simplify({ alpha: 0.4, beta: 0.4, gamma: 0.2 })
|
|
8
|
+
* .layout({ separationIters: 200, regularityIters: 300 });
|
|
9
|
+
* nodus.hypergraph.render({ view: 'primal' });
|
|
10
|
+
*/
|
|
11
|
+
import { APIModule } from './APIModule';
|
|
12
|
+
import type { HypergraphData, HypergraphId, HypergraphRenderOptions, InteractionEvent, LayoutOptions, QualityMetrics, SimplificationOptions, Vec2, AtomicOperationRecord } from '../hypergraph';
|
|
13
|
+
export declare class HypergraphAPI extends APIModule {
|
|
14
|
+
private get _module();
|
|
15
|
+
setData(data: HypergraphData): this;
|
|
16
|
+
fromNodesAndEdges(opts: {
|
|
17
|
+
groupBy: (n: any) => Array<HypergraphId>;
|
|
18
|
+
}): this;
|
|
19
|
+
getData(): HypergraphData;
|
|
20
|
+
getDual(): HypergraphData;
|
|
21
|
+
simplify(opts?: SimplificationOptions): {
|
|
22
|
+
scales: number;
|
|
23
|
+
operations: number;
|
|
24
|
+
};
|
|
25
|
+
getScales(): ReadonlyArray<HypergraphData>;
|
|
26
|
+
getOperationStack(): ReadonlyArray<AtomicOperationRecord>;
|
|
27
|
+
layout(opts?: LayoutOptions): Promise<{
|
|
28
|
+
totalEnergy: number;
|
|
29
|
+
overlapCount: number;
|
|
30
|
+
}>;
|
|
31
|
+
getVertexPositions(): Map<HypergraphId, Vec2>;
|
|
32
|
+
getDualPositions(): Map<HypergraphId, Vec2>;
|
|
33
|
+
getHyperedgePolygon(heId: HypergraphId): Vec2[];
|
|
34
|
+
render(opts?: HypergraphRenderOptions): {
|
|
35
|
+
primal?: any;
|
|
36
|
+
dual?: any;
|
|
37
|
+
};
|
|
38
|
+
refresh(): this;
|
|
39
|
+
hide(): this;
|
|
40
|
+
show(): this;
|
|
41
|
+
destroy(): this;
|
|
42
|
+
setActiveView(view: 'primal' | 'dual' | 'both'): this;
|
|
43
|
+
getQualityMetrics(): QualityMetrics;
|
|
44
|
+
/** Hyperedge currently under the mouse, or null. */
|
|
45
|
+
getHoveredHyperedge(): HypergraphId | null;
|
|
46
|
+
/** Vertex currently under the mouse, or null. */
|
|
47
|
+
getHoveredVertex(): HypergraphId | null;
|
|
48
|
+
/** Dual-polygon hit (corresponds to a primal vertex), or null. */
|
|
49
|
+
getHoveredDual(): HypergraphId | null;
|
|
50
|
+
/** Currently selected hyperedge ids. */
|
|
51
|
+
getSelectedHyperedges(): HypergraphId[];
|
|
52
|
+
/** Currently selected vertex ids. */
|
|
53
|
+
getSelectedVertices(): HypergraphId[];
|
|
54
|
+
/** Replace the selection. Pass `replace:false` to add to existing. */
|
|
55
|
+
setSelected(opts: {
|
|
56
|
+
hyperedges?: HypergraphId[];
|
|
57
|
+
vertices?: HypergraphId[];
|
|
58
|
+
replace?: boolean;
|
|
59
|
+
}): this;
|
|
60
|
+
/** Toggle a single hyperedge or vertex in the selection. */
|
|
61
|
+
toggleSelected(opts: {
|
|
62
|
+
hyperedge?: HypergraphId;
|
|
63
|
+
vertex?: HypergraphId;
|
|
64
|
+
}): this;
|
|
65
|
+
/** Empty the selection. */
|
|
66
|
+
clearSelection(): this;
|
|
67
|
+
/** Hit-test at a world-space point, returning the first match. */
|
|
68
|
+
getHyperedgeAtPoint(world: Vec2): InteractionEvent;
|
|
69
|
+
on(event: 'simplifyStart' | 'simplifyEnd' | 'layoutStart' | 'layoutPhase' | 'layoutIter' | 'layoutEnd' | 'render' | 'viewChanged' | 'hyperedgeHover' | 'hyperedgeOut' | 'hyperedgeClick' | 'vertexHover' | 'vertexOut' | 'vertexClick' | 'selectionChanged', cb: (e: any) => void): this;
|
|
70
|
+
off(cb: (e: any) => void): this;
|
|
71
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { APIModule } from './APIModule';
|
|
2
|
+
export declare class LayersAPI extends APIModule {
|
|
3
|
+
addLayer(opts: any, position?: any): any;
|
|
4
|
+
addCanvasLayer(opts: any, draw?: Function, position?: any): any;
|
|
5
|
+
addOverlay(opts: any, position?: any): any;
|
|
6
|
+
addSVGLayer(opts: any, position?: any): any;
|
|
7
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* LayoutsAPI — graph layout algorithms.
|
|
3
|
+
* Binary: `LayoutsAPI = class extends APIModule { constructor(e){ super(e), this.stop=..., ... } }`
|
|
4
|
+
* Each layout function is a factory that registers the layout with modules.layouts AND returns the API method.
|
|
5
|
+
*/
|
|
6
|
+
import { APIModule } from './APIModule';
|
|
7
|
+
import forceFactory from '../algorithms/forceFactory';
|
|
8
|
+
import forceLinkFactory from '../algorithms/forceLinkFactory';
|
|
9
|
+
import gridFactory from '../algorithms/gridFactory';
|
|
10
|
+
import hierarchicalFactory from '../algorithms/hierarchicalFactory';
|
|
11
|
+
import sequentialFactory from '../algorithms/sequentialFactory';
|
|
12
|
+
import radialFactory from '../algorithms/radialFactory';
|
|
13
|
+
import concentricFactory from '../algorithms/concentricFactory';
|
|
14
|
+
export { radialFactory, forceFactory, forceLinkFactory, gridFactory, hierarchicalFactory, sequentialFactory, concentricFactory, };
|
|
15
|
+
export declare class LayoutsAPI extends APIModule {
|
|
16
|
+
stop: () => void;
|
|
17
|
+
concentric: (opts?: any) => Promise<void>;
|
|
18
|
+
radial: (opts?: any) => Promise<void>;
|
|
19
|
+
force: (opts?: any) => Promise<void>;
|
|
20
|
+
forceLink: (opts?: any) => Promise<void>;
|
|
21
|
+
hierarchical: (opts?: any) => Promise<void>;
|
|
22
|
+
sequential: (opts?: any) => Promise<void>;
|
|
23
|
+
grid: (opts?: any) => Promise<void>;
|
|
24
|
+
constructor(nodus: any);
|
|
25
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* MouseAPI — virtual mouse simulation.
|
|
3
|
+
* Binary: `MouseAPI = class extends APIModule { constructor(){ super(...arguments), this.move=..., ... } }`
|
|
4
|
+
*/
|
|
5
|
+
import { APIModule } from './APIModule';
|
|
6
|
+
export declare class MouseAPI extends APIModule {
|
|
7
|
+
move: (coords: any) => any;
|
|
8
|
+
down: (coords: any) => any;
|
|
9
|
+
up: (coords: any) => any;
|
|
10
|
+
click: (coords: any) => any;
|
|
11
|
+
rightClick: (coords: any) => any;
|
|
12
|
+
doubleclick: (coords: any) => any;
|
|
13
|
+
drag: (from: any, to: any) => any;
|
|
14
|
+
wheel: (coords: any) => any;
|
|
15
|
+
constructor(nodus: any);
|
|
16
|
+
}
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import type { RawGraph } from '../publicTypes';
|
|
2
|
+
export interface Neo4JNodeData<Props = Record<string, unknown>> {
|
|
3
|
+
neo4jLabels: string[];
|
|
4
|
+
neo4jProperties: Props;
|
|
5
|
+
}
|
|
6
|
+
export interface Neo4JEdgeData<Props = Record<string, unknown>> {
|
|
7
|
+
neo4jType?: string;
|
|
8
|
+
neo4jProperties: Props;
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Parse a GEXF XML string and return the raw graph.
|
|
12
|
+
*/
|
|
13
|
+
export declare function gexf<ND = unknown, ED = unknown>(content: string): Promise<RawGraph<ND, ED>>;
|
|
14
|
+
/**
|
|
15
|
+
* Fetch and parse a GEXF file from a URL.
|
|
16
|
+
*/
|
|
17
|
+
export declare function gexfFromUrl<ND = unknown, ED = unknown>(url: string): Promise<RawGraph<ND, ED>>;
|
|
18
|
+
/**
|
|
19
|
+
* Parse a JSON string and return the raw graph.
|
|
20
|
+
* If a transform function is provided, it is used to convert the parsed
|
|
21
|
+
* JSON into a RawGraph.
|
|
22
|
+
*/
|
|
23
|
+
export declare function json<ND = unknown, ED = unknown>(content: string, transform?: (json: Record<string, any> | unknown[]) => RawGraph<ND, ED>): Promise<RawGraph<ND, ED>>;
|
|
24
|
+
/**
|
|
25
|
+
* Fetch and parse a JSON file from a URL.
|
|
26
|
+
*/
|
|
27
|
+
export declare function jsonFromUrl<ND = unknown, ED = unknown>(url: string, transform?: (json: Record<string, any> | unknown[]) => RawGraph<ND, ED>): Promise<RawGraph<ND, ED>>;
|
|
28
|
+
/**
|
|
29
|
+
* Parse a GraphML XML string and return the raw graph.
|
|
30
|
+
*/
|
|
31
|
+
export declare function graphml<ND = unknown, ED = unknown>(content: string, xmlparser?: DOMParser): Promise<RawGraph<ND, ED>>;
|
|
32
|
+
/**
|
|
33
|
+
* Fetch and parse a GraphML file from a URL.
|
|
34
|
+
*/
|
|
35
|
+
export declare function graphmlFromUrl<ND = unknown, ED = unknown>(url: string, xmlparser?: DOMParser): Promise<RawGraph<ND, ED>>;
|
|
36
|
+
/**
|
|
37
|
+
* Parse a Neo4j bolt driver result into a raw graph.
|
|
38
|
+
*
|
|
39
|
+
* Expects the result of a Neo4j session.run() call. The result should have
|
|
40
|
+
* a `records` array where each record contains nodes and relationships
|
|
41
|
+
* accessible via .get() or ._fields.
|
|
42
|
+
*
|
|
43
|
+
* Nodes have: identity, labels, properties
|
|
44
|
+
* Relationships have: identity, type, start, end, properties
|
|
45
|
+
*/
|
|
46
|
+
export declare function neo4j<ND extends Neo4JNodeData = Neo4JNodeData, ED extends Neo4JEdgeData = Neo4JEdgeData>(content: object | string): Promise<RawGraph<ND, ED>>;
|
|
47
|
+
/**
|
|
48
|
+
* Parse the result of a JanusGraph/Gremlin query into a raw graph.
|
|
49
|
+
*
|
|
50
|
+
* Expects the result of gremlin-client's `client.execute()` which returns
|
|
51
|
+
* a response with captured stores for vertices ("v") and edges ("e").
|
|
52
|
+
* Format: { result: { data: [{ v: [...], e: [...] }] } }
|
|
53
|
+
* or just an array of vertices/edges from cap("v", "e").
|
|
54
|
+
*/
|
|
55
|
+
export declare function janus<ND = unknown, ED = unknown>(content: string): Promise<RawGraph<ND, ED>>;
|
|
56
|
+
/**
|
|
57
|
+
* Parse a Matrix Market (.mtx) format string into a raw graph.
|
|
58
|
+
*
|
|
59
|
+
* Supports the coordinate format:
|
|
60
|
+
* %%MatrixMarket matrix coordinate [real|integer|pattern] [general|symmetric]
|
|
61
|
+
*
|
|
62
|
+
* Lines starting with % are comments.
|
|
63
|
+
* The first non-comment line is: rows cols entries
|
|
64
|
+
* Subsequent lines are: row col [value]
|
|
65
|
+
*
|
|
66
|
+
* Nodes are created for each unique row/column index.
|
|
67
|
+
* Edges are created for each non-zero entry.
|
|
68
|
+
* For symmetric matrices, edges are added in both directions.
|
|
69
|
+
*/
|
|
70
|
+
export declare function mtx<ND = unknown, ED = unknown>(content: string): Promise<RawGraph<ND, ED>>;
|
|
71
|
+
export declare function mtxFromUrl<ND = unknown, ED = unknown>(url: string): Promise<RawGraph<ND, ED>>;
|
|
72
|
+
export declare const parse: {
|
|
73
|
+
gexf: typeof gexf;
|
|
74
|
+
gexfFromUrl: typeof gexfFromUrl;
|
|
75
|
+
json: typeof json;
|
|
76
|
+
jsonFromUrl: typeof jsonFromUrl;
|
|
77
|
+
graphml: typeof graphml;
|
|
78
|
+
graphmlFromUrl: typeof graphmlFromUrl;
|
|
79
|
+
neo4j: typeof neo4j;
|
|
80
|
+
janus: typeof janus;
|
|
81
|
+
mtx: typeof mtx;
|
|
82
|
+
mtxFromUrl: typeof mtxFromUrl;
|
|
83
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { APIModule } from './APIModule';
|
|
2
|
+
export { PropertyInformation, NonObjectPropertyWatcher, ObjectPropertyWatcher, } from '../internals/SchemaWatchPrimitives';
|
|
3
|
+
export declare class SchemaAPI extends APIModule {
|
|
4
|
+
watchNodeObjectProperty: (opts: any) => any;
|
|
5
|
+
watchEdgeObjectProperty: (opts: any) => any;
|
|
6
|
+
watchNodeNonObjectProperty: (opts: any) => any;
|
|
7
|
+
watchEdgeNonObjectProperty: (opts: any) => any;
|
|
8
|
+
constructor(nodus: any);
|
|
9
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* SelectionAPI mixin — merged into Nodus via applyMixins.
|
|
3
|
+
* Binary: `SelectionAPI = class { clearSelection(){...} getSelectedNodes(){...} ... }`
|
|
4
|
+
*/
|
|
5
|
+
export declare class SelectionAPI<ND = any, ED = any> {
|
|
6
|
+
modules: any;
|
|
7
|
+
clearSelection(): any;
|
|
8
|
+
getSelectedNodes(): any;
|
|
9
|
+
getNonSelectedNodes(): any;
|
|
10
|
+
getSelectedEdges(): any;
|
|
11
|
+
getNonSelectedEdges(): any;
|
|
12
|
+
}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* StylesAPI — node/edge visual style management.
|
|
3
|
+
* Provides the public surface for styling: each method delegates to the
|
|
4
|
+
* relevant internal module (styleRules, graphics, classes, hover, selection,
|
|
5
|
+
* disabled) to apply visibility, rules, classes and themed attributes.
|
|
6
|
+
*/
|
|
7
|
+
import { APIModule } from './APIModule';
|
|
8
|
+
export declare class StylesAPI extends APIModule {
|
|
9
|
+
setNodesVisibility: (value: boolean) => void;
|
|
10
|
+
setEdgesVisibility: (value: boolean) => void;
|
|
11
|
+
setNodeTextsVisibility: (value: boolean) => void;
|
|
12
|
+
setEdgeTextsVisibility: (value: boolean) => void;
|
|
13
|
+
addRule: (opts?: any) => any;
|
|
14
|
+
getRuleList: () => any[];
|
|
15
|
+
addNodeRule: (attrsOrSelector: any, attrs?: any) => any;
|
|
16
|
+
addEdgeRule: (attrsOrSelector: any, attrs?: any) => any;
|
|
17
|
+
getNodeRules: () => any[];
|
|
18
|
+
getEdgeRules: () => any[];
|
|
19
|
+
createClass: (opts: any) => any;
|
|
20
|
+
getClass: (name: string) => any;
|
|
21
|
+
getClassList: () => any[];
|
|
22
|
+
setHoveredNodeAttributes: (attrs: any, opts?: any) => void;
|
|
23
|
+
setHoveredEdgeAttributes: (attrs: any, opts?: any) => void;
|
|
24
|
+
setHoveredEdgeExtremitiesAttributes: (attrs: any, extended?: boolean) => any;
|
|
25
|
+
setSelectedNodeAttributes: (attrs: any, extended?: boolean) => void;
|
|
26
|
+
setSelectedEdgeAttributes: (attrs: any, extended?: boolean) => void;
|
|
27
|
+
setSelectedEdgeExtremitiesAttributes: (attrs: any, extended?: boolean) => void;
|
|
28
|
+
setDisabledNodeAttributes: (attrs: any, opts?: any) => void;
|
|
29
|
+
setDisabledEdgeAttributes: (attrs: any, opts?: any) => void;
|
|
30
|
+
setTheme: (theme: any) => void;
|
|
31
|
+
fontSizeToBadgeScale: any;
|
|
32
|
+
constructor(nodus: any);
|
|
33
|
+
}
|
|
34
|
+
export declare class StyleRule {
|
|
35
|
+
private _module;
|
|
36
|
+
private _id;
|
|
37
|
+
private _whenApplied;
|
|
38
|
+
constructor(module: any, id: number, whenApplied: Promise<any>);
|
|
39
|
+
getId(): number;
|
|
40
|
+
whenApplied(): Promise<this>;
|
|
41
|
+
refresh(): Promise<any>;
|
|
42
|
+
getIndex(): number | null;
|
|
43
|
+
setIndex(index: number): Promise<any>;
|
|
44
|
+
update(options: any): Promise<any>;
|
|
45
|
+
getDefinition(): any;
|
|
46
|
+
destroy(): Promise<any>;
|
|
47
|
+
}
|
|
48
|
+
export declare class StyleClass {
|
|
49
|
+
private _classes;
|
|
50
|
+
private _name;
|
|
51
|
+
constructor(classes: any, name: string);
|
|
52
|
+
getName(): string;
|
|
53
|
+
getIndex(): number;
|
|
54
|
+
setIndex(index: number): void;
|
|
55
|
+
update(options: any): this;
|
|
56
|
+
getDefinition(): any;
|
|
57
|
+
getNodes(opts?: any): any;
|
|
58
|
+
getEdges(opts?: any): any;
|
|
59
|
+
clearNodes(opts?: any): void;
|
|
60
|
+
clearEdges(opts?: any): void;
|
|
61
|
+
add(elements: any): void;
|
|
62
|
+
remove(elements: any): void;
|
|
63
|
+
destroy(): Promise<any>;
|
|
64
|
+
}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ToolsAPI — aggregates tool sub-modules.
|
|
3
|
+
* Binary: `ToolsAPI = class extends APIModule { constructor(e) { super(e), this.lasso = ..., ... } }`
|
|
4
|
+
*/
|
|
5
|
+
import { APIModule } from './APIModule';
|
|
6
|
+
import { LegendAPI } from './LegendAPI';
|
|
7
|
+
import { BrandAPI } from './BrandAPI';
|
|
8
|
+
declare class LassoAPI extends APIModule {
|
|
9
|
+
enable(opts?: any): any;
|
|
10
|
+
disable(): any;
|
|
11
|
+
enabled(): any;
|
|
12
|
+
}
|
|
13
|
+
declare class ConnectNodesAPI extends APIModule {
|
|
14
|
+
enable(opts?: any): any;
|
|
15
|
+
disable(): any;
|
|
16
|
+
enabled(): any;
|
|
17
|
+
}
|
|
18
|
+
declare class RectangleSelectAPI extends APIModule {
|
|
19
|
+
enable(opts?: any): any;
|
|
20
|
+
disable(): any;
|
|
21
|
+
enabled(): any;
|
|
22
|
+
}
|
|
23
|
+
declare class ResizingAPI extends APIModule {
|
|
24
|
+
enable(opts?: any): any;
|
|
25
|
+
disable(): any;
|
|
26
|
+
enabled(): any;
|
|
27
|
+
}
|
|
28
|
+
declare class RewiringAPI extends APIModule {
|
|
29
|
+
enable(opts?: any): any;
|
|
30
|
+
setEdgesToRewire(edges: any): any;
|
|
31
|
+
disable(): any;
|
|
32
|
+
enabled(): any;
|
|
33
|
+
}
|
|
34
|
+
declare class SnappingAPI extends APIModule {
|
|
35
|
+
enable(opts?: any): any;
|
|
36
|
+
disable(): any;
|
|
37
|
+
enabled(): any;
|
|
38
|
+
}
|
|
39
|
+
declare class TooltipAPI extends APIModule {
|
|
40
|
+
onNodeHover(handler: any, options?: any): any;
|
|
41
|
+
onNodeClick(handler: any, options?: any): any;
|
|
42
|
+
onNodeRightClick(handler: any, options?: any): any;
|
|
43
|
+
onNodeDoubleClick(handler: any, options?: any): any;
|
|
44
|
+
onEdgeHover(handler: any, options?: any): any;
|
|
45
|
+
onEdgeClick(handler: any, options?: any): any;
|
|
46
|
+
onEdgeRightClick(handler: any, options?: any): any;
|
|
47
|
+
onEdgeDoubleClick(handler: any, options?: any): any;
|
|
48
|
+
onBackgroundClick(handler: any, options?: any): any;
|
|
49
|
+
onBackgroundRightClick(handler: any, options?: any): any;
|
|
50
|
+
onBackgroundDoubleClick(handler: any, options?: any): any;
|
|
51
|
+
hide(): any;
|
|
52
|
+
isShown(): any;
|
|
53
|
+
refresh(): any;
|
|
54
|
+
show(content: any, options?: any): any;
|
|
55
|
+
}
|
|
56
|
+
export declare class ToolsAPI extends APIModule {
|
|
57
|
+
lasso: LassoAPI;
|
|
58
|
+
connectNodes: ConnectNodesAPI;
|
|
59
|
+
legend: LegendAPI;
|
|
60
|
+
rectangleSelect: RectangleSelectAPI;
|
|
61
|
+
resize: ResizingAPI;
|
|
62
|
+
rewire: RewiringAPI;
|
|
63
|
+
snapping: SnappingAPI;
|
|
64
|
+
tooltip: TooltipAPI;
|
|
65
|
+
brand: BrandAPI;
|
|
66
|
+
constructor(nodus: any);
|
|
67
|
+
}
|
|
68
|
+
export {};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { APIModule } from './APIModule';
|
|
2
|
+
export declare class TransformationsAPI extends APIModule {
|
|
3
|
+
getList: () => any[];
|
|
4
|
+
clear: () => Promise<void>;
|
|
5
|
+
getById: (id: any) => any;
|
|
6
|
+
afterNextUpdate: () => Promise<void>;
|
|
7
|
+
onGroupsUpdated: (cb: Function) => void;
|
|
8
|
+
layoutGroups: (a: any, b: any, c?: boolean) => any;
|
|
9
|
+
triggerGroupUpdated: (id: any) => void;
|
|
10
|
+
triggerGroupsUpdated: () => void;
|
|
11
|
+
constructor(nodus: any);
|
|
12
|
+
addNodeGrouping(e: any): any;
|
|
13
|
+
addNodeClustering(e: any): any;
|
|
14
|
+
addEdgeGrouping(e: any): any;
|
|
15
|
+
addDrillDown(e: any): any;
|
|
16
|
+
addDrilldown(e: any): any;
|
|
17
|
+
addNodeFilter(e: any): any;
|
|
18
|
+
addEdgeFilter(e: any): any;
|
|
19
|
+
getNodeFilters(): any;
|
|
20
|
+
getEdgeFilters(): any;
|
|
21
|
+
addNeighborGeneration(e: any): any;
|
|
22
|
+
addNeighborMerging(e: any): any;
|
|
23
|
+
addNodeCollapsing(e?: any): any;
|
|
24
|
+
addGeoClustering(e: any): any;
|
|
25
|
+
addVirtualProperties(e: any): any;
|
|
26
|
+
getXYR(e: any): any;
|
|
27
|
+
expandGroup({ node: e, computeSubNodesPosition: t, onExpand: s }: any): any;
|
|
28
|
+
collapseGroup({ node: e, onCollapse: t }: any): any;
|
|
29
|
+
setAnimation(e: any): void;
|
|
30
|
+
}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ViewAPI — camera/viewport control.
|
|
3
|
+
* Public facade whose methods delegate to the internal camera, dom, locate, and
|
|
4
|
+
* spatial modules to handle zoom, pan, rotation, coordinate conversion, and hit testing.
|
|
5
|
+
*/
|
|
6
|
+
import { APIModule } from './APIModule';
|
|
7
|
+
export declare class ViewAPI extends APIModule {
|
|
8
|
+
setZoom: (zoom: number, opts?: any) => any;
|
|
9
|
+
zoomIn: (opts?: any) => any;
|
|
10
|
+
zoomOut: (opts?: any) => any;
|
|
11
|
+
getZoom: () => number;
|
|
12
|
+
setCenter: (center: any, opts?: any) => any;
|
|
13
|
+
move: (delta: any, opts?: any) => any;
|
|
14
|
+
moveToBounds: (bounds: any, opts?: any) => any;
|
|
15
|
+
moveTo: (target: any, opts?: any) => any;
|
|
16
|
+
getCenter: () => {
|
|
17
|
+
x: number;
|
|
18
|
+
y: number;
|
|
19
|
+
};
|
|
20
|
+
setAngle: (angle: number, opts?: any) => any;
|
|
21
|
+
rotate: (delta: number, opts?: any) => any;
|
|
22
|
+
getAngle: () => number;
|
|
23
|
+
set: (view: any, opts?: any) => any;
|
|
24
|
+
get: () => any;
|
|
25
|
+
graphToScreenCoordinates: (pt: any) => any;
|
|
26
|
+
screenToGraphCoordinates: (pt: any) => any;
|
|
27
|
+
getImageData: () => any;
|
|
28
|
+
getElementAt: (pt: any) => any;
|
|
29
|
+
getElementsInView: () => any;
|
|
30
|
+
getBounds: () => any;
|
|
31
|
+
getElementsInside: (x1: number, y1: number, x2: number, y2: number, inGraphCoords?: boolean) => any;
|
|
32
|
+
beforeNextFrame: () => Promise<void>;
|
|
33
|
+
afterNextFrame: () => Promise<void>;
|
|
34
|
+
setFullScreen: (value: boolean) => any;
|
|
35
|
+
isFullScreen: () => boolean;
|
|
36
|
+
forceResize: () => void;
|
|
37
|
+
getSize: () => {
|
|
38
|
+
width: number;
|
|
39
|
+
height: number;
|
|
40
|
+
};
|
|
41
|
+
setSize: (size: {
|
|
42
|
+
width: number;
|
|
43
|
+
height: number;
|
|
44
|
+
}) => Promise<void>;
|
|
45
|
+
locateGraph: (opts?: any) => Promise<void>;
|
|
46
|
+
locateRawGraph: (graph: any, opts?: any) => Promise<void>;
|
|
47
|
+
getGraphBoundingBox: (opts?: any) => any;
|
|
48
|
+
animationInProgress: () => boolean;
|
|
49
|
+
getTextBoundingBox: (element: any) => any;
|
|
50
|
+
getNodeBadgeAt: (node: any, position: any) => any;
|
|
51
|
+
constructor(nodus: any);
|
|
52
|
+
}
|