File tree Expand file tree Collapse file tree 7 files changed +20
-8
lines changed Expand file tree Collapse file tree 7 files changed +20
-8
lines changed Original file line number Diff line number Diff line change 1
1
## Changelog for vue-autoNumeric
2
2
3
+ ### 1.2.6
4
+ + Fixes #24 VueAutonumeric value prop validator should accept strings
5
+
3
6
### 1.2.5
4
7
+ Fixes #14 The ` readOnly ` option is not respected for non-input tags (` contenteditable ` is always set to ` true ` )
5
8
Original file line number Diff line number Diff line change @@ -225,7 +225,7 @@ Huge Thanks :)
225
225
226
226
### License
227
227
228
- ` vue-autoNumeric ` is open source and released under the [ MIT License] ( https://github.com/autoNumeric/vue-autoNumeric/blob/master/LICENSE ) .
228
+ ` vue-autoNumeric ` is open- source and released under the [ MIT License] ( https://github.com/autoNumeric/vue-autoNumeric/blob/master/LICENSE ) .
229
229
230
230
<br >Copyright © 2016-2018 Alexandre Bonneau
231
231
Original file line number Diff line number Diff line change 1
1
/**
2
- * vue-autonumeric v1.2.5 (https://github.com/autoNumeric/vue-autoNumeric)
2
+ * vue-autonumeric v1.2.6 (https://github.com/autoNumeric/vue-autoNumeric)
3
3
* © 2018 Alexandre Bonneau <alexandre.bonneau@linuxfr.eu>
4
4
* Released under the MIT License.
5
5
*/
@@ -346,7 +346,7 @@ exports.default = {
346
346
value : {
347
347
required : false ,
348
348
validator : function validator ( val ) {
349
- return typeof val === 'number' || val === '' || val === null ;
349
+ return typeof val === 'number' || typeof val === 'string' || val === '' || val === null ;
350
350
}
351
351
} ,
352
352
Original file line number Diff line number Diff line change 279
279
<div class =" rawValue" >{{ externalTracker }}</div >
280
280
</div >
281
281
</div >
282
+
283
+ <div :class =" boxClasses" :style =" boxStyle" >
284
+ <div :class =" labelClasses" >Text variable for the value (cf. issue #24)</div >
285
+ <div class =" inputAndRawValue" >
286
+ <vue-autonumeric :options =" ''" v-model =" textAnModel" />
287
+ <div class =" rawValue" >{{ textAnModel }}</div >
288
+ </div >
289
+ </div >
282
290
</div >
283
291
</div >
284
292
</div >
300
308
autoNumericModel : 221456.72 , // Default value for the examples
301
309
autoNumericModel2: 12468.642 ,
302
310
autoNumericModel3: 221226.44 ,
311
+ textAnModel : ' 12468.02' ,
303
312
anModel : 42.01 ,
304
313
emptyValue : ' ' ,
305
314
externalTracker : 1222114.66 ,
Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " vue-autonumeric" ,
3
- "version" : " 1.2.5 " ,
3
+ "version" : " 1.2.6 " ,
4
4
"description" : " An AutoNumeric wrapper for Vue.js" ,
5
5
"author" : " Alexandre Bonneau <alexandre.bonneau@linuxfr.eu>" ,
6
6
"license" : " MIT" ,
Original file line number Diff line number Diff line change 1
1
<!--
2
2
vue-autonumeric
3
3
4
- @version 1.2.5
5
- @date 2018-05-25 UTC 19:50
4
+ @version 1.2.6
5
+ @date 2018-09-14 UTC 19:06
6
6
7
7
@author Alexandre Bonneau
8
8
@copyright 2018 © Alexandre Bonneau <alexandre.bonneau@linuxfr.eu>
@@ -102,7 +102,7 @@ OTHER DEALINGS IN THE SOFTWARE.
102
102
value: {
103
103
required: false ,
104
104
validator (val ) {
105
- return typeof val === ' number' || val === ' ' || val === null ;
105
+ return typeof val === ' number' || typeof val === ' string ' || val === ' ' || val === null ;
106
106
},
107
107
},
108
108
You can’t perform that action at this time.
0 commit comments