@arkyn/components 3.0.1-beta.154 → 3.0.1-beta.156

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 (337) hide show
  1. package/dist/index.js +4694 -75
  2. package/dist/modules/components/alert/alertContainer/index.js +22 -0
  3. package/dist/modules/components/alert/alertContent/index.js +9 -0
  4. package/dist/modules/components/alert/alertDescription/index.js +9 -0
  5. package/dist/modules/components/alert/alertIcon/index.js +20 -0
  6. package/dist/modules/components/alert/alertTitle/index.js +9 -0
  7. package/dist/modules/components/audioPlayer/index.js +76 -0
  8. package/dist/modules/components/audioUpload/hasFileContent/index.js +63 -0
  9. package/dist/modules/components/audioUpload/index.js +80 -0
  10. package/dist/modules/components/audioUpload/noFileContent/index.js +46 -0
  11. package/dist/modules/components/badge/index.js +23 -0
  12. package/dist/modules/components/button/index.js +33 -0
  13. package/dist/modules/components/calendar/_calendarProvider.js +65 -0
  14. package/dist/modules/components/calendar/_viewService.js +141 -0
  15. package/dist/modules/components/calendar/calendarContainer/index.js +8 -0
  16. package/dist/modules/components/calendar/calendarHeader/index.js +73 -0
  17. package/dist/modules/components/calendar/calendarTableBody/index.js +11 -0
  18. package/dist/modules/components/calendar/calendarTableContainer/index.js +8 -0
  19. package/dist/modules/components/calendar/calendarTableHeader/index.js +11 -0
  20. package/dist/modules/components/calendar/calendarTableTd/index.js +24 -0
  21. package/dist/modules/components/calendar/index.js +50 -0
  22. package/dist/modules/components/cardTab/cardTabButton/index.js +30 -0
  23. package/dist/modules/components/cardTab/cardTabContainer/index.js +29 -0
  24. package/dist/modules/components/cardTab/cardTabContext.js +13 -0
  25. package/dist/modules/components/checkbox/index.js +65 -0
  26. package/dist/modules/components/clientOnly.js +9 -0
  27. package/dist/modules/components/currencyInput/index.js +140 -0
  28. package/dist/modules/components/divider/index.js +13 -0
  29. package/dist/modules/components/drawer/drawerContainer/index.js +44 -0
  30. package/dist/modules/components/drawer/drawerContext.js +13 -0
  31. package/dist/modules/components/drawer/drawerHeader/index.js +28 -0
  32. package/dist/modules/components/facebookPixel/facebookPixel.client.js +19 -0
  33. package/dist/modules/components/facebookPixel/index.js +9 -0
  34. package/dist/modules/components/facebookPixel/pixel.js +53 -0
  35. package/dist/modules/components/fieldError/index.js +9 -0
  36. package/dist/modules/components/fieldLabel/index.js +13 -0
  37. package/dist/modules/components/fieldWrapper/index.js +14 -0
  38. package/dist/modules/components/fileUpload/hasFileContent/index.js +68 -0
  39. package/dist/modules/components/fileUpload/index.js +73 -0
  40. package/dist/modules/components/fileUpload/noFileContent/index.js +46 -0
  41. package/dist/modules/components/fullCalendar/_fullCalendarProvider.js +48 -0
  42. package/dist/modules/components/fullCalendar/_viewService.js +106 -0
  43. package/dist/modules/components/fullCalendar/dayCalendar/dayCalendarContainer/index.js +8 -0
  44. package/dist/modules/components/fullCalendar/dayCalendar/dayCalendarEvent/index.js +79 -0
  45. package/dist/modules/components/fullCalendar/dayCalendar/dayCalendarRow/index.js +34 -0
  46. package/dist/modules/components/fullCalendar/dayCalendar/index.js +11 -0
  47. package/dist/modules/components/fullCalendar/fullCalendarContainer/index.js +8 -0
  48. package/dist/modules/components/fullCalendar/fullCalendarHeader/index.js +72 -0
  49. package/dist/modules/components/fullCalendar/index.js +31 -0
  50. package/dist/modules/components/fullCalendar/monthlyCalendar/index.js +13 -0
  51. package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarEvent/index.js +37 -0
  52. package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarTableBody/index.js +11 -0
  53. package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarTableContainer/index.js +10 -0
  54. package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarTableHeader/index.js +11 -0
  55. package/dist/modules/components/fullCalendar/monthlyCalendar/monthlyCalendarTableTd/index.js +37 -0
  56. package/dist/modules/components/fullCalendar/weekCalendar/index.js +13 -0
  57. package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarEvent/index.js +79 -0
  58. package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarTableBody/index.js +21 -0
  59. package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarTableContainer/index.js +10 -0
  60. package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarTableHeader/index.js +20 -0
  61. package/dist/modules/components/fullCalendar/weekCalendar/weekCalendarTableTd/index.js +40 -0
  62. package/dist/modules/components/googleAnalytics/googleAnalytics.client.js +8 -0
  63. package/dist/modules/components/googleAnalytics/googleAnalytics.js +18 -0
  64. package/dist/modules/components/googleAnalytics/index.js +10 -0
  65. package/dist/modules/components/googleAnalytics/snippets/generateGAElements.js +16 -0
  66. package/dist/modules/components/googleTagManager/googleTagManager.client.js +8 -0
  67. package/dist/modules/components/googleTagManager/googleTagManager.js +49 -0
  68. package/dist/modules/components/googleTagManager/index.js +28 -0
  69. package/dist/modules/components/googleTagManager/snippets/appendToDataLayer.js +9 -0
  70. package/dist/modules/components/googleTagManager/snippets/generateGTMElements.js +24 -0
  71. package/dist/modules/components/iconButton/index.js +30 -0
  72. package/dist/modules/components/imageUpload/hasFileContent/index.js +64 -0
  73. package/dist/modules/components/imageUpload/index.js +83 -0
  74. package/dist/modules/components/imageUpload/noFileContent/index.js +46 -0
  75. package/dist/modules/components/input/index.js +121 -0
  76. package/dist/modules/components/mapView/index.js +33 -0
  77. package/dist/modules/components/mapView/mapView.client.js +52 -0
  78. package/dist/modules/components/maskedInput/index.js +113 -0
  79. package/dist/modules/components/modal/modalContainer/index.js +43 -0
  80. package/dist/modules/components/modal/modalContext.js +13 -0
  81. package/dist/modules/components/modal/modalFooter/index.js +9 -0
  82. package/dist/modules/components/modal/modalHeader/index.js +28 -0
  83. package/dist/modules/components/multiSelect/index.js +155 -0
  84. package/dist/modules/components/multiSelect/multiSelectChevron/index.js +22 -0
  85. package/dist/modules/components/multiSelect/multiSelectContainer/index.js +30 -0
  86. package/dist/modules/components/multiSelect/multiSelectContent/index.js +9 -0
  87. package/dist/modules/components/multiSelect/multiSelectMark/index.js +23 -0
  88. package/dist/modules/components/multiSelect/multiSelectOption/index.js +14 -0
  89. package/dist/modules/components/multiSelect/multiSelectOptionsContainer/index.js +46 -0
  90. package/dist/modules/components/multiSelect/multiSelectOverlay/index.js +9 -0
  91. package/dist/modules/components/multiSelect/multiSelectSpinner/index.js +17 -0
  92. package/dist/modules/components/pagination/chevronButton/index.js +18 -0
  93. package/dist/modules/components/pagination/currentButton/index.js +8 -0
  94. package/dist/modules/components/pagination/index.js +84 -0
  95. package/dist/modules/components/pagination/pageButton/index.js +9 -0
  96. package/dist/modules/components/pagination/paginationService.js +49 -0
  97. package/dist/modules/components/pagination/spread/index.js +9 -0
  98. package/dist/modules/components/phoneInput/index.js +152 -0
  99. package/dist/modules/components/phoneInput/phoneInputContainer/index.js +20 -0
  100. package/dist/modules/components/phoneInput/phoneInputCountriesOverlay/index.js +9 -0
  101. package/dist/modules/components/phoneInput/phoneInputCountryOption/index.js +16 -0
  102. package/dist/modules/components/phoneInput/phoneInputCountryOptionsContainer/index.js +44 -0
  103. package/dist/modules/components/phoneInput/phoneInputCountrySelector/index.js +22 -0
  104. package/dist/modules/components/phoneInput/phoneInputMask/index.js +62 -0
  105. package/dist/modules/components/popover/index.js +37 -0
  106. package/dist/modules/components/radio/radioBox/index.js +43 -0
  107. package/dist/modules/components/radio/radioContext.js +20 -0
  108. package/dist/modules/components/radio/radioGroup/index.js +65 -0
  109. package/dist/modules/components/richText/blockButton/index.js +24 -0
  110. package/dist/modules/components/richText/element/index.js +59 -0
  111. package/dist/modules/components/richText/index.js +136 -0
  112. package/dist/modules/components/richText/insertImage/index.js +106 -0
  113. package/dist/modules/components/richText/insertVideo/index.js +98 -0
  114. package/dist/modules/components/richText/leaf/index.js +7 -0
  115. package/dist/modules/components/richText/markButton/index.js +23 -0
  116. package/dist/modules/components/richText/toolbar/index.js +8 -0
  117. package/dist/modules/components/searchPlaces.js +67 -0
  118. package/dist/modules/components/select/index.js +145 -0
  119. package/dist/modules/components/select/selectChevron/index.js +22 -0
  120. package/dist/modules/components/select/selectContainer/index.js +30 -0
  121. package/dist/modules/components/select/selectContent/index.js +9 -0
  122. package/dist/modules/components/select/selectOption/index.js +14 -0
  123. package/dist/modules/components/select/selectOptionsContainer/index.js +46 -0
  124. package/dist/modules/components/select/selectOverlay/index.js +9 -0
  125. package/dist/modules/components/select/selectSpinner/index.js +10 -0
  126. package/dist/modules/components/slider/index.js +42 -0
  127. package/dist/modules/components/switch/index.js +63 -0
  128. package/dist/modules/components/tab/tabButton/index.js +30 -0
  129. package/dist/modules/components/tab/tabContainer/index.js +29 -0
  130. package/dist/modules/components/tab/tabContext.js +13 -0
  131. package/dist/modules/components/table/tableBody/index.js +15 -0
  132. package/dist/modules/components/table/tableCaption/index.js +9 -0
  133. package/dist/modules/components/table/tableContainer/index.js +9 -0
  134. package/dist/modules/components/table/tableFooter/index.js +12 -0
  135. package/dist/modules/components/table/tableHeader/index.js +12 -0
  136. package/dist/modules/components/textarea/index.js +70 -0
  137. package/dist/modules/components/tooltip/index.js +46 -0
  138. package/dist/modules/hooks/useAutomation.js +28 -0
  139. package/dist/modules/hooks/useDrawer.js +20 -0
  140. package/dist/modules/hooks/useForm.js +8 -0
  141. package/dist/modules/hooks/useHydrated.js +15 -0
  142. package/dist/modules/hooks/useModal.js +20 -0
  143. package/dist/modules/hooks/useScopedParams.js +18 -0
  144. package/dist/modules/hooks/useScrollLock.js +21 -0
  145. package/dist/modules/hooks/useSearchAutomation.js +15 -0
  146. package/dist/modules/hooks/useSlider.js +14 -0
  147. package/dist/modules/hooks/useToast.js +11 -0
  148. package/dist/modules/index.js +144 -0
  149. package/dist/modules/providers/drawerProvider.js +31 -0
  150. package/dist/modules/providers/formProvider.js +18 -0
  151. package/dist/modules/providers/modalProvider.js +34 -0
  152. package/dist/modules/providers/placesProvider.js +18 -0
  153. package/dist/modules/providers/toastProvider.js +52 -0
  154. package/dist/modules/services/extractTextFromNode.js +7 -0
  155. package/dist/modules/services/fieldTemplate.js +24 -0
  156. package/dist/modules/services/iconRenderer.js +8 -0
  157. package/dist/modules/services/isBlockActive.js +15 -0
  158. package/dist/modules/services/isMarkActive.js +8 -0
  159. package/dist/modules/services/maskCurrencyValues.js +14 -0
  160. package/dist/modules/services/toHtml.js +7 -0
  161. package/dist/modules/services/toRichTextValue.js +9 -0
  162. package/dist/modules/services/toggleBlock.js +20 -0
  163. package/dist/modules/services/toggleMark.js +8 -0
  164. package/dist/modules/style.css +1 -0
  165. package/dist/modules/templates/badResponses.js +14 -0
  166. package/dist/modules/templates/richTextTemplates.js +14 -0
  167. package/dist/modules/templates/successResponses.js +4 -0
  168. package/dist/modules/utils/phoneInputUtilities.js +32 -0
  169. package/dist/modules/utils/richTextUtilities.js +77 -0
  170. package/package.json +208 -208
  171. package/dist/components/alert/alertContainer/index.js +0 -71
  172. package/dist/components/alert/alertContent/index.js +0 -26
  173. package/dist/components/alert/alertDescription/index.js +0 -25
  174. package/dist/components/alert/alertIcon/index.js +0 -43
  175. package/dist/components/alert/alertTitle/index.js +0 -27
  176. package/dist/components/audioPlayer/index.js +0 -112
  177. package/dist/components/audioUpload/hasFileContent/index.js +0 -26
  178. package/dist/components/audioUpload/index.js +0 -95
  179. package/dist/components/audioUpload/noFileContent/index.js +0 -29
  180. package/dist/components/badge/index.js +0 -41
  181. package/dist/components/button/index.js +0 -51
  182. package/dist/components/calendar/_calendarProvider.js +0 -58
  183. package/dist/components/calendar/_viewService.js +0 -179
  184. package/dist/components/calendar/calendarContainer/index.js +0 -6
  185. package/dist/components/calendar/calendarHeader/index.js +0 -13
  186. package/dist/components/calendar/calendarTableBody/index.js +0 -9
  187. package/dist/components/calendar/calendarTableContainer/index.js +0 -6
  188. package/dist/components/calendar/calendarTableHeader/index.js +0 -9
  189. package/dist/components/calendar/calendarTableTd/index.js +0 -15
  190. package/dist/components/calendar/index.js +0 -54
  191. package/dist/components/cardTab/cardTabButton/index.js +0 -40
  192. package/dist/components/cardTab/cardTabContainer/index.js +0 -42
  193. package/dist/components/cardTab/cardTabContext.js +0 -10
  194. package/dist/components/checkbox/index.js +0 -71
  195. package/dist/components/clientOnly.js +0 -31
  196. package/dist/components/currencyInput/index.js +0 -126
  197. package/dist/components/divider/index.js +0 -28
  198. package/dist/components/drawer/drawerContainer/index.js +0 -38
  199. package/dist/components/drawer/drawerContext.js +0 -10
  200. package/dist/components/drawer/drawerHeader/index.js +0 -33
  201. package/dist/components/facebookPixel/facebookPixel.client.js +0 -23
  202. package/dist/components/facebookPixel/index.js +0 -45
  203. package/dist/components/facebookPixel/pixel.js +0 -111
  204. package/dist/components/fieldError/index.js +0 -26
  205. package/dist/components/fieldLabel/index.js +0 -23
  206. package/dist/components/fieldWrapper/index.js +0 -27
  207. package/dist/components/fileUpload/hasFileContent/index.js +0 -34
  208. package/dist/components/fileUpload/index.js +0 -89
  209. package/dist/components/fileUpload/noFileContent/index.js +0 -29
  210. package/dist/components/fullCalendar/_fullCalendarProvider.js +0 -36
  211. package/dist/components/fullCalendar/_viewService.js +0 -144
  212. package/dist/components/fullCalendar/dayCalendar/dayCalendarContainer/index.js +0 -6
  213. package/dist/components/fullCalendar/dayCalendar/dayCalendarEvent/index.js +0 -105
  214. package/dist/components/fullCalendar/dayCalendar/dayCalendarRow/index.js +0 -24
  215. package/dist/components/fullCalendar/dayCalendar/index.js +0 -9
  216. package/dist/components/fullCalendar/fullCalendarContainer/index.js +0 -6
  217. package/dist/components/fullCalendar/fullCalendarHeader/index.js +0 -37
  218. package/dist/components/fullCalendar/index.js +0 -52
  219. package/dist/components/fullCalendar/monthlyCalendar/index.js +0 -8
  220. package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarEvent/index.js +0 -29
  221. package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableBody/index.js +0 -9
  222. package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableContainer/index.js +0 -6
  223. package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableHeader/index.js +0 -9
  224. package/dist/components/fullCalendar/monthlyCalendar/monthlyCalendarTableTd/index.js +0 -30
  225. package/dist/components/fullCalendar/weekCalendar/index.js +0 -8
  226. package/dist/components/fullCalendar/weekCalendar/weekCalendarEvent/index.js +0 -102
  227. package/dist/components/fullCalendar/weekCalendar/weekCalendarTableBody/index.js +0 -11
  228. package/dist/components/fullCalendar/weekCalendar/weekCalendarTableContainer/index.js +0 -6
  229. package/dist/components/fullCalendar/weekCalendar/weekCalendarTableHeader/index.js +0 -10
  230. package/dist/components/fullCalendar/weekCalendar/weekCalendarTableTd/index.js +0 -25
  231. package/dist/components/googleAnalytics/googleAnalytics.client.js +0 -8
  232. package/dist/components/googleAnalytics/googleAnalytics.js +0 -23
  233. package/dist/components/googleAnalytics/index.js +0 -31
  234. package/dist/components/googleAnalytics/snippets/generateGAElements.js +0 -16
  235. package/dist/components/googleTagManager/googleTagManager.client.js +0 -8
  236. package/dist/components/googleTagManager/googleTagManager.js +0 -52
  237. package/dist/components/googleTagManager/index.js +0 -47
  238. package/dist/components/googleTagManager/snippets/appendToDataLayer.js +0 -7
  239. package/dist/components/googleTagManager/snippets/generateGTMElements.js +0 -25
  240. package/dist/components/iconButton/index.js +0 -38
  241. package/dist/components/imageUpload/hasFileContent/index.js +0 -24
  242. package/dist/components/imageUpload/index.js +0 -101
  243. package/dist/components/imageUpload/noFileContent/index.js +0 -29
  244. package/dist/components/input/index.js +0 -94
  245. package/dist/components/mapView/index.js +0 -53
  246. package/dist/components/mapView/mapView.client.js +0 -51
  247. package/dist/components/maskedInput/index.js +0 -108
  248. package/dist/components/modal/modalContainer/index.js +0 -40
  249. package/dist/components/modal/modalContext.js +0 -10
  250. package/dist/components/modal/modalFooter/index.js +0 -32
  251. package/dist/components/modal/modalHeader/index.js +0 -34
  252. package/dist/components/multiSelect/index.js +0 -135
  253. package/dist/components/multiSelect/multiSelectChevron/index.js +0 -18
  254. package/dist/components/multiSelect/multiSelectContainer/index.js +0 -11
  255. package/dist/components/multiSelect/multiSelectContent/index.js +0 -8
  256. package/dist/components/multiSelect/multiSelectMark/index.js +0 -11
  257. package/dist/components/multiSelect/multiSelectOption/index.js +0 -10
  258. package/dist/components/multiSelect/multiSelectOptionsContainer/index.js +0 -44
  259. package/dist/components/multiSelect/multiSelectOverlay/index.js +0 -9
  260. package/dist/components/multiSelect/multiSelectSpinner/index.js +0 -10
  261. package/dist/components/pagination/chevronButton/index.js +0 -9
  262. package/dist/components/pagination/currentButton/index.js +0 -6
  263. package/dist/components/pagination/index.js +0 -46
  264. package/dist/components/pagination/pageButton/index.js +0 -7
  265. package/dist/components/pagination/paginationService.js +0 -62
  266. package/dist/components/pagination/spread/index.js +0 -7
  267. package/dist/components/phoneInput/index.js +0 -127
  268. package/dist/components/phoneInput/phoneInputContainer/index.js +0 -11
  269. package/dist/components/phoneInput/phoneInputCountriesOverlay/index.js +0 -9
  270. package/dist/components/phoneInput/phoneInputCountryOption/index.js +0 -10
  271. package/dist/components/phoneInput/phoneInputCountryOptionsContainer/index.js +0 -40
  272. package/dist/components/phoneInput/phoneInputCountrySelector/index.js +0 -9
  273. package/dist/components/phoneInput/phoneInputMask/index.js +0 -37
  274. package/dist/components/popover/index.js +0 -62
  275. package/dist/components/radio/radioBox/index.js +0 -48
  276. package/dist/components/radio/radioContext.js +0 -11
  277. package/dist/components/radio/radioGroup/index.js +0 -58
  278. package/dist/components/richText/blockButton/index.js +0 -18
  279. package/dist/components/richText/element/index.js +0 -26
  280. package/dist/components/richText/index.js +0 -136
  281. package/dist/components/richText/insertImage/index.js +0 -33
  282. package/dist/components/richText/insertVideo/index.js +0 -51
  283. package/dist/components/richText/leaf/index.js +0 -13
  284. package/dist/components/richText/markButton/index.js +0 -16
  285. package/dist/components/richText/toolbar/index.js +0 -6
  286. package/dist/components/searchPlaces.js +0 -99
  287. package/dist/components/select/index.js +0 -134
  288. package/dist/components/select/selectChevron/index.js +0 -18
  289. package/dist/components/select/selectContainer/index.js +0 -11
  290. package/dist/components/select/selectContent/index.js +0 -8
  291. package/dist/components/select/selectOption/index.js +0 -10
  292. package/dist/components/select/selectOptionsContainer/index.js +0 -44
  293. package/dist/components/select/selectOverlay/index.js +0 -9
  294. package/dist/components/select/selectSpinner/index.js +0 -10
  295. package/dist/components/slider/index.js +0 -79
  296. package/dist/components/switch/index.js +0 -66
  297. package/dist/components/tab/tabButton/index.js +0 -40
  298. package/dist/components/tab/tabContainer/index.js +0 -42
  299. package/dist/components/tab/tabContext.js +0 -10
  300. package/dist/components/table/tableBody/index.js +0 -34
  301. package/dist/components/table/tableCaption/index.js +0 -24
  302. package/dist/components/table/tableContainer/index.js +0 -37
  303. package/dist/components/table/tableFooter/index.js +0 -23
  304. package/dist/components/table/tableHeader/index.js +0 -25
  305. package/dist/components/textarea/index.js +0 -80
  306. package/dist/components/tooltip/index.js +0 -96
  307. package/dist/hooks/useAutomation.js +0 -74
  308. package/dist/hooks/useDrawer.js +0 -20
  309. package/dist/hooks/useForm.js +0 -35
  310. package/dist/hooks/useHydrated.js +0 -26
  311. package/dist/hooks/useModal.js +0 -20
  312. package/dist/hooks/useScopedParams.js +0 -55
  313. package/dist/hooks/useScrollLock.js +0 -46
  314. package/dist/hooks/useSearchAutomation.js +0 -64
  315. package/dist/hooks/useSlider.js +0 -35
  316. package/dist/hooks/useToast.js +0 -28
  317. package/dist/providers/drawerProvider.js +0 -54
  318. package/dist/providers/formProvider.js +0 -34
  319. package/dist/providers/modalProvider.js +0 -58
  320. package/dist/providers/placesProvider.js +0 -40
  321. package/dist/providers/toastProvider.js +0 -62
  322. package/dist/services/extractTextFromNode.js +0 -5
  323. package/dist/services/fieldTemplate.js +0 -11
  324. package/dist/services/iconRenderer.js +0 -13
  325. package/dist/services/isBlockActive.js +0 -14
  326. package/dist/services/isMarkActive.js +0 -6
  327. package/dist/services/maskCurrencyValues.js +0 -23
  328. package/dist/services/toHtml.js +0 -22
  329. package/dist/services/toRichTextValue.js +0 -34
  330. package/dist/services/toggleBlock.js +0 -32
  331. package/dist/services/toggleMark.js +0 -10
  332. package/dist/templates/badResponses.js +0 -12
  333. package/dist/templates/richTextTemplates.js +0 -12
  334. package/dist/templates/successResponses.js +0 -2
  335. package/dist/types/richTextTypes.js +0 -1
  336. package/dist/utils/phoneInputUtilities.js +0 -37
  337. package/dist/utils/richTextUtilities.js +0 -89
@@ -0,0 +1,28 @@
1
+ import { useEffect as h } from "react";
2
+ import { scroller as A } from "react-scroll";
3
+ import { useModal as j } from "./useModal.js";
4
+ import { useToast as v } from "./useToast.js";
5
+ import { badResponses as w } from "../templates/badResponses.js";
6
+ import { successResponses as x } from "../templates/successResponses.js";
7
+ function B(c) {
8
+ var t, T, g, y;
9
+ const { closeAll: E } = j(), { showToast: i } = v(), b = c == null ? void 0 : c.closeModal, l = c == null ? void 0 : c.message, r = c == null ? void 0 : c.name, d = (T = (t = c == null ? void 0 : c.cause) == null ? void 0 : t.data) == null ? void 0 : T.scrollTo, u = (g = c == null ? void 0 : c.cause) != null && g.fieldErrors ? Object.values((y = c == null ? void 0 : c.cause) == null ? void 0 : y.fieldErrors)[0] : null;
10
+ function M() {
11
+ if (!(!l && !u)) {
12
+ if (x.includes(r))
13
+ return i({ message: l, type: "success" });
14
+ if (w.includes(r)) {
15
+ if (u)
16
+ return i({ message: u, type: "danger" });
17
+ if (l !== "Unprocessable entity")
18
+ return i({ message: l, type: "danger" });
19
+ }
20
+ }
21
+ }
22
+ h(() => {
23
+ b && E(), d && A.scrollTo(d, { smooth: !0, offset: 20 }), M();
24
+ }, [c]);
25
+ }
26
+ export {
27
+ B as useAutomation
28
+ };
@@ -0,0 +1,20 @@
1
+ import { useContext as D } from "react";
2
+ import { drawerContext as p } from "../providers/drawerProvider.js";
3
+ function l(r) {
4
+ const e = D(p);
5
+ if (Object.entries(e).length === 0)
6
+ throw new Error("useDrawer must be used within a Provider");
7
+ if (r) {
8
+ const {
9
+ drawerData: t,
10
+ drawerIsOpen: o,
11
+ openDrawer: n,
12
+ closeDrawer: a
13
+ } = e, s = o(r), w = t(r);
14
+ return { drawerIsOpen: s, drawerData: w, openDrawer: (c) => n(r, c), closeDrawer: () => a(r) };
15
+ } else
16
+ return e;
17
+ }
18
+ export {
19
+ l as useDrawer
20
+ };
@@ -0,0 +1,8 @@
1
+ import { useContext as t } from "react";
2
+ import { formContext as o } from "../providers/formProvider.js";
3
+ function m() {
4
+ return t(o);
5
+ }
6
+ export {
7
+ m as useForm
8
+ };
@@ -0,0 +1,15 @@
1
+ import { useSyncExternalStore as r } from "react";
2
+ function e() {
3
+ return () => {
4
+ };
5
+ }
6
+ function n() {
7
+ return r(
8
+ e,
9
+ () => !0,
10
+ () => !1
11
+ );
12
+ }
13
+ export {
14
+ n as useHydrated
15
+ };
@@ -0,0 +1,20 @@
1
+ import { useContext as r } from "react";
2
+ import { modalContext as M } from "../providers/modalProvider.js";
3
+ function x(o) {
4
+ const t = r(M);
5
+ if (Object.entries(t).length === 0)
6
+ throw new Error("useModal must be used within a Provider");
7
+ if (o) {
8
+ const {
9
+ modalData: e,
10
+ modalIsOpen: n,
11
+ openModal: a,
12
+ closeModal: l
13
+ } = t, s = n(o), d = e(o);
14
+ return { modalIsOpen: s, modalData: d, openModal: (c) => a(o, c), closeModal: () => l(o) };
15
+ } else
16
+ return t;
17
+ }
18
+ export {
19
+ x as useModal
20
+ };
@@ -0,0 +1,18 @@
1
+ function i(n, c = "") {
2
+ const t = new URLSearchParams(n), a = c ? `${c}:` : "", o = (r) => {
3
+ Object.entries(r).forEach(([e, s]) => {
4
+ s === void 0 ? t.delete(`${a}${e}`) : t.set(`${a}${e}`, String(s));
5
+ });
6
+ };
7
+ return {
8
+ getParam: (r) => t.get(`${a}${r}`),
9
+ getScopedSearch: (r) => {
10
+ o(r);
11
+ let e = t.toString();
12
+ return e && (e = "?" + e), e;
13
+ }
14
+ };
15
+ }
16
+ export {
17
+ i as useScopedParams
18
+ };
@@ -0,0 +1,21 @@
1
+ import { useEffect as c } from "react";
2
+ function l() {
3
+ return typeof window > "u" ? 0 : window.innerWidth - document.documentElement.clientWidth;
4
+ }
5
+ function u(t) {
6
+ c(() => {
7
+ if (t) {
8
+ const e = document.body.style.overflow, n = document.body.style.paddingRight, o = l();
9
+ if (o > 0) {
10
+ const d = window.getComputedStyle(document.body), i = parseInt(d.paddingRight) || 0;
11
+ document.body.style.paddingRight = `${i + o}px`;
12
+ }
13
+ return document.body.style.overflow = "hidden", () => {
14
+ document.body.style.overflow = e, document.body.style.paddingRight = n;
15
+ };
16
+ }
17
+ }, [t]);
18
+ }
19
+ export {
20
+ u as useScrollLock
21
+ };
@@ -0,0 +1,15 @@
1
+ import { useEffect as u } from "react";
2
+ import { useModal as f } from "./useModal.js";
3
+ import { useToast as d } from "./useToast.js";
4
+ import { badResponses as r } from "../templates/badResponses.js";
5
+ import { successResponses as a } from "../templates/successResponses.js";
6
+ import { useScopedParams as l } from "./useScopedParams.js";
7
+ function R(m, i = "") {
8
+ const { closeAll: p } = f(), { showToast: o } = d(), { getParam: t } = l(m, i), n = t("closeModal") === "true", s = t("message"), e = t("name"), c = t("type");
9
+ u(() => {
10
+ n && p(), s && (c === "success" && o({ message: s, type: "success" }), c === "danger" && o({ message: s, type: "danger" }), e && r.includes(e) && !r.includes(s) && o({ message: s, type: "danger" }), e && a.includes(e) && !a.includes(s) && o({ message: s, type: "success" }));
11
+ }, [n, s, e, c]);
12
+ }
13
+ export {
14
+ R as useSearchAutomation
15
+ };
@@ -0,0 +1,14 @@
1
+ import { useState as f } from "react";
2
+ function c(r) {
3
+ function t() {
4
+ return !r || r <= 0 ? 0 : r >= 100 ? 100 : r;
5
+ }
6
+ const [i, e] = f(t());
7
+ function u(n) {
8
+ return n <= 0 ? e(0) : n >= 100 ? e(100) : e(n);
9
+ }
10
+ return [i, u];
11
+ }
12
+ export {
13
+ c as useSlider
14
+ };
@@ -0,0 +1,11 @@
1
+ import { toastContext as e } from "../providers/toastProvider.js";
2
+ import { useContext as o } from "react";
3
+ function s() {
4
+ const t = o(e);
5
+ if (Object.entries(t).length === 0)
6
+ throw new Error("useToast must be used within a Provider");
7
+ return t;
8
+ }
9
+ export {
10
+ s as useToast
11
+ };
@@ -0,0 +1,144 @@
1
+ import { AlertContainer as e } from "./components/alert/alertContainer/index.js";
2
+ import { AlertContent as p } from "./components/alert/alertContent/index.js";
3
+ import { AlertDescription as x } from "./components/alert/alertDescription/index.js";
4
+ import { AlertIcon as a } from "./components/alert/alertIcon/index.js";
5
+ import { AlertTitle as i } from "./components/alert/alertTitle/index.js";
6
+ import { AudioPlayer as d } from "./components/audioPlayer/index.js";
7
+ import { AudioUpload as c } from "./components/audioUpload/index.js";
8
+ import { Badge as T } from "./components/badge/index.js";
9
+ import { Button as P } from "./components/button/index.js";
10
+ import { Calendar as A } from "./components/calendar/index.js";
11
+ import { CardTabButton as M } from "./components/cardTab/cardTabButton/index.js";
12
+ import { CardTabContainer as g } from "./components/cardTab/cardTabContainer/index.js";
13
+ import { Checkbox as v } from "./components/checkbox/index.js";
14
+ import { ClientOnly as I } from "./components/clientOnly.js";
15
+ import { CurrencyInput as y } from "./components/currencyInput/index.js";
16
+ import { Divider as H } from "./components/divider/index.js";
17
+ import { DrawerContainer as R } from "./components/drawer/drawerContainer/index.js";
18
+ import { DrawerHeader as U } from "./components/drawer/drawerHeader/index.js";
19
+ import { FacebookPixel as V } from "./components/facebookPixel/index.js";
20
+ import { FieldError as O } from "./components/fieldError/index.js";
21
+ import { FieldLabel as j } from "./components/fieldLabel/index.js";
22
+ import { FieldWrapper as z } from "./components/fieldWrapper/index.js";
23
+ import { FileUpload as K } from "./components/fileUpload/index.js";
24
+ import { FullCalendar as Q } from "./components/fullCalendar/index.js";
25
+ import { GoogleAnalytics as Y } from "./components/googleAnalytics/index.js";
26
+ import { GoogleTagManager as _ } from "./components/googleTagManager/index.js";
27
+ import { IconButton as oo } from "./components/iconButton/index.js";
28
+ import { ImageUpload as eo } from "./components/imageUpload/index.js";
29
+ import { Input as po } from "./components/input/index.js";
30
+ import { MapView as xo } from "./components/mapView/index.js";
31
+ import { MaskedInput as ao } from "./components/maskedInput/index.js";
32
+ import { ModalContainer as io } from "./components/modal/modalContainer/index.js";
33
+ import { ModalFooter as uo } from "./components/modal/modalFooter/index.js";
34
+ import { ModalHeader as so } from "./components/modal/modalHeader/index.js";
35
+ import { MultiSelect as Co } from "./components/multiSelect/index.js";
36
+ import { Pagination as bo } from "./components/pagination/index.js";
37
+ import { PhoneInput as Fo } from "./components/phoneInput/index.js";
38
+ import { Popover as So } from "./components/popover/index.js";
39
+ import { RadioBox as ho } from "./components/radio/radioBox/index.js";
40
+ import { RadioGroup as Bo } from "./components/radio/radioGroup/index.js";
41
+ import { RichText as wo } from "./components/richText/index.js";
42
+ import { SearchPlaces as Do } from "./components/searchPlaces.js";
43
+ import { Select as ko } from "./components/select/index.js";
44
+ import { Slider as Go } from "./components/slider/index.js";
45
+ import { Switch as Lo } from "./components/switch/index.js";
46
+ import { TabButton as Eo } from "./components/tab/tabButton/index.js";
47
+ import { TabContainer as Wo } from "./components/tab/tabContainer/index.js";
48
+ import { TableBody as qo } from "./components/table/tableBody/index.js";
49
+ import { TableCaption as Jo } from "./components/table/tableCaption/index.js";
50
+ import { TableContainer as No } from "./components/table/tableContainer/index.js";
51
+ import { TableFooter as Xo } from "./components/table/tableFooter/index.js";
52
+ import { TableHeader as Zo } from "./components/table/tableHeader/index.js";
53
+ import { Textarea as $o } from "./components/textarea/index.js";
54
+ import { Tooltip as rr } from "./components/tooltip/index.js";
55
+ import { useAutomation as tr } from "./hooks/useAutomation.js";
56
+ import { useDrawer as mr } from "./hooks/useDrawer.js";
57
+ import { useForm as fr } from "./hooks/useForm.js";
58
+ import { useHydrated as lr } from "./hooks/useHydrated.js";
59
+ import { useModal as nr } from "./hooks/useModal.js";
60
+ import { useScopedParams as ur } from "./hooks/useScopedParams.js";
61
+ import { useScrollLock as sr } from "./hooks/useScrollLock.js";
62
+ import { useSearchAutomation as Cr } from "./hooks/useSearchAutomation.js";
63
+ import { useSlider as br } from "./hooks/useSlider.js";
64
+ import { useToast as Fr } from "./hooks/useToast.js";
65
+ import { DrawerProvider as Sr } from "./providers/drawerProvider.js";
66
+ import { FormProvider as hr } from "./providers/formProvider.js";
67
+ import { ModalProvider as Br } from "./providers/modalProvider.js";
68
+ import { PlacesProvider as wr } from "./providers/placesProvider.js";
69
+ import { ToastProvider as Dr } from "./providers/toastProvider.js";
70
+ import { toHtml as kr } from "./services/toHtml.js";
71
+ import { toRichTextValue as Gr } from "./services/toRichTextValue.js";
72
+ export {
73
+ e as AlertContainer,
74
+ p as AlertContent,
75
+ x as AlertDescription,
76
+ a as AlertIcon,
77
+ i as AlertTitle,
78
+ d as AudioPlayer,
79
+ c as AudioUpload,
80
+ T as Badge,
81
+ P as Button,
82
+ A as Calendar,
83
+ M as CardTabButton,
84
+ g as CardTabContainer,
85
+ v as Checkbox,
86
+ I as ClientOnly,
87
+ y as CurrencyInput,
88
+ H as Divider,
89
+ R as DrawerContainer,
90
+ U as DrawerHeader,
91
+ Sr as DrawerProvider,
92
+ V as FacebookPixel,
93
+ O as FieldError,
94
+ j as FieldLabel,
95
+ z as FieldWrapper,
96
+ K as FileUpload,
97
+ hr as FormProvider,
98
+ Q as FullCalendar,
99
+ Y as GoogleAnalytics,
100
+ _ as GoogleTagManager,
101
+ oo as IconButton,
102
+ eo as ImageUpload,
103
+ po as Input,
104
+ xo as MapView,
105
+ ao as MaskedInput,
106
+ io as ModalContainer,
107
+ uo as ModalFooter,
108
+ so as ModalHeader,
109
+ Br as ModalProvider,
110
+ Co as MultiSelect,
111
+ bo as Pagination,
112
+ Fo as PhoneInput,
113
+ wr as PlacesProvider,
114
+ So as Popover,
115
+ ho as RadioBox,
116
+ Bo as RadioGroup,
117
+ wo as RichText,
118
+ Do as SearchPlaces,
119
+ ko as Select,
120
+ Go as Slider,
121
+ Lo as Switch,
122
+ Eo as TabButton,
123
+ Wo as TabContainer,
124
+ qo as TableBody,
125
+ Jo as TableCaption,
126
+ No as TableContainer,
127
+ Xo as TableFooter,
128
+ Zo as TableHeader,
129
+ $o as Textarea,
130
+ Dr as ToastProvider,
131
+ rr as Tooltip,
132
+ kr as toHtml,
133
+ Gr as toRichTextValue,
134
+ tr as useAutomation,
135
+ mr as useDrawer,
136
+ fr as useForm,
137
+ lr as useHydrated,
138
+ nr as useModal,
139
+ ur as useScopedParams,
140
+ sr as useScrollLock,
141
+ Cr as useSearchAutomation,
142
+ br as useSlider,
143
+ Fr as useToast
144
+ };
@@ -0,0 +1,31 @@
1
+ import { jsx as w } from "react/jsx-runtime";
2
+ import { useState as p, createContext as D } from "react";
3
+ const m = D({});
4
+ function C(a) {
5
+ const { children: s = !1 } = a, [t, n] = p([]);
6
+ function i(e) {
7
+ return !!t.some((r) => r.key === e);
8
+ }
9
+ function f(e) {
10
+ var r;
11
+ return (r = t.find((o) => o.key === e)) == null ? void 0 : r.data;
12
+ }
13
+ function c(e, r) {
14
+ const o = i(e);
15
+ n(o ? (u) => [...u.filter((l) => l.key !== e), { key: e, data: r }] : [...t, { key: e, data: r }]);
16
+ }
17
+ function d(e) {
18
+ n(t.filter((r) => r.key !== e));
19
+ }
20
+ return /* @__PURE__ */ w(
21
+ m.Provider,
22
+ {
23
+ value: { drawerIsOpen: i, drawerData: f, openDrawer: c, closeDrawer: d },
24
+ children: s
25
+ }
26
+ );
27
+ }
28
+ export {
29
+ C as DrawerProvider,
30
+ m as drawerContext
31
+ };
@@ -0,0 +1,18 @@
1
+ import { jsxs as n } from "react/jsx-runtime";
2
+ import { cloneElement as i, createContext as m } from "react";
3
+ const c = m({});
4
+ function s(e) {
5
+ const { children: o, fieldErrors: t, form: r } = e;
6
+ return /* @__PURE__ */ n(c.Provider, { value: { fieldErrors: t }, children: [
7
+ !r && o,
8
+ r && i(
9
+ r,
10
+ r.props,
11
+ o
12
+ )
13
+ ] });
14
+ }
15
+ export {
16
+ s as FormProvider,
17
+ c as formContext
18
+ };
@@ -0,0 +1,34 @@
1
+ import { jsx as p } from "react/jsx-runtime";
2
+ import { useState as x, createContext as M } from "react";
3
+ const v = M({});
4
+ function P(i) {
5
+ const { children: d = !1 } = i, [t, n] = x([]);
6
+ function l(e) {
7
+ return !!t.some((o) => o.key === e);
8
+ }
9
+ function s(e) {
10
+ var o;
11
+ return (o = t.find((r) => r.key === e)) == null ? void 0 : o.data;
12
+ }
13
+ function a(e, o) {
14
+ const r = l(e);
15
+ n(r ? (u) => [...u.filter((m) => m.key !== e), { key: e, data: o }] : [...t, { key: e, data: o }]);
16
+ }
17
+ function c(e) {
18
+ n(t.filter((o) => o.key !== e));
19
+ }
20
+ function f() {
21
+ n([]);
22
+ }
23
+ return /* @__PURE__ */ p(
24
+ v.Provider,
25
+ {
26
+ value: { modalIsOpen: l, modalData: s, openModal: a, closeModal: c, closeAll: f },
27
+ children: d
28
+ }
29
+ );
30
+ }
31
+ export {
32
+ P as ModalProvider,
33
+ v as modalContext
34
+ };
@@ -0,0 +1,18 @@
1
+ import { jsx as i, Fragment as s } from "react/jsx-runtime";
2
+ import { useLoadScript as a } from "@react-google-maps/api";
3
+ const p = [
4
+ "places",
5
+ "marker",
6
+ "maps"
7
+ ];
8
+ function l(e) {
9
+ const { apiKey: o, children: r, preventFontsLoading: n = !0 } = e, { isLoaded: t } = a({
10
+ googleMapsApiKey: o,
11
+ libraries: p,
12
+ preventGoogleFontsLoading: n
13
+ });
14
+ return /* @__PURE__ */ i(s, { children: r(t) });
15
+ }
16
+ export {
17
+ l as PlacesProvider
18
+ };
@@ -0,0 +1,52 @@
1
+ import { jsxs as f, jsx as n } from "react/jsx-runtime";
2
+ import { createContext as s } from "react";
3
+ import o, { Toaster as i } from "react-hot-toast";
4
+ const a = s({});
5
+ function m({ children: t }) {
6
+ function r(e) {
7
+ switch (e.type) {
8
+ case "success":
9
+ return o.success(e.message, {
10
+ style: {
11
+ background: "#10B981",
12
+ color: "#ffffff",
13
+ padding: "12px 16px",
14
+ fontSize: "14px",
15
+ fontWeight: 600
16
+ },
17
+ iconTheme: {
18
+ primary: "#059669",
19
+ secondary: "#ffffff"
20
+ }
21
+ });
22
+ case "danger":
23
+ return o.error(e.message, {
24
+ style: {
25
+ background: "#E11D48",
26
+ color: "#ffffff",
27
+ padding: "12px 16px",
28
+ fontSize: "14px",
29
+ fontWeight: 600
30
+ },
31
+ iconTheme: {
32
+ primary: "#BE123C",
33
+ secondary: "#ffffff"
34
+ }
35
+ });
36
+ }
37
+ }
38
+ return /* @__PURE__ */ f(a.Provider, { value: { showToast: r }, children: [
39
+ /* @__PURE__ */ n(
40
+ i,
41
+ {
42
+ position: "top-right",
43
+ containerStyle: { zIndex: 999999999999999 }
44
+ }
45
+ ),
46
+ t
47
+ ] });
48
+ }
49
+ export {
50
+ m as ToastProvider,
51
+ a as toastContext
52
+ };
@@ -0,0 +1,7 @@
1
+ import { Node as t } from "slate";
2
+ function n(o) {
3
+ return o.map((r) => t.string(r)).join("");
4
+ }
5
+ export {
6
+ n as extractTextFromNode
7
+ };
@@ -0,0 +1,24 @@
1
+ import { jsxs as d, jsx as o } from "react/jsx-runtime";
2
+ import { FieldError as p } from "../components/fieldError/index.js";
3
+ import { FieldLabel as c } from "../components/fieldLabel/index.js";
4
+ import { FieldWrapper as f } from "../components/fieldWrapper/index.js";
5
+ function b(l) {
6
+ const {
7
+ name: t,
8
+ label: r,
9
+ showAsterisk: n,
10
+ className: m,
11
+ unShowFieldTemplate: s,
12
+ errorMessage: e,
13
+ children: i,
14
+ orientation: a
15
+ } = l;
16
+ return s ? i : /* @__PURE__ */ d(f, { id: t, className: m, orientation: a, children: [
17
+ r && /* @__PURE__ */ o(c, { showAsterisk: n, children: r }),
18
+ i,
19
+ e && /* @__PURE__ */ o(p, { children: e })
20
+ ] });
21
+ }
22
+ export {
23
+ b as FieldTemplate
24
+ };
@@ -0,0 +1,8 @@
1
+ import { jsx as e, Fragment as t } from "react/jsx-runtime";
2
+ function f(i) {
3
+ const { iconSize: o, icon: r, className: n, show: c = !0 } = i;
4
+ return c ? r ? typeof r == "string" ? /* @__PURE__ */ e("p", { className: n, children: r }) : /* @__PURE__ */ e(r, { size: o, strokeWidth: 2.5, className: n }) : /* @__PURE__ */ e(t, {}) : /* @__PURE__ */ e(t, {});
5
+ }
6
+ export {
7
+ f as IconRenderer
8
+ };
@@ -0,0 +1,15 @@
1
+ import { Editor as n, Element as s } from "slate";
2
+ function m(t, r, c = "type") {
3
+ const { selection: o } = t;
4
+ if (!o) return !1;
5
+ const [i] = Array.from(
6
+ n.nodes(t, {
7
+ at: n.unhangRange(t, o),
8
+ match: (e) => !n.isEditor(e) && s.isElement(e) && e[c] === r
9
+ })
10
+ );
11
+ return !!i;
12
+ }
13
+ export {
14
+ m as isBlockActive
15
+ };
@@ -0,0 +1,8 @@
1
+ import { Editor as e } from "slate";
2
+ function s(t, o) {
3
+ const r = e.marks(t);
4
+ return r ? r[o] === !0 : !1;
5
+ }
6
+ export {
7
+ s as isMarkActive
8
+ };
@@ -0,0 +1,14 @@
1
+ import { formatToCurrency as o, removeNonNumeric as i } from "@arkyn/shared";
2
+ function f(e) {
3
+ let r = e;
4
+ return typeof e == "string" ? (r = +i(e), r % 1 !== 0 && (r = r.toFixed(2))) : r = Number.isInteger(e) ? Number(e) * 10 ** 2 : e.toFixed(2), +i(String(r)) / 10 ** 2;
5
+ }
6
+ function u(e, r) {
7
+ if (!e) return [0, o(0, r)];
8
+ const t = f(e), n = o(t, r);
9
+ return [t, n];
10
+ }
11
+ export {
12
+ u as maskCurrencyValues,
13
+ f as normalizeValue
14
+ };
@@ -0,0 +1,7 @@
1
+ import { serialize as t } from "../utils/richTextUtilities.js";
2
+ function e(o) {
3
+ return o.map((r) => t(r)).join("");
4
+ }
5
+ export {
6
+ e as toHtml
7
+ };
@@ -0,0 +1,9 @@
1
+ import f from "html-react-parser";
2
+ import { deserialize as e } from "../utils/richTextUtilities.js";
3
+ function p(i) {
4
+ const r = f(i);
5
+ return Array.isArray(r) ? r.map((t) => typeof t == "string" ? { text: t } : e(t)) : typeof r == "string" ? [{ text: r }] : [e(r)];
6
+ }
7
+ export {
8
+ p as toRichTextValue
9
+ };
@@ -0,0 +1,20 @@
1
+ import { Transforms as o, Editor as y, Element as d } from "slate";
2
+ import { listTypes as n, textAlignTypes as p } from "../templates/richTextTemplates.js";
3
+ import { isBlockActive as m } from "./isBlockActive.js";
4
+ function g(t, e) {
5
+ const r = p.includes(e) ? "align" : "type", i = m(t, e, r), c = n.includes(e);
6
+ o.unwrapNodes(t, {
7
+ match: (s) => !y.isEditor(s) && d.isElement(s) && n.includes(s.type) && !p.includes(e),
8
+ split: !0
9
+ });
10
+ let l;
11
+ if (p.includes(e) ? l = { align: i ? void 0 : e } : l = {
12
+ type: i ? "paragraph" : c ? "listItem" : e
13
+ }, o.setNodes(t, l), !i && c) {
14
+ const s = { type: e, children: [] };
15
+ o.wrapNodes(t, s);
16
+ }
17
+ }
18
+ export {
19
+ g as toggleBlock
20
+ };
@@ -0,0 +1,8 @@
1
+ import { Editor as r } from "slate";
2
+ import { isMarkActive as t } from "./isMarkActive.js";
3
+ function k(i, e) {
4
+ t(i, e) ? r.removeMark(i, e) : r.addMark(i, e, !0);
5
+ }
6
+ export {
7
+ k as toggleMark
8
+ };