Skip to content

Commit

Permalink
chore: Remove close tab option (#2983)
Browse files Browse the repository at this point in the history
  • Loading branch information
DafyddLlyr authored Apr 5, 2024
1 parent ad82ee3 commit 1fae3a7
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 8 deletions.
9 changes: 4 additions & 5 deletions editor.planx.uk/src/pages/Preview/ResumePage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -109,14 +109,13 @@ export const EmailError: React.FC<{ retry: () => void }> = ({ retry }) => {

export const EmailSuccess: React.FC = () => {
return (
<StatusPage
bannerHeading="Check your email"
buttonText="Close Tab"
onButtonClick={() => window.close()}
>
<StatusPage bannerHeading="Check your email">
<Typography variant="body1">
If you have any draft applications we have sent you an email that
contains a link. Use this link to access your applications.
<br />
<br />
You may now close this tab.
</Typography>
</StatusPage>
);
Expand Down
9 changes: 6 additions & 3 deletions editor.planx.uk/src/pages/Preview/SavePage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import { add } from "date-fns";
import { useStore } from "pages/FlowEditor/lib/store";
import React, { useEffect, useState } from "react";
import { SendEmailPayload } from "types";
import { removeSessionIdSearchParam } from "utils";

import StatusPage from "./StatusPage";

Expand All @@ -21,9 +22,8 @@ export const SaveSuccess: React.FC<{
<StatusPage
bannerHeading="Application saved"
showDownloadLink
buttonText="Close tab"
onButtonClick={() => window.close()}
additionalOption="startNewApplication"
buttonText="Start a new application"
onButtonClick={removeSessionIdSearchParam}
>
<Typography variant="body2">
We have sent a link to {saveToEmail}. Use the link to continue your
Expand All @@ -34,6 +34,9 @@ export const SaveSuccess: React.FC<{
<br />
<br />
Your application will be deleted if you do not complete it by this date.
<br />
<br />
You may now close this tab.
</Typography>
</StatusPage>
);
Expand Down

0 comments on commit 1fae3a7

Please sign in to comment.