MCPcopy Create free account
hub / github.com/heygen-com/hyperframes / buildPreviewSelectSection

Function buildPreviewSelectSection

packages/sdk-playground/src/main.ts:733–750  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

731}
732
733function buildPreviewSelectSection(): HTMLDivElement {
734 const preview = playgroundPreview!;
735 const ids = comp!
736 .getElements()
737 .filter((e) => !e.attributes["data-hf-root"])
738 .map((e) => e.id);
739 const buttons = ids.map((id) =>
740 mkBtn(id, "", () => {
741 preview.select([id]);
742 logEntry("op", { "preview.select": [id] });
743 }),
744 );
745 const clear = mkBtn("clear", "danger", () => {
746 preview.select([]);
747 logEntry("op", { "preview.select": [] });
748 });
749 return opSection("PreviewAdapter.select()", opRow(...buttons, clear));
750}
751
752function buildSetStyleSection(): HTMLDivElement {
753 const colorInput = mkInput("#f43f5e", "#f43f5e");

Callers

nothing calls this directly

Calls 6

mkBtnFunction · 0.85
logEntryFunction · 0.85
opSectionFunction · 0.85
opRowFunction · 0.85
getElementsMethod · 0.65
selectMethod · 0.65

Tested by

no test coverage detected