diff --git a/packages/core/src/compiler/timingCompiler.test.ts b/packages/core/src/compiler/timingCompiler.test.ts index b7dcf044c..f32f0df17 100644 --- a/packages/core/src/compiler/timingCompiler.test.ts +++ b/packages/core/src/compiler/timingCompiler.test.ts @@ -16,6 +16,29 @@ describe("compileTimingAttrs", () => { expect(unresolved).toHaveLength(0); }); + it("injects a real id when the element has only data-hf-id (not a phantom match)", () => { + // Regression: getAttr(tag, "id") matched the trailing id="…" inside + // data-hf-id="…" and returned a phantom, so compileTag skipped its + // hf-video-N injection — leaving no real el.id and a blank-wash render. + const html = '