Align action_* strings with Element X project in Localazy (#11437)

This commit is contained in:
Michael Telatynski 2023-08-22 20:55:15 +01:00 committed by GitHub
parent bdd3710f25
commit df4a2218d7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
166 changed files with 1697 additions and 1555 deletions

View file

@ -840,7 +840,7 @@ export default class LegacyCallHandler extends EventEmitter {
button: _t("Try using %(server)s", {
server: new URL(FALLBACK_ICE_SERVER).pathname,
}),
cancelButton: _t("OK"),
cancelButton: _t("action|ok"),
onFinished: (allow) => {
SettingsStore.setValue("fallbackICEServerAllowed", null, SettingLevel.DEVICE, allow);
cli.setFallbackICEServerAllowed(!!allow);

View file

@ -612,7 +612,7 @@ async function checkServerVersions(): Promise<void> {
brand: SdkConfig.get().brand,
},
),
acceptLabel: _t("OK"),
acceptLabel: _t("action|ok"),
onAccept: () => {
ToastStore.sharedInstance().dismissToast(toastKey);
},

View file

@ -407,7 +407,7 @@ export const Commands = [
)}
</p>
),
button: _t("Continue"),
button: _t("action|continue"),
});
prom = finished.then(([useDefault]) => {
@ -457,7 +457,7 @@ export const Commands = [
new Command({
command: "part",
args: "[<room-address>]",
description: _td("Leave room"),
description: _td("action|leave_room"),
analyticsName: "Part",
isEnabled: (cli) => !isCurrentLocalRoom(cli),
runFn: function (cli, roomId, threadId, args) {

View file

@ -62,7 +62,7 @@ export default class DisableEventIndexDialog extends React.Component<IProps, ISt
{_t("If disabled, messages from encrypted rooms won't appear in search results.")}
{this.state.disabling ? <Spinner /> : <div />}
<DialogButtons
primaryButton={_t("Disable")}
primaryButton={_t("action|disable")}
onPrimaryButtonClick={this.onDisable}
primaryButtonClass="danger"
cancelButtonClass="warning"

View file

@ -195,10 +195,10 @@ export default class ManageEventIndexDialog extends React.Component<IProps, ISta
>
{eventIndexingSettings}
<DialogButtons
primaryButton={_t("Done")}
primaryButton={_t("action|done")}
onPrimaryButtonClick={this.props.onFinished}
primaryButtonClass="primary"
cancelButton={_t("Disable")}
cancelButton={_t("action|disable")}
onCancel={this.onDisable}
cancelButtonClass="danger"
/>

View file

@ -131,7 +131,7 @@ export default class CreateKeyBackupDialog extends React.PureComponent<IProps, I
return (
<div>
<p>{_t("Your keys are being backed up (the first backup could take a few minutes).")}</p>
<DialogButtons primaryButton={_t("OK")} onPrimaryButtonClick={this.onDone} hasCancel={false} />
<DialogButtons primaryButton={_t("action|ok")} onPrimaryButtonClick={this.onDone} hasCancel={false} />
</div>
);
}
@ -154,7 +154,7 @@ export default class CreateKeyBackupDialog extends React.PureComponent<IProps, I
<div>
<p>{_t("Unable to create key backup")}</p>
<DialogButtons
primaryButton={_t("Retry")}
primaryButton={_t("action|retry")}
onPrimaryButtonClick={this.createBackup}
hasCancel={true}
onCancel={this.onCancel}

View file

@ -567,7 +567,7 @@ export default class CreateSecretStorageDialog extends React.PureComponent<IProp
{optionPassphrase}
</div>
<DialogButtons
primaryButton={_t("Continue")}
primaryButton={_t("action|continue")}
onPrimaryButtonClick={this.onChooseKeyPassphraseFormSubmit}
onCancel={this.onCancelClick}
hasCancel={this.state.canSkip}
@ -578,7 +578,7 @@ export default class CreateSecretStorageDialog extends React.PureComponent<IProp
private renderPhaseMigrate(): JSX.Element {
let authPrompt;
let nextCaption = _t("Next");
let nextCaption = _t("action|next");
if (this.state.canUploadKeysWithPasswordOnly) {
authPrompt = (
<div>
@ -654,7 +654,7 @@ export default class CreateSecretStorageDialog extends React.PureComponent<IProp
</div>
<DialogButtons
primaryButton={_t("Continue")}
primaryButton={_t("action|continue")}
onPrimaryButtonClick={this.onPassPhraseNextClick}
hasCancel={false}
disabled={!this.state.passPhraseValid}
@ -712,7 +712,7 @@ export default class CreateSecretStorageDialog extends React.PureComponent<IProp
<div className="mx_CreateSecretStorageDialog_passPhraseMatch">{passPhraseMatch}</div>
</div>
<DialogButtons
primaryButton={_t("Continue")}
primaryButton={_t("action|continue")}
onPrimaryButtonClick={this.onPassPhraseConfirmNextClick}
hasCancel={false}
disabled={this.state.passPhrase !== this.state.passPhraseConfirm}
@ -730,7 +730,7 @@ export default class CreateSecretStorageDialog extends React.PureComponent<IProp
if (this.state.phase === Phase.ShowKey) {
continueButton = (
<DialogButtons
primaryButton={_t("Continue")}
primaryButton={_t("action|continue")}
disabled={!this.state.downloaded && !this.state.copied && !this.state.setPassphrase}
onPrimaryButtonClick={this.onShowKeyContinueClick}
hasCancel={false}
@ -777,7 +777,7 @@ export default class CreateSecretStorageDialog extends React.PureComponent<IProp
onClick={this.onCopyClick}
disabled={this.state.phase === Phase.Storing}
>
{this.state.copied ? _t("Copied!") : _t("Copy")}
{this.state.copied ? _t("Copied!") : _t("action|copy")}
</AccessibleButton>
</div>
</div>
@ -800,7 +800,7 @@ export default class CreateSecretStorageDialog extends React.PureComponent<IProp
<>
<p className="mx_Dialog_content">{_t("Your keys are now being backed up from this device.")}</p>
<DialogButtons
primaryButton={_t("Done")}
primaryButton={_t("action|done")}
onPrimaryButtonClick={() => this.props.onFinished(true)}
hasCancel={false}
/>
@ -814,7 +814,7 @@ export default class CreateSecretStorageDialog extends React.PureComponent<IProp
<p>{_t("Unable to query secret storage status")}</p>
<div className="mx_Dialog_buttons">
<DialogButtons
primaryButton={_t("Retry")}
primaryButton={_t("action|retry")}
onPrimaryButtonClick={this.onLoadRetryClick}
hasCancel={this.state.canSkip}
onCancel={this.onCancel}
@ -889,7 +889,7 @@ export default class CreateSecretStorageDialog extends React.PureComponent<IProp
<p>{_t("Unable to set up secret storage")}</p>
<div className="mx_Dialog_buttons">
<DialogButtons
primaryButton={_t("Retry")}
primaryButton={_t("action|retry")}
onPrimaryButtonClick={this.bootstrapSecretStorage}
hasCancel={this.state.canSkip}
onCancel={this.onCancel}

View file

@ -75,7 +75,7 @@ export default class NewRecoveryMethodDialog extends React.PureComponent<IProps>
<p>{_t("This session is encrypting history using the new recovery method.")}</p>
{hackWarning}
<DialogButtons
primaryButton={_t("OK")}
primaryButton={_t("action|ok")}
onPrimaryButtonClick={this.onOkClick}
cancelButton={_t("Go to Settings")}
onCancel={this.onGoToSettingsClick}

View file

@ -1196,7 +1196,7 @@ export default class MatrixChat extends React.PureComponent<IProps, IState> {
const isSpace = roomToLeave?.isSpaceRoom();
Modal.createDialog(QuestionDialog, {
title: isSpace ? _t("Leave space") : _t("Leave room"),
title: isSpace ? _t("Leave space") : _t("action|leave_room"),
description: (
<span>
{isSpace
@ -1209,7 +1209,7 @@ export default class MatrixChat extends React.PureComponent<IProps, IState> {
{warnings}
</span>
),
button: _t("Leave"),
button: _t("action|leave"),
onFinished: async (shouldLeave) => {
if (shouldLeave) {
await leaveRoomBehaviour(cli, roomId);
@ -1398,7 +1398,7 @@ export default class MatrixChat extends React.PureComponent<IProps, IState> {
title: userNotice.title,
props: {
description: <Linkify>{userNotice.description}</Linkify>,
acceptLabel: _t("OK"),
acceptLabel: _t("action|ok"),
onAccept: () => {
ToastStore.sharedInstance().dismissToast(key);
localStorage.setItem(key, "1");

View file

@ -286,7 +286,7 @@ function LocalRoomView(props: LocalRoomViewProps): ReactElement {
if (room.isError) {
const buttons = (
<AccessibleButton onClick={onRetryClicked} className="mx_RoomStatusBar_unsentRetry">
{_t("Retry")}
{_t("action|retry")}
</AccessibleButton>
);

View file

@ -716,7 +716,7 @@ const ManageButtons: React.FC<IManageButtonsProps> = ({ hierarchy, selected, set
kind="danger_outline"
disabled={disabled}
>
{removing ? _t("Removing…") : _t("Remove")}
{removing ? _t("Removing…") : _t("action|remove")}
</Button>
<Button
{...props}

View file

@ -232,7 +232,7 @@ const SpaceLanding: React.FC<{ space: Room }> = ({ space }) => {
showSpaceInvite(space);
}}
>
{_t("Invite")}
{_t("action|invite")}
</AccessibleButton>
);
}
@ -364,7 +364,7 @@ const SpaceSetupFirstRooms: React.FC<{
let buttonLabel = _t("Skip for now");
if (roomNames.some((name) => name.trim())) {
onClick = onNextClick;
buttonLabel = busy ? _t("Creating rooms…") : _t("Continue");
buttonLabel = busy ? _t("Creating rooms…") : _t("action|continue");
}
return (
@ -572,7 +572,7 @@ const SpaceSetupPrivateInvite: React.FC<{
let buttonLabel = _t("Skip for now");
if (emailAddresses.some((name) => name.trim())) {
onClick = onNextClick;
buttonLabel = busy ? _t("Inviting…") : _t("Continue");
buttonLabel = busy ? _t("Inviting…") : _t("action|continue");
}
return (

View file

@ -157,7 +157,7 @@ export default class ViewSource extends React.Component<IProps, IState> {
? this.canSendStateEvent(mxEvent)
: canEditContent(MatrixClientPeg.safeGet(), this.props.mxEvent);
return (
<BaseDialog className="mx_ViewSource" onFinished={this.props.onFinished} title={_t("View Source")}>
<BaseDialog className="mx_ViewSource" onFinished={this.props.onFinished} title={_t("action|view_source")}>
<div className="mx_ViewSource_header">
<CopyableText getTextToCopy={() => roomId} border={false}>
{_t("Room ID: %(roomId)s", { roomId })}
@ -176,7 +176,7 @@ export default class ViewSource extends React.Component<IProps, IState> {
{isEditing ? this.editSourceContent() : this.viewSourceContent()}
{!isEditing && canEdit && (
<div className="mx_Dialog_buttons">
<button onClick={() => this.onEdit()}>{_t("Edit")}</button>
<button onClick={() => this.onEdit()}>{_t("action|edit")}</button>
</div>
)}
</BaseDialog>

View file

@ -364,7 +364,7 @@ export default class ForgotPassword extends React.Component<Props, State> {
</p>
</div>
),
button: _t("Continue"),
button: _t("action|continue"),
});
const [confirmed] = await finished;
return !!confirmed;

View file

@ -481,7 +481,7 @@ export default class LoginComponent extends React.PureComponent<IProps, IState>
);
}}
>
{_t("Continue")}
{_t("action|continue")}
</AccessibleButton>
);
};

View file

@ -244,7 +244,7 @@ export default class SetupEncryptionBody extends React.Component<IProps, IState>
{message}
<div className="mx_CompleteSecurity_actionRow">
<AccessibleButton kind="primary" onClick={this.onDoneClick}>
{_t("Done")}
{_t("action|done")}
</AccessibleButton>
</div>
</div>

View file

@ -66,7 +66,7 @@ export const CheckEmail: React.FC<CheckEmailProps> = ({
</div>
</div>
{errorText && <ErrorMessage message={errorText} />}
<input onClick={onSubmitForm} type="button" className="mx_Login_submit" value={_t("Next")} />
<input onClick={onSubmitForm} type="button" className="mx_Login_submit" value={_t("action|next")} />
<div className="mx_AuthBody_did-not-receive">
<span className="mx_VerifyEMailDialog_text-light">{_t("Did not receive it?")}</span>
<AccessibleButton

View file

@ -153,7 +153,7 @@ export class PasswordAuthEntry extends React.Component<IAuthEntryProps, IPasswor
type="submit"
className="mx_Dialog_primary"
disabled={!this.state.password}
value={_t("Continue")}
value={_t("action|continue")}
/>
);
}
@ -745,7 +745,7 @@ export class RegistrationTokenAuthEntry extends React.Component<IAuthEntryProps,
} else {
submitButtonOrSpinner = (
<AccessibleButton onClick={this.onSubmit} kind="primary" disabled={!this.state.registrationToken}>
{_t("Continue")}
{_t("action|continue")}
</AccessibleButton>
);
}

View file

@ -77,7 +77,7 @@ const OwnBeaconStatus: React.FC<Props & HTMLProps<HTMLDivElement>> = ({ beacon,
onClick={preventDefaultWrapper(onResetLocationPublishError)}
className="mx_OwnBeaconStatus_button mx_OwnBeaconStatus_destructiveButton"
>
{_t("Retry")}
{_t("action|retry")}
</AccessibleButton>
)}
{hasStopSharingError && (
@ -89,7 +89,7 @@ const OwnBeaconStatus: React.FC<Props & HTMLProps<HTMLDivElement>> = ({ beacon,
onClick={preventDefaultWrapper(onStopSharing)}
className="mx_OwnBeaconStatus_button mx_OwnBeaconStatus_destructiveButton"
>
{_t("Retry")}
{_t("action|retry")}
</AccessibleButton>
)}
</BeaconStatus>

View file

@ -111,7 +111,7 @@ const RoomLiveShareWarningInner: React.FC<RoomLiveShareWarningInnerProps> = ({ l
element="button"
disabled={stoppingInProgress}
>
{hasError ? _t("Retry") : _t("Stop")}
{hasError ? _t("action|retry") : _t("Stop")}
</AccessibleButton>
{hasLocationPublishError && (
<AccessibleButton

View file

@ -425,7 +425,7 @@ export default class MessageContextMenu extends React.Component<IProps, IState>
redactButton = (
<IconizedContextMenuOption
iconClassName="mx_MessageContextMenu_iconRedact"
label={_t("Remove")}
label={_t("action|remove")}
onClick={this.onRedactClick}
/>
);
@ -456,7 +456,7 @@ export default class MessageContextMenu extends React.Component<IProps, IState>
forwardButton = (
<IconizedContextMenuOption
iconClassName="mx_MessageContextMenu_iconForward"
label={_t("Forward")}
label={_t("action|forward")}
onClick={this.onForwardClick(forwardableEvent)}
/>
);
@ -530,7 +530,7 @@ export default class MessageContextMenu extends React.Component<IProps, IState>
quoteButton = (
<IconizedContextMenuOption
iconClassName="mx_MessageContextMenu_iconQuote"
label={_t("Quote")}
label={_t("action|quote")}
onClick={this.onQuoteClick}
/>
);
@ -600,7 +600,7 @@ export default class MessageContextMenu extends React.Component<IProps, IState>
<IconizedContextMenuOption
iconClassName="mx_MessageContextMenu_iconCopy"
onClick={this.onCopyLinkClick}
label={_t("Copy link")}
label={_t("action|copy_link")}
element="a"
{
// XXX: Typescript signature for AccessibleButton doesn't work properly for non-inputs like `a`
@ -619,7 +619,7 @@ export default class MessageContextMenu extends React.Component<IProps, IState>
copyButton = (
<IconizedContextMenuOption
iconClassName="mx_MessageContextMenu_iconCopy"
label={_t("Copy")}
label={_t("action|copy")}
triggerOnMouseDown={true} // We use onMouseDown so that the selection isn't cleared when we click
onClick={this.onCopyClick}
/>
@ -631,7 +631,7 @@ export default class MessageContextMenu extends React.Component<IProps, IState>
editButton = (
<IconizedContextMenuOption
iconClassName="mx_MessageContextMenu_iconEdit"
label={_t("Edit")}
label={_t("action|edit")}
onClick={this.onEditClick}
/>
);
@ -642,7 +642,7 @@ export default class MessageContextMenu extends React.Component<IProps, IState>
replyButton = (
<IconizedContextMenuOption
iconClassName="mx_MessageContextMenu_iconReply"
label={_t("Reply")}
label={_t("action|reply")}
onClick={this.onReplyClick}
/>
);
@ -664,7 +664,7 @@ export default class MessageContextMenu extends React.Component<IProps, IState>
reactButton = (
<IconizedContextMenuOption
iconClassName="mx_MessageContextMenu_iconReact"
label={_t("React")}
label={_t("action|react")}
onClick={this.onReactClick}
inputRef={this.reactButtonRef}
/>

View file

@ -105,7 +105,7 @@ const RoomContextMenu: React.FC<IProps> = ({ room, onFinished, ...props }) => {
leaveOption = (
<IconizedContextMenuOption
onClick={onLeaveRoomClick}
label={_t("Leave")}
label={_t("action|leave")}
className="mx_IconizedContextMenu_option_red"
iconClassName="mx_RoomTile_iconSignOut"
/>
@ -136,7 +136,7 @@ const RoomContextMenu: React.FC<IProps> = ({ room, onFinished, ...props }) => {
inviteOption = (
<IconizedContextMenuOption
onClick={onInviteClick}
label={_t("Invite")}
label={_t("action|invite")}
iconClassName="mx_RoomTile_iconInvite"
/>
);

View file

@ -138,7 +138,7 @@ export const RoomGeneralContextMenu: React.FC<RoomGeneralContextMenuProps> = ({
}),
onPostInviteClick,
)}
label={_t("Invite")}
label={_t("action|invite")}
iconClassName="mx_RoomGeneralContextMenu_iconInvite"
/>
);
@ -205,7 +205,7 @@ export const RoomGeneralContextMenu: React.FC<RoomGeneralContextMenuProps> = ({
}),
onPostLeaveClick,
)}
label={_t("Leave")}
label={_t("action|leave")}
className="mx_IconizedContextMenu_option_red"
iconClassName="mx_RoomGeneralContextMenu_iconSignOut"
/>

View file

@ -69,7 +69,7 @@ const SpaceContextMenu: React.FC<IProps> = ({ space, hideHeader, onFinished, ...
data-testid="invite-option"
className="mx_SpacePanel_contextMenu_inviteButton"
iconClassName="mx_SpacePanel_iconInvite"
label={_t("Invite")}
label={_t("action|invite")}
onClick={onInviteClick}
/>
);

View file

@ -159,7 +159,7 @@ export const WidgetContextMenu: React.FC<IProps> = ({
onFinished();
};
editButton = <IconizedContextMenuOption onClick={_onEditClick} label={_t("Edit")} />;
editButton = <IconizedContextMenuOption onClick={_onEditClick} label={_t("action|edit")} />;
}
let snapshotButton: JSX.Element | undefined;
@ -208,7 +208,7 @@ export const WidgetContextMenu: React.FC<IProps> = ({
deleteButton = (
<IconizedContextMenuOption
onClick={_onDeleteClick}
label={userWidget ? _t("Remove") : _t("Remove for everyone")}
label={userWidget ? _t("action|remove") : _t("Remove for everyone")}
/>
);
}

View file

@ -246,7 +246,7 @@ export const AddExistingToSpace: React.FC<IAddExistingToSpaceProps> = ({
</span>
<AccessibleButton className="mx_AddExistingToSpaceDialog_retryButton" onClick={addRooms}>
{_t("Retry")}
{_t("action|retry")}
</AccessibleButton>
</>
);

View file

@ -48,7 +48,7 @@ export default class ConfirmRedactDialog extends React.Component<IProps> {
description={description}
placeholder={_t("Reason (optional)")}
focus
button={_t("Remove")}
button={_t("action|remove")}
/>
);
}

View file

@ -343,7 +343,7 @@ export default class CreateRoomDialog extends React.Component<IProps, IState> {
if (isVideoRoom) {
title = _t("Create a video room");
} else if (this.props.parentSpace || this.state.joinRule === JoinRule.Knock) {
title = _t("Create a room");
title = _t("action|create_a_room");
} else {
title = this.state.joinRule === JoinRule.Public ? _t("Create a public room") : _t("Create a private room");
}

View file

@ -83,7 +83,7 @@ export default class ErrorDialog extends React.Component<IProps, IState> {
</div>
<div className="mx_Dialog_buttons">
<button className="mx_Dialog_primary" onClick={this.onClick} autoFocus={this.props.focus}>
{this.props.button || _t("OK")}
{this.props.button || _t("action|ok")}
</button>
</div>
</BaseDialog>

View file

@ -315,7 +315,7 @@ const ExportDialog: React.FC<IProps> = ({ room, onFinished }) => {
primaryButton={_t("Stop")}
primaryButtonClass="danger"
hasCancel={true}
cancelButton={_t("Continue")}
cancelButton={_t("action|continue")}
onCancel={() => setCancelWarning(false)}
onPrimaryButtonClick={confirmCancel}
/>

View file

@ -211,7 +211,7 @@ export default class IncomingSasDialog extends React.Component<IProps, IState> {
{profile}
{isSelf ? selfDetailText : userDetailText}
<DialogButtons
primaryButton={_t("Continue")}
primaryButton={_t("action|continue")}
hasCancel={true}
onPrimaryButtonClick={this.onContinueClick}
onCancel={this.onCancelClick}

View file

@ -62,7 +62,7 @@ export default class InfoDialog extends React.Component<IProps> {
</div>
{this.props.button !== false && (
<DialogButtons
primaryButton={this.props.button || _t("OK")}
primaryButton={this.props.button || _t("action|ok")}
onPrimaryButtonClick={this.onFinished}
hasCancel={false}
/>

View file

@ -54,7 +54,7 @@ export default class IntegrationsDisabledDialog extends React.Component<IProps>
<DialogButtons
primaryButton={_t("common|settings")}
onPrimaryButtonClick={this.onOpenSettingsClick}
cancelButton={_t("OK")}
cancelButton={_t("action|ok")}
onCancel={this.onAcknowledgeClick}
/>
</BaseDialog>

View file

@ -49,7 +49,7 @@ export default class IntegrationsImpossibleDialog extends React.Component<IProps
</p>
</div>
<DialogButtons
primaryButton={_t("OK")}
primaryButton={_t("action|ok")}
onPrimaryButtonClick={this.onAcknowledgeClick}
hasCancel={false}
/>

View file

@ -135,7 +135,7 @@ class DMUserTile extends React.PureComponent<IDMUserTileProps> {
<AccessibleButton className="mx_InviteDialog_userTile_remove" onClick={this.onRemove}>
<img
src={require("../../../../res/img/icon-pill-remove.svg").default}
alt={_t("Remove")}
alt={_t("action|remove")}
width={8}
height={8}
/>
@ -944,7 +944,7 @@ export default class InviteDialog extends React.PureComponent<Props, IInviteDial
"The following users might not exist or are invalid, and cannot be invited: %(csvNames)s",
{ csvNames: failed.join(", ") },
),
button: _t("OK"),
button: _t("action|ok"),
});
}
@ -1388,7 +1388,7 @@ export default class InviteDialog extends React.PureComponent<Props, IInviteDial
},
);
buttonText = _t("Invite");
buttonText = _t("action|invite");
goButtonFn = this.inviteUsers;
if (cli.isRoomEncrypted(this.props.roomId)) {

View file

@ -100,7 +100,7 @@ const KeySignatureUploadFailedDialog: React.FC<IProps> = ({ failures, source, co
body = (
<div>
<span>{text}</span>
<DialogButtons primaryButton={_t("OK")} hasCancel={false} onPrimaryButtonClick={onFinished} />
<DialogButtons primaryButton={_t("action|ok")} hasCancel={false} onPrimaryButtonClick={onFinished} />
</div>
);
}

View file

@ -37,7 +37,7 @@ const LazyLoadingResyncDialog: React.FC<IProps> = (props) => {
hasCancelButton={false}
title={_t("Updating %(brand)s", { brand })}
description={<div>{description}</div>}
button={_t("OK")}
button={_t("action|ok")}
onFinished={props.onFinished}
/>
);

View file

@ -46,7 +46,7 @@ export class ModuleUiDialog<P extends DialogProps, C extends DialogContent<P>> e
this.state = {
title: this.props.initialOptions.title,
actionLabel: this.props.initialOptions.actionLabel ?? _t("OK"),
actionLabel: this.props.initialOptions.actionLabel ?? _t("action|ok"),
cancelLabel: this.props.initialOptions.cancelLabel,
canSubmit: this.props.initialOptions.canSubmit ?? true,
};

View file

@ -77,7 +77,7 @@ export default class QuestionDialog extends React.Component<IQuestionDialogProps
{this.props.description}
</div>
<DialogButtons
primaryButton={this.props.button || _t("OK")}
primaryButton={this.props.button || _t("action|ok")}
primaryButtonClass={primaryButtonClass}
primaryDisabled={this.props.buttonDisabled}
cancelButton={this.props.cancelButton}

View file

@ -79,7 +79,7 @@ const RegistrationEmailPromptDialog: React.FC<IProps> = ({ onFinished }) => {
/>
</form>
</div>
<DialogButtons primaryButton={_t("Continue")} onPrimaryButtonClick={onSubmit} hasCancel={false} />
<DialogButtons primaryButton={_t("action|continue")} onPrimaryButtonClick={onSubmit} hasCancel={false} />
</BaseDialog>
);
};

View file

@ -361,7 +361,7 @@ export default class ReportEventDialog extends React.Component<IProps, IState> {
<BaseDialog
className="mx_ReportEventDialog"
onFinished={this.props.onFinished}
title={_t("Report Content")}
title={_t("action|report_content")}
contentId="mx_ReportEventDialog"
>
<div>

View file

@ -239,10 +239,10 @@ export default class ServerPickerDialog extends React.PureComponent<IProps, ISta
<p>{_t("Use your preferred Matrix homeserver if you have one, or host your own.")}</p>
<AccessibleButton className="mx_ServerPickerDialog_continue" kind="primary" onClick={this.onSubmit}>
{_t("Continue")}
{_t("action|continue")}
</AccessibleButton>
<h2>{_t("Learn more")}</h2>
<h2>{_t("action|learn_more")}</h2>
<ExternalLink
href="https://matrix.org/docs/matrix-concepts/elements-of-matrix/#homeserver"
target="_blank"

View file

@ -80,7 +80,7 @@ export default class SetEmailDialog extends React.Component<IProps, IState> {
description: _t(
"Please check your email and click on the link it contains. Once this is done, click continue.",
),
button: _t("Continue"),
button: _t("action|continue"),
onFinished: this.onEmailDialogFinished,
});
},
@ -131,7 +131,7 @@ export default class SetEmailDialog extends React.Component<IProps, IState> {
Modal.createDialog(QuestionDialog, {
title: _t("Verification Pending"),
description: message,
button: _t("Continue"),
button: _t("action|continue"),
onFinished: this.onEmailDialogFinished,
});
} else {
@ -173,7 +173,12 @@ export default class SetEmailDialog extends React.Component<IProps, IState> {
{emailInput}
</div>
<div className="mx_Dialog_buttons">
<input className="mx_Dialog_primary" type="submit" value={_t("Continue")} onClick={this.onSubmit} />
<input
className="mx_Dialog_primary"
type="submit"
value={_t("action|continue")}
onClick={this.onSubmit}
/>
<input type="submit" value={_t("Skip")} onClick={this.onCancelled} />
</div>
</BaseDialog>

View file

@ -122,7 +122,7 @@ export const SlidingSyncOptionsDialog: React.FC<{ onFinished(enabled: boolean):
}
placeholder={hasNativeSupport ? _t("Proxy URL (optional)") : _t("Proxy URL")}
value={currentProxy}
button={_t("Enable")}
button={_t("action|enable")}
validator={validProxy}
onFinished={(enable, proxyUrl) => {
if (enable) {

View file

@ -213,7 +213,7 @@ export default class TermsDialog extends React.PureComponent<ITermsDialogProps,
</div>
<DialogButtons
primaryButton={_t("Next")}
primaryButton={_t("action|next")}
hasCancel={true}
onCancel={this.onCancelClick}
onPrimaryButtonClick={this.onNextClick}

View file

@ -71,7 +71,7 @@ const UntrustedDeviceDialog: React.FC<IProps> = ({ device, user, onFinished }) =
{_t("Interactively verify by emoji")}
</AccessibleButton>
<AccessibleButton kind="primary" onClick={() => onFinished(false)}>
{_t("Done")}
{_t("action|done")}
</AccessibleButton>
</div>
</BaseDialog>

View file

@ -60,7 +60,7 @@ export default class UploadFailureDialog extends React.Component<IProps> {
);
buttons = (
<DialogButtons
primaryButton={_t("OK")}
primaryButton={_t("action|ok")}
hasCancel={false}
onPrimaryButtonClick={this.onCancelClick}
focus={true}
@ -78,7 +78,7 @@ export default class UploadFailureDialog extends React.Component<IProps> {
);
buttons = (
<DialogButtons
primaryButton={_t("OK")}
primaryButton={_t("action|ok")}
hasCancel={false}
onPrimaryButtonClick={this.onCancelClick}
focus={true}

View file

@ -89,7 +89,7 @@ export default class WidgetOpenIDPermissionsDialog extends React.PureComponent<I
</p>
</div>
<DialogButtons
primaryButton={_t("Continue")}
primaryButton={_t("action|continue")}
onPrimaryButtonClick={this.onAllow}
onCancel={this.onDeny}
additive={

View file

@ -161,7 +161,7 @@ export const EventViewer: React.FC<IViewerProps> = ({ mxEvent, onBack, Editor, e
};
return (
<BaseTool onBack={onBack} actionLabel={_t("Edit")} onAction={onAction} extraButton={extraButton}>
<BaseTool onBack={onBack} actionLabel={_t("action|edit")} onAction={onAction} extraButton={extraButton}>
<SyntaxHighlight language="json">{stringify(mxEvent.event)}</SyntaxHighlight>
</BaseTool>
);

View file

@ -30,7 +30,7 @@ const PHASE_MAP: Record<Phase, TranslationKey> = {
[Phase.Unsent]: _td("Unsent"),
[Phase.Requested]: _td("Requested"),
[Phase.Ready]: _td("Ready"),
[Phase.Done]: _td("Done"),
[Phase.Done]: _td("action|done"),
[Phase.Started]: _td("Started"),
[Phase.Cancelled]: _td("Cancelled"),
};

View file

@ -64,7 +64,7 @@ export const OidcLogoutDialog: React.FC<OidcLogoutDialogProps> = ({
href={logoutUrl}
target="_blank"
>
{_t("Continue")}
{_t("action|continue")}
</AccessibleButton>
</>
)}

View file

@ -366,7 +366,7 @@ export default class AccessSecretStorageDialog extends React.PureComponent<IProp
/>
{keyStatus}
<DialogButtons
primaryButton={_t("Continue")}
primaryButton={_t("action|continue")}
onPrimaryButtonClick={this.onPassPhraseNext}
hasCancel={true}
onCancel={this.onCancel}
@ -432,7 +432,7 @@ export default class AccessSecretStorageDialog extends React.PureComponent<IProp
</div>
{recoveryKeyFeedback}
<DialogButtons
primaryButton={_t("Continue")}
primaryButton={_t("action|continue")}
onPrimaryButtonClick={this.onRecoveryKeyNext}
hasCancel={true}
cancelButton={_t("Go Back")}

View file

@ -176,7 +176,7 @@ export default class CreateCrossSigningDialog extends React.PureComponent<IProps
<p>{_t("Unable to set up keys")}</p>
<div className="mx_Dialog_buttons">
<DialogButtons
primaryButton={_t("Retry")}
primaryButton={_t("action|retry")}
onPrimaryButtonClick={this.bootstrapCrossSigning}
onCancel={this.onCancel}
/>

View file

@ -396,7 +396,7 @@ export default class RestoreKeyBackupDialog extends React.PureComponent<IProps,
</p>
{failedToDecrypt}
<DialogButtons
primaryButton={_t("OK")}
primaryButton={_t("action|ok")}
onPrimaryButtonClick={this.onDone}
hasCancel={false}
focus={true}
@ -429,7 +429,7 @@ export default class RestoreKeyBackupDialog extends React.PureComponent<IProps,
autoFocus={true}
/>
<DialogButtons
primaryButton={_t("Next")}
primaryButton={_t("action|next")}
onPrimaryButtonClick={this.onPassPhraseNext}
primaryIsSubmit={true}
hasCancel={true}
@ -501,7 +501,7 @@ export default class RestoreKeyBackupDialog extends React.PureComponent<IProps,
/>
{keyStatus}
<DialogButtons
primaryButton={_t("Next")}
primaryButton={_t("action|next")}
onPrimaryButtonClick={this.onRecoveryKeyNext}
hasCancel={true}
onCancel={this.onCancel}

View file

@ -910,7 +910,7 @@ const SpotlightDialog: React.FC<IProps> = ({ initialText = "", initialFilter = n
copyPlaintext(ownInviteLink);
}}
onHideTooltip={() => setInviteLinkCopied(false)}
title={inviteLinkCopied ? _t("Copied!") : _t("Copy")}
title={inviteLinkCopied ? _t("Copied!") : _t("action|copy")}
>
<span className="mx_AccessibleButton mx_AccessibleButton_hasKind mx_AccessibleButton_kind_primary_outline">
{_t("Copy invite link")}

View file

@ -155,7 +155,7 @@ export default class AppPermission extends React.Component<IProps, IState> {
</div>
<div>
<AccessibleButton kind="primary_sm" onClick={this.props.onPermissionGranted}>
{_t("Continue")}
{_t("action|continue")}
</AccessibleButton>
</div>
</div>

View file

@ -54,7 +54,7 @@ const CopyableText: React.FC<IProps> = ({ children, getTextToCopy, border = true
<div className={combinedClassName}>
{children}
<AccessibleTooltipButton
title={tooltip ?? _t("Copy")}
title={tooltip ?? _t("action|copy")}
onClick={onCopyClickInternal}
className="mx_CopyableText_copyButton"
onHideTooltip={onHideTooltip}

View file

@ -67,14 +67,14 @@ export class EditableItem extends React.Component<IItemProps, IItemState> {
kind="primary_sm"
className="mx_EditableItem_confirmBtn"
>
{_t("Yes")}
{_t("action|yes")}
</AccessibleButton>
<AccessibleButton
onClick={this.onDontRemove}
kind="danger_sm"
className="mx_EditableItem_confirmBtn"
>
{_t("No")}
{_t("action|no")}
</AccessibleButton>
</div>
);
@ -82,7 +82,12 @@ export class EditableItem extends React.Component<IItemProps, IItemState> {
return (
<div className="mx_EditableItem">
<div onClick={this.onRemove} className="mx_EditableItem_delete" title={_t("Remove")} role="button" />
<div
onClick={this.onRemove}
className="mx_EditableItem_delete"
title={_t("action|remove")}
role="button"
/>
<span className="mx_EditableItem_item">{this.props.value}</span>
</div>
);

View file

@ -38,7 +38,7 @@ const LearnMore: React.FC<LearnMoreProps> = ({ title, description, ...rest }) =>
return (
<AccessibleButton {...rest} kind="link_inline" onClick={onClick} className="mx_LearnMore_button">
{_t("Learn more")}
{_t("action|learn_more")}
</AccessibleButton>
);
};

View file

@ -79,7 +79,7 @@ function editingInitialState(editingMxEvent: MatrixEvent): IState {
return {
title: _t("Edit poll"),
actionLabel: _t("Done"),
actionLabel: _t("action|done"),
canSubmit: true,
question: poll.question.text,
options: poll.answers.map((ans) => ans.text),

View file

@ -88,7 +88,7 @@ const SSOButton: React.FC<ISSOButtonProps> = ({
if (idp) {
label = _t("Continue with %(provider)s", { provider: idp.name });
} else if (DELEGATED_OIDC_COMPATIBILITY.findIn<boolean>(flow)) {
label = _t("Continue");
label = _t("action|continue");
} else {
label = _t("Sign in with single sign-on");
}

View file

@ -72,7 +72,7 @@ const ServerPicker: React.FC<IProps> = ({ title, dialogTitle, serverConfig, onSe
};
editBtn = (
<AccessibleButton className="mx_ServerPicker_change" kind="link" onClick={onClick}>
{_t("Edit")}
{_t("action|edit")}
</AccessibleButton>
);
}

View file

@ -53,7 +53,7 @@ export const EnableLiveShare: React.FC<Props> = ({ onSubmit }) => {
onClick={onSubmit}
disabled={!isEnabled}
>
{_t("OK")}
{_t("action|ok")}
</AccessibleButton>
</div>
);

View file

@ -44,7 +44,7 @@ export const MapError: React.FC<MapErrorProps> = ({ error, isMinimised, classNam
<p className="mx_MapError_message">{getLocationShareErrorMessage(error)}</p>
{onFinished && (
<AccessibleButton element="button" kind="primary" onClick={onFinished}>
{_t("OK")}
{_t("action|ok")}
</AccessibleButton>
)}
</div>

View file

@ -63,7 +63,7 @@ const getPermissionsErrorParams = (
const modalParams = {
title: _t("You don't have permission to share locations"),
description: _t("You need to have the right permissions in order to share locations in this room."),
button: _t("OK"),
button: _t("action|ok"),
hasCancelButton: false,
onFinished: () => {}, // NOOP
};

View file

@ -133,9 +133,9 @@ const ActiveLoadedCallEvent = forwardRef<any, ActiveLoadedCallEventProps>(({ mxE
case ConnectionState.Connecting:
return [_t("Join"), "primary", null];
case ConnectionState.Connected:
return [_t("Leave"), "danger", disconnect];
return [_t("action|leave"), "danger", disconnect];
case ConnectionState.Disconnecting:
return [_t("Leave"), "danger", null];
return [_t("action|leave"), "danger", null];
}
}, [connectionState, connect, disconnect]);

View file

@ -137,13 +137,13 @@ export default class EditHistoryMessage extends React.PureComponent<IProps, ISta
// hide the button when already redacted
let redactButton: JSX.Element | undefined;
if (!this.props.mxEvent.isRedacted() && !this.props.isBaseEvent && this.state.canRedact) {
redactButton = <AccessibleButton onClick={this.onRedactClick}>{_t("Remove")}</AccessibleButton>;
redactButton = <AccessibleButton onClick={this.onRedactClick}>{_t("action|remove")}</AccessibleButton>;
}
let viewSourceButton: JSX.Element | undefined;
if (SettingsStore.getValue("developerMode")) {
viewSourceButton = (
<AccessibleButton onClick={this.onViewSourceClick}>{_t("View Source")}</AccessibleButton>
<AccessibleButton onClick={this.onViewSourceClick}>{_t("action|view_source")}</AccessibleButton>
);
}

View file

@ -137,7 +137,7 @@ export default class LegacyCallEvent extends React.PureComponent<IProps, IState>
onClick={this.props.callEventGrouper.rejectCall}
kind="danger"
>
<span> {_t("Decline")} </span>
<span> {_t("action|decline")} </span>
</AccessibleButton>
<AccessibleButton
className="mx_LegacyCallEvent_content_button mx_LegacyCallEvent_content_button_answer"
@ -234,7 +234,7 @@ export default class LegacyCallEvent extends React.PureComponent<IProps, IState>
kind={InfoTooltipKind.Warning}
/>
{_t("Connection failed")}
{this.renderCallBackButton(_t("Retry"))}
{this.renderCallBackButton(_t("action|retry"))}
{this.props.timestamp}
</div>
);

View file

@ -170,7 +170,7 @@ export default class MKeyVerificationRequest extends React.Component<IProps> {
stateNode = (
<div className="mx_cryptoEvent_buttons">
<AccessibleButton kind="danger" onClick={this.onRejectClicked}>
{_t("Decline")}
{_t("action|decline")}
</AccessibleButton>
<AccessibleButton kind="primary" onClick={this.onAcceptClicked}>
{_t("Accept")}

View file

@ -173,7 +173,7 @@ const ReactButton: React.FC<IReactButtonProps> = ({ mxEvent, reactions, onFocusC
<React.Fragment>
<ContextMenuTooltipButton
className="mx_MessageActionBar_iconButton"
title={_t("React")}
title={_t("action|react")}
onClick={onClick}
onContextMenu={onClick}
isExpanded={menuDisplayed}
@ -391,7 +391,7 @@ export default class MessageActionBar extends React.PureComponent<IMessageAction
toolbarOpts.push(
<RovingAccessibleTooltipButton
className="mx_MessageActionBar_iconButton"
title={_t("Edit")}
title={_t("action|edit")}
onClick={this.onEditClick}
onContextMenu={this.onEditClick}
key="edit"
@ -429,7 +429,7 @@ export default class MessageActionBar extends React.PureComponent<IMessageAction
0,
<RovingAccessibleTooltipButton
className="mx_MessageActionBar_iconButton"
title={_t("Retry")}
title={_t("action|retry")}
onClick={this.onResendClick}
onContextMenu={this.onResendClick}
key="resend"
@ -455,7 +455,7 @@ export default class MessageActionBar extends React.PureComponent<IMessageAction
0,
<RovingAccessibleTooltipButton
className="mx_MessageActionBar_iconButton"
title={_t("Reply")}
title={_t("action|reply")}
onClick={this.onReplyClick}
onContextMenu={this.onReplyClick}
key="reply"

View file

@ -499,7 +499,7 @@ export default class TextualBody extends React.Component<IBodyProps, IState> {
)}
</div>
),
button: _t("Continue"),
button: _t("action|continue"),
onFinished(confirmed) {
if (!confirmed) {
return;

View file

@ -95,7 +95,7 @@ export default class TileErrorBoundary extends React.Component<IProps, IState> {
<>
&nbsp;
<AccessibleButton onClick={this.onViewSource} kind="link">
{_t("View Source")}
{_t("action|view_source")}
</AccessibleButton>
</>
);

View file

@ -127,8 +127,8 @@ export const WidgetPip: FC<Props> = ({ widgetId, room, viewingRoom, onStartMovin
<Toolbar className="mx_WidgetPip_footer">
<RovingAccessibleTooltipButton
onClick={onLeaveClick}
tooltip={_t("Leave")}
aria-label={_t("Leave")}
tooltip={_t("action|leave")}
aria-label={_t("action|leave")}
alignment={Alignment.Top}
>
<HangupIcon className="mx_Icon mx_Icon_24" />

View file

@ -486,7 +486,7 @@ export const UserOptionsSection: React.FC<{
inviteUserButton = (
<AccessibleButton kind="link" onClick={onInviteUserButton} className="mx_UserInfo_field">
{_t("Invite")}
{_t("action|invite")}
</AccessibleButton>
);
}
@ -1186,7 +1186,7 @@ export const PowerLevelEditor: React.FC<{
{_t("Are you sure?")}
</div>
),
button: _t("Continue"),
button: _t("action|continue"),
});
const [confirmed] = await finished;

View file

@ -123,7 +123,7 @@ export default class VerificationPanel extends React.PureComponent<IProps, IStat
onClick={this.startSAS}
kind="primary"
>
{_t("Start")}
{_t("action|start")}
</AccessibleButton>
</div>
);
@ -254,14 +254,14 @@ export default class VerificationPanel extends React.PureComponent<IProps, IStat
disabled={this.state.reciprocateButtonClicked}
onClick={this.onReciprocateNoClick}
>
{_t("No")}
{_t("action|no")}
</AccessibleButton>
<AccessibleButton
kind="primary"
disabled={this.state.reciprocateButtonClicked}
onClick={this.onReciprocateYesClick}
>
{_t("Yes")}
{_t("action|yes")}
</AccessibleButton>
</div>
</React.Fragment>

View file

@ -229,7 +229,7 @@ export default class RoomProfileSettings extends React.Component<IProps, IState>
{_t("Cancel")}
</AccessibleButton>
<AccessibleButton onClick={this.saveProfile} kind="primary" disabled={!this.isSaveEnabled()}>
{_t("Save")}
{_t("action|save")}
</AccessibleButton>
</div>
);

View file

@ -490,7 +490,7 @@ class EditMessageComposer extends React.Component<IEditMessageComposerProps, ISt
{_t("Cancel")}
</AccessibleButton>
<AccessibleButton kind="primary" onClick={this.sendEdit} disabled={this.state.saveDisabled}>
{_t("Save")}
{_t("action|save")}
</AccessibleButton>
</div>
</div>

View file

@ -162,7 +162,7 @@ export default class EntityTile extends React.PureComponent<IProps, IState> {
inviteButton = (
<div className="mx_EntityTile_invite">
<img
alt={_t("Invite")}
alt={_t("action|invite")}
src={require("../../../../res/img/plus.svg").default}
width="16"
height="16"

View file

@ -618,7 +618,7 @@ export default class RoomHeader extends React.Component<IProps, IState> {
<AccessibleTooltipButton
className="mx_LegacyRoomHeader_button mx_LegacyRoomHeader_inviteButton"
onClick={this.props.onInviteClick}
title={_t("Invite")}
title={_t("action|invite")}
alignment={Alignment.Bottom}
key="invite"
/>,

View file

@ -81,7 +81,7 @@ export default class MessageComposerFormatBar extends React.PureComponent<IProps
visible={this.state.visible}
/>
<FormatButton
label={_t("Quote")}
label={_t("action|quote")}
onClick={() => this.props.onAction(Formatting.Quote)}
icon="Quote"
shortcut={this.props.shortcuts.quote}

View file

@ -195,8 +195,8 @@ const DmAuxButton: React.FC<IAuxButtonProps> = ({ tabIndex, dispatcher = default
}}
className="mx_RoomSublist_auxButton"
tooltipClassName="mx_RoomSublist_addRoomTooltip"
aria-label={_t("Start chat")}
title={_t("Start chat")}
aria-label={_t("action|start_chat")}
title={_t("action|start_chat")}
/>
);
}
@ -387,7 +387,7 @@ const UntaggedAuxButton: React.FC<IAuxButtonProps> = ({ tabIndex }) => {
const TAG_AESTHETICS: TagAestheticsMap = {
[DefaultTagID.Invite]: {
sectionLabel: _td("Invites"),
sectionLabel: _td("action|invites_list"),
isInvite: true,
defaultHidden: false,
},

View file

@ -185,7 +185,7 @@ const RoomListHeader: React.FC<IProps> = ({ onVisibilityChange }) => {
if (shouldShowSpaceInvite(activeSpace)) {
inviteOption = (
<IconizedContextMenuOption
label={_t("Invite")}
label={_t("action|invite")}
iconClassName="mx_RoomListHeader_iconInvite"
onClick={(e) => {
e.preventDefault();

View file

@ -84,7 +84,7 @@ const RoomPreviewCard: FC<IProps> = ({ room, onJoinButtonClicked, onRejectButton
});
}}
>
{_t("Leave")}
{_t("action|leave")}
</AccessibleButton>
);
} else if (myMembership === "invite") {

View file

@ -36,7 +36,7 @@ export function EditionButtons({
{_t("Cancel")}
</AccessibleButton>
<AccessibleButton kind="primary" onClick={onSaveClick} disabled={isSaveDisabled}>
{_t("Save")}
{_t("action|save")}
</AccessibleButton>
</div>
);

View file

@ -148,7 +148,7 @@ export function FormattingButtons({ composer, actionStates }: FormattingButtonsP
)}
<Button
actionState={actionStates.quote}
label={_t("Quote")}
label={_t("action|quote")}
onClick={() => composer.quote()}
icon={<QuoteIcon className="mx_FormattingButtons_Icon" />}
/>

View file

@ -128,11 +128,11 @@ export const LinkModal: React.FC<LinkModalProps> = ({
onFinished();
}}
>
{_t("Remove")}
{_t("action|remove")}
</button>
)}
<DialogButtons
primaryButton={_t("Save")}
primaryButton={_t("action|save")}
primaryDisabled={isSaveDisabled}
primaryIsSubmit={true}
onCancel={onFinished}

View file

@ -80,7 +80,7 @@ const AvatarSetting: React.FC<IProps> = ({ avatarUrl, avatarAltText, avatarName,
if (avatarUrl && removeAvatar) {
removeAvatarBtn = (
<AccessibleButton onClick={removeAvatar} kind="link_sm">
{_t("Remove")}
{_t("action|remove")}
</AccessibleButton>
);
}

View file

@ -172,7 +172,7 @@ export default class EventIndexPanel extends React.Component<{}, IState> {
</SettingsSubsectionText>
<div>
<AccessibleButton kind="primary" disabled={this.state.enabling} onClick={this.onEnable}>
{_t("Enable")}
{_t("action|enable")}
</AccessibleButton>
{this.state.enabling ? <InlineSpinner /> : <div />}
</div>

View file

@ -219,7 +219,7 @@ export default class ProfileSettings extends React.Component<{}, IState> {
kind="primary"
disabled={!this.state.enableProfileSave}
>
{_t("Save")}
{_t("action|save")}
</AccessibleButton>
</div>
</form>

View file

@ -200,7 +200,7 @@ export default class SetIdServer extends React.Component<IProps, IState> {
new: (sub) => <b>{abbreviateUrl(idServer)}</b>,
},
),
button: _t("Continue"),
button: _t("action|continue"),
});
save = !!confirmed;
}
@ -232,7 +232,7 @@ export default class SetIdServer extends React.Component<IProps, IState> {
<span>&nbsp;{_t("Only continue if you trust the owner of the server.")}</span>
</div>
),
button: _t("Continue"),
button: _t("action|continue"),
});
return finished;
}

View file

@ -47,7 +47,7 @@ export class ExistingSpellCheckLanguage extends React.Component<ExistingSpellChe
<div className="mx_ExistingSpellCheckLanguage">
<span className="mx_ExistingSpellCheckLanguage_language">{this.props.language}</span>
<AccessibleButton onClick={this.onRemove} kind="danger_sm">
{_t("Remove")}
{_t("action|remove")}
</AccessibleButton>
</div>
);

View file

@ -107,7 +107,7 @@ export class ExistingEmailAddress extends React.Component<IExistingEmailAddressP
kind="danger_sm"
className="mx_GeneralUserSettingsTab_section--discovery_existing_button"
>
{_t("Remove")}
{_t("action|remove")}
</AccessibleButton>
<AccessibleButton
onClick={this.onDontRemove}
@ -126,7 +126,7 @@ export class ExistingEmailAddress extends React.Component<IExistingEmailAddressP
{this.props.email.address}
</span>
<AccessibleButton onClick={this.onRemove} kind="danger_sm" disabled={this.props.disabled}>
{_t("Remove")}
{_t("action|remove")}
</AccessibleButton>
</div>
);
@ -284,7 +284,7 @@ export default class EmailAddresses extends React.Component<IProps, IState> {
kind="primary"
disabled={this.state.continueDisabled}
>
{_t("Continue")}
{_t("action|continue")}
</AccessibleButton>
</div>
);

View file

@ -102,7 +102,7 @@ export class ExistingPhoneNumber extends React.Component<IExistingPhoneNumberPro
kind="danger_sm"
className="mx_GeneralUserSettingsTab_section--discovery_existing_button"
>
{_t("Remove")}
{_t("action|remove")}
</AccessibleButton>
<AccessibleButton
onClick={this.onDontRemove}
@ -121,7 +121,7 @@ export class ExistingPhoneNumber extends React.Component<IExistingPhoneNumberPro
+{this.props.msisdn.address}
</span>
<AccessibleButton onClick={this.onRemove} kind="danger_sm" disabled={this.props.disabled}>
{_t("Remove")}
{_t("action|remove")}
</AccessibleButton>
</div>
);
@ -304,7 +304,7 @@ export default class PhoneNumbers extends React.Component<IProps, IState> {
this.state.newPhoneNumberCode.length === 0
}
>
{_t("Continue")}
{_t("action|continue")}
</AccessibleButton>
</form>
</div>

View file

@ -109,7 +109,7 @@ const DeviceNameEditor: React.FC<Props & { stopEditing: () => void }> = ({ devic
data-testid="device-rename-submit-cta"
disabled={isLoading}
>
{_t("Save")}
{_t("action|save")}
</AccessibleButton>
<AccessibleButton
onClick={stopEditing}

View file

@ -75,9 +75,9 @@ export default class GeneralRoomSettingsTab extends React.Component<IProps, ISta
let leaveSection;
if (room.getMyMembership() === "join") {
leaveSection = (
<SettingsSubsection heading={_t("Leave room")}>
<SettingsSubsection heading={_t("action|leave_room")}>
<AccessibleButton kind="danger" onClick={this.onLeaveClick}>
{_t("Leave room")}
{_t("action|leave_room")}
</AccessibleButton>
</SettingsSubsection>
);

View file

@ -304,7 +304,7 @@ export default class NotificationsSettingsTab extends React.Component<IProps, IS
onClick={this.onClickSaveSound}
kind="primary"
>
{_t("Save")}
{_t("action|save")}
</AccessibleButton>
<br />
</div>

View file

@ -185,7 +185,7 @@ export default class MjolnirUserSettingsTab extends React.Component<{}, IState>
onClick={() => this.removePersonalRule(rule)}
disabled={this.state.busy}
>
{_t("Remove")}
{_t("action|remove")}
</AccessibleButton>
&nbsp;
<code>{rule.entity}</code>

View file

@ -312,7 +312,7 @@ export default class SecurityUserSettingsTab extends React.Component<IProps, ISt
if (PosthogAnalytics.instance.isEnabled()) {
const onClickAnalyticsLearnMore = (): void => {
showAnalyticsLearnMoreDialog({
primaryButton: _t("OK"),
primaryButton: _t("action|ok"),
hasCancel: false,
});
};
@ -325,7 +325,7 @@ export default class SecurityUserSettingsTab extends React.Component<IProps, ISt
)}
>
<AccessibleButton kind="link" onClick={onClickAnalyticsLearnMore}>
{_t("Learn more")}
{_t("action|learn_more")}
</AccessibleButton>
{PosthogAnalytics.instance.isEnabled() && (
<SettingsFlag name="pseudonymousAnalyticsOptIn" level={SettingLevel.ACCOUNT} />

View file

@ -341,7 +341,7 @@ const SpaceCreateMenu: React.FC<{
/>
<AccessibleButton kind="primary" onClick={onSpaceCreateClick} disabled={busy}>
{busy ? _t("Creating…") : _t("Create")}
{busy ? _t("Creating…") : _t("action|create")}
</AccessibleButton>
</React.Fragment>
);

View file

@ -126,7 +126,7 @@ export default class InlineTermsAgreement extends React.Component<IProps, IState
disabled={hasUnchecked || this.state.busy}
kind="primary_sm"
>
{_t("Continue")}
{_t("action|continue")}
</AccessibleButton>
</div>
);

Some files were not shown because too many files have changed in this diff Show more