-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpopup.html
More file actions
168 lines (150 loc) · 7.34 KB
/
popup.html
File metadata and controls
168 lines (150 loc) · 7.34 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>WordMap</title>
<link rel="stylesheet" href="popup.css">
</head>
<body>
<main class="popup-shell">
<header class="topbar">
<div class="brand">
<img class="brand-logo" src="assets/logo.svg" alt="WordMap logo">
<div class="brand-copy">
<h1 class="brand-title" data-i18n="appTitleCompact"></h1>
<p class="brand-subtitle" data-i18n="appSubtitleCompact"></p>
</div>
</div>
<div class="toolbar">
<button id="uiLangToggle" class="toolbar-btn toolbar-btn--lang" type="button">
<svg class="toolbar-btn__icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true">
<circle cx="12" cy="12" r="9"></circle>
<path d="M3 12h18"></path>
<path d="M12 3a14.5 14.5 0 0 1 0 18"></path>
<path d="M12 3a14.5 14.5 0 0 0 0 18"></path>
</svg>
<span id="uiLangToggleText"></span>
</button>
<a id="sponsorBtn" class="toolbar-btn toolbar-btn--icon toolbar-btn--heart" href="https://www.paypal.com/paypalme/robin326753" target="_blank" rel="noreferrer">
<svg class="toolbar-btn__icon" viewBox="0 0 24 24" fill="currentColor" aria-hidden="true">
<path d="M12 21s-6.8-4.35-9.18-8.08C.76 9.74 2 5.9 5.57 4.63c2.14-.76 4.12-.1 5.43 1.42 1.31-1.52 3.29-2.18 5.43-1.42C20 5.9 21.24 9.74 19.18 12.92 16.8 16.65 12 21 12 21Z"></path>
</svg>
</a>
<button id="shortcutBtn" class="toolbar-btn toolbar-btn--icon" type="button">
<svg class="toolbar-btn__icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true">
<rect x="3.5" y="6" width="17" height="12" rx="2.5"></rect>
<path d="M7 10h2"></path>
<path d="M11 10h2"></path>
<path d="M15 10h2"></path>
<path d="M7 14h10"></path>
</svg>
</button>
</div>
</header>
<section class="guide-strip" aria-label="Quick guide">
<div class="guide-step"><span class="guide-step__index">1</span><span class="guide-step__label" data-i18n="stepSetup"></span></div>
<div class="guide-step"><span class="guide-step__index">2</span><span class="guide-step__label" data-i18n="stepLanguage"></span></div>
<div class="guide-step"><span class="guide-step__index">3</span><span class="guide-step__label" data-i18n="stepCapture"></span></div>
</section>
<section id="missingConfigBanner" class="notice-banner" hidden>
<span class="notice-banner__icon">!</span>
<span class="notice-banner__text" data-i18n="requiredHintDetailed"></span>
</section>
<section class="main-card">
<div class="section-label-wrap">
<div class="section-label" data-i18n="sectionSetupTitle"></div>
<span class="mini-badge" data-i18n="ocrUiSeparatedBadge"></span>
</div>
<div class="field field--full" id="apiBaseUrlField">
<label for="apiBaseUrl" data-i18n="apiBaseUrlLabel"></label>
<input type="text" id="apiBaseUrl" data-i18n-placeholder="apiBaseUrlPlaceholder" autocomplete="off" spellcheck="false">
</div>
<div class="grid-2">
<div class="field" id="modelNameField">
<label for="modelName" data-i18n="modelNameLabel"></label>
<input type="text" id="modelName" data-i18n-placeholder="modelNamePlaceholder" autocomplete="off" spellcheck="false">
</div>
<div class="field">
<label for="apiKey" data-i18n="apiKeyLabel"></label>
<input type="password" id="apiKey" data-i18n-placeholder="apiKeyPlaceholder" autocomplete="off">
</div>
</div>
<div class="grid-2">
<div class="field">
<label for="sourceLang" data-i18n="sourceLangLabel"></label>
<select id="sourceLang"></select>
</div>
<div class="field">
<label for="targetLang" data-i18n="targetLangLabel"></label>
<select id="targetLang"></select>
</div>
</div>
<div class="mobile-strip">
<div class="mobile-strip__copy">
<div class="mobile-strip__title" data-i18n="mobileQuickTitle"></div>
<div class="mobile-strip__hint" data-i18n="mobileQuickHint"></div>
</div>
<div class="mobile-strip__controls">
<label class="switch" for="mobileQuickEnabled">
<input id="mobileQuickEnabled" type="checkbox">
<span class="switch__slider"></span>
<span class="switch__label" data-i18n="mobileQuickToggle"></span>
</label>
<div class="field field--compact">
<label for="mobileQuickMode" data-i18n="mobileQuickModeLabel"></label>
<select id="mobileQuickMode"></select>
</div>
</div>
</div>
<details id="advancedDetails" class="advanced-details">
<summary id="advancedSummary"></summary>
<div class="field field--full">
<label for="ocrApiKey" data-i18n="ocrApiKeyLabel"></label>
<input type="password" id="ocrApiKey" data-i18n-placeholder="ocrApiKeyPlaceholder" autocomplete="off">
</div>
</details>
<div class="action-head">
<div>
<div class="section-label" data-i18n="quickActions"></div>
<p class="mini-copy" data-i18n="quickActionsDesc"></p>
</div>
</div>
<div class="capture-grid">
<button id="drawPencilBtn" class="capture-btn capture-btn--blue" type="button">
<span class="capture-btn__icon" aria-hidden="true">
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round">
<path d="M4 20l3.2-.8 9.9-9.9a2.4 2.4 0 0 0-3.4-3.4L3.8 15.8 3 19z"></path>
<path d="M12.6 6.9l4.5 4.5"></path>
<path d="M14 20h6"></path>
</svg>
</span>
<span class="capture-btn__copy">
<span class="capture-btn__title" data-i18n="drawPencilLabel"></span>
<span class="capture-btn__hint" data-i18n="drawPencilDescShort"></span>
</span>
</button>
<button id="drawRectBtn" class="capture-btn capture-btn--purple" type="button">
<span class="capture-btn__icon" aria-hidden="true">
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.9" stroke-linecap="round" stroke-linejoin="round">
<rect x="4.5" y="6" width="15" height="12" rx="2.5"></rect>
<path d="M8 10h8"></path>
<path d="M8 14h5"></path>
</svg>
</span>
<span class="capture-btn__copy">
<span class="capture-btn__title" data-i18n="drawRectLabel"></span>
<span class="capture-btn__hint" data-i18n="drawRectDescShort"></span>
</span>
</button>
</div>
<div class="panel-meta">
<span id="status" class="save-state" hidden></span>
<a class="text-link" href="https://ocr.space/OCRAPI" target="_blank" rel="noreferrer" data-i18n="ocrKeyHelpLinkShort"></a>
</div>
</section>
</main>
<script src="i18n.js"></script>
<script src="popup.js"></script>
</body>
</html>