( node: Element, condition: (n: Element) => boolean )
| 28 | } |
| 29 | |
| 30 | export function findParent( |
| 31 | node: Element, |
| 32 | condition: (n: Element) => boolean |
| 33 | ): Element | undefined { |
| 34 | if (condition(node)) return node; |
| 35 | else if (node.parentNode) |
| 36 | return findParent(node.parentNode as Element, condition); |
| 37 | |
| 38 | return undefined; // nothing found |
| 39 | } |
| 40 | |
| 41 | export function createNumberInput( |
| 42 | inputClassName: string, |
no outgoing calls
no test coverage detected
searching dependent graphs…