Skip to content
Snippets Groups Projects
Commit 8354785a authored by Anca Ursachi's avatar Anca Ursachi
Browse files

fix(contextualBox): Make contextual boxes toggle again.

parent 924cb037
No related branches found
No related tags found
2 merge requests!222Sprint #26,!217Sprint #26
......@@ -34,7 +34,14 @@ const CustomHeader = ({
</Header>
)
const ContextualBox = ({ label, children, rightChildren, ...props }) =>
const ContextualBox = ({
label,
children,
rightChildren,
toggle,
expanded,
...props
}) =>
!isUndefined(props.expanded) ? (
<ControlledAccordion
header={CustomHeader}
......@@ -75,8 +82,8 @@ ContextualBox.propTypes = {
ContextualBox.defaultProps = {
label: '',
rightChildren: undefined,
expanded: false,
toggle: () => {},
toggle: undefined,
expanded: undefined,
}
// #region styles
......
......@@ -28,7 +28,6 @@ const EditorialReportCard = ({
<Label mb={1 / 2}>
{editorRole === 'HE' ? 'Recommendation' : 'Decision'}
</Label>
)
<Text>{recommendation}</Text>
</Item>
......
......@@ -368,10 +368,8 @@ export default compose(
fetchUpdatedCollection,
editorialRecommendations,
fragment,
collection: { status },
currentUser: {
isEIC,
isReviewer,
isInvitedHE,
isInvitedToReview,
isHEToManuscript,
......@@ -398,15 +396,6 @@ export default compose(
setEditorInChief(head(res.users)),
)
if (isEIC && status === 'pendingApproval') {
this.props.toggleEicDecision()
}
if (isReviewer && status === 'reviewCompleted')
this.props.toggleReviewReport()
if (isHEToManuscript && status === 'reviewCompleted')
this.props.toggleHERecommentation()
if (canInviteReviewers) {
getPublonsReviewers(fragmentId, setError)
}
......
......@@ -17,7 +17,6 @@ const SubmittedReports = ({ reports }) => (
{reports}
</Text>
<Text mr={1 / 2} pr={1 / 2} secondary>
{' '}
submitted
</Text>
</Row>
......
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