@bigbinary/neeto-molecules 3.15.42 → 3.15.43

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/package.json +1 -1
  2. package/dist/AuditLogs.js +0 -539
  3. package/dist/AuditLogs.js.map +0 -1
  4. package/dist/BoardView.js +0 -394
  5. package/dist/BoardView.js.map +0 -1
  6. package/dist/Breadcrumbs.js +0 -46
  7. package/dist/Breadcrumbs.js.map +0 -1
  8. package/dist/BrowserPreview.js +0 -50
  9. package/dist/BrowserPreview.js.map +0 -1
  10. package/dist/BrowserSupport.js +0 -348
  11. package/dist/BrowserSupport.js.map +0 -1
  12. package/dist/Builder.js +0 -786
  13. package/dist/Builder.js.map +0 -1
  14. package/dist/ButtonGroup.js +0 -36
  15. package/dist/ButtonGroup.js.map +0 -1
  16. package/dist/CalendarView.js +0 -353
  17. package/dist/CalendarView.js.map +0 -1
  18. package/dist/CardLayout.js +0 -49
  19. package/dist/CardLayout.js.map +0 -1
  20. package/dist/Chevron-6dLkaXtR.js +0 -246
  21. package/dist/Chevron-6dLkaXtR.js.map +0 -1
  22. package/dist/Codeblock.js +0 -58
  23. package/dist/Codeblock.js.map +0 -1
  24. package/dist/Columns.js +0 -21
  25. package/dist/Columns.js.map +0 -1
  26. package/dist/ConfigurePageSidebar.js +0 -97
  27. package/dist/ConfigurePageSidebar.js.map +0 -1
  28. package/dist/ConfirmationModal.js +0 -110
  29. package/dist/ConfirmationModal.js.map +0 -1
  30. package/dist/Container.js +0 -38
  31. package/dist/Container.js.map +0 -1
  32. package/dist/CopyToClipboardButton.js +0 -82
  33. package/dist/CopyToClipboardButton.js.map +0 -1
  34. package/dist/Currency.js +0 -917
  35. package/dist/Currency.js.map +0 -1
  36. package/dist/DateFormat.js +0 -45
  37. package/dist/DateFormat.js.map +0 -1
  38. package/dist/DateRangeFilter.js +0 -178
  39. package/dist/DateRangeFilter.js.map +0 -1
  40. package/dist/DeleteArchiveModal.js +0 -98
  41. package/dist/DeleteArchiveModal.js.map +0 -1
  42. package/dist/DeviceIncompatibilityMessage.js +0 -95
  43. package/dist/DeviceIncompatibilityMessage.js.map +0 -1
  44. package/dist/DocumentEditor.js +0 -183
  45. package/dist/DocumentEditor.js.map +0 -1
  46. package/dist/DownloadMobileAppCallout.js +0 -40
  47. package/dist/DownloadMobileAppCallout.js.map +0 -1
  48. package/dist/DynamicVariables.js +0 -115
  49. package/dist/DynamicVariables.js.map +0 -1
  50. package/dist/EmailForm.js +0 -567
  51. package/dist/EmailForm.js.map +0 -1
  52. package/dist/EmailPreview.js +0 -140
  53. package/dist/EmailPreview.js.map +0 -1
  54. package/dist/EmojiPicker.js +0 -112
  55. package/dist/EmojiPicker.js.map +0 -1
  56. package/dist/EmojiReactions.js +0 -82
  57. package/dist/EmojiReactions.js.map +0 -1
  58. package/dist/Engagements.js +0 -292
  59. package/dist/Engagements.js.map +0 -1
  60. package/dist/ErrorPage.js +0 -1811
  61. package/dist/ErrorPage.js.map +0 -1
  62. package/dist/FileUpload.js +0 -595
  63. package/dist/FileUpload.js.map +0 -1
  64. package/dist/FinderModal.js +0 -280
  65. package/dist/FinderModal.js.map +0 -1
  66. package/dist/FloatingActionMenu.js +0 -854
  67. package/dist/FloatingActionMenu.js.map +0 -1
  68. package/dist/GoogleFontPicker.js +0 -581
  69. package/dist/GoogleFontPicker.js.map +0 -1
  70. package/dist/Header.js +0 -126
  71. package/dist/Header.js.map +0 -1
  72. package/dist/HelpPopover.js +0 -83
  73. package/dist/HelpPopover.js.map +0 -1
  74. package/dist/IconPicker.js +0 -1159
  75. package/dist/IconPicker.js.map +0 -1
  76. package/dist/ImageWithFallback.js +0 -49
  77. package/dist/ImageWithFallback.js.map +0 -1
  78. package/dist/InlineInput.js +0 -230
  79. package/dist/InlineInput.js.map +0 -1
  80. package/dist/Insights.js +0 -358
  81. package/dist/Insights.js.map +0 -1
  82. package/dist/IntegrationCard.js +0 -227
  83. package/dist/IntegrationCard.js.map +0 -1
  84. package/dist/IpRestriction.js +0 -3617
  85. package/dist/IpRestriction.js.map +0 -1
  86. package/dist/KeyboardShortcuts.js +0 -284
  87. package/dist/KeyboardShortcuts.js.map +0 -1
  88. package/dist/LoginPage.js +0 -184
  89. package/dist/LoginPage.js.map +0 -1
  90. package/dist/MadeWith.js +0 -41
  91. package/dist/MadeWith.js.map +0 -1
  92. package/dist/MenuBar.js +0 -1326
  93. package/dist/MenuBar.js.map +0 -1
  94. package/dist/Metadata.js +0 -218
  95. package/dist/Metadata.js.map +0 -1
  96. package/dist/MobilePreviewHeader.js +0 -25
  97. package/dist/MobilePreviewHeader.js.map +0 -1
  98. package/dist/MoreDropdown.js +0 -163
  99. package/dist/MoreDropdown.js.map +0 -1
  100. package/dist/NavigationHeader.js +0 -264
  101. package/dist/NavigationHeader.js.map +0 -1
  102. package/dist/NeetoWidget.js +0 -2867
  103. package/dist/NeetoWidget.js.map +0 -1
  104. package/dist/Onboarding.js +0 -246
  105. package/dist/Onboarding.js.map +0 -1
  106. package/dist/OptionFields.js +0 -717
  107. package/dist/OptionFields.js.map +0 -1
  108. package/dist/PageLoader.js +0 -40
  109. package/dist/PageLoader.js.map +0 -1
  110. package/dist/PhoneNumber.js +0 -75
  111. package/dist/PhoneNumber.js.map +0 -1
  112. package/dist/ProductEmbed.js +0 -884
  113. package/dist/ProductEmbed.js.map +0 -1
  114. package/dist/PublishBlock.js +0 -447
  115. package/dist/PublishBlock.js.map +0 -1
  116. package/dist/PublishYourItem.js +0 -58
  117. package/dist/PublishYourItem.js.map +0 -1
  118. package/dist/Rename.js +0 -366
  119. package/dist/Rename.js.map +0 -1
  120. package/dist/ResponsiveDevicePicker.js +0 -63
  121. package/dist/ResponsiveDevicePicker.js.map +0 -1
  122. package/dist/Schedule.js +0 -926
  123. package/dist/Schedule.js.map +0 -1
  124. package/dist/Scrollable.js +0 -42
  125. package/dist/Scrollable.js.map +0 -1
  126. package/dist/Search.js +0 -110
  127. package/dist/Search.js.map +0 -1
  128. package/dist/SendToFields.js +0 -2221
  129. package/dist/SendToFields.js.map +0 -1
  130. package/dist/SessionEnvironment.js +0 -431
  131. package/dist/SessionEnvironment.js.map +0 -1
  132. package/dist/Settings.js +0 -250
  133. package/dist/Settings.js.map +0 -1
  134. package/dist/ShareRecordingPane.js +0 -216
  135. package/dist/ShareRecordingPane.js.map +0 -1
  136. package/dist/ShareViaEmail.js +0 -416
  137. package/dist/ShareViaEmail.js.map +0 -1
  138. package/dist/ShareViaLink.js +0 -1556
  139. package/dist/ShareViaLink.js.map +0 -1
  140. package/dist/Sidebar.js +0 -294
  141. package/dist/Sidebar.js.map +0 -1
  142. package/dist/StatusDropdown.js +0 -109
  143. package/dist/StatusDropdown.js.map +0 -1
  144. package/dist/StickyRibbonsContainer.js +0 -131
  145. package/dist/StickyRibbonsContainer.js.map +0 -1
  146. package/dist/SubHeader.js +0 -209
  147. package/dist/SubHeader.js.map +0 -1
  148. package/dist/SubscriptionNotificationsContainer.js +0 -77
  149. package/dist/SubscriptionNotificationsContainer.js.map +0 -1
  150. package/dist/SuffixedInput.js +0 -111
  151. package/dist/SuffixedInput.js.map +0 -1
  152. package/dist/TableWrapper.js +0 -27
  153. package/dist/TableWrapper.js.map +0 -1
  154. package/dist/Taxonomy.js +0 -496
  155. package/dist/Taxonomy.js.map +0 -1
  156. package/dist/TimeFormat.js +0 -14
  157. package/dist/TimeFormat.js.map +0 -1
  158. package/dist/TimezoneMismatchModal.js +0 -138
  159. package/dist/TimezoneMismatchModal.js.map +0 -1
  160. package/dist/ToggleFeatureCard.js +0 -211
  161. package/dist/ToggleFeatureCard.js.map +0 -1
  162. package/dist/_commonjsHelpers-BFTU3MAI.js +0 -8
  163. package/dist/_commonjsHelpers-BFTU3MAI.js.map +0 -1
  164. package/dist/cjs/AuditLogs.js +0 -541
  165. package/dist/cjs/AuditLogs.js.map +0 -1
  166. package/dist/cjs/BoardView.js +0 -396
  167. package/dist/cjs/BoardView.js.map +0 -1
  168. package/dist/cjs/Breadcrumbs.js +0 -48
  169. package/dist/cjs/Breadcrumbs.js.map +0 -1
  170. package/dist/cjs/BrowserPreview.js +0 -52
  171. package/dist/cjs/BrowserPreview.js.map +0 -1
  172. package/dist/cjs/BrowserSupport.js +0 -350
  173. package/dist/cjs/BrowserSupport.js.map +0 -1
  174. package/dist/cjs/Builder.js +0 -794
  175. package/dist/cjs/Builder.js.map +0 -1
  176. package/dist/cjs/ButtonGroup.js +0 -38
  177. package/dist/cjs/ButtonGroup.js.map +0 -1
  178. package/dist/cjs/CalendarView.js +0 -355
  179. package/dist/cjs/CalendarView.js.map +0 -1
  180. package/dist/cjs/CardLayout.js +0 -51
  181. package/dist/cjs/CardLayout.js.map +0 -1
  182. package/dist/cjs/Chevron-wfVdaB4-.js +0 -256
  183. package/dist/cjs/Chevron-wfVdaB4-.js.map +0 -1
  184. package/dist/cjs/Codeblock.js +0 -60
  185. package/dist/cjs/Codeblock.js.map +0 -1
  186. package/dist/cjs/Columns.js +0 -35
  187. package/dist/cjs/Columns.js.map +0 -1
  188. package/dist/cjs/ConfigurePageSidebar.js +0 -99
  189. package/dist/cjs/ConfigurePageSidebar.js.map +0 -1
  190. package/dist/cjs/ConfirmationModal.js +0 -131
  191. package/dist/cjs/ConfirmationModal.js.map +0 -1
  192. package/dist/cjs/Container.js +0 -40
  193. package/dist/cjs/Container.js.map +0 -1
  194. package/dist/cjs/CopyToClipboardButton.js +0 -84
  195. package/dist/cjs/CopyToClipboardButton.js.map +0 -1
  196. package/dist/cjs/Currency.js +0 -920
  197. package/dist/cjs/Currency.js.map +0 -1
  198. package/dist/cjs/DateFormat.js +0 -47
  199. package/dist/cjs/DateFormat.js.map +0 -1
  200. package/dist/cjs/DateRangeFilter.js +0 -180
  201. package/dist/cjs/DateRangeFilter.js.map +0 -1
  202. package/dist/cjs/DeleteArchiveModal.js +0 -100
  203. package/dist/cjs/DeleteArchiveModal.js.map +0 -1
  204. package/dist/cjs/DeviceIncompatibilityMessage.js +0 -115
  205. package/dist/cjs/DeviceIncompatibilityMessage.js.map +0 -1
  206. package/dist/cjs/DocumentEditor.js +0 -185
  207. package/dist/cjs/DocumentEditor.js.map +0 -1
  208. package/dist/cjs/DownloadMobileAppCallout.js +0 -42
  209. package/dist/cjs/DownloadMobileAppCallout.js.map +0 -1
  210. package/dist/cjs/DynamicVariables.js +0 -117
  211. package/dist/cjs/DynamicVariables.js.map +0 -1
  212. package/dist/cjs/EmailForm.js +0 -593
  213. package/dist/cjs/EmailForm.js.map +0 -1
  214. package/dist/cjs/EmailPreview.js +0 -142
  215. package/dist/cjs/EmailPreview.js.map +0 -1
  216. package/dist/cjs/EmojiPicker.js +0 -114
  217. package/dist/cjs/EmojiPicker.js.map +0 -1
  218. package/dist/cjs/EmojiReactions.js +0 -84
  219. package/dist/cjs/EmojiReactions.js.map +0 -1
  220. package/dist/cjs/Engagements.js +0 -294
  221. package/dist/cjs/Engagements.js.map +0 -1
  222. package/dist/cjs/ErrorPage.js +0 -1831
  223. package/dist/cjs/ErrorPage.js.map +0 -1
  224. package/dist/cjs/FileUpload.js +0 -598
  225. package/dist/cjs/FileUpload.js.map +0 -1
  226. package/dist/cjs/FinderModal.js +0 -282
  227. package/dist/cjs/FinderModal.js.map +0 -1
  228. package/dist/cjs/FloatingActionMenu.js +0 -875
  229. package/dist/cjs/FloatingActionMenu.js.map +0 -1
  230. package/dist/cjs/GoogleFontPicker.js +0 -583
  231. package/dist/cjs/GoogleFontPicker.js.map +0 -1
  232. package/dist/cjs/Header.js +0 -128
  233. package/dist/cjs/Header.js.map +0 -1
  234. package/dist/cjs/HelpPopover.js +0 -85
  235. package/dist/cjs/HelpPopover.js.map +0 -1
  236. package/dist/cjs/IconPicker.js +0 -1161
  237. package/dist/cjs/IconPicker.js.map +0 -1
  238. package/dist/cjs/ImageWithFallback.js +0 -51
  239. package/dist/cjs/ImageWithFallback.js.map +0 -1
  240. package/dist/cjs/InlineInput.js +0 -233
  241. package/dist/cjs/InlineInput.js.map +0 -1
  242. package/dist/cjs/Insights.js +0 -360
  243. package/dist/cjs/Insights.js.map +0 -1
  244. package/dist/cjs/IntegrationCard.js +0 -229
  245. package/dist/cjs/IntegrationCard.js.map +0 -1
  246. package/dist/cjs/IpRestriction.js +0 -3638
  247. package/dist/cjs/IpRestriction.js.map +0 -1
  248. package/dist/cjs/KeyboardShortcuts.js +0 -286
  249. package/dist/cjs/KeyboardShortcuts.js.map +0 -1
  250. package/dist/cjs/LoginPage.js +0 -205
  251. package/dist/cjs/LoginPage.js.map +0 -1
  252. package/dist/cjs/MadeWith.js +0 -43
  253. package/dist/cjs/MadeWith.js.map +0 -1
  254. package/dist/cjs/MenuBar.js +0 -1328
  255. package/dist/cjs/MenuBar.js.map +0 -1
  256. package/dist/cjs/Metadata.js +0 -220
  257. package/dist/cjs/Metadata.js.map +0 -1
  258. package/dist/cjs/MobilePreviewHeader.js +0 -27
  259. package/dist/cjs/MobilePreviewHeader.js.map +0 -1
  260. package/dist/cjs/MoreDropdown.js +0 -165
  261. package/dist/cjs/MoreDropdown.js.map +0 -1
  262. package/dist/cjs/NavigationHeader.js +0 -266
  263. package/dist/cjs/NavigationHeader.js.map +0 -1
  264. package/dist/cjs/NeetoWidget.js +0 -2888
  265. package/dist/cjs/NeetoWidget.js.map +0 -1
  266. package/dist/cjs/Onboarding.js +0 -248
  267. package/dist/cjs/Onboarding.js.map +0 -1
  268. package/dist/cjs/OptionFields.js +0 -719
  269. package/dist/cjs/OptionFields.js.map +0 -1
  270. package/dist/cjs/PageLoader.js +0 -42
  271. package/dist/cjs/PageLoader.js.map +0 -1
  272. package/dist/cjs/PhoneNumber.js +0 -80
  273. package/dist/cjs/PhoneNumber.js.map +0 -1
  274. package/dist/cjs/ProductEmbed.js +0 -886
  275. package/dist/cjs/ProductEmbed.js.map +0 -1
  276. package/dist/cjs/PublishBlock.js +0 -449
  277. package/dist/cjs/PublishBlock.js.map +0 -1
  278. package/dist/cjs/PublishYourItem.js +0 -60
  279. package/dist/cjs/PublishYourItem.js.map +0 -1
  280. package/dist/cjs/Rename.js +0 -368
  281. package/dist/cjs/Rename.js.map +0 -1
  282. package/dist/cjs/ResponsiveDevicePicker.js +0 -65
  283. package/dist/cjs/ResponsiveDevicePicker.js.map +0 -1
  284. package/dist/cjs/Schedule.js +0 -947
  285. package/dist/cjs/Schedule.js.map +0 -1
  286. package/dist/cjs/Scrollable.js +0 -44
  287. package/dist/cjs/Scrollable.js.map +0 -1
  288. package/dist/cjs/Search.js +0 -112
  289. package/dist/cjs/Search.js.map +0 -1
  290. package/dist/cjs/SendToFields.js +0 -2223
  291. package/dist/cjs/SendToFields.js.map +0 -1
  292. package/dist/cjs/SessionEnvironment.js +0 -433
  293. package/dist/cjs/SessionEnvironment.js.map +0 -1
  294. package/dist/cjs/Settings.js +0 -252
  295. package/dist/cjs/Settings.js.map +0 -1
  296. package/dist/cjs/ShareRecordingPane.js +0 -218
  297. package/dist/cjs/ShareRecordingPane.js.map +0 -1
  298. package/dist/cjs/ShareViaEmail.js +0 -437
  299. package/dist/cjs/ShareViaEmail.js.map +0 -1
  300. package/dist/cjs/ShareViaLink.js +0 -1577
  301. package/dist/cjs/ShareViaLink.js.map +0 -1
  302. package/dist/cjs/Sidebar.js +0 -315
  303. package/dist/cjs/Sidebar.js.map +0 -1
  304. package/dist/cjs/StatusDropdown.js +0 -111
  305. package/dist/cjs/StatusDropdown.js.map +0 -1
  306. package/dist/cjs/StickyRibbonsContainer.js +0 -133
  307. package/dist/cjs/StickyRibbonsContainer.js.map +0 -1
  308. package/dist/cjs/SubHeader.js +0 -211
  309. package/dist/cjs/SubHeader.js.map +0 -1
  310. package/dist/cjs/SubscriptionNotificationsContainer.js +0 -79
  311. package/dist/cjs/SubscriptionNotificationsContainer.js.map +0 -1
  312. package/dist/cjs/SuffixedInput.js +0 -113
  313. package/dist/cjs/SuffixedInput.js.map +0 -1
  314. package/dist/cjs/TableWrapper.js +0 -29
  315. package/dist/cjs/TableWrapper.js.map +0 -1
  316. package/dist/cjs/Taxonomy.js +0 -517
  317. package/dist/cjs/Taxonomy.js.map +0 -1
  318. package/dist/cjs/TimeFormat.js +0 -16
  319. package/dist/cjs/TimeFormat.js.map +0 -1
  320. package/dist/cjs/TimezoneMismatchModal.js +0 -140
  321. package/dist/cjs/TimezoneMismatchModal.js.map +0 -1
  322. package/dist/cjs/ToggleFeatureCard.js +0 -213
  323. package/dist/cjs/ToggleFeatureCard.js.map +0 -1
  324. package/dist/cjs/_commonjsHelpers-BJu3ubxk.js +0 -11
  325. package/dist/cjs/_commonjsHelpers-BJu3ubxk.js.map +0 -1
  326. package/dist/cjs/index-JY2zVpnv.js +0 -1189
  327. package/dist/cjs/index-JY2zVpnv.js.map +0 -1
  328. package/dist/cjs/inject-css-vQvjPR2x.js +0 -6
  329. package/dist/cjs/inject-css-vQvjPR2x.js.map +0 -1
  330. package/dist/cjs/phone-number-BN-c0rfv.js +0 -320
  331. package/dist/cjs/phone-number-BN-c0rfv.js.map +0 -1
  332. package/dist/cjs/platform-BUcCb8Jx.js +0 -1254
  333. package/dist/cjs/platform-BUcCb8Jx.js.map +0 -1
  334. package/dist/cjs/useColumns-BP8c4PV-.js +0 -282
  335. package/dist/cjs/useColumns-BP8c4PV-.js.map +0 -1
  336. package/dist/index-DAYCJu79.js +0 -1187
  337. package/dist/index-DAYCJu79.js.map +0 -1
  338. package/dist/inject-css-DmrvuTKK.js +0 -4
  339. package/dist/inject-css-DmrvuTKK.js.map +0 -1
  340. package/dist/phone-number-CXCBroLh.js +0 -295
  341. package/dist/phone-number-CXCBroLh.js.map +0 -1
  342. package/dist/platform-F44zJ4Xh.js +0 -1252
  343. package/dist/platform-F44zJ4Xh.js.map +0 -1
  344. package/dist/styles/page-loader.css +0 -1
  345. package/dist/styles/page-loader.js +0 -3
  346. package/dist/useColumns-Db5uic1-.js +0 -274
  347. package/dist/useColumns-Db5uic1-.js.map +0 -1
  348. package/types/AuditLogs.d.ts +0 -22
  349. package/types/BoardView.d.ts +0 -149
  350. package/types/Breadcrumbs.d.ts +0 -30
  351. package/types/BrowserPreview.d.ts +0 -30
  352. package/types/BrowserSupport.d.ts +0 -110
  353. package/types/Builder.d.ts +0 -99
  354. package/types/ButtonGroup.d.ts +0 -45
  355. package/types/CalendarView.d.ts +0 -98
  356. package/types/CardLayout.d.ts +0 -34
  357. package/types/Codeblock.d.ts +0 -37
  358. package/types/Columns.d.ts +0 -168
  359. package/types/ConfigurePageSidebar.d.ts +0 -45
  360. package/types/ConfirmationModal.d.ts +0 -65
  361. package/types/Container.d.ts +0 -38
  362. package/types/CopyToClipboardButton.d.ts +0 -28
  363. package/types/Currency.d.ts +0 -50
  364. package/types/DateFormat.d.ts +0 -15
  365. package/types/DateRangeFilter.d.ts +0 -56
  366. package/types/DeleteArchiveModal.d.ts +0 -65
  367. package/types/DeviceIncompatibilityMessage.d.ts +0 -19
  368. package/types/DocumentEditor.d.ts +0 -61
  369. package/types/DownloadMobileAppCallout.d.ts +0 -35
  370. package/types/DynamicVariables.d.ts +0 -48
  371. package/types/EmailForm.d.ts +0 -165
  372. package/types/EmailFormProvider.d.ts +0 -48
  373. package/types/EmailPreview.d.ts +0 -43
  374. package/types/EmojiPicker.d.ts +0 -35
  375. package/types/EmojiReactions.d.ts +0 -62
  376. package/types/Engagements.d.ts +0 -131
  377. package/types/ErrorPage.d.ts +0 -22
  378. package/types/FileUpload.d.ts +0 -89
  379. package/types/FinderModal.d.ts +0 -66
  380. package/types/FloatingActionMenu.d.ts +0 -59
  381. package/types/GoogleFontPicker.d.ts +0 -68
  382. package/types/Header.d.ts +0 -37
  383. package/types/HelpPopover.d.ts +0 -45
  384. package/types/IconPicker.d.ts +0 -45
  385. package/types/ImageWithFallback.d.ts +0 -24
  386. package/types/InlineInput.d.ts +0 -87
  387. package/types/Insights.d.ts +0 -112
  388. package/types/IntegrationCard.d.ts +0 -60
  389. package/types/IpRestriction.d.ts +0 -25
  390. package/types/KeyboardShortcuts.d.ts +0 -149
  391. package/types/LoginPage.d.ts +0 -45
  392. package/types/MadeWith.d.ts +0 -18
  393. package/types/MenuBar.d.ts +0 -127
  394. package/types/Metadata.d.ts +0 -109
  395. package/types/MobilePreviewHeader.d.ts +0 -19
  396. package/types/MoreDropdown.d.ts +0 -52
  397. package/types/NavigationHeader.d.ts +0 -180
  398. package/types/NeetoWidget.d.ts +0 -43
  399. package/types/Onboarding.d.ts +0 -70
  400. package/types/OptionFields.d.ts +0 -70
  401. package/types/PageLoader.d.ts +0 -40
  402. package/types/PhoneNumber.d.ts +0 -112
  403. package/types/ProductEmbed.d.ts +0 -93
  404. package/types/PublishBlock.d.ts +0 -148
  405. package/types/Rename.d.ts +0 -73
  406. package/types/ResponsiveDevicePicker.d.ts +0 -32
  407. package/types/Schedule.d.ts +0 -146
  408. package/types/Scrollable.d.ts +0 -30
  409. package/types/Search.d.ts +0 -22
  410. package/types/SendToFields.d.ts +0 -67
  411. package/types/SessionEnvironment.d.ts +0 -170
  412. package/types/Settings.d.ts +0 -108
  413. package/types/ShareRecordingPane.d.ts +0 -85
  414. package/types/ShareViaEmail.d.ts +0 -99
  415. package/types/ShareViaLink.d.ts +0 -183
  416. package/types/Sidebar.d.ts +0 -51
  417. package/types/StatusDropdown.d.ts +0 -74
  418. package/types/StickyRibbonsContainer.d.ts +0 -28
  419. package/types/SubHeader.d.ts +0 -105
  420. package/types/SubscriptionNotificationsContainer.d.ts +0 -26
  421. package/types/SuffixedInput.d.ts +0 -45
  422. package/types/TableWrapper.d.ts +0 -40
  423. package/types/Taxonomy.d.ts +0 -59
  424. package/types/TimeFormat.d.ts +0 -13
  425. package/types/TimezoneMismatchModal.d.ts +0 -41
  426. package/types/ToggleFeatureCard.d.ts +0 -38
@@ -1,886 +0,0 @@
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