@visualli/core 0.2.13 → 0.2.15
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/dist/{chunk-EB5RHCQP.js → chunk-4R5LZUVK.js} +2 -2
- package/dist/{chunk-4O42KVJ5.js → chunk-C5IC52GJ.js} +11 -6
- package/dist/chunk-C5IC52GJ.js.map +1 -0
- package/dist/{chunk-KUW3GHKQ.js → chunk-COKCN5NW.js} +18 -11
- package/dist/chunk-COKCN5NW.js.map +1 -0
- package/dist/{chunk-DRTDHK4R.js → chunk-EASI6BW7.js} +2 -2
- package/dist/{chunk-XMD5FYME.js → chunk-KP57ODE7.js} +2 -2
- package/dist/{chunk-C2DF7LGT.js → chunk-OOTXA4BA.js} +2 -2
- package/dist/{chunk-TJF6R4WH.js → chunk-RDHSLWMU.js} +18 -2
- package/dist/chunk-RDHSLWMU.js.map +1 -0
- package/dist/{chunk-WGLWQQKC.js → chunk-URWZU4I5.js} +2 -2
- package/dist/config/index.cjs.map +1 -1
- package/dist/config/index.d.cts +4 -4
- package/dist/config/index.d.ts +4 -4
- package/dist/config/index.js +2 -2
- package/dist/constants/index.cjs.map +1 -1
- package/dist/constants/index.d.cts +2 -2
- package/dist/constants/index.d.ts +2 -2
- package/dist/constants/index.js +2 -2
- package/dist/{designSystem-C6DKkmV8.d.ts → designSystem-D-iI9c23.d.cts} +1 -1
- package/dist/{designSystem-C6DKkmV8.d.cts → designSystem-D-iI9c23.d.ts} +1 -1
- package/dist/{ideaSize-B4lvLW5S.d.ts → ideaSize-BD-vUcOU.d.ts} +1 -1
- package/dist/{ideaSize-CTA03TLY.d.cts → ideaSize-Dj7qGmuk.d.cts} +1 -1
- package/dist/{index-BSG3ACvL.d.ts → index-Bi8djF7z.d.ts} +1 -1
- package/dist/{index-CzKgW53y.d.cts → index-uqNXf5yF.d.cts} +1 -1
- package/dist/index.cjs +42 -13
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +23 -13
- package/dist/index.d.ts +23 -13
- package/dist/index.js +10 -8
- package/dist/index.js.map +1 -1
- package/dist/layout/index.d.cts +2 -2
- package/dist/layout/index.d.ts +2 -2
- package/dist/{mindmap-B59ENw1g.d.ts → mindmap-BU-aLrAR.d.ts} +1 -1
- package/dist/{mindmap-D2M47Mxn.d.cts → mindmap-BbQrM6Pm.d.cts} +1 -1
- package/dist/parser/index.cjs +23 -2
- package/dist/parser/index.cjs.map +1 -1
- package/dist/parser/index.d.cts +3 -3
- package/dist/parser/index.d.ts +3 -3
- package/dist/parser/index.js +4 -4
- package/dist/performance/index.cjs.map +1 -1
- package/dist/performance/index.js +2 -2
- package/dist/theme/index.cjs +17 -1
- package/dist/theme/index.cjs.map +1 -1
- package/dist/theme/index.d.cts +2 -2
- package/dist/theme/index.d.ts +2 -2
- package/dist/theme/index.js +2 -2
- package/dist/types/index.d.cts +2 -2
- package/dist/types/index.d.ts +2 -2
- package/dist/viewport/index.cjs.map +1 -1
- package/dist/viewport/index.d.cts +2 -2
- package/dist/viewport/index.d.ts +2 -2
- package/dist/viewport/index.js +2 -2
- package/package.json +2 -2
- package/src/generated/designSystem.ts +17 -1
- package/src/generated/geometry/interaction.ts +19 -8
- package/src/index.ts +3 -3
- package/src/parser/visualliConverter.ts +8 -3
- package/dist/chunk-4O42KVJ5.js.map +0 -1
- package/dist/chunk-KUW3GHKQ.js.map +0 -1
- package/dist/chunk-TJF6R4WH.js.map +0 -1
- /package/dist/{chunk-EB5RHCQP.js.map → chunk-4R5LZUVK.js.map} +0 -0
- /package/dist/{chunk-DRTDHK4R.js.map → chunk-EASI6BW7.js.map} +0 -0
- /package/dist/{chunk-XMD5FYME.js.map → chunk-KP57ODE7.js.map} +0 -0
- /package/dist/{chunk-C2DF7LGT.js.map → chunk-OOTXA4BA.js.map} +0 -0
- /package/dist/{chunk-WGLWQQKC.js.map → chunk-URWZU4I5.js.map} +0 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { R as RenderConfig } from '../mindmap-
|
|
2
|
-
import '../designSystem-
|
|
1
|
+
import { R as RenderConfig } from '../mindmap-BbQrM6Pm.cjs';
|
|
2
|
+
import '../designSystem-D-iI9c23.cjs';
|
|
3
3
|
|
|
4
4
|
declare const FPS_TARGET = 60;
|
|
5
5
|
declare const FPS_WARNING_THRESHOLD = 45;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { R as RenderConfig } from '../mindmap-
|
|
2
|
-
import '../designSystem-
|
|
1
|
+
import { R as RenderConfig } from '../mindmap-BU-aLrAR.js';
|
|
2
|
+
import '../designSystem-D-iI9c23.js';
|
|
3
3
|
|
|
4
4
|
declare const FPS_TARGET = 60;
|
|
5
5
|
declare const FPS_WARNING_THRESHOLD = 45;
|
package/dist/constants/index.js
CHANGED
|
@@ -9,7 +9,7 @@ import {
|
|
|
9
9
|
getRecommendedRenderConfig,
|
|
10
10
|
getRenderConfigForQuality,
|
|
11
11
|
isFeatureEnabled
|
|
12
|
-
} from "../chunk-
|
|
12
|
+
} from "../chunk-4R5LZUVK.js";
|
|
13
13
|
import {
|
|
14
14
|
LAYOUT_SPACING
|
|
15
15
|
} from "../chunk-N7HCYULH.js";
|
|
@@ -55,7 +55,7 @@ import {
|
|
|
55
55
|
ZOOM_DEFAULT,
|
|
56
56
|
ZOOM_MAX,
|
|
57
57
|
ZOOM_MIN
|
|
58
|
-
} from "../chunk-
|
|
58
|
+
} from "../chunk-COKCN5NW.js";
|
|
59
59
|
export {
|
|
60
60
|
CIRCULAR_REFERENCE_MAX_DEPTH,
|
|
61
61
|
CLICK_THRESHOLD,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/** Version of the design system these modules were generated from. */
|
|
2
|
-
declare const DESIGN_SYSTEM_VERSION: "0.3.
|
|
2
|
+
declare const DESIGN_SYSTEM_VERSION: "0.3.7";
|
|
3
3
|
declare const THEME_NAMES: readonly ["light", "dark", "focus-light", "focus-dark", "colorsafe-light", "colorsafe-dark", "contrast-light", "contrast-dark"];
|
|
4
4
|
type ThemeName = (typeof THEME_NAMES)[number];
|
|
5
5
|
/** Every token for every theme (each theme already merged over "light"). Keys match the CSS custom properties. */
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/** Version of the design system these modules were generated from. */
|
|
2
|
-
declare const DESIGN_SYSTEM_VERSION: "0.3.
|
|
2
|
+
declare const DESIGN_SYSTEM_VERSION: "0.3.7";
|
|
3
3
|
declare const THEME_NAMES: readonly ["light", "dark", "focus-light", "focus-dark", "colorsafe-light", "colorsafe-dark", "contrast-light", "contrast-dark"];
|
|
4
4
|
type ThemeName = (typeof THEME_NAMES)[number];
|
|
5
5
|
/** Every token for every theme (each theme already merged over "light"). Keys match the CSS custom properties. */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { I as IdeaKind } from './mindmap-
|
|
1
|
+
import { I as IdeaKind } from './mindmap-BU-aLrAR.js';
|
|
2
2
|
import { V as VisualliLayer } from './layer-B2A3Ki48.js';
|
|
3
3
|
|
|
4
4
|
/** Width in px of `text` in the idea label's face at `px` (the label's weight; readable type adds its tracking). */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { I as IdeaKind } from './mindmap-
|
|
1
|
+
import { I as IdeaKind } from './mindmap-BbQrM6Pm.cjs';
|
|
2
2
|
import { V as VisualliLayer } from './layer-B2A3Ki48.cjs';
|
|
3
3
|
|
|
4
4
|
/** Width in px of `text` in the idea label's face at `px` (the label's weight; readable type adds its tracking). */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { T as TopicName$1, M as METRICS, a as ThemeName } from './designSystem-
|
|
1
|
+
import { T as TopicName$1, M as METRICS, a as ThemeName } from './designSystem-D-iI9c23.js';
|
|
2
2
|
|
|
3
3
|
/** The eight topics, in the order missing colors cycle through. */
|
|
4
4
|
declare const TOPIC_ORDER: readonly ["teal", "harbor", "iris", "berry", "coral", "amber", "sun", "stone"];
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { T as TopicName$1, M as METRICS, a as ThemeName } from './designSystem-
|
|
1
|
+
import { T as TopicName$1, M as METRICS, a as ThemeName } from './designSystem-D-iI9c23.cjs';
|
|
2
2
|
|
|
3
3
|
/** The eight topics, in the order missing colors cycle through. */
|
|
4
4
|
declare const TOPIC_ORDER: readonly ["teal", "harbor", "iris", "berry", "coral", "amber", "sun", "stone"];
|
package/dist/index.cjs
CHANGED
|
@@ -30,6 +30,7 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
|
|
|
30
30
|
// src/index.ts
|
|
31
31
|
var index_exports = {};
|
|
32
32
|
__export(index_exports, {
|
|
33
|
+
BACK: () => BACK,
|
|
33
34
|
BLOB_SHAPES: () => BLOB_SHAPES,
|
|
34
35
|
CANVAS_STYLE: () => CANVAS_STYLE,
|
|
35
36
|
CIRCULAR_REFERENCE_MAX_DEPTH: () => CIRCULAR_REFERENCE_MAX_DEPTH,
|
|
@@ -537,7 +538,7 @@ function countLayersBeneath(doc, nodeId, visited = /* @__PURE__ */ new Set()) {
|
|
|
537
538
|
}
|
|
538
539
|
|
|
539
540
|
// src/generated/designSystem.ts
|
|
540
|
-
var DESIGN_SYSTEM_VERSION = "0.3.
|
|
541
|
+
var DESIGN_SYSTEM_VERSION = "0.3.7";
|
|
541
542
|
var THEME_NAMES = [
|
|
542
543
|
"light",
|
|
543
544
|
"dark",
|
|
@@ -572,6 +573,8 @@ var TOKENS = {
|
|
|
572
573
|
"node-ink": "#182140",
|
|
573
574
|
"edge": "#2a3048",
|
|
574
575
|
"edge-label": "#4f5671",
|
|
576
|
+
"info": "#2f5a87",
|
|
577
|
+
"info-soft": "#e2edf8",
|
|
575
578
|
"topic-teal": "#87f2f8",
|
|
576
579
|
"topic-teal-ring": "#00949c",
|
|
577
580
|
"topic-harbor": "#bcdbff",
|
|
@@ -645,6 +648,8 @@ var TOKENS = {
|
|
|
645
648
|
"node-ink": "#182140",
|
|
646
649
|
"edge": "#c9cddc",
|
|
647
650
|
"edge-label": "#b3b8cc",
|
|
651
|
+
"info": "#7cc8f2",
|
|
652
|
+
"info-soft": "#13283a",
|
|
648
653
|
"topic-teal": "#87f2f8",
|
|
649
654
|
"topic-teal-ring": "#0fc5cd",
|
|
650
655
|
"topic-harbor": "#bcdbff",
|
|
@@ -718,6 +723,8 @@ var TOKENS = {
|
|
|
718
723
|
"node-ink": "#182140",
|
|
719
724
|
"edge": "#5a6079",
|
|
720
725
|
"edge-label": "#5a6079",
|
|
726
|
+
"info": "#2f5a87",
|
|
727
|
+
"info-soft": "#e2edf8",
|
|
721
728
|
"topic-teal": "#bce8ea",
|
|
722
729
|
"topic-teal-ring": "#2c9298",
|
|
723
730
|
"topic-harbor": "#c9d9ec",
|
|
@@ -791,6 +798,8 @@ var TOKENS = {
|
|
|
791
798
|
"node-ink": "#182140",
|
|
792
799
|
"edge": "#a9aec0",
|
|
793
800
|
"edge-label": "#b3b8cc",
|
|
801
|
+
"info": "#7cc8f2",
|
|
802
|
+
"info-soft": "#13283a",
|
|
794
803
|
"topic-teal": "#bce8ea",
|
|
795
804
|
"topic-teal-ring": "#71bdc1",
|
|
796
805
|
"topic-harbor": "#c9d9ec",
|
|
@@ -864,6 +873,8 @@ var TOKENS = {
|
|
|
864
873
|
"node-ink": "#182140",
|
|
865
874
|
"edge": "#2a3048",
|
|
866
875
|
"edge-label": "#4f5671",
|
|
876
|
+
"info": "#603376",
|
|
877
|
+
"info-soft": "#efe6f6",
|
|
867
878
|
"topic-teal": "#bbeec1",
|
|
868
879
|
"topic-teal-ring": "#389754",
|
|
869
880
|
"topic-harbor": "#9bc9ef",
|
|
@@ -937,6 +948,8 @@ var TOKENS = {
|
|
|
937
948
|
"node-ink": "#182140",
|
|
938
949
|
"edge": "#c9cddc",
|
|
939
950
|
"edge-label": "#b3b8cc",
|
|
951
|
+
"info": "#daa4f6",
|
|
952
|
+
"info-soft": "#2a1c33",
|
|
940
953
|
"topic-teal": "#bbeec1",
|
|
941
954
|
"topic-teal-ring": "#69c27e",
|
|
942
955
|
"topic-harbor": "#9bc9ef",
|
|
@@ -1010,6 +1023,8 @@ var TOKENS = {
|
|
|
1010
1023
|
"node-ink": "#000000",
|
|
1011
1024
|
"edge": "#000000",
|
|
1012
1025
|
"edge-label": "#1f2433",
|
|
1026
|
+
"info": "#471f61",
|
|
1027
|
+
"info-soft": "#ffffff",
|
|
1013
1028
|
"topic-teal": "#87f2f8",
|
|
1014
1029
|
"topic-teal-ring": "#006b70",
|
|
1015
1030
|
"topic-harbor": "#bcdbff",
|
|
@@ -1083,6 +1098,8 @@ var TOKENS = {
|
|
|
1083
1098
|
"node-ink": "#000000",
|
|
1084
1099
|
"edge": "#ffffff",
|
|
1085
1100
|
"edge-label": "#e6e8f0",
|
|
1101
|
+
"info": "#d5a5d6",
|
|
1102
|
+
"info-soft": "#000000",
|
|
1086
1103
|
"topic-teal": "#87f2f8",
|
|
1087
1104
|
"topic-teal-ring": "#64eff7",
|
|
1088
1105
|
"topic-harbor": "#bcdbff",
|
|
@@ -1867,8 +1884,13 @@ function convertVisualliToFlatNodes(doc, opts = {}) {
|
|
|
1867
1884
|
}
|
|
1868
1885
|
for (const node of map.values()) {
|
|
1869
1886
|
node.childrenIds = [];
|
|
1870
|
-
|
|
1871
|
-
|
|
1887
|
+
}
|
|
1888
|
+
for (const node of map.values()) {
|
|
1889
|
+
if (node.parentId) {
|
|
1890
|
+
const parent = map.get(node.parentId);
|
|
1891
|
+
if (parent) {
|
|
1892
|
+
(parent.childrenIds ?? (parent.childrenIds = [])).push(node.id);
|
|
1893
|
+
}
|
|
1872
1894
|
}
|
|
1873
1895
|
}
|
|
1874
1896
|
return map;
|
|
@@ -2063,24 +2085,30 @@ var GESTURE = {
|
|
|
2063
2085
|
pinchZoom: true,
|
|
2064
2086
|
/** Moving both fingers pans the contents. */
|
|
2065
2087
|
twoFingerPan: true,
|
|
2088
|
+
/** One finger on the empty canvas pans the contents too, on every surface (VI-040). A host whose map sits inside a
|
|
2089
|
+
* scrolling page can pass `gestures="cooperative"` to give one finger back to the page (two fingers then move the map). */
|
|
2090
|
+
oneFingerPan: true,
|
|
2066
2091
|
/** The pointers that pinch (PointerEvent.pointerType). */
|
|
2067
2092
|
pointers: ["touch"],
|
|
2068
|
-
/**
|
|
2069
|
-
*
|
|
2070
|
-
* page (touch-action: pan-x pan-y); two fingers that land together pinch the map. */
|
|
2093
|
+
/** The map takes every touch gesture (touch-action: none), so the browser never zooms or scrolls under it. With
|
|
2094
|
+
* `gestures="cooperative"` one finger scrolls the page (touch-action: pan-x pan-y); two fingers move the map. */
|
|
2071
2095
|
appTouchAction: "none",
|
|
2072
2096
|
embeddedTouchAction: "pan-x pan-y",
|
|
2073
|
-
/** Press and move on the empty canvas to pan the contents
|
|
2074
|
-
*
|
|
2097
|
+
/** Press and move on the empty canvas to pan the contents - mouse, pen and one finger. A press that moves less than
|
|
2098
|
+
* `panSlop` px is a click or a tap. */
|
|
2075
2099
|
dragPan: true,
|
|
2076
|
-
panPointers: ["mouse", "pen"],
|
|
2100
|
+
panPointers: ["mouse", "pen", "touch"],
|
|
2077
2101
|
panSlop: 6,
|
|
2078
2102
|
/** Moving an idea starts once the press has moved this far (px), by pointerModeFor: a mouse ('hover') sooner, a finger
|
|
2079
2103
|
* or pen ('touch') later, so taps still work. */
|
|
2080
|
-
ideaDragSlop: { hover: 4, touch: 10 }
|
|
2081
|
-
|
|
2082
|
-
|
|
2083
|
-
|
|
2104
|
+
ideaDragSlop: { hover: 4, touch: 10 }
|
|
2105
|
+
};
|
|
2106
|
+
var BACK = {
|
|
2107
|
+
/** Two taps this close in time (ms) and place (px) are a double-tap. */
|
|
2108
|
+
doubleTapMs: 300,
|
|
2109
|
+
doubleTapPx: 32,
|
|
2110
|
+
/** The bump at the top layer (ms). */
|
|
2111
|
+
bumpMs: 320
|
|
2084
2112
|
};
|
|
2085
2113
|
function pinchZoom(startZoom, startDistance, distance) {
|
|
2086
2114
|
const z = startZoom * (distance / Math.max(startDistance, 1));
|
|
@@ -2960,6 +2988,7 @@ function shadowsShown(visibleIdeas) {
|
|
|
2960
2988
|
}
|
|
2961
2989
|
// Annotate the CommonJS export names for ESM import in node:
|
|
2962
2990
|
0 && (module.exports = {
|
|
2991
|
+
BACK,
|
|
2963
2992
|
BLOB_SHAPES,
|
|
2964
2993
|
CANVAS_STYLE,
|
|
2965
2994
|
CIRCULAR_REFERENCE_MAX_DEPTH,
|