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

release 4.0.0 (#812) #857

Merged
merged 6 commits into from
Dec 18, 2019
Merged

release 4.0.0 (#812) #857

merged 6 commits into from
Dec 18, 2019

Conversation

silviuaavram
Copy link
Collaborator

@silviuaavram silviuaavram commented Dec 12, 2019

Release useCombobox hook, adapts the TS typings and improves the docsite.

The useCombobox should be the way forward when it comes to building an autocomplete component.
Structure the docsite as a Hooks menu with a submenu for each hook. Each hook should be represented on a full page.
Details in #812.

BREAKING CHANGE: Remove DownshiftInterface as it's not required anymore to make Downshift props generic.You can pass your generic to the Downshift props as <Downshift<MyItem> {...props} />. #748

BREAKING CHANGE: Change TS typings for useSelect, in getter props, to specify that most of them will require refKey in case the user renders a custom React component with a ref prop that has a different name than ref (like innerRef for instance). #812

  getToggleButtonProps: (options?: UseSelectGetMenuPropsOptions) => any
  getLabelProps: (options?: UseSelectGetLabelPropsOptions) => any
  getMenuProps: (options?: UseSelectGetToggleButtonPropsOptions) => any
  getItemProps: (options: UseSelectGetItemPropsOptions<Item>) => any

Each new UseSelect type is like:

export interface UseSelectGetToggleButtonPropsOptions
  extends GetPropsWithRefKey,
    GetToggleButtonPropsOptions {}

silviuaavram and others added 3 commits December 12, 2019 14:59
* start implementation

* more code reuse

* create useCombobox

* start implementation for handlers

* remove not needed call

* input handlers

* progress on handlers

* fix close on toggle button click

* remove unneeded state change types

* add example to docsite

* focus input at toggle click + reactNative

* add setInputValue

* rename root to combobox + tests

* add icon to button

* add item tests

* add more menu tests

* finished input tests + initial state

* finish testing

* don't apply handlers if disabled

* add tests for disabled cases

* apply mozilla button close fix

* initial default values small refactor

* improvements for docs

* updates to the docs and readme

* readme updates

* prop types validation not on production

* readme correction

* add ts typings
@codecov-io
Copy link

codecov-io commented Dec 12, 2019

Codecov Report

Merging #857 into master will not change coverage.
The diff coverage is 100%.

Impacted file tree graph

@@          Coverage Diff           @@
##           master   #857    +/-   ##
======================================
  Coverage     100%   100%            
======================================
  Files           8     12     +4     
  Lines         702    886   +184     
  Branches      158    184    +26     
======================================
+ Hits          702    886   +184
Impacted Files Coverage Δ
src/hooks/useSelect/index.js 100% <ø> (ø) ⬆️
src/hooks/useSelect/reducer.js 100% <ø> (ø) ⬆️
src/downshift.js 100% <ø> (ø) ⬆️
src/hooks/useCombobox/testUtils.js 100% <100%> (ø)
src/hooks/useCombobox/reducer.js 100% <100%> (ø)
src/hooks/useSelect/testUtils.js 100% <100%> (ø) ⬆️
src/hooks/useCombobox/index.js 100% <100%> (ø)
src/hooks/useSelect/utils.js 100% <100%> (ø) ⬆️
src/hooks/utils.js 100% <100%> (ø) ⬆️
src/hooks/useCombobox/utils.js 100% <100%> (ø)
... and 4 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 78e47ae...94fc1ac. Read the comment docs.

@silviuaavram silviuaavram changed the title 4.0.0 (#812) feat: release 4.0.0 (#812) Dec 16, 2019
@silviuaavram silviuaavram changed the title feat: release 4.0.0 (#812) release 4.0.0 (#812) Dec 16, 2019
@silviuaavram silviuaavram merged commit 1a11745 into master Dec 18, 2019
@silviuaavram silviuaavram deleted the next branch December 18, 2019 11:35
@silviuaavram
Copy link
Collaborator Author

🎉 This PR is included in version 3.5.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@silviuaavram
Copy link
Collaborator Author

Will re-release this to 4.0.0.

@silviuaavram silviuaavram restored the next branch December 18, 2019 13:02
silviuaavram added a commit that referenced this pull request Dec 18, 2019
@silviuaavram
Copy link
Collaborator Author

🎉 This PR is included in version 4.0.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants