Skip to content

Commit 21282fe

Browse files
committed
Update: Wiki page
1 parent 389f2ad commit 21282fe

5 files changed

Lines changed: 698 additions & 622 deletions

File tree

.github/workflows/generate-wiki.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ on:
77
- 'src/**'
88
- 'docs/**'
99
- 'scripts/generate-wiki.mjs'
10+
- '.github/workflows/generate-wiki.yml'
1011
workflow_dispatch:
1112

1213
permissions:
@@ -62,7 +63,10 @@ jobs:
6263
cd -
6364
fi
6465
65-
# Copy generated wiki pages (overwrite existing auto-generated ones)
66+
# Replace generated wiki pages so removed/renamed pages do not linger.
67+
find "$WIKI_DIR_TMP" -maxdepth 1 -type f -name '*.md' -delete
68+
69+
# Copy generated wiki pages.
6670
cp wiki/*.md "$WIKI_DIR_TMP/"
6771
6872
# Commit and push

docs/DOCUMENTATION-STANDARD.md

Lines changed: 60 additions & 68 deletions
Original file line numberDiff line numberDiff line change
@@ -1,54 +1,51 @@
11
# Documentation Standard
22

3-
This project auto-generates wiki pages from source code JSDoc comments. Follow these standards to ensure proper wiki generation.
4-
5-
## Plugin Classes
6-
7-
Add a JSDoc block **directly above** every exported class in `src/src/plugins/`:
8-
9-
```typescript
10-
/**
11-
* @wiki Automatically accepts the matchmaking queue when a game is found.
12-
* @author Lyfhael
13-
* @modifier Elaina Da Catto
14-
* @usage
15-
* 1. Open League Client settings
16-
* 2. Navigate to **Elaina Theme** → **Plugin Settings**
17-
* 3. Toggle **Auto Accept** to enabled
18-
* @settings auto_accept, auto_accept_button
19-
*/
20-
export class AutoAccept {
21-
```
3+
The GitHub Wiki is generated from centralized documentation files. Do not edit generated wiki pages by hand.
4+
5+
## Wiki Sources
6+
7+
| File | Purpose |
8+
|------|---------|
9+
| `docs/wiki-content.json` | Page order, installation text, asset instructions, grouped wiki sections, FAQ content. |
10+
| `docs/settings-meta.json` | Setting categories, descriptions, and value types. |
11+
| `src/src/config/datastoreDefault.js` | Default values shown in generated setting tables. |
12+
| `src/src/locales/default.js` | UI labels shown beside setting keys when available. |
13+
14+
The generator no longer depends on editing JSDoc in every plugin file for user-facing wiki content. JSDoc can still be useful for code maintainers, but wiki content should be maintained in `docs/wiki-content.json` and `docs/settings-meta.json`.
15+
16+
## Required Wiki Structure
2217

23-
### Required Tags (enforced by ESLint)
18+
The generated wiki contains these pages in this order:
2419

25-
| Tag | Purpose | Example |
26-
|-----|---------|---------|
27-
| `@wiki` | User-facing feature description (displayed in wiki) | `@wiki Adds a dodge button in champion select` |
20+
1. Home
21+
2. Installation instructions
22+
3. Theme customization
23+
- 3.1. Add wallpaper/audio
24+
- 3.2. Theme settings
25+
- 3.3. Plugins settings
26+
4. Backup/Restore
27+
5. FAQ & Troubleshooting
2828

29-
### Recommended Tags
29+
The order is controlled by the `navigation` array in `docs/wiki-content.json`.
3030

31-
| Tag | Purpose | Example |
32-
|-----|---------|---------|
33-
| `@author` | Original author | `@author Elaina Da Catto` |
34-
| `@modifier` | Who modified the original code | `@modifier Elaina Da Catto` |
35-
| `@usage` | Step-by-step instructions for end users | See example above |
36-
| `@settings` | Comma-separated DataStore keys this plugin uses | `@settings dodge-button, auto_accept` |
31+
## Updating Wiki Content
3732

38-
### Notes
33+
Use `docs/wiki-content.json` for page text and section grouping.
3934

40-
- Use `@wiki` instead of `@description` for user-facing text. `@description` is also supported but `@wiki` takes priority.
41-
- The `@usage` tag supports Markdown formatting.
42-
- The wiki generator also detects `ElainaData.get("key")` / `ElainaData.set("key")` calls to automatically find which settings a plugin uses.
35+
Common edits:
36+
37+
- Add or rewrite installation instructions in `installation`.
38+
- Add asset rules or supported formats in `themeCustomization.assets`.
39+
- Move a setting to another wiki group by editing `themeSettingGroups` or `pluginSettingGroups`.
40+
- Add FAQ entries in `faq.items`.
41+
- Add runtime-only settings to `runtimeSettingKeys` when the key is created outside `datastoreDefault.js`.
4342

4443
## Settings Documentation
4544

46-
Settings descriptions live in `docs/settings-meta.json`. When you add a new setting to `datastoreDefault.js`:
45+
Every setting displayed in the wiki should have an entry in `docs/settings-meta.json`.
4746

48-
1. Add the key to `docs/settings-meta.json` with a `category`, `description`, and `type`.
49-
2. The wiki generator will warn about any missing settings.
47+
Example:
5048

51-
Example entry:
5249
```json
5350
{
5451
"auto_accept": {
@@ -59,41 +56,36 @@ Example entry:
5956
}
6057
```
6158

62-
### Categories
63-
64-
| Key | Name | Used for |
65-
|-----|------|----------|
66-
| `theme-core` | Core Theme | Basic theme behavior, version |
67-
| `wallpaper-audio` | Wallpaper & Audio | Backgrounds, audio playback |
68-
| `theme-visual` | Visual Customization | Fonts, UI tweaks, colors |
69-
| `custom-assets` | Custom Assets | Icons, banners, avatars |
70-
| `plugins` | Plugin Settings | Per-plugin configuration |
71-
| `tft` | TFT Settings | TFT-specific toggles |
72-
| `backup` | Backup & Restore | Cloud backup settings |
73-
| `deprecated` | Deprecated | Unused settings |
74-
75-
New categories can be added to the `categories` object in `settings-meta.json`.
59+
When adding a new key to `datastoreDefault.js`:
7660

77-
## ESLint Enforcement
61+
1. Add its category, description, and type to `docs/settings-meta.json`.
62+
2. If it should appear in the wiki, add it to a group in `docs/wiki-content.json`.
63+
3. Run `pnpm run wiki:check`.
64+
4. Run `pnpm run wiki:generate` and review the generated files in `wiki/`.
7865

79-
The ESLint config (`eslint.config.js`) enforces documentation rules:
66+
## Categories
8067

81-
- **Current level**: `warn` — shows warnings but doesn't block commits
82-
- **To enforce strictly**: Change `warn``error` in `eslint.config.js` for `jsdoc/require-jsdoc` and `jsdoc/require-description`
83-
84-
## Git Hooks
85-
86-
- **Pre-commit**: Runs ESLint on staged files via `lint-staged`
87-
- **Pre-push**: Runs full lint + wiki validation (`--check` mode)
88-
89-
## Wiki Generation
68+
| Key | Name | Used for |
69+
|-----|------|----------|
70+
| `theme-core` | Core Theme | Basic theme behavior, version, language, update notices. |
71+
| `wallpaper-audio` | Wallpaper & Audio | Backgrounds, audio playback, slideshow, window effects. |
72+
| `theme-visual` | Visual Customization | Fonts, UI tweaks, colors, layout visibility. |
73+
| `custom-assets` | Custom Assets | Icons, banners, avatars, and visual replacements. |
74+
| `plugins` | Plugin Settings | Optional plugin behavior and plugin configuration. |
75+
| `tft` | TFT Settings | TFT-specific toggles. |
76+
| `backup` | Backup & Restore | Manual and cloud backup settings. |
77+
| `deprecated` | Deprecated | Settings no longer in active use. |
78+
| `internal` | Internal | Values not meant to be shown to normal users. |
79+
80+
## Validation
9081

9182
```bash
92-
# Generate wiki locally
93-
pnpm run wiki:generate
94-
95-
# Check documentation coverage (no file writes)
9683
pnpm run wiki:check
84+
pnpm run wiki:generate
9785
```
9886

99-
The GitHub Action (`.github/workflows/generate-wiki.yml`) runs on push to `main` and auto-publishes to the repo wiki.
87+
`wiki:check` validates that referenced settings are documented and that required pages are present. Warnings are informational; errors fail the check.
88+
89+
## Publishing
90+
91+
The GitHub Action at `.github/workflows/generate-wiki.yml` runs the generator and pushes generated Markdown files to the repository wiki. It replaces old generated Markdown pages so removed or renamed pages do not remain in the wiki.

docs/settings-meta.json

Lines changed: 76 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,11 @@
4040
"description": "Master toggle to enable or disable all Elaina Theme plugins.",
4141
"type": "boolean"
4242
},
43+
"Theme-language": {
44+
"category": "theme-core",
45+
"description": "Theme UI language. Use client to follow the League Client language.",
46+
"type": "string"
47+
},
4348
"Theme-version": {
4449
"category": "theme-core",
4550
"description": "Current installed theme version (managed automatically).",
@@ -160,6 +165,46 @@
160165
"description": "Time between wallpaper changes in slideshow mode (milliseconds).",
161166
"type": "number"
162167
},
168+
"WallpaperAudio-timeUpdate": {
169+
"category": "wallpaper-audio",
170+
"description": "Interval for saving wallpaper/audio playback progress to ElainaData (milliseconds).",
171+
"type": "number"
172+
},
173+
"Playback-speed": {
174+
"category": "wallpaper-audio",
175+
"description": "Wallpaper video playback speed as a percentage.",
176+
"type": "number"
177+
},
178+
"disable-theme-wallpaper": {
179+
"category": "wallpaper-audio",
180+
"description": "Completely disable the theme wallpaper background.",
181+
"type": "boolean"
182+
},
183+
"window-effect-name": {
184+
"category": "wallpaper-audio",
185+
"description": "Window background effect mode such as transparent, acrylic, mica, or vibrancy.",
186+
"type": "string"
187+
},
188+
"window-effect-color-base": {
189+
"category": "wallpaper-audio",
190+
"description": "Base color used by the selected window effect before alpha is applied.",
191+
"type": "string"
192+
},
193+
"window-effect-alpha": {
194+
"category": "wallpaper-audio",
195+
"description": "Alpha component appended to the window effect color.",
196+
"type": "string"
197+
},
198+
"window-effect-color": {
199+
"category": "wallpaper-audio",
200+
"description": "Computed window effect color including alpha.",
201+
"type": "string"
202+
},
203+
"window-effect-material": {
204+
"category": "wallpaper-audio",
205+
"description": "Material variant used by window effects that support material selection.",
206+
"type": "string"
207+
},
163208
"turnoff-audio-ingame": {
164209
"category": "wallpaper-audio",
165210
"description": "Automatically mute theme audio when in a game.",
@@ -415,6 +460,31 @@
415460
"description": "Hide the theme usage time counter in settings.",
416461
"type": "boolean"
417462
},
463+
"hide-summoner-rift-5v5": {
464+
"category": "theme-visual",
465+
"description": "Hide the Summoner's Rift 5v5 tab or section in the play page.",
466+
"type": "boolean"
467+
},
468+
"hide-aram": {
469+
"category": "theme-visual",
470+
"description": "Hide the ARAM tab or section in the play page.",
471+
"type": "boolean"
472+
},
473+
"hide-arena": {
474+
"category": "theme-visual",
475+
"description": "Hide the Arena tab or section in the play page.",
476+
"type": "boolean"
477+
},
478+
"hide-custom-game-section": {
479+
"category": "theme-visual",
480+
"description": "Hide the custom game section in the play page.",
481+
"type": "boolean"
482+
},
483+
"hide-tft": {
484+
"category": "tft",
485+
"description": "Hide the TFT tab or section in the play page.",
486+
"type": "boolean"
487+
},
418488
"hide-tft-match-history": {
419489
"category": "tft",
420490
"description": "Hide TFT match history section.",
@@ -470,6 +540,11 @@
470540
"description": "Show the auto-accept toggle button in the lobby.",
471541
"type": "boolean"
472542
},
543+
"auto_accept_delay": {
544+
"category": "plugins",
545+
"description": "Delay before auto-accepting a ready check (milliseconds).",
546+
"type": "number"
547+
},
473548
"dodge-button": {
474549
"category": "plugins",
475550
"description": "Show a dodge button in champion select to leave the queue.",
@@ -716,4 +791,4 @@
716791
"hidden": true
717792
}
718793
}
719-
}
794+
}

0 commit comments

Comments
 (0)