opensearch-project / oui

OpenSearch UI Framework
Apache License 2.0
31 stars 65 forks source link

[BUG] OuiSplitButton still displays dropdown when no options available #1208

Open pjfitzgibbons opened 6 months ago

pjfitzgibbons commented 6 months ago

Describe the bug

When options is blank-array, or options is not present at all, the "dropdown" side of SplitButton is still displayed, and when clicked an empty Popover is rendered.

To Reproduce Steps to reproduce the behavior:

  1. Use this TSX :
    <OuiSplitButton >Test</OuiSplitButton>
  2. See dropdown button
  3. Click dropdown button
  4. See empty Popver (2-pixel line under dropdown)

Expected behavior No dropdown button, no popover