Closed doyoucrm closed 5 years ago
P.S. to the community: I get that this repo has been virtually forgotten by Microsoft these days, but it's still worth logging issues and feature-requests in case some brave person wants to fork the repo.
Microsoft no longer supports this content and will not be responding to bugs or issues. We recommend that you use the newer version, Office UI Fabric, with React as your front-end framework. We are closing this issue; if you still need assistance with Fabric.js, visit Stack Overflow/office-ui-fabric.
This may be more of a feature request since there are a number of work-arounds. However, I find it frustrating that initialized Dropdowns don't copy
data
attributes (orclass
or any other attribute for that matter) from the original option elements.Obviously copying the id attribute is out of the question, but at the very least, it would be tremendously helpful for the new li elements that are created when the Dropdown is initialized to include data attributes from the original option elements.
Again...there are already plenty of other ways to work with these elements. There's data-binding with frameworks like Knockout, or you can easily use jQuery or vanilla JavaScript to get the nth child of either the
select
orul
elements to do your own binding.But still... if the Dropdown's
li
elements could just be natively initialized with thedata
attributes from the originaloption
elements, it would save a lot of time writing methods for handling this.