Fix that weird scrolling issue in ios when keyboard is shown#166
Conversation
…o feat/bugfixes-and-refactor
ctrl v in the focused input is visible, just like thek eyboard fixed, should paste and focus. media in filmstrp not preloading, they show empty song icons
…oad-more Messages during a chathistory batch are now held in pendingMessages and flushed to state in one setState at BATCH_END, so history appears all at once instead of one by one. Scroll position is preserved via a useLayoutEffect delta correction (scrollTop += newHeight - prevHeight) instead of CSS scroll anchoring, which was unreliable on WKWebView flex containers and caused double-jumps in browser when both mechanisms ran simultaneously. overflow-anchor:none disables the browser's native anchoring so only our correction runs. Also fixes: scroll-to-bottom button showing stale true on channel switch, load older messages button not appearing on chathistory-capable servers.
…iewer arrow key handling
- Narrow ChannelMessageList selector to per-channel key (was subscribing
to full messages map, causing re-render on every incoming message)
- Wrap MessageItem in memo + useMemo markdown processing
- Lazy-load highlight.js (969KB deferred from initial bundle)
- Replace opacity:0 with visibility:hidden on message action bars
- Split vendor chunks (react, markdown, zustand) for better caching
- Fix reactions and replies lost during chathistory batch playback
- Inline MdAddReaction/RiReplyFill SVGs to drop react-icons sub-packages
|
Caution Review failedPull request was closed or merged during review 📝 WalkthroughWalkthroughThis PR introduces a new Changes
Sequence Diagram(s)sequenceDiagram
participant iOS as iOS UIResponder
participant Swift as KeyboardPlugin (Swift)
participant Rust as Plugin Manager (Rust)
participant JS as JavaScript Layer
iOS->>Swift: keyboardWillShow/keyboardDidShow Notification
Swift->>Swift: Extract keyboard height & animation duration
Swift->>Rust: trigger("plugin:keyboard::ios-keyboard-event", KeyboardEvent)
Rust->>JS: Send keyboard event via IPC
iOS->>Swift: keyboardWillHide Notification
Swift->>Swift: Set keyboard height to 0
Swift->>Rust: trigger("plugin:keyboard::ios-keyboard-event", KeyboardEvent)
Rust->>JS: Send keyboard event via IPC
JS->>JS: Update layout / trigger handlers
Estimated code review effort🎯 4 (Complex) | ⏱️ ~60 minutes Possibly related PRs
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Automated deployment preview for the PR in the Cloudflare Pages. |
…o fix/ios-fucking-webkit-sucks-scroll-issue-fork-rust-plugin-aah
Summary by CodeRabbit
Release Notes
New Features
Bug Fixes
Chores