forked from HHS/TANF-app
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Add css class for reprocessed modal
- Add ReprocessedModal component - Use new component for submission history tables
- Loading branch information
Showing
5 changed files
with
81 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
46 changes: 46 additions & 0 deletions
46
tdrs-frontend/src/components/SubmissionHistory/ReprocessedModal.jsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
import React, { useState } from 'react' | ||
import Modal from '../Modal' | ||
|
||
const Message = ({ date }) => { | ||
return ( | ||
<> | ||
We've reprocessed your submission with updated validation criteria, based | ||
on system improvements, to improve accuracy of error reports. No changes | ||
have been made to your original data submission. | ||
<br /> | ||
<br /> | ||
Data was reprocessed on: {date} | ||
</> | ||
) | ||
} | ||
|
||
const ReprocessedModal = ({ date }) => { | ||
const [modalVisible, setModalVisible] = useState(false) | ||
const message = <Message date={date} /> | ||
return ( | ||
<div> | ||
<br /> | ||
<button className="reprocessed" onClick={() => setModalVisible(true)}> | ||
Reprocessed <span>ⓘ</span> | ||
</button> | ||
<br /> | ||
<br /> | ||
<Modal | ||
title="Most Recent Reprocessed Date" | ||
message={message} | ||
isVisible={modalVisible} | ||
buttons={[ | ||
{ | ||
key: '1', | ||
text: 'Close', | ||
onClick: () => { | ||
setModalVisible(false) | ||
}, | ||
}, | ||
]} | ||
/> | ||
</div> | ||
) | ||
} | ||
|
||
export default ReprocessedModal |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters