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

feat(deleteManuscriptModal): Update modal for deleting a manuscript.

parent 246bb06e
No related branches found
No related tags found
3 merge requests!222Sprint #26,!217Sprint #26,!198Hin 1166 admin delete manuscript
...@@ -23,10 +23,19 @@ const Form = compose( ...@@ -23,10 +23,19 @@ const Form = compose(
}), }),
)(({ fetchingError, hideModal, handleSubmit, isFetching }) => ( )(({ fetchingError, hideModal, handleSubmit, isFetching }) => (
<Root> <Root>
<IconButton icon="x" onClick={hideModal} right={5} secondary top={5} /> <IconButton
<H2>Are you sure you want to remove this manuscript?</H2> icon="x"
iconSize={2}
onClick={hideModal}
right={5}
secondary
top={5}
/>
<H2 ml={4} mr={4}>
Are you sure you want to remove this manuscript?
</H2>
<Row mt={1}> <Row mt={2}>
<ItemOverrideAlert data-test-id="manuscript-return-reason" vertical> <ItemOverrideAlert data-test-id="manuscript-return-reason" vertical>
<Label required> <Label required>
Reason for removing the manuscript from the platform: Reason for removing the manuscript from the platform:
...@@ -34,6 +43,7 @@ const Form = compose( ...@@ -34,6 +43,7 @@ const Form = compose(
<ValidatedField <ValidatedField
component={TextArea} component={TextArea}
name="comments" name="comments"
style={{ 'max-width': '440px', 'min-width': '440px' }}
validate={[required]} validate={[required]}
/> />
</ItemOverrideAlert> </ItemOverrideAlert>
...@@ -43,7 +53,7 @@ const Form = compose( ...@@ -43,7 +53,7 @@ const Form = compose(
{fetchingError} {fetchingError}
</Text> </Text>
)} )}
<Row mt={1}> <Row mt={3}>
{isFetching ? ( {isFetching ? (
<Spinner size={3} /> <Spinner size={3} />
) : ( ) : (
...@@ -52,7 +62,7 @@ const Form = compose( ...@@ -52,7 +62,7 @@ const Form = compose(
NO NO
</Button> </Button>
<Button data-test-id="modal-confirm" onClick={handleSubmit} primary> <Button data-test-id="modal-confirm" onClick={handleSubmit} primary>
YES OK
</Button> </Button>
</Fragment> </Fragment>
)} )}
...@@ -87,18 +97,17 @@ DeleteManuscriptModal.defaultProps = { ...@@ -87,18 +97,17 @@ DeleteManuscriptModal.defaultProps = {
const DeleteIcon = styled(ActionLink)`` const DeleteIcon = styled(ActionLink)``
const Root = styled.div` const Root = styled.div`
align-items: center; align-items: center;
background: ${th('colorBackground')}; background: ${th('colorBackgroundHue')};
border: ${th('borderWidth')} ${th('borderStyle')} transparent; border: ${th('borderWidth')} ${th('borderStyle')} transparent;
border-radius: ${th('borderRadius')}; border-radius: ${th('borderRadius')};
box-shadow: ${th('boxShadow')}; box-shadow: ${th('boxShadow')};
display: flex; display: flex;
flex-direction: column; flex-direction: column;
position: relative; position: relative;
padding: calc(${th('gridUnit')} * 3); padding: calc(${th('gridUnit')} * 5);
width: calc(${th('gridUnit')} * 60); width: calc(${th('gridUnit')} * 65);
${H2} { ${H2} {
margin: 0;
text-align: center; text-align: center;
} }
` `
......
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