-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpopup.html
More file actions
126 lines (119 loc) · 4.63 KB
/
Copy pathpopup.html
File metadata and controls
126 lines (119 loc) · 4.63 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Color Palette Extractor</title>
<link rel="stylesheet" href="styles/popup.css">
</head>
<body>
<div class="container">
<!-- Header -->
<header class="header">
<div class="header-content">
<div class="logo">
<div class="logo-icon">🎨</div>
<h1>Color Palette</h1>
</div>
<button id="refresh-btn" class="refresh-btn" title="Refresh Palette">
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
<path d="M23 4v6h-6M1 20v-6h6M20.49 9A9 9 0 0 0 5.64 5.64L1 10m22 4l-4.64 4.36A9 9 0 0 1 3.51 15"/>
</svg>
</button>
</div>
<div class="stats">
<span id="color-count" class="color-count">0 colors</span>
<span id="page-url" class="page-url"></span>
</div>
<div class="header-accent"></div>
</header>
<!-- Loading State -->
<div id="loading" class="loading">
<div class="loading-spinner"></div>
<p>Extracting colors...</p>
</div>
<!-- Empty State -->
<div id="empty-state" class="empty-state hidden">
<div class="empty-icon">🎨</div>
<h3>No Colors Found</h3>
<p>No colors detected on this page. Try refreshing or navigating to a different page.</p>
<button id="retry-btn" class="retry-btn">Try Again</button>
</div>
<!-- Color Palette -->
<main id="palette-content" class="palette-content hidden">
<div class="palette-controls">
<div class="view-toggle">
<button id="grid-view" class="view-btn active" data-view="grid">
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
<rect x="3" y="3" width="7" height="7"/>
<rect x="14" y="3" width="7" height="7"/>
<rect x="14" y="14" width="7" height="7"/>
<rect x="3" y="14" width="7" height="7"/>
</svg>
Grid
</button>
<button id="list-view" class="view-btn" data-view="list">
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
<line x1="8" y1="6" x2="21" y2="6"/>
<line x1="8" y1="12" x2="21" y2="12"/>
<line x1="8" y1="18" x2="21" y2="18"/>
<line x1="3" y1="6" x2="3.01" y2="6"/>
<line x1="3" y1="12" x2="3.01" y2="12"/>
<line x1="3" y1="18" x2="3.01" y2="18"/>
</svg>
List
</button>
</div>
<div class="sort-controls">
<select id="sort-select" class="sort-select">
<option value="frequency">Most Used</option>
<option value="hue">By Hue</option>
<option value="brightness">By Brightness</option>
<option value="contrast">By Contrast</option>
</select>
</div>
</div>
<div id="palette-grid" class="palette-grid"></div>
<div id="palette-list" class="palette-list hidden"></div>
</main>
<!-- Export Section -->
<footer class="export-section">
<div class="export-controls">
<select id="export-select" class="export-select">
<option value="json">JSON</option>
<option value="scss">SCSS Variables</option>
<option value="css">CSS Variables</option>
<option value="csv">CSV</option>
</select>
<button id="export-btn" class="export-btn">
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
<path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"/>
<polyline points="7,10 12,15 17,10"/>
<line x1="12" y1="15" x2="12" y2="3"/>
</svg>
Export
</button>
</div>
<div class="export-info">
<span class="info-text">All data stays local - no tracking</span>
</div>
</footer>
</div>
<!-- Color Detail Modal -->
<div id="color-modal" class="color-modal hidden">
<div class="modal-overlay"></div>
<div class="modal-content">
<div class="modal-header">
<h3>Color Details</h3>
<button id="close-modal" class="close-btn">×</button>
</div>
<div class="modal-body">
<div id="modal-color-preview" class="color-preview"></div>
<div id="modal-color-info" class="color-info"></div>
<div id="modal-contrast-tests" class="contrast-tests"></div>
</div>
</div>
</div>
<script src="popup.js" type="module"></script>
</body>
</html>