/
githubmirror
/
socket.io
Обзор
Документация
Войти
/
githubmirror
/
socket.io
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
examples/basic-crud-application/angular-client/src/app/app.component.html
24 строки
2 KB
Damien Arrachequesne
docs(examples): upgrade basic-crud-application to Angular v17
21 ноя 2023, 16:15
Не верифицирован
21 ноя 2023, 16:15
3848280
Код
Авторство
О чём код?
<section class="todoapp"> <header class="header"> <h1>todos</h1> <!-- <input class="new-todo" placeholder="What needs to be done?" autofocus="" [(ngModel)]="newTodoText" (keyup.enter)="addTodo()">--> <input class="new-todo" placeholder="What needs to be done?" autofocus="" [formControl]="newTodoText" (keyup.enter)="addTodo()"> </header> <section class="main" *ngIf="todoStore.todos.length > 0"> <input id="toggle-all" class="toggle-all" type="checkbox" *ngIf="todoStore.todos.length" #toggleall [checked]="todoStore.allCompleted()" (click)="todoStore.setAllTo(toggleall.checked)"> <ul class="todo-list"> <li *ngFor="let todo of todoStore.todos" [class.completed]="todo.completed" [class.editing]="todo.editing"> <div class="view"> <input class="toggle" type="checkbox" (click)="toggleCompletion(todo)" [checked]="todo.completed"> <label (dblclick)="editTodo(todo)">{{todo.title}}</label> <button class="destroy" (click)="remove(todo)"></button> </div> <input class="edit" *ngIf="todo.editing" [value]="todo.title" #editedtodo (blur)="stopEditing(todo, editedtodo.value)" (keyup.enter)="updateEditingTodo(todo, editedtodo.value)" (keyup.escape)="cancelEditingTodo(todo)"> </li> </ul> </section> <footer class="footer" *ngIf="todoStore.todos.length > 0"> <span class="todo-count"><strong>{{todoStore.getRemaining().length}}</strong> {{todoStore.getRemaining().length == 1 ? 'item' : 'items'}} left</span> <button class="clear-completed" *ngIf="todoStore.getCompleted().length > 0" (click)="removeCompleted()">Clear completed</button> </footer> </section>