This repository has been archived by the owner on Jan 24, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstack-sepal.ir
1 lines (1 loc) · 5.79 KB
/
stack-sepal.ir
1
{:definitions {"component.task/style-task" ["def" "style-task" ["{}"]], "main/dispatch!" ["defn" "dispatch!" ["op" "op-data"] ["send!" "op" "op-data"]], "component.todolist/handle-add" ["defn" "handle-add" ["state" "mutate"] ["fn" ["e" "dispatch"] ["dispatch" ":task/add" "state"] ["mutate" "|"]]], "main/on-jsload!" ["defn" "on-jsload!" [] ["clear-cache!"] ["render-app!"] ["println" "|code updated."]], "main/render-app!" ["defn" "render-app!" [] ["let" [["target" [".querySelector" "js/document" "|#app"]]] ["render!" ["comp-container" "@store-ref"] "target" "dispatch!" "states-ref"]]], "component.todolist/style-input" ["def" "style-input" ["{}" [":border" "|none"] [":outline" "|none"] [":font-size" "|14px"] [":font-family" "|Verdana"] [":padding" "|0 8px"]]], "main/-main" ["defn" "-main" [] ["enable-console-print!"] ["render-app!"] ["setup-socket!" "store-ref" ["{}" ":url" "|ws://localhost:4010"]] ["add-watch" "store-ref" ":changes" "render-app!"] ["add-watch" "states-ref" ":changes" "render-app!"] ["println" "|app started!"]], "component.container/render" ["defn" "render" ["store"] ["fn" ["state" "mutate"] ["div" ["{}"] ["comp-todolist" [":tasks" "store"]]]]], "core/receiver" ["defonce" "receiver" ["chan"]], "core/sender" ["defonce" "sender" ["chan"]], "component.task/render" ["defn" "render" ["task"] ["fn" ["state" "mutate"] ["div" ["{}" [":style" "style-task"]] ["text" [":text" "task"]] ["div" ["{}" [":style" "style-rm"] [":event" ["{}" ":click" ["handle-rm" [":id" "task"]]]]] ["text" "|rm"]] ["--" "comp-debug" "task" ["{}"]]]]], "component.todolist/comp-todolist" ["def" "comp-todolist" ["create-comp" ":todolist" "init-state" "update-state" "render"]], "component.todolist/update-state" ["defn" "update-state" ["state" "new-text"] "new-text"], "component.task/handle-rm" ["defn" "handle-rm" ["task-id"] ["fn" ["e" "dispatch"] ["dispatch" ":task/rm" "task-id"]]], "component.todolist/style-button" ["def" "style-button" ["{}" [":display" "|inline-block"] [":background-color" ["hsl" "200" "80" "50"]] [":line-height" "2"] [":color" ["hsl" "0" "0" "100"]] [":padding" "|0 8px"]]], "component.todolist/render" ["defn" "render" ["tasks"] ["fn" ["state" "mutate"] ["div" ["{}"] ["div" ["{}"] ["input" ["{}" [":style" "style-input"] [":attrs" ["{}" [":value" "state"]]] [":event" ["{}" [":input" ["handle-input" "mutate"]]]]]] ["div" ["{}" [":style" "style-button"] [":event" ["{}" [":click" ["handle-add" "state" "mutate"]]]]] ["text" "|Add"]]] ["div" ["{}"] ["->>" "tasks" ["map" ["fn" ["entry"] ["[]" ["key" "entry"] ["comp-task" ["val" "entry"]]]]] ["into" ["sorted-map"]]]]]]], "main/store-ref" ["defonce" "store-ref" ["atom" ["{}"]]], "component.todolist/init-state" ["defn" "init-state" ["tasks"] "|"], "core/send!" ["defn" "send!" ["op" "op-data"] ["go" [">!" "sender" ["[]" "op" "op-data"]]]], "component.task/style-rm" ["def" "style-rm" ["{}" [":display" "|inline-block"] [":font-size" "|12px"] [":color" ["hsl" "0" "0" "100"]] [":padding" "|0 4px"] [":background-color" ["hsl" "0" "80" "60"]]]], "util.text/text" ["defn" "text" ["x"] ["span" ["{}" [":attrs" ["{}" ":inner-text" "x"]]]]], "main/states-ref" ["defonce" "states-ref" ["atom" ["{}"]]], "component.todolist/handle-input" ["defn" "handle-input" ["mutate"] ["fn" ["e" "dispatch"] ["mutate" [":value" "e"]]]], "component.container/comp-container" ["def" "comp-container" ["create-comp" ":container" "render"]], "core/setup-socket!" ["defn" "setup-socket!" ["store-ref" "configs"] ["let" [["ws-url" [":url" "configs"]] ["ws" ["js/WebSocket." "ws-url"]] ["handle-close!" ["if" ["fn?" [":on-close!" "configs"]] [":on-close!" "configs"] "identity"]] ["handle-open!" ["if" ["fn?" [":on-open!" "configs"]] [":on-open!" "configs"] "identity"]]] ["set!" "ws.onopen" ["fn" ["event"] ["handle-open!" "event"]]] ["set!" "ws.onclose" ["fn" ["event"] ["handle-close!" "event"]]] ["set!" "ws.onmessage" ["fn" ["event"] ["let" [["changes" ["reader/read-string" "event.data"]]] ["reset!" "store-ref" ["patch" "@store-ref" "changes"]]]]] ["go" ["loop" ["[]"] [".send" "ws" ["pr-str" ["<!" "sender"]]] ["recur"]]]]], "component.task/comp-task" ["def" "comp-task" ["create-comp" ":task" "render"]]}, :namespaces {"component.container" ["ns" "cumulo-client.component.container" [":require" ["[]" "hsl.core" ":refer" ["[]" "hsl"]] ["[]" "respo.alias" ":refer" ["[]" "create-comp" "div" "span"]] ["[]" "cumulo-client.component.todolist" ":refer" ["[]" "comp-todolist"]]]], "component.task" ["ns" "cumulo-client.component.task" [":require" ["[]" "hsl.core" ":refer" ["[]" "hsl"]] ["[]" "respo.alias" ":refer" ["[]" "create-comp" "div" "span"]] ["[]" "respo.component.debug" ":refer" ["[]" "comp-debug"]] ["[]" "cumulo-client.util.text" ":refer" ["[]" "text"]]]], "component.todolist" ["ns" "cumulo-client.component.todolist" [":require" ["[]" "respo.alias" ":refer" ["[]" "create-comp" "div" "input" "span"]] ["[]" "respo.component.debug" ":refer" ["[]" "comp-debug"]] ["[]" "cumulo-client.component.task" ":refer" ["[]" "comp-task"]] ["[]" "cumulo-client.util.text" ":refer" ["[]" "text"]] ["[]" "hsl.core" ":refer" ["[]" "hsl"]]]], "core" ["ns" "cumulo-client.core" [":require-macros" ["[]" "cljs.core.async.macros" ":refer" ["[]" "go"]]] [":require" ["[]" "cljs.reader" ":as" "reader"] ["[]" "cljs.core.async" ":as" "a" ":refer" ["[]" ">!" "<!" "chan" "timeout"]] ["[]" "shallow-diff.patch" ":refer" ["[]" "patch"]]]], "main" ["ns" "cumulo-client.main" [":require" ["[]" "respo.core" ":refer" ["[]" "render!" "clear-cache!"]] ["[]" "cumulo-client.component.container" ":refer" ["[]" "comp-container"]] ["[]" "cumulo-client.core" ":refer" ["[]" "send!" "setup-socket!"]]]], "util.text" ["ns" "cumulo-client.util.text" [":require" ["[]" "respo.alias" ":refer" ["[]" "span"]]]]}, :procedures {"component.container" [], "component.task" [], "component.todolist" [], "core" [], "main" [["set!" "js/window.onload" "-main"]], "util.text" []}, :package "cumulo-client"}