Compare commits

..

1 Commits

Author SHA1 Message Date
Kevin Jahns
55f0abcdfc v13.0.0-54 -- distribution files 2018-03-01 16:45:38 +01:00
9 changed files with 19501 additions and 15 deletions

2
package-lock.json generated
View File

@@ -1,6 +1,6 @@
{
"name": "yjs",
"version": "13.0.0-55",
"version": "13.0.0-54",
"lockfileVersion": 1,
"requires": true,
"dependencies": {

View File

@@ -1,6 +1,6 @@
{
"name": "yjs",
"version": "13.0.0-55",
"version": "13.0.0-54",
"description": "A framework for real-time p2p shared editing on any data",
"main": "./y.node.js",
"browser": "./y.js",

View File

@@ -8,9 +8,6 @@ export default class YXmlElement extends YXmlFragment {
super()
this.nodeName = null
this._scrollElement = null
if (typeof arg2 === 'function') {
this._domFilter = arg2
}
if (typeof arg1 === 'string') {
this.nodeName = arg1.toUpperCase()
} else if (arg1 != null && arg1.nodeType != null && arg1.nodeType === arg1.ELEMENT_NODE) {
@@ -19,6 +16,9 @@ export default class YXmlElement extends YXmlFragment {
} else {
this.nodeName = 'UNDEFINED'
}
if (typeof arg2 === 'function') {
this._domFilter = arg2
}
}
_copy () {
let struct = super._copy()
@@ -39,7 +39,7 @@ export default class YXmlElement extends YXmlFragment {
// get attribute via getAttribute for custom element support (some write something different in attr.value)
attributes.set(attr.name, dom.getAttribute(attr.name))
}
attributes = this._domFilter(dom.nodeName, attributes)
attributes = this._domFilter(dom, attributes)
attributes.forEach((value, name) => {
this.setAttribute(name, value)
})

4
y.js

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -1,7 +1,7 @@
/**
* yjs - A framework for real-time p2p shared editing on any data
* @version v13.0.0-55
* @version v13.0.0-54
* @license MIT
*/
@@ -3126,9 +3126,6 @@ class YXmlElement extends YXmlFragment {
super();
this.nodeName = null;
this._scrollElement = null;
if (typeof arg2 === 'function') {
this._domFilter = arg2;
}
if (typeof arg1 === 'string') {
this.nodeName = arg1.toUpperCase();
} else if (arg1 != null && arg1.nodeType != null && arg1.nodeType === arg1.ELEMENT_NODE) {
@@ -3137,6 +3134,9 @@ class YXmlElement extends YXmlFragment {
} else {
this.nodeName = 'UNDEFINED';
}
if (typeof arg2 === 'function') {
this._domFilter = arg2;
}
}
_copy () {
let struct = super._copy();
@@ -3157,7 +3157,7 @@ class YXmlElement extends YXmlFragment {
// get attribute via getAttribute for custom element support (some write something different in attr.value)
attributes.set(attr.name, dom.getAttribute(attr.name));
}
attributes = this._domFilter(dom.nodeName, attributes);
attributes = this._domFilter(dom, attributes);
attributes.forEach((value, name) => {
this.setAttribute(name, value);
});

File diff suppressed because one or more lines are too long

19485
y.test.js Normal file

File diff suppressed because one or more lines are too long

1
y.test.js.map Normal file

File diff suppressed because one or more lines are too long