File tree Expand file tree Collapse file tree 2 files changed +8
-4
lines changed
packages/react/src/components/Tooltip Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -161,8 +161,8 @@ export default {
161161
162162export const DefaultBottom = ( ) => (
163163 < div style = { containerStyles } >
164- < Tooltip { ...props . withIcon ( ) } tooltipBodyId = "tooltip-body" >
165- < p id = "tooltip-body" >
164+ < Tooltip { ...props . withIcon ( ) } >
165+ < p >
166166 This is some tooltip text. This box shows the maximum amount of text
167167 that should appear inside. If more room is needed please use a modal
168168 instead.
Original file line number Diff line number Diff line change @@ -671,7 +671,9 @@ class Tooltip extends Component {
671671 className = { `${ prefix } --tooltip__trigger` }
672672 { ...properties }
673673 ref = { refProp }
674- aria-describedby = { tooltipBodyId } >
674+ aria-describedby = {
675+ tooltipBodyId || properties [ 'aria-describedby' ]
676+ } >
675677 < IconCustomElement { ...iconProperties } />
676678 </ div >
677679 </ div >
@@ -681,7 +683,9 @@ class Tooltip extends Component {
681683 className = { triggerClasses }
682684 ref = { refProp }
683685 { ...properties }
684- aria-describedby = { tooltipBodyId } >
686+ aria-describedby = {
687+ tooltipBodyId || properties [ 'aria-describedby' ]
688+ } >
685689 { triggerText }
686690 </ div >
687691 ) }
You can’t perform that action at this time.
0 commit comments