@strapi/admin 4.1.10-beta.0 → 4.1.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/admin/src/assets/images/homepage-logo.png +0 -0
- package/admin/src/components/AutoReloadOverlayBlockerProvider/Blocker.js +2 -6
- package/admin/src/components/GuidedTour/Homepage/index.js +1 -2
- package/admin/src/components/GuidedTour/Modal/components/Stepper.js +1 -2
- package/admin/src/components/LeftMenu/index.js +9 -9
- package/admin/src/components/Notifications/Notification/index.js +2 -2
- package/admin/src/components/Providers/index.js +4 -8
- package/admin/src/components/UnauthenticatedLogo/index.js +2 -4
- package/admin/src/components/UpgradePlanModal/index.js +6 -2
- package/admin/src/content-manager/components/SelectMany/ListItem.js +1 -2
- package/admin/src/content-manager/components/SelectWrapper/index.js +8 -7
- package/admin/src/content-manager/components/SingleTypeFormWrapper/index.js +2 -2
- package/admin/src/content-manager/components/Wysiwyg/Editor.js +2 -0
- package/admin/src/content-manager/pages/App/LeftMenu/index.js +8 -7
- package/admin/src/content-manager/pages/EditSettingsView/components/ComponentFieldList.js +1 -1
- package/admin/src/content-manager/pages/EditSettingsView/components/LinkToCTB.js +1 -2
- package/admin/src/content-manager/pages/EditSettingsView/index.js +1 -2
- package/admin/src/content-manager/pages/EditView/Header/index.js +3 -3
- package/admin/src/content-manager/pages/EditView/index.js +1 -4
- package/admin/src/content-manager/pages/ListSettingsView/index.js +1 -2
- package/admin/src/content-manager/pages/ListView/index.js +1 -1
- package/admin/src/content-manager/pages/NoContentType/index.js +1 -2
- package/admin/src/pages/App/index.js +2 -7
- package/admin/src/pages/AuthPage/components/ForgotPassword/index.js +1 -2
- package/admin/src/pages/AuthPage/components/ForgotPasswordSuccess/index.js +1 -1
- package/admin/src/pages/AuthPage/components/Login/BaseLogin.js +1 -2
- package/admin/src/pages/AuthPage/components/Oops/index.js +1 -2
- package/admin/src/pages/AuthPage/components/Register/index.js +12 -12
- package/admin/src/pages/AuthPage/components/ResetPassword/index.js +3 -4
- package/admin/src/pages/HomePage/HomeHeader.js +2 -2
- package/admin/src/pages/HomePage/SocialLinks.js +4 -3
- package/admin/src/pages/InternalErrorPage/index.js +1 -2
- package/admin/src/pages/MarketplacePage/components/PageHeader/index.js +2 -1
- package/admin/src/pages/MarketplacePage/components/PluginCard/index.js +4 -3
- package/admin/src/pages/NotFoundPage/index.js +1 -2
- package/admin/src/pages/SettingsPage/components/SettingsNav/index.js +5 -4
- package/admin/src/pages/SettingsPage/pages/ApiTokens/EditView/index.js +1 -1
- package/admin/src/pages/SettingsPage/pages/ApiTokens/ListView/DynamicTable/UpdateButton/index.js +1 -1
- package/admin/src/pages/SettingsPage/pages/ApiTokens/ListView/index.js +1 -1
- package/admin/src/pages/SettingsPage/pages/ApplicationInfosPage/index.js +94 -150
- package/admin/src/pages/SettingsPage/pages/Roles/EditPage/index.js +1 -1
- package/admin/src/pages/SettingsPage/pages/Users/EditPage/index.js +1 -1
- package/admin/src/pages/SettingsPage/pages/Webhooks/EditView/components/WebhookForm/index.js +1 -2
- package/admin/src/pages/SettingsPage/pages/Webhooks/ListView/index.js +1 -1
- package/admin/src/translations/ca.json +699 -0
- package/admin/src/translations/en.json +0 -25
- package/admin/src/translations/languageNativeNames.js +1 -0
- package/admin/src/translations/ru.json +34 -0
- package/build/2077.51485bfb.chunk.js +194 -0
- package/build/6706.7f57cb76.chunk.js +113 -0
- package/build/7589.95466f9a.chunk.js +194 -0
- package/build/{5289.0341db2d.chunk.js → 7757.6d20cfe0.chunk.js} +89 -87
- package/build/8681.96961454.chunk.js +163 -0
- package/build/9066.118ecccd.chunk.js +101 -0
- package/build/9115.abdf4e3b.chunk.js +1 -0
- package/build/9158.60fcd720.chunk.js +503 -0
- package/build/{9298.f97fcef0.chunk.js → 9298.5b5c6ea1.chunk.js} +2 -2
- package/build/9420.cb0b75e8.chunk.js +508 -0
- package/build/Admin-authenticatedApp.ec0f0834.chunk.js +80 -0
- package/build/Admin_homePage.e6d4d977.chunk.js +71 -0
- package/build/Admin_marketplace.25133b64.chunk.js +11 -0
- package/build/Admin_settingsPage.e1dfbb1d.chunk.js +172 -0
- package/build/admin-edit-roles-page.e77a2acc.chunk.js +1 -0
- package/build/admin-edit-users.4c49fe98.chunk.js +11 -0
- package/build/api-tokens-create-page.618b3e40.chunk.js +1 -0
- package/build/api-tokens-edit-page.8d19dfe1.chunk.js +1 -0
- package/build/api-tokens-list-page.274e1c80.chunk.js +15 -0
- package/build/ca-json.0097e443.chunk.js +1 -0
- package/build/content-manager.d6449678.chunk.js +1204 -0
- package/build/{content-type-builder.0d8729ad.chunk.js → content-type-builder.a9554707.chunk.js} +8 -8
- package/build/en-json.3e1a222e.chunk.js +1 -0
- package/build/fb376b132d18bf4522ca.png +0 -0
- package/build/index.html +1 -1
- package/build/main.6dad6108.js +8404 -0
- package/build/ru-json.28147733.chunk.js +1 -0
- package/build/runtime~main.26528011.js +2 -0
- package/build/users-roles-settings-page.28bf6bdc.chunk.js +30 -0
- package/build/{webhook-edit-page.2e6727ab.chunk.js → webhook-edit-page.ca670f8d.chunk.js} +3 -3
- package/build/webhook-list-page.ce1fa92f.chunk.js +133 -0
- package/ee/admin/pages/AuthPage/components/Providers/index.js +1 -1
- package/ee/admin/pages/SettingsPage/pages/Roles/CreatePage/index.js +1 -1
- package/package.json +5 -5
- package/server/config/admin-actions.js +0 -14
- package/server/controllers/admin.js +1 -33
- package/server/routes/admin.js +0 -28
- package/server/services/index.js +0 -1
- package/server/services/permission/permissions-manager/sanitize.js +22 -0
- package/server/services/user.js +1 -1
- package/server/utils/index.d.ts +0 -2
- package/admin/src/components/ConfigurationsProvider/index.js +0 -51
- package/admin/src/components/ConfigurationsProvider/reducer.js +0 -28
- package/admin/src/pages/SettingsPage/pages/ApplicationInfosPage/components/Form/index.js +0 -85
- package/admin/src/pages/SettingsPage/pages/ApplicationInfosPage/components/Form/init.js +0 -13
- package/admin/src/pages/SettingsPage/pages/ApplicationInfosPage/components/Form/reducer.js +0 -43
- package/admin/src/pages/SettingsPage/pages/ApplicationInfosPage/components/LogoInput/index.js +0 -116
- package/admin/src/pages/SettingsPage/pages/ApplicationInfosPage/components/LogoInput/reducer.js +0 -28
- package/admin/src/pages/SettingsPage/pages/ApplicationInfosPage/components/LogoInput/stepper.js +0 -25
- package/admin/src/pages/SettingsPage/pages/ApplicationInfosPage/components/LogoModalStepper/AddLogoDialog.js +0 -67
- package/admin/src/pages/SettingsPage/pages/ApplicationInfosPage/components/LogoModalStepper/FromComputerForm.js +0 -176
- package/admin/src/pages/SettingsPage/pages/ApplicationInfosPage/components/LogoModalStepper/FromUrlForm.js +0 -82
- package/admin/src/pages/SettingsPage/pages/ApplicationInfosPage/components/LogoModalStepper/ImageCardAsset.js +0 -51
- package/admin/src/pages/SettingsPage/pages/ApplicationInfosPage/components/LogoModalStepper/PendingLogoDialog.js +0 -97
- package/admin/src/pages/SettingsPage/pages/ApplicationInfosPage/components/LogoModalStepper/index.js +0 -85
- package/admin/src/pages/SettingsPage/pages/ApplicationInfosPage/components/LogoModalStepper/reducer.js +0 -28
- package/admin/src/pages/SettingsPage/pages/ApplicationInfosPage/utils/api.js +0 -16
- package/admin/src/pages/SettingsPage/pages/ApplicationInfosPage/utils/constants.js +0 -3
- package/admin/src/pages/SettingsPage/pages/ApplicationInfosPage/utils/getFormData.js +0 -17
- package/admin/src/pages/SettingsPage/pages/ApplicationInfosPage/utils/parseFileMetadatas.js +0 -76
- package/admin/src/pages/SettingsPage/pages/ApplicationInfosPage/utils/prefixAllUrls.js +0 -17
- package/admin/src/pages/SettingsPage/pages/ApplicationInfosPage/utils/urlToFile.js +0 -21
- package/build/2481.7ba28142.chunk.js +0 -184
- package/build/2a9e9ef5c4c775bb7c7b.png +0 -0
- package/build/372.3720845e.chunk.js +0 -899
- package/build/497.fbd75558.chunk.js +0 -284
- package/build/6404.80bf5858.chunk.js +0 -506
- package/build/7197.959bbe97.chunk.js +0 -113
- package/build/7589.f3b26345.chunk.js +0 -194
- package/build/9115.318a6841.chunk.js +0 -1
- package/build/9853.d96fbc67.chunk.js +0 -356
- package/build/Admin-authenticatedApp.d8767873.chunk.js +0 -80
- package/build/Admin_homePage.50b6c129.chunk.js +0 -71
- package/build/Admin_marketplace.514ace37.chunk.js +0 -11
- package/build/Admin_settingsPage.0d94a598.chunk.js +0 -180
- package/build/admin-edit-roles-page.06f3d288.chunk.js +0 -1
- package/build/admin-edit-users.6a325cca.chunk.js +0 -11
- package/build/api-tokens-create-page.635e20c8.chunk.js +0 -1
- package/build/api-tokens-edit-page.db07253e.chunk.js +0 -1
- package/build/api-tokens-list-page.346c2149.chunk.js +0 -15
- package/build/content-manager.78e3f35c.chunk.js +0 -1204
- package/build/en-json.ca572384.chunk.js +0 -1
- package/build/main.06f66609.js +0 -7909
- package/build/ru-json.4560906c.chunk.js +0 -1
- package/build/runtime~main.dc1c7ef6.js +0 -2
- package/build/users-roles-settings-page.97d7092d.chunk.js +0 -30
- package/build/webhook-list-page.927257b5.chunk.js +0 -133
- package/server/services/project-settings.js +0 -173
- package/server/validation/project-settings.js +0 -39
|
@@ -3,7 +3,7 @@ import styled from 'styled-components';
|
|
|
3
3
|
import PropTypes from 'prop-types';
|
|
4
4
|
import { useIntl } from 'react-intl';
|
|
5
5
|
import { Typography } from '@strapi/design-system/Typography';
|
|
6
|
-
import { Link } from '@strapi/design-system/Link';
|
|
6
|
+
import { Link } from '@strapi/design-system/v2/Link';
|
|
7
7
|
import { Stack } from '@strapi/design-system/Stack';
|
|
8
8
|
import { Box } from '@strapi/design-system/Box';
|
|
9
9
|
import { Button } from '@strapi/design-system/Button';
|
|
@@ -49,7 +49,7 @@ const HomeHeader = ({ hasCreatedContentType, onCreateCT }) => {
|
|
|
49
49
|
})}
|
|
50
50
|
</WordWrap>
|
|
51
51
|
{hasCreatedContentType ? (
|
|
52
|
-
<Link href="https://strapi.io/blog">
|
|
52
|
+
<Link isExternal href="https://strapi.io/blog">
|
|
53
53
|
{formatMessage({
|
|
54
54
|
id: 'app.components.HomePage.button.blog',
|
|
55
55
|
defaultMessage: 'See more on the blog',
|
|
@@ -10,8 +10,8 @@ import { Typography } from '@strapi/design-system/Typography';
|
|
|
10
10
|
import { Box } from '@strapi/design-system/Box';
|
|
11
11
|
import { Stack } from '@strapi/design-system/Stack';
|
|
12
12
|
import { Grid, GridItem } from '@strapi/design-system/Grid';
|
|
13
|
-
import { LinkButton } from '@strapi/design-system/LinkButton';
|
|
14
|
-
import { Link } from '@strapi/design-system/Link';
|
|
13
|
+
import { LinkButton } from '@strapi/design-system/v2/LinkButton';
|
|
14
|
+
import { Link } from '@strapi/design-system/v2/Link';
|
|
15
15
|
import ExternalLink from '@strapi/icons/ExternalLink';
|
|
16
16
|
import Github from '@strapi/icons/Github';
|
|
17
17
|
import Discord from '@strapi/icons/Discord';
|
|
@@ -167,7 +167,7 @@ const SocialLinks = () => {
|
|
|
167
167
|
})}
|
|
168
168
|
</Typography>
|
|
169
169
|
</Stack>
|
|
170
|
-
<Link href="https://feedback.strapi.io/" endIcon={<ExternalLink />}>
|
|
170
|
+
<Link href="https://feedback.strapi.io/" isExternal endIcon={<ExternalLink />}>
|
|
171
171
|
{formatMessage({
|
|
172
172
|
id: 'app.components.HomePage.roadmap',
|
|
173
173
|
defaultMessage: 'See our road map',
|
|
@@ -184,6 +184,7 @@ const SocialLinks = () => {
|
|
|
184
184
|
startIcon={socialLink.icon}
|
|
185
185
|
variant="tertiary"
|
|
186
186
|
href={socialLink.link}
|
|
187
|
+
isExternal
|
|
187
188
|
>
|
|
188
189
|
{socialLink.name}
|
|
189
190
|
</LinkCustom>
|
|
@@ -5,9 +5,8 @@
|
|
|
5
5
|
*
|
|
6
6
|
*/
|
|
7
7
|
import React from 'react';
|
|
8
|
-
import { useFocusWhenNavigate } from '@strapi/helper-plugin';
|
|
8
|
+
import { useFocusWhenNavigate, LinkButton } from '@strapi/helper-plugin';
|
|
9
9
|
import { Main } from '@strapi/design-system/Main';
|
|
10
|
-
import { LinkButton } from '@strapi/design-system/LinkButton';
|
|
11
10
|
import { ContentLayout, HeaderLayout } from '@strapi/design-system/Layout';
|
|
12
11
|
import { EmptyStateLayout } from '@strapi/design-system/EmptyStateLayout';
|
|
13
12
|
import EmptyPictures from '@strapi/icons/EmptyPictures';
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import PropTypes from 'prop-types';
|
|
3
3
|
import { useIntl } from 'react-intl';
|
|
4
4
|
import { HeaderLayout } from '@strapi/design-system/Layout';
|
|
5
|
-
import { LinkButton } from '@strapi/design-system/LinkButton';
|
|
5
|
+
import { LinkButton } from '@strapi/design-system/v2/LinkButton';
|
|
6
6
|
import Upload from '@strapi/icons/Upload';
|
|
7
7
|
import { useTracking } from '@strapi/helper-plugin';
|
|
8
8
|
|
|
@@ -27,6 +27,7 @@ const PageHeader = ({ isOnline }) => {
|
|
|
27
27
|
variant="tertiary"
|
|
28
28
|
href="https://market.strapi.io/submit-plugin"
|
|
29
29
|
onClick={() => trackUsage('didSubmitPlugin')}
|
|
30
|
+
isExternal
|
|
30
31
|
>
|
|
31
32
|
{formatMessage({
|
|
32
33
|
id: 'admin.pages.MarketPlacePage.submit.plugin.link',
|
|
@@ -5,7 +5,7 @@ import styled from 'styled-components';
|
|
|
5
5
|
import { Box } from '@strapi/design-system/Box';
|
|
6
6
|
import { Stack } from '@strapi/design-system/Stack';
|
|
7
7
|
import { Typography } from '@strapi/design-system/Typography';
|
|
8
|
-
import { LinkButton } from '@strapi/design-system/LinkButton';
|
|
8
|
+
import { LinkButton } from '@strapi/design-system/v2/LinkButton';
|
|
9
9
|
import { Flex } from '@strapi/design-system/Flex';
|
|
10
10
|
import { Icon } from '@strapi/design-system/Icon';
|
|
11
11
|
import { Tooltip } from '@strapi/design-system/Tooltip';
|
|
@@ -46,9 +46,9 @@ const PluginCard = ({ plugin, installedPluginNames, useYarn, isInDevelopmentMode
|
|
|
46
46
|
direction="column"
|
|
47
47
|
justifyContent="space-between"
|
|
48
48
|
paddingTop={4}
|
|
49
|
-
paddingRight={
|
|
49
|
+
paddingRight={4}
|
|
50
50
|
paddingBottom={4}
|
|
51
|
-
paddingLeft={
|
|
51
|
+
paddingLeft={4}
|
|
52
52
|
hasRadius
|
|
53
53
|
background="neutral0"
|
|
54
54
|
shadow="tableShadow"
|
|
@@ -108,6 +108,7 @@ const PluginCard = ({ plugin, installedPluginNames, useYarn, isInDevelopmentMode
|
|
|
108
108
|
<LinkButton
|
|
109
109
|
size="S"
|
|
110
110
|
href={`https://market.strapi.io/plugins/${attributes.slug}`}
|
|
111
|
+
isExternal
|
|
111
112
|
endIcon={<ExternalLink />}
|
|
112
113
|
aria-label={formatMessage(
|
|
113
114
|
{
|
|
@@ -5,9 +5,8 @@
|
|
|
5
5
|
*
|
|
6
6
|
*/
|
|
7
7
|
import React from 'react';
|
|
8
|
-
import { useFocusWhenNavigate } from '@strapi/helper-plugin';
|
|
8
|
+
import { useFocusWhenNavigate, LinkButton } from '@strapi/helper-plugin';
|
|
9
9
|
import { Main } from '@strapi/design-system/Main';
|
|
10
|
-
import { LinkButton } from '@strapi/design-system/LinkButton';
|
|
11
10
|
import { ContentLayout, HeaderLayout } from '@strapi/design-system/Layout';
|
|
12
11
|
import { EmptyStateLayout } from '@strapi/design-system/EmptyStateLayout';
|
|
13
12
|
import EmptyPictures from '@strapi/icons/EmptyPictures';
|
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
+
import { NavLink } from 'react-router-dom';
|
|
3
|
+
import { useIntl } from 'react-intl';
|
|
4
|
+
import PropTypes from 'prop-types';
|
|
2
5
|
import {
|
|
3
6
|
SubNav,
|
|
4
7
|
SubNavHeader,
|
|
5
8
|
SubNavSection,
|
|
6
9
|
SubNavSections,
|
|
7
10
|
SubNavLink,
|
|
8
|
-
} from '@strapi/design-system/SubNav';
|
|
9
|
-
import { useIntl } from 'react-intl';
|
|
10
|
-
import PropTypes from 'prop-types';
|
|
11
|
+
} from '@strapi/design-system/v2/SubNav';
|
|
11
12
|
import { getSectionsToDisplay } from '../../utils';
|
|
12
13
|
|
|
13
14
|
const SettingsNav = ({ menu }) => {
|
|
@@ -41,7 +42,7 @@ const SettingsNav = ({ menu }) => {
|
|
|
41
42
|
{sections.map(section => (
|
|
42
43
|
<SubNavSection key={section.id} label={formatMessage(section.intlLabel)}>
|
|
43
44
|
{section.links.map(link => (
|
|
44
|
-
<SubNavLink withBullet={link.hasNotification} to={link.to} key={link.id}>
|
|
45
|
+
<SubNavLink as={NavLink} withBullet={link.hasNotification} to={link.to} key={link.id}>
|
|
45
46
|
{formatMessage(link.intlLabel)}
|
|
46
47
|
</SubNavLink>
|
|
47
48
|
))}
|
|
@@ -8,13 +8,13 @@ import {
|
|
|
8
8
|
useNotification,
|
|
9
9
|
useTracking,
|
|
10
10
|
useGuidedTour,
|
|
11
|
+
Link,
|
|
11
12
|
} from '@strapi/helper-plugin';
|
|
12
13
|
import { HeaderLayout, ContentLayout } from '@strapi/design-system/Layout';
|
|
13
14
|
import { Main } from '@strapi/design-system/Main';
|
|
14
15
|
import { Button } from '@strapi/design-system/Button';
|
|
15
16
|
import Check from '@strapi/icons/Check';
|
|
16
17
|
import ArrowLeft from '@strapi/icons/ArrowLeft';
|
|
17
|
-
import { Link } from '@strapi/design-system/Link';
|
|
18
18
|
import { Formik } from 'formik';
|
|
19
19
|
import { Stack } from '@strapi/design-system/Stack';
|
|
20
20
|
import { Box } from '@strapi/design-system/Box';
|
package/admin/src/pages/SettingsPage/pages/ApiTokens/ListView/DynamicTable/UpdateButton/index.js
CHANGED
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import Pencil from '@strapi/icons/Pencil';
|
|
3
3
|
import { useIntl } from 'react-intl';
|
|
4
4
|
import PropTypes from 'prop-types';
|
|
5
|
-
import { Link } from '@strapi/
|
|
5
|
+
import { Link } from '@strapi/helper-plugin';
|
|
6
6
|
import { useHistory } from 'react-router-dom';
|
|
7
7
|
import styled from 'styled-components';
|
|
8
8
|
|
|
@@ -10,11 +10,11 @@ import {
|
|
|
10
10
|
DynamicTable,
|
|
11
11
|
useTracking,
|
|
12
12
|
useGuidedTour,
|
|
13
|
+
LinkButton,
|
|
13
14
|
} from '@strapi/helper-plugin';
|
|
14
15
|
import { HeaderLayout, ContentLayout } from '@strapi/design-system/Layout';
|
|
15
16
|
import { Main } from '@strapi/design-system/Main';
|
|
16
17
|
import { Button } from '@strapi/design-system/Button';
|
|
17
|
-
import { LinkButton } from '@strapi/design-system/LinkButton';
|
|
18
18
|
import Plus from '@strapi/icons/Plus';
|
|
19
19
|
import { useQuery, useMutation, useQueryClient } from 'react-query';
|
|
20
20
|
import { useHistory } from 'react-router-dom';
|
|
@@ -1,76 +1,26 @@
|
|
|
1
|
-
import React
|
|
2
|
-
import { useQuery, useMutation, useQueryClient } from 'react-query';
|
|
1
|
+
import React from 'react';
|
|
3
2
|
import { useIntl } from 'react-intl';
|
|
4
|
-
import {
|
|
5
|
-
useAppInfos,
|
|
6
|
-
SettingsPageTitle,
|
|
7
|
-
useFocusWhenNavigate,
|
|
8
|
-
CheckPermissions,
|
|
9
|
-
useNotification,
|
|
10
|
-
useTracking,
|
|
11
|
-
} from '@strapi/helper-plugin';
|
|
3
|
+
import { useAppInfos, SettingsPageTitle, useFocusWhenNavigate } from '@strapi/helper-plugin';
|
|
12
4
|
import { HeaderLayout, Layout, ContentLayout } from '@strapi/design-system/Layout';
|
|
13
5
|
import { Main } from '@strapi/design-system/Main';
|
|
14
6
|
import { Box } from '@strapi/design-system/Box';
|
|
15
7
|
import { Grid, GridItem } from '@strapi/design-system/Grid';
|
|
16
8
|
import { Typography } from '@strapi/design-system/Typography';
|
|
9
|
+
|
|
17
10
|
import { Stack } from '@strapi/design-system/Stack';
|
|
18
|
-
import { Link } from '@strapi/design-system/Link';
|
|
19
|
-
import { Button } from '@strapi/design-system/Button';
|
|
11
|
+
import { Link } from '@strapi/design-system/v2/Link';
|
|
20
12
|
import ExternalLink from '@strapi/icons/ExternalLink';
|
|
21
|
-
import Check from '@strapi/icons/Check';
|
|
22
|
-
import { useConfigurations } from '../../../../hooks';
|
|
23
|
-
import Form from './components/Form';
|
|
24
|
-
import { fetchProjectSettings, postProjectSettings } from './utils/api';
|
|
25
|
-
import getFormData from './utils/getFormData';
|
|
26
|
-
|
|
27
|
-
const permissions = [{ action: 'admin::project-settings.update', subject: null }];
|
|
28
13
|
|
|
29
14
|
const ApplicationInfosPage = () => {
|
|
30
|
-
const inputsRef = useRef();
|
|
31
|
-
const toggleNotification = useNotification();
|
|
32
|
-
const { trackUsage } = useTracking();
|
|
33
15
|
const { formatMessage } = useIntl();
|
|
34
|
-
const queryClient = useQueryClient();
|
|
35
16
|
useFocusWhenNavigate();
|
|
36
17
|
const appInfos = useAppInfos();
|
|
37
18
|
const { shouldUpdateStrapi, latestStrapiReleaseTag, strapiVersion } = appInfos;
|
|
38
|
-
const { updateProjectSettings } = useConfigurations();
|
|
39
|
-
|
|
40
|
-
const { data } = useQuery('project-settings', fetchProjectSettings);
|
|
41
19
|
|
|
42
20
|
const currentPlan = appInfos.communityEdition
|
|
43
21
|
? 'app.components.UpgradePlanModal.text-ce'
|
|
44
22
|
: 'app.components.UpgradePlanModal.text-ee';
|
|
45
23
|
|
|
46
|
-
const submitMutation = useMutation(body => postProjectSettings(body), {
|
|
47
|
-
onSuccess: async ({ menuLogo }) => {
|
|
48
|
-
await queryClient.invalidateQueries('project-settings', { refetchActive: true });
|
|
49
|
-
updateProjectSettings({ menuLogo: menuLogo?.url });
|
|
50
|
-
},
|
|
51
|
-
});
|
|
52
|
-
|
|
53
|
-
const handleSubmit = () => {
|
|
54
|
-
const inputValues = inputsRef.current.getValues();
|
|
55
|
-
const formData = getFormData(inputValues);
|
|
56
|
-
|
|
57
|
-
submitMutation.mutate(formData, {
|
|
58
|
-
onSuccess: () => {
|
|
59
|
-
const { menuLogo } = inputValues;
|
|
60
|
-
|
|
61
|
-
if (menuLogo.rawFile) {
|
|
62
|
-
trackUsage('didChangeLogo');
|
|
63
|
-
}
|
|
64
|
-
},
|
|
65
|
-
onError: () => {
|
|
66
|
-
toggleNotification({
|
|
67
|
-
type: 'warning',
|
|
68
|
-
message: { id: 'notification.error', defaultMessage: 'An error occurred' },
|
|
69
|
-
});
|
|
70
|
-
},
|
|
71
|
-
});
|
|
72
|
-
};
|
|
73
|
-
|
|
74
24
|
return (
|
|
75
25
|
<Layout>
|
|
76
26
|
<SettingsPageTitle name="Application" />
|
|
@@ -81,113 +31,107 @@ const ApplicationInfosPage = () => {
|
|
|
81
31
|
id: 'Settings.application.description',
|
|
82
32
|
defaultMessage: 'Administration panel’s global information',
|
|
83
33
|
})}
|
|
84
|
-
primaryAction={
|
|
85
|
-
<Button onClick={handleSubmit} startIcon={<Check />}>
|
|
86
|
-
{formatMessage({ id: 'global.save', defaultMessage: 'Save' })}
|
|
87
|
-
</Button>
|
|
88
|
-
}
|
|
89
34
|
/>
|
|
90
35
|
<ContentLayout>
|
|
91
|
-
<
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
>
|
|
101
|
-
<
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
</Typography>
|
|
36
|
+
<Box
|
|
37
|
+
hasRadius
|
|
38
|
+
background="neutral0"
|
|
39
|
+
shadow="tableShadow"
|
|
40
|
+
paddingTop={7}
|
|
41
|
+
paddingBottom={7}
|
|
42
|
+
paddingRight={6}
|
|
43
|
+
paddingLeft={6}
|
|
44
|
+
>
|
|
45
|
+
<Stack spacing={5}>
|
|
46
|
+
<Typography variant="delta" as="h3">
|
|
47
|
+
{formatMessage({
|
|
48
|
+
id: 'global.details',
|
|
49
|
+
defaultMessage: 'Details',
|
|
50
|
+
})}
|
|
51
|
+
</Typography>
|
|
108
52
|
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
53
|
+
<Grid paddingTop={1}>
|
|
54
|
+
<GridItem col={6} s={12}>
|
|
55
|
+
<Typography variant="sigma" textColor="neutral600">
|
|
56
|
+
{formatMessage({
|
|
57
|
+
id: 'Settings.application.strapiVersion',
|
|
58
|
+
defaultMessage: 'strapi version',
|
|
59
|
+
})}
|
|
60
|
+
</Typography>
|
|
61
|
+
<Typography as="p">v{strapiVersion}</Typography>
|
|
62
|
+
<Link
|
|
63
|
+
href={
|
|
64
|
+
appInfos.communityEdition
|
|
65
|
+
? 'https://discord.strapi.io'
|
|
66
|
+
: 'https://support.strapi.io/support/home'
|
|
67
|
+
}
|
|
68
|
+
isExternal
|
|
69
|
+
endIcon={<ExternalLink />}
|
|
70
|
+
>
|
|
71
|
+
{formatMessage({
|
|
72
|
+
id: 'Settings.application.get-help',
|
|
73
|
+
defaultMessage: 'Get help',
|
|
74
|
+
})}
|
|
75
|
+
</Link>
|
|
76
|
+
</GridItem>
|
|
77
|
+
<GridItem col={6} s={12}>
|
|
78
|
+
<Typography variant="sigma" textColor="neutral600">
|
|
79
|
+
{formatMessage({
|
|
80
|
+
id: 'Settings.application.edition-title',
|
|
81
|
+
defaultMessage: 'current plan',
|
|
82
|
+
})}
|
|
83
|
+
</Typography>
|
|
84
|
+
<Typography as="p">
|
|
85
|
+
{formatMessage({
|
|
86
|
+
id: currentPlan,
|
|
87
|
+
defaultMessage: `${
|
|
88
|
+
appInfos.communityEdition ? 'Community Edition' : 'Enterprise Edition'
|
|
89
|
+
}`,
|
|
90
|
+
})}
|
|
91
|
+
</Typography>
|
|
92
|
+
</GridItem>
|
|
93
|
+
</Grid>
|
|
94
|
+
|
|
95
|
+
<Grid paddingTop={1}>
|
|
96
|
+
<GridItem col={6} s={12}>
|
|
97
|
+
{shouldUpdateStrapi && (
|
|
118
98
|
<Link
|
|
119
|
-
href={
|
|
120
|
-
|
|
121
|
-
? 'https://discord.strapi.io'
|
|
122
|
-
: 'https://support.strapi.io/support/home'
|
|
123
|
-
}
|
|
99
|
+
href={`https://github.com/strapi/strapi/releases/tag/${latestStrapiReleaseTag}`}
|
|
100
|
+
isExternal
|
|
124
101
|
endIcon={<ExternalLink />}
|
|
125
102
|
>
|
|
126
103
|
{formatMessage({
|
|
127
|
-
id: 'Settings.application.
|
|
128
|
-
defaultMessage: '
|
|
129
|
-
})}
|
|
130
|
-
</Link>
|
|
131
|
-
</GridItem>
|
|
132
|
-
<GridItem col={6} s={12}>
|
|
133
|
-
<Typography variant="sigma" textColor="neutral600">
|
|
134
|
-
{formatMessage({
|
|
135
|
-
id: 'Settings.application.edition-title',
|
|
136
|
-
defaultMessage: 'current plan',
|
|
137
|
-
})}
|
|
138
|
-
</Typography>
|
|
139
|
-
<Typography as="p">
|
|
140
|
-
{formatMessage({
|
|
141
|
-
id: currentPlan,
|
|
142
|
-
defaultMessage: `${
|
|
143
|
-
appInfos.communityEdition ? 'Community Edition' : 'Enterprise Edition'
|
|
144
|
-
}`,
|
|
145
|
-
})}
|
|
146
|
-
</Typography>
|
|
147
|
-
</GridItem>
|
|
148
|
-
</Grid>
|
|
149
|
-
|
|
150
|
-
<Grid paddingTop={1}>
|
|
151
|
-
<GridItem col={6} s={12}>
|
|
152
|
-
{shouldUpdateStrapi && (
|
|
153
|
-
<Link
|
|
154
|
-
href={`https://github.com/strapi/strapi/releases/tag/${latestStrapiReleaseTag}`}
|
|
155
|
-
endIcon={<ExternalLink />}
|
|
156
|
-
>
|
|
157
|
-
{formatMessage({
|
|
158
|
-
id: 'Settings.application.link-upgrade',
|
|
159
|
-
defaultMessage: 'Upgrade your admin panel',
|
|
160
|
-
})}
|
|
161
|
-
</Link>
|
|
162
|
-
)}
|
|
163
|
-
</GridItem>
|
|
164
|
-
<GridItem col={6} s={12}>
|
|
165
|
-
<Link href="https://strapi.io/pricing-self-hosted" endIcon={<ExternalLink />}>
|
|
166
|
-
{formatMessage({
|
|
167
|
-
id: 'Settings.application.link-pricing',
|
|
168
|
-
defaultMessage: 'See all pricing plans',
|
|
104
|
+
id: 'Settings.application.link-upgrade',
|
|
105
|
+
defaultMessage: 'Upgrade your admin panel',
|
|
169
106
|
})}
|
|
170
107
|
</Link>
|
|
171
|
-
|
|
172
|
-
</
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
108
|
+
)}
|
|
109
|
+
</GridItem>
|
|
110
|
+
<GridItem col={6} s={12}>
|
|
111
|
+
<Link
|
|
112
|
+
href="https://strapi.io/pricing-self-hosted"
|
|
113
|
+
isExternal
|
|
114
|
+
endIcon={<ExternalLink />}
|
|
115
|
+
>
|
|
176
116
|
{formatMessage({
|
|
177
|
-
id: 'Settings.application.
|
|
178
|
-
defaultMessage: '
|
|
117
|
+
id: 'Settings.application.link-pricing',
|
|
118
|
+
defaultMessage: 'See all pricing plans',
|
|
179
119
|
})}
|
|
180
|
-
</
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
120
|
+
</Link>
|
|
121
|
+
</GridItem>
|
|
122
|
+
</Grid>
|
|
123
|
+
|
|
124
|
+
<Box paddingTop={1}>
|
|
125
|
+
<Typography variant="sigma" textColor="neutral600">
|
|
126
|
+
{formatMessage({
|
|
127
|
+
id: 'Settings.application.node-version',
|
|
128
|
+
defaultMessage: 'node version',
|
|
129
|
+
})}
|
|
130
|
+
</Typography>
|
|
131
|
+
<Typography as="p">{appInfos.nodeVersion}</Typography>
|
|
132
|
+
</Box>
|
|
133
|
+
</Stack>
|
|
134
|
+
</Box>
|
|
191
135
|
</ContentLayout>
|
|
192
136
|
</Main>
|
|
193
137
|
</Layout>
|
|
@@ -6,6 +6,7 @@ import {
|
|
|
6
6
|
useTracking,
|
|
7
7
|
LoadingIndicatorPage,
|
|
8
8
|
SettingsPageTitle,
|
|
9
|
+
Link,
|
|
9
10
|
} from '@strapi/helper-plugin';
|
|
10
11
|
import { Box } from '@strapi/design-system/Box';
|
|
11
12
|
import { Button } from '@strapi/design-system/Button';
|
|
@@ -13,7 +14,6 @@ import { ContentLayout, HeaderLayout } from '@strapi/design-system/Layout';
|
|
|
13
14
|
import { Main } from '@strapi/design-system/Main';
|
|
14
15
|
import { Stack } from '@strapi/design-system/Stack';
|
|
15
16
|
import { Formik } from 'formik';
|
|
16
|
-
import { Link } from '@strapi/design-system/Link';
|
|
17
17
|
import ArrowLeft from '@strapi/icons/ArrowLeft';
|
|
18
18
|
import get from 'lodash/get';
|
|
19
19
|
import { useIntl } from 'react-intl';
|
|
@@ -15,6 +15,7 @@ import {
|
|
|
15
15
|
useNotification,
|
|
16
16
|
useOverlayBlocker,
|
|
17
17
|
LoadingIndicatorPage,
|
|
18
|
+
Link,
|
|
18
19
|
} from '@strapi/helper-plugin';
|
|
19
20
|
import { useQuery } from 'react-query';
|
|
20
21
|
import { Formik } from 'formik';
|
|
@@ -22,7 +23,6 @@ import { Box } from '@strapi/design-system/Box';
|
|
|
22
23
|
import { Button } from '@strapi/design-system/Button';
|
|
23
24
|
import { Grid, GridItem } from '@strapi/design-system/Grid';
|
|
24
25
|
import { HeaderLayout, ContentLayout } from '@strapi/design-system/Layout';
|
|
25
|
-
import { Link } from '@strapi/design-system/Link';
|
|
26
26
|
import { Typography } from '@strapi/design-system/Typography';
|
|
27
27
|
import { Main } from '@strapi/design-system/Main';
|
|
28
28
|
import { Stack } from '@strapi/design-system/Stack';
|
package/admin/src/pages/SettingsPage/pages/Webhooks/EditView/components/WebhookForm/index.js
CHANGED
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
import React, { useState } from 'react';
|
|
2
2
|
import PropTypes from 'prop-types';
|
|
3
|
-
import { Form } from '@strapi/helper-plugin';
|
|
3
|
+
import { Form, Link } from '@strapi/helper-plugin';
|
|
4
4
|
import ArrowLeft from '@strapi/icons/ArrowLeft';
|
|
5
5
|
import Check from '@strapi/icons/Check';
|
|
6
6
|
import Publish from '@strapi/icons/Play';
|
|
7
7
|
import { ContentLayout, HeaderLayout } from '@strapi/design-system/Layout';
|
|
8
8
|
import { Box } from '@strapi/design-system/Box';
|
|
9
9
|
import { Button } from '@strapi/design-system/Button';
|
|
10
|
-
import { Link } from '@strapi/design-system/Link';
|
|
11
10
|
import { Stack } from '@strapi/design-system/Stack';
|
|
12
11
|
import { TextInput } from '@strapi/design-system/TextInput';
|
|
13
12
|
import { Grid, GridItem } from '@strapi/design-system/Grid';
|
|
@@ -17,6 +17,7 @@ import {
|
|
|
17
17
|
ConfirmDialog,
|
|
18
18
|
onRowClick,
|
|
19
19
|
stopPropagation,
|
|
20
|
+
LinkButton,
|
|
20
21
|
} from '@strapi/helper-plugin';
|
|
21
22
|
import { HeaderLayout, Layout, ContentLayout, ActionLayout } from '@strapi/design-system/Layout';
|
|
22
23
|
import { EmptyStateLayout } from '@strapi/design-system/EmptyStateLayout';
|
|
@@ -30,7 +31,6 @@ import { Button } from '@strapi/design-system/Button';
|
|
|
30
31
|
import { VisuallyHidden } from '@strapi/design-system/VisuallyHidden';
|
|
31
32
|
import { Switch } from '@strapi/design-system/Switch';
|
|
32
33
|
import { Main } from '@strapi/design-system/Main';
|
|
33
|
-
import { LinkButton } from '@strapi/design-system/LinkButton';
|
|
34
34
|
import { useNotifyAT } from '@strapi/design-system/LiveRegions';
|
|
35
35
|
import { Box } from '@strapi/design-system/Box';
|
|
36
36
|
import Plus from '@strapi/icons/Plus';
|