fix localization strings with command:
. For #125786
This commit is contained in:
parent
83d889c27f
commit
edcd499235
4 changed files with 34 additions and 11 deletions
|
@ -233,9 +233,10 @@ class FormatOnSaveParticipant implements ITextFileSaveParticipant {
|
|||
const nestedProgress = new Progress<{ displayName?: string, extensionId?: ExtensionIdentifier }>(provider => {
|
||||
progress.report({
|
||||
message: localize(
|
||||
'formatting',
|
||||
"Running '{0}' Formatter ([configure](command:workbench.action.openSettings?%5B%22editor.formatOnSave%22%5D)).",
|
||||
provider.displayName || provider.extensionId && provider.extensionId.value || '???'
|
||||
{ key: 'formatting2', comment: ['[configure]({1}) is a link. Only translate `configure`. Do not change brackets and parentheses or {1}'] },
|
||||
"Running '{0}' Formatter ([configure]({1})).",
|
||||
provider.displayName || provider.extensionId && provider.extensionId.value || '???',
|
||||
'command:workbench.action.openSettings?%5B%22editor.formatOnSave%22%5D'
|
||||
)
|
||||
});
|
||||
});
|
||||
|
@ -336,9 +337,10 @@ class CodeActionOnSaveParticipant implements ITextFileSaveParticipant {
|
|||
private _report(): void {
|
||||
progress.report({
|
||||
message: localize(
|
||||
'codeaction.get',
|
||||
"Getting code actions from '{0}' ([configure](command:workbench.action.openSettings?%5B%22editor.codeActionsOnSave%22%5D)).",
|
||||
[...this._names].map(name => `'${name}'`).join(', ')
|
||||
{ key: 'codeaction.get2', comment: ['[configure]({1}) is a link. Only translate `configure`. Do not change brackets and parentheses or {1}'] },
|
||||
"Getting code actions from '{0}' ([configure]({1})).",
|
||||
[...this._names].map(name => `'${name}'`).join(', '),
|
||||
'command:workbench.action.openSettings?%5B%22editor.codeActionsOnSave%22%5D'
|
||||
)
|
||||
});
|
||||
}
|
||||
|
|
|
@ -314,7 +314,9 @@ class OnAutoForwardedAction extends Disposable {
|
|||
}
|
||||
|
||||
private linkMessage() {
|
||||
return nls.localize('remote.tunnelsView.notificationLink', "[See all forwarded ports](command:{0}.focus)", TunnelPanel.ID);
|
||||
return nls.localize(
|
||||
{ key: 'remote.tunnelsView.notificationLink2', comment: ['[See all forwarded ports]({0}) is a link. Only translate `See all forwarded ports`. Do not change brackets and parentheses or {0}'] },
|
||||
"[See all forwarded ports]({0})", `command:${TunnelPanel.ID}.focus`);
|
||||
}
|
||||
|
||||
private async showNotification(tunnel: RemoteTunnel) {
|
||||
|
|
|
@ -301,7 +301,11 @@ export class RemoteStatusIndicator extends Disposable implements IWorkbenchContr
|
|||
const workspaceLabel = this.getWorkspaceLabel();
|
||||
if (workspaceLabel) {
|
||||
const toolTip: IMarkdownString = {
|
||||
value: nls.localize('workspace.tooltip', "Virtual workspace on {0}\n\n[Some features](command:{1}) are not available for resources located on a virtual file system.", workspaceLabel, LIST_WORKSPACE_UNSUPPORTED_EXTENSIONS_COMMAND_ID),
|
||||
value: nls.localize(
|
||||
{ key: 'workspace.tooltip2', comment: ['[abc]({1}) is a link. Only translate `Some features`. Do not change brackets and parentheses or {1}'] },
|
||||
"Virtual workspace on {0}\n\n[Some features]({1}) are not available for resources located on a virtual file system.",
|
||||
workspaceLabel, `command:${LIST_WORKSPACE_UNSUPPORTED_EXTENSIONS_COMMAND_ID}`
|
||||
),
|
||||
isTrusted: true
|
||||
};
|
||||
this.renderRemoteStatusIndicator(`$(remote) ${truncate(workspaceLabel, RemoteStatusIndicator.REMOTE_STATUS_LABEL_MAX_LENGTH)}`, toolTip);
|
||||
|
|
|
@ -374,7 +374,12 @@ export class WorkspaceTrustUXHandler extends Disposable implements IWorkbenchCon
|
|||
ariaLabel = trusted ? localize('status.ariaTrustedWindow', "This window is trusted.") :
|
||||
localize('status.ariaUntrustedWindow', "Restricted Mode: Some features are disabled because this window is not trusted.");
|
||||
toolTip = trusted ? ariaLabel : {
|
||||
value: localize('status.tooltipUntrustedWindow', "Running in Restricted Mode\n\n\Some [features are disabled](command:{0}) because this [window is not trusted](command:{1}).", LIST_WORKSPACE_UNSUPPORTED_EXTENSIONS_COMMAND_ID, MANAGE_TRUST_COMMAND_ID),
|
||||
value: localize(
|
||||
{ key: 'status.tooltipUntrustedWindow2', comment: ['[abc]({n}) are links. Only translate `features are disabled` and `window is not trusted`. Do not change brackets and parentheses or {n}'] },
|
||||
"Running in Restricted Mode\n\nSome [features are disabled]({0}) because this [window is not trusted]({1}).",
|
||||
`command:${LIST_WORKSPACE_UNSUPPORTED_EXTENSIONS_COMMAND_ID}`,
|
||||
`command:${MANAGE_TRUST_COMMAND_ID}`
|
||||
),
|
||||
isTrusted: true,
|
||||
supportThemeIcons: true
|
||||
};
|
||||
|
@ -384,7 +389,12 @@ export class WorkspaceTrustUXHandler extends Disposable implements IWorkbenchCon
|
|||
ariaLabel = trusted ? localize('status.ariaTrustedFolder', "This folder is trusted.") :
|
||||
localize('status.ariaUntrustedFolder', "Restricted Mode: Some features are disabled because this folder is not trusted.");
|
||||
toolTip = trusted ? ariaLabel : {
|
||||
value: localize('status.tooltipUntrustedFolder', "Running in Restricted Mode\n\n\Some [features are disabled](command:{0}) because this [folder is not trusted](command:{1}).", LIST_WORKSPACE_UNSUPPORTED_EXTENSIONS_COMMAND_ID, MANAGE_TRUST_COMMAND_ID),
|
||||
value: localize(
|
||||
{ key: 'status.tooltipUntrustedFolder2', comment: ['[abc]({n}) are links. Only translate `features are disabled` and `folder is not trusted`. Do not change brackets and parentheses or {n}'] },
|
||||
"Running in Restricted Mode\n\nSome [features are disabled]({0}) because this [folder is not trusted]({1}).",
|
||||
`command:${LIST_WORKSPACE_UNSUPPORTED_EXTENSIONS_COMMAND_ID}`,
|
||||
`command:${MANAGE_TRUST_COMMAND_ID}`
|
||||
),
|
||||
isTrusted: true,
|
||||
supportThemeIcons: true
|
||||
};
|
||||
|
@ -394,7 +404,12 @@ export class WorkspaceTrustUXHandler extends Disposable implements IWorkbenchCon
|
|||
ariaLabel = trusted ? localize('status.ariaTrustedWorkspace', "This workspace is trusted.") :
|
||||
localize('status.ariaUntrustedWorkspace', "Restricted Mode: Some features are disabled because this workspace is not trusted.");
|
||||
toolTip = trusted ? ariaLabel : {
|
||||
value: localize('status.tooltipUntrustedWorkspace', "Running in Restricted Mode\n\n\Some [features are disabled](command:{0}) because this [workspace is not trusted](command:{1}).", LIST_WORKSPACE_UNSUPPORTED_EXTENSIONS_COMMAND_ID, MANAGE_TRUST_COMMAND_ID),
|
||||
value: localize(
|
||||
{ key: 'status.tooltipUntrustedWorkspace2', comment: ['[abc]({n}) are links. Only translate `features are disabled` and `workspace is not trusted`. Do not change brackets and parentheses or {n}'] },
|
||||
"Running in Restricted Mode\n\nSome [features are disabled]({0}) because this [workspace is not trusted]({1}).",
|
||||
`command:${LIST_WORKSPACE_UNSUPPORTED_EXTENSIONS_COMMAND_ID}`,
|
||||
`command:${MANAGE_TRUST_COMMAND_ID}`
|
||||
),
|
||||
isTrusted: true,
|
||||
supportThemeIcons: true
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue