-
Notifications
You must be signed in to change notification settings - Fork 165
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(page: right-control): completed todo item can be hide #4
Conversation
https://tirelyl.github.io/today-ng-steps online demo |
名称 | ||
<ul nz-menu> | ||
<li nz-menu-item (click)="toggleCompletedHide()"> | ||
{{ completedHide ? '显示以完成' : '隐藏已完成' }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
错别字
<nz-dropdown [nzPlacement]="'bottomRight'"> | ||
<a nz-dropdown> | ||
排序 | ||
更多设置 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
叫设置就可以了
最好设置 icon
@@ -1,6 +1,6 @@ | |||
<nz-list *ngIf="todos.length > 0" [nzDataSource]="todos" [nzRenderItem]="item" [nzItemLayout]="'horizontal'"> | |||
<ng-template #item let-item> | |||
<nz-list-item class="todo-item" (click)="click(item._id)" (contextmenu)="contextMenu($event, todoContextRef, item._id)"> | |||
<nz-list-item *ngIf="!(item.completedFlag && completedHide)" class="todo-item" (click)="click(item._id)" (contextmenu)="contextMenu($event, todoContextRef, item._id)"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这样的代码把决定该显示什么东西的算法分离到模板当中, 但是更多的算法在组件类里, 分离会造成后续不易维护.
No description provided.