Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F82310273
journalCard.js
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Tue, Sep 10, 17:01
Size
2 KB
Mime Type
text/x-java
Expires
Thu, Sep 12, 17:01 (2 d)
Engine
blob
Format
Raw Data
Handle
20679374
Attached To
rOACCT Open Access Compliance Check Tool (OACCT)
journalCard.js
View Options
import
React
from
"react"
;
import
{
Card
,
Accordion
}
from
'react-bootstrap'
;
import
{
makeStyles
}
from
'@material-ui/core/styles'
;
import
Chip
from
'@material-ui/core/Chip'
;
import
DoneIcon
from
'@material-ui/icons/Done'
;
import
HighlightOffIcon
from
'@material-ui/icons/HighlightOff'
;
const
useStyles
=
makeStyles
({
root
:
{
background
:
'linear-gradient(45deg, #FE6B8B 30%, #FF8E53 90%)'
,
border
:
0
,
borderRadius
:
3
,
boxShadow
:
'0 3px 5px 2px rgba(255, 105, 135, .3)'
,
color
:
'primary'
,
height
:
48
,
padding
:
'0 30px'
,
},
card
:
{
width
:
'100%'
,
marginTop
:
"1rem"
}
});
const
handleClick
=
()
=>
{
console
.
info
(
'You clicked the Chip.'
);
};
export
default
function
JournalCard
({
journal
}){
const
classes
=
useStyles
();
return
(
<
Accordion
defaultActiveKey
=
"0"
>
<
Card
className
=
{
classes
.
card
}
>
<
Accordion
.
Toggle
as
=
{
Card
.
Header
}
eventKey
=
"0"
>
{
journal
.
name
}
<
/Accordion.Toggle>
<
Accordion
.
Collapse
eventKey
=
"0"
>
<
Card
.
Body
>
<
Card
.
Title
>
<
h3
>
{
journal
.
name
}
<
/h3></Card.Title>
<
Card
.
Subtitle
className
=
"mb-2 text-muted"
>
Since
{
journal
.
starting_year
}
<
/Card.Subtitle>
<
Card
.
Text
>
<
h5
>
ISSN
<
/h5>
<
ul
>
{
journal
.
issn
.
map
(
item
=>
(
<
li
>
{
item
}
<
/li>
))}
<
/ul>
{
journal
.
oa_status
?
(
<
Chip
size
=
"small"
avatar
=
{
<
DoneIcon
/>
}
label
=
"OA Status"
clickable
=
{
handleClick
}
// color="secondary"
// onDelete={handleDelete}
style
=
{{
background
:
"#cddc39"
}}
/>
)
:
(
<
Chip
size
=
"small"
avatar
=
{
<
HighlightOffIcon
/>
}
label
=
"OA Status"
clickable
=
{
handleClick
}
// color="secondary"
// onDelete={handleDelete}
style
=
{{
background
:
"#f50057"
}}
/>
)
}
<
/Card.Text>
<
Card
.
Link
href
=
"#"
>
{
journal
.
website
}
<
/Card.Link>
<
/Card.Body>
<
/Accordion.Collapse>
<
/Card>
<
/Accordion>
)
}
Event Timeline
Log In to Comment