@tbib-image-viewer/react 0.0.0-stage → 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,3 +1,66 @@
1
- # Temporary Holding Version
1
+ # @tbib-image-viewer/react
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ Interactive React Image Viewer & Swipe Gallery with Hand-Free Annotation Suite (Pen, Highlighter, WebGL Laser, Eraser), pan & zoom, mobile touch gestures, and high-res export.
4
+
5
+ ## Installation
6
+
7
+ ```bash
8
+ npm install @tbib-image-viewer/react @tbib-image-viewer/core @fortawesome/react-fontawesome @fortawesome/free-solid-svg-icons ogl
9
+ ```
10
+
11
+ ## Quick Start
12
+
13
+ ```tsx
14
+ import React from "react";
15
+ import { ImageViewer } from "@tbib-image-viewer/react";
16
+ import "@tbib-image-viewer/react/styles.css";
17
+
18
+ export function App() {
19
+ return (
20
+ <div style={{ height: "600px", width: "100%" }}>
21
+ <ImageViewer
22
+ src="/path/to/image.png"
23
+ theme="dark"
24
+ initialTool="pen"
25
+ initialColor="#ef4444"
26
+ />
27
+ </div>
28
+ );
29
+ }
30
+ ```
31
+
32
+ ## Fullscreen Swipe Lightbox Modal
33
+
34
+ ```tsx
35
+ import React, { useState } from "react";
36
+ import { ImageGalleryLightbox } from "@tbib-image-viewer/react";
37
+ import "@tbib-image-viewer/react/styles.css";
38
+
39
+ export function Gallery() {
40
+ const [isOpen, setIsOpen] = useState(false);
41
+ const items = [
42
+ { id: "1", src: "/img1.png", title: "Slide 1" },
43
+ { id: "2", src: "/img2.png", title: "Slide 2" },
44
+ ];
45
+
46
+ return (
47
+ <>
48
+ <button onClick={() => setIsOpen(true)}>Open Gallery</button>
49
+ <ImageGalleryLightbox
50
+ isOpen={isOpen}
51
+ items={items}
52
+ onClose={() => setIsOpen(false)}
53
+ theme="dark"
54
+ />
55
+ </>
56
+ );
57
+ }
58
+ ```
59
+
60
+ ## Documentation
61
+
62
+ Full documentation & interactive demo: [https://github.com/itzHamza/tbib-image-viewer](https://github.com/itzHamza/tbib-image-viewer)
63
+
64
+ ## License
65
+
66
+ MIT © [TBiB Space](https://tbib.space)
package/dist/index.css ADDED
@@ -0,0 +1,420 @@
1
+ @import "https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap";
2
+
3
+ /* src/styles/index.css */
4
+ :root {
5
+ --tbib-iv-bg: #0b1120;
6
+ --tbib-iv-surface: #131f37;
7
+ --tbib-iv-surface-hover: #1e293b;
8
+ --tbib-iv-border: rgba(148, 163, 184, 0.2);
9
+ --tbib-iv-border-active: rgba(139, 92, 246, 0.6);
10
+ --tbib-iv-text: #f8fafc;
11
+ --tbib-iv-text-muted: #94a3b8;
12
+ --tbib-iv-accent: #8b5cf6;
13
+ --tbib-iv-accent-hover: #7c3aed;
14
+ --tbib-iv-accent-subtle: rgba(139, 92, 246, 0.15);
15
+ --tbib-iv-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5), 0 8px 10px -6px rgba(0, 0, 0, 0.4);
16
+ }
17
+ .tbib-iv-light {
18
+ --tbib-iv-bg: #f8fafc;
19
+ --tbib-iv-surface: #ffffff;
20
+ --tbib-iv-surface-hover: #f1f5f9;
21
+ --tbib-iv-border: rgba(148, 163, 184, 0.35);
22
+ --tbib-iv-border-active: rgba(79, 70, 229, 0.7);
23
+ --tbib-iv-text: #0f172a;
24
+ --tbib-iv-text-muted: #64748b;
25
+ --tbib-iv-accent: #4f46e5;
26
+ --tbib-iv-accent-hover: #4338ca;
27
+ --tbib-iv-accent-subtle: rgba(79, 70, 229, 0.12);
28
+ --tbib-iv-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.08);
29
+ }
30
+ .tbib-iv-container {
31
+ position: relative;
32
+ width: 100%;
33
+ height: 100%;
34
+ min-height: 320px;
35
+ overflow: hidden;
36
+ user-select: none;
37
+ background-color: var(--tbib-iv-bg);
38
+ color: var(--tbib-iv-text);
39
+ font-family:
40
+ "Plus Jakarta Sans",
41
+ -apple-system,
42
+ BlinkMacSystemFont,
43
+ "Segoe UI",
44
+ Roboto,
45
+ Helvetica,
46
+ Arial,
47
+ sans-serif;
48
+ }
49
+ .tbib-iv-container *,
50
+ .tbib-iv-lightbox-overlay * {
51
+ box-sizing: border-box;
52
+ font-family: inherit;
53
+ }
54
+ .tbib-iv-lightbox-overlay {
55
+ position: fixed;
56
+ inset: 0;
57
+ z-index: 9999;
58
+ background-color: rgba(5, 9, 20, 0.94);
59
+ backdrop-filter: blur(8px);
60
+ display: flex;
61
+ flex-direction: column;
62
+ font-family:
63
+ "Plus Jakarta Sans",
64
+ -apple-system,
65
+ BlinkMacSystemFont,
66
+ "Segoe UI",
67
+ Roboto,
68
+ Helvetica,
69
+ Arial,
70
+ sans-serif;
71
+ }
72
+ .tbib-iv-toolbar-wrapper {
73
+ position: absolute;
74
+ top: max(12px, env(safe-area-inset-top));
75
+ left: 0;
76
+ right: 0;
77
+ display: flex;
78
+ flex-direction: column;
79
+ align-items: center;
80
+ gap: 6px;
81
+ z-index: 50;
82
+ padding: 0 12px;
83
+ pointer-events: none;
84
+ }
85
+ .tbib-iv-toolbar {
86
+ pointer-events: auto;
87
+ display: inline-flex;
88
+ align-items: center;
89
+ gap: 4px;
90
+ background: var(--tbib-iv-surface);
91
+ border: 1px solid var(--tbib-iv-border);
92
+ box-shadow: var(--tbib-iv-shadow);
93
+ border-radius: 1rem;
94
+ padding: 6px 8px;
95
+ max-width: calc(100vw - 24px);
96
+ overflow: visible;
97
+ position: relative;
98
+ }
99
+ .tbib-iv-toolbar::-webkit-scrollbar {
100
+ display: none;
101
+ }
102
+ .tbib-iv-subtoolbar {
103
+ pointer-events: auto;
104
+ display: inline-flex;
105
+ align-items: center;
106
+ gap: 8px;
107
+ background: var(--tbib-iv-surface);
108
+ border: 1px solid var(--tbib-iv-border);
109
+ box-shadow: var(--tbib-iv-shadow);
110
+ border-radius: 0.85rem;
111
+ padding: 5px 10px;
112
+ max-width: calc(100vw - 24px);
113
+ overflow-x: auto;
114
+ scrollbar-width: none;
115
+ -webkit-overflow-scrolling: touch;
116
+ animation: tbib-slide-down 0.15s cubic-bezier(0.16, 1, 0.3, 1);
117
+ }
118
+ .tbib-iv-subtoolbar::-webkit-scrollbar {
119
+ display: none;
120
+ }
121
+ @keyframes tbib-slide-down {
122
+ from {
123
+ opacity: 0;
124
+ transform: translateY(-6px);
125
+ }
126
+ to {
127
+ opacity: 1;
128
+ transform: translateY(0);
129
+ }
130
+ }
131
+ .tbib-iv-swatch-btn {
132
+ width: 22px;
133
+ height: 22px;
134
+ border-radius: 50%;
135
+ cursor: pointer;
136
+ border: 2px solid transparent;
137
+ transition: transform 0.15s ease, box-shadow 0.15s ease;
138
+ padding: 0;
139
+ flex-shrink: 0;
140
+ position: relative;
141
+ }
142
+ .tbib-iv-swatch-btn:hover {
143
+ transform: scale(1.15);
144
+ }
145
+ .tbib-iv-swatch-active {
146
+ transform: scale(1.22);
147
+ box-shadow: 0 0 0 2px var(--tbib-iv-surface), 0 0 0 4px var(--tbib-iv-accent);
148
+ border-color: #ffffff;
149
+ }
150
+ .tbib-iv-custom-color-btn {
151
+ width: 22px;
152
+ height: 22px;
153
+ border-radius: 50%;
154
+ position: relative;
155
+ overflow: hidden;
156
+ border: 1px solid var(--tbib-iv-border);
157
+ cursor: pointer;
158
+ display: flex;
159
+ align-items: center;
160
+ justify-content: center;
161
+ flex-shrink: 0;
162
+ }
163
+ .tbib-iv-custom-color-input {
164
+ position: absolute;
165
+ inset: -10px;
166
+ width: 200%;
167
+ height: 200%;
168
+ opacity: 0;
169
+ cursor: pointer;
170
+ }
171
+ .tbib-iv-thickness-group {
172
+ display: inline-flex;
173
+ align-items: center;
174
+ gap: 3px;
175
+ background: rgba(0, 0, 0, 0.2);
176
+ padding: 2px 4px;
177
+ border-radius: 0.6rem;
178
+ border: 1px solid var(--tbib-iv-border);
179
+ }
180
+ .tbib-iv-thickness-btn {
181
+ display: inline-flex;
182
+ align-items: center;
183
+ gap: 4px;
184
+ padding: 3px 8px;
185
+ border-radius: 0.45rem;
186
+ font-size: 11px;
187
+ font-weight: 500;
188
+ border: 1px solid transparent;
189
+ background: transparent;
190
+ color: var(--tbib-iv-text-muted);
191
+ cursor: pointer;
192
+ transition: all 0.15s ease;
193
+ flex-shrink: 0;
194
+ }
195
+ .tbib-iv-thickness-btn:hover {
196
+ color: var(--tbib-iv-text);
197
+ background: var(--tbib-iv-surface-hover);
198
+ }
199
+ .tbib-iv-thickness-active {
200
+ background: var(--tbib-iv-accent-subtle) !important;
201
+ color: var(--tbib-iv-accent) !important;
202
+ border-color: var(--tbib-iv-border-active) !important;
203
+ font-weight: 700;
204
+ }
205
+ .tbib-iv-divider {
206
+ width: 1px;
207
+ height: 22px;
208
+ background-color: var(--tbib-iv-border);
209
+ margin: 0 4px;
210
+ flex-shrink: 0;
211
+ }
212
+ .tbib-iv-btn {
213
+ display: inline-flex;
214
+ align-items: center;
215
+ justify-content: center;
216
+ min-width: 36px;
217
+ height: 36px;
218
+ padding: 0 8px;
219
+ border-radius: 0.75rem;
220
+ border: 1px solid transparent;
221
+ background: transparent;
222
+ color: var(--tbib-iv-text);
223
+ font-size: 13px;
224
+ font-weight: 500;
225
+ cursor: pointer;
226
+ transition: all 0.15s ease-in-out;
227
+ touch-action: manipulation;
228
+ flex-shrink: 0;
229
+ }
230
+ .tbib-iv-btn:hover {
231
+ background-color: var(--tbib-iv-surface-hover);
232
+ }
233
+ .tbib-iv-btn:active {
234
+ transform: scale(0.96);
235
+ }
236
+ .tbib-iv-btn:focus-visible {
237
+ outline: 2px solid var(--tbib-iv-accent);
238
+ outline-offset: 2px;
239
+ }
240
+ .tbib-iv-btn-active {
241
+ background: var(--tbib-iv-accent-subtle) !important;
242
+ color: var(--tbib-iv-accent) !important;
243
+ border-color: var(--tbib-iv-border-active) !important;
244
+ font-weight: 600;
245
+ }
246
+ .tbib-iv-btn:disabled {
247
+ opacity: 0.4;
248
+ cursor: not-allowed;
249
+ transform: none;
250
+ }
251
+ .tbib-iv-tabular {
252
+ font-variant-numeric: tabular-nums;
253
+ font-size: 12px;
254
+ color: var(--tbib-iv-text-muted);
255
+ font-weight: 600;
256
+ padding: 0 6px;
257
+ white-space: nowrap;
258
+ }
259
+ .tbib-iv-popover {
260
+ position: absolute;
261
+ top: calc(100% + 8px);
262
+ background: var(--tbib-iv-surface);
263
+ border: 1px solid var(--tbib-iv-border);
264
+ box-shadow: var(--tbib-iv-shadow);
265
+ border-radius: 0.75rem;
266
+ padding: 6px;
267
+ z-index: 100;
268
+ display: flex;
269
+ backdrop-filter: blur(12px);
270
+ animation: tbib-slide-down 0.15s cubic-bezier(0.16, 1, 0.3, 1);
271
+ }
272
+ .tbib-iv-stage {
273
+ position: relative;
274
+ width: 100%;
275
+ height: 100%;
276
+ flex: 1;
277
+ display: flex;
278
+ align-items: center;
279
+ justify-content: center;
280
+ overflow: hidden;
281
+ touch-action: none;
282
+ }
283
+ .tbib-iv-stage-inner {
284
+ position: relative;
285
+ will-change: transform;
286
+ transform-origin: center center;
287
+ user-select: none;
288
+ }
289
+ .tbib-iv-image {
290
+ display: block;
291
+ max-width: 100%;
292
+ max-height: 100%;
293
+ object-fit: contain;
294
+ pointer-events: none;
295
+ border-radius: 4px;
296
+ }
297
+ .tbib-iv-annotation-svg {
298
+ position: absolute;
299
+ inset: 0;
300
+ width: 100%;
301
+ height: 100%;
302
+ overflow: visible;
303
+ }
304
+ .tbib-iv-laser-layer {
305
+ position: absolute;
306
+ top: 0;
307
+ left: 0;
308
+ width: 100%;
309
+ height: 100%;
310
+ pointer-events: auto;
311
+ touch-action: none;
312
+ cursor: crosshair;
313
+ z-index: 30;
314
+ overflow: hidden;
315
+ }
316
+ .tbib-iv-laser-canvas {
317
+ position: absolute;
318
+ top: 0;
319
+ left: 0;
320
+ width: 100%;
321
+ height: 100%;
322
+ display: block;
323
+ pointer-events: none;
324
+ }
325
+ .tbib-iv-nav-prev,
326
+ .tbib-iv-nav-next {
327
+ position: absolute;
328
+ top: 50%;
329
+ transform: translateY(-50%);
330
+ z-index: 40;
331
+ width: 44px;
332
+ height: 44px;
333
+ border-radius: 50%;
334
+ background: var(--tbib-iv-surface);
335
+ border: 1px solid var(--tbib-iv-border);
336
+ color: var(--tbib-iv-text);
337
+ box-shadow: var(--tbib-iv-shadow);
338
+ display: flex;
339
+ align-items: center;
340
+ justify-content: center;
341
+ cursor: pointer;
342
+ transition: all 0.2s;
343
+ }
344
+ .tbib-iv-nav-prev {
345
+ left: 16px;
346
+ }
347
+ .tbib-iv-nav-next {
348
+ right: 16px;
349
+ }
350
+ .tbib-iv-nav-prev:hover,
351
+ .tbib-iv-nav-next:hover {
352
+ background: var(--tbib-iv-surface-hover);
353
+ transform: translateY(-50%) scale(1.08);
354
+ }
355
+ .tbib-iv-thumbnail-strip {
356
+ position: absolute;
357
+ bottom: max(12px, env(safe-area-inset-bottom));
358
+ left: 50%;
359
+ transform: translateX(-50%);
360
+ display: flex;
361
+ align-items: center;
362
+ gap: 8px;
363
+ background: var(--tbib-iv-surface);
364
+ border: 1px solid var(--tbib-iv-border);
365
+ border-radius: 1rem;
366
+ padding: 6px 10px;
367
+ z-index: 50;
368
+ max-width: min(90vw, 600px);
369
+ overflow-x: auto;
370
+ scrollbar-width: none;
371
+ }
372
+ .tbib-iv-thumbnail-item {
373
+ width: 48px;
374
+ height: 48px;
375
+ border-radius: 0.5rem;
376
+ overflow: hidden;
377
+ border: 2px solid transparent;
378
+ cursor: pointer;
379
+ flex-shrink: 0;
380
+ opacity: 0.6;
381
+ transition: all 0.2s;
382
+ }
383
+ .tbib-iv-thumbnail-item:hover {
384
+ opacity: 0.9;
385
+ }
386
+ .tbib-iv-thumbnail-item-active {
387
+ border-color: var(--tbib-iv-accent);
388
+ opacity: 1;
389
+ }
390
+ .tbib-iv-thumbnail-img {
391
+ width: 100%;
392
+ height: 100%;
393
+ object-fit: cover;
394
+ }
395
+ @media (max-width: 640px) {
396
+ .tbib-iv-toolbar {
397
+ padding: 4px 6px;
398
+ gap: 2px;
399
+ }
400
+ .tbib-iv-subtoolbar {
401
+ padding: 4px 6px;
402
+ gap: 4px;
403
+ }
404
+ .tbib-iv-btn {
405
+ min-width: 34px;
406
+ height: 34px;
407
+ padding: 0 6px;
408
+ }
409
+ .tbib-iv-nav-prev {
410
+ left: 8px;
411
+ width: 38px;
412
+ height: 38px;
413
+ }
414
+ .tbib-iv-nav-next {
415
+ right: 8px;
416
+ width: 38px;
417
+ height: 38px;
418
+ }
419
+ }
420
+ /*# sourceMappingURL=index.css.map */
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/styles/index.css"],"sourcesContent":["/* TBiB Image Viewer & Gallery Stylesheet (DESIGN.md Compliant) */\n@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');\n\n:root {\n --tbib-iv-bg: #0b1120;\n --tbib-iv-surface: #131f37;\n --tbib-iv-surface-hover: #1e293b;\n --tbib-iv-border: rgba(148, 163, 184, 0.2);\n --tbib-iv-border-active: rgba(139, 92, 246, 0.6);\n --tbib-iv-text: #f8fafc;\n --tbib-iv-text-muted: #94a3b8;\n --tbib-iv-accent: #8b5cf6;\n --tbib-iv-accent-hover: #7c3aed;\n --tbib-iv-accent-subtle: rgba(139, 92, 246, 0.15);\n --tbib-iv-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5), 0 8px 10px -6px rgba(0, 0, 0, 0.4);\n}\n\n.tbib-iv-light {\n --tbib-iv-bg: #f8fafc;\n --tbib-iv-surface: #ffffff;\n --tbib-iv-surface-hover: #f1f5f9;\n --tbib-iv-border: rgba(148, 163, 184, 0.35);\n --tbib-iv-border-active: rgba(79, 70, 229, 0.7);\n --tbib-iv-text: #0f172a;\n --tbib-iv-text-muted: #64748b;\n --tbib-iv-accent: #4f46e5;\n --tbib-iv-accent-hover: #4338ca;\n --tbib-iv-accent-subtle: rgba(79, 70, 229, 0.12);\n --tbib-iv-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.08);\n}\n\n/* Container Root */\n.tbib-iv-container {\n position: relative;\n width: 100%;\n height: 100%;\n min-height: 320px;\n overflow: hidden;\n user-select: none;\n background-color: var(--tbib-iv-bg);\n color: var(--tbib-iv-text);\n font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif;\n}\n\n.tbib-iv-container *,\n.tbib-iv-lightbox-overlay * {\n box-sizing: border-box;\n font-family: inherit;\n}\n\n/* Modal Lightbox Overlay */\n.tbib-iv-lightbox-overlay {\n position: fixed;\n inset: 0;\n z-index: 9999;\n background-color: rgba(5, 9, 20, 0.94);\n backdrop-filter: blur(8px);\n display: flex;\n flex-direction: column;\n font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif;\n}\n\n/* Top Toolbar Wrapper: Stacks Main toolbar & sub-shelf cleanly */\n.tbib-iv-toolbar-wrapper {\n position: absolute;\n top: max(12px, env(safe-area-inset-top));\n left: 0;\n right: 0;\n display: flex;\n flex-direction: column;\n align-items: center;\n gap: 6px;\n z-index: 50;\n padding: 0 12px;\n pointer-events: none;\n}\n\n/* Main Toolbar */\n.tbib-iv-toolbar {\n pointer-events: auto;\n display: inline-flex;\n align-items: center;\n gap: 4px;\n background: var(--tbib-iv-surface);\n border: 1px solid var(--tbib-iv-border);\n box-shadow: var(--tbib-iv-shadow);\n border-radius: 1rem;\n padding: 6px 8px;\n max-width: calc(100vw - 24px);\n overflow: visible;\n position: relative;\n}\n\n.tbib-iv-toolbar::-webkit-scrollbar {\n display: none;\n}\n\n/* Secondary Sub-toolbar for Colors & Thickness */\n.tbib-iv-subtoolbar {\n pointer-events: auto;\n display: inline-flex;\n align-items: center;\n gap: 8px;\n background: var(--tbib-iv-surface);\n border: 1px solid var(--tbib-iv-border);\n box-shadow: var(--tbib-iv-shadow);\n border-radius: 0.85rem;\n padding: 5px 10px;\n max-width: calc(100vw - 24px);\n overflow-x: auto;\n scrollbar-width: none;\n -webkit-overflow-scrolling: touch;\n animation: tbib-slide-down 0.15s cubic-bezier(0.16, 1, 0.3, 1);\n}\n\n.tbib-iv-subtoolbar::-webkit-scrollbar {\n display: none;\n}\n\n@keyframes tbib-slide-down {\n from {\n opacity: 0;\n transform: translateY(-6px);\n }\n to {\n opacity: 1;\n transform: translateY(0);\n }\n}\n\n/* Direct Color Swatch Button */\n.tbib-iv-swatch-btn {\n width: 22px;\n height: 22px;\n border-radius: 50%;\n cursor: pointer;\n border: 2px solid transparent;\n transition: transform 0.15s ease, box-shadow 0.15s ease;\n padding: 0;\n flex-shrink: 0;\n position: relative;\n}\n\n.tbib-iv-swatch-btn:hover {\n transform: scale(1.15);\n}\n\n.tbib-iv-swatch-active {\n transform: scale(1.22);\n box-shadow: 0 0 0 2px var(--tbib-iv-surface), 0 0 0 4px var(--tbib-iv-accent);\n border-color: #ffffff;\n}\n\n/* Color input button */\n.tbib-iv-custom-color-btn {\n width: 22px;\n height: 22px;\n border-radius: 50%;\n position: relative;\n overflow: hidden;\n border: 1px solid var(--tbib-iv-border);\n cursor: pointer;\n display: flex;\n align-items: center;\n justify-content: center;\n flex-shrink: 0;\n}\n\n.tbib-iv-custom-color-input {\n position: absolute;\n inset: -10px;\n width: 200%;\n height: 200%;\n opacity: 0;\n cursor: pointer;\n}\n\n/* Thickness Option Buttons */\n.tbib-iv-thickness-group {\n display: inline-flex;\n align-items: center;\n gap: 3px;\n background: rgba(0, 0, 0, 0.2);\n padding: 2px 4px;\n border-radius: 0.6rem;\n border: 1px solid var(--tbib-iv-border);\n}\n\n.tbib-iv-thickness-btn {\n display: inline-flex;\n align-items: center;\n gap: 4px;\n padding: 3px 8px;\n border-radius: 0.45rem;\n font-size: 11px;\n font-weight: 500;\n border: 1px solid transparent;\n background: transparent;\n color: var(--tbib-iv-text-muted);\n cursor: pointer;\n transition: all 0.15s ease;\n flex-shrink: 0;\n}\n\n.tbib-iv-thickness-btn:hover {\n color: var(--tbib-iv-text);\n background: var(--tbib-iv-surface-hover);\n}\n\n.tbib-iv-thickness-active {\n background: var(--tbib-iv-accent-subtle) !important;\n color: var(--tbib-iv-accent) !important;\n border-color: var(--tbib-iv-border-active) !important;\n font-weight: 700;\n}\n\n/* Toolbar Divider */\n.tbib-iv-divider {\n width: 1px;\n height: 22px;\n background-color: var(--tbib-iv-border);\n margin: 0 4px;\n flex-shrink: 0;\n}\n\n/* Toolbar Action Button */\n.tbib-iv-btn {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n min-width: 36px;\n height: 36px;\n padding: 0 8px;\n border-radius: 0.75rem;\n border: 1px solid transparent;\n background: transparent;\n color: var(--tbib-iv-text);\n font-size: 13px;\n font-weight: 500;\n cursor: pointer;\n transition: all 0.15s ease-in-out;\n touch-action: manipulation;\n flex-shrink: 0;\n}\n\n.tbib-iv-btn:hover {\n background-color: var(--tbib-iv-surface-hover);\n}\n\n.tbib-iv-btn:active {\n transform: scale(0.96);\n}\n\n.tbib-iv-btn:focus-visible {\n outline: 2px solid var(--tbib-iv-accent);\n outline-offset: 2px;\n}\n\n.tbib-iv-btn-active {\n background: var(--tbib-iv-accent-subtle) !important;\n color: var(--tbib-iv-accent) !important;\n border-color: var(--tbib-iv-border-active) !important;\n font-weight: 600;\n}\n\n.tbib-iv-btn:disabled {\n opacity: 0.4;\n cursor: not-allowed;\n transform: none;\n}\n\n/* Badge & Numbers */\n.tbib-iv-tabular {\n font-variant-numeric: tabular-nums;\n font-size: 12px;\n color: var(--tbib-iv-text-muted);\n font-weight: 600;\n padding: 0 6px;\n white-space: nowrap;\n}\n\n/* Popovers & Dropdowns */\n.tbib-iv-popover {\n position: absolute;\n top: calc(100% + 8px);\n background: var(--tbib-iv-surface);\n border: 1px solid var(--tbib-iv-border);\n box-shadow: var(--tbib-iv-shadow);\n border-radius: 0.75rem;\n padding: 6px;\n z-index: 100;\n display: flex;\n backdrop-filter: blur(12px);\n animation: tbib-slide-down 0.15s cubic-bezier(0.16, 1, 0.3, 1);\n}\n\n/* Viewport Stage */\n.tbib-iv-stage {\n position: relative;\n width: 100%;\n height: 100%;\n flex: 1;\n display: flex;\n align-items: center;\n justify-content: center;\n overflow: hidden;\n touch-action: none;\n}\n\n.tbib-iv-stage-inner {\n position: relative;\n will-change: transform;\n transform-origin: center center;\n user-select: none;\n}\n\n/* Image Element */\n.tbib-iv-image {\n display: block;\n max-width: 100%;\n max-height: 100%;\n object-fit: contain;\n pointer-events: none;\n border-radius: 4px;\n}\n\n/* Annotation SVG Layer */\n.tbib-iv-annotation-svg {\n position: absolute;\n inset: 0;\n width: 100%;\n height: 100%;\n overflow: visible;\n}\n\n/* Laser Layer: strictly absolute over image, never pushing layout */\n.tbib-iv-laser-layer {\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n pointer-events: auto;\n touch-action: none;\n cursor: crosshair;\n z-index: 30;\n overflow: hidden;\n}\n\n.tbib-iv-laser-canvas {\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n display: block;\n pointer-events: none;\n}\n\n/* Nav arrows on sides */\n.tbib-iv-nav-prev,\n.tbib-iv-nav-next {\n position: absolute;\n top: 50%;\n transform: translateY(-50%);\n z-index: 40;\n width: 44px;\n height: 44px;\n border-radius: 50%;\n background: var(--tbib-iv-surface);\n border: 1px solid var(--tbib-iv-border);\n color: var(--tbib-iv-text);\n box-shadow: var(--tbib-iv-shadow);\n display: flex;\n align-items: center;\n justify-content: center;\n cursor: pointer;\n transition: all 0.2s;\n}\n\n.tbib-iv-nav-prev {\n left: 16px;\n}\n\n.tbib-iv-nav-next {\n right: 16px;\n}\n\n.tbib-iv-nav-prev:hover,\n.tbib-iv-nav-next:hover {\n background: var(--tbib-iv-surface-hover);\n transform: translateY(-50%) scale(1.08);\n}\n\n/* Bottom Thumbnail Strip */\n.tbib-iv-thumbnail-strip {\n position: absolute;\n bottom: max(12px, env(safe-area-inset-bottom));\n left: 50%;\n transform: translateX(-50%);\n display: flex;\n align-items: center;\n gap: 8px;\n background: var(--tbib-iv-surface);\n border: 1px solid var(--tbib-iv-border);\n border-radius: 1rem;\n padding: 6px 10px;\n z-index: 50;\n max-width: min(90vw, 600px);\n overflow-x: auto;\n scrollbar-width: none;\n}\n\n.tbib-iv-thumbnail-item {\n width: 48px;\n height: 48px;\n border-radius: 0.5rem;\n overflow: hidden;\n border: 2px solid transparent;\n cursor: pointer;\n flex-shrink: 0;\n opacity: 0.6;\n transition: all 0.2s;\n}\n\n.tbib-iv-thumbnail-item:hover {\n opacity: 0.9;\n}\n\n.tbib-iv-thumbnail-item-active {\n border-color: var(--tbib-iv-accent);\n opacity: 1;\n}\n\n.tbib-iv-thumbnail-img {\n width: 100%;\n height: 100%;\n object-fit: cover;\n}\n\n/* Small Screens / Mobile Specific Tweaks */\n@media (max-width: 640px) {\n .tbib-iv-toolbar {\n padding: 4px 6px;\n gap: 2px;\n }\n .tbib-iv-subtoolbar {\n padding: 4px 6px;\n gap: 4px;\n }\n .tbib-iv-btn {\n min-width: 34px;\n height: 34px;\n padding: 0 6px;\n }\n .tbib-iv-nav-prev {\n left: 8px;\n width: 38px;\n height: 38px;\n }\n .tbib-iv-nav-next {\n right: 8px;\n width: 38px;\n height: 38px;\n }\n}\n"],"mappings":";;;AAGA;AACE,gBAAc;AACd,qBAAmB;AACnB,2BAAyB;AACzB,oBAAkB,KAAK,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE;AACtC,2BAAyB,KAAK,GAAG,EAAE,EAAE,EAAE,GAAG,EAAE;AAC5C,kBAAgB;AAChB,wBAAsB;AACtB,oBAAkB;AAClB,0BAAwB;AACxB,2BAAyB,KAAK,GAAG,EAAE,EAAE,EAAE,GAAG,EAAE;AAC5C,oBAAkB,EAAE,KAAK,KAAK,KAAK,KAAK,CAAC,EA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AI;AAChB,WAAS;AACT,eAAa;AACb,mBAAiB;AACjB,UAAQ;AACR,cAAY,IAAI;AAClB;AAEA,CApBC;AAqBC,QAAM;AACR;AAEA,CAvBC;AAwBC,SAAO;AACT;AAEA,CA5BC,gBA4BgB;AACjB,CA5BC,gBA4BgB;AACf,cAAY,IAAI;AAChB,aAAW,WAAW,MAAM,MAAM;AACpC;AAGA,CAAC;AACC,YAAU;AACV,UAAQ,IAAI,IAAI,EAAE,IAAI;AACtB,QAAM;AACN,aAAW,WAAW;AACtB,WAAS;AACT,eAAa;AACb,OAAK;AACL,cAAY,IAAI;AAChB,UAAQ,IAAI,MAAM,IAAI;AACtB,iBAAe;AACf,WAAS,IAAI;AACb,WAAS;AACT,aAAW,IAAI,IAAI,EAAE;AACrB,cAAY;AACZ,mBAAiB;AACnB;AAEA,CAAC;AACC,SAAO;AACP,UAAQ;AACR,iBAAe;AACf,YAAU;AACV,UAAQ,IAAI,MAAM;AAClB,UAAQ;AACR,eAAa;AACb,WAAS;AACT,cAAY,IAAI;AAClB;AAEA,CAZC,sBAYsB;AACrB,WAAS;AACX;AAEA,CAAC;AACC,gBAAc,IAAI;AAClB,WAAS;AACX;AAEA,CAAC;AACC,SAAO;AACP,UAAQ;AACR,cAAY;AACd;AAGA,QAAO,WAAY;AACjB,GA5WD;AA6WG,aAAS,IAAI;AACb,SAAK;AACP;AACA,GA5VD;AA6VG,aAAS,IAAI;AACb,SAAK;AACP;AACA,GAhOD;AAiOG,eAAW;AACX,YAAQ;AACR,aAAS,EAAE;AACb;AACA,GA/FD;AAgGG,UAAM;AACN,WAAO;AACP,YAAQ;AACV;AACA,GAnGD;AAoGG,WAAO;AACP,WAAO;AACP,YAAQ;AACV;AACF;","names":[]}
@@ -0,0 +1,175 @@
1
+ import { GalleryItem, InteractionMode, SlideAnnotations, AnnotationStroke, DrawTool, NormalizedPoint, TransformState } from '@tbib-image-viewer/core';
2
+ export { AnnotationStroke, DrawTool, ExportOptions, GalleryItem, InteractionMode, SlideAnnotations, TransformState } from '@tbib-image-viewer/core';
3
+ import * as React$1 from 'react';
4
+ import React__default, { HTMLAttributes } from 'react';
5
+
6
+ interface ImageViewerProps {
7
+ /** Source image URL */
8
+ src: string;
9
+ alt?: string;
10
+ className?: string;
11
+ style?: React.CSSProperties;
12
+ /** Theme: 'dark' (default Midnight Ocean) or 'light' (Warm Parchment) */
13
+ theme?: "dark" | "light";
14
+ /** Initial tool selected */
15
+ initialTool?: InteractionMode;
16
+ /** Initial stroke color */
17
+ initialColor?: string;
18
+ /** Initial stroke width */
19
+ initialStrokeWidth?: number;
20
+ /** Show top toolbar */
21
+ showToolbar?: boolean;
22
+ /** Allow hand-free drawings (pen, highlighter, eraser) */
23
+ enableAnnotations?: boolean;
24
+ /** Allow laser pointer mode */
25
+ enableLaser?: boolean;
26
+ /** Unique ID for storing strokes (defaults to src URL) */
27
+ slideId?: string;
28
+ /** Initial annotations */
29
+ initialAnnotations?: AnnotationStroke[];
30
+ /** Callback fired whenever annotations change */
31
+ onAnnotationsChange?: (strokes: AnnotationStroke[]) => void;
32
+ /** Custom children to render on top of viewer */
33
+ children?: React.ReactNode;
34
+ }
35
+ interface ImageGalleryLightboxProps {
36
+ /** Array of gallery images */
37
+ items: GalleryItem[];
38
+ /** Index of currently active slide (0-based) */
39
+ activeIndex?: number;
40
+ /** Whether the modal is open */
41
+ isOpen: boolean;
42
+ /** Called when the user closes the lightbox */
43
+ onClose: () => void;
44
+ /** Called when the active index changes */
45
+ onIndexChange?: (newIndex: number) => void;
46
+ /** Theme */
47
+ theme?: "dark" | "light";
48
+ /** Initial tool */
49
+ initialTool?: InteractionMode;
50
+ /** Initial color */
51
+ initialColor?: string;
52
+ /** Enable bottom thumbnail strip */
53
+ showThumbnails?: boolean;
54
+ /** Initial annotations for all slides */
55
+ initialAnnotations?: SlideAnnotations[];
56
+ /** Callback fired whenever any slide's annotations update */
57
+ onAnnotationsChange?: (slideId: string, strokes: AnnotationStroke[]) => void;
58
+ }
59
+
60
+ declare const ImageViewer: React__default.FC<ImageViewerProps>;
61
+
62
+ declare const ImageGalleryLightbox: React__default.FC<ImageGalleryLightboxProps>;
63
+
64
+ interface ImageToolbarProps {
65
+ activeTool: InteractionMode;
66
+ onToolChange: (tool: InteractionMode) => void;
67
+ color: string;
68
+ onColorChange: (color: string) => void;
69
+ strokeWidth: number;
70
+ onStrokeWidthChange: (width: number) => void;
71
+ canUndo: boolean;
72
+ canRedo: boolean;
73
+ onUndo: () => void;
74
+ onRedo: () => void;
75
+ onClear: () => void;
76
+ zoomScale: number;
77
+ onZoomIn: () => void;
78
+ onZoomOut: () => void;
79
+ onZoomReset: () => void;
80
+ onRotate: () => void;
81
+ onDownloadAnnotated: () => Promise<void>;
82
+ onDownloadClean: () => Promise<void>;
83
+ onExportJson?: () => void;
84
+ onClose?: () => void;
85
+ isFullscreen?: boolean;
86
+ onToggleFullscreen?: () => void;
87
+ currentIndex?: number;
88
+ totalImages?: number;
89
+ }
90
+ declare const ImageToolbar: React__default.FC<ImageToolbarProps>;
91
+
92
+ interface AnnotationCanvasProps {
93
+ width: number;
94
+ height: number;
95
+ strokes: AnnotationStroke[];
96
+ activeTool: DrawTool | "hand";
97
+ color: string;
98
+ strokeWidth: number;
99
+ onStrokeComplete: (stroke: AnnotationStroke) => void;
100
+ onEraseStroke: (point: NormalizedPoint) => void;
101
+ }
102
+ declare const AnnotationCanvas: React__default.FC<AnnotationCanvasProps>;
103
+
104
+ interface LaserCursorLayerProps extends Omit<HTMLAttributes<HTMLDivElement>, "color"> {
105
+ color?: string;
106
+ secondaryColor?: string;
107
+ trailLength?: number;
108
+ trailWidth?: number;
109
+ trailTaper?: number;
110
+ followSpeed?: number;
111
+ glowIntensity?: number;
112
+ glowSpread?: number;
113
+ hotspot?: number;
114
+ brightness?: number;
115
+ opacity?: number;
116
+ pulseSpeed?: number;
117
+ noiseStrength?: number;
118
+ idleFade?: boolean;
119
+ idleTimeout?: number;
120
+ fadeDuration?: number;
121
+ enabled?: boolean;
122
+ }
123
+ declare const LaserCursorLayer: React__default.FC<LaserCursorLayerProps>;
124
+
125
+ interface ColorPickerProps {
126
+ color: string;
127
+ onChange: (color: string) => void;
128
+ }
129
+ declare const ColorPicker: React__default.FC<ColorPickerProps>;
130
+
131
+ interface StrokeWidthPickerProps {
132
+ strokeWidth: number;
133
+ onChange: (width: number) => void;
134
+ }
135
+ declare const StrokeWidthPicker: React__default.FC<StrokeWidthPickerProps>;
136
+
137
+ interface DownloadMenuProps {
138
+ onDownloadAnnotated: () => Promise<void>;
139
+ onDownloadClean: () => Promise<void>;
140
+ onExportJson?: () => void;
141
+ }
142
+ declare const DownloadMenu: React__default.FC<DownloadMenuProps>;
143
+
144
+ interface ThumbnailStripProps {
145
+ items: GalleryItem[];
146
+ activeIndex: number;
147
+ onSelect: (index: number) => void;
148
+ }
149
+ declare const ThumbnailStrip: React__default.FC<ThumbnailStripProps>;
150
+
151
+ declare function useImageTransform(): {
152
+ transform: TransformState;
153
+ setTransform: React$1.Dispatch<React$1.SetStateAction<TransformState>>;
154
+ zoomIn: () => void;
155
+ zoomOut: () => void;
156
+ resetTransform: () => void;
157
+ rotateClockwise: () => void;
158
+ panBy: (dx: number, dy: number) => void;
159
+ handleWheel: (e: React.WheelEvent) => void;
160
+ handleTouchStart: (e: React.TouchEvent) => void;
161
+ handleTouchMove: (e: React.TouchEvent) => void;
162
+ handleTouchEnd: () => void;
163
+ };
164
+
165
+ interface SwipeHandlers {
166
+ onSwipeLeft: () => void;
167
+ onSwipeRight: () => void;
168
+ enabled?: boolean;
169
+ }
170
+ declare function useSwipeGesture({ onSwipeLeft, onSwipeRight, enabled }: SwipeHandlers): {
171
+ onTouchStart: (e: React.TouchEvent) => void;
172
+ onTouchEnd: (e: React.TouchEvent) => void;
173
+ };
174
+
175
+ export { AnnotationCanvas, type AnnotationCanvasProps, ColorPicker, type ColorPickerProps, DownloadMenu, type DownloadMenuProps, ImageGalleryLightbox, type ImageGalleryLightboxProps, ImageToolbar, type ImageToolbarProps, ImageViewer, type ImageViewerProps, LaserCursorLayer, type LaserCursorLayerProps, StrokeWidthPicker, type StrokeWidthPickerProps, type SwipeHandlers, ThumbnailStrip, type ThumbnailStripProps, useImageTransform, useSwipeGesture };