Commit 70fe17b6 authored by Przemyslaw Kaminski's avatar Przemyslaw Kaminski

[DocsTable] chart is a reactix element now

parent af59716b
...@@ -72,7 +72,7 @@ trashCategory Favorite = Trash ...@@ -72,7 +72,7 @@ trashCategory Favorite = Trash
type Props = type Props =
{ nodeId :: Int { nodeId :: Int
, totalRecords :: Int , totalRecords :: Int
, chart :: ReactElement , chart :: R.Element
, tabType :: TabType , tabType :: TabType
, listId :: Int , listId :: Int
, corpusId :: Maybe Int , corpusId :: Maybe Int
...@@ -176,7 +176,7 @@ layoutDocview documentIdsDeleted@(_ /\ setDocumentIdsDeleted) localCategories (m ...@@ -176,7 +176,7 @@ layoutDocview documentIdsDeleted@(_ /\ setDocumentIdsDeleted) localCategories (m
cpt {nodeId, tabType, listId, corpusId, totalRecords, chart} _children = do cpt {nodeId, tabType, listId, corpusId, totalRecords, chart} _children = do
pure $ H.div {className: "container1"} pure $ H.div {className: "container1"}
[ H.div {className: "row"} [ H.div {className: "row"}
[ R2.buff chart [ chart
, H.div {} , H.div {}
[ H.input { type: "text" [ H.input { type: "text"
, onChange: onChangeQuery , onChange: onChangeQuery
......
...@@ -22,8 +22,8 @@ import Gargantext.Components.DocsTable as DT ...@@ -22,8 +22,8 @@ import Gargantext.Components.DocsTable as DT
import Gargantext.Components.Tab as Tab import Gargantext.Components.Tab as Tab
import Gargantext.Utils.Reactix as R2 import Gargantext.Utils.Reactix as R2
import Reactix.DOM.HTML as H
import React (ReactElement, ReactClass, createElement, Children) import React (ReactElement, ReactClass, createElement, Children)
import React.DOM (div)
import Thermite (Spec, hideState, noState, cmapProps, createClass) import Thermite (Spec, hideState, noState, cmapProps, createClass)
data Mode = Authors | Sources | Institutes | Terms data Mode = Authors | Sources | Institutes | Terms
...@@ -66,7 +66,7 @@ statefulTabs = ...@@ -66,7 +66,7 @@ statefulTabs =
(cmapProps (\{corpusId, corpusData: {defaultListId}} -> (cmapProps (\{corpusId, corpusData: {defaultListId}} ->
{ nodeId: corpusId { nodeId: corpusId
-- ^ TODO merge nodeId and corpusId in DT -- ^ TODO merge nodeId and corpusId in DT
, chart : div [][] , chart : H.div {} []
, tabType: TabCorpus TabDocs , tabType: TabCorpus TabDocs
, totalRecords: 4737 , totalRecords: 4737
, listId: defaultListId , listId: defaultListId
...@@ -75,7 +75,7 @@ statefulTabs = ...@@ -75,7 +75,7 @@ statefulTabs =
) )
trash = cmapProps (\{corpusId, corpusData: {defaultListId}} -> trash = cmapProps (\{corpusId, corpusData: {defaultListId}} ->
{ nodeId: corpusId { nodeId: corpusId
, chart: div [][] , chart : H.div {} []
, tabType: TabCorpus TabTrash , tabType: TabCorpus TabTrash
, totalRecords: 4736 , totalRecords: 4736
, listId: defaultListId , listId: defaultListId
......
...@@ -22,8 +22,8 @@ import Gargantext.Components.DocsTable as DT ...@@ -22,8 +22,8 @@ import Gargantext.Components.DocsTable as DT
import Gargantext.Components.Tab as Tab import Gargantext.Components.Tab as Tab
import Gargantext.Utils.Reactix as R2 import Gargantext.Utils.Reactix as R2
import Reactix.DOM.HTML as H
import React (ReactElement, ReactClass, createElement, Children) import React (ReactElement, ReactClass, createElement, Children)
import React.DOM (div)
import Thermite (Spec, hideState, noState, cmapProps, createClass) import Thermite (Spec, hideState, noState, cmapProps, createClass)
data Mode = MoreLikeFav | MoreLikeTrash data Mode = MoreLikeFav | MoreLikeTrash
...@@ -64,7 +64,7 @@ statefulTabs = ...@@ -64,7 +64,7 @@ statefulTabs =
(cmapProps (\{corpusId, corpusData: {defaultListId}} -> (cmapProps (\{corpusId, corpusData: {defaultListId}} ->
{ nodeId: corpusId { nodeId: corpusId
-- ^ TODO merge nodeId and corpusId in DT -- ^ TODO merge nodeId and corpusId in DT
, chart : div [][] , chart : H.div {} []
, tabType: TabCorpus TabDocs , tabType: TabCorpus TabDocs
, totalRecords: 4737 , totalRecords: 4737
, listId: defaultListId , listId: defaultListId
...@@ -75,7 +75,7 @@ statefulTabs = ...@@ -75,7 +75,7 @@ statefulTabs =
moreLikeFav = noState (cmapProps (\{corpusId, corpusData: {defaultListId}} -> moreLikeFav = noState (cmapProps (\{corpusId, corpusData: {defaultListId}} ->
{ nodeId: corpusId { nodeId: corpusId
-- ^ TODO merge nodeId and corpusId in DT -- ^ TODO merge nodeId and corpusId in DT
, chart : div [][] , chart : H.div {} []
, tabType: TabCorpus TabMoreLikeFav , tabType: TabCorpus TabMoreLikeFav
, totalRecords: 4737 , totalRecords: 4737
, listId: defaultListId , listId: defaultListId
...@@ -85,7 +85,7 @@ statefulTabs = ...@@ -85,7 +85,7 @@ statefulTabs =
moreLikeTrash = noState (cmapProps (\{corpusId, corpusData: {defaultListId}} -> moreLikeTrash = noState (cmapProps (\{corpusId, corpusData: {defaultListId}} ->
{ nodeId: corpusId { nodeId: corpusId
-- ^ TODO merge nodeId and corpusId in DT -- ^ TODO merge nodeId and corpusId in DT
, chart : div [][] , chart : H.div {} []
, tabType: TabCorpus TabMoreLikeTrash , tabType: TabCorpus TabMoreLikeTrash
, totalRecords: 4737 , totalRecords: 4737
, listId: defaultListId , listId: defaultListId
...@@ -94,7 +94,7 @@ statefulTabs = ...@@ -94,7 +94,7 @@ statefulTabs =
trash = cmapProps (\{corpusId, corpusData: {defaultListId}} -> trash = cmapProps (\{corpusId, corpusData: {defaultListId}} ->
{ nodeId: corpusId { nodeId: corpusId
, chart: div [][] , chart : H.div {} []
, tabType: TabCorpus TabTrash , tabType: TabCorpus TabTrash
, totalRecords: 4736 , totalRecords: 4736
, listId: defaultListId , listId: defaultListId
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment