dream-aim-deliver/dad-ui-kit-starter-template

Add a storybook control to match onSth controls to an action

Opened this issue · 0 comments

Description

Components that have args like onClick, onChange etc, should have a storybook control corresponding to an action
https://storybook.js.org/docs/essentials/actions

Motivation

No response

Change

controls: {
      matchers: {
        color: /(background|color)$/i,
        date: /Date$/i,
// ADD THIS PART
        parameters: {
          actions: { argTypesRegex: '^on.*' },
        },
      },

See parameters: {

Additional Information

  • The API needs to be changed.