1# DokuWiki Calendar Plugin - Matrix Edition v4.0.0 2 3A powerful, feature-rich calendar plugin with **Matrix theme**, live system monitoring, real-time weather, **Outlook sync**, and advanced event management. 4 5**Version**: 4.0.0 6**Release Date**: February 6, 2026 7**Codename**: Matrix Edition 8 9--- 10 11## Key Features 12 13### Multiple Views 14- **Sidebar Widget** - Compact week view with live stats (recommended) 15- **Full Calendar** - Traditional month grid with event panel 16- **Event Panel** - Standalone event management 17- **Event List** - Flexible date range displays 18 19### Matrix Theme 20- **Authentic Aesthetics** - Green glow effects throughout 21- **Single Color Bars** - Clean 3px bars showing event color 22- **Dark Backgrounds** - #1a1a1a, rgba(36, 36, 36) 23- **Live Updates** - Clock, weather, system stats 24 25### Sidebar Widget Features 26- **Interactive Week Grid** - Click any day to view events 27- **Live System Monitoring** - CPU load, real-time CPU, memory usage 28- **Hover Tooltips** - Detailed stats (load averages, top processes) 29- **Real-time Weather** - Geolocation-based temperature 30- **Live Clock** - Updates every second 31- **Event Sections** - Today (orange), Tomorrow (green), Important (purple) 32- **Add Event Button** - Dark green bar opens full event dialog 33 34### ⚡ Event Management 35- **All-Day Events First** - Then sorted chronologically by time 36- **Conflict Detection** - Orange ⚠ badge on overlapping events 37- **Rich Content** - Full DokuWiki formatting (**bold**, [[links]], //italic//) 38- **Single Color Bars** - Clean design with event's assigned color 39- **AJAX Operations** - Create, edit, delete without page reload 40- **Draggable Dialogs** - Professional event forms 41 42### Outlook Integration 43- **Bi-directional Sync** - DokuWiki ↔ Microsoft Outlook calendars 44- **Category Mapping** - Map DokuWiki colors to Outlook categories 45- **Azure AD Authentication** - Secure OAuth 2.0 46- **Import/Export Config** - Encrypted configuration files 47 48### ️ Admin Interface 49- **Update Plugin Tab** (default) - Version info, changelog, Clear Cache button 50- **Outlook Sync Tab** - Azure configuration, category mapping 51- **Manage Events Tab** - Browse, edit, delete, move events 52 53--- 54 55## Installation 56 57### 1. Extract Plugin 58```bash 59cd /path/to/dokuwiki/lib/plugins/ 60unzip calendar-matrix-edition-v4.0.0.zip 61``` 62 63### 2. Set Permissions 64```bash 65mkdir -p data/meta/calendar 66chmod -R 775 data/meta/calendar 67chown -R www-data:www-data data/meta/calendar 68``` 69 70### 3. Clear Cache 711. Go to **Admin → Calendar Management** 722. Click **️ Clear Cache** button (orange, prominent) 733. Refresh your wiki page 74 75--- 76 77## Usage 78 79### Sidebar Widget (Recommended) 80 81Display the Matrix-themed sidebar widget: 82 83``` 84{{calendar sidebar}} 85``` 86 87**Features**: 88- Current week grid (7 days, clickable) 89- Live system stats (CPU, memory) 90- Real-time weather with temperature 91- Live clock 92- Today/Tomorrow/Important event sections 93- Dark green Add Event button 94 95**With Namespace**: 96``` 97{{calendar sidebar namespace=team}} 98``` 99 100### Full Calendar 101 102Traditional month view with event panel: 103 104``` 105{{calendar}} 106``` 107 108**Specific Month**: 109``` 110{{calendar year=2026 month=6}} 111``` 112 113**With Namespace**: 114``` 115{{calendar namespace=team}} 116``` 117 118### Event Panel Only 119 120Display just the event management panel (320px wide): 121 122``` 123{{eventpanel}} 124``` 125 126Perfect for page sidebars. 127 128### Event List 129 130Display events in a simple list: 131 132``` 133{{eventlist date=2026-02-06}} 134``` 135 136**Date Range**: 137``` 138{{eventlist daterange=2026-01-01:2026-01-31}} 139``` 140 141**With Namespace**: 142``` 143{{eventlist daterange=2026-01-01:2026-01-31 namespace=team}} 144``` 145 146--- 147 148## Creating Events 149 150### Method 1: Sidebar Widget Add Event Button 151 1521. Click the **+ ADD EVENT** dark green bar 1532. Event dialog opens 1543. Fill in event details 1554. Click **Save** 156 157### Method 2: Click Week Grid Day 158 1591. Click any day in the week grid 1602. View existing events 1613. Click **+ Add** button if desired 1624. Fill in event details 1635. Click **Save** 164 165### Method 3: Full Calendar 166 1671. Click **+ Add** button in event panel 1682. Fill in event details 1693. Click **Save** 170 171### Event Fields 172 173**Required**: 174- **Date** - YYYY-MM-DD format 175- **Title** - Event name (supports **bold**, [[links]], //italic//) 176 177**Optional**: 178- **Time** - HH:MM format (24-hour) - leave blank for all-day 179- **End Time** - HH:MM format (for duration) 180- **Color** - Choose from picker or enter hex code 181- **Category** - For organization 182- **Description** - Full DokuWiki formatting supported 183 184### DokuWiki Formatting 185 186Events support full DokuWiki syntax: 187 188``` 189**Meeting with [[team:bob|Bob]]** 190 191Discuss: 192 * Project timeline 193 * //Budget review// 194 * [[projects:alpha|Project Alpha]] status 195``` 196 197Renders with proper HTML formatting including clickable links. 198 199--- 200 201## Viewing Events 202 203### Sidebar Widget 204 205**Week Grid**: 206- 7 days displayed (current week) 207- Event count badges on days with events 208- Click any day → View all events (expandable section) 209- Events sorted: All-day first, then by time 210 211**Today Section** (Orange): 212- All events happening today 213- Sorted: All-day first, then chronologically 214 215**Tomorrow Section** (Green): 216- All events happening tomorrow 217- Same sorting as Today 218 219**Important Events Section** (Purple): 220- Future events from "important" namespace 221- Configurable in Outlook Sync settings 222 223### Clicked Day Events 224 225When you click a day in the week grid: 226 227``` 228Monday, Feb 5 229├─ [Green] All Day - Project Deadline 230├─ [Blue] 8:00 AM - Morning Standup 231├─ [Orange] 10:30 AM - Coffee with Bob ⚠ 232└─ [Purple] 2:00 PM - Team Meeting 233``` 234 235**Features**: 236- **Single color bar** (3px) - Event's assigned color 237- **Conflict badge** - ⚠ appears on right if event overlaps 238- **Sorting** - All-day events FIRST, then chronological 239 240--- 241 242## ⚙️ System Monitoring 243 244### Live Stats in Sidebar 245 246**Green Bar** (5-min CPU Load): 247``` 248Hover to see: 249CPU Load Average 2501-min: 2.45 2515-min: 2.12 25215-min: 1.98 253Uptime: 5 days, 3 hours 254``` 255 256**Purple Bar** (Real-time CPU): 257``` 258Hover to see: 259CPU Load (Short-term) 260Current: 25.3% 261 262Top Processes: 2631. apache2 (8.2%) 2642. mysql (6.1%) 2653. php-fpm (4.5%) 266``` 267 268**Orange Bar** (Memory Usage): 269``` 270Hover to see: 271Memory Usage 272Total: 16.0 GB 273Used: 8.2 GB (51%) 274Available: 7.8 GB 275 276Top Processes: 2771. mysql (2.1 GB) 2782. apache2 (1.3 GB) 2793. php-fpm (845 MB) 280``` 281 282**Update Frequency**: 283- Stats: Every 2 seconds 284- Weather: Every 10 minutes 285- Clock: Every second 286 287--- 288 289## ️ Weather Display 290 291- **Geolocation-based** temperature 292- **Fallback**: Irvine, CA (33.6846, -117.8265) 293- **Updates**: Every 10 minutes 294- **Display**: Icon + temperature (e.g., "️ 72°") 295 296--- 297 298## Outlook Sync Setup 299 300### Prerequisites 3011. Microsoft Azure account 3022. Registered application in Azure Portal 3033. Calendar permissions granted 304 305### Configuration Steps 306 3071. **Register Azure App**: 308 - Go to https://portal.azure.com 309 - Navigate to App Registrations 310 - Create new registration 311 - Note: Tenant ID, Client ID 312 3132. **Create Client Secret**: 314 - In your app, go to Certificates & secrets 315 - Create new client secret 316 - Copy the secret value (shown once!) 317 3183. **Configure Permissions**: 319 - Add API permissions: 320 - Calendars.ReadWrite 321 - Calendars.ReadWrite.Shared 322 - Grant admin consent 323 3244. **Enter in DokuWiki**: 325 - Admin → Calendar Management → Outlook Sync 326 - Enter Tenant ID, Client ID, Client Secret 327 - Enter your email address 328 - Select timezone 329 - Configure sync settings 330 - Click **Save Configuration** 331 3325. **Test Sync**: 333 - Create event in DokuWiki 334 - Run sync (cron job or manual) 335 - Check Outlook calendar 336 - Create event in Outlook 337 - Run sync 338 - Check DokuWiki calendar 339 340### Sync Behavior 341 342**DokuWiki → Outlook**: 343- New events created in Outlook 344- Updates sync to existing events 345- Deletes sync if "Delete Outlook events" enabled 346 347**Outlook → DokuWiki**: 348- New events created in DokuWiki 349- Updates sync to existing events 350- Category colors mapped to DokuWiki colors 351 352**Conflict Resolution**: Last-write-wins 353 354--- 355 356## Color Scheme 357 358### Section Colors 359 360- **Today**: Orange #ff9800 361- **Tomorrow**: Green #4caf50 362- **Important Events**: Purple #9b59b6 363- **Add Event Bar**: Dark green #006400 364 365### System Bars 366 367- **Green Bar**: 5-min CPU load average 368- **Purple Bar**: Real-time CPU usage 369- **Orange Bar**: Real-time memory usage 370 371### Event Colors 372 373- **Default**: Matrix Green #00cc07 374- **Custom**: User-assigned color (via color picker) 375 376--- 377 378## ️ Admin Interface 379 380### Access 381Go to **Admin → Calendar Management** 382 383### Tabs 384 385#### 1. Update Plugin (Default Tab) 386 387**Features**: 388- Current version and date 389- Author information 390- Installation path 391- Permission check 392- **️ Clear Cache** button (prominent orange) 393- Recent changelog (last 10 versions) 394 395**Clear Cache**: 396- Click orange button 397- Confirm dialog 398- Clears all DokuWiki cache 399- **Use after every plugin update!** 400 401#### 2. ⚙️ Outlook Sync 402 403**Azure Configuration**: 404- Tenant ID 405- Client ID 406- Client Secret 407- User Email 408- Timezone 409 410**Sync Settings**: 411- Default category 412- Reminder minutes 413- Sync completed tasks (checkbox) 414- Delete Outlook events (checkbox) 415- Important namespaces (comma-separated) 416 417**Category Mapping**: 418- Map DokuWiki colors to Outlook categories 419- Visual color picker 420 421**Buttons**: 422- ** Export Config** - Download encrypted config 423- ** Import Config** - Upload encrypted config 424- **Save Configuration** 425 426#### 3. Manage Events 427 428**Features**: 429- Browse all events across all namespaces 430- Filter by namespace 431- Search events 432- Edit event details 433- Delete events 434- Move events between dates/namespaces 435 436--- 437 438## File Structure 439 440### Event Storage 441``` 442data/meta/calendar/2026-02.json 443data/meta/team/calendar/2026-02.json 444``` 445 446### Event JSON Format 447```json 448{ 449 "2026-02-06": [ 450 { 451 "id": "evt_abc123", 452 "title": "**Team Meeting**", 453 "title_html": "<strong>Team Meeting</strong>", 454 "time": "14:00", 455 "end_time": "15:00", 456 "description": "Discuss //timeline//", 457 "description_html": "Discuss <em>timeline</em>", 458 "color": "#3498db", 459 "category": "Meetings", 460 "namespace": "team", 461 "created": "2026-02-05 10:00:00", 462 "modified": "2026-02-05 10:30:00", 463 "conflict": false 464 } 465 ] 466} 467``` 468 469### Fields Explained 470 471- **id**: Unique identifier (auto-generated) 472- **title**: Raw DokuWiki syntax 473- **title_html**: Pre-rendered HTML for JavaScript 474- **time**: Start time (HH:MM, 24-hour) 475- **end_time**: End time (optional) 476- **description**: Raw DokuWiki syntax 477- **description_html**: Pre-rendered HTML 478- **color**: Hex color code 479- **category**: Category name 480- **namespace**: Calendar namespace 481- **created**: Timestamp 482- **modified**: Last modified timestamp 483- **conflict**: Boolean - time conflict detected 484 485--- 486 487## Troubleshooting 488 489### Events Not Displaying 490 491**Check 1**: Clear cache 492- Admin → Calendar Management 493- Click **️ Clear Cache** 494- Confirm and refresh page 495 496**Check 2**: File permissions 497```bash 498ls -la data/meta/calendar/ 499# Should show www-data:www-data ownership 500# Should show 775 permissions 501 502# Fix if needed: 503chown -R www-data:www-data data/meta/calendar/ 504chmod -R 775 data/meta/calendar/ 505``` 506 507**Check 3**: Check JSON validity 508```bash 509cat data/meta/calendar/2026-02.json 510# Should be valid JSON 511``` 512 513### Color Bars Not Showing 514 515**Solution**: 5161. Clear browser cache (Ctrl+Shift+R) 5172. Clear DokuWiki cache (admin button) 5183. Verify plugin version is 4.0.0 519 520### Tooltips Not Working 521 522**Solution**: 5231. Verify JavaScript is enabled 5242. Clear cache 5253. Check console for errors 5264. Update to version 4.0.0 527 528### Weather Shows "--°" 529 530**Solution**: 5311. Clear cache 5322. Allow geolocation in browser 5333. Wait 10 seconds for initial update 5344. Check console for errors 535 536### Add Event Button Doesn't Work 537 538**Solution**: 5391. Check browser console for errors 5402. Verify calendar-main.js loaded 5413. Clear cache 5424. Update to version 4.0.0 543 544### Outlook Sync Not Working 545 546**Check 1**: Azure credentials 547- Verify Tenant ID, Client ID, Client Secret 548- Check app permissions in Azure Portal 549- Ensure admin consent granted 550 551**Check 2**: Cron job 552```bash 553# Check cron is running 554crontab -l 555 556# Should show: 557*/15 * * * * /usr/bin/php /path/to/dokuwiki/lib/plugins/calendar/sync_outlook.php 558``` 559 560--- 561 562## Performance 563 564### Optimizations 565 566- **Event Caching**: JSON files cached per month 567- **Lazy Loading**: Events loaded on demand 568- **AJAX Updates**: No full page reloads 569- **Minimal DOM**: Only visible events rendered 570 571### Recommended Limits 572 573- **Events per month**: < 500 (no performance issues) 574- **Events per day**: < 50 (UI remains clean) 575- **Namespaces**: Unlimited (loaded separately) 576- **Event description**: < 500 characters (for readability) 577 578--- 579 580## Security 581 582### Data Storage 583- Events stored server-side in JSON 584- No client-side storage used 585- File permissions protect data 586 587### Outlook Sync 588- Credentials encrypted in config file 589- OAuth 2.0 authentication 590- Secrets never logged or displayed 591 592### Admin Access 593- Requires DokuWiki admin permissions 594- All actions logged 595- CSRF protection on forms 596 597--- 598 599## Browser Support 600 601| Browser | Version | Status | 602|---------|---------|--------| 603| Chrome | 90+ | ✅ Full | 604| Firefox | 88+ | ✅ Full | 605| Safari | 14+ | ✅ Full | 606| Edge | 90+ | ✅ Full | 607| Mobile | Modern | ⚠️ Limited (sidebar scrollable) | 608 609**Required Features**: 610- Flexbox 611- Fetch API 612- ES6 JavaScript 613- CSS Grid 614 615--- 616 617## Support 618 619### Documentation 620- `CHANGELOG.md` - Full version history 621- `RELEASE_NOTES_v4.0.0.txt` - v4.0 details 622- `OUTLOOK_SYNC_SETUP.md` - Detailed sync guide 623- `QUICK_REFERENCE.md` - Syntax quick reference 624 625### Getting Help 6261. Check this README first 6272. Review CHANGELOG for recent changes 6283. Clear cache after updates 6294. Check browser console for errors 6305. Verify file permissions 631 632--- 633 634## License 635 636GPL 2.0 637 638--- 639 640## ✨ What's New in v4.0.0 641 642### Major Changes from v3.x 643- ✅ **Single color bars** (removed dual bars) 644- ✅ **All-day events first** (reversed sorting) 645- ✅ **Add Event dialog** in sidebar widget 646- ✅ **Perfect spacing** throughout 647- ✅ **Matrix Edition** official naming 648- ✅ **Production ready** - all bugs resolved 649 650### Breaking Changes 651- Dual color bars removed (now single bar only) 652- All-day events now appear FIRST (not last) 653- Update Plugin tab is now default (not Config) 654 655### Bug Fixes 656- Fixed color bars rendering (align-self:stretch) 657- Fixed tooltip function naming 658- Fixed weather display 659- Fixed HTML rendering in events 660- Fixed Add Event dialog 661- Fixed spacing throughout 662 663--- 664 665## Quick Start Examples 666 667### Personal Calendar 668``` 669====== My Schedule ====== 670 671{{calendar sidebar namespace=personal}} 672 673**Quick Add**: Click the dark green "+ ADD EVENT" bar 674``` 675 676### Team Dashboard 677``` 678====== Development Team ====== 679 680{{calendar sidebar namespace=team:dev}} 681 682**System Stats**: Hover over colored bars for details 683**Today's Events**: Automatically displayed below calendar 684``` 685 686### Project Timeline 687``` 688====== Project Alpha ====== 689 690{{calendar namespace=projects:alpha year=2026 month=3}} 691 692**Milestones**: 693 * [[projects:alpha:kickoff|Mar 1 - Kickoff]] 694 * [[projects:alpha:design|Mar 15 - Design Review]] 695 * [[projects:alpha:launch|Mar 31 - Launch]] 696``` 697 698--- 699 700## Credits 701 702**Author**: atari911 703**Email**: atari911@gmail.com 704**Version**: 4.0.0 705**Date**: February 6, 2026 706 707**Special Features**: 708- Matrix theme design 709- Outlook synchronization 710- System monitoring integration 711- Real-time weather display 712- Advanced event conflict detection 713 714--- 715 716## Final Notes 717 718**Version 4.0.0 - Matrix Edition** represents a complete, production-ready calendar plugin with: 719 720- ✨ Beautiful Matrix-themed design 721- Live system monitoring 722- ️ Real-time weather 723- Advanced event management 724- Enterprise Outlook sync 725- Polished UI throughout 726 727**Install it, clear cache, and enjoy your Matrix calendar!** 728 729--- 730 731**Happy Calendaring! ️✨** 732