MCPcopy Create free account
hub / github.com/cafebazaar/blacksmith / updateOptionElement

Function updateOptionElement

web/static/bower_components/angular/angular.js:26558–26571  ·  view source on GitHub ↗
(option, element)

Source from the content-addressed store, hash-verified

26556
26557
26558 function updateOptionElement(option, element) {
26559 option.element = element;
26560 element.disabled = option.disabled;
26561 // NOTE: The label must be set before the value, otherwise IE10/11/EDGE create unresponsive
26562 // selects in certain circumstances when multiple selects are next to each other and display
26563 // the option list in listbox style, i.e. the select is [multiple], or specifies a [size].
26564 // See https://github.com/angular/angular.js/issues/11314 for more info.
26565 // This is unfortunately untestable with unit / e2e tests
26566 if (option.label !== element.label) {
26567 element.label = option.label;
26568 element.textContent = option.label;
26569 }
26570 if (option.value !== element.value) element.value = option.selectValue;
26571 }
26572
26573 function addOrReuseElement(parent, current, type, templateElement) {
26574 var element;

Callers 1

updateOptionsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected