@akemona-org/strapi-admin 3.12.4 → 3.13.1

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.
Files changed (129) hide show
  1. package/admin/src/components/FormBloc/index.js +3 -3
  2. package/admin/src/components/HeaderSearch/index.js +2 -2
  3. package/admin/src/components/IntlInput/index.js +2 -2
  4. package/admin/src/components/LeftMenu/LeftMenuFooter/Wrapper.js +3 -1
  5. package/admin/src/components/LeftMenu/LeftMenuHeader/index.js +3 -3
  6. package/admin/src/components/LeftMenu/LeftMenuLink/LeftMenuIcon.js +3 -1
  7. package/admin/src/components/LeftMenu/LeftMenuLink/LeftMenuLinkContent.js +3 -3
  8. package/admin/src/components/LeftMenu/LeftMenuLink/NotificationCount.js +3 -3
  9. package/admin/src/components/LeftMenu/LeftMenuLink/index.js +2 -2
  10. package/admin/src/components/LeftMenu/LeftMenuLinkHeader/index.js +2 -2
  11. package/admin/src/components/LeftMenu/LeftMenuLinkSection/index.js +3 -3
  12. package/admin/src/components/PageTitle/index.js +3 -3
  13. package/admin/src/components/Roles/ButtonWithNumber/index.js +2 -2
  14. package/admin/src/components/Roles/ConditionsButton/index.js +2 -2
  15. package/admin/src/components/Roles/ConditionsModal/ActionRow/index.js +3 -3
  16. package/admin/src/components/Roles/ConditionsModal/ConditionsSelect/ClearIndicator.js +2 -2
  17. package/admin/src/components/Roles/ConditionsModal/ConditionsSelect/CustomDropdownIndicator.js +2 -2
  18. package/admin/src/components/Roles/ConditionsModal/ConditionsSelect/IndicatorSeparator.js +3 -1
  19. package/admin/src/components/Roles/ConditionsModal/ConditionsSelect/MenuList/SubUl.js +2 -2
  20. package/admin/src/components/Roles/ConditionsModal/ConditionsSelect/MenuList/index.js +2 -2
  21. package/admin/src/components/Roles/ConditionsModal/ConditionsSelect/SingleValue.js +2 -2
  22. package/admin/src/components/Roles/ConditionsModal/ConditionsSelect/index.js +3 -3
  23. package/admin/src/components/Roles/ConditionsModal/index.js +3 -3
  24. package/admin/src/components/Roles/ContentTypeCollapse/Collapse/index.js +3 -3
  25. package/admin/src/components/Roles/ContentTypeCollapse/CollapsePropertyMatrix/ActionRow/index.js +3 -3
  26. package/admin/src/components/Roles/ContentTypeCollapse/CollapsePropertyMatrix/Header/index.js +2 -2
  27. package/admin/src/components/Roles/ContentTypeCollapse/CollapsePropertyMatrix/SubActionRow/index.js +3 -3
  28. package/admin/src/components/Roles/ContentTypeCollapse/CollapsePropertyMatrix/index.js +3 -3
  29. package/admin/src/components/Roles/ContentTypeCollapse/index.js +3 -3
  30. package/admin/src/components/Roles/ContentTypeCollapses/index.js +2 -2
  31. package/admin/src/components/Roles/ContentTypes/index.js +2 -2
  32. package/admin/src/components/Roles/Curve/index.js +3 -3
  33. package/admin/src/components/Roles/EmptyRole/index.js +2 -2
  34. package/admin/src/components/Roles/GlobalActions/index.js +2 -2
  35. package/admin/src/components/Roles/PermissionsDataManagerProvider/index.js +2 -2
  36. package/admin/src/components/Roles/PluginsAndSettings/Row/index.js +3 -3
  37. package/admin/src/components/Roles/PluginsAndSettings/SubCategory/index.js +2 -2
  38. package/admin/src/components/Roles/PluginsAndSettings/index.js +2 -2
  39. package/admin/src/components/Roles/RequiredSign/index.js +3 -1
  40. package/admin/src/components/Roles/RoleForm/NameInput.js +3 -1
  41. package/admin/src/components/Roles/RoleForm/RoleForm.js +2 -2
  42. package/admin/src/components/Roles/RoleList/RoleRow.js +2 -2
  43. package/admin/src/components/Roles/RowLabelWithCheckbox/index.js +3 -3
  44. package/admin/src/components/Roles/Tabs/index.js +2 -2
  45. package/admin/src/components/Settings/Header/index.js +3 -3
  46. package/admin/src/components/SettingsPageTitle/index.js +2 -2
  47. package/admin/src/components/SizedInput/index.js +2 -2
  48. package/admin/src/components/UpgradePlanModal/components/Option/index.js +2 -2
  49. package/admin/src/components/UpgradePlanModal/index.js +2 -2
  50. package/admin/src/components/Users/Filter/index.js +2 -2
  51. package/admin/src/components/Users/FilterPicker/Button.js +2 -2
  52. package/admin/src/components/Users/FilterPicker/Card/index.js +2 -2
  53. package/admin/src/components/Users/FilterPicker/index.js +2 -2
  54. package/admin/src/components/Users/Footer/index.js +2 -2
  55. package/admin/src/components/Users/LinkNotification/Envelope.js +3 -3
  56. package/admin/src/components/Users/LinkNotification/index.js +2 -2
  57. package/admin/src/components/Users/MagicLink/index.js +2 -2
  58. package/admin/src/components/Users/RoleSettingsModalSection/RolesSelectComponent.js +2 -2
  59. package/admin/src/components/Users/RoleSettingsModalSection/index.js +2 -2
  60. package/admin/src/components/Users/SelectRoles/ClearIndicator.js +2 -2
  61. package/admin/src/components/Users/SelectRoles/DropdownIndicator.js +2 -2
  62. package/admin/src/components/Users/SelectRoles/IndicatorSeparator.js +3 -1
  63. package/admin/src/components/Users/SelectRoles/MultiValueContainer.js +2 -2
  64. package/admin/src/components/Users/SelectRoles/index.js +2 -2
  65. package/admin/src/components/Users/SortPicker/Button.js +2 -2
  66. package/admin/src/components/Users/SortPicker/List.js +2 -2
  67. package/admin/src/components/Users/SortPicker/ListItem.js +2 -2
  68. package/admin/src/components/Users/SortPicker/index.js +2 -2
  69. package/admin/src/components/Webhooks/EventInput/EventRow.js +2 -2
  70. package/admin/src/components/Webhooks/EventInput/index.js +2 -2
  71. package/admin/src/components/Webhooks/HeadersInput/index.js +2 -2
  72. package/admin/src/components/Webhooks/TriggerContainer/index.js +2 -2
  73. package/admin/src/containers/ApplicationInfosPage/components/Detail/index.js +2 -2
  74. package/admin/src/containers/ApplicationInfosPage/components/InfoText/index.js +2 -2
  75. package/admin/src/containers/ApplicationInfosPage/components/Link/index.js +2 -2
  76. package/admin/src/containers/ApplicationInfosPage/index.js +2 -2
  77. package/admin/src/containers/AuthPage/components/AuthLink/index.js +2 -2
  78. package/admin/src/containers/AuthPage/components/Box/index.js +3 -3
  79. package/admin/src/containers/AuthPage/components/ForgotPassword/index.js +2 -2
  80. package/admin/src/containers/AuthPage/components/ForgotPasswordSuccess/Envelope.js +3 -3
  81. package/admin/src/containers/AuthPage/components/ForgotPasswordSuccess/index.js +2 -2
  82. package/admin/src/containers/AuthPage/components/Input/index.js +2 -2
  83. package/admin/src/containers/AuthPage/components/Login/BaseLogin.js +2 -2
  84. package/admin/src/containers/AuthPage/components/Login/index.js +2 -2
  85. package/admin/src/containers/AuthPage/components/Logo/index.js +3 -1
  86. package/admin/src/containers/AuthPage/components/Oops/index.js +2 -2
  87. package/admin/src/containers/AuthPage/components/Register/CustomLabel.js +2 -2
  88. package/admin/src/containers/AuthPage/components/Register/index.js +3 -3
  89. package/admin/src/containers/AuthPage/components/ResetPassword/index.js +2 -2
  90. package/admin/src/containers/AuthPage/index.js +2 -2
  91. package/admin/src/containers/HomePage/BlogPost.js +2 -2
  92. package/admin/src/containers/HomePage/SocialLink.js +2 -2
  93. package/admin/src/containers/InstalledPluginsPage/Row.js +2 -2
  94. package/admin/src/containers/InstalledPluginsPage/index.js +2 -2
  95. package/admin/src/containers/LeftMenu/Loader.js +2 -2
  96. package/admin/src/containers/LeftMenu/index.js +2 -2
  97. package/admin/src/containers/LeftMenu/useMenuSections.js +2 -3
  98. package/admin/src/containers/MarketplacePage/MarketplaceBanner/index.js +2 -2
  99. package/admin/src/containers/MarketplacePage/index.js +2 -2
  100. package/admin/src/containers/NewNotification/Notification/index.js +2 -2
  101. package/admin/src/containers/NewNotification/index.js +2 -2
  102. package/admin/src/containers/NotFoundPage/index.js +3 -1
  103. package/admin/src/containers/Onboarding/index.js +2 -2
  104. package/admin/src/containers/PermissionsManager/index.js +2 -2
  105. package/admin/src/containers/PrivateRoute/index.js +3 -3
  106. package/admin/src/containers/ProfilePage/index.js +2 -2
  107. package/admin/src/containers/Roles/CreatePage/index.js +2 -2
  108. package/admin/src/containers/Roles/EditPage/index.js +2 -2
  109. package/admin/src/containers/Roles/ListPage/index.js +2 -2
  110. package/admin/src/containers/Roles/ProtectedEditPage/index.js +2 -2
  111. package/admin/src/containers/Roles/ProtectedListPage/index.js +3 -3
  112. package/admin/src/containers/SettingsHeaderSearchContextProvider/index.js +2 -2
  113. package/admin/src/containers/SettingsPage/components/ApplicationDetailLink/index.js +2 -2
  114. package/admin/src/containers/SettingsPage/components/SettingDispatcher/index.js +2 -2
  115. package/admin/src/containers/Theme/index.js +2 -2
  116. package/admin/src/containers/Users/EditPage/index.js +2 -2
  117. package/admin/src/containers/Users/ListPage/Header.js +3 -3
  118. package/admin/src/containers/Users/ListPage/ModalForm.js +2 -2
  119. package/admin/src/containers/Users/ListPage/index.js +2 -2
  120. package/admin/src/containers/Users/ProtectedEditPage/index.js +2 -2
  121. package/admin/src/containers/Users/ProtectedListPage/index.js +3 -3
  122. package/admin/src/containers/Webhooks/ProtectedCreateView/index.js +3 -3
  123. package/admin/src/containers/Webhooks/ProtectedEditView/index.js +3 -3
  124. package/admin/src/containers/Webhooks/ProtectedListView/index.js +3 -3
  125. package/admin/src/contexts/MarketPlace/index.js +2 -2
  126. package/admin/src/utils/MiddlewareApi.js +1 -0
  127. package/controllers/authentication.js +2 -3
  128. package/middlewares/auth/index.js +2 -3
  129. package/package.json +4 -4
@@ -4,8 +4,8 @@ import { BaselineAlignment, LoadingIndicator, Row } from '@akemona-org/strapi-he
4
4
  import PropTypes from 'prop-types';
5
5
  import Bloc from '../Bloc';
6
6
 
7
- const FormBloc = ({ children, actions, isLoading, title, subtitle }) => (
8
- <Bloc>
7
+ function FormBloc({ children, actions, isLoading, title, subtitle }) {
8
+ return <Bloc>
9
9
  <BaselineAlignment top size={title ? '18px' : '22px'} />
10
10
  <Padded left right size="sm">
11
11
  {isLoading ? (
@@ -40,7 +40,7 @@ const FormBloc = ({ children, actions, isLoading, title, subtitle }) => (
40
40
  )}
41
41
  </Padded>
42
42
  </Bloc>
43
- );
43
+ }
44
44
 
45
45
  FormBloc.defaultProps = {
46
46
  actions: null,
@@ -6,7 +6,7 @@ import { useIntl } from 'react-intl';
6
6
  import { useQuery } from '@akemona-org/strapi-helper-plugin';
7
7
  import StyledHeaderSearch from './HeaderSearch';
8
8
 
9
- const HeaderSearch = ({ label, queryParameter }) => {
9
+ function HeaderSearch({ label, queryParameter }) {
10
10
  const { formatMessage } = useIntl();
11
11
  const query = useQuery();
12
12
  const searchValue = query.get(queryParameter) || '';
@@ -79,7 +79,7 @@ const HeaderSearch = ({ label, queryParameter }) => {
79
79
  onClear={handleClear}
80
80
  />
81
81
  );
82
- };
82
+ }
83
83
 
84
84
  HeaderSearch.defaultProps = {
85
85
  queryParameter: '_q',
@@ -4,7 +4,7 @@ import { useIntl } from 'react-intl';
4
4
  import { Inputs } from '@buffetjs/custom';
5
5
  import PropTypes from 'prop-types';
6
6
 
7
- const IntlInput = ({ label: labelId, defaultMessage, error, ...rest }) => {
7
+ function IntlInput({ label: labelId, defaultMessage, error, ...rest }) {
8
8
  const { formatMessage } = useIntl();
9
9
  const label = formatMessage({ id: labelId, defaultMessage: defaultMessage || labelId });
10
10
  const translatedError = error ? formatMessage(error) : null;
@@ -20,7 +20,7 @@ const IntlInput = ({ label: labelId, defaultMessage, error, ...rest }) => {
20
20
  return (
21
21
  <Inputs {...rest} label={label} error={translatedError} translatedErrors={formattedErrors} />
22
22
  );
23
- };
23
+ }
24
24
 
25
25
  IntlInput.defaultProps = {
26
26
  defaultMessage: null,
@@ -23,8 +23,10 @@ const Wrapper = styled.div`
23
23
  `;
24
24
 
25
25
  const A = styled.a`
26
+ color: ${(props) => props.theme.main.colors.lightBlue};
27
+
26
28
  &:hover {
27
- color: #007bff;
29
+ color: ${(props) => props.theme.main.colors.mediumBlue};
28
30
  text-decoration: underline;
29
31
  }
30
32
  `;
@@ -3,12 +3,12 @@ import { Link } from 'react-router-dom';
3
3
 
4
4
  import Wrapper from './Wrapper';
5
5
 
6
- const LeftMenuHeader = () => (
7
- <Wrapper>
6
+ function LeftMenuHeader() {
7
+ return <Wrapper>
8
8
  <Link to="/" className="leftMenuHeaderLink">
9
9
  <span className="projectName" />
10
10
  </Link>
11
11
  </Wrapper>
12
- );
12
+ }
13
13
 
14
14
  export default LeftMenuHeader;
@@ -11,7 +11,9 @@ const FaIcon = styled(({ small, ...props }) => <FontAwesomeIcon {...props} />)`
11
11
  font-size: ${({ small }) => (small ? '.5rem' : '1.3rem')};
12
12
  `;
13
13
 
14
- const LeftMenuIcon = ({ icon }) => <FaIcon small={icon === 'circle'} icon={icon} />;
14
+ function LeftMenuIcon({ icon }) {
15
+ return <FaIcon small={icon === 'circle'} icon={icon} />
16
+ }
15
17
 
16
18
  LeftMenuIcon.propTypes = {
17
19
  icon: PropTypes.string,
@@ -23,14 +23,14 @@ const LinkLabel = styled.span`
23
23
  `;
24
24
 
25
25
  // TODO: refacto this file
26
- const LeftMenuLinkContent = ({
26
+ function LeftMenuLinkContent({
27
27
  destination,
28
28
  iconName,
29
29
  label,
30
30
  location,
31
31
  notificationsCount,
32
32
  search,
33
- }) => {
33
+ }) {
34
34
  const isLinkActive = startsWith(
35
35
  location.pathname.replace('/admin', '').concat('/'),
36
36
  destination.concat('/')
@@ -78,7 +78,7 @@ const LeftMenuLinkContent = ({
78
78
  {notificationsCount > 0 && <NotificationCount count={notificationsCount} />}
79
79
  </A>
80
80
  );
81
- };
81
+ }
82
82
 
83
83
  LeftMenuLinkContent.defaultProps = {
84
84
  search: null,
@@ -13,13 +13,13 @@ const NotificationWrapper = styled.div`
13
13
  font-size: 11px;
14
14
  `;
15
15
 
16
- const NotificationCount = ({ count }) => (
17
- <NotificationWrapper>
16
+ function NotificationCount({ count }) {
17
+ return <NotificationWrapper>
18
18
  <Text fontWeight="bold" fontSize="xs" lineHeight="14px" color="#919bae">
19
19
  {count}
20
20
  </Text>
21
21
  </NotificationWrapper>
22
- );
22
+ }
23
23
 
24
24
  NotificationCount.defaultProps = {
25
25
  count: 0,
@@ -9,7 +9,7 @@ import PropTypes from 'prop-types';
9
9
 
10
10
  import LeftMenuLinkContent from './LeftMenuLinkContent';
11
11
 
12
- const LeftMenuLink = ({ destination, iconName, label, location, notificationsCount, search }) => {
12
+ function LeftMenuLink({ destination, iconName, label, location, notificationsCount, search }) {
13
13
  return (
14
14
  <LeftMenuLinkContent
15
15
  destination={destination}
@@ -20,7 +20,7 @@ const LeftMenuLink = ({ destination, iconName, label, location, notificationsCou
20
20
  search={search}
21
21
  />
22
22
  );
23
- };
23
+ }
24
24
 
25
25
  LeftMenuLink.propTypes = {
26
26
  destination: PropTypes.string.isRequired,
@@ -11,7 +11,7 @@ import Title from './Title';
11
11
  import SearchButton from './SearchButton';
12
12
  import SearchWrapper from './SearchWrapper';
13
13
 
14
- const LeftMenuLinkHeader = ({ section, searchable, setSearch, search }) => {
14
+ function LeftMenuLinkHeader({ section, searchable, setSearch, search }) {
15
15
  const [showSearch, setShowSearch] = useState(false);
16
16
  const ref = createRef();
17
17
  const { id, defaultMessage } = messages[camelCase(section)];
@@ -63,7 +63,7 @@ const LeftMenuLinkHeader = ({ section, searchable, setSearch, search }) => {
63
63
  )}
64
64
  </Title>
65
65
  );
66
- };
66
+ }
67
67
 
68
68
  LeftMenuLinkHeader.propTypes = {
69
69
  section: PropTypes.string.isRequired,
@@ -10,14 +10,14 @@ import LeftMenuListLink from './LeftMenuListLink';
10
10
  import EmptyLinksList from './EmptyLinksList';
11
11
  import EmptyLinksListWrapper from './EmptyLinksListWrapper';
12
12
 
13
- const LeftMenuLinksSection = ({
13
+ function LeftMenuLinksSection({
14
14
  section,
15
15
  searchable,
16
16
  location,
17
17
  links,
18
18
  emptyLinksListMessage,
19
19
  shrink,
20
- }) => {
20
+ }) {
21
21
  const [search, setSearch] = useState('');
22
22
 
23
23
  const filteredList = sortBy(
@@ -60,7 +60,7 @@ const LeftMenuLinksSection = ({
60
60
  </LeftMenuListLink>
61
61
  </>
62
62
  );
63
- };
63
+ }
64
64
 
65
65
  LeftMenuLinksSection.defaultProps = {
66
66
  shrink: false,
@@ -4,9 +4,9 @@ import PropTypes from 'prop-types';
4
4
 
5
5
  import favicon from '../../favicon.png';
6
6
 
7
- const PageTitle = ({ title }) => (
8
- <Helmet title={title} link={[{ rel: 'icon', type: 'image/png', href: favicon }]} />
9
- );
7
+ function PageTitle({ title }) {
8
+ return <Helmet title={title} link={[{ rel: 'icon', type: 'image/png', href: favicon }]} />
9
+ }
10
10
 
11
11
  PageTitle.propTypes = {
12
12
  title: PropTypes.string.isRequired,
@@ -6,7 +6,7 @@ import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
6
6
 
7
7
  import NumberCard from './NumberCard';
8
8
 
9
- const ButtonWithNumber = ({ number, onClick }) => {
9
+ function ButtonWithNumber({ number, onClick }) {
10
10
  const { formatMessage } = useIntl();
11
11
 
12
12
  return (
@@ -29,7 +29,7 @@ const ButtonWithNumber = ({ number, onClick }) => {
29
29
  </Flex>
30
30
  </Button>
31
31
  );
32
- };
32
+ }
33
33
 
34
34
  ButtonWithNumber.defaultProps = {
35
35
  number: 0,
@@ -7,7 +7,7 @@ import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
7
7
 
8
8
  import Wrapper from './Wrapper';
9
9
 
10
- const ConditionsButton = ({ onClick, className, hasConditions, isRight }) => {
10
+ function ConditionsButton({ onClick, className, hasConditions, isRight }) {
11
11
  const { formatMessage } = useIntl();
12
12
 
13
13
  return (
@@ -29,7 +29,7 @@ const ConditionsButton = ({ onClick, className, hasConditions, isRight }) => {
29
29
  </Padded>
30
30
  </Wrapper>
31
31
  );
32
- };
32
+ }
33
33
 
34
34
  ConditionsButton.defaultProps = {
35
35
  className: null,
@@ -6,7 +6,7 @@ import { useIntl } from 'react-intl';
6
6
  import ConditionsSelect from '../ConditionsSelect';
7
7
  import Wrapper from './Wrapper';
8
8
 
9
- const ActionRow = ({
9
+ function ActionRow({
10
10
  arrayOfOptionsGroupedByCategory,
11
11
  isFormDisabled,
12
12
  isGrey,
@@ -15,7 +15,7 @@ const ActionRow = ({
15
15
  onCategoryChange,
16
16
  onChange,
17
17
  value,
18
- }) => {
18
+ }) {
19
19
  const { formatMessage } = useIntl();
20
20
 
21
21
  return (
@@ -73,7 +73,7 @@ const ActionRow = ({
73
73
  />
74
74
  </Wrapper>
75
75
  );
76
- };
76
+ }
77
77
 
78
78
  ActionRow.propTypes = {
79
79
  arrayOfOptionsGroupedByCategory: PropTypes.array.isRequired,
@@ -2,7 +2,7 @@ import React from 'react';
2
2
  import { Remove } from '@buffetjs/icons';
3
3
  import { components } from 'react-select';
4
4
 
5
- const ClearIndicator = (props) => {
5
+ function ClearIndicator(props) {
6
6
  const Component = components.ClearIndicator;
7
7
 
8
8
  return (
@@ -10,6 +10,6 @@ const ClearIndicator = (props) => {
10
10
  <Remove width="11px" height="11px" fill="#9EA7B8" />
11
11
  </Component>
12
12
  );
13
- };
13
+ }
14
14
 
15
15
  export default ClearIndicator;
@@ -15,7 +15,7 @@ const Wrapper = styled(Flex)`
15
15
  }
16
16
  `;
17
17
 
18
- const DropdownIndicator = ({ selectProps: { menuIsOpen } }) => {
18
+ function DropdownIndicator({ selectProps: { menuIsOpen } }) {
19
19
  const icon = menuIsOpen ? 'caret-up' : 'caret-down';
20
20
 
21
21
  return (
@@ -23,7 +23,7 @@ const DropdownIndicator = ({ selectProps: { menuIsOpen } }) => {
23
23
  <FontAwesomeIcon icon={icon} />
24
24
  </Wrapper>
25
25
  );
26
- };
26
+ }
27
27
 
28
28
  DropdownIndicator.propTypes = {
29
29
  selectProps: PropTypes.shape({
@@ -1,3 +1,5 @@
1
- const IndicatorSeparator = () => null;
1
+ function IndicatorSeparator() {
2
+ return null
3
+ }
2
4
 
3
5
  export default IndicatorSeparator;
@@ -27,13 +27,13 @@ const ToggleUl = styled(Collapse)`
27
27
  }
28
28
  `;
29
29
 
30
- const SubUl = ({ children, isOpen }) => {
30
+ function SubUl({ children, isOpen }) {
31
31
  return (
32
32
  <ToggleUl tag="ul" isOpen={isOpen}>
33
33
  {children}
34
34
  </ToggleUl>
35
35
  );
36
- };
36
+ }
37
37
 
38
38
  SubUl.defaultProps = {
39
39
  children: null,
@@ -15,7 +15,7 @@ import UpperFirst from './UpperFirst';
15
15
 
16
16
  /* eslint-disable jsx-a11y/no-static-element-interactions */
17
17
 
18
- const MenuList = ({ selectProps, ...rest }) => {
18
+ function MenuList({ selectProps, ...rest }) {
19
19
  const Component = components.MenuList;
20
20
  const { arrayOfOptionsGroupedByCategory } = selectProps;
21
21
 
@@ -127,7 +127,7 @@ const MenuList = ({ selectProps, ...rest }) => {
127
127
  </Ul>
128
128
  </Component>
129
129
  );
130
- };
130
+ }
131
131
 
132
132
  MenuList.propTypes = {
133
133
  selectProps: PropTypes.shape({
@@ -6,7 +6,7 @@ import { Text } from '@buffetjs/core';
6
6
  import { useIntl } from 'react-intl';
7
7
  import { createArrayOfValues } from '../../utils';
8
8
 
9
- const Value = ({ children, selectProps, ...props }) => {
9
+ function Value({ children, selectProps, ...props }) {
10
10
  const { formatMessage } = useIntl();
11
11
  const SingleValue = components.SingleValue;
12
12
  const valuesArray = createArrayOfValues(selectProps.value).filter((val) => val);
@@ -27,7 +27,7 @@ const Value = ({ children, selectProps, ...props }) => {
27
27
  </Text>
28
28
  </SingleValue>
29
29
  );
30
- };
30
+ }
31
31
 
32
32
  Value.defaultProps = {
33
33
  children: null,
@@ -16,14 +16,14 @@ const Wrapper = styled.div`
16
16
  cursor: ${({ disabled }) => (disabled ? 'not-allowed' : 'default')};
17
17
  `;
18
18
 
19
- const ConditionsSelect = ({
19
+ function ConditionsSelect({
20
20
  arrayOfOptionsGroupedByCategory,
21
21
  isFormDisabled,
22
22
  name,
23
23
  onCategoryChange,
24
24
  onChange,
25
25
  value,
26
- }) => {
26
+ }) {
27
27
  const { formatMessage } = useIntl();
28
28
 
29
29
  return (
@@ -53,7 +53,7 @@ const ConditionsSelect = ({
53
53
  />
54
54
  </Wrapper>
55
55
  );
56
- };
56
+ }
57
57
 
58
58
  ConditionsSelect.propTypes = {
59
59
  arrayOfOptionsGroupedByCategory: PropTypes.array.isRequired,
@@ -10,14 +10,14 @@ import ActionRow from './ActionRow';
10
10
  import Separator from './Separator';
11
11
  import updateValues from '../Permissions/utils/updateValues';
12
12
 
13
- const ConditionsModal = ({
13
+ function ConditionsModal({
14
14
  actions,
15
15
  headerBreadCrumbs,
16
16
  isOpen,
17
17
  isFormDisabled,
18
18
  onClosed,
19
19
  onToggle,
20
- }) => {
20
+ }) {
21
21
  const { formatMessage } = useIntl();
22
22
  const { availableConditions, modifiedData, onChangeConditions } = usePermissionsDataManager();
23
23
 
@@ -127,7 +127,7 @@ const ConditionsModal = ({
127
127
  </ModalFooter>
128
128
  </Modal>
129
129
  );
130
- };
130
+ }
131
131
 
132
132
  ConditionsModal.propTypes = {
133
133
  actions: PropTypes.arrayOf(
@@ -14,7 +14,7 @@ import RowLabelWithCheckbox from '../../RowLabelWithCheckbox';
14
14
  import Wrapper from './Wrapper';
15
15
  import generateCheckboxesActions from './utils/generateCheckboxesActions';
16
16
 
17
- const Collapse = ({
17
+ function Collapse({
18
18
  availableActions,
19
19
  isActive,
20
20
  isGrey,
@@ -22,7 +22,7 @@ const Collapse = ({
22
22
  label,
23
23
  onClickToggle,
24
24
  pathToData,
25
- }) => {
25
+ }) {
26
26
  const [modalState, setModalState] = useState({ isOpen: false, isMounted: false });
27
27
  const { modifiedData, onChangeParentCheckbox, onChangeSimpleCheckbox } =
28
28
  usePermissionsDataManager();
@@ -138,7 +138,7 @@ const Collapse = ({
138
138
  )}
139
139
  </Wrapper>
140
140
  );
141
- };
141
+ }
142
142
 
143
143
  Collapse.propTypes = {
144
144
  availableActions: PropTypes.array.isRequired,
@@ -14,7 +14,7 @@ import SubActionRow from '../SubActionRow';
14
14
  import Wrapper from './Wrapper';
15
15
  import getRowLabelCheckboxeState from './utils/getRowLabelCheckboxeState';
16
16
 
17
- const ActionRow = ({
17
+ function ActionRow({
18
18
  childrenForm,
19
19
  label,
20
20
  isFormDisabled,
@@ -23,7 +23,7 @@ const ActionRow = ({
23
23
  pathToData,
24
24
  propertyActions,
25
25
  propertyName,
26
- }) => {
26
+ }) {
27
27
  const [rowToOpen, setRowToOpen] = useState(null);
28
28
  const {
29
29
  modifiedData,
@@ -141,7 +141,7 @@ const ActionRow = ({
141
141
  )}
142
142
  </>
143
143
  );
144
- };
144
+ }
145
145
 
146
146
  ActionRow.defaultProps = {
147
147
  childrenForm: [],
@@ -17,7 +17,7 @@ const PropertyLabelWrapper = styled.div`
17
17
  padding-left: 3.5rem;
18
18
  `;
19
19
 
20
- const Header = ({ headers, label }) => {
20
+ function Header({ headers, label }) {
21
21
  const { formatMessage } = useIntl();
22
22
  const translatedLabel = formatMessage(
23
23
  {
@@ -50,7 +50,7 @@ const Header = ({ headers, label }) => {
50
50
  })}
51
51
  </Flex>
52
52
  );
53
- };
53
+ }
54
54
 
55
55
  Header.propTypes = {
56
56
  headers: PropTypes.arrayOf(
@@ -20,7 +20,7 @@ const SubLevelWrapper = styled.div`
20
20
  padding-bottom: 8px;
21
21
  `;
22
22
 
23
- const SubActionRow = ({
23
+ function SubActionRow({
24
24
  childrenForm,
25
25
  isFormDisabled,
26
26
  recursiveLevel,
@@ -28,7 +28,7 @@ const SubActionRow = ({
28
28
  propertyActions,
29
29
  parentName,
30
30
  propertyName,
31
- }) => {
31
+ }) {
32
32
  const { modifiedData, onChangeParentCheckbox, onChangeSimpleCheckbox } =
33
33
  usePermissionsDataManager();
34
34
  const [rowToOpen, setRowToOpen] = useState(null);
@@ -157,7 +157,7 @@ const SubActionRow = ({
157
157
  })}
158
158
  </Wrapper>
159
159
  );
160
- };
160
+ }
161
161
 
162
162
  SubActionRow.propTypes = {
163
163
  childrenForm: PropTypes.array.isRequired,
@@ -6,7 +6,7 @@ import Header from './Header';
6
6
  import ActionRow from './ActionRow';
7
7
  import Wrapper from './Wrapper';
8
8
 
9
- const CollapsePropertyMatrix = ({
9
+ function CollapsePropertyMatrix({
10
10
  availableActions,
11
11
  childrenForm,
12
12
  isLast,
@@ -14,7 +14,7 @@ const CollapsePropertyMatrix = ({
14
14
  label,
15
15
  pathToData,
16
16
  propertyName,
17
- }) => {
17
+ }) {
18
18
  const propertyActions = useMemo(
19
19
  () => generateHeadersFromActions(availableActions, propertyName),
20
20
  [availableActions, propertyName]
@@ -40,7 +40,7 @@ const CollapsePropertyMatrix = ({
40
40
  </Padded>
41
41
  </Wrapper>
42
42
  );
43
- };
43
+ }
44
44
 
45
45
  CollapsePropertyMatrix.propTypes = {
46
46
  childrenForm: PropTypes.array.isRequired,
@@ -5,7 +5,7 @@ import CollapsePropertyMatrix from './CollapsePropertyMatrix';
5
5
  import { getAvailableActions } from './utils';
6
6
  import Wrapper from './Wrapper';
7
7
 
8
- const ContentTypeCollapse = ({
8
+ function ContentTypeCollapse({
9
9
  allActions,
10
10
  contentTypeName,
11
11
  label,
@@ -15,7 +15,7 @@ const ContentTypeCollapse = ({
15
15
  onClickToggleCollapse,
16
16
  pathToData,
17
17
  properties,
18
- }) => {
18
+ }) {
19
19
  const handleClickToggleCollapse = useCallback(() => {
20
20
  onClickToggleCollapse(contentTypeName);
21
21
  }, [contentTypeName, onClickToggleCollapse]);
@@ -55,7 +55,7 @@ const ContentTypeCollapse = ({
55
55
  })}
56
56
  </Wrapper>
57
57
  );
58
- };
58
+ }
59
59
 
60
60
  ContentTypeCollapse.propTypes = {
61
61
  allActions: PropTypes.array.isRequired,
@@ -2,7 +2,7 @@ import React, { memo, useState } from 'react';
2
2
  import PropTypes from 'prop-types';
3
3
  import ContentTypeCollapse from '../ContentTypeCollapse';
4
4
 
5
- const ContentTypeCollapses = ({ actions, isFormDisabled, pathToData, subjects }) => {
5
+ function ContentTypeCollapses({ actions, isFormDisabled, pathToData, subjects }) {
6
6
  const [collapseToOpen, setCollapseToOpen] = useState(null);
7
7
 
8
8
  const handleClickToggleCollapse = (collapseName) => {
@@ -27,7 +27,7 @@ const ContentTypeCollapses = ({ actions, isFormDisabled, pathToData, subjects })
27
27
  />
28
28
  );
29
29
  });
30
- };
30
+ }
31
31
 
32
32
  ContentTypeCollapses.defaultProps = {
33
33
  actions: [],
@@ -5,7 +5,7 @@ import ContentTypeCollapses from '../ContentTypeCollapses';
5
5
  import GlobalActions from '../GlobalActions';
6
6
  import Wrapper from './Wrapper';
7
7
 
8
- const ContentTypes = ({ isFormDisabled, kind, layout: { actions, subjects } }) => {
8
+ function ContentTypes({ isFormDisabled, kind, layout: { actions, subjects } }) {
9
9
  return (
10
10
  <Wrapper>
11
11
  <Padded left right bottom size="md">
@@ -19,7 +19,7 @@ const ContentTypes = ({ isFormDisabled, kind, layout: { actions, subjects } }) =
19
19
  </Padded>
20
20
  </Wrapper>
21
21
  );
22
- };
22
+ }
23
23
 
24
24
  ContentTypes.propTypes = {
25
25
  isFormDisabled: PropTypes.bool.isRequired,
@@ -1,8 +1,8 @@
1
1
  import React, { memo } from 'react';
2
2
  import PropTypes from 'prop-types';
3
3
 
4
- const Curve = (props) => (
5
- <svg
4
+ function Curve(props) {
5
+ return <svg
6
6
  style={{
7
7
  height: '14px',
8
8
  transform: 'translate(-3.2px, -1px)',
@@ -23,7 +23,7 @@ const Curve = (props) => (
23
23
  />
24
24
  </g>
25
25
  </svg>
26
- );
26
+ }
27
27
 
28
28
  Curve.defaultProps = {
29
29
  fill: '#f3f4f4',
@@ -3,7 +3,7 @@ import { Flex, Padded, Text } from '@buffetjs/core';
3
3
  import { useIntl } from 'react-intl';
4
4
  import { BaselineAlignment, useQuery } from '@akemona-org/strapi-helper-plugin';
5
5
 
6
- const EmptyRole = () => {
6
+ function EmptyRole() {
7
7
  const { formatMessage } = useIntl();
8
8
  const query = useQuery();
9
9
  const search = query.get('_q');
@@ -26,6 +26,6 @@ const EmptyRole = () => {
26
26
  </Padded>
27
27
  </>
28
28
  );
29
- };
29
+ }
30
30
 
31
31
  export default EmptyRole;