Skip to content

Commit 935f2ec

Browse files
committed
Revert "temp: Remove warning from Create Legacy Library page"
This reverts commit 8ddb6aa.
1 parent 106f22b commit 935f2ec

2 files changed

Lines changed: 16 additions & 0 deletions

File tree

src/library-authoring/create-legacy-library/CreateLegacyLibrary.tsx

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,14 @@ import { StudioFooterSlot } from '@edx/frontend-component-footer';
22
import { getConfig } from '@edx/frontend-platform';
33
import { useIntl } from '@edx/frontend-platform/i18n';
44
import {
5+
Alert,
56
Container,
67
Form,
78
Button,
89
StatefulButton,
910
ActionRow,
1011
} from '@openedx/paragon';
12+
import { Warning } from '@openedx/paragon/icons';
1113
import { Formik } from 'formik';
1214
import { useNavigate } from 'react-router-dom';
1315
import * as Yup from 'yup';
@@ -100,6 +102,10 @@ export const CreateLegacyLibrary = ({
100102
title={intl.formatMessage(legacyMessages.createLibrary)}
101103
/>
102104
)}
105+
<Alert variant="warning" icon={Warning}>
106+
<Alert.Heading>{intl.formatMessage(legacyMessages.warningTitle)}</Alert.Heading>
107+
{intl.formatMessage(legacyMessages.warningBody)}
108+
</Alert>
103109
<Formik
104110
initialValues={{
105111
displayName: '',

src/library-authoring/create-legacy-library/messages.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,16 @@ const messages = defineMessages({
1111
defaultMessage: 'Legacy library name',
1212
description: 'Label for the title field when creating a legacy library.',
1313
},
14+
warningTitle: {
15+
id: 'course-authoring.library-authoring.create-legacy-library.warning.title',
16+
defaultMessage: 'You are creating content in a deprecated format',
17+
description: 'Warning to discourage users from creating a new Legacy Library',
18+
},
19+
warningBody: {
20+
id: 'course-authoring.library-authoring.create-legacy-library.warning.body',
21+
defaultMessage: 'Legacy libraries will be unsupported in a future release. Any content you create in a legacy library will soon need to be migrated. Consider using the Libraries (Beta) feature instead.',
22+
description: 'Warning to discourage users from creating a new Legacy Library',
23+
},
1424
createLibraryButton: {
1525
id: 'course-authoring.library-authoring.create-legacy-library.form.create-library.button',
1626
defaultMessage: 'Create legacy library',

0 commit comments

Comments
 (0)