(session: Composition, id: string)
| 91 | } |
| 92 | |
| 93 | function resolveSnapshot(session: Composition, id: string): FlatEl | null { |
| 94 | const els = session.getElements(); |
| 95 | const exact = els.find((el) => el.scopedId === id); |
| 96 | if (exact) return exact; |
| 97 | const matches = els.filter((el) => el.id === id); |
| 98 | return matches.find((el) => el.scopedId === el.id) ?? matches[0] ?? null; |
| 99 | } |
| 100 | |
| 101 | function checkStyleOp( |
| 102 | op: PatchOperation, |
no test coverage detected