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
8a899e20
Commit
8a899e20
authored
Apr 05, 2024
by
Fabien Manière
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
corpus children: add tabs and title icons + reduce the spinner width
parent
4a302ff2
Changes
11
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
58 additions
and
8 deletions
+58
-8
bootstrap-darkster.css
dist/styles/bootstrap-darkster.css
+3
-0
bootstrap-default.css
dist/styles/bootstrap-default.css
+3
-0
bootstrap-greyson.css
dist/styles/bootstrap-greyson.css
+3
-0
bootstrap-herbie.css
dist/styles/bootstrap-herbie.css
+3
-0
bootstrap-monotony.css
dist/styles/bootstrap-monotony.css
+3
-0
Layout.purs
src/Gargantext/Components/Corpus/Layout.purs
+1
-1
LoadingSpinner.purs
src/Gargantext/Components/LoadingSpinner.purs
+1
-1
Tab.purs
src/Gargantext/Components/Tab.purs
+13
-2
Table.purs
src/Gargantext/Components/Table.purs
+14
-4
Types.purs
src/Gargantext/Types.purs
+9
-0
_nav.scss
src/sass/base/_nav.scss
+5
-0
No files found.
dist/styles/bootstrap-darkster.css
View file @
8a899e20
...
...
@@ -6699,6 +6699,9 @@ a:hover {
.nav.nav-tabs
.nav-link
{
cursor
:
pointer
;
}
.nav.nav-tabs
.nav-link
.active
{
font-weight
:
500
;
}
.nav.nav-tabs
.nav-tabs
.nav-link.active
,
.nav.nav-tabs
.nav-tabs
.nav-item.show
.nav-link
,
.nav.nav-tabs
li
a
{
color
:
#DEE2E6
;
}
...
...
dist/styles/bootstrap-default.css
View file @
8a899e20
...
...
@@ -6510,6 +6510,9 @@ a:hover {
.nav.nav-tabs
.nav-link
{
cursor
:
pointer
;
}
.nav.nav-tabs
.nav-link
.active
{
font-weight
:
500
;
}
.nav.nav-tabs
.nav-tabs
.nav-link.active
,
.nav.nav-tabs
.nav-tabs
.nav-item.show
.nav-link
,
.nav.nav-tabs
li
a
{
color
:
#495057
;
}
...
...
dist/styles/bootstrap-greyson.css
View file @
8a899e20
...
...
@@ -6353,6 +6353,9 @@ a:hover {
.nav.nav-tabs
.nav-link
{
cursor
:
pointer
;
}
.nav.nav-tabs
.nav-link
.active
{
font-weight
:
500
;
}
.nav.nav-tabs
.nav-tabs
.nav-link.active
,
.nav.nav-tabs
.nav-tabs
.nav-item.show
.nav-link
,
.nav.nav-tabs
li
a
{
color
:
#495057
;
}
...
...
dist/styles/bootstrap-herbie.css
View file @
8a899e20
...
...
@@ -6574,6 +6574,9 @@ a:hover {
.nav.nav-tabs
.nav-link
{
cursor
:
pointer
;
}
.nav.nav-tabs
.nav-link
.active
{
font-weight
:
500
;
}
.nav.nav-tabs
.nav-tabs
.nav-link.active
,
.nav.nav-tabs
.nav-tabs
.nav-item.show
.nav-link
,
.nav.nav-tabs
li
a
{
color
:
#495057
;
}
...
...
dist/styles/bootstrap-monotony.css
View file @
8a899e20
...
...
@@ -6647,6 +6647,9 @@ a:hover {
.nav.nav-tabs
.nav-link
{
cursor
:
pointer
;
}
.nav.nav-tabs
.nav-link
.active
{
font-weight
:
500
;
}
.nav.nav-tabs
.nav-tabs
.nav-link.active
,
.nav.nav-tabs
.nav-tabs
.nav-item.show
.nav-link
,
.nav.nav-tabs
li
a
{
color
:
#495057
;
}
...
...
src/Gargantext/Components/Corpus/Layout.purs
View file @
8a899e20
...
...
@@ -34,7 +34,7 @@ layout :: R2.Leaf Props
layout = R2.leaf layoutCpt
layoutCpt :: R.Component Props
layoutCpt = here.component "layout" cpt where
cpt { nodeId, nodeData: { name } } _ = do
cpt { nodeId, nodeData: { name
, type_id
} } _ = do
-- | Hooks
-- |
boxes@{
...
...
src/Gargantext/Components/LoadingSpinner.purs
View file @
8a899e20
...
...
@@ -23,6 +23,6 @@ loadingSpinnerCpt = here.component "LoadingSpinner" cpt where
-- cpt _ _ = H.i {className: "fa fa-circle-o-notch fa-spin fa-3x fa-fw"} [H.text ""]
cpt { additionalClass } _ = do
pure $ H.i { className: "fa fa-spinner fa-pulse fa-
3x fa-
fw " <> c } [H.text ""]
pure $ H.i { className: "fa fa-spinner fa-pulse fa-fw " <> c } [H.text ""]
where
c = fromMaybe "" additionalClass
src/Gargantext/Components/Tab.purs
View file @
8a899e20
...
...
@@ -3,6 +3,8 @@ module Gargantext.Components.Tab where
import Data.FunctorWithIndex (mapWithIndex)
import Data.Tuple (Tuple)
import Data.Tuple.Nested ((/\))
import Gargantext.Components.Bootstrap as B
import Gargantext.Types as GT
import Reactix as R
import Reactix.DOM.HTML as H
import Toestand as T
...
...
@@ -49,10 +51,19 @@ tabsCpt = here.component "tabs" cpt where
(mapWithIndex (item activeTab') tabs')
]
button activeTab selected index (name /\ _) =
H.a { className, on: { click } } [ H.text name ] where
H.a { className, on: { click } }
[
B.icon
{ className: "mx-1"
, name: iconName
}
,
H.span {} [ H.text name ]
] where
eq = index == selected
className = "nav-item nav-link" <> (if eq then " active" else "")
className = "
tab-label_" <> name <> "
nav-item nav-link" <> (if eq then " active" else "")
click _ = T.write_ index activeTab
iconName = GT.getTabIcon name
item selected index (_ /\ cpt') = tab { selected, index } [ cpt' ]
-- TODO: document what these are (selection, item indices)
...
...
src/Gargantext/Components/Table.purs
View file @
8a899e20
...
...
@@ -166,11 +166,21 @@ tableHeaderWithRenameBoxedLayoutCpt = here.component "tableHeaderWithRenameBoxed
,
-}
H.div
{ className: "table-header-rename__title" }
{ className: "table-header-rename__title
text-primary
" }
[
B.div'
{ className: "table-header-rename__title__text" }
name
H.div { className: "table-header-rename__title__text" }
[
B.icon
{ className: "mx-1"
, name: "book"
}
,
H.span {}
[
H.text name
]
]
,
H.hr
{ className: "table-header-rename__title__line" }
...
...
src/Gargantext/Types.purs
View file @
8a899e20
...
...
@@ -701,6 +701,15 @@ modeFromString "Sources" = Just Sources
modeFromString "Terms" = Just Terms
modeFromString _ = Nothing
getTabIcon :: String -> String
getTabIcon "Authors" = "list"
getTabIcon "Institutes" = "list"
getTabIcon "Sources" = "list"
getTabIcon "Terms" = "list"
getTabIcon "Documents" = "newspaper-o"
getTabIcon "Trash" = "trash"
getTabIcon _ = ""
-- Async tasks
-- corresponds to /add/form/async or /add/query/async
...
...
src/sass/base/_nav.scss
View file @
8a899e20
...
...
@@ -2,6 +2,11 @@
.nav-link
{
cursor
:
pointer
;
.active
{
font-weight
:
500
;
}
}
.nav-tabs
.nav-link.active
,
.nav-tabs
.nav-item.show
.nav-link
,
li
a
{
...
...
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