diff --git a/.gitignore b/.gitignore
index ee7cd60..4bb5e54 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,2 +1,4 @@
-bower_components
-node_modules/
+bower_components
+bower_components-1.x
+bower-1.x.json
+node_modules/
diff --git a/bower.json b/bower.json
index 2da3a46..77edf55 100644
--- a/bower.json
+++ b/bower.json
@@ -10,10 +10,21 @@
"package.json"
],
"dependencies": {
- "polymer": "^1.5.0"
+ "polymer": "Polymer/polymer#1.9 - 2.0"
},
"devDependencies": {
- "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.1.5",
- "web-component-tester": "^4.2.2"
+ "iron-test-helpers": "PolymerElements/iron-test-helpers#1 - 2",
+ "web-component-tester": "^6.0.0"
+ },
+ "variants": {
+ "1.x": {
+ "dependencies": {
+ "polymer": "Polymer/polymer#^1.9.1"
+ },
+ "devDependencies": {
+ "iron-test-helpers": "PolymerElements/iron-test-helpers#^1.4.1",
+ "web-component-tester": "^5.0.0"
+ }
+ }
}
}
diff --git a/d2l-dom.html b/d2l-dom.html
index 21b9055..636e4de 100644
--- a/d2l-dom.html
+++ b/d2l-dom.html
@@ -27,6 +27,8 @@
if (node.tagName === 'CONTENT') {
nodes = node.getDistributedNodes();
+ } else if (node.tagName === 'SLOT') {
+ nodes = node.assignedNodes({flatten: true});
} else {
if (node.shadowRoot) {
node = node.shadowRoot;
@@ -53,6 +55,10 @@
}
}
+ if (node.assignedSlot) {
+ return node.assignedSlot;
+ }
+
if (node.parentNode) {
return node.parentNode;
} else if (node.host) {
diff --git a/demo/dom-focus-demo.html b/demo/dom-focus-demo.html
new file mode 100644
index 0000000..94e5e85
--- /dev/null
+++ b/demo/dom-focus-demo.html
@@ -0,0 +1,27 @@
+
+
+