{"_id":"@agentfiber/voice-ui","_rev":"2-dc98a98b6ac5020eb4d154777266f866","name":"@agentfiber/voice-ui","dist-tags":{"latest":"0.1.1"},"versions":{"0.1.0":{"name":"@agentfiber/voice-ui","version":"0.1.0","license":"MIT","_id":"@agentfiber/voice-ui@0.1.0","maintainers":[{"name":"tereby","email":"a@appg.dev"}],"homepage":"https://agentfiber.org","bugs":{"url":"https://github.com/tereby/agentic-tv-ui/issues"},"dist":{"shasum":"974b8db68ded9dc9cb074fdf15b9bab81f6d3279","tarball":"https://registry.npmjs.org/@agentfiber/voice-ui/-/voice-ui-0.1.0.tgz","fileCount":11,"integrity":"sha512-zhDXymKLTjw5A6FfMbm0umJFfUMbAqldMaOSLfI80t/gOJW0rggycA7VbAq9mP/VOYFx/s3OPi73L9ilndvneg==","signatures":[{"sig":"MEUCIDIUz8R9ILQVKbbr98bjk1nr0yHiikgMGL3+8RMoCEjhAiEAppojf1FImEwSDSaJETBdHhhJ+alm4Q0kqep8TTVqV20=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":30371},"main":"./dist/index.js","type":"module","types":"./dist/index.d.ts","engines":{"node":">=20.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"},"./react":{"types":"./dist/react.d.ts","import":"./dist/react.js","default":"./dist/react.js"},"./canvas":{"types":"./dist/canvas.d.ts","import":"./dist/canvas.js","default":"./dist/canvas.js"}},"gitHead":"4728e79c917eb45f55540b7376e626d5e5e0b469","scripts":{"test":"vitest run","build":"tsc -p tsconfig.build.json","prepack":"pnpm build","prepare":"pnpm build","typecheck":"tsc --noEmit","smoke:pack":"node ../../scripts/smoke-agentfiber-voice-ui-pack.mjs"},"_npmUser":{"name":"tereby","email":"a@appg.dev"},"repository":{"url":"git+https://github.com/tereby/agentic-tv-ui.git","type":"git","directory":"packages/agentfiber-voice-ui"},"_npmVersion":"11.6.2","description":"Renderer-neutral voice orb and level visualisation primitives for AgentFiber.","directories":{},"sideEffects":false,"_nodeVersion":"22.18.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"jsdom":"25.0.1","react":"19.2.6","vitest":"2.1.5","react-dom":"19.2.6","typescript":"5.6.3","@types/react":"19.2.15","@types/react-dom":"19.2.3"},"peerDependencies":{"react":">=18"},"peerDependenciesMeta":{"react":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/voice-ui_0.1.0_1787831992325_0.3767997504840632","host":"s3://npm-registry-packages-npm-production"}},"0.1.1":{"_id":"@agentfiber/voice-ui@0.1.1","bugs":{"url":"https://github.com/dobreadi/agentfiber-voice/issues"},"dist":{"shasum":"0f2136d7357b7b393265ae1037c1ba127cc75a62","tarball":"https://registry.npmjs.org/@agentfiber/voice-ui/-/voice-ui-0.1.1.tgz","fileCount":11,"integrity":"sha512-cQ2Bw1fAzzfn+ZEr1ebqPe88QYXFVYqyf2neURBFiAu1LgXgPZy3cb9aEYRlGFwxFwyAlNeo73MB65LvHHRLOA==","signatures":[{"sig":"MEUCIQCvZyfvhCjNBflhQ+tCUcrhEI33LCWLgp1dTwG/vAQtfAIgEdNtA75sFVEs/SF9gvLSlVFKH5uKTE+cKI3PVuakccg=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIAC1pO/KSy9D1nO8SiE/3CLhJcxkYx4smrBafmTZRPLtAiEA45UiX30wrdxJwVt0112WAX8SdYP8qkIbW9ptdQnFvs0="}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@agentfiber%2fvoice-ui@0.1.1","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":30467},"main":"./dist/index.js","name":"@agentfiber/voice-ui","type":"module","_from":"file:/tmp/agentfiber-release-IDvJla/voice-ui/agentfiber-voice-ui-0.1.1.tgz","types":"./dist/index.d.ts","engines":{"node":">=20.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"},"./react":{"types":"./dist/react.d.ts","import":"./dist/react.js","default":"./dist/react.js"},"./canvas":{"types":"./dist/canvas.d.ts","import":"./dist/canvas.js","default":"./dist/canvas.js"}},"license":"MIT","scripts":{"test":"vitest run","build":"tsc -p tsconfig.build.json","prepack":"pnpm build","prepare":"pnpm build","typecheck":"tsc --noEmit","smoke:pack":"node ../../scripts/smoke-agentfiber-voice-ui-pack.mjs"},"version":"0.1.1","_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:0d02dcb3-a693-4a58-8604-b840c08e67a5"}},"homepage":"https://github.com/dobreadi/agentfiber-voice/tree/main/packages/agentfiber-voice-ui#readme","_resolved":"/tmp/agentfiber-release-IDvJla/voice-ui/agentfiber-voice-ui-0.1.1.tgz","_integrity":"sha512-cQ2Bw1fAzzfn+ZEr1ebqPe88QYXFVYqyf2neURBFiAu1LgXgPZy3cb9aEYRlGFwxFwyAlNeo73MB65LvHHRLOA==","repository":{"url":"git+https://github.com/dobreadi/agentfiber-voice.git","type":"git","directory":"packages/agentfiber-voice-ui"},"_npmVersion":"11.6.2","description":"Renderer-neutral voice orb and level visualisation primitives for AgentFiber.","directories":{},"maintainers":[{"name":"tereby","email":"a@appg.dev"}],"sideEffects":false,"_nodeVersion":"24.20.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"jsdom":"25.0.1","react":"19.2.6","vitest":"2.1.5","react-dom":"19.2.6","typescript":"5.6.3","@types/react":"19.2.15","@types/react-dom":"19.2.3"},"peerDependencies":{"react":">=18"},"peerDependenciesMeta":{"react":{"optional":true}},"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/voice-ui_0.1.1_1789573875069_0.880855856080202"}}},"time":{"created":"2026-08-27T11:59:52.169Z","modified":"2026-09-16T15:51:15.570Z","0.1.0":"2026-08-27T11:59:52.471Z","0.1.1":"2026-09-16T15:51:15.198Z"},"bugs":{"url":"https://github.com/dobreadi/agentfiber-voice/issues"},"license":"MIT","homepage":"https://github.com/dobreadi/agentfiber-voice/tree/main/packages/agentfiber-voice-ui#readme","repository":{"url":"git+https://github.com/dobreadi/agentfiber-voice.git","type":"git","directory":"packages/agentfiber-voice-ui"},"description":"Renderer-neutral voice orb and level visualisation primitives for AgentFiber.","maintainers":[{"name":"tereby","email":"a@appg.dev"}],"readme":"# `@agentfiber/voice-ui`\n\nPortable, policy-free voice capture visualisation for AgentFiber products. The package provides a\nliquid orb as renderer-neutral math and GLSL, a raw WebGL canvas controller, and an\noptional React layer with both canvas and DOM/SVG choices.\n\nIt does **not** capture audio, transcribe speech, parse intents, choose actions, or map product\nstatuses. Those decisions belong to the ASR adapter and product host.\n\n## Install\n\n```sh\nnpm install @agentfiber/voice-ui\n```\n\nInstall React only when using the React entry point:\n\n```sh\nnpm install @agentfiber/voice-ui react\n```\n\n## Choose an entry point\n\n- `@agentfiber/voice-ui` — pure modes, scalar envelope/math helpers, and WebGL1/GLES2 shader\n  sources. Use this for a custom renderer such as Pixi.\n- `@agentfiber/voice-ui/canvas` — a raw `<canvas>` WebGL controller. It has no framework runtime\n  dependency and fails closed with `null` when WebGL is unavailable.\n- `@agentfiber/voice-ui/react` — `VoiceOrbCanvas` plus `VoiceLevelBars`, a bounded SVG fallback that\n  has no animation loop.\n\n## Canvas\n\n```ts\nimport { mountVoiceOrb } from \"@agentfiber/voice-ui/canvas\";\n\nconst canvas = document.querySelector(\"canvas\");\nconst orb = canvas instanceof HTMLCanvasElement ? mountVoiceOrb(canvas) : null;\n\norb?.setMode(\"reactive\");\norb?.setLevel(0.65);\n\n// When capture or the surface closes:\norb?.setMode(\"off\");\norb?.destroy();\n```\n\n`setLevel` accepts a normalized per-chunk peak. The controller folds peaks into a short fixed RMS\nwindow and applies the shared fast-attack/slow-decay envelope. It runs requestAnimationFrame only\nwhile its mode is active and the document is visible. `reducedMotion: true` paints one calm,\nnon-reactive frame instead of keeping an animation loop alive.\n\n## React\n\n```tsx\nimport { VoiceLevelBars, VoiceOrbCanvas } from \"@agentfiber/voice-ui/react\";\n\nexport function CaptureIndicator({ level }: { level: number }) {\n  return (\n    <div>\n      <VoiceOrbCanvas\n        mode=\"reactive\"\n        level={level}\n        reducedMotion={window.matchMedia(\"(prefers-reduced-motion: reduce)\").matches}\n        aria-label=\"Listening\"\n      />\n      <VoiceLevelBars level={level} aria-label=\"Microphone input level\" />\n    </div>\n  );\n}\n```\n\nThe application owns mode selection, copy, layout, permission UI, and fallbacks. If WebGL is not a\ngood fit for the target, use `VoiceLevelBars` alone or build another renderer from the root exports.\n\n## Product authority\n\nApplications retain status-to-mode mapping, scheduling, layout, and all intent/dispatch policy. Reusing a visual component gives it no authority to execute a transcript or proposal.\n\nFor capture and transcription contracts, use [`@agentfiber/asr`](../agentfiber-asr/README.md). For\nintent contracts and dispatch, use [`@agentfiber/voice`](../agentfiber-voice/README.md).\n\n## Validate a checkout\n\nFrom the repository root with Node 22.18.0 and pnpm 10.0.0:\n\n```sh\npnpm --filter @agentfiber/voice-ui test\npnpm --filter @agentfiber/voice-ui typecheck\npnpm --filter @agentfiber/voice-ui smoke:pack\n```\n\nThe packed-artifact smoke uses `npm pack`, rejects local dependency protocols, checks the public\npeer boundary, installs the tarball in a clean consumer, and verifies every export plus TypeScript\ndeclarations. Passing it is release evidence; it is not evidence that a version was published.\n\nSee the [voice package index](../../README.md) for related packages.\n","readmeFilename":"README.md"}