mirror of
https://github.com/status-im/re-frame-10x.git
synced 2025-02-04 10:23:39 +00:00
Add toggle arrow indicators next to expandable objects
This commit is contained in:
parent
5a832abab4
commit
ea2f3d6dab
@ -460,6 +460,10 @@
|
||||
color: #8f8f8f;
|
||||
content: "▶ ";
|
||||
}
|
||||
#--re-frame-trace-- .re-frame-trace--object.expanded:before {
|
||||
color: #8f8f8f;
|
||||
content: "▼ ";
|
||||
}
|
||||
#--re-frame-trace-- .re-frame-trace--object > span {
|
||||
vertical-align: text-top;
|
||||
}
|
||||
|
@ -579,7 +579,12 @@
|
||||
color: @text-color-muted;
|
||||
content: "▶ ";
|
||||
}
|
||||
// display: block;
|
||||
&.expanded {
|
||||
&:before {
|
||||
color: @text-color-muted;
|
||||
content: "▼ ";
|
||||
}
|
||||
}
|
||||
|
||||
&>span {
|
||||
vertical-align: text-top;
|
||||
|
@ -23,8 +23,10 @@
|
||||
[jsonml]
|
||||
(let [expand? (r/atom true)]
|
||||
(fn []
|
||||
[:span.re-frame-trace--object
|
||||
{:on-click #(swap! expand? not)}
|
||||
[:span
|
||||
{:class (str/join " " ["re-frame-trace--object"
|
||||
(when @expand? "expanded")])
|
||||
:on-click #(swap! expand? not)}
|
||||
(jsonml->hiccup (if @expand?
|
||||
(cljs-devtools/body-api-call
|
||||
(.-object (get jsonml 1))
|
||||
|
Loading…
x
Reference in New Issue
Block a user