Element: [Bug Report] Radio button group fails using vue 2.5.0

Created on 13 Oct 2017  ·  4Comments  ·  Source: ElemeFE/element

Element UI version

1.4.6

OS/Browsers version

Arch Linux/ Chromium 61.0.3163.100

Vue version

2.5.0

Reproduction Link

https://jsfiddle.net/sunsijie/pgn7gyu9/#&togetherjs=smS20MqksL

Steps to reproduce

just click it

What is Expected?

only one should be highlighted

What is actually happening?

every item clicked is highlighted

Most helpful comment

Same here.

the cause is that the input element's input event cannot be handled by v-model in 2.5.0, so the parent radio group will never $emit

A thing to note:
If you import redio button directly from source (with webpack), that said, use import ElRadioButton from 'element-ui/packages/radio-button' and use it in your code, the component will work again.
So this bug seems to be a regression on vue's side

seems similar cause for #7474

All 4 comments

Same here.

the cause is that the input element's input event cannot be handled by v-model in 2.5.0, so the parent radio group will never $emit

A thing to note:
If you import redio button directly from source (with webpack), that said, use import ElRadioButton from 'element-ui/packages/radio-button' and use it in your code, the component will work again.
So this bug seems to be a regression on vue's side

seems similar cause for #7474

posted an issue in vue vuejs/vue#6803

it is to be fixed in vue's next patch version

@KagamiChan Thanks for boiling it down.

Upgrading Vue to 2.5.2 fixes this: https://jsfiddle.net/pgn7gyu9/1/

Was this page helpful?
0 / 5 - 0 ratings

Related issues

fscardua picture fscardua  ·  3Comments

akaylh picture akaylh  ·  3Comments

smallpath picture smallpath  ·  3Comments

chao-hua picture chao-hua  ·  3Comments

Kingwl picture Kingwl  ·  3Comments