Skip to content

fix(studio): keep brand actions below short landscape previews - #640

Open
open-design-crew[bot] wants to merge 2 commits into
mainfrom
codex/brand-preview-followup-20261119
Open

open-design-crew[bot] wants to merge 2 commits into
mainfrom
codex/brand-preview-followup-20261119

Conversation

@open-design-crew

Copy link
Copy Markdown
Contributor

Why

After PR #584, the brand-story preview still lets the fixed action dock cover the video in short landscape viewports such as 640×360. The preview and its controls need to remain readable without changing the existing desktop or portrait layout.

What changed

  • Keep the action dock in normal document flow for short landscape viewports below 700px wide.
  • Remove the extra dialog bottom padding and dock shadow only in that mode so the dock follows the video instead of overlaying it.
  • Extend the existing browser regression to assert that the dock is static and does not overlap the selected video at 640×360 and 568×320, while keeping the portrait fixed dock unchanged.

Scope: OPEND-5460 follow-up only. The existing preview sizing and playback behavior from PR #584 remain unchanged.

Validation

  • npm run test:studio -- --run studio/src/motion/BrandStories.test.tsx — 15 tests passed.
  • npm run typecheck:studio — passed.
  • npm run build:studio — passed.
  • npm run check — passed.
  • npm run design:check — passed.
  • git diff --check — passed.
  • tests/related-template-preview-browser.mjs — passed in both themes at 640×360, 568×320, 390×844 and 1440×900. At 640×360 and 568×320 the action dock is position: static and has no overlap with the video. At 390×844 the existing fixed portrait dock remains in place.

Install package impact

None.

Review follow-up

The author owns follow-up after opening this PR. Follow the review checklist: verify feedback, push validated fixes, reply with evidence, resolve addressed threads and re-request prior reviewers after changes. Complete these as review progresses:

  • Every review thread has an addressed outcome or a clearly reported blocker.
  • Required checks and merge conflicts have been checked on the latest commit; pending items are reported.

Merge and publication follow the repository's existing authorization rules. The user will merge this PR with their GitHub account after it is approved and green.

@lefarcen
lefarcen requested a review from mrcfps November 19, 2026 06:30
@lefarcen lefarcen added size/XS Extra-small change (<20 lines) risk/medium Medium risk change type/bugfix Bug fix labels Nov 19, 2026

@qd1993102 qd1993102 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed the short-landscape fix for the brand-story work-action dock and the browser check that guards it. The dock now flows with the copy instead of covering the preview, and the new assertion fails if it returns to a viewport-anchored overlay. One alignment detail in the new media block is noted inline.

🔁 Powered by Looper · runner=reviewer · agent=omp · An autonomous AI dev team for your GitHub repos.

}
@media(max-width:699px) and (orientation:landscape) {
.storyDialog[open] { padding-bottom:0; }
.actionDock { position:static; margin-top:var(--motion-space-12); box-shadow:none; }

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[P2] Reset the dock's horizontal padding when it returns to normal flow

This landscape rule only resets position, margin-top and box-shadow, so the mobile rule at line 156 still applies padding-inline: var(--motion-space-16) to an element that is now an in-flow block inside .timelinePanel, which already applies 16px inline padding at line 145. In short landscape the dock's buttons therefore sit 32px from the dialog edge while the copy above sits at 16px (and the dock's top border spans the wider box), a visible misalignment in the exact mode this change targets. Add padding-inline:0 to this rule while keeping the vertical padding and safe-area inset, and the actions will align with the copy they now follow.

🔁 Powered by Looper · runner=reviewer · agent=omp · An autonomous AI dev team for your GitHub repos.

@open-design-crew

Copy link
Copy Markdown
Contributor Author

Addressed the inline alignment finding in 1e541d5f.

The short-landscape action dock now also resets padding-inline to 0, so it aligns with the content column after returning to normal document flow. The mobile vertical padding and safe-area inset remain unchanged.

Validation after the fix:

  • npm run test:studio -- --run studio/src/motion/BrandStories.test.tsx — 15 passed.
  • npm run typecheck:studio — passed.
  • npm run build:studio — passed.
  • tests/related-template-preview-browser.mjs — passed. The dock remains static and non-overlapping at 640×360 and 568×320, and remains fixed in the existing portrait layout at 390×844.
  • git diff --check — passed.

The inline thread can be resolved by the reviewer once the updated head is re-read.

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

Labels

risk/medium Medium risk change size/XS Extra-small change (<20 lines) type/bugfix Bug fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants