()
| 55 | } |
| 56 | |
| 57 | export function refreshOverlay() { |
| 58 | const activeStagePosition = getState("__activeStagePosition"); |
| 59 | const overlaySvg = getState("__overlaySvg"); |
| 60 | |
| 61 | if (!activeStagePosition) { |
| 62 | return; |
| 63 | } |
| 64 | |
| 65 | if (!overlaySvg) { |
| 66 | console.warn("No stage svg found."); |
| 67 | return; |
| 68 | } |
| 69 | |
| 70 | const windowX = window.innerWidth; |
| 71 | const windowY = window.innerHeight; |
| 72 | |
| 73 | overlaySvg.setAttribute("viewBox", `0 0 ${windowX} ${windowY}`); |
| 74 | } |
| 75 | |
| 76 | function mountOverlay(stagePosition: StageDefinition) { |
| 77 | const overlaySvg = createOverlaySvg(stagePosition); |
no test coverage detected
searching dependent graphs…