diff --git a/assets/styles/application.template.scss b/assets/styles/application.template.scss index 769ade9..0844706 100644 --- a/assets/styles/application.template.scss +++ b/assets/styles/application.template.scss @@ -14,6 +14,7 @@ @import './layouts/list'; @import './layouts/single'; @import './layouts/notes'; +@import './layouts/404'; // navigators @import './navigators/navbar'; diff --git a/assets/styles/layouts/404.scss b/assets/styles/layouts/404.scss new file mode 100644 index 0000000..458b2dc --- /dev/null +++ b/assets/styles/layouts/404.scss @@ -0,0 +1,95 @@ +body.kind-404 { + .navbar-toggler { + display: none; + } + + .notFound { + padding-top: 5rem; + text-align: center; + padding-bottom: 8rem; + } + + .notFound img { + height: 500px; + } + + .notFound h1 { + font-style: italic; + } + + .notFound .message { + position: absolute; + max-width: 20rem; + top: 40%; + left: 30%; + } + + /* ============= Device specific fixes ======= */ + + /* Large screens such as TV */ + @media only screen and (min-width: 1824px) { + } + + /* Extra large devices (large desktops, 1200px and up) */ + + @media (max-width: 1400px) { + } + + @media (max-width: 1200px) { + .notFound .message { + top: 50%; + left: 25%; + } + } + + /* IPad Pro */ + @media (max-width: 1024px) { + } + + /* Large devices (desktops, 992px and up) */ + + @media (max-width: 992px) { + .notFound .message { + top: 46%; + left: 25%; + } + } + + /* Medium devices (tablets, 768px and up) */ + + @media only screen and (max-width: 768px) { + .notFound img { + height: 400px; + } + + .notFound .message { + top: 20rem; + left: 4rem; + } + } + + /* Small devices (landscape phones, 576px and up) */ + + @media only screen and (max-width: 576px) { + .notFound img { + height: 250px; + } + + .notFound .message { + top: 20rem; + left: 2rem; + } + } + + /* iPhoneX, iPhone 6,7,8 */ + @media only screen and (max-width: 375px) { + } + + /* Galaxy S5, Moto G4 */ + @media only screen and (max-width: 360px) { + } + + /* iPhone 5 or before */ + @media only screen and (max-width: 320px) { + } +} diff --git a/layouts/404.html b/layouts/404.html index c602109..c241311 100644 --- a/layouts/404.html +++ b/layouts/404.html @@ -1,7 +1,3 @@ -{{ define "header" }} - -{{ end }} - {{ define "navbar" }} {{ partial "navigators/navbar-2.html" (dict "baseURL" site.BaseURL "title" site.Title "hasToggleButton" false) }} {{ end }} diff --git a/static/css/404.css b/static/css/404.css deleted file mode 100644 index 4ccb97c..0000000 --- a/static/css/404.css +++ /dev/null @@ -1,93 +0,0 @@ -.navbar-toggler { - display: none; -} - -.notFound { - padding-top: 5rem; - text-align: center; - padding-bottom: 8rem; -} - -.notFound img { - height: 500px; -} - -.notFound h1 { - font-style: italic; -} - -.notFound .message { - position: absolute; - max-width: 20rem; - top: 40%; - left: 30%; -} - -/* ============= Device specific fixes ======= */ - -/* Large screens such as TV */ -@media only screen and (min-width: 1824px) { -} - -/* Extra large devices (large desktops, 1200px and up) */ - -@media (max-width: 1400px) { -} - -@media (max-width: 1200px) { - .notFound .message { - top: 50%; - left: 25%; - } -} - -/* IPad Pro */ -@media (max-width: 1024px) { -} - -/* Large devices (desktops, 992px and up) */ - -@media (max-width: 992px) { - .notFound .message { - top: 46%; - left: 25%; - } -} - -/* Medium devices (tablets, 768px and up) */ - -@media only screen and (max-width: 768px) { - .notFound img { - height: 400px; - } - - .notFound .message { - top: 20rem; - left: 4rem; - } -} - -/* Small devices (landscape phones, 576px and up) */ - -@media only screen and (max-width: 576px) { - .notFound img { - height: 250px; - } - - .notFound .message { - top: 20rem; - left: 2rem; - } -} - -/* iPhoneX, iPhone 6,7,8 */ -@media only screen and (max-width: 375px) { -} - -/* Galaxy S5, Moto G4 */ -@media only screen and (max-width: 360px) { -} - -/* iPhone 5 or before */ -@media only screen and (max-width: 320px) { -}