Skip to content

Commit 8880f66

Browse files
committed
test(i18n): pins and docs read the App Studio / 应用搭建 sentences
The pins that read those sentences, in the packs or in the inline fallbacks, move to the new text. The two docs lines that quote the builder's button and app label follow, and a patch changeset records it. Claude-Session: https://claude.ai/code/session_01L9qibz59TqsYwACVq1LPf9 Co-authored-by: Claude <noreply@anthropic.com>
1 parent 1e2e63f commit 8880f66

18 files changed

Lines changed: 52 additions & 38 deletions
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
'@object-ui/i18n': patch
3+
'@object-ui/app-shell': patch
4+
'@object-ui/fields': patch
5+
'@object-ui/plugin-chatbot': patch
6+
'@object-ui/console': patch
7+
---
8+
9+
fix(i18n): sentences that name Studio read 应用搭建 in Chinese and App Studio in the other languages
10+
11+
Clause-②: no
12+
Metadata-protocol: none
13+
14+
The brand, the app name and the doors into Studio already read 应用搭建 / App Studio; the sentences that mention it still said "Studio", so a Chinese interface mixed the two names. Every such sentence now names the builder by its display name: 应用搭建 in the Chinese packs (繁體 應用搭建, regenerated), App Studio in every other pack, with each sentence's wording otherwise unchanged. That covers 25 keys of the UI packs (for example `common.editInStudio`, `console.studio.accessRequired`, `empty.openInStudio`, the "unpublished changes in Studio" notices and the `capability.label.studio_access` capability label) and 20 keys of the `studio` namespace (for example `engine.studio.menu.label`, `engine.studio.backToAppTitle` and `engine.studio.refusal.draftUnreadable`). The inline `defaultValue` fallbacks paired with those `en` values follow. Display text only: the `/studio` address, the `studio.access` capability name, package names and identifiers are unchanged.

‎content/docs/build-without-code.mdx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ You do not have to write metadata files to build on this platform. **Console**,
1919

2020
## Studio — where the app is designed
2121

22-
From any app, **"Design in Studio"** opens the same application in design mode. Studio is organized around four pillars:
22+
From any app, **"Design in App Studio"** opens the same application in design mode. Studio is organized around four pillars:
2323

2424
| Pillar | What you manage there |
2525
|---|---|

‎content/docs/ui/apps.mdx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -678,7 +678,7 @@ import { defineApp } from '@objectstack/spec';
678678

679679
const studioApp = defineApp({
680680
name: 'studio',
681-
label: 'Studio',
681+
label: 'App Studio',
682682
icon: 'hammer',
683683

684684
contextSelectors: [

‎ui/apps/console/src/components/StudioRoute.test.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ const pathname = () => screen.getByTestId('pathname').textContent;
154154
* answers. That the packs answer in the caller's language is the sibling
155155
* file's pin.
156156
*/
157-
const NOTICE = 'You need Studio access to open Studio. An administrator can grant it with a permission set in Setup → Permission Set Assignment.';
157+
const NOTICE = 'You need App Studio access to open App Studio. An administrator can grant it with a permission set in Setup → Permission Set Assignment.';
158158
/** jsdom's window is 1024 px wide: a desktop, whose way home opens an app's start page. */
159159
const WAY_HOME = 'Back to app start page';
160160
/** A phone's way home, to its app list. */

‎ui/packages/app-shell/src/views/DashboardView.inPageEdit-36372.test.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -355,7 +355,7 @@ describe('DashboardView in-page edit (objectstack#36372)', () => {
355355
await waitFor(() => expect(toasts.error).toHaveLength(1));
356356
expect(screen.queryByTestId('dashboard-editing-badge')).not.toBeInTheDocument();
357357
expect(toasts.error).toHaveLength(1);
358-
expect(String((toasts.error[0] as unknown[])[0])).toContain('unpublished changes in Studio');
358+
expect(String((toasts.error[0] as unknown[])[0])).toContain('unpublished changes in App Studio');
359359
expect(client.value.save).not.toHaveBeenCalled();
360360
});
361361

‎ui/packages/app-shell/src/views/__tests__/PageView.editInStudioFollowsPackagePosture-12615.test.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ async function mountUnder(app: Record<string, unknown>) {
137137
/** Absent, not disabled: no element carries the pencil's test id or its name. */
138138
function expectNoPencil() {
139139
expect(screen.queryByTestId('page-edit-in-studio-button')).toBeNull();
140-
expect(screen.queryByLabelText('Edit in studio')).toBeNull();
140+
expect(screen.queryByLabelText('Edit in App Studio')).toBeNull();
141141
}
142142

143143
beforeEach(() => {

‎ui/packages/app-shell/src/views/metadata-admin/PackageFormDialog.newAppStep-36748.test.tsx‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,7 @@ describe('PackageFormDialog with a new-app step: one confirm creates the package
270270
// (objectstack#37456: the package row's first control, beside the switcher).
271271
const row = await screen.findByTestId('studio-package-row', undefined, { timeout: 8000 });
272272
await waitFor(
273-
() => expect(within(row).getByTestId('studio-package-back')).toHaveAccessibleName('Leave Studio and go back to Visits'),
273+
() => expect(within(row).getByTestId('studio-package-back')).toHaveAccessibleName('Leave App Studio and go back to Visits'),
274274
{ timeout: 8000 },
275275
);
276276
expect(within(row).getByTestId('studio-pkg-switcher-name')).toHaveTextContent('Visits');
@@ -383,7 +383,7 @@ describe('CreatePackageDialog: ticked creates the package and its app; unticked
383383
// and with an app the way back names it (objectstack#37456).
384384
const row = await screen.findByTestId('studio-package-row', undefined, { timeout: 8000 });
385385
await waitFor(
386-
() => expect(within(row).getByTestId('studio-package-back')).toHaveAccessibleName('Leave Studio and go back to Visits'),
386+
() => expect(within(row).getByTestId('studio-package-back')).toHaveAccessibleName('Leave App Studio and go back to Visits'),
387387
{ timeout: 8000 },
388388
);
389389
expect(within(row).getByTestId('studio-pkg-switcher-name')).toHaveTextContent('Visits');
@@ -406,7 +406,7 @@ describe('CreatePackageDialog: ticked creates the package and its app; unticked
406406
const row = await screen.findByTestId('studio-package-row', undefined, { timeout: 8000 });
407407
const packageId = String((srv.writes[0].body?.manifest as Record<string, unknown>).id);
408408
await waitFor(() => expect(within(row).getByTestId('studio-pkg-switcher-name')).toHaveTextContent('Shared parts'), { timeout: 8000 });
409-
expect(within(row).getByTestId('studio-package-back')).toHaveAccessibleName('Leave Studio and go back to your apps');
409+
expect(within(row).getByTestId('studio-package-back')).toHaveAccessibleName('Leave App Studio and go back to your apps');
410410
expect(packageId).toMatch(/shared-parts$/);
411411
});
412412

‎ui/packages/app-shell/src/views/studio-design/MetadataListCreateDialog.newObjectJoinsAppMenu-36748.test.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ describe('新建对象 joins the package’s one app menu (objectstack#36748)',
141141
srv.appSave = () => Promise.reject(Object.assign(new Error('conflict'), { status: 409, code: 'METADATA_CONFLICT' }));
142142
await createObject('Visit');
143143
await waitFor(() => expect(toast.warning).toHaveBeenCalledWith(
144-
expect.stringMatching(/^“Visit” was created, but it could not be added to the menu of “Visits”: The app has unpublished changes in Studio\. /),
144+
expect.stringMatching(/^“Visit” was created, but it could not be added to the menu of “Visits”: The app has unpublished changes in App Studio\. /),
145145
));
146146
expect(srv.calls).toEqual(['save object draft', 'publish object', 'save app draft']);
147147
// The object is created all the same: the list opens it.

‎ui/packages/app-shell/src/views/studio-design/StudioDesignSurface.backToApp-36501.test.tsx‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ function renderAt(entry: string) {
157157
// open package. The button names where it leads in its accessible name.
158158
const row = () => screen.getByTestId('studio-package-row');
159159
const backLink = () => within(row()).findByTestId('studio-package-back', undefined, { timeout: 8000 });
160-
const leadsTo = (app: string) => `Leave Studio and go back to ${app}`;
160+
const leadsTo = (app: string) => `Leave App Studio and go back to ${app}`;
161161

162162
describe('the way back returns to the app page the author came from (objectstack#36501)', () => {
163163
it('names the app the author came from and returns to that page, query kept', async () => {
@@ -210,7 +210,7 @@ describe('a package with no app: the switcher names the package and the way back
210210
const link = await backLink();
211211
// objectstack#36748 — the open package is named, by its label (now the switcher's name).
212212
await waitFor(() => expect(within(row()).getByTestId('studio-pkg-switcher-name')).toHaveTextContent('Sales'), { timeout: 8000 });
213-
expect(link).toHaveAccessibleName('Leave Studio and go back to your apps');
213+
expect(link).toHaveAccessibleName('Leave App Studio and go back to your apps');
214214
expect(screen.getByTestId('studio-brand-name')).toHaveTextContent(/^App Studio$/);
215215
fireEvent.click(link);
216216
expect(await screen.findByTestId('elsewhere')).toHaveTextContent('/home');
@@ -223,7 +223,7 @@ describe('a package with no app: the switcher names the package and the way back
223223
const link = await backLink();
224224
await waitFor(() => expect(within(row()).getByTestId('studio-pkg-switcher-name')).toHaveTextContent('Sales'), { timeout: 8000 });
225225
// No app is named or opened.
226-
expect(link).toHaveAccessibleName('Leave Studio and go back to your apps');
226+
expect(link).toHaveAccessibleName('Leave App Studio and go back to your apps');
227227
fireEvent.click(link);
228228
expect(await screen.findByTestId('elsewhere')).toHaveTextContent('/home');
229229
});
@@ -237,7 +237,7 @@ describe('the controls the back link replaced stay gone (objectstack#36501)', ()
237237
for (const id of ['studio-home', 'studio-pkg-chip', 'studio-open-app']) {
238238
expect(screen.queryByTestId(id)).toBeNull();
239239
}
240-
expect(screen.queryByRole('button', { name: /Open app|Studio home/ })).toBeNull();
240+
expect(screen.queryByRole('button', { name: /Open app|App Studio home/ })).toBeNull();
241241
expect(within(row()).getAllByRole('button').map((b) => b.dataset.testid)).toEqual(['studio-package-back', 'studio-pkg-switcher']);
242242
});
243243
});

‎ui/packages/app-shell/src/views/studio-design/StudioDesignSurface.homeLoop-12513.test.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,7 @@ describe('Studio home loop (objectui#12513)', () => {
222222
const row = screen.getByTestId('studio-package-row');
223223
expect(within(row).getAllByRole('button')[0]).toBe(back);
224224
expect(within(screen.getByTestId('studio-brand-row')).getByTestId('studio-menu-toggle')).toBeTruthy();
225-
expect(screen.queryByRole('button', { name: 'Studio home' })).toBeNull();
225+
expect(screen.queryByRole('button', { name: 'App Studio home' })).toBeNull();
226226
});
227227
// objectstack#36903 — the Automations rail's empty blocks went with the rail:
228228
// the package-less scope's list offers no create (StudioDesignSurface.packageLessFlows-11553).

0 commit comments

Comments
 (0)