These are chat archives for chandu0101/scalajs-react-components

13th
Nov 2015
Roberto Leibman
@rleibman
Nov 13 2015 17:23
@elacin... hey I've got some questions as I work on elemental-ui.... Firstly... how far are you on your latest version of material? I'd love to ask for a merge of my stuff into head at some point, but since I'm basing my stuff on your fork I want to coordinate with you on that.
Øyvind Raddum Berg
@oyvindberg
Nov 13 2015 18:00
hey @rleibman - really cool that you're working on elemental-ui
um, its pretty far along
im squeezed on time nowadays, so things are going a bit slow
i can merge the scalajs-react branch asap, as it seems to be working
the material-ui 0.13 update is "done" but not tested
Roberto Leibman
@rleibman
Nov 13 2015 18:01
Yeah, I just got your latest branch and it broke all that I was doing ... but no worries I'll get it back to working soon.
Øyvind Raddum Berg
@oyvindberg
Nov 13 2015 18:02
hehe sorry about that, though there shouldnt be big breakages
anyway i generated the new material-ui from the documentation in part
so im going to write a few more complicated demos to see if it really works well
Roberto Leibman
@rleibman
Nov 13 2015 18:03
Well, on the old branch you had a bunch of U[Something] while you now do a (clearer, IMHO) js.UndefOr
Øyvind Raddum Berg
@oyvindberg
Nov 13 2015 18:03
thought its looking good
ah yeah, i stopped that, there was no point to it
but you can search/replace it
Roberto Leibman
@rleibman
Nov 13 2015 18:12
How would you map
value: React.PropTypes.oneOfType([
20 React.PropTypes.number,
21 React.PropTypes.string
22 ]
It didn't like js.UndefOr[String | Number]
Øyvind Raddum Berg
@oyvindberg
Nov 13 2015 18:17
also dont like it
not sure yet
perhaps it can work with a wrapper AnyVal class StringOrNumber
havent tried, but it might be better
Roberto Leibman
@rleibman
Nov 13 2015 18:18
I'll just let it go as a String for now.
Øyvind Raddum Berg
@oyvindberg
Nov 13 2015 18:23
i guess that blows up if you actually get a number?
Roberto Leibman
@rleibman
Nov 13 2015 18:25
I have no idea. It's for an input field, I'm sure some of it's newer types (like range) support a number, but I imagine javascript in it's untyped "beauty" won't care.
Or it will convert "5" to Nothing or something equally stupid.
Øyvind Raddum Berg
@oyvindberg
Nov 13 2015 20:10
ah, you wrote «it didnt like» - you can solve that actually
but there is still implicit resolution issues, in that say a user-provided Int might be upgraded to a Int | String, but not necessarily a js.UndefOr[Int | String]
which is why i dont like it, hehe