diff --git a/source/Ox/js/DOM.js b/source/Ox/js/DOM.js index b022b515..42cadfe2 100644 --- a/source/Ox/js/DOM.js +++ b/source/Ox/js/DOM.js @@ -236,6 +236,12 @@ Ox.$ = Ox.element = function(value) { return this; }, /*@ + is Returns true if the element matches the query + @*/ + is: function(query) { + return Ox.contains(this.parent().querySelectorAll(query), this[0]); + }, + /*@ next Returns the sibling after this element () -> Next element @*/