1234567891011121314151617181920212223242526272829303132333435363738 |
- #!/bin/sh
- template() {
- message=$1
- cat <<EOF
- <!DOCTYPE html>
- <html>
- <head>
- <meta charset="UTF-8">
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
- <title>toymaker::error</title>
- <style>
- * {
- box-sizing: border-box;
- }
- a {
- color: #00afff;
- }
- a:hover {
- background-color: #db9d3b;
- color: #000000;
- }
- </style>
- </head>
- <body style="background-color: #292929; color: #fafafa;">
- <header style="font-size: 1.25rem; padding-top: .3125rem; padding-bottom: .3125rem;">
- <a href="/toys/" style="font-family: monospace; text-decoration: none;">toymaker</a>
- </header>
- <main style="margin-left: 1rem; margin-top: 2rem;">
- EOF
- printf '\t\t\t<span style="font-size: 2rem; color: #ff5c57;">%s</span>\n' "$message"
- cat <<EOF
- </main>
- </body>
- </html>
- EOF
- }
|