Page MenuHomec4science

action.component.html
No OneTemporary

File Metadata

Created
Thu, May 2, 05:41

action.component.html

<div class="action" *ngIf="actions">
<div class="button" *ngFor="let action of actions.response_handlers">
<button (click)="sendChange(action)" [title]="action.description" [disabled]="words.length ==0">{{action.action_name}}</button>
</div>
<select *ngIf="actions.pages" (change)="changePage($event.target.value)">
<option *ngFor="let page of actions.pages" [selected]="page == actions.target_file" [ngValue]="page">{{page}}</option>
</select>
<div class="word" *ngFor="let word of words">
<table>
<tr>
<td><button (click)="removeWord(word)">x</button></td>
<td class="td-attr" *ngIf="word.tp_id">id: {{word.id}}</td>
<td class="td-attr" *ngIf="word.fp_id">
<select (change)="updateWord(word, $event.target.value)">
<option *ngFor="let id of getWordIds()" [selected]="id === word.id" [ngValue]="id">{{id}}</option>
</select>
</td>
<td class="td-longer-attr"><input type="checkbox" [(ngModel)]="word.deleted" [checked]="word.deleted" />deleted</td>
<td>
<label> ln:
<input [(ngModel)]="word.line" type="number" size="4"/>
</label>
</td>
<td class="td-word">{{word.text}}</td>
<td class="td-word" *ngIf="word.edited_text">edited text: {{word.edited_text}}</td>
<td class="td-word" *ngIf="word.earlier_version">v0: {{word.earlier_version}}</td>
<td class="td-word" *ngIf="word.overwrites_word">over: {{word.overwrites_word}}</td>
<td class="td-word" *ngIf="word.tp_id">tp_id: {{word.tp_id}}</td>
<td class="td-word" *ngIf="word.fp_id">fp_id: {{word.fp_id}}</td>
<td class="td-word" *ngIf="word.part_text">part: {{word.part_text}}</td>
<td class="td-word" *ngIf="word.deletion_path">path: {{word.deletion_path}}</td>
<td class="td-word" *ngIf="word.paths_near_word" (change)="addDeletionPath(word, $event.target.value)">
<select>
<option [selected]="true" [value]=""></option>
<option *ngFor="let path of word.paths_near_word">{{path}}</option>
</select>
</td>
<td>
<label> left:
<input [(ngModel)]="word.left" type="number" size="4"/>
</label>
</td>
<td>
<label> top:
<input [(ngModel)]="word.top" type="number" size="4"/>
</label>
</td>
</tr>
</table>
</div>
<div class="message-board" *ngIf="actions.result && words.length == 0">{{actions.result}}</div>
</div>
<div class="requirement" *ngIf="response_handler">
<h4>Add extra information in order to {{response_handler.action_name}}</h4>
<div *ngFor="let requirement of response_handler.requirements">
<label>{{requirement.name}}
<input [type]="requirement.type == 'boolean' ? 'checkbox' : 'text'" [(ngModel)]="requirement.input" />
</label>
</div>
<button (click)="sendChange(response_handler)">send</button>
<button (click)="resetResponseHandler()">cancel</button>
</div>

Event Timeline