-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Disable within disabled fieldset #772
base: master
Are you sure you want to change the base?
Conversation
…side a disabled field-set
…y are inside a disabled field-set" This reverts commit 8dd5e39.
element.append(disabledWatch); | ||
|
||
// Watch the disabled flag on disabledWatch, and set $select.disabled. | ||
scope.$watch(function () { return disabledWatch.is(":disabled"); }, function (value) { |
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.
.is() isn't part of angular.element so we'll be creating a dependency on jquery to make this work which we should avoid
What if we did this instead: if(!!disabledWatch.is) {
return disabledWatch.is(':disabled'); // Use jquery if available
}
return !!element[0].querySelector('.ui-select-disabled-watch:disabled'); I tested in in Chrome and Firefox and it worked fine. It doesn't seem to work in IE 11, but neither do fieldsets. Also maybe the unit tests shouldn't use jquery if dependency on jquery should be avoided. |
@rwlogel That seems to work. I ran the tests on my machine and updated the pull request with the change. |
hello? |
Any ETA for this merge? |
can anybody update on this merge ? |
This needs history cleaned up - there should be no revert commit. |
+1 |
What about merging this via squash merge? |
+1 |
Hi, I think people see what needs to be done to get this merged. Somebody maybe can make a new PR for this? |
disable ui-selects when inside a disabled fieldset