optimistex / ngx-select-ex

Angular based replacement for select boxes
https://optimistex.github.io/ngx-select-ex/
MIT License
109 stars 42 forks source link

any click in input allows multiselect to open #156

Closed craig-dae closed 5 years ago

craig-dae commented 5 years ago

User can click anywhere in the select input area to open a dropdown, instead of only on the second row.

Prevents propagation when clicking on an existing entry

craig-dae commented 5 years ago

I don't understand why the checks failed. Something with the build. Worked fine on my end, and the unit tests passed, but I had the same weird issue when I tried to build. All I changed was two lines of html.

Edit: Just had a chance to look at it. See the problem. Considering a fix. The problem is that the variable input is out of scope on line 40, because it's declared as a tag variable on line 58. Working on a solution.

codecov-io commented 5 years ago

Codecov Report

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

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #156   +/-   ##
=======================================
  Coverage   82.53%   82.53%           
=======================================
  Files          13       13           
  Lines         584      584           
  Branches      137      137           
=======================================
  Hits          482      482           
  Misses         23       23           
  Partials       79       79
Impacted Files Coverage Δ
src/app/lib/ngx-select/ngx-select.component.ts 89% <100%> (ø) :arrow_up:

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 aa1d9e4...29be8d3. Read the comment docs.

craig-dae commented 5 years ago

Issue resolved. Can't use (click)="inputClick(input && input.value)" because input is out of scope on line 40. Used inputElRef instead, which is defined in the component.ts, and is available.

optimistex commented 5 years ago

Merged into development branch. To install it use npm i ngx-select-ex@3.6.11-dev