lightweight, client-only calendar web application. All data persists in the URL hash for instant sharing, No backend required. Optional AES-GCM password protection keeps shared links locked without a server
JavaScript
feat: Add Buy Me a Coffee buttons to the sidebar, mobile quick actions, and mobile drawer, and refactor copy/share buttons into the sidebar.
Supun Lakmal0f7599af9950
diff --git a/index.html b/index.htmlindex 7ad8d4f..23437ad 100644--- a/index.html+++ b/index.html@@ -108,8 +108,6 @@<div class="action-divider desktop-only"></div><button id="add-event" class="primary" type="button" data-i18n="btn.addEvent">Add event</button>- <button id="copy-link" type="button" data-i18n="btn.copyLink">Copy link</button>- <button id="share-qr" type="button" data-i18n="btn.shareQr">Share QR</button><button id="lock-btn" type="button" data-i18n="btn.lock">Lock</button><button id="readonly-btn" type="button" data-i18n="btn.readOnly" aria-pressed="false">Read only</button><button id="world-planner-btn" type="button" class="accent-btn" aria-label="Open World Planner"@@ -142,6 +140,10 @@<button id="mobile-copy-link" type="button" class="quick-action-btn" aria-label="Copy link"><i class="fa-solid fa-copy"></i></button>+ <a href="https://www.buymeacoffee.com/supunlakmal" class="quick-action-btn bmc-mobile-btn" target="_blank"+ rel="noopener" aria-label="Buy me a coffee">+ <i class="fa-solid fa-mug-hot"></i>+ </a><button id="mobile-share-qr" type="button" class="quick-action-btn" aria-label="Share QR"><i class="fa-solid fa-share-nodes"></i></button>@@ -209,6 +211,22 @@<button id="side-panel-close" class="side-close mobile-only" type="button" aria-label="Close details"><i class="fa-solid fa-xmark"></i></button>++ <a href="https://www.buymeacoffee.com/supunlakmal" class="action-link bmc-link sidebar-bmc" target="_blank"+ rel="noopener">+ <i class="fa-solid fa-mug-hot" aria-hidden="true"></i>+ <span>Buy me a coffee</span>+ </a>++ <div class="side-actions-top">+ <button id="copy-link" type="button" class="primary w-100" data-i18n="btn.copyLink">+ <i class="fa-solid fa-copy"></i> <span>Copy link</span>+ </button>+ <button id="share-qr" type="button" class="ghost w-100" data-i18n="btn.shareQr">+ <i class="fa-solid fa-qrcode"></i> <span>Share QR</span>+ </button>+ </div>+<div class="side-card"><h3 id="selected-date-label" class="side-title" data-i18n="panel.selectedDay">Selected day</h3><div id="event-list" class="event-list"></div>@@ -534,6 +552,10 @@rel="noopener"><i class="fa-brands fa-github"></i> <span>GitHub</span></a>+ <a href="https://www.buymeacoffee.com/supunlakmal" class="mobile-drawer-item action-link bmc-link"+ target="_blank" rel="noopener">+ <i class="fa-solid fa-mug-hot"></i> <span>Buy me a coffee</span>+ </a></div><div id="mobile-share-export-section" class="mobile-drawer-section">diff --git a/styles.css b/styles.cssindex c7c7156..d3c8dbd 100644--- a/styles.css+++ b/styles.css@@ -127,6 +127,42 @@ button {transform: translateY(-1px);}+.sidebar-bmc {+ justify-content: center;+ margin-bottom: 8px;+ background: linear-gradient(135deg, #ffdd00 0%, #f7c300 100%);+ color: #111;+ border: none;+ font-size: 0.85rem;+ padding: 10px;+ box-shadow: var(--shadow-md);+}++.sidebar-bmc i {+ color: #111;+}++.sidebar-bmc:hover {+ background: linear-gradient(135deg, #f7c300 0%, #ffdd00 100%);+ box-shadow: var(--shadow-lg);+ transform: translateY(-2px);+}++.side-actions-top {+ display: flex;+ flex-direction: column;+ gap: 8px;+ margin-bottom: 16px;+}++.w-100 {+ width: 100%;+ display: flex;+ align-items: center;+ justify-content: center;+ gap: 8px;+}+.app {height: 100vh;display: flex;@@ -2620,6 +2656,17 @@ body[data-theme="dark"] .ripple {transform: translateY(-1px);}+.bmc-mobile-btn {+ background: linear-gradient(135deg, #ffdd00 0%, #f7c300 100%);+ color: #111 !important;+ border-color: #e6c200;+}++.bmc-mobile-btn:hover {+ background: linear-gradient(135deg, #f7c300 0%, #ffdd00 100%);+ border-color: #d4b000;+}+.quick-action-btn:disabled {opacity: 0.4;cursor: not-allowed;@@ -2819,6 +2866,73 @@ body[data-theme="dark"] .wp-cell.current {box-shadow: 0 0 12px rgba(99, 102, 241, 0.4);}+/* Buy Me a Coffee Button */+.bmc-link {+ background: linear-gradient(135deg, #ffdd00 0%, #ffc800 100%);+ border: 1px solid #e6c200;+ color: #000000 !important;+ font-weight: 600;+ box-shadow: 0 2px 8px rgba(255, 221, 0, 0.3);+ transition: all 0.2s ease;+}++.bmc-link:hover {+ background: linear-gradient(135deg, #ffe333 0%, #ffcc00 100%);+ border-color: #d4b000;+ box-shadow: 0 4px 12px rgba(255, 221, 0, 0.4);+ transform: translateY(-2px);+}++.bmc-link i {+ color: #000000;+}++/* Dark mode adjustments for BMC button */+body[data-theme="dark"] .bmc-link {+ background: linear-gradient(135deg, #ffdd00 0%, #ffc800 100%);+ border-color: #b39700;+ color: #000000 !important;+ box-shadow: 0 2px 8px rgba(255, 221, 0, 0.2);+}++body[data-theme="dark"] .bmc-link:hover {+ background: linear-gradient(135deg, #ffe333 0%, #ffcc00 100%);+ box-shadow: 0 4px 12px rgba(255, 221, 0, 0.35);+}++/* Mobile drawer BMC button */+.mobile-drawer-item.bmc-link {+ background: linear-gradient(135deg, #ffdd00 0%, #ffc800 100%);+ border: 1px solid #e6c200;+ color: #000000 !important;+ margin-top: 4px;+}+.mobile-drawer-item.bmc-link:hover,+.mobile-drawer-item.bmc-link:active {+ background: linear-gradient(135deg, #ffe333 0%, #ffcc00 100%);+}++.mobile-drawer-item.bmc-link i,+.mobile-drawer-item.bmc-link span {+ color: #000000 !important;+}++/* Hide text on smaller screens in top bar, show just icon */+@media (max-width: 1200px) {+ .action-link.bmc-link span {+ display: none;+ }++ .action-link.bmc-link {+ padding: 8px 10px;+ }+}+/* Hide brand text (hash-calendar title) on mobile */+@media (max-width: 768px) {+ .brand-text {+ display: none;+ }+}