Skip to content

Commit 8fe4eaf

Browse files
fix(app-shell)!: Home no longer offers Build with AI or Build an app (#37249)
repo:objectstack#4 · os-justin · session_01QSeKYnagJvGbCtNg2PhvgW Fixes #37227 Clause-②: yes (narrowing) Metadata-protocol: none Skills-docs: none — no skill or doc teaches the two Home entries or the phone welcome copy; `git grep` of `skills/` and `content/docs/` finds none of them or the retired keys ## 维护者速读 - 手机首页、以及电脑上「暂无应用」页面,不再出现「用 AI 搭建」和「搭建应用」两个入口;部署了构建智能体时,手机上「暂无应用」的欢迎语改为普通文案,不再承诺「用 AI 搭建」。「新建空白应用」「从模板开始」和其它入口照旧。 - 落实维护者「两个入口一并去掉」的裁决,以及席位关于欢迎文案的裁决,属于 Studio 首页收口这条主线。 - 若出错,用户会看到缺了一个本该保留的入口、删掉的入口又出现,或欢迎文案不对;改动只删不加,撤回即可恢复。 - 无。 ## What changes - `HomePage.tsx` - The greeting row's agent-present build chip, 「Build an app」 (to bare `/studio`), is gone. The no-agent form, 「New blank app」 (`home.build.inStudio`), is untouched: label, key, condition and target are exactly as on main. - `HomeAiActions` no longer draws 「Build with AI」. 「Ask AI」 keeps exactly the gate it had: hidden for a maker the build agent serves (the cloud#1674 convergence), shown otherwise. - The phone zero-app admin welcome, where the build agent is deployed, now shows `home.noAppsTitle` and the existing NoBuild/NoAi description, not 「Build your business system with AI」 and "Describe your business in one sentence — AI generates …". Without the build agent the welcome is unchanged. No new key is added. - The desktop no-apps empty state is not changed here. Since #37166 the shared 「Add app」 list holds no 「Build with AI」 door, so the doors are `new-in-studio`, `template`, `marketplace`. The page-side filter from the earlier head was a no-op after the merge and is removed. - Doc comments that described the two entries are rewritten. - `QuickActions.tsx`: comment only (the component has no call site). - Retired from all eleven locale packs, each released in 18.6.0 and with zero readers on the merged tree: `home.build.title`, `home.buildWithAI` (its last reader was this page's CTA; #37166 removed the sidebar's) and `home.welcomeAdminDescription`. `home.build.inStudio`, `home.welcome` and `home.build.noCapability` stay; they are still read. - Changeset `37227-home-drop-build-entries.md`: `Clause-②: yes (narrowing)`, the three keys under 「Removed translation keys」, `not-required (no-migration-prescription)` disposition. ## Overlap and ordering Answering the landed notice 7169175122 (body refreshed 2026-11-25T19:21Z): #37166 merged first (fbb62e1). This branch merged `origin/main` (merge commit b1f7c48, no rebase). Two test files conflicted and keep both PRs' pins: - `HomePage.desktopNoApps-36732`: #37166's doors list `[new-in-studio, template, marketplace]` and its Setup → Packages target are kept. This PR adds two assertions: no 「Build with AI」 label and no bare `/studio` door. - `HomePage.noAgentsBuildChip-26614`: #37166's `setupPair` state and its Studio-only author case (to `~all`) are kept, beside this PR's `answered` latch and `catalogAnswered()`. `overlap-check` at the new head: VERDICT clean (origin/main; no open PR shares a file). ## Tests - `HomePage.noAgentsBuildChip-26614`: with the build agent in the catalog, no build chip of either form, for a maker and for a session that may not author, and for the legacy build-agent id. Each absence is read after the catalog stand-in has answered. - `HomePage.desktopNoApps-36732`: as above. - `HomePage.authoringCapabilityGate`: the gate acts on 「Start with a template」. The capability-present case pins both entries absent. The phone zero-app welcome pins `home.noAppsTitle` + NoAi and no `home.welcome`. - `HomePage.phoneTapTargets-29147`: the phone-target case pins both entries absent. A new top-level describe covers the phone zero-app admin welcome: build agent → `noAppsTitle` + NoAi; build + ask → `noAppsTitle` + NoBuild; CONTROL with no agent → `home.welcome` + NoAi. - `HomePage.greetingAndApps-12601`: build-chip assertions move to the template chip. - `HomePage.aiStudioDisabled`, `HomePage.marketplaceDisabled`: their catalog is a custom agent, so the chip these flags gate is 「New blank app」. ## Acceptance notes - `homeAffordancesFollowDeclaration-7256`, `landingHomeParity-7256`, `homeRecoveryRedirectsFollowDeclaration-7373`, `useHomePath.test`, `homePath.test` and `workspaceAdminPositions-5389` mention 「Build an app」 only in prose about a past defect, and assert nothing about the chip. - The earlier head's gap note (no button on an aiStudio + build-agent + no-marketplace no-apps state) is closed by #37166: 「New blank app」 now shows there on every deployment with AI Studio. ## Verification Two-minute check: run `pnpm --dir ui exec vitest run packages/app-shell/src/console/home/`. All files pass. No assertion finds `home-build-app` or `home-build-with-ai` on the page, and the phone zero-app welcome with the build agent reads `«home.noAppsTitle»`. Read first, by risk: 1. `HomePage.tsx`, the admin zero-app welcome: the title and description branches. 2. `HomePage.tsx` `HomeAiActions`: the early return `if (!askAvailable || maker) return null`, which keeps the 「Ask AI」 gate byte-equivalent. 3. The two merge-resolved test files (above). <details><summary>Ablations on the merged head (scripts/ablation-replace.mjs; the tests import HomePage from src)</summary> Every mutation was checked on disk (anchor 1 to 0, blob changed). Every restore was checked: blob == HEAD 1f30b19, `git diff HEAD` empty. Suite: phoneTapTargets, authoringCapabilityGate, noAgentsBuildChip, greetingAndApps. - Old welcome description restored (`home.welcomeAdminDescription` when the build agent is deployed): 3 failed / 54 passed. - Old welcome title restored (`home.welcome`): 3 failed / 54 passed. - 「Build an app」 chip restored: 8 failed / 49 passed. - 「Build with AI」 restored in `HomeAiActions`: 4 failed / 53 passed. </details> <details><summary>Local gates and tests (head 7e70756)</summary> - `vitest run` over `packages/app-shell/src/console/home/`, `packages/app-shell/src/layout/` (incl. SidebarAppMenu-36112), `packages/app-shell/src/hooks/`, `packages/i18n/` and `check-i18n-call-site-keys`: Test Files 423 passed (423); Tests 4858 passed, 13 skipped. VERDICT command-exit 0. - `pnpm --filter @object-ui/i18n --filter @object-ui/app-shell run type-check`: both Done. VERDICT command-exit 0. - `dispatch-gates --commands`: 41 families, plus `check:changeset-fixed`, all exit 0. `--ran`: "41 run, 0 NOT-MEASURED (a DERIVED zero)". - Dogfood battery: head 7e70756; VERDICT command-exit 0; Test Files 487 passed, 3 skipped (490); Tests 4128 passed, 68 skipped (4196); no failures. </details> --- _Generated by [Claude Code](https://claude.ai/code/session_01QSeKYnagJvGbCtNg2PhvgW)_ --------- Co-authored-by: Claude <noreply@anthropic.com>
1 parent 9981f27 commit 8fe4eaf

21 files changed

Lines changed: 268 additions & 187 deletions
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
---
2+
'@object-ui/app-shell': patch
3+
'@object-ui/i18n': patch
4+
---
5+
6+
fix(app-shell)!: Home no longer offers 「Build with AI」 or 「Build an app」
7+
8+
Clause-②: yes (narrowing)
9+
Metadata-protocol: none
10+
11+
<!-- adr-0087: not-required (no-migration-prescription) the removed operands are two Home entry points, one welcome sentence and three translation keys of the console's own language packs; no packages/spec schema, registered node type, stored row or ADR-0087 conversion surface names them, and no key, value or default a metadata author can write changes, so there is nothing for objectstack migrate meta to rewrite -->
12+
13+
**BREAKING** for a deployment that overrides one of the removed translation keys below: the override no longer applies, because nothing reads the key any more.
14+
15+
The home page shows on a phone, and on a desktop as the 「No applications yet」 screen when you have no app. On it:
16+
17+
- **「Build with AI」** is gone: the button shown beside the greeting, and in the phone's 「No applications yet」 welcome, when the build agent is deployed.
18+
- **「Build an app」** is gone: the chip beside the greeting that opened Studio when the build agent is deployed.
19+
- **The phone welcome makes no AI-building promise any more.** On a phone with no app yet, an administrator on a deployment with the build agent was welcomed with 「Build your business system with AI」 and "Describe your business in one sentence — AI generates …". That welcome now reads 「No applications yet」 with the description other deployments show: set up your first application from the Administration menu, plus the AI-assistant sentence where an ask agent is deployed. Deployments without the build agent keep their welcome unchanged.
20+
21+
Everything else stays. 「Start with a template」 is still there, and so is 「New blank app」 where it showed before. 「Ask AI」 shows exactly where it did before.
22+
23+
Nothing to do on upgrade, unless your deployment overrides one of the keys below.
24+
25+
## Removed translation keys
26+
27+
Removed from every language pack of `@object-ui/i18n` (ar, de, en, es, fr, ja, ko, pt-BR, ru, zh-Hans, zh-Hant). Each shipped in 18.6.0.
28+
29+
- `home.build.title` (en: "Build an app")
30+
- `home.buildWithAI` (en: "Build with AI")
31+
- `home.welcomeAdminDescription` (en: "Describe your business in one sentence — AI generates the objects, screens, APIs and agent tools. Or set things up yourself from the menu on the left.")

‎ui/packages/app-shell/src/console/home/HomePage.tsx‎

Lines changed: 65 additions & 83 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,9 @@
2121
* From 768 px up the page is retired (objectstack#36732): the host redirects
2222
* `/home` into an app whenever the viewer has a product app, so a desktop
2323
* reaches this page only with none, and draws the no-apps empty state
24-
* ({@link DesktopNoApps}): build with AI, start from a template, the app
25-
* marketplace, for the viewers who may add an app.
24+
* ({@link DesktopNoApps}): a new blank app, start from a template, the app
25+
* marketplace, for the viewers who may add an app. Neither 「Build with AI」
26+
* nor 「Build an app」 is drawn on this page (objectstack#37227).
2627
*
2728
* @module
2829
*/
@@ -83,7 +84,7 @@ import {
8384
TooltipTrigger,
8485
cn,
8586
} from '@object-ui/components';
86-
import { Sparkles, MessageSquareText, Hammer, LayoutGrid } from 'lucide-react';
87+
import { MessageSquareText, Hammer, LayoutGrid } from 'lucide-react';
8788
import { usePendingDrafts } from '../../preview/usePendingDrafts.js';
8889
import { usePublishAllDrafts } from '../../preview/usePublishAllDrafts.js';
8990
import { fetchPackages } from '../../views/studio-design/packages-io.js';
@@ -93,21 +94,21 @@ import { useNewPackageDoorPath } from '../../hooks/useNewPackageDoorPath.js';
9394
import { useOpenAssistant } from '../../layout/chatDockControl.js';
9495
import { isProductApp } from '../../utils/homePath.js';
9596
import { useAddAppEntries, useMayAddApp } from '../../hooks/useAddAppEntries.js';
96-
import { studioLandingPath } from '../../views/studio-design/studioAddress.js';
9797
import { catalogServesBuild } from '../../hooks/surfaceAgent.js';
9898

9999
/**
100100
* Which AI home CTAs to surface, driven by the live agent catalog (the single
101101
* source of truth) — gated PER agent, because the community edition can be in
102102
* any of three states:
103103
* - `askAvailable` — a data/query agent (`ask`/`data_chat`) is deployed → "Ask AI".
104-
* - `buildAvailable` — a build/authoring agent is deployed → "Build with AI".
105-
* That's a cloud / AI-Studio feature, ABSENT on open-source builds.
104+
* - `buildAvailable` — a build/authoring agent is deployed. That's a cloud /
105+
* AI-Studio feature, ABSENT on open-source builds. Home draws no build
106+
* button for it (objectstack#37227); it withholds "Ask AI" from a maker.
106107
* - `aiEnabled` — any agent at all (AI is on here in some form).
107108
* - `buildServed` — the catalog lists the build agent itself, alias-aware
108-
* (`catalogServesBuild`, objectstack#36969): what the "Build an app" chip
109-
* promises. Where in-app building is closed the catalog keeps `ask` and
110-
* drops `build`, so `aiEnabled` alone would promise a build nothing serves.
109+
* (`catalogServesBuild`, objectstack#36969). Where in-app building is
110+
* closed the catalog keeps `ask` and drops `build`; there the builder chip
111+
* takes its Studio form, "New blank app".
111112
* All false while the catalog loads or when AI isn't enabled, so nothing
112113
* flashes and no AI CTA appears where there's no agent to back it.
113114
*
@@ -143,8 +144,8 @@ function useHomeAiAvailability(): {
143144

144145
/**
145146
* One 32 px builder chip at the greeting's right (objectui#12601): "Start with
146-
* a template" outlined, "Build an app" on the soft primary tint with its icon in
147-
* the primary colour. Admins only — the caller decides that.
147+
* a template" outlined, "New blank app" on the soft primary tint with its icon
148+
* in the primary colour. Admins only — the caller decides that.
148149
*
149150
* Disabled (not hidden) when the session cannot use it: a vanished front door
150151
* reads as a broken page, while a dimmed one explains the deployment's
@@ -286,20 +287,17 @@ function NoAppsAddActions() {
286287
}
287288

288289
/**
289-
* Home AI call-to-action(s). "Build with AI" only when a build agent is
290-
* deployed AND the session may author metadata; "Ask AI" only when a
291-
* data/query agent is deployed. Renders nothing when neither exists (AI off, or
292-
* only custom agents — those are reachable via the assistant launcher / FAB).
293-
* `layout="stack"` is used by the empty-state; the hero uses the default inline
294-
* row. Availability is passed in so the host fetches the catalog once.
290+
* Home's AI call-to-action: "Ask AI", only when a data/query agent is
291+
* deployed. Renders nothing when none is (AI off, or only custom agents —
292+
* those are reachable via the assistant launcher / FAB). `layout="stack"` is
293+
* used by the empty-state; the hero uses the default inline row. Availability
294+
* is passed in so the host fetches the catalog once.
295295
*
296-
* "Build with AI" routes to the AI authoring studio, whose output is
297-
* draft metadata nobody without `manage_metadata` can publish — so it is one of
298-
* the "any other metadata-authoring CTA" the objectstack#8270 ruling covers.
299-
* It is HIDDEN rather than disabled: unlike the builder chips it is not the
300-
* page's structural front door, the chips beside it already carry the reason,
301-
* and a disabled hero button next to a live "Ask AI" would read as a transient
302-
* failure. "Ask AI" is read-only and never gated.
296+
* There is no "Build with AI" button here any more (objectstack#37227): the
297+
* maintainer ruled it off the home page. "Ask AI" keeps the gate it had beside
298+
* it, the cloud#1674 maker convergence below: a session for which the build
299+
* agent is deployed and that may author metadata is not offered "Ask AI",
300+
* since the ask agent would converge that maker straight back onto build.
303301
*/
304302
function HomeAiActions({
305303
askAvailable,
@@ -313,41 +311,29 @@ function HomeAiActions({
313311
buildAvailable: boolean;
314312
canAuthorMetadata: boolean;
315313
/** objectstack#34608 — opens the console's chat drawer on this agent, in place. */
316-
openAssistant: (agent: 'build' | 'ask') => void;
314+
openAssistant: (agent: 'ask') => void;
317315
t: (key: string, opts?: any) => string;
318316
layout?: 'row' | 'stack';
319317
}) {
320-
const showBuild = buildAvailable && canAuthorMetadata;
321-
if (!askAvailable && !showBuild) return null;
318+
const maker = buildAvailable && canAuthorMetadata;
319+
if (!askAvailable || maker) return null;
322320
const container =
323321
layout === 'stack'
324322
? 'mt-6 flex flex-col sm:flex-row items-center gap-3'
325323
: 'flex shrink-0 items-center gap-2';
326-
// In the greeting row the buttons take the builder chips' 32 px height;
324+
// In the greeting row the button takes the builder chips' 32 px height;
327325
// below `sm` both layouts take the 44 px touch target.
328326
const buttonClass = layout === 'stack' ? 'max-sm:h-11' : 'h-8 px-3 text-sm max-sm:h-11';
329327
return (
330328
<div className={container}>
331-
{showBuild && (
332-
<Button onClick={() => openAssistant('build')} className={buttonClass} data-testid="home-build-with-ai">
333-
<Sparkles className="mr-2 h-4 w-4" />
334-
{t('home.buildWithAI', { defaultValue: 'Build with AI' })}
335-
</Button>
336-
)}
337-
{/* cloud#1674 maker convergence: with the build CTA shown, "Ask AI" is
338-
not a second door — the build composer answers data questions too
339-
(data superset since cloud#1673), and the ask agent would converge a
340-
maker straight back onto build. Non-authoring sessions keep it. */}
341-
{askAvailable && !showBuild && (
342-
<Button
343-
onClick={() => openAssistant('ask')}
344-
className={buttonClass}
345-
data-testid="home-ask-ai"
346-
>
347-
<MessageSquareText className="mr-2 h-4 w-4" />
348-
{t('home.askAI', { defaultValue: 'Ask AI' })}
349-
</Button>
350-
)}
329+
<Button
330+
onClick={() => openAssistant('ask')}
331+
className={buttonClass}
332+
data-testid="home-ask-ai"
333+
>
334+
<MessageSquareText className="mr-2 h-4 w-4" />
335+
{t('home.askAI', { defaultValue: 'Ask AI' })}
336+
</Button>
351337
</div>
352338
);
353339
}
@@ -470,7 +456,7 @@ export function HomePage({ checklist }: HomePageProps = {}) {
470456
// objectstack#34608 — the Home AI buttons open the same right-side drawer
471457
// every console page has (in place, no navigation).
472458
const openAssistant = useOpenAssistant();
473-
const openHomeAssistant = (agent: 'build' | 'ask') => openAssistant({ agent });
459+
const openHomeAssistant = (agent: 'ask') => openAssistant({ agent });
474460
const { t, language } = useObjectTranslation();
475461
const metadata = useMetadata();
476462
const { apps, loading } = metadata;
@@ -516,9 +502,9 @@ export function HomePage({ checklist }: HomePageProps = {}) {
516502
// every app mount) is the only "which app is the user in" signal available
517503
// here, and it is undefined on a cold landing straight at `/home`.
518504
const { currentAppName } = useNavigationContext();
519-
// AI CTA gating, per agent: "Build with AI" only when a build agent is
520-
// deployed (cloud / AI Studio); "Ask AI" only when a data agent is; neither
521-
// when AI isn't enabled. Community builds typically land in the ask-only state.
505+
// AI CTA gating, per agent: "Ask AI" only when a data agent is deployed,
506+
// and not for a maker the build agent serves; nothing when AI isn't
507+
// enabled. Home draws no "Build with AI" (objectstack#37227).
522508
const { aiResolved, askAvailable, buildAvailable, buildServed } = useHomeAiAvailability();
523509
// objectstack#8270 — the authoring CTAs below are gated on the SERVER's
524510
// capability answer, not on the admin ROLE: on the EE multi-tenant deploy an
@@ -828,22 +814,29 @@ export function HomePage({ checklist }: HomePageProps = {}) {
828814
white-label deployments should see their own name in the hero, that
829815
is a copy change to the ten packs, not an argument at this call site.
830816
*/}
831-
<EmptyTitle>{t('home.welcome', { defaultValue: 'Build your business system with AI' })}</EmptyTitle>
832-
<EmptyDescription>
817+
{/*
818+
objectstack#37227 — where the build agent is deployed this
819+
welcome used to promise building with AI, the 「Build with AI」
820+
button below it. That button is gone from Home, so the promise
821+
would be false: the title is the plain no-apps one there, and the
822+
description is the same NoBuild / NoAi copy any other deployment
823+
reads. The assistant drawer still serves the build agent.
824+
*/}
825+
<EmptyTitle>
833826
{buildAvailable
834-
? t('home.welcomeAdminDescription', {
827+
? t('home.noAppsTitle', { defaultValue: 'No applications yet' })
828+
: t('home.welcome', { defaultValue: 'Build your business system with AI' })}
829+
</EmptyTitle>
830+
<EmptyDescription>
831+
{askAvailable
832+
? t('home.welcomeAdminDescriptionNoBuild', {
835833
defaultValue:
836-
'Describe your business in one sentence — AI generates the objects, screens, APIs and agent tools. Or set things up yourself from the menu on the left.',
834+
'Set up your first application from the Administration menu on the left. Once you have data, the AI assistant can help you explore it.',
837835
})
838-
: askAvailable
839-
? t('home.welcomeAdminDescriptionNoBuild', {
840-
defaultValue:
841-
'Set up your first application from the Administration menu on the left. Once you have data, the AI assistant can help you explore it.',
842-
})
843-
: t('home.welcomeAdminDescriptionNoAi', {
844-
defaultValue:
845-
'Set up your first application from the Administration menu on the left.',
846-
})}
836+
: t('home.welcomeAdminDescriptionNoAi', {
837+
defaultValue:
838+
'Set up your first application from the Administration menu on the left.',
839+
})}
847840
</EmptyDescription>
848841
<HomeAiActions
849842
askAvailable={askAvailable}
@@ -969,24 +962,13 @@ export function HomePage({ checklist }: HomePageProps = {}) {
969962
* since Studio is then the ONLY way to build, a session that
970963
* may not author gets no chip rather than a dimmed one (the
971964
* template chip beside it still carries the reason). With
972-
* agents present nothing changes. The chip waits for the
973-
* catalog's answer, so neither form flashes before the other.
974-
*
975-
* objectstack#36969 — the AI form is drawn only where the
976-
* catalog serves the build agent itself (`buildServed`), not
977-
* any agent: a deployment that closed in-app building still
978-
* serves `ask`, and there the chip takes this Studio form. */}
979-
{aiStudioEnabled && buildServed && (
980-
<BuilderChip
981-
icon={Hammer}
982-
label={t('home.build.title', { defaultValue: 'Build an app' })}
983-
tone="soft"
984-
onClick={() => navigate(studioLandingPath())}
985-
disabledReason={!canAuthorMetadata ? authoringGateReason : undefined}
986-
reasonId={authoringReasonId}
987-
testId="home-build-app"
988-
/>
989-
)}
965+
* the build agent served, the chip's other form, "Build an
966+
* app" to bare `/studio`, is gone (objectstack#37227): the
967+
* maintainer ruled it off this page, with "Build with AI".
968+
* The Studio form waits for the catalog's answer, so it
969+
* never flashes, and is drawn only where the catalog does not
970+
* serve the build agent itself (`buildServed`,
971+
* objectstack#36969). */}
990972
{aiStudioEnabled && aiResolved && !buildServed && canAuthorMetadata && (
991973
<BuilderChip
992974
icon={Hammer}

‎ui/packages/app-shell/src/console/home/QuickActions.tsx‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,9 @@ export function QuickActions() {
2828
const navigate = useNavigate();
2929
const { t } = useObjectTranslation();
3030

31-
// Manual "Create App" deprecated — the AI-first builder (Build with AI on
32-
// /home) is the path to a new application. No "Manage Objects" card either
31+
// Manual "Create App" deprecated — and no build entry of any kind: Home
32+
// offers neither "Build with AI" nor "Build an app" (objectstack#37227); a
33+
// new app starts from a template or in Studio. No "Manage Objects" card either
3334
// (objectstack ADR-0146 D1): objects are designed in Studio, which Home
3435
// opens from its own cover.
3536
const actions: QuickAction[] = [

‎ui/packages/app-shell/src/console/home/__tests__/HomePage.aiStudioDisabled.test.tsx‎

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,10 @@ vi.mock('@object-ui/auth', async (importOriginal) => ({
9090

9191
vi.mock('@object-ui/plugin-chatbot/core', async (importOriginal) => ({
9292
...(await importOriginal<typeof import('@object-ui/plugin-chatbot/core')>()),
93-
useAgents: () => ({ agents: [{ name: 'build' }] }),
93+
// objectstack#37227 — Home draws no build chip where the catalog serves the
94+
// build agent ("Build an app" was ruled off the page), so the chip this flag
95+
// gates is the Studio form, "New in Studio", drawn where it does not.
96+
useAgents: () => ({ agents: [{ name: 'custom_helper' }] }),
9497
isAskAgent: () => false,
9598
agentHasCapability: () => true,
9699
}));
@@ -304,9 +307,10 @@ describe('Home on a runtime reporting features.aiStudio: false (objectui#5521)',
304307
await bootOn(serverConfig({ aiStudio: false }));
305308
});
306309

307-
it('withholds the "Build an app" cover entirely — not dimmed, gone', () => {
310+
it('withholds the build chip entirely — not dimmed, gone', () => {
308311
renderHome();
309312

313+
expect(screen.queryByTestId('home-build-in-studio')).toBeNull();
310314
expect(screen.queryByTestId('home-build-app')).toBeNull();
311315
// Counter-probe against a page that rendered NOTHING: the strip behind the
312316
// cover is still there with the workspace's app on it.
@@ -352,7 +356,7 @@ describe('Home on the measured composed hosted-SaaS shape (objectui#5521)', () =
352356
await bootOn(serverConfig({ aiStudio: false, marketplace: false, installLocal: false }));
353357
renderHome();
354358

355-
expect(screen.queryByTestId('home-build-app')).toBeNull();
359+
expect(screen.queryByTestId('home-build-in-studio')).toBeNull();
356360
expect(screen.getByTestId('home-start-template')).toBeDisabled();
357361
expect(screen.getByTestId('home-marketplace-disabled-reason')).toHaveTextContent(
358362
'«home.template.marketplaceDisabled»',
@@ -363,13 +367,13 @@ describe('Home on the measured composed hosted-SaaS shape (objectui#5521)', () =
363367
});
364368

365369
describe('Home on a runtime that DOES offer AI Studio', () => {
366-
it('keeps the "Build an app" cover exactly as before', async () => {
370+
it('keeps the build chip exactly as before', async () => {
367371
// Same fixture, same helper, one flag flipped — so the denials above cannot
368372
// be passing because the card never renders in this suite at all.
369373
await bootOn(serverConfig({ aiStudio: true }));
370374
renderHome();
371375

372-
const build = screen.getByTestId('home-build-app');
376+
const build = screen.getByTestId('home-build-in-studio');
373377
expect(build).toBeInTheDocument();
374378
expect(build).toBeEnabled();
375379
});
@@ -382,14 +386,14 @@ describe('Home on a runtime that DOES offer AI Studio', () => {
382386
await bootOn(serverConfig({}));
383387
renderHome();
384388

385-
expect(screen.getByTestId('home-build-app')).toBeEnabled();
389+
expect(screen.getByTestId('home-build-in-studio')).toBeEnabled();
386390
});
387391

388392
it('fails OPEN when the runtime answers no config at all', async () => {
389393
await bootOnNoConfig();
390394

391395
renderHome();
392396

393-
expect(screen.getByTestId('home-build-app')).toBeEnabled();
397+
expect(screen.getByTestId('home-build-in-studio')).toBeEnabled();
394398
});
395399
});

0 commit comments

Comments
 (0)