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
0
Issues
0
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
Grégoire Locqueville
purescript-gargantext
Commits
3f6b58fd
Commit
3f6b58fd
authored
Jun 25, 2020
by
Alexandre Delanoë
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[FIX] unsafePartial error fix
parent
ca62568f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
5 deletions
+4
-5
Tree.purs
src/Gargantext/Components/Forest/Tree.purs
+0
-3
ProgressBar.purs
...antext/Components/Forest/Tree/Node/Tools/ProgressBar.purs
+4
-2
No files found.
src/Gargantext/Components/Forest/Tree.purs
View file @
3f6b58fd
...
@@ -281,7 +281,6 @@ performAction (ShareNode username) p@{ reload: (_ /\ setReload)
...
@@ -281,7 +281,6 @@ performAction (ShareNode username) p@{ reload: (_ /\ setReload)
do
do
void $ share session id $ ShareValue {text:username}
void $ share session id $ ShareValue {text:username}
-------
-------
performAction (AddNode name nodeType) p@{ openNodes: (_ /\ setOpenNodes)
performAction (AddNode name nodeType) p@{ openNodes: (_ /\ setOpenNodes)
, reload: (_ /\ setReload)
, reload: (_ /\ setReload)
...
@@ -319,8 +318,6 @@ performAction (LinkNode n1 n2) p@{session} = do
...
@@ -319,8 +318,6 @@ performAction (LinkNode n1 n2) p@{session} = do
void $ linkNodeReq session n1 n2
void $ linkNodeReq session n1 n2
performAction RefreshTree p
performAction RefreshTree p
-------
-------
performAction RefreshTree { reload: (_ /\ setReload) } = do
performAction RefreshTree { reload: (_ /\ setReload) } = do
liftEffect $ setReload (_ + 1)
liftEffect $ setReload (_ + 1)
...
...
src/Gargantext/Components/Forest/Tree/Node/Tools/ProgressBar.purs
View file @
3f6b58fd
...
@@ -3,7 +3,7 @@ module Gargantext.Components.Forest.Tree.Node.Tools.ProgressBar where
...
@@ -3,7 +3,7 @@ module Gargantext.Components.Forest.Tree.Node.Tools.ProgressBar where
import Gargantext.Prelude
import Gargantext.Prelude
import Data.Int (fromNumber)
import Data.Int (fromNumber)
import Data.Maybe (Maybe(..),
fromJust
)
import Data.Maybe (Maybe(..),
maybe
)
import Data.Tuple.Nested ((/\))
import Data.Tuple.Nested ((/\))
import Effect (Effect)
import Effect (Effect)
import Effect.Aff (Aff, launchAff_)
import Effect.Aff (Aff, launchAff_)
...
@@ -65,7 +65,9 @@ asyncProgressBarCpt = R.hooksComponent "G.C.F.T.N.PB.asyncProgressBar" cpt
...
@@ -65,7 +65,9 @@ asyncProgressBarCpt = R.hooksComponent "G.C.F.T.N.PB.asyncProgressBar" cpt
pure $ progressIndicator { barType, label: id, progress: toInt progress }
pure $ progressIndicator { barType, label: id, progress: toInt progress }
toInt :: Number -> Int
toInt :: Number -> Int
toInt n = unsafePartial $ fromJust $ fromNumber n
toInt n = case fromNumber n of
Nothing -> 0
Just x -> x
type ProgressIndicatorProps =
type ProgressIndicatorProps =
( barType :: BarType
( barType :: BarType
...
...
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