FCI theming refresh, contact identity fields, Amplify secrets fix
- Remap globals.css tokens to FCI brand palette (Eggplant #801d7f, Spring Pea #96bc33, Seed Grant #679038, Squash #c9ad2d, FCI gray #4b5657). Existing leaf-* / clay-* class names preserved. - Switch body font to Open Sans (FCI's free fallback for Museo Sans). Headings keep Fraunces. - Add contact identity (first name, last name, email) as readonly fields at the top of Stage 0. /api/data fetches via APIv4 Contact.get with email_primary.email join; values flow through FormDataPayload.contact and into the form's evalState so the readonly renderer displays them. Draft restore re-applies them so a stale local draft can't override. - amplify.yml: fetch Amplify Secrets from SSM Parameter Store when they don't arrive as build-shell env vars (the common failure mode behind "Refusing to run in production without CIVI_*"). Adds a length-only diagnostic echo and a hard-fail guard so a missing required var stops the build with a clear message instead of bundling empty strings and crashing the SSR Lambda at runtime.
This commit is contained in:
@@ -168,6 +168,17 @@ export interface FormConfig {
|
||||
sections: StageSectionConfig[];
|
||||
}
|
||||
|
||||
/**
|
||||
* Identifying details for the contact submitting the form, derived from the
|
||||
* cid resolved by /api/data. Surfaced as readonly fields in Stage 0 so the
|
||||
* person filling out the check-in can confirm who's logged as the submitter.
|
||||
*/
|
||||
export interface ContactIdentity {
|
||||
firstName: string;
|
||||
lastName: string;
|
||||
email: string;
|
||||
}
|
||||
|
||||
/**
|
||||
* The shape returned by /api/data. Used by the form on initial load.
|
||||
*/
|
||||
@@ -176,6 +187,8 @@ export interface FormDataPayload {
|
||||
orgName: string;
|
||||
/** Current Framework Stage (text value). */
|
||||
currentStage: string;
|
||||
/** Identifying details of the contact behind the cid (readonly display). */
|
||||
contact?: ContactIdentity;
|
||||
/**
|
||||
* Per-field-most-recent prefill values, keyed by the FieldConfig.name.
|
||||
* Fields with no prior value are simply absent from this map.
|
||||
|
||||
Reference in New Issue
Block a user