diff --git a/frontend/src/components/treatment/voiceApply.ts b/frontend/src/components/treatment/voiceApply.ts index 4f31cdc..c2af8fd 100644 --- a/frontend/src/components/treatment/voiceApply.ts +++ b/frontend/src/components/treatment/voiceApply.ts @@ -1,5 +1,5 @@ import type { ProsthesisCatalogEntry } from '@/types/treatment-catalog'; -import type { LabCaseDraft, TreatmentDetailDraft } from '@/types/treatment'; +import type { FdiToothId, LabCaseDraft, TreatmentDetailDraft } from '@/types/treatment'; import type { VoiceApplySelection, VoiceExtractionResult } from '@/types/voice'; import { newDetail, newLabCaseDraft } from './treatmentDetailRules'; import { landVoiceProsthesisJobs, prosthesisTargetLines } from './voiceReviewRows'; @@ -77,7 +77,7 @@ export function buildVoiceApplyPlan( ); detail.teeth = lines .filter((line) => !line.isJaw && line.applied.length > 0) - .map((line) => line.target); + .map((line) => line.target as FdiToothId); detail.toothSelectionGroups = landed.groups; } diff --git a/frontend/src/components/treatment/voiceReviewRows.ts b/frontend/src/components/treatment/voiceReviewRows.ts index 1ae876b..b40ae56 100644 --- a/frontend/src/components/treatment/voiceReviewRows.ts +++ b/frontend/src/components/treatment/voiceReviewRows.ts @@ -265,7 +265,7 @@ export function landVoiceProsthesisJobs( .map((line) => line.target as FdiToothId); const byCode = catalogByCode(catalog); const jobsByTooth = new Map(applied.map((line) => [line.target, line.applied])); - let groups = groupsFromFlatTeeth(fdiTeeth, existingGroups ?? []); + let groups = groupsFromFlatTeeth(fdiTeeth, [...(existingGroups ?? [])]); for (const line of applied) { if (line.isJaw || !line.applied.includes(PONTIC_CODE)) continue; groups = connectPonticTooth(groups, line.target as FdiToothId, jobsByTooth, byCode); diff --git a/frontend/src/components/ui/billing/BillingSheetsPanel.tsx b/frontend/src/components/ui/billing/BillingSheetsPanel.tsx index 7161eb5..352fa74 100644 --- a/frontend/src/components/ui/billing/BillingSheetsPanel.tsx +++ b/frontend/src/components/ui/billing/BillingSheetsPanel.tsx @@ -193,7 +193,7 @@ export function BillingSheetsPanel({ {editorSheet !== undefined ? (