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

Function buildHistorySection

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

Source from the content-addressed store, hash-verified

971}
972
973function buildHistorySection(): HTMLDivElement {
974 const undo = mkBtn("← Undo", "", () => {
975 comp!.undo();
976 logEntry("undo", "dispatched");
977 });
978 const redo = mkBtn("Redo →", "", () => {
979 comp!.redo();
980 logEntry("redo", "dispatched");
981 });
982 const canCheck = mkBtn("can(addGsapTween)?", "", () => {
983 const r = comp!.can({
984 type: "addGsapTween",
985 target: "hf-badge",
986 tween: { method: "to", duration: 0.5 },
987 });
988 logEntry("info", { "can(addGsapTween)": r });
989 });
990 const overrides = mkBtn("getOverrides()", "", () => logEntry("info", comp!.getOverrides()));
991 const flush = mkBtn("flush", "", () => {
992 comp!.flush().then(() => logEntry("info", "flush complete"));
993 });
994 return opSection("History / inspect", opRow(undo, redo), opRow(canCheck, overrides, flush));
995}
996
997const OPS_SECTIONS = [
998 buildPreviewSelectSection,

Callers

nothing calls this directly

Calls 9

mkBtnFunction · 0.85
logEntryFunction · 0.85
opSectionFunction · 0.85
opRowFunction · 0.85
undoMethod · 0.65
redoMethod · 0.65
canMethod · 0.65
getOverridesMethod · 0.65
flushMethod · 0.65

Tested by

no test coverage detected