Skip to content

Latest commit

 

History

History
784 lines (425 loc) · 41.1 KB

CHANGELOG.md

File metadata and controls

784 lines (425 loc) · 41.1 KB

Change Log

All notable changes to this project will be documented in this file. See Conventional Commits for commit guidelines.

1.0.4 (2020-06-06)

Bug Fixes

  • Fix Tabbable preventing drag events on mouse down on Safari (#670) (6830c5a)

1.0.3 (2020-06-04)

Bug Fixes

  • Fix blur/focus events order on Tabbable on Safari and Firefox on MacOS (#658) (aad12ce)

Performance Improvements

1.0.2 (2020-05-14)

Bug Fixes

  • Fix DialogDisclosure focus on click on iOS Safari (8f54b0c)

1.0.1 (2020-05-13)

Bug Fixes

  • Fix Tabbable not receiving focus on VoiceOver click (#644) (ea4b204)
  • Fix enter animation on DisclosureContent and derivative components (#645) (11f9687), closes #643

1.0.0 (2020-05-12)

Bug Fixes

  • Fix Composite focus when inside conditionally rendered Dialog (1331ead)
  • Fix Tabbable elements preventing behaviors on mouse down (#641) (239eb56), closes #432
  • Fix error on TabPanel when used without Tabs (5bd8bb1)

Features

  • Add setVisible method to useDisclosureState (7896f2f)
  • Remove undefined props from props hooks and render props (d95c9e5)
  • Remove deprecated Hidden module (7a1cb99)
  • Remove deprecated modal prop from Dialog (5d787b1)
  • Remove deprecated stopId prop (2ffe843)
  • Support nested CompositeItems (#642) (64cf18b)

BREAKING CHANGES

  • The deprecated stopId prop has been removed from all the CompositeItem derivative components, such as Tab, Radio, ToolbarItem and MenuItem.

    On Tab, the stopId prop has been replaced by id, and it's no longer required, just like on the other CompositeItem components:

    - <Tab stopId="id" />
    + <Tab id="id" />
    // or
    + <Tab />

    On TabPanel, the stopId prop has been replaced by tabId, and it's no longer required (the relationship between Tab and TabPanel is now automatically inferred by their order in the DOM, learn more):

    - <TabPanel stopId="tab-id" />
    + <TabPanel tabId="tab-id" />
    // or
    + <TabPanel />

    On all the other CompositeItem derivative components (Radio, ToolbarItem and MenuItem), the optional stopId prop has been replaced by the — also optional — id prop:

    - <Radio stopId="id" />
    + <Radio id="id" />
    - <ToolbarItem stopId="id" />
    + <ToolbarItem id="id" />
    - <MenuItem stopId="id" />
    + <MenuItem id="id" />
  • The deprecated Hidden module has been removed. Use Disclosure instead.

    Before:

    import { useHiddenState, Hidden, HiddenDisclosure } from "reakit/Hidden";
    const hidden = useHiddenState();
    <HiddenDisclosure {...hidden}>Disclosure</HiddenDisclosure>
    <Hidden {...hidden}>Hidden</Hidden>

    After:

    import {
      useDisclosureState,
      DisclosureContent,
      Disclosure,
    } from "reakit/Disclosure";
    const disclosure = useDisclosureState();
    <Disclosure {...disclosure}>Disclosure</Disclosure>
    <DisclosureContent {...disclosure}>Content</DisclosureContent>
  • The deprecated modal prop has been removed from Dialog. Now you can only set it on useDialogState.

    Before:

    const dialog = useDialogState();
    <Dialog {...dialog} modal={false} />

    After:

    const dialog = useDialogState({ modal: false });
    <Dialog {...dialog} />

1.0.0-rc.2 (2020-04-29)

Bug Fixes

  • Ensure undefined doesn't override default tabIndex in Dialog (#638) (a6a87f4), closes #636
  • Fix Menu issues on Safari (8d9f33c)
  • Fix hovering MenuItem with Dialog open closing the dialog (06c72ff)
  • Fix nested Dialog blocking parent auto focus when it's conditionally rendered (324395b)

Features

  • Make CompositeItem tabbable before they're registered (for example, on SSR) (dff1ba1)

Performance Improvements

  • Reduce the number of renders on Popover/Tooltip/Menu (f554600)

1.0.0-rc.1 (2020-04-20)

Bug Fixes

  • Add missing setVirtual action to CompositeState reducer (965704c)
  • Fix <Tabbable disabled focusable /> not focusing closest parent (b3dfb96)
  • Fix Checkbox activating twice on space key on Firefox (#625) (c4d5961), closes #368
  • Fix Composite on IE11 (#609) (555b931)
  • Fix CompositeItem not receiving focus when clicking with Safari/VoiceOver (d3ba001)
  • Fix Dialog closing on Firefox when the window loses focus and get focused again (#620) (7c3119d), closes #619
  • Fix Menu -> Dialog -> Menu behaving as a sub menu (#621) (9feb9c1)
  • Fix Tooltip when used with Composite components (#623) (0b70f43)
  • Fix animated Dialog not being correctly focused with VoiceOver (#618) (db71535)
  • Fix click outside not closing all Menu (341a250)
  • Fix disabled MenuButton being activated when used as a menu item (6c31dab)
  • Fix falsy values on Radio not working (387e8d3), closes #607
  • Fix nested Dialog not rendering correctly when the parent has a backdrop (ce766d5)
  • Fix nested modals when using VoiceOver/Safari (#608) (417b3b3)
  • Fix submenu closing when trying to move into it (38f0c0b)

Features

  • Add experimental unstable_timeout option to useTooltipState (#622) (5fe208f)
  • Hide Tooltip when pressing Escape (#629) (d7f5e8c)
  • Remove experimental IdGroup component (1c73f02)
  • Replace unstable_animated by animated with improvements on the API (#616) (16f843f), closes #528

BREAKING CHANGES

  • This should affect only people who were using the unstable_animated API: DisclosureContent and its derivative components don't add hidden class anymore. You should now use [data-enter] and [data-leave] selectors. For more details, see Animating.

1.0.0-rc.0 (2020-03-30)

Bug Fixes

  • Fix Tabbable dispatching click twice when it's composed by another Tabbable (#553) (d231120)

Features

  • Add Clickable component (#596) (6a9fca9)
  • Add DisclosureContent component (#554) (fd93b08)
  • Automatically check Radio on focus (#599) (6edc689)
  • Remove Provider from reakit/utils/Provider (134f7eb)
  • Select the first Tab by default and don't require stopId prop (#597) (528b016)
  • Support rtl on Toolbar (#601) (2811071)

BREAKING CHANGES

  • The first Tab is now selected by default. There's no need to pass selectedId to useTabState anymore.

    If you're already using selectedId to select a tab in the initial render, you don't need to change anything as this still works. But, if you want to render tabs with none selected, you should now pass null to selectedId:

    // if you're already using selectedId, there's no need to change anything
    const tab = useTabState({ selectedId: "tab-1" });
    // when there's no tab selected by default, you now need to explicitly specify it
    - const tab = useTabState();
    + const tab = useTabState({ selectedId: null });
  • Most users will not be affected by this, but stops, register and unregister on the returned object of state hooks have been renamed to items, registerItem and unregisterItem, respectively.

    const tab = useTabState();
    - tab.stops.map(...);
    + tab.items.map(...);
    - tab.register(...);
    + tab.registerItem(...);
    - tab.unregister(...);
    + tab.unregisterItem(...);
  • Tabbable doesn't trigger a click on the element when pressing Enter and Space anymore. If you need that feature, use Clickable instead.

    Before:

    import { Tabbable } from "reakit/Tabbable";
    <Tabbable />

    After:

    import { Clickable } from "reakit/Clickable";
    // Tabbable is not going away, it just doesn't represent a clickable element
    // anymore
    <Clickable />
  • Importing Provider from reakit/utils is not supported anymore. It should be imported from reakit/Provider or reakit.

  • DisclosureRegion has been renamed to DisclosureContent.

1.0.0-beta.16 (2020-02-10)

Bug Fixes

  • Check for classList existence before use (#540) (92a5fa1), closes #537
  • Fix transitionEnd capturing children transitions (#548) (4cf1eaa), closes #531
  • Fix inconsistent Tooltip behavior on disabled Tabbable (#552) (d507772), closes #471
  • Fix portaled components without dimensions in the first render (#547) (8783aec), closes #532
  • Remove confusing rover.unregister() warning (#549) (2a72e35), closes #488

Features

BREAKING CHANGES

  • The internal popper.js dependency has been upgraded to v2. The stable Popover API remains the same. But, while this change has been tested with the most common use cases, there may be some edge cases where Popover and Menu (which uses Popover underneath) may behave differently.

1.0.0-beta.15 (2020-02-05)

Bug Fixes

  • Fix parent Dialog closing when clicking on nested DialogBackdrop (#530) (e8bc3be), closes #529
  • Fix warning on deprecated Provider import (1cd9421)
  • Prevent clicks when pressing Enter/Space with meta key on non-native Tabbable (#534) (7f0c8cf)
  • Stop converting File objects into plain objects when submitting Form (5899d8d), closes #415

Features

  • Add modal state to useDialogState (#535) (f3953ad), closes #404
  • Add unstable_offset option to usePopoverState (#527) (301fbca), closes #511
  • Render nested Dialog on a portal outside of its parent Dialog (#533) (9f0a5cc)
  • Replace unstable_wrap by wrapElement (#538) (17a12fb)
  • reakit-utils: Add getActiveElement method (a252fcd)

BREAKING CHANGES

  • This should affect a very small number of people: the way nested modal Dialogs are rendered has been changed. To avoid styling issues, nested dialogs are rendered outside of the parent Dialog (but still inside the parent Portal).

1.0.0-beta.14 (2019-12-18)

Bug Fixes

  • Fix Dialog closing when clicking inside it and dragging outside (#510) (7d580e6), closes #506
  • Fix Portal with null context on client (#514) (619adfd), closes #513
  • Fix components not rendering id prop (#520) (866db9d), closes #518

Features

  • Add unstable_inner option to usePopoverState (#517) (d5e1e8f), closes #516

1.0.0-beta.13 (2019-11-22)

Bug Fixes

  • Fix form.reset() not reverting array fields to initial state (#503) (43ca6a8), closes #502
  • Prevent an unnecessary re-render on Button (e39842d)
  • Standardize precedence when options and htmlProps conflict (#501) (5b8e02f)
  • Stop ignoring checked and value props passed as html props to useCheckbox (#500) (c8cb0bb), closes #465
  • Stop persisting onChange event on Checkbox (#499) (fd4a694), closes #498

BREAKING CHANGES

  • When passing a custom onChange prop to Checkbox, event.target.checked will no longer return a different value than when using the native <input type="checkbox"> element.

    Before:

    <Checkbox onChange={event => setChecked(!event.target.checked)} />;

    After:

    <Checkbox onChange={event => setChecked(event.target.checked)} />;

1.0.0-beta.12 (2019-11-14)

Features

  • reakit-system: Replace useCompose by useComposeOptions on createHook (#493) (50fd7df)
  • Add baseId option to useHiddenState and derivative hooks (837aa58)
  • Add baseId option to useRoverState and derivative hooks (#494) (42e9dd0)
  • Add experimental Id module (#492) (5d87e99)

1.0.0-beta.11 (2019-11-08)

Bug Fixes

  • Fix Tabbable preventing click after enabling it (#481) (6b58a34), closes #480
  • Fix Tabbable preventing space and enter keys on FormInput (3f49d6b)

1.0.0-beta.10 (2019-11-02)

Bug Fixes

  • Fix MenuItemCheckbox and MenuItemRadio not working (#473) (11b7bfa), closes #472
  • Fix Rover trying to focus itself again when it receives focus (#476) (b27194e)
  • Fix Tabbable focus behavior on Mac Safari/Firefox (#458) (8306241)
  • Stop adding type="button" on Button by default (#474) (82b7279)

1.0.0-beta.9 (2019-10-12)

Bug Fixes

  • Add a useIsomorphicEffect hook to allow proper SSR rendering (#461) (47434b2), closes #438
  • Fix PopoverArrow ignoring size prop (#455) (5f51e39), closes #454
  • Fix nested Dialogs not working with VoiceOver (#457) (208bcb6)
  • Make Menu run without menu state props (#459) (5992362)
  • Prevent scrollbar flickering when opening Dialog (#450) (d84fd10), closes #449

Features

  • Expose unstable_update() to update the popover positioning (#463) (eb4a8e5)

1.0.0-beta.8 (2019-09-25)

Bug Fixes

  • Fix MenuItem ignoring ref prop (19119ca)
  • Fix focus not going onto MenuDisclosure after closing a Menu opened with down arrow (01f83ba)
  • Replace IE11 incompatible DOM features (#443) (8837557), closes #360

Features

  • Add gutter option to usePopoverState (#442) (5e9bc21)
  • Add experimental unstable_portal prop to Tooltip (#440) (1b2d5dd)
  • Add experimental unstable_scheduleUpdate function to usePopoverState return (still undocumented) (b40a4da)

1.0.0-beta.7 (2019-09-19)

Bug Fixes

  • Fix Dialog initial focus (#433) (a0916c7)
  • Fix Dialog with tabIndex={0} not being included in the tab order (#426) (bfb1d05)
  • Fix FormSubmitButton ignoring disabled prop (#439) (bbfdfdd), closes #437

Features

BREAKING CHANGES

  • StaticMenu has been replaced by MenuBar.

    Before:

    import { useMenuState, StaticMenu } from "reakit/Menu";
    
    const menu = useMenuState();
    <StaticMenu {...menu} />;

    After:

    import { useMenuBarState, MenuBar } from "reakit/Menu";
    
    const menuBar = useMenuBarState(); // useMenuState can be used here as well
    <MenuBar {...menuBar} />;

1.0.0-beta.6 (2019-08-25)

Bug Fixes

  • Fix Checkbox event.target.checked value inside onChange event (#419) (75063fc), closes #393
  • Fix FormInput as textarea caret position when focusing (#420) (d8e7af3), closes #418
  • Fix useRoverState and its derivatives including all props in the return object (987d16e)
  • Remove erroneous React.LiHTMLAttributes type from ToolbarItemHTMLProps (0cb6e66)

Features

  • reakit-utils: Move tabbable internal module to reakit-utils package (b84acce)
  • Add new MenuArrow component (#422) (731a376)
  • Add support for HiddenDisclosure to control multiple Hidden components (#423) (bdfbd74)
  • Support nested Tabbable and Rover components (#417) (ee9623e), closes #376

1.0.0-beta.5 (2019-08-12)

Bug Fixes

  • Fix typings (29c4456)
  • Fix FormGroup and FormRadioGroup not receiving focus when Form has been submited with errors (59adc8b)
  • Fix FormSubmitButton not considering elements other than inputs as invalid fields (c4f688a)
  • Fix Hidden not setting unstable_animating to false while visible (#410) (6d5827c), closes #407
  • Fix Menu preventing default behavior when pressing ASCII keys on elements other than MenuItem (cacb978)
  • Fix Tooltip error when visible is initially set to true (#409) (c132e56), closes #408
  • Fix empty array values being filtered prematurely before useFormState's onValidate (6052829)

Features

  • Support onSubmit and onValidate functions to be updated between renders in useFormState (#411) (f576db1), closes #400

1.0.0-beta.4 (2019-06-27)

Bug Fixes

  • Always focus Rover when calling rover.{move|first|last}() (#389) (f346df4)
  • Fix missing React Hooks deps (b08b62c)

Features

  • website: Hide state hook props from docs (#390) (fdac912)
  • Add new size prop to PopoverArrow and TooltipArrow (11a6df1), closes #383

1.0.0-beta.3 (2019-06-23)

Bug Fixes

  • Add missing deps to usePopoverState effect (d44df81)
  • Make Menu work properly with unstable_animated (#386) (b96c466)
  • Remove false positive warning from Dialog (#385) (5334bd4)

Features

  • Move helpers to separate package (reakit-utils, reakit-system) (#380) (354b874)

BREAKING CHANGES

  • Utils aren't exported by reakit or reakit/utils anymore. Import them from the reakit-utils package instead.
  • System utils aren't exported by reakit or reakit/system anymore. Import them from the reakit-system package instead.
  • Provider isn't exported by reakit/utils or reakit/utils/Provider anymore. Import it from reakit or reakit/Provider instead.

1.0.0-beta.2 (2019-06-01)

Bug Fixes

  • Fix Checkbox toggling twice on space bar key on Firefox (#369) (27e9b63), closes #368
  • Remove async/await so users don't need regenerator-runtime (#365) (9c6d41a)
  • Stop adding role="button" on Button by default (574e2a9)

Features

  • Add unstable_animated option to useHiddenState and its derivatives (#370) (4ba7f61)
  • Enable conditional render on Hidden components with render props (#371) (70322c2)
  • Remove z-index and extra styles from Dialog and DialogBackdrop (#372) (5edd0d8), closes #366

BREAKING CHANGES

  • Removed extra styles from Dialog and DialogBackdrop and all their derivative components. Also removed default z-index from Tooltip. These styles have been moved to the reakit-system-bootstrap package. If you're not using this system package, you should apply the styles manually.

    Before:

    <DialogBackdrop />
    <Dialog />
    <Popover />
    <Menu />
    <Tooltip />

    After:

    <DialogBackdrop
      style={{
        position: "fixed",
        top: 0,
        right: 0,
        bottom: 0,
        left: 0,
        zIndex: 998
      }}
    />
    <Dialog style={{ zIndex: 999 }} />
    <Popover style={{ zIndex: 999 }} />
    <Menu style={{ zIndex: 999 }} />
    <Tooltip style={{ zIndex: 999 }} />

1.0.0-beta.1 (2019-05-21)

Bug Fixes

  • Avoid infinite loop when using render props composition (8256330)
  • Fix Provider not working without unstable_system prop (37862fb)
  • Stop flipping orientation on Separator (52a0e63)

Features

  • Set display: none on Hidden when its visible prop is set to false (73d6cd2)

BREAKING CHANGES

  • Separator doesn't flip its orientation anymore. If you pass orientation="vertical" it'll render aria-orientation="vertical" now.

1.0.0-beta.0 (2019-05-13)

Bug Fixes

  • Fix Tabbable erroneously preventing onMouseDown on inputs (10af438)
  • Fix nested Dialogs not closing when parent dialogs close (84d1e16)

1.0.0-alpha.4 (2019-05-12)

Bug Fixes

  • Fix Menu not correctly moving with arrow keys (3b55b85)
  • Fix PopoverArrow styles (a90d71f)
  • Fix Tabbable not responding to Enter key (24b54c3)
  • Fix arrow keys closing Dialog opened by Menu (c3fdbcd)
  • Prevent buggy scroll on focus when showing Dialog (e0a328b)
  • Remove the need of double click on MenuItem on mobile (73b920e)
  • Render VisuallyHidden as span instead of div since it could be placed in an inline element (ac24c08)

Features

  • Add state and setState props to Checkbox and Radio (5902ab1)
  • Add unstable_animated prop to Hidden (e0ff29f)
  • Add unstable_preventOverflow, unstable_boundariesElement and unstable_fixed props to usePopoverState (f0930e2)
  • Add experimental unstable_orphan prop to Dialog (d0f6b52)
  • Remove experimental KeyBinder in favor of internal createOnKeyDown util (b0adfa8)
  • Rename mergeProps util to unstable_mergeProps (9be2e14)
  • Warn when some refs aren't passed to components (92f035c)

Performance Improvements

  • Improve general performance by using React.memo on components (91f0d54)

BREAKING CHANGES

  • mergeProps util has been renamed to unstable_mergeProps and is not exported by the root package anymore. Instead, it should be imported from reakit/utils/mergeProps.
  • currentValue and setValue have been replaced by state and setState on Checkbox, Radio and all their derivative components and related hooks.
  • All the ComponentProps typings have been renamed to ComponentHTMLProps. ComponentProps is now the combination of ComponentOptions and ComponentHTMLProps.
  • placement prop is now required on MenuDisclosure.
  • placement prop is now required on Menu.

1.0.0-alpha.3 (2019-04-25)

Bug Fixes

  • Fix Checkbox not reverting indeterminate state when currentValue changes (2ee7455)
  • Fix mouseOut events triggering outside Dialog. (d814ddf)
  • Fix arrow keys not working on Menu when cursor leaves it (9f278ac)
  • Fix arrow keys on MenuItem incorrectly hiding Menu (94bd9db)
  • Fix focusing MenuItem on mouse over outside an open Dialog (aac7f3c)

Features

  • Add VisuallyHidden component (7b1d826)
  • Add experimental KeyBinder component (7eb739a)
  • Render MenuGroup as a div instead of fieldset (5d4b476)
  • Return unstable_wrap method from props hooks (f668ae4)

1.0.0-alpha.2 (2019-04-17)

Bug Fixes

  • MenuDisclosure should close the submenu when in menubar (d481674)
  • Change system's useProps order in built-in components (e679024)
  • Fix DialogDisclosure not closing Dialog on Safari when hideOnClickOutside is truthy (37865cf)
  • Fix MenuDisclosure race condition on focus/click (8a37d31)
  • Make click/focus behavior cross-browser by automatically focusing Tabbable on mouse down (54b618c)
  • Restore hasShownOnFocus state in MenuDisclosure (63228fd)

Features

  • Add use prefix automatically in useProps/useOptions (167fda1)
  • Expose unstable_useSealedState util (1540eab)
  • Remove unstable_ prefix from currentId prop (003d1ad)
  • Remove unstable_ prefix from focusable prop (965dcb7)
  • Remove unstable_ prefix from loop, move, next, previous, first, last props (501f822)
  • Remove unstable_ prefix from manual, selectedId, select props (c36413f)
  • Remove unstable_ prefix from stops, register and unregister props (061cc55)
  • Remove focus from MenuItem on mouse out (fdd1bb8)

1.0.0-alpha.1 (2019-04-09)

Bug Fixes

  • Clicking on an element inside the disclosure should hide Dialog (93072cb)

Features

  • Improve Dialog/Menu API (cf7426f)
  • Remove unstable_ prefix from many things (ec434fc)

1.0.0-alpha.0 (2019-04-02)

Note: Version bump only for package reakit