wj-elements 0.2.0-alpha.4 → 0.2.0-alpha.5

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 (243) hide show
  1. package/dist/packages/wje-sliding-container/sliding-container.element.d.ts +2 -2
  2. package/dist/wje-file-upload.js +1 -0
  3. package/dist/wje-file-upload.js.map +1 -1
  4. package/package.json +1 -1
  5. package/dist/index.d.ts +0 -107
  6. package/dist/internals/form-associated-element.d.ts +0 -143
  7. package/dist/localize/localize.d.ts +0 -48
  8. package/dist/translations/en-gb.d.ts +0 -18
  9. package/dist/translations/sk-sk.d.ts +0 -13
  10. package/dist/utils/animations.d.ts +0 -2
  11. package/dist/utils/base-path.d.ts +0 -14
  12. package/dist/utils/date.d.ts +0 -2
  13. package/dist/utils/element-utils.d.ts +0 -46
  14. package/dist/utils/event.d.ts +0 -67
  15. package/dist/utils/icon-library.d.ts +0 -3
  16. package/dist/utils/localize.d.ts +0 -4
  17. package/dist/utils/permissions.d.ts +0 -40
  18. package/dist/utils/universal-service.d.ts +0 -18
  19. package/dist/utils/utils.d.ts +0 -1
  20. package/dist/wje-accordion/accordion.d.ts +0 -2
  21. package/dist/wje-accordion/accordion.element.d.ts +0 -72
  22. package/dist/wje-accordion/accordion.test.d.ts +0 -0
  23. package/dist/wje-accordion-item/accordion-item.d.ts +0 -2
  24. package/dist/wje-accordion-item/accordion-item.element.d.ts +0 -40
  25. package/dist/wje-animation/animation.d.ts +0 -2
  26. package/dist/wje-animation/animation.element.d.ts +0 -158
  27. package/dist/wje-aside/aside.d.ts +0 -2
  28. package/dist/wje-aside/aside.element.d.ts +0 -31
  29. package/dist/wje-avatar/avatar.d.ts +0 -2
  30. package/dist/wje-avatar/avatar.element.d.ts +0 -76
  31. package/dist/wje-avatar/avatar.test.d.ts +0 -1
  32. package/dist/wje-avatar/service/service.d.ts +0 -52
  33. package/dist/wje-badge/badge.d.ts +0 -2
  34. package/dist/wje-badge/badge.element.d.ts +0 -35
  35. package/dist/wje-badge/badge.test.d.ts +0 -1
  36. package/dist/wje-breadcrumb/breadcrumb.d.ts +0 -2
  37. package/dist/wje-breadcrumb/breadcrumb.element.d.ts +0 -98
  38. package/dist/wje-breadcrumbs/breadcrumbs.d.ts +0 -2
  39. package/dist/wje-breadcrumbs/breadcrumbs.element.d.ts +0 -105
  40. package/dist/wje-breadcrumbs/breadcrumbs.test.d.ts +0 -1
  41. package/dist/wje-button/button.d.ts +0 -2
  42. package/dist/wje-button/button.element.d.ts +0 -204
  43. package/dist/wje-button/button.test.d.ts +0 -1
  44. package/dist/wje-button-group/button-group.d.ts +0 -2
  45. package/dist/wje-button-group/button-group.element.d.ts +0 -96
  46. package/dist/wje-card/card.d.ts +0 -2
  47. package/dist/wje-card/card.element.d.ts +0 -31
  48. package/dist/wje-card-content/card-content.d.ts +0 -2
  49. package/dist/wje-card-content/card-content.element.d.ts +0 -22
  50. package/dist/wje-card-controls/card-controls.d.ts +0 -2
  51. package/dist/wje-card-controls/card-controls.element.d.ts +0 -23
  52. package/dist/wje-card-header/card-header.d.ts +0 -2
  53. package/dist/wje-card-header/card-header.element.d.ts +0 -22
  54. package/dist/wje-card-subtitle/card-subtitle.d.ts +0 -2
  55. package/dist/wje-card-subtitle/card-subtitle.element.d.ts +0 -30
  56. package/dist/wje-card-title/card-title.d.ts +0 -2
  57. package/dist/wje-card-title/card-title.element.d.ts +0 -32
  58. package/dist/wje-carousel/carousel.d.ts +0 -2
  59. package/dist/wje-carousel/carousel.element.d.ts +0 -154
  60. package/dist/wje-carousel-item/carousel-item.d.ts +0 -2
  61. package/dist/wje-carousel-item/carousel-item.element.d.ts +0 -38
  62. package/dist/wje-checkbox/checkbox.d.ts +0 -2
  63. package/dist/wje-checkbox/checkbox.element.d.ts +0 -100
  64. package/dist/wje-chip/chip.d.ts +0 -2
  65. package/dist/wje-chip/chip.element.d.ts +0 -76
  66. package/dist/wje-chip/chip.test.d.ts +0 -1
  67. package/dist/wje-col/col.d.ts +0 -2
  68. package/dist/wje-col/col.element.d.ts +0 -16
  69. package/dist/wje-color-picker/color-picker.d.ts +0 -2
  70. package/dist/wje-color-picker/color-picker.element.d.ts +0 -230
  71. package/dist/wje-color-picker/color-picker.test.d.ts +0 -1
  72. package/dist/wje-container/container.d.ts +0 -2
  73. package/dist/wje-container/container.element.d.ts +0 -31
  74. package/dist/wje-copy-button/copy-button.d.ts +0 -2
  75. package/dist/wje-copy-button/copy-button.element.d.ts +0 -89
  76. package/dist/wje-copy-button/service/service.d.ts +0 -12
  77. package/dist/wje-dialog/dialog.d.ts +0 -2
  78. package/dist/wje-dialog/dialog.element.d.ts +0 -132
  79. package/dist/wje-divider/divider.d.ts +0 -2
  80. package/dist/wje-divider/divider.element.d.ts +0 -32
  81. package/dist/wje-dropdown/dropdown.d.ts +0 -2
  82. package/dist/wje-dropdown/dropdown.element.d.ts +0 -108
  83. package/dist/wje-element/element.d.ts +0 -341
  84. package/dist/wje-file-upload/file-upload.d.ts +0 -2
  85. package/dist/wje-file-upload/file-upload.element.d.ts +0 -191
  86. package/dist/wje-file-upload/service/service.d.ts +0 -70
  87. package/dist/wje-file-upload-item/file-upload-item.d.ts +0 -2
  88. package/dist/wje-file-upload-item/file-upload-item.element.d.ts +0 -68
  89. package/dist/wje-footer/footer.d.ts +0 -2
  90. package/dist/wje-footer/footer.element.d.ts +0 -28
  91. package/dist/wje-form/form.d.ts +0 -2
  92. package/dist/wje-form/form.element.d.ts +0 -28
  93. package/dist/wje-format-digital/format-digital.d.ts +0 -2
  94. package/dist/wje-format-digital/format-digital.element.d.ts +0 -83
  95. package/dist/wje-format-digital/format-digital.test.d.ts +0 -1
  96. package/dist/wje-grid/grid.d.ts +0 -2
  97. package/dist/wje-grid/grid.element.d.ts +0 -26
  98. package/dist/wje-header/header.d.ts +0 -2
  99. package/dist/wje-header/header.element.d.ts +0 -35
  100. package/dist/wje-icon/icon.d.ts +0 -2
  101. package/dist/wje-icon/icon.element.d.ts +0 -40
  102. package/dist/wje-icon/service/library.d.ts +0 -3
  103. package/dist/wje-icon/service/service.d.ts +0 -11
  104. package/dist/wje-icon-picker/icon-picker.d.ts +0 -2
  105. package/dist/wje-icon-picker/icon-picker.element.d.ts +0 -210
  106. package/dist/wje-img/img.d.ts +0 -2
  107. package/dist/wje-img/img.element.d.ts +0 -118
  108. package/dist/wje-img-comparer/img-comparer.d.ts +0 -2
  109. package/dist/wje-img-comparer/img-comparer.element.d.ts +0 -60
  110. package/dist/wje-img-comparer/service/service.d.ts +0 -1
  111. package/dist/wje-infinite-scroll/infinite-scroll.d.ts +0 -2
  112. package/dist/wje-infinite-scroll/infinite-scroll.element.d.ts +0 -173
  113. package/dist/wje-input/input.d.ts +0 -2
  114. package/dist/wje-input/input.element.d.ts +0 -159
  115. package/dist/wje-input-file/input-file.d.ts +0 -2
  116. package/dist/wje-input-file/input-file.element.d.ts +0 -50
  117. package/dist/wje-item/item.d.ts +0 -2
  118. package/dist/wje-item/item.element.d.ts +0 -68
  119. package/dist/wje-kanban/kanban.d.ts +0 -2
  120. package/dist/wje-kanban/kanban.element.d.ts +0 -182
  121. package/dist/wje-label/label.d.ts +0 -2
  122. package/dist/wje-label/label.element.d.ts +0 -34
  123. package/dist/wje-level-indicator/level-indicator.d.ts +0 -2
  124. package/dist/wje-level-indicator/level-indicator.element.d.ts +0 -91
  125. package/dist/wje-list/list.d.ts +0 -2
  126. package/dist/wje-list/list.element.d.ts +0 -31
  127. package/dist/wje-main/main.d.ts +0 -2
  128. package/dist/wje-main/main.element.d.ts +0 -30
  129. package/dist/wje-masonry/masonry.d.ts +0 -2
  130. package/dist/wje-masonry/masonry.element.d.ts +0 -114
  131. package/dist/wje-masonry/service/service.d.ts +0 -32
  132. package/dist/wje-menu/menu.d.ts +0 -2
  133. package/dist/wje-menu/menu.element.d.ts +0 -47
  134. package/dist/wje-menu-button/menu-button.d.ts +0 -2
  135. package/dist/wje-menu-button/menu-button.element.d.ts +0 -34
  136. package/dist/wje-menu-item/menu-item.d.ts +0 -2
  137. package/dist/wje-menu-item/menu-item.element.d.ts +0 -161
  138. package/dist/wje-menu-label/menu-label.d.ts +0 -2
  139. package/dist/wje-menu-label/menu-label.element.d.ts +0 -39
  140. package/dist/wje-option/option.d.ts +0 -2
  141. package/dist/wje-option/option.element.d.ts +0 -95
  142. package/dist/wje-options/options.d.ts +0 -2
  143. package/dist/wje-options/options.element.d.ts +0 -232
  144. package/dist/wje-orgchart/orgchart.d.ts +0 -2
  145. package/dist/wje-orgchart/orgchart.element.d.ts +0 -24
  146. package/dist/wje-orgchart-group/orgchart-group.d.ts +0 -2
  147. package/dist/wje-orgchart-group/orgchart-group.element.d.ts +0 -28
  148. package/dist/wje-orgchart-item/orgchart-item.d.ts +0 -2
  149. package/dist/wje-orgchart-item/orgchart-item.element.d.ts +0 -49
  150. package/dist/wje-pagination/pagination.d.ts +0 -2
  151. package/dist/wje-pagination/pagination.element.d.ts +0 -178
  152. package/dist/wje-pagination/pagination.test.d.ts +0 -1
  153. package/dist/wje-pagination/service/service.d.ts +0 -9
  154. package/dist/wje-panel/panel.d.ts +0 -2
  155. package/dist/wje-panel/panel.element.d.ts +0 -34
  156. package/dist/wje-popup/popup.d.ts +0 -2
  157. package/dist/wje-popup/popup.element.d.ts +0 -145
  158. package/dist/wje-progress-bar/progress-bar.d.ts +0 -2
  159. package/dist/wje-progress-bar/progress-bar.element.d.ts +0 -96
  160. package/dist/wje-qr-code/qr-code.d.ts +0 -2
  161. package/dist/wje-qr-code/qr-code.element.d.ts +0 -33
  162. package/dist/wje-radio/radio.d.ts +0 -2
  163. package/dist/wje-radio/radio.element.d.ts +0 -64
  164. package/dist/wje-radio-group/radio-group.d.ts +0 -2
  165. package/dist/wje-radio-group/radio-group.element.d.ts +0 -61
  166. package/dist/wje-rate/rate.d.ts +0 -2
  167. package/dist/wje-rate/rate.element.d.ts +0 -156
  168. package/dist/wje-relative-time/relative-time.d.ts +0 -2
  169. package/dist/wje-relative-time/relative-time.element.d.ts +0 -55
  170. package/dist/wje-relative-time/relative-time.test.d.ts +0 -1
  171. package/dist/wje-reorder/reorder.d.ts +0 -2
  172. package/dist/wje-reorder/reorder.element.d.ts +0 -119
  173. package/dist/wje-reorder-dropzone/reorder-dropzone.d.ts +0 -2
  174. package/dist/wje-reorder-dropzone/reorder-dropzone.element.d.ts +0 -23
  175. package/dist/wje-reorder-handle/reorder-handle.d.ts +0 -2
  176. package/dist/wje-reorder-handle/reorder-handle.element.d.ts +0 -84
  177. package/dist/wje-reorder-item/reorder-item.d.ts +0 -2
  178. package/dist/wje-reorder-item/reorder-item.element.d.ts +0 -24
  179. package/dist/wje-route/route.d.ts +0 -2
  180. package/dist/wje-route/route.element.d.ts +0 -22
  181. package/dist/wje-router/router.d.ts +0 -2
  182. package/dist/wje-router/router.element.d.ts +0 -43
  183. package/dist/wje-router-link/router-link.d.ts +0 -2
  184. package/dist/wje-router-link/router-link.element.d.ts +0 -31
  185. package/dist/wje-router-outlet/router-outlet.d.ts +0 -2
  186. package/dist/wje-router-outlet/router-outlet.element.d.ts +0 -16
  187. package/dist/wje-row/row.d.ts +0 -2
  188. package/dist/wje-row/row.element.d.ts +0 -23
  189. package/dist/wje-select/select.d.ts +0 -2
  190. package/dist/wje-select/select.element.d.ts +0 -386
  191. package/dist/wje-select/select.test.d.ts +0 -1
  192. package/dist/wje-slider/slider.d.ts +0 -2
  193. package/dist/wje-slider/slider.element.d.ts +0 -103
  194. package/dist/wje-sliding-container/sliding-container.d.ts +0 -2
  195. package/dist/wje-sliding-container/sliding-container.element.d.ts +0 -265
  196. package/dist/wje-split-view/service/service.d.ts +0 -1
  197. package/dist/wje-split-view/split-view.d.ts +0 -2
  198. package/dist/wje-split-view/split-view.element.d.ts +0 -65
  199. package/dist/wje-status/status.d.ts +0 -2
  200. package/dist/wje-status/status.element.d.ts +0 -26
  201. package/dist/wje-step/step.d.ts +0 -2
  202. package/dist/wje-step/step.element.d.ts +0 -23
  203. package/dist/wje-stepper/stepper.d.ts +0 -2
  204. package/dist/wje-stepper/stepper.element.d.ts +0 -125
  205. package/dist/wje-store/default-store-actions.d.ts +0 -25
  206. package/dist/wje-store/pubsub.d.ts +0 -22
  207. package/dist/wje-store/store.d.ts +0 -153
  208. package/dist/wje-tab/tab.d.ts +0 -2
  209. package/dist/wje-tab/tab.element.d.ts +0 -66
  210. package/dist/wje-tab-group/tab-group.d.ts +0 -2
  211. package/dist/wje-tab-group/tab-group.element.d.ts +0 -131
  212. package/dist/wje-tab-group/tab-group.test.d.ts +0 -1
  213. package/dist/wje-tab-panel/tab-panel.d.ts +0 -2
  214. package/dist/wje-tab-panel/tab-panel.element.d.ts +0 -23
  215. package/dist/wje-textarea/textarea.d.ts +0 -2
  216. package/dist/wje-textarea/textarea.element.d.ts +0 -89
  217. package/dist/wje-thumbnail/thumbnail.d.ts +0 -2
  218. package/dist/wje-thumbnail/thumbnail.element.d.ts +0 -31
  219. package/dist/wje-timeline/timeline.d.ts +0 -2
  220. package/dist/wje-timeline/timeline.element.d.ts +0 -25
  221. package/dist/wje-timeline-item/timeline-item.d.ts +0 -2
  222. package/dist/wje-timeline-item/timeline-item.element.d.ts +0 -27
  223. package/dist/wje-toast/toast.d.ts +0 -2
  224. package/dist/wje-toast/toast.element.d.ts +0 -173
  225. package/dist/wje-toast/toast.test.d.ts +0 -1
  226. package/dist/wje-toggle/toggle.d.ts +0 -2
  227. package/dist/wje-toggle/toggle.element.d.ts +0 -81
  228. package/dist/wje-toggle/toggle.test.d.ts +0 -1
  229. package/dist/wje-toolbar/toolbar.d.ts +0 -2
  230. package/dist/wje-toolbar/toolbar.element.d.ts +0 -39
  231. package/dist/wje-toolbar-action/toolbar-action.d.ts +0 -2
  232. package/dist/wje-toolbar-action/toolbar-action.element.d.ts +0 -35
  233. package/dist/wje-tooltip/tooltip.d.ts +0 -2
  234. package/dist/wje-tooltip/tooltip.element.d.ts +0 -77
  235. package/dist/wje-tree/tree.d.ts +0 -2
  236. package/dist/wje-tree/tree.element.d.ts +0 -105
  237. package/dist/wje-tree/tree.test.d.ts +0 -1
  238. package/dist/wje-tree-item/tree-item.d.ts +0 -2
  239. package/dist/wje-tree-item/tree-item.element.d.ts +0 -155
  240. package/dist/wje-tree-item/tree-item.test.d.ts +0 -1
  241. package/dist/wje-visually-hidden/visually-hidden.d.ts +0 -2
  242. package/dist/wje-visually-hidden/visually-hidden.element.d.ts +0 -29
  243. /package/dist/{wje-animation/animation.test.d.ts → packages/wje-file-upload/file-upload.test.d.ts} +0 -0
@@ -1,67 +0,0 @@
1
- export let event: Event;
2
- declare class Event {
3
- customEventWeakMap: WeakMap<WeakKey, any>;
4
- /**
5
- * Dispatch custom event to the element with the specified event name and detail.
6
- * @param element
7
- * @param event
8
- * @param detail
9
- */
10
- dispatchCustomEvent(element: any, event: any, detail: any): void;
11
- /**
12
- * Find record by element in the storage.
13
- * @param element
14
- * @returns {*}
15
- */
16
- findRecordByElement(element: any): any;
17
- /**
18
- * Add listener to the element. If the element is an array, the listener will be added to all elements in the array.
19
- * @param element
20
- * @param originalEvent
21
- * @param event
22
- * @param listener
23
- * @param options
24
- */
25
- addListener(element: any, originalEvent: any, event: any, listener: any, options: any): void;
26
- /**
27
- * Write record to the storage.
28
- * @param element
29
- * @param originalEvent
30
- * @param event
31
- * @param listener
32
- * @param options
33
- */
34
- writeRecord(element: any, originalEvent: any, event: any, listener: any, options: any): void;
35
- /**
36
- * Performs a deep equality check between two objects.
37
- * @param x The first object to compare.
38
- * @param y The second object to compare.
39
- * @returns - Returns `true` if the objects are deeply equal, `false` otherwise.
40
- */
41
- deepEqual(x: any, y: any): any;
42
- /**
43
- * Check if the listener already exists on the element.
44
- * @param records
45
- * @param eventObj
46
- * @returns
47
- */
48
- listenerExists(records: any, eventObj: any): any;
49
- isRecordExists(records: any, eventObj: any): any;
50
- /**
51
- * Remove listener from the element and delete the listener from the custom event storage.
52
- * @param element
53
- * @param originalEvent
54
- * @param event
55
- * @param listener
56
- * @param options
57
- */
58
- removeListener(element: any, originalEvent: any, event: any, listener: any, options: any): void;
59
- /**
60
- * Remove all event listeners from the specified element and delete the element from the custom event storage.
61
- * @param {HTMLElement} element The element from which all listeners will be removed.
62
- */
63
- removeElement(element: HTMLElement): void;
64
- createPromiseFromEvent(element: any, event: any): Promise<any>;
65
- #private;
66
- }
67
- export {};
@@ -1,3 +0,0 @@
1
- export function getIconLibrary(name: any): any;
2
- export function registerIconLibrary(name: any, options: any): void;
3
- export function unregisterIconLibrary(name: any): void;
@@ -1,4 +0,0 @@
1
- import { LocalizerDefault } from '../localize/localize.js';
2
- export class Localizer extends LocalizerDefault {
3
- static registerTranslation(...translation: any[]): void;
4
- }
@@ -1,40 +0,0 @@
1
- /**
2
- * PermissionsApi is a utility class for managing permissions.
3
- * It allows setting, retrieving, and checking permissions stored in the browser's local storage.
4
- */
5
- export class Permissions {
6
- static _permissionKey: string;
7
- /**
8
- * Sets the permission key for the PermissionsApi.
9
- * The key is stored internally and defaults to 'permissions' if no value is provided.
10
- * @param {string} value The key to set for permissions. If no value is provided, the default is 'permissions'.
11
- */
12
- static set permissionKey(value: string);
13
- /**
14
- * Retrieves the permission key used for accessing the permissions API.
15
- * @returns {string} The permission key associated with the PermissionsApi.
16
- */
17
- static get permissionKey(): string;
18
- /**
19
- * Sets the permissions by storing them in the local storage.
20
- * @param {object} value The permissions object to be stored.
21
- */
22
- static set permissions(value: object);
23
- /**
24
- * Retrieves the list of permissions stored in the browser's local storage.
25
- * @returns {Array} An array of permissions. If no permissions are found, returns an empty array.
26
- */
27
- static get permissions(): any[];
28
- /**
29
- * Determines whether the specified key exists in the permissions list.
30
- * @param {string} key The key to check for existence in the permissions list.
31
- * @returns {boolean} Returns true if the key exists in the permissions list; otherwise, returns false.
32
- */
33
- static includesKey(key: string): boolean;
34
- /**
35
- * Checks if at least one of the given permissions is fulfilled, based on the permissions available in `PermissionsApi`.
36
- * @param {Array<string>} permissions The list of permissions to check against the permissions available in `PermissionsApi`.
37
- * @returns {boolean} Returns `true` if any of the given permissions match the permissions available in `PermissionsApi`, otherwise returns `false`.
38
- */
39
- static isPermissionFulfilled(permissions: Array<string>): boolean;
40
- }
@@ -1,18 +0,0 @@
1
- export class UniversalService {
2
- constructor(props?: {});
3
- _store: any;
4
- findByKey: (attrName: any, key: any, keyValue: any) => any;
5
- findById: (attrName: any, id: any) => any;
6
- findAttributeValue: (attrName: any) => any;
7
- update: (data: any, action: any) => void;
8
- add: (data: any, action: any) => void;
9
- _request(url: any, data: any, action: any, dispatchMethod: any, method: any, signal: any): any;
10
- put(url: any, data: any, action: any, dispatchMethod?: boolean, signal?: any): any;
11
- post(url: any, data: any, action: any, dispatchMethod?: boolean, signal?: any): any;
12
- delete(url: any, data: any, action: any, dispatchMethod?: boolean, signal?: any): any;
13
- get(url: any, action: any, dispatchMethod?: boolean, signal?: any): any;
14
- patch(url: any, data: any, action: any, dispatchMethod?: boolean, signal?: any): any;
15
- dispatch(promise: any, dispatchMethod: any, action: any): any;
16
- loadPromise: (url: any, action: any, method?: string, data?: string, permissionCallBack?: () => void) => Promise<any>;
17
- loadOnePromise: (url: any, action: any) => Promise<any>;
18
- }
@@ -1 +0,0 @@
1
- export function bool(v: any): boolean;
@@ -1,2 +0,0 @@
1
- import { default as Accordion } from './accordion.element.js';
2
- export default Accordion;
@@ -1,72 +0,0 @@
1
- import { default as WJElement } from '../wje-element/element.js';
2
- /**
3
- * @summary This class represents an Accordion element, extending the WJElement class.
4
- * @documentation https://elements.webjet.sk/components/accordion
5
- * @status stable
6
- * @augments WJElement
7
- * @attribute {boolean} multiple - The multiple attribute for the accordion.
8
- * @attribute {number} index - The index attribute for the accordion.
9
- * @attribute {boolean} disabled - The disabled attribute for the accordion.
10
- * @attribute {boolean} expanded - The expanded attribute for the accordion.
11
- * @slot - The accordion main content.
12
- * //@fires [wje-accordion-item:open] The event fired when the accordion item is opened.
13
- * @tag wje-accordion
14
- */
15
- export default class Accordion extends WJElement {
16
- /**
17
- * Getter for the CSS stylesheet.
18
- * @returns {object} The styles for the Accordion element.
19
- */
20
- static get cssStyleSheet(): object;
21
- /**
22
- * Getter for the observed attributes.
23
- * @returns {Array} An array containing the name of the observed attribute.
24
- */
25
- static get observedAttributes(): any[];
26
- /**
27
- * Sets the `multiple` attribute on the element.
28
- * If `true`, the `multiple` attribute is added.
29
- * If `false`, the `multiple` attribute is removed.
30
- * @param {boolean} value A boolean value indicating whether the element should support multiple selections.
31
- */
32
- set multiple(value: boolean);
33
- /**
34
- * Determines whether the element has the `multiple` attribute.
35
- * @returns {boolean} `true` if the `multiple` attribute is present, otherwise `false`.
36
- */
37
- get multiple(): boolean;
38
- /**
39
- * Sets the value of the `index` attribute.
40
- * @param {number|string} value The value to set for the `index` attribute.
41
- */
42
- set index(value: number | string);
43
- /**
44
- * Retrieves the value of the `index` attribute as a number.
45
- * @returns {number} The numerical value of the `index` attribute, or `0` if the attribute is not set.
46
- */
47
- get index(): number;
48
- /**
49
- * Method to run before the element is drawn.
50
- */
51
- beforeDraw(): void;
52
- /**
53
- * Method to draw the Accordion element.
54
- * @returns {object} The document fragment containing the drawn element.
55
- */
56
- draw(): object;
57
- slotEl: HTMLSlotElement;
58
- /**
59
- * Method to run after the element is drawn.
60
- */
61
- afterDraw(): void;
62
- /**
63
- * Method to run after the element is drawn.
64
- * @param exception
65
- */
66
- collapseAll(exception: any): void;
67
- /**
68
- * Method to get the accordions.
69
- * @returns {Array} An array containing the accordions.
70
- */
71
- getAccordions(): any[];
72
- }
File without changes
@@ -1,2 +0,0 @@
1
- import { default as AccordionItem } from './accordion-item.element.js';
2
- export default AccordionItem;
@@ -1,40 +0,0 @@
1
- import { default as WJElement } from '../wje-element/element.js';
2
- /**
3
- * @summary This class represents an Accordion Item element, extending the WJElement class.
4
- * @documentation https://elements.webjet.sk/components/accordion-item
5
- * @status stable
6
- * @augments WJElement
7
- * @slot - The accordion item main content.
8
- * @tag wje-accordion
9
- */
10
- export default class AccordionItem extends WJElement {
11
- /**
12
- * Getter for the CSS stylesheet.
13
- * @returns {object} The styles for the Accordion Item element.
14
- */
15
- static get cssStyleSheet(): object;
16
- /**
17
- * Getter for the observed attributes.
18
- * @returns {Array} An array containing the name of the observed attribute.
19
- */
20
- static get observedAttributes(): any[];
21
- /**
22
- * Method to draw the Accordion Item element. This method returns a document fragment containing the drawn element.
23
- * @returns {object} The document fragment containing the drawn element.
24
- */
25
- draw(): object;
26
- headline: HTMLDivElement;
27
- toggle: HTMLSlotElement;
28
- /**
29
- * Method to execute after the Accordion Item element is drawn.
30
- */
31
- afterDraw(): void;
32
- /**
33
- * Method to handle the attribute changes.
34
- */
35
- collapse: () => void;
36
- /**
37
- * Method to handle the attribute changes.
38
- */
39
- expand: () => void;
40
- }
@@ -1,2 +0,0 @@
1
- import { default as Animation } from './animation.element.js';
2
- export default Animation;
@@ -1,158 +0,0 @@
1
- import { default as WJElement } from '../wje-element/element.js';
2
- /**
3
- * @summary This class represents an Animation element, extending the WJElement class.
4
- * @documentation https://elements.webjet.sk/components/animation
5
- * @status stable
6
- * @augments WJElement
7
- * @slot - The animation main content.
8
- * @cssproperty --size - The size of the avatar.
9
- * @tag wje-animation
10
- */
11
- export default class Animation extends WJElement {
12
- /**
13
- * Getter for the CSS stylesheet.
14
- * @returns {object} The styles for the Animation element.
15
- */
16
- static get cssStyleSheet(): object;
17
- /**
18
- * Getter for the observed attributes.
19
- * @returns {Array} An array containing the name of the observed attribute.
20
- */
21
- static get observedAttributes(): any[];
22
- _animations: any[];
23
- /**
24
- * Setter for the name attribute.
25
- * @param value
26
- */
27
- set name(value: string);
28
- /**
29
- * Getter for the name attribute.
30
- * @returns {string}
31
- */
32
- get name(): string;
33
- /**
34
- * Setter for the name attribute.
35
- * @param value
36
- */
37
- set duration(value: number);
38
- /**
39
- * Getter for the name attribute.
40
- * @returns {number}
41
- */
42
- get duration(): number;
43
- /**
44
- * Setter for the name attribute.
45
- * @param value
46
- */
47
- set delay(value: number);
48
- /**
49
- * Getter for the name attribute.
50
- * @returns {number}
51
- */
52
- get delay(): number;
53
- /**
54
- * Setter for the name attribute.
55
- * @param value
56
- */
57
- set endDelay(value: number);
58
- /**
59
- * Getter for the name attribute.
60
- * @returns {number}
61
- */
62
- get endDelay(): number;
63
- /**
64
- * Setter for the name attribute.
65
- * @param value
66
- */
67
- set fill(value: string);
68
- /**
69
- * Getter for the name attribute.
70
- * @returns {string}
71
- */
72
- get fill(): string;
73
- /**
74
- * Setter for the name attribute.
75
- * @param value
76
- */
77
- set iterations(value: string | number);
78
- /**
79
- * Getter for the name attribute.
80
- * @returns {string|number}
81
- */
82
- get iterations(): string | number;
83
- /**
84
- * Setter for the name attribute.
85
- * @param value
86
- */
87
- set iterationStart(value: number);
88
- /**
89
- * Getter for the name attribute.
90
- * @returns {number}
91
- */
92
- get iterationStart(): number;
93
- /**
94
- * Setter for the name attribute.
95
- * @param value
96
- */
97
- set direction(value: string);
98
- /**
99
- * Getter for the name attribute.
100
- * @returns {string}
101
- */
102
- get direction(): string;
103
- /**
104
- * Setter for the name attribute.
105
- * @param value
106
- */
107
- set easing(value: string);
108
- /**
109
- * Getter for the name attribute.
110
- * @returns {string}
111
- */
112
- get easing(): string;
113
- /**
114
- * Setter for the animations property.
115
- * @param {Array} value The new value for the animations property.
116
- */
117
- set animations(value: any[]);
118
- /**
119
- * Getter for the animations' property.
120
- * @returns {Array} The current value of the animations' property.
121
- */
122
- get animations(): any[];
123
- /**
124
- * Method to draw the Animation element.
125
- * @returns {object} The document fragment containing the drawn element.
126
- */
127
- draw(): object;
128
- slotEl: HTMLSlotElement;
129
- /**
130
- * Method to perform actions after the Animation element is drawn.
131
- * This method destroys any existing animation, fetches a new animations array,
132
- * selects the appropriate animation, and applies it to the element.
133
- */
134
- afterDraw(): Promise<void>;
135
- animation: Animation;
136
- /**
137
- * Method to fetch and parse the animations array from a CSS file.
138
- * @returns {Array} An array of animation definitions parsed from the CSS file.
139
- */
140
- getAnimationsArray(): any[];
141
- /**
142
- * Terminates and cleans up the currently active animation if it exists.
143
- * Calls the `cancel` method to stop the animation process.
144
- * @returns {void} Does not return any value.
145
- */
146
- destroyAnimation(): void;
147
- /**
148
- * Plays the currently assigned animation, if available.
149
- * @returns {void} This method does not return any value.
150
- */
151
- play(): void;
152
- /**
153
- * Cancels the current animation if it is initialized and has a cancel method.
154
- * Logs a warning if the animation is not initialized or the cancel method is unavailable.
155
- * @returns {void} Does not return a value.
156
- */
157
- cancel(): void;
158
- }
@@ -1,2 +0,0 @@
1
- import { default as Aside } from './aside.element.js';
2
- export default Aside;
@@ -1,31 +0,0 @@
1
- import { default as WJElement } from '../wje-element/element.js';
2
- /**
3
- * @summary This class represents an Aside element, extending the WJElement class.
4
- * @documentation https://elements.webjet.sk/components/aside
5
- * @status stable
6
- * @augments WJElement
7
- * @slot - The aside main content.
8
- * @cssproperty --wje-aside-width;
9
- * @cssproperty --wje-aside-top;
10
- * @cssproperty --wje-aside-border-color: var(--wje-border-color);
11
- * @cssproperty --wje-aside-border-width;
12
- * @cssproperty --wje-aside-border-style;
13
- * @tag wje-aside
14
- */
15
- export default class Aside extends WJElement {
16
- /**
17
- * Getter for the CSS stylesheet.
18
- * @returns {object} The styles for the Aside element.
19
- */
20
- static get cssStyleSheet(): object;
21
- /**
22
- * Getter for the observed attributes.
23
- * @returns {Array} An empty array as there are no observed attributes.
24
- */
25
- static get observedAttributes(): any[];
26
- /**
27
- * Method to draw the Aside element.
28
- * @returns {object} The document fragment containing the drawn element.
29
- */
30
- draw(): object;
31
- }
@@ -1,2 +0,0 @@
1
- import { default as Avatar } from './avatar.element.js';
2
- export default Avatar;
@@ -1,76 +0,0 @@
1
- import { default as WJElement } from '../wje-element/element.js';
2
- /**
3
- * @summary This class represents an Avatar element, extending the WJElement class.
4
- * @documentation https://elements.webjet.sk/components/avatar
5
- * @status stable
6
- * @augments WJElement
7
- * @slot - The avatar main content.
8
- * @csspart native - The component's native wrapper.
9
- * @cssproperty --wje-avatar-width;
10
- * @cssproperty --wje-avatar-height;
11
- * @cssproperty --wje-avatar-font-size;
12
- * @cssproperty --wje-avatar-font-weight;
13
- * @cssproperty --wje-avatar-color;
14
- * @cssproperty --wje-avatar-background-color;
15
- * @cssproperty --wje-avatar-border-radius;
16
- * @cssproperty --wje-avatar-border-color;
17
- * @cssproperty --wje-avatar-border-width;
18
- * @cssproperty --wje-avatar-border-style;
19
- * @tag wje-avatar
20
- */
21
- export default class Avatar extends WJElement {
22
- /**
23
- * Getter for cssStyleSheet.
24
- * @returns {string} styles
25
- */
26
- static get cssStyleSheet(): string;
27
- /**
28
- * Returns the list of attributes to observe for changes.
29
- * @static
30
- * @returns {Array<string>}
31
- */
32
- static get observedAttributes(): Array<string>;
33
- /**
34
- * Sets the value of the 'label' attribute for the element.
35
- * @param {string} value The new value to be set for the 'label' attribute.
36
- */
37
- set label(value: string);
38
- /**
39
- * Retrieves the value of the 'label' attribute for the element.
40
- * If the attribute is not set, it defaults to an empty string.
41
- * @returns {string} The value of the 'label' attribute or an empty string if not defined.
42
- */
43
- get label(): string;
44
- /**
45
- * Sets the value of initials for the element by updating
46
- * the 'initials' attribute with the provided value.
47
- * @param {string} value The value to be set as the initials.
48
- */
49
- set initials(value: string);
50
- /**
51
- * Retrieves the value of the 'initials' attribute if it exists.
52
- * @returns {boolean} Returns true if the 'initials' attribute is present, otherwise false.
53
- */
54
- get initials(): boolean;
55
- /**
56
- * Sets the size attribute for the element.
57
- * @param {string | number} value The value to set for the size attribute.
58
- */
59
- set size(value: string | number);
60
- /**
61
- * Retrieves the size attribute of the element. If the size attribute
62
- * is not defined, it returns the default value 'medium'.
63
- * @returns {string} The size value of the element or 'medium' if not specified.
64
- */
65
- get size(): string;
66
- /**
67
- * Method to draw the avatar element and return a document fragment.
68
- * @returns {object} fragment - The document fragment
69
- */
70
- draw(): object;
71
- /**
72
- * Method to check if the avatar is an image.
73
- * @returns {boolean} - True if the avatar is an image, false otherwise
74
- */
75
- isImage(): boolean;
76
- }
@@ -1 +0,0 @@
1
- export {};
@@ -1,52 +0,0 @@
1
- /**
2
- * Generates an HSL color value based on the input text.
3
- * @param {string} text The input text to generate the HSL color.
4
- * @param {number} [s] The saturation value (in percentage) for the HSL color.
5
- * @param {number} [l] The lightness value (in percentage) for the HSL color.
6
- * @returns {string} - The HSL color string in the format `hsl(h, s%, l%)`.
7
- * @description
8
- * This function computes a hash from the input text and uses it to generate
9
- * a hue value. The hue is combined with the provided saturation and lightness
10
- * values to create an HSL color. This can be useful for consistently assigning
11
- * colors based on text input, such as for avatars or tags.
12
- * @example
13
- * // Returns 'hsl(180, 40%, 65%)'
14
- * getHsl('example');
15
- * @example
16
- * // Returns 'hsl(300, 50%, 70%)'
17
- * getHsl('test', 50, 70);
18
- */
19
- export function getHsl(text: string, s?: number, l?: number): string;
20
- /**
21
- * Generates background and text HSL colors for avatars based on input text.
22
- * The text color is a darker, more saturated variant of the background color
23
- * to ensure sufficient contrast while keeping the same hue.
24
- *
25
- * @param {string} text The input text (e.g. initials or name).
26
- * @returns {{ background: string, color: string }}
27
- */
28
- export function getAvatarColors(text: string): {
29
- background: string;
30
- color: string;
31
- };
32
- /**
33
- * Generates initials from a given string.
34
- * @param {string} string The input string, typically a full name.
35
- * @param {number} [length] The desired number of initials (default is 2).
36
- * @returns {string} - The generated initials in uppercase.
37
- * @description
38
- * This function takes a string, splits it by spaces, and generates initials.
39
- * It always includes the first character of the first word. If the input string
40
- * contains more than one word and the `length` parameter is greater than 1, it
41
- * also includes the first character of the last word.
42
- * @example
43
- * // Returns 'JD'
44
- * getInitials('John Doe');
45
- * @example
46
- * // Returns 'J'
47
- * getInitials('John');
48
- * @example
49
- * // Returns 'JM'
50
- * getInitials('John Michael Doe', 2);
51
- */
52
- export function getInitials(string: string, length?: number): string;
@@ -1,2 +0,0 @@
1
- import { default as Badge } from './badge.element.js';
2
- export default Badge;
@@ -1,35 +0,0 @@
1
- import { default as WJElement } from '../wje-element/element.js';
2
- /**
3
- * @summary This class represents a Badge element, extending the WJElement class.
4
- * @documentation https://elements.webjet.sk/components/badge
5
- * @status stable
6
- * @augments WJElement
7
- * @attribute {string} color - The color of the badge element. Accepts any valid string primary, secondary, success, danger, warning, info, default.
8
- * @slot - The badge's main content.
9
- * @csspart native - The component's native wrapper.
10
- * @cssproperty [--wje-badge-border-radius=var(--wje-border-radius-pill)] - Border radius of the badge element.
11
- * @tag wje-badge
12
- */
13
- export default class Badge extends WJElement {
14
- /**
15
- * Retrieves the CSS stylesheet for the Badge element.
16
- * @static
17
- * @returns {CSSStyleSheet} The CSS styles associated with the Badge.
18
- */
19
- static get cssStyleSheet(): CSSStyleSheet;
20
- /**
21
- * Specifies the attributes to observe for changes.
22
- * @static
23
- * @returns {Array<string>} An array containing the names of attributes to observe.
24
- * @example
25
- * static get observedAttributes() {
26
- * return ['color'];
27
- * }
28
- */
29
- static get observedAttributes(): Array<string>;
30
- /**
31
- * Creates the DOM structure for the Badge element.
32
- * @returns {DocumentFragment} A document fragment containing the Badge's structure.
33
- */
34
- draw(): DocumentFragment;
35
- }
@@ -1 +0,0 @@
1
- export {};
@@ -1,2 +0,0 @@
1
- import { default as Breadcrumb } from './breadcrumb.element.js';
2
- export default Breadcrumb;