Skip to content
This repository has been archived by the owner on Oct 2, 2019. It is now read-only.

Don't hide input box when SearchEnable is false #1109

Closed
wants to merge 1 commit into from

Conversation

cdjackson
Copy link
Contributor

Fixes #453

@dimirc
Copy link
Contributor

dimirc commented Jul 31, 2015

Up and down key don't work

@cdjackson
Copy link
Contributor Author

Thanks - I’ll take a look…

@cdjackson
Copy link
Contributor Author

I've modified the concept slightly to allow the keys to work correctly. The problem was that by hiding the search box, we loose focus on the input. I've now changed this to instead add the 'ui-select-offscreen' class to the searchbox so that it still provides keyboard input, but is also hidden from the user.

I also added closing the select list if the list is open, and the user clicks on the match box again when in searchEnabled=false mode. Previously you had to click off the ui-select completely which seems wrong.

@wesleycho
Copy link
Contributor

History needs to be cleaned up here - there should not be any merge commits. It may be better to open a new PR with clean history.

angular-ui#453
Update to move search box off screen
Fix test to check against ui-select-offscreen class, not ng-hide

Signed-off-by: Chris Jackson <chris@cd-jackson.com>
@cdjackson
Copy link
Contributor Author

Squashed into a single commit.

fcaballero added a commit to fcaballero/ui-select that referenced this pull request Mar 30, 2016
fcaballero added a commit to fcaballero/ui-select that referenced this pull request Apr 25, 2016
…bled is false

Closes angular-ui#375 PRs angular-ui#1114 and angular-ui#1109

fix(indentation)  use 2 spaces, add white-space
user378230 pushed a commit to user378230/ui-select that referenced this pull request Jul 10, 2016
Fix issue where keyboard navigation was disabled when searchEnabled
was set to false.

Caused by hiding the input box which prevent key events from
propagating to the directive.

Resolved hiding the input offscreen when searchEnabled is false.

Fixes angular-ui#1059, fixes angular-ui#917, fixes angular-ui#589, fixes angular-ui#375
Closes angular-ui#1543, closes angular-ui#1114, closes angular-ui#1109 (supersedes all)
aaronroberson pushed a commit that referenced this pull request Aug 7, 2016
* fix(searchEnabled): maintain keyboard nagivation

Fix issue where keyboard navigation was disabled when searchEnabled
was set to false.

Caused by hiding the input box which prevent key events from
propagating to the directive.

Resolved hiding the input offscreen when searchEnabled is false.

Fixes #1059, fixes #917, fixes #589, fixes #375
Closes #1543, closes #1114, closes #1109 (supersedes all)

* fix(selectize): show placeholder when search disabled

Previously when searchEnabled was set to false, the placeholder would
also be hidden on the selectize theme.

This fix sets the search input to disabled rather then hidden when the
searchEnabled attribute is set to false.

Fixes #1145, fixes #949, fixes #691

* fix(searchEnabled): Prevent searching when disabled

Previously, even when search-enabled was set to false, users could
still type in text and filter the list. This made disabling the search
feature pointless.

This fix prevents text entry to the search input and thus disables
filtering.

Fixes #1658
kboga pushed a commit to kboga/ui-select that referenced this pull request Nov 29, 2016
* fix(searchEnabled): maintain keyboard nagivation

Fix issue where keyboard navigation was disabled when searchEnabled
was set to false.

Caused by hiding the input box which prevent key events from
propagating to the directive.

Resolved hiding the input offscreen when searchEnabled is false.

Fixes angular-ui#1059, fixes angular-ui#917, fixes angular-ui#589, fixes angular-ui#375
Closes angular-ui#1543, closes angular-ui#1114, closes angular-ui#1109 (supersedes all)

* fix(selectize): show placeholder when search disabled

Previously when searchEnabled was set to false, the placeholder would
also be hidden on the selectize theme.

This fix sets the search input to disabled rather then hidden when the
searchEnabled attribute is set to false.

Fixes angular-ui#1145, fixes angular-ui#949, fixes angular-ui#691

* fix(searchEnabled): Prevent searching when disabled

Previously, even when search-enabled was set to false, users could
still type in text and filter the list. This made disabling the search
feature pointless.

This fix prevents text entry to the search input and thus disables
filtering.

Fixes angular-ui#1658
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants