Commit bfba4654 authored by Fabien Maniere's avatar Fabien Maniere

beginning some changes on the node settings box

parent ab5ad60d
......@@ -11072,6 +11072,8 @@ select.form-control {
padding: 0.7rem 1.5rem 0.6rem;
display: list-item;
border: 1px solid transparent;
border-top-left-radius: 0.25rem;
border-top-right-radius: 0.25rem;
margin-bottom: -1px;
}
.node-popup-tooltip .popup-container__cta__button:hover, .node-popup-tooltip .popup-container__cta__button--active {
......@@ -11082,8 +11084,8 @@ select.form-control {
}
.node-popup-tooltip .popup-container__cta__icon {
position: absolute;
top: 6px;
right: 6px;
top: 8px;
right: 10px;
font-size: 11px;
}
.node-popup-tooltip .popup-container__cta--almost-useable .popup-container__cta__icon {
......
......@@ -10878,6 +10878,8 @@ select.form-control {
padding: 0.7rem 1.5rem 0.6rem;
display: list-item;
border: 1px solid transparent;
border-top-left-radius: 0.25rem;
border-top-right-radius: 0.25rem;
margin-bottom: -1px;
}
.node-popup-tooltip .popup-container__cta__button:hover, .node-popup-tooltip .popup-container__cta__button--active {
......@@ -10888,8 +10890,8 @@ select.form-control {
}
.node-popup-tooltip .popup-container__cta__icon {
position: absolute;
top: 6px;
right: 6px;
top: 8px;
right: 10px;
font-size: 11px;
}
.node-popup-tooltip .popup-container__cta--almost-useable .popup-container__cta__icon {
......
......@@ -10723,6 +10723,8 @@ select.form-control {
padding: 0.7rem 1.5rem 0.6rem;
display: list-item;
border: 1px solid transparent;
border-top-left-radius: 0.25rem;
border-top-right-radius: 0.25rem;
margin-bottom: -1px;
}
.node-popup-tooltip .popup-container__cta__button:hover, .node-popup-tooltip .popup-container__cta__button--active {
......@@ -10733,8 +10735,8 @@ select.form-control {
}
.node-popup-tooltip .popup-container__cta__icon {
position: absolute;
top: 6px;
right: 6px;
top: 8px;
right: 10px;
font-size: 11px;
}
.node-popup-tooltip .popup-container__cta--almost-useable .popup-container__cta__icon {
......
......@@ -10948,6 +10948,8 @@ select.form-control {
padding: 0.7rem 1.5rem 0.6rem;
display: list-item;
border: 1px solid transparent;
border-top-left-radius: 0.25rem;
border-top-right-radius: 0.25rem;
margin-bottom: -1px;
}
.node-popup-tooltip .popup-container__cta__button:hover, .node-popup-tooltip .popup-container__cta__button--active {
......@@ -10958,8 +10960,8 @@ select.form-control {
}
.node-popup-tooltip .popup-container__cta__icon {
position: absolute;
top: 6px;
right: 6px;
top: 8px;
right: 10px;
font-size: 11px;
}
.node-popup-tooltip .popup-container__cta--almost-useable .popup-container__cta__icon {
......
......@@ -11021,6 +11021,8 @@ select.form-control {
padding: 0.7rem 1.5rem 0.6rem;
display: list-item;
border: 1px solid transparent;
border-top-left-radius: 0.25rem;
border-top-right-radius: 0.25rem;
margin-bottom: -1px;
}
.node-popup-tooltip .popup-container__cta__button:hover, .node-popup-tooltip .popup-container__cta__button--active {
......@@ -11031,8 +11033,8 @@ select.form-control {
}
.node-popup-tooltip .popup-container__cta__icon {
position: absolute;
top: 6px;
right: 6px;
top: 8px;
right: 10px;
font-size: 11px;
}
.node-popup-tooltip .popup-container__cta--almost-useable .popup-container__cta__icon {
......
......@@ -25,16 +25,27 @@ actionDocCpt = here.component "actionDoc" cpt
cpt { nodeType } _ = do
pure $
Tools.panelNoFooter { mError: Nothing }
( [ H.div { style: { margin: "10px" } }
[ H.h3 {} [ H.text "Documentation about " ]
, H.h3 { className: GT.fldr nodeType true }
[ H.span { className: "font-family-theme mx-1" }
[ H.text $ show nodeType ]
]
]
]
<> (map (\info -> H.p {} [ H.text info ]) $ docOf nodeType)
)
([ H.div { }
[ H.h5 { className: "text-primary" } [H.text "Documentation about the current node" ]
, H.div { className: "" }
[ H.dl { className: "row" }
[
-- node type name
H.dt { className: "text-bold col-3" } [ H.text "Node type name" ]
, H.dd { className: "col-9" }
[ H.span {className: GT.fldr nodeType true} []
, H.span {className: "mx-1"} [ H.text $ show nodeType ]
]
-- node description
, H.dt { className: "text-bold col-3" } [ H.text "Description" ]
, H.dd { className: "col-9" }
[ R.fragment (map (\info -> H.p {} [ H.text info ]) $ docOf nodeType) ]
]
]
]
-- <> (map (\info -> H.p {} [ H.text info ]) $ docOf nodeType)
])
-- | TODO add documentation of all NodeType
docOf :: NodeType -> Array String
......
......@@ -309,6 +309,7 @@ fileTypeFromFileName name = do
case ext of
-- There should be more file extensions here, but I don't understand the other
-- constructors of `FileType`
"csv" -> pure TSV
"tsv" -> pure TSV
"json" -> pure JSON
_ -> Nothing
......
......@@ -74,46 +74,53 @@ nodePopupViewCpt = here.component "nodePopupView" cpt
panelHeading renameIsOpen open p@{ dispatch, id, name, nodeType } =
H.div
{ className: "popup-container__header card-header" }
[ B.wad
[ "d-flex", "align-items-center" ]
[ B.wad
[ "w-2/12" ]
[ H.span
{ className: GT.fldr nodeType true }
[] -- TODO fix names
-- ,
-- B.span' { className: "small" } $ prettyNodeType nodeType
]
, B.wad
[ "w-8/12 text-center" ]
[ if open then
textInputBox
{ boxAction: renameAction
, boxName: "Rename"
, dispatch
, id
, text: name
, isOpen: renameIsOpen
}
[]
else
B.wad'
[ "text-primary" ]
p.name
]
, B.wad
[ "w-2/12", "text-right" ]
[ editIcon renameIsOpen open
, B.wad_ [ "d-inline-block", "w-3" ]
, B.iconButton
{ callback: const $ p.closeCallback unit
, title: "Close"
, name: "times"
, elevation: Level2
}
]
]
{ className: "popup-container__header card-header" }
[
B.wad
[ "d-flex", "align-items-center" ]
[
B.wad
[ "w-2/12" ]
[
H.span
{ className: GT.fldr nodeType true} [] -- TODO fix names
-- ,
-- B.span' { className: "small" } $ prettyNodeType nodeType
]
,
B.wad
[ "w-8/12 text-center text-bold" ]
[
if open then
textInputBox
{ boxAction: renameAction
, boxName: "Rename"
, dispatch
, id
, text: name
, isOpen: renameIsOpen
} []
else
B.wad'
[ "text-primary" ]
p.name
]
,
B.wad
[ "w-2/12", "text-right" ]
[
editIcon renameIsOpen open
,
B.wad_ [ "d-inline-block", "w-3" ]
,
B.iconButton
{ callback: const $ p.closeCallback unit
, title: "Close"
, name: "times"
, elevation: Level2
}
]
]
editIcon _ true = mempty
......
......@@ -380,6 +380,8 @@ select.form-control
padding: 0.7rem 1.5rem 0.6rem
display: list-item
border: 1px solid transparent
border-top-left-radius: 0.25rem
border-top-right-radius: 0.25rem
margin-bottom: -1px
&:hover, &--active
......@@ -392,8 +394,8 @@ select.form-control
&__icon
$offset-y: 6px
$offset-x: 6px
$offset-y: 8px
$offset-x: 10px
position: absolute
top: $offset-y
......
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