diff --git a/docs/3.0.0-beta.x/guides/registering-a-field-in-admin.md b/docs/3.0.0-beta.x/guides/registering-a-field-in-admin.md index b20c25fb14..a4a55a4015 100644 --- a/docs/3.0.0-beta.x/guides/registering-a-field-in-admin.md +++ b/docs/3.0.0-beta.x/guides/registering-a-field-in-admin.md @@ -19,7 +19,7 @@ yarn create strapi-app my-app --quickstart --no-run 2. Generate a plugin: ```bash -strapi generate:plugin wysiwyg +yarn run strapi generate:plugin wysiwyg ``` 3. Install the needed dependencies: @@ -126,7 +126,7 @@ export default MediaLib; **Path —** `./plugins/wysiwyg/admin/src/components/Wysiwyg/index.js` ```js -iimport React, { useState } from 'react'; +import React, { useState } from 'react'; import PropTypes from 'prop-types'; import { isEmpty } from 'lodash'; import { Button } from '@buffetjs/core'; @@ -332,4 +332,4 @@ export default strapi => { }; ``` -And VOILA, if you create a new `collectionType` or a `singleType` with a `richtext` field you will see the implementation of [CKEditor]((https://ckeditor.com/ckeditor-5/) instead of the default WYSIWYG. +And VOILA, if you create a new `collectionType` or a `singleType` with a `richtext` field you will see the implementation of [CKEditor](https://ckeditor.com/ckeditor-5/) instead of the default WYSIWYG. diff --git a/packages/strapi-admin/admin/src/components/Inputs/Wrapper.js b/packages/strapi-admin/admin/src/components/Inputs/Wrapper.js index de8274e020..6e3c5821a5 100644 --- a/packages/strapi-admin/admin/src/components/Inputs/Wrapper.js +++ b/packages/strapi-admin/admin/src/components/Inputs/Wrapper.js @@ -15,7 +15,7 @@ const Wrapper = styled.div` margin-bottom: 1rem; } > p { - width 100%; + width: 100%; margin-bottom: -8px; padding-top: 10px; font-size: 13px; diff --git a/packages/strapi-admin/admin/src/containers/AuthPage/Wrapper.js b/packages/strapi-admin/admin/src/containers/AuthPage/Wrapper.js index 6ad6e7fc45..87a35f65f6 100644 --- a/packages/strapi-admin/admin/src/containers/AuthPage/Wrapper.js +++ b/packages/strapi-admin/admin/src/containers/AuthPage/Wrapper.js @@ -86,8 +86,7 @@ const Wrapper = styled.div` } .bordered { - border-top: 2px solid - ${({ withSucessBorder }) => (withSucessBorder ? '#5a9e06' : '#1c5de7')}; + border-top: 2px solid ${({ withSuccessBorder }) => (withSuccessBorder ? '#5a9e06' : '#1c5de7')}; } .borderedSuccess { diff --git a/packages/strapi-admin/admin/src/containers/AuthPage/index.js b/packages/strapi-admin/admin/src/containers/AuthPage/index.js index f1d3bb8e37..d8682636f2 100644 --- a/packages/strapi-admin/admin/src/containers/AuthPage/index.js +++ b/packages/strapi-admin/admin/src/containers/AuthPage/index.js @@ -3,13 +3,7 @@ import PropTypes from 'prop-types'; import { get, isEmpty, omit, set, upperFirst } from 'lodash'; import { FormattedMessage } from 'react-intl'; import { Link, Redirect } from 'react-router-dom'; -import { - auth, - Button, - getQueryParameters, - getYupInnerErrors, - request, -} from 'strapi-helper-plugin'; +import { auth, Button, getQueryParameters, getYupInnerErrors, request } from 'strapi-helper-plugin'; import NavTopRightWrapper from '../../components/NavTopRightWrapper'; import LogoStrapi from '../../assets/images/logo_strapi.png'; import PageTitle from '../../components/PageTitle'; @@ -29,9 +23,9 @@ const AuthPage = ({ }) => { const [reducerState, dispatch] = useReducer(reducer, initialState); const codeRef = useRef(); - const aborController = new AbortController(); + const abortController = new AbortController(); - const { signal } = aborController; + const { signal } = abortController; codeRef.current = getQueryParameters(search, 'code'); useEffect(() => { // Set the reset code provided by the url @@ -49,17 +43,11 @@ const AuthPage = ({ } return () => { - aborController.abort(); + abortController.abort(); }; // eslint-disable-next-line react-hooks/exhaustive-deps }, [authType, codeRef]); - const { - didCheckErrors, - errors, - modifiedData, - submitSuccess, - userEmail, - } = reducerState.toJS(); + const { didCheckErrors, errors, modifiedData, submitSuccess, userEmail } = reducerState.toJS(); const handleChange = ({ target: { name, value } }) => { dispatch({ type: 'ON_CHANGE', @@ -124,9 +112,7 @@ const AuthPage = ({ } else if (authType === 'forgot-password') { formErrors = { email: formattedError[0] }; } else { - strapi.notification.error( - get(formattedError, '0.id', 'notification.error') - ); + strapi.notification.error(get(formattedError, '0.id', 'notification.error')); } } } catch (err) { @@ -164,7 +150,7 @@ const AuthPage = ({ return ( <> - + @@ -177,9 +163,7 @@ const AuthPage = ({ )}
- {authType === 'register' && ( - - )} + {authType === 'register' && }
{/* TODO Forgot success style */}
@@ -217,9 +201,7 @@ const AuthPage = ({ })}