Skip to content

NotionFlow v1.3.1 - Full Desktop Route & Settings Fix

Choose a tag to compare

@intelQong intelQong released this 05 Sep 14:37
· 8 commits to main since this release

🚀 What's New in v1.3.1

🎯 Defeated Notion's Internal iPad Detector (Root-Cause Fix)

  • Neutralized "ontouchend" in document check: Reverse-engineering Notion's production JavaScript chunks (module 900532) revealed that when navigator.platform is spoofed to "MacIntel", Notion inspects "ontouchend" in window.document to detect iPadOS. On iOS Safari/PWA, this evaluated to true, causing Notion's detector to return isIpad: true, cascading to isMobile: true and serving mobile routes for Settings and Notifications.
  • Stripped ontouch* listener properties from Document.prototype, HTMLDocument.prototype, and document so Notion's detector evaluates:
    • isIpad: false
    • isIOS: false
    • isMobile: false
    • isDesktop: true

🛡️ Locked window.CONFIG.isMobile Desktop Property Descriptor

  • Intercepted Notion's core configuration module (module 386961) using an accessor descriptor lock to guarantee window.CONFIG.isMobile is permanently forced to false.

⚡ WebKit EventTarget & MutationObserver Stability

  • Replaced Proxy wrappers on window.matchMedia with direct Object.defineProperty overrides, preventing WebKit TypeError: Can only call EventTarget.addEventListener on instances of EventTarget.
  • Debounced all DOM MutationObserver listeners using requestAnimationFrame to prevent microtask loops in WebKit.
  • Added safeAppend & safeAppendBody utilities to guarantee flawless execution at document-start.

🧪 Verified with Playwright WebKit

  • Verified inside Playwright WebKit on emulated iPhone 14 Pro:
    • Notion Detector: { isIpad: false, isIOS: false, isMobile: false, isDesktop: true }
    • window.CONFIG.isMobile: false
    • Floating Action Bar & Settings trigger: Mounted cleanly with 0 console errors.