Skip to content

[Bug]: cannot add multiple argTypes for single prop #24502

Open

Description

Describe the bug

Hello, I checked https://storybook.js.org/docs/react/essentials/controls#conditional-controls for info about conditionals and found I can use something like this:

hasError: {
  if: {arg: "isDisabled", truthy: false}
},

How can I define multiple conditionals? I tried this but it doesn't work:

errorMessage: {
  if: [
    {arg: "hasError", truthy: true},
    {arg: "isDisabled", truthy: false}
  ]
},

It says Invalid conditional value {}

To Reproduce

No response

System

No response

Additional context

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    • Status

      No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions