Skip to content

fix: free trial chip in /pro/subscribe#16309

Open
abhigyanghosh30 wants to merge 3 commits into
mainfrom
fix_visual_pro_subscribe
Open

fix: free trial chip in /pro/subscribe#16309
abhigyanghosh30 wants to merge 3 commits into
mainfrom
fix_visual_pro_subscribe

Conversation

@abhigyanghosh30
Copy link
Copy Markdown
Contributor

@abhigyanghosh30 abhigyanghosh30 commented Apr 24, 2026

Done

  • Fix the visual of the free trial status beside the buy now button in /pro/subscribe

QA

  • Open the DEMO
  • Alternatively, check out this feature branch
  • Run the site using the command ./run serve or dotrun
  • View the site locally in your web browser at: http://0.0.0.0:8001/
    • Be sure to test on mobile, tablet and desktop screen sizes
  • Visit /pro/subscribe

Issue / Card

Fixes #

Screenshots

Before:
Screen Shot 2026-04-25 at 04 40 23

After:
Screen Shot 2026-04-25 at 04 41 06

Help

QA steps - Commit guidelines

Copilot AI review requested due to automatic review settings April 24, 2026 23:11
@webteam-app
Copy link
Copy Markdown

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates the /pro/subscribe ProductSummary UI to improve the visual placement of the “Free trial on checkout” status chip relative to the checkout button.

Changes:

  • Adjust vertical alignment in the desktop/tablet ProductSummary action area to align elements to the bottom.
  • Add spacing between the free-trial StatusLabel and the PaymentButton.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 120 to 124
style={{ display: "flex", alignItems: "flex-end" }}
>
{product?.canBeTrialled && productUser !== ProductUsers.myself ? (
<StatusLabel appearance="positive">
<StatusLabel appearance="positive" style={{ marginRight: "1rem" }}>
Free trial on checkout
Copy link

Copilot AI Apr 24, 2026

Choose a reason for hiding this comment

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

The spacing between StatusLabel and PaymentButton is currently achieved via marginRight on the label. Since the parent <Col> is already a flex container, consider using gap on the flex container instead to avoid duplicating inline styles on children and keep spacing concerns on the layout wrapper.

Copilot uses AI. Check for mistakes.
{product?.canBeTrialled && productUser !== ProductUsers.myself ? (
<Col size={12}>
<StatusLabel appearance="positive">
<StatusLabel appearance="positive" style={{ marginRight: "1rem" }}>
Copy link

Copilot AI Apr 24, 2026

Choose a reason for hiding this comment

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

On the small/medium layout the free-trial StatusLabel is rendered in its own full-width <Col> below the <PaymentButton>, so marginRight here won’t affect the label/button spacing. Consider removing this style, or switching to vertical spacing (e.g., margin-top) / colocating the label with the button if you need to adjust their relative positioning.

Suggested change
<StatusLabel appearance="positive" style={{ marginRight: "1rem" }}>
<StatusLabel appearance="positive">

Copilot uses AI. Check for mistakes.
@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 24, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 48.30%. Comparing base (ba6f838) to head (eb7d35e).

Additional details and impacted files
@@           Coverage Diff           @@
##             main   #16309   +/-   ##
=======================================
  Coverage   48.30%   48.30%           
=======================================
  Files          37       37           
  Lines        5912     5912           
=======================================
  Hits         2856     2856           
  Misses       3056     3056           
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@anthonydillon
Copy link
Copy Markdown
Contributor

I know this is a design point of view but have we considered using help-text instead of a label which looks like a smaller button?

image

If you like this you can use this mark-up:

<div class="u-align--right col-4 col-start-large-9" style="display: flex;align-items: flex-end;gap:1rem;">
    <p class="p-form-help-text u-no-margin--bottom">Free trial on checkout</p>
    <button class="p-button--positive u-no-margin--bottom">Continue to checkout</button>
</div>

@anthonydillon anthonydillon self-assigned this Apr 28, 2026
@abhigyanghosh30
Copy link
Copy Markdown
Contributor Author

I know this is a design point of view but have we considered using help-text instead of a label which looks like a smaller button?

image If you like this you can use this mark-up:
<div class="u-align--right col-4 col-start-large-9" style="display: flex;align-items: flex-end;gap:1rem;">
    <p class="p-form-help-text u-no-margin--bottom">Free trial on checkout</p>
    <button class="p-button--positive u-no-margin--bottom">Continue to checkout</button>
</div>

I was also looking at the chip component which might look better. @polgarp would be the best person to suggest what to do here

@polgarp
Copy link
Copy Markdown

polgarp commented Apr 30, 2026

@abhigyanghosh30 you are right! Status labels are deprecated and the recommendation is to use chips instead - also since this is a small piece of additional piece of information.

@abhigyanghosh30 abhigyanghosh30 force-pushed the fix_visual_pro_subscribe branch from 1788655 to 0d9807f Compare May 9, 2026 18:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants