DEV: remove slightly less trivial {{action}} usages (#24289)

Follow-up to #24278 that is slightly less trivial.

* Some were "trivial" usages that were missed in the previous PR because the same file that had at least one other non-trivial usage.
* These involve extra arguments or inheritance but I have checked that they seem correct.
This commit is contained in:
Godfrey Chan
2023-11-13 04:29:20 -08:00
committed by GitHub
parent fcafc8872f
commit 8444c865e9
20 changed files with 31 additions and 31 deletions

View File

@ -26,7 +26,7 @@
id="public-channels-caret"
role="button"
title="toggle nav list"
{{on "click" (action "toggleChannelSection" "public-channels")}}
{{on "click" (fn this.toggleChannelSection "public-channels")}}
data-toggleable="public-channels"
>
{{d-icon "angle-up"}}
@ -86,7 +86,7 @@
title="toggle nav list"
{{on
"click"
(action "toggleChannelSection" "direct-message-channels")
(fn this.toggleChannelSection "direct-message-channels")
}}
data-toggleable="direct-message-channels"
>

View File

@ -43,7 +43,7 @@
<DcFilterInput
@class="filter-input"
@filterAction={{action "debouncedFiltering"}}
@filterAction={{this.debouncedFiltering}}
@icons={{hash right="search"}}
placeholder={{i18n "chat.browse.filter_input_placeholder"}}
{{did-insert (action this.focusFilterInput)}}

View File

@ -18,7 +18,7 @@
}}
@type="text"
@value={{this.editedName}}
{{on "input" (action "onChangeChatChannelName" value="target.value")}}
{{on "input" this.onChangeChatChannelName}}
/>
</div>
@ -34,7 +34,7 @@
name="channel-slug"
class="chat-channel-edit-name-slug-modal__slug-input"
placeholder={{this.autoGeneratedSlug}}
{{on "input" (action "onChangeChatChannelSlug" value="target.value")}}
{{on "input" this.onChangeChatChannelSlug}}
@type="text"
@value={{this.editedSlug}}
/>

View File

@ -57,9 +57,9 @@ export default class ChatModalEditChannelName extends Component {
}
@action
onChangeChatChannelName(title) {
onChangeChatChannelName(event) {
this.flash = null;
this.#debouncedGenerateSlug(title);
this.#debouncedGenerateSlug(event?.target?.value);
}
@action

View File

@ -53,7 +53,7 @@
}}</label>
<Textarea
@value={{this.pollOptionsText}}
{{on "input" (action "onOptionsTextChange")}}
{{on "input" this.onOptionsTextChange}}
/>
{{#if this.showMinNumOfOptionsValidation}}
{{#unless this.minNumOfOptionsValidation.ok}}