~kvikshaug/kvikshaug.no

0761722dabc391825761c2f9b9e47f942f9de9dc — Ali Kaafarani 1 year, 4 months ago ac5d0d5 master
Add 404 page
A assets/sass/404.scss => assets/sass/404.scss +21 -0
@@ 0,0 1,21 @@
@use "fonts";

body {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100vh;
  margin: 0 40px;
}

h1 {
  font-family: "EB Garamond", Garamond, Georgia, serif;
  font-size: 4rem;
  font-weight: normal;
}

@media (max-width: 991px) {
  h1 {
    font-size: 3rem;
  }
}

M assets/sass/_design.scss => assets/sass/_design.scss +0 -28
@@ 1,32 1,4 @@
//
// Fonts
//

@font-face {
  font-family: "EB Garamond";
  font-style: normal;
  font-weight: 400;
  font-display: block;
  src: url("/assets/fonts/eb-garamond-latin-regular.woff2") format("woff2");
}

@font-face {
  font-family: "EB Garamond";
  font-style: normal;
  font-weight: 700;
  font-display: block;
  src: url("/assets/fonts/eb-garamond-latin-bold.woff2") format("woff2");
}

@font-face {
  font-family: "EB Garamond";
  font-style: italic;
  font-weight: 400;
  font-display: block;
  src: url("/assets/fonts/eb-garamond-latin-italic.woff2") format("woff2");
}

//
// Base element definitions
//


A assets/sass/_fonts.scss => assets/sass/_fonts.scss +27 -0
@@ 0,0 1,27 @@
//
// Fonts
//

@font-face {
  font-family: "EB Garamond";
  font-style: normal;
  font-weight: 400;
  font-display: block;
  src: url("/assets/fonts/eb-garamond-latin-regular.woff2") format("woff2");
}

@font-face {
  font-family: "EB Garamond";
  font-style: normal;
  font-weight: 700;
  font-display: block;
  src: url("/assets/fonts/eb-garamond-latin-bold.woff2") format("woff2");
}

@font-face {
  font-family: "EB Garamond";
  font-style: italic;
  font-weight: 400;
  font-display: block;
  src: url("/assets/fonts/eb-garamond-latin-italic.woff2") format("woff2");
}

M assets/sass/style.scss => assets/sass/style.scss +1 -0
@@ 1,4 1,5 @@
@use "reset";
@use "fonts";
@use "design";
@use "design_responsive";
@use "content";

M src/kvikshaug/app.py => src/kvikshaug/app.py +5 -0
@@ 13,6 13,11 @@ if app.config["DEBUG"]:
    app.jinja_env.undefined = StrictUndefined


@app.errorhandler(404)
def page_not_found(error):
    return render_template("404.html"), 404


@app.route("/")
def home():
    return render_template("layout.html")

A templates/404.html => templates/404.html +13 -0
@@ 0,0 1,13 @@
<!doctype html>
<html lang="en">
  <head>
    <title>Ali Kaafarani</title>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <link rel="stylesheet" href="/assets/css/404.css">
    <link rel="icon" href="/assets/favicon.png" type="image/png">
  </head>
  <body>
    <h1>Whatever you are looking for, it is not here.</h1>
  </body>
</html>