markmap-view 0.17.3-beta.3 → 0.17.3-beta.4
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/browser/index.js +6 -54
- package/dist/constants.d.ts +1 -1
- package/dist/index.js +7 -55
- package/package.json +5 -5
package/dist/browser/index.js
CHANGED
|
@@ -584,63 +584,15 @@
|
|
|
584
584
|
const version$1 = "2.1.2";
|
|
585
585
|
const main = "build/d3-flextree.js";
|
|
586
586
|
const module = "index";
|
|
587
|
-
const author = {
|
|
588
|
-
name: "Chris Maloney",
|
|
589
|
-
url: "http://chrismaloney.org"
|
|
590
|
-
};
|
|
587
|
+
const author = { "name": "Chris Maloney", "url": "http://chrismaloney.org" };
|
|
591
588
|
const description = "Flexible tree layout algorithm that allows for variable node sizes.";
|
|
592
|
-
const keywords = [
|
|
593
|
-
"d3",
|
|
594
|
-
"d3-module",
|
|
595
|
-
"layout",
|
|
596
|
-
"tree",
|
|
597
|
-
"hierarchy",
|
|
598
|
-
"d3-hierarchy",
|
|
599
|
-
"plugin",
|
|
600
|
-
"d3-plugin",
|
|
601
|
-
"infovis",
|
|
602
|
-
"visualization",
|
|
603
|
-
"2d"
|
|
604
|
-
];
|
|
589
|
+
const keywords = ["d3", "d3-module", "layout", "tree", "hierarchy", "d3-hierarchy", "plugin", "d3-plugin", "infovis", "visualization", "2d"];
|
|
605
590
|
const homepage = "https://github.com/klortho/d3-flextree";
|
|
606
591
|
const license = "WTFPL";
|
|
607
|
-
const repository = {
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
};
|
|
611
|
-
const scripts = {
|
|
612
|
-
clean: "rm -rf build demo test",
|
|
613
|
-
"build:demo": "rollup -c --environment BUILD:demo",
|
|
614
|
-
"build:dev": "rollup -c --environment BUILD:dev",
|
|
615
|
-
"build:prod": "rollup -c --environment BUILD:prod",
|
|
616
|
-
"build:test": "rollup -c --environment BUILD:test",
|
|
617
|
-
build: "rollup -c",
|
|
618
|
-
lint: "eslint index.js src",
|
|
619
|
-
"test:main": "node test/bundle.js",
|
|
620
|
-
"test:browser": "node test/browser-tests.js",
|
|
621
|
-
test: "npm-run-all test:*",
|
|
622
|
-
prepare: "npm-run-all clean build lint test"
|
|
623
|
-
};
|
|
624
|
-
const dependencies = {
|
|
625
|
-
"d3-hierarchy": "^1.1.5"
|
|
626
|
-
};
|
|
627
|
-
const devDependencies = {
|
|
628
|
-
"babel-plugin-external-helpers": "^6.22.0",
|
|
629
|
-
"babel-preset-es2015-rollup": "^3.0.0",
|
|
630
|
-
d3: "^4.13.0",
|
|
631
|
-
"d3-selection-multi": "^1.0.1",
|
|
632
|
-
eslint: "^4.19.1",
|
|
633
|
-
jsdom: "^11.6.2",
|
|
634
|
-
"npm-run-all": "^4.1.2",
|
|
635
|
-
rollup: "^0.55.3",
|
|
636
|
-
"rollup-plugin-babel": "^2.7.1",
|
|
637
|
-
"rollup-plugin-commonjs": "^8.0.2",
|
|
638
|
-
"rollup-plugin-copy": "^0.2.3",
|
|
639
|
-
"rollup-plugin-json": "^2.3.0",
|
|
640
|
-
"rollup-plugin-node-resolve": "^3.0.2",
|
|
641
|
-
"rollup-plugin-uglify": "^3.0.0",
|
|
642
|
-
"uglify-es": "^3.3.9"
|
|
643
|
-
};
|
|
592
|
+
const repository = { "type": "git", "url": "https://github.com/klortho/d3-flextree.git" };
|
|
593
|
+
const scripts = { "clean": "rm -rf build demo test", "build:demo": "rollup -c --environment BUILD:demo", "build:dev": "rollup -c --environment BUILD:dev", "build:prod": "rollup -c --environment BUILD:prod", "build:test": "rollup -c --environment BUILD:test", "build": "rollup -c", "lint": "eslint index.js src", "test:main": "node test/bundle.js", "test:browser": "node test/browser-tests.js", "test": "npm-run-all test:*", "prepare": "npm-run-all clean build lint test" };
|
|
594
|
+
const dependencies = { "d3-hierarchy": "^1.1.5" };
|
|
595
|
+
const devDependencies = { "babel-plugin-external-helpers": "^6.22.0", "babel-preset-es2015-rollup": "^3.0.0", "d3": "^4.13.0", "d3-selection-multi": "^1.0.1", "eslint": "^4.19.1", "jsdom": "^11.6.2", "npm-run-all": "^4.1.2", "rollup": "^0.55.3", "rollup-plugin-babel": "^2.7.1", "rollup-plugin-commonjs": "^8.0.2", "rollup-plugin-copy": "^0.2.3", "rollup-plugin-json": "^2.3.0", "rollup-plugin-node-resolve": "^3.0.2", "rollup-plugin-uglify": "^3.0.0", "uglify-es": "^3.3.9" };
|
|
644
596
|
const packageInfo = {
|
|
645
597
|
name,
|
|
646
598
|
version: version$1,
|
package/dist/constants.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { IMarkmapOptions } from 'markmap-common';
|
|
2
2
|
export declare const isMacintosh: boolean;
|
|
3
|
-
export declare const defaultColorFn: import("d3
|
|
3
|
+
export declare const defaultColorFn: import("d3").ScaleOrdinal<string, string, never>;
|
|
4
4
|
export declare const defaultOptions: IMarkmapOptions;
|
package/dist/index.js
CHANGED
|
@@ -186,63 +186,15 @@ E.prototype = O.prototype = {
|
|
|
186
186
|
links: Ct,
|
|
187
187
|
copy: wt
|
|
188
188
|
};
|
|
189
|
-
const Mt = "d3-flextree", Bt = "2.1.2", Ot = "build/d3-flextree.js", $t = "index", At = {
|
|
190
|
-
name: "Chris Maloney",
|
|
191
|
-
url: "http://chrismaloney.org"
|
|
192
|
-
}, Dt = "Flexible tree layout algorithm that allows for variable node sizes.", Ft = [
|
|
193
|
-
"d3",
|
|
194
|
-
"d3-module",
|
|
195
|
-
"layout",
|
|
196
|
-
"tree",
|
|
197
|
-
"hierarchy",
|
|
198
|
-
"d3-hierarchy",
|
|
199
|
-
"plugin",
|
|
200
|
-
"d3-plugin",
|
|
201
|
-
"infovis",
|
|
202
|
-
"visualization",
|
|
203
|
-
"2d"
|
|
204
|
-
], Tt = "https://github.com/klortho/d3-flextree", _t = "WTFPL", Ht = {
|
|
205
|
-
type: "git",
|
|
206
|
-
url: "https://github.com/klortho/d3-flextree.git"
|
|
207
|
-
}, Lt = {
|
|
208
|
-
clean: "rm -rf build demo test",
|
|
209
|
-
"build:demo": "rollup -c --environment BUILD:demo",
|
|
210
|
-
"build:dev": "rollup -c --environment BUILD:dev",
|
|
211
|
-
"build:prod": "rollup -c --environment BUILD:prod",
|
|
212
|
-
"build:test": "rollup -c --environment BUILD:test",
|
|
213
|
-
build: "rollup -c",
|
|
214
|
-
lint: "eslint index.js src",
|
|
215
|
-
"test:main": "node test/bundle.js",
|
|
216
|
-
"test:browser": "node test/browser-tests.js",
|
|
217
|
-
test: "npm-run-all test:*",
|
|
218
|
-
prepare: "npm-run-all clean build lint test"
|
|
219
|
-
}, Nt = {
|
|
220
|
-
"d3-hierarchy": "^1.1.5"
|
|
221
|
-
}, Pt = {
|
|
222
|
-
"babel-plugin-external-helpers": "^6.22.0",
|
|
223
|
-
"babel-preset-es2015-rollup": "^3.0.0",
|
|
224
|
-
d3: "^4.13.0",
|
|
225
|
-
"d3-selection-multi": "^1.0.1",
|
|
226
|
-
eslint: "^4.19.1",
|
|
227
|
-
jsdom: "^11.6.2",
|
|
228
|
-
"npm-run-all": "^4.1.2",
|
|
229
|
-
rollup: "^0.55.3",
|
|
230
|
-
"rollup-plugin-babel": "^2.7.1",
|
|
231
|
-
"rollup-plugin-commonjs": "^8.0.2",
|
|
232
|
-
"rollup-plugin-copy": "^0.2.3",
|
|
233
|
-
"rollup-plugin-json": "^2.3.0",
|
|
234
|
-
"rollup-plugin-node-resolve": "^3.0.2",
|
|
235
|
-
"rollup-plugin-uglify": "^3.0.0",
|
|
236
|
-
"uglify-es": "^3.3.9"
|
|
237
|
-
}, Wt = {
|
|
189
|
+
const Mt = "d3-flextree", Bt = "2.1.2", Ot = "build/d3-flextree.js", $t = "index", At = { name: "Chris Maloney", url: "http://chrismaloney.org" }, Ft = "Flexible tree layout algorithm that allows for variable node sizes.", Dt = ["d3", "d3-module", "layout", "tree", "hierarchy", "d3-hierarchy", "plugin", "d3-plugin", "infovis", "visualization", "2d"], Tt = "https://github.com/klortho/d3-flextree", _t = "WTFPL", Ht = { type: "git", url: "https://github.com/klortho/d3-flextree.git" }, Lt = { clean: "rm -rf build demo test", "build:demo": "rollup -c --environment BUILD:demo", "build:dev": "rollup -c --environment BUILD:dev", "build:prod": "rollup -c --environment BUILD:prod", "build:test": "rollup -c --environment BUILD:test", build: "rollup -c", lint: "eslint index.js src", "test:main": "node test/bundle.js", "test:browser": "node test/browser-tests.js", test: "npm-run-all test:*", prepare: "npm-run-all clean build lint test" }, Nt = { "d3-hierarchy": "^1.1.5" }, Pt = { "babel-plugin-external-helpers": "^6.22.0", "babel-preset-es2015-rollup": "^3.0.0", d3: "^4.13.0", "d3-selection-multi": "^1.0.1", eslint: "^4.19.1", jsdom: "^11.6.2", "npm-run-all": "^4.1.2", rollup: "^0.55.3", "rollup-plugin-babel": "^2.7.1", "rollup-plugin-commonjs": "^8.0.2", "rollup-plugin-copy": "^0.2.3", "rollup-plugin-json": "^2.3.0", "rollup-plugin-node-resolve": "^3.0.2", "rollup-plugin-uglify": "^3.0.0", "uglify-es": "^3.3.9" }, Wt = {
|
|
238
190
|
name: Mt,
|
|
239
191
|
version: Bt,
|
|
240
192
|
main: Ot,
|
|
241
193
|
module: $t,
|
|
242
194
|
"jsnext:main": "index",
|
|
243
195
|
author: At,
|
|
244
|
-
description:
|
|
245
|
-
keywords:
|
|
196
|
+
description: Ft,
|
|
197
|
+
keywords: Dt,
|
|
246
198
|
homepage: Tt,
|
|
247
199
|
license: _t,
|
|
248
200
|
repository: Ht,
|
|
@@ -679,12 +631,12 @@ class Y {
|
|
|
679
631
|
const o = (m = this.firstChild) == null ? void 0 : m.firstChild;
|
|
680
632
|
z.unobserve(o);
|
|
681
633
|
});
|
|
682
|
-
const
|
|
634
|
+
const F = C.merge($), Z = c.flatMap(
|
|
683
635
|
(o) => {
|
|
684
636
|
var m;
|
|
685
637
|
return (m = o.payload) != null && m.fold ? [] : o.children.map((y) => ({ source: o, target: y }));
|
|
686
638
|
}
|
|
687
|
-
), w = this.g.selectAll(b("path")).data(Z, (o) => o.target.state.key), q = w.exit(),
|
|
639
|
+
), w = this.g.selectAll(b("path")).data(Z, (o) => o.target.state.key), q = w.exit(), D = w.enter().insert("path", "g").attr("class", "markmap-link").attr("data-depth", (o) => o.target.state.depth).attr("data-path", (o) => o.target.state.path), J = D.merge(w);
|
|
688
640
|
this.svg.style(
|
|
689
641
|
"--markmap-max-width",
|
|
690
642
|
l ? `${l}px` : null
|
|
@@ -703,12 +655,12 @@ class Y {
|
|
|
703
655
|
var m;
|
|
704
656
|
return (m = o.payload) != null && m.fold && o.children ? s(o) : "var(--markmap-circle-open-bg)";
|
|
705
657
|
}
|
|
706
|
-
), this.transition(k).attr("r", 6), this.transition(A).style("opacity", 0),
|
|
658
|
+
), this.transition(k).attr("r", 6), this.transition(A).style("opacity", 0), F.attr("width", (o) => Math.max(0, o.state.rect.width - n * 2)).attr("height", (o) => o.state.rect.height), this.transition(F).style("opacity", 1);
|
|
707
659
|
const S = [
|
|
708
660
|
a.x + a.width,
|
|
709
661
|
a.y + a.height / 2
|
|
710
662
|
];
|
|
711
|
-
this.transition(q).attr("d", M({ source: S, target: S })).remove(),
|
|
663
|
+
this.transition(q).attr("d", M({ source: S, target: S })).remove(), D.attr(
|
|
712
664
|
"d",
|
|
713
665
|
M({ source: S, target: S })
|
|
714
666
|
), this.transition(J).attr("stroke", (o) => s(o.target)).attr("stroke-width", (o) => H(o.target)).attr("d", (o) => {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "markmap-view",
|
|
3
|
-
"version": "0.17.3-beta.
|
|
3
|
+
"version": "0.17.3-beta.4+120a195",
|
|
4
4
|
"description": "View markmaps in browser",
|
|
5
5
|
"author": "Gerald <gera2ld@live.com>",
|
|
6
6
|
"license": "MIT",
|
|
@@ -22,8 +22,8 @@
|
|
|
22
22
|
"clean": "del-cli dist",
|
|
23
23
|
"build:types": "tsc",
|
|
24
24
|
"build:js": "vite build && TARGET=es vite build",
|
|
25
|
-
"build": "
|
|
26
|
-
"prepublishOnly": "
|
|
25
|
+
"build": "pnpm clean && pnpm /^build:/",
|
|
26
|
+
"prepublishOnly": "pnpm build"
|
|
27
27
|
},
|
|
28
28
|
"bugs": {
|
|
29
29
|
"url": "https://github.com/markmap/markmap/issues"
|
|
@@ -46,10 +46,10 @@
|
|
|
46
46
|
},
|
|
47
47
|
"devDependencies": {
|
|
48
48
|
"@types/d3-flextree": "^2.1.1",
|
|
49
|
-
"markmap-common": "0.17.3-beta.
|
|
49
|
+
"markmap-common": "0.17.3-beta.4+120a195"
|
|
50
50
|
},
|
|
51
51
|
"peerDependencies": {
|
|
52
52
|
"markmap-common": "*"
|
|
53
53
|
},
|
|
54
|
-
"gitHead": "
|
|
54
|
+
"gitHead": "120a1954940590e194130156a4c5fb60d82c0b3d"
|
|
55
55
|
}
|