-
Notifications
You must be signed in to change notification settings - Fork 469
/
Copy pathlocConstants.ts
814 lines (798 loc) · 32.5 KB
/
locConstants.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { l10n } from "vscode";
// Warning: Only update these strings if you are sure you want to affect _all_ locations they're shared between.
export class Common {
public static remindMeLater = l10n.t("Remind Me Later");
public static dontShowAgain = l10n.t("Don't Show Again");
public static learnMore = l10n.t("Learn More");
public static delete = l10n.t("Delete");
public static cancel = l10n.t("Cancel");
public static areYouSure = l10n.t("Are you sure?");
public static areYouSureYouWantTo = (action: string) =>
l10n.t({
message: "Are you sure you want to {0}?",
args: [action],
comment: ["{0} is the action being confirmed"],
});
}
export let viewMore = l10n.t("View More");
export let releaseNotesPromptDescription = l10n.t(
"View mssql for Visual Studio Code release notes?",
);
export function msgStartedExecute(documentName: string) {
return l10n.t({
message: 'Started query execution for document "{0}"',
args: [documentName],
comment: ["{0} is the document name"],
});
}
export function msgFinishedExecute(documentName: string) {
return l10n.t({
message: 'Finished query execution for document "{0}"',
args: [documentName],
comment: ["{0} is the document name"],
});
}
export let msgRunQueryInProgress = l10n.t(
"A query is already running for this editor session. Please cancel this query or wait for its completion.",
);
export let runQueryBatchStartMessage = l10n.t("Started executing query at ");
export function runQueryBatchStartLine(lineNumber: number) {
return l10n.t({
message: "Line {0}",
args: [lineNumber],
comment: ["{0} is the line number"],
});
}
export function msgCancelQueryFailed(error: string) {
return l10n.t({
message: "Canceling the query failed: {0}",
args: [error],
comment: ["{0} is the error message"],
});
}
export let msgCancelQueryNotRunning = l10n.t(
"Cannot cancel query as no query is running.",
);
export let msgChooseDatabaseNotConnected = l10n.t(
"No connection was found. Please connect to a server first.",
);
export let msgChooseDatabasePlaceholder = l10n.t(
"Choose a database from the list below",
);
export function msgConnectionError(errorNumber: number, errorMessage: string) {
return l10n.t({
message: "Error {0}: {1}",
args: [errorNumber, errorMessage],
comment: ["{0} is the error number", "{1} is the error message"],
});
}
export function msgConnectionError2(errorMessage: string) {
return l10n.t({
message: "Failed to connect: {0}",
args: [errorMessage],
comment: ["{0} is the error message"],
});
}
export let serverNameMissing = l10n.t("Server name not set.");
export function msgConnectionErrorPasswordExpired(
errorNumber: number,
errorMessage: string,
) {
return l10n.t({
message:
"Error {0}: {1} Please login as a different user and change the password using ALTER LOGIN.",
args: [errorNumber, errorMessage],
comment: ["{0} is the error number", "{1} is the error message"],
});
}
export let connectionErrorChannelName = l10n.t("Connection Errors");
export let msgPromptCancelConnect = l10n.t(
"Server connection in progress. Do you want to cancel?",
);
export let msgPromptClearRecentConnections = l10n.t(
"Confirm to clear recent connections list",
);
export let msgOpenSqlFile = l10n.t(
'To use this command, Open a .sql file -or- Change editor language to "SQL" -or- Select T-SQL text in the active SQL editor.',
);
export let recentConnectionsPlaceholder = l10n.t(
"Choose a connection profile from the list below",
);
export let CreateProfileFromConnectionsListLabel = l10n.t(
"Create Connection Profile",
);
export let CreateProfileLabel = l10n.t("Create");
export let ClearRecentlyUsedLabel = l10n.t("Clear Recent Connections List");
export let EditProfilesLabel = l10n.t("Edit");
export let RemoveProfileLabel = l10n.t("Remove");
export let ManageProfilesPrompt = l10n.t("Manage Connection Profiles");
export let SampleServerName = l10n.t("{{put-server-name-here}}");
export let serverPrompt = l10n.t("Server name or ADO.NET connection string");
export let serverPlaceholder = l10n.t(
"hostname\\instance or <server>.database.windows.net or ADO.NET connection string",
);
export let databasePrompt = l10n.t("Database name");
export let startIpAddressPrompt = l10n.t("Start IP Address");
export let endIpAddressPrompt = l10n.t("End IP Address");
export let firewallRuleNamePrompt = l10n.t("Firewall rule name");
export let databasePlaceholder = l10n.t(
"[Optional] Database to connect (press Enter to connect to <default> database)",
);
export let authTypePrompt = l10n.t("Authentication Type");
export let authTypeName = l10n.t("authenticationType");
export let authTypeIntegrated = l10n.t("Integrated");
export let authTypeSql = l10n.t("SQL Login");
export let authTypeAzureActiveDirectory = l10n.t(
"Microsoft Entra Id - Universal w/ MFA Support",
);
export let azureAuthTypeCodeGrant = l10n.t("Azure Code Grant");
export let azureAuthTypeDeviceCode = l10n.t("Azure Device Code");
export let azureLogChannelName = l10n.t("Azure Logs");
export let azureConsentDialogOpen = l10n.t("Open");
export let azureConsentDialogIgnore = l10n.t("Ignore Tenant");
export function azureConsentDialogBody(
tenantName: string,
tenantId: string,
resource: string,
) {
return l10n.t({
message:
"Your tenant '{0} ({1})' requires you to re-authenticate again to access {2} resources. Press Open to start the authentication process.",
args: [tenantName, tenantId, resource],
comment: [
"{0} is the tenant name",
"{1} is the tenant id",
"{2} is the resource",
],
});
}
export function azureConsentDialogBodyAccount(resource: string) {
return l10n.t({
message:
"Your account needs re-authentication to access {0} resources. Press Open to start the authentication process.",
args: [resource],
comment: ["{0} is the resource"],
});
}
export let azureMicrosoftCorpAccount = l10n.t("Microsoft Corp");
export let azureMicrosoftAccount = l10n.t("Microsoft Entra Account");
export function azureNoMicrosoftResource(provider: string) {
return l10n.t({
message:
"Provider '{0}' does not have a Microsoft resource endpoint defined.",
args: [provider],
comment: ["{0} is the provider"],
});
}
export let unableToGetProxyAgentOptionsToGetTenants = l10n.t(
"Unable to read proxy agent options to get tenants.",
);
export let azureServerCouldNotStart = l10n.t(
"Server could not start. This could be a permissions error or an incompatibility on your system. You can try enabling device code authentication from settings.",
);
export let azureAuthNonceError = l10n.t(
"Authentication failed due to a nonce mismatch, please close Azure Data Studio and try again.",
);
export let azureAuthStateError = l10n.t(
"Authentication failed due to a state mismatch, please close ADS and try again.",
);
export let encryptPrompt = l10n.t("Encrypt");
export let encryptName = l10n.t("encrypt");
export let encryptOptional = l10n.t("Optional (False)");
export let encryptMandatory = l10n.t("Mandatory (True)");
export let encryptMandatoryRecommended = l10n.t("Mandatory (Recommended)");
export let enableTrustServerCertificate = l10n.t(
"Enable Trust Server Certificate",
);
export let readMore = l10n.t("Read more");
export let msgCopyAndOpenWebpage = l10n.t("Copy code and open webpage");
export let azureChooseAccount = l10n.t("Choose a Microsoft Entra account");
export let azureAddAccount = l10n.t("Add a Microsoft Entra account...");
export function accountAddedSuccessfully(account: string) {
return l10n.t({
message: "Microsoft Entra account {0} successfully added.",
args: [account],
comment: ["{0} is the account name"],
});
}
export let accountCouldNotBeAdded = l10n.t(
"New Microsoft Entra account could not be added.",
);
export let accountRemovedSuccessfully = l10n.t(
"Selected Microsoft Entra account removed successfully.",
);
export function accountRemovalFailed(error: string) {
return l10n.t({
message:
"An error occurred while removing Microsoft Entra account: {0}",
args: [error],
comment: ["{0} is the error message"],
});
}
export let noAzureAccountForRemoval = l10n.t(
"No Microsoft Entra account can be found for removal.",
);
export let clearedAzureTokenCache = l10n.t(
"Azure token cache cleared successfully.",
);
export let cannotConnect = l10n.t(
"Cannot connect due to expired tokens. Please re-authenticate and try again.",
);
export let aad = l10n.t("Microsoft Entra Id");
export let azureChooseTenant = l10n.t("Choose a Microsoft Entra tenant");
export let tenant = l10n.t("Tenant");
export let usernamePrompt = l10n.t("User name");
export let usernamePlaceholder = l10n.t("User name (SQL Login)");
export let passwordPrompt = l10n.t("Password");
export let passwordPlaceholder = l10n.t("Password (SQL Login)");
export let msgSavePassword = l10n.t(
"Save Password? If 'No', password will be required each time you connect",
);
export let profileNamePrompt = l10n.t("Profile Name");
export let profileNamePlaceholder = l10n.t(
"[Optional] Enter a display name for this connection profile",
);
export let msgCannotOpenContent = l10n.t(
"Error occurred opening content in editor.",
);
export let msgSaveStarted = l10n.t("Started saving results to ");
export let msgSaveFailed = l10n.t("Failed to save results. ");
export let msgSaveSucceeded = l10n.t("Successfully saved results to ");
export let msgSelectProfileToRemove = l10n.t("Select profile to remove");
export let confirmRemoveProfilePrompt = l10n.t(
"Confirm to remove this profile.",
);
export let msgNoProfilesSaved = l10n.t("No connection profile to remove.");
export let msgProfileRemoved = l10n.t("Profile removed successfully");
export let msgProfileCreated = l10n.t("Profile created successfully");
export let msgProfileCreatedAndConnected = l10n.t(
"Profile created and connected",
);
export let msgClearedRecentConnections = l10n.t(
"Recent connections list cleared",
);
export let msgIsRequired = l10n.t(" is required.");
export let msgError = l10n.t("Error: ");
export let msgYes = l10n.t("Yes");
export let msgNo = l10n.t("No");
export let defaultDatabaseLabel = l10n.t("<default>");
export let notConnectedLabel = l10n.t("Disconnected");
export let notConnectedTooltip = l10n.t("Click to connect to a database");
export let connectingLabel = l10n.t("Connecting");
export let connectingTooltip = l10n.t("Connecting to: ");
export let connectErrorLabel = l10n.t("Connection error");
export let connectErrorTooltip = l10n.t("Error connecting to: ");
export let connectErrorCode = l10n.t("Error code: ");
export let connectErrorMessage = l10n.t("Error Message: ");
export let cancelingQueryLabel = l10n.t("Canceling query ");
export let updatingIntelliSenseLabel = l10n.t("Updating IntelliSense...");
export let extensionNotInitializedError = l10n.t(
"Unable to execute the command while the extension is initializing. Please try again later.",
);
export let untitledScheme = l10n.t("untitled");
export let msgChangeLanguageMode = l10n.t(
'To use this command, you must set the language to "SQL". Confirm to change language mode.',
);
export function msgChangedDatabaseContext(
databaseName: string,
documentName: string,
) {
return l10n.t({
message: 'Changed database context to "{0}" for document "{1}"',
args: [databaseName, documentName],
comment: ["{0} is the database name", "{1} is the document name"],
});
}
export let msgPromptRetryCreateProfile = l10n.t(
"Error: Unable to connect using the connection information provided. Retry profile creation?",
);
export let refreshTokenLabel = l10n.t("Refresh Credentials");
export let msgGetTokenFail = l10n.t("Failed to fetch user tokens.");
export let msgPromptRetryConnectionDifferentCredentials = l10n.t(
"Error: Login failed. Retry using different credentials?",
);
export let msgPromptSSLCertificateValidationFailed = l10n.t(
"Encryption was enabled on this connection; review your SSL and certificate configuration for the target SQL Server, or set 'Trust server certificate' to 'true' in the settings file. Note: A self-signed certificate offers only limited protection and is not a recommended practice for production environments. Do you want to enable 'Trust server certificate' on this connection and retry?",
);
export let msgPromptRetryFirewallRuleNotSignedIn = l10n.t(
"Your client IP address does not have access to the server. Add a Microsoft Entra account and create a new firewall rule to enable access.",
);
export function msgPromptRetryFirewallRuleSignedIn(
clientIp: string,
serverName: string,
) {
return l10n.t({
message:
"Your client IP Address '{0}' does not have access to the server '{1}' you're attempting to connect to. Would you like to create new firewall rule?",
args: [clientIp, serverName],
comment: ["{0} is the client IP address", "{1} is the server name"],
});
}
export let msgPromptRetryFirewallRuleAdded = l10n.t(
"Firewall rule successfully added. Retry profile creation? ",
);
export let msgAccountRefreshFailed = l10n.t(
"Credential Error: An error occurred while attempting to refresh account credentials. Please re-authenticate.",
);
export let msgPromptProfileUpdateFailed = l10n.t(
"Connection Profile could not be updated. Please modify the connection details manually in settings.json and try again.",
);
export let msgUnableToExpand = l10n.t(
"Unable to expand. Please check logs for more information.",
);
export let msgPromptFirewallRuleCreated = l10n.t(
"Firewall rule successfully created.",
);
export let msgAuthTypeNotFound = l10n.t(
"Failed to get authentication method, please remove and re-add the account.",
);
export let msgAccountNotFound = l10n.t("Account not found");
export let msgChooseQueryHistory = l10n.t("Choose Query History");
export let msgChooseQueryHistoryAction = l10n.t("Choose An Action");
export let msgOpenQueryHistory = l10n.t("Open Query History");
export let msgRunQueryHistory = l10n.t("Run Query History");
export let msgInvalidIpAddress = l10n.t("Invalid IP Address");
export let msgInvalidRuleName = l10n.t("Invalid Firewall rule name");
export let msgNoQueriesAvailable = l10n.t("No Queries Available");
export let retryLabel = l10n.t("Retry");
export let createFirewallRuleLabel = l10n.t("Create Firewall Rule");
export function msgConnecting(serverName: string, documentName: string) {
return l10n.t({
message: 'Connecting to server "{0}" on document "{1}".',
args: [serverName, documentName],
comment: ["{0} is the server name", "{1} is the document name"],
});
}
export function msgConnectionNotFound(uri: string) {
return l10n.t({
message: 'Connection not found for uri "{0}".',
args: [uri],
comment: ["{0} is the uri"],
});
}
export function msgFoundPendingReconnect(uri: string) {
return l10n.t({
message: "Found pending reconnect promise for uri {0}, waiting.",
args: [uri],
comment: ["{0} is the uri"],
});
}
export function msgPendingReconnectSuccess(uri: string) {
return l10n.t({
message: "Previous pending reconnection for uri {0}, succeeded.",
args: [uri],
comment: ["{0} is the uri"],
});
}
export function msgFoundPendingReconnectFailed(uri: string) {
return l10n.t({
message: "Found pending reconnect promise for uri {0}, failed.",
args: [uri],
comment: ["{0} is the uri"],
});
}
export function msgFoundPendingReconnectError(uri: string, error: string) {
return l10n.t({
message:
"Previous pending reconnect promise for uri {0} is rejected with error {1}, will attempt to reconnect if necessary.",
args: [uri, error],
comment: ["{0} is the uri", "{1} is the error"],
});
}
export function msgAcessTokenExpired(connectionId: string, uri: string) {
return l10n.t({
message: "Access token expired for connection {0} with uri {1}",
args: [connectionId, uri],
comment: ["{0} is the connection id", "{1} is the uri"],
});
}
export let msgRefreshTokenError = l10n.t("Error when refreshing token");
export let msgAzureCredStoreSaveFailedError = l10n.t(
'Keys for token cache could not be saved in credential store, this may cause Microsoft Entra Id access token persistence issues and connection instabilities. It\'s likely that SqlTools has reached credential storage limit on Windows, please clear at least 2 credentials that start with "Microsoft.SqlTools|" in Windows Credential Manager and reload.',
);
export function msgRefreshConnection(connectionId: string, uri: string) {
return l10n.t({
message:
"Failed to refresh connection ${0} with uri {1}, invalid connection result.",
args: [connectionId, uri],
comment: ["{0} is the connection id", "{1} is the uri"],
});
}
export function msgRefreshTokenSuccess(
connectionId: string,
uri: string,
message: string,
) {
return l10n.t({
message:
"Successfully refreshed token for connection {0} with uri {1}, {2}",
args: [connectionId, uri, message],
comment: [
"{0} is the connection id",
"{1} is the uri",
"{2} is the message",
],
});
}
export function msgRefreshTokenNotNeeded(connectionId: string, uri: string) {
return l10n.t({
message:
"No need to refresh Microsoft Entra acccount token for connection {0} with uri {1}",
args: [connectionId, uri],
comment: ["{0} is the connection id", "{1} is the uri"],
});
}
export function msgConnectedServerInfo(
serverName: string,
documentName: string,
serverInfo: string,
) {
return l10n.t({
message:
'Connected to server "{0}" on document "{1}". Server information: {2}',
args: [serverName, documentName, serverInfo],
comment: [
"{0} is the server name",
"{1} is the document name",
"{2} is the server info",
],
});
}
export function msgConnectionFailed(serverName: string, errorMessage: string) {
return l10n.t({
message: 'Error connecting to server "{0}". Details: {1}',
args: [serverName, errorMessage],
comment: ["{0} is the server name", "{1} is the error message"],
});
}
export function msgChangingDatabase(
databaseName: string,
serverName: string,
documentName: string,
) {
return l10n.t({
message:
'Changing database context to "{0}" on server "{1}" on document "{2}".',
args: [databaseName, serverName, documentName],
comment: [
"{0} is the database name",
"{1} is the server name",
"{2} is the document name",
],
});
}
export function msgChangedDatabase(
databaseName: string,
serverName: string,
documentName: string,
) {
return l10n.t({
message:
'Changed database context to "{0}" on server "{1}" on document "{2}".',
args: [databaseName, serverName, documentName],
comment: [
"{0} is the database name",
"{1} is the server name",
"{2} is the document name",
],
});
}
export function msgDisconnected(documentName: string) {
return l10n.t({
message: 'Disconnected on document "{0}"',
args: [documentName],
comment: ["{0} is the document name"],
});
}
export let macOpenSslErrorMessage = l10n.t(
"OpenSSL version >=1.0.1 is required to connect.",
);
export let macOpenSslHelpButton = l10n.t("Help");
export let macSierraRequiredErrorMessage = l10n.t(
"macOS Sierra or newer is required to use this feature.",
);
export let gettingDefinitionMessage = l10n.t("Getting definition ...");
export let definitionRequestedStatus = l10n.t("DefinitionRequested");
export let definitionRequestCompletedStatus = l10n.t(
"DefinitionRequestCompleted",
);
export let updatingIntelliSenseStatus = l10n.t("updatingIntelliSense");
export let intelliSenseUpdatedStatus = l10n.t("intelliSenseUpdated");
export let testLocalizationConstant = l10n.t("test");
export let disconnectOptionLabel = l10n.t("Disconnect");
export let disconnectOptionDescription = l10n.t("Close the current connection");
export let disconnectConfirmationMsg = l10n.t(
"Are you sure you want to disconnect?",
);
export function elapsedBatchTime(batchTime: string) {
return l10n.t({
message: "Batch execution time: {0}",
args: [batchTime],
comment: ["{0} is the batch time"],
});
}
export let noActiveEditorMsg = l10n.t(
"A SQL editor must have focus before executing this command",
);
export let maximizeLabel = l10n.t("Maximize");
export let restoreLabel = l10n.t("Restore");
export let saveCSVLabel = l10n.t("Save as CSV");
export let saveJSONLabel = l10n.t("Save as JSON");
export let saveExcelLabel = l10n.t("Save as Excel");
export let fileTypeCSVLabel = l10n.t("CSV");
export let fileTypeJSONLabel = l10n.t("JSON");
export let fileTypeExcelLabel = l10n.t("Excel");
export let resultPaneLabel = l10n.t("Results");
export let selectAll = l10n.t("Select all");
export let copyLabel = l10n.t("Copy");
export let copyWithHeadersLabel = l10n.t("Copy with Headers");
export let executeQueryLabel = l10n.t("Executing query...");
export let QueryExecutedLabel = l10n.t("Query executed");
export let messagePaneLabel = l10n.t("Messages");
export let messagesTableTimeStampColumn = l10n.t("Timestamp");
export let messagesTableMessageColumn = l10n.t("Message");
export function lineSelectorFormatted(lineNumber: number) {
return l10n.t({
message: "Line {0}",
args: [lineNumber],
comment: ["{0} is the line number"],
});
}
export function elapsedTimeLabel(elapsedTime: string) {
return l10n.t({
message: "Total execution time: {0}",
args: [elapsedTime],
comment: ["{0} is the elapsed time"],
});
}
export let msgCannotSaveMultipleSelections = l10n.t(
"Save results command cannot be used with multiple selections.",
);
export let mssqlProviderName = l10n.t("MSSQL");
export let noneProviderName = l10n.t("None");
export let flavorChooseLanguage = l10n.t("Choose SQL Language");
export let flavorDescriptionMssql = l10n.t(
"Use T-SQL intellisense and syntax error checking on current document",
);
export let flavorDescriptionNone = l10n.t(
"Disable intellisense and syntax error checking on current document",
);
export let autoDisableNonTSqlLanguageServicePrompt = l10n.t(
"Non-SQL Server SQL file detected. Disable IntelliSense for such files?",
);
export let msgAddConnection = l10n.t("Add Connection");
export let msgConnect = l10n.t("Connect");
export let azureSignIn = l10n.t("Azure: Sign In");
export let azureSignInDescription = l10n.t(
"Sign in to your Azure subscription",
);
export let azureSignInWithDeviceCode = l10n.t(
"Azure: Sign In with Device Code",
);
export let azureSignInWithDeviceCodeDescription = l10n.t(
"Sign in to your Azure subscription with a device code. Use this in setups where the Sign In command does not work",
);
export let azureSignInToAzureCloud = l10n.t("Azure: Sign In to Azure Cloud");
export let azureSignInToAzureCloudDescription = l10n.t(
"Sign in to your Azure subscription in one of the sovereign clouds.",
);
export function taskStatusWithName(taskName: string, status: string) {
return l10n.t({
message: "{0}: {1}",
args: [taskName, status],
comment: ["{0} is the task name", "{1} is the status"],
});
}
export function taskStatusWithMessage(status: string, message: string) {
return l10n.t({
message: "{0}. {1}",
args: [status, message],
comment: ["{0} is the status", "{1} is the message"],
});
}
export function taskStatusWithNameAndMessage(
taskName: string,
status: string,
message: string,
) {
return l10n.t({
message: "{0}: {1}. {2}",
args: [taskName, status, message],
comment: [
"{0} is the task name",
"{1} is the status",
"{2} is the message",
],
});
}
export let failed = l10n.t("Failed");
export let succeeded = l10n.t("Succeeded");
export let succeededWithWarning = l10n.t("Succeeded with warning");
export let canceled = l10n.t("Canceled");
export let inProgress = l10n.t("In progress");
export let canceling = l10n.t("Canceling");
export let notStarted = l10n.t("Not started");
export let nodeErrorMessage = l10n.t("Parent node was not TreeNodeInfo.");
export function deleteCredentialError(id: string, error: string) {
return l10n.t({
message: "Failed to delete credential with id: {0}. {1}",
args: [id, error],
comment: ["{0} is the id", "{1} is the error"],
});
}
export let msgClearedRecentConnectionsWithErrors = l10n.t(
"The recent connections list has been cleared but there were errors while deleting some associated credentials. View the errors in the MSSQL output channel.",
);
export let connectProgressNoticationTitle = l10n.t(
"Testing connection profile...",
);
export let msgMultipleSelectionModeNotSupported = l10n.t(
"Running query is not supported when the editor is in multiple selection mode.",
);
export let newColumnWidthPrompt = l10n.t("Enter new column width");
export let columnWidthInvalidNumberError = l10n.t("Invalid column width");
export let columnWidthMustBePositiveError = l10n.t(
"Width cannot be 0 or negative",
);
export let objectExplorerNodeRefreshError = l10n.t(
"An error occurred refreshing nodes. See the MSSQL output channel for more details.",
);
export let showOutputChannelActionButtonText = l10n.t("Show MSSQL output");
export let reloadPrompt = l10n.t(
"Authentication Library has changed, please reload Visual Studio Code.",
);
export let reloadPromptGeneric = l10n.t(
"Visual Studio Code must be relaunched for this setting to come into effect. Please reload Visual Studio Code.",
);
export let reloadChoice = l10n.t("Reload Visual Studio Code");
export let switchToMsal = l10n.t("Switch to MSAL");
export let dismiss = l10n.t("Dismiss");
export let querySuccess = l10n.t("Query succeeded");
export let queryFailed = l10n.t("Query failed");
export let parameters = l10n.t("Parameters");
export let loading = l10n.t("Loading");
export let executionPlan = l10n.t("Execution Plan");
export let executionPlanFileFilter = l10n.t("SQL Plan Files");
export let scriptCopiedToClipboard = l10n.t("Script copied to clipboard");
export let copied = l10n.t("Copied");
export let openQueryResultsInTabByDefaultPrompt = l10n.t(
"Do you want to always display query results in a new tab instead of the query pane?",
);
export let alwaysShowInNewTab = l10n.t("Always show in new tab");
export let keepInQueryPane = l10n.t("Keep in query pane");
export function enableRichExperiencesPrompt(learnMoreUrl: string) {
return l10n.t({
message:
"The MSSQL for VS Code extension is introducing new modern data development features! Would you like to enable them? [Learn more]({0})",
args: [learnMoreUrl],
comment: ["{0} is a url to learn more about the new features"],
});
}
export let enableRichExperiences = l10n.t("Enable Experiences & Reload");
export class ObjectExplorer {
public static ErrorLoadingRefreshToTryAgain = l10n.t(
"Error loading; refresh to try again",
);
}
export class ConnectionDialog {
public static connectionDialog = l10n.t("Connection Dialog (Preview)");
public static azureAccount = l10n.t("Azure Account");
public static azureAccountIsRequired = l10n.t("Azure Account is required");
public static selectAnAccount = l10n.t("Select an account");
public static savePassword = l10n.t("Save Password");
public static tenantId = l10n.t("Tenant ID");
public static selectATenant = l10n.t("Select a tenant");
public static tenantIdIsRequired = l10n.t("Tenant ID is required");
public static profileName = l10n.t("Profile Name");
public static serverIsRequired = l10n.t("Server is required");
public static usernameIsRequired = l10n.t("User name is required");
public static connectionString = l10n.t("Connection String");
public static connectionStringIsRequired = l10n.t(
"Connection string is required",
);
public static signIn = l10n.t("Sign in");
public static additionalParameters = l10n.t("Additional parameters");
public static connect = l10n.t("Connect");
public static errorLoadingAzureDatabases(
subscriptionName: string,
subscriptionId: string,
) {
return l10n.t({
message:
"Error loading Azure databases for subscription {0} ({1}). Confirm that you have permission.",
args: [subscriptionName, subscriptionId],
comment: [
"{0} is the subscription name",
"{1} is the subscription id",
],
});
}
public static deleteTheSavedConnection = (connectionName: string) => {
return l10n.t({
message: "delete the saved connection: {0}?",
args: [connectionName],
comment: ["{0} is the connection name"],
});
};
public static errorLoadingAzureAccountInfoForTenantId = (
tenantId: string,
) => {
return l10n.t({
message:
"Error loading Azure account information for tenant ID '{0}'",
args: [tenantId],
comment: ["{0} is the tenant ID"],
});
};
public static errorCreatingFirewallRule = (
ruleInfo: string,
error: string,
) => {
return l10n.t({
message:
"Error creating firewall rule {0}. Check your Azure account settings and try again. Error: {1}",
args: [ruleInfo, error],
comment: [
"{0} is the rule info in format 'name (startIp - endIp)'",
"{1} is the error message",
],
});
};
}
export class UserSurvey {
public static overallHowSatisfiedAreYouWithMSSQLExtension = l10n.t(
"Overall, how satisfied are you with the MSSQL extension?",
);
public static howlikelyAreYouToRecommendMSSQLExtension = l10n.t(
"How likely it is that you would recommend the MSSQL extension to a friend or colleague?",
);
public static whatCanWeDoToImprove = l10n.t("What can we do to improve?");
public static takeSurvey = l10n.t("Take Survey");
public static doYouMindTakingAQuickFeedbackSurvey = l10n.t(
"Do you mind taking a quick feedback survey about the MSSQL Extension for VS Code?",
);
public static mssqlFeedback = l10n.t("MSSQL Feedback");
public static privacyDisclaimer = l10n.t(
"Microsoft reviews your feedback to improve our products, so don't share any personal data or confidential/proprietary content.",
);
public static overallHowStatisfiedAreYouWithFeature = (
featureName: string,
) =>
l10n.t({
message: "Overall, how satisfied are you with {0}?",
args: [featureName],
comment: ["{0} is the feature name"],
});
public static howLikelyAreYouToRecommendFeature = (featureName: string) =>
l10n.t({
message:
"How likely it is that you would recommend {0} to a friend or colleague?",
args: [featureName],
comment: ["{0} is the feature name"],
});
public static fileAnIssuePrompt = l10n.t(
"Encountering a problem? Share the details with us by opening a GitHub issue so we can improve!",
);
public static submitIssue = l10n.t("Submit an issue");
}
export class Webview {
public static webviewRestorePrompt = (webviewName: string) =>
l10n.t({
message: "{0} has been closed. Would you like to restore it?",
args: [webviewName],
comment: ["{0} is the webview name"],
});
public static Restore = l10n.t("Restore");
}
export class TableDesigner {
public static General = l10n.t("General");
public static Columns = l10n.t("Columns");
public static AdvancedOptions = l10n.t("Advanced Options");
}
export class SchemaCompare {
public static Title = l10n.t("Schema Compare");
}