Browse Source

fix #12758 multiple Select drop-down bug when set dropdownMatchSelectWidth

pull/12816/head
hengkx 6 years ago
parent
commit
6fcdce97f2
  1. 33
      components/select/demo/multiple.md
  2. 1
      components/select/style/index.less

33
components/select/demo/multiple.md

@ -28,14 +28,29 @@ function handleChange(value) {
}
ReactDOM.render(
<Select
mode="multiple"
style={{ width: '100%' }}
placeholder="Please select"
defaultValue={['a10', 'c12']}
onChange={handleChange}
>
{children}
</Select>,
<div>
<Select
mode="multiple"
style={{ width: '100%' }}
placeholder="Please select"
defaultValue={['a10', 'c12']}
onChange={handleChange}
>
{children}
</Select>
<Select
mode="multiple"
style={{ width: '100%' }}
placeholder="Please select"
onChange={handleChange}
dropdownMatchSelectWidth={false}
>
<Option value="jack">Jack</Option>
<Option value="lucy">Lucy</Option>
<Option value="disabled" >Disabled</Option>
<Option value="Yiminghe">yiminghe</Option>
<Option value="lucy">Lucy</Option>
</Select>
</div>,
mountNode);
````

1
components/select/style/index.less

@ -545,6 +545,7 @@
&&--multiple {
.@{select-prefix-cls}-dropdown-menu-item {
padding-right: @control-padding-horizontal + 20;
& .@{select-prefix-cls}-selected-icon {
color: transparent;
.iconfont-size-under-12px(10px);

Loading…
Cancel
Save