Clone any website into a pixel-accurate Next.js app with AI — Playwright-measured extraction (no eyeballing), spec-gated parallel builder agents, and scored pixel-diff QA at phone/tablet/desktop. Works with Claude Code, Cursor, Copilot + 9 more.
JavaScript aiai-agentsclaudeclaude-codecursornextjspixel-perfectplaywrightscreenshot-to-codetailwindcssweb-cloningwebsite-cloner
fix(lib): restore launchPage as a shim over the shared-browser API
Mahanaicoach27068a212523
diff --git a/docs/design-references/127.0.0.1/new-page-ipad.png b/docs/design-references/127.0.0.1/new-page-ipad.pngnew file mode 100644index 0000000..0ee0402Binary files /dev/null and b/docs/design-references/127.0.0.1/new-page-ipad.png differdiff --git a/docs/design-references/127.0.0.1/new-page-pc.png b/docs/design-references/127.0.0.1/new-page-pc.pngnew file mode 100644index 0000000..2a6da72Binary files /dev/null and b/docs/design-references/127.0.0.1/new-page-pc.png differdiff --git a/docs/design-references/127.0.0.1/new-page-phone.png b/docs/design-references/127.0.0.1/new-page-phone.pngnew file mode 100644index 0000000..1e8a05cBinary files /dev/null and b/docs/design-references/127.0.0.1/new-page-phone.png differdiff --git a/docs/research/127.0.0.1/sections/n-b.json b/docs/research/127.0.0.1/sections/n-b.jsonnew file mode 100644index 0000000..6f5ffbd--- /dev/null+++ b/docs/research/127.0.0.1/sections/n-b.json@@ -0,0 +1,140 @@+{+ "url": "http://127.0.0.1:8899/",+ "viewport": "pc",+ "generatedAt": "2026-07-21T20:36:13.288Z",+ "selector": "#banner",+ "tree": {+ "tag": "section",+ "classes": null,+ "text": null,+ "rect": {+ "x": 0,+ "y": 19,+ "w": 1440,+ "h": 640+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(36, 41, 67)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "60px",+ "paddingRight": "40px",+ "paddingBottom": "60px",+ "paddingLeft": "40px",+ "width": "1360px",+ "height": "520px",+ "minHeight": "520px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 2,+ "children": [+ {+ "tag": "h1",+ "classes": null,+ "text": "Hero heading",+ "rect": {+ "x": 40,+ "y": 119,+ "w": 1360,+ "h": 94+ },+ "styles": {+ "fontSize": "60px",+ "fontWeight": "700",+ "fontFamily": "system-ui",+ "letterSpacing": "-1.2px",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "marginTop": "40.2px",+ "marginBottom": "40.2px",+ "width": "1360px",+ "height": "94px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::after": {+ "content": "\"\"",+ "width": "120px",+ "height": "6px",+ "backgroundColor": "rgb(24, 191, 239)",+ "opacity": "1",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "margin": "16px 0px 0px",+ "transition": "width 2.5s"+ }+ },+ "childCount": 0,+ "children": []+ },+ {+ "tag": "p",+ "classes": null,+ "text": "Sub copy here.",+ "rect": {+ "x": 40,+ "y": 253,+ "w": 1360,+ "h": 19+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "marginTop": "16px",+ "marginBottom": "16px",+ "width": "1360px",+ "height": "19px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ }+}diff --git a/docs/research/127.0.0.1/sections/n-c.json b/docs/research/127.0.0.1/sections/n-c.jsonnew file mode 100644index 0000000..6707ab8--- /dev/null+++ b/docs/research/127.0.0.1/sections/n-c.json@@ -0,0 +1,124 @@+{+ "url": "http://127.0.0.1:8899/",+ "viewport": "pc",+ "generatedAt": "2026-07-21T20:36:13.288Z",+ "selector": "#two",+ "tree": {+ "tag": "section",+ "classes": null,+ "text": null,+ "rect": {+ "x": 0,+ "y": 545,+ "w": 1440,+ "h": 224+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(0, 0, 0)",+ "textAlign": "start",+ "backgroundColor": "rgb(255, 255, 255)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "60px",+ "paddingRight": "40px",+ "paddingBottom": "60px",+ "paddingLeft": "40px",+ "width": "1360px",+ "height": "103.812px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(0, 0, 0)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 2,+ "children": [+ {+ "tag": "h2",+ "classes": null,+ "text": "CTA",+ "rect": {+ "x": 40,+ "y": 625,+ "w": 1360,+ "h": 29+ },+ "styles": {+ "fontSize": "24px",+ "fontWeight": "700",+ "fontFamily": "system-ui",+ "color": "rgb(0, 0, 0)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "marginTop": "19.92px",+ "marginBottom": "19.92px",+ "width": "1360px",+ "height": "29px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(0, 0, 0)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ },+ {+ "tag": "p",+ "classes": null,+ "text": "Do the thing.",+ "rect": {+ "x": 40,+ "y": 674,+ "w": 1360,+ "h": 19+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(0, 0, 0)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "marginTop": "16px",+ "marginBottom": "16px",+ "width": "1360px",+ "height": "19px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(0, 0, 0)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ }+}diff --git a/docs/research/127.0.0.1/sections/n-h.json b/docs/research/127.0.0.1/sections/n-h.jsonnew file mode 100644index 0000000..11cf640--- /dev/null+++ b/docs/research/127.0.0.1/sections/n-h.json@@ -0,0 +1,79 @@+{+ "url": "http://127.0.0.1:8899/",+ "viewport": "pc",+ "generatedAt": "2026-07-21T20:36:13.288Z",+ "selector": "header#header",+ "tree": {+ "tag": "header",+ "classes": null,+ "text": null,+ "rect": {+ "x": 0,+ "y": 0,+ "w": 1440,+ "h": 19+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(0, 0, 0)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "width": "1440px",+ "height": "19px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(0, 0, 0)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 1,+ "children": [+ {+ "tag": "nav",+ "classes": null,+ "text": "Nav",+ "rect": {+ "x": 0,+ "y": 0,+ "w": 1440,+ "h": 19+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(0, 0, 0)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "width": "1440px",+ "height": "19px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(0, 0, 0)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ }+}diff --git a/docs/research/127.0.0.1/sections/n-t.json b/docs/research/127.0.0.1/sections/n-t.jsonnew file mode 100644index 0000000..539d89e--- /dev/null+++ b/docs/research/127.0.0.1/sections/n-t.json@@ -0,0 +1,666 @@+{+ "url": "http://127.0.0.1:8899/",+ "viewport": "pc",+ "generatedAt": "2026-07-21T20:36:13.288Z",+ "selector": "#one",+ "tree": {+ "tag": "section",+ "classes": null,+ "text": null,+ "rect": {+ "x": 0,+ "y": 236,+ "w": 1440,+ "h": 664+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(0, 0, 0)",+ "textAlign": "start",+ "backgroundColor": "rgb(245, 245, 245)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "60px",+ "paddingRight": "40px",+ "paddingBottom": "60px",+ "paddingLeft": "40px",+ "width": "1360px",+ "height": "544px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(0, 0, 0)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 1,+ "children": [+ {+ "tag": "div",+ "classes": "tiles",+ "text": null,+ "rect": {+ "x": 40,+ "y": 296,+ "w": 1360,+ "h": 544+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(0, 0, 0)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "width": "1360px",+ "height": "544px",+ "display": "grid",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gap": "24px",+ "rowGap": "24px",+ "columnGap": "24px",+ "gridTemplateColumns": "437.328px 437.328px 437.344px",+ "gridTemplateRows": "260px 260px",+ "gridAutoFlow": "row",+ "borderColor": "rgb(0, 0, 0)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 6,+ "children": [+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 40,+ "y": 296,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.328px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.328px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "One",+ "rect": {+ "x": 60,+ "y": 317,+ "w": 30,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ },+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 501,+ "y": 296,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.328px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.328px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "Two",+ "rect": {+ "x": 521,+ "y": 317,+ "w": 29,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ },+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 963,+ "y": 296,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.344px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.344px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "Three",+ "rect": {+ "x": 983,+ "y": 317,+ "w": 42,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ },+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 40,+ "y": 580,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.328px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.328px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "Four",+ "rect": {+ "x": 60,+ "y": 601,+ "w": 33,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ },+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 501,+ "y": 580,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.328px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.328px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "Five",+ "rect": {+ "x": 521,+ "y": 601,+ "w": 30,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ },+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 963,+ "y": 580,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.344px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.344px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "Six",+ "rect": {+ "x": 983,+ "y": 601,+ "w": 22,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ }+ ]+ }+ ]+ }+}diff --git a/docs/research/127.0.0.1/sections/t-banner.json b/docs/research/127.0.0.1/sections/t-banner.jsonnew file mode 100644index 0000000..bdd58d9--- /dev/null+++ b/docs/research/127.0.0.1/sections/t-banner.json@@ -0,0 +1,140 @@+{+ "url": "http://127.0.0.1:8899/",+ "viewport": "pc",+ "generatedAt": "2026-07-21T20:33:54.245Z",+ "selector": "#banner",+ "tree": {+ "tag": "section",+ "classes": null,+ "text": null,+ "rect": {+ "x": 0,+ "y": 19,+ "w": 1440,+ "h": 640+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(36, 41, 67)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "60px",+ "paddingRight": "40px",+ "paddingBottom": "60px",+ "paddingLeft": "40px",+ "width": "1360px",+ "height": "520px",+ "minHeight": "520px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 2,+ "children": [+ {+ "tag": "h1",+ "classes": null,+ "text": "Hero heading",+ "rect": {+ "x": 40,+ "y": 119,+ "w": 1360,+ "h": 94+ },+ "styles": {+ "fontSize": "60px",+ "fontWeight": "700",+ "fontFamily": "system-ui",+ "letterSpacing": "-1.2px",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "marginTop": "40.2px",+ "marginBottom": "40.2px",+ "width": "1360px",+ "height": "94px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::after": {+ "content": "\"\"",+ "width": "120px",+ "height": "6px",+ "backgroundColor": "rgb(24, 191, 239)",+ "opacity": "1",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "margin": "16px 0px 0px",+ "transition": "width 2.5s"+ }+ },+ "childCount": 0,+ "children": []+ },+ {+ "tag": "p",+ "classes": null,+ "text": "Sub copy here.",+ "rect": {+ "x": 40,+ "y": 253,+ "w": 1360,+ "h": 19+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "marginTop": "16px",+ "marginBottom": "16px",+ "width": "1360px",+ "height": "19px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ }+}diff --git a/docs/research/127.0.0.1/sections/t-chrome.json b/docs/research/127.0.0.1/sections/t-chrome.jsonnew file mode 100644index 0000000..f1c2d53--- /dev/null+++ b/docs/research/127.0.0.1/sections/t-chrome.json@@ -0,0 +1,79 @@+{+ "url": "http://127.0.0.1:8899/",+ "viewport": "pc",+ "generatedAt": "2026-07-21T20:33:54.245Z",+ "selector": "header#header",+ "tree": {+ "tag": "header",+ "classes": null,+ "text": null,+ "rect": {+ "x": 0,+ "y": 0,+ "w": 1440,+ "h": 19+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(0, 0, 0)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "width": "1440px",+ "height": "19px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(0, 0, 0)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 1,+ "children": [+ {+ "tag": "nav",+ "classes": null,+ "text": "Nav",+ "rect": {+ "x": 0,+ "y": 0,+ "w": 1440,+ "h": 19+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(0, 0, 0)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "width": "1440px",+ "height": "19px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(0, 0, 0)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ }+}diff --git a/docs/research/127.0.0.1/sections/t-cta.json b/docs/research/127.0.0.1/sections/t-cta.jsonnew file mode 100644index 0000000..1d86564--- /dev/null+++ b/docs/research/127.0.0.1/sections/t-cta.json@@ -0,0 +1,124 @@+{+ "url": "http://127.0.0.1:8899/",+ "viewport": "pc",+ "generatedAt": "2026-07-21T20:33:54.245Z",+ "selector": "#two",+ "tree": {+ "tag": "section",+ "classes": null,+ "text": null,+ "rect": {+ "x": 0,+ "y": 545,+ "w": 1440,+ "h": 224+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(0, 0, 0)",+ "textAlign": "start",+ "backgroundColor": "rgb(255, 255, 255)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "60px",+ "paddingRight": "40px",+ "paddingBottom": "60px",+ "paddingLeft": "40px",+ "width": "1360px",+ "height": "103.812px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(0, 0, 0)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 2,+ "children": [+ {+ "tag": "h2",+ "classes": null,+ "text": "CTA",+ "rect": {+ "x": 40,+ "y": 625,+ "w": 1360,+ "h": 29+ },+ "styles": {+ "fontSize": "24px",+ "fontWeight": "700",+ "fontFamily": "system-ui",+ "color": "rgb(0, 0, 0)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "marginTop": "19.92px",+ "marginBottom": "19.92px",+ "width": "1360px",+ "height": "29px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(0, 0, 0)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ },+ {+ "tag": "p",+ "classes": null,+ "text": "Do the thing.",+ "rect": {+ "x": 40,+ "y": 674,+ "w": 1360,+ "h": 19+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(0, 0, 0)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "marginTop": "16px",+ "marginBottom": "16px",+ "width": "1360px",+ "height": "19px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(0, 0, 0)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ }+}diff --git a/docs/research/127.0.0.1/sections/t-tiles-hover.json b/docs/research/127.0.0.1/sections/t-tiles-hover.jsonnew file mode 100644index 0000000..e4e67be--- /dev/null+++ b/docs/research/127.0.0.1/sections/t-tiles-hover.json@@ -0,0 +1,1336 @@+{+ "url": "http://127.0.0.1:8899/",+ "viewport": "pc",+ "generatedAt": "2026-07-21T20:34:05.709Z",+ "selector": "#one",+ "trigger": "hover:.tile",+ "settleMs": 2500,+ "stateA": {+ "tag": "section",+ "classes": null,+ "text": null,+ "rect": {+ "x": 0,+ "y": 236,+ "w": 1440,+ "h": 664+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(0, 0, 0)",+ "textAlign": "start",+ "backgroundColor": "rgb(245, 245, 245)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "60px",+ "paddingRight": "40px",+ "paddingBottom": "60px",+ "paddingLeft": "40px",+ "width": "1360px",+ "height": "544px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(0, 0, 0)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 1,+ "children": [+ {+ "tag": "div",+ "classes": "tiles",+ "text": null,+ "rect": {+ "x": 40,+ "y": 296,+ "w": 1360,+ "h": 544+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(0, 0, 0)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "width": "1360px",+ "height": "544px",+ "display": "grid",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gap": "24px",+ "rowGap": "24px",+ "columnGap": "24px",+ "gridTemplateColumns": "437.328px 437.328px 437.344px",+ "gridTemplateRows": "260px 260px",+ "gridAutoFlow": "row",+ "borderColor": "rgb(0, 0, 0)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 6,+ "children": [+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 40,+ "y": 296,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.328px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.328px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "One",+ "rect": {+ "x": 60,+ "y": 317,+ "w": 30,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ },+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 501,+ "y": 296,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.328px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.328px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "Two",+ "rect": {+ "x": 521,+ "y": 317,+ "w": 29,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ },+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 963,+ "y": 296,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.344px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.344px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "Three",+ "rect": {+ "x": 983,+ "y": 317,+ "w": 42,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ },+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 40,+ "y": 580,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.328px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.328px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "Four",+ "rect": {+ "x": 60,+ "y": 601,+ "w": 33,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ },+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 501,+ "y": 580,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.328px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.328px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "Five",+ "rect": {+ "x": 521,+ "y": 601,+ "w": 30,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ },+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 963,+ "y": 580,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.344px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.344px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "Six",+ "rect": {+ "x": 983,+ "y": 601,+ "w": 22,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ }+ ]+ }+ ]+ },+ "stateB": {+ "tag": "section",+ "classes": null,+ "text": null,+ "rect": {+ "x": 0,+ "y": 236,+ "w": 1440,+ "h": 664+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(0, 0, 0)",+ "textAlign": "start",+ "backgroundColor": "rgb(245, 245, 245)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "60px",+ "paddingRight": "40px",+ "paddingBottom": "60px",+ "paddingLeft": "40px",+ "width": "1360px",+ "height": "544px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(0, 0, 0)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 1,+ "children": [+ {+ "tag": "div",+ "classes": "tiles",+ "text": null,+ "rect": {+ "x": 40,+ "y": 296,+ "w": 1360,+ "h": 544+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(0, 0, 0)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "width": "1360px",+ "height": "544px",+ "display": "grid",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gap": "24px",+ "rowGap": "24px",+ "columnGap": "24px",+ "gridTemplateColumns": "437.328px 437.328px 437.344px",+ "gridTemplateRows": "260px 260px",+ "gridAutoFlow": "row",+ "borderColor": "rgb(0, 0, 0)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 6,+ "children": [+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 40,+ "y": 296,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.328px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.328px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.15",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "One",+ "rect": {+ "x": 60,+ "y": 317,+ "w": 30,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ },+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 501,+ "y": 296,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.328px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.328px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "Two",+ "rect": {+ "x": 521,+ "y": 317,+ "w": 29,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ },+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 963,+ "y": 296,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.344px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.344px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "Three",+ "rect": {+ "x": 983,+ "y": 317,+ "w": 42,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ },+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 40,+ "y": 580,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.328px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.328px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "Four",+ "rect": {+ "x": 60,+ "y": 601,+ "w": 33,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ },+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 501,+ "y": 580,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.328px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.328px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "Five",+ "rect": {+ "x": 521,+ "y": 601,+ "w": 30,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ },+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 963,+ "y": 580,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.344px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.344px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "Six",+ "rect": {+ "x": 983,+ "y": 601,+ "w": 22,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ }+ ]+ }+ ]+ },+ "diff": [+ {+ "path": "section > div[0] > div[0]::before",+ "prop": "opacity",+ "before": "0.85",+ "after": "0.15"+ }+ ]+}diff --git a/docs/research/127.0.0.1/sections/t-tiles.json b/docs/research/127.0.0.1/sections/t-tiles.jsonnew file mode 100644index 0000000..ae10468--- /dev/null+++ b/docs/research/127.0.0.1/sections/t-tiles.json@@ -0,0 +1,666 @@+{+ "url": "http://127.0.0.1:8899/",+ "viewport": "pc",+ "generatedAt": "2026-07-21T20:33:54.245Z",+ "selector": "#one",+ "tree": {+ "tag": "section",+ "classes": null,+ "text": null,+ "rect": {+ "x": 0,+ "y": 236,+ "w": 1440,+ "h": 664+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(0, 0, 0)",+ "textAlign": "start",+ "backgroundColor": "rgb(245, 245, 245)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "60px",+ "paddingRight": "40px",+ "paddingBottom": "60px",+ "paddingLeft": "40px",+ "width": "1360px",+ "height": "544px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(0, 0, 0)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 1,+ "children": [+ {+ "tag": "div",+ "classes": "tiles",+ "text": null,+ "rect": {+ "x": 40,+ "y": 296,+ "w": 1360,+ "h": 544+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(0, 0, 0)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "width": "1360px",+ "height": "544px",+ "display": "grid",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gap": "24px",+ "rowGap": "24px",+ "columnGap": "24px",+ "gridTemplateColumns": "437.328px 437.328px 437.344px",+ "gridTemplateRows": "260px 260px",+ "gridAutoFlow": "row",+ "borderColor": "rgb(0, 0, 0)",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 6,+ "children": [+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 40,+ "y": 296,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.328px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.328px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "One",+ "rect": {+ "x": 60,+ "y": 317,+ "w": 30,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ },+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 501,+ "y": 296,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.328px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.328px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "Two",+ "rect": {+ "x": 521,+ "y": 317,+ "w": 29,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ },+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 963,+ "y": 296,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.344px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.344px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "Three",+ "rect": {+ "x": 983,+ "y": 317,+ "w": 42,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ },+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 40,+ "y": 580,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.328px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.328px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "Four",+ "rect": {+ "x": 60,+ "y": 601,+ "w": 33,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ },+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 501,+ "y": 580,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.328px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.328px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "Five",+ "rect": {+ "x": 521,+ "y": 601,+ "w": 30,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ },+ {+ "tag": "div",+ "classes": "tile",+ "text": null,+ "rect": {+ "x": 963,+ "y": 580,+ "w": 437,+ "h": 260+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundColor": "rgb(102, 102, 102)",+ "backgroundPosition": "0% 0%",+ "paddingTop": "20px",+ "paddingRight": "20px",+ "paddingBottom": "20px",+ "paddingLeft": "20px",+ "width": "397.344px",+ "height": "220px",+ "display": "block",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "overflow": "hidden",+ "overflowX": "hidden",+ "overflowY": "hidden",+ "position": "relative",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "pseudo": {+ "::before": {+ "content": "\"\"",+ "width": "437.344px",+ "height": "260px",+ "backgroundColor": "rgb(24, 191, 239)",+ "position": "absolute",+ "opacity": "0.85",+ "display": "block",+ "borderColor": "rgb(255, 255, 255)",+ "zIndex": "1",+ "transition": "opacity 2.5s"+ }+ },+ "childCount": 1,+ "children": [+ {+ "tag": "span",+ "classes": null,+ "text": "Six",+ "rect": {+ "x": 983,+ "y": 601,+ "w": 22,+ "h": 16+ },+ "styles": {+ "fontSize": "16px",+ "fontWeight": "400",+ "fontFamily": "system-ui",+ "color": "rgb(255, 255, 255)",+ "textAlign": "start",+ "backgroundPosition": "0% 0%",+ "display": "inline",+ "flexDirection": "row",+ "flexWrap": "nowrap",+ "gridAutoFlow": "row",+ "borderColor": "rgb(255, 255, 255)",+ "position": "relative",+ "zIndex": "2",+ "opacity": "1",+ "transition": "all",+ "objectFit": "fill",+ "objectPosition": "50% 50%",+ "textOverflow": "clip",+ "order": "0",+ "flexGrow": "0",+ "flexShrink": "1"+ },+ "childCount": 0,+ "children": []+ }+ ]+ }+ ]+ }+ ]+ }+}diff --git a/scripts/diff.mjs b/scripts/diff.mjsindex ee7178b..5dc3430 100644--- a/scripts/diff.mjs+++ b/scripts/diff.mjs@@ -13,24 +13,27 @@import { readFileSync, writeFileSync, mkdirSync } from "node:fs";import { PNG } from "pngjs";import pixelmatch from "pixelmatch";-import { VIEWPORTS, launchPage, gotoAndSettle, autoScroll, freezePage, slugify, parseArgs } from "./lib.mjs";+import { VIEWPORTS, openPage, closeBrowser, gotoAndSettle, autoScroll, freezePage, slugify, parseArgs } from "./lib.mjs";const args = parseArgs(process.argv.slice(2));async function shoot(url, path, viewport, selector) {- const { browser, page } = await launchPage(viewport);- await gotoAndSettle(page, url);- await autoScroll(page);- await freezePage(page); // deterministic pixels: no animations, paused videos- if (selector) {- const loc = page.locator(selector).first();- await loc.scrollIntoViewIfNeeded();- await page.waitForTimeout(400);- await loc.screenshot({ path });- } else {- await page.screenshot({ path, fullPage: true });+ const { page, close } = await openPage(viewport);+ try {+ await gotoAndSettle(page, url);+ // Full-page shots must include lazy content; section shots need only the section.+ await autoScroll(page, { force: !selector });+ await freezePage(page); // deterministic pixels: no animations, paused videos+ if (selector) {+ const loc = page.locator(selector).first();+ await loc.scrollIntoViewIfNeeded();+ await loc.screenshot({ path });+ } else {+ await page.screenshot({ path, fullPage: true });+ }+ } finally {+ await close();}- await browser.close();return path;}@@ -43,8 +46,12 @@ if (args.original && args.clone) {const name = args.name || slugify(args.selector || "page");const dir = "docs/research/qa";mkdirSync(dir, { recursive: true });- fileA = await shoot(args.original, `${dir}/${name}-${vp}-original.png`, VIEWPORTS[vp], args.selector);- fileB = await shoot(args.clone, `${dir}/${name}-${vp}-clone.png`, VIEWPORTS[vp], args["clone-selector"] || args.selector);+ // Both sides shoot concurrently on one browser — they're independent pages.+ [fileA, fileB] = await Promise.all([+ shoot(args.original, `${dir}/${name}-${vp}-original.png`, VIEWPORTS[vp], args.selector),+ shoot(args.clone, `${dir}/${name}-${vp}-clone.png`, VIEWPORTS[vp], args["clone-selector"] || args.selector),+ ]);+ await closeBrowser();outPath = outPath || `${dir}/${name}-${vp}-diff.png`;}if (!fileA || !fileB) {diff --git a/scripts/extract/probe.mjs b/scripts/extract/probe.mjsindex f9a68f3..6dd43ad 100644--- a/scripts/extract/probe.mjs+++ b/scripts/extract/probe.mjs@@ -4,24 +4,31 @@// because writing "iPad: same as desktop" makes builders guess, and guesses cost// QA points on any site whose spacing scales with root font-size.//+// All three viewports load concurrently on one browser.+//// Usage:// node scripts/extract/probe.mjs <url> --selector "section#two" [--selector "h2" ...]// node scripts/extract/probe.mjs <url> --selector "#two" --props fontSize,paddingTop,marginBottom//// Output: a markdown table per selector (stdout) + docs/research/<host>/probe-<name>.json-import { VIEWPORTS, launchPage, gotoAndSettle, autoScroll, hostOf, slugify, writeJson } from "../lib.mjs";+import {+ VIEWPORTS,+ forEachViewport,+ closeBrowser,+ gotoAndSettle,+ autoScroll,+ hostOf,+ slugify,+ writeJson,+ parseArgs,+ toList,+} from "../lib.mjs";-// --selector can repeat, so parse args manually rather than with parseArgs()-const argv = process.argv.slice(2);-const url = argv.find((a) => !a.startsWith("--") && argv[argv.indexOf(a) - 1]?.startsWith("--") !== true);-const selectors = [];-let props = null;-let name = null;-for (let i = 0; i < argv.length; i++) {- if (argv[i] === "--selector") selectors.push(argv[++i]);- else if (argv[i] === "--props") props = argv[++i].split(",");- else if (argv[i] === "--name") name = argv[++i];-}+const args = parseArgs(process.argv.slice(2));+const url = args._[0];+const selectors = toList(args.selector);+const props = args.props ? String(args.props).split(",") : null;+const name = typeof args.name === "string" ? args.name : null;if (!url || !selectors.length) {console.error('Usage: node scripts/extract/probe.mjs <url> --selector "css" [--selector "css2"] [--props a,b,c]');process.exit(1);@@ -49,15 +56,14 @@ const PROBE = `(function (selectors, props) {return out;})`;-const results = {};-for (const [vpName, vp] of Object.entries(VIEWPORTS)) {- const { browser, page } = await launchPage(vp);+const results = await forEachViewport(Object.keys(VIEWPORTS), async (page, vpName) => {await gotoAndSettle(page, url);await autoScroll(page);- results[vpName] = await page.evaluate(`(${PROBE})(${JSON.stringify(selectors)}, ${JSON.stringify(USE)})`);- await browser.close();- console.error(` ✓ probed @ ${vpName} (${vp.width}px)`);-}+ const r = await page.evaluate(`(${PROBE})(${JSON.stringify(selectors)}, ${JSON.stringify(USE)})`);+ console.error(` ✓ probed @ ${vpName} (${VIEWPORTS[vpName].width}px)`);+ return r;+});+await closeBrowser();// Markdown tables — only rows that actually differ across viewports are interesting,// but print everything so the spec author can copy what matters.diff --git a/scripts/extract/responsive.mjs b/scripts/extract/responsive.mjsindex 6fca156..92b8542 100644--- a/scripts/extract/responsive.mjs+++ b/scripts/extract/responsive.mjs@@ -7,7 +7,7 @@// Usage: node scripts/extract/responsive.mjs <url> [--selector "css"]// (no --selector = auto-detect top-level sections: header, main children, footer)// Output: docs/research/<host>/responsive.json-import { VIEWPORTS, launchPage, gotoAndSettle, autoScroll, hostOf, writeJson, parseArgs } from "../lib.mjs";+import { VIEWPORTS, openPage, closeBrowser, gotoAndSettle, autoScroll, hostOf, writeJson, parseArgs } from "../lib.mjs";const args = parseArgs(process.argv.slice(2));const url = args._[0];@@ -179,23 +179,35 @@ let sections = null;// indistinguishable by height.const ORDER = ["pc", "ipad", "phone"].filter((v) => VIEWPORTS[v]);-for (const vpName of ORDER) {- const vp = VIEWPORTS[vpName];- const { browser, page } = await launchPage(vp);- await gotoAndSettle(page, url);- await autoScroll(page);- if (!sections) {- sections = args.selector- ? [{ selector: args.selector, label: args.selector }]- : await page.evaluate(`(${DETECT})()`);- }- results[vpName] = {};- for (const s of sections) {- results[vpName][s.selector] = await page.evaluate(`(${SIGNATURE})(${JSON.stringify(s.selector)})`);- }- await browser.close();- console.error(` ✓ measured ${sections.length} sections @ ${vpName} (${vp.width}px)`);-}+// Load all three viewports concurrently — that's the slow part and the three+// loads are independent. Detection still happens on PC alone, then every+// viewport measures the same section list.+const loaded = await Promise.all(+ ORDER.map(async (vpName) => {+ const { page, close } = await openPage(VIEWPORTS[vpName]);+ await gotoAndSettle(page, url);+ await autoScroll(page);+ return { vpName, page, close };+ })+);++const pcPage = (loaded.find((l) => l.vpName === "pc") || loaded[0]).page;+sections = args.selector+ ? [{ selector: args.selector, label: args.selector }]+ : await pcPage.evaluate(`(${DETECT})()`);++await Promise.all(+ loaded.map(async ({ vpName, page, close }) => {+ const measured = {};+ for (const s of sections) {+ measured[s.selector] = await page.evaluate(`(${SIGNATURE})(${JSON.stringify(s.selector)})`);+ }+ results[vpName] = measured;+ await close();+ console.error(` ✓ measured ${sections.length} sections @ ${vpName} (${VIEWPORTS[vpName].width}px)`);+ })+);+await closeBrowser();// Build human-readable change summaries per sectionconst summarize = (sel) => {diff --git a/scripts/extract/screenshot.mjs b/scripts/extract/screenshot.mjsindex ca462b0..8187bb3 100644--- a/scripts/extract/screenshot.mjs+++ b/scripts/extract/screenshot.mjs@@ -1,11 +1,22 @@#!/usr/bin/env node// Screenshot a page (or one section) at phone/iPad/PC viewports.+// All viewports render concurrently on one browser.// Usage:// node scripts/extract/screenshot.mjs <url> [--name hero] [--selector "css"]// [--viewports phone,ipad,pc] [--no-freeze] [--out-dir docs/design-references]// Output: <out-dir>/<host>/<name>-<viewport>.pngimport { mkdirSync } from "node:fs";-import { VIEWPORTS, launchPage, gotoAndSettle, autoScroll, freezePage, hostOf, slugify, parseArgs } from "../lib.mjs";+import {+ VIEWPORTS,+ forEachViewport,+ closeBrowser,+ gotoAndSettle,+ autoScroll,+ freezePage,+ hostOf,+ slugify,+ parseArgs,+} from "../lib.mjs";const args = parseArgs(process.argv.slice(2));const url = args._[0];@@ -18,20 +29,21 @@ const name = args.name || (args.selector ? slugify(args.selector) : "page");const outDir = `${args["out-dir"] || "docs/design-references"}/${hostOf(url)}`;mkdirSync(outDir, { recursive: true });-for (const vp of wanted) {- const { browser, page } = await launchPage(VIEWPORTS[vp]);+await forEachViewport(wanted, async (page, vp) => {await gotoAndSettle(page, url);- await autoScroll(page); // lazy content must be loaded before a full-page shot+ // A full-page shot must include lazy content, so force the scroll pass here+ // even when the page shows no lazy-loading signals.+ await autoScroll(page, { force: !args.selector });if (!args["no-freeze"]) await freezePage(page);const path = `${outDir}/${name}-${vp}.png`;if (args.selector) {const loc = page.locator(args.selector).first();await loc.scrollIntoViewIfNeeded();- await page.waitForTimeout(400);await loc.screenshot({ path });} else {await page.screenshot({ path, fullPage: true });}console.log(` ✓ ${path}`);- await browser.close();-}+});++await closeBrowser();diff --git a/scripts/extract/section.mjs b/scripts/extract/section.mjsindex 565f04a..fe60dac 100644--- a/scripts/extract/section.mjs+++ b/scripts/extract/section.mjs@@ -1,31 +1,50 @@#!/usr/bin/env node-// Deep-extract one section: full computed-style DOM walk + verbatim text + assets.-// Optionally capture a second state (scroll/click/hover) and diff the two.+// Deep-extract one or more sections: full computed-style DOM walk + verbatim+// text + assets. Optionally capture a second state (scroll/click/hover) and+// diff the two.//// Usage:// node scripts/extract/section.mjs <url> --selector "header" [--name header]// [--viewport pc|ipad|phone] [--depth 5]// [--state scroll:600 | click:.tab-btn | hover:.card]//+// --selector and --name repeat, and every section is walked from a SINGLE+// page load. Extracting five sections is one navigation, not five:+// node scripts/extract/section.mjs <url> \+// --selector "#banner" --name banner \+// --selector "#one" --name tiles+//// Output: docs/research/<host>/sections/<name>.json (stateA/stateB/diff when --state used)-import { VIEWPORTS, launchPage, gotoAndSettle, autoScroll, hostOf, slugify, writeJson, parseArgs } from "../lib.mjs";+import {+ VIEWPORTS,+ openPage,+ closeBrowser,+ gotoAndSettle,+ autoScroll,+ transitionMs,+ hostOf,+ slugify,+ writeJson,+ parseArgs,+ toList,+} from "../lib.mjs";const args = parseArgs(process.argv.slice(2));const url = args._[0];-const selector = args.selector;-if (!url || !selector) {+const selectors = toList(args.selector);+if (!url || !selectors.length) {console.error('Usage: node scripts/extract/section.mjs <url> --selector "css" [--name x] [--state scroll:600|click:sel|hover:sel]');+ console.error(" --selector/--name repeat; all sections extract from one page load.");process.exit(1);}+const names = toList(args.name);const viewport = VIEWPORTS[args.viewport || "pc"];const depth = Number(args.depth ?? 5);-const name = args.name || slugify(selector);+const targets = selectors.map((selector, i) => ({ selector, name: names[i] || slugify(selector) }));-const { browser, page } = await launchPage(viewport);+const { page, close } = await openPage(viewport);await gotoAndSettle(page, url);await autoScroll(page);-await page.locator(selector).first().scrollIntoViewIfNeeded().catch(() => {});-await page.waitForTimeout(600);// The walker runs in the page. Captures every relevant computed property per element.const WALKER = `(function (selector, maxDepth) {@@ -115,16 +134,47 @@ const WALKER = `(function (selector, maxDepth) {return walk(el, 0);})`;-const capture = () => page.evaluate(`(${WALKER})(${JSON.stringify(selector)}, ${depth})`);+async function capture(selector) {+ await page.locator(selector).first().scrollIntoViewIfNeeded().catch(() => {});+ return page.evaluate(`(${WALKER})(${JSON.stringify(selector)}, ${depth})`);+}-const stateA = await capture();-if (stateA.error) {- console.error(stateA.error);- await browser.close();- process.exit(1);+// Style deltas between two captures of the same subtree, element by element.+// Both real styles and pseudo-element styles count: a hover effect built from a+// ::before overlay changes nothing on the element itself.+function diffNode(a, b, path, out) {+ if (!a || !b || a.error || b.error) return;+ const keys = new Set([...Object.keys(a.styles || {}), ...Object.keys(b.styles || {})]);+ for (const k of keys) {+ if ((a.styles?.[k] || null) !== (b.styles?.[k] || null)) {+ out.push({ path, prop: k, before: a.styles?.[k] ?? "(unset)", after: b.styles?.[k] ?? "(unset)" });+ }+ }+ for (const pe of ["::before", "::after"]) {+ const pa = a.pseudo?.[pe] || {};+ const pb = b.pseudo?.[pe] || {};+ const pkeys = new Set([...Object.keys(pa), ...Object.keys(pb)]);+ for (const k of pkeys) {+ if ((pa[k] || null) !== (pb[k] || null)) {+ out.push({ path: path + pe, prop: k, before: pa[k] ?? "(unset)", after: pb[k] ?? "(unset)" });+ }+ }+ }+ (a.children || []).forEach((c, i) => diffNode(c, b.children?.[i], `${path} > ${c.tag}[${i}]`, out));}-let result = { url, selector, viewport: args.viewport || "pc", generatedAt: new Date().toISOString() };+const meta = { url, viewport: args.viewport || "pc", generatedAt: new Date().toISOString() };+const stateA = {};+for (const { selector } of targets) {+ const tree = await capture(selector);+ if (tree.error) {+ console.error(tree.error);+ await close();+ await closeBrowser();+ process.exit(1);+ }+ stateA[selector] = tree;+}if (args.state) {const [kind, ...rest] = String(args.state).split(":");@@ -133,27 +183,33 @@ if (args.state) {if (kind === "scroll") await page.evaluate((y) => window.scrollTo(0, Number(y)), target || "600");else if (kind === "click") await page.locator(target).first().click({ timeout: 5000 }).catch((e) => console.error("click failed:", e.message));else if (kind === "hover") await page.locator(target).first().hover({ timeout: 5000 }).catch((e) => console.error("hover failed:", e.message));- await page.waitForTimeout(800); // let transitions finish- const stateB = await capture();- // diff styles per element path- function diffNode(a, b, path, out) {- if (!a || !b || a.error || b.error) return;- const keys = new Set([...Object.keys(a.styles || {}), ...Object.keys(b.styles || {})]);- for (const k of keys) {- if ((a.styles?.[k] || null) !== (b.styles?.[k] || null)) {- out.push({ path, prop: k, before: a.styles?.[k] ?? "(unset)", after: b.styles?.[k] ?? "(unset)" });- }- }- (a.children || []).forEach((c, i) => diffNode(c, b.children?.[i], `${path} > ${c.tag}[${i}]`, out));+ // Wait exactly as long as this section's slowest transition, not a flat guess.+ // A 2.5s overlay fade used to get captured mid-flight and recorded as final.+ const settle = Math.max(...(await Promise.all(targets.map((t) => transitionMs(page, t.selector)))));+ await page.waitForTimeout(settle);++ for (const { selector, name } of targets) {+ const stateB = await capture(selector);+ const diff = [];+ diffNode(stateA[selector], stateB, stateA[selector].tag, diff);+ writeJson(`docs/research/${hostOf(url)}/sections/${name}.json`, {+ ...meta,+ selector,+ trigger: args.state,+ settleMs: settle,+ stateA: stateA[selector],+ stateB,+ diff,+ });+ console.log(`${name}: ${diff.length} properties changed after "${args.state}" (waited ${settle}ms)`);}- const diff = [];- diffNode(stateA, stateB, stateA.tag, diff);- result = { ...result, trigger: args.state, stateA, stateB, diff };- console.log(`State diff: ${diff.length} properties changed after "${args.state}"`);} else {- result = { ...result, tree: stateA };+ for (const { selector, name } of targets) {+ writeJson(`docs/research/${hostOf(url)}/sections/${name}.json`, { ...meta, selector, tree: stateA[selector] });+ }+ console.log(`Extracted ${targets.length} section(s) from one page load.`);}-await browser.close();-writeJson(`docs/research/${hostOf(url)}/sections/${name}.json`, result);+await close();+await closeBrowser();diff --git a/scripts/lib.mjs b/scripts/lib.mjsindex 8bdc67f..51a5570 100644--- a/scripts/lib.mjs+++ b/scripts/lib.mjs@@ -37,35 +37,200 @@ export function writeJson(path, data) {console.error(` ✓ wrote ${path}`);}-export async function launchPage(viewport = VIEWPORTS.pc) {- const browser = await chromium.launch({ headless: true });- const context = await browser.newContext({- viewport,- userAgent:- "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36",- deviceScaleFactor: 1,+// ---------------------------------------------------------------------------+// Browser lifecycle+//+// One Chromium per process, shared by every context. Launching costs ~350ms;+// opening a context on a live browser costs ~40ms. Scripts that touch three+// viewports used to pay the launch three times — now they pay it once.+// ---------------------------------------------------------------------------++let _browser = null;++const CONTEXT_OPTS = {+ userAgent:+ "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36",+ deviceScaleFactor: 1,+};++export async function getBrowser() {+ if (!_browser) _browser = await chromium.launch({ headless: true });+ return _browser;+}++// Every script must call this before exiting — the browser process keeps the+// Node event loop alive otherwise.+export async function closeBrowser() {+ if (_browser) {+ await _browser.close();+ _browser = null;+ }+}++// Lazy-loading detection: count IntersectionObservers the page constructs, so+// autoScroll() can tell "this page reveals content on scroll" from "this page+// is fully painted already" instead of always paying the scroll cost.+async function instrumentLazySignals(context) {+ await context.addInitScript(() => {+ window.__ioCount = 0;+ const Native = window.IntersectionObserver;+ if (!Native) return;+ window.IntersectionObserver = class extends Native {+ constructor(...a) {+ super(...a);+ window.__ioCount++;+ }+ };});+}++// Open a page on the shared browser. `close()` disposes only this context.+export async function openPage(viewport = VIEWPORTS.pc) {+ const browser = await getBrowser();+ const context = await browser.newContext({ viewport, ...CONTEXT_OPTS });+ await instrumentLazySignals(context);const page = await context.newPage();- return { browser, page };+ return { page, context, close: () => context.close() };+}++// Back-compat for single-page scripts written against the older API:+// const { browser, page } = await launchPage(); … await browser.close();+// `browser.close()` tears down the context AND the shared Chromium, matching the+// old semantics exactly. Deferring the teardown to a process exit hook would+// deadlock: Playwright's open socket keeps the event loop alive, so 'beforeExit'+// never fires and the script hangs instead of exiting.+export async function launchPage(viewport = VIEWPORTS.pc) {+ const { page, close } = await openPage(viewport);+ return {+ page,+ browser: {+ close: async () => {+ await close();+ await closeBrowser();+ },+ },+ };+}++// Run `fn(page, viewportName)` at several viewports concurrently on one browser.+// Returns results keyed by viewport name. Page loads are the expensive part and+// they overlap completely here.+export async function forEachViewport(names, fn) {+ const entries = await Promise.all(+ names.map(async (vpName) => {+ const { page, close } = await openPage(VIEWPORTS[vpName]);+ try {+ return [vpName, await fn(page, vpName)];+ } finally {+ await close();+ }+ })+ );+ return Object.fromEntries(entries);+}++// ---------------------------------------------------------------------------+// Waiting — conditions, not sleeps+// ---------------------------------------------------------------------------++// Wait until the document stops growing. Replaces a fixed sleep with the signal+// the sleep was standing in for: late CSS, webfonts and hero images all change+// scrollHeight when they land.+export async function settleLayout(page, { timeout = 3000, quietMs = 150 } = {}) {+ await page+ .evaluate(+ async ({ timeout, quietMs }) => {+ const deadline = Date.now() + timeout;+ let last = -1;+ let stableSince = 0;+ while (Date.now() < deadline) {+ const h = document.documentElement.scrollHeight;+ if (h === last) {+ if (!stableSince) stableSince = Date.now();+ if (Date.now() - stableSince >= quietMs) return;+ } else {+ last = h;+ stableSince = 0;+ }+ await new Promise((r) => requestAnimationFrame(r));+ }+ },+ { timeout, quietMs }+ )+ .catch(() => {});}export async function gotoAndSettle(page, url) {await page.goto(url, { waitUntil: "load", timeout: 60000 });- await page.waitForTimeout(1500);+ // Network quiet + fonts ready + stable height are the three things the old+ // blanket 1500ms was guessing at. On a fast page this returns almost instantly.+ await page.waitForLoadState("networkidle", { timeout: 15000 }).catch(() => {});+ await page.evaluate(() => document.fonts?.ready).catch(() => {});+ await settleLayout(page);}-// Scroll to bottom in steps (triggers lazy-loaded images/animations), then back to top.-export async function autoScroll(page) {+// Scroll to bottom in steps (triggers lazy-loaded images/animations), then back+// to top. Skipped entirely when the page shows no sign of lazy content — pass+// `{ force: true }` to scroll regardless.+export async function autoScroll(page, { force = false } = {}) {+ const needed = force+ ? true+ : await page+ .evaluate(() => {+ if (window.__ioCount > 0) return true;+ return !!document.querySelector(+ 'img[loading="lazy"],iframe[loading="lazy"],[data-src],[data-srcset],[data-bg],[data-lazy]'+ );+ })+ .catch(() => true); // if the probe fails, assume the worst and scroll++ if (!needed) return;+await page.evaluate(async () => {+ // Half-viewport steps: IntersectionObserver thresholds commonly need an+ // element substantially in view, and a full-viewport jump can skip them.const step = window.innerHeight / 2;- const max = document.body.scrollHeight;- for (let y = 0; y <= max; y += step) {+ for (let y = 0; y <= document.documentElement.scrollHeight; y += step) {window.scrollTo(0, y);- await new Promise((r) => setTimeout(r, 120));+ // Two frames is enough for observer callbacks to fire and request images;+ // whether those images *arrive* is what the networkidle wait below covers.+ await new Promise((r) => requestAnimationFrame(() => requestAnimationFrame(r)));}window.scrollTo(0, 0);});- await page.waitForTimeout(800);+ await page.waitForLoadState("networkidle", { timeout: 10000 }).catch(() => {});+ await settleLayout(page);+}++// How long the transitions inside `selector` actually take, in ms — so a state+// capture can wait exactly that long instead of guessing. Covers ::before and+// ::after, where hover overlays usually live.+export async function transitionMs(page, selector, { min = 150, max = 4000 } = {}) {+ const ms = await page+ .evaluate(+ ({ selector, max }) => {+ const root = document.querySelector(selector);+ if (!root) return 0;+ const els = [root, ...root.querySelectorAll("*")].slice(0, 500);+ const nums = (v) => String(v || "").split(",").map((s) => parseFloat(s) || 0);+ let worst = 0;+ for (const el of els) {+ for (const pe of [null, "::before", "::after"]) {+ const cs = getComputedStyle(el, pe);+ const dur = nums(cs.transitionDuration);+ const delay = nums(cs.transitionDelay);+ for (let i = 0; i < dur.length; i++) {+ worst = Math.max(worst, (dur[i] + (delay[i] || 0)) * 1000);+ }+ }+ if (worst >= max) return max;+ }+ return worst;+ },+ { selector, max }+ )+ .catch(() => 0);+ return Math.min(max, Math.max(min, Math.round(ms)));}// Kill animations/transitions/videos so screenshots are deterministic (for QA diffs).@@ -83,6 +248,7 @@ export async function freezePage(page) {}// Tiny CLI arg parser: --key value / --flag -> { _: [positionals], key: value, flag: true }+// A repeated key collects into an array (--selector a --selector b -> ["a","b"]).export function parseArgs(argv) {const out = { _: [] };for (let i = 0; i < argv.length; i++) {@@ -90,15 +256,19 @@ export function parseArgs(argv) {if (a.startsWith("--")) {const key = a.slice(2);const next = argv[i + 1];- if (next !== undefined && !next.startsWith("--")) {- out[key] = next;- i++;- } else {- out[key] = true;- }+ const val = next !== undefined && !next.startsWith("--") ? (i++, next) : true;+ if (key in out) out[key] = [].concat(out[key], val);+ else out[key] = val;} else {out._.push(a);}}return out;}++// Normalise a possibly-repeated arg into an array. `--selector x` and+// `--selector x --selector y` both come back as arrays.+export function toList(v) {+ if (v === undefined || v === true) return [];+ return [].concat(v);+}