docs: update draggable demo with rtl mode (#34785)

* docs: update draggable demo with rtl mode

* test: update tabs demo snapshot
This commit is contained in:
miracles1919 2022-03-31 14:06:44 +08:00 committed by GitHub
parent f5c6379bba
commit 550f60ff76
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 11 additions and 13 deletions

View File

@ -945,8 +945,7 @@ exports[`renders ./components/tabs/demo/custom-tab-bar-node.md extend context co
style="transform:translate(0px, 0px)"
>
<div
class=""
style="margin-right:24px"
class="dragnode "
>
<div
class="ant-tabs-tab ant-tabs-tab-active"
@ -962,8 +961,7 @@ exports[`renders ./components/tabs/demo/custom-tab-bar-node.md extend context co
</div>
</div>
<div
class=""
style="margin-right:24px"
class="dragnode "
>
<div
class="ant-tabs-tab"
@ -979,8 +977,7 @@ exports[`renders ./components/tabs/demo/custom-tab-bar-node.md extend context co
</div>
</div>
<div
class=""
style="margin-right:24px"
class="dragnode "
>
<div
class="ant-tabs-tab"

View File

@ -831,8 +831,7 @@ exports[`renders ./components/tabs/demo/custom-tab-bar-node.md correctly 1`] = `
style="transform:translate(0px, 0px)"
>
<div
class=""
style="margin-right:24px"
class="dragnode "
>
<div
class="ant-tabs-tab ant-tabs-tab-active"
@ -848,8 +847,7 @@ exports[`renders ./components/tabs/demo/custom-tab-bar-node.md correctly 1`] = `
</div>
</div>
<div
class=""
style="margin-right:24px"
class="dragnode "
>
<div
class="ant-tabs-tab"
@ -865,8 +863,7 @@ exports[`renders ./components/tabs/demo/custom-tab-bar-node.md correctly 1`] = `
</div>
</div>
<div
class=""
style="margin-right:24px"
class="dragnode "
>
<div
class="ant-tabs-tab"

View File

@ -50,7 +50,7 @@ const DraggableTabNode = ({ index, children, moveNode }) => {
});
drop(drag(ref));
return (
<div ref={ref} style={{ marginRight: 24 }} className={isOver ? dropClassName : ''}>
<div ref={ref} className={`dragnode ${isOver ? dropClassName : ''}`}>
{children}
</div>
);
@ -152,4 +152,8 @@ ReactDOM.render(
background: #fefefe;
transition: all 0.3s;
}
.dragnode {
margin-inline-end: 24px;
}
```