(element)
| 2516 | |
| 2517 | ///////////////////////////////////////////// |
| 2518 | function JQLite(element) { |
| 2519 | if (element instanceof JQLite) { |
| 2520 | return element; |
| 2521 | } |
| 2522 | |
| 2523 | var argIsString; |
| 2524 | |
| 2525 | if (isString(element)) { |
| 2526 | element = trim(element); |
| 2527 | argIsString = true; |
| 2528 | } |
| 2529 | if (!(this instanceof JQLite)) { |
| 2530 | if (argIsString && element.charAt(0) != '<') { |
| 2531 | throw jqLiteMinErr('nosel', 'Looking up elements via selectors is not supported by jqLite! See: http://docs.angularjs.org/api/angular.element'); |
| 2532 | } |
| 2533 | return new JQLite(element); |
| 2534 | } |
| 2535 | |
| 2536 | if (argIsString) { |
| 2537 | jqLiteAddNodes(this, jqLiteParseHTML(element)); |
| 2538 | } else { |
| 2539 | jqLiteAddNodes(this, element); |
| 2540 | } |
| 2541 | } |
| 2542 | |
| 2543 | function jqLiteClone(element) { |
| 2544 | return element.cloneNode(true); |
no test coverage detected