@mrfylke/contact-form 0.1.24 → 0.1.26

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 (297) hide show
  1. package/README.md +42 -24
  2. package/lib/ContactFormRoot.d.ts +2 -2
  3. package/lib/ContactFormRoot.d.ts.map +1 -1
  4. package/lib/ContactFormRoot.js +6 -4
  5. package/lib/components/button/link.d.ts +1 -1
  6. package/lib/components/button/link.d.ts.map +1 -1
  7. package/lib/components/button/utils.d.ts +2 -2
  8. package/lib/components/button/utils.d.ts.map +1 -1
  9. package/lib/components/checkbox/checkbox.d.ts +1 -1
  10. package/lib/components/checkbox/checkbox.d.ts.map +1 -1
  11. package/lib/components/error-message/error-message.d.ts +1 -1
  12. package/lib/components/error-message/error-message.d.ts.map +1 -1
  13. package/lib/components/external-link-page.d.ts +1 -1
  14. package/lib/components/external-link-page.d.ts.map +1 -1
  15. package/lib/components/form/date-selector.d.ts +1 -1
  16. package/lib/components/form/date-selector.d.ts.map +1 -1
  17. package/lib/components/form/date-selector.js +2 -2
  18. package/lib/components/form/departure-time-field.d.ts +1 -1
  19. package/lib/components/form/departure-time-field.d.ts.map +1 -1
  20. package/lib/components/form/description-modal.d.ts +1 -1
  21. package/lib/components/form/description-modal.d.ts.map +1 -1
  22. package/lib/components/form/field-wrapper-with-error/index.d.ts +1 -1
  23. package/lib/components/form/field-wrapper-with-error/index.d.ts.map +1 -1
  24. package/lib/components/form/fieldset/index.d.ts +1 -1
  25. package/lib/components/form/fieldset/index.d.ts.map +1 -1
  26. package/lib/components/form/file-input.d.ts +1 -1
  27. package/lib/components/form/file-input.d.ts.map +1 -1
  28. package/lib/components/form/form-component-label/index.d.ts +3 -2
  29. package/lib/components/form/form-component-label/index.d.ts.map +1 -1
  30. package/lib/components/form/form-component-label/index.js +2 -2
  31. package/lib/components/form/input.d.ts +1 -1
  32. package/lib/components/form/input.d.ts.map +1 -1
  33. package/lib/components/form/radio.d.ts +1 -1
  34. package/lib/components/form/radio.d.ts.map +1 -1
  35. package/lib/components/form/searchable-select/searchable-select.d.ts +1 -1
  36. package/lib/components/form/searchable-select/searchable-select.d.ts.map +1 -1
  37. package/lib/components/form/searchable-select/searchable-select.js +1 -1
  38. package/lib/components/form/select.d.ts +1 -1
  39. package/lib/components/form/select.d.ts.map +1 -1
  40. package/lib/components/form/select.js +1 -1
  41. package/lib/components/form/textarea.d.ts +1 -1
  42. package/lib/components/form/textarea.d.ts.map +1 -1
  43. package/lib/components/form/time-selector.d.ts +1 -1
  44. package/lib/components/form/time-selector.d.ts.map +1 -1
  45. package/lib/components/form/time-selector.js +2 -2
  46. package/lib/components/icon/checkbox-icon.d.ts +1 -1
  47. package/lib/components/icon/checkbox-icon.d.ts.map +1 -1
  48. package/lib/components/icon/color-icon.d.ts +1 -1
  49. package/lib/components/icon/color-icon.d.ts.map +1 -1
  50. package/lib/components/icon/generated-icons.d.ts +422 -262
  51. package/lib/components/icon/generated-icons.d.ts.map +1 -1
  52. package/lib/components/icon/generated-icons.js +1931 -1771
  53. package/lib/components/icon/illustration.d.ts +1 -1
  54. package/lib/components/icon/illustration.d.ts.map +1 -1
  55. package/lib/components/icon/image.d.ts +1 -1
  56. package/lib/components/icon/image.d.ts.map +1 -1
  57. package/lib/components/icon/mono-icon.d.ts +1 -1
  58. package/lib/components/icon/mono-icon.d.ts.map +1 -1
  59. package/lib/components/icon/utils.d.ts.map +1 -1
  60. package/lib/components/icon/utils.js +6 -6
  61. package/lib/components/loading/index.d.ts +2 -2
  62. package/lib/components/loading/index.d.ts.map +1 -1
  63. package/lib/components/section-card/section-card.d.ts +1 -1
  64. package/lib/components/section-card/section-card.d.ts.map +1 -1
  65. package/lib/components/typography/index.d.ts +6 -6
  66. package/lib/components/typography/index.d.ts.map +1 -1
  67. package/lib/contact.module.css +0 -9
  68. package/lib/error-content/error-content.d.ts +1 -1
  69. package/lib/error-content/error-content.d.ts.map +1 -1
  70. package/lib/group-travel/index.d.ts +1 -1
  71. package/lib/group-travel/index.d.ts.map +1 -1
  72. package/lib/group-travel/index.js +1 -2
  73. package/lib/index.d.ts +3 -5
  74. package/lib/index.d.ts.map +1 -1
  75. package/lib/index.js +5 -10
  76. package/lib/journey-info/events.d.ts.map +1 -1
  77. package/lib/journey-info/index.d.ts +1 -1
  78. package/lib/journey-info/index.d.ts.map +1 -1
  79. package/lib/journey-info/index.js +10 -8
  80. package/lib/journey-info/journeyInfoStateMachine.d.ts +2 -2
  81. package/lib/journey-info/journeyInfoStateMachine.d.ts.map +1 -1
  82. package/lib/journey-info/journeyInfoStateMachine.js +1 -1
  83. package/lib/layouts/contact-form-container.d.ts +1 -1
  84. package/lib/layouts/contact-form-container.d.ts.map +1 -1
  85. package/lib/layouts/contact-page-layout.d.ts +1 -8
  86. package/lib/layouts/contact-page-layout.d.ts.map +1 -1
  87. package/lib/layouts/contact-page-layout.js +8 -93
  88. package/lib/layouts/contact-pages.d.ts +20 -0
  89. package/lib/layouts/contact-pages.d.ts.map +1 -0
  90. package/lib/layouts/contact-pages.js +124 -0
  91. package/lib/layouts/index.d.ts +2 -1
  92. package/lib/layouts/index.d.ts.map +1 -1
  93. package/lib/layouts/index.js +5 -2
  94. package/lib/lines/use-departures.js +2 -2
  95. package/lib/lines/use-lines.d.ts +2 -2
  96. package/lib/lines/use-lines.js +1 -1
  97. package/lib/lost-property/LostPropertyForm.d.ts +2 -1
  98. package/lib/lost-property/LostPropertyForm.d.ts.map +1 -1
  99. package/lib/lost-property/LostPropertyMachine.d.ts +2 -2
  100. package/lib/lost-property/LostPropertyMachine.d.ts.map +1 -1
  101. package/lib/lost-property/LostPropertyMachine.js +1 -1
  102. package/lib/lost-property/index.d.ts +1 -1
  103. package/lib/lost-property/index.d.ts.map +1 -1
  104. package/lib/lost-property-external/index.d.ts +1 -1
  105. package/lib/lost-property-external/index.d.ts.map +1 -1
  106. package/lib/lost-property-external/index.js +1 -2
  107. package/lib/means-of-transport/events.d.ts.map +1 -1
  108. package/lib/means-of-transport/forms/delayForm.d.ts +1 -1
  109. package/lib/means-of-transport/forms/delayForm.d.ts.map +1 -1
  110. package/lib/means-of-transport/forms/driverForm.d.ts +1 -1
  111. package/lib/means-of-transport/forms/driverForm.d.ts.map +1 -1
  112. package/lib/means-of-transport/forms/injuryForm.d.ts +1 -1
  113. package/lib/means-of-transport/forms/injuryForm.d.ts.map +1 -1
  114. package/lib/means-of-transport/forms/serviceOfferingForm.d.ts +1 -1
  115. package/lib/means-of-transport/forms/serviceOfferingForm.d.ts.map +1 -1
  116. package/lib/means-of-transport/forms/serviceOfferingForm.js +3 -1
  117. package/lib/means-of-transport/forms/stopForm.d.ts +1 -1
  118. package/lib/means-of-transport/forms/stopForm.d.ts.map +1 -1
  119. package/lib/means-of-transport/forms/transportationForm.d.ts +1 -1
  120. package/lib/means-of-transport/forms/transportationForm.d.ts.map +1 -1
  121. package/lib/means-of-transport/index.d.ts +1 -1
  122. package/lib/means-of-transport/index.d.ts.map +1 -1
  123. package/lib/means-of-transport/index.js +8 -2
  124. package/lib/means-of-transport/means-of-transport-form-machine.d.ts +4 -2
  125. package/lib/means-of-transport/means-of-transport-form-machine.d.ts.map +1 -1
  126. package/lib/means-of-transport/means-of-transport-form-machine.js +9 -3
  127. package/lib/modules/config/context.d.ts +13 -38
  128. package/lib/modules/config/context.d.ts.map +1 -1
  129. package/lib/modules/config/context.js +16 -52
  130. package/lib/modules/config/default-submit.d.ts +3 -0
  131. package/lib/modules/config/default-submit.d.ts.map +1 -0
  132. package/lib/modules/config/default-submit.js +13 -0
  133. package/lib/modules/config/index.d.ts +1 -0
  134. package/lib/modules/config/index.d.ts.map +1 -1
  135. package/lib/modules/config/index.js +1 -0
  136. package/lib/modules/config/types.d.ts +60 -78
  137. package/lib/modules/config/types.d.ts.map +1 -1
  138. package/lib/modules/org-data/index.d.ts +1 -2
  139. package/lib/modules/org-data/index.d.ts.map +1 -1
  140. package/lib/modules/org-data/index.js +1 -2
  141. package/lib/modules/theme/theme-context.d.ts +1 -1
  142. package/lib/modules/theme/theme-context.d.ts.map +1 -1
  143. package/lib/modules/transport-mode/filter/filter.d.ts +1 -1
  144. package/lib/modules/transport-mode/filter/filter.d.ts.map +1 -1
  145. package/lib/modules/transport-mode/icon/index.d.ts +4 -4
  146. package/lib/modules/transport-mode/icon/index.d.ts.map +1 -1
  147. package/lib/modules/transport-mode/types.d.ts +3 -5
  148. package/lib/modules/transport-mode/types.d.ts.map +1 -1
  149. package/lib/modules/transport-mode/types.js +3 -138
  150. package/lib/modules/transport-mode/utils.d.ts +2 -2
  151. package/lib/modules/transport-mode/utils.d.ts.map +1 -1
  152. package/lib/modules/transport-mode/utils.js +39 -6
  153. package/lib/refund/forms/refund-and-travel-guarantee/index.d.ts +1 -1
  154. package/lib/refund/forms/refund-and-travel-guarantee/index.d.ts.map +1 -1
  155. package/lib/refund/forms/refund-and-travel-guarantee/index.js +1 -1
  156. package/lib/refund/forms/refund-and-travel-guarantee/refundCarForm.d.ts +1 -1
  157. package/lib/refund/forms/refund-and-travel-guarantee/refundCarForm.d.ts.map +1 -1
  158. package/lib/refund/forms/refund-and-travel-guarantee/refundCarForm.js +1 -1
  159. package/lib/refund/forms/refund-and-travel-guarantee/refundTaxiForm.d.ts +1 -1
  160. package/lib/refund/forms/refund-and-travel-guarantee/refundTaxiForm.d.ts.map +1 -1
  161. package/lib/refund/forms/refund-ticket/appTicketRefund.d.ts +2 -2
  162. package/lib/refund/forms/refund-ticket/appTicketRefund.d.ts.map +1 -1
  163. package/lib/refund/forms/refund-ticket/appTicketRefund.js +18 -2
  164. package/lib/refund/forms/refund-ticket/index.d.ts +1 -1
  165. package/lib/refund/forms/refund-ticket/index.d.ts.map +1 -1
  166. package/lib/refund/forms/refund-ticket/index.js +1 -1
  167. package/lib/refund/forms/refund-ticket/otherTicketRefund.d.ts +1 -1
  168. package/lib/refund/forms/refund-ticket/otherTicketRefund.d.ts.map +1 -1
  169. package/lib/refund/forms/refund-ticket/otherTicketRefund.js +16 -4
  170. package/lib/refund/forms/residualValueOnTravelCard/index.d.ts +1 -1
  171. package/lib/refund/forms/residualValueOnTravelCard/index.d.ts.map +1 -1
  172. package/lib/refund/forms/residualValueOnTravelCard/index.js +1 -2
  173. package/lib/refund/index.d.ts +1 -1
  174. package/lib/refund/index.d.ts.map +1 -1
  175. package/lib/refund/index.js +9 -0
  176. package/lib/refund/refundFormMachine.d.ts +10 -2
  177. package/lib/refund/refundFormMachine.d.ts.map +1 -1
  178. package/lib/refund/refundFormMachine.js +23 -2
  179. package/lib/server/departures-route-handler.d.ts +27 -0
  180. package/lib/server/departures-route-handler.d.ts.map +1 -0
  181. package/lib/server/departures-route-handler.js +93 -0
  182. package/lib/server/index.d.ts +2 -0
  183. package/lib/server/index.d.ts.map +1 -1
  184. package/lib/server/index.js +5 -1
  185. package/lib/server/journey-planner/authority.d.ts +2 -2
  186. package/lib/server/journey-planner/authority.js +3 -3
  187. package/lib/server/journey-planner/index.d.ts.map +1 -1
  188. package/lib/server/journey-planner/index.js +8 -9
  189. package/lib/server/journey-planner/journey-gql/lines.generated.d.ts +1 -0
  190. package/lib/server/journey-planner/journey-gql/lines.generated.d.ts.map +1 -1
  191. package/lib/server/journey-planner/journey-gql/lines.generated.js +1 -0
  192. package/lib/server/journey-planner/validators.d.ts +4 -4
  193. package/lib/server/journey-planner/validators.js +3 -3
  194. package/lib/server/lines-route-handler.d.ts +7 -18
  195. package/lib/server/lines-route-handler.d.ts.map +1 -1
  196. package/lib/server/lines-route-handler.js +15 -17
  197. package/lib/server/submit-route-handler.d.ts +20 -0
  198. package/lib/server/submit-route-handler.d.ts.map +1 -0
  199. package/lib/server/submit-route-handler.js +62 -0
  200. package/lib/success-content/success-content.d.ts +1 -1
  201. package/lib/success-content/success-content.d.ts.map +1 -1
  202. package/lib/ticket-control/events.d.ts +1 -1
  203. package/lib/ticket-control/events.d.ts.map +1 -1
  204. package/lib/ticket-control/forms/feeComplaintForm.d.ts +1 -1
  205. package/lib/ticket-control/forms/feeComplaintForm.d.ts.map +1 -1
  206. package/lib/ticket-control/forms/feeComplaintForm.js +5 -1
  207. package/lib/ticket-control/forms/feedbackForm.d.ts +1 -1
  208. package/lib/ticket-control/forms/feedbackForm.d.ts.map +1 -1
  209. package/lib/ticket-control/forms/postponePayment.d.ts +1 -1
  210. package/lib/ticket-control/forms/postponePayment.d.ts.map +1 -1
  211. package/lib/ticket-control/forms/postponePayment.js +5 -1
  212. package/lib/ticket-control/index.d.ts +1 -1
  213. package/lib/ticket-control/index.d.ts.map +1 -1
  214. package/lib/ticket-control/index.js +2 -0
  215. package/lib/ticket-control/ticket-control-form-machine.d.ts +8 -4
  216. package/lib/ticket-control/ticket-control-form-machine.d.ts.map +1 -1
  217. package/lib/ticket-control/ticket-control-form-machine.js +14 -3
  218. package/lib/ticketing/events.d.ts.map +1 -1
  219. package/lib/ticketing/forms/app/appAccountForm.d.ts +1 -1
  220. package/lib/ticketing/forms/app/appAccountForm.d.ts.map +1 -1
  221. package/lib/ticketing/forms/app/appTicketingForm.d.ts +1 -1
  222. package/lib/ticketing/forms/app/appTicketingForm.d.ts.map +1 -1
  223. package/lib/ticketing/forms/app/appTravelSuggestionForm.d.ts +1 -1
  224. package/lib/ticketing/forms/app/appTravelSuggestionForm.d.ts.map +1 -1
  225. package/lib/ticketing/forms/app/index.d.ts +1 -1
  226. package/lib/ticketing/forms/app/index.d.ts.map +1 -1
  227. package/lib/ticketing/forms/priceAndTicketTypesForm.d.ts +1 -1
  228. package/lib/ticketing/forms/priceAndTicketTypesForm.d.ts.map +1 -1
  229. package/lib/ticketing/forms/travel-card/index.d.ts +1 -1
  230. package/lib/ticketing/forms/travel-card/index.d.ts.map +1 -1
  231. package/lib/ticketing/forms/travel-card/orderTravelCard.d.ts +1 -1
  232. package/lib/ticketing/forms/travel-card/orderTravelCard.d.ts.map +1 -1
  233. package/lib/ticketing/forms/travel-card/orderTravelCard.js +1 -1
  234. package/lib/ticketing/forms/travel-card/travelCardQuestionForm.d.ts +1 -1
  235. package/lib/ticketing/forms/travel-card/travelCardQuestionForm.d.ts.map +1 -1
  236. package/lib/ticketing/forms/webshop/index.d.ts +1 -1
  237. package/lib/ticketing/forms/webshop/index.d.ts.map +1 -1
  238. package/lib/ticketing/forms/webshop/webshopAccountForm.d.ts +1 -1
  239. package/lib/ticketing/forms/webshop/webshopAccountForm.d.ts.map +1 -1
  240. package/lib/ticketing/forms/webshop/webshopTicketingForm.d.ts +1 -1
  241. package/lib/ticketing/forms/webshop/webshopTicketingForm.d.ts.map +1 -1
  242. package/lib/ticketing/index.d.ts +1 -1
  243. package/lib/ticketing/index.d.ts.map +1 -1
  244. package/lib/ticketing/ticketingStateMachine.d.ts +2 -2
  245. package/lib/ticketing/ticketingStateMachine.d.ts.map +1 -1
  246. package/lib/translations/commons.d.ts +1 -0
  247. package/lib/translations/commons.d.ts.map +1 -1
  248. package/lib/translations/commons.js +4 -4
  249. package/lib/translations/index.d.ts +2 -6
  250. package/lib/translations/index.d.ts.map +1 -1
  251. package/lib/translations/index.js +1 -9
  252. package/lib/translations/language-context.d.ts +3 -11
  253. package/lib/translations/language-context.d.ts.map +1 -1
  254. package/lib/translations/language-context.js +1 -31
  255. package/lib/translations/merge-overrides.d.ts +3 -9
  256. package/lib/translations/merge-overrides.d.ts.map +1 -1
  257. package/lib/translations/merge-overrides.js +3 -15
  258. package/lib/translations/pages/contact.d.ts +15 -4
  259. package/lib/translations/pages/contact.d.ts.map +1 -1
  260. package/lib/translations/pages/contact.js +17 -20
  261. package/lib/translations/server/endpoints.d.ts +0 -62
  262. package/lib/translations/server/endpoints.d.ts.map +1 -1
  263. package/lib/translations/server/endpoints.js +1 -139
  264. package/lib/translations/translations-context.d.ts +1 -1
  265. package/lib/translations/translations-context.d.ts.map +1 -1
  266. package/lib/translations/types.d.ts +7 -13
  267. package/lib/translations/types.d.ts.map +1 -1
  268. package/lib/translations/utils.d.ts +0 -7
  269. package/lib/translations/utils.d.ts.map +1 -1
  270. package/lib/translations/utils.js +0 -26
  271. package/lib/types/submit-payloads.d.ts +1 -0
  272. package/lib/types/submit-payloads.d.ts.map +1 -1
  273. package/lib/types.d.ts.map +1 -1
  274. package/lib/validation/validationRules.d.ts.map +1 -1
  275. package/lib/validation/validationRules.js +7 -0
  276. package/package.json +37 -32
  277. package/lib/components/icon/icon-wrapper.d.ts +0 -30
  278. package/lib/components/icon/icon-wrapper.d.ts.map +0 -1
  279. package/lib/components/icon/icon-wrapper.js +0 -39
  280. package/lib/components/icon/mono-icon-new.d.ts +0 -32
  281. package/lib/components/icon/mono-icon-new.d.ts.map +0 -1
  282. package/lib/components/icon/mono-icon-new.js +0 -43
  283. package/lib/translations/common/index.d.ts +0 -3
  284. package/lib/translations/common/index.d.ts.map +0 -1
  285. package/lib/translations/common/index.js +0 -7
  286. package/lib/translations/common/layout.d.ts +0 -8
  287. package/lib/translations/common/layout.d.ts.map +0 -1
  288. package/lib/translations/common/layout.js +0 -39
  289. package/lib/translations/common/titles.d.ts +0 -4
  290. package/lib/translations/common/titles.d.ts.map +0 -1
  291. package/lib/translations/common/titles.js +0 -25
  292. package/lib/translations/json-to-override.d.ts +0 -19
  293. package/lib/translations/json-to-override.d.ts.map +0 -1
  294. package/lib/translations/json-to-override.js +0 -65
  295. package/lib/translations/load-org-translations.d.ts +0 -19
  296. package/lib/translations/load-org-translations.d.ts.map +0 -1
  297. package/lib/translations/load-org-translations.js +0 -23
@@ -1 +1 @@
1
- {"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../../../src/modules/config/context.tsx"],"names":[],"mappings":"AAAA,OAAO,EAA6B,iBAAiB,EAAE,MAAM,OAAO,CAAC;AACrE,OAAO,KAAK,EAAE,iBAAiB,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAQxD,MAAM,MAAM,8BAA8B,GAAG,iBAAiB,CAAC;IAC7D,MAAM,EAAE,iBAAiB,CAAC;CAC3B,CAAC,CAAC;AAEH;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,wBAAgB,yBAAyB,CAAC,EACxC,MAAM,EACN,QAAQ,GACT,EAAE,8BAA8B,2CAWhC;AAED;;;GAGG;AACH,wBAAgB,oBAAoB,IAAI,iBAAiB,CASxD;AAED;;;GAGG;AACH,wBAAgB,cAAc,UAG7B;AA4BD;;GAEG;AACH,wBAAgB,aAAa,8BAG5B;AAED;;GAEG;AACH,wBAAgB,YAAY,gCAG3B;AAED;;GAEG;AACH,wBAAgB,YAAY,gCAG3B"}
1
+ {"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../../../src/modules/config/context.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,iBAAiB,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAGxD;;;GAGG;AACH,eAAO,MAAM,wBAAwB,mDAEpC,CAAC;AAEF,wBAAgB,yBAAyB,CACvC,MAAM,EAAE,iBAAiB,GACxB,iBAAiB,CAKnB;AAED;;;GAGG;AACH,wBAAgB,oBAAoB,IAAI,iBAAiB,CASxD;AAED;;;GAGG;AACH,wBAAgB,cAAc,UAG7B;AA4BD;;GAEG;AACH,wBAAgB,YAAY;;;aAY6yD,CAAC;kBAA+U,CAAC;cAAoB,CAAC;;EAD9qE"}
@@ -1,59 +1,32 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ContactFormConfigProvider = ContactFormConfigProvider;
3
+ exports.ContactFormConfigContext = void 0;
4
+ exports.mergeConfigThemeOverrides = mergeConfigThemeOverrides;
4
5
  exports.useContactFormConfig = useContactFormConfig;
5
6
  exports.useThemeConfig = useThemeConfig;
6
- exports.useIconConfig = useIconConfig;
7
- exports.useOrgConfig = useOrgConfig;
8
7
  exports.useApiConfig = useApiConfig;
9
- const jsx_runtime_1 = require("react/jsx-runtime");
10
8
  const react_1 = require("react");
9
+ const default_submit_1 = require("./default-submit");
11
10
  /**
12
11
  * Context for contact form configuration.
13
12
  * This allows the entire form to access theme, icons, and other settings.
14
13
  */
15
- const ContactFormConfigContext = (0, react_1.createContext)(null);
16
- /**
17
- * Provider component that supplies configuration to the entire contact form.
18
- * This should wrap your entire application or the part that uses the contact form.
19
- *
20
- * @example
21
- * ```tsx
22
- * import { ContactFormConfigProvider } from '@mrfylke/contact-form';
23
- * import { myTheme, myIcons } from './my-config';
24
- *
25
- * function App() {
26
- * return (
27
- * <ContactFormConfigProvider
28
- * config={{
29
- * theme: myTheme,
30
- * icons: myIcons,
31
- * api: { baseUrl: '/api', endpoints: { submitForm: '/contact' } },
32
- * org: { name: 'My Company', supportEmail: 'support@example.com' }
33
- * }}
34
- * >
35
- * <ContactForm />
36
- * </ContactFormConfigProvider>
37
- * );
38
- * }
39
- * ```
40
- */
41
- function ContactFormConfigProvider({ config, children, }) {
42
- const mergedConfig = {
14
+ exports.ContactFormConfigContext = (0, react_1.createContext)(null);
15
+ function mergeConfigThemeOverrides(config) {
16
+ return {
43
17
  ...config,
44
18
  theme: mergeThemeWithOverrides(config.theme, config.themeOverrides),
45
19
  };
46
- return ((0, jsx_runtime_1.jsx)(ContactFormConfigContext.Provider, { value: mergedConfig, children: children }));
47
20
  }
48
21
  /**
49
22
  * Hook to access the contact form configuration.
50
- * @throws Error if used outside of ContactFormConfigProvider
23
+ * @throws Error if used outside of ContactFormRoot
51
24
  */
52
25
  function useContactFormConfig() {
53
- const context = (0, react_1.useContext)(ContactFormConfigContext);
26
+ const context = (0, react_1.useContext)(exports.ContactFormConfigContext);
54
27
  if (!context) {
55
- throw new Error('useContactFormConfig must be used within ContactFormConfigProvider. ' +
56
- 'Make sure to wrap your app with <ContactFormConfigProvider config={...}>');
28
+ throw new Error('useContactFormConfig must be used within ContactFormRoot. ' +
29
+ 'Make sure to wrap your app with <ContactFormRoot config={...}>');
57
30
  }
58
31
  return context;
59
32
  }
@@ -89,24 +62,15 @@ function mergeThemeWithOverrides(base, overrides) {
89
62
  apply(result, overrides);
90
63
  return result;
91
64
  }
92
- /**
93
- * Hook to access the icon set from configuration.
94
- */
95
- function useIconConfig() {
96
- const { icons } = useContactFormConfig();
97
- return icons;
98
- }
99
- /**
100
- * Hook to access the org configuration.
101
- */
102
- function useOrgConfig() {
103
- const { org } = useContactFormConfig();
104
- return org;
105
- }
106
65
  /**
107
66
  * Hook to access the API configuration.
108
67
  */
109
68
  function useApiConfig() {
110
69
  const { api } = useContactFormConfig();
111
- return api;
70
+ const endpoint = api?.endpoints?.submit;
71
+ const defaultOnSubmit = (0, react_1.useCallback)((slug, state) => (0, default_submit_1.createDefaultOnSubmit)(endpoint)(slug, state), [endpoint]);
72
+ return {
73
+ ...api,
74
+ onSubmit: api?.onSubmit ?? defaultOnSubmit,
75
+ };
112
76
  }
@@ -0,0 +1,3 @@
1
+ import type { FormSlug } from './types';
2
+ export declare function createDefaultOnSubmit(endpoint?: string): (slug: FormSlug, state: Record<string, unknown>) => Promise<Response>;
3
+ //# sourceMappingURL=default-submit.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"default-submit.d.ts","sourceRoot":"","sources":["../../../src/modules/config/default-submit.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAIxC,wBAAgB,qBAAqB,CACnC,QAAQ,GAAE,MAAgC,IAGxC,MAAM,QAAQ,EACd,OAAO,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,KAC7B,OAAO,CAAC,QAAQ,CAAC,CAOrB"}
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.createDefaultOnSubmit = createDefaultOnSubmit;
4
+ const DEFAULT_SUBMIT_ENDPOINT = '/api/contact/submit';
5
+ function createDefaultOnSubmit(endpoint = DEFAULT_SUBMIT_ENDPOINT) {
6
+ return async (slug, state) => {
7
+ return fetch(endpoint, {
8
+ method: 'POST',
9
+ headers: { 'Content-Type': 'application/json' },
10
+ body: JSON.stringify({ ...state, $slug: slug }),
11
+ });
12
+ };
13
+ }
@@ -1,4 +1,5 @@
1
1
  export * from './types';
2
2
  export * from './context';
3
3
  export * from './theme-adapter';
4
+ export * from './default-submit';
4
5
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/modules/config/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,WAAW,CAAC;AAC1B,cAAc,iBAAiB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/modules/config/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,WAAW,CAAC;AAC1B,cAAc,iBAAiB,CAAC;AAChC,cAAc,kBAAkB,CAAC"}
@@ -17,3 +17,4 @@ Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./types"), exports);
18
18
  __exportStar(require("./context"), exports);
19
19
  __exportStar(require("./theme-adapter"), exports);
20
+ __exportStar(require("./default-submit"), exports);
@@ -12,7 +12,7 @@ export type ContactPage = {
12
12
  /** Stable page identifier used for `pages.enabledPageIds` / `externalUrlByPageId`. */
13
13
  id: PageId;
14
14
  title: TranslatedString;
15
- /** URL segment under the host's basePath, e.g. 'refund' -> `${basePath}/refund`. */
15
+ /** URL segment under the host's basePath, e.g. 'refund' -> `${basePath}/refund`. Also the connector form-type slug the default onSubmit and submit route handler use on the wire. */
16
16
  slug: string;
17
17
  icon: MonoIcons;
18
18
  /** Body component rendered for this page. */
@@ -34,26 +34,6 @@ export type ExtraPageId = `extra-${string}`;
34
34
  export type ExtraContactPage = Omit<ContactPage, 'id'> & {
35
35
  id: ExtraPageId;
36
36
  };
37
- /**
38
- * Icon component type - consumers provide components that render icons
39
- */
40
- export type IconComponent = (props: {
41
- size?: 'small' | 'normal' | 'large';
42
- className?: string;
43
- role?: string;
44
- alt?: string;
45
- style?: React.CSSProperties;
46
- }) => React.ReactElement;
47
- /**
48
- * Icon names used throughout the contact form
49
- */
50
- export type IconName = 'transportation/BusFill' | 'transportation/TramFill' | 'transportation/TrainFill' | 'transportation/WalkFill' | 'transportation/BicycleFill' | 'transportation/PlaneFill' | 'transportation/BoatFill' | 'transportation/FerryFill' | 'transportation/MetroFill' | 'transportation/UnknownFill' | 'actions/Close' | 'actions/Clear' | 'actions/Add' | 'status/CheckmarkFill' | 'status/ErrorFill';
51
- /**
52
- * Icon set that consumers must provide
53
- */
54
- export type IconSet = {
55
- [key in IconName]: IconComponent;
56
- };
57
37
  /**
58
38
  * Color object used for theming
59
39
  */
@@ -169,63 +149,36 @@ export type ThemeColors = {
169
149
  };
170
150
  export type TextColorType = 'light' | 'dark';
171
151
  /**
172
- * Typography configuration
173
- */
174
- export type TypographyConfig = {
175
- fontFamily?: string;
176
- textTypes?: {
177
- heading__title?: string;
178
- heading__component?: string;
179
- body__primary?: string;
180
- body__secondary?: string;
181
- body__xs?: string;
182
- label__uppercase?: string;
183
- };
184
- };
185
- /**
186
- * Form schema names that identify different form types.
187
- * Consumers can use this to route submissions to different endpoints or handle them differently.
152
+ * Slugs of the pages that submit through the shared onSubmit(slug, state)
153
+ * contract. A subset of `PageId`'s slugs — excludes pages that don't submit
154
+ * (e.g. 'group-travel', 'lost-property-external').
188
155
  */
189
- export type FormSchemaName = 'ticketControl' | 'refund' | 'meansOfTransport' | 'ticketing' | 'journeyInfo' | 'lostProperty';
156
+ export type FormSlug = 'ticket-control' | 'refund' | 'means-of-transport' | 'ticketing' | 'journey-info' | 'lost-property';
190
157
  /**
191
158
  * API configuration
192
159
  */
193
160
  export type ApiConfig = {
194
- baseUrl: string;
195
- endpoints: {
196
- submitForm: string;
197
- uploadFile?: string;
161
+ endpoints?: {
198
162
  lines?: string;
163
+ /**
164
+ * Opt-in: unlike `lines`, the package has no default backend for
165
+ * departures. When unset, forms fall back to a plain time input instead
166
+ * of a departures dropdown — set this only once you've mounted your own
167
+ * departures route.
168
+ */
199
169
  departures?: string;
170
+ submit?: string;
200
171
  };
201
172
  /**
202
- * Submit callback that receives the schema name and form state.
203
- * Consumers can use the schema name to route to different endpoints or handle submissions differently.
173
+ * Submit callback that receives the form slug and form state.
174
+ * Optional omit it to use the package's default (POSTs
175
+ * `{ ...state, $slug: slug }` to `endpoints.submit`).
204
176
  *
205
- * @param schemaName - The form schema identifier ('ticketControl' | 'refund' | 'meansOfTransport' | 'ticketing' | 'journeyInfo')
177
+ * @param slug - The submitting page's slug, see `FormSlug`
206
178
  * @param state - The form data as a record of field values
207
179
  * @returns Promise<Response> - The fetch Response from the submission
208
180
  */
209
- onSubmit: (schemaName: FormSchemaName, state: Record<string, unknown>) => Promise<Response>;
210
- };
211
- /**
212
- * Organization/branding configuration
213
- */
214
- export type OrgConfig = {
215
- name: string;
216
- supportEmail: string;
217
- authorityId?: string;
218
- /** URL for the travel search / journey planner link shown in journey-info form. Default: '/' */
219
- travelSearchHref?: string;
220
- /** URL for the contact/opening-hours page linked from the journey-info form. */
221
- contactHref?: string;
222
- logo?: {
223
- src: string;
224
- srcDark?: string;
225
- alt: string;
226
- /** Override for header/footer (accent bar). When set, used instead of src/srcDark. Default: srcDark ?? src (light variant on dark bar). */
227
- accentBar?: string;
228
- };
181
+ onSubmit?: (slug: FormSlug, state: Record<string, unknown>) => Promise<Response>;
229
182
  };
230
183
  /** Label type for layout links - compatible with TranslatedString */
231
184
  export type LayoutLinkLabel = Record<string, string>;
@@ -348,14 +301,8 @@ export type ContactFormConfig = {
348
301
  * full theme from @atb-as/theme.
349
302
  */
350
303
  themeOverrides?: DeepPartial<Theme>;
351
- /** Icon set for all icons used in the form */
352
- icons: IconSet;
353
- /** Typography configuration */
354
- typography?: TypographyConfig;
355
304
  /** API endpoints for form submission */
356
- api: ApiConfig;
357
- /** Organization/branding information */
358
- org: OrgConfig;
305
+ api?: ApiConfig;
359
306
  /** Feature flags */
360
307
  features?: {
361
308
  enableFileUploads?: boolean;
@@ -367,20 +314,23 @@ export type ContactFormConfig = {
367
314
  includeFerry?: boolean;
368
315
  /**
369
316
  * Include bank account fields (bankkontonummer / utenlandsk bankkontonummer) in the
370
- * fee complaint form. Default: true.
317
+ * fee complaint form.
318
+ * Default: true.
371
319
  * When false, bank account fields are hidden and not validated.
372
320
  */
373
321
  includeBankAccountFields?: boolean;
374
322
  /**
375
323
  * Include the ticket type selector (Enkeltbillett/Periodebillett) in the
376
- * "other ticket refund" form (otherTicketRefund). Default: true.
324
+ * "other ticket refund" form (otherTicketRefund).
325
+ * Default: true.
377
326
  * When false, the ticket type dropdown is hidden and not validated.
378
327
  * Set to false for orgs where the "other ticket" is a travel card (e.g. Innlandskort).
379
328
  */
380
329
  includeOtherTicketTypeSelector?: boolean;
381
330
  /**
382
331
  * Include the customer number field in the fee complaint form when
383
- * "app ticket" storage mode is selected. Default: true.
332
+ * "app ticket" storage mode is selected.
333
+ * Default: true.
384
334
  * When false, only the phone number (appPhoneNumber) is shown and validated —
385
335
  * useful for orgs using Entur-appen where customers don't have a customer number.
386
336
  */
@@ -399,16 +349,48 @@ export type ContactFormConfig = {
399
349
  * When true, a departure section is shown and validated in those forms.
400
350
  */
401
351
  includeRefundDepartureInfo?: boolean;
352
+ /**
353
+ * Include the customer number and purchase platform fields in the app
354
+ * ticket refund form.
355
+ * Default: false.
356
+ */
357
+ includeCustomerNumberAndPurchasePlatformInAppTicketRefund?: boolean;
358
+ /**
359
+ * Require the line field in the service offering form (means of
360
+ * transport).
361
+ * Default: false.
362
+ * When true, line is validated as required; it is always shown either way.
363
+ */
364
+ enableRequiredLineInServiceOffering?: boolean;
365
+ /**
366
+ * Include the order id and amount fields in the other ticket refund
367
+ * form.
368
+ * Default: false.
369
+ */
370
+ includeOrderIdAndAmountInOtherTicketRefund?: boolean;
371
+ /**
372
+ * Include the fee date field in the fee complaint and postpone payment
373
+ * forms.
374
+ * Default: false.
375
+ */
376
+ includeFeeDateInTicketControl?: boolean;
377
+ /**
378
+ * Require the attachments field in the other ticket refund form.
379
+ * Has no effect unless enableFileUploads is also true.
380
+ * Default: false.
381
+ */
382
+ enableRequiredAttachmentInOtherTicketRefund?: boolean;
402
383
  };
403
384
  /** Optional host-provided filters for line lookups. */
404
385
  lineFilters?: LineFilterConfig;
405
386
  /** Optional layout config: basePath, backLinkDefault, successPath, errorPath */
406
387
  layout?: LayoutConfig;
407
388
  /**
408
- * Translations for all text used in the contact form.
409
- * Host app must provide all translations - there are no defaults in the package.
389
+ * Translation overrides for the contact form. Any key left unset falls
390
+ * back to the package's built-in default translations. Omit entirely to
391
+ * use the package's defaults as-is.
410
392
  */
411
- translations: ContactFormTranslationsOverride;
393
+ translations?: ContactFormTranslationsOverride;
412
394
  /**
413
395
  * Which contact pages (tabs) are shown and whether they link externally.
414
396
  * Host app must provide `enabledPageIds` - no page is shown by default.
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/modules/config/types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAC7C,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,yCAAyC,CAAC;AACpE,OAAO,KAAK,EACV,+BAA+B,EAC/B,gBAAgB,EACjB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAC;AACrD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,KAAK,EAAE,aAAa,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAE1E,MAAM,MAAM,WAAW,GAAG;IACxB,sFAAsF;IACtF,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,gBAAgB,CAAC;IACxB,oFAAoF;IACpF,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,SAAS,CAAC;IAChB,6CAA6C;IAC7C,SAAS,EAAE,aAAa,CAAC;CAC1B,CAAC;AAEF;;;;;;;;GAQG;AACH,MAAM,MAAM,MAAM,GACd,gBAAgB,GAChB,QAAQ,GACR,oBAAoB,GACpB,WAAW,GACX,eAAe,GACf,wBAAwB,GACxB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;KAC1B,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,SAAS,MAAM,GAAG,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAChE,CAAC"}
@@ -5,8 +5,7 @@
5
5
  * const { supportEmail, orgId } = getOrgData();
6
6
  *
7
7
  * New usage:
8
- * const org = useOrgConfig();
9
- * const email = org.supportEmail;
8
+ * const config = useContactFormConfig();
10
9
  */
11
10
  export * from './compat-layer';
12
11
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/modules/org-data/index.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,cAAc,gBAAgB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/modules/org-data/index.tsx"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,cAAc,gBAAgB,CAAC"}
@@ -6,8 +6,7 @@
6
6
  * const { supportEmail, orgId } = getOrgData();
7
7
  *
8
8
  * New usage:
9
- * const org = useOrgConfig();
10
- * const email = org.supportEmail;
9
+ * const config = useContactFormConfig();
11
10
  */
12
11
  var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
13
12
  if (k2 === undefined) k2 = k;
@@ -14,7 +14,7 @@ export type ThemeProviderProps = PropsWithChildren<{
14
14
  * Theme provider that applies the host-controlled theme variant.
15
15
  * Uses the theme from ContactFormConfig (from design-system) to resolve colors.
16
16
  */
17
- export declare function ThemeProvider({ children, theme }: ThemeProviderProps): import("react/jsx-runtime").JSX.Element;
17
+ export declare function ThemeProvider({ children, theme }: ThemeProviderProps): import("react").JSX.Element;
18
18
  /**
19
19
  * Hook to access the current theme and dark mode state.
20
20
  * @throws Error if used outside of ThemeProvider
@@ -1 +1 @@
1
- {"version":3,"file":"theme-context.d.ts","sourceRoot":"","sources":["../../../src/modules/theme/theme-context.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAiB,iBAAiB,EAAc,MAAM,OAAO,CAAC;AACrE,OAAO,KAAK,EACV,gBAAgB,EAChB,gBAAgB,EAChB,aAAa,EACb,WAAW,EACZ,MAAM,WAAW,CAAC;AAGnB;;GAEG;AACH,KAAK,iBAAiB,GAAG;IACvB,UAAU,EAAE,OAAO,CAAC;IACpB,KAAK,EAAE,WAAW,CAAC;CACpB,CAAC;AAIF,MAAM,MAAM,kBAAkB,GAAG,iBAAiB,CAAC;IACjD,KAAK,EAAE,OAAO,GAAG,MAAM,CAAC;CACzB,CAAC,CAAC;AAEH;;;GAGG;AACH,wBAAgB,aAAa,CAAC,EAAE,QAAQ,EAAE,KAAK,EAAE,EAAE,kBAAkB,2CAUpE;AAED;;;GAGG;AACH,wBAAgB,QAAQ,sBASvB;AAED;;;GAGG;AACH,wBAAgB,eAAe,SAO9B;AAGD,YAAY,EAAE,WAAW,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,aAAa,EAAE,CAAC;AAC/E,YAAY,EACV,eAAe,EACf,aAAa,EACb,YAAY,GACb,MAAM,sBAAsB,CAAC"}
1
+ {"version":3,"file":"theme-context.d.ts","sourceRoot":"","sources":["../../../src/modules/theme/theme-context.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAiB,iBAAiB,EAAc,MAAM,OAAO,CAAC;AACrE,OAAO,KAAK,EACV,gBAAgB,EAChB,gBAAgB,EAChB,aAAa,EACb,WAAW,EACZ,MAAM,WAAW,CAAC;AAGnB;;GAEG;AACH,KAAK,iBAAiB,GAAG;IACvB,UAAU,EAAE,OAAO,CAAC;IACpB,KAAK,EAAE,WAAW,CAAC;CACpB,CAAC;AAIF,MAAM,MAAM,kBAAkB,GAAG,iBAAiB,CAAC;IACjD,KAAK,EAAE,OAAO,GAAG,MAAM,CAAC;CACzB,CAAC,CAAC;AAEH;;;GAGG;AACH,wBAAgB,aAAa,CAAC,EAAE,QAAQ,EAAE,KAAK,EAAE,EAAE,kBAAkB,+BAUpE;AAED;;;GAGG;AACH,wBAAgB,QAAQ,sBASvB;AAED;;;GAGG;AACH,wBAAgB,eAAe,SAO9B;AAGD,YAAY,EAAE,WAAW,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,aAAa,EAAE,CAAC;AAC/E,YAAY,EACV,eAAe,EACf,aAAa,EACb,YAAY,GACb,MAAM,sBAAsB,CAAC"}
@@ -4,6 +4,6 @@ type TransportModeFilterProps = {
4
4
  onChange: (transportModeFilter: string[] | null) => void;
5
5
  data?: TransportModeFilterOptionType[];
6
6
  };
7
- export default function TransportModeFilter({ filterState, onChange, data, }: TransportModeFilterProps): import("react/jsx-runtime").JSX.Element | null;
7
+ export default function TransportModeFilter({ filterState, onChange, data, }: TransportModeFilterProps): import("react").JSX.Element | null;
8
8
  export {};
9
9
  //# sourceMappingURL=filter.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"filter.d.ts","sourceRoot":"","sources":["../../../../src/modules/transport-mode/filter/filter.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,6BAA6B,EAAE,MAAM,sBAAsB,CAAC;AAUrE,KAAK,wBAAwB,GAAG;IAC9B,WAAW,EAAE,MAAM,EAAE,GAAG,IAAI,CAAC;IAC7B,QAAQ,EAAE,CAAC,mBAAmB,EAAE,MAAM,EAAE,GAAG,IAAI,KAAK,IAAI,CAAC;IACzD,IAAI,CAAC,EAAE,6BAA6B,EAAE,CAAC;CACxC,CAAC;AAEF,MAAM,CAAC,OAAO,UAAU,mBAAmB,CAAC,EAC1C,WAAW,EACX,QAAQ,EACR,IAAI,GACL,EAAE,wBAAwB,kDAyG1B"}
1
+ {"version":3,"file":"filter.d.ts","sourceRoot":"","sources":["../../../../src/modules/transport-mode/filter/filter.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,6BAA6B,EAAE,MAAM,sBAAsB,CAAC;AAUrE,KAAK,wBAAwB,GAAG;IAC9B,WAAW,EAAE,MAAM,EAAE,GAAG,IAAI,CAAC;IAC7B,QAAQ,EAAE,CAAC,mBAAmB,EAAE,MAAM,EAAE,GAAG,IAAI,KAAK,IAAI,CAAC;IACzD,IAAI,CAAC,EAAE,6BAA6B,EAAE,CAAC;CACxC,CAAC;AAEF,MAAM,CAAC,OAAO,UAAU,mBAAmB,CAAC,EAC1C,WAAW,EACX,QAAQ,EACR,IAAI,GACL,EAAE,wBAAwB,sCAyG1B"}
@@ -4,21 +4,21 @@ import { ContrastColor, TransportColors } from '../../../modules/theme';
4
4
  export type TransportIconsProps = {
5
5
  modes: TransportModeGroup[];
6
6
  };
7
- export declare function TransportIcons({ modes }: TransportIconsProps): import("react/jsx-runtime").JSX.Element;
7
+ export declare function TransportIcons({ modes }: TransportIconsProps): import("react").JSX.Element;
8
8
  export type TransportIconProps = {
9
9
  mode: TransportModeGroup;
10
10
  size?: MonoIconProps['size'];
11
11
  isFlexible?: boolean;
12
12
  };
13
- export declare function TransportIcon({ mode, size, isFlexible, }: TransportIconProps): import("react/jsx-runtime").JSX.Element;
14
- export declare function TransportMonoIcon({ mode }: TransportIconProps): import("react/jsx-runtime").JSX.Element;
13
+ export declare function TransportIcon({ mode, size, isFlexible, }: TransportIconProps): import("react").JSX.Element;
14
+ export declare function TransportMonoIcon({ mode }: TransportIconProps): import("react").JSX.Element;
15
15
  export type TransportIconWithDurationProps = {
16
16
  mode: TransportModeGroup;
17
17
  label?: string;
18
18
  duration?: number;
19
19
  isFlexible?: boolean;
20
20
  };
21
- export declare function TransportIconWithDuration({ mode, label, duration, isFlexible, }: TransportIconWithDurationProps): import("react/jsx-runtime").JSX.Element;
21
+ export declare function TransportIconWithDuration({ mode, label, duration, isFlexible, }: TransportIconWithDurationProps): import("react").JSX.Element;
22
22
  export declare function useTransportationThemeColor(mode: TransportModeGroup, isFlexible?: boolean): {
23
23
  backgroundColor: string;
24
24
  textColor: string;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/modules/transport-mode/icon/index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E,OAAO,GACnB,aAAa,CAqCf;AAED,wBAAgB,oBAAoB,CAClC,IAAI,EAAE,kBAAkB,GACvB,aAAa,CAAC,MAAM,CAAC,CAwBvB"}
@@ -1,8 +1,6 @@
1
- import { z } from 'zod';
2
- export declare const transportModeSchema: z.ZodUnion<readonly [z.ZodLiteral<"air">, z.ZodLiteral<"bus">, z.ZodLiteral<"foot">, z.ZodLiteral<"bicycle">, z.ZodLiteral<"cableway">, z.ZodLiteral<"car">, z.ZodLiteral<"carpool">, z.ZodLiteral<"coach">, z.ZodLiteral<"funicular">, z.ZodLiteral<"lift">, z.ZodLiteral<"metro">, z.ZodLiteral<"monorail">, z.ZodLiteral<"rail">, z.ZodLiteral<"scooter">, z.ZodLiteral<"taxi">, z.ZodLiteral<"tram">, z.ZodLiteral<"trolleybus">, z.ZodLiteral<"unknown">, z.ZodLiteral<"water">, z.ZodLiteral<"snowAndIce">]>;
3
- export type TransportModeType = z.infer<typeof transportModeSchema>;
4
- export declare const transportSubmodeSchema: z.ZodUnion<readonly [z.ZodLiteral<"SchengenAreaFlight">, z.ZodLiteral<"airportBoatLink">, z.ZodLiteral<"airportLinkBus">, z.ZodLiteral<"airportLinkRail">, z.ZodLiteral<"airshipService">, z.ZodLiteral<"allFunicularServices">, z.ZodLiteral<"allHireVehicles">, z.ZodLiteral<"allTaxiServices">, z.ZodLiteral<"bikeTaxi">, z.ZodLiteral<"blackCab">, z.ZodLiteral<"cableCar">, z.ZodLiteral<"cableFerry">, z.ZodLiteral<"canalBarge">, z.ZodLiteral<"carTransportRailService">, z.ZodLiteral<"chairLift">, z.ZodLiteral<"charterTaxi">, z.ZodLiteral<"cityTram">, z.ZodLiteral<"communalTaxi">, z.ZodLiteral<"commuterCoach">, z.ZodLiteral<"crossCountryRail">, z.ZodLiteral<"dedicatedLaneBus">, z.ZodLiteral<"demandAndResponseBus">, z.ZodLiteral<"domesticCharterFlight">, z.ZodLiteral<"domesticFlight">, z.ZodLiteral<"domesticScheduledFlight">, z.ZodLiteral<"dragLift">, z.ZodLiteral<"escooter">, z.ZodLiteral<"expressBus">, z.ZodLiteral<"funicular">, z.ZodLiteral<"helicopterService">, z.ZodLiteral<"highFrequencyBus">, z.ZodLiteral<"highSpeedPassengerService">, z.ZodLiteral<"highSpeedRail">, z.ZodLiteral<"highSpeedVehicleService">, z.ZodLiteral<"hireCar">, z.ZodLiteral<"hireCycle">, z.ZodLiteral<"hireMotorbike">, z.ZodLiteral<"hireVan">, z.ZodLiteral<"intercontinentalCharterFlight">, z.ZodLiteral<"intercontinentalFlight">, z.ZodLiteral<"international">, z.ZodLiteral<"internationalCarFerry">, z.ZodLiteral<"internationalCharterFlight">, z.ZodLiteral<"internationalCoach">, z.ZodLiteral<"internationalFlight">, z.ZodLiteral<"internationalPassengerFerry">, z.ZodLiteral<"interregionalRail">, z.ZodLiteral<"lift">, z.ZodLiteral<"local">, z.ZodLiteral<"localBus">, z.ZodLiteral<"localCarFerry">, z.ZodLiteral<"localPassengerFerry">, z.ZodLiteral<"localTram">, z.ZodLiteral<"longDistance">, z.ZodLiteral<"metro">, z.ZodLiteral<"miniCab">, z.ZodLiteral<"mobilityBus">, z.ZodLiteral<"mobilityBusForRegisteredDisabled">, z.ZodLiteral<"nationalCarFerry">, z.ZodLiteral<"nationalCoach">, z.ZodLiteral<"nationalPassengerFerry">, z.ZodLiteral<"nightBus">, z.ZodLiteral<"nightRail">, z.ZodLiteral<"postBoat">, z.ZodLiteral<"postBus">, z.ZodLiteral<"rackAndPinionRailway">, z.ZodLiteral<"railReplacementBus">, z.ZodLiteral<"railShuttle">, z.ZodLiteral<"railTaxi">, z.ZodLiteral<"regionalBus">, z.ZodLiteral<"regionalCarFerry">, z.ZodLiteral<"regionalCoach">, z.ZodLiteral<"regionalPassengerFerry">, z.ZodLiteral<"regionalRail">, z.ZodLiteral<"regionalTram">, z.ZodLiteral<"replacementRailService">, z.ZodLiteral<"riverBus">, z.ZodLiteral<"roadFerryLink">, z.ZodLiteral<"roundTripCharterFlight">, z.ZodLiteral<"scheduledFerry">, z.ZodLiteral<"schoolAndPublicServiceBus">, z.ZodLiteral<"schoolBoat">, z.ZodLiteral<"schoolBus">, z.ZodLiteral<"schoolCoach">, z.ZodLiteral<"shortHaulInternationalFlight">, z.ZodLiteral<"shuttleBus">, z.ZodLiteral<"shuttleCoach">, z.ZodLiteral<"shuttleFerryService">, z.ZodLiteral<"shuttleFlight">, z.ZodLiteral<"shuttleTram">, z.ZodLiteral<"sightseeingBus">, z.ZodLiteral<"sightseeingCoach">, z.ZodLiteral<"sightseeingFlight">, z.ZodLiteral<"sightseeingService">, z.ZodLiteral<"sightseeingTram">, z.ZodLiteral<"sleeperRailService">, z.ZodLiteral<"specialCoach">, z.ZodLiteral<"specialNeedsBus">, z.ZodLiteral<"specialTrain">, z.ZodLiteral<"streetCableCar">, z.ZodLiteral<"suburbanRailway">, z.ZodLiteral<"telecabin">, z.ZodLiteral<"telecabinLink">, z.ZodLiteral<"touristCoach">, z.ZodLiteral<"touristRailway">, z.ZodLiteral<"trainFerry">, z.ZodLiteral<"trainTram">, z.ZodLiteral<"tube">, z.ZodLiteral<"undefined">, z.ZodLiteral<"undefinedFunicular">, z.ZodLiteral<"unknown">, z.ZodLiteral<"urbanRailway">, z.ZodLiteral<"waterTaxi">]>;
5
- export type TransportSubmodeType = z.infer<typeof transportSubmodeSchema>;
1
+ import { TransportModeType as transportModeSchema, TransportSubmodeType as transportSubmodeSchema, type TransportModeType, type TransportSubmodeType } from '@atb-as/config-specs';
2
+ export { transportModeSchema, transportSubmodeSchema };
3
+ export type { TransportModeType, TransportSubmodeType };
6
4
  export type TransportModeGroup = {
7
5
  transportMode: TransportModeType;
8
6
  transportSubModes?: TransportSubmodeType[];
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/modules/transport-mode/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,mBAAmB,ofAqB9B,CAAC;AACH,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEpE,eAAO,MAAM,sBAAsB,wjHAkHjC,CAAC;AAEH,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC;AAE1E,MAAM,MAAM,kBAAkB,GAAG;IAC/B,aAAa,EAAE,iBAAiB,CAAC;IACjC,iBAAiB,CAAC,EAAE,oBAAoB,EAAE,CAAC;CAC5C,CAAC"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/modules/transport-mode/types.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,iBAAiB,IAAI,mBAAmB,EACxC,oBAAoB,IAAI,sBAAsB,EAC9C,KAAK,iBAAiB,EACtB,KAAK,oBAAoB,EAC1B,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EAAE,mBAAmB,EAAE,sBAAsB,EAAE,CAAC;AACvD,YAAY,EAAE,iBAAiB,EAAE,oBAAoB,EAAE,CAAC;AAExD,MAAM,MAAM,kBAAkB,GAAG;IAC/B,aAAa,EAAE,iBAAiB,CAAC;IACjC,iBAAiB,CAAC,EAAE,oBAAoB,EAAE,CAAC;CAC5C,CAAC"}