["^ ","~:rename-macros",["^ "],"~:renames",["^ "],"~:externs",["^ ","~$Error",["^ "],"~$document",["^ ","~$getElementById",["^ "]],"~$goog",["^ ","~$date",["^ ","~$DateTime",["^ ","~$prototype",["^ ","~$getYear",["^ "],"~$getMonth",["^ "],"~$getDate",["^ "]]],"~$UtcDateTime",["^ "]]]],"~:use-macros",["^ ","~$superset?","~$clojure.set"],"~:excludes",["~#set",[]],"~:name","~$re-com.util","~:imports",null,"~:requires",["^ ","^@","^@","~$reagent.ratom","^G","~$goog.date.DateTime","^H","~$goog.date.UtcDateTime","^I"],"~:cljs.spec/speced-vars",[],"~:uses",["^ ","~$RAtom","^G","^?","^@","~$Reaction","^G","~$RCursor","^G","~$Track","^G","~$Wrapper","^G"],"~:defs",["^ ","~$sum-scroll-offsets",["^ ","~:protocol-inline",null,"~:meta",["^ ","~:file","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_com/util.cljs","~:line",139,"~:column",7,"~:end-line",139,"~:end-column",25,"~:arglists",["~#list",["~$quote",["^[",[["~$node"]]]]],"~:doc","Given a DOM node, I traverse through all ascendant nodes (until I reach body), summing any scrollLeft and scrollTop values\n   and return these sums in a map"],"^C","~$re-com.util/sum-scroll-offsets","~:variadic",false,"^U","out-cli/re_com/util.cljs","^Y",25,"~:method-params",["^[",[["^11"]]],"~:protocol-impl",null,"~:arglists-meta",["^[",[null,null]],"^W",1,"^V",139,"^X",139,"~:max-fixed-arity",1,"~:fn-var",true,"^Z",["^[",["^10",["^[",[["^11"]]]]],"^12","Given a DOM node, I traverse through all ascendant nodes (until I reach body), summing any scrollLeft and scrollTop values\n   and return these sums in a map"],"~$position-for-id",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_com/util.cljs","^V",105,"^W",7,"^X",105,"^Y",22,"^Z",["^[",["^10",["^[",[["~$id","~$v","~$&",["^ ","~:keys",["~$id-fn"],"~:or",["^ ","^1=","~:id"]]]]]]],"^12","Takes a vector of maps 'v'. Returns the position of the first item in 'v' whose id-fn (default :id) matches 'id'.\n   Returns nil if id not found","~:top-fn",["^ ","^14",true,"^18",2,"^15",[["^[",["^1;","~$v",["^ ","^1<",["^1="],"^1>",["^ ","^1=","^1?"]]]]],"^Z",["^[",[["^1;","~$v","~$&",["^ ","^1<",["^1="],"^1>",["^ ","^1=","^1?"]]]]],"^17",["^[",[null]]]],"^C","~$re-com.util/position-for-id","^14",true,"^U","out-cli/re_com/util.cljs","^Y",22,"^1@",["^ ","^14",true,"^18",2,"^15",[["^[",["^1;","~$v",["^ ","^1<",["^1="],"^1>",["^ ","^1=","^1?"]]]]],"^Z",["^[",[["^1;","~$v","~$&",["^ ","^1<",["^1="],"^1>",["^ ","^1=","^1?"]]]]],"^17",["^[",[null]]],"^15",[["^[",["^1;","~$v",["^ ","^1<",["^1="],"^1>",["^ ","^1=","^1?"]]]]],"^16",null,"^17",["^[",[null]],"^W",1,"^V",105,"^X",105,"^18",2,"^19",true,"^Z",["^[",[["^1;","~$v","~$&",["^ ","^1<",["^1="],"^1>",["^ ","^1=","^1?"]]]]],"^12","Takes a vector of maps 'v'. Returns the position of the first item in 'v' whose id-fn (default :id) matches 'id'.\n   Returns nil if id not found"],"~$enumerate",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_com/util.cljs","^V",132,"^W",7,"^X",132,"^Y",16,"^Z",["^[",["^10",["^[",[["~$coll"]]]]],"^12","(for [[index item first? last?] (enumerate coll)] ...)  "],"^C","~$re-com.util/enumerate","^14",false,"^U","out-cli/re_com/util.cljs","^Y",16,"^15",["^[",[["^1C"]]],"^16",null,"^17",["^[",[null,null]],"^W",1,"^V",132,"^X",132,"^18",1,"^19",true,"^Z",["^[",["^10",["^[",[["^1C"]]]]],"^12","(for [[index item first? last?] (enumerate coll)] ...)  "],"~$remove-id-item",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_com/util.cljs","^V",121,"^W",7,"^X",121,"^Y",21,"^Z",["^[",["^10",["^[",[["^1;","~$v","~$&",["^ ","^1<",["^1="],"^1>",["^ ","^1=","^1?"]]]]]]],"^12","Takes a vector of maps 'v', each of which has an id-fn (default :id) key.\n  Return v where item matching 'id' is excluded","^1@",["^ ","^14",true,"^18",2,"^15",[["^[",["^1;","~$v",["^ ","^1<",["^1="],"^1>",["^ ","^1=","^1?"]]]]],"^Z",["^[",[["^1;","~$v","~$&",["^ ","^1<",["^1="],"^1>",["^ ","^1=","^1?"]]]]],"^17",["^[",[null]]]],"^C","~$re-com.util/remove-id-item","^14",true,"^U","out-cli/re_com/util.cljs","^Y",21,"^1@",["^ ","^14",true,"^18",2,"^15",[["^[",["^1;","~$v",["^ ","^1<",["^1="],"^1>",["^ ","^1=","^1?"]]]]],"^Z",["^[",[["^1;","~$v","~$&",["^ ","^1<",["^1="],"^1>",["^ ","^1=","^1?"]]]]],"^17",["^[",[null]]],"^15",[["^[",["^1;","~$v",["^ ","^1<",["^1="],"^1>",["^ ","^1=","^1?"]]]]],"^16",null,"^17",["^[",[null]],"^W",1,"^V",121,"^X",121,"^18",2,"^19",true,"^Z",["^[",[["^1;","~$v","~$&",["^ ","^1<",["^1="],"^1>",["^ ","^1=","^1?"]]]]],"^12","Takes a vector of maps 'v', each of which has an id-fn (default :id) key.\n  Return v where item matching 'id' is excluded"],"~$remove-nth",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_com/util.cljs","^V",88,"^W",7,"^X",88,"^Y",17,"^Z",["^[",["^10",["^[",[["~$v","~$n"]]]]],"^12","Removes the item at position n from a vector v, returning a shrunk vector"],"^C","~$re-com.util/remove-nth","^14",false,"^U","out-cli/re_com/util.cljs","^Y",17,"^15",["^[",[["~$v","~$n"]]],"^16",null,"^17",["^[",[null,null]],"^W",1,"^V",88,"^X",88,"^18",2,"^19",true,"^Z",["^[",["^10",["^[",[["~$v","~$n"]]]]],"^12","Removes the item at position n from a vector v, returning a shrunk vector"],"~$deref-or-value",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_com/util.cljs","^V",22,"^W",7,"^X",22,"^Y",21,"^Z",["^[",["^10",["^[",[["~$val-or-atom"]]]]],"^12","Takes a value or an atom\n  If it's a value, returns it\n  If it's a Reagent object that supports IDeref, returns the value inside it by derefing\n  "],"^C","~$re-com.util/deref-or-value","^14",false,"^U","out-cli/re_com/util.cljs","^Y",21,"^15",["^[",[["^1J"]]],"^16",null,"^17",["^[",[null,null]],"^W",1,"^V",22,"^X",22,"^18",1,"^19",true,"^Z",["^[",["^10",["^[",[["^1J"]]]]],"^12","Takes a value or an atom\n  If it's a value, returns it\n  If it's a Reagent object that supports IDeref, returns the value inside it by derefing\n  "],"~$insert-nth",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_com/util.cljs","^V",96,"^W",7,"^X",96,"^Y",17,"^Z",["^[",["^10",["^[",[["~$vect","~$index","~$item"]]]]]],"^C","~$re-com.util/insert-nth","^14",false,"^U","out-cli/re_com/util.cljs","^Y",17,"^15",["^[",[["^1M","^1N","^1O"]]],"^16",null,"^17",["^[",[null,null]],"^W",1,"^V",96,"^X",96,"^18",3,"^19",true,"^Z",["^[",["^10",["^[",[["^1M","^1N","^1O"]]]]]],"~$now->utc",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_com/util.cljs","^V",157,"^W",7,"^X",157,"^Y",15,"^Z",["^[",["^10",["^[",[[]]]]],"^12","Answer a goog.date.UtcDateTime based on local date/time."],"^C","~$re-com.util/now->utc","^14",false,"^U","out-cli/re_com/util.cljs","^Y",15,"^15",["^[",[[]]],"^16",null,"^17",["^[",[null,null]],"^W",1,"^V",157,"^X",157,"^18",0,"^19",true,"^Z",["^[",["^10",["^[",[[]]]]],"^12","Answer a goog.date.UtcDateTime based on local date/time."],"~$deep-merge",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_com/util.cljs","^V",14,"^W",7,"^X",14,"^Y",17,"^Z",["^[",["^10",["^[",[["~$&","~$vals"]]]]],"^12","Recursively merges maps. If vals are not maps, the last value wins.","^1@",["^ ","^14",true,"^18",0,"^15",[["^[",["^1T"]]],"^Z",["^[",[["~$&","^1T"]]],"^17",["^[",[null]]]],"^C","~$re-com.util/deep-merge","^14",true,"^U","out-cli/re_com/util.cljs","^Y",17,"^1@",["^ ","^14",true,"^18",0,"^15",[["^[",["^1T"]]],"^Z",["^[",[["~$&","^1T"]]],"^17",["^[",[null]]],"^15",[["^[",["^1T"]]],"^16",null,"^17",["^[",[null]],"^W",1,"^V",14,"^X",14,"^18",0,"^19",true,"^Z",["^[",[["~$&","^1T"]]],"^12","Recursively merges maps. If vals are not maps, the last value wins."],"~$deref-or-value-peek",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_com/util.cljs","^V",33,"^W",7,"^X",33,"^Y",26,"^Z",["^[",["^10",["^[",[["^1J"]]]]],"^12","Takes a value or an atom\n  If it's a value, returns it\n  If it's a Reagent object that supports IDeref, returns the value inside it, but WITHOUT derefing\n\n  The arg validation code uses this, since calling deref-or-value adds this arg to the watched ratom list for the component\n  in question, which in turn can cause different rendering behaviour between dev (where we validate) and prod (where we don't).\n\n  This was experienced in popover-content-wrapper with the position-injected atom which was not derefed there, however\n  the dev-only validation caused it to be derefed, modifying its render behaviour and causing mayhem and madness for the developer.\n\n  See below that different Reagent types have different ways of retrieving the value without causing capture, although in the case of\n  Track, we just deref it as there is no peek or state, so hopefully this won't cause issues (surely this is used very rarely).\n  "],"^C","~$re-com.util/deref-or-value-peek","^14",false,"^U","out-cli/re_com/util.cljs","^Y",26,"^15",["^[",[["^1J"]]],"^16",null,"^17",["^[",[null,null]],"^W",1,"^V",33,"^X",33,"^18",1,"^19",true,"^Z",["^[",["^10",["^[",[["^1J"]]]]],"^12","Takes a value or an atom\n  If it's a value, returns it\n  If it's a Reagent object that supports IDeref, returns the value inside it, but WITHOUT derefing\n\n  The arg validation code uses this, since calling deref-or-value adds this arg to the watched ratom list for the component\n  in question, which in turn can cause different rendering behaviour between dev (where we validate) and prod (where we don't).\n\n  This was experienced in popover-content-wrapper with the position-injected atom which was not derefed there, however\n  the dev-only validation caused it to be derefed, modifying its render behaviour and causing mayhem and madness for the developer.\n\n  See below that different Reagent types have different ways of retrieving the value without causing capture, although in the case of\n  Track, we just deref it as there is no peek or state, so hopefully this won't cause issues (surely this is used very rarely).\n  "],"~$pad-zero",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_com/util.cljs","^V",64,"^W",7,"^X",64,"^Y",15,"^Z",["^[",["^10",["^[",[["~$s","~$len"]]]]],"^12","Left pad a string 's' with '0', until 's' has length 'len'. Return 's' unchanged, if it is already len or greater"],"^C","~$re-com.util/pad-zero","^14",false,"^U","out-cli/re_com/util.cljs","^Y",15,"^15",["^[",[["~$s","^1Y"]]],"^16",null,"^17",["^[",[null,null]],"^W",1,"^V",64,"^X",64,"^18",2,"^19",true,"^Z",["^[",["^10",["^[",[["~$s","^1Y"]]]]],"^12","Left pad a string 's' with '0', until 's' has length 'len'. Return 's' unchanged, if it is already len or greater"],"~$get-element-by-id",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_com/util.cljs","^V",59,"^W",7,"^X",59,"^Y",24,"^Z",["^[",["^10",["^[",[["^1;"]]]]]],"^C","~$re-com.util/get-element-by-id","^14",false,"^U","out-cli/re_com/util.cljs","^Y",24,"^15",["^[",[["^1;"]]],"^16",null,"^17",["^[",[null,null]],"^W",1,"^V",59,"^X",59,"^18",1,"^19",true,"^Z",["^[",["^10",["^[",[["^1;"]]]]]],"~$px",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_com/util.cljs","^V",78,"^W",7,"^X",78,"^Y",9,"^Z",["^[",["^10",["^[",[["~$val","~$&","~$negative"]]]]],"^12","takes a number (and optional :negative keyword to indicate a negative value) and returns that number as a string with 'px' at the end","^1@",["^ ","^14",true,"^18",1,"^15",[["^[",["^22","^23"]]],"^Z",["^[",[["^22","~$&","^23"]]],"^17",["^[",[null]]]],"^C","~$re-com.util/px","^14",true,"^U","out-cli/re_com/util.cljs","^Y",9,"^1@",["^ ","^14",true,"^18",1,"^15",[["^[",["^22","^23"]]],"^Z",["^[",[["^22","~$&","^23"]]],"^17",["^[",[null]]],"^15",[["^[",["^22","^23"]]],"^16",null,"^17",["^[",[null]],"^W",1,"^V",78,"^X",78,"^18",1,"^19",true,"^Z",["^[",[["^22","~$&","^23"]]],"^12","takes a number (and optional :negative keyword to indicate a negative value) and returns that number as a string with 'px' at the end"],"~$item-for-id",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_com/util.cljs","^V",114,"^W",7,"^X",114,"^Y",18,"^Z",["^[",["^10",["^[",[["^1;","~$v","~$&",["^ ","^1<",["^1="],"^1>",["^ ","^1=","^1?"]]]]]]],"^12","Takes a vector of maps 'v'. Returns the first item in 'v' whose id-fn (default :id) matches 'id'.\n   Returns nil if id not found","^1@",["^ ","^14",true,"^18",2,"^15",[["^[",["^1;","~$v",["^ ","^1<",["^1="],"^1>",["^ ","^1=","^1?"]]]]],"^Z",["^[",[["^1;","~$v","~$&",["^ ","^1<",["^1="],"^1>",["^ ","^1=","^1?"]]]]],"^17",["^[",[null]]]],"^C","~$re-com.util/item-for-id","^14",true,"^U","out-cli/re_com/util.cljs","^Y",18,"^1@",["^ ","^14",true,"^18",2,"^15",[["^[",["^1;","~$v",["^ ","^1<",["^1="],"^1>",["^ ","^1=","^1?"]]]]],"^Z",["^[",[["^1;","~$v","~$&",["^ ","^1<",["^1="],"^1>",["^ ","^1=","^1?"]]]]],"^17",["^[",[null]]],"^15",[["^[",["^1;","~$v",["^ ","^1<",["^1="],"^1>",["^ ","^1=","^1?"]]]]],"^16",null,"^17",["^[",[null]],"^W",1,"^V",114,"^X",114,"^18",2,"^19",true,"^Z",["^[",[["^1;","~$v","~$&",["^ ","^1<",["^1="],"^1>",["^ ","^1=","^1?"]]]]],"^12","Takes a vector of maps 'v'. Returns the first item in 'v' whose id-fn (default :id) matches 'id'.\n   Returns nil if id not found"],"~$fmap",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_com/util.cljs","^V",8,"^W",7,"^X",8,"^Y",11,"^Z",["^[",["^10",["^[",[["~$f","~$m"]]]]],"^12","Takes a function 'f' amd a map 'm'.  Applies 'f' to each value in 'm' and returns.\n   (fmap  inc  {:a 4  :b 2})   =>   {:a 5  :b 3}"],"^C","~$re-com.util/fmap","^14",false,"^U","out-cli/re_com/util.cljs","^Y",11,"^15",["^[",[["~$f","~$m"]]],"^16",null,"^17",["^[",[null,null]],"^W",1,"^V",8,"^X",8,"^18",2,"^19",true,"^Z",["^[",["^10",["^[",[["~$f","~$m"]]]]],"^12","Takes a function 'f' amd a map 'm'.  Applies 'f' to each value in 'm' and returns.\n   (fmap  inc  {:a 4  :b 2})   =>   {:a 5  :b 3}"],"~$pad-zero-number",["^ ","^S",null,"^T",["^ ","^U","/Users/jmmk/Dropbox/clojure/javascript-externs-generator/out-cli/re_com/util.cljs","^V",72,"^W",7,"^X",72,"^Y",22,"^Z",["^[",["^10",["^[",[["~$num","^1Y"]]]]],"^12","return 'num' as a string of 'len' characters, left padding with '0' as necessary"],"^C","~$re-com.util/pad-zero-number","^14",false,"^U","out-cli/re_com/util.cljs","^Y",22,"^15",["^[",[["^2:","^1Y"]]],"^16",null,"^17",["^[",[null,null]],"^W",1,"^V",72,"^X",72,"^18",2,"^19",true,"^Z",["^[",["^10",["^[",[["^2:","^1Y"]]]]],"^12","return 'num' as a string of 'len' characters, left padding with '0' as necessary"]],"~:cljs.spec/registry-ref",[],"~:require-macros",["^ ","^G","^G"],"~:cljs.analyzer/constants",["^ ","~:seen",["^B",["~:else","~:top","~:id-fn","^1?","~:left"]],"~:order",["^2@","^2B","^1?","^2C","^2A"]],"^12",null]