Skip to content

Commit

Permalink
feat(rich-tooltip): add cases stories react
Browse files Browse the repository at this point in the history
  • Loading branch information
gabrielduete committed Feb 13, 2025
1 parent f3b1717 commit e840c76
Showing 1 changed file with 22 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,12 +37,34 @@ const createTooltip = (args, buttonText = 'Hover') => (
</>
)

export const Hover: StoryObj = {
render: (args) => createTooltip(args, 'Hover'),
args: {
...RichTooltipComponentArgs,
element: 'hover',
placement: 'top',
open: false,
},
}

export const Click: StoryObj = {
render: (args) => createTooltip(args, 'Click'),
args: {
...RichTooltipComponentArgs,
element: 'click',
placement: 'top',
action: 'click',
open: false,
},
}

export const Opened: StoryObj = {
render: (args) => createTooltip(args, 'Opened'),
args: {
...RichTooltipComponentArgs,
element: 'opened',
placement: 'left',
action: 'click',
open: true,
},
}

0 comments on commit e840c76

Please sign in to comment.