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

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 (246) hide show
  1. package/dist/packages/wje-select/select.element.d.ts +10 -10
  2. package/dist/packages/wje-sliding-container/sliding-container.element.d.ts +2 -2
  3. package/dist/wje-file-upload.js +2 -0
  4. package/dist/wje-file-upload.js.map +1 -1
  5. package/dist/wje-select.js +40 -29
  6. package/dist/wje-select.js.map +1 -1
  7. package/package.json +1 -1
  8. package/dist/index.d.ts +0 -107
  9. package/dist/internals/form-associated-element.d.ts +0 -143
  10. package/dist/localize/localize.d.ts +0 -48
  11. package/dist/translations/en-gb.d.ts +0 -18
  12. package/dist/translations/sk-sk.d.ts +0 -13
  13. package/dist/utils/animations.d.ts +0 -2
  14. package/dist/utils/base-path.d.ts +0 -14
  15. package/dist/utils/date.d.ts +0 -2
  16. package/dist/utils/element-utils.d.ts +0 -46
  17. package/dist/utils/event.d.ts +0 -67
  18. package/dist/utils/icon-library.d.ts +0 -3
  19. package/dist/utils/localize.d.ts +0 -4
  20. package/dist/utils/permissions.d.ts +0 -40
  21. package/dist/utils/universal-service.d.ts +0 -18
  22. package/dist/utils/utils.d.ts +0 -1
  23. package/dist/wje-accordion/accordion.d.ts +0 -2
  24. package/dist/wje-accordion/accordion.element.d.ts +0 -72
  25. package/dist/wje-accordion/accordion.test.d.ts +0 -0
  26. package/dist/wje-accordion-item/accordion-item.d.ts +0 -2
  27. package/dist/wje-accordion-item/accordion-item.element.d.ts +0 -40
  28. package/dist/wje-animation/animation.d.ts +0 -2
  29. package/dist/wje-animation/animation.element.d.ts +0 -158
  30. package/dist/wje-aside/aside.d.ts +0 -2
  31. package/dist/wje-aside/aside.element.d.ts +0 -31
  32. package/dist/wje-avatar/avatar.d.ts +0 -2
  33. package/dist/wje-avatar/avatar.element.d.ts +0 -76
  34. package/dist/wje-avatar/avatar.test.d.ts +0 -1
  35. package/dist/wje-avatar/service/service.d.ts +0 -52
  36. package/dist/wje-badge/badge.d.ts +0 -2
  37. package/dist/wje-badge/badge.element.d.ts +0 -35
  38. package/dist/wje-badge/badge.test.d.ts +0 -1
  39. package/dist/wje-breadcrumb/breadcrumb.d.ts +0 -2
  40. package/dist/wje-breadcrumb/breadcrumb.element.d.ts +0 -98
  41. package/dist/wje-breadcrumbs/breadcrumbs.d.ts +0 -2
  42. package/dist/wje-breadcrumbs/breadcrumbs.element.d.ts +0 -105
  43. package/dist/wje-breadcrumbs/breadcrumbs.test.d.ts +0 -1
  44. package/dist/wje-button/button.d.ts +0 -2
  45. package/dist/wje-button/button.element.d.ts +0 -204
  46. package/dist/wje-button/button.test.d.ts +0 -1
  47. package/dist/wje-button-group/button-group.d.ts +0 -2
  48. package/dist/wje-button-group/button-group.element.d.ts +0 -96
  49. package/dist/wje-card/card.d.ts +0 -2
  50. package/dist/wje-card/card.element.d.ts +0 -31
  51. package/dist/wje-card-content/card-content.d.ts +0 -2
  52. package/dist/wje-card-content/card-content.element.d.ts +0 -22
  53. package/dist/wje-card-controls/card-controls.d.ts +0 -2
  54. package/dist/wje-card-controls/card-controls.element.d.ts +0 -23
  55. package/dist/wje-card-header/card-header.d.ts +0 -2
  56. package/dist/wje-card-header/card-header.element.d.ts +0 -22
  57. package/dist/wje-card-subtitle/card-subtitle.d.ts +0 -2
  58. package/dist/wje-card-subtitle/card-subtitle.element.d.ts +0 -30
  59. package/dist/wje-card-title/card-title.d.ts +0 -2
  60. package/dist/wje-card-title/card-title.element.d.ts +0 -32
  61. package/dist/wje-carousel/carousel.d.ts +0 -2
  62. package/dist/wje-carousel/carousel.element.d.ts +0 -154
  63. package/dist/wje-carousel-item/carousel-item.d.ts +0 -2
  64. package/dist/wje-carousel-item/carousel-item.element.d.ts +0 -38
  65. package/dist/wje-checkbox/checkbox.d.ts +0 -2
  66. package/dist/wje-checkbox/checkbox.element.d.ts +0 -100
  67. package/dist/wje-chip/chip.d.ts +0 -2
  68. package/dist/wje-chip/chip.element.d.ts +0 -76
  69. package/dist/wje-chip/chip.test.d.ts +0 -1
  70. package/dist/wje-col/col.d.ts +0 -2
  71. package/dist/wje-col/col.element.d.ts +0 -16
  72. package/dist/wje-color-picker/color-picker.d.ts +0 -2
  73. package/dist/wje-color-picker/color-picker.element.d.ts +0 -230
  74. package/dist/wje-color-picker/color-picker.test.d.ts +0 -1
  75. package/dist/wje-container/container.d.ts +0 -2
  76. package/dist/wje-container/container.element.d.ts +0 -31
  77. package/dist/wje-copy-button/copy-button.d.ts +0 -2
  78. package/dist/wje-copy-button/copy-button.element.d.ts +0 -89
  79. package/dist/wje-copy-button/service/service.d.ts +0 -12
  80. package/dist/wje-dialog/dialog.d.ts +0 -2
  81. package/dist/wje-dialog/dialog.element.d.ts +0 -132
  82. package/dist/wje-divider/divider.d.ts +0 -2
  83. package/dist/wje-divider/divider.element.d.ts +0 -32
  84. package/dist/wje-dropdown/dropdown.d.ts +0 -2
  85. package/dist/wje-dropdown/dropdown.element.d.ts +0 -108
  86. package/dist/wje-element/element.d.ts +0 -341
  87. package/dist/wje-file-upload/file-upload.d.ts +0 -2
  88. package/dist/wje-file-upload/file-upload.element.d.ts +0 -191
  89. package/dist/wje-file-upload/service/service.d.ts +0 -70
  90. package/dist/wje-file-upload-item/file-upload-item.d.ts +0 -2
  91. package/dist/wje-file-upload-item/file-upload-item.element.d.ts +0 -68
  92. package/dist/wje-footer/footer.d.ts +0 -2
  93. package/dist/wje-footer/footer.element.d.ts +0 -28
  94. package/dist/wje-form/form.d.ts +0 -2
  95. package/dist/wje-form/form.element.d.ts +0 -28
  96. package/dist/wje-format-digital/format-digital.d.ts +0 -2
  97. package/dist/wje-format-digital/format-digital.element.d.ts +0 -83
  98. package/dist/wje-format-digital/format-digital.test.d.ts +0 -1
  99. package/dist/wje-grid/grid.d.ts +0 -2
  100. package/dist/wje-grid/grid.element.d.ts +0 -26
  101. package/dist/wje-header/header.d.ts +0 -2
  102. package/dist/wje-header/header.element.d.ts +0 -35
  103. package/dist/wje-icon/icon.d.ts +0 -2
  104. package/dist/wje-icon/icon.element.d.ts +0 -40
  105. package/dist/wje-icon/service/library.d.ts +0 -3
  106. package/dist/wje-icon/service/service.d.ts +0 -11
  107. package/dist/wje-icon-picker/icon-picker.d.ts +0 -2
  108. package/dist/wje-icon-picker/icon-picker.element.d.ts +0 -210
  109. package/dist/wje-img/img.d.ts +0 -2
  110. package/dist/wje-img/img.element.d.ts +0 -118
  111. package/dist/wje-img-comparer/img-comparer.d.ts +0 -2
  112. package/dist/wje-img-comparer/img-comparer.element.d.ts +0 -60
  113. package/dist/wje-img-comparer/service/service.d.ts +0 -1
  114. package/dist/wje-infinite-scroll/infinite-scroll.d.ts +0 -2
  115. package/dist/wje-infinite-scroll/infinite-scroll.element.d.ts +0 -173
  116. package/dist/wje-input/input.d.ts +0 -2
  117. package/dist/wje-input/input.element.d.ts +0 -159
  118. package/dist/wje-input-file/input-file.d.ts +0 -2
  119. package/dist/wje-input-file/input-file.element.d.ts +0 -50
  120. package/dist/wje-item/item.d.ts +0 -2
  121. package/dist/wje-item/item.element.d.ts +0 -68
  122. package/dist/wje-kanban/kanban.d.ts +0 -2
  123. package/dist/wje-kanban/kanban.element.d.ts +0 -182
  124. package/dist/wje-label/label.d.ts +0 -2
  125. package/dist/wje-label/label.element.d.ts +0 -34
  126. package/dist/wje-level-indicator/level-indicator.d.ts +0 -2
  127. package/dist/wje-level-indicator/level-indicator.element.d.ts +0 -91
  128. package/dist/wje-list/list.d.ts +0 -2
  129. package/dist/wje-list/list.element.d.ts +0 -31
  130. package/dist/wje-main/main.d.ts +0 -2
  131. package/dist/wje-main/main.element.d.ts +0 -30
  132. package/dist/wje-masonry/masonry.d.ts +0 -2
  133. package/dist/wje-masonry/masonry.element.d.ts +0 -114
  134. package/dist/wje-masonry/service/service.d.ts +0 -32
  135. package/dist/wje-menu/menu.d.ts +0 -2
  136. package/dist/wje-menu/menu.element.d.ts +0 -47
  137. package/dist/wje-menu-button/menu-button.d.ts +0 -2
  138. package/dist/wje-menu-button/menu-button.element.d.ts +0 -34
  139. package/dist/wje-menu-item/menu-item.d.ts +0 -2
  140. package/dist/wje-menu-item/menu-item.element.d.ts +0 -161
  141. package/dist/wje-menu-label/menu-label.d.ts +0 -2
  142. package/dist/wje-menu-label/menu-label.element.d.ts +0 -39
  143. package/dist/wje-option/option.d.ts +0 -2
  144. package/dist/wje-option/option.element.d.ts +0 -95
  145. package/dist/wje-options/options.d.ts +0 -2
  146. package/dist/wje-options/options.element.d.ts +0 -232
  147. package/dist/wje-orgchart/orgchart.d.ts +0 -2
  148. package/dist/wje-orgchart/orgchart.element.d.ts +0 -24
  149. package/dist/wje-orgchart-group/orgchart-group.d.ts +0 -2
  150. package/dist/wje-orgchart-group/orgchart-group.element.d.ts +0 -28
  151. package/dist/wje-orgchart-item/orgchart-item.d.ts +0 -2
  152. package/dist/wje-orgchart-item/orgchart-item.element.d.ts +0 -49
  153. package/dist/wje-pagination/pagination.d.ts +0 -2
  154. package/dist/wje-pagination/pagination.element.d.ts +0 -178
  155. package/dist/wje-pagination/pagination.test.d.ts +0 -1
  156. package/dist/wje-pagination/service/service.d.ts +0 -9
  157. package/dist/wje-panel/panel.d.ts +0 -2
  158. package/dist/wje-panel/panel.element.d.ts +0 -34
  159. package/dist/wje-popup/popup.d.ts +0 -2
  160. package/dist/wje-popup/popup.element.d.ts +0 -145
  161. package/dist/wje-progress-bar/progress-bar.d.ts +0 -2
  162. package/dist/wje-progress-bar/progress-bar.element.d.ts +0 -96
  163. package/dist/wje-qr-code/qr-code.d.ts +0 -2
  164. package/dist/wje-qr-code/qr-code.element.d.ts +0 -33
  165. package/dist/wje-radio/radio.d.ts +0 -2
  166. package/dist/wje-radio/radio.element.d.ts +0 -64
  167. package/dist/wje-radio-group/radio-group.d.ts +0 -2
  168. package/dist/wje-radio-group/radio-group.element.d.ts +0 -61
  169. package/dist/wje-rate/rate.d.ts +0 -2
  170. package/dist/wje-rate/rate.element.d.ts +0 -156
  171. package/dist/wje-relative-time/relative-time.d.ts +0 -2
  172. package/dist/wje-relative-time/relative-time.element.d.ts +0 -55
  173. package/dist/wje-relative-time/relative-time.test.d.ts +0 -1
  174. package/dist/wje-reorder/reorder.d.ts +0 -2
  175. package/dist/wje-reorder/reorder.element.d.ts +0 -119
  176. package/dist/wje-reorder-dropzone/reorder-dropzone.d.ts +0 -2
  177. package/dist/wje-reorder-dropzone/reorder-dropzone.element.d.ts +0 -23
  178. package/dist/wje-reorder-handle/reorder-handle.d.ts +0 -2
  179. package/dist/wje-reorder-handle/reorder-handle.element.d.ts +0 -84
  180. package/dist/wje-reorder-item/reorder-item.d.ts +0 -2
  181. package/dist/wje-reorder-item/reorder-item.element.d.ts +0 -24
  182. package/dist/wje-route/route.d.ts +0 -2
  183. package/dist/wje-route/route.element.d.ts +0 -22
  184. package/dist/wje-router/router.d.ts +0 -2
  185. package/dist/wje-router/router.element.d.ts +0 -43
  186. package/dist/wje-router-link/router-link.d.ts +0 -2
  187. package/dist/wje-router-link/router-link.element.d.ts +0 -31
  188. package/dist/wje-router-outlet/router-outlet.d.ts +0 -2
  189. package/dist/wje-router-outlet/router-outlet.element.d.ts +0 -16
  190. package/dist/wje-row/row.d.ts +0 -2
  191. package/dist/wje-row/row.element.d.ts +0 -23
  192. package/dist/wje-select/select.d.ts +0 -2
  193. package/dist/wje-select/select.element.d.ts +0 -386
  194. package/dist/wje-select/select.test.d.ts +0 -1
  195. package/dist/wje-slider/slider.d.ts +0 -2
  196. package/dist/wje-slider/slider.element.d.ts +0 -103
  197. package/dist/wje-sliding-container/sliding-container.d.ts +0 -2
  198. package/dist/wje-sliding-container/sliding-container.element.d.ts +0 -265
  199. package/dist/wje-split-view/service/service.d.ts +0 -1
  200. package/dist/wje-split-view/split-view.d.ts +0 -2
  201. package/dist/wje-split-view/split-view.element.d.ts +0 -65
  202. package/dist/wje-status/status.d.ts +0 -2
  203. package/dist/wje-status/status.element.d.ts +0 -26
  204. package/dist/wje-step/step.d.ts +0 -2
  205. package/dist/wje-step/step.element.d.ts +0 -23
  206. package/dist/wje-stepper/stepper.d.ts +0 -2
  207. package/dist/wje-stepper/stepper.element.d.ts +0 -125
  208. package/dist/wje-store/default-store-actions.d.ts +0 -25
  209. package/dist/wje-store/pubsub.d.ts +0 -22
  210. package/dist/wje-store/store.d.ts +0 -153
  211. package/dist/wje-tab/tab.d.ts +0 -2
  212. package/dist/wje-tab/tab.element.d.ts +0 -66
  213. package/dist/wje-tab-group/tab-group.d.ts +0 -2
  214. package/dist/wje-tab-group/tab-group.element.d.ts +0 -131
  215. package/dist/wje-tab-group/tab-group.test.d.ts +0 -1
  216. package/dist/wje-tab-panel/tab-panel.d.ts +0 -2
  217. package/dist/wje-tab-panel/tab-panel.element.d.ts +0 -23
  218. package/dist/wje-textarea/textarea.d.ts +0 -2
  219. package/dist/wje-textarea/textarea.element.d.ts +0 -89
  220. package/dist/wje-thumbnail/thumbnail.d.ts +0 -2
  221. package/dist/wje-thumbnail/thumbnail.element.d.ts +0 -31
  222. package/dist/wje-timeline/timeline.d.ts +0 -2
  223. package/dist/wje-timeline/timeline.element.d.ts +0 -25
  224. package/dist/wje-timeline-item/timeline-item.d.ts +0 -2
  225. package/dist/wje-timeline-item/timeline-item.element.d.ts +0 -27
  226. package/dist/wje-toast/toast.d.ts +0 -2
  227. package/dist/wje-toast/toast.element.d.ts +0 -173
  228. package/dist/wje-toast/toast.test.d.ts +0 -1
  229. package/dist/wje-toggle/toggle.d.ts +0 -2
  230. package/dist/wje-toggle/toggle.element.d.ts +0 -81
  231. package/dist/wje-toggle/toggle.test.d.ts +0 -1
  232. package/dist/wje-toolbar/toolbar.d.ts +0 -2
  233. package/dist/wje-toolbar/toolbar.element.d.ts +0 -39
  234. package/dist/wje-toolbar-action/toolbar-action.d.ts +0 -2
  235. package/dist/wje-toolbar-action/toolbar-action.element.d.ts +0 -35
  236. package/dist/wje-tooltip/tooltip.d.ts +0 -2
  237. package/dist/wje-tooltip/tooltip.element.d.ts +0 -77
  238. package/dist/wje-tree/tree.d.ts +0 -2
  239. package/dist/wje-tree/tree.element.d.ts +0 -105
  240. package/dist/wje-tree/tree.test.d.ts +0 -1
  241. package/dist/wje-tree-item/tree-item.d.ts +0 -2
  242. package/dist/wje-tree-item/tree-item.element.d.ts +0 -155
  243. package/dist/wje-tree-item/tree-item.test.d.ts +0 -1
  244. package/dist/wje-visually-hidden/visually-hidden.d.ts +0 -2
  245. package/dist/wje-visually-hidden/visually-hidden.element.d.ts +0 -29
  246. /package/dist/{wje-animation/animation.test.d.ts → packages/wje-file-upload/file-upload.test.d.ts} +0 -0
@@ -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;
@@ -1,98 +0,0 @@
1
- import { default as WJElement } from '../wje-element/element.js';
2
- /**
3
- * @summary This class represents a Breadcrumb element, extending the WJElement class. It provides a navigational aid in user interfaces, displaying the current location within a hierarchy.
4
- * @documentation https://elements.webjet.sk/components/breadcrumb
5
- * @status stable
6
- * @augments WJElement
7
- * @slot - The main content of the breadcrumb.
8
- * @slot start - Slot for content at the start of the breadcrumb.
9
- * @slot end - Slot for content at the end of the breadcrumb.
10
- * @slot separator - Slot for a custom separator between breadcrumb items.
11
- * @csspart native - The native wrapper of the breadcrumb component.
12
- * @csspart separator - The separator between breadcrumb items.
13
- * @cssproperty [--wje-breadcrumb-a=var(--wje-color-contrast-8)] - The color of the breadcrumb text.
14
- * @cssproperty [--wje-breadcrumb-a-hover=var(--wje-color-contrast-6)] - The color of the breadcrumb separator line.
15
- * @tag wje-breadcrumb
16
- */
17
- export default class Breadcrumb extends WJElement {
18
- /**
19
- * Get CSS stylesheet for the Breadcrumb element.
20
- * @static
21
- * @returns {object} styles - The CSS styles
22
- */
23
- static get cssStyleSheet(): object;
24
- /**
25
- * Get observed attributes for the Breadcrumb element.
26
- * @static
27
- * @returns {Array<string>} - The observed attributes array for the Breadcrumb element.
28
- */
29
- static get observedAttributes(): Array<string>;
30
- _showSeparator: boolean;
31
- _showCollapsedIndicator: boolean;
32
- /**
33
- * Set show separator flag.
34
- * @param {boolean} value The value to set
35
- */
36
- set showSeparator(value: boolean);
37
- /**
38
- * Get show separator flag.
39
- * @returns {boolean} showSeparator - The show separator flag
40
- */
41
- get showSeparator(): boolean;
42
- /**
43
- * Set collapsed variant.
44
- * @param {string} value The value to set
45
- */
46
- set collapsedVariant(value: string);
47
- /**
48
- * Get collapsed variant.
49
- * @returns {string} The collapsed variant value in uppercase.
50
- */
51
- get collapsedVariant(): string;
52
- _collapsedVariant: string;
53
- /**
54
- * Handles attribute changes for the custom element and updates its behavior or appearance accordingly.
55
- * @param {string} name The name of the attribute that was changed.
56
- * @param {string|null} oldValue The previous value of the attribute before it was changed. Null if the attribute was not previously set.
57
- * @param {string|null} newValue The new value of the attribute after it was changed. Null if the attribute was removed.
58
- * @returns {boolean} Returns false to signal no default behavior is implemented.
59
- */
60
- attributeChangedCallback(name: string, oldValue: string | null, newValue: string | null): boolean;
61
- active: boolean;
62
- /**
63
- * Draw method for the Breadcrumb element.
64
- * @returns {object} fragment - The document fragment
65
- */
66
- draw(): object;
67
- native: HTMLAnchorElement;
68
- /**
69
- * Renders the collapsed indicator based on the current collapsed variant.
70
- * If the collapsed variant is 'DROPDOWN', it invokes the collapseDropdown method.
71
- * Otherwise, it invokes the collapseButton method.
72
- * @returns {any} The rendered collapsed indicator, either as a dropdown or a button.
73
- */
74
- drawCollapsedIndicator(): any;
75
- /**
76
- * Creates and returns a dropdown UI component for collapsed breadcrumbs.
77
- * This method generates a dropdown element with a button trigger and a menu populated with items corresponding
78
- * to the collapsed breadcrumbs. The dropdown is configured to handle specific interactions and ensure that
79
- * events are appropriately managed to avoid propagation issues. Menu items are linked to their corresponding
80
- * breadcrumbs, enabling the same functionality as clicking on the original breadcrumb.
81
- * @returns {HTMLElement} A configured dropdown element containing a button as trigger and a menu with breadcrumb items.
82
- */
83
- collapseDropdown(): HTMLElement;
84
- /**
85
- * Creates a button element that expands hidden breadcrumbs when clicked.
86
- * The button is set with appropriate attributes and event listeners to handle
87
- * the expanding of hidden breadcrumb elements. Clicking the button will remove
88
- * the button itself, reveal hidden breadcrumbs, and stop the current event
89
- * propagation.
90
- * @returns {HTMLButtonElement} The created button configured to expand breadcrumbs.
91
- */
92
- collapseButton(): HTMLButtonElement;
93
- /**
94
- * Retrieves the breadcrumb trail for the current element by returning its parent element.
95
- * @returns {Element} The parent element representing the breadcrumb trail.
96
- */
97
- getBreadcrumbs(): Element;
98
- }
@@ -1,2 +0,0 @@
1
- import { default as Breadcrumbs } from './breadcrumbs.element.js';
2
- export default Breadcrumbs;
@@ -1,105 +0,0 @@
1
- import { default as WJElement } from '../wje-element/element.js';
2
- /**
3
- * @summary This class represents a Breadcrumbs container, extending the WJElement class. It acts as a wrapper for individual breadcrumb elements and manages their behavior, such as collapsing and marking the last breadcrumb.
4
- * @documentation https://elements.webjet.sk/components/breadcrumbs
5
- * @status stable
6
- * @augments WJElement
7
- * @slot - The container for breadcrumb elements.
8
- * @csspart container - The component's container wrapper.
9
- * @attribute {number} max-items - The maximum number of visible breadcrumbs before collapsing.
10
- * @attribute {number} items-before-collapse - The number of breadcrumbs to show before the collapsed indicator.
11
- * @attribute {number} items-after-collapse - The number of breadcrumbs to show after the collapsed indicator.
12
- * @tag wje-breadcrumbs
13
- * @example
14
- * <!-- Example usage -->
15
- * <wje-breadcrumbs max-items="5" items-before-collapse="2" items-after-collapse="2">
16
- * <wje-breadcrumb>Home</wje-breadcrumb>
17
- * <wje-breadcrumb>About</wje-breadcrumb>
18
- * <wje-breadcrumb>Services</wje-breadcrumb>
19
- * <wje-breadcrumb>Portfolio</wje-breadcrumb>
20
- * <wje-breadcrumb>Contact</wje-breadcrumb>
21
- * </wje-breadcrumbs>
22
- *
23
- * <!-- Output: Only the first two and last two breadcrumbs will be visible, with a collapsed indicator in the middle -->
24
- */
25
- export default class Breadcrumbs extends WJElement {
26
- /**
27
- * Get CSS stylesheet for the Breadcrumbs element.
28
- * @static
29
- * @returns {object} styles - The CSS styles
30
- */
31
- static get cssStyleSheet(): object;
32
- /**
33
- * Get observed attributes for the Breadcrumb element.
34
- * @static
35
- * @returns {Array<string>} - The observed attributes array for the Breadcrumb element.
36
- */
37
- static get observedAttributes(): Array<string>;
38
- /**
39
- * Last breadcrumb flag
40
- * @type {boolean}
41
- */
42
- last: boolean;
43
- /**
44
- * Set variant attribute for the Breadcrumbs element.
45
- * @param value
46
- */
47
- set variant(value: string);
48
- /**
49
- * Get variant attribute for the Breadcrumbs element.
50
- * @returns {string}
51
- */
52
- get variant(): string;
53
- /**
54
- * Get items before collapse attribute.
55
- * @param {string} value
56
- */
57
- set maxItems(value: string);
58
- /**
59
- * Get items before collapse attribute.
60
- * @returns {number}
61
- */
62
- get maxItems(): number;
63
- /**
64
- * Get items before collapse attribute.
65
- * @param value
66
- */
67
- set itemsBeforeCollapse(value: number);
68
- /**
69
- * Get items before collapse attribute.
70
- * @returns {number}
71
- */
72
- get itemsBeforeCollapse(): number;
73
- /**
74
- * Get items after collapse attribute.
75
- * @param value
76
- */
77
- set itemsAfterCollapse(value: number);
78
- /**
79
- * Get items after collapse attribute.
80
- * @returns {number}
81
- */
82
- get itemsAfterCollapse(): number;
83
- /**
84
- * Draw method for the Breadcrumbs element.
85
- * @returns {object} fragment - The document fragment
86
- */
87
- draw(): object;
88
- /**
89
- * Updates the breadcrumb elements after they are drawn on the page.
90
- * It manages attributes on breadcrumb items and handles the logic for collapsing breadcrumbs
91
- * if the total exceeds the specified maximum items.
92
- * @returns {void} This method does not return a value.
93
- */
94
- afterDraw(): void;
95
- /**
96
- * Retrieves all breadcrumb elements within the current instance.
97
- * @returns {Array<Element>} An array of breadcrumb elements (`wje-breadcrumb`) found within the instance. Returns an empty array if no breadcrumbs are found.
98
- */
99
- getBreadcrumbs(): Array<Element>;
100
- /**
101
- * Retrieves all breadcrumb elements that have the 'collapsed' attribute.
102
- * @returns {Array<Element>} An array of DOM elements representing breadcrumbs with the 'collapsed' attribute.
103
- */
104
- getBreadcrumbsCollapsed(): Array<Element>;
105
- }
@@ -1 +0,0 @@
1
- export {};
@@ -1,2 +0,0 @@
1
- import { default as Button } from './button.element.js';
2
- export default Button;
@@ -1,204 +0,0 @@
1
- import { default as WJElement } from '../wje-element/element.js';
2
- /**
3
- * @summary This class represents Button element, extending the WJElement class.
4
- * @documentation https://elements.webjet.sk/components/button
5
- * @status stable
6
- * @augments WJElement
7
- * @dependency wje-icon
8
- * @slot - The button main content.
9
- * @slot icon - The button icon.
10
- * @slot caret - The button caret.
11
- * @slot start - The button start slot.
12
- * @slot end - The button end slot.
13
- * @slot toggle - The button toggle slot.
14
- * @csspart native - The component's native wrapper.
15
- * @cssproperty [--wje-button-background-color=transparent] - Background color of the component;
16
- * @cssproperty [--wje-button-border-color=--wje-color-contrast-4] - Border color of the component;
17
- * @cssproperty [--wje-button-color=--wje-color-contrast-11] - Color of the component;
18
- * @cssproperty [--wje-button-border-radius=--wje-border-radius-medium] - Border radius of the component;
19
- * @cssproperty [--wje-button-border-width=1px] - Border width of the component;
20
- * @cssproperty [--wje-button-border-style=solid] - Border style of the component;
21
- * @cssproperty [--wje-button-border-color=--wje-color-contrast-1] - Border color of the component;
22
- * @cssproperty [--wje-button-margin-inline=0] - Margin inline of the component;
23
- */
24
- export default class Button extends WJElement {
25
- /**
26
- * Get CSS stylesheet for the Button element.
27
- * @static
28
- * @returns {CSSStyleSheet} styles - The CSS stylesheet for the Button element.
29
- */
30
- static get cssStyleSheet(): CSSStyleSheet;
31
- /**
32
- * Get observed attributes for the Button element.
33
- * @static
34
- * @returns {Array<string>} observedAttributes - The observed attributes array for the Button element.
35
- */
36
- static get observedAttributes(): Array<string>;
37
- /**
38
- * @summary A static property that indicates whether the custom element is form-associated or not.
39
- * Form-associated custom elements are elements that can participate in form submission.
40
- * @type {boolean}
41
- */
42
- static formAssociated: boolean;
43
- internals_: ElementInternals;
44
- /**
45
- * Dependencies of the Button element.
46
- * @type {object}
47
- */
48
- dependencies: object;
49
- /**
50
- * Properties of the element Button.
51
- * @param value
52
- */
53
- set color(value: string | string);
54
- /**
55
- * Get color of the Button element.
56
- * @returns {string|string}
57
- */
58
- get color(): string | string;
59
- /**
60
- * Set variant of the Button element.
61
- * @param value
62
- */
63
- set caret(value: boolean);
64
- /**
65
- * Get variant of the Button element.
66
- * @returns {boolean}
67
- */
68
- get caret(): boolean;
69
- /**
70
- * Sets the 'round' attribute on the element. If the value is true, the attribute is added;
71
- * otherwise, it is removed from the element.
72
- * @param {boolean} value A boolean indicating whether to set or remove the 'round' attribute.
73
- */
74
- set round(value: boolean);
75
- /**
76
- * Retrieves the value of the 'round' attribute as a boolean.
77
- * Checks if the 'round' attribute is present on the element.
78
- * @returns {boolean} True if the 'round' attribute exists, otherwise false.
79
- */
80
- get round(): boolean;
81
- /**
82
- * Set variant of the Button element.
83
- * @param value
84
- */
85
- set tooltip(value: boolean);
86
- /**
87
- * Get variant of the Button element.
88
- * @returns {boolean}
89
- */
90
- get tooltip(): boolean;
91
- /**
92
- * Set variant of the Button element.
93
- * @param value
94
- */
95
- set dialog(value: string | object);
96
- /**
97
- * Get variant of the Button element.
98
- * @returns {string|object}
99
- */
100
- get dialog(): string | object;
101
- /**
102
- * Set active state of the Button element.
103
- * @param {boolean} value The value to set
104
- */
105
- set active(value: boolean);
106
- /**
107
- * Get active state of the Button element.
108
- * @returns {boolean} active - The active state
109
- */
110
- get active(): boolean;
111
- /**
112
- * Set disabled state of the Button element.
113
- * @param {boolean} value The value to set
114
- */
115
- set disabled(value: boolean);
116
- /**
117
- * Get disabled state of the Button element.
118
- * @returns {boolean} disabled - The disabled state
119
- */
120
- get disabled(): boolean;
121
- /**
122
- * Set fill of the Button element.
123
- * @param {string} value The value to set
124
- */
125
- set fill(value: string);
126
- /**
127
- * Get fill of the Button element.
128
- * @returns {string} fill - The fill value
129
- */
130
- get fill(): string;
131
- /**
132
- * Set outline state of the Button element.
133
- * @param {boolean} value The value to set
134
- */
135
- set outline(value: boolean);
136
- /**
137
- * Get outline state of the Button element.
138
- * @returns {boolean} outline - The outline state
139
- */
140
- get outline(): boolean;
141
- /**
142
- * Set stop propagation state of the Button element.
143
- * @param {boolean} value The value to set
144
- */
145
- set stopPropagation(value: boolean);
146
- /**
147
- * Get stop propagation state of the Button element.
148
- * @returns {boolean} stopPropagation - The stop propagation state
149
- */
150
- get stopPropagation(): boolean;
151
- /**
152
- * Sets the value of the custom event attribute.
153
- * @param {string} value The value to be assigned to the custom event attribute.
154
- */
155
- set customEvent(value: string);
156
- /**
157
- * Retrieves the value of the 'custom-event' attribute from the element.
158
- * @returns {string | null} The value of the 'custom-event' attribute, or null if the attribute is not set.
159
- */
160
- get customEvent(): string | null;
161
- /**
162
- * Retrieves a mapped object containing custom event parameters extracted from the element's attributes.
163
- * Attributes considered are those that begin with 'custom-event-'.
164
- * The mapped object's keys are derived by removing the 'custom-event-' prefix from the attribute names,
165
- * and the values are the corresponding attribute values.
166
- * @returns {object} An object containing key-value pairs of custom event parameters.
167
- */
168
- get customEventParameters(): object;
169
- /**
170
- * @summary Callback function that is called when the custom element is associated with a form.
171
- * This function sets the internal `_form` property to the associated form.
172
- * @param {HTMLFormElement} form The form the custom element is associated with.
173
- */
174
- formAssociatedCallback(form: HTMLFormElement): void;
175
- _form: HTMLFormElement;
176
- /**
177
- * @summary Callback function that is called when the form-associated state of the custom element changes.
178
- * This function updates the 'disabled' attribute of the element based on the new state.
179
- * @param {boolean} disabled The new form-associated state.
180
- */
181
- formDisabledCallback(disabled: boolean): void;
182
- /**
183
- * Draw method for the Button element.
184
- * @returns {object} fragment - The document fragment containing the drawn element.
185
- */
186
- draw(): object;
187
- hasToggle: boolean;
188
- slotToggle: HTMLSlotElement;
189
- /**
190
- * After draw method for the Button element.
191
- */
192
- afterDraw(): void;
193
- unbindRouterLinks: any;
194
- /**
195
- * Event dialog open method for the Button element.
196
- * @param {Event} e The event object
197
- */
198
- eventDialogOpen: (e: Event) => void;
199
- /**
200
- * Toggle states method for the Button element.
201
- */
202
- toggleStates: () => void;
203
- #private;
204
- }
@@ -1 +0,0 @@
1
- export {};
@@ -1,2 +0,0 @@
1
- import { default as ButtonGroup } from './button-group.element.js';
2
- export default ButtonGroup;
@@ -1,96 +0,0 @@
1
- import { default as WJElement } from '../wje-element/element.js';
2
- /**
3
- * @summary ButtonGroup class
4
- * @class
5
- * @augments WJElement
6
- * @csspart native - The component's native wrapper.
7
- * @slot - The button group main content.
8
- * @csspart native - The component's native wrapper.
9
- */
10
- export default class ButtonGroup extends WJElement {
11
- /**
12
- * Get CSS stylesheet for the ButtonGroup element.
13
- * @static
14
- * @returns {object} styles - The CSS styles
15
- */
16
- static get cssStyleSheet(): object;
17
- /**
18
- * Get observed attributes for the ButtonGroup element.
19
- * @static
20
- * @returns {Array<string>} observedAttributes - The observed attributes array
21
- */
22
- static get observedAttributes(): Array<string>;
23
- /**
24
- * Sets the "active" attribute to indicate the active state.
25
- * @param {boolean|string|number} value The value to set for the "active" attribute, indicating the active state.
26
- */
27
- set active(value: boolean | string | number);
28
- /**
29
- * Retrieves the value of the 'active' attribute.
30
- * If the attribute is not set, it returns false.
31
- * @returns {string|boolean} The value of the 'active' attribute or false if it is not set.
32
- */
33
- get active(): string | boolean;
34
- /**
35
- * Sets the color attribute of the element.
36
- * @param {string} value The value to set for the color attribute.
37
- */
38
- set color(value: string);
39
- /**
40
- * Retrieves the current value of the 'color' attribute.
41
- * If the 'color' attribute is not set, it defaults to 'primary'.
42
- * @returns {string} The value of the 'color' attribute or the default value 'primary'.
43
- */
44
- get color(): string;
45
- /**
46
- * Sets the round attribute for the element.
47
- * @param {string} value The value to set for the round attribute.
48
- */
49
- set round(value: string);
50
- /**
51
- * Returns whether the element has the 'round' attribute.
52
- * @returns {boolean} True if the 'round' attribute is present, otherwise false.
53
- */
54
- get round(): boolean;
55
- /**
56
- * Sets the 'fill' attribute of the element.
57
- * @param {string} value The value to assign to the 'fill' attribute.
58
- */
59
- set fill(value: string);
60
- /**
61
- * Retrieves the 'fill' attribute of the element. If the 'fill' attribute is not set,
62
- * it returns the default value 'link'.
63
- * @returns {string} The value of the 'fill' attribute, or 'link' if the attribute is not present.
64
- */
65
- get fill(): string;
66
- /**
67
- * Draw method for the ButtonGroup element.
68
- * @returns {object} fragment - The document fragment
69
- */
70
- draw(): object;
71
- slotElement: HTMLSlotElement;
72
- /**
73
- * After draw method for the ButtonGroup element.
74
- */
75
- afterDraw(): void;
76
- /**
77
- * Find button method to find the button element.
78
- * @param {object} el The element
79
- * @returns {object} button - The button element
80
- */
81
- findButton(el: object): object;
82
- /**
83
- * Toggles the state of a group of buttons based on the active button.
84
- * @param {object} activeButton The button that is currently active.
85
- * @param {Array<object>} buttons An array of button objects to be toggled.
86
- * @returns {void} This method does not return a value.
87
- */
88
- toggle(activeButton: object, buttons: Array<object>, index: any): void;
89
- /**
90
- * Updates the state of a button by removing one mode attribute and setting another mode attribute.
91
- * @param {HTMLElement} button The button element whose state is to be updated.
92
- * @param {string} modeToRemove The mode attribute to be removed from the button. Expected values are 'color' or 'fill'.
93
- * @returns {void}
94
- */
95
- updateButtonState(button: HTMLElement, modeToRemove: string): void;
96
- }
@@ -1,2 +0,0 @@
1
- import { default as Card } from './card.element.js';
2
- export default Card;
@@ -1,31 +0,0 @@
1
- import { default as WJElement } from '../wje-element/element.js';
2
- /**
3
- * @summary This class represents Card element, extending the WJElement class.
4
- * @documentation https://elements.webjet.sk/components/card
5
- * @status stable
6
- * @augments WJElement
7
- * @slot - The card main content.
8
- * @cssproperty [--wje-card-background=#fff] - Background of the component;
9
- * @cssproperty [--wje-card-color=#000] - Color of the component;
10
- * @cssproperty [--wje-card-border-color=transparent] - Border color of the component;
11
- * @cssproperty [--wje-card-border-style=solid] - Border style of the component;
12
- * @cssproperty [--wje-card-border-width=1px] - Border width of the component;
13
- * @cssproperty [--wje-card-border-radius=0.5rem] - Border radius of the component;
14
- * @cssproperty [--wje-card-shadow=var(--wje-shadow-x-large)] - Shadow of the component;
15
- */
16
- export default class Card extends WJElement {
17
- /**
18
- * Get CSS stylesheet for the Card element.
19
- * @static
20
- * @returns {object} styles - The CSS styles
21
- */
22
- static get cssStyleSheet(): object;
23
- /**
24
- * Draw method for the Card element.
25
- * @param {object} context The context object
26
- * @param {object} store The store object
27
- * @param {object} params The parameters
28
- * @returns {object} fragment - The document fragment
29
- */
30
- draw(context: object, store: object, params: object): object;
31
- }
@@ -1,2 +0,0 @@
1
- import { default as CardContent } from './card-content.element.js';
2
- export default CardContent;