crmbonus-component-wake 2.0.51 → 2.0.52
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.
- package/dist/cjs/app-globals-3a1e7e63.js +7 -0
- package/dist/cjs/app-globals-3a1e7e63.js.map +1 -0
- package/dist/cjs/app-modal.cjs.entry.js +28 -0
- package/dist/cjs/app-modal.cjs.entry.js.map +1 -0
- package/dist/cjs/countdown-timer_4.cjs.entry.js +181 -0
- package/dist/cjs/countdown-timer_4.cjs.entry.js.map +1 -0
- package/dist/cjs/crm-bonus-form.cjs.entry.js +103 -0
- package/dist/cjs/crm-bonus-form.cjs.entry.js.map +1 -0
- package/dist/cjs/crm-bonus-note.cjs.entry.js +53 -0
- package/dist/{crmbonus-component-wake/crm-bonus-note.entry.js.map → cjs/crm-bonus-note.cjs.entry.js.map} +1 -1
- package/dist/cjs/crm-bonus.cjs.entry.js +204 -0
- package/dist/cjs/crm-bonus.cjs.entry.js.map +1 -0
- package/dist/cjs/crm-button.cjs.entry.js +25 -0
- package/dist/cjs/crm-button.cjs.entry.js.map +1 -0
- package/dist/cjs/crm-giftback-form.cjs.entry.js +173 -0
- package/dist/cjs/crm-giftback-form.cjs.entry.js.map +1 -0
- package/dist/cjs/crmbonus-component-wake.cjs.js +27 -0
- package/dist/cjs/crmbonus-component-wake.cjs.js.map +1 -0
- package/dist/cjs/crmbonus.service-3c4ebbdf.js +3852 -0
- package/dist/cjs/crmbonus.service-3c4ebbdf.js.map +1 -0
- package/dist/cjs/giftback-finish_4.cjs.entry.js +132 -0
- package/dist/cjs/giftback-finish_4.cjs.entry.js.map +1 -0
- package/dist/cjs/i18n-efd790a3.js +2209 -0
- package/dist/cjs/i18n-efd790a3.js.map +1 -0
- package/dist/cjs/index-80419303.js +1253 -0
- package/dist/cjs/index-80419303.js.map +1 -0
- package/dist/cjs/index-96a8951f.js +16 -0
- package/dist/cjs/index-96a8951f.js.map +1 -0
- package/dist/cjs/index.cjs.js +11 -0
- package/dist/cjs/index.cjs.js.map +1 -0
- package/dist/cjs/info.config.helper-c5d9f781.js +16 -0
- package/dist/cjs/info.config.helper-c5d9f781.js.map +1 -0
- package/dist/cjs/loader.cjs.js +17 -0
- package/dist/cjs/loader.cjs.js.map +1 -0
- package/dist/cjs/loading-spinner.cjs.entry.js +24 -0
- package/dist/cjs/loading-spinner.cjs.entry.js.map +1 -0
- package/dist/cjs/pedido-finalizado.cjs.entry.js +36 -0
- package/dist/cjs/pedido-finalizado.cjs.entry.js.map +1 -0
- package/dist/cjs/phone-cancel-input.cjs.entry.js +25 -0
- package/dist/cjs/phone-cancel-input.cjs.entry.js.map +1 -0
- package/dist/cjs/phone-input-mask.cjs.entry.js +61 -0
- package/dist/cjs/phone-input-mask.cjs.entry.js.map +1 -0
- package/dist/cjs/phone-input.cjs.entry.js +25 -0
- package/dist/cjs/phone-input.cjs.entry.js.map +1 -0
- package/dist/collection/assets/svg/money-dollars-svgrepo-com.svg +6 -0
- package/dist/collection/collection-manifest.json +30 -0
- package/dist/collection/components/button/crm-button.css +22 -0
- package/dist/collection/components/button/index.js +76 -0
- package/dist/collection/components/button/index.js.map +1 -0
- package/dist/collection/components/countdown-timer/countdown-timer.js +51 -0
- package/dist/collection/components/countdown-timer/countdown-timer.js.map +1 -0
- package/dist/collection/components/crm-bonus/assets/logo.svg +18 -0
- package/dist/collection/components/crm-bonus/assets/success-svgrepo-com.svg +8 -0
- package/dist/collection/components/crm-bonus/assets/svg/logo.svg +18 -0
- package/dist/collection/components/crm-bonus/assets/svg/success-svgrepo-com.svg +8 -0
- package/dist/collection/components/crm-bonus/crm-bonus.css +84 -0
- package/dist/collection/components/crm-bonus/crm-bonus.js +291 -0
- package/dist/collection/components/crm-bonus/crm-bonus.js.map +1 -0
- package/dist/collection/components/crm-bonus-form/crm-bonus-form.css +19 -0
- package/dist/collection/components/crm-bonus-form/crm-bonus-form.js +348 -0
- package/dist/collection/components/crm-bonus-form/crm-bonus-form.js.map +1 -0
- package/dist/collection/components/crm-bonus-form/subcomponents/giftback-finish/giftback-finish.css +10 -0
- package/dist/collection/components/crm-bonus-form/subcomponents/giftback-finish/giftback-finish.js +20 -0
- package/dist/collection/components/crm-bonus-form/subcomponents/giftback-finish/giftback-finish.js.map +1 -0
- package/dist/collection/components/crm-bonus-form/subcomponents/giftback-pin/giftback-pin.css +70 -0
- package/dist/collection/components/crm-bonus-form/subcomponents/giftback-pin/giftback-pin.js +127 -0
- package/dist/collection/components/crm-bonus-form/subcomponents/giftback-pin/giftback-pin.js.map +1 -0
- package/dist/collection/components/crm-bonus-form/subcomponents/giftback-progress/giftback-progress.css +110 -0
- package/dist/collection/components/crm-bonus-form/subcomponents/giftback-progress/giftback-progress.js +127 -0
- package/dist/collection/components/crm-bonus-form/subcomponents/giftback-progress/giftback-progress.js.map +1 -0
- package/dist/collection/components/crm-bonus-form/subcomponents/name-input/name-input.css +108 -0
- package/dist/collection/components/crm-bonus-form/subcomponents/name-input/name-input.js +110 -0
- package/dist/collection/components/crm-bonus-form/subcomponents/name-input/name-input.js.map +1 -0
- package/dist/collection/components/crm-bonus-form/subcomponents/phone/phone.input.js +75 -0
- package/dist/collection/components/crm-bonus-form/subcomponents/phone/phone.input.js.map +1 -0
- package/dist/collection/components/crm-bonus-form/subcomponents/phone-cancel/phone.cancel.input.js +75 -0
- package/dist/collection/components/crm-bonus-form/subcomponents/phone-cancel/phone.cancel.input.js.map +1 -0
- package/dist/collection/components/giftback-form/giftback-form.css +74 -0
- package/dist/collection/components/giftback-form/giftback-form.js +248 -0
- package/dist/collection/components/giftback-form/giftback-form.js.map +1 -0
- package/dist/collection/components/giftback-form/subcomponents/giftback-info/giftback-info.css +154 -0
- package/dist/collection/components/giftback-form/subcomponents/giftback-info/giftback-info.js +156 -0
- package/dist/collection/components/giftback-form/subcomponents/giftback-info/giftback-info.js.map +1 -0
- package/dist/collection/components/giftback-form/subcomponents/giftback-message/giftback-massage.js +11 -0
- package/dist/collection/components/giftback-form/subcomponents/giftback-message/giftback-massage.js.map +1 -0
- package/dist/collection/components/giftback-form/subcomponents/phone-form/phone-form.js +103 -0
- package/dist/collection/components/giftback-form/subcomponents/phone-form/phone-form.js.map +1 -0
- package/dist/collection/components/giftback-form/subcomponents/pin-form/pin-form.css +84 -0
- package/dist/collection/components/giftback-form/subcomponents/pin-form/pin-form.js +198 -0
- package/dist/collection/components/giftback-form/subcomponents/pin-form/pin-form.js.map +1 -0
- package/dist/collection/components/loading-spinner/loading-spinner.css +17 -0
- package/dist/collection/components/loading-spinner/loading-spinner.js +63 -0
- package/dist/collection/components/loading-spinner/loading-spinner.js.map +1 -0
- package/dist/collection/components/modal/app-modal.css +45 -0
- package/dist/collection/components/modal/app-modal.js +83 -0
- package/dist/collection/components/modal/app-modal.js.map +1 -0
- package/dist/collection/components/note/crm-bonus-note.css +54 -0
- package/dist/collection/components/note/crm-bonus-note.js +94 -0
- package/dist/collection/components/note/crm-bonus-note.js.map +1 -0
- package/dist/collection/components/pedido/pedido.js +83 -0
- package/dist/collection/components/pedido/pedido.js.map +1 -0
- package/dist/collection/components/phone/phone-input-mask.css +39 -0
- package/dist/collection/components/phone/phone-input-mask.js +125 -0
- package/dist/collection/components/phone/phone-input-mask.js.map +1 -0
- package/dist/collection/contants/index.js +11 -0
- package/dist/collection/contants/index.js.map +1 -0
- package/dist/collection/contants/mocks.js +28 -0
- package/dist/collection/contants/mocks.js.map +1 -0
- package/dist/collection/dto/pin.sent.js +2 -0
- package/dist/collection/dto/pin.sent.js.map +1 -0
- package/dist/collection/dto/update.order.dto.js +2 -0
- package/dist/collection/dto/update.order.dto.js.map +1 -0
- package/dist/collection/dto/validate.pin.bonus.js +2 -0
- package/dist/collection/dto/validate.pin.bonus.js.map +1 -0
- package/dist/collection/helpers/info.config.helper.js +11 -0
- package/dist/collection/helpers/info.config.helper.js.map +1 -0
- package/dist/collection/i18n/i18n.js +25 -0
- package/dist/collection/i18n/i18n.js.map +1 -0
- package/dist/collection/index.js +11 -0
- package/dist/collection/index.js.map +1 -0
- package/dist/collection/services/crmbonus.service.js +96 -0
- package/dist/collection/services/crmbonus.service.js.map +1 -0
- package/dist/collection/utils/utils.js +4 -0
- package/dist/collection/utils/utils.js.map +1 -0
- package/dist/components/app-modal.js +46 -0
- package/dist/components/app-modal.js.map +1 -0
- package/dist/components/countdown-timer.js +8 -0
- package/dist/components/countdown-timer.js.map +1 -0
- package/dist/components/crm-bonus-form.js +165 -0
- package/dist/components/crm-bonus-form.js.map +1 -0
- package/dist/components/crm-bonus-note.js +72 -0
- package/dist/components/crm-bonus-note.js.map +1 -0
- package/dist/components/crm-bonus.js +282 -0
- package/dist/components/crm-bonus.js.map +1 -0
- package/dist/components/crm-button.js +8 -0
- package/dist/components/crm-button.js.map +1 -0
- package/dist/components/crm-giftback-form.js +8 -0
- package/dist/components/crm-giftback-form.js.map +1 -0
- package/dist/components/giftback-finish.js +8 -0
- package/dist/components/giftback-finish.js.map +1 -0
- package/dist/components/giftback-info.js +8 -0
- package/dist/components/giftback-info.js.map +1 -0
- package/dist/components/giftback-pin.js +8 -0
- package/dist/components/giftback-pin.js.map +1 -0
- package/dist/components/giftback-progress.js +8 -0
- package/dist/components/giftback-progress.js.map +1 -0
- package/dist/components/index.js +9 -0
- package/dist/components/index.js.map +1 -0
- package/dist/components/loading-spinner.js +8 -0
- package/dist/components/loading-spinner.js.map +1 -0
- package/dist/components/name-input.js +8 -0
- package/dist/components/name-input.js.map +1 -0
- package/dist/components/p-2f266d73.js +1068 -0
- package/dist/components/p-2f266d73.js.map +1 -0
- package/dist/components/p-39d680b6.js +49 -0
- package/dist/components/p-39d680b6.js.map +1 -0
- package/dist/{crmbonus-component-wake/giftback-pin.entry.js → components/p-4f18f4c0.js} +39 -9
- package/dist/components/p-4f18f4c0.js.map +1 -0
- package/dist/components/p-57ec707e.js +79 -0
- package/dist/components/p-57ec707e.js.map +1 -0
- package/dist/components/p-5c3fe5a8.js +39 -0
- package/dist/components/p-5c3fe5a8.js.map +1 -0
- package/dist/components/p-73e75b43.js +240 -0
- package/dist/components/p-73e75b43.js.map +1 -0
- package/dist/components/p-75ba7b9a.js +14 -0
- package/dist/components/p-75ba7b9a.js.map +1 -0
- package/dist/components/p-9f68d2a1.js +65 -0
- package/dist/components/p-9f68d2a1.js.map +1 -0
- package/dist/{crmbonus-component-wake/name-input.entry.js → components/p-a30bd6b1.js} +38 -9
- package/dist/components/p-a30bd6b1.js.map +1 -0
- package/dist/components/p-a561251a.js +14 -0
- package/dist/components/p-a561251a.js.map +1 -0
- package/dist/{crmbonus-component-wake/crmbonus.service-98a7bcf0.js → components/p-dd6f6ab7.js} +90 -165
- package/dist/components/p-dd6f6ab7.js.map +1 -0
- package/dist/components/p-e4ac17bf.js +46 -0
- package/dist/components/p-e4ac17bf.js.map +1 -0
- package/dist/components/p-f168d5f6.js +69 -0
- package/dist/components/p-f168d5f6.js.map +1 -0
- package/dist/{crmbonus-component-wake/pin-form.entry.js → components/p-f4244087.js} +57 -10
- package/dist/components/p-f4244087.js.map +1 -0
- package/dist/{crmbonus-component-wake/giftback-info.entry.js → components/p-f579d773.js} +36 -13
- package/dist/components/p-f579d773.js.map +1 -0
- package/dist/components/p-f5fcff75.js +36 -0
- package/dist/components/p-f5fcff75.js.map +1 -0
- package/dist/{crmbonus-component-wake/i18n-a17a0837.js → components/p-fb505488.js} +1 -16
- package/dist/components/p-fb505488.js.map +1 -0
- package/dist/components/pedido-finalizado.js +54 -0
- package/dist/components/pedido-finalizado.js.map +1 -0
- package/dist/components/phone-cancel-input.js +55 -0
- package/dist/components/phone-cancel-input.js.map +1 -0
- package/dist/components/phone-form.js +8 -0
- package/dist/components/phone-form.js.map +1 -0
- package/dist/components/phone-input-mask.js +8 -0
- package/dist/components/phone-input-mask.js.map +1 -0
- package/dist/components/phone-input.js +55 -0
- package/dist/components/phone-input.js.map +1 -0
- package/dist/components/pin-form.js +8 -0
- package/dist/components/pin-form.js.map +1 -0
- package/dist/crmbonus-component-wake/crmbonus-component-wake.css +1 -7
- package/dist/crmbonus-component-wake/crmbonus-component-wake.esm.js +1 -48
- package/dist/crmbonus-component-wake/crmbonus-component-wake.esm.js.map +1 -1
- package/dist/crmbonus-component-wake/index.esm.js +1 -16
- package/dist/crmbonus-component-wake/index.esm.js.map +1 -1
- package/dist/crmbonus-component-wake/p-118fc099.entry.js +2 -0
- package/dist/crmbonus-component-wake/p-118fc099.entry.js.map +1 -0
- package/dist/crmbonus-component-wake/p-298d8fff.entry.js +2 -0
- package/dist/crmbonus-component-wake/p-298d8fff.entry.js.map +1 -0
- package/dist/crmbonus-component-wake/p-312caf3f.entry.js +2 -0
- package/dist/crmbonus-component-wake/p-312caf3f.entry.js.map +1 -0
- package/dist/crmbonus-component-wake/p-3522a3e3.entry.js +2 -0
- package/dist/crmbonus-component-wake/p-3522a3e3.entry.js.map +1 -0
- package/dist/crmbonus-component-wake/p-3beb5158.entry.js +2 -0
- package/dist/crmbonus-component-wake/p-3beb5158.entry.js.map +1 -0
- package/dist/crmbonus-component-wake/p-66f41fd0.entry.js +2 -0
- package/dist/crmbonus-component-wake/p-66f41fd0.entry.js.map +1 -0
- package/dist/crmbonus-component-wake/p-6e6bf96e.js +3 -0
- package/dist/crmbonus-component-wake/p-6e6bf96e.js.map +1 -0
- package/dist/crmbonus-component-wake/p-75ba7b9a.js +2 -0
- package/dist/crmbonus-component-wake/p-75ba7b9a.js.map +1 -0
- package/dist/crmbonus-component-wake/p-830b5bdc.entry.js +2 -0
- package/dist/crmbonus-component-wake/p-830b5bdc.entry.js.map +1 -0
- package/dist/crmbonus-component-wake/p-8b9a1aec.entry.js +2 -0
- package/dist/crmbonus-component-wake/p-8b9a1aec.entry.js.map +1 -0
- package/dist/crmbonus-component-wake/p-9acd4f81.entry.js +2 -0
- package/dist/crmbonus-component-wake/p-9acd4f81.entry.js.map +1 -0
- package/dist/crmbonus-component-wake/p-a561251a.js +2 -0
- package/dist/crmbonus-component-wake/p-a561251a.js.map +1 -0
- package/dist/crmbonus-component-wake/p-adb37e26.entry.js +2 -0
- package/dist/crmbonus-component-wake/p-adb37e26.entry.js.map +1 -0
- package/dist/crmbonus-component-wake/p-c4cc29a0.entry.js +2 -0
- package/dist/crmbonus-component-wake/p-c4cc29a0.entry.js.map +1 -0
- package/dist/crmbonus-component-wake/p-c8054eaf.entry.js +2 -0
- package/dist/crmbonus-component-wake/p-c8054eaf.entry.js.map +1 -0
- package/dist/crmbonus-component-wake/p-c86583a2.entry.js +2 -0
- package/dist/crmbonus-component-wake/p-c86583a2.entry.js.map +1 -0
- package/dist/crmbonus-component-wake/p-dd6f6ab7.js +2 -0
- package/dist/crmbonus-component-wake/p-dd6f6ab7.js.map +1 -0
- package/dist/crmbonus-component-wake/p-e1255160.js +2 -0
- package/dist/crmbonus-component-wake/p-e1255160.js.map +1 -0
- package/dist/crmbonus-component-wake/p-fb505488.js +2 -0
- package/dist/crmbonus-component-wake/p-fb505488.js.map +1 -0
- package/dist/env.js +5 -0
- package/dist/env.js.map +1 -0
- package/dist/{crmbonus-component-wake → esm}/app-modal.entry.js +4 -3
- package/dist/esm/app-modal.entry.js.map +1 -0
- package/dist/esm/countdown-timer_4.entry.js +174 -0
- package/dist/esm/countdown-timer_4.entry.js.map +1 -0
- package/dist/{crmbonus-component-wake → esm}/crm-bonus-form.entry.js +5 -4
- package/dist/esm/crm-bonus-form.entry.js.map +1 -0
- package/dist/{crmbonus-component-wake → esm}/crm-bonus-note.entry.js +6 -5
- package/dist/esm/crm-bonus-note.entry.js.map +1 -0
- package/dist/{crmbonus-component-wake → esm}/crm-bonus.entry.js +6 -7
- package/dist/esm/crm-bonus.entry.js.map +1 -0
- package/dist/{crmbonus-component-wake → esm}/crm-button.entry.js +4 -3
- package/dist/esm/crm-button.entry.js.map +1 -0
- package/dist/{crmbonus-component-wake → esm}/crm-giftback-form.entry.js +11 -10
- package/dist/esm/crm-giftback-form.entry.js.map +1 -0
- package/dist/esm/crmbonus-component-wake.js +22 -0
- package/dist/esm/crmbonus-component-wake.js.map +1 -0
- package/dist/{crmbonus-component-wake/crmbonus.service-0e166281.js → esm/crmbonus.service-9cba7b49.js} +92 -167
- package/dist/esm/crmbonus.service-9cba7b49.js.map +1 -0
- package/dist/esm/giftback-finish_4.entry.js +125 -0
- package/dist/esm/giftback-finish_4.entry.js.map +1 -0
- package/dist/esm/i18n-887a3ef8.js +2207 -0
- package/dist/{crmbonus-component-wake/i18n-a17a0837.js.map → esm/i18n-887a3ef8.js.map} +1 -1
- package/dist/esm/index-a4c14fca.js +1225 -0
- package/dist/esm/index-a4c14fca.js.map +1 -0
- package/dist/esm/index.js +7 -0
- package/dist/esm/index.js.map +1 -0
- package/dist/esm/loader.js +13 -0
- package/dist/esm/loader.js.map +1 -0
- package/dist/{crmbonus-component-wake → esm}/loading-spinner.entry.js +4 -3
- package/dist/esm/loading-spinner.entry.js.map +1 -0
- package/dist/{crmbonus-component-wake → esm}/pedido-finalizado.entry.js +3 -3
- package/dist/esm/pedido-finalizado.entry.js.map +1 -0
- package/dist/{crmbonus-component-wake → esm}/phone-cancel-input.entry.js +2 -2
- package/dist/esm/phone-cancel-input.entry.js.map +1 -0
- package/dist/{crmbonus-component-wake → esm}/phone-input-mask.entry.js +4 -3
- package/dist/esm/phone-input-mask.entry.js.map +1 -0
- package/dist/{crmbonus-component-wake → esm}/phone-input.entry.js +2 -2
- package/dist/esm/phone-input.entry.js.map +1 -0
- package/dist/index.cjs.js +1 -0
- package/dist/index.js +1 -0
- package/package.json +1 -1
- package/dist/crmbonus-component-wake/app-modal.entry.js.map +0 -1
- package/dist/crmbonus-component-wake/countdown-timer.entry.js +0 -30
- package/dist/crmbonus-component-wake/countdown-timer.entry.js.map +0 -1
- package/dist/crmbonus-component-wake/crm-bonus-form.entry.js.map +0 -1
- package/dist/crmbonus-component-wake/crm-bonus.entry.js.map +0 -1
- package/dist/crmbonus-component-wake/crm-button.entry.js.map +0 -1
- package/dist/crmbonus-component-wake/crm-giftback-form.entry.js.map +0 -1
- package/dist/crmbonus-component-wake/crmbonus.service-0e166281.js.map +0 -1
- package/dist/crmbonus-component-wake/crmbonus.service-98a7bcf0.js.map +0 -1
- package/dist/crmbonus-component-wake/giftback-finish.entry.js +0 -19
- package/dist/crmbonus-component-wake/giftback-finish.entry.js.map +0 -1
- package/dist/crmbonus-component-wake/giftback-info.entry.js.map +0 -1
- package/dist/crmbonus-component-wake/giftback-pin.entry.js.map +0 -1
- package/dist/crmbonus-component-wake/giftback-progress.entry.js +0 -40
- package/dist/crmbonus-component-wake/giftback-progress.entry.js.map +0 -1
- package/dist/crmbonus-component-wake/index-bdc90e13.js +0 -3039
- package/dist/crmbonus-component-wake/index-bdc90e13.js.map +0 -1
- package/dist/crmbonus-component-wake/loading-spinner.entry.js.map +0 -1
- package/dist/crmbonus-component-wake/name-input.entry.js.map +0 -1
- package/dist/crmbonus-component-wake/pedido-finalizado.entry.js.map +0 -1
- package/dist/crmbonus-component-wake/phone-cancel-input.entry.js.map +0 -1
- package/dist/crmbonus-component-wake/phone-form.entry.js +0 -26
- package/dist/crmbonus-component-wake/phone-form.entry.js.map +0 -1
- package/dist/crmbonus-component-wake/phone-input-mask.entry.js.map +0 -1
- package/dist/crmbonus-component-wake/phone-input.entry.js.map +0 -1
- package/dist/crmbonus-component-wake/pin-form.entry.js.map +0 -1
- package/dist/crmbonus-component-wake/shadow-css-7ad5caf8.js +0 -334
- package/dist/crmbonus-component-wake/shadow-css-7ad5caf8.js.map +0 -1
- /package/dist/{crmbonus-component-wake → esm}/app-globals-0f993ce5.js +0 -0
- /package/dist/{crmbonus-component-wake → esm}/app-globals-0f993ce5.js.map +0 -0
- /package/dist/{crmbonus-component-wake → esm}/index-3c6d4feb.js +0 -0
- /package/dist/{crmbonus-component-wake → esm}/index-3c6d4feb.js.map +0 -0
- /package/dist/{crmbonus-component-wake → esm}/info.config.helper-42d9ddf9.js +0 -0
- /package/dist/{crmbonus-component-wake → esm}/info.config.helper-42d9ddf9.js.map +0 -0
package/dist/collection/components/giftback-form/subcomponents/giftback-info/giftback-info.css
ADDED
@@ -0,0 +1,154 @@
|
|
1
|
+
:host {
|
2
|
+
--text-color: #6D6D5F
|
3
|
+
}
|
4
|
+
|
5
|
+
.giftback-container {
|
6
|
+
display: flex;
|
7
|
+
flex-direction: column;
|
8
|
+
gap: 14px;
|
9
|
+
}
|
10
|
+
|
11
|
+
h3 {
|
12
|
+
font-size: 1.2rem;
|
13
|
+
margin-bottom: 8px;
|
14
|
+
color: #333;
|
15
|
+
}
|
16
|
+
|
17
|
+
.container-description p {
|
18
|
+
font-size: 14px;
|
19
|
+
font-weight: 400;
|
20
|
+
}
|
21
|
+
|
22
|
+
|
23
|
+
p {
|
24
|
+
font-size: 12px;
|
25
|
+
color: #000;
|
26
|
+
}
|
27
|
+
|
28
|
+
.value-display h2 {
|
29
|
+
color: #6D6D5F;
|
30
|
+
/* Verde para o valor atual */
|
31
|
+
font-size: 1.6rem;
|
32
|
+
margin: 16px 0;
|
33
|
+
}
|
34
|
+
|
35
|
+
input[type='range'] {
|
36
|
+
width: 100%;
|
37
|
+
margin: 12px 0;
|
38
|
+
-webkit-appearance: none;
|
39
|
+
background: #ddd;
|
40
|
+
height: 4px;
|
41
|
+
border-radius: 4px;
|
42
|
+
outline: none;
|
43
|
+
padding: 3px;
|
44
|
+
}
|
45
|
+
|
46
|
+
input[type='range']::-webkit-slider-thumb {
|
47
|
+
-webkit-appearance: none;
|
48
|
+
appearance: none;
|
49
|
+
width: 16px;
|
50
|
+
height: 16px;
|
51
|
+
background: var(--text-color);
|
52
|
+
/* Azul para o slider */
|
53
|
+
border-radius: 50%;
|
54
|
+
cursor: pointer;
|
55
|
+
}
|
56
|
+
|
57
|
+
.options {
|
58
|
+
margin: 0px 0;
|
59
|
+
display: flex;
|
60
|
+
gap: 10px;
|
61
|
+
flex-direction: column;
|
62
|
+
}
|
63
|
+
|
64
|
+
.options label {
|
65
|
+
display: block;
|
66
|
+
margin: 0px 0;
|
67
|
+
font-size: 0.9rem;
|
68
|
+
color: #333;
|
69
|
+
}
|
70
|
+
|
71
|
+
.options input[type='radio'] {
|
72
|
+
margin-right: 8px;
|
73
|
+
height: 16px;
|
74
|
+
width: 16px;
|
75
|
+
}
|
76
|
+
|
77
|
+
.options input[type='radio'] {
|
78
|
+
appearance: none;
|
79
|
+
-webkit-appearance: none;
|
80
|
+
margin-right: 8px;
|
81
|
+
width: 16px;
|
82
|
+
height: 16px;
|
83
|
+
border: 2px solid #ddd;
|
84
|
+
border-radius: 50%;
|
85
|
+
background-color: #fff;
|
86
|
+
cursor: pointer;
|
87
|
+
transition: all 0.3s;
|
88
|
+
padding: 0px;
|
89
|
+
}
|
90
|
+
|
91
|
+
.options input[type='radio']:checked {
|
92
|
+
border-color: #000;
|
93
|
+
background-color: #FAFAFA;
|
94
|
+
border: 4px solid #000;
|
95
|
+
}
|
96
|
+
|
97
|
+
.info-box {
|
98
|
+
background-color: #f9f9f9;
|
99
|
+
border: 1px solid #e0e0e0;
|
100
|
+
border-radius: 4px;
|
101
|
+
padding: 8px;
|
102
|
+
font-size: 14px;
|
103
|
+
color: #262626;
|
104
|
+
line-height: 20px;
|
105
|
+
}
|
106
|
+
|
107
|
+
.info-icon {
|
108
|
+
font-size: 0.9rem;
|
109
|
+
cursor: pointer;
|
110
|
+
color: #888;
|
111
|
+
}
|
112
|
+
|
113
|
+
h3 {
|
114
|
+
font-size: 1.2rem;
|
115
|
+
margin-bottom: 8px;
|
116
|
+
color: #333;
|
117
|
+
}
|
118
|
+
|
119
|
+
.slider-wrapper {
|
120
|
+
position: relative;
|
121
|
+
margin: 21px 0px 0px 0px;
|
122
|
+
}
|
123
|
+
|
124
|
+
.slider {
|
125
|
+
width: 100%;
|
126
|
+
-webkit-appearance: none;
|
127
|
+
background: #ddd;
|
128
|
+
height: 4px;
|
129
|
+
border-radius: 2px;
|
130
|
+
outline: none;
|
131
|
+
}
|
132
|
+
|
133
|
+
.slider::-webkit-slider-thumb {
|
134
|
+
-webkit-appearance: none;
|
135
|
+
appearance: none;
|
136
|
+
width: 16px;
|
137
|
+
height: 16px;
|
138
|
+
background: var(--text-color);
|
139
|
+
/* Azul para o slider */
|
140
|
+
border-radius: 50%;
|
141
|
+
cursor: pointer;
|
142
|
+
}
|
143
|
+
|
144
|
+
.slider-value {
|
145
|
+
position: absolute;
|
146
|
+
top: -30px;
|
147
|
+
/* Posição acima do slider */
|
148
|
+
font-size: 16px;
|
149
|
+
font-weight: 700;
|
150
|
+
color: var(--text-color);
|
151
|
+
/* Verde para o texto */
|
152
|
+
transform: translateX(-50%);
|
153
|
+
white-space: nowrap;
|
154
|
+
}
|
@@ -0,0 +1,156 @@
|
|
1
|
+
import { h } from "@stencil/core";
|
2
|
+
import i18next from "../../../../i18n/i18n";
|
3
|
+
export class GiftbackInfo {
|
4
|
+
constructor() {
|
5
|
+
this.usedValue = 0;
|
6
|
+
this.selectedOption = 'none';
|
7
|
+
this.loading = false;
|
8
|
+
this.bonus = {
|
9
|
+
totalBonus: 52,
|
10
|
+
cartId: "",
|
11
|
+
minimumPurchase: 6000,
|
12
|
+
bonusBalance: 25,
|
13
|
+
calculatedValue: 25,
|
14
|
+
firstValidityDate: "",
|
15
|
+
totalValue: 200
|
16
|
+
};
|
17
|
+
this.reserve = undefined;
|
18
|
+
this.cancel = undefined;
|
19
|
+
this.sliderPosition = 50;
|
20
|
+
}
|
21
|
+
componentWillLoad() {
|
22
|
+
this.usedValue = parseFloat(this.bonus.bonusBalance.toString());
|
23
|
+
this.buildPositionSlider(0, this.bonus.totalBonus);
|
24
|
+
}
|
25
|
+
handleSliderChange(event) {
|
26
|
+
const input = event.target;
|
27
|
+
this.usedValue = parseFloat(input.value);
|
28
|
+
// Calculando a posição do texto com base no valor do slider
|
29
|
+
// const percentage = ((this.usedValue - parseInt(input.min)) / (parseInt(input.max) - parseInt(input.min))) * 100;
|
30
|
+
// this.sliderPosition = percentage;
|
31
|
+
this.buildPositionSlider(parseFloat(input.min), parseFloat(input.max));
|
32
|
+
}
|
33
|
+
buildPositionSlider(min, max) {
|
34
|
+
// Calculando a posição do texto com base no valor do slider
|
35
|
+
const percentage = ((this.usedValue - min) / (max - min)) * 100;
|
36
|
+
this.sliderPosition = percentage;
|
37
|
+
}
|
38
|
+
async handleOptionChange(option) {
|
39
|
+
this.selectedOption = option;
|
40
|
+
switch (this.selectedOption) {
|
41
|
+
case 'use':
|
42
|
+
await this.reserve(this.usedValue);
|
43
|
+
break;
|
44
|
+
case 'dontUse':
|
45
|
+
await this.cancel();
|
46
|
+
break;
|
47
|
+
default:
|
48
|
+
}
|
49
|
+
}
|
50
|
+
render() {
|
51
|
+
const remainingGiftback = this.bonus.minimumPurchase - this.bonus.totalValue;
|
52
|
+
const translateDescription = i18next.t("giftDescription", { amount: `${this.bonus.totalBonus.toFixed(2).replace(".", ",")}`, custom_name: "Giftback" });
|
53
|
+
return (h("div", { key: 'fbc3b08d2e77fc7312ecbf24e9e785284c08ea86', class: "giftback-container" }, h("div", { key: '3717e46c93ad2dc4547a042ba159c3d28de64beb', class: "container-description" }, h("p", { key: '2acb0e117f873348cd819faec028f9d27736a106', innerHTML: translateDescription })), h("div", { key: '59c662da7f9b3070004ff7fe9a782a4714bff125', class: "slider-wrapper" }, h("div", { key: '4ed2c4049deb9d5c32f12b251cec2acd56446fa5', class: "slider-value", style: {
|
54
|
+
left: `calc(${this.sliderPosition}% - 20px)`, // Ajuste para centralizar o texto
|
55
|
+
} }, "R$ ", this.usedValue.toFixed(2).replace(".", ",")), h("input", { key: '1a73c61a7b2fc20932773b69147b27dc6ca0247b', type: "range", min: "0", max: this.bonus.totalBonus, value: this.usedValue, class: "slider", step: "0.01", onInput: (event) => this.handleSliderChange(event), style: {
|
56
|
+
background: `linear-gradient(to right, #6D6D5F ${this.sliderPosition}%, #ddd ${this.sliderPosition}%)`,
|
57
|
+
} })), h("p", { key: 'f490f6b4eb0adae75140b34e36694b49feb241ed' }, "Adicione ", h("strong", { key: 'a7b67ed94043d2d55cc9748c956c5516ce535245' }, "R$ ", remainingGiftback < 0 ? "0,00" : remainingGiftback.toFixed(2).replace(".", ",")), " ao carrinho para atingir o valor m\u00E1ximo!"), h("div", { key: 'd0ce836a492168e7f8439fbc3b1a7bca85305248', class: "options" }, h("label", { key: 'dd661987e7df0d967b4fe930c47144718d31b9f6' }, h("input", { key: '3201b786de110c3071d14af6134f61b9f1ede2c0', type: "radio", name: "giftbackOption", value: "use", checked: this.selectedOption === 'use', onChange: () => this.handleOptionChange('use') }), "Usar o meu Giftback"), h("label", { key: 'c7da572b125d4ae515e4ca026bc25815e0701712' }, h("input", { key: 'b6d1aee5626923f8cf49ae90114fb8e5c35e3fbf', type: "radio", name: "giftbackOption", value: "dontUse", checked: this.selectedOption === 'dontUse', onChange: () => this.handleOptionChange('dontUse') }), "N\u00E3o usar o meu Giftback")), h("div", { key: '577c1869fc4cb58d2817f0ab7fb2c18fae99ed66', class: "info-box" }, "O Giftback ser\u00E1 aplicado na pr\u00F3xima etapa.")));
|
58
|
+
}
|
59
|
+
static get is() { return "giftback-info"; }
|
60
|
+
static get originalStyleUrls() {
|
61
|
+
return {
|
62
|
+
"$": ["giftback-info.css"]
|
63
|
+
};
|
64
|
+
}
|
65
|
+
static get styleUrls() {
|
66
|
+
return {
|
67
|
+
"$": ["giftback-info.css"]
|
68
|
+
};
|
69
|
+
}
|
70
|
+
static get properties() {
|
71
|
+
return {
|
72
|
+
"loading": {
|
73
|
+
"type": "boolean",
|
74
|
+
"mutable": false,
|
75
|
+
"complexType": {
|
76
|
+
"original": "boolean",
|
77
|
+
"resolved": "boolean",
|
78
|
+
"references": {}
|
79
|
+
},
|
80
|
+
"required": false,
|
81
|
+
"optional": false,
|
82
|
+
"docs": {
|
83
|
+
"tags": [],
|
84
|
+
"text": ""
|
85
|
+
},
|
86
|
+
"attribute": "loading",
|
87
|
+
"reflect": false,
|
88
|
+
"defaultValue": "false"
|
89
|
+
},
|
90
|
+
"bonus": {
|
91
|
+
"type": "unknown",
|
92
|
+
"mutable": false,
|
93
|
+
"complexType": {
|
94
|
+
"original": "Partial<IBonus>",
|
95
|
+
"resolved": "{ hasBonus?: boolean; bonusBalance?: number; totalBonus?: number; minimumPurchase?: number; bonusIds?: string; firstValidityDate?: string; history?: [{ validityStart: string; validityEnd: string; value: number; }, { validityStart: string; validityEnd: string; value: number; }]; storeId?: number; userId?: number; cartId?: string; calculatedValue?: number; totalValue?: number; }",
|
96
|
+
"references": {
|
97
|
+
"Partial": {
|
98
|
+
"location": "global",
|
99
|
+
"id": "global::Partial"
|
100
|
+
},
|
101
|
+
"IBonus": {
|
102
|
+
"location": "import",
|
103
|
+
"path": "../../../../dto/validate.pin.bonus",
|
104
|
+
"id": "src/dto/validate.pin.bonus.ts::IBonus"
|
105
|
+
}
|
106
|
+
}
|
107
|
+
},
|
108
|
+
"required": false,
|
109
|
+
"optional": false,
|
110
|
+
"docs": {
|
111
|
+
"tags": [],
|
112
|
+
"text": ""
|
113
|
+
},
|
114
|
+
"defaultValue": "{\n totalBonus: 52,\n cartId: \"\",\n minimumPurchase: 6000,\n bonusBalance: 25,\n calculatedValue: 25,\n firstValidityDate: \"\",\n totalValue: 200\n }"
|
115
|
+
},
|
116
|
+
"reserve": {
|
117
|
+
"type": "unknown",
|
118
|
+
"mutable": false,
|
119
|
+
"complexType": {
|
120
|
+
"original": "(amountRedeemed: number) => void",
|
121
|
+
"resolved": "(amountRedeemed: number) => void",
|
122
|
+
"references": {}
|
123
|
+
},
|
124
|
+
"required": false,
|
125
|
+
"optional": false,
|
126
|
+
"docs": {
|
127
|
+
"tags": [],
|
128
|
+
"text": ""
|
129
|
+
}
|
130
|
+
},
|
131
|
+
"cancel": {
|
132
|
+
"type": "unknown",
|
133
|
+
"mutable": false,
|
134
|
+
"complexType": {
|
135
|
+
"original": "() => void",
|
136
|
+
"resolved": "() => void",
|
137
|
+
"references": {}
|
138
|
+
},
|
139
|
+
"required": false,
|
140
|
+
"optional": false,
|
141
|
+
"docs": {
|
142
|
+
"tags": [],
|
143
|
+
"text": ""
|
144
|
+
}
|
145
|
+
}
|
146
|
+
};
|
147
|
+
}
|
148
|
+
static get states() {
|
149
|
+
return {
|
150
|
+
"usedValue": {},
|
151
|
+
"selectedOption": {},
|
152
|
+
"sliderPosition": {}
|
153
|
+
};
|
154
|
+
}
|
155
|
+
}
|
156
|
+
//# sourceMappingURL=giftback-info.js.map
|
package/dist/collection/components/giftback-form/subcomponents/giftback-info/giftback-info.js.map
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"giftback-info.js","sourceRoot":"","sources":["../../../../../../src/components/giftback-form/subcomponents/giftback-info/giftback-info.tsx"],"names":[],"mappings":"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","sourcesContent":["import { Component, Prop, State, h } from \"@stencil/core\";\nimport { IBonus } from \"../../../../dto/validate.pin.bonus\";\n\nimport i18next from '../../../../i18n/i18n'\n\n@Component({\n tag: 'giftback-info',\n styleUrls: ['giftback-info.css']\n})\nexport class GiftbackInfo {\n @State() usedValue: number = 0;\n @State() selectedOption: string = 'none';\n\n @Prop() loading: boolean = false;\n @Prop() bonus: Partial<IBonus> = {\n totalBonus: 52,\n cartId: \"\",\n minimumPurchase: 6000,\n bonusBalance: 25,\n calculatedValue: 25,\n firstValidityDate: \"\",\n totalValue: 200\n };\n @Prop() reserve: (amountRedeemed: number) => void;\n @Prop() cancel: () => void;\n\n @State() sliderPosition: number = 50;\n\n componentWillLoad() {\n this.usedValue = parseFloat(this.bonus.bonusBalance.toString());\n\n this.buildPositionSlider(0, this.bonus.totalBonus);\n }\n\n handleSliderChange(event: Event) {\n const input = event.target as HTMLInputElement;\n this.usedValue = parseFloat(input.value);\n\n // Calculando a posição do texto com base no valor do slider\n // const percentage = ((this.usedValue - parseInt(input.min)) / (parseInt(input.max) - parseInt(input.min))) * 100;\n // this.sliderPosition = percentage;\n\n this.buildPositionSlider(parseFloat(input.min), parseFloat(input.max))\n }\n\n\n private buildPositionSlider(min:number, max: number) {\n // Calculando a posição do texto com base no valor do slider\n const percentage = ((this.usedValue - min) / (max - min)) * 100;\n this.sliderPosition = percentage;\n }\n\n async handleOptionChange(option: string) {\n this.selectedOption = option;\n switch (this.selectedOption) {\n case 'use':\n await this.reserve(this.usedValue)\n break;\n case 'dontUse':\n await this.cancel()\n break;\n default:\n }\n }\n render() {\n const remainingGiftback = this.bonus.minimumPurchase - this.bonus.totalValue;\n\n const translateDescription = i18next.t(\"giftDescription\", { amount: `${this.bonus.totalBonus.toFixed(2).replace(\".\", \",\")}`, custom_name: \"Giftback\" })\n\n return (\n\n <div class=\"giftback-container\">\n <div class=\"container-description\">\n <p innerHTML={translateDescription}></p>\n </div>\n <div class=\"slider-wrapper\">\n <div\n class=\"slider-value\"\n style={{\n left: `calc(${this.sliderPosition}% - 20px)`, // Ajuste para centralizar o texto\n }}\n >\n R$ {this.usedValue.toFixed(2).replace(\".\", \",\")}\n </div>\n <input\n type=\"range\"\n min=\"0\"\n max={this.bonus.totalBonus}\n value={this.usedValue}\n class=\"slider\"\n step=\"0.01\"\n onInput={(event) => this.handleSliderChange(event)}\n style={{\n background: `linear-gradient(to right, #6D6D5F ${this.sliderPosition}%, #ddd ${this.sliderPosition}%)`,\n }}\n />\n </div>\n <p>\n Adicione <strong>R$ {remainingGiftback < 0 ? \"0,00\" : remainingGiftback.toFixed(2).replace(\".\", \",\")}</strong> ao carrinho para atingir o valor\n máximo!\n </p>\n <div class=\"options\">\n <label>\n <input\n type=\"radio\"\n name=\"giftbackOption\"\n value=\"use\"\n checked={this.selectedOption === 'use'}\n onChange={() => this.handleOptionChange('use')}\n />\n Usar o meu Giftback\n </label>\n <label>\n <input\n type=\"radio\"\n name=\"giftbackOption\"\n value=\"dontUse\"\n checked={this.selectedOption === 'dontUse'}\n onChange={() => this.handleOptionChange('dontUse')}\n />\n Não usar o meu Giftback\n </label>\n </div>\n <div class=\"info-box\">\n O Giftback será aplicado na próxima etapa.\n </div>\n </div>\n );\n }\n}"]}
|
package/dist/collection/components/giftback-form/subcomponents/giftback-message/giftback-massage.js
ADDED
@@ -0,0 +1,11 @@
|
|
1
|
+
import { Component, Host, h } from "@stencil/core";
|
2
|
+
Component({
|
3
|
+
tag: 'giftback-message',
|
4
|
+
styleUrls: ['giftback-message.css']
|
5
|
+
});
|
6
|
+
export class GiftbackMessage {
|
7
|
+
render() {
|
8
|
+
return (h(Host, { class: "container-message" }, h("h1", null, "Voc\u00EA n\u00E3o possui Giftback dispon\u00EDvel para essa compra.")));
|
9
|
+
}
|
10
|
+
}
|
11
|
+
//# sourceMappingURL=giftback-massage.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"giftback-massage.js","sourceRoot":"","sources":["../../../../../../src/components/giftback-form/subcomponents/giftback-message/giftback-massage.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,eAAe,CAAA;AAElD,SAAS,CAAC;IACN,GAAG,EAAE,kBAAkB;IACvB,SAAS,EAAE,CAAC,sBAAsB,CAAC;CACtC,CAAC,CAAA;AACF,MAAM,OAAO,eAAe;IACxB,MAAM;QACF,OAAO,CACH,EAAC,IAAI,IAAC,KAAK,EAAC,mBAAmB;YAC3B,qFAA8D,CAC3D,CACV,CAAA;IACL,CAAC;CACJ","sourcesContent":["import { Component, Host, h } from \"@stencil/core\"\n\nComponent({\n tag: 'giftback-message',\n styleUrls: ['giftback-message.css']\n})\nexport class GiftbackMessage {\n render() {\n return (\n <Host class=\"container-message\">\n <h1>Você não possui Giftback disponível para essa compra.</h1>\n </Host>\n )\n }\n}"]}
|
@@ -0,0 +1,103 @@
|
|
1
|
+
import { Host, h } from "@stencil/core";
|
2
|
+
export class PhoneForm {
|
3
|
+
constructor() {
|
4
|
+
this.value = undefined;
|
5
|
+
this.loading = undefined;
|
6
|
+
this.handlerSubmit = undefined;
|
7
|
+
this.config = undefined;
|
8
|
+
}
|
9
|
+
async handlePhone() {
|
10
|
+
const phone = await this.phoneInputMask.getPhone();
|
11
|
+
await this.handlerSubmit(phone);
|
12
|
+
}
|
13
|
+
render() {
|
14
|
+
var _a;
|
15
|
+
return (h(Host, { key: 'a1fa8f1b45d663be5a434ac12af569100ad05f99', class: "crm-phone-form" }, h("label", { key: 'b374c22ba75e76f482379a7bfc1d1c202e72d9a9', class: "crm-subtitle" }, "Digite o seu celular para verificar se h\u00E1 desconto dispon\u00EDvel nessa compra"), h("phone-input-mask", { key: 'f0816190a397e74a9afb6fc3fe90ee3b00eab3be', initialValue: this.value, ref: ref => this.phoneInputMask = ref }), h("crm-button", { key: '1102ce8d88adf95fb46e3e1eaaa34830ecaa0be5', txtBtn: ((_a = this.config) === null || _a === void 0 ? void 0 : _a.btnApplyBonusLabel) || "Avançar", loading: this.loading, onClick: () => this.handlePhone() })));
|
16
|
+
}
|
17
|
+
static get is() { return "phone-form"; }
|
18
|
+
static get originalStyleUrls() {
|
19
|
+
return {
|
20
|
+
"$": ["../../giftback-form.css"]
|
21
|
+
};
|
22
|
+
}
|
23
|
+
static get styleUrls() {
|
24
|
+
return {
|
25
|
+
"$": ["../../giftback-form.css"]
|
26
|
+
};
|
27
|
+
}
|
28
|
+
static get properties() {
|
29
|
+
return {
|
30
|
+
"value": {
|
31
|
+
"type": "string",
|
32
|
+
"mutable": false,
|
33
|
+
"complexType": {
|
34
|
+
"original": "string",
|
35
|
+
"resolved": "string",
|
36
|
+
"references": {}
|
37
|
+
},
|
38
|
+
"required": false,
|
39
|
+
"optional": false,
|
40
|
+
"docs": {
|
41
|
+
"tags": [],
|
42
|
+
"text": ""
|
43
|
+
},
|
44
|
+
"attribute": "value",
|
45
|
+
"reflect": false
|
46
|
+
},
|
47
|
+
"loading": {
|
48
|
+
"type": "boolean",
|
49
|
+
"mutable": false,
|
50
|
+
"complexType": {
|
51
|
+
"original": "boolean",
|
52
|
+
"resolved": "boolean",
|
53
|
+
"references": {}
|
54
|
+
},
|
55
|
+
"required": false,
|
56
|
+
"optional": false,
|
57
|
+
"docs": {
|
58
|
+
"tags": [],
|
59
|
+
"text": ""
|
60
|
+
},
|
61
|
+
"attribute": "loading",
|
62
|
+
"reflect": false
|
63
|
+
},
|
64
|
+
"handlerSubmit": {
|
65
|
+
"type": "unknown",
|
66
|
+
"mutable": false,
|
67
|
+
"complexType": {
|
68
|
+
"original": "(phone: string) => void",
|
69
|
+
"resolved": "(phone: string) => void",
|
70
|
+
"references": {}
|
71
|
+
},
|
72
|
+
"required": false,
|
73
|
+
"optional": false,
|
74
|
+
"docs": {
|
75
|
+
"tags": [],
|
76
|
+
"text": ""
|
77
|
+
}
|
78
|
+
},
|
79
|
+
"config": {
|
80
|
+
"type": "unknown",
|
81
|
+
"mutable": false,
|
82
|
+
"complexType": {
|
83
|
+
"original": "IInfoStore",
|
84
|
+
"resolved": "IInfoStore",
|
85
|
+
"references": {
|
86
|
+
"IInfoStore": {
|
87
|
+
"location": "import",
|
88
|
+
"path": "../../../../helpers/info.config.helper",
|
89
|
+
"id": "src/helpers/info.config.helper.ts::IInfoStore"
|
90
|
+
}
|
91
|
+
}
|
92
|
+
},
|
93
|
+
"required": false,
|
94
|
+
"optional": false,
|
95
|
+
"docs": {
|
96
|
+
"tags": [],
|
97
|
+
"text": ""
|
98
|
+
}
|
99
|
+
}
|
100
|
+
};
|
101
|
+
}
|
102
|
+
}
|
103
|
+
//# sourceMappingURL=phone-form.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"phone-form.js","sourceRoot":"","sources":["../../../../../../src/components/giftback-form/subcomponents/phone-form/phone-form.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,eAAe,CAAC;AAOzD,MAAM,OAAO,SAAS;;;;;;;IAWlB,KAAK,CAAC,WAAW;QAEb,MAAM,KAAK,GAAG,MAAM,IAAI,CAAC,cAAc,CAAC,QAAQ,EAAE,CAAA;QAElD,MAAM,IAAI,CAAC,aAAa,CAAC,KAAK,CAAC,CAAC;IACpC,CAAC;IAGD,MAAM;;QACF,OAAO,CACH,EAAC,IAAI,qDAAC,KAAK,EAAC,gBAAgB;YACxB,8DAAO,KAAK,EAAC,cAAc,2FAAoF;YAC/G,yEAAkB,YAAY,EAAE,IAAI,CAAC,KAAK,EAAE,GAAG,EAAE,GAAG,CAAC,EAAE,CAAC,IAAI,CAAC,cAAc,GAAG,GAAG,GAAI;YAErF,mEAAY,MAAM,EAAE,CAAA,MAAA,IAAI,CAAC,MAAM,0CAAE,kBAAkB,KAAI,SAAS,EAAE,OAAO,EAAE,IAAI,CAAC,OAAO,EAAE,OAAO,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,WAAW,EAAE,GAAK,CAC5H,CACV,CAAA;IACL,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACJ","sourcesContent":["import { Component, Host, Prop, h } from \"@stencil/core\";\nimport { IInfoStore } from \"../../../../helpers/info.config.helper\";\n\n@Component({\n tag: 'phone-form',\n styleUrl: '../../giftback-form.css'\n})\nexport class PhoneForm {\n\n private phoneInputMask: HTMLPhoneInputMaskElement;\n\n @Prop() value: string;\n @Prop() loading: boolean;\n @Prop() handlerSubmit: (phone: string) => void;\n\n @Prop() config: IInfoStore;\n\n\n async handlePhone() {\n\n const phone = await this.phoneInputMask.getPhone()\n\n await this.handlerSubmit(phone);\n }\n\n\n render() {\n return (\n <Host class=\"crm-phone-form\">\n <label class=\"crm-subtitle\" >Digite o seu celular para verificar se há desconto disponível nessa compra</label>\n <phone-input-mask initialValue={this.value} ref={ref => this.phoneInputMask = ref} />\n\n <crm-button txtBtn={this.config?.btnApplyBonusLabel || \"Avançar\"} loading={this.loading} onClick={() => this.handlePhone() } />\n </Host>\n )\n }\n}"]}
|
@@ -0,0 +1,84 @@
|
|
1
|
+
:host {
|
2
|
+
display: block;
|
3
|
+
font-family: Arial, sans-serif;
|
4
|
+
}
|
5
|
+
|
6
|
+
.form-container-pin {
|
7
|
+
display: flex;
|
8
|
+
flex-direction: column;
|
9
|
+
align-items: center;
|
10
|
+
}
|
11
|
+
|
12
|
+
.pin-container {
|
13
|
+
display: flex;
|
14
|
+
/* margin: 26px 0; */
|
15
|
+
justify-content: start;
|
16
|
+
gap: 10px;
|
17
|
+
}
|
18
|
+
|
19
|
+
input {
|
20
|
+
width: 40px;
|
21
|
+
height: 48px;
|
22
|
+
font-size: 14px;
|
23
|
+
text-align: center;
|
24
|
+
border: 1px solid #ccc;
|
25
|
+
border-radius: 5px;
|
26
|
+
}
|
27
|
+
|
28
|
+
button {
|
29
|
+
padding: 10px 20px;
|
30
|
+
background-color: #ddd;
|
31
|
+
border: none;
|
32
|
+
border-radius: 5px;
|
33
|
+
cursor: pointer;
|
34
|
+
}
|
35
|
+
|
36
|
+
|
37
|
+
.success {
|
38
|
+
color: green;
|
39
|
+
margin-top: 10px;
|
40
|
+
}
|
41
|
+
|
42
|
+
.button {
|
43
|
+
top: 50%;
|
44
|
+
background-color: #6c6c7e;
|
45
|
+
color: #fff;
|
46
|
+
border: none;
|
47
|
+
border-radius: 10px;
|
48
|
+
padding: 15px;
|
49
|
+
min-height: 30px;
|
50
|
+
min-width: 120px;
|
51
|
+
font-size: 20px;
|
52
|
+
cursor: pointer;
|
53
|
+
}
|
54
|
+
|
55
|
+
.button-cancel {
|
56
|
+
top: 50%;
|
57
|
+
background-color: #ffffff;
|
58
|
+
color: #1e1c1c;
|
59
|
+
border: 1px solid gray;
|
60
|
+
border-radius: 10px;
|
61
|
+
padding: 10px;
|
62
|
+
min-height: 30px;
|
63
|
+
min-width: 120px;
|
64
|
+
font-size: 19px;
|
65
|
+
cursor: pointer;
|
66
|
+
}
|
67
|
+
|
68
|
+
.crm-description {
|
69
|
+
font-size: 14px;
|
70
|
+
width: 100%;
|
71
|
+
display: flex;
|
72
|
+
gap: 9px;
|
73
|
+
}
|
74
|
+
|
75
|
+
.crm-description a {
|
76
|
+
font-weight: bold;
|
77
|
+
cursor: pointer;
|
78
|
+
text-decoration: underline;
|
79
|
+
}
|
80
|
+
|
81
|
+
.crm-description div {
|
82
|
+
display: flex;
|
83
|
+
gap: 5px;
|
84
|
+
}
|