Skip to content

Conversation

@MananTank
Copy link
Member

@MananTank MananTank commented Oct 9, 2024

Problem solved

Short description of the bug fixed or feature added


PR-Codex overview

This PR enhances the ApplyCouponCard component by adding support for pre-filling a coupon code from URL search parameters and implementing a smooth scroll effect when the coupon is applied. It also introduces a loading state for the coupon section.

Detailed summary

  • Added BadgeContainer with a prefilled coupon code in ApplyCouponCard.stories.tsx.
  • Utilized useSearchParams to retrieve the coupon code in CouponCard.tsx.
  • Implemented pre-fill functionality for the promo code in ApplyCouponCardUI.
  • Added smooth scrolling effect to the ApplyCouponCardUI when a coupon code is present.
  • Created a new LoadingCouponSection component for loading states in the CouponSection.

✨ Ask PR-Codex anything about this PR by commenting with /codex {your question}

@changeset-bot
Copy link

changeset-bot bot commented Oct 9, 2024

⚠️ No Changeset found

Latest commit: 9adf6e6

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@vercel
Copy link

vercel bot commented Oct 9, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
thirdweb-www ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 9, 2024 5:20pm
3 Skipped Deployments
Name Status Preview Comments Updated (UTC)
docs-v2 ⬜️ Skipped (Inspect) Oct 9, 2024 5:20pm
thirdweb_playground ⬜️ Skipped (Inspect) Oct 9, 2024 5:20pm
wallet-ui ⬜️ Skipped (Inspect) Oct 9, 2024 5:20pm

@vercel vercel bot temporarily deployed to Preview – docs-v2 October 9, 2024 15:13 Inactive
@graphite-app
Copy link
Contributor

graphite-app bot commented Oct 9, 2024

Your org has enabled the Graphite merge queue for merging into main

Add the label “merge-queue” to the PR and Graphite will automatically add it to the merge queue when it’s ready to merge. Or use the label “hotfix” to add to the merge queue as a hot fix.

You must have a Graphite account and log in to Graphite in order to use the merge queue. Sign up using this link.

@vercel vercel bot temporarily deployed to Preview – thirdweb_playground October 9, 2024 15:13 Inactive
@vercel vercel bot temporarily deployed to Preview – wallet-ui October 9, 2024 15:13 Inactive
@github-actions github-actions bot added the Dashboard Involves changes to the Dashboard. label Oct 9, 2024
@MananTank MananTank changed the title Prefill Promose code on coupon card from search param + scroll into view Prefill Promo code on coupon card from search param + scroll into view Oct 9, 2024
Copy link
Member Author

MananTank commented Oct 9, 2024

@MananTank MananTank marked this pull request as ready for review October 9, 2024 15:13
@codecov
Copy link

codecov bot commented Oct 9, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 47.66%. Comparing base (9330401) to head (9adf6e6).
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #4968   +/-   ##
=======================================
  Coverage   47.66%   47.66%           
=======================================
  Files        1057     1057           
  Lines       57267    57267           
  Branches     3939     3939           
=======================================
  Hits        27299    27299           
  Misses      29277    29277           
  Partials      691      691           
Flag Coverage Δ *Carryforward flag
legacy_packages 65.68% <ø> (ø) Carriedforward from 9330401
packages 43.44% <ø> (ø)

*This pull request uses carry forward flags. Click here to find out more.

@github-actions
Copy link
Contributor

github-actions bot commented Oct 9, 2024

size-limit report 📦

Path Size Loading time (3g) Running time (snapdragon) Total time
thirdweb (esm) 42.1 KB (0%) 842 ms (0%) 323 ms (+1.3% 🔺) 1.2 s
thirdweb (cjs) 101.73 KB (0%) 2.1 s (0%) 593 ms (+27.58% 🔺) 2.7 s
thirdweb (minimal + tree-shaking) 4.82 KB (0%) 97 ms (0%) 55 ms (-19.17% 🔽) 151 ms
thirdweb/chains (tree-shaking) 498 B (0%) 10 ms (0%) 11 ms (+52.95% 🔺) 21 ms
thirdweb/react (minimal + tree-shaking) 17.23 KB (0%) 345 ms (0%) 112 ms (+93.02% 🔺) 457 ms

@graphite-app
Copy link
Contributor

graphite-app bot commented Oct 9, 2024

Merge activity

#4968)

## Problem solved

Short description of the bug fixed or feature added

<!-- start pr-codex -->

---

## PR-Codex overview
This PR introduces functionality for pre-filling a coupon code in the `ApplyCouponCard` component based on URL search parameters and enhances the user experience by scrolling into view when a coupon code is present.

### Detailed summary
- Added `BadgeContainer` for pre-filled coupon code display in `ApplyCouponCard.stories.tsx`.
- Utilized `useSearchParams` to retrieve the coupon code from the URL in `CouponCard.tsx`.
- Enhanced `ApplyCouponCardUI` to accept `prefillPromoCode` and `scrollIntoView` props.
- Implemented scrolling behavior to focus on the form when a coupon code is present.
- Wrapped `ApplyCouponCard` in a `Suspense` component to manage loading states effectively.

> ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}`

<!-- end pr-codex -->
@MananTank MananTank force-pushed the 10-09-include_current_page_s_search_params_when_redirecting_to_login_page branch from ff9ba30 to 9330401 Compare October 9, 2024 17:10
@MananTank MananTank force-pushed the 10-09-prefill_promose_code_on_coupon_card_from_search_param_scroll_into_view branch from 151a38a to 9adf6e6 Compare October 9, 2024 17:11
Base automatically changed from 10-09-include_current_page_s_search_params_when_redirecting_to_login_page to main October 9, 2024 17:20
@graphite-app graphite-app bot merged commit 9adf6e6 into main Oct 9, 2024
29 checks passed
@graphite-app graphite-app bot deleted the 10-09-prefill_promose_code_on_coupon_card_from_search_param_scroll_into_view branch October 9, 2024 17:21
@vercel vercel bot temporarily deployed to Production – thirdweb_playground October 9, 2024 17:21 Inactive
@vercel vercel bot temporarily deployed to Production – docs-v2 October 9, 2024 17:21 Inactive
@vercel vercel bot temporarily deployed to Production – wallet-ui October 9, 2024 17:21 Inactive
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Dashboard Involves changes to the Dashboard.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants