sparkbox / Custom-Selectbox

Select box UI replacement
70 stars 25 forks source link

Double .selected class #7

Closed ghost closed 12 years ago

ghost commented 12 years ago

If within options there is same words it gets class .selected try example below and you'll see that both first options will be selected.

<select class="sparkbox-custom">
    <option value="the_googs">Chrome</option>
    <option value="the_faris">Chrome Safari</option>
    <option value="foxfire">Firefox</option>
    <option value="the_splora">IE 9</option>
  </select>
happymonkeyshoes commented 12 years ago

Found this issue as well. Only happens with the top two options. Tested in current versions of Firefox and Chrome.

eithe commented 12 years ago

Fixed in this pull request: https://github.com/sparkbox/Custom-Selectbox/pull/8

kutec commented 11 years ago

If I take similar words it adds class SELECTED to both. Here is a code:

<select class="sparkbox-custom">
    <option value="1">Chrome</option>
    <option value="2">Safari Chrome</option>
    <option value="3">Firefox</option>
    <option value="4">IE 9</option>
</select>

If you select 1st value, 1st and 2nd both will be selected.

https://github.com/sparkbox/Custom-Selectbox/issues/8 doesn't help. Can anyone please suggest me the solution?