Fixing 404 page search overflow (#599)
* Fixing 404 page search overflow
* Adding ability to add noindex no follow to page
diff --git a/content/css/styles.css b/content/css/styles.css
index f04f34a..89ab0ba 100644
--- a/content/css/styles.css
+++ b/content/css/styles.css
@@ -1083,6 +1083,15 @@
padding-bottom: 5px;
}
+#page-404-search {
+ background-color: #fff;
+ position: absolute;
+}
+#page-404-search .pagefind-ui__results {
+ max-height: 400px;
+ overflow: auto;
+}
+
/* RESPONSIVE STYLES */
/* Media Adjustments */
diff --git a/content/foundation/example.ezmd b/content/foundation/example.ezmd
index aeb2986..a201b57 100644
--- a/content/foundation/example.ezmd
+++ b/content/foundation/example.ezmd
@@ -1,6 +1,7 @@
Title: Example Page
page_heading: Lorem Ipsum Dolor
license: https://www.apache.org/licenses/LICENSE-2.0
+noindex: true
## Lorem Ipsum Dolor
<!-- add 4 sentences of lorem ipsum below -->
diff --git a/theme/apache/templates/base.html b/theme/apache/templates/base.html
index 502aadf..bea4de6 100644
--- a/theme/apache/templates/base.html
+++ b/theme/apache/templates/base.html
@@ -5,6 +5,9 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="{{page.description}}">
+ {% if page.noindex == 'true' %}
+ <meta name="robots" content="noindex, nofollow" />
+ {% endif %}
<link rel="apple-touch-icon" sizes="57x57" href="/favicons/apple-touch-icon-57x57.png">
<link rel="apple-touch-icon" sizes="60x60" href="/favicons/apple-touch-icon-60x60.png">
<link rel="apple-touch-icon" sizes="72x72" href="/favicons/apple-touch-icon-72x72.png">