Decathlon / vitamin-web

Decathlon Design System UI components for web applications
https://decathlon.github.io/vitamin-web
Apache License 2.0
279 stars 77 forks source link

fix(@vtmn/svelte, @vtmn/vue, @vtmn/react): interactive `VtmnRating` have duplicate `$$restProps` #1411

Closed Tlahey closed 1 year ago

Tlahey commented 1 year ago

Closes #1385

Changes description

Add on the VtmnRating svelte component a check on the restProps in order to not apply it on the root level of the component and under if the rating is interactive. No changes on the class, only on props like aria-label etc ...

Context

In some case, if the component is interactive, the class are applied twice, on the root level and under.

Checklist

Does this introduce a breaking change?

Tested on svelte / react / vue on storybook.

lauthieb commented 1 year ago

Thanks @Tlahey, that's ok for me. I'll let @thibault-mahe review next Tuesday.