Select props dropdownStyle set left/top failure
See original GitHub issueEnvironment
antd 2.11.2
Reproduction link
[https://codepen.io/paranoidjk/pen/LWpaKe(我暂时无法提供 Link to minimal reproduction选项的Url,因此挂载上了默认提供的一个Url))
Steps to reproduce
<Select
mode='multiple'
notFoundContent={NOT_FOUNT_TEXT}
dropdownMatchSelectWidth={false}
onFocus={this.handleFocus.bind(this)}
onSelect={this.handleSelect.bind(this)}
onDeselect={this.handleDeslect.bind(this)}
onSearch={this.handleSearch.bind(this)}
getPopupContainer={() => document.getElementById('drop-down-area')}
***dropdownStyle={{ left: inputLeft, display: showDropDown ? '' : 'none' }}***
dropdownClassName='my-drop-down'
>
{
renderTags.map((d, i) => (<Option key={d.value}>{d.value}</Option>))
}
</Select>
What is expected?
I want to use dropdownStyle to control dropdown menu’s left/top i.e. its position params
What is actually happening?
The left/top params will be coverd by components params。 传入的style参数并不生效
Issue Analytics
- State:
- Created 6 years ago
- Comments:22 (11 by maintainers)
Top Results From Across the Web
unable to select item from react-native-dropdown-picker
am using React-native-dropdown-picker, however am unable to select any item from the dropdown list, the items are being overlapped by the ...
Read more >Customize the Ant Design Select Component - Level Up Coding
I recently answered a question on Stack Overflow where a user was trying to customize the layout/style of their Ant Design Select component....
Read more >Custom Select Component in React and Styled Components
A guide on how to create a custom dropdown in React.
Read more >How to style the Drop-Down List in ComboBox in C ...
Step 3: After drag and drop you will go to the properties of the ComboBox control to set the DropDownStyle property of the...
Read more >ComboBox.DropDownStyle Property (System.Windows.Forms)
Gets or sets a value specifying the style of the combo box.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
For anyone who is looking for the document, too: dependency chain:
Select.dropdownAlign
=>rc-select.dropdownAlign
=>rc-trigger.popupAlign
=>dom-align.alignConfig
rc-select rc-trigger dom-align
Dropdown and Select are all based on
rc-trigger
, In Select, it’s calleddropdownAlign
.https://codesandbox.io/s/ov56m6zk25