@graphty/graphty-element 2.3.1 → 2.4.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.
Files changed (69) hide show
  1. package/AGENTS.md +4 -3
  2. package/dist/ai.js +3 -3
  3. package/dist/catalog.js +28 -27
  4. package/dist/chunks/{AiManager-BBmGJbH4.js → AiManager-BD9XK30e.js} +5 -5
  5. package/dist/chunks/{DataSource-OeN3NeyD.js → DataSource-B8vf2uhW.js} +3 -3
  6. package/dist/chunks/{GraphSession-Bef1AYw9.js → GraphSession-dcwOjGJh.js} +2821 -2743
  7. package/dist/chunks/{GraphtyError-BwcnblTH.js → GraphtyError-B93WRH3e.js} +8 -6
  8. package/dist/chunks/{GraphtyLogger-5KEttFUo.js → GraphtyLogger-CqOVV13Y.js} +2 -2
  9. package/dist/chunks/{NodeStyle-DKj7HjMJ.js → NodeStyle-CtmA7dXi.js} +16 -14
  10. package/dist/chunks/{VoiceInputAdapter-Dr9Gcmds.js → VoiceInputAdapter-D0tHHi9G.js} +1 -1
  11. package/dist/chunks/{XRPivotCameraController-BbfgZWpS.js → XRPivotCameraController-DTfhvhHz.js} +2 -2
  12. package/dist/chunks/{algorithms-CpX56sUB.js → algorithms-BF0X6RPw.js} +780 -635
  13. package/dist/chunks/{capability-check-Blhb2aBB.js → capability-check-BJzlK4oL.js} +1 -1
  14. package/dist/chunks/{detect-Cqwshr9a.js → detect-vJxK7n0D.js} +2 -2
  15. package/dist/chunks/{format-detection-BXGO1lSn.js → format-detection-C80TLQ2e.js} +1 -1
  16. package/dist/chunks/{index-C0mIoumR.js → index-2xkq7wyD.js} +2623 -2241
  17. package/dist/chunks/{optionsFromZod-17lkrAJs.js → optionsFromZod-BuTOFgVM.js} +146 -139
  18. package/dist/chunks/{paletteRegistry-x7WOEKZY.js → paletteRegistry-A63C71Gn.js} +8 -6
  19. package/dist/chunks/{registry-CSba5QGJ.js → registry-jB46Gmeb.js} +1 -1
  20. package/dist/chunks/{scales-BRwl51k8.js → scales-B2d-7Bf0.js} +572 -399
  21. package/dist/chunks/{types-B7bX5c0K.js → types-C_c53VgR.js} +31 -26
  22. package/dist/commands.d.ts +4 -0
  23. package/dist/custom-elements.json +1 -1
  24. package/dist/extend.js +8 -8
  25. package/dist/graphty-catalog.json +245 -12
  26. package/dist/graphty.bundle.js +37836 -36835
  27. package/dist/graphty.js +11 -11
  28. package/dist/logging.js +2 -2
  29. package/dist/schema.d.ts +1 -1
  30. package/dist/schema.js +42 -40
  31. package/dist/session.js +6 -6
  32. package/dist/src/Graph.d.ts +79 -7
  33. package/dist/src/acceleration/AccelerationController.d.ts +14 -3
  34. package/dist/src/acceleration/types.d.ts +78 -0
  35. package/dist/src/algorithms/KCoreAlgorithm.d.ts +26 -0
  36. package/dist/src/algorithms/LinkPredictionAlgorithm.d.ts +41 -0
  37. package/dist/src/catalog/algorithms.d.ts +5 -5
  38. package/dist/src/catalog/index.d.ts +2 -2
  39. package/dist/src/catalog/layouts.d.ts +7 -6
  40. package/dist/src/catalog/types.d.ts +77 -6
  41. package/dist/src/config/EdgeStyle.d.ts +35 -0
  42. package/dist/src/config/index.d.ts +1 -1
  43. package/dist/src/data/GEXFDataSource.d.ts +23 -0
  44. package/dist/src/errors/codes.d.ts +14 -0
  45. package/dist/src/events.d.ts +30 -0
  46. package/dist/src/graphty-element.d.ts +66 -26
  47. package/dist/src/layout/GridLayoutEngine.d.ts +37 -0
  48. package/dist/src/layout/LayoutEngine.d.ts +7 -7
  49. package/dist/src/layout/NGraphLayoutEngine.d.ts +2 -0
  50. package/dist/src/layout/RadialLayoutEngine.d.ts +37 -0
  51. package/dist/src/layout/SimulationLayoutEngine.d.ts +12 -0
  52. package/dist/src/managers/DataManager.d.ts +69 -2
  53. package/dist/src/managers/EventManager.d.ts +10 -4
  54. package/dist/src/managers/GraphContext.d.ts +2 -1
  55. package/dist/src/managers/LayoutManager.d.ts +30 -3
  56. package/dist/src/meshes/MeshCache.d.ts +18 -0
  57. package/dist/src/meshes/NodeEffects.d.ts +16 -11
  58. package/dist/src/meshes/NodeMesh.d.ts +2 -2
  59. package/dist/src/meshes/RichTextParser.d.ts +26 -0
  60. package/dist/src/meshes/RichTextRenderer.d.ts +0 -1
  61. package/dist/src/session/cost/estimate.d.ts +1 -1
  62. package/dist/src/session/layout.d.ts +3 -3
  63. package/dist/src/session/runs/RunsApi.d.ts +1 -1
  64. package/dist/src/session/styles/StylesApi.d.ts +6 -0
  65. package/dist/src/session/styles/intern.d.ts +26 -5
  66. package/dist/src/session/styles/repaint.d.ts +2 -1
  67. package/dist/src/session/types.d.ts +6 -6
  68. package/dist/webgpu.js +2 -2
  69. package/package.json +6 -6
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$generated": "THIS FILE IS AUTO GENERATED: DO NOT EDIT THIS FILE. INSTEAD EDIT the descriptor tables in graphty-element/src/catalog/ AND RUN graphty-element/scripts/generate-catalog-json.mjs (it runs as part of `npm run build`).",
3
3
  "package": "@graphty/graphty-element",
4
- "version": "2.3.0",
4
+ "version": "2.3.1",
5
5
  "algorithms": [
6
6
  {
7
7
  "key": "degree",
@@ -2325,6 +2325,159 @@
2325
2325
  "key": "min-cut"
2326
2326
  }
2327
2327
  ]
2328
+ },
2329
+ {
2330
+ "key": "k-core",
2331
+ "plainName": "Core depth",
2332
+ "technicalName": "K-core decomposition",
2333
+ "description": "Peels the graph layer by layer and gives each node the depth of the most tightly knit core it belongs to: a node of depth k has at least k neighbours inside that core.",
2334
+ "category": "structure",
2335
+ "shape": "node-metric",
2336
+ "fields": [
2337
+ {
2338
+ "name": "value",
2339
+ "plainName": "Core depth",
2340
+ "technicalName": "core number",
2341
+ "kind": "node",
2342
+ "type": "integer",
2343
+ "path": "results.$.value"
2344
+ },
2345
+ {
2346
+ "name": "rank",
2347
+ "plainName": "Rank",
2348
+ "technicalName": "rank",
2349
+ "kind": "node",
2350
+ "type": "integer",
2351
+ "path": "results.$.rank"
2352
+ },
2353
+ {
2354
+ "name": "percentile",
2355
+ "plainName": "Percentile",
2356
+ "technicalName": "percentile",
2357
+ "kind": "node",
2358
+ "type": "number",
2359
+ "path": "results.$.percentile"
2360
+ },
2361
+ {
2362
+ "name": "min",
2363
+ "plainName": "Lowest",
2364
+ "technicalName": "min",
2365
+ "kind": "graph",
2366
+ "type": "number",
2367
+ "path": "results.$.min"
2368
+ },
2369
+ {
2370
+ "name": "max",
2371
+ "plainName": "Highest",
2372
+ "technicalName": "max",
2373
+ "kind": "graph",
2374
+ "type": "number",
2375
+ "path": "results.$.max"
2376
+ },
2377
+ {
2378
+ "name": "median",
2379
+ "plainName": "Middle",
2380
+ "technicalName": "median",
2381
+ "kind": "graph",
2382
+ "type": "number",
2383
+ "path": "results.$.median"
2384
+ },
2385
+ {
2386
+ "name": "mean",
2387
+ "plainName": "Average",
2388
+ "technicalName": "mean",
2389
+ "kind": "graph",
2390
+ "type": "number",
2391
+ "path": "results.$.mean"
2392
+ },
2393
+ {
2394
+ "name": "measured",
2395
+ "plainName": "Measured",
2396
+ "technicalName": "measured",
2397
+ "kind": "graph",
2398
+ "type": "integer",
2399
+ "path": "results.$.measured"
2400
+ },
2401
+ {
2402
+ "name": "normalization",
2403
+ "plainName": "Normalization",
2404
+ "technicalName": "normalization",
2405
+ "kind": "graph",
2406
+ "type": "string",
2407
+ "path": "results.$.normalization"
2408
+ },
2409
+ {
2410
+ "name": "tiedAtMin",
2411
+ "plainName": "Tied at the lowest value",
2412
+ "technicalName": "tiedAtMin",
2413
+ "kind": "graph",
2414
+ "type": "integer",
2415
+ "path": "results.$.tiedAtMin"
2416
+ }
2417
+ ],
2418
+ "options": [],
2419
+ "costClass": "instant",
2420
+ "complexity": "O(n + m)",
2421
+ "legacyKeys": [
2422
+ {
2423
+ "key": "k-core"
2424
+ }
2425
+ ]
2426
+ },
2427
+ {
2428
+ "key": "link-prediction",
2429
+ "plainName": "Likely new links",
2430
+ "technicalName": "Link prediction",
2431
+ "description": "Scores the pairs of nodes that are not yet joined by the neighbours they share, and lists the pairs most likely to be joined next.",
2432
+ "category": "prediction",
2433
+ "shape": "pair-list",
2434
+ "fields": [
2435
+ {
2436
+ "name": "pairs",
2437
+ "plainName": "Likely new links",
2438
+ "technicalName": "pairs",
2439
+ "kind": "graph",
2440
+ "type": "table",
2441
+ "path": "results.$.pairs"
2442
+ }
2443
+ ],
2444
+ "options": [
2445
+ {
2446
+ "name": "method",
2447
+ "plainName": "Method",
2448
+ "technicalName": "method",
2449
+ "type": "enum",
2450
+ "description": "Common neighbours counts the neighbours two nodes share. Adamic-Adar counts them too, but a shared neighbour with few connections counts for more than one with many.",
2451
+ "default": "adamic-adar",
2452
+ "values": [
2453
+ {
2454
+ "value": "adamic-adar",
2455
+ "label": "Adamic Adar"
2456
+ },
2457
+ {
2458
+ "value": "common-neighbors",
2459
+ "label": "Common Neighbors"
2460
+ }
2461
+ ]
2462
+ },
2463
+ {
2464
+ "name": "topK",
2465
+ "plainName": "Pairs",
2466
+ "technicalName": "topK",
2467
+ "type": "integer",
2468
+ "description": "How many of the best-scoring pairs to keep.",
2469
+ "default": 10,
2470
+ "min": 1,
2471
+ "max": 1000
2472
+ }
2473
+ ],
2474
+ "costClass": "heavy",
2475
+ "complexity": "O(n^2 * d)",
2476
+ "legacyKeys": [
2477
+ {
2478
+ "key": "link-prediction"
2479
+ }
2480
+ ]
2328
2481
  }
2329
2482
  ],
2330
2483
  "layouts": [
@@ -2534,6 +2687,93 @@
2534
2687
  ],
2535
2688
  "honoursWeights": false
2536
2689
  },
2690
+ {
2691
+ "id": "radial",
2692
+ "plainName": "Rings from a Node",
2693
+ "technicalName": "Radial layout",
2694
+ "description": "Puts one node at the centre and every other node on a ring by how many steps away it is, so the rings read outward as distance from that node.",
2695
+ "family": "geometric",
2696
+ "kind": "batch",
2697
+ "maxDimensions": 2,
2698
+ "sizeRating": "any",
2699
+ "structuralInputs": [],
2700
+ "engine": "radial",
2701
+ "options": [
2702
+ {
2703
+ "name": "scalingFactor",
2704
+ "plainName": "Scaling Factor",
2705
+ "technicalName": "scalingFactor",
2706
+ "type": "number",
2707
+ "description": "Multiplier for node positions",
2708
+ "default": 100,
2709
+ "min": 1,
2710
+ "max": 1000
2711
+ },
2712
+ {
2713
+ "name": "root",
2714
+ "plainName": "Root Node",
2715
+ "technicalName": "root",
2716
+ "type": "node-id",
2717
+ "description": "The node at the centre; empty picks the node with the most edges",
2718
+ "default": null
2719
+ },
2720
+ {
2721
+ "name": "scale",
2722
+ "plainName": "Scale",
2723
+ "technicalName": "scale",
2724
+ "type": "number",
2725
+ "description": "Radius of the outermost ring",
2726
+ "default": 1,
2727
+ "min": 0,
2728
+ "step": 0.1
2729
+ }
2730
+ ],
2731
+ "honoursWeights": false
2732
+ },
2733
+ {
2734
+ "id": "grid",
2735
+ "plainName": "Grid",
2736
+ "technicalName": "Grid layout",
2737
+ "description": "Places nodes in evenly spaced rows and columns, in the order the nodes were loaded.",
2738
+ "family": "geometric",
2739
+ "kind": "batch",
2740
+ "maxDimensions": 2,
2741
+ "sizeRating": "any",
2742
+ "structuralInputs": [],
2743
+ "engine": "grid",
2744
+ "options": [
2745
+ {
2746
+ "name": "scalingFactor",
2747
+ "plainName": "Scaling Factor",
2748
+ "technicalName": "scalingFactor",
2749
+ "type": "number",
2750
+ "description": "Multiplier for node positions",
2751
+ "default": 100,
2752
+ "min": 1,
2753
+ "max": 1000
2754
+ },
2755
+ {
2756
+ "name": "columns",
2757
+ "plainName": "Columns",
2758
+ "technicalName": "columns",
2759
+ "type": "integer",
2760
+ "description": "Number of columns; empty makes the grid as close to square as it can",
2761
+ "default": null,
2762
+ "min": 0
2763
+ },
2764
+ {
2765
+ "name": "scale",
2766
+ "plainName": "Scale",
2767
+ "technicalName": "scale",
2768
+ "type": "number",
2769
+ "description": "Half the length of the grid's longer side",
2770
+ "default": 1,
2771
+ "min": 0,
2772
+ "step": 0.1
2773
+ }
2774
+ ],
2775
+ "honoursWeights": false
2776
+ },
2537
2777
  {
2538
2778
  "id": "shell",
2539
2779
  "plainName": "Concentric Rings",
@@ -2783,7 +3023,7 @@
2783
3023
  "technicalName": "seed",
2784
3024
  "type": "seed",
2785
3025
  "description": "Seed for reproducible random positions",
2786
- "default": null,
3026
+ "default": 1,
2787
3027
  "min": 0,
2788
3028
  "advanced": true
2789
3029
  }
@@ -3816,16 +4056,7 @@
3816
4056
  }
3817
4057
  ],
3818
4058
  "unserved": {
3819
- "layouts": [
3820
- {
3821
- "id": "radial",
3822
- "reason": "No engine arranges a graph in rings by distance from a chosen node. The spiral layout winds outward but orders nodes by position in the list, not by the graph, so it answers a different question and is published under its own name instead."
3823
- },
3824
- {
3825
- "id": "grid",
3826
- "reason": "No engine places nodes on a regular lattice."
3827
- }
3828
- ],
4059
+ "layouts": [],
3829
4060
  "formats": [
3830
4061
  {
3831
4062
  "id": "sif",
@@ -3879,6 +4110,8 @@
3879
4110
  "E_PARSE_FAILED",
3880
4111
  "E_EDGE_ENDPOINTS_UNRESOLVED",
3881
4112
  "E_ID_MISSING",
4113
+ "E_EMPTY_LOAD",
4114
+ "E_SUPERSEDED",
3882
4115
  "E_TOO_LARGE",
3883
4116
  "E_OUT_OF_MEMORY",
3884
4117
  "E_CAP_EXCEEDED",