fix(contact): use wp_kses_post for block wrapper and AA color for required marker

- contact-info.php was calling esc_attr() on the output of
  blockWrapperAttributes(), which returns a full attribute string.
  esc_attr() turned the wrapping quotes into " so the class
  attribute rendered literally as class="contact-info ...".
  Switched to wp_kses_post() to match the pattern used by every
  other block template in the project.
- contact-info.css: .gfield_required used --color-cwc-orange-01
  (#e15747, 3.71:1 on white) which fails WCAG 2 AA. Swapped to the
  project's --color-secondary-accessible token (#c43c2b) so the
  required marker is brand-aligned and meets the 4.5:1 minimum.
- Regenerated static/dist/theme.css to match.
This commit is contained in:
Keith Solomon
2026-07-04 14:14:50 -05:00
parent 0f4cd48c60
commit f77a78b856
3 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -6257,7 +6257,7 @@ a.contact-info__value:hover {
}
.contact-info__form .gfield_required {
color: var(--color-cwc-orange-01);
color: var(--color-secondary-accessible);
margin-left: .25rem;
font-weight: 700;
}
+1 -1
View File
@@ -131,7 +131,7 @@ a.contact-info__value:hover {
}
.contact-info__form .gfield_required {
color: var(--color-cwc-orange-01);
color: var(--color-secondary-accessible);
font-weight: 700;
margin-left: 0.25rem;
}
+1 -1
View File
@@ -20,7 +20,7 @@ $classes = 'contact-info';
$wrapper = blockWrapperAttributes( $classes, $is_preview );
?>
<section <?php echo esc_attr( $wrapper ); ?>>
<section <?php echo wp_kses_post( $wrapper ); ?>>
<div class="contact-info__grid">
<div class="contact-info__details">
<h1 class="contact-info__heading">Contact</h1>