mirror of
https://github.com/heygen-com/hyperframes.git
synced 2026-11-17 15:24:19 +00:00
Compositions that style their own box via the bare `[data-composition-id="X"]` selector (e.g. `display: flex` to center their children) rely on that rule landing on whatever element actually parents their content. Once flattenInnerRoot preserves the authored root as a wrapper below the host (data-hf-inner-root), the bare root selector was only ever rewritten onto the host, one level too high, so the composition's own children lost their flex or grid layout context entirely. Rewrite a bare root composition-id selector to a compound-OR targeting both the host and its data-hf-inner-root descendant, so the box styling reaches whichever element actually holds the composition's content. Selectors with a descendant part (e.g. `[data-composition-id="X"] .title`) are unaffected, since a plain descendant combinator already matches at any depth.