diff --git a/about.json b/about.json index cc16158..219ee4d 100644 --- a/about.json +++ b/about.json @@ -1,8 +1,8 @@ { - "name": "Search Banner", + "name": "Advanced Search Banner", "component": true, - "about_url": "https://meta.discourse.org/t/search-banner-theme-component/122939", - "license_url": "https://github.com/discourse/discourse-search-banner/blob/master/LICENSE", + "about_url": "https://meta.discourse.org/t/-/122939", + "license_url": "https://github.com/discourse/discourse-search-banner/blob/main/LICENSE", "assets": {}, "color_schemes": {} } diff --git a/common/common.scss b/common/common.scss index 50ff36b..b75fcaf 100644 --- a/common/common.scss +++ b/common/common.scss @@ -163,5 +163,9 @@ $max-width: 600px; } } +.welcome-banner { + display: none; +} + // these are add-on styles controlled by settings @import "special-styles"; diff --git a/locales/en.yml b/locales/en.yml index 08ee1e3..9e9e5bb 100644 --- a/locales/en.yml +++ b/locales/en.yml @@ -3,3 +3,5 @@ en: headline: "Welcome to our community" subhead: "We're happy to have you here. If you need help, please search before you post." search_button_text: "" + theme_metadata: + description: "Advanced Search Banner puts a search bar along with optional headline and subhead text in a banner above the main topic list navigation" diff --git a/spec/system/viewing_search_banner_spec.rb b/spec/system/viewing_search_banner_spec.rb index 6131a33..25bd5ab 100644 --- a/spec/system/viewing_search_banner_spec.rb +++ b/spec/system/viewing_search_banner_spec.rb @@ -5,7 +5,7 @@ fab!(:topic) let(:topic_page) { PageObjects::Pages::Topic.new } - xit "should display the search banner below the site header when `plugin_outlet` theme setting is set to `below-site-header`" do + it "should display the search banner below the site header when `plugin_outlet` theme setting is set to `below-site-header`" do theme.update_setting(:plugin_outlet, "below-site-header") theme.save! @@ -15,7 +15,7 @@ expect(page).to_not have_css("#main-outlet .custom-search-banner") end - xit "should display the search banner above the main container when `plugin_outlet` theme setting is set to `above-main-container`" do + it "should display the search banner above the main container when `plugin_outlet` theme setting is set to `above-main-container`" do theme.update_setting(:plugin_outlet, "above-main-container") theme.save! @@ -24,7 +24,7 @@ expect(page).to have_css("#main-outlet .custom-search-banner") end - xit "should display the search icon when searching within a topic when search button text is present" do + it "should display the search icon when searching within a topic when search button text is present" do theme.update_setting(:show_on, "all") theme.update_translation("search_banner.search_button_text", "Foo") theme.save! diff --git a/test/acceptance/search-banner-test.js b/test/acceptance/search-banner-test.js index b0170b1..fc6fd65 100644 --- a/test/acceptance/search-banner-test.js +++ b/test/acceptance/search-banner-test.js @@ -2,10 +2,10 @@ import { click, fillIn, triggerKeyEvent, visit } from "@ember/test-helpers"; import { test } from "qunit"; import { acceptance, query } from "discourse/tests/helpers/qunit-helpers"; -acceptance("Discourse Search Banner", function (needs) { +acceptance("Discourse Advanced Search Banner", function (needs) { needs.user({ admin: true, experimental_search_menu_groups_enabled: true }); - test("Search Banner is present", async function (assert) { + test("Advanced Search Banner is present", async function (assert) { await visit("/"); assert.dom(".custom-search-banner input#search-term").exists(); });