@zanichelli/albe-web-components 19.2.6-RC2 → 19.2.7

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 (250) hide show
  1. package/CHANGELOG.md +21 -0
  2. package/dist/cjs/{iconset-Bcbz2MS1.js → iconset-oiCBBbd2.js} +15 -3
  3. package/dist/cjs/index-D_S5lGcb.js +4 -4
  4. package/dist/cjs/index.cjs.js +1 -1
  5. package/dist/cjs/loader.cjs.js +1 -1
  6. package/dist/cjs/web-components-library.cjs.js +1 -1
  7. package/dist/cjs/z-alert.cjs.entry.js +1 -1
  8. package/dist/cjs/z-app-header_12.cjs.entry.js +127 -199
  9. package/dist/cjs/z-combobox.cjs.entry.js +5 -3
  10. package/dist/cjs/z-myz-card-alert.cjs.entry.js +1 -1
  11. package/dist/cjs/z-myz-card-dictionary.cjs.entry.js +1 -1
  12. package/dist/cjs/z-myz-card-footer-sections.cjs.entry.js +1 -1
  13. package/dist/cjs/z-myz-card-footer.cjs.entry.js +1 -1
  14. package/dist/cjs/z-myz-card-icon.cjs.entry.js +1 -1
  15. package/dist/cjs/z-myz-card-info.cjs.entry.js +1 -1
  16. package/dist/cjs/z-myz-card-list.cjs.entry.js +1 -1
  17. package/dist/cjs/z-myz-card_4.cjs.entry.js +4 -4
  18. package/dist/cjs/z-myz-list-item.cjs.entry.js +1 -1
  19. package/dist/cjs/z-myz-list.cjs.entry.js +1 -1
  20. package/dist/cjs/z-otp.cjs.entry.js +2 -2
  21. package/dist/cjs/z-pagination.cjs.entry.js +2 -2
  22. package/dist/cjs/z-skip-to-content.cjs.entry.js +1 -1
  23. package/dist/cjs/z-stepper-item.cjs.entry.js +1 -1
  24. package/dist/cjs/z-stepper.cjs.entry.js +1 -1
  25. package/dist/cjs/z-td.cjs.entry.js +3 -3
  26. package/dist/cjs/z-th.cjs.entry.js +5 -3
  27. package/dist/cjs/z-toast-notification-list.cjs.entry.js +1 -1
  28. package/dist/cjs/z-toast-notification.cjs.entry.js +3 -3
  29. package/dist/cjs/z-toggle-button.cjs.entry.js +2 -2
  30. package/dist/cjs/z-toggle-switch.cjs.entry.js +3 -3
  31. package/dist/cjs/z-tool.cjs.entry.js +2 -2
  32. package/dist/cjs/z-toolbar.cjs.entry.js +1 -1
  33. package/dist/cjs/z-tooltip.cjs.entry.js +1 -1
  34. package/dist/collection/components/css-components/z-scrollbar/styles.css +40 -0
  35. package/dist/collection/components/table/cells/{z-td/styles.css → z-table-cells.css} +0 -1
  36. package/dist/collection/components/table/cells/z-td/index.js +3 -3
  37. package/dist/collection/components/table/cells/z-th/index.js +3 -3
  38. package/dist/collection/components/table/cells/z-th/styles.css +0 -72
  39. package/dist/collection/components/z-combobox/index.js +3 -3
  40. package/dist/collection/components/z-combobox/styles.css +0 -12
  41. package/dist/collection/components/z-input/index.js +3 -3
  42. package/dist/collection/components/z-input/styles-checkbox-radio.css +130 -0
  43. package/dist/collection/components/z-input/styles-general.css +166 -0
  44. package/dist/collection/components/z-input/styles-text.css +87 -0
  45. package/dist/collection/components/z-input/styles-textarea.css +19 -0
  46. package/dist/collection/components/z-pagination/index.js +2 -2
  47. package/dist/collection/components/z-searchbar/index.js +111 -193
  48. package/dist/collection/components/z-searchbar/index.stories.js +3 -16
  49. package/dist/collection/components/z-searchbar/styles.css +87 -201
  50. package/dist/collection/components/z-skip-to-content/index.js +1 -1
  51. package/dist/collection/components/z-stepper/index.js +1 -1
  52. package/dist/collection/components/z-stepper-item/index.js +1 -1
  53. package/dist/collection/components/z-toast-notification/index.js +3 -3
  54. package/dist/collection/components/z-toast-notification-list/index.js +1 -1
  55. package/dist/collection/components/z-toggle-button/index.js +2 -2
  56. package/dist/collection/components/z-toggle-switch/index.js +3 -3
  57. package/dist/collection/components/z-tool/index.js +3 -3
  58. package/dist/collection/components/z-toolbar/index.js +1 -1
  59. package/dist/collection/components/z-tooltip/index.js +1 -1
  60. package/dist/collection/constants/iconset.js +15 -3
  61. package/dist/collection/snowflakes/myz/card/z-myz-card/index.js +1 -1
  62. package/dist/collection/snowflakes/myz/card/z-myz-card-alert/index.js +1 -1
  63. package/dist/collection/snowflakes/myz/card/z-myz-card-body/index.js +1 -1
  64. package/dist/collection/snowflakes/myz/card/z-myz-card-cover/index.js +1 -1
  65. package/dist/collection/snowflakes/myz/card/z-myz-card-dictionary/index.js +1 -1
  66. package/dist/collection/snowflakes/myz/card/z-myz-card-footer/index.js +1 -1
  67. package/dist/collection/snowflakes/myz/card/z-myz-card-footer-sections/index.js +1 -1
  68. package/dist/collection/snowflakes/myz/card/z-myz-card-header/index.js +1 -1
  69. package/dist/collection/snowflakes/myz/card/z-myz-card-icon/index.js +1 -1
  70. package/dist/collection/snowflakes/myz/card/z-myz-card-info/index.js +1 -1
  71. package/dist/collection/snowflakes/myz/card/z-myz-card-list/index.js +1 -1
  72. package/dist/collection/snowflakes/myz/list/z-myz-list/index.js +1 -1
  73. package/dist/collection/snowflakes/myz/list/z-myz-list-item/index.js +1 -1
  74. package/dist/collection/snowflakes/myz/z-alert/index.js +1 -1
  75. package/dist/collection/snowflakes/myz/z-otp/index.js +2 -2
  76. package/dist/components/iconset.js +1 -1
  77. package/dist/components/index13.js +1 -1
  78. package/dist/components/index22.js +1 -1
  79. package/dist/components/index23.js +1 -1
  80. package/dist/components/index24.js +1 -1
  81. package/dist/components/index25.js +1 -1
  82. package/dist/components/index26.js +1 -1
  83. package/dist/components/index27.js +1 -1
  84. package/dist/components/index4.js +1 -1
  85. package/dist/components/index7.js +1 -1
  86. package/dist/components/z-combobox.js +1 -1
  87. package/dist/components/z-myz-card-alert.js +1 -1
  88. package/dist/components/z-myz-card-dictionary.js +1 -1
  89. package/dist/components/z-myz-card-footer-sections.js +1 -1
  90. package/dist/components/z-myz-card-footer.js +1 -1
  91. package/dist/components/z-myz-card-icon.js +1 -1
  92. package/dist/components/z-myz-card-info.js +1 -1
  93. package/dist/components/z-myz-card-list.js +1 -1
  94. package/dist/components/z-myz-list.js +1 -1
  95. package/dist/components/z-otp.js +1 -1
  96. package/dist/components/z-pagination.js +1 -1
  97. package/dist/components/z-skip-to-content.js +1 -1
  98. package/dist/components/z-stepper-item.js +1 -1
  99. package/dist/components/z-stepper.js +1 -1
  100. package/dist/components/z-td.js +1 -1
  101. package/dist/components/z-th.js +1 -1
  102. package/dist/components/z-toast-notification-list.js +1 -1
  103. package/dist/components/z-toast-notification.js +1 -1
  104. package/dist/components/z-toggle-button.js +1 -1
  105. package/dist/components/z-toggle-switch.js +1 -1
  106. package/dist/components/z-tool.js +1 -1
  107. package/dist/components/z-toolbar.js +1 -1
  108. package/dist/esm/{iconset-BanpkIXZ.js → iconset-CjHS9zeM.js} +15 -3
  109. package/dist/esm/index-DPdXlnVe.js +4 -4
  110. package/dist/esm/index.js +2 -2
  111. package/dist/esm/loader.js +1 -1
  112. package/dist/esm/{utils-0PByxJyN.js → utils-DYd3kO0P.js} +1 -1
  113. package/dist/esm/web-components-library.js +1 -1
  114. package/dist/esm/z-alert.entry.js +1 -1
  115. package/dist/esm/z-app-header_12.entry.js +129 -201
  116. package/dist/esm/z-book-card-deprecated.entry.js +1 -1
  117. package/dist/esm/z-breadcrumb.entry.js +1 -1
  118. package/dist/esm/z-color-picker.entry.js +1 -1
  119. package/dist/esm/z-combobox.entry.js +6 -4
  120. package/dist/esm/z-menu.entry.js +1 -1
  121. package/dist/esm/z-myz-card-alert.entry.js +1 -1
  122. package/dist/esm/z-myz-card-dictionary.entry.js +1 -1
  123. package/dist/esm/z-myz-card-footer-sections.entry.js +1 -1
  124. package/dist/esm/z-myz-card-footer.entry.js +1 -1
  125. package/dist/esm/z-myz-card-icon.entry.js +1 -1
  126. package/dist/esm/z-myz-card-info.entry.js +2 -2
  127. package/dist/esm/z-myz-card-list.entry.js +1 -1
  128. package/dist/esm/z-myz-card_4.entry.js +4 -4
  129. package/dist/esm/z-myz-list-item.entry.js +2 -2
  130. package/dist/esm/z-myz-list.entry.js +1 -1
  131. package/dist/esm/z-otp.entry.js +2 -2
  132. package/dist/esm/z-pagination.entry.js +2 -2
  133. package/dist/esm/z-popover.entry.js +1 -1
  134. package/dist/esm/z-select.entry.js +1 -1
  135. package/dist/esm/z-skip-to-content.entry.js +2 -2
  136. package/dist/esm/z-slideshow.entry.js +1 -1
  137. package/dist/esm/z-stepper-item.entry.js +1 -1
  138. package/dist/esm/z-stepper.entry.js +1 -1
  139. package/dist/esm/z-table.entry.js +1 -1
  140. package/dist/esm/z-td.entry.js +3 -3
  141. package/dist/esm/z-th.entry.js +5 -3
  142. package/dist/esm/z-toast-notification-list.entry.js +1 -1
  143. package/dist/esm/z-toast-notification.entry.js +3 -3
  144. package/dist/esm/z-toggle-button.entry.js +2 -2
  145. package/dist/esm/z-toggle-switch.entry.js +4 -4
  146. package/dist/esm/z-tool.entry.js +3 -3
  147. package/dist/esm/z-toolbar.entry.js +1 -1
  148. package/dist/esm/z-tooltip.entry.js +1 -1
  149. package/dist/esm/z-tr.entry.js +1 -1
  150. package/dist/types/components/z-searchbar/index.d.ts +24 -28
  151. package/dist/types/components.d.ts +14 -14
  152. package/dist/types/constants/iconset.d.ts +30 -6
  153. package/dist/web-components-library/index.esm.js +1 -1
  154. package/dist/web-components-library/p-087956fa.entry.js +1 -0
  155. package/dist/web-components-library/{p-5fa910e4.entry.js → p-13e7f751.entry.js} +1 -1
  156. package/dist/web-components-library/{p-2ce3ac48.entry.js → p-14b804f9.entry.js} +1 -1
  157. package/dist/web-components-library/{p-45866f64.entry.js → p-1580db58.entry.js} +1 -1
  158. package/{www/build/p-eed4e897.entry.js → dist/web-components-library/p-1d023220.entry.js} +1 -1
  159. package/dist/web-components-library/{p-de0b7109.entry.js → p-299f0f85.entry.js} +1 -1
  160. package/dist/web-components-library/{p-d11d39f5.entry.js → p-2c036e17.entry.js} +1 -1
  161. package/dist/web-components-library/{p-5b9cacd7.entry.js → p-2df6d169.entry.js} +1 -1
  162. package/dist/web-components-library/{p-550ee6c3.entry.js → p-37e84b71.entry.js} +1 -1
  163. package/dist/web-components-library/{p-6fb8a984.entry.js → p-3ea03d34.entry.js} +1 -1
  164. package/dist/web-components-library/p-41584e90.entry.js +1 -0
  165. package/dist/web-components-library/p-53670be4.entry.js +1 -0
  166. package/dist/web-components-library/{p-7d9477ed.entry.js → p-583b8152.entry.js} +1 -1
  167. package/dist/web-components-library/{p-538a1bd2.entry.js → p-5d20fc3d.entry.js} +1 -1
  168. package/dist/web-components-library/{p-364b0ca4.entry.js → p-658f022d.entry.js} +1 -1
  169. package/dist/web-components-library/{p-f94c360f.entry.js → p-788eaac7.entry.js} +1 -1
  170. package/dist/web-components-library/{p-a40ae683.entry.js → p-8261c869.entry.js} +1 -1
  171. package/{www/build/p-4ae7df7f.entry.js → dist/web-components-library/p-83da1031.entry.js} +1 -1
  172. package/{www/build/p-c6920758.entry.js → dist/web-components-library/p-85cac60d.entry.js} +1 -1
  173. package/dist/web-components-library/{p-c6ae9241.entry.js → p-88a3ba7c.entry.js} +1 -1
  174. package/dist/web-components-library/{p-e2d94c86.entry.js → p-8a8df4f4.entry.js} +1 -1
  175. package/dist/web-components-library/{p-ab50e989.entry.js → p-8b026993.entry.js} +1 -1
  176. package/dist/web-components-library/{p-8fd25c59.entry.js → p-9d15ecdf.entry.js} +1 -1
  177. package/dist/web-components-library/{p-D4yqZKyM.js → p-CPsEG702.js} +1 -1
  178. package/dist/web-components-library/p-CjHS9zeM.js +1 -0
  179. package/dist/web-components-library/{p-f5bbcaa6.entry.js → p-a4f673f8.entry.js} +1 -1
  180. package/dist/web-components-library/{p-2d6a4515.entry.js → p-b6223d7e.entry.js} +1 -1
  181. package/dist/web-components-library/{p-7835fdda.entry.js → p-b9343431.entry.js} +1 -1
  182. package/dist/web-components-library/{p-c539ae57.entry.js → p-c42ddd93.entry.js} +1 -1
  183. package/{www/build/p-eadf2552.entry.js → dist/web-components-library/p-c4e7bd16.entry.js} +1 -1
  184. package/dist/web-components-library/{p-3f996a63.entry.js → p-c944a943.entry.js} +1 -1
  185. package/dist/web-components-library/{p-19f5fdd3.entry.js → p-cd33f4b1.entry.js} +1 -1
  186. package/dist/web-components-library/p-d10e6b1a.entry.js +1 -0
  187. package/dist/web-components-library/p-dc5ab2cc.entry.js +1 -0
  188. package/dist/web-components-library/p-e48497f0.entry.js +1 -0
  189. package/dist/web-components-library/{p-19d3a16b.entry.js → p-eddc2d19.entry.js} +1 -1
  190. package/dist/web-components-library/{p-91503030.entry.js → p-ef5018bb.entry.js} +1 -1
  191. package/dist/web-components-library/{p-7a9d19b8.entry.js → p-f7e46ef2.entry.js} +1 -1
  192. package/dist/web-components-library/web-components-library.esm.js +1 -1
  193. package/package.json +2 -3
  194. package/www/build/index.esm.js +1 -1
  195. package/www/build/p-087956fa.entry.js +1 -0
  196. package/www/build/{p-5fa910e4.entry.js → p-13e7f751.entry.js} +1 -1
  197. package/www/build/{p-2ce3ac48.entry.js → p-14b804f9.entry.js} +1 -1
  198. package/www/build/{p-45866f64.entry.js → p-1580db58.entry.js} +1 -1
  199. package/{dist/web-components-library/p-eed4e897.entry.js → www/build/p-1d023220.entry.js} +1 -1
  200. package/www/build/{p-38f551b0.js → p-23143b48.js} +1 -1
  201. package/www/build/{p-de0b7109.entry.js → p-299f0f85.entry.js} +1 -1
  202. package/www/build/{p-d11d39f5.entry.js → p-2c036e17.entry.js} +1 -1
  203. package/www/build/{p-5b9cacd7.entry.js → p-2df6d169.entry.js} +1 -1
  204. package/www/build/{p-550ee6c3.entry.js → p-37e84b71.entry.js} +1 -1
  205. package/www/build/{p-6fb8a984.entry.js → p-3ea03d34.entry.js} +1 -1
  206. package/www/build/p-41584e90.entry.js +1 -0
  207. package/www/build/p-53670be4.entry.js +1 -0
  208. package/www/build/{p-7d9477ed.entry.js → p-583b8152.entry.js} +1 -1
  209. package/www/build/{p-538a1bd2.entry.js → p-5d20fc3d.entry.js} +1 -1
  210. package/www/build/{p-364b0ca4.entry.js → p-658f022d.entry.js} +1 -1
  211. package/www/build/{p-f94c360f.entry.js → p-788eaac7.entry.js} +1 -1
  212. package/www/build/{p-a40ae683.entry.js → p-8261c869.entry.js} +1 -1
  213. package/{dist/web-components-library/p-4ae7df7f.entry.js → www/build/p-83da1031.entry.js} +1 -1
  214. package/{dist/web-components-library/p-c6920758.entry.js → www/build/p-85cac60d.entry.js} +1 -1
  215. package/www/build/{p-c6ae9241.entry.js → p-88a3ba7c.entry.js} +1 -1
  216. package/www/build/{p-e2d94c86.entry.js → p-8a8df4f4.entry.js} +1 -1
  217. package/www/build/{p-ab50e989.entry.js → p-8b026993.entry.js} +1 -1
  218. package/www/build/{p-8fd25c59.entry.js → p-9d15ecdf.entry.js} +1 -1
  219. package/www/build/{p-D4yqZKyM.js → p-CPsEG702.js} +1 -1
  220. package/www/build/p-CjHS9zeM.js +1 -0
  221. package/www/build/{p-f5bbcaa6.entry.js → p-a4f673f8.entry.js} +1 -1
  222. package/www/build/{p-2d6a4515.entry.js → p-b6223d7e.entry.js} +1 -1
  223. package/www/build/{p-7835fdda.entry.js → p-b9343431.entry.js} +1 -1
  224. package/www/build/{p-c539ae57.entry.js → p-c42ddd93.entry.js} +1 -1
  225. package/{dist/web-components-library/p-eadf2552.entry.js → www/build/p-c4e7bd16.entry.js} +1 -1
  226. package/www/build/{p-3f996a63.entry.js → p-c944a943.entry.js} +1 -1
  227. package/www/build/{p-19f5fdd3.entry.js → p-cd33f4b1.entry.js} +1 -1
  228. package/www/build/p-d10e6b1a.entry.js +1 -0
  229. package/www/build/p-dc5ab2cc.entry.js +1 -0
  230. package/www/build/p-e48497f0.entry.js +1 -0
  231. package/www/build/{p-19d3a16b.entry.js → p-eddc2d19.entry.js} +1 -1
  232. package/www/build/{p-91503030.entry.js → p-ef5018bb.entry.js} +1 -1
  233. package/www/build/{p-7a9d19b8.entry.js → p-f7e46ef2.entry.js} +1 -1
  234. package/www/build/web-components-library.esm.js +1 -1
  235. package/www/index.html +1 -1
  236. package/dist/collection/components/z-input/styles.css +0 -406
  237. package/dist/web-components-library/p-2b7ceab2.entry.js +0 -1
  238. package/dist/web-components-library/p-BanpkIXZ.js +0 -1
  239. package/dist/web-components-library/p-a9d90b04.entry.js +0 -1
  240. package/dist/web-components-library/p-a9f848ef.entry.js +0 -1
  241. package/dist/web-components-library/p-ae69bb7d.entry.js +0 -1
  242. package/dist/web-components-library/p-f3436721.entry.js +0 -1
  243. package/dist/web-components-library/p-fc15a666.entry.js +0 -1
  244. package/www/build/p-2b7ceab2.entry.js +0 -1
  245. package/www/build/p-BanpkIXZ.js +0 -1
  246. package/www/build/p-a9d90b04.entry.js +0 -1
  247. package/www/build/p-a9f848ef.entry.js +0 -1
  248. package/www/build/p-ae69bb7d.entry.js +0 -1
  249. package/www/build/p-f3436721.entry.js +0 -1
  250. package/www/build/p-fc15a666.entry.js +0 -1
@@ -1,6 +1,6 @@
1
1
  import { Host, h, } from "@stencil/core";
2
- import { ButtonVariant, ControlSize, Device, KeyboardCode, ListDividerType, } from "../../beans";
3
- import { getDevice, handleEnterKeydSubmit, randomId } from "../../utils/utils";
2
+ import { ButtonVariant, ControlSize, KeyboardCode, } from "../../beans";
3
+ import { handleEnterKeydSubmit, randomId } from "../../utils/utils";
4
4
  /**
5
5
  * @cssprop --z-searchbar-results-height - Max height of the results container (default: 540px)
6
6
  * @cssprop --z-searchbar-tag-text-color - Color of tag's text (default --color-primary03);
@@ -8,7 +8,7 @@ import { getDevice, handleEnterKeydSubmit, randomId } from "../../utils/utils";
8
8
  */
9
9
  export class ZSearchbar {
10
10
  constructor() {
11
- /** the id of the searchbar element */
11
+ /** The id of the searchbar element */
12
12
  this.htmlid = `searchbar-${randomId()}`;
13
13
  /** Prevent submit action */
14
14
  this.preventSubmit = false;
@@ -22,30 +22,26 @@ export class ZSearchbar {
22
22
  this.sortResultsItems = false;
23
23
  /** Show submit button */
24
24
  this.showSearchButton = false;
25
- /** Set button icon without label*/
25
+ /** Hide the label of the submit button, showing only the icon */
26
26
  this.searchButtonIconOnly = false;
27
- /** Available sizes: `big`, `small` and `x-small`. Defaults to `big`. */
27
+ /** Size of the `z-input` and submit `z-button` */
28
28
  this.size = ControlSize.BIG;
29
- /** Graphical variant: `primary`, `secondary`, `tertiary`. Defaults to `primary`. */
29
+ /** Submit `z-button` variant */
30
30
  this.variant = ButtonVariant.PRIMARY;
31
31
  this.searchString = this.value;
32
- this.currResultsCount = 0;
32
+ this.currResultsCount = this.resultsCount;
33
33
  this.showResults = false;
34
34
  this.isMobile = false;
35
35
  this.resultsItemsList = null;
36
- this.items = [];
37
- }
38
- emitSearchSubmit() {
39
- this.searchSubmit.emit(this.inputRef.value);
40
- }
41
- emitSearchTyping(search) {
42
- this.searchTyping.emit(search);
43
36
  }
44
37
  emitSearchItemClick(item) {
45
38
  this.searchItemClick.emit(item);
46
39
  this.selectedItem = item;
47
40
  this.searchString = "";
48
41
  }
42
+ emitSearchSubmit() {
43
+ this.searchSubmit.emit(this.inputRef.value);
44
+ }
49
45
  watchItems() {
50
46
  this.resultsItemsList = this.getResultsItemsList();
51
47
  }
@@ -56,42 +52,17 @@ export class ZSearchbar {
56
52
  this.searchString = this.value;
57
53
  }
58
54
  watchSearchString() {
59
- this.emitSearchTyping(this.searchString);
60
- this.items = [];
55
+ this.searchTyping.emit(this.searchString);
61
56
  if (!this.searchString) {
62
57
  this.currResultsCount = this.resultsCount;
63
58
  }
64
59
  }
65
- watchShowResults() {
66
- if (!this.showResults) {
67
- this.items = [];
68
- }
69
- }
70
- disconnectedCallback() {
71
- var _a;
72
- (_a = this.resizeObserver) === null || _a === void 0 ? void 0 : _a.disconnect();
73
- }
74
- componentDidLoad() {
75
- this.resizeObserver = new ResizeObserver(() => {
76
- if (getDevice() === Device.MOBILE && !this.isMobile) {
77
- this.isMobile = true;
78
- }
79
- if (getDevice() !== Device.MOBILE && this.isMobile) {
80
- this.isMobile = false;
81
- }
82
- });
83
- this.resizeObserver.observe(this.element);
84
- }
85
- componentWillLoad() {
86
- this.resultsItemsList = this.getResultsItemsList();
87
- this.currResultsCount = this.resultsCount;
88
- }
89
60
  getResultsItemsList() {
90
61
  return typeof this.resultsItems === "string" ? JSON.parse(this.resultsItems) : this.resultsItems;
91
62
  }
92
- getGroupedItems(items) {
63
+ getGroupedItems() {
93
64
  const groupedItems = {};
94
- items.forEach((item) => {
65
+ this.resultsItemsList.forEach((item) => {
95
66
  var _a;
96
67
  const key = `${item === null || item === void 0 ? void 0 : item.category}${item === null || item === void 0 ? void 0 : item.subcategory}`;
97
68
  groupedItems[key] = (_a = groupedItems[key]) !== null && _a !== void 0 ? _a : {
@@ -121,148 +92,77 @@ export class ZSearchbar {
121
92
  }
122
93
  return groupedItems;
123
94
  }
124
- checkResultsCount(counter) {
125
- if (!this.currResultsCount || counter < this.currResultsCount) {
126
- return true;
127
- }
128
- return false;
129
- }
130
- handleStopTyping(e) {
131
- e.stopPropagation();
132
- this.searchString = e.detail.value;
133
- if (this.selectedItem) {
134
- this.selectedItem = undefined;
135
- }
136
- }
137
- handleSubmit() {
138
- if (this.preventSubmit) {
95
+ onListItemKeyDown(e, item) {
96
+ if (e.key === KeyboardCode.ENTER) {
97
+ e.preventDefault();
98
+ this.emitSearchItemClick(item);
139
99
  return;
140
100
  }
141
- this.emitSearchSubmit();
101
+ this.handleArrowsNavigation(e);
142
102
  }
143
- handleOutsideClick(e) {
144
- const cp = e.composedPath();
145
- const searchbar = cp.find((elem) => elem.nodeName === "Z-SEARCHBAR");
146
- if (!searchbar || searchbar.htmlid !== this.htmlid) {
147
- this.showResults = false;
148
- return;
149
- }
150
- if (cp.find((elem) => { var _a; return (elem === null || elem === void 0 ? void 0 : elem.nodeName) === "Z-INPUT" || ((_a = elem === null || elem === void 0 ? void 0 : elem.classList) === null || _a === void 0 ? void 0 : _a.contains("results")); })) {
151
- this.showResults = true;
103
+ onSearchHelperKeyDown(e) {
104
+ if (e.key === KeyboardCode.ENTER) {
105
+ e.preventDefault();
106
+ this.emitSearchSubmit();
152
107
  return;
153
108
  }
154
- this.showResults = false;
155
- }
156
- renderInput() {
157
- var _a;
158
- return (h("z-input", { ref: (val) => {
159
- this.inputRef = val;
160
- }, htmlid: `input-${this.htmlid}`, message: false, placeholder: this.placeholder, onStopTyping: (e) => this.handleStopTyping(e), onKeyUp: (e) => {
161
- handleEnterKeydSubmit(e, () => this.handleSubmit());
162
- this.handleArrowsNavigation(e);
163
- }, value: this.searchString || ((_a = this.selectedItem) === null || _a === void 0 ? void 0 : _a.label), size: this.size, label: this.label, "aria-label": this.htmlAriaLabel || this.placeholder }));
164
- }
165
- renderButton() {
166
- if (!this.showSearchButton) {
167
- return null;
168
- }
169
- const iconProp = this.searchButtonIconOnly ? { icon: "search" } : null;
170
- const buttonLabel = this.searchButtonIconOnly ? "" : "CERCA";
171
- const ariaLabel = this.searchButtonIconOnly ? { "aria-label": "CERCA" } : null;
172
- const defaultProps = Object.assign(Object.assign({ disabled: this.preventSubmit, variant: this.variant, size: this.size, onClick: () => this.handleSubmit() }, iconProp), ariaLabel);
173
- return h("z-button", Object.assign({}, defaultProps), buttonLabel);
174
- }
175
- renderResults() {
176
- if (!this.showResults ||
177
- !this.autocomplete ||
178
- !this.searchString ||
179
- this.searchString.length < this.autocompleteMinChars ||
180
- !this.resultsItemsList) {
181
- return null;
182
- }
183
- return (h("div", { class: "results-wrapper" }, h("div", { class: "results" }, this.renderResultsList())));
184
- }
185
- renderResultsList() {
186
- var _a, _b;
187
- if (this.preventSubmit && !((_a = this.resultsItemsList) === null || _a === void 0 ? void 0 : _a.length)) {
188
- return (h("span", { class: "item item-no-results" }, "Non abbiamo trovato risultati per ", h("b", null, this.searchString), h("br", null), h("br", null), "Cosa puoi fare?", h("ul", null, h("li", null, "Verificare di aver scritto bene"), h("li", null, "Provare a cercare un'altra parola"), h("li", null, "Provare a cercare qualcosa di pi\u00F9 generico"))));
189
- }
190
- return (h("z-list", { role: "listbox", id: `list-${this.htmlid}`, "aria-label": this.htmlAriaLabel || this.label }, this.renderSearchHelper(!!((_b = this.resultsItemsList) === null || _b === void 0 ? void 0 : _b.length)), this.renderItems(), this.renderShowAllResults()));
191
- }
192
- renderItems() {
193
- var _a;
194
- if (!((_a = this.resultsItemsList) === null || _a === void 0 ? void 0 : _a.length)) {
195
- return [];
196
- }
197
- const groupedItems = this.getGroupedItems(this.resultsItemsList);
198
- const listGroups = [];
199
- let counter = 0;
200
- Object.values(groupedItems).forEach((groupItem, index, array) => {
201
- if (this.checkResultsCount(counter)) {
202
- const listGroupsElements = [];
203
- groupItem.items.forEach((item, subindex, subarray) => {
204
- if (this.checkResultsCount(counter)) {
205
- const isLast = index === array.length - 1 && subindex === subarray.length - 1;
206
- listGroupsElements.push(this.renderItem(item, subindex, !isLast));
207
- }
208
- counter++;
209
- });
210
- if (listGroupsElements.length) {
211
- listGroups.push(h("z-list-group", { "divider-type": ListDividerType.ELEMENT }, this.renderItemCategory(groupItem), listGroupsElements));
212
- }
213
- }
214
- });
215
- return listGroups;
109
+ this.handleArrowsNavigation(e);
216
110
  }
217
111
  handleArrowsNavigation(e) {
218
- const currentElement = e.target;
219
- const arrows = [KeyboardCode.ARROW_DOWN, KeyboardCode.ARROW_UP];
220
- if (!arrows.includes(e.key)) {
221
- e.preventDefault();
112
+ var _a, _b, _c, _d, _e, _f;
113
+ if (![KeyboardCode.ARROW_DOWN, KeyboardCode.ARROW_UP].includes(e.key)) {
222
114
  return;
223
115
  }
224
- if (!this.items.length) {
225
- const list = this.element.shadowRoot.querySelector("z-list");
226
- if (!list) {
227
- return;
228
- }
229
- this.items = Array.from(list.querySelectorAll(".list-element"));
230
- }
231
- this.items.forEach((item) => {
232
- item.classList.toggle("focused", false);
233
- });
234
- const currentIndex = this.items.indexOf(currentElement);
116
+ const currentElement = e.target;
117
+ const items = Array.from((_b = (_a = this.host.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelectorAll("z-list .list-item")) !== null && _b !== void 0 ? _b : []);
118
+ const currentIndex = items.indexOf(currentElement);
235
119
  if (e.key === KeyboardCode.ARROW_DOWN) {
236
120
  e.preventDefault();
237
121
  const nextIndex = currentIndex + 1;
238
- if (nextIndex < this.items.length) {
239
- this.items[nextIndex].focus();
240
- this.items[nextIndex].classList.add("focused");
122
+ if (nextIndex < items.length) {
123
+ items[nextIndex].focus();
241
124
  }
242
125
  }
243
126
  if (e.key === KeyboardCode.ARROW_UP) {
244
127
  e.preventDefault();
245
128
  const prevIndex = currentIndex - 1;
246
129
  if (prevIndex < 0) {
247
- this.element.shadowRoot.querySelector("input").focus();
248
- this.element.shadowRoot
249
- .querySelector("input")
250
- .setSelectionRange(this.inputRef.value.length, this.inputRef.value.length);
130
+ (_d = (_c = this.host.shadowRoot) === null || _c === void 0 ? void 0 : _c.querySelector("input")) === null || _d === void 0 ? void 0 : _d.focus();
131
+ (_f = (_e = this.host.shadowRoot) === null || _e === void 0 ? void 0 : _e.querySelector("input")) === null || _f === void 0 ? void 0 : _f.setSelectionRange(this.inputRef.value.length, this.inputRef.value.length);
251
132
  }
252
133
  if (prevIndex >= 0) {
253
- this.items[prevIndex].focus();
254
- this.items[prevIndex].classList.add("focused");
134
+ items[prevIndex].focus();
255
135
  }
256
136
  }
257
137
  }
258
- renderItem(item, key, divider) {
259
- return (h("z-list-element", { id: `list-item-${this.htmlid}-${key}`, tabIndex: 0, role: "option", dividerType: divider ? ListDividerType.ELEMENT : undefined, onKeyDown: (e) => this.handleArrowsNavigation(e) }, h("div", { class: "list-element", tabIndex: 0, onClick: () => this.emitSearchItemClick(item), onKeyDown: (e) => handleEnterKeydSubmit(e, () => this.emitSearchItemClick(item)), onMouseEnter: (e) => {
260
- const currentElement = e.target;
261
- currentElement.classList.add("hovered");
262
- }, onMouseLeave: (e) => {
263
- const currentElement = e.target;
264
- currentElement.classList.toggle("hovered", false);
265
- } }, h("span", { class: "item ellipsis" }, (item === null || item === void 0 ? void 0 : item.icon) && (h("z-icon", { class: "item-icon", name: item.icon })), h("span", { class: "item-label", title: item.label, innerHTML: this.renderItemLabel(item.label) })), (item === null || item === void 0 ? void 0 : item.tag) && h("z-tag", { icon: item.tag.icon }, !this.isMobile ? item.tag.text : "")), item.children && item.children.length > 0 ? (h("z-list", null, h("div", { class: "children-node" }, item.children.map((child, index) => this.renderItem(child, index, false))))) : null));
138
+ handleStopTyping(e) {
139
+ e.stopPropagation();
140
+ this.searchString = e.detail.value;
141
+ this.selectedItem = undefined;
142
+ }
143
+ handleSubmit() {
144
+ if (this.preventSubmit) {
145
+ return;
146
+ }
147
+ this.emitSearchSubmit();
148
+ }
149
+ handleOutsideClick(e) {
150
+ const cp = e.composedPath();
151
+ if (cp.includes(this.host)) {
152
+ return;
153
+ }
154
+ this.showResults = false;
155
+ }
156
+ componentWillLoad() {
157
+ this.resultsItemsList = this.getResultsItemsList();
158
+ this.mql = matchMedia("(max-width: 767px)");
159
+ this.onMobileViewChange = (e) => (this.isMobile = e.matches);
160
+ this.mql.addEventListener("change", this.onMobileViewChange);
161
+ this.isMobile = this.mql.matches;
162
+ }
163
+ disconnectedCallback() {
164
+ var _a;
165
+ (_a = this.mql) === null || _a === void 0 ? void 0 : _a.removeEventListener("change", this.onMobileViewChange);
266
166
  }
267
167
  renderItemLabel(label) {
268
168
  if (!this.searchString) {
@@ -270,41 +170,62 @@ export class ZSearchbar {
270
170
  }
271
171
  return label.replace(new RegExp(this.searchString.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), "gmi"), (found) => `<mark>${found}</mark>`);
272
172
  }
273
- renderItemCategory(groupItem) {
274
- if (!(groupItem === null || groupItem === void 0 ? void 0 : groupItem.category)) {
275
- return null;
276
- }
277
- return (h("span", { class: "category-heading", slot: "header-title" }, h("span", { class: "category" }, groupItem.category), (groupItem === null || groupItem === void 0 ? void 0 : groupItem.subcategory) && h("span", { class: "subcategory" }, groupItem.subcategory)));
173
+ renderItem(item, index) {
174
+ var _a;
175
+ return (h("z-list-element", { id: `list-item-${this.htmlid}-${index}`, role: "presentation", htmlTabindex: -1, onKeyDown: (e) => this.onListItemKeyDown(e, item), onClick: () => this.emitSearchItemClick(item) }, h("div", { class: "list-item ellipsis", role: "option", tabindex: 0 }, !!(item === null || item === void 0 ? void 0 : item.icon) && (h("z-icon", { class: "item-icon", name: item.icon })), h("div", { class: "item-label body-3 mobile-body-4", title: item.label, innerHTML: this.renderItemLabel(item.label) }), !!(item === null || item === void 0 ? void 0 : item.tag) && h("z-tag", { icon: item.tag.icon }, !this.isMobile ? item.tag.text : "")), !!((_a = item.children) === null || _a === void 0 ? void 0 : _a.length) && (h("z-list", { class: "sub-list", role: "group", "aria-label": item.label || undefined }, item.children.map((child, index) => this.renderItem(child, index))))));
278
176
  }
279
- renderSearchHelper(hasDivider = true) {
280
- if (!this.autocomplete || this.preventSubmit || !this.searchString) {
281
- return null;
177
+ /**
178
+ * Renders the item grouped by category and subcategory. If `resultsCount` is set, it limits the number of rendered items.
179
+ */
180
+ renderItemGroups() {
181
+ var _a;
182
+ if (!((_a = this.resultsItemsList) === null || _a === void 0 ? void 0 : _a.length)) {
183
+ return;
282
184
  }
283
- return (h("z-list-element", { role: "option", dividerType: hasDivider ? ListDividerType.ELEMENT : undefined, id: `list-item-${this.htmlid}-search`, onKeyDown: (e) => this.handleArrowsNavigation(e) }, h("div", { tabindex: 0, onClick: () => this.emitSearchSubmit(), onKeyDown: (e) => handleEnterKeydSubmit(e, () => this.emitSearchSubmit()), class: "list-element" }, h("span", { class: "item item-search" }, h("z-icon", { class: "search-icon", name: "left-magnifying-glass" }), h("span", { class: "item-label", innerHTML: this.searchHelperLabel.replace("{searchString}", `<mark>${this.searchString}</mark>`) })))));
284
- }
285
- renderShowAllResults() {
286
- var _a, _b;
287
- if (!this.currResultsCount ||
288
- !this.searchString ||
289
- !((_a = this.resultsItemsList) === null || _a === void 0 ? void 0 : _a.length) ||
290
- this.currResultsCount >= ((_b = this.resultsItemsList) === null || _b === void 0 ? void 0 : _b.length)) {
291
- return null;
185
+ const groupedItems = Object.values(this.getGroupedItems());
186
+ const listGroups = [];
187
+ const hasResultsLimit = !!this.currResultsCount;
188
+ let renderedCount = 0;
189
+ for (const groupItem of groupedItems) {
190
+ const remaining = hasResultsLimit ? this.currResultsCount - renderedCount : groupItem.items.length;
191
+ if (remaining <= 0) {
192
+ break;
193
+ }
194
+ const visibleItems = groupItem.items.slice(0, remaining);
195
+ const listGroupsElements = visibleItems.map((item, subindex) => this.renderItem(item, subindex));
196
+ renderedCount += listGroupsElements.length;
197
+ if (!listGroupsElements.length) {
198
+ continue;
199
+ }
200
+ const ariaLabel = [groupItem.category, groupItem.subcategory].filter(Boolean).join(" ");
201
+ listGroups.push(h("z-list-group", { "aria-label": ariaLabel || undefined }, groupItem.category && (h("z-list-element", { class: "category-heading body-3 mobile-body-4", slot: "header-title", role: "presentation", htmlTabindex: -1 }, h("div", { class: "category" }, groupItem.category), groupItem.subcategory && h("div", { class: "subcategory" }, groupItem.subcategory))), listGroupsElements));
292
202
  }
293
- return (h("z-list-element", { role: "option", tabindex: 0, clickable: true, id: `list-item-${this.htmlid}-show-all`, onClickItem: () => (this.currResultsCount = 0), color: "color-primary01" }, h("div", { class: "item-show-all" }, "Vedi tutti i risultati")));
203
+ return listGroups;
294
204
  }
295
205
  render() {
296
- return (h(Host, { key: '6ccdb51d39d0e211de9b79cbbed90f4597b2c25b', onFocus: () => (this.showResults = true), onClick: (e) => this.handleOutsideClick(e), class: { "has-submit": this.showSearchButton, "has-results": this.autocomplete } }, h("div", { key: '90e51c50fe4b06429aad4d222cb26e5789183c30', class: "input-container" }, this.renderInput(), this.renderResults()), this.renderButton()));
206
+ var _a, _b, _c, _d, _e;
207
+ return (h(Host, { key: 'ef0ac81207a219b31d80fd2091070deea1f4314a', onFocus: () => (this.showResults = true), onClick: (e) => this.handleOutsideClick(e), class: { "has-submit": !!this.showSearchButton, "has-results": !!this.autocomplete } }, h("div", { key: 'cb73f19a10f7c26ef0f627916fb8d7dd6a28409c', class: "input-container" }, h("z-input", { key: '11c8ec74157a8a6a278d1e7928b6c819167ff3f4', ref: (el) => (this.inputRef = el), htmlid: `input-${this.htmlid}`, message: false, placeholder: this.placeholder, onStopTyping: (e) => this.handleStopTyping(e), onKeyUp: (e) => {
208
+ handleEnterKeydSubmit(e, () => this.handleSubmit());
209
+ this.handleArrowsNavigation(e);
210
+ }, onFocus: () => (this.showResults = true), value: this.searchString || ((_a = this.selectedItem) === null || _a === void 0 ? void 0 : _a.label), size: this.size, label: this.label, "aria-label": this.htmlAriaLabel || this.placeholder || undefined }), !!(this.showResults &&
211
+ this.autocomplete &&
212
+ this.searchString &&
213
+ this.searchString.length >= this.autocompleteMinChars &&
214
+ this.resultsItemsList) && (h("div", { key: '072a63a8d3f91b4325c53c0ec56fa90f925199f2', class: "results z-scrollbar" }, this.preventSubmit && !((_b = this.resultsItemsList) === null || _b === void 0 ? void 0 : _b.length) ? (h("div", { class: "item-no-results body-3 mobile-body-4" }, "Non abbiamo trovato risultati per ", h("b", null, this.searchString), h("br", null), h("br", null), "Cosa puoi fare?", h("ul", null, h("li", null, "Verificare di aver scritto bene"), h("li", null, "Provare a cercare un'altra parola"), h("li", null, "Provare a cercare qualcosa di pi\u00F9 generico")))) : (h("z-list", { role: "listbox", id: `list-${this.htmlid}`, "aria-label": this.htmlAriaLabel || this.label || undefined }, this.autocomplete && !this.preventSubmit && !!this.searchString && (h("z-list-element", { role: "presentation", htmlTabindex: -1, id: `list-item-${this.htmlid}-search`, onKeyDown: (e) => this.onSearchHelperKeyDown(e), onClick: () => this.emitSearchSubmit() }, h("div", { class: "list-item item-search", role: "option", tabindex: 0 }, h("z-icon", { class: "search-icon", name: "left-magnifying-glass" }), h("div", { class: "item-label body-3 mobile-body-4", innerHTML: (_c = this.searchHelperLabel) === null || _c === void 0 ? void 0 : _c.replace("{searchString}", `<mark>${this.searchString}</mark>`) })))), this.renderItemGroups(), !!(this.searchString &&
215
+ ((_d = this.resultsItemsList) === null || _d === void 0 ? void 0 : _d.length) &&
216
+ this.currResultsCount &&
217
+ this.currResultsCount < ((_e = this.resultsItemsList) === null || _e === void 0 ? void 0 : _e.length)) && (h("z-list-element", { role: "presentation", htmlTabindex: -1, id: `list-item-${this.htmlid}-show-all` }, h("div", { role: "option", class: "item-show-all body-3 mobile-body-4", tabindex: 0, onClick: () => (this.currResultsCount = undefined) }, "Vedi tutti i risultati")))))))), this.showSearchButton && (h("z-button", { key: 'c839b4c5fa6d46f28f9ab83e0a02b1bc3d9594bf', icon: this.searchButtonIconOnly ? "search" : undefined, "aria-label": this.searchButtonIconOnly ? "CERCA" : undefined, disabled: !!this.preventSubmit, variant: this.variant, size: this.size, onClick: () => this.handleSubmit() }, this.searchButtonIconOnly ? "" : "CERCA"))));
297
218
  }
298
219
  static get is() { return "z-searchbar"; }
299
220
  static get encapsulation() { return "shadow"; }
300
221
  static get originalStyleUrls() {
301
222
  return {
302
- "$": ["styles.css", "../css-components/z-label/styles.css"]
223
+ "$": ["styles.css", "../css-components/z-label/styles.css", "../css-components/z-scrollbar/styles.css", "../../tokens/typography.css"]
303
224
  };
304
225
  }
305
226
  static get styleUrls() {
306
227
  return {
307
- "$": ["styles.css", "../css-components/z-label/styles.css"]
228
+ "$": ["styles.css", "../css-components/z-label/styles.css", "../css-components/z-scrollbar/styles.css", "../../tokens/typography.css"]
308
229
  };
309
230
  }
310
231
  static get properties() {
@@ -321,7 +242,7 @@ export class ZSearchbar {
321
242
  "optional": false,
322
243
  "docs": {
323
244
  "tags": [],
324
- "text": "the id of the searchbar element"
245
+ "text": "The id of the searchbar element"
325
246
  },
326
247
  "getter": false,
327
248
  "setter": false,
@@ -361,7 +282,7 @@ export class ZSearchbar {
361
282
  "optional": true,
362
283
  "docs": {
363
284
  "tags": [],
364
- "text": "the input label"
285
+ "text": "The input label"
365
286
  },
366
287
  "getter": false,
367
288
  "setter": false,
@@ -380,7 +301,7 @@ export class ZSearchbar {
380
301
  "optional": true,
381
302
  "docs": {
382
303
  "tags": [],
383
- "text": "the input aria-label"
304
+ "text": "The input aria-label"
384
305
  },
385
306
  "getter": false,
386
307
  "setter": false,
@@ -477,7 +398,7 @@ export class ZSearchbar {
477
398
  "optional": true,
478
399
  "docs": {
479
400
  "tags": [],
480
- "text": "Number of results shown - default all"
401
+ "text": "Number of results shown. Default: all"
481
402
  },
482
403
  "getter": false,
483
404
  "setter": false,
@@ -582,7 +503,7 @@ export class ZSearchbar {
582
503
  "optional": true,
583
504
  "docs": {
584
505
  "tags": [],
585
- "text": "Set button icon without label"
506
+ "text": "Hide the label of the submit button, showing only the icon"
586
507
  },
587
508
  "getter": false,
588
509
  "setter": false,
@@ -609,7 +530,7 @@ export class ZSearchbar {
609
530
  "optional": true,
610
531
  "docs": {
611
532
  "tags": [],
612
- "text": "Available sizes: `big`, `small` and `x-small`. Defaults to `big`."
533
+ "text": "Size of the `z-input` and submit `z-button`"
613
534
  },
614
535
  "getter": false,
615
536
  "setter": false,
@@ -636,7 +557,7 @@ export class ZSearchbar {
636
557
  "optional": true,
637
558
  "docs": {
638
559
  "tags": [],
639
- "text": "Graphical variant: `primary`, `secondary`, `tertiary`. Defaults to `primary`."
560
+ "text": "Submit `z-button` variant"
640
561
  },
641
562
  "getter": false,
642
563
  "setter": false,
@@ -710,7 +631,7 @@ export class ZSearchbar {
710
631
  }
711
632
  }];
712
633
  }
713
- static get elementRef() { return "element"; }
634
+ static get elementRef() { return "host"; }
714
635
  static get watchers() {
715
636
  return [{
716
637
  "propName": "resultsItems",
@@ -724,9 +645,6 @@ export class ZSearchbar {
724
645
  }, {
725
646
  "propName": "searchString",
726
647
  "methodName": "watchSearchString"
727
- }, {
728
- "propName": "showResults",
729
- "methodName": "watchShowResults"
730
648
  }];
731
649
  }
732
650
  static get listeners() {
@@ -24,29 +24,16 @@ const StoryMeta = {
24
24
  "searchButtonIconOnly": false,
25
25
  "autocomplete": false,
26
26
  "autocompleteMinChars": 3,
27
- "resultsCount": null,
27
+ "resultsCount": undefined,
28
28
  "searchHelperLabel": "Cerca {searchString}",
29
- "resultsItems": [
30
- {
31
- label: "first item",
32
- },
33
- {
34
- label: "second item",
35
- },
36
- {
37
- label: "third item",
38
- },
39
- {
40
- label: "fourth item",
41
- },
42
- ],
29
+ "resultsItems": [{ label: "first item" }, { label: "second item" }, { label: "third item" }, { label: "fourth item" }],
43
30
  "sortResultsItems": false,
44
31
  "htmlid": "myId",
45
32
  "placeholder": "my placeholder",
46
33
  "value": "",
47
34
  "label": "",
48
35
  "htmlAriaLabel": "",
49
- "--z-searchbar-results-height": "",
36
+ "--z-searchbar-results-height": "540px",
50
37
  "--z-searchbar-tag-text-color": "var(--color-primary03)",
51
38
  "--z-searchbar-tag-bg": "var(--color-hover-primary)",
52
39
  "size": ControlSize.BIG,