-
Notifications
You must be signed in to change notification settings - Fork 72
docs: audit and fix documentation architecture #1049
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
1PoPTRoN
wants to merge
1
commit into
kubestellar:main
Choose a base branch
from
1PoPTRoN:docs-fix-and-audit
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,45 @@ | ||
| # KubeStellar Documentation Developer Guide | ||
|
|
||
| Welcome! This guide explains how the documentation system works and how to contribute effectively. | ||
|
|
||
| ## Architecture | ||
|
|
||
| This site is built with **Next.js 15** and **Nextra 4**. It uses a hybrid approach: | ||
|
|
||
| - **Unified Content**: Almost all documentation resides in `docs/content/`. | ||
| - **Dynamic Routing**: The `src/app/docs/[...slug]` route dynamically renders Markdown/MDX files from the content folder. | ||
| - **Navigation**: Sidebar structure is defined statically in `src/app/docs/page-map.ts`. | ||
|
|
||
| ## How to Add a Page | ||
|
|
||
| 1. **Add the File**: Create a `.md` or `.mdx` file in `docs/content/` (or a subfolder). | ||
| 2. **Update Navigation**: Add an entry to the `NAV_STRUCTURE` array in [page-map.ts](file:///Users/p0ptr0n/Documents/c0des/LFX/docs/src/app/docs/page-map.ts). | ||
| ```typescript | ||
| { 'My New Page': 'path/to/file.md' } | ||
| ``` | ||
|
|
||
| ## Images and Assets | ||
|
|
||
| - Images should be placed in `docs/content/images/` or a subfolder within the project (e.g., `docs/content/console/images/`). | ||
| - **Pathing Rule**: Use the standardized `/docs-images/` prefix in your MDX/Markdown. | ||
| - Good: `` | ||
| - Next.js will automatically rewrite this to the correct local API for serving images from the content folder. | ||
|
|
||
| ## Internationalization (i18n) | ||
|
|
||
| - UI strings are located in `messages/*.json`. | ||
| - **Sidebar Titles**: We are currently migrating sidebar titles to use `next-intl`. Use the translation keys defined in the JSON files. | ||
|
|
||
| ## Maintenance Commands | ||
|
|
||
| - `npm run dev`: Start local development server. | ||
| - `npm run build`: Run production build (verifies MDX integrity). | ||
| - `npm run lint`: Check for code and accessibility issues. | ||
|
|
||
| ## Common Issues | ||
|
|
||
| ### Build Failure: `localStorage is not defined` | ||
| The build runs on the server. If a dependency uses `localStorage`, it will break. We have a mock in `next.config.ts`, but try to keep client-side code inside `useEffect` or behind a client-check. | ||
|
|
||
| ### Link Resolution | ||
| The dynamic router tries to resolve relative links. If a link breaks, check that the file path in [page-map.ts](file:///Users/p0ptr0n/Documents/c0des/LFX/docs/src/app/docs/page-map.ts) exactly matches the file on disk. | ||
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change | ||
|---|---|---|---|---|
|
|
@@ -224,7 +224,29 @@ The console includes 44+ additional specialized cards across categories like: | |||
| - **Deploy** - Deployment management and progress tracking | ||||
| - **Events** - Event timeline and filtering | ||||
| - **Data Compliance** - Data classification and compliance checks | ||||
| - **Arcade** - Interactive visualizations | ||||
| - **Data Compliance** - Data classification and compliance checks | ||||
|
||||
| - **Data Compliance** - Data classification and compliance checks |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These links point to a local
file:///Users/...path, which won’t work for other contributors or on GitHub. Use a relative repo link instead (e.g.src/app/docs/page-map.ts) or a standard GitHub URL.