lnreader-plugins
lnreader-plugins copied to clipboard
fix(vi/hako): fix chapterPath parsing, decrypt protected content, format notes tag, remove suggestion banners
Summary
This PR fixes the Hako plugin (ln.hako) which was broken due to encrypted chapter content and incorrect chapter path parsing. It also cleans up the chapter content by removing recommendation banners and formats note tags.
Details of Changes
- Decryption Support: Implemented decryption helpers (XOR shuffle, base64 reverse) to decrypt the protected chapter content (
#chapter-c-protected). - Path Parsing Fix: Fixed the chapter path parsing issue where the domain was not stripped correctly, causing fetch errors.
- Note Tags Formatting: Formatted
[note(\d+)]tags into HTML span/anchor tags following the original website's logic for proper rendering. - Content Cleanup: Removed recommendation/suggestion banners at the end of chapters to provide a cleaner reading experience.
- Version Bump: Bumped the plugin version to
1.1.1.
Checklist
- [X] Update version code if an existing plugin was modified
- [X] Test changes in Plugin Playground or the app
- [ ] Reference related issues in the PR body (e.g. Closes #xyz) (No related issues)