{"_id":"@bozonx/fastcat-embed","_rev":"7-f398532bbe6b4a79cfe475ff2999f14d","name":"@bozonx/fastcat-embed","dist-tags":{"latest":"0.7.3"},"versions":{"0.1.0":{"name":"@bozonx/fastcat-embed","version":"0.1.0","keywords":["fastcat","video-editor","embed","iframe","sdk","postmessage","webgpu"],"author":"FastCat Team","license":"MIT","_id":"@bozonx/fastcat-embed@0.1.0","maintainers":[{"name":"bozonx","email":"ipkozyrin@gmail.com"}],"homepage":"https://github.com/bozonx/fastcat#readme","bugs":{"url":"https://github.com/bozonx/fastcat/issues"},"dist":{"shasum":"0e9b698f61b079fd13ac99fe97ec3826b91ca7cf","tarball":"https://registry.npmjs.org/@bozonx/fastcat-embed/-/fastcat-embed-0.1.0.tgz","fileCount":11,"integrity":"sha512-rRNc47+JPMYq3/fiyvJ6aiSG81QbCGny+YwNZdUsTljO7tWcoTV+U2xUB0cCyPr2cuMgUH5pseOpS7Or7Dhn6A==","signatures":[{"sig":"MEUCIAy4VIDHKCJQG8doqwkF/Q+ZpwGa5aZf0NMppoabeA6VAiEA49jCPgDcOzn9DXWvEpD2JLjRAMFQrwep0IFbuaaAKzE=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":80198},"main":"./dist/index.js","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=18.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"},"./protocol":{"types":"./dist/protocol.d.ts","import":"./dist/protocol.js","default":"./dist/protocol.js"},"./package.json":"./package.json"},"scripts":{"lint":"eslint --max-warnings 0 .","build":"tsc -p tsconfig.json","check":"pnpm typecheck && pnpm lint && pnpm format:check","clean":"rm -rf dist","format":"prettier --write .","lint:fix":"eslint --fix .","validate":"pnpm check","typecheck":"tsc -p tsconfig.json --noEmit","format:check":"prettier --check ."},"_npmUser":{"name":"bozonx","email":"ipkozyrin@gmail.com"},"repository":{"url":"https://github.com/bozonx/fastcat.git","type":"git","directory":"packages/embed"},"description":"SDK for embedding the FastCat video editor into any web page through an isolated iframe.","directories":{},"sideEffects":false,"_nodeVersion":"22.23.2","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^10.7.0","typescript":"~5.9.0","@fastcat/eslint-config":"0.1.0","@fastcat/typescript-config":"0.1.0"},"_npmOperationalInternal":{"tmp":"tmp/fastcat-embed_0.1.0_1787277060837_0.3292604730756701","host":"s3://npm-registry-packages-npm-production"}},"0.2.0":{"name":"@bozonx/fastcat-embed","version":"0.2.0","keywords":["fastcat","video-editor","embed","iframe","sdk","postmessage","webgpu"],"author":"FastCat Team","license":"MIT","_id":"@bozonx/fastcat-embed@0.2.0","maintainers":[{"name":"bozonx","email":"ipkozyrin@gmail.com"}],"homepage":"https://github.com/bozonx/fastcat#readme","bugs":{"url":"https://github.com/bozonx/fastcat/issues"},"dist":{"shasum":"18c41f8a9516e6809c1cdae4df240fd11df3ffbf","tarball":"https://registry.npmjs.org/@bozonx/fastcat-embed/-/fastcat-embed-0.2.0.tgz","fileCount":11,"integrity":"sha512-z17y7QvruhgEu7XYd4CiNrD1lE/Tm7K03suYbmJi0p57A1HnqJVMbS6qFknwYl6nAnTYBy1XZiC/TIqxAfL47Q==","signatures":[{"sig":"MEUCIQCfR5mn6zVpqL1LFWDuldVr9aW/MInPgHav/uiinb7pGQIgfokvhKGo9DZYT40gPCFwdrxT+U++w5NIvQMjVrkr+DI=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":80924},"main":"./dist/index.js","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=24.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"},"./protocol":{"types":"./dist/protocol.d.ts","import":"./dist/protocol.js","default":"./dist/protocol.js"},"./package.json":"./package.json"},"scripts":{"lint":"eslint --max-warnings 0 .","build":"tsc -p tsconfig.json","check":"pnpm typecheck && pnpm lint && pnpm format:check","clean":"rm -rf dist","format":"prettier --write .","lint:fix":"eslint --fix .","validate":"pnpm check","typecheck":"tsc -p tsconfig.json --noEmit","format:check":"prettier --check ."},"_npmUser":{"name":"bozonx","email":"ipkozyrin@gmail.com"},"repository":{"url":"https://github.com/bozonx/fastcat.git","type":"git","directory":"packages/embed"},"description":"SDK for embedding the FastCat video editor into any web page through an isolated iframe.","directories":{},"sideEffects":false,"_nodeVersion":"24.19.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^10.7.0","typescript":"~5.9.0","@fastcat/eslint-config":"0.1.0","@fastcat/typescript-config":"0.1.0"},"_npmOperationalInternal":{"tmp":"tmp/fastcat-embed_0.2.0_1787324412994_0.8423076511596841","host":"s3://npm-registry-packages-npm-production"}},"0.2.2":{"name":"@bozonx/fastcat-embed","version":"0.2.2","keywords":["fastcat","video-editor","embed","iframe","sdk","postmessage","webgpu"],"author":"FastCat Team","license":"MIT","_id":"@bozonx/fastcat-embed@0.2.2","maintainers":[{"name":"bozonx","email":"ipkozyrin@gmail.com"}],"homepage":"https://github.com/bozonx/fastcat#readme","bugs":{"url":"https://github.com/bozonx/fastcat/issues"},"dist":{"shasum":"6cae6a224e196cdf27903f325a93ea9583829b36","tarball":"https://registry.npmjs.org/@bozonx/fastcat-embed/-/fastcat-embed-0.2.2.tgz","fileCount":11,"integrity":"sha512-siuifzi+/ugn9ITcjbKLQYZVlC9jp3DTGpNRfWh1BYdgBE8X9W/d76uLB21cxFHepw14UpAvzsVOdfFKbY0G/g==","signatures":[{"sig":"MEUCIQCCnav9pGcMKfmGvX7jDc6jcv35jToXnsmWP9T7vQ9ZWwIgdkigxEwtCi0JWKRTBlf90ZBhgy0al03Tiev4HgoEOEM=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":81140},"main":"./dist/index.js","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=24.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"},"./protocol":{"types":"./dist/protocol.d.ts","import":"./dist/protocol.js","default":"./dist/protocol.js"},"./package.json":"./package.json"},"scripts":{"lint":"eslint --max-warnings 0 .","build":"tsc -p tsconfig.json","check":"pnpm typecheck && pnpm lint && pnpm format:check","clean":"rm -rf dist","format":"prettier --write .","lint:fix":"eslint --fix .","validate":"pnpm check","typecheck":"tsc -p tsconfig.json --noEmit","format:check":"prettier --check ."},"_npmUser":{"name":"bozonx","email":"ipkozyrin@gmail.com"},"repository":{"url":"https://github.com/bozonx/fastcat.git","type":"git","directory":"packages/embed"},"description":"SDK for embedding the FastCat video editor into any web page through an isolated iframe.","directories":{},"sideEffects":false,"_nodeVersion":"24.20.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^10.7.0","typescript":"~5.9.0","@fastcat/eslint-config":"0.1.0","@fastcat/typescript-config":"0.1.0"},"_npmOperationalInternal":{"tmp":"tmp/fastcat-embed_0.2.2_1788545312048_0.47917973300029404","host":"s3://npm-registry-packages-npm-production"}},"0.7.0":{"name":"@bozonx/fastcat-embed","version":"0.7.0","keywords":["fastcat","video-editor","embed","iframe","sdk","postmessage","webgpu"],"author":"FastCat Team","license":"MIT","_id":"@bozonx/fastcat-embed@0.7.0","maintainers":[{"name":"bozonx","email":"ipkozyrin@gmail.com"}],"homepage":"https://github.com/bozonx/fastcat#readme","bugs":{"url":"https://github.com/bozonx/fastcat/issues"},"dist":{"shasum":"35801d3c666d7a10cb52fde33e464a8a77806f4a","tarball":"https://registry.npmjs.org/@bozonx/fastcat-embed/-/fastcat-embed-0.7.0.tgz","fileCount":11,"integrity":"sha512-Kbhj+qvcBK0xQcysZJH57h8nbNRpgRB4uTntqpO8SQze0UDkKZ5KD0nf55BKwSTMvRlOdzSah9rQ6RiS5CqDqg==","signatures":[{"sig":"MEUCIAhgqGPgAdd2+vqg1l+tbDg1I93gYLj37PsvedXSX15RAiEAuYpD/6UQr3OJRi2Reo9UNeS2iTUglyUe/8NR2aPufKU=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"sig":"MEQCIA9iT5bIzXMPNL0gvYQ9+fEmptWNC4p/Cx2LV43OcUuvAiAIE2tDOkD6yYSJK2iPhcwVTswyjE8mXa1IHj2QTGhLXA==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":81303},"main":"./dist/index.js","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=24.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"},"./protocol":{"types":"./dist/protocol.d.ts","import":"./dist/protocol.js","default":"./dist/protocol.js"},"./package.json":"./package.json"},"scripts":{"lint":"eslint --max-warnings 0 .","build":"tsc -p tsconfig.json","check":"pnpm typecheck && pnpm lint && pnpm format:check","clean":"rm -rf dist","format":"prettier --write .","lint:fix":"eslint --fix .","validate":"pnpm check","typecheck":"tsc -p tsconfig.json --noEmit","format:check":"prettier --check ."},"_npmUser":{"name":"bozonx","email":"ipkozyrin@gmail.com"},"repository":{"url":"https://github.com/bozonx/fastcat.git","type":"git","directory":"packages/embed"},"description":"SDK for embedding the FastCat video editor into any web page through an isolated iframe.","directories":{},"sideEffects":false,"_nodeVersion":"24.20.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^10.7.0","typescript":"~5.9.0","@fastcat/eslint-config":"0.1.1","@fastcat/typescript-config":"0.1.1"},"_npmOperationalInternal":{"tmp":"tmp/fastcat-embed_0.7.0_1789759159102_0.1035982761628449","host":"s3://npm-registry-packages-npm-production"}},"0.7.1":{"name":"@bozonx/fastcat-embed","version":"0.7.1","keywords":["fastcat","video-editor","embed","iframe","sdk","postmessage","webgpu"],"author":"FastCat Team","license":"MIT","_id":"@bozonx/fastcat-embed@0.7.1","maintainers":[{"name":"bozonx","email":"ipkozyrin@gmail.com"}],"homepage":"https://github.com/bozonx/fastcat#readme","bugs":{"url":"https://github.com/bozonx/fastcat/issues"},"dist":{"shasum":"d94243b6dfdd21e8b8983fb7feef362ea668ea24","tarball":"https://registry.npmjs.org/@bozonx/fastcat-embed/-/fastcat-embed-0.7.1.tgz","fileCount":11,"integrity":"sha512-5dJKwAvhpwG2LOxKcmgwPvG+g5cSBzLmDtG9ioVg9SE0z8AoQnK9LYejpxIzBd6HIpR9mYArz7upeGQUiW0PiA==","signatures":[{"sig":"MEUCIQCGEutCPpAGXZE7d1zU+WeVGDfkVuvXnMMhSNKT+euSHgIgec65el8vVaAvJM8bpZR+8v7/5CaOS9RZvdAGTap59Ls=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"sig":"MEUCIQC1HQhXDFGTNuwBm5lZMb+e72wALwxLkVxPRaGtE1gfUgIgMoTYcpguKju2nrIFphAss9hKyQCrTuQH28hhAyn8DzA=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":81303},"main":"./dist/index.js","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=24.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"},"./protocol":{"types":"./dist/protocol.d.ts","import":"./dist/protocol.js","default":"./dist/protocol.js"},"./package.json":"./package.json"},"scripts":{"lint":"eslint --max-warnings 0 .","build":"tsc -p tsconfig.json","check":"pnpm typecheck && pnpm lint && pnpm format:check","clean":"rm -rf dist","format":"prettier --write .","lint:fix":"eslint --fix .","validate":"pnpm check","typecheck":"tsc -p tsconfig.json --noEmit","format:check":"prettier --check ."},"_npmUser":{"name":"bozonx","email":"ipkozyrin@gmail.com"},"repository":{"url":"https://github.com/bozonx/fastcat.git","type":"git","directory":"packages/embed"},"description":"SDK for embedding the FastCat video editor into any web page through an isolated iframe.","directories":{},"sideEffects":false,"_nodeVersion":"24.20.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^10.7.0","typescript":"~5.9.0","@fastcat/eslint-config":"0.1.2","@fastcat/typescript-config":"0.1.2"},"_npmOperationalInternal":{"tmp":"tmp/fastcat-embed_0.7.1_1789817414862_0.49599336795071136","host":"s3://npm-registry-packages-npm-production"}},"0.7.2":{"name":"@bozonx/fastcat-embed","version":"0.7.2","keywords":["fastcat","video-editor","embed","iframe","sdk","postmessage","webgpu"],"author":"FastCat Team","license":"MIT","_id":"@bozonx/fastcat-embed@0.7.2","maintainers":[{"name":"bozonx","email":"ipkozyrin@gmail.com"}],"homepage":"https://github.com/bozonx/fastcat#readme","bugs":{"url":"https://github.com/bozonx/fastcat/issues"},"dist":{"shasum":"310d2ad84d19646f2916e170a830c358855baca4","tarball":"https://registry.npmjs.org/@bozonx/fastcat-embed/-/fastcat-embed-0.7.2.tgz","fileCount":11,"integrity":"sha512-YmL/msvSHZechwtcLbMlJyzCznUtMF6gdPb8QYKPpJ8b0IwhVB+aPLNjpF2z8ZSuzMy0cVnS5VBgPEqX077x/g==","signatures":[{"sig":"MEUCIQDC+rd44P+jynwwa1Pcy4zynbPEvCG3Af3VBa8IKP+Q9gIgZf2iWUjjMadi3F4Dv26LHvXazAujJ3mOR9E5ldFrH6g=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"sig":"MEUCIAxzpnQxhcCn3fF9IZjGVv+qIRw4Cm7xS5D4fB7V7dG8AiEA/cTcgxcXWMMl5zbqJSXu+0XNsw9rlOr6nm8uh+h/vFc=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":81303},"main":"./dist/index.js","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=24.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"},"./protocol":{"types":"./dist/protocol.d.ts","import":"./dist/protocol.js","default":"./dist/protocol.js"},"./package.json":"./package.json"},"scripts":{"lint":"eslint --max-warnings 0 .","build":"tsc -p tsconfig.json","check":"pnpm typecheck && pnpm lint && pnpm format:check","clean":"rm -rf dist","format":"prettier --write .","lint:fix":"eslint --fix .","validate":"pnpm check","typecheck":"tsc -p tsconfig.json --noEmit","format:check":"prettier --check ."},"_npmUser":{"name":"bozonx","email":"ipkozyrin@gmail.com"},"repository":{"url":"https://github.com/bozonx/fastcat.git","type":"git","directory":"packages/embed"},"description":"SDK for embedding the FastCat video editor into any web page through an isolated iframe.","directories":{},"sideEffects":false,"_nodeVersion":"24.20.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^10.7.0","typescript":"~5.9.0","@fastcat/eslint-config":"0.1.3","@fastcat/typescript-config":"0.1.3"},"_npmOperationalInternal":{"tmp":"tmp/fastcat-embed_0.7.2_1789821778845_0.7850924501887193","host":"s3://npm-registry-packages-npm-production"}},"0.7.3":{"_id":"@bozonx/fastcat-embed@0.7.3","bugs":{"url":"https://github.com/bozonx/fastcat/issues"},"dist":{"shasum":"070ee4148b66bbd4756ec54e1903502178181da6","tarball":"https://registry.npmjs.org/@bozonx/fastcat-embed/-/fastcat-embed-0.7.3.tgz","fileCount":11,"integrity":"sha512-oRZKc85KfopNT/C7Y8nAZ3E8LwWa0xehyj0ZwcpjX631kj1zm35shVOgYqj3gesQBe6rrH5H/BvwuZh5nuZpug==","signatures":[{"sig":"MEQCIHkRrqT58tLpXzZruYEGdoTcDPl73Fih5K4ZODY2ZSx+AiAC2vNPSVjeSDg95C6MEKlxsOMZNSqhaoZZizvpE4c3IQ==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIGZIXVmQs9VwUpBNPIE2i23mujSW0DHRHC3rX+QXdDxPAiAbRDPXXMes72Kv+ifJYz+cCtAQXPg4B2NCzmfSNUtqMQ=="}],"unpackedSize":86909},"main":"./dist/index.js","name":"@bozonx/fastcat-embed","type":"module","types":"./dist/index.d.ts","author":"FastCat Team","module":"./dist/index.js","engines":{"node":">=24.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"},"./protocol":{"types":"./dist/protocol.d.ts","import":"./dist/protocol.js","default":"./dist/protocol.js"},"./package.json":"./package.json"},"license":"MIT","scripts":{"lint":"eslint --max-warnings 0 .","build":"tsc -p tsconfig.json","check":"pnpm typecheck && pnpm lint && pnpm format:check","clean":"rm -rf dist","format":"prettier --write .","lint:fix":"eslint --fix .","validate":"pnpm check","typecheck":"tsc -p tsconfig.json --noEmit","format:check":"prettier --check ."},"version":"0.7.3","_npmUser":{"name":"bozonx","email":"ipkozyrin@gmail.com"},"homepage":"https://github.com/bozonx/fastcat#readme","keywords":["fastcat","video-editor","embed","iframe","sdk","postmessage","webgpu"],"repository":{"url":"https://github.com/bozonx/fastcat.git","type":"git","directory":"packages/embed"},"description":"SDK for embedding the FastCat video editor into any web page through an isolated iframe.","directories":{},"maintainers":[{"name":"bozonx","email":"ipkozyrin@gmail.com"}],"sideEffects":false,"_nodeVersion":"24.20.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"eslint":"^10.7.0","typescript":"~5.9.0","@fastcat/eslint-config":"0.1.4","@fastcat/typescript-config":"0.1.4"},"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/fastcat-embed_0.7.3_1789851396976_0.06627793032610074"}}},"time":{"created":"2026-08-21T01:51:00.593Z","modified":"2026-09-19T20:56:37.290Z","0.1.0":"2026-08-21T01:51:00.968Z","0.2.0":"2026-08-21T15:00:13.135Z","0.2.2":"2026-09-04T18:08:32.173Z","0.7.0":"2026-09-18T19:19:19.203Z","0.7.1":"2026-09-19T11:30:14.970Z","0.7.2":"2026-09-19T12:42:58.952Z","0.7.3":"2026-09-19T20:56:37.131Z"},"bugs":{"url":"https://github.com/bozonx/fastcat/issues"},"author":"FastCat Team","license":"MIT","homepage":"https://github.com/bozonx/fastcat#readme","keywords":["fastcat","video-editor","embed","iframe","sdk","postmessage","webgpu"],"repository":{"url":"https://github.com/bozonx/fastcat.git","type":"git","directory":"packages/embed"},"description":"SDK for embedding the FastCat video editor into any web page through an isolated iframe.","maintainers":[{"name":"bozonx","email":"ipkozyrin@gmail.com"}],"readme":"# @bozonx/fastcat-embed\n\nOfficial JavaScript / TypeScript SDK for embedding the **FastCat Video Editor** into any web application through an isolated cross-origin iframe.\n\n[![npm version](https://img.shields.io/npm/v/@bozonx/fastcat-embed.svg)](https://www.npmjs.com/package/@bozonx/fastcat-embed)\n[![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)\n\n---\n\n## Overview\n\n`@bozonx/fastcat-embed` is a zero-dependency, lightweight host-side library that manages the lifecycle of the FastCat editor iframe, handles cryptographic origin and nonce verification, and provides a strictly typed message boundary between your host application and the editor.\n\nThe editor itself runs in an isolated iframe (hosted on your domain or FastCat Cloud), while your host page controls initial configuration, media feeding, export triggers, and event listening.\n\nTo serve the editor from your own domain, deploy [`@bozonx/fastcat`](https://www.npmjs.com/package/@bozonx/fastcat) of the same version — see its `HOSTING.md`.\n\n---\n\n## Installation\n\n```bash\n# npm\nnpm install @bozonx/fastcat-embed\n\n# pnpm\npnpm add @bozonx/fastcat-embed\n\n# yarn\nyarn add @bozonx/fastcat-embed\n```\n\n---\n\n## Quick Start\n\n```typescript\nimport { createFastcatEmbed, type FastcatEmbed } from '@bozonx/fastcat-embed';\n\nconst container = document.getElementById('editor-container')!;\n\nconst embed: FastcatEmbed = createFastcatEmbed({\n  container,\n  editorUrl: 'https://embed.fastcat.video/embed',\n  locale: 'en',\n  layout: 'desktop', // 'auto' | 'desktop' | 'mobile'\n  features: ['export', 'files', 'sound'],\n  assets: [\n    {\n      id: 'clip-1',\n      kind: 'video',\n      url: 'https://cdn.example.com/videos/intro.mp4',\n      filename: 'intro.mp4',\n    },\n  ],\n  onReady: (capabilities) => {\n    console.log('Editor ready with capabilities:', capabilities);\n  },\n  onChange: ({ dirty, otio }) => {\n    console.log('Timeline changed (unsaved draft):', { dirty, otio });\n  },\n  onExportProgress: ({ phase, progress }) => {\n    console.log(`Export progress (${phase}): ${Math.round(progress * 100)}%`);\n  },\n  onExportDone: async (result) => {\n    console.log('Export finished:', result.meta);\n    if (result.file) {\n      // Stream or upload the resulting File\n      const downloadUrl = URL.createObjectURL(result.file);\n      window.open(downloadUrl);\n    }\n  },\n  onError: (err) => {\n    console.error('Editor error:', err);\n  },\n});\n\n// Programmatic actions\nawait embed.ready;\nawait embed.initialized;\n// embed.startExport({ filename: 'my-video.mp4' });\n// embed.addAssets([{ url: 'https://cdn.example.com/audio.mp3', kind: 'audio' }]);\n// await embed.dispose();\n```\n\n---\n\n## API Reference\n\n### `createFastcatEmbed(options: FastcatEmbedOptions): FastcatEmbed`\n\nMounts the editor iframe into `options.container`, initiates the secure handshake, and returns a controller handle.\n\n#### `FastcatEmbedOptions`\n\n| Option            | Type                              | Default               | Description                                                                                                    |\n| :---------------- | :-------------------------------- | :-------------------- | :------------------------------------------------------------------------------------------------------------- |\n| `container`       | `HTMLElement`                     | _required_            | The DOM element where the iframe is appended.                                                                  |\n| `editorUrl`       | `string`                          | _required_            | Absolute URL of the editor embed route (e.g. `https://embed.fastcat.video/embed`).                             |\n| `assets`          | `EmbedAsset[]`                    | `[]`                  | Initial media assets loaded into the editor session.                                                           |\n| `locale`          | `string`                          | `'en'`                | Interface language code (e.g. `'en'`, `'ru'`).                                                                 |\n| `layout`          | `'auto' \\| 'desktop' \\| 'mobile'` | `'auto'`              | Preferred editor layout. `'auto'` selects automatically on first render.                                       |\n| `features`        | `EmbedFeatureName[]`              | `['export']`          | Optional views: `'files'`, `'sound'`, `'settings'`; `'export'` adds advanced export settings. Unknown ignored. |\n| `projectDefaults` | `EmbedProjectDefaults`            | `undefined`           | Output format. Omitted: taken from the first video; if there is none, the user is asked.                       |\n| `assetTransport`  | `'url' \\| 'host'`                 | `'url'`               | `'url'` streams assets via HTTP range requests; `'host'` uses in-memory transfers.                             |\n| `output`          | `'blob' \\| 'upload'`              | `'blob'`              | `'blob'` returns `File` in `onExportDone`; `'upload'` streams directly to presigned URL.                       |\n| `initialProject`  | `{ otio: string }`                | `undefined`           | Optional previous OTIO document restored before initial assets.                                                |\n| `preferences`     | `unknown`                         | `undefined`           | Opaque state from a previous session (`onPreferencesChanged`).                                                 |\n| `readyTimeoutMs`  | `number`                          | `20000`               | Timeout in milliseconds before `onUnavailable` is called.                                                      |\n| `sandbox`         | `string`                          | `undefined`           | Custom iframe `sandbox` attribute value if needed.                                                             |\n| `allow`           | `string`                          | `DEFAULT_EMBED_ALLOW` | Iframe feature policy (`fullscreen; clipboard-write; autoplay; ...`).                                          |\n\n#### What an embedded session leaves out\n\nA session is one timeline in a workspace that is deleted when it closes, and the host owns\nstorage, credentials and the interface language. The editor therefore does not offer what would\nbe lost or would belong to the host:\n\n- **One timeline.** No new timelines, versions, \"save as\" copies or markdown notes, and the\n  session timeline cannot be deleted. Files keep the names and places the session gave them:\n  renaming and moving are not offered. `onChange` and `onExportDone` always describe\n  the timeline the host restores with `initialProject`.\n- **Export goes to the host.** The export panel's button delivers the render through\n  `onExportDone`, like `startExport()`, rather than into the session's `_export/` folder.\n- **`files` shows the session project only.** There is no workspace browser and no remote\n  content library.\n- **`settings` is limited to preferences the host can keep** (`onPreferencesChanged`): general\n  and interface options, snapping and the session's project format. The settings view is part\n  of the mobile layout only. Language, storage,\n  integrations, proxies, engine tuning and backups are not shown; the language comes from\n  `locale`.\n\n#### Event Callbacks\n\n| Callback               | Signature                                                                                  | Description                                                                    |\n| :--------------------- | :----------------------------------------------------------------------------------------- | :----------------------------------------------------------------------------- |\n| `onReady`              | `(capabilities: EmbedCapabilities) => void`                                                | Called after handshake confirms hardware capabilities (WebGPU, OPFS, etc.).    |\n| `onInitialized`        | `(info: EmbedInitializedInfo) => void`                                                     | Called once initial assets and timeline are loaded.                            |\n| `onChange`             | `(change: { dirty: boolean; otio: string }) => void`                                       | Emitted when timeline edits occur. Save `otio` to preserve user draft.         |\n| `onExportProgress`     | `(progress: { phase: string \\| null; progress: number }) => void`                          | Real-time rendering progress updates.                                          |\n| `onExportDone`         | `(result: FastcatEmbedExportResult) => void \\| Promise<void>`                              | Export completed. Read `file` before the returned promise settles — see below. |\n| `onAssetProgress`      | `(progress: { assetId: string; loadedBytes: number; totalBytes: number \\| null }) => void` | Asset buffering and fetch progress.                                            |\n| `onAssetUrlExpired`    | `(assetId: string) => Promise<string> \\| string`                                           | Invoked when signed asset URL expires mid-session. Return fresh URL to resume. |\n| `onPreferencesChanged` | `(preferences: unknown) => void`                                                           | Opaque user settings to store in host database.                                |\n| `onSttRequest`         | `(payload: unknown) => Promise<unknown>`                                                   | Handle speech-to-text proxy requests using host credentials.                   |\n| `onLlmRequest`         | `(payload: unknown) => Promise<unknown>`                                                   | Handle LLM/AI requests using host credentials.                                 |\n| `onError`              | `(error: { code: string; message: string }) => void`                                       | Error notification from editor.                                                |\n| `onRequestClose`       | `() => void`                                                                               | User clicked the close/exit button inside the editor.                          |\n| `onResizeRequest`      | `(request: { minHeightPx: number }) => void`                                               | Advisory request for more vertical viewport space.                             |\n| `onUnavailable`        | `(reason: string) => void`                                                                 | Handshake, initialization, or protocol validation failed.                      |\n| `onDebug`              | `(direction: 'in' \\| 'out', type: string, payload: unknown) => void`                       | Low-level message logger for debugging.                                        |\n\n---\n\n### Instance Methods (`FastcatEmbed`)\n\n```typescript\nexport interface FastcatEmbed {\n  /** The created HTMLIFrameElement mounted in container. */\n  readonly iframe: HTMLIFrameElement;\n  /** Triggers video rendering. */\n  startExport: (options?: { filename?: string; uploadUrl?: string }) => void;\n  /** Cancels an ongoing render. */\n  cancelExport: () => void;\n  /** Adds new assets into an active session. */\n  addAssets: (assets: EmbedAsset[]) => void;\n  /** Requests the editor to emit current timeline immediately (bypassing debounce). */\n  requestSave: () => void;\n  /** Gracefully tears down iframe and cleans up storage. */\n  dispose: () => Promise<void>;\n}\n```\n\n---\n\n## Direct Protocol Import\n\nIf you are building custom host adapters and only need types and message envelope utilities:\n\n```typescript\nimport {\n  EMBED_PROTOCOL_VERSION,\n  buildEmbedUrl,\n  createEmbedNonce,\n  isEmbedEnvelope,\n  type EmbedAsset,\n  type EmbedCapabilities,\n  type HostToEditorMessages,\n  type EditorToHostMessages,\n} from '@bozonx/fastcat-embed/protocol';\n```\n\n---\n\n## Security & Architecture\n\n1. **Origin Verification & Cryptographic Nonce**:\n   During initialization, `@bozonx/fastcat-embed` generates a 128-bit cryptographic nonce and supplies the host origin via URL hash parameters. Both the host and the editor verify each other's origins and nonce on every `postMessage` envelope.\n2. **Iframe Isolation**:\n   The host application does not require cross-origin isolation (COOP/COEP headers), making integration safe for host sites that load third-party scripts.\n3. **Hardware Acceleration**:\n   The editor utilizes WebGPU, WebCodecs, and OPFS for real-time timeline compositing and zero-lag rendering.\n\nThe lifecycle is `creating → ready → initialized → active/exporting → disposing → disposed`.\nHandshake and initialization failures move to `unavailable`; commands before `active` reject\nwith a stable `protocol-invalid-state` error. `dispose()` is idempotent and cancels outstanding\nsession work. Invalid payloads, unknown messages, and protocol version mismatches are reported\nas stable `protocol-*` errors rather than silently becoming a timeout.\n\nIn `blob` mode the exported `file` is backed by the editor's storage. It stays readable until the\npromise returned by `onExportDone` settles; the SDK then sends `export:ack` and the editor deletes\nits copy. Copy or upload the bytes inside the callback. An export that is never acknowledged is\nreleased after `EMBED_EXPORT_ACK_TIMEOUT_MS` (ten minutes) with a `protocol-timeout` error.\n`cancelExport()` also stops an export the user started from the editor's own export panel. A\nstopped export reaches `onError` as `export-cancelled`, a failed one as `export-failed`.\n\nAsset URLs and upload URLs must use HTTP(S), filenames must be plain basenames, and initial and\nadded assets are limited in count and size. When an asset has an `id`, the editor derives its\nstable storage path from that ID and uses `filename` only as the user-facing label. Supplying the\nsame assets alongside `initialProject` materializes their bytes without duplicating restored\nclips. Asset servers need CORS; `Range` support is strongly recommended, while a range-blind HTTP\n200 response is consumed once as a fallback. Use short-lived signed URLs and refresh them through\n`onAssetUrlExpired`; upload endpoints must accept `PUT`.\n\nThe SDK does not enable `sandbox` by default: an opaque sandbox origin breaks OPFS. If a host\nrequires it, test `allow-scripts allow-same-origin` plus the configured permissions in target\nbrowsers. The editor deployment must set its own `frame-ancestors`, `connect-src`, and\n`Permissions-Policy`; a client SDK cannot enforce response headers for another origin.\n\n---\n\n## Browser Support\n\n| Browser                      | Supported Versions | Notes                                               |\n| :--------------------------- | :----------------- | :-------------------------------------------------- |\n| **Google Chrome / Chromium** | 113+               | Full WebGPU + WebCodecs hardware acceleration       |\n| **Microsoft Edge**           | 113+               | Full WebGPU + WebCodecs hardware acceleration       |\n| **Apple Safari**             | 17+                | WebCodecs + WebGPU support                          |\n| **Mozilla Firefox**          | 120+               | WebCodecs enabled; WebGPU subject to platform flags |\n\n---\n\n## License\n\n[MIT](LICENSE) © FastCat Team\n","readmeFilename":""}