Skip to content

Commit 2e7b000

Browse files
authored
UX: make sure search banner is visible (#56)
* UX: adjustment for search banner changes * DEV: remove support for 'Discourse Showcased Categories' * fix linting
1 parent e34ce85 commit 2e7b000

File tree

4 files changed

+5
-86
lines changed

4 files changed

+5
-86
lines changed

README.md

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -20,14 +20,6 @@ In the options for the `discourse-search-banner` theme component, following chan
2020
> As of Oct. 4th, 2022: The outlet will be auto-set by the Mint theme
2121
- `background image` can be set as per your requirement
2222

23-
### Discourse Showcased Categories
24-
25-
In the options for the `Showcased Categories` theme component, following changes are required for this theme to render properly:
26-
27-
- select the `feed one category` and `feed two category` as per your requirement
28-
- fill in the `feed one title` and `feed two title` as per your requirement
29-
- recommended value for `max list length` is `3`.
30-
3123
## 🖼️ Screenshots
3224

3325
### Homepage (categories)

about.json

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,6 @@
2323
"hover": "1c302b"
2424
}
2525
},
26-
"components": [
27-
"https://github.com/discourse/discourse-showcased-categories.git",
28-
"https://github.com/discourse/discourse-search-banner.git"
29-
],
26+
"components": ["https://github.com/discourse/discourse-search-banner.git"],
3027
"screenshots": ["screenshots/light.png", "screenshots/dark.png"]
3128
}

common/common.scss

Lines changed: 4 additions & 67 deletions
Original file line numberDiff line numberDiff line change
@@ -25,54 +25,6 @@
2525
border-radius: 10px;
2626
}
2727

28-
.custom-homepage-columns {
29-
margin: 2em 0 2em 0;
30-
padding: 0;
31-
display: none;
32-
33-
.col {
34-
position: relative;
35-
border-radius: var(--mint-border-radius);
36-
padding: 2em 2em 1em;
37-
border-top: 8px solid var(--tertiary);
38-
box-shadow:
39-
0 8px 60px 0 rgb(103, 151, 255, 0.1),
40-
0 12px 90px 0 rgb(133, 255, 103, 0.1);
41-
42-
@include mint-card-bg;
43-
44-
.header-wrapper {
45-
background-color: transparent;
46-
47-
a h2 {
48-
color: var(--primary);
49-
}
50-
51-
.btn-primary {
52-
display: none;
53-
}
54-
}
55-
56-
.btn-more {
57-
color: var(--secondary);
58-
background: var(--tertiary);
59-
transition: all 0.3s linear;
60-
border-radius: var(--mint-border-radius);
61-
text-transform: uppercase;
62-
border: 1px solid var(--tertiary);
63-
64-
&:hover {
65-
color: var(--secondary);
66-
background: var(--tertiary-hover);
67-
}
68-
}
69-
}
70-
71-
.loading-container:not(:has(.spinner)) {
72-
min-height: unset;
73-
}
74-
}
75-
7628
.navigation-categories .search-banner {
7729
border-radius: var(--mint-border-radius);
7830
height: 350px;
@@ -208,6 +160,10 @@ a {
208160
}
209161
}
210162

163+
.list-controls {
164+
margin-top: 1em;
165+
}
166+
211167
.list-controls .combo-box .combo-box-header {
212168
border: none;
213169
border-radius: var(--mint-border-radius);
@@ -384,10 +340,6 @@ a:hover {
384340
color: var(--primary-very-low);
385341
}
386342

387-
.btn[href] {
388-
color: var(--secondary);
389-
}
390-
391343
summary.select-kit-header.single-select-header.dropdown-select-box-header {
392344
padding: 0.5em;
393345
}
@@ -402,18 +354,3 @@ summary.select-kit-header.single-select-header.dropdown-select-box-header {
402354
border: 1px dashed var(--tertiary);
403355
}
404356
}
405-
406-
// Control order of plugin connectors
407-
.search-banner {
408-
display: none;
409-
}
410-
411-
.mint-component-extensions {
412-
.search-banner {
413-
display: block;
414-
}
415-
416-
.custom-homepage-columns {
417-
display: flex;
418-
}
419-
}

javascripts/discourse/connectors/above-main-container/mint-component-extensions.gjs

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,6 @@ import Component from "@ember/component";
22
import { classNames } from "@ember-decorators/component";
33
import { optionalRequire } from "discourse/lib/utilities";
44

5-
const TwoTopicList = optionalRequire(
6-
"discourse/plugins/discourse-showcased-categories/discourse/components/two-topic-list"
7-
);
85
const SearchBanner = optionalRequire(
96
"discourse/plugins/discourse-search-banner/discourse/components/search-banner"
107
);
@@ -17,9 +14,5 @@ export default class MintComponentExtensions extends Component {
1714
<SearchBanner />
1815
</div>
1916
{{/if}}
20-
21-
{{#if TwoTopicList}}
22-
<TwoTopicList />
23-
{{/if}}
2417
</template>
2518
}

0 commit comments

Comments
 (0)