Skip to content

Add target-app selection and routing support - #128

Open
Fayiz1 wants to merge 1 commit into
L1M80:developfrom
Fayiz1:develop
Open

Add target-app selection and routing support#128
Fayiz1 wants to merge 1 commit into
L1M80:developfrom
Fayiz1:develop

Conversation

@Fayiz1

@Fayiz1 Fayiz1 commented Aug 13, 2026

Copy link
Copy Markdown

feat(web): Support dual Antigravity engines and add chat auto-scroll ResizeObserver

Detailed Changes:

  1. Chat Auto-Scroll Stabilization (ResizeObserver):

    • Resolved a critical bug where long chats would jump/stay scrolled to the top on load.
    • Introduced a ResizeObserver on the inner messages container to detect asynchronous height increases (e.g. text expanding, Markdown compiling, images loading) and snap the scroll position to the bottom if the user was already near the bottom.
    • Restructured layout references (innerRef and scrollRef) in ChatPanel.tsx to handle the resize events.
  2. Dual-Target Engine Support (Antigravity & Antigravity IDE):

    • Enabled target routing selection in the UI, allowing the Porta web app to switch between both the standard antigravity Language Server and the Desktop antigravity-ide Language Server.
    • Ensured headers (x-porta-target-app) and WebSocket parameters are correctly passed so that step updates and message submissions route to the correct LS process.
  3. Background Mobile Load & Caching Optimization:

    • Implemented sessionStorage caching for conversation trajectories in useStepsStream.ts to instantly restore message histories.
    • Eliminated the jarring blank "loading skeleton" flash when users perform a pull-to-refresh on mobile devices or reload on unstable network connections.
    • Set up silent background polling to merge and sync new steps seamlessly.

feat(web):  Support dual Antigravity engines and add chat auto-scroll ResizeObserver

Detailed Changes:
1. **Chat Auto-Scroll Stabilization (ResizeObserver)**:
   - Resolved a critical bug where long chats would jump/stay scrolled to the top on load.
   - Introduced a `ResizeObserver` on the inner messages container to detect asynchronous height increases (e.g. text expanding, Markdown compiling, images loading) and snap the scroll position to the bottom if the user was already near the bottom.
   - Restructured layout references (`innerRef` and `scrollRef`) in `ChatPanel.tsx` to handle the resize events.

2. **Dual-Target Engine Support (Antigravity & Antigravity IDE)**:
   - Enabled target routing selection in the UI, allowing the Porta web app to switch between both the standard `antigravity` Language Server and the Desktop `antigravity-ide` Language Server.
   - Ensured headers (`x-porta-target-app`) and WebSocket parameters are correctly passed so that step updates and message submissions route to the correct LS process.

3. **Background Mobile Load & Caching Optimization**:
   - Implemented sessionStorage caching for conversation trajectories in `useStepsStream.ts` to instantly restore message histories.
   - Eliminated the jarring blank "loading skeleton" flash when users perform a pull-to-refresh on mobile devices or reload on unstable network connections.
   - Set up silent background polling to merge and sync new steps seamlessly.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant