mirror of
https://github.com/strapi/strapi.git
synced 2025-09-08 16:16:21 +00:00
Upgrade parts
Signed-off-by: soupette <cyril@strapi.io>
This commit is contained in:
parent
ce708cfc9a
commit
3fb4297cae
@ -3,6 +3,7 @@ import PropTypes from 'prop-types';
|
||||
import { useDispatch, useSelector } from 'react-redux';
|
||||
import { useIntl } from 'react-intl';
|
||||
import { Select, Option } from '@strapi/parts/Select';
|
||||
import { Box } from '@strapi/parts/Box';
|
||||
import { useTracking } from '@strapi/helper-plugin';
|
||||
import { onChangeListHeaders } from '../actions';
|
||||
import { selectDisplayedHeaders } from '../selectors';
|
||||
@ -43,25 +44,27 @@ const FieldPicker = ({ layout }) => {
|
||||
};
|
||||
|
||||
return (
|
||||
<Select
|
||||
aria-label="change displayed fields"
|
||||
value={values}
|
||||
onChange={handleChange}
|
||||
customizeContent={values => `${values.length} currently selected`}
|
||||
multi
|
||||
size="S"
|
||||
>
|
||||
{allAllowedHeaders.map(header => {
|
||||
return (
|
||||
<Option key={header.name} value={header.name}>
|
||||
{formatMessage({
|
||||
id: header.intlLabel.id || header.name,
|
||||
defaultMessage: header.intlLabel.defaultMessage || header.name,
|
||||
})}
|
||||
</Option>
|
||||
);
|
||||
})}
|
||||
</Select>
|
||||
<Box paddingLeft={3}>
|
||||
<Select
|
||||
aria-label="change displayed fields"
|
||||
value={values}
|
||||
onChange={handleChange}
|
||||
customizeContent={values => `${values.length} currently selected`}
|
||||
multi
|
||||
size="S"
|
||||
>
|
||||
{allAllowedHeaders.map(header => {
|
||||
return (
|
||||
<Option key={header.name} value={header.name}>
|
||||
{formatMessage({
|
||||
id: header.intlLabel.id || header.name,
|
||||
defaultMessage: header.intlLabel.defaultMessage || header.name,
|
||||
})}
|
||||
</Option>
|
||||
);
|
||||
})}
|
||||
</Select>
|
||||
</Box>
|
||||
);
|
||||
};
|
||||
|
||||
|
@ -22,6 +22,7 @@ import { Main } from '@strapi/parts/Main';
|
||||
import { ActionLayout, ContentLayout, HeaderLayout } from '@strapi/parts/Layout';
|
||||
import { useNotifyAT } from '@strapi/parts/LiveRegions';
|
||||
import { Button } from '@strapi/parts/Button';
|
||||
import { Row } from '@strapi/parts/Row';
|
||||
import Add from '@strapi/icons/Add';
|
||||
import axios from 'axios';
|
||||
import { axiosInstance } from '../../../core/utils';
|
||||
@ -265,10 +266,10 @@ function ListView({
|
||||
{canRead && (isSearchable || isFilterable) && (
|
||||
<ActionLayout
|
||||
endActions={
|
||||
<>
|
||||
<Row style={{ flexShrink: 0 }}>
|
||||
<InjectionZone area="contentManager.listView.actions" />
|
||||
<FieldPicker layout={layout} />
|
||||
</>
|
||||
</Row>
|
||||
}
|
||||
startActions={
|
||||
<>
|
||||
|
File diff suppressed because one or more lines are too long
@ -40,8 +40,8 @@
|
||||
"@fortawesome/react-fontawesome": "^0.1.14",
|
||||
"@strapi/babel-plugin-switch-ee-ce": "1.0.0",
|
||||
"@strapi/helper-plugin": "3.6.8",
|
||||
"@strapi/icons": "0.0.1-alpha.37",
|
||||
"@strapi/parts": "0.0.1-alpha.37",
|
||||
"@strapi/icons": "0.0.1-alpha.38",
|
||||
"@strapi/parts": "0.0.1-alpha.38",
|
||||
"@strapi/utils": "3.6.8",
|
||||
"axios": "^0.21.1",
|
||||
"babel-loader": "8.2.2",
|
||||
|
@ -57,8 +57,8 @@
|
||||
"@storybook/builder-webpack5": "^6.3.7",
|
||||
"@storybook/manager-webpack5": "^6.3.7",
|
||||
"@storybook/react": "^6.3.7",
|
||||
"@strapi/icons": "0.0.1-alpha.37",
|
||||
"@strapi/parts": "0.0.1-alpha.37",
|
||||
"@strapi/icons": "0.0.1-alpha.38",
|
||||
"@strapi/parts": "0.0.1-alpha.38",
|
||||
"babel-loader": "^8.2.2",
|
||||
"cross-env": "^7.0.3",
|
||||
"enzyme": "^3.8.0",
|
||||
|
File diff suppressed because one or more lines are too long
16
yarn.lock
16
yarn.lock
@ -4921,15 +4921,15 @@
|
||||
resolve-from "^5.0.0"
|
||||
store2 "^2.12.0"
|
||||
|
||||
"@strapi/icons@0.0.1-alpha.37":
|
||||
version "0.0.1-alpha.37"
|
||||
resolved "https://registry.yarnpkg.com/@strapi/icons/-/icons-0.0.1-alpha.37.tgz#65131221835227958d020f7c9910ab471834a515"
|
||||
integrity sha512-tUTKqQ+qQrt7V0qwoT/mHmyP/b/O1zk087nb8pjx22sjTXSyXToZW3RkMATn2RNF9MKGrKAQRswphyFY6Os+Yg==
|
||||
"@strapi/icons@0.0.1-alpha.38":
|
||||
version "0.0.1-alpha.38"
|
||||
resolved "https://registry.yarnpkg.com/@strapi/icons/-/icons-0.0.1-alpha.38.tgz#393b0e757bef37a476ebf755cf3603fa977757a4"
|
||||
integrity sha512-FQpt2KQLNVHHHOX26LvwO23EbOEDH5/jFZHQDLTuNmEjD14gNih9SwYr40MEMURrzlpHEOuEpAiooNHWIxMEoA==
|
||||
|
||||
"@strapi/parts@0.0.1-alpha.37":
|
||||
version "0.0.1-alpha.37"
|
||||
resolved "https://registry.yarnpkg.com/@strapi/parts/-/parts-0.0.1-alpha.37.tgz#1746151b0c86014da089761eec192920f4921ab0"
|
||||
integrity sha512-KdTJj/d0N3jfobmFkpy02pqnX4rsI5oUVIQ5EVSl9zV+8aagC76Txdb3tQdHFwVYTWHjpODoXpQqPduX+IvL0A==
|
||||
"@strapi/parts@0.0.1-alpha.38":
|
||||
version "0.0.1-alpha.38"
|
||||
resolved "https://registry.yarnpkg.com/@strapi/parts/-/parts-0.0.1-alpha.38.tgz#8873275e21a6162ffe6d6890bf5587189232a3a8"
|
||||
integrity sha512-rUJoqRAe85bENwr8JCBNyaVJ6sVZ8VEp60ueNGke205mCMoerPGirX4wovLCHu8PtfsAKinUi9eWfm6nbYMyiQ==
|
||||
dependencies:
|
||||
"@internationalized/number" "^3.0.2"
|
||||
compute-scroll-into-view "^1.0.17"
|
||||
|
Loading…
x
Reference in New Issue
Block a user