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: picklist when readonly and click the label it opens the menu #2041

Conversation

yvmunayev
Copy link
Contributor

fix: #2036

Changes proposed in this PR:

@nexxtway/react-rainbow

@commit-lint
Copy link

commit-lint bot commented Dec 5, 2020

Bug Fixes

  • picklist when readOnly and click the label it opens the menu (cd78c27)

Tests

Contributors

yvmunayev, TahimiLeonBravo

Commit-Lint commands

You can trigger Commit-Lint actions by commenting on this PR:

  • @Commit-Lint merge patch will merge dependabot PR on "patch" versions (X.X.Y - Y change)
  • @Commit-Lint merge minor will merge dependabot PR on "minor" versions (X.Y.Y - Y change)
  • @Commit-Lint merge major will merge dependabot PR on "major" versions (Y.Y.Y - Y change)
  • @Commit-Lint merge disable will desactivate merge dependabot PR
  • @Commit-Lint review will approve dependabot PR
  • @Commit-Lint stop review will stop approve dependabot PR

this.setState({
isOpen: true,
});
}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we should add test to this

@@ -132,4 +132,18 @@ describe('<Picklist />', () => {
expect(component.find('[aria-expanded=true]').exists()).toBe(false);
expect(component.find(InternalOverlay).prop('isVisible')).toBe(false);
});
it('should not open menu when is readOnly and click the picklist label', () => {
const component = mount(
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar blocks of code found in 3 locations. Consider refactoring.

@codeclimate
Copy link

codeclimate bot commented Dec 7, 2020

Code Climate has analyzed commit 8d14a83 and detected 1 issue on this pull request.

Here's the issue category breakdown:

Category Count
Duplication 1

View more on Code Climate.

@LeandroTorresSicilia LeandroTorresSicilia merged commit cde68df into nexxtway:master Dec 7, 2020
jpetaux pushed a commit to jpetaux/react-rainbow that referenced this pull request Jun 27, 2021
…xxtway#2041)

* fix: picklist when readOnly and click the label it opens the menu

* test: add unit test

Co-authored-by: Tahimi <tahimileon@gmail.com>
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.

fix: picklist when readOnly and click the label it opens the menu
3 participants