Skip to content

Commit d7d2303

Browse files
committed
improved ui layout
1 parent 13d310a commit d7d2303

File tree

3 files changed

+32
-31
lines changed

3 files changed

+32
-31
lines changed

annotation-tool/src/App/Tabs/Export.purs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ exportComponent =
6060

6161
tikzStrOrErr = Right $ tikzReduction tikzStandalone $ evalGraph true true model.reduction
6262
in
63-
HH.div [ class_ "content-np tab" ]
63+
HH.div [ class_ "content-np tab pure-form" ]
6464
[ if validationIsOk val then
6565
HH.text ""
6666
else
@@ -70,14 +70,14 @@ exportComponent =
7070
Right jsonStr ->
7171
HH.div_
7272
[ HH.div [ class_ "pure-g" ]
73-
[ HH.div [ class_ "pure-u-3-5" ]
73+
[ HH.label [ class_ "pure-u-3-5" ]
7474
[ HH.input
7575
[ HP.type_ $ HP.InputCheckbox
7676
, HP.checked pretty
7777
, HE.onChange \_ -> TogglePretty
7878
, HP.id "prettyJSON"
7979
]
80-
, HH.label [ HP.for "prettyJSON" ] [ HH.text " pretty" ]
80+
, HH.text " pretty"
8181
]
8282
, HH.button
8383
[ class_ "pure-button pure-u-1-5"
@@ -122,14 +122,14 @@ exportComponent =
122122
Right tikzStr ->
123123
HH.div_
124124
[ HH.div [ class_ "pure-g" ]
125-
[ HH.div [ class_ "pure-u-3-5" ]
125+
[ HH.label [ class_ "pure-u-3-5" ]
126126
[ HH.input
127127
[ HP.type_ $ HP.InputCheckbox
128128
, HP.checked tikzStandalone
129129
, HE.onChange \_ -> ToggleTikzStandalone
130130
, HP.id "tikzStandalone"
131131
]
132-
, HH.label [ HP.for "prettyJSON" ] [ HH.text " standalone document" ]
132+
, HH.text " standalone document"
133133
]
134134
, HH.button
135135
[ class_ "pure-button pure-u-1-5"

annotation-tool/src/App/Tabs/SVG.purs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -68,17 +68,17 @@ svgComponent = H.mkComponent
6868
render :: SVGState -> _
6969
render { modelInfo, settings, showSurface } = HH.div_
7070
[ HH.div [ class_ "content-np tab pure-form pure-g" ]
71-
[ HH.div [ class_ "pure-u-4-5" ]
71+
[ HH.label [ class_ "pure-u-4-5" ]
7272
[ HH.input
7373
[ HP.type_ $ HP.InputCheckbox
7474
, HP.checked showSurface
7575
, HE.onChange \_ -> SVGToggleSurface
7676
, HP.id "showSurface"
7777
]
78-
, HH.label [ HP.for "showSurface" ] [ HH.text " show full surface below graph" ]
78+
, HH.text " show full surface below graph"
7979
]
8080
, HH.button
81-
[ class_ "pure-button pure-button-primary pure-u-1-5"
81+
[ class_ "pure-button pure-button-primary pure-u-1-5 center"
8282
, HE.onClick \_ -> SVGDownload
8383
]
8484
[ HH.text "Download" ]

annotation-tool/src/App/Tabs/Settings.purs

Lines changed: 24 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -27,32 +27,33 @@ settingsComponent = H.mkComponent { initialState, render, eval: H.mkEval H.defau
2727

2828
render { settings } =
2929
HH.div [ class_ "content-np tab pure-form" ]
30-
[ HH.p_
31-
[ HH.input
32-
[ HP.type_ $ HP.InputCheckbox
33-
, HP.checked settings.flatHori
34-
, HE.onChange \_ -> SettingsToggleFlatHori
35-
, HP.id "flatHori"
30+
[ HH.div [ class_ "pure-g" ]
31+
[ HH.label [ class_ "pure-u-1-5" ]
32+
[ HH.input
33+
[ HP.type_ $ HP.InputCheckbox
34+
, HP.checked settings.flatHori
35+
, HE.onChange \_ -> SettingsToggleFlatHori
36+
]
37+
, HH.text " render horis flat"
3638
]
37-
, HH.label [ HP.for "flatHori" ] [ HH.text " render horis flat" ]
38-
]
39-
, HH.p_
40-
[ HH.input
41-
[ HP.type_ $ HP.InputCheckbox
42-
, HP.checked settings.showAllEdges
43-
, HE.onChange \_ -> SettingsToggleShowAllEdges
44-
, HP.id "showAllEdges"
39+
40+
, HH.label [ class_ "pure-u-1-5" ]
41+
[ HH.input
42+
[ HP.type_ $ HP.InputCheckbox
43+
, HP.checked settings.showAllEdges
44+
, HE.onChange \_ -> SettingsToggleShowAllEdges
45+
]
46+
, HH.text " show all edges"
4547
]
46-
, HH.label [ HP.for "showAllEdges" ] [ HH.text " show all edges" ]
47-
]
48-
, HH.p_
49-
[ HH.input
50-
[ HP.type_ $ HP.InputCheckbox
51-
, HP.checked settings.showScore
52-
, HE.onChange \_ -> SettingsToggleShowScore
53-
, HP.id "showScore"
48+
49+
, HH.label [ class_ "pure-u-1-5" ]
50+
[ HH.input
51+
[ HP.type_ $ HP.InputCheckbox
52+
, HP.checked settings.showScore
53+
, HE.onChange \_ -> SettingsToggleShowScore
54+
]
55+
, HH.text " show score"
5456
]
55-
, HH.label [ HP.for "showScore" ] [ HH.text " show score" ]
5657
]
5758
, HH.p [ class_ "pure-g" ]
5859
[ HH.label [ class_ "pure-u-1-5", HP.for "xscale" ] [ HH.text $ "horizontal zoom: " <> show settings.xscale ]

0 commit comments

Comments
 (0)