chore: auto merge branches (#46656)

chore: merge master into feature
This commit is contained in:
github-actions[bot] 2023-12-27 12:31:38 +00:00 committed by GitHub
commit 98ddc029f3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
27 changed files with 161 additions and 173 deletions

View File

@ -134,10 +134,28 @@ const GlobalLayout: React.FC = () => {
const [styleCache] = React.useState(() => createCache()); const [styleCache] = React.useState(() => createCache());
useServerInsertedHTML(() => { useServerInsertedHTML(() => {
const styleText = extractStyle(styleCache, true); const styleText = extractStyle(styleCache, {
plain: true,
types: 'style',
});
return <style data-type="antd-cssinjs" dangerouslySetInnerHTML={{ __html: styleText }} />; return <style data-type="antd-cssinjs" dangerouslySetInnerHTML={{ __html: styleText }} />;
}); });
useServerInsertedHTML(() => {
const styleText = extractStyle(styleCache, {
plain: true,
types: ['cssVar', 'token'],
});
return (
<style
data-type="antd-css-var"
data-rc-order="prepend"
data-rc-priority="-9999"
dangerouslySetInnerHTML={{ __html: styleText }}
/>
);
});
useServerInsertedHTML(() => ( useServerInsertedHTML(() => (
<style <style
data-sandpack="true" data-sandpack="true"

View File

@ -179,6 +179,15 @@ const RoutesPlugin = (api: IApi) => {
const cssFile = writeCSSFile('antd', antdStyle, antdStyle); const cssFile = writeCSSFile('antd', antdStyle, antdStyle);
file.content = addLinkStyle(file.content, cssFile, true); file.content = addLinkStyle(file.content, cssFile, true);
// Insert antd cssVar to head
const cssVarMatchRegex = /<style data-type="antd-css-var"[\S\s]+?<\/style>/;
const cssVarMatchList = file.content.match(cssVarMatchRegex) || [];
cssVarMatchList.forEach((text) => {
file.content = file.content.replace(text, '');
file.content = file.content.replace('<head>', `<head>${text}`);
});
return file; return file;
}), }),
); );
@ -190,20 +199,6 @@ const RoutesPlugin = (api: IApi) => {
return memo; return memo;
}); });
// zombieJ: Unique CSS file is large, we move to build css for each page.
// See the `modifyExportHTMLFiles` above.
// generate ssr css file
// api.onBuildHtmlComplete(() => {
// const styleCache = (global as any)?.styleCache;
// const styleText = styleCache ? extractStyle(styleCache) : '';
// const styleTextWithoutStyleTag = styleText
// .replace(/<style\s[^>]*>/g, '')
// .replace(/<\/style>/g, '');
// fs.writeFileSync(`./_site/${ssrCssFileName}`, styleTextWithoutStyleTag, 'utf8');
// });
}; };
export default RoutesPlugin; export default RoutesPlugin;

View File

@ -5,44 +5,24 @@
version: 2 version: 2
updates: updates:
- package-ecosystem: "npm" # See documentation for possible values - package-ecosystem: "npm"
directory: "/" # Location of package manifests directory: "/"
schedule: schedule:
interval: "daily" interval: "daily"
ignore: versioning-strategy: increase
- dependency-name: "rc-cascader" groups:
- dependency-name: "rc-checkbox" rc-component-patch:
- dependency-name: "rc-collapse" dependency-type: "production"
- dependency-name: "rc-dialog" patterns:
- dependency-name: "rc-drawer" - "rc-*"
- dependency-name: "rc-dropdown" - "@rc-component*"
- dependency-name: "rc-field-form" update-types: ["patch"]
- dependency-name: "rc-image" dependencies:
- dependency-name: "rc-input" dependency-type: "production"
- dependency-name: "rc-input-number" exclude-patterns:
- dependency-name: "rc-mentions" - "rc-*"
- dependency-name: "rc-menu" - "@rc-component*"
- dependency-name: "rc-motion" update-types: ["major", "minor"]
- dependency-name: "rc-notification" dev-dependencies:
- dependency-name: "rc-pagination" dependency-type: "development"
- dependency-name: "rc-picker" update-types: ["major", "minor"]
- dependency-name: "rc-progress"
- dependency-name: "rc-rate"
- dependency-name: "rc-resize-observer"
- dependency-name: "rc-select"
- dependency-name: "rc-segmented"
- dependency-name: "rc-slider"
- dependency-name: "rc-steps"
- dependency-name: "rc-switch"
- dependency-name: "rc-table"
- dependency-name: "rc-tabs"
- dependency-name: "rc-textarea"
- dependency-name: "rc-tooltip"
- dependency-name: "rc-tree"
- dependency-name: "rc-tree-select"
- dependency-name: "@rc-component/trigger"
- dependency-name: "@rc-component/tour"
- dependency-name: "@rc-component/mutate-observer"
- dependency-name: "@rc-component/color-picker"
- dependency-name: "rc-upload"
- dependency-name: "rc-util"

View File

@ -52,7 +52,7 @@ describe('Avatar Render', () => {
it('should handle onError correctly', () => { it('should handle onError correctly', () => {
const LOAD_FAILURE_SRC = 'http://error.url/'; const LOAD_FAILURE_SRC = 'http://error.url/';
const LOAD_SUCCESS_SRC = 'https://xsgames.co/randomusers/avatar.php?g=pixel'; const LOAD_SUCCESS_SRC = 'https://api.dicebear.com/7.x/pixel-art/svg';
const Foo: React.FC = () => { const Foo: React.FC = () => {
const [avatarSrc, setAvatarSrc] = useState<typeof LOAD_FAILURE_SRC | typeof LOAD_SUCCESS_SRC>( const [avatarSrc, setAvatarSrc] = useState<typeof LOAD_FAILURE_SRC | typeof LOAD_SUCCESS_SRC>(
LOAD_FAILURE_SRC, LOAD_FAILURE_SRC,
@ -74,7 +74,7 @@ describe('Avatar Render', () => {
it('should show image on success after a failure state', () => { it('should show image on success after a failure state', () => {
const LOAD_FAILURE_SRC = 'http://error.url'; const LOAD_FAILURE_SRC = 'http://error.url';
const LOAD_SUCCESS_SRC = 'https://xsgames.co/randomusers/avatar.php?g=pixel'; const LOAD_SUCCESS_SRC = 'https://api.dicebear.com/7.x/pixel-art/svg';
const div = global.document.createElement('div'); const div = global.document.createElement('div');
global.document.body.appendChild(div); global.document.body.appendChild(div);
@ -166,7 +166,7 @@ describe('Avatar Render', () => {
}); });
it('should exist crossorigin attribute', () => { it('should exist crossorigin attribute', () => {
const LOAD_SUCCESS_SRC = 'https://xsgames.co/randomusers/avatar.php?g=pixel'; const LOAD_SUCCESS_SRC = 'https://api.dicebear.com/7.x/pixel-art/svg';
const crossOrigin = 'anonymous'; const crossOrigin = 'anonymous';
const { container } = render( const { container } = render(
<Avatar src={LOAD_SUCCESS_SRC} crossOrigin={crossOrigin}> <Avatar src={LOAD_SUCCESS_SRC} crossOrigin={crossOrigin}>
@ -178,7 +178,7 @@ describe('Avatar Render', () => {
}); });
it('should not exist crossorigin attribute', () => { it('should not exist crossorigin attribute', () => {
const LOAD_SUCCESS_SRC = 'https://xsgames.co/randomusers/avatar.php?g=pixel'; const LOAD_SUCCESS_SRC = 'https://api.dicebear.com/7.x/pixel-art/svg';
const { container } = render(<Avatar src={LOAD_SUCCESS_SRC}>crossorigin</Avatar>); const { container } = render(<Avatar src={LOAD_SUCCESS_SRC}>crossorigin</Avatar>);
expect(container.querySelector('img')?.crossOrigin).toBeFalsy(); expect(container.querySelector('img')?.crossOrigin).toBeFalsy();
expect(container.querySelector('img')?.crossOrigin).toEqual(''); expect(container.querySelector('img')?.crossOrigin).toEqual('');

View File

@ -140,7 +140,7 @@ exports[`Avatar Render should handle onError correctly 1`] = `
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel" src="https://api.dicebear.com/7.x/pixel-art/svg"
/> />
</span> </span>
`; `;
@ -163,7 +163,7 @@ exports[`Avatar Render should show image on success after a failure state 2`] =
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel" src="https://api.dicebear.com/7.x/pixel-art/svg"
/> />
</span> </span>
`; `;

View File

@ -370,7 +370,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=2" src="https://api.dicebear.com/7.x/miniavs/svg?seed=2"
/> />
</span> </span>
<span <span
@ -656,7 +656,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=1" src="https://api.dicebear.com/7.x/miniavs/svg?seed=1"
/> />
</span> </span>
<a <a
@ -753,7 +753,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=2" src="https://api.dicebear.com/7.x/miniavs/svg?seed=2"
/> />
</span> </span>
<span <span
@ -879,7 +879,7 @@ Array [
class="ant-avatar ant-avatar-lg ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-lg ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=3" src="https://api.dicebear.com/7.x/miniavs/svg?seed=3"
/> />
</span> </span>
<span <span

View File

@ -366,7 +366,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=2" src="https://api.dicebear.com/7.x/miniavs/svg?seed=2"
/> />
</span> </span>
<span <span
@ -557,7 +557,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=1" src="https://api.dicebear.com/7.x/miniavs/svg?seed=1"
/> />
</span> </span>
<a <a
@ -635,7 +635,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=2" src="https://api.dicebear.com/7.x/miniavs/svg?seed=2"
/> />
</span> </span>
<span <span
@ -672,7 +672,7 @@ Array [
class="ant-avatar ant-avatar-lg ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-lg ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=3" src="https://api.dicebear.com/7.x/miniavs/svg?seed=3"
/> />
</span> </span>
<span <span

View File

@ -29,7 +29,7 @@ const App: React.FC = () => (
</Space> </Space>
<Space> <Space>
<Avatar.Group maxCount={2} maxStyle={{ color: '#f56a00', backgroundColor: '#fde3cf' }}> <Avatar.Group maxCount={2} maxStyle={{ color: '#f56a00', backgroundColor: '#fde3cf' }}>
<Avatar src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=2" /> <Avatar src="https://api.dicebear.com/7.x/miniavs/svg?seed=2" />
<Avatar style={{ backgroundColor: '#f56a00' }}>K</Avatar> <Avatar style={{ backgroundColor: '#f56a00' }}>K</Avatar>
<Tooltip title="Ant User" placement="top"> <Tooltip title="Ant User" placement="top">
<Avatar style={{ backgroundColor: '#87d068' }} icon={<UserOutlined />} /> <Avatar style={{ backgroundColor: '#87d068' }} icon={<UserOutlined />} />

View File

@ -5,7 +5,7 @@ import { Avatar, Divider, Tooltip } from 'antd';
const App: React.FC = () => ( const App: React.FC = () => (
<> <>
<Avatar.Group> <Avatar.Group>
<Avatar src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=1" /> <Avatar src="https://api.dicebear.com/7.x/miniavs/svg?seed=1" />
<a href="https://ant.design"> <a href="https://ant.design">
<Avatar style={{ backgroundColor: '#f56a00' }}>K</Avatar> <Avatar style={{ backgroundColor: '#f56a00' }}>K</Avatar>
</a> </a>
@ -16,7 +16,7 @@ const App: React.FC = () => (
</Avatar.Group> </Avatar.Group>
<Divider /> <Divider />
<Avatar.Group maxCount={2} maxStyle={{ color: '#f56a00', backgroundColor: '#fde3cf' }}> <Avatar.Group maxCount={2} maxStyle={{ color: '#f56a00', backgroundColor: '#fde3cf' }}>
<Avatar src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=2" /> <Avatar src="https://api.dicebear.com/7.x/miniavs/svg?seed=2" />
<Avatar style={{ backgroundColor: '#f56a00' }}>K</Avatar> <Avatar style={{ backgroundColor: '#f56a00' }}>K</Avatar>
<Tooltip title="Ant User" placement="top"> <Tooltip title="Ant User" placement="top">
<Avatar style={{ backgroundColor: '#87d068' }} icon={<UserOutlined />} /> <Avatar style={{ backgroundColor: '#87d068' }} icon={<UserOutlined />} />
@ -29,7 +29,7 @@ const App: React.FC = () => (
size="large" size="large"
maxStyle={{ color: '#f56a00', backgroundColor: '#fde3cf' }} maxStyle={{ color: '#f56a00', backgroundColor: '#fde3cf' }}
> >
<Avatar src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=3" /> <Avatar src="https://api.dicebear.com/7.x/miniavs/svg?seed=3" />
<Avatar style={{ backgroundColor: '#f56a00' }}>K</Avatar> <Avatar style={{ backgroundColor: '#f56a00' }}>K</Avatar>
<Tooltip title="Ant User" placement="top"> <Tooltip title="Ant User" placement="top">
<Avatar style={{ backgroundColor: '#87d068' }} icon={<UserOutlined />} /> <Avatar style={{ backgroundColor: '#87d068' }} icon={<UserOutlined />} />

View File

@ -16,7 +16,7 @@ const App: React.FC = () => {
<Switch checked={!loading} onChange={onChange} /> <Switch checked={!loading} onChange={onChange} />
<Card style={{ width: 300, marginTop: 16 }} loading={loading}> <Card style={{ width: 300, marginTop: 16 }} loading={loading}>
<Meta <Meta
avatar={<Avatar src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=1" />} avatar={<Avatar src="https://api.dicebear.com/7.x/miniavs/svg?seed=1" />}
title="Card title" title="Card title"
description="This is the description" description="This is the description"
/> />
@ -31,7 +31,7 @@ const App: React.FC = () => {
> >
<Skeleton loading={loading} avatar active> <Skeleton loading={loading} avatar active>
<Meta <Meta
avatar={<Avatar src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=2" />} avatar={<Avatar src="https://api.dicebear.com/7.x/miniavs/svg?seed=2" />}
title="Card title" title="Card title"
description="This is the description" description="This is the description"
/> />

View File

@ -117,7 +117,7 @@ const Sider = React.forwardRef<HTMLDivElement, SiderProps>((props, ref) => {
if (typeof window !== 'undefined') { if (typeof window !== 'undefined') {
const { matchMedia } = window; const { matchMedia } = window;
if (matchMedia! && breakpoint && breakpoint in dimensionMaxMap) { if (matchMedia! && breakpoint && breakpoint in dimensionMaxMap) {
mql = matchMedia(`(max-width: ${dimensionMaxMap[breakpoint]})`); mql = matchMedia(`screen and (max-width: ${dimensionMaxMap[breakpoint]})`);
try { try {
mql.addEventListener('change', responsiveHandler); mql.addEventListener('change', responsiveHandler);
} catch (error) { } catch (error) {

View File

@ -26,7 +26,7 @@ exports[`renders components/list/demo/basic.tsx extend context correctly 1`] = `
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=0" src="https://api.dicebear.com/7.x/miniavs/svg?seed=0"
/> />
</span> </span>
</div> </div>
@ -63,7 +63,7 @@ exports[`renders components/list/demo/basic.tsx extend context correctly 1`] = `
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=1" src="https://api.dicebear.com/7.x/miniavs/svg?seed=1"
/> />
</span> </span>
</div> </div>
@ -100,7 +100,7 @@ exports[`renders components/list/demo/basic.tsx extend context correctly 1`] = `
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=2" src="https://api.dicebear.com/7.x/miniavs/svg?seed=2"
/> />
</span> </span>
</div> </div>
@ -137,7 +137,7 @@ exports[`renders components/list/demo/basic.tsx extend context correctly 1`] = `
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=3" src="https://api.dicebear.com/7.x/miniavs/svg?seed=3"
/> />
</span> </span>
</div> </div>
@ -436,7 +436,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=0" src="https://api.dicebear.com/7.x/miniavs/svg?seed=0"
/> />
</span> </span>
</div> </div>
@ -473,7 +473,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=1" src="https://api.dicebear.com/7.x/miniavs/svg?seed=1"
/> />
</span> </span>
</div> </div>
@ -510,7 +510,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=2" src="https://api.dicebear.com/7.x/miniavs/svg?seed=2"
/> />
</span> </span>
</div> </div>
@ -547,7 +547,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=3" src="https://api.dicebear.com/7.x/miniavs/svg?seed=3"
/> />
</span> </span>
</div> </div>
@ -610,7 +610,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=0" src="https://api.dicebear.com/7.x/miniavs/svg?seed=0"
/> />
</span> </span>
</div> </div>
@ -647,7 +647,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=1" src="https://api.dicebear.com/7.x/miniavs/svg?seed=1"
/> />
</span> </span>
</div> </div>
@ -684,7 +684,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=2" src="https://api.dicebear.com/7.x/miniavs/svg?seed=2"
/> />
</span> </span>
</div> </div>
@ -721,7 +721,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=3" src="https://api.dicebear.com/7.x/miniavs/svg?seed=3"
/> />
</span> </span>
</div> </div>
@ -2023,7 +2023,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=0" src="https://api.dicebear.com/7.x/miniavs/svg?seed=0"
/> />
</span> </span>
</div> </div>
@ -2060,7 +2060,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=1" src="https://api.dicebear.com/7.x/miniavs/svg?seed=1"
/> />
</span> </span>
</div> </div>
@ -2097,7 +2097,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=2" src="https://api.dicebear.com/7.x/miniavs/svg?seed=2"
/> />
</span> </span>
</div> </div>
@ -2134,7 +2134,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=3" src="https://api.dicebear.com/7.x/miniavs/svg?seed=3"
/> />
</span> </span>
</div> </div>
@ -2748,7 +2748,7 @@ exports[`renders components/list/demo/vertical.tsx extend context correctly 1`]
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=0" src="https://api.dicebear.com/7.x/miniavs/svg?seed=0"
/> />
</span> </span>
</div> </div>
@ -2911,7 +2911,7 @@ exports[`renders components/list/demo/vertical.tsx extend context correctly 1`]
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=1" src="https://api.dicebear.com/7.x/miniavs/svg?seed=1"
/> />
</span> </span>
</div> </div>
@ -3074,7 +3074,7 @@ exports[`renders components/list/demo/vertical.tsx extend context correctly 1`]
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=2" src="https://api.dicebear.com/7.x/miniavs/svg?seed=2"
/> />
</span> </span>
</div> </div>

View File

@ -26,7 +26,7 @@ exports[`renders components/list/demo/basic.tsx correctly 1`] = `
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=0" src="https://api.dicebear.com/7.x/miniavs/svg?seed=0"
/> />
</span> </span>
</div> </div>
@ -63,7 +63,7 @@ exports[`renders components/list/demo/basic.tsx correctly 1`] = `
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=1" src="https://api.dicebear.com/7.x/miniavs/svg?seed=1"
/> />
</span> </span>
</div> </div>
@ -100,7 +100,7 @@ exports[`renders components/list/demo/basic.tsx correctly 1`] = `
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=2" src="https://api.dicebear.com/7.x/miniavs/svg?seed=2"
/> />
</span> </span>
</div> </div>
@ -137,7 +137,7 @@ exports[`renders components/list/demo/basic.tsx correctly 1`] = `
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=3" src="https://api.dicebear.com/7.x/miniavs/svg?seed=3"
/> />
</span> </span>
</div> </div>
@ -439,7 +439,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=0" src="https://api.dicebear.com/7.x/miniavs/svg?seed=0"
/> />
</span> </span>
</div> </div>
@ -476,7 +476,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=1" src="https://api.dicebear.com/7.x/miniavs/svg?seed=1"
/> />
</span> </span>
</div> </div>
@ -513,7 +513,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=2" src="https://api.dicebear.com/7.x/miniavs/svg?seed=2"
/> />
</span> </span>
</div> </div>
@ -550,7 +550,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=3" src="https://api.dicebear.com/7.x/miniavs/svg?seed=3"
/> />
</span> </span>
</div> </div>
@ -613,7 +613,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=0" src="https://api.dicebear.com/7.x/miniavs/svg?seed=0"
/> />
</span> </span>
</div> </div>
@ -650,7 +650,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=1" src="https://api.dicebear.com/7.x/miniavs/svg?seed=1"
/> />
</span> </span>
</div> </div>
@ -687,7 +687,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=2" src="https://api.dicebear.com/7.x/miniavs/svg?seed=2"
/> />
</span> </span>
</div> </div>
@ -724,7 +724,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=3" src="https://api.dicebear.com/7.x/miniavs/svg?seed=3"
/> />
</span> </span>
</div> </div>
@ -2016,7 +2016,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=0" src="https://api.dicebear.com/7.x/miniavs/svg?seed=0"
/> />
</span> </span>
</div> </div>
@ -2053,7 +2053,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=1" src="https://api.dicebear.com/7.x/miniavs/svg?seed=1"
/> />
</span> </span>
</div> </div>
@ -2090,7 +2090,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=2" src="https://api.dicebear.com/7.x/miniavs/svg?seed=2"
/> />
</span> </span>
</div> </div>
@ -2127,7 +2127,7 @@ Array [
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=3" src="https://api.dicebear.com/7.x/miniavs/svg?seed=3"
/> />
</span> </span>
</div> </div>
@ -2728,7 +2728,7 @@ exports[`renders components/list/demo/vertical.tsx correctly 1`] = `
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=0" src="https://api.dicebear.com/7.x/miniavs/svg?seed=0"
/> />
</span> </span>
</div> </div>
@ -2891,7 +2891,7 @@ exports[`renders components/list/demo/vertical.tsx correctly 1`] = `
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=1" src="https://api.dicebear.com/7.x/miniavs/svg?seed=1"
/> />
</span> </span>
</div> </div>
@ -3054,7 +3054,7 @@ exports[`renders components/list/demo/vertical.tsx correctly 1`] = `
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=2" src="https://api.dicebear.com/7.x/miniavs/svg?seed=2"
/> />
</span> </span>
</div> </div>

View File

@ -23,7 +23,7 @@ const App: React.FC = () => (
renderItem={(item, index) => ( renderItem={(item, index) => (
<List.Item> <List.Item>
<List.Item.Meta <List.Item.Meta
avatar={<Avatar src={`https://xsgames.co/randomusers/avatar.php?g=pixel&key=${index}`} />} avatar={<Avatar src={`https://api.dicebear.com/7.x/miniavs/svg?seed=${index}`} />}
title={<a href="https://ant.design">{item.title}</a>} title={<a href="https://ant.design">{item.title}</a>}
description="Ant Design, a design language for background applications, is refined by Ant UED Team" description="Ant Design, a design language for background applications, is refined by Ant UED Team"
/> />

View File

@ -80,9 +80,7 @@ const App: React.FC = () => (
renderItem={(item, index) => ( renderItem={(item, index) => (
<List.Item> <List.Item>
<List.Item.Meta <List.Item.Meta
avatar={ avatar={<Avatar src={`https://api.dicebear.com/7.x/miniavs/svg?seed=${index}`} />}
<Avatar src={`https://xsgames.co/randomusers/avatar.php?g=pixel&key=${index}`} />
}
title={<a href="https://ant.design">{item.title}</a>} title={<a href="https://ant.design">{item.title}</a>}
description="Ant Design, a design language for background applications, is refined by Ant UED Team" description="Ant Design, a design language for background applications, is refined by Ant UED Team"
/> />
@ -96,9 +94,7 @@ const App: React.FC = () => (
renderItem={(item, index) => ( renderItem={(item, index) => (
<List.Item> <List.Item>
<List.Item.Meta <List.Item.Meta
avatar={ avatar={<Avatar src={`https://api.dicebear.com/7.x/miniavs/svg?seed=${index}`} />}
<Avatar src={`https://xsgames.co/randomusers/avatar.php?g=pixel&key=${index}`} />
}
title={<a href="https://ant.design">{item.title}</a>} title={<a href="https://ant.design">{item.title}</a>}
description="Ant Design, a design language for background applications, is refined by Ant UED Team" description="Ant Design, a design language for background applications, is refined by Ant UED Team"
/> />

View File

@ -70,9 +70,7 @@ const App: React.FC = () => {
renderItem={(item, index) => ( renderItem={(item, index) => (
<List.Item> <List.Item>
<List.Item.Meta <List.Item.Meta
avatar={ avatar={<Avatar src={`https://api.dicebear.com/7.x/miniavs/svg?seed=${index}`} />}
<Avatar src={`https://xsgames.co/randomusers/avatar.php?g=pixel&key=${index}`} />
}
title={<a href="https://ant.design">{item.title}</a>} title={<a href="https://ant.design">{item.title}</a>}
description="Ant Design, a design language for background applications, is refined by Ant UED Team" description="Ant Design, a design language for background applications, is refined by Ant UED Team"
/> />

View File

@ -5,7 +5,7 @@ import { Avatar, List, Space } from 'antd';
const data = Array.from({ length: 23 }).map((_, i) => ({ const data = Array.from({ length: 23 }).map((_, i) => ({
href: 'https://ant.design', href: 'https://ant.design',
title: `ant design part ${i}`, title: `ant design part ${i}`,
avatar: `https://xsgames.co/randomusers/avatar.php?g=pixel&key=${i}`, avatar: `https://api.dicebear.com/7.x/miniavs/svg?seed=${i}`,
description: description:
'Ant Design, a design language for background applications, is refined by Ant UED Team.', 'Ant Design, a design language for background applications, is refined by Ant UED Team.',
content: content:

View File

@ -113,6 +113,9 @@ const InternalSelect = <
style, style,
allowClear, allowClear,
variant: customizeVariant, variant: customizeVariant,
dropdownStyle,
transitionName,
tagRender,
...rest ...rest
} = props; } = props;
@ -153,6 +156,7 @@ const InternalSelect = <
}, [props.mode]); }, [props.mode]);
const isMultiple = mode === 'multiple' || mode === 'tags'; const isMultiple = mode === 'multiple' || mode === 'tags';
const showSuffixIcon = useShowArrow(props.suffixIcon, props.showArrow); const showSuffixIcon = useShowArrow(props.suffixIcon, props.showArrow);
const mergedPopupMatchSelectWidth = const mergedPopupMatchSelectWidth =
@ -190,10 +194,7 @@ const InternalSelect = <
const mergedAllowClear = allowClear === true ? { clearIcon } : allowClear; const mergedAllowClear = allowClear === true ? { clearIcon } : allowClear;
const selectProps = omit(rest as typeof rest & { itemIcon: React.ReactNode }, [ const selectProps = omit(rest, ['suffixIcon', 'itemIcon' as any]);
'suffixIcon',
'itemIcon',
]);
const mergedPopupClassName = classNames( const mergedPopupClassName = classNames(
popupClassName || dropdownClassName, popupClassName || dropdownClassName,
@ -262,7 +263,7 @@ const InternalSelect = <
} }
// ====================== zIndex ========================= // ====================== zIndex =========================
const [zIndex] = useZIndex('SelectLike', props.dropdownStyle?.zIndex as number); const [zIndex] = useZIndex('SelectLike', dropdownStyle?.zIndex as number);
// ====================== Render ======================= // ====================== Render =======================
return wrapCSSVar( return wrapCSSVar(
@ -274,7 +275,7 @@ const InternalSelect = <
style={{ ...select?.style, ...style }} style={{ ...select?.style, ...style }}
dropdownMatchSelectWidth={mergedPopupMatchSelectWidth} dropdownMatchSelectWidth={mergedPopupMatchSelectWidth}
builtinPlacements={mergedBuiltinPlacements} builtinPlacements={mergedBuiltinPlacements}
transitionName={getTransitionName(rootPrefixCls, 'slide-up', props.transitionName)} transitionName={getTransitionName(rootPrefixCls, 'slide-up', transitionName)}
listHeight={listHeight} listHeight={listHeight}
listItemHeight={listItemHeight} listItemHeight={listItemHeight}
mode={mode} mode={mode}
@ -290,10 +291,8 @@ const InternalSelect = <
getPopupContainer={getPopupContainer || getContextPopupContainer} getPopupContainer={getPopupContainer || getContextPopupContainer}
dropdownClassName={mergedPopupClassName} dropdownClassName={mergedPopupClassName}
disabled={mergedDisabled} disabled={mergedDisabled}
dropdownStyle={{ dropdownStyle={{ ...dropdownStyle, zIndex }}
...props?.dropdownStyle, tagRender={tagRender}
zIndex,
}}
/>, />,
); );
}; };

View File

@ -131,6 +131,16 @@ const genSingleStyle: GenerateStyle<SelectToken> = (token) => {
[`${selectItemCls}-option-state`]: { [`${selectItemCls}-option-state`]: {
color: token.colorPrimary, color: token.colorPrimary,
}, },
[`&:has(+ ${selectItemCls}-option-selected:not(${selectItemCls}-option-disabled))`]: {
borderEndStartRadius: 0,
borderEndEndRadius: 0,
[`& + ${selectItemCls}-option-selected:not(${selectItemCls}-option-disabled)`]: {
borderStartStartRadius: 0,
borderStartEndRadius: 0,
},
},
}, },
'&-disabled': { '&-disabled': {
[`&${selectItemCls}-option-selected`]: { [`&${selectItemCls}-option-selected`]: {

View File

@ -11,7 +11,7 @@ interface IconTextProps {
const listData = Array.from({ length: 3 }).map((_, i) => ({ const listData = Array.from({ length: 3 }).map((_, i) => ({
href: 'https://ant.design', href: 'https://ant.design',
title: `ant design part ${i + 1}`, title: `ant design part ${i + 1}`,
avatar: `https://xsgames.co/randomusers/avatar.php?g=pixel&key=${i}`, avatar: `https://api.dicebear.com/7.x/miniavs/svg?seed=${i}`,
description: description:
'Ant Design, a design language for background applications, is refined by Ant UED Team.', 'Ant Design, a design language for background applications, is refined by Ant UED Team.',
content: content:

View File

@ -1573,7 +1573,7 @@ exports[`renders components/steps/demo/inline.tsx extend context correctly 1`] =
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=0" src="https://api.dicebear.com/7.x/miniavs/svg?seed=0"
/> />
</span> </span>
</div> </div>
@ -1780,7 +1780,7 @@ exports[`renders components/steps/demo/inline.tsx extend context correctly 1`] =
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=1" src="https://api.dicebear.com/7.x/miniavs/svg?seed=1"
/> />
</span> </span>
</div> </div>
@ -1987,7 +1987,7 @@ exports[`renders components/steps/demo/inline.tsx extend context correctly 1`] =
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=2" src="https://api.dicebear.com/7.x/miniavs/svg?seed=2"
/> />
</span> </span>
</div> </div>
@ -2194,7 +2194,7 @@ exports[`renders components/steps/demo/inline.tsx extend context correctly 1`] =
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=3" src="https://api.dicebear.com/7.x/miniavs/svg?seed=3"
/> />
</span> </span>
</div> </div>

View File

@ -1463,7 +1463,7 @@ exports[`renders components/steps/demo/inline.tsx correctly 1`] = `
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=0" src="https://api.dicebear.com/7.x/miniavs/svg?seed=0"
/> />
</span> </span>
</div> </div>
@ -1613,7 +1613,7 @@ exports[`renders components/steps/demo/inline.tsx correctly 1`] = `
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=1" src="https://api.dicebear.com/7.x/miniavs/svg?seed=1"
/> />
</span> </span>
</div> </div>
@ -1763,7 +1763,7 @@ exports[`renders components/steps/demo/inline.tsx correctly 1`] = `
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=2" src="https://api.dicebear.com/7.x/miniavs/svg?seed=2"
/> />
</span> </span>
</div> </div>
@ -1913,7 +1913,7 @@ exports[`renders components/steps/demo/inline.tsx correctly 1`] = `
class="ant-avatar ant-avatar-circle ant-avatar-image" class="ant-avatar ant-avatar-circle ant-avatar-image"
> >
<img <img
src="https://xsgames.co/randomusers/avatar.php?g=pixel&key=3" src="https://api.dicebear.com/7.x/miniavs/svg?seed=3"
/> />
</span> </span>
</div> </div>

View File

@ -45,9 +45,7 @@ const App: React.FC = () => (
renderItem={(item, index) => ( renderItem={(item, index) => (
<List.Item> <List.Item>
<List.Item.Meta <List.Item.Meta
avatar={ avatar={<Avatar src={`https://api.dicebear.com/7.x/miniavs/svg?seed=${index}`} />}
<Avatar src={`https://xsgames.co/randomusers/avatar.php?g=pixel&key=${index}`} />
}
title={<a href="https://ant.design">{item.title}</a>} title={<a href="https://ant.design">{item.title}</a>}
description="Ant Design, a design language for background applications, is refined by Ant UED Team" description="Ant Design, a design language for background applications, is refined by Ant UED Team"
/> />

View File

@ -6,7 +6,7 @@
对某一列数据进行排序,通过指定列的 `sorter` 函数即可启动排序按钮。`sorter: function(rowA, rowB) { ... }` rowA、rowB 为比较的两个行数据。 对某一列数据进行排序,通过指定列的 `sorter` 函数即可启动排序按钮。`sorter: function(rowA, rowB) { ... }` rowA、rowB 为比较的两个行数据。
`sortDirections: ['ascend' | 'descend']`改变每列可用的排序方式,切换排序时按数组内容依次切换,设置在 table props 上时对所有列生效。你可以通过设置 `['ascend', 'descend', 'ascend']` 禁止排序恢复到默认状态。 `sortDirections: ['ascend', 'descend']` 改变每列可用的排序方式,切换排序时按数组内容依次切换,设置在 table props 上时对所有列生效。你可以通过设置 `['ascend', 'descend', 'ascend']` 禁止排序恢复到默认状态。
使用 `defaultSortOrder` 属性,设置列的默认排序顺序。 使用 `defaultSortOrder` 属性,设置列的默认排序顺序。
@ -20,7 +20,7 @@ Use `defaultFilteredValue` to make a column filtered by default.
Use `sorter` to make a column sortable. `sorter` can be a function of the type `sorter: function(rowA, rowB) { ... }` for sorting data locally. Use `sorter` to make a column sortable. `sorter` can be a function of the type `sorter: function(rowA, rowB) { ... }` for sorting data locally.
`sortDirections: ['ascend' | 'descend']` defines available sort methods for each columns, effective for all columns when set on table props. You can set as `['ascend', 'descend', 'ascend']` to prevent sorter back to default status. `sortDirections: ['ascend', 'descend']` defines available sort methods for each columns, effective for all columns when set on table props. You can set as `['ascend', 'descend', 'ascend']` to prevent sorter back to default status.
Use `defaultSortOrder` to make a column sorted by default. Use `defaultSortOrder` to make a column sorted by default.

View File

@ -70,6 +70,8 @@ const genFixedStyle: GenerateStyle<TableToken, CSSObject> = (token) => {
}, },
[`${componentCls}-container`]: { [`${componentCls}-container`]: {
position: 'relative',
'&::before, &::after': { '&::before, &::after': {
position: 'absolute', position: 'absolute',
top: 0, top: 0,
@ -91,12 +93,8 @@ const genFixedStyle: GenerateStyle<TableToken, CSSObject> = (token) => {
}, },
[`${componentCls}-ping-left`]: { [`${componentCls}-ping-left`]: {
[`&:not(${componentCls}-has-fix-left) ${componentCls}-container`]: { [`&:not(${componentCls}-has-fix-left) ${componentCls}-container::before`]: {
position: 'relative', boxShadow: `inset 10px 0 8px -8px ${shadowColor}`,
'&::before': {
boxShadow: `inset 10px 0 8px -8px ${shadowColor}`,
},
}, },
[` [`
@ -112,12 +110,8 @@ const genFixedStyle: GenerateStyle<TableToken, CSSObject> = (token) => {
}, },
[`${componentCls}-ping-right`]: { [`${componentCls}-ping-right`]: {
[`&:not(${componentCls}-has-fix-right) ${componentCls}-container`]: { [`&:not(${componentCls}-has-fix-right) ${componentCls}-container::after`]: {
position: 'relative', boxShadow: `inset -10px 0 8px -8px ${shadowColor}`,
'&::after': {
boxShadow: `inset -10px 0 8px -8px ${shadowColor}`,
},
}, },
[` [`

View File

@ -117,6 +117,8 @@ const InternalTreeSelect = <
popupMatchSelectWidth, popupMatchSelectWidth,
allowClear, allowClear,
variant: customVariant, variant: customVariant,
dropdownStyle,
tagRender,
...props ...props
}: TreeSelectProps<ValueType, OptionType>, }: TreeSelectProps<ValueType, OptionType>,
ref: React.Ref<BaseSelectRef>, ref: React.Ref<BaseSelectRef>,
@ -220,12 +222,12 @@ const InternalTreeSelect = <
} }
// ==================== Render ===================== // ==================== Render =====================
const selectProps = omit(props as typeof props & { itemIcon: any; switcherIcon: any }, [ const selectProps = omit(props, [
'suffixIcon', 'suffixIcon',
'itemIcon',
'removeIcon', 'removeIcon',
'clearIcon', 'clearIcon',
'switcherIcon', 'itemIcon' as any,
'switcherIcon' as any,
]); ]);
// ===================== Placement ===================== // ===================== Placement =====================
@ -273,7 +275,7 @@ const InternalTreeSelect = <
); );
// ============================ zIndex ============================ // ============================ zIndex ============================
const [zIndex] = useZIndex('SelectLike', props.dropdownStyle?.zIndex as number); const [zIndex] = useZIndex('SelectLike', dropdownStyle?.zIndex as number);
const returnNode = ( const returnNode = (
<RcTreeSelect <RcTreeSelect
@ -302,13 +304,11 @@ const InternalTreeSelect = <
getPopupContainer={getPopupContainer || getContextPopupContainer} getPopupContainer={getPopupContainer || getContextPopupContainer}
treeMotion={null} treeMotion={null}
dropdownClassName={mergedDropdownClassName} dropdownClassName={mergedDropdownClassName}
dropdownStyle={{ dropdownStyle={{ ...dropdownStyle, zIndex }}
...props.dropdownStyle,
zIndex,
}}
choiceTransitionName={getTransitionName(rootPrefixCls, '', choiceTransitionName)} choiceTransitionName={getTransitionName(rootPrefixCls, '', choiceTransitionName)}
transitionName={getTransitionName(rootPrefixCls, 'slide-up', transitionName)} transitionName={getTransitionName(rootPrefixCls, 'slide-up', transitionName)}
treeExpandAction={treeExpandAction} treeExpandAction={treeExpandAction}
tagRender={tagRender}
/> />
); );

View File

@ -117,15 +117,15 @@
"@ant-design/cssinjs": "^1.18.2", "@ant-design/cssinjs": "^1.18.2",
"@ant-design/icons": "^5.2.6", "@ant-design/icons": "^5.2.6",
"@ant-design/react-slick": "~1.0.2", "@ant-design/react-slick": "~1.0.2",
"@babel/runtime": "^7.23.4", "@babel/runtime": "^7.23.6",
"@ctrl/tinycolor": "^3.6.1", "@ctrl/tinycolor": "^3.6.1",
"@rc-component/color-picker": "~1.4.1", "@rc-component/color-picker": "~1.4.1",
"@rc-component/mutate-observer": "^1.1.0", "@rc-component/mutate-observer": "^1.1.0",
"@rc-component/tour": "~1.12.0", "@rc-component/tour": "~1.12.0",
"@rc-component/trigger": "^1.18.2", "@rc-component/trigger": "^1.18.2",
"classnames": "^2.3.2", "classnames": "^2.4.0",
"copy-to-clipboard": "^3.3.3", "copy-to-clipboard": "^3.3.3",
"dayjs": "^1.11.1", "dayjs": "^1.11.10",
"qrcode.react": "^3.1.0", "qrcode.react": "^3.1.0",
"rc-cascader": "~3.20.0", "rc-cascader": "~3.20.0",
"rc-checkbox": "~3.1.0", "rc-checkbox": "~3.1.0",
@ -345,11 +345,11 @@
"size-limit": [ "size-limit": [
{ {
"path": "./dist/antd.min.js", "path": "./dist/antd.min.js",
"limit": "330 KiB" "limit": "331 KiB"
}, },
{ {
"path": "./dist/antd-with-locales.min.js", "path": "./dist/antd-with-locales.min.js",
"limit": "376 KiB" "limit": "377 KiB"
} }
], ],
"title": "Ant Design", "title": "Ant Design",