MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / readConsoleStyle

Function readConsoleStyle

e2e/scenarios/artifacts.test.ts:146–156  ·  view source on GitHub ↗
(
  page: Page,
)

Source from the content-addressed store, hash-verified

144 page.evaluate(() => globalThis.__handshakeOrder ?? []);
145
146const readConsoleStyle = (
147 page: Page,
148): Promise<{ primary: string; buttonBg: string; styleSheets: number }> =>
149 page.evaluate(() => {
150 const button = document.querySelector("button");
151 return {
152 primary: getComputedStyle(document.documentElement).getPropertyValue("--primary").trim(),
153 buttonBg: button ? getComputedStyle(button).backgroundColor : "",
154 styleSheets: document.styleSheets.length,
155 };
156 });
157
158scenario(
159 "Artifacts · create-artifact hands a non-Apps client a deep link that renders the live component",

Callers 1

artifacts.test.tsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected