docs: Update Dropdown demo

This commit is contained in:
zombiej 2022-04-22 15:33:01 +08:00
parent cf2450e759
commit a513051761
3 changed files with 66 additions and 41 deletions

View File

@ -4270,28 +4270,39 @@ exports[`renders ./components/dropdown/demo/dropdown-button.md extend context co
class="ant-btn ant-btn-default ant-dropdown-trigger" class="ant-btn ant-btn-default ant-dropdown-trigger"
type="button" type="button"
> >
<span> <div
Button class="ant-space ant-space-horizontal ant-space-align-center"
</span>
<span
aria-label="down"
class="anticon anticon-down"
role="img"
> >
<svg <div
aria-hidden="true" class="ant-space-item"
data-icon="down" style="margin-right:8px"
fill="currentColor"
focusable="false"
height="1em"
viewBox="64 64 896 896"
width="1em"
> >
<path Button
d="M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z" </div>
/> <div
</svg> class="ant-space-item"
</span> >
<span
aria-label="down"
class="anticon anticon-down"
role="img"
>
<svg
aria-hidden="true"
data-icon="down"
fill="currentColor"
focusable="false"
height="1em"
viewBox="64 64 896 896"
width="1em"
>
<path
d="M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"
/>
</svg>
</span>
</div>
</div>
</button> </button>
<div> <div>
<div <div

View File

@ -340,28 +340,39 @@ exports[`renders ./components/dropdown/demo/dropdown-button.md correctly 1`] = `
class="ant-btn ant-btn-default ant-dropdown-trigger" class="ant-btn ant-btn-default ant-dropdown-trigger"
type="button" type="button"
> >
<span> <div
Button class="ant-space ant-space-horizontal ant-space-align-center"
</span>
<span
aria-label="down"
class="anticon anticon-down"
role="img"
> >
<svg <div
aria-hidden="true" class="ant-space-item"
data-icon="down" style="margin-right:8px"
fill="currentColor"
focusable="false"
height="1em"
viewBox="64 64 896 896"
width="1em"
> >
<path Button
d="M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z" </div>
/> <div
</svg> class="ant-space-item"
</span> >
<span
aria-label="down"
class="anticon anticon-down"
role="img"
>
<svg
aria-hidden="true"
data-icon="down"
fill="currentColor"
focusable="false"
height="1em"
viewBox="64 64 896 896"
width="1em"
>
<path
d="M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"
/>
</svg>
</span>
</div>
</div>
</button> </button>
</div> </div>
</div> </div>

View File

@ -74,7 +74,10 @@ export default () => (
</Dropdown.Button> </Dropdown.Button>
<Dropdown overlay={menu}> <Dropdown overlay={menu}>
<Button> <Button>
Button <DownOutlined /> <Space>
Button
<DownOutlined />
</Space>
</Button> </Button>
</Dropdown> </Dropdown>
</Space> </Space>