|
17 | 17 | (def ^:private help-ui-css
|
18 | 18 | (let [primary-color "#4E84E0"]
|
19 | 19 | (css/register ::css
|
20 |
| - {".list-view" |
| 20 | + {"*" {:-fx-font-size 13 :-fx-font-family "system"} |
| 21 | + ".list-view" |
21 | 22 | {:-fx-background-color :transparent
|
22 | 23 | :-fx-border-width [0 1 0 0]
|
23 | 24 | :-fx-border-color "#aaa"
|
|
71 | 72 | :-fx-fixed-cell-size 24
|
72 | 73 | ":focused > .virtual-flow > .clipped-container > .sheet > .tree-cell:focused"
|
73 | 74 | {:-fx-background-color primary-color}}
|
74 |
| - ".tree-cell" {:-fx-background-color :transparent} |
| 75 | + ".tree-cell" {:-fx-background-color :transparent |
| 76 | + :-fx-text-fill "#000"} |
75 | 77 | ".inspector" {"-backdrop" {:-fx-background-color "#ccc"
|
76 | 78 | :-fx-effect "dropshadow(gaussian, #0006, 10, 0, 0, 5)"}
|
77 | 79 | "-root" {:-fx-pref-width 300
|
|
80 | 82 | :-fx-max-height 500
|
81 | 83 | :-fx-background-color :transparent}}
|
82 | 84 | ".table" {"-view" {:-fx-background-color :transparent
|
| 85 | + :-fx-fixed-cell-size 25 |
83 | 86 | :-fx-border-color ["#aaa" :transparent :transparent :transparent]
|
84 | 87 | "> .column-header-background"
|
85 | 88 | {:-fx-background-color :transparent
|
|
91 | 94 | ":focused" {:-fx-background-color "#4E84E033"}}
|
92 | 95 | "-column" {:-fx-background-color :transparent
|
93 | 96 | :-fx-border-color [:transparent "#aaa" :transparent :transparent]
|
94 |
| - " .label" {:-fx-alignment :center-left}} |
| 97 | + " .label" {:-fx-alignment :center-left :-fx-text-fill "#000"}} |
95 | 98 | "-row-cell" {:-fx-background-color :transparent}}})))
|
96 | 99 |
|
97 | 100 | (defn- type->string [type->id fx-type]
|
|
227 | 230 | {:text (str type (when text (str " - " (pr-str text))))}))
|
228 | 231 |
|
229 | 232 | (defn on-inspector-tree-view-selection-changed [state {:keys [^TreeItem fx/event]}]
|
230 |
| - (assoc state :path (subvec (:path (.getValue event)) 1))) |
| 233 | + (if event |
| 234 | + (assoc state :path (subvec (:path (.getValue event)) 1)) |
| 235 | + (dissoc state :path))) |
231 | 236 |
|
232 | 237 | (defn- initialize-inspector-table! [^TableView table]
|
233 | 238 | (.selectFirst (.getSelectionModel table))
|
|
306 | 311 | (dispatchEvent [_ e next]
|
307 | 312 | (if (and (instance? KeyEvent e)
|
308 | 313 | (= KeyEvent/KEY_PRESSED (.getEventType e))
|
309 |
| - (= KeyCode/ESCAPE (.getCode ^KeyEvent e))) |
| 314 | + (#{KeyCode/ESCAPE KeyCode/SPACE} (.getCode ^KeyEvent e))) |
310 | 315 | e
|
311 | 316 | (.dispatchEvent dispatcher e next)))))))
|
312 | 317 |
|
|
0 commit comments