Skip to content

Refresh CardModal fallback height on window resize - #3104

Open
Chris0Jeky wants to merge 2 commits into
mainfrom
codex/1739-layout-viewport-resize
Open

Chris0Jeky wants to merge 2 commits into
mainfrom
codex/1739-layout-viewport-resize

Conversation

@Chris0Jeky

@Chris0Jeky Chris0Jeky commented Sep 15, 2026

Copy link
Copy Markdown
Owner

Purpose

Fix #1739's no-VisualViewport path. CardModal deliberately uses the composable's layout fallback, but that fallback sampled window.innerHeight only once. A resize or orientation change could therefore leave an open modal at stale geometry and clip its actions.

The implementation observes window.resize only when VisualViewport is unavailable and the caller selected the layout fallback. The existing VisualViewport resize/scroll path and the unset/100dvh dialog fallback are unchanged.

Red → green evidence

RED — exact test-only head. Commit 351ae44a7c87dc7b5ca57e6c0a27d570537b1a9d added only useVisualViewportFallbackResize.spec.ts. CI run 34915717641, Ubuntu frontend job 104212818008, passed lint, typecheck, production build, and PWA validation, then failed the frontend test phase. Its archived JUnit receipt reports exactly one failure:

  • useVisualViewport layout fallback resize > tracks window resize without VisualViewport and removes the fallback listener on unmount
  • assertion: expected undefined to be defined
  • cause: no window.resize listener was registered.

GREEN — exact hosted head. Commit f3ae80bb2d09042e93a02fea5f945a0b9098b359 adds the narrow fallback listener and symmetric cleanup.

  • Smart CI Self-Test run 34916091226: success.
  • CI Extended run 34916091593: success.
  • Main CI run 34916091523: success.
  • The exact-head matrix covers frontend tests on Ubuntu and Windows, E2E smoke, API integration on both operating systems, backend/CLI tests, migrations, container and encrypted-backup verification, security, architecture, docs governance, production/PWA build, and source-launcher checks.

Scope

  • Layout-fallback observation only.
  • Listener ownership is explicit and cleanup removes the same handler exactly once.
  • The VisualViewport resize/scroll path and the unset/100dvh dialog fallback remain unchanged.
  • No CardModal form, focus, save, archive, viewport-breakpoint, or server behavior changes.

Closes #1739

@Chris0Jeky
Chris0Jeky marked this pull request as ready for review September 15, 2026 01:38
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 15, 2026

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review Completed 2026-09-15T01:40:13.497219Z f3ae80b Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Pending

Development

Successfully merging this pull request may close these issues.

Refresh CardModal fallback height when VisualViewport is unavailable

1 participant