feat:🔥New Component: Splitter #50038
feat:🔥New Component: Splitter #50038zombieJ merged 123 commits intoant-design:featurefrom wanpan11:feat-splitPanel
Conversation
|
|
👁 Visual Regression Report for PR #50038 Failed ❌
Check Full Report for details If you think the visual diff is acceptable, please check:
|
More templates
commit: |
圆角拉线到边缘的时候会超出来,否则就要加一下 |
* feat: SplitPanel init * feat: SplitPanel update * feat: SplitPanel update * feat: splitPanel update useResize * feat: SplitPanel update * feat: splitPanel update useResize * feat: SplitPanel update * feat: splitPanel demo * feat: splitPanel update * feat: splitPanel support complicated combination * feat: SplitPanel rename to Splitter * feat: Splitter support onRize * feat: support collapsible * feat: support token and collapsible * feat: update docs * feat: size defaultSize support string * feat: min max support string * feat: update * feat: support DOM structure * feat: Optimize UI * feat: Optimize Code * fix: Add a default size during initialization to prevent failure to obtain container size * feat: optimized code * feat: optimized code * feat: Optimize Code * Update components/splitter/demo/layout.tsx Co-authored-by: lijianan <[email protected]> Signed-off-by: Wanpan <[email protected]> * Update components/splitter/demo/multiple.tsx Co-authored-by: lijianan <[email protected]> Signed-off-by: Wanpan <[email protected]> * docs: update * feat: Modify the style and optimize the interface * feat: use PropsWithChildren * feat: support rtl * feat: collapsible supports object types * fix: when collapsible is boolean not work * feat: Splitter add test * feat: update * test: update snapshots * docs: update * test: update snapshots * test: update * test: update * test: update * test: update * fix: Removed invalid min and max restrictions when collapsible exists * test: update * test: update * test: update * test: test coverage * Revert "test: test coverage" This reverts commit d247193. * test: test coverage * feat: rename * feat: optimized code * ci: lint * feat: optimized code * feat: add useag tips * feat: optimized code * feat: Modify splitbar layout * feat: optimized code * feat: numerical precision * feat: optimized code * feat: Optimized trigger region * feat: Support configuration animation * fix: Fix Collapsible exception when using multiple panels * fix: Fixed the issue of drag area overlapping when multiple panels are folded * feat: optimized code * feat: annotation * feAt: optimized code * fix: bgcolor * fix: Modify the initial value calculation method * test: update * feat: add cover image * chore: adjust logic * chore: use items size * chore: rtl * chore: limit * chore: controlled * docs: update demo * docs: adjust style * chore: add split style * chore: hor collapisble style * chore: collapse icon * chore: update warning * chore: clean up * chore: collapse logic * chore: adjust demo * chore: clean up * test: adjust logic * docs: update demo * docs: rm useless demo * docs: demo * test: add demo test * test: test of them * test: 100% coverage * chore: fix lint * docs: update demo * refactor: unique resize config * docs: add demo * fix: support virtual resiable * chore: add cursor mask * test: update snapshot * test: add test case * test: update snapshot * chore: use px base * chore: rm useless code --------- Signed-off-by: Wanpan <[email protected]> Co-authored-by: lijianan <[email protected]> Co-authored-by: 二货机器人 <[email protected]> Co-authored-by: ice <[email protected]>
|
Hello guys! I dont know if this is the right place to ask about this, but since this is a commit about the new component i think it might be. Could we add the option to set a custom icon to the splitter component instead of only the little line that it does? I know that it is customizable via the design token, but adding icons would be even better for UI. I'm talking about this guy: What do you think @li-jia-nan ? |
|
这个支持 lazy 模式吗? 这样只会 resize 一次,性能会好一些。 拖动过程中,可以有一个临时的 splitter 移动的效果。 |
目前不支持这个,可以试试在你的组件外层加一层 div 然后定义一个 width ,当 onResizeEnd 触发式 在更新这个 width |
Of course this is a good idea, I will add this feature later |
































中文版模板 / Chinese template
🤔 This is a ...
🔗 Related issue link
💡 Background and solution
demo 预览 看看大家的想法:https://preview-50038-ant-design.surge.sh/components/splitter-cn
@zombieJ Update:
size改成受控形式,并提供defaultSize进行初始化支持useSizeshooks 统一受控与非受控场景number类型值从 % 改为 pxonResize第二个index参数暂时移除,因为它对应到 Panel 而是 SplitBarcontext因为内聚后 Panel 不再需要消费collapsible支持与min组合使用,并且抽象useResizable聚合推导值transition属性📝 Changelog