Skip to content
This repository has been archived by the owner on Oct 27, 2022. It is now read-only.

Commit

Permalink
Update texts (#1226)
Browse files Browse the repository at this point in the history
Co-authored-by: Fredrik Strand Oseberg <fredrik.no@gmail.com>
  • Loading branch information
sjaanus and FredrikOseberg committed Aug 22, 2022
1 parent 80a9536 commit 6e9596e
Showing 1 changed file with 11 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ const StyledDeleteParagraph = styled('p')(({ theme }) => ({

const StyledFormInput = styled(Input)(({ theme }) => ({
marginTop: theme.spacing(2),
width: '100%',
}));

export const ArchivedFeatureDeleteConfirm = ({
Expand All @@ -41,7 +42,7 @@ export const ArchivedFeatureDeleteConfirm = ({
await refetch();
setToastData({
type: 'success',
title: 'Feature deleted',
title: 'Feature toggle deleted',
text: `You have successfully deleted the ${deletedFeature.name} feature toggle.`,
});
} catch (error: unknown) {
Expand All @@ -60,7 +61,7 @@ export const ArchivedFeatureDeleteConfirm = ({

return (
<Dialogue
title="Are you sure you want to delete this feature toggle?"
title="Delete feature toggle?"
open={open}
primaryButtonText="Delete feature toggle"
secondaryButtonText="Cancel"
Expand All @@ -70,15 +71,16 @@ export const ArchivedFeatureDeleteConfirm = ({
formId={formId}
>
<Alert severity="warning">
Warning! To safely delete a feature toggle you might want to
delete the related code in your application first. This ensures
you avoid any errors in case you create a new feature toggle
with the same name in the future.
<b>Warning!</b> Before you delete a feature toggle, make sure
all in-code references to that feature toggle have been removed.
Otherwise, a new feature toggle with the same name could
activate the old code paths.
</Alert>

<StyledDeleteParagraph>
In order to delete this feature toggle, please enter the name of
the toggle in the textfield below:{' '}
In order to delete this feature toggle, please enter its name in
the text field below:
<br />
<strong>{deletedFeature?.name}</strong>
</StyledDeleteParagraph>

Expand All @@ -89,6 +91,7 @@ export const ArchivedFeatureDeleteConfirm = ({
setConfirmName(e.currentTarget.value);
}}
value={confirmName}
placeholder="<feature toggle name>"
label="Feature toggle name"
/>
</form>
Expand Down

0 comments on commit 6e9596e

Please sign in to comment.