text: use "default" prop instead of "value" to define default value (#195)

This commit is contained in:
jean-emmanuel 2018-03-05 22:28:41 +01:00
parent ca60328c78
commit a1f2f6c6fa

View file

@ -56,7 +56,7 @@ module.exports = class Text extends Widget {
if (this.getProp('align') === 'right') this.widget.classList.add('right')
if (this.getProp('wrap')) this.widget.classList.add('wrap')
this.defaultValue = this.getProp('value') || ( this.getProp('label')===false ?
this.defaultValue = this.getProp('default') || ( this.getProp('label')===false ?
this.getProp('id'):
this.getProp('label')=='auto'?
this.getProp('id'):