-
Notifications
You must be signed in to change notification settings - Fork 11
/
chunk-FVMS7RCB.js
4 lines (4 loc) · 106 KB
/
chunk-FVMS7RCB.js
1
2
3
4
import{a as hn,b as pn}from"./chunk-JU572LED.js";import{a as fn}from"./chunk-DWJLHIXK.js";import{f as $e,g as mn,h as un,k as Ge}from"./chunk-RKL5WCT5.js";import"./chunk-MGFBB5Y4.js";import{a as an,b as dn,d as sn}from"./chunk-HVFPNQ3B.js";import{a as ln}from"./chunk-6AJOFIIP.js";import"./chunk-3LAVY7RV.js";import{a as ce,g as Qe,h as Ue,j as qe}from"./chunk-Q4ISATUO.js";import"./chunk-JXWNPNAC.js";import{Ca as D,Ea as I,Eb as Re,Fa as ye,Fc as Ke,Hc as je,Ia as Jt,Ic as We,Ja as en,Ka as q,La as tn,Lc as Ze,Pa as Ct,Qa as nn,Sb as ve,_a as Le,ab as rn,ec as Oe,ia as vt,kc as cn,oc as Pe,sb as on,sc as He}from"./chunk-YWVGY2C2.js";import{$ as pt,Aa as _,Ac as J,Ba as w,Bc as Z,C as Te,Ca as y,Cc as Q,E as mt,F as Ie,Fa as xe,Gc as Me,Hc as i,I as ut,Ib as z,J as ht,Jb as xt,Jc as T,Kb as B,La as Ee,Ma as zt,Mb as ne,Mc as Ut,N as ue,Nc as qt,Ob as Y,Oc as Xt,P as At,Pb as E,Pc as U,Q as Lt,Qa as de,Vb as Ht,Vc as St,Wb as m,Yb as ie,Zc as _t,_c as Yt,aa as De,ba as te,da as he,dc as pe,ed as se,f as le,fc as Kt,fd as Ae,g as O,gc as $t,ha as W,hc as Gt,i as Bt,ic as t,id as G,j as It,ja as ft,jc as n,jd as _e,k as Vt,kc as u,la as Rt,lb as gt,lc as jt,mc as Wt,nc as we,o as N,oa as v,oc as P,pc as Zt,q as Mt,rb as c,rc as g,s as k,sb as C,t as ge,tc as f,ub as Ot,uc as Et,vc as Se,w as ct,xb as Pt,ya as Ve,yb as Ne,za as S,zc as Qt}from"./chunk-GBKJFEQZ.js";import{a as Fe,b as Be}from"./chunk-EQDQRRRY.js";var Tt=class{dataNodes;expansionModel=new q(!0);trackBy;getLevel;isExpandable;getChildren;toggle(d){this.expansionModel.toggle(this._trackByValue(d))}expand(d){this.expansionModel.select(this._trackByValue(d))}collapse(d){this.expansionModel.deselect(this._trackByValue(d))}isExpanded(d){return this.expansionModel.isSelected(this._trackByValue(d))}toggleDescendants(d){this.expansionModel.isSelected(this._trackByValue(d))?this.collapseDescendants(d):this.expandDescendants(d)}collapseAll(){this.expansionModel.clear()}expandDescendants(d){let e=[d];e.push(...this.getDescendants(d)),this.expansionModel.select(...e.map(r=>this._trackByValue(r)))}collapseDescendants(d){let e=[d];e.push(...this.getDescendants(d)),this.expansionModel.deselect(...e.map(r=>this._trackByValue(r)))}_trackByValue(d){return this.trackBy?this.trackBy(d):d}},b=class extends Tt{getLevel;isExpandable;options;constructor(d,e,r){super(),this.getLevel=d,this.isExpandable=e,this.options=r,this.options&&(this.trackBy=this.options.trackBy)}getDescendants(d){let e=this.dataNodes.indexOf(d),r=[];for(let o=e+1;o<this.dataNodes.length&&this.getLevel(d)<this.getLevel(this.dataNodes[o]);o++)r.push(this.dataNodes[o]);return r}expandAll(){this.expansionModel.select(...this.dataNodes.map(d=>this._trackByValue(d)))}};var Dt=new Rt("CDK_TREE_NODE_OUTLET_NODE"),Xe=(()=>{class a{viewContainer=v(Ne);_node=v(Dt,{optional:!0});constructor(){}static \u0275fac=function(r){return new(r||a)};static \u0275dir=B({type:a,selectors:[["","cdkTreeNodeOutlet",""]]})}return a})(),be=class{$implicit;level;index;count;constructor(d){this.$implicit=d}},Ye=(()=>{class a{template=v(Ot);when;constructor(){}static \u0275fac=function(r){return new(r||a)};static \u0275dir=B({type:a,selectors:[["","cdkTreeNodeDef",""]],inputs:{when:[0,"cdkTreeNodeDefWhen","when"]}})}return a})();function zn(){return Error("Could not find a tree control, levelAccessor, or childrenAccessor for the tree.")}var fe=(()=>{class a{_differs=v(Ae);_changeDetectorRef=v(se);_elementRef=v(de);_dir=v(ye);_onDestroy=new le;_dataDiffer;_defaultNodeDef;_dataSubscription;_levels=new Map;_parents=new Map;_ariaSets=new Map;get dataSource(){return this._dataSource}set dataSource(e){this._dataSource!==e&&this._switchDataSource(e)}_dataSource;treeControl;levelAccessor;childrenAccessor;trackBy;expansionKey;_nodeOutlet;_nodeDefs;viewChange=new O({start:0,end:Number.MAX_VALUE});_expansionModel;_flattenedNodes=new O([]);_nodeType=new O(null);_nodes=new O(new Map);_keyManagerNodes=new O([]);_keyManagerFactory=v(rn);_keyManager;_viewInit=!1;constructor(){}ngAfterContentInit(){this._initializeKeyManager()}ngAfterContentChecked(){this._updateDefaultNodeDefinition(),this._subscribeToDataChanges()}ngOnDestroy(){this._nodeOutlet.viewContainer.clear(),this.viewChange.complete(),this._onDestroy.next(),this._onDestroy.complete(),this._dataSource&&typeof this._dataSource.disconnect=="function"&&this.dataSource.disconnect(this),this._dataSubscription&&(this._dataSubscription.unsubscribe(),this._dataSubscription=null),this._keyManager?.destroy()}ngOnInit(){this._checkTreeControlUsage(),this._initializeDataDiffer()}ngAfterViewInit(){this._viewInit=!0}_updateDefaultNodeDefinition(){let e=this._nodeDefs.filter(r=>!r.when);e.length>1,this._defaultNodeDef=e[0]}_setNodeTypeIfUnset(e){this._nodeType.value===null&&this._nodeType.next(e)}_switchDataSource(e){this._dataSource&&typeof this._dataSource.disconnect=="function"&&this.dataSource.disconnect(this),this._dataSubscription&&(this._dataSubscription.unsubscribe(),this._dataSubscription=null),e||this._nodeOutlet.viewContainer.clear(),this._dataSource=e,this._nodeDefs&&this._subscribeToDataChanges()}_getExpansionModel(){return this.treeControl?this.treeControl.expansionModel:(this._expansionModel??=new q(!0),this._expansionModel)}_subscribeToDataChanges(){if(this._dataSubscription)return;let e;en(this._dataSource)?e=this._dataSource.connect(this):Mt(this._dataSource)?e=this._dataSource:Array.isArray(this._dataSource)&&(e=N(this._dataSource)),e&&(this._dataSubscription=this._getRenderData(e).pipe(te(this._onDestroy)).subscribe(r=>{this._renderDataChanges(r)}))}_getRenderData(e){let r=this._getExpansionModel();return ge([e,this._nodeType,r.changed.pipe(pt(null),he(o=>{this._emitExpansionChanges(o)}))]).pipe(De(([o,l])=>l===null?N({renderNodes:o,flattenedNodes:null,nodeType:l}):this._computeRenderingData(o,l).pipe(k(s=>Be(Fe({},s),{nodeType:l})))))}_renderDataChanges(e){if(e.nodeType===null){this.renderNodeChanges(e.renderNodes);return}this._updateCachedData(e.flattenedNodes),this.renderNodeChanges(e.renderNodes),this._updateKeyManagerItems(e.flattenedNodes)}_emitExpansionChanges(e){if(!e)return;let r=this._nodes.value;for(let o of e.added)r.get(o)?._emitExpansionState(!0);for(let o of e.removed)r.get(o)?._emitExpansionState(!1)}_initializeKeyManager(){let e=ge([this._keyManagerNodes,this._nodes]).pipe(k(([o,l])=>o.reduce((s,h)=>{let p=l.get(this._getExpansionKey(h));return p&&s.push(p),s},[]))),r={trackBy:o=>this._getExpansionKey(o.data),skipPredicate:o=>!!o.isDisabled,typeAheadDebounceInterval:!0,horizontalOrientation:this._dir.value};this._keyManager=this._keyManagerFactory(e,r)}_initializeDataDiffer(){let e=this.trackBy??((r,o)=>this._getExpansionKey(o));this._dataDiffer=this._differs.find([]).create(e)}_checkTreeControlUsage(){}renderNodeChanges(e,r=this._dataDiffer,o=this._nodeOutlet.viewContainer,l){let s=r.diff(e);!s&&!this._viewInit||(s?.forEachOperation((h,p,x)=>{if(h.previousIndex==null)this.insertNode(e[x],x,o,l);else if(x==null)o.remove(p);else{let ae=o.get(p);o.move(ae,x)}}),s?.forEachIdentityChange(h=>{let p=h.item;if(h.currentIndex!=null){let x=o.get(h.currentIndex);x.context.$implicit=p}}),l?this._changeDetectorRef.markForCheck():this._changeDetectorRef.detectChanges())}_getNodeDef(e,r){if(this._nodeDefs.length===1)return this._nodeDefs.first;let o=this._nodeDefs.find(l=>l.when&&l.when(r,e))||this._defaultNodeDef;return o}insertNode(e,r,o,l){let s=this._getLevelAccessor(),h=this._getNodeDef(e,r),p=this._getExpansionKey(e),x=new be(e);l??=this._parents.get(p)??void 0,s?x.level=s(e):l!==void 0&&this._levels.has(this._getExpansionKey(l))?x.level=this._levels.get(this._getExpansionKey(l))+1:x.level=0,this._levels.set(p,x.level),(o||this._nodeOutlet.viewContainer).createEmbeddedView(h.template,x,r),re.mostRecentTreeNode&&(re.mostRecentTreeNode.data=e)}isExpanded(e){return!!(this.treeControl?.isExpanded(e)||this._expansionModel?.isSelected(this._getExpansionKey(e)))}toggle(e){this.treeControl?this.treeControl.toggle(e):this._expansionModel&&this._expansionModel.toggle(this._getExpansionKey(e))}expand(e){this.treeControl?this.treeControl.expand(e):this._expansionModel&&this._expansionModel.select(this._getExpansionKey(e))}collapse(e){this.treeControl?this.treeControl.collapse(e):this._expansionModel&&this._expansionModel.deselect(this._getExpansionKey(e))}toggleDescendants(e){this.treeControl?this.treeControl.toggleDescendants(e):this._expansionModel&&(this.isExpanded(e)?this.collapseDescendants(e):this.expandDescendants(e))}expandDescendants(e){if(this.treeControl)this.treeControl.expandDescendants(e);else if(this._expansionModel){let r=this._expansionModel;r.select(this._getExpansionKey(e)),this._getDescendants(e).pipe(ue(1),te(this._onDestroy)).subscribe(o=>{r.select(...o.map(l=>this._getExpansionKey(l)))})}}collapseDescendants(e){if(this.treeControl)this.treeControl.collapseDescendants(e);else if(this._expansionModel){let r=this._expansionModel;r.deselect(this._getExpansionKey(e)),this._getDescendants(e).pipe(ue(1),te(this._onDestroy)).subscribe(o=>{r.deselect(...o.map(l=>this._getExpansionKey(l)))})}}expandAll(){this.treeControl?this.treeControl.expandAll():this._expansionModel&&this._expansionModel.select(...this._flattenedNodes.value.map(r=>this._getExpansionKey(r)))}collapseAll(){this.treeControl?this.treeControl.collapseAll():this._expansionModel&&this._expansionModel.deselect(...this._flattenedNodes.value.map(r=>this._getExpansionKey(r)))}_getLevelAccessor(){return this.treeControl?.getLevel?.bind(this.treeControl)??this.levelAccessor}_getChildrenAccessor(){return this.treeControl?.getChildren?.bind(this.treeControl)??this.childrenAccessor}_getDirectChildren(e){let r=this._getLevelAccessor(),o=this._expansionModel??this.treeControl?.expansionModel;if(!o)return N([]);let l=this._getExpansionKey(e),s=o.changed.pipe(De(p=>p.added.includes(l)?N(!0):p.removed.includes(l)?N(!1):Vt),pt(this.isExpanded(e)));if(r)return ge([s,this._flattenedNodes]).pipe(k(([p,x])=>p?this._findChildrenByLevel(r,x,e,1):[]));let h=this._getChildrenAccessor();if(h)return Le(h(e)??[]);throw zn()}_findChildrenByLevel(e,r,o,l){let s=this._getExpansionKey(o),h=r.findIndex(ze=>this._getExpansionKey(ze)===s),p=e(o),x=p+l,ae=[];for(let ze=h+1;ze<r.length;ze++){let Ft=e(r[ze]);if(Ft<=p)break;Ft<=x&&ae.push(r[ze])}return ae}_registerNode(e){this._nodes.value.set(this._getExpansionKey(e.data),e),this._nodes.next(this._nodes.value)}_unregisterNode(e){this._nodes.value.delete(this._getExpansionKey(e.data)),this._nodes.next(this._nodes.value)}_getLevel(e){return this._levels.get(this._getExpansionKey(e))}_getSetSize(e){return this._getAriaSet(e).length}_getPositionInSet(e){let r=this._getAriaSet(e),o=this._getExpansionKey(e);return r.findIndex(l=>this._getExpansionKey(l)===o)+1}_getNodeParent(e){let r=this._parents.get(this._getExpansionKey(e.data));return r&&this._nodes.value.get(this._getExpansionKey(r))}_getNodeChildren(e){return this._getDirectChildren(e.data).pipe(k(r=>r.reduce((o,l)=>{let s=this._nodes.value.get(this._getExpansionKey(l));return s&&o.push(s),o},[])))}_sendKeydownToKeyManager(e){if(e.target===this._elementRef.nativeElement)this._keyManager.onKeydown(e);else{let r=this._nodes.getValue();for(let[,o]of r)if(e.target===o._elementRef.nativeElement){this._keyManager.onKeydown(e);break}}}_getDescendants(e){if(this.treeControl)return N(this.treeControl.getDescendants(e));if(this.levelAccessor){let r=this._findChildrenByLevel(this.levelAccessor,this._flattenedNodes.value,e,1/0);return N(r)}if(this.childrenAccessor)return this._getAllChildrenRecursively(e).pipe(ut((r,o)=>(r.push(...o),r),[]));throw zn()}_getAllChildrenRecursively(e){return this.childrenAccessor?Le(this.childrenAccessor(e)).pipe(ue(1),De(r=>{for(let o of r)this._parents.set(this._getExpansionKey(o),e);return N(...r).pipe(ht(o=>ct(N([o]),this._getAllChildrenRecursively(o))))})):N([])}_getExpansionKey(e){return this.expansionKey?.(e)??e}_getAriaSet(e){let r=this._getExpansionKey(e),o=this._parents.get(r),l=o?this._getExpansionKey(o):null;return this._ariaSets.get(l)??[e]}_findParentForNode(e,r,o){if(!o.length)return null;let l=this._levels.get(this._getExpansionKey(e))??0;for(let s=r-1;s>=0;s--){let h=o[s];if((this._levels.get(this._getExpansionKey(h))??0)<l)return h}return null}_flattenNestedNodesWithExpansion(e,r=0){let o=this._getChildrenAccessor();return o?N(...e).pipe(ht(l=>{let s=this._getExpansionKey(l);this._parents.has(s)||this._parents.set(s,null),this._levels.set(s,r);let h=Le(o(l));return ct(N([l]),h.pipe(ue(1),he(p=>{this._ariaSets.set(s,[...p??[]]);for(let x of p??[]){let ae=this._getExpansionKey(x);this._parents.set(ae,l),this._levels.set(ae,r+1)}}),De(p=>p?this._flattenNestedNodesWithExpansion(p,r+1).pipe(k(x=>this.isExpanded(l)?x:[])):N([]))))}),ut((l,s)=>(l.push(...s),l),[])):N([...e])}_computeRenderingData(e,r){if(this.childrenAccessor&&r==="flat")return this._ariaSets.set(null,[...e]),this._flattenNestedNodesWithExpansion(e).pipe(k(o=>({renderNodes:o,flattenedNodes:o})));if(this.levelAccessor&&r==="nested"){let o=this.levelAccessor;return N(e.filter(l=>o(l)===0)).pipe(k(l=>({renderNodes:l,flattenedNodes:e})),he(({flattenedNodes:l})=>{this._calculateParents(l)}))}else return r==="flat"?N({renderNodes:e,flattenedNodes:e}).pipe(he(({flattenedNodes:o})=>{this._calculateParents(o)})):(this._ariaSets.set(null,[...e]),this._flattenNestedNodesWithExpansion(e).pipe(k(o=>({renderNodes:e,flattenedNodes:o}))))}_updateCachedData(e){this._flattenedNodes.next(e)}_updateKeyManagerItems(e){this._keyManagerNodes.next(e)}_calculateParents(e){let r=this._getLevelAccessor();if(r){this._parents.clear(),this._ariaSets.clear();for(let o=0;o<e.length;o++){let l=e[o],s=this._getExpansionKey(l);this._levels.set(s,r(l));let h=this._findParentForNode(l,o,e);this._parents.set(s,h);let p=h?this._getExpansionKey(h):null,x=this._ariaSets.get(p)??[];x.splice(o,0,l),this._ariaSets.set(p,x)}}}static \u0275fac=function(r){return new(r||a)};static \u0275cmp=z({type:a,selectors:[["cdk-tree"]],contentQueries:function(r,o,l){if(r&1&&Qt(l,Ye,5),r&2){let s;Z(s=Q())&&(o._nodeDefs=s)}},viewQuery:function(r,o){if(r&1&&J(Xe,7),r&2){let l;Z(l=Q())&&(o._nodeOutlet=l.first)}},hostAttrs:["role","tree",1,"cdk-tree"],hostBindings:function(r,o){r&1&&g("keydown",function(s){return o._sendKeydownToKeyManager(s)})},inputs:{dataSource:"dataSource",treeControl:"treeControl",levelAccessor:"levelAccessor",childrenAccessor:"childrenAccessor",trackBy:"trackBy",expansionKey:"expansionKey"},exportAs:["cdkTree"],decls:1,vars:0,consts:[["cdkTreeNodeOutlet",""]],template:function(r,o){r&1&&we(0,0)},dependencies:[Xe],encapsulation:2})}return a})(),re=(()=>{class a{_elementRef=v(de);_tree=v(fe);_tabindex=-1;_type="flat";get role(){return"treeitem"}set role(e){}get isExpandable(){return this._isExpandable()}set isExpandable(e){this._inputIsExpandable=e,!(this.data&&!this._isExpandable||!this._inputIsExpandable)&&(this._inputIsExpanded?this.expand():this._inputIsExpanded===!1&&this.collapse())}get isExpanded(){return this._tree.isExpanded(this._data)}set isExpanded(e){this._inputIsExpanded=e,e?this.expand():this.collapse()}isDisabled;typeaheadLabel;getLabel(){return this.typeaheadLabel||this._elementRef.nativeElement.textContent?.trim()||""}activation=new Ee;expandedChange=new Ee;static mostRecentTreeNode=null;_destroyed=new le;_dataChanges=new le;_inputIsExpandable=!1;_inputIsExpanded=void 0;_shouldFocus=!0;_parentNodeAriaLevel;get data(){return this._data}set data(e){e!==this._data&&(this._data=e,this._dataChanges.next())}_data;get isLeafNode(){return this._tree.treeControl?.isExpandable!==void 0&&!this._tree.treeControl.isExpandable(this._data)?!0:this._tree.treeControl?.isExpandable===void 0&&this._tree.treeControl?.getDescendants(this._data).length===0}get level(){return this._tree._getLevel(this._data)??this._parentNodeAriaLevel}_isExpandable(){return this._tree.treeControl?!this.isLeafNode:this._inputIsExpandable}_getAriaExpanded(){return this._isExpandable()?String(this.isExpanded):null}_getSetSize(){return this._tree._getSetSize(this._data)}_getPositionInSet(){return this._tree._getPositionInSet(this._data)}_changeDetectorRef=v(se);constructor(){a.mostRecentTreeNode=this}ngOnInit(){this._parentNodeAriaLevel=Tn(this._elementRef.nativeElement),this._tree._getExpansionModel().changed.pipe(k(()=>this.isExpanded),Lt()).subscribe(()=>this._changeDetectorRef.markForCheck()),this._tree._setNodeTypeIfUnset(this._type),this._tree._registerNode(this)}ngOnDestroy(){a.mostRecentTreeNode===this&&(a.mostRecentTreeNode=null),this._dataChanges.complete(),this._destroyed.next(),this._destroyed.complete()}getParent(){return this._tree._getNodeParent(this)??null}getChildren(){return this._tree._getNodeChildren(this)}focus(){this._tabindex=0,this._shouldFocus&&this._elementRef.nativeElement.focus(),this._changeDetectorRef.markForCheck()}unfocus(){this._tabindex=-1,this._changeDetectorRef.markForCheck()}activate(){this.isDisabled||this.activation.next(this._data)}collapse(){this.isExpandable&&this._tree.collapse(this._data)}expand(){this.isExpandable&&this._tree.expand(this._data)}makeFocusable(){this._tabindex=0,this._changeDetectorRef.markForCheck()}_focusItem(){this.isDisabled||this._tree._keyManager.focusItem(this)}_setActiveItem(){this.isDisabled||(this._shouldFocus=!1,this._tree._keyManager.focusItem(this),this._shouldFocus=!0)}_emitExpansionState(e){this.expandedChange.emit(e)}static \u0275fac=function(r){return new(r||a)};static \u0275dir=B({type:a,selectors:[["cdk-tree-node"]],hostAttrs:["role","treeitem",1,"cdk-tree-node"],hostVars:5,hostBindings:function(r,o){r&1&&g("click",function(){return o._setActiveItem()})("focus",function(){return o._focusItem()}),r&2&&(Zt("tabindex",o._tabindex),Ht("aria-expanded",o._getAriaExpanded())("aria-level",o.level+1)("aria-posinset",o._getPositionInSet())("aria-setsize",o._getSetSize()))},inputs:{role:"role",isExpandable:[2,"isExpandable","isExpandable",G],isExpanded:"isExpanded",isDisabled:[2,"isDisabled","isDisabled",G],typeaheadLabel:[0,"cdkTreeNodeTypeaheadLabel","typeaheadLabel"]},outputs:{activation:"activation",expandedChange:"expandedChange"},exportAs:["cdkTreeNode"],features:[Y]})}return a})();function Tn(a){let d=a.parentElement;for(;d&&!Dn(d);)d=d.parentElement;return d?d.classList.contains("cdk-nested-tree-node")?_e(d.getAttribute("aria-level")):0:-1}function Dn(a){let d=a.classList;return!!(d?.contains("cdk-nested-tree-node")||d?.contains("cdk-tree"))}var Nn=/([A-Za-z%]+)$/,Nt=(()=>{class a{_treeNode=v(re);_tree=v(fe);_element=v(de);_dir=v(ye,{optional:!0});_currentPadding;_destroyed=new le;indentUnits="px";get level(){return this._level}set level(e){this._setLevelInput(e)}_level;get indent(){return this._indent}set indent(e){this._setIndentInput(e)}_indent=40;constructor(){this._setPadding(),this._dir?.change.pipe(te(this._destroyed)).subscribe(()=>this._setPadding(!0)),this._treeNode._dataChanges.subscribe(()=>this._setPadding())}ngOnDestroy(){this._destroyed.next(),this._destroyed.complete()}_paddingIndent(){let e=(this._treeNode.data&&this._tree._getLevel(this._treeNode.data))??null,r=this._level==null?e:this._level;return typeof r=="number"?`${r*this._indent}${this.indentUnits}`:null}_setPadding(e=!1){let r=this._paddingIndent();if(r!==this._currentPadding||e){let o=this._element.nativeElement,l=this._dir&&this._dir.value==="rtl"?"paddingRight":"paddingLeft",s=l==="paddingLeft"?"paddingRight":"paddingLeft";o.style[l]=r||"",o.style[s]="",this._currentPadding=r}}_setLevelInput(e){this._level=isNaN(e)?null:e,this._setPadding()}_setIndentInput(e){let r=e,o="px";if(typeof e=="string"){let l=e.split(Nn);r=l[0],o=l[1]||o}this.indentUnits=o,this._indent=_e(r),this._setPadding()}static \u0275fac=function(r){return new(r||a)};static \u0275dir=B({type:a,selectors:[["","cdkTreeNodePadding",""]],inputs:{level:[2,"cdkTreeNodePadding","level",_e],indent:[0,"cdkTreeNodePaddingIndent","indent"]},features:[Y]})}return a})(),wt=(()=>{class a{_tree=v(fe);_treeNode=v(re);recursive=!1;constructor(){}_toggle(){this.recursive?this._tree.toggleDescendants(this._treeNode.data):this._tree.toggle(this._treeNode.data),this._tree._keyManager.focusItem(this._treeNode)}static \u0275fac=function(r){return new(r||a)};static \u0275dir=B({type:a,selectors:[["","cdkTreeNodeToggle",""]],hostAttrs:["tabindex","-1"],hostBindings:function(r,o){r&1&&g("click",function(s){return o._toggle(),s.stopPropagation()})("keydown.Enter",function(s){return o._toggle(),s.preventDefault()})("keydown.Space",function(s){return o._toggle(),s.preventDefault()})},inputs:{recursive:[2,"cdkTreeNodeToggleRecursive","recursive",G]},features:[Y]})}return a})();function wn(a,d){if(a&1&&u(0,"span",1),a&2){let e=d.$implicit;ie("ant-tree-indent-unit-end",!e)}}var yn=[[["nz-tree-node-toggle"],["","nz-tree-node-toggle",""]],[["nz-tree-node-checkbox"]],[["nz-tree-node-option"]],"*"],bn=["nz-tree-node-toggle, [nz-tree-node-toggle]","nz-tree-node-checkbox","nz-tree-node-option","*"];function kn(a,d){if(a&1&&u(0,"nz-tree-node-indents",0),a&2){let e=f();m("indents",e.indents)}}function Fn(a,d){a&1&&(t(0,"nz-tree-node-toggle",1),u(1,"span",2),n())}var Bn=["*"];function In(a,d){}function Vn(a,d){if(a&1&&(jt(0),E(1,In,0,0,"ng-template",4),Wt()),a&2){let e=d.$implicit,r=f();c(),m("data",e)("compareBy",r.compareBy)}}var En=(()=>{class a{constructor(e,r,o,l){this.ngZone=e,this.ref=r,this.host=o,this.destroy$=l,this.nzClick=new Ee}ngOnInit(){vt(this.host.nativeElement,"click").pipe(te(this.destroy$)).subscribe(e=>{!this.nzDisabled&&this.nzClick.observers.length&&this.ngZone.run(()=>{this.nzClick.emit(e),this.ref.markForCheck()})})}static{this.\u0275fac=function(r){return new(r||a)(C(zt),C(se),C(de),C(ve))}}static{this.\u0275cmp=z({type:a,selectors:[["nz-tree-node-checkbox",3,"builtin",""]],hostAttrs:[1,"ant-tree-checkbox"],hostVars:6,hostBindings:function(r,o){r&2&&ie("ant-tree-checkbox-checked",o.nzChecked)("ant-tree-checkbox-indeterminate",o.nzIndeterminate)("ant-tree-checkbox-disabled",o.nzDisabled)},inputs:{nzChecked:[2,"nzChecked","nzChecked",G],nzIndeterminate:[2,"nzIndeterminate","nzIndeterminate",G],nzDisabled:[2,"nzDisabled","nzDisabled",G]},outputs:{nzClick:"nzClick"},features:[U([ve]),Y],decls:1,vars:0,consts:[[1,"ant-tree-checkbox-inner"]],template:function(r,o){r&1&&u(0,"span",0)},encapsulation:2,changeDetection:0})}}return a})(),gn=(a,d,e)=>{let r=a.indexOf(d);if(r<0)return null;let o=e(d);for(r--;r>=0;r--){let l=e(a[r]);if(l+1===o)return a[r];if(l+1<o)return null}return null},xn=(a,d,e,r)=>{let o=typeof r<"u"?r:a.indexOf(d);if(o<0)return null;let l=e(d);for(o++;o<a.length;o++){let s=e(a[o]);if(s<l)return null;if(s===l)return a[o]}return null},ke=class extends re{},Ce=(()=>{class a extends fe{get dataSource(){return super.dataSource}set dataSource(e){super.dataSource=e}constructor(e,r,o){super(e,r,o),this.differs=e,this.changeDetectorRef=r,this.directionality=o,this.destroy$=new le,this.dir="ltr",this._dataSourceChanged=new le,this.nzDirectoryTree=!1,this.nzBlockNode=!1,this.noAnimation=v(Re,{host:!0,optional:!0})}ngOnInit(){super.ngOnInit(),this.dir=this.directionality.value,this.directionality.change?.pipe(te(this.destroy$)).subscribe(e=>{this.dir=e,this.changeDetectorRef.detectChanges()})}ngOnDestroy(){super.ngOnDestroy(),this.destroy$.next(!0),this.destroy$.complete()}renderNodeChanges(e,r,o,l){super.renderNodeChanges(e,r,o,l),this._dataSourceChanged.next()}static{this.\u0275fac=function(r){return new(r||a)(C(Ae),C(se),C(ye))}}static{this.\u0275cmp=z({type:a,selectors:[["ng-component"]],inputs:{treeControl:[0,"nzTreeControl","treeControl"],dataSource:[0,"nzDataSource","dataSource"],nzDirectoryTree:[2,"nzDirectoryTree","nzDirectoryTree",G],nzBlockNode:[2,"nzBlockNode","nzBlockNode",G]},features:[Y,ne],decls:0,vars:0,template:function(r,o){},encapsulation:2})}}return a})();function Mn(a){return a.map(d=>d?1:0).join("")}var An=typeof requestAnimationFrame<"u"?It:Bt,Ln=(()=>{class a{constructor(){this.indents=[]}static{this.\u0275fac=function(r){return new(r||a)}}static{this.\u0275cmp=z({type:a,selectors:[["nz-tree-node-indents"]],hostAttrs:[1,"ant-tree-indent"],inputs:{indents:"indents"},decls:2,vars:0,consts:[[1,"ant-tree-indent-unit",3,"ant-tree-indent-unit-end"],[1,"ant-tree-indent-unit"]],template:function(r,o){r&1&&$t(0,wn,1,2,"span",0,Kt),r&2&&Gt(o.indents)},encapsulation:2,changeDetection:0})}}return a})(),et=(()=>{class a{constructor(e,r,o){this.treeNode=e,this.tree=r,this.cdr=o,this.isLast="unset",this.isLeaf=!1,this.preNodeRef=null,this.nextNodeRef=null,this.currentIndents="",this.buildIndents(),this.checkLast(),this.changeSubscription=Te(this.treeNode._dataChanges,r._dataSourceChanged).pipe(Ie(0,An)).subscribe(()=>{this.buildIndents(),this.checkAdjacent(),this.cdr.markForCheck()})}getIndents(){let e=[],r=this.tree.treeControl.dataNodes,o=this.tree.treeControl.getLevel,l=gn(r,this.treeNode.data,o);for(;l;)xn(r,l,o)?e.unshift(!0):e.unshift(!1),l=gn(r,l,o);return e}buildIndents(){if(this.treeNode.data){let e=this.getIndents(),r=Mn(e);r!==this.currentIndents&&(this.treeNode.setIndents(this.getIndents()),this.currentIndents=r)}}checkAdjacent(){let e=this.tree.treeControl.dataNodes,r=e.indexOf(this.treeNode.data),o=e[r-1]||null,l=e[r+1]||null;(this.nextNodeRef!==l||this.preNodeRef!==o)&&this.checkLast(r),this.preNodeRef=o,this.nextNodeRef=l}checkLast(e){let r=this.tree.treeControl.dataNodes;this.isLeaf=this.treeNode.isLeaf,this.isLast=!xn(r,this.treeNode.data,this.tree.treeControl.getLevel,e)}ngOnDestroy(){this.preNodeRef=null,this.nextNodeRef=null,this.changeSubscription.unsubscribe()}static{this.\u0275fac=function(r){return new(r||a)(C(ke),C(Ce),C(se))}}static{this.\u0275dir=B({type:a,selectors:[["nz-tree-node","nzTreeNodeIndentLine",""]],hostAttrs:[1,"ant-tree-show-line"],hostVars:2,hostBindings:function(r,o){r&2&&ie("ant-tree-treenode-leaf-last",o.isLast&&o.isLeaf)}})}}return a})(),H=(()=>{class a{static{this.\u0275fac=function(r){return new(r||a)}}static{this.\u0275dir=B({type:a,selectors:[["nz-tree-node-toggle","nzTreeNodeNoopToggle",""],["","nzTreeNodeNoopToggle",""]],hostAttrs:[1,"ant-tree-switcher","ant-tree-switcher-noop"]})}}return a})(),A=(()=>{class a extends wt{constructor(){super(...arguments),this.recursive=!1}get isExpanded(){return this._treeNode.isExpanded}static{this.\u0275fac=(()=>{let e;return function(o){return(e||(e=xe(a)))(o||a)}})()}static{this.\u0275dir=B({type:a,selectors:[["nz-tree-node-toggle",3,"nzTreeNodeNoopToggle",""],["","nzTreeNodeToggle",""]],hostAttrs:[1,"ant-tree-switcher"],hostVars:4,hostBindings:function(r,o){r&2&&ie("ant-tree-switcher_open",o.isExpanded)("ant-tree-switcher_close",!o.isExpanded)},inputs:{recursive:[2,"nzTreeNodeToggleRecursive","recursive",G]},features:[U([{provide:wt,useExisting:W(()=>a)}]),Y,ne]})}}return a})(),K=(()=>{class a{static{this.\u0275fac=function(r){return new(r||a)}}static{this.\u0275dir=B({type:a,selectors:[["","nzTreeNodeToggleRotateIcon",""]],hostAttrs:[1,"ant-tree-switcher-icon"]})}}return a})(),Sn=(()=>{class a{static{this.\u0275fac=function(r){return new(r||a)}}static{this.\u0275dir=B({type:a,selectors:[["","nzTreeNodeToggleActiveIcon",""]],hostAttrs:[1,"ant-tree-switcher-loading-icon"]})}}return a})(),F=(()=>{class a extends ke{constructor(e,r,o,l){super(e,r),this.elementRef=e,this.tree=r,this.renderer=o,this.cdr=l,this.indents=[],this.disabled=!1,this.selected=!1,this.isLeaf=!1,this._elementRef.nativeElement.classList.add("ant-tree-treenode")}ngOnInit(){this.isLeaf=!this.tree.treeControl.isExpandable(this.data)}disable(){this.disabled=!0,this.updateDisabledClass()}enable(){this.disabled=!1,this.updateDisabledClass()}select(){this.selected=!0,this.updateSelectedClass()}deselect(){this.selected=!1,this.updateSelectedClass()}setIndents(e){this.indents=e,this.cdr.markForCheck()}updateSelectedClass(){this.selected?this.renderer.addClass(this.elementRef.nativeElement,"ant-tree-treenode-selected"):this.renderer.removeClass(this.elementRef.nativeElement,"ant-tree-treenode-selected")}updateDisabledClass(){this.disabled?this.renderer.addClass(this.elementRef.nativeElement,"ant-tree-treenode-disabled"):this.renderer.removeClass(this.elementRef.nativeElement,"ant-tree-treenode-disabled")}static{this.\u0275fac=function(r){return new(r||a)(C(de),C(Ce),C(Pt),C(se))}}static{this.\u0275cmp=z({type:a,selectors:[["nz-tree-node",3,"builtin",""]],hostVars:4,hostBindings:function(r,o){r&2&&ie("ant-tree-treenode-switcher-open",o.isExpanded)("ant-tree-treenode-switcher-close",!o.isExpanded)},exportAs:["nzTreeNode"],features:[U([{provide:re,useExisting:W(()=>a)},{provide:ke,useExisting:W(()=>a)}]),ne],ngContentSelectors:bn,decls:6,vars:2,consts:[[3,"indents"],["nzTreeNodeNoopToggle","",1,"nz-tree-leaf-line-icon"],[1,"ant-tree-switcher-leaf-line"]],template:function(r,o){r&1&&(Et(yn),E(0,kn,1,1,"nz-tree-node-indents",0),Se(1),E(2,Fn,2,0,"nz-tree-node-toggle",1),Se(3,1),Se(4,2),Se(5,3)),r&2&&(pe(o.indents.length?0:-1),c(2),pe(o.indents.length&&o.isLeaf?2:-1))},dependencies:[Ln,H],encapsulation:2,changeDetection:0})}}return a})(),L=(()=>{class a extends Ye{static{this.\u0275fac=(()=>{let e;return function(o){return(e||(e=xe(a)))(o||a)}})()}static{this.\u0275dir=B({type:a,selectors:[["","nzTreeNodeDef",""]],inputs:{when:[0,"nzTreeNodeDefWhen","when"]},features:[U([{provide:Ye,useExisting:W(()=>a)}]),ne]})}}return a})(),Rn=(()=>{class a{constructor(e){this._viewContainerRef=e,this._viewRef=null}ngOnChanges(e){if(this.shouldRecreateView(e)){let o=this._viewContainerRef;this._viewRef&&o.remove(o.indexOf(this._viewRef)),this._viewRef=this.data?o.createEmbeddedView(this.data.nodeDef.template,this.data.context):null,re.mostRecentTreeNode&&this._viewRef&&(re.mostRecentTreeNode.data=this.data.data)}else this._viewRef&&this.data.context&&this.updateExistingContext(this.data.context)}shouldRecreateView(e){let r=e.data;return r&&this.hasContextShapeChanged(r)}hasContextShapeChanged(e){let r=Object.keys(e.previousValue||{}),o=Object.keys(e.currentValue||{});if(r.length===o.length){for(let l of o)if(r.indexOf(l)===-1)return!0;return this.innerCompareBy(e.previousValue?.data??null)!==this.innerCompareBy(e.currentValue?.data??null)}return!0}get innerCompareBy(){return e=>e===null?e:this.compareBy?this.compareBy(e):e}updateExistingContext(e){for(let r of Object.keys(e))this._viewRef.context[r]=this.data.context[r]}static{this.\u0275fac=function(r){return new(r||a)(C(Ne))}}static{this.\u0275dir=B({type:a,selectors:[["","nzTreeVirtualScrollNodeOutlet",""]],inputs:{data:"data",compareBy:"compareBy"},features:[Ve]})}}return a})(),ee=(()=>{class a{constructor(e,r,o,l){this.ngZone=e,this.host=r,this.destroy$=o,this.treeNode=l,this.nzSelected=!1,this.nzDisabled=!1,this.nzClick=new Ee}get isExpanded(){return this.treeNode.isExpanded}ngOnChanges(e){let{nzDisabled:r,nzSelected:o}=e;r&&(r.currentValue?this.treeNode.disable():this.treeNode.enable()),o&&(o.currentValue?this.treeNode.select():this.treeNode.deselect())}ngOnInit(){vt(this.host.nativeElement,"click").pipe(mt(()=>!this.nzDisabled&&this.nzClick.observers.length>0),te(this.destroy$)).subscribe(e=>{this.ngZone.run(()=>this.nzClick.emit(e))})}static{this.\u0275fac=function(r){return new(r||a)(C(zt),C(de),C(ve),C(F))}}static{this.\u0275cmp=z({type:a,selectors:[["nz-tree-node-option"]],hostAttrs:[1,"ant-tree-node-content-wrapper"],hostVars:4,hostBindings:function(r,o){r&2&&ie("ant-tree-node-content-wrapper-open",o.isExpanded)("ant-tree-node-selected",o.nzSelected)},inputs:{nzSelected:[2,"nzSelected","nzSelected",G],nzDisabled:[2,"nzDisabled","nzDisabled",G]},outputs:{nzClick:"nzClick"},features:[U([ve]),Y,Ve],ngContentSelectors:Bn,decls:2,vars:0,consts:[[1,"ant-tree-title"]],template:function(r,o){r&1&&(Et(),t(0,"span",0),Se(1),n())},encapsulation:2,changeDetection:0})}}return a})(),Je=(()=>{class a{constructor(e){this.viewContainer=e,this._node=v(Dt,{optional:!0})}static{this.\u0275fac=function(r){return new(r||a)(C(Ne))}}static{this.\u0275dir=B({type:a,selectors:[["","nzTreeNodeOutlet",""]],features:[U([{provide:Xe,useExisting:W(()=>a)}])]})}}return a})(),j=(()=>{class a extends Nt{constructor(){super(...arguments),this._indent=24}get level(){return this._level}set level(e){this._setLevelInput(e)}get indent(){return this._indent}set indent(e){this._setIndentInput(e)}static{this.\u0275fac=(()=>{let e;return function(o){return(e||(e=xe(a)))(o||a)}})()}static{this.\u0275dir=B({type:a,selectors:[["","nzTreeNodePadding",""]],inputs:{level:[2,"nzTreeNodePadding","level",_e],indent:[0,"nzTreeNodePaddingIndent","indent"]},features:[U([{provide:Nt,useExisting:W(()=>a)}]),Y,ne]})}}return a})(),$=(()=>{class a extends Ce{constructor(){super(...arguments),this._afterViewInit=!1}ngAfterViewInit(){Promise.resolve().then(()=>{this._afterViewInit=!0,this.changeDetectorRef.markForCheck()})}static{this.\u0275fac=(()=>{let e;return function(o){return(e||(e=xe(a)))(o||a)}})()}static{this.\u0275cmp=z({type:a,selectors:[["nz-tree-view"]],viewQuery:function(r,o){if(r&1&&J(Je,7),r&2){let l;Z(l=Q())&&(o.nodeOutlet=l.first)}},hostAttrs:[1,"ant-tree"],hostVars:6,hostBindings:function(r,o){r&2&&ie("ant-tree-block-node",o.nzDirectoryTree||o.nzBlockNode)("ant-tree-directory",o.nzDirectoryTree)("ant-tree-rtl",o.dir==="rtl")},exportAs:["nzTreeView"],features:[U([{provide:fe,useExisting:W(()=>a)},{provide:Ce,useExisting:W(()=>a)}]),ne],decls:3,vars:2,consts:[[1,"ant-tree-list-holder"],[1,"ant-tree-list-holder-inner"],["nzTreeNodeOutlet",""]],template:function(r,o){r&1&&(t(0,"div",0)(1,"div",1),we(2,2),n()()),r&2&&(c(),m("@.disabled",!o._afterViewInit||!!(o.noAnimation!=null&&o.noAnimation.nzNoAnimation))("@treeCollapseMotion",o._nodeOutlet.viewContainer.length))},dependencies:[Je],encapsulation:2,data:{animation:[on]},changeDetection:0})}}return a})(),yt=28,bt=(()=>{class a extends Ce{constructor(){super(...arguments),this.nzItemSize=yt,this.nzMinBufferPx=yt*5,this.nzMaxBufferPx=yt*10,this.nodes=[],this.innerTrackBy=e=>e}ngOnChanges(e){e.trackBy&&(typeof e.trackBy.currentValue=="function"?this.innerTrackBy=(r,o)=>this.trackBy(r,o.data):this.innerTrackBy=r=>r)}get compareBy(){let e=this.treeControl;return e.trackBy?e.trackBy:null}renderNodeChanges(e){this.nodes=new Array(...e).map((r,o)=>this.createNode(r,o)),this._dataSourceChanged.next(),this.changeDetectorRef.markForCheck()}_getLevel(e){if(this.treeControl.getLevel)return this.treeControl.getLevel(e)}createNode(e,r){let o=this._getNodeDef(e,r),l=new be(e);return this.treeControl.getLevel?l.level=this.treeControl.getLevel(e):l.level=0,{data:e,context:l,nodeDef:o}}static{this.\u0275fac=(()=>{let e;return function(o){return(e||(e=xe(a)))(o||a)}})()}static{this.\u0275cmp=z({type:a,selectors:[["nz-tree-virtual-scroll-view"]],viewQuery:function(r,o){if(r&1&&(J(Je,7),J(Ct,7)),r&2){let l;Z(l=Q())&&(o.nodeOutlet=l.first),Z(l=Q())&&(o.virtualScrollViewport=l.first)}},hostAttrs:[1,"ant-tree"],hostVars:6,hostBindings:function(r,o){r&2&&ie("ant-tree-block-node",o.nzDirectoryTree||o.nzBlockNode)("ant-tree-directory",o.nzDirectoryTree)("ant-tree-rtl",o.dir==="rtl")},inputs:{nzItemSize:"nzItemSize",nzMinBufferPx:"nzMinBufferPx",nzMaxBufferPx:"nzMaxBufferPx",trackBy:"trackBy"},exportAs:["nzTreeVirtualScrollView"],features:[U([{provide:Ce,useExisting:W(()=>a)},{provide:fe,useExisting:W(()=>a)}]),ne,Ve],decls:4,vars:5,consts:[[1,"ant-tree-list"],[1,"ant-tree-list-holder",3,"itemSize","minBufferPx","maxBufferPx"],[4,"cdkVirtualFor","cdkVirtualForOf","cdkVirtualForTrackBy"],["nzTreeNodeOutlet",""],["nzTreeVirtualScrollNodeOutlet","",3,"data","compareBy"]],template:function(r,o){r&1&&(t(0,"div",0)(1,"cdk-virtual-scroll-viewport",1),E(2,Vn,2,2,"ng-container",2),n()(),we(3,3)),r&2&&(c(),m("itemSize",o.nzItemSize)("minBufferPx",o.nzMinBufferPx)("maxBufferPx",o.nzMaxBufferPx),c(),m("cdkVirtualForOf",o.nodes)("cdkVirtualForTrackBy",o.innerTrackBy))},dependencies:[Rn,nn,Je,Ct,tn],encapsulation:2,changeDetection:0})}}return a})();var R=(()=>{class a{static{this.\u0275fac=function(r){return new(r||a)}}static{this.\u0275mod=xt({type:a})}static{this.\u0275inj=ft({imports:[bt]})}}return a})(),V=class{constructor(d,e,r,o){this.transformFunction=d,this.getLevel=e,this.isExpandable=r,this.getChildren=o}flattenNode(d,e,r,o){let l=this.transformFunction(d,e);if(r.push(l),this.isExpandable(l)){let s=this.getChildren(d);s&&(Array.isArray(s)?this.flattenChildren(s,e,r,o):s.pipe(ue(1)).subscribe(h=>{this.flattenChildren(h,e,r,o)}))}return r}flattenChildren(d,e,r,o){d.forEach((l,s)=>{let h=o.slice();h.push(s!==d.length-1),this.flattenNode(l,e+1,r,h)})}flattenNodes(d){let e=[];return d.forEach(r=>this.flattenNode(r,0,e,[])),e}expandFlattenedNodes(d,e){let r=[],o=[];return o[0]=!0,d.forEach(l=>{let s=!0;for(let h=0;h<=this.getLevel(l);h++)s=s&&o[h];s&&r.push(l),this.isExpandable(l)&&(o[this.getLevel(l)+1]=e.isExpanded(l))}),r}},M=class extends Jt{constructor(d,e,r=[]){super(),this._treeControl=d,this._treeFlattener=e,this._flattenedData=new O([]),this._expandedData=new O([]),this._data=new O(r),this.flatNodes()}setData(d){this._data.next(d),this.flatNodes()}getData(){return this._data.getValue()}connect(d){let e=[d.viewChange,this._treeControl.expansionModel.changed.asObservable(),this._flattenedData.asObservable()];return Te(...e).pipe(k(()=>(this._expandedData.next(this._treeFlattener.expandFlattenedNodes(this._flattenedData.value,this._treeControl)),this._expandedData.value)))}disconnect(){}flatNodes(){this._flattenedData.next(this._treeFlattener.flattenNodes(this.getData())),this._treeControl.dataNodes=this._flattenedData.value}};function On(a,d){if(a&1){let e=P();t(0,"nz-tree-node",3),u(1,"nz-tree-node-toggle",4),t(2,"nz-tree-node-option",5),g("nzClick",function(){let o=w(e).$implicit,l=f();return y(l.selectListSelection.toggle(o))}),i(3),n()()}if(a&2){let e=d.$implicit,r=f();c(2),m("nzDisabled",e.disabled)("nzSelected",r.selectListSelection.isSelected(e)),c(),T(" ",e.name," ")}}function Pn(a,d){if(a&1){let e=P();t(0,"nz-tree-node",3)(1,"nz-tree-node-toggle"),u(2,"nz-icon",6),n(),t(3,"nz-tree-node-option",5),g("nzClick",function(){let o=w(e).$implicit,l=f();return y(l.selectListSelection.toggle(o))}),i(4),n()()}if(a&2){let e=d.$implicit,r=f();c(3),m("nzDisabled",e.disabled)("nzSelected",r.selectListSelection.isSelected(e)),c(),T(" ",e.name," ")}}var Hn=[{name:"parent 1",children:[{name:"parent 1-0",disabled:!0,children:[{name:"leaf"},{name:"leaf"}]},{name:"parent 1-1",children:[{name:"leaf"}]}]}],tt=(()=>{class a{constructor(){this.transformer=(e,r)=>({expandable:!!e.children&&e.children.length>0,name:e.name,level:r,disabled:!!e.disabled}),this.selectListSelection=new q(!0),this.treeControl=new b(e=>e.level,e=>e.expandable),this.treeFlattener=new V(this.transformer,e=>e.level,e=>e.expandable,e=>e.children),this.dataSource=new M(this.treeControl,this.treeFlattener),this.hasChild=(e,r)=>r.expandable,this.dataSource.setData(Hn),this.treeControl.expandAll()}static{this.\u0275fac=function(r){return new(r||a)}}static{this.\u0275cmp=z({type:a,selectors:[["nz-demo-tree-view-basic"]],decls:3,vars:3,consts:[[3,"nzTreeControl","nzDataSource"],["nzTreeNodePadding","",4,"nzTreeNodeDef"],["nzTreeNodePadding","",4,"nzTreeNodeDef","nzTreeNodeDefWhen"],["nzTreeNodePadding",""],["nzTreeNodeNoopToggle",""],[3,"nzClick","nzDisabled","nzSelected"],["nzType","caret-down","nzTreeNodeToggleRotateIcon",""]],template:function(r,o){r&1&&(t(0,"nz-tree-view",0),E(1,On,4,3,"nz-tree-node",1)(2,Pn,5,3,"nz-tree-node",2),n()),r&2&&(m("nzTreeControl",o.treeControl)("nzDataSource",o.dataSource),c(2),m("nzTreeNodeDefWhen",o.hasChild))},dependencies:[I,D,R,$,L,F,A,j,K,ee,H],encapsulation:2})}}return a})();function Kn(a,d){if(a&1){let e=P();t(0,"nz-tree-node",3),u(1,"nz-tree-node-toggle",4),t(2,"nz-tree-node-checkbox",5),g("nzClick",function(){let o=w(e).$implicit,l=f();return y(l.leafItemSelectionToggle(o))}),n(),t(3,"nz-tree-node-option",6),g("nzClick",function(){let o=w(e).$implicit,l=f();return y(l.leafItemSelectionToggle(o))}),i(4),n()()}if(a&2){let e=d.$implicit,r=f();c(2),m("nzDisabled",e.disabled)("nzChecked",r.checklistSelection.isSelected(e)),c(),m("nzDisabled",e.disabled),c(),T(" ",e.name," ")}}function $n(a,d){if(a&1){let e=P();t(0,"nz-tree-node",3)(1,"nz-tree-node-toggle"),u(2,"nz-icon",7),n(),t(3,"nz-tree-node-checkbox",8),g("nzClick",function(){let o=w(e).$implicit,l=f();return y(l.itemSelectionToggle(o))}),n(),t(4,"nz-tree-node-option",6),g("nzClick",function(){let o=w(e).$implicit,l=f();return y(l.itemSelectionToggle(o))}),i(5),n()()}if(a&2){let e=d.$implicit,r=f();c(3),m("nzDisabled",e.disabled)("nzChecked",r.descendantsAllSelected(e))("nzIndeterminate",r.descendantsPartiallySelected(e)),c(),m("nzDisabled",e.disabled),c(),T(" ",e.name," ")}}var Gn=[{name:"0-0",disabled:!0,children:[{name:"0-0-0"},{name:"0-0-1"},{name:"0-0-2"}]},{name:"0-1",children:[{name:"0-1-0",children:[{name:"0-1-0-0"},{name:"0-1-0-1"}]},{name:"0-1-1",children:[{name:"0-1-1-0"},{name:"0-1-1-1"}]}]}],nt=(()=>{class a{constructor(){this.transformer=(e,r)=>{let o=this.nestedNodeMap.get(e),l=o&&o.name===e.name?o:{expandable:!!e.children&&e.children.length>0,name:e.name,level:r,disabled:!!e.disabled};return this.flatNodeMap.set(l,e),this.nestedNodeMap.set(e,l),l},this.flatNodeMap=new Map,this.nestedNodeMap=new Map,this.checklistSelection=new q(!0),this.treeControl=new b(e=>e.level,e=>e.expandable),this.treeFlattener=new V(this.transformer,e=>e.level,e=>e.expandable,e=>e.children),this.dataSource=new M(this.treeControl,this.treeFlattener),this.hasChild=(e,r)=>r.expandable,this.dataSource.setData(Gn)}descendantsAllSelected(e){let r=this.treeControl.getDescendants(e);return r.length>0&&r.every(o=>this.checklistSelection.isSelected(o))}descendantsPartiallySelected(e){return this.treeControl.getDescendants(e).some(l=>this.checklistSelection.isSelected(l))&&!this.descendantsAllSelected(e)}leafItemSelectionToggle(e){this.checklistSelection.toggle(e),this.checkAllParentsSelection(e)}itemSelectionToggle(e){this.checklistSelection.toggle(e);let r=this.treeControl.getDescendants(e);this.checklistSelection.isSelected(e)?this.checklistSelection.select(...r):this.checklistSelection.deselect(...r),r.forEach(o=>this.checklistSelection.isSelected(o)),this.checkAllParentsSelection(e)}checkAllParentsSelection(e){let r=this.getParentNode(e);for(;r;)this.checkRootNodeSelection(r),r=this.getParentNode(r)}checkRootNodeSelection(e){let r=this.checklistSelection.isSelected(e),o=this.treeControl.getDescendants(e),l=o.length>0&&o.every(s=>this.checklistSelection.isSelected(s));r&&!l?this.checklistSelection.deselect(e):!r&&l&&this.checklistSelection.select(e)}getParentNode(e){let r=e.level;if(r<1)return null;let o=this.treeControl.dataNodes.indexOf(e)-1;for(let l=o;l>=0;l--){let s=this.treeControl.dataNodes[l];if(s.level<r)return s}return null}static{this.\u0275fac=function(r){return new(r||a)}}static{this.\u0275cmp=z({type:a,selectors:[["nz-demo-tree-view-checkbox"]],decls:3,vars:3,consts:[[3,"nzTreeControl","nzDataSource"],["nzTreeNodePadding","",4,"nzTreeNodeDef"],["nzTreeNodePadding","",4,"nzTreeNodeDef","nzTreeNodeDefWhen"],["nzTreeNodePadding",""],["nzTreeNodeNoopToggle",""],[3,"nzClick","nzDisabled","nzChecked"],[3,"nzClick","nzDisabled"],["nzType","caret-down","nzTreeNodeToggleRotateIcon",""],[3,"nzClick","nzDisabled","nzChecked","nzIndeterminate"]],template:function(r,o){r&1&&(t(0,"nz-tree-view",0),E(1,Kn,5,4,"nz-tree-node",1)(2,$n,6,5,"nz-tree-node",2),n()),r&2&&(m("nzTreeControl",o.treeControl)("nzDataSource",o.dataSource),c(2),m("nzTreeNodeDefWhen",o.hasChild))},dependencies:[I,D,R,$,L,F,A,j,K,ee,H,En],encapsulation:2})}}return a})();function jn(a,d){if(a&1){let e=P();t(0,"nz-tree-node",3),u(1,"nz-tree-node-toggle",4),t(2,"nz-tree-node-option",5),g("nzClick",function(){let o=w(e).$implicit,l=f();return y(l.selectListSelection.toggle(o))}),u(3,"nz-icon",6),i(4),n()()}if(a&2){let e=d.$implicit,r=f();c(2),m("nzDisabled",e.disabled)("nzSelected",r.selectListSelection.isSelected(e)),c(2),T(" ",e.name," ")}}function Wn(a,d){if(a&1){let e=P();t(0,"nz-tree-node",3)(1,"nz-tree-node-toggle"),u(2,"nz-icon",7),n(),t(3,"nz-tree-node-option",5),g("nzClick",function(){let o=w(e).$implicit,l=f();return y(l.selectListSelection.toggle(o))}),u(4,"nz-icon",8),i(5),n()()}if(a&2){let e=d.$implicit,r=f();c(3),m("nzDisabled",e.disabled)("nzSelected",r.selectListSelection.isSelected(e)),c(),m("nzType",r.treeControl.isExpanded(e)?"folder-open":"folder"),c(),T(" ",e.name," ")}}var Zn=[{name:"Fruit",children:[{name:"Apple"},{name:"Banana",disabled:!0},{name:"Fruit loops"}]},{name:"Vegetables",children:[{name:"Green",children:[{name:"Broccoli"},{name:"Brussels sprouts"}]},{name:"Orange",children:[{name:"Pumpkins"},{name:"Carrots"}]}]}],it=(()=>{class a{constructor(){this.transformer=(e,r)=>({expandable:!!e.children&&e.children.length>0,name:e.name,level:r,disabled:!!e.disabled}),this.selectListSelection=new q,this.treeControl=new b(e=>e.level,e=>e.expandable),this.treeFlattener=new V(this.transformer,e=>e.level,e=>e.expandable,e=>e.children),this.dataSource=new M(this.treeControl,this.treeFlattener),this.hasChild=(e,r)=>r.expandable,this.dataSource.setData(Zn)}ngAfterViewInit(){setTimeout(()=>{this.treeControl.expand(this.getNode("Vegetables"))},300)}getNode(e){return this.treeControl.dataNodes.find(r=>r.name===e)||null}static{this.\u0275fac=function(r){return new(r||a)}}static{this.\u0275cmp=z({type:a,selectors:[["nz-demo-tree-view-directory"]],decls:3,vars:4,consts:[[3,"nzTreeControl","nzDataSource","nzDirectoryTree"],["nzTreeNodePadding","",4,"nzTreeNodeDef"],["nzTreeNodePadding","",4,"nzTreeNodeDef","nzTreeNodeDefWhen"],["nzTreeNodePadding",""],["nzTreeNodeNoopToggle",""],[3,"nzClick","nzDisabled","nzSelected"],["nzType","file","nzTheme","outline"],["nzType","caret-down","nzTreeNodeToggleRotateIcon",""],["nzTheme","outline",3,"nzType"]],template:function(r,o){r&1&&(t(0,"nz-tree-view",0),E(1,jn,5,3,"nz-tree-node",1)(2,Wn,6,4,"nz-tree-node",2),n()),r&2&&(m("nzTreeControl",o.treeControl)("nzDataSource",o.dataSource)("nzDirectoryTree",!0),c(2),m("nzTreeNodeDefWhen",o.hasChild))},dependencies:[I,D,R,$,L,F,A,j,K,ee,H],encapsulation:2})}}return a})();function Qn(a,d){if(a&1&&(t(0,"nz-tree-node",3),i(1),n()),a&2){let e=d.$implicit;c(),T(" ",e.label," ")}}function Un(a,d){a&1&&(t(0,"nz-tree-node-toggle"),u(1,"nz-icon",5),n())}function qn(a,d){a&1&&(t(0,"nz-tree-node-toggle",4),u(1,"nz-icon",6),n())}function Xn(a,d){if(a&1&&(t(0,"nz-tree-node",3),E(1,Un,2,0,"nz-tree-node-toggle")(2,qn,2,0,"nz-tree-node-toggle",4),i(3),n()),a&2){let e=d.$implicit;c(),pe(e.loading?2:1),c(2),T(" ",e.label," ")}}var Yn=[{id:0,label:"Expand to load",level:0,expandable:!0},{id:1,label:"Expand to load",level:0,expandable:!0}];function Jn(a){return N([{id:Date.now(),label:`Child Node (level-${a.level+1})`,level:a.level+1,expandable:!0},{id:Date.now(),label:`Child Node (level-${a.level+1})`,level:a.level+1,expandable:!0},{id:Date.now(),label:`Leaf Node (level-${a.level+1})`,level:a.level+1,expandable:!1}]).pipe(At(500))}var kt=class{constructor(d,e){this.treeControl=d,this.childrenLoadedSet=new Set,this.flattenedData=new O(e),d.dataNodes=e}connect(d){let e=[d.viewChange,this.treeControl.expansionModel.changed.pipe(he(r=>this.handleExpansionChange(r))),this.flattenedData.asObservable()];return Te(...e).pipe(k(()=>this.expandFlattenedNodes(this.flattenedData.getValue())))}expandFlattenedNodes(d){let e=this.treeControl,r=[],o=[];return o[0]=!0,d.forEach(l=>{let s=!0;for(let h=0;h<=e.getLevel(l);h++)s=s&&o[h];s&&r.push(l),e.isExpandable(l)&&(o[e.getLevel(l)+1]=e.isExpanded(l))}),r}handleExpansionChange(d){d.added&&d.added.forEach(e=>this.loadChildren(e))}loadChildren(d){this.childrenLoadedSet.has(d)||(d.loading=!0,Jn(d).subscribe(e=>{d.loading=!1;let r=this.flattenedData.getValue(),o=r.indexOf(d);o!==-1&&(r.splice(o+1,0,...e),this.childrenLoadedSet.add(d)),this.flattenedData.next(r)}))}disconnect(){this.flattenedData.complete()}},rt=(()=>{class a{constructor(){this.treeControl=new b(e=>e.level,e=>e.expandable),this.dataSource=new kt(this.treeControl,Yn),this.hasChild=(e,r)=>r.expandable}static{this.\u0275fac=function(r){return new(r||a)}}static{this.\u0275cmp=z({type:a,selectors:[["nz-demo-tree-view-dynamic"]],decls:3,vars:3,consts:[[3,"nzTreeControl","nzDataSource"],["nzTreeNodePadding","",4,"nzTreeNodeDef"],["nzTreeNodePadding","",4,"nzTreeNodeDef","nzTreeNodeDefWhen"],["nzTreeNodePadding",""],["nzTreeNodeNoopToggle",""],["nzType","caret-down","nzTreeNodeToggleRotateIcon",""],["nzType","loading","nzTreeNodeToggleActiveIcon",""]],template:function(r,o){r&1&&(t(0,"nz-tree-view",0),E(1,Qn,2,1,"nz-tree-node",1)(2,Xn,4,2,"nz-tree-node",2),n()),r&2&&(m("nzTreeControl",o.treeControl)("nzDataSource",o.dataSource),c(2),m("nzTreeNodeDefWhen",o.hasChild))},dependencies:[I,D,R,$,L,F,A,j,K,Sn,H],encapsulation:2})}}return a})();function ti(a,d){if(a&1){let e=P();t(0,"nz-tree-node",4)(1,"nz-tree-node-option",5),g("nzClick",function(){let o=w(e).$implicit,l=f();return y(l.selectListSelection.toggle(o))}),i(2),n(),t(3,"button",6),g("click",function(){let o=w(e).$implicit,l=f();return y(l.delete(o))}),u(4,"nz-icon",7),n()()}if(a&2){let e=d.$implicit,r=f();c(),m("nzDisabled",e.disabled)("nzSelected",r.selectListSelection.isSelected(e)),c(),T(" ",e.name," ")}}function ni(a,d){if(a&1){let e=P();t(0,"nz-tree-node",4),u(1,"input",8,0),i(3," \xA0 "),t(4,"button",9),g("click",function(){let o=w(e).$implicit,l=Me(2),s=f();return y(s.saveNode(o,l.value))}),i(5,"Add"),n()()}}function ii(a,d){if(a&1){let e=P();t(0,"nz-tree-node",4)(1,"nz-tree-node-toggle"),u(2,"nz-icon",10),n(),i(3),t(4,"button",6),g("click",function(){let o=w(e).$implicit,l=f();return y(l.addNewNode(o))}),u(5,"nz-icon",11),n()()}if(a&2){let e=d.$implicit;c(3),T(" ",e.name," ")}}var ri=[{name:"parent 1",key:"1",children:[{name:"parent 1-0",key:"1-0",children:[{name:"leaf",key:"1-0-0"},{name:"leaf",key:"1-0-1"}]},{name:"parent 1-1",key:"1-1",children:[{name:"leaf",key:"1-1-0"}]}]},{key:"2",name:"parent 2",children:[{name:"leaf",key:"2-0"}]}],ot=(()=>{class a{constructor(){this.transformer=(e,r)=>{let o=this.nestedNodeMap.get(e),l=o&&o.key===e.key?o:{expandable:!!e.children&&e.children.length>0,name:e.name,level:r,key:e.key};return l.name=e.name,this.flatNodeMap.set(l,e),this.nestedNodeMap.set(e,l),l},this.treeData=ri,this.flatNodeMap=new Map,this.nestedNodeMap=new Map,this.selectListSelection=new q(!0),this.treeControl=new b(e=>e.level,e=>e.expandable),this.treeFlattener=new V(this.transformer,e=>e.level,e=>e.expandable,e=>e.children),this.dataSource=new M(this.treeControl,this.treeFlattener),this.hasChild=(e,r)=>r.expandable,this.hasNoContent=(e,r)=>r.name==="",this.trackBy=(e,r)=>`${r.key}-${r.name}`,this.dataSource.setData(this.treeData),this.treeControl.expandAll()}delete(e){let r=this.flatNodeMap.get(e),l=(()=>{let s=[...this.treeData];for(;s.length>0;){let h=s.pop();if(h.children){if(h.children.find(p=>p===r))return h;for(let p=h.children.length-1;p>=0;p--)s.push(h.children[p])}}return null})();l&&l.children&&(l.children=l.children.filter(s=>s!==r)),this.dataSource.setData(this.treeData)}addNewNode(e){let r=this.flatNodeMap.get(e);r&&(r.children=r.children||[],r.children.push({name:"",key:`${r.key}-${r.children.length}`}),this.dataSource.setData(this.treeData),this.treeControl.expand(e))}saveNode(e,r){let o=this.flatNodeMap.get(e);o&&(o.name=r,this.dataSource.setData(this.treeData))}static{this.\u0275fac=function(r){return new(r||a)}}static{this.\u0275cmp=z({type:a,selectors:[["nz-demo-tree-view-editable"]],decls:4,vars:5,consts:[["inputElement",""],[3,"nzTreeControl","nzDataSource","trackBy"],["nzTreeNodeIndentLine","",4,"nzTreeNodeDef"],["nzTreeNodeIndentLine","",4,"nzTreeNodeDef","nzTreeNodeDefWhen"],["nzTreeNodeIndentLine",""],[3,"nzClick","nzDisabled","nzSelected"],["nz-button","","nzType","text","nzSize","small",3,"click"],["nzType","minus","nzTheme","outline"],["nz-input","","placeholder","Input node name","nzSize","small"],["nz-button","","nzSize","small",3,"click"],["nzType","caret-down","nzTreeNodeToggleRotateIcon",""],["nzType","plus","nzTheme","outline"]],template:function(r,o){r&1&&(t(0,"nz-tree-view",1),E(1,ti,5,3,"nz-tree-node",2)(2,ni,6,0,"nz-tree-node",3)(3,ii,6,1,"nz-tree-node",3),n()),r&2&&(m("nzTreeControl",o.treeControl)("nzDataSource",o.dataSource)("trackBy",o.trackBy),c(2),m("nzTreeNodeDefWhen",o.hasNoContent),c(),m("nzTreeNodeDefWhen",o.hasChild))},dependencies:[sn,dn,an,ln,Ge,$e,I,D,R,$,L,F,A,K,ee,et],encapsulation:2})}}return a})();function ai(a,d){a&1&&(t(0,"nz-tree-node-toggle",5),u(1,"nz-icon",6),n())}function li(a,d){if(a&1&&(t(0,"nz-tree-node",4),E(1,ai,2,0,"nz-tree-node-toggle",5),t(2,"nz-tree-node-option"),i(3),n()()),a&2){let e=d.$implicit,r=f();c(),pe(r.showLeafIcon?1:-1),c(2),T(" ",e.name," ")}}function di(a,d){if(a&1&&(t(0,"nz-tree-node",4)(1,"nz-tree-node-toggle"),u(2,"span",7),n(),t(3,"nz-tree-node-option"),i(4),n()()),a&2){let e=d.$implicit,r=f();c(2),m("nzType",r.treeControl.isExpanded(e)?"minus-square":"plus-square"),c(2),T(" ",e.name," ")}}var si=[{name:"parent 1",children:[{name:"parent 1-0",children:[{name:"leaf"},{name:"leaf"}]},{name:"parent 1-1",children:[{name:"leaf"},{name:"parent 1-1-0",children:[{name:"leaf"},{name:"leaf"}]},{name:"leaf"}]}]},{name:"parent 2",children:[{name:"leaf"},{name:"leaf"}]}],at=(()=>{class a{constructor(){this.transformer=(e,r)=>({expandable:!!e.children&&e.children.length>0,name:e.name,level:r}),this.treeControl=new b(e=>e.level,e=>e.expandable),this.treeFlattener=new V(this.transformer,e=>e.level,e=>e.expandable,e=>e.children),this.dataSource=new M(this.treeControl,this.treeFlattener),this.showLeafIcon=!1,this.hasChild=(e,r)=>r.expandable,this.dataSource.setData(si)}ngAfterViewInit(){this.treeControl.expandAll()}static{this.\u0275fac=function(r){return new(r||a)}}static{this.\u0275cmp=z({type:a,selectors:[["nz-demo-tree-view-line"]],decls:5,vars:4,consts:[[3,"ngModelChange","ngModel"],[3,"nzTreeControl","nzDataSource"],["nzTreeNodeIndentLine","",4,"nzTreeNodeDef"],["nzTreeNodeIndentLine","",4,"nzTreeNodeDef","nzTreeNodeDefWhen"],["nzTreeNodeIndentLine",""],["nzTreeNodeNoopToggle",""],["nzType","file","nzTheme","outline"],["nz-icon","","nzTheme","outline",3,"nzType"]],template:function(r,o){r&1&&(i(0," Show Leaf Icon: "),t(1,"nz-switch",0),Xt("ngModelChange",function(s){return qt(o.showLeafIcon,s)||(o.showLeafIcon=s),s}),n(),t(2,"nz-tree-view",1),E(3,li,4,2,"nz-tree-node",2)(4,di,5,2,"nz-tree-node",3),n()),r&2&&(c(),Ut("ngModel",o.showLeafIcon),c(),m("nzTreeControl",o.treeControl)("nzDataSource",o.dataSource),c(2),m("nzTreeNodeDefWhen",o.hasChild))},dependencies:[Ke,Pe,He,I,D,pn,hn,R,$,L,F,A,ee,H,et],encapsulation:2})}}return a})();function ci(a,d){a&1&&u(0,"nz-icon",6)}function mi(a,d){if(a&1&&(t(0,"nz-tree-node",7),u(1,"nz-tree-node-toggle",8)(2,"span",9),St(3,"nzHighlight"),n()),a&2){let e=d.$implicit,r=f();c(2),m("innerHTML",_t(3,1,e.name,r.searchValue,"i","highlight"),gt)}}function ui(a,d){if(a&1&&(t(0,"nz-tree-node",7)(1,"nz-tree-node-toggle"),u(2,"nz-icon",10),n(),u(3,"span",9),St(4,"nzHighlight"),n()),a&2){let e=d.$implicit,r=f();c(3),m("innerHTML",_t(4,1,e.name,r.searchValue,"i","highlight"),gt)}}var hi=[{name:"0-0",children:[{name:"0-0-0"},{name:"0-0-1"},{name:"0-0-2"}]},{name:"0-1",children:[{name:"0-1-0",children:[{name:"0-1-0-0"},{name:"0-1-0-1"}]},{name:"0-1-1",children:[{name:"0-1-1-0"},{name:"0-1-1-1"}]}]}],lt=class{constructor(d,e=[]){this.treeData=d,this.needsToExpanded=e}};function pi(a,d){let e=new Set,r=(l,s)=>{if(l.name.search(d)!==-1)return s.push(l),s;if(Array.isArray(l.children)){let h=l.children.reduce((p,x)=>r(x,p),[]);if(h.length){let p=Be(Fe({},l),{children:h});e.add(p),s.push(p)}}return s},o=a.reduce((l,s)=>r(s,l),[]);return new lt(o,[...e])}var dt=(()=>{class a{constructor(){this.flatNodeMap=new Map,this.nestedNodeMap=new Map,this.expandedNodes=[],this.searchValue="",this.originData$=new O(hi),this.searchValue$=new O(""),this.transformer=(e,r)=>{let o=this.nestedNodeMap.get(e),l=o&&o.name===e.name?o:{expandable:!!e.children&&e.children.length>0,name:e.name,level:r};return this.flatNodeMap.set(l,e),this.nestedNodeMap.set(e,l),l},this.treeControl=new b(e=>e.level,e=>e.expandable,{trackBy:e=>this.flatNodeMap.get(e)}),this.treeFlattener=new V(this.transformer,e=>e.level,e=>e.expandable,e=>e.children),this.dataSource=new M(this.treeControl,this.treeFlattener),this.filteredData$=ge([this.originData$,this.searchValue$.pipe(Ie(300),k(e=>this.searchValue=e))]).pipe(k(([e,r])=>r?pi(e,r):new lt(e))),this.hasChild=(e,r)=>r.expandable,this.filteredData$.subscribe(e=>{this.dataSource.setData(e.treeData),!!this.searchValue?(this.expandedNodes.length===0&&(this.expandedNodes=this.treeControl.expansionModel.selected,this.treeControl.expansionModel.clear()),this.treeControl.expansionModel.select(...e.needsToExpanded)):this.expandedNodes.length&&(this.treeControl.expansionModel.clear(),this.treeControl.expansionModel.select(...this.expandedNodes),this.expandedNodes=[])})}static{this.\u0275fac=function(r){return new(r||a)}}static{this.\u0275cmp=z({type:a,selectors:[["nz-demo-tree-view-search"]],decls:7,vars:4,consts:[["suffixIcon",""],[3,"nzSuffix"],["type","text","nz-input","","placeholder","Search","ngModel","",3,"ngModelChange"],["nzNoAnimation","",3,"nzTreeControl","nzDataSource"],["nzTreeNodePadding","",4,"nzTreeNodeDef"],["nzTreeNodePadding","",4,"nzTreeNodeDef","nzTreeNodeDefWhen"],["nzType","search"],["nzTreeNodePadding",""],["nzTreeNodeNoopToggle",""],[3,"innerHTML"],["nzType","caret-down","nzTreeNodeToggleRotateIcon",""]],template:function(r,o){if(r&1){let l=P();t(0,"nz-input-group",1)(1,"input",2),g("ngModelChange",function(h){return w(l),y(o.searchValue$.next(h))}),n()(),E(2,ci,1,0,"ng-template",null,0,Yt),t(4,"nz-tree-view",3),E(5,mi,4,6,"nz-tree-node",4)(6,ui,5,6,"nz-tree-node",5),n()}if(r&2){let l=Me(3);m("nzSuffix",l),c(4),m("nzTreeControl",o.treeControl)("nzDataSource",o.dataSource),c(2),m("nzTreeNodeDefWhen",o.hasChild)}},dependencies:[Ke,cn,Pe,He,Ge,$e,un,mn,I,D,R,$,L,F,A,j,K,H,Re,fn],styles:["nz-input-group[_ngcontent-%COMP%]{margin-bottom:8px} .highlight{color:#f50}"]})}}return a})();function fi(a,d){if(a&1&&(t(0,"nz-tree-node",3),u(1,"nz-tree-node-toggle",4),i(2),n()),a&2){let e=d.$implicit;c(2),T(" ",e.name," ")}}function zi(a,d){if(a&1&&(t(0,"nz-tree-node",3)(1,"nz-tree-node-toggle"),u(2,"nz-icon",5),n(),i(3),n()),a&2){let e=d.$implicit;c(3),T(" ",e.name," ")}}function _n(a="0",d=3){let e=[];for(let r=0;r<10;r+=1){let o=`${a}-${r}`,l={name:o};d>0&&(l.children=_n(o,d-1)),e.push(l)}return e}var gi=_n(),st=(()=>{class a{constructor(){this.transformer=(e,r)=>({expandable:!!e.children&&e.children.length>0,name:e.name,level:r}),this.treeControl=new b(e=>e.level,e=>e.expandable),this.treeFlattener=new V(this.transformer,e=>e.level,e=>e.expandable,e=>e.children),this.dataSource=new M(this.treeControl,this.treeFlattener),this.hasChild=(e,r)=>r.expandable,this.dataSource.setData(gi),this.treeControl.expandAll()}static{this.\u0275fac=function(r){return new(r||a)}}static{this.\u0275cmp=z({type:a,selectors:[["nz-demo-tree-view-virtual-scroll"]],decls:3,vars:3,consts:[[1,"virtual-scroll-tree",3,"nzTreeControl","nzDataSource"],["nzTreeNodePadding","",4,"nzTreeNodeDef"],["nzTreeNodePadding","",4,"nzTreeNodeDef","nzTreeNodeDefWhen"],["nzTreeNodePadding",""],["nzTreeNodeNoopToggle",""],["nzType","caret-down","nzTreeNodeToggleRotateIcon",""]],template:function(r,o){r&1&&(t(0,"nz-tree-virtual-scroll-view",0),E(1,fi,3,1,"nz-tree-node",1)(2,zi,4,1,"nz-tree-node",2),n()),r&2&&(m("nzTreeControl",o.treeControl)("nzDataSource",o.dataSource),c(2),m("nzTreeNodeDefWhen",o.hasChild))},dependencies:[I,D,R,L,F,A,j,K,H,bt],styles:[".virtual-scroll-tree[_ngcontent-%COMP%]{height:200px}"]})}}return a})();var vn=(()=>{class a{constructor(){this.expanded=!1}goLink(e){window&&(window.location.hash=e)}expandAllCode(){this.expanded=!this.expanded,this.codeBoxes.forEach(e=>e.expandCode(this.expanded))}static{this.\u0275fac=function(r){return new(r||a)}}static{this.\u0275cmp=z({type:a,selectors:[["nz-demo-tree-view"]],viewQuery:function(r,o){if(r&1&&J(ce,5),r&2){let l;Z(l=Q())&&(o.codeBoxes=l)}},decls:708,vars:39,consts:[[1,"toc-affix",3,"nzOffsetTop"],["nzShowInkInFixed","",3,"nzClick","nzAffix"],["nzHref","#components-tree-view-demo-basic","nzTitle","\u57FA\u672C"],["nzHref","#components-tree-view-demo-checkbox","nzTitle","\u9009\u62E9\u6846"],["nzHref","#components-tree-view-demo-directory","nzTitle","\u76EE\u5F55"],["nzHref","#components-tree-view-demo-dynamic","nzTitle","\u5F02\u6B65\u52A0\u8F7D\u6570\u636E"],["nzHref","#components-tree-view-demo-line","nzTitle","\u5E26\u8FDE\u63A5\u7EBF\u7684\u6811"],["nzHref","#components-tree-view-demo-editable","nzTitle","\u53EF\u7F16\u8F91"],["nzHref","#components-tree-view-demo-search","nzTitle","\u641C\u7D22"],["nzHref","#components-tree-view-demo-virtual-scroll","nzTitle","\u865A\u62DF\u6EDA\u52A8"],["nzHref","#api","nzTitle","API"],[1,"markdown"],[1,"subtitle"],[1,"widget"],["aria-label","Edit this page on Github","href","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/tree-view/doc/index.zh-CN.md","target","_blank","rel","noopener noreferrer",1,"edit-button"],["nzType","edit"],["id","\u4F55\u65F6\u4F7F\u7528"],["onclick","window.location.hash = '\u4F55\u65F6\u4F7F\u7528'",1,"anchor"],[1,"language-ts"],[1,"token","keyword"],[1,"token","punctuation"],[1,"token","string"],["nz-icon","","nzType","appstore","nz-tooltip","","nzTooltipTitle","\u5C55\u5F00\u5168\u90E8\u4EE3\u7801",1,"code-box-expand-trigger",3,"click"],["nz-row","",3,"nzGutter"],["nz-col","",3,"nzXl","nzSpan"],["nzTitle","\u57FA\u672C","nzSelector","nz-demo-tree-view-basic","nzGenerateCommand","ng g ng-zorro-antd:tree-view-basic <name>","nzComponentName","NzDemoTreeViewBasicComponent","nzIframeSource","null",3,"nzId","nzLink","nzIframeHeight","nzHref"],["demo",""],["intro",""],["nzTitle","\u76EE\u5F55","nzSelector","nz-demo-tree-view-directory","nzGenerateCommand","ng g ng-zorro-antd:tree-view-directory <name>","nzComponentName","NzDemoTreeViewDirectoryComponent","nzIframeSource","null",3,"nzId","nzLink","nzIframeHeight","nzHref"],["nzTitle","\u5E26\u8FDE\u63A5\u7EBF\u7684\u6811","nzSelector","nz-demo-tree-view-line","nzGenerateCommand","ng g ng-zorro-antd:tree-view-line <name>","nzComponentName","NzDemoTreeViewLineComponent","nzIframeSource","null",3,"nzId","nzLink","nzIframeHeight","nzHref"],["nzTitle","\u641C\u7D22","nzSelector","nz-demo-tree-view-search","nzGenerateCommand","ng g ng-zorro-antd:tree-view-search <name>","nzComponentName","NzDemoTreeViewSearchComponent","nzIframeSource","null",3,"nzId","nzLink","nzIframeHeight","nzHref"],["nzTitle","\u9009\u62E9\u6846","nzSelector","nz-demo-tree-view-checkbox","nzGenerateCommand","ng g ng-zorro-antd:tree-view-checkbox <name>","nzComponentName","NzDemoTreeViewCheckboxComponent","nzIframeSource","null",3,"nzId","nzLink","nzIframeHeight","nzHref"],["nzTitle","\u5F02\u6B65\u52A0\u8F7D\u6570\u636E","nzSelector","nz-demo-tree-view-dynamic","nzGenerateCommand","ng g ng-zorro-antd:tree-view-dynamic <name>","nzComponentName","NzDemoTreeViewDynamicComponent","nzIframeSource","null",3,"nzId","nzLink","nzIframeHeight","nzHref"],["nzTitle","\u53EF\u7F16\u8F91","nzSelector","nz-demo-tree-view-editable","nzGenerateCommand","ng g ng-zorro-antd:tree-view-editable <name>","nzComponentName","NzDemoTreeViewEditableComponent","nzIframeSource","null",3,"nzId","nzLink","nzIframeHeight","nzHref"],["nzTitle","\u865A\u62DF\u6EDA\u52A8","nzSelector","nz-demo-tree-view-virtual-scroll","nzGenerateCommand","ng g ng-zorro-antd:tree-view-virtual-scroll <name>","nzComponentName","NzDemoTreeViewVirtualScrollComponent","nzIframeSource","null",3,"nzId","nzLink","nzIframeHeight","nzHref"],[1,"markdown","api-container"],["id","api"],["onclick","window.location.hash = 'api'",1,"anchor"],["id","nz-tree-view"],[1,"api-type-label","component"],["onclick","window.location.hash = 'nz-tree-view'",1,"anchor"],["href","https://material.angular.io/cdk/tree/api#TreeControl","target","_blank","rel","noopener"],["href","https://material.angular.io/cdk/tree/overview#data-source","target","_blank","rel","noopener"],["id","nz-tree-virtual-scroll-view"],["onclick","window.location.hash = 'nz-tree-virtual-scroll-view'",1,"anchor"],["href","https://material.angular.io/cdk/scrolling/api#CdkVirtualScrollViewport","target","_blank","rel","noopener"],["id","[nztreenodedef]"],[1,"api-type-label","directive"],["onclick","window.location.hash = '[nztreenodedef]'",1,"anchor"],["id","nz-tree-node"],["onclick","window.location.hash = 'nz-tree-node'",1,"anchor"],["id","[nztreenodepadding]"],["onclick","window.location.hash = '[nztreenodepadding]'",1,"anchor"],[1,"language-html"],[1,"token","tag"],[1,"token","attr-name"],["id","nztreenodeindentline"],["onclick","window.location.hash = 'nztreenodeindentline'",1,"anchor"],["id","nz-tree-node-toggle"],["onclick","window.location.hash = 'nz-tree-node-toggle'",1,"anchor"],["id","nz-tree-node-toggle[nztreenodenooptoggle]"],["onclick","window.location.hash = 'nz-tree-node-toggle[nztreenodenooptoggle]'",1,"anchor"],["id","[nztreenodetogglerotateicon]"],["onclick","window.location.hash = '[nztreenodetogglerotateicon]'",1,"anchor"],["id","[nztreenodetoggleactiveicon]"],["onclick","window.location.hash = '[nztreenodetoggleactiveicon]'",1,"anchor"],["id","nz-tree-node-option"],["onclick","window.location.hash = 'nz-tree-node-option'",1,"anchor"],["id","nz-tree-node-checkbox"],["onclick","window.location.hash = 'nz-tree-node-checkbox'",1,"anchor"],["id","classes"],["onclick","window.location.hash = 'classes'",1,"anchor"],["id","<strong>nztreeflatdatasource-extends-datasource</strong>"],["onclick","window.location.hash = '<strong>nztreeflatdatasource-extends-datasource</strong>'",1,"anchor"],["id","\u6784\u9020\u53C2\u6570"],["onclick","window.location.hash = '\u6784\u9020\u53C2\u6570'",1,"anchor"],["id","\u65B9\u6CD5"],["onclick","window.location.hash = '\u65B9\u6CD5'",1,"anchor"],["id","<strong>nztreeflattener</strong>"],["onclick","window.location.hash = '<strong>nztreeflattener</strong>'",1,"anchor"]],template:function(r,o){r&1&&(t(0,"article")(1,"nz-affix",0)(2,"nz-anchor",1),g("nzClick",function(s){return o.goLink(s)}),u(3,"nz-link",2)(4,"nz-link",3)(5,"nz-link",4)(6,"nz-link",5)(7,"nz-link",6)(8,"nz-link",7)(9,"nz-link",8)(10,"nz-link",9)(11,"nz-link",10),n()(),t(12,"section",11)(13,"h1"),i(14,"Tree View"),t(15,"span",12),i(16,"\u6811\u89C6\u56FE"),n(),u(17,"span",13),t(18,"a",14),u(19,"nz-icon",15),n()(),t(20,"section",11),_(),t(21,"h2",16)(22,"span"),i(23,"\u4F55\u65F6\u4F7F\u7528"),n(),t(24,"a",17),i(25,"#"),n()(),t(26,"p"),i(27,"\u66F4\u57FA\u7840\u7684 Tree \u7EC4\u4EF6\uFF0C\u5141\u8BB8\u5728\u6A21\u7248\u4E2D\u5B9A\u4E49\u6BCF\u4E2A\u7EC4\u6210\u90E8\u5206\uFF0C\u5E76\u624B\u52A8\u7BA1\u7406\u72B6\u6001\u3002\u76F8\u6BD4\u5C01\u88C5\u597D\u7684 Tree \u7EC4\u4EF6\u5177\u6709\u66F4\u9AD8\u7684\u5B9A\u5236\u5EA6\u548C\u66F4\u597D\u7684\u6027\u80FD\u3002"),n(),t(28,"pre",18)(29,"code")(30,"span",19),i(31,"import"),n(),i(32," "),t(33,"span",20),i(34,"{"),n(),i(35," NzTreeViewModule "),t(36,"span",20),i(37,"}"),n(),i(38," "),t(39,"span",19),i(40,"from"),n(),i(41," "),t(42,"span",21),i(43,"'ng-zorro-antd/tree-view'"),n(),t(44,"span",20),i(45,";"),n()()(),S(),n(),t(46,"h2")(47,"span"),i(48,"\u4EE3\u7801\u6F14\u793A"),n(),t(49,"span",22),g("click",function(){return o.expandAllCode()}),n()()(),t(50,"div",23)(51,"div",24)(52,"nz-code-box",25),u(53,"nz-demo-tree-view-basic",26),t(54,"div",27),_(),t(55,"p"),i(56,"\u6700\u7B80\u5355\u7684\u7528\u6CD5\uFF0C\u9009\u4E2D\uFF0C\u7981\u7528\uFF0C\u5C55\u5F00\u7B49\u529F\u80FD\u3002"),n(),S(),n()(),t(57,"nz-code-box",28),u(58,"nz-demo-tree-view-directory",26),t(59,"div",27),_(),t(60,"p"),i(61,"\u76EE\u5F55\u6811"),n(),S(),n()(),t(62,"nz-code-box",29),u(63,"nz-demo-tree-view-line",26),t(64,"div",27),_(),t(65,"p"),i(66,"\u8282\u70B9\u4E4B\u95F4\u5E26\u8FDE\u63A5\u7EBF\u7684\u6811\uFF0C\u5E38\u7528\u4E8E\u6587\u4EF6\u76EE\u5F55\u7ED3\u6784\u5C55\u793A\u3002"),n(),S(),n()(),t(67,"nz-code-box",30),u(68,"nz-demo-tree-view-search",26),t(69,"div",27),_(),t(70,"p"),i(71,"\u53EF\u641C\u7D22\u7684\u6811\u3002"),n(),S(),n()()(),t(72,"div",24)(73,"nz-code-box",31),u(74,"nz-demo-tree-view-checkbox",26),t(75,"div",27),_(),t(76,"p"),i(77,"\u5E26\u9009\u62E9\u6846\u7684\u6811\u3002"),n(),S(),n()(),t(78,"nz-code-box",32),u(79,"nz-demo-tree-view-dynamic",26),t(80,"div",27),_(),t(81,"p"),i(82,"\u70B9\u51FB\u5C55\u5F00\u8282\u70B9\uFF0C\u52A8\u6001\u52A0\u8F7D\u6570\u636E\u3002"),n(),S(),n()(),t(83,"nz-code-box",33),u(84,"nz-demo-tree-view-editable",26),t(85,"div",27),_(),t(86,"p"),i(87,"\u5E26\u6DFB\u52A0\u548C\u5220\u9664\u529F\u80FD\u7684\u6811\u3002"),n(),S(),n()(),t(88,"nz-code-box",34),u(89,"nz-demo-tree-view-virtual-scroll",26),t(90,"div",27),_(),t(91,"p"),i(92,"\u4F7F\u7528\u865A\u62DF\u6EDA\u52A8\u3002"),n(),S(),n()()()(),t(93,"section",35),_(),t(94,"h2",36)(95,"span"),i(96,"API"),n(),t(97,"a",37),i(98,"#"),n()(),t(99,"h3",38)(100,"span"),i(101,"nz-tree-view"),n(),t(102,"label",39),i(103,"component"),n(),t(104,"a",40),i(105,"#"),n()(),t(106,"table")(107,"thead")(108,"tr")(109,"th"),i(110,"\u53C2\u6570"),n(),t(111,"th"),i(112,"\u8BF4\u660E"),n(),t(113,"th"),i(114,"\u7C7B\u578B"),n(),t(115,"th"),i(116,"\u9ED8\u8BA4\u503C"),n()()(),t(117,"tbody")(118,"tr")(119,"td"),i(120,"[nzTreeControl]"),n(),t(121,"td"),i(122,"\u6811\u63A7\u5236\u5668"),n(),t(123,"td")(124,"a",41),i(125,"TreeControl"),n()(),t(126,"td"),i(127,"-"),n()(),t(128,"tr")(129,"td"),i(130,"[nzDataSource]"),n(),t(131,"td"),i(132,"\u7528\u4E8E\u6E32\u67D3\u6811\u7684\u6570\u7EC4\u6570\u636E"),n(),t(133,"td")(134,"a",42),i(135,"DataSource"),n(),i(136,"<T>"),n(),t(137,"td"),i(138,"Observable<T[]>"),n()(),t(139,"tr")(140,"td"),i(141,"[nzDirectoryTree]"),n(),t(142,"td"),i(143,"\u8282\u70B9\u662F\u5426\u4EE5\u6587\u4EF6\u5939\u6837\u5F0F\u663E\u793A"),n(),t(144,"td"),i(145,"boolean"),n(),t(146,"td")(147,"code"),i(148,"false"),n()()(),t(149,"tr")(150,"td"),i(151,"[nzBlockNode]"),n(),t(152,"td"),i(153,"\u8282\u70B9\u662F\u5426\u5360\u636E\u6574\u884C"),n(),t(154,"td"),i(155,"boolean"),n(),t(156,"td")(157,"code"),i(158,"false"),n()()()()(),t(159,"h3",43)(160,"span"),i(161,"nz-tree-virtual-scroll-view"),n(),t(162,"label",39),i(163,"component"),n(),t(164,"a",44),i(165,"#"),n()(),t(166,"p"),i(167,"\u865A\u62DF\u6EDA\u52A8\u7684\u6811\u89C6\u56FE\uFF0C\u53EF\u4EE5\u901A\u8FC7\u7EC4\u4EF6\u5B9E\u4F8B\u4E0A\u7684 "),t(168,"code"),i(169,"virtualScrollViewport"),n(),i(170," \u6210\u5458\u8BBF\u95EE "),t(171,"a",45),i(172,"CdkVirtualScrollViewport"),n(),i(173," \u5B9E\u4F8B\u3002"),n(),t(174,"table")(175,"thead")(176,"tr")(177,"th"),i(178,"\u53C2\u6570"),n(),t(179,"th"),i(180,"\u8BF4\u660E"),n(),t(181,"th"),i(182,"\u7C7B\u578B"),n(),t(183,"th"),i(184,"\u9ED8\u8BA4\u503C"),n()()(),t(185,"tbody")(186,"tr")(187,"td"),i(188,"[nzTreeControl]"),n(),t(189,"td"),i(190,"\u6811\u63A7\u5236\u5668"),n(),t(191,"td")(192,"a",41),i(193,"TreeControl"),n()(),t(194,"td"),i(195,"-"),n()(),t(196,"tr")(197,"td"),i(198,"[nzDataSource]"),n(),t(199,"td"),i(200,"\u7528\u4E8E\u6E32\u67D3\u6811\u7684\u6570\u7EC4\u6570\u636E"),n(),t(201,"td")(202,"a",42),i(203,"DataSource"),n(),i(204,"<T>"),n(),t(205,"td"),i(206,"Observable<T[]>"),n()(),t(207,"tr")(208,"td"),i(209,"[nzDirectoryTree]"),n(),t(210,"td"),i(211,"\u8282\u70B9\u662F\u5426\u4EE5\u6587\u4EF6\u5939\u6837\u5F0F\u663E\u793A"),n(),t(212,"td")(213,"code"),i(214,"boolean"),n()(),t(215,"td")(216,"code"),i(217,"false"),n()()(),t(218,"tr")(219,"td"),i(220,"[nzBlockNode]"),n(),t(221,"td"),i(222,"\u8282\u70B9\u662F\u5426\u5360\u636E\u6574\u884C"),n(),t(223,"td")(224,"code"),i(225,"boolean"),n()(),t(226,"td")(227,"code"),i(228,"false"),n()()(),t(229,"tr")(230,"td"),i(231,"[nzItemSize]"),n(),t(232,"td"),i(233,"\u8282\u70B9\u7684\u5C3A\u5BF8(px)"),n(),t(234,"td")(235,"code"),i(236,"number"),n()(),t(237,"td")(238,"code"),i(239,"28"),n()()(),t(240,"tr")(241,"td"),i(242,"[nzMinBufferPx]"),n(),t(243,"td"),i(244,"\u8D85\u51FA\u6E32\u67D3\u533A\u7684\u6700\u5C0F\u7F13\u5B58\u533A\u5927\u5C0F(px)"),n(),t(245,"td")(246,"code"),i(247,"number"),n()(),t(248,"td")(249,"code"),i(250,"28 * 5"),n()()(),t(251,"tr")(252,"td"),i(253,"[nzMaxBufferPx]"),n(),t(254,"td"),i(255,"\u9700\u8981\u6E32\u67D3\u65B0\u8282\u70B9\u65F6\u7684\u7F13\u51B2\u533A\u5927\u5C0F(px)"),n(),t(256,"td")(257,"code"),i(258,"number"),n()(),t(259,"td")(260,"code"),i(261,"28 * 10"),n()()()()(),t(262,"h3",46)(263,"span"),i(264,"[nzTreeNodeDef]"),n(),t(265,"label",47),i(266,"directive"),n(),t(267,"a",48),i(268,"#"),n()(),t(269,"p"),i(270,"\u7528\u4E8E\u5B9A\u4E49 "),t(271,"code"),i(272,"nz-tree-node"),n(),i(273," \u7684\u6307\u4EE4\u3002"),n(),t(274,"table")(275,"thead")(276,"tr")(277,"th"),i(278,"\u53C2\u6570"),n(),t(279,"th"),i(280,"\u8BF4\u660E"),n(),t(281,"th"),i(282,"\u7C7B\u578B"),n(),t(283,"th"),i(284,"\u9ED8\u8BA4\u503C"),n()()(),t(285,"tbody")(286,"tr")(287,"td"),i(288,"[nzTreeNodeDefWhen]"),n(),t(289,"td"),i(290,"\u7528\u4E8E\u5B9A\u4E49\u662F\u5426\u4F7F\u7528\u6B64\u8282\u70B9\u7684\u65B9\u6CD5\uFF0C\u4F18\u5148\u5339\u914D\u7B2C\u4E00\u4E2A\u8FD4\u56DE "),t(291,"code"),i(292,"true"),n(),i(293," \u7684\u8282\u70B9\u3002\u5982\u679C\u6CA1\u6709\u8FD4\u56DE "),t(294,"code"),i(295,"true"),n(),i(296," \u7684\u8282\u70B9\uFF0C\u5219\u5339\u914D\u672A\u5B9A\u4E49\u6B64\u65B9\u6CD5\u7684\u8282\u70B9\u3002"),n(),t(297,"td")(298,"code"),i(299,"(index: number, nodeData: T) => boolean"),n()(),t(300,"td"),i(301,"-"),n()()()(),t(302,"h3",49)(303,"span"),i(304,"nz-tree-node"),n(),t(305,"label",39),i(306,"component"),n(),t(307,"a",50),i(308,"#"),n()(),t(309,"p"),i(310,"\u6811\u8282\u70B9\u5BB9\u5668\u7EC4\u4EF6\uFF0C\u9700\u8981\u901A\u8FC7 "),t(311,"code"),i(312,"nzTreeNodeDef"),n(),i(313," \u6307\u4EE4\u5B9A\u4E49\u3002"),n(),t(314,"h3",51)(315,"span"),i(316,"[nzTreeNodePadding]"),n(),t(317,"label",47),i(318,"directive"),n(),t(319,"a",52),i(320,"#"),n()(),t(321,"pre",53)(322,"code")(323,"span",54)(324,"span",54)(325,"span",20),i(326,"<"),n(),i(327,"nz-tree-node"),n(),i(328," "),t(329,"span",55),i(330,"nzTreeNodePadding"),n(),t(331,"span",20),i(332,">"),n()(),t(333,"span",54)(334,"span",54)(335,"span",20),i(336,"</"),n(),i(337,"nz-tree-node"),n(),t(338,"span",20),i(339,">"),n()()()(),t(340,"p"),i(341,"\u4EE5\u6DFB\u52A0 "),t(342,"code"),i(343,"padding"),n(),i(344," \u7684\u65B9\u5F0F\u663E\u793A\u8282\u70B9\u7F29\u8FDB "),t(345,"strong"),i(346,"\u6027\u80FD\u6700\u597D"),n(),i(347,"\u3002"),n(),t(348,"h3",56)(349,"span"),i(350,"nzTreeNodeIndentLine"),n(),t(351,"a",57),i(352,"#"),n()(),t(353,"pre",53)(354,"code")(355,"span",54)(356,"span",54)(357,"span",20),i(358,"<"),n(),i(359,"nz-tree-node"),n(),i(360," "),t(361,"span",55),i(362,"nzTreeNodeIndentLine"),n(),t(363,"span",20),i(364,">"),n()(),t(365,"span",54)(366,"span",54)(367,"span",20),i(368,"</"),n(),i(369,"nz-tree-node"),n(),t(370,"span",20),i(371,">"),n()()()(),t(372,"p"),i(373,"\u4EE5\u6DFB\u52A0\u7F29\u8FDB\u7EBF\u7684\u65B9\u5F0F\u663E\u793A\u8282\u70B9\u7F29\u8FDB\u3002"),n(),t(374,"h3",58)(375,"span"),i(376,"nz-tree-node-toggle"),n(),t(377,"label",39),i(378,"component"),n(),t(379,"a",59),i(380,"#"),n()(),t(381,"p"),i(382,"\u5207\u6362\u90E8\u5206\uFF0C\u7528\u4E8E\u8282\u70B9\u7684\u5C55\u5F00/\u6536\u8D77\u3002"),n(),t(383,"table")(384,"thead")(385,"tr")(386,"th"),i(387,"\u53C2\u6570"),n(),t(388,"th"),i(389,"\u8BF4\u660E"),n(),t(390,"th"),i(391,"\u7C7B\u578B"),n(),t(392,"th"),i(393,"\u9ED8\u8BA4\u503C"),n()()(),t(394,"tbody")(395,"tr")(396,"td"),i(397,"[nzTreeNodeToggleRecursive]"),n(),t(398,"td"),i(399,"\u662F\u5426\u4E3A\u9012\u5F52\u5C55\u5F00/\u6536\u8D77"),n(),t(400,"td")(401,"code"),i(402,"boolean"),n()(),t(403,"td")(404,"code"),i(405,"false"),n()()()()(),t(406,"h3",60)(407,"span"),i(408,"nz-tree-node-toggle[nzTreeNodeNoopToggle]"),n(),t(409,"label",39),i(410,"component"),n(),t(411,"a",61),i(412,"#"),n()(),t(413,"p"),i(414,"\u4E0D\u505A\u4EFB\u4F55\u64CD\u4F5C\u7684\u5207\u6362\u90E8\u5206\uFF0C\u53EF\u7528\u4E8E\u5360\u4F4D\u6216\u8005\u663E\u793A\u56FE\u6807\u3002"),n(),t(415,"h3",62)(416,"span"),i(417,"[nztreenodetogglerotateicon]"),n(),t(418,"label",47),i(419,"directive"),n(),t(420,"a",63),i(421,"#"),n()(),t(422,"p"),i(423,"\u5B9A\u4E49\u5207\u6362\u90E8\u5206\u4E2D\u7684\u56FE\u6807\uFF0C\u4F1A\u968F\u7740\u5C55\u5F00\u6536\u8D77\u72B6\u6001\u81EA\u52A8\u65CB\u8F6C\u3002"),n(),t(424,"h3",64)(425,"span"),i(426,"[nztreenodetoggleactiveicon]"),n(),t(427,"label",47),i(428,"directive"),n(),t(429,"a",65),i(430,"#"),n()(),t(431,"p"),i(432,"\u5B9A\u4E49\u5207\u6362\u90E8\u5206\u4E2D\u7684\u56FE\u6807\uFF0C\u4F7F\u5176\u5177\u6709\u6FC0\u6D3B\u72B6\u6001\u7684\u6837\u5F0F\uFF0C\u53EF\u7528\u4E8E loading \u56FE\u6807\u3002"),n(),t(433,"h3",66)(434,"span"),i(435,"nz-tree-node-option"),n(),t(436,"label",39),i(437,"component"),n(),t(438,"a",67),i(439,"#"),n()(),t(440,"p"),i(441,"\u5B9A\u4E49\u8282\u70B9\u4E2D\u7684\u53EF\u9009\u62E9\u90E8\u5206\u3002"),n(),t(442,"table")(443,"thead")(444,"tr")(445,"th"),i(446,"\u53C2\u6570"),n(),t(447,"th"),i(448,"\u8BF4\u660E"),n(),t(449,"th"),i(450,"\u7C7B\u578B"),n(),t(451,"th"),i(452,"\u9ED8\u8BA4\u503C"),n()()(),t(453,"tbody")(454,"tr")(455,"td"),i(456,"[nzSelected]"),n(),t(457,"td"),i(458,"\u662F\u5426\u9009\u4E2D"),n(),t(459,"td")(460,"code"),i(461,"boolean"),n()(),t(462,"td")(463,"code"),i(464,"false"),n()()(),t(465,"tr")(466,"td"),i(467,"[nzDisabled]"),n(),t(468,"td"),i(469,"\u662F\u5426\u7981\u7528"),n(),t(470,"td")(471,"code"),i(472,"boolean"),n()(),t(473,"td")(474,"code"),i(475,"false"),n()()(),t(476,"tr")(477,"td"),i(478,"(nzClick)"),n(),t(479,"td"),i(480,"\u70B9\u51FB\u65F6\u7684\u4E8B\u4EF6"),n(),t(481,"td")(482,"code"),i(483,"EventEmitter<MouseEvent>"),n()(),t(484,"td"),i(485,"-"),n()()()(),t(486,"h3",68)(487,"span"),i(488,"nz-tree-node-checkbox"),n(),t(489,"label",39),i(490,"component"),n(),t(491,"a",69),i(492,"#"),n()(),t(493,"p"),i(494,"\u5B9A\u4E49\u8282\u70B9\u4E2D\u7684\u53EF\u52FE\u9009\u7684\u90E8\u5206\u3002"),n(),t(495,"table")(496,"thead")(497,"tr")(498,"th"),i(499,"\u53C2\u6570"),n(),t(500,"th"),i(501,"\u8BF4\u660E"),n(),t(502,"th"),i(503,"\u7C7B\u578B"),n(),t(504,"th"),i(505,"\u9ED8\u8BA4\u503C"),n()()(),t(506,"tbody")(507,"tr")(508,"td"),i(509,"[nzChecked]"),n(),t(510,"td"),i(511,"\u662F\u5426\u52FE\u9009"),n(),t(512,"td")(513,"code"),i(514,"boolean"),n()(),t(515,"td")(516,"code"),i(517,"false"),n()()(),t(518,"tr")(519,"td"),i(520,"[nzIndeterminate]"),n(),t(521,"td"),i(522,"\u662F\u5426\u4E3A\u534A\u9009"),n(),t(523,"td")(524,"code"),i(525,"boolean"),n()(),t(526,"td")(527,"code"),i(528,"false"),n()()(),t(529,"tr")(530,"td"),i(531,"[nzDisabled]"),n(),t(532,"td"),i(533,"\u662F\u5426\u7981\u7528"),n(),t(534,"td")(535,"code"),i(536,"boolean"),n()(),t(537,"td")(538,"code"),i(539,"false"),n()()(),t(540,"tr")(541,"td"),i(542,"(nzClick)"),n(),t(543,"td"),i(544,"\u70B9\u51FB\u65F6\u7684\u4E8B\u4EF6"),n(),t(545,"td")(546,"code"),i(547,"EventEmitter<MouseEvent>"),n()(),t(548,"td"),i(549,"-"),n()()()(),t(550,"h2",70)(551,"span"),i(552,"Classes"),n(),t(553,"a",71),i(554,"#"),n()(),t(555,"h3",72)(556,"span")(557,"strong"),i(558,"NzTreeFlatDataSource extends DataSource"),n()(),t(559,"a",73),i(560,"#"),n()(),t(561,"h3",74)(562,"span"),i(563,"\u6784\u9020\u53C2\u6570"),n(),t(564,"a",75),i(565,"#"),n()(),t(566,"table")(567,"thead")(568,"tr")(569,"th"),i(570,"\u540D\u79F0"),n(),t(571,"th"),i(572,"\u8BF4\u660E"),n()()(),t(573,"tbody")(574,"tr")(575,"td")(576,"code"),i(577,"treeControl: FlatTreeControl<F, K>"),n()(),t(578,"td"),i(579,"Tree \u63A7\u5236\u5668"),n()(),t(580,"tr")(581,"td")(582,"code"),i(583,"treeFlattener: NzTreeFlattener<T, F, K>"),n()(),t(584,"td"),i(585,"\u7528\u4E8E\u5C06\u5D4C\u5957\u8282\u70B9 "),t(586,"code"),i(587,"T"),n(),i(588," \u5904\u7406\u4E3A\u6241\u5E73\u8282\u70B9 "),t(589,"code"),i(590,"F"),n(),i(591," \u7684\u5C55\u5E73\u5668"),n()(),t(592,"tr")(593,"td")(594,"code"),i(595,"initialData: T[] = []"),n()(),t(596,"td"),i(597,"\u521D\u59CB\u5316\u6570\u636E"),n()()()(),t(598,"h3",76)(599,"span"),i(600,"\u65B9\u6CD5"),n(),t(601,"a",77),i(602,"#"),n()(),t(603,"table")(604,"thead")(605,"tr")(606,"th"),i(607,"\u540D\u79F0"),n(),t(608,"th"),i(609,"\u8BF4\u660E"),n()()(),t(610,"tbody")(611,"tr")(612,"td")(613,"code"),i(614,"connect(collectionViewer: CollectionViewer): Observable<F[]>"),n()(),t(615,"td"),i(616,"TreeView \u7EC4\u4EF6\u4E2D\u8C03\u7528\uFF0C\u7528\u4E8E\u83B7\u53D6\u6570\u636E\u7684\u66F4\u65B0"),n()(),t(617,"tr")(618,"td")(619,"code"),i(620,"disconnect(): void"),n()(),t(621,"td"),i(622,"TreeView \u7EC4\u4EF6\u9500\u6BC1\u65F6\u8C03\u7528"),n()(),t(623,"tr")(624,"td")(625,"code"),i(626,"setData(value: T[]): void"),n()(),t(627,"td"),i(628,"\u8BBE\u7F6E\u539F\u59CB\u6570\u636E"),n()(),t(629,"tr")(630,"td")(631,"code"),i(632,"getData(): T[]"),n()(),t(633,"td"),i(634,"\u83B7\u53D6\u539F\u59CB\u6570\u636E"),n()()()(),t(635,"h3",78)(636,"span")(637,"strong"),i(638,"NzTreeFlattener"),n()(),t(639,"a",79),i(640,"#"),n()(),t(641,"p"),i(642,"\u5C06\u5177\u6709\u5B50\u8282\u70B9\u7684\u5D4C\u5957\u6570\u636E\u8F6C\u6362\u4E3A\u5177\u6709\u7EA7\u522B\uFF08level\uFF09\u4FE1\u606F\u7684\u8F6C\u6362\u5668\u7C7B\u3002"),n(),t(643,"h3",74)(644,"span"),i(645,"\u6784\u9020\u53C2\u6570"),n(),t(646,"a",75),i(647,"#"),n()(),t(648,"table")(649,"thead")(650,"tr")(651,"th"),i(652,"\u540D\u79F0"),n(),t(653,"th"),i(654,"\u8BF4\u660E"),n()()(),t(655,"tbody")(656,"tr")(657,"td")(658,"code"),i(659,"transformFunction: (node: T, level: number) => F"),n()(),t(660,"td"),i(661,"\u63A5\u6536\u4E00\u4E2A\u5D4C\u5957\u8282\u70B9\uFF0C\u8FD4\u56DE\u6241\u5E73\u8282\u70B9"),n()(),t(662,"tr")(663,"td")(664,"code"),i(665,"getLevel: (node: F) => number"),n()(),t(666,"td"),i(667,"\u5B9A\u4E49\u83B7\u53D6 "),t(668,"code"),i(669,"level"),n(),i(670," \u5C5E\u6027\u7684\u65B9\u6CD5"),n()(),t(671,"tr")(672,"td")(673,"code"),i(674,"isExpandable: (node: F) => boolean"),n()(),t(675,"td"),i(676,"\u5B9A\u4E49\u662F\u5426\u4E3A\u53EF\u5C55\u5F00\u8282\u70B9\u7684\u65B9\u6CD5"),n()(),t(677,"tr")(678,"td")(679,"code"),i(680,"getChildren: (node: T) => Observable<T[]> | T[] | undefined | null"),n()(),t(681,"td"),i(682,"\u5B9A\u4E49\u4ECE\u5D4C\u5957\u6570\u636E\u4E2D\u83B7\u53D6\u5B50\u8282\u70B9\u7684\u65B9\u6CD5"),n()()()(),t(683,"h3",76)(684,"span"),i(685,"\u65B9\u6CD5"),n(),t(686,"a",77),i(687,"#"),n()(),t(688,"table")(689,"thead")(690,"tr")(691,"th"),i(692,"\u540D\u79F0"),n(),t(693,"th"),i(694,"\u8BF4\u660E"),n()()(),t(695,"tbody")(696,"tr")(697,"td")(698,"code"),i(699,"flattenNodes(structuredData: T[]): F[]"),n()(),t(700,"td"),i(701,"\u63A5\u6536\u5D4C\u5957\u6570\u636E\uFF0C\u8FD4\u56DE\u6241\u5E73\u6570\u636E"),n()(),t(702,"tr")(703,"td")(704,"code"),i(705,"expandFlattenedNodes(nodes: F[], treeControl: TreeControl<F, K>): F[]"),n()(),t(706,"td"),i(707,"\u6309 TreeControl \u4E2D\u7684\u5C55\u5F00\u72B6\u6001\u83B7\u53D6\u8282\u70B9"),n()()()(),S(),n()()),r&2&&(c(),m("nzOffsetTop",16),c(),m("nzAffix",!1),c(48),m("nzGutter",16),c(),m("nzXl",12)("nzSpan",24),c(),m("nzId","components-tree-view-demo-basic")("nzLink","components-tree-view-demo-basic")("nzIframeHeight",null)("nzHref","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/tree-view/demo/basic.md"),c(5),m("nzId","components-tree-view-demo-directory")("nzLink","components-tree-view-demo-directory")("nzIframeHeight",null)("nzHref","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/tree-view/demo/directory.md"),c(5),m("nzId","components-tree-view-demo-line")("nzLink","components-tree-view-demo-line")("nzIframeHeight",null)("nzHref","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/tree-view/demo/line.md"),c(5),m("nzId","components-tree-view-demo-search")("nzLink","components-tree-view-demo-search")("nzIframeHeight",null)("nzHref","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/tree-view/demo/search.md"),c(5),m("nzXl",12)("nzSpan",24),c(),m("nzId","components-tree-view-demo-checkbox")("nzLink","components-tree-view-demo-checkbox")("nzIframeHeight",null)("nzHref","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/tree-view/demo/checkbox.md"),c(5),m("nzId","components-tree-view-demo-dynamic")("nzLink","components-tree-view-demo-dynamic")("nzIframeHeight",null)("nzHref","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/tree-view/demo/dynamic.md"),c(5),m("nzId","components-tree-view-demo-editable")("nzLink","components-tree-view-demo-editable")("nzIframeHeight",null)("nzHref","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/tree-view/demo/editable.md"),c(5),m("nzId","components-tree-view-demo-virtual-scroll")("nzLink","components-tree-view-demo-virtual-scroll")("nzIframeHeight",null)("nzHref","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/tree-view/demo/virtual-scroll.md"))},dependencies:[qe,ce,Qe,Ue,Ze,We,je,Oe,D,tt,nt,it,rt,ot,at,dt,st],encapsulation:2})}}return a})();var Cn=(()=>{class a{constructor(){this.expanded=!1}goLink(e){window&&(window.location.hash=e)}expandAllCode(){this.expanded=!this.expanded,this.codeBoxes.forEach(e=>e.expandCode(this.expanded))}static{this.\u0275fac=function(r){return new(r||a)}}static{this.\u0275cmp=z({type:a,selectors:[["nz-demo-tree-view"]],viewQuery:function(r,o){if(r&1&&J(ce,5),r&2){let l;Z(l=Q())&&(o.codeBoxes=l)}},decls:708,vars:39,consts:[[1,"toc-affix",3,"nzOffsetTop"],["nzShowInkInFixed","",3,"nzClick","nzAffix"],["nzHref","#components-tree-view-demo-basic","nzTitle","basic"],["nzHref","#components-tree-view-demo-checkbox","nzTitle","checkbox"],["nzHref","#components-tree-view-demo-directory","nzTitle","Directory"],["nzHref","#components-tree-view-demo-dynamic","nzTitle","Load data asynchronously"],["nzHref","#components-tree-view-demo-line","nzTitle","Tree with line"],["nzHref","#components-tree-view-demo-editable","nzTitle","editable"],["nzHref","#components-tree-view-demo-search","nzTitle","search"],["nzHref","#components-tree-view-demo-virtual-scroll","nzTitle","Virtual Scroll"],["nzHref","#api","nzTitle","API"],[1,"markdown"],[1,"subtitle"],[1,"widget"],["aria-label","Edit this page on Github","href","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/tree-view/doc/index.en-US.md","target","_blank","rel","noopener noreferrer",1,"edit-button"],["nzType","edit"],["id","when-to-use"],["onclick","window.location.hash = 'when-to-use'",1,"anchor"],[1,"language-ts"],[1,"token","keyword"],[1,"token","punctuation"],[1,"token","string"],["nz-icon","","nzType","appstore","nz-tooltip","","nzTooltipTitle","Expand All Code",1,"code-box-expand-trigger",3,"click"],["nz-row","",3,"nzGutter"],["nz-col","",3,"nzXl","nzSpan"],["nzTitle","basic","nzSelector","nz-demo-tree-view-basic","nzGenerateCommand","ng g ng-zorro-antd:tree-view-basic <name>","nzComponentName","NzDemoTreeViewBasicComponent","nzIframeSource","null",3,"nzId","nzLink","nzIframeHeight","nzHref"],["demo",""],["intro",""],["nzTitle","Directory","nzSelector","nz-demo-tree-view-directory","nzGenerateCommand","ng g ng-zorro-antd:tree-view-directory <name>","nzComponentName","NzDemoTreeViewDirectoryComponent","nzIframeSource","null",3,"nzId","nzLink","nzIframeHeight","nzHref"],["nzTitle","Tree with line","nzSelector","nz-demo-tree-view-line","nzGenerateCommand","ng g ng-zorro-antd:tree-view-line <name>","nzComponentName","NzDemoTreeViewLineComponent","nzIframeSource","null",3,"nzId","nzLink","nzIframeHeight","nzHref"],["nzTitle","search","nzSelector","nz-demo-tree-view-search","nzGenerateCommand","ng g ng-zorro-antd:tree-view-search <name>","nzComponentName","NzDemoTreeViewSearchComponent","nzIframeSource","null",3,"nzId","nzLink","nzIframeHeight","nzHref"],["nzTitle","checkbox","nzSelector","nz-demo-tree-view-checkbox","nzGenerateCommand","ng g ng-zorro-antd:tree-view-checkbox <name>","nzComponentName","NzDemoTreeViewCheckboxComponent","nzIframeSource","null",3,"nzId","nzLink","nzIframeHeight","nzHref"],["nzTitle","Load data asynchronously","nzSelector","nz-demo-tree-view-dynamic","nzGenerateCommand","ng g ng-zorro-antd:tree-view-dynamic <name>","nzComponentName","NzDemoTreeViewDynamicComponent","nzIframeSource","null",3,"nzId","nzLink","nzIframeHeight","nzHref"],["nzTitle","editable","nzSelector","nz-demo-tree-view-editable","nzGenerateCommand","ng g ng-zorro-antd:tree-view-editable <name>","nzComponentName","NzDemoTreeViewEditableComponent","nzIframeSource","null",3,"nzId","nzLink","nzIframeHeight","nzHref"],["nzTitle","Virtual Scroll","nzSelector","nz-demo-tree-view-virtual-scroll","nzGenerateCommand","ng g ng-zorro-antd:tree-view-virtual-scroll <name>","nzComponentName","NzDemoTreeViewVirtualScrollComponent","nzIframeSource","null",3,"nzId","nzLink","nzIframeHeight","nzHref"],[1,"markdown","api-container"],["id","api"],["onclick","window.location.hash = 'api'",1,"anchor"],["id","nz-tree-view"],[1,"api-type-label","component"],["onclick","window.location.hash = 'nz-tree-view'",1,"anchor"],["href","https://material.angular.io/cdk/tree/api#TreeControl","target","_blank","rel","noopener"],["href","https://material.angular.io/cdk/tree/overview#data-source","target","_blank","rel","noopener"],["id","nz-tree-virtual-scroll-view"],["onclick","window.location.hash = 'nz-tree-virtual-scroll-view'",1,"anchor"],["href","https://material.angular.io/cdk/scrolling/api#CdkVirtualScrollViewport","target","_blank","rel","noopener"],["id","[nztreenodedef]"],[1,"api-type-label","directive"],["onclick","window.location.hash = '[nztreenodedef]'",1,"anchor"],["id","nz-tree-node"],["onclick","window.location.hash = 'nz-tree-node'",1,"anchor"],["id","[nztreenodepadding]"],["onclick","window.location.hash = '[nztreenodepadding]'",1,"anchor"],[1,"language-html"],[1,"token","tag"],[1,"token","attr-name"],["id","nztreenodeindentline"],["onclick","window.location.hash = 'nztreenodeindentline'",1,"anchor"],["id","nz-tree-node-toggle"],["onclick","window.location.hash = 'nz-tree-node-toggle'",1,"anchor"],["id","nz-tree-node-toggle[nztreenodenooptoggle]"],["onclick","window.location.hash = 'nz-tree-node-toggle[nztreenodenooptoggle]'",1,"anchor"],["id","[nztreenodetogglerotateicon]"],["onclick","window.location.hash = '[nztreenodetogglerotateicon]'",1,"anchor"],["id","[nztreenodetoggleactiveicon]"],["onclick","window.location.hash = '[nztreenodetoggleactiveicon]'",1,"anchor"],["id","nz-tree-node-option"],["onclick","window.location.hash = 'nz-tree-node-option'",1,"anchor"],["id","nz-tree-node-checkbox"],["onclick","window.location.hash = 'nz-tree-node-checkbox'",1,"anchor"],["id","classes"],["onclick","window.location.hash = 'classes'",1,"anchor"],["id","<strong>nztreeflatdatasource-extends-datasource</strong>"],["onclick","window.location.hash = '<strong>nztreeflatdatasource-extends-datasource</strong>'",1,"anchor"],["id","construction-parameters"],["onclick","window.location.hash = 'construction-parameters'",1,"anchor"],["id","methods"],["onclick","window.location.hash = 'methods'",1,"anchor"],["id","<strong>nztreeflattener</strong>"],["onclick","window.location.hash = '<strong>nztreeflattener</strong>'",1,"anchor"]],template:function(r,o){r&1&&(t(0,"article")(1,"nz-affix",0)(2,"nz-anchor",1),g("nzClick",function(s){return o.goLink(s)}),u(3,"nz-link",2)(4,"nz-link",3)(5,"nz-link",4)(6,"nz-link",5)(7,"nz-link",6)(8,"nz-link",7)(9,"nz-link",8)(10,"nz-link",9)(11,"nz-link",10),n()(),t(12,"section",11)(13,"h1"),i(14,"Tree View"),u(15,"span",12)(16,"span",13),t(17,"a",14),u(18,"nz-icon",15),n()(),t(19,"section",11),_(),t(20,"h2",16)(21,"span"),i(22,"When To Use"),n(),t(23,"a",17),i(24,"#"),n()(),t(25,"p"),i(26,`More basic Tree component, allowing each of its parts to be defined in the template, and state to be managed manually.
With better performance and customizability.`),n(),t(27,"pre",18)(28,"code")(29,"span",19),i(30,"import"),n(),i(31," "),t(32,"span",20),i(33,"{"),n(),i(34," NzTreeViewModule "),t(35,"span",20),i(36,"}"),n(),i(37," "),t(38,"span",19),i(39,"from"),n(),i(40," "),t(41,"span",21),i(42,"'ng-zorro-antd/tree-view'"),n(),t(43,"span",20),i(44,";"),n()()(),S(),n(),t(45,"h2")(46,"span"),i(47,"Examples"),n(),t(48,"span",22),g("click",function(){return o.expandAllCode()}),n()()(),t(49,"div",23)(50,"div",24)(51,"nz-code-box",25),u(52,"nz-demo-tree-view-basic",26),t(53,"div",27),_(),t(54,"p"),i(55,"The most basic usage including select, disable and expand features."),n(),S(),n()(),t(56,"nz-code-box",28),u(57,"nz-demo-tree-view-directory",26),t(58,"div",27),_(),t(59,"p"),i(60,"Directory tree."),n(),S(),n()(),t(61,"nz-code-box",29),u(62,"nz-demo-tree-view-line",26),t(63,"div",27),_(),t(64,"p"),i(65,"Tree with connected line between nodes."),n(),S(),n()(),t(66,"nz-code-box",30),u(67,"nz-demo-tree-view-search",26),t(68,"div",27),_(),t(69,"p"),i(70,"Searchable Tree."),n(),S(),n()()(),t(71,"div",24)(72,"nz-code-box",31),u(73,"nz-demo-tree-view-checkbox",26),t(74,"div",27),_(),t(75,"p"),i(76,"Tree with checkboxes."),n(),S(),n()(),t(77,"nz-code-box",32),u(78,"nz-demo-tree-view-dynamic",26),t(79,"div",27),_(),t(80,"p"),i(81,"To load data asynchronously when click to expand a treeNode."),n(),S(),n()(),t(82,"nz-code-box",33),u(83,"nz-demo-tree-view-editable",26),t(84,"div",27),_(),t(85,"p"),i(86,"Tree with add and delete actions."),n(),S(),n()(),t(87,"nz-code-box",34),u(88,"nz-demo-tree-view-virtual-scroll",26),t(89,"div",27),_(),t(90,"p"),i(91,"Use virtual scroll."),n(),S(),n()()()(),t(92,"section",35),_(),t(93,"h2",36)(94,"span"),i(95,"API"),n(),t(96,"a",37),i(97,"#"),n()(),t(98,"h3",38)(99,"span"),i(100,"nz-tree-view"),n(),t(101,"label",39),i(102,"component"),n(),t(103,"a",40),i(104,"#"),n()(),t(105,"table")(106,"thead")(107,"tr")(108,"th"),i(109,"Property"),n(),t(110,"th"),i(111,"Description"),n(),t(112,"th"),i(113,"Type"),n(),t(114,"th"),i(115,"Default"),n()()(),t(116,"tbody")(117,"tr")(118,"td"),i(119,"[nzTreeControl]"),n(),t(120,"td"),i(121,"The tree controller"),n(),t(122,"td")(123,"a",41),i(124,"TreeControl"),n()(),t(125,"td"),i(126,"-"),n()(),t(127,"tr")(128,"td"),i(129,"[nzDataSource]"),n(),t(130,"td"),i(131,"The data array to render"),n(),t(132,"td")(133,"a",42),i(134,"DataSource"),n(),i(135,"<T>"),n(),t(136,"td"),i(137,"Observable<T[]>"),n()(),t(138,"tr")(139,"td"),i(140,"[nzDirectoryTree]"),n(),t(141,"td"),i(142,"Whether nodes are displayed as directory style"),n(),t(143,"td")(144,"code"),i(145,"boolean"),n()(),t(146,"td")(147,"code"),i(148,"false"),n()()(),t(149,"tr")(150,"td"),i(151,"[nzBlockNode]"),n(),t(152,"td"),i(153,"Whether tree nodes fill remaining horizontal space"),n(),t(154,"td")(155,"code"),i(156,"boolean"),n()(),t(157,"td")(158,"code"),i(159,"false"),n()()()()(),t(160,"h3",43)(161,"span"),i(162,"nz-tree-virtual-scroll-view"),n(),t(163,"label",39),i(164,"component"),n(),t(165,"a",44),i(166,"#"),n()(),t(167,"p"),i(168,`The virtual scroll tree view, which can be accessed from
the `),t(169,"a",45),i(170,"CdkVirtualScrollViewport"),n(),i(171,` instance through
the `),t(172,"code"),i(173,"virtualScrollViewport"),n(),i(174," member of the component instance."),n(),t(175,"table")(176,"thead")(177,"tr")(178,"th"),i(179,"Property"),n(),t(180,"th"),i(181,"Description"),n(),t(182,"th"),i(183,"Type"),n(),t(184,"th"),i(185,"Default"),n()()(),t(186,"tbody")(187,"tr")(188,"td"),i(189,"[nzTreeControl]"),n(),t(190,"td"),i(191,"The tree controller"),n(),t(192,"td")(193,"a",41),i(194,"TreeControl"),n()(),t(195,"td"),i(196,"-"),n()(),t(197,"tr")(198,"td"),i(199,"[nzDataSource]"),n(),t(200,"td"),i(201,"The data array to render"),n(),t(202,"td")(203,"a",42),i(204,"DataSource"),n(),i(205,"<T>"),n(),t(206,"td"),i(207,"Observable<T[]>"),n()(),t(208,"tr")(209,"td"),i(210,"[nzDirectoryTree]"),n(),t(211,"td"),i(212,"Whether nodes are displayed as directory style"),n(),t(213,"td")(214,"code"),i(215,"boolean"),n()(),t(216,"td")(217,"code"),i(218,"false"),n()()(),t(219,"tr")(220,"td"),i(221,"[nzBlockNode]"),n(),t(222,"td"),i(223,"Whether tree nodes fill remaining horizontal space"),n(),t(224,"td")(225,"code"),i(226,"boolean"),n()(),t(227,"td")(228,"code"),i(229,"false"),n()()(),t(230,"tr")(231,"td"),i(232,"[nzItemSize]"),n(),t(233,"td"),i(234,"The size of nodes in the tree (in pixels)"),n(),t(235,"td")(236,"code"),i(237,"number"),n()(),t(238,"td")(239,"code"),i(240,"28"),n()()(),t(241,"tr")(242,"td"),i(243,"[nzMinBufferPx]"),n(),t(244,"td"),i(245,"The minimum amount of buffer rendered allowed outside the viewport (in pixels)"),n(),t(246,"td")(247,"code"),i(248,"number"),n()(),t(249,"td")(250,"code"),i(251,"28 * 5"),n()()(),t(252,"tr")(253,"td"),i(254,"[nzMaxBufferPx]"),n(),t(255,"td"),i(256,"The amount of buffer required for rendering new nodes (in pixels)"),n(),t(257,"td")(258,"code"),i(259,"number"),n()(),t(260,"td")(261,"code"),i(262,"28 * 10"),n()()()()(),t(263,"h3",46)(264,"span"),i(265,"[nzTreeNodeDef]"),n(),t(266,"label",47),i(267,"directive"),n(),t(268,"a",48),i(269,"#"),n()(),t(270,"p"),i(271,"Directive to define "),t(272,"code"),i(273,"nz-tree-node"),n(),i(274,"."),n(),t(275,"table")(276,"thead")(277,"tr")(278,"th"),i(279,"Property"),n(),t(280,"th"),i(281,"Description"),n(),t(282,"th"),i(283,"Type"),n(),t(284,"th"),i(285,"Default"),n()()(),t(286,"tbody")(287,"tr")(288,"td"),i(289,"[nzTreeNodeDefWhen]"),n(),t(290,"td"),i(291,"A matching function which indicates whether inputted node should be used. It matches the very first node that makes this function return "),t(292,"code"),i(293,"true"),n(),i(294,". If no nodes that makes this function return "),t(295,"code"),i(296,"true"),n(),i(297,", the node which does not define this function would be matched instead."),n(),t(298,"td")(299,"code"),i(300,"(index: number, nodeData: T) => boolean"),n()(),t(301,"td"),i(302,"-"),n()()()(),t(303,"h3",49)(304,"span"),i(305,"nz-tree-node"),n(),t(306,"label",39),i(307,"component"),n(),t(308,"a",50),i(309,"#"),n()(),t(310,"p"),i(311,"The tree node container component, which needs to be defined by the "),t(312,"code"),i(313,"nzTreeNodeDef"),n(),i(314," directive."),n(),t(315,"h3",51)(316,"span"),i(317,"[nzTreeNodePadding]"),n(),t(318,"label",47),i(319,"directive"),n(),t(320,"a",52),i(321,"#"),n()(),t(322,"pre",53)(323,"code")(324,"span",54)(325,"span",54)(326,"span",20),i(327,"<"),n(),i(328,"nz-tree-node"),n(),i(329," "),t(330,"span",55),i(331,"nzTreeNodePadding"),n(),t(332,"span",20),i(333,">"),n()(),t(334,"span",54)(335,"span",54)(336,"span",20),i(337,"</"),n(),i(338,"nz-tree-node"),n(),t(339,"span",20),i(340,">"),n()()()(),t(341,"p"),i(342,"Show node indentation by adding "),t(343,"code"),i(344,"padding"),n(),t(345,"strong"),i(346,"Best Performance"),n(),i(347,"."),n(),t(348,"h3",56)(349,"span"),i(350,"nzTreeNodeIndentLine"),n(),t(351,"a",57),i(352,"#"),n()(),t(353,"pre",53)(354,"code")(355,"span",54)(356,"span",54)(357,"span",20),i(358,"<"),n(),i(359,"nz-tree-node"),n(),i(360," "),t(361,"span",55),i(362,"nzTreeNodeIndentLine"),n(),t(363,"span",20),i(364,">"),n()(),t(365,"span",54)(366,"span",54)(367,"span",20),i(368,"</"),n(),i(369,"nz-tree-node"),n(),t(370,"span",20),i(371,">"),n()()()(),t(372,"p"),i(373,"Show node indentation by adding indent lines."),n(),t(374,"h3",58)(375,"span"),i(376,"nz-tree-node-toggle"),n(),t(377,"label",39),i(378,"component"),n(),t(379,"a",59),i(380,"#"),n()(),t(381,"p"),i(382,"A toggle which is used to expand / collapse the node."),n(),t(383,"table")(384,"thead")(385,"tr")(386,"th"),i(387,"Property"),n(),t(388,"th"),i(389,"Description"),n(),t(390,"th"),i(391,"Type"),n(),t(392,"th"),i(393,"Default"),n()()(),t(394,"tbody")(395,"tr")(396,"td"),i(397,"[nzTreeNodeToggleRecursive]"),n(),t(398,"td"),i(399,"Is it recursively expand / collapse"),n(),t(400,"td")(401,"code"),i(402,"boolean"),n()(),t(403,"td")(404,"code"),i(405,"false"),n()()()()(),t(406,"h3",60)(407,"span"),i(408,"nz-tree-node-toggle[nzTreeNodeNoopToggle]"),n(),t(409,"label",39),i(410,"component"),n(),t(411,"a",61),i(412,"#"),n()(),t(413,"p"),i(414,"A toggle that does no actions. This can be used for placeholders or displays icons."),n(),t(415,"h3",62)(416,"span"),i(417,"[nzTreeNodeToggleRotateIcon]"),n(),t(418,"label",47),i(419,"directive"),n(),t(420,"a",63),i(421,"#"),n()(),t(422,"p"),i(423,"Define an icon in the toggle, which it will automatically rotate depending on the collapse/expand state."),n(),t(424,"h3",64)(425,"span"),i(426,"[nzTreeNodeToggleActiveIcon]"),n(),t(427,"label",47),i(428,"directive"),n(),t(429,"a",65),i(430,"#"),n()(),t(431,"p"),i(432,"Define an icon in the toggle for an active style, which it can be used for the loading state."),n(),t(433,"h3",66)(434,"span"),i(435,"nz-tree-node-option"),n(),t(436,"label",39),i(437,"component"),n(),t(438,"a",67),i(439,"#"),n()(),t(440,"p"),i(441,"Define the selectable feature of a node."),n(),t(442,"table")(443,"thead")(444,"tr")(445,"th"),i(446,"Property"),n(),t(447,"th"),i(448,"Description"),n(),t(449,"th"),i(450,"Type"),n(),t(451,"th"),i(452,"Default"),n()()(),t(453,"tbody")(454,"tr")(455,"td"),i(456,"[nzSelected]"),n(),t(457,"td"),i(458,"Whether the option is selected"),n(),t(459,"td")(460,"code"),i(461,"boolean"),n()(),t(462,"td")(463,"code"),i(464,"false"),n()()(),t(465,"tr")(466,"td"),i(467,"[nzDisabled]"),n(),t(468,"td"),i(469,"Whether the option is disabled"),n(),t(470,"td")(471,"code"),i(472,"boolean"),n()(),t(473,"td")(474,"code"),i(475,"false"),n()()(),t(476,"tr")(477,"td"),i(478,"(nzClick)"),n(),t(479,"td"),i(480,"Event on click"),n(),t(481,"td")(482,"code"),i(483,"EventEmitter<MouseEvent>"),n()(),t(484,"td"),i(485,"-"),n()()()(),t(486,"h3",68)(487,"span"),i(488,"nz-tree-node-checkbox"),n(),t(489,"label",39),i(490,"component"),n(),t(491,"a",69),i(492,"#"),n()(),t(493,"p"),i(494,"Define the checkbox feature of a node."),n(),t(495,"table")(496,"thead")(497,"tr")(498,"th"),i(499,"Property"),n(),t(500,"th"),i(501,"Description"),n(),t(502,"th"),i(503,"Type"),n(),t(504,"th"),i(505,"Default"),n()()(),t(506,"tbody")(507,"tr")(508,"td"),i(509,"[nzChecked]"),n(),t(510,"td"),i(511,"Whether the checkbox is checked"),n(),t(512,"td")(513,"code"),i(514,"boolean"),n()(),t(515,"td")(516,"code"),i(517,"false"),n()()(),t(518,"tr")(519,"td"),i(520,"[nzDisabled]"),n(),t(521,"td"),i(522,"Whether the checkbox is disabled"),n(),t(523,"td")(524,"code"),i(525,"boolean"),n()(),t(526,"td")(527,"code"),i(528,"false"),n()()(),t(529,"tr")(530,"td"),i(531,"[nzIndeterminate]"),n(),t(532,"td"),i(533,"Whether the checkbox is indeterminate"),n(),t(534,"td")(535,"code"),i(536,"boolean"),n()(),t(537,"td")(538,"code"),i(539,"false"),n()()(),t(540,"tr")(541,"td"),i(542,"(nzClick)"),n(),t(543,"td"),i(544,"Event on click"),n(),t(545,"td")(546,"code"),i(547,"EventEmitter<MouseEvent>"),n()(),t(548,"td"),i(549,"-"),n()()()(),t(550,"h2",70)(551,"span"),i(552,"Classes"),n(),t(553,"a",71),i(554,"#"),n()(),t(555,"h3",72)(556,"span")(557,"strong"),i(558,"NzTreeFlatDataSource extends DataSource"),n()(),t(559,"a",73),i(560,"#"),n()(),t(561,"h3",74)(562,"span"),i(563,"Construction Parameters"),n(),t(564,"a",75),i(565,"#"),n()(),t(566,"table")(567,"thead")(568,"tr")(569,"th"),i(570,"Name"),n(),t(571,"th"),i(572,"Description"),n()()(),t(573,"tbody")(574,"tr")(575,"td")(576,"code"),i(577,"treeControl: FlatTreeControl<F, K>"),n()(),t(578,"td"),i(579,"The tree controller."),n()(),t(580,"tr")(581,"td")(582,"code"),i(583,"treeFlattener: NzTreeFlattener<T, F, K>"),n()(),t(584,"td"),i(585,"Flattener for convert nested nodes "),t(586,"code"),i(587,"T"),n(),i(588," into flattened nodes "),t(589,"code"),i(590,"F"),n(),i(591,"."),n()(),t(592,"tr")(593,"td")(594,"code"),i(595,"initialData: T[] = []"),n()(),t(596,"td"),i(597,"Initialized data."),n()()()(),t(598,"h3",76)(599,"span"),i(600,"Methods"),n(),t(601,"a",77),i(602,"#"),n()(),t(603,"table")(604,"thead")(605,"tr")(606,"th"),i(607,"Name"),n(),t(608,"th"),i(609,"Description"),n()()(),t(610,"tbody")(611,"tr")(612,"td")(613,"code"),i(614,"connect(collectionViewer: CollectionViewer): Observable<F[]>"),n()(),t(615,"td"),i(616,"Call from the TreeView component to listen for data updates."),n()(),t(617,"tr")(618,"td")(619,"code"),i(620,"disconnect(): void"),n()(),t(621,"td"),i(622,"Call when TreeView component is destroyed."),n()(),t(623,"tr")(624,"td")(625,"code"),i(626,"setData(value: T[]): void"),n()(),t(627,"td"),i(628,"Set the origin data"),n()(),t(629,"tr")(630,"td")(631,"code"),i(632,"getData(): T[]"),n()(),t(633,"td"),i(634,"Get the origin data"),n()()()(),t(635,"h3",78)(636,"span")(637,"strong"),i(638,"NzTreeFlattener"),n()(),t(639,"a",79),i(640,"#"),n()(),t(641,"p"),i(642,"Convert nested data with child nodes into node data with level information."),n(),t(643,"h3",74)(644,"span"),i(645,"Construction Parameters"),n(),t(646,"a",75),i(647,"#"),n()(),t(648,"table")(649,"thead")(650,"tr")(651,"th"),i(652,"Name"),n(),t(653,"th"),i(654,"Description"),n()()(),t(655,"tbody")(656,"tr")(657,"td")(658,"code"),i(659,"transformFunction: (node: T, level: number) => F"),n()(),t(660,"td"),i(661,"Receive a nested node and return a flattened node"),n()(),t(662,"tr")(663,"td")(664,"code"),i(665,"getLevel: (node: F) => number"),n()(),t(666,"td"),i(667,"Define the method to get the "),t(668,"code"),i(669,"level"),n(),i(670," property"),n()(),t(671,"tr")(672,"td")(673,"code"),i(674,"isExpandable: (node: F) => boolean"),n()(),t(675,"td"),i(676,"Methods for defining whether a node is expandable"),n()(),t(677,"tr")(678,"td")(679,"code"),i(680,"getChildren: (node: T) => Observable<T[]> | T[] | undefined | null"),n()(),t(681,"td"),i(682,"Define methods to get children nodes from nested node"),n()()()(),t(683,"h3",76)(684,"span"),i(685,"Methods"),n(),t(686,"a",77),i(687,"#"),n()(),t(688,"table")(689,"thead")(690,"tr")(691,"th"),i(692,"Name"),n(),t(693,"th"),i(694,"Description"),n()()(),t(695,"tbody")(696,"tr")(697,"td")(698,"code"),i(699,"flattenNodes(structuredData: T[]): F[]"),n()(),t(700,"td"),i(701,"Receive nested data and return flattened data"),n()(),t(702,"tr")(703,"td")(704,"code"),i(705,"expandFlattenedNodes(nodes: F[], treeControl: TreeControl<F, K>): F[]"),n()(),t(706,"td"),i(707,"Get flattened node data based on expansion status"),n()()()(),S(),n()()),r&2&&(c(),m("nzOffsetTop",16),c(),m("nzAffix",!1),c(47),m("nzGutter",16),c(),m("nzXl",12)("nzSpan",24),c(),m("nzId","components-tree-view-demo-basic")("nzLink","components-tree-view-demo-basic")("nzIframeHeight",null)("nzHref","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/tree-view/demo/basic.md"),c(5),m("nzId","components-tree-view-demo-directory")("nzLink","components-tree-view-demo-directory")("nzIframeHeight",null)("nzHref","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/tree-view/demo/directory.md"),c(5),m("nzId","components-tree-view-demo-line")("nzLink","components-tree-view-demo-line")("nzIframeHeight",null)("nzHref","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/tree-view/demo/line.md"),c(5),m("nzId","components-tree-view-demo-search")("nzLink","components-tree-view-demo-search")("nzIframeHeight",null)("nzHref","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/tree-view/demo/search.md"),c(5),m("nzXl",12)("nzSpan",24),c(),m("nzId","components-tree-view-demo-checkbox")("nzLink","components-tree-view-demo-checkbox")("nzIframeHeight",null)("nzHref","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/tree-view/demo/checkbox.md"),c(5),m("nzId","components-tree-view-demo-dynamic")("nzLink","components-tree-view-demo-dynamic")("nzIframeHeight",null)("nzHref","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/tree-view/demo/dynamic.md"),c(5),m("nzId","components-tree-view-demo-editable")("nzLink","components-tree-view-demo-editable")("nzIframeHeight",null)("nzHref","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/tree-view/demo/editable.md"),c(5),m("nzId","components-tree-view-demo-virtual-scroll")("nzLink","components-tree-view-demo-virtual-scroll")("nzIframeHeight",null)("nzHref","https://github.com/NG-ZORRO/ng-zorro-antd/edit/master/components/tree-view/demo/virtual-scroll.md"))},dependencies:[qe,ce,Qe,Ue,Ze,We,je,Oe,D,tt,nt,it,rt,ot,at,dt,st],encapsulation:2})}}return a})();var Ci=[{path:"en",component:Cn},{path:"zh",component:vn}],Bo=Ci;export{Bo as default};