Merge Workstream F: unlocks/inventory UI + sigil designer + listening tool
This commit is contained in:
@@ -256,6 +256,10 @@ function SeanceSession({ username }: { username: string }) {
|
||||
{t('nav.codex')}
|
||||
</Link>
|
||||
|
||||
<Link to="/inventory" className="seance-codex-link">
|
||||
{t('nav.inventory', { defaultValue: 'inventory' })}
|
||||
</Link>
|
||||
|
||||
<span className="seance-user" title={username}>
|
||||
{username}
|
||||
</span>
|
||||
@@ -469,7 +473,11 @@ function WirePanel() {
|
||||
|
||||
function EvpPanel() {
|
||||
const { sendAnomaly } = useSeance()
|
||||
const { user } = useAuth()
|
||||
const { t } = useTranslation()
|
||||
// "listening_tool" unlock (GET /auth/me's `unlocks`) lowers the EVP
|
||||
// detector's threshold so fainter deviations register — see lib/evp.ts.
|
||||
const hasListeningTool = user?.unlocks?.includes('listening_tool') ?? false
|
||||
const [listening, setListening] = useState(false)
|
||||
const [pending, setPending] = useState(false)
|
||||
const [denied, setDenied] = useState(false)
|
||||
@@ -531,7 +539,7 @@ function EvpPanel() {
|
||||
setBandDb(Number.isFinite(peak) ? peak : null)
|
||||
}
|
||||
},
|
||||
})
|
||||
}, { hasListeningTool })
|
||||
if (listenerRef.current === listener) setListening(true)
|
||||
} catch {
|
||||
if (listenerRef.current === listener) listenerRef.current = null
|
||||
|
||||
Reference in New Issue
Block a user