Closed mindingdata closed 1 year ago
What eversion are you running?
npx sb info
I hope this issue can reopen since I've encountered the same problem.
Environment Info:
System: OS: macOS 13.0.1 CPU: (10) arm64 Apple M1 Pro Binaries: Node: 16.18.0 - ~/.nvm/versions/node/v16.18.0/bin/node npm: 8.19.2 - ~/.nvm/versions/node/v16.18.0/bin/npm Browsers: Chrome: 110.0.5481.177 Safari: 16.1 npmPackages: @storybook/addon-a11y: 6.5.10 => 6.5.10 @storybook/addon-actions: 6.5.10 => 6.5.10 @storybook/addon-essentials: 6.5.10 => 6.5.10 @storybook/addon-links: 6.5.10 => 6.5.10 @storybook/addon-notes: ^5.3.21 => 5.3.21 @storybook/addon-storysource: 6.5.10 => 6.5.10 @storybook/builder-webpack5: 6.5.10 => 6.5.10 @storybook/manager-webpack5: 6.5.10 => 6.5.10 @storybook/node-logger: 6.5.10 => 6.5.10 @storybook/preset-create-react-app: ^4.1.2 => 4.1.2 @storybook/react: 6.5.10 => 6.5.10
Describe the bug
If I have a component that has an action that returns a boolean, for example a Toggle Switch or checkbox like so :
When this is wired up automatically by Storybook, the actions tab looks looks like so :
Notice how when the value is false, I get a more verbose output than just the value.
If I had to guess, there is a check somewhere around the "truthy" values and since I am returning false, this isn't returned correctly.
I've had a quick look through the code and even a line like so could be tripping this up given we only return a single value, so args in this case would be false.
https://github.com/storybookjs/storybook/blob/a2e5f9b99209f28cf417467f6860baf3a263052d/code/addons/actions/src/components/ActionLogger/index.tsx#L50
To Reproduce
No response
System
No response
Additional context
No response