@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.
Files changed (161) hide show
  1. package/CHANGELOG.md +153 -0
  2. package/CONTRIBUTING.md +20 -38
  3. package/LICENSE +1 -1
  4. package/README.md +36 -42
  5. package/esm2020/ks89-angular-modal-gallery.mjs +5 -0
  6. package/esm2020/lib/components/accessibility-default.mjs +41 -0
  7. package/esm2020/lib/components/accessible.component.mjs +130 -0
  8. package/esm2020/lib/components/carousel/carousel-previews/carousel-previews.component.mjs +462 -0
  9. package/esm2020/lib/components/carousel/carousel.component.mjs +747 -0
  10. package/esm2020/lib/components/components.mjs +50 -0
  11. package/esm2020/lib/components/current-image/current-image.component.mjs +616 -0
  12. package/esm2020/lib/components/current-image/loading-spinner/loading-spinner.component.mjs +80 -0
  13. package/esm2020/lib/components/dots/dots.component.mjs +127 -0
  14. package/esm2020/lib/components/modal-gallery/modal-gallery-ref.mjs +103 -0
  15. package/esm2020/lib/components/modal-gallery/modal-gallery.component.mjs +523 -0
  16. package/esm2020/lib/components/modal-gallery/modal-gallery.service.mjs +187 -0
  17. package/esm2020/lib/components/modal-gallery/modal-gallery.tokens.mjs +26 -0
  18. package/esm2020/lib/components/plain-gallery/plain-gallery.component.mjs +249 -0
  19. package/esm2020/lib/components/previews/previews.component.mjs +332 -0
  20. package/esm2020/lib/components/upper-buttons/upper-buttons-default.mjs +76 -0
  21. package/esm2020/lib/components/upper-buttons/upper-buttons.component.mjs +249 -0
  22. package/esm2020/lib/directives/a-tag-bg-image.directive.mjs +78 -0
  23. package/esm2020/lib/directives/click-outside.directive.mjs +91 -0
  24. package/esm2020/lib/directives/description.directive.mjs +98 -0
  25. package/esm2020/lib/directives/direction.directive.mjs +73 -0
  26. package/esm2020/lib/directives/directives.mjs +49 -0
  27. package/esm2020/lib/directives/fallback-image.directive.mjs +59 -0
  28. package/esm2020/lib/directives/keyboard-navigation.directive.mjs +58 -0
  29. package/esm2020/lib/directives/margin.directive.mjs +84 -0
  30. package/esm2020/lib/directives/max-size.directive.mjs +75 -0
  31. package/esm2020/lib/directives/size.directive.mjs +76 -0
  32. package/{esm2015/lib/directives/size.directive.js → esm2020/lib/directives/wrap.directive.mjs} +23 -22
  33. package/esm2020/lib/modal-gallery.module.mjs +94 -0
  34. package/esm2020/lib/model/accessibility.interface.mjs +25 -0
  35. package/esm2020/lib/model/action.enum.mjs +36 -0
  36. package/esm2020/lib/model/buttons-config.interface.mjs +62 -0
  37. package/esm2020/lib/model/carousel-config.interface.mjs +25 -0
  38. package/esm2020/lib/model/carousel-image-config.interface.mjs +25 -0
  39. package/esm2020/lib/model/carousel-preview-config.interface.mjs +25 -0
  40. package/{esm2015/lib/model/keyboard-service-config.interface.js → esm2020/lib/model/current-image-config.interface.mjs} +2 -2
  41. package/esm2020/lib/model/description.interface.mjs +33 -0
  42. package/{esm2015/lib/model/preview-config.interface.js → esm2020/lib/model/dots-config.interface.mjs} +2 -2
  43. package/esm2020/lib/model/image-internal.class.mjs +35 -0
  44. package/esm2020/lib/model/image.class.mjs +54 -0
  45. package/esm2020/lib/model/interaction-event.interface.mjs +2 -0
  46. package/esm2020/lib/model/keyboard-config.interface.mjs +25 -0
  47. package/esm2020/lib/model/keyboard-service-config.interface.mjs +25 -0
  48. package/esm2020/lib/model/keyboard.enum.mjs +35 -0
  49. package/esm2020/lib/model/lib-config.interface.mjs +25 -0
  50. package/esm2020/lib/model/loading-config.interface.mjs +37 -0
  51. package/{esm2015/lib/model/dots-config.interface.js → esm2020/lib/model/max-size.interface.mjs} +2 -2
  52. package/{esm2015/lib/model/carousel-preview-config.interface.js → esm2020/lib/model/modal-gallery-config.interface.mjs} +2 -2
  53. package/esm2020/lib/model/plain-gallery-config.interface.mjs +55 -0
  54. package/{esm2015/lib/model/image-internal.class.js → esm2020/lib/model/play-config.interface.mjs} +3 -13
  55. package/esm2020/lib/model/preview-config.interface.mjs +25 -0
  56. package/esm2020/lib/model/size.interface.mjs +25 -0
  57. package/{esm2015/lib/model/carousel-config.interface.js → esm2020/lib/model/slide-config.interface.mjs} +2 -2
  58. package/esm2020/lib/services/config.service.mjs +396 -0
  59. package/esm2020/lib/services/id-validator.service.mjs +71 -0
  60. package/esm2020/lib/services/keyboard.service.mjs +111 -0
  61. package/esm2020/lib/utils/image.util.mjs +48 -0
  62. package/esm2020/lib/utils/user-input.util.mjs +104 -0
  63. package/esm2020/public-api.mjs +42 -0
  64. package/fesm2015/ks89-angular-modal-gallery.mjs +5782 -0
  65. package/fesm2015/ks89-angular-modal-gallery.mjs.map +1 -0
  66. package/{fesm2015/ks89-angular-modal-gallery.js → fesm2020/ks89-angular-modal-gallery.mjs} +3046 -2947
  67. package/fesm2020/ks89-angular-modal-gallery.mjs.map +1 -0
  68. package/ks89-angular-modal-gallery.d.ts +1 -24
  69. package/lib/components/accessible.component.d.ts +5 -2
  70. package/lib/components/carousel/carousel-previews/carousel-previews.component.d.ts +7 -11
  71. package/lib/components/carousel/carousel.component.d.ts +28 -67
  72. package/lib/components/current-image/current-image.component.d.ts +10 -4
  73. package/lib/components/current-image/loading-spinner/loading-spinner.component.d.ts +3 -0
  74. package/lib/components/dots/dots.component.d.ts +7 -0
  75. package/lib/components/modal-gallery/modal-gallery-ref.d.ts +35 -0
  76. package/lib/components/modal-gallery/modal-gallery.component.d.ts +58 -50
  77. package/lib/components/modal-gallery/modal-gallery.service.d.ts +60 -1
  78. package/lib/components/plain-gallery/plain-gallery.component.d.ts +18 -9
  79. package/lib/components/previews/previews.component.d.ts +9 -0
  80. package/lib/components/upper-buttons/upper-buttons.component.d.ts +8 -1
  81. package/lib/directives/a-tag-bg-image.directive.d.ts +3 -0
  82. package/lib/directives/click-outside.directive.d.ts +3 -0
  83. package/lib/directives/description.directive.d.ts +3 -0
  84. package/lib/directives/direction.directive.d.ts +3 -0
  85. package/lib/directives/fallback-image.directive.d.ts +6 -0
  86. package/lib/directives/keyboard-navigation.directive.d.ts +4 -1
  87. package/lib/directives/margin.directive.d.ts +3 -0
  88. package/lib/directives/max-size.directive.d.ts +3 -0
  89. package/lib/directives/size.directive.d.ts +5 -2
  90. package/lib/directives/wrap.directive.d.ts +4 -1
  91. package/lib/modal-gallery.module.d.ts +28 -0
  92. package/lib/model/carousel-config.interface.d.ts +0 -1
  93. package/lib/model/keyboard-config.interface.d.ts +4 -4
  94. package/lib/model/keyboard.enum.d.ts +11 -8
  95. package/lib/model/lib-config.interface.d.ts +20 -7
  96. package/lib/model/modal-gallery-config.interface.d.ts +2 -2
  97. package/lib/model/plain-gallery-config.interface.d.ts +1 -9
  98. package/lib/services/config.service.d.ts +3 -0
  99. package/lib/services/id-validator.service.d.ts +5 -1
  100. package/lib/services/keyboard.service.d.ts +5 -2
  101. package/lib/utils/user-input.util.d.ts +35 -26
  102. package/package.json +28 -16
  103. package/public-api.d.ts +2 -2
  104. package/bundles/ks89-angular-modal-gallery.umd.js +0 -5906
  105. package/bundles/ks89-angular-modal-gallery.umd.js.map +0 -1
  106. package/bundles/ks89-angular-modal-gallery.umd.min.js +0 -16
  107. package/bundles/ks89-angular-modal-gallery.umd.min.js.map +0 -1
  108. package/esm2015/ks89-angular-modal-gallery.js +0 -29
  109. package/esm2015/lib/components/accessibility-default.js +0 -41
  110. package/esm2015/lib/components/accessible.component.js +0 -127
  111. package/esm2015/lib/components/carousel/carousel-previews/carousel-previews.component.js +0 -466
  112. package/esm2015/lib/components/carousel/carousel.component.js +0 -772
  113. package/esm2015/lib/components/components.js +0 -50
  114. package/esm2015/lib/components/current-image/current-image.component.js +0 -590
  115. package/esm2015/lib/components/current-image/loading-spinner/loading-spinner.component.js +0 -80
  116. package/esm2015/lib/components/dots/dots.component.js +0 -127
  117. package/esm2015/lib/components/modal-gallery/modal-gallery-ref.js +0 -45
  118. package/esm2015/lib/components/modal-gallery/modal-gallery.component.js +0 -534
  119. package/esm2015/lib/components/modal-gallery/modal-gallery.service.js +0 -135
  120. package/esm2015/lib/components/modal-gallery/modal-gallery.tokens.js +0 -3
  121. package/esm2015/lib/components/plain-gallery/plain-gallery.component.js +0 -243
  122. package/esm2015/lib/components/previews/previews.component.js +0 -331
  123. package/esm2015/lib/components/upper-buttons/upper-buttons-default.js +0 -76
  124. package/esm2015/lib/components/upper-buttons/upper-buttons.component.js +0 -256
  125. package/esm2015/lib/directives/a-tag-bg-image.directive.js +0 -78
  126. package/esm2015/lib/directives/click-outside.directive.js +0 -85
  127. package/esm2015/lib/directives/description.directive.js +0 -99
  128. package/esm2015/lib/directives/direction.directive.js +0 -73
  129. package/esm2015/lib/directives/directives.js +0 -49
  130. package/esm2015/lib/directives/fallback-image.directive.js +0 -54
  131. package/esm2015/lib/directives/keyboard-navigation.directive.js +0 -52
  132. package/esm2015/lib/directives/margin.directive.js +0 -82
  133. package/esm2015/lib/directives/max-size.directive.js +0 -76
  134. package/esm2015/lib/directives/wrap.directive.js +0 -74
  135. package/esm2015/lib/modal-gallery.module.js +0 -64
  136. package/esm2015/lib/model/accessibility.interface.js +0 -25
  137. package/esm2015/lib/model/action.enum.js +0 -36
  138. package/esm2015/lib/model/buttons-config.interface.js +0 -66
  139. package/esm2015/lib/model/carousel-image-config.interface.js +0 -25
  140. package/esm2015/lib/model/current-image-config.interface.js +0 -25
  141. package/esm2015/lib/model/description.interface.js +0 -33
  142. package/esm2015/lib/model/image.class.js +0 -54
  143. package/esm2015/lib/model/interaction-event.interface.js +0 -2
  144. package/esm2015/lib/model/keyboard-config.interface.js +0 -25
  145. package/esm2015/lib/model/keyboard.enum.js +0 -35
  146. package/esm2015/lib/model/lib-config.interface.js +0 -25
  147. package/esm2015/lib/model/loading-config.interface.js +0 -37
  148. package/esm2015/lib/model/max-size.interface.js +0 -25
  149. package/esm2015/lib/model/modal-gallery-config.interface.js +0 -25
  150. package/esm2015/lib/model/plain-gallery-config.interface.js +0 -64
  151. package/esm2015/lib/model/play-config.interface.js +0 -25
  152. package/esm2015/lib/model/size.interface.js +0 -25
  153. package/esm2015/lib/model/slide-config.interface.js +0 -25
  154. package/esm2015/lib/services/config.service.js +0 -392
  155. package/esm2015/lib/services/id-validator.service.js +0 -71
  156. package/esm2015/lib/services/keyboard.service.js +0 -108
  157. package/esm2015/lib/utils/image.util.js +0 -48
  158. package/esm2015/lib/utils/user-input.util.js +0 -95
  159. package/esm2015/public-api.js +0 -46
  160. package/fesm2015/ks89-angular-modal-gallery.js.map +0 -1
  161. package/ks89-angular-modal-gallery.metadata.json +0 -1
@@ -1,52 +1,69 @@
1
1
  /**
2
2
  * Key of the keyboard's key `enter`
3
3
  */
4
- export declare const ENTER_KEY = "Enter";
4
+ export declare const ENTER_KEY: string;
5
5
  /**
6
6
  * Code of the keyboard's key `enter`
7
7
  */
8
- export declare const ENTER_CODE = "Enter";
8
+ export declare const ENTER_CODE: string;
9
+ /**
10
+ * Key of the keyboard's key `esc`
11
+ */
12
+ export declare const ESC_KEY: string;
13
+ /**
14
+ * Code of the keyboard's key `esc`
15
+ */
16
+ export declare const ESC_CODE: string;
9
17
  /**
10
18
  * Key of the keyboard's key 'right arrow'
11
19
  */
12
- export declare const RIGHT_ARROW_KEY = "ArrowRight";
20
+ export declare const RIGHT_ARROW_KEY: string;
13
21
  /**
14
22
  * Code of the keyboard's key 'right arrow'
15
23
  */
16
- export declare const RIGHT_ARROW_CODE = "ArrowRight";
24
+ export declare const RIGHT_ARROW_CODE: string;
17
25
  /**
18
- * KeyCode of the keyboard's key 'right arrow'
19
- * Used in unit tests only
26
+ * Key of the keyboard's key 'left arrow'
20
27
  */
21
- export declare const RIGHT_ARROW_KEYCODE = 39;
28
+ export declare const LEFT_ARROW_KEY: string;
29
+ /**
30
+ * Code of the keyboard's key 'left arrow'
31
+ */
32
+ export declare const LEFT_ARROW_CODE: string;
22
33
  /**
23
34
  * Key of the keyboard's key 'left arrow'
24
35
  */
25
- export declare const LEFT_ARROW_KEY = "ArrowLeft";
36
+ export declare const UP_ARROW_KEY: string;
26
37
  /**
27
38
  * Code of the keyboard's key 'left arrow'
28
39
  */
29
- export declare const LEFT_ARROW_CODE = "ArrowLeft";
40
+ export declare const UP_ARROW_CODE: string;
41
+ /**
42
+ * Key of the keyboard's key 'left arrow'
43
+ */
44
+ export declare const DOWN_ARROW_KEY: string;
30
45
  /**
31
- * KeyCode of the keyboard's key 'left arrow'
32
- * Used in unit tests only
46
+ * Code of the keyboard's key 'left arrow'
33
47
  */
34
- export declare const LEFT_ARROW_KEYCODE = 37;
48
+ export declare const DOWN_ARROW_CODE: string;
35
49
  /**
36
50
  * Key of the keyboard's key `space`
37
51
  */
38
- export declare const SPACE_KEY = "";
52
+ export declare const SPACE_KEY: string;
39
53
  /**
40
54
  * Code of the keyboard's key `space`
41
55
  */
42
- export declare const SPACE_CODE = "Space";
56
+ export declare const SPACE_CODE: string;
57
+ /**
58
+ * Const to represent the right direction
59
+ */
60
+ export declare const DIRECTION_RIGHT: string;
43
61
  /**
44
- * KeyCode of the keyboard's key 'space'
45
- * Used in unit tests only
62
+ * Const to represent the left direction
46
63
  */
47
- export declare const SPACE_KEYCODE = 32;
64
+ export declare const DIRECTION_LEFT: string;
48
65
  /**
49
- * KeyCode of the main mouse button
66
+ * Keycode of the main mouse button
50
67
  */
51
68
  export declare const MOUSE_MAIN_BUTTON_CLICK = 0;
52
69
  /**
@@ -61,11 +78,3 @@ export declare const PREV = -1;
61
78
  * Const NOTHING to represents a situation when it isn't both NEXT and PREV
62
79
  */
63
80
  export declare const NOTHING = 0;
64
- /**
65
- * Const to represent the right direction
66
- */
67
- export declare const DIRECTION_RIGHT = "right";
68
- /**
69
- * Const to represent the left direction
70
- */
71
- export declare const DIRECTION_LEFT = "left";
package/package.json CHANGED
@@ -1,25 +1,25 @@
1
1
  {
2
2
  "name": "@ks89/angular-modal-gallery",
3
- "version": "8.0.0-beta.5",
3
+ "version": "9.0.0",
4
4
  "description": "Image gallery for Angular",
5
5
  "license": "MIT",
6
6
  "author": "Stefano Cappa",
7
7
  "engines": {
8
- "node": ">=14.7.0",
9
- "npm": ">=6.14.7"
8
+ "node": ">=16.3.0",
9
+ "npm": ">=7.16.0"
10
10
  },
11
11
  "homepage": "https://ks89.github.io/angular-modal-gallery-2020-v8.github.io/",
12
12
  "dependencies": {
13
- "tslib": ">=1.10.0"
13
+ "tslib": ">=2.3.0"
14
14
  },
15
15
  "peerDependencies": {
16
- "@angular/platform-browser": ">=9.0.0",
17
- "@angular/common": ">=9.0.0",
18
- "@angular/core": ">=9.0.0",
19
- "@angular/cdk": ">=9.0.0",
16
+ "@angular/platform-browser": ">=13.0.0",
17
+ "@angular/common": ">=13.0.0",
18
+ "@angular/core": ">=13.0.0",
19
+ "@angular/cdk": ">=13.0.0",
20
20
  "hammerjs": ">=2.0.8",
21
21
  "mousetrap": ">=1.6.5",
22
- "rxjs": ">=6.5.4"
22
+ "rxjs": ">=7.4.0"
23
23
  },
24
24
  "keywords": [
25
25
  "angular-modal-gallery",
@@ -54,12 +54,24 @@
54
54
  "bugs": {
55
55
  "url": "https://github.com/Ks89/angular-modal-gallery/issues"
56
56
  },
57
- "main": "bundles/ks89-angular-modal-gallery.umd.js",
58
- "module": "fesm2015/ks89-angular-modal-gallery.js",
59
- "es2015": "fesm2015/ks89-angular-modal-gallery.js",
60
- "esm2015": "esm2015/ks89-angular-modal-gallery.js",
61
- "fesm2015": "fesm2015/ks89-angular-modal-gallery.js",
57
+ "module": "fesm2015/ks89-angular-modal-gallery.mjs",
58
+ "es2020": "fesm2020/ks89-angular-modal-gallery.mjs",
59
+ "esm2020": "esm2020/ks89-angular-modal-gallery.mjs",
60
+ "fesm2020": "fesm2020/ks89-angular-modal-gallery.mjs",
61
+ "fesm2015": "fesm2015/ks89-angular-modal-gallery.mjs",
62
62
  "typings": "ks89-angular-modal-gallery.d.ts",
63
- "metadata": "ks89-angular-modal-gallery.metadata.json",
63
+ "exports": {
64
+ "./package.json": {
65
+ "default": "./package.json"
66
+ },
67
+ ".": {
68
+ "types": "./ks89-angular-modal-gallery.d.ts",
69
+ "esm2020": "./esm2020/ks89-angular-modal-gallery.mjs",
70
+ "es2020": "./fesm2020/ks89-angular-modal-gallery.mjs",
71
+ "es2015": "./fesm2015/ks89-angular-modal-gallery.mjs",
72
+ "node": "./fesm2015/ks89-angular-modal-gallery.mjs",
73
+ "default": "./fesm2020/ks89-angular-modal-gallery.mjs"
74
+ }
75
+ },
64
76
  "sideEffects": false
65
- }
77
+ }
package/public-api.d.ts CHANGED
@@ -16,14 +16,14 @@ export { PlayConfig } from './lib/model/play-config.interface';
16
16
  export { CarouselImageConfig } from './lib/model/carousel-image-config.interface';
17
17
  export { Size } from './lib/model/size.interface';
18
18
  export { ButtonsConfig, ButtonsStrategy, ButtonType, ButtonEvent } from './lib/model/buttons-config.interface';
19
- export { LibConfig } from './lib/model/lib-config.interface';
19
+ export { ModalLibConfig, PlainLibConfig, CarouselLibConfig } from './lib/model/lib-config.interface';
20
20
  export { ModalGalleryConfig } from './lib/model/modal-gallery-config.interface';
21
21
  export { CurrentImageConfig } from './lib/model/current-image-config.interface';
22
22
  export { LoadingConfig, LoadingType } from './lib/model/loading-config.interface';
23
23
  export { InteractionEvent } from './lib/model/interaction-event.interface';
24
24
  export { KS_DEFAULT_ACCESSIBILITY_CONFIG } from './lib/components/accessibility-default';
25
25
  export { KS_DEFAULT_BTN_FULL_SCREEN, KS_DEFAULT_BTN_CLOSE, KS_DEFAULT_BTN_DELETE, KS_DEFAULT_BTN_DOWNLOAD, KS_DEFAULT_BTN_EXTURL, KS_DEFAULT_SIZE } from './lib/components/upper-buttons/upper-buttons-default';
26
- export { PlainGalleryConfig, PlainGalleryLayout, LineLayout, GridLayout, AdvancedLayout, PlainGalleryStrategy, BreakConfig } from './lib/model/plain-gallery-config.interface';
26
+ export { PlainGalleryConfig, PlainGalleryLayout, LineLayout, GridLayout, PlainGalleryStrategy, BreakConfig } from './lib/model/plain-gallery-config.interface';
27
27
  export { ModalGalleryComponent } from './lib/components/modal-gallery/modal-gallery.component';
28
28
  export { PlainGalleryComponent } from './lib/components/plain-gallery/plain-gallery.component';
29
29
  export { CarouselComponent } from './lib/components/carousel/carousel.component';