crmbonus-component-wake 2.1.41-ngrok → 2.1.41-shoulder

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 (303) hide show
  1. package/LICENSE +21 -21
  2. package/dist/cjs/app-modal.cjs.entry.js +2 -2
  3. package/dist/cjs/app-modal.cjs.entry.js.map +1 -1
  4. package/dist/cjs/bc-crmbonus.cjs.entry.js +28 -0
  5. package/dist/cjs/bc-crmbonus.cjs.entry.js.map +1 -0
  6. package/dist/cjs/bc-phone-form_2.cjs.entry.js +333 -0
  7. package/dist/cjs/bc-phone-form_2.cjs.entry.js.map +1 -0
  8. package/dist/cjs/bc-wake-crmbonus.cjs.entry.js +18 -0
  9. package/dist/cjs/bc-wake-crmbonus.cjs.entry.js.map +1 -0
  10. package/dist/cjs/cart.helper-d1f02660.js +201 -0
  11. package/dist/cjs/cart.helper-d1f02660.js.map +1 -0
  12. package/dist/cjs/container-empty.cjs.entry.js +2 -2
  13. package/dist/cjs/container-empty.cjs.entry.js.map +1 -1
  14. package/dist/cjs/countdown-timer-v2.cjs.entry.js +2 -2
  15. package/dist/cjs/countdown-timer-v2.cjs.entry.js.map +1 -1
  16. package/dist/cjs/countdown-timer_11.cjs.entry.js +55 -43
  17. package/dist/cjs/countdown-timer_11.cjs.entry.js.map +1 -1
  18. package/dist/cjs/crm-bonus-note.cjs.entry.js +14 -12
  19. package/dist/cjs/crm-bonus-note.cjs.entry.js.map +1 -1
  20. package/dist/cjs/crmbonus-component-wake.cjs.js +2 -2
  21. package/dist/{components/p-0d09c221.js → cjs/crmbonus.service-ef8fe456.js} +30 -117
  22. package/dist/cjs/crmbonus.service-ef8fe456.js.map +1 -0
  23. package/dist/{esm/info.config.helper-e4b8c478.js → cjs/i18n-defaa4f8.js} +3 -30
  24. package/dist/cjs/i18n-defaa4f8.js.map +1 -0
  25. package/dist/cjs/{index-a7537457.js → index-e45b352e.js} +17 -1
  26. package/dist/cjs/index-e45b352e.js.map +1 -0
  27. package/dist/cjs/info.config.helper-52984ab9.js +36 -0
  28. package/dist/cjs/info.config.helper-52984ab9.js.map +1 -0
  29. package/dist/cjs/loader.cjs.js +2 -2
  30. package/dist/cjs/pedido-finalizado.cjs.entry.js +6 -5
  31. package/dist/cjs/pedido-finalizado.cjs.entry.js.map +1 -1
  32. package/dist/cjs/utils-5d59acb1.js.map +1 -1
  33. package/dist/collection/assets/svg/money-dollars-svgrepo-com.svg +5 -5
  34. package/dist/collection/collection-manifest.json +5 -1
  35. package/dist/collection/components/button/crm-button.css +21 -21
  36. package/dist/collection/components/button/index.js +1 -1
  37. package/dist/collection/components/button/index.js.map +1 -1
  38. package/dist/collection/components/countdown-timer/countdown-timer.js +1 -1
  39. package/dist/collection/components/countdown-timer/countdown-timer.js.map +1 -1
  40. package/dist/collection/components/countdown-timer/countdown-timer.v2.js +2 -2
  41. package/dist/collection/components/countdown-timer/countdown-timer.v2.js.map +1 -1
  42. package/dist/collection/components/crm-bonus/assets/logo.svg +17 -17
  43. package/dist/collection/components/crm-bonus/assets/svg/logo.svg +17 -17
  44. package/dist/collection/components/crm-bonus/crm-bonus.css +86 -82
  45. package/dist/collection/components/crm-bonus/crm-bonus.js +16 -7
  46. package/dist/collection/components/crm-bonus/crm-bonus.js.map +1 -1
  47. package/dist/collection/components/crmbonus/crmbonus.js +26 -0
  48. package/dist/collection/components/crmbonus/crmbonus.js.map +1 -0
  49. package/dist/collection/components/crmbonus/subcomponents/phone-form/index.js +95 -0
  50. package/dist/collection/components/crmbonus/subcomponents/phone-form/index.js.map +1 -0
  51. package/dist/collection/components/crmbonus/subcomponents/phone-form/styles.scss +5 -0
  52. package/dist/collection/components/crmbonus/subcomponents/phone-validate/index.js +129 -0
  53. package/dist/collection/components/crmbonus/subcomponents/phone-validate/index.js.map +1 -0
  54. package/dist/collection/components/crmbonus/subcomponents/phone-validate/styles.scss +84 -0
  55. package/dist/collection/components/giftback-form/giftback-form.css +74 -74
  56. package/dist/collection/components/giftback-form/giftback-form.js +5 -5
  57. package/dist/collection/components/giftback-form/giftback-form.js.map +1 -1
  58. package/dist/collection/components/giftback-form/subcomponents/giftback-info/giftback-info.css +181 -181
  59. package/dist/collection/components/giftback-form/subcomponents/giftback-info/giftback-info.js +6 -6
  60. package/dist/collection/components/giftback-form/subcomponents/giftback-info/giftback-info.js.map +1 -1
  61. package/dist/collection/components/giftback-form/subcomponents/giftback-message/giftback-massage.js.map +1 -1
  62. package/dist/collection/components/giftback-form/subcomponents/phone-form/phone-form.js +1 -1
  63. package/dist/collection/components/giftback-form/subcomponents/phone-form/phone-form.js.map +1 -1
  64. package/dist/collection/components/giftback-form/subcomponents/pin-form/pin-form.css +83 -83
  65. package/dist/collection/components/giftback-form/subcomponents/pin-form/pin-form.js +1 -1
  66. package/dist/collection/components/giftback-form/subcomponents/pin-form/pin-form.js.map +1 -1
  67. package/dist/collection/components/loading-container/container-empty.js +1 -1
  68. package/dist/collection/components/loading-container/container-empty.js.map +1 -1
  69. package/dist/collection/components/loading-container/loading-container.css +53 -53
  70. package/dist/collection/components/loading-container/loading-container.js +1 -1
  71. package/dist/collection/components/loading-container/loading-container.js.map +1 -1
  72. package/dist/collection/components/loading-spinner/loading-spinner.css +16 -16
  73. package/dist/collection/components/loading-spinner/loading-spinner.js +1 -1
  74. package/dist/collection/components/loading-spinner/loading-spinner.js.map +1 -1
  75. package/dist/collection/components/modal/app-modal.css +44 -44
  76. package/dist/collection/components/modal/app-modal.js +1 -1
  77. package/dist/collection/components/modal/app-modal.js.map +1 -1
  78. package/dist/collection/components/note/crm-bonus-note.css +68 -68
  79. package/dist/collection/components/note/crm-bonus-note.js +2 -2
  80. package/dist/collection/components/note/crm-bonus-note.js.map +1 -1
  81. package/dist/collection/components/pedido/pedido.js +2 -2
  82. package/dist/collection/components/pedido/pedido.js.map +1 -1
  83. package/dist/collection/components/phone/phone-input-mask.css +40 -40
  84. package/dist/collection/components/phone/phone-input-mask.js +1 -1
  85. package/dist/collection/components/phone/phone-input-mask.js.map +1 -1
  86. package/dist/collection/components/tooltip/crm-tooltip.css +48 -48
  87. package/dist/collection/components/tooltip/tooltip.js +1 -1
  88. package/dist/collection/components/tooltip/tooltip.js.map +1 -1
  89. package/dist/collection/contants/index.js.map +1 -1
  90. package/dist/collection/contants/mocks.js.map +1 -1
  91. package/dist/collection/dto/checkout.dto.js +2 -0
  92. package/dist/collection/dto/checkout.dto.js.map +1 -0
  93. package/dist/collection/dto/pin.sent.js.map +1 -1
  94. package/dist/collection/dto/reserved-info.dto.js.map +1 -1
  95. package/dist/collection/dto/update.order.dto.js.map +1 -1
  96. package/dist/collection/dto/validate.pin.bonus.js.map +1 -1
  97. package/dist/collection/helpers/build.payload.helper.js +1 -0
  98. package/dist/collection/helpers/build.payload.helper.js.map +1 -1
  99. package/dist/collection/helpers/cart.helper.js +55 -1
  100. package/dist/collection/helpers/cart.helper.js.map +1 -1
  101. package/dist/collection/helpers/info.config.helper.js.map +1 -1
  102. package/dist/collection/helpers/payload.interface.js.map +1 -1
  103. package/dist/collection/helpers/time.helper.js.map +1 -1
  104. package/dist/collection/i18n/i18n.js.map +1 -1
  105. package/dist/collection/index.js.map +1 -1
  106. package/dist/collection/objectvalues/cart.wake.js +33 -8
  107. package/dist/collection/objectvalues/cart.wake.js.map +1 -1
  108. package/dist/collection/platforms/wake/index.js +8 -0
  109. package/dist/collection/platforms/wake/index.js.map +1 -0
  110. package/dist/collection/services/crmbonus.service.js +21 -2
  111. package/dist/collection/services/crmbonus.service.js.map +1 -1
  112. package/dist/collection/utils/keys.storage.js.map +1 -1
  113. package/dist/collection/utils/retry.utils.js.map +1 -1
  114. package/dist/collection/utils/utils.js.map +1 -1
  115. package/dist/components/app-modal.js +2 -2
  116. package/dist/components/app-modal.js.map +1 -1
  117. package/dist/components/bc-crmbonus.d.ts +11 -0
  118. package/dist/components/bc-crmbonus.js +8 -0
  119. package/dist/components/bc-crmbonus.js.map +1 -0
  120. package/dist/components/bc-phone-form.d.ts +11 -0
  121. package/dist/components/bc-phone-form.js +8 -0
  122. package/dist/components/bc-phone-form.js.map +1 -0
  123. package/dist/components/bc-phone-validate-pin-form.d.ts +11 -0
  124. package/dist/components/bc-phone-validate-pin-form.js +8 -0
  125. package/dist/components/bc-phone-validate-pin-form.js.map +1 -0
  126. package/dist/components/bc-wake-crmbonus.d.ts +11 -0
  127. package/dist/components/bc-wake-crmbonus.js +74 -0
  128. package/dist/components/bc-wake-crmbonus.js.map +1 -0
  129. package/dist/components/container-empty.js +2 -2
  130. package/dist/components/container-empty.js.map +1 -1
  131. package/dist/components/countdown-timer-v2.js +2 -2
  132. package/dist/components/countdown-timer-v2.js.map +1 -1
  133. package/dist/components/countdown-timer.js +1 -1
  134. package/dist/components/crm-bonus-note.js +8 -7
  135. package/dist/components/crm-bonus-note.js.map +1 -1
  136. package/dist/components/crm-bonus.js +30 -19
  137. package/dist/components/crm-bonus.js.map +1 -1
  138. package/dist/components/crm-button.js +1 -1
  139. package/dist/components/crm-giftback-form.js +1 -1
  140. package/dist/components/crm-tooltip.js +1 -1
  141. package/dist/components/giftback-info.js +1 -1
  142. package/dist/components/index.js +1 -1
  143. package/dist/components/loading-container.js +1 -1
  144. package/dist/components/loading-spinner.js +1 -1
  145. package/dist/components/p-06d73541.js +80 -0
  146. package/dist/components/p-06d73541.js.map +1 -0
  147. package/dist/components/p-09f86f1d.js +106 -0
  148. package/dist/components/p-09f86f1d.js.map +1 -0
  149. package/dist/components/p-1b441909.js.map +1 -1
  150. package/dist/components/p-2362455d.js +195 -0
  151. package/dist/components/p-2362455d.js.map +1 -0
  152. package/dist/components/p-2fac7f5e.js +78 -0
  153. package/dist/components/p-2fac7f5e.js.map +1 -0
  154. package/dist/components/{p-786485b2.js → p-39bd2459.js} +3 -3
  155. package/dist/components/p-39bd2459.js.map +1 -0
  156. package/dist/components/{p-144c34f6.js → p-496bc4af.js} +17 -16
  157. package/dist/components/p-496bc4af.js.map +1 -0
  158. package/dist/{esm/cart.helper-8c8d4a0a.js → components/p-60787be2.js} +25 -117
  159. package/dist/components/p-60787be2.js.map +1 -0
  160. package/dist/components/{p-0a7ccd8c.js → p-6aa17c2b.js} +6 -6
  161. package/dist/components/p-6aa17c2b.js.map +1 -0
  162. package/dist/components/{p-c250687d.js → p-80a69118.js} +4 -4
  163. package/dist/components/p-80a69118.js.map +1 -0
  164. package/dist/components/p-81e4e697.js +1298 -0
  165. package/dist/components/p-81e4e697.js.map +1 -0
  166. package/dist/components/{p-2cece106.js → p-8f45d088.js} +3 -3
  167. package/dist/components/p-8f45d088.js.map +1 -0
  168. package/dist/components/{p-9b5c07d8.js → p-9231dc5e.js} +4 -4
  169. package/dist/components/p-9231dc5e.js.map +1 -0
  170. package/dist/components/{p-3c8ae82e.js → p-ade5e41e.js} +11 -10
  171. package/dist/components/p-ade5e41e.js.map +1 -0
  172. package/dist/components/p-af3ba015.js.map +1 -1
  173. package/dist/components/{p-e6863cf5.js → p-bf1d624e.js} +6 -6
  174. package/dist/components/p-bf1d624e.js.map +1 -0
  175. package/dist/components/{p-8274e2c4.js → p-c1522ad8.js} +3 -3
  176. package/dist/components/p-c1522ad8.js.map +1 -0
  177. package/dist/components/p-c53241bf.js.map +1 -1
  178. package/dist/components/{p-11520f0f.js → p-eabf185c.js} +3 -3
  179. package/dist/components/p-eabf185c.js.map +1 -0
  180. package/dist/components/p-ecc51430.js.map +1 -1
  181. package/dist/components/{p-9d950d25.js → p-f58c9cb2.js} +2 -2
  182. package/dist/components/p-f58c9cb2.js.map +1 -0
  183. package/dist/components/pedido-finalizado.js +5 -4
  184. package/dist/components/pedido-finalizado.js.map +1 -1
  185. package/dist/components/phone-form.js +1 -1
  186. package/dist/components/phone-input-mask.js +1 -1
  187. package/dist/components/pin-form.js +1 -1
  188. package/dist/crmbonus-component-wake/assets/logo.svg +17 -17
  189. package/dist/crmbonus-component-wake/crmbonus-component-wake.esm.js +1 -1
  190. package/dist/crmbonus-component-wake/crmbonus-component-wake.esm.js.map +1 -1
  191. package/dist/crmbonus-component-wake/{p-ac027576.entry.js → p-06d494c4.entry.js} +2 -2
  192. package/dist/crmbonus-component-wake/p-06d494c4.entry.js.map +1 -0
  193. package/dist/crmbonus-component-wake/{p-8c362346.js → p-19848de4.js} +2 -2
  194. package/dist/crmbonus-component-wake/p-19848de4.js.map +1 -0
  195. package/dist/crmbonus-component-wake/p-20d0467e.js +2 -0
  196. package/dist/crmbonus-component-wake/p-20d0467e.js.map +1 -0
  197. package/dist/crmbonus-component-wake/p-2362455d.js +2 -0
  198. package/dist/crmbonus-component-wake/p-2362455d.js.map +1 -0
  199. package/dist/crmbonus-component-wake/p-2dd97532.entry.js +2 -0
  200. package/dist/crmbonus-component-wake/p-2dd97532.entry.js.map +1 -0
  201. package/dist/crmbonus-component-wake/p-3e02757c.entry.js +2 -0
  202. package/dist/crmbonus-component-wake/p-3e02757c.entry.js.map +1 -0
  203. package/dist/crmbonus-component-wake/p-4cbebe64.entry.js +2 -0
  204. package/dist/crmbonus-component-wake/p-4cbebe64.entry.js.map +1 -0
  205. package/dist/crmbonus-component-wake/{p-0d09c221.js → p-60787be2.js} +2 -2
  206. package/dist/crmbonus-component-wake/p-60787be2.js.map +1 -0
  207. package/dist/crmbonus-component-wake/p-6e7c09cd.entry.js +2 -0
  208. package/dist/crmbonus-component-wake/p-6e7c09cd.entry.js.map +1 -0
  209. package/dist/crmbonus-component-wake/p-9b556ee6.entry.js +2 -0
  210. package/dist/crmbonus-component-wake/p-9b556ee6.entry.js.map +1 -0
  211. package/dist/crmbonus-component-wake/p-af3ba015.js.map +1 -1
  212. package/dist/crmbonus-component-wake/p-b435da9a.entry.js +2 -0
  213. package/dist/crmbonus-component-wake/p-b435da9a.entry.js.map +1 -0
  214. package/dist/crmbonus-component-wake/p-c53241bf.js +2 -0
  215. package/dist/crmbonus-component-wake/p-c53241bf.js.map +1 -0
  216. package/dist/crmbonus-component-wake/p-c533ea8b.entry.js +2 -0
  217. package/dist/crmbonus-component-wake/p-c533ea8b.entry.js.map +1 -0
  218. package/dist/crmbonus-component-wake/p-c7d03986.entry.js +2 -0
  219. package/dist/crmbonus-component-wake/p-c7d03986.entry.js.map +1 -0
  220. package/dist/env.js +2 -2
  221. package/dist/env.js.map +1 -1
  222. package/dist/esm/app-modal.entry.js +2 -2
  223. package/dist/esm/app-modal.entry.js.map +1 -1
  224. package/dist/esm/bc-crmbonus.entry.js +24 -0
  225. package/dist/esm/bc-crmbonus.entry.js.map +1 -0
  226. package/dist/esm/bc-phone-form_2.entry.js +328 -0
  227. package/dist/esm/bc-phone-form_2.entry.js.map +1 -0
  228. package/dist/esm/bc-wake-crmbonus.entry.js +14 -0
  229. package/dist/esm/bc-wake-crmbonus.entry.js.map +1 -0
  230. package/dist/esm/cart.helper-22ecdec9.js +195 -0
  231. package/dist/esm/cart.helper-22ecdec9.js.map +1 -0
  232. package/dist/esm/container-empty.entry.js +2 -2
  233. package/dist/esm/container-empty.entry.js.map +1 -1
  234. package/dist/esm/countdown-timer-v2.entry.js +2 -2
  235. package/dist/esm/countdown-timer-v2.entry.js.map +1 -1
  236. package/dist/esm/countdown-timer_11.entry.js +41 -29
  237. package/dist/esm/countdown-timer_11.entry.js.map +1 -1
  238. package/dist/esm/crm-bonus-note.entry.js +9 -7
  239. package/dist/esm/crm-bonus-note.entry.js.map +1 -1
  240. package/dist/esm/crmbonus-component-wake.js +3 -3
  241. package/dist/{cjs/cart.helper-31ba8997.js → esm/crmbonus.service-d83e6bb6.js} +25 -125
  242. package/dist/esm/crmbonus.service-d83e6bb6.js.map +1 -0
  243. package/dist/{cjs/info.config.helper-d4b1291b.js → esm/i18n-b9d8b0cc.js} +2 -36
  244. package/dist/esm/i18n-b9d8b0cc.js.map +1 -0
  245. package/dist/esm/{index-bdb70d5a.js → index-09314622.js} +16 -2
  246. package/dist/esm/index-09314622.js.map +1 -0
  247. package/dist/esm/info.config.helper-156cb9b2.js +32 -0
  248. package/dist/esm/info.config.helper-156cb9b2.js.map +1 -0
  249. package/dist/esm/loader.js +3 -3
  250. package/dist/esm/pedido-finalizado.entry.js +5 -4
  251. package/dist/esm/pedido-finalizado.entry.js.map +1 -1
  252. package/dist/esm/utils-dec6df66.js.map +1 -1
  253. package/dist/store.js +25 -0
  254. package/dist/store.js.map +1 -0
  255. package/dist/types/components/crmbonus/crmbonus.d.ts +9 -0
  256. package/dist/types/components/crmbonus/subcomponents/phone-form/index.d.ts +13 -0
  257. package/dist/types/components/crmbonus/subcomponents/phone-validate/index.d.ts +17 -0
  258. package/dist/types/components.d.ts +76 -0
  259. package/dist/types/dto/checkout.dto.d.ts +8 -0
  260. package/dist/types/dto/pin.sent.d.ts +3 -0
  261. package/dist/types/dto/validate.pin.bonus.d.ts +9 -0
  262. package/dist/types/helpers/cart.helper.d.ts +1 -0
  263. package/dist/types/home/darlison/Projects/Bycoders/crmbonus/crmbonus-component/.stencil/env.d.ts +2 -0
  264. package/dist/types/home/darlison/Projects/Bycoders/crmbonus/crmbonus-component/.stencil/store.d.ts +11 -0
  265. package/dist/types/objectvalues/cart.wake.d.ts +2 -1
  266. package/dist/types/platforms/wake/index.d.ts +3 -0
  267. package/dist/types/services/crmbonus.service.d.ts +4 -2
  268. package/package.json +59 -58
  269. package/readme.md +114 -114
  270. package/dist/cjs/cart.helper-31ba8997.js.map +0 -1
  271. package/dist/cjs/index-a7537457.js.map +0 -1
  272. package/dist/cjs/info.config.helper-d4b1291b.js.map +0 -1
  273. package/dist/components/p-0a7ccd8c.js.map +0 -1
  274. package/dist/components/p-0d09c221.js.map +0 -1
  275. package/dist/components/p-11520f0f.js.map +0 -1
  276. package/dist/components/p-144c34f6.js.map +0 -1
  277. package/dist/components/p-2cece106.js.map +0 -1
  278. package/dist/components/p-3c8ae82e.js.map +0 -1
  279. package/dist/components/p-786485b2.js.map +0 -1
  280. package/dist/components/p-8274e2c4.js.map +0 -1
  281. package/dist/components/p-9b5c07d8.js.map +0 -1
  282. package/dist/components/p-9d950d25.js.map +0 -1
  283. package/dist/components/p-c250687d.js.map +0 -1
  284. package/dist/components/p-e6863cf5.js.map +0 -1
  285. package/dist/crmbonus-component-wake/p-0d09c221.js.map +0 -1
  286. package/dist/crmbonus-component-wake/p-1644deef.entry.js +0 -2
  287. package/dist/crmbonus-component-wake/p-1644deef.entry.js.map +0 -1
  288. package/dist/crmbonus-component-wake/p-60742512.entry.js +0 -2
  289. package/dist/crmbonus-component-wake/p-60742512.entry.js.map +0 -1
  290. package/dist/crmbonus-component-wake/p-7e52727e.entry.js +0 -2
  291. package/dist/crmbonus-component-wake/p-7e52727e.entry.js.map +0 -1
  292. package/dist/crmbonus-component-wake/p-8c362346.js.map +0 -1
  293. package/dist/crmbonus-component-wake/p-ac027576.entry.js.map +0 -1
  294. package/dist/crmbonus-component-wake/p-ac1e7c32.entry.js +0 -2
  295. package/dist/crmbonus-component-wake/p-ac1e7c32.entry.js.map +0 -1
  296. package/dist/crmbonus-component-wake/p-b4f52f79.js +0 -2
  297. package/dist/crmbonus-component-wake/p-b4f52f79.js.map +0 -1
  298. package/dist/crmbonus-component-wake/p-df80d1b0.entry.js +0 -2
  299. package/dist/crmbonus-component-wake/p-df80d1b0.entry.js.map +0 -1
  300. package/dist/esm/cart.helper-8c8d4a0a.js.map +0 -1
  301. package/dist/esm/index-bdb70d5a.js.map +0 -1
  302. package/dist/esm/info.config.helper-e4b8c478.js.map +0 -1
  303. package/dist/types/Users/Darlison/Projects/Bycoders/crmbonus/crmbonus-component/.stencil/env.d.ts +0 -2
@@ -2,9 +2,11 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- const index = require('./index-a7537457.js');
6
- const cart_helper = require('./cart.helper-31ba8997.js');
7
- const info_config_helper = require('./info.config.helper-d4b1291b.js');
5
+ const index = require('./index-e45b352e.js');
6
+ const crmbonus_service = require('./crmbonus.service-ef8fe456.js');
7
+ const info_config_helper = require('./info.config.helper-52984ab9.js');
8
+ const i18n = require('./i18n-defaa4f8.js');
9
+ const cart_helper = require('./cart.helper-d1f02660.js');
8
10
  const utils = require('./utils-5d59acb1.js');
9
11
 
10
12
  const CountdownTimer = class {
@@ -51,7 +53,7 @@ const CountdownTimer = class {
51
53
  const minutos = Math.floor(this.tempoRestante / 60000);
52
54
  const segundos = Math.floor((this.tempoRestante % 60000) / 1000);
53
55
  const tempoFormatado = `${String(minutos).padStart(2, '0')}:${String(segundos).padStart(2, '0')}`;
54
- return (index.h("label", { key: 'ed1e0654cba5b152adcadb10cf9dfd6909c07a1f' }, " ", tempoFormatado));
56
+ return (index.h("label", { key: '18d5e1487a5c1986858f319f6169d9ea6f8db925' }, " ", tempoFormatado));
55
57
  }
56
58
  };
57
59
 
@@ -64,6 +66,7 @@ var AjustesTipoEnum;
64
66
  })(AjustesTipoEnum || (AjustesTipoEnum = {}));
65
67
 
66
68
  function buildProductsByWake(productsWake = []) {
69
+ console.log('productsWake', productsWake);
67
70
  const products = [];
68
71
  for (const pw of productsWake) {
69
72
  // let discounts_formula = getDiscountFormula(pw.Ajustes);
@@ -106,13 +109,13 @@ function getDiscount(ajustes = [], hasOriginalPrice) {
106
109
  return discounts;
107
110
  }
108
111
 
109
- const crmBonusCss = ".container-button{cursor:pointer;padding:5px 5px 5px 14px;}.section-crm{border:1px solid #dbd4d4;text-align:-webkit-center;margin-bottom:20px}.section-cart-crm{margin-top:10px}.section-cart-crm p{padding:0;margin:0px 0px 0px 15px}.button{top:50%;background-color:#6c6c7e;color:#fff;border:none;padding:15px;min-height:30px;min-width:120px;cursor:pointer;margin-left:10px;height:70px}.form-container{width:97%;display:flex;justify-content:space-around}.btn{display:inline-block;padding:6px 12px;margin-bottom:0;font-weight:400;line-height:1.42857143;text-align:center;white-space:nowrap;vertical-align:middle;-ms-touch-action:manipulation;touch-action:manipulation;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;background-image:none;border:1px solid transparent;border-radius:0px}.form-container .btnCrm{background:#00162e;border-color:#00162e;width:30%;color:#fff}.message-alert{color:#df4d4d;margin-top:5px}";
112
+ const crmBonusCss = ".container-button{cursor:pointer;padding:5px 5px 5px 14px;}.section-crm{border:1px solid #dbd4d4;text-align:-webkit-center;margin-bottom:20px}.section-cart-crm{margin-top:10px}.section-cart-crm p{padding:0;margin:0px 0px 0px 15px}.button{top:50%;background-color:#6c6c7e;color:#fff;border:none;padding:15px;min-height:30px;min-width:120px;cursor:pointer;margin-left:10px;height:70px}.form-container{width:97%;display:flex;justify-content:space-around}.btn{display:inline-block;padding:6px 12px;margin-bottom:0;font-weight:400;line-height:1.42857143;text-align:center;white-space:nowrap;vertical-align:middle;-ms-touch-action:manipulation;touch-action:manipulation;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;background-image:none;border:1px solid transparent;border-radius:0px}.form-container .btnCrm{background:#00162e;border-color:#00162e;width:30%;color:#fff}.message-alert{color:#df4d4d;margin-top:5px}.empty-container{min-height:150px}";
110
113
  const CrmBonusStyle0 = crmBonusCss;
111
114
 
112
115
  const CrmBonus$1 = class {
113
116
  constructor(hostRef) {
114
117
  index.registerInstance(this, hostRef);
115
- this.crmBonusService = cart_helper.CrmBonusService.getInstance();
118
+ this.crmBonusService = crmbonus_service.CrmBonusService.getInstance();
116
119
  this.cart = undefined;
117
120
  this.canhidden = false;
118
121
  this.showModal = false;
@@ -156,10 +159,10 @@ const CrmBonus$1 = class {
156
159
  console.log("[CRMBONUS] - reprocess");
157
160
  this.loading_reprocess = true;
158
161
  try {
159
- const isUse = localStorage.getItem(cart_helper.USED_KEY);
162
+ const isUse = localStorage.getItem(crmbonus_service.USED_KEY);
160
163
  if (!isUse)
161
164
  return;
162
- this.cartWake = await cart_helper.getCart();
165
+ this.cartWake = await cart_helper.getCartStoreFront();
163
166
  await this.resetBonus();
164
167
  }
165
168
  catch (err) {
@@ -193,7 +196,7 @@ const CrmBonus$1 = class {
193
196
  }, 2000);
194
197
  });
195
198
  await this.observerHandle();
196
- info_config_helper.instance.changeLanguage(info_config_helper.instance.language);
199
+ i18n.instance.changeLanguage(i18n.instance.language);
197
200
  }
198
201
  async componentDidLoad() {
199
202
  try {
@@ -211,16 +214,23 @@ const CrmBonus$1 = class {
211
214
  async observerHandle() {
212
215
  const elements = document.getElementsByTagName('a');
213
216
  document.addEventListener('click', (event) => {
217
+ var _a, _b, _c;
214
218
  //@ts-ignore
215
219
  console.log('Clique detectado em:', event.target.href);
220
+ //@ts-ignore
221
+ console.log('Clique detectado em:', event.target.id);
216
222
  console.log('Clique detectado em:', event.target);
217
223
  //@ts-ignore
218
- if (['validarCupom'].includes(event.target.id)) {
224
+ if (['validarCupom', 'removerCupomCarrinho'].includes(event.target.id)) {
219
225
  setTimeout(async () => {
220
226
  await this.reprocess();
221
227
  this.observerHandle();
222
228
  }, 2000);
223
229
  }
230
+ //@ts-ignore
231
+ if (['crm_label'].includes(event.target.id)) {
232
+ this.crmBonusService.saveTracking((_a = this.cartWake) === null || _a === void 0 ? void 0 : _a.id, { action: 'click_label', storeName: (_c = (_b = this.cartWake) === null || _b === void 0 ? void 0 : _b.store) === null || _c === void 0 ? void 0 : _c.name });
233
+ }
224
234
  });
225
235
  //@ts-ignore
226
236
  for (let el of elements) {
@@ -285,8 +295,8 @@ const CrmBonus$1 = class {
285
295
  }
286
296
  }
287
297
  async loadSession() {
288
- this.cartWake = this.cart ? new cart_helper.CartWake(JSON.parse(this.cart)) : await cart_helper.getCart();
289
- console.log('[bc:carregou carrinho]');
298
+ this.cartWake = this.cart ? cart_helper.CartWake.fromCheckout(JSON.parse(this.cart)) : await cart_helper.getCartStoreFront();
299
+ console.log('[bc:carregou carrinho]', this.cartWake);
290
300
  this.session = await this.crmBonusService.getToken(this.cartWake.store.name);
291
301
  console.log('[bc:carregou session]');
292
302
  setTimeout(() => {
@@ -347,7 +357,8 @@ const CrmBonus$1 = class {
347
357
  }
348
358
  }
349
359
  buildProducts() {
350
- return buildProductsByWake(this.cartWake.products);
360
+ var _a;
361
+ return buildProductsByWake(((_a = this.cartWake) === null || _a === void 0 ? void 0 : _a.products) || []);
351
362
  }
352
363
  handleCloseModal() {
353
364
  this.showModal = false;
@@ -388,10 +399,11 @@ const CrmBonus$1 = class {
388
399
  this.showModal = true;
389
400
  }
390
401
  render() {
402
+ var _a, _b;
391
403
  if (this.canhidden) {
392
404
  return null;
393
405
  }
394
- return (index.h("loading-container", { loading: this.loading_reprocess, text: 'carregando...' }, !this.loading_reprocess && (index.h("crm-giftback-form", { customStyles: this.styles, style: { position: "relative" }, ref: ref => this.crmBonusRef = ref, storeName: this.cartWake.store.name, products: this.buildProducts(), cartId: this.cartWake.id, customer: this.customer, loadProducts: () => this.buildProducts(), loadAll: () => this.handleLoad(), reservedInfo: this.reservedInfo }))));
406
+ return (index.h("loading-container", { loading: this.loading_reprocess, text: 'carregando...' }, this.loading_reprocess && index.h("div", { class: "empty-container" }), !this.loading_reprocess && this.cartWake && (index.h("crm-giftback-form", { customStyles: this.styles, style: { position: "relative" }, ref: ref => this.crmBonusRef = ref, storeName: (_b = (_a = this.cartWake) === null || _a === void 0 ? void 0 : _a.store) === null || _b === void 0 ? void 0 : _b.name, products: this.buildProducts(), cartId: this.cartWake.id, customer: this.customer, loadProducts: () => this.buildProducts(), loadAll: () => this.handleLoad(), reservedInfo: this.reservedInfo }))));
395
407
  }
396
408
  static get assetsDirs() { return ["assets"]; }
397
409
  };
@@ -408,7 +420,7 @@ const Button = class {
408
420
  this.handleClick = undefined;
409
421
  }
410
422
  render() {
411
- return (index.h("div", { key: '785b4975fb6538dbe2cdb7b99d5801abc72c534a', class: "crm-contaner-button" }, index.h("button", { key: '1e41951aa024e9f3b9b1836e8386bd369d022f76', class: "crm-button", onClick: () => this.handleClick() }, !this.loading ? this.txtBtn : index.h("loading-spinner", { size: "15px", color: "#fff" }))));
423
+ return (index.h("div", { key: '848df9f754a114343163eae85d34a2acb6b04863', class: "crm-contaner-button" }, index.h("button", { key: '517b761b39ced2615dd04fc42d5aaa98a7d749f6', class: "crm-button", onClick: () => this.handleClick() }, !this.loading ? this.txtBtn : index.h("loading-spinner", { size: "15px", color: "#fff" }))));
412
424
  }
413
425
  };
414
426
  Button.style = CrmButtonStyle0;
@@ -420,7 +432,7 @@ const CrmBonus = class {
420
432
  constructor(hostRef) {
421
433
  index.registerInstance(this, hostRef);
422
434
  // private phoneInputMask: HTMLPhoneFormElement;
423
- this.crmBonusService = cart_helper.CrmBonusService.getInstance();
435
+ this.crmBonusService = crmbonus_service.CrmBonusService.getInstance();
424
436
  this.storeName = undefined;
425
437
  this.cartId = undefined;
426
438
  this.products = undefined;
@@ -451,7 +463,7 @@ const CrmBonus = class {
451
463
  if (hasNewProduct) {
452
464
  this.products = products;
453
465
  }
454
- const _bonus = localStorage.getItem(cart_helper.getKeyReserveByCartId(this.cartId));
466
+ const _bonus = localStorage.getItem(crmbonus_service.getKeyReserveByCartId(this.cartId));
455
467
  console.log('[_bonus]', _bonus);
456
468
  if (_bonus) {
457
469
  const bonus = JSON.parse(_bonus);
@@ -489,7 +501,7 @@ const CrmBonus = class {
489
501
  await this.processBonus();
490
502
  }
491
503
  getPhoneNumberAgain() {
492
- const consulta_bonus = localStorage.getItem(cart_helper.getKeyReserveByCartId(this.cartId));
504
+ const consulta_bonus = localStorage.getItem(crmbonus_service.getKeyReserveByCartId(this.cartId));
493
505
  if (!consulta_bonus)
494
506
  return true;
495
507
  const bonus = JSON.parse(consulta_bonus);
@@ -541,7 +553,7 @@ const CrmBonus = class {
541
553
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
542
554
  this.loadingAllComponent = true;
543
555
  await this.loadProducts();
544
- const used_or_no = localStorage.getItem(cart_helper.USED_KEY);
556
+ const used_or_no = localStorage.getItem(crmbonus_service.USED_KEY);
545
557
  if (used_or_no == "dontUse") {
546
558
  this.step = info_config_helper.StepFormEnum.STEP_RESERVE;
547
559
  return;
@@ -565,15 +577,15 @@ const CrmBonus = class {
565
577
  try {
566
578
  this.bonus = await this.crmBonusService.validatePinBonus(payload);
567
579
  if (!this.bonus.hasBonus) {
568
- localStorage.setItem(cart_helper.getKeyReserveByCartId(this.cartId), JSON.stringify(Object.assign(Object.assign({}, this.bonus), { phone: this.phone })));
580
+ localStorage.setItem(crmbonus_service.getKeyReserveByCartId(this.cartId), JSON.stringify(Object.assign(Object.assign({}, this.bonus), { phone: this.phone })));
569
581
  this.loading = false;
570
582
  this.step = info_config_helper.StepFormEnum.STEP_NO_BONUS;
571
583
  return;
572
584
  }
573
585
  this.sucess = "Código validado com sucesso!";
574
- localStorage.setItem(cart_helper.getKeyReserveByCartId(this.cartId), JSON.stringify(Object.assign(Object.assign({}, this.bonus), { phone: this.phone })));
586
+ localStorage.setItem(crmbonus_service.getKeyReserveByCartId(this.cartId), JSON.stringify(Object.assign(Object.assign({}, this.bonus), { phone: this.phone })));
575
587
  localStorage.setItem(`bc:${this.phone}`, JSON.stringify(this.bonus));
576
- localStorage.setItem(cart_helper.USED_KEY, "use");
588
+ localStorage.setItem(crmbonus_service.USED_KEY, "use");
577
589
  localStorage.setItem(this.cartId, this.bonus.bonusBalance.toString());
578
590
  this.updateMetadata({ storeId: Number(storeId), userId: Number(userId) }, payload.cellphone);
579
591
  console.log('RESERVE', this.bonus);
@@ -633,7 +645,7 @@ const CrmBonus = class {
633
645
  this.loading = true;
634
646
  try {
635
647
  await this.crmBonusService.cancel(this.cartId);
636
- localStorage.setItem(cart_helper.USED_KEY, "dontUse");
648
+ localStorage.setItem(crmbonus_service.USED_KEY, "dontUse");
637
649
  // this.save(0)
638
650
  await this.updateMetadata({ storeId: null, userId: null }, null);
639
651
  }
@@ -675,18 +687,18 @@ const CrmBonus = class {
675
687
  });
676
688
  }
677
689
  render() {
678
- return (index.h("div", { key: 'a637c864ea60213cb587e7cb45e22a81480a9808', class: "crm-container-form fbits-responsive-carrinho-desconto", style: this.customStyles }, index.h("label", { key: '129e5e186fcb43d3bd96fbe235e03f9f5effb732', class: "crm-title" }, this.config.giftbackTitle), this.error && (index.h("label", { key: '841e97f1998d736e7ba8eb413870ecf5b1fbd1b8', class: "crm-message-error" }, this.error)), this.step === info_config_helper.StepFormEnum.STEP_PHONE &&
679
- index.h("phone-form", { key: 'cebcc523fd68ac798038424433cc839e3acfcc45', value: this.customer.phone, config: this.config, loading: this.loading, handlerSubmit: (phone) => this.handleSendPin(phone) }), this.step === info_config_helper.StepFormEnum.STEP_PIN &&
680
- index.h("pin-form", { key: 'c4d49b98b5e9fd0797797a072fb13ac795cd91f2', config: this.config, phone: this.phone, cancel: () => this.changePhone(), resend: () => this.sendPin(), validate: (data) => this.validateBonus(data), loading: this.loading }, this.sucess && index.h("p", { key: 'fb7bcc0108152dde62e3f0197b78ee4be76d1c32', class: "crm-message-info" }, this.sucess), this.error && index.h("p", { key: '502d0ebbdc1bead841dc19d3446d26611850f144', class: "crm-message-error" }, this.error)), this.step === info_config_helper.StepFormEnum.STEP_RESERVE &&
681
- index.h("giftback-info", { key: '789f2d1b42e5b4d776e01bf96c31f0be4b5a6b71', storeName: this.storeName, infoBonus: this.reservedInfo, config: this.config, loading: this.loading, cancel: () => this.handleCancel(), bonus: this.bonus, reserve: () => this.processBonus(), cartId: this.cartId }), this.step === info_config_helper.StepFormEnum.STEP_NO_BONUS &&
682
- (index.h("div", { key: '5b6db02d4919df3737feedb22c5f4fdf17b0614c', class: "container-message" }, info_config_helper.instance.t("noGiftback", { storename: this.config.giftbackTitle })))));
690
+ return (index.h("div", { key: 'f3ea32db1927595fd1b656732ab3f61e80068ed8', class: "crm-container-form fbits-responsive-carrinho-desconto", style: this.customStyles }, index.h("label", { key: '915c8169197885ec905ab94d5c2de0c261742af8', class: "crm-title" }, this.config.giftbackTitle), this.error && (index.h("label", { key: '2a77b7a19f1d731286eb9709428c7f42c19e4abe', class: "crm-message-error" }, this.error)), this.step === info_config_helper.StepFormEnum.STEP_PHONE &&
691
+ index.h("phone-form", { key: '3f403066b0cb2bd1d84d8583695154a02f7462a9', value: this.customer.phone, config: this.config, loading: this.loading, handlerSubmit: (phone) => this.handleSendPin(phone) }), this.step === info_config_helper.StepFormEnum.STEP_PIN &&
692
+ index.h("pin-form", { key: 'e19c016ba700d1dd3f9a5dc9ba40b2a992d4509e', config: this.config, phone: this.phone, cancel: () => this.changePhone(), resend: () => this.sendPin(), validate: (data) => this.validateBonus(data), loading: this.loading }, this.sucess && index.h("p", { key: '214edf06235b404c43839f37ea495583022eaf2d', class: "crm-message-info" }, this.sucess), this.error && index.h("p", { key: '4e4155abab6bc35ab73eaef16d39770672bc21c9', class: "crm-message-error" }, this.error)), this.step === info_config_helper.StepFormEnum.STEP_RESERVE &&
693
+ index.h("giftback-info", { key: 'f2622765c8be61a5cda96c1fd7bca338f6e314ed', storeName: this.storeName, infoBonus: this.reservedInfo, config: this.config, loading: this.loading, cancel: () => this.handleCancel(), bonus: this.bonus, reserve: () => this.processBonus(), cartId: this.cartId }), this.step === info_config_helper.StepFormEnum.STEP_NO_BONUS &&
694
+ (index.h("div", { key: '2e72c4579e8cdc94257cb7d8b554eadfc544a0c6', class: "container-message" }, i18n.instance.t("noGiftback", { storename: this.config.giftbackTitle })))));
683
695
  }
684
696
  };
685
697
  CrmBonus.style = CrmGiftbackFormStyle0;
686
698
 
687
699
  const infoCircleSvgrepoComSvg = 'data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz48IS0tIFVwbG9hZGVkIHRvOiBTVkcgUmVwbywgd3d3LnN2Z3JlcG8uY29tLCBHZW5lcmF0b3I6IFNWRyBSZXBvIE1peGVyIFRvb2xzIC0tPg0KPHN2ZyB3aWR0aD0iODAwcHgiIGhlaWdodD0iODAwcHgiIHZpZXdCb3g9IjAgMCAyNCAyNCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4NCjxwYXRoIGQ9Ik0xMiAxNy43NUMxMi40MTQyIDE3Ljc1IDEyLjc1IDE3LjQxNDIgMTIuNzUgMTdWMTFDMTIuNzUgMTAuNTg1OCAxMi40MTQyIDEwLjI1IDEyIDEwLjI1QzExLjU4NTggMTAuMjUgMTEuMjUgMTAuNTg1OCAxMS4yNSAxMVYxN0MxMS4yNSAxNy40MTQyIDExLjU4NTggMTcuNzUgMTIgMTcuNzVaIiBmaWxsPSIjMUMyNzRDIi8+DQo8cGF0aCBkPSJNMTIgN0MxMi41NTIzIDcgMTMgNy40NDc3MiAxMyA4QzEzIDguNTUyMjggMTIuNTUyMyA5IDEyIDlDMTEuNDQ3NyA5IDExIDguNTUyMjggMTEgOEMxMSA3LjQ0NzcyIDExLjQ0NzcgNyAxMiA3WiIgZmlsbD0iIzFDMjc0QyIvPg0KPHBhdGggZmlsbC1ydWxlPSJldmVub2RkIiBjbGlwLXJ1bGU9ImV2ZW5vZGQiIGQ9Ik0xLjI1IDEyQzEuMjUgNi4wNjI5NCA2LjA2Mjk0IDEuMjUgMTIgMS4yNUMxNy45MzcxIDEuMjUgMjIuNzUgNi4wNjI5NCAyMi43NSAxMkMyMi43NSAxNy45MzcxIDE3LjkzNzEgMjIuNzUgMTIgMjIuNzVDNi4wNjI5NCAyMi43NSAxLjI1IDE3LjkzNzEgMS4yNSAxMlpNMTIgMi43NUM2Ljg5MTM3IDIuNzUgMi43NSA2Ljg5MTM3IDIuNzUgMTJDMi43NSAxNy4xMDg2IDYuODkxMzcgMjEuMjUgMTIgMjEuMjVDMTcuMTA4NiAyMS4yNSAyMS4yNSAxNy4xMDg2IDIxLjI1IDEyQzIxLjI1IDYuODkxMzcgMTcuMTA4NiAyLjc1IDEyIDIuNzVaIiBmaWxsPSIjMUMyNzRDIi8+DQo8L3N2Zz4=';
688
700
 
689
- const crmTooltipCss = ".crm-tooltip-container {\r\n display: flex;\r\n\r\n & img {\r\n width: 16px;\r\n margin-left: 3px;\r\n position: relative;\r\n }\r\n}\r\n\r\n.crm-tooltip {\r\n position: relative;\r\n display: inline-block;\r\n}\r\n\r\n.crm-tooltip .tooltiptext {\r\n visibility: hidden;\r\n background-color: black;\r\n color: #fff;\r\n text-align: center;\r\n padding: 8px 12px;\r\n border-radius: 0px;\r\n position: absolute;\r\n z-index: 1;\r\n min-width: 271px;\r\n top: 100%;\r\n left: 50%;\r\n margin-left: -238px;\r\n}\r\n\r\n@container (max-width: 410px) {\r\n .crm-tooltip .tooltiptext {\r\n margin-left: -14px;\r\n }\r\n\r\n .crm-tooltip #crm-role-description {\r\n margin-left: -151px;\r\n }\r\n}\r\n\r\n@container (max-width: 250px) {\r\n .crm-tooltip .tooltiptext {\r\n margin-left: -201px;\r\n }\r\n}\r\n\r\n.crm-tooltip:hover .tooltiptext {\r\n visibility: visible;\r\n}";
701
+ const crmTooltipCss = ".crm-tooltip-container {\n display: flex;\n\n & img {\n width: 16px;\n margin-left: 3px;\n position: relative;\n }\n}\n\n.crm-tooltip {\n position: relative;\n display: inline-block;\n}\n\n.crm-tooltip .tooltiptext {\n visibility: hidden;\n background-color: black;\n color: #fff;\n text-align: center;\n padding: 8px 12px;\n border-radius: 0px;\n position: absolute;\n z-index: 1;\n min-width: 271px;\n top: 100%;\n left: 50%;\n margin-left: -238px;\n}\n\n@container (max-width: 410px) {\n .crm-tooltip .tooltiptext {\n margin-left: -14px;\n }\n\n .crm-tooltip #crm-role-description {\n margin-left: -151px;\n }\n}\n\n@container (max-width: 250px) {\n .crm-tooltip .tooltiptext {\n margin-left: -201px;\n }\n}\n\n.crm-tooltip:hover .tooltiptext {\n visibility: visible;\n}";
690
702
  const CrmTooltipStyle0 = crmTooltipCss;
691
703
 
692
704
  const Tooltip = class {
@@ -696,7 +708,7 @@ const Tooltip = class {
696
708
  this.identity = undefined;
697
709
  }
698
710
  render() {
699
- return (index.h("div", { key: '01d82d0172ca5f0dbb0b8ea278b4a5d438c13dd5', class: "crm-tooltip-container crm-tooltip" }, index.h("img", { key: '3b632cc38e8ff206402a2bfaadba9f9d2d747095', src: infoCircleSvgrepoComSvg }), index.h("span", { key: '08310e35ac945bda0e9356ecad8742698016f262', id: this.identity, class: "tooltiptext" }, this.text)));
711
+ return (index.h("div", { key: '534965648e0dbd0a1a188a5ed863197d1525e06b', class: "crm-tooltip-container crm-tooltip" }, index.h("img", { key: '0c78ae4b8e8420cb6d478f570d4ecca2b5378366', src: infoCircleSvgrepoComSvg }), index.h("span", { key: '8ceefd15b739459d642ed8bc843d12c44a9f0cf0', id: this.identity, class: "tooltiptext" }, this.text)));
700
712
  }
701
713
  };
702
714
  Tooltip.style = CrmTooltipStyle0;
@@ -738,7 +750,7 @@ const GiftbackInfo = class {
738
750
  }
739
751
  componentWillLoad() {
740
752
  this.updateBonus();
741
- this.selectedOption = localStorage.getItem(cart_helper.USED_KEY);
753
+ this.selectedOption = localStorage.getItem(crmbonus_service.USED_KEY);
742
754
  }
743
755
  handleSliderChange(event) {
744
756
  const input = event.target;
@@ -763,7 +775,7 @@ const GiftbackInfo = class {
763
775
  }
764
776
  async handleOptionChange(option) {
765
777
  this.selectedOption = option;
766
- localStorage.setItem(cart_helper.USED_KEY, option);
778
+ localStorage.setItem(crmbonus_service.USED_KEY, option);
767
779
  await cart_helper.persisteMetadata(this.storeName, this.cartId, Object.assign(Object.assign({}, this.infoBonus.metadata), { createdAt: null }));
768
780
  switch (this.selectedOption) {
769
781
  case 'use':
@@ -799,16 +811,16 @@ const GiftbackInfo = class {
799
811
  var _a, _b, _c, _d, _e, _f, _g;
800
812
  console.log('this.bonus', this.bonus);
801
813
  const remainingGiftback = this.bonus.minimumPurchase - this.bonus.totalValue;
802
- const translateDescription = info_config_helper.instance.t("giftDescription", { amount: `${(_b = (_a = this.bonus) === null || _a === void 0 ? void 0 : _a.totalBonus) === null || _b === void 0 ? void 0 : _b.toFixed(2).replace(".", ",")}`, custom_name: "Giftback" });
814
+ const translateDescription = i18n.instance.t("giftDescription", { amount: `${(_b = (_a = this.bonus) === null || _a === void 0 ? void 0 : _a.totalBonus) === null || _b === void 0 ? void 0 : _b.toFixed(2).replace(".", ",")}`, custom_name: "Giftback" });
803
815
  const limit = utils.defineLimit(remainingGiftback);
804
- return (index.h("div", { key: 'baf90a1de29b3275c1c3cfd31f9d004ca3187a84', class: "giftback-container" }, index.h("div", { key: '57af5fe5b40b3292a275065f577a9444470f8bf0', class: "container-description" }, index.h("p", { key: 'fff28c85077c36854f37d5f23f2908fa47197dac', innerHTML: translateDescription }), index.h("crm-tooltip", { key: 'b66b1914dfa5e0806f85a9695840fdd4bd52d21e', identity: "crm-role-description", text: info_config_helper.instance.t("labelUseGiftback", { minimumPurchase: this.bonus.minimumPurchase, expírationDate: utils.formatDateToBr(this.bonus.firstValidityDate) }) })), index.h("div", { key: 'e13afe9428744084443697df22048ac05b41ffd0', class: "slider-wrapper" }, index.h("div", { key: '1826a50e4e1b474322dbb0020db0154fe9ed5b80', class: "slider-value", style: {
816
+ return (index.h("div", { key: '195e2a11cd6d7dd00764436a17ffca161d6b4da3', class: "giftback-container" }, index.h("div", { key: 'f3d0fa8659c60ccda46e591fe355c228a456b5ea', class: "container-description" }, index.h("p", { key: '2f6d1e3482a21b841dca2caab3b35a5ae686d89c', innerHTML: translateDescription }), index.h("crm-tooltip", { key: '434187c198f3e98511596ce0fb333676a61afbaa', identity: "crm-role-description", text: i18n.instance.t("labelUseGiftback", { minimumPurchase: this.bonus.minimumPurchase, expírationDate: utils.formatDateToBr(this.bonus.firstValidityDate) }) })), index.h("div", { key: '18e7d357e6227117ac4a86690bd75881f95746f1', class: "slider-wrapper" }, index.h("div", { key: '3c76569ccde6669617fffbe38e86b76f35087505', class: "slider-value", style: {
805
817
  left: `calc(${this.sliderValuePosition}% - 20px)`, // Ajuste para centralizar o texto
806
- } }, "R$ ", this.usedValue.toFixed(2).replace(".", ",")), index.h("input", { key: '73b42919b8e4e0223dc8490a6190697d1975e96d', ref: ref => this._refIinputRange = ref, id: "position_value_id", disabled: true, type: "range", min: "0", max: this.bonus.totalBonus, value: this.usedValue, class: "slider", step: "0.01", onInput: (event) => this.handleSliderChange(event), style: {
818
+ } }, "R$ ", this.usedValue.toFixed(2).replace(".", ",")), index.h("input", { key: '54ffa09e4fac90c19cb3c75fc4196d272e624618', ref: ref => this._refIinputRange = ref, id: "position_value_id", disabled: true, type: "range", min: "0", max: this.bonus.totalBonus, value: this.usedValue, class: "slider", step: "0.01", onInput: (event) => this.handleSliderChange(event), style: {
807
819
  background: `linear-gradient(to right, #6D6D5F ${this.sliderPosition}%, #ddd ${this.sliderPosition}%)`,
808
- } })), limit.isComplete && (index.h("p", { key: 'b9b853490c112bf3e98d14c2ceee25d0b7604983' }, info_config_helper.instance.t("maxAmount"))), !limit.isComplete && (index.h("div", { key: '50b23f6c4bde42ca12b077a33f0ffbde25601e3d', class: "container-description" }, index.h("p", { key: '73bfbcc779b8775aecc63050816909ba9120af3e' }, "Adicione ", index.h("strong", { key: '6d5a2ea943a1d3eee80b0f4d0cdda159a300bb25' }, "R$ ", remainingGiftback < 0 ? "0,00" : remainingGiftback.toFixed(2).replace(".", ",")), " ao carrinho para atingir o valor m\u00E1ximo!"), index.h("crm-tooltip", { key: '5a5bbbeb32abd51fbfb84c63d3e7a06f8d459ea0', identity: "crm-max-description", text: info_config_helper.instance.t("labelamountPartial") }))), index.h("div", { key: 'ea3f6aa8f4668b759b912bac36d9780e183a6180', class: "options" }, index.h("div", { key: '6f7f70930c8cd97f1215301d823f8631d071b472', class: "options-option" }, index.h("input", { key: '35b4f8380f34becd4dc94c1bcb1572c2b3401db8', disabled: this.showTime(), type: "radio", name: "giftbackOption", value: "use", checked: this.selectedOption === 'use', onChange: () => this.handleOptionChange('use') }), index.h("p", { key: '228beeb474e10a67811925bee00e5c1d0f5d64b6' }, "Usar o meu ", (_c = this.config) === null || _c === void 0 ? void 0 :
809
- _c.giftbackTitle)), index.h("div", { key: '2a9ad1052f869057d5e36c3eba0cf1a24af88e1b', class: "options-option" }, index.h("input", { key: '3cc3fae293fda510873f9c5f4d906308affca8e1', disabled: this.showTime(), type: "radio", name: "giftbackOption", value: "dontUse", checked: this.selectedOption === 'dontUse', onChange: () => this.handleOptionChange('dontUse') }), index.h("p", { key: '364f7de414a6f536680f849fe3efdee803d9a596' }, "N\u00E3o usar o meu ", (_d = this.config) === null || _d === void 0 ? void 0 :
820
+ } })), limit.isComplete && (index.h("p", { key: '041f7e96e2fe0d54b68c716e8d9f74ddfef10281' }, i18n.instance.t("maxAmount"))), !limit.isComplete && (index.h("div", { key: '1a1532056a0cb4b24d51435d31d5964b14c2bcc6', class: "container-description" }, index.h("p", { key: '17b4891372a3c99c70ed0e08128ecf9204b1b1e7' }, "Adicione ", index.h("strong", { key: 'fda5f4395726a7d24779f565e240c0e1d8cbf449' }, "R$ ", remainingGiftback < 0 ? "0,00" : remainingGiftback.toFixed(2).replace(".", ",")), " ao carrinho para atingir o valor m\u00E1ximo!"), index.h("crm-tooltip", { key: 'd4a87c3cea10126ddccccf3a43228da3a9584498', identity: "crm-max-description", text: i18n.instance.t("labelamountPartial") }))), index.h("div", { key: 'f026b9fdf3fca8087eb89fffe171dc09ae7afb78', class: "options" }, index.h("div", { key: '2865aa73085ea32b24aa112cb1bc805465b900cb', class: "options-option" }, index.h("input", { key: 'cc7da252330f60f386368bbc8453ca6dce07bc44', disabled: this.showTime(), type: "radio", name: "giftbackOption", value: "use", checked: this.selectedOption === 'use', onChange: () => this.handleOptionChange('use') }), index.h("p", { key: '97e619e5c003a676f1213dfff2ed7c4d0bff46e1' }, "Usar o meu ", (_c = this.config) === null || _c === void 0 ? void 0 :
821
+ _c.giftbackTitle)), index.h("div", { key: 'b71d5555915d93048a52cd92046e8f69fb823ffa', class: "options-option" }, index.h("input", { key: '3e5b513d5f1fc8db55a4e3124149884e8507ea14', disabled: this.showTime(), type: "radio", name: "giftbackOption", value: "dontUse", checked: this.selectedOption === 'dontUse', onChange: () => this.handleOptionChange('dontUse') }), index.h("p", { key: 'e63495d7145bdacbc7bef993097b6136874ba508' }, "N\u00E3o usar o meu ", (_d = this.config) === null || _d === void 0 ? void 0 :
810
822
  _d.giftbackTitle))), this.showTime() &&
811
- (index.h("div", { key: '8fe525904208e2fc13ebd80615bbe7856cc2dc2c', class: "info-box" }, "Ap\u00F3s ", index.h("countdown-timer", { key: '3913bc9060980620654f03a987f62f628d6ee440', dataCriacao: new Date((_f = (_e = this.infoBonus) === null || _e === void 0 ? void 0 : _e.metadata) === null || _f === void 0 ? void 0 : _f.createdAt).toString(), downtime: () => { window.location.reload(); } }), ", voc\u00EA poder\u00E1 alterar sua escolha de usar ou n\u00E3o o Giftback.")), !((_g = this === null || this === void 0 ? void 0 : this.infoBonus) === null || _g === void 0 ? void 0 : _g.isBonusProcessed) && (index.h("div", { key: 'aecd80b9920c8b483d38a1c24a6b38ce03d52b64', class: "info-box" }, "O Giftback ser\u00E1 aplicado na pr\u00F3xima etapa."))));
823
+ (index.h("div", { key: 'ae2bd73c7a6bf96a752df0d0a6392f0a0acd8d8d', class: "info-box" }, "Ap\u00F3s ", index.h("countdown-timer", { key: '30b0740031c60414d02dcd29afd1d3137923813a', dataCriacao: new Date((_f = (_e = this.infoBonus) === null || _e === void 0 ? void 0 : _e.metadata) === null || _f === void 0 ? void 0 : _f.createdAt).toString(), downtime: () => { window.location.reload(); } }), ", voc\u00EA poder\u00E1 alterar sua escolha de usar ou n\u00E3o o Giftback.")), !((_g = this === null || this === void 0 ? void 0 : this.infoBonus) === null || _g === void 0 ? void 0 : _g.isBonusProcessed) && (index.h("div", { key: 'c4a5764d0c55b1a2857328625f1c70285f2f41ca', class: "info-box" }, "O Giftback ser\u00E1 aplicado na pr\u00F3xima etapa."))));
812
824
  }
813
825
  static get watchers() { return {
814
826
  "bonus": ["changedBonus"]
@@ -826,7 +838,7 @@ const LoadingContainer = class {
826
838
  this.text = null;
827
839
  }
828
840
  render() {
829
- return (index.h("div", { key: '5e323e6b562ee4d770bb2c9f786a23d6b47ce06e', class: "relative-xy" }, this.loading && (index.h("div", { key: '31183c82285ec32c7de0348885d0fd30e4a82502', class: "loading-container" }, index.h("div", { key: '1de235c7594a15e822d044364de0700d3c9e1fa4', class: "loading-spinner" }), this.text && index.h("p", { key: '82daa6b96a1e14d83be2fc22fd879b3a41896d0e' }, this.text))), index.h("slot", { key: '09c654783fde15f7b34c4a0804fcec07cfa28b30' })));
841
+ return (index.h("div", { key: '486a3d4734d92d8be2da057450f42e5b2800b7a8', class: "relative-xy" }, this.loading && (index.h("div", { key: '3f8312f7498943ef8be28ce1e82de117ff29ad89', class: "loading-container" }, index.h("div", { key: '3b5757424aea6a1802574c594db99298831e7941', class: "loading-spinner" }), this.text && index.h("p", { key: 'cab83dd07dd6b6395400ba7092370322a04d0792' }, this.text))), index.h("slot", { key: '8cd2f16b6ba255f5a3ee65d76699d31f388836f9' })));
830
842
  }
831
843
  };
832
844
  LoadingContainer.style = LoadingContainerStyle0;
@@ -841,7 +853,7 @@ const LoadingSpinner = class {
841
853
  this.color = '#0078d7';
842
854
  }
843
855
  render() {
844
- return (index.h("div", { key: 'e1916d264937b0470cd5b1581c87184061b40c3a', class: "spinner", style: { width: this.size, height: this.size, borderColor: `${this.color} transparent transparent transparent` } }));
856
+ return (index.h("div", { key: '6caf8a2629d91a30af01a779893c898568b4ee68', class: "spinner", style: { width: this.size, height: this.size, borderColor: `${this.color} transparent transparent transparent` } }));
845
857
  }
846
858
  };
847
859
  LoadingSpinner.style = LoadingSpinnerStyle0;
@@ -863,7 +875,7 @@ const PhoneForm = class {
863
875
  }
864
876
  render() {
865
877
  var _a;
866
- return (index.h(index.Host, { key: 'b27f64d8464d4c6b259d2d5f0113f55a6f809afb', class: "crm-phone-form" }, index.h("p", { key: '6f279841f43cd7f70f7a1b5340288b9c2d11c551', class: "crm-subtitle" }, "Digite o seu celular para verificar se h\u00E1 desconto dispon\u00EDvel nessa compra:"), index.h("phone-input-mask", { key: '7e86f63998a4f35d134b8f4e867a5e5c0b9df20a', initialValue: this.value, ref: ref => this.phoneInputMask = ref }), index.h("crm-button", { key: '462b7cc91f166c8fc588a5c922ba943a6715dca5', txtBtn: ((_a = this.config) === null || _a === void 0 ? void 0 : _a.btnApplyBonusLabel) || "Avançar", loading: this.loading, handleClick: () => this.handlePhone() })));
878
+ return (index.h(index.Host, { key: 'c2de82d459c0cc83cdd5067bcc9c30f53eb8be61', class: "crm-phone-form" }, index.h("p", { key: 'ed7ddeaed69dad3f907b7975c1c21a9d89e30aaf', class: "crm-subtitle" }, "Digite o seu celular para verificar se h\u00E1 desconto dispon\u00EDvel nessa compra:"), index.h("phone-input-mask", { key: 'faba3de2a7e2a169e6e0e8a4eb3064affd4c40b1', initialValue: this.value, ref: ref => this.phoneInputMask = ref }), index.h("crm-button", { key: '5189a76614a5bdd4f489c4af99298c9271a8f855', txtBtn: ((_a = this.config) === null || _a === void 0 ? void 0 : _a.btnApplyBonusLabel) || "Avançar", loading: this.loading, handleClick: () => this.handlePhone() })));
867
879
  }
868
880
  };
869
881
  PhoneForm.style = PhoneFormStyle0;
@@ -914,7 +926,7 @@ const PhoneInputMask = class {
914
926
  return this.phone;
915
927
  }
916
928
  render() {
917
- return (index.h("div", { key: 'bbb0389d0a7ccb8651b8ee20e92dd4cdc94e3617' }, index.h("input", { key: 'b36cc9e65314cb786c7f94fee6b4992ba30a82e6', disabled: this.disabled, id: "phone", type: "text", class: "phone-input-form", value: this.phone, onInput: (event) => this.handleInput(event), placeholder: "(99) 99999 9999" }), index.h("p", { key: '81e48cda38cd9a8fc7d753d269425bd4288c57b1', class: "crm-erro-msg" }, this.message)));
929
+ return (index.h("div", { key: '3d6d215ecccdb5a556c7a4c28b89c638c2c88578' }, index.h("input", { key: 'cc27335746fa2e45ff766653a0607c0f7342b119', disabled: this.disabled, id: "phone", type: "text", class: "phone-input-form", value: this.phone, onInput: (event) => this.handleInput(event), placeholder: "(99) 99999 9999" }), index.h("p", { key: 'fe4388da1e7dbd421aeb5ef065e2251c9bbc56ac', class: "crm-erro-msg" }, this.message)));
918
930
  }
919
931
  };
920
932
  PhoneInputMask.style = PhoneInputMaskStyle0;
@@ -985,7 +997,7 @@ const GiftbackPin = class {
985
997
  }
986
998
  render() {
987
999
  var _a;
988
- return (index.h("div", { key: '3f60e4c74c925daf656092812f40ae0d1f3b5a99', class: "crm-phone-form" }, index.h("label", { key: 'd0c023e22ff7eb8978ee6cc0ca4ced8192c53c20', class: "crm-subtitle" }, info_config_helper.instance.t('pin-sutitle'), " ", index.h("strong", { key: '05bb0e2493c99abaa29031a7cc787260266bb417' }, "+55 ", this.phone)), index.h("div", { key: '24c8eb55625f3b880741086c66decd96ecf40044', class: "pin-container" }, this.pin.map((_, index$1) => (index.h("input", { type: "text", maxLength: 1, value: this.pin[index$1], onInput: (event) => this.handleInput(event, index$1) })))), index.h("slot", { key: '02276aa80396d16f779a92a381e75506fa37d56d' }), index.h("p", { key: '27af068858b3ead8a70b8ec961d367c7beb04d94', class: "crm-description" }, " N\u00E3o recebeu?", !this.canResend && index.h("label", { key: '8ef93baf6f92142292078e5e4bcc125ff12b80d7' }, " Reenviar em", index.h("countdown-timer", { key: 'f3a0c60c7a88229e37add445886c44b00c60913f', minutos: 0, segundos: 30, dataCriacao: this.buildTime(), downtime: () => this.handleTimeout() }), " "), this.canResend && (index.h("div", { key: '2d1b5b028a7085d912acb0d0c696436e8aa75a29' }, index.h("a", { key: 'ad9aea2c6f167f1270c75b8dbd2ee79879f7567d', onClick: () => this.handleResend() }, "Reenviar"), index.h("a", { key: 'b0734ab0e472c5cf24fa083c0a712e4f29cf8d79', onClick: () => this.cancel() }, "Trocar n\u00FAmero")))), index.h("crm-button", { key: '39095211d007c871f48971509c3ff52b0f257c29', txtBtn: ((_a = this.config) === null || _a === void 0 ? void 0 : _a.btnApplyBonusLabel) || "Avançar", loading: this.loading, handleClick: () => this.validatePin() })));
1000
+ return (index.h("div", { key: '2be147a2bf1e2861182eeddfad6714d0df2ec2bf', class: "crm-phone-form" }, index.h("label", { key: '4c09360b91a93b82b4da5f7131e9e1ab6bae6d2e', class: "crm-subtitle" }, i18n.instance.t('pin-sutitle'), " ", index.h("strong", { key: '93e6cff73e4a880ec15a58a5deed7494d7c6ceea' }, "+55 ", this.phone)), index.h("div", { key: '64fac61c1c38ae629175c01d48c5ea8166c647c3', class: "pin-container" }, this.pin.map((_, index$1) => (index.h("input", { type: "text", maxLength: 1, value: this.pin[index$1], onInput: (event) => this.handleInput(event, index$1) })))), index.h("slot", { key: '0d839e75cdbe72dc0bbb0087d07dcde69203bf4f' }), index.h("p", { key: 'a9b36da6547b1bf1fdf60c76ace23d766261e4b8', class: "crm-description" }, " N\u00E3o recebeu?", !this.canResend && index.h("label", { key: 'ad36c4798d3e64ec148edb6ca7d602bee31c78c7' }, " Reenviar em", index.h("countdown-timer", { key: '61fb798a992ab419715fc3c00de76098d70ea229', minutos: 0, segundos: 30, dataCriacao: this.buildTime(), downtime: () => this.handleTimeout() }), " "), this.canResend && (index.h("div", { key: '6fa670dd030d93d300b9033c7fa577bb6ad13dbf' }, index.h("a", { key: '65be3061249de1a8669daa6f76ffdf555af53242', onClick: () => this.handleResend() }, "Reenviar"), index.h("a", { key: '625d1c3f61c04a4337f57fce587037970050b272', onClick: () => this.cancel() }, "Trocar n\u00FAmero")))), index.h("crm-button", { key: '644e5753282950c06811ea74be34071c4d7ca35e', txtBtn: ((_a = this.config) === null || _a === void 0 ? void 0 : _a.btnApplyBonusLabel) || "Avançar", loading: this.loading, handleClick: () => this.validatePin() })));
989
1001
  }
990
1002
  };
991
1003
  GiftbackPin.style = PinFormStyle0 + PinFormStyle1;