mirror of
https://github.com/discourse/discourse.git
synced 2024-11-29 04:18:24 +08:00
1c87bb7fe9
1. Use `this.` instead of `{{action}}` where applicable 2. Use `{{fn}}` instead of `@actionParam` where applicable 3. Use non-`@` versions of class/type/tabindex/aria-controls/aria-expanded 4. Remove `btn` class (it's added automatically to all DButtons) 5. Remove `type="button"` (it's the default) 6. Use `concat-class` helper
54 lines
1.3 KiB
Handlebars
54 lines
1.3 KiB
Handlebars
<div class="admin-emojis">
|
|
<h1>{{i18n "admin.emoji.title"}}</h1>
|
|
|
|
<p class="desc">{{i18n "admin.emoji.help"}}</p>
|
|
|
|
<EmojiUploader
|
|
@emojiGroups={{this.emojiGroups}}
|
|
@done={{action "emojiUploaded"}}
|
|
@id="emoji-uploader"
|
|
/>
|
|
|
|
<hr />
|
|
|
|
{{#if this.sortedEmojis}}
|
|
<table id="custom_emoji">
|
|
<thead>
|
|
<tr>
|
|
<th>{{i18n "admin.emoji.image"}}</th>
|
|
<th>{{i18n "admin.emoji.name"}}</th>
|
|
<th colspan="2">
|
|
<ComboBox
|
|
@value={{this.filter}}
|
|
@content={{this.sortingGroups}}
|
|
@nameProperty={{null}}
|
|
@valueProperty={{null}}
|
|
@onChange={{action "filterGroups"}}
|
|
/>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{{#each this.sortedEmojis as |e|}}
|
|
<tr>
|
|
<td><img
|
|
class="emoji emoji-custom"
|
|
src={{e.url}}
|
|
title={{e.name}}
|
|
alt={{i18n "admin.emoji.alt"}}
|
|
/></td>
|
|
<td>:{{e.name}}:</td>
|
|
<td>{{e.group}}</td>
|
|
<td class="action">
|
|
<DButton
|
|
@action={{fn this.destroyEmoji e}}
|
|
@icon="far-trash-alt"
|
|
class="btn-danger"
|
|
/>
|
|
</td>
|
|
</tr>
|
|
{{/each}}
|
|
</tbody>
|
|
</table>
|
|
{{/if}}
|
|
</div> |