From 77f6fc0b84fe182e5a4ae12967de3da2ea3185f8 Mon Sep 17 00:00:00 2001 From: Scott Anderson Date: Thu, 27 Aug 2020 10:46:16 -0600 Subject: [PATCH 1/2] updated 404 page to account for mulitple products, resolves #1358 --- assets/styles/layouts/_error-page.scss | 36 +++++++++-- layouts/404.html | 90 ++++++++++++++++++-------- 2 files changed, 94 insertions(+), 32 deletions(-) diff --git a/assets/styles/layouts/_error-page.scss b/assets/styles/layouts/_error-page.scss index 36778828b..0743af4d8 100644 --- a/assets/styles/layouts/_error-page.scss +++ b/assets/styles/layouts/_error-page.scss @@ -7,7 +7,7 @@ .error-content { margin-top: 10vh; - max-width: 310px; + max-width: 380px; } .error-code { @@ -56,24 +56,50 @@ margin: 2rem 0 1.5rem; .btn { - display: block; + display: flex; + position: relative; flex-grow: 1; margin-right: 4px; padding: .75rem 1rem; border-radius: $radius; text-align: center; + justify-content: center; + align-items: center; color: $error-page-btn-text; transition: background-color .2s; + z-index: 1; @include gradient($article-btn-gradient); - &:hover { - @include gradient($article-btn-gradient-hover); - } + &.back:before { content: "\e90a"; font-family: "icomoon"; margin-right: .35rem; vertical-align: text-top; } + + &:after { + content: ""; + position: absolute; + display: block; + top: 0; + right: 0; + width: 100%; + height: 100%; + border-radius: $radius; + @include gradient($article-btn-gradient-hover); + opacity: 0; + transition: opacity .2s; + z-index: -1; + } + + &:hover { + cursor: pointer; + + &:after { + opacity: 1; + } + } + } } diff --git a/layouts/404.html b/layouts/404.html index bc45ee189..75992c0da 100644 --- a/layouts/404.html +++ b/layouts/404.html @@ -1,34 +1,70 @@ -{{ partial "header.html" . }} + + + + {{ partial "header/google-analytics-head.html" }} + + + Page not found + + + -
-
-
-
-

404

+ {{ partial "header/stylesheets.html" }} + {{ partial "header/google-fonts.html" }} + {{ partial "header/javascript.html" }} + + + + + + {{ partial "header/google-analytics-body.html" }} + +
+
+
+
+

404

+
+
+
+ Back + +
+

Whoops! Looks like this page doesn't exist. If a link brought you here, let us know. We'd like to fix it.

-
-
- Back - InfluxDB -
-

Whoops! Looks like this page doesn't exist. If a link brought you here, let us know. We'd like to fix it.

-
- + if ( project != undefined && project.path === '/platform') { + $('.btn.version').append(`${project.name}`).attr('href', `${project.path}/`); + } else if ( project != undefined && projectVersion != undefined ) { + $('.btn.version').append(`${project.name} ${projectVersion}`).attr('href', `${project.path}/${projectVersion}/`); + } else if ( project != undefined && projectVersion == undefined ){ + $('.btn.version').append(`${project.name}`).attr('href', `${project.path}/`); + } else { + $('.btn.version').hide() + } + + + +{{ partial "footer/javascript.html" . }} + -{{ partial "footer.html" . }} From 517a18f81a32a58f3132963d7ea16a96a2e8874a Mon Sep 17 00:00:00 2001 From: Scott Anderson Date: Thu, 27 Aug 2020 11:47:38 -0600 Subject: [PATCH 2/2] fixed landing page styles --- assets/styles/layouts/_landing.scss | 17 +++++++++++------ content/influxdb/v2.0/_index.md | 2 +- ...rsion-landing.html => landing-influxdb.html} | 0 3 files changed, 12 insertions(+), 7 deletions(-) rename layouts/_default/{version-landing.html => landing-influxdb.html} (100%) diff --git a/assets/styles/layouts/_landing.scss b/assets/styles/layouts/_landing.scss index 0b7eacd73..e2cf691f2 100644 --- a/assets/styles/layouts/_landing.scss +++ b/assets/styles/layouts/_landing.scss @@ -50,7 +50,8 @@ width: 90%; position: relative; margin-bottom: 1px; - padding: 2rem 3.5vw 2rem 3vw; + // padding: 2rem 3.5vw 2rem 3vw; + padding: 0 3.5vw 0 3vw; // added min-height: 140px; background: $landing-sm-bg; transition: background-color .4s, width .2s; @@ -61,28 +62,31 @@ background: $landing-sm-bg-hover; width: 100%; h3 { - transform: translateY(-1.2rem); font-weight: $medium; font-size: 1.2rem; } p { opacity: 1; - transition-delay: 100ms; + // transition-delay: 100ms; + max-height: 3.75rem; // added } } h3 { font-size: 1.1rem; transition: all .2s; + margin: 0; // added } p { - position: absolute; + // position: absolute; + margin: .5rem 0 0; // added + max-height: 0; // added width: 80%; color: $g20-white; font-size: .95rem; line-height: 1.25rem; opacity: 0; - transition: opacity .2s; + transition: opacity .2s .1s, max-height .2s; } } @@ -181,13 +185,14 @@ p { opacity: .6; position: relative; + max-height: fit-content; width: auto; margin: 0; } &:hover { background: $landing-sm-bg-hover; h3 { transform: none; } - p { opacity: 1; } + p { opacity: 1; max-height: fit-content; } } } } diff --git a/content/influxdb/v2.0/_index.md b/content/influxdb/v2.0/_index.md index 7dee8c207..91566806e 100644 --- a/content/influxdb/v2.0/_index.md +++ b/content/influxdb/v2.0/_index.md @@ -3,7 +3,7 @@ title: InfluxDB v2.0 documentation description: > InfluxDB is an open source time series database designed to handle high write and query loads. Learn how to use and leverage InfluxDB in use cases such as monitoring metrics, IoT data, and events. -layout: version-landing +layout: landing-influxdb menu: influxdb_2_0: name: InfluxDB 2.0 home diff --git a/layouts/_default/version-landing.html b/layouts/_default/landing-influxdb.html similarity index 100% rename from layouts/_default/version-landing.html rename to layouts/_default/landing-influxdb.html