github.com/anth0d/nomad@v0.0.0-20221214183521-ae3a0a2cad06/ui/app/components/das/task-row.hbs (about) 1 <tr 2 class={{if @active 'active'}} 3 {{on 'click' @onClick}} 4 {{did-insert this.calculateHeight}} 5 data-test-task-toggles 6 > 7 <td class="task-cell" data-test-name colspan="2">{{@task.name}}</td> 8 <td class="toggle-cell"> 9 <Toggle 10 data-test-cpu-toggle 11 @isActive={{@cpu.isActive}} 12 @onToggle={{action @toggleRecommendation @cpu.recommendation}} 13 @isDisabled={{not @cpu.recommendation}} 14 title={{concat 'CPU for ' @task.name}} 15 /> 16 </td> 17 <td class="toggle-cell"> 18 <Toggle 19 data-test-memory-toggle 20 @isActive={{@memory.isActive}} 21 @onToggle={{action @toggleRecommendation @memory.recommendation}} 22 @isDisabled={{not @memory.recommendation}} 23 title={{concat 'Memory for ' @task.name}} 24 /> 25 26 {{#if (and @active this.height)}} 27 <svg width={{this.height}} height={{this.height}}> 28 <rect class="border-cover" x="0" y="1" height={{this.borderCoverHeight}} /> 29 <polyline class="triangle" points="1 1 {{this.half}} {{this.half}} 1 {{this.height}}" /> 30 </svg> 31 {{/if}} 32 </td> 33 </tr>