(element, name, value)
| 2669 | } |
| 2670 | |
| 2671 | function jqLiteInheritedData(element, name, value) { |
| 2672 | // if element is the document object work with the html element instead |
| 2673 | // this makes $(document).scope() possible |
| 2674 | if (element.nodeType == NODE_TYPE_DOCUMENT) { |
| 2675 | element = element.documentElement; |
| 2676 | } |
| 2677 | var names = isArray(name) ? name : [name]; |
| 2678 | |
| 2679 | while (element) { |
| 2680 | for (var i = 0, ii = names.length; i < ii; i++) { |
| 2681 | if ((value = jqLite.data(element, names[i])) !== undefined) return value; |
| 2682 | } |
| 2683 | |
| 2684 | // If dealing with a document fragment node with a host element, and no parent, use the host |
| 2685 | // element as the parent. This enables directives within a Shadow DOM or polyfilled Shadow DOM |
| 2686 | // to lookup parent controllers. |
| 2687 | element = element.parentNode || (element.nodeType === NODE_TYPE_DOCUMENT_FRAGMENT && element.host); |
| 2688 | } |
| 2689 | } |
| 2690 | |
| 2691 | function jqLiteEmpty(element) { |
| 2692 | jqLiteDealoc(element, true); |
no outgoing calls
no test coverage detected