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
128
Issues
128
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
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
fe89cd5f
Commit
fe89cd5f
authored
Sep 17, 2020
by
Przemyslaw Kaminski
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev' into dev-doc-annotation-issue
parents
f1619d14
0ba22a14
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
84 additions
and
5 deletions
+84
-5
Styles.css
dist/styles/Styles.css
+14
-0
Styles.sass
dist/styles/Styles.sass
+10
-0
App.purs
src/Gargantext/Components/App.purs
+5
-1
GraphExplorer.purs
src/Gargantext/Components/GraphExplorer.purs
+2
-1
Sidebar.purs
src/Gargantext/Components/GraphExplorer/Sidebar.purs
+41
-1
LoadingSpinner.purs
src/Gargantext/Components/LoadingSpinner.purs
+7
-2
Reactix.purs
src/Gargantext/Utils/Reactix.purs
+5
-0
No files found.
dist/styles/Styles.css
0 → 100644
View file @
fe89cd5f
#page-wrapper
.cache-toggle
{
cursor
:
pointer
;
}
.simple-layout
{
height
:
100%
;
}
.simple-layout
.spinner
{
position
:
absolute
;
left
:
50%
;
top
:
50%
;
}
/*# sourceMappingURL=Styles.css.map */
dist/styles/Styles.sass
0 → 100644
View file @
fe89cd5f
#page-wrapper
.cache-toggle
cursor
:
pointer
.simple-layout
height
:
100%
.spinner
position
:
absolute
left
:
50%
top
:
50%
src/Gargantext/Components/App.purs
View file @
fe89cd5f
...
...
@@ -148,7 +148,11 @@ forestLayoutMainCpt = R2.hooksComponent thisModule "forestLayoutMain" cpt
-- Simple layout does not accommodate the tree
simpleLayout :: R.State GT.Handed -> R.Element -> R.Element
simpleLayout handed child = R.fragment [ topBar { handed }, child, license]
simpleLayout handed child = H.div { className: "simple-layout" } [
topBar { handed }
, child
, license
]
mainPage :: R.Element -> R.Element
mainPage child =
...
...
src/Gargantext/Components/GraphExplorer.purs
View file @
fe89cd5f
...
...
@@ -37,6 +37,7 @@ import Gargantext.Types as Types
import Gargantext.Utils.Range as Range
import Gargantext.Utils.Reactix as R2
thisModule :: String
thisModule = "Gargantext.Components.GraphExplorer"
type LayoutProps =
...
...
@@ -79,7 +80,7 @@ explorerLayoutView graphVersion p = R.createElement el p []
explorer (Record.merge props { graph, graphVersion, hyperdataGraph: loaded, mMetaData })
where
GET.HyperdataGraph { graph: hyperdataGraph } = loaded
(Tuple mMetaData graph)
= convert hyperdataGraph
Tuple mMetaData graph
= convert hyperdataGraph
--------------------------------------------------------------
explorer :: Record Props -> R.Element
...
...
src/Gargantext/Components/GraphExplorer/Sidebar.purs
View file @
fe89cd5f
...
...
@@ -20,6 +20,7 @@ import Reactix.DOM.HTML as H
import Gargantext.Prelude
import Gargantext.Components.Lang (Lang(..))
import Gargantext.Components.Search (SearchType(..), SearchQuery(..))
import Gargantext.Components.GraphExplorer.Types as GET
import Gargantext.Components.GraphExplorer.Types (SidePanelState(..), SideTab(..))
...
...
@@ -85,8 +86,10 @@ sideTabNav (sidePanel /\ setSidePanel) sideTabs =
sideTab :: SidePanelState -> Record Props -> R.Element
sideTab (Opened SideTabLegend) props@{metaData} =
let (GET.MetaData {legend}) = metaData
H.div {} [
let (GET.MetaData {legend}) = metaData
in Legend.legend { items: Seq.fromFoldable legend}
, documentation EN
]
sideTab (Opened SideTabData) props =
RH.div {} [ selectedNodes props (SigmaxT.nodesGraphMap props.graph)
...
...
@@ -290,4 +293,41 @@ query searchType frontends (GET.MetaData metaData) session nodesMap (selectedNod
]
]
-}
--------------------------------------------------------------------------
documentation :: Lang -> R.Element
documentation _ =
H.div {} [ H.h2 {} [ H.text "What is Graph ?"]
, ul [ "Graph is a conveniant tool to explore your documents. "
, "Nodes are terms selected in your Map List. "
<> "Node size is proportional to the number of documents with the associated term. "
, "Edges between nodes represent proximities of terms according to a specific distance between your documents. "
<> "Link strength is proportional to the strenght of terms association."
]
, H.h3 {} [ H.text "Basic Interactions:"]
, ul [ "Click on a node to select/unselect and get its information. "
, "In case of multiple selection, the button unselect clears all selections. "
<> "Use your mouse scroll to zoom in and out in the graph. "
, "Use the node filter to create a subgraph with nodes of a given size "
<>"range (e.g. display only generic terms). "
, "Use the edge filter so create a subgraph with links in a given range (e.g. keep the strongest association)."
]
]
where
ul ts = H.ul {} $ map (\t -> H.li {} [ H.text t ]) ts
{-
TODO DOC
Conditional distance between the terms X and Y is the probability to have both terms X and Y in the same textual context.
Distributional distance between the terms X and Y is the probability to have same others terms in the same textual context as X or Y.
Global/local view:
The 'change level' button allows to change between global view and node centered view,
To explore the neighborhood of a selection click on the 'change level' button.
-}
src/Gargantext/Components/LoadingSpinner.purs
View file @
fe89cd5f
...
...
@@ -3,15 +3,20 @@ module Gargantext.Components.LoadingSpinner where
import Reactix as R
import Reactix.DOM.HTML as H
import Gargantext.Utils.Reactix as R2
thisModule :: String
thisModule = "Gargantext.Components.LoadingSpinner"
type Props = ()
loadingSpinner :: Record Props -> R.Element
loadingSpinner props = R.createElement loadingSpinnerCpt props []
loadingSpinnerCpt :: R.Component Props
loadingSpinnerCpt = R
.staticComponent
"LoadingSpinner" cpt
loadingSpinnerCpt = R
2.staticComponent thisModule
"LoadingSpinner" cpt
where
cpt _ _ = H.i {className: "fa fa-smile-o fa-spin fa-3x fa-fw"} [H.text ""]
cpt _ _ = H.i {className: "
spinner
fa fa-smile-o fa-spin fa-3x fa-fw"} [H.text ""]
-- cpt _ _ = H.i {className: "fa fa-globe fa-spin fa-3x fa-fw"} [H.text ""]
-- cpt _ _ = H.i {className: "fa fa-circle-o-notch fa-spin fa-3x fa-fw"} [H.text ""]
...
...
src/Gargantext/Utils/Reactix.purs
View file @
fe89cd5f
...
...
@@ -48,6 +48,11 @@ type HooksComponent props = Record props -> Array R.Element -> R.Hooks R.Element
hooksComponent :: forall props. String -> String -> HooksComponent props -> R.Component props
hooksComponent module' name c = R.hooksComponent (module' <> "." <> name) c
type StaticComponent props = Record props -> Array R.Element -> R.Element
staticComponent :: forall props. String -> String -> StaticComponent props -> R.Component props
staticComponent module' name c = R.staticComponent (module' <> "." <> name) c
newtype Point = Point { x :: Number, y :: Number }
-- a setter function, for useState
...
...
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