Release govoplan-campaign v0.1.28: stabilize saving, review and delivery recovery
Module Package Release / publish-packages (push) Successful in 12s

This commit is contained in:
2026-09-08 01:32:26 +02:00
parent 1b32427813
commit c51fc180fb
111 changed files with 6905 additions and 980 deletions
@@ -47,3 +47,27 @@ export function calculateBuildReviewProgress(input: BuildReviewProgressInput): B
remaining: individualRemaining + groupRemaining
};
}
/** Summary match counts describe inputs; they are not fresh review gates. */
export function attachmentDeliveryPreflight(input: {
migrationRequired: boolean;
hasBuild: boolean;
reviewLoaded: boolean;
blocking: number;
remaining: number;
inspectionComplete: boolean;
missing: number;
ambiguous: number;
}): { state: "ready" | "warning" | "blocked" | "info"; detail: string } {
if (input.migrationRequired) return { state: "blocked", detail: "i18n:govoplan-campaign.attachment_checks_await_mail_migration" };
if (!input.hasBuild) return { state: "info", detail: "i18n:govoplan-campaign.attachment_preflight_build_first" };
if (!input.reviewLoaded) return { state: "info", detail: "i18n:govoplan-campaign.attachment_preflight_loading" };
if (input.blocking > 0) return { state: "blocked", detail: "i18n:govoplan-campaign.attachment_preflight_blocked" };
if (input.inspectionComplete || input.remaining === 0) {
return { state: "ready", detail: "i18n:govoplan-campaign.attachment_preflight_satisfied" };
}
if (input.missing + input.ambiguous > 0) {
return { state: "warning", detail: "i18n:govoplan-campaign.attachment_preflight_review" };
}
return { state: "info", detail: "i18n:govoplan-campaign.attachment_preflight_pending" };
}