Skip to content

fix(ui): make the Pro Features dialog fit narrow screens - #10181

Merged
Kitenite merged 1 commit into
mainfrom
make-dialog-responsive-fa55e986
Nov 23, 2026
Merged

Kitenite merged 1 commit into
mainfrom
make-dialog-responsive-fa55e986

Conversation

@Kitenite

@Kitenite Kitenite commented Nov 23, 2026 •

Copy link
Copy Markdown
Member

Summary

  • The Pro Features dialog now fits narrow viewports. It forced a 744px width, so on a phone it ran off both edges of the screen and the Cancel and Get Paradev Pro buttons were cut off.
  • Adds a Storybook story for the dialog.

Why / Context

The dialog is shared by the web integrations page paywall and the desktop paywall. Web is reachable on a phone, and the desktop window can shrink to 540px, so both overflowed.

How It Works

Below the md breakpoint (768px):

  • The feature list becomes a horizontally scrolling tab row under the title. A tapped tab scrolls into view.
  • The preview takes the full width below the tabs. Demo cards shrink to fit and the phone mock is centred.
  • The dialog is capped at the viewport minus a 1rem margin on each side. The footer stays pinned and the body scrolls when the dialog is taller than the screen.

At md and above the layout is the same as before. The preview column flexes instead of using a fixed 495px, so the row fits in the 768px to 775px range where the dialog is narrower than 744px.

.storybook/main.ts defines process.env. The dialog imports @superset/shared/constants, which reads process.env, and the story crashed with "process is not defined" without it.

Manual QA

Checked in Storybook through a browser pane with device metrics emulation, on the Remote Access and Mobile App stories, at 320, 375, 390, 600, 767 and 768px:

  • No horizontal overflow of the document or the dialog
  • Both footer buttons are inside the dialog at every width
  • Demo card stays inside the preview (the phone mock is cropped by design)
  • 1280px layout looks the same as before

Not checked: the real /integrations page and the desktop paywall. Both render the same shared component with no layout props.

Testing

  • bunx biome check packages/ui/src/components/ProFeaturesDialog packages/ui/.storybook
  • bunx tsc --noEmit -p packages/ui

Summary by cubic

Fixes the Pro Features dialog overflowing on narrow screens. It forced a 744px width, so on phones and desktop windows near the 540px minimum it ran off both edges and the Cancel and Get Paradev Pro buttons were cut off.

Below the md breakpoint the feature list becomes a horizontally scrolling tab row, the preview fills the width below it, the dialog is capped at the viewport minus a 1rem margin on each side, and the footer stays pinned while the body scrolls. At md and above the layout is unchanged; the preview column now flexes instead of using a fixed 495px width so the 768–775px range fits. Adds a Storybook story for the dialog and defines process.env in the Storybook config so the dialog's import of @superset/shared/constants renders instead of crashing.

Written for commit 995f04e. Summary will update on new commits.

View guided diff Turn on auto-fix

Summary by CodeRabbit

  • Bug Fixes
    • The Pro Features dialog and its previews now adapt to smaller screens, stay within the viewport, and allow content to scroll.
    • Feature navigation scrolls horizontally on smaller screens and switches to a vertical list on larger screens.

The dialog forced a 744px width, so it ran off both edges on a phone and
in a desktop window near the 540px minimum. Below the md breakpoint the
feature list is now a scrolling tab row above the preview, the dialog is
capped to the viewport, and the footer stays pinned while the body scrolls.

Adds a Storybook story for the dialog. Storybook defines process.env so
components that read @superset/shared constants render.
@github-actions

github-actions Bot commented Nov 23, 2026 •

Copy link
Copy Markdown
Contributor

🧹 Preview Cleanup Complete

The following preview resources have been cleaned up:

  • ✅ Neon database branch

Thank you for your contribution! 🎉

@coderabbitai

coderabbitai Bot commented Nov 23, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The Pro features dialog now uses responsive sizing and layout for its content, sidebar, and feature previews. Storybook adds RemoteAccess and MobileApp examples, and its Vite configuration defines an empty process.env object.

Changes: Pro Features Dialog

Layer / File(s) Summary
Storybook examples and configuration
packages/ui/.storybook/main.ts, packages/ui/src/components/ProFeaturesDialog/ProFeaturesDialog.stories.tsx
The Storybook configuration adds an empty process.env definition while retaining existing Vite definitions. The new stories manage selected-feature state and show the RemoteAccess and MobileApp variants.
Responsive dialog and feature navigation
packages/ui/src/components/ProFeaturesDialog/ProFeaturesDialog.tsx, packages/ui/src/components/ProFeaturesDialog/components/FeatureSidebar/FeatureSidebar.tsx
The dialog uses viewport-relative size constraints, a vertically scrollable content area, and a responsive column-to-row layout. The sidebar uses horizontal scrolling on smaller screens and a vertical list at the md breakpoint. Feature buttons scroll into view before selection.
Responsive feature previews
packages/ui/src/components/ProFeaturesDialog/components/FeaturePreview/FeaturePreview.tsx, packages/ui/src/components/ProFeaturesDialog/components/FeaturePreview/components/*Demo/*.tsx
The preview container and demo panels constrain their widths for smaller viewports. The MobileApp phone frame is centered by default and right-aligned at the md breakpoint and above.

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Bug fix

Suggested reviewers: saddlepaddle

Merge Risk: Minimal · up to 995f0

This change makes the Pro Features dialog fit narrow screens and adds Storybook examples. No concrete merge-blocking risk was found; the desktop layout is intended to remain the same.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the main change: the Pro Features dialog is adjusted to fit narrow screens. It follows conventional commit format with the fix(ui) scope. The changeset matches this: responsive layout …
Description check Passed The description follows the repository template. It has a What and why section that explains the overflow problem and the fix, and a How I tested it section with Manual QA steps at multiple viewport w…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title names the main change: the Pro Features dialog is adjusted to fit narrow screens. It follows conventional commit format with the fix(ui) scope. The changeset matches this: responsive layout below the md breakpoint, a viewport-capped dialog, and a horizontally scrolling feature list. The title does not cover the Storybook story or the process.env definition, which is expected for a short title.

Full details: Description check

Explanation

The description follows the repository template. It has a What and why section that explains the overflow problem and the fix, and a How I tested it section with Manual QA steps at multiple viewport widths and the commands run. The checklist items from the template are absent. The description has no linked issue, and it does not include before/after screenshots, which the template strongly prefers for user-visible bug fixes. The description is substantive and matches the changeset, so the check passes.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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.

Share

Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 934c09a1-1dfe-4446-a6b2-0c6679df9d58
Commits

Reviewing files that changed from the base of the PR and between 1a09765 and 995f04e.

Files selected for processing: 11

  • packages/ui/.storybook/main.ts
  • packages/ui/src/components/ProFeaturesDialog/ProFeaturesDialog.stories.tsx
  • packages/ui/src/components/ProFeaturesDialog/ProFeaturesDialog.tsx
  • packages/ui/src/components/ProFeaturesDialog/components/FeaturePreview/FeaturePreview.tsx
  • packages/ui/src/components/ProFeaturesDialog/components/FeaturePreview/components/AutomationsDemo/AutomationsDemo.tsx
  • packages/ui/src/components/ProFeaturesDialog/components/FeaturePreview/components/MobileAppDemo/MobileAppDemo.tsx
  • packages/ui/src/components/ProFeaturesDialog/components/FeaturePreview/components/RemoteAccessDemo/RemoteAccessDemo.tsx
  • packages/ui/src/components/ProFeaturesDialog/components/FeaturePreview/components/SlackIntegrationDemo/SlackIntegrationDemo.tsx
  • packages/ui/src/components/ProFeaturesDialog/components/FeaturePreview/components/TasksDemo/TasksDemo.tsx
  • packages/ui/src/components/ProFeaturesDialog/components/FeaturePreview/components/TeamCollaborationDemo/TeamCollaborationDemo.tsx
  • packages/ui/src/components/ProFeaturesDialog/components/FeatureSidebar/FeatureSidebar.tsx

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 7 remain after this review.

Copy link
Copy Markdown
Contributor

Review verdict: minor issues. The fix works: in Storybook at 320–768px the dialog and both footer buttons stay on screen (before: the dialog spanned x = −184…560 at 375px). The 1280px layout is unchanged. CI is green at 995f04e8.

Findings:

  • Minor packages/ui/src/components/ProFeaturesDialog/components/FeatureSidebar/FeatureSidebar.tsx:41: the overflow-x-auto tab row shows a 15px classic scrollbar on non-overlay-scrollbar browsers (web, 540–767px). Add [scrollbar-width:none] [&::-webkit-scrollbar]:hidden or a thin styled scrollbar.
  • Minor .../FeaturePreview/FeaturePreview.tsx:35: the 346px preview pushes the description below the fold on a 375×667 phone. Consider h-[260px] md:h-[346px].
  • Nit .../ProFeaturesDialog.stories.tsx:36-39: PRO_FEATURES[0]?.id ?? "mobile-app" is just the default remote-access, so the Mobile App tab starts off-screen, which production never does. Use highlightedFeatureId: "mobile-app".

The web /integrations and desktop paywalls were not run because they need a signed-in non-Pro session. Storybook was verified only.

Full report with screenshots and measurements: https://app.superset.sh/page/pr-10181-review-pro-features-dialog-on-narrow-scre-6xw7wa

@Kitenite
Kitenite merged commit a660d3f into main Nov 23, 2026
20 checks passed
@Kitenite
Kitenite deleted the make-dialog-responsive-fa55e986 branch November 23, 2026 06:27

This branch was previously deployed

1 inactive deployment
preview — 995f04e8 Deployed Nov 23, 2026 by Kitenite via Cleanup Preview Resources #5992
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.

2 participants