Commit 23bc6190 authored by Karen Konou's avatar Karen Konou

[Graph] Show graph parameters in legend

parent c405a828
Pipeline #7549 passed with stages
in 22 minutes and 11 seconds
......@@ -9750,6 +9750,20 @@ input[type=range]:-moz-focusring {
margin-right: 8px;
border: 1px solid #ADB5BD;
}
.graph-legend__separator {
fill: #B5B5B5;
}
.graph-legend__params {
margin: 16px;
}
.graph-legend__params__heading {
font-weight: bold;
list-style: none;
}
.graph-legend__params__item {
list-style: initial;
margin-left: 16px;
}
.graph-legend .renameable-container__text {
margin-right: 8px;
......
......@@ -9558,6 +9558,20 @@ input[type=range]:-moz-focusring {
margin-right: 8px;
border: 1px solid #ADB5BD;
}
.graph-legend__separator {
fill: #B5B5B5;
}
.graph-legend__params {
margin: 16px;
}
.graph-legend__params__heading {
font-weight: bold;
list-style: none;
}
.graph-legend__params__item {
list-style: initial;
margin-left: 16px;
}
.graph-legend .renameable-container__text {
margin-right: 8px;
......
......@@ -9401,6 +9401,20 @@ input[type=range]:-moz-focusring {
margin-right: 8px;
border: 1px solid #ADB5BD;
}
.graph-legend__separator {
fill: #B5B5B5;
}
.graph-legend__params {
margin: 16px;
}
.graph-legend__params__heading {
font-weight: bold;
list-style: none;
}
.graph-legend__params__item {
list-style: initial;
margin-left: 16px;
}
.graph-legend .renameable-container__text {
margin-right: 8px;
......
......@@ -9626,6 +9626,20 @@ input[type=range]:-moz-focusring {
margin-right: 8px;
border: 1px solid #ADB5BD;
}
.graph-legend__separator {
fill: #B5B5B5;
}
.graph-legend__params {
margin: 16px;
}
.graph-legend__params__heading {
font-weight: bold;
list-style: none;
}
.graph-legend__params__item {
list-style: initial;
margin-left: 16px;
}
.graph-legend .renameable-container__text {
margin-right: 8px;
......
......@@ -9699,6 +9699,20 @@ input[type=range]:-moz-focusring {
margin-right: 8px;
border: 1px solid #ADB5BD;
}
.graph-legend__separator {
fill: #B5B5B5;
}
.graph-legend__params {
margin: 16px;
}
.graph-legend__params__heading {
font-weight: bold;
list-style: none;
}
.graph-legend__params__item {
list-style: initial;
margin-left: 16px;
}
.graph-legend .renameable-container__text {
margin-right: 8px;
......
......@@ -122,7 +122,7 @@ sideTabLegend = R2.leaf sideTabLegendCpt
sideTabLegendCpt :: R.Component Props
sideTabLegendCpt = here.component "sideTabLegend" cpt
where
cpt { metaData: GET.MetaData { legend }, session, graphId } _ = do
cpt { metaData: m@(GET.MetaData { legend }), session, graphId } _ = do
-- | States
-- |
store <- GraphStore.use
......@@ -160,6 +160,7 @@ sideTabLegendCpt = here.component "sideTabLegend" cpt
, selectedNodeIds: store.selectedNodeIds
, session
, graphId
, metaData: m
}
]
......
......@@ -37,6 +37,7 @@ type Props =
, selectedNodeIds :: T.Box ST.NodeIds
, session :: Session
, graphId :: GET.GraphId
, metaData :: GET.MetaData
)
legend :: R2.Leaf Props
......@@ -52,6 +53,7 @@ legendCpt = here.component "legend" cpt
, selectedNodeIds
, session
, graphId
, metaData: GET.MetaData m
}
_ = do
-- | Hooks
......@@ -84,6 +86,40 @@ legendCpt = here.component "legend" cpt
]
]
]
, H.hr
{ className: "graph-legend__separator" }
-- Graph params
, H.ul
{ className: "graph-legend__params" }
[ H.li
{ className: "graph-legend__params__heading" }
[ H.text "Graph parameters:"
]
, H.li
{ className: "graph-legend__params__item" }
[ H.text $ "Version: " <> show m.list.version
]
, H.li
{ className: "graph-legend__params__item" }
[ H.text $ "Metric: " <> show m.metric
]
, H.li
{ className: "graph-legend__params__item" }
[ H.text $ "Start Force Atlas: " <> show m.startForceAtlas
]
, H.li
{ className: "graph-legend__params__item" }
[ H.text $ "Edges Strength: " <> maybe "null" show m.edgesStrength
]
-- , H.li
-- { className: "graph-legend__params__item" }
-- [ H.text $ "PartitionMethod: " <> maybe "null" show m.partitionMethod
-- ]
, H.li
{ className: "graph-legend__params__item" }
[ H.text $ "Bridgeness Method: " <> maybe "null" show m.bridgenessMethod
]
]
]
where
rename :: String -> Int -> String -> Effect Unit
......
......@@ -229,6 +229,24 @@
margin-right: space-x(1);
border: 1px solid $gray-500;
}
&__separator {
fill: #B5B5B5;
}
&__params {
margin: space-x(2);
&__heading {
font-weight: bold;
list-style: none;
}
&__item {
list-style: initial;
margin-left: space-x(2)
}
}
}
.graph-legend .renameable-container__text {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment