bigfoot-dom
Advanced tools
Comparing version 0.0.1 to 0.0.2
{ | ||
"name": "dom", | ||
"main": "dist/dom.js", | ||
"version": "0.0.1", | ||
"version": "0.0.2", | ||
"authors": [ | ||
@@ -6,0 +6,0 @@ "Chris Sauve <chrismsauve@gmail.com>" |
110
dist/dom.js
@@ -1,61 +0,59 @@ | ||
(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){ | ||
var dom; | ||
(function() { | ||
var dom; | ||
dom = { | ||
matches: function(node, selector) { | ||
return node.webkitMatchesSelector(selector); | ||
}, | ||
all: function(selector, scope) { | ||
if (scope == null) { | ||
scope = document; | ||
} | ||
return Array.prototype.slice.apply(scope.querySelectorAll(selector)); | ||
}, | ||
one: function(selector, scope) { | ||
if (scope == null) { | ||
scope = document; | ||
} | ||
return scope.querySelector(selector); | ||
}, | ||
closest: function(node, selector) { | ||
while (node !== document) { | ||
if (node.webkitMatchesSelector(selector)) { | ||
return node; | ||
dom = { | ||
matches: function(node, selector) { | ||
return node.webkitMatchesSelector(selector); | ||
}, | ||
all: function(selector, scope) { | ||
if (scope == null) { | ||
scope = document; | ||
} | ||
node = node.parentNode; | ||
return Array.prototype.slice.apply(scope.querySelectorAll(selector)); | ||
}, | ||
one: function(selector, scope) { | ||
if (scope == null) { | ||
scope = document; | ||
} | ||
return scope.querySelector(selector); | ||
}, | ||
closest: function(node, selector) { | ||
while (node !== document) { | ||
if (node.webkitMatchesSelector(selector)) { | ||
return node; | ||
} | ||
node = node.parentNode; | ||
} | ||
}, | ||
children: function(node, selector) { | ||
if (selector == null) { | ||
selector = '*'; | ||
} | ||
return Array.prototype.slice.apply(node.children).filter(function(child) { | ||
return child.webkitMatchesSelector(selector); | ||
}); | ||
}, | ||
find: function(node, selector) { | ||
return this.one(selector, node); | ||
}, | ||
docDefer: function(selector, eventName, handler) { | ||
return document.addEventListener(eventName, function(event) { | ||
if (event.target.webkitMatchesSelector(selector)) { | ||
return handler(event); | ||
} | ||
}); | ||
}, | ||
trigger: function(eventName, node) { | ||
var event; | ||
event = new Event(eventName); | ||
return node.dispatchEvent(event); | ||
} | ||
}, | ||
children: function(node, selector) { | ||
if (selector == null) { | ||
selector = '*'; | ||
} | ||
return Array.prototype.slice.apply(node.children).filter(function(child) { | ||
return child.webkitMatchesSelector(selector); | ||
}); | ||
}, | ||
find: function(node, selector) { | ||
return this.one(selector, node); | ||
}, | ||
docDefer: function(selector, eventName, handler) { | ||
return document.addEventListener(eventName, function(event) { | ||
if (event.target.webkitMatchesSelector(selector)) { | ||
return handler(event); | ||
} | ||
}); | ||
}, | ||
trigger: function(eventName, node) { | ||
var event; | ||
event = new Event(eventName); | ||
return node.dispatchEvent(event); | ||
}; | ||
if (typeof module !== "undefined" && module !== null) { | ||
module.exports = dom; | ||
} else { | ||
window.dom = dom; | ||
} | ||
}; | ||
if (typeof module !== "undefined" && module !== null) { | ||
module.exports = dom; | ||
} else { | ||
window.dom = dom; | ||
} | ||
},{}]},{},[1]); | ||
}).call(this); |
@@ -1,1 +0,1 @@ | ||
!function a(b,c,d){function e(g,h){if(!c[g]){if(!b[g]){var i="function"==typeof require&&require;if(!h&&i)return i(g,!0);if(f)return f(g,!0);var j=new Error("Cannot find module '"+g+"'");throw j.code="MODULE_NOT_FOUND",j}var k=c[g]={exports:{}};b[g][0].call(k.exports,function(a){var c=b[g][1][a];return e(c?c:a)},k,k.exports,a,b,c,d)}return c[g].exports}for(var f="function"==typeof require&&require,g=0;g<d.length;g++)e(d[g]);return e}({1:[function(a,b){var c;c={matches:function(a,b){return a.webkitMatchesSelector(b)},all:function(a,b){return null==b&&(b=document),Array.prototype.slice.apply(b.querySelectorAll(a))},one:function(a,b){return null==b&&(b=document),b.querySelector(a)},closest:function(a,b){for(;a!==document;){if(a.webkitMatchesSelector(b))return a;a=a.parentNode}},children:function(a,b){return null==b&&(b="*"),Array.prototype.slice.apply(a.children).filter(function(a){return a.webkitMatchesSelector(b)})},find:function(a,b){return this.one(b,a)},docDefer:function(a,b,c){return document.addEventListener(b,function(b){return b.target.webkitMatchesSelector(a)?c(b):void 0})},trigger:function(a,b){var c;return c=new Event(a),b.dispatchEvent(c)}},"undefined"!=typeof b&&null!==b?b.exports=c:window.dom=c},{}]},{},[1]); | ||
(function(){var a;a={matches:function(a,b){return a.webkitMatchesSelector(b)},all:function(a,b){return null==b&&(b=document),Array.prototype.slice.apply(b.querySelectorAll(a))},one:function(a,b){return null==b&&(b=document),b.querySelector(a)},closest:function(a,b){for(;a!==document;){if(a.webkitMatchesSelector(b))return a;a=a.parentNode}},children:function(a,b){return null==b&&(b="*"),Array.prototype.slice.apply(a.children).filter(function(a){return a.webkitMatchesSelector(b)})},find:function(a,b){return this.one(b,a)},docDefer:function(a,b,c){return document.addEventListener(b,function(b){return b.target.webkitMatchesSelector(a)?c(b):void 0})},trigger:function(a,b){var c;return c=new Event(a),b.dispatchEvent(c)}},"undefined"!=typeof module&&null!==module?module.exports=a:window.dom=a}).call(this); |
{ | ||
"name": "bigfoot-dom", | ||
"version": "0.0.1", | ||
"version": "0.0.2", | ||
"main": "dist/dom.js", | ||
@@ -12,3 +12,2 @@ "scripts": { | ||
"grunt": ">= 0.4.5", | ||
"grunt-browserify": ">= 3.2.1", | ||
"grunt-compare-size": ">= 0.4.0", | ||
@@ -15,0 +14,0 @@ "grunt-contrib-coffee": ">= 0.12.0", |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
Found 1 instance in 1 package
10
2
0
7362
10
84