feat(rectification): 删掉年月录入卡,年月阶段打字回答且不被追问覆盖
Independent Staging Quality Gate / validate (push) Successful in 10m1s
Independent Staging Quality Gate / publish (push) Successful in 36m54s

This commit is contained in:
jesse-ux
2026-09-16 23:22:32 +08:00
parent abcfdac523
commit 6aabbe386f
49 changed files with 1035 additions and 431 deletions
@@ -113,13 +113,6 @@ import {
import { ModelSelector } from "./model-selector";
import { RectificationBoard, RectificationBoardPeek } from "./rectification-board";
import { RectificationChoiceCard } from "./rectification-choice-card";
import {
EventDateEntryCard,
eventDateYearRange,
formatEventDateEntryMessage,
} from "./event-date-entry-card";
import { parseYearEntryQuestionId } from "@/lib/rectification-agentic/v9/collection-question-pool";
import { birthYearFromDate } from "@/lib/rectification-agentic/v9/adult-floor";
import {
applyLiveCandidateOffer,
copyTextForMessage,
@@ -1424,8 +1417,6 @@ export function RectificationAgenticChat(props: RectificationAgenticChatProps) {
answeredProbeCount: candidateResult?.answeredProbeCount ?? null,
datedEventCount: candidateResult?.rangeDelivery?.event_count ?? null,
});
const yearEntry = parseYearEntryQuestionId(currentQuestion?.question_id);
const yearRange = eventDateYearRange(birthYearFromDate(birthDate));
const persistedOfferKey = [...messages].reverse().find((message) => message.candidateOffer)?.renderKey;
const liveSelectionCardKey = persistedOfferKey
?? (canOfferCards && !candidateResult?.selectedTime ? latestSettledAssistant?.renderKey : undefined);
@@ -1739,7 +1730,7 @@ export function RectificationAgenticChat(props: RectificationAgenticChatProps) {
})}
{questionGap === "persisted_question" && currentQuestion?.prompt && (
<div className="rectification-message-wrap rectification-message-entry" data-testid="persisted-question">
<div className="rectification-message-question">
<div className="rectification-message-question is-standalone">
{persistedQuestionSurface({
questionKind: currentQuestion.kind,
hasChoiceCard: Boolean(choiceCard),
@@ -1758,21 +1749,6 @@ export function RectificationAgenticChat(props: RectificationAgenticChatProps) {
onStop={submitStop}
/>
</>
) : yearEntry ? (
<>
<p className="rectification-message-question__prompt">{currentQuestion.prompt}</p>
<EventDateEntryCard
defaultDomain={yearEntry.domain}
defaultYear={yearEntry.year ?? undefined}
defaultMonth={yearEntry.month ?? undefined}
minYear={yearRange.minYear}
maxYear={yearRange.maxYear}
disabled={busy || readonly}
onSubmit={(value) => {
void send("message", formatEventDateEntryMessage(value));
}}
/>
</>
) : (
<p className="rectification-message-question__prompt">{currentQuestion.prompt}</p>
)}