Skip to content

Commit c1b619e

Browse files
committed
feat: add buttonPadding prop to InfoIconTippy for customizable button styling
1 parent 9e4f3dc commit c1b619e

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

src/Common/Types.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,7 @@ export interface InfoIconTippyProps
164164
dataTestid?: string
165165
children?: TippyCustomizedProps['children']
166166
iconClassName?: string
167+
buttonPadding?: string
167168
}
168169

169170
export interface GenericEmptyStateType {

src/Shared/Components/InfoIconTippy/InfoIconTippy.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ const InfoIconTippy = ({
3131
dataTestid = 'info-tippy-button',
3232
children,
3333
headingInfo,
34+
buttonPadding = 'p-0',
3435
}: InfoIconTippyProps) => (
3536
<TippyCustomized
3637
theme={TippyTheme.white}
@@ -53,7 +54,7 @@ const InfoIconTippy = ({
5354
{children || (
5455
<button
5556
type="button"
56-
className="p-0 dc__no-background dc__no-border dc__outline-none-imp flex dc__tab-focus dc__no-shrink"
57+
className={`${buttonPadding} dc__no-background dc__no-border dc__outline-none-imp flex dc__tab-focus dc__no-shrink`}
5758
aria-label="Info Icon"
5859
data-testid={dataTestid}
5960
>

0 commit comments

Comments
 (0)