Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve menu controlling with onOpenChange #17712

Merged
merged 8 commits into from Apr 6, 2021

Commits on Apr 6, 2021

  1. Improve menu controlling

    Adds `onOpenChange` callback to the `Menu` which is called when the
    internals of the menu component request a change to the open state of
    the menu.
    
    When the menu is not controlled (i.e. no `open`) prop, this callback can
    be used to watch the changes of the menu internal state.
    
    When the menu is controlled, allows the consumer to benefit from the
    popup edge cases that are used internally.
    ling1726 committed Apr 6, 2021
    Configuration menu
    Copy the full SHA
    3bd45e8 View commit details
    Browse the repository at this point in the history
  2. remove console

    ling1726 committed Apr 6, 2021
    Configuration menu
    Copy the full SHA
    f77e1c2 View commit details
    Browse the repository at this point in the history
  3. useEventCallback

    ling1726 committed Apr 6, 2021
    Configuration menu
    Copy the full SHA
    4123637 View commit details
    Browse the repository at this point in the history
  4. remove console

    ling1726 committed Apr 6, 2021
    Configuration menu
    Copy the full SHA
    f34eb92 View commit details
    Browse the repository at this point in the history
  5. improve types

    ling1726 committed Apr 6, 2021
    Configuration menu
    Copy the full SHA
    2810817 View commit details
    Browse the repository at this point in the history
  6. Change files

    ling1726 committed Apr 6, 2021
    Configuration menu
    Copy the full SHA
    e7e426f View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    a4c4235 View commit details
    Browse the repository at this point in the history
  8. add tests

    ling1726 committed Apr 6, 2021
    Configuration menu
    Copy the full SHA
    be151dd View commit details
    Browse the repository at this point in the history