# Calendar Plugin Changelog ## Version 6.0.2 (2026-02-09) - FIREFOX DAY HEADER FIX - **Fixed:** In Firefox, the SMTWTFS day-of-week header row was rendering at the same height as calendar day cells (58px instead of 22px). Firefox ignores `max-height` on `` table cells per CSS spec. Replaced `` with a CSS grid `
` outside the table, making header height fully independent of table cell sizing. Works consistently across Chrome, Firefox, Safari, and Edge. ## Version 6.0.1 (2026-02-09) - THEME PARAMETER FIX - **Fixed:** `theme=wiki` (and all `theme=` parameters) had no effect — all three render functions (`renderCompactCalendar`, `renderEventPanelOnly`, `renderSidebarWidget`) were ignoring the syntax parameter and always reading the admin global default via `getSidebarTheme()` - **Fixed:** `renderEventDialog` also ignored theme context — now receives theme from its caller - **How it works now:** `{{calendar theme=wiki}}`, `{{eventlist sidebar theme=purple}}`, `{{eventpanel theme=professional}}` all correctly apply the specified theme. The admin-configured default is used as fallback only when no `theme=` parameter is present. ## Version 6.0.0 (2026-02-09) - CODE AUDIT & v6 RELEASE - **Audited:** All PHP files (syntax.php, action.php, admin.php, sync_outlook.php) — balanced braces confirmed - **Audited:** calendar-main.js (2,840 lines) — Node syntax check passed, 44 global functions verified - **Audited:** style.css (3,218 lines) — balanced braces confirmed - **Audited:** All admin manage tab action handlers verified functional (13 actions) - **New:** Fresh README.md for GitHub with complete documentation - **Includes all v5.5.x fixes:** - Delta sync for Outlook (hash-based change tracking, O(changes) not O(total)) - Wiki theme sidebar section headers: distinct colors, no glow, themed day-click panel - Conflict badges on past events after AJAX navigation - Admin panel: green cleanup header, fixed broken CSS, endTime field name, cache clearing for all mutations, empty file cleanup, dead code removal ## Version 5.5.9 (2026-02-09) - ADMIN MANAGE TAB CLEANUP - **Fixed:** Cleanup Old Events section header now green (#00cc07) to match all other section headers - **Fixed:** Recurring stat card had broken CSS from `$colors['bg'] . '3e0'` concatenation — now uses proper `#fff3e0` - **Fixed:** Same broken CSS pattern in Outlook Sync tab log warning - **Fixed:** `editRecurringSeries` wrote `end_time` instead of correct `endTime` field name - **Fixed:** `editRecurringSeries` used uninitialized `$firstEventDate` variable — now properly declared - **Fixed:** `moveEvents` and `moveSingleEvent` could crash if event date key didn't exist in JSON — added `isset()` check - **Fixed:** `moveSingleEvent` now cleans up empty date keys and deletes empty files after moving - **Fixed:** `deleteRecurringSeries` now cleans up empty date keys and deletes empty JSON files - **Fixed:** Export version was hardcoded as '3.4.6' — now reads dynamically from plugin.info.txt - **Added:** `clearStatsCache()` helper method — all 11 mutation functions now properly clear the event stats cache - **Removed:** Dead `move_events` action handler (all forms use `move_selected_events`) - **Removed:** `console.log` debug statements from `sortRecurringTable` and `editRecurringSeries` - **Removed:** Stale "NEW!" comment from Events Manager section ## Version 5.5.8 (2026-02-09) - DELTA SYNC & WIKI THEME SIDEBAR POLISH - **Added:** Outlook sync now uses hash-based delta tracking — only new, modified, or deleted events hit the API - **Added:** computeEventHash() hashes all sync-relevant fields (title, description, time, date, color, namespace, task status) - **Added:** Sync state v2 format stores {outlookId, hash} per event; auto-migrates from v1 on first run - **Added:** Delta analysis summary shows new/modified/unchanged/deleted counts before syncing - **Changed:** Unchanged events are completely skipped (zero API calls) — O(changes) instead of O(total) - **Changed:** Removed per-run duplicate scan (was re-querying every event); use --clean-duplicates when needed - **Changed:** Wiki theme sidebar section headers now use distinct colors: orange (Today), green (Tomorrow), purple (Important) - **Fixed:** Wiki theme sidebar section headers no longer have colored glow — clean shadow instead - **Fixed:** Wiki theme week grid day-click panel header now uses accent color with white text - **Fixed:** Removed invalid var(--__...__) CSS syntax from inline styles (only works in CSS files, not HTML attributes) ## Version 5.5.7 (2026-02-09) - WIKI THEME SIDEBAR POLISH - **Fixed:** Sidebar Today/Tomorrow/Important headers now use three distinct colors (orange/green/purple) instead of similar greys - **Fixed:** Sidebar section headers no longer glow on wiki theme (clean shadow like professional) - **Fixed:** Week grid day-click panel header now uses theme accent color with white text instead of grey background - **Fixed:** Removed invalid var(--__...__) CSS variable syntax from inline styles (DokuWiki replacements only work in CSS files) - **Changed:** Wiki theme section header text now white for readability on colored backgrounds - **Changed:** Week grid JS theme colors now use actual $themeStyles values ## Version 5.5.6 (2026-02-09) - FIX CONFLICT BADGES ON PAST EVENTS AFTER AJAX - **Fixed:** Conflict badges now render on past events in JS rebuild path (were only in the future events branch) ## Version 5.5.5 (2026-02-09) - FIX SIDEBAR CONFLICT TOOLTIP POSITIONING - **Fixed:** Sidebar widget conflict tooltips now display next to the badge instead of upper-left corner - **Fixed:** Week grid conflict tooltips also fixed (same issue) - **Changed:** All conflict badges now use unified showConflictTooltip() system with base64-encoded data - **Removed:** data-tooltip CSS pseudo-element approach for conflict badges (replaced with JS tooltip) ## Version 5.5.4 (2026-02-09) - FIX PAST EVENT EXPAND ON FIRST LOAD - **Fixed:** Past events now expand on click from initial page load (PHP-rendered items were missing onclick="togglePastEventExpand(this)" handler that the JS-rebuilt version had) ## Version 5.5.3 (2026-02-09) - FIX CONFLICT TOOLTIP THEME COLORS - **Fixed:** Conflict tooltip now finds calendar container even when badge is inside day popup (appended to body) - **Fixed:** Empty CSS variable values no longer produce invisible text — fallback defaults applied when var returns empty string ## Version 5.5.2 (2026-02-09) - FIX CONFLICT TOOLTIP JSON PARSING - **Fixed:** Conflict tooltip data now base64-encoded to eliminate JSON parse errors from attribute quote escaping - **Fixed:** Removed double htmlspecialchars encoding on conflict titles in PHP (was escaping titles then re-escaping the JSON) - **Changed:** Both PHP and JS conflict badge rendering now use base64 for data-conflicts attribute - **Changed:** showConflictTooltip decodes base64 first, falls back to plain JSON for compatibility ## Version 5.5.1 (2026-02-09) - AJAX ROBUSTNESS & DIALOG THEMING - **Fixed:** Conflict tooltip badges now work after AJAX month navigation via event delegation - **Fixed:** All document-level event listeners guarded against duplicate attachment from multiple script loads - **Fixed:** showConflictTooltip closest() selector now matches actual container IDs (cal_, panel_, sidebar-widget-) - **Fixed:** Description textarea in add/edit dialog now 2 lines tall instead of 1 - **Added:** Event delegation for conflict badge mouseenter/mouseleave (capture phase) survives DOM rebuilds - **Added:** ESC key now also closes day popups and conflict tooltips - **Changed:** Namespace click filter handler wrapped in guard to prevent duplicate binding ## Version 5.5.0 (2026-02-09) - CSS VARIABLE REFACTOR & THEME CONSISTENCY - **Refactored:** All theming now driven by 15 CSS custom properties injected per calendar instance - **Refactored:** Removed ~85 inline styles from syntax.php and ~41 from calendar-main.js - **Refactored:** style.css is now the single source of truth for all visual styling - **Fixed:** Day popup (click cell) now fully themed — CSS vars propagated from container - **Fixed:** Add/Edit event dialog now themed in all contexts (main calendar, eventlist panel, sidebar widget) - **Fixed:** Popup footer and "+ Add Event" button were using inline themeStyles — now use CSS vars - **Added:** CSS variable injection for {{eventlist panel}} containers - **Added:** CSS variable injection for {{eventlist sidebar}} widget containers - **Added:** propagateThemeVars() helper ensures dialogs/popups always get theme regardless of DOM position - **Added:** Wiki template mapping reads __link__ as accent color from style.ini - **Added:** Detailed CSS variable reference table in style.css header comment - **Added:** Detailed style.ini → CSS variable mapping documentation in syntax.php - **Changed:** Conflict tooltip reads CSS vars via getComputedStyle instead of data-themeStyles - **Changed:** Admin changelog now uses paginated timeline viewer instead of tiny scrolling div - **Removed:** Dark Reader MutationObserver compatibility (CSS vars natively compatible) - **Removed:** $isWikiTheme branching from PHP render path ## Version 5.3.6 (2026-02-09) - HEARTS + CSS BACKGROUND FIX! 💖 ### 💖 Added: Hearts in Explosions! - **Added:** 8-12 pink hearts in each click explosion - **Added:** Random sizes (12-28px) and directions - **Result:** Extra love in every click! 💖 ### 🎨 Fixed: Background CSS Property for Dark Mode Readers - **Fixed:** Added `background: transparent` to CSS (was completely removed) - **Fixed:** Now CSS readers can detect and modify background property - **Why:** Inline styles override transparent, but CSS readers can now see the property - **Result:** Dark mode plugins can now change calendar backgrounds! ### The CSS Problem **Why backgrounds weren't changing with dark mode readers**: **Before (v5.3.5)**: ```css .calendar-compact-grid tbody td { /* background removed - set via inline style */ border: 1px solid... } ``` **Problem**: CSS property doesn't exist! - Dark mode readers look for `background` property in CSS - Can't override what doesn't exist - Inline styles work, but readers can't modify them **After (v5.3.6)**: ```css .calendar-compact-grid tbody td { background: transparent; /* Now exists! */ border: 1px solid... } ``` **Solution**: - Property exists in CSS - Dark mode readers can override it - Inline styles still override transparent - Everyone wins! ### What's Fixed **Elements now have background property**: - `.calendar-compact-grid tbody td` ✓ - `.calendar-compact-grid tbody td:hover` ✓ - `.event-compact-item` ✓ - `.event-compact-item:hover` ✓ **How it works**: 1. CSS sets `background: transparent` (default) 2. Inline styles set actual color (overrides transparent) 3. Dark mode readers can override CSS property 4. Works for everyone! ### Hearts in Explosion **Click anywhere → Hearts explode!** **Heart details**: - Count: 8-12 per explosion (random) - Size: 12-28px (random variety) - Emoji: 💖 (pink heart) - Direction: Random 360° - Speed: 60-140px travel - Duration: 0.8-1.2s - z-index: 9999999 (always visible) **Combined with**: - 25 glowing particles - 40 pixel sparkles - Bright flash - **Total: 73-77 elements!** ### Visual Result **Click explosion**: ``` 💖 ✦ • ✦ 💖 💖 • • 💖 ✦ • 💥! • ✦ 💖 • • 💖 💖 ✦ • ✦ 💖 Hearts + Particles + Pixels! ``` **Dark mode now works**: ```css /* Dark mode reader can now do this: */ .calendar-compact-grid tbody td { background: #000 !important; /* Works! */ } ``` ### Why Transparent Works **CSS Cascade**: 1. CSS: `background: transparent` (lowest priority) 2. Inline style: `background: #f5f5f5` (overrides CSS) 3. Dark mode CSS: `background: #000 !important` (overrides inline) **Perfect solution!** ✓ ## Version 5.3.5 (2026-02-09) - PARTICLES ABOVE DIALOGS! 🎆 ### 🔝 Fixed: Particles Now Appear Above All Dialogs! - **Fixed:** Increased z-index to 9999999 for all particles - **Fixed:** Particles now visible above event dialogs, month picker, etc. - **Result:** Cursor effects and explosions always visible! ### The Z-Index Problem **Before (v5.3.4)**: - Particles: z-index 9999 - Dialogs: z-index 10000-999999 - **Particles hidden behind dialogs!** **After (v5.3.5)**: - Particles: z-index 9999999 - Trail: z-index 9999998 - Pixels: z-index 9999997 - **Particles ALWAYS on top!** ### What's Fixed ✅ **Main particles** (explosion orbs) ✅ **Cursor trail** (glowing dots) ✅ **Pixel sparkles** (tiny bright stars) ✅ **Flash effect** (click burst) **All now appear above**: - Event dialog popups - Month picker - Day popups - Any modal overlays ### Visual Result **Moving cursor over dialog**: ``` ┌─────────────────────┐ │ Event Dialog │ │ ✦ • ✦ │ ← Sparkles visible! │ → ✦ │ ← Cursor trail visible! │ • ✦ • │ └─────────────────────┘ ``` **Clicking on dialog**: ``` ┌─────────────────────┐ │ ✦ • ✦ • ✦ │ │ • 💥! • │ ← Explosion visible! │ ✦ • ✦ • ✦ │ └─────────────────────┘ ``` **Perfect visibility everywhere!** ✨ ## Version 5.3.4 (2026-02-09) - THEMED MONTH PICKER + DIALOG CURSOR FIX ### 🎨 Fixed: Month Picker Now Themed! - **Fixed:** Jump to Month dialog now uses theme colors - **Fixed:** Dialog background, borders, text all themed - **Fixed:** Select dropdowns use theme colors - **Fixed:** Buttons use theme accent colors - **Result:** Month picker matches calendar theme! ### 🎆 Fixed: Cursor Effects Work in Dialogs! - **Fixed:** Cursor trail now works when hovering over dialogs - **Fixed:** Click explosions work when clicking inside dialogs - **Technical:** Changed to capture phase event listeners - **Result:** Effects work EVERYWHERE now! ### Month Picker Theming **Before (v5.3.3)**: - White background (hardcoded) - Black text (hardcoded) - No theme integration - Looked out of place **After (v5.3.4)**: - Dialog background: `theme.bg` - Dialog border: `theme.border` - Text color: `theme.text_primary` - Dropdowns: `theme.cell_bg` + `theme.text_primary` - Cancel button: `theme.cell_bg` - Go button: `theme.border` (accent color) **Fully integrated!** ✅ --- ### Theme Examples **Matrix Theme**: ``` ┌─────────────────────────┐ │ Jump to Month │ ← Dark bg, green border │ [February ▼] [2026 ▼] │ ← Dark dropdowns │ [Cancel] [Go] │ ← Green "Go" button └─────────────────────────┘ ``` **Pink Theme**: ``` ┌─────────────────────────┐ │ Jump to Month │ ← Dark bg, pink border │ [February ▼] [2026 ▼] │ ← Dark dropdowns │ [Cancel] [Go] │ ← Pink "Go" button └─────────────────────────┘ With sparkle effects! ✨ ``` **Professional Theme**: ``` ┌─────────────────────────┐ │ Jump to Month │ ← Clean bg, blue border │ [February ▼] [2026 ▼] │ ← Clean dropdowns │ [Cancel] [Go] │ ← Blue "Go" button └─────────────────────────┘ ``` --- ### Dialog Cursor Fix **The Problem**: Dialogs use `event.stopPropagation()` to prevent clicks from closing them. This blocked cursor effects! **The Solution**: Use **capture phase** event listeners: ```javascript // Before (bubbling phase) document.addEventListener('click', handler) // After (capture phase) document.addEventListener('click', handler, true) ↑ Capture phase! ``` **Capture phase runs BEFORE stopPropagation!** --- ### Now Works Everywhere ✅ **Calendar area** ✅ **Event dialogs** ✅ **Month picker dialog** ✅ **Day popup dialogs** ✅ **Anywhere on screen** **No more blocked effects!** 🎆 --- ### Technical Details **Event phases**: ``` 1. Capture phase ← We listen here now! 2. Target phase 3. Bubbling phase ← stopPropagation blocks this ``` **By using capture phase**: - Events caught before stopPropagation - Works in all dialogs - No conflicts with dialog logic --- ### All Dialogs Checked ✅ **Month picker** - Now themed! ✅ **Event dialog** - Already themed ✅ **Day popup** - Already themed **Everything consistent!** 🎨 --- ## Version 5.3.3 (2026-02-09) - TINY NEON PIXEL SPARKLES! ✨ ### ✨ Added: Bright Neon Pixel Sparkles Everywhere! - **Added:** Tiny 1-2px bright pixel sparkles alongside cursor trail - **Added:** 40 pixel sparkles in click explosions - **Changed:** Cursor effects now work on ENTIRE SCREEN (not just calendar) - **Result:** Maximum sparkle effect! 💎 ### Tiny Pixel Sparkles **3-6 tiny bright pixels appear with each cursor movement!** **Characteristics**: - Size: 1-2px (single pixel appearance!) - Colors: Bright neon whites and pinks - Pure white (#fff) - 40% chance - Hot pink (#ff1493) - Pink (#ff69b4) - Light pink (#ffb6c1) - Soft pink (#ff85c1) - Glow: Triple-layer shadow (intense!) - Spawn: Random 30px radius around cursor - Animations: - 50% twinkle in place - 50% float upward **Creates a cloud of sparkles around your cursor!** --- ### Click Explosion Enhanced **Now with 40 EXTRA pixel sparkles!** **Click anywhere → BIG BOOM**: - 25 main glowing particles (6-10px) - **40 tiny pixel sparkles (1-2px)** ← NEW! - Bright white flash - Total: 65+ visual elements! **Pixel sparkles in explosion**: - Shoot outward in all directions - Random distances (30-110px) - Multiple bright colors - Some twinkle, some explode - Creates stellar effect! --- ### Entire Screen Coverage **Effects now work EVERYWHERE!** **Before (v5.3.2)**: - Only inside calendar viewport - Limited to calendar area **After (v5.3.3)**: - Works on entire screen! ✓ - Cursor trail follows everywhere - Click explosions anywhere - Used `position: fixed` + `clientX/Y` **Move anywhere on the page for sparkles!** --- ### Visual Effect **Cursor movement**: ``` • ✦ • ← Tiny pixels • ✦ • ← Glowing trail ✦ • → • ✦ ← Cursor • ✦ • ← Mixed sizes • ✦ • ← Sparkle cloud ``` **Click explosion**: ``` ✦ • ✦ • ✦ ✦ • • ✦ ✦ • 💥! • ✦ ✦ • • ✦ ✦ • ✦ • ✦ 65+ particles total! ``` --- ### Sparkle Details **Trail Pixels** (3-6 per movement): - Size: 1-2px - Spawn rate: Every 40ms - Spread: 30px radius - Duration: 0.6-0.8s - 50% twinkle, 50% float **Explosion Pixels** (40 total): - Size: 1-3px - Spread: 30-110px radius - Duration: 0.4-0.8s - All directions - Intense glow **Main Particles** (25 total): - Size: 4-10px - Spread: 50-150px - Full color palette - Original firework effect --- ### Color Distribution **Pixel sparkles favor white**: - 40% pure white (#fff) - brightest! - 60% pink shades - variety **Creates brilliant sparkle effect!** --- ### Performance **Still optimized**: - Trail: 30ms throttle - Pixels: 40ms throttle - Auto-cleanup - Hardware accelerated - Smooth 60fps **Lots of sparkles, zero lag!** --- ### Full-Screen Magic **Pink theme calendar detected**: ```javascript if (pink calendar exists) { Enable effects for ENTIRE SCREEN Not just calendar area } ``` **Works everywhere on page!** ✨ --- ## Version 5.3.2 (2026-02-09) - PINK FIREWORKS! 🎆💖 ### 🎆 Changed: Glowing Pink Particles Instead of Emoji Sparkles! - **Removed:** Emoji sparkle images (✨) - **Added:** Glowing pink particle trail following cursor - **Added:** FIREWORKS explosion on click! - **Result:** Beautiful glowing effects, not emoji! ### Glowing Cursor Trail **Pink glowing dots follow your cursor!** - Small glowing pink orbs (8px) - Radial gradient glow effect - Multiple box-shadows for depth - Fade out smoothly (0.5s) - Throttled to 30ms for smoothness ``` • • • → • ← Your cursor • • ``` **Not emoji - actual glowing particles!** --- ### Click Fireworks! 🎆 **Click anywhere on the calendar → BOOM!** **20 pink particles explode outward!** - Radial burst pattern (360° coverage) - Random speeds (50-150px travel) - 4 shades of pink: - Hot pink (#ff1493) - Pink (#ff69b4) - Light pink (#ff85c1) - Very light pink (#ffc0cb) - Random sizes (4-10px) - Individual glowing halos - Smooth explosion animation **Plus a bright flash at click point!** - 30px radius glow - Intense pink flash - Fades quickly (0.3s) --- ### Visual Effect **Cursor movement**: ``` • • • • • → • ← Glowing trail • • • • ``` **Click explosion**: ``` • • • • • • BOOM! • ← 20 particles • • • • • ``` **All particles glow with pink halos!** --- ### Particle Details **Trail Particles**: - Size: 8x8px - Color: Pink radial gradient - Shadow: 10px + 20px glow layers - Duration: 0.5s fade - Rate: 30ms throttle **Explosion Particles**: - Size: 4-10px (random) - Colors: 4 pink shades (random) - Shadow: 10px + 20px glow (matches color) - Duration: 0.6-1.0s (random) - Pattern: Perfect circle burst **Flash Effect**: - Size: 30x30px - Color: Bright hot pink - Shadow: 30px + 50px mega-glow - Duration: 0.3s instant fade --- ### Performance **Optimized for smoothness**: - Trail throttled to 30ms - Auto-cleanup after animations - CSS hardware acceleration - No memory leaks - Smooth 60fps **Won't slow you down!** --- ### Comparison **Before (v5.3.1)**: - ✨ Emoji sparkle images - Static unicode characters - Limited visual impact **After (v5.3.2)**: - 💖 Glowing pink particles - Radial gradients + shadows - Beautiful firework explosions - Much more impressive! --- ### Only Pink Theme **These effects only appear**: - On `.calendar-theme-pink` elements - Other themes unaffected - Pure pink magic! 💖 --- ## Version 5.3.1 (2026-02-09) - MYSPACE SPARKLE CURSOR! ✨✨✨ ### ✨ Added: MySpace-Style Sparkle Trail! - **Added:** Sparkle cursor trail that follows your mouse (pink theme only!) - **Toned down:** Reduced glow effects for better taste - **Added:** Sparkles appear on cell hover - **Added:** Sparkles on event hover (left and right sides!) - **Added:** Sparkles on today's cell corners - **Added:** Sparkles on navigation buttons - **Added:** Sparkles in calendar header - **Result:** Pure nostalgic MySpace magic! ✨ ### MySpace Sparkle Cursor Trail **The classic effect from 2006!** - Sparkles follow your cursor as you move - Random sizes (12-22px) - Random slight offsets for natural feel - Float up and fade out animation - Throttled to 50ms (smooth, not laggy) - Only on pink theme calendars ``` ✨ ✨ ✨ ✨ → ✨ (cursor trail) ✨ ✨ ✨ ``` **Pure nostalgia!** --- ### Sparkles Everywhere **Calendar cells**: - Hover over any day → ✨ floats up - Smooth 1.5s animation - Centered sparkle **Event items**: - Hover → ✨ on left side - Hover → ✨ on right side - Staggered animations (0.4s delay) - Continuous twinkling **Today's cell**: - ✨ in top-right corner (continuous) - ✨ in bottom-left corner (offset timing) - Always sparkling! **Navigation buttons**: - Hover on < or > → ✨ appears top-right - One-time float animation **Calendar header**: - ✨ on left side (continuous) - ✨ on right side (offset 1s) - Always twinkling --- ### Toned Down Glows **Before (v5.3.0)**: TOO MUCH GLOW! - 50px shadows - 4-layer effects - Overwhelming **After (v5.3.1)**: Just right! - 8-15px max shadows (subtle) - 2-layer effects - Professional with personality **Glow reductions**: - Today shimmer: 35px → 12px - Today hover: 50px → 15px - Event glow: 18px → 6px - Badge pulse: 25px → 8px - Container glow: 20px → 8px **Much more tasteful!** --- ### Sparkle Animations **sparkle-twinkle** (0.8s): ``` Opacity: 0 → 1 → 1 → 0 Scale: 0 → 1 → 1 → 0 Rotation: 0° → 180° → 360° ``` **sparkle-float** (1.5s): ``` Moves up: 0px → -50px Opacity: 0 → 1 → 1 → 0 Scale: 0 → 1 → 0.8 → 0 ``` **Pure MySpace magic!** ✨ --- ### Where Sparkles Appear ✅ **Cursor trail** (continuous while moving) ✅ **Calendar cells** (on hover) ✅ **Event items** (on hover, left + right) ✅ **Today's cell** (continuous, corners) ✅ **Navigation buttons** (on hover) ✅ **Calendar header** (continuous, sides) **Sparkles EVERYWHERE!** ✨✨✨ --- ### Performance **Cursor trail**: - Throttled to 50ms - Auto-cleanup after 1s - No memory leaks - Smooth 60fps **CSS animations**: - Hardware accelerated - No JavaScript overhead (except cursor) - Efficient transforms **Won't slow down your browser!** --- ### Pure Nostalgia **Remember MySpace profiles?** - Glitter graphics ✨ - Sparkle cursors ✨ - Auto-play music 🎵 (ok, we didn't add that) - Animated GIF backgrounds - Comic Sans everywhere **We brought back the sparkles!** ✨ --- ### Theme Comparison **Other themes**: Professional and clean **Pink theme**: ✨ SPARKLES EVERYWHERE ✨ **Only pink theme gets the magic!** --- ## Version 5.3.0 (2026-02-09) - PINK BLING THEME EFFECTS! ✨💎 ### 💖 Added: Pink Theme Gets BLING! - **Added:** Shimmering animation for today's cell - **Added:** Sparkling text effect on today's date - **Added:** Glowing pulse for event bars - **Added:** Gradient shimmer on headers - **Added:** Extra glow on hover effects - **Added:** Pulsing urgent badge for past due items - **Result:** Pink theme is now FABULOUS! ✨ ### Shimmer Effects **Today's Cell**: - Continuous shimmer animation (2 second loop) - Multi-layer glow effect - Pink and hot pink overlapping shadows - Pulses from subtle to intense - Extra sparkle on hover **Today's Date Number**: - Sparkle animation (1.5 second loop) - Text shadow glow effect - Slight scale pulse (100% → 105%) - Pink to hot pink shadow transition ### Glow Effects **Event Bars**: - Continuous glow pulse (2 second loop) - Uses event's own color - Adds pink accent glow layer - Creates depth and dimension **Event Items**: - Subtle base glow - Enhanced glow on hover - Slight slide animation on hover - Professional yet playful ### Gradient Shimmer **Headers**: - Animated gradient background - 3-color pink gradient flow - Smooth 3-second animation - Creates movement and life - Applies to calendar header and event list header ### Badge Effects **TODAY Badge**: - Sparkle animation - Synchronized with today's date - Extra prominence **PAST DUE Badge**: - Urgent pulsing effect (1 second loop) - Orange glow intensifies - Draws attention to urgent items - Faster pulse for urgency ### Container Bling **Main Container**: - Multi-layer pink glow - Soft outer shadow - Creates floating effect - Subtle but elegant ### Animation Details **pink-shimmer** (2s loop): ``` Start: Subtle 5px glow Peak: Intense 35px multi-layer glow End: Back to subtle ``` **pink-sparkle** (1.5s loop): ``` Start: Base glow + scale 1.0 Peak: Intense glow + scale 1.05 End: Back to base ``` **pink-glow-pulse** (2s loop): ``` Start: Small glow (3px, 6px) Peak: Large glow (6px, 12px, 18px) End: Back to small ``` **pink-gradient-shimmer** (3s loop): ``` Gradient flows across element Creates wave effect Smooth continuous motion ``` **pink-pulse-urgent** (1s loop - faster!): ``` Start: Orange glow 5px Peak: Orange glow 25px (intense) End: Back to 5px ``` ### Visual Experience **Today's Cell**: ``` ┌──┬──┬──┬──┬──┬──┬──┐ │ │ │ ✨ │ │ │ │ │ ← Shimmers constantly │ │ │[9]│ │ │ │ │ ← Sparkles │ │ │ ✨ │ │ │ │ │ ← Glows and pulses └──┴──┴──┴──┴──┴──┴──┘ ``` **Event Bars**: ``` ━━━━━━━ ← Glows and pulses ━━━━━━━ ← Each bar animated ━━━━━━━ ← Creates rhythm ``` **Headers**: ``` ╔═════════════════════╗ ║ ~~~~~~~~~~ ║ ← Gradient flows ║ February 2026 ║ ← Shimmer effect ╚═════════════════════╝ ``` ### Theme Comparison **Before (v5.2.8)**: - Pink colors - Static elements - Standard shadows **After (v5.3.0)**: - Pink colors ✓ - Animated shimmer ✨ - Sparkling effects 💎 - Glowing pulses ✨ - Moving gradients 🌊 - BLING! 💖 ### Performance **All animations**: - Hardware accelerated (transform, opacity) - Smooth 60fps - CSS animations (no JavaScript) - Minimal CPU usage - Disabled in reduced-motion preference ### Only for Pink Theme **Effects only apply when**: ```css .calendar-theme-pink ``` **Other themes unaffected**: - Matrix stays Matrix - Professional stays Professional - Purple stays Purple - Wiki stays clean **Pink gets all the bling!** ✨💎 ### Use Cases **Perfect for**: - Celebrating occasions - Fun team calendars - Personal style expression - Standing out - Making calendar time fabulous **Not just pink, but BLING pink!** 💖✨ ## Version 5.2.8 (2026-02-09) - TODAY BOX USES THEME COLORS ### 🎨 Fixed: Today's Date Box Now Uses Theme Colors - **Fixed:** Today's day number box now uses theme border color - **Fixed:** Text color adapts to theme (white for dark themes, bg color for light) - **Result:** Today box matches the theme perfectly! ### The Issue Today's date had a hardcoded green box: **In style.css**: ```css .cal-today .day-num { background: #008800; /* Hardcoded green! */ color: white; } ``` **Didn't adapt to themes at all!** ### The Fix **Now uses theme colors**: ```php // Today's day number if ($isToday) { background: $themeStyles['border'], // Theme's accent color! color: (professional theme) ? white : bg color } ``` ### Theme Examples **Matrix Theme**: - Box background: `#00cc07` (matrix green) - Text color: `#242424` (dark background) **Purple Theme**: - Box background: `#9b59b6` (purple) - Text color: `#2a2030` (dark background) **Professional Theme**: - Box background: `#4a90e2` (blue) - Text color: `#ffffff` (white text) **Pink Theme**: - Box background: `#ff1493` (hot pink) - Text color: `#1a0d14` (dark background) **Wiki Theme**: - Box background: Template's `__border__` color - Text color: Template's `__background_site__` color ### Visual Result **Matrix Theme**: ``` ┌──┬──┬──┬──┬──┬──┬──┐ │ 1│ 2│ 3│[4]│ 5│ 6│ 7│ └──┴──┴──┴──┴──┴──┴──┘ ↑ Green box (#00cc07) ``` **Professional Theme**: ``` ┌──┬──┬──┬──┬──┬──┬──┐ │ 1│ 2│ 3│[4]│ 5│ 6│ 7│ └──┴──┴──┴──┴──┴──┴──┘ ↑ Blue box (#4a90e2) ``` **Wiki Theme**: ``` ┌──┬──┬──┬──┬──┬──┬──┐ │ 1│ 2│ 3│[4]│ 5│ 6│ 7│ └──┴──┴──┴──┴──┴──┴──┘ ↑ Template border color ``` ### Implementation **Inline styles added**: - Background uses `$themeStyles['border']` (theme accent) - Text color uses `$themeStyles['bg']` for contrast - Special case: Professional theme uses white text - All with `!important` to override CSS **CSS cleaned up**: - Removed hardcoded `#008800` background - Removed hardcoded `white` color - Kept structural styles (border-radius, font-weight) ### Benefits **Theme Consistency**: - Today box matches theme accent color - Proper contrast with background - Professional appearance **Automatic Adaptation**: - Works with all themes - Works with custom wiki template colors - No manual adjustment needed **Visual Harmony**: - Border color used throughout theme - Today box reinforces theme identity - Consistent design language ## Version 5.2.7 (2026-02-09) - FIX GRID BACKGROUND MISMATCH ### 🎯 Fixed: Table Grid Background Now Matches Cells - **Found:** `grid_bg` was using `__background_alt__` (different from cells!) - **Fixed:** Changed `grid_bg` to use `__background_site__` (same as cells) - **Result:** Table background no longer shows through cells! ### The Layer Problem The table itself had a DIFFERENT background color than its cells! **Before (v5.2.6)**: ```php 'grid_bg' => __background_alt__, // Table background (#e8e8e8) 'cell_bg' => __background_site__, // Cell background (#f5f5f5) ``` **The table background was showing THROUGH the cells!** ### Why This Happened **Visual layers**: ``` Table Element ├─ background: __background_alt__ (#e8e8e8) ← Different! └─ Cells └─ background: __background_site__ (#f5f5f5) ← Different! The table background shows through any gaps! ``` ### The Fix **After (v5.2.7)**: ```php 'grid_bg' => __background_site__, // Table background (#f5f5f5) ✓ 'cell_bg' => __background_site__, // Cell background (#f5f5f5) ✓ ``` **NOW THEY MATCH!** ### Where grid_bg Is Used The table element itself: ```html ← Was showing through!
1
``` Even with cell inline styles, the TABLE background shows through! ### All Background Sources Now Unified **Everything now uses __background_site__**: - `bg` → __background_site__ ✓ - `header_bg` → __background_site__ ✓ - `grid_bg` → __background_site__ ✓ (JUST FIXED!) - `cell_bg` → __background_site__ ✓ **Perfect consistency!** 🎨 ### Why It Was Different **Originally the grid was meant to show borders**: - `grid_bg` was `__background_alt__` (slightly different) - Created visual separation between cells - But with transparent/thin cells, it showed through! **Now unified for consistency!** ### Visual Result **Before (layers visible)**: ``` ┌─────────────────┐ │ Grid (#e8e8e8) │ ← Showing through! │ ┌──┬──┬──┐ │ │ │ │ │ │ │ ← Cells (#f5f5f5) │ └──┴──┴──┘ │ └─────────────────┘ ``` **After (unified)**: ``` ┌─────────────────┐ │ Grid (#f5f5f5) │ ← Same color! │ ┌──┬──┬──┐ │ │ │ │ │ │ │ ← Cells (#f5f5f5) │ └──┴──┴──┘ │ └─────────────────┘ Perfect match! ``` ### Complete Background Mapping **All using __background_site__ now**: - Main container background - Left panel background - Right panel background - Eventlist background - Calendar grid background ← JUST FIXED - Calendar cell backgrounds - Event item backgrounds - Clock header background - Search input background - Past events toggle **EVERYTHING UNIFIED!** 🎯 ## Version 5.2.6 (2026-02-09) - REMOVE CONTAINER BACKGROUNDS ### 🐛 Fixed: Removed Container Backgrounds Showing Through - **Found:** `.calendar-compact-container` had `background: #ffffff;` - **Found:** `.calendar-compact-left` had `background: #fafafa;` - **Found:** `.calendar-compact-right` had `background: #ffffff;` - **Found:** `.event-search-input-inline` had `background: white;` - **Found:** `.past-events-toggle` had `background: #f5f5f5;` - **Result:** Container backgrounds no longer show through cells! ### The Container Problem The parent containers had hardcoded backgrounds that were showing through! **Container backgrounds (lines 4-91)**: ```css .calendar-compact-container { background: #ffffff; /* ← Main container! */ } .calendar-compact-left { background: #fafafa; /* ← Left panel (calendar side)! */ } .calendar-compact-right { background: #ffffff; /* ← Right panel (events side)! */ } ``` **These were showing through the cells and events!** ### Why Containers Matter Even though cells have inline styles, if the CONTAINER behind them has a different background, it can show through: ``` Container (#fafafa) ← Showing through! └─ Table Cell (#f5f5f5) ← Transparent areas └─ Content ``` ### All Backgrounds Removed **v5.2.6 removes**: - `.calendar-compact-container` background - `.calendar-compact-left` background - `.calendar-compact-right` background - `.event-search-input-inline` background - `.past-events-toggle` background & hover **v5.2.5 removed**: - `.calendar-compact-grid tbody td` background - `.calendar-compact-grid thead th` background **v5.2.4 removed**: - `.cal-empty`, `.cal-today`, `.cal-has-events` backgrounds **v5.2.3 removed**: - `.event-compact-item` background **ALL container and element backgrounds eliminated!** 🧹 ### What Should Work Now **Calendar cells**: No container background showing through ✓ **Event items**: No container background showing through ✓ **Search bar**: Uses template color ✓ **Past events toggle**: Uses template color ✓ ### Complete List of Fixes **Containers**: - Main container ✓ - Left panel ✓ - Right panel ✓ **Elements**: - Table cells ✓ - Event items ✓ - Search input ✓ - Past events toggle ✓ **EVERYTHING removed!** 🎯 ### Critical: Clear Caches **Must clear caches or won't work**: 1. Hard refresh: Ctrl+Shift+R (5 times!) 2. Clear DokuWiki cache 3. Close browser completely 4. Reopen and test **CSS caching is EXTREMELY persistent!** ## Version 5.2.5 (2026-02-09) - REMOVE TABLE CELL CSS BACKGROUNDS ### 🐛 Fixed: Removed Hardcoded Backgrounds from Table Cells - **Found:** `.calendar-compact-grid tbody td` had `background: #ffffff;`! - **Found:** `.calendar-compact-grid tbody td:hover` had `background: #f0f7ff;`! - **Found:** `.calendar-compact-grid thead th` had `background: #f8f8f8;`! - **Fixed:** Removed ALL hardcoded backgrounds from table CSS - **Result:** Calendar table cells finally use template colors! ### The REAL Culprits The generic table CSS was overriding everything! **In style.css (lines 307-356)**: ```css .calendar-compact-grid thead th { background: #f8f8f8; /* ← Header cells hardcoded! */ } .calendar-compact-grid tbody td { background: #ffffff; /* ← ALL table cells hardcoded! */ } .calendar-compact-grid tbody td:hover { background: #f0f7ff; /* ← Hover state hardcoded! */ } ``` **These apply to ALL `` and `` elements in the calendar table!** ### Why This Was the Last One **CSS Specificity Order**: 1. `.calendar-compact-grid tbody td` (generic - applies to ALL cells) 2. `.cal-empty`, `.cal-today`, `.cal-has-events` (specific - applies to some cells) 3. Inline styles (should win but didn't) **We removed the specific ones (v5.2.4), but the generic one was still there!** ### What We've Removed **v5.2.3**: - `.event-compact-item` background - `.event-compact-item:hover` background **v5.2.4**: - `.cal-empty` background & hover - `.cal-today` background & hover - `.cal-has-events` background & hover **v5.2.5 (FINAL)**: - `.calendar-compact-grid tbody td` background ✓ - `.calendar-compact-grid tbody td:hover` background ✓ - `.calendar-compact-grid thead th` background ✓ **All CSS background overrides ELIMINATED!** 🎯 ### Why It Took 5 Versions **CSS had layers of hardcoded backgrounds**: ``` Layer 1: Table cells (.calendar-compact-grid tbody td) ↓ Overrode inline styles Layer 2: Cell states (.cal-today, .cal-empty, etc.) ↓ Overrode table cells Layer 3: Event items (.event-compact-item) ↓ Overrode inline styles ALL had to be removed! ``` **We kept finding more specific CSS, but the base table CSS was there all along!** ### Visual Result **NOW everything matches**: ``` Calendar Table: ┌──┬──┬──┬──┬──┬──┬──┐ │ S│ M│ T│ W│ T│ F│ S│ ← Headers: __background_site__ ├──┼──┼──┼──┼──┼──┼──┤ │ 1│ 2│ 3│ 4│ 5│ 6│ 7│ ← Cells: __background_site__ ├──┼──┼──┼──┼──┼──┼──┤ │ 8│ 9│10│11│12│13│14│ ← All: __background_site__ └──┴──┴──┴──┴──┴──┴──┘ Sidebar Events: ┌────────────────────────┐ │ 📅 Event │ ← __background_site__ │ 📅 Event │ ← __background_site__ └────────────────────────┘ FINALLY ALL MATCHING! ✓ ``` ### Complete List of Removed CSS **ALL hardcoded backgrounds removed**: - `.event-compact-item` background - `.event-compact-item:hover` background - `.cal-empty` background & hover - `.cal-today` background & hover - `.cal-has-events` background & hover - `.calendar-compact-grid tbody td` background ← NEW - `.calendar-compact-grid tbody td:hover` background ← NEW - `.calendar-compact-grid thead th` background ← NEW **Every single CSS background override is GONE!** 🧹 ### Testing Steps **After installing v5.2.5**: 1. **Clear browser cache**: Ctrl+Shift+R (3 times!) 2. **Clear DokuWiki cache**: Click the button 3. **Close browser completely**: Restart it 4. **Visit page**: Should finally see matching backgrounds **CSS is EXTREMELY sticky - may need to clear multiple times!** ### This Should Be It **No more CSS overrides exist** (we've checked the entire file): - Table cells ✓ Fixed - Cell states ✓ Fixed - Event items ✓ Fixed - Headers ✓ Fixed - Hover states ✓ Fixed **All backgrounds now come from inline styles using template colors!** ## Version 5.2.4 (2026-02-09) - REMOVE CALENDAR CELL CSS BACKGROUNDS ### 🐛 Fixed: Removed Hardcoded Backgrounds from Calendar Cells - **Found:** Calendar cell CSS had hardcoded backgrounds with `!important`! - **Fixed:** Removed backgrounds from `.cal-today`, `.cal-empty`, `.cal-has-events` CSS - **Result:** Calendar cells now use template colors! ### The Second Culprit MORE hardcoded backgrounds in the CSS file! **In style.css (lines 359-382)**: ```css .cal-empty { background: #fafafa !important; /* ← Overriding inline styles! */ } .cal-today { background: #e8f5e9 !important; /* ← Overriding today cell! */ } .cal-today:hover { background: #c8e6c9 !important; /* ← Overriding hover! */ } .cal-has-events { background: #fffbf0; /* ← Overriding event cells! */ } .cal-has-events:hover { background: #fff4d9; /* ← Overriding hover! */ } ``` **These were ALL overriding the inline styles!** ### The Fix **Removed all hardcoded backgrounds**: ```css .cal-empty { /* background removed - inline style handles this */ cursor: default !important; } .cal-today { /* background removed - inline style handles this */ } .cal-has-events { /* background removed - inline style handles this */ } /* Hover states also removed */ ``` ### What Was Overridden **v5.2.3 fixed**: - Event items in sidebar ✓ **v5.2.4 fixes**: - Calendar day cells ✓ - Today cell ✓ - Empty cells ✓ - Cells with events ✓ - All hover states ✓ ### Why This Kept Happening **CSS had hardcoded backgrounds everywhere**: 1. Event items: `#ffffff` (fixed in v5.2.3) 2. Calendar cells: Multiple colors (fixed in v5.2.4) 3. **All with `!important` flags!** **The inline styles couldn't override them!** ### Visual Result **Now ALL backgrounds match**: ``` Calendar Grid: ┌──┬──┬──┬──┬──┬──┬──┐ │ │ │ │ │ │ │ │ ← All use __background_site__ ├──┼──┼──┼──┼──┼──┼──┤ │ │██│ │ │ │ │ │ ← Today uses __background_neu__ ├──┼──┼──┼──┼──┼──┼──┤ │ │ │ │ │ │ │ │ ← All match template └──┴──┴──┴──┴──┴──┴──┘ Sidebar Events: ┌────────────────────────┐ │ 📅 Event │ ← Uses __background_site__ │ 📅 Event │ ← Uses __background_site__ └────────────────────────┘ Perfect consistency! ``` ### CSS Removed **Calendar cells**: - `.cal-empty` background - `.cal-empty:hover` background - `.cal-today` background - `.cal-today:hover` background - `.cal-has-events` background - `.cal-has-events:hover` background **All gone!** ✓ ### Important: Clear Caches Again! After installing v5.2.4: 1. **Hard refresh browser**: Ctrl+Shift+R (twice!) 2. **Clear DokuWiki cache**: Admin → Clear Cache 3. **May need to restart browser**: To clear CSS cache **Old CSS is VERY sticky!** ### Why It Took So Long **Multiple CSS overrides**: - Event items (v5.2.3) ✓ Fixed - Calendar cells (v5.2.4) ✓ Fixed - Each with different classes - Each with `!important` - Hidden throughout CSS file **Found them all now!** 🎯 ## Version 5.2.3 (2026-02-09) - REMOVE HARDCODED CSS BACKGROUNDS ### 🐛 Fixed: Removed Hardcoded Backgrounds from CSS - **Found:** CSS file had hardcoded `background: #ffffff;` overriding inline styles! - **Fixed:** Removed hardcoded backgrounds from `.event-compact-item` CSS - **Result:** Event backgrounds now properly use template colors! ### The Root Cause The CSS file was overriding the inline styles with hardcoded white backgrounds! **In style.css (lines 599-616)**: ```css .event-compact-item { background: #ffffff; /* ← This was overriding inline styles! */ } .event-compact-item:hover { background: #f8f9fa; /* ← And this on hover! */ } ``` **Even though inline styles had `!important`**, the CSS was still being applied because it comes after in the cascade! ### The Fix **Removed hardcoded backgrounds from CSS**: ```css .event-compact-item { /* background removed - set via inline style with template colors */ display: flex; /* ... other styles ... */ } .event-compact-item:hover { box-shadow: 0 1px 3px rgba(0,0,0,0.08); /* background removed - inline style handles this */ } ``` ### Why This Was So Difficult to Find **CSS Specificity & Cascade**: 1. Inline styles with `!important` should win 2. But CSS that comes after can still apply 3. The hardcoded `background: #ffffff` was silently overriding 4. All the PHP code was correct - it was the CSS! **What We Were Doing**: - ✓ Reading template colors correctly - ✓ Setting `cell_bg` to `__background_site__` correctly - ✓ Applying inline styles with `!important` correctly - ✗ CSS file was overriding everything! ### What Was Affected **Event items in**: - Main calendar sidebar - Standalone event list - Sidebar widget - All event displays **All had white backgrounds hardcoded in CSS!** ### Now Working **Events use template colors**: ```html
← Now this inline style actually works!
``` **No CSS override** ✓ ### Testing To verify this works: 1. Clear browser cache (important!) 2. Clear DokuWiki cache 3. Reload page 4. Events should now match eventlist background **Browser caching can make old CSS persist!** ### Visual Result **All backgrounds now matching**: ``` ┌────────────────────────────┐ │ Eventlist (#f5f5f5) │ ← Template color ├────────────────────────────┤ │ 📅 Event (#f5f5f5) │ ← Template color (was #ffffff) ├────────────────────────────┤ │ 📅 Event (#f5f5f5) │ ← Template color (was #ffffff) └────────────────────────────┘ Perfect match! ``` ### Why Everything Else Worked **Clock area, calendar cells, etc.** didn't have hardcoded CSS backgrounds: - They only had inline styles ✓ - Inline styles worked correctly ✓ - Only event items had the CSS override ✗ ### Important Notes **Clear caches**: - Browser cache (Ctrl+Shift+R or Cmd+Shift+R) - DokuWiki cache (Admin → Clear Cache) - Old CSS may be cached! **This was the culprit all along!** ## Version 5.2.2 (2026-02-09) - FIX CLOCK AREA BACKGROUND ### 🎨 Fixed: Clock Area Now Matches Event Cells - **Fixed:** `header_bg` now uses `__background_site__` (was `__background_alt__`) - **Result:** Clock/Today header matches event cell backgrounds! ### The Issue The clock area (Today header) was using a different background: **Before (v5.2.1)**: ```php 'header_bg' => __background_alt__, // Different color (gray #e8e8e8) 'cell_bg' => __background_site__, // Event cells (#f5f5f5) ``` **After (v5.2.2)**: ```php 'header_bg' => __background_site__, // Same as cells (#f5f5f5) ✓ 'cell_bg' => __background_site__, // Event cells (#f5f5f5) ✓ ``` ### What's the Clock Area? The clock/Today header in the sidebar: ``` ┌────────────────────────────┐ │ 3:45:23 PM │ ← Clock area (header_bg) │ 🌤️ --° | Sun, Feb 9, 2026 │ └────────────────────────────┘ ``` ### All Backgrounds Now Unified **Everything now uses __background_site__**: - Eventlist background ✓ - Calendar cells ✓ - Event items ✓ - Clock/Today header ✓ - Sidebar widget ✓ - All backgrounds match! ✓ ### Visual Result **Complete consistency**: ``` ┌────────────────────────────┐ │ 3:45:23 PM │ ← Same background │ 🌤️ --° | Sun, Feb 9, 2026 │ ├────────────────────────────┤ │ 📅 Meeting at 2pm │ ← Same background │ Description... │ ├────────────────────────────┤ │ 📅 Another event │ ← Same background │ More details... │ └────────────────────────────┘ All using __background_site__ (#f5f5f5) ``` **Perfect visual harmony!** 🎨 ## Version 5.2.1 (2026-02-09) - FIX: MATCH EVENTLIST BACKGROUND ### 🐛 Fixed: Calendar Cells Now Match Eventlist Background - **Fixed:** Changed `cell_bg` to use `__background_site__` (not `__background__`) - **Result:** Calendar cells now match the eventlist background perfectly! ### The Real Issue The eventlist was showing the CORRECT background color all along! **Eventlist was using**: - `bg` → `__background_site__` ✓ (This was correct!) **Calendar cells were using**: - `cell_bg` → `__background__` ✗ (This was wrong!) **They didn't match!** ### The Correct Fix **Now everything uses __background_site__**: ```php 'bg' => __background_site__, // Eventlist (was already correct) 'cell_bg' => __background_site__, // Cells (now fixed to match) ``` ### Why __background_site__? The eventlist sidebar and calendar are meant to match the **page/site background**, not the inner content area background: ``` Page Layout: ┌────────────────────────────────────┐ │ __background_site__ (page bg) │ ← This is where calendar lives │ │ │ ┌──────────────────────────────┐ │ │ │ __background__ (content bg) │ │ ← Wiki article content │ │ │ │ │ └──────────────────────────────┘ │ │ │ └────────────────────────────────────┘ ``` **Calendar should match the page background, not the content background!** ### Template Example Typical DokuWiki template: ```ini __background_site__ = "#f5f5f5" (Light gray - page background) __background__ = "#ffffff" (White - content area) ``` **Before (v5.2.0)**: - Eventlist: `#f5f5f5` (light gray) ✓ Correct - Calendar cells: `#ffffff` (white) ✗ Wrong - didn't match **After (v5.2.1)**: - Eventlist: `#f5f5f5` (light gray) ✓ Correct - Calendar cells: `#f5f5f5` (light gray) ✓ Correct - MATCHED! ### All Backgrounds Now Unified **Everything now uses __background_site__**: - Eventlist sidebar background ✓ - Main calendar background ✓ - Calendar day cells ✓ - Sidebar widget ✓ - Event items ✓ - Input fields ✓ - Buttons ✓ **All perfectly matched to the page background!** ### Why Version 5.2.0 Was Wrong I incorrectly assumed `__background__` was the right color because it's often white. But the eventlist was already correct using `__background_site__` to match the page, not the content area. **The eventlist knew what it was doing all along!** The cells just needed to catch up. ## Version 5.2.0 (2026-02-09) - UNIFIED WIKI THEME BACKGROUNDS **Note**: This version went the wrong direction. See v5.2.1 for the correct fix. ### 🎨 Fixed: All Backgrounds Now Use __background__ - **Fixed:** `bg` now uses `__background__` instead of `__background_site__` - **Fixed:** Eventlist, calendar cells, and sidebar all match now - **Result:** Completely unified background throughout! ### The Issue Different parts of the calendar were using different background sources: **Before (v5.1.9)**: ```php 'bg' => __background_site__ // Eventlist background (outer page) 'cell_bg' => __background__ // Cell backgrounds (content area) ``` **These are different colors!** - `__background_site__` = Outer page wrapper (often gray) - `__background__` = Main content area (often white) ### The Fix **After (v5.2.0)**: ```php 'bg' => __background__ // Eventlist background ✓ 'cell_bg' => __background__ // Cell backgrounds ✓ ``` **Both use the same source!** ### What Uses 'bg' The `bg` color is used for: - Eventlist sidebar background - Main calendar container - Sidebar widget background - Form backgrounds - Event dialogs ### What Uses 'cell_bg' The `cell_bg` color is used for: - Calendar day cells - Event item backgrounds - Input field backgrounds - Button backgrounds ### Why This Matters **Template color hierarchy**: ``` __background_site__ → Outer page/body (e.g., #f5f5f5 light gray) __background__ → Main content area (e.g., #ffffff white) __background_alt__ → Sections/headers __background_neu__ → Highlights ``` **We want all calendar backgrounds to match the main content area!** ### Visual Comparison **Before (v5.1.9)**: Mismatched backgrounds ``` ┌────────────────────────────────┐ │ Eventlist (gray #f5f5f5) │ ← __background_site__ └────────────────────────────────┘ ┌────────────────────────────────┐ │ Calendar │ │ ┌──┬──┬──┬──┬──┬──┬──┐ │ │ │ │ │ │ │ │ │ │ │ ← __background__ (white #fff) │ └──┴──┴──┴──┴──┴──┴──┘ │ └────────────────────────────────┘ Different colors - looks inconsistent ``` **After (v5.2.0)**: Unified backgrounds ``` ┌────────────────────────────────┐ │ Eventlist (white #fff) │ ← __background__ └────────────────────────────────┘ ┌────────────────────────────────┐ │ Calendar │ │ ┌──┬──┬──┬──┬──┬──┬──┐ │ │ │ │ │ │ │ │ │ │ │ ← __background__ (white #fff) │ └──┴──┴──┴──┴──┴──┴──┘ │ └────────────────────────────────┘ Same color - perfectly consistent! ``` ### Template Examples **Light Template**: ```ini __background_site__ = "#f5f5f5" (light gray) __background__ = "#ffffff" (white) ``` **Before**: Eventlist gray, cells white **After**: Eventlist white, cells white ✓ **Dark Template**: ```ini __background_site__ = "#1a1a1a" (very dark) __background__ = "#2d2d2d" (dark) ``` **Before**: Eventlist very dark, cells dark **After**: Eventlist dark, cells dark ✓ ### Benefits **Visual Consistency**: - All backgrounds match - Clean, unified appearance - Professional look **Correct Template Integration**: - Uses content area color (not page wrapper) - Matches wiki content area - Proper color hierarchy **Works Everywhere**: - Light templates ✓ - Dark templates ✓ - Custom templates ✓ ### All Backgrounds Unified **Now using __background__**: - Eventlist background ✓ - Calendar cells ✓ - Sidebar widget ✓ - Event items ✓ - Input fields ✓ - Buttons ✓ - Dialogs ✓ **Perfect harmony throughout!** 🎨 ## Version 5.1.9 (2026-02-09) - FIX WIKI THEME EVENT BACKGROUNDS ### 🐛 Fixed: Wiki Theme Event Backgrounds Not Showing - **Fixed:** Wiki theme fallback used CSS variables in inline styles (doesn't work!) - **Fixed:** Replaced CSS variables with actual hex colors - **Result:** Event backgrounds now show correctly with template colors! ### The Problem CSS variables like `var(--__background__, #fff)` don't work in inline `style=""` attributes! **Before (broken)**: ```php 'cell_bg' => 'var(--__background__, #fff)', // Doesn't work in inline styles! ``` **After (fixed)**: ```php 'cell_bg' => '#fff', // Actual hex color works! ``` ### What Was Affected **When style.ini read successfully**: - ✅ Worked fine (uses actual hex colors from file) **When style.ini fallback used**: - ❌ Events had no background - ❌ CSS variables don't work in inline styles - ❌ Looked broken ### The Fix **Wiki theme fallback now uses real colors**: ```php 'wiki' => [ 'bg' => '#f5f5f5', // Real hex (was: var(--__background_site__)) 'border' => '#ccc', // Real hex (was: var(--__border__)) 'cell_bg' => '#fff', // Real hex (was: var(--__background__)) 'cell_today_bg' => '#eee', // Real hex (was: var(--__background_neu__)) 'text_primary' => '#333', // Real hex (was: var(--__text__)) 'text_bright' => '#2b73b7', // Real hex (was: var(--__link__)) 'text_dim' => '#666', // Real hex (was: var(--__text_neu__)) 'grid_bg' => '#e8e8e8', // Real hex (was: var(--__background_alt__)) // ... all colors now use real hex values ] ``` ### Why CSS Variables Don't Work **CSS variables work**: ```css .some-class { background: var(--__background__, #fff); /* ✓ Works in CSS */ } ``` **CSS variables DON'T work**: ```html
``` ### How It Works Now **Priority system**: 1. **Try reading style.ini** → Use actual template hex colors ✓ 2. **If file not found** → Use fallback hex colors ✓ 3. **Never use CSS variables in inline styles** ✓ **Both paths now work correctly!** ### Visual Result **Events now have proper backgrounds**: ``` ┌──────────────────────────┐ │ 📅 Meeting at 2pm │ ← White background (#fff) │ Description here... │ │ [✏️ Edit] [🗑️ Delete] │ └──────────────────────────┘ Not: ┌──────────────────────────┐ │ 📅 Meeting at 2pm │ ← No background (broken) │ Description here... │ └──────────────────────────┘ ``` ### Affected Areas **All event displays**: - Main calendar events ✓ - Sidebar widget events ✓ - Event list items ✓ - Event backgrounds ✓ - Button backgrounds ✓ - Input field backgrounds ✓ **Everything uses real colors now!** ## Version 5.1.8 (2026-02-09) - IMPROVED UPDATE TAB LAYOUT ### 🎨 Reorganized: Better Update Tab Layout - **Moved:** Current Version section to the top - **Combined:** Upload and Important Notes side-by-side - **Improved:** Space-efficient two-column layout - **Result:** More information visible at once! ### New Layout Order **Version 5.1.8**: ``` 1. Current Version (at top - see what you have) 2. Upload + Important Notes (side-by-side) 3. Recent Changes (changelog) 4. Backups ``` ### Side-by-Side Design **Upload form (left 60%) + Important Notes (right 40%)**: ``` ┌──────────────────────────────────────────┐ │ 📋 Current Version │ │ Version: 5.1.8 │ │ ✅ Permissions: OK │ └──────────────────────────────────────────┘ ┌─────────────────────┬────────────────────┐ │ 📤 Upload New │ ⚠️ Important Notes │ │ [Choose File] │ • Replaces files │ │ ☑ Backup first │ • Config preserved │ │ [Upload] [Clear] │ • Events safe │ └─────────────────────┴────────────────────┘ ``` ### Benefits **Current Version First**: - See what you have immediately - Check permissions at a glance - Know if ready to update **Side-by-Side Layout**: - Upload form and warnings together - Read notes while choosing file - More efficient use of space - Less scrolling needed **Better Information Flow**: 1. See current version ✓ 2. Upload new version with notes visible ✓ 3. Review recent changes ✓ 4. Manage backups ✓ ### Visual Comparison **Before (v5.1.7)**: ``` Important Notes (full width) ↓ Upload Form (full width) ↓ Current Version ↓ Recent Changes ↓ Backups ``` **After (v5.1.8)**: ``` Current Version (full width) ↓ Upload (60%) | Notes (40%) ↓ Recent Changes ↓ Backups ``` **More compact, better organized!** ### Responsive Design **Wide screens**: - Upload and notes side-by-side - Full 1200px width utilized - Efficient space usage **Narrow screens**: - Sections stack gracefully - Flex layout adapts - Still fully functional ### Layout Details **Current Version Section**: - Full width (1200px max) - Shows version, author, description - Permission status with icons - Helpful fix commands if needed **Upload/Notes Section**: - Flexbox layout with gap - Upload: `flex:1` (grows) - Notes: `flex:0 0 350px` (fixed 350px) - Both have proper min-width **Recent Changes Section**: - Full width (1200px max) - Compact scrollable view - Color-coded change types - Last 10 versions shown **Backups Section**: - Full width (1200px max) - Manual backup button - Scrollable file list - All actions accessible ### Improved Max Widths All sections now use `max-width:1200px` (previously 900px): - Better use of wide screens - Still responsive on narrow screens - Consistent throughout tab ## Version 5.1.7 (2026-02-09) - FIX SYNTAX ERROR ### 🐛 Fixed: Extra Closing Brace - **Fixed:** ParseError on line 1936 (extra closing brace) - **Result:** Manual backup feature now works correctly! ### What Was Wrong Extra `}` after the backup section: **Before (broken)**: ```php echo '
'; } // ← Extra closing brace! echo ''; ``` **Why it broke**: Backticks (`) are special in PHP too! ### The Fix **Changed from template literals to concatenation**: **BEFORE (broken)**: ```javascript let nsOptions = ``; nsOptions += ``; console.log('Edit recurring:', namespace); ``` **AFTER (fixed)**: ```javascript let nsOptions = ""; nsOptions += ""; console.log("Edit recurring:", namespace); ``` **Changes**: - ✅ Backticks (`) → Double quotes (") - ✅ Template literals (${var}) → Concatenation (" + var + ") - ✅ Single quotes in console.log → Double quotes - ✅ Properly escaped quotes for PHP echo ### Technical Details **The Issue**: ```php // Inside PHP echo string: echo ''; ``` **The Solution**: ```php // Use regular string concatenation: echo ''; ``` **Quote Escaping**: ```javascript // Double quotes inside PHP single-quote string: '' ↑↑ Escaped for JavaScript ``` ### Result **Before**: Admin page crashed with parse error ✗ **After**: Admin page loads perfectly ✓ **No functionality changed - just syntax fix!** ## Version 4.6.3 (2026-02-07) - FIX RECURRING EVENTS NAMESPACE DROPDOWN ### 🐛 Critical Fix: Namespace Dropdown in Recurring Events Section - **Fixed:** Namespace dropdown now shows ALL available namespaces when editing - **Fixed:** Current namespace now properly selected in dropdown - **Fixed:** Namespace extraction from DOM now uses multiple methods - **Added:** Console logging to debug namespace detection ### The Problem **When editing from 🔄 Recurring Events section**: ``` Click "Edit" on recurring event Namespace dropdown shows: - (default) - (nothing else!) ✗ Can't select any namespace! ✗ ``` **Why**: Broken namespace extraction logic ```javascript // OLD CODE (broken): const namespaces = Array.from(document.querySelectorAll("[id^=ns_]")) .map(el => { // Complex parsing that often failed const nsSpan = el.querySelector("span:nth-child(3)"); return nsSpan.textContent.replace("📁 ", "").trim(); }) .filter(ns => ns !== namespace); // Excluded current! ✗ ``` **Result**: Empty dropdown, can't change namespace! ✗ ### The Fix **NEW CODE (robust)**: ```javascript const namespaces = new Set(); // Method 1: Namespace explorer folders document.querySelectorAll("[id^=ns_]").forEach(el => { const nsSpan = el.querySelector("span:nth-child(3)"); if (nsSpan) { let nsText = nsSpan.textContent.replace("📁 ", "").trim(); if (nsText && nsText !== "(default)") { namespaces.add(nsText); // ✓ } } }); // Method 2: Datalist (backup method) document.querySelectorAll("#namespaceList option").forEach(opt => { if (opt.value && opt.value !== "") { namespaces.add(opt.value); // ✓ } }); // Build dropdown with ALL namespaces let options = ``; // Show current namespace as selected if (namespace) { options += ``; } // Show all other namespaces for (const ns of nsArray) { if (ns !== namespace) { options += ``; } } ``` **Result**: All namespaces visible! ✓ ### How It Works Now **Before (Broken)**: ``` Edit recurring event in "work" namespace Dropdown shows: ☐ (default) That's it! Can't select anything! ✗ ``` **After (Fixed)**: ``` Edit recurring event in "work" namespace Dropdown shows: ☐ (default) ☑ work (current) ← Selected! ☐ personal ☐ projects ☐ meetings All namespaces available! ✓ ``` ### Key Improvements **1. Dual extraction methods**: - Primary: Parse namespace explorer DOM - Backup: Read from datalist - Result: Always finds namespaces ✓ **2. Current namespace included**: ```javascript // OLD: Excluded current namespace .filter(ns => ns !== namespace) ✗ // NEW: Include and mark as selected options += `` ✓ ``` **3. Better error handling**: ```javascript if (nsSpan) { // Check exists let nsText = nsSpan.textContent.replace("📁 ", "").trim(); if (nsText && nsText !== "(default)") { // Validate namespaces.add(nsText); } } ``` **4. Console debugging**: ```javascript console.log('Edit recurring - Current namespace:', namespace); console.log('Available namespaces:', nsArray); ``` Open browser console (F12) to see what namespaces are detected! ### Example Usage **Scenario**: Edit recurring "Team Meeting" in "work" namespace **Steps**: 1. Go to 🔄 Recurring Events section 2. Click "Edit" on "Team Meeting" 3. See namespace dropdown: - ☐ (default) - ☑ work (current) - ☐ personal - ☐ projects 4. Select "personal" to move event 5. Click "Save Changes" 6. Event moved to "personal" namespace ✓ **Finally works as expected!** 🎉 ## Version 4.6.2 (2026-02-07) - FIX NAMESPACE PRESERVATION ### 🐛 Recurring Events Namespace Fix - **Fixed:** Namespace now properly preserved when editing recurring events - **Fixed:** Namespace selector now allows selecting any namespace (not just default) - **Added:** Better logging for namespace preservation debugging - **Added:** Console logging to track namespace values during edit ### The Namespace Problem **Issue 1**: Can't select non-default namespace ``` When editing recurring event: - Dropdown shows all namespaces ✓ - User selects "work" - Form submits with "" (empty/default) ✗ ``` **Issue 2**: Namespace not preserved ``` Recurring event in "personal" namespace Edit the title only After save: namespace changed to "" (default) ✗ ``` ### The Fixes **Fix 1**: Better namespace preservation logic ```php // When editing recurring event: $existingNamespace = $existingEventData['namespace']; // Preserve if user didn't explicitly change it: if (empty($namespace) || strpos($namespace, '*') !== false || strpos($namespace, ';') !== false) { // User didn't select or selected wildcard $namespace = $existingNamespace; // Keep existing! } ``` **Fix 2**: Proper form population ```javascript // When editing, set BOTH inputs: namespaceHidden.value = event.namespace || ''; // Hidden (submitted) namespaceSearch.value = event.namespace || '(default)'; // Visible // Plus logging: console.log('Set namespace for editing:', event.namespace); ``` **Fix 3**: Added detailed logging ```php error_log("Preserving namespace '$namespace' (received='$receivedNamespace')"); error_log("Using new namespace '$namespace'"); error_log("No existing namespace to preserve"); ``` ### How It Works Now **Scenario 1**: Edit without changing namespace ``` Event in "work" namespace Edit title to "Updated Meeting" Namespace field shows: "work" Hidden input value: "work" Result: Saved in "work" ✓ ``` **Scenario 2**: Change namespace during edit ``` Event in "personal" namespace Edit and select "work" namespace Hidden input value: "work" Result: Saved in "work" ✓ ``` **Scenario 3**: Edit with empty/wildcard namespace ``` Event in "projects" namespace Namespace field empty or shows "personal;work" System preserves: "projects" Result: Saved in "projects" ✓ ``` ### Debugging Now with console logging, you can see: ```javascript Set namespace for editing: work Hidden value: work ``` And in PHP logs: ``` Calendar saveEvent recurring: Loaded existing data - namespace='work' Calendar saveEvent recurring: Preserving namespace 'work' (received='') ``` **Namespace preservation now works correctly!** 🎉 ## Version 4.6.1 (2026-02-07) - PRESERVE RECURRING EVENT DATA ### 🐛 Recurring Events Edit Fix - **Fixed:** Editing recurring events now preserves unchanged fields - **Fixed:** Empty fields no longer erase existing data - **Added:** Smart merge of existing event data with new changes ### The Problem **Before**: Editing erased unchanged fields! ``` Original recurring event: - Title: "Team Meeting" - Time: "10:00 AM" - Description: "Weekly standup with engineering team" - Color: Red User edits ONLY the title to "Staff Meeting" Form sends: - Title: "Staff Meeting" ✓ - Time: "" ✗ (empty because user didn't change it) - Description: "" ✗ (empty) - Color: "#3498db" ✗ (default blue) Result after save: - Title: "Staff Meeting" ✓ - Time: BLANK ✗ - Description: BLANK ✗ - Color: Blue ✗ ``` **All the other data was lost!** ✗ ### The Fix **After**: Preserves unchanged data! ```php if ($eventId && $isRecurring) { // Load existing event data $existingEventData = getExistingEventData($eventId); // Merge: use new value OR keep existing $title = $title ?: $existingEventData['title']; $time = $time ?: $existingEventData['time']; $description = $description ?: $existingEventData['description']; $color = ($color === '#3498db') ? $existingEventData['color'] : $color; } ``` **Now**: ``` User edits ONLY the title to "Staff Meeting" System: 1. Loads existing event data 2. Merges: new title + existing time/description/color 3. Saves merged data Result: - Title: "Staff Meeting" ✓ (changed) - Time: "10:00 AM" ✓ (preserved!) - Description: "Weekly standup..." ✓ (preserved!) - Color: Red ✓ (preserved!) ``` **Only changed fields are updated!** ✓ ### How It Works **Step 1**: Load existing data ```php $existingEventData = $this->getExistingEventData( $eventId, $date, $namespace ); ``` **Step 2**: Merge with new data ```php // If new value is empty, use existing value $title = $newTitle ?: $existingEventData['title']; $time = $newTime ?: $existingEventData['time']; $description = $newDesc ?: $existingEventData['description']; // Special handling for color (default is #3498db) if ($newColor === '#3498db' && $existingEventData['color']) { $color = $existingEventData['color']; } ``` **Step 3**: Save merged data ```php createRecurringEvents(..., $title, $time, $description, $color, ...); ``` ### Fields Preserved When editing recurring events, these fields are now preserved if not changed: - ✅ Title (if left blank) - ✅ Time (if not specified) - ✅ End Time (if not specified) - ✅ Description (if left empty) - ✅ Color (if still default blue) **Edit only what you want to change - everything else stays!** 🎉 ## Version 4.6.0 (2026-02-07) - NAMESPACE RENAME & RECURRING FIX ### ✨ New Feature: Rename Namespaces - **Added:** ✏️ Rename button in Namespace Explorer - **Added:** Rename all events in a namespace at once - **Added:** Automatic cleanup of old directory structure ### 🐛 Critical Fix: Recurring Events Actually Edit Now! - **Fixed:** Editing recurring events now deletes ALL instances - **Fixed:** Previously only deleted one instance, left orphans - **Fixed:** Recurring events properly regenerated on edit ### Namespace Rename Feature **Before**: Could only delete namespaces, not rename **After**: Click ✏️ to rename! ``` 📁 work (15 events) [3] [✏️] [🗑️] ↑ NEW! ``` **How It Works**: 1. Click ✏️ rename button 2. Enter new namespace name 3. All events moved to new namespace 4. Event `namespace` field updated in JSON 5. Old directory cleaned up **Example**: ``` Rename: "work" → "business" Before: /data/meta/work/calendar/*.json Events: {namespace: "work"} After: /data/meta/business/calendar/*.json Events: {namespace: "business"} ``` **Implementation**: ```php private function renameNamespace() { // 1. Validate new name // 2. Rename directory // 3. Update all event namespace fields in JSON // 4. Clean up old empty directories } ``` ### Recurring Events Fix - The Problem **Before**: Editing didn't work! ``` Original recurring event generates: - Event-0 (Mon, Feb 10) - Event-1 (Mon, Feb 17) - Event-2 (Mon, Feb 24) User edits Event-0, changes title to "Updated" What SHOULD happen: - Delete Event-0, Event-1, Event-2 - Generate new instances with "Updated" title What ACTUALLY happened: - Delete Event-0 only ✗ - Generate new instances - Result: Event-1 and Event-2 still show old title! ✗ ``` **After**: Properly deletes ALL instances! **The Fix**: ```php private function deleteEvent() { $event = getEvent($eventId); // Check if recurring if ($event['recurring'] && $event['recurringId']) { // Delete ALL instances with same recurringId deleteAllRecurringInstances($recurringId); } // Then normal delete for spanning events } private function deleteAllRecurringInstances($recurringId) { // Scan ALL calendar JSON files foreach (glob('*.json') as $file) { // Filter out events with matching recurringId $events = array_filter($events, function($event) { return $event['recurringId'] !== $recurringId; }); } } ``` **Result**: - Edit "Weekly Team Meeting" → ALL instances updated ✓ - Delete recurring event → ALL instances deleted ✓ - No more orphaned events! ✓ ### Recurring Event Fields Every recurring event has: ```json { "id": "abc123-0", "recurring": true, "recurringId": "abc123", ← Links all instances ... } ``` When editing/deleting, we find ALL events with same `recurringId` and remove them! **Finally, recurring events work properly!** 🎉 ## Version 4.5.2 (2026-02-07) - FIX SORTING & PINK TOOLTIPS ### 🐛 Important Events Sorting - ACTUALLY FIXED! - **Fixed:** Important Events now REALLY sorted by date first, then time - **Fixed:** renderSidebarSection was re-sorting and breaking the order - **Changed:** Important Events use date-first sorting, Today/Tomorrow use time-only ### 💖 Pink Theme Tooltip Bling! - **Added:** Pink gradient tooltips (hot pink → light pink) - **Added:** Glowing pink border on tooltips - **Added:** Sparkling heart (💖) appears next to tooltip! - **Added:** Heart has pink glow drop-shadow ### The Sorting Bug - Root Cause **Problem**: Two sorts were happening! **Sort #1** (Line 2047): Before rendering ```php usort($importantEvents, ...) // Sort by date ✓ ``` **Sort #2** (Line 2751): Inside renderSidebarSection ```php usort($events, ...) // Sort by TIME ONLY ✗ // This was breaking the date order! ``` **The Fix**: Different sorting for different sections ```php if ($title === 'Important Events') { // Sort by DATE first, then time usort($events, function($a, $b) { if ($dateA !== $dateB) { return strcmp($dateA, $dateB); // DATE first! } // Same date - sort by time return timeCompare($a, $b); }); } else { // Today/Tomorrow - sort by TIME only (same date) usort($events, function($a, $b) { return timeCompare($a, $b); }); } ``` **Result**: Important Events now CORRECTLY sorted! ``` ✓ Sun, Feb 8 - 3:30 PM Super Bowl ✓ Tue, Feb 10 - 11:30 AM Doctor visit ✓ Sat, Feb 14 - Valentine's Day (all-day) ✓ Sat, Feb 14 - 8:00 PM Crab Shack ``` ### Pink Tooltip Magic! 💖 **Normal Tooltips**: Black background, plain ```css background: rgba(0, 0, 0, 0.95); color: #fff; ``` **Pink Theme Tooltips**: FABULOUS! ```css /* Pink gradient background */ background: linear-gradient(135deg, #ff1493 0%, #ff69b4 100%); /* Glowing pink border */ border: 2px solid #ff85c1; /* Double glow shadow */ box-shadow: 0 0 15px rgba(255, 20, 147, 0.6), 0 4px 12px rgba(0, 0, 0, 0.4); /* Bold text */ font-weight: 600; ``` **Plus**: Sparkling heart next to tooltip! ```css .sidebar-pink [data-tooltip]:after { content: '💖'; font-size: 12px; filter: drop-shadow(0 0 3px rgba(255, 20, 147, 0.8)); } ``` **The Effect**: ``` Hover over ⚠ conflict warning: ┌────────────────────┐ 💖 │ Conflicts with: │ ← Pink gradient │ • Event 1 (3PM) │ ← Pink border │ • Event 2 (4PM) │ ← Pink glow └────────────────────┘ ``` **Maximum glamour on tooltips too!** ✨ ## Version 4.5.1 (2026-02-07) - FIX IMPORTANT EVENTS SORTING ### 🐛 Important Events Order Fixed - **Fixed:** Important Events now sorted by date (earliest first) - **Fixed:** Events on same date sorted by time (chronological) - **Fixed:** All-day events appear last within each date ### Sorting Issue **Before**: Random order ``` Important Events: 💖 Valentine's Day (Sat, Feb 14) 11:30 AM Doctor visit (Tue, Feb 10) ← Feb 10 after Feb 14! 3:30 PM Super Bowl (Sun, Feb 8) ← Feb 8 after Feb 14! 8:00 PM Crab Shack (Sat, Feb 14) ``` **After**: Chronological order ``` Important Events: 3:30 PM Super Bowl (Sun, Feb 8) ← Earliest! 11:30 AM Doctor visit (Tue, Feb 10) 💖 Valentine's Day (Sat, Feb 14) ← All-day event 8:00 PM Crab Shack (Sat, Feb 14) ← Same day, sorted by time ``` ### Sorting Logic **Primary Sort**: By date ```php strcmp($dateA, $dateB); // "2026-02-08" < "2026-02-14" ``` **Secondary Sort**: By time (within same date) ```php // All-day events (no time) go last if (empty($timeA) && !empty($timeB)) return 1; if (!empty($timeA) && empty($timeB)) return -1; // Both have times - sort chronologically $aMinutes = timeToMinutes($timeA); // "11:30" = 690 minutes $bMinutes = timeToMinutes($timeB); // "20:00" = 1200 minutes return $aMinutes - $bMinutes; // 690 < 1200 ``` **Result**: 1. Sun, Feb 8 - 3:30 PM (earliest date & time) 2. Tue, Feb 10 - 11:30 AM (next date) 3. Sat, Feb 14 - Valentine's Day (all-day, so last on Feb 14) 4. Sat, Feb 14 - 8:00 PM (timed event on Feb 14) **Perfect chronological order for next 2 weeks!** ✓ ## Version 4.5.0 (2026-02-07) - SPARKLE EDITION ✨💖 ### 💎 EXTREME PINK BLING EFFECTS! - **Added:** Click sparkles - 8 sparkles burst out on every click! - **Added:** Auto-sparkles - random sparkles appear every 3 seconds - **Added:** Hover mega-glow - sidebar glows BRIGHT on hover - **Added:** Pulsing border glow - constantly breathing pink glow - **Added:** Drop shadows on sparkles for extra depth - **Added:** More sparkle emojis - hearts, diamonds, crowns, bows! ### Sparkle Effects Breakdown **Click Sparkles** 💥: ```javascript // 8 sparkles burst out when you click anywhere! for (let i = 0; i < 8; i++) { // Staggered appearance (40ms apart) createSparkle(x, y); } // Sparkle emojis: ["✨", "💖", "💎", "⭐", "💕", "🌟", "💗", "💫", "🎀", "👑"] ``` **Each sparkle**: - Starts at click point - Flies outward 30-60px in random direction - Spins 360 degrees - Fades in and out - Has pink glow drop-shadow - Disappears after 1 second **Auto Sparkles** ⏰: ```javascript // Random sparkle every 3 seconds setInterval(() => { const x = Math.random() * width; const y = Math.random() * height; createSparkle(x, y); }, 3000); ``` **Result**: Constant magical sparkles even without clicking! ✨ **Hover Mega-Glow** 🌟: ```css .sidebar-pink:hover { box-shadow: 0 0 30px rgba(255, 20, 147, 0.9), 0 0 50px rgba(255, 20, 147, 0.5) !important; } ``` **Result**: Sidebar EXPLODES with pink glow when you hover over it! 💖 **Pulsing Border Glow** 💓: ```css @keyframes pulse-glow { 0%, 100% { box-shadow: 0 0 10px rgba(255, 20, 147, 0.4); } 50% { box-shadow: 0 0 25px rgba(255, 20, 147, 0.8), 0 0 40px rgba(255, 20, 147, 0.4); } } animation: pulse-glow 3s ease-in-out infinite; ``` **Result**: Border continuously breathes with pink glow! 💕 **Sparkle Animation** 🎭: ```css @keyframes sparkle { 0% { opacity: 0; transform: translate(0, 0) scale(0) rotate(0deg); } 50% { opacity: 1; transform: translate(halfway) scale(1) rotate(180deg); } 100% { opacity: 0; transform: translate(far) scale(0) rotate(360deg); } } ``` **Result**: Sparkles spin, grow, shrink, and fly! 🌟 ### Complete Pink Bling Experience: **Always Active**: - ✨ Pulsing pink border glow (3 second cycle) - ✨ Auto-sparkles every 3 seconds **On Hover**: - 💖 MEGA GLOW EFFECT (2x brightness!) **On Click**: - 💎 8 sparkles EXPLODE outward! - 🎀 Random emojis (hearts, stars, diamonds, crowns!) - 👑 Each sparkle spins 360° while flying - 💫 Pink glow drop-shadow on each sparkle **The Result**: - Click anywhere = SPARKLE EXPLOSION! 💥 - Hover anywhere = MEGA GLOW! ✨ - Always breathing and sparkling! 💖 - Maximum glamour! 👑 - Wife approval: 1000%! 💕 **THIS IS THE MOST FABULOUS CALENDAR EVER!** 💖✨💎 ## Version 4.4.2 (2026-02-07) - FINAL PINK POLISH ### 💖 Pink Theme Final Touches - **Fixed:** Add Event text now black (was bright pink, hard to read) - **Fixed:** Clock border now COMPLETELY pink on all sides (no more green!) - **Removed:** Text shadow on Add Event button (cleaner with black text) ### Add Event Text - Black & Readable! **Before**: Bright pink text (#ff1493) on dark pink background ```php $addBtnTextColor = $themeStyles['text_bright']; // #ff1493 - hard to read! text-shadow: 0 0 3px #ff1493; // Glowy pink ``` **After**: Black text, no shadow, perfect contrast! ```php $addBtnTextColor = $theme === 'pink' ? '#000000' : ...; $addBtnTextShadow = $theme === 'pink' ? 'none' : ...; ``` **Result**: - Black text pops against dark pink background ✓ - Easy to read ✓ - Professional look with bling ✓ ### Clock Border - All Pink! **The Problem**: Inline style only set `border-bottom`, CSS set other sides to green **Before**: ```php // Inline style (only bottom): style="border-bottom:2px solid #ff1493;" // CSS (all sides): .eventlist-today-header { border: 2px solid #00cc07; // Green on top/sides! } ``` **After**: Inline style overrides ALL sides ```php style="border:2px solid #ff1493;" // All 4 sides pink! ``` **Result**: Clock box now 100% pink border on all four sides! ✓ ### What Changed: **Add Event Button**: - Background: #b8156f (dark pink) ✓ - Text: **#000000 (black)** ← NEW! - Text shadow: **none** ← NEW! - Glow: 0 0 10px pink ✓ **Clock Border**: - Top: **#ff1493 (pink)** ← FIXED! - Right: **#ff1493 (pink)** ← FIXED! - Bottom: #ff1493 (pink) ✓ - Left: **#ff1493 (pink)** ← FIXED! **Perfect pink theme - wife approved!** 💖✨ ## Version 4.4.1 (2026-02-07) - PINK THEME PERFECTION ### 💖 Pink Theme Complete Makeover - **Fixed:** Clock border now completely pink (was green on sides/top) - **Changed:** Today/Tomorrow/Important sections now different shades of pink - **Changed:** Add Event button now dark pink (was clashing blue) - **Changed:** System status bars now pink gradient (3 shades!) ### All-Pink Everything! 💎 **Clock Border**: ```css /* Before: Green border */ border: 2px solid #00cc07; /* After: Hot pink border */ .sidebar-pink .eventlist-today-header { border-color: #ff1493; box-shadow: 0 0 10px rgba(255, 20, 147, 0.4); } ``` **Section Colors** (Different Pink Shades): ```php // Before: Orange, green, purple 'Today' => '#ff9800', 'Tomorrow' => '#4caf50', 'Important' => '#9b59b6' // After: Hot pink, pink, light pink 'Today' => '#ff1493', // Hot pink (DeepPink) 'Tomorrow' => '#ff69b4', // Pink (HotPink) 'Important' => '#ff85c1' // Light pink ``` **Add Event Button**: ```php // Before: Clashing blue background: #3498db; // After: Dark pink with glow background: #b8156f; // Dark pink hover: #8b0f54; // Darker pink shadow: 0 0 10px rgba(255, 20, 147, 0.5); ``` **System Status Bars** (Pink Gradient): ```css /* 5-min load average */ .sidebar-pink .eventlist-cpu-fill { background: #ff1493; /* Hot pink */ box-shadow: 0 0 5px rgba(255, 20, 147, 0.7); } /* Realtime CPU */ .sidebar-pink .eventlist-cpu-fill-purple { background: #ff69b4; /* Pink */ box-shadow: 0 0 5px rgba(255, 105, 180, 0.7); } /* Memory */ .sidebar-pink .eventlist-cpu-fill-orange { background: #ff85c1; /* Light pink */ box-shadow: 0 0 5px rgba(255, 133, 193, 0.7); } ``` ### Pink Theme Visual Hierarchy: **Darkest → Lightest Pink Shades**: 1. Add Event button: #b8156f (dark pink) 2. Today section: #ff1493 (hot pink / deep pink) 3. System bar 1: #ff1493 (hot pink) 4. Tomorrow section: #ff69b4 (pink) 5. System bar 2: #ff69b4 (pink) 6. Important section: #ff85c1 (light pink) 7. System bar 3: #ff85c1 (light pink) **Result**: Beautiful pink gradient throughout entire sidebar! 💖✨ ### What's Pink Now: ✅ Sidebar background & border ✅ **Clock border** ← FIXED! ✅ Header gradient ✅ Week grid ✅ **Add Event button** ← FIXED! ✅ **Today section** ← Different shade! ✅ **Tomorrow section** ← Different shade! ✅ **Important section** ← Different shade! ✅ Event text & bars ✅ **System status bars** ← All 3 different pink shades! ✅ All shadows & glows **EVERYTHING is pink and fabulous!** 💎✨ ## Version 4.4.0 (2026-02-07) - PINK BLING THEME & PROFESSIONAL SHADOWS ### ✨ New Theme: Pink Bling! 💎 - **Added:** Glamorous hot pink theme with maximum sparkle - **Features:** Deep pink (#ff1493), extra glow, hearts and diamonds aesthetic - **Perfect for:** Fabulous calendars that demand attention ✨ ### 🎨 Professional Theme Shadow Fix - **Fixed:** Section headers now have subtle shadow (not glow) - **Fixed:** Clicked day panel header has proper shadow ### Pink Bling Theme Colors **Background & Borders**: ```php 'bg' => '#1a0d14', // Dark rich pink-black 'border' => '#ff1493', // Hot pink (DeepPink) 'shadow' => 'rgba(255, 20, 147, 0.4)', // Strong pink glow ``` **Text Colors**: ```php 'text_primary' => '#ff69b4', // Hot pink 'text_bright' => '#ff1493', // Deep pink 'text_dim' => '#ff85c1', // Light pink ``` **Week Grid**: ```php 'grid_bg' => '#2d1a24', // Dark purple-pink 'cell_bg' => '#1a0d14', // Dark 'cell_today_bg' => '#3d2030', // Highlighted purple-pink ``` **Special Effects**: ```php 'bar_glow' => '0 0 5px', // Extra sparkly glow! 'header_shadow' => '0 0 12px rgba(255, 20, 147, 0.6)' // Maximum bling! ``` ### Professional Theme Shadow Fix **Before**: Section headers had colored glow ```php box-shadow: 0 0 8px #3498db; // Blue glow - wrong! ``` **After**: Section headers have subtle shadow ```php $headerShadow = ($theme === 'professional') ? '0 2px 4px rgba(0, 0, 0, 0.15)' : // Shadow for professional '0 0 8px ' . $accentColor; // Glow for others ``` **Result**: - **Matrix/Purple/Pink**: Colored glow on headers ✓ - **Professional**: Clean grey shadow (no glow) ✓ ### All Four Themes: **🟢 Matrix Edition**: - Dark green (#00cc07) - Neon glow effects - Hacker aesthetic **🟣 Purple Dream**: - Elegant purple (#9b59b6) - Violet glow effects - Royal aesthetic **🔵 Professional Blue**: - Clean grey/blue (#4a90e2) - Subtle shadows (NO glow) - Corporate aesthetic **💖 Pink Bling** (NEW!): - Hot pink (#ff1493) - MAXIMUM sparkle & glow - Glamorous aesthetic ✨💎 ### Technical Implementation **Theme Added To**: - `getSidebarThemeStyles()` - color definitions - `getSidebarTheme()` - validation - `saveSidebarTheme()` - admin save - Admin panel - UI with preview - All shadow/glow calculations - JavaScript theme colors - Clicked day panel colors **Perfect for users who want FABULOUS pink calendars!** 💖✨ ## Version 4.3.1 (2026-02-07) - REDUCE TEXT GLOW & CONSISTENCY ### 🎨 Text Glow Refinement - **Changed:** Reduced text glow from 3px to 2px (less intense) - **Fixed:** Clicked day panel now has same text glow as sections ### Text Glow Reduction **Before**: Text glow was too strong (3px) ```php // Sections: text-shadow: 0 0 3px #00cc07; // Too bright! // Clicked day panel: text-shadow: 0 0 3px #00cc07; // Too bright! ``` **After**: Subtler text glow (2px) ```php // Sections: text-shadow: 0 0 2px #00cc07; // Just right ✓ // Clicked day panel: text-shadow: 0 0 2px #00cc07; // Just right ✓ ``` **Visual Impact**: - **Matrix**: Softer green glow, easier to read - **Purple**: Softer purple glow, more elegant - **Professional**: Still no glow (clean) ### Consistency Fix **Before**: Sections had glow, clicked day panel had NO glow **After**: Both sections AND clicked day panel have matching subtle glow **Where Glow Appears**: - ✅ Today section event text - ✅ Tomorrow section event text - ✅ Important section event text - ✅ **Clicked day panel event text** ← NOW CONSISTENT! **Result**: - Glow is less intense and easier on eyes ✓ - All event text has consistent styling ✓ - Matrix/Purple themes more refined ✓ ### Technical Details **PHP (Sections)**: ```php $textShadow = ($theme === 'professional') ? '' : 'text-shadow:0 0 2px ' . $titleColor . ';'; ``` **JavaScript (Clicked Day Panel)**: ```javascript themeColors.text_shadow = 'text-shadow:0 0 2px #00cc07'; // Or purple eventHTML += "style='...color:" + color + "; " + themeColors.text_shadow + ";'"; ``` **Perfect consistency and subtle elegance!** ✨ ## Version 4.3.0 (2026-02-07) - IMPORTANT EVENTS FUTURE + REMOVE GREY ### ✨ Important Events Enhancement - **Changed:** Important events now show from next 2 weeks (not just current week) - **Fixed:** Important events on Sunday after current week now visible - **Changed:** Events loaded 2 weeks into future for Important section ### 🎨 Background Cleanup - **Removed:** Grey/white backgrounds from Today/Tomorrow/Important sections - **Removed:** Grey backgrounds from individual events - **Result:** Clean transparent backgrounds, original dark Matrix look restored ### Important Events - Future Coverage **Before**: Only showed Important events from current week ```php if ($isImportant && $dateKey >= $weekStart && $dateKey <= $weekEnd) { $importantEvents[] = $event; } ``` **After**: Shows Important events from today through next 2 weeks ```php // Load events 2 weeks out $twoWeeksOut = date('Y-m-d', strtotime($weekEnd . ' +14 days')); // Show all important events from today forward if ($isImportant && $dateKey >= $todayStr) { $importantEvents[] = $event; } ``` **Example**: - Today: Saturday Feb 7 - Current week: Sun Feb 1 → Sat Feb 7 - Important events shown: Feb 7 → Feb 21 (today + 14 days) **Result**: Important events on Sunday Feb 8 (next week) now visible! ✓ ### Background Removal **Before**: Light grey/white backgrounds added ```php // Section background: $sectionBg = 'rgba(255, 255, 255, 0.05)'; // Grey overlay // Event background: $eventBg = 'rgba(255, 255, 255, 0.03)'; // Grey overlay ``` **After**: No backgrounds (transparent) ```php // Section: No background property
// Event: No background property
``` **Result**: - Clean, dark Matrix aesthetic restored ✓ - Purple theme darker and more elegant ✓ - Professional theme still has its light grey sidebar bg ✓ - Events stand out with just color bars and borders ✓ ### What Changed: **Sections (Today/Tomorrow/Important)**: - ❌ No more grey overlay - ✓ Transparent background - ✓ Colored borders & glows remain **Individual Events**: - ❌ No more grey overlay - ✓ Transparent background - ✓ Colored bars & borders remain **Perfect! Back to the original clean dark look with future Important events!** 🌙 ## Version 4.2.6 (2026-02-07) - FIX SECTION SHADOWS & DESCRIPTION COLOR ### 🎨 Final Theme Polish - **Fixed:** Today/Tomorrow/Important section shadows now match theme - **Fixed:** Event description text color now uses theme dim color ### Section Shadow Fix **Problem**: Sections always had green glow regardless of theme **Before**: ```php // Hardcoded green: box-shadow: 0 0 5px rgba(0, 204, 7, 0.2); ``` **After**: ```php // Theme-aware: $sectionShadow = $theme === 'matrix' ? '0 0 5px rgba(0, 204, 7, 0.2)' : ($theme === 'purple' ? '0 0 5px rgba(155, 89, 182, 0.2)' : '0 2px 4px rgba(0, 0, 0, 0.1)'); ``` **Result**: - **Matrix**: Green glow around sections ✓ - **Purple**: Purple glow around sections ✓ - **Professional**: Subtle grey shadow (no glow) ✓ ### Description Color Fix **Problem**: Description text always green in clicked day panel **Before**: ```javascript color: #00aa00; // Always green ``` **After**: ```javascript color: themeColors.text_dim; // Theme dim color ``` **Result**: - **Matrix**: Dim green (#00aa00) ✓ - **Purple**: Dim purple (#8e7ab8) ✓ - **Professional**: Grey (#7f8c8d) ✓ ### Now 100% Theme Consistent Every single visual element respects theme: - ✅ Sidebar background & border - ✅ Header colors & shadows - ✅ Week grid & cells - ✅ Add Event button - ✅ Section borders & **shadows** ← Fixed! - ✅ Event titles & times - ✅ Event **descriptions** ← Fixed! - ✅ Clicked day panel - ✅ Event bars & glows **Absolute perfection across all three themes!** 🎨✨ ## Version 4.2.5 (2026-02-07) - CLICKED DAY PANEL THEMES & GREY BACKGROUND ### 🎨 Theme Improvements - **Fixed:** Clicked day panel now uses correct theme colors - **Changed:** Professional Blue background now light grey (not white) - **Added:** Theme colors passed to JavaScript for dynamic rendering ### Clicked Day Panel Theming **Before**: Always blue regardless of theme ```javascript // Hardcoded blue: color:#00cc07; // Always green background:#3498db; // Always blue ``` **After**: Theme-aware colors ```php // PHP passes theme to JavaScript: window.themeColors_XXX = { text_primary: '#00cc07' or '#b19cd9' or '#2c3e50', text_bright: '#00dd00' or '#d4a5ff' or '#4a90e2', text_shadow: '0 0 3px ...' or '', event_bg: 'rgba(...)', border_color: 'rgba(...)', bar_shadow: '0 0 3px' or '0 1px 2px rgba(...)' }; // JavaScript uses theme colors: color: themeColors.text_primary; background: themeColors.event_bg; ``` **Result**: - Matrix: Green panel with green glow ✓ - Purple: Purple panel with purple glow ✓ - Professional: Blue panel, no glow, clean ✓ ### Professional Theme Background Change **Before**: Almost white (#f5f7fa, #ffffff) ```php 'bg' => '#f5f7fa', // Very light 'cell_bg' => '#ffffff', // Pure white ``` **After**: Light grey tones ```php 'bg' => '#e8ecf1', // Soft grey-blue 'cell_bg' => '#f5f7fa', // Light grey 'grid_bg' => '#d5dbe3', // Medium grey 'cell_today_bg' => '#dce8f7' // Highlighted grey-blue ``` **Visual Impact**: - Sidebar: Light grey-blue background (#e8ecf1) - Week cells: Lighter grey (#f5f7fa) - Today cell: Highlighted blue-grey (#dce8f7) - More depth and contrast ✓ - Professional appearance ✓ ### All Theme Elements Now Consistent **Matrix (Green)**: - Sidebar: Dark (#242424) - Clicked panel: Dark with green - Text: Green with glow **Purple Dream**: - Sidebar: Dark purple (#2a2030) - Clicked panel: Dark with purple - Text: Purple with glow **Professional Blue**: - Sidebar: Light grey (#e8ecf1) - Clicked panel: Light with blue - Text: Dark grey, no glow **Perfect theme consistency everywhere!** 🎨 ## Version 4.2.4 (2026-02-07) - FIX TOMORROW LOADING & DOUBLE ENCODING ### 🐛 Critical Fixes - **Fixed:** Tomorrow events not loaded when outside current week - **Fixed:** `&` showing instead of `&` (double HTML encoding) ### Issue 1: Tomorrow Not Loading **Problem**: Sidebar only loaded events for current week - Today (Saturday): Week ends today - Tomorrow (Sunday): Start of NEXT week - Tomorrow events never loaded from data files! **Before**: ```php // Only load current week $end = new DateTime($weekEnd); $end->modify('+1 day'); $period = new DatePeriod($start, $interval, $end); // If tomorrow > weekEnd, it's not in period! ``` **After**: ```php // Check if tomorrow is outside week $tomorrowDate = date('Y-m-d', strtotime('+1 day')); if ($tomorrowDate > $weekEnd) { // Extend to include tomorrow $end = new DateTime($tomorrowDate); } $end->modify('+1 day'); $period = new DatePeriod($start, $interval, $end); ``` **Result**: Tomorrow events now loaded even at week boundary! ✓ ### Issue 2: Double HTML Encoding **Problem**: `&` characters showing as `&` **Cause**: Double encoding on line 2625 and 2681 ```php // Line 2625: $title = htmlspecialchars($event['title']); // "Coffee & Tea" → "Coffee & Tea" // Line 2681: $html .= htmlspecialchars($title); // "Coffee & Tea" → "Coffee &amp; Tea" ❌ ``` **Fixed**: ```php // Line 2625: $title = htmlspecialchars($event['title']); // Encode once // Line 2681: $html .= $title; // Use already-encoded value ✓ ``` **Result**: `&` displays correctly! ✓ ### Both Fixes Critical These were **two separate bugs**: 1. **Loading bug**: Tomorrow events not read from files 2. **Display bug**: Double-encoding text Both needed fixing for Tomorrow section to work properly! ## Version 4.2.3 (2026-02-07) - FIX TOMORROW SECTION AT WEEK BOUNDARY ### 🐛 Critical Fix - **Fixed:** Tomorrow section missing when tomorrow is outside current week - **Fixed:** Today section now always shows regardless of week boundaries - **Changed:** Today/Tomorrow processed BEFORE week boundary checks ### The Problem **Scenario**: Today is Saturday (last day of week) - Week: Feb 1 (Sun) → Feb 7 (Sat) ← Today - Tomorrow: Feb 8 (Sun) ← **Start of NEXT week** **BROKEN Logic** (v4.2.2): ```php foreach ($events as $dateKey => $dayEvents) { if ($dateKey < $weekStart) continue; // Skip old events // ...week processing... if ($dateKey === $tomorrowStr) { // ← Never reached! $tomorrowEvents[] = $event; // Tomorrow > weekEnd } } ``` **Result**: Tomorrow events never added because loop skipped them! ❌ ### The Fix **Process Today/Tomorrow FIRST**: ```php foreach ($events as $dateKey => $dayEvents) { $eventsWithConflicts = $this->detectTimeConflicts($dayEvents); foreach ($eventsWithConflicts as $event) { // ALWAYS process Today and Tomorrow first! if ($dateKey === $todayStr) { $todayEvents[] = $event; // ✓ Always shows } if ($dateKey === $tomorrowStr) { $tomorrowEvents[] = $event; // ✓ Always shows } // THEN check week boundaries for grid if ($dateKey >= $weekStart && $dateKey <= $weekEnd) { $weekEvents[$dateKey][] = $event; } // Important events still week-only if ($isImportant && $dateKey >= $weekStart && $dateKey <= $weekEnd) { $importantEvents[] = $event; } } } ``` ### What Changed **Before**: 1. Skip events < weekStart ❌ 2. Process week grid 3. Try to add Today/Tomorrow ← **Failed if outside week** 4. Add Important events **After**: 1. **Always add Today events** ✓ 2. **Always add Tomorrow events** ✓ 3. Add to week grid if in range 4. Add Important events if in range **Result**: - Today section: ✓ Always shows - Tomorrow section: ✓ Always shows (even at week boundary!) - Week grid: ✓ Only current week - Important: ✓ Only current week ### Edge Cases Fixed **Saturday → Sunday transition**: - Today (Sat): Shows in Today section ✓ - Tomorrow (Sun): Shows in Tomorrow section ✓ - Week grid: Only shows Sat (today) ✓ **Sunday → Monday transition**: - Today (Sun): Shows in Today section ✓ - Tomorrow (Mon): Shows in Tomorrow section ✓ - Week grid: Shows both Sun and Mon ✓ **Perfect! Tomorrow section now always works!** 📅 ## Version 4.2.2 (2026-02-07) - SUNDAY NOT SATURDAY! ### 🔄 Corrected Week Options - **Changed:** Week start options are now Monday vs **Sunday** (not Saturday!) - **Changed:** Default is **Sunday** (US/Canada standard) - **Fixed:** Day names array for Sunday start: S M T W T F S ### 📅 Correct Week Start Options **Sunday Start** (Default): - Grid shows: **S M T W T F S** - Week: Sunday → Saturday - US/Canada standard - Most common worldwide **Monday Start**: - Grid shows: **M T W T F S S** - Week: Monday → Sunday - ISO 8601 standard - Common in Europe ### Technical Changes **All References Updated**: ```php // Changed from 'saturday' to 'sunday' in: - Admin validation - Week calculation logic - Day names array - Default value - Comments ``` **Sunday Calculation** (when today is Saturday): ```php $today = date('w'); // 0=Sun, 6=Sat if ($today == 0) { $weekStart = date('Y-m-d'); // Today! } else { // Go back $today days to last Sunday $weekStart = date('Y-m-d', strtotime('-' . $today . ' days')); } ``` **Examples**: - Today (Saturday): Week = Sun Feb 1 → Sat Feb 7 - Tomorrow (Sunday): Week = Sun Feb 8 → Sat Feb 14 **Sorry for the confusion - it's Sunday not Saturday!** 🌅 ## Version 4.2.1 (2026-02-07) - FIX WEEK CALCULATION ON SATURDAY ### 🐛 Critical Fix - **Fixed:** Week calculation broken when today is Saturday - **Fixed:** Events not showing in Today/Important sections - **Fixed:** Week grid event bars missing - **Changed:** Default week start is Saturday (matches main calendar) ### Technical Details **The Bug**: ```php // BROKEN (v4.2.0): $weekStart = date('Y-m-d', strtotime('saturday this week')); // When TODAY is Saturday, this is ambiguous and fails! // FIXED (v4.2.1): $today = date('w'); // 0 (Sun) to 6 (Sat) if ($today == 6) { $weekStart = date('Y-m-d'); // Today! } else { $daysBack = ($today == 0) ? 1 : ($today + 1); $weekStart = date('Y-m-d', strtotime('-' . $daysBack . ' days')); } $weekEnd = date('Y-m-d', strtotime($weekStart . ' +6 days')); ``` **Why It Failed**: - `strtotime('saturday this week')` is ambiguous when run ON a Saturday - PHP may interpret it as "next Saturday" or fail - Result: Week range was wrong, events filtered out **The Fix**: - Explicit calculation using day-of-week math - Saturday (day 6): weekStart = today - Sunday (day 0): weekStart = yesterday - Monday-Friday: calculate days back to last Saturday **Result**: Works reliably every day of the week! **Default Changed**: Saturday start (was Monday in 4.2.0) - Matches main calendar behavior - Users can still switch to Monday in settings ## Version 4.2.0 (2026-02-07) - WEEK START DAY SELECTOR ### ✨ New Feature - **Added:** Week start day selector in Themes tab - **Added:** Choose between Monday (ISO standard) or Saturday week start - **Added:** Week grid and all events now respect the selected start day - **Changed:** Themes tab renamed to "Sidebar Widget Settings" ### 📅 Week Start Options **Monday Start** (Default): - Grid shows: M T W T F S S - Week runs: Monday → Sunday - ISO 8601 standard - Common in Europe, most of world **Saturday Start**: - Grid shows: S S M T W T F - Week runs: Saturday → Friday - Common in Middle East - Sabbath-observant communities ### Technical Details **Configuration**: ```php // Saved in: data/meta/calendar_week_start.txt // Values: 'monday' or 'saturday' // Week calculation: if ($weekStartDay === 'saturday') { $weekStart = date('Y-m-d', strtotime('saturday this week')); $weekEnd = date('Y-m-d', strtotime('friday next week')); } else { $weekStart = date('Y-m-d', strtotime('monday this week')); $weekEnd = date('Y-m-d', strtotime('sunday this week')); } ``` **Day Names Array**: ```php // Monday start: ['M', 'T', 'W', 'T', 'F', 'S', 'S'] // Saturday start: ['S', 'S', 'M', 'T', 'W', 'T', 'F'] ``` **What Changes**: - Week grid day letters - Week grid date sequence - Today/Tomorrow/Important event date ranges - Week event grouping **What Stays Same**: - All themes still work - Event data unchanged - Main calendar unaffected ### How to Change: 1. Admin → Calendar → 🎨 Themes tab 2. Under "Week Start Day" section 3. Select Monday or Saturday 4. Click "Save Settings" 5. Refresh sidebar to see changes **Perfect for international users or religious observances!** 📅 ## Version 4.1.4 (2026-02-07) - WEEK STARTS SUNDAY & LIGHTER BACKGROUNDS ### 🗓️ Calendar Improvements - **Changed:** Week grid now starts on Sunday and ends on Saturday (matches main calendar) - **Changed:** Event section backgrounds much lighter (almost white) - **Changed:** Individual event backgrounds lighter and more readable - **Changed:** Event borders now theme-colored ### Technical Details **Week Start Change**: ```php // Before: $weekStart = date('Y-m-d', strtotime('monday this week')); $weekEnd = date('Y-m-d', strtotime('sunday this week')); $dayNames = ['M', 'T', 'W', 'T', 'F', 'S', 'S']; // After: $weekStart = date('Y-m-d', strtotime('sunday this week')); $weekEnd = date('Y-m-d', strtotime('saturday this week')); $dayNames = ['S', 'M', 'T', 'W', 'T', 'F', 'S']; ``` **Background Colors**: ```php // Section backgrounds (Today, Tomorrow, Important): Matrix: rgba(255, 255, 255, 0.05) // Very light overlay Purple: rgba(255, 255, 255, 0.08) // Slightly lighter Professional: rgba(255, 255, 255, 0.95) // Almost white! // Individual event backgrounds: Matrix: rgba(255, 255, 255, 0.03) // Subtle Purple: rgba(255, 255, 255, 0.05) // Light Professional: rgba(255, 255, 255, 0.5) // Semi-transparent white ``` **Event Borders**: ```php Matrix: rgba(0, 204, 7, 0.2) // Green Purple: rgba(155, 89, 182, 0.2) // Purple Professional: rgba(74, 144, 226, 0.2) // Blue ``` ### Visual Result: **Before**: Dark backgrounds made text hard to read **After**: Light backgrounds make events pop and text very readable **Week Grid**: ``` Before: [M][T][W][T][F][S][S] After: [S][M][T][W][T][F][S] ← Now matches main calendar! ``` ## Version 4.1.3 (2026-02-07) - EVENT TEXT THEME COLORS ### 🎨 Final Theme Polish - **Fixed:** Event titles in Today/Tomorrow/Important sections now use theme colors - **Fixed:** Event times now use theme bright color - **Fixed:** Event dates use theme dim color - **Fixed:** Task checkboxes use theme bright color - **Fixed:** Event color bars use theme-appropriate shadows - **Fixed:** No text shadows on Professional theme ### Technical Details **Event Text Colors**: ```php // Matrix: - Title: #00cc07 (green) - Time: #00dd00 (bright green) - Date: #00aa00 (dim green) - Text shadow: 0 0 3px (glow) // Purple: - Title: #b19cd9 (lavender) - Time: #d4a5ff (bright purple) - Date: #8e7ab8 (dim purple) - Text shadow: 0 0 3px (glow) // Professional: - Title: #2c3e50 (dark grey) - Time: #4a90e2 (blue) - Date: #7f8c8d (grey) - Text shadow: none (clean) ``` **Color Bar Shadows**: ```php // Matrix & Purple: Glow effect box-shadow: 0 0 3px [event-color]; // Professional: Subtle shadow box-shadow: 0 1px 2px rgba(0,0,0,0.2); ``` ### What's Now Fully Themed: ✅ Sidebar background & border ✅ Header (clock box) background, border, text ✅ Week grid background, borders, cells ✅ Week grid day letters & numbers ✅ Week grid event bars & "+N more" text ✅ Add Event button background & text ✅ Today/Tomorrow/Important event titles ✅ Event times ✅ Event dates (Important section) ✅ Task checkboxes ✅ Event color bars ✅ All text shadows (glow vs none) **Every single element now respects the theme!** 🎨 ## Version 4.1.2 (2026-02-07) - COMPLETE THEME INTEGRATION ### 🎨 Theme Improvements - **Fixed:** Week calendar grid now uses theme colors (purple/blue) - **Fixed:** Add Event button now uses theme colors - **Fixed:** Clock box border now matches theme - **Fixed:** All text shadows respect theme (no glow on professional) - **Fixed:** Event bars use theme-appropriate shadows ### Technical Details **Week Grid Theming**: ```php // Matrix: Dark green (#1a3d1a) background, green (#00cc07) borders // Purple: Dark purple (#3d2b4d) background, purple (#9b59b6) borders // Professional: Light grey (#e8ecf1) background, blue (#4a90e2) borders ``` **Add Event Button**: ```php // Matrix: Dark green (#006400) with bright green text // Purple: Purple (#7d3c98) with lavender text // Professional: Blue (#3498db) with white text ``` **Text Shadows**: ```php // Matrix & Purple: Glow effects (text-shadow: 0 0 6px color) // Professional: No glow (clean look) ``` **CSS Overrides**: ```css /* Purple theme */ .sidebar-purple .eventlist-today-header { border-color: #9b59b6; box-shadow: 0 0 8px rgba(155, 89, 182, 0.2); } /* Professional theme */ .sidebar-professional .eventlist-today-header { border-color: #4a90e2; box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); } ``` ### What Changed Per Theme: **Purple Dream**: - Week grid: Purple borders and dark purple background - Add Event: Purple button with lavender text - Clock box: Purple border with purple glow - Event bars: Purple glow instead of green - All text: Purple/lavender shades **Professional Blue**: - Week grid: Blue borders and light grey background - Add Event: Blue button with white text - Clock box: Blue border with subtle shadow (no glow) - Event bars: Subtle shadows (no glow) - All text: Dark grey and blue shades **Matrix Edition**: Unchanged (still perfect green theme!) ## Version 4.1.1 (2026-02-07) - THEMES TAB & TOOLTIP LEFT POSITIONING ### ✨ New Features - **Added:** 🎨 Themes tab in admin for sidebar widget theming - **Added:** Three visual themes: Matrix (green), Purple Dream (purple), Professional Blue (blue/grey) - **Added:** Theme selector with live previews - **Added:** Theme persistence across page loads ### 🎨 Available Themes **Matrix Edition** (Default): - Dark background (#242424) - Green accents (#00cc07) - Neon glow effects - Original Matrix styling **Purple Dream**: - Dark purple background (#2a2030) - Purple/violet accents (#9b59b6) - Elegant purple glow - Rich purple color scheme **Professional Blue**: - Light grey background (#f5f7fa) - Blue accents (#4a90e2) - Clean professional look - Subtle shadows instead of glow ### 🐛 Bug Fix - **Fixed:** Tooltips now go UP and to the LEFT (was going right) - **Changed:** Tooltip offset from `rect.right` to `rect.left - 150px` ### Technical Details **Theme System**: ```php // Saved in: data/meta/calendar_theme.txt // Applied dynamically in syntax.php $theme = $this->getSidebarTheme(); // 'matrix', 'purple', or 'professional' $styles = $this->getSidebarThemeStyles($theme); // Styles include: - bg, border, shadow - header_bg, header_border, header_shadow - text_primary, text_bright, text_dim - grid_bg, grid_border - cell_bg, cell_today_bg ``` **Theme Changes**: - Header background gradient - Border colors - Text colors - Shadow/glow effects - Grid colors **How to Change**: 1. Admin → Calendar → 🎨 Themes tab 2. Select desired theme 3. Click "Save Theme" 4. Refresh page to see changes ### Notes - Themes only affect sidebar widget appearance - Main calendar view unchanged - Theme setting stored in `data/meta/calendar_theme.txt` - Safe to switch themes - no data affected ## Version 4.1.0 (2026-02-07) - FIX EVENT SORTING & TOOLTIP POSITIONING ### 🐛 Bug Fixes - **Fixed:** Events now sort chronologically by time (was using string comparison) - **Fixed:** Tooltip positioning using JavaScript like system tooltips - **Fixed:** All-day events appear first, then events in time order ### Technical Details **Event Sorting Fix**: ```php // BROKEN (v4.0.9): return strcmp($aTime, $bTime); // String comparison: "10:00" < "8:00" because "1" < "8" // Result: 10:00 AM shown BEFORE 8:00 AM ❌ // FIXED (v4.1.0): $aMinutes = $this->timeToMinutes($aTime); // 8:00 = 480 $bMinutes = $this->timeToMinutes($bTime); // 10:00 = 600 return $aMinutes - $bMinutes; // Result: 8:00 AM shown BEFORE 10:00 AM ✓ ``` **Example Before Fix**: ``` 🔖 Weekend Ticket Duty (all-day) 8:00 AM START TICKETS 10:00 AM Soul Winning ← Wrong! 9:45 AM Coffee ← Should be before 10:00 AM ``` **Example After Fix**: ``` 🔖 Weekend Ticket Duty (all-day) 8:00 AM START TICKETS 9:45 AM Coffee ← Correct! 10:00 AM Soul Winning ``` **Tooltip Positioning**: - Added JavaScript to dynamically position tooltips using `getBoundingClientRect()` - Uses CSS custom properties `--tooltip-left` and `--tooltip-top` - Positioned on `mouseenter` event - Matches system tooltip implementation (no cutoff) **JavaScript Implementation**: ```javascript element.addEventListener("mouseenter", function() { const rect = element.getBoundingClientRect(); element.style.setProperty("--tooltip-left", (rect.right - 10) + "px"); element.style.setProperty("--tooltip-top", (rect.top - 30) + "px"); }); ``` **Result**: Tooltips now extend beyond sidebar without cutoff, positioned dynamically! ## Version 4.0.9 (2026-02-07) - COMPACT TOOLTIPS & OVERFLOW FIX ### 🎨 UI Improvements - **Fixed:** Sidebar tooltips no longer cut off at sidebar edge - **Fixed:** Changed inline `overflow:hidden` to `overflow:visible` in sidebar - **Changed:** Main calendar conflict tooltip now much smaller (was too big) ### Technical Details **Sidebar Overflow Fix**: ```php // Before (line 2005): style="...overflow:hidden..." // ← Blocked tooltips! // After: style="...overflow:visible..." // ← Tooltips extend beyond! ``` **The Problem**: Inline `overflow:hidden` overrode CSS `overflow:visible !important` **Main Calendar Tooltip Size**: ```css /* Before: */ .conflict-tooltip { border: 2px solid #ff9800; border-radius: 6px; padding: 8px 12px; font-size: 12px; min-width: 200px; max-width: 350px; } /* After: */ .conflict-tooltip { border: 1px solid #ff9800; /* Thinner */ border-radius: 3px; /* Smaller */ padding: 4px 8px; /* Less padding */ font-size: 10px; /* Smaller header */ min-width: 120px; /* Narrower */ max-width: 200px; /* Narrower */ } .conflict-tooltip-body { padding: 6px 8px; /* Was 10px 12px */ font-size: 9px; /* Was 11px */ line-height: 1.4; /* Was 1.6 */ } .conflict-item { padding: 2px 0; /* Was 4px */ font-size: 9px; /* Added smaller font */ } ``` **Result**: - Main calendar tooltip ~50% smaller - Sidebar tooltips now extend beyond borders - Both tooltips compact and readable ## Version 4.0.8 (2026-02-07) - FIX NEWLINES IN TOOLTIP ### 🐛 Bug Fix - **Fixed:** Tooltip now shows actual line breaks (not literal `\n` text) - **Changed:** Using HTML entity ` ` for newlines instead of `\n` ### Technical Details **The Problem**: ```php // Before (v4.0.7): $conflictTooltip = 'Conflicts with:\n'; // Literal \n showed in tooltip // Displayed as: "Conflicts with:\n• Event 1\n• Event 2" // ← Literal backslash-n ``` **The Fix**: ```php // After (v4.0.8): $conflictTooltip = "Conflicts with: "; // HTML entity for newline // Displays as: Conflicts with: • Event 1 • Event 2 ``` **Why ` ` Works**: - HTML entity for line feed character - Works in data attributes - CSS `white-space: pre-line` preserves the newlines - Renders as actual line breaks in tooltip **Applied to**: - PHP rendering (sidebar Today/Tomorrow/Important) - JavaScript rendering (clicked day events) ## Version 4.0.7 (2026-02-07) - COMPACT TOOLTIP & OVERFLOW FIX ### 🎨 UI Improvements - **Changed:** Tooltip size reduced significantly (much more compact) - **Fixed:** Tooltip now overflows sidebar borders (not cut off) - **Changed:** Smaller padding (3px vs 6px), smaller font (9px vs 11px) - **Changed:** Narrower width (120-200px vs 200-300px) ### Technical Details **Tooltip Size Reduction**: ```css /* Before (v4.0.6): padding: 6px 10px; font-size: 11px; min-width: 200px; max-width: 300px; /* After (v4.0.7): */ padding: 3px 6px; font-size: 9px; min-width: 120px; max-width: 200px; ``` **Overflow Fix**: ```css /* Allow tooltip to extend beyond sidebar */ .sidebar-widget, .sidebar-matrix { overflow: visible !important; } /* Position tooltip outside */ [data-tooltip]:before { bottom: 120%; /* Further above */ right: -10px; /* Can extend beyond edge */ z-index: 10000; /* Always on top */ } ``` **Visual Result**: - Tooltip is ~40% smaller - Extends beyond sidebar border if needed - Still readable, just more compact - Better for small screens ## Version 4.0.6 (2026-02-07) - MATCH MAIN CALENDAR LOGIC & TOOLTIP POSITIONING ### 🐛 Critical Fix - **Fixed:** Sidebar conflict detection now matches main calendar logic exactly - **Fixed:** Checks both `end_time` (snake_case) and `endTime` (camelCase) field names - **Fixed:** Events without end time now treated as zero-duration (not +1 hour) - **Fixed:** Now matches what you see in main calendar view ### ✨ UI Improvement - **Changed:** Conflict tooltips now appear ABOVE and to the LEFT (not below/right) - **Added:** Custom CSS tooltip with data-tooltip attribute - **Improved:** Better tooltip positioning - doesn't overflow screen edges ### Technical Details **The Problem - Field Name Mismatch**: ```php // Main calendar (line 697): $end1 = isset($evt1['endTime']) ? ... // ← Checks 'endTime' (camelCase) // Sidebar (before fix): $endTime = isset($event['end_time']) ? ... // ← Only checked 'end_time' (snake_case) ``` **The Problem - Duration Logic**: ```php // Main calendar (line 697): $end1 = isset($evt1['endTime']) && !empty($evt1['endTime']) ? $evt1['endTime'] : $evt1['time']; // ← Uses START time (zero duration) // Sidebar (before fix): $endTime = ... ? ... : $this->addHoursToTime($startTime, 1); // ← Added 1 hour! ``` **The Fix**: ```php // Now checks BOTH field names: if (isset($event['end_time']) && $event['end_time'] !== '') { $endTime = $event['end_time']; } elseif (isset($event['endTime']) && $event['endTime'] !== '') { $endTime = $event['endTime']; } else { $endTime = $startTime; // ← Matches main calendar! } ``` **Tooltip Positioning**: - Uses `data-tooltip` attribute instead of `title` - CSS positions tooltip ABOVE badge (`bottom: 100%`) - Aligns to RIGHT edge (`right: 0`) - Arrow points down to badge - Black background with white text - Max width 300px ### Example **6:00 PM Evening Service** (no end time): - Old: 6:00 PM - 7:00 PM (assumed 1 hour) ❌ - New: 6:00 PM - 6:00 PM (zero duration) ✓ Matches main calendar! **3:30 PM-7:00 PM Super Bowl** vs **6:00 PM Service**: - Zero-duration events at 6:00 PM don't overlap with anything - ONLY if service has explicit end time (e.g., 6:00-7:00) will it conflict **Tooltip appears**: ``` ┌────────────────────┐ │ Conflicts with: │ │ • Super Bowl │ │ (3:30 PM-7:00 PM)│ └─────────┬──────────┘ ▼ ⚠ ``` ## Version 4.0.5 (2026-02-07) - FIX END_TIME DEFAULT HANDLING ### 🐛 Bug Fix - **Fixed:** Events without end_time now properly get 1-hour default duration - **Fixed:** Empty string end_time values now treated as missing (was causing issues) - **Improved:** More robust checking for `end_time` field (checks both isset and not empty) ### Technical Details **The Problem**: ```php // Before (broken): $endTime = isset($event['end_time']) ? $event['end_time'] : default; // If end_time exists but is empty string "": isset($event['end_time']) = TRUE $endTime = "" // ← Empty string, not default! ``` **The Fix**: ```php // After (fixed): $endTime = (isset($event['end_time']) && $event['end_time'] !== '') ? $event['end_time'] : $this->addHoursToTime($startTime, 1); // Now empty string gets the default 1-hour duration ``` **Why This Matters**: Events like "6:00 PM Evening Service" with no end time should be treated as 6:00-7:00 PM (1 hour). If the `end_time` field contains an empty string instead of being absent, the old code would use the empty string, causing conflict detection to fail. **Example**: ``` Super Bowl: 3:30 PM - 7:00 PM Evening Service: 6:00 PM - ??? (should be 7:00 PM) If end_time = "" (empty string): Old code: Uses "" → conflict detection fails New code: Uses 7:00 PM → conflict detected ✓ ``` ### Testing If you're still not seeing the conflict on the 6:00 PM service: 1. Check if the event has `end_time` set in the JSON 2. Clear cache (Admin → Manage Events → Clear Cache) 3. The conflict should now appear ## Version 4.0.4 (2026-02-07) - CONFLICT TOOLTIP WITH DETAILS ### ✨ Feature Added - **Added:** Hover over ⚠ badge to see which events are conflicting - **Added:** Tooltip shows conflicting event titles and times - **Added:** Works in both sidebar sections and clicked day events ### Technical Details **Conflict Tracking Enhanced**: ```php // Now tracks WHICH events conflict: $event['conflictingWith'] = [ ['title' => 'Meeting', 'time' => '10:00', 'end_time' => '11:00'], ['title' => 'Call', 'time' => '10:30', 'end_time' => '11:30'] ]; ``` **Tooltip Format**: ``` Conflicts with: • Meeting (10:00 AM-11:00 AM) • Call (10:30 AM-11:30 PM) ``` **Where It Works**: - ✅ Today section (sidebar) - ✅ Tomorrow section (sidebar) - ✅ Important Events section (sidebar) - ✅ Clicked day events (week grid) **Cursor**: Changes to `help` cursor on hover to indicate tooltip ### Note on Multi-Day Events The current conflict detection only checks time conflicts **within the same day**. If you have an event that spans multiple days (e.g., start date on Monday, end date on Wednesday), each day is treated independently. To see conflicts across the entire span, you would need to check each individual day. ## Version 4.0.3 (2026-02-07) - FIX CONFLICT BADGE & IMPORTANT EVENTS LOGIC ### 🐛 Bug Fixes - **Fixed:** Conflict badge (⚠) now displays in sidebar Today/Tomorrow/Important sections - **Fixed:** Important Events now shows events even if they're today or tomorrow - **Fixed:** Field name mismatch - was checking `'conflicts'` (plural) but setting `'conflict'` (singular) ### Technical Details **Conflict Badge Issue**: ```php // BROKEN (line 2511): $hasConflict = isset($event['conflicts']) && !empty($event['conflicts']); // ↑ Checking 'conflicts' (plural) // But detectTimeConflicts() sets: $event['conflict'] = true/false; // ↑ Setting 'conflict' (singular) // FIXED: $hasConflict = isset($event['conflict']) && $event['conflict']; ``` **Result**: Badge now shows for ALL conflicting events in sidebar sections **Important Events Logic Issue**: ```php // BROKEN: if ($dateKey === $todayStr) { $todayEvents[] = ...; } elseif ($dateKey === $tomorrowStr) { $tomorrowEvents[] = ...; } else { // ← Only checked if NOT today/tomorrow! if ($isImportant) { $importantEvents[] = ...; } } // FIXED: if ($dateKey === $todayStr) { $todayEvents[] = ...; } if ($dateKey === $tomorrowStr) { $tomorrowEvents[] = ...; } // ↑ Changed to separate 'if' statements if ($isImportant && $dateKey in this week) { $importantEvents[] = ...; // ← Now includes today/tomorrow too! } ``` **Result**: Important namespace events now show in Important section even if they're today or tomorrow ### Conflict Badge Display - Simplified to just ⚠ icon (no count) - Orange color (#ff9800) - 10px font size - Hover shows "Time conflict detected" ## Version 4.0.2 (2026-02-07) - FIX IMPORTANT EVENTS DISPLAY ### 🐛 Bug Fix - **Fixed:** Important Events section now displays all events correctly - **Fixed:** Single-event days now get conflict flag (was returning early without flag) - **Fixed:** Conflict detection no longer causes events to disappear from Important section ### Technical Details **The Problem**: - `detectTimeConflicts()` returned early if only 1 event on a day - Returned original array without adding 'conflict' field - This inconsistency caused issues in event categorization **The Solution**: ```php // Before (broken): if (empty($dayEvents) || count($dayEvents) < 2) { return $dayEvents; // No 'conflict' field added! } // After (fixed): if (count($dayEvents) === 1) { return [array_merge($dayEvents[0], ['conflict' => false])]; // Always add flag } ``` **Result**: - All events now have 'conflict' field consistently - Single events: conflict = false - Multiple events: conflict = true/false based on overlap - Important Events section displays correctly ## Version 4.0.1 (2026-02-06) - CONFLICT DETECTION, TAB REORDER, FIXES ### 🐛 Bug Fixes - **Fixed:** Conflict badge (⚠) now displays in clicked day events - **Fixed:** Recurring events edit now updates time and end_time correctly - **Fixed:** Field names changed from 'start'/'end' to 'time'/'end_time' in recurring edit ### ✨ Features Added - **Added:** Time conflict detection for overlapping events - **Added:** detectTimeConflicts() function checks all events on same day - **Added:** timesOverlap(), timeToMinutes(), addMinutesToTime() helper functions - **Added:** Events now have 'conflict' flag set automatically ### 🎨 UI Changes - **Changed:** Admin tab order: 📅 Manage Events (first), 📦 Update Plugin, ⚙️ Outlook Sync - **Changed:** Default admin tab is now "Manage Events" (was "Update Plugin") - **Changed:** Week view now shows 4 colored event bars before "+1" (was 3 bars) ### Technical Details **Conflict Detection**: ```php // Automatically detects overlapping events on same day // Sets 'conflict' flag to true if event overlaps with another $eventsWithConflicts = $this->detectTimeConflicts($dayEvents); ``` **Logic**: - All-day events never conflict (no time set) - Timed events check for overlap with other timed events - Overlap = start1 < end2 AND start2 < end1 - Default duration is 60 minutes if no end_time **Recurring Events Fix**: - Old: Updated `$event['start']` and `$event['end']` (wrong fields) - New: Updates `$event['time']` and `$event['end_time']` (correct fields) - Now edits actually save and update the events **Week View Bars**: - Shows 4 colored bars instead of 3 - "+1" becomes "+2" with 5 events, "+3" with 6 events, etc. ## Version 4.0.0 (2026-02-06) - MATRIX EDITION RELEASE 🎉 **Major Release**: Complete Matrix-themed calendar plugin with advanced features! ### 🌟 Major Features #### Sidebar Widget - **Week Grid**: Interactive 7-day calendar with click-to-view events - **Live System Monitoring**: CPU load, real-time CPU, memory usage with tooltips - **Live Clock**: Updates every second with date display - **Real-time Weather**: Geolocation-based temperature with icon - **Event Sections**: Today (orange), Tomorrow (green), Important (purple) - **Add Event Button**: Dark green bar opens full event creation dialog - **Matrix Theme**: Green glow effects throughout #### Event Management - **Single Color Bars**: Clean 3px bars showing event's assigned color - **All-Day Events First**: Then sorted chronologically by time - **Conflict Detection**: Orange ⚠ badge on overlapping events - **Rich Content**: Full DokuWiki formatting (**bold**, [[links]], //italic//) - **HTML Rendering**: Pre-rendered for JavaScript display - **Click-to-View**: Click week grid days to expand event details #### Admin Interface - **Update Plugin Tab** (Default): Version info, changelog, prominent Clear Cache button - **Outlook Sync Tab**: Microsoft Azure integration, category mapping, sync settings - **Manage Events Tab**: Browse, edit, delete, move events across namespaces #### Outlook Sync - **Bi-directional Sync**: DokuWiki ↔ Microsoft Outlook - **Category Mapping**: Map colors to Outlook categories - **Conflict Resolution**: Time conflict detection - **Import/Export Config**: Encrypted configuration files ### 🎨 Design - **Matrix Theme**: Authentic green glow aesthetic - **Dark Backgrounds**: #1a1a1a header, rgba(36, 36, 36) sections - **Color Scheme**: - Today: Orange #ff9800 - Tomorrow: Green #4caf50 - Important: Purple #9b59b6 - Add Event: Dark green #006400 - System bars: Green/Purple/Orange ### 🔧 Technical Highlights - **Zero-margin Design**: Perfect flush alignment throughout - **Flexbox Layout**: Modern, responsive structure - **AJAX Operations**: No page reloads needed - **Smart Sorting**: All-day events first, then chronological - **Tooltip System**: Detailed stats on hover (working correctly) - **Event Dialog**: Full form with drag support - **Cache Management**: One-click cache clearing ### 📝 Breaking Changes from v3.x - Removed dual color bars (now single event color bar only) - Add Event button moved to between header and week grid - All-day events now appear FIRST (not last) - Update Plugin tab is now the default admin tab ### 🐛 Bug Fixes (v3.10.x → v4.0.0) - ✅ Fixed color bars not showing (align-self:stretch vs height:100%) - ✅ Fixed tooltip function naming (sanitized calId for JavaScript) - ✅ Fixed weather display (added updateWeather function) - ✅ Fixed HTML rendering in events (title_html/description_html fields) - ✅ Fixed Add Event dialog (null check for calendar element) - ✅ Fixed text positioning in Add Event button - ✅ Fixed spacing throughout sidebar widget ### 📦 Complete Feature List - Full calendar view (month grid) - Sidebar widget (week view) - Event panel (standalone) - Event list (date ranges) - Namespace support - Color coding - Time conflict detection - DokuWiki syntax in events - Outlook synchronization - System monitoring - Weather display - Live clock - Admin interface - Cache management - Draggable dialogs - AJAX save/edit/delete - Import/export config ### 🎯 Usage **Sidebar Widget**: ``` {{calendar sidebar}} {{calendar sidebar namespace=team}} ``` **Full Calendar**: ``` {{calendar}} {{calendar year=2026 month=6 namespace=team}} ``` **Event Panel**: ``` {{eventpanel}} ``` **Event List**: ``` {{eventlist daterange=2026-01-01:2026-01-31}} ``` ### 📊 Stats - **40+ versions** developed during v3.x iterations - **3.10.0 → 3.11.4**: Polish and refinement - **4.0.0**: Production-ready Matrix Edition ### 🙏 Credits Massive iteration and refinement session resulting in a polished, feature-complete calendar plugin with authentic Matrix aesthetics and enterprise-grade Outlook integration. --- ## Previous Versions (v3.11.4 and earlier) ## Version 3.11.4 (2026-02-06) - RESTORE HEADER BOTTOM SPACING - **Changed:** Restored 2px bottom padding to header (was 0px, now 2px) - **Improved:** Small breathing room between system stats bars and Add Event button - **Visual:** Better spacing for cleaner appearance ### CSS Change: **eventlist-today-header**: - `padding: 6px 10px 0 10px` → `padding: 6px 10px 2px 10px` ### Visual Result: ``` │ ▓▓▓░░ ▓▓░░░ ▓▓▓▓░ │ ← Stats bars │ │ ← 2px space (restored) ├───────────────────────┤ │ + ADD EVENT │ ← Add Event bar ├───────────────────────┤ ``` **Before (v3.11.3)**: No space, bars directly touch Add Event button **After (v3.11.4)**: 2px breathing room for better visual hierarchy ## Version 3.11.3 (2026-02-06) - FIX ADD EVENT DIALOG & TEXT POSITION - **Fixed:** openAddEvent() function now checks if calendar element exists before reading dataset - **Fixed:** Add Event button no longer throws "Cannot read properties of null" error - **Changed:** Add Event text moved up 1px (position:relative; top:-1px) - **Changed:** Line-height reduced from 12px to 10px for better text centering - **Improved:** openAddEvent() works for both regular calendars and sidebar widgets ### JavaScript Fix: **Problem**: Line 1084-1085 in calendar-main.js ```javascript const calendar = document.getElementById(calId); const filteredNamespace = calendar.dataset.filteredNamespace; // ← Null error! ``` **Solution**: Added null check ```javascript const calendar = document.getElementById(calId); const filteredNamespace = calendar ? calendar.dataset.filteredNamespace : null; ``` **Why This Happened**: - Regular calendar has element with id=calId - Sidebar widget doesn't have this element (different structure) - Code tried to read .dataset on null, causing error ### Text Position Fix: **Before**: - line-height: 12px - vertical-align: middle - Text slightly low **After**: - line-height: 10px - position: relative; top: -1px - Text perfectly centered ### What Works Now: ✅ Click "+ ADD EVENT" in sidebar → Dialog opens ✅ No console errors ✅ Text properly centered vertically ✅ Form pre-filled with today's date ✅ Save works correctly ## Version 3.11.2 (2026-02-06) - ADD EVENT DIALOG IN SIDEBAR - **Added:** Event dialog to sidebar widget (same as regular calendar) - **Changed:** Add Event button now opens proper event form dialog - **Added:** renderEventDialog() called in renderSidebarWidget() - **Fixed:** Add Event button calls openAddEvent() with calId, namespace, and today's date - **Improved:** Can now add events directly from sidebar widget ### Add Event Button Behavior: **Before (v3.11.1)**: Showed alert with instructions **After (v3.11.2)**: Opens full event creation dialog **Dialog Features**: - Date field (defaults to today) - Title field (required) - Time field (optional) - End time field (optional) - Color picker - Category field - Description field - Save and Cancel buttons - Draggable dialog ### Technical Changes: - Added `$html .= $this->renderEventDialog($calId, $namespace);` at end of renderSidebarWidget() - Changed Add Event onclick from alert to `openAddEvent('calId', 'namespace', 'YYYY-MM-DD')` - Dialog uses same structure as regular calendar - Uses existing openAddEvent() and saveEventCompact() JavaScript functions ### User Flow: 1. User clicks "+ ADD EVENT" green bar 2. Event dialog opens with today's date pre-filled 3. User fills in event details 4. User clicks Save 5. Event saved via AJAX 6. Dialog closes 7. Sidebar refreshes to show new event ## Version 3.11.1 (2026-02-06) - FLUSH HEADER & ADD EVENT DIALOG - **Fixed:** Removed bottom padding from header (was 2px, now 0) - **Fixed:** Removed margin from stats container (was margin-top:2px, now margin:0) - **Fixed:** Add Event bar now flush against header with zero gap - **Changed:** Add Event button now shows helpful alert dialog instead of navigating to admin - **Improved:** Alert provides clear instructions on how to add events ### CSS Changes: **eventlist-today-header**: - `padding: 6px 10px 2px 10px` → `padding: 6px 10px 0 10px` (removed 2px bottom) **eventlist-stats-container**: - `margin-top: 2px` → `margin: 0` (removed all margins) ### Add Event Button Behavior: **Before**: Clicked → Navigated to Admin → Manage Events tab **After**: Clicked → Shows alert with instructions **Alert Message**: ``` To add an event, go to: Admin → Calendar Management → Manage Events tab or use the full calendar view {{calendar}} ``` ### Visual Result: ``` │ ▓▓▓░░ ▓▓░░░ ▓▓▓▓░ │ ← Stats (no margin-bottom) ├────────────────────────┤ │ + ADD EVENT │ ← Perfectly flush! ├────────────────────────┤ ``` No gaps, perfectly aligned! ## Version 3.11.0 (2026-02-06) - ADD EVENT BAR FINAL POSITION & SIZE - **Moved:** Add Event bar back to original position (between header and week grid) - **Changed:** Font size reduced from 9px to 8px (prevents text cutoff) - **Changed:** Letter spacing reduced from 0.5px to 0.4px - **Fixed:** Text now fully visible without being cut off - **Final:** Optimal position and size determined ### Final Layout: ``` ┌─────────────────────────────┐ │ Clock | Weather | Stats │ ← Header ├─────────────────────────────┤ │ + ADD EVENT │ ← Bar (back here, smaller text) ├─────────────────────────────┤ │ M T W T F S S │ ← Week Grid │ 3 4 5 6 7 8 9 │ ├─────────────────────────────┤ │ Today │ ← Event sections └─────────────────────────────┘ ``` ### Text Size Changes: **v3.10.9**: 9px font, 0.5px letter-spacing → Text slightly cut off **v3.11.0**: 8px font, 0.4px letter-spacing → Text fully visible ### Why This Position: - Separates header from calendar - Natural action point after viewing stats - Users see stats → decide to add event → view calendar - Consistent with original design intent ## Version 3.10.9 (2026-02-06) - ADD EVENT BAR MOVED BELOW WEEK GRID - **Moved:** Add Event bar repositioned from between header/grid to below week grid - **Improved:** Better visual flow - header → stats → grid → add button → events - **Changed:** Add Event bar now acts as separator between calendar and event sections ### New Layout: ``` ┌─────────────────────────────┐ │ Clock | Weather | Stats │ ← Header ├─────────────────────────────┤ │ M T W T F S S │ ← Week Grid │ 3 4 5 6 7 8 9 │ ├─────────────────────────────┤ │ + ADD EVENT │ ← Add bar (moved here!) ├─────────────────────────────┤ │ Today │ ← Event sections │ Tomorrow │ │ Important Events │ └─────────────────────────────┘ ``` ### Visual Flow: **Before (v3.10.8)**: 1. Header (clock, weather, stats) 2. **+ ADD EVENT** bar 3. Week grid 4. Event sections **After (v3.10.9)**: 1. Header (clock, weather, stats) 2. Week grid (calendar days) 3. **+ ADD EVENT** bar 4. Event sections ### Benefits: - Natural reading flow: View calendar → Add event → See events - Add button positioned between calendar and event list - Acts as visual separator - More logical action placement ## Version 3.10.8 (2026-02-06) - SINGLE COLOR BAR & ZERO MARGIN ADD BAR - **Removed:** Section color bar (blue/orange/green/purple) - now shows ONLY event color - **Changed:** Events now display with single 3px color bar (event's assigned color only) - **Fixed:** Add Event bar now has zero margin (margin:0) - touches header perfectly - **Simplified:** Cleaner visual with one color bar instead of two - **Improved:** More space for event content without extra bar ### Visual Changes: **Before (v3.10.7)** - Dual color bars: ``` ├─ [Orange][Green] Event Title ├─ [Blue][Purple] Event Title ``` **After (v3.10.8)** - Single color bar: ``` ├─ [Green] Event Title ← Only event color! ├─ [Purple] Event Title ← Only event color! ``` ### Add Bar Changes: - Added `margin:0` to eliminate gaps - Now flush against header (no space above) - Now flush against week grid (no space below) - Perfect seamless connection ### Technical Changes: **renderSidebarEvent()**: - Removed section color bar (4px) - Kept only event color bar (3px) **showDayEvents() JavaScript**: - Removed section color bar (4px blue) - Kept only event color bar (3px) **Add Event bar**: - Added `margin:0` inline style - Removed all top/bottom margins ## Version 3.10.7 (2026-02-06) - COLOR BARS FIX FOR SECTIONS & DARK GREEN ADD BAR - **Fixed:** Color bars now display in Today/Tomorrow/Important sections (was only showing in clicked day) - **Fixed:** Changed Today/Tomorrow/Important event rendering to use `align-self:stretch` instead of `height:100%` - **Changed:** Add Event bar color from orange to dark green (#006400) - **Changed:** Add Event bar height increased from 6px to 12px (text no longer cut off) - **Changed:** Add Event bar text now bright green (#00ff00) with green glow - **Changed:** Add Event bar font size increased from 7px to 9px - **Changed:** Add Event bar letter spacing increased to 0.5px - **Improved:** Hover effect on Add Event bar now darker green (#004d00) ### Color Bar Fix Details: **Problem**: Today/Tomorrow/Important sections still used `height:100%` on color bars **Solution**: Applied same fix as clicked day events: - Changed parent div: `align-items:start` → `align-items:stretch` - Added `min-height:20px` to parent - Changed bars: `height:100%` → `align-self:stretch` - Bars now properly fill vertical space in ALL sections ### Add Event Bar Changes: **Before**: - Background: Orange (#ff9800) - Text: Black (#000) - Height: 6px (text cut off) - Font: 7px **After**: - Background: Dark green (#006400) - Text: Bright green (#00ff00) with green glow - Height: 12px (text fully visible) - Font: 9px - Hover: Darker green (#004d00) - Matrix-themed green aesthetic ## Version 3.10.6 (2026-02-06) - COLOR BARS FIX, SORTING REVERSAL, CONFLICT BADGE, README UPDATE - **Fixed:** Event color bars now display correctly in clicked day events - **Fixed:** Changed sorting - all-day events now appear FIRST, then timed events - **Added:** Conflict badge (⚠) appears on right side of conflicting events - **Updated:** Complete README.md rewrite with full Matrix theme documentation - **Changed:** Color bars use `align-self:stretch` instead of `height:100%` (fixes rendering) - **Changed:** Parent div uses `align-items:stretch` and `min-height:20px` - **Improved:** Content wrapper now uses flexbox for proper conflict badge positioning ### Color Bar Fix: **Problem**: Bars had `height:100%` but parent had no explicit height **Solution**: - Changed to `align-self:stretch` on bars - Parent uses `align-items:stretch` - Added `min-height:20px` to parent - Bars now properly fill vertical space ### Sorting Change: **Before**: Timed events first → All-day events last **After**: All-day events FIRST → Timed events chronologically **Example**: ``` Monday, Feb 5 ├─ All Day - Project Deadline ← All-day first ├─ 8:00 AM - Morning Standup ← Earliest time ├─ 10:30 AM - Coffee with Bob └─ 2:00 PM - Team Meeting ← Latest time ``` ### Conflict Badge: - Orange warning triangle (⚠) on right side - 10px font size - Only appears if `event.conflict` is true - Title attribute shows "Time conflict detected" - Small and unobtrusive ### README Update: - Complete rewrite with Matrix theme focus - Full usage instructions for all features - Admin interface documentation - Outlook sync setup guide - System monitoring details - Troubleshooting section - Color scheme reference - File structure documentation - Performance tips - Security notes - Quick start examples ## Version 3.10.5 (2026-02-06) - TIME SORTING & THINNER ADD BAR - **Added:** Events now sorted by time when clicking week grid days - **Changed:** Add Event bar now ultra-thin (6px height, down from 12px) - **Improved:** Events with times appear first, sorted chronologically - **Improved:** All-day events appear after timed events - **Changed:** Add Event bar font size reduced to 7px (from 10px) - **Changed:** Add Event bar now has 0 padding and fixed 6px height ### Sorting Logic: - Events with times sorted by time (earliest first) - All-day events (no time) appear at the end - Sort algorithm: Convert time to minutes (HH:MM → total minutes) and compare - Chronological order: 8:00 AM → 10:30 AM → 2:00 PM → All-day event ### Add Event Bar Changes: - **Height**: 6px (was ~12px with padding) - **Padding**: 0 (was 4px top/bottom) - **Font Size**: 7px (was 10px) - **Letter Spacing**: 0.3px (was 0.5px) - **Line Height**: 6px to match height - **Vertical Align**: Middle for text centering ## Version 3.10.4 (2026-02-06) - ADD EVENT BAR - **Added:** Thin orange "Add Event" bar between header and week grid - **Added:** Quick access to event creation from sidebar widget - **Styled:** Sleek design with hover effects and glow - **Interactive:** Clicks navigate to Manage Events tab in admin - **Improved:** User workflow for adding events from sidebar ### Visual Design: - Orange background (#ff9800) matching Today section color - 4px top/bottom padding for thin, sleek appearance - Black text with white text-shadow for visibility - Hover effect: Darkens to #ff7700 with enhanced glow - Orange glow effect (box-shadow) matching Matrix theme - Centered "+ ADD EVENT" text (10px, bold, letter-spacing) ### Technical Changes: - Added between header close and renderWeekGrid() call - Inline onclick handler navigates to admin manage tab - Inline onmouseover/onmouseout for hover effects - Smooth 0.2s transition on all style changes ## Version 3.10.3 (2026-02-06) - UI IMPROVEMENTS & CACHE BUTTON RELOCATION - **Changed:** Update Plugin tab is now the default tab when opening admin - **Moved:** Clear Cache button relocated from Outlook Sync tab to Update Plugin tab - **Improved:** Clear Cache button now larger and more prominent with helpful description - **Improved:** Tab order reorganized: Update Plugin (default) → Outlook Sync → Manage Events - **Removed:** Debug console.log statements from day event display - **Fixed:** Cache clear now redirects back to Update Plugin tab instead of Config tab ### UI Changes: - Update Plugin tab opens by default (was Config/Outlook Sync tab) - Clear Cache button prominently displayed at top of Update Plugin tab - Orange 🗑️ button (10px 20px padding) with confirmation dialog - Help text: "Clear the DokuWiki cache if changes aren't appearing or after updating the plugin" - Success/error messages display on Update Plugin tab after cache clear - Tab navigation reordered to put Update first ### Technical Changes: - Default tab changed from 'config' to 'update' in html() method - Tab navigation HTML reordered to show Update Plugin tab first - clearCache() method now redirects with 'update' tab parameter - Removed Clear Cache button from renderConfigTab() - Added Clear Cache button to renderUpdateTab() with message display ## Version 3.10.2 (2026-02-06) - EVENT HTML RENDERING FIX - **Fixed:** Event formatting (bold, links, italic) now displays correctly when clicking week grid days - **Added:** renderDokuWikiToHtml() helper function to convert DokuWiki syntax to HTML - **Changed:** Events in weekEvents now pre-rendered with title_html and description_html fields - **Improved:** DokuWiki syntax (**bold**, [[links]], //italic//, etc.) properly rendered in clicked day events ### Technical Changes: - Added renderDokuWikiToHtml() private function using p_get_instructions() and p_render() - Events added to weekEvents now include pre-rendered HTML versions - title_html and description_html fields populated before json_encode() - JavaScript now receives properly formatted HTML content ## Version 3.10.1 (2026-02-06) - TOOLTIP FIX & WEATHER & CACHE BUTTON - **Fixed:** System tooltip functions now use sanitized calId (showTooltip_sidebar_abc123 instead of showTooltip_sidebar-abc123) - **Fixed:** HTML event handlers now call correctly sanitized function names - **Fixed:** Weather temperature now updates correctly in sidebar widget - **Added:** Weather update function to sidebar widget JavaScript - **Added:** "Clear Cache" button in admin panel for easy cache refresh - **Added:** Default weather location set to Irvine, CA when geolocation unavailable - **Improved:** All tooltip functions now work correctly on system status bars ### Technical Changes: - Changed tooltip function names to use $jsCalId instead of $calId - Changed HTML onmouseover/onmouseout to use $jsCalId - Added updateWeather() function to sidebar widget - Added getWeatherIcon() function to sidebar widget - Added clearCache() method in admin.php - Added recursiveDelete() helper method in admin.php - Admin UI now has 🗑️ Clear Cache button alongside Export/Import ## Version 3.10.0 (2026-02-06) - JAVASCRIPT FIXES - **Fixed:** JavaScript syntax error "Missing initializer in const declaration" - **Fixed:** Event links and formatting not displaying in clicked day events - **Fixed:** Sanitized calId to jsCalId by replacing dashes with underscores - **Changed:** Event titles now use `title_html` field to preserve HTML formatting - **Changed:** Event descriptions now use `description_html` field to preserve links and formatting - **Improved:** All JavaScript variable names now use valid syntax - **Improved:** Links, bold, italic, and other HTML formatting preserved in events ### Technical Changes: - Added variable sanitization: `$jsCalId = str_replace('-', '_', $calId);` - JavaScript variables now use underscores instead of dashes - Event HTML rendering preserves DokuWiki formatting - Fixed "showTooltip_sidebar is not defined" errors - Fixed "showDayEvents_cal is not defined" errors ## Version 3.9.9 (2026-02-06) - JAVASCRIPT LOADING ORDER FIX - **Fixed:** Critical JavaScript loading order issue causing ReferenceError - **Fixed:** Functions now defined BEFORE HTML that uses them - **Changed:** Consolidated all JavaScript into single comprehensive script block - **Removed:** ~290 lines of duplicate JavaScript code - **Added:** Shared state management with `sharedState_[calId]` object - **Improved:** System tooltip functions now work correctly - **Improved:** Week grid click events now work correctly ### Technical Changes: - Moved all JavaScript to beginning of widget (before HTML) - Removed duplicate script blocks - Unified tooltip and stats functions - Shared latestStats and cpuHistory state - Fixed "Uncaught ReferenceError: showTooltip_sidebar is not defined" ## Version 3.9.8 (2026-02-05) - DUAL COLOR BARS & CLICK EVENTS - **Added:** Dual color bars on events (section color + event color) - **Added:** Click week grid days to view events (replaced hover tooltips) - **Added:** Expandable section below week grid for selected day events - **Added:** Blue theme for selected day section - **Changed:** Week grid days now clickable instead of tooltips - **Changed:** Section bar: 4px wide (left) - **Changed:** Event bar: 3px wide (right) - **Increased:** Gap between color bars from 3px to 6px - **Improved:** Click is more reliable and mobile-friendly than hover tooltips ### Visual Changes: - Each event shows TWO color bars side-by-side - Left bar (4px): Section context (Today=Orange, Tomorrow=Green, Important=Purple, Selected=Blue) - Right bar (3px): Individual event's assigned color - Click any day in week grid to expand event list - X button to close selected day events ## Version 3.9.7 (2026-02-05) - EVENT COLOR BAR VISIBILITY - **Increased:** Event color bar width from 2px to 3px - **Increased:** Gap between section and event bars from 3px to 6px - **Improved:** Event color bars now more visible alongside section bars - **Note:** Dual color bar system already in place from v3.9.6 ## Version 3.9.6 (2026-02-05) - UI REFINEMENTS - **Changed:** Date in Important Events moved below event name (was above) - **Changed:** Section headers now 9px font size (was 10px) - **Changed:** Section headers now normal case (was ALL CAPS) - **Changed:** Letter spacing reduced from 0.8px to 0.3px - **Improved:** More natural reading flow with date below event name - **Improved:** Cleaner, more subtle section headers ### Header Changes: - "TODAY" → "Today" - "TOMORROW" → "Tomorrow" - "IMPORTANT EVENTS" → "Important Events" ## Version 3.9.0 (2026-02-05) - SIDEBAR WIDGET REDESIGN - **Redesigned:** Complete overhaul of `sidebar` parameter - **Added:** Compact week-at-a-glance itinerary view (200px wide) - **Added:** Live clock widget at top of sidebar - **Added:** 7-cell week grid showing event bars - **Added:** Today section with orange header and left border - **Added:** Tomorrow section with green header and left border - **Added:** Important Events section with purple header and left border - **Added:** Admin setting to configure important namespaces - **Added:** Time conflict badges in sidebar events - **Added:** Task checkboxes in sidebar events - **Changed:** Sidebar now optimized for narrow spaces (200px) - **Improved:** Perfect for dashboards, page sidebars, and quick glance widgets ### New Features: - Clock updates every second showing current time - Week grid shows Mon-Sun with colored event bars - Today/Tomorrow sections show full event details - Important events highlighted in purple (configurable namespaces) - All badges (conflict, time, etc.) shown in compact format - Automatic time conflict detection ## Version 3.8.0 (2026-02-05) - PRODUCTION CLEANUP - **Removed:** 16 unused/debug/backup files - **Removed:** 69 console.log() debug statements - **Removed:** 3 orphaned object literals from console.log removal - **Removed:** Temporary comments and markers - **Fixed:** JavaScript syntax errors from cleanup - **Improved:** Code quality and maintainability - **Improved:** Reduced plugin size by removing unnecessary files - **Status:** Production-ready, fully cleaned codebase ### Files Removed: - style.css.backup, script.js.backup - admin_old_backup.php, admin_minimal.php, admin_new.php, admin_clean.php - debug_events.php, debug_html.php, cleanup_events.php - fix_corrupted_json.php, fix_wildcard_namespaces.php - find_outlook_duplicates.php, update_namespace.php - validate_calendar_json.php, admin.js - test_date_field.html ## Version 3.7.5 (2026-02-05) - **Fixed:** PHP syntax error (duplicate foreach loop removed) - **Fixed:** Time variable handling in grace period logic ## Version 3.7.4 (2026-02-05) - **Added:** 15-minute grace period for timed events - **Changed:** Events with times now stay visible for 15 minutes after their start time - **Changed:** Prevents events from immediately disappearing when they start - **Improved:** Better user experience for ongoing events - **Fixed:** Events from earlier today now properly handled with grace period ## Version 3.7.3 (2026-02-05) - **Changed:** Complete redesign of cleanup section for compact, sleek layout - **Changed:** Radio buttons now in single row at top - **Changed:** All options visible with grayed-out inactive states (opacity 0.4) - **Changed:** Inline controls - no more grid layout or wrapper boxes - **Changed:** Namespace filter now compact single-line input - **Changed:** Smaller buttons and tighter spacing throughout - **Improved:** More professional, space-efficient design ## Version 3.7.2 (2026-02-04) - **Fixed:** Strange boxes under cleanup options - now properly hidden - **Changed:** Unified color scheme across all admin sections - **Changed:** Green (#00cc07) - Primary actions and main theme - **Changed:** Orange (#ff9800) - Warnings and cleanup features - **Changed:** Purple (#7b1fa2) - Secondary actions and accents - **Improved:** Consistent visual design throughout admin interface ## Version 3.7.1 (2026-02-04) - **Fixed:** Cleanup section background changed from orange to white - **Fixed:** Event cleanup now properly scans all calendar directories - **Added:** Debug info display when preview finds no events - **Improved:** Better directory scanning logic matching other features ## Version 3.7.0 (2026-02-04) - **Added:** Event cleanup feature in Events Manager - **Added:** Delete old events by age (months/years old) - **Added:** Delete events by status (completed tasks, past events) - **Added:** Delete events by date range - **Added:** Namespace filter for targeted cleanup - **Added:** Preview function to see what will be deleted - **Added:** Automatic backup creation before cleanup - **Changed:** Reduced changelog viewer height to 100px (was 400px) ## Version 3.6.3 (2026-02-04) - **Fixed:** Conflict tooltips now work properly after navigating between months - **Added:** Changelog display in Update Plugin tab - **Added:** CHANGELOG.md file with version history - **Improved:** Changelog shows last 10 versions with color-coded change types - **Fixed:** Removed debug console.log statements ## Version 3.6.2 (2026-02-04) - **Fixed:** Month title now updates correctly when navigating between months - **Changed:** All eventpanel header elements reduced by 10% for more compact design - **Changed:** Reduced header height from 78px to 70px ## Version 3.6.1 (2026-02-04) - **Changed:** Complete redesign of eventpanel header with practical two-row layout - **Fixed:** Improved layout for narrow widths (~500px) - **Changed:** Simplified color scheme (removed purple gradient) ## Version 3.6.0 (2026-02-04) - **Changed:** Redesigned eventpanel header with gradient background - **Changed:** Consolidated multiple header rows into compact single-row design ## Version 3.5.1 (2026-02-04) - **Changed:** Moved event search bar into header row next to + Add button - **Improved:** More compact UI with search integrated into header ## Version 3.5.0 (2026-02-04) - **Added:** Event search functionality in sidebar and eventpanel - **Added:** Real-time filtering as you type - **Added:** Clear button (✕) appears when searching - **Added:** "No results" message when search returns nothing ## Version 3.4.7 (2026-02-04) - **Changed:** Made conflict badges smaller and more subtle (9px font, less padding) - **Fixed:** Removed debug logging from console - **Changed:** Updated export version number to match plugin version ## Version 3.4.6 (2026-02-04) - **Added:** Debug logging to diagnose conflict detection issues - **Development:** Extensive console logging for troubleshooting ## Version 3.4.5 (2026-02-04) - **Added:** Debug logging to showDayPopup and conflict detection - **Development:** Added logging to trace conflict detection flow ## Version 3.4.4 (2026-02-04) - **Fixed:** Conflict detection now persists across page refreshes (PHP-based) - **Fixed:** Conflict tooltips now appear on hover - **Added:** Dual conflict detection (PHP for initial load, JavaScript for navigation) - **Added:** Conflict badges in both future and past events sections ## Version 3.4.3 (2026-02-04) - **Added:** Custom styled conflict tooltips with hover functionality - **Changed:** Conflict badge shows count of conflicts (e.g., ⚠️ 2) - **Improved:** Beautiful tooltip design with orange header and clean formatting ## Version 3.4.2 (2026-02-04) - **Fixed:** Attempted to fix tooltip newlines (reverted in 3.4.3) ## Version 3.4.1 (2026-02-04) - **Fixed:** End time field now properly saves to database - **Fixed:** End time dropdown now filters to show only valid times after start time - **Added:** Smart dropdown behavior - expands on focus, filters invalid options - **Improved:** End time auto-suggests +1 hour when start time selected ## Version 3.4.0 (2026-02-04) - **Added:** End time support for events (start and end times) - **Added:** Automatic time conflict detection - **Added:** Conflict warning badges (⚠️) on events with overlapping times - **Added:** Conflict tooltips showing which events conflict - **Added:** Visual conflict indicators with pulse animation - **Changed:** Time display now shows ranges (e.g., "2:00 PM - 4:00 PM") ## Version 3.3.77 (2026-02-04) - **Fixed:** Namespace badge onclick handlers restored after clearing filter - **Fixed:** Namespace filtering works infinitely (filter → clear → filter) ## Version 3.3.76 (2026-02-04) - **Fixed:** Namespace badges now clickable after clearing namespace filter ## Version 3.3.75 (2026-02-04) - **Fixed:** Form resubmission warnings eliminated - **Improved:** Implemented proper POST-Redirect-GET pattern with HTTP 303 - **Changed:** All admin redirects now use absolute URLs ## Version 3.3.74 (2026-02-04) - **Fixed:** Clearing namespace filter now restores original namespace instead of default - **Added:** data-original-namespace attribute to preserve initial namespace setting - **Improved:** Console logging for namespace filter debugging ## Version 3.3.73 (2026-02-03) - **Added:** Dynamic namespace filtering banner with clear button - **Fixed:** JavaScript function accessibility issues - **Fixed:** Namespace badge click handlers in event lists - **Improved:** Persistent namespace filtering across views ## Earlier Versions See previous transcripts for complete history through v3.3.73, including: - Recurring events with Outlook sync - Multi-namespace support - Event categories and mapping - Backup/restore functionality - System statistics bar - Namespace selector with fuzzy search - Events Manager with import/export - And much more...