( /**HTMLElement*/el, /**String*/selector, /**HTMLElement*/ctx, includeCTX)
| 156 | return el.host && el !== document && el.host.nodeType && el.host !== el ? el.host : el.parentNode; |
| 157 | } |
| 158 | function closest( /**HTMLElement*/el, /**String*/selector, /**HTMLElement*/ctx, includeCTX) { |
| 159 | if (el) { |
| 160 | ctx = ctx || document; |
| 161 | do { |
| 162 | if (selector != null && (selector[0] === '>' ? el.parentNode === ctx && matches(el, selector) : matches(el, selector)) || includeCTX && el === ctx) { |
| 163 | return el; |
| 164 | } |
| 165 | if (el === ctx) break; |
| 166 | /* jshint boss:true */ |
| 167 | } while (el = getParentOrHost(el)); |
| 168 | } |
| 169 | return null; |
| 170 | } |
| 171 | var R_SPACE = /\s+/g; |
| 172 | function toggleClass(el, name, state) { |
| 173 | if (el && name) { |
no test coverage detected
searching dependent graphs…