yet-another-react-lightbox 3.14.0 → 3.15.1
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 +3 -3
- package/dist/index.js +20 -20
- package/dist/plugins/thumbnails/index.js +4 -6
- package/dist/plugins/video/index.js +1 -3
- package/dist/plugins/zoom/index.js +3 -11
- package/dist/types.d.ts +1 -1
- package/package.json +167 -167
package/README.md
CHANGED
|
@@ -5,9 +5,9 @@ extendable.
|
|
|
5
5
|
|
|
6
6
|
## Overview
|
|
7
7
|
|
|
8
|
-
[](https://www.npmjs.com/package/yet-another-react-lightbox)
|
|
9
|
-
[](https://bundlephobia.com/package/yet-another-react-lightbox)
|
|
10
|
-
[](https://github.com/igordanchenko/yet-another-react-lightbox/blob/main/LICENSE)
|
|
8
|
+
[](https://www.npmjs.com/package/yet-another-react-lightbox)
|
|
9
|
+
[](https://bundlephobia.com/package/yet-another-react-lightbox)
|
|
10
|
+
[](https://github.com/igordanchenko/yet-another-react-lightbox/blob/main/LICENSE)
|
|
11
11
|
|
|
12
12
|
- **Built for React:** works with React 18, 17 and 16.8.0+
|
|
13
13
|
- **UX:** supports keyboard, mouse, touchpad and touchscreen navigation
|
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
import * as React from 'react';
|
|
3
|
-
import { ACTION_CLOSE, IMAGE_FIT_CONTAIN, MODULE_CONTROLLER, IMAGE_FIT_COVER, UNKNOWN_ACTION_TYPE, ELEMENT_BUTTON, ELEMENT_ICON, EVENT_ON_POINTER_DOWN, EVENT_ON_POINTER_MOVE, EVENT_ON_POINTER_UP, EVENT_ON_POINTER_LEAVE, EVENT_ON_POINTER_CANCEL, EVENT_ON_KEY_DOWN, EVENT_ON_KEY_UP, EVENT_ON_WHEEL, SLIDE_STATUS_LOADING, activeSlideStatus, SLIDE_STATUS_COMPLETE, SLIDE_STATUS_ERROR, SLIDE_STATUS_PLACEHOLDER, ACTION_PREV, ACTION_NEXT, ACTION_SWIPE, CLASS_FLEX_CENTER, MODULE_CAROUSEL, CLASS_FULLSIZE, VK_ARROW_RIGHT, VK_ARROW_LEFT, VK_ESCAPE, MODULE_NAVIGATION, CLASS_NO_SCROLL, CLASS_NO_SCROLL_PADDING, MODULE_NO_SCROLL,
|
|
3
|
+
import { ACTION_CLOSE, IMAGE_FIT_CONTAIN, MODULE_CONTROLLER, IMAGE_FIT_COVER, UNKNOWN_ACTION_TYPE, ELEMENT_BUTTON, ELEMENT_ICON, EVENT_ON_POINTER_DOWN, EVENT_ON_POINTER_MOVE, EVENT_ON_POINTER_UP, EVENT_ON_POINTER_LEAVE, EVENT_ON_POINTER_CANCEL, EVENT_ON_KEY_DOWN, EVENT_ON_KEY_UP, EVENT_ON_WHEEL, SLIDE_STATUS_LOADING, activeSlideStatus, SLIDE_STATUS_COMPLETE, SLIDE_STATUS_ERROR, SLIDE_STATUS_PLACEHOLDER, ACTION_PREV, ACTION_NEXT, ACTION_SWIPE, MODULE_PORTAL, CLASS_FLEX_CENTER, MODULE_CAROUSEL, CLASS_FULLSIZE, VK_ARROW_RIGHT, VK_ARROW_LEFT, VK_ESCAPE, MODULE_NAVIGATION, CLASS_NO_SCROLL, CLASS_NO_SCROLL_PADDING, MODULE_NO_SCROLL, MODULE_ROOT, MODULE_TOOLBAR } from './types.js';
|
|
4
4
|
import { createPortal } from 'react-dom';
|
|
5
5
|
export { ACTIVE_SLIDE_COMPLETE, ACTIVE_SLIDE_ERROR, ACTIVE_SLIDE_LOADING, ACTIVE_SLIDE_PLAYING, PLUGIN_CAPTIONS, PLUGIN_COUNTER, PLUGIN_DOWNLOAD, PLUGIN_FULLSCREEN, PLUGIN_INLINE, PLUGIN_SHARE, PLUGIN_SLIDESHOW, PLUGIN_THUMBNAILS, PLUGIN_ZOOM, SLIDE_STATUS_PLAYING } from './types.js';
|
|
6
6
|
|
|
@@ -673,8 +673,7 @@ function usePointerSwipe(subscribeSensors, isSwipeValid, containerWidth, swipeAn
|
|
|
673
673
|
addPointer(event);
|
|
674
674
|
});
|
|
675
675
|
const onPointerUp = useEventCallback((event) => {
|
|
676
|
-
if (pointers.current.find((x) => x.pointerId === event.pointerId) &&
|
|
677
|
-
activePointer.current === event.pointerId) {
|
|
676
|
+
if (pointers.current.find((x) => x.pointerId === event.pointerId) && activePointer.current === event.pointerId) {
|
|
678
677
|
const duration = Date.now() - startTime.current;
|
|
679
678
|
const currentOffset = offset.current;
|
|
680
679
|
if (gesture.current === Gesture.SWIPE) {
|
|
@@ -945,9 +944,7 @@ function Controller({ children, ...props }) {
|
|
|
945
944
|
var _a;
|
|
946
945
|
if (carouselRef.current && containerRect && ((_a = state.animation) === null || _a === void 0 ? void 0 : _a.duration)) {
|
|
947
946
|
const parsedSpacing = parseLengthPercentage(carousel.spacing);
|
|
948
|
-
const spacingValue = (parsedSpacing.percent
|
|
949
|
-
? (parsedSpacing.percent * containerRect.width) / 100
|
|
950
|
-
: parsedSpacing.pixel) || 0;
|
|
947
|
+
const spacingValue = (parsedSpacing.percent ? (parsedSpacing.percent * containerRect.width) / 100 : parsedSpacing.pixel) || 0;
|
|
951
948
|
return {
|
|
952
949
|
keyframes: [
|
|
953
950
|
{
|
|
@@ -1061,9 +1058,10 @@ function Controller({ children, ...props }) {
|
|
|
1061
1058
|
usePointerSwipe(...swipeParams, closeOnPullDown, ...pullDownParams);
|
|
1062
1059
|
useWheelSwipe(swipeState, ...swipeParams);
|
|
1063
1060
|
const focusOnMount = useEventCallback(() => {
|
|
1064
|
-
var _a;
|
|
1065
1061
|
if (controller.focus) {
|
|
1066
|
-
(
|
|
1062
|
+
if (document.querySelector(`.${cssClass(MODULE_PORTAL)} .${cssClass(cssContainerPrefix())}`)) {
|
|
1063
|
+
focus();
|
|
1064
|
+
}
|
|
1067
1065
|
}
|
|
1068
1066
|
});
|
|
1069
1067
|
React.useEffect(focusOnMount, [focusOnMount]);
|
|
@@ -1116,9 +1114,7 @@ function Controller({ children, ...props }) {
|
|
|
1116
1114
|
[cssVar("pull_down_opacity")]: `${pullDownOpacity.current}`,
|
|
1117
1115
|
}
|
|
1118
1116
|
: null),
|
|
1119
|
-
...(controller.touchAction !== "none"
|
|
1120
|
-
? { [cssVar("controller_touch_action")]: controller.touchAction }
|
|
1121
|
-
: null),
|
|
1117
|
+
...(controller.touchAction !== "none" ? { [cssVar("controller_touch_action")]: controller.touchAction } : null),
|
|
1122
1118
|
...styles.container,
|
|
1123
1119
|
}, ...(controller.aria ? { role: "presentation", "aria-live": "polite" } : null), tabIndex: -1, ...registerSensors }, containerRect && (React.createElement(ControllerContext.Provider, { value: context },
|
|
1124
1120
|
children, (_a = render.controls) === null || _a === void 0 ? void 0 :
|
|
@@ -1312,6 +1308,7 @@ function Portal({ children, animation, styles, className, on, portal, close }) {
|
|
|
1312
1308
|
const [mounted, setMounted] = React.useState(false);
|
|
1313
1309
|
const [visible, setVisible] = React.useState(false);
|
|
1314
1310
|
const cleanup = React.useRef([]);
|
|
1311
|
+
const restoreFocus = React.useRef(null);
|
|
1315
1312
|
const { setTimeout } = useTimeouts();
|
|
1316
1313
|
const { subscribe } = useEvents();
|
|
1317
1314
|
const reduceMotion = useMotionPreference();
|
|
@@ -1326,6 +1323,8 @@ function Portal({ children, animation, styles, className, on, portal, close }) {
|
|
|
1326
1323
|
const handleClose = useEventCallback(() => {
|
|
1327
1324
|
var _a;
|
|
1328
1325
|
setVisible(false);
|
|
1326
|
+
cleanup.current.forEach((clean) => clean());
|
|
1327
|
+
cleanup.current = [];
|
|
1329
1328
|
(_a = on.exiting) === null || _a === void 0 ? void 0 : _a.call(on);
|
|
1330
1329
|
setTimeout(() => {
|
|
1331
1330
|
var _a;
|
|
@@ -1347,23 +1346,20 @@ function Portal({ children, animation, styles, className, on, portal, close }) {
|
|
|
1347
1346
|
cleanup.current.push(setAttribute(element, "aria-hidden", "true"));
|
|
1348
1347
|
}
|
|
1349
1348
|
}
|
|
1349
|
+
cleanup.current.push(() => {
|
|
1350
|
+
var _a, _b;
|
|
1351
|
+
(_b = (_a = restoreFocus.current) === null || _a === void 0 ? void 0 : _a.focus) === null || _b === void 0 ? void 0 : _b.call(_a);
|
|
1352
|
+
});
|
|
1350
1353
|
setTimeout(() => {
|
|
1351
1354
|
var _a;
|
|
1352
1355
|
(_a = on.entered) === null || _a === void 0 ? void 0 : _a.call(on);
|
|
1353
1356
|
}, animationDuration);
|
|
1354
1357
|
});
|
|
1355
|
-
const handleExit = useEventCallback(() => {
|
|
1356
|
-
cleanup.current.forEach((clean) => clean());
|
|
1357
|
-
cleanup.current = [];
|
|
1358
|
-
});
|
|
1359
1358
|
const handleRef = React.useCallback((node) => {
|
|
1360
1359
|
if (node) {
|
|
1361
1360
|
handleEnter(node);
|
|
1362
1361
|
}
|
|
1363
|
-
|
|
1364
|
-
handleExit();
|
|
1365
|
-
}
|
|
1366
|
-
}, [handleEnter, handleExit]);
|
|
1362
|
+
}, [handleEnter]);
|
|
1367
1363
|
return mounted
|
|
1368
1364
|
? createPortal(React.createElement("div", { ref: handleRef, className: clsx(className, cssClass("root"), cssClass(cssPrefix$1()), cssClass(CLASS_NO_SCROLL_PADDING), visible && cssClass(cssPrefix$1("open"))), role: "presentation", "aria-live": "polite", style: {
|
|
1369
1365
|
...(animation.fade !== LightboxDefaultProps.animation.fade
|
|
@@ -1373,6 +1369,10 @@ function Portal({ children, animation, styles, className, on, portal, close }) {
|
|
|
1373
1369
|
? { [cssVar("fade_animation_timing_function")]: animation.easing.fade }
|
|
1374
1370
|
: null),
|
|
1375
1371
|
...styles.root,
|
|
1372
|
+
}, onFocus: (event) => {
|
|
1373
|
+
if (!restoreFocus.current) {
|
|
1374
|
+
restoreFocus.current = event.relatedTarget;
|
|
1375
|
+
}
|
|
1376
1376
|
} }, children), portal.root || document.body)
|
|
1377
1377
|
: null;
|
|
1378
1378
|
}
|
|
@@ -1397,7 +1397,7 @@ function Toolbar({ toolbar: { buttons }, render: { buttonClose, iconClose }, sty
|
|
|
1397
1397
|
return buttonClose();
|
|
1398
1398
|
return React.createElement(IconButton, { key: ACTION_CLOSE, label: "Close", icon: CloseIcon, renderIcon: iconClose, onClick: close });
|
|
1399
1399
|
};
|
|
1400
|
-
return (React.createElement("div", { ref: setContainerRef, style: styles.toolbar, className: cssClass(cssPrefix())
|
|
1400
|
+
return (React.createElement("div", { ref: setContainerRef, style: styles.toolbar, className: cssClass(cssPrefix()) }, buttons === null || buttons === void 0 ? void 0 : buttons.map((button) => (button === ACTION_CLOSE ? renderCloseButton() : button))));
|
|
1401
1401
|
}
|
|
1402
1402
|
const ToolbarModule = createModule(MODULE_TOOLBAR, Toolbar);
|
|
1403
1403
|
|
|
@@ -194,9 +194,7 @@ function ThumbnailsTrack({ visible, containerRef }) {
|
|
|
194
194
|
(offset < 0 && slideIndex < index - preload - offset && slideIndex >= index - preload)
|
|
195
195
|
? {
|
|
196
196
|
duration: fadeAnimationDuration,
|
|
197
|
-
delay: ((offset > 0
|
|
198
|
-
? slideIndex - (index + preload - offset)
|
|
199
|
-
: index - preload - offset - slideIndex) -
|
|
197
|
+
delay: ((offset > 0 ? slideIndex - (index + preload - offset) : index - preload - offset - slideIndex) -
|
|
200
198
|
1) *
|
|
201
199
|
fadeAnimationDuration,
|
|
202
200
|
}
|
|
@@ -209,7 +207,7 @@ function ThumbnailsTrack({ visible, containerRef }) {
|
|
|
209
207
|
: -offset - (slideIndex - (index + preload))) * fadeAnimationDuration,
|
|
210
208
|
}
|
|
211
209
|
: undefined;
|
|
212
|
-
return (React.createElement(Thumbnail, { key: slideIndex, slide: slide, active: slideIndex === index, fadeIn: fadeIn, fadeOut: fadeOut, placeholder: Boolean(placeholder), onClick: handleClick(slideIndex), onLoseFocus: () => { var _a; return (_a = track.current) === null || _a === void 0 ? void 0 : _a.focus(); } }));
|
|
210
|
+
return (React.createElement(Thumbnail, { key: [`${slideIndex}`, placeholder && "placeholder"].filter(Boolean).join("-"), slide: slide, active: slideIndex === index, fadeIn: fadeIn, fadeOut: fadeOut, placeholder: Boolean(placeholder), onClick: handleClick(slideIndex), onLoseFocus: () => { var _a; return (_a = track.current) === null || _a === void 0 ? void 0 : _a.focus(); } }));
|
|
213
211
|
})),
|
|
214
212
|
vignette && React.createElement("div", { className: cssClass(cssPrefix("vignette")) })));
|
|
215
213
|
}
|
|
@@ -229,9 +227,9 @@ function ThumbnailsContextProvider({ children, ...props }) {
|
|
|
229
227
|
return (React.createElement(LightboxPropsProvider, { ...props },
|
|
230
228
|
React.createElement(ThumbnailsContext.Provider, { value: context },
|
|
231
229
|
React.createElement("div", { ref: containerRef, className: clsx(cssClass(cssPrefix()), cssClass(cssPrefix(`${position}`))) },
|
|
232
|
-
["start", "top"].includes(position) &&
|
|
230
|
+
["start", "top"].includes(position) && React.createElement(ThumbnailsTrack, { containerRef: containerRef, visible: visible }),
|
|
233
231
|
React.createElement("div", { className: cssClass(cssPrefix("wrapper")) }, children),
|
|
234
|
-
["end", "bottom"].includes(position) &&
|
|
232
|
+
["end", "bottom"].includes(position) && React.createElement(ThumbnailsTrack, { containerRef: containerRef, visible: visible })))));
|
|
235
233
|
}
|
|
236
234
|
|
|
237
235
|
const thumbnailsIcon = () => (React.createElement(React.Fragment, null,
|
|
@@ -49,9 +49,7 @@ function VideoSlide({ slide, offset }) {
|
|
|
49
49
|
if (width && height && containerRect) {
|
|
50
50
|
const widthBound = width / height > containerRect.width / containerRect.height;
|
|
51
51
|
const elementWidth = widthBound ? containerRect.width : Math.round((containerRect.height / height) * width);
|
|
52
|
-
const elementHeight = !widthBound
|
|
53
|
-
? containerRect.height
|
|
54
|
-
: Math.round((containerRect.width / width) * height);
|
|
52
|
+
const elementHeight = !widthBound ? containerRect.height : Math.round((containerRect.width / width) * height);
|
|
55
53
|
scalingProps.width = elementWidth;
|
|
56
54
|
scalingProps.height = elementHeight;
|
|
57
55
|
scalingProps.style.width = elementWidth;
|
|
@@ -315,11 +315,7 @@ function useZoomState(imageRect, maxZoom, zoomWrapperRef) {
|
|
|
315
315
|
changeOffsets();
|
|
316
316
|
}
|
|
317
317
|
});
|
|
318
|
-
useLayoutEffect(handleControllerRectChange, [
|
|
319
|
-
containerRect.width,
|
|
320
|
-
containerRect.height,
|
|
321
|
-
handleControllerRectChange,
|
|
322
|
-
]);
|
|
318
|
+
useLayoutEffect(handleControllerRectChange, [containerRect.width, containerRect.height, handleControllerRectChange]);
|
|
323
319
|
const zoomIn = React.useCallback(() => changeZoom(zoom * zoomInMultiplier), [zoom, zoomInMultiplier, changeZoom]);
|
|
324
320
|
const zoomOut = React.useCallback(() => changeZoom(zoom / zoomInMultiplier), [zoom, zoomInMultiplier, changeZoom]);
|
|
325
321
|
return { zoom, offsetX, offsetY, disabled, changeOffsets, changeZoom, zoomIn, zoomOut };
|
|
@@ -438,9 +434,7 @@ function ResponsiveImage(props) {
|
|
|
438
434
|
WebkitTransform: "translateZ(0)",
|
|
439
435
|
};
|
|
440
436
|
if (!cover) {
|
|
441
|
-
Object.assign(style, rect.width / rect.height < width / height
|
|
442
|
-
? { width: "100%", height: "auto" }
|
|
443
|
-
: { width: "auto", height: "100%" });
|
|
437
|
+
Object.assign(style, rect.width / rect.height < width / height ? { width: "100%", height: "auto" } : { width: "auto", height: "100%" });
|
|
444
438
|
}
|
|
445
439
|
return (React.createElement(React.Fragment, null,
|
|
446
440
|
preload && preload !== current && (React.createElement(ImageSlide, { key: "preload", ...props, slide: { ...image, src: preload, srcSet: undefined }, style: { position: "absolute", visibility: "hidden", ...style }, onLoad: () => handlePreload(preload), render: {
|
|
@@ -480,9 +474,7 @@ function ZoomWrapper({ render, slide, offset, rect }) {
|
|
|
480
474
|
}
|
|
481
475
|
if (!rendered)
|
|
482
476
|
return null;
|
|
483
|
-
return (React.createElement("div", { ref: zoomWrapperRef, className: clsx(cssClass(CLASS_FULLSIZE), cssClass(CLASS_FLEX_CENTER)), style: offset === 0
|
|
484
|
-
? { transform: `scale(${zoom}) translateX(${offsetX}px) translateY(${offsetY}px)` }
|
|
485
|
-
: undefined }, rendered));
|
|
477
|
+
return (React.createElement("div", { ref: zoomWrapperRef, className: clsx(cssClass(CLASS_FULLSIZE), cssClass(CLASS_FLEX_CENTER)), style: offset === 0 ? { transform: `scale(${zoom}) translateX(${offsetX}px) translateY(${offsetY}px)` } : undefined }, rendered));
|
|
486
478
|
}
|
|
487
479
|
|
|
488
480
|
const Zoom = ({ augment, addModule }) => {
|
package/dist/types.d.ts
CHANGED
|
@@ -222,7 +222,7 @@ interface AnimationSettings {
|
|
|
222
222
|
interface ControllerSettings {
|
|
223
223
|
/** controller ref */
|
|
224
224
|
ref: React.ForwardedRef<ControllerRef>;
|
|
225
|
-
/**
|
|
225
|
+
/** @deprecated for internal use only */
|
|
226
226
|
focus: boolean;
|
|
227
227
|
/** controller `touch-action` */
|
|
228
228
|
touchAction: "none" | "pan-y";
|
package/package.json
CHANGED
|
@@ -1,169 +1,169 @@
|
|
|
1
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
|
-
|
|
2
|
+
"name": "yet-another-react-lightbox",
|
|
3
|
+
"version": "3.15.1",
|
|
4
|
+
"description": "Modern React lightbox component",
|
|
5
|
+
"author": "Igor Danchenko",
|
|
6
|
+
"license": "MIT",
|
|
7
|
+
"type": "module",
|
|
8
|
+
"module": "dist/index.js",
|
|
9
|
+
"types": "dist/index.d.ts",
|
|
10
|
+
"exports": {
|
|
11
|
+
".": {
|
|
12
|
+
"types": "./dist/index.d.ts",
|
|
13
|
+
"default": "./dist/index.js"
|
|
14
|
+
},
|
|
15
|
+
"./core": {
|
|
16
|
+
"types": "./dist/index.d.ts",
|
|
17
|
+
"default": "./dist/index.js"
|
|
18
|
+
},
|
|
19
|
+
"./styles.css": {
|
|
20
|
+
"types": "./dist/styles.css.d.ts",
|
|
21
|
+
"default": "./dist/styles.css"
|
|
22
|
+
},
|
|
23
|
+
"./plugins": {
|
|
24
|
+
"types": "./dist/plugins/index.d.ts",
|
|
25
|
+
"default": "./dist/plugins/index.js"
|
|
26
|
+
},
|
|
27
|
+
"./plugins/captions": {
|
|
28
|
+
"types": "./dist/plugins/captions/index.d.ts",
|
|
29
|
+
"default": "./dist/plugins/captions/index.js"
|
|
30
|
+
},
|
|
31
|
+
"./plugins/captions.css": {
|
|
32
|
+
"types": "./dist/plugins/captions/captions.css.d.ts",
|
|
33
|
+
"default": "./dist/plugins/captions/captions.css"
|
|
34
|
+
},
|
|
35
|
+
"./plugins/counter": {
|
|
36
|
+
"types": "./dist/plugins/counter/index.d.ts",
|
|
37
|
+
"default": "./dist/plugins/counter/index.js"
|
|
38
|
+
},
|
|
39
|
+
"./plugins/counter.css": {
|
|
40
|
+
"types": "./dist/plugins/counter/counter.css.d.ts",
|
|
41
|
+
"default": "./dist/plugins/counter/counter.css"
|
|
42
|
+
},
|
|
43
|
+
"./plugins/download": {
|
|
44
|
+
"types": "./dist/plugins/download/index.d.ts",
|
|
45
|
+
"default": "./dist/plugins/download/index.js"
|
|
46
|
+
},
|
|
47
|
+
"./plugins/fullscreen": {
|
|
48
|
+
"types": "./dist/plugins/fullscreen/index.d.ts",
|
|
49
|
+
"default": "./dist/plugins/fullscreen/index.js"
|
|
50
|
+
},
|
|
51
|
+
"./plugins/inline": {
|
|
52
|
+
"types": "./dist/plugins/inline/index.d.ts",
|
|
53
|
+
"default": "./dist/plugins/inline/index.js"
|
|
54
|
+
},
|
|
55
|
+
"./plugins/share": {
|
|
56
|
+
"types": "./dist/plugins/share/index.d.ts",
|
|
57
|
+
"default": "./dist/plugins/share/index.js"
|
|
58
|
+
},
|
|
59
|
+
"./plugins/slideshow": {
|
|
60
|
+
"types": "./dist/plugins/slideshow/index.d.ts",
|
|
61
|
+
"default": "./dist/plugins/slideshow/index.js"
|
|
62
|
+
},
|
|
63
|
+
"./plugins/thumbnails": {
|
|
64
|
+
"types": "./dist/plugins/thumbnails/index.d.ts",
|
|
65
|
+
"default": "./dist/plugins/thumbnails/index.js"
|
|
66
|
+
},
|
|
67
|
+
"./plugins/thumbnails.css": {
|
|
68
|
+
"types": "./dist/plugins/thumbnails/thumbnails.css.d.ts",
|
|
69
|
+
"default": "./dist/plugins/thumbnails/thumbnails.css"
|
|
70
|
+
},
|
|
71
|
+
"./plugins/video": {
|
|
72
|
+
"types": "./dist/plugins/video/index.d.ts",
|
|
73
|
+
"default": "./dist/plugins/video/index.js"
|
|
74
|
+
},
|
|
75
|
+
"./plugins/zoom": {
|
|
76
|
+
"types": "./dist/plugins/zoom/index.d.ts",
|
|
77
|
+
"default": "./dist/plugins/zoom/index.js"
|
|
78
|
+
}
|
|
79
|
+
},
|
|
80
|
+
"typesVersions": {
|
|
81
|
+
"*": {
|
|
82
|
+
"*": [
|
|
83
|
+
"dist/index.d.ts"
|
|
84
|
+
],
|
|
85
|
+
"core": [
|
|
86
|
+
"dist/index.d.ts"
|
|
87
|
+
],
|
|
88
|
+
"styles.css": [
|
|
89
|
+
"dist/styles.css.d.ts"
|
|
90
|
+
],
|
|
91
|
+
"plugins": [
|
|
92
|
+
"dist/plugins/index.d.ts"
|
|
93
|
+
],
|
|
94
|
+
"plugins/captions": [
|
|
95
|
+
"dist/plugins/captions/index.d.ts"
|
|
96
|
+
],
|
|
97
|
+
"plugins/captions.css": [
|
|
98
|
+
"dist/plugins/captions/captions.css.d.ts"
|
|
99
|
+
],
|
|
100
|
+
"plugins/counter": [
|
|
101
|
+
"dist/plugins/counter/index.d.ts"
|
|
102
|
+
],
|
|
103
|
+
"plugins/counter.css": [
|
|
104
|
+
"dist/plugins/counter/counter.css.d.ts"
|
|
105
|
+
],
|
|
106
|
+
"plugins/download": [
|
|
107
|
+
"dist/plugins/download/index.d.ts"
|
|
108
|
+
],
|
|
109
|
+
"plugins/fullscreen": [
|
|
110
|
+
"dist/plugins/fullscreen/index.d.ts"
|
|
111
|
+
],
|
|
112
|
+
"plugins/inline": [
|
|
113
|
+
"dist/plugins/inline/index.d.ts"
|
|
114
|
+
],
|
|
115
|
+
"plugins/share": [
|
|
116
|
+
"dist/plugins/share/index.d.ts"
|
|
117
|
+
],
|
|
118
|
+
"plugins/slideshow": [
|
|
119
|
+
"dist/plugins/slideshow/index.d.ts"
|
|
120
|
+
],
|
|
121
|
+
"plugins/thumbnails": [
|
|
122
|
+
"dist/plugins/thumbnails/index.d.ts"
|
|
123
|
+
],
|
|
124
|
+
"plugins/thumbnails.css": [
|
|
125
|
+
"dist/plugins/thumbnails/thumbnails.css.d.ts"
|
|
126
|
+
],
|
|
127
|
+
"plugins/video": [
|
|
128
|
+
"dist/plugins/video/index.d.ts"
|
|
129
|
+
],
|
|
130
|
+
"plugins/zoom": [
|
|
131
|
+
"dist/plugins/zoom/index.d.ts"
|
|
132
|
+
]
|
|
133
|
+
}
|
|
134
|
+
},
|
|
135
|
+
"files": [
|
|
136
|
+
"dist"
|
|
137
|
+
],
|
|
138
|
+
"sideEffects": [
|
|
139
|
+
"*.css"
|
|
140
|
+
],
|
|
141
|
+
"homepage": "https://yet-another-react-lightbox.com",
|
|
142
|
+
"repository": {
|
|
143
|
+
"type": "git",
|
|
144
|
+
"url": "https://github.com/igordanchenko/yet-another-react-lightbox.git"
|
|
145
|
+
},
|
|
146
|
+
"bugs": {
|
|
147
|
+
"url": "https://github.com/igordanchenko/yet-another-react-lightbox/issues"
|
|
148
|
+
},
|
|
149
|
+
"engines": {
|
|
150
|
+
"node": ">=14"
|
|
151
|
+
},
|
|
152
|
+
"publishConfig": {
|
|
153
|
+
"access": "public",
|
|
154
|
+
"provenance": true
|
|
155
|
+
},
|
|
156
|
+
"peerDependencies": {
|
|
157
|
+
"react": ">=16.8.0",
|
|
158
|
+
"react-dom": ">=16.8.0"
|
|
159
|
+
},
|
|
160
|
+
"keywords": [
|
|
161
|
+
"react",
|
|
162
|
+
"image",
|
|
163
|
+
"photo",
|
|
164
|
+
"lightbox",
|
|
165
|
+
"react lightbox",
|
|
166
|
+
"react image lightbox",
|
|
167
|
+
"react photo lightbox"
|
|
168
|
+
]
|
|
169
169
|
}
|