NHentai Improved
V3 Update
I have rewritten large parts of the script to work with the fundamental changes NHentai made to the site.
It appears to now be working, but some issues remain, and it is not yet thoroughly tested. I will work on fixing remaining issues at some point.
Known issues:
- Alt version grouping as a whole has not been implemented yet
- Infinite load:
- No Favourites page handling
- Not handling rare language flags (only en/ch/jp)
- Sometimes gets stuck not infinite loading after a bunch of random-ish navigation?
- Reader: Improved Zoom doesn't play nice with "Image Scaling: Fit on Screen"
- Looks like NHentai is serving mixed content? (http / https). This can cause "Blocked loading mixed active content" errors when making API calls.
- This can be "fixed" by making the browser force https everywhere (which is good practice anyway)
- Chrome doesn't appear to have an equivalent option (it does have "Always use secure connections", but that doesn't appear to be good enough) and the various force HTTPS extensions don't work either.
- Not tested without login at all
- Can't enter NHI settings unless logged in
- Not tested on mobile at all
Features
- Block Extra Ads (on by default)
- Completely remove non-english (off by default)
- Partially fade out non-english (on by default)
- Non-english fade opacity (0.3 by default)
- Dynamically load more comics as you scroll (on by default)
- Width of the thumbnail container (0 by default, [0 = site default])
- Width of the thumbnails (0 by default, [0 = site default])
- Mark as read Feature (on by default)
- Marked as read fade opacity (0.3 by default)
- Mark as read tag font size (15 by default)
- Subscribe Feature (on by default)
- Version Grouping Feature (on by default) (CURRENTLY NOT IMPLEMENTED FOR V3)
- Filter out normal brackets for version searches (off by default)
(square brackets are always filtered out regardless of this setting) (CURRENTLY NOT IMPLEMENTED FOR V3)
- Automatically group on-page comics (on by default)
(doesn't search the site, just current page) (CURRENTLY NOT IMPLEMENTED FOR V3)
- Improved Zoom for comic reader (on by default)
- Remember last used zoom level for comic reader (on by default)
- Remove Native Blacklisted comics (on by default)
- Backup(Import/Export/Sync(sort of)) settings and data
Some extra info about specific features
Block Extra Ads
Blocks extra ads not caught by normal ad blockers (only tested with uBlock Origin)
Dynamic page loading
Scrolling to the bottom of the page in a browse section loads in more comics dynamically.
Mark as read
Comics marked as read are partially faded out with a "READ" tag on the bottom right of that comic.
You can mark comics as read/unread on the main comic info page for that comic.
Subscriptions
You can now subscribe to artists/groups/tags/languages/categories. Currently all this does is list subscriptions on a new subscriptions page and highlight subscribed tags.
Version Grouping
By clicking "Find Alt Versions" on the thumbnail of any comic, alternative versions of said comic get searched from the entire site and grouped in with it. i.e. different language versions of the same comic in most cases.
This relies on titles so it isn't perfect. Occasional false positives or missing matches are possible.
Comic Reader Improved Zoom
Allows you to zoom below 1.0 and moves in 0.1 increments
Backups
Lists of marked comics, blocked tags, subs and settings are stored in your browser's local data. Meaning if you wipe your browser, this data too gets wiped. There are import/export buttons for NHentai Improved's data below the settings, so you can make backups if you wish. During import, you can also choose if you wish to combine/replace/discard changes to Marked-As-Read and Subscription data. This means, you could have a separate instance of this script on your phone and PC and bring in your backup to one or the other to "sync" all your Marked-As-Read and Subscriptions data.
You'll find the settings in a new section in the standard site settings.
Tested and working script managers:
- Tampermonkey, last tested (NHI v3.0.0): v5.4.1
- Violentmonkey (Android), last tested (NHI v2.1.3): v2.29.0 *
Tested and working browsers:
- LibreWolf, last tested (NHI v3.0.0): v150.0-1
- Firefox, last tested (NHI v3.0.0): v150
- Chrome, last tested (NHI v3.0.0): v147.0.7727.117 - Has some issues with at least infinite load.
- Kiwi Browser (Android), last tested (NHI v2.1.3): v124.0.6327.4 *
*Only cursory testing. Some combinations of settings are yet to be tested.