Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
purescript-gargantext
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
142
Issues
142
List
Board
Labels
Milestones
Merge Requests
5
Merge Requests
5
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gargantext
purescript-gargantext
Commits
13fdc40a
Commit
13fdc40a
authored
Nov 01, 2019
by
Alexandre Delanoë
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[FOREST][DESIGN] Icons/Box.
parent
5874a9d6
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
59 additions
and
36 deletions
+59
-36
Forest.purs
src/Gargantext/Components/Forest.purs
+1
-1
Rename.purs
...Gargantext/Components/Forest/Tree/Node/Action/Rename.purs
+4
-2
Box.purs
src/Gargantext/Components/Forest/Tree/Node/Box.purs
+10
-27
Document.purs
src/Gargantext/Components/Nodes/Corpus/Document.purs
+2
-1
Types.purs
src/Gargantext/Components/Search/Types.purs
+4
-4
Types.purs
src/Gargantext/Types.purs
+36
-0
index.html
src/index.html
+2
-1
No files found.
src/Gargantext/Components/Forest.purs
View file @
13fdc40a
...
...
@@ -35,7 +35,7 @@ plus :: R2.Setter Boolean -> R.Element
plus showLogin =
H.button {on: {click}}
[ H.div { "type": ""
, className: "fa fa-plus-circle fa-
2x
"
, className: "fa fa-plus-circle fa-
lg
"
--, className: "glyphicon glyphicon-plus"
} [H.text "Login"] ]
-- TODO same as the one in the Login Modal (same CSS)
...
...
src/Gargantext/Components/Forest/Tree/Node/Action/Rename.purs
View file @
13fdc40a
...
...
@@ -5,6 +5,7 @@ import Effect.Aff (Aff, launchAff, runAff)
import Effect.Uncurried (mkEffectFn1)
import FFI.Simple ((..))
import Gargantext.Components.Forest.Tree.Node.Action
import Gargantext.Types (NodeType(..))
import Prelude hiding (div)
import Reactix as R
import Reactix.DOM.HTML as H
...
...
@@ -12,13 +13,14 @@ import Reactix.DOM.HTML as H
-- | START Rename Box
type RenameBoxProps =
( id :: ID
, name :: Name)
, name :: Name
, nodeType :: NodeType)
renameBox :: (Action -> Aff Unit) -> Record RenameBoxProps -> R.State Boolean -> R.Element
renameBox d p (true /\ setRenameBoxOpen) = R.createElement el p []
where
el = R.hooksComponent "RenameBox" cpt
cpt {id, name} _ = do
cpt {id, name
, nodeType
} _ = do
renameNodeName <- R.useState' name
pure $ H.div {className: "from-group row-no-padding"}
[ renameInput renameNodeName
...
...
src/Gargantext/Components/Forest/Tree/Node/Box.purs
View file @
13fdc40a
...
...
@@ -20,7 +20,7 @@ import Gargantext.Ends (Frontends, url)
import Gargantext.Routes (AppRoute, SessionRoute(..))
import Gargantext.Routes as Routes
import Gargantext.Sessions (Session, sessionId, get, put, post, postWwwUrlencoded, delete)
import Gargantext.Types (class ToQuery, toQuery, NodeType(..), NodePath(..), readNodeType)
import Gargantext.Types (class ToQuery, toQuery, NodeType(..), NodePath(..), readNodeType
, fldr
)
import Gargantext.Utils (id, glyphicon, glyphiconActive)
import Gargantext.Utils.Reactix as R2
import Partial.Unsafe (unsafePartial)
...
...
@@ -125,30 +125,6 @@ nodeMainSpan d p folderOpen session frontends = R.createElement el p []
setIsDragOver $ const true
onDragLeave (_ /\ setIsDragOver) _ = setIsDragOver $ const false
fldr :: NodeType -> Boolean -> String
fldr NodeUser false = "fa fa-user-circle"
fldr NodeUser true = "fa fa-user-circle-o"
fldr FolderPrivate true = "fa fa-lock"
fldr FolderPrivate false = "fa fa-expeditedssl"
fldr FolderShared true = "fa fa-users" -- "fa fa-share-alt"
fldr FolderShared false = "fa fa-share-alt-square"
fldr FolderPublic _ = "fa fa-globe"
fldr Corpus true = "fa fa-sun-o" -- "fa fa-snowflake-o"
fldr Corpus false = "fa fa-sun" -- "fa fa-snowflake-o"
fldr Graph _ = "fa fa-hubzilla"
fldr Texts _ = "fa fa-newspaper-o"
fldr Dashboard _ = "fa fa-signal"
fldr NodeList _ = "fa fa-list"
fldr _ false = "fa fa-folder"
fldr _ true = "fa fa-folder-o"
{-
fldr nt open = if open
then "fa fa-globe" -- <> color nt
...
...
@@ -213,7 +189,13 @@ nodePopupView d p mPop@(Just NodePopup /\ setPopupOpen) = R.createElement el p [
, boxShadow : "0 2px 5px rgba(0,0,0,0.2)"
}
}
[ panelHeading renameBoxOpen
[ H.div {className: ""}
[ H.div { className : "col-md-11"}
[ H.h3 { className: fldr nodeType true}
[ H.text $ show nodeType]
]
]
, panelHeading renameBoxOpen
, panelBody nodePopupState d
, if isJust nodePopup.action
then H.div { className: glyphicon "remove-circle"
...
...
@@ -237,7 +219,8 @@ nodePopupView d p mPop@(Just NodePopup /\ setPopupOpen) = R.createElement el p [
H.div {className: "panel-heading"}
[ -- H.h1 {className : "col-md-12"} [H.text "Settings Box"]
H.div {className: "row" }
[ H.div {className: "col-md-8"} [ renameBox d {id, name} renameBoxOpen ]
[
H.div {className: "col-md-8"} [ renameBox d {id, name, nodeType} renameBoxOpen ]
, if edit then editIcon renameBoxOpen else H.div {} []
, H.div {className: "col-md-1"}
[ H.a { "type" : "button"
...
...
src/Gargantext/Components/Nodes/Corpus/Document.purs
View file @
13fdc40a
...
...
@@ -347,7 +347,8 @@ docViewSpec = simpleSpec performAction render
docViewClass :: ReactClass { children :: Children
, loaded :: LoadedData
, path :: DocPath }
, path :: DocPath
}
docViewClass = createClass "DocumentView" docViewSpec initialState
type LayoutProps = ( session :: Session, nodeId :: Int, listId :: Int, corpusId :: Maybe Int )
...
...
src/Gargantext/Components/Search/Types.purs
View file @
13fdc40a
...
...
@@ -40,15 +40,15 @@ instance showLangs :: Show Langs where
show EN = "EN"
instance showDatabase :: Show Database where
show All = "
All
"
show All = "
In Gargantext
"
show PubMed = "PubMed"
show HAL_EN = "HAL_" <> show EN
show HAL_FR = "HAL_" <> show FR
show IsTex_EN = "IsTex_" <> show EN
show IsTex_FR = "IsTex_" <> show FR
show Isidore_EN = "Isidore_" <> show EN
show Isidore_FR = "Isidore_" <> show FR
...
...
src/Gargantext/Types.purs
View file @
13fdc40a
...
...
@@ -189,6 +189,42 @@ readNodeType "Team" = Team
readNodeType "NodeList" = NodeList
readNodeType "NodeTexts" = Texts
readNodeType _ = Error
fldr :: NodeType -> Boolean -> String
fldr NodeUser false = "fa fa-user-circle"
fldr NodeUser true = "fa fa-user-circle-o"
fldr FolderPrivate true = "fa fa-lock"
fldr FolderPrivate false = "fa fa-expeditedssl"
fldr FolderShared true = "fa fa-users" -- "fa fa-share-alt"
fldr FolderShared false = "fa fa-share-alt-square"
fldr FolderPublic _ = "fa fa-globe"
fldr Corpus _ = "fa fa-book" -- "fa fa-snowflake-o"
fldr Phylo _ = "fa fa-code-fork"
fldr Graph _ = "fa fa-hubzilla"
fldr Texts _ = "fa fa-newspaper-o"
fldr Dashboard _ = "fa fa-signal"
fldr NodeList _ = "fa fa-list"
fldr Annuaire true = "fa fa-address-book-o"
fldr Annuaire false = "fa fa-address-book"
fldr NodeContact true = "fa fa-address-card-o"
fldr NodeContact false = "fa fa-address-card"
fldr _ false = "fa fa-folder"
fldr _ true = "fa fa-folder-o"
{-
------------------------------------------------------------
instance ordNodeType :: Ord NodeType where
...
...
src/index.html
View file @
13fdc40a
...
...
@@ -5,7 +5,8 @@
<title>
CNRS GarganText
</title>
<link
href=
"https://fonts.googleapis.com/icon?family=Material+Icons"
rel=
"stylesheet"
>
<!--<link href="https://use.fontawesome.com/releases/v5.0.8/styles/all.css" rel="stylesheet">-->
<link
rel=
"stylesheet"
href=
"icons/fork-awesome/css/fork-awesome.css"
>
<!--<link rel="stylesheet" href="icons/fork-awesome/css/fork-awesome.css">-->
<link
rel=
"stylesheet"
href=
"https://cdn.jsdelivr.net/npm/fork-awesome@1.1.7/css/fork-awesome.min.css"
integrity=
"sha256-gsmEoJAws/Kd3CjuOQzLie5Q3yshhvmo7YNtBG7aaEY="
crossorigin=
"anonymous"
>
<link
href=
"styles/login.min.css"
rel=
"stylesheet"
>
<link
href=
"styles/bootstrap.min.css"
rel=
"stylesheet"
>
<!-- <link href="styles/lavish-bootstrap.css" rel="stylesheet"> -->
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment