(element)
| 2739 | |
| 2740 | ///////////////////////////////////////////// |
| 2741 | function JQLite(element) { |
| 2742 | if (element instanceof JQLite) { |
| 2743 | return element; |
| 2744 | } |
| 2745 | |
| 2746 | var argIsString; |
| 2747 | |
| 2748 | if (isString(element)) { |
| 2749 | element = trim(element); |
| 2750 | argIsString = true; |
| 2751 | } |
| 2752 | if (!(this instanceof JQLite)) { |
| 2753 | if (argIsString && element.charAt(0) != '<') { |
| 2754 | throw jqLiteMinErr('nosel', 'Looking up elements via selectors is not supported by jqLite! See: http://docs.angularjs.org/api/angular.element'); |
| 2755 | } |
| 2756 | return new JQLite(element); |
| 2757 | } |
| 2758 | |
| 2759 | if (argIsString) { |
| 2760 | jqLiteAddNodes(this, jqLiteParseHTML(element)); |
| 2761 | } else { |
| 2762 | jqLiteAddNodes(this, element); |
| 2763 | } |
| 2764 | } |
| 2765 | |
| 2766 | function jqLiteClone(element) { |
| 2767 | return element.cloneNode(true); |
no test coverage detected