mirror of
https://github.com/heygen-com/hyperframes.git
synced 2026-09-10 22:20:14 +00:00
refactor: address review nits
- merge gsapResizeIntercept's duplicate module imports - move the core-constant imports to the file headers (picker, domEditingDom) - justify the cross-realm HTMLElement casts (iframe-realm nodes fail instanceof; access is duck-typed)
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
* selector utilities, and composition source resolution.
|
||||
* No imports from other domEditing* modules — safe to import from anywhere.
|
||||
*/
|
||||
import { COLOR_GRADING_SOURCE_HIDDEN_ATTR } from "@hyperframes/core/color-grading";
|
||||
import { CURATED_STYLE_PROPERTIES } from "./domEditingTypes";
|
||||
|
||||
// ─── Type guard ───────────────────────────────────────────────────────────────
|
||||
@@ -28,8 +29,6 @@ export function isTextBearingTag(tagName: string): boolean {
|
||||
return ["div", "span", "p", "strong", "h1", "h2", "h3", "h4", "h5", "h6"].includes(tagName);
|
||||
}
|
||||
|
||||
import { COLOR_GRADING_SOURCE_HIDDEN_ATTR } from "@hyperframes/core/color-grading";
|
||||
|
||||
export function isElementVisibleThroughAncestors(el: HTMLElement): boolean {
|
||||
const win = el.ownerDocument.defaultView;
|
||||
if (!win) return true;
|
||||
|
||||
Reference in New Issue
Block a user