@dolphinweex/weex-vue-render 0.2.80 → 0.2.82
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.common.js +17 -4
- package/package.json +1 -1
package/dist/index.common.js
CHANGED
|
@@ -8,6 +8,9 @@ console.log('START WEEX VUE RENDER: 1.0.36, Build 2018-12-29 17:52.');
|
|
|
8
8
|
(global.WeexVueRender = factory());
|
|
9
9
|
}(this, (function () { 'use strict';
|
|
10
10
|
|
|
11
|
+
// 记录当前已经添加过的字体
|
|
12
|
+
const AddedRules = {}
|
|
13
|
+
|
|
11
14
|
function __$styleInject(css, returnValue) {
|
|
12
15
|
if (typeof document === 'undefined') {
|
|
13
16
|
return returnValue;
|
|
@@ -4844,7 +4847,7 @@ var appearWatched = false;
|
|
|
4844
4847
|
*/
|
|
4845
4848
|
var debouncedWatchAppear = debounce(function () {
|
|
4846
4849
|
watchAppear(appearWatched, true);
|
|
4847
|
-
},
|
|
4850
|
+
}, 100);
|
|
4848
4851
|
|
|
4849
4852
|
/**
|
|
4850
4853
|
* if it's a scrollable tag, then watch appear events for it.
|
|
@@ -5864,7 +5867,8 @@ function getImage(weex) {
|
|
|
5864
5867
|
},
|
|
5865
5868
|
|
|
5866
5869
|
render: function render(createElement) {
|
|
5867
|
-
|
|
5870
|
+
const isFlvFile = this.src && this.src.toLowerCase().endsWith('.flv');
|
|
5871
|
+
return createElement(isFlvFile ? "video" : "figure", {
|
|
5868
5872
|
attrs: {
|
|
5869
5873
|
"weex-type": "img",
|
|
5870
5874
|
src: this.checkTrim(this.src),
|
|
@@ -8225,11 +8229,11 @@ var slideMixin = {
|
|
|
8225
8229
|
this._emitScrollEvent('scrollstart');
|
|
8226
8230
|
}
|
|
8227
8231
|
|
|
8228
|
-
setTimeout(() => {
|
|
8232
|
+
// setTimeout(() => {
|
|
8229
8233
|
this$1._throttleEmitScroll(dist, () => {
|
|
8230
8234
|
this$1._emitScrollEvent('scrollend');
|
|
8231
8235
|
});
|
|
8232
|
-
}, THROTTLE_SCROLL_TIME);
|
|
8236
|
+
// }, THROTTLE_SCROLL_TIME);
|
|
8233
8237
|
|
|
8234
8238
|
this._loopShowNodes(step);
|
|
8235
8239
|
|
|
@@ -11323,6 +11327,12 @@ var dom = {
|
|
|
11323
11327
|
* @param {object} styles rules
|
|
11324
11328
|
*/
|
|
11325
11329
|
addRule: function (key, styles) {
|
|
11330
|
+
const rule_key = styles["fontFamily"] + styles["src"]
|
|
11331
|
+
if (AddedRules[rule_key]) {
|
|
11332
|
+
console.log("已经添加过字体了,无需再添加", styles.src)
|
|
11333
|
+
return
|
|
11334
|
+
}
|
|
11335
|
+
|
|
11326
11336
|
var camelToKebab = utils$3.camelToKebab;
|
|
11327
11337
|
var appendCss = utils$3.appendCss;
|
|
11328
11338
|
key = camelToKebab(key);
|
|
@@ -11343,6 +11353,9 @@ var dom = {
|
|
|
11343
11353
|
key,
|
|
11344
11354
|
styles,
|
|
11345
11355
|
}, undefined, undefined, undefined);
|
|
11356
|
+
|
|
11357
|
+
|
|
11358
|
+
AddedRules[rule_key] = styles
|
|
11346
11359
|
}
|
|
11347
11360
|
};
|
|
11348
11361
|
var dom$1 = {
|
package/package.json
CHANGED