From 8dca169b833226459675aba725fe2badc782748f Mon Sep 17 00:00:00 2001 From: dharaneesh-r Date: Tue, 6 Oct 2026 20:58:15 +0530 Subject: [PATCH] updates on the logic on the skills and settings tab --- .../doormile/AgentOperationsBanner.jsx | 10 ++++++-- src/pages/doormile/settings/Settings.jsx | 21 ++++++++++++++--- tests/lib/AgentOperationsBanner.test.jsx | 23 +++++++++++++++++++ tests/lib/agentClickThrough.test.jsx | 2 ++ tests/lib/settingsTabs.test.js | 23 +++++++++++++++++++ 5 files changed, 74 insertions(+), 5 deletions(-) create mode 100644 tests/lib/settingsTabs.test.js diff --git a/src/components/doormile/AgentOperationsBanner.jsx b/src/components/doormile/AgentOperationsBanner.jsx index e30c2c1..84d3da8 100644 --- a/src/components/doormile/AgentOperationsBanner.jsx +++ b/src/components/doormile/AgentOperationsBanner.jsx @@ -10,6 +10,8 @@ import { SkillRegistry } from '@/lib/assistant/skills/SkillRegistry'; import { wallClockNow } from '@/lib/assistant/agent/signals'; import { executeProposal, canExecuteProposal } from '@/lib/assistant/agent/actions'; import { Button } from '@/components/ui/button'; +import { useAuth } from '@/lib/AuthContext'; +import { canOnboardClients } from '@/lib/clientOnboarding'; /** * AgentOperationsBanner @@ -40,6 +42,10 @@ export default function AgentOperationsBanner({ className = '' }) { const navigate = useNavigate(); + // The Skills & Tools tab is the owner login's only; nobody else gets a + // button into it. + const { user, isClient } = useAuth(); + const canConfigure = canOnboardClients(user, isClient); // Which settings the rules are running on — the registry's, or the code // defaults while it is unreachable. Said on screen, so a tuned threshold is // never assumed when it is not in force. @@ -141,7 +147,7 @@ export default function AgentOperationsBanner({
- + }