From 7b5f992a2a6d5b27a98508d2ba3ddf5b5bee0215 Mon Sep 17 00:00:00 2001 From: peptiderepo Date: Sun, 26 Apr 2026 02:12:35 +0000 Subject: [PATCH] =?UTF-8?q?fix:=20CMO=20walkthrough=20P1=20fixes=20?= =?UTF-8?q?=E2=80=94=20verdict=5Ftext,=20per-row=20glyphs,=20conditional?= =?UTF-8?q?=20disclosure,=20dark=20mode=20(v2.0.0-alpha.3)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit P1.1: verdict_text meta field + card.php wiring - Register verdict_text (textarea, show_in_rest) on peptide CPT - card.php reads verdict_text meta; falls back to placeholder if empty - Hardcoded generic placeholder no longer the default for published posts - All 3 monographs populated with CMO-authored verdict text P1.2: per-row glyph meta fields - Register signal_row_1/2/3_glyph (enum: ✓|!|?|⊘|⚠, show_in_rest) - card.php reads per-row glyph from meta instead of hardcoding by position - Missing glyph renders nothing (not a wrong glyph) - Semaglutide: ✓✓! | BPC-157: ✓!? | Melanotan-II: !!⚠ P1.3: conditional inline disclosure - Register has_partner_link (boolean, default false, show_in_rest) - single-peptide.php only renders inline disclosure when has_partner_link=true - All 3 loaded monographs set to has_partner_link=false - Footer disclosure unaffected (always renders) N.1: dark mode toggle hidden - header.php: toggle button hidden (display:none + aria-hidden) - Dark-mode verdict colors not validated for v1; re-enable in v1.1 Meta box updated with textarea, glyph dropdowns, and partner-link checkbox. --- CHANGELOG.md | 29 +++++ functions.php | 2 +- header.php | 3 +- inc/verdict-meta.php | 198 +++++++++++++++++++++++++------- single-peptide.php | 12 +- style.css | 2 +- template-parts/verdict/card.php | 40 ++++--- 7 files changed, 223 insertions(+), 63 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 7e6a1f3..877ca7e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,34 @@ # Peptide Starter Theme - Changelog +## [2.0.0-alpha.3] - 2026-04-26 — CMO walkthrough P1 fixes + +### Fixed +- `template-parts/verdict/card.php`: Verdict text was a hardcoded generic placeholder. + Now reads `verdict_text` post meta (CMO-authored 3-5 sentence opinionated verdict). + Falls back to placeholder only if the field is empty (defensive, not normative). +- `template-parts/verdict/card.php`: Evidence-row glyphs were hardcoded by row position + (row 1=✓, row 2=!, row 3=?), producing wrong glyph/content pairings on Established and + Cautionary verdicts. Now reads `signal_row_N_glyph` meta per row; renders no glyph if + the field is empty rather than defaulting to a wrong one. +- `single-peptide.php`: Inline affiliate disclosure rendered on monographs with no partner + link, directly contradicting the content ("We have no fulfillment partner at this time"). + Now conditional on `has_partner_link` boolean meta (default false). Disclosure suppressed + unless a partner link is explicitly flagged by the CMO. +- `header.php`: Dark-mode toggle was live in the header. Verdict-color accessibility has + only been validated for light mode (per brand spec §1 — "no dark mode for v1"). Toggle + hidden (display:none + aria-hidden) until dark palette is audited in v1.1. + +### Added +- `inc/verdict-meta.php`: New meta fields on `peptide` CPT: + - `verdict_text` (textarea, show_in_rest: true) — opinionated verdict paragraph + - `signal_row_1/2/3_glyph` (enum ✓|!|?|⊘|⚠, show_in_rest: true) — per-row glyph + - `has_partner_link` (boolean, default false, show_in_rest: true) — disclosure gate +- Meta box updated with textarea for verdict_text, glyph dropdowns per row, partner-link + checkbox. +- All 3 loaded monographs updated with correct `verdict_text`, `signal_row_N_glyph`, and + `has_partner_link=false`. + + ## [2.0.0-alpha.2] - 2026-04-26 — Wire verdict card and disclosure into single-peptide.php ### Fixed diff --git a/functions.php b/functions.php index 08df239..fc7f54c 100644 --- a/functions.php +++ b/functions.php @@ -26,7 +26,7 @@ if ( ! defined( 'ABSPATH' ) ) { } // Theme constants. -define( 'PEPTIDE_STARTER_VERSION', '2.0.0-alpha.2' ); +define( 'PEPTIDE_STARTER_VERSION', '2.0.0-alpha.3' ); define( 'PEPTIDE_STARTER_DIR', get_template_directory() ); define( 'PEPTIDE_STARTER_URI', get_template_directory_uri() ); diff --git a/header.php b/header.php index 68599ea..47f6ab1 100644 --- a/header.php +++ b/header.php @@ -118,7 +118,8 @@ -