diff --git a/app/assets/javascripts/discourse/app/templates/topic.hbs b/app/assets/javascripts/discourse/app/templates/topic.hbs index aa362ea5d04..a830830a10e 100644 --- a/app/assets/javascripts/discourse/app/templates/topic.hbs +++ b/app/assets/javascripts/discourse/app/templates/topic.hbs @@ -72,7 +72,7 @@ filterable=true categoryId=this.buffered.category_id minimum=this.minimumRequiredTags - filterPlaceholder="topic_edit.tag_filter_placeholder" + filterPlaceholder="tagging.choose_for_topic" useHeaderFilter=true }} /> diff --git a/app/assets/javascripts/discourse/tests/integration/components/select-kit/mini-tag-chooser-test.js b/app/assets/javascripts/discourse/tests/integration/components/select-kit/mini-tag-chooser-test.js index 876ed6b859a..29a68d284a3 100644 --- a/app/assets/javascripts/discourse/tests/integration/components/select-kit/mini-tag-chooser-test.js +++ b/app/assets/javascripts/discourse/tests/integration/components/select-kit/mini-tag-chooser-test.js @@ -206,6 +206,25 @@ module( assert.dom(".select-kit-collection").doesNotExist(); assert.dom(".select-kit-header button[data-name='apple']").doesNotExist(); assert.strictEqual(this.subject.header().value(), "orange,potato"); + + assert + .dom(".select-kit-header .filter-input") + .hasAttribute( + "placeholder", + "", + "Placeholder is empty when there is a selection" + ); + + await click(".select-kit-header button[data-name='orange']"); + await click(".select-kit-header button[data-name='potato']"); + + assert + .dom(".select-kit-header .filter-input") + .hasAttribute( + "placeholder", + "Search...", + "Placeholder is back to default when there is no selection" + ); }); } ); diff --git a/app/assets/javascripts/select-kit/addon/components/multi-select/multi-select-filter.hbs b/app/assets/javascripts/select-kit/addon/components/multi-select/multi-select-filter.hbs index d0f57faf828..f9099884900 100644 --- a/app/assets/javascripts/select-kit/addon/components/multi-select/multi-select-filter.hbs +++ b/app/assets/javascripts/select-kit/addon/components/multi-select/multi-select-filter.hbs @@ -5,7 +5,7 @@ {{else}} diff --git a/config/locales/client.en.yml b/config/locales/client.en.yml index 5e273dfb02b..ef0a16fe7ba 100644 --- a/config/locales/client.en.yml +++ b/config/locales/client.en.yml @@ -3900,8 +3900,6 @@ en: personal_message: title: "This topic is a personal message" help: "This topic is a personal message" - topic_edit: - tag_filter_placeholder: "+ tag" posts: "Posts" pending_posts: label: "Pending" diff --git a/plugins/styleguide/assets/javascripts/discourse/components/sections/atoms/dropdowns.hbs b/plugins/styleguide/assets/javascripts/discourse/components/sections/atoms/dropdowns.hbs index 4167556bfa8..ea750997bbe 100644 --- a/plugins/styleguide/assets/javascripts/discourse/components/sections/atoms/dropdowns.hbs +++ b/plugins/styleguide/assets/javascripts/discourse/components/sections/atoms/dropdowns.hbs @@ -138,7 +138,7 @@ @value={{@dummy.selectedTags}} @options={{hash filterable=true - filterPlaceholder="topic_edit.tag_filter_placeholder" + filterPlaceholder="tagging.choose_for_topic" useHeaderFilter=true }} />