-
Notifications
You must be signed in to change notification settings - Fork 15
Expand file tree
/
Copy pathindex.html
More file actions
222 lines (193 loc) · 7.71 KB
/
index.html
File metadata and controls
222 lines (193 loc) · 7.71 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>My-Calendar</title>
<link rel="stylesheet" href="style.css" />
<link rel="icon" type="image/png" href="images/android-chrome-512x512.png">
</head>
<body>
<header class="topbar">
<div class="brand">
<div class="logo" aria-hidden="true">🗓️</div>
<div>
<h1>My-Calendar</h1>
</div>
</div>
</header>
<div id="notifBanner" class="notif-banner" hidden>
<span>🔔 Enable notifications to get reminders for your events — even when this tab is in the background.</span>
<div class="notif-banner-actions">
<button id="notifAllowBtn" class="btn primary" type="button">Enable Notifications</button>
<button id="notifDismissBtn" class="btn ghost" type="button">Dismiss</button>
</div>
</div>
<main class="wrap">
<section class="panel">
<div class="panel-head">
<div>
<h2>Calendar</h2>
<p class="muted">Click a date to view events. Select an event to Edit/Delete from the side.</p>
<div class="monthbar">
<button id="prevBtn" class="btn" type="button" aria-label="Previous month">←</button>
<div class="month-year-group">
<select id="monthSelect" class="month-select" aria-label="Select month">
<option value="0">January</option>
<option value="1">February</option>
<option value="2">March</option>
<option value="3">April</option>
<option value="4">May</option>
<option value="5">June</option>
<option value="6">July</option>
<option value="7">August</option>
<option value="8">September</option>
<option value="9">October</option>
<option value="10">November</option>
<option value="11">December</option>
</select>
<select id="yearSelect" class="year-select" aria-label="Select year"></select>
</div>
<button id="nextBtn" class="btn" type="button" aria-label="Next month">→</button>
<button id="todayBtn" class="btn ghost" type="button">Today</button>
</div>
</div>
<div class="head-right">
<input id="searchInput" class="search" type="search" placeholder="Search events…" />
<button id="themeToggle" class="btn ghost" type="button">🌙 Dark</button>
</div>
</div>
<div class="dow">
<div>Sun</div><div>Mon</div><div>Tue</div>
<div>Wed</div><div>Thu</div><div>Fri</div><div>Sat</div>
</div>
supreme
supreme
master
main
<div id="grid" class="grid" aria-label="Calendar grid"></div>
<div id="noResults" class="no-results" hidden>No events found</div>
<div id="grid" class="grid"></div>
main
</section>
<aside class="panel side">
<div class="panel-head">
<h2>Selected Day</h2>
<p id="dayLabel" class="muted">—</p>
</div>
<div id="selectedEvents" class="day-list"></div>
<div class="panel-head upcoming-heading">
<h2>Upcoming Events</h2>
</div>
<div id="upcomingEvents" class="day-list"></div>
<div class="panel-foot">
<button id="addBtn" class="btn primary" type="button">+ Add Event</button>
<button id="editBtn" class="btn" type="button">Edit</button>
<button id="deleteSideBtn" class="btn danger" type="button">Delete</button>
<button id="exportBtn" class="btn ghost" type="button">📥 Export</button>
<button id="importBtn" class="btn ghost" type="button">📤 Import</button>
<button id="clearAllBtn" class="btn clear-custom" type="button">Clear All Events</button>
</div>
</aside>
</main>
supreme
<!-- Modal -->
<dialog id="eventModal" class="modal" aria-labelledby="modalTitle">
<form id="eventForm" class="modal-form" method="dialog">
<div id="backdrop" class="backdrop" hidden></div>
<dialog id="eventModal" class="modal">
<form id="eventForm" method="dialog">
main
<div class="modal-head">
<div>
<div id="modalTitle" class="modal-title">New event</div>
<div id="modalSub" class="modal-sub">—</div>
</div>
<button id="closeBtn" class="btn ghost" type="button">✕</button>
</div>
<div class="form">
<input type="hidden" id="idInput">
<label class="field">
<span>Event name</span>
<input id="titleInput" required placeholder="Event name" maxlength="100">
</label>
<div class="row">
<label class="field">
<span>Start date</span>
<input id="dateInput" type="date" required>
</label>
<label class="field">
<span>End date</span>
<input id="endDateInput" type="date">
</label>
</div>
<div class="row">
<label class="field">
<span>Start time</span>
<input id="startInput" type="time">
</label>
<label class="field">
<span>End time</span>
<input id="endInput" type="time">
</label>
</div>
<label class="field">
<span>Description</span>
<textarea id="descInput" rows="3" maxlength="500" placeholder="Optional notes"></textarea>
</label>
<div class="row">
<label class="field">
<span>Reminder</span>
<select id="remindInput">
<option value="off">Off</option>
<option value="popup">Popup (day-of alert on open)</option>
<option value="60">🔔 Notify 1 hour before</option>
<option value="30">🔔 Notify 30 mins before</option>
<option value="15">🔔 Notify 15 mins before</option>
</select>
<div class="hint">Passive (🔔) reminders fire as OS notifications even when the tab is backgrounded. Requires notification permission.</div>
</label>
<label class="field">
<span>Color</span>
<select id="colorInput">
<option value="default">Default</option>
<option value="red">Red</option>
<option value="blue">Blue</option>
<option value="green">Green</option>
</select>
</label>
</div>
<div id="conflictBox" class="callout warn" hidden>
⚠️ Time conflict detected with another event.
</div>
</div>
<div class="modal-foot">
<button id="deleteBtn" class="btn danger" type="button" hidden>Delete</button>
<button id="cancelBtn" class="btn ghost" type="button">Cancel</button>
<button class="btn primary" type="submit">Save</button>
</div>
</form>
</dialog>
<dialog id="importModal" class="modal">
<div class="modal-head">
<div>
<div class="modal-title">Import Events</div>
<div class="modal-sub">Upload a JSON file to add events to your calendar.</div>
</div>
<button id="importCloseBtn" class="btn ghost" type="button">✕</button>
</div>
<div class="form">
<label class="field">
<span>Event file</span>
<input type="file" id="importFileInput" accept=".json">
</label>
<div id="importError" class="callout warn" hidden></div>
</div>
<div class="modal-foot">
<button id="importCancelBtn" class="btn ghost" type="button">Cancel</button>
<button id="importConfirmBtn" class="btn primary" type="button" disabled>Import</button>
</div>
</dialog>
<script src="app.js"></script>
</body>
</html>