open-nomad/ui/app/templates/components/fs/directory-entry.hbs
Buck Doyle 244157786a
Add explicit this to templates (#8388)
This is the result of running the no-implicit-this-codemod, some manual fixes,
and the addition of a linting rule to prevent future ambiguity.
2020-07-09 15:19:07 -05:00

16 lines
627 B
Handlebars

<tr data-test-entry>
<td>
<Fs::Link @allocation={{this.allocation}} @taskState={{this.taskState}} @path={{this.pathToEntry}}>
{{#if this.entry.IsDir}}
{{x-icon "folder-outline"}}
{{else}}
{{x-icon "file-outline"}}
{{/if}}
<span class="name" data-test-name>{{this.entry.Name}}</span>
</Fs::Link>
</td>
<td class="has-text-right" data-test-size>{{#unless this.entry.IsDir}}{{format-bytes this.entry.Size}}{{/unless}}</td>
<td class="has-text-right" title={{format-ts this.entry.ModTime}} data-test-last-modified>{{moment-from this.entry.ModTime interval=1000}}</td>
</tr>