@@ -100,6 +100,8 @@ exports.valObjectMeta = {
100
100
requiredOpts : [ ] ,
101
101
otherOpts : [ 'dflt' , 'min' , 'max' , 'arrayOk' ] ,
102
102
coerceFunction : function ( v , propOut , dflt , opts ) {
103
+ if ( isTypedArraySpec ( v ) ) v = decodeTypedArraySpec ( v ) ;
104
+
103
105
if ( ! isNumeric ( v ) ||
104
106
( opts . min !== undefined && v < opts . min ) ||
105
107
( opts . max !== undefined && v > opts . max ) ) {
@@ -121,6 +123,8 @@ exports.valObjectMeta = {
121
123
return ;
122
124
}
123
125
126
+ if ( isTypedArraySpec ( v ) ) v = decodeTypedArraySpec ( v ) ;
127
+
124
128
if ( v % 1 || ! isNumeric ( v ) ||
125
129
( opts . min !== undefined && v < opts . min ) ||
126
130
( opts . max !== undefined && v > opts . max ) ) {
@@ -161,6 +165,8 @@ exports.valObjectMeta = {
161
165
requiredOpts : [ ] ,
162
166
otherOpts : [ 'dflt' , 'arrayOk' ] ,
163
167
coerceFunction : function ( v , propOut , dflt ) {
168
+ if ( isTypedArraySpec ( v ) ) v = decodeTypedArraySpec ( v ) ;
169
+
164
170
if ( tinycolor ( v ) . isValid ( ) ) propOut . set ( v ) ;
165
171
else propOut . set ( dflt ) ;
166
172
}
@@ -203,6 +209,8 @@ exports.valObjectMeta = {
203
209
requiredOpts : [ ] ,
204
210
otherOpts : [ 'dflt' , 'arrayOk' ] ,
205
211
coerceFunction : function ( v , propOut , dflt ) {
212
+ if ( isTypedArraySpec ( v ) ) v = decodeTypedArraySpec ( v ) ;
213
+
206
214
if ( v === 'auto' ) propOut . set ( 'auto' ) ;
207
215
else if ( ! isNumeric ( v ) ) propOut . set ( dflt ) ;
208
216
else propOut . set ( modHalf ( + v , 360 ) ) ;
0 commit comments