Skip to content

v1.3.2 - Sign-in Fixes & Tab Reordering

Choose a tag to compare

@Thuong180702 Thuong180702 released this 09 Aug 05:21
· 7 commits to main since this release

🚀 Notihub v1.3.2

Release Title: v1.3.2 - Sign-in Fixes & Tab Reordering


⚠️ If you are on v1.3.1, please update

v1.3.1 broke signing in. Two separate regressions, both introduced by that release and both fixed here:

  • Google refused to sign you in, and clicking sign-in bounced you out to your default browser.
  • Zalo's login QR rendered as a blank white square, so it could not be scanned.

Nothing was wrong with your account, your session, or Zalo — v1.3.1 was misrepresenting itself to both sites. Details below.


🛠️ Fixes

🔑 Google sign-in — a capital letter in the User-Agent

v1.3.1 renamed the app to "Notihub". Electron builds its User-Agent out of the app's own name, and the code that strips that name back out was a regex hardcoded to the lowercase notihub. So every service started seeing:

… (KHTML, like Gecko) Notihub/43.3.0 Chrome/150.0.7871.212 Safari/537.36
                      ^^^^^^^^^^^^^^ no longer stripped

Google refuses to complete a sign-in from a User-Agent carrying a product token it doesn't recognise, and hands the flow to a real browser instead — exactly the reported symptom.

The stripping is now an allowlist of the tokens a stock Chrome UA is made of, rather than a list of names to remove, so it cannot be broken by renaming the app again. It lives in src/config.js with unit tests covering the capitalised name, a name with spaces, and an already-clean UA. The UA the app sends is now byte-for-byte what v1.3.0 sent.

📱 Zalo's login QR — force dark erased it

v1.3.1's new Dark Service Pages used Chromium's auto-dark pass. Chromium leaves <img> and <canvas> alone, so that looked safe — but inline <svg> is page content, not an image, and its fills get inverted like any other colour. Zalo draws its login QR as inline SVG.

Measured on the real login screen: the QR is 43% dark pixels normally and 0% under force dark — a blank white square with only the three blue corner markers left.

Fixed with a per-service opt-out:

  • Zalo is excluded out of the box (it ships in the preset).
  • Right-click any tab → "Don't Darken This Site" for anything else that comes out wrong.
  • Dark Service Pages otherwise stays on and unchanged.

Checked the other QR sign-ins while I was there: WhatsApp and Telegram draw theirs into a <canvas>, and both measured pixel-identical with force dark on — they were never affected and are not excluded.


🌟 New

↔️ Drag a tab to reorder it

Press and hold a tab for a moment, then drag: it lifts off the strip and the others slide around it. Drag against either end and the strip scrolls itself, so a tab can be moved further than the visible width. The order is saved and survives a restart, and it drives everything that reads it — the tray list, Control+Tab cycling, and the Cmd+1…9 shortcuts.

Press-and-hold is what the gesture is bound to precisely so that drag-to-pan still works: move straight away and you pan the strip as before, hold first and you reorder.

🔁 A restart prompt you can actually see

An update finishes minutes after the click that started it, by which point the "Restart Now" button was sitting on a Settings page nobody was looking at. Now, the moment an update finishes installing, a prompt comes to the front with Restart Now and Later.

Later changes nothing else: the update stays installed and the Restart button stays in Settings for whenever it suits you.


✅ How this was verified

Both regressions were reproduced and then re-measured after the fix, against the real sites:

  • User-Agent: printed from a real Electron run with app.setName('Notihub') — the sent UA no longer contains the app name or Electron, and matches v1.3.0's exactly. Unit tests cover the capitalised-name case that shipped.
  • Zalo QR: driving the actual config.js decision the way main.js does, against the live login page — 44% dark pixels with the preset default (scannable, screenshotted) versus 0% when force dark is applied, which is now only reachable by explicitly opting that site back in.
  • WhatsApp / Telegram QR: measured unchanged (49%/57% dark pixels) with force dark both off and on.
  • Tab reordering and the restart prompt: driven through synthetic pointer and click events — hold-then-drag reorders and reports the new order, a quick drag still pans without reordering, a plain click still selects, and Later/Restart Now each do the right thing.
  • npm test: 54 existing tests plus new coverage for the UA stripping, the per-service dark decision, and the reordering.

A third bug turned up during that testing rather than in review: a drag ending without the click that normally follows it (pointer cancelled, released off-window) left the click-suppression armed, so the next click on a tab would be swallowed. Fixed.


📦 Download Assets & Checksums

Asset File Format SHA-256 Checksum
notihub-v1.3.2-mac.dmg Native macOS DMG Installer eab33e69b99ebf8ea90baefcc02c5e06d9a78b19828adb622c0b1692594647cd
notihub-v1.3.2-mac.zip Portable Zip Archive 3d4bfe4738329aeb12f6787a29c287a3e2080334a07bb52e7aa88fa188630a9b

These match what GitHub publishes as the digest field on each asset — the same value src/updater.js verifies the download against before installing.


📥 Installation Options

Method 1: Homebrew (Recommended)

brew tap thuong180702/notihub
brew install --cask notihub

Method 2: npm (CLI companion)

npm install -g @thuong180702/notihub

Method 3: DMG Installer

  1. Download notihub-v1.3.2-mac.dmg below.
  2. Double click to open the DMG, then drag notihub.app into Applications.

Method 4: Direct Zip Download

  1. Download notihub-v1.3.2-mac.zip.
  2. Unzip and move notihub.app into /Applications.

⬆️ Upgrading from v1.3.1

Use Settings → Download & Install. No bundle identifier or data-directory change, so logins and notification permissions stay intact.

If Google is still refusing to sign you in after updating, reload that tab (right-click → Reload Service): the fixed User-Agent applies from the next page load.


⚠️ Gatekeeper Notice

Notihub is signed ad-hoc, not notarized by Apple, so macOS will refuse a manual install with "notihub is damaged and can't be opened". This isn't corruption — it's Gatekeeper rejecting an unnotarized app. Clear the quarantine flag once:

xattr -dr com.apple.quarantine /Applications/notihub.app

Updates Notihub installs itself are never quarantined, so this is only needed for a fresh manual install.