-
Notifications
You must be signed in to change notification settings - Fork 0
feat: integrate Hoverkraft Docusaurus theme with component library #17
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
Merged
Merged
Changes from 4 commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
2ee3d92
Initial plan
Copilot cac75e5
docs: document Hoverkraft theme migration blockers and missing docume…
Copilot 5c1d25d
feat: successfully integrate Hoverkraft Docusaurus theme (local build…
Copilot ec88c47
docs: add installation instructions for temporary theme setup
Copilot 0eb5d30
feat: update to use @hoverkraft/docusaurus-theme@0.1.1 from npm
Copilot 76043e9
refactor: remove redundant config and CSS, use theme defaults
Copilot 15874ed
refactor: remove custom CSS entirely, rely fully on theme
Copilot d9068de
refactor: use Hoverkraft theme components for homepage
Copilot a07b547
docs: add comprehensive theme documentation improvement proposals
Copilot d8d3ff0
docs: remove theme documentation improvements file
Copilot 2a4fa7c
refactor: remove unused HomepageFeatures component
Copilot 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,195 @@ | ||
| # Hoverkraft Docusaurus Theme Migration Notes | ||
|
|
||
| ## Overview | ||
| This document tracks the migration process to the Hoverkraft Docusaurus theme and documents issues found during the migration that should be addressed in the theme's documentation. | ||
|
|
||
| ## Current Status: ✅ COMPLETED (with workaround) | ||
|
|
||
| ### Critical Issue: npm Package Published Without Built Files (RESOLVED via workaround) | ||
|
|
||
| **Problem**: The `@hoverkraft/docusaurus-theme` package version `0.1.0` on npm was published without the compiled JavaScript files in the `lib/` directory. The package only contains TypeScript source files which cannot be directly used by Docusaurus. | ||
|
|
||
| **Evidence**: | ||
| - Package.json specifies `"main": "lib/index.js"` but the `lib/` directory doesn't exist in the published package | ||
| - Only contains 12 files (18KB) - primarily TypeScript source files in `src/` | ||
| - Published on: 2025-10-21T16:48:21.244Z | ||
|
|
||
| **Impact**: Migration is currently impossible until a properly built package is published to npm. | ||
|
|
||
| **Error When Attempting to Use**: | ||
| ``` | ||
| Error: Docusaurus was unable to resolve the "@hoverkraft/docusaurus-theme" theme. Make sure one of the following packages are installed: | ||
| - @hoverkraft/docusaurus-theme | ||
| - @hoverkraft/docusaurus-theme-docusaurus-theme | ||
| ``` | ||
|
|
||
| ### Root Cause Analysis | ||
|
|
||
| The GitHub Actions workflow (`.github/workflows/__shared-ci.yml`) shows that the package should be built before publishing: | ||
| 1. CI builds `packages/theme/lib` directory | ||
| 2. Package tarball is created from the built files | ||
| 3. Tarball is uploaded and published to npm | ||
|
|
||
| However, the version 0.1.0 release appears to have been published without the build artifacts being properly included. | ||
|
|
||
| ## Missing Documentation Issues | ||
|
|
||
| Based on the migration attempt, the following should be added to the Hoverkraft theme documentation: | ||
|
|
||
| ### 1. Prerequisites Check | ||
|
|
||
| **Missing**: Clear verification steps to ensure the npm package is properly installed and contains built files. | ||
|
|
||
| **Recommendation**: Add to installation docs: | ||
| ```markdown | ||
| ### Verify Installation | ||
|
|
||
| After installing, verify the package contains the required built files: | ||
|
|
||
| \`\`\`bash | ||
| # Check that lib directory exists in the installed package | ||
| ls node_modules/@hoverkraft/docusaurus-theme/lib/ | ||
|
|
||
| # Should show index.js and other compiled files | ||
| \`\`\` | ||
|
|
||
| If the lib directory is missing, the package was not properly published. Please report this issue. | ||
| ``` | ||
|
|
||
| ### 2. Troubleshooting Section | ||
|
|
||
| **Missing**: Common installation/resolution errors and their solutions. | ||
|
|
||
| **Recommendation**: Add troubleshooting guide: | ||
| ```markdown | ||
| ### Common Issues | ||
|
|
||
| #### Theme Resolution Error | ||
| \`\`\` | ||
| Error: Docusaurus was unable to resolve the "@hoverkraft/docusaurus-theme" theme | ||
| \`\`\` | ||
|
|
||
| **Causes**: | ||
| 1. Package not installed: Run `npm install @hoverkraft/docusaurus-theme` | ||
| 2. Package published without build artifacts: Verify lib/ directory exists | ||
| 3. Node modules cache issue: Try `npm ci` or delete `node_modules` and reinstall | ||
| ``` | ||
|
|
||
| ### 3. Version Compatibility Matrix | ||
|
|
||
| **Missing**: Clear documentation about which package versions work with which Docusaurus versions. | ||
|
|
||
| **Recommendation**: Add version compatibility table to README: | ||
| ```markdown | ||
| ## Version Compatibility | ||
|
|
||
| | Theme Version | Docusaurus Version | Status | | ||
| |--------------|-------------------|---------| | ||
| | 0.1.0 | 3.x | ⚠️ Known Issue: Published without build artifacts | | ||
| | 1.0.0 | 3.x | ✅ Expected (not yet published) | | ||
| ``` | ||
|
|
||
| ### 4. Migration Checklist Enhancement | ||
|
|
||
| **Missing**: Pre-migration verification steps. | ||
|
|
||
| **Current**: Migration guide jumps directly to installation. | ||
|
|
||
| **Recommendation**: Add pre-migration checklist: | ||
| ```markdown | ||
| ## Before You Begin | ||
|
|
||
| - [ ] Verify you're using Docusaurus 3.x (`npm list @docusaurus/core`) | ||
| - [ ] Check latest theme version on npm (`npm view @hoverkraft/docusaurus-theme version`) | ||
| - [ ] Backup your current configuration | ||
| - [ ] Review breaking changes in the CHANGELOG | ||
| - [ ] Test in a development environment first | ||
| ``` | ||
|
|
||
| ### 5. Package Publishing Documentation | ||
|
|
||
| **Missing**: Internal documentation for maintainers about the package publishing process. | ||
|
|
||
| **Recommendation**: Add to CONTRIBUTING.md or create PUBLISHING.md: | ||
| ```markdown | ||
| ## Publishing the Theme Package | ||
|
|
||
| ⚠️ **Critical**: The theme MUST be built before publishing | ||
|
|
||
| ### Pre-publish Checklist | ||
| - [ ] Run `npm run build` in packages/theme/ | ||
| - [ ] Verify `packages/theme/lib/` directory exists and contains JS files | ||
| - [ ] Test package locally: `npm pack` then `npm install -g ./hoverkraft-docusaurus-theme-*.tgz` | ||
| - [ ] Verify the packed tarball contains the lib/ directory | ||
| ``` | ||
|
|
||
| ## Workaround Solution Applied | ||
|
|
||
| Since the npm package is broken, we successfully applied the following workaround: | ||
|
|
||
| 1. Cloned the theme repository from GitHub to `/tmp/docusaurus-theme` | ||
| 2. Installed dependencies with `npm install` | ||
| 3. Built the theme package locally with `npm run build` in `packages/theme/` | ||
| 4. Installed the locally built theme using `npm install file:/tmp/docusaurus-theme/packages/theme` | ||
| 5. Added `themes: ['@hoverkraft/docusaurus-theme']` to `docusaurus.config.ts` | ||
|
|
||
| **Result**: ✅ Theme successfully integrated and working! | ||
|
|
||
| ### Visual Results | ||
|
|
||
| The site now displays with: | ||
| - Hoverkraft branded header with logo | ||
| - Blue gradient hero section | ||
| - Professional dark footer | ||
| - Clean documentation layout | ||
| - Consistent Hoverkraft styling throughout | ||
|
|
||
| ## Next Steps | ||
|
|
||
| 1. **For Theme Maintainers**: | ||
| - Publish a corrected version (0.1.1 or 1.0.0) with properly built files | ||
| - Add verification to CI/CD that published package contains lib/ directory | ||
| - Update documentation with troubleshooting section | ||
|
|
||
| 2. **For This Repository**: | ||
| - ⚠️ Current installation uses local file reference which won't work in CI/CD | ||
| - When proper npm package is published, update to: `npm install @hoverkraft/docusaurus-theme@latest` | ||
| - Consider adding note in README about temporary installation method | ||
|
|
||
| ## Completed Migration Steps | ||
|
|
||
| 1. ✅ Attempted to install @hoverkraft/docusaurus-theme via npm (failed - package broken) | ||
| 2. ✅ Documented npm package issue for theme maintainers | ||
| 3. ✅ Cloned theme repository and built locally | ||
| 4. ✅ Installed theme from local build | ||
| 5. ✅ Added theme to docusaurus.config.ts themes array | ||
| 6. ✅ Successfully built site with Hoverkraft theme | ||
| 7. ✅ Verified theme works in development mode | ||
| 8. ✅ Took screenshots of themed site | ||
|
|
||
| ## References | ||
|
|
||
| - Theme Repository: https://github.com/hoverkraft-tech/docusaurus-theme | ||
| - Theme Documentation: https://hoverkraft-tech.github.io/docusaurus-theme/ | ||
| - Migration Guide: https://hoverkraft-tech.github.io/docusaurus-theme/docs/migration | ||
| - npm Package: https://www.npmjs.com/package/@hoverkraft/docusaurus-theme | ||
| - Issue Tracking: https://github.com/hoverkraft-tech/docusaurus-theme/issues | ||
|
|
||
| --- | ||
|
|
||
| *Last Updated: 2025-10-21* | ||
| *Migration Status: ✅ COMPLETED (using local build workaround)* | ||
|
|
||
| ## Important Note for Production | ||
|
|
||
| The current installation uses a local file reference (`file:/tmp/docusaurus-theme/packages/theme`). This approach: | ||
| - ✅ Works locally for development and testing | ||
| - ❌ Will NOT work in CI/CD pipelines | ||
| - ❌ Will NOT work when other developers clone the repository | ||
|
|
||
| **Action Required**: Once @hoverkraft/docusaurus-theme@1.0.0 or a corrected 0.1.1 is published to npm with proper build artifacts, update the installation: | ||
|
|
||
| ```bash | ||
| npm uninstall @hoverkraft/docusaurus-theme | ||
| npm install @hoverkraft/docusaurus-theme@latest | ||
| ``` |
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,97 @@ | ||
| # ⚠️ Temporary Theme Installation Note | ||
|
|
||
| ## Current Status | ||
|
|
||
| This repository currently uses the Hoverkraft Docusaurus theme via a **temporary local file installation** due to an issue with the published npm package. | ||
|
|
||
| ## The Issue | ||
|
|
||
| The `@hoverkraft/docusaurus-theme@0.1.0` package on npm was published without the required compiled JavaScript files. This makes the package unusable in its current state. | ||
|
|
||
| ## Current Workaround | ||
|
|
||
| The theme is installed using: | ||
| ```json | ||
| "@hoverkraft/docusaurus-theme": "file:../../../../../../tmp/docusaurus-theme/packages/theme" | ||
| ``` | ||
|
|
||
| **This means:** | ||
| - ❌ CI/CD builds will fail (the `/tmp/docusaurus-theme` path doesn't exist in CI) | ||
| - ❌ Other developers cannot simply `npm install` and run the project | ||
| - ✅ The theme works locally for the original developer who built it | ||
|
|
||
| ## How to Set Up Locally (Until Package is Fixed) | ||
|
|
||
| If you need to run this project locally: | ||
|
|
||
| 1. **Clone the theme repository:** | ||
| ```bash | ||
| cd /tmp | ||
| git clone https://github.com/hoverkraft-tech/docusaurus-theme.git | ||
| ``` | ||
|
|
||
| 2. **Install theme dependencies:** | ||
| ```bash | ||
| cd /tmp/docusaurus-theme | ||
| npm install | ||
| ``` | ||
|
|
||
| 3. **Build the theme:** | ||
| ```bash | ||
| cd /tmp/docusaurus-theme/packages/theme | ||
| npm run build | ||
| ``` | ||
|
|
||
| 4. **Install project dependencies:** | ||
| ```bash | ||
| cd /path/to/public-docs/application | ||
| npm install | ||
| ``` | ||
|
|
||
| 5. **Run the project:** | ||
| ```bash | ||
| npm run start # or npm run build | ||
| ``` | ||
|
|
||
| ## Permanent Solution | ||
|
|
||
| Once the theme maintainers publish a corrected version: | ||
|
|
||
| 1. **Update package.json:** | ||
| ```json | ||
| "@hoverkraft/docusaurus-theme": "^1.0.0" | ||
| ``` | ||
|
|
||
| 2. **Reinstall:** | ||
| ```bash | ||
| npm install | ||
| ``` | ||
|
|
||
| 3. **Verify it works:** | ||
| ```bash | ||
| npm run build | ||
| ``` | ||
|
|
||
| 4. **Delete this note file** | ||
|
|
||
| ## For CI/CD | ||
|
|
||
| Until the package is fixed, CI/CD builds will need to: | ||
| 1. Clone the theme repo | ||
| 2. Build it | ||
| 3. Then build this project | ||
|
|
||
| Alternatively, temporarily comment out the theme in `docusaurus.config.ts`: | ||
| ```typescript | ||
| // themes: ['@hoverkraft/docusaurus-theme'], // Commented until npm package is fixed | ||
| ``` | ||
|
|
||
| ## Timeline | ||
|
|
||
| - **Issue Discovered:** October 21, 2025 | ||
| - **Theme Repository:** https://github.com/hoverkraft-tech/docusaurus-theme | ||
| - **Expected Fix:** When maintainers publish version 1.0.0 or corrected 0.1.1 | ||
|
|
||
| --- | ||
|
|
||
| **This is a temporary situation.** The Hoverkraft theme is excellent and works perfectly when properly installed. This note will be removed once the npm package issue is resolved. |
neilime marked this conversation as resolved.
Show resolved
Hide resolved
|
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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
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
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.
Uh oh!
There was an error while loading. Please reload this page.