@ks89/angular-modal-gallery 8.0.0-beta.5 → 9.0.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 +153 -0
- package/CONTRIBUTING.md +20 -38
- package/LICENSE +1 -1
- package/README.md +36 -42
- package/esm2020/ks89-angular-modal-gallery.mjs +5 -0
- package/esm2020/lib/components/accessibility-default.mjs +41 -0
- package/esm2020/lib/components/accessible.component.mjs +130 -0
- package/esm2020/lib/components/carousel/carousel-previews/carousel-previews.component.mjs +462 -0
- package/esm2020/lib/components/carousel/carousel.component.mjs +747 -0
- package/esm2020/lib/components/components.mjs +50 -0
- package/esm2020/lib/components/current-image/current-image.component.mjs +616 -0
- package/esm2020/lib/components/current-image/loading-spinner/loading-spinner.component.mjs +80 -0
- package/esm2020/lib/components/dots/dots.component.mjs +127 -0
- package/esm2020/lib/components/modal-gallery/modal-gallery-ref.mjs +103 -0
- package/esm2020/lib/components/modal-gallery/modal-gallery.component.mjs +523 -0
- package/esm2020/lib/components/modal-gallery/modal-gallery.service.mjs +187 -0
- package/esm2020/lib/components/modal-gallery/modal-gallery.tokens.mjs +26 -0
- package/esm2020/lib/components/plain-gallery/plain-gallery.component.mjs +249 -0
- package/esm2020/lib/components/previews/previews.component.mjs +332 -0
- package/esm2020/lib/components/upper-buttons/upper-buttons-default.mjs +76 -0
- package/esm2020/lib/components/upper-buttons/upper-buttons.component.mjs +249 -0
- package/esm2020/lib/directives/a-tag-bg-image.directive.mjs +78 -0
- package/esm2020/lib/directives/click-outside.directive.mjs +91 -0
- package/esm2020/lib/directives/description.directive.mjs +98 -0
- package/esm2020/lib/directives/direction.directive.mjs +73 -0
- package/esm2020/lib/directives/directives.mjs +49 -0
- package/esm2020/lib/directives/fallback-image.directive.mjs +59 -0
- package/esm2020/lib/directives/keyboard-navigation.directive.mjs +58 -0
- package/esm2020/lib/directives/margin.directive.mjs +84 -0
- package/esm2020/lib/directives/max-size.directive.mjs +75 -0
- package/esm2020/lib/directives/size.directive.mjs +76 -0
- package/{esm2015/lib/directives/size.directive.js → esm2020/lib/directives/wrap.directive.mjs} +23 -22
- package/esm2020/lib/modal-gallery.module.mjs +94 -0
- package/esm2020/lib/model/accessibility.interface.mjs +25 -0
- package/esm2020/lib/model/action.enum.mjs +36 -0
- package/esm2020/lib/model/buttons-config.interface.mjs +62 -0
- package/esm2020/lib/model/carousel-config.interface.mjs +25 -0
- package/esm2020/lib/model/carousel-image-config.interface.mjs +25 -0
- package/esm2020/lib/model/carousel-preview-config.interface.mjs +25 -0
- package/{esm2015/lib/model/keyboard-service-config.interface.js → esm2020/lib/model/current-image-config.interface.mjs} +2 -2
- package/esm2020/lib/model/description.interface.mjs +33 -0
- package/{esm2015/lib/model/preview-config.interface.js → esm2020/lib/model/dots-config.interface.mjs} +2 -2
- package/esm2020/lib/model/image-internal.class.mjs +35 -0
- package/esm2020/lib/model/image.class.mjs +54 -0
- package/esm2020/lib/model/interaction-event.interface.mjs +2 -0
- package/esm2020/lib/model/keyboard-config.interface.mjs +25 -0
- package/esm2020/lib/model/keyboard-service-config.interface.mjs +25 -0
- package/esm2020/lib/model/keyboard.enum.mjs +35 -0
- package/esm2020/lib/model/lib-config.interface.mjs +25 -0
- package/esm2020/lib/model/loading-config.interface.mjs +37 -0
- package/{esm2015/lib/model/dots-config.interface.js → esm2020/lib/model/max-size.interface.mjs} +2 -2
- package/{esm2015/lib/model/carousel-preview-config.interface.js → esm2020/lib/model/modal-gallery-config.interface.mjs} +2 -2
- package/esm2020/lib/model/plain-gallery-config.interface.mjs +55 -0
- package/{esm2015/lib/model/image-internal.class.js → esm2020/lib/model/play-config.interface.mjs} +3 -13
- package/esm2020/lib/model/preview-config.interface.mjs +25 -0
- package/esm2020/lib/model/size.interface.mjs +25 -0
- package/{esm2015/lib/model/carousel-config.interface.js → esm2020/lib/model/slide-config.interface.mjs} +2 -2
- package/esm2020/lib/services/config.service.mjs +396 -0
- package/esm2020/lib/services/id-validator.service.mjs +71 -0
- package/esm2020/lib/services/keyboard.service.mjs +111 -0
- package/esm2020/lib/utils/image.util.mjs +48 -0
- package/esm2020/lib/utils/user-input.util.mjs +104 -0
- package/esm2020/public-api.mjs +42 -0
- package/fesm2015/ks89-angular-modal-gallery.mjs +5782 -0
- package/fesm2015/ks89-angular-modal-gallery.mjs.map +1 -0
- package/{fesm2015/ks89-angular-modal-gallery.js → fesm2020/ks89-angular-modal-gallery.mjs} +3046 -2947
- package/fesm2020/ks89-angular-modal-gallery.mjs.map +1 -0
- package/ks89-angular-modal-gallery.d.ts +1 -24
- package/lib/components/accessible.component.d.ts +5 -2
- package/lib/components/carousel/carousel-previews/carousel-previews.component.d.ts +7 -11
- package/lib/components/carousel/carousel.component.d.ts +28 -67
- package/lib/components/current-image/current-image.component.d.ts +10 -4
- package/lib/components/current-image/loading-spinner/loading-spinner.component.d.ts +3 -0
- package/lib/components/dots/dots.component.d.ts +7 -0
- package/lib/components/modal-gallery/modal-gallery-ref.d.ts +35 -0
- package/lib/components/modal-gallery/modal-gallery.component.d.ts +58 -50
- package/lib/components/modal-gallery/modal-gallery.service.d.ts +60 -1
- package/lib/components/plain-gallery/plain-gallery.component.d.ts +18 -9
- package/lib/components/previews/previews.component.d.ts +9 -0
- package/lib/components/upper-buttons/upper-buttons.component.d.ts +8 -1
- package/lib/directives/a-tag-bg-image.directive.d.ts +3 -0
- package/lib/directives/click-outside.directive.d.ts +3 -0
- package/lib/directives/description.directive.d.ts +3 -0
- package/lib/directives/direction.directive.d.ts +3 -0
- package/lib/directives/fallback-image.directive.d.ts +6 -0
- package/lib/directives/keyboard-navigation.directive.d.ts +4 -1
- package/lib/directives/margin.directive.d.ts +3 -0
- package/lib/directives/max-size.directive.d.ts +3 -0
- package/lib/directives/size.directive.d.ts +5 -2
- package/lib/directives/wrap.directive.d.ts +4 -1
- package/lib/modal-gallery.module.d.ts +28 -0
- package/lib/model/carousel-config.interface.d.ts +0 -1
- package/lib/model/keyboard-config.interface.d.ts +4 -4
- package/lib/model/keyboard.enum.d.ts +11 -8
- package/lib/model/lib-config.interface.d.ts +20 -7
- package/lib/model/modal-gallery-config.interface.d.ts +2 -2
- package/lib/model/plain-gallery-config.interface.d.ts +1 -9
- package/lib/services/config.service.d.ts +3 -0
- package/lib/services/id-validator.service.d.ts +5 -1
- package/lib/services/keyboard.service.d.ts +5 -2
- package/lib/utils/user-input.util.d.ts +35 -26
- package/package.json +28 -16
- package/public-api.d.ts +2 -2
- package/bundles/ks89-angular-modal-gallery.umd.js +0 -5906
- package/bundles/ks89-angular-modal-gallery.umd.js.map +0 -1
- package/bundles/ks89-angular-modal-gallery.umd.min.js +0 -16
- package/bundles/ks89-angular-modal-gallery.umd.min.js.map +0 -1
- package/esm2015/ks89-angular-modal-gallery.js +0 -29
- package/esm2015/lib/components/accessibility-default.js +0 -41
- package/esm2015/lib/components/accessible.component.js +0 -127
- package/esm2015/lib/components/carousel/carousel-previews/carousel-previews.component.js +0 -466
- package/esm2015/lib/components/carousel/carousel.component.js +0 -772
- package/esm2015/lib/components/components.js +0 -50
- package/esm2015/lib/components/current-image/current-image.component.js +0 -590
- package/esm2015/lib/components/current-image/loading-spinner/loading-spinner.component.js +0 -80
- package/esm2015/lib/components/dots/dots.component.js +0 -127
- package/esm2015/lib/components/modal-gallery/modal-gallery-ref.js +0 -45
- package/esm2015/lib/components/modal-gallery/modal-gallery.component.js +0 -534
- package/esm2015/lib/components/modal-gallery/modal-gallery.service.js +0 -135
- package/esm2015/lib/components/modal-gallery/modal-gallery.tokens.js +0 -3
- package/esm2015/lib/components/plain-gallery/plain-gallery.component.js +0 -243
- package/esm2015/lib/components/previews/previews.component.js +0 -331
- package/esm2015/lib/components/upper-buttons/upper-buttons-default.js +0 -76
- package/esm2015/lib/components/upper-buttons/upper-buttons.component.js +0 -256
- package/esm2015/lib/directives/a-tag-bg-image.directive.js +0 -78
- package/esm2015/lib/directives/click-outside.directive.js +0 -85
- package/esm2015/lib/directives/description.directive.js +0 -99
- package/esm2015/lib/directives/direction.directive.js +0 -73
- package/esm2015/lib/directives/directives.js +0 -49
- package/esm2015/lib/directives/fallback-image.directive.js +0 -54
- package/esm2015/lib/directives/keyboard-navigation.directive.js +0 -52
- package/esm2015/lib/directives/margin.directive.js +0 -82
- package/esm2015/lib/directives/max-size.directive.js +0 -76
- package/esm2015/lib/directives/wrap.directive.js +0 -74
- package/esm2015/lib/modal-gallery.module.js +0 -64
- package/esm2015/lib/model/accessibility.interface.js +0 -25
- package/esm2015/lib/model/action.enum.js +0 -36
- package/esm2015/lib/model/buttons-config.interface.js +0 -66
- package/esm2015/lib/model/carousel-image-config.interface.js +0 -25
- package/esm2015/lib/model/current-image-config.interface.js +0 -25
- package/esm2015/lib/model/description.interface.js +0 -33
- package/esm2015/lib/model/image.class.js +0 -54
- package/esm2015/lib/model/interaction-event.interface.js +0 -2
- package/esm2015/lib/model/keyboard-config.interface.js +0 -25
- package/esm2015/lib/model/keyboard.enum.js +0 -35
- package/esm2015/lib/model/lib-config.interface.js +0 -25
- package/esm2015/lib/model/loading-config.interface.js +0 -37
- package/esm2015/lib/model/max-size.interface.js +0 -25
- package/esm2015/lib/model/modal-gallery-config.interface.js +0 -25
- package/esm2015/lib/model/plain-gallery-config.interface.js +0 -64
- package/esm2015/lib/model/play-config.interface.js +0 -25
- package/esm2015/lib/model/size.interface.js +0 -25
- package/esm2015/lib/model/slide-config.interface.js +0 -25
- package/esm2015/lib/services/config.service.js +0 -392
- package/esm2015/lib/services/id-validator.service.js +0 -71
- package/esm2015/lib/services/keyboard.service.js +0 -108
- package/esm2015/lib/utils/image.util.js +0 -48
- package/esm2015/lib/utils/user-input.util.js +0 -95
- package/esm2015/public-api.js +0 -46
- package/fesm2015/ks89-angular-modal-gallery.js.map +0 -1
- package/ks89-angular-modal-gallery.metadata.json +0 -1
|
@@ -5,6 +5,7 @@ import { Image, ImageModalEvent } from '../../model/image.class';
|
|
|
5
5
|
import { ConfigService } from '../../services/config.service';
|
|
6
6
|
import { ButtonEvent } from '../../model/buttons-config.interface';
|
|
7
7
|
import { ModalGalleryConfig } from '../../model/modal-gallery-config.interface';
|
|
8
|
+
import * as i0 from "@angular/core";
|
|
8
9
|
export declare class ModalGalleryService {
|
|
9
10
|
private injector;
|
|
10
11
|
private overlay;
|
|
@@ -13,18 +14,76 @@ export declare class ModalGalleryService {
|
|
|
13
14
|
updateImages$: import("rxjs").Observable<Image[]>;
|
|
14
15
|
private dialogRef;
|
|
15
16
|
constructor(injector: Injector, overlay: Overlay, configService: ConfigService);
|
|
17
|
+
/**
|
|
18
|
+
* Method to open modal gallery passing the configuration
|
|
19
|
+
* @param config ModalGalleryConfig that contains: id, array of images, current image and optionally the configuration object
|
|
20
|
+
* @return ModalGalleryRef | undefined is the object used to listen for events.
|
|
21
|
+
*/
|
|
16
22
|
open(config: ModalGalleryConfig): ModalGalleryRef | undefined;
|
|
23
|
+
/**
|
|
24
|
+
* Method to close a modal gallery previously opened.
|
|
25
|
+
* @param id Unique identifier of the modal gallery
|
|
26
|
+
* @param clickOutside boolean is true if closed clicking on the modal backdrop, false otherwise.
|
|
27
|
+
*/
|
|
17
28
|
close(id: number, clickOutside: boolean): void;
|
|
29
|
+
/**
|
|
30
|
+
* Method to update images array.
|
|
31
|
+
* @param images Image[] updated array of images
|
|
32
|
+
*/
|
|
18
33
|
updateModalImages(images: Image[]): void;
|
|
34
|
+
/**
|
|
35
|
+
* Method to emit close event.
|
|
36
|
+
* @param event ImageModalEvent is the event payload
|
|
37
|
+
*/
|
|
19
38
|
emitClose(event: ImageModalEvent): void;
|
|
39
|
+
/**
|
|
40
|
+
* Method to emit show event.
|
|
41
|
+
* @param event ImageModalEvent is the event payload
|
|
42
|
+
*/
|
|
20
43
|
emitShow(event: ImageModalEvent): void;
|
|
44
|
+
/**
|
|
45
|
+
* Method to emit firstImage event.
|
|
46
|
+
* @param event ImageModalEvent is the event payload
|
|
47
|
+
*/
|
|
21
48
|
emitFirstImage(event: ImageModalEvent): void;
|
|
49
|
+
/**
|
|
50
|
+
* Method to emit lastImage event.
|
|
51
|
+
* @param event ImageModalEvent is the event payload
|
|
52
|
+
*/
|
|
22
53
|
emitLastImage(event: ImageModalEvent): void;
|
|
54
|
+
/**
|
|
55
|
+
* Method to emit hasData event.
|
|
56
|
+
* @param event ImageModalEvent is the event payload
|
|
57
|
+
*/
|
|
23
58
|
emitHasData(event: ImageModalEvent): void;
|
|
59
|
+
/**
|
|
60
|
+
* Method to emit buttonBeforeHook event.
|
|
61
|
+
* @param event ButtonEvent is the event payload
|
|
62
|
+
*/
|
|
24
63
|
emitButtonBeforeHook(event: ButtonEvent): void;
|
|
64
|
+
/**
|
|
65
|
+
* Method to emit buttonAfterHook event.
|
|
66
|
+
* @param event ButtonEvent is the event payload
|
|
67
|
+
*/
|
|
25
68
|
emitButtonAfterHook(event: ButtonEvent): void;
|
|
69
|
+
/**
|
|
70
|
+
* Private method to create an Overlay using Angular CDK APIs
|
|
71
|
+
* @private
|
|
72
|
+
*/
|
|
26
73
|
private createOverlay;
|
|
74
|
+
/**
|
|
75
|
+
* Private method to attach ModalGalleryComponent to the overlay.
|
|
76
|
+
* @param overlayRef OverlayRef is the Overlay object created using Angular CDK APIs
|
|
77
|
+
* @param config ModalGalleryConfig that contains: id, array of images, current image and optionally the configuration object
|
|
78
|
+
* @param dialogRef ModalGalleryRef is the object to control the dialog instance
|
|
79
|
+
* @private
|
|
80
|
+
*/
|
|
27
81
|
private attachDialogContainer;
|
|
28
|
-
|
|
82
|
+
/**
|
|
83
|
+
* Private method to create an OverlayConfig instance
|
|
84
|
+
* @private
|
|
85
|
+
*/
|
|
29
86
|
private getOverlayConfig;
|
|
87
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ModalGalleryService, never>;
|
|
88
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<ModalGalleryService>;
|
|
30
89
|
}
|
|
@@ -5,7 +5,8 @@ import { Size } from '../../model/size.interface';
|
|
|
5
5
|
import { PlainGalleryConfig } from '../../model/plain-gallery-config.interface';
|
|
6
6
|
import { ConfigService } from '../../services/config.service';
|
|
7
7
|
import { AccessibleComponent } from '../accessible.component';
|
|
8
|
-
import {
|
|
8
|
+
import { PlainLibConfig } from '../../model/lib-config.interface';
|
|
9
|
+
import * as i0 from "@angular/core";
|
|
9
10
|
/**
|
|
10
11
|
* Component with the gallery of thumbs.
|
|
11
12
|
* In receives an array of Images, a boolean to show/hide
|
|
@@ -15,23 +16,23 @@ import { LibConfig } from '../../model/lib-config.interface';
|
|
|
15
16
|
*/
|
|
16
17
|
export declare class PlainGalleryComponent extends AccessibleComponent implements OnInit, OnChanges {
|
|
17
18
|
private configService;
|
|
19
|
+
/**
|
|
20
|
+
* Unique id (>=0) of the current instance of this library. This is required when you are using
|
|
21
|
+
* the service to call modal gallery.
|
|
22
|
+
*/
|
|
18
23
|
id: number | undefined;
|
|
19
24
|
/**
|
|
20
25
|
* Array of `Image` that represent the model of this library with all images, thumbs and so on.
|
|
21
26
|
*/
|
|
22
27
|
images: Image[];
|
|
23
28
|
/**
|
|
24
|
-
*
|
|
25
|
-
*/
|
|
26
|
-
showGallery: boolean | undefined;
|
|
27
|
-
/**
|
|
28
|
-
* Array of `Image` that represent the model of this library with all images, thumbs and so on.
|
|
29
|
+
* PlainLibConfig object to configure plain-gallery.
|
|
29
30
|
*/
|
|
30
|
-
config:
|
|
31
|
+
config: PlainLibConfig | undefined;
|
|
31
32
|
/**
|
|
32
|
-
* Output to emit an event when an image is
|
|
33
|
+
* Output to emit an event when an image is clicked.
|
|
33
34
|
*/
|
|
34
|
-
|
|
35
|
+
clickImage: EventEmitter<number>;
|
|
35
36
|
/**
|
|
36
37
|
* Object of type `PlainGalleryConfig` to configure the plain gallery.
|
|
37
38
|
*/
|
|
@@ -91,6 +92,12 @@ export declare class PlainGalleryComponent extends AccessibleComponent implement
|
|
|
91
92
|
* @param Image img is the Image to show
|
|
92
93
|
*/
|
|
93
94
|
showModalGalleryByImage(img: Image): void;
|
|
95
|
+
/**
|
|
96
|
+
* Method called when you navigate between images.
|
|
97
|
+
* This will emit the show event with the image as payload.
|
|
98
|
+
* @param KeyboardEvent event that triggered the navigation
|
|
99
|
+
* @param Image img is the Image to show
|
|
100
|
+
*/
|
|
94
101
|
onNavigationEvent(event: KeyboardEvent, img: Image): void;
|
|
95
102
|
/**
|
|
96
103
|
* Method to get `alt attribute`.
|
|
@@ -123,4 +130,6 @@ export declare class PlainGalleryComponent extends AccessibleComponent implement
|
|
|
123
130
|
* based on the layout type.
|
|
124
131
|
*/
|
|
125
132
|
private initImageGrid;
|
|
133
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<PlainGalleryComponent, never>;
|
|
134
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<PlainGalleryComponent, "ks-plain-gallery", never, { "id": "id"; "images": "images"; "config": "config"; }, { "clickImage": "clickImage"; }, never, never>;
|
|
126
135
|
}
|
|
@@ -8,11 +8,16 @@ import { SlideConfig } from '../../model/slide-config.interface';
|
|
|
8
8
|
import { Action } from '../../model/action.enum';
|
|
9
9
|
import { ConfigService } from '../../services/config.service';
|
|
10
10
|
import { Size } from '../../model/size.interface';
|
|
11
|
+
import * as i0 from "@angular/core";
|
|
11
12
|
/**
|
|
12
13
|
* Component with image previews
|
|
13
14
|
*/
|
|
14
15
|
export declare class PreviewsComponent extends AccessibleComponent implements OnInit, OnChanges {
|
|
15
16
|
private configService;
|
|
17
|
+
/**
|
|
18
|
+
* Unique id (>=0) of the current instance of this library. This is required when you are using
|
|
19
|
+
* the service to call modal gallery.
|
|
20
|
+
*/
|
|
16
21
|
id: number | undefined;
|
|
17
22
|
/**
|
|
18
23
|
* Object of type `InternalLibImage` that represent the visible image.
|
|
@@ -91,6 +96,7 @@ export declare class PreviewsComponent extends AccessibleComponent implements On
|
|
|
91
96
|
* This will trigger the `clickpreview` output with the input preview as its payload.
|
|
92
97
|
* @param InternalLibImage preview that triggered this method
|
|
93
98
|
* @param KeyboardEvent | MouseEvent event payload
|
|
99
|
+
* @param Action action that triggered the source event or `Action.NORMAL` if not specified
|
|
94
100
|
*/
|
|
95
101
|
onImageEvent(preview: InternalLibImage, event: KeyboardEvent | MouseEvent, action?: Action): void;
|
|
96
102
|
/**
|
|
@@ -98,6 +104,7 @@ export declare class PreviewsComponent extends AccessibleComponent implements On
|
|
|
98
104
|
* It also emits an event to specify which arrow.
|
|
99
105
|
* @param string direction of the navigation that can be either 'next' or 'prev'
|
|
100
106
|
* @param KeyboardEvent | MouseEvent event payload
|
|
107
|
+
* @param Action action that triggered the source event or `Action.NORMAL` if not specified
|
|
101
108
|
*/
|
|
102
109
|
onNavigationEvent(direction: string, event: KeyboardEvent | MouseEvent, action?: Action): void;
|
|
103
110
|
/**
|
|
@@ -144,4 +151,6 @@ export declare class PreviewsComponent extends AccessibleComponent implements On
|
|
|
144
151
|
* Private method to handle navigation changing the previews array and other variables.
|
|
145
152
|
*/
|
|
146
153
|
private updatePreviews;
|
|
154
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<PreviewsComponent, never>;
|
|
155
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<PreviewsComponent, "ks-previews", never, { "id": "id"; "currentImage": "currentImage"; "images": "images"; }, { "clickPreview": "clickPreview"; }, never, never>;
|
|
147
156
|
}
|
|
@@ -4,6 +4,7 @@ import { Action } from '../../model/action.enum';
|
|
|
4
4
|
import { Image } from '../../model/image.class';
|
|
5
5
|
import { ButtonConfig, ButtonEvent, ButtonsConfig } from '../../model/buttons-config.interface';
|
|
6
6
|
import { ConfigService } from '../../services/config.service';
|
|
7
|
+
import * as i0 from "@angular/core";
|
|
7
8
|
/**
|
|
8
9
|
* Internal representation of `ButtonConfig` with an optional `id` field, used by trackId to improve performances.
|
|
9
10
|
*/
|
|
@@ -16,6 +17,10 @@ export interface InternalButtonConfig extends ButtonConfig {
|
|
|
16
17
|
*/
|
|
17
18
|
export declare class UpperButtonsComponent extends AccessibleComponent implements OnInit {
|
|
18
19
|
private configService;
|
|
20
|
+
/**
|
|
21
|
+
* Unique id (>=0) of the current instance of this library. This is required when you are using
|
|
22
|
+
* the service to call modal gallery.
|
|
23
|
+
*/
|
|
19
24
|
id: number | undefined;
|
|
20
25
|
/**
|
|
21
26
|
* Object of type `Image` that represent the visible image.
|
|
@@ -117,9 +122,11 @@ export declare class UpperButtonsComponent extends AccessibleComponent implement
|
|
|
117
122
|
private addButtonIds;
|
|
118
123
|
/**
|
|
119
124
|
* Private method to validate custom buttons received as input.
|
|
120
|
-
* @param ButtonConfig[] buttons config array
|
|
125
|
+
* @param ButtonConfig[] buttons config array. [] by default.
|
|
121
126
|
* @returns ButtonConfig[] the same input buttons config array
|
|
122
127
|
* @throws an error is exists a button with an unknown type
|
|
123
128
|
*/
|
|
124
129
|
private validateCustomButtons;
|
|
130
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<UpperButtonsComponent, never>;
|
|
131
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<UpperButtonsComponent, "ks-upper-buttons", never, { "id": "id"; "currentImage": "currentImage"; }, { "refresh": "refresh"; "delete": "delete"; "navigate": "navigate"; "download": "download"; "closeButton": "closeButton"; "fullscreen": "fullscreen"; "customEmit": "customEmit"; }, never, never>;
|
|
125
132
|
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { ElementRef, OnChanges, OnInit, Renderer2 } from '@angular/core';
|
|
2
2
|
import { Image } from '../model/image.class';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
3
4
|
/**
|
|
4
5
|
* Directive to add an image to an `<a>` tag with some additional custom properties.
|
|
5
6
|
*/
|
|
@@ -32,4 +33,6 @@ export declare class ATagBgImageDirective implements OnInit, OnChanges {
|
|
|
32
33
|
* Private method to add an image as background of an `<a>` tag.
|
|
33
34
|
*/
|
|
34
35
|
private applyStyle;
|
|
36
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ATagBgImageDirective, never>;
|
|
37
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<ATagBgImageDirective, "[ksATagBgImage]", never, { "image": "image"; "style": "style"; }, {}, never>;
|
|
35
38
|
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { EventEmitter } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
2
3
|
/**
|
|
3
4
|
* Directive to close the modal gallery clicking on the semi-transparent background.
|
|
4
5
|
* In fact, it listens for a click on all elements that aren't 'inside' and it emits
|
|
@@ -18,4 +19,6 @@ export declare class ClickOutsideDirective {
|
|
|
18
19
|
* @param MouseEvent event payload received evey click
|
|
19
20
|
*/
|
|
20
21
|
onClick(event: MouseEvent): void;
|
|
22
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ClickOutsideDirective, never>;
|
|
23
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<ClickOutsideDirective, "[ksClickOutside]", never, { "clickOutsideEnable": "clickOutsideEnable"; }, { "clickOutside": "clickOutside"; }, never>;
|
|
21
24
|
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { ElementRef, OnChanges, OnInit, Renderer2 } from '@angular/core';
|
|
2
2
|
import { Description } from '../model/description.interface';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
3
4
|
/**
|
|
4
5
|
* Directive to customize the description.
|
|
5
6
|
*/
|
|
@@ -27,4 +28,6 @@ export declare class DescriptionDirective implements OnInit, OnChanges {
|
|
|
27
28
|
* Private method to change description's style.
|
|
28
29
|
*/
|
|
29
30
|
private applyStyle;
|
|
31
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DescriptionDirective, never>;
|
|
32
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<DescriptionDirective, "[ksDescription]", never, { "description": "description"; }, {}, never>;
|
|
30
33
|
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ElementRef, OnChanges, OnInit, Renderer2 } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
2
3
|
/**
|
|
3
4
|
* Directive to change the flex-direction of an element, based on two inputs (`direction` and `justify`).
|
|
4
5
|
*/
|
|
@@ -30,4 +31,6 @@ export declare class DirectionDirective implements OnInit, OnChanges {
|
|
|
30
31
|
* Private method to change both direction and justify of an element.
|
|
31
32
|
*/
|
|
32
33
|
private applyStyle;
|
|
34
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<DirectionDirective, never>;
|
|
35
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<DirectionDirective, "[ksDirection]", never, { "direction": "direction"; "justify": "justify"; }, {}, never>;
|
|
33
36
|
}
|
|
@@ -1,5 +1,9 @@
|
|
|
1
1
|
import { ElementRef, EventEmitter, Renderer2 } from '@angular/core';
|
|
2
2
|
import { SafeResourceUrl } from '@angular/platform-browser';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
/**
|
|
5
|
+
* Directive to add fallback image if the original one is not reachable.
|
|
6
|
+
*/
|
|
3
7
|
export declare class FallbackImageDirective {
|
|
4
8
|
private renderer;
|
|
5
9
|
private el;
|
|
@@ -7,4 +11,6 @@ export declare class FallbackImageDirective {
|
|
|
7
11
|
fallbackApplied: EventEmitter<boolean>;
|
|
8
12
|
constructor(renderer: Renderer2, el: ElementRef);
|
|
9
13
|
onError(): void;
|
|
14
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<FallbackImageDirective, never>;
|
|
15
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<FallbackImageDirective, "[ksFallbackImage]", never, { "fallbackImg": "fallbackImg"; }, { "fallbackApplied": "fallbackApplied"; }, never>;
|
|
10
16
|
}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { EventEmitter } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
2
3
|
export declare class KeyboardNavigationDirective {
|
|
3
4
|
isOpen: boolean | undefined;
|
|
4
|
-
keyboardNavigation: EventEmitter<
|
|
5
|
+
keyboardNavigation: EventEmitter<string>;
|
|
5
6
|
/**
|
|
6
7
|
* Listener to catch keyboard's events and call the right method based on the key.
|
|
7
8
|
* For instance, pressing esc, this will call `closeGallery(Action.KEYBOARD)` and so on.
|
|
@@ -9,4 +10,6 @@ export declare class KeyboardNavigationDirective {
|
|
|
9
10
|
* @param e KeyboardEvent caught by the listener.
|
|
10
11
|
*/
|
|
11
12
|
onKeyDown(e: KeyboardEvent): void;
|
|
13
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<KeyboardNavigationDirective, never>;
|
|
14
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<KeyboardNavigationDirective, "[ksKeyboardNavigation]", never, { "isOpen": "isOpen"; }, { "keyboardNavigation": "keyboardNavigation"; }, never>;
|
|
12
15
|
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ElementRef, OnChanges, OnInit, Renderer2 } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
2
3
|
/**
|
|
3
4
|
* Directive to change margins of an element.
|
|
4
5
|
*/
|
|
@@ -38,4 +39,6 @@ export declare class MarginDirective implements OnInit, OnChanges {
|
|
|
38
39
|
* Private method to change both width and height of an element.
|
|
39
40
|
*/
|
|
40
41
|
private applyStyle;
|
|
42
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<MarginDirective, never>;
|
|
43
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<MarginDirective, "[ksMargin]", never, { "marginLeft": "marginLeft"; "marginRight": "marginRight"; "marginTop": "marginTop"; "marginBottom": "marginBottom"; }, {}, never>;
|
|
41
44
|
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { ElementRef, OnChanges, OnInit, Renderer2 } from '@angular/core';
|
|
2
2
|
import { MaxSize } from '../model/max-size.interface';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
3
4
|
/**
|
|
4
5
|
* Directive to change the max size of an element.
|
|
5
6
|
*/
|
|
@@ -27,4 +28,6 @@ export declare class MaxSizeDirective implements OnInit, OnChanges {
|
|
|
27
28
|
* Private method to change both max-width and max-height of an element.
|
|
28
29
|
*/
|
|
29
30
|
private applyStyle;
|
|
31
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<MaxSizeDirective, never>;
|
|
32
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<MaxSizeDirective, "[ksMaxSize]", never, { "maxSizeConfig": "maxSizeConfig"; }, {}, never>;
|
|
30
33
|
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { ElementRef, OnChanges, OnInit, Renderer2 } from '@angular/core';
|
|
2
2
|
import { Size } from '../model/size.interface';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
3
4
|
/**
|
|
4
5
|
* Directive to change the size of an element.
|
|
5
6
|
*/
|
|
@@ -13,13 +14,13 @@ export declare class SizeDirective implements OnInit, OnChanges {
|
|
|
13
14
|
constructor(renderer: Renderer2, el: ElementRef);
|
|
14
15
|
/**
|
|
15
16
|
* Method ´ngOnInit´ to apply the style of this directive.
|
|
16
|
-
* This is an Angular
|
|
17
|
+
* This is an Angular lifecycle hook, so its called automatically by Angular itself.
|
|
17
18
|
* In particular, it's called only one time!!!
|
|
18
19
|
*/
|
|
19
20
|
ngOnInit(): void;
|
|
20
21
|
/**
|
|
21
22
|
* Method ´ngOnChanges´ to apply the style of this directive.
|
|
22
|
-
* This is an Angular
|
|
23
|
+
* This is an Angular lifecycle hook, so its called automatically by Angular itself.
|
|
23
24
|
* In particular, it's called when any data-bound property of a directive changes!!!
|
|
24
25
|
*/
|
|
25
26
|
ngOnChanges(): void;
|
|
@@ -27,4 +28,6 @@ export declare class SizeDirective implements OnInit, OnChanges {
|
|
|
27
28
|
* Private method to change both width and height of an element.
|
|
28
29
|
*/
|
|
29
30
|
private applyStyle;
|
|
31
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SizeDirective, never>;
|
|
32
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<SizeDirective, "[ksSize]", never, { "sizeConfig": "sizeConfig"; }, {}, never>;
|
|
30
33
|
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ElementRef, OnChanges, OnInit, Renderer2 } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
2
3
|
/**
|
|
3
4
|
* Directive to change the flex-wrap css property of an element.
|
|
4
5
|
*/
|
|
@@ -27,7 +28,9 @@ export declare class WrapDirective implements OnInit, OnChanges {
|
|
|
27
28
|
*/
|
|
28
29
|
ngOnChanges(): void;
|
|
29
30
|
/**
|
|
30
|
-
* Private method to change both
|
|
31
|
+
* Private method to change both width and flex-wrap css properties.
|
|
31
32
|
*/
|
|
32
33
|
private applyStyle;
|
|
34
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<WrapDirective, never>;
|
|
35
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<WrapDirective, "[ksWrap]", never, { "wrap": "wrap"; "width": "width"; }, {}, never>;
|
|
33
36
|
}
|
|
@@ -1,10 +1,38 @@
|
|
|
1
1
|
/// <reference types="hammerjs" />
|
|
2
2
|
import { HammerGestureConfig } from '@angular/platform-browser';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
import * as i1 from "./components/plain-gallery/plain-gallery.component";
|
|
5
|
+
import * as i2 from "./components/carousel/carousel.component";
|
|
6
|
+
import * as i3 from "./components/carousel/carousel-previews/carousel-previews.component";
|
|
7
|
+
import * as i4 from "./components/upper-buttons/upper-buttons.component";
|
|
8
|
+
import * as i5 from "./components/dots/dots.component";
|
|
9
|
+
import * as i6 from "./components/previews/previews.component";
|
|
10
|
+
import * as i7 from "./components/current-image/current-image.component";
|
|
11
|
+
import * as i8 from "./components/current-image/loading-spinner/loading-spinner.component";
|
|
12
|
+
import * as i9 from "./components/accessible.component";
|
|
13
|
+
import * as i10 from "./components/modal-gallery/modal-gallery.component";
|
|
14
|
+
import * as i11 from "./directives/click-outside.directive";
|
|
15
|
+
import * as i12 from "./directives/size.directive";
|
|
16
|
+
import * as i13 from "./directives/keyboard-navigation.directive";
|
|
17
|
+
import * as i14 from "./directives/wrap.directive";
|
|
18
|
+
import * as i15 from "./directives/direction.directive";
|
|
19
|
+
import * as i16 from "./directives/a-tag-bg-image.directive";
|
|
20
|
+
import * as i17 from "./directives/description.directive";
|
|
21
|
+
import * as i18 from "./directives/margin.directive";
|
|
22
|
+
import * as i19 from "./directives/max-size.directive";
|
|
23
|
+
import * as i20 from "./directives/fallback-image.directive";
|
|
24
|
+
import * as i21 from "@angular/common";
|
|
25
|
+
import * as i22 from "@angular/cdk/overlay";
|
|
3
26
|
export declare class KsHammerGestureConfig extends HammerGestureConfig {
|
|
4
27
|
buildHammer(element: HTMLElement): HammerManager;
|
|
28
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<KsHammerGestureConfig, never>;
|
|
29
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<KsHammerGestureConfig>;
|
|
5
30
|
}
|
|
6
31
|
/**
|
|
7
32
|
* Module to import it in the root module of your application.
|
|
8
33
|
*/
|
|
9
34
|
export declare class GalleryModule {
|
|
35
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<GalleryModule, never>;
|
|
36
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<GalleryModule, [typeof i1.PlainGalleryComponent, typeof i2.CarouselComponent, typeof i3.CarouselPreviewsComponent, typeof i4.UpperButtonsComponent, typeof i5.DotsComponent, typeof i6.PreviewsComponent, typeof i7.CurrentImageComponent, typeof i8.LoadingSpinnerComponent, typeof i9.AccessibleComponent, typeof i10.ModalGalleryComponent, typeof i11.ClickOutsideDirective, typeof i12.SizeDirective, typeof i13.KeyboardNavigationDirective, typeof i14.WrapDirective, typeof i15.DirectionDirective, typeof i16.ATagBgImageDirective, typeof i17.DescriptionDirective, typeof i18.MarginDirective, typeof i19.MaxSizeDirective, typeof i20.FallbackImageDirective], [typeof i21.CommonModule, typeof i22.OverlayModule], [typeof i1.PlainGalleryComponent, typeof i2.CarouselComponent]>;
|
|
37
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<GalleryModule>;
|
|
10
38
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Interface `KeyboardConfig` to assign custom
|
|
2
|
+
* Interface `KeyboardConfig` to assign custom codes to ESC, RIGHT and LEFT keyboard's actions.
|
|
3
3
|
*/
|
|
4
4
|
export interface KeyboardConfig {
|
|
5
|
-
esc?:
|
|
6
|
-
right?:
|
|
7
|
-
left?:
|
|
5
|
+
esc?: string;
|
|
6
|
+
right?: string;
|
|
7
|
+
left?: string;
|
|
8
8
|
}
|
|
@@ -1,10 +1,13 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Enum `Keyboard` with keys and their relative
|
|
2
|
+
* Enum `Keyboard` with keys and their relative codes.
|
|
3
3
|
*/
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
4
|
+
import { DOWN_ARROW_CODE, ESC_CODE, LEFT_ARROW_CODE, RIGHT_ARROW_CODE, UP_ARROW_CODE } from '../utils/user-input.util';
|
|
5
|
+
declare type Keyboard = Readonly<{
|
|
6
|
+
ESC: typeof ESC_CODE;
|
|
7
|
+
LEFT_ARROW: typeof LEFT_ARROW_CODE;
|
|
8
|
+
RIGHT_ARROW: typeof RIGHT_ARROW_CODE;
|
|
9
|
+
UP_ARROW: typeof UP_ARROW_CODE;
|
|
10
|
+
DOWN_ARROW: typeof DOWN_ARROW_CODE;
|
|
11
|
+
}>;
|
|
12
|
+
export declare const Keyboard: Keyboard;
|
|
13
|
+
export {};
|
|
@@ -11,20 +11,33 @@ import { CarouselImageConfig } from './carousel-image-config.interface';
|
|
|
11
11
|
import { CarouselPreviewConfig } from './carousel-preview-config.interface';
|
|
12
12
|
import { PlayConfig } from './play-config.interface';
|
|
13
13
|
import { KeyboardServiceConfig } from './keyboard-service-config.interface';
|
|
14
|
-
export interface
|
|
15
|
-
slideConfig?: SlideConfig;
|
|
14
|
+
export interface AccessibleLibConfig {
|
|
16
15
|
accessibilityConfig?: AccessibilityConfig;
|
|
16
|
+
}
|
|
17
|
+
export interface CommonLibConfig {
|
|
17
18
|
previewConfig?: PreviewConfig;
|
|
18
|
-
buttonsConfig?: ButtonsConfig;
|
|
19
19
|
dotsConfig?: DotsConfig;
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
20
|
+
slideConfig?: SlideConfig;
|
|
21
|
+
}
|
|
22
|
+
export interface KeyboardServiceLibConfig {
|
|
23
|
+
keyboardServiceConfig?: KeyboardServiceConfig;
|
|
24
|
+
}
|
|
25
|
+
export interface CarouselLibConfig extends CommonLibConfig, AccessibleLibConfig, KeyboardServiceLibConfig {
|
|
23
26
|
carouselConfig?: CarouselConfig;
|
|
24
27
|
carouselImageConfig?: CarouselImageConfig;
|
|
25
28
|
carouselPreviewsConfig?: CarouselPreviewConfig;
|
|
26
29
|
carouselPlayConfig?: PlayConfig;
|
|
27
30
|
carouselDotsConfig?: DotsConfig;
|
|
31
|
+
carouselSlideInfinite?: boolean;
|
|
32
|
+
}
|
|
33
|
+
export interface ModalLibConfig extends CommonLibConfig, AccessibleLibConfig, KeyboardServiceLibConfig {
|
|
28
34
|
enableCloseOutside?: boolean;
|
|
29
|
-
|
|
35
|
+
keyboardConfig?: KeyboardConfig;
|
|
36
|
+
currentImageConfig?: CurrentImageConfig;
|
|
37
|
+
buttonsConfig?: ButtonsConfig;
|
|
38
|
+
}
|
|
39
|
+
export interface PlainLibConfig extends AccessibleLibConfig {
|
|
40
|
+
plainGalleryConfig?: PlainGalleryConfig;
|
|
41
|
+
}
|
|
42
|
+
export interface LibConfig extends ModalLibConfig, PlainLibConfig, CarouselLibConfig {
|
|
30
43
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { Image } from './image.class';
|
|
2
|
-
import {
|
|
2
|
+
import { ModalLibConfig } from './lib-config.interface';
|
|
3
3
|
export interface ModalGalleryConfig {
|
|
4
4
|
id: number;
|
|
5
5
|
images: Image[];
|
|
6
6
|
currentImage: Image;
|
|
7
|
-
libConfig?:
|
|
7
|
+
libConfig?: ModalLibConfig;
|
|
8
8
|
}
|
|
@@ -9,7 +9,7 @@ export interface PlainGalleryConfig {
|
|
|
9
9
|
}
|
|
10
10
|
/**
|
|
11
11
|
* Interface `PlainGalleryLayout` to configure the layout. This interface isn't used directly, instead
|
|
12
|
-
* refers to either `LineLayout`, `GridLayout
|
|
12
|
+
* refers to either `LineLayout`, `GridLayout`.
|
|
13
13
|
*/
|
|
14
14
|
export interface PlainGalleryLayout {
|
|
15
15
|
}
|
|
@@ -30,14 +30,6 @@ export declare class GridLayout implements PlainGalleryLayout {
|
|
|
30
30
|
size: Size;
|
|
31
31
|
constructor(size: Size, breakConfig: BreakConfig);
|
|
32
32
|
}
|
|
33
|
-
/**
|
|
34
|
-
* Class `AdvancedLayout` to configure a fully custom plain gallery.
|
|
35
|
-
*/
|
|
36
|
-
export declare class AdvancedLayout implements PlainGalleryLayout {
|
|
37
|
-
modalOpenerByIndex: number;
|
|
38
|
-
hideDefaultPlainGallery: boolean;
|
|
39
|
-
constructor(modalOpenerByIndex: number, hideDefaultPlainGallery: boolean);
|
|
40
|
-
}
|
|
41
33
|
/**
|
|
42
34
|
* Enum `PlainGalleryStrategy` to choose the behaviour of the plain gallery.
|
|
43
35
|
*/
|
|
@@ -11,6 +11,7 @@ import { CarouselImageConfig } from '../model/carousel-image-config.interface';
|
|
|
11
11
|
import { BreakpointsConfig, CarouselPreviewConfig } from '../model/carousel-preview-config.interface';
|
|
12
12
|
import { KeyboardServiceConfig } from '../model/keyboard-service-config.interface';
|
|
13
13
|
import { LibConfig } from '../model/lib-config.interface';
|
|
14
|
+
import * as i0 from "@angular/core";
|
|
14
15
|
export declare const DEFAULT_PREVIEW_SIZE: Size;
|
|
15
16
|
export declare const DEFAULT_LAYOUT: LineLayout;
|
|
16
17
|
export declare const DEFAULT_PLAIN_CONFIG: PlainGalleryConfig;
|
|
@@ -35,4 +36,6 @@ export declare class ConfigService {
|
|
|
35
36
|
getConfig(id: number): LibConfig | undefined;
|
|
36
37
|
setConfig(id: number, obj: LibConfig | undefined): void;
|
|
37
38
|
private initIfNotExists;
|
|
39
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ConfigService, never>;
|
|
40
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<ConfigService>;
|
|
38
41
|
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
1
2
|
/**
|
|
2
3
|
* Service to check if the provided id is unique
|
|
3
4
|
*/
|
|
@@ -14,8 +15,11 @@ export declare class IdValidatorService {
|
|
|
14
15
|
/**
|
|
15
16
|
* Method to remove a reserved id. In this way you are able to use the id again for another instance of the library.
|
|
16
17
|
* @param galleryId number or undefined that represents the unique id of the gallery.
|
|
17
|
-
* @return boolean true if success. false is never returned, instead an exception is thrown
|
|
18
|
+
* @return boolean true if success. false is never returned, instead an exception is thrown*
|
|
18
19
|
* @throws a error with a message if galleryId is neither integer or < 0
|
|
20
|
+
* * this should be improved without return true, because it doesn't make sense! :(
|
|
19
21
|
*/
|
|
20
22
|
remove(galleryId: number | undefined): boolean;
|
|
23
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<IdValidatorService, never>;
|
|
24
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<IdValidatorService>;
|
|
21
25
|
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { LibConfig } from '../model/lib-config.interface';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
2
3
|
/**
|
|
3
4
|
* Service to intercept ctrl+s (or cmd+s on macOS) using a third-party library, called Mousetrap.
|
|
4
5
|
*/
|
|
@@ -7,9 +8,9 @@ export declare class KeyboardService {
|
|
|
7
8
|
/**
|
|
8
9
|
* Private Mousetrap variable to store the instance.
|
|
9
10
|
*/
|
|
10
|
-
private
|
|
11
|
+
private mousetrapInstance;
|
|
11
12
|
constructor(platformId: any);
|
|
12
|
-
init(config: LibConfig):
|
|
13
|
+
init(config: LibConfig): Promise<void>;
|
|
13
14
|
/**
|
|
14
15
|
* Method to add a lister for ctrl+s/cmd+s keyboard events.
|
|
15
16
|
* @param (e: KeyboardEvent, combo: string) => any onBind callback function to add shortcuts
|
|
@@ -20,4 +21,6 @@ export declare class KeyboardService {
|
|
|
20
21
|
* to free resources ad prevent leaks.
|
|
21
22
|
*/
|
|
22
23
|
reset(config: LibConfig): void;
|
|
24
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<KeyboardService, never>;
|
|
25
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<KeyboardService>;
|
|
23
26
|
}
|