Skip to content

feat(BBBHint): allow uncontrolled open/close state & add hideCloseButton prop - #66

Open
Arthurk12 wants to merge 2 commits into
bigbluebutton:developfrom
Arthurk12:issue/29-30
Open

feat(BBBHint): allow uncontrolled open/close state & add hideCloseButton prop#66
Arthurk12 wants to merge 2 commits into
bigbluebutton:developfrom
Arthurk12:issue/29-30

Conversation

@Arthurk12

Copy link
Copy Markdown
Member

What does this PR do?

Adds an optional open prop so BBBHint can manage its own visibility and close itself when the close button is clicked, removing the need for external useState boilerplate in simple cases. Passing open switches to the existing controlled behavior, where the parent decides visibility via onRequestClose.

Adds a hideCloseButton prop to hide the close (X) button for hints that shouldn't be manually dismissed, e.g. ones dismissed via another UI element or tooltip-style hints with no explicit dismiss action. The close button no longer depends on title being set, so
label-only hints can now show one too unless hidden.

Closes Issue(s)

Closes #29
Closes #30

Adds an optional `open` prop so BBBHint can manage its own visibility
and close itself when the close button is clicked, removing the need
for external useState boilerplate in simple cases. Passing `open`
switches to the existing controlled behavior, where the parent decides
visibility via `onRequestClose`.

Closes bigbluebutton#29
Adds a `hideCloseButton` prop to hide the close (X) button for hints
that shouldn't be manually dismissed, e.g. ones dismissed via another
UI element or tooltip-style hints with no explicit dismiss action.
The close button no longer depends on `title` being set, so
label-only hints can now show one too unless hidden.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant