File tree Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Original file line number Diff line number Diff line change 1818 < h1 > AngularJS Color Picker</ h1 >
1919 < p > An AngularJS directive for a color picker. No requirement on jQuery.</ p >
2020 {{color}}
21+ {{color()}}
2122 < color-picker
2223 ng-model ="color "
2324 ng-model-options ="{ getterSetter: true } "
Original file line number Diff line number Diff line change @@ -171,13 +171,14 @@ export default class AngularColorPickerController {
171171 }
172172
173173 init ( ) {
174- this . internalNgModel = this . ngModel ;
175174
176175 // ng model options
177176 if ( this . $scope . control [ 0 ] . $options && this . $scope . control [ 0 ] . $options . $$options ) {
178177 this . ngModelOptions = this . $scope . control [ 0 ] . $options . $$options ;
179178 }
180179
180+ this . internalNgModel = this . ngModelOptions . getterSetter ? this . ngModel ( ) : this . ngModel ;
181+
181182 // browser variables
182183 this . chrome = Boolean ( window . chrome ) ;
183184 let _android_version = window . navigator . userAgent . match ( / A n d r o i d \s ( [ 0 - 9 \. ] * ) / i) ;
You can’t perform that action at this time.
0 commit comments