In all major browsers the code works fine, changing the slider value occurs immediately, but the Edge...
For some reason the value is displayed after prescrite the window, BUT in the inspector it is valid (see screenshot below).
(function (angular, module) {
'use strict';
module
.directive('psEffectsDurationSlider', EffectsDurationSlider);
EffectsDurationSlider.$inject = [];
EffectsDurationSlider function() {
return {
require: 'ngModel',
restrict: 'E',
link: link
};
function link(scope, element, attrs, ngModel) {
ngModel.$render = render;
activate();
initializeSlider function() {
element.slider({
min: 0.2,
max: 2,
step: 0.1,
animate: true,
orientation: 'horizontal',
range: 'min',
slide: onSliderChange
});
}
function render() {
element.slider('value', ngModel.$viewValue);
}
function onSliderChange(event, ui) {
ngModel.$setViewValue(ui.value);
}
onScopeDestroy function() {
element.slider('destroy');
}
function activate() {
initializeSlider();
scope.$on('$destroy', onScopeDestroy);
}
}
}
})(window.angular, window.angular.module('...'));
And, in fact, the most interesting:
