( propName: string, node: HTMLElement, options: Options, )
| 5 | import { getMimeType } from './mimes' |
| 6 | |
| 7 | async function embedProp( |
| 8 | propName: string, |
| 9 | node: HTMLElement, |
| 10 | options: Options, |
| 11 | ) { |
| 12 | const propValue = node.style?.getPropertyValue(propName) |
| 13 | if (propValue) { |
| 14 | const cssString = await embedResources(propValue, null, options) |
| 15 | node.style.setProperty( |
| 16 | propName, |
| 17 | cssString, |
| 18 | node.style.getPropertyPriority(propName), |
| 19 | ) |
| 20 | return true |
| 21 | } |
| 22 | return false |
| 23 | } |
| 24 | |
| 25 | async function embedBackground<T extends HTMLElement>( |
| 26 | clonedNode: T, |
no test coverage detected
searching dependent graphs…