@textbus/adapter-viewfly 5.1.0 → 5.1.2
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/bundles/index.esm.js +9 -5
- package/bundles/index.js +9 -5
- package/package.json +6 -6
package/bundles/index.esm.js
CHANGED
|
@@ -74,12 +74,16 @@ class ViewflyAdapter extends DomAdapter {
|
|
|
74
74
|
throw adapterError(`cannot found view component \`${component.name}\`!`);
|
|
75
75
|
},
|
|
76
76
|
vElementToViewElement(vNode, children) {
|
|
77
|
-
|
|
78
|
-
vNode.attrs.
|
|
79
|
-
|
|
80
|
-
|
|
77
|
+
let key;
|
|
78
|
+
const props = Array.from(vNode.attrs).reduce((a, b) => {
|
|
79
|
+
const propName = b[0];
|
|
80
|
+
if (propName === 'key') {
|
|
81
|
+
key = b[1];
|
|
82
|
+
return a;
|
|
83
|
+
}
|
|
84
|
+
a[propName] = b[1];
|
|
81
85
|
return a;
|
|
82
|
-
}, {})
|
|
86
|
+
}, {});
|
|
83
87
|
if (vNode.classes.size) {
|
|
84
88
|
props.class = Array.from(vNode.classes).join(' ');
|
|
85
89
|
}
|
package/bundles/index.js
CHANGED
|
@@ -76,12 +76,16 @@ class ViewflyAdapter extends platformBrowser.DomAdapter {
|
|
|
76
76
|
throw adapterError(`cannot found view component \`${component.name}\`!`);
|
|
77
77
|
},
|
|
78
78
|
vElementToViewElement(vNode, children) {
|
|
79
|
-
|
|
80
|
-
vNode.attrs.
|
|
81
|
-
|
|
82
|
-
|
|
79
|
+
let key;
|
|
80
|
+
const props = Array.from(vNode.attrs).reduce((a, b) => {
|
|
81
|
+
const propName = b[0];
|
|
82
|
+
if (propName === 'key') {
|
|
83
|
+
key = b[1];
|
|
84
|
+
return a;
|
|
85
|
+
}
|
|
86
|
+
a[propName] = b[1];
|
|
83
87
|
return a;
|
|
84
|
-
}, {})
|
|
88
|
+
}, {});
|
|
85
89
|
if (vNode.classes.size) {
|
|
86
90
|
props.class = Array.from(vNode.classes).join(' ');
|
|
87
91
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@textbus/adapter-viewfly",
|
|
3
|
-
"version": "5.1.
|
|
3
|
+
"version": "5.1.2",
|
|
4
4
|
"description": "Textbus is a rich text editor and framework that is highly customizable and extensible to achieve rich wysiwyg effects.",
|
|
5
5
|
"main": "./bundles/index.js",
|
|
6
6
|
"module": "./bundles/index.esm.js",
|
|
@@ -26,11 +26,11 @@
|
|
|
26
26
|
],
|
|
27
27
|
"dependencies": {
|
|
28
28
|
"@tanbo/stream": "^1.2.7",
|
|
29
|
-
"@textbus/core": "^5.1.
|
|
30
|
-
"@textbus/platform-browser": "^5.1.
|
|
31
|
-
"@textbus/platform-node": "^5.1.
|
|
32
|
-
"@viewfly/core": "^2.0.0
|
|
33
|
-
"@viewfly/platform-browser": "^2.0.0
|
|
29
|
+
"@textbus/core": "^5.1.2",
|
|
30
|
+
"@textbus/platform-browser": "^5.1.2",
|
|
31
|
+
"@textbus/platform-node": "^5.1.2",
|
|
32
|
+
"@viewfly/core": "^2.0.0",
|
|
33
|
+
"@viewfly/platform-browser": "^2.0.0"
|
|
34
34
|
},
|
|
35
35
|
"devDependencies": {
|
|
36
36
|
"@rollup/plugin-commonjs": "^28.0.2",
|