-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[#2667]fix the bug of the data-size when the first option style has 'display: none' #2713
[#2667]fix the bug of the data-size when the first option style has 'display: none' #2713
Conversation
js/bootstrap-select.js
Outdated
@@ -1920,7 +1920,8 @@ | |||
if (this.selectpicker.current.data.length) { | |||
for (var i = 0; i < this.selectpicker.current.data.length; i++) { | |||
var data = this.selectpicker.current.data[i]; | |||
if (data.type === 'option') { | |||
var a = data.element.firstChild; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
a
is a poor variable name choice
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for your contribution. This change would be a good opportunity to add a test case in the tests
folder (even if we don't currently test automatically for things yet). Basically an example showing the problem, and showing that with this PR the problem goes away!
thank you for reviewing. I added a test (febdfea) and pasted the capture. How about that? problemfixed |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, looks good to me!
resolved: #2667