Skip to content

Action detail: choices UX — secondary active CTA, email-first order, replace-all civility key

Follow-up to !72 (merged) (merged) — Catalyst feedback round on the action detail page, 3 scoped changes:

1. Active platform CTA = secondary styling The active channel button in the choices line renders with the secondary class instead of primary. Also removes the .secondary[active] solid-fill override from _buttons.scss so an active secondary button keeps its normal outline styling (it previously read as primary — defeating the purpose). Chevron unchanged.

2. Email first in the choices list When the action carries email targetting (email isn't mandatory), the email button always displays first. Remaining platforms keep their admin order (_orderedPlateforms getter, stable reorder).

3. [Madame/Monsieur] replaced at ALL occurrences The email template personalization now uses a global regex instead of replacing only the first match — greeting AND closing salutation both get the representatives' names (action 1385's LDH text has the key twice).

Test data: action 1385 (LDH PPL présomption de légitime défense) — email + twitter + instagram channels, email text with 2 [Madame/Monsieur] occurrences.

Verified before push: esbuild clean on all 3 files, sass compile of _buttons.scss, vite-served artifacts carry all changes, .secondary[active] fill absent from compiled CSS.

Merge request reports