-
Notifications
You must be signed in to change notification settings - Fork 462
chore(clerk-js,types): Display info tooltip for past due amounts in checkout #6097
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 2 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| --- | ||
| '@clerk/clerk-js': patch | ||
| --- | ||
|
|
||
| Display info tooltip for past due amounts in checkout. | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,6 @@ | ||
| --- | ||
| '@clerk/localizations': patch | ||
| '@clerk/types': patch | ||
| --- | ||
|
|
||
| Introduce `commerce.checkout.pastDueNotice` localization key. | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧹 Nitpick (assertive) Add a top-level heading per Markdown lint rules. The file should begin with an H1 heading to satisfy MD041 (first-line-heading). Please add a leading 🧰 Tools🪛 markdownlint-cli2 (0.17.2)6-6: First line in a file should be a top-level heading (MD041, first-line-heading, first-line-h1) 🤖 Prompt for AI Agents |
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -83,9 +83,10 @@ function Group({ children, borderTop = false, variant = 'primary' }: GroupProps) | |
| interface TitleProps { | ||
| title: string | LocalizationKey; | ||
| description?: string | LocalizationKey; | ||
| icon?: React.ComponentType; | ||
| } | ||
|
|
||
| function Title({ title, description }: TitleProps) { | ||
| const Title = React.forwardRef<HTMLTableCellElement, TitleProps>(({ title, description, icon }, ref) => { | ||
|
panteliselef marked this conversation as resolved.
|
||
| const context = React.useContext(GroupContext); | ||
| if (!context) { | ||
| throw new Error('LineItems.Title must be used within LineItems.Group'); | ||
|
|
@@ -94,6 +95,7 @@ function Title({ title, description }: TitleProps) { | |
| const textVariant = variant === 'primary' ? 'subtitle' : 'caption'; | ||
| return ( | ||
| <Dt | ||
| ref={ref} | ||
| elementDescriptor={descriptors.lineItemsTitle} | ||
| elementId={descriptors.lineItemsTitle.setId(variant)} | ||
| sx={t => ({ | ||
|
|
@@ -102,7 +104,22 @@ function Title({ title, description }: TitleProps) { | |
| ...common.textVariants(t)[textVariant], | ||
| })} | ||
| > | ||
| <Span localizationKey={title} /> | ||
| <Span | ||
| sx={t => ({ | ||
| display: 'inline-flex', | ||
| alignItems: 'center', | ||
| gap: t.space.$1, | ||
| })} | ||
| > | ||
| {icon ? ( | ||
| <Icon | ||
| size='md' | ||
| icon={icon} | ||
| aria-hidden | ||
| /> | ||
| ) : null} | ||
| <Span localizationKey={title} /> | ||
| </Span> | ||
|
Comment on lines
+107
to
+122
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Technically breaking, but given the fact that we still use |
||
| {description ? ( | ||
| <Span | ||
| localizationKey={description} | ||
|
|
@@ -115,7 +132,7 @@ function Title({ title, description }: TitleProps) { | |
| ) : null} | ||
| </Dt> | ||
| ); | ||
| } | ||
| }); | ||
|
|
||
| /* ------------------------------------------------------------------------------------------------- | ||
| * LineItems.Description | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.