Beautiful, AI-native markdown IDE and LLM wiki
TypeScript 2nd-brainagent-skillsclaudecodexcompany-braindocsknowledge-knowledge-baseknowledge-managementllmllm-wikillm-wiki-karpathymarkdownmarkdown-editormdmdxnotespkmsecond-brainskills
Polish the share splash page (/d/[encoded]) (#2066)
sarahca3b9b22254e
diff --git a/bun.lock b/bun.lockindex 28acfb0c0..995287f98 100644--- a/bun.lock+++ b/bun.lock@@ -22,6 +22,7 @@"version": "0.0.1","dependencies": {"@inkeep/cxkit-react": "^0.5.117",+ "@radix-ui/react-popover": "^1.1.17","@types/mdx": "^2.0.13","clsx": "^2.1.1","fumadocs-core": "~16.1.0",@@ -1353,7 +1354,7 @@"@radix-ui/react-password-toggle-field": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/primitive": "1.1.3", "@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/react-context": "1.1.2", "@radix-ui/react-id": "1.1.1", "@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-use-controllable-state": "1.2.2", "@radix-ui/react-use-effect-event": "0.0.2", "@radix-ui/react-use-is-hydrated": "0.1.0" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react", "@types/react-dom"] }, "sha512-/UuCrDBWravcaMix4TdT+qlNdVwOM1Nck9kWx/vafXsdfj1ChfhOdfi3cy9SGBpWgTXwYCuboT/oYpJy3clqfw=="],- "@radix-ui/react-popover": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/primitive": "1.1.3", "@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/react-context": "1.1.2", "@radix-ui/react-dismissable-layer": "1.1.11", "@radix-ui/react-focus-guards": "1.1.3", "@radix-ui/react-focus-scope": "1.1.7", "@radix-ui/react-id": "1.1.1", "@radix-ui/react-popper": "1.2.8", "@radix-ui/react-portal": "1.1.9", "@radix-ui/react-presence": "1.1.5", "@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-slot": "1.2.3", "@radix-ui/react-use-controllable-state": "1.2.2", "aria-hidden": "^1.2.4", "react-remove-scroll": "^2.6.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react", "@types/react-dom"] }, "sha512-kr0X2+6Yy/vJzLYJUPCZEc8SfQcf+1COFoAqauJm74umQhta9M7lNJHP7QQS3vkvcGLQUbWpMzwrXYwrYztHKA=="],+ "@radix-ui/react-popover": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/primitive": "1.1.4", "@radix-ui/react-compose-refs": "1.1.3", "@radix-ui/react-context": "1.1.4", "@radix-ui/react-dismissable-layer": "1.1.13", "@radix-ui/react-focus-guards": "1.1.4", "@radix-ui/react-focus-scope": "1.1.10", "@radix-ui/react-id": "1.1.2", "@radix-ui/react-popper": "1.3.1", "@radix-ui/react-portal": "1.1.12", "@radix-ui/react-presence": "1.1.6", "@radix-ui/react-primitive": "2.1.6", "@radix-ui/react-slot": "1.3.0", "@radix-ui/react-use-controllable-state": "1.2.3", "aria-hidden": "^1.2.4", "react-remove-scroll": "^2.7.2" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react", "@types/react-dom"] }, "sha512-/YSAOdJ7YJvdn7bn5sdSx2egW+SKY+u7O5RyAVs94Ymrg2fg5QTSFPMRkzvhGyFuE4/qsmPBdrwYoZMZh/4f+g=="],"@radix-ui/react-popper": ["@radix-ui/[email protected]", "", { "dependencies": { "@floating-ui/react-dom": "^2.0.0", "@radix-ui/react-arrow": "1.1.7", "@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/react-context": "1.1.2", "@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-use-callback-ref": "1.1.1", "@radix-ui/react-use-layout-effect": "1.1.1", "@radix-ui/react-use-rect": "1.1.1", "@radix-ui/react-use-size": "1.1.1", "@radix-ui/rect": "1.1.1" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react", "@types/react-dom"] }, "sha512-0NJQ4LFFUuWkE7Oxf0htBKS6zLkkjBH+hM1uk7Ng705ReR8m/uelduy1DBo0PyBXPKVnBA6YBlU94MBGXrSBCw=="],@@ -4351,6 +4352,32 @@"@quansync/fs/quansync": ["[email protected]", "", {}, "sha512-5xZacEEufv3HSTPQuchrvV6soaiACMFnq1H8wkVioctoH3TRha9Sz66lOxRwPK/qZj7HPiSveih9yAyh98gvqA=="],+ "@radix-ui/react-popover/@radix-ui/primitive": ["@radix-ui/[email protected]", "", {}, "sha512-7AdCK9PQyiljKoBDbN8OuctCbd/esdwZPQ8RtOE3SsyQtUpiPb+ND75q0jEhC1m1ecBI0MFNeLJvwIh9iKHRcQ=="],++ "@radix-ui/react-popover/@radix-ui/react-compose-refs": ["@radix-ui/[email protected]", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-rYOP8OMnuuPMQF1uhPVlGNcCDlkokKqGFE3JcxFViIkAXP7EvFWUliJAstrapypaBLJNHbZL6jGhbVDGTwmVhA=="],++ "@radix-ui/react-popover/@radix-ui/react-context": ["@radix-ui/[email protected]", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-QwH4PO5urrbO+FaGd5Aglg+YJgWTyyuZ3g/6mKvsqraLkglDdckw9JafgL5McL5VEJ6EPNduPaT3ZE9BttDAqg=="],++ "@radix-ui/react-popover/@radix-ui/react-dismissable-layer": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/primitive": "1.1.4", "@radix-ui/react-compose-refs": "1.1.3", "@radix-ui/react-primitive": "2.1.6", "@radix-ui/react-use-callback-ref": "1.1.2", "@radix-ui/react-use-escape-keydown": "1.1.2" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react", "@types/react-dom"] }, "sha512-2v+zNAWWe0ySxgC0D0yeXMPQ23xZVgXZTerTz+JKlmdRj6gfTqmCcR29jb6d290DezXPGgruHWDX/vYUebtErg=="],++ "@radix-ui/react-popover/@radix-ui/react-focus-guards": ["@radix-ui/[email protected]", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-cot/aB/mOm0IYVYTTmQcEEK1M48lZWi8FlYe5nDPQQ8NYZUlXEFgncJ9p2Kzer3RKSrY7cTTpEMLZKNo9QoP5Q=="],++ "@radix-ui/react-popover/@radix-ui/react-focus-scope": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.3", "@radix-ui/react-primitive": "2.1.6", "@radix-ui/react-use-callback-ref": "1.1.2" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react", "@types/react-dom"] }, "sha512-Fas/lXQqhVvqwAb64s5RFeHiHYElZ6SUQbZaNd6EkfhP/Al7wTIQ9WIR4QVX475tlu5yFCEdDcJH6/UwsZjMWw=="],++ "@radix-ui/react-popover/@radix-ui/react-id": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/react-use-layout-effect": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-orBC88futVpqCmhX1p4cvquNHsELQ+w+vBJnuj3ftETI5bJb0bZn3Tqu3SWN2IOcPycTnMGnhwoermvISt72sA=="],++ "@radix-ui/react-popover/@radix-ui/react-popper": ["@radix-ui/[email protected]", "", { "dependencies": { "@floating-ui/react-dom": "^2.0.0", "@radix-ui/react-arrow": "1.1.10", "@radix-ui/react-compose-refs": "1.1.3", "@radix-ui/react-context": "1.1.4", "@radix-ui/react-primitive": "2.1.6", "@radix-ui/react-use-callback-ref": "1.1.2", "@radix-ui/react-use-layout-effect": "1.1.2", "@radix-ui/react-use-rect": "1.1.2", "@radix-ui/react-use-size": "1.1.2", "@radix-ui/rect": "1.1.2" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react", "@types/react-dom"] }, "sha512-bhnq/0DEPTi2lsOD3J5rTL65qUKHbKbhqHsmN9TMiclSXpipi651ooUKPPp6G5lF/WiHBdn1s0Wuqsn+myVAvw=="],++ "@radix-ui/react-popover/@radix-ui/react-portal": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/react-primitive": "2.1.6", "@radix-ui/react-use-layout-effect": "1.1.2" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react", "@types/react-dom"] }, "sha512-m309havGzsjLHHaIX50G5PlvRs3xkgPCsGk/5PTvYm8D5q33yG0J7w/712PTOhid7NTaFETtnSXjngHQavvhVw=="],++ "@radix-ui/react-popover/@radix-ui/react-presence": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/react-use-layout-effect": "1.1.2" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react", "@types/react-dom"] }, "sha512-zdTk4PlUO0E18HnZ3wYbW0KkJJxWCdiNYp6g6X1PtONFhxVkg01vliTJAmwIszU6mHiyBOoW9P0rAugl5/hULQ=="],++ "@radix-ui/react-popover/@radix-ui/react-primitive": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/react-slot": "1.3.0" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react", "@types/react-dom"] }, "sha512-wetd0QI77DbvrPpTAvH1SqOxsYF2wZe5TNxqwOd5Ty4XDpV3dpV0s8K/1MGMJBeY5o7lg8ub5VIt1Ub+yVen6g=="],++ "@radix-ui/react-popover/@radix-ui/react-slot": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.3" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-MojKku4U/miO8Av4Dkb+ctMAQx7JmY96LmtDQlAarCRtd7rN52QCSzBF+XAvr5S6coSVj9HEPBgHAHKEJVk/WA=="],++ "@radix-ui/react-popover/@radix-ui/react-use-controllable-state": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/react-use-effect-event": "0.0.3", "@radix-ui/react-use-layout-effect": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-PLzC90MS+ReootmjC597dvopoelpZ8Q61HJkDXZSExitIq7PL55vHNnesAHwguHK0aPfBnpdNzQtv1uliaqQrA=="],+"@rolldown/binding-wasm32-wasi/@napi-rs/wasm-runtime": ["@napi-rs/[email protected]", "", { "dependencies": { "@tybys/wasm-util": "^0.10.1" }, "peerDependencies": { "@emnapi/core": "^1.7.1", "@emnapi/runtime": "^1.7.1" } }, "sha512-xK9sGVbJWYb08+mTJt3/YV24WxvxpXcXtP6B172paPZ+Ts69Re9dAr7lKwJoeIx8OoeuimEiRZ7umkiUVClmmQ=="],"@tailwindcss/node/jiti": ["[email protected]", "", { "bin": { "jiti": "lib/jiti-cli.mjs" } }, "sha512-ekilCSN1jwRvIbgeg/57YFh8qQDNbwDb9xT/qu2DAHbFFZUicIl4ygVaAvzveMhMVr3LnpSKTNnwt8PoOfmKhQ=="],@@ -4485,6 +4512,8 @@"fumadocs-typescript/ts-morph": ["[email protected]", "", { "dependencies": { "@ts-morph/common": "~0.28.1", "code-block-writer": "^13.0.3" } }, "sha512-fhUhgeljcrdZ+9DZND1De1029PrE+cMkIP7ooqkLRTrRLTqcki2AstsyJm0vRNbTbVCNJ0idGlbBrfqc7/nA8w=="],+ "fumadocs-ui/@radix-ui/react-popover": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/primitive": "1.1.3", "@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/react-context": "1.1.2", "@radix-ui/react-dismissable-layer": "1.1.11", "@radix-ui/react-focus-guards": "1.1.3", "@radix-ui/react-focus-scope": "1.1.7", "@radix-ui/react-id": "1.1.1", "@radix-ui/react-popper": "1.2.8", "@radix-ui/react-portal": "1.1.9", "@radix-ui/react-presence": "1.1.5", "@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-slot": "1.2.3", "@radix-ui/react-use-controllable-state": "1.2.2", "aria-hidden": "^1.2.4", "react-remove-scroll": "^2.6.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react", "@types/react-dom"] }, "sha512-kr0X2+6Yy/vJzLYJUPCZEc8SfQcf+1COFoAqauJm74umQhta9M7lNJHP7QQS3vkvcGLQUbWpMzwrXYwrYztHKA=="],+"fumadocs-ui/@radix-ui/react-slot": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-Jl+bCv8HxKnlTLVrcDE8zTMJ09R9/ukw4qBs/oZClOfoQk/cOTbDn+NceXfV7j09YPVQUryJPHurafcSg6EVKA=="],"fumadocs-ui/tailwind-merge": ["[email protected]", "", {}, "sha512-I8K9wewnVDkL1NTGoqWmVEIlUcB9gFriAEkXkfCjX5ib8ezGxtR3xD7iZIxrfArjEsH7F1CHD4RFUtxefdqV/A=="],@@ -4601,6 +4630,8 @@"puppeteer-core/ws": ["[email protected]", "", { "peerDependencies": { "bufferutil": "^4.0.1", "utf-8-validate": ">=5.0.2" }, "optionalPeers": ["bufferutil", "utf-8-validate"] }, "sha512-sAt8BhgNbzCtgGbt2OxmpuryO63ZoDk/sqaB/znQm94T4fCEsy/yV+7CdC1kJhOU9lboAEU7R3kquuycDoibVA=="],+ "radix-ui/@radix-ui/react-popover": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/primitive": "1.1.3", "@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/react-context": "1.1.2", "@radix-ui/react-dismissable-layer": "1.1.11", "@radix-ui/react-focus-guards": "1.1.3", "@radix-ui/react-focus-scope": "1.1.7", "@radix-ui/react-id": "1.1.1", "@radix-ui/react-popper": "1.2.8", "@radix-ui/react-portal": "1.1.9", "@radix-ui/react-presence": "1.1.5", "@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-slot": "1.2.3", "@radix-ui/react-use-controllable-state": "1.2.2", "aria-hidden": "^1.2.4", "react-remove-scroll": "^2.6.3" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react", "@types/react-dom"] }, "sha512-kr0X2+6Yy/vJzLYJUPCZEc8SfQcf+1COFoAqauJm74umQhta9M7lNJHP7QQS3vkvcGLQUbWpMzwrXYwrYztHKA=="],+"rc/ini": ["[email protected]", "", {}, "sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew=="],"rc/strip-json-comments": ["[email protected]", "", {}, "sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ=="],@@ -4835,6 +4866,34 @@"@opentelemetry/instrumentation-fetch/@opentelemetry/sdk-trace-web/@opentelemetry/sdk-trace-base": ["@opentelemetry/[email protected]", "", { "dependencies": { "@opentelemetry/core": "2.1.0", "@opentelemetry/resources": "2.1.0", "@opentelemetry/semantic-conventions": "^1.29.0" }, "peerDependencies": { "@opentelemetry/api": ">=1.3.0 <1.10.0" } }, "sha512-uTX9FBlVQm4S2gVQO1sb5qyBLq/FPjbp+tmGoxu4tIgtYGmBYB44+KX/725RFDe30yBSaA9Ml9fqphe1hbUyLQ=="],+ "@radix-ui/react-popover/@radix-ui/react-dismissable-layer/@radix-ui/react-use-callback-ref": ["@radix-ui/[email protected]", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-xCso9j1/u8sEgP1RNHjFrXJLApL8LiqOkI1R4ywuN00rxWdYg4oQXuwKLS3i0j5NWLromUD27/4nlxj2UFVvIw=="],++ "@radix-ui/react-popover/@radix-ui/react-dismissable-layer/@radix-ui/react-use-escape-keydown": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/react-use-callback-ref": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-2uVLvLjgO7NZCWw01/FdqRwmA42J0BcjPMUCA+koFEOAb+zjqIP7SiFz/7zWPrKnVmSqr76Omq2ALyCuX4dhLw=="],++ "@radix-ui/react-popover/@radix-ui/react-focus-scope/@radix-ui/react-use-callback-ref": ["@radix-ui/[email protected]", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-xCso9j1/u8sEgP1RNHjFrXJLApL8LiqOkI1R4ywuN00rxWdYg4oQXuwKLS3i0j5NWLromUD27/4nlxj2UFVvIw=="],++ "@radix-ui/react-popover/@radix-ui/react-id/@radix-ui/react-use-layout-effect": ["@radix-ui/[email protected]", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-jrBWOxZITuGcnjRCM2t2U5ZPkCLxD+Ym6DjfssS5haTj2iiak/DOb64JeN6OdLfLgptb6/e2kKR+ZuTrGoZTPA=="],++ "@radix-ui/react-popover/@radix-ui/react-popper/@radix-ui/react-arrow": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/react-primitive": "2.1.6" }, "peerDependencies": { "@types/react": "*", "@types/react-dom": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react", "@types/react-dom"] }, "sha512-j2VTDz1vgCsmuG0k5lBfOcM8n5JPFqZBcMryasFjHYMhwxYL5SRUV5lMSUpRdNtw3D/Sv8pzJtrlAgkssYSsQQ=="],++ "@radix-ui/react-popover/@radix-ui/react-popper/@radix-ui/react-use-callback-ref": ["@radix-ui/[email protected]", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-xCso9j1/u8sEgP1RNHjFrXJLApL8LiqOkI1R4ywuN00rxWdYg4oQXuwKLS3i0j5NWLromUD27/4nlxj2UFVvIw=="],++ "@radix-ui/react-popover/@radix-ui/react-popper/@radix-ui/react-use-layout-effect": ["@radix-ui/[email protected]", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-jrBWOxZITuGcnjRCM2t2U5ZPkCLxD+Ym6DjfssS5haTj2iiak/DOb64JeN6OdLfLgptb6/e2kKR+ZuTrGoZTPA=="],++ "@radix-ui/react-popover/@radix-ui/react-popper/@radix-ui/react-use-rect": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/rect": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-d8a+bBY/FxikNPlgJJoaBHZX+zKVbWHYJGTLnLvveQgFSTntkGdEKv3JDtHrMS0DNYpllz2nRsTLGLKYttbpmw=="],++ "@radix-ui/react-popover/@radix-ui/react-popper/@radix-ui/react-use-size": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/react-use-layout-effect": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-giWQp+4mxjBPt4KZ0MmyuykFNWfbDxKt4x+fPkRYmgRFJSbCZFzUglvMb/Kjn38tm10YP4ufiQZDx3zna4LU6w=="],++ "@radix-ui/react-popover/@radix-ui/react-popper/@radix-ui/rect": ["@radix-ui/[email protected]", "", {}, "sha512-xnXE7wG13PI+cxieVssYXlQJuYVRhH9NBoxt3KNwzghDIA69GMm7d4wXRouHIYjE+KvS6U/MsMO73NdS2MH9ZA=="],++ "@radix-ui/react-popover/@radix-ui/react-portal/@radix-ui/react-use-layout-effect": ["@radix-ui/[email protected]", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-jrBWOxZITuGcnjRCM2t2U5ZPkCLxD+Ym6DjfssS5haTj2iiak/DOb64JeN6OdLfLgptb6/e2kKR+ZuTrGoZTPA=="],++ "@radix-ui/react-popover/@radix-ui/react-presence/@radix-ui/react-use-layout-effect": ["@radix-ui/[email protected]", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-jrBWOxZITuGcnjRCM2t2U5ZPkCLxD+Ym6DjfssS5haTj2iiak/DOb64JeN6OdLfLgptb6/e2kKR+ZuTrGoZTPA=="],++ "@radix-ui/react-popover/@radix-ui/react-use-controllable-state/@radix-ui/react-use-effect-event": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/react-use-layout-effect": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-6c8ZqvPTWILEKnyVkP53EGRCcpnJiKTC21sS/6R1GF5xKyHJJWQEPfkqlcgUkdRQivd6tb23abUwe4ngWmY0JA=="],++ "@radix-ui/react-popover/@radix-ui/react-use-controllable-state/@radix-ui/react-use-layout-effect": ["@radix-ui/[email protected]", "", { "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-jrBWOxZITuGcnjRCM2t2U5ZPkCLxD+Ym6DjfssS5haTj2iiak/DOb64JeN6OdLfLgptb6/e2kKR+ZuTrGoZTPA=="],+"@types/busboy/@types/node/undici-types": ["[email protected]", "", {}, "sha512-Zz+aZWSj8LE6zoxD+xrjh4VfkIG8Ya6LvYkZqtUQGJPZjYl53ypCaUwWqo7eI0x66KBGeRo+mlBEkMSeSZ38Nw=="],"@types/cacheable-request/@types/node/undici-types": ["[email protected]", "", {}, "sha512-Zz+aZWSj8LE6zoxD+xrjh4VfkIG8Ya6LvYkZqtUQGJPZjYl53ypCaUwWqo7eI0x66KBGeRo+mlBEkMSeSZ38Nw=="],@@ -4961,6 +5020,8 @@"fumadocs-typescript/ts-morph/@ts-morph/common": ["@ts-morph/[email protected]", "", { "dependencies": { "minimatch": "^10.0.1", "path-browserify": "^1.0.1", "tinyglobby": "^0.2.14" } }, "sha512-W74iWf7ILp1ZKNYXY5qbddNaml7e9Sedv5lvU1V8lftlitkc9Pq1A+jlH23ltDgWYeZFFEqGCD1Ies9hqu3O+g=="],+ "fumadocs-ui/@radix-ui/react-popover/@radix-ui/react-slot": ["@radix-ui/[email protected]", "", { "dependencies": { "@radix-ui/react-compose-refs": "1.1.2" }, "peerDependencies": { "@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc" }, "optionalPeers": ["@types/react"] }, "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A=="],+"glob/minimatch/brace-expansion": ["[email protected]", "", { "dependencies": { "balanced-match": "^1.0.0", "concat-map": "0.0.1" } }, "sha512-MWPGfDxnyzKU7rNOW9SP/c50vi3xrmrua/+6hfPbCS2ABNWfx24vPidzvC7krjU/RTo235sV776ymlsMtGKj8g=="],"hast-util-from-html/parse5/entities": ["[email protected]", "", {}, "sha512-aN97NXWF6AWBTahfVOIrB/NShkzi5H7F9r1s9mD3cDj4Ko5f2qhhVoYMibXF7GlLveb/D2ioWay8lxI97Ven3g=="],diff --git a/docs/components.json b/docs/components.jsonnew file mode 100644index 000000000..c6a338228--- /dev/null+++ b/docs/components.json@@ -0,0 +1,21 @@+{+ "$schema": "https://ui.shadcn.com/schema.json",+ "style": "new-york",+ "rsc": true,+ "tsx": true,+ "tailwind": {+ "config": "",+ "css": "src/app/global.css",+ "baseColor": "neutral",+ "cssVariables": true,+ "prefix": ""+ },+ "aliases": {+ "components": "@/components",+ "utils": "@/lib/utils",+ "ui": "@/components/ui",+ "lib": "@/lib",+ "hooks": "@/hooks"+ },+ "iconLibrary": "lucide"+}diff --git a/docs/package.json b/docs/package.jsonindex 130c33849..4b5c59b33 100644--- a/docs/package.json+++ b/docs/package.json@@ -17,6 +17,7 @@},"dependencies": {"@inkeep/cxkit-react": "^0.5.117",+ "@radix-ui/react-popover": "^1.1.17","@types/mdx": "^2.0.13","clsx": "^2.1.1","fumadocs-core": "~16.1.0",diff --git a/docs/src/app/d/[encoded]/page.tsx b/docs/src/app/d/[encoded]/page.tsxindex 935b7c66c..8472bbf9d 100644--- a/docs/src/app/d/[encoded]/page.tsx+++ b/docs/src/app/d/[encoded]/page.tsx@@ -1,19 +1,7 @@-import { ChevronDown, FolderIcon, GitBranchIcon } from 'lucide-react';import type { Metadata } from 'next';-import Link from 'next/link';-import { OkWordmark } from '@/components/ok-wordmark';-import {- buildCloneCommand,- buildShareDescription,- buildSplashViewModel,- SPLASH_DOWNLOAD_URL,- SPLASH_INSTALL_COMMAND,-} from '@/lib/share-splash';+import { buildShareDescription, buildSplashViewModel } from '@/lib/share-splash';import { metaDescription, SITE_NAME, SITE_URL, TWITTER_HANDLE } from '@/lib/site';-import { cn } from '@/lib/utils';-import { DotTexture } from '../../(home)/dot-texture';-import { SplashButtonLabel, splashOutlineButton, splashPrimaryButton } from './splash-buttons';-import { SplashCtaPanel } from './splash-cta-panel';+import { SplashFallback, SplashShareView } from './splash-share-view';export const dynamic = 'force-static';@@ -85,179 +73,5 @@ export default async function SplashPage({ params }: SplashPageProps) {return <SplashFallback heading="Invalid share URL." />;}- return (- <main className="relative min-h-screen overflow-hidden bg-slide-bg font-[family-name:var(--font-dm-sans)]">- <SplashChrome />-- <section className="relative z-10 px-4 pt-16 pb-16 md:pt-24 md:pb-20">- <div className="mx-auto max-w-5xl">- <p className="mb-6 font-mono text-base font-medium uppercase tracking-wide text-primary">- {view.target === 'folder' ? 'Shared folder' : 'Shared'}- </p>-- <h1- className="text-3xl font-light tracking-tight text-slide-text sm:text-4xl lg:text-[3.25rem] lg:leading-[1.1]"- data-testid="splash-filename"- >- <span className="relative inline-block break-words">- {view.filename}- <svg- className="absolute -bottom-2 left-0 h-3 w-full"- viewBox="0 0 286 14"- fill="none"- preserveAspectRatio="none"- aria-hidden="true"- >- <path- d="M3 11C45 3.5 91.5 1.5 143 5.5C194.5 9.5 241 7 283 3"- stroke="var(--slide-accent)"- strokeWidth="4"- strokeLinecap="round"- />- </svg>- </span>- </h1>-- <p- className="mt-8 text-lg leading-relaxed text-slide-muted"- data-testid="splash-repo-path"- >- {view.repoPath}- </p>-- {view.target === 'folder' ? (- <p- className="mt-2 inline-flex items-center gap-2 text-sm text-slide-muted"- data-testid="splash-folder-indicator"- >- <FolderIcon className="size-4" aria-hidden="true" />- <span>Folder</span>- </p>- ) : null}-- {view.isDefaultBranch ? null : (- <p- className="mt-2 inline-flex items-center gap-2 text-sm text-slide-muted"- data-testid="splash-branch-indicator"- >- <GitBranchIcon className="size-4" aria-hidden="true" />- <span>- on <span className="font-medium text-slide-text">{view.branch}</span>- </span>- </p>- )}-- <SplashCtaPanel- downloadUrl={`/d/${encoded}/download`}- customSchemeUrl={view.customSchemeUrl}- githubUrl={view.githubUrl}- installCommand={SPLASH_INSTALL_COMMAND}- cloneCommand={buildCloneCommand({- owner: view.owner,- repo: view.repo,- branch: view.branch,- })}- />- </div>- </section>- </main>- );-}--function SplashChrome() {- return (- <>- <DotTexture- variant="right"- priority- className="top-0 right-0 w-60 dark:opacity-30 sm:w-[680px]"- />- <DotTexture- variant="left"- className="bottom-0 left-0 w-40 dark:opacity-30 sm:w-72 lg:w-[515px]"- />- <header className="relative z-10 px-4">- <div className="mx-auto flex max-w-5xl pt-8 md:pt-10">- <Link href="/" aria-label="Open Knowledge home" className="inline-flex items-center">- {/* Link already names the control; hide the wordmark's own label to- avoid a doubled "Open Knowledge" announcement. */}- <OkWordmark aria-hidden="true" className="h-8 w-auto text-slide-text" />- </Link>- </div>- </header>- </>- );-}--function SplashFallback({ heading }: { heading: string }) {- return (- <main className="relative min-h-screen overflow-hidden bg-slide-bg font-[family-name:var(--font-dm-sans)]">- <SplashChrome />-- <section className="relative z-10 px-4 pt-16 pb-16 md:pt-24 md:pb-20">- <div className="mx-auto max-w-5xl">- <h1 className="text-3xl font-light tracking-tight text-slide-text sm:text-4xl">- {heading}- </h1>-- <div className="mt-10 flex flex-wrap items-center gap-4">- <a href={SPLASH_DOWNLOAD_URL} className={splashPrimaryButton}>- <SplashButtonLabel direction="down">Download for macOS</SplashButtonLabel>- </a>- <Link href="/" className={splashOutlineButton}>- <SplashButtonLabel iconStyle="plain">Learn more</SplashButtonLabel>- </Link>- </div>-- <p className="mt-8 text-sm text-slide-muted">- The desktop app runs on macOS. The CLI is cross-platform on macOS and Linux.- </p>-- <SplashFallbackCli />- </div>- </section>- </main>- );-}--function SplashFallbackCli() {- return (- <details className="group mt-6" data-testid="splash-fallback-cli-disclosure">- <summary- className={cn(- 'inline-flex cursor-pointer list-none items-center gap-2 rounded-full border border-azure-blue px-5 py-[13px]',- 'bg-transparent font-mono text-sm font-medium uppercase leading-[115%] tracking-[-0.64px] text-azure-blue sm:text-base',- 'transition duration-200 ease-in-out outline-none',- 'hover:bg-azure-blue hover:text-white',- 'focus-visible:ring-2 focus-visible:ring-slide-accent focus-visible:ring-offset-2',- '[&::-webkit-details-marker]:hidden',- )}- data-testid="splash-fallback-cli-summary"- >- <span>Install the CLI</span>- <ChevronDown- className="size-4 shrink-0 transition-transform duration-200 group-open:rotate-180 motion-reduce:transition-none"- aria-hidden="true"- />- </summary>- <div- className="not-prose mt-3 rounded-lg border border-slide-border bg-slide-bg-elevated p-4"- data-testid="splash-fallback-cli-body"- >- <pre className="overflow-x-auto whitespace-pre rounded bg-black/5 p-3 font-mono text-sm leading-relaxed text-slide-text dark:bg-white/10">- <code className="block">{SPLASH_INSTALL_COMMAND}</code>- </pre>- <p className="mt-3 text-sm text-slide-muted">- See the{' '}- <Link- href="/docs/reference/cli"- className="font-medium text-slide-text underline underline-offset-4 transition-colors hover:text-slide-accent-strong focus-visible:rounded focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-slide-accent"- >- CLI reference- </Link>{' '}- for `ok clone <owner/repo>` and other commands.- </p>- </div>- </details>- );+ return <SplashShareView encoded={encoded} view={view} />;}diff --git a/docs/src/app/d/[encoded]/splash-buttons.tsx b/docs/src/app/d/[encoded]/splash-buttons.tsxindex a65c511d1..0bedcf102 100644--- a/docs/src/app/d/[encoded]/splash-buttons.tsx+++ b/docs/src/app/d/[encoded]/splash-buttons.tsx@@ -5,7 +5,7 @@ export const splashPrimaryButton = cn('inline-flex items-center gap-2 rounded-full h-12 px-[18px] py-[14px] pr-2.5','bg-azure-blue text-white text-sm sm:text-base font-medium uppercase leading-[115%] tracking-[-0.64px]','transition duration-200 ease-in-out outline-none cursor-pointer',- 'hover:bg-blue-dark hover:shadow-lg hover:-translate-y-0.5 active:scale-[0.98] motion-reduce:transform-none motion-reduce:transition-none',+ 'hover:bg-blue-dark dark:hover:bg-primary hover:shadow-lg hover:-translate-y-0.5 active:scale-[0.98] motion-reduce:transform-none motion-reduce:transition-none','focus-visible:ring-2 focus-visible:ring-slide-accent focus-visible:ring-offset-2',);@@ -17,6 +17,14 @@ export const splashOutlineButton = cn('focus-visible:ring-2 focus-visible:ring-slide-accent focus-visible:ring-offset-2',);+export const splashSolidButton = cn(+ 'inline-flex items-center gap-2 rounded-full font-mono border border-azure-blue px-5 py-[13px]',+ 'bg-azure-blue text-white text-sm sm:text-base font-medium uppercase leading-[115%] tracking-[-0.64px]',+ 'transition duration-200 ease-in-out outline-none cursor-pointer',+ 'hover:bg-blue-dark hover:border-blue-dark dark:hover:bg-primary dark:hover:border-primary',+ 'focus-visible:ring-2 focus-visible:ring-slide-accent focus-visible:ring-offset-2',+);+export function SplashButtonLabel({children,direction = 'right',diff --git a/docs/src/app/d/[encoded]/splash-cli-block.tsx b/docs/src/app/d/[encoded]/splash-cli-block.tsxindex 53a1c337a..a723fdbf6 100644--- a/docs/src/app/d/[encoded]/splash-cli-block.tsx+++ b/docs/src/app/d/[encoded]/splash-cli-block.tsx@@ -1,15 +1,15 @@'use client';-import { Check, ChevronDown, Copy } from 'lucide-react';+import { Check, Copy } from 'lucide-react';import { useEffect, useRef, useState } from 'react';import { clipboardCopyOutcome } from '@/lib/share-splash';import { cn } from '@/lib/utils';interface SplashCliBlockProps {installCommand: string;- cloneCommand: string;- disclosureSummary?: { lead: string; action: string };- initialOpen?: boolean;+ cloneCommand?: string;+ wrapperClassName?: string;+ showHeading?: boolean;}const COPY_RESET_MS = 2000;@@ -20,8 +20,8 @@ type CopyStatus = 'idle' | 'copied' | 'failed';export function SplashCliBlock({installCommand,cloneCommand,- disclosureSummary,- initialOpen,+ wrapperClassName,+ showHeading,}: SplashCliBlockProps) {const [status, setStatus] = useState<CopyStatus>('idle');const [failureSelected, setFailureSelected] = useState(false);@@ -43,7 +43,7 @@ export function SplashCliBlock({}, ms);}- const payload = `${installCommand}\n${cloneCommand}`;+ const payload = cloneCommand ? `${installCommand}\n${cloneCommand}` : installCommand;const handleCopy = async () => {let succeeded = true;@@ -81,69 +81,59 @@ export function SplashCliBlock({: "Couldn't copy": 'Copy';- const body = (- <div className="not-prose relative" data-testid="splash-cli-body">- <pre- ref={codeRef}- className="overflow-x-auto whitespace-pre rounded-lg border border-slide-border bg-slide-bg-elevated py-3.5 pr-12 pl-4 font-mono text-sm leading-relaxed text-slide-text"- >- <code className="block">{installCommand}</code>- <code className="block">{cloneCommand}</code>- </pre>- <button- type="button"- onClick={handleCopy}- data-testid="splash-cli-copy"- aria-label="Copy install and clone commands to clipboard"- title={statusLabel}- data-copy-status={status}- className={cn(- 'absolute top-2.5 right-2.5 inline-flex size-7 items-center justify-center rounded-md text-slide-muted transition',- 'hover:bg-black/5 hover:text-slide-text dark:hover:bg-white/10',- 'focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-slide-accent',- status === 'copied' && 'text-slide-accent-strong',- )}- >- {status === 'copied' ? (- <Check className="size-4" aria-hidden="true" />- ) : (- <Copy className="size-4" aria-hidden="true" />- )}- {/* Status stays announced to assistive tech (the clipboard-failure- recovery) while the visible affordance is icon-only. */}- <span className="sr-only" aria-live="polite">- {statusLabel}- </span>- </button>- </div>- );-- if (!disclosureSummary) {- return <div className="mt-12">{body}</div>;- }-return (- <details className="group mt-6" data-testid="splash-cli-disclosure" open={initialOpen ?? false}>- <summary- className={cn(- 'group/cli inline-flex w-fit cursor-pointer list-none items-center gap-1.5 text-sm text-slide-muted',- 'focus-visible:rounded focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-slide-accent',- '[&::-webkit-details-marker]:hidden',- )}- data-testid="splash-cli-disclosure-summary"- >- <span>- {disclosureSummary.lead}{' '}- <span className="font-medium text-slide-text underline underline-offset-4 transition-colors group-hover/cli:text-slide-accent-strong">- {disclosureSummary.action}+ <div className={cn(wrapperClassName ?? 'mt-12')}>+ {showHeading ? (+ <p className="mb-2 inline-flex w-fit items-center gap-1.5 font-mono text-sm uppercase tracking-wide text-slide-muted">+ Open with CLI+ </p>+ ) : null}+ {/* Single rounded code surface with a top-right copy icon, mirroring the+ docs code-block treatment rather than a nested inset + bottom text button.+ Scroll + frame live on the wrapper; padding stays on the <pre> so the+ trailing `px-4` survives a horizontal scroll (a scroll container drops+ its own right padding at the scroll end). */}+ <div className="not-prose relative" data-testid="splash-cli-body">+ <div className="subtle-scrollbar overflow-x-auto rounded-lg border bg-slide-bg dark:bg-white/5">+ <pre+ ref={codeRef}+ translate="no"+ className="w-max min-w-full whitespace-pre px-4 pt-3 pb-2 font-mono text-sm leading-relaxed text-slide-text"+ >+ <code className="block">{installCommand}</code>+ {cloneCommand ? <code className="block">{cloneCommand}</code> : null}+ </pre>+ </div>+ <button+ type="button"+ onClick={handleCopy}+ data-testid="splash-cli-copy"+ aria-label={+ cloneCommand+ ? 'Copy install and clone commands to clipboard'+ : 'Copy install command to clipboard'+ }+ title={statusLabel}+ data-copy-status={status}+ className={cn(+ 'absolute top-2.5 right-2.5 inline-flex size-7 items-center justify-center rounded-md text-slide-muted transition backdrop-blur-xl',+ 'hover:bg-black/5 hover:text-slide-text dark:hover:bg-white/10',+ 'focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-slide-accent',+ status === 'copied' && 'text-primary',+ )}+ >+ {status === 'copied' ? (+ <Check className="size-4" aria-hidden="true" />+ ) : (+ <Copy className="size-4" aria-hidden="true" />+ )}+ {/* Status stays announced to assistive tech (the clipboard-failure+ recovery) while the visible affordance is icon-only. */}+ <span className="sr-only" aria-live="polite">+ {statusLabel}</span>- </span>- <ChevronDown- className="size-3.5 shrink-0 text-slide-muted transition-transform duration-200 group-open:rotate-180 motion-reduce:transition-none"- aria-hidden="true"- />- </summary>- <div className="mt-3">{body}</div>- </details>+ </button>+ </div>+ </div>);}diff --git a/docs/src/app/d/[encoded]/splash-cli-button.tsx b/docs/src/app/d/[encoded]/splash-cli-button.tsxnew file mode 100644index 000000000..9cfcd1851--- /dev/null+++ b/docs/src/app/d/[encoded]/splash-cli-button.tsx@@ -0,0 +1,40 @@+'use client';++import { ChevronDown } from 'lucide-react';+import { cn } from '@/lib/utils';+import { splashOutlineButton, splashSolidButton } from './splash-buttons';+import { SplashCliPopover } from './splash-cli-popover';++export function SplashCliButton({+ installCommand,+ cloneCommand,+ variant = 'outline',+}: {+ installCommand: string;+ cloneCommand?: string;+ variant?: 'primary' | 'outline';+}) {+ return (+ <SplashCliPopover+ installCommand={installCommand}+ cloneCommand={cloneCommand}+ align="start"+ trigger={(open) => (+ <button+ type="button"+ data-testid="splash-cli-trigger"+ className={variant === 'primary' ? splashSolidButton : splashOutlineButton}+ >+ <span className="relative z-[1] whitespace-nowrap font-mono">Open with CLI</span>+ <ChevronDown+ aria-hidden="true"+ className={cn(+ 'size-5 shrink-0 transition-transform duration-200 motion-reduce:transition-none',+ open && 'rotate-180',+ )}+ />+ </button>+ )}+ />+ );+}diff --git a/docs/src/app/d/[encoded]/splash-cli-popover.tsx b/docs/src/app/d/[encoded]/splash-cli-popover.tsxnew file mode 100644index 000000000..c06507d78--- /dev/null+++ b/docs/src/app/d/[encoded]/splash-cli-popover.tsx@@ -0,0 +1,65 @@+'use client';++import { ArrowUpRight } from 'lucide-react';+import { type ReactNode, useState } from 'react';+import { Popover, PopoverContent, PopoverTrigger } from '@/components/ui/popover';+import { cn } from '@/lib/utils';+import { SplashCliBlock } from './splash-cli-block';++interface SplashCliPopoverProps {+ trigger: (open: boolean) => ReactNode;+ installCommand: string;+ cloneCommand?: string;+ githubUrl?: string;+ align?: 'start' | 'center' | 'end';+ sideOffset?: number;+}++export function SplashCliPopover({+ trigger,+ installCommand,+ cloneCommand,+ githubUrl,+ align = 'end',+ sideOffset = 12,+}: SplashCliPopoverProps) {+ const [open, setOpen] = useState(false);++ return (+ <Popover open={open} onOpenChange={setOpen}>+ <PopoverTrigger asChild>{trigger(open)}</PopoverTrigger>+ <PopoverContent+ align={align}+ sideOffset={sideOffset}+ aria-label="Open with CLI"+ data-testid="splash-more-options-panel"+ className="w-88 max-w-[calc(100vw-2rem)] text-left"+ >+ <SplashCliBlock+ installCommand={installCommand}+ cloneCommand={cloneCommand}+ wrapperClassName=""+ showHeading+ />++ {githubUrl ? (+ <a+ href={githubUrl}+ target="_blank"+ rel="noopener noreferrer"+ onClick={() => setOpen(false)}+ data-testid="splash-github-cta"+ className={cn(+ 'mt-4 inline-flex w-fit touch-manipulation items-center gap-1.5 font-mono text-sm uppercase tracking-wide text-slide-muted',+ 'transition-colors hover:text-slide-text',+ 'focus-visible:rounded focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-slide-accent',+ )}+ >+ View on GitHub+ <ArrowUpRight className="size-3.5 shrink-0" aria-hidden="true" />+ </a>+ ) : null}+ </PopoverContent>+ </Popover>+ );+}diff --git a/docs/src/app/d/[encoded]/splash-cta-cluster.tsx b/docs/src/app/d/[encoded]/splash-cta-cluster.tsxindex 5e767497b..eb478b633 100644--- a/docs/src/app/d/[encoded]/splash-cta-cluster.tsx+++ b/docs/src/app/d/[encoded]/splash-cta-cluster.tsx@@ -1,14 +1,16 @@'use client';-import { ArrowUpRight } from 'lucide-react';import { useEffect, useRef, useState } from 'react';import { cn } from '@/lib/utils';import { SplashButtonLabel, splashPrimaryButton } from './splash-buttons';+import { SplashDownloadSplitButton } from './splash-download-split-button';interface SplashCtaClusterProps {downloadUrl: string;customSchemeUrl: string;githubUrl: string;+ installCommand: string;+ cloneCommand: string;}const FALLBACK_REVEAL_DELAY_MS = 2500;@@ -17,38 +19,16 @@ export function SplashCtaCluster({downloadUrl,customSchemeUrl,githubUrl,+ installCommand,+ cloneCommand,}: SplashCtaClusterProps) {const [attempting, setAttempting] = useState(false);const [handoffFailed, setHandoffFailed] = useState(false);- const [downloadClicked, setDownloadClicked] = useState(false);- const [showReopen, setShowReopen] = useState(false);const attemptCleanupRef = useRef<(() => void) | null>(null);const fallbackCtaRef = useRef<HTMLAnchorElement | null>(null);- const reopenCtaRef = useRef<HTMLAnchorElement | null>(null);useEffect(() => () => attemptCleanupRef.current?.(), []);- useEffect(() => {- if (!downloadClicked) return;- function onRefocus() {- if (document.visibilityState === 'visible') setShowReopen(true);- }- window.addEventListener('focus', onRefocus);- document.addEventListener('visibilitychange', onRefocus);- return () => {- window.removeEventListener('focus', onRefocus);- document.removeEventListener('visibilitychange', onRefocus);- };- }, [downloadClicked]);-- useEffect(() => {- if (showReopen) reopenCtaRef.current?.focus();- }, [showReopen]);-- const handleDownloadClick = () => {- setDownloadClicked(true);- };-useEffect(() => {if (handoffFailed) fallbackCtaRef.current?.focus();}, [handoffFailed]);@@ -89,28 +69,6 @@ export function SplashCtaCluster({return (<div className="mt-12">- {showReopen ? (- <div- className="mb-6 rounded-lg border border-[var(--slide-border,rgba(0,0,0,0.08))] p-4"- data-testid="splash-reopen-prompt"- >- <p className="text-sm text-slide-muted">- Installed Open Knowledge? Open it to land on this share.- </p>- <a- ref={reopenCtaRef}- href={customSchemeUrl}- onClick={handleOpenClick}- data-testid="splash-reopen-cta"- className={cn(splashPrimaryButton, 'mt-3 touch-manipulation')}- >- <SplashButtonLabel>- {attempting ? 'Opening…' : 'Open in Open Knowledge'}- </SplashButtonLabel>- </a>- </div>- ) : null}-<div className="flex flex-wrap items-center gap-4"><ahref={customSchemeUrl}@@ -118,54 +76,28 @@ export function SplashCtaCluster({data-testid="splash-open-cta"className={cn(splashPrimaryButton, 'touch-manipulation')}>- <SplashButtonLabel>- {attempting ? 'Opening…' : 'Open in Open Knowledge'}- </SplashButtonLabel>+ <SplashButtonLabel>{attempting ? 'Opening…' : 'Open in macOS app'}</SplashButtonLabel></a>- <a- href={githubUrl}- data-testid="splash-github-cta"- rel="noopener noreferrer"- target="_blank"- className="inline-flex touch-manipulation items-center gap-1.5 font-mono text-sm uppercase tracking-wide text-slide-muted transition-colors hover:text-slide-text focus-visible:rounded focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-slide-accent"- >- View on GitHub- <ArrowUpRight className="size-3.5" aria-hidden="true" />- </a>+ {/* Download + the secondary open-paths (copyable CLI commands, GitHub)+ condensed into one segmented control. fallbackCtaRef lands focus on+ the download segment when the deep-link handoff times out. */}+ <SplashDownloadSplitButton+ downloadUrl={downloadUrl}+ githubUrl={githubUrl}+ installCommand={installCommand}+ cloneCommand={cloneCommand}+ downloadRef={fallbackCtaRef}+ /></div><div aria-live="polite">{handoffFailed ? (- <div className="mt-6" data-testid="splash-handoff-fallback">- <p className="text-sm text-slide-muted">- Looks like Open Knowledge isn’t installed yet.- </p>- <a- ref={fallbackCtaRef}- href={downloadUrl}- onClick={handleDownloadClick}- data-testid="splash-download-fallback-cta"- className={cn(splashPrimaryButton, 'mt-3 touch-manipulation')}- >- <SplashButtonLabel direction="down">- Download Open Knowledge for macOS- </SplashButtonLabel>- </a>- </div>- ) : (- <p className="mt-4 text-sm text-slide-muted">- Don’t have the app?{' '}- <a- href={downloadUrl}- onClick={handleDownloadClick}- data-testid="splash-download-cta"- className="touch-manipulation font-medium text-slide-text underline underline-offset-4 transition-colors hover:text-slide-accent-strong focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-slide-accent focus-visible:rounded"- >- Download for macOS- </a>+ <p className="mt-4 text-sm text-slide-muted" data-testid="splash-handoff-fallback">+ Looks like the macOS app isn’t installed yet — use{' '}+ <span className="font-medium text-slide-text">Download the app</span> above.</p>- )}+ ) : null}</div></div>);diff --git a/docs/src/app/d/[encoded]/splash-cta-panel.tsx b/docs/src/app/d/[encoded]/splash-cta-panel.tsxindex a1e2f8fa6..9f2afbddb 100644--- a/docs/src/app/d/[encoded]/splash-cta-panel.tsx+++ b/docs/src/app/d/[encoded]/splash-cta-panel.tsx@@ -3,7 +3,7 @@import { ArrowUpRight } from 'lucide-react';import { useEffect, useState } from 'react';import { classifySplashOs, type SplashOs, splashCtaLayout } from '@/lib/share-splash';-import { SplashCliBlock } from './splash-cli-block';+import { SplashCliButton } from './splash-cli-button';import { SplashCtaCluster } from './splash-cta-cluster';interface SplashCtaPanelProps {@@ -40,24 +40,23 @@ export function SplashCtaPanel({downloadUrl={downloadUrl}customSchemeUrl={customSchemeUrl}githubUrl={githubUrl}+ installCommand={installCommand}+ cloneCommand={cloneCommand}/>)}- <SplashCliBlock- installCommand={installCommand}- cloneCommand={cloneCommand}- disclosureSummary={- layout.cliInline ? undefined : { lead: 'Have an Intel Mac?', action: 'Open with the CLI' }- }- />-- {/* Linux drops the cluster (no desktop binary, no deep link) but keeps a- standalone GitHub fallback so a recipient who can't run the CLI still- reaches the content. splashCtaLayout encodes the invariant that every- OS keeps a GitHub path (cluster / standalone / Windows notice). */}- {layout.showStandaloneGithub && (- <div className="mt-6">- <SplashGithubLink githubUrl={githubUrl} />+ {/* macOS/unknown carries the CLI inside the cluster's Download dropdown.+ Linux has no desktop binary, so the CLI popover IS the primary action,+ with View on GitHub as the secondary in the same row (the invariant+ that every OS keeps a GitHub path — cluster / here / Windows notice). */}+ {layout.cliInline && (+ <div className="mt-12 flex flex-wrap items-center gap-4">+ <SplashCliButton+ installCommand={installCommand}+ cloneCommand={cloneCommand}+ variant="primary"+ />+ {layout.showStandaloneGithub && <SplashGithubLink githubUrl={githubUrl} />}</div>)}</>@@ -74,7 +73,7 @@ function readPlatformInput(): string | null {function SplashWindowsNotice({ githubUrl }: { githubUrl: string }) {return (- <div className="mt-12 flex flex-col gap-4" role="status" data-testid="splash-windows-notice">+ <div className="mt-12 flex gap-4" role="status" data-testid="splash-windows-notice"><pclassName="text-base leading-relaxed text-slide-text"data-testid="splash-windows-notice-text"diff --git a/docs/src/app/d/[encoded]/splash-download-split-button.tsx b/docs/src/app/d/[encoded]/splash-download-split-button.tsxnew file mode 100644index 000000000..f8fb246f5--- /dev/null+++ b/docs/src/app/d/[encoded]/splash-download-split-button.tsx@@ -0,0 +1,71 @@+'use client';++import { ArrowDown, ChevronDown } from 'lucide-react';+import type { Ref } from 'react';+import { cn } from '@/lib/utils';+import { SplashCliPopover } from './splash-cli-popover';++interface SplashDownloadSplitButtonProps {+ downloadUrl: string;+ githubUrl: string;+ installCommand: string;+ cloneCommand: string;+ downloadRef?: Ref<HTMLAnchorElement>;+}++export function SplashDownloadSplitButton({+ downloadUrl,+ githubUrl,+ installCommand,+ cloneCommand,+ downloadRef,+}: SplashDownloadSplitButtonProps) {+ return (+ // biome-ignore lint/a11y/useSemanticElements: a split button groups two controls, not form fields — role="group" is the correct ARIA pattern (fieldset is wrong here).+ <div+ role="group"+ aria-label="Download or open with other options"+ className="inline-flex items-stretch font-mono text-sm font-medium uppercase leading-[115%] tracking-[-0.64px] text-azure-blue sm:text-base"+ >+ <a+ ref={downloadRef}+ href={downloadUrl}+ data-testid="splash-download-cta"+ className={cn(+ 'inline-flex touch-manipulation items-center gap-2 rounded-l-full border border-r-0 border-azure-blue px-5 py-[13px]',+ 'transition-colors duration-200 outline-none hover:bg-azure-blue hover:text-white',+ 'focus-visible:relative focus-visible:z-10 focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-slide-accent',+ )}+ >+ <ArrowDown aria-hidden="true" className="size-4 shrink-0" />+ Download the app+ </a>++ <SplashCliPopover+ installCommand={installCommand}+ cloneCommand={cloneCommand}+ githubUrl={githubUrl}+ trigger={(open) => (+ <button+ type="button"+ aria-label="More ways to open this share"+ data-testid="splash-more-options"+ className={cn(+ 'flex touch-manipulation items-center rounded-r-full border border-azure-blue border-l-azure-blue/40 px-3 py-[13px]',+ 'transition-colors duration-200 outline-none hover:bg-azure-blue hover:text-white',+ 'focus-visible:relative focus-visible:z-10 focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-slide-accent',+ )}+ >+ <ChevronDown+ aria-hidden="true"+ className={cn(+ 'size-4 shrink-0 transition-transform duration-200 motion-reduce:transition-none',+ open && 'rotate-180',+ )}+ />+ </button>+ )}+ />+ </div>+ );+}diff --git a/docs/src/app/d/[encoded]/splash-share-view.tsx b/docs/src/app/d/[encoded]/splash-share-view.tsxnew file mode 100644index 000000000..1a4e39ca9--- /dev/null+++ b/docs/src/app/d/[encoded]/splash-share-view.tsx@@ -0,0 +1,149 @@+import { DotIcon, GitBranchIcon } from 'lucide-react';+import Link from 'next/link';+import { OkWordmark } from '@/components/ok-wordmark';+import {+ buildCloneCommand,+ SPLASH_DOWNLOAD_URL,+ SPLASH_INSTALL_COMMAND,+ type SplashView,+} from '@/lib/share-splash';+import { DotTexture } from '../../(home)/dot-texture';+import { SiteFooter } from '../../(home)/footer';+import { SplashButtonLabel, splashPrimaryButton } from './splash-buttons';+import { SplashCliButton } from './splash-cli-button';+import { SplashCtaPanel } from './splash-cta-panel';++type OkSplashView = Extract<SplashView, { kind: 'ok' }>;++export function SplashShareView({ encoded, view }: { encoded: string; view: OkSplashView }) {+ return (+ <main className="relative flex min-h-screen flex-col overflow-hidden bg-slide-bg font-[family-name:var(--font-dm-sans)]">+ <SplashChrome />++ <section className="relative z-20 flex-1 px-4 pt-16 pb-16 md:pt-24 md:pb-20">+ <div className="mx-auto max-w-5xl">+ <p className="mb-6 font-mono text-base font-medium uppercase tracking-wide text-primary">+ {view.target === 'folder' ? 'Shared folder' : 'Shared'}+ </p>++ <h1+ className="text-3xl font-light tracking-tight text-slide-text sm:text-4xl lg:text-[3.25rem] lg:leading-[1.1]"+ data-testid="splash-filename"+ >+ <a+ href={view.githubUrl}+ target="_blank"+ rel="noopener noreferrer"+ className="relative inline-block break-words rounded-sm outline-none transition-colors hover:text-primary focus-visible:outline-2 focus-visible:outline-offset-4 focus-visible:outline-slide-accent"+ >+ {view.filename}+ <svg+ className="absolute -bottom-2 left-0 h-3 w-full"+ viewBox="0 0 286 14"+ fill="none"+ preserveAspectRatio="none"+ aria-hidden="true"+ >+ <path+ d="M3 11C45 3.5 91.5 1.5 143 5.5C194.5 9.5 241 7 283 3"+ stroke="var(--slide-accent)"+ strokeWidth="4"+ strokeLinecap="round"+ />+ </svg>+ </a>+ </h1>+ <div className="flex items-center gap-2 mt-8">+ <a+ href={view.githubUrl}+ target="_blank"+ rel="noopener noreferrer"+ className="flex w-fit items-center gap-1.5 text-lg leading-relaxed text-slide-muted underline decoration-slide-muted/30 underline-offset-4 outline-none transition-colors hover:text-slide-text hover:decoration-slide-text/50 focus-visible:rounded focus-visible:no-underline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-slide-accent"+ data-testid="splash-repo-path"+ >+ {view.repoPath}+ </a>++ {view.isDefaultBranch ? null : (+ <p+ className="inline-flex items-center gap-1.5 text-slide-muted"+ data-testid="splash-branch-indicator"+ >+ <DotIcon aria-hidden="true" />+ <GitBranchIcon className="size-4" aria-hidden="true" />+ <span className="font-medium">{view.branch}</span>+ </p>+ )}+ </div>+ <SplashCtaPanel+ downloadUrl={`/d/${encoded}/download`}+ customSchemeUrl={view.customSchemeUrl}+ githubUrl={view.githubUrl}+ installCommand={SPLASH_INSTALL_COMMAND}+ cloneCommand={buildCloneCommand({+ owner: view.owner,+ repo: view.repo,+ branch: view.branch,+ })}+ />+ </div>+ </section>++ <div className="relative z-10">+ <SiteFooter />+ </div>+ </main>+ );+}++function SplashChrome() {+ return (+ <>+ <DotTexture+ variant="right"+ priority+ className="top-0 right-0 w-60 dark:opacity-30 sm:w-[680px]"+ />+ <DotTexture+ variant="left"+ className="bottom-0 left-0 w-40 dark:opacity-30 sm:w-72 lg:w-[515px]"+ />+ <header className="relative z-10 px-4">+ <div className="mx-auto flex max-w-5xl pt-8 md:pt-10">+ <Link href="/" aria-label="Open Knowledge home" className="inline-flex items-center">+ {/* Link already names the control; hide the wordmark's own label to+ avoid a doubled "Open Knowledge" announcement. */}+ <OkWordmark aria-hidden="true" className="h-8 w-auto text-slide-text" />+ </Link>+ </div>+ </header>+ </>+ );+}++export function SplashFallback({ heading }: { heading: string }) {+ return (+ <main className="relative flex min-h-screen flex-col overflow-hidden bg-slide-bg font-[family-name:var(--font-dm-sans)]">+ <SplashChrome />++ <section className="relative z-20 flex-1 px-4 pt-16 pb-16 md:pt-24 md:pb-20">+ <div className="mx-auto max-w-5xl">+ <h1 className="text-3xl font-light tracking-tight text-slide-text sm:text-4xl">+ {heading}+ </h1>++ <div className="mt-10 flex flex-wrap items-center gap-4">+ <a href={SPLASH_DOWNLOAD_URL} className={splashPrimaryButton}>+ <SplashButtonLabel direction="down">Download for macOS</SplashButtonLabel>+ </a>+ <SplashCliButton installCommand={SPLASH_INSTALL_COMMAND} />+ </div>+ </div>+ </section>++ <div className="relative z-10">+ <SiteFooter />+ </div>+ </main>+ );+}diff --git a/docs/src/app/global.css b/docs/src/app/global.cssindex 85dae155b..b8ab08c6b 100644--- a/docs/src/app/global.css+++ b/docs/src/app/global.css@@ -84,6 +84,10 @@}}+.subtle-scrollbar {+ @apply scrollbar-thin scrollbar-track-transparent scrollbar-thumb-fd-muted-foreground/30 dark:scrollbar-thumb-fd-muted-foreground/50;+}+/* Home-route nav polish: match the page background, give the barmore vertical room than Fumadocs' default h-14, and render thetheme-toggle icons as stroke-only Lucide (Fumadocs hardcodesdiff --git a/docs/src/components/ui/popover.tsx b/docs/src/components/ui/popover.tsxnew file mode 100644index 000000000..447eec5ae--- /dev/null+++ b/docs/src/components/ui/popover.tsx@@ -0,0 +1,37 @@+'use client';++import * as PopoverPrimitive from '@radix-ui/react-popover';+import type * as React from 'react';+import { cn } from '@/lib/utils';++function Popover({ ...props }: React.ComponentProps<typeof PopoverPrimitive.Root>) {+ return <PopoverPrimitive.Root data-slot="popover" {...props} />;+}++function PopoverTrigger({ ...props }: React.ComponentProps<typeof PopoverPrimitive.Trigger>) {+ return <PopoverPrimitive.Trigger data-slot="popover-trigger" {...props} />;+}++function PopoverContent({+ className,+ align = 'center',+ sideOffset = 4,+ ...props+}: React.ComponentProps<typeof PopoverPrimitive.Content>) {+ return (+ <PopoverPrimitive.Portal>+ <PopoverPrimitive.Content+ data-slot="popover-content"+ align={align}+ sideOffset={sideOffset}+ className={cn(+ 'z-50 w-72 rounded-2xl border bg-slide-bg-elevated p-4 text-slide-text shadow-xl outline-none',+ className,+ )}+ {...props}+ />+ </PopoverPrimitive.Portal>+ );+}++export { Popover, PopoverContent, PopoverTrigger };