Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@plurix/coupons

Package Overview
Dependencies
Maintainers
3
Versions
53
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@plurix/coupons - npm Package Compare versions

Comparing version 0.2.12 to 0.2.13

2

dist/coupons.cjs.development.js

@@ -68,3 +68,3 @@ 'use strict';

return React.createElement("div", {
className: "container-card-coupon " + (isApplyCoupon && 'active')
className: "container-card-coupon " + (isApplyCoupon ? 'active' : '')
}, React.createElement("div", {

@@ -71,0 +71,0 @@ className: "text-container"

@@ -1,2 +0,2 @@

"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e,t=(e=require("react"))&&"object"==typeof e&&"default"in e?e.default:e,l=function(e){var l=e.width,a=e.height;return t.createElement("svg",{width:void 0===l?20:l,height:void 0===a?16:a,viewBox:"0 0 20 16",fill:"none",xmlns:"http://www.w3.org/2000/svg","data-testid":"cupon-icon"},t.createElement("path",{d:"M1.5 16C1.1 16 0.75 15.85 0.45 15.55C0.15 15.25 0 14.9 0 14.5V10.675C0.616667 10.5417 1.12917 10.2208 1.5375 9.7125C1.94583 9.20417 2.15 8.63333 2.15 8C2.15 7.36667 1.94583 6.79167 1.5375 6.275C1.12917 5.75833 0.616667 5.44167 0 5.325V1.5C0 1.1 0.15 0.75 0.45 0.45C0.75 0.15 1.1 0 1.5 0H18.5C18.9 0 19.25 0.15 19.55 0.45C19.85 0.75 20 1.1 20 1.5V5.325C19.3833 5.44167 18.875 5.75833 18.475 6.275C18.075 6.79167 17.875 7.36667 17.875 8C17.875 8.63333 18.075 9.20417 18.475 9.7125C18.875 10.2208 19.3833 10.5417 20 10.675V14.5C20 14.9 19.85 15.25 19.55 15.55C19.25 15.85 18.9 16 18.5 16H1.5ZM1.5 14.5H18.5V11.775C17.9 11.3583 17.3958 10.8208 16.9875 10.1625C16.5792 9.50417 16.375 8.78333 16.375 8C16.375 7.21667 16.5792 6.49583 16.9875 5.8375C17.3958 5.17917 17.9 4.64167 18.5 4.225V1.5H1.5V4.225C2.1 4.64167 2.60833 5.17917 3.025 5.8375C3.44167 6.49583 3.65 7.21667 3.65 8C3.65 8.78333 3.44167 9.50417 3.025 10.1625C2.60833 10.8208 2.1 11.3583 1.5 11.775V14.5ZM7.4 12.05L10 10.025L12.6 12.05L11.6 8.85L14.05 6.8H11.05L10 3.75L8.95 6.8H5.95L8.4 8.85L7.4 12.05Z",fill:"var(--color-main)"}))},a=function(e){var l=e.width,a=e.height;return t.createElement("svg",{width:void 0===l?18:l,height:void 0===a?18:a,viewBox:"0 0 18 18",fill:"none",xmlns:"http://www.w3.org/2000/svg","data-testid":"success-icon"},t.createElement("path",{d:"M9 17A8 8 0 1 0 9 1a8 8 0 0 0 0 16Z",fill:"var(--color-positiveFeedback)",stroke:"var(--color-positiveFeedback)",strokeWidth:1.2,strokeLinecap:"round",strokeLinejoin:"round"}),t.createElement("path",{d:"m5 9 2.667 2.667L13 6.334",stroke:"var(--color-grayScale-white)",strokeWidth:1.2,strokeLinecap:"round",strokeLinejoin:"round"}))},n=function(e){var l=e.color;return t.createElement("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg","data-testid":"error-icon"},t.createElement("circle",{cx:"8",cy:"8",r:"8",fill:null!=l?l:"var(--color-negativeFeedback-light)"}),t.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M5.48082 6.19357C5.28406 5.99682 5.28406 5.67782 5.48082 5.48106C5.67757 5.28431 5.99657 5.28431 6.19333 5.48106L7.99995 7.28768L9.80657 5.48106C10.0033 5.28431 10.3223 5.28431 10.5191 5.48106C10.7158 5.67782 10.7158 5.99682 10.5191 6.19357L8.71246 8.00019L10.519 9.80675C10.7158 10.0035 10.7158 10.3225 10.519 10.5193C10.3223 10.716 10.0033 10.716 9.80651 10.5193L7.99995 8.7127L6.19339 10.5193C5.99663 10.716 5.67763 10.716 5.48088 10.5193C5.28412 10.3225 5.28412 10.0035 5.48088 9.80675L7.28744 8.00019L5.48082 6.19357Z",fill:"white"}))},o=function(e){var l=e.color;return t.createElement("svg",{width:"1em",height:"1em",fill:"none",xmlns:"http://www.w3.org/2000/svg","data-testid":"close"},t.createElement("path",{d:"m12 4-8 8M4 4l8 8",stroke:null!=l?l:"var(--color-grayScale)",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}))},r=function(){return t.createElement("svg",{width:"244",height:"238",viewBox:"0 0 244 238",fill:"none",xmlns:"http://www.w3.org/2000/svg","data-testid":"no-coupons-icon"},t.createElement("g",{clipPath:"url(#clip0_26761_18544)"},t.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M26.482 150.19C22.1336 125.874 37.9324 104.456 50.0396 82.9455C62.6056 60.62 72.6499 34.527 96.628 25.5648C122.436 15.9186 151.867 21.7914 175.456 36.0686C198.894 50.2543 213.275 74.4716 220.932 100.799C228.91 128.231 234.847 159.974 218.242 183.189C202.232 205.572 170.376 204.483 143.304 209.326C119.197 213.639 94.4892 220.307 72.6245 209.239C49.4706 197.518 31.0545 175.759 26.482 150.19Z",fill:"#F5F5F5"}),t.createElement("path",{d:"M130.149 24.7279L212.957 85.3986C211.35 86.0845 209.527 86.4389 207.604 86.3497L50.7152 79.1039C48.0165 78.9797 45.5868 78.0022 43.748 76.4774L105.326 25.3523C112.012 19.8017 123.047 19.524 130.149 24.7279Z",fill:"#7D97F4"}),t.createElement("path",{d:"M48.0411 188.468L204.902 189C211 189 215.942 184.62 215.942 179.215V92.057C215.942 86.8639 211.365 82.5757 205.515 82.2874L48.6576 74.5381C42.09 74.2131 36.6611 79.0181 37.0165 84.8401V179.215C37.3373 184.405 42.1781 188.468 48.0411 188.468Z",fill:"#404583"}),t.createElement("path",{d:"M125.86 136.408L43.3027 75.4704C44.9116 74.789 46.7361 74.4424 48.6574 74.5376L205.518 82.2866C208.214 82.4186 210.639 83.4035 212.473 84.9346L150.684 135.863C143.977 141.391 132.942 141.633 125.86 136.408Z",fill:"#7D97F4"}),t.createElement("mask",{id:"mask0_26761_18544",style:{maskType:"luminance"},maskUnits:"userSpaceOnUse",x:"45",y:"28",width:"167",height:"113"},t.createElement("path",{d:"M125.861 136.408L45.9427 77.4203C44.6981 76.4998 45.3265 74.7124 46.9381 74.5698C47.5007 74.5207 48.0754 28.1225 48.6588 28.1517L205.518 35.9008C207.387 35.9928 209.127 82.8804 210.628 83.6889C211.649 84.2382 211.769 85.5146 210.895 86.2357L150.685 135.862C143.977 141.391 132.943 141.633 125.861 136.408Z",fill:"var(--color-neutral-0)"})),t.createElement("g",{mask:"url(#mask0_26761_18544)"},t.createElement("path",{d:"M75.5508 152.414H179.874V47.3704C179.874 43.351 176.336 40.0294 171.806 39.7978L84.6009 35.344C79.6884 35.0939 75.5508 38.5567 75.5508 42.9167V152.414Z",fill:"#BDD0FB"}),t.createElement("path",{d:"M85.5327 48.37L86.7364 84.0735L86.9227 89.6014C86.9284 90.324 87.599 90.9099 88.4158 90.9054L168.526 90.4665C169.342 90.4619 170.004 89.8683 169.999 89.1457L170.053 83.6166L170.383 48.3411C170.377 47.6185 169.408 46.2147 167.651 46.3312L89.3415 44.9642C88.3184 44.9475 87.3325 45.3003 86.6132 45.9447C85.8938 46.589 85.5041 47.465 85.5327 48.37Z",fill:"#91B3FA"}),t.createElement("path",{d:"M137.357 74.161C137.357 76.025 137.495 77.3813 137.766 78.2328C138.038 79.0841 138.494 79.5107 139.129 79.5107C139.765 79.5107 140.223 79.0841 140.511 78.2328C140.799 77.3813 140.943 76.025 140.943 74.161C140.943 72.297 140.796 70.9437 140.5 70.0985C140.204 69.2547 139.748 68.8312 139.129 68.8312C138.508 68.8312 138.06 69.2547 137.777 70.0985C137.498 70.9437 137.357 72.297 137.357 74.161ZM145.775 74.1213C145.775 77.1513 145.2 79.4494 144.051 81.0189C142.903 82.5867 141.244 83.3706 139.083 83.3706C136.814 83.3706 135.155 82.6035 134.101 81.068C133.051 79.5338 132.524 77.2446 132.524 74.2009C132.524 71.1986 133.067 68.9019 134.148 67.3139C135.228 65.7247 136.873 64.9299 139.083 64.9299C143.544 64.9299 145.775 67.9936 145.775 74.1213ZM138.766 53.6092L125.061 83.0087H120.361L134.023 53.6092H138.766ZM118.206 62.417C118.206 64.281 118.344 65.6371 118.616 66.4886C118.887 67.3401 119.343 67.7665 119.978 67.7665C120.614 67.7665 121.073 67.3401 121.36 66.4886C121.648 65.6371 121.792 64.281 121.792 62.417C121.792 60.5527 121.645 59.1966 121.349 58.3451C121.054 57.4936 120.597 57.0672 119.978 57.0672C119.343 57.0672 118.887 57.4936 118.616 58.3451C118.344 59.1966 118.206 60.5527 118.206 62.417ZM126.624 62.377C126.624 65.407 126.054 67.7083 124.911 69.2838C123.771 70.8595 122.11 71.6463 119.93 71.6463C117.676 71.6463 116.02 70.8764 114.961 69.3345C113.902 67.7927 113.373 65.5006 113.373 62.4567C113.373 56.2771 115.559 53.1857 119.93 53.1857C124.393 53.1857 126.624 56.2494 126.624 62.377Z",fill:"var(--color-neutral-0)"}),t.createElement("path",{d:"M88.7641 46.273L88.4028 45.285C88.833 45.1592 89.2889 45.0964 89.7476 45.0964H89.8308L93.2459 45.1546L93.223 46.1947L89.805 46.1366C89.4208 46.1119 89.0824 46.1826 88.7641 46.273ZM102.565 46.3543L97.894 46.2745L97.9169 45.2359L102.588 45.3157L102.565 46.3543ZM111.907 46.5155L107.236 46.4341L107.259 45.3955L111.93 45.4753L111.907 46.5155ZM121.249 46.6751L116.578 46.5952L116.601 45.5551L121.272 45.6349L121.249 46.6751ZM130.591 46.8346L125.92 46.7548L125.943 45.7162L130.614 45.796L130.591 46.8346ZM139.933 46.9958L135.262 46.9144L135.285 45.8758L139.956 45.9556L139.933 46.9958ZM149.275 47.1553L144.604 47.0756L144.627 46.0351L149.298 46.115L149.275 47.1553ZM158.614 47.3149L153.946 47.2352L153.969 46.1963L158.64 46.2745L158.614 47.3149ZM167.876 47.4804C167.724 47.459 167.563 47.4529 167.394 47.4636L163.288 47.3945L163.311 46.3559L167.366 46.425C167.397 46.4219 167.477 46.4189 167.558 46.4189C167.727 46.4189 167.896 46.4311 168.062 46.4542L167.876 47.4804ZM85.6014 53.0956L85.458 48.9563L86.0458 48.921L86.6308 48.9241L86.7713 53.0633L85.6014 53.0956ZM170.594 54.3139L169.422 54.3045L169.462 50.1637L170.634 50.1729L170.594 54.3139ZM85.8824 61.3725L85.7419 57.2333L86.9118 57.2025L87.0552 61.3402L85.8824 61.3725ZM170.514 62.5951L169.344 62.586L169.381 58.4452L170.554 58.4544L170.514 62.5951ZM86.1634 69.6495L86.0229 65.5102L87.1956 65.4795L87.3362 69.6187L86.1634 69.6495ZM170.437 70.8754L169.264 70.866L169.301 66.7252L170.474 66.7344L170.437 70.8754ZM86.4444 77.9264L86.3039 73.7887L87.4767 73.7564L87.6172 77.8956L86.4444 77.9264ZM170.356 79.1553L169.184 79.1459L169.224 75.0067L170.397 75.0143L170.356 79.1553ZM86.7254 86.2033L86.5849 82.0656L87.7577 82.0333L87.8982 86.1726L86.7254 86.2033ZM170.276 87.4369L169.103 87.4274L169.143 83.3373L169.731 83.2915L170.316 83.2961L170.276 87.4369ZM162.64 90.5789L162.634 89.5385L167.305 89.5141L167.311 90.5527L162.64 90.5789ZM153.295 90.6295L153.29 89.5908L157.961 89.5647L157.969 90.6048L153.295 90.6295ZM143.953 90.6815L143.947 89.6414L148.619 89.6168L148.624 90.6554L143.953 90.6815ZM134.608 90.7321L134.603 89.692L139.274 89.6673L139.282 90.706L134.608 90.7321ZM125.266 90.7827L125.261 89.7441L129.932 89.7182L129.937 90.7583L125.266 90.7827ZM115.921 90.835L115.916 89.7949L120.587 89.7702L120.595 90.8089L115.921 90.835ZM106.579 90.8856L106.574 89.847L111.245 89.8208L111.25 90.8594L106.579 90.8856ZM97.2345 90.9377L97.2287 89.8976L101.9 89.8714L101.908 90.9118L97.2345 90.9377ZM88.896 90.9822C88.4229 90.9822 87.9641 90.8411 87.5971 90.5835L88.3283 89.7687C88.4889 89.8838 88.6839 89.9436 88.8903 89.9436L92.5549 89.9237L92.5635 90.9624L88.896 90.9822Z",fill:"var(--color-neutral-0)"}))),t.createElement("defs",null,t.createElement("clipPath",{id:"clip0_26761_18544"},t.createElement("rect",{width:"242.574",height:"237.513",fill:"var(--color-neutral-0)",transform:"translate(0.712891)"}))))};exports.AppliedCoupon=function(e){var l=e.type;return"success"===l?t.createElement("div",{className:"applied-coupon-bagde succes-coupon"},t.createElement("span",null,t.createElement(a,null)),"Cupom aplicado com sucesso"):"removed"===l?t.createElement("div",{className:"applied-coupon-bagde succes-coupon"},t.createElement("span",null,t.createElement(a,null)),"Cupom removido com sucesso"):t.createElement("div",{className:"applied-coupon-bagde error-coupon"},t.createElement("span",null,t.createElement(n,null)),"error"===l?"Não foi possivel aplicar o cupom. Tente aplicar mais tarde.":"Cupom expirado ou incorreto")},exports.CouponCard=function(e){var n=e.item,o=e.loading,r=e.isApplyCoupon,c=e.setActiveRule,i=e.setDataItem,s=e.handleApplyCoupon,L=e.handleRemoveCoupon;return t.createElement("div",{className:"container-card-coupon "+(r&&"active")},t.createElement("div",{className:"text-container"},t.createElement("div",{className:"container-title"},t.createElement(l,{width:20,height:16}),t.createElement("p",{className:"title"},n.couponName)),n.couponValue&&t.createElement("p",{className:"price-babge"},"- ",n.couponValue),n.couponDescription&&t.createElement("p",{className:"subtitle"},n.couponDescription),n.couponExpirationDate&&t.createElement("p",{className:"subtitle"},"Válido até ",n.couponExpirationDate)),t.createElement("div",{className:"vertical-line"}),t.createElement("div",{className:"buttons-container"},r&&t.createElement("button",{className:"applied-coupon"},t.createElement("span",{className:"applied-coupon-span"},t.createElement(a,null)),"Aplicado"),r?t.createElement("button",{onClick:function(){return L(n.couponName)},className:"remove-coupon",disabled:o},"Remover"):t.createElement("button",{onClick:function(){return s(n.couponName)},className:"apply-coupon",disabled:o},"Aplicar"),n.couponDescription&&t.createElement("a",{onClick:function(){c(!0),i(n)}},"Ver Regras")))},exports.ModalRules=function(e){var l=e.children,a=e.setCloseX;return t.createElement("div",{className:"modal-rule-coupon-external"},t.createElement("div",{className:"modal-rule-coupon-internal"},t.createElement("div",{className:"modal-rule-coupon-title"},t.createElement("h1",{className:"modal-rule-coupon-title-h1"},e.title),t.createElement("span",{className:".modal-rule-coupon-title-span",onClick:function(){return a(!1)}},t.createElement(o,null))),t.createElement("div",{className:"modal-rule-coupon-children"},l)))},exports.NoCoupons=function(){return t.createElement("div",{className:"noCoupons"},t.createElement("h1",{className:"noCoupons-h1"},"Não há cupons disponíveis no momento"),t.createElement("p",{className:"noCoupons-p"},"Aqui você verá todos os cupons disponíveis para aplicar"),t.createElement(r,null))};
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e,t=(e=require("react"))&&"object"==typeof e&&"default"in e?e.default:e,l=function(e){var l=e.width,a=e.height;return t.createElement("svg",{width:void 0===l?20:l,height:void 0===a?16:a,viewBox:"0 0 20 16",fill:"none",xmlns:"http://www.w3.org/2000/svg","data-testid":"cupon-icon"},t.createElement("path",{d:"M1.5 16C1.1 16 0.75 15.85 0.45 15.55C0.15 15.25 0 14.9 0 14.5V10.675C0.616667 10.5417 1.12917 10.2208 1.5375 9.7125C1.94583 9.20417 2.15 8.63333 2.15 8C2.15 7.36667 1.94583 6.79167 1.5375 6.275C1.12917 5.75833 0.616667 5.44167 0 5.325V1.5C0 1.1 0.15 0.75 0.45 0.45C0.75 0.15 1.1 0 1.5 0H18.5C18.9 0 19.25 0.15 19.55 0.45C19.85 0.75 20 1.1 20 1.5V5.325C19.3833 5.44167 18.875 5.75833 18.475 6.275C18.075 6.79167 17.875 7.36667 17.875 8C17.875 8.63333 18.075 9.20417 18.475 9.7125C18.875 10.2208 19.3833 10.5417 20 10.675V14.5C20 14.9 19.85 15.25 19.55 15.55C19.25 15.85 18.9 16 18.5 16H1.5ZM1.5 14.5H18.5V11.775C17.9 11.3583 17.3958 10.8208 16.9875 10.1625C16.5792 9.50417 16.375 8.78333 16.375 8C16.375 7.21667 16.5792 6.49583 16.9875 5.8375C17.3958 5.17917 17.9 4.64167 18.5 4.225V1.5H1.5V4.225C2.1 4.64167 2.60833 5.17917 3.025 5.8375C3.44167 6.49583 3.65 7.21667 3.65 8C3.65 8.78333 3.44167 9.50417 3.025 10.1625C2.60833 10.8208 2.1 11.3583 1.5 11.775V14.5ZM7.4 12.05L10 10.025L12.6 12.05L11.6 8.85L14.05 6.8H11.05L10 3.75L8.95 6.8H5.95L8.4 8.85L7.4 12.05Z",fill:"var(--color-main)"}))},a=function(e){var l=e.width,a=e.height;return t.createElement("svg",{width:void 0===l?18:l,height:void 0===a?18:a,viewBox:"0 0 18 18",fill:"none",xmlns:"http://www.w3.org/2000/svg","data-testid":"success-icon"},t.createElement("path",{d:"M9 17A8 8 0 1 0 9 1a8 8 0 0 0 0 16Z",fill:"var(--color-positiveFeedback)",stroke:"var(--color-positiveFeedback)",strokeWidth:1.2,strokeLinecap:"round",strokeLinejoin:"round"}),t.createElement("path",{d:"m5 9 2.667 2.667L13 6.334",stroke:"var(--color-grayScale-white)",strokeWidth:1.2,strokeLinecap:"round",strokeLinejoin:"round"}))},n=function(e){var l=e.color;return t.createElement("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg","data-testid":"error-icon"},t.createElement("circle",{cx:"8",cy:"8",r:"8",fill:null!=l?l:"var(--color-negativeFeedback-light)"}),t.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M5.48082 6.19357C5.28406 5.99682 5.28406 5.67782 5.48082 5.48106C5.67757 5.28431 5.99657 5.28431 6.19333 5.48106L7.99995 7.28768L9.80657 5.48106C10.0033 5.28431 10.3223 5.28431 10.5191 5.48106C10.7158 5.67782 10.7158 5.99682 10.5191 6.19357L8.71246 8.00019L10.519 9.80675C10.7158 10.0035 10.7158 10.3225 10.519 10.5193C10.3223 10.716 10.0033 10.716 9.80651 10.5193L7.99995 8.7127L6.19339 10.5193C5.99663 10.716 5.67763 10.716 5.48088 10.5193C5.28412 10.3225 5.28412 10.0035 5.48088 9.80675L7.28744 8.00019L5.48082 6.19357Z",fill:"white"}))},o=function(e){var l=e.color;return t.createElement("svg",{width:"1em",height:"1em",fill:"none",xmlns:"http://www.w3.org/2000/svg","data-testid":"close"},t.createElement("path",{d:"m12 4-8 8M4 4l8 8",stroke:null!=l?l:"var(--color-grayScale)",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}))},r=function(){return t.createElement("svg",{width:"244",height:"238",viewBox:"0 0 244 238",fill:"none",xmlns:"http://www.w3.org/2000/svg","data-testid":"no-coupons-icon"},t.createElement("g",{clipPath:"url(#clip0_26761_18544)"},t.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M26.482 150.19C22.1336 125.874 37.9324 104.456 50.0396 82.9455C62.6056 60.62 72.6499 34.527 96.628 25.5648C122.436 15.9186 151.867 21.7914 175.456 36.0686C198.894 50.2543 213.275 74.4716 220.932 100.799C228.91 128.231 234.847 159.974 218.242 183.189C202.232 205.572 170.376 204.483 143.304 209.326C119.197 213.639 94.4892 220.307 72.6245 209.239C49.4706 197.518 31.0545 175.759 26.482 150.19Z",fill:"#F5F5F5"}),t.createElement("path",{d:"M130.149 24.7279L212.957 85.3986C211.35 86.0845 209.527 86.4389 207.604 86.3497L50.7152 79.1039C48.0165 78.9797 45.5868 78.0022 43.748 76.4774L105.326 25.3523C112.012 19.8017 123.047 19.524 130.149 24.7279Z",fill:"#7D97F4"}),t.createElement("path",{d:"M48.0411 188.468L204.902 189C211 189 215.942 184.62 215.942 179.215V92.057C215.942 86.8639 211.365 82.5757 205.515 82.2874L48.6576 74.5381C42.09 74.2131 36.6611 79.0181 37.0165 84.8401V179.215C37.3373 184.405 42.1781 188.468 48.0411 188.468Z",fill:"#404583"}),t.createElement("path",{d:"M125.86 136.408L43.3027 75.4704C44.9116 74.789 46.7361 74.4424 48.6574 74.5376L205.518 82.2866C208.214 82.4186 210.639 83.4035 212.473 84.9346L150.684 135.863C143.977 141.391 132.942 141.633 125.86 136.408Z",fill:"#7D97F4"}),t.createElement("mask",{id:"mask0_26761_18544",style:{maskType:"luminance"},maskUnits:"userSpaceOnUse",x:"45",y:"28",width:"167",height:"113"},t.createElement("path",{d:"M125.861 136.408L45.9427 77.4203C44.6981 76.4998 45.3265 74.7124 46.9381 74.5698C47.5007 74.5207 48.0754 28.1225 48.6588 28.1517L205.518 35.9008C207.387 35.9928 209.127 82.8804 210.628 83.6889C211.649 84.2382 211.769 85.5146 210.895 86.2357L150.685 135.862C143.977 141.391 132.943 141.633 125.861 136.408Z",fill:"var(--color-neutral-0)"})),t.createElement("g",{mask:"url(#mask0_26761_18544)"},t.createElement("path",{d:"M75.5508 152.414H179.874V47.3704C179.874 43.351 176.336 40.0294 171.806 39.7978L84.6009 35.344C79.6884 35.0939 75.5508 38.5567 75.5508 42.9167V152.414Z",fill:"#BDD0FB"}),t.createElement("path",{d:"M85.5327 48.37L86.7364 84.0735L86.9227 89.6014C86.9284 90.324 87.599 90.9099 88.4158 90.9054L168.526 90.4665C169.342 90.4619 170.004 89.8683 169.999 89.1457L170.053 83.6166L170.383 48.3411C170.377 47.6185 169.408 46.2147 167.651 46.3312L89.3415 44.9642C88.3184 44.9475 87.3325 45.3003 86.6132 45.9447C85.8938 46.589 85.5041 47.465 85.5327 48.37Z",fill:"#91B3FA"}),t.createElement("path",{d:"M137.357 74.161C137.357 76.025 137.495 77.3813 137.766 78.2328C138.038 79.0841 138.494 79.5107 139.129 79.5107C139.765 79.5107 140.223 79.0841 140.511 78.2328C140.799 77.3813 140.943 76.025 140.943 74.161C140.943 72.297 140.796 70.9437 140.5 70.0985C140.204 69.2547 139.748 68.8312 139.129 68.8312C138.508 68.8312 138.06 69.2547 137.777 70.0985C137.498 70.9437 137.357 72.297 137.357 74.161ZM145.775 74.1213C145.775 77.1513 145.2 79.4494 144.051 81.0189C142.903 82.5867 141.244 83.3706 139.083 83.3706C136.814 83.3706 135.155 82.6035 134.101 81.068C133.051 79.5338 132.524 77.2446 132.524 74.2009C132.524 71.1986 133.067 68.9019 134.148 67.3139C135.228 65.7247 136.873 64.9299 139.083 64.9299C143.544 64.9299 145.775 67.9936 145.775 74.1213ZM138.766 53.6092L125.061 83.0087H120.361L134.023 53.6092H138.766ZM118.206 62.417C118.206 64.281 118.344 65.6371 118.616 66.4886C118.887 67.3401 119.343 67.7665 119.978 67.7665C120.614 67.7665 121.073 67.3401 121.36 66.4886C121.648 65.6371 121.792 64.281 121.792 62.417C121.792 60.5527 121.645 59.1966 121.349 58.3451C121.054 57.4936 120.597 57.0672 119.978 57.0672C119.343 57.0672 118.887 57.4936 118.616 58.3451C118.344 59.1966 118.206 60.5527 118.206 62.417ZM126.624 62.377C126.624 65.407 126.054 67.7083 124.911 69.2838C123.771 70.8595 122.11 71.6463 119.93 71.6463C117.676 71.6463 116.02 70.8764 114.961 69.3345C113.902 67.7927 113.373 65.5006 113.373 62.4567C113.373 56.2771 115.559 53.1857 119.93 53.1857C124.393 53.1857 126.624 56.2494 126.624 62.377Z",fill:"var(--color-neutral-0)"}),t.createElement("path",{d:"M88.7641 46.273L88.4028 45.285C88.833 45.1592 89.2889 45.0964 89.7476 45.0964H89.8308L93.2459 45.1546L93.223 46.1947L89.805 46.1366C89.4208 46.1119 89.0824 46.1826 88.7641 46.273ZM102.565 46.3543L97.894 46.2745L97.9169 45.2359L102.588 45.3157L102.565 46.3543ZM111.907 46.5155L107.236 46.4341L107.259 45.3955L111.93 45.4753L111.907 46.5155ZM121.249 46.6751L116.578 46.5952L116.601 45.5551L121.272 45.6349L121.249 46.6751ZM130.591 46.8346L125.92 46.7548L125.943 45.7162L130.614 45.796L130.591 46.8346ZM139.933 46.9958L135.262 46.9144L135.285 45.8758L139.956 45.9556L139.933 46.9958ZM149.275 47.1553L144.604 47.0756L144.627 46.0351L149.298 46.115L149.275 47.1553ZM158.614 47.3149L153.946 47.2352L153.969 46.1963L158.64 46.2745L158.614 47.3149ZM167.876 47.4804C167.724 47.459 167.563 47.4529 167.394 47.4636L163.288 47.3945L163.311 46.3559L167.366 46.425C167.397 46.4219 167.477 46.4189 167.558 46.4189C167.727 46.4189 167.896 46.4311 168.062 46.4542L167.876 47.4804ZM85.6014 53.0956L85.458 48.9563L86.0458 48.921L86.6308 48.9241L86.7713 53.0633L85.6014 53.0956ZM170.594 54.3139L169.422 54.3045L169.462 50.1637L170.634 50.1729L170.594 54.3139ZM85.8824 61.3725L85.7419 57.2333L86.9118 57.2025L87.0552 61.3402L85.8824 61.3725ZM170.514 62.5951L169.344 62.586L169.381 58.4452L170.554 58.4544L170.514 62.5951ZM86.1634 69.6495L86.0229 65.5102L87.1956 65.4795L87.3362 69.6187L86.1634 69.6495ZM170.437 70.8754L169.264 70.866L169.301 66.7252L170.474 66.7344L170.437 70.8754ZM86.4444 77.9264L86.3039 73.7887L87.4767 73.7564L87.6172 77.8956L86.4444 77.9264ZM170.356 79.1553L169.184 79.1459L169.224 75.0067L170.397 75.0143L170.356 79.1553ZM86.7254 86.2033L86.5849 82.0656L87.7577 82.0333L87.8982 86.1726L86.7254 86.2033ZM170.276 87.4369L169.103 87.4274L169.143 83.3373L169.731 83.2915L170.316 83.2961L170.276 87.4369ZM162.64 90.5789L162.634 89.5385L167.305 89.5141L167.311 90.5527L162.64 90.5789ZM153.295 90.6295L153.29 89.5908L157.961 89.5647L157.969 90.6048L153.295 90.6295ZM143.953 90.6815L143.947 89.6414L148.619 89.6168L148.624 90.6554L143.953 90.6815ZM134.608 90.7321L134.603 89.692L139.274 89.6673L139.282 90.706L134.608 90.7321ZM125.266 90.7827L125.261 89.7441L129.932 89.7182L129.937 90.7583L125.266 90.7827ZM115.921 90.835L115.916 89.7949L120.587 89.7702L120.595 90.8089L115.921 90.835ZM106.579 90.8856L106.574 89.847L111.245 89.8208L111.25 90.8594L106.579 90.8856ZM97.2345 90.9377L97.2287 89.8976L101.9 89.8714L101.908 90.9118L97.2345 90.9377ZM88.896 90.9822C88.4229 90.9822 87.9641 90.8411 87.5971 90.5835L88.3283 89.7687C88.4889 89.8838 88.6839 89.9436 88.8903 89.9436L92.5549 89.9237L92.5635 90.9624L88.896 90.9822Z",fill:"var(--color-neutral-0)"}))),t.createElement("defs",null,t.createElement("clipPath",{id:"clip0_26761_18544"},t.createElement("rect",{width:"242.574",height:"237.513",fill:"var(--color-neutral-0)",transform:"translate(0.712891)"}))))};exports.AppliedCoupon=function(e){var l=e.type;return"success"===l?t.createElement("div",{className:"applied-coupon-bagde succes-coupon"},t.createElement("span",null,t.createElement(a,null)),"Cupom aplicado com sucesso"):"removed"===l?t.createElement("div",{className:"applied-coupon-bagde succes-coupon"},t.createElement("span",null,t.createElement(a,null)),"Cupom removido com sucesso"):t.createElement("div",{className:"applied-coupon-bagde error-coupon"},t.createElement("span",null,t.createElement(n,null)),"error"===l?"Não foi possivel aplicar o cupom. Tente aplicar mais tarde.":"Cupom expirado ou incorreto")},exports.CouponCard=function(e){var n=e.item,o=e.loading,r=e.isApplyCoupon,c=e.setActiveRule,i=e.setDataItem,s=e.handleApplyCoupon,L=e.handleRemoveCoupon;return t.createElement("div",{className:"container-card-coupon "+(r?"active":"")},t.createElement("div",{className:"text-container"},t.createElement("div",{className:"container-title"},t.createElement(l,{width:20,height:16}),t.createElement("p",{className:"title"},n.couponName)),n.couponValue&&t.createElement("p",{className:"price-babge"},"- ",n.couponValue),n.couponDescription&&t.createElement("p",{className:"subtitle"},n.couponDescription),n.couponExpirationDate&&t.createElement("p",{className:"subtitle"},"Válido até ",n.couponExpirationDate)),t.createElement("div",{className:"vertical-line"}),t.createElement("div",{className:"buttons-container"},r&&t.createElement("button",{className:"applied-coupon"},t.createElement("span",{className:"applied-coupon-span"},t.createElement(a,null)),"Aplicado"),r?t.createElement("button",{onClick:function(){return L(n.couponName)},className:"remove-coupon",disabled:o},"Remover"):t.createElement("button",{onClick:function(){return s(n.couponName)},className:"apply-coupon",disabled:o},"Aplicar"),n.couponDescription&&t.createElement("a",{onClick:function(){c(!0),i(n)}},"Ver Regras")))},exports.ModalRules=function(e){var l=e.children,a=e.setCloseX;return t.createElement("div",{className:"modal-rule-coupon-external"},t.createElement("div",{className:"modal-rule-coupon-internal"},t.createElement("div",{className:"modal-rule-coupon-title"},t.createElement("h1",{className:"modal-rule-coupon-title-h1"},e.title),t.createElement("span",{className:".modal-rule-coupon-title-span",onClick:function(){return a(!1)}},t.createElement(o,null))),t.createElement("div",{className:"modal-rule-coupon-children"},l)))},exports.NoCoupons=function(){return t.createElement("div",{className:"noCoupons"},t.createElement("h1",{className:"noCoupons-h1"},"Não há cupons disponíveis no momento"),t.createElement("p",{className:"noCoupons-p"},"Aqui você verá todos os cupons disponíveis para aplicar"),t.createElement(r,null))};
//# sourceMappingURL=coupons.cjs.production.min.js.map

@@ -62,3 +62,3 @@ import React from 'react';

return React.createElement("div", {
className: "container-card-coupon " + (isApplyCoupon && 'active')
className: "container-card-coupon " + (isApplyCoupon ? 'active' : '')
}, React.createElement("div", {

@@ -65,0 +65,0 @@ className: "text-container"

{
"version": "0.2.12",
"version": "0.2.13",
"license": "MIT",

@@ -4,0 +4,0 @@ "main": "dist/index.js",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc