You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We are using {{one-way-select}} inside of an ember-modal-dialog and are animating that dialog using liquid-fire (via liquid-wormhole). Unfortunately during the animation the select box will always select the first element in the list instead of the selected one. Once the animation has settled the correct option is selected.
We are using
{{one-way-select}}
inside of anember-modal-dialog
and are animating that dialog usingliquid-fire
(vialiquid-wormhole
). Unfortunately during the animation the select box will always select the first element in the list instead of theselected
one. Once the animation has settled the correct option is selected.I've traced this down to the
selected
attribute in<option selected={{isSelected}}>
not being set properly on the DOM node (see also https://stackoverflow.com/questions/41839681/how-can-i-dynamically-set-the-selected-attribute-on-an-option-tag). Sinceliquid-fire
appears to clone the modal DOM for animation the cloned<option>
will not have theselected
attribute set on it, which causes the select box to default to the first entry.tl;dr https://github.com/DockYard/ember-one-way-controls/blob/v2.0.1/addon/templates/components/one-way-select/option.hbs#L2 is not quite working as expected
A possible solution is something like
which seems to be animated properly.
/cc @cibernox @ef4 @pzuraq
The text was updated successfully, but these errors were encountered: