Skip to content

Commit eb209fe

Browse files
committed
Add prop as private
1 parent 417bea6 commit eb209fe

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

packages/react/src/Button/IconButton.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ const IconButton = forwardRef(
6262
type={description ? undefined : 'label'}
6363
direction={tooltipDirection}
6464
keybindingHint={keybindingHint ?? keyshortcuts}
65-
closeTooltip={hasActivePopup}
65+
_privateDisableTooltip={hasActivePopup}
6666
>
6767
<ButtonBase
6868
icon={Icon}

packages/react/src/TooltipV2/Tooltip.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,15 +26,15 @@ export type TooltipProps = React.PropsWithChildren<{
2626
*/
2727
delay?: 'short' | 'medium' | 'long'
2828
/**
29-
* Prevents the tooltip from opening if `true`.
29+
* Private API for use internally only. Prevents the tooltip from opening if `true`.
3030
*
3131
* Accessibility note: This prop should be used with caution. Only use when needing to
3232
* programmatically close the tooltip in response to a specific user action, such as
3333
* opening a menu, or content where the tooltip could overlap with interactive content.
3434
*
3535
* @default false
3636
*/
37-
closeTooltip?: boolean
37+
_privateDisableTooltip?: boolean
3838
}> &
3939
React.HTMLAttributes<HTMLElement>
4040

@@ -117,7 +117,7 @@ export const Tooltip: ForwardRefExoticComponent<
117117
className,
118118
keybindingHint,
119119
delay = 'short',
120-
closeTooltip: hideTooltip = false,
120+
_privateDisableTooltip = false,
121121
...rest
122122
}: TooltipProps,
123123
forwardedRef,
@@ -142,7 +142,7 @@ export const Tooltip: ForwardRefExoticComponent<
142142
triggerRef.current &&
143143
tooltipElRef.current.hasAttribute('popover') &&
144144
!tooltipElRef.current.matches(':popover-open') &&
145-
!hideTooltip
145+
!_privateDisableTooltip
146146
) {
147147
const tooltip = tooltipElRef.current
148148
const trigger = triggerRef.current

0 commit comments

Comments
 (0)