Verified Commit e5ea3eff authored by Przemyslaw Kaminski's avatar Przemyslaw Kaminski

Merge branch 'dev' into 603-dev-istex-zip-file-upload

parents a6c29d63 ebf80996
Pipeline #5216 failed with stage
in 0 seconds
......@@ -12314,6 +12314,29 @@ select.form-control {
overflow-x: hidden;
}
.breadcrumb-wrapper {
border-bottom: 1px solid #dee2e6;
}
.breadcrumb-wrapper .breadcrumb {
background-color: transparent;
padding: 4px 4px !important;
margin: 0 !important;
}
.breadcrumb-wrapper .breadcrumb-item {
color: #DEE2E6;
}
.breadcrumb-wrapper .breadcrumb-item .active-page {
font-weight: bold;
color: #33A2FF;
}
.breadcrumb-wrapper .breadcrumb-item .b-icon {
margin: 0 4px;
}
.breadcrumb-wrapper .fa-spinner {
font-size: 100%;
margin: auto 10px;
}
.dropdown-menu {
background-color: #181A1B;
}
......
......@@ -12116,6 +12116,29 @@ select.form-control {
overflow-x: hidden;
}
.breadcrumb-wrapper {
border-bottom: 1px solid #dee2e6;
}
.breadcrumb-wrapper .breadcrumb {
background-color: transparent;
padding: 4px 4px !important;
margin: 0 !important;
}
.breadcrumb-wrapper .breadcrumb-item {
color: #495057;
}
.breadcrumb-wrapper .breadcrumb-item .active-page {
font-weight: bold;
color: #005a9a;
}
.breadcrumb-wrapper .breadcrumb-item .b-icon {
margin: 0 4px;
}
.breadcrumb-wrapper .fa-spinner {
font-size: 100%;
margin: auto 10px;
}
.btn-secondary,
.btn-secondary:hover,
.btn-outline-secondary:not(:disabled):not(.disabled):hover,
......
......@@ -11880,4 +11880,27 @@ select.form-control {
overflow-x: hidden;
}
.breadcrumb-wrapper {
border-bottom: 1px solid #dee2e6;
}
.breadcrumb-wrapper .breadcrumb {
background-color: transparent;
padding: 4px 4px !important;
margin: 0 !important;
}
.breadcrumb-wrapper .breadcrumb-item {
color: #495057;
}
.breadcrumb-wrapper .breadcrumb-item .active-page {
font-weight: bold;
color: #2f3c48;
}
.breadcrumb-wrapper .breadcrumb-item .b-icon {
margin: 0 4px;
}
.breadcrumb-wrapper .fa-spinner {
font-size: 100%;
margin: auto 10px;
}
/*# sourceMappingURL=bootstrap-greyson.css.map */
......@@ -12128,4 +12128,27 @@ select.form-control {
overflow-x: hidden;
}
.breadcrumb-wrapper {
border-bottom: 1px solid #dee2e6;
}
.breadcrumb-wrapper .breadcrumb {
background-color: transparent;
padding: 4px 4px !important;
margin: 0 !important;
}
.breadcrumb-wrapper .breadcrumb-item {
color: #495057;
}
.breadcrumb-wrapper .breadcrumb-item .active-page {
font-weight: bold;
color: #083358;
}
.breadcrumb-wrapper .breadcrumb-item .b-icon {
margin: 0 4px;
}
.breadcrumb-wrapper .fa-spinner {
font-size: 100%;
margin: auto 10px;
}
/*# sourceMappingURL=bootstrap-herbie.css.map */
......@@ -12129,4 +12129,27 @@ select.form-control {
overflow-x: hidden;
}
.breadcrumb-wrapper {
border-bottom: 1px solid #dee2e6;
}
.breadcrumb-wrapper .breadcrumb {
background-color: transparent;
padding: 4px 4px !important;
margin: 0 !important;
}
.breadcrumb-wrapper .breadcrumb-item {
color: #495057;
}
.breadcrumb-wrapper .breadcrumb-item .active-page {
font-weight: bold;
color: #222222;
}
.breadcrumb-wrapper .breadcrumb-item .b-icon {
margin: 0 4px;
}
.breadcrumb-wrapper .fa-spinner {
font-size: 100%;
margin: auto 10px;
}
/*# sourceMappingURL=bootstrap-monotony.css.map */
{
"name": "Gargantext",
"version": "0.0.6.9.9.8",
"version": "0.0.6.9.9.8.2",
"scripts": {
"generate-purs-packages-nix": "./nix/generate-purs-packages.nix",
"generate-psc-packages-nix": "./nix/generate-packages-json.bash",
......
This diff is collapsed.
......@@ -166,9 +166,9 @@ allDatabases = [ Empty
, HAL Nothing
, Arxiv
, OpenAlex
-- , IsTex
-- , IsTex_Advanced
-- , Isidore
, IsTex
--, IsTex_Advanced
--, Isidore
--, Web
--, News
--, SocialNetworks
......
......@@ -15,7 +15,7 @@ import Gargantext.Components.GraphQL.Context as GQLCTX
import Gargantext.Components.GraphQL.IMT as GQLIMT
import Gargantext.Components.GraphQL.NLP as GQLNLP
import Gargantext.Components.GraphQL.Node as GQLNode
import Gargantext.Components.GraphQL.Tree (TreeFirstLevel)
import Gargantext.Components.GraphQL.Tree (TreeFirstLevel, BreadcrumbInfo)
import Gargantext.Components.GraphQL.User (User, UserInfo, UserInfoM, UserPubmedAPIKeyM)
import Gargantext.Components.GraphQL.Team (Team, TeamDeleteM)
import Gargantext.Ends (Backend(..))
......@@ -86,6 +86,7 @@ type Schema
, users :: { user_id :: Int } ==> Array User
, team :: { team_node_id :: Int } ==> Team
, tree :: { root_id :: Int } ==> TreeFirstLevel
, tree_branch :: { node_id :: Int } ==> BreadcrumbInfo
}
type Mutation
......
......@@ -16,10 +16,10 @@ import Gargantext.Components.GraphQL.IMT as GQLIMT
import Gargantext.Components.GraphQL.NLP as GQLNLP
import Gargantext.Components.GraphQL.Node (Corpus, Node, nodeParentQuery, nodesQuery, nodesCorpusQuery)
import Gargantext.Components.GraphQL.Team (Team, teamQuery)
import Gargantext.Components.GraphQL.Tree (TreeFirstLevel, treeFirstLevelQuery)
import Gargantext.Components.GraphQL.Tree (TreeFirstLevel, treeFirstLevelQuery, BreadcrumbInfo, breadcrumbQuery)
import Gargantext.Components.GraphQL.User (UserInfo, userInfoQuery, User, userQuery)
import Gargantext.Components.Lang (Lang)
import Gargantext.Config.REST (RESTError(..), AffRESTError)
import Gargantext.Config.REST (RESTError(..), AffRESTError, logRESTError)
import Gargantext.Core.NgramsTable.Types (NgramsTerm(..))
import Gargantext.Sessions (Session(..))
import Gargantext.Types (CorpusId, NodeType)
......@@ -178,3 +178,9 @@ getContextNgrams session context_id list_id = do
let query = GQLCTX.contextNgramsQuery `withVars` { context_id, list_id }
{ context_ngrams } <- queryGql session "get context ngrams" query
pure $ Right $ NormNgramsTerm <$> context_ngrams
getBreadcrumb :: Session -> Int -> AffRESTError BreadcrumbInfo
getBreadcrumb session id = do
{ tree_branch } <- queryGql session "get breadcrumb branch" $ breadcrumbQuery `withVars` { id }
liftEffect $ here.log2 "[getBreadcrumb] breadcrumb" tree_branch
pure $ Right tree_branch
......@@ -19,6 +19,10 @@ type TreeFirstLevel =
, parent :: Maybe TreeNode
}
type BreadcrumbInfo =
{ parents :: Array TreeNode }
treeFirstLevelQuery = { tree: { root_id: Var :: _ "id" Int} =>>
{ root: { name: unit
, node_type: unit
......@@ -37,3 +41,13 @@ treeFirstLevelQuery = { tree: { root_id: Var :: _ "id" Int} =>>
}
}
}
breadcrumbQuery = { tree_branch: { node_id: Var :: _ "id" Int} =>>
{ parents:
{ name: unit
, node_type: unit
, id: unit
, parent_id: unit
}
}
}
\ No newline at end of file
......@@ -114,16 +114,16 @@ userLayoutWithKeyCpt = here.component "userLayoutWithKey" cpt where
display { title: fromMaybe "no name" (Just ui_username) }
(contactInfos userInfo (onUpdateUserInfo boxes.errors reload))
, pubmedSettings { boxes, nodeId, session }
, Tabs.tabs {
boxes
, cacheState
, defaultListId: 424242
, frontends
, nodeId
, session
, sidePanel: sidePanelTexts
, sidePanelList: sidePanelLists
}
-- , Tabs.tabs {
-- boxes
-- , cacheState
-- , defaultListId: 424242
-- , frontends
-- , nodeId
-- , session
-- , sidePanel: sidePanelTexts
-- , sidePanelList: sidePanelLists
-- }
]
}
where
......
......@@ -12,9 +12,12 @@ import Data.UUID (UUID)
import Data.UUID as UUID
import Effect (Effect)
import Gargantext.Components.App.Store (Boxes)
import Gargantext.Components.Bootstrap as B
import Gargantext.Components.ErrorsView as ErrorsView
import Gargantext.Components.Forest (forestLayout)
import Gargantext.Components.Forest.Breadcrumb as Breadcrumb
import Gargantext.Components.ForgotPassword (forgotPasswordLayout)
-- import Gargantext.Components.GraphQL.Node (Node)
import Gargantext.Components.Login (login)
import Gargantext.Components.Nodes.Annuaire (annuaireLayout)
import Gargantext.Components.Nodes.Annuaire.User (userLayout)
......@@ -34,6 +37,7 @@ import Gargantext.Components.Tile (tileBlock)
import Gargantext.Components.TopBar as TopBar
import Gargantext.Components.TreeSearch (treeSearch)
import Gargantext.Config (defaultFrontends, defaultBackends)
import Gargantext.Config.REST (AffRESTError, logRESTError)
import Gargantext.Context.Session as SessionContext
import Gargantext.Ends (Backend)
import Gargantext.Hooks.Resize (ResizeType(..), useResizeHandler)
......@@ -64,6 +68,8 @@ type SessionProps = ( sessionId :: SessionId | Props )
type SessionNodeProps = ( nodeId :: NodeID | SessionProps )
type Props' = ( backend :: Backend, route' :: AppRoute | Props )
type NodeProps = ( nodeId :: NodeID | Props )
router :: R2.Leaf Props
router = R2.leaf routerCpt
routerCpt :: R.Component Props
......@@ -123,6 +129,25 @@ routerCpt = here.component "router" cpt where
--------------------------------------------------------------
-- breadcrumb :: R2.Leaf NodeProps
-- breadcrumb = R2.leaf breadcrumbCpt
-- breadcrumbCpt :: R.Component NodeProps
-- breadcrumbCpt = here.component "breadcrumb" cpt where
-- cpt props@{ nodeId } _ = do
-- let
-- sessionProps = RE.pick props :: Record SessionProps
-- authedProps =
-- -- Record.merge { content: \session -> breadcrumbLayout
-- -- { boxes
-- -- , frontends: defaultFrontends
-- -- , nodeId
-- -- , session } } sessionProps
-- Record.merge { content: \_ -> breadcrumbLayout { nodeId } } sessionProps
-- pure $ authed authedProps []
-- -- pure $ breadcrumbLayout { nodeId }
--------------------------------------------------------------
mainPage :: R2.Leaf Props
mainPage = R2.leaf mainPageCpt
mainPageCpt :: R.Component Props
......@@ -148,11 +173,15 @@ mainPageCpt = here.component "mainPage" cpt where
let hasHorizontalTiles = not $ eq 0 $ length tileAxisXList
let hasVerticalTiles = not $ eq 0 $ length tileAxisYList
-- Render
pure $
H.div { className: "router__body main-page" }
[
Breadcrumb.component
{ boxes }
,
H.div
{ className: intercalate " "
[ "main-page__main-row"
......
......@@ -13,3 +13,4 @@
@import "./_legacy/_corpus"
@import "./_legacy/_annuaire"
@import "./_legacy/_search"
@import "./_legacy/_breadcrumb"
\ No newline at end of file
.breadcrumb-wrapper
border-bottom: 1px solid $border-color
.breadcrumb
background-color: transparent
padding: space-x(0.5) space-x(0.5) !important
margin: 0 !important
&-item
color: $gray-700
& .active-page
font-weight: bold
color: $primary
.b-icon
margin: 0 space-x(0.5)
.fa-spinner
font-size: 100%
margin: auto 10px
\ No newline at end of file
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