Skip to content

Commit

Permalink
feat(module:tree-select): support nzCheckStrictly property (#4149)
Browse files Browse the repository at this point in the history
close #4120
  • Loading branch information
hsuanxyz authored and vthinkxie committed Oct 12, 2019
1 parent 8345c54 commit 1f8cf1d
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions components/tree-select/doc/index.en-US.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ import { NzTreeSelectModule } from 'ng-zorro-antd/tree-select';
| `[nzHideUnMatched]` | Hide unmatched nodes while searching | `boolean` | `false` ||
| `[nzSize]` | To set the size of the select input | `'large' \| 'small' \| 'default'` | `'default'` ||
| `[nzCheckable]` | Whether to show checkbox on the treeNodes | `boolean` | `false` |
| `[nzCheckStrictly]` | Check treeNode precisely; parent treeNode and children treeNodes are not associated | `boolean` | `false` |
| `[nzShowExpand]` | Show a Expand Icon before the treeNodes | `boolean` | `true` | |
| `[nzShowLine]` | Shows a connecting line | `boolean` | `false` | |
| `[nzAsyncData]` | Load data asynchronously (should be used with NzTreeNode.addChildren(...)) | `boolean` | `false` |
Expand Down
1 change: 1 addition & 0 deletions components/tree-select/doc/index.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ import { NzTreeSelectModule } from 'ng-zorro-antd/tree-select';
| `[nzHideUnMatched]` | 搜索隐藏未匹配的节点 | `boolean` | `false` ||
| `[nzSize]` | 选择框大小 | `'large' \| 'small' \| 'default'` | `'default'` ||
| `[nzCheckable]` | 节点前添加 Checkbox 复选框 | `boolean` | `false` |
| `[nzCheckStrictly]` | checkable 状态下节点选择完全受控(父子节点选中状态不再关联) | `boolean` | `false` |
| `[nzShowExpand]` | 节点前添加展开图标 | `boolean` | `true` | |
| `[nzShowLine]` | 是否展示连接线 | `boolean` | `false` | |
| `[nzAsyncData]` | 是否异步加载(显示加载状态) | `boolean` | `false` |
Expand Down
1 change: 1 addition & 0 deletions components/tree-select/nz-tree-select.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@
[nzCheckedKeys]="nzCheckable ? value : []"
[nzSelectedKeys]="!nzCheckable ? value : []"
[nzTreeTemplate]="treeTemplate"
[nzCheckStrictly]="nzCheckStrictly"
(nzExpandChange)="onExpandedKeysChange($event)"
(nzClick)="nzTreeClick.emit($event)"
(nzCheckedKeysChange)="updateSelectedNodes()"
Expand Down
1 change: 1 addition & 0 deletions components/tree-select/nz-tree-select.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@ export class NzTreeSelectComponent extends NzTreeBase implements ControlValueAcc
@Input() @InputBoolean() nzAsyncData = false;
@Input() @InputBoolean() nzMultiple = false;
@Input() @InputBoolean() nzDefaultExpandAll = false;
@Input() @InputBoolean() nzCheckStrictly = false;
@Input() nzExpandedIcon: TemplateRef<{ $implicit: NzTreeNode }>;
@Input() nzNotFoundContent: string;
@Input() nzNodes: Array<NzTreeNode | NzTreeNodeOptions> = [];
Expand Down

0 comments on commit 1f8cf1d

Please sign in to comment.