forked from Coder-s-OG-s/Global_Notes-workspace
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
862 lines (807 loc) · 40.3 KB
/
index.html
File metadata and controls
862 lines (807 loc) · 40.3 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
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<title>Global Notes Workspace V2</title>
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap" rel="stylesheet">
<link rel="stylesheet" href="CSS/index.css?v=3.3" />
<link rel="stylesheet" href="CSS/tagManager.css" />
<link rel="manifest" href="/manifest.json">
<!-- Google Site Verification -->
<meta name="google-site-verification" content="WbUo_0T0kC4YmSlPrwLvwl-ez09WyeheFaD1YThQZqY" />
<!-- SEO Meta Tags -->
<meta name="description"
content="Global Notes Workspace - A powerful, offline-capable workspace for organizing your thoughts, notes, and ideas. Designed for productivity with a clean, distraction-free interface.">
<meta name="keywords"
content="notes, workspace, productivity, offline notes, organization, ideas, writing, personal knowledge management">
<meta name="author" content="Global Notes Workspace">
<meta name="theme-color" content="#0f172a">
<!-- Open Graph / Facebook -->
<meta property="og:type" content="website">
<meta property="og:url" content="https://jai-ramdev-timber-and-plywood.vercel.app/">
<meta property="og:title" content="Global Notes Workspace - Organize ideas. Work smarter.">
<meta property="og:description"
content="A simple, powerful workspace for your thoughts. Designed for productivity. Built with care.">
<meta property="og:image" content="https://jai-ramdev-timber-and-plywood.vercel.app/assets/images/logo.png">
<!-- Twitter -->
<meta property="twitter:card" content="summary_large_image">
<meta property="twitter:url" content="https://jai-ramdev-timber-and-plywood.vercel.app/">
<meta property="twitter:title" content="Global Notes Workspace - Organize ideas. Work smarter.">
<meta property="twitter:description"
content="A simple, powerful workspace for your thoughts. Designed for productivity. Built with care.">
<meta property="twitter:image" content="https://jai-ramdev-timber-and-plywood.vercel.app/assets/images/logo.png">
<script>
// Force Redirect from 0.0.0.0 to localhost to ensure Secure Context
if (window.location.hostname === '0.0.0.0') {
window.location.hostname = 'localhost';
}
</script>
</head>
<body>
<div class="sidebar-overlay" id="sidebar-overlay"></div>
<header class="app-header">
<!-- Primary Navbar: 3 Zones -->
<div class="navbar-primary">
<!-- Zone 1: Left (Menu + Brand) -->
<!-- Zone 1: Left (Menu + Brand) -->
<div class="navbar-left">
<button class="btn ghost icon-only mobile-toggle" id="sidebar-toggle" aria-label="Toggle Menu">
<svg class="icon" viewBox="0 0 24 24">
<line x1="3" y1="12" x2="21" y2="12"></line>
<line x1="3" y1="6" x2="21" y2="6"></line>
<line x1="3" y1="18" x2="21" y2="18"></line>
</svg>
</button>
<div class="brand">
<div class="logo-wrapper">
<img src="assets/images/logo.png" alt="Logo" class="logo-img" />
</div>
<h1>Global Notes Workspace</h1>
</div>
</div>
<!-- Zone 2: Center (Search + Date) -->
<div class="navbar-center">
<div class="search-container">
<svg class="search-icon" viewBox="0 0 24 24">
<circle cx="11" cy="11" r="8"></circle>
<line x1="21" y1="21" x2="16.65" y2="16.65"></line>
</svg>
<input type="search" id="search" class="search-input" placeholder="Search notes…" aria-label="Search notes" />
</div>
<div class="date-filter smart-calendar-container" id="search-date-filter">
<div class="date-input-wrapper">
<input type="date" id="date-filter" class="date-filter-input" aria-label="Select note date" />
<button class="calendar-icon-btn" id="calendar-toggle" aria-label="Toggle calendar">
<div class="cal-icon-header" id="cal-icon-month">JAN</div>
<div class="cal-icon-body" id="cal-icon-day">01</div>
</button>
</div>
<!-- Custom Calendar Popup -->
<div class="smart-calendar-popup hidden" id="smart-calendar">
<div class="real-time-date-display" id="real-time-date-display"></div>
<div class="calendar-header">
<button class="cal-nav-btn" id="cal-prev">←</button>
<span class="cal-current-month" id="cal-month-year">December 2025</span>
<button class="cal-nav-btn" id="cal-next">→</button>
</div>
<div class="calendar-grid" id="calendar-grid">
<!-- Days will be injected here -->
</div>
<div class="calendar-footer">
<button class="btn tiny ghost" id="cal-today">Today</button>
<button class="btn tiny ghost" id="clear-date" style="margin-left: auto;">Clear</button>
</div>
</div>
</div>
</div>
<!-- Zone 3: Right (Actions + Profile) -->
<div class="navbar-right">
<button class="btn primary" id="new-note">
<span class="btn-icon-wrapper">
<svg class="icon" viewBox="0 0 24 24" style="width: 16px; height: 16px;">
<line x1="12" y1="5" x2="12" y2="19"></line>
<line x1="5" y1="12" x2="19" y2="12"></line>
</svg>
</span>
<span class="btn-text">New Note</span>
</button>
<button class="btn ghost icon-only" id="export" title="Export Notes">
<svg class="icon" viewBox="0 0 24 24">
<path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"></path>
<polyline points="7 10 12 15 17 10"></polyline>
<line x1="12" y1="15" x2="12" y2="3"></line>
</svg>
</button>
<!-- Preferences Dropdown Trigger -->
<div class="dropdown-wrapper" id="preferences-dropdown-wrapper">
<button class="btn ghost icon-only" id="preferences-toggle" title="Preferences">
<svg class="icon" viewBox="0 0 24 24">
<circle cx="12" cy="12" r="3"></circle>
<path
d="M19.4 15a1.65 1.65 0 0 0 .33 1.82l.06.06a2 2 0 0 1 0 2.83 2 2 0 0 1-2.83 0l-.06-.06a1.65 1.65 0 0 0-1.82-.33 1.65 1.65 0 0 0-1 1.51V21a2 2 0 0 1-2 2 2 2 0 0 1-2-2v-.09A1.65 1.65 0 0 0 9 19.4a1.65 1.65 0 0 0-1.82.33l-.06.06a2 2 0 0 1-2.83 0 2 2 0 0 1 0-2.83l.06-.06a1.65 1.65 0 0 0 .33-1.82 1.65 1.65 0 0 0-1.51-1H3a2 2 0 0 1-2-2 2 2 0 0 1 2-2h.09A1.65 1.65 0 0 0 4.6 9a1.65 1.65 0 0 0-.33-1.82l-.06-.06a2 2 0 0 1 0-2.83 2 2 0 0 1 2.83 0l.06.06a1.65 1.65 0 0 0 1.82.33H9a1.65 1.65 0 0 0 1-1.51V3a2 2 0 0 1 2-2 2 2 0 0 1 2 2v.09a1.65 1.65 0 0 0 1 1.51 1.65 1.65 0 0 0 1.82-.33l.06-.06a2 2 0 0 1 2.83 0 2 2 0 0 1 0 2.83l-.06.06a1.65 1.65 0 0 0-.33 1.82V9a1.65 1.65 0 0 0 1.51 1H21a2 2 0 0 1 2 2 2 2 0 0 1-2 2h-.09a1.65 1.65 0 0 0-1.51 1z">
</path>
</svg>
</button>
<!-- Dropdown Content -->
<div class="dropdown-menu hidden" id="preferences-menu">
<div class="dropdown-header">Preferences</div>
<div class="dropdown-section">
<label class="dropdown-label">Theme</label>
<div class="theme-options-grid">
<button class="theme-option active" data-value="amoled-dark" title="AMOLED Dark">
<span class="theme-check">✓</span>
<span class="theme-name">Dark</span>
</button>
<button class="theme-option" data-value="nature-green" title="Nature Green">
<span class="theme-check">✓</span>
<span class="theme-name">Nature</span>
</button>
<button class="theme-option" data-value="corporate-gray" title="Corporate Gray">
<span class="theme-check">✓</span>
<span class="theme-name">Gray</span>
</button>
<button class="theme-option" data-value="minimal-white" title="Minimal White">
<span class="theme-check">✓</span>
<span class="theme-name">White</span>
</button>
</div>
<!-- Hidden select for JS compatibility -->
<select id="theme-selector" class="hidden" aria-label="UI Theme">
<option value="amoled-dark">AMOLED Dark</option>
<option value="nature-green">Nature Green</option>
<option value="corporate-gray">Corporate Gray</option>
<option value="minimal-white">Minimal White</option>
</select>
</div>
<div class="dropdown-divider"></div>
<div class="dropdown-section">
<div class="toggle-row">
<label for="auto-save-toggle" class="dropdown-label">Auto Save</label>
<label class="toggle-switch" for="auto-save-toggle">
<input type="checkbox" id="auto-save-toggle">
<span class="toggle-slider"></span>
</label>
</div>
</div>
</div>
</div>
<!-- Profile / Auth -->
<div class="auth-wrapper">
<button class="btn secondary" id="login">Sign In</button>
<div class="profile-dropdown-wrapper hidden" id="user-pill">
<button class="profile-avatar-btn" id="profile-toggle">
<img id="header-avatar" class="header-avatar" src="" alt="Profile" />
</button>
<div class="dropdown-menu hidden" id="profile-menu">
<div class="dropdown-header user-info">
<span class="user-name-display" id="user-name"></span>
<span class="user-role">Free Plan</span>
</div>
<div class="dropdown-divider"></div>
<button class="dropdown-item" id="open-profile-modal">
<svg class="icon" viewBox="0 0 24 24">
<path d="M20 21v-2a4 4 0 0 0-4-4H8a4 4 0 0 0-4 4v2"></path>
<circle cx="12" cy="7" r="4"></circle>
</svg>
Profile Settings
</button>
<div class="dropdown-divider"></div>
<button class="dropdown-item danger-text" id="logout">
<svg class="icon" viewBox="0 0 24 24">
<path d="M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4"></path>
<polyline points="16 17 21 12 16 7"></polyline>
<line x1="21" y1="12" x2="9" y2="12"></line>
</svg>
Log Out
</button>
</div>
</div>
</div>
</div>
</div>
<!-- Secondary Navbar: Filters -->
<div class="navbar-secondary">
<div class="filters-container">
<div class="filters">
<button class="chip active" data-filter="all" aria-pressed="true">All</button>
<button class="chip" data-filter="work">Work</button>
<button class="chip" data-filter="personal">Personal</button>
<button class="chip" data-filter="ideas">Ideas</button>
<button class="chip" data-filter="todo">To‑do</button>
</div>
</div>
</div>
</header>
<main class="layout">
<!-- Sidebar -->
<aside class="app-sidebar" id="app-sidebar">
<!-- 1. Sidebar Header (Collapse Only) -->
<div class="sidebar-header">
<div class="sidebar-top-row">
<span class="user-workspace-name">My Workspace</span>
<button class="btn ghost icon-only mobile-close" id="sidebar-close" aria-label="Close Menu">
<svg class="icon" viewBox="0 0 24 24">
<line x1="18" y1="6" x2="6" y2="18"></line>
<line x1="6" y1="6" x2="18" y2="18"></line>
</svg>
</button>
</div>
</div>
<!-- 2. Library Section (Navigation Hub) -->
<div class="sidebar-section library-section">
<div class="section-header">
<span class="section-title">Library</span>
</div>
<ul class="library-list">
<li class="library-item active" id="nav-all-notes">
<button class="library-btn" title="All Notes">
<svg class="library-icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"
stroke-linecap="round" stroke-linejoin="round">
<path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"></path>
<polyline points="14 2 14 8 20 8"></polyline>
<line x1="16" y1="13" x2="8" y2="13"></line>
<line x1="16" y1="17" x2="8" y2="17"></line>
<polyline points="10 9 9 9 8 9"></polyline>
</svg>
<span>All Notes</span>
</button>
</li>
<li class="library-item" id="nav-recent">
<button class="library-btn" title="Recent Notes">
<svg class="library-icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"
stroke-linecap="round" stroke-linejoin="round">
<circle cx="12" cy="12" r="10"></circle>
<polyline points="12 6 12 12 16 14"></polyline>
</svg>
<span>Recent</span>
</button>
</li>
<li class="library-item" id="nav-favorites">
<button class="library-btn" title="Favorites">
<svg class="library-icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"
stroke-linecap="round" stroke-linejoin="round">
<polygon
points="12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2">
</polygon>
</svg>
<span>Favorites</span>
</button>
</li>
<li class="library-item" id="nav-archived">
<button class="library-btn" title="Archived">
<svg class="library-icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"
stroke-linecap="round" stroke-linejoin="round">
<path d="M21 8v13H3V8"></path>
<path d="M1 3h22v5H1z"></path>
<path d="M10 12h4"></path>
</svg>
<span>Archived</span>
</button>
</li>
</ul>
</div>
<!-- 3. Folders Section -->
<div class="sidebar-section folders-section">
<div class="section-header">
<span class="section-title">Folders</span>
<button class="folder-pill-btn" id="create-folder" title="New Folder" aria-label="New Folder">
<span class="folder-pill-inner">
<!-- Folder + icon -->
<svg class="folder-pill-icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.2"
stroke-linecap="round" stroke-linejoin="round">
<path d="M22 19a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h5l2 3h9a2 2 0 0 1 2 2z" />
<line x1="12" y1="11" x2="12" y2="17" />
<line x1="9" y1="14" x2="15" y2="14" />
</svg>
<span class="folder-pill-label">New Folder</span>
</span>
</button>
</div>
<ul class="folders-list" id="folders-list">
<!-- Injected via JS -->
</ul>
</div>
<!-- 3. Notes List -->
<div class="sidebar-section notes-section">
<div class="section-header">
<span class="section-title">NOTES</span>
</div>
<ul class="notes-list" id="notes-list">
<!-- Injected via JS -->
</ul>
</div>
<!-- Resizer Handle -->
<div class="sidebar-resizer" id="sidebar-resizer"></div>
</aside>
<!-- Editor: note details -->
<section class="editor">
<header class="editor-bar">
<input type="text" class="title-input" id="title" placeholder="Untitled note" aria-label="Note title" />
<div class="editor-actions">
<div class="tags-input">
<div class="tags-chips" id="tags">
<!-- Tags will be injected here -->
</div>
<div class="tag-manager-container">
<button class="btn-icon circular" id="add-tag-btn" aria-label="Add tag" title="Add tag"
style="width: 28px; height: 28px; border-radius: 50%; border: 1px dashed var(--border);">
<svg class="icon" style="width: 14px; height: 14px;" viewBox="0 0 24 24">
<line x1="12" y1="5" x2="12" y2="19"></line>
<line x1="5" y1="12" x2="19" y2="12"></line>
</svg>
</button>
<!-- Tag Menu Popover -->
<div id="tag-menu" class="tag-menu-popover hidden">
<div class="tag-menu-header">
<input type="text" id="tag-search" placeholder="Search tags..." aria-label="Search tags"
autocomplete="off">
</div>
<div class="tag-menu-list" id="tag-menu-list">
<!-- Tag options will be injected here -->
</div>
<div class="tag-menu-footer">
<button class="btn tiny ghost full-width" id="create-new-tag-btn">
+ Create new label
</button>
</div>
</div>
</div>
</div>
<div class="buttons">
<!-- AI Quick Popover -->
<div class="editor-quick-tool" id="editor-ai-tool">
<button class="ai-pill-btn" id="editor-ai-trigger" title="AI Assistant" aria-label="AI Assistant">
<span class="ai-pill-inner">
<!-- Sparkle / Gemini-style icon -->
<svg class="ai-pill-icon" viewBox="0 0 24 24" fill="currentColor" xmlns="http://www.w3.org/2000/svg">
<path
d="M12 2.5C12 2.5 13.5 7.5 17 9C13.5 10.5 12 15.5 12 15.5C12 15.5 10.5 10.5 7 9C10.5 7.5 12 2.5 12 2.5Z" />
<path
d="M5.5 14C5.5 14 6.3 16.7 8.5 17.5C6.3 18.3 5.5 21 5.5 21C5.5 21 4.7 18.3 2.5 17.5C4.7 16.7 5.5 14 5.5 14Z"
opacity="0.7" />
<path
d="M18.5 2C18.5 2 19.1 4 20.5 4.5C19.1 5 18.5 7 18.5 7C18.5 7 17.9 5 16.5 4.5C17.9 4 18.5 2 18.5 2Z"
opacity="0.6" />
</svg>
<span class="ai-pill-label">AI</span>
</span>
</button>
<div class="editor-tool-popover" id="editor-ai-popover">
<div class="editor-tool-popover-header">
<span>AI Assistant</span>
<button class="editor-tool-popover-close" data-close="editor-ai-popover" aria-label="Close">✕</button>
</div>
<textarea id="editor-ai-prompt" class="editor-tool-input"
placeholder="Ask AI to write, summarize, or explain..." rows="3"></textarea>
<button class="editor-tool-generate-btn" id="editor-ai-generate-btn">
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round"
stroke-linejoin="round" style="width:12px;height:12px;flex-shrink:0;">
<path
d="M12 2l3.09 6.26L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l6.91-1.01L12 2z" />
</svg>
Generate
</button>
</div>
</div>
<!-- Mail Quick Popover -->
<div class="editor-quick-tool" id="editor-mail-tool">
<button class="mail-pill-btn" id="editor-mail-trigger" title="Mail Writer" aria-label="Mail Writer">
<span class="mail-pill-inner">
<!-- Envelope icon -->
<svg class="mail-pill-icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.2"
stroke-linecap="round" stroke-linejoin="round">
<rect x="2" y="4" width="20" height="16" rx="3" />
<path d="m22 7-8.97 5.7a1.94 1.94 0 0 1-2.06 0L2 7" />
</svg>
<span class="mail-pill-label">Mail</span>
</span>
</button>
<div class="editor-tool-popover" id="editor-mail-popover">
<div class="editor-tool-popover-header">
<span>Mail Writer</span>
<button class="editor-tool-popover-close" data-close="editor-mail-popover"
aria-label="Close">✕</button>
</div>
<input type="email" id="editor-mail-sender" class="editor-tool-input editor-tool-input-sm"
placeholder="Your Email" />
<input type="email" id="editor-mail-recipient" class="editor-tool-input editor-tool-input-sm"
placeholder="Recipient Email" />
<textarea id="editor-mail-prompt" class="editor-tool-input" placeholder="What is this email about?"
rows="3"></textarea>
<button class="editor-tool-generate-btn" id="editor-mail-generate-btn">
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round"
stroke-linejoin="round" style="width:12px;height:12px;flex-shrink:0;">
<path d="M22 2L11 13M22 2l-7 20-4-9-9-4 20-7z" />
</svg>
Draft in Gmail
</button>
</div>
</div>
<button class="btn btn-icon" id="toggle-favorite" aria-label="Toggle favorite" title="Toggle favorite">
<svg class="icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"
stroke-linecap="round" stroke-linejoin="round">
<polygon
points="12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2">
</polygon>
</svg>
</button>
<button class="btn secondary" id="share-note" aria-label="Share note">Share</button>
<button class="btn" id="duplicate-note">Duplicate</button>
<button class="btn danger" id="delete-note">Delete</button>
<button class="btn primary" id="save-note" aria-label="Save note">
<svg class="icon" style="width: 16px; height: 16px; color: white;" viewBox="0 0 24 24">
<path d="M19 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h11l5 5v11a2 2 0 0 1-2 2z"></path>
<polyline points="17 21 17 13 7 13 7 21"></polyline>
<polyline points="7 3 7 8 15 8"></polyline>
</svg>
</button>
</div>
</div>
</header>
<div class="editor-body">
<div class="editor-toolbar" aria-label="Text formatting controls">
<div class="toolbar-controls">
<div class="toolbar-group">
<button class="btn tiny ghost" id="edit-undo" type="button" aria-label="Undo" title="Undo">
<svg class="icon" style="width: 14px; height: 14px;" viewBox="0 0 24 24">
<path d="M3 7v6h6"></path>
<path d="M21 17a9 9 0 0 0-9-9 9 9 0 0 0-6 2.3L3 13"></path>
</svg>
</button>
<button class="btn tiny ghost" id="edit-redo" type="button" aria-label="Redo" title="Redo">
<svg class="icon" style="width: 14px; height: 14px;" viewBox="0 0 24 24">
<path d="M21 7v6h-6"></path>
<path d="M3 17a9 9 0 0 1 9-9 9 9 0 0 1 6 2.3l3 4.7"></path>
</svg>
</button>
</div>
<div class="toolbar-group">
<label for="text-size" class="text-size-label">Size:</label>
<select id="text-size" class="select tiny" aria-label="Text size">
<option value="12">12 px</option>
<option value="13">13 px</option>
<option value="14">14 px</option>
<option value="15" selected>15 px</option>
<option value="16">16 px</option>
<option value="17">17 px</option>
<option value="18">18 px</option>
<option value="19">19 px</option>
<option value="20">20 px</option>
<option value="21">21 px</option>
<option value="22">22 px</option>
<option value="23">23 px</option>
<option value="24">24 px</option>
</select>
</div>
<div class="toolbar-group">
<label for="text-color" class="text-size-label">Color:</label>
<select id="text-color" class="select tiny" aria-label="Text color">
<option value="" selected>Default</option>
<option value="#000000">Black</option>
<option value="#2d3436">Dark gray</option>
<option value="#ff6b6b">Red</option>
<option value="#45b7d1">Blue</option>
<option value="#96ceb4">Green</option>
<option value="#dda0dd">Purple</option>
</select>
<input type="color" id="custom-text-color" class="color-picker-tiny" title="Custom color" />
</div>
<div class="toolbar-group">
<label for="highlight-color" class="text-size-label">Highlight:</label>
<select id="highlight-color" class="select tiny" aria-label="Highlight color">
<option value="" selected>None</option>
<option value="#FFFF00">Neon Yellow</option>
<option value="#39FF14">Neon Green</option>
<option value="#00FFFF">Cyan</option>
<option value="#FF00FF">Magenta</option>
<option value="#FF5F1F">Neon Orange</option>
<option value="#FF69B4">Hot Pink</option>
</select>
</div>
<div class="toolbar-group">
<label for="note-theme" class="text-size-label">Card:</label>
<select id="note-theme" class="select tiny" aria-label="Note card theme">
<option value="classic-blue">Classic Blue</option>
<option value="elegant-purple">Elegant Purple</option>
<option value="forest-green">Forest Green</option>
<option value="sunset-orange">Sunset Orange</option>
<option value="ocean-teal">Ocean Teal</option>
<option value="rose-gold">Rose Gold</option>
<option value="slate-gray">Slate Gray</option>
<option value="crimson-red">Crimson Red</option>
</select>
</div>
<div class="toolbar-group">
<label for="editor-pattern" class="text-size-label">Background:</label>
<select id="editor-pattern" class="select tiny" aria-label="Editor background pattern">
<option value="plain">Plain</option>
<option value="lined">Lined</option>
<option value="grid">Grid</option>
<option value="dotted">Dotted</option>
<option value="blueprint">Blueprint</option>
<option value="sunset">Sunset</option>
<option value="mint">Mint</option>
<option value="lavender">Lavender</option>
</select>
</div>
<select id="format-action" class="select tiny" aria-label="Text formatting">
<option value="">Format</option>
<option value="bold">Bold</option>
<option value="italic">Italic</option>
<option value="underline">Underline</option>
<option value="strikethrough">Strikethrough</option>
<option value="alignLeft">Align Left</option>
<option value="alignCenter">Align Center</option>
<option value="alignRight">Align Right</option>
<option value="bullet">Bullet List</option>
</select>
<select id="edit-action" class="select tiny" aria-label="Edit actions">
<option value="">Edit</option>
<option value="cut">Cut</option>
<option value="copy">Copy</option>
<option value="paste">Paste</option>
</select>
<select id="insert-action" class="select tiny" aria-label="Insert content">
<option value="">Insert</option>
<option value="photo-video">Choose Photo or Video</option>
<option value="audio">Record Audio</option>
<option value="file">Attach File</option>
<option value="sketch">Add Sketch</option>
<option value="shapes">Shapes</option>
<option value="table">Table</option>
</select>
<!-- Hidden inputs for triggers -->
<input type="file" id="media-upload-input" accept="image/*,video/*" hidden />
<input type="file" id="file-upload-input" hidden />
</div>
<button class="btn-icon tiny" id="toolbar-toggle" aria-label="Toggle toolbar">▲</button>
</div>
<div id="content" class="editor-content content-input" contenteditable="true" aria-label="Note content">
<!-- Text will go here -->
</div>
</div>
</section>
</main>
<!-- Profile Modal -->
<dialog id="profile-modal" class="modal">
<div class="modal-content">
<div class="modal-header">
<h2>User Profile</h2>
<button class="btn-icon close-modal" aria-label="Close modal">×</button>
</div>
<div class="profile-body">
<div class="profile-header">
<div class="avatar-wrapper">
<img id="profile-avatar-large" src="" alt="Profile Picture" class="profile-avatar-large">
<button class="btn tiny secondary edit-avatar-btn" id="change-avatar-btn">Change</button>
<input type="file" id="avatar-upload" accept="image/*" hidden>
</div>
<div class="profile-info">
<h3 id="profile-username"></h3>
<span class="member-since" id="member-since">Joined: December 2025</span>
</div>
</div>
<div class="stats-grid">
<div class="stat-card">
<span class="stat-value" id="stat-total-notes">0</span>
<span class="stat-label">Total Notes</span>
</div>
<div class="stat-card">
<span class="stat-value" id="stat-words">0</span>
<span class="stat-label">Words Written</span>
</div>
<div class="stat-card">
<span class="stat-value" id="stat-last-active">Never</span>
<span class="stat-label">Last Active</span>
</div>
</div>
</div>
</div>
</dialog>
<!-- Audio Recorder Modal -->
<dialog id="audio-modal" class="modal">
<div class="modal-content">
<div class="modal-header">
<h2>Record Audio</h2>
<button class="btn-icon close-modal">×</button>
</div>
<div class="audio-body">
<div class="audio-visualizer" id="audio-visualizer">
<!-- Simple waveform visualization -->
<div class="wave"></div>
<div class="wave"></div>
<div class="wave"></div>
<div class="wave"></div>
<div class="wave"></div>
<div class="wave"></div>
<div class="wave"></div>
<div class="wave"></div>
</div>
<div class="audio-controls">
<button class="btn primary" id="start-record-btn">Record</button>
<button class="btn danger" id="stop-record-btn" disabled>Stop</button>
</div>
<div class="audio-status" id="audio-status">Ready to record</div>
</div>
<div class="modal-footer">
<button class="btn secondary close-modal">Cancel</button>
<button class="btn primary" id="save-audio-btn" disabled>Insert Audio</button>
</div>
</div>
</dialog>
<!-- Sketch Pad Modal -->
<dialog id="sketch-modal" class="modal large">
<div class="modal-content">
<div class="modal-header">
<h2>Add Sketch</h2>
<button class="btn-icon close-modal">×</button>
</div>
<div class="sketch-body">
<canvas id="sketch-canvas" width="600" height="400"></canvas>
<div class="sketch-tools">
<button class="btn tiny active" id="tool-pen">Pen</button>
<button class="btn tiny" id="tool-eraser">Eraser</button>
<div class="divider-vertical"></div>
<button class="btn tiny" id="sketch-undo" title="Undo">↺</button>
<button class="btn tiny" id="sketch-redo" title="Redo">↻</button>
<div class="divider-vertical"></div>
<input type="color" id="sketch-color" value="#000000" title="Color">
<input type="range" id="sketch-size" min="1" max="20" value="2" title="Size">
<button class="btn tiny danger" id="tool-clear">Clear</button>
</div>
</div>
<div class="modal-footer">
<button class="btn secondary close-modal">Cancel</button>
<button class="btn primary" id="save-sketch-btn">Insert Sketch</button>
</div>
</div>
</dialog>
<!-- Shapes Modal -->
<dialog id="shapes-modal" class="modal">
<div class="modal-content">
<div class="modal-header">
<h2>Insert Shape</h2>
<button class="btn-icon close-modal">×</button>
</div>
<div class="shapes-body">
<div class="shapes-grid">
<button class="shape-btn" data-shape="rectangle" aria-label="Rectangle">
<svg viewBox="0 0 24 24" width="24" height="24">
<rect x="3" y="5" width="18" height="14" rx="2" stroke="currentColor" fill="none" stroke-width="2" />
</svg>
<span>Rectangle</span>
</button>
<button class="shape-btn" data-shape="circle" aria-label="Circle">
<svg viewBox="0 0 24 24" width="24" height="24">
<circle cx="12" cy="12" r="9" stroke="currentColor" fill="none" stroke-width="2" />
</svg>
<span>Circle</span>
</button>
<button class="shape-btn" data-shape="triangle" aria-label="Triangle">
<svg viewBox="0 0 24 24" width="24" height="24">
<path d="M12 4L21 20H3L12 4Z" stroke="currentColor" fill="none" stroke-width="2" />
</svg>
<span>Triangle</span>
</button>
<button class="shape-btn" data-shape="star" aria-label="Star">
<svg viewBox="0 0 24 24" width="24" height="24">
<path d="M12 2L15.09 8.26L22 9.27L17 14.14L18.18 21.02L12 17.77L5.82 21.02L7 14.14L2 9.27L8.91 8.26L12 2Z"
stroke="currentColor" fill="none" stroke-width="2" />
</svg>
<span>Star</span>
</button>
<button class="shape-btn" data-shape="arrow-right" aria-label="Arrow">
<svg viewBox="0 0 24 24" width="24" height="24">
<path d="M5 12H19M19 12L12 5M19 12L12 19" stroke="currentColor" fill="none" stroke-width="2"
stroke-linecap="round" stroke-linejoin="round" />
</svg>
<span>Arrow</span>
</button>
<button class="shape-btn" data-shape="line" aria-label="Line">
<svg viewBox="0 0 24 24" width="24" height="24">
<line x1="3" y1="12" x2="21" y2="12" stroke="currentColor" stroke-width="2" stroke-linecap="round" />
</svg>
<span>Line</span>
</button>
</div>
</div>
<div class="modal-footer">
<button class="btn secondary close-modal">Cancel</button>
</div>
</div>
</dialog>
<!-- Custom Tag Creation Modal -->
<dialog id="custom-tag-modal" class="modal">
<div class="modal-content">
<div class="modal-header">
<h2>Create new label</h2>
<button class="btn-icon close-modal">×</button>
</div>
<div class="modal-body" style="padding: 20px;">
<div class="form-group" style="margin-bottom: 20px; display: flex; justify-content: center;">
<div class="label-preview-container">
<span class="tag" style="font-size: 14px; padding: 6px 16px;" id="new-tag-preview">Label preview</span>
</div>
</div>
<div class="form-group" style="margin-bottom: 16px;">
<label for="new-tag-name" style="display: block; margin-bottom: 8px; font-weight: 500;">Name</label>
<input type="text" id="new-tag-name" class="search-input"
style="width: 100%; border: 1px solid var(--border);" placeholder="Label name" maxlength="20">
</div>
<div class="form-group" style="margin-bottom: 16px;">
<label for="new-tag-desc" style="display: block; margin-bottom: 8px; font-weight: 500;">Description
(optional)</label>
<input type="text" id="new-tag-desc" class="search-input"
style="width: 100%; border: 1px solid var(--border);" placeholder="Description">
</div>
<div class="form-group" style="margin-bottom: 16px;">
<label style="display: block; margin-bottom: 8px; font-weight: 500;">Color</label>
<div class="color-options" id="new-tag-colors"
style="display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 8px;">
<!-- Color swatches generated by JS -->
</div>
<div class="custom-color-input" style="display: flex; align-items: center; gap: 8px;">
<input type="color" id="new-tag-color-picker"
style="width: 36px; height: 36px; padding: 0; border: none; background: none; cursor: pointer;">
<span id="new-tag-color-hex" style="font-family: monospace; color: var(--text-dim);">#000000</span>
</div>
</div>
</div>
<div class="modal-footer">
<button class="btn secondary close-modal">Cancel</button>
<button class="btn primary" id="save-new-tag-btn">Create label</button>
</div>
</div>
</dialog>
<!-- Share Modal -->
<dialog id="share-modal" class="modal">
<div class="modal-content">
<div class="modal-header">
<h2>Share Note</h2>
<button class="btn-icon close-modal">×</button>
</div>
<div class="share-body"
style="display: flex; flex-direction: column; align-items: stretch; gap: 15px; padding: 25px;">
<p style="text-align: center; color: var(--text-muted); margin-bottom: 5px;">
Share this note directly as text via:
</p>
<a id="share-whatsapp" href="#" target="_blank" class="btn full-width"
style="background-color: #25D366; color: white; text-decoration: none; display: flex; align-items: center; justify-content: center; gap: 10px; border: none;">
<span style="font-size: 1.2em;">💬</span> Share on WhatsApp
</a>
<a id="share-email" href="#" class="btn full-width"
style="background-color: #EA4335; color: white; text-decoration: none; display: flex; align-items: center; justify-content: center; gap: 10px; border: none;">
<span style="font-size: 1.2em;">✉️</span> Share via Email
</a>
<div style="height: 1px; background: var(--border); margin: 5px 0;"></div>
<button id="share-copy-text" class="btn secondary full-width"
style="display: flex; align-items: center; justify-content: center; gap: 10px;">
<span style="font-size: 1.2em;">📋</span> Copy Text to Clipboard
</button>
</div>
<div class="modal-footer">
<button class="btn secondary close-modal">Close</button>
</div>
</div>
</dialog>
<footer class="global-footer">
<p>Global Notes Workspace — Organize ideas. Work smarter. A simple, powerful workspace for your thoughts, designed
for productivity, built with care.</p>
</footer>
<link rel="stylesheet" href="CSS/footer.css">
<script src="https://cdn.jsdelivr.net/npm/@supabase/supabase-js@2/dist/umd/supabase.min.js"></script>
<script type="text/javascript" src="JS/vendor/lz-string.min.js"></script>
<script type="text/javascript" src="JS/vendor/qrcode.min.js"></script>
<script type="module" src="JS/notesApp.js?v=2.3"></script>
<script>
if ('serviceWorker' in navigator) {
navigator.serviceWorker.register('sw.js')
.then(() => console.log('Service Worker Registered'))
.catch((err) => console.log('SW Registration Failed', err));
}
</script>
</body>
</html>