mirror of
https://github.com/Azure/cosmos-explorer.git
synced 2026-05-14 09:17:29 +01:00
Improve delete confirmation dialogs with copyable resource ID and warning (#2464)
* feat: add copyable ID to delete confirmation dialogs When deleting databases or containers, the confirmation dialog now displays the resource ID in a read-only text field with a copy button, allowing users to copy-paste the ID into the confirmation input instead of typing it manually. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Fixed formatting. * revert non-en locale changes; add localization instruction Revert changes to non-English locale files — translations are managed by a separate localization process. Add a note to copilot instructions clarifying that only en/Resources.json should be modified. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * fix: capitalize 'Id' in copyable resource ID labels Changed 'id:' to 'Id:' in the copyable ID labels for delete confirmation dialogs (both database and collection). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * fix: capitalize collection name in copyable ID label Use getCollectionName() directly (returns 'Container', 'Collection', etc.) instead of the lowercased collectionName variable for the copyable ID label. The database panel already used getDatabaseName() which returns capitalized. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * feat: add warning message to delete container confirmation dialog Added the same warning banner that exists in the delete database dialog to the delete container dialog, informing users that the action cannot be undone and will permanently delete the resource and its children. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
@@ -109,6 +109,8 @@ const title = t("splashScreen.title.default");
|
||||
```
|
||||
The `ResourceKey` type (derived from `Resources.json`) ensures compile-time safety — invalid keys will cause a type error. When adding new strings, add the English entry to `Resources.json` first, then reference it with `t()`.
|
||||
|
||||
**Important:** Only modify the English resource file (`src/Localization/en/Resources.json`). Do not modify non-English locale files (`src/Localization/<locale>/Resources.json`) — translations are managed by a separate localization process.
|
||||
|
||||
### Imports
|
||||
|
||||
TypeScript `baseUrl` is set to `src/`, so imports from `src/` are written without a leading `./src/` prefix:
|
||||
|
||||
Reference in New Issue
Block a user