vendor: 24,016 bytes, lines 1-823
1(function (global, factory) { 2 typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) : 3 typeof define === 'function' && define.amd ? define(['exports'], factory) : 4 (factory((global.d3 = global.d3 || {}))); 5}(this, (function (exports) { 'use strict'; 6 7function count(node) { 8 var sum = 0, 9 children = node.children, 10 i = children && children.length; 11 if (!i) sum = 1; 12 else while (--i >= 0) sum += children[i].value; 13 node.value = sum; 14} 15 16function node_count() { 17 return this.eachAfter(count); 18} 19 20function node_each(callback) { 21 var node = this, current, next = [node], children, i, n; 22 do { 23 current = next.reverse(), next = []; 24 while (node = current.pop()) { 25 callback(node), children = node.children; 26 if (children) for (i = 0, n = children.length; i < n; ++i) { 27 next.push(children[i]); 28 } 29 } 30 } while (next.length); 31 return this; 32} 33 34function node_eachBefore(callback) { 35 var node = this, nodes = [node], children, i; 36 while (node = nodes.pop()) { 37 callback(node), children = node.children; 38 if (children) for (i = children.length - 1; i >= 0; --i) { 39 nodes.push(children[i]); 40 } 41 } 42 return this; 43} 44 45function node_eachAfter(callback) { 46 var node = this, nodes = [node], next = [], children, i, n; 47 while (node = nodes.pop()) { 48 next.push(node), children = node.children; 49 if (children) for (i = 0, n = children.length; i < n; ++i) { 50 nodes.push(children[i]); 51 } 52 } 53 while (node = next.pop()) { 54 callback(node); 55 } 56 return this; 57} 58 59function node_sum(value) { 60 return this.eachAfter(function(node) { 61 var sum = +value(node.data) || 0, 62 children = node.children, 63 i = children && children.length; 64 while (--i >= 0) sum += children[i].value; 65 node.value = sum; 66 }); 67} 68 69function node_sort(compare) { 70 return this.eachBefore(function(node) { 71 if (node.children) { 72 node.children.sort(compare); 73 } 74 }); 75} 76 77function node_path(end) { 78 var start = this, 79 ancestor = leastCommonAncestor(start, end), 80 nodes = [start]; 81 while (start !== ancestor) { 82 start = start.parent; 83 nodes.push(start); 84 } 85 var k = nodes.length; 86 while (end !== ancestor) { 87 nodes.splice(k, 0, end); 88 end = end.parent; 89 } 90 return nodes; 91} 92 93function leastCommonAncestor(a, b) { 94 if (a === b) return a; 95 var aNodes = a.ancestors(), 96 bNodes = b.ancestors(), 97 c = null; 98 a = aNodes.pop(); 99 b = bNodes.pop(); 100 while (a === b) { 101 c = a; 102 a = aNodes.pop(); 103 b = bNodes.pop(); 104 } 105 return c; 106} 107 108function node_ancestors() { 109 var node = this, nodes = [node]; 110 while (node = node.parent) { 111 nodes.push(node); 112 } 113 return nodes; 114} 115 116function node_descendants() { 117 var nodes = []; 118 this.each(function(node) { 119 nodes.push(node); 120 }); 121 return nodes; 122} 123 124function node_leaves() { 125 var leaves = []; 126 this.eachBefore(function(node) { 127 if (!node.children) { 128 leaves.push(node); 129 } 130 }); 131 return leaves; 132} 133 134function node_links() { 135 var root = this, links = []; 136 root.each(function(node) { 137 if (node !== root) { // Donââ¬â¢t include the rootââ¬â¢s parent, if any. 138 links.push({source: node.parent, target: node}); 139 } 140 }); 141 return links; 142} 143 144function hierarchy(data, children) { 145 var root = new Node(data), 146 valued = +data.value && (root.value = data.value), 147 node, 148 nodes = [root], 149 child, 150 childs, 151 i, 152 n; 153 154 if (children == null) children = defaultChildren; 155 156 while (node = nodes.pop()) { 157 if (valued) node.value = +node.data.value; 158 if ((childs = children(node.data)) && (n = childs.length)) { 159 node.children = new Array(n); 160 for (i = n - 1; i >= 0; --i) { 161 nodes.push(child = node.children[i] = new Node(childs[i])); 162 child.parent = node; 163 child.depth = node.depth + 1; 164 } 165 } 166 } 167 168 return root.eachBefore(computeHeight); 169} 170 171function node_copy() { 172 return hierarchy(this).eachBefore(copyData); 173} 174 175function defaultChildren(d) { 176 return d.children; 177} 178 179function copyData(node) { 180 node.data = node.data.data; 181} 182 183function computeHeight(node) { 184 var height = 0; 185 do node.height = height; 186 while ((node = node.parent) && (node.height < ++height)); 187} 188 189function Node(data) { 190 this.data = data; 191 this.depth = 192 this.height = 0; 193 this.parent = null; 194} 195 196Node.prototype = hierarchy.prototype = { 197 constructor: Node, 198 count: node_count, 199 each: node_each, 200 eachAfter: node_eachAfter, 201 eachBefore: node_eachBefore, 202 sum: node_sum, 203 sort: node_sort, 204 path: node_path, 205 ancestors: node_ancestors, 206 descendants: node_descendants, 207 leaves: node_leaves, 208 links: node_links, 209 copy: node_copy 210}; 211 212var name = "d3-flextree"; 213var version = "2.1.2"; 214var main = "build/d3-flextree.js"; 215var module$1 = "index"; 216var author = { "name": "Chris Maloney", "url": "https://chrismaloney.org" }; 217var description = "Flexible tree layout algorithm that allows for variable node sizes."; 218var keywords = ["d3", "d3-module", "layout", "tree", "hierarchy", "d3-hierarchy", "plugin", "d3-plugin", "infovis", "visualization", "2d"]; 219var homepage = "https://github.com/klortho/d3-flextree"; 220var license = "WTFPL"; 221var repository = { "type": "git", "url": "https://github.com/klortho/d3-flextree.git" }; 222var 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" }; 223var dependencies = { "d3-hierarchy": "^1.1.5" }; 224var 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" }; 225var packageInfo = { 226 name: name, 227 version: version, 228 main: main, 229 module: module$1, 230 author: author, 231 description: description, 232 keywords: keywords, 233 homepage: homepage, 234 license: license, 235 repository: repository, 236 scripts: scripts, 237 dependencies: dependencies, 238 devDependencies: devDependencies, 239 "jsnext:main": "index" 240}; 241 242var classCallCheck = function (instance, Constructor) { 243 if (!(instance instanceof Constructor)) { 244 throw new TypeError("Cannot call a class as a function"); 245 } 246}; 247 248var createClass = function () { 249 function defineProperties(target, props) { 250 for (var i = 0; i < props.length; i++) { 251 var descriptor = props[i]; 252 descriptor.enumerable = descriptor.enumerable || false; 253 descriptor.configurable = true; 254 if ("value" in descriptor) descriptor.writable = true; 255 Object.defineProperty(target, descriptor.key, descriptor); 256 } 257 } 258 259 return function (Constructor, protoProps, staticProps) { 260 if (protoProps) defineProperties(Constructor.prototype, protoProps); 261 if (staticProps) defineProperties(Constructor, staticProps); 262 return Constructor; 263 }; 264}(); 265 266 267 268 269 270 271 272 273 274var inherits = function (subClass, superClass) { 275 if (typeof superClass !== "function" && superClass !== null) { 276 throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); 277 } 278 279 subClass.prototype = Object.create(superClass && superClass.prototype, { 280 constructor: { 281 value: subClass, 282 enumerable: false, 283 writable: true, 284 configurable: true 285 } 286 }); 287 if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; 288}; 289 290 291 292 293 294 295 296 297 298 299 300var possibleConstructorReturn = function (self, call) { 301 if (!self) { 302 throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); 303 } 304 305 return call && (typeof call === "object" || typeof call === "function") ? call : self; 306}; 307 308 309 310 311 312var slicedToArray = function () { 313 function sliceIterator(arr, i) { 314 var _arr = []; 315 var _n = true; 316 var _d = false; 317 var _e = undefined; 318 319 try { 320 for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { 321 _arr.push(_s.value); 322 323 if (i && _arr.length === i) break; 324 } 325 } catch (err) { 326 _d = true; 327 _e = err; 328 } finally { 329 try { 330 if (!_n && _i["return"]) _i["return"](); 331 } finally { 332 if (_d) throw _e; 333 } 334 } 335 336 return _arr; 337 } 338 339 return function (arr, i) { 340 if (Array.isArray(arr)) { 341 return arr; 342 } else if (Symbol.iterator in Object(arr)) { 343 return sliceIterator(arr, i); 344 } else { 345 throw new TypeError("Invalid attempt to destructure non-iterable instance"); 346 } 347 }; 348}(); 349 350var version$1 = packageInfo.version; 351 352var defaults$1 = Object.freeze({ 353 children: function children(data) { 354 return data.children; 355 }, 356 nodeSize: function nodeSize(node) { 357 return node.data.size; 358 }, 359 spacing: 0 360}); 361 362// Create a layout function with customizable options. Per D3-style, the 363// options can be set at any time using setter methods. The layout function 364// will compute the tree node positions based on the options in effect at the 365// time it is called. 366function flextree(options) { 367 var opts = Object.assign({}, defaults$1, options); 368 function accessor(name$$1) { 369 var opt = opts[name$$1]; 370 return typeof opt === 'function' ? opt : function () { 371 return opt; 372 }; 373 } 374 375 function layout(tree) { 376 var wtree = wrap(getWrapper(), tree, function (node) { 377 return node.children; 378 }); 379 wtree.update(); 380 return wtree.data; 381 } 382 383 function getFlexNode() { 384 var nodeSize = accessor('nodeSize'); 385 var _spacing = accessor('spacing'); 386 return function (_hierarchy$prototype$) { 387 inherits(FlexNode, _hierarchy$prototype$); 388 389 function FlexNode(data) { 390 classCallCheck(this, FlexNode); 391 return possibleConstructorReturn(this, (FlexNode.__proto__ || Object.getPrototypeOf(FlexNode)).call(this, data)); 392 } 393 394 createClass(FlexNode, [{ 395 key: 'copy', 396 value: function copy() { 397 var c = wrap(this.constructor, this, function (node) { 398 return node.children; 399 }); 400 c.each(function (node) { 401 return node.data = node.data.data; 402 }); 403 return c; 404 } 405 }, { 406 key: 'spacing', 407 value: function spacing(oNode) { 408 return _spacing(this, oNode); 409 } 410 }, { 411 key: 'size', 412 get: function get$$1() { 413 return nodeSize(this); 414 } 415 }, { 416 key: 'nodes', 417 get: function get$$1() { 418 return this.descendants(); 419 } 420 }, { 421 key: 'xSize', 422 get: function get$$1() { 423 return this.size[0]; 424 } 425 }, { 426 key: 'ySize', 427 get: function get$$1() { 428 return this.size[1]; 429 } 430 }, { 431 key: 'top', 432 get: function get$$1() { 433 return this.y; 434 } 435 }, { 436 key: 'bottom', 437 get: function get$$1() { 438 return this.y + this.ySize; 439 } 440 }, { 441 key: 'left', 442 get: function get$$1() { 443 return this.x - this.xSize / 2; 444 } 445 }, { 446 key: 'right', 447 get: function get$$1() { 448 return this.x + this.xSize / 2; 449 } 450 }, { 451 key: 'root', 452 get: function get$$1() { 453 var ancs = this.ancestors(); 454 return ancs[ancs.length - 1]; 455 } 456 }, { 457 key: 'numChildren', 458 get: function get$$1() { 459 return this.hasChildren ? this.children.length : 0; 460 } 461 }, { 462 key: 'hasChildren', 463 get: function get$$1() { 464 return !this.noChildren; 465 } 466 }, { 467 key: 'noChildren', 468 get: function get$$1() { 469 return this.children === null; 470 } 471 }, { 472 key: 'firstChild', 473 get: function get$$1() { 474 return this.hasChildren ? this.children[0] : null; 475 } 476 }, { 477 key: 'lastChild', 478 get: function get$$1() { 479 return this.hasChildren ? this.children[this.numChildren - 1] : null; 480 } 481 }, { 482 key: 'extents', 483 get: function get$$1() { 484 return (this.children || []).reduce(function (acc, kid) { 485 return FlexNode.maxExtents(acc, kid.extents); 486 }, this.nodeExtents); 487 } 488 }, { 489 key: 'nodeExtents', 490 get: function get$$1() { 491 return { 492 top: this.top, 493 bottom: this.bottom, 494 left: this.left, 495 right: this.right 496 }; 497 } 498 }], [{ 499 key: 'maxExtents', 500 value: function maxExtents(e0, e1) { 501 return { 502 top: Math.min(e0.top, e1.top), 503 bottom: Math.max(e0.bottom, e1.bottom), 504 left: Math.min(e0.left, e1.left), 505 right: Math.max(e0.right, e1.right) 506 }; 507 } 508 }]); 509 return FlexNode; 510 }(hierarchy.prototype.constructor); 511 } 512 513 function getWrapper() { 514 var FlexNode = getFlexNode(); 515 var nodeSize = accessor('nodeSize'); 516 var _spacing2 = accessor('spacing'); 517 return function (_FlexNode) { 518 inherits(_class, _FlexNode); 519 520 function _class(data) { 521 classCallCheck(this, _class); 522 523 var _this2 = possibleConstructorReturn(this, (_class.__proto__ || Object.getPrototypeOf(_class)).call(this, data)); 524 525 Object.assign(_this2, { 526 x: 0, y: 0, 527 relX: 0, prelim: 0, shift: 0, change: 0, 528 lExt: _this2, lExtRelX: 0, lThr: null, 529 rExt: _this2, rExtRelX: 0, rThr: null 530 }); 531 return _this2; 532 } 533 534 createClass(_class, [{ 535 key: 'spacing', 536 value: function spacing(oNode) { 537 return _spacing2(this.data, oNode.data); 538 } 539 }, { 540 key: 'update', 541 value: function update() { 542 layoutChildren(this); 543 resolveX(this); 544 return this; 545 } 546 }, { 547 key: 'size', 548 get: function get$$1() { 549 return nodeSize(this.data); 550 } 551 }, { 552 key: 'x', 553 get: function get$$1() { 554 return this.data.x; 555 }, 556 set: function set$$1(v) { 557 this.data.x = v; 558 } 559 }, { 560 key: 'y', 561 get: function get$$1() { 562 return this.data.y; 563 }, 564 set: function set$$1(v) { 565 this.data.y = v; 566 } 567 }]); 568 return _class; 569 }(FlexNode); 570 } 571 572 function wrap(FlexClass, treeData, children) { 573 var _wrap = function _wrap(data, parent) { 574 var node = new FlexClass(data); 575 Object.assign(node, { 576 parent: parent, 577 depth: parent === null ? 0 : parent.depth + 1, 578 height: 0, 579 length: 1 580 }); 581 var kidsData = children(data) || []; 582 node.children = kidsData.length === 0 ? null : kidsData.map(function (kd) { 583 return _wrap(kd, node); 584 }); 585 if (node.children) { 586 Object.assign(node, node.children.reduce(function (hl, kid) { 587 return { 588 height: Math.max(hl.height, kid.height + 1), 589 length: hl.length + kid.length 590 }; 591 }, node)); 592 } 593 return node; 594 }; 595 return _wrap(treeData, null); 596 } 597 598 Object.assign(layout, { 599 nodeSize: function nodeSize(arg) { 600 return arguments.length ? (opts.nodeSize = arg, layout) : opts.nodeSize; 601 }, 602 spacing: function spacing(arg) { 603 return arguments.length ? (opts.spacing = arg, layout) : opts.spacing; 604 }, 605 children: function children(arg) { 606 return arguments.length ? (opts.children = arg, layout) : opts.children; 607 }, 608 hierarchy: function hierarchy(treeData, children) { 609 var kids = typeof children === 'undefined' ? opts.children : children; 610 return wrap(getFlexNode(), treeData, kids); 611 }, 612 dump: function dump(tree) { 613 var nodeSize = accessor('nodeSize'); 614 var _dump = function _dump(i0) { 615 return function (node) { 616 var i1 = i0 + ' '; 617 var i2 = i0 + ' '; 618 var x = node.x, 619 y = node.y; 620 621 var size = nodeSize(node); 622 var kids = node.children || []; 623 var kdumps = kids.length === 0 ? ' ' : ',' + i1 + 'children: [' + i2 + kids.map(_dump(i2)).join(i2) + i1 + '],' + i0; 624 return '{ size: [' + size.join(', ') + '],' + i1 + 'x: ' + x + ', y: ' + y + kdumps + '},'; 625 }; 626 }; 627 return _dump('\n')(tree); 628 } 629 }); 630 return layout; 631} 632flextree.version = version$1; 633 634var layoutChildren = function layoutChildren(w) { 635 var y = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0; 636 637 w.y = y; 638 (w.children || []).reduce(function (acc, kid) { 639 var _acc = slicedToArray(acc, 2), 640 i = _acc[0], 641 lastLows = _acc[1]; 642 643 layoutChildren(kid, w.y + w.ySize); 644 // The lowest vertical coordinate while extreme nodes still point 645 // in current subtree. 646 var lowY = (i === 0 ? kid.lExt : kid.rExt).bottom; 647 if (i !== 0) separate(w, i, lastLows); 648 var lows = updateLows(lowY, i, lastLows); 649 return [i + 1, lows]; 650 }, [0, null]); 651 shiftChange(w); 652 positionRoot(w); 653 return w; 654}; 655 656// Resolves the relative coordinate properties - relX and prelim -- 657// to set the final, absolute x coordinate for each node. This also sets 658// `prelim` to 0, so that `relX` for each node is its x-coordinate relative 659// to its parent. 660var resolveX = function resolveX(w, prevSum, parentX) { 661 // A call to resolveX without arguments is assumed to be for the root of 662 // the tree. This will set the root's x-coord to zero. 663 if (typeof prevSum === 'undefined') { 664 prevSum = -w.relX - w.prelim; 665 parentX = 0; 666 } 667 var sum = prevSum + w.relX; 668 w.relX = sum + w.prelim - parentX; 669 w.prelim = 0; 670 w.x = parentX + w.relX; 671 (w.children || []).forEach(function (k) { 672 return resolveX(k, sum, w.x); 673 }); 674 return w; 675}; 676 677// Process shift and change for all children, to add intermediate spacing to 678// each child's modifier. 679var shiftChange = function shiftChange(w) { 680 (w.children || []).reduce(function (acc, child) { 681 var _acc2 = slicedToArray(acc, 2), 682 lastShiftSum = _acc2[0], 683 lastChangeSum = _acc2[1]; 684 685 var shiftSum = lastShiftSum + child.shift; 686 var changeSum = lastChangeSum + shiftSum + child.change; 687 child.relX += changeSum; 688 return [shiftSum, changeSum]; 689 }, [0, 0]); 690}; 691 692// Separates the latest child from its previous sibling 693/* eslint-disable complexity */ 694var separate = function separate(w, i, lows) { 695 var lSib = w.children[i - 1]; 696 var curSubtree = w.children[i]; 697 var rContour = lSib; 698 var rSumMods = lSib.relX; 699 var lContour = curSubtree; 700 var lSumMods = curSubtree.relX; 701 var isFirst = true; 702 while (rContour && lContour) { 703 if (rContour.bottom > lows.lowY) lows = lows.next; 704 // How far to the left of the right side of rContour is the left side 705 // of lContour? First compute the center-to-center distance, then add 706 // the "spacing" 707 var dist = rSumMods + rContour.prelim - (lSumMods + lContour.prelim) + rContour.xSize / 2 + lContour.xSize / 2 + rContour.spacing(lContour); 708 if (dist > 0 || dist < 0 && isFirst) { 709 lSumMods += dist; 710 // Move subtree by changing relX. 711 moveSubtree$1(curSubtree, dist); 712 distributeExtra(w, i, lows.index, dist); 713 } 714 isFirst = false; 715 // Advance highest node(s) and sum(s) of modifiers 716 var rightBottom = rContour.bottom; 717 var leftBottom = lContour.bottom; 718 if (rightBottom <= leftBottom) { 719 rContour = nextRContour(rContour); 720 if (rContour) rSumMods += rContour.relX; 721 } 722 if (rightBottom >= leftBottom) { 723 lContour = nextLContour(lContour); 724 if (lContour) lSumMods += lContour.relX; 725 } 726 } 727 // Set threads and update extreme nodes. In the first case, the 728 // current subtree is taller than the left siblings. 729 if (!rContour && lContour) setLThr(w, i, lContour, lSumMods); 730 // In the next case, the left siblings are taller than the current subtree 731 else if (rContour && !lContour) setRThr(w, i, rContour, rSumMods); 732}; 733/* eslint-enable complexity */ 734 735// Move subtree by changing relX. 736var moveSubtree$1 = function moveSubtree(subtree, distance) { 737 subtree.relX += distance; 738 subtree.lExtRelX += distance; 739 subtree.rExtRelX += distance; 740}; 741 742var distributeExtra = function distributeExtra(w, curSubtreeI, leftSibI, dist) { 743 var curSubtree = w.children[curSubtreeI]; 744 var n = curSubtreeI - leftSibI; 745 // Are there intermediate children? 746 if (n > 1) { 747 var delta = dist / n; 748 w.children[leftSibI + 1].shift += delta; 749 curSubtree.shift -= delta; 750 curSubtree.change -= dist - delta; 751 } 752}; 753 754var nextLContour = function nextLContour(w) { 755 return w.hasChildren ? w.firstChild : w.lThr; 756}; 757 758var nextRContour = function nextRContour(w) { 759 return w.hasChildren ? w.lastChild : w.rThr; 760}; 761 762var setLThr = function setLThr(w, i, lContour, lSumMods) { 763 var firstChild = w.firstChild; 764 var lExt = firstChild.lExt; 765 var curSubtree = w.children[i]; 766 lExt.lThr = lContour; 767 // Change relX so that the sum of modifier after following thread is correct. 768 var diff = lSumMods - lContour.relX - firstChild.lExtRelX; 769 lExt.relX += diff; 770 // Change preliminary x coordinate so that the node does not move. 771 lExt.prelim -= diff; 772 // Update extreme node and its sum of modifiers. 773 firstChild.lExt = curSubtree.lExt; 774 firstChild.lExtRelX = curSubtree.lExtRelX; 775}; 776 777// Mirror image of setLThr. 778var setRThr = function setRThr(w, i, rContour, rSumMods) { 779 var curSubtree = w.children[i]; 780 var rExt = curSubtree.rExt; 781 var lSib = w.children[i - 1]; 782 rExt.rThr = rContour; 783 var diff = rSumMods - rContour.relX - curSubtree.rExtRelX; 784 rExt.relX += diff; 785 rExt.prelim -= diff; 786 curSubtree.rExt = lSib.rExt; 787 curSubtree.rExtRelX = lSib.rExtRelX; 788}; 789 790// Position root between children, taking into account their modifiers 791var positionRoot = function positionRoot(w) { 792 if (w.hasChildren) { 793 var k0 = w.firstChild; 794 var kf = w.lastChild; 795 var prelim = (k0.prelim + k0.relX - k0.xSize / 2 + kf.relX + kf.prelim + kf.xSize / 2) / 2; 796 Object.assign(w, { 797 prelim: prelim, 798 lExt: k0.lExt, lExtRelX: k0.lExtRelX, 799 rExt: kf.rExt, rExtRelX: kf.rExtRelX 800 }); 801 } 802}; 803 804// Make/maintain a linked list of the indexes of left siblings and their 805// lowest vertical coordinate. 806var updateLows = function updateLows(lowY, index, lastLows) { 807 // Remove siblings that are hidden by the new subtree. 808 while (lastLows !== null && lowY >= lastLows.lowY) { 809 lastLows = lastLows.next; 810 } // Prepend the new subtree. 811 return { 812 lowY: lowY, 813 index: index, 814 next: lastLows 815 }; 816}; 817 818exports.flextree = flextree; 819 820Object.defineProperty(exports, '__esModule', { value: true }); 821 822}))); 823//# sourceMappingURL=d3-flextree.js.map
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.