Browse Source

Merge pull request #911 in VISUAL/fineui from ~WINDY/fineui:master to master

* commit '174b9bdf82f96f2674103e399ef67b99fb3a1f1b':
  BI-44302 feat: label支持text属性传function
es6
windy 6 years ago
parent
commit
723c2001d5
  1. 19
      dist/2.0/fineui.ie.js
  2. 19
      dist/2.0/fineui.js
  3. 19
      dist/base.js
  4. 19
      dist/bundle.ie.js
  5. 19
      dist/bundle.js
  6. 19
      dist/fineui.ie.js
  7. 19
      dist/fineui.js
  8. 19
      dist/fineui_without_jquery_polyfill.js
  9. 19
      src/base/single/text.js

19
dist/2.0/fineui.ie.js vendored

@ -36069,16 +36069,21 @@ BI.Text = BI.inherit(BI.Single, {
}
},
mounted: function () {
_getShowText: function () {
var o = this.options;
return BI.isFunction(o.text) ? o.text() : o.text;
},
if (BI.isKey(o.text)) {
this.setText(o.text);
mounted: function () {
var o = this.options;
var text = this._getShowText();
if (BI.isKey(text)) {
this.setText(text);
} else if (BI.isKey(o.value)) {
this.setText(o.value);
}
if (BI.isKey(o.keyword)) {
this.text.element.__textKeywordMarked__(o.text, o.keyword, o.py);
this.text.element.__textKeywordMarked__(text, o.keyword, o.py);
}
if (o.highLight) {
this.doHighLight();
@ -36089,13 +36094,13 @@ BI.Text = BI.inherit(BI.Single, {
var o = this.options;
// render之后做的doredmark,这个时候虽然标红了,但是之后text mounted执行的时候并没有keyword
o.keyword = keyword;
this.text.element.__textKeywordMarked__(o.text || o.value, keyword, o.py);
this.text.element.__textKeywordMarked__(this._getShowText() || o.value, keyword, o.py);
},
unRedMark: function () {
var o = this.options;
o.keyword = "";
this.text.element.__textKeywordMarked__(o.text || o.value, "", o.py);
this.text.element.__textKeywordMarked__(this._getShowText() || o.value, "", o.py);
},
doHighLight: function () {
@ -36120,7 +36125,7 @@ BI.Text = BI.inherit(BI.Single, {
setText: function (text) {
BI.Text.superclass.setText.apply(this, arguments);
this.options.text = text;
this.text.element.html(BI.htmlEncode(text));
this.text.element.html(BI.htmlEncode(this._getShowText()));
}
});

19
dist/2.0/fineui.js vendored

@ -36473,16 +36473,21 @@ BI.Text = BI.inherit(BI.Single, {
}
},
mounted: function () {
_getShowText: function () {
var o = this.options;
return BI.isFunction(o.text) ? o.text() : o.text;
},
if (BI.isKey(o.text)) {
this.setText(o.text);
mounted: function () {
var o = this.options;
var text = this._getShowText();
if (BI.isKey(text)) {
this.setText(text);
} else if (BI.isKey(o.value)) {
this.setText(o.value);
}
if (BI.isKey(o.keyword)) {
this.text.element.__textKeywordMarked__(o.text, o.keyword, o.py);
this.text.element.__textKeywordMarked__(text, o.keyword, o.py);
}
if (o.highLight) {
this.doHighLight();
@ -36493,13 +36498,13 @@ BI.Text = BI.inherit(BI.Single, {
var o = this.options;
// render之后做的doredmark,这个时候虽然标红了,但是之后text mounted执行的时候并没有keyword
o.keyword = keyword;
this.text.element.__textKeywordMarked__(o.text || o.value, keyword, o.py);
this.text.element.__textKeywordMarked__(this._getShowText() || o.value, keyword, o.py);
},
unRedMark: function () {
var o = this.options;
o.keyword = "";
this.text.element.__textKeywordMarked__(o.text || o.value, "", o.py);
this.text.element.__textKeywordMarked__(this._getShowText() || o.value, "", o.py);
},
doHighLight: function () {
@ -36524,7 +36529,7 @@ BI.Text = BI.inherit(BI.Single, {
setText: function (text) {
BI.Text.superclass.setText.apply(this, arguments);
this.options.text = text;
this.text.element.html(BI.htmlEncode(text));
this.text.element.html(BI.htmlEncode(this._getShowText()));
}
});

19
dist/base.js vendored

@ -602,16 +602,21 @@ BI.Text = BI.inherit(BI.Single, {
}
},
mounted: function () {
_getShowText: function () {
var o = this.options;
return BI.isFunction(o.text) ? o.text() : o.text;
},
if (BI.isKey(o.text)) {
this.setText(o.text);
mounted: function () {
var o = this.options;
var text = this._getShowText();
if (BI.isKey(text)) {
this.setText(text);
} else if (BI.isKey(o.value)) {
this.setText(o.value);
}
if (BI.isKey(o.keyword)) {
this.text.element.__textKeywordMarked__(o.text, o.keyword, o.py);
this.text.element.__textKeywordMarked__(text, o.keyword, o.py);
}
if (o.highLight) {
this.doHighLight();
@ -622,13 +627,13 @@ BI.Text = BI.inherit(BI.Single, {
var o = this.options;
// render之后做的doredmark,这个时候虽然标红了,但是之后text mounted执行的时候并没有keyword
o.keyword = keyword;
this.text.element.__textKeywordMarked__(o.text || o.value, keyword, o.py);
this.text.element.__textKeywordMarked__(this._getShowText() || o.value, keyword, o.py);
},
unRedMark: function () {
var o = this.options;
o.keyword = "";
this.text.element.__textKeywordMarked__(o.text || o.value, "", o.py);
this.text.element.__textKeywordMarked__(this._getShowText() || o.value, "", o.py);
},
doHighLight: function () {
@ -653,7 +658,7 @@ BI.Text = BI.inherit(BI.Single, {
setText: function (text) {
BI.Text.superclass.setText.apply(this, arguments);
this.options.text = text;
this.text.element.html(BI.htmlEncode(text));
this.text.element.html(BI.htmlEncode(this._getShowText()));
}
});

19
dist/bundle.ie.js vendored

@ -36069,16 +36069,21 @@ BI.Text = BI.inherit(BI.Single, {
}
},
mounted: function () {
_getShowText: function () {
var o = this.options;
return BI.isFunction(o.text) ? o.text() : o.text;
},
if (BI.isKey(o.text)) {
this.setText(o.text);
mounted: function () {
var o = this.options;
var text = this._getShowText();
if (BI.isKey(text)) {
this.setText(text);
} else if (BI.isKey(o.value)) {
this.setText(o.value);
}
if (BI.isKey(o.keyword)) {
this.text.element.__textKeywordMarked__(o.text, o.keyword, o.py);
this.text.element.__textKeywordMarked__(text, o.keyword, o.py);
}
if (o.highLight) {
this.doHighLight();
@ -36089,13 +36094,13 @@ BI.Text = BI.inherit(BI.Single, {
var o = this.options;
// render之后做的doredmark,这个时候虽然标红了,但是之后text mounted执行的时候并没有keyword
o.keyword = keyword;
this.text.element.__textKeywordMarked__(o.text || o.value, keyword, o.py);
this.text.element.__textKeywordMarked__(this._getShowText() || o.value, keyword, o.py);
},
unRedMark: function () {
var o = this.options;
o.keyword = "";
this.text.element.__textKeywordMarked__(o.text || o.value, "", o.py);
this.text.element.__textKeywordMarked__(this._getShowText() || o.value, "", o.py);
},
doHighLight: function () {
@ -36120,7 +36125,7 @@ BI.Text = BI.inherit(BI.Single, {
setText: function (text) {
BI.Text.superclass.setText.apply(this, arguments);
this.options.text = text;
this.text.element.html(BI.htmlEncode(text));
this.text.element.html(BI.htmlEncode(this._getShowText()));
}
});

19
dist/bundle.js vendored

@ -36473,16 +36473,21 @@ BI.Text = BI.inherit(BI.Single, {
}
},
mounted: function () {
_getShowText: function () {
var o = this.options;
return BI.isFunction(o.text) ? o.text() : o.text;
},
if (BI.isKey(o.text)) {
this.setText(o.text);
mounted: function () {
var o = this.options;
var text = this._getShowText();
if (BI.isKey(text)) {
this.setText(text);
} else if (BI.isKey(o.value)) {
this.setText(o.value);
}
if (BI.isKey(o.keyword)) {
this.text.element.__textKeywordMarked__(o.text, o.keyword, o.py);
this.text.element.__textKeywordMarked__(text, o.keyword, o.py);
}
if (o.highLight) {
this.doHighLight();
@ -36493,13 +36498,13 @@ BI.Text = BI.inherit(BI.Single, {
var o = this.options;
// render之后做的doredmark,这个时候虽然标红了,但是之后text mounted执行的时候并没有keyword
o.keyword = keyword;
this.text.element.__textKeywordMarked__(o.text || o.value, keyword, o.py);
this.text.element.__textKeywordMarked__(this._getShowText() || o.value, keyword, o.py);
},
unRedMark: function () {
var o = this.options;
o.keyword = "";
this.text.element.__textKeywordMarked__(o.text || o.value, "", o.py);
this.text.element.__textKeywordMarked__(this._getShowText() || o.value, "", o.py);
},
doHighLight: function () {
@ -36524,7 +36529,7 @@ BI.Text = BI.inherit(BI.Single, {
setText: function (text) {
BI.Text.superclass.setText.apply(this, arguments);
this.options.text = text;
this.text.element.html(BI.htmlEncode(text));
this.text.element.html(BI.htmlEncode(this._getShowText()));
}
});

19
dist/fineui.ie.js vendored

@ -36314,16 +36314,21 @@ BI.Text = BI.inherit(BI.Single, {
}
},
mounted: function () {
_getShowText: function () {
var o = this.options;
return BI.isFunction(o.text) ? o.text() : o.text;
},
if (BI.isKey(o.text)) {
this.setText(o.text);
mounted: function () {
var o = this.options;
var text = this._getShowText();
if (BI.isKey(text)) {
this.setText(text);
} else if (BI.isKey(o.value)) {
this.setText(o.value);
}
if (BI.isKey(o.keyword)) {
this.text.element.__textKeywordMarked__(o.text, o.keyword, o.py);
this.text.element.__textKeywordMarked__(text, o.keyword, o.py);
}
if (o.highLight) {
this.doHighLight();
@ -36334,13 +36339,13 @@ BI.Text = BI.inherit(BI.Single, {
var o = this.options;
// render之后做的doredmark,这个时候虽然标红了,但是之后text mounted执行的时候并没有keyword
o.keyword = keyword;
this.text.element.__textKeywordMarked__(o.text || o.value, keyword, o.py);
this.text.element.__textKeywordMarked__(this._getShowText() || o.value, keyword, o.py);
},
unRedMark: function () {
var o = this.options;
o.keyword = "";
this.text.element.__textKeywordMarked__(o.text || o.value, "", o.py);
this.text.element.__textKeywordMarked__(this._getShowText() || o.value, "", o.py);
},
doHighLight: function () {
@ -36365,7 +36370,7 @@ BI.Text = BI.inherit(BI.Single, {
setText: function (text) {
BI.Text.superclass.setText.apply(this, arguments);
this.options.text = text;
this.text.element.html(BI.htmlEncode(text));
this.text.element.html(BI.htmlEncode(this._getShowText()));
}
});

19
dist/fineui.js vendored

@ -36718,16 +36718,21 @@ BI.Text = BI.inherit(BI.Single, {
}
},
mounted: function () {
_getShowText: function () {
var o = this.options;
return BI.isFunction(o.text) ? o.text() : o.text;
},
if (BI.isKey(o.text)) {
this.setText(o.text);
mounted: function () {
var o = this.options;
var text = this._getShowText();
if (BI.isKey(text)) {
this.setText(text);
} else if (BI.isKey(o.value)) {
this.setText(o.value);
}
if (BI.isKey(o.keyword)) {
this.text.element.__textKeywordMarked__(o.text, o.keyword, o.py);
this.text.element.__textKeywordMarked__(text, o.keyword, o.py);
}
if (o.highLight) {
this.doHighLight();
@ -36738,13 +36743,13 @@ BI.Text = BI.inherit(BI.Single, {
var o = this.options;
// render之后做的doredmark,这个时候虽然标红了,但是之后text mounted执行的时候并没有keyword
o.keyword = keyword;
this.text.element.__textKeywordMarked__(o.text || o.value, keyword, o.py);
this.text.element.__textKeywordMarked__(this._getShowText() || o.value, keyword, o.py);
},
unRedMark: function () {
var o = this.options;
o.keyword = "";
this.text.element.__textKeywordMarked__(o.text || o.value, "", o.py);
this.text.element.__textKeywordMarked__(this._getShowText() || o.value, "", o.py);
},
doHighLight: function () {
@ -36769,7 +36774,7 @@ BI.Text = BI.inherit(BI.Single, {
setText: function (text) {
BI.Text.superclass.setText.apply(this, arguments);
this.options.text = text;
this.text.element.html(BI.htmlEncode(text));
this.text.element.html(BI.htmlEncode(this._getShowText()));
}
});

19
dist/fineui_without_jquery_polyfill.js vendored

@ -25149,16 +25149,21 @@ BI.Text = BI.inherit(BI.Single, {
}
},
mounted: function () {
_getShowText: function () {
var o = this.options;
return BI.isFunction(o.text) ? o.text() : o.text;
},
if (BI.isKey(o.text)) {
this.setText(o.text);
mounted: function () {
var o = this.options;
var text = this._getShowText();
if (BI.isKey(text)) {
this.setText(text);
} else if (BI.isKey(o.value)) {
this.setText(o.value);
}
if (BI.isKey(o.keyword)) {
this.text.element.__textKeywordMarked__(o.text, o.keyword, o.py);
this.text.element.__textKeywordMarked__(text, o.keyword, o.py);
}
if (o.highLight) {
this.doHighLight();
@ -25169,13 +25174,13 @@ BI.Text = BI.inherit(BI.Single, {
var o = this.options;
// render之后做的doredmark,这个时候虽然标红了,但是之后text mounted执行的时候并没有keyword
o.keyword = keyword;
this.text.element.__textKeywordMarked__(o.text || o.value, keyword, o.py);
this.text.element.__textKeywordMarked__(this._getShowText() || o.value, keyword, o.py);
},
unRedMark: function () {
var o = this.options;
o.keyword = "";
this.text.element.__textKeywordMarked__(o.text || o.value, "", o.py);
this.text.element.__textKeywordMarked__(this._getShowText() || o.value, "", o.py);
},
doHighLight: function () {
@ -25200,7 +25205,7 @@ BI.Text = BI.inherit(BI.Single, {
setText: function (text) {
BI.Text.superclass.setText.apply(this, arguments);
this.options.text = text;
this.text.element.html(BI.htmlEncode(text));
this.text.element.html(BI.htmlEncode(this._getShowText()));
}
});

19
src/base/single/text.js

@ -75,16 +75,21 @@ BI.Text = BI.inherit(BI.Single, {
}
},
mounted: function () {
_getShowText: function () {
var o = this.options;
return BI.isFunction(o.text) ? o.text() : o.text;
},
if (BI.isKey(o.text)) {
this.setText(o.text);
mounted: function () {
var o = this.options;
var text = this._getShowText();
if (BI.isKey(text)) {
this.setText(text);
} else if (BI.isKey(o.value)) {
this.setText(o.value);
}
if (BI.isKey(o.keyword)) {
this.text.element.__textKeywordMarked__(o.text, o.keyword, o.py);
this.text.element.__textKeywordMarked__(text, o.keyword, o.py);
}
if (o.highLight) {
this.doHighLight();
@ -95,13 +100,13 @@ BI.Text = BI.inherit(BI.Single, {
var o = this.options;
// render之后做的doredmark,这个时候虽然标红了,但是之后text mounted执行的时候并没有keyword
o.keyword = keyword;
this.text.element.__textKeywordMarked__(o.text || o.value, keyword, o.py);
this.text.element.__textKeywordMarked__(this._getShowText() || o.value, keyword, o.py);
},
unRedMark: function () {
var o = this.options;
o.keyword = "";
this.text.element.__textKeywordMarked__(o.text || o.value, "", o.py);
this.text.element.__textKeywordMarked__(this._getShowText() || o.value, "", o.py);
},
doHighLight: function () {
@ -126,7 +131,7 @@ BI.Text = BI.inherit(BI.Single, {
setText: function (text) {
BI.Text.superclass.setText.apply(this, arguments);
this.options.text = text;
this.text.element.html(BI.htmlEncode(text));
this.text.element.html(BI.htmlEncode(this._getShowText()));
}
});

Loading…
Cancel
Save