@@ -3,11 +3,6 @@ window.addEventListener("DOMContentLoaded", () => {
3
3
const searchModalEl = document . getElementById ( "search" ) ;
4
4
const root = document . documentElement ;
5
5
6
- // Get the current doc platform
7
- const activePlatform = document
8
- . getElementsByTagName ( "meta" )
9
- [ "docsearch:platform" ] . getAttribute ( "content" ) ;
10
-
11
6
// Set search page title
12
7
// TODO: Do the right way
13
8
const pageName = document
@@ -103,8 +98,8 @@ window.addEventListener("DOMContentLoaded", () => {
103
98
initialUiState : {
104
99
minio : {
105
100
refinementList : {
106
- platform : [ activePlatform ] ,
107
- site : "docs"
101
+ site : "docs" ,
102
+ edition : "community" ,
108
103
} ,
109
104
} ,
110
105
} ,
@@ -128,17 +123,6 @@ window.addEventListener("DOMContentLoaded", () => {
128
123
if ( query !== "" ) {
129
124
// Make search modal active
130
125
searchModalEl . classList . add ( "search--focused" ) ;
131
-
132
- // Clear the filters and select the active platform
133
- setTimeout ( ( ) => {
134
- const activeFilterEl = document . querySelector (
135
- ".search__filters__checkbox[value='" + activePlatform + "']"
136
- ) ;
137
-
138
- if ( activeFilterEl && ! activeFilterEl . checked ) {
139
- activeFilterEl . click ( ) ;
140
- }
141
- } , 50 ) ;
142
126
} else {
143
127
// Clear the filters
144
128
clearRefinements ( ) ;
@@ -201,7 +185,6 @@ window.addEventListener("DOMContentLoaded", () => {
201
185
</i>
202
186
<div class="search__hits__text">
203
187
<div class="search__hits__title">${ data . _highlightResult . hierarchy . lvl1 . value } </div>
204
- <div class="search__hits__platform">${ data . platform } </div>
205
188
</div>
206
189
` ;
207
190
}
@@ -219,7 +202,6 @@ window.addEventListener("DOMContentLoaded", () => {
219
202
<div class="search__hits__text">
220
203
<div class="search__hits__title">${ data . _highlightResult . hierarchy . lvl2 . value } </div>
221
204
<div class="search__hits__label">
222
- <div class="search__hits__platform">${ data . platform } </div>
223
205
${ data . hierarchy . lvl1 }
224
206
</div>
225
207
</div>
@@ -239,7 +221,6 @@ window.addEventListener("DOMContentLoaded", () => {
239
221
<div class="search__hits__text">
240
222
<div class="search__hits__title">${ data . _highlightResult . hierarchy . lvl3 . value } </div>
241
223
<div class="search__hits__label">
242
- <div class="search__hits__platform">${ data . platform } </div>
243
224
${ data . hierarchy . lvl1 }
244
225
</div>
245
226
</div>
@@ -262,7 +243,6 @@ window.addEventListener("DOMContentLoaded", () => {
262
243
data . _snippetResult . content . value
263
244
} </div>
264
245
<div class="search__hits__label">
265
- <div class="search__hits__platform">${ data . platform } </div>
266
246
${ data . hierarchy . lvl1 }
267
247
${
268
248
data . hierarchy . lvl2
@@ -374,24 +354,9 @@ window.addEventListener("DOMContentLoaded", () => {
374
354
if ( e . key === "Enter" ) {
375
355
const searchInputEl = document . querySelector ( ".search__input" ) ;
376
356
if ( searchInputEl . value && document . activeElement === searchInputEl ) {
377
- var platform = "" ;
378
357
var environment = location . hostname === "localhost" || location . hostname === "127.0.0.1" ? "dev" : "prod" ;
379
358
380
- if ( activePlatform === "k8s" ) {
381
- platform = "kubernetes/upstream" ;
382
- } else if ( activePlatform === "openshift" ) {
383
- platform = "kubernetes/openshift" ;
384
- } else if ( activePlatform === "eks" ) {
385
- platform = "kubernetes/eks" ;
386
- } else if ( activePlatform === "gke" ) {
387
- platform = "kubernetes/gke" ;
388
- } else if ( activePlatform === "aks" ) {
389
- platform = "kubernetes/aks" ;
390
- } else {
391
- platform = activePlatform ;
392
- }
393
-
394
- var pathname = environment === "dev" ? "/search.html" : `/docs/minio/${ platform } /search.html` ;
359
+ var pathname = environment === "dev" ? "/search.html" : `/docs/minio/search.html` ;
395
360
396
361
setTimeout ( ( ) => {
397
362
window . location . pathname = pathname ;
0 commit comments