cipchk / ng-tree-antd Goto Github PK
View Code? Open in Web Editor NEWA antd style of based on angular-tree-component.
Home Page: https://cipchk.github.io/ng-tree-antd/
License: MIT License
A antd style of based on angular-tree-component.
Home Page: https://cipchk.github.io/ng-tree-antd/
License: MIT License
默认节点展开,这个有设置的属性吗?
$ ng build -prod
ERROR in ..\ng-tree-antd\index.ts(10,2): Error during template compile of 'NzTreeModule'
Function calls are not supported in decorators but 'ɵmakeDecorator' was called in 'NgModule'
'NgModule' calls 'ɵmakeDecorator'.
为什么异步加载的数据显示不出来呢?
ERROR in Error at /Users/hanzhendong/workspace/web/angular-webapp/pclearner/node_modules/ng-tree-antd/components/nz-tree.component.d.ts.NzTreeComponent.html(59,13): ("
<ng-container
[ngTemplateOutlet]="nzTitle"
[ERROR ->][ngOutletContext]="{ $implicit: node, node: node, index: index }">
")
angular5 ng build --prod
你好,我查了angular2-tree关于自定义图标,有人说用custom template可以,https://angular2-tree.readme.io/discuss/58945fe1f4de7c1b003265bb
我在nztree上试了下 不生效,看源代码发现nztree封装了ng-template,这是不是以为这我不能在nztree上使用ng-template了。
我的需求是在node上带一个属性,然后根据属性应用不同的font-icon来显示图标。
谢谢
看ng-alain项目里面有好几个icon库,但是simple-line-icons可以显示在menu的左边,用antd自带的icon不会显示在菜单旁
NzTreeComponent.html:42 ERROR TypeError: angularTreeComponent.TREE_ACTIONS.TOGGLE_ACTIVE is not a function
at click (ng-tree-antd.umd.js:108)
at TreeNode.mouseAction (tree-node.model.js:366)
at Object.eval [as handleEvent] (NzTreeComponent.html:46)
at handleEvent (core.js:13581)
at callWithDebugContext (core.js:15090)
at Object.debugHandleEvent [as handleEvent] (core.js:14677)
at dispatchEvent (core.js:9990)
at eval (core.js:10611)
at HTMLSpanElement.eval (platform-browser.js:2628)
at ZoneDelegate.invokeTask (zone.js:421)
i dont find any method?
业务要求,节点返回的不一定是checked,比如可能是allow、enabled等,所以能不能增加一个像idField那样的checkField的选项,谢谢
checkbox不存在的时候
How to select all nodes by default?
expandAll();树全部展开怎么去掉展开动画?测试后发现数据越多树的展开速度越慢,怎么样能加快树的展开速度?谢谢
错误信息为:The only valid numeric escape in strict mode is '\0', and this must not be followed by a decimal digit.
Angular 已经不支持 IE6IE8,因此,使用 "\9" 这样的 hack 去区别并兼容 IE7IE8 的样式已经没有必要了。反而这个 "\9" 在Safari浏览下面会引起字符串解析的Exception。
I goes just as document say,nothing different,but the error below happen!
I don't knnown what wrong with my code.
Error: Uncaught (in promise): TypeError: Object(...) is not a function
TypeError: Object(...) is not a function
at http://localhost:8100/build/0.js:89717:122
at Object. (http://localhost:8100/build/0.js:89719:2)
at webpack_require (http://localhost:8100/build/vendor.js:55:30)
at Object. (http://localhost:8100/build/0.js:89051:80)
at webpack_require (http://localhost:8100/build/vendor.js:55:30)
at Object. (http://localhost:8100/build/0.js:215161:81)
at webpack_require (http://localhost:8100/build/vendor.js:55:30)
at Object. (http://localhost:8100/build/0.js:164045:79)
at webpack_require (http://localhost:8100/build/vendor.js:55:30)
at Object. (http://localhost:8100/build/0.js:154457:72)
at c (http://localhost:8100/build/polyfills.js:3:19752)
at c (http://localhost:8100/build/polyfills.js:3:19461)
at http://localhost:8100/build/polyfills.js:3:20233
at t.invokeTask (http://localhost:8100/build/polyfills.js:3:15660)
at Object.onInvokeTask (http://localhost:8100/build/vendor.js:5126:33)
at t.invokeTask (http://localhost:8100/build/polyfills.js:3:15581)
at r.runTask (http://localhost:8100/build/polyfills.js:3:10834)
at o (http://localhost:8100/build/polyfills.js:3:7894)
引入ng-tree-antd 并使用checkbox属性的时候发现颜色还是蓝色,而不是系统目前选择的其他主题色。
https://cipchk.github.io/ng-alain/#/elements/tree-antd 验证过 也是一样,作者好像是在css里写死了
@cipchk 你好
能否支持设置:选中所有字节点时不自动关联选中父节点,只有用户主动选中才选中。
环境:
"angular-tree-component": "^5.1.2",
"ng-zorro-antd": "^0.6.0-rc.2",
"ng-tree-antd": "^1.0.0",
已在AppModule引入NzTreeModule
使用nz-tree组件:
<nz-tree [nzNodes]="nodes" [nzShowLine]="true" (nzEvent)="onEvent($event)">
编译可以通过,浏览器控制台出现:
Uncaught Error: Template parse errors:
Can't bind to 'nzNodes' since it isn't a known property of 'nz-tree'.
1. If 'nz-tree' is an Angular component and it has 'nzNodes' input, then verify that it is part of this module.
2. If 'nz-tree' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.
3. To allow any property add 'NO_ERRORS_SCHEMA' to the '@NgModule.schemas' of this component. ("<nz-tree [ERROR ->][nzNodes]="nodes" [nzShowLine]="true" (nzEvent)="onEvent($event)"></nz-tree>"): ng:///HomeRoutingModule/OrganComponent.html@0:9
Can't bind to 'nzShowLine' since it isn't a known property of 'nz-tree'.
1. If 'nz-tree' is an Angular component and it has 'nzShowLine' input, then verify that it is part of this module.
2. If 'nz-tree' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.
3. To allow any property add 'NO_ERRORS_SCHEMA' to the '@NgModule.schemas' of this component. ("<nz-tree [nzNodes]="nodes" [ERROR ->][nzShowLine]="true" (nzEvent)="onEvent($event)"></nz-tree>"): ng:///HomeRoutingModule/OrganComponent.html@0:27
'nz-tree' is not a known element:
1. If 'nz-tree' is an Angular component, then verify that it is part of this module.
2. If 'nz-tree' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message. ("[ERROR ->]<nz-tree [nzNodes]="nodes" [nzShowLine]="true" (nzEvent)="onEvent($event)"></nz-tree>"): ng:///HomeRoutingModule/OrganComponent.html@0:0
this.nzTreeComponent.treeModel.setState({selectedLeafNodeIds,activeNodeIds});
这样设置的话,treeModel里面的selectedLeafNodeIds属性值变了,但是复选框没有被选中
ERROR Error: Uncaught (in promise): Error: [mobx] MobX 5+ requires Proxy objects. If your environment doesn't support Proxy objects, please downgrade to MobX 4.
angular-tree-component should be placed into dependencies of package.json?
How to get all selected nodes, such as the id of all selected nodes
There are 3 levels menu. Do the operations:
expect all items are unchecked but the top remains intermedian.
I found everything OK in angular-tree-component
demo page.
如题,能否简要说明下步骤和工具 谢谢。
设置了isExpanded属性为true二级菜单一直再转
这个nzloading 应该写在html 中的哪里?
ERROR in node_modules/@angular/core/src/render3/ng_dev_mode.d.ts(9,11): error TS2451: Cannot redeclare block-scoped variable 'ngDevMode'.
node_modules/ng-tree-antd/node_modules/@angular/core/src/render3/ng_dev_mode.d.ts(9,11): error TS2451: Cannot redeclare block-scoped variable 'ngDevMode'.
我暂时锁到2.0.0版本,没有报错。
在后台项目里树控件用的很多,现在也已提供了check的属性和事件,但是无法获取tree控件的全部checked状态的节点
请问可否增加右键菜单
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.