diff --git a/apps/web/src/components/import-from-deco-dialog.tsx b/apps/web/src/components/import-from-deco-dialog.tsx index 25e880758e..99a030deef 100644 --- a/apps/web/src/components/import-from-deco-dialog.tsx +++ b/apps/web/src/components/import-from-deco-dialog.tsx @@ -312,12 +312,6 @@ export function ImportFromDecoDialog({ themeColor: "#22C55E", slug, pinnedViews: [ - { - connectionId: connId, - toolName: "fetch_assets", - label: "Assets", - icon: null, - }, { connectionId: connId, toolName: "get_monitor_data", diff --git a/apps/web/src/components/settings/navigation-settings.tsx b/apps/web/src/components/settings/navigation-settings.tsx index a10bc85027..e1312a8aa1 100644 --- a/apps/web/src/components/settings/navigation-settings.tsx +++ b/apps/web/src/components/settings/navigation-settings.tsx @@ -1,16 +1,12 @@ import { toast } from "sonner"; import { Switch } from "@decocms/ui/components/switch.tsx"; -import { LayoutLeft, Package } from "@untitledui/icons"; +import { LayoutLeft } from "@untitledui/icons"; import { SettingsCard, SettingsCardItem, SettingsSection, } from "@/components/settings/settings-section"; -import { - useNavV2, - useOrgFlag, - useSetOrgFlag, -} from "@/hooks/use-organization-settings"; +import { useNavV2, useSetOrgFlag } from "@/hooks/use-organization-settings"; import { useT } from "@/i18n/use-t.ts"; /** @@ -22,7 +18,6 @@ import { useT } from "@/i18n/use-t.ts"; export function NavigationSettings() { const t = useT(); const enabled = useNavV2(); - const nativeAssetsEnabled = useOrgFlag("native_assets_tab"); const setFlag = useSetOrgFlag(); return ( } /> - } - title={t("settings.navigation.nativeAssetsTitle")} - description={t("settings.navigation.nativeAssetsDescription")} - action={ - - setFlag.mutate("native_assets_tab", next, { - onError: () => - toast.error(t("settings.navigation.updateError")), - }) - } - /> - } - /> ); diff --git a/apps/web/src/i18n/en/settings.ts b/apps/web/src/i18n/en/settings.ts index 274dd081ab..be89be0ade 100644 --- a/apps/web/src/i18n/en/settings.ts +++ b/apps/web/src/i18n/en/settings.ts @@ -446,9 +446,6 @@ export const settings = { "settings.navigation.navV2Title": "First-class navigation", "settings.navigation.navV2Description": "The sidebar lists destinations (Reports, Library, Tasks) instead of chats, and the chat list moves to the top of the chat panel. On by default for report organizations.", - "settings.navigation.nativeAssetsTitle": "Native Assets tab", - "settings.navigation.nativeAssetsDescription": - "Show a native Assets tab that browses the site's associated storage bucket, instead of the external admin view. Appears only on sites that have a bucket configured.", "settings.orgGeneral.organization": "Organization", "settings.mainAgent.title": "Main agent", "settings.mainAgent.description": diff --git a/apps/web/src/i18n/pt-br/settings.ts b/apps/web/src/i18n/pt-br/settings.ts index dcd1326a5d..dd01de8f7a 100644 --- a/apps/web/src/i18n/pt-br/settings.ts +++ b/apps/web/src/i18n/pt-br/settings.ts @@ -465,9 +465,6 @@ export const settings = { "settings.navigation.navV2Title": "Navegação de primeira classe", "settings.navigation.navV2Description": "A barra lateral lista destinos (Relatórios, Biblioteca, Tarefas) em vez de chats, e a lista de chats vai para o topo do painel de chat. Ativada por padrão em organizações de relatório.", - "settings.navigation.nativeAssetsTitle": "Aba de Assets nativa", - "settings.navigation.nativeAssetsDescription": - "Mostra uma aba de Assets nativa que navega o bucket de armazenamento associado ao site, em vez da view externa de admin. Aparece s\u00f3 em sites que t\u00eam um bucket configurado.", "settings.orgGeneral.organization": "Organiza\u00e7\u00e3o", "settings.mainAgent.title": "Agente principal", "settings.mainAgent.description": diff --git a/apps/web/src/layouts/main-panel-tabs/use-main-panel-tabs.ts b/apps/web/src/layouts/main-panel-tabs/use-main-panel-tabs.ts index f836e38078..c6963f366a 100644 --- a/apps/web/src/layouts/main-panel-tabs/use-main-panel-tabs.ts +++ b/apps/web/src/layouts/main-panel-tabs/use-main-panel-tabs.ts @@ -68,11 +68,7 @@ import { import { useCapability } from "@/hooks/use-capability"; import { useFileConfigsQuery } from "@/hooks/use-file-configs"; import { matchSiteSlugConfig } from "@/components/file-picker/match-site-slug-config"; -import { - useNavV2, - useOrgFlag, - useReportsOnly, -} from "@/hooks/use-organization-settings"; +import { useNavV2, useReportsOnly } from "@/hooks/use-organization-settings"; import { useT } from "@/i18n/use-t.ts"; export type AgentTabDef = { @@ -293,19 +289,18 @@ export function useMainPanelTabs(ctx: { const showContentTab = hasEditableDecoContent(decofile, meta); /** - * Assets is a per-site tab behind the `native_assets_tab` org flag: it shows - * only when the flag is on AND an S3 bucket is associated to this site's slug - * (managed `deco-assets-` or a BYOB bucket). Uses the non-suspense - * configs query so the bar never blocks on the bucket list. + * Assets is a per-site tab: it shows whenever an S3 bucket is associated to + * this site's slug (managed `deco-assets-` or a BYOB bucket). Uses the + * non-suspense configs query so the bar never blocks on the bucket list. */ - const nativeAssetsTabEnabled = useOrgFlag("native_assets_tab"); const siteSlug = (entity?.metadata as { siteSlug?: string | null } | undefined)?.siteSlug ?? null; const fileConfigsQuery = useFileConfigsQuery(); - const showAssetsTab = - nativeAssetsTabEnabled && - !!matchSiteSlugConfig(fileConfigsQuery.data?.configs ?? [], siteSlug); + const showAssetsTab = !!matchSiteSlugConfig( + fileConfigsQuery.data?.configs ?? [], + siteSlug, + ); const { activeTab: rawActiveTab, mainOpen: rawMainOpen } = resolveActiveTabAndOpen({ @@ -450,6 +445,8 @@ export function useMainPanelTabs(ctx: { }); } for (const pv of pinnedViews) { + // Retired admin-MCP view, now the native Assets tab: drop stale pins. + if (pv.toolName === "fetch_assets") continue; const id = formatPinnedViewTabId(pv.connectionId, pv.toolName); pinnedTabMap.set(id, { id, diff --git a/packages/shared/src/organization/schema.ts b/packages/shared/src/organization/schema.ts index 865a0df608..9cd3e1218f 100644 --- a/packages/shared/src/organization/schema.ts +++ b/packages/shared/src/organization/schema.ts @@ -173,12 +173,6 @@ export const OrgFlagsSchema = z.object({ .describe( "When a report import creates a task board item without an assignee, delegate it to the Super Agent automatically instead of leaving it unassigned.", ), - native_assets_tab: z - .boolean() - .optional() - .describe( - "Show the native Assets tab (a browser over the site's associated S3 bucket) instead of relying on the external admin-MCP fetch_assets view. Off by default while in development.", - ), }); export type OrgFlags = z.infer; diff --git a/packages/shared/src/tools/tool-io.ts b/packages/shared/src/tools/tool-io.ts index 7fe12fba7d..f6617d9630 100644 --- a/packages/shared/src/tools/tool-io.ts +++ b/packages/shared/src/tools/tool-io.ts @@ -127,7 +127,6 @@ export interface StudioToolIO { auto_merge?: boolean | undefined; cheap_reviewer_model?: boolean | undefined; auto_assign_report_tasks_to_super_agent?: boolean | undefined; - native_assets_tab?: boolean | undefined; } | null | undefined; @@ -196,7 +195,6 @@ export interface StudioToolIO { auto_merge?: boolean | undefined; cheap_reviewer_model?: boolean | undefined; auto_assign_report_tasks_to_super_agent?: boolean | undefined; - native_assets_tab?: boolean | undefined; } | undefined; main_agent_id?: string | null | undefined; @@ -265,7 +263,6 @@ export interface StudioToolIO { auto_merge?: boolean | undefined; cheap_reviewer_model?: boolean | undefined; auto_assign_report_tasks_to_super_agent?: boolean | undefined; - native_assets_tab?: boolean | undefined; } | null | undefined;