I was testing some build improvements to storybook when I started getting this error:
DialogButtonBar is not defined
Investigating it, I found that docgen was trying to use DialogButtonBar. But DialogButtonBar and DialogContent are not exported (they get exposed as subcomponents of Dialog, like Dialog.ButtonBar, etc) so it could not find it.
To fix this, instead of directly assigning DialogButtonBar to ModalButtonBar and DialogContent to ModalContent, I am now creating a wrapper component over it. I would imagine this would potentially fix some similar issues on the user's side too.
I was testing some build improvements to storybook when I started getting this error:
Investigating it, I found that docgen was trying to use
DialogButtonBar
. ButDialogButtonBar
andDialogContent
are not exported (they get exposed as subcomponents ofDialog
, likeDialog.ButtonBar
, etc) so it could not find it.To fix this, instead of directly assigning
DialogButtonBar
toModalButtonBar
andDialogContent
toModalContent
, I am now creating a wrapper component over it. I would imagine this would potentially fix some similar issues on the user's side too.