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

fix(Tab): use correct onTabChange activeIndex #1890

Merged
merged 1 commit into from
Jul 21, 2017

Conversation

levithomason
Copy link
Member

@levithomason levithomason commented Jul 21, 2017

Fixes #1888

The proposed activeIndex was being overridden by spreading props after it was set.

Tests were passing due to forgiving calledWithMatch logic. I've updated tests to be more strict and added an explicit test.

I've also updated the controlled example to handle onTabChange in addition to the range input. This way we have test and doc coverage on this.

@codecov-io
Copy link

codecov-io commented Jul 21, 2017

Codecov Report

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

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #1890   +/-   ##
=======================================
  Coverage   99.75%   99.75%           
=======================================
  Files         145      145           
  Lines        2477     2477           
=======================================
  Hits         2471     2471           
  Misses          6        6
Impacted Files Coverage Δ
src/modules/Tab/Tab.js 100% <100%> (ø) ⬆️

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 18a8c3e...504de5f. Read the comment docs.

@levithomason levithomason merged commit d58b584 into master Jul 21, 2017
@levithomason levithomason deleted the fix/tab-callback-active-index branch July 21, 2017 20:37
@levithomason
Copy link
Member Author

Released in semantic-ui-react@0.71.2

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.

2 participants