Skip to content

Commit 3e68025

Browse files
authored
Merge pull request #18 from hmyam6090-lab/main
Added a custom 404 error page
2 parents 6533b8d + 9d8f131 commit 3e68025

3 files changed

Lines changed: 86 additions & 25 deletions

File tree

docs/assets/404_L5.gif

57.1 KB
Loading

mkdocs.yml

Lines changed: 28 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -16,38 +16,41 @@ theme:
1616
favicon: assets/L5-logo-blob.png
1717
features:
1818
- navigation.indexes
19-
- content.code.copy # Copy button
20-
- content.code.select # Allow selecting code
19+
- content.code.copy # Copy button
20+
- content.code.select # Allow selecting code
21+
custom_dir: overrides
22+
static_templates:
23+
- 404.html
2124
extra_css:
22-
- stylesheets/extra.css
25+
- stylesheets/extra.css
2326
extra:
2427
generator: false
2528
nav:
2629
- Welcome to L5: index.md
27-
- Download:
28-
- Download: download/index.md
29-
- Install for Mac: download/install-mac.md
30-
- Install for Windows: download/install-windows.md
31-
- Install for Linux: download/install-linux.md
30+
- Download:
31+
- Download: download/index.md
32+
- Install for Mac: download/install-mac.md
33+
- Install for Windows: download/install-windows.md
34+
- Install for Linux: download/install-linux.md
3235
- Getting Started: getting-started.md
3336
- L5 for Processing-p5.js programmers: L5-for-processingp5.md
34-
- Reference:
35-
- Reference Summary: reference/index.md
36-
- Shape: reference/#shape
37-
- Color: reference/#color
38-
- Typography: reference/#typography
39-
- Image: reference/#image
40-
- Media: reference/#media
41-
- Transform: reference/#transform
42-
- Environment: reference/#environment
43-
- Rendering: reference/#rendering
44-
- Math: reference/#math
45-
- IO: reference/#io
46-
- Events: reference/#events
47-
- Data: reference/#data
48-
- Structure: reference/#structure
49-
- Constants: reference/#constants
50-
- Foundation: reference/#foundation
37+
- Reference:
38+
- Reference Summary: reference/index.md
39+
- Shape: reference/#shape
40+
- Color: reference/#color
41+
- Typography: reference/#typography
42+
- Image: reference/#image
43+
- Media: reference/#media
44+
- Transform: reference/#transform
45+
- Environment: reference/#environment
46+
- Rendering: reference/#rendering
47+
- Math: reference/#math
48+
- IO: reference/#io
49+
- Events: reference/#events
50+
- Data: reference/#data
51+
- Structure: reference/#structure
52+
- Constants: reference/#constants
53+
- Foundation: reference/#foundation
5154
- Tutorials: tutorials/index.md
5255
- Examples: examples/index.md
5356
- Bug Reports: bug-reports.md

overrides/404.html

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
{% extends "base.html" %}
2+
3+
{% block content %}
4+
<div class="md-container" data-md-component="container">
5+
<div class="md-grid" data-md-component="grid">
6+
<main class="md-main" data-md-component="main">
7+
<div class="md-main__inner md-grid">
8+
<div class="md-content">
9+
<article class="md-content__inner md-typeset">
10+
<h1>404 — Page Not Found</h1>
11+
12+
<p style="text-align: center;">
13+
<img src="{{ config.site_url }}assets/404_L5.gif" alt="Error Page L5 animation" style="max-width: 400px; margin: 20px auto; display: block;">
14+
</p>
15+
16+
<h2>Oops! We couldn't find that page.</h2>
17+
18+
<p>It looks like the page you're looking for doesn't exist or has been moved. This might happen if:</p>
19+
20+
<ul>
21+
<li>The URL was typed incorrectly</li>
22+
<li>A link is outdated or broken</li>
23+
<li>The page has been reorganized in a newer version</li>
24+
</ul>
25+
26+
<h2>Where to go from here</h2>
27+
28+
<p>Start exploring L5 from these helpful places:</p>
29+
30+
<ul>
31+
<li><strong><a href="{{ config.site_url }}">Welcome to L5</a></strong>: Get started with L5 fundamentals</li>
32+
<li><strong><a href="{{ config.site_url }}getting-started/">Getting Started</a></strong>: Installation and your first sketch</li>
33+
<li><strong><a href="{{ config.site_url }}download/">Download L5</a></strong>: Get the latest version for your platform</li>
34+
<li><strong><a href="{{ config.site_url }}reference/">Reference</a></strong>: Complete API documentation</li>
35+
<li><strong><a href="{{ config.site_url }}examples/">Examples</a></strong>: Learn by exploring example sketches</li>
36+
<li><strong><a href="{{ config.site_url }}L5-for-processingp5/">L5 for Processing Users</a></strong>: If you know Processing, start here</li>
37+
</ul>
38+
39+
<h2>Have trouble?</h2>
40+
41+
<p>If you think you found a broken link or something is missing, please help us improve:</p>
42+
43+
<ul>
44+
<li><a href="{{ config.site_url }}bug-reports/">Report a bug</a>: Let us know about issues</li>
45+
<li><a href="{{ config.site_url }}contributing/">Contributing guide</a>: Help improve the L5 documentation</li>
46+
<li><a href="https://github.com/l5lua/L5">Visit the L5 GitHub repository</a>: Check the issues or join the discussion</li>
47+
</ul>
48+
49+
<hr>
50+
51+
<p><em>L5 is a Processing library in Lua. Happy coding!</em></p>
52+
</article>
53+
</div>
54+
</div>
55+
</main>
56+
</div>
57+
</div>
58+
{% endblock %}

0 commit comments

Comments
 (0)