docs: update Status.md with tabbed interface implementation

- Document Trainers/Venues/Events tab navigation
- Document venue cards, event cards, info modal
- Document CDN cache issue and version bump fix
- Add CAPTCHA implementation as planned next session task

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
ben 2026-02-01 19:56:28 -04:00
parent ea3031528e
commit d2a43bfd9b

127
Status.md
View file

@ -1,19 +1,108 @@
# HVAC Community Events - Project Status
**Last Updated:** February 1, 2026
**Current Session:** measureQuick Approved Training Labs Implementation
**Version:** 2.3.0 (Deployed to Staging)
**Current Session:** Tabbed Interface for Find Training Page
**Version:** 2.2.6 (Deployed to Staging)
---
## 🎯 CURRENT SESSION - MEASUREQUICK APPROVED TRAINING LABS (Feb 1, 2026)
## 🎯 NEXT SESSION - CAPTCHA IMPLEMENTATION
### Status: 🔄 **IN PROGRESS - Deployed to Staging, Venues Not Displaying**
### Status: 📋 **PLANNED**
**Objective:** Transform /find-training to showcase only measureQuick Approved Training Labs with venue categories, equipment/amenities tags, and contact forms.
**Objective:** Add CAPTCHA to all user-facing forms to prevent spam and bot submissions.
**Forms to Update:**
- Training login form
- Trainer registration form
- Contact forms (trainer, venue)
- Any other public-facing forms
---
## 🎯 CURRENT SESSION - TABBED INTERFACE FOR FIND TRAINING (Feb 1, 2026)
### Status: ✅ **COMPLETE - Deployed to Staging, Verified Working**
**Objective:** Refactor the Find Training page sidebar from a single trainer list to a tabbed interface with Trainers, Venues, and Events tabs.
### Changes Made
1. ✅ **Tab Navigation System** (`templates/page-find-training.php`)
- Replaced "42 trainers" header with three tabs: Trainers | Venues | Events
- Each tab displays dynamic count in parentheses
- ARIA accessibility attributes (role="tablist", role="tab", aria-selected)
- Keyboard navigation (arrow keys, Home, End)
2. ✅ **Visibility Toggles Relocated**
- Moved from map overlay to sidebar header
- Colored dots (teal/orange/purple) match marker colors
- Only control map marker visibility, not tab content
3. ✅ **Venue Cards** (`assets/js/find-training-map.js`)
- Name with building icon
- City, State location
- "X upcoming events" count
4. ✅ **Event Cards** (`assets/js/find-training-map.js`)
- Date badge showing month/day
- Event title
- Venue name
- Cost display
- "Past" badge for past events
5. ✅ **Info Modal** (`templates/page-find-training.php`)
- "What is Upskill HVAC?" section
- "How to Use" instructions
- Map Legend (trainer/venue/event markers)
6. ✅ **Context-Aware Search** (`assets/js/find-training-filters.js`)
- Placeholder changes based on active tab
- Client-side filtering for instant results (150ms debounce)
- Falls back to server-side when filters active
7. ✅ **CSS Styling** (`assets/css/find-training-map.css`)
- Tab navigation container and button styles
- Venue card and event card layouts
- Info button and modal styling
- Responsive adjustments for tablet/mobile
### Files Modified
| File | Change |
|------|--------|
| `templates/page-find-training.php` | Tab navigation, panels, info modal |
| `assets/js/find-training-map.js` | Tab switching, card creators, grid renderers |
| `assets/js/find-training-filters.js` | Context-aware search, client-side filtering |
| `assets/css/find-training-map.css` | ~300 lines new CSS for tabs, cards, modal |
| `includes/class-hvac-plugin.php` | Version bump 2.2.5 → 2.2.6 (CDN cache bust) |
### Issue Resolved: CDN Cache
**Problem:** After deployment, browser loaded old JavaScript without new `initTabs` method.
**Root Cause:** CDN cached old assets. Deploy script clears WP/OPcache but not CDN edge cache.
**Fix:** Bumped `HVAC_VERSION` from 2.2.5 to 2.2.6, changing script URL query string to force cache refresh.
### Verified on Staging
- ✅ 42 trainers tab count
- ✅ 9 venues tab count
- ✅ 8 events tab count
- ✅ Tab switching works with proper ARIA attributes
- ✅ Venue cards display correctly
- ✅ Event cards with date badges display correctly
- ✅ Info modal opens and displays content
- ✅ Visibility toggles control map markers
---
## 📋 PREVIOUS SESSION - MEASUREQUICK APPROVED TRAINING LABS (Feb 1, 2026)
### Status: ✅ **COMPLETE - Deployed to Staging, Venues Displaying Correctly**
**Objective:** Transform /find-training to showcase only measureQuick Approved Training Labs with venue categories, equipment/amenities tags, and contact forms.
1. ✅ **Venue Taxonomies Created** (`includes/class-hvac-venue-categories.php` NEW)
- `venue_type` - For lab classification (e.g., "measureQuick Approved Training Lab")
- `venue_equipment` - Furnace, Heat Pump, AC, Mini-Split, Boiler, etc.
@ -53,6 +142,8 @@
|------|-------------|
| `includes/class-hvac-venue-categories.php` | Venue taxonomy registration (singleton) |
| `scripts/setup-approved-labs.php` | WP-CLI script to configure all labs |
| `scripts/check-venue-coordinates.php` | Diagnostic script to verify venue coordinates |
| `scripts/geocode-approved-labs.php` | Geocode venues missing coordinates |
### Files Modified
@ -65,19 +156,25 @@
| `assets/js/find-training-map.js` | Render badges, bind contact form handler |
| `assets/css/find-training-map.css` | Equipment/amenities badge styles |
### Known Issue: Venues Not Displaying on Map
### Issue Resolved: Venues Now Displaying on Map ✅
**Symptom:** Map at `/find-training` shows no venue markers despite data being correctly configured.
**Root Cause:** `venue_type` taxonomy wasn't being registered when `get_venue_markers()` ran.
**Verified:**
- ✅ 9 venues have `mq-approved-lab` taxonomy term assigned
- ✅ API endpoint returns 9 approved labs correctly
- ✅ Equipment and amenities data populated
`HVAC_Venue_Categories::instance()` was instantiated at 'init' priority 5, but then tried to add hooks to 'init' priority 5 for taxonomy registration. Since WordPress was already processing priority 5 handlers, the hook never fired.
**To Debug Next Session:**
- Check JavaScript console for marker rendering errors
- Verify Google Maps marker creation for venues
- Check venue toggle state (`#hvac-show-venues`)
**Fix Applied:**
1. **`includes/class-hvac-venue-categories.php`** - Added `did_action('init')` check in constructor
- If 'init' has already fired, call `register_taxonomies()` and `create_default_terms()` directly
- Otherwise, use the standard hook approach
2. **`includes/find-training/class-hvac-training-map-data.php`** - Fixed HTML entity encoding
- Venue names now use `html_entity_decode()` to properly display `&` and `` characters
- Event titles also fixed
**Result:**
- ✅ All 9 approved training labs now display as orange venue markers on the map
- ✅ Venue names display correctly (e.g., "Auer Steel & Heating Supply" not "Auer Steel &#038;...")
- ✅ Marker clustering works with mixed trainer/venue markers
---