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
4
Merge Requests
4
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
f0ce010f
Commit
f0ce010f
authored
Sep 10, 2018
by
Alexandre Delanoë
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Chart] With Smart Constructor only (Sankey).
parent
df46c07f
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
10 deletions
+9
-10
Series.purs
src/Gargantext/Components/Charts/Options/Series.purs
+8
-9
Dashboard.purs
src/Gargantext/Pages/Corpus/Doc/Facets/Dashboard.purs
+1
-1
No files found.
src/Gargantext/Components/Charts/Options/Series.purs
View file @
f0ce010f
...
@@ -60,7 +60,7 @@ type D2 =
...
@@ -60,7 +60,7 @@ type D2 =
{ "symbolSize" :: Number
{ "symbolSize" :: Number
, "data" :: Array (Array Number)
, "data" :: Array (Array Number)
, "type" :: SeriesType
, "type" :: SeriesType
}
}
toSeries :: Serie -> Series
toSeries :: Serie -> Series
toSeries (SeriesD1 a) = unsafeCoerce a
toSeries (SeriesD1 a) = unsafeCoerce a
...
@@ -81,8 +81,8 @@ type Link = { source :: String
...
@@ -81,8 +81,8 @@ type Link = { source :: String
, value :: Number
, value :: Number
}
}
mkSankey :: Array Node -> Array Link -> S
ankey
mkSankey :: Array Node -> Array Link -> S
erie
mkSankey ns ls =
{"type"
: seriesType Sankey
mkSankey ns ls =
SeriesSankey {"type"
: seriesType Sankey
, layout : "none"
, layout : "none"
, "data" : ns
, "data" : ns
, "links" : ls
, "links" : ls
...
@@ -131,4 +131,3 @@ mkSankey ns ls = {"type" : seriesType Sankey
...
@@ -131,4 +131,3 @@ mkSankey ns ls = {"type" : seriesType Sankey
-- https://ecomfe.github.io/echarts-examples/public/editor.html?c=scatter3D-dataset&gl=1
-- https://ecomfe.github.io/echarts-examples/public/editor.html?c=scatter3D-dataset&gl=1
src/Gargantext/Pages/Corpus/Doc/Facets/Dashboard.purs
View file @
f0ce010f
...
@@ -125,7 +125,7 @@ sankeyEx :: Options
...
@@ -125,7 +125,7 @@ sankeyEx :: Options
sankeyEx = Options { mainTitle : ""
sankeyEx = Options { mainTitle : ""
, subTitle : ""
, subTitle : ""
, xAxis : xAxis []
, xAxis : xAxis []
, yAxis : [
SeriesSankey $
mkSankey [{name : "a"}, {name : "b"}, {name:"c"}, {name:"d"}]
, yAxis : [ mkSankey [{name : "a"}, {name : "b"}, {name:"c"}, {name:"d"}]
[{source : "a", target : "b", value :2.0}
[{source : "a", target : "b", value :2.0}
, {source : "a", target : "c", value :1.0}
, {source : "a", target : "c", value :1.0}
, {source : "b", target : "c", value :1.0}
, {source : "b", target : "c", value :1.0}
...
...
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