cloudflare / cf-ui

:gem: Cloudflare UI Framework
Other
1.29k stars 81 forks source link

feat(cf-component-checkbox): migrate css to fela #310

Closed koddsson closed 7 years ago

koddsson commented 7 years ago

BREAKING CHANGE: Styles are now managed in the component using the CSS-in-JS framework fela. This internal re-write warrants a re-write.

Additionally the onChange callback on the input has changed. The callback now gives you the change event rather than just the Event.EventTarget.checked property.

Related-to: #212

tajo commented 7 years ago

Additionally the onChange callback on the input has changed. The callback now gives you the change event rather than just the Event.EventTarget.checked property.

Why? It seems like an implementation detail that doesn't need to be exposed.

koddsson commented 7 years ago

Additionally the onChange callback on the input has changed. The callback now gives you the change event rather than just the Event.EventTarget.checked property.

Why? It seems like an implementation detail that doesn't need to be exposed.

It matches the behaviour of cf-component-input as well as giving you access to the whole event in case you'd like to use the target element or any other data in the event.

koddsson commented 7 years ago

What do you think about this @tajo ?