Skip to content

Commit 4f0fa1a

Browse files
committed
docs: init
1 parent e1806ab commit 4f0fa1a

File tree

3 files changed

+179
-1
lines changed

3 files changed

+179
-1
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
# inflated-goboscript.github.io
2-
gh pages
2+
gh pages using material for mkdocs
3+

mkdocs.yml

Lines changed: 121 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,121 @@
1+
# yaml-language-server: $schema=https://squidfunk.github.io/mkdocs-material/schema.json
2+
3+
site_name: inflated-goboscript
4+
site_url: https://inflated-goboscript.github.io/
5+
site_description: Documentation for the inflation of gobos.
6+
7+
repo_url: https://github.com/inflated-goboscript/inflator
8+
repo_name: inflated-goboscript/inflator
9+
10+
theme:
11+
name: material
12+
custom_dir: overrides
13+
14+
palette:
15+
# Palette toggle for automatic mode
16+
- media: "(prefers-color-scheme)"
17+
toggle:
18+
icon: material/brightness-auto
19+
name: Switch to light mode
20+
primary: amber
21+
accent: amber
22+
23+
# Palette toggle for light mode
24+
- media: "(prefers-color-scheme: light)"
25+
scheme: default
26+
toggle:
27+
icon: material/brightness-7
28+
name: Switch to dark mode
29+
primary: amber
30+
accent: amber
31+
32+
# Palette toggle for dark mode
33+
- media: "(prefers-color-scheme: dark)"
34+
scheme: slate
35+
toggle:
36+
icon: material/brightness-4
37+
name: Switch to system preference
38+
primary: amber
39+
accent: amber
40+
41+
42+
features:
43+
- navigation.instant
44+
- navigation.instant.prefetch
45+
- navigation.instant.progress
46+
- navigation.instant.preview
47+
- navigation.tracking
48+
- navigation.tabs
49+
- content.tabs.link
50+
- content.tooltips
51+
52+
53+
plugins:
54+
- social
55+
- search
56+
- glightbox
57+
- meta
58+
59+
markdown_extensions:
60+
- admonition
61+
- pymdownx.details
62+
- pymdownx.superfences:
63+
custom_fences:
64+
- name: mermaid
65+
class: mermaid
66+
format: !!python/name:pymdownx.superfences.fence_code_format
67+
- attr_list
68+
- md_in_html
69+
- pymdownx.superfences
70+
- pymdownx.emoji:
71+
emoji_index: !!python/name:material.extensions.emoji.twemoji
72+
emoji_generator: !!python/name:material.extensions.emoji.to_svg
73+
74+
- pymdownx.highlight:
75+
anchor_linenums: true
76+
line_spans: __span
77+
pygments_lang_class: true
78+
- pymdownx.inlinehilite
79+
- pymdownx.snippets
80+
- pymdownx.superfences
81+
- pymdownx.tabbed:
82+
alternate_style: true
83+
- tables
84+
- footnotes
85+
- pymdownx.critic
86+
- pymdownx.caret
87+
- pymdownx.keys
88+
- pymdownx.mark
89+
- pymdownx.tilde
90+
- attr_list
91+
- pymdownx.blocks.caption
92+
- def_list
93+
- pymdownx.tasklist:
94+
custom_checkbox: true
95+
96+
extra:
97+
social:
98+
# Took this from the goboscript mkdocs yml file
99+
- icon: fontawesome/brands/github
100+
link: https://github.com/inflated-goboscript/
101+
- icon: fontawesome/brands/discord
102+
link: https://discord.gg/XGKV8X9hfh
103+
104+
analytics:
105+
provider: google
106+
property: G-XXXXXXXXXX # these are required fields, but unused
107+
108+
feedback:
109+
title: Was this page helpful?
110+
ratings:
111+
- icon: material/emoticon-happy-outline
112+
name: This page was helpful
113+
data: 1
114+
note: >-
115+
Thanks for your feedback!
116+
- icon: material/emoticon-sad-outline
117+
name: This page could be improved
118+
data: 0
119+
note: >-
120+
Thanks for your feedback! Help us improve this page by
121+
using our <a href="https://github.com/inflated-goboscript/inflated-goboscript.github.io/issues/new/?title=[Feedback]+{title}+-+{url}" target="_blank" rel="noopener">feedback form</a>.

overrides/partials/comments.html

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
{% if page.meta.comments %}
2+
<h2 id="__comments">{{ lang.t("meta.comments") }}</h2>
3+
<!-- Insert generated snippet here -->
4+
<script src="https://giscus.app/client.js"
5+
data-repo="inflated-goboscript/inflated-goboscript.github.io"
6+
data-repo-id="R_kgDOPq_w-A"
7+
data-category="Giscus"
8+
data-category-id="DIC_kwDOPq_w-M4CvDbs"
9+
data-mapping="pathname"
10+
data-strict="1"
11+
data-reactions-enabled="1"
12+
data-emit-metadata="0"
13+
data-input-position="top"
14+
data-theme="preferred_color_scheme"
15+
data-lang="en"
16+
data-loading="lazy"
17+
crossorigin="anonymous"
18+
async>
19+
</script>
20+
21+
<!-- Synchronize Giscus theme with palette -->
22+
<script>
23+
var giscus = document.querySelector("script[src*=giscus]")
24+
25+
// Set palette on initial load
26+
var palette = __md_get("__palette")
27+
if (palette && typeof palette.color === "object") {
28+
var theme = palette.color.scheme === "slate"
29+
? "transparent_dark"
30+
: "light"
31+
32+
// Instruct Giscus to set theme
33+
giscus.setAttribute("data-theme", theme)
34+
}
35+
36+
// Register event handlers after documented loaded
37+
document.addEventListener("DOMContentLoaded", function() {
38+
var ref = document.querySelector("[data-md-component=palette]")
39+
ref.addEventListener("change", function() {
40+
var palette = __md_get("__palette")
41+
if (palette && typeof palette.color === "object") {
42+
var theme = palette.color.scheme === "slate"
43+
? "transparent_dark"
44+
: "light"
45+
46+
// Instruct Giscus to change theme
47+
var frame = document.querySelector(".giscus-frame")
48+
frame.contentWindow.postMessage(
49+
{ giscus: { setConfig: { theme } } },
50+
"https://giscus.app"
51+
)
52+
}
53+
})
54+
})
55+
</script>
56+
{% endif %}

0 commit comments

Comments
 (0)