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
24191699
Unverified
Commit
24191699
authored
Nov 28, 2018
by
Nicolas Pouillard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove ngramview from global state
parent
7f7e4ea2
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
16 deletions
+4
-16
Actions.purs
src/Gargantext/Pages/Corpus/Tabs/Actions.purs
+0
-7
Specs.purs
src/Gargantext/Pages/Corpus/Tabs/Specs.purs
+4
-4
States.purs
src/Gargantext/Pages/Corpus/Tabs/States.purs
+0
-5
No files found.
src/Gargantext/Pages/Corpus/Tabs/Actions.purs
View file @
24191699
...
...
@@ -11,7 +11,6 @@ import Gargantext.Components.Tab as Tab
data Action
= DocViewA DV.Action -- = Void
| NgramViewA Void -- NG.Action TODO needed ?
| TabViewA Tab.Action -- = ChangeTab which is only used locally
_docAction :: Prism' Action DV.Action
...
...
@@ -20,12 +19,6 @@ _docAction = prism DocViewA \ action ->
DocViewA laction -> Right laction
_-> Left action
_NgramViewA :: Prism' Action Void -- NG.Action
_NgramViewA = prism NgramViewA \ action ->
case action of
NgramViewA laction -> Right laction
_-> Left action
_tabAction :: Prism' Action Tab.Action
_tabAction = prism TabViewA \ action ->
case action of
...
...
src/Gargantext/Pages/Corpus/Tabs/Specs.purs
View file @
24191699
...
...
@@ -6,13 +6,13 @@ import Data.List (fromFoldable)
import Data.Tuple (Tuple(..))
import Gargantext.Pages.Corpus.Tabs.Types (Props)
import Gargantext.Pages.Corpus.Tabs.States (State(), _doclens, _
ngramsView, _
tablens, initialState)
import Gargantext.Pages.Corpus.Tabs.Actions (Action(), _docAction, _
NgramViewA, _
tabAction)
import Gargantext.Pages.Corpus.Tabs.States (State(), _doclens, _tablens, initialState)
import Gargantext.Pages.Corpus.Tabs.Actions (Action(), _docAction, _tabAction)
import Gargantext.Pages.Corpus.Tabs.Documents as DV
import Gargantext.Pages.Corpus.Tabs.Ngrams.NgramsTable as NV
import Gargantext.Components.Tab as Tab
import Thermite (Spec, focus, hideState, cmapProps)
import Thermite (Spec, focus, hideState,
noState,
cmapProps)
-- pureTabs :: Spec {} Props Void
...
...
@@ -34,7 +34,7 @@ docPageSpec = focus _doclens _docAction DV.layoutDocview
ngramsViewSpec :: {mode :: NV.Mode} -> Spec State Props Action
ngramsViewSpec {mode} =
cmapProps (\{loaded, path, dispatch} -> {mode,loaded,path, dispatch})
(
focus _ngramsView _NgramViewA
NV.ngramsTableSpec)
(
noState
NV.ngramsTableSpec)
authorPageSpec :: Spec State Props Action
authorPageSpec = ngramsViewSpec {mode: NV.Authors}
...
...
src/Gargantext/Pages/Corpus/Tabs/States.purs
View file @
24191699
...
...
@@ -9,7 +9,6 @@ import Gargantext.Components.Tab as Tab
type State =
{ docsView :: D.State
, ngramsView :: {} -- N.State TODO needed
, activeTab :: Int
}
...
...
@@ -18,15 +17,11 @@ initialState _ =
{ docsView :
{ documentIdsToDelete : mempty
}
, ngramsView : {} -- N.initialState
, activeTab : 0
}
_doclens :: Lens' State D.State
_doclens = lens (\s -> s.docsView) (\s ss -> s {docsView = ss})
_ngramsView :: Lens' State {} -- N.State
_ngramsView = lens (\s -> s.ngramsView) (\s ss -> s {ngramsView = ss})
_tablens :: Lens' State Tab.State
_tablens = lens (\s -> s.activeTab) (\s ss -> s {activeTab = ss})
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