Skip to content

Commit 79e9007

Browse files
committed
separation and re-wiring
1 parent e77cf53 commit 79e9007

28 files changed

Lines changed: 264 additions & 135 deletions

.github/workflows/ci.yml

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,84 @@ concurrency:
1515
cancel-in-progress: true
1616

1717
jobs:
18+
website:
19+
name: Website Sanity
20+
runs-on: ubuntu-latest
21+
timeout-minutes: 10
22+
23+
steps:
24+
- name: Checkout
25+
uses: actions/checkout@v5
26+
27+
- name: Set up Node.js
28+
uses: actions/setup-node@v5
29+
with:
30+
node-version: "22"
31+
32+
- name: Validate workflow YAML
33+
shell: bash
34+
run: |
35+
ruby -e 'require "yaml"; Dir[".github/workflows/*.yml"].sort.each { |file| YAML.load_file(file) }'
36+
37+
- name: Validate website asset structure
38+
shell: bash
39+
run: |
40+
test -f docs/website/index.html
41+
test -f docs/website/css/core/base.css
42+
test -f docs/website/css/layout/topbar.css
43+
test -f docs/website/css/layout/sidebar.css
44+
test -f docs/website/css/layout/content.css
45+
test -f docs/website/css/layout/responsive.css
46+
test -f docs/website/css/components/workflow.css
47+
test -f docs/website/css/components/modules.css
48+
test -f docs/website/js/core/site-data.js
49+
test -f docs/website/js/core/helpers.js
50+
test -f docs/website/js/features/sidebar.js
51+
test -f docs/website/js/features/easter-eggs.js
52+
test -f docs/website/js/features/search.js
53+
test -f docs/website/js/features/contact-panel.js
54+
test -f docs/website/js/features/workflow-visual.js
55+
test -f docs/website/js/bootstrap/app.js
56+
test -f docs/website/web_assets/media/favicon.ico
57+
test -f docs/website/.nojekyll
58+
59+
- name: Validate website scripts
60+
shell: bash
61+
run: |
62+
for file in docs/website/js/core/*.js docs/website/js/features/*.js docs/website/js/bootstrap/*.js; do
63+
node --check "$file"
64+
done
65+
66+
- name: Validate page includes
67+
shell: bash
68+
run: |
69+
shopt -s nullglob
70+
pages=(docs/website/*.html)
71+
[ ${#pages[@]} -gt 0 ]
72+
for page in "${pages[@]}"; do
73+
grep -q 'css/core/base.css?v=' "${page}"
74+
grep -q 'css/layout/topbar.css?v=' "${page}"
75+
grep -q 'css/layout/sidebar.css?v=' "${page}"
76+
grep -q 'css/layout/content.css?v=' "${page}"
77+
grep -q 'css/components/workflow.css?v=' "${page}"
78+
grep -q 'css/components/modules.css?v=' "${page}"
79+
grep -q 'css/layout/responsive.css?v=' "${page}"
80+
grep -q 'js/core/site-data.js?v=' "${page}"
81+
grep -q 'js/core/helpers.js?v=' "${page}"
82+
grep -q 'js/features/sidebar.js?v=' "${page}"
83+
grep -q 'js/features/easter-eggs.js?v=' "${page}"
84+
grep -q 'js/features/search.js?v=' "${page}"
85+
grep -q 'js/features/contact-panel.js?v=' "${page}"
86+
grep -q 'js/features/workflow-visual.js?v=' "${page}"
87+
grep -q 'js/bootstrap/app.js?v=' "${page}"
88+
grep -q 'topbar-contact-popover" hidden' "${page}"
89+
done
90+
1891
verify:
1992
name: Verify (Ruby ${{ matrix.ruby }})
2093
runs-on: ubuntu-latest
2194
timeout-minutes: 25
95+
needs: website
2296
strategy:
2397
fail-fast: false
2498
matrix:

.github/workflows/pages.yml

Lines changed: 34 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,26 @@ jobs:
3838
- name: Validate docs website shell
3939
shell: bash
4040
run: |
41-
node --check docs/website/app.js
41+
for file in docs/website/js/core/*.js docs/website/js/features/*.js docs/website/js/bootstrap/*.js; do
42+
node --check "$file"
43+
done
4244
test -f docs/website/index.html
4345
test -f docs/website/download.html
44-
test -f docs/website/styles.css
46+
test -f docs/website/css/core/base.css
47+
test -f docs/website/css/layout/topbar.css
48+
test -f docs/website/css/layout/sidebar.css
49+
test -f docs/website/css/layout/content.css
50+
test -f docs/website/css/layout/responsive.css
51+
test -f docs/website/css/components/workflow.css
52+
test -f docs/website/css/components/modules.css
53+
test -f docs/website/js/core/site-data.js
54+
test -f docs/website/js/core/helpers.js
55+
test -f docs/website/js/features/sidebar.js
56+
test -f docs/website/js/features/easter-eggs.js
57+
test -f docs/website/js/features/search.js
58+
test -f docs/website/js/features/contact-panel.js
59+
test -f docs/website/js/features/workflow-visual.js
60+
test -f docs/website/js/bootstrap/app.js
4561
test -f docs/website/web_assets/media/favicon.ico
4662
test -f docs/website/web_assets/media/asrfacet-rb-site-preview.png
4763
test -f docs/website/web_assets/installers/asrfacet-rb-installer-linux.sh
@@ -58,8 +74,21 @@ jobs:
5874
[ ${#pages[@]} -gt 0 ]
5975
for page in "${pages[@]}"; do
6076
grep -q 'topbar-contact-popover" hidden' "${page}"
61-
grep -q 'styles.css?v=' "${page}"
62-
grep -q 'app.js?v=' "${page}"
77+
grep -q 'css/core/base.css?v=' "${page}"
78+
grep -q 'css/layout/topbar.css?v=' "${page}"
79+
grep -q 'css/layout/sidebar.css?v=' "${page}"
80+
grep -q 'css/layout/content.css?v=' "${page}"
81+
grep -q 'css/components/workflow.css?v=' "${page}"
82+
grep -q 'css/components/modules.css?v=' "${page}"
83+
grep -q 'css/layout/responsive.css?v=' "${page}"
84+
grep -q 'js/core/site-data.js?v=' "${page}"
85+
grep -q 'js/core/helpers.js?v=' "${page}"
86+
grep -q 'js/features/sidebar.js?v=' "${page}"
87+
grep -q 'js/features/easter-eggs.js?v=' "${page}"
88+
grep -q 'js/features/search.js?v=' "${page}"
89+
grep -q 'js/features/contact-panel.js?v=' "${page}"
90+
grep -q 'js/features/workflow-visual.js?v=' "${page}"
91+
grep -q 'js/bootstrap/app.js?v=' "${page}"
6392
done
6493
6594
- name: Validate download center wiring
@@ -74,7 +103,7 @@ jobs:
74103
grep -q 'web_assets/installers/asrfacet-rb-installer-macos.sh' docs/website/download.html
75104
grep -q 'web_assets/installers/asrfacet-rb-installer-windows.ps1' docs/website/download.html
76105
grep -q 'web_assets/installers/asrfacet-rb-installer-windows.cmd' docs/website/download.html
77-
grep -q '"download.html": { title: "Download Center"' docs/website/app.js
106+
grep -q '"download.html": { title: "Download Center"' docs/website/js/core/site-data.js
78107
79108
- name: Upload static site artifact
80109
uses: actions/upload-pages-artifact@v3

docs/architecture.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,3 +164,28 @@ The local web UI uses:
164164
- `ASRFacet::Web::Server` for the local control panel
165165

166166
Session drafts survive accidental closes, and running sessions use heartbeats so stale runs can be recovered after interruption without falsely corrupting active state.
167+
168+
## Documentation Website Structure
169+
170+
The static documentation site under `docs/website/` is split into smaller
171+
asset segments so it stays easy to maintain as pages grow.
172+
173+
### Website CSS
174+
175+
- `docs/website/css/core/` holds shared tokens and baseline styling.
176+
- `docs/website/css/layout/` holds structural layout layers such as top bar,
177+
sidebar, page body, and responsive behavior.
178+
- `docs/website/css/components/` holds reusable feature styling such as the
179+
workflow visual and documentation modules.
180+
181+
### Website JavaScript
182+
183+
- `docs/website/js/core/` holds shared website data, state, and helpers.
184+
- `docs/website/js/features/` holds isolated UI features such as search,
185+
sidebar behavior, contact panel logic, easter eggs, and the workflow visual.
186+
- `docs/website/js/bootstrap/` holds the final page bootstrap that wires the
187+
shared features together.
188+
189+
This keeps the docs site aligned with the same broader project principle used
190+
elsewhere in ASRFacet-Rb: shared state first, focused modules second, and a
191+
small bootstrap layer at the edge.

docs/website/app.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1-
// Website behavior now loads from docs/website/js/*.html-included segments.
2-
// This legacy entry is intentionally kept minimal so the repo does not carry
1+
// Website behavior now loads from docs/website/js/core,
2+
// docs/website/js/features, and docs/website/js/bootstrap.
3+
// This legacy entry stays intentionally minimal so the repo does not carry
34
// two parallel copies of the same website logic.

docs/website/cli-reference.html

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!DOCTYPE html>
1+
<!DOCTYPE html>
22
<html lang="en">
33
<head>
44
<meta charset="UTF-8">
@@ -19,13 +19,13 @@
1919
<meta name="twitter:image" content="https://raw.githubusercontent.com/voltsparx/ASRFacet-Rb/main/docs/website/web_assets/media/asrfacet-rb-site-preview.png">
2020
<link rel="preconnect" href="https://fonts.googleapis.com">
2121
<link href="https://fonts.googleapis.com/css2?family=Share+Tech+Mono&family=Rajdhani:wght@300;400;500;600;700&family=Orbitron:wght@400;600;700;900&display=swap" rel="stylesheet">
22-
<link rel="stylesheet" href="css/base.css?v=1.0.0">
23-
<link rel="stylesheet" href="css/topbar.css?v=1.0.0">
24-
<link rel="stylesheet" href="css/sidebar.css?v=1.0.0">
25-
<link rel="stylesheet" href="css/content.css?v=1.0.0">
26-
<link rel="stylesheet" href="css/workflow.css?v=1.0.0">
27-
<link rel="stylesheet" href="css/modules.css?v=1.0.0">
28-
<link rel="stylesheet" href="css/responsive.css?v=1.0.0">
22+
<link rel="stylesheet" href="css/core/base.css?v=1.0.0">
23+
<link rel="stylesheet" href="css/layout/topbar.css?v=1.0.0">
24+
<link rel="stylesheet" href="css/layout/sidebar.css?v=1.0.0">
25+
<link rel="stylesheet" href="css/layout/content.css?v=1.0.0">
26+
<link rel="stylesheet" href="css/components/workflow.css?v=1.0.0">
27+
<link rel="stylesheet" href="css/components/modules.css?v=1.0.0">
28+
<link rel="stylesheet" href="css/layout/responsive.css?v=1.0.0">
2929
<link rel="icon" href="web_assets/media/favicon.ico" sizes="any">
3030
<link rel="shortcut icon" href="web_assets/media/favicon.ico" type="image/x-icon">
3131
</head>
@@ -141,14 +141,14 @@
141141
<div><div class="footer-col-title">Home</div><a class="footer-link" href="index.html">Overview</a><a class="footer-link" href="getting-started.html#quickstart">Quick Start</a></div>
142142
</footer>
143143

144-
<script src="js/core.js?v=1.0.0"></script>
145-
<script src="js/helpers.js?v=1.0.0"></script>
146-
<script src="js/sidebar.js?v=1.0.0"></script>
147-
<script src="js/easter-eggs.js?v=1.0.0"></script>
148-
<script src="js/search.js?v=1.0.0"></script>
149-
<script src="js/contact-panel.js?v=1.0.0"></script>
150-
<script src="js/workflow-visual.js?v=1.0.0"></script>
151-
<script src="js/app.js?v=1.0.0"></script>
144+
<script src="js/core/site-data.js?v=1.0.0"></script>
145+
<script src="js/core/helpers.js?v=1.0.0"></script>
146+
<script src="js/features/sidebar.js?v=1.0.0"></script>
147+
<script src="js/features/easter-eggs.js?v=1.0.0"></script>
148+
<script src="js/features/search.js?v=1.0.0"></script>
149+
<script src="js/features/contact-panel.js?v=1.0.0"></script>
150+
<script src="js/features/workflow-visual.js?v=1.0.0"></script>
151+
<script src="js/bootstrap/app.js?v=1.0.0"></script>
152152
</body>
153153
</html>
154154

0 commit comments

Comments
 (0)