Fork me on GitHub
#reagent
<
2017-03-17
>
negaduck13:03:04

I spent so much time submitting this issue. Here’s a byproduct: https://koddo.github.io/tmp-cljs-react-with-addons-issue/ <- click the checkbox

negaduck13:03:06

sadly, css transitions are slow and jerky in ios safari

joshkh14:03:22

does reagent have a logo? i need something visual for a slide deck 🙂

negaduck14:03:47

and a sticker for macbook

shaun-mahood15:03:48

@gadfly361 was handing out Reagent stickers at the last Conj - they are pretty sweet 🙂 The logo can be seen at the top of https://github.com/reagent-project or https://avatars3.githubusercontent.com/u/9254615 for the actual image.

shdzzl16:03:51

So, after seeing the logo pasted here, I thought I might try my hand at making an alternative logo. I'm not a graphic designer or anything but it seemed like a fun way to kill an hour. So I present an incredibly dodgy GIMP-edit reagent logo remix: http://imgur.com/xE8keVa

shdzzl16:03:33

The difference in thickness between React's electron orbits and the bottle's brackets could be reduced. But all in all, I think it's alright for a little under an hour's work.

gadfly36119:03:23

That's a picture of the stickers I have

kenny21:03:50

Does anyone have a workaround for typing negative numbers into a type=number input box? For example, take this code:

(defonce input-state (r/atom 0))

(defn hello []
  [:input {:type "number"
           :value @input-state
           :on-change (fn [evt]
                        (reset! input-state (aget evt "target" "value")))}])

[hello]
If you try and input a negative number into the input box, it will not let you — the input box remains blank after typing a hyphen. I suppose I could just make the input type=text and write my own validation logic but then I lose the ability to use the up and down arrows to change the value and the numeric keyboard won’t pop up on mobile devices.

shdzzl22:03:32

@kenny use :on-input

kenny22:03:06

@shdzzl I now receive this warning:

Warning: Failed form propType: You provided a `value` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultValue`. Otherwise, set either `onChange` or `readOnly`. Check the render method of `ReagentInput`.
I can add a nop fn :onChange handler to the input but then I am not able to type in a negative number anymore.

gordon23:03:17

@kenny which browser are you using for testing?

shdzzl23:03:04

Had to step out for a bit.

gordon23:03:53

One workaround if you want the keyboard is <input type="text" pattern="\d*"> or something like it http://stackoverflow.com/questions/6178556/phone-numeric-keyboard-for-text-input