Fork me on GitHub
#reagent
<
2018-11-16
>
ouvasam06:11:13

Hi @thheller and many thanks. I did try and it is better now. but still can’t make it work

ouvasam06:11:17

i have this

ouvasam06:11:19

(def el (.div posed #js {:aaa {“opacity” .5} :bbb {“opacity” .5}})) (.log js/console el) (defn pose-test [] [:> el {:pose :aaa} “pose test”]))

ouvasam06:11:00

The compoenent render well but it does not take the pose attribute in account

ouvasam06:11:58

I did try several syntax and even [(r/adapt-react-class el) ...

ouvasam06:11:34

i can see the style attribute on the element and the defined trnasition when log el

thheller07:11:31

@ouvasam #js does not transform nested objects so {"opacity" .5} remains as a clojure map which JS doesn't support. try (clj->js {:aaa {"opacity" ...}})

🙏 4
ouvasam07:11:41

@thheller Wow !!! Many thanks 🙏 It works now 🙂

ouvasam07:11:04

Here is the code for others who will search for this :

ouvasam08:11:02

And here the code for a using a transition