@ks89/angular-modal-gallery 11.0.0 → 11.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/CHANGELOG.md +26 -0
- package/README.md +2 -0
- package/esm2022/lib/components/carousel/carousel-previews/carousel-previews.component.mjs +3 -3
- package/esm2022/lib/components/carousel/carousel.component.mjs +3 -3
- package/esm2022/lib/components/current-image/current-image.component.mjs +3 -3
- package/esm2022/lib/components/plain-gallery/plain-gallery.component.mjs +3 -3
- package/esm2022/lib/components/previews/previews.component.mjs +3 -3
- package/esm2022/lib/directives/keyboard-navigation.directive.mjs +7 -1
- package/esm2022/lib/directives/swipe.directive.mjs +6 -4
- package/esm2022/lib/model/image.class.mjs +4 -2
- package/fesm2022/ks89-angular-modal-gallery.mjs +24 -14
- package/fesm2022/ks89-angular-modal-gallery.mjs.map +1 -1
- package/lib/directives/keyboard-navigation.directive.d.ts +9 -0
- package/lib/directives/swipe.directive.d.ts +5 -3
- package/lib/model/image.class.d.ts +11 -1
- package/package.json +1 -1
|
@@ -1,7 +1,16 @@
|
|
|
1
1
|
import { EventEmitter } from '@angular/core';
|
|
2
2
|
import * as i0 from "@angular/core";
|
|
3
|
+
/**
|
|
4
|
+
* Directive to manage keyboard navigation.
|
|
5
|
+
*/
|
|
3
6
|
export declare class KeyboardNavigationDirective {
|
|
7
|
+
/**
|
|
8
|
+
* Boolean input to skip keyboard navigation.
|
|
9
|
+
*/
|
|
4
10
|
isOpen: boolean | undefined;
|
|
11
|
+
/**
|
|
12
|
+
* Output to emit keyboard `code` of the pressed key (keydown).
|
|
13
|
+
*/
|
|
5
14
|
keyboardNavigation: EventEmitter<string>;
|
|
6
15
|
/**
|
|
7
16
|
* Listener to catch keyboard's events and call the right method based on the key.
|
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
import { EventEmitter } from '@angular/core';
|
|
2
2
|
import * as i0 from "@angular/core";
|
|
3
3
|
/**
|
|
4
|
-
* Directive to
|
|
5
|
-
* In fact, it listens for a click on all elements that aren't 'inside' and it emits
|
|
6
|
-
* an event using `@Output clickOutside`.
|
|
4
|
+
* Directive to manage swipe events on touch devices.
|
|
7
5
|
*/
|
|
8
6
|
export declare class SwipeDirective {
|
|
9
7
|
defaultTouch: {
|
|
@@ -12,15 +10,19 @@ export declare class SwipeDirective {
|
|
|
12
10
|
time: number;
|
|
13
11
|
};
|
|
14
12
|
/**
|
|
13
|
+
* Output to emit swipe left event. Payload is empty.
|
|
15
14
|
*/
|
|
16
15
|
swipeLeft: EventEmitter<void>;
|
|
17
16
|
/**
|
|
17
|
+
* Output to emit swipe right event. Payload is empty.
|
|
18
18
|
*/
|
|
19
19
|
swipeRight: EventEmitter<void>;
|
|
20
20
|
/**
|
|
21
|
+
* Output to emit swipe up event. Payload is empty.
|
|
21
22
|
*/
|
|
22
23
|
swipeUp: EventEmitter<void>;
|
|
23
24
|
/**
|
|
25
|
+
* Output to emit swipe down event. Payload is empty.
|
|
24
26
|
*/
|
|
25
27
|
swipeDown: EventEmitter<void>;
|
|
26
28
|
/**
|
|
@@ -7,9 +7,11 @@ import { SafeResourceUrl } from '@angular/platform-browser';
|
|
|
7
7
|
*/
|
|
8
8
|
export declare class Image {
|
|
9
9
|
id: number;
|
|
10
|
+
loading: 'eager' | 'lazy';
|
|
11
|
+
fetchpriority: 'high' | 'low' | 'auto';
|
|
10
12
|
modal: ModalImage;
|
|
11
13
|
plain?: PlainImage;
|
|
12
|
-
constructor(id: number, modal: ModalImage, plain?: PlainImage);
|
|
14
|
+
constructor(id: number, modal: ModalImage, plain?: PlainImage, loading?: 'eager' | 'lazy', fetchpriority?: 'high' | 'low' | 'auto');
|
|
13
15
|
}
|
|
14
16
|
/**
|
|
15
17
|
* Interface `ImageData` to configure an image, but it isn't used directly.
|
|
@@ -29,6 +31,7 @@ export interface ImageData {
|
|
|
29
31
|
export interface ModalImage extends ImageData {
|
|
30
32
|
extUrl?: string;
|
|
31
33
|
downloadFileName?: string;
|
|
34
|
+
sources?: Source[];
|
|
32
35
|
}
|
|
33
36
|
/**
|
|
34
37
|
* Interface `PlainImage` to configure the plain image.
|
|
@@ -52,3 +55,10 @@ export declare class ImageEvent {
|
|
|
52
55
|
export declare class ImageModalEvent extends ImageEvent {
|
|
53
56
|
constructor(galleryId: number, action: Action, result: number | boolean);
|
|
54
57
|
}
|
|
58
|
+
/**
|
|
59
|
+
* Interface `Source` to configure sources of picture element.
|
|
60
|
+
*/
|
|
61
|
+
export interface Source {
|
|
62
|
+
srcset: string;
|
|
63
|
+
media: string;
|
|
64
|
+
}
|