@bigbinary/neeto-molecules 3.15.43 → 3.15.45

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 (426) hide show
  1. package/dist/AuditLogs.js +539 -0
  2. package/dist/AuditLogs.js.map +1 -0
  3. package/dist/BoardView.js +394 -0
  4. package/dist/BoardView.js.map +1 -0
  5. package/dist/Breadcrumbs.js +46 -0
  6. package/dist/Breadcrumbs.js.map +1 -0
  7. package/dist/BrowserPreview.js +50 -0
  8. package/dist/BrowserPreview.js.map +1 -0
  9. package/dist/BrowserSupport.js +348 -0
  10. package/dist/BrowserSupport.js.map +1 -0
  11. package/dist/Builder.js +786 -0
  12. package/dist/Builder.js.map +1 -0
  13. package/dist/ButtonGroup.js +36 -0
  14. package/dist/ButtonGroup.js.map +1 -0
  15. package/dist/CalendarView.js +356 -0
  16. package/dist/CalendarView.js.map +1 -0
  17. package/dist/CardLayout.js +49 -0
  18. package/dist/CardLayout.js.map +1 -0
  19. package/dist/Chevron-DfSoxXBs.js +246 -0
  20. package/dist/Chevron-DfSoxXBs.js.map +1 -0
  21. package/dist/Codeblock.js +58 -0
  22. package/dist/Codeblock.js.map +1 -0
  23. package/dist/Columns.js +21 -0
  24. package/dist/Columns.js.map +1 -0
  25. package/dist/ConfigurePageSidebar.js +97 -0
  26. package/dist/ConfigurePageSidebar.js.map +1 -0
  27. package/dist/ConfirmationModal.js +110 -0
  28. package/dist/ConfirmationModal.js.map +1 -0
  29. package/dist/Container.js +38 -0
  30. package/dist/Container.js.map +1 -0
  31. package/dist/CopyToClipboardButton.js +82 -0
  32. package/dist/CopyToClipboardButton.js.map +1 -0
  33. package/dist/Currency.js +917 -0
  34. package/dist/Currency.js.map +1 -0
  35. package/dist/DateFormat.js +45 -0
  36. package/dist/DateFormat.js.map +1 -0
  37. package/dist/DateRangeFilter.js +178 -0
  38. package/dist/DateRangeFilter.js.map +1 -0
  39. package/dist/DeleteArchiveModal.js +98 -0
  40. package/dist/DeleteArchiveModal.js.map +1 -0
  41. package/dist/DeviceIncompatibilityMessage.js +95 -0
  42. package/dist/DeviceIncompatibilityMessage.js.map +1 -0
  43. package/dist/DocumentEditor.js +183 -0
  44. package/dist/DocumentEditor.js.map +1 -0
  45. package/dist/DownloadMobileAppCallout.js +40 -0
  46. package/dist/DownloadMobileAppCallout.js.map +1 -0
  47. package/dist/DynamicVariables.js +115 -0
  48. package/dist/DynamicVariables.js.map +1 -0
  49. package/dist/EmailForm.js +567 -0
  50. package/dist/EmailForm.js.map +1 -0
  51. package/dist/EmailPreview.js +140 -0
  52. package/dist/EmailPreview.js.map +1 -0
  53. package/dist/EmojiPicker.js +112 -0
  54. package/dist/EmojiPicker.js.map +1 -0
  55. package/dist/EmojiReactions.js +82 -0
  56. package/dist/EmojiReactions.js.map +1 -0
  57. package/dist/Engagements.js +292 -0
  58. package/dist/Engagements.js.map +1 -0
  59. package/dist/ErrorPage.js +1811 -0
  60. package/dist/ErrorPage.js.map +1 -0
  61. package/dist/FileUpload.js +595 -0
  62. package/dist/FileUpload.js.map +1 -0
  63. package/dist/FinderModal.js +280 -0
  64. package/dist/FinderModal.js.map +1 -0
  65. package/dist/FloatingActionMenu.js +854 -0
  66. package/dist/FloatingActionMenu.js.map +1 -0
  67. package/dist/GoogleFontPicker.js +581 -0
  68. package/dist/GoogleFontPicker.js.map +1 -0
  69. package/dist/Header.js +126 -0
  70. package/dist/Header.js.map +1 -0
  71. package/dist/HelpPopover.js +83 -0
  72. package/dist/HelpPopover.js.map +1 -0
  73. package/dist/IconPicker.js +1159 -0
  74. package/dist/IconPicker.js.map +1 -0
  75. package/dist/ImageWithFallback.js +49 -0
  76. package/dist/ImageWithFallback.js.map +1 -0
  77. package/dist/InlineInput.js +230 -0
  78. package/dist/InlineInput.js.map +1 -0
  79. package/dist/Insights.js +358 -0
  80. package/dist/Insights.js.map +1 -0
  81. package/dist/IntegrationCard.js +227 -0
  82. package/dist/IntegrationCard.js.map +1 -0
  83. package/dist/IpRestriction.js +3617 -0
  84. package/dist/IpRestriction.js.map +1 -0
  85. package/dist/KeyboardShortcuts.js +284 -0
  86. package/dist/KeyboardShortcuts.js.map +1 -0
  87. package/dist/LoginPage.js +184 -0
  88. package/dist/LoginPage.js.map +1 -0
  89. package/dist/MadeWith.js +41 -0
  90. package/dist/MadeWith.js.map +1 -0
  91. package/dist/MenuBar.js +1326 -0
  92. package/dist/MenuBar.js.map +1 -0
  93. package/dist/Metadata.js +218 -0
  94. package/dist/Metadata.js.map +1 -0
  95. package/dist/MobilePreviewHeader.js +25 -0
  96. package/dist/MobilePreviewHeader.js.map +1 -0
  97. package/dist/MoreDropdown.js +163 -0
  98. package/dist/MoreDropdown.js.map +1 -0
  99. package/dist/NavigationHeader.js +264 -0
  100. package/dist/NavigationHeader.js.map +1 -0
  101. package/dist/NeetoWidget.js +2867 -0
  102. package/dist/NeetoWidget.js.map +1 -0
  103. package/dist/Onboarding.js +246 -0
  104. package/dist/Onboarding.js.map +1 -0
  105. package/dist/OptionFields.js +717 -0
  106. package/dist/OptionFields.js.map +1 -0
  107. package/dist/PageLoader.js +40 -0
  108. package/dist/PageLoader.js.map +1 -0
  109. package/dist/PhoneNumber.js +75 -0
  110. package/dist/PhoneNumber.js.map +1 -0
  111. package/dist/ProductEmbed.js +884 -0
  112. package/dist/ProductEmbed.js.map +1 -0
  113. package/dist/PublishBlock.js +447 -0
  114. package/dist/PublishBlock.js.map +1 -0
  115. package/dist/PublishYourItem.js +58 -0
  116. package/dist/PublishYourItem.js.map +1 -0
  117. package/dist/Rename.js +366 -0
  118. package/dist/Rename.js.map +1 -0
  119. package/dist/ResponsiveDevicePicker.js +63 -0
  120. package/dist/ResponsiveDevicePicker.js.map +1 -0
  121. package/dist/Schedule.js +926 -0
  122. package/dist/Schedule.js.map +1 -0
  123. package/dist/Scrollable.js +42 -0
  124. package/dist/Scrollable.js.map +1 -0
  125. package/dist/Search.js +110 -0
  126. package/dist/Search.js.map +1 -0
  127. package/dist/SendToFields.js +2221 -0
  128. package/dist/SendToFields.js.map +1 -0
  129. package/dist/SessionEnvironment.js +431 -0
  130. package/dist/SessionEnvironment.js.map +1 -0
  131. package/dist/Settings.js +250 -0
  132. package/dist/Settings.js.map +1 -0
  133. package/dist/ShareRecordingPane.js +216 -0
  134. package/dist/ShareRecordingPane.js.map +1 -0
  135. package/dist/ShareViaEmail.js +416 -0
  136. package/dist/ShareViaEmail.js.map +1 -0
  137. package/dist/ShareViaLink.js +1556 -0
  138. package/dist/ShareViaLink.js.map +1 -0
  139. package/dist/Sidebar.js +294 -0
  140. package/dist/Sidebar.js.map +1 -0
  141. package/dist/StatusDropdown.js +109 -0
  142. package/dist/StatusDropdown.js.map +1 -0
  143. package/dist/StickyRibbonsContainer.js +131 -0
  144. package/dist/StickyRibbonsContainer.js.map +1 -0
  145. package/dist/SubHeader.js +209 -0
  146. package/dist/SubHeader.js.map +1 -0
  147. package/dist/SubscriptionNotificationsContainer.js +77 -0
  148. package/dist/SubscriptionNotificationsContainer.js.map +1 -0
  149. package/dist/SuffixedInput.js +111 -0
  150. package/dist/SuffixedInput.js.map +1 -0
  151. package/dist/TableWrapper.js +27 -0
  152. package/dist/TableWrapper.js.map +1 -0
  153. package/dist/Taxonomy.js +496 -0
  154. package/dist/Taxonomy.js.map +1 -0
  155. package/dist/TimeFormat.js +14 -0
  156. package/dist/TimeFormat.js.map +1 -0
  157. package/dist/TimezoneMismatchModal.js +138 -0
  158. package/dist/TimezoneMismatchModal.js.map +1 -0
  159. package/dist/ToggleFeatureCard.js +211 -0
  160. package/dist/ToggleFeatureCard.js.map +1 -0
  161. package/dist/_commonjsHelpers-BFTU3MAI.js +8 -0
  162. package/dist/_commonjsHelpers-BFTU3MAI.js.map +1 -0
  163. package/dist/cjs/AuditLogs.js +541 -0
  164. package/dist/cjs/AuditLogs.js.map +1 -0
  165. package/dist/cjs/BoardView.js +396 -0
  166. package/dist/cjs/BoardView.js.map +1 -0
  167. package/dist/cjs/Breadcrumbs.js +48 -0
  168. package/dist/cjs/Breadcrumbs.js.map +1 -0
  169. package/dist/cjs/BrowserPreview.js +52 -0
  170. package/dist/cjs/BrowserPreview.js.map +1 -0
  171. package/dist/cjs/BrowserSupport.js +350 -0
  172. package/dist/cjs/BrowserSupport.js.map +1 -0
  173. package/dist/cjs/Builder.js +794 -0
  174. package/dist/cjs/Builder.js.map +1 -0
  175. package/dist/cjs/ButtonGroup.js +38 -0
  176. package/dist/cjs/ButtonGroup.js.map +1 -0
  177. package/dist/cjs/CalendarView.js +358 -0
  178. package/dist/cjs/CalendarView.js.map +1 -0
  179. package/dist/cjs/CardLayout.js +51 -0
  180. package/dist/cjs/CardLayout.js.map +1 -0
  181. package/dist/cjs/Chevron-DJbXy_CD.js +256 -0
  182. package/dist/cjs/Chevron-DJbXy_CD.js.map +1 -0
  183. package/dist/cjs/Codeblock.js +60 -0
  184. package/dist/cjs/Codeblock.js.map +1 -0
  185. package/dist/cjs/Columns.js +35 -0
  186. package/dist/cjs/Columns.js.map +1 -0
  187. package/dist/cjs/ConfigurePageSidebar.js +99 -0
  188. package/dist/cjs/ConfigurePageSidebar.js.map +1 -0
  189. package/dist/cjs/ConfirmationModal.js +131 -0
  190. package/dist/cjs/ConfirmationModal.js.map +1 -0
  191. package/dist/cjs/Container.js +40 -0
  192. package/dist/cjs/Container.js.map +1 -0
  193. package/dist/cjs/CopyToClipboardButton.js +84 -0
  194. package/dist/cjs/CopyToClipboardButton.js.map +1 -0
  195. package/dist/cjs/Currency.js +920 -0
  196. package/dist/cjs/Currency.js.map +1 -0
  197. package/dist/cjs/DateFormat.js +47 -0
  198. package/dist/cjs/DateFormat.js.map +1 -0
  199. package/dist/cjs/DateRangeFilter.js +180 -0
  200. package/dist/cjs/DateRangeFilter.js.map +1 -0
  201. package/dist/cjs/DeleteArchiveModal.js +100 -0
  202. package/dist/cjs/DeleteArchiveModal.js.map +1 -0
  203. package/dist/cjs/DeviceIncompatibilityMessage.js +115 -0
  204. package/dist/cjs/DeviceIncompatibilityMessage.js.map +1 -0
  205. package/dist/cjs/DocumentEditor.js +185 -0
  206. package/dist/cjs/DocumentEditor.js.map +1 -0
  207. package/dist/cjs/DownloadMobileAppCallout.js +42 -0
  208. package/dist/cjs/DownloadMobileAppCallout.js.map +1 -0
  209. package/dist/cjs/DynamicVariables.js +117 -0
  210. package/dist/cjs/DynamicVariables.js.map +1 -0
  211. package/dist/cjs/EmailForm.js +593 -0
  212. package/dist/cjs/EmailForm.js.map +1 -0
  213. package/dist/cjs/EmailPreview.js +142 -0
  214. package/dist/cjs/EmailPreview.js.map +1 -0
  215. package/dist/cjs/EmojiPicker.js +114 -0
  216. package/dist/cjs/EmojiPicker.js.map +1 -0
  217. package/dist/cjs/EmojiReactions.js +84 -0
  218. package/dist/cjs/EmojiReactions.js.map +1 -0
  219. package/dist/cjs/Engagements.js +294 -0
  220. package/dist/cjs/Engagements.js.map +1 -0
  221. package/dist/cjs/ErrorPage.js +1831 -0
  222. package/dist/cjs/ErrorPage.js.map +1 -0
  223. package/dist/cjs/FileUpload.js +598 -0
  224. package/dist/cjs/FileUpload.js.map +1 -0
  225. package/dist/cjs/FinderModal.js +282 -0
  226. package/dist/cjs/FinderModal.js.map +1 -0
  227. package/dist/cjs/FloatingActionMenu.js +875 -0
  228. package/dist/cjs/FloatingActionMenu.js.map +1 -0
  229. package/dist/cjs/GoogleFontPicker.js +583 -0
  230. package/dist/cjs/GoogleFontPicker.js.map +1 -0
  231. package/dist/cjs/Header.js +128 -0
  232. package/dist/cjs/Header.js.map +1 -0
  233. package/dist/cjs/HelpPopover.js +85 -0
  234. package/dist/cjs/HelpPopover.js.map +1 -0
  235. package/dist/cjs/IconPicker.js +1161 -0
  236. package/dist/cjs/IconPicker.js.map +1 -0
  237. package/dist/cjs/ImageWithFallback.js +51 -0
  238. package/dist/cjs/ImageWithFallback.js.map +1 -0
  239. package/dist/cjs/InlineInput.js +233 -0
  240. package/dist/cjs/InlineInput.js.map +1 -0
  241. package/dist/cjs/Insights.js +360 -0
  242. package/dist/cjs/Insights.js.map +1 -0
  243. package/dist/cjs/IntegrationCard.js +229 -0
  244. package/dist/cjs/IntegrationCard.js.map +1 -0
  245. package/dist/cjs/IpRestriction.js +3638 -0
  246. package/dist/cjs/IpRestriction.js.map +1 -0
  247. package/dist/cjs/KeyboardShortcuts.js +286 -0
  248. package/dist/cjs/KeyboardShortcuts.js.map +1 -0
  249. package/dist/cjs/LoginPage.js +205 -0
  250. package/dist/cjs/LoginPage.js.map +1 -0
  251. package/dist/cjs/MadeWith.js +43 -0
  252. package/dist/cjs/MadeWith.js.map +1 -0
  253. package/dist/cjs/MenuBar.js +1328 -0
  254. package/dist/cjs/MenuBar.js.map +1 -0
  255. package/dist/cjs/Metadata.js +220 -0
  256. package/dist/cjs/Metadata.js.map +1 -0
  257. package/dist/cjs/MobilePreviewHeader.js +27 -0
  258. package/dist/cjs/MobilePreviewHeader.js.map +1 -0
  259. package/dist/cjs/MoreDropdown.js +165 -0
  260. package/dist/cjs/MoreDropdown.js.map +1 -0
  261. package/dist/cjs/NavigationHeader.js +266 -0
  262. package/dist/cjs/NavigationHeader.js.map +1 -0
  263. package/dist/cjs/NeetoWidget.js +2888 -0
  264. package/dist/cjs/NeetoWidget.js.map +1 -0
  265. package/dist/cjs/Onboarding.js +248 -0
  266. package/dist/cjs/Onboarding.js.map +1 -0
  267. package/dist/cjs/OptionFields.js +719 -0
  268. package/dist/cjs/OptionFields.js.map +1 -0
  269. package/dist/cjs/PageLoader.js +42 -0
  270. package/dist/cjs/PageLoader.js.map +1 -0
  271. package/dist/cjs/PhoneNumber.js +80 -0
  272. package/dist/cjs/PhoneNumber.js.map +1 -0
  273. package/dist/cjs/ProductEmbed.js +886 -0
  274. package/dist/cjs/ProductEmbed.js.map +1 -0
  275. package/dist/cjs/PublishBlock.js +449 -0
  276. package/dist/cjs/PublishBlock.js.map +1 -0
  277. package/dist/cjs/PublishYourItem.js +60 -0
  278. package/dist/cjs/PublishYourItem.js.map +1 -0
  279. package/dist/cjs/Rename.js +368 -0
  280. package/dist/cjs/Rename.js.map +1 -0
  281. package/dist/cjs/ResponsiveDevicePicker.js +65 -0
  282. package/dist/cjs/ResponsiveDevicePicker.js.map +1 -0
  283. package/dist/cjs/Schedule.js +947 -0
  284. package/dist/cjs/Schedule.js.map +1 -0
  285. package/dist/cjs/Scrollable.js +44 -0
  286. package/dist/cjs/Scrollable.js.map +1 -0
  287. package/dist/cjs/Search.js +112 -0
  288. package/dist/cjs/Search.js.map +1 -0
  289. package/dist/cjs/SendToFields.js +2223 -0
  290. package/dist/cjs/SendToFields.js.map +1 -0
  291. package/dist/cjs/SessionEnvironment.js +433 -0
  292. package/dist/cjs/SessionEnvironment.js.map +1 -0
  293. package/dist/cjs/Settings.js +252 -0
  294. package/dist/cjs/Settings.js.map +1 -0
  295. package/dist/cjs/ShareRecordingPane.js +218 -0
  296. package/dist/cjs/ShareRecordingPane.js.map +1 -0
  297. package/dist/cjs/ShareViaEmail.js +437 -0
  298. package/dist/cjs/ShareViaEmail.js.map +1 -0
  299. package/dist/cjs/ShareViaLink.js +1577 -0
  300. package/dist/cjs/ShareViaLink.js.map +1 -0
  301. package/dist/cjs/Sidebar.js +315 -0
  302. package/dist/cjs/Sidebar.js.map +1 -0
  303. package/dist/cjs/StatusDropdown.js +111 -0
  304. package/dist/cjs/StatusDropdown.js.map +1 -0
  305. package/dist/cjs/StickyRibbonsContainer.js +133 -0
  306. package/dist/cjs/StickyRibbonsContainer.js.map +1 -0
  307. package/dist/cjs/SubHeader.js +211 -0
  308. package/dist/cjs/SubHeader.js.map +1 -0
  309. package/dist/cjs/SubscriptionNotificationsContainer.js +79 -0
  310. package/dist/cjs/SubscriptionNotificationsContainer.js.map +1 -0
  311. package/dist/cjs/SuffixedInput.js +113 -0
  312. package/dist/cjs/SuffixedInput.js.map +1 -0
  313. package/dist/cjs/TableWrapper.js +29 -0
  314. package/dist/cjs/TableWrapper.js.map +1 -0
  315. package/dist/cjs/Taxonomy.js +517 -0
  316. package/dist/cjs/Taxonomy.js.map +1 -0
  317. package/dist/cjs/TimeFormat.js +16 -0
  318. package/dist/cjs/TimeFormat.js.map +1 -0
  319. package/dist/cjs/TimezoneMismatchModal.js +140 -0
  320. package/dist/cjs/TimezoneMismatchModal.js.map +1 -0
  321. package/dist/cjs/ToggleFeatureCard.js +213 -0
  322. package/dist/cjs/ToggleFeatureCard.js.map +1 -0
  323. package/dist/cjs/_commonjsHelpers-BJu3ubxk.js +11 -0
  324. package/dist/cjs/_commonjsHelpers-BJu3ubxk.js.map +1 -0
  325. package/dist/cjs/index-JY2zVpnv.js +1189 -0
  326. package/dist/cjs/index-JY2zVpnv.js.map +1 -0
  327. package/dist/cjs/inject-css-vQvjPR2x.js +6 -0
  328. package/dist/cjs/inject-css-vQvjPR2x.js.map +1 -0
  329. package/dist/cjs/phone-number-BN-c0rfv.js +320 -0
  330. package/dist/cjs/phone-number-BN-c0rfv.js.map +1 -0
  331. package/dist/cjs/platform-BUcCb8Jx.js +1254 -0
  332. package/dist/cjs/platform-BUcCb8Jx.js.map +1 -0
  333. package/dist/cjs/useColumns-BP8c4PV-.js +282 -0
  334. package/dist/cjs/useColumns-BP8c4PV-.js.map +1 -0
  335. package/dist/index-DAYCJu79.js +1187 -0
  336. package/dist/index-DAYCJu79.js.map +1 -0
  337. package/dist/inject-css-DmrvuTKK.js +4 -0
  338. package/dist/inject-css-DmrvuTKK.js.map +1 -0
  339. package/dist/phone-number-CXCBroLh.js +295 -0
  340. package/dist/phone-number-CXCBroLh.js.map +1 -0
  341. package/dist/platform-F44zJ4Xh.js +1252 -0
  342. package/dist/platform-F44zJ4Xh.js.map +1 -0
  343. package/dist/styles/page-loader.css +1 -0
  344. package/dist/styles/page-loader.js +3 -0
  345. package/dist/useColumns-Db5uic1-.js +274 -0
  346. package/dist/useColumns-Db5uic1-.js.map +1 -0
  347. package/package.json +5 -5
  348. package/types/AuditLogs.d.ts +22 -0
  349. package/types/BoardView.d.ts +149 -0
  350. package/types/Breadcrumbs.d.ts +30 -0
  351. package/types/BrowserPreview.d.ts +30 -0
  352. package/types/BrowserSupport.d.ts +110 -0
  353. package/types/Builder.d.ts +99 -0
  354. package/types/ButtonGroup.d.ts +45 -0
  355. package/types/CalendarView.d.ts +98 -0
  356. package/types/CardLayout.d.ts +34 -0
  357. package/types/Codeblock.d.ts +37 -0
  358. package/types/Columns.d.ts +168 -0
  359. package/types/ConfigurePageSidebar.d.ts +45 -0
  360. package/types/ConfirmationModal.d.ts +65 -0
  361. package/types/Container.d.ts +38 -0
  362. package/types/CopyToClipboardButton.d.ts +28 -0
  363. package/types/Currency.d.ts +50 -0
  364. package/types/DateFormat.d.ts +15 -0
  365. package/types/DateRangeFilter.d.ts +56 -0
  366. package/types/DeleteArchiveModal.d.ts +65 -0
  367. package/types/DeviceIncompatibilityMessage.d.ts +19 -0
  368. package/types/DocumentEditor.d.ts +61 -0
  369. package/types/DownloadMobileAppCallout.d.ts +35 -0
  370. package/types/DynamicVariables.d.ts +48 -0
  371. package/types/EmailForm.d.ts +165 -0
  372. package/types/EmailFormProvider.d.ts +48 -0
  373. package/types/EmailPreview.d.ts +43 -0
  374. package/types/EmojiPicker.d.ts +35 -0
  375. package/types/EmojiReactions.d.ts +62 -0
  376. package/types/Engagements.d.ts +131 -0
  377. package/types/ErrorPage.d.ts +22 -0
  378. package/types/FileUpload.d.ts +89 -0
  379. package/types/FinderModal.d.ts +66 -0
  380. package/types/FloatingActionMenu.d.ts +59 -0
  381. package/types/GoogleFontPicker.d.ts +68 -0
  382. package/types/Header.d.ts +37 -0
  383. package/types/HelpPopover.d.ts +45 -0
  384. package/types/IconPicker.d.ts +45 -0
  385. package/types/ImageWithFallback.d.ts +24 -0
  386. package/types/InlineInput.d.ts +87 -0
  387. package/types/Insights.d.ts +112 -0
  388. package/types/IntegrationCard.d.ts +60 -0
  389. package/types/IpRestriction.d.ts +25 -0
  390. package/types/KeyboardShortcuts.d.ts +149 -0
  391. package/types/LoginPage.d.ts +45 -0
  392. package/types/MadeWith.d.ts +18 -0
  393. package/types/MenuBar.d.ts +127 -0
  394. package/types/Metadata.d.ts +109 -0
  395. package/types/MobilePreviewHeader.d.ts +19 -0
  396. package/types/MoreDropdown.d.ts +52 -0
  397. package/types/NavigationHeader.d.ts +180 -0
  398. package/types/NeetoWidget.d.ts +43 -0
  399. package/types/Onboarding.d.ts +70 -0
  400. package/types/OptionFields.d.ts +70 -0
  401. package/types/PageLoader.d.ts +40 -0
  402. package/types/PhoneNumber.d.ts +112 -0
  403. package/types/ProductEmbed.d.ts +93 -0
  404. package/types/PublishBlock.d.ts +148 -0
  405. package/types/Rename.d.ts +73 -0
  406. package/types/ResponsiveDevicePicker.d.ts +32 -0
  407. package/types/Schedule.d.ts +146 -0
  408. package/types/Scrollable.d.ts +30 -0
  409. package/types/Search.d.ts +22 -0
  410. package/types/SendToFields.d.ts +67 -0
  411. package/types/SessionEnvironment.d.ts +170 -0
  412. package/types/Settings.d.ts +108 -0
  413. package/types/ShareRecordingPane.d.ts +85 -0
  414. package/types/ShareViaEmail.d.ts +99 -0
  415. package/types/ShareViaLink.d.ts +183 -0
  416. package/types/Sidebar.d.ts +51 -0
  417. package/types/StatusDropdown.d.ts +74 -0
  418. package/types/StickyRibbonsContainer.d.ts +28 -0
  419. package/types/SubHeader.d.ts +105 -0
  420. package/types/SubscriptionNotificationsContainer.d.ts +26 -0
  421. package/types/SuffixedInput.d.ts +45 -0
  422. package/types/TableWrapper.d.ts +40 -0
  423. package/types/Taxonomy.d.ts +59 -0
  424. package/types/TimeFormat.d.ts +13 -0
  425. package/types/TimezoneMismatchModal.d.ts +41 -0
  426. package/types/ToggleFeatureCard.d.ts +38 -0
@@ -0,0 +1,886 @@
1
+ 'use strict';
2
+
3
+ var _defineProperty = require('@babel/runtime/helpers/defineProperty');
4
+ var _slicedToArray = require('@babel/runtime/helpers/slicedToArray');
5
+ var React = require('react');
6
+ var classnames = require('classnames');
7
+ var neetoCist = require('@bigbinary/neeto-cist');
8
+ var LeftArrow = require('@bigbinary/neeto-icons/LeftArrow');
9
+ var Button = require('@bigbinary/neetoui/Button');
10
+ var Typography = require('@bigbinary/neetoui/Typography');
11
+ var ramda = require('ramda');
12
+ var reactI18next = require('react-i18next');
13
+ var Codeblock = require('./Codeblock.js');
14
+ var jsxRuntime = require('react/jsx-runtime');
15
+ var i18next = require('i18next');
16
+ var Code$1 = require('@bigbinary/neeto-icons/Code');
17
+ var Input = require('@bigbinary/neetoui/Input');
18
+ var Callout = require('@bigbinary/neetoui/Callout');
19
+ var _toConsumableArray = require('@babel/runtime/helpers/toConsumableArray');
20
+ var Delete = require('@bigbinary/neeto-icons/Delete');
21
+ var Plus = require('@bigbinary/neeto-icons/Plus');
22
+ var Label = require('@bigbinary/neetoui/Label');
23
+ var _objectWithoutProperties = require('@babel/runtime/helpers/objectWithoutProperties');
24
+ var Checkbox = require('@bigbinary/neetoui/Checkbox');
25
+ var Select = require('@bigbinary/neetoui/Select');
26
+ var ColorPicker = require('@bigbinary/neetoui/ColorPicker');
27
+ var Tab = require('@bigbinary/neetoui/Tab');
28
+ var Radio = require('@bigbinary/neetoui/Radio');
29
+ var Spinner = require('@bigbinary/neetoui/Spinner');
30
+ var BrowserPreview = require('./BrowserPreview.js');
31
+ var injectCss = require('./inject-css-vQvjPR2x.js');
32
+ require('react-syntax-highlighter/dist/esm/prism-light.js');
33
+ require('react-syntax-highlighter/dist/esm/styles/prism');
34
+ require('./CopyToClipboardButton.js');
35
+ require('@bigbinary/neeto-commons-frontend/utils/general');
36
+ require('@bigbinary/neeto-icons/Copy');
37
+ require('@bigbinary/neeto-icons/Check');
38
+
39
+ var Code = function Code(_ref) {
40
+ var code = _ref.code,
41
+ tab = _ref.tab;
42
+ return /*#__PURE__*/jsxRuntime.jsx("div", {
43
+ className: "neeto-molecules-embed__code-block relative w-full overflow-y-auto",
44
+ "data-cy": "embed-code-block",
45
+ "data-testid": "".concat(tab, "-code-block"),
46
+ children: /*#__PURE__*/jsxRuntime.jsx(Codeblock, {
47
+ code: code
48
+ })
49
+ });
50
+ };
51
+
52
+ var TAB_KEYS = {
53
+ HTML: "html",
54
+ REACT: "react"
55
+ };
56
+ var TABS = [{
57
+ key: TAB_KEYS.HTML,
58
+ label: i18next.t("neetoMolecules.productEmbed.tab.html"),
59
+ icon: Code$1
60
+ }, {
61
+ key: TAB_KEYS.REACT,
62
+ label: i18next.t("neetoMolecules.productEmbed.tab.react"),
63
+ icon: Code$1
64
+ }];
65
+ var EMBED_OPTIONS = {
66
+ INLINE: "inline",
67
+ FLOATING_POPUP: "floatingPopup",
68
+ ELEMENT_POPUP: "elementPopup"
69
+ };
70
+ var DEFAULT_CUSTOMIZATION = _defineProperty(_defineProperty(_defineProperty({}, EMBED_OPTIONS.INLINE, {
71
+ width: 100,
72
+ height: 100,
73
+ elementSelector: "inline-embed-container"
74
+ }), EMBED_OPTIONS.FLOATING_POPUP, {
75
+ showIcon: false,
76
+ btnText: "Open",
77
+ btnColor: "#008068",
78
+ btnTextColor: "#fff",
79
+ btnPosition: "bottomRight"
80
+ }), EMBED_OPTIONS.ELEMENT_POPUP, {
81
+ elementSelector: "open-popup-button"
82
+ });
83
+ var SCRIPT_ID = "embed-script";
84
+ var TAB_STRING = " ";
85
+
86
+ var FLOATING_BUTTON_POSITIONS = [{
87
+ label: i18next.t("neetoMolecules.productEmbed.customization.position.bottomLeft"),
88
+ value: "bottomLeft"
89
+ }, {
90
+ label: i18next.t("neetoMolecules.productEmbed.customization.position.bottomRight"),
91
+ value: "bottomRight"
92
+ }];
93
+ var INITIAL_QUERY_PARAM = {
94
+ name: "",
95
+ value: ""
96
+ };
97
+
98
+ var camelCasedAppName$1 = globalProps.appName.replace(/^neeto/i, "neeto");
99
+ var embedBaseScript = function embedBaseScript(embedScriptLink) {
100
+ return "<script>window.".concat(camelCasedAppName$1, " = window.").concat(camelCasedAppName$1, " || { embed: function(){(").concat(camelCasedAppName$1, ".q=").concat(camelCasedAppName$1, ".q||[]).push(arguments)} };</script>\n <script async\n src=\"").concat(embedScriptLink, "\">\n </script>");
101
+ };
102
+ var embedEnv$1 = function embedEnv() {
103
+ return globalProps.railsEnv !== "production" ? "\n".concat(TAB_STRING, " env: \"").concat(globalProps.railsEnv, "\",") : "";
104
+ };
105
+ var embedQueryParam$1 = function embedQueryParam(queryParams) {
106
+ return queryParams ? "\n".concat(TAB_STRING, " queryParams: ").concat(queryParams, ",") : "";
107
+ };
108
+ var parseExtraArgs$1 = function parseExtraArgs(extraArgs) {
109
+ return ramda.toPairs(extraArgs).map(function (_ref) {
110
+ var _ref2 = _slicedToArray(_ref, 2),
111
+ key = _ref2[0],
112
+ value = _ref2[1];
113
+ return "\n".concat(TAB_STRING, " ").concat(key, ": \"").concat(value, "\"");
114
+ });
115
+ };
116
+ var inlineEmbedCode$1 = function inlineEmbedCode(_ref3) {
117
+ var customization = _ref3.customization,
118
+ id = _ref3.id,
119
+ embedScriptLink = _ref3.embedScriptLink,
120
+ extraArgs = _ref3.extraArgs,
121
+ inlineWrapperStyle = _ref3.inlineWrapperStyle;
122
+ var elementSelector = customization.elementSelector,
123
+ _customization$width = customization.width,
124
+ width = _customization$width === void 0 ? 100 : _customization$width,
125
+ _customization$height = customization.height,
126
+ height = _customization$height === void 0 ? 100 : _customization$height,
127
+ queryParams = customization.queryParams;
128
+ return "\n <!-- ".concat(globalProps.appName, " inline embed code begins -->\n <div style=\"").concat(inlineWrapperStyle || "height: 90vh; width: 100%;", "\" id=\"").concat(elementSelector, "\">\n <!-- ").concat(globalProps.appName, " widget will be added here -->\n </div>\n ").concat(embedBaseScript(embedScriptLink), "\n <script>\n ").concat(camelCasedAppName$1, ".embed({\n type: \"inline\",\n id: \"").concat(id, "\",\n organization: \"").concat(globalProps.organization.subdomain, "\",\n elementSelector: \"#").concat(elementSelector, "\",\n styles: { height: \"").concat(height, "%\", width: \"").concat(width, "%\"},").concat(embedQueryParam$1(queryParams)).concat(embedEnv$1()).concat(parseExtraArgs$1(extraArgs), "\n });\n </script>\n <!-- ").concat(globalProps.appName, " inline embed code ends -->");
129
+ };
130
+ var floatingPopupEmbedCode$1 = function floatingPopupEmbedCode(_ref4) {
131
+ var customization = _ref4.customization,
132
+ id = _ref4.id,
133
+ embedScriptLink = _ref4.embedScriptLink,
134
+ extraArgs = _ref4.extraArgs;
135
+ var btnTextColor = customization.btnTextColor,
136
+ showIcon = customization.showIcon,
137
+ btnText = customization.btnText,
138
+ btnPosition = customization.btnPosition,
139
+ btnColor = customization.btnColor,
140
+ icon = customization.icon,
141
+ queryParams = customization.queryParams;
142
+ return "\n <!-- ".concat(globalProps.appName, " floating-popup embed code begins -->\n ").concat(embedBaseScript(embedScriptLink), "\n <script>\n ").concat(camelCasedAppName$1, ".embed({\n type: \"floatingPopup\",\n id: \"").concat(id, "\",\n organization: \"").concat(globalProps.organization.subdomain, "\",\n styles: {\n btnTextColor: \"").concat(btnTextColor, "\",\n btnPosition: \"").concat(btnPosition, "\",\n btnColor: \"").concat(btnColor, "\",\n btnText: \"").concat(btnText, "\", ").concat(icon ? "\n".concat(TAB_STRING).concat(TAB_STRING, "showIcon: ").concat(showIcon, ",") : "", "\n },").concat(embedQueryParam$1(queryParams)).concat(embedEnv$1()).concat(parseExtraArgs$1(extraArgs), "\n });\n </script>\n <!-- ").concat(globalProps.appName, " floating-popup embed code ends -->");
143
+ };
144
+ var elementPopupEmbedCode$1 = function elementPopupEmbedCode(_ref5) {
145
+ var customization = _ref5.customization,
146
+ id = _ref5.id,
147
+ embedScriptLink = _ref5.embedScriptLink,
148
+ extraArgs = _ref5.extraArgs;
149
+ var elementSelector = customization.elementSelector,
150
+ queryParams = customization.queryParams;
151
+ return "\n <!-- This is a demo button, you can use any element on your website instead. -->\n <button id=\"".concat(elementSelector, "\">Click to open popup</button>\n\n <!-- ").concat(globalProps.appName, " element-click embed code begins -->\n ").concat(embedBaseScript(embedScriptLink), "\n <script>\n ").concat(camelCasedAppName$1, ".embed({\n type: \"elementClick\",\n id: \"").concat(id, "\",\n organization: \"").concat(globalProps.organization.subdomain, "\",\n elementSelector: \"#").concat(elementSelector, "\",").concat(embedQueryParam$1(queryParams)).concat(embedEnv$1()).concat(parseExtraArgs$1(extraArgs), "\n });\n </script>\n <!-- ").concat(globalProps.appName, " element-click embed code ends -->");
152
+ };
153
+ var htmlCodeGenerators = {
154
+ inline: inlineEmbedCode$1,
155
+ floatingPopup: floatingPopupEmbedCode$1,
156
+ elementPopup: elementPopupEmbedCode$1
157
+ };
158
+
159
+ var camelCasedAppName = globalProps.appName.replace(/^neeto/i, "neeto");
160
+ var embedFunctionName = "embed".concat(globalProps.appName);
161
+ var baseScript = "const baseScript = document.createElement(\"script\");\n baseScript.innerHTML = `window.".concat(camelCasedAppName, " = window.").concat(camelCasedAppName, " || { embed: function(){(").concat(camelCasedAppName, ".q=").concat(camelCasedAppName, ".q||[]).push(arguments)} };`\n document.body.appendChild(baseScript);\n");
162
+ var embedScript = function embedScript(scriptLink) {
163
+ return "const embedScript = document.createElement(\"script\");\n embedScript.src = \"".concat(scriptLink, "\";\n embedScript.async = true;\n document.body.appendChild(embedScript);\n");
164
+ };
165
+ var cleanupFunction = "// Cleanup function\n return () => {\n document.body.removeChild(baseScript);\n document.body.removeChild(embedScript);\n };";
166
+ var embedEnv = function embedEnv() {
167
+ return globalProps.railsEnv !== "production" ? "\n".concat(TAB_STRING).concat(TAB_STRING, "env: \"").concat(globalProps.railsEnv, "\",") : "";
168
+ };
169
+ var embedQueryParam = function embedQueryParam(queryParams) {
170
+ return queryParams ? "\n".concat(TAB_STRING).concat(TAB_STRING, "queryParams: ").concat(queryParams, ",") : "";
171
+ };
172
+ var parseExtraArgs = function parseExtraArgs(extraArgs) {
173
+ return ramda.toPairs(extraArgs).map(function (_ref) {
174
+ var _ref2 = _slicedToArray(_ref, 2),
175
+ key = _ref2[0],
176
+ value = _ref2[1];
177
+ return "\n".concat(TAB_STRING).concat(TAB_STRING).concat(key, ": \"").concat(value, "\"");
178
+ });
179
+ };
180
+ var parseInlineStyle = function parseInlineStyle(styleString) {
181
+ return styleString ? styleString.split(";").map(function (rule) {
182
+ var _rule$split$map = rule.split(":").map(function (s) {
183
+ return s.trim();
184
+ }),
185
+ _rule$split$map2 = _slicedToArray(_rule$split$map, 2),
186
+ key = _rule$split$map2[0],
187
+ value = _rule$split$map2[1];
188
+ return key && value ? "".concat(key, ": \"").concat(value, "\"") : null;
189
+ }).filter(Boolean).join(", ") : 'height: "90vh", width: "100%"';
190
+ };
191
+ var inlineEmbedCode = function inlineEmbedCode(_ref3) {
192
+ var customization = _ref3.customization,
193
+ id = _ref3.id,
194
+ embedScriptLink = _ref3.embedScriptLink,
195
+ extraArgs = _ref3.extraArgs,
196
+ inlineWrapperStyle = _ref3.inlineWrapperStyle;
197
+ var elementSelector = customization.elementSelector,
198
+ _customization$width = customization.width,
199
+ width = _customization$width === void 0 ? 100 : _customization$width,
200
+ _customization$height = customization.height,
201
+ height = _customization$height === void 0 ? 100 : _customization$height,
202
+ queryParams = customization.queryParams;
203
+ return "\n import { useEffect } from \"react\";\n\n const App = () => {\n const ".concat(embedFunctionName, " = () => {\n ").concat(baseScript, "\n ").concat(embedScript(embedScriptLink), "\n ").concat(camelCasedAppName, ".embed({\n type: \"inline\",\n id: \"").concat(id, "\",\n organization: \"").concat(globalProps.organization.subdomain, "\",\n elementSelector: \"#").concat(elementSelector, "\",\n styles: { height: \"").concat(height, "%\", width: \"").concat(width, "%\" },").concat(embedQueryParam(queryParams)).concat(embedEnv()).concat(parseExtraArgs(extraArgs), "\n });\n\n ").concat(cleanupFunction, "\n };\n\n useEffect(() => ").concat(embedFunctionName, "(), []);\n\n return (\n <div\n id=\"inline-embed-container\"\n style={{ ").concat(parseInlineStyle(inlineWrapperStyle), " }}\n />\n );\n };");
204
+ };
205
+ var floatingPopupEmbedCode = function floatingPopupEmbedCode(_ref4) {
206
+ var customization = _ref4.customization,
207
+ id = _ref4.id,
208
+ embedScriptLink = _ref4.embedScriptLink,
209
+ extraArgs = _ref4.extraArgs;
210
+ var btnTextColor = customization.btnTextColor,
211
+ showIcon = customization.showIcon,
212
+ btnText = customization.btnText,
213
+ btnPosition = customization.btnPosition,
214
+ btnColor = customization.btnColor,
215
+ icon = customization.icon,
216
+ queryParams = customization.queryParams;
217
+ return "\n import { useEffect } from \"react\";\n\n const App = () => {\n const ".concat(embedFunctionName, " = () => {\n ").concat(baseScript, "\n ").concat(embedScript(embedScriptLink), "\n ").concat(camelCasedAppName, ".embed({\n type: \"floatingPopup\",\n id: \"").concat(id, "\",\n organization: \"").concat(globalProps.organization.subdomain, "\",\n styles: {\n btnTextColor: \"").concat(btnTextColor, "\",\n btnPosition: \"").concat(btnPosition, "\",\n btnColor: \"").concat(btnColor, "\",\n btnText: \"").concat(btnText, "\",").concat(icon ? "\n".concat(TAB_STRING).concat(TAB_STRING, " showIcon: ").concat(showIcon, ",") : "", "\n },").concat(embedQueryParam(queryParams)).concat(embedEnv()).concat(parseExtraArgs(extraArgs), "\n });\n\n ").concat(cleanupFunction, "\n };\n\n useEffect(() => ").concat(embedFunctionName, "(), []);\n\n return <div />;\n };");
218
+ };
219
+ var elementPopupEmbedCode = function elementPopupEmbedCode(_ref5) {
220
+ var customization = _ref5.customization,
221
+ id = _ref5.id,
222
+ embedScriptLink = _ref5.embedScriptLink,
223
+ extraArgs = _ref5.extraArgs;
224
+ var elementSelector = customization.elementSelector,
225
+ queryParams = customization.queryParams;
226
+ return "\n import { useEffect } from \"react\";\n\n const App = () => {\n const ".concat(embedFunctionName, " = () => {\n ").concat(baseScript, "\n ").concat(embedScript(embedScriptLink), "\n ").concat(camelCasedAppName, ".embed({\n type: \"elementClick\",\n id: \"").concat(id, "\",\n organization: \"").concat(globalProps.organization.subdomain, "\",\n elementSelector: \"#").concat(elementSelector, "\",").concat(embedQueryParam(queryParams)).concat(embedEnv()).concat(parseExtraArgs(extraArgs), "\n });\n\n ").concat(cleanupFunction, "\n };\n\n useEffect(() => ").concat(embedFunctionName, "(), []);\n\n return <button id=\"").concat(elementSelector, "\">Click to open popup</button>;\n };");
227
+ };
228
+ var reactCodeGenerators = {
229
+ inline: inlineEmbedCode,
230
+ floatingPopup: floatingPopupEmbedCode,
231
+ elementPopup: elementPopupEmbedCode
232
+ };
233
+
234
+ var _excluded = ["tab", "type"];
235
+ var generateCode = function generateCode(options) {
236
+ var _reactCodeGenerators$, _htmlCodeGenerators$t;
237
+ var tab = options.tab,
238
+ type = options.type,
239
+ embeddedCodeOptions = _objectWithoutProperties(options, _excluded);
240
+ return tab === "react" ? (_reactCodeGenerators$ = reactCodeGenerators[type]) === null || _reactCodeGenerators$ === void 0 ? void 0 : _reactCodeGenerators$.call(reactCodeGenerators, embeddedCodeOptions) : (_htmlCodeGenerators$t = htmlCodeGenerators[type]) === null || _htmlCodeGenerators$t === void 0 ? void 0 : _htmlCodeGenerators$t.call(htmlCodeGenerators, embeddedCodeOptions);
241
+ };
242
+ var buildDefaultCustomization = function buildDefaultCustomization(defaultCustomizations) {
243
+ return ramda.mergeDeepLeft(defaultCustomizations, DEFAULT_CUSTOMIZATION);
244
+ };
245
+ var buildQueryParamsFromInputFields = function buildQueryParamsFromInputFields(inputFields) {
246
+ var filteredInputFields = inputFields.filter(function (_ref) {
247
+ var name = _ref.name,
248
+ value = _ref.value;
249
+ return name && value;
250
+ });
251
+ var queryParams = filteredInputFields.reduce(function (queryParams, _ref2) {
252
+ var name = _ref2.name,
253
+ value = _ref2.value;
254
+ queryParams[name] = value;
255
+ return queryParams;
256
+ }, {});
257
+ if (ramda.isEmpty(queryParams)) return "";
258
+ var queryParamJsonString = JSON.stringify(queryParams, null, 2);
259
+ return queryParamJsonString.replace(/"([^"]+)":/g, "$1: ").replace(/\n/g, " ").replace(/\s\s+/g, " ");
260
+ };
261
+
262
+ function ownKeys$1(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
263
+ function _objectSpread$1(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$1(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$1(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
264
+ var DynamicQueryParams = function DynamicQueryParams(_ref) {
265
+ var updateCustomization = _ref.updateCustomization;
266
+ var _useTranslation = reactI18next.useTranslation(),
267
+ t = _useTranslation.t;
268
+ var _useState = React.useState([INITIAL_QUERY_PARAM]),
269
+ _useState2 = _slicedToArray(_useState, 2),
270
+ queryParams = _useState2[0],
271
+ setQueryParams = _useState2[1];
272
+ var handleAddQueryParam = function handleAddQueryParam() {
273
+ setQueryParams([].concat(_toConsumableArray(queryParams), [INITIAL_QUERY_PARAM]));
274
+ };
275
+ var handleRemoveQueryParam = function handleRemoveQueryParam(index) {
276
+ var newQueryParams = queryParams.filter(function (_, i) {
277
+ return i !== index;
278
+ });
279
+ setQueryParams(newQueryParams);
280
+ };
281
+ var handleInputChange = function handleInputChange(index, field, value) {
282
+ var newQueryParams = queryParams.map(function (param, i) {
283
+ return i === index ? _objectSpread$1(_objectSpread$1({}, param), {}, _defineProperty({}, field, value)) : param;
284
+ });
285
+ setQueryParams(newQueryParams);
286
+ };
287
+ React.useEffect(function () {
288
+ updateCustomization({
289
+ queryParams: buildQueryParamsFromInputFields(queryParams)
290
+ });
291
+ }, [queryParams]);
292
+ return /*#__PURE__*/jsxRuntime.jsxs("div", {
293
+ children: [/*#__PURE__*/jsxRuntime.jsx(Label, {
294
+ className: "mb-2",
295
+ "data-cy": "dynamic-query-params-label",
296
+ children: t("neetoMolecules.productEmbed.customization.queryParam.label")
297
+ }), queryParams.map(function (param, index) {
298
+ return /*#__PURE__*/jsxRuntime.jsxs("div", {
299
+ className: "mb-1 flex gap-1",
300
+ children: [/*#__PURE__*/jsxRuntime.jsx(Input, {
301
+ "data-cy": "dynamic-query-key-name-input",
302
+ "data-testid": "dynamic-query-key-name-input",
303
+ name: "queryParams.".concat(index, ".name"),
304
+ value: param.name,
305
+ placeholder: t("neetoMolecules.productEmbed.customization.queryParam.keyNamePlaceholder"),
306
+ onChange: function onChange(e) {
307
+ return handleInputChange(index, "name", e.target.value);
308
+ }
309
+ }), /*#__PURE__*/jsxRuntime.jsx(Input, {
310
+ "data-cy": "dynamic-query-key-value-input",
311
+ "data-testid": "dynamic-query-key-value-input",
312
+ name: "queryParams.".concat(index, ".value"),
313
+ value: param.value,
314
+ placeholder: t("neetoMolecules.productEmbed.customization.queryParam.keyValuePlaceholder"),
315
+ onChange: function onChange(e) {
316
+ return handleInputChange(index, "value", e.target.value);
317
+ }
318
+ }), /*#__PURE__*/jsxRuntime.jsx(Button, {
319
+ "data-cy": "dynamic-query-delete-button",
320
+ icon: Delete,
321
+ style: "text",
322
+ onClick: function onClick() {
323
+ return handleRemoveQueryParam(index);
324
+ }
325
+ })]
326
+ }, index);
327
+ }), /*#__PURE__*/jsxRuntime.jsx(Button, {
328
+ className: "my-2",
329
+ "data-cy": "dynamic-query-add-new-button",
330
+ icon: Plus,
331
+ iconPosition: "left",
332
+ style: "link",
333
+ label: t("neetoMolecules.productEmbed.customization.queryParam.addQueryParam"),
334
+ onClick: handleAddQueryParam
335
+ })]
336
+ });
337
+ };
338
+
339
+ var ElementPopup$1 = function ElementPopup(_ref) {
340
+ var customization = _ref.customization,
341
+ updateCustomization = _ref.updateCustomization,
342
+ isQueryParamsEnabled = _ref.isQueryParamsEnabled,
343
+ otherCustomizations = _ref.otherCustomizations;
344
+ var elementSelector = customization.elementSelector;
345
+ var _useTranslation = reactI18next.useTranslation(),
346
+ t = _useTranslation.t;
347
+ React.useEffect(function () {
348
+ if (isQueryParamsEnabled) return;
349
+ updateCustomization({
350
+ queryParams: undefined
351
+ });
352
+ }, []);
353
+ return /*#__PURE__*/jsxRuntime.jsxs("div", {
354
+ className: "space-y-6",
355
+ children: [/*#__PURE__*/jsxRuntime.jsx(Typography, {
356
+ "data-cy": "element-popup-header",
357
+ style: "h4",
358
+ children: t("neetoMolecules.productEmbed.customization.elementPopup.title")
359
+ }), /*#__PURE__*/jsxRuntime.jsx(Callout, {
360
+ "data-cy": "element-popup-description",
361
+ children: t("neetoMolecules.productEmbed.customization.elementPopup.description")
362
+ }), /*#__PURE__*/jsxRuntime.jsx(Input, {
363
+ className: "w-full",
364
+ "data-cy": "element-id-input-field",
365
+ "data-testid": "element-id-input-field",
366
+ value: elementSelector,
367
+ error: !elementSelector && t("neetoMolecules.productEmbed.customization.elementPopup.warning"),
368
+ label: t("neetoMolecules.productEmbed.customization.elementPopup.elementId"),
369
+ onChange: function onChange(e) {
370
+ return updateCustomization({
371
+ elementSelector: e.target.value
372
+ });
373
+ }
374
+ }), otherCustomizations(), isQueryParamsEnabled && /*#__PURE__*/jsxRuntime.jsx(DynamicQueryParams, {
375
+ updateCustomization: updateCustomization
376
+ })]
377
+ });
378
+ };
379
+
380
+ var FloatingPopup$1 = function FloatingPopup(_ref) {
381
+ var customization = _ref.customization,
382
+ updateCustomization = _ref.updateCustomization,
383
+ isQueryParamsEnabled = _ref.isQueryParamsEnabled,
384
+ otherCustomizations = _ref.otherCustomizations;
385
+ var _useTranslation = reactI18next.useTranslation(),
386
+ t = _useTranslation.t;
387
+ var btnTextColor = customization.btnTextColor,
388
+ showIcon = customization.showIcon,
389
+ btnText = customization.btnText,
390
+ btnPosition = customization.btnPosition,
391
+ btnColor = customization.btnColor,
392
+ icon = customization.icon;
393
+ React.useEffect(function () {
394
+ if (isQueryParamsEnabled) return;
395
+ updateCustomization({
396
+ queryParams: undefined
397
+ });
398
+ }, []);
399
+ return /*#__PURE__*/jsxRuntime.jsxs("div", {
400
+ className: "space-y-6",
401
+ children: [/*#__PURE__*/jsxRuntime.jsx(Typography, {
402
+ "data-cy": "popup-customization-header",
403
+ style: "h4",
404
+ children: t("neetoMolecules.productEmbed.customization.floatingPopup.title")
405
+ }), icon && /*#__PURE__*/jsxRuntime.jsx(Checkbox, {
406
+ checked: showIcon,
407
+ "data-cy": "show-icon-checkbox",
408
+ "data-testid": "show-icon-checkbox",
409
+ label: t("neetoMolecules.productEmbed.customization.floatingPopup.showCalIcon"),
410
+ onChange: function onChange(e) {
411
+ return updateCustomization({
412
+ showIcon: e.target.checked
413
+ });
414
+ }
415
+ }), /*#__PURE__*/jsxRuntime.jsx("div", {
416
+ className: "space-y-2",
417
+ children: /*#__PURE__*/jsxRuntime.jsx(Input, {
418
+ "data-cy": "button-text-input-field",
419
+ "data-testid": "button-text-input-field",
420
+ value: btnText,
421
+ label: t("neetoMolecules.productEmbed.customization.floatingPopup.button.text"),
422
+ onChange: function onChange(e) {
423
+ return updateCustomization({
424
+ btnText: e.target.value
425
+ });
426
+ }
427
+ })
428
+ }), /*#__PURE__*/jsxRuntime.jsx("div", {
429
+ className: "space-y-2",
430
+ children: /*#__PURE__*/jsxRuntime.jsx(Select, {
431
+ "data-cy": "button-position-select-field",
432
+ "data-testid": "button-position-select-field",
433
+ options: FLOATING_BUTTON_POSITIONS,
434
+ value: btnPosition,
435
+ getOptionValue: function getOptionValue(option) {
436
+ return typeof option === "string" ? option : option.value;
437
+ },
438
+ label: t("neetoMolecules.productEmbed.customization.floatingPopup.button.pos"),
439
+ onChange: function onChange(e) {
440
+ return updateCustomization({
441
+ btnPosition: e.value
442
+ });
443
+ }
444
+ })
445
+ }), /*#__PURE__*/jsxRuntime.jsxs("div", {
446
+ className: "flex items-center justify-between gap-x-2",
447
+ "data-cy": "button-color-label",
448
+ children: [/*#__PURE__*/jsxRuntime.jsx(Label, {
449
+ children: t("neetoMolecules.productEmbed.customization.floatingPopup.button.color")
450
+ }), /*#__PURE__*/jsxRuntime.jsx(ColorPicker, {
451
+ color: btnColor,
452
+ onChange: function onChange(e) {
453
+ return updateCustomization({
454
+ btnColor: e.hex
455
+ });
456
+ }
457
+ })]
458
+ }), /*#__PURE__*/jsxRuntime.jsxs("div", {
459
+ className: "flex items-center justify-between gap-x-2",
460
+ "data-cy": "button-text-color-label",
461
+ children: [/*#__PURE__*/jsxRuntime.jsx(Label, {
462
+ children: t("neetoMolecules.productEmbed.customization.floatingPopup.button.textColor")
463
+ }), /*#__PURE__*/jsxRuntime.jsx(ColorPicker, {
464
+ color: btnTextColor,
465
+ onChange: function onChange(e) {
466
+ return updateCustomization({
467
+ btnTextColor: e.hex
468
+ });
469
+ }
470
+ })]
471
+ }), otherCustomizations(), isQueryParamsEnabled && /*#__PURE__*/jsxRuntime.jsx(DynamicQueryParams, {
472
+ updateCustomization: updateCustomization
473
+ })]
474
+ });
475
+ };
476
+
477
+ var Inline$1 = function Inline(_ref) {
478
+ var customization = _ref.customization,
479
+ updateCustomization = _ref.updateCustomization,
480
+ isQueryParamsEnabled = _ref.isQueryParamsEnabled,
481
+ otherCustomizations = _ref.otherCustomizations;
482
+ var height = customization.height,
483
+ width = customization.width,
484
+ elementSelector = customization.elementSelector;
485
+ var _useTranslation = reactI18next.useTranslation(),
486
+ t = _useTranslation.t;
487
+ var handleInputChange = function handleInputChange(_ref2, attribute) {
488
+ var value = _ref2.target.value;
489
+ return updateCustomization(_defineProperty({}, attribute, value));
490
+ };
491
+ React.useEffect(function () {
492
+ if (isQueryParamsEnabled) return;
493
+ updateCustomization({
494
+ queryParams: undefined
495
+ });
496
+ }, []);
497
+ return /*#__PURE__*/jsxRuntime.jsxs("div", {
498
+ className: "flex flex-col gap-y-6",
499
+ children: [/*#__PURE__*/jsxRuntime.jsx(Typography, {
500
+ "data-cy": "customization-text",
501
+ style: "h4",
502
+ children: t("neetoMolecules.productEmbed.customization.inline.title")
503
+ }), /*#__PURE__*/jsxRuntime.jsxs("div", {
504
+ className: "flex flex-col gap-2",
505
+ children: [/*#__PURE__*/jsxRuntime.jsx(Label, {
506
+ "data-cy": "window-size-text",
507
+ children: t("neetoMolecules.productEmbed.customization.inline.sizeOfEmbedWindow")
508
+ }), /*#__PURE__*/jsxRuntime.jsxs("div", {
509
+ className: "flex justify-between gap-x-2",
510
+ children: [/*#__PURE__*/jsxRuntime.jsx(Input, {
511
+ className: "neeto-molecules-product-embed-size-input",
512
+ "data-cy": "inline-width-input-field",
513
+ "data-testid": "inline-width-input-field",
514
+ max: 100,
515
+ min: 0,
516
+ prefix: "W",
517
+ suffix: "%",
518
+ type: "number",
519
+ value: width,
520
+ onChange: function onChange(e) {
521
+ return handleInputChange(e, "width");
522
+ }
523
+ }), /*#__PURE__*/jsxRuntime.jsx(Input, {
524
+ className: "neeto-molecules-product-embed-size-input",
525
+ "data-cy": "inline-height-input-field",
526
+ "data-testid": "inline-height-input-field",
527
+ max: 100,
528
+ min: 0,
529
+ prefix: "H",
530
+ suffix: "%",
531
+ type: "number",
532
+ value: height,
533
+ onChange: function onChange(e) {
534
+ return handleInputChange(e, "height");
535
+ }
536
+ })]
537
+ })]
538
+ }), /*#__PURE__*/jsxRuntime.jsxs("div", {
539
+ className: "flex flex-col gap-2",
540
+ children: [/*#__PURE__*/jsxRuntime.jsx(Label, {
541
+ "data-cy": "inline-element-id-input-label",
542
+ children: t("neetoMolecules.productEmbed.customization.inline.elementId")
543
+ }), /*#__PURE__*/jsxRuntime.jsx(Input, {
544
+ "data-cy": "inline-element-id-input-field",
545
+ "data-testid": "inline-element-id-input-field",
546
+ value: elementSelector,
547
+ onChange: function onChange(e) {
548
+ return handleInputChange(e, "elementSelector");
549
+ }
550
+ })]
551
+ }), otherCustomizations(), isQueryParamsEnabled && /*#__PURE__*/jsxRuntime.jsx(DynamicQueryParams, {
552
+ updateCustomization: updateCustomization
553
+ })]
554
+ });
555
+ };
556
+
557
+ var Customization = function Customization(_ref) {
558
+ var option = _ref.option,
559
+ customization = _ref.customization,
560
+ updateCustomization = _ref.updateCustomization,
561
+ isQueryParamsEnabled = _ref.isQueryParamsEnabled,
562
+ otherCustomizations = _ref.otherCustomizations;
563
+ var type = _defineProperty(_defineProperty(_defineProperty({}, EMBED_OPTIONS.INLINE, Inline$1), EMBED_OPTIONS.FLOATING_POPUP, FloatingPopup$1), EMBED_OPTIONS.ELEMENT_POPUP, ElementPopup$1);
564
+ var Component = type[option];
565
+ return /*#__PURE__*/jsxRuntime.jsx(Component, {
566
+ customization: customization,
567
+ isQueryParamsEnabled: isQueryParamsEnabled,
568
+ otherCustomizations: otherCustomizations,
569
+ updateCustomization: updateCustomization
570
+ });
571
+ };
572
+
573
+ var Header = function Header(_ref) {
574
+ var supportedLanguagesTabs = _ref.supportedLanguagesTabs,
575
+ setTab = _ref.setTab,
576
+ tab = _ref.tab;
577
+ return /*#__PURE__*/jsxRuntime.jsx("div", {
578
+ className: "flex w-full",
579
+ children: /*#__PURE__*/jsxRuntime.jsx(Tab, {
580
+ noUnderline: true,
581
+ className: "neeto-molecules-product-embed-tab",
582
+ children: supportedLanguagesTabs.map(function (_ref2) {
583
+ var key = _ref2.key,
584
+ label = _ref2.label,
585
+ icon = _ref2.icon;
586
+ return /*#__PURE__*/React.createElement(Tab.Item, {
587
+ icon: icon,
588
+ active: tab === key,
589
+ "data-cy": "".concat(key, "-tab"),
590
+ "data-testid": "".concat(key, "-tab"),
591
+ key: key,
592
+ onClick: function onClick() {
593
+ return setTab(key);
594
+ }
595
+ }, label);
596
+ })
597
+ })
598
+ });
599
+ };
600
+
601
+ var Options = function Options(_ref) {
602
+ var options = _ref.options,
603
+ selectedOption = _ref.selectedOption,
604
+ setSelectedOption = _ref.setSelectedOption;
605
+ return /*#__PURE__*/jsxRuntime.jsx(Radio, {
606
+ stacked: true,
607
+ containerClassName: "w-full flex flex-col gap-y-4",
608
+ name: "options",
609
+ children: Object.entries(options).map(function (_ref2) {
610
+ var _ref3 = _slicedToArray(_ref2, 2),
611
+ key = _ref3[0],
612
+ _ref3$ = _ref3[1],
613
+ label = _ref3$.label,
614
+ description = _ref3$.description;
615
+ return /*#__PURE__*/jsxRuntime.jsxs("label", {
616
+ className: "neeto-ui-border-gray-300 neeto-ui-bg-white neeto-ui-rounded-lg w-full cursor-pointer border p-4",
617
+ "data-cy": "".concat(key, "-embed-option-label"),
618
+ "data-testid": "".concat(key, "-embed-option-label"),
619
+ htmlFor: key,
620
+ children: [/*#__PURE__*/jsxRuntime.jsx("div", {
621
+ className: "flex items-center",
622
+ children: /*#__PURE__*/jsxRuntime.jsx(Radio.Item, {
623
+ label: label,
624
+ checked: key === selectedOption,
625
+ className: "mb-0",
626
+ "data-cy": "".concat(key, "-embed-radio-button"),
627
+ "data-testid": "".concat(key, "-embed-radio-button"),
628
+ id: key,
629
+ name: "options",
630
+ value: key,
631
+ onChange: function onChange(event) {
632
+ return setSelectedOption(event.target.value);
633
+ }
634
+ })
635
+ }), /*#__PURE__*/jsxRuntime.jsx(Typography, {
636
+ className: "w-full pl-6 pt-1",
637
+ "data-cy": "".concat(key, "-embed-option-description"),
638
+ style: "body2",
639
+ children: description
640
+ })]
641
+ }, key);
642
+ })
643
+ });
644
+ };
645
+
646
+ var ElementPopup = function ElementPopup(_ref) {
647
+ var iframeURL = _ref.iframeURL,
648
+ customization = _ref.customization;
649
+ var _useTranslation = reactI18next.useTranslation(),
650
+ t = _useTranslation.t;
651
+ var elementSelector = customization.elementSelector;
652
+ React.useEffect(function () {
653
+ var element = document.getElementById(elementSelector);
654
+ if (element) {
655
+ var _window$globalProps$a;
656
+ (_window$globalProps$a = window[globalProps.appName.replace(/^neeto/i, "neeto")]) === null || _window$globalProps$a === void 0 || _window$globalProps$a.embed(element, iframeURL);
657
+ }
658
+ }, []);
659
+ return /*#__PURE__*/jsxRuntime.jsx("div", {
660
+ className: "relative flex h-full w-full items-center justify-center p-6",
661
+ children: /*#__PURE__*/jsxRuntime.jsx(Button, {
662
+ "data-cy": "preview-element-popup-button",
663
+ "data-testid": "preview-element-popup-button",
664
+ id: elementSelector,
665
+ label: t("neetoMolecules.productEmbed.customization.elementPopup.label")
666
+ })
667
+ });
668
+ };
669
+
670
+ var FloatingPopup = function FloatingPopup(_ref) {
671
+ var iframeURL = _ref.iframeURL,
672
+ customization = _ref.customization;
673
+ var btnTextColor = customization.btnTextColor,
674
+ showIcon = customization.showIcon,
675
+ btnText = customization.btnText,
676
+ btnPosition = customization.btnPosition,
677
+ btnColor = customization.btnColor,
678
+ icon = customization.icon;
679
+ React.useEffect(function () {
680
+ var _window$globalProps$a;
681
+ var btn = document.getElementById("embedBtn");
682
+ (_window$globalProps$a = window[globalProps.appName.replace(/^neeto/i, "neeto")]) === null || _window$globalProps$a === void 0 || _window$globalProps$a.embed(btn, iframeURL);
683
+ }, []);
684
+ React.useEffect(function () {
685
+ var btn = document.getElementById("embedBtn");
686
+ btn.style.backgroundColor = btnColor;
687
+ btn.style.color = btnTextColor;
688
+ }, [btnColor, btnTextColor]);
689
+ return /*#__PURE__*/jsxRuntime.jsx("div", {
690
+ className: "relative h-full w-full",
691
+ children: /*#__PURE__*/jsxRuntime.jsx(Button, {
692
+ "data-cy": "popup-preview-button",
693
+ icon: icon && showIcon ? icon : null,
694
+ iconPosition: "left",
695
+ id: "embedBtn",
696
+ label: btnText,
697
+ className: classnames("absolute bottom-0 m-4", {
698
+ "left-0": btnPosition === "bottomLeft",
699
+ "right-0": btnPosition === "bottomRight"
700
+ })
701
+ })
702
+ });
703
+ };
704
+
705
+ var Inline = function Inline(_ref) {
706
+ var iframeURL = _ref.iframeURL,
707
+ customization = _ref.customization;
708
+ var height = customization.height,
709
+ width = customization.width;
710
+ return /*#__PURE__*/jsxRuntime.jsx("iframe", {
711
+ className: "m-auto",
712
+ height: "".concat(height, "%"),
713
+ src: iframeURL,
714
+ width: "".concat(width, "%")
715
+ });
716
+ };
717
+
718
+ var Preview = function Preview(_ref) {
719
+ var isScriptLoading = _ref.isScriptLoading,
720
+ selectedOption = _ref.selectedOption,
721
+ id = _ref.id,
722
+ customization = _ref.customization,
723
+ _ref$customPreviewIfr = _ref.customPreviewIframeUrl,
724
+ customPreviewIframeUrl = _ref$customPreviewIfr === void 0 ? "" : _ref$customPreviewIfr;
725
+ var preview = _defineProperty(_defineProperty(_defineProperty({}, EMBED_OPTIONS.INLINE, Inline), EMBED_OPTIONS.FLOATING_POPUP, FloatingPopup), EMBED_OPTIONS.ELEMENT_POPUP, ElementPopup);
726
+ var iframeURL = customPreviewIframeUrl || "".concat(location.origin, "/embed/").concat(id);
727
+ var Component = preview[selectedOption];
728
+ if (isScriptLoading) {
729
+ return /*#__PURE__*/jsxRuntime.jsx("div", {
730
+ className: "flex min-h-0 flex-grow items-center justify-center overflow-y-auto",
731
+ children: /*#__PURE__*/jsxRuntime.jsx(Spinner, {})
732
+ });
733
+ }
734
+ return /*#__PURE__*/jsxRuntime.jsx(BrowserPreview, {
735
+ className: "h-full",
736
+ wrapperClassName: "neeto-molecules-embed__browser-preview pointer-events-auto",
737
+ children: /*#__PURE__*/jsxRuntime.jsx(Component, {
738
+ customization: customization,
739
+ iframeURL: iframeURL
740
+ })
741
+ });
742
+ };
743
+
744
+ var css = ".neeto-molecules-product-embed-size-input.neeto-ui-input__wrapper .neeto-ui-input__prefix{align-self:stretch;background-color:rgb(var(--neeto-ui-gray-200));margin-left:0!important;padding-left:.75rem;padding-right:.75rem}.neeto-molecules-product-embed-tab{gap:.5rem}.neeto-molecules-product-embed-tab .neeto-ui-tab{border-radius:var(--neeto-ui-btn-border-radius);color:rgb(var(--neeto-ui-gray-800))}.neeto-molecules-product-embed-tab .neeto-ui-tab:not(.active):hover{background-color:rgb(var(--neeto-ui-gray-100))}.neeto-molecules-product-embed-tab .neeto-ui-tab.active{background-color:rgb(var(--neeto-ui-gray-200))}.neeto-molecules-embed__left-sidebar{align-items:flex-start;display:flex;flex-direction:column;flex-shrink:0;overflow-y:auto;padding:1.5rem;width:100%}@media (min-width:768px){.neeto-molecules-embed__left-sidebar{border-right:1px solid rgb(var(--neeto-ui-gray-200));max-width:25rem}}@media (min-width:1024px){.neeto-molecules-embed__left-sidebar{max-width:27.5rem}}.neeto-molecules-embed__code-block .neeto-molecules-code-block{font-size:.875rem;height:15.625rem;margin-top:0!important}.neeto-molecules-embed__browser-preview{height:100%;min-height:18.75rem}.neeto-molecules-embed__browser-preview .neeto-molecules-browser-preview__body{position:relative}.neeto-molecules-embed__browser-preview .neeto-molecules-browser-preview__body iframe{height:100%;left:0;position:absolute;top:0;width:100%}";
745
+ injectCss.n(css,{});
746
+
747
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
748
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
749
+ var ProductEmbed = function ProductEmbed(_ref) {
750
+ var _ref$className = _ref.className,
751
+ className = _ref$className === void 0 ? "" : _ref$className,
752
+ _ref$customEmbedScrip = _ref.customEmbedScriptPath,
753
+ customEmbedScriptPath = _ref$customEmbedScrip === void 0 ? "" : _ref$customEmbedScrip,
754
+ _ref$customPreviewIfr = _ref.customPreviewIframeUrl,
755
+ customPreviewIframeUrl = _ref$customPreviewIfr === void 0 ? "" : _ref$customPreviewIfr,
756
+ _ref$goBackLink = _ref.goBackLink,
757
+ goBackLink = _ref$goBackLink === void 0 ? "" : _ref$goBackLink,
758
+ id = _ref.id,
759
+ _ref$isQueryParamsEna = _ref.isQueryParamsEnabled,
760
+ isQueryParamsEnabled = _ref$isQueryParamsEna === void 0 ? false : _ref$isQueryParamsEna,
761
+ _ref$options = _ref.options,
762
+ options = _ref$options === void 0 ? {} : _ref$options,
763
+ _ref$extraArgs = _ref.extraArgs,
764
+ extraArgs = _ref$extraArgs === void 0 ? {} : _ref$extraArgs,
765
+ _ref$otherCustomizati = _ref.otherCustomizations,
766
+ otherCustomizations = _ref$otherCustomizati === void 0 ? neetoCist.noop : _ref$otherCustomizati,
767
+ _ref$inlineWrapperSty = _ref.inlineWrapperStyle,
768
+ inlineWrapperStyle = _ref$inlineWrapperSty === void 0 ? "" : _ref$inlineWrapperSty,
769
+ _ref$supportedLanguag = _ref.supportedLanguages,
770
+ supportedLanguages = _ref$supportedLanguag === void 0 ? ["html"] : _ref$supportedLanguag;
771
+ var supportedLanguagesTabs = neetoCist.filterBy({
772
+ key: function key(_key) {
773
+ return supportedLanguages === null || supportedLanguages === void 0 ? void 0 : supportedLanguages.includes(_key);
774
+ }
775
+ }, TABS);
776
+ var _useState = React.useState(true),
777
+ _useState2 = _slicedToArray(_useState, 2),
778
+ isScriptLoading = _useState2[0],
779
+ setIsScriptLoading = _useState2[1];
780
+ var _useState3 = React.useState(supportedLanguagesTabs[0].key),
781
+ _useState4 = _slicedToArray(_useState3, 2),
782
+ tab = _useState4[0],
783
+ setTab = _useState4[1];
784
+ var _useState5 = React.useState(EMBED_OPTIONS.INLINE),
785
+ _useState6 = _slicedToArray(_useState5, 2),
786
+ selectedOption = _useState6[0],
787
+ setSelectedOption = _useState6[1];
788
+ var _useState7 = React.useState(function () {
789
+ return buildDefaultCustomization(options);
790
+ }),
791
+ _useState8 = _slicedToArray(_useState7, 2),
792
+ customizations = _useState8[0],
793
+ setCustomizations = _useState8[1];
794
+ var _useTranslation = reactI18next.useTranslation(),
795
+ t = _useTranslation.t;
796
+ var embedScriptLink = customEmbedScriptPath || "".concat(window.location.protocol, "//").concat(window.location.host, "/javascript/embed.js");
797
+ var code = generateCode({
798
+ id: id,
799
+ tab: tab,
800
+ type: selectedOption,
801
+ customization: customizations[selectedOption],
802
+ embedScriptLink: embedScriptLink,
803
+ extraArgs: extraArgs,
804
+ inlineWrapperStyle: inlineWrapperStyle
805
+ });
806
+ var loadScript = function loadScript() {
807
+ var script = document.createElement("script");
808
+ script.id = SCRIPT_ID;
809
+ script.src = embedScriptLink;
810
+ document.head.appendChild(script);
811
+ setIsScriptLoading(false);
812
+ };
813
+ var updateCustomization = function updateCustomization(props) {
814
+ return setCustomizations(function (prevState) {
815
+ return _objectSpread(_objectSpread({}, prevState), {}, _defineProperty({}, selectedOption, ramda.mergeLeft(props, prevState[selectedOption])));
816
+ });
817
+ };
818
+ React.useEffect(function () {
819
+ var isScriptLoaded = document.getElementById(SCRIPT_ID);
820
+ if (isScriptLoaded) setIsScriptLoading(false);else loadScript();
821
+ }, []);
822
+ return /*#__PURE__*/jsxRuntime.jsxs("div", {
823
+ "data-testid": "embed-product",
824
+ className: classnames("neeto-molecules-embed flex w-full flex-grow flex-col md:flex-row", className),
825
+ children: [/*#__PURE__*/jsxRuntime.jsxs("div", {
826
+ className: "neeto-molecules-embed__left-sidebar",
827
+ children: [goBackLink && /*#__PURE__*/jsxRuntime.jsx(Button, {
828
+ className: "mb-4",
829
+ "data-cy": "back-button",
830
+ "data-testid": "back-button",
831
+ icon: LeftArrow,
832
+ iconPosition: "left",
833
+ label: t("neetoMolecules.productEmbed.backToShare"),
834
+ size: "small",
835
+ style: "link",
836
+ to: goBackLink
837
+ }), /*#__PURE__*/jsxRuntime.jsx(Typography, {
838
+ "data-cy": "embed-options-header-title",
839
+ style: "h3",
840
+ children: t("neetoMolecules.productEmbed.embedOptions.title")
841
+ }), /*#__PURE__*/jsxRuntime.jsxs("div", {
842
+ className: "mt-6 flex w-full flex-col gap-y-6 md:pb-20",
843
+ children: [/*#__PURE__*/jsxRuntime.jsx(Options, {
844
+ options: options,
845
+ selectedOption: selectedOption,
846
+ setSelectedOption: setSelectedOption
847
+ }), /*#__PURE__*/jsxRuntime.jsx(Customization, {
848
+ isQueryParamsEnabled: isQueryParamsEnabled,
849
+ otherCustomizations: otherCustomizations,
850
+ updateCustomization: updateCustomization,
851
+ customization: customizations[selectedOption],
852
+ option: selectedOption
853
+ })]
854
+ })]
855
+ }), /*#__PURE__*/jsxRuntime.jsxs("div", {
856
+ className: "neeto-molecules-embed__preview neeto-ui-bg-white flex min-h-screen w-full min-w-0 flex-col gap-3 overflow-y-auto p-6 md:min-h-0 md:flex-grow",
857
+ children: [/*#__PURE__*/jsxRuntime.jsx(Header, {
858
+ setTab: setTab,
859
+ supportedLanguagesTabs: supportedLanguagesTabs,
860
+ tab: tab
861
+ }), /*#__PURE__*/jsxRuntime.jsxs("div", {
862
+ className: "flex min-h-0 flex-grow flex-col gap-3",
863
+ children: [/*#__PURE__*/jsxRuntime.jsx("div", {
864
+ className: "flex-shrink-0",
865
+ "data-testid": "embed-code-block",
866
+ children: /*#__PURE__*/jsxRuntime.jsx(Code, {
867
+ code: code,
868
+ tab: tab
869
+ })
870
+ }), /*#__PURE__*/jsxRuntime.jsx("div", {
871
+ className: "flex-grow",
872
+ children: /*#__PURE__*/jsxRuntime.jsx(Preview, {
873
+ customPreviewIframeUrl: customPreviewIframeUrl,
874
+ id: id,
875
+ isScriptLoading: isScriptLoading,
876
+ selectedOption: selectedOption,
877
+ customization: customizations[selectedOption]
878
+ })
879
+ })]
880
+ })]
881
+ })]
882
+ });
883
+ };
884
+
885
+ module.exports = ProductEmbed;
886
+ //# sourceMappingURL=ProductEmbed.js.map