@roadtrip/components 3.17.0 → 3.19.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (393) hide show
  1. package/dist/cjs/index-fb57f684.js.map +1 -1
  2. package/dist/cjs/loader.cjs.js +1 -1
  3. package/dist/cjs/road-accordion.cjs.entry.js +1 -1
  4. package/dist/cjs/road-accordion.cjs.entry.js.map +1 -1
  5. package/dist/cjs/road-autocomplete.cjs.entry.js +1 -1
  6. package/dist/cjs/road-autocomplete.cjs.entry.js.map +1 -1
  7. package/dist/cjs/road-badge_14.cjs.entry.js +40 -8
  8. package/dist/cjs/road-badge_14.cjs.entry.js.map +1 -1
  9. package/dist/cjs/road-banner.cjs.entry.js +1 -1
  10. package/dist/cjs/road-banner.cjs.entry.js.map +1 -1
  11. package/dist/cjs/road-button-floating.cjs.entry.js +1 -1
  12. package/dist/cjs/road-button-floating.cjs.entry.js.map +1 -1
  13. package/dist/cjs/road-card.cjs.entry.js +1 -1
  14. package/dist/cjs/road-card.cjs.entry.js.map +1 -1
  15. package/dist/cjs/road-carousel.cjs.entry.js +30 -118
  16. package/dist/cjs/road-carousel.cjs.entry.js.map +1 -1
  17. package/dist/cjs/road-chip.cjs.entry.js +2 -2
  18. package/dist/cjs/road-chip.cjs.entry.js.map +1 -1
  19. package/dist/cjs/road-collapse.cjs.entry.js +1 -1
  20. package/dist/cjs/road-collapse.cjs.entry.js.map +1 -1
  21. package/dist/cjs/road-dialog.cjs.entry.js +2 -2
  22. package/dist/cjs/road-dialog.cjs.entry.js.map +1 -1
  23. package/dist/cjs/road-dropdown.cjs.entry.js +4 -4
  24. package/dist/cjs/road-dropdown.cjs.entry.js.map +1 -1
  25. package/dist/cjs/road-global-navigation.cjs.entry.js +1 -1
  26. package/dist/cjs/road-global-navigation.cjs.entry.js.map +1 -1
  27. package/dist/cjs/road-illustration.cjs.entry.js +1 -1
  28. package/dist/cjs/road-illustration.cjs.entry.js.map +1 -1
  29. package/dist/cjs/road-modal.cjs.entry.js +2 -2
  30. package/dist/cjs/road-modal.cjs.entry.js.map +1 -1
  31. package/dist/cjs/road-navbar-item.cjs.entry.js +1 -1
  32. package/dist/cjs/road-navbar-item.cjs.entry.js.map +1 -1
  33. package/dist/cjs/road-navbar.cjs.entry.js +1 -1
  34. package/dist/cjs/road-navbar.cjs.entry.js.map +1 -1
  35. package/dist/cjs/road-phone-number-input.cjs.entry.js +41 -5
  36. package/dist/cjs/road-phone-number-input.cjs.entry.js.map +1 -1
  37. package/dist/cjs/road-plate-number.cjs.entry.js +2 -2
  38. package/dist/cjs/road-plate-number.cjs.entry.js.map +1 -1
  39. package/dist/cjs/road-profil-dropdown.cjs.entry.js +10 -1
  40. package/dist/cjs/road-profil-dropdown.cjs.entry.js.map +1 -1
  41. package/dist/cjs/road-progress-indicator-vertical.cjs.entry.js +2 -2
  42. package/dist/cjs/road-progress-indicator-vertical.cjs.entry.js.map +1 -1
  43. package/dist/cjs/road-progress-tracker.cjs.entry.js +2 -2
  44. package/dist/cjs/road-progress-tracker.cjs.entry.js.map +1 -1
  45. package/dist/cjs/road-progress.cjs.entry.js +1 -1
  46. package/dist/cjs/road-progress.cjs.entry.js.map +1 -1
  47. package/dist/cjs/road-range.cjs.entry.js +26 -2
  48. package/dist/cjs/road-range.cjs.entry.js.map +1 -1
  49. package/dist/cjs/road-segmented-button.cjs.entry.js +1 -1
  50. package/dist/cjs/road-segmented-button.cjs.entry.js.map +1 -1
  51. package/dist/cjs/road-select-filter.cjs.entry.js +34 -4
  52. package/dist/cjs/road-select-filter.cjs.entry.js.map +1 -1
  53. package/dist/cjs/road-select.cjs.entry.js +1 -1
  54. package/dist/cjs/road-select.cjs.entry.js.map +1 -1
  55. package/dist/cjs/road-textarea.cjs.entry.js +1 -1
  56. package/dist/cjs/road-textarea.cjs.entry.js.map +1 -1
  57. package/dist/cjs/road-tooltip.cjs.entry.js +1 -1
  58. package/dist/cjs/road-tooltip.cjs.entry.js.map +1 -1
  59. package/dist/cjs/roadtrip.cjs.js +1 -1
  60. package/dist/collection/components/accordion/accordion.css +4 -0
  61. package/dist/collection/components/accordion/accordion.stories.js +1 -1
  62. package/dist/collection/components/alert/alert.stories.js +1 -1
  63. package/dist/collection/components/autocomplete/autocomplete.js +1 -1
  64. package/dist/collection/components/autocomplete/autocomplete.js.map +1 -1
  65. package/dist/collection/components/autocomplete/autocomplete.stories.js +2 -2
  66. package/dist/collection/components/avatar/avatar.stories.js +1 -1
  67. package/dist/collection/components/badge/badge.stories.js +2 -2
  68. package/dist/collection/components/banner/banner.js +1 -1
  69. package/dist/collection/components/banner/banner.js.map +1 -1
  70. package/dist/collection/components/button/button.stories.js +6 -6
  71. package/dist/collection/components/button-floating/button-floating.css +0 -4
  72. package/dist/collection/components/button-floating/button-floating.stories.js +2 -2
  73. package/dist/collection/components/card/card.css +4 -0
  74. package/dist/collection/components/card/card.stories.js +4 -4
  75. package/dist/collection/components/carousel/carousel.css +4 -1
  76. package/dist/collection/components/carousel/carousel.js +93 -250
  77. package/dist/collection/components/carousel/carousel.js.map +1 -1
  78. package/dist/collection/components/chip/chip.css +2 -2
  79. package/dist/collection/components/chip/chip.js +1 -1
  80. package/dist/collection/components/chip/chip.js.map +1 -1
  81. package/dist/collection/components/chip/chip.stories.js +26 -1
  82. package/dist/collection/components/collapse/collapse.css +4 -0
  83. package/dist/collection/components/collapse/collapse.stories.js +8 -8
  84. package/dist/collection/components/counter/counter.css +5 -0
  85. package/dist/collection/components/counter/counter.js +19 -1
  86. package/dist/collection/components/counter/counter.js.map +1 -1
  87. package/dist/collection/components/dialog/dialog.js +2 -2
  88. package/dist/collection/components/dialog/dialog.js.map +1 -1
  89. package/dist/collection/components/drawer/drawer.js +1 -1
  90. package/dist/collection/components/drawer/drawer.js.map +1 -1
  91. package/dist/collection/components/drawer/drawer.stories.js +2 -2
  92. package/dist/collection/components/dropdown/dropdown.css +9 -4
  93. package/dist/collection/components/dropdown/dropdown.js +3 -3
  94. package/dist/collection/components/dropdown/dropdown.js.map +1 -1
  95. package/dist/collection/components/dropdown/dropdown.stories.js +4 -4
  96. package/dist/collection/components/global-navigation/global-navigation.js +1 -1
  97. package/dist/collection/components/global-navigation/global-navigation.js.map +1 -1
  98. package/dist/collection/components/global-navigation/global-navigation.stories.js +39 -39
  99. package/dist/collection/components/icon/icon.stories.js +44 -43
  100. package/dist/collection/components/icon/svg/fuel-air-supply-color.svg +1 -1
  101. package/dist/collection/components/icon/svg/fuel-air-supply-outline.svg +1 -1
  102. package/dist/collection/components/icon/svg/funding-best-price-color.svg +1 -1
  103. package/dist/collection/components/icon/svg/funding-best-price-outline.svg +1 -1
  104. package/dist/collection/components/icon/svg/helmet-cross-color.svg +1 -1
  105. package/dist/collection/components/icon/svg/helmet-cross-outline.svg +1 -1
  106. package/dist/collection/components/icon/svg/ice-color.svg +1 -1
  107. package/dist/collection/components/icon/svg/ice-outline.svg +1 -1
  108. package/dist/collection/components/icon/svg/ice-solid-color.svg +1 -1
  109. package/dist/collection/components/icon/svg/ice-solid.svg +1 -1
  110. package/dist/collection/components/icon/svg/light-beam-signal-color.svg +1 -1
  111. package/dist/collection/components/icon/svg/light-beam-signal-outline.svg +1 -1
  112. package/dist/collection/components/icon/svg/social-facebook-badge.svg +1 -1
  113. package/dist/collection/components/icon/svg/social-google-badge.svg +1 -1
  114. package/dist/collection/components/icon/svg/social-instagram-badge.svg +1 -1
  115. package/dist/collection/components/icon/svg/social-instagramWithinCircle.svg +1 -1
  116. package/dist/collection/components/icon/svg/social-linkedin-badge.svg +1 -1
  117. package/dist/collection/components/icon/svg/social-paypal-badge.svg +1 -1
  118. package/dist/collection/components/icon/svg/social-tiktok-badge.svg +1 -1
  119. package/dist/collection/components/icon/svg/social-twitter-badge.svg +1 -1
  120. package/dist/collection/components/icon/svg/social-whatsapp-badge.svg +1 -1
  121. package/dist/collection/components/icon/svg/social-youtube-badge.svg +1 -1
  122. package/dist/collection/components/icon/svg/tire-ice-color.svg +1 -1
  123. package/dist/collection/components/icon/svg/tire-ice-outline.svg +1 -1
  124. package/dist/collection/components/icon/svg/tire-ice-solid.svg +1 -1
  125. package/dist/collection/components/icon/svg/vehicle-car-unselected-color.svg +1 -1
  126. package/dist/collection/components/icon/svg/vehicle-car-unselected-outline.svg +1 -1
  127. package/dist/collection/components/icon/svg/wrench-twin-color.svg +1 -1
  128. package/dist/collection/components/icon/svg/wrench-twin-outline.svg +1 -1
  129. package/dist/collection/components/icon/svg/wrench-twin-solid.svg +1 -1
  130. package/dist/collection/components/illustration/illustration.js +1 -1
  131. package/dist/collection/components/illustration/illustration.js.map +1 -1
  132. package/dist/collection/components/input/input.css +8 -2
  133. package/dist/collection/components/input/input.js +16 -2
  134. package/dist/collection/components/input/input.js.map +1 -1
  135. package/dist/collection/components/input-group/input-group.js +1 -1
  136. package/dist/collection/components/input-group/input-group.js.map +1 -1
  137. package/dist/collection/components/input-group/input-group.stories.js +4 -4
  138. package/dist/collection/components/item/item.stories.js +9 -9
  139. package/dist/collection/components/list/list.stories.js +8 -8
  140. package/dist/collection/components/modal/modal.css +2 -2
  141. package/dist/collection/components/modal/modal.js +1 -1
  142. package/dist/collection/components/modal/modal.js.map +1 -1
  143. package/dist/collection/components/navbar/navbar.js +1 -1
  144. package/dist/collection/components/navbar/navbar.js.map +1 -1
  145. package/dist/collection/components/navbar/navbar.stories.js +84 -63
  146. package/dist/collection/components/navbar-item/navbar-item.js +1 -1
  147. package/dist/collection/components/navbar-item/navbar-item.js.map +1 -1
  148. package/dist/collection/components/patterns/link.stories.js +2 -2
  149. package/dist/collection/components/phone-number-input/phone-number-input.css +0 -1
  150. package/dist/collection/components/phone-number-input/phone-number-input.js +40 -4
  151. package/dist/collection/components/phone-number-input/phone-number-input.js.map +1 -1
  152. package/dist/collection/components/plate-number/plate-number.css +1 -1
  153. package/dist/collection/components/plate-number/plate-number.js +1 -1
  154. package/dist/collection/components/plate-number/plate-number.js.map +1 -1
  155. package/dist/collection/components/profil-dropdown/profil-dropdown.css +8 -0
  156. package/dist/collection/components/profil-dropdown/profil-dropdown.js +18 -0
  157. package/dist/collection/components/profil-dropdown/profil-dropdown.js.map +1 -1
  158. package/dist/collection/components/profil-dropdown/profil-dropdown.stories.js +4 -4
  159. package/dist/collection/components/progress/progress.js +1 -1
  160. package/dist/collection/components/progress/progress.js.map +1 -1
  161. package/dist/collection/components/progress-indicator-vertical/progress-indicator-vertical.css +5 -0
  162. package/dist/collection/components/progress-indicator-vertical/progress-indicator-vertical.js +1 -1
  163. package/dist/collection/components/progress-indicator-vertical/progress-indicator-vertical.js.map +1 -1
  164. package/dist/collection/components/progress-indicator-vertical/progress-indicator-vertical.stories.js +20 -20
  165. package/dist/collection/components/progress-tracker/progress-tracker.css +4 -0
  166. package/dist/collection/components/progress-tracker/progress-tracker.js +1 -1
  167. package/dist/collection/components/progress-tracker/progress-tracker.js.map +1 -1
  168. package/dist/collection/components/range/range.css +17 -2
  169. package/dist/collection/components/range/range.js +41 -2
  170. package/dist/collection/components/range/range.js.map +1 -1
  171. package/dist/collection/components/segmented-button/segmented-button.js +1 -1
  172. package/dist/collection/components/segmented-button/segmented-button.js.map +1 -1
  173. package/dist/collection/components/select/select.css +1 -1
  174. package/dist/collection/components/select-filter/select-filter.css +5 -0
  175. package/dist/collection/components/select-filter/select-filter.js +43 -9
  176. package/dist/collection/components/select-filter/select-filter.js.map +1 -1
  177. package/dist/collection/components/select-filter/select-filter.stories.js +8 -8
  178. package/dist/collection/components/tabs/tabs.stories.js +5 -5
  179. package/dist/collection/components/textarea/textarea.css +2 -2
  180. package/dist/collection/components/toolbar/toolbar.css +0 -2
  181. package/dist/collection/components/toolbar/toolbar.stories.js +8 -8
  182. package/dist/collection/components/tooltip/tooltip.js +1 -1
  183. package/dist/collection/components/tooltip/tooltip.js.map +1 -1
  184. package/dist/collection/components/tooltip/tooltip.stories.js +3 -3
  185. package/dist/esm/{index-891decf5.js → index-7a0158a4.js} +2 -2
  186. package/dist/esm/index-7a0158a4.js.map +1 -0
  187. package/dist/esm/loader.js +1 -1
  188. package/dist/esm/road-accordion.entry.js +2 -2
  189. package/dist/esm/road-accordion.entry.js.map +1 -1
  190. package/dist/esm/road-autocomplete.entry.js +1 -1
  191. package/dist/esm/road-autocomplete.entry.js.map +1 -1
  192. package/dist/esm/road-badge_14.entry.js +41 -9
  193. package/dist/esm/road-badge_14.entry.js.map +1 -1
  194. package/dist/esm/road-banner.entry.js +2 -2
  195. package/dist/esm/road-banner.entry.js.map +1 -1
  196. package/dist/esm/road-button-floating.entry.js +1 -1
  197. package/dist/esm/road-button-floating.entry.js.map +1 -1
  198. package/dist/esm/road-card.entry.js +1 -1
  199. package/dist/esm/road-card.entry.js.map +1 -1
  200. package/dist/esm/road-carousel.entry.js +31 -119
  201. package/dist/esm/road-carousel.entry.js.map +1 -1
  202. package/dist/esm/road-checkbox.entry.js +1 -1
  203. package/dist/esm/road-chip.entry.js +3 -3
  204. package/dist/esm/road-chip.entry.js.map +1 -1
  205. package/dist/esm/road-collapse.entry.js +1 -1
  206. package/dist/esm/road-collapse.entry.js.map +1 -1
  207. package/dist/esm/road-dialog.entry.js +3 -3
  208. package/dist/esm/road-dialog.entry.js.map +1 -1
  209. package/dist/esm/road-dropdown.entry.js +4 -4
  210. package/dist/esm/road-dropdown.entry.js.map +1 -1
  211. package/dist/esm/road-global-navigation.entry.js +1 -1
  212. package/dist/esm/road-global-navigation.entry.js.map +1 -1
  213. package/dist/esm/road-illustration.entry.js +1 -1
  214. package/dist/esm/road-illustration.entry.js.map +1 -1
  215. package/dist/esm/road-modal.entry.js +3 -3
  216. package/dist/esm/road-modal.entry.js.map +1 -1
  217. package/dist/esm/road-navbar-item.entry.js +1 -1
  218. package/dist/esm/road-navbar-item.entry.js.map +1 -1
  219. package/dist/esm/road-navbar.entry.js +1 -1
  220. package/dist/esm/road-navbar.entry.js.map +1 -1
  221. package/dist/esm/road-phone-number-input.entry.js +41 -5
  222. package/dist/esm/road-phone-number-input.entry.js.map +1 -1
  223. package/dist/esm/road-plate-number.entry.js +3 -3
  224. package/dist/esm/road-plate-number.entry.js.map +1 -1
  225. package/dist/esm/road-profil-dropdown.entry.js +11 -2
  226. package/dist/esm/road-profil-dropdown.entry.js.map +1 -1
  227. package/dist/esm/road-progress-indicator-vertical.entry.js +2 -2
  228. package/dist/esm/road-progress-indicator-vertical.entry.js.map +1 -1
  229. package/dist/esm/road-progress-tracker.entry.js +2 -2
  230. package/dist/esm/road-progress-tracker.entry.js.map +1 -1
  231. package/dist/esm/road-progress.entry.js +1 -1
  232. package/dist/esm/road-progress.entry.js.map +1 -1
  233. package/dist/esm/road-range.entry.js +28 -4
  234. package/dist/esm/road-range.entry.js.map +1 -1
  235. package/dist/esm/road-rating.entry.js +1 -1
  236. package/dist/esm/road-segmented-button.entry.js +1 -1
  237. package/dist/esm/road-segmented-button.entry.js.map +1 -1
  238. package/dist/esm/road-select-filter.entry.js +34 -4
  239. package/dist/esm/road-select-filter.entry.js.map +1 -1
  240. package/dist/esm/road-select.entry.js +1 -1
  241. package/dist/esm/road-select.entry.js.map +1 -1
  242. package/dist/esm/road-textarea.entry.js +1 -1
  243. package/dist/esm/road-textarea.entry.js.map +1 -1
  244. package/dist/esm/road-toast.entry.js +1 -1
  245. package/dist/esm/road-tooltip.entry.js +1 -1
  246. package/dist/esm/road-tooltip.entry.js.map +1 -1
  247. package/dist/esm/roadtrip.js +1 -1
  248. package/dist/html.html-data.json +3 -3
  249. package/dist/icons/index.js +30 -30
  250. package/dist/roadtrip/p-054acf61.entry.js +2 -0
  251. package/dist/roadtrip/p-054acf61.entry.js.map +1 -0
  252. package/dist/roadtrip/{p-ea28a425.entry.js → p-08b0be1b.entry.js} +2 -2
  253. package/dist/roadtrip/p-08b0be1b.entry.js.map +1 -0
  254. package/dist/roadtrip/{p-1a761fc0.entry.js → p-0fd454dc.entry.js} +2 -2
  255. package/dist/roadtrip/p-0fd454dc.entry.js.map +1 -0
  256. package/dist/roadtrip/{p-60e25858.entry.js → p-14ecc91e.entry.js} +2 -2
  257. package/dist/roadtrip/{p-60e25858.entry.js.map → p-14ecc91e.entry.js.map} +1 -1
  258. package/dist/roadtrip/{p-82919e58.entry.js → p-16c934bc.entry.js} +2 -2
  259. package/dist/roadtrip/p-17ae87b0.entry.js +2 -0
  260. package/dist/roadtrip/p-17ae87b0.entry.js.map +1 -0
  261. package/dist/roadtrip/{p-6e3e0b40.entry.js → p-18967429.entry.js} +2 -2
  262. package/dist/roadtrip/{p-6e3e0b40.entry.js.map → p-18967429.entry.js.map} +1 -1
  263. package/dist/roadtrip/{p-a73ef7de.entry.js → p-233eb25c.entry.js} +2 -2
  264. package/dist/roadtrip/p-233eb25c.entry.js.map +1 -0
  265. package/dist/roadtrip/p-27d2770a.entry.js +2 -0
  266. package/dist/roadtrip/p-27d2770a.entry.js.map +1 -0
  267. package/dist/roadtrip/{p-4f47f4f7.entry.js → p-31cf9b61.entry.js} +2 -2
  268. package/dist/roadtrip/p-31cf9b61.entry.js.map +1 -0
  269. package/dist/roadtrip/{p-dcb280e3.entry.js → p-3bce3bdc.entry.js} +2 -2
  270. package/dist/roadtrip/p-3bce3bdc.entry.js.map +1 -0
  271. package/dist/roadtrip/p-4a2f2612.entry.js +2 -0
  272. package/dist/roadtrip/p-4a2f2612.entry.js.map +1 -0
  273. package/dist/roadtrip/p-5203acea.entry.js +2 -0
  274. package/dist/roadtrip/p-5203acea.entry.js.map +1 -0
  275. package/dist/roadtrip/p-6ad5091d.entry.js +2 -0
  276. package/dist/roadtrip/p-6ad5091d.entry.js.map +1 -0
  277. package/dist/roadtrip/{p-2c132382.entry.js → p-72b3b34a.entry.js} +2 -2
  278. package/dist/roadtrip/p-72b3b34a.entry.js.map +1 -0
  279. package/dist/roadtrip/p-7a14e5b7.entry.js +2 -0
  280. package/dist/roadtrip/p-7a14e5b7.entry.js.map +1 -0
  281. package/dist/roadtrip/{p-c3c92152.entry.js → p-7f1d9286.entry.js} +2 -2
  282. package/dist/roadtrip/p-7f1d9286.entry.js.map +1 -0
  283. package/dist/roadtrip/p-9a929988.entry.js +2 -0
  284. package/dist/roadtrip/p-9a929988.entry.js.map +1 -0
  285. package/dist/roadtrip/{p-336aa5f6.entry.js → p-9ff79904.entry.js} +2 -2
  286. package/dist/roadtrip/{p-336aa5f6.entry.js.map → p-9ff79904.entry.js.map} +1 -1
  287. package/dist/roadtrip/p-a5eee655.entry.js +2 -0
  288. package/dist/roadtrip/{p-40daa53b.entry.js.map → p-a5eee655.entry.js.map} +1 -1
  289. package/dist/roadtrip/{p-73fe2357.js → p-ac7a8bca.js} +2 -2
  290. package/dist/roadtrip/p-ac7a8bca.js.map +1 -0
  291. package/dist/roadtrip/{p-6177bb46.entry.js → p-b510e552.entry.js} +2 -2
  292. package/dist/roadtrip/{p-6177bb46.entry.js.map → p-b510e552.entry.js.map} +1 -1
  293. package/dist/roadtrip/{p-46cccafc.entry.js → p-c096723c.entry.js} +2 -2
  294. package/dist/roadtrip/{p-46cccafc.entry.js.map → p-c096723c.entry.js.map} +1 -1
  295. package/dist/roadtrip/p-c7866ae4.entry.js +2 -0
  296. package/dist/roadtrip/p-c7866ae4.entry.js.map +1 -0
  297. package/dist/roadtrip/p-cdefa79c.entry.js +2 -0
  298. package/dist/roadtrip/p-cdefa79c.entry.js.map +1 -0
  299. package/dist/roadtrip/{p-cbc00bfb.entry.js → p-cfc0a3a7.entry.js} +2 -2
  300. package/dist/roadtrip/p-dcbaee2f.entry.js +2 -0
  301. package/dist/roadtrip/p-dcbaee2f.entry.js.map +1 -0
  302. package/dist/roadtrip/{p-7048f786.entry.js → p-dcbb0d20.entry.js} +2 -2
  303. package/dist/roadtrip/p-dcbb0d20.entry.js.map +1 -0
  304. package/dist/roadtrip/{p-414a2791.entry.js → p-e8c9c816.entry.js} +2 -2
  305. package/dist/roadtrip/{p-f5cce766.entry.js → p-ebd19369.entry.js} +2 -2
  306. package/dist/roadtrip/{p-f5cce766.entry.js.map → p-ebd19369.entry.js.map} +1 -1
  307. package/dist/roadtrip/p-f7b4f1fa.entry.js +2 -0
  308. package/dist/roadtrip/p-f7b4f1fa.entry.js.map +1 -0
  309. package/dist/roadtrip/p-f90af0e1.entry.js +2 -0
  310. package/dist/roadtrip/p-f90af0e1.entry.js.map +1 -0
  311. package/dist/roadtrip/roadtrip.css +1 -1
  312. package/dist/roadtrip/roadtrip.esm.js +1 -1
  313. package/dist/roadtrip/roadtrip.esm.js.map +1 -1
  314. package/dist/roadtrip/svg/fuel-air-supply-color.svg +1 -1
  315. package/dist/roadtrip/svg/fuel-air-supply-outline.svg +1 -1
  316. package/dist/roadtrip/svg/funding-best-price-color.svg +1 -1
  317. package/dist/roadtrip/svg/funding-best-price-outline.svg +1 -1
  318. package/dist/roadtrip/svg/helmet-cross-color.svg +1 -1
  319. package/dist/roadtrip/svg/helmet-cross-outline.svg +1 -1
  320. package/dist/roadtrip/svg/ice-color.svg +1 -1
  321. package/dist/roadtrip/svg/ice-outline.svg +1 -1
  322. package/dist/roadtrip/svg/ice-solid-color.svg +1 -1
  323. package/dist/roadtrip/svg/ice-solid.svg +1 -1
  324. package/dist/roadtrip/svg/light-beam-signal-color.svg +1 -1
  325. package/dist/roadtrip/svg/light-beam-signal-outline.svg +1 -1
  326. package/dist/roadtrip/svg/social-facebook-badge.svg +1 -1
  327. package/dist/roadtrip/svg/social-google-badge.svg +1 -1
  328. package/dist/roadtrip/svg/social-instagram-badge.svg +1 -1
  329. package/dist/roadtrip/svg/social-instagramWithinCircle.svg +1 -1
  330. package/dist/roadtrip/svg/social-linkedin-badge.svg +1 -1
  331. package/dist/roadtrip/svg/social-paypal-badge.svg +1 -1
  332. package/dist/roadtrip/svg/social-tiktok-badge.svg +1 -1
  333. package/dist/roadtrip/svg/social-twitter-badge.svg +1 -1
  334. package/dist/roadtrip/svg/social-whatsapp-badge.svg +1 -1
  335. package/dist/roadtrip/svg/social-youtube-badge.svg +1 -1
  336. package/dist/roadtrip/svg/tire-ice-color.svg +1 -1
  337. package/dist/roadtrip/svg/tire-ice-outline.svg +1 -1
  338. package/dist/roadtrip/svg/tire-ice-solid.svg +1 -1
  339. package/dist/roadtrip/svg/vehicle-car-unselected-color.svg +1 -1
  340. package/dist/roadtrip/svg/vehicle-car-unselected-outline.svg +1 -1
  341. package/dist/roadtrip/svg/wrench-twin-color.svg +1 -1
  342. package/dist/roadtrip/svg/wrench-twin-outline.svg +1 -1
  343. package/dist/roadtrip/svg/wrench-twin-solid.svg +1 -1
  344. package/dist/types/components/carousel/carousel.d.ts +1 -131
  345. package/dist/types/components/counter/counter.d.ts +1 -0
  346. package/dist/types/components/phone-number-input/phone-number-input.d.ts +1 -0
  347. package/dist/types/components/profil-dropdown/profil-dropdown.d.ts +2 -0
  348. package/dist/types/components/range/range.d.ts +3 -0
  349. package/dist/types/components/select-filter/select-filter.d.ts +16 -4
  350. package/dist/types/components.d.ts +4 -128
  351. package/hydrate/index.js +217 -176
  352. package/icons/index.js +30 -30
  353. package/package.json +1 -1
  354. package/dist/esm/index-891decf5.js.map +0 -1
  355. package/dist/roadtrip/p-1a761fc0.entry.js.map +0 -1
  356. package/dist/roadtrip/p-2b5974fc.entry.js +0 -2
  357. package/dist/roadtrip/p-2b5974fc.entry.js.map +0 -1
  358. package/dist/roadtrip/p-2c132382.entry.js.map +0 -1
  359. package/dist/roadtrip/p-2c8a6854.entry.js +0 -2
  360. package/dist/roadtrip/p-2c8a6854.entry.js.map +0 -1
  361. package/dist/roadtrip/p-2e25c08d.entry.js +0 -2
  362. package/dist/roadtrip/p-2e25c08d.entry.js.map +0 -1
  363. package/dist/roadtrip/p-33002e9d.entry.js +0 -2
  364. package/dist/roadtrip/p-33002e9d.entry.js.map +0 -1
  365. package/dist/roadtrip/p-372fcb4d.entry.js +0 -2
  366. package/dist/roadtrip/p-372fcb4d.entry.js.map +0 -1
  367. package/dist/roadtrip/p-40daa53b.entry.js +0 -2
  368. package/dist/roadtrip/p-4f47f4f7.entry.js.map +0 -1
  369. package/dist/roadtrip/p-5053b01a.entry.js +0 -2
  370. package/dist/roadtrip/p-5053b01a.entry.js.map +0 -1
  371. package/dist/roadtrip/p-7048f786.entry.js.map +0 -1
  372. package/dist/roadtrip/p-73fe2357.js.map +0 -1
  373. package/dist/roadtrip/p-9bef58e1.entry.js +0 -2
  374. package/dist/roadtrip/p-9bef58e1.entry.js.map +0 -1
  375. package/dist/roadtrip/p-a44a569a.entry.js +0 -2
  376. package/dist/roadtrip/p-a44a569a.entry.js.map +0 -1
  377. package/dist/roadtrip/p-a73ef7de.entry.js.map +0 -1
  378. package/dist/roadtrip/p-acbc0a14.entry.js +0 -2
  379. package/dist/roadtrip/p-acbc0a14.entry.js.map +0 -1
  380. package/dist/roadtrip/p-b2e7bfcb.entry.js +0 -2
  381. package/dist/roadtrip/p-b2e7bfcb.entry.js.map +0 -1
  382. package/dist/roadtrip/p-c3c92152.entry.js.map +0 -1
  383. package/dist/roadtrip/p-dcb280e3.entry.js.map +0 -1
  384. package/dist/roadtrip/p-e2149bdf.entry.js +0 -2
  385. package/dist/roadtrip/p-e2149bdf.entry.js.map +0 -1
  386. package/dist/roadtrip/p-ea28a425.entry.js.map +0 -1
  387. package/dist/roadtrip/p-ee7aaee5.entry.js +0 -2
  388. package/dist/roadtrip/p-ee7aaee5.entry.js.map +0 -1
  389. package/dist/roadtrip/p-faba450c.entry.js +0 -2
  390. package/dist/roadtrip/p-faba450c.entry.js.map +0 -1
  391. /package/dist/roadtrip/{p-82919e58.entry.js.map → p-16c934bc.entry.js.map} +0 -0
  392. /package/dist/roadtrip/{p-cbc00bfb.entry.js.map → p-cfc0a3a7.entry.js.map} +0 -0
  393. /package/dist/roadtrip/{p-414a2791.entry.js.map → p-e8c9c816.entry.js.map} +0 -0
@@ -1,2 +1,2 @@
1
- import{r as t,c as e,h as s,H as i,a as n}from"./p-f3d586b3.js";function r(t){return!Array.isArray?M(t)==="[object Array]":Array.isArray(t)}const c=1/0;function o(t){if(typeof t=="string"){return t}let e=t+"";return e=="0"&&1/t==-c?"-0":e}function a(t){return t==null?"":o(t)}function l(t){return typeof t==="string"}function h(t){return typeof t==="number"}function u(t){return t===true||t===false||d(t)&&M(t)=="[object Boolean]"}function f(t){return typeof t==="object"}function d(t){return f(t)&&t!==null}function g(t){return t!==undefined&&t!==null}function m(t){return!t.trim().length}function M(t){return t==null?t===undefined?"[object Undefined]":"[object Null]":Object.prototype.toString.call(t)}const x="Extended search is not available";const p="Incorrect 'index' type";const v=t=>`Invalid value for key ${t}`;const y=t=>`Pattern length exceeds max of ${t}.`;const L=t=>`Missing ${t} property in key`;const w=t=>`Property 'weight' in key '${t}' must be a positive integer`;const b=Object.prototype.hasOwnProperty;class ${constructor(t){this._keys=[];this._keyMap={};let e=0;t.forEach((t=>{let s=k(t);e+=s.weight;this._keys.push(s);this._keyMap[s.id]=s;e+=s.weight}));this._keys.forEach((t=>{t.weight/=e}))}get(t){return this._keyMap[t]}keys(){return this._keys}toJSON(){return JSON.stringify(this._keys)}}function k(t){let e=null;let s=null;let i=null;let n=1;if(l(t)||r(t)){i=t;e=S(t);s=A(t)}else{if(!b.call(t,"name")){throw new Error(L("name"))}const r=t.name;i=r;if(b.call(t,"weight")){n=t.weight;if(n<=0){throw new Error(w(r))}}e=S(r);s=A(r)}return{path:e,id:s,weight:n,src:i}}function S(t){return r(t)?t:t.split(".")}function A(t){return r(t)?t.join("."):t}function C(t,e){let s=[];let i=false;const n=(t,e,c)=>{if(!g(t)){return}if(!e[c]){s.push(t)}else{let o=e[c];const f=t[o];if(!g(f)){return}if(c===e.length-1&&(l(f)||h(f)||u(f))){s.push(a(f))}else if(r(f)){i=true;for(let t=0,s=f.length;t<s;t+=1){n(f[t],e,c+1)}}else if(e.length){n(f,e,c+1)}}};n(t,l(e)?e.split("."):e,0);return i?s:s[0]}const R={includeMatches:false,findAllMatches:false,minMatchCharLength:1};const N={isCaseSensitive:false,includeScore:false,keys:[],shouldSort:true,sortFn:(t,e)=>t.score===e.score?t.idx<e.idx?-1:1:t.score<e.score?-1:1};const I={location:0,threshold:.6,distance:100};const F={useExtendedSearch:false,getFn:C,ignoreLocation:false,ignoreFieldNorm:false,fieldNormWeight:1};var j={...N,...R,...I,...F};const O=/[^ ]+/g;function E(t=1,e=3){const s=new Map;const i=Math.pow(10,e);return{get(e){const n=e.match(O).length;if(s.has(n)){return s.get(n)}const r=1/Math.pow(n,.5*t);const c=parseFloat(Math.round(r*i)/i);s.set(n,c);return c},clear(){s.clear()}}}class _{constructor({getFn:t=j.getFn,fieldNormWeight:e=j.fieldNormWeight}={}){this.norm=E(e,3);this.getFn=t;this.isCreated=false;this.setIndexRecords()}setSources(t=[]){this.docs=t}setIndexRecords(t=[]){this.records=t}setKeys(t=[]){this.keys=t;this._keysMap={};t.forEach(((t,e)=>{this._keysMap[t.id]=e}))}create(){if(this.isCreated||!this.docs.length){return}this.isCreated=true;if(l(this.docs[0])){this.docs.forEach(((t,e)=>{this._addString(t,e)}))}else{this.docs.forEach(((t,e)=>{this._addObject(t,e)}))}this.norm.clear()}add(t){const e=this.size();if(l(t)){this._addString(t,e)}else{this._addObject(t,e)}}removeAt(t){this.records.splice(t,1);for(let e=t,s=this.size();e<s;e+=1){this.records[e].i-=1}}getValueForItemAtKeyId(t,e){return t[this._keysMap[e]]}size(){return this.records.length}_addString(t,e){if(!g(t)||m(t)){return}let s={v:t,i:e,n:this.norm.get(t)};this.records.push(s)}_addObject(t,e){let s={i:e,$:{}};this.keys.forEach(((e,i)=>{let n=this.getFn(t,e.path);if(!g(n)){return}if(r(n)){let t=[];const e=[{nestedArrIndex:-1,value:n}];while(e.length){const{nestedArrIndex:s,value:i}=e.pop();if(!g(i)){continue}if(l(i)&&!m(i)){let e={v:i,i:s,n:this.norm.get(i)};t.push(e)}else if(r(i)){i.forEach(((t,s)=>{e.push({nestedArrIndex:s,value:t})}))}else;}s.$[i]=t}else if(!m(n)){let t={v:n,n:this.norm.get(n)};s.$[i]=t}}));this.records.push(s)}toJSON(){return{keys:this.keys,records:this.records}}}function W(t,e,{getFn:s=j.getFn,fieldNormWeight:i=j.fieldNormWeight}={}){const n=new _({getFn:s,fieldNormWeight:i});n.setKeys(t.map(k));n.setSources(e);n.create();return n}function z(t,{getFn:e=j.getFn,fieldNormWeight:s=j.fieldNormWeight}={}){const{keys:i,records:n}=t;const r=new _({getFn:e,fieldNormWeight:s});r.setKeys(i);r.setIndexRecords(n);return r}function P(t,{errors:e=0,currentLocation:s=0,expectedLocation:i=0,distance:n=j.distance,ignoreLocation:r=j.ignoreLocation}={}){const c=e/t.length;if(r){return c}const o=Math.abs(i-s);if(!n){return o?1:c}return c+o/n}function T(t=[],e=j.minMatchCharLength){let s=[];let i=-1;let n=-1;let r=0;for(let c=t.length;r<c;r+=1){let c=t[r];if(c&&i===-1){i=r}else if(!c&&i!==-1){n=r-1;if(n-i+1>=e){s.push([i,n])}i=-1}}if(t[r-1]&&r-i>=e){s.push([i,r-1])}return s}const H=32;function J(t,e,s,{location:i=j.location,distance:n=j.distance,threshold:r=j.threshold,findAllMatches:c=j.findAllMatches,minMatchCharLength:o=j.minMatchCharLength,includeMatches:a=j.includeMatches,ignoreLocation:l=j.ignoreLocation}={}){if(e.length>H){throw new Error(y(H))}const h=e.length;const u=t.length;const f=Math.max(0,Math.min(i,u));let d=r;let g=f;const m=o>1||a;const M=m?Array(u):[];let x;while((x=t.indexOf(e,g))>-1){let t=P(e,{currentLocation:x,expectedLocation:f,distance:n,ignoreLocation:l});d=Math.min(t,d);g=x+h;if(m){let t=0;while(t<h){M[x+t]=1;t+=1}}}g=-1;let p=[];let v=1;let L=h+u;const w=1<<h-1;for(let i=0;i<h;i+=1){let r=0;let o=L;while(r<o){const t=P(e,{errors:i,currentLocation:f+o,expectedLocation:f,distance:n,ignoreLocation:l});if(t<=d){r=o}else{L=o}o=Math.floor((L-r)/2+r)}L=o;let a=Math.max(1,f-o+1);let x=c?u:Math.min(f+o,u)+h;let y=Array(x+2);y[x+1]=(1<<i)-1;for(let r=x;r>=a;r-=1){let c=r-1;let o=s[t.charAt(c)];if(m){M[c]=+!!o}y[r]=(y[r+1]<<1|1)&o;if(i){y[r]|=(p[r+1]|p[r])<<1|1|p[r+1]}if(y[r]&w){v=P(e,{errors:i,currentLocation:c,expectedLocation:f,distance:n,ignoreLocation:l});if(v<=d){d=v;g=c;if(g<=f){break}a=Math.max(1,2*f-g)}}}const b=P(e,{errors:i+1,currentLocation:f,expectedLocation:f,distance:n,ignoreLocation:l});if(b>d){break}p=y}const b={isMatch:g>=0,score:Math.max(.001,v)};if(m){const t=T(M,o);if(!t.length){b.isMatch=false}else if(a){b.indices=t}}return b}function B(t){let e={};for(let s=0,i=t.length;s<i;s+=1){const n=t.charAt(s);e[n]=(e[n]||0)|1<<i-s-1}return e}class K{constructor(t,{location:e=j.location,threshold:s=j.threshold,distance:i=j.distance,includeMatches:n=j.includeMatches,findAllMatches:r=j.findAllMatches,minMatchCharLength:c=j.minMatchCharLength,isCaseSensitive:o=j.isCaseSensitive,ignoreLocation:a=j.ignoreLocation}={}){this.options={location:e,threshold:s,distance:i,includeMatches:n,findAllMatches:r,minMatchCharLength:c,isCaseSensitive:o,ignoreLocation:a};this.pattern=o?t:t.toLowerCase();this.chunks=[];if(!this.pattern.length){return}const l=(t,e)=>{this.chunks.push({pattern:t,alphabet:B(t),startIndex:e})};const h=this.pattern.length;if(h>H){let t=0;const e=h%H;const s=h-e;while(t<s){l(this.pattern.substr(t,H),t);t+=H}if(e){const t=h-H;l(this.pattern.substr(t),t)}}else{l(this.pattern,0)}}searchIn(t){const{isCaseSensitive:e,includeMatches:s}=this.options;if(!e){t=t.toLowerCase()}if(this.pattern===t){let e={isMatch:true,score:0};if(s){e.indices=[[0,t.length-1]]}return e}const{location:i,distance:n,threshold:r,findAllMatches:c,minMatchCharLength:o,ignoreLocation:a}=this.options;let l=[];let h=0;let u=false;this.chunks.forEach((({pattern:e,alphabet:f,startIndex:d})=>{const{isMatch:g,score:m,indices:M}=J(t,e,f,{location:i+d,distance:n,threshold:r,findAllMatches:c,minMatchCharLength:o,includeMatches:s,ignoreLocation:a});if(g){u=true}h+=m;if(g&&M){l=[...l,...M]}}));let f={isMatch:u,score:u?h/this.chunks.length:1};if(u&&s){f.indices=l}return f}}class D{constructor(t){this.pattern=t}static isMultiMatch(t){return U(t,this.multiRegex)}static isSingleMatch(t){return U(t,this.singleRegex)}search(){}}function U(t,e){const s=t.match(e);return s?s[1]:null}class V extends D{constructor(t){super(t)}static get type(){return"exact"}static get multiRegex(){return/^="(.*)"$/}static get singleRegex(){return/^=(.*)$/}search(t){const e=t===this.pattern;return{isMatch:e,score:e?0:1,indices:[0,this.pattern.length-1]}}}class q extends D{constructor(t){super(t)}static get type(){return"inverse-exact"}static get multiRegex(){return/^!"(.*)"$/}static get singleRegex(){return/^!(.*)$/}search(t){const e=t.indexOf(this.pattern);const s=e===-1;return{isMatch:s,score:s?0:1,indices:[0,t.length-1]}}}class G extends D{constructor(t){super(t)}static get type(){return"prefix-exact"}static get multiRegex(){return/^\^"(.*)"$/}static get singleRegex(){return/^\^(.*)$/}search(t){const e=t.startsWith(this.pattern);return{isMatch:e,score:e?0:1,indices:[0,this.pattern.length-1]}}}class Q extends D{constructor(t){super(t)}static get type(){return"inverse-prefix-exact"}static get multiRegex(){return/^!\^"(.*)"$/}static get singleRegex(){return/^!\^(.*)$/}search(t){const e=!t.startsWith(this.pattern);return{isMatch:e,score:e?0:1,indices:[0,t.length-1]}}}class X extends D{constructor(t){super(t)}static get type(){return"suffix-exact"}static get multiRegex(){return/^"(.*)"\$$/}static get singleRegex(){return/^(.*)\$$/}search(t){const e=t.endsWith(this.pattern);return{isMatch:e,score:e?0:1,indices:[t.length-this.pattern.length,t.length-1]}}}class Y extends D{constructor(t){super(t)}static get type(){return"inverse-suffix-exact"}static get multiRegex(){return/^!"(.*)"\$$/}static get singleRegex(){return/^!(.*)\$$/}search(t){const e=!t.endsWith(this.pattern);return{isMatch:e,score:e?0:1,indices:[0,t.length-1]}}}class Z extends D{constructor(t,{location:e=j.location,threshold:s=j.threshold,distance:i=j.distance,includeMatches:n=j.includeMatches,findAllMatches:r=j.findAllMatches,minMatchCharLength:c=j.minMatchCharLength,isCaseSensitive:o=j.isCaseSensitive,ignoreLocation:a=j.ignoreLocation}={}){super(t);this._bitapSearch=new K(t,{location:e,threshold:s,distance:i,includeMatches:n,findAllMatches:r,minMatchCharLength:c,isCaseSensitive:o,ignoreLocation:a})}static get type(){return"fuzzy"}static get multiRegex(){return/^"(.*)"$/}static get singleRegex(){return/^(.*)$/}search(t){return this._bitapSearch.searchIn(t)}}class tt extends D{constructor(t){super(t)}static get type(){return"include"}static get multiRegex(){return/^'"(.*)"$/}static get singleRegex(){return/^'(.*)$/}search(t){let e=0;let s;const i=[];const n=this.pattern.length;while((s=t.indexOf(this.pattern,e))>-1){e=s+n;i.push([s,e-1])}const r=!!i.length;return{isMatch:r,score:r?0:1,indices:i}}}const et=[V,tt,G,Q,Y,X,q,Z];const st=et.length;const it=/ +(?=([^\"]*\"[^\"]*\")*[^\"]*$)/;const nt="|";function rt(t,e={}){return t.split(nt).map((t=>{let s=t.trim().split(it).filter((t=>t&&!!t.trim()));let i=[];for(let t=0,n=s.length;t<n;t+=1){const n=s[t];let r=false;let c=-1;while(!r&&++c<st){const t=et[c];let s=t.isMultiMatch(n);if(s){i.push(new t(s,e));r=true}}if(r){continue}c=-1;while(++c<st){const t=et[c];let s=t.isSingleMatch(n);if(s){i.push(new t(s,e));break}}}return i}))}const ct=new Set([Z.type,tt.type]);class ot{constructor(t,{isCaseSensitive:e=j.isCaseSensitive,includeMatches:s=j.includeMatches,minMatchCharLength:i=j.minMatchCharLength,ignoreLocation:n=j.ignoreLocation,findAllMatches:r=j.findAllMatches,location:c=j.location,threshold:o=j.threshold,distance:a=j.distance}={}){this.query=null;this.options={isCaseSensitive:e,includeMatches:s,minMatchCharLength:i,findAllMatches:r,ignoreLocation:n,location:c,threshold:o,distance:a};this.pattern=e?t:t.toLowerCase();this.query=rt(this.pattern,this.options)}static condition(t,e){return e.useExtendedSearch}searchIn(t){const e=this.query;if(!e){return{isMatch:false,score:1}}const{includeMatches:s,isCaseSensitive:i}=this.options;t=i?t:t.toLowerCase();let n=0;let r=[];let c=0;for(let i=0,o=e.length;i<o;i+=1){const o=e[i];r.length=0;n=0;for(let e=0,i=o.length;e<i;e+=1){const i=o[e];const{isMatch:a,indices:l,score:h}=i.search(t);if(a){n+=1;c+=h;if(s){const t=i.constructor.type;if(ct.has(t)){r=[...r,...l]}else{r.push(l)}}}else{c=0;n=0;r.length=0;break}}if(n){let t={isMatch:true,score:c/n};if(s){t.indices=r}return t}}return{isMatch:false,score:1}}}const at=[];function lt(...t){at.push(...t)}function ht(t,e){for(let s=0,i=at.length;s<i;s+=1){let i=at[s];if(i.condition(t,e)){return new i(t,e)}}return new K(t,e)}const ut={AND:"$and",OR:"$or"};const ft={PATH:"$path",PATTERN:"$val"};const dt=t=>!!(t[ut.AND]||t[ut.OR]);const gt=t=>!!t[ft.PATH];const mt=t=>!r(t)&&f(t)&&!dt(t);const Mt=t=>({[ut.AND]:Object.keys(t).map((e=>({[e]:t[e]})))});function xt(t,e,{auto:s=true}={}){const i=t=>{let n=Object.keys(t);const c=gt(t);if(!c&&n.length>1&&!dt(t)){return i(Mt(t))}if(mt(t)){const i=c?t[ft.PATH]:n[0];const r=c?t[ft.PATTERN]:t[i];if(!l(r)){throw new Error(v(i))}const o={keyId:A(i),pattern:r};if(s){o.searcher=ht(r,e)}return o}let o={children:[],operator:n[0]};n.forEach((e=>{const s=t[e];if(r(s)){s.forEach((t=>{o.children.push(i(t))}))}}));return o};if(!dt(t)){t=Mt(t)}return i(t)}function pt(t,{ignoreFieldNorm:e=j.ignoreFieldNorm}){t.forEach((t=>{let s=1;t.matches.forEach((({key:t,norm:i,score:n})=>{const r=t?t.weight:null;s*=Math.pow(n===0&&r?Number.EPSILON:n,(r||1)*(e?1:i))}));t.score=s}))}function vt(t,e){const s=t.matches;e.matches=[];if(!g(s)){return}s.forEach((t=>{if(!g(t.indices)||!t.indices.length){return}const{indices:s,value:i}=t;let n={indices:s,value:i};if(t.key){n.key=t.key.src}if(t.idx>-1){n.refIndex=t.idx}e.matches.push(n)}))}function yt(t,e){e.score=t.score}function Lt(t,e,{includeMatches:s=j.includeMatches,includeScore:i=j.includeScore}={}){const n=[];if(s)n.push(vt);if(i)n.push(yt);return t.map((t=>{const{idx:s}=t;const i={item:e[s],refIndex:s};if(n.length){n.forEach((e=>{e(t,i)}))}return i}))}class wt{constructor(t,e={},s){this.options={...j,...e};if(this.options.useExtendedSearch&&!true){throw new Error(x)}this._keyStore=new $(this.options.keys);this.setCollection(t,s)}setCollection(t,e){this._docs=t;if(e&&!(e instanceof _)){throw new Error(p)}this._myIndex=e||W(this.options.keys,this._docs,{getFn:this.options.getFn,fieldNormWeight:this.options.fieldNormWeight})}add(t){if(!g(t)){return}this._docs.push(t);this._myIndex.add(t)}remove(t=(()=>false)){const e=[];for(let s=0,i=this._docs.length;s<i;s+=1){const n=this._docs[s];if(t(n,s)){this.removeAt(s);s-=1;i-=1;e.push(n)}}return e}removeAt(t){this._docs.splice(t,1);this._myIndex.removeAt(t)}getIndex(){return this._myIndex}search(t,{limit:e=-1}={}){const{includeMatches:s,includeScore:i,shouldSort:n,sortFn:r,ignoreFieldNorm:c}=this.options;let o=l(t)?l(this._docs[0])?this._searchStringList(t):this._searchObjectList(t):this._searchLogical(t);pt(o,{ignoreFieldNorm:c});if(n){o.sort(r)}if(h(e)&&e>-1){o=o.slice(0,e)}return Lt(o,this._docs,{includeMatches:s,includeScore:i})}_searchStringList(t){const e=ht(t,this.options);const{records:s}=this._myIndex;const i=[];s.forEach((({v:t,i:s,n})=>{if(!g(t)){return}const{isMatch:r,score:c,indices:o}=e.searchIn(t);if(r){i.push({item:t,idx:s,matches:[{score:c,value:t,norm:n,indices:o}]})}}));return i}_searchLogical(t){const e=xt(t,this.options);const s=(t,e,i)=>{if(!t.children){const{keyId:s,searcher:n}=t;const r=this._findMatches({key:this._keyStore.get(s),value:this._myIndex.getValueForItemAtKeyId(e,s),searcher:n});if(r&&r.length){return[{idx:i,item:e,matches:r}]}return[]}const n=[];for(let r=0,c=t.children.length;r<c;r+=1){const c=t.children[r];const o=s(c,e,i);if(o.length){n.push(...o)}else if(t.operator===ut.AND){return[]}}return n};const i=this._myIndex.records;const n={};const r=[];i.forEach((({$:t,i})=>{if(g(t)){let c=s(e,t,i);if(c.length){if(!n[i]){n[i]={idx:i,item:t,matches:[]};r.push(n[i])}c.forEach((({matches:t})=>{n[i].matches.push(...t)}))}}}));return r}_searchObjectList(t){const e=ht(t,this.options);const{keys:s,records:i}=this._myIndex;const n=[];i.forEach((({$:t,i})=>{if(!g(t)){return}let r=[];s.forEach(((s,i)=>{r.push(...this._findMatches({key:s,value:t[i],searcher:e}))}));if(r.length){n.push({idx:i,item:t,matches:r})}}));return n}_findMatches({key:t,value:e,searcher:s}){if(!g(e)){return[]}let i=[];if(r(e)){e.forEach((({v:e,i:n,n:r})=>{if(!g(e)){return}const{isMatch:c,score:o,indices:a}=s.searchIn(e);if(c){i.push({score:o,key:t,value:e,idx:n,norm:r,indices:a})}}))}else{const{v:n,n:r}=e;const{isMatch:c,score:o,indices:a}=s.searchIn(n);if(c){i.push({score:o,key:t,value:n,norm:r,indices:a})}}return i}}wt.version="6.5.3";wt.createIndex=W;wt.parseIndex=z;wt.config=j;{wt.parseQuery=xt}{lt(ot)}const bt=".sc-road-select-filter-h{--margin-top:3rem;position:relative;display:block}.select-filter-list.sc-road-select-filter{position:absolute;top:var(--margin-top);z-index:1;width:100%;max-height:16rem;padding:0.5rem 0;margin:0;overflow-y:scroll;font-family:var(--road-font, sans-serif);font-size:1rem;color:var(--road-on-surface);list-style-type:none;background:var(--road-surface);border-radius:0 0 0.25rem 0.25rem;box-shadow:var(--road-elevation-low)}.select-filter-list.not-active.sc-road-select-filter{opacity:0}.select-filter-item.sc-road-select-filter{display:flex;align-items:center;padding:0.75rem 1rem;cursor:pointer}.select-filter-item.sc-road-select-filter:hover,.select-filter-item.highlight.sc-road-select-filter{color:var(--road-on-primary);background:var(--road-primary)}";const $t=class{constructor(s){t(this,s);this.roadselected=e(this,"roadselected",7);this.roadSelected=e(this,"roadSelected",7);this.onClick=(t,e)=>{this.el.querySelector("road-input").value=e;if(document.getElementsByClassName("phone-number-label-icon").length>0){this.el.querySelector("road-icon").name="flag-"+e}this.isOpen=false;this.roadselected.emit({value:t.toString(),label:e});this.roadSelected.emit({value:t.toString(),label:e})};this.isOpen=false;this.currentValue="";this.options=[];this.parameters={keys:["value","label"],threshold:.3,ignoreLocation:true};this.isActive=false;this.onlySelect=true}handleFocus(){this.isOpen=true;this.isActive=true}handleBlur(){this.isActive=false}handleChange(t){this.currentValue=t.detail.value.toLowerCase()}onClickOutside(t){if(this.isOpen&&!this.el.contains(t.target)){this.isOpen=false;this.isActive=false;const t=this.el.querySelector("road-input").value;if(this.onlySelect&&!this.options.some((e=>e["label"]===t))){this.el.querySelector("road-input").value=""}}}render(){const t=new wt(this.options,this.parameters);const e=this.currentValue===""?this.options.map(((t,e)=>({item:t,score:1,refIndex:e}))):t.search(this.currentValue);const n=this.isActive?"true":"false";const r=this.isActive?"":"not-active";return s(i,{"is-active":n},s("slot",null),this.isOpen&&s("ul",{class:`${r} select-filter-list`,role:"listbox"},e.map((t=>s("li",{class:"select-filter-item",role:"option",onClick:()=>this.onClick(t.item.value,t.item.label.replace(/(<([^>]+)>)/gi,"")),innerHTML:t.item.label})))))}get el(){return n(this)}};$t.style=bt;export{$t as road_select_filter};
2
- //# sourceMappingURL=p-1a761fc0.entry.js.map
1
+ import{r as t,c as e,h as s,H as i,a as n}from"./p-f3d586b3.js";function r(t){return!Array.isArray?M(t)==="[object Array]":Array.isArray(t)}const c=1/0;function o(t){if(typeof t=="string"){return t}let e=t+"";return e=="0"&&1/t==-c?"-0":e}function a(t){return t==null?"":o(t)}function l(t){return typeof t==="string"}function h(t){return typeof t==="number"}function u(t){return t===true||t===false||d(t)&&M(t)=="[object Boolean]"}function f(t){return typeof t==="object"}function d(t){return f(t)&&t!==null}function g(t){return t!==undefined&&t!==null}function m(t){return!t.trim().length}function M(t){return t==null?t===undefined?"[object Undefined]":"[object Null]":Object.prototype.toString.call(t)}const p="Extended search is not available";const x="Incorrect 'index' type";const v=t=>`Invalid value for key ${t}`;const y=t=>`Pattern length exceeds max of ${t}.`;const w=t=>`Missing ${t} property in key`;const L=t=>`Property 'weight' in key '${t}' must be a positive integer`;const b=Object.prototype.hasOwnProperty;class ${constructor(t){this._keys=[];this._keyMap={};let e=0;t.forEach((t=>{let s=k(t);e+=s.weight;this._keys.push(s);this._keyMap[s.id]=s;e+=s.weight}));this._keys.forEach((t=>{t.weight/=e}))}get(t){return this._keyMap[t]}keys(){return this._keys}toJSON(){return JSON.stringify(this._keys)}}function k(t){let e=null;let s=null;let i=null;let n=1;if(l(t)||r(t)){i=t;e=A(t);s=S(t)}else{if(!b.call(t,"name")){throw new Error(w("name"))}const r=t.name;i=r;if(b.call(t,"weight")){n=t.weight;if(n<=0){throw new Error(L(r))}}e=A(r);s=S(r)}return{path:e,id:s,weight:n,src:i}}function A(t){return r(t)?t:t.split(".")}function S(t){return r(t)?t.join("."):t}function C(t,e){let s=[];let i=false;const n=(t,e,c)=>{if(!g(t)){return}if(!e[c]){s.push(t)}else{let o=e[c];const f=t[o];if(!g(f)){return}if(c===e.length-1&&(l(f)||h(f)||u(f))){s.push(a(f))}else if(r(f)){i=true;for(let t=0,s=f.length;t<s;t+=1){n(f[t],e,c+1)}}else if(e.length){n(f,e,c+1)}}};n(t,l(e)?e.split("."):e,0);return i?s:s[0]}const R={includeMatches:false,findAllMatches:false,minMatchCharLength:1};const N={isCaseSensitive:false,includeScore:false,keys:[],shouldSort:true,sortFn:(t,e)=>t.score===e.score?t.idx<e.idx?-1:1:t.score<e.score?-1:1};const I={location:0,threshold:.6,distance:100};const F={useExtendedSearch:false,getFn:C,ignoreLocation:false,ignoreFieldNorm:false,fieldNormWeight:1};var O={...N,...R,...I,...F};const j=/[^ ]+/g;function E(t=1,e=3){const s=new Map;const i=Math.pow(10,e);return{get(e){const n=e.match(j).length;if(s.has(n)){return s.get(n)}const r=1/Math.pow(n,.5*t);const c=parseFloat(Math.round(r*i)/i);s.set(n,c);return c},clear(){s.clear()}}}class _{constructor({getFn:t=O.getFn,fieldNormWeight:e=O.fieldNormWeight}={}){this.norm=E(e,3);this.getFn=t;this.isCreated=false;this.setIndexRecords()}setSources(t=[]){this.docs=t}setIndexRecords(t=[]){this.records=t}setKeys(t=[]){this.keys=t;this._keysMap={};t.forEach(((t,e)=>{this._keysMap[t.id]=e}))}create(){if(this.isCreated||!this.docs.length){return}this.isCreated=true;if(l(this.docs[0])){this.docs.forEach(((t,e)=>{this._addString(t,e)}))}else{this.docs.forEach(((t,e)=>{this._addObject(t,e)}))}this.norm.clear()}add(t){const e=this.size();if(l(t)){this._addString(t,e)}else{this._addObject(t,e)}}removeAt(t){this.records.splice(t,1);for(let e=t,s=this.size();e<s;e+=1){this.records[e].i-=1}}getValueForItemAtKeyId(t,e){return t[this._keysMap[e]]}size(){return this.records.length}_addString(t,e){if(!g(t)||m(t)){return}let s={v:t,i:e,n:this.norm.get(t)};this.records.push(s)}_addObject(t,e){let s={i:e,$:{}};this.keys.forEach(((e,i)=>{let n=this.getFn(t,e.path);if(!g(n)){return}if(r(n)){let t=[];const e=[{nestedArrIndex:-1,value:n}];while(e.length){const{nestedArrIndex:s,value:i}=e.pop();if(!g(i)){continue}if(l(i)&&!m(i)){let e={v:i,i:s,n:this.norm.get(i)};t.push(e)}else if(r(i)){i.forEach(((t,s)=>{e.push({nestedArrIndex:s,value:t})}))}else;}s.$[i]=t}else if(!m(n)){let t={v:n,n:this.norm.get(n)};s.$[i]=t}}));this.records.push(s)}toJSON(){return{keys:this.keys,records:this.records}}}function W(t,e,{getFn:s=O.getFn,fieldNormWeight:i=O.fieldNormWeight}={}){const n=new _({getFn:s,fieldNormWeight:i});n.setKeys(t.map(k));n.setSources(e);n.create();return n}function z(t,{getFn:e=O.getFn,fieldNormWeight:s=O.fieldNormWeight}={}){const{keys:i,records:n}=t;const r=new _({getFn:e,fieldNormWeight:s});r.setKeys(i);r.setIndexRecords(n);return r}function P(t,{errors:e=0,currentLocation:s=0,expectedLocation:i=0,distance:n=O.distance,ignoreLocation:r=O.ignoreLocation}={}){const c=e/t.length;if(r){return c}const o=Math.abs(i-s);if(!n){return o?1:c}return c+o/n}function T(t=[],e=O.minMatchCharLength){let s=[];let i=-1;let n=-1;let r=0;for(let c=t.length;r<c;r+=1){let c=t[r];if(c&&i===-1){i=r}else if(!c&&i!==-1){n=r-1;if(n-i+1>=e){s.push([i,n])}i=-1}}if(t[r-1]&&r-i>=e){s.push([i,r-1])}return s}const H=32;function J(t,e,s,{location:i=O.location,distance:n=O.distance,threshold:r=O.threshold,findAllMatches:c=O.findAllMatches,minMatchCharLength:o=O.minMatchCharLength,includeMatches:a=O.includeMatches,ignoreLocation:l=O.ignoreLocation}={}){if(e.length>H){throw new Error(y(H))}const h=e.length;const u=t.length;const f=Math.max(0,Math.min(i,u));let d=r;let g=f;const m=o>1||a;const M=m?Array(u):[];let p;while((p=t.indexOf(e,g))>-1){let t=P(e,{currentLocation:p,expectedLocation:f,distance:n,ignoreLocation:l});d=Math.min(t,d);g=p+h;if(m){let t=0;while(t<h){M[p+t]=1;t+=1}}}g=-1;let x=[];let v=1;let w=h+u;const L=1<<h-1;for(let i=0;i<h;i+=1){let r=0;let o=w;while(r<o){const t=P(e,{errors:i,currentLocation:f+o,expectedLocation:f,distance:n,ignoreLocation:l});if(t<=d){r=o}else{w=o}o=Math.floor((w-r)/2+r)}w=o;let a=Math.max(1,f-o+1);let p=c?u:Math.min(f+o,u)+h;let y=Array(p+2);y[p+1]=(1<<i)-1;for(let r=p;r>=a;r-=1){let c=r-1;let o=s[t.charAt(c)];if(m){M[c]=+!!o}y[r]=(y[r+1]<<1|1)&o;if(i){y[r]|=(x[r+1]|x[r])<<1|1|x[r+1]}if(y[r]&L){v=P(e,{errors:i,currentLocation:c,expectedLocation:f,distance:n,ignoreLocation:l});if(v<=d){d=v;g=c;if(g<=f){break}a=Math.max(1,2*f-g)}}}const b=P(e,{errors:i+1,currentLocation:f,expectedLocation:f,distance:n,ignoreLocation:l});if(b>d){break}x=y}const b={isMatch:g>=0,score:Math.max(.001,v)};if(m){const t=T(M,o);if(!t.length){b.isMatch=false}else if(a){b.indices=t}}return b}function K(t){let e={};for(let s=0,i=t.length;s<i;s+=1){const n=t.charAt(s);e[n]=(e[n]||0)|1<<i-s-1}return e}class B{constructor(t,{location:e=O.location,threshold:s=O.threshold,distance:i=O.distance,includeMatches:n=O.includeMatches,findAllMatches:r=O.findAllMatches,minMatchCharLength:c=O.minMatchCharLength,isCaseSensitive:o=O.isCaseSensitive,ignoreLocation:a=O.ignoreLocation}={}){this.options={location:e,threshold:s,distance:i,includeMatches:n,findAllMatches:r,minMatchCharLength:c,isCaseSensitive:o,ignoreLocation:a};this.pattern=o?t:t.toLowerCase();this.chunks=[];if(!this.pattern.length){return}const l=(t,e)=>{this.chunks.push({pattern:t,alphabet:K(t),startIndex:e})};const h=this.pattern.length;if(h>H){let t=0;const e=h%H;const s=h-e;while(t<s){l(this.pattern.substr(t,H),t);t+=H}if(e){const t=h-H;l(this.pattern.substr(t),t)}}else{l(this.pattern,0)}}searchIn(t){const{isCaseSensitive:e,includeMatches:s}=this.options;if(!e){t=t.toLowerCase()}if(this.pattern===t){let e={isMatch:true,score:0};if(s){e.indices=[[0,t.length-1]]}return e}const{location:i,distance:n,threshold:r,findAllMatches:c,minMatchCharLength:o,ignoreLocation:a}=this.options;let l=[];let h=0;let u=false;this.chunks.forEach((({pattern:e,alphabet:f,startIndex:d})=>{const{isMatch:g,score:m,indices:M}=J(t,e,f,{location:i+d,distance:n,threshold:r,findAllMatches:c,minMatchCharLength:o,includeMatches:s,ignoreLocation:a});if(g){u=true}h+=m;if(g&&M){l=[...l,...M]}}));let f={isMatch:u,score:u?h/this.chunks.length:1};if(u&&s){f.indices=l}return f}}class D{constructor(t){this.pattern=t}static isMultiMatch(t){return U(t,this.multiRegex)}static isSingleMatch(t){return U(t,this.singleRegex)}search(){}}function U(t,e){const s=t.match(e);return s?s[1]:null}class V extends D{constructor(t){super(t)}static get type(){return"exact"}static get multiRegex(){return/^="(.*)"$/}static get singleRegex(){return/^=(.*)$/}search(t){const e=t===this.pattern;return{isMatch:e,score:e?0:1,indices:[0,this.pattern.length-1]}}}class q extends D{constructor(t){super(t)}static get type(){return"inverse-exact"}static get multiRegex(){return/^!"(.*)"$/}static get singleRegex(){return/^!(.*)$/}search(t){const e=t.indexOf(this.pattern);const s=e===-1;return{isMatch:s,score:s?0:1,indices:[0,t.length-1]}}}class G extends D{constructor(t){super(t)}static get type(){return"prefix-exact"}static get multiRegex(){return/^\^"(.*)"$/}static get singleRegex(){return/^\^(.*)$/}search(t){const e=t.startsWith(this.pattern);return{isMatch:e,score:e?0:1,indices:[0,this.pattern.length-1]}}}class Q extends D{constructor(t){super(t)}static get type(){return"inverse-prefix-exact"}static get multiRegex(){return/^!\^"(.*)"$/}static get singleRegex(){return/^!\^(.*)$/}search(t){const e=!t.startsWith(this.pattern);return{isMatch:e,score:e?0:1,indices:[0,t.length-1]}}}class X extends D{constructor(t){super(t)}static get type(){return"suffix-exact"}static get multiRegex(){return/^"(.*)"\$$/}static get singleRegex(){return/^(.*)\$$/}search(t){const e=t.endsWith(this.pattern);return{isMatch:e,score:e?0:1,indices:[t.length-this.pattern.length,t.length-1]}}}class Y extends D{constructor(t){super(t)}static get type(){return"inverse-suffix-exact"}static get multiRegex(){return/^!"(.*)"\$$/}static get singleRegex(){return/^!(.*)\$$/}search(t){const e=!t.endsWith(this.pattern);return{isMatch:e,score:e?0:1,indices:[0,t.length-1]}}}class Z extends D{constructor(t,{location:e=O.location,threshold:s=O.threshold,distance:i=O.distance,includeMatches:n=O.includeMatches,findAllMatches:r=O.findAllMatches,minMatchCharLength:c=O.minMatchCharLength,isCaseSensitive:o=O.isCaseSensitive,ignoreLocation:a=O.ignoreLocation}={}){super(t);this._bitapSearch=new B(t,{location:e,threshold:s,distance:i,includeMatches:n,findAllMatches:r,minMatchCharLength:c,isCaseSensitive:o,ignoreLocation:a})}static get type(){return"fuzzy"}static get multiRegex(){return/^"(.*)"$/}static get singleRegex(){return/^(.*)$/}search(t){return this._bitapSearch.searchIn(t)}}class tt extends D{constructor(t){super(t)}static get type(){return"include"}static get multiRegex(){return/^'"(.*)"$/}static get singleRegex(){return/^'(.*)$/}search(t){let e=0;let s;const i=[];const n=this.pattern.length;while((s=t.indexOf(this.pattern,e))>-1){e=s+n;i.push([s,e-1])}const r=!!i.length;return{isMatch:r,score:r?0:1,indices:i}}}const et=[V,tt,G,Q,Y,X,q,Z];const st=et.length;const it=/ +(?=([^\"]*\"[^\"]*\")*[^\"]*$)/;const nt="|";function rt(t,e={}){return t.split(nt).map((t=>{let s=t.trim().split(it).filter((t=>t&&!!t.trim()));let i=[];for(let t=0,n=s.length;t<n;t+=1){const n=s[t];let r=false;let c=-1;while(!r&&++c<st){const t=et[c];let s=t.isMultiMatch(n);if(s){i.push(new t(s,e));r=true}}if(r){continue}c=-1;while(++c<st){const t=et[c];let s=t.isSingleMatch(n);if(s){i.push(new t(s,e));break}}}return i}))}const ct=new Set([Z.type,tt.type]);class ot{constructor(t,{isCaseSensitive:e=O.isCaseSensitive,includeMatches:s=O.includeMatches,minMatchCharLength:i=O.minMatchCharLength,ignoreLocation:n=O.ignoreLocation,findAllMatches:r=O.findAllMatches,location:c=O.location,threshold:o=O.threshold,distance:a=O.distance}={}){this.query=null;this.options={isCaseSensitive:e,includeMatches:s,minMatchCharLength:i,findAllMatches:r,ignoreLocation:n,location:c,threshold:o,distance:a};this.pattern=e?t:t.toLowerCase();this.query=rt(this.pattern,this.options)}static condition(t,e){return e.useExtendedSearch}searchIn(t){const e=this.query;if(!e){return{isMatch:false,score:1}}const{includeMatches:s,isCaseSensitive:i}=this.options;t=i?t:t.toLowerCase();let n=0;let r=[];let c=0;for(let i=0,o=e.length;i<o;i+=1){const o=e[i];r.length=0;n=0;for(let e=0,i=o.length;e<i;e+=1){const i=o[e];const{isMatch:a,indices:l,score:h}=i.search(t);if(a){n+=1;c+=h;if(s){const t=i.constructor.type;if(ct.has(t)){r=[...r,...l]}else{r.push(l)}}}else{c=0;n=0;r.length=0;break}}if(n){let t={isMatch:true,score:c/n};if(s){t.indices=r}return t}}return{isMatch:false,score:1}}}const at=[];function lt(...t){at.push(...t)}function ht(t,e){for(let s=0,i=at.length;s<i;s+=1){let i=at[s];if(i.condition(t,e)){return new i(t,e)}}return new B(t,e)}const ut={AND:"$and",OR:"$or"};const ft={PATH:"$path",PATTERN:"$val"};const dt=t=>!!(t[ut.AND]||t[ut.OR]);const gt=t=>!!t[ft.PATH];const mt=t=>!r(t)&&f(t)&&!dt(t);const Mt=t=>({[ut.AND]:Object.keys(t).map((e=>({[e]:t[e]})))});function pt(t,e,{auto:s=true}={}){const i=t=>{let n=Object.keys(t);const c=gt(t);if(!c&&n.length>1&&!dt(t)){return i(Mt(t))}if(mt(t)){const i=c?t[ft.PATH]:n[0];const r=c?t[ft.PATTERN]:t[i];if(!l(r)){throw new Error(v(i))}const o={keyId:S(i),pattern:r};if(s){o.searcher=ht(r,e)}return o}let o={children:[],operator:n[0]};n.forEach((e=>{const s=t[e];if(r(s)){s.forEach((t=>{o.children.push(i(t))}))}}));return o};if(!dt(t)){t=Mt(t)}return i(t)}function xt(t,{ignoreFieldNorm:e=O.ignoreFieldNorm}){t.forEach((t=>{let s=1;t.matches.forEach((({key:t,norm:i,score:n})=>{const r=t?t.weight:null;s*=Math.pow(n===0&&r?Number.EPSILON:n,(r||1)*(e?1:i))}));t.score=s}))}function vt(t,e){const s=t.matches;e.matches=[];if(!g(s)){return}s.forEach((t=>{if(!g(t.indices)||!t.indices.length){return}const{indices:s,value:i}=t;let n={indices:s,value:i};if(t.key){n.key=t.key.src}if(t.idx>-1){n.refIndex=t.idx}e.matches.push(n)}))}function yt(t,e){e.score=t.score}function wt(t,e,{includeMatches:s=O.includeMatches,includeScore:i=O.includeScore}={}){const n=[];if(s)n.push(vt);if(i)n.push(yt);return t.map((t=>{const{idx:s}=t;const i={item:e[s],refIndex:s};if(n.length){n.forEach((e=>{e(t,i)}))}return i}))}class Lt{constructor(t,e={},s){this.options={...O,...e};if(this.options.useExtendedSearch&&!true){throw new Error(p)}this._keyStore=new $(this.options.keys);this.setCollection(t,s)}setCollection(t,e){this._docs=t;if(e&&!(e instanceof _)){throw new Error(x)}this._myIndex=e||W(this.options.keys,this._docs,{getFn:this.options.getFn,fieldNormWeight:this.options.fieldNormWeight})}add(t){if(!g(t)){return}this._docs.push(t);this._myIndex.add(t)}remove(t=(()=>false)){const e=[];for(let s=0,i=this._docs.length;s<i;s+=1){const n=this._docs[s];if(t(n,s)){this.removeAt(s);s-=1;i-=1;e.push(n)}}return e}removeAt(t){this._docs.splice(t,1);this._myIndex.removeAt(t)}getIndex(){return this._myIndex}search(t,{limit:e=-1}={}){const{includeMatches:s,includeScore:i,shouldSort:n,sortFn:r,ignoreFieldNorm:c}=this.options;let o=l(t)?l(this._docs[0])?this._searchStringList(t):this._searchObjectList(t):this._searchLogical(t);xt(o,{ignoreFieldNorm:c});if(n){o.sort(r)}if(h(e)&&e>-1){o=o.slice(0,e)}return wt(o,this._docs,{includeMatches:s,includeScore:i})}_searchStringList(t){const e=ht(t,this.options);const{records:s}=this._myIndex;const i=[];s.forEach((({v:t,i:s,n})=>{if(!g(t)){return}const{isMatch:r,score:c,indices:o}=e.searchIn(t);if(r){i.push({item:t,idx:s,matches:[{score:c,value:t,norm:n,indices:o}]})}}));return i}_searchLogical(t){const e=pt(t,this.options);const s=(t,e,i)=>{if(!t.children){const{keyId:s,searcher:n}=t;const r=this._findMatches({key:this._keyStore.get(s),value:this._myIndex.getValueForItemAtKeyId(e,s),searcher:n});if(r&&r.length){return[{idx:i,item:e,matches:r}]}return[]}const n=[];for(let r=0,c=t.children.length;r<c;r+=1){const c=t.children[r];const o=s(c,e,i);if(o.length){n.push(...o)}else if(t.operator===ut.AND){return[]}}return n};const i=this._myIndex.records;const n={};const r=[];i.forEach((({$:t,i})=>{if(g(t)){let c=s(e,t,i);if(c.length){if(!n[i]){n[i]={idx:i,item:t,matches:[]};r.push(n[i])}c.forEach((({matches:t})=>{n[i].matches.push(...t)}))}}}));return r}_searchObjectList(t){const e=ht(t,this.options);const{keys:s,records:i}=this._myIndex;const n=[];i.forEach((({$:t,i})=>{if(!g(t)){return}let r=[];s.forEach(((s,i)=>{r.push(...this._findMatches({key:s,value:t[i],searcher:e}))}));if(r.length){n.push({idx:i,item:t,matches:r})}}));return n}_findMatches({key:t,value:e,searcher:s}){if(!g(e)){return[]}let i=[];if(r(e)){e.forEach((({v:e,i:n,n:r})=>{if(!g(e)){return}const{isMatch:c,score:o,indices:a}=s.searchIn(e);if(c){i.push({score:o,key:t,value:e,idx:n,norm:r,indices:a})}}))}else{const{v:n,n:r}=e;const{isMatch:c,score:o,indices:a}=s.searchIn(n);if(c){i.push({score:o,key:t,value:n,norm:r,indices:a})}}return i}}Lt.version="6.5.3";Lt.createIndex=W;Lt.parseIndex=z;Lt.config=O;{Lt.parseQuery=pt}{lt(ot)}const bt=".sc-road-select-filter-h{--margin-top:3rem;position:relative;display:block}.select-filter-list.sc-road-select-filter{position:absolute;top:var(--margin-top);z-index:1;width:100%;max-height:16rem;padding:0.5rem 0;margin:0;overflow-y:scroll;font-family:var(--road-font, sans-serif);font-size:1rem;color:var(--road-on-surface);list-style-type:none;background:var(--road-surface);border-radius:0 0 0.25rem 0.25rem;box-shadow:var(--road-elevation-low)}.select-filter-list.not-active.sc-road-select-filter{opacity:0}.select-filter-item.sc-road-select-filter{display:flex;align-items:center;padding:0.75rem 1rem;cursor:pointer}.select-filter-item.active.sc-road-select-filter{outline:1px solid var(--road-input-outline-variant)}.select-filter-item.sc-road-select-filter:hover,.select-filter-item.sc-road-select-filter:focus,.select-filter-item.highlight.sc-road-select-filter{color:var(--road-on-primary);background:var(--road-primary)}";const $t=class{constructor(s){t(this,s);this.roadselected=e(this,"roadselected",7);this.roadSelected=e(this,"roadSelected",7);this.onClick=(t,e)=>{this.el.querySelector("road-input").value=e;if(document.getElementsByClassName("phone-number-label-icon").length>0){this.el.querySelector("road-icon").name="flag-"+e}this.isOpen=false;this.roadselected.emit({value:t.toString(),label:e});this.roadSelected.emit({value:t.toString(),label:e});this.activeIndex=-1};this.handleOptionMouseOver=t=>{this.activeIndex=t};this.handleOptionClick=(t,e)=>{this.onClick(t,e)};this.isOpen=false;this.currentValue="";this.activeIndex=-1;this.options=[];this.parameters={keys:["value","label"],threshold:.3,ignoreLocation:true};this.isActive=false;this.onlySelect=true}handleFocus(){this.isOpen=true;this.isActive=true}handleBlur(){this.isActive=false}handleChange(t){this.currentValue=t.detail.value.toLowerCase()}onClickOutside(t){if(this.isOpen&&!this.el.contains(t.target)){this.isOpen=false;this.isActive=false;const t=this.el.querySelector("road-input").value;if(this.onlySelect&&!this.options.some((e=>e["label"]===t))){this.el.querySelector("road-input").value=""}}}handleKeydown(t){if(this.isOpen){if(t.key==="ArrowDown"){t.preventDefault();this.activeIndex=(this.activeIndex+1)%this.filteredOptions.length}else if(t.key==="ArrowUp"){t.preventDefault();this.activeIndex=(this.activeIndex-1+this.filteredOptions.length)%this.filteredOptions.length}else if(t.key==="Enter"){t.preventDefault();const e=this.filteredOptions[this.activeIndex];if(e){this.onClick(e.item.value,e.item.label)}}}}get filteredOptions(){const t=new Lt(this.options,this.parameters);return this.currentValue===""?this.options.map(((t,e)=>({item:t,score:1,refIndex:e}))):t.search(this.currentValue)}render(){const t=this.filteredOptions;const e=this.isActive?"true":"false";const n=this.isActive?"":"not-active";return s(i,{"is-active":e},s("slot",null),this.isOpen&&s("ul",{class:`${n} select-filter-list`,role:"listbox"},t.map(((t,e)=>s("li",{class:`select-filter-item ${this.activeIndex===e?"active":""}`,role:"option","aria-selected":this.activeIndex===e?"true":"false",onClick:()=>this.handleOptionClick(t.item.value,t.item.label.replace(/(<([^>]+)>)/gi,"")),onMouseOver:()=>this.handleOptionMouseOver(e),innerHTML:t.item.label,tabindex:this.activeIndex===e?0:-1})))))}get el(){return n(this)}};$t.style=bt;export{$t as road_select_filter};
2
+ //# sourceMappingURL=p-0fd454dc.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["isArray","value","Array","getTag","INFINITY","baseToString","result","toString","isString","isNumber","isBoolean","isObjectLike","isObject","isDefined","undefined","isBlank","trim","length","Object","prototype","call","EXTENDED_SEARCH_UNAVAILABLE","INCORRECT_INDEX_TYPE","LOGICAL_SEARCH_INVALID_QUERY_FOR_KEY","key","PATTERN_LENGTH_TOO_LARGE","max","MISSING_KEY_PROPERTY","name","INVALID_KEY_WEIGHT_VALUE","hasOwn","hasOwnProperty","KeyStore","constructor","keys","this","_keys","_keyMap","totalWeight","forEach","obj","createKey","weight","push","id","get","keyId","toJSON","JSON","stringify","path","src","createKeyPath","createKeyId","Error","split","join","list","arr","deepGet","index","i","len","MatchOptions","includeMatches","findAllMatches","minMatchCharLength","BasicOptions","isCaseSensitive","includeScore","shouldSort","sortFn","a","b","score","idx","FuzzyOptions","location","threshold","distance","AdvancedOptions","useExtendedSearch","getFn","ignoreLocation","ignoreFieldNorm","fieldNormWeight","Config","SPACE","norm","mantissa","cache","Map","m","Math","pow","numTokens","match","has","n","parseFloat","round","set","clear","FuseIndex","isCreated","setIndexRecords","setSources","docs","records","setKeys","_keysMap","create","doc","docIndex","_addString","_addObject","add","size","removeAt","splice","getValueForItemAtKeyId","item","record","v","$","keyIndex","subRecords","stack","nestedArrIndex","pop","subRecord","k","createIndex","myIndex","map","parseIndex","data","computeScore$1","pattern","errors","currentLocation","expectedLocation","accuracy","proximity","abs","convertMaskToIndices","matchmask","indices","start","end","MAX_BITS","search","text","patternAlphabet","patternLen","textLen","min","currentThreshold","bestLocation","computeMatches","matchMask","indexOf","lastBitArr","finalScore","binMax","mask","binMin","binMid","floor","finish","bitArr","j","charMatch","charAt","isMatch","createPatternAlphabet","char","BitapSearch","options","toLowerCase","chunks","addChunk","startIndex","alphabet","remainder","substr","searchIn","allIndices","totalScore","hasMatches","BaseMatch","isMultiMatch","getMatch","multiRegex","isSingleMatch","singleRegex","exp","matches","ExactMatch","super","type","InverseExactMatch","PrefixExactMatch","startsWith","InversePrefixExactMatch","SuffixExactMatch","endsWith","InverseSuffixExactMatch","FuzzyMatch","_bitapSearch","IncludeMatch","searchers","searchersLen","SPACE_RE","OR_TOKEN","parseQuery","query","filter","results","queryItem","found","searcher","token","MultiMatchSet","Set","ExtendedSearch","condition","_","numMatches","qLen","pLen","registeredSearchers","register","args","createSearcher","searcherClass","LogicalOperator","AND","OR","KeyType","PATH","PATTERN","isExpression","isPath","isLeaf","convertToExplicit","parse","auto","next","isQueryPath","node","children","operator","computeScore","Number","EPSILON","transformMatches","refIndex","transformScore","format","transformers","transformer","Fuse","_keyStore","setCollection","_docs","_myIndex","remove","predicate","getIndex","limit","_searchStringList","_searchObjectList","_searchLogical","sort","slice","expression","evaluate","_findMatches","res","child","resultMap","expResults","version","config","selectFilterCss","SelectFilter","onClick","label","el","querySelector","document","getElementsByClassName","isOpen","roadselected","emit","roadSelected","activeIndex","handleOptionMouseOver","handleOptionClick","handleFocus","isActive","handleBlur","handleChange","event","currentValue","detail","onClickOutside","contains","target","onlySelect","some","option","handleKeydown","preventDefault","filteredOptions","activeOption","fuseSearch","parameters","render","notActive","h","Host","class","role","replace","onMouseOver","innerHTML","tabindex"],"sources":["node_modules/fuse.js/dist/fuse.esm.js","src/components/select-filter/select-filter.css?tag=road-select-filter&encapsulation=scoped","src/components/select-filter/select-filter.tsx"],"sourcesContent":["/**\n * Fuse.js v6.5.3 - Lightweight fuzzy-search (http://fusejs.io)\n *\n * Copyright (c) 2021 Kiro Risk (http://kiro.me)\n * All Rights Reserved. Apache Software License 2.0\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n */\n\nfunction isArray(value) {\n return !Array.isArray\n ? getTag(value) === '[object Array]'\n : Array.isArray(value)\n}\n\n// Adapted from: https://github.com/lodash/lodash/blob/master/.internal/baseToString.js\nconst INFINITY = 1 / 0;\nfunction baseToString(value) {\n // Exit early for strings to avoid a performance hit in some environments.\n if (typeof value == 'string') {\n return value\n }\n let result = value + '';\n return result == '0' && 1 / value == -INFINITY ? '-0' : result\n}\n\nfunction toString(value) {\n return value == null ? '' : baseToString(value)\n}\n\nfunction isString(value) {\n return typeof value === 'string'\n}\n\nfunction isNumber(value) {\n return typeof value === 'number'\n}\n\n// Adapted from: https://github.com/lodash/lodash/blob/master/isBoolean.js\nfunction isBoolean(value) {\n return (\n value === true ||\n value === false ||\n (isObjectLike(value) && getTag(value) == '[object Boolean]')\n )\n}\n\nfunction isObject(value) {\n return typeof value === 'object'\n}\n\n// Checks if `value` is object-like.\nfunction isObjectLike(value) {\n return isObject(value) && value !== null\n}\n\nfunction isDefined(value) {\n return value !== undefined && value !== null\n}\n\nfunction isBlank(value) {\n return !value.trim().length\n}\n\n// Gets the `toStringTag` of `value`.\n// Adapted from: https://github.com/lodash/lodash/blob/master/.internal/getTag.js\nfunction getTag(value) {\n return value == null\n ? value === undefined\n ? '[object Undefined]'\n : '[object Null]'\n : Object.prototype.toString.call(value)\n}\n\nconst EXTENDED_SEARCH_UNAVAILABLE = 'Extended search is not available';\n\nconst INCORRECT_INDEX_TYPE = \"Incorrect 'index' type\";\n\nconst LOGICAL_SEARCH_INVALID_QUERY_FOR_KEY = (key) =>\n `Invalid value for key ${key}`;\n\nconst PATTERN_LENGTH_TOO_LARGE = (max) =>\n `Pattern length exceeds max of ${max}.`;\n\nconst MISSING_KEY_PROPERTY = (name) => `Missing ${name} property in key`;\n\nconst INVALID_KEY_WEIGHT_VALUE = (key) =>\n `Property 'weight' in key '${key}' must be a positive integer`;\n\nconst hasOwn = Object.prototype.hasOwnProperty;\n\nclass KeyStore {\n constructor(keys) {\n this._keys = [];\n this._keyMap = {};\n\n let totalWeight = 0;\n\n keys.forEach((key) => {\n let obj = createKey(key);\n\n totalWeight += obj.weight;\n\n this._keys.push(obj);\n this._keyMap[obj.id] = obj;\n\n totalWeight += obj.weight;\n });\n\n // Normalize weights so that their sum is equal to 1\n this._keys.forEach((key) => {\n key.weight /= totalWeight;\n });\n }\n get(keyId) {\n return this._keyMap[keyId]\n }\n keys() {\n return this._keys\n }\n toJSON() {\n return JSON.stringify(this._keys)\n }\n}\n\nfunction createKey(key) {\n let path = null;\n let id = null;\n let src = null;\n let weight = 1;\n\n if (isString(key) || isArray(key)) {\n src = key;\n path = createKeyPath(key);\n id = createKeyId(key);\n } else {\n if (!hasOwn.call(key, 'name')) {\n throw new Error(MISSING_KEY_PROPERTY('name'))\n }\n\n const name = key.name;\n src = name;\n\n if (hasOwn.call(key, 'weight')) {\n weight = key.weight;\n\n if (weight <= 0) {\n throw new Error(INVALID_KEY_WEIGHT_VALUE(name))\n }\n }\n\n path = createKeyPath(name);\n id = createKeyId(name);\n }\n\n return { path, id, weight, src }\n}\n\nfunction createKeyPath(key) {\n return isArray(key) ? key : key.split('.')\n}\n\nfunction createKeyId(key) {\n return isArray(key) ? key.join('.') : key\n}\n\nfunction get(obj, path) {\n let list = [];\n let arr = false;\n\n const deepGet = (obj, path, index) => {\n if (!isDefined(obj)) {\n return\n }\n if (!path[index]) {\n // If there's no path left, we've arrived at the object we care about.\n list.push(obj);\n } else {\n let key = path[index];\n\n const value = obj[key];\n\n if (!isDefined(value)) {\n return\n }\n\n // If we're at the last value in the path, and if it's a string/number/bool,\n // add it to the list\n if (\n index === path.length - 1 &&\n (isString(value) || isNumber(value) || isBoolean(value))\n ) {\n list.push(toString(value));\n } else if (isArray(value)) {\n arr = true;\n // Search each item in the array.\n for (let i = 0, len = value.length; i < len; i += 1) {\n deepGet(value[i], path, index + 1);\n }\n } else if (path.length) {\n // An object. Recurse further.\n deepGet(value, path, index + 1);\n }\n }\n };\n\n // Backwards compatibility (since path used to be a string)\n deepGet(obj, isString(path) ? path.split('.') : path, 0);\n\n return arr ? list : list[0]\n}\n\nconst MatchOptions = {\n // Whether the matches should be included in the result set. When `true`, each record in the result\n // set will include the indices of the matched characters.\n // These can consequently be used for highlighting purposes.\n includeMatches: false,\n // When `true`, the matching function will continue to the end of a search pattern even if\n // a perfect match has already been located in the string.\n findAllMatches: false,\n // Minimum number of characters that must be matched before a result is considered a match\n minMatchCharLength: 1\n};\n\nconst BasicOptions = {\n // When `true`, the algorithm continues searching to the end of the input even if a perfect\n // match is found before the end of the same input.\n isCaseSensitive: false,\n // When true, the matching function will continue to the end of a search pattern even if\n includeScore: false,\n // List of properties that will be searched. This also supports nested properties.\n keys: [],\n // Whether to sort the result list, by score\n shouldSort: true,\n // Default sort function: sort by ascending score, ascending index\n sortFn: (a, b) =>\n a.score === b.score ? (a.idx < b.idx ? -1 : 1) : a.score < b.score ? -1 : 1\n};\n\nconst FuzzyOptions = {\n // Approximately where in the text is the pattern expected to be found?\n location: 0,\n // At what point does the match algorithm give up. A threshold of '0.0' requires a perfect match\n // (of both letters and location), a threshold of '1.0' would match anything.\n threshold: 0.6,\n // Determines how close the match must be to the fuzzy location (specified above).\n // An exact letter match which is 'distance' characters away from the fuzzy location\n // would score as a complete mismatch. A distance of '0' requires the match be at\n // the exact location specified, a threshold of '1000' would require a perfect match\n // to be within 800 characters of the fuzzy location to be found using a 0.8 threshold.\n distance: 100\n};\n\nconst AdvancedOptions = {\n // When `true`, it enables the use of unix-like search commands\n useExtendedSearch: false,\n // The get function to use when fetching an object's properties.\n // The default will search nested paths *ie foo.bar.baz*\n getFn: get,\n // When `true`, search will ignore `location` and `distance`, so it won't matter\n // where in the string the pattern appears.\n // More info: https://fusejs.io/concepts/scoring-theory.html#fuzziness-score\n ignoreLocation: false,\n // When `true`, the calculation for the relevance score (used for sorting) will\n // ignore the field-length norm.\n // More info: https://fusejs.io/concepts/scoring-theory.html#field-length-norm\n ignoreFieldNorm: false,\n // The weight to determine how much field length norm effects scoring.\n fieldNormWeight: 1\n};\n\nvar Config = {\n ...BasicOptions,\n ...MatchOptions,\n ...FuzzyOptions,\n ...AdvancedOptions\n};\n\nconst SPACE = /[^ ]+/g;\n\n// Field-length norm: the shorter the field, the higher the weight.\n// Set to 3 decimals to reduce index size.\nfunction norm(weight = 1, mantissa = 3) {\n const cache = new Map();\n const m = Math.pow(10, mantissa);\n\n return {\n get(value) {\n const numTokens = value.match(SPACE).length;\n\n if (cache.has(numTokens)) {\n return cache.get(numTokens)\n }\n\n // Default function is 1/sqrt(x), weight makes that variable\n const norm = 1 / Math.pow(numTokens, 0.5 * weight);\n\n // In place of `toFixed(mantissa)`, for faster computation\n const n = parseFloat(Math.round(norm * m) / m);\n\n cache.set(numTokens, n);\n\n return n\n },\n clear() {\n cache.clear();\n }\n }\n}\n\nclass FuseIndex {\n constructor({\n getFn = Config.getFn,\n fieldNormWeight = Config.fieldNormWeight\n } = {}) {\n this.norm = norm(fieldNormWeight, 3);\n this.getFn = getFn;\n this.isCreated = false;\n\n this.setIndexRecords();\n }\n setSources(docs = []) {\n this.docs = docs;\n }\n setIndexRecords(records = []) {\n this.records = records;\n }\n setKeys(keys = []) {\n this.keys = keys;\n this._keysMap = {};\n keys.forEach((key, idx) => {\n this._keysMap[key.id] = idx;\n });\n }\n create() {\n if (this.isCreated || !this.docs.length) {\n return\n }\n\n this.isCreated = true;\n\n // List is Array<String>\n if (isString(this.docs[0])) {\n this.docs.forEach((doc, docIndex) => {\n this._addString(doc, docIndex);\n });\n } else {\n // List is Array<Object>\n this.docs.forEach((doc, docIndex) => {\n this._addObject(doc, docIndex);\n });\n }\n\n this.norm.clear();\n }\n // Adds a doc to the end of the index\n add(doc) {\n const idx = this.size();\n\n if (isString(doc)) {\n this._addString(doc, idx);\n } else {\n this._addObject(doc, idx);\n }\n }\n // Removes the doc at the specified index of the index\n removeAt(idx) {\n this.records.splice(idx, 1);\n\n // Change ref index of every subsquent doc\n for (let i = idx, len = this.size(); i < len; i += 1) {\n this.records[i].i -= 1;\n }\n }\n getValueForItemAtKeyId(item, keyId) {\n return item[this._keysMap[keyId]]\n }\n size() {\n return this.records.length\n }\n _addString(doc, docIndex) {\n if (!isDefined(doc) || isBlank(doc)) {\n return\n }\n\n let record = {\n v: doc,\n i: docIndex,\n n: this.norm.get(doc)\n };\n\n this.records.push(record);\n }\n _addObject(doc, docIndex) {\n let record = { i: docIndex, $: {} };\n\n // Iterate over every key (i.e, path), and fetch the value at that key\n this.keys.forEach((key, keyIndex) => {\n // console.log(key)\n let value = this.getFn(doc, key.path);\n\n if (!isDefined(value)) {\n return\n }\n\n if (isArray(value)) {\n let subRecords = [];\n const stack = [{ nestedArrIndex: -1, value }];\n\n while (stack.length) {\n const { nestedArrIndex, value } = stack.pop();\n\n if (!isDefined(value)) {\n continue\n }\n\n if (isString(value) && !isBlank(value)) {\n let subRecord = {\n v: value,\n i: nestedArrIndex,\n n: this.norm.get(value)\n };\n\n subRecords.push(subRecord);\n } else if (isArray(value)) {\n value.forEach((item, k) => {\n stack.push({\n nestedArrIndex: k,\n value: item\n });\n });\n } else ;\n }\n record.$[keyIndex] = subRecords;\n } else if (!isBlank(value)) {\n let subRecord = {\n v: value,\n n: this.norm.get(value)\n };\n\n record.$[keyIndex] = subRecord;\n }\n });\n\n this.records.push(record);\n }\n toJSON() {\n return {\n keys: this.keys,\n records: this.records\n }\n }\n}\n\nfunction createIndex(\n keys,\n docs,\n { getFn = Config.getFn, fieldNormWeight = Config.fieldNormWeight } = {}\n) {\n const myIndex = new FuseIndex({ getFn, fieldNormWeight });\n myIndex.setKeys(keys.map(createKey));\n myIndex.setSources(docs);\n myIndex.create();\n return myIndex\n}\n\nfunction parseIndex(\n data,\n { getFn = Config.getFn, fieldNormWeight = Config.fieldNormWeight } = {}\n) {\n const { keys, records } = data;\n const myIndex = new FuseIndex({ getFn, fieldNormWeight });\n myIndex.setKeys(keys);\n myIndex.setIndexRecords(records);\n return myIndex\n}\n\nfunction computeScore$1(\n pattern,\n {\n errors = 0,\n currentLocation = 0,\n expectedLocation = 0,\n distance = Config.distance,\n ignoreLocation = Config.ignoreLocation\n } = {}\n) {\n const accuracy = errors / pattern.length;\n\n if (ignoreLocation) {\n return accuracy\n }\n\n const proximity = Math.abs(expectedLocation - currentLocation);\n\n if (!distance) {\n // Dodge divide by zero error.\n return proximity ? 1.0 : accuracy\n }\n\n return accuracy + proximity / distance\n}\n\nfunction convertMaskToIndices(\n matchmask = [],\n minMatchCharLength = Config.minMatchCharLength\n) {\n let indices = [];\n let start = -1;\n let end = -1;\n let i = 0;\n\n for (let len = matchmask.length; i < len; i += 1) {\n let match = matchmask[i];\n if (match && start === -1) {\n start = i;\n } else if (!match && start !== -1) {\n end = i - 1;\n if (end - start + 1 >= minMatchCharLength) {\n indices.push([start, end]);\n }\n start = -1;\n }\n }\n\n // (i-1 - start) + 1 => i - start\n if (matchmask[i - 1] && i - start >= minMatchCharLength) {\n indices.push([start, i - 1]);\n }\n\n return indices\n}\n\n// Machine word size\nconst MAX_BITS = 32;\n\nfunction search(\n text,\n pattern,\n patternAlphabet,\n {\n location = Config.location,\n distance = Config.distance,\n threshold = Config.threshold,\n findAllMatches = Config.findAllMatches,\n minMatchCharLength = Config.minMatchCharLength,\n includeMatches = Config.includeMatches,\n ignoreLocation = Config.ignoreLocation\n } = {}\n) {\n if (pattern.length > MAX_BITS) {\n throw new Error(PATTERN_LENGTH_TOO_LARGE(MAX_BITS))\n }\n\n const patternLen = pattern.length;\n // Set starting location at beginning text and initialize the alphabet.\n const textLen = text.length;\n // Handle the case when location > text.length\n const expectedLocation = Math.max(0, Math.min(location, textLen));\n // Highest score beyond which we give up.\n let currentThreshold = threshold;\n // Is there a nearby exact match? (speedup)\n let bestLocation = expectedLocation;\n\n // Performance: only computer matches when the minMatchCharLength > 1\n // OR if `includeMatches` is true.\n const computeMatches = minMatchCharLength > 1 || includeMatches;\n // A mask of the matches, used for building the indices\n const matchMask = computeMatches ? Array(textLen) : [];\n\n let index;\n\n // Get all exact matches, here for speed up\n while ((index = text.indexOf(pattern, bestLocation)) > -1) {\n let score = computeScore$1(pattern, {\n currentLocation: index,\n expectedLocation,\n distance,\n ignoreLocation\n });\n\n currentThreshold = Math.min(score, currentThreshold);\n bestLocation = index + patternLen;\n\n if (computeMatches) {\n let i = 0;\n while (i < patternLen) {\n matchMask[index + i] = 1;\n i += 1;\n }\n }\n }\n\n // Reset the best location\n bestLocation = -1;\n\n let lastBitArr = [];\n let finalScore = 1;\n let binMax = patternLen + textLen;\n\n const mask = 1 << (patternLen - 1);\n\n for (let i = 0; i < patternLen; i += 1) {\n // Scan for the best match; each iteration allows for one more error.\n // Run a binary search to determine how far from the match location we can stray\n // at this error level.\n let binMin = 0;\n let binMid = binMax;\n\n while (binMin < binMid) {\n const score = computeScore$1(pattern, {\n errors: i,\n currentLocation: expectedLocation + binMid,\n expectedLocation,\n distance,\n ignoreLocation\n });\n\n if (score <= currentThreshold) {\n binMin = binMid;\n } else {\n binMax = binMid;\n }\n\n binMid = Math.floor((binMax - binMin) / 2 + binMin);\n }\n\n // Use the result from this iteration as the maximum for the next.\n binMax = binMid;\n\n let start = Math.max(1, expectedLocation - binMid + 1);\n let finish = findAllMatches\n ? textLen\n : Math.min(expectedLocation + binMid, textLen) + patternLen;\n\n // Initialize the bit array\n let bitArr = Array(finish + 2);\n\n bitArr[finish + 1] = (1 << i) - 1;\n\n for (let j = finish; j >= start; j -= 1) {\n let currentLocation = j - 1;\n let charMatch = patternAlphabet[text.charAt(currentLocation)];\n\n if (computeMatches) {\n // Speed up: quick bool to int conversion (i.e, `charMatch ? 1 : 0`)\n matchMask[currentLocation] = +!!charMatch;\n }\n\n // First pass: exact match\n bitArr[j] = ((bitArr[j + 1] << 1) | 1) & charMatch;\n\n // Subsequent passes: fuzzy match\n if (i) {\n bitArr[j] |=\n ((lastBitArr[j + 1] | lastBitArr[j]) << 1) | 1 | lastBitArr[j + 1];\n }\n\n if (bitArr[j] & mask) {\n finalScore = computeScore$1(pattern, {\n errors: i,\n currentLocation,\n expectedLocation,\n distance,\n ignoreLocation\n });\n\n // This match will almost certainly be better than any existing match.\n // But check anyway.\n if (finalScore <= currentThreshold) {\n // Indeed it is\n currentThreshold = finalScore;\n bestLocation = currentLocation;\n\n // Already passed `loc`, downhill from here on in.\n if (bestLocation <= expectedLocation) {\n break\n }\n\n // When passing `bestLocation`, don't exceed our current distance from `expectedLocation`.\n start = Math.max(1, 2 * expectedLocation - bestLocation);\n }\n }\n }\n\n // No hope for a (better) match at greater error levels.\n const score = computeScore$1(pattern, {\n errors: i + 1,\n currentLocation: expectedLocation,\n expectedLocation,\n distance,\n ignoreLocation\n });\n\n if (score > currentThreshold) {\n break\n }\n\n lastBitArr = bitArr;\n }\n\n const result = {\n isMatch: bestLocation >= 0,\n // Count exact matches (those with a score of 0) to be \"almost\" exact\n score: Math.max(0.001, finalScore)\n };\n\n if (computeMatches) {\n const indices = convertMaskToIndices(matchMask, minMatchCharLength);\n if (!indices.length) {\n result.isMatch = false;\n } else if (includeMatches) {\n result.indices = indices;\n }\n }\n\n return result\n}\n\nfunction createPatternAlphabet(pattern) {\n let mask = {};\n\n for (let i = 0, len = pattern.length; i < len; i += 1) {\n const char = pattern.charAt(i);\n mask[char] = (mask[char] || 0) | (1 << (len - i - 1));\n }\n\n return mask\n}\n\nclass BitapSearch {\n constructor(\n pattern,\n {\n location = Config.location,\n threshold = Config.threshold,\n distance = Config.distance,\n includeMatches = Config.includeMatches,\n findAllMatches = Config.findAllMatches,\n minMatchCharLength = Config.minMatchCharLength,\n isCaseSensitive = Config.isCaseSensitive,\n ignoreLocation = Config.ignoreLocation\n } = {}\n ) {\n this.options = {\n location,\n threshold,\n distance,\n includeMatches,\n findAllMatches,\n minMatchCharLength,\n isCaseSensitive,\n ignoreLocation\n };\n\n this.pattern = isCaseSensitive ? pattern : pattern.toLowerCase();\n\n this.chunks = [];\n\n if (!this.pattern.length) {\n return\n }\n\n const addChunk = (pattern, startIndex) => {\n this.chunks.push({\n pattern,\n alphabet: createPatternAlphabet(pattern),\n startIndex\n });\n };\n\n const len = this.pattern.length;\n\n if (len > MAX_BITS) {\n let i = 0;\n const remainder = len % MAX_BITS;\n const end = len - remainder;\n\n while (i < end) {\n addChunk(this.pattern.substr(i, MAX_BITS), i);\n i += MAX_BITS;\n }\n\n if (remainder) {\n const startIndex = len - MAX_BITS;\n addChunk(this.pattern.substr(startIndex), startIndex);\n }\n } else {\n addChunk(this.pattern, 0);\n }\n }\n\n searchIn(text) {\n const { isCaseSensitive, includeMatches } = this.options;\n\n if (!isCaseSensitive) {\n text = text.toLowerCase();\n }\n\n // Exact match\n if (this.pattern === text) {\n let result = {\n isMatch: true,\n score: 0\n };\n\n if (includeMatches) {\n result.indices = [[0, text.length - 1]];\n }\n\n return result\n }\n\n // Otherwise, use Bitap algorithm\n const {\n location,\n distance,\n threshold,\n findAllMatches,\n minMatchCharLength,\n ignoreLocation\n } = this.options;\n\n let allIndices = [];\n let totalScore = 0;\n let hasMatches = false;\n\n this.chunks.forEach(({ pattern, alphabet, startIndex }) => {\n const { isMatch, score, indices } = search(text, pattern, alphabet, {\n location: location + startIndex,\n distance,\n threshold,\n findAllMatches,\n minMatchCharLength,\n includeMatches,\n ignoreLocation\n });\n\n if (isMatch) {\n hasMatches = true;\n }\n\n totalScore += score;\n\n if (isMatch && indices) {\n allIndices = [...allIndices, ...indices];\n }\n });\n\n let result = {\n isMatch: hasMatches,\n score: hasMatches ? totalScore / this.chunks.length : 1\n };\n\n if (hasMatches && includeMatches) {\n result.indices = allIndices;\n }\n\n return result\n }\n}\n\nclass BaseMatch {\n constructor(pattern) {\n this.pattern = pattern;\n }\n static isMultiMatch(pattern) {\n return getMatch(pattern, this.multiRegex)\n }\n static isSingleMatch(pattern) {\n return getMatch(pattern, this.singleRegex)\n }\n search(/*text*/) {}\n}\n\nfunction getMatch(pattern, exp) {\n const matches = pattern.match(exp);\n return matches ? matches[1] : null\n}\n\n// Token: 'file\n\nclass ExactMatch extends BaseMatch {\n constructor(pattern) {\n super(pattern);\n }\n static get type() {\n return 'exact'\n }\n static get multiRegex() {\n return /^=\"(.*)\"$/\n }\n static get singleRegex() {\n return /^=(.*)$/\n }\n search(text) {\n const isMatch = text === this.pattern;\n\n return {\n isMatch,\n score: isMatch ? 0 : 1,\n indices: [0, this.pattern.length - 1]\n }\n }\n}\n\n// Token: !fire\n\nclass InverseExactMatch extends BaseMatch {\n constructor(pattern) {\n super(pattern);\n }\n static get type() {\n return 'inverse-exact'\n }\n static get multiRegex() {\n return /^!\"(.*)\"$/\n }\n static get singleRegex() {\n return /^!(.*)$/\n }\n search(text) {\n const index = text.indexOf(this.pattern);\n const isMatch = index === -1;\n\n return {\n isMatch,\n score: isMatch ? 0 : 1,\n indices: [0, text.length - 1]\n }\n }\n}\n\n// Token: ^file\n\nclass PrefixExactMatch extends BaseMatch {\n constructor(pattern) {\n super(pattern);\n }\n static get type() {\n return 'prefix-exact'\n }\n static get multiRegex() {\n return /^\\^\"(.*)\"$/\n }\n static get singleRegex() {\n return /^\\^(.*)$/\n }\n search(text) {\n const isMatch = text.startsWith(this.pattern);\n\n return {\n isMatch,\n score: isMatch ? 0 : 1,\n indices: [0, this.pattern.length - 1]\n }\n }\n}\n\n// Token: !^fire\n\nclass InversePrefixExactMatch extends BaseMatch {\n constructor(pattern) {\n super(pattern);\n }\n static get type() {\n return 'inverse-prefix-exact'\n }\n static get multiRegex() {\n return /^!\\^\"(.*)\"$/\n }\n static get singleRegex() {\n return /^!\\^(.*)$/\n }\n search(text) {\n const isMatch = !text.startsWith(this.pattern);\n\n return {\n isMatch,\n score: isMatch ? 0 : 1,\n indices: [0, text.length - 1]\n }\n }\n}\n\n// Token: .file$\n\nclass SuffixExactMatch extends BaseMatch {\n constructor(pattern) {\n super(pattern);\n }\n static get type() {\n return 'suffix-exact'\n }\n static get multiRegex() {\n return /^\"(.*)\"\\$$/\n }\n static get singleRegex() {\n return /^(.*)\\$$/\n }\n search(text) {\n const isMatch = text.endsWith(this.pattern);\n\n return {\n isMatch,\n score: isMatch ? 0 : 1,\n indices: [text.length - this.pattern.length, text.length - 1]\n }\n }\n}\n\n// Token: !.file$\n\nclass InverseSuffixExactMatch extends BaseMatch {\n constructor(pattern) {\n super(pattern);\n }\n static get type() {\n return 'inverse-suffix-exact'\n }\n static get multiRegex() {\n return /^!\"(.*)\"\\$$/\n }\n static get singleRegex() {\n return /^!(.*)\\$$/\n }\n search(text) {\n const isMatch = !text.endsWith(this.pattern);\n return {\n isMatch,\n score: isMatch ? 0 : 1,\n indices: [0, text.length - 1]\n }\n }\n}\n\nclass FuzzyMatch extends BaseMatch {\n constructor(\n pattern,\n {\n location = Config.location,\n threshold = Config.threshold,\n distance = Config.distance,\n includeMatches = Config.includeMatches,\n findAllMatches = Config.findAllMatches,\n minMatchCharLength = Config.minMatchCharLength,\n isCaseSensitive = Config.isCaseSensitive,\n ignoreLocation = Config.ignoreLocation\n } = {}\n ) {\n super(pattern);\n this._bitapSearch = new BitapSearch(pattern, {\n location,\n threshold,\n distance,\n includeMatches,\n findAllMatches,\n minMatchCharLength,\n isCaseSensitive,\n ignoreLocation\n });\n }\n static get type() {\n return 'fuzzy'\n }\n static get multiRegex() {\n return /^\"(.*)\"$/\n }\n static get singleRegex() {\n return /^(.*)$/\n }\n search(text) {\n return this._bitapSearch.searchIn(text)\n }\n}\n\n// Token: 'file\n\nclass IncludeMatch extends BaseMatch {\n constructor(pattern) {\n super(pattern);\n }\n static get type() {\n return 'include'\n }\n static get multiRegex() {\n return /^'\"(.*)\"$/\n }\n static get singleRegex() {\n return /^'(.*)$/\n }\n search(text) {\n let location = 0;\n let index;\n\n const indices = [];\n const patternLen = this.pattern.length;\n\n // Get all exact matches\n while ((index = text.indexOf(this.pattern, location)) > -1) {\n location = index + patternLen;\n indices.push([index, location - 1]);\n }\n\n const isMatch = !!indices.length;\n\n return {\n isMatch,\n score: isMatch ? 0 : 1,\n indices\n }\n }\n}\n\n// ❗Order is important. DO NOT CHANGE.\nconst searchers = [\n ExactMatch,\n IncludeMatch,\n PrefixExactMatch,\n InversePrefixExactMatch,\n InverseSuffixExactMatch,\n SuffixExactMatch,\n InverseExactMatch,\n FuzzyMatch\n];\n\nconst searchersLen = searchers.length;\n\n// Regex to split by spaces, but keep anything in quotes together\nconst SPACE_RE = / +(?=([^\\\"]*\\\"[^\\\"]*\\\")*[^\\\"]*$)/;\nconst OR_TOKEN = '|';\n\n// Return a 2D array representation of the query, for simpler parsing.\n// Example:\n// \"^core go$ | rb$ | py$ xy$\" => [[\"^core\", \"go$\"], [\"rb$\"], [\"py$\", \"xy$\"]]\nfunction parseQuery(pattern, options = {}) {\n return pattern.split(OR_TOKEN).map((item) => {\n let query = item\n .trim()\n .split(SPACE_RE)\n .filter((item) => item && !!item.trim());\n\n let results = [];\n for (let i = 0, len = query.length; i < len; i += 1) {\n const queryItem = query[i];\n\n // 1. Handle multiple query match (i.e, once that are quoted, like `\"hello world\"`)\n let found = false;\n let idx = -1;\n while (!found && ++idx < searchersLen) {\n const searcher = searchers[idx];\n let token = searcher.isMultiMatch(queryItem);\n if (token) {\n results.push(new searcher(token, options));\n found = true;\n }\n }\n\n if (found) {\n continue\n }\n\n // 2. Handle single query matches (i.e, once that are *not* quoted)\n idx = -1;\n while (++idx < searchersLen) {\n const searcher = searchers[idx];\n let token = searcher.isSingleMatch(queryItem);\n if (token) {\n results.push(new searcher(token, options));\n break\n }\n }\n }\n\n return results\n })\n}\n\n// These extended matchers can return an array of matches, as opposed\n// to a singl match\nconst MultiMatchSet = new Set([FuzzyMatch.type, IncludeMatch.type]);\n\n/**\n * Command-like searching\n * ======================\n *\n * Given multiple search terms delimited by spaces.e.g. `^jscript .python$ ruby !java`,\n * search in a given text.\n *\n * Search syntax:\n *\n * | Token | Match type | Description |\n * | ----------- | -------------------------- | -------------------------------------- |\n * | `jscript` | fuzzy-match | Items that fuzzy match `jscript` |\n * | `=scheme` | exact-match | Items that are `scheme` |\n * | `'python` | include-match | Items that include `python` |\n * | `!ruby` | inverse-exact-match | Items that do not include `ruby` |\n * | `^java` | prefix-exact-match | Items that start with `java` |\n * | `!^earlang` | inverse-prefix-exact-match | Items that do not start with `earlang` |\n * | `.js$` | suffix-exact-match | Items that end with `.js` |\n * | `!.go$` | inverse-suffix-exact-match | Items that do not end with `.go` |\n *\n * A single pipe character acts as an OR operator. For example, the following\n * query matches entries that start with `core` and end with either`go`, `rb`,\n * or`py`.\n *\n * ```\n * ^core go$ | rb$ | py$\n * ```\n */\nclass ExtendedSearch {\n constructor(\n pattern,\n {\n isCaseSensitive = Config.isCaseSensitive,\n includeMatches = Config.includeMatches,\n minMatchCharLength = Config.minMatchCharLength,\n ignoreLocation = Config.ignoreLocation,\n findAllMatches = Config.findAllMatches,\n location = Config.location,\n threshold = Config.threshold,\n distance = Config.distance\n } = {}\n ) {\n this.query = null;\n this.options = {\n isCaseSensitive,\n includeMatches,\n minMatchCharLength,\n findAllMatches,\n ignoreLocation,\n location,\n threshold,\n distance\n };\n\n this.pattern = isCaseSensitive ? pattern : pattern.toLowerCase();\n this.query = parseQuery(this.pattern, this.options);\n }\n\n static condition(_, options) {\n return options.useExtendedSearch\n }\n\n searchIn(text) {\n const query = this.query;\n\n if (!query) {\n return {\n isMatch: false,\n score: 1\n }\n }\n\n const { includeMatches, isCaseSensitive } = this.options;\n\n text = isCaseSensitive ? text : text.toLowerCase();\n\n let numMatches = 0;\n let allIndices = [];\n let totalScore = 0;\n\n // ORs\n for (let i = 0, qLen = query.length; i < qLen; i += 1) {\n const searchers = query[i];\n\n // Reset indices\n allIndices.length = 0;\n numMatches = 0;\n\n // ANDs\n for (let j = 0, pLen = searchers.length; j < pLen; j += 1) {\n const searcher = searchers[j];\n const { isMatch, indices, score } = searcher.search(text);\n\n if (isMatch) {\n numMatches += 1;\n totalScore += score;\n if (includeMatches) {\n const type = searcher.constructor.type;\n if (MultiMatchSet.has(type)) {\n allIndices = [...allIndices, ...indices];\n } else {\n allIndices.push(indices);\n }\n }\n } else {\n totalScore = 0;\n numMatches = 0;\n allIndices.length = 0;\n break\n }\n }\n\n // OR condition, so if TRUE, return\n if (numMatches) {\n let result = {\n isMatch: true,\n score: totalScore / numMatches\n };\n\n if (includeMatches) {\n result.indices = allIndices;\n }\n\n return result\n }\n }\n\n // Nothing was matched\n return {\n isMatch: false,\n score: 1\n }\n }\n}\n\nconst registeredSearchers = [];\n\nfunction register(...args) {\n registeredSearchers.push(...args);\n}\n\nfunction createSearcher(pattern, options) {\n for (let i = 0, len = registeredSearchers.length; i < len; i += 1) {\n let searcherClass = registeredSearchers[i];\n if (searcherClass.condition(pattern, options)) {\n return new searcherClass(pattern, options)\n }\n }\n\n return new BitapSearch(pattern, options)\n}\n\nconst LogicalOperator = {\n AND: '$and',\n OR: '$or'\n};\n\nconst KeyType = {\n PATH: '$path',\n PATTERN: '$val'\n};\n\nconst isExpression = (query) =>\n !!(query[LogicalOperator.AND] || query[LogicalOperator.OR]);\n\nconst isPath = (query) => !!query[KeyType.PATH];\n\nconst isLeaf = (query) =>\n !isArray(query) && isObject(query) && !isExpression(query);\n\nconst convertToExplicit = (query) => ({\n [LogicalOperator.AND]: Object.keys(query).map((key) => ({\n [key]: query[key]\n }))\n});\n\n// When `auto` is `true`, the parse function will infer and initialize and add\n// the appropriate `Searcher` instance\nfunction parse(query, options, { auto = true } = {}) {\n const next = (query) => {\n let keys = Object.keys(query);\n\n const isQueryPath = isPath(query);\n\n if (!isQueryPath && keys.length > 1 && !isExpression(query)) {\n return next(convertToExplicit(query))\n }\n\n if (isLeaf(query)) {\n const key = isQueryPath ? query[KeyType.PATH] : keys[0];\n\n const pattern = isQueryPath ? query[KeyType.PATTERN] : query[key];\n\n if (!isString(pattern)) {\n throw new Error(LOGICAL_SEARCH_INVALID_QUERY_FOR_KEY(key))\n }\n\n const obj = {\n keyId: createKeyId(key),\n pattern\n };\n\n if (auto) {\n obj.searcher = createSearcher(pattern, options);\n }\n\n return obj\n }\n\n let node = {\n children: [],\n operator: keys[0]\n };\n\n keys.forEach((key) => {\n const value = query[key];\n\n if (isArray(value)) {\n value.forEach((item) => {\n node.children.push(next(item));\n });\n }\n });\n\n return node\n };\n\n if (!isExpression(query)) {\n query = convertToExplicit(query);\n }\n\n return next(query)\n}\n\n// Practical scoring function\nfunction computeScore(\n results,\n { ignoreFieldNorm = Config.ignoreFieldNorm }\n) {\n results.forEach((result) => {\n let totalScore = 1;\n\n result.matches.forEach(({ key, norm, score }) => {\n const weight = key ? key.weight : null;\n\n totalScore *= Math.pow(\n score === 0 && weight ? Number.EPSILON : score,\n (weight || 1) * (ignoreFieldNorm ? 1 : norm)\n );\n });\n\n result.score = totalScore;\n });\n}\n\nfunction transformMatches(result, data) {\n const matches = result.matches;\n data.matches = [];\n\n if (!isDefined(matches)) {\n return\n }\n\n matches.forEach((match) => {\n if (!isDefined(match.indices) || !match.indices.length) {\n return\n }\n\n const { indices, value } = match;\n\n let obj = {\n indices,\n value\n };\n\n if (match.key) {\n obj.key = match.key.src;\n }\n\n if (match.idx > -1) {\n obj.refIndex = match.idx;\n }\n\n data.matches.push(obj);\n });\n}\n\nfunction transformScore(result, data) {\n data.score = result.score;\n}\n\nfunction format(\n results,\n docs,\n {\n includeMatches = Config.includeMatches,\n includeScore = Config.includeScore\n } = {}\n) {\n const transformers = [];\n\n if (includeMatches) transformers.push(transformMatches);\n if (includeScore) transformers.push(transformScore);\n\n return results.map((result) => {\n const { idx } = result;\n\n const data = {\n item: docs[idx],\n refIndex: idx\n };\n\n if (transformers.length) {\n transformers.forEach((transformer) => {\n transformer(result, data);\n });\n }\n\n return data\n })\n}\n\nclass Fuse {\n constructor(docs, options = {}, index) {\n this.options = { ...Config, ...options };\n\n if (\n this.options.useExtendedSearch &&\n !true\n ) {\n throw new Error(EXTENDED_SEARCH_UNAVAILABLE)\n }\n\n this._keyStore = new KeyStore(this.options.keys);\n\n this.setCollection(docs, index);\n }\n\n setCollection(docs, index) {\n this._docs = docs;\n\n if (index && !(index instanceof FuseIndex)) {\n throw new Error(INCORRECT_INDEX_TYPE)\n }\n\n this._myIndex =\n index ||\n createIndex(this.options.keys, this._docs, {\n getFn: this.options.getFn,\n fieldNormWeight: this.options.fieldNormWeight\n });\n }\n\n add(doc) {\n if (!isDefined(doc)) {\n return\n }\n\n this._docs.push(doc);\n this._myIndex.add(doc);\n }\n\n remove(predicate = (/* doc, idx */) => false) {\n const results = [];\n\n for (let i = 0, len = this._docs.length; i < len; i += 1) {\n const doc = this._docs[i];\n if (predicate(doc, i)) {\n this.removeAt(i);\n i -= 1;\n len -= 1;\n\n results.push(doc);\n }\n }\n\n return results\n }\n\n removeAt(idx) {\n this._docs.splice(idx, 1);\n this._myIndex.removeAt(idx);\n }\n\n getIndex() {\n return this._myIndex\n }\n\n search(query, { limit = -1 } = {}) {\n const {\n includeMatches,\n includeScore,\n shouldSort,\n sortFn,\n ignoreFieldNorm\n } = this.options;\n\n let results = isString(query)\n ? isString(this._docs[0])\n ? this._searchStringList(query)\n : this._searchObjectList(query)\n : this._searchLogical(query);\n\n computeScore(results, { ignoreFieldNorm });\n\n if (shouldSort) {\n results.sort(sortFn);\n }\n\n if (isNumber(limit) && limit > -1) {\n results = results.slice(0, limit);\n }\n\n return format(results, this._docs, {\n includeMatches,\n includeScore\n })\n }\n\n _searchStringList(query) {\n const searcher = createSearcher(query, this.options);\n const { records } = this._myIndex;\n const results = [];\n\n // Iterate over every string in the index\n records.forEach(({ v: text, i: idx, n: norm }) => {\n if (!isDefined(text)) {\n return\n }\n\n const { isMatch, score, indices } = searcher.searchIn(text);\n\n if (isMatch) {\n results.push({\n item: text,\n idx,\n matches: [{ score, value: text, norm, indices }]\n });\n }\n });\n\n return results\n }\n\n _searchLogical(query) {\n\n const expression = parse(query, this.options);\n\n const evaluate = (node, item, idx) => {\n if (!node.children) {\n const { keyId, searcher } = node;\n\n const matches = this._findMatches({\n key: this._keyStore.get(keyId),\n value: this._myIndex.getValueForItemAtKeyId(item, keyId),\n searcher\n });\n\n if (matches && matches.length) {\n return [\n {\n idx,\n item,\n matches\n }\n ]\n }\n\n return []\n }\n\n const res = [];\n for (let i = 0, len = node.children.length; i < len; i += 1) {\n const child = node.children[i];\n const result = evaluate(child, item, idx);\n if (result.length) {\n res.push(...result);\n } else if (node.operator === LogicalOperator.AND) {\n return []\n }\n }\n return res\n };\n\n const records = this._myIndex.records;\n const resultMap = {};\n const results = [];\n\n records.forEach(({ $: item, i: idx }) => {\n if (isDefined(item)) {\n let expResults = evaluate(expression, item, idx);\n\n if (expResults.length) {\n // Dedupe when adding\n if (!resultMap[idx]) {\n resultMap[idx] = { idx, item, matches: [] };\n results.push(resultMap[idx]);\n }\n expResults.forEach(({ matches }) => {\n resultMap[idx].matches.push(...matches);\n });\n }\n }\n });\n\n return results\n }\n\n _searchObjectList(query) {\n const searcher = createSearcher(query, this.options);\n const { keys, records } = this._myIndex;\n const results = [];\n\n // List is Array<Object>\n records.forEach(({ $: item, i: idx }) => {\n if (!isDefined(item)) {\n return\n }\n\n let matches = [];\n\n // Iterate over every key (i.e, path), and fetch the value at that key\n keys.forEach((key, keyIndex) => {\n matches.push(\n ...this._findMatches({\n key,\n value: item[keyIndex],\n searcher\n })\n );\n });\n\n if (matches.length) {\n results.push({\n idx,\n item,\n matches\n });\n }\n });\n\n return results\n }\n _findMatches({ key, value, searcher }) {\n if (!isDefined(value)) {\n return []\n }\n\n let matches = [];\n\n if (isArray(value)) {\n value.forEach(({ v: text, i: idx, n: norm }) => {\n if (!isDefined(text)) {\n return\n }\n\n const { isMatch, score, indices } = searcher.searchIn(text);\n\n if (isMatch) {\n matches.push({\n score,\n key,\n value: text,\n idx,\n norm,\n indices\n });\n }\n });\n } else {\n const { v: text, n: norm } = value;\n\n const { isMatch, score, indices } = searcher.searchIn(text);\n\n if (isMatch) {\n matches.push({ score, key, value: text, norm, indices });\n }\n }\n\n return matches\n }\n}\n\nFuse.version = '6.5.3';\nFuse.createIndex = createIndex;\nFuse.parseIndex = parseIndex;\nFuse.config = Config;\n\n{\n Fuse.parseQuery = parse;\n}\n\n{\n register(ExtendedSearch);\n}\n\nexport { Fuse as default };\n","/*\n * Autocomplete\n *\n * Autocomplete layer for fields\n *\n * Index\n * - List\n * - Item\n */\n\n/**\n * @prop --margin-top: margin top of the select-filter (should equal the height of the field)\n */\n\n:host {\n --margin-top: 3rem;\n\n position: relative;\n display: block;\n}\n\n/* LIST\n -------------------- */\n\n.select-filter-list {\n position: absolute;\n top: var(--margin-top);\n z-index: 1;\n width: 100%;\n max-height: 16rem;\n padding: 0.5rem 0;\n margin: 0;\n overflow-y: scroll;\n font-family: var(--road-font, sans-serif);\n font-size: 1rem;\n color: var(--road-on-surface);\n list-style-type: none;\n background: var(--road-surface);\n border-radius: 0 0 0.25rem 0.25rem;\n box-shadow: var(--road-elevation-low);\n}\n\n.select-filter-list.not-active {\n opacity: 0;\n}\n\n/* ITEM\n -------------------- */\n\n.select-filter-item {\n display: flex;\n align-items: center;\n padding: 0.75rem 1rem;\n cursor: pointer;\n}\n\n.select-filter-item.active {\n outline: 1px solid var(--road-input-outline-variant);\n}\n\n/**\n * Hover state\n */\n\n.select-filter-item:hover,\n.select-filter-item:focus,\n.select-filter-item.highlight {\n color: var(--road-on-primary);\n background: var(--road-primary);\n}\n","import { Component, Element, Host, Listen, Prop, State, h, Event, EventEmitter } from '@stencil/core';\nimport Fuse from 'fuse.js';\n\n/**\n * @slot - Input element for the widget, it should be a road-input element.\n */\n\n@Component({\n tag: 'road-select-filter',\n styleUrl: 'select-filter.css',\n scoped: true,\n})\nexport class SelectFilter {\n\n @Element() el!: HTMLRoadSelectFilterElement;\n\n @State() isOpen: boolean = false;\n\n @State() currentValue: string = '';\n\n @State() activeIndex: number = -1;\n\n /**\n * List of options of the select\n */\n @Prop() options: Array<{\n value: string | number;\n label: string;\n }> = [];\n\n /**\n * Options to pass to the fuse.js instance.\n * See https://fusejs.io/api/options.html for valid options\n */\n @Prop() parameters: any = {\n keys: [\"value\", \"label\"],\n threshold: 0.3,\n ignoreLocation: true,\n };\n\n /**\n * If `true`, add class Active\n */\n @Prop() isActive: boolean = false;\n\n /**\n * If `false`, the user can submit custom value\n */\n @Prop() onlySelect: boolean = true;\n\n @Listen('roadFocus')\n @Listen('roadfocus')\n handleFocus() {\n this.isOpen = true;\n this.isActive = true;\n }\n\n @Listen('roadBlur')\n @Listen('roadblur')\n handleBlur() {\n this.isActive = false;\n }\n\n @Listen('roadChange')\n @Listen('roadchange')\n handleChange(event: CustomEvent) {\n this.currentValue = event.detail.value.toLowerCase();\n }\n\n @Listen('click', { target: 'document' })\n onClickOutside(event: MouseEvent) {\n if (this.isOpen && !this.el.contains(event.target as Node)) {\n this.isOpen = false;\n this.isActive = false;\n const value = (this.el.querySelector('road-input') as HTMLRoadInputElement).value;\n if (this.onlySelect && !this.options.some(option => option['label'] === value)) {\n (this.el.querySelector('road-input') as HTMLRoadInputElement).value = '';\n }\n }\n }\n\n @Listen('keydown', { target: 'window' })\n handleKeydown(event: KeyboardEvent) {\n if (this.isOpen) {\n if (event.key === 'ArrowDown') {\n event.preventDefault();\n this.activeIndex = (this.activeIndex + 1) % this.filteredOptions.length;\n } else if (event.key === 'ArrowUp') {\n event.preventDefault();\n this.activeIndex = (this.activeIndex - 1 + this.filteredOptions.length) % this.filteredOptions.length;\n } else if (event.key === 'Enter') {\n event.preventDefault();\n const activeOption = this.filteredOptions[this.activeIndex];\n if (activeOption) {\n this.onClick(activeOption.item.value, activeOption.item.label);\n }\n }\n }\n }\n\n get filteredOptions() {\n const fuseSearch = new Fuse(this.options, this.parameters);\n return this.currentValue === '' ? this.options.map((doc, idx) => ({ item: doc, score: 1, refIndex: idx })) : fuseSearch.search(this.currentValue);\n }\n\n @Event() roadselected!: EventEmitter<{\n value: string | undefined | null,\n label: string\n }>;\n\n @Event() roadSelected!: EventEmitter<{\n value: string | undefined | null,\n label: string\n }>;\n\n private onClick = (value: string | number, label: string) => {\n (this.el.querySelector('road-input') as HTMLRoadInputElement).value = label;\n if (document.getElementsByClassName('phone-number-label-icon').length > 0) {\n (this.el.querySelector('road-icon') as HTMLRoadIconElement).name = 'flag-' + label;\n }\n this.isOpen = false;\n this.roadselected.emit({\n value: value.toString(),\n label: label,\n });\n this.roadSelected.emit({\n value: value.toString(),\n label: label,\n });\n this.activeIndex = -1;\n };\n\n private handleOptionMouseOver = (index: number) => {\n this.activeIndex = index;\n };\n\n private handleOptionClick = (value: string | number, label: string) => {\n this.onClick(value, label);\n };\n\n render() {\n const options = this.filteredOptions;\n const isActive = this.isActive ? 'true' : 'false';\n const notActive = this.isActive ? '' : 'not-active';\n\n return (\n <Host is-active={isActive}>\n <slot />\n {this.isOpen &&\n <ul class={`${notActive} select-filter-list`} role=\"listbox\">\n {options.map((option, idx) => (\n <li\n class={`select-filter-item ${this.activeIndex === idx ? 'active' : ''}`}\n role=\"option\"\n aria-selected={this.activeIndex === idx ? 'true' : 'false'}\n onClick={() => this.handleOptionClick(option.item.value, option.item.label.replace(/(<([^>]+)>)/gi, \"\"))}\n onMouseOver={() => this.handleOptionMouseOver(idx)}\n innerHTML={option.item.label}\n tabindex={this.activeIndex === idx ? 0 : -1}\n >\n </li>\n ))}\n </ul>}\n </Host>\n );\n }\n}\n"],"mappings":"gEASA,SAASA,EAAQC,GACf,OAAQC,MAAMF,QACVG,EAAOF,KAAW,iBAClBC,MAAMF,QAAQC,EACpB,CAGA,MAAMG,EAAW,EAAI,EACrB,SAASC,EAAaJ,GAEpB,UAAWA,GAAS,SAAU,CAC5B,OAAOA,CACX,CACE,IAAIK,EAASL,EAAQ,GACrB,OAAOK,GAAU,KAAO,EAAIL,IAAUG,EAAW,KAAOE,CAC1D,CAEA,SAASC,EAASN,GAChB,OAAOA,GAAS,KAAO,GAAKI,EAAaJ,EAC3C,CAEA,SAASO,EAASP,GAChB,cAAcA,IAAU,QAC1B,CAEA,SAASQ,EAASR,GAChB,cAAcA,IAAU,QAC1B,CAGA,SAASS,EAAUT,GACjB,OACEA,IAAU,MACVA,IAAU,OACTU,EAAaV,IAAUE,EAAOF,IAAU,kBAE7C,CAEA,SAASW,EAASX,GAChB,cAAcA,IAAU,QAC1B,CAGA,SAASU,EAAaV,GACpB,OAAOW,EAASX,IAAUA,IAAU,IACtC,C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,EAAKtC,MAAO,EAAGuL,SAAUtL,MAAUkP,EAAWtK,OAAOpH,KAAK8Q,a,CAsCtI,MAAAc,GACE,MAAM7I,EAAU/I,KAAKwR,gBACrB,MAAMd,EAAW1Q,KAAK0Q,SAAW,OAAS,QAC1C,MAAMmB,EAAY7R,KAAK0Q,SAAW,GAAK,aAEvC,OACEoB,EAACC,EAAI,aAAYrB,GACfoB,EAAA,aACC9R,KAAKkQ,QACJ4B,EAAA,MAAIE,MAAO,GAAGH,uBAAgCI,KAAK,WAChDlJ,EAAQ5C,KAAI,CAACkL,EAAQ7O,IACpBsP,EAAA,MACEE,MAAO,sBAAsBhS,KAAKsQ,cAAgB9N,EAAM,SAAW,KACnEyP,KAAK,SAAQ,gBACEjS,KAAKsQ,cAAgB9N,EAAM,OAAS,QACnDoN,QAAS,IAAM5P,KAAKwQ,kBAAkBa,EAAO/L,KAAKxH,MAAOuT,EAAO/L,KAAKuK,MAAMqC,QAAQ,gBAAiB,KACpGC,YAAa,IAAMnS,KAAKuQ,sBAAsB/N,GAC9C4P,UAAWf,EAAO/L,KAAKuK,MACvBwC,SAAUrS,KAAKsQ,cAAgB9N,EAAM,GAAK,O"}
@@ -1,2 +1,2 @@
1
- import{r as t,c as e,h as o,H as i}from"./p-f3d586b3.js";import"./p-1ccae339.js";const a=":host{--z-index:3;position:fixed;bottom:0;left:0;z-index:var(--z-index);box-sizing:border-box;display:flex;align-items:center;width:100%;height:5.125rem;padding-left:0;margin:0;text-align:center;-webkit-user-select:none;user-select:none;background-color:var(--road-surface);border-top:1px solid var(--road-outline)}@media (max-width: 576px){:host{overflow-x:auto}}@media (min-width: 1200px){:host{bottom:auto;flex-direction:column;width:104px;height:100%;border-top:0;border-right:1px solid var(--road-outline)}}::slotted(.drawer-button-save){position:absolute;bottom:0;width:100%}";const r=class{constructor(o){t(this,o);this.roadnavbarchanged=e(this,"roadnavbarchanged",7);this.roadNavbarChanged=e(this,"roadNavbarChanged",7);this.selectedTab=undefined}selectedTabChanged(){if(this.selectedTab!==undefined){this.roadnavbarchanged.emit({tab:this.selectedTab});this.roadNavbarChanged.emit({tab:this.selectedTab})}}onNavbarChanged(t){this.selectedTab=t.detail.tab}componentWillLoad(){this.selectedTabChanged()}render(){return o(i,{role:"tablist"},o("slot",null))}static get watchers(){return{selectedTab:["selectedTabChanged"]}}};r.style=a;export{r as road_navbar};
2
- //# sourceMappingURL=p-60e25858.entry.js.map
1
+ import{r as t,c as e,h as o,H as i}from"./p-f3d586b3.js";import"./p-1ccae339.js";const a=":host{--z-index:3;position:fixed;bottom:0;left:0;z-index:var(--z-index);box-sizing:border-box;display:flex;align-items:center;width:100%;height:5.125rem;padding-left:0;margin:0;text-align:center;-webkit-user-select:none;user-select:none;background-color:var(--road-surface);border-top:1px solid var(--road-outline)}@media (max-width: 576px){:host{overflow-x:auto}}@media (min-width: 1200px){:host{bottom:auto;flex-direction:column;width:104px;height:100%;border-top:0;border-right:1px solid var(--road-outline)}}::slotted(.drawer-button-save){position:absolute;bottom:0;width:100%}";const r=class{constructor(o){t(this,o);this.roadnavbarchanged=e(this,"roadnavbarchanged",7);this.roadNavbarChanged=e(this,"roadNavbarChanged",7);this.selectedTab=undefined}selectedTabChanged(){if(this.selectedTab!==undefined){this.roadnavbarchanged.emit({tab:this.selectedTab});this.roadNavbarChanged.emit({tab:this.selectedTab})}}onNavbarChanged(t){this.selectedTab=t.detail.tab}componentWillLoad(){this.selectedTabChanged()}render(){return o(i,{role:"menubar"},o("slot",null))}static get watchers(){return{selectedTab:["selectedTabChanged"]}}};r.style=a;export{r as road_navbar};
2
+ //# sourceMappingURL=p-14ecc91e.entry.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["navbarCss","Navbar","selectedTabChanged","this","selectedTab","undefined","roadnavbarchanged","emit","tab","roadNavbarChanged","onNavbarChanged","ev","detail","componentWillLoad","render","h","Host","role"],"sources":["src/components/navbar/navbar.css?tag=road-navbar&encapsulation=shadow","src/components/navbar/navbar.tsx"],"sourcesContent":["/*\n * Navbar\n *\n */\n\n/**\n * @prop --z-index: The z-index of the Navbar.\n */\n\n:host {\n --z-index: 3;\n\n position: fixed;\n bottom: 0;\n left: 0;\n z-index: var(--z-index);\n box-sizing: border-box;\n display: flex;\n align-items: center;\n width: 100%;\n height: 5.125rem;\n padding-left: 0;\n margin: 0;\n text-align: center;\n user-select: none;\n background-color: var(--road-surface);\n border-top: 1px solid var(--road-outline);\n}\n\n@media (max-width: 576px) {\n\n :host {\n overflow-x: auto;\n }\n}\n\n@media (min-width: 1200px) {\n\n :host {\n bottom: auto;\n flex-direction: column;\n width: 104px;\n height: 100%;\n border-top: 0;\n border-right: 1px solid var(--road-outline);\n }\n}\n\n/**\n * Button save drawer.\n */\n\n::slotted(.drawer-button-save) {\n position: absolute;\n bottom: 0;\n width: 100%;\n}\n","import { Component, Host, h, Prop, Watch, Event, EventEmitter, Listen } from '@stencil/core';\nimport './../../utils/polyfill';\n\n/**\n * @slot - Content of the navbar, it should be road-navbar-item elements. Max 5 items on Mobile\n */\n\n@Component({\n tag: 'road-navbar',\n styleUrl: 'navbar.css',\n shadow: true,\n})\nexport class Navbar {\n\n /**\n * The selected tab component\n */\n @Prop() selectedTab?: string;\n @Watch('selectedTab')\n selectedTabChanged() {\n if (this.selectedTab !== undefined) {\n this.roadnavbarchanged.emit({\n tab: this.selectedTab,\n });\n this.roadNavbarChanged.emit({\n tab: this.selectedTab,\n });\n }\n }\n\n /** @internal */\n @Event() roadnavbarchanged!: EventEmitter;\n /** @internal */\n @Event() roadNavbarChanged!: EventEmitter;\n\n @Listen('roadNavbarItemClick')\n @Listen('roadnavbaritemclick')\n onNavbarChanged(ev: CustomEvent) {\n this.selectedTab = ev.detail.tab;\n }\n\n componentWillLoad() {\n this.selectedTabChanged();\n }\n\n render() {\n return (\n <Host\n role=\"tablist\"\n >\n <slot/>\n </Host>\n );\n }\n\n}\n"],"mappings":"iFAAA,MAAMA,EAAY,wkB,MCYLC,EAAM,M,8JAOjB,kBAAAC,GACE,GAAIC,KAAKC,cAAgBC,UAAW,CAClCF,KAAKG,kBAAkBC,KAAK,CAC1BC,IAAKL,KAAKC,cAEZD,KAAKM,kBAAkBF,KAAK,CAC1BC,IAAKL,KAAKC,a,EAYhB,eAAAM,CAAgBC,GACdR,KAAKC,YAAcO,EAAGC,OAAOJ,G,CAG/B,iBAAAK,GACEV,KAAKD,oB,CAGP,MAAAY,GACE,OACEC,EAACC,EAAI,CACHC,KAAK,WAELF,EAAA,a"}
1
+ {"version":3,"names":["navbarCss","Navbar","selectedTabChanged","this","selectedTab","undefined","roadnavbarchanged","emit","tab","roadNavbarChanged","onNavbarChanged","ev","detail","componentWillLoad","render","h","Host","role"],"sources":["src/components/navbar/navbar.css?tag=road-navbar&encapsulation=shadow","src/components/navbar/navbar.tsx"],"sourcesContent":["/*\n * Navbar\n *\n */\n\n/**\n * @prop --z-index: The z-index of the Navbar.\n */\n\n:host {\n --z-index: 3;\n\n position: fixed;\n bottom: 0;\n left: 0;\n z-index: var(--z-index);\n box-sizing: border-box;\n display: flex;\n align-items: center;\n width: 100%;\n height: 5.125rem;\n padding-left: 0;\n margin: 0;\n text-align: center;\n user-select: none;\n background-color: var(--road-surface);\n border-top: 1px solid var(--road-outline);\n}\n\n@media (max-width: 576px) {\n\n :host {\n overflow-x: auto;\n }\n}\n\n@media (min-width: 1200px) {\n\n :host {\n bottom: auto;\n flex-direction: column;\n width: 104px;\n height: 100%;\n border-top: 0;\n border-right: 1px solid var(--road-outline);\n }\n}\n\n/**\n * Button save drawer.\n */\n\n::slotted(.drawer-button-save) {\n position: absolute;\n bottom: 0;\n width: 100%;\n}\n","import { Component, Host, h, Prop, Watch, Event, EventEmitter, Listen } from '@stencil/core';\nimport './../../utils/polyfill';\n\n/**\n * @slot - Content of the navbar, it should be road-navbar-item elements. Max 5 items on Mobile\n */\n\n@Component({\n tag: 'road-navbar',\n styleUrl: 'navbar.css',\n shadow: true,\n})\nexport class Navbar {\n\n /**\n * The selected tab component\n */\n @Prop() selectedTab?: string;\n @Watch('selectedTab')\n selectedTabChanged() {\n if (this.selectedTab !== undefined) {\n this.roadnavbarchanged.emit({\n tab: this.selectedTab,\n });\n this.roadNavbarChanged.emit({\n tab: this.selectedTab,\n });\n }\n }\n\n /** @internal */\n @Event() roadnavbarchanged!: EventEmitter;\n /** @internal */\n @Event() roadNavbarChanged!: EventEmitter;\n\n @Listen('roadNavbarItemClick')\n @Listen('roadnavbaritemclick')\n onNavbarChanged(ev: CustomEvent) {\n this.selectedTab = ev.detail.tab;\n }\n\n componentWillLoad() {\n this.selectedTabChanged();\n }\n\n render() {\n return (\n <Host\n role=\"menubar\"\n >\n <slot/>\n </Host>\n );\n }\n\n}\n"],"mappings":"iFAAA,MAAMA,EAAY,wkB,MCYLC,EAAM,M,8JAOjB,kBAAAC,GACE,GAAIC,KAAKC,cAAgBC,UAAW,CAClCF,KAAKG,kBAAkBC,KAAK,CAC1BC,IAAKL,KAAKC,cAEZD,KAAKM,kBAAkBF,KAAK,CAC1BC,IAAKL,KAAKC,a,EAYhB,eAAAM,CAAgBC,GACdR,KAAKC,YAAcO,EAAGC,OAAOJ,G,CAG/B,iBAAAK,GACEV,KAAKD,oB,CAGP,MAAAY,GACE,OACEC,EAACC,EAAI,CACHC,KAAK,WAELF,EAAA,a"}
@@ -1,2 +1,2 @@
1
- import{r as o,c as t,h as s,H as a}from"./p-f3d586b3.js";import{a as r,d as i,e,f as n,g as c}from"./p-73fe2357.js";const d=":host{position:fixed;right:0;bottom:1rem;left:0;z-index:1;display:flex;justify-content:center;width:328px;margin:0 auto;pointer-events:none;visibility:hidden;opacity:0;transition:opacity .3s ease-in-out,visibility .15s,transform .3s ease-in-out;transform:translateY(-100%)}@media (min-width: 1200px){:host{right:1.5rem;bottom:3rem;left:auto;width:auto;transform:translateX(100%)}}:host(.toast-open){visibility:visible;opacity:1;transform:none}.toast{position:relative;box-sizing:border-box;display:flex;flex:0 0 100%;flex-flow:wrap;align-items:flex-start;width:328px;padding:0.75rem 2rem 0.6rem 1rem;font-family:var(--road-font);font-size:var(--road-body-medium);line-height:1.4;color:var(--road-on-info-surface-inverse);text-align:left;background:var(--road-info-surface-inverse);border-radius:0.25rem}@media (min-width: 575px){.toast{padding:1rem;margin-right:auto;margin-left:auto}}.toast-danger{color:var(--road-on-danger-surface-inverse);pointer-events:all;background:var(--road-danger-surface-inverse)}.toast-danger road-icon{color:var(--road-danger-icon-inverse)}.toast-warning{color:var(--road-on-warning-surface-inverse);background:var(--road-warning-surface-inverse)}.toast-warning road-icon{color:var(--road-warning-icon-inverse)}.toast-success{color:var(--road-on-success-surface-inverse);background:var(--road-success-surface-inverse)}.toast-success road-icon{color:var(--road-success-icon-inverse)}.toast-info{color:var(--road-on-info-surface-inverse);background:var(--road-info-surface-inverse)}.toast-info road-icon{color:var(--road-info-icon-inverse)}.toast-icon{top:auto;left:0.5rem;margin-top:-5px;margin-right:0.5rem}@media (min-width: 575px){.toast-icon{position:relative;top:auto;left:auto;margin-right:0.5rem}}.toast-close{position:absolute;right:0.5rem;padding:0;color:inherit;cursor:pointer;background:none;border:0;border-radius:4px;fill:var(--road-info-icon-inverse)}.toast-warning .toast-close{fill:var(--road-warning-icon-inverse)}.toast-close:focus{border-color:var(--road-info-surface-inverse);outline:none}.toast-label{width:240px;margin:0}:host ::slotted(road-progress){position:absolute;bottom:-8px;left:0;flex-basis:100%;width:100%;margin-top:0.5rem}@keyframes load{0%{width:0}100%{width:100%}}";const l=class{constructor(s){o(this,s);this.onClose=t(this,"close",7);this.onClick=o=>{o.stopPropagation();o.preventDefault();this.close()};this.isOpen=false;this.color="info";this.label=undefined;this.timeout=5e3}isOpenChanged(){if(this.isOpen&&this.timeout>0){setTimeout((()=>this.close()),this.timeout)}}async open(){this.isOpen=true;if(this.timeout>0){setTimeout((()=>{this.close()}),this.timeout)}}async close(){this.isOpen=false;this.onClose.emit()}componentDidLoad(){if(this.isOpen&&this.timeout>0){setTimeout((()=>this.close()),this.timeout)}}render(){const o=this.isOpen?"toast-open":"";let t;switch(this.color){case"info":t=i;break;case"success":t=c;break;case"warning":t=n;break;case"danger":t=e;break;default:t=i;break}if(this.color=="danger"){this.timeout=0}return s(a,{class:`${o}`,role:"alert"},s("div",{class:`toast toast-${this.color}`},s("road-icon",{class:"toast-icon",icon:t,"aria-hidden":"true"}),s("p",{class:"toast-label"},this.label),s("button",{type:"button",class:"toast-close","aria-label":"Close",onClick:this.onClick},s("road-icon",{icon:r,size:"md"})),s("slot",{name:"progress"})))}static get watchers(){return{isOpen:["isOpenChanged"]}}};l.style=d;export{l as road_toast};
2
- //# sourceMappingURL=p-82919e58.entry.js.map
1
+ import{r as o,c as t,h as a,H as s}from"./p-f3d586b3.js";import{a as r,d as i,e,f as n,g as c}from"./p-ac7a8bca.js";const d=":host{position:fixed;right:0;bottom:1rem;left:0;z-index:1;display:flex;justify-content:center;width:328px;margin:0 auto;pointer-events:none;visibility:hidden;opacity:0;transition:opacity .3s ease-in-out,visibility .15s,transform .3s ease-in-out;transform:translateY(-100%)}@media (min-width: 1200px){:host{right:1.5rem;bottom:3rem;left:auto;width:auto;transform:translateX(100%)}}:host(.toast-open){visibility:visible;opacity:1;transform:none}.toast{position:relative;box-sizing:border-box;display:flex;flex:0 0 100%;flex-flow:wrap;align-items:flex-start;width:328px;padding:0.75rem 2rem 0.6rem 1rem;font-family:var(--road-font);font-size:var(--road-body-medium);line-height:1.4;color:var(--road-on-info-surface-inverse);text-align:left;background:var(--road-info-surface-inverse);border-radius:0.25rem}@media (min-width: 575px){.toast{padding:1rem;margin-right:auto;margin-left:auto}}.toast-danger{color:var(--road-on-danger-surface-inverse);pointer-events:all;background:var(--road-danger-surface-inverse)}.toast-danger road-icon{color:var(--road-danger-icon-inverse)}.toast-warning{color:var(--road-on-warning-surface-inverse);background:var(--road-warning-surface-inverse)}.toast-warning road-icon{color:var(--road-warning-icon-inverse)}.toast-success{color:var(--road-on-success-surface-inverse);background:var(--road-success-surface-inverse)}.toast-success road-icon{color:var(--road-success-icon-inverse)}.toast-info{color:var(--road-on-info-surface-inverse);background:var(--road-info-surface-inverse)}.toast-info road-icon{color:var(--road-info-icon-inverse)}.toast-icon{top:auto;left:0.5rem;margin-top:-5px;margin-right:0.5rem}@media (min-width: 575px){.toast-icon{position:relative;top:auto;left:auto;margin-right:0.5rem}}.toast-close{position:absolute;right:0.5rem;padding:0;color:inherit;cursor:pointer;background:none;border:0;border-radius:4px;fill:var(--road-info-icon-inverse)}.toast-warning .toast-close{fill:var(--road-warning-icon-inverse)}.toast-close:focus{border-color:var(--road-info-surface-inverse);outline:none}.toast-label{width:240px;margin:0}:host ::slotted(road-progress){position:absolute;bottom:-8px;left:0;flex-basis:100%;width:100%;margin-top:0.5rem}@keyframes load{0%{width:0}100%{width:100%}}";const l=class{constructor(a){o(this,a);this.onClose=t(this,"close",7);this.onClick=o=>{o.stopPropagation();o.preventDefault();this.close()};this.isOpen=false;this.color="info";this.label=undefined;this.timeout=5e3}isOpenChanged(){if(this.isOpen&&this.timeout>0){setTimeout((()=>this.close()),this.timeout)}}async open(){this.isOpen=true;if(this.timeout>0){setTimeout((()=>{this.close()}),this.timeout)}}async close(){this.isOpen=false;this.onClose.emit()}componentDidLoad(){if(this.isOpen&&this.timeout>0){setTimeout((()=>this.close()),this.timeout)}}render(){const o=this.isOpen?"toast-open":"";let t;switch(this.color){case"info":t=i;break;case"success":t=c;break;case"warning":t=n;break;case"danger":t=e;break;default:t=i;break}if(this.color=="danger"){this.timeout=0}return a(s,{class:`${o}`,role:"alert"},a("div",{class:`toast toast-${this.color}`},a("road-icon",{class:"toast-icon",icon:t,"aria-hidden":"true"}),a("p",{class:"toast-label"},this.label),a("button",{type:"button",class:"toast-close","aria-label":"Close",onClick:this.onClick},a("road-icon",{icon:r,size:"md"})),a("slot",{name:"progress"})))}static get watchers(){return{isOpen:["isOpenChanged"]}}};l.style=d;export{l as road_toast};
2
+ //# sourceMappingURL=p-16c934bc.entry.js.map
@@ -0,0 +1,2 @@
1
+ import{r as o,h as r}from"./p-f3d586b3.js";import{n as a}from"./p-ac7a8bca.js";import"./p-1ccae339.js";const i=':host{--accordion-header-border:1px;--content-margin:0 1rem 0.75rem;--content-padding:0.75rem 0 0;--header-padding:0.75rem 1rem;--icon-color:var(--road-icon);--max-height:none;display:block;margin-bottom:1rem}:host(.focus-visible){border:1px solid var(--road-primary)}.accordion{--max-height:none;overflow:hidden;font-family:var(--road-font, sans-serif);font-size:var(--road-body-small);line-height:1.5;color:var(--road-on-surface);background:var(--road-surface);border:1px solid;border-color:var(--road-outline-weak);border-radius:0.25rem;transition:max-height 0.3s ease-in-out}.accordion.accordion-light{border:0}.accordion[open]{max-height:var(--max-height)}.accordion[open] .accordion-arrow{transform:rotate(-90deg)}.accordion[open] .accordion-content{padding:var(--content-padding);margin:var(--content-margin)}.accordion-light[open] .accordion-light-content{padding:0.75rem 0;margin:0 1rem 0.75rem}.accordion-light[open] .accordion-light-header::after{display:none}.accordion-trigger{box-sizing:border-box;display:block;border:1px solid transparent;border-radius:0.25rem;outline:0;-webkit-tap-highlight-color:rgba(0, 0, 0, 0)}.accordion-trigger::-webkit-details-marker{display:none}.accordion-trigger.focus-visible{border-color:var(--road-primary)}.accordion-trigger:active{background:var(--road-surface-inverse)}.accordion-header{box-sizing:border-box;display:flex;align-items:center;justify-content:flex-start;padding:var(--header-padding);font-size:var(--road-body-medium);font-weight:700;cursor:pointer;-webkit-user-select:none;user-select:none}.accordion-light-header{position:relative;font-size:var(--road-body-large)}.accordion-light--small .accordion-light-header{font-size:var(--road-body-medium)}.accordion-light--border .accordion-light-header::after{position:absolute;bottom:1px;width:98.3%;height:1px;content:"";background:var(--road-outline-weak)}.accordion-arrow{margin-left:auto;color:var(--icon-color);transform:rotate(90deg)}.accordion-light--small .accordion-arrow{width:1.5rem;height:1.5rem}::slotted([slot="header"]){display:flex;align-items:center}:host(.accordion-icon-left){width:1.5rem;height:1.5rem;margin-right:1rem}.accordion-content{padding:0 0.5rem;margin:0 1rem;overflow:hidden;font-size:var(--road-body-medium);border-top:var(--accordion-header-border) solid var(--road-outline-weak)}.accordion-light-content{border-top:1px solid var(--road-outline-weak)}.accordion-light--border .accordion-light-content{border-top:1px solid var(--road-outline-weak);border-bottom:1px solid var(--road-outline-weak)}';const e=class{constructor(r){o(this,r);this.onClick=()=>{this.isOpen=!this.isOpen};this.isOpen=false;this.isLight=false;this.isLightSeparator=false;this.isSmall=false}render(){const o=this.isLight?"accordion accordion-light":"accordion";const i=this.isLight?"accordion-header accordion-light-header":"accordion-header";const e=this.isLight?"accordion-content accordion-light-content":"accordion-content";const n=this.isLightSeparator?"accordion accordion-light accordion-light--border":"accordion";const t=this.isSmall?"accordion accordion-light accordion-light--small":"accordion";return r("details",{class:`${o} ${t} ${n}`,open:this.isOpen},r("summary",{class:"accordion-trigger","aria-expanded":`${this.isOpen}`,tabindex:"0",role:"button",onClick:this.onClick},r("div",{class:i},r("slot",{name:"icon-left"}),r("slot",{name:"header"}),r("road-icon",{class:"accordion-arrow",icon:a}))),r("div",{class:e},r("slot",null)))}};e.style=i;export{e as road_accordion};
2
+ //# sourceMappingURL=p-17ae87b0.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["accordionCss","Accordion","this","onClick","isOpen","render","accordionLight","isLight","accordionLightHeader","accordionLightContent","accordionLightSeparator","isLightSeparator","accordionSmall","isSmall","h","class","open","tabindex","role","name","icon","navigationChevron"],"sources":["src/components/accordion/accordion.css?tag=road-accordion&encapsulation=shadow","src/components/accordion/accordion.tsx"],"sourcesContent":["/*\n * Accordion\n *\n * For accessibility, we provide a style for focus only on Tab.\n * For enable this focus, load the javascript polyfill for focus-visible\n * (https://github.com/WICG/focus-visible).\n *\n * Index\n * - Accordion\n * - Button\n * - Content\n */\n\n/**\n * @prop --accordion-header-border: height of the border of the header\n * @prop --content-margin: margin of the accordion content\n * @prop --content-padding: padding of the accordion content\n * @prop --header-padding: padding of the accordion header\n * @prop --icon-color: color of the chevron icon\n * @prop --max-height: maximum height of the collapse content\n */\n\n:host {\n --accordion-header-border: 1px;\n --content-margin: 0 1rem 0.75rem;\n --content-padding: 0.75rem 0 0;\n --header-padding: 0.75rem 1rem;\n --icon-color: var(--road-icon);\n --max-height: none;\n\n display: block;\n margin-bottom: 1rem;\n}\n\n:host(.focus-visible){\n border: 1px solid var(--road-primary);\n}\n\n/* ACCORDION\n -------------------- */\n\n.accordion {\n --max-height: none;\n overflow: hidden;\n font-family: var(--road-font, sans-serif);\n font-size: var(--road-body-small);\n line-height: 1.5;\n color: var(--road-on-surface);\n background: var(--road-surface);\n border: 1px solid;\n border-color: var(--road-outline-weak);\n border-radius: 0.25rem;\n transition: max-height 0.3s ease-in-out;\n}\n\n.accordion.accordion-light {\n border: 0;\n}\n\n/**\n * Open state\n */\n\n.accordion[open] {\n max-height: var(--max-height);\n}\n\n.accordion[open] .accordion-arrow {\n transform: rotate(-90deg);\n}\n\n.accordion[open] .accordion-content {\n padding: var(--content-padding);\n margin: var(--content-margin);\n}\n\n.accordion-light[open] .accordion-light-content {\n padding: 0.75rem 0;\n margin: 0 1rem 0.75rem;\n}\n\n.accordion-light[open] .accordion-light-header::after {\n display: none;\n}\n\n/* BUTTON\n -------------------- */\n\n.accordion-trigger {\n box-sizing: border-box;\n display: block;\n border: 1px solid transparent;\n border-radius: 0.25rem;\n outline: 0;\n -webkit-tap-highlight-color: rgba(0, 0, 0, 0);\n}\n\n.accordion-trigger::-webkit-details-marker { /* Remove chrome native arrow */\n display: none;\n}\n\n/**\n * Focus on Tab\n */\n\n.accordion-trigger.focus-visible {\n border-color: var(--road-primary);\n}\n\n/**\n * Active state\n */\n\n.accordion-trigger:active {\n background: var(--road-surface-inverse);\n}\n\n/**\n * .accordion-header is an additionnal div\n * because Safari doesn't support flexbox on <summary> element\n */\n\n.accordion-header {\n box-sizing: border-box;\n display: flex;\n align-items: center;\n justify-content: flex-start;\n padding: var(--header-padding);\n font-size: var(--road-body-medium);\n font-weight: 700;\n cursor: pointer;\n user-select: none;\n}\n\n.accordion-light-header {\n position: relative;\n font-size: var(--road-body-large);\n}\n\n.accordion-light--small .accordion-light-header {\n font-size: var(--road-body-medium);\n}\n\n.accordion-light--border .accordion-light-header::after {\n position: absolute;\n bottom: 1px;\n width: 98.3%;\n height: 1px;\n content: \"\";\n background: var(--road-outline-weak);\n}\n\n/**\n * Custom arrow\n */\n\n.accordion-arrow {\n margin-left: auto;\n color: var(--icon-color);\n transform: rotate(90deg);\n}\n\n.accordion-light--small .accordion-arrow {\n width: 1.5rem;\n height: 1.5rem;\n}\n\n::slotted([slot=\"header\"]){\n display: flex;\n align-items: center;\n}\n\n:host(.accordion-icon-left){\n width: 1.5rem;\n height: 1.5rem;\n margin-right: 1rem;\n}\n\n/* CONTENT\n -------------------- */\n\n.accordion-content {\n padding: 0 0.5rem;\n margin: 0 1rem;\n overflow: hidden;\n font-size: var(--road-body-medium);\n border-top: var(--accordion-header-border) solid var(--road-outline-weak);\n}\n\n.accordion-light-content {\n border-top: 1px solid var(--road-outline-weak);\n}\n\n.accordion-light--border .accordion-light-content {\n border-top: 1px solid var(--road-outline-weak);\n border-bottom: 1px solid var(--road-outline-weak);\n}\n","import { Component, Prop, h } from '@stencil/core';\nimport { navigationChevron } from '../../../icons';\nimport './../../utils/polyfill';\n\n/**\n * @slot header - Content of the header.\n * @slot - Content hidden in the accordion.\n * @slot icon-left - Icon of the alert, it should be a road-icon element.\n * `<road-icon name=\"alert-info-outline\" class=\"mr-16\"></road-icon>`\n\n */\n\n@Component({\n tag: 'road-accordion',\n styleUrl: 'accordion.css',\n shadow: true,\n})\nexport class Accordion {\n\n /**\n * Set to `true` to open the accordion and to `false` to close it.\n */\n @Prop({ mutable: true }) isOpen : boolean = false;\n\n /**\n * Set to `true` to remove border the accordion and to `false` to add border it.\n */\n @Prop() isLight : boolean = false;\n\n /**\n * Set to `true` to add a border in the header and the content only for the light accordion.\n */\n @Prop() isLightSeparator : boolean = false;\n\n /**\n * Set to `true` to add the small version only for the light accordion.\n */\n @Prop() isSmall : boolean = false;\n\n /**\n * Toggle the display when clicking header\n */\n private onClick = () => {\n this.isOpen = !this.isOpen;\n };\n\n render() {\n\n const accordionLight = this.isLight ? 'accordion accordion-light' : 'accordion';\n const accordionLightHeader = this.isLight ? 'accordion-header accordion-light-header' : 'accordion-header';\n const accordionLightContent = this.isLight ? 'accordion-content accordion-light-content' : 'accordion-content';\n const accordionLightSeparator = this.isLightSeparator ? 'accordion accordion-light accordion-light--border' : 'accordion';\n const accordionSmall = this.isSmall ? 'accordion accordion-light accordion-light--small' : 'accordion';\n return (\n <details class={`${accordionLight} ${accordionSmall} ${accordionLightSeparator}`} open={this.isOpen}>\n <summary class=\"accordion-trigger\" aria-expanded={`${this.isOpen}`} tabindex=\"0\" role=\"button\" onClick={this.onClick}>\n <div class={accordionLightHeader}>\n <slot name=\"icon-left\"/>\n <slot name=\"header\"/>\n <road-icon class=\"accordion-arrow\" icon={navigationChevron}></road-icon>\n </div>\n </summary>\n <div class={accordionLightContent}>\n <slot/>\n </div>\n </details>\n );\n }\n}"],"mappings":"uGAAA,MAAMA,EAAe,6+E,MCiBRC,EAAS,M,yBAyBZC,KAAAC,QAAU,KAChBD,KAAKE,QAAUF,KAAKE,MAAM,E,YArBgB,M,aAKf,M,sBAKU,M,aAKT,K,CAS9B,MAAAC,GAEE,MAAMC,EAAiBJ,KAAKK,QAAU,4BAA8B,YACpE,MAAMC,EAAuBN,KAAKK,QAAU,0CAA4C,mBACxF,MAAME,EAAwBP,KAAKK,QAAU,4CAA8C,oBAC3F,MAAMG,EAA0BR,KAAKS,iBAAmB,oDAAsD,YAC9G,MAAMC,EAAiBV,KAAKW,QAAU,mDAAqD,YAC3F,OACEC,EAAA,WAASC,MAAO,GAAGT,KAAkBM,KAAkBF,IAA2BM,KAAMd,KAAKE,QAC3FU,EAAA,WAASC,MAAM,oBAAmB,gBAAgB,GAAGb,KAAKE,SAAUa,SAAS,IAAIC,KAAK,SAASf,QAASD,KAAKC,SAC3GW,EAAA,OAAKC,MAAOP,GACVM,EAAA,QAAMK,KAAK,cACXL,EAAA,QAAMK,KAAK,WACXL,EAAA,aAAWC,MAAM,kBAAkBK,KAAMC,MAG7CP,EAAA,OAAKC,MAAON,GACVK,EAAA,c"}
@@ -1,2 +1,2 @@
1
- import{r as i,c as e,h as a,H as o,a as t}from"./p-f3d586b3.js";import{a as s,d as n,e as d,f as r,g as l}from"./p-73fe2357.js";const c=":host{--z-index:3;position:fixed;top:0;left:0;z-index:var(--z-index);display:flex;align-items:center;justify-content:center;width:100%;height:100%;overflow:hidden;font-family:var(--road-font, sans-serif);line-height:1.5;color:var(--road-on-surface);visibility:hidden !important;opacity:0;transition:opacity 0.15s linear, visibility 0.15s}.dialog-overlay{position:absolute;top:0;right:0;bottom:0;left:0;display:block;touch-action:none;background:var(--road-overlay)}:host(.dialog-has-close) .dialog-overlay{cursor:pointer}.dialog-modal{position:relative;width:auto;margin:1rem;pointer-events:none;transition:transform 0.3s ease-out;transform:translateY(50px)}:host(.dialog-open){visibility:visible !important;opacity:1}:host(.dialog-open) .dialog-modal{transform:none}.dialog-content{position:relative;display:flex;flex-direction:column;width:100%;padding:0 0 1.5rem;pointer-events:auto;background:var(--road-surface);background-clip:padding-box;border-radius:0.25rem;outline:0;box-shadow:var(--road-elevation-highest)}@media (min-width: 576px){.dialog-content{max-width:454px}}.dialog-header{display:flex;align-items:center;justify-content:flex-end;height:100%;max-height:2.75rem;margin-bottom:2rem}.dialog-close{display:flex;align-items:center;align-self:flex-start;justify-content:center;width:3.5rem;height:3.5rem;padding:0;color:inherit;cursor:pointer;background:transparent;border:0;-webkit-appearance:none;appearance:none;-webkit-tap-highlight-color:rgba(0, 0, 0, 0)}.dialog-icon{display:inline-block;width:3rem;height:3rem;font-size:var(--road-font-size-48)}.dialog-body{padding:0 1.5rem;text-align:center}@media (min-width: 768px){.dialog-body{padding:0 3rem}}.dialog-title{padding:0;margin:0 0 1rem;font-size:var(--road-body-medium);font-weight:700;line-height:1.2}.dialog-description{margin:0 0 0.5rem;overflow:auto;font-size:var(--road-body-medium)}.dialog-footer{display:flex;justify-content:center;padding:0 1.5rem}.dialog-footer ::slotted(road-button){margin-top:1rem}.dialog-footer .btn{min-width:130px;max-width:calc(50% - 0.5rem)}";const h=class{constructor(a){i(this,a);this.onClose=e(this,"close",7);this.onClick=i=>{i.stopPropagation();i.preventDefault();this.close()};this.isOpen=false;this.hasCloseIcon=true;this.color=undefined;this.icon=undefined;this.label=undefined;this.description=undefined}async open(){this.isOpen=true}async close(){this.isOpen=false;this.el.addEventListener("transitionend",(()=>{this.onClose.emit()}),{once:true})}onEscape(i){if((i.key==="Escape"||i.key==="Esc")&&this.isOpen&&this.hasCloseIcon){this.close()}}componentDidLoad(){this.el.querySelectorAll('[data-dismiss="modal"]').forEach((i=>{i.addEventListener("click",(()=>this.close()))}))}render(){const i=this.isOpen?"dialog-open":"";const e=this.hasCloseIcon?"dialog-has-close":"";let t;if(this.icon){t=this.icon}else{switch(this.color){case"info":t=n;break;case"success":t=l;break;case"warning":t=r;break;case"danger":t=d;break;default:t=n;break}}return a(o,{class:`dialog ${i} ${e}`,role:"alertdialog","aria-modal":"true",tabindex:"-1","aria-labelledby":"dialogLabel","aria-describedby":"dialogDesc"},a("div",{class:"dialog-overlay",onClick:this.hasCloseIcon===true?this.onClick:undefined,tabindex:"-1"}),a("div",{class:"dialog-modal",role:"document",tabindex:"0"},a("div",{class:"dialog-content"},a("header",{class:"dialog-header"},this.hasCloseIcon?a("button",{type:"button",class:"dialog-close",onClick:this.onClick,"aria-label":"Close"},a("road-icon",{icon:s,"aria-hidden":"true"})):""),a("div",{class:"dialog-body"},this.color!==undefined?a("road-icon",{class:"dialog-icon",part:"dialog-icon",color:this.color,icon:t,"aria-hidden":"true"}):"",a("h2",{class:"dialog-title",id:"dialogLabel"},this.label),a("p",{class:"dialog-description",id:"dialogDesc"},this.description)),a("footer",{class:"dialog-footer"},a("slot",null)))))}get el(){return t(this)}};h.style=c;export{h as road_dialog};
2
- //# sourceMappingURL=p-6e3e0b40.entry.js.map
1
+ import{r as i,c as e,h as a,H as o,a as t}from"./p-f3d586b3.js";import{a as s,d as n,e as d,f as r,g as l}from"./p-ac7a8bca.js";const c=":host{--z-index:3;position:fixed;top:0;left:0;z-index:var(--z-index);display:flex;align-items:center;justify-content:center;width:100%;height:100%;overflow:hidden;font-family:var(--road-font, sans-serif);line-height:1.5;color:var(--road-on-surface);visibility:hidden !important;opacity:0;transition:opacity 0.15s linear, visibility 0.15s}.dialog-overlay{position:absolute;top:0;right:0;bottom:0;left:0;display:block;touch-action:none;background:var(--road-overlay)}:host(.dialog-has-close) .dialog-overlay{cursor:pointer}.dialog-modal{position:relative;width:auto;margin:1rem;pointer-events:none;transition:transform 0.3s ease-out;transform:translateY(50px)}:host(.dialog-open){visibility:visible !important;opacity:1}:host(.dialog-open) .dialog-modal{transform:none}.dialog-content{position:relative;display:flex;flex-direction:column;width:100%;padding:0 0 1.5rem;pointer-events:auto;background:var(--road-surface);background-clip:padding-box;border-radius:0.25rem;outline:0;box-shadow:var(--road-elevation-highest)}@media (min-width: 576px){.dialog-content{max-width:454px}}.dialog-header{display:flex;align-items:center;justify-content:flex-end;height:100%;max-height:2.75rem;margin-bottom:2rem}.dialog-close{display:flex;align-items:center;align-self:flex-start;justify-content:center;width:3.5rem;height:3.5rem;padding:0;color:inherit;cursor:pointer;background:transparent;border:0;-webkit-appearance:none;appearance:none;-webkit-tap-highlight-color:rgba(0, 0, 0, 0)}.dialog-icon{display:inline-block;width:3rem;height:3rem;font-size:var(--road-font-size-48)}.dialog-body{padding:0 1.5rem;text-align:center}@media (min-width: 768px){.dialog-body{padding:0 3rem}}.dialog-title{padding:0;margin:0 0 1rem;font-size:var(--road-body-medium);font-weight:700;line-height:1.2}.dialog-description{margin:0 0 0.5rem;overflow:auto;font-size:var(--road-body-medium)}.dialog-footer{display:flex;justify-content:center;padding:0 1.5rem}.dialog-footer ::slotted(road-button){margin-top:1rem}.dialog-footer .btn{min-width:130px;max-width:calc(50% - 0.5rem)}";const h=class{constructor(a){i(this,a);this.onClose=e(this,"close",7);this.onClick=i=>{i.stopPropagation();i.preventDefault();this.close()};this.isOpen=false;this.hasCloseIcon=true;this.color=undefined;this.icon=undefined;this.label=undefined;this.description=undefined}async open(){this.isOpen=true}async close(){this.isOpen=false;this.el.addEventListener("transitionend",(()=>{this.onClose.emit()}),{once:true})}onEscape(i){if((i.key==="Escape"||i.key==="Esc")&&this.isOpen&&this.hasCloseIcon){this.close()}}componentDidLoad(){this.el.querySelectorAll('[data-dismiss="modal"]').forEach((i=>{i.addEventListener("click",(()=>this.close()))}))}render(){const i=this.isOpen?"dialog-open":"";const e=this.hasCloseIcon?"dialog-has-close":"";let t;if(this.icon){t=this.icon}else{switch(this.color){case"info":t=n;break;case"success":t=l;break;case"warning":t=r;break;case"danger":t=d;break;default:t=n;break}}return a(o,{class:`dialog ${i} ${e}`,role:"alertdialog","aria-modal":"true",tabindex:"-1","aria-label":"dialogLabel"},a("div",{class:"dialog-overlay",onClick:this.hasCloseIcon===true?this.onClick:undefined,tabindex:"-1"}),a("div",{class:"dialog-modal",role:"document",tabindex:"0"},a("div",{class:"dialog-content"},a("header",{class:"dialog-header"},this.hasCloseIcon?a("button",{type:"button",class:"dialog-close",onClick:this.onClick,"aria-label":"Close"},a("road-icon",{icon:s,"aria-hidden":"true"})):""),a("div",{class:"dialog-body"},this.color!==undefined?a("road-icon",{class:"dialog-icon",part:"dialog-icon",color:this.color,icon:t,"aria-hidden":"true"}):"",a("h2",{class:"dialog-title"},this.label),a("p",{class:"dialog-description",id:"dialogDesc"},this.description)),a("footer",{class:"dialog-footer"},a("slot",null)))))}get el(){return t(this)}};h.style=c;export{h as road_dialog};
2
+ //# sourceMappingURL=p-18967429.entry.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["dialogCss","Dialog","this","onClick","ev","stopPropagation","preventDefault","close","open","isOpen","el","addEventListener","onClose","emit","once","onEscape","event","key","hasCloseIcon","componentDidLoad","querySelectorAll","forEach","item","render","modalIsOpenClass","modalhasClose","icon","color","alertInfoOutline","alertSuccessOutline","alertWarningOutline","alertDangerOutline","h","Host","class","role","tabindex","undefined","type","navigationClose","part","id","label","description"],"sources":["src/components/dialog/dialog.css?tag=road-dialog&encapsulation=shadow","src/components/dialog/dialog.tsx"],"sourcesContent":["/*\n * Dialog\n *\n * Index\n * - Overlay\n * - Dialog\n * - Content\n * - Header\n * - Close\n * - Body\n * - Title\n * - Description\n * - Footer\n */\n\n/**\n * @prop --z-index: The z-index of the Dialog.\n */\n\n:host {\n --z-index: 3;\n\n position: fixed;\n top: 0;\n left: 0;\n z-index: var(--z-index);\n display: flex;\n align-items: center;\n justify-content: center;\n width: 100%;\n height: 100%;\n overflow: hidden;\n font-family: var(--road-font, sans-serif);\n line-height: 1.5;\n color: var(--road-on-surface);\n visibility: hidden !important;\n opacity: 0;\n transition: opacity 0.15s linear, visibility 0.15s;\n}\n\n/* OVERLAY\n -------------------- */\n\n.dialog-overlay {\n position: absolute;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n display: block;\n touch-action: none;\n background: var(--road-overlay);\n}\n\n:host(.dialog-has-close) .dialog-overlay {\n cursor: pointer;\n}\n\n/* DIALOG\n -------------------- */\n\n.dialog-modal {\n position: relative;\n width: auto;\n margin: 1rem;\n pointer-events: none;\n transition: transform 0.3s ease-out;\n transform: translateY(50px);\n}\n\n/**\n * Open state\n */\n\n:host(.dialog-open) {\n visibility: visible !important;\n opacity: 1;\n}\n\n:host(.dialog-open) .dialog-modal {\n transform: none;\n}\n\n/* CONTENT\n -------------------- */\n\n.dialog-content {\n position: relative;\n display: flex;\n flex-direction: column;\n width: 100%;\n padding: 0 0 1.5rem;\n pointer-events: auto;\n background: var(--road-surface);\n background-clip: padding-box;\n border-radius: 0.25rem;\n outline: 0;\n box-shadow: var(--road-elevation-highest);\n}\n\n@media (min-width: 576px) {\n\n .dialog-content {\n max-width: 454px;\n }\n}\n\n/* HEADER\n -------------------- */\n\n.dialog-header {\n display: flex;\n align-items: center;\n justify-content: flex-end;\n height: 100%;\n max-height: 2.75rem;\n margin-bottom: 2rem;\n}\n\n/* CLOSE\n -------------------- */\n\n.dialog-close {\n display: flex;\n align-items: center;\n align-self: flex-start;\n justify-content: center;\n width: 3.5rem;\n height: 3.5rem;\n padding: 0;\n color: inherit;\n cursor: pointer;\n background: transparent;\n border: 0;\n appearance: none;\n -webkit-tap-highlight-color: rgba(0, 0, 0, 0);\n}\n\n.dialog-icon {\n display: inline-block;\n width: 3rem;\n height: 3rem;\n font-size: var(--road-font-size-48);\n}\n\n/* BODY\n -------------------- */\n\n.dialog-body {\n padding: 0 1.5rem;\n text-align: center;\n}\n\n@media (min-width: 768px) {\n\n .dialog-body {\n padding: 0 3rem;\n }\n}\n\n/* TITLE\n -------------------- */\n\n.dialog-title {\n padding: 0;\n margin: 0 0 1rem;\n font-size: var(--road-body-medium);\n font-weight: 700;\n line-height: 1.2;\n}\n\n/* DESCRIPTION\n -------------------- */\n\n.dialog-description {\n margin: 0 0 0.5rem;\n overflow: auto;\n font-size: var(--road-body-medium);\n}\n\n/* FOOTER\n -------------------- */\n\n.dialog-footer {\n display: flex;\n justify-content: center;\n padding: 0 1.5rem;\n}\n\n.dialog-footer ::slotted(road-button) {\n margin-top: 1rem;\n}\n\n/**\n * Footer buttons\n */\n\n.dialog-footer .btn {\n min-width: 130px;\n max-width: calc(50% - 0.5rem);\n}\n","import { Component, Element, Event, EventEmitter, Listen, Method, Prop, h, Host } from '@stencil/core';\nimport { FeedbackColors } from '../../interface';\nimport { navigationClose, alertDangerOutline, alertInfoOutline, alertSuccessOutline, alertWarningOutline } from '../../../icons';\n\n/**\n * @slot - Content of the footer dialog if it's an action dialog add action buttons here.\n *\n * @part dialog-icon - main icon of the dialog\n */\n\n@Component({\n tag: 'road-dialog',\n styleUrl: 'dialog.css',\n shadow: true,\n})\nexport class Dialog {\n\n /**\n * Current reference of the dialog\n */\n @Element() el!: HTMLRoadDialogElement;\n\n /**\n * Set isOpen property to true to open the dialog\n */\n @Prop({ mutable: true }) isOpen: boolean = false;\n\n /**\n * Show / hide the close icon\n */\n @Prop() hasCloseIcon: boolean = true;\n\n /**\n * Set the color of information dialog. e.g. info, success, warning, danger\n */\n @Prop() color?: FeedbackColors;\n\n /**\n * override default icon\n */\n @Prop() icon?: string;\n\n /**\n * Text to the top\n */\n @Prop() label?: string;\n\n /**\n * Content description of the dialog\n */\n @Prop() description?: string;\n\n /**\n * Indicate when closing the dialog\n */\n @Event({ eventName: 'close' }) onClose!: EventEmitter<void>;\n\n /**\n * Open the dialog\n */\n @Method()\n async open() {\n this.isOpen = true;\n }\n\n /**\n * Close the dialog\n */\n @Method()\n async close() {\n this.isOpen = false;\n this.el.addEventListener('transitionend', () => {\n this.onClose.emit();\n }, { once: true});\n }\n\n /**\n * Close the dialog when clicking on the cross or layer\n */\n private onClick = (ev: UIEvent) => {\n ev.stopPropagation();\n ev.preventDefault();\n\n this.close();\n };\n\n /**\n * Close the dialog when press Escape key\n */\n @Listen('keyup', { target: 'document' })\n onEscape(event: KeyboardEvent) {\n if ((event.key === 'Escape' || event.key === \"Esc\") && this.isOpen && this.hasCloseIcon) {\n this.close();\n }\n }\n\n /**\n * Call close function when clicking an element with data-dismiss=\"modal\" attribute\n */\n componentDidLoad() {\n this.el.querySelectorAll('[data-dismiss=\"modal\"]').forEach(item => {\n item.addEventListener('click', () => this.close());\n });\n }\n\n render() {\n const modalIsOpenClass = this.isOpen ? 'dialog-open' : '';\n const modalhasClose = this.hasCloseIcon ? 'dialog-has-close' : '';\n\n let icon;\n\n if(this.icon) {\n icon = this.icon;\n } else {\n switch(this.color) {\n case 'info':\n icon = alertInfoOutline;\n break;\n case 'success':\n icon = alertSuccessOutline;\n break;\n case 'warning':\n icon = alertWarningOutline;\n break;\n case 'danger':\n icon = alertDangerOutline;\n break;\n default:\n icon = alertInfoOutline;\n break;\n }\n }\n\n return (\n <Host class={`dialog ${modalIsOpenClass} ${modalhasClose}`} role=\"alertdialog\" aria-modal=\"true\" tabindex=\"-1\" aria-labelledby=\"dialogLabel\" aria-describedby=\"dialogDesc\">\n <div class=\"dialog-overlay\" onClick={this.hasCloseIcon === true ? this.onClick : undefined} tabindex=\"-1\"></div>\n <div class=\"dialog-modal\" role=\"document\" tabindex=\"0\">\n <div class=\"dialog-content\">\n <header class=\"dialog-header\">\n {this.hasCloseIcon\n ? <button type=\"button\" class=\"dialog-close\" onClick={this.onClick} aria-label=\"Close\"><road-icon icon={navigationClose} aria-hidden=\"true\"></road-icon></button>\n : ''}\n </header>\n <div class=\"dialog-body\">\n {this.color !== undefined\n ? <road-icon class=\"dialog-icon\" part=\"dialog-icon\" color={this.color} icon={icon} aria-hidden=\"true\"></road-icon>\n : ''}\n <h2 class=\"dialog-title\" id=\"dialogLabel\">{this.label}</h2>\n <p class=\"dialog-description\" id=\"dialogDesc\">{this.description}</p>\n </div>\n <footer class=\"dialog-footer\">\n <slot/>\n </footer>\n </div>\n </div>\n </Host>\n );\n }\n}"],"mappings":"gIAAA,MAAMA,EAAY,kgE,MCeLC,EAAM,M,wDAgETC,KAAAC,QAAWC,IACjBA,EAAGC,kBACHD,EAAGE,iBAEHJ,KAAKK,OAAO,E,YA1D6B,M,kBAKX,K,yFA+BhC,UAAMC,GACJN,KAAKO,OAAS,I,CAOhB,WAAMF,GACJL,KAAKO,OAAS,MACdP,KAAKQ,GAAGC,iBAAiB,iBAAiB,KACxCT,KAAKU,QAAQC,MAAM,GAClB,CAAEC,KAAM,M,CAiBb,QAAAC,CAASC,GACP,IAAKA,EAAMC,MAAQ,UAAYD,EAAMC,MAAQ,QAAUf,KAAKO,QAAUP,KAAKgB,aAAc,CACvFhB,KAAKK,O,EAOT,gBAAAY,GACEjB,KAAKQ,GAAGU,iBAAiB,0BAA0BC,SAAQC,IACzDA,EAAKX,iBAAiB,SAAS,IAAMT,KAAKK,SAAQ,G,CAItD,MAAAgB,GACE,MAAMC,EAAmBtB,KAAKO,OAAS,cAAgB,GACvD,MAAMgB,EAAgBvB,KAAKgB,aAAe,mBAAqB,GAE/D,IAAIQ,EAEJ,GAAGxB,KAAKwB,KAAM,CACZA,EAAOxB,KAAKwB,I,KACP,CACL,OAAOxB,KAAKyB,OACZ,IAAK,OACHD,EAAOE,EACP,MACF,IAAK,UACHF,EAAOG,EACP,MACF,IAAK,UACHH,EAAOI,EACP,MACF,IAAK,SACHJ,EAAOK,EACP,MACF,QACEL,EAAOE,EACP,M,CAIJ,OACEI,EAACC,EAAI,CAACC,MAAO,UAAUV,KAAoBC,IAAiBU,KAAK,cAAa,aAAY,OAAOC,SAAS,KAAI,kBAAiB,cAAa,mBAAkB,cAC5JJ,EAAA,OAAKE,MAAM,iBAAiB/B,QAASD,KAAKgB,eAAiB,KAAOhB,KAAKC,QAAUkC,UAAWD,SAAS,OACrGJ,EAAA,OAAKE,MAAM,eAAeC,KAAK,WAAWC,SAAS,KACjDJ,EAAA,OAAKE,MAAM,kBACTF,EAAA,UAAQE,MAAM,iBACXhC,KAAKgB,aACFc,EAAA,UAAQM,KAAK,SAASJ,MAAM,eAAe/B,QAASD,KAAKC,QAAO,aAAa,SAAQ6B,EAAA,aAAWN,KAAMa,EAAe,cAAc,UACnI,IAENP,EAAA,OAAKE,MAAM,eACRhC,KAAKyB,QAAUU,UACZL,EAAA,aAAWE,MAAM,cAAcM,KAAK,cAAcb,MAAOzB,KAAKyB,MAAOD,KAAMA,EAAI,cAAc,SAC7F,GACJM,EAAA,MAAIE,MAAM,eAAeO,GAAG,eAAevC,KAAKwC,OAChDV,EAAA,KAAGE,MAAM,qBAAqBO,GAAG,cAAcvC,KAAKyC,cAEtDX,EAAA,UAAQE,MAAM,iBACZF,EAAA,gB"}
1
+ {"version":3,"names":["dialogCss","Dialog","this","onClick","ev","stopPropagation","preventDefault","close","open","isOpen","el","addEventListener","onClose","emit","once","onEscape","event","key","hasCloseIcon","componentDidLoad","querySelectorAll","forEach","item","render","modalIsOpenClass","modalhasClose","icon","color","alertInfoOutline","alertSuccessOutline","alertWarningOutline","alertDangerOutline","h","Host","class","role","tabindex","undefined","type","navigationClose","part","label","id","description"],"sources":["src/components/dialog/dialog.css?tag=road-dialog&encapsulation=shadow","src/components/dialog/dialog.tsx"],"sourcesContent":["/*\n * Dialog\n *\n * Index\n * - Overlay\n * - Dialog\n * - Content\n * - Header\n * - Close\n * - Body\n * - Title\n * - Description\n * - Footer\n */\n\n/**\n * @prop --z-index: The z-index of the Dialog.\n */\n\n:host {\n --z-index: 3;\n\n position: fixed;\n top: 0;\n left: 0;\n z-index: var(--z-index);\n display: flex;\n align-items: center;\n justify-content: center;\n width: 100%;\n height: 100%;\n overflow: hidden;\n font-family: var(--road-font, sans-serif);\n line-height: 1.5;\n color: var(--road-on-surface);\n visibility: hidden !important;\n opacity: 0;\n transition: opacity 0.15s linear, visibility 0.15s;\n}\n\n/* OVERLAY\n -------------------- */\n\n.dialog-overlay {\n position: absolute;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n display: block;\n touch-action: none;\n background: var(--road-overlay);\n}\n\n:host(.dialog-has-close) .dialog-overlay {\n cursor: pointer;\n}\n\n/* DIALOG\n -------------------- */\n\n.dialog-modal {\n position: relative;\n width: auto;\n margin: 1rem;\n pointer-events: none;\n transition: transform 0.3s ease-out;\n transform: translateY(50px);\n}\n\n/**\n * Open state\n */\n\n:host(.dialog-open) {\n visibility: visible !important;\n opacity: 1;\n}\n\n:host(.dialog-open) .dialog-modal {\n transform: none;\n}\n\n/* CONTENT\n -------------------- */\n\n.dialog-content {\n position: relative;\n display: flex;\n flex-direction: column;\n width: 100%;\n padding: 0 0 1.5rem;\n pointer-events: auto;\n background: var(--road-surface);\n background-clip: padding-box;\n border-radius: 0.25rem;\n outline: 0;\n box-shadow: var(--road-elevation-highest);\n}\n\n@media (min-width: 576px) {\n\n .dialog-content {\n max-width: 454px;\n }\n}\n\n/* HEADER\n -------------------- */\n\n.dialog-header {\n display: flex;\n align-items: center;\n justify-content: flex-end;\n height: 100%;\n max-height: 2.75rem;\n margin-bottom: 2rem;\n}\n\n/* CLOSE\n -------------------- */\n\n.dialog-close {\n display: flex;\n align-items: center;\n align-self: flex-start;\n justify-content: center;\n width: 3.5rem;\n height: 3.5rem;\n padding: 0;\n color: inherit;\n cursor: pointer;\n background: transparent;\n border: 0;\n appearance: none;\n -webkit-tap-highlight-color: rgba(0, 0, 0, 0);\n}\n\n.dialog-icon {\n display: inline-block;\n width: 3rem;\n height: 3rem;\n font-size: var(--road-font-size-48);\n}\n\n/* BODY\n -------------------- */\n\n.dialog-body {\n padding: 0 1.5rem;\n text-align: center;\n}\n\n@media (min-width: 768px) {\n\n .dialog-body {\n padding: 0 3rem;\n }\n}\n\n/* TITLE\n -------------------- */\n\n.dialog-title {\n padding: 0;\n margin: 0 0 1rem;\n font-size: var(--road-body-medium);\n font-weight: 700;\n line-height: 1.2;\n}\n\n/* DESCRIPTION\n -------------------- */\n\n.dialog-description {\n margin: 0 0 0.5rem;\n overflow: auto;\n font-size: var(--road-body-medium);\n}\n\n/* FOOTER\n -------------------- */\n\n.dialog-footer {\n display: flex;\n justify-content: center;\n padding: 0 1.5rem;\n}\n\n.dialog-footer ::slotted(road-button) {\n margin-top: 1rem;\n}\n\n/**\n * Footer buttons\n */\n\n.dialog-footer .btn {\n min-width: 130px;\n max-width: calc(50% - 0.5rem);\n}\n","import { Component, Element, Event, EventEmitter, Listen, Method, Prop, h, Host } from '@stencil/core';\nimport { FeedbackColors } from '../../interface';\nimport { navigationClose, alertDangerOutline, alertInfoOutline, alertSuccessOutline, alertWarningOutline } from '../../../icons';\n\n/**\n * @slot - Content of the footer dialog if it's an action dialog add action buttons here.\n *\n * @part dialog-icon - main icon of the dialog\n */\n\n@Component({\n tag: 'road-dialog',\n styleUrl: 'dialog.css',\n shadow: true,\n})\nexport class Dialog {\n\n /**\n * Current reference of the dialog\n */\n @Element() el!: HTMLRoadDialogElement;\n\n /**\n * Set isOpen property to true to open the dialog\n */\n @Prop({ mutable: true }) isOpen: boolean = false;\n\n /**\n * Show / hide the close icon\n */\n @Prop() hasCloseIcon: boolean = true;\n\n /**\n * Set the color of information dialog. e.g. info, success, warning, danger\n */\n @Prop() color?: FeedbackColors;\n\n /**\n * override default icon\n */\n @Prop() icon?: string;\n\n /**\n * Text to the top\n */\n @Prop() label?: string;\n\n /**\n * Content description of the dialog\n */\n @Prop() description?: string;\n\n /**\n * Indicate when closing the dialog\n */\n @Event({ eventName: 'close' }) onClose!: EventEmitter<void>;\n\n /**\n * Open the dialog\n */\n @Method()\n async open() {\n this.isOpen = true;\n }\n\n /**\n * Close the dialog\n */\n @Method()\n async close() {\n this.isOpen = false;\n this.el.addEventListener('transitionend', () => {\n this.onClose.emit();\n }, { once: true});\n }\n\n /**\n * Close the dialog when clicking on the cross or layer\n */\n private onClick = (ev: UIEvent) => {\n ev.stopPropagation();\n ev.preventDefault();\n\n this.close();\n };\n\n /**\n * Close the dialog when press Escape key\n */\n @Listen('keyup', { target: 'document' })\n onEscape(event: KeyboardEvent) {\n if ((event.key === 'Escape' || event.key === \"Esc\") && this.isOpen && this.hasCloseIcon) {\n this.close();\n }\n }\n\n /**\n * Call close function when clicking an element with data-dismiss=\"modal\" attribute\n */\n componentDidLoad() {\n this.el.querySelectorAll('[data-dismiss=\"modal\"]').forEach(item => {\n item.addEventListener('click', () => this.close());\n });\n }\n\n render() {\n const modalIsOpenClass = this.isOpen ? 'dialog-open' : '';\n const modalhasClose = this.hasCloseIcon ? 'dialog-has-close' : '';\n\n let icon;\n\n if(this.icon) {\n icon = this.icon;\n } else {\n switch(this.color) {\n case 'info':\n icon = alertInfoOutline;\n break;\n case 'success':\n icon = alertSuccessOutline;\n break;\n case 'warning':\n icon = alertWarningOutline;\n break;\n case 'danger':\n icon = alertDangerOutline;\n break;\n default:\n icon = alertInfoOutline;\n break;\n }\n }\n\n return (\n <Host class={`dialog ${modalIsOpenClass} ${modalhasClose}`} role=\"alertdialog\" aria-modal=\"true\" tabindex=\"-1\" aria-label=\"dialogLabel\">\n <div class=\"dialog-overlay\" onClick={this.hasCloseIcon === true ? this.onClick : undefined} tabindex=\"-1\"></div>\n <div class=\"dialog-modal\" role=\"document\" tabindex=\"0\">\n <div class=\"dialog-content\">\n <header class=\"dialog-header\">\n {this.hasCloseIcon\n ? <button type=\"button\" class=\"dialog-close\" onClick={this.onClick} aria-label=\"Close\"><road-icon icon={navigationClose} aria-hidden=\"true\"></road-icon></button>\n : ''}\n </header>\n <div class=\"dialog-body\">\n {this.color !== undefined\n ? <road-icon class=\"dialog-icon\" part=\"dialog-icon\" color={this.color} icon={icon} aria-hidden=\"true\"></road-icon>\n : ''}\n <h2 class=\"dialog-title\">{this.label}</h2>\n <p class=\"dialog-description\" id=\"dialogDesc\">{this.description}</p>\n </div>\n <footer class=\"dialog-footer\">\n <slot/>\n </footer>\n </div>\n </div>\n </Host>\n );\n }\n}"],"mappings":"gIAAA,MAAMA,EAAY,kgE,MCeLC,EAAM,M,wDAgETC,KAAAC,QAAWC,IACjBA,EAAGC,kBACHD,EAAGE,iBAEHJ,KAAKK,OAAO,E,YA1D6B,M,kBAKX,K,yFA+BhC,UAAMC,GACJN,KAAKO,OAAS,I,CAOhB,WAAMF,GACJL,KAAKO,OAAS,MACdP,KAAKQ,GAAGC,iBAAiB,iBAAiB,KACxCT,KAAKU,QAAQC,MAAM,GAClB,CAAEC,KAAM,M,CAiBb,QAAAC,CAASC,GACP,IAAKA,EAAMC,MAAQ,UAAYD,EAAMC,MAAQ,QAAUf,KAAKO,QAAUP,KAAKgB,aAAc,CACvFhB,KAAKK,O,EAOT,gBAAAY,GACEjB,KAAKQ,GAAGU,iBAAiB,0BAA0BC,SAAQC,IACzDA,EAAKX,iBAAiB,SAAS,IAAMT,KAAKK,SAAQ,G,CAItD,MAAAgB,GACE,MAAMC,EAAmBtB,KAAKO,OAAS,cAAgB,GACvD,MAAMgB,EAAgBvB,KAAKgB,aAAe,mBAAqB,GAE/D,IAAIQ,EAEJ,GAAGxB,KAAKwB,KAAM,CACZA,EAAOxB,KAAKwB,I,KACP,CACL,OAAOxB,KAAKyB,OACZ,IAAK,OACHD,EAAOE,EACP,MACF,IAAK,UACHF,EAAOG,EACP,MACF,IAAK,UACHH,EAAOI,EACP,MACF,IAAK,SACHJ,EAAOK,EACP,MACF,QACEL,EAAOE,EACP,M,CAIJ,OACEI,EAACC,EAAI,CAACC,MAAO,UAAUV,KAAoBC,IAAiBU,KAAK,cAAa,aAAY,OAAOC,SAAS,KAAI,aAAY,eACxHJ,EAAA,OAAKE,MAAM,iBAAiB/B,QAASD,KAAKgB,eAAiB,KAAOhB,KAAKC,QAAUkC,UAAWD,SAAS,OACrGJ,EAAA,OAAKE,MAAM,eAAeC,KAAK,WAAWC,SAAS,KACjDJ,EAAA,OAAKE,MAAM,kBACTF,EAAA,UAAQE,MAAM,iBACXhC,KAAKgB,aACFc,EAAA,UAAQM,KAAK,SAASJ,MAAM,eAAe/B,QAASD,KAAKC,QAAO,aAAa,SAAQ6B,EAAA,aAAWN,KAAMa,EAAe,cAAc,UACnI,IAENP,EAAA,OAAKE,MAAM,eACRhC,KAAKyB,QAAUU,UACZL,EAAA,aAAWE,MAAM,cAAcM,KAAK,cAAcb,MAAOzB,KAAKyB,MAAOD,KAAMA,EAAI,cAAc,SAC7F,GACJM,EAAA,MAAIE,MAAM,gBAAgBhC,KAAKuC,OAC/BT,EAAA,KAAGE,MAAM,qBAAqBQ,GAAG,cAAcxC,KAAKyC,cAEtDX,EAAA,UAAQE,MAAM,iBACZF,EAAA,gB"}
@@ -1,2 +1,2 @@
1
- import{r as o,c as e,h as a,H as t,a as i}from"./p-f3d586b3.js";import{a as r}from"./p-73fe2357.js";const d=":host{--z-index:3;position:fixed;top:0;left:0;z-index:var(--z-index);display:flex;align-items:center;justify-content:center;width:100%;height:100%;overflow:hidden;font-family:var(--road-font, sans-serif);line-height:1.5;color:var(--road-grey-900);visibility:hidden !important;opacity:0;transition:opacity 0.15s linear, visibility 0.15s}.modal-overlay{position:absolute;top:0;right:0;bottom:0;left:0;display:block;touch-action:none;cursor:pointer;background:var(--road-overlay)}.modal-dialog{position:relative;width:100%;pointer-events:none;transition:transform 0.3s ease-out;transform:translateY(50px)}:host(.modal-open){visibility:visible !important;opacity:1}:host(.modal-open) .modal-dialog{transform:none}.modal-content{position:relative;display:flex;flex-direction:column;width:100%;height:100vh;pointer-events:auto;background:var(--road-surface);background-clip:padding-box;box-shadow:var(--road-elevation-hight)}@media (min-width: 768px){.modal-content{height:auto;border-radius:0.25rem}}.modal-header{display:flex;align-items:center;justify-content:flex-end;color:var(--road-on-header-surface);background:var(--road-header-surface)}.modal-header road-icon{color:var(--road-header-icon)}@media (min-width: 768px){.modal-header{border-radius:0.25rem 0.25rem 0 0}}.modal-header-inverse{color:var(--road-on-surface);background:none}.modal-header-inverse road-icon{color:var(--road-icon)}.modal-action,.modal-close{display:flex;align-items:center;justify-content:center;width:3.5rem;height:3.5rem;padding:0;font-weight:700;color:inherit;cursor:pointer;background:transparent;border:0;-webkit-appearance:none;appearance:none;-webkit-tap-highlight-color:rgba(0, 0, 0, 0)}.modal-action~.modal-title,.modal-close~.modal-title{padding-left:0}.modal-action-left,.modal-close-left{margin-right:auto}.modal-title{display:flex;flex-grow:1;align-items:center;justify-content:center;height:3.5rem;padding-left:3.5rem;margin:0;font-size:var(--road-body-medium);font-weight:400}.modal-body{padding:2.5rem 0.5rem;overflow-y:auto}.modal-header-inverse+.modal-body{padding-top:0}@media (min-width: 768px){.modal-body{max-height:86vh;padding-right:5rem;padding-left:5rem}}";const n=class{constructor(a){o(this,a);this.onClose=e(this,"close",7);this.onClick=o=>{o.stopPropagation();o.preventDefault();this.close()};this.maxWidth=696;this.isOpen=false;this.hasInverseHeader=false;this.modalTitle=undefined;this.hasCloseIcon=true}async open(){this.isOpen=true}async close(){this.isOpen=false;this.el.addEventListener("transitionend",(()=>{this.onClose.emit()}),{once:true})}onEscape(o){if(o.key==="Escape"||o.key==="Esc"){this.close()}}componentDidLoad(){this.el.querySelectorAll('[data-dismiss="modal"]').forEach((o=>{o.addEventListener("click",(()=>this.close()))}))}render(){const o=this.isOpen?"modal-open":"";const e=this.hasInverseHeader?"modal-header-inverse":"";const i=this.hasCloseIcon?a("button",{type:"button",class:"modal-close",onClick:this.onClick,"aria-label":"Close"},a("road-icon",{icon:r,"aria-hidden":"true"})):"";return a(t,{class:`modal ${o}`,tabindex:"-1",role:"dialog"},a("div",{class:"modal-overlay",onClick:this.onClick,tabindex:"-1"}),a("div",{class:"modal-dialog",style:{maxWidth:`${this.maxWidth}px`},role:"document",tabindex:"0"},a("div",{class:"modal-content"},a("header",{class:`modal-header ${e}`},a("h2",{class:"modal-title"},this.modalTitle),i),a("div",{class:"modal-body"},a("slot",null)))))}get el(){return i(this)}};n.style=d;export{n as road_modal};
2
- //# sourceMappingURL=p-a73ef7de.entry.js.map
1
+ import{r as a,c as o,h as e,H as i,a as t}from"./p-f3d586b3.js";import{a as r}from"./p-ac7a8bca.js";const d=":host{--z-index:3;position:fixed;top:0;left:0;z-index:var(--z-index);display:flex;align-items:center;justify-content:center;width:100%;height:100%;overflow:hidden;font-family:var(--road-font, sans-serif);line-height:1.5;color:var(--road-grey-900);visibility:hidden !important;opacity:0;transition:opacity 0.15s linear, visibility 0.15s}.modal-overlay{position:absolute;top:0;right:0;bottom:0;left:0;display:block;touch-action:none;cursor:pointer;background:var(--road-overlay)}.modal-dialog{position:relative;width:100%;pointer-events:none;transition:transform 0.3s ease-out;transform:translateY(50px)}:host(.modal-open){visibility:visible !important;opacity:1}:host(.modal-open) .modal-dialog{transform:none}.modal-content{position:relative;display:flex;flex-direction:column;width:100%;height:100vh;pointer-events:auto;background:var(--road-surface);background-clip:padding-box;box-shadow:var(--road-elevation-hight)}@media (min-width: 768px){.modal-content{height:auto;border-radius:0.25rem}}.modal-header{display:flex;align-items:center;justify-content:flex-end;color:var(--road-on-header-surface);background:var(--road-header-surface)}.modal-header road-icon{color:var(--road-header-icon)}@media (min-width: 768px){.modal-header{border-radius:0.25rem 0.25rem 0 0}}.modal-header-inverse{color:var(--road-on-surface);background:none}.modal-header-inverse road-icon{color:var(--road-icon)}.modal-action,.modal-close{display:flex;align-items:center;justify-content:center;width:3.5rem;height:3.5rem;padding:0;font-weight:700;color:inherit;cursor:pointer;background:transparent;border:0;-webkit-appearance:none;appearance:none;-webkit-tap-highlight-color:rgba(0, 0, 0, 0)}.modal-action~.modal-title,.modal-close~.modal-title{padding-left:0}.modal-action-left,.modal-close-left{margin-right:auto}.modal-title{display:flex;flex-grow:1;align-items:center;justify-content:center;height:3.5rem;padding-left:3.5rem;margin:0;font-size:var(--road-body-medium);font-weight:400}.modal-body{padding:2.5rem 0.5rem;overflow-y:auto}.modal-header-inverse+.modal-body{padding-top:0}@media (min-width: 768px){.modal-body{max-height:86vh;padding-right:var(--road-spacing-06);padding-left:var(--road-spacing-06)}}";const n=class{constructor(e){a(this,e);this.onClose=o(this,"close",7);this.onClick=a=>{a.stopPropagation();a.preventDefault();this.close()};this.maxWidth=696;this.isOpen=false;this.hasInverseHeader=false;this.modalTitle=undefined;this.hasCloseIcon=true}async open(){this.isOpen=true}async close(){this.isOpen=false;this.el.addEventListener("transitionend",(()=>{this.onClose.emit()}),{once:true})}onEscape(a){if(a.key==="Escape"||a.key==="Esc"){this.close()}}componentDidLoad(){this.el.querySelectorAll('[data-dismiss="modal"]').forEach((a=>{a.addEventListener("click",(()=>this.close()))}))}render(){const a=this.isOpen?"modal-open":"";const o=this.hasInverseHeader?"modal-header-inverse":"";const t=this.hasCloseIcon?e("button",{type:"button",class:"modal-close",onClick:this.onClick,"aria-label":"Close"},e("road-icon",{icon:r,"aria-hidden":"true"})):"";return e(i,{class:`modal ${a}`,tabindex:"-1",role:"dialog","aria-label":"modal"},e("div",{class:"modal-overlay",onClick:this.onClick,tabindex:"-1"}),e("div",{class:"modal-dialog",style:{maxWidth:`${this.maxWidth}px`},role:"document",tabindex:"0"},e("div",{class:"modal-content"},e("header",{class:`modal-header ${o}`},e("h2",{class:"modal-title"},this.modalTitle),t),e("div",{class:"modal-body"},e("slot",null)))))}get el(){return t(this)}};n.style=d;export{n as road_modal};
2
+ //# sourceMappingURL=p-233eb25c.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["modalCss","Modal","this","onClick","ev","stopPropagation","preventDefault","close","open","isOpen","el","addEventListener","onClose","emit","once","onEscape","event","key","componentDidLoad","querySelectorAll","forEach","item","render","modalIsOpenClass","inverseHeaderClass","hasInverseHeader","closeIconElement","hasCloseIcon","h","type","class","icon","navigationClose","Host","tabindex","role","style","maxWidth","modalTitle"],"sources":["src/components/modal/modal.css?tag=road-modal&encapsulation=shadow","src/components/modal/modal.tsx"],"sourcesContent":["/*\n * Modal\n *\n * Index\n * - Overlay\n * - Modal\n * - Content\n * - Header\n * - Actions\n * - Title\n * - Body\n */\n\n/**\n * @prop --z-index: The z-index of the Modal.\n */\n\n\n/* OVERLAY\n -------------------- */\n\n:host {\n --z-index: 3;\n\n position: fixed;\n top: 0;\n left: 0;\n z-index: var(--z-index);\n display: flex;\n align-items: center;\n justify-content: center;\n width: 100%;\n height: 100%;\n overflow: hidden;\n font-family: var(--road-font, sans-serif);\n line-height: 1.5;\n color: var(--road-grey-900);\n visibility: hidden !important;\n opacity: 0;\n transition: opacity 0.15s linear, visibility 0.15s;\n}\n\n/* OVERLAY\n -------------------- */\n\n.modal-overlay {\n position: absolute;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n display: block;\n touch-action: none;\n cursor: pointer;\n background: var(--road-overlay);\n}\n\n/* MODAL\n -------------------- */\n\n.modal-dialog {\n position: relative;\n width: 100%;\n pointer-events: none;\n transition: transform 0.3s ease-out;\n transform: translateY(50px);\n}\n\n/**\n * Open state\n */\n\n:host(.modal-open) {\n visibility: visible !important;\n opacity: 1;\n}\n\n:host(.modal-open) .modal-dialog {\n transform: none;\n}\n\n/* CONTENT\n -------------------- */\n\n.modal-content {\n position: relative;\n display: flex;\n flex-direction: column;\n width: 100%;\n height: 100vh;\n pointer-events: auto;\n background: var(--road-surface);\n background-clip: padding-box;\n box-shadow: var(--road-elevation-hight);\n}\n\n@media (min-width: 768px) {\n\n .modal-content {\n height: auto;\n border-radius: 0.25rem;\n }\n}\n\n/* HEADER\n -------------------- */\n\n.modal-header {\n display: flex;\n align-items: center;\n justify-content: flex-end;\n color: var(--road-on-header-surface);\n background: var(--road-header-surface);\n}\n\n.modal-header road-icon {\n color: var(--road-header-icon);\n}\n\n@media (min-width: 768px) {\n\n .modal-header {\n border-radius: 0.25rem 0.25rem 0 0;\n }\n}\n\n/**\n * Modal header inverse colors\n */\n\n.modal-header-inverse {\n color: var(--road-on-surface);\n background: none;\n}\n\n.modal-header-inverse road-icon {\n color: var(--road-icon);\n}\n\n/* ACTIONS\n -------------------- */\n\n.modal-action,\n.modal-close {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 3.5rem;\n height: 3.5rem;\n padding: 0;\n font-weight: 700;\n color: inherit;\n cursor: pointer;\n background: transparent;\n border: 0;\n appearance: none;\n -webkit-tap-highlight-color: rgba(0, 0, 0, 0);\n}\n\n.modal-action ~ .modal-title,\n.modal-close ~ .modal-title {\n padding-left: 0;\n}\n\n.modal-action-left,\n.modal-close-left {\n margin-right: auto;\n}\n\n/* TITLE\n -------------------- */\n\n.modal-title {\n display: flex;\n flex-grow: 1;\n align-items: center;\n justify-content: center;\n height: 3.5rem;\n padding-left: 3.5rem;\n margin: 0;\n font-size: var(--road-body-medium);\n font-weight: 400;\n}\n\n/* BODY\n -------------------- */\n\n.modal-body {\n padding: 2.5rem 0.5rem;\n overflow-y: auto;\n}\n\n.modal-header-inverse + .modal-body {\n padding-top: 0;\n}\n\n@media (min-width: 768px) {\n\n .modal-body {\n max-height: 86vh;\n padding-right: var(--road-spacing-06);\n padding-left: var(--road-spacing-06);\n }\n}\n","import { Component, Element, Event, EventEmitter, Listen, Method, Prop, h, Host } from '@stencil/core';\nimport { navigationClose } from '../../../icons';\n\n/**\n * @slot - Content of the modal.\n */\n\n@Component({\n tag: 'road-modal',\n styleUrl: 'modal.css',\n shadow: true,\n})\nexport class Modal {\n\n /**\n * Current reference of the modal\n */\n @Element() el!: HTMLRoadModalElement;\n\n /**\n * Max width of the modal on desktop\n */\n @Prop() maxWidth: number = 696;\n\n /**\n * Set isOpen propertie to true to show the modal\n */\n @Prop({ mutable: true }) isOpen: boolean = false;\n\n /**\n * inverse header colors\n */\n @Prop() hasInverseHeader: boolean = false;\n\n /**\n * Title of the modal in the header bar\n */\n @Prop() modalTitle?: string;\n\n /**\n * Show / hide close icon\n */\n @Prop() hasCloseIcon: boolean = true;\n\n /**\n * Indicate when closing the modal\n */\n @Event({ eventName: 'close' }) onClose!: EventEmitter<void>;\n\n /**\n * Open the modal\n */\n @Method()\n async open() {\n this.isOpen = true;\n }\n\n /**\n * Close the modal\n */\n @Method()\n async close() {\n this.isOpen = false;\n this.el.addEventListener('transitionend', () => {\n this.onClose.emit();\n }, { once: true});\n }\n\n /**\n * Close the dialog when clicking on the cross or layer\n */\n private onClick = (ev: UIEvent) => {\n ev.stopPropagation();\n ev.preventDefault();\n\n this.close();\n };\n\n /**\n * Close the dialog when press Escape key\n */\n @Listen('keyup', { target: 'document' })\n onEscape(event: KeyboardEvent) {\n if (event.key === 'Escape' || event.key === \"Esc\") {\n this.close();\n }\n }\n\n /**\n * Call close function when clicking an element with data-dismiss=\"modal\" attribute\n */\n componentDidLoad() {\n this.el.querySelectorAll('[data-dismiss=\"modal\"]').forEach(item => {\n item.addEventListener('click', () => this.close());\n });\n }\n\n render() {\n const modalIsOpenClass = this.isOpen ? 'modal-open' : '';\n const inverseHeaderClass = this.hasInverseHeader ? 'modal-header-inverse' : '';\n const closeIconElement = this.hasCloseIcon ? <button type=\"button\" class=\"modal-close\" onClick={this.onClick} aria-label=\"Close\"><road-icon icon={navigationClose} aria-hidden=\"true\"></road-icon></button> : '';\n\n return (\n <Host class={`modal ${modalIsOpenClass}`} tabindex=\"-1\" role=\"dialog\" aria-label=\"modal\">\n <div class=\"modal-overlay\" onClick={this.onClick} tabindex=\"-1\"></div>\n <div class=\"modal-dialog\" style={{ maxWidth: `${this.maxWidth}px` }} role=\"document\" tabindex=\"0\">\n <div class=\"modal-content\">\n <header class={`modal-header ${inverseHeaderClass}`}>\n <h2 class=\"modal-title\">{this.modalTitle}</h2>\n {closeIconElement}\n </header>\n <div class=\"modal-body\">\n <slot/>\n </div>\n </div>\n </div>\n </Host>\n );\n }\n}"],"mappings":"oGAAA,MAAMA,EAAW,qpE,MCYJC,EAAK,M,wDA2DRC,KAAAC,QAAWC,IACjBA,EAAGC,kBACHD,EAAGE,iBAEHJ,KAAKK,OAAO,E,cArDa,I,YAKgB,M,sBAKP,M,4CAUJ,I,CAWhC,UAAMC,GACJN,KAAKO,OAAS,I,CAOhB,WAAMF,GACJL,KAAKO,OAAS,MACdP,KAAKQ,GAAGC,iBAAiB,iBAAiB,KACxCT,KAAKU,QAAQC,MAAM,GAClB,CAAEC,KAAM,M,CAiBb,QAAAC,CAASC,GACP,GAAIA,EAAMC,MAAQ,UAAYD,EAAMC,MAAQ,MAAO,CACjDf,KAAKK,O,EAOT,gBAAAW,GACEhB,KAAKQ,GAAGS,iBAAiB,0BAA0BC,SAAQC,IACzDA,EAAKV,iBAAiB,SAAS,IAAMT,KAAKK,SAAQ,G,CAItD,MAAAe,GACE,MAAMC,EAAmBrB,KAAKO,OAAS,aAAe,GACtD,MAAMe,EAAqBtB,KAAKuB,iBAAmB,uBAAyB,GAC5E,MAAMC,EAAmBxB,KAAKyB,aAAeC,EAAA,UAAQC,KAAK,SAASC,MAAM,cAAc3B,QAASD,KAAKC,QAAO,aAAa,SAAQyB,EAAA,aAAWG,KAAMC,EAAe,cAAc,UAA+B,GAE9M,OACEJ,EAACK,EAAI,CAACH,MAAO,SAASP,IAAoBW,SAAS,KAAKC,KAAK,SAAQ,aAAY,SAC/EP,EAAA,OAAKE,MAAM,gBAAgB3B,QAASD,KAAKC,QAAS+B,SAAS,OAC3DN,EAAA,OAAKE,MAAM,eAAeM,MAAO,CAAEC,SAAU,GAAGnC,KAAKmC,cAAgBF,KAAK,WAAWD,SAAS,KAC5FN,EAAA,OAAKE,MAAM,iBACTF,EAAA,UAAQE,MAAO,gBAAgBN,KAC7BI,EAAA,MAAIE,MAAM,eAAe5B,KAAKoC,YAC7BZ,GAEHE,EAAA,OAAKE,MAAM,cACTF,EAAA,gB"}
@@ -0,0 +1,2 @@
1
+ import{r as e,c as r,h as t}from"./p-f3d586b3.js";import{l as a}from"./p-ac7a8bca.js";const n=".sc-road-plate-number-h{display:block}.plate-number.sc-road-plate-number{--margin-bottom:0}.plate-number-start.sc-road-plate-number,.plate-number-end.sc-road-plate-number{width:1.75rem;height:calc(3rem - 0.25rem);background:var(--road-info-50)}.input-group-prepend.sc-road-plate-number{margin-right:-1px}.input-group-prepend.sc-road-plate-number,.input-group-append.sc-road-plate-number{padding:0}.plate-number-start.sc-road-plate-number{display:flex;flex-direction:column;align-items:center;justify-content:center;padding:0;margin-right:0;margin-left:1px;color:var(--road-icon-inverse);border-radius:0.125rem 0 0 0.125rem}.plate-number-icon.sc-road-plate-number{width:1.25rem;height:1.25rem;color:#f3db53}.plate-number-location.sc-road-plate-number{font-size:var(--road-button-medium);font-weight:700}.plate-number-end.sc-road-plate-number{margin-right:1px;border-radius:0 0.125rem 0.125rem 0}.plate-number-be.sc-road-plate-number .plate-number-input.sc-road-plate-number{color:var(--road-on-danger-surface)}.plate-number-be.sc-road-plate-number .plate-number-input.sc-road-plate-number,.plate-number-be.sc-road-plate-number .input-group-append.sc-road-plate-number,.plate-number-be.sc-road-plate-number .input-group-prepend.sc-road-plate-number{border-color:var(--road-danger-outline)}.plate-number-input.sc-road-plate-number{position:relative;display:block;height:3rem;margin:0;font-family:var(--road-font, sans-serif);font-size:var(--road-heading-04);font-weight:700;color:var(--road-on-surface);text-align:center;background:var(--road-surface);border:1px solid var(--road-input-outline);border-radius:0;outline:0;box-shadow:none;-webkit-appearance:none;appearance:none}.plate-number-input.sc-road-plate-number::placeholder{color:var(--road-on-surface-weak);opacity:1}.plate-number-input.sc-road-plate-number:disabled{color:var(--road-on-surface-disabled);cursor:not-allowed;background:var(--road-surface-disabled);opacity:1}.plate-number-input.sc-road-plate-number:disabled~.input-group-prepend.sc-road-plate-number,.plate-number-input.sc-road-plate-number:disabled~.input-group-append.sc-road-plate-number{cursor:not-allowed;background:var(--road-surface-disabled)}@media (hover: hover){.plate-number-input.sc-road-plate-number:not(:disabled):not([readonly]):hover{border-color:var(--road-input-outline-variant)}}.plate-number-input.sc-road-plate-number:not([readonly]):focus{border-color:var(--road-input-outline-variant);outline:0}.motorbike-plate.sc-road-plate-number .plate-number-input.sc-road-plate-number{height:6rem;padding:0.75rem 1rem 0;resize:none;border-left:0}.motorbike-plate.sc-road-plate-number .input-group-prepend.sc-road-plate-number,.motorbike-plate.sc-road-plate-number .input-group-append.sc-road-plate-number{align-items:flex-start;height:6rem;padding:0}.motorbike-plate.sc-road-plate-number .plate-number-start.sc-road-plate-number{margin-top:1px;border-radius:0.125rem 0 0}.motorbike-plate.sc-road-plate-number .plate-number-end.sc-road-plate-number{margin-top:1px;border-radius:0 0.125rem 0 0}";const o=class{constructor(t){e(this,t);this.roadinput=r(this,"roadinput",7);this.roadInput=r(this,"roadInput",7);this.roadchange=r(this,"roadchange",7);this.roadChange=r(this,"roadChange",7);this.roadblur=r(this,"roadblur",7);this.roadBlur=r(this,"roadBlur",7);this.roadfocus=r(this,"roadfocus",7);this.roadFocus=r(this,"roadFocus",7);this.countries=[{country:"FR",letter:"F",placeholder:"AT-857-YY"},{country:"BE",letter:"B",placeholder:"1-AAA-001"},{country:"IT",letter:"I",placeholder:"AT 814TX"},{country:"ES",letter:"E",placeholder:"9512 HVY"},{country:"PT",letter:"P",placeholder:"13 24 PZ"},{country:"PL",letter:"PL",placeholder:"GD 921KF"},{country:"AT",letter:"A",placeholder:"FF 10 FF"},{country:"DE",letter:"D",placeholder:"RA KL 8136"}];this.onInput=e=>{const r=e.target;if(r){r.value=r.value.toUpperCase()||""}this.roadinput.emit(e);this.roadInput.emit(e)};this.onBlur=()=>{this.roadblur.emit();this.roadBlur.emit()};this.onFocus=()=>{this.roadfocus.emit();this.roadFocus.emit()};this.country="FR";this.disabled=false;this.placeholder=undefined;this.readonly=false;this.value="";this.motorbike=undefined}valueChanged(){this.roadchange.emit({value:this.value==null?this.value:this.value.toString()});this.roadChange.emit({value:this.value==null?this.value:this.value.toString()})}getValue(){return typeof this.value==="number"?this.value.toString():(this.value||"").toString()}render(){const e=this.getValue();const r=this.motorbike?"motorbike-plate":"";return t("road-input-group",{class:`plate-number plate-number-${this.country.toLowerCase()} ${r}`},t("label",{slot:"prepend",class:"input-group-prepend"},t("div",{class:"plate-number-start"},t("road-icon",{class:"plate-number-icon",icon:a}),t("div",{class:"plate-number-location","aria-label":this.country,role:"img"},this.countries.filter((e=>e.country===this.country))[0].letter))),this.motorbike?t("textarea",{class:"form-control plate-number-input mb-0",disabled:this.disabled,placeholder:this.placeholder!=null?this.placeholder:this.countries.filter((e=>e.country===this.country))[0].placeholder,readOnly:this.readonly,maxlength:"9",rows:2,onInput:this.onInput,onBlur:this.onBlur,onFocus:this.onFocus}):t("input",{class:"plate-number-input mb-0",disabled:this.disabled,placeholder:this.placeholder!=null?this.placeholder:this.countries.filter((e=>e.country===this.country))[0].placeholder,readOnly:this.readonly,value:e,onInput:this.onInput,onBlur:this.onBlur,onFocus:this.onFocus}),t("label",{slot:"append",class:"input-group-append"},t("div",{class:"plate-number-end"})))}static get watchers(){return{value:["valueChanged"]}}};o.style=n;export{o as road_plate_number};
2
+ //# sourceMappingURL=p-27d2770a.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["plateNumberCss","PlateNumber","this","countries","country","letter","placeholder","onInput","ev","input","target","value","toUpperCase","roadinput","emit","roadInput","onBlur","roadblur","roadBlur","onFocus","roadfocus","roadFocus","valueChanged","roadchange","toString","roadChange","getValue","render","motorbikeClass","motorbike","h","class","toLowerCase","slot","icon","licensePlateStarEu","role","filter","item","disabled","readOnly","readonly","maxlength","rows"],"sources":["src/components/plate-number/plate-number.css?tag=road-plate-number&encapsulation=scoped","src/components/plate-number/plate-number.tsx"],"sourcesContent":["/*\n * Plate Number\n *\n * Index\n * - Plate Number\n * - Input\n */\n\n/* PLATE NUMBER\n -------------------- */\n\n:host {\n display: block;\n}\n\n.plate-number {\n --margin-bottom: 0;\n}\n\n.plate-number-start,\n.plate-number-end {\n width: 1.75rem;\n height: calc(3rem - 0.25rem);\n background: var(--road-info-50);\n}\n\n.input-group-prepend {\n margin-right: -1px;\n}\n\n.input-group-prepend,\n.input-group-append {\n padding: 0;\n}\n\n.plate-number-start {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n padding: 0;\n margin-right: 0;\n margin-left: 1px;\n color: var(--road-icon-inverse);\n border-radius: 0.125rem 0 0 0.125rem;\n}\n\n.plate-number-icon {\n width: 1.25rem;\n height: 1.25rem;\n color: #f3db53;\n}\n\n.plate-number-location {\n font-size: var(--road-button-medium);\n font-weight: 700;\n}\n\n.plate-number-end {\n margin-right: 1px;\n border-radius: 0 0.125rem 0.125rem 0;\n}\n\n.plate-number-be .plate-number-input {\n color: var(--road-on-danger-surface);\n}\n\n.plate-number-be .plate-number-input,\n.plate-number-be .input-group-append,\n.plate-number-be .input-group-prepend {\n border-color: var(--road-danger-outline);\n}\n\n/* INPUT\n -------------------- */\n\n.plate-number-input {\n position: relative;\n display: block;\n height: 3rem;\n margin: 0;\n font-family: var(--road-font, sans-serif);\n font-size: var(--road-heading-04);\n font-weight: 700;\n color: var(--road-on-surface);\n text-align: center;\n background: var(--road-surface);\n border: 1px solid var(--road-input-outline);\n border-radius: 0;\n outline: 0;\n box-shadow: none;\n appearance: none;\n}\n\n.plate-number-input::placeholder {\n color: var(--road-on-surface-weak);\n opacity: 1;\n}\n\n/**\n * Disabled state\n */\n\n.plate-number-input:disabled {\n color: var(--road-on-surface-disabled);\n cursor: not-allowed;\n background: var(--road-surface-disabled);\n opacity: 1;\n}\n\n.plate-number-input:disabled ~ .input-group-prepend,\n.plate-number-input:disabled ~ .input-group-append {\n cursor: not-allowed;\n background: var(--road-surface-disabled);\n}\n\n/**\n * Hover state\n */\n\n@media (hover: hover) {\n\n .plate-number-input:not(:disabled):not([readonly]):hover {\n border-color: var(--road-input-outline-variant);\n }\n}\n\n/**\n * Focus state\n */\n\n.plate-number-input:not([readonly]):focus {\n border-color: var(--road-input-outline-variant);\n outline: 0;\n}\n\n/* MOTORBIKE\n -------------------- */\n\n.motorbike-plate .plate-number-input {\n height: 6rem;\n padding: 0.75rem 1rem 0;\n resize: none;\n border-left: 0;\n}\n\n.motorbike-plate .input-group-prepend,\n.motorbike-plate .input-group-append {\n align-items: flex-start;\n height: 6rem;\n padding: 0;\n}\n\n.motorbike-plate .plate-number-start {\n margin-top: 1px;\n border-radius: 0.125rem 0 0;\n}\n\n.motorbike-plate .plate-number-end {\n margin-top: 1px;\n border-radius: 0 0.125rem 0 0;\n}\n","import { Component, h, Prop, Event, EventEmitter, Watch } from '@stencil/core';\nimport { licensePlateStarEu } from '../../../icons';\n\n@Component({\n tag: 'road-plate-number',\n styleUrl: 'plate-number.css',\n scoped: true,\n})\nexport class PlateNumber {\n\n private countries = [\n {\n country: 'FR',\n letter: 'F',\n placeholder: 'AT-857-YY',\n },\n {\n country: 'BE',\n letter: 'B',\n placeholder: '1-AAA-001',\n },\n {\n country: 'IT',\n letter: 'I',\n placeholder: 'AT 814TX',\n },\n {\n country: 'ES',\n letter: 'E',\n placeholder: '9512 HVY',\n },\n {\n country: 'PT',\n letter: 'P',\n placeholder: '13 24 PZ',\n },\n {\n country: 'PL',\n letter: 'PL',\n placeholder: 'GD 921KF',\n },\n {\n country: 'AT',\n letter: 'A',\n placeholder: 'FF 10 FF',\n },\n {\n country: 'DE',\n letter: 'D',\n placeholder: 'RA KL 8136',\n }\n ];\n\n /**\n * country of the plate\n */\n @Prop() country: 'FR' | 'BE' | 'IT' | 'ES' | 'PT' | 'PL' | 'AT' | 'DE' = 'FR';\n\n /**\n * If `true`, the user cannot interact with the input.\n */\n @Prop() disabled = false;\n\n /**\n * overwrite the default placeholder\n */\n @Prop() placeholder?: string;\n\n /**\n * If `true`, the user cannot modify the value.\n */\n @Prop() readonly = false;\n\n /**\n * The value of the input.\n */\n @Prop({ mutable: true }) value?: string | number | null = '';\n\n /**\n * Enable motorbike display\n */\n @Prop() motorbike?: boolean;\n\n /**\n * Update the native input element when the value changes\n */\n @Watch('value')\n protected valueChanged() {\n this.roadchange.emit({ value: this.value == null ? this.value : this.value.toString() });\n this.roadChange.emit({ value: this.value == null ? this.value : this.value.toString() });\n }\n\n /**\n * Emitted when a keyboard input occurred.\n */\n @Event() roadinput!: EventEmitter<KeyboardEvent>;\n /** @internal */\n @Event() roadInput!: EventEmitter<KeyboardEvent>;\n\n /**\n * Emitted when the value has changed.\n */\n @Event() roadchange!: EventEmitter<{\n value: string | undefined | null;\n }>;\n /** @internal */\n @Event() roadChange!: EventEmitter<{\n value: string | undefined | null;\n }>;\n\n /**\n * Emitted when the input loses focus.\n */\n @Event() roadblur!: EventEmitter<void>;\n /** @internal */\n @Event() roadBlur!: EventEmitter<void>;\n\n /**\n * Emitted when the input has focus.\n */\n @Event() roadfocus!: EventEmitter<void>;\n /** @internal */\n @Event() roadFocus!: EventEmitter<void>;\n\n private getValue(): string {\n return typeof this.value === 'number'\n ? this.value.toString()\n : (this.value || '').toString();\n }\n\n private onInput = (ev: Event) => {\n const input = ev.target as HTMLInputElement | null;\n if (input) {\n input.value = input.value.toUpperCase() || \"\";\n }\n this.roadinput.emit(ev as KeyboardEvent);\n this.roadInput.emit(ev as KeyboardEvent);\n };\n\n private onBlur = () => {\n this.roadblur.emit();\n this.roadBlur.emit();\n };\n\n private onFocus = () => {\n this.roadfocus.emit();\n this.roadFocus.emit();\n };\n\n render() {\n const value = this.getValue();\n const motorbikeClass = this.motorbike ? 'motorbike-plate' : '';\n\n return (\n <road-input-group class={`plate-number plate-number-${this.country.toLowerCase()} ${motorbikeClass}`}>\n <label slot=\"prepend\" class=\"input-group-prepend\">\n <div class=\"plate-number-start\">\n <road-icon class=\"plate-number-icon\" icon={licensePlateStarEu}></road-icon>\n <div class=\"plate-number-location\" aria-label={this.country} role=\"img\">\n {this.countries\n .filter(item => item.country === this.country)[0].letter}\n </div>\n </div>\n </label>\n {this.motorbike\n ? (\n <textarea\n class=\"form-control plate-number-input mb-0\"\n disabled={this.disabled}\n placeholder={this.placeholder != null ? this.placeholder : this.countries.filter(item => item.country === this.country)[0].placeholder}\n readOnly={this.readonly}\n maxlength=\"9\"\n rows={2}\n onInput={this.onInput}\n onBlur={this.onBlur}\n onFocus={this.onFocus}\n >\n </textarea>\n )\n : (\n <input\n class=\"plate-number-input mb-0\"\n disabled={this.disabled}\n placeholder={this.placeholder != null ? this.placeholder : this.countries.filter(item => item.country === this.country)[0].placeholder}\n readOnly={this.readonly}\n value={value}\n onInput={this.onInput}\n onBlur={this.onBlur}\n onFocus={this.onFocus}\n />\n )}\n <label slot=\"append\" class=\"input-group-append\">\n <div class=\"plate-number-end\"></div>\n </label>\n </road-input-group>\n );\n }\n\n}"],"mappings":"sFAAA,MAAMA,EAAiB,o9F,MCQVC,EAAW,M,iUAEdC,KAAAC,UAAY,CAClB,CACEC,QAAS,KACTC,OAAQ,IACRC,YAAa,aAEf,CACEF,QAAS,KACTC,OAAQ,IACRC,YAAa,aAEf,CACEF,QAAS,KACTC,OAAQ,IACRC,YAAa,YAEf,CACEF,QAAS,KACTC,OAAQ,IACRC,YAAa,YAEf,CACEF,QAAS,KACTC,OAAQ,IACRC,YAAa,YAEf,CACEF,QAAS,KACTC,OAAQ,KACRC,YAAa,YAEf,CACEF,QAAS,KACTC,OAAQ,IACRC,YAAa,YAEf,CACEF,QAAS,KACTC,OAAQ,IACRC,YAAa,eAiFTJ,KAAAK,QAAWC,IACjB,MAAMC,EAAQD,EAAGE,OACjB,GAAID,EAAO,CACTA,EAAME,MAAQF,EAAME,MAAMC,eAAiB,E,CAE7CV,KAAKW,UAAUC,KAAKN,GACpB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B,UAKhBW,EAAA,SACEC,MAAM,0BACNQ,SAAUrC,KAAKqC,SACfjC,YAAaJ,KAAKI,aAAe,KAAOJ,KAAKI,YAAeJ,KAAKC,UAAUkC,QAAOC,GAAQA,EAAKlC,UAAYF,KAAKE,UAAS,GAAGE,YAC5HkC,SAAUtC,KAAKuC,SACf9B,MAAOA,EACPJ,QAASL,KAAKK,QACdS,OAAQd,KAAKc,OACbG,QAASjB,KAAKiB,UAGpBW,EAAA,SAAOG,KAAK,SAASF,MAAM,sBACzBD,EAAA,OAAKC,MAAM,sB"}
@@ -1,2 +1,2 @@
1
- import{r,h as o,H as i}from"./p-f3d586b3.js";import{a as e}from"./p-73fe2357.js";import"./p-1ccae339.js";const a=":host{box-sizing:border-box;display:inline-flex;align-items:center;height:1.5rem;padding:0.25rem 0.5rem;margin-bottom:0.5rem;font-size:var(--road-font-size-14);cursor:pointer;border:0;border-radius:1.625rem;outline:0;transition:background 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms, border 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms}.chip-description{display:inline-flex;align-items:center;padding:0 0.5rem}:host(.chip-outline){border-style:solid;border-width:1px}::slotted(road-icon){width:1.25rem;height:1.25rem;margin-right:0.5rem;margin-left:-0.5rem}.chip-close{width:1rem;height:1rem;margin-right:-0.25rem;color:var(--road-surface);background:var(--road-on-surface-weak);border-radius:50%;transition:background 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms}:host(.chip-lg){height:2.5rem;padding:0 0.75rem;font-size:var(--road-font-size-16)}:host(.chip-lg) ::slotted(road-icon){width:1.5rem;height:1.5rem;margin-right:0.75rem;margin-left:-0.75rem}:host(.chip-lg) .chip-description{padding:0 0.75rem}:host(.chip-lg) .chip-close{width:1.5rem;height:1.5rem}:host(.chip-default){color:var(--road-on-surface);background:var(--road-grey-200)}:host(.chip-outline.chip-default){background:var(--road-surface);border-color:var(--road-outline)}:host(.chip-secondary){color:var(--road-surface-inverse);background:var(--road-button-primary);border-color:transparent}:host(.chip-secondary) .chip-close{color:var(--road-primary);background:var(--road-surface)}@media (any-hover: hover){:host(.chip-outline:hover){border-color:var(--road-outline-variant)}:host(.chip-secondary:hover){background:var(--road-button-primary-variant)}:host(.chip-secondary:hover) .chip-close{color:var(--road-primary)}}:host(.chip-outline:hover){border-color:var(--road-outline-variant)}:host(.chip-secondary.focus-visible){background:var(--road-button-primary-variant)}";const t=class{constructor(o){r(this,o);this.color="default";this.outline=false;this.size="md";this.hasCloseIcon=false}render(){const r=this.outline?"chip-outline":"";return o(i,{class:`${r} chip-${this.color} chip-${this.size}`},o("div",{class:"chip-description"},o("slot",null)),this.hasCloseIcon&&o("road-icon",{class:"chip-close",icon:e}))}};t.style=a;export{t as road_chip};
2
- //# sourceMappingURL=p-4f47f4f7.entry.js.map
1
+ import{r,h as o,H as i}from"./p-f3d586b3.js";import{a as e}from"./p-ac7a8bca.js";import"./p-1ccae339.js";const a=":host{box-sizing:border-box;display:inline-flex;align-items:center;height:1.5rem;padding:0.25rem 0.5rem;margin-bottom:0.5rem;font-size:var(--road-font-size-14);cursor:pointer;border:0;border-radius:1.625rem;outline:0;transition:background 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms, border 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms}.chip-description{display:inline-flex;align-items:center;padding:0 0.5rem}:host(.chip-outline){border-style:solid;border-width:1px}::slotted(road-icon){width:1.25rem;height:1.25rem;margin-right:0.5rem;margin-left:-0.5rem}.chip-close{width:1rem;height:1rem;margin-right:-0.25rem;color:var(--road-surface);background:var(--road-on-surface-weak);border-radius:50%;transition:background 250ms cubic-bezier(0.4, 0, 0.2, 1) 0ms}:host(.chip-lg){height:2.5rem;padding:0 0.75rem;font-size:var(--road-font-size-16)}:host(.chip-lg) ::slotted(road-icon){width:1.5rem;height:1.5rem;margin-right:0.75rem;margin-left:-0.75rem}:host(.chip-lg) .chip-description{padding:0 0.75rem}:host(.chip-lg) .chip-close{width:1.5rem;height:1.5rem}:host(.chip-default){color:var(--road-on-surface);background:var(--road-grey-200)}:host(.chip-outline.chip-default){background:var(--road-surface);border-color:var(--road-outline)}:host(.chip-secondary){color:var(--road-on-button-primary);background:var(--road-button-primary);border-color:transparent}:host(.chip-secondary) .chip-close{color:var(--road-primary);background:var(--road-surface)}@media (any-hover: hover){:host(.chip-outline:hover){border-color:var(--road-outline-variant)}:host(.chip-secondary:hover){background:var(--road-button-primary-variant)}:host(.chip-secondary:hover) .chip-close{color:var(--road-primary)}}:host(.chip-outline:focus-visible){border-color:var(--road-outline-variant)}:host(.chip-secondary.focus-visible){background:var(--road-button-primary-variant)}";const t=class{constructor(o){r(this,o);this.color="default";this.outline=false;this.size="md";this.hasCloseIcon=false}render(){const r=this.outline?"chip-outline":"";return o(i,{class:`${r} chip-${this.color} chip-${this.size}`,tabindex:"0"},o("div",{class:"chip-description"},o("slot",null)),this.hasCloseIcon&&o("road-icon",{class:"chip-close",icon:e}))}};t.style=a;export{t as road_chip};
2
+ //# sourceMappingURL=p-31cf9b61.entry.js.map