fix(Splitter): fix the issue about Splitter had unexpected gaps in Flex (#51096)

This commit is contained in:
kiner-tang 2024-10-02 17:46:22 +08:00 committed by GitHub
parent d5ef5f3f2c
commit e8b0fc4925
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -146,7 +146,6 @@ const Splitter: React.FC<React.PropsWithChildren<SplitterProps>> = (props) => {
const mergedStyle: React.CSSProperties = { ...splitter?.style, ...style };
return wrapCSSVar(
<>
<ResizeObserver onResize={onContainerResize}>
<div style={mergedStyle} className={containerClassName}>
{items.map((item, idx) => {
@ -197,14 +196,12 @@ const Splitter: React.FC<React.PropsWithChildren<SplitterProps>> = (props) => {
</React.Fragment>
);
})}
</div>
</ResizeObserver>
{/* Fake mask for cursor */}
{typeof movingIndex === 'number' && (
<div aria-hidden className={classNames(maskCls, `${maskCls}-${layout}`)} />
)}
</>,
</div>
</ResizeObserver>,
);
};