tether-ui 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (79) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +241 -0
  3. package/dist/cli/format.d.ts +3 -0
  4. package/dist/cli/format.js +30 -0
  5. package/dist/cli/index.d.ts +2 -0
  6. package/dist/cli/index.js +135 -0
  7. package/dist/contract/infer.d.ts +2 -0
  8. package/dist/contract/infer.js +27 -0
  9. package/dist/drift/compare.d.ts +5 -0
  10. package/dist/drift/compare.js +121 -0
  11. package/dist/report/server.d.ts +1 -0
  12. package/dist/report/server.js +80 -0
  13. package/dist/scanner/browser.d.ts +2 -0
  14. package/dist/scanner/browser.js +22 -0
  15. package/dist/scanner/collect.d.ts +10 -0
  16. package/dist/scanner/collect.js +171 -0
  17. package/dist/scanner/scan.d.ts +2 -0
  18. package/dist/scanner/scan.js +82 -0
  19. package/dist/types.d.ts +78 -0
  20. package/dist/types.js +12 -0
  21. package/dist/utils/config.d.ts +5 -0
  22. package/dist/utils/config.js +85 -0
  23. package/dist/utils/normalize.d.ts +4 -0
  24. package/dist/utils/normalize.js +66 -0
  25. package/dist/utils/storage.d.ts +2 -0
  26. package/dist/utils/storage.js +17 -0
  27. package/package.json +60 -0
  28. package/report/out/404/index.html +1 -0
  29. package/report/out/404.html +1 -0
  30. package/report/out/__next.__PAGE__.txt +20 -0
  31. package/report/out/__next._full.txt +15 -0
  32. package/report/out/__next._tree.txt +2 -0
  33. package/report/out/_next/static/NEP_BMzhg1ixudz9w2f3I/_buildManifest.js +1 -0
  34. package/report/out/_next/static/NEP_BMzhg1ixudz9w2f3I/_ssgManifest.js +1 -0
  35. package/report/out/_next/static/chunks/100-cde31512e90ea4ee.js +1 -0
  36. package/report/out/_next/static/chunks/158-65f5491737ca4c2e.js +52 -0
  37. package/report/out/_next/static/chunks/979-2cc4e681ca63e0b3.js +1 -0
  38. package/report/out/_next/static/chunks/app/_global-error/page-b656bfa1d65ad738.js +1 -0
  39. package/report/out/_next/static/chunks/app/_not-found/page-e3039971fa1f5f8d.js +1 -0
  40. package/report/out/_next/static/chunks/app/contract/page-340f86944045adea.js +1 -0
  41. package/report/out/_next/static/chunks/app/drift/page-559460ac1a19903b.js +1 -0
  42. package/report/out/_next/static/chunks/app/layout-6c6cbe0311c0f643.js +1 -0
  43. package/report/out/_next/static/chunks/app/page-ab86e7319bb488c8.js +1 -0
  44. package/report/out/_next/static/chunks/app/viewports/page-8970bc5bd4e2e4f2.js +1 -0
  45. package/report/out/_next/static/chunks/c7879cf7-33323d49ba6da96a.js +1 -0
  46. package/report/out/_next/static/chunks/framework-daae672d050d1c9a.js +1 -0
  47. package/report/out/_next/static/chunks/main-42ac6ccb2a105cbb.js +5 -0
  48. package/report/out/_next/static/chunks/main-app-91d98c37495a2d56.js +1 -0
  49. package/report/out/_next/static/chunks/next/dist/client/components/builtin/app-error-b656bfa1d65ad738.js +1 -0
  50. package/report/out/_next/static/chunks/next/dist/client/components/builtin/forbidden-b656bfa1d65ad738.js +1 -0
  51. package/report/out/_next/static/chunks/next/dist/client/components/builtin/global-error-657c3d8e42266fe3.js +1 -0
  52. package/report/out/_next/static/chunks/next/dist/client/components/builtin/not-found-b656bfa1d65ad738.js +1 -0
  53. package/report/out/_next/static/chunks/next/dist/client/components/builtin/unauthorized-b656bfa1d65ad738.js +1 -0
  54. package/report/out/_next/static/chunks/polyfills-42372ed130431b0a.js +1 -0
  55. package/report/out/_next/static/chunks/webpack-21c0bda91597affb.js +1 -0
  56. package/report/out/_next/static/css/b85889345c486052.css +1 -0
  57. package/report/out/_not-found/__next._full.txt +16 -0
  58. package/report/out/_not-found/__next._not-found.__PAGE__.txt +22 -0
  59. package/report/out/_not-found/__next._tree.txt +2 -0
  60. package/report/out/_not-found/index.html +1 -0
  61. package/report/out/_not-found/index.txt +16 -0
  62. package/report/out/contract/__next._full.txt +17 -0
  63. package/report/out/contract/__next._tree.txt +2 -0
  64. package/report/out/contract/__next.contract.__PAGE__.txt +23 -0
  65. package/report/out/contract/index.html +1 -0
  66. package/report/out/contract/index.txt +17 -0
  67. package/report/out/drift/__next._full.txt +17 -0
  68. package/report/out/drift/__next._tree.txt +2 -0
  69. package/report/out/drift/__next.drift.__PAGE__.txt +23 -0
  70. package/report/out/drift/index.html +1 -0
  71. package/report/out/drift/index.txt +17 -0
  72. package/report/out/index.html +1 -0
  73. package/report/out/index.txt +15 -0
  74. package/report/out/knot.svg +1 -0
  75. package/report/out/viewports/__next._full.txt +17 -0
  76. package/report/out/viewports/__next._tree.txt +2 -0
  77. package/report/out/viewports/__next.viewports.__PAGE__.txt +23 -0
  78. package/report/out/viewports/index.html +1 -0
  79. package/report/out/viewports/index.txt +17 -0
package/package.json ADDED
@@ -0,0 +1,60 @@
1
+ {
2
+ "name": "tether-ui",
3
+ "version": "0.1.0",
4
+ "description": "Visual QA for AI-coded interfaces. Learn a visual contract and detect frontend drift.",
5
+ "type": "module",
6
+ "license": "MIT",
7
+ "engines": {
8
+ "node": ">=20.9"
9
+ },
10
+ "bin": {
11
+ "tether": "dist/cli/index.js"
12
+ },
13
+ "files": [
14
+ "dist",
15
+ "report/out",
16
+ "README.md",
17
+ "LICENSE"
18
+ ],
19
+ "keywords": [
20
+ "visual-qa",
21
+ "design-system",
22
+ "playwright",
23
+ "ai",
24
+ "frontend",
25
+ "cli"
26
+ ],
27
+ "scripts": {
28
+ "build": "npm run build:cli && npm run build:report",
29
+ "build:cli": "tsc -p tsconfig.json",
30
+ "build:report": "next build report --webpack",
31
+ "dev": "next dev report -p 4318",
32
+ "demo": "tsx demo/server.ts",
33
+ "test": "tsx --test tests/*.test.ts",
34
+ "test:e2e": "tsx scripts/e2e.ts",
35
+ "assets": "tsx scripts/generate-readme-assets.ts",
36
+ "lint": "tsc --noEmit && tsc -p report/tsconfig.json --noEmit",
37
+ "browser:install": "playwright install chromium",
38
+ "prepack": "npm run build",
39
+ "format": "prettier --write src report/app scripts tests demo/server.ts"
40
+ },
41
+ "dependencies": {
42
+ "commander": "^14.0.0",
43
+ "jiti": "^2.6.0",
44
+ "playwright": "^1.58.0"
45
+ },
46
+ "devDependencies": {
47
+ "@tailwindcss/postcss": "^4.2.0",
48
+ "@types/node": "^22.0.0",
49
+ "@types/react": "^19.0.0",
50
+ "@types/react-dom": "^19.0.0",
51
+ "lucide-react": "^0.577.0",
52
+ "next": "^16.2.0",
53
+ "prettier": "^3.9.9",
54
+ "react": "^19.2.0",
55
+ "react-dom": "^19.2.0",
56
+ "tailwindcss": "^4.2.0",
57
+ "tsx": "^4.21.0",
58
+ "typescript": "^5.9.0"
59
+ }
60
+ }
@@ -0,0 +1 @@
1
+ <!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="/_next/static/css/b85889345c486052.css" data-precedence="next"/><link rel="preload" as="script" fetchPriority="low" href="/_next/static/chunks/webpack-21c0bda91597affb.js"/><script src="/_next/static/chunks/c7879cf7-33323d49ba6da96a.js" async=""></script><script src="/_next/static/chunks/158-65f5491737ca4c2e.js" async=""></script><script src="/_next/static/chunks/main-app-91d98c37495a2d56.js" async=""></script><meta name="robots" content="noindex"/><title>tether — Visual QA</title><meta name="description" content="Compare your frontend with its saved visual baseline."/><link rel="icon" href="/knot.svg"/><title>404: This page could not be found.</title><script src="/_next/static/chunks/polyfills-42372ed130431b0a.js" noModule=""></script></head><body><div hidden=""><!--$--><!--/$--></div><div style="font-family:system-ui,&quot;Segoe UI&quot;,Roboto,Helvetica,Arial,sans-serif,&quot;Apple Color Emoji&quot;,&quot;Segoe UI Emoji&quot;;height:100vh;text-align:center;display:flex;flex-direction:column;align-items:center;justify-content:center"><div><style>body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}</style><h1 class="next-error-h1" style="display:inline-block;margin:0 20px 0 0;padding:0 23px 0 0;font-size:24px;font-weight:500;vertical-align:top;line-height:49px">404</h1><div style="display:inline-block"><h2 style="font-size:14px;font-weight:400;line-height:49px;margin:0">This page could not be found.</h2></div></div></div><!--$--><!--/$--><script src="/_next/static/chunks/webpack-21c0bda91597affb.js" id="_R_" async=""></script><script>(self.__next_f=self.__next_f||[]).push([0])</script><script>self.__next_f.push([1,"1:\"$Sreact.fragment\"\n2:I[1133,[],\"\"]\n3:I[4297,[],\"\"]\n4:I[1872,[],\"OutletBoundary\"]\n5:\"$Sreact.suspense\"\n8:I[1872,[],\"ViewportBoundary\"]\na:I[1872,[],\"MetadataBoundary\"]\nc:I[7567,[],\"default\",1]\n:HL[\"/_next/static/css/b85889345c486052.css\",\"style\"]\n7:X\n0:{\"P\":null,\"c\":[\"\",\"_not-found\",\"\"],\"q\":\"\",\"i\":false,\"f\":[[[\"\",{\"children\":[\"_not-found\",{\"children\":[\"__PAGE__\",{},\"$undefined\",\"$undefined\",4608]},\"$undefined\",\"$undefined\",4608]},\"$undefined\",\"$undefined\",4624],[[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/css/b85889345c486052.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}]],[\"$\",\"html\",null,{\"lang\":\"en\",\"children\":[\"$\",\"body\",null,{\"children\":[\"$\",\"$L2\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L3\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]}]}]]}],{\"children\":[[\"$\",\"$1\",\"c\",{\"children\":[null,[\"$\",\"$L2\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L3\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}],{\"children\":[[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"},\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"},\"children\":404}],[\"$\",\"div\",null,{\"style\":{\"display\":\"inline-block\"},\"children\":[\"$\",\"h2\",null,{\"style\":{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0},\"children\":\"This page could not be found.\"}]}]]}]}]],null,[\"$\",\"$L4\",null,{\"children\":[\"$\",\"$5\",null,{\"name\":\"Next.MetadataOutlet\",\"children\":\"$@6\"}]}]]}],{},null,false,null]},null,false,\"$7\"]},null,false,null],[\"$\",\"$1\",\"h\",{\"children\":[[\"$\",\"meta\",null,{\"name\":\"robots\",\"content\":\"noindex\"}],[\"$\",\"$L8\",null,{\"children\":\"$L9\"}],[\"$\",\"div\",null,{\"hidden\":true,\"children\":[\"$\",\"$La\",null,{\"children\":[\"$\",\"$5\",null,{\"name\":\"Next.Metadata\",\"children\":\"$Lb\"}]}]}],null]}],false]],\"m\":\"$undefined\",\"G\":[\"$c\",[]],\"S\":true,\"h\":null,\"r\":\"$undefined\",\"s\":\"$undefined\",\"a\":\"$undefined\",\"l\":\"$undefined\",\"p\":\"$undefined\",\"d\":\"$undefined\",\"b\":\"NEP_BMzhg1ixudz9w2f3I\"}\n7:C\n9:[[\"$\",\"meta\",\"0\",{\"charSet\":\"utf-8\"}],[\"$\",\"meta\",\"1\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}]]\nd:I[2569,[],\"IconMark\"]\n6:null\nb:[[\"$\",\"title\",\"0\",{\"children\":\"tether — Visual QA\"}],[\"$\",\"meta\",\"1\",{\"name\":\"description\",\"content\":\"Compare your frontend with its saved visual baseline.\"}],[\"$\",\"link\",\"2\",{\"rel\":\"icon\",\"href\":\"/knot.svg\"}],[\"$\",\"$Ld\",\"3\",{}]]\n"])</script></body></html>
@@ -0,0 +1 @@
1
+ <!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="/_next/static/css/b85889345c486052.css" data-precedence="next"/><link rel="preload" as="script" fetchPriority="low" href="/_next/static/chunks/webpack-21c0bda91597affb.js"/><script src="/_next/static/chunks/c7879cf7-33323d49ba6da96a.js" async=""></script><script src="/_next/static/chunks/158-65f5491737ca4c2e.js" async=""></script><script src="/_next/static/chunks/main-app-91d98c37495a2d56.js" async=""></script><meta name="robots" content="noindex"/><title>tether — Visual QA</title><meta name="description" content="Compare your frontend with its saved visual baseline."/><link rel="icon" href="/knot.svg"/><title>404: This page could not be found.</title><script src="/_next/static/chunks/polyfills-42372ed130431b0a.js" noModule=""></script></head><body><div hidden=""><!--$--><!--/$--></div><div style="font-family:system-ui,&quot;Segoe UI&quot;,Roboto,Helvetica,Arial,sans-serif,&quot;Apple Color Emoji&quot;,&quot;Segoe UI Emoji&quot;;height:100vh;text-align:center;display:flex;flex-direction:column;align-items:center;justify-content:center"><div><style>body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}</style><h1 class="next-error-h1" style="display:inline-block;margin:0 20px 0 0;padding:0 23px 0 0;font-size:24px;font-weight:500;vertical-align:top;line-height:49px">404</h1><div style="display:inline-block"><h2 style="font-size:14px;font-weight:400;line-height:49px;margin:0">This page could not be found.</h2></div></div></div><!--$--><!--/$--><script src="/_next/static/chunks/webpack-21c0bda91597affb.js" id="_R_" async=""></script><script>(self.__next_f=self.__next_f||[]).push([0])</script><script>self.__next_f.push([1,"1:\"$Sreact.fragment\"\n2:I[1133,[],\"\"]\n3:I[4297,[],\"\"]\n4:I[1872,[],\"OutletBoundary\"]\n5:\"$Sreact.suspense\"\n8:I[1872,[],\"ViewportBoundary\"]\na:I[1872,[],\"MetadataBoundary\"]\nc:I[7567,[],\"default\",1]\n:HL[\"/_next/static/css/b85889345c486052.css\",\"style\"]\n7:X\n0:{\"P\":null,\"c\":[\"\",\"_not-found\",\"\"],\"q\":\"\",\"i\":false,\"f\":[[[\"\",{\"children\":[\"_not-found\",{\"children\":[\"__PAGE__\",{},\"$undefined\",\"$undefined\",4608]},\"$undefined\",\"$undefined\",4608]},\"$undefined\",\"$undefined\",4624],[[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/css/b85889345c486052.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}]],[\"$\",\"html\",null,{\"lang\":\"en\",\"children\":[\"$\",\"body\",null,{\"children\":[\"$\",\"$L2\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L3\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]}]}]]}],{\"children\":[[\"$\",\"$1\",\"c\",{\"children\":[null,[\"$\",\"$L2\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L3\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}],{\"children\":[[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"title\",null,{\"children\":\"404: This page could not be found.\"}],[\"$\",\"div\",null,{\"style\":{\"fontFamily\":\"system-ui,\\\"Segoe UI\\\",Roboto,Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\"\",\"height\":\"100vh\",\"textAlign\":\"center\",\"display\":\"flex\",\"flexDirection\":\"column\",\"alignItems\":\"center\",\"justifyContent\":\"center\"},\"children\":[\"$\",\"div\",null,{\"children\":[[\"$\",\"style\",null,{\"dangerouslySetInnerHTML\":{\"__html\":\"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}\"}}],[\"$\",\"h1\",null,{\"className\":\"next-error-h1\",\"style\":{\"display\":\"inline-block\",\"margin\":\"0 20px 0 0\",\"padding\":\"0 23px 0 0\",\"fontSize\":24,\"fontWeight\":500,\"verticalAlign\":\"top\",\"lineHeight\":\"49px\"},\"children\":404}],[\"$\",\"div\",null,{\"style\":{\"display\":\"inline-block\"},\"children\":[\"$\",\"h2\",null,{\"style\":{\"fontSize\":14,\"fontWeight\":400,\"lineHeight\":\"49px\",\"margin\":0},\"children\":\"This page could not be found.\"}]}]]}]}]],null,[\"$\",\"$L4\",null,{\"children\":[\"$\",\"$5\",null,{\"name\":\"Next.MetadataOutlet\",\"children\":\"$@6\"}]}]]}],{},null,false,null]},null,false,\"$7\"]},null,false,null],[\"$\",\"$1\",\"h\",{\"children\":[[\"$\",\"meta\",null,{\"name\":\"robots\",\"content\":\"noindex\"}],[\"$\",\"$L8\",null,{\"children\":\"$L9\"}],[\"$\",\"div\",null,{\"hidden\":true,\"children\":[\"$\",\"$La\",null,{\"children\":[\"$\",\"$5\",null,{\"name\":\"Next.Metadata\",\"children\":\"$Lb\"}]}]}],null]}],false]],\"m\":\"$undefined\",\"G\":[\"$c\",[]],\"S\":true,\"h\":null,\"r\":\"$undefined\",\"s\":\"$undefined\",\"a\":\"$undefined\",\"l\":\"$undefined\",\"p\":\"$undefined\",\"d\":\"$undefined\",\"b\":\"NEP_BMzhg1ixudz9w2f3I\"}\n7:C\n9:[[\"$\",\"meta\",\"0\",{\"charSet\":\"utf-8\"}],[\"$\",\"meta\",\"1\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}]]\nd:I[2569,[],\"IconMark\"]\n6:null\nb:[[\"$\",\"title\",\"0\",{\"children\":\"tether — Visual QA\"}],[\"$\",\"meta\",\"1\",{\"name\":\"description\",\"content\":\"Compare your frontend with its saved visual baseline.\"}],[\"$\",\"link\",\"2\",{\"rel\":\"icon\",\"href\":\"/knot.svg\"}],[\"$\",\"$Ld\",\"3\",{}]]\n"])</script></body></html>
@@ -0,0 +1,20 @@
1
+ 1:"$Sreact.fragment"
2
+ 2:I[1350,["979","static/chunks/979-2cc4e681ca63e0b3.js","100","static/chunks/100-cde31512e90ea4ee.js","974","static/chunks/app/page-ab86e7319bb488c8.js"],"default"]
3
+ 3:I[1872,[],"OutletBoundary"]
4
+ 4:"$Sreact.suspense"
5
+ 8:I[1872,[],"ViewportBoundary"]
6
+ 9:I[1872,[],"MetadataBoundary"]
7
+ a:I[2569,[],"IconMark"]
8
+ c:I[1133,[],""]
9
+ d:I[4297,[],""]
10
+ :HL["/_next/static/css/b85889345c486052.css","style"]
11
+ 7:X
12
+ 0:{"buildId":"NEP_BMzhg1ixudz9w2f3I","data":[{"rsc":["$","$1","c",{"children":[["$","$L2",null,{"page":"overview"}],null,["$","$L3",null,{"children":["$","$4",null,{"name":"Next.MetadataOutlet","children":"$@5"}]}]]}],"isPartial":"$@6","staleTime":"$7","varyParams":null},{"rsc":["$","$1","h",{"children":[null,["$","$L8",null,{"children":[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]]}],["$","div",null,{"hidden":true,"children":["$","$L9",null,{"children":["$","$4",null,{"name":"Next.Metadata","children":[["$","title","0",{"children":"tether — Visual QA"}],["$","meta","1",{"name":"description","content":"Compare your frontend with its saved visual baseline."}],["$","link","2",{"rel":"icon","href":"/knot.svg"}],["$","$La","3",{}]]}]}]}],null]}],"isPartial":"$@b","staleTime":"$7","varyParams":null},{"rsc":["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/b85889345c486052.css","precedence":"next"}]],["$","html",null,{"lang":"en","children":["$","body",null,{"children":["$","$Lc",null,{"parallelRouterKey":"children","template":["$","$Ld",null,{}],"notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]]}]}]}]]}],"isPartial":"$@e","staleTime":"$7","varyParams":null}],"isUpgradeableISRFallback":false,"a":"$@f","rootVaryParams":null,"needsRuntimeRequest":"$@10"}
13
+ 5:null
14
+ 7:300
15
+ 10:true
16
+ 7:C
17
+ f:0
18
+ b:"$undefined"
19
+ e:"$undefined"
20
+ 6:"$undefined"
@@ -0,0 +1,15 @@
1
+ 1:"$Sreact.fragment"
2
+ 2:I[1133,[],""]
3
+ 3:I[4297,[],""]
4
+ 4:I[1350,["979","static/chunks/979-2cc4e681ca63e0b3.js","100","static/chunks/100-cde31512e90ea4ee.js","974","static/chunks/app/page-ab86e7319bb488c8.js"],"default"]
5
+ 5:I[1872,[],"OutletBoundary"]
6
+ 6:"$Sreact.suspense"
7
+ 8:I[1872,[],"ViewportBoundary"]
8
+ a:I[1872,[],"MetadataBoundary"]
9
+ c:I[7567,[],"default",1]
10
+ :HL["/_next/static/css/b85889345c486052.css","style"]
11
+ 0:{"P":null,"c":["",""],"q":"","i":false,"f":[[["",{"children":["__PAGE__",{},"$undefined","$undefined",4608]},"$undefined","$undefined",4624],[["$","$1","c",{"children":[[["$","link","0",{"rel":"stylesheet","href":"/_next/static/css/b85889345c486052.css","precedence":"next","crossOrigin":"$undefined","nonce":"$undefined"}]],["$","html",null,{"lang":"en","children":["$","body",null,{"children":["$","$L2",null,{"parallelRouterKey":"children","error":"$undefined","errorStyles":"$undefined","errorScripts":"$undefined","template":["$","$L3",null,{}],"templateStyles":"$undefined","templateScripts":"$undefined","notFound":[[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"","height":"100vh","textAlign":"center","display":"flex","flexDirection":"column","alignItems":"center","justifyContent":"center"},"children":["$","div",null,{"children":[["$","style",null,{"dangerouslySetInnerHTML":{"__html":"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}],["$","h1",null,{"className":"next-error-h1","style":{"display":"inline-block","margin":"0 20px 0 0","padding":"0 23px 0 0","fontSize":24,"fontWeight":500,"verticalAlign":"top","lineHeight":"49px"},"children":404}],["$","div",null,{"style":{"display":"inline-block"},"children":["$","h2",null,{"style":{"fontSize":14,"fontWeight":400,"lineHeight":"49px","margin":0},"children":"This page could not be found."}]}]]}]}]],[]],"forbidden":"$undefined","unauthorized":"$undefined"}]}]}]]}],{"children":[["$","$1","c",{"children":[["$","$L4",null,{"page":"overview"}],null,["$","$L5",null,{"children":["$","$6",null,{"name":"Next.MetadataOutlet","children":"$@7"}]}]]}],{},null,false,null]},null,false,null],["$","$1","h",{"children":[null,["$","$L8",null,{"children":"$L9"}],["$","div",null,{"hidden":true,"children":["$","$La",null,{"children":["$","$6",null,{"name":"Next.Metadata","children":"$Lb"}]}]}],null]}],false]],"m":"$undefined","G":["$c",[]],"S":true,"h":null,"r":"$undefined","s":"$undefined","a":"$undefined","l":"$undefined","p":"$undefined","d":"$undefined","b":"NEP_BMzhg1ixudz9w2f3I"}
12
+ 9:[["$","meta","0",{"charSet":"utf-8"}],["$","meta","1",{"name":"viewport","content":"width=device-width, initial-scale=1"}]]
13
+ d:I[2569,[],"IconMark"]
14
+ 7:null
15
+ b:[["$","title","0",{"children":"tether — Visual QA"}],["$","meta","1",{"name":"description","content":"Compare your frontend with its saved visual baseline."}],["$","link","2",{"rel":"icon","href":"/knot.svg"}],["$","$Ld","3",{}]]
@@ -0,0 +1,2 @@
1
+ :HL["/_next/static/css/b85889345c486052.css","style"]
2
+ 0:{"tree":{"name":"","param":null,"prefetchHints":4176,"slots":{"children":{"name":"__PAGE__","param":null,"prefetchHints":4256,"slots":null}}},"staleTime":300,"buildId":"NEP_BMzhg1ixudz9w2f3I"}
@@ -0,0 +1 @@
1
+ self.__BUILD_MANIFEST={__rewrites:{afterFiles:[],beforeFiles:[],fallback:[]},__routerFilterStatic:{numItems:6,errorRate:1e-4,numBits:116,numHashes:14,bitArray:[1,0,0,0,1,0,1,1,0,0,0,1,1,0,0,1,0,1,0,0,0,0,1,0,0,0,1,1,1,0,1,0,1,0,1,1,1,0,1,1,0,0,1,1,1,1,0,0,1,1,0,0,0,1,0,0,0,1,0,1,1,1,1,1,0,0,1,1,0,1,0,1,0,0,0,0,1,0,0,0,1,0,1,1,1,0,1,1,0,1,0,1,1,1,0,1,1,0,1,1,1,0,1,1,1,1,1,1,0,0,1,0,0,0,1,0]},__routerFilterDynamic:{numItems:0,errorRate:1e-4,numBits:0,numHashes:null,bitArray:[]},sortedPages:["/_app"]},self.__BUILD_MANIFEST_CB&&self.__BUILD_MANIFEST_CB();
@@ -0,0 +1 @@
1
+ self.__SSG_MANIFEST=new Set([]);self.__SSG_MANIFEST_CB&&self.__SSG_MANIFEST_CB()
@@ -0,0 +1 @@
1
+ (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[100],{100:(s,e,a)=>{Promise.resolve().then(a.bind(a,1350))},1350:(s,e,a)=>{"use strict";a.d(e,{default:()=>R});var i=a(3365),n=a(1521),l=a(9568),c=a.n(l),r=a(9376),t=a(21),d=a(4639),o=a(2665),h=a(8768),x=a(3960),j=a(634),m=a(4582),p=a(7494),v=a(8232),u=a(1613),g=a(6687),N=a(6504),w=a(1838),y=a(2293),f=a(3382);let b={overview:"Overview",drift:"Visual drift",contract:"Visual contract",viewports:"Viewports"},k={colors:"Color",fontFamilies:"Typography",fontSizes:"Typography",fontWeights:"Typography",lineHeights:"Typography",spacing:"Spacing",radii:"Radius",shadows:"Shadow",borders:"Border",elementHeights:"Height",layout:"Layout"},S=["All","Color","Typography","Spacing","Radius","Layout","Shadow","Border","Height"];function A(s){return new Date(s).toLocaleString("en-US",{month:"short",day:"numeric",hour:"2-digit",minute:"2-digit"})}function z({children:s}){return(0,i.jsx)("span",{className:"count",children:s})}function C({severity:s}){return(0,i.jsxs)("span",{className:`severity ${s}`,children:[(0,i.jsx)("i",{}),s]})}function E(){return(0,i.jsx)("p",{className:"muted",children:"No recurring values in this category."})}function T({issue:s}){return(0,i.jsxs)("article",{className:"issue-card",children:[(0,i.jsxs)("div",{className:"issue-heading",children:[(0,i.jsx)("span",{className:"category",children:k[s.category]}),(0,i.jsx)(C,{severity:s.severity})]}),(0,i.jsx)("h3",{children:s.title}),(0,i.jsxs)("div",{className:"comparison",children:[(0,i.jsxs)("div",{children:[(0,i.jsx)("span",{className:"micro",children:"CURRENT"}),(0,i.jsxs)("code",{className:"current",children:["colors"===s.category&&(0,i.jsx)("i",{className:"tiny-swatch",style:{background:s.current}}),s.current]})]}),(0,i.jsx)(r.A,{size:15,className:"muted"}),(0,i.jsxs)("div",{children:[(0,i.jsx)("span",{className:"micro",children:"EXPECTED"}),(0,i.jsx)("p",{className:"expected",children:s.expected.join(" \xb7 ")||"Review baseline"})]})]}),(0,i.jsxs)("div",{className:"issue-meta",children:[(0,i.jsx)("code",{children:s.selector}),(0,i.jsxs)("span",{children:[s.route," ",(0,i.jsx)("span",{className:"dot",children:"\xb7"})," ",s.viewports.join(", ")]})]}),(0,i.jsxs)("details",{children:[(0,i.jsx)("summary",{children:"Inspect property"}),(0,i.jsx)("code",{children:s.property})]})]})}function R({page:s}){let[e,a]=(0,n.useState)(null),[l,C]=(0,n.useState)(""),[E,L]=(0,n.useState)("All"),[H,$]=(0,n.useState)("all"),[D,M]=(0,n.useState)(!1),[V,B]=(0,n.useState)(!1),[I,P]=(0,n.useState)(null);async function _(){if(e)try{await navigator.clipboard.writeText(e.agentMarkdown),M(!0),B(!1),setTimeout(()=>M(!1),2200)}catch{B(!0)}}(0,n.useEffect)(()=>{fetch("/report.json",{cache:"no-store"}).then(s=>{if(!s.ok)throw Error("No scan data found. Run tether check, then reopen tether report.");return s.json()}).then(a).catch(s=>C(s.message))},[]),(0,n.useEffect)(()=>{if(!I)return;let s=s=>{"Escape"===s.key&&P(null)};return document.addEventListener("keydown",s),()=>document.removeEventListener("keydown",s)},[I]);let O=[{key:"overview",href:"/",icon:t.A},{key:"drift",href:"/drift/",icon:d.A},{key:"contract",href:"/contract/",icon:o.A},{key:"viewports",href:"/viewports/",icon:h.A}],U=new Set,W=(e?.issues??[]).filter(s=>{let e=k[s.category];return!U.has(e)&&(U.add(e),!0)}).slice(0,4),q=e?.issues.filter(s=>("All"===E||k[s.category]===E)&&("all"===H||s.severity===H))??[];return(0,i.jsxs)("div",{className:"shell",children:[(0,i.jsx)("a",{href:"#main",className:"skip",children:"Skip to report"}),(0,i.jsxs)("aside",{className:"sidebar",children:[(0,i.jsxs)(c(),{href:"/",className:"brand",children:[(0,i.jsx)("img",{className:"brand-symbol",src:"/knot.svg",alt:"",width:34,height:34}),"tether",(0,i.jsx)("span",{className:"version",children:"0.1"})]}),(0,i.jsxs)("div",{className:"workspace",children:[(0,i.jsx)("div",{className:"workspace-icon",children:(0,i.jsx)(x.A,{size:18})}),(0,i.jsxs)("div",{children:[(0,i.jsx)("strong",{children:"Local workspace"}),(0,i.jsx)("small",{children:"Latest scan"})]}),(0,i.jsx)("span",{className:"connection",title:"Local report"})]}),(0,i.jsx)("nav",{"aria-label":"Report navigation",children:O.map(({key:a,href:n,icon:l})=>(0,i.jsxs)(c(),{href:n,className:s===a?"active":"","aria-current":s===a?"page":void 0,children:[(0,i.jsx)(l,{size:17}),"drift"===a?"Drift":b[a],"drift"===a&&!!e?.issues.length&&(0,i.jsx)(z,{children:e.issues.length})]},a))}),(0,i.jsx)("div",{className:"sidebar-bottom",children:(0,i.jsxs)("div",{className:"local-note",children:[(0,i.jsx)(j.A,{size:16}),(0,i.jsx)("span",{children:"Data stays on this device"})]})})]}),(0,i.jsxs)("div",{className:"main-shell",children:[(0,i.jsxs)("header",{className:"topbar",children:[(0,i.jsxs)("div",{children:["tether ",(0,i.jsx)(m.A,{size:13}),(0,i.jsx)("b",{children:b[s]})]}),(0,i.jsxs)("span",{className:"local-pill",children:[(0,i.jsx)("i",{})," Local report"]})]}),(0,i.jsxs)("main",{id:"main",children:[(0,i.jsxs)("div",{className:"page-heading",children:[(0,i.jsxs)("div",{children:[(0,i.jsx)("h1",{children:b[s]}),(0,i.jsx)("p",{children:"overview"===s?"Changes since your baseline scan.":"drift"===s?"Review changes by category and severity.":"contract"===s?"Saved colors, typography, spacing, and other styles.":"Screenshots and layout issues at each screen size."})]}),(0,i.jsxs)("button",{className:"button",onClick:_,disabled:!e,children:[D?(0,i.jsx)(p.A,{size:15}):(0,i.jsx)(v.A,{size:15}),D?"Copied to clipboard":"Copy agent brief"]})]}),V&&(0,i.jsxs)("p",{role:"status",className:"notice",children:["Clipboard unavailable."," ",(0,i.jsx)("a",{href:"data:text/markdown;charset=utf-8,"+encodeURIComponent(e?.agentMarkdown??""),download:"tether-agent.md",children:"Download the agent brief"}),"."]}),l&&(0,i.jsxs)("div",{role:"alert",className:"empty",children:[(0,i.jsx)(u.A,{}),(0,i.jsx)("h2",{children:"No scan yet"}),(0,i.jsx)("p",{children:l}),(0,i.jsx)("code",{children:"tether init && tether check"})]}),!l&&!e&&(0,i.jsx)("div",{className:"empty",role:"status",children:"Loading scan…"}),e&&(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)("div",{className:"scan-strip",children:[(0,i.jsxs)("span",{className:"scan-state",children:[(0,i.jsx)(g.A,{size:15})," Scan complete"]}),(0,i.jsx)("code",{children:e.scan.url}),(0,i.jsx)("span",{className:"scan-time",children:A(e.scan.createdAt)}),(0,i.jsxs)("span",{className:"snapshot-label",children:[e.scan.snapshots.length," snapshots"]})]}),e.scan.snapshots.some(s=>s.truncated)&&(0,i.jsx)("p",{className:"notice",children:"Partial coverage: an element limit was reached. Increase maxElements and scan again."}),"overview"===s&&(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)("section",{className:"stats-grid",children:[(0,i.jsxs)("div",{className:"score-stat",children:[(0,i.jsxs)("div",{className:"stat-label",children:["Visual consistency"," ",(0,i.jsx)("span",{title:"Heuristic: 100 minus 8 per high, 4 per medium, and 2 per low deviation.",children:"ⓘ"})]}),(0,i.jsxs)("div",{className:"score-number",children:[e.score,(0,i.jsx)("span",{children:"/ 100"})]}),(0,i.jsx)("div",{className:"score-track",children:(0,i.jsx)("span",{style:{width:`${e.score}%`}})}),(0,i.jsxs)("small",{children:["Heuristic score \xb7"," ",e.issues.length?"Changes detected":"No changes detected"]})]}),(0,i.jsxs)("div",{className:"stat",children:[(0,i.jsx)("span",{className:"stat-label",children:"Deviations"}),(0,i.jsx)("strong",{children:e.issues.length.toString().padStart(2,"0")}),(0,i.jsxs)("small",{children:[(0,i.jsx)("span",{className:"warning-dot"}),e.issues.filter(s=>"high"===s.severity).length," ","high priority"]})]}),(0,i.jsxs)("div",{className:"stat",children:[(0,i.jsx)("span",{className:"stat-label",children:"Elements inspected"}),(0,i.jsx)("strong",{children:e.elementCount}),(0,i.jsx)("small",{children:"Across all snapshots"})]}),(0,i.jsxs)("div",{className:"stat",children:[(0,i.jsx)("span",{className:"stat-label",children:"Routes covered"}),(0,i.jsx)("strong",{children:new Set(e.scan.snapshots.map(s=>s.route)).size.toString().padStart(2,"0")}),(0,i.jsxs)("small",{children:[new Set(e.scan.snapshots.map(s=>s.viewport.name)).size," ","viewport sizes"]})]})]}),(0,i.jsxs)("div",{className:"overview-columns",children:[(0,i.jsxs)("section",{children:[(0,i.jsxs)("div",{className:"section-heading",children:[(0,i.jsxs)("h2",{children:["Visual drift ",(0,i.jsx)(z,{children:e.issues.length})]}),(0,i.jsxs)(c(),{href:"/drift/",children:["View all deviations ",(0,i.jsx)(N.A,{size:14})]})]}),(0,i.jsx)("p",{className:"section-description",children:"One finding from each affected category."}),(0,i.jsxs)("div",{className:"issue-list",children:[W.map(s=>(0,i.jsx)(T,{issue:s},s.id)),!e.issues.length&&(0,i.jsxs)("div",{className:"empty",children:[(0,i.jsx)(g.A,{}),(0,i.jsx)("h3",{children:"No drift detected"}),(0,i.jsx)("p",{children:"The scan matches your visual contract."})]})]})]}),(0,i.jsxs)("aside",{className:"overview-aside",children:[(0,i.jsxs)("div",{className:"contract-summary",children:[(0,i.jsx)("div",{className:"small-icon",children:(0,i.jsx)(o.A,{size:22})}),(0,i.jsx)("h3",{children:"Baseline styles"}),(0,i.jsx)("p",{children:"Styles saved from your baseline scan."}),(0,i.jsx)("div",{className:"palette-strip",children:e.contract.colors.slice(0,7).map(s=>(0,i.jsx)("span",{style:{background:s.value},title:s.value},s.value))}),(0,i.jsxs)("div",{className:"summary-pairs",children:[(0,i.jsx)("span",{children:"Color palette"}),(0,i.jsxs)("b",{children:[e.contract.colors.length," colors"]}),(0,i.jsx)("span",{children:"Type scale"}),(0,i.jsxs)("b",{children:[e.contract.fontSizes.length," sizes"]}),(0,i.jsx)("span",{children:"Spacing scale"}),(0,i.jsxs)("b",{children:[e.contract.spacing.length," values"]})]}),(0,i.jsxs)(c(),{className:"text-link",href:"/contract/",children:["View contract ",(0,i.jsx)(r.A,{size:15})]})]}),(0,i.jsxs)("div",{className:"viewport-summary",children:[(0,i.jsxs)("div",{className:"section-heading",children:[(0,i.jsx)("h3",{children:"Responsive checks"}),(0,i.jsx)(h.A,{size:16})]}),Array.from(new Map(e.scan.snapshots.map(s=>[s.viewport.name,s.viewport])).values()).map(s=>{let a=e.issues.filter(e=>"layout"===e.category&&e.viewports.includes(s.name)).length;return(0,i.jsxs)("div",{className:"viewport-line",children:[(0,i.jsxs)("span",{children:[s.name," ",(0,i.jsxs)("small",{children:[s.width,"px"]})]}),a?(0,i.jsxs)("span",{className:"layout-warning",children:[a," layout issues"]}):(0,i.jsx)(p.A,{size:15,className:"green"})]},s.name)}),(0,i.jsxs)(c(),{href:"/viewports/",className:"text-link",children:["Inspect screenshots ",(0,i.jsx)(r.A,{size:15})]})]}),(0,i.jsxs)("div",{className:"baseline-note",children:[(0,i.jsx)(j.A,{size:15}),(0,i.jsxs)("span",{children:["Baseline created ",A(e.baselineAt),(0,i.jsx)("br",{}),"Stored locally in ",(0,i.jsx)("code",{children:".tether/"})]})]})]})]})]}),"drift"===s&&(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)("div",{className:"filter-toolbar",children:[(0,i.jsx)("div",{className:"filters","aria-label":"Filter by category",children:S.map(s=>(0,i.jsx)("button",{onClick:()=>L(s),"aria-pressed":E===s,className:E===s?"selected":"",children:s},s))}),(0,i.jsxs)("label",{className:"severity-select",children:[(0,i.jsx)("span",{className:"sr-only",children:"Severity"}),(0,i.jsxs)("select",{value:H,onChange:s=>$(s.target.value),children:[(0,i.jsx)("option",{value:"all",children:"All severities"}),(0,i.jsx)("option",{value:"high",children:"High severity"}),(0,i.jsx)("option",{value:"medium",children:"Medium severity"}),(0,i.jsx)("option",{value:"low",children:"Low severity"})]})]})]}),(0,i.jsxs)("div",{className:"results-line",children:[q.length," ",1===q.length?"deviation":"deviations",(0,i.jsx)("span",{children:"Sorted by severity"})]}),(0,i.jsx)("div",{className:"drift-grid",children:q.map(s=>(0,i.jsx)(T,{issue:s},s.id))}),!q.length&&(0,i.jsxs)("div",{className:"empty",children:[(0,i.jsx)(g.A,{}),(0,i.jsx)("h2",{children:"No matching deviations"}),(0,i.jsx)("p",{children:"No deviations match these filters."})]})]}),"contract"===s&&(0,i.jsx)(F,{report:e}),"viewports"===s&&(0,i.jsx)(i.Fragment,{children:(0,i.jsx)("div",{className:"viewport-grid",children:e.scan.snapshots.map(s=>{let a=e.issues.filter(e=>e.route===s.route&&e.viewports.includes(s.viewport.name)),n=a.filter(s=>"layout"===s.category);return(0,i.jsxs)("article",{className:"viewport-card",children:[(0,i.jsxs)("div",{className:"viewport-card-heading",children:[s.viewport.width<500?(0,i.jsx)(w.A,{size:18}):(0,i.jsx)(h.A,{size:18}),(0,i.jsx)("h3",{children:s.viewport.name}),(0,i.jsxs)("span",{children:[s.viewport.width," \xd7 ",s.viewport.height]})]}),(0,i.jsx)("button",{className:"screenshot-button",onClick:()=>P("/"+s.screenshot),"aria-label":`Enlarge ${s.viewport.name} screenshot for ${s.route}`,children:(0,i.jsx)("img",{src:"/"+s.screenshot,alt:`${s.route} at ${s.viewport.width} pixels`})}),(0,i.jsxs)("div",{className:"viewport-caption",children:[(0,i.jsx)("code",{children:s.route}),(0,i.jsxs)("span",{children:[a.length," deviations"]})]}),(0,i.jsxs)("div",{className:n.length?"viewport-status warning":"viewport-status",children:[n.length?(0,i.jsx)(u.A,{size:14}):(0,i.jsx)(g.A,{size:14}),n.length?n.map(s=>s.title).join(" \xb7 "):"Content fits the viewport"]}),(0,i.jsxs)("a",{href:"/"+s.screenshot,download:!0,className:"download-shot",children:[(0,i.jsx)(y.A,{size:13}),"Download capture"]})]},`${s.route}-${s.viewport.name}`)})})})]})]})]}),I&&(0,i.jsxs)("div",{className:"preview",role:"dialog","aria-modal":"true","aria-label":"Screenshot preview",onClick:()=>P(null),children:[(0,i.jsx)("button",{autoFocus:!0,onClick:()=>P(null),"aria-label":"Close preview",children:(0,i.jsx)(f.A,{size:22})}),(0,i.jsx)("img",{src:I,alt:"Full viewport capture",onClick:s=>s.stopPropagation()})]})]})}function F({report:s}){let e=s.contract,a=s=>[...s].sort((s,e)=>parseFloat(s.value)-parseFloat(e.value));return(0,i.jsxs)("div",{className:"contract-content",children:[(0,i.jsxs)("div",{className:"contract-banner",children:[(0,i.jsx)(o.A,{size:20}),(0,i.jsxs)("div",{children:[(0,i.jsx)("b",{children:"Saved tokens"}),(0,i.jsxs)("span",{children:["Recurring values \xb7 target of ",e.minOccurrences,"+ distinct elements per token"]})]}),(0,i.jsxs)("span",{className:"contract-date",children:["Baseline \xb7 ",A(s.baselineAt)]})]}),(0,i.jsxs)("section",{className:"token-section",children:[(0,i.jsxs)("div",{className:"section-heading",children:[(0,i.jsxs)("h2",{children:["01 ",(0,i.jsx)("span",{children:"Color palette"})]}),(0,i.jsxs)(z,{children:[e.colors.length," tokens"]})]}),(0,i.jsxs)("div",{className:"color-grid",children:[e.colors.map(s=>(0,i.jsxs)("div",{className:"color-token",children:[(0,i.jsx)("div",{className:"swatch",style:{background:s.value}}),(0,i.jsxs)("div",{children:[(0,i.jsx)("code",{children:s.value}),(0,i.jsxs)("small",{children:[s.count," elements"]})]})]},s.value)),!e.colors.length&&(0,i.jsx)(E,{})]})]}),(0,i.jsxs)("div",{className:"contract-two-columns",children:[(0,i.jsxs)("section",{className:"token-section",children:[(0,i.jsxs)("div",{className:"section-heading",children:[(0,i.jsxs)("h2",{children:["02 ",(0,i.jsx)("span",{children:"Typography"})]}),(0,i.jsxs)(z,{children:[e.fontSizes.length," sizes"]})]}),(0,i.jsxs)("div",{className:"type-info",children:[(0,i.jsx)("span",{children:e.fontFamilies.map(s=>s.value).join(" \xb7 ")}),(0,i.jsx)("code",{children:e.fontWeights.map(s=>s.value).join(" / ")})]}),(0,i.jsxs)("div",{className:"type-scale",children:[a(e.fontSizes).reverse().map(s=>(0,i.jsxs)("div",{children:[(0,i.jsx)("code",{children:s.value}),(0,i.jsx)("span",{style:{fontSize:s.value},children:"The quick brown fox"}),(0,i.jsxs)("small",{children:["\xd7",s.count]})]},s.value)),!e.fontSizes.length&&(0,i.jsx)(E,{})]}),(0,i.jsxs)("p",{className:"token-footnote",children:["Line heights:"," ",e.lineHeights.map(s=>s.value).join(" \xb7 ")||"Browser default"]})]}),(0,i.jsxs)("section",{className:"token-section",children:[(0,i.jsxs)("div",{className:"section-heading",children:[(0,i.jsxs)("h2",{children:["03 ",(0,i.jsx)("span",{children:"Spacing"})]}),(0,i.jsxs)(z,{children:[e.spacing.length," steps"]})]}),(0,i.jsx)("p",{className:"token-caption",children:"Margins, padding, and gaps."}),(0,i.jsxs)("div",{className:"spacing-scale",children:[a(e.spacing).map(s=>(0,i.jsxs)("div",{children:[(0,i.jsx)("code",{children:s.value}),(0,i.jsx)("div",{className:"spacing-track",children:(0,i.jsx)("span",{style:{width:`${Math.min(4*Math.abs(parseFloat(s.value)),260)}px`}})}),(0,i.jsxs)("small",{children:["\xd7",s.count]})]},s.value)),!e.spacing.length&&(0,i.jsx)(E,{})]})]})]}),(0,i.jsxs)("div",{className:"contract-two-columns",children:[(0,i.jsxs)("section",{className:"token-section",children:[(0,i.jsxs)("div",{className:"section-heading",children:[(0,i.jsxs)("h2",{children:["04 ",(0,i.jsx)("span",{children:"Corner radii"})]}),(0,i.jsxs)(z,{children:[e.radii.length," tokens"]})]}),(0,i.jsxs)("div",{className:"radius-grid",children:[a(e.radii).map(s=>(0,i.jsxs)("div",{children:[(0,i.jsx)("div",{className:"radius-example",style:{borderRadius:s.value}}),(0,i.jsx)("code",{children:s.value}),(0,i.jsxs)("small",{children:[s.count," elements"]})]},s.value)),!e.radii.length&&(0,i.jsx)(E,{})]})]}),(0,i.jsxs)("section",{className:"token-section",children:[(0,i.jsx)("div",{className:"section-heading",children:(0,i.jsxs)("h2",{children:["05 ",(0,i.jsx)("span",{children:"Shadows & borders"})]})}),(0,i.jsxs)("div",{className:"shadow-grid",children:[e.shadows.map(s=>(0,i.jsxs)("div",{children:[(0,i.jsx)("div",{className:"shadow-example",style:{boxShadow:s.value},children:"Aa"}),(0,i.jsx)("code",{children:s.value})]},s.value)),!e.shadows.length&&(0,i.jsx)(E,{})]}),(0,i.jsx)("div",{className:"border-list",children:e.borders.map(s=>(0,i.jsxs)("div",{children:[(0,i.jsx)("span",{style:{borderTop:s.value}}),(0,i.jsx)("code",{children:s.value}),(0,i.jsxs)("small",{children:["\xd7",s.count]})]},s.value))})]})]}),(0,i.jsxs)("section",{className:"token-section control-section",children:[(0,i.jsx)("div",{className:"section-heading",children:(0,i.jsxs)("h2",{children:["06 ",(0,i.jsx)("span",{children:"Control heights"})]})}),(0,i.jsxs)("div",{children:[a(e.elementHeights).map(s=>(0,i.jsxs)("span",{className:"control-token",children:[(0,i.jsx)("code",{children:s.value}),(0,i.jsxs)("small",{children:[s.count," controls"]})]},s.value)),!e.elementHeights.length&&(0,i.jsx)(E,{})]})]})]})}}}]);