Fix search result card layout (#820)

Signed-off-by: hossainemruz <hossainemruz@gmail.com>
This commit is contained in:
Emruz Hossain 2023-10-21 02:20:26 +06:00 committed by GitHub
parent fecc0546e6
commit 69611695e7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
14 changed files with 3 additions and 0 deletions

View file

@ -0,0 +1,54 @@
---
title: "অনুসন্ধানের ফলাফল"
date: 2010-06-08T08:06:25+06:00
weight: 999999
sitemap:
priority : 0.1
layout: "search"
url: search
---
This file exists solely to respond to /search URL with the related `search` layout template.
No content shown here is rendered, all content is based in the template layouts/page/search.html
Setting a very low sitemap priority will tell search engines this is not important content.
This implementation uses Fusejs and mark.js
## Initial setup
Search depends on additional output content type of JSON in config.toml
\```
[outputs]
home = ["HTML", "JSON"]
\```
## Searching additional fileds
To search additional fields defined in front matter, you must add it in 2 places.
### Edit layouts/_default/index.JSON
This exposes the values in /index.json
i.e. add `category`
\```
...
"contents":{{ .Content | plainify | jsonify }}
{{ if .Params.tags }},
"tags":{{ .Params.tags | jsonify }}{{end}},
"categories" : {{ .Params.categories | jsonify }},
...
\```
### Edit fuse.js options to Search
`assets/scripts/pages/search.js`
\```
keys: [
"title",
"contents",
"tags",
"categories"
]
\```

View file

@ -0,0 +1,54 @@
---
title: "Search Results"
date: 2010-06-08T08:06:25+06:00
weight: 999999
sitemap:
priority : 0.1
layout: "search"
url: search
---
This file exists solely to respond to /search URL with the related `search` layout template.
No content shown here is rendered, all content is based in the template layouts/page/search.html
Setting a very low sitemap priority will tell search engines this is not important content.
This implementation uses Fusejs and mark.js
## Initial setup
Search depends on additional output content type of JSON in config.toml
\```
[outputs]
home = ["HTML", "JSON"]
\```
## Searching additional fileds
To search additional fields defined in front matter, you must add it in 2 places.
### Edit layouts/_default/index.JSON
This exposes the values in /index.json
i.e. add `category`
\```
...
"contents":{{ .Content | plainify | jsonify }}
{{ if .Params.tags }},
"tags":{{ .Params.tags | jsonify }}{{end}},
"categories" : {{ .Params.categories | jsonify }},
...
\```
### Edit fuse.js options to Search
`assets/scripts/pages/search.js`
\```
keys: [
"title",
"contents",
"tags",
"categories"
]
\```

View file

@ -0,0 +1,54 @@
---
title: "Search Results"
date: 2010-06-08T08:06:25+06:00
weight: 999999
sitemap:
priority : 0.1
layout: "search"
url: search
---
This file exists solely to respond to /search URL with the related `search` layout template.
No content shown here is rendered, all content is based in the template layouts/page/search.html
Setting a very low sitemap priority will tell search engines this is not important content.
This implementation uses Fusejs and mark.js
## Initial setup
Search depends on additional output content type of JSON in config.toml
\```
[outputs]
home = ["HTML", "JSON"]
\```
## Searching additional fileds
To search additional fields defined in front matter, you must add it in 2 places.
### Edit layouts/_default/index.JSON
This exposes the values in /index.json
i.e. add `category`
\```
...
"contents":{{ .Content | plainify | jsonify }}
{{ if .Params.tags }},
"tags":{{ .Params.tags | jsonify }}{{end}},
"categories" : {{ .Params.categories | jsonify }},
...
\```
### Edit fuse.js options to Search
`assets/scripts/pages/search.js`
\```
keys: [
"title",
"contents",
"tags",
"categories"
]
\```

View file

@ -0,0 +1,54 @@
---
title: "Resultados de Búsqueda"
date: 2010-06-08T08:06:25+06:00
weight: 999999
sitemap:
priority : 0.1
layout: "search"
url: search
---
Este archivo existe únicamente para responder a la URL /search con la plantilla de diseño `search` relacionada.
No se muestra ningún contenido aquí, todo el contenido se basa en la plantilla layouts/page/search.html
Establecer una prioridad muy baja en el mapa del sitio le dirá a los motores de búsqueda que éste no es un contenido importante.
Esta implementación utiliza Fusejs, jquery y mark.js
## Configuración inicial
La búsqueda depende del tipo de contenido de salida adicional de JSON en config.toml
\```
[outputs]
home = ["HTML", "JSON"]
\```
## Búsqueda de archivos adicionales
Para buscar campos adicionales definidos en el front matter, debes añadirlo en 2 lugares.
### Editar layouts/_default/index.JSON
Esto expone los valores en /index.json: por ejemplo, para agregar `categories`
\```
...
"contents":{{ .Content | plainify | jsonify }}
{{ if .Params.tags }},
"tags":{{ .Params.tags | jsonify }}{{end}},
"categories" : {{ .Params.categories | jsonify }},
...
\```
### Editar las opciones de fuse.js para buscar
`assets/scripts/pages/search.js`
\```
keys: [
"title",
"contents",
"tags",
"categories"
]
\```

View file

@ -0,0 +1,54 @@
---
title: "Search Results"
date: 2010-06-08T08:06:25+06:00
weight: 999999
sitemap:
priority : 0.1
layout: "search"
url: search
---
This file exists solely to respond to /search URL with the related `search` layout template.
No content shown here is rendered, all content is based in the template layouts/page/search.html
Setting a very low sitemap priority will tell search engines this is not important content.
This implementation uses Fusejs and mark.js
## Initial setup
Search depends on additional output content type of JSON in config.toml
\```
[outputs]
home = ["HTML", "JSON"]
\```
## Searching additional fileds
To search additional fields defined in front matter, you must add it in 2 places.
### Edit layouts/_default/index.JSON
This exposes the values in /index.json
i.e. add `category`
\```
...
"contents":{{ .Content | plainify | jsonify }}
{{ if .Params.tags }},
"tags":{{ .Params.tags | jsonify }}{{end}},
"categories" : {{ .Params.categories | jsonify }},
...
\```
### Edit fuse.js options to Search
`assets/scripts/pages/search.js`
\```
keys: [
"title",
"contents",
"tags",
"categories"
]
\```

View file

@ -0,0 +1,54 @@
---
title: "Search Results"
date: 2010-06-08T08:06:25+06:00
weight: 999999
sitemap:
priority : 0.1
layout: "search"
url: search
---
This file exists solely to respond to /search URL with the related `search` layout template.
No content shown here is rendered, all content is based in the template layouts/page/search.html
Setting a very low sitemap priority will tell search engines this is not important content.
This implementation uses Fusejs and mark.js
## Initial setup
Search depends on additional output content type of JSON in config.toml
\```
[outputs]
home = ["HTML", "JSON"]
\```
## Searching additional fileds
To search additional fields defined in front matter, you must add it in 2 places.
### Edit layouts/_default/index.JSON
This exposes the values in /index.json
i.e. add `category`
\```
...
"contents":{{ .Content | plainify | jsonify }}
{{ if .Params.tags }},
"tags":{{ .Params.tags | jsonify }}{{end}},
"categories" : {{ .Params.categories | jsonify }},
...
\```
### Edit fuse.js options to Search
`assets/scripts/pages/search.js`
\```
keys: [
"title",
"contents",
"tags",
"categories"
]
\```

View file

@ -0,0 +1,54 @@
---
title: "Search Results"
date: 2010-06-08T08:06:25+06:00
weight: 999999
sitemap:
priority : 0.1
layout: "search"
url: search
---
This file exists solely to respond to /search URL with the related `search` layout template.
No content shown here is rendered, all content is based in the template layouts/page/search.html
Setting a very low sitemap priority will tell search engines this is not important content.
This implementation uses Fusejs and mark.js
## Initial setup
Search depends on additional output content type of JSON in config.toml
\```
[outputs]
home = ["HTML", "JSON"]
\```
## Searching additional fileds
To search additional fields defined in front matter, you must add it in 2 places.
### Edit layouts/_default/index.JSON
This exposes the values in /index.json
i.e. add `category`
\```
...
"contents":{{ .Content | plainify | jsonify }}
{{ if .Params.tags }},
"tags":{{ .Params.tags | jsonify }}{{end}},
"categories" : {{ .Params.categories | jsonify }},
...
\```
### Edit fuse.js options to Search
`assets/scripts/pages/search.js`
\```
keys: [
"title",
"contents",
"tags",
"categories"
]
\```

View file

@ -0,0 +1,54 @@
---
title: "Search Results"
date: 2010-06-08T08:06:25+06:00
weight: 999999
sitemap:
priority : 0.1
layout: "search"
url: search
---
This file exists solely to respond to /search URL with the related `search` layout template.
No content shown here is rendered, all content is based in the template layouts/page/search.html
Setting a very low sitemap priority will tell search engines this is not important content.
This implementation uses Fusejs and mark.js
## Initial setup
Search depends on additional output content type of JSON in config.toml
\```
[outputs]
home = ["HTML", "JSON"]
\```
## Searching additional fileds
To search additional fields defined in front matter, you must add it in 2 places.
### Edit layouts/_default/index.JSON
This exposes the values in /index.json
i.e. add `category`
\```
...
"contents":{{ .Content | plainify | jsonify }}
{{ if .Params.tags }},
"tags":{{ .Params.tags | jsonify }}{{end}},
"categories" : {{ .Params.categories | jsonify }},
...
\```
### Edit fuse.js options to Search
`assets/scripts/pages/search.js`
\```
keys: [
"title",
"contents",
"tags",
"categories"
]
\```

View file

@ -0,0 +1,54 @@
---
title: "Search Results"
date: 2010-06-08T08:06:25+06:00
weight: 999999
sitemap:
priority : 0.1
layout: "search"
url: search
---
This file exists solely to respond to /search URL with the related `search` layout template.
No content shown here is rendered, all content is based in the template layouts/page/search.html
Setting a very low sitemap priority will tell search engines this is not important content.
This implementation uses Fusejs and mark.js
## Initial setup
Search depends on additional output content type of JSON in config.toml
\```
[outputs]
home = ["HTML", "JSON"]
\```
## Searching additional fileds
To search additional fields defined in front matter, you must add it in 2 places.
### Edit layouts/_default/index.JSON
This exposes the values in /index.json
i.e. add `category`
\```
...
"contents":{{ .Content | plainify | jsonify }}
{{ if .Params.tags }},
"tags":{{ .Params.tags | jsonify }}{{end}},
"categories" : {{ .Params.categories | jsonify }},
...
\```
### Edit fuse.js options to Search
`assets/scripts/pages/search.js`
\```
keys: [
"title",
"contents",
"tags",
"categories"
]
\```

View file

@ -0,0 +1,54 @@
---
title: "Search Results"
date: 2010-06-08T08:06:25+06:00
weight: 999999
sitemap:
priority : 0.1
layout: "search"
url: search
---
This file exists solely to respond to /search URL with the related `search` layout template.
No content shown here is rendered, all content is based in the template layouts/page/search.html
Setting a very low sitemap priority will tell search engines this is not important content.
This implementation uses Fusejs and mark.js
## Initial setup
Search depends on additional output content type of JSON in config.toml
\```
[outputs]
home = ["HTML", "JSON"]
\```
## Searching additional fileds
To search additional fields defined in front matter, you must add it in 2 places.
### Edit layouts/_default/index.JSON
This exposes the values in /index.json
i.e. add `category`
\```
...
"contents":{{ .Content | plainify | jsonify }}
{{ if .Params.tags }},
"tags":{{ .Params.tags | jsonify }}{{end}},
"categories" : {{ .Params.categories | jsonify }},
...
\```
### Edit fuse.js options to Search
`assets/scripts/pages/search.js`
\```
keys: [
"title",
"contents",
"tags",
"categories"
]
\```

54
content/search/search.md Normal file
View file

@ -0,0 +1,54 @@
---
title: "Search Results"
date: 2010-06-08T08:06:25+06:00
weight: 999999
sitemap:
priority : 0.1
layout: "search"
url: search
---
This file exists solely to respond to /search URL with the related `search` layout template.
No content shown here is rendered, all content is based in the template layouts/page/search.html
Setting a very low sitemap priority will tell search engines this is not important content.
This implementation uses Fusejs and mark.js
## Initial setup
Search depends on additional output content type of JSON in config.toml
\```
[outputs]
home = ["HTML", "JSON"]
\```
## Searching additional fileds
To search additional fields defined in front matter, you must add it in 2 places.
### Edit layouts/_default/index.JSON
This exposes the values in /index.json
i.e. add `category`
\```
...
"contents":{{ .Content | plainify | jsonify }}
{{ if .Params.tags }},
"tags":{{ .Params.tags | jsonify }}{{end}},
"categories" : {{ .Params.categories | jsonify }},
...
\```
### Edit fuse.js options to Search
`assets/scripts/pages/search.js`
\```
keys: [
"title",
"contents",
"tags",
"categories"
]
\```

View file

@ -0,0 +1,54 @@
---
title: "Search Results"
date: 2010-06-08T08:06:25+06:00
weight: 999999
sitemap:
priority : 0.1
layout: "search"
url: search
---
This file exists solely to respond to /search URL with the related `search` layout template.
No content shown here is rendered, all content is based in the template layouts/page/search.html
Setting a very low sitemap priority will tell search engines this is not important content.
This implementation uses Fusejs and mark.js
## Initial setup
Search depends on additional output content type of JSON in config.toml
\```
[outputs]
home = ["HTML", "JSON"]
\```
## Searching additional fileds
To search additional fields defined in front matter, you must add it in 2 places.
### Edit layouts/_default/index.JSON
This exposes the values in /index.json
i.e. add `category`
\```
...
"contents":{{ .Content | plainify | jsonify }}
{{ if .Params.tags }},
"tags":{{ .Params.tags | jsonify }}{{end}},
"categories" : {{ .Params.categories | jsonify }},
...
\```
### Edit fuse.js options to Search
`assets/scripts/pages/search.js`
\```
keys: [
"title",
"contents",
"tags",
"categories"
]
\```

View file

@ -0,0 +1,54 @@
---
title: "Search Results"
date: 2010-06-08T08:06:25+06:00
weight: 999999
sitemap:
priority : 0.1
layout: "search"
url: search
---
This file exists solely to respond to /search URL with the related `search` layout template.
No content shown here is rendered, all content is based in the template layouts/page/search.html
Setting a very low sitemap priority will tell search engines this is not important content.
This implementation uses Fusejs and mark.js
## Initial setup
Search depends on additional output content type of JSON in config.toml
\```
[outputs]
home = ["HTML", "JSON"]
\```
## Searching additional fileds
To search additional fields defined in front matter, you must add it in 2 places.
### Edit layouts/_default/index.JSON
This exposes the values in /index.json
i.e. add `category`
\```
...
"contents":{{ .Content | plainify | jsonify }}
{{ if .Params.tags }},
"tags":{{ .Params.tags | jsonify }}{{end}},
"categories" : {{ .Params.categories | jsonify }},
...
\```
### Edit fuse.js options to Search
`assets/scripts/pages/search.js`
\```
keys: [
"title",
"contents",
"tags",
"categories"
]
\```