Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 7 additions & 4 deletions apps/web/src/components/app/app-sidebar/sidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -955,7 +955,7 @@ export const SidebarSettingsWidget = (props: SidebarSettingsWidgetProps) => {
<span class="size-5 flex items-center justify-center">
<GearIcon class="size-4 shrink-0 text-ink-extra-muted" />
</span>
<span class="flex-1 text-ink">{t('Settings')}</span>
<span class="flex-1 text-ink">{t('Settings', { context: 'sidebar' })}</span>
<Hotkey
token={TOKENS.global.toggleSettings}
theme="subtle"
Expand Down Expand Up @@ -1754,15 +1754,18 @@ export const SidebarOpenInSplitMenu = (props: SidebarOpenInSplitMenuProps) => {
<ContextMenu.Portal>
<ContextMenuContent class="text-xs text-ink-muted">
<MenuItem
text={t('Open in new split')}
text={t('Open in new split', { context: 'sidebar' })}
onClick={openInNewSplit}
disabled={!canOpenInNewSplit()}
/>
<Show when={canOpenFullscreen()}>
<MenuItem text={t('Open fullscreen')} onClick={openFullscreen} />
<MenuItem
text={t('Open fullscreen', { context: 'sidebar' })}
onClick={openFullscreen}
/>
</Show>
<MenuItem
text={t('Open in current split')}
text={t('Open in current split', { context: 'sidebar' })}
onClick={openInCurrentSplit}
/>
</ContextMenuContent>
Expand Down
4 changes: 2 additions & 2 deletions apps/web/src/components/app/mobile/MobileDockRow.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ function CreateMenu() {
}}
</For>
<MobileTouchMenu.Separator />
<MobileTouchMenu.Footer>{t('Create')}</MobileTouchMenu.Footer>
<MobileTouchMenu.Footer>{t('Create', { context: 'dock' })}</MobileTouchMenu.Footer>
</MobileTouchMenu.Content>
</MobileTouchMenu>
</MobileDockIsland>
Expand Down Expand Up @@ -171,7 +171,7 @@ function MoreViewsMenu(props: {
animateIcon={false}
onSelect={toggleSettings}
>
{t('Settings')}
{t('Settings', { context: 'dock' })}
</MobileTouchMenu.Item>
<MobileTouchMenu.Separator />
{/* Rows render top → bottom ending at the thumb: reverse the shared
Expand Down
4 changes: 2 additions & 2 deletions apps/web/src/features/activity/my-activity-view.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ export function MyActivityView() {
fallback={
<p class={`${INSET_CLASS} px-2 py-2 text-ink-muted text-sm`}>
{feed.isLoading
? t('Loading…')
? t('Loading…', { context: 'activity' })
: feed.isError
? t(
'Activity is unavailable right now. Try again in a moment.'
Expand All @@ -82,7 +82,7 @@ export function MyActivityView() {
onClick={() => void feed.fetchNextPage()}
disabled={feed.isFetchingNextPage}
>
{feed.isFetchingNextPage ? t('Loading…') : t('Show more')}
{feed.isFetchingNextPage ? t('Loading…', { context: 'activity' }) : t('Show more')}
</Button>
</div>
</Show>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ export function AutomationComposer() {
<div class="grid max-h-[70vh] gap-3 overflow-y-auto p-3">
<div class="grid gap-1.5">
<label class="text-xs font-medium text-ink-muted cursor-default">
{t('Name')}
{t('Name', { context: 'automation' })}
</label>
<input
class={INPUT_CLASS}
Expand Down Expand Up @@ -309,7 +309,7 @@ export function AutomationComposer() {
class="cursor-default"
onClick={() => setAutomationComposerOpen(false, false)}
>
{t('Cancel')}
{t('Cancel', { context: 'automation' })}
</Button>
<Button
variant="accent"
Expand All @@ -318,7 +318,7 @@ export function AutomationComposer() {
disabled={createMutation.isPending}
onClick={handleCreate}
>
{createMutation.isPending ? t('Creating…') : t('Create')}
{createMutation.isPending ? t('Creating…') : t('Create', { context: 'automation' })}
</Button>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -292,12 +292,12 @@ function ChannelRow(props: {
<ContextMenuContent class="text-xs text-ink-muted">
<MenuGroup>
<MenuItem
text={t('Open in new split')}
text={t('Open in new split', { context: 'channel' })}
onClick={openInNewSplit}
disabled={!canOpenInNewSplit()}
/>
<MenuItem
text={t('Open in current split')}
text={t('Open in current split', { context: 'channel' })}
onClick={openInCurrentSplit}
/>
</MenuGroup>
Expand Down
6 changes: 3 additions & 3 deletions apps/web/src/features/command/Launcher.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -900,7 +900,7 @@ export const LauncherInner = (props: LauncherInnerProps) => {
registerHotkey({
hotkey: 'shift+enter',
scopeId: launcherScope,
description: t('Open in new split'),
description: t('Open in new split', { context: 'launcher' }),
keyDownHandler: () => {
return runLauncherItem(blocks()[focusedIndex()]);
},
Expand All @@ -911,7 +911,7 @@ export const LauncherInner = (props: LauncherInnerProps) => {
const confirmHotkey = registerHotkey({
hotkey: 'enter' as ValidHotkey,
scopeId: launcherScope,
description: t('Open in current split'),
description: t('Open in current split', { context: 'launcher' }),
keyDownHandler: () => {
return runLauncherItem(blocks()[focusedIndex()]);
},
Expand Down Expand Up @@ -1045,7 +1045,7 @@ export const LauncherInner = (props: LauncherInnerProps) => {
</span>
<CommandMenuHotkeyHint
hotkey={<Hotkey shortcut={confirmHotkey.hotkey()} />}
label={t('Create')}
label={t('Create', { context: 'launcher' })}
/>
<span class="hidden touch:hidden md:flex items-center gap-1">
{t('Hold')}
Expand Down
6 changes: 3 additions & 3 deletions apps/web/src/features/command/sidebar/sidebar-create-menu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ export const SidebarCreateMenu = (props: SidebarCreateMenuProps) => {
fullWidth
tooltipPlacement="right"
tooltipDisabled={!isSlim()}
label={t('Create')}
label={t('Create', { context: 'menu' })}
hotkey={TOKENS.global.createCommand}
onMouseDown={(e: MouseEvent) => {
if (e.button !== 0) return;
Expand All @@ -115,7 +115,7 @@ export const SidebarCreateMenu = (props: SidebarCreateMenuProps) => {
<PlusIcon class="size-4" />
</div>
<span class="whitespace-nowrap group-data-[slim=true]/sidebar:hidden">
{t('Create')}
{t('Create', { context: 'menu' })}
</span>
<Show when={open()}>
<div class="text-xxs text-ink-extra-muted/50 rounded-sm ml-auto border border-ink/5 px-1.5 py-px -my-1 group-data-[slim=true]/sidebar:hidden">
Expand All @@ -134,7 +134,7 @@ export const SidebarCreateMenu = (props: SidebarCreateMenuProps) => {
size="icon-sm"
depth={1}
class="size-[26px] rounded-full bg-surface shadow-md shadow-drop-shadow [&_svg]:size-4!"
label={t('Create')}
label={t('Create', { context: 'menu' })}
hotkey={TOKENS.global.createCommand}
onMouseDown={(e: MouseEvent) => {
if (e.button !== 0) return;
Expand Down
6 changes: 3 additions & 3 deletions apps/web/src/features/favorites/sidebar/favorites-section.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -504,18 +504,18 @@ const FavoriteRow = (props: {
<ContextMenuContent class="text-xs text-ink-muted">
<MenuGroup>
<MenuItem
text={t('Open in new split')}
text={t('Open in new split', { context: 'favorites' })}
onClick={openInNewSplit}
disabled={!canOpenInNewSplit()}
/>
<Show when={canOpenFullscreen()}>
<MenuItem
text={t('Open fullscreen')}
text={t('Open fullscreen', { context: 'favorites' })}
onClick={openFullscreen}
/>
</Show>
<MenuItem
text={t('Open in current split')}
text={t('Open in current split', { context: 'favorites' })}
onClick={openInCurrentSplit}
/>
</MenuGroup>
Expand Down
2 changes: 1 addition & 1 deletion apps/web/src/features/inbox/AddInboxDialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ export function AddInboxDialog() {
disabled={pending()}
onClick={() => setIsOpen(false)}
>
{t('Cancel')}
{t('Cancel', { context: 'inbox' })}
</Button>
<Button
variant="accent"
Expand Down
6 changes: 3 additions & 3 deletions apps/web/src/features/settings/Agents.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { MACRO_AGENT_BOT_ID } from '@core/constant/macroAgent';
import { useChannelsContext } from '@core/context/channels';
import { useUserId } from '@core/context/user';
import MacroLogo from '@icon/macro-logo.svg';
import { __t } from '@macro/i18n';
import { t, __t } from '@macro/i18n';
import PencilIcon from '@phosphor/pencil-simple.svg';
import PlusIcon from '@phosphor/plus.svg';
import RobotIcon from '@phosphor/robot.svg';
Expand Down Expand Up @@ -703,7 +703,7 @@ function AgentDialog(props: {
<div class="mt-4 grid grid-cols-2 gap-3 mobile:grid-cols-1">
<label class="flex flex-col gap-1.5">
<span class="text-xs font-medium text-ink">
{__t('Name')}
{t('Name', { context: 'agents' })}
</span>
<input
autofocus
Expand Down Expand Up @@ -921,7 +921,7 @@ function AgentDialog(props: {

<Panel.Footer class="justify-end gap-2 px-3 py-2">
<Button type="button" variant="ghost" size="sm" onClick={close}>
{__t('Cancel')}
{t('Cancel', { context: 'agents' })}
</Button>
<Button
type="submit"
Expand Down
4 changes: 2 additions & 2 deletions apps/web/src/features/settings/Crm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ function ConfirmDialog(props: {
disabled={props.pending}
onClick={props.onClose}
>
{t('Cancel')}
{t('Cancel', { context: 'crm' })}
</Button>
<Button
variant="danger"
Expand Down Expand Up @@ -229,7 +229,7 @@ function CrmEnablementSection() {
disabled={patchCrmMutation.isPending}
onClick={() => setShowEnableModal(false)}
>
{t('Cancel')}
{t('Cancel', { context: 'crm' })}
</Button>
<Button
variant="outline"
Expand Down
4 changes: 2 additions & 2 deletions apps/web/src/features/settings/GitHub.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ export function GitHubCard() {
>
<Show
when={!githubLink.isLoading}
fallback={<span class="text-xs text-ink-muted">{t('Loading…')}</span>}
fallback={<span class="text-xs text-ink-muted">{t('Loading…', { context: 'github' })}</span>}
>
<Switch
fallback={
Expand Down Expand Up @@ -138,7 +138,7 @@ export function GitHubCard() {
fallback={
<span class="text-xs text-ink-muted">
{githubLink.isLoading
? t('Loading…')
? t('Loading…', { context: 'github' })
: t('Connect your GitHub account first')}
</span>
}
Expand Down
6 changes: 3 additions & 3 deletions apps/web/src/features/settings/Harness.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ export function Harness() {
<Show
when={!cursorStatus.isPlaceholderData}
fallback={
<p class="mt-4 text-xs text-ink-muted">{t('Loading…')}</p>
<p class="mt-4 text-xs text-ink-muted">{t('Loading…', { context: 'harness' })}</p>
}
>
<Show
Expand Down Expand Up @@ -366,7 +366,7 @@ export function Harness() {
<p class="truncate text-sm text-ink">{harness.name}</p>
<span class="shrink-0 rounded-full border border-edge-muted px-2 py-0.5 text-xxs font-medium uppercase text-ink-extra-muted">
{harness.owner.type === 'team'
? t('Team')
? t('Team', { context: 'harness' })
: t('Private')}
</span>
<StatusDot
Expand Down Expand Up @@ -461,7 +461,7 @@ function HarnessRemoveDialog(props: {
disabled={props.pending}
onClick={props.onClose}
>
{t('Cancel')}
{t('Cancel', { context: 'harness' })}
</Button>
<Button
type="button"
Expand Down
10 changes: 5 additions & 5 deletions apps/web/src/features/settings/HarnessPairingDialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ export function HarnessPairingDialog(props: {

<label class="flex flex-col gap-1.5">
<span class="text-xs font-medium text-ink">
{t('Name')}
{t('Name', { context: 'harness' })}
</span>
<input
class="settings-input w-full"
Expand Down Expand Up @@ -221,7 +221,7 @@ export function HarnessPairingDialog(props: {
name="harness-share"
value="team"
checked={share() === 'Team'}
title={t('Team')}
title={t('Team', { context: 'harness' })}
description={
canShareWithTeam()
? t('Your team can run agents on this harness.')
Expand Down Expand Up @@ -308,7 +308,7 @@ export function HarnessPairingDialog(props: {
disabled={approveMutation.isPending}
onClick={props.onClose}
>
{t('Cancel')}
{t('Cancel', { context: 'harness' })}
</Button>
<Button
type="button"
Expand All @@ -327,7 +327,7 @@ export function HarnessPairingDialog(props: {
size="sm"
onClick={props.onClose}
>
{t('Cancel')}
{t('Cancel', { context: 'harness' })}
</Button>
</Match>
<Match when>
Expand All @@ -337,7 +337,7 @@ export function HarnessPairingDialog(props: {
size="sm"
onClick={props.onClose}
>
{t('Cancel')}
{t('Cancel', { context: 'harness' })}
</Button>
<Button
type="button"
Expand Down
4 changes: 2 additions & 2 deletions apps/web/src/features/settings/Settings.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -273,7 +273,7 @@ export function SettingsPanel(props: SettingsPanelProps) {
<HeaderIsland>
<div class="h-full flex gap-3 items-center">
<h1 class="font-semibold text-ink select-none text-sm shrink-0">
{t('Settings')}
{t('Settings', { context: 'settings' })}
</h1>
</div>
</HeaderIsland>
Expand All @@ -297,7 +297,7 @@ export function SettingsPanel(props: SettingsPanelProps) {
<SplitHeaderRight>
<Button
class="p-1 rounded-lg"
label={t('Open fullscreen')}
label={t('Open fullscreen', { context: 'settings' })}
onClick={() => moveSettingsToSolo()}
>
<ArrowsOut class="size-4" />
Expand Down
Loading
Loading