Addressing some PR comments

This commit is contained in:
Chuck Skelton
2026-05-15 12:00:32 -07:00
parent 45acb71207
commit de4dbb9df1
2 changed files with 12 additions and 10 deletions
@@ -247,10 +247,10 @@ export const ChangePartitionKeyPane: React.FC<ChangePartitionKeyPaneProps> = ({
const partitionKeyString = partitionKey.trim(); const partitionKeyString = partitionKey.trim();
const partitionKeyData: DataModels.PartitionKey = partitionKeyString const partitionKeyData: DataModels.PartitionKey = partitionKeyString
? { ? {
paths: [partitionKeyString, ...(subPartitionKeys.length > 0 ? subPartitionKeys : [])], paths: [partitionKeyString, ...(subPartitionKeys.length > 0 ? subPartitionKeys : [])],
kind: subPartitionKeys.length > 0 ? "MultiHash" : "Hash", kind: subPartitionKeys.length > 0 ? "MultiHash" : "Hash",
version: 2, version: 2,
} }
: undefined; : undefined;
const createCollectionParams: DataModels.CreateCollectionParams = { const createCollectionParams: DataModels.CreateCollectionParams = {
@@ -301,7 +301,7 @@ export const ChangePartitionKeyPane: React.FC<ChangePartitionKeyPaneProps> = ({
{/* Migration Type */} {/* Migration Type */}
<Stack data-test="migration-type-section"> <Stack data-test="migration-type-section">
<Text className="panelTextBold" variant="small" style={{ marginBottom: 4 }}> <Text className="panelTextBold" variant="small" style={{ marginBottom: 4 }}>
Migration type {t(Keys.containerCopy.migrationType.title)}
</Text> </Text>
<Stack className="panelGroupSpacing" horizontal verticalAlign="center"> <Stack className="panelGroupSpacing" horizontal verticalAlign="center">
<div role="radiogroup"> <div role="radiogroup">
@@ -317,7 +317,7 @@ export const ChangePartitionKeyPane: React.FC<ChangePartitionKeyPaneProps> = ({
tabIndex={0} tabIndex={0}
onChange={() => setOnlineMode(false)} onChange={() => setOnlineMode(false)}
/> />
<span className="panelRadioBtnLabel">Offline mode</span> <span className="panelRadioBtnLabel">{t(Keys.containerCopy.migrationType.offline.title)}</span>
<input <input
className="panelRadioBtn" className="panelRadioBtn"
@@ -330,7 +330,7 @@ export const ChangePartitionKeyPane: React.FC<ChangePartitionKeyPaneProps> = ({
tabIndex={0} tabIndex={0}
onChange={() => setOnlineMode(true)} onChange={() => setOnlineMode(true)}
/> />
<span className="panelRadioBtnLabel">Online mode</span> <span className="panelRadioBtnLabel">{t(Keys.containerCopy.migrationType.online.title)}</span>
</div> </div>
</Stack> </Stack>
{migrationTypeContent && ( {migrationTypeContent && (
@@ -348,7 +348,7 @@ export const ChangePartitionKeyPane: React.FC<ChangePartitionKeyPaneProps> = ({
<Stack horizontal> <Stack horizontal>
<span className="mandatoryStar">*&nbsp;</span> <span className="mandatoryStar">*&nbsp;</span>
<Text className="panelTextBold" variant="small"> <Text className="panelTextBold" variant="small">
Database id {t(Keys.panes.addDatabase.databaseIdLabel)}
</Text> </Text>
<TooltipHost <TooltipHost
directionalHint={DirectionalHint.bottomLeftEdge} directionalHint={DirectionalHint.bottomLeftEdge}
@@ -691,7 +691,7 @@ export const ChangePartitionKeyPane: React.FC<ChangePartitionKeyPaneProps> = ({
{!onlinePrerequisitesMet && ( {!onlinePrerequisitesMet && (
<MessageBar messageBarType={MessageBarType.warning} data-test="online-prerequisites-warning"> <MessageBar messageBarType={MessageBarType.warning} data-test="online-prerequisites-warning">
Online migration prerequisites must be enabled before proceeding. {t(Keys.containerCopy.onlineCopyEnabled.onlineMigrationPrerequisitesMessage)}
</MessageBar> </MessageBar>
)} )}
</Stack> </Stack>
+3 -1
View File
@@ -1027,6 +1027,7 @@
"accountDropdownPlaceholder": "Select an account" "accountDropdownPlaceholder": "Select an account"
}, },
"migrationType": { "migrationType": {
"title": "Migration type",
"offline": { "offline": {
"title": "Offline mode", "title": "Offline mode",
"description": "Offline container copy jobs let you copy data from a source container to a destination Cosmos DB container for supported APIs. To ensure data integrity between the source and destination, we recommend stopping updates on the source container before creating the copy job. Learn more about [offline copy jobs](https://learn.microsoft.com/azure/cosmos-db/how-to-container-copy?tabs=offline-copy&pivots=api-nosql)." "description": "Offline container copy jobs let you copy data from a source container to a destination Cosmos DB container for supported APIs. To ensure data integrity between the source and destination, we recommend stopping updates on the source container before creating the copy job. Learn more about [offline copy jobs](https://learn.microsoft.com/azure/cosmos-db/how-to-container-copy?tabs=offline-copy&pivots=api-nosql)."
@@ -1120,7 +1121,8 @@
"buttonText": "Enable Online Copy", "buttonText": "Enable Online Copy",
"validateAllVersionsAndDeletesChangeFeedSpinnerLabel": "Validating All versions and deletes change feed mode (preview)...", "validateAllVersionsAndDeletesChangeFeedSpinnerLabel": "Validating All versions and deletes change feed mode (preview)...",
"enablingAllVersionsAndDeletesChangeFeedSpinnerLabel": "Enabling All versions and deletes change feed mode (preview)...", "enablingAllVersionsAndDeletesChangeFeedSpinnerLabel": "Enabling All versions and deletes change feed mode (preview)...",
"enablingOnlineCopySpinnerLabel": "Enabling online copy on your \"{{accountName}}\" account ..." "enablingOnlineCopySpinnerLabel": "Enabling online copy on your \"{{accountName}}\" account ...",
"onlineMigrationPrerequisitesMessage": "Online migration prerequisites must be enabled before proceeding."
}, },
"monitorJobs": { "monitorJobs": {
"columns": { "columns": {