Skip to content

Commit

Permalink
[Docs]: change default placement for tooltip examples
Browse files Browse the repository at this point in the history
  • Loading branch information
AlekseyManetov committed Dec 11, 2024
1 parent 80e053f commit d400a96
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 31 deletions.
24 changes: 0 additions & 24 deletions app/src/docs/_examples/tooltip/Basic.example.tsx

This file was deleted.

6 changes: 3 additions & 3 deletions app/src/docs/_examples/tooltip/Types.example.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,20 +15,20 @@ export default function TypesTooltipExample() {

return (
<div className={ css.container }>
<Tooltip content="Compact" placement="bottom">
<Tooltip content="Compact">
<Button icon={ copyIcon } caption="Copy" fill="outline" color="primary" cx={ css.firstColumn } onClick={ () => null } />
</Tooltip>

<FlexRow alignItems="center" cx={ css.firstColumn }>
<RichTextView>
<span className={ css.permissionText }>Permissions</span>
</RichTextView>
<Tooltip content="Default tooltip. Can be inside as one row as 3 rows of text" placement="bottom">
<Tooltip content="Default tooltip. Can be inside as one row as 3 rows of text">
<IconContainer icon={ infoIcon } cx={ css.iconBlue } />
</Tooltip>
</FlexRow>

<Tooltip content={ renderTypesMarkup() } placement="bottom" color="neutral">
<Tooltip content={ renderTypesMarkup() } color="neutral">
<Button icon={ plusIcon } onClick={ () => null } cx={ css.firstColumn } />
</Tooltip>

Expand Down
6 changes: 3 additions & 3 deletions app/src/docs/_examples/tooltip/Variants.example.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@ import css from './TypesExample.module.scss';
export default function VariantsTooltipExample() {
return (
<div className={ css.container }>
<Tooltip content="Tooltip message" placement="bottom" color="inverted">
<Tooltip content="Tooltip message" color="inverted">
<Button caption="Default" fill="outline" color="secondary" onClick={ () => null } />
</Tooltip>

<Tooltip content="Tooltip message" placement="bottom" color="neutral">
<Tooltip content="Tooltip message" color="neutral">
<Button caption="Contrast" color="primary" onClick={ () => null } />
</Tooltip>

<Tooltip content="Tooltip message" placement="bottom" color="critical">
<Tooltip content="Tooltip message" color="critical">
<Button caption="Critical" fill="outline" color="critical" onClick={ () => null } />
</Tooltip>

Expand Down
2 changes: 1 addition & 1 deletion app/src/docs/_examples/tooltip/WithLink.example.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ export default function LinkTooltipExample() {
return (
<FlexRow alignItems="center">
<Text fontSize="14">Working from home allowed for employees only</Text>
<Tooltip content={ renderTypesMarkup() } placement="top" color="neutral" closeOnMouseLeave="boundary">
<Tooltip content={ renderTypesMarkup() } color="neutral" closeOnMouseLeave="boundary">
<IconContainer icon={ myIcon } style={ { justifyContent: 'center', marginLeft: '3px' } } cx={ css.iconAmber } />
</Tooltip>
</FlexRow>
Expand Down

0 comments on commit d400a96

Please sign in to comment.