{"version":3,"sources":["api/auth/auth.js","components/Loader/styles.js","components/Loader/index.jsx","pages/Conversao/index.jsx","assets/icons/icon-alert-alert.svg","assets/icons/icon-alert-error.svg","assets/icons/icon-alert-info.svg","assets/icons/icon-alert-success.svg","components/ToastContainer/Toast/styles.js","components/ToastContainer/Toast/index.jsx","components/ToastContainer/styles.js","components/ToastContainer/index.jsx","hooks/toast.jsx","hooks/index.jsx","assets/icons/icon-search.svg","assets/icons/icon-menu.svg","assets/icons/icon-profile.svg","assets/icons/icon-whishlist.svg","assets/icons/icon-arrow-down.svg","assets/icons/icon-assinatura.svg","assets/icons/icon-contratos.svg","assets/icons/icon-local.svg","assets/icons/icon-info.svg","assets/icons/icon-footer-facebook.svg","assets/icons/icon-footer-twitter.svg","assets/icons/icon-footer-instagram.svg","assets/icons/icon-footer-linkedin.svg","assets/icons/icon-footer-youtube.svg","assets/icons/icon-cart.svg","assets/icons/icon-check.svg","assets/icons/icon-close.svg","assets/icons/icon-eye.svg","assets/icons/icon-arrow-button-right.svg","assets/icons/icon-arrow-button-left.svg","styles/scroll.js","styles/icons.js","styles/global.js","styles/radio.js","styles/checkbox.js","store/ducks/endereco.js","store/ducks/pagamento.js","api/defaultoption.js","api/pagamento.js","pages/Pagamento/fetch.js","utils/utils.js","api/carrinho.js","pages/Envio/fetch.js","components/PaymentCards/GimbaCard/fetch.js","api/clientes.js","utils/estadosST.js","utils/validatePJ.js","pages/Auth/fetch.js","store/ducks/user.js","api/traceLog.js","utils/traceLogAcessos.js","pages/Auth/Login.jsx","hooks/useQuery.jsx","pages/Auth/Logout.jsx","components/Container/index.jsx","components/MediaMatch/index.jsx","components/Header/styles.js","components/SearchModal/styles.js","components/SearchModal/mock/search.js","components/Icon/index.jsx","components/SearchModal/index.jsx","components/SearchBox/styles.js","components/SearchBox/index.jsx","components/ProfileModal/styles.js","components/ProfileModal/mock/profile.js","components/ProfileModal/index.jsx","assets/img/icon-facebook.svg","components/AccountModal/styles.js","assets/icons/icon-input-success.svg","assets/icons/icon-input-error.svg","components/Form/styles.js","api/usuarios.js","components/AccountModal/facebookLogin.jsx","components/FormPJ/fieldValidator.js","components/FormPF/fieldValidator.js","components/Tooltip/styles.js","components/Tooltip/index.jsx","components/TextField/styles.js","components/TextField/index.jsx","components/AccountModal/index.jsx","components/Button/styles.js","components/CartModal/styles.js","components/CartModal/index.jsx","assets/img/user.png","assets/img/icon-arrow-right.svg","components/MenuMobile/styles.js","components/MenuMobile/index.jsx","assets/icons/icon-menu-mobile.svg","assets/img/avatar-default.svg","components/Header/index.jsx","assets/icons/icon-remove.svg","components/PaymentCards/CreditCard/styles.js","components/Select/styles.js","components/Select/index.jsx","components/PaymentCards/CreditCardImage/styles.js","assets/img/pagamento/cartao-visa.svg","assets/img/pagamento/cartao-amex.svg","assets/img/pagamento/cartao-mastercard.svg","assets/img/pagamento/cartao-diners.svg","assets/img/pagamento/cartao-elo.svg","assets/img/pagamento/cartao-default.svg","assets/img/pagamento/boleto.svg","assets/img/pagamento/icon-pix.svg","components/PaymentCards/CreditCardImage/index.jsx","components/PaymentCards/CreditCard/index.jsx","components/PaymentCards/GimbaCard/styles.js","store/ducks/envio.js","components/PaymentCards/GimbaCard/index.jsx","components/PaymentCards/styles.js","components/PaymentCards/BoletoCard/styles.js","components/PaymentCards/BoletoCard/index.jsx","components/PaymentCards/NewCard/styles.js","components/PaymentCards/NewCard/index.jsx","components/ToastFaturado/styles.js","components/ToastFaturado/index.jsx","components/PerguntasST/styles.js","pages/Cotacao/fetch.js","pages/Negociacao/fetch.js","components/PerguntasST/index.jsx","components/PaymentCards/PixCard/styles.js","components/PaymentCards/PixCard/index.jsx","components/PaymentCards/index.jsx","components/ResumoPedido/styles.js","components/ResumoPedido/fetch.js","store/ducks/finalizado.js","components/ToastAvisoBoleto/styles.js","components/ToastAvisoBoleto/index.jsx","components/Sellers/masks.js","components/ResumoPedido/index.jsx","components/Steps/styles.js","components/Steps/index.jsx","components/PaymentCardsModal/styles.js","components/FormAddNewCreditCard/styles.js","utils/creditCardValidation.js","components/FormAddNewCreditCard/fetch.js","components/FormAddNewCreditCard/cardDate.js","components/FormAddNewCreditCard/index.jsx","components/PaymentCardsModal/index.jsx","components/FormAddNewCreditCardModal/styles.js","components/FormChangePassword/styles.js","components/FormAddNewCreditCardModal/index.jsx","components/MyAddressModal/styles.js","components/MyAddress/EmptyAdress/styles.js","components/MyAddress/EmptyAdress/index.jsx","assets/icons/icon-edit.svg","components/MyAddressModal/AddressCardModal/styles.js","components/FormPF/masks.js","components/MyAddressModal/AddressCardModal/index.jsx","api/ceps.js","components/MyAddressModal/NewAddressFormModal/styles.js","components/MyAddressModal/NewAddressFormModal/index.jsx","components/MyAddressModal/EditAddressFormModal/styles.js","components/MyAddressModal/EditAddressFormModal/index.jsx","components/MyAddressModal/index.jsx","styles/checkout.js","components/FormCVV/styles.js","assets/img/pagamento/icon-cvv.svg","components/FormCVV/index.jsx","components/PaymentCards/DeleteCardModal/styles.js","components/PaymentCards/DeleteCardModal/index.jsx","pages/Pagamento/index.jsx","components/Sellers/CardFrete/styles.js","components/Sellers/CardFrete/index.jsx","assets/img/icon-calendar.svg","components/CalendarDatePicker/styles.js","components/CalendarDatePicker/utils.js","components/CalendarDatePicker/index.jsx","components/Sellers/CardFreteAgenda/styles.js","components/Sellers/CardFreteAgenda/index.jsx","components/Sellers/CardProduto/styles.js","components/Sellers/CardProduto/index.jsx","components/Sellers/styles.js","components/Sellers/index.jsx","components/MyAddress/AddressCardEnvio/styles.js","components/MyAddress/AddressCardEnvio/index.jsx","components/ToastCotacao/styles.js","components/ToastCotacao/index.jsx","components/ToastEndereco/styles.js","components/ToastEndereco/index.jsx","pages/Envio/index.jsx","components/Sellers/show.jsx","components/MyAddress/AddressCardConfirmacao/styles.js","components/MyAddress/AddressCardConfirmacao/index.jsx","components/PaymentCards/PaymentMethodConfirmacao/styles.js","components/PaymentCards/PaymentMethodConfirmacao/index.jsx","components/BloqueioModal/styles.js","components/BloqueioModal/index.jsx","pages/Confirmacao/index.jsx","api/pedidos.js","components/AcompanharPedidoModal/styles.js","components/PedidoFinalizado/styles.js","assets/img/icon-whatsapp.svg","components/PedidoFinalizado/index.jsx","components/ModalPesquisa/styles.js","components/ModalPesquisa/index.jsx","pages/Finalizado/index.jsx","assets/img/icon-breadcrumb-right.svg","styles/breadcrumb.js","components/CotacaoCheckout/styles.js","components/CotacaoCheckout/CardProduto/styles.js","components/CotacaoCheckout/CardProduto/index.jsx","components/CotacaoCheckout/index.jsx","components/ResumoCotacao/styles.js","components/ResumoCotacao/index.jsx","components/CotacaoCheckout/OpcoesFrete/styles.js","components/CotacaoCheckout/CardFreteAgenda/styles.js","components/CotacaoCheckout/CardFreteAgenda/index.jsx","components/CotacaoCheckout/OpcoesFrete/index.jsx","components/CotacaoCheckout/FormaPagamento/Boleto/styles.js","components/CotacaoCheckout/FormaPagamento/Boleto/index.jsx","components/CotacaoCheckout/FormaPagamento/Cartao/index.jsx","components/CotacaoCheckout/FormaPagamento/Pix/styles.js","components/CotacaoCheckout/FormaPagamento/Pix/index.jsx","components/CotacaoCheckout/FormaPagamento/styles.js","components/CotacaoCheckout/FormaPagamento/index.jsx","components/CotacaoCheckout/OpcoesFreteModal/styles.js","components/CotacaoCheckout/OpcoesFreteModal/FreteCards/styles.js","components/CotacaoCheckout/OpcoesFreteModal/FreteCards/index.jsx","components/CotacaoCheckout/OpcoesFreteModal/indes.jsx","components/CotacaoFinalizadaModal/styles.js","components/CotacaoFinalizadaModal/index.jsx","pages/Cotacao/index.jsx","pages/Negociacao/index.jsx","assets/icons/icon-arrow-right.svg","components/CepModal/styles.js","components/Category/styles.js","components/Menu/styles.js","components/Category/index.jsx","components/Footer/styles.js","components/Footer/index.jsx","styles/page-profile.js","components/ErrorNotFound/styles.js","assets/products/carrinho.png","components/ErrorNotFound/index.jsx","pages/Erro404/index.jsx","utils/error.js","components/ErrorNotFound/ErroR.jsx","pages/ErroR/index.jsx","styles/theme.js","App.jsx","reportWebVitals.js","store/ducks/rootReducer.js","store/index.js","index.js"],"names":["TOKEN_KEY","token","localStorage","getItem","sessionStorage","isAuthenticated","window","getToken","login","vToken","elseAction","removeItem","setItem","location","href","process","logout","authCheck","userToken","isPF","user","jwt","decode","cpf","trim","length","loader","keyframes","loaderDot","loaderDotBefore","showModal","Background","styled","div","LoaderContainer","LoaderDot","Loader","props","Conversao","useQueryParam","StringParam","pedidoEncoded","formaPagamentoEncoded","PixPagamento","useState","wait","setWait","pedidoDecoded","Buffer","from","toString","formaPagamentoDecoded","pixPagamentoDecoded","pixPagamentoParsed","toLowerCase","JSON","parse","useEffect","pick","pickIndex","stringify","Id","id","condicaoIndex","condicoes","Descricao","toastTypeVariations","info","css","success","error","warning","Container","animated","type","hasDescription","icons","src","IconAlertInfo","style","width","marginRight","height","alt","IconAlertError","IconAlertSuccess","IconAlert","Toast","message","removeToast","msgArray","useToast","removeTime","timer","setTimeout","keep","clearTimeout","Number","description","title","onClick","size","ToastContainer","messages","messagesWithTransitions","useTransition","right","opacity","enter","leave","slice","map","item","key","ToastContext","createContext","ToastProvider","children","setMessages","addToast","useCallback","v4","Provider","value","context","useContext","Error","AppProvider","Scroll","IconArrowBtnRight","GlobalStyles","createGlobalStyle","theme","removeBg","colors","primary","RadioStyles","IconSearch","IconMenu","IconProfile","IconWishlist","IconArrowDown","IconAssinatura","IconContratos","IconLocal","IconInfo","IconFooterFacebook","IconFooterTwitter","IconFooterInstagram","IconFooterLinkedin","IconFooterYoutube","IconCart","IconCheck","IconClose","IconEye","IconArrowBtnLeft","IconStyles","CheckBoxStyles","font","sizes","medium","mediumGrey","IconArrowButtonLeft","media","desktop","Types","INITIAL_STATE","enderecos","padrao","setEndereco","payload","setPadrao","pickF","condicaoFaturado","condicaoIndexF","gimplus","pagamento","pagamentoSeller","st","destinoFiscal","undefined","icms","observacao","cvv","setPagamento","setPick","setPickF","setGimplusStore","setPromotor","setST","field","setCondicoes","setCondicaoIndex","setCondicaoIndexF","setCvv","setCondicaoFaturado","defaultOptions","headers","Authorization","auth","getFormas","body","fetch","method","timeout","getFormasSeller","getFormasGimba","addCartao","axios","post","catch","response","delCartao","Token","getCupom","cupom","limpaCupom","getGimplus","setGimplus","valor","ValorPontos","idEndereço","fretePick","a","save","load","store","activation","consumo","checked","sellers","Object","keys","filter","e","SellerId","Valor","isFaturado","IdTipo","envio","resumo","Carrinho","periodo","str","Selecionada","Agenda","Data","date","Perido","turno","Frete","FreteGimba","IdTransportadora","Gimba","DiasParaEntrega","time","Retira","FOB","Agendamento","Periodo","FreteSellers","SituacaoTributariaConsumo","SituacaoTributariaSelecionada","SituacaoTributariaIcms","IdEnderecoSelecionado","DescricaoFormaPagamento","res","json","convertDecimalCurrency","toLocaleString","currency","formatarParaPorcentagem","numero","numeroComVirgula","parseFloat","toFixed","replace","capitalizeWord","charAt","toUpperCase","capitalizePhrase","split","word","substring","join","precoMask","val","negative","isNaN","onlyNumber","showFullFlagName","flag","iframeLink","websiteUrl","self","top","parent","carrinho","getResumo","addressId","getFrete","postPedido","postPedidoFaturado","postCotacao","getImage","ok","wg","IdEndereco","ProdutosConcatenados","FreteCondicoes","tipoPedido","preCupom","saveResumo","saveFrete","saveFretePick","savePagamento","msg","endereco","bodyFrete","frete","ret","getFormasCupom","Validation","IsValid","Errors","Message","OpcoesFrete","el","newFrete","newPick","name","RazaoSocial","ValorFrete","ValorFreteAgendado","save2","minGimplus","ValorMinimoGimplus","percentualGimplus","ValorPercentualGimplus","valorCalc","saldo","Total","Utilizado","valorProdutos","ValorProdutos","Resumo","getPromotorVendas","promotor","clientes","resbody","Mensagem","getLoggedUserPF","params","getLoggedUserPJ","getLoggedCompany","cargos","departamentos","atividades","subAtividades","idAtividade","funcionarios","getTokenParceria","postTokenParceria","postPromotorVendas","getNews","patchNews","validateEmail","email","updateTelefone","estadosST","tokenDecoded","isInscricaoEstadualIsento","tipoCliente","inscricaoEstadual","getFaturamentoUF","addressList","tipoEndereco","uf","allowAddEnderecoEntregaPJ","faturamentoUF","checkRevendaPj","idSubAtividade","checkGovernoPj","checkEstadoST","some","ufsPermitidas","allowNewAddress","address","inscEst","faturamento","includes","getAddress","save1","router","Array","isArray","validateAddNewAddress","find","padrao1","padrao2","fetchUser","updateState","stringToken","setUserInfo","traceLog","logAcessos","userInfo","postLogAcessos","ip","currentUrl","previousUrl","utmSource","utmMedium","utmCampaign","Url","HttpReferer","EmailCliente","getLocalStorageLog","currentPath","origin","clientip","redirectUrl","pathname","Login","useHistory","tipo","dispatch","useDispatch","useSelector","reduxState","query","search","useLocation","useMemo","URLSearchParams","useQuery","userData","setUserData","get","getQueryParamsToTracelog","path","push","Logout","mediaMatchModifiers","lessThan","greaterThan","Wrapper","header","onlyLogo","ipad","HColumsn","HColumn","MenuMobileIcon","Logo","img","HeaderNavigation","HeaderNavigationItem","active","HeaderNavigationItemLink","NavigationItemLinksIcons","white","HeaderModalBox","cel","visible","SearchModalBox","SearchSuggestion","SearchSuggestionList","ul","SearchSuggestionItem","li","SearchSuggestionProduct","SearchTitle","h4","SearchSuggestionProductItem","ItemThumbnails","ItemTitle","span","SuggestionOffer","ProductFormCart","cart","FormGroupQuantity","suggestion","thumbnail","oldPrice","price","icon","Icon","color","transform","customClass","className","SearchModal","index","mock","placeholder","SearchInputWrapper","SearchInput","input","SearchDiv","SearchButton","button","SearchBox","searchText","setSearchText","onChange","newValue","currentTarget","OverlayModifiers","Overlay","transition","default","HeaderModal","ModalList","ModalListItem","links","ProfileModal","to","ModalClose","ModalTitle","h3","AccountDescription","p","ButtonLink","ButtonPrimary","ButtonFacebook","IconFacebook","ButtonOutline","AccountOr","FormGroup","FormInput","backgroundSuccess","IconInputSuccess","backgroundError","IconInputError","usuarios","loginFacebook","accessToken","getMenuHorizontal","getEsqueciSenha","cid","trocarSenha","alterarSenha","FacebookLogin","history","redirectCadastro","Nome","Email","salvarToken","responseFacebook","getReader","read","uint8Array","unit8String","TextDecoder","CompletarCadadastro","document","querySelector","click","appId","fields","callback","senha","emailVal","match","passVal","LabelTooltip","label","TooltipBox","left","Tooltip","TooltipBody","htmlFor","InputWrapper","Input","Label","wrapperModifiers","grey","disabled","required","TextField","reference","labelFor","initialValue","maxlength","onInput","tooltip","tooltipText","pattern","image","setValue","display","justifyContent","ref","maxLength","AccountModal","handleLeave","setEmail","password","setPassword","userLogin","preventDefault","isValidLogin","isValidPassword","then","result","Promise","reject","errors","Messages","target","Button","ButtonBlock","CartModalBox","HeaderModalCart","ProfileModalStyles","HeaderModalCartWrapper","HeaderModalSubtitle","ModalCartItemQuantity","ModalCartList","ModalCartListItem","ModalCartItemThumbnails","ModalCartItemTitle","ModalCartItemPrice","HeaderModalCartFooter","ModalCartFooterTotal","BuyLink","CartModal","_","Modal","nav","MenuMobileContent","CloseModal","MenuMobileBox","MenuMobileHeader","Account","IconArrowRight","ProfileMenuList","Category","CategoryMenuList","CategoryMenuItem","CategorySubmenuList","CategorySubmenuItem","MenuMobile","showMenu","setShowMenu","categories","modalRef","useRef","isCategMenuOpen","setIsCategMenuOpen","isProfileMenuOpen","setIsProfileMenuOpen","isCategSubmenuOpen","setIsCategSubmenuOpen","arraySubCategories","setOpenSubCategories","setActiveClass","logged","userLogged","current","prev","UserImg","marginLeft","userNameWelcome","categorias","i","activeLink","handleClick","subCategorias","nome","itemSub","textoApoioTituloLink","Header","sessionLocalUser","localUser","profile","modalsOpen","setModalsOpen","handleHover","MediaMatch","IconMenuMobile","passHref","role","onMouseEnter","onMouseLeave","UserPicture","cursor","AvatarDefault","apelido","contato","h2","CardWrapper","CardBox","MainCard","CardInfo","CardIcon","SelectWrapper","Select","select","Option","option","checkout","hidden","multiple","options","CardSvgWrapper","CreditCardImage","cartao","IconVisa","srcset","IconAmex","IconMaster","IconDiners","IconElo","IconBoleto","IconPix","IconCartao","CreditCard","data","check","setCheck","setSelectedParcela","selectedParcela","removeCard","faturado","showOptions","readOnly","bandeira","Parcelas","DescricaoPagamento","Formas","Condicoes","descricao","parcelasOpt","IconRemove","CardName","InputArea","ButtonApply","produtos","setResumo","setFrete","setFretePick","seller","resetFretePick","setTurno","GimbaCard","setLoad","gimplusField","setGimplusField","tokenField","setTokenField","promotorField","setPromotorField","resetCupom","zIndex","v","ind","indexOf","lastInd","lastIndexOf","max","gimplusValue","IdCupom","ValorCupom","margin","fontSize","NomeCliente","codigoPromotorGimba","verifyPromotor","SectionTitle","BoletoCard","setData","condParcelas","condFaturado","NewCard","addCreditCard","setPaymentModal","ToastFaturado","ObservacaoNF","getResumoGimba","getFreteGimba","getFormasCotacao","SituacaoTributariaExibir","modal","dataAgendada","day","month","year","fill","n","String","Date","getDate","getMonth","getFullYear","freteGimba","CodigoPromotor","TipoPedido","Cartao","NomeTitular","NumeroCartao","CodigoSeguranca","ValidadeMes","ValidadeAno","Salvar","Pagamento","Status","UriImagem","TipoPessoa","CodigoERP","IdEmpresa","Endereco","TipoEndereco","TipoLogradouro","tipoLogradouro","logradouro","ApelidoEndereco","PontoReferencia","pontoReferencia","Numero","Complemento","complemento","Bairro","bairro","Cidade","cidade","UF","Cep","cep","ValorFreteEmpresa","ValorTda","ValorTde","ValorAdmFrete","ValorFreteAteRedespacho","ValorPercentualIcms","ValorTranslado","CNPJTransportadoraRedespacho","CNPJTranslado","DataAgendamento","PeriodoAgendamento","ValorEmex","DemaisInformacoes","IdPedido","ObservacaoNegociacao","SituacaoTributaria","SituacaoTributariaSelecionar","PeriodoEntregaAgendada","DataEntregaAgendada","DataAgendada","EntregaAgendada","ObservacaoCliente","observacaoCliente","cotacaoStatus","cotacao","getFormasNegociacao","postNegociacao","console","log","PerguntaST","negociacao","carrinhoGimbaBool","PixCard","pix","forma","PaymentForm","cardData","cardDataSeller","formas","formasSeller","revenda","governo","formasValidation","cond","descontao","card","cardF","marginTop","SideContainer","onlySeller","PedidoInfo","ItemInfo","MobileWrapper","bloqueio","StoredFreteSeller","saveId","PrazoEntrega","IdNomeMetodoEntrega","NomeMetodoEntrega","FreteSeller","pedidoStatus","pedido","erro","Bloqueio","Valid","status","bodyGimba","FormasSeller","condicFaturado","bodySeller","setPedido","ToastAvisoBoleto","setDisplay","Gimbafy","ResumoPedido","confirmacao","setCvvModal","setBloqueio","lock","setLock","descontoMarketplace","setDescontoMarketplace","conFaturado","conIndex","acrescimo","setAcrescimo","ValorIpi","totalIPI","setTotalIPI","condicoesCartaoPJ","ValorSt","carrinhoSellerBool","sumFrete","reduce","acc","validFrete","estoque","produto","TemEstoque","carrinhoGimba","checkFrete","Set","ids","NomeSeller","has","add","carrinhoArray","freteSelecionadoArray","product","totalPorCarrinho","PrecoVenda","Quantidade","freteSelecionado","total","remessa","dataLayer","event","ecommerce","shipping_tier","items","item_id","item_name","DescricaoResumida","quantity","handleDatalayerEnvio","checkPagamento","pagamentoGimba","sellerName","payment_type","handleDatalayerPagamento","postFinal","verificarEAtualizarTotalIPI","novoValorIPI","condicoesBoleto","ValorTotalIPI","ValorParcela","NumeroParcela","PercentualJuros","condicoesCartao","condicoesPix","PercentualDesconto","quantidadeTotal","forEach","valorProdutosConsolidado","ValorProdutosSeller","valorTotalEnvio","valorTotalPagamento","ValorGimplus","getCampanha","pagamentoFiltered","condicao","condicaoId","filterPagamento","descontoTotalCampanha","campanha","Campanhas","IdCondicaoPagamentoGimba","ProdutoPrecoCampanha","PossuiIPI","marginBottom","SteptsList","StepsItem","Steps","steps","stepId","activeStep","ModalWrapper","ContentWrapper","ProfileBoxFooter","HeaderModalClose","WrapperSmall","section","RegisterCard","CardImage","CaptchaContainer","acceptedCreditCards","visa","mastercard","amex","discover","diners_club","jcb","elo","cardFlagPrediction","diners","validateCVV","cardFlag","test","adicionarCartao","sav","newBody","cardName","cardNumber","cardCvv","cardMonth","cardYear","Temporario","temporario","Bandeira","TokenCaptcha","tokenCaptcha","anoAtual","mesAtual","monthsList","finalMonthArray","mesesArray","newMonthArray","minDigit","number","splice","yearsList","range","arr","newArray","FormAddNewCreditCard","cancelar","values","setValues","inputErrors","setInputErrors","isCardNumberValid","setIsCardNumberValid","isCVVNumberValid","setIsCVVNumberValid","setCardFlag","expired","captcha","setCaptcha","handleNumberChange","formattedValue","formatCardNumber","getCardFlag","setDispatch","Yup","errorMessage","this","createError","formData","passSchema","shape","creditCardNumber","creditCardFlag","creditCardCVV","handleSubmit","validate","abortEarly","every","inner","errorArray","objeto","d","onSubmit","onBlur","nCheck","bEven","cDigit","nDigit","parseInt","valid","accepted","validateCard","autoFocus","sitekey","PaymentCardsModal","setShowModal","paymentModal","selectedPaymentMethod","setSelectedPaymentMethod","selectedCondicoes","setSelectedCondicoes","parcela","aria-label","ModalContent","FormAddNewCreditCardModal","ProfileBox","EmptyAdress","CardConfig","CardLink","CardAddressType","Address","noMask","cepMask","addressNumber","noSpecialChars","AddressCardModal","setCurrent","userAddress","deleteModal","setCardId","loading","setLoading","setSelectedAddress","allowAddAdressPJ","inscEstadualIsento","setChecked","capitalize","handleDeleteCard","element","IconEdit","isMaxAdressLimit","ceps","NewAddressFormModal","userTokenData","userId","isCepUnico","setIsCepUnico","checkNewAddressUF","handleChange","trimStart","handleBlur","trimEnd","onBlurCep","addressSchema","min","handleCEPChange","rel","form","EditAddressFormModal","cardId","checkLogradouro","setCheckLogradouro","handleEditAddress","checkCep","s","MyAddressModal","selectedAddress","inscricaoEstadualIsento","faturamentoUf","openModal","setUserAddress","CheckoutSection","PageTitle","PageContent","Tributacao","ColGroup","outline","AvaliacaoGimba","FormCVV","IconCVV","DeleteCardModal","handleMockDeleteCard","retry","setRetry","showDeleteModal","setShowDeleteModal","cvvModal","cartoes","CartoesSalvos","IdCartao","Brand","MaskedNumber","vencimento","cartoesSeller","onlylogo","CardInfoTitle","Gratis","agenda","isFreteInvalid","CalendarWrapper","aside","rightSide","IconCalendar","isWeekday","getDay","checkWeekend","addDays","CalendarDatePicker","minDate","maxDate","QuantidadeDiasEntregaAgendada","selectedDate","setSelectedDate","CustomInput","forwardRef","selected","startDate","dateFormat","filterDate","locale","ptBR","customInput","CardFreteAgenda","defaultValue","CardInfoLine","Seller","Price","CardLinePrice","AliquotaIPI","IPI","Alterar","campanhaPreco","idMedia","ImgMock","PercentualIPI","alignItems","preco","ValorProdutoUnitarioIPI","quantidade","SellerWrapper","SectionTitle2","TitleContainer","ButtonAlterar","Sellers","noFrete","textAlign","padding","freteGimbaDisplay","dataF","IdObjetoMedia","CardFrete","freteSellerDisplay","sellerObj","sId","OpcoesEntrega","EstimativaTransitoDiasUteis","CustoFinalEnvio","NomeProvedorLogistica","precoNovo","quant","ProdutosPercentualQuantidades","sort","b","ValorNominal","CardProduto","ButtonChangeAddress","AddressCardEnvio","allowOtherAddress","ToastCotacao","finalizado","ToastEndereco","Envio","showModalAddress","setShowModalAddress","load0","setLoad0","load1","setLoad1","ipAddress","setIpAddress","enderecoFaturamento","getIpAddress","IPv4","err","finally","CodigoLocalidade","opcao","freteSellers","opcoes","posId","nomeCompleto","sobrenome","userPF","telefoneCliente","telefoneCelularDDD","telefoneCelularNumero","emailCliente","primeiroNomeCliente","sobrenomeCliente","idCliente","userAgent","navigator","userIP","fbc","cookies","fbp","userPJ","dddTelefoneComercial","numeroTelefoneComercial","sendUserDatalayer","turnoCompleto","checkSeller","estimativa","entregaEstimada","addBusinessDays","format","ptBr","freteSellerShowDisplay","disp","NomeCondicaoPagamentoOmnik","fontWeight","AddressCardConfirmacao","CardTitle","pickedMethod","BloqueioModal","Itens","IdProduto","Confirmacao","showModalPayment","setShowModalPayment","openModalAddress","PaymentMethodConfirmacao","pedidos","OpcaoFiltro","DataInicial","DataFinal","Page","PageSize","page","pagesize","opcaofiltro","datainicial","datafinal","vendaPromovida","codigoPromotor","idPedido","tagPedido","tagNegociacao","tagCotacao","Title","showTooltip","CopyTooltip","Info","PedidoFinalizado","localPagamento","localFinalizado","pixData","boletoAVista","pagamentoFaturado","copy","setCopy","codeRef","qrCodeValue","QrCode","qrCodeUrl","QrCodeUrl","pixValidade","DataVencimento","popBoleto","open","copyToClipboard","clipboard","writeText","inicial","textDecoration","fontWseight","BlocoPesquisa","ModalPesquisa","showPeqModal","setShowPeqModal","pesqTrackSalesRef","mostrarPesquisa","setMostrarPesquisa","keyPress","addEventListener","removeEventListener","observer","MutationObserver","mutationsList","isOnlyBtnFecharPesquisa","observe","childList","disconnect","Finalizacao","pedidoPix","receberNovidades","receberWhatsApp","setNews","localEndereco","pickedMethodF","userCel","linkboleto","fetchGet","set","isMobileSafari","once","us","f","g","appendTo","customer","phone","numeroTelefonePrincipal","Estado","Celular","Cnpj","cnpj","DddCel","Ddd","dddTelefonePrincipal","c","getElementsByTagName","getElementById","createElement","async","onload","onreadystatechange","h","readyState","TrackWidget","createWidget","parentNode","insertBefore","visibility","Breadcrumb","BreadcrumbItem","inconBreadcrumbRight","BoxContainer","showAllItems","CotacaoItem","CotacaoItens","setShowAllItems","ResumoCotacao","ValorFinalCotacao","ValorFinalNegociacao","ValorDescontoNegociacao","FreteAgendaCotacao","BoletoCotacao","condBoleto","pag","parcelas","CartaoCotacao","selectedCard","setSelectedCard","parcelasMock","opt","PixCotacao","FormaPagamento","pixEnabled","Boleto","Pix","FreteCards","setCache","setSelectedFrete","OpcoesFreteModal","selectedFrete","cache","TitleHead","CotacaoFinalizadaModal","numeroCotacao","DetalheSubstituicaoTributaria","Cotacao","showModalFrete","setShowModalFrete","showModalCotacao","setShowModalCotacao","waitGroup","setWaitGroup","finalizarCotacao","Negociacao","finalizar","FrameFooter","iframe","footer","Footer","frameBorder","Profile","ErrorBox","ErrorNotFound","ImgCarrinho","Erro404","stringHandler","ErrorR","treat","ErroR","grid","container","gutter","border","radius","family","thin","extraLight","light","normal","semiBold","bold","extraBold","black","xsmall","small","large","xlarge","xxlarge","huge","alert","backgroundInfo","backgroundAlert","spacings","xxsmall","layers","base","menu","overlay","alwaysOnTop","fast","App","TagManager","initialize","gtmId","script","appendChild","component","exact","Finalizado","reportWebVitals","onPerfEntry","Function","getCLS","getFID","getFCP","getLCP","getTTFB","combineReducers","state","createStore","rootreducer","ReactDOM","render","StrictMode","ReactRouterRoute","Route"],"mappings":"+HAAA,mQAEaA,EAAY,YAEZC,EAAQ,WACnB,OAAI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AmBnlC,KAAM/P,IAC3B,KAAKL,GACH,OAAOC,GACT,QACE,OAAOs1C,IqHZ4Dx+C,KjMM1D,WAA4D,IAA3Cw+C,EAA0C,uDAAlCt1C,GAAkC,yCAAjB5F,EAAiB,EAAjBA,KAAMgG,EAAW,EAAXA,QAC7D,OAAQhG,GACN,KAAK2F,GACH,OAAO,6BAAKu1C,GAAZ,IAAmBz7C,KAAMuG,IAC3B,KAAKL,GACH,OAAO,6BAAKu1C,GAAZ,IAAmBznC,QAASzN,IAC9B,KAAKL,GACH,OAAOC,GACT,QACE,OAAOs1C,MkMjBE1xC,GAFD2xC,aAAYC,ICM1BC,IAASC,OACP,cAAC,IAAMC,WAAP,UACE,cAAC,KAAD,CAAU/xC,MAAOA,GAAjB,SACE,cAAC,IAAD,UACE,cAAC,IAAD,CAAoBgyC,iBAAkBC,IAAtC,SACE,cAAC,GAAD,YAKRx9B,SAASu1B,eAAe,SAM1BiH,O","file":"static/js/main.5713dea0.chunk.js","sourcesContent":["import jwt from 'jsonwebtoken'\r\n\r\nexport const TOKEN_KEY = 'authtoken'\r\n\r\nexport const token = () => {\r\n if (localStorage.getItem(TOKEN_KEY)) {\r\n return localStorage.getItem(TOKEN_KEY)\r\n } else {\r\n return sessionStorage.getItem(TOKEN_KEY)\r\n }\r\n //mockPF\r\n // return 'eyJhbGciOiJodHRwOi8vd3d3LnczLm9yZy8yMDAxLzA0L3htbGRzaWctbW9yZSNobWFjLXNoYTI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjUyMDI3NSIsIm5hbWUiOiJhbGV4LmZyZWl0YXMuZGV2QGdtYWlsLmNvbSIsInVzZXJOYW1lIjoiQWxleCBGcmVpdGFzIFBGIiwidXNlck5hbWVXZWxjb21lIjoic2lyIGFsZXggICAgICAgICAgICAgICAgICAgICAgIiwic29jaWFsTmV0d29yayI6ImZhbHNlIiwiZW1haWwiOiJhbGV4LmZyZWl0YXMuZGV2QGdtYWlsLmNvbSIsInRpcG9DbGllbnRlI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cuZ2ltYmEuY29tLmJyIiwiYXVkIjoiR2ltYmEuTG9naW4ifQ.GLQAsVXhCFfIDnF5fESwJCkGh5szqVzTf36T-Y89-ak'\r\n}\r\n\r\nexport const isAuthenticated = () =>\r\n typeof window !== 'undefined' ? token() !== null : false\r\n\r\nexport const getToken = () => (typeof window !== 'undefined' ? token() : '')\r\n\r\nexport const login = (vToken, elseAction = () => undefined) => {\r\n localStorage.removeItem(TOKEN_KEY)\r\n sessionStorage.removeItem(TOKEN_KEY)\r\n if (!!vToken) {\r\n localStorage.setItem(TOKEN_KEY, vToken)\r\n sessionStorage.setItem(TOKEN_KEY, vToken)\r\n return elseAction()\r\n } else {\r\n return (window.location.href = process.env.REACT_APP_URL_MAIN)\r\n }\r\n}\r\n\r\nexport const logout = () => {\r\n localStorage.removeItem(TOKEN_KEY)\r\n sessionStorage.removeItem(TOKEN_KEY)\r\n}\r\n\r\nexport const authCheck = (elseAction = () => undefined) => {\r\n const userToken = token()\r\n if (userToken === null)\r\n return (window.location.href = process.env.REACT_APP_URL_MAIN)\r\n // const user = jwt.decode(userToken)\r\n // if (user?.cpf === undefined) return logout()\r\n return elseAction()\r\n}\r\n\r\nexport const isPF = () => {\r\n const userToken = token()\r\n const user = jwt.decode(userToken)\r\n if (user?.cpf?.trim().length > 0) return true\r\n return false\r\n}\r\n","import styled, { keyframes } from 'styled-components'\r\n\r\nconst loader = keyframes`\r\n 100% {\r\n transform: rotate(360deg);\r\n }\r\n`\r\n\r\nconst loaderDot = keyframes`\r\n 80%, 100% {\r\n transform: rotate(360deg);\r\n }\r\n`\r\n\r\nconst loaderDotBefore = keyframes`\r\n 50% {\r\n transform: scale(0.4);\r\n }\r\n 100%, 0% {\r\n transform: scale(1.0);\r\n }\r\n`\r\n\r\nconst showModal = keyframes`\r\n from {\r\n opacity: 0;\r\n } to {\r\n opacity: 1;\r\n }\r\n`\r\n\r\nexport const Background = styled.div`\r\n width: 100%;\r\n height: 100%;\r\n background: rgba(0, 0, 0, 0.1);\r\n transition: background 0.2s;\r\n position: fixed;\r\n top: 0;\r\n left: 0;\r\n display: flex;\r\n justify-content: center;\r\n align-items: center;\r\n z-index: 1000;\r\n animation: ${showModal} 200ms;\r\n`\r\n\r\nexport const LoaderContainer = styled.div`\r\n width: 60px;\r\n height: 60px;\r\n position: relative;\r\n margin: 0 auto;\r\n z-index: 1001;\r\n animation: ${loader} 2.5s infinite linear both;\r\n`\r\n\r\nexport const LoaderDot = styled.div`\r\n width: 100%;\r\n height: 100%;\r\n position: absolute;\r\n left: 0;\r\n top: 0;\r\n animation: ${loaderDot} 2s infinite ease-in-out both;\r\n\r\n &:before {\r\n content: '';\r\n display: block;\r\n width: 25%;\r\n height: 25%;\r\n background-color: #d22630;\r\n border-radius: 100%;\r\n animation: ${loaderDotBefore} 2s infinite ease-in-out both;\r\n }\r\n\r\n &:nth-child(1) {\r\n animation-delay: -1.1s;\r\n }\r\n\r\n &:nth-child(2) {\r\n animation-delay: -1s;\r\n }\r\n\r\n &:nth-child(3) {\r\n animation-delay: -0.9s;\r\n }\r\n\r\n &:nth-child(4) {\r\n animation-delay: -0.8s;\r\n }\r\n\r\n &:nth-child(5) {\r\n animation-delay: -0.7s;\r\n }\r\n\r\n &:nth-child(6) {\r\n animation-delay: -0.6s;\r\n }\r\n\r\n &:nth-child(1):before {\r\n animation-delay: -1.1s;\r\n }\r\n\r\n &:nth-child(2):before {\r\n animation-delay: -1s;\r\n }\r\n\r\n &:nth-child(3):before {\r\n animation-delay: -0.9s;\r\n }\r\n\r\n &:nth-child(4):before {\r\n animation-delay: -0.8s;\r\n }\r\n\r\n &:nth-child(5):before {\r\n animation-delay: -0.7s;\r\n }\r\n\r\n &:nth-child(6):before {\r\n animation-delay: -0.6s;\r\n }\r\n`\r\n","import * as S from './styles'\r\n\r\nconst Loader = (props) => {\r\n return (\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n )\r\n}\r\n\r\nexport default Loader\r\n","/* eslint-disable react-hooks/exhaustive-deps */\r\nimport { useEffect } from 'react'\r\nimport { useQueryParam, StringParam } from 'use-query-params'\r\nimport Loader from '../../components/Loader'\r\nimport { useState } from 'react'\r\nimport { token } from '../../api/auth/auth.js'\r\n\r\nconst Conversao = () => {\r\n const [pedidoEncoded] = useQueryParam('p', StringParam)\r\n const [formaPagamentoEncoded] = useQueryParam('f', StringParam)\r\n const [PixPagamento] = useQueryParam('px', StringParam)\r\n const [valorEncoded] = useQueryParam('v', StringParam)\r\n const [operacaoEncoded] = useQueryParam('o', StringParam)\r\n\r\n const [wait, setWait] = useState(0)\r\n\r\n // const b64 = new Buffer.from('Boleto à vista').toString('base64')\r\n\r\n const pedidoDecoded = new Buffer.from(pedidoEncoded, 'base64').toString(\r\n 'ascii'\r\n )\r\n\r\n const formaPagamentoDecoded = new Buffer.from(\r\n formaPagamentoEncoded,\r\n 'base64'\r\n ).toString('ascii')\r\n\r\n const pixPagamentoDecoded = new Buffer.from(PixPagamento, 'base64').toString()\r\n const pixPagamentoParsed =\r\n formaPagamentoDecoded.toLowerCase() === 'pix' &&\r\n JSON.parse(pixPagamentoDecoded)\r\n\r\n useEffect(() => {\r\n if (wait === 0) {\r\n // console.log('pedido', pedidoDecoded)\r\n // console.log('formaPagamento', formaPagamentoDecoded)\r\n // console.log('pix', pixPagamentoParsed)\r\n // console.log('na string', b64)\r\n let pick = 'cartao'\r\n let pickIndex = 0\r\n if (formaPagamentoDecoded === 'Boleto C vista') {\r\n pick = 'boleto'\r\n pickIndex = 0\r\n } else if (formaPagamentoDecoded.toLowerCase() === 'pix') {\r\n pick = 'pix'\r\n\r\n pickIndex = 0\r\n } else if (formaPagamentoDecoded === 'Boleto Faturado') {\r\n pick = 'boleto'\r\n pickIndex = 1\r\n } else {\r\n pickIndex = 2\r\n }\r\n\r\n if (!!pedidoEncoded) {\r\n localStorage.setItem(\r\n 'finalizado',\r\n JSON.stringify({\r\n Id: pedidoDecoded,\r\n PixPagamento: pixPagamentoParsed\r\n })\r\n )\r\n\r\n sessionStorage.setItem(\r\n 'finalizado',\r\n JSON.stringify({\r\n Id: pedidoDecoded,\r\n PixPagamento: pixPagamentoParsed\r\n })\r\n )\r\n }\r\n\r\n if (!!formaPagamentoEncoded) {\r\n localStorage.setItem(\r\n 'pagamento',\r\n JSON.stringify({\r\n pick: { id: pick },\r\n condicaoIndex: pickIndex,\r\n condicoes: {\r\n Descricao:\r\n formaPagamentoDecoded === 'Boleto C vista'\r\n ? 'Boleto à vista'\r\n : formaPagamentoDecoded === 'Pix'\r\n ? 'Pix'\r\n : 'outro'\r\n }\r\n })\r\n )\r\n\r\n sessionStorage.setItem(\r\n 'pagamento',\r\n JSON.stringify({\r\n pick: { id: pick },\r\n condicaoIndex: pickIndex,\r\n condicoes: {\r\n Descricao:\r\n formaPagamentoDecoded === 'Boleto C vista'\r\n ? 'Boleto à vista'\r\n : formaPagamentoDecoded === 'Pix'\r\n ? 'Pix'\r\n : 'outro'\r\n }\r\n })\r\n )\r\n }\r\n\r\n setWait(1)\r\n }\r\n if (wait === 1) {\r\n window.location.href = `${\r\n process.env.REACT_APP_URL_MAIN\r\n }/checkout/pedidoEfetuado?token=${token()}&idPedidoEfetuado=${pedidoDecoded}`\r\n setWait(2)\r\n }\r\n }, [wait])\r\n\r\n return (\r\n
\r\n \r\n
\r\n )\r\n}\r\nexport default Conversao\r\n","export default __webpack_public_path__ + \"static/media/icon-alert-alert.d0728114.svg\";","export default __webpack_public_path__ + \"static/media/icon-alert-error.b20571c2.svg\";","export default __webpack_public_path__ + \"static/media/icon-alert-info.5a546e72.svg\";","export default __webpack_public_path__ + \"static/media/icon-alert-success.c9097775.svg\";","import styled, { css } from 'styled-components'\r\nimport { animated } from 'react-spring'\r\n\r\nconst toastTypeVariations = {\r\n info: css`\r\n background: #f1f8ff;\r\n color: #1877f2;\r\n `,\r\n success: css`\r\n background: #e5f7e7;\r\n color: #27ae60;\r\n `,\r\n error: css`\r\n background: #feeaea;\r\n color: #d22630;\r\n `,\r\n warning: css`\r\n background: #fff3e7;\r\n color: #ff9017;\r\n `\r\n}\r\nexport const Container = styled(animated.div)`\r\n position: relative;\r\n padding: 20px 40px 16px 20px;\r\n border-radius: 5px;\r\n display: flex;\r\n align-items: center;\r\n & + div {\r\n margin-top: 8px;\r\n }\r\n ${(props) => toastTypeVariations[props.type || 'info']}\r\n > svg {\r\n margin: 4px 30px 0 10px;\r\n }\r\n div {\r\n flex: 1;\r\n p {\r\n margin-top: 4px;\r\n font-size: 14px;\r\n opacity: 0.8;\r\n line-height: 20px;\r\n }\r\n }\r\n button {\r\n position: absolute;\r\n right: 16px;\r\n /* top: 24px; */\r\n border: 0;\r\n background: transparent;\r\n color: inherit;\r\n cursor: pointer;\r\n }\r\n ${(props) =>\r\n !props.hasDescription &&\r\n css`\r\n align-items: center;\r\n svg {\r\n margin-top: 0;\r\n }\r\n `}\r\n`\r\n","import React, { useEffect } from 'react'\r\nimport { HiX } from 'react-icons/hi'\r\n\r\nimport IconAlert from '../../../assets/icons/icon-alert-alert.svg'\r\nimport IconAlertError from '../../../assets/icons/icon-alert-error.svg'\r\nimport IconAlertInfo from '../../../assets/icons/icon-alert-info.svg'\r\nimport IconAlertSuccess from '../../../assets/icons/icon-alert-success.svg'\r\n\r\nimport { useToast } from '../../../hooks/toast'\r\n\r\nimport { Container } from './styles'\r\n\r\nconst icons = {\r\n info: (\r\n \r\n ),\r\n error: (\r\n \r\n ),\r\n success: (\r\n \r\n ),\r\n warning: (\r\n \r\n )\r\n}\r\n\r\nconst Toast = ({ message, style, msgArray }) => {\r\n const { removeToast } = useToast()\r\n\r\n let removeTime = message.timer || 4000\r\n\r\n useEffect(() => {\r\n const timer = setTimeout(() => {\r\n if (!message.keep) removeToast(message.id)\r\n }, removeTime)\r\n\r\n return () => {\r\n clearTimeout(timer)\r\n }\r\n }, [removeToast, message.id, removeTime])\r\n\r\n return (\r\n \r\n {icons[message.type || 'info']}\r\n
\r\n {message.title}\r\n {message.description &&

{message.description}

}\r\n
\r\n\r\n \r\n \r\n )\r\n}\r\n\r\nexport default Toast\r\n","import styled from 'styled-components'\r\n\r\nexport const Container = styled.div`\r\n max-width: 100vw;\r\n width: 100%;\r\n position: fixed;\r\n right: 0;\r\n bottom: 0;\r\n overflow: hidden;\r\n z-index: 301;\r\n`\r\n","import React from 'react'\r\nimport { useTransition } from 'react-spring'\r\n\r\nimport Toast from './Toast'\r\nimport { Container } from './styles'\r\n\r\nconst ToastContainer = ({ messages }) => {\r\n const messagesWithTransitions = useTransition(\r\n messages,\r\n (message) => message.id,\r\n {\r\n from: { right: '-120%', opacity: 0 },\r\n enter: { right: '0%', opacity: 1 },\r\n leave: { right: '-120%', opacity: 0 }\r\n }\r\n )\r\n\r\n return (\r\n \r\n {messagesWithTransitions.slice(-1).map(({ item, key, props }) => (\r\n \r\n ))}\r\n \r\n )\r\n}\r\n\r\nexport default ToastContainer\r\n","import React, { createContext, useContext, useCallback, useState } from 'react'\r\nimport { v4 } from 'uuid'\r\n\r\nimport ToastContainer from '../components/ToastContainer/index'\r\n\r\nconst ToastContext = createContext({})\r\n\r\nconst ToastProvider = ({ children }) => {\r\n const [messages, setMessages] = useState([])\r\n\r\n const addToast = useCallback(({ type, title, description, timer, keep }) => {\r\n const id = v4()\r\n\r\n const toast = {\r\n id,\r\n type,\r\n title,\r\n description,\r\n timer,\r\n keep\r\n }\r\n\r\n setMessages(toast)\r\n }, [])\r\n\r\n const removeToast = useCallback((id) => {\r\n setMessages(messages)\r\n }, [])\r\n\r\n return (\r\n \r\n {children}\r\n \r\n \r\n )\r\n}\r\n\r\nfunction useToast() {\r\n const context = useContext(ToastContext)\r\n\r\n if (!context) {\r\n throw new Error('useToast must be used within a ToastProvider')\r\n }\r\n\r\n return context\r\n}\r\n\r\nexport { ToastProvider, useToast }\r\n","import React from 'react'\r\n\r\nimport { ToastProvider } from './toast'\r\n\r\nconst AppProvider = ({ children }) => (\r\n {children}\r\n)\r\n\r\nexport default AppProvider\r\n","export default __webpack_public_path__ + \"static/media/icon-search.3acf1ded.svg\";","export default __webpack_public_path__ + \"static/media/icon-menu.2969e51f.svg\";","export default __webpack_public_path__ + \"static/media/icon-profile.3a7ec974.svg\";","export default __webpack_public_path__ + \"static/media/icon-whishlist.445e802b.svg\";","export default __webpack_public_path__ + \"static/media/icon-arrow-down.987febc0.svg\";","export default __webpack_public_path__ + \"static/media/icon-assinatura.2ac21fea.svg\";","export default __webpack_public_path__ + \"static/media/icon-contratos.8dda5d23.svg\";","export default __webpack_public_path__ + \"static/media/icon-local.43030f86.svg\";","export default __webpack_public_path__ + \"static/media/icon-info.b0b89a5d.svg\";","export default __webpack_public_path__ + \"static/media/icon-footer-facebook.e6b6bd42.svg\";","export default __webpack_public_path__ + \"static/media/icon-footer-twitter.8e7b3ef7.svg\";","export default __webpack_public_path__ + \"static/media/icon-footer-instagram.766ec0d1.svg\";","export default __webpack_public_path__ + \"static/media/icon-footer-linkedin.b5db2fbc.svg\";","export default __webpack_public_path__ + \"static/media/icon-footer-youtube.cd97da45.svg\";","export default __webpack_public_path__ + \"static/media/icon-cart.a13c134f.svg\";","export default __webpack_public_path__ + \"static/media/icon-check.bab3acea.svg\";","export default __webpack_public_path__ + \"static/media/icon-close.0e1b64f3.svg\";","export default __webpack_public_path__ + \"static/media/icon-eye.52999197.svg\";","export default __webpack_public_path__ + \"static/media/icon-arrow-button-right.551943ad.svg\";","export default __webpack_public_path__ + \"static/media/icon-arrow-button-left.e842f2b2.svg\";","import { css } from 'styled-components'\r\n\r\nexport const Scroll = css`\r\n * {\r\n &::-webkit-scrollbar {\r\n border-radius: 5px;\r\n background: #eeeeee;\r\n height: 10px;\r\n width: 10px;\r\n }\r\n\r\n &::-webkit-scrollbar-track {\r\n border-radius: 5px;\r\n }\r\n\r\n &::-webkit-scrollbar-thumb {\r\n border-radius: 5px;\r\n background: #afaeae;\r\n }\r\n }\r\n`\r\n","import { css } from 'styled-components'\r\n\r\nimport IconSearch from '../assets/icons/icon-search.svg'\r\nimport IconMenu from '../assets/icons/icon-menu.svg'\r\nimport IconProfile from '../assets/icons/icon-profile.svg'\r\nimport IconWishlist from '../assets/icons/icon-whishlist.svg'\r\nimport IconArrowDown from '../assets/icons/icon-arrow-down.svg'\r\nimport IconAssinatura from '../assets/icons/icon-assinatura.svg'\r\nimport IconContratos from '../assets/icons/icon-contratos.svg'\r\nimport IconLocal from '../assets/icons/icon-local.svg'\r\nimport IconInfo from '../assets/icons/icon-info.svg'\r\nimport IconFooterFacebook from '../assets/icons/icon-footer-facebook.svg'\r\nimport IconFooterTwitter from '../assets/icons/icon-footer-twitter.svg'\r\nimport IconFooterInstagram from '../assets/icons/icon-footer-instagram.svg'\r\nimport IconFooterLinkedin from '../assets/icons/icon-footer-linkedin.svg'\r\nimport IconFooterYoutube from '../assets/icons/icon-footer-youtube.svg'\r\nimport IconCart from '../assets/icons/icon-cart.svg'\r\nimport IconCheck from '../assets/icons/icon-check.svg'\r\nimport IconClose from '../assets/icons/icon-close.svg'\r\nimport IconEye from '../assets/icons/icon-eye.svg'\r\nimport IconArrowBtnRight from '../assets/icons/icon-arrow-button-right.svg'\r\nimport IconArrowBtnLeft from '../assets/icons/icon-arrow-button-left.svg'\r\n\r\nexport const IconStyles = (theme) => css`\r\n // Icons.\r\n .icon {\r\n background-size: contain;\r\n background-repeat: no-repeat;\r\n background-position: center;\r\n display: inline-block;\r\n width: 30px;\r\n height: 30px;\r\n }\r\n\r\n // Search.\r\n .icon-search {\r\n background-image: url(${IconSearch});\r\n }\r\n\r\n // Search.\r\n .icon-menu {\r\n background-image: url(${IconMenu});\r\n }\r\n\r\n // Profile.\r\n .icon-profile {\r\n background-image: url(${IconProfile});\r\n }\r\n\r\n // Whishlist.\r\n .icon-whishlist {\r\n background-image: url(${IconWishlist});\r\n }\r\n\r\n // Arrow Down.\r\n .icon-arrow-down {\r\n background-image: url(${IconArrowDown});\r\n width: 12px;\r\n height: 8px;\r\n margin-left: 3px;\r\n }\r\n\r\n // Assinatura.\r\n .icon-assinatura {\r\n background-image: url(${IconAssinatura});\r\n }\r\n\r\n // Contratos.\r\n .icon-contratos {\r\n background-image: url(${IconContratos});\r\n }\r\n\r\n // Local.\r\n .icon-local {\r\n background-image: url(${IconLocal});\r\n }\r\n\r\n // Footer Youtube.\r\n .icon-info {\r\n background-image: url(${IconInfo});\r\n }\r\n\r\n // Footer Facebook.\r\n .icon-footer-facebook {\r\n background-image: url(${IconFooterFacebook});\r\n }\r\n\r\n // Footer Twitter.\r\n .icon-footer-twitter {\r\n background-image: url(${IconFooterTwitter});\r\n }\r\n\r\n // Footer Instagram.\r\n .icon-footer-instagram {\r\n background-image: url(${IconFooterInstagram});\r\n }\r\n\r\n // Footer Linkedin.\r\n .icon-footer-linkedin {\r\n background-image: url(${IconFooterLinkedin});\r\n }\r\n\r\n // Footer Youtube.\r\n .icon-footer-youtube {\r\n background-image: url(${IconFooterYoutube});\r\n }\r\n\r\n // *** Mask.\r\n\r\n // Cart.\r\n .icon-cart {\r\n mask-image: url(${IconCart});\r\n mask-size: contain;\r\n mask-repeat: no-repeat;\r\n }\r\n\r\n // Check.\r\n .icon-check {\r\n mask-image: url(${IconCheck});\r\n mask-size: contain;\r\n mask-repeat: no-repeat;\r\n }\r\n\r\n // Close.\r\n .icon-close {\r\n mask-image: url(${IconClose});\r\n mask-size: contain;\r\n mask-repeat: no-repeat;\r\n width: 20px;\r\n height: 20px;\r\n background-color: #707070;\r\n }\r\n\r\n // Eye.\r\n .icon-eye {\r\n mask-image: url(${IconEye});\r\n mask-size: contain;\r\n mask-repeat: no-repeat;\r\n width: 20px;\r\n height: 20px;\r\n background-color: #707070;\r\n }\r\n\r\n // Arrow Button Right.\r\n .icon-arrow-button-right {\r\n mask-image: url(${IconArrowBtnRight});\r\n mask-size: contain;\r\n mask-repeat: no-repeat;\r\n width: 20px;\r\n height: 10px;\r\n background-color: #ffffff;\r\n }\r\n\r\n // Arrow Button Left.\r\n .icon-arrow-button-left {\r\n mask-image: url(${IconArrowBtnLeft});\r\n mask-size: contain;\r\n mask-repeat: no-repeat;\r\n width: 20px;\r\n height: 10px;\r\n background-color: ${theme.colors.primary};\r\n }\r\n`\r\n// Arrow Button Right.\r\nexport const IconArrowButtonRight = css`\r\n mask-image: url(${IconArrowBtnRight});\r\n mask-size: contain;\r\n mask-repeat: no-repeat;\r\n width: 20px;\r\n height: 10px;\r\n background-color: #ffffff;\r\n`\r\n\r\n// Arrow Button Left.\r\nexport const IconArrowButtonLeft = (theme) => css`\r\n mask-image: url(${IconArrowBtnLeft});\r\n mask-size: contain;\r\n mask-repeat: no-repeat;\r\n width: 20px;\r\n height: 10px;\r\n background-color: ${theme.colors.primary};\r\n`\r\n","import {\r\n createGlobalStyle,\r\n css,\r\n} from 'styled-components'\r\nimport { CheckBoxStyles } from './checkbox'\r\nimport { IconStyles } from './icons'\r\nimport { RadioStyles } from './radio'\r\n\r\nimport { Scroll } from './scroll'\r\n\r\nimport IconArrowButtonLeft from '../assets/icons/icon-arrow-button-left.svg'\r\n\r\n\r\nconst GlobalStyles = createGlobalStyle`\r\n @font-face {\r\n font-family: 'Montserrat';\r\n font-style: normal;\r\n font-weight: 100;\r\n font-display: swap;\r\n src: local(''),\r\n url('/fonts/montserrat-v15-latin-100.woff2') format('woff2'), /* Chrome 26+, Opera 23+, Firefox 39+ */\r\n }\r\n @font-face {\r\n font-family: 'Montserrat';\r\n font-style: normal;\r\n font-weight: 200;\r\n font-display: swap;\r\n src: local(''),\r\n url('/fonts/montserrat-v15-latin-200.woff2') format('woff2'), /* Chrome 26+, Opera 23+, Firefox 39+ */\r\n }\r\n @font-face {\r\n font-family: 'Montserrat';\r\n font-style: normal;\r\n font-weight: 300;\r\n font-display: swap;\r\n src: local(''),\r\n url('/fonts/montserrat-v15-latin-300.woff2') format('woff2'), /* Chrome 26+, Opera 23+, Firefox 39+ */\r\n }\r\n @font-face {\r\n font-family: 'Montserrat';\r\n font-style: normal;\r\n font-weight: 400;\r\n font-display: swap;\r\n src: local(''),\r\n url('/fonts/montserrat-v15-latin-regular.woff2') format('woff2'), /* Chrome 26+, Opera 23+, Firefox 39+ */\r\n }\r\n @font-face {\r\n font-family: 'Montserrat';\r\n font-style: normal;\r\n font-weight: 500;\r\n font-display: swap;\r\n src: local(''),\r\n url('/fonts/montserrat-v15-latin-500.woff2') format('woff2'), /* Chrome 26+, Opera 23+, Firefox 39+ */\r\n }\r\n @font-face {\r\n font-family: 'Montserrat';\r\n font-style: normal;\r\n font-weight: 600;\r\n font-display: swap;\r\n src: local(''),\r\n url('/fonts/montserrat-v15-latin-600.woff2') format('woff2'), /* Chrome 26+, Opera 23+, Firefox 39+ */\r\n }\r\n @font-face {\r\n font-family: 'Montserrat';\r\n font-style: normal;\r\n font-weight: 700;\r\n font-display: swap;\r\n src: local(''),\r\n url('/fonts/montserrat-v15-latin-700.woff2') format('woff2'), /* Chrome 26+, Opera 23+, Firefox 39+ */\r\n }\r\n @font-face {\r\n font-family: 'Montserrat';\r\n font-style: normal;\r\n font-weight: 800;\r\n font-display: swap;\r\n src: local(''),\r\n url('/fonts/montserrat-v15-latin-800.woff2') format('woff2'), /* Chrome 26+, Opera 23+, Firefox 39+ */\r\n }\r\n @font-face {\r\n font-family: 'Montserrat';\r\n font-style: normal;\r\n font-weight: 900;\r\n font-display: swap;\r\n src: local(''),\r\n url('/fonts/montserrat-v15-latin-900.woff2') format('woff2'), /* Chrome 26+, Opera 23+, Firefox 39+ */\r\n }\r\n\r\n * {\r\n margin: 0;\r\n padding: 0;\r\n box-sizing: border-box;\r\n -webkit-font-smoothing: antialiased;\r\n -moz-osx-font-smoothing: grayscale;\r\n\r\n &::before,\r\n &::after {\r\n box-sizing: inherit;\r\n }\r\n }\r\n\r\n *, *:focus, *:hover {\r\n outline: none;\r\n }\r\n\r\n html,\r\n body,\r\n div,\r\n span,\r\n object,\r\n iframe,\r\n h1,\r\n h2,\r\n h3,\r\n h4,\r\n h5,\r\n h6,\r\n p,\r\n blockquote,\r\n pre,\r\n abbr,\r\n address,\r\n cite,\r\n code,\r\n del,\r\n dfn,\r\n em,\r\n img,\r\n ins,\r\n kbd,\r\n q,\r\n samp,\r\n small,\r\n strong,\r\n sub,\r\n sup,\r\n var,\r\n b,\r\n i,\r\n dl,\r\n dt,\r\n dd,\r\n ol,\r\n ul,\r\n li,\r\n fieldset,\r\n form,\r\n label,\r\n legend,\r\n table,\r\n caption,\r\n tbody,\r\n tfoot,\r\n thead,\r\n tr,\r\n th,\r\n td,\r\n article,\r\n aside,\r\n canvas,\r\n details,\r\n figcaption,\r\n figure,\r\n footer,\r\n header,\r\n hgroup,\r\n menu,\r\n nav,\r\n section,\r\n summary,\r\n time,\r\n mark,\r\n audio,\r\n video {\r\n margin: 0;\r\n padding: 0;\r\n border: 0;\r\n outline: 0;\r\n font-size: 100%;\r\n vertical-align: baseline;\r\n background: transparent;\r\n }\r\n\r\n a {\r\n text-decoration: none;\r\n color: currentColor;\r\n\r\n &:focus {\r\n outline: none;\r\n }\r\n }\r\n\r\n .text-center{\r\n text-align: center;\r\n }\r\n\r\n .text-right{\r\n text-align: right;\r\n }\r\n\r\n ${({ theme, removeBg }) => css`\r\n ${Scroll}\r\n ${RadioStyles(theme)}\r\n ${IconStyles(theme)}\r\n ${CheckBoxStyles(theme)}\r\n\r\n .text-color-primary {\r\n color: ${theme.colors.primary};\r\n }\r\n\r\n html {\r\n font-size: 62.5%;\r\n }\r\n\r\n body {\r\n font-family: 'Montserrat', sans-serif;\r\n font-size: ${theme.font.sizes.medium};\r\n color: ${theme.colors.mediumGrey};\r\n\r\n ${!removeBg &&\r\n css`\r\n background-color: #fbfbfb;\r\n `}\r\n\r\n .text-center {\r\n text-align: center;\r\n }\r\n\r\n .link {\r\n text-decoration: underline;\r\n font-size: 14px;\r\n transition: all 400ms;\r\n\r\n &:hover {\r\n opacity: 0.6;\r\n }\r\n }\r\n }\r\n\r\n .col-group {\r\n margin-left: -10px;\r\n margin-right: -10px;\r\n }\r\n\r\n .col-group:before,\r\n .col-group:after {\r\n content: ' ';\r\n display: table;\r\n }\r\n\r\n .col-group:after {\r\n clear: both;\r\n }\r\n\r\n .IconArrowButtonLeft {\r\n mask-image: url(${IconArrowButtonLeft});\r\n mask-size: contain;\r\n mask-repeat: no-repeat;\r\n width: 20px;\r\n height: 10px;\r\n background-color: ${theme.colors.primary};\r\n }\r\n\r\n .col-1,\r\n .col-2,\r\n .col-3,\r\n .col-4,\r\n .col-5,\r\n .col-6,\r\n .col-7,\r\n .col-8,\r\n .col-9,\r\n .col-10,\r\n .col-11,\r\n .col-12 {\r\n min-height: 1px;\r\n padding-left: 10px;\r\n padding-right: 10px;\r\n position: relative;\r\n }\r\n\r\n @media (min-width: ${theme.media.desktop}) {\r\n .col-1,\r\n .col-2,\r\n .col-3,\r\n .col-4,\r\n .col-5,\r\n .col-6,\r\n .col-7,\r\n .col-8,\r\n .col-9,\r\n .col-10,\r\n .col-11,\r\n .col-12 {\r\n float: left;\r\n }\r\n .col-12 {\r\n width: 100%;\r\n }\r\n .col-11 {\r\n width: 91.66666667%;\r\n }\r\n .col-10 {\r\n width: 83.33333333%;\r\n }\r\n .col-9 {\r\n width: 75%;\r\n }\r\n .col-8 {\r\n width: 66.66666667%;\r\n }\r\n .col-7 {\r\n width: 58.33333333%;\r\n }\r\n .col-6 {\r\n width: 50%;\r\n }\r\n .col-5 {\r\n width: 41.66666667%;\r\n }\r\n .col-4 {\r\n width: 33.33333333%;\r\n }\r\n .col-3 {\r\n width: 25%;\r\n }\r\n .col-2 {\r\n width: 16.66666667%;\r\n }\r\n .col-1 {\r\n width: 8.33333333%;\r\n }\r\n }\r\n `}\r\n`\r\n\r\nexport default GlobalStyles\r\n","import { css} from 'styled-components'\r\n\r\nexport const RadioStyles = (theme) => css`\r\n [type='radio']:not(:checked),\r\n [type='radio']:checked {\r\n left: -9999px;\r\n position: absolute;\r\n }\r\n\r\n [type='radio']:not(:checked) + label,\r\n [type='radio']:checked + label {\r\n cursor: pointer;\r\n display: inline-block;\r\n font-size: 14px;\r\n padding-top: 5px;\r\n font-weight: 400 !important;\r\n padding-left: 27px;\r\n position: relative;\r\n }\r\n\r\n [type='radio']:not(:checked) + label:before,\r\n [type='radio']:checked + label:before {\r\n background: transparent;\r\n border: 1px solid #afaeae;\r\n border-radius: 50%;\r\n content: '';\r\n height: 18px;\r\n left: 0;\r\n position: absolute;\r\n top: 2px;\r\n transition: border-color 0.5s ease;\r\n vertical-align: middle;\r\n width: 18px;\r\n }\r\n\r\n [type='radio']:checked + label:before {\r\n border: 3px solid ${theme.colors.primary};\r\n }\r\n\r\n // checked\r\n [type='radio']:not(:checked) + label:after,\r\n [type='radio']:checked + label:after {\r\n border-color: #fff;\r\n border-style: solid;\r\n border-width: 0 2px 2px 0;\r\n content: '';\r\n height: 9px;\r\n left: 8px;\r\n opacity: 0;\r\n position: absolute;\r\n top: 10px;\r\n transform: translate(-50%, -65%) rotate(45deg);\r\n transition: opacity 0.5s ease, visibility 0.5s ease;\r\n width: 4px;\r\n }\r\n\r\n [type='radio']:not(:checked) + label:after {\r\n opacity: 0;\r\n }\r\n\r\n [type='radio']:checked + label:after {\r\n opacity: 1;\r\n }\r\n\r\n // disabled radio\r\n [type='radio']:disabled:not(:checked) + label:before,\r\n [type='radio']:disabled:checked + label:before {\r\n border-color: #cccccc;\r\n background: #f6f6f6;\r\n }\r\n\r\n [type='radio']:disabled:checked + label:after {\r\n color: #999;\r\n }\r\n`\r\n","import { css} from 'styled-components'\r\n\r\nexport const CheckBoxStyles = (theme) => css`\r\n [type='checkbox']:not(:checked),\r\n [type='checkbox']:checked {\r\n left: -9999px;\r\n position: absolute;\r\n }\r\n\r\n [type='checkbox']:not(:checked) + label,\r\n [type='checkbox']:checked + label {\r\n cursor: pointer;\r\n display: inline-block;\r\n font-size: 14px;\r\n font-weight: 400;\r\n line-height: 20px;\r\n padding-left: 23px;\r\n position: relative;\r\n }\r\n\r\n [type='checkbox']:not(:checked) + label:before,\r\n [type='checkbox']:checked + label:before {\r\n background: transparent;\r\n border: 1px solid ${theme.colors.primary};\r\n border-radius: 4px;\r\n content: '';\r\n height: 15px;\r\n left: 0;\r\n position: absolute;\r\n top: 2px;\r\n transition: border-color 0.5s ease;\r\n vertical-align: middle;\r\n width: 15px;\r\n }\r\n\r\n [type='checkbox']:checked + label:before {\r\n background: ${theme.colors.primary};\r\n }\r\n\r\n // checked\r\n [type='checkbox']:not(:checked) + label:after,\r\n [type='checkbox']:checked + label:after {\r\n border-color: #fff;\r\n border-style: solid;\r\n border-width: 0 2px 2px 0;\r\n content: '';\r\n height: 9px;\r\n left: 8px;\r\n opacity: 0;\r\n position: absolute;\r\n top: 10px;\r\n transform: translate(-50%, -65%) rotate(45deg);\r\n transition: opacity 0.5s ease, visibility 0.5s ease;\r\n width: 4px;\r\n }\r\n\r\n [type='checkbox']:not(:checked) + label:after {\r\n opacity: 0;\r\n }\r\n\r\n [type='checkbox']:checked + label:after {\r\n opacity: 1;\r\n }\r\n\r\n // disabled checkbox\r\n [type='checkbox']:disabled:not(:checked) + label:before,\r\n [type='checkbox']:disabled:checked + label:before {\r\n border-color: #cccccc;\r\n background: #f6f6f6;\r\n }\r\n\r\n [type='checkbox']:disabled:checked + label:after,\r\n [type='checkbox']:disabled + label:after {\r\n border-color: #c1c1c1;\r\n }\r\n`\r\n","//Keys\r\nexport const Types = {\r\n SETENDERECO: '@setEndereco',\r\n SETPADRAO: '@setPadrao',\r\n RESETENDERECO: '@resetEndereco'\r\n}\r\n\r\n//Reducer\r\nconst INITIAL_STATE = { enderecos: [], padrao: {} }\r\n\r\nexport default function reducer(state = INITIAL_STATE, { type, payload }) {\r\n switch (type) {\r\n case Types.SETENDERECO:\r\n return { ...state, enderecos: payload }\r\n case Types.SETPADRAO:\r\n return { ...state, padrao: payload }\r\n case Types.RESETENDERECO:\r\n return INITIAL_STATE\r\n default:\r\n return state\r\n }\r\n}\r\n\r\n//Actions\r\nexport const setEndereco = (payload) => {\r\n return { type: Types.SETENDERECO, payload: payload }\r\n}\r\n\r\nexport const setPadrao = (payload) => {\r\n return { type: Types.SETPADRAO, payload: payload }\r\n}\r\n\r\nexport const resetEndereco = () => {\r\n return { type: Types.RESETENDERECO }\r\n}\r\n","//Keys\r\nexport const Types = {\r\n SETPAGAMENTO: '@setPagamento',\r\n SETPAGAMENTOSELLER: '@setPagamentoSeller',\r\n SETPICK: '@setPick',\r\n SETPICKF: '@setPickF',\r\n SETGIMPLUS: '@setGimplus',\r\n SETPROMOTOR: '@setPromotor',\r\n SETST: '@setST',\r\n SETCONDICOES: '@setCondicoes',\r\n SETCONDICAOINDEX: '@setCondicaoIndex',\r\n SETCONDICAOINDEXF: '@setCondicaoIndexF',\r\n SETCVV: '@setCVV',\r\n SETCONDICAOFATURADO: '@setCondicaoFaturado',\r\n RESETPAGAMENTO: '@resetPagamento'\r\n}\r\n\r\n//Reducer\r\nconst INITIAL_STATE = {\r\n pick: {},\r\n pickF: {},\r\n condicoes: {},\r\n condicaoFaturado: {},\r\n condicaoIndex: 0,\r\n condicaoIndexF: 0,\r\n gimplus: {},\r\n pagamento: {},\r\n pagamentoSeller: {},\r\n st: { destinoFiscal: undefined, icms: undefined, observacao: '' },\r\n cvv: ''\r\n}\r\n\r\nexport default function reducer(state = INITIAL_STATE, { type, payload }) {\r\n switch (type) {\r\n case Types.SETPAGAMENTO:\r\n return { ...state, pagamento: payload }\r\n case Types.SETPAGAMENTOSELLER:\r\n return { ...state, pagamentoSeller: payload }\r\n case Types.SETPICK:\r\n return { ...state, pick: payload }\r\n case Types.SETPICKF:\r\n return { ...state, pickF: payload }\r\n case Types.SETGIMPLUS:\r\n return { ...state, gimplus: payload }\r\n case Types.SETPROMOTOR:\r\n return { ...state, promotor: payload }\r\n case Types.SETST:\r\n return { ...state, st: { ...state.st, ...payload } }\r\n case Types.SETCONDICOES:\r\n return { ...state, condicoes: payload }\r\n case Types.SETCONDICAOINDEX:\r\n return { ...state, condicaoIndex: payload }\r\n case Types.SETCONDICAOINDEXF:\r\n return { ...state, condicaoIndexF: payload }\r\n case Types.SETCVV:\r\n return { ...state, cvv: payload }\r\n case Types.SETCONDICAOFATURADO:\r\n return { ...state, condicaoFaturado: payload }\r\n case Types.RESETPAGAMENTO:\r\n return INITIAL_STATE\r\n default:\r\n return state\r\n }\r\n}\r\n\r\n//Actions\r\nexport const setPagamento = (payload) => {\r\n return { type: Types.SETPAGAMENTO, payload: payload }\r\n}\r\n\r\nexport const setPagamentoSeller = (payload) => {\r\n return { type: Types.SETPAGAMENTOSELLER, payload: payload }\r\n}\r\n\r\nexport const setPick = (payload) => {\r\n return { type: Types.SETPICK, payload: payload }\r\n}\r\n\r\nexport const setPickF = (payload) => {\r\n return { type: Types.SETPICKF, payload: payload }\r\n}\r\n\r\nexport const setGimplusStore = (payload) => {\r\n return { type: Types.SETGIMPLUS, payload: payload }\r\n}\r\n\r\nexport const setPromotor = (payload) => {\r\n return { type: Types.SETPROMOTOR, payload: payload }\r\n}\r\n\r\nexport const setST = (field, value) => {\r\n return { type: Types.SETST, payload: { [field]: value } }\r\n}\r\n\r\nexport const setCondicoes = (payload) => {\r\n return { type: Types.SETCONDICOES, payload: payload }\r\n}\r\n\r\nexport const setCondicaoIndex = (payload) => {\r\n return { type: Types.SETCONDICAOINDEX, payload: payload }\r\n}\r\n\r\nexport const setCondicaoIndexF = (payload) => {\r\n return { type: Types.SETCONDICAOINDEXF, payload: payload }\r\n}\r\n\r\nexport const setCvv = (payload) => {\r\n return { type: Types.SETCVV, payload: payload }\r\n}\r\n\r\nexport const setCondicaoFaturado = (payload) => {\r\n return { type: Types.SETCONDICAOFATURADO, payload: payload }\r\n}\r\n\r\nexport const resetPagamento = () => {\r\n return { type: Types.RESETPAGAMENTO }\r\n}\r\n","import * as auth from './auth/auth'\r\n\r\nconst defaultOptions = {\r\n headers: {\r\n Authorization: `Bearer ${auth.token()}`,\r\n 'Content-Type': 'application/json',\r\n 'Access-Control-Allow-Origin': '*'\r\n }\r\n}\r\n\r\nexport default defaultOptions\r\n","import axios from 'axios'\r\nimport * as auth from './auth/auth'\r\nimport defaultOptions from './defaultoption'\r\n\r\nconst pagamento = {\r\n async getFormas(body, token = auth.token()) {\r\n return await fetch(\r\n process.env.REACT_APP_API_CHECKOUT + 'api/Pagamento/GetFormas',\r\n {\r\n method: 'POST',\r\n headers: {\r\n Authorization: `Bearer ${token}`,\r\n 'Content-Type': 'application/json',\r\n 'Access-Control-Allow-Origin': '*'\r\n },\r\n body: JSON.stringify(body),\r\n timeout: 45000\r\n }\r\n )\r\n },\r\n async getFormasSeller(body, token = auth.token()) {\r\n return await fetch(\r\n process.env.REACT_APP_API_CHECKOUT +\r\n 'api/Pagamento/GetFormasSomenteSeller',\r\n {\r\n method: 'POST',\r\n headers: {\r\n Authorization: `Bearer ${token}`,\r\n 'Content-Type': 'application/json',\r\n 'Access-Control-Allow-Origin': '*'\r\n },\r\n body: JSON.stringify(body),\r\n timeout: 45000\r\n }\r\n )\r\n },\r\n async getFormasGimba(body, token = auth.token()) {\r\n return await fetch(\r\n process.env.REACT_APP_API_CHECKOUT +\r\n 'api/Pagamento/GetFormasSomenteGimba',\r\n {\r\n method: 'POST',\r\n headers: {\r\n Authorization: `Bearer ${token}`,\r\n 'Content-Type': 'application/json',\r\n 'Access-Control-Allow-Origin': '*'\r\n },\r\n body: JSON.stringify(body),\r\n timeout: 45000\r\n }\r\n )\r\n },\r\n async addCartao(body, token = auth.token()) {\r\n return axios\r\n .post(\r\n `${process.env.REACT_APP_API_CHECKOUT}api/Pagamento/AdicionarCartaov2`,\r\n body,\r\n {\r\n headers: {\r\n Authorization: `Bearer ${token}`,\r\n 'Content-Type': 'application/json',\r\n 'Access-Control-Allow-Origin': '*'\r\n },\r\n timeout: 45000\r\n }\r\n )\r\n .catch((error) => error.response)\r\n },\r\n async delCartao(token) {\r\n return await fetch(\r\n process.env.REACT_APP_API_CHECKOUT + 'api/Pagamento/ExcluirToken',\r\n {\r\n method: 'POST',\r\n headers: {\r\n Authorization: `Bearer ${auth.token()}`,\r\n 'Content-Type': 'application/json',\r\n 'Access-Control-Allow-Origin': '*'\r\n },\r\n body: JSON.stringify({ Token: token })\r\n }\r\n )\r\n },\r\n async getCupom(cupom, token = auth.token()) {\r\n return await fetch(\r\n process.env.REACT_APP_API_CHECKOUT + `api/Cupom/GetCupom/${cupom}`,\r\n {\r\n method: 'POST',\r\n headers: {\r\n Authorization: `Bearer ${token}`,\r\n 'Content-Type': 'application/json',\r\n 'Access-Control-Allow-Origin': '*'\r\n }\r\n }\r\n )\r\n },\r\n async limpaCupom(token = auth.token()) {\r\n return await fetch(\r\n process.env.REACT_APP_API_CHECKOUT + 'api/Cupom/LimpaCupom',\r\n {\r\n method: 'POST',\r\n headers: {\r\n Authorization: `Bearer ${token}`,\r\n 'Content-Type': 'application/json',\r\n 'Access-Control-Allow-Origin': '*'\r\n }\r\n }\r\n )\r\n },\r\n async getGimplus(token = auth.token()) {\r\n return await fetch(process.env.REACT_APP_API_CHECKOUT + 'api/Gimplus/Get', {\r\n method: 'GET',\r\n headers: {\r\n Authorization: `Bearer ${token}`,\r\n 'Content-Type': 'application/json',\r\n 'Access-Control-Allow-Origin': '*'\r\n }\r\n })\r\n },\r\n async setGimplus(valor, token = auth.token()) {\r\n return await fetch(process.env.REACT_APP_API_CHECKOUT + 'api/Gimplus/Set', {\r\n method: 'POST',\r\n headers: {\r\n Authorization: `Bearer ${token}`,\r\n 'Content-Type': 'application/json',\r\n 'Access-Control-Allow-Origin': '*'\r\n },\r\n body: JSON.stringify({ ValorPontos: valor })\r\n })\r\n }\r\n}\r\n\r\nexport default pagamento\r\n","import pagamento from '../../api/pagamento'\n\nexport const getFormas = async (\n idEndereço,\n fretePick,\n save = () => undefined,\n load = () => undefined,\n store,\n activation,\n consumo = undefined,\n checked = false\n) => {\n load(true)\n const sellers = Object.keys(fretePick)\n .filter((e) => e !== 'Gimba' && e !== 'Agenda')\n .map((e) => ({ SellerId: fretePick[e].id + '', Valor: fretePick[e].value }))\n\n const isFaturado = () => {\n return (\n store.pagamento.condicaoFaturado?.IdTipo === 3 &&\n +store.pagamento?.condicaoIndex > 0 &&\n store.envio.resumo?.Carrinho.filter((e) => e.SellerId === null).length >\n 0 &&\n store.envio.resumo?.Carrinho.filter((e) => e.SellerId !== null).length > 0\n )\n }\n\n const periodo = (str) => {\n if (str === 'm') return 0\n if (str === 't') return 1\n if (str === 'n') return 2\n }\n\n const agendamento = (fretePick) => ({\n Selecionada: fretePick.Agenda?.id === 'agenda',\n Data: fretePick.Agenda?.id === 'agenda.teste' ? fretePick.Agenda?.date : '',\n Perido:\n fretePick.Agenda?.id === 'agenda' ? periodo(fretePick.Agenda?.turno) : 0\n })\n\n const body = {\n Frete: {\n FreteGimba: {\n IdTransportadora: fretePick.Gimba?.id?.trim(),\n Valor: fretePick.Gimba?.value,\n DiasParaEntrega: fretePick.Gimba?.time,\n Retira: false,\n FOB: false,\n Agendamento: {\n Selecionada: false,\n Data: '',\n Periodo: 0\n }\n },\n FreteSellers: sellers\n },\n SituacaoTributariaConsumo: consumo !== undefined ? consumo : true,\n SituacaoTributariaSelecionada: activation,\n SituacaoTributariaIcms: checked,\n\n IdEnderecoSelecionado: idEndereço,\n DescricaoFormaPagamento: ''\n }\n\n let res = isFaturado()\n ? await pagamento.getFormasGimba(body)\n : await pagamento.getFormas(body)\n res = await res.json()\n save(res)\n load(false)\n}\n\nexport const getFormasSeller = async (\n idEndereço,\n fretePick,\n save,\n load = () => undefined,\n store\n) => {\n load(true)\n const sellers = Object.keys(fretePick)\n .filter((e) => e !== 'Gimba' && e !== 'Agenda')\n .map((e) => ({ SellerId: fretePick[e].id + '', Valor: fretePick[e].value }))\n\n const periodo = (str) => {\n if (str === 'm') return 0\n if (str === 't') return 1\n if (str === 'n') return 2\n }\n\n const agendamento = (fretePick) => ({\n Selecionada: fretePick.Agenda?.id === 'agenda',\n Data: fretePick.Agenda?.id === 'agenda.teste' ? fretePick.Agenda?.date : '',\n Perido:\n fretePick.Agenda?.id === 'agenda' ? periodo(fretePick.Agenda?.turno) : 0\n })\n\n const body = {\n Frete: {\n FreteSellers: sellers\n },\n SituacaoTributariaConsumo: true,\n SituacaoTributariaIcms: false,\n SituacaoTributariaSelecionada: false,\n IdEnderecoSelecionado: idEndereço,\n DescricaoFormaPagamento: ''\n }\n\n let res = await pagamento.getFormasSeller(body)\n res = await res.json()\n\n save(res)\n load(false)\n}\n","export const convertDecimalCurrency = (str) => {\n return str?.toLocaleString('pt-BR', { style: 'currency', currency: 'BRL' })\n}\n\nexport const convertDecimalPercentage = (str) => {\n return (str * 100)?.toLocaleString('pt-BR', { minimumSignificantDigits: 3 })\n}\n\nexport const formatarParaPorcentagem = (numero) => {\n const numeroFormatado = parseFloat(numero).toFixed(2)\n const numeroComVirgula = numeroFormatado.replace('.', ',')\n return `${numeroComVirgula}%`\n}\n\nexport const capitalizeWord = (str) => {\n return str.toLowerCase().charAt(0).toUpperCase() + str.slice(1).toLowerCase()\n}\n\nexport const capitalizePhrase = (str) => {\n return (\n str &&\n str\n .toLowerCase()\n .split(' ')\n .map((word) => word.charAt(0).toUpperCase() + word.substring(1))\n .join(' ')\n )\n}\n\nexport const removeSecondsFromTime = (value) => {\n const time = value?.slice(0, 6).split(':')\n return `${time[0]}:${time[1]}`\n}\n\nexport const precoMask = (val = 0, negative = false) => {\n if (val === 0 || val === undefined) return '-'\n if (isNaN(val)) val = 0\n val = val.toLocaleString('pt-BR', { style: 'currency', currency: 'BRL' })\n // if (val.slice(-3, -2) !== ',') val = val + ',00'\n return negative ? '- ' + val : val\n}\n\nexport const gimplusValueMask = (val = 0) => {\n // eslint-disable-next-line eqeqeq\n if (val + ''.length == 0) return ''\n\n if ((val + '')[0] === '0') return 'doidera'\n return 'R$ ' + val\n}\n\nexport const onlyNumber = (value) => {\n return value.replace(/[^0-9]/g, '')\n}\n\nexport const gimplusValue = (value = '0') => {\n let v = value.replace(/[^0-9,]/g, '')\n let ind = v.indexOf(',')\n let lastInd = v.lastIndexOf(',')\n let max = v.slice(0, ind + 3)\n if (ind !== lastInd) return v.slice(0, lastInd)\n return ind !== -1 ? max : v\n}\n\nexport const cellNumberMask = (value) => {\n if (typeof value === 'string')\n return value\n .replace(/\\D/g, '')\n .replace(/(\\d{5})(\\d)/, '$1-$2')\n .replace(/(\\(\\d{2}\\)\\s\\d{5}-\\d{4})\\d+?$/, '$1')\n return ''\n}\n\nexport const tokenMask = (value) => {\n return value\n .toUpperCase()\n .replace(/[^0-9A-Z]/g, '')\n .replace(/([0-9A-Z]{4})([0-9A-Z])/, '$1-$2')\n .replace(/([0-9A-Z]{4})([0-9A-Z])/, '$1-$2')\n .replace(/([0-9A-Z]{4})([0-9A-Z])/, '$1-$2')\n .replace(\n /([0-9A-Z]{4}-[0-9A-Z]{4}-[0-9A-Z]{4}-[0-9A-Z]{4})[0-9A-Z]+?$/,\n '$1'\n )\n}\n\nexport const showFullFlagName = (flag) => {\n if (flag === 'Amex') {\n return 'American Express'\n } else if (flag === 'Diners') {\n return \"Diner's Club\"\n } else {\n return flag\n }\n}\n\nexport function getSafe(fn, defaultVal) {\n try {\n return fn()\n } catch (e) {\n return defaultVal\n }\n}\n\nexport function iframeLink(websiteUrl) {\n if (window.self !== window.top) {\n // checking if it is an iframe\n return (window.parent.location.href = websiteUrl)\n } else {\n return (window.location.href = websiteUrl)\n }\n}\n","import defaultOptions from './defaultoption'\r\nimport * as auth from './auth/auth'\r\n\r\nconst carrinho = {\r\n async getResumo(addressId, token = auth.token()) {\r\n return await fetch(\r\n `${process.env.REACT_APP_API_CHECKOUT}api/OnePage/Resumo/${addressId}`,\r\n {\r\n method: 'GET',\r\n headers: {\r\n Authorization: `Bearer ${token}`,\r\n 'Content-Type': 'application/json',\r\n 'Access-Control-Allow-Origin': '*'\r\n },\r\n timeout: 45000\r\n }\r\n )\r\n },\r\n async getFrete(body) {\r\n return await fetch(\r\n `${process.env.REACT_APP_API_CHECKOUT}api/Enderecos/Select`,\r\n {\r\n method: 'POST',\r\n headers: {\r\n Authorization: `Bearer ${auth.token()}`,\r\n 'Content-Type': 'application/json',\r\n 'Access-Control-Allow-Origin': '*'\r\n },\r\n body: JSON.stringify(body),\r\n timeout: 45000\r\n }\r\n )\r\n },\r\n async postPedido(body) {\r\n return await fetch(\r\n `${process.env.REACT_APP_API_CHECKOUT}api/Pedido/Salvar`,\r\n {\r\n method: 'POST',\r\n headers: {\r\n Authorization: `Bearer ${auth.token()}`,\r\n 'Content-Type': 'application/json',\r\n 'Access-Control-Allow-Origin': '*'\r\n },\r\n body: JSON.stringify(body),\r\n timeout: 45000\r\n }\r\n )\r\n },\r\n async postPedidoFaturado(body) {\r\n return await fetch(\r\n `${process.env.REACT_APP_API_CHECKOUT}api/Pedido/SalvarPJFaturado`,\r\n {\r\n method: 'POST',\r\n headers: {\r\n Authorization: `Bearer ${auth.token()}`,\r\n 'Content-Type': 'application/json',\r\n 'Access-Control-Allow-Origin': '*'\r\n },\r\n body: JSON.stringify(body),\r\n timeout: 45000\r\n }\r\n )\r\n },\r\n async postCotacao(body) {\r\n return await fetch(\r\n `${process.env.REACT_APP_API_CHECKOUT}api/CotacaoNegociacao/Salvar`,\r\n {\r\n method: 'POST',\r\n headers: {\r\n Authorization: `Bearer ${auth.token()}`,\r\n 'Content-Type': 'application/json',\r\n 'Access-Control-Allow-Origin': '*'\r\n },\r\n body: JSON.stringify(body),\r\n timeout: 45000\r\n }\r\n )\r\n },\r\n async getImage(id = 66941) {\r\n return await fetch(`${process.env.REACT_APP_URL_IMAGES}${id}`, {\r\n method: 'GET',\r\n headers: defaultOptions.headers,\r\n timeout: 45000\r\n })\r\n }\r\n}\r\n\r\nexport default carrinho\r\n","import carrinho from '../../api/carrinho'\r\n\r\nexport const getResumo = async (\r\n addressId,\r\n save,\r\n load,\r\n error = () => undefined,\r\n token\r\n) => {\r\n load(true)\r\n let res = await carrinho.getResumo(addressId, token)\r\n if (!res.ok) error()\r\n res = await res.json()\r\n save(res)\r\n load(false)\r\n}\r\n\r\nexport const getFrete = async (\r\n id,\r\n resumo,\r\n save,\r\n load,\r\n wg = () => undefined,\r\n error = () => undefined\r\n) => {\r\n load(true)\r\n let body = {\r\n IdEndereco: id,\r\n ProdutosConcatenados: resumo.FreteCondicoes?.ProdutosConcatenados,\r\n tipoPedido: 'P'\r\n }\r\n let res = await carrinho.getFrete(body)\r\n if (!res.ok) error()\r\n res = await res.json()\r\n await save(res)\r\n wg()\r\n load(false)\r\n}\r\n\r\n// PesoProdutos: resumo.FreteCondicoes?.PesoProdutos,\r\n// PesoEspecialProdutos: resumo.FreteCondicoes?.PesoEspecialProdutos,\r\n// QuantidadeDiasManuseio: resumo.FreteCondicoes?.QuantidadeDiasManuseio,\r\n// PrazoEntregaEspecial: resumo.FreteCondicoes?.PrazoEntregaEspecial,\r\n// TransporteEspecial: resumo.FreteCondicoes?.TransporteEspecial,\r\n// FreteFull: resumo.FreteCondicoes?.FreteFull,\r\n// ValorProdutos: resumo?.ValorProdutos\r\n","import pagamento from '../../../api/pagamento'\r\nimport clientes from '../../../api/clientes'\r\nimport { getFormas } from '../../../pages/Pagamento/fetch'\r\nimport { convertDecimalCurrency } from '../../../utils/utils'\r\nimport { getResumo, getFrete } from '../../../pages/Envio/fetch'\r\nimport { token } from '../../../api/auth/auth'\r\nimport carrinho from '../../../api/carrinho'\r\n\r\n//cupom\r\nexport const preCupom = async (\r\n cupom,\r\n store,\r\n saveResumo,\r\n saveFrete,\r\n saveFretePick,\r\n savePagamento,\r\n load = () => undefined,\r\n msg = () => undefined\r\n) => {\r\n load(true)\r\n let res = await pagamento.getCupom(cupom)\r\n await getResumo(\r\n store.endereco.padrao?.id,\r\n saveResumo,\r\n () => undefined,\r\n token()\r\n )\r\n\r\n let bodyFrete = {\r\n IdEndereco: store.endereco.padrao?.id,\r\n ProdutosConcatenados:\r\n store.envio.resumo.FreteCondicoes?.ProdutosConcatenados,\r\n tipoPedido: 'P'\r\n }\r\n let frete = await carrinho.getFrete(bodyFrete)\r\n\r\n if (!frete.ok) return\r\n frete = await frete.json()\r\n await saveFrete(frete)\r\n let ret = false\r\n await getFormasCupom(saveFretePick, savePagamento, store, frete)\r\n\r\n if (res.ok) ret = await res.json()\r\n if (!ret) {\r\n msg({\r\n type: 'error',\r\n title: `Problema ao aplicar Cupom. Tente novamente mais tarde`\r\n })\r\n } else if (ret?.Validation?.IsValid === true) {\r\n msg({\r\n type: 'success',\r\n title: `Cupom Aplicado`\r\n })\r\n } else if (ret?.Validation?.IsValid === false) {\r\n msg({\r\n type: 'error',\r\n title: `${ret?.Validation?.Errors[0]?.Message}`\r\n })\r\n }\r\n load(false)\r\n return 'ok'\r\n}\r\n\r\nexport const getFormasCupom = async (saveFretePick, save, store, frete) => {\r\n let newFrete = await frete.Gimba?.OpcoesFrete?.filter(\r\n (el) => el?.Id === store.envio.fretePick?.Gimba?.id\r\n )[0]\r\n\r\n let newPick = {\r\n id: newFrete?.Id,\r\n name: newFrete?.RazaoSocial,\r\n time: newFrete?.DiasParaEntrega,\r\n value: newFrete?.ValorFrete,\r\n ValorFreteAgendado: newFrete?.ValorFreteAgendado\r\n }\r\n\r\n await saveFretePick(newPick)\r\n await getFormas(\r\n store.endereco.padrao.id,\r\n { ...store.envio.fretePick, Gimba: newPick },\r\n save,\r\n () => undefined,\r\n store,\r\n store.pagamento.st.icms !== undefined,\r\n store.pagamento.st.destinoFiscal !== 'revenda'\r\n )\r\n}\r\n\r\nexport const limpaCupom = async (\r\n store,\r\n saveResumo,\r\n saveFrete,\r\n saveFretePick,\r\n savePagamento,\r\n load = () => undefined,\r\n msg = () => undefined\r\n) => {\r\n load(true)\r\n let res = await pagamento.limpaCupom()\r\n await getResumo(\r\n store.endereco.padrao?.id,\r\n saveResumo,\r\n () => undefined,\r\n token()\r\n )\r\n\r\n let bodyFrete = {\r\n IdEndereco: store.endereco.padrao?.id,\r\n ProdutosConcatenados:\r\n store.envio.resumo.FreteCondicoes?.ProdutosConcatenados,\r\n tipoPedido: 'P'\r\n }\r\n let frete = await carrinho.getFrete(bodyFrete)\r\n\r\n if (!frete.ok) return\r\n frete = await frete.json()\r\n await saveFrete(frete)\r\n await getFormasCupom(saveFretePick, savePagamento, store, frete)\r\n load(false)\r\n if (res.ok) {\r\n msg({\r\n type: 'success',\r\n title: `Cupom Removido`\r\n })\r\n }\r\n}\r\n\r\n//gimplus\r\nexport const getGimplus = async (save, load = () => undefined) => {\r\n load(true)\r\n let res = await pagamento.getGimplus()\r\n res = await res.json()\r\n save(res)\r\n load(false)\r\n}\r\nexport const setGimplus = async (\r\n valor,\r\n store,\r\n save,\r\n idEndereço,\r\n fretePick,\r\n save2,\r\n load = () => undefined,\r\n msg = () => undefined\r\n) => {\r\n load(true)\r\n if (typeof valor == 'string') valor = valor.replace(/,/g, '.')\r\n valor = parseFloat(Number(valor).toFixed(2))\r\n\r\n const minGimplus = store.envio.resumo?.ValorMinimoGimplus\r\n const percentualGimplus = store.envio.resumo?.ValorPercentualGimplus / 100\r\n\r\n let valorCalc = valor\r\n const saldo =\r\n store.pagamento.gimplus?.Total - store.pagamento.gimplus?.Utilizado\r\n\r\n if (valorCalc > saldo) {\r\n load(false)\r\n return msg('Valor acima do saldo disponível', 'error')\r\n }\r\n\r\n const valorProdutos =\r\n store.envio.resumo?.ValorProdutos ||\r\n store.pagamento.pagamento?.Resumo?.ValorProdutos\r\n\r\n if (valorCalc > percentualGimplus * valorProdutos) {\r\n load(false)\r\n return msg(\r\n `O valor do gimplus a ser utilizado não deve ultrapassar ${store.envio.resumo?.ValorPercentualGimplus}% do valor dos produtos vendidos e entregues pelo Gimba`,\r\n 'error',\r\n 5000\r\n )\r\n }\r\n\r\n if (store.pagamento.gimplus?.Total === 0) {\r\n load(false)\r\n return msg('Não existe saldo para essa operação', 'error')\r\n }\r\n if (valorProdutos === 0) {\r\n load(false)\r\n return msg('Gimplus somente aplicável em produtos Gimba', 'error')\r\n }\r\n if (store.envio.resumo?.ValorMinimoGimplus > store.pagamento.gimplus.Total) {\r\n load(false)\r\n return msg(\r\n `No momento seu saldo está abaixo do mínimo permitido para utilização, que é de ${convertDecimalCurrency(\r\n store.envio.resumo?.ValorMinimoGimplus\r\n )}`,\r\n 'error',\r\n 5000\r\n )\r\n }\r\n //Verifica se valor inserido no Gimplus é menor que o mínimo do webConfig\r\n if (valor !== 0 && valor < minGimplus) {\r\n load(false)\r\n return msg(\r\n `O valor mínimo de uso do Gimplus é de ${convertDecimalCurrency(\r\n minGimplus\r\n )}`,\r\n 'error'\r\n )\r\n }\r\n if (valorProdutos <= minGimplus) {\r\n load(false)\r\n return msg(\r\n `O valor mínimo de produtos Gimba para o Gimplus é ${convertDecimalCurrency(\r\n minGimplus\r\n )}`,\r\n 'error'\r\n )\r\n }\r\n\r\n const res = await pagamento.setGimplus(\r\n parseFloat(Number(valorCalc).toFixed(2))\r\n )\r\n\r\n await getGimplus(save)\r\n await getFormas(\r\n idEndereço,\r\n fretePick,\r\n save2,\r\n () => undefined,\r\n store,\r\n store.pagamento.st.icms !== undefined,\r\n store.pagamento.st.destinoFiscal !== 'revenda'\r\n )\r\n load(false)\r\n if (res.ok) return msg()\r\n}\r\n\r\n//promotor\r\nexport const getPromotorVendas = async (\r\n promotor,\r\n save,\r\n load = () => undefined,\r\n msg = () => undefined\r\n) => {\r\n load(true)\r\n let res = await clientes.getPromotorVendas(promotor)\r\n let resbody = await res.json()\r\n msg(resbody.Mensagem)\r\n // if (!!resbody.codigoPromotorGimba) msg('Teste')\r\n save(resbody)\r\n load(false)\r\n}\r\n","import { getPromotorVendas } from '../components/PaymentCards/GimbaCard/fetch'\r\nimport defaultOptions from './defaultoption'\r\n\r\nconst clientes = {\r\n async getLoggedUserPF(params) {\r\n return await fetch(\r\n process.env.REACT_APP_API_CLIENTES + 'clientes/pessoas-fisicas',\r\n params\r\n )\r\n },\r\n async getLoggedUserPJ(params) {\r\n return await fetch(\r\n process.env.REACT_APP_API_CLIENTES + 'clientes/pessoas-juridicas',\r\n params\r\n )\r\n },\r\n async getLoggedCompany(params) {\r\n return await fetch(\r\n process.env.REACT_APP_API_CLIENTES + 'clientes-pessoas-juridicas',\r\n params\r\n )\r\n },\r\n async post(params) {\r\n return await fetch(\r\n process.env.REACT_APP_API_CLIENTES + 'clientes/pessoas-fisicas',\r\n params\r\n )\r\n },\r\n async cargos() {\r\n return await fetch(process.env.REACT_APP_API_CLIENTES + 'cargos', {\r\n method: 'GET',\r\n headers: defaultOptions.headers\r\n })\r\n },\r\n async departamentos() {\r\n return await fetch(process.env.REACT_APP_API_CLIENTES + 'departamentos', {\r\n method: 'GET',\r\n headers: defaultOptions.headers\r\n })\r\n },\r\n async atividades() {\r\n return await fetch(process.env.REACT_APP_API_CLIENTES + 'atividades', {\r\n method: 'GET',\r\n headers: defaultOptions.headers\r\n })\r\n },\r\n async subAtividades(idAtividade) {\r\n return await fetch(\r\n `${process.env.REACT_APP_API_CLIENTES}atividades/${idAtividade}/sub-atividades`\r\n )\r\n },\r\n async funcionarios() {\r\n return await fetch(process.env.REACT_APP_API_CLIENTES + 'funcionarios', {\r\n method: 'GET',\r\n headers: defaultOptions.headers\r\n })\r\n },\r\n async enderecos(params = defaultOptions) {\r\n return await fetch(\r\n `${process.env.REACT_APP_API_CLIENTES}clientes/enderecos`,\r\n { timeout: 45000, ...params }\r\n )\r\n },\r\n async getTokenParceria(token) {\r\n return await fetch(\r\n `${process.env.REACT_APP_API_CLIENTES}parcerias/token/${token}`,\r\n {\r\n method: 'GET',\r\n headers: defaultOptions.headers\r\n }\r\n )\r\n },\r\n async postTokenParceria(token) {\r\n return await fetch(\r\n `${process.env.REACT_APP_API_CLIENTES}parcerias/token/${token}`,\r\n {\r\n method: 'POST',\r\n headers: defaultOptions.headers\r\n }\r\n )\r\n },\r\n async postPromotorVendas() {\r\n return await fetch(`${process.env.REACT_APP_API_CLIENTES}promotor`, {\r\n method: 'POST',\r\n headers: defaultOptions.headers\r\n })\r\n },\r\n async getNews() {\r\n return await fetch(\r\n `${process.env.REACT_APP_API_CLIENTES}newsletter/receber`,\r\n {\r\n method: 'GET',\r\n headers: defaultOptions.headers\r\n }\r\n )\r\n },\r\n async patchNews(body) {\r\n return await fetch(\r\n `${process.env.REACT_APP_API_CLIENTES}newsletter/receber`,\r\n {\r\n method: 'PATCH',\r\n headers: defaultOptions.headers,\r\n body: JSON.stringify(body)\r\n }\r\n )\r\n },\r\n async validateEmail(email) {\r\n return await fetch(\r\n `${process.env.REACT_APP_API_CLIENTES}clientes/validar-email?email=${email}`,\r\n {\r\n method: 'GET',\r\n headers: defaultOptions.headers\r\n }\r\n )\r\n },\r\n async getPromotorVendas(promotor) {\r\n return await fetch(\r\n `${process.env.REACT_APP_API_CHECKOUT}api/OnePage/ClienteDadosPromotor/${promotor}`,\r\n {\r\n method: 'GET',\r\n headers: defaultOptions.headers\r\n }\r\n )\r\n },\r\n async updateTelefone(params) {\r\n return fetch(\r\n `${process.env.REACT_APP_API_CLIENTES}clientes/telefone`,\r\n params\r\n )\r\n }\r\n}\r\n\r\nexport default clientes\r\n","export const estadosST = [\r\n 'AC',\r\n 'AL',\r\n 'AP',\r\n 'AM',\r\n 'BA',\r\n 'CE',\r\n 'DF',\r\n 'ES',\r\n 'GO',\r\n 'MA',\r\n 'MT',\r\n 'MS',\r\n 'MG',\r\n 'PA',\r\n 'PB',\r\n 'PR',\r\n 'PE',\r\n 'PI',\r\n 'RJ',\r\n 'RN',\r\n 'RS',\r\n 'RO',\r\n 'RR',\r\n 'SC',\r\n 'SE',\r\n 'TO'\r\n]\r\n","import jwt from 'jsonwebtoken'\r\nimport { isPF, token } from '../api/auth/auth'\r\nimport clientes from '../api/clientes'\r\nimport defaultOptions from '../api/defaultoption'\r\nimport { estadosST } from './estadosST'\r\n\r\nconst tokenDecoded = jwt.decode(token())\r\n\r\nexport const isInscricaoEstadualIsento = () => {\r\n if (tokenDecoded?.tipoCliente === 'J') {\r\n return tokenDecoded?.inscricaoEstadual === 'ISENTO'\r\n } else {\r\n return null\r\n }\r\n}\r\n\r\n// export const getIE = () => {\r\n// return tokenDecoded?.inscricaoEstadual\r\n// }\r\n\r\nexport const getIEFixed = async () => {\r\n let user = await clientes.getLoggedUserPJ({\r\n method: 'GET',\r\n headers: defaultOptions.headers\r\n })\r\n\r\n return user\r\n}\r\n\r\nexport const getFaturamentoUF = (addressList) => {\r\n if (!isPF() && addressList[0]?.tipoEndereco !== 'C') {\r\n return addressList[0]?.uf\r\n } else {\r\n return addressList.filter((item) => item.tipoEndereco === 'C')[0]?.uf\r\n }\r\n}\r\n\r\nexport const isMaxAdressLimit = (userAddress) => {\r\n if (userAddress.length >= 5) {\r\n return true\r\n }\r\n}\r\n\r\nexport const allowAddEnderecoEntregaPJ = (faturamentoUF) => {\r\n if (\r\n !isInscricaoEstadualIsento() &&\r\n (faturamentoUF === 'SP' || faturamentoUF === 'RJ')\r\n ) {\r\n // console.log('permitir Adicionar')\r\n return true\r\n } else if (\r\n !isInscricaoEstadualIsento() &&\r\n (faturamentoUF !== 'SP' || faturamentoUF !== 'RJ')\r\n ) {\r\n // console.log('bloquer Adicionar')\r\n return false\r\n } else {\r\n // console.log('permitir Adicionar')\r\n return true\r\n }\r\n}\r\n\r\n// const user = jwt.decode(token())\r\n\r\nexport const checkRevendaPj = (user) => {\r\n if (user.idAtividade == '5' && user.idSubAtividade == '501') {\r\n return true\r\n } else return false\r\n}\r\n\r\nexport const checkGovernoPj = (user) => {\r\n if (user.idAtividade == '6' && user.idSubAtividade == '606') {\r\n // console.log('show')\r\n return true\r\n } else {\r\n return false\r\n }\r\n}\r\n\r\nexport const checkEstadoST = (store) => {\r\n return estadosST.some((item) => item === store.endereco.padrao.uf)\r\n}\r\n\r\nconst ufsPermitidas = ['SP', 'RJ']\r\n\r\nexport const allowNewAddress = (address, inscEst) => {\r\n const faturamento = address?.filter((item) => item.tipoEndereco === 'C')\r\n // console.log('TESTE', address, inscEst)\r\n if (\r\n !isPF() &&\r\n !ufsPermitidas.includes(faturamento[0]?.uf) &&\r\n inscEst !== 'ISENTO'\r\n ) {\r\n return false\r\n } else if (!isPF() && inscEst === 'ISENTO') {\r\n return true\r\n } else {\r\n return true\r\n }\r\n // return faturamento[0].uf\r\n}\r\n","import jwt from 'jsonwebtoken'\r\nimport defaultOptions from '../../api/defaultoption'\r\nimport * as auth from '../../api/auth/auth'\r\nimport clientes from '../../api/clientes'\r\nimport {\r\n allowAddEnderecoEntregaPJ,\r\n getFaturamentoUF\r\n} from '../../utils/validatePJ'\r\n\r\nexport const getAddress = async (\r\n save1,\r\n save2,\r\n router = () => undefined,\r\n error = () => undefined,\r\n token\r\n) => {\r\n try {\r\n let res = await clientes.enderecos({\r\n method: 'GET',\r\n headers: {\r\n Authorization: `Bearer ${token}`,\r\n 'Content-Type': 'application/json',\r\n 'Access-Control-Allow-Origin': '*'\r\n }\r\n })\r\n\r\n res = await res.json()\r\n\r\n const faturamentoUF = await getFaturamentoUF(res)\r\n await save1(res)\r\n if (Array.isArray(res)) {\r\n localStorage.setItem('localEndereco', JSON.stringify(res[0]))\r\n sessionStorage.setItem('localEndereco', JSON.stringify(res[0]))\r\n } else {\r\n localStorage.setItem('localEndereco', JSON.stringify(res))\r\n sessionStorage.setItem('localEndereco', JSON.stringify(res))\r\n }\r\n //validar endereços PJ\r\n const validateAddNewAddress = () => {\r\n if (!auth.isPF() && !allowAddEnderecoEntregaPJ(faturamentoUF)) {\r\n return false\r\n // setCurrent(1)\r\n } else {\r\n return true\r\n // setCurrent(1)\r\n }\r\n }\r\n\r\n //endereço padrão\r\n if (!auth.isPF() && !validateAddNewAddress()) {\r\n const padrao1 = await res.find((e) => e.tipoEndereco === 'C')\r\n const padrao2 = await res.find((e) => e.padrao)\r\n await save2(padrao1 || padrao2 || res[0] || {})\r\n\r\n return router()\r\n } else {\r\n const padrao1 = await res.find((e) => e.padrao)\r\n const padrao2 = await res.find((e) => e.tipoEndereco === 'E')\r\n save2(padrao1 || padrao2 || res[0] || {})\r\n return router()\r\n }\r\n } catch (e) {\r\n if (token === null || token === 'null') {\r\n return (window.location.href = process.env.REACT_APP_URL_MAIN)\r\n } else {\r\n error()\r\n }\r\n }\r\n}\r\n\r\nexport const fetchUser = async (updateState) => {\r\n let user\r\n const stringToken = auth.getToken()\r\n const token = jwt.decode(stringToken)\r\n\r\n try {\r\n if (token?.cpf?.trim() !== '' && token?.cpf?.trim() !== undefined) {\r\n user = await clientes.getLoggedUserPF({\r\n method: 'GET',\r\n headers: {\r\n Authorization: `Bearer ${stringToken}`,\r\n 'Content-Type': 'application/json',\r\n 'Access-Control-Allow-Origin': '*'\r\n }\r\n })\r\n } else {\r\n user = await clientes.getLoggedUserPJ({\r\n method: 'GET',\r\n headers: {\r\n Authorization: `Bearer ${stringToken}`,\r\n 'Content-Type': 'application/json',\r\n 'Access-Control-Allow-Origin': '*'\r\n }\r\n })\r\n }\r\n user = await user.json()\r\n\r\n // console.log('tokenOld', token)\r\n // console.log('CPF', token?.cpf?.trim())\r\n // console.log('CNPJ', token?.cnpj?.trim())\r\n // console.log('UserFetch', user)\r\n\r\n updateState({ ...token, ...user[0] })\r\n } catch (error) {\r\n auth.authCheck()\r\n }\r\n}\r\n\r\nexport const authRoute = async () => {}\r\n","//Keys\r\nexport const Types = {\r\n SETUSERINFO: '@setUserInfo',\r\n SETUSERADDRESS: '@setUserAddress',\r\n RESETUSER: '@resetUser'\r\n}\r\n\r\n//Reducer\r\nconst INITIAL_STATE = {\r\n info: {},\r\n address: {}\r\n}\r\n\r\nexport default function reducer(state = INITIAL_STATE, { type, payload }) {\r\n switch (type) {\r\n case Types.SETUSERINFO:\r\n return { ...state, info: payload }\r\n case Types.SETUSERADDRESS:\r\n return { ...state, address: payload }\r\n case Types.RESETUSER:\r\n return INITIAL_STATE\r\n default:\r\n return state\r\n }\r\n}\r\n\r\n//Actions\r\nexport const setUserInfo = (payload) => {\r\n return { type: Types.SETUSERINFO, payload: payload }\r\n}\r\n\r\nexport const setUserAddress = (payload) => {\r\n return { type: Types.SETUSERADDRESS, payload: payload }\r\n}\r\n\r\nexport const resetUser = () => {\r\n return { type: Types.RESETUSER }\r\n}\r\n","import { token } from './auth/auth'\r\n\r\nconst traceLog = {\r\n async logAcessos(body) {\r\n return await fetch(\r\n `${process.env.REACT_APP_API_CHECKOUT}api/Pedido/SalvarDadosRastreamento`,\r\n // `${process.env.REACT_APP_API_ENDPOINT}trace-log/LogAcessos`,\r\n {\r\n method: 'POST',\r\n headers: {\r\n Authorization: `Bearer ${token()}`,\r\n 'Content-Type': 'application/json'\r\n },\r\n body: JSON.stringify(body)\r\n }\r\n )\r\n }\r\n}\r\n\r\nexport default traceLog\r\n","import axios from 'axios'\r\nimport traceLog from '../api/traceLog'\r\nimport { token } from '../api/auth/auth'\r\nimport jwt from 'jsonwebtoken'\r\n\r\nexport const traceLogAcessos = async (path) => {\r\n // const { data } = await axios.get('https://www.myexternalip.com/json')\r\n // postLogAcessos(data.ip, window.location.href, path)\r\n}\r\n\r\nconst userInfo = jwt.decode(token())\r\n\r\nexport const getQueryParamsToTracelog = (query) => {\r\n const currentUrl = window.location.origin + window.location.pathname\r\n const clientip = query.get('clientip')\r\n const utmSource = query.get('u_src')\r\n const utmMedium = query.get('u_med')\r\n const utmCampaign = query.get('u_camp')\r\n const redirectUrl = query.get('redirectUrl')\r\n\r\n localStorage.removeItem('u_src')\r\n // localStorage.removeItem('clientip')\r\n localStorage.removeItem('u_med')\r\n localStorage.removeItem('u_camp')\r\n\r\n if (clientip !== null) {\r\n localStorage.setItem('clientip', clientip)\r\n\r\n // localStorage.getItem('clientip')\r\n } else {\r\n if (localStorage.getItem('clientip') === '') {\r\n localStorage.setItem('clientip', '')\r\n }\r\n }\r\n\r\n utmSource !== null && localStorage.setItem('u_src', utmSource)\r\n utmMedium !== null && localStorage.setItem('u_med', utmMedium)\r\n utmCampaign !== null && localStorage.setItem('u_camp', utmCampaign)\r\n\r\n localStorage.setItem('redirectUrl', redirectUrl)\r\n\r\n // postLogAcessos(clientip, currentUrl, redirectUrl, utmSource, utmMedium, utmCampaign)\r\n}\r\n\r\nexport const postLogAcessos = async (\r\n ip,\r\n currentUrl,\r\n previousUrl,\r\n utmSource,\r\n utmMedium,\r\n utmCampaign\r\n) => {\r\n const body = {\r\n // ip: ip === null ? '' : ip,\r\n // utmSource: utmSource,\r\n // utmMedium: utmMedium,\r\n // utmCampaign: utmCampaign,\r\n // url: currentUrl,\r\n // httpReferer: previousUrl,\r\n // // idLojaEspecial: 0,\r\n // adWords: 0,\r\n // idLojaVirtual: 1\r\n Url: currentUrl,\r\n HttpReferer: previousUrl,\r\n EmailCliente: userInfo?.email\r\n }\r\n // console.log('POST', body)\r\n\r\n let res = await traceLog.logAcessos(body)\r\n res = await res.json()\r\n return res\r\n}\r\n\r\nexport const getLocalStorageLog = async (currentPath) => {\r\n const previousUrl = window.location.origin\r\n const clientip = localStorage.getItem('clientip')\r\n const utmSource = localStorage.getItem('u_src')\r\n const utmMedium = localStorage.getItem('u_med')\r\n const utmCampaign = localStorage.getItem('u_camp')\r\n let redirectUrl = localStorage.getItem('redirectUrl')\r\n\r\n if (redirectUrl === null || redirectUrl === 'null') {\r\n redirectUrl = window.location.origin + window.location.pathname\r\n }\r\n\r\n try {\r\n await postLogAcessos(\r\n clientip,\r\n redirectUrl,\r\n previousUrl,\r\n utmSource,\r\n utmMedium,\r\n utmCampaign\r\n )\r\n } catch (e) {}\r\n}\r\n","/* eslint-disable react-hooks/exhaustive-deps */\r\nimport { useEffect } from 'react'\r\nimport { useQueryParam, StringParam } from 'use-query-params'\r\nimport { login } from '../../api/auth/auth'\r\nimport Loader from '../../components/Loader'\r\nimport { useHistory } from 'react-router-dom'\r\nimport { useDispatch, useSelector } from 'react-redux'\r\nimport { setEndereco, setPadrao } from '../../store/ducks/endereco'\r\nimport { setPromotor } from '../../store/ducks/pagamento'\r\nimport { fetchUser, getAddress } from './fetch'\r\nimport { useState } from 'react'\r\nimport { setUserInfo } from '../../store/ducks/user'\r\nimport { useQuery } from '../../hooks/useQuery'\r\nimport { getQueryParamsToTracelog } from '../../utils/traceLogAcessos'\r\n\r\nconst Login = () => {\r\n const router = useHistory()\r\n const [token] = useQueryParam('token', StringParam)\r\n const [promotor] = useQueryParam('promotor', StringParam)\r\n const [tipo] = useQueryParam('tipo', StringParam)\r\n const dispatch = useDispatch()\r\n const store = useSelector((reduxState) => reduxState)\r\n\r\n const query = useQuery()\r\n\r\n const [wait, setWait] = useState(0)\r\n\r\n const [userData, setUserData] = useState('')\r\n\r\n useEffect(() => {\r\n if (store.user.info.id === undefined && userData !== '' && wait > 0) {\r\n dispatch(setUserInfo(userData))\r\n localStorage.setItem('localUser', JSON.stringify(userData))\r\n sessionStorage.setItem('localUser', JSON.stringify(userData))\r\n }\r\n // eslint-disable-next-line react-hooks/exhaustive-deps\r\n }, [store.user.info, userData])\r\n\r\n useEffect(() => {\r\n if (wait === 0) {\r\n login(token)\r\n getQueryParamsToTracelog(query)\r\n setWait(1)\r\n }\r\n if (wait === 1) {\r\n fetchUser(setUserData)\r\n setWait(2)\r\n }\r\n if (wait === 2) {\r\n let path = '/envio'\r\n if (tipo === 'cotacao') path = '/cotacao'\r\n if (tipo === 'negociacao') path = '/negociacao'\r\n getAddress(\r\n (res) => dispatch(setEndereco(res)),\r\n (res) => dispatch(setPadrao(res)),\r\n () => router.push(path),\r\n () => router.push('/'),\r\n token\r\n )\r\n dispatch(setPromotor(promotor))\r\n setWait(3)\r\n }\r\n }, [wait])\r\n\r\n return (\r\n
\r\n \r\n
\r\n )\r\n}\r\nexport default Login\r\n","import React, { useMemo } from 'react'\r\nimport { useLocation } from 'react-router-dom'\r\n\r\nconst useQuery = () => {\r\n const { search } = useLocation()\r\n\r\n return useMemo(() => new URLSearchParams(search), [search])\r\n}\r\n\r\nexport { useQuery }","import { useEffect } from 'react'\r\nimport { useQueryParam, StringParam } from 'use-query-params'\r\nimport { logout } from '../../api/auth/auth'\r\nimport Loader from '../../components/Loader'\r\n\r\nconst Logout = () => {\r\n const [redirectUrl] = useQueryParam('redirectUrl', StringParam)\r\n\r\n useEffect(() => {\r\n logout()\r\n window.location.href = redirectUrl || process.env.REACT_APP_URL_MAIN\r\n // eslint-disable-next-line react-hooks/exhaustive-deps\r\n }, [])\r\n\r\n return (\r\n
\r\n \r\n
\r\n )\r\n}\r\nexport default Logout\r\n","import styled from 'styled-components'\r\n\r\nexport const Container = styled.div`\r\n max-width: 1360px;\r\n margin-left: auto;\r\n margin-right: auto;\r\n\r\n @media (max-width: 1450px) {\r\n max-width: 95%;\r\n }\r\n`\r\n","import styled, { css } from 'styled-components'\r\nimport media from 'styled-media-query'\r\n\r\nconst mediaMatchModifiers = {\r\n lessThan: (size) => css`\r\n ${media.lessThan(size)` display: block `}\r\n `,\r\n\r\n greaterThan: (size) => css`\r\n ${media.greaterThan(size)` display: block `}\r\n `\r\n}\r\n\r\nexport default styled.div`\r\n ${({ lessThan, greaterThan }) => css`\r\n display: none;\r\n ${!!lessThan && mediaMatchModifiers.lessThan(lessThan)}\r\n ${!!greaterThan && mediaMatchModifiers.greaterThan(greaterThan)}\r\n `}\r\n`\r\n","import styled, { css } from 'styled-components'\r\nimport media from 'styled-media-query'\r\n\r\nexport const Wrapper = styled.header`\r\n ${({ theme, onlyLogo }) => css`\r\n background: #fff;\r\n padding: 20px 0;\r\n position: relative;\r\n -webkit-box-shadow: 0px 1px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 1px 4px rgba(0, 0, 0, 0.1);\r\n\r\n ${onlyLogo &&\r\n css`\r\n border-bottom: 1px solid #eeeeee;\r\n `}\r\n\r\n .new-header {\r\n display: flex;\r\n align-items: center;\r\n justify-content: space-between;\r\n\r\n margin-right: 80px;\r\n }\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n //height: 150px;\r\n padding: 13px;\r\n }\r\n `}\r\n`\r\n\r\nexport const HColumsn = styled.div`\r\n display: block;\r\n font-size: 0;\r\n`\r\n\r\nexport const HColumn = styled.div`\r\n ${({ theme }) => css`\r\n display: inline-block;\r\n vertical-align: middle;\r\n\r\n &:nth-of-type(1) {\r\n width: 14%;\r\n }\r\n\r\n &:nth-of-type(2) {\r\n /* width: 46%; */\r\n }\r\n\r\n &:nth-of-type(3) {\r\n width: 40%;\r\n }\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n &:nth-of-type(1) {\r\n width: 40%;\r\n }\r\n\r\n &:nth-of-type(2) {\r\n display: none;\r\n /* width: 100%;\r\n float: left; */\r\n }\r\n\r\n &:nth-of-type(3) {\r\n width: 60%;\r\n }\r\n }\r\n `}\r\n`\r\n\r\n// export const MenuMobileIcon = styled.div`\r\n// ${({ theme }) => css`\r\n// display: flex;\r\n// align-items: center;\r\n// justify-content: center;\r\n\r\n// img {\r\n// width: 2.6rem;\r\n// height: 2.3rem;\r\n// }\r\n\r\n// &:hover {\r\n// background-color: ${theme.colors.primary};\r\n// }\r\n\r\n// ${media.greaterThan('medium')`\r\n// display: inline-block;\r\n// `}\r\n// `}\r\n// `\r\n\r\nexport const MenuMobileIcon = styled.div`\r\n ${({ theme }) => css`\r\n display: none;\r\n width: 26px;\r\n height: 23px;\r\n font-size: 0;\r\n border: 0;\r\n position: absolute;\r\n top: 19px;\r\n cursor: pointer;\r\n\r\n img {\r\n width: 2.6rem;\r\n height: 2.3rem;\r\n }\r\n\r\n &:hover {\r\n img {\r\n filter: invert(22%) sepia(78%) saturate(2710%) hue-rotate(341deg)\r\n brightness(88%) contrast(96%);\r\n }\r\n }\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n display: inline-block;\r\n }\r\n `}\r\n`\r\n\r\nexport const Logo = styled.img`\r\n width: 15rem;\r\n\r\n ${media.lessThan('large')`\r\n /* margin-left: 5rem; */\r\n `}\r\n\r\n ${media.lessThan('small')`\r\n /* margin-left: .8rem; */\r\n width: 85%;\r\n `}\r\n\r\n @media(max-width: 1170px) {\r\n max-width: 100px;\r\n }\r\n`\r\nexport const HeaderNavigation = styled.div`\r\n display: flex;\r\n align-items: center;\r\n justify-content: flex-end;\r\n font-size: 1.4rem;\r\n\r\n @media (max-width: 1170px) {\r\n .account {\r\n display: none;\r\n }\r\n }\r\n`\r\n\r\nexport const HeaderNavigationItem = styled.div`\r\n ${({ active }) =>\r\n active &&\r\n css`\r\n z-index: 200;\r\n background: #ffffff;\r\n `}\r\n\r\n display: inline-block;\r\n position: relative;\r\n padding: 15px 8px;\r\n border-radius: 4px 4px 0 0;\r\n margin-right: 60px;\r\n /* width: 256px; */\r\n\r\n &:nth-of-type(2) {\r\n margin: 0 10px;\r\n }\r\n\r\n &:first-child {\r\n padding: 15px 15px;\r\n }\r\n\r\n &:last-child {\r\n padding: 15px 12px;\r\n }\r\n\r\n @media (max-width: 1390px) {\r\n padding: 15px 5px;\r\n }\r\n\r\n @media (max-width: 1245px) {\r\n padding: 15px 0;\r\n }\r\n`\r\n\r\nexport const HeaderNavigationItemLink = styled.a`\r\n ${({ theme }) => css`\r\n display: flex;\r\n align-items: center;\r\n font-size: 14px;\r\n text-decoration: none;\r\n color: ${theme.colors.mediumGrey};\r\n /* background-color: gold; */\r\n\r\n transition: all 400ms;\r\n\r\n &:hover {\r\n color: ${theme.colors.primary};\r\n }\r\n\r\n /* img {\r\n margin-left: 0.6rem;\r\n } */\r\n\r\n ${media.lessThan('large')`\r\n font-size: 0;\r\n margin: 0 15px;\r\n `}\r\n `}\r\n`\r\n\r\nexport const NavigationItemLinksIcons = styled.div`\r\n position: relative;\r\n vertical-align: middle;\r\n display: inline-block;\r\n\r\n ${({ theme }) => css`\r\n /* img {\r\n width: 28px;\r\n height: 28px;\r\n margin-right: 6px;\r\n\r\n &.icon-cart {\r\n background-color: #8f8f8f;\r\n }\r\n }\r\n\r\n img {\r\n width: 37px;\r\n margin-right: 6px;\r\n /* border-radius: 50%;\r\n } */\r\n\r\n .profile-img {\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n width: 37px;\r\n height: 37px;\r\n border-radius: 50%;\r\n margin-right: 10px;\r\n box-shadow: 0px 0px 0px 2px #fff, 0px 0px 0px 4px #f1f2f2;\r\n\r\n background-color: #e4e4e4;\r\n\r\n img {\r\n width: 20px;\r\n }\r\n }\r\n\r\n .counter-quantity {\r\n background: ${theme.colors.primary};\r\n border-radius: 50%;\r\n width: 20px;\r\n height: 20px;\r\n font-size: 10px;\r\n position: absolute;\r\n top: -9px;\r\n right: -6px;\r\n text-align: center;\r\n color: ${theme.colors.white};\r\n font-weight: bold;\r\n line-height: 21px;\r\n }\r\n `}\r\n`\r\n\r\nexport const HeaderModalBox = styled.div`\r\n ${({ theme }) => css`\r\n background: #ffffff;\r\n border-radius: 5px;\r\n padding: 16px;\r\n position: relative;\r\n text-align: left;\r\n\r\n .header-modal-account & {\r\n width: 400px;\r\n }\r\n\r\n .header-modal-category & {\r\n min-width: 1000px;\r\n padding: 0;\r\n }\r\n\r\n .header-modal-cart & {\r\n width: 400px;\r\n border-radius: 10px 0 10px 10px;\r\n padding: 0;\r\n\r\n @media (max-width: ${theme.media.cel}) {\r\n width: 100%;\r\n }\r\n }\r\n\r\n .header-modal-local & {\r\n width: 360px;\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n width: 100%;\r\n }\r\n }\r\n\r\n .header-modal-search & {\r\n padding: 30px;\r\n }\r\n\r\n .header-modal-profile & {\r\n padding: 30px 30px 10px 30px;\r\n }\r\n\r\n p {\r\n font-size: 14px;\r\n margin: 15px 0;\r\n display: block;\r\n }\r\n `}\r\n`\r\n","import styled, { css } from 'styled-components'\r\n\r\nimport { HeaderModalBox } from '../../components/Header/styles'\r\n\r\nexport const Wrapper = styled.div`\r\n ${({ theme, visible }) => css`\r\n width: 600px;\r\n height: 500px;\r\n\r\n display: ${visible ? 'block' : 'none'};\r\n transition: all 400ms;\r\n position: absolute;\r\n left: 0;\r\n z-index: 5;\r\n\r\n &.header-modal-cart {\r\n left: initial;\r\n right: 0;\r\n }\r\n\r\n @media (max-width: 1600px) {\r\n &.header-modal-local {\r\n left: initial;\r\n right: 0;\r\n }\r\n }\r\n\r\n @media (max-width: 1360px) {\r\n &.header-modal-cart {\r\n left: initial;\r\n right: 0;\r\n min-width: 355px;\r\n }\r\n }\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n &.header-modal-local {\r\n width: 100%;\r\n }\r\n }\r\n `}\r\n`\r\n\r\nexport const SearchModalBox = styled(HeaderModalBox)`\r\n padding: 30px;\r\n`\r\n\r\nexport const SearchSuggestion = styled.div`\r\n max-height: 170px;\r\n overflow-y: auto;\r\n`\r\n\r\nexport const SearchSuggestionList = styled.ul`\r\n list-style-type: none;\r\n`\r\n\r\nexport const SearchSuggestionItem = styled.li`\r\n ${({ theme }) => css`\r\n margin-bottom: 20px;\r\n\r\n span {\r\n font-size: 15px;\r\n transition: all 400ms;\r\n &:hover {\r\n color: ${theme.colors.primary};\r\n }\r\n }\r\n `}\r\n`\r\nexport const SearchSuggestionProduct = styled.div`\r\n margin-top: 20px;\r\n`\r\n\r\nexport const SearchTitle = styled.h4`\r\n ${({ theme }) => css`\r\n font-size: 18px;\r\n font-weight: 600;\r\n color: ${theme.colors.primary};\r\n margin-bottom: 30px;\r\n position: relative;\r\n\r\n span {\r\n background: #ffffff;\r\n z-index: 99;\r\n position: relative;\r\n padding-right: 10px;\r\n }\r\n\r\n &:after {\r\n content: '';\r\n width: 100%;\r\n height: 1px;\r\n left: 0;\r\n background: #cccccc;\r\n position: absolute;\r\n top: 10px;\r\n }\r\n `}\r\n`\r\n\r\nexport const SearchSuggestionProductItem = styled.li`\r\n ${({ theme }) => css`\r\n display: block;\r\n width: 100%;\r\n margin-bottom: 15px;\r\n\r\n &:last-child {\r\n margin-bottom: 0;\r\n }\r\n\r\n // Column.\r\n .header-list-column {\r\n display: inline-block;\r\n vertical-align: middle;\r\n\r\n &:nth-of-type(1) {\r\n width: 15%;\r\n }\r\n &:nth-of-type(2) {\r\n padding: 0 15px;\r\n width: 55%;\r\n }\r\n &:nth-of-type(3) {\r\n width: 30%;\r\n }\r\n\r\n @media (max-width: 1330px) {\r\n &:nth-of-type(2) {\r\n width: 45%;\r\n }\r\n &:nth-of-type(3) {\r\n width: 40%;\r\n }\r\n }\r\n\r\n @media (max-width: ${theme.media.cel}) {\r\n &:nth-of-type(1) {\r\n width: 30%;\r\n }\r\n &:nth-of-type(2) {\r\n width: 70%;\r\n }\r\n &:nth-of-type(3) {\r\n margin-top: 10px;\r\n padding-left: calc(30% + 15px);\r\n text-align: left;\r\n width: 100%;\r\n\r\n .header-modal-search-suggestion-product-form-cart {\r\n text-align: left;\r\n }\r\n }\r\n }\r\n }\r\n `}\r\n`\r\n\r\nexport const ItemThumbnails = styled.div`\r\n img {\r\n display: block;\r\n width: 70px;\r\n height: 70px;\r\n }\r\n`\r\n\r\nexport const ItemTitle = styled.span`\r\n font-size: 14px;\r\n line-height: 18px;\r\n`\r\n\r\nexport const SuggestionOffer = styled.div`\r\n ${({ theme }) => css`\r\n font-size: 14px;\r\n margin-top: 8px;\r\n\r\n .text-old-price {\r\n text-decoration: line-through;\r\n }\r\n\r\n .text-price {\r\n color: ${theme.colors.primary};\r\n font-weight: 600;\r\n font-size: 16px;\r\n }\r\n `}\r\n`\r\n\r\nexport const ProductFormCart = styled.div`\r\n ${({ theme }) => css`\r\n text-align: center;\r\n vertical-align: top;\r\n\r\n .button-search-cart {\r\n background: ${theme.colors.cart};\r\n border-radius: 3px;\r\n border: 0;\r\n height: 32px;\r\n width: 70px;\r\n margin-left: 5px;\r\n transition: all 400ms;\r\n position: relative;\r\n\r\n svg {\r\n fill: white;\r\n background-color: transparent;\r\n position: absolute;\r\n top: 50%;\r\n left: 50%;\r\n transform: translate(-50%, -50%);\r\n width: 18px;\r\n height: 17px;\r\n filter: brightness(0) invert(1);\r\n\r\n .icon-cart {\r\n width: 20px;\r\n height: 18px;\r\n }\r\n .icon-check {\r\n width: 17px;\r\n height: 15px;\r\n }\r\n }\r\n\r\n &:hover {\r\n background: darken(${theme.colors.cart}, 10%);\r\n }\r\n }\r\n `}\r\n`\r\n\r\nexport const FormGroupQuantity = styled.div`\r\n border-radius: 3px;\r\n width: 80px;\r\n border: 1px solid #bbbbbb;\r\n display: inline-block;\r\n vertical-align: top;\r\n\r\n input {\r\n font-family: 'Montserrat', sans-serif;\r\n border: 0;\r\n width: 26px;\r\n text-align: center;\r\n display: inline-block;\r\n padding: 5px 0;\r\n\r\n &.input-quantity-control {\r\n background: none;\r\n cursor: pointer;\r\n font-size: 17px;\r\n\r\n &:hover {\r\n opacity: 0.6;\r\n }\r\n }\r\n\r\n &.input-quantity-number {\r\n &::placeholder {\r\n color: #afaeae;\r\n }\r\n }\r\n }\r\n`\r\n","/* eslint-disable import/no-anonymous-default-export */\r\nexport default {\r\n suggestion: [\r\n {\r\n thumbnail: 'tenis',\r\n name: 'Tênis infantil Hello Mop escolar preto e branco',\r\n oldPrice: 'R$67,90',\r\n price: 'R$49,90',\r\n icon: 'icon-cart'\r\n },\r\n {\r\n thumbnail: 'estojo',\r\n name: 'Estojo escolar Duplo com zíper',\r\n oldPrice: 'R$67,90',\r\n price: 'R$29,90',\r\n icon: 'icon-check'\r\n },\r\n {\r\n thumbnail: 'mochila',\r\n name: 'Mochila Juvenil escolar preta',\r\n oldPrice: 'R$89,90',\r\n price: 'R$79,90',\r\n icon: 'icon-check'\r\n }\r\n ]\r\n}\r\n","import { ReactSVG } from 'react-svg'\r\n\r\n\r\nconst Icon = ({ name='', size='', color='', transform='', customClass='' }) => {\r\n return (\r\n \r\n )\r\n}\r\n\r\nexport default Icon\r\n","import { Link } from 'react-router-dom'\r\n\r\nimport * as S from './styles'\r\n\r\nimport mock from './mock/search'\r\nimport Icon from '../../components/Icon'\r\n\r\n\r\nconst SearchModal = ({ visible }) => (\r\n \r\n \r\n \r\n \r\n {Array.from(Array(3).keys()).map((index) => (\r\n
\r\n \r\n \r\n \r\n Mochila escolar masculino (134)\r\n \r\n \r\n \r\n \r\n \r\n \r\n Mochila escolar infantil (71)\r\n \r\n \r\n \r\n \r\n \r\n \r\n Mochila escolar feminina (165)\r\n \r\n \r\n \r\n \r\n \r\n \r\n Mochila escolar (324)\r\n \r\n \r\n \r\n
\r\n ))}\r\n
\r\n
\r\n\r\n \r\n \r\n Sugestões para você\r\n \r\n\r\n
    \r\n {mock.suggestion.map(\r\n ({ name, thumbnail, oldPrice, price, icon }, index) => (\r\n \r\n \r\n tumbnail\r\n \r\n
    \r\n \r\n {name}\r\n \r\n \r\n De {oldPrice} por{' '}\r\n {price}\r\n \r\n
    \r\n\r\n
    \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
    \r\n \r\n )\r\n )}\r\n
\r\n
\r\n
\r\n
\r\n)\r\n\r\nexport default SearchModal\r\n","import styled, { css } from 'styled-components'\r\n\r\nexport const Wrapper = styled.div`\r\n ${({ theme }) => css`\r\n width: 100%;\r\n padding: 10px 10px 10px 10px;\r\n border-radius: 10px 10px 0 0;\r\n position: relative;\r\n margin: auto;\r\n\r\n &._is-active {\r\n z-index: 200;\r\n background: ${theme.colors.white};\r\n border-radius: 10px 10px 0 0;\r\n padding: 10px;\r\n }\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n border-top: 1px solid #cccccc;\r\n border-radius: 0;\r\n padding: 10px 0;\r\n }\r\n `}\r\n`\r\n\r\nexport const SearchInputWrapper = styled.div``\r\n\r\nexport const SearchInput = styled.input`\r\n background: #f2f2f2;\r\n border: 0;\r\n border-radius: 10px;\r\n font-size: 15px;\r\n padding: 16px 70px 16px 30px;\r\n width: 100%;\r\n\r\n &::placeholder {\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 400;\r\n }\r\n`\r\nexport const SearchDiv = styled.div`\r\n width: 100%;\r\n padding: 10px 10px 10px 10px;\r\n border-radius: 10px 10px 0 0;\r\n position: relative;\r\n margin: auto;\r\n border: 0;\r\n outline: 0;\r\n font-size: 100%;\r\n vertical-align: baseline;\r\n background: transparent;\r\n`\r\nexport const SearchButton = styled.button`\r\n ${({ theme }) => css`\r\n border: 0;\r\n border-radius: 0 10px 10px 0;\r\n font-size: 0;\r\n height: 49px;\r\n position: absolute;\r\n right: 10px;\r\n width: 50px;\r\n text-align: center;\r\n display: inline-block;\r\n transition: all 400ms;\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n right: 0;\r\n }\r\n\r\n img {\r\n width: 20px;\r\n height: 20px;\r\n }\r\n\r\n &.button-search {\r\n background: ${theme.colors.primary};\r\n\r\n &:hover {\r\n background: #707070;\r\n }\r\n }\r\n\r\n &.button-close {\r\n display: none;\r\n background: transparent;\r\n\r\n svg {\r\n background-color: #707070;\r\n }\r\n }\r\n `}\r\n`\r\n","import { useState } from 'react'\r\n\r\nimport SearchModal from '../../components/SearchModal'\r\nimport * as S from './styles'\r\n\r\nimport IconSearch from '../../assets/icons/icon-search.svg'\r\nimport IconClose from '../../assets/icons/icon-close.svg'\r\n\r\nconst SearchBox = () => {\r\n const [searchText, setSearchText] = useState('')\r\n\r\n const onChange = (e) => {\r\n const newValue = e.currentTarget.value\r\n setSearchText(newValue)\r\n }\r\n\r\n return (\r\n \r\n \r\n
\r\n \r\n setSearchText('')}\r\n onChange={onChange}\r\n />\r\n\r\n \r\n {/* */}\r\n \"\"\r\n \r\n\r\n \r\n {/* */}\r\n \"\"\r\n \r\n \r\n\r\n \r\n \r\n
\r\n
\r\n )\r\n}\r\n\r\nexport default SearchBox\r\n","import styled, { css } from 'styled-components'\r\n\r\nconst OverlayModifiers = {\r\n active: () => css`\r\n opacity: 1;\r\n `,\r\n close: () => css`\r\n opacity: 0;\r\n pointer-events: none;\r\n `\r\n}\r\n\r\nexport const Overlay = styled.div`\r\n ${({ theme, active }) => css`\r\n position: fixed;\r\n width: 100%;\r\n height: 100%;\r\n top: 0;\r\n left: 0;\r\n background: rgba(0, 0, 0, 0.7);\r\n z-index: 100;\r\n transition: opacity ${theme.transition.default};\r\n\r\n ${active && OverlayModifiers.active()}\r\n ${!active && OverlayModifiers.close()}\r\n `}\r\n`\r\n\r\nexport const HeaderModal = styled.div`\r\n ${({ theme, active }) => css`\r\n display: ${active ? 'block' : 'none'};\r\n transition: all 400ms;\r\n position: absolute;\r\n left: 0;\r\n\r\n z-index: 5;\r\n\r\n &.header-modal-cart {\r\n left: initial;\r\n right: 0;\r\n }\r\n\r\n @media (max-width: 1600px) {\r\n &.header-modal-local {\r\n left: initial;\r\n right: 0;\r\n }\r\n }\r\n\r\n @media (max-width: 1360px) {\r\n &.header-modal-cart {\r\n left: initial;\r\n right: 0;\r\n min-width: 355px;\r\n }\r\n }\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n &.header-modal-local {\r\n width: 100%;\r\n }\r\n }\r\n `}\r\n`\r\n\r\nexport const Wrapper = styled(HeaderModal)`\r\n width: 270px;\r\n`\r\n\r\nexport const ModalList = styled.ul``\r\n\r\nexport const ModalListItem = styled.li`\r\n ${({theme}) => css `\r\n\r\n list-style-type: none;\r\n margin-bottom: 20px;\r\n\r\n a {\r\n font-size: 15px;\r\n transition: all 400ms;\r\n\r\n &:hover {\r\n color: ${theme.colors.primary};\r\n }\r\n }\r\n\r\n &:last-child {\r\n padding-top: 20px;\r\n border-top: 1px solid #bbbbbb;\r\n font-weight: bold;\r\n }\r\n `}\r\n`\r\n","/* eslint-disable import/no-anonymous-default-export */\r\nexport default {\r\n links: [\r\n {\r\n name: 'Meu Perfil'\r\n },\r\n {\r\n name: 'Meu Gimplus'\r\n },\r\n {\r\n name: 'Meus Pedidos'\r\n },\r\n {\r\n name: 'Minhas Cotações'\r\n },\r\n {\r\n name: 'Minhas Negociações'\r\n },\r\n {\r\n name: 'Minhas Listas'\r\n },\r\n {\r\n name: '2º Via do Boleto Faturado'\r\n }\r\n ]\r\n}\r\n","/* eslint-disable jsx-a11y/anchor-is-valid */\r\nimport { Link } from 'react-router-dom'\r\nimport * as S from './styles'\r\nimport * as HeaderStyles from '../Header/styles'\r\nimport * as auth from '../../api/auth/auth'\r\nimport mock from './mock/profile'\r\n\r\nfunction ProfileModal({ active }) {\r\n const logout = () => {\r\n auth.logout()\r\n }\r\n\r\n return (\r\n \r\n \r\n \r\n {mock.links.map(({ name }) => (\r\n \r\n {name}\r\n \r\n ))}\r\n\r\n \r\n logout()}>\r\n Sair\r\n \r\n \r\n \r\n \r\n \r\n )\r\n}\r\n\r\nexport default ProfileModal\r\n","export default __webpack_public_path__ + \"static/media/icon-facebook.11695fcf.svg\";","import styled, { css } from 'styled-components'\r\nimport IconFacebook from '../../assets/img/icon-facebook.svg'\r\n\r\n\r\nexport const HeaderModal = styled.div`\r\n ${({ theme, active }) => css`\r\n display: ${active ? 'block' : 'none'};\r\n transition: all 400ms;\r\n position: absolute;\r\n left: 0;\r\n z-index: 5;\r\n\r\n &.header-modal-cart {\r\n left: initial;\r\n right: 0;\r\n }\r\n\r\n @media (max-width: 1600px) {\r\n &.header-modal-local {\r\n left: initial;\r\n right: 0;\r\n }\r\n }\r\n\r\n @media (max-width: 1360px) {\r\n &.header-modal-cart {\r\n left: initial;\r\n right: 0;\r\n min-width: 355px;\r\n }\r\n }\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n ${active = false}\r\n &.header-modal-local {\r\n width: 100%;\r\n }\r\n }\r\n `}\r\n`\r\n\r\nexport const Wrapper = styled(HeaderModal)`\r\n width: 400px;\r\n`\r\n\r\nexport const ModalClose = styled.button`\r\n background: none;\r\n border: 0;\r\n position: absolute;\r\n top: 30px;\r\n right: 40px;\r\n transition: all 400ms;\r\n cursor: pointer;\r\n\r\n img {\r\n width: 20px;\r\n height: 20px;\r\n }\r\n\r\n &:hover {\r\n opacity: 0.6;\r\n }\r\n`\r\n\r\nexport const ModalTitle = styled.h3`\r\n ${({ theme }) => css`\r\n font-size: 24px;\r\n font-weight: 500;\r\n color: ${theme.colors.primary};\r\n margin-bottom: 20px;\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n font-size: 18px;\r\n }\r\n `}\r\n`\r\nexport const AccountDescription = styled.p`\r\n font-size: 14px;\r\n margin: 15px 0;\r\n display: block;\r\n`\r\n\r\nconst ButtonLink = styled.a`\r\n ${({ theme }) => css`\r\n border-radius: 5px;\r\n border: 2px solid transparent;\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 500;\r\n font-size: 16px;\r\n padding: 15px 30px;\r\n text-align: center;\r\n transition: all 400ms;\r\n cursor: pointer;\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n &.button-block {\r\n display: block;\r\n width: 100%;\r\n }\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n font-size: 14px;\r\n }\r\n `}\r\n`\r\n\r\nexport const ButtonPrimary = styled(ButtonLink)`\r\n ${({ theme }) => css`\r\n background: ${theme.colors.primary};\r\n color: #ffffff;\r\n\r\n &:hover {\r\n background: darken(${theme.colors.primary}, 10%);\r\n }\r\n `}\r\n`\r\n\r\nexport const ButtonFacebook = styled(ButtonLink)`\r\n ${({ theme }) => css`\r\n background: #1877f2;\r\n color: #ffffff;\r\n margin-bottom: 20px;\r\n position: relative;\r\n cursor: pointer;\r\n .metro {\r\n display: none;\r\n }\r\n\r\n &:after {\r\n content: '';\r\n display: inline-block;\r\n background-image: url(${IconFacebook});\r\n background-size: cover;\r\n width: 30px;\r\n height: 30px;\r\n position: absolute;\r\n left: 15px;\r\n top: 50%;\r\n transform: translateY(-50%);\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n width: 20px;\r\n height: 20px;\r\n }\r\n }\r\n\r\n &:hover {\r\n background: darken(#1877f2, 10%);\r\n }\r\n `}\r\n`\r\n\r\nexport const ButtonOutline = styled(ButtonLink)`\r\n ${({ theme }) => css`\r\n background: transparent;\r\n border: 2px solid ${theme.colors.primary};\r\n color: ${theme.colors.primary};\r\n\r\n &:hover {\r\n border-color: #4a4a4a;\r\n color: #4a4a4a;\r\n }\r\n `}\r\n`\r\n\r\nexport const AccountOr = styled.span`\r\n width: 100%;\r\n height: 1px;\r\n background: #cccccc;\r\n display: block;\r\n margin: 30px 0;\r\n position: relative;\r\n\r\n &:after {\r\n background: #fbfbfb;\r\n padding: 0 10px;\r\n content: 'ou';\r\n font-size: 14px;\r\n text-align: center;\r\n display: block;\r\n position: absolute;\r\n left: 50%;\r\n top: 50%;\r\n transform: translate(-50%, -50%);\r\n }\r\n`\r\n","export default __webpack_public_path__ + \"static/media/icon-input-success.ba718699.svg\";","export default __webpack_public_path__ + \"static/media/icon-input-error.580ee1b3.svg\";","import styled, { css } from 'styled-components'\r\nimport IconInputSuccess from '../../assets/icons/icon-input-success.svg'\r\nimport IconInputError from '../../assets/icons/icon-input-error.svg'\r\n\r\nexport const FormGroup = styled.div`\r\n ${({ theme }) => css`\r\n margin-bottom: 0px;\r\n position: relative;\r\n\r\n label {\r\n font-size: 15px;\r\n font-weight: 600;\r\n color: #4a4a4a;\r\n display: block;\r\n letter-spacing: -1px;\r\n margin-bottom: 5px;\r\n }\r\n\r\n small {\r\n display: block;\r\n margin-bottom: 5px;\r\n }\r\n\r\n &.required {\r\n label {\r\n &:after {\r\n content: '*';\r\n color: ${theme.colors.primary};\r\n display: inline-block;\r\n margin-left: 4px;\r\n }\r\n }\r\n }\r\n\r\n .endereco-link-cep {\r\n text-decoration: underline;\r\n position: absolute;\r\n top: 0;\r\n right: 0;\r\n font-size: 12px;\r\n }\r\n `}\r\n`\r\n\r\nexport const FormGroupIcon = styled(FormGroup)`\r\n ${({ theme }) => css`\r\n position: relative;\r\n\r\n .icon {\r\n position: absolute;\r\n right: 15px;\r\n top: 17px;\r\n cursor: pointer;\r\n transition: all 400ms;\r\n\r\n &:hover {\r\n background-color: ${theme.colors.primary};\r\n }\r\n }\r\n `}\r\n`\r\n\r\nexport const FormGroupPlaceholder = css`\r\n position: relative;\r\n\r\n .form-input {\r\n padding-left: 60px;\r\n }\r\n`\r\n\r\nexport const FormInput = styled.input`\r\n ${({ theme }) => css`\r\n border: 1px solid #afaeae;\r\n border-radius: 6px;\r\n padding: 15px 15px;\r\n width: 100%;\r\n transition: all 400ms;\r\n\r\n &::placeholder {\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 400;\r\n color: #afaeae;\r\n }\r\n\r\n &:focus {\r\n border-color: ${theme.colors.primary};\r\n }\r\n\r\n // Feedbacks.\r\n &.input-success {\r\n background: ${theme.colors.backgroundSuccess}\r\n url(${IconInputSuccess}) right 10px center no-repeat !important;\r\n border-color: ${theme.colors.success};\r\n }\r\n\r\n &.input-error {\r\n background: ${theme.colors.backgroundError}\r\n url(${IconInputError}) right 10px center no-repeat !important;\r\n border-color: ${theme.colors.error};\r\n }\r\n `}\r\n`\r\n\r\nexport const FormTextPlaceholder = css`\r\n position: absolute;\r\n top: 50%;\r\n transform: translateY(-50%);\r\n left: 15px;\r\n`\r\n","\r\nconst usuarios = {\r\n login(params) {\r\n return fetch(\r\n `${process.env.REACT_APP_API_USUARIOS}api/usuarios/login`,\r\n params\r\n )\r\n },\r\n loginFacebook(response) {\r\n return fetch(\r\n `${process.env.REACT_APP_API_USUARIOS}api/usuarios/loginSocialFacebook?accessToken=${response.accessToken}`,\r\n {\r\n method: 'post',\r\n headers: { 'Content-Type': 'application/json' }\r\n }\r\n )\r\n },\r\n getMenuHorizontal() {\r\n return fetch(\r\n `${process.env.REACT_APP_API_ENDPOINT}` +\r\n 'busca-produtos/api/categoriasMenuHorizontal'\r\n )\r\n },\r\n getEsqueciSenha(token, cid) {\r\n return fetch(\r\n `${process.env.REACT_APP_API_USUARIOS}api/esqueci-minha-senha/dados-esqueci-senha?token=${token}&cid=${cid}`,\r\n {\r\n method: 'GET',\r\n headers: { 'Content-Type': 'application/json' }\r\n }\r\n )\r\n },\r\n trocarSenha(params) {\r\n return fetch(\r\n `${process.env.REACT_APP_API_USUARIOS}api/esqueci-minha-senha/trocar-senha`,\r\n params\r\n )\r\n },\r\n alterarSenha(params) {\r\n return fetch(\r\n `${process.env.REACT_APP_API_CLIENTES}clientes/senha`,\r\n params\r\n )\r\n }\r\n}\r\n\r\nexport default usuarios\r\n","import * as S from './styles'\r\nimport PopupMaster from 'react-facebook-login'\r\nimport { useHistory } from 'react-router-dom'\r\nimport usuarios from '../../api/usuarios'\r\nimport * as auth from '../../api/auth/auth'\r\n\r\nconst FacebookLogin = () => {\r\n let history = useHistory();\r\n\r\n const redirectCadastro = (body) =>\r\n history.push(`/cadastro?name=${body.Nome}&email=${body.Email}`)\r\n\r\n const salvarToken = (res) => auth.login(res.Token)\r\n\r\n const responseFacebook = async (response) => {\r\n try {\r\n const res = await usuarios.loginFacebook(response)\r\n const uint8Array = await res.body?.getReader().read()\r\n const unit8String = new TextDecoder('utf-8').decode(uint8Array?.value)\r\n const body = JSON.parse(unit8String)\r\n\r\n if (body.CompletarCadadastro) return redirectCadastro(body)\r\n return salvarToken(response)\r\n } catch (e) {\r\n \r\n }\r\n }\r\n\r\n return (\r\n {\r\n const doc = document.querySelector('.metro')\r\n doc.click()\r\n }}\r\n >\r\n Entrar com o Facebook\r\n \r\n \r\n )\r\n}\r\n\r\nexport default FacebookLogin\r\n","export const login = (value) =>\r\n value?.length === 0 ? 'Preencha o email corretamente' : undefined\r\n\r\nexport const senha = (value) => {\r\n if (value?.length || 0) return undefined\r\n\r\n if ((value?.length || 0) < 6)\r\n return 'A senha deve conter entre 6 e 8 caracteres'\r\n\r\n if ((value?.length || 0) > 8)\r\n return 'A senha deve conter entre 6 e 8 caracteres'\r\n\r\n return undefined\r\n}\r\n\r\nexport const contatoVal = (value) =>\r\n (value?.length || 0) < 8 ? 'Preencher contato' : undefined\r\n\r\nexport const razaoVal = (value) =>\r\n (value?.length || 0) < 8 ? 'Preencher razão social' : undefined\r\n\r\nexport const nomeFanVal = (value) =>\r\n (value?.length || 0) < 8 ? 'Preencher nome fantasia' : undefined\r\n\r\nfunction validarCNPJ(cnpj) {\r\n cnpj = cnpj.replace(/[^\\d]+/g, '')\r\n\r\n if (cnpj === '') return false\r\n\r\n if (cnpj.length !== 14) return false\r\n\r\n // Elimina CNPJs invalidos conhecidos\r\n if (\r\n cnpj === '00000000000000' ||\r\n cnpj === '11111111111111' ||\r\n cnpj === '22222222222222' ||\r\n cnpj === '33333333333333' ||\r\n cnpj === '44444444444444' ||\r\n cnpj === '55555555555555' ||\r\n cnpj === '66666666666666' ||\r\n cnpj === '77777777777777' ||\r\n cnpj === '88888888888888' ||\r\n cnpj === '99999999999999'\r\n )\r\n return false\r\n\r\n // Valida DVs\r\n let tamanho = cnpj.length - 2\r\n let numeros = cnpj.substring(0, tamanho)\r\n let digitos = cnpj.substring(tamanho)\r\n let soma = 0\r\n let pos = tamanho - 7\r\n for (let i = tamanho; i >= 1; i--) {\r\n soma += numeros.charAt(tamanho - i) * pos--\r\n if (pos < 2) pos = 9\r\n }\r\n let resultado = soma % 11 < 2 ? 0 : 11 - (soma % 11)\r\n // eslint-disable-next-line eqeqeq\r\n if (resultado != digitos.charAt(0)) return false\r\n\r\n tamanho = tamanho + 1\r\n numeros = cnpj.substring(0, tamanho)\r\n soma = 0\r\n pos = tamanho - 7\r\n for (let i = tamanho; i >= 1; i--) {\r\n soma += numeros.charAt(tamanho - i) * pos--\r\n if (pos < 2) pos = 9\r\n }\r\n resultado = soma % 11 < 2 ? 0 : 11 - (soma % 11)\r\n // eslint-disable-next-line eqeqeq\r\n if (resultado != digitos.charAt(1)) return false\r\n\r\n return true\r\n}\r\n\r\nexport const cnpjVal = (value) => {\r\n if ((value?.length || 0) < 18) return 'CNPJ deve ser composto de 14 dígitos'\r\n return validarCNPJ(value) ? undefined : 'CNPJ inválido'\r\n}\r\n\r\nexport const inscEstVal = (value) =>\r\n (value?.length || 0) < 10 ? 'Inscrição estadual possui 9 digitos' : undefined\r\n\r\nexport const inscMunVal = (value) =>\r\n (value?.length || 0) < 6 ? 'Preencher Inscrição Municipal' : undefined\r\n\r\nexport const openVal = (value) => {\r\n if ((value?.length || 0) < 10) return 'Data de abertura obrigatória'\r\n const dates = value?.split('/') || []\r\n if (+dates[0] < 1 || +dates[0] > 31)\r\n return 'O dia de abertura deve ser entre 01 e 31'\r\n if (+dates[1] < 1 || +dates[1] > 12)\r\n return 'O mês de abertura deve ser entre 01 e 12'\r\n if (+dates[2] < 1700) return 'Favor preencher com ano válido'\r\n return undefined\r\n}\r\n\r\nexport const comercialPhoneVal = (value) =>\r\n (value?.length || 0) < 14 ? 'Telefone Comercial incompleto' : undefined\r\n","\r\nexport const emailVal = (value) =>\r\n value?.match(/@/gi)?.length !== 1 ? 'Digite um e-mail válido' : undefined\r\n\r\nexport const emailConfVal = (email, confEmail) => {\r\n if (email?.match(/@/gi)?.length !== 1) return 'Os e-mails devem ser iguais'\r\n return email !== confEmail ? 'Os e-mails devem ser iguais' : undefined\r\n}\r\n\r\nexport const passVal = (value) =>\r\n (value?.length || 0) < 6 ? 'Senha deve ter mais de 6 digitos' : undefined\r\n\r\nexport const passConfVal = (pass, passConf) =>\r\n pass !== passConf\r\n ? 'Senha e confirmação de senha devem ser iguais'\r\n : undefined\r\n\r\nconst validarCPF = (cpf) => {\r\n cpf = cpf.replace(/[^\\d]+/g, '')\r\n if (cpf === '') return false\r\n if (\r\n cpf.length !== 11 ||\r\n cpf === '00000000000' ||\r\n cpf === '11111111111' ||\r\n cpf === '22222222222' ||\r\n cpf === '33333333333' ||\r\n cpf === '44444444444' ||\r\n cpf === '55555555555' ||\r\n cpf === '66666666666' ||\r\n cpf === '77777777777' ||\r\n cpf === '88888888888' ||\r\n cpf === '99999999999'\r\n )\r\n return false\r\n let add = 0\r\n for (let i = 0; i < 9; i++) add += parseInt(cpf.charAt(i)) * (10 - i)\r\n let rev = 11 - (add % 11)\r\n if (rev === 10 || rev === 11) rev = 0\r\n if (rev !== parseInt(cpf.charAt(9))) return false\r\n let add2 = 0\r\n for (let i = 0; i < 10; i++) add2 += parseInt(cpf.charAt(i)) * (11 - i)\r\n let rev2 = 11 - (add2 % 11)\r\n if (rev2 === 10 || rev2 === 11) rev2 = 0\r\n if (rev2 !== parseInt(cpf.charAt(10))) return false\r\n return true\r\n}\r\n\r\nexport const cpfVal = (value) => {\r\n if ((value?.length || 0) < 14) return 'CPF deve ser composto de 11 dígitos'\r\n return validarCPF(value) ? undefined : 'CPF inválido'\r\n}\r\n\r\nexport const birthVal = (value) => {\r\n if ((value?.length || 0) < 10) return 'Data de nascimento obrigatória'\r\n const dates = value?.split('/') || []\r\n if (+dates[0] < 1 || +dates[0] > 31)\r\n return 'O dia de nascimento deve ser entre 01 e 31'\r\n if (+dates[1] < 1 || +dates[1] > 12)\r\n return 'O mês de nascimento deve ser entre 01 e 12'\r\n if (+dates[2] < 1900 || +dates[2] > 2021)\r\n return 'Favor preencher com ano válido'\r\n return undefined\r\n}\r\n\r\nexport const cellVal = (value) =>\r\n (value?.length || 0) < 15 ? 'Número de celular incompleto' : undefined\r\n\r\nexport const fixPhoneVal = (value) =>\r\n (value?.length || 0) < 14 && (value?.length || 0) > 0\r\n ? 'Número de telefone incompleto'\r\n : undefined\r\n\r\nexport const nameVal = (value) =>\r\n (value?.length || 0) < 7 ? 'Preencher nome de cadatro' : undefined\r\n\r\nexport const preNameVal = (value) =>\r\n (value?.length || 0) < 1 ? 'Preencher com apelido ou nome' : undefined\r\n\r\nexport const fieldVal = (arr, val) => {\r\n let message = ''\r\n for (let i = 0; i < arr.length; i++) {\r\n if (val[i](arr[i])) message += val[i](arr[i]) + '. '\r\n }\r\n return message\r\n}\r\n\r\nexport const fieldValComp = (arr, val) => {\r\n let message = ''\r\n for (let i = 0, k = 0; i < val.length; i++, k += 2) {\r\n if (val[i](arr[k], arr[k + 1])) message += val[i](arr[k], arr[k + 1]) + '. '\r\n }\r\n return message\r\n}\r\n","import styled, { css } from 'styled-components'\n\nexport const LabelTooltip = styled.label`\n right: initial;\n margin-left: 10px;\n top: -10px;\n`\n\nexport const TooltipBox = styled.div`\n ${({ theme, right, left, top }) => css`\n display: none;\n position: absolute;\n background: #ffffff;\n border: 1px solid #afaeae;\n padding: 10px 15px;\n font-size: 13px;\n line-height: 15px;\n min-width: 250px;\n max-width: 300px;\n left: 30px;\n top: -15px;\n border-radius: 5px;\n text-align: justify;\n\n ${!!right &&\n css`\n top: 15px;\n left: -100px;\n `}\n\n ${!!left &&\n css`\n top: 15px;\n left: -200px;\n `}\n\n ${!!top &&\n css`\n top: -55px;\n left: 25px;\n `}\n\n @media (max-width: ${theme.media.cel}) {\n }\n `}\n`\n\nexport const Wrapper = styled.div`\n display: inline-block;\n position: absolute;\n right: -4px;\n top: 10px;\n z-index: 99;\n transition: all 400ms;\n\n i {\n background: 1px solid red;\n cursor: pointer;\n width: 20px;\n height: 20px;\n bottom: -10px;\n position: absolute;\n }\n\n &:hover {\n ${TooltipBox} {\n display: block;\n z-index: -9999;\n }\n }\n\n // Label Tooltip\n ${LabelTooltip} & {\n right: initial;\n margin-left: 10px;\n top: 30px;\n }\n`\n","import * as S from './styles'\n\nconst Tooltip = ({ icon, label, message, right, left, top }) => {\n const TooltipBody = () => (\n \n {!!icon && icon}\n \n {message}\n \n \n )\n\n if (label) {\n return (\n \n {label}\n \n \n )\n }\n\n return \n}\n\nexport default Tooltip\n","import styled, { css } from 'styled-components'\nimport IconInputError from '../../assets/icons/icon-input-error.svg'\nimport IconInputSuccess from '../../assets/icons/icon-input-success.svg'\n\n\nexport const InputWrapper = styled.div``\n\nexport const Input = styled.input`\n ${({ theme }) => css`\n border: 1px solid #afaeae;\n border-radius: 6px;\n padding: 15px 15px;\n width: 100%;\n transition: all 400ms;\n\n &::placeholder {\n font-family: 'Montserrat', sans-serif;\n font-weight: 400;\n color: #afaeae;\n }\n\n &:focus {\n border-color: ${theme.colors.primary};\n }\n `}\n`\n\nexport const Label = styled.label`\n cursor: pointer;\n font-size: 15px;\n font-weight: 600;\n color: #4a4a4a;\n display: block;\n letter-spacing: -1px;\n margin-bottom: 5px;\n`\n\nexport const Error = styled.p`\n ${({ theme }) => css`\n color: ${theme.colors.error};\n font-style: italic;\n margin-top: 5px;\n display: block;\n font-size: 13px;\n `}\n`\n\nconst wrapperModifiers = {\n disabled: (theme) => css`\n ${Label} {\n cursor: not-allowed;\n color: #4a4a4a;\n }\n\n ${Input} {\n cursor: not-allowed;\n background: ${theme.colors.grey};\n }\n `,\n\n error: (theme) => css`\n ${InputWrapper} {\n border-color: ${theme.colors.error};\n }\n\n ${Input} {\n background: ${theme.colors.backgroundError}\n url(${IconInputError}) right 10px center no-repeat !important;\n border-color: ${theme.colors.error};\n }\n `,\n\n success: (theme) => css`\n ${Input} {\n background: ${theme.colors.backgroundSuccess}\n url(${IconInputSuccess}) right 10px center no-repeat !important;\n border-color: ${theme.colors.success};\n }\n `,\n required: (theme) => css`\n ${Label} {\n &:after {\n content: '*';\n color: ${theme.colors.primary};\n display: inline-block;\n margin-left: 4px;\n }\n }\n `\n}\n\nexport const Wrapper = styled.div`\n ${({ theme, disabled, error, success, required }) => css`\n ${disabled && wrapperModifiers.disabled(theme)};\n ${error && wrapperModifiers.error(theme)}\n ${success && wrapperModifiers.success(theme)}\n ${required && wrapperModifiers.required(theme)}\n height:67px;\n margin-bottom: 0px;\n position: relative;\n\n small {\n display: block;\n margin-bottom: 5px;\n }\n `}\n`\n","import { useState } from 'react'\r\nimport { HiCreditCard } from 'react-icons/hi'\r\nimport Tooltip from '../Tooltip'\r\n\r\nimport * as S from './styles'\r\n\r\nconst TextField = ({\r\n reference,\r\n name,\r\n label,\r\n labelFor = '',\r\n initialValue = '',\r\n maxlength = 25,\r\n onInput,\r\n required = false,\r\n disabled = false,\r\n success = false,\r\n error,\r\n type = 'text',\r\n tooltip,\r\n tooltipText = '',\r\n pattern,\r\n image,\r\n ...props\r\n}) => {\r\n const [value, setValue] = useState(initialValue)\r\n\r\n const onChange = (e) => {\r\n const newValue = e.currentTarget.value\r\n setValue(newValue)\r\n\r\n !!onInput && onInput(newValue)\r\n }\r\n\r\n return (\r\n \r\n {!!label && {label}}\r\n \r\n \r\n \r\n {image}\r\n \r\n\r\n {tooltip && (\r\n }\r\n message={tooltipText}\r\n left\r\n />\r\n )}\r\n \r\n {!!error && {error}}\r\n \r\n )\r\n}\r\n\r\nexport default TextField\r\n","import { useState } from 'react'\r\n// import {useRouter} from 'react-router'\r\nimport { useHistory } from 'react-router-dom'\r\nimport * as S from './styles'\r\nimport * as HeaderStyles from '../Header/styles'\r\nimport * as FormStyles from '../Form/styles'\r\nimport FacebookLogin from './facebookLogin'\r\nimport { useToast } from '../../hooks/toast'\r\nimport * as auth from '../../api/auth/auth'\r\nimport usuarios from '../../api/usuarios'\r\nimport defaultOptions from '../../api/defaultoption'\r\nimport { login, senha } from '../FormPJ/fieldValidator'\r\nimport { emailVal, passVal } from '../FormPF/fieldValidator'\r\nimport TextField from '../TextField'\r\n\r\nimport IconClose from '../../assets/icons/icon-close.svg'\r\nimport { Link } from 'react-router-dom'\r\n\r\nfunction AccountModal({ active, handleLeave }) {\r\n const { addToast } = useToast()\r\n const [email, setEmail] = useState('')\r\n const [password, setPassword] = useState('')\r\n\r\n const router = useHistory()\r\n\r\n const userLogin = async (e) => {\r\n e.preventDefault()\r\n\r\n const isValidLogin = login(email.trim())\r\n const isValidPassword = senha(password.trim())\r\n\r\n if (isValidLogin !== undefined || isValidPassword !== undefined) {\r\n addToast({ type: 'error', title: 'Preencham os campos corretamente' })\r\n return\r\n }\r\n\r\n const res = await usuarios\r\n .login({\r\n method: 'POST',\r\n headers: defaultOptions.headers,\r\n body: JSON.stringify({\r\n login: email,\r\n password: password\r\n })\r\n })\r\n .then((result) => {\r\n //Here body is not ready yet, throw promise\r\n if (!result.ok) return Promise.reject(result)\r\n return result.json()\r\n })\r\n .then((result) => {\r\n //Successful request processing\r\n return result\r\n })\r\n .catch((error) => {\r\n //Here is still promise\r\n \r\n error.json().then((body) => {\r\n //Here is already the payload from API\r\n addToast({ type: 'error', title: body.errors.Messages[0] })\r\n })\r\n })\r\n\r\n //interceptor();\r\n\r\n if (res) {\r\n auth.login(res.Token)\r\n router.push('/')\r\n }\r\n }\r\n\r\n return (\r\n <>\r\n \r\n \r\n {\r\n handleLeave('profile')\r\n }}\r\n >\r\n {/* */}\r\n \"\"\r\n \r\n\r\n \r\n Acesse sua conta\r\n \r\n\r\n
\r\n \r\n \r\n setEmail(e.target.value)}\r\n />\r\n \r\n \r\n \r\n setPassword(e.target.value)}\r\n />\r\n \r\n \r\n \r\n \r\n \r\n userLogin(e)}\r\n className=\"button button-primary button-block\"\r\n >\r\n Entrar\r\n \r\n\r\n
\r\n \r\n {/* AJUSTAR ESSE LINK */}\r\n \r\n Esqueci minha senha\r\n \r\n \r\n\r\n \r\n\r\n {/* \r\n Entrar com o Facebook\r\n */}\r\n\r\n \r\n\r\n {/* */}\r\n\r\n \r\n Ainda não tenho cadastro\r\n \r\n\r\n \r\n Quero me cadastrar\r\n \r\n\r\n \r\n \r\n Ao continuar com o acesso e/ou cadastro, você está ciente e\r\n concorda com nossa{' '}\r\n \r\n {' '}\r\n política de privacidade\r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n \r\n )\r\n}\r\n\r\nexport default AccountModal\r\n","import { css } from 'styled-components'\r\n\r\nexport const Button = (theme) => css`\r\n border-radius: 5px;\r\n border: 2px solid transparent;\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 500;\r\n font-size: 16px;\r\n padding: 15px 30px;\r\n text-align: center;\r\n transition: all 400ms;\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n font-size: 14px;\r\n }\r\n`\r\n\r\nexport const ButtonPrimary = (theme) => css`\r\n background: ${theme.colors.primary};\r\n color: #ffffff;\r\n\r\n &:hover {\r\n background: darken(${theme.colors.primary}, 10%);\r\n }\r\n`\r\n\r\nexport const ButtonBlock = css`\r\n display: block;\r\n width: 100%;\r\n`\r\n\r\nexport const ButtonOutline = (theme) => css`\r\n background: transparent;\r\n border: 2px solid ${theme.colors.primary};\r\n color: ${theme.colors.primary};\r\n\r\n &:hover {\r\n border-color: #4a4a4a;\r\n color: #4a4a4a;\r\n }\r\n`\r\n\r\nexport const ButtonBack = (theme) => css`\r\n background: #ffffff;\r\n border: 2px solid ${theme.colors.primary};\r\n color: ${theme.colors.primary};\r\n\r\n &:hover {\r\n border-color: #4a4a4a;\r\n color: #4a4a4a;\r\n }\r\n`\r\n\r\nexport const ButtonIcon = css`\r\n padding: 15px 40px;\r\n vertical-align: middle;\r\n\r\n i {\r\n display: inline-block;\r\n\r\n &.icon-arrow-button-right {\r\n margin-left: 10px;\r\n }\r\n\r\n &.icon-arrow-button-left {\r\n margin-right: 10px;\r\n }\r\n }\r\n`\r\n","import styled, { css } from 'styled-components'\r\nimport * as ProfileModalStyles from '../ProfileModal/styles'\r\nimport { Button, ButtonPrimary, ButtonBlock } from '../../components/Button/styles'\r\nimport { HeaderModalBox } from '../../components/Header/styles'\r\n\r\nexport const CartModalBox = styled(HeaderModalBox)`\r\n padding: 0;\r\n`\r\n\r\nexport const HeaderModalCart = styled(ProfileModalStyles.HeaderModal)`\r\n width: 40rem;\r\n`\r\n\r\nexport const HeaderModalCartWrapper = styled.div`\r\n padding: 20px;\r\n`\r\n\r\nexport const ColumnGroup = styled.div`\r\n margin-left: -10px;\r\n margin-right: -10px;\r\n`\r\n\r\nexport const HeaderModalSubtitle = styled.h4`\r\n font-size: 16px;\r\n font-weight: 400;\r\n line-height: 22px;\r\n margin-bottom: 20px;\r\n white-space: pre-wrap;\r\n`\r\n\r\nexport const ModalCartItemQuantity = styled.span`\r\n ${({ theme }) => css`\r\n font-size: 14px;\r\n color: ${theme.colors.primary};\r\n font-weight: 500;\r\n `}\r\n`\r\n\r\nexport const ModalCartList = styled.ul``\r\n\r\nexport const ModalCartListItem = styled.li`\r\n display: block;\r\n width: 100%;\r\n border-bottom: 1px solid #eee;\r\n padding-bottom: 10px;\r\n margin-bottom: 10px;\r\n\r\n &:last-child {\r\n border-bottom: 0;\r\n margin-bottom: 0;\r\n }\r\n\r\n // Column.\r\n .header-list-column {\r\n display: inline-block;\r\n vertical-align: middle;\r\n\r\n &:nth-of-type(1) {\r\n width: 20%;\r\n }\r\n &:nth-of-type(2) {\r\n width: 40%;\r\n padding: 0 10px;\r\n }\r\n &:nth-of-type(3) {\r\n width: 10%;\r\n padding: 0 10px;\r\n text-align: center;\r\n }\r\n &:nth-of-type(4) {\r\n width: 20%;\r\n text-align: center;\r\n }\r\n }\r\n`\r\n\r\nexport const ModalCartItemThumbnails = styled.div`\r\n img {\r\n width: 70px;\r\n }\r\n`\r\n\r\nexport const ModalCartItemTitle = styled.div`\r\n font-size: 14px;\r\n line-height: 22px;\r\n`\r\n\r\nexport const ModalCartItemPrice = styled.div`\r\n font-size: 14px;\r\n font-weight: 600;\r\n`\r\n\r\nexport const HeaderModalCartFooter = styled.div`\r\n background: #f1f1f1;\r\n border-radius: 0 0 10px 10px;\r\n`\r\n\r\nexport const ModalCartFooterTotal = styled.span`\r\n font-size: 15px;\r\n font-weight: 500;\r\n display: block;\r\n margin-bottom: 15px;\r\n text-align: right;\r\n`\r\n\r\nexport const BuyLink = styled.a`\r\n ${({ theme }) => css`\r\n ${Button(theme)}\r\n ${ButtonPrimary(theme)}\r\n ${ButtonBlock}\r\n `}\r\n`\r\n","import * as S from './styles'\r\n\r\n\r\n\r\nconst CartModal = ({ active }) => (\r\n \r\n \r\n \r\n
\r\n
\r\n \r\n Meu carrinho\r\n \r\n
\r\n
\r\n \r\n 2 iten(s)\r\n \r\n
\r\n
\r\n\r\n \r\n {[1, 2].map((_, index) => (\r\n \r\n \r\n \"relogio\"/\r\n \r\n \r\n Relógio Smartwatch B57 Hero Band 3 - Preto\r\n \r\n \r\n 02\r\n \r\n \r\n R$240,99\r\n \r\n \r\n ))}\r\n \r\n
\r\n\r\n \r\n \r\n \r\n Total (valor sem frete): R$ 590,00\r\n \r\n \r\n Comprar\r\n \r\n \r\n \r\n
\r\n
\r\n)\r\n\r\nexport default CartModal\r\n","export default \"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADgAAAA4CAYAAACohjseAAAABHNCSVQICAgIfAhkiAAAHa9JREFUaEO9mgmwXfV93z9nX+5+3/6epCc9SWgBAQKMweBgiB3bxE7t1GA6nqZx3DrtTCdppk4DEyfjtkkdt67rZm0zWdx02tg4CcnEBGPAYMCSALEIgXbpbdJb737vuWc/p/P/v8R1YzvYTtI7cwfd4d17zvf8tu/v+/0r/D28fv/Pj+zXTeu9fuDNtXubk66qTNTj4YRjm5OF6QOgKGtrzc31QXdzzci663XLvFRTgz/5wft+8uLf9e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JokOQ53kDsilG77yePnVtpP7LY7D/yxHNPrH8v1/++x8T3e5EP3PoDb9k/M75vrFLYXSyYuw3T2KNpym550kJXL6qaclFRjYtJmlwMwuTUh//jbx37fq/1N33v/wD+cFcGSv6XDQAAAABJRU5ErkJggg==\"","export default __webpack_public_path__ + \"static/media/icon-arrow-right.9ec4f1b4.svg\";","\r\nimport styled, { css } from 'styled-components'\r\nimport IconArrowRight from '../../assets/img/icon-arrow-right.svg'\r\n\r\nexport const Modal = styled.nav`\r\n ${({ active }) => css`\r\n background: rgba(0, 0, 0, 0.6);\r\n position: fixed;\r\n top: 0;\r\n width: 100%;\r\n height: 100vh;\r\n display: block;\r\n left: 0;\r\n transition: all 1s;\r\n z-index: 900;\r\n cursor: auto;\r\n\r\n ${active &&\r\n css`\r\n display: block;\r\n `}\r\n `}\r\n`\r\n\r\nexport const MenuMobileContent = styled.div`\r\n width: 80%;\r\n height: 100vh;\r\n position: relative;\r\n z-index: 901;\r\n`\r\n\r\nexport const CloseModal = styled.div`\r\n background: #a71e26;\r\n padding: 10px;\r\n border: 0;\r\n position: absolute;\r\n right: -40px;\r\n cursor: pointer;\r\n\r\n img {\r\n filter: brightness(250%);\r\n width: 20px;\r\n height: 20px;\r\n }\r\n`\r\n\r\nexport const MenuMobileBox = styled.div`\r\n ${({ theme }) => css`\r\n background: ${theme.colors.white};\r\n height: 100%;\r\n cursor: auto;\r\n `}\r\n`\r\n\r\nexport const MenuMobileHeader = styled.div`\r\n ${({ theme }) => css`\r\n background: ${theme.colors.primary};\r\n color: ${theme.colors.white}\r\n border-top: 1px solid #bbbbbb;\r\n font-weight: bold;\r\n font-size: 18px;\r\n padding: 20px 20px;\r\n `}\r\n\r\n color: #fff;\r\n`\r\n\r\nexport const Account = styled.div`\r\n background: #fafafa;\r\n padding: 15px 20px;\r\n border-bottom: 1px solid #eeeeee;\r\n`\r\n\r\nexport const HeaderNavigationItemLink = styled.a`\r\n ${({ theme }) => css`\r\n display: flex;\r\n align-items: center;\r\n font-size: 14px;\r\n text-decoration: none;\r\n cursor: pointer;\r\n color: ${theme.colors.mediumGrey};\r\n\r\n transition: all 400ms;\r\n\r\n &:before {\r\n content: '';\r\n background: url(${IconArrowRight}) no-repeat;\r\n background-size: contain;\r\n width: 6px;\r\n height: 10px;\r\n position: absolute;\r\n transition: all 400ms;\r\n right: 20px;\r\n }\r\n }\r\n\r\n img {\r\n width: 28px;\r\n height: 28px;\r\n margin-right: 6px;\r\n }\r\n\r\n img.profile-img {\r\n width: 30px;\r\n margin-right: 6px;\r\n border-radius: 50%;\r\n }\r\n\r\n span {\r\n margin-left: 6px;\r\n }\r\n `}\r\n`\r\n\r\nexport const Wrapper = styled.div`\r\n padding: 30px 20px;\r\n overflow-y: scroll;\r\n max-height: 84vh;\r\n background-color: white;\r\n`\r\n\r\nexport const ProfileMenuList = styled.ul`\r\n position: relative;\r\n list-style: none;\r\n display: block;\r\n\r\n li {\r\n margin-bottom: 20px;\r\n display: block;\r\n font-size: 15px;\r\n position: relative;\r\n transition: all 400ms ease-in-out;\r\n\r\n .link-back {\r\n padding-left: 30px;\r\n margin-bottom: 30px;\r\n\r\n &:before {\r\n left: 0;\r\n top: 4px;\r\n transform: rotate(-180deg);\r\n transform-origin: center center;\r\n }\r\n }\r\n\r\n .link-back:before {\r\n content: '';\r\n background: url(${IconArrowRight}) no-repeat;\r\n background-size: contain;\r\n width: 6px;\r\n height: 10px;\r\n position: absolute;\r\n transition: all 400ms;\r\n right: 0;\r\n }\r\n}\r\n`\r\n\r\nexport const Category = styled.div``\r\n\r\nexport const CategoryMenuList = styled.ul`\r\n position: relative;\r\n list-style: none;\r\n display: block;\r\n\r\n /* &.isActive {\r\n display: block;\r\n } */\r\n`\r\nexport const CategoryMenuItem = styled.li`\r\n ${({ theme }) => css`\r\n margin-bottom: 20px;\r\n\r\n a {\r\n display: block;\r\n font-size: 15px;\r\n position: relative;\r\n transition: ${theme.transition.default};\r\n\r\n &.link-back {\r\n padding-left: 30px;\r\n margin-bottom: 30px;\r\n\r\n &:before {\r\n left: 0;\r\n top: 4px;\r\n transform: rotate(-180deg);\r\n transform-origin: center center;\r\n }\r\n }\r\n\r\n &:before {\r\n content: '';\r\n background: url(${IconArrowRight}) no-repeat;\r\n background-size: contain;\r\n width: 6px;\r\n height: 10px;\r\n position: absolute;\r\n transition: all 400ms;\r\n right: 0;\r\n }\r\n }\r\n `}\r\n\r\n display: block;\r\n\r\n &.isActive {\r\n display: none;\r\n }\r\n`\r\n\r\nexport const CategorySubmenuList = styled.ul`\r\n display: block;\r\n list-style: none;\r\n display: none;\r\n\r\n &.isActive {\r\n display: block;\r\n }\r\n`\r\n\r\nexport const CategorySubmenuItem = styled.li`\r\n ${({ theme }) => css`\r\n margin-bottom: 20px;\r\n\r\n a {\r\n display: block;\r\n font-size: 15px;\r\n position: relative;\r\n transition: ${theme.transition.default};\r\n\r\n &.link-back {\r\n padding-left: 30px;\r\n margin-bottom: 30px;\r\n\r\n &:before {\r\n left: 0;\r\n top: 4px;\r\n transform: rotate(-180deg);\r\n transform-origin: center center;\r\n }\r\n\r\n &:before {\r\n content: '';\r\n background: url(${IconArrowRight}) no-repeat;\r\n background-size: contain;\r\n width: 6px;\r\n height: 10px;\r\n position: absolute;\r\n transition: all 400ms;\r\n right: 0;\r\n }\r\n }\r\n }\r\n `}\r\n`\r\n","/* eslint-disable jsx-a11y/anchor-is-valid */\r\nimport { useRef, useState } from 'react'\r\nimport * as auth from '../../api/auth/auth'\r\nimport jwt from 'jsonwebtoken'\r\n\r\nimport IconClose from '../../assets/icons/icon-close.svg'\r\nimport IconProfile from '../../assets/icons/icon-profile.svg'\r\nimport UserImg from '../../assets/img/user.png'\r\n\r\nimport * as S from './styles'\r\nimport { Link } from 'react-router-dom'\r\n\r\nconst MenuMobile = ({ showMenu, setShowMenu, categories }) => {\r\n const modalRef = useRef()\r\n\r\n const closeMenu = (e) => {\r\n if (modalRef.current === e.target) {\r\n setShowMenu(false)\r\n }\r\n }\r\n\r\n const [isCategMenuOpen, setIsCategMenuOpen] = useState(true)\r\n const [isProfileMenuOpen, setIsProfileMenuOpen] = useState(false)\r\n const [isCategSubmenuOpen, setIsCategSubmenuOpen] = useState(false)\r\n const [arraySubCategories, setOpenSubCategories] = useState([])\r\n // eslint-disable-next-line no-unused-vars\r\n const [activeLink, setActiveClass] = useState(1)\r\n\r\n // const logged = auth.isAuthenticated()\r\n const logged = auth.isAuthenticated()\r\n const token = auth.getToken()\r\n const userLogged = jwt.decode(token)\r\n\r\n const openSubCategories = () => {\r\n if (isCategMenuOpen) {\r\n setIsCategMenuOpen(false)\r\n setIsCategSubmenuOpen(true)\r\n }\r\n }\r\n\r\n const closeSubCategories = () => {\r\n if (isCategSubmenuOpen) {\r\n setIsCategSubmenuOpen(false)\r\n setIsCategMenuOpen(true)\r\n }\r\n }\r\n\r\n const openProfileMenu = () => {\r\n setIsProfileMenuOpen(true)\r\n }\r\n\r\n const handleClick = (activeLink, arraySubCategories) => {\r\n setActiveClass(activeLink)\r\n setOpenSubCategories(arraySubCategories)\r\n }\r\n\r\n return (\r\n <>\r\n {showMenu ? (\r\n \r\n \r\n setShowMenu((prev) => !prev)}>\r\n \"\"\r\n \r\n \r\n Menu\r\n {logged ? (\r\n \r\n \r\n \r\n Olá,{' '}\r\n \r\n {userLogged.userNameWelcome}\r\n \r\n \r\n \r\n ) : (\r\n \r\n \r\n {/* */}\r\n \"\"\r\n Entre ou cadastre-se\r\n \r\n \r\n )}\r\n \r\n {logged && isProfileMenuOpen ? (\r\n \r\n
  • \r\n {\r\n setIsProfileMenuOpen(false)\r\n }}\r\n className=\"link-back\"\r\n >\r\n Voltar\r\n \r\n
  • \r\n
  • \r\n Dados de Cadastro\r\n
  • \r\n
  • \r\n Meus Pedidos\r\n
  • \r\n
  • \r\n Minhas Listas\r\n
  • \r\n
  • \r\n Meus Endereços\r\n
  • \r\n
  • \r\n Gimplus\r\n
  • \r\n
  • \r\n Negociações\r\n
  • \r\n
  • \r\n Cotações\r\n
  • \r\n
  • \r\n Vendas Promovidas\r\n
  • \r\n
  • \r\n Alterar Senha\r\n
  • \r\n
  • \r\n Sair\r\n
  • \r\n
    \r\n ) : (\r\n \r\n \r\n {categories &&\r\n categories.categorias.map(function (item, i) {\r\n return (\r\n \r\n handleClick(item.id, item.subCategorias)\r\n }\r\n >\r\n {item.nome}\r\n \r\n )\r\n })}\r\n \r\n\r\n \r\n \r\n \r\n Voltar\r\n \r\n \r\n\r\n {arraySubCategories &&\r\n arraySubCategories.map(function (itemSub, i) {\r\n return (\r\n \r\n \r\n {itemSub.nome}\r\n \r\n \r\n )\r\n })}\r\n \r\n \r\n )}\r\n
    \r\n
    \r\n
    \r\n
    \r\n ) : null}\r\n \r\n )\r\n}\r\n\r\nexport default MenuMobile\r\n","export default __webpack_public_path__ + \"static/media/icon-menu-mobile.ab2d1a3e.svg\";","export default __webpack_public_path__ + \"static/media/avatar-default.cf118178.svg\";","/* eslint-disable jsx-a11y/anchor-is-valid */\r\nimport { useEffect, useState } from 'react'\r\nimport { Link } from 'react-router-dom'\r\n\r\nimport { Container } from '../Container'\r\nimport MediaMatch from '../MediaMatch'\r\nimport SearchBox from '../SearchBox'\r\nimport ProfileModal from '../ProfileModal'\r\nimport AccountModal from '../AccountModal'\r\nimport CartModal from '../CartModal'\r\nimport { Overlay } from '../ProfileModal/styles'\r\nimport MenuMobile from '../MenuMobile'\r\nimport * as S from './styles'\r\nimport * as auth from '../../api/auth/auth'\r\n// import jwt from 'jsonwebtoken'\r\n\r\nimport Logo from '../../assets/img/logotipo-gimba.png'\r\nimport IconMenuMobile from '../../assets/icons/icon-menu-mobile.svg'\r\nimport IconArrowDown from '../../assets/icons/icon-arrow-down.svg'\r\nimport IconProfile from '../../assets/icons/icon-profile.svg'\r\nimport UserPicture from '../../assets/img/user.png'\r\nimport IconWishlist from '../../assets/icons/icon-whishlist.svg'\r\nimport IconCart from '../../assets/icons/icon-cart.svg'\r\nimport { useSelector } from 'react-redux'\r\nimport AvatarDefault from '../../assets/img/avatar-default.svg'\r\nimport { iframeLink } from '../../utils/utils'\r\n\r\nconst Header = ({ onlyLogo }) => {\r\n // const [logged, setLogged] = useState(false)\r\n // const [profileModalOpen, setProfileModalOpen] = useState(false)\r\n // const [cartModalOpen, setCartModalOpen] = useState(false)\r\n const sessionLocalUser = sessionStorage.getItem('localUser')\r\n const localUser = JSON.parse(sessionLocalUser)\r\n // console.log(JSON.parse(localUser))\r\n\r\n const [modalsOpen, setModalsOpen] = useState({\r\n cart: false,\r\n profile: false\r\n })\r\n const [props, setProps] = useState({})\r\n const [showMenu, setShowMenu] = useState(false)\r\n const store = useSelector((reduxState) => reduxState)\r\n\r\n // const token = auth.getToken()\r\n const logged = auth.isAuthenticated()\r\n // const userLogged = jwt.decode(token)\r\n\r\n useEffect(() => {\r\n // getApiData()\r\n // eslint-disable-next-line react-hooks/exhaustive-deps\r\n }, [])\r\n\r\n const handleHover = (type) => {\r\n setModalsOpen((prev) => ({\r\n ...prev,\r\n [type]: true\r\n }))\r\n }\r\n\r\n const handleLeave = (type) => {\r\n setModalsOpen((prev) => ({\r\n ...prev,\r\n [type]: false\r\n }))\r\n }\r\n\r\n const openMenu = () => {\r\n setShowMenu((prev) => !prev)\r\n }\r\n\r\n if (!onlyLogo) {\r\n return (\r\n \r\n \r\n \r\n \r\n \r\n iframeLink(process.env.REACT_APP_URL_MAIN)}\r\n >\r\n \r\n \r\n \r\n \r\n handleHover('profile')}\r\n // onMouseLeave={() => handleLeave('profile')}\r\n // active={modalsOpen.profile}\r\n className=\"header-navigation-item no-mobile js-toggle-modal-profile account\"\r\n >\r\n iframeLink(process.env.REACT_APP_URL_CLIENTE)}\r\n >\r\n \r\n \r\n
    \r\n \r\n
    \r\n
    \r\n {/*

    Olá, {userLogged.userNameWelcome}

    */}\r\n

    \r\n Olá,{' '}\r\n \r\n {localUser !== null && localUser !== undefined ? (\r\n \r\n {localUser?.cpf?.trim().length > 0\r\n ? localUser?.apelido || store.user.info.apelido\r\n : localUser?.contato || store.user.info.contato}\r\n \r\n ) : (\r\n \r\n {!!auth.isPF()\r\n ? localUser?.apelido || store.user.info.apelido\r\n : localUser?.contato || store.user.info.contato}\r\n \r\n )}\r\n \r\n

    \r\n {/* \"\" */}\r\n
    \r\n \r\n\r\n \r\n \r\n
    \r\n
    \r\n
    \r\n
    \r\n )\r\n }\r\n\r\n if (onlyLogo) {\r\n return (\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {\r\n e.preventDefault()\r\n openMenu()\r\n }}\r\n >\r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n \r\n \r\n {logged ? (\r\n handleHover('profile')}\r\n onMouseLeave={() => handleLeave('profile')}\r\n active={modalsOpen.profile}\r\n className=\"header-navigation-item no-mobile js-toggle-modal-profile account\"\r\n >\r\n \r\n \r\n \r\n \r\n {/* Olá, {userLogged.unique_name} */}\r\n {/* */}\r\n \"\"\r\n \r\n\r\n \r\n \r\n ) : (\r\n handleHover('profile')}\r\n // onMouseLeave={() => handleLeave('profile')}\r\n active={modalsOpen.profile}\r\n className=\"header-navigation-item no-mobile js-toggle-modal-account account\"\r\n >\r\n \r\n \r\n {/* */}\r\n \"\"\r\n \r\n Entre ou cadastre-se\r\n {/* */}\r\n \r\n \r\n\r\n \r\n \r\n )}\r\n\r\n \r\n \r\n \r\n 0\r\n {/* */}\r\n \"\"\r\n \r\n Minha Lista\r\n \r\n \r\n\r\n handleHover('cart')}\r\n onMouseLeave={() => handleLeave('cart')}\r\n active={modalsOpen.cart}\r\n className=\"header-navigation-item\"\r\n >\r\n \r\n \r\n {/* */}\r\n \"\"\r\n 9\r\n \r\n Carrinho\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n )\r\n }\r\n}\r\n\r\nexport default Header\r\n","export default __webpack_public_path__ + \"static/media/icon-remove.79d6073f.svg\";","import styled, { css } from 'styled-components'\r\n\r\nexport const ProfileTitle = styled.h2`\r\n font-size: 22px;\r\n margin-bottom: 20px;\r\n color: #555;\r\n`\r\n\r\nexport const Wrapper = styled.div``\r\n\r\nexport const CardWrapper = styled.div`\r\n @media (min-width: 1170px) {\r\n .col-6 {\r\n width: 50%;\r\n }\r\n }\r\n`\r\n\r\nexport const CardBox = styled.div`\r\n padding: 8px 16px;\r\n height: 100px;\r\n display: flex;\r\n align-items: center;\r\n justify-content: flex-start;\r\n position: relative;\r\n\r\n background: #ffffff;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 4px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 8px;\r\n\r\n .iconCredit {\r\n background-color: blue;\r\n display: flex;\r\n align-items: center;\r\n width: 70px;\r\n\r\n @media (max-width: 480px) {\r\n width: 28px;\r\n }\r\n }\r\n\r\n .credit-icon {\r\n background-color: red;\r\n width: 70px;\r\n }\r\n`\r\n\r\nexport const MainCard = styled.div`\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n position: relative;\r\n\r\n label {\r\n position: absolute;\r\n display: flex;\r\n align-items: center;\r\n margin-top: -17px;\r\n }\r\n`\r\n\r\nexport const CardInfo = styled.div`\r\n justify-self: left;\r\n font-size: 14px;\r\n margin-left: 16px;\r\n margin-right: 8px;\r\n width: 240px;\r\n flex: 1;\r\n\r\n p > p {\r\n color: #707070;\r\n }\r\n strong {\r\n font-weight: 600;\r\n }\r\n\r\n select.parcelas {\r\n padding: 8px 30px 8px 16px;\r\n max-width: 260px;\r\n color: #2e2e2e;\r\n }\r\n\r\n @media (max-width: 480px) {\r\n font-size: 14px;\r\n margin-left: 8px;\r\n }\r\n`\r\n\r\nexport const CardIcon = styled.a`\r\n transition: all 400ms;\r\n right: 22px;\r\n /* flex: 1; */\r\n text-align: right;\r\n\r\n & img {\r\n width: 18px;\r\n height: 21px;\r\n cursor: pointer;\r\n\r\n &:hover {\r\n filter: invert(22%) sepia(78%) saturate(2710%) hue-rotate(341deg)\r\n brightness(88%) contrast(96%);\r\n }\r\n\r\n @media (max-width: 480px) {\r\n width: 16px;\r\n }\r\n }\r\n`\r\n","import styled, { css } from 'styled-components'\r\nimport IconArrowDown from '../../assets/icons/icon-arrow-down.svg'\r\nimport IconInputError from '../../assets/icons/icon-input-error.svg'\r\nimport IconInputSuccess from '../../assets/icons/icon-input-success.svg'\r\n\r\n\r\nexport const SelectWrapper = styled.div``\r\n\r\nexport const Select = styled.select`\r\n background: url(${IconArrowDown}) no-repeat;\r\n background-position: right 10px center;\r\n border: 1px solid #afaeae;\r\n border-radius: 6px;\r\n font-family: 'Montserrat', sans-serif;\r\n padding: 15px 15px;\r\n color: #afaeae;\r\n width: 100%;\r\n transition: all 400ms;\r\n appearance: none;\r\n`\r\n\r\nexport const Option = styled.option`\r\n font-family: 'Montserrat', sans-serif;\r\n color: #000000;\r\n`\r\n\r\nexport const Label = styled.label`\r\n cursor: pointer;\r\n font-size: 15px;\r\n font-weight: 600;\r\n color: #4a4a4a;\r\n display: block;\r\n letter-spacing: -1px;\r\n margin-bottom: 5px;\r\n`\r\n\r\nexport const Error = styled.p`\r\n ${({ theme }) => css`\r\n color: ${theme.colors.error};\r\n font-style: italic;\r\n margin-top: 5px;\r\n display: block;\r\n font-size: 13px;\r\n `}\r\n`\r\n\r\nconst wrapperModifiers = {\r\n disabled: (theme) => css`\r\n ${Label} {\r\n cursor: not-allowed;\r\n color: #4a4a4a;\r\n }\r\n\r\n ${Select} {\r\n cursor: not-allowed;\r\n background: ${theme.colors.grey};\r\n }\r\n `,\r\n\r\n error: (theme) => css`\r\n ${SelectWrapper} {\r\n border-color: ${theme.colors.error};\r\n }\r\n\r\n ${Select} {\r\n background: ${theme.colors.backgroundError}\r\n url(${IconInputError}) right 10px center no-repeat !important;\r\n border-color: ${theme.colors.error};\r\n }\r\n `,\r\n\r\n success: (theme) => css`\r\n ${Select} {\r\n background: ${theme.colors.backgroundSuccess}\r\n url(${IconInputSuccess}) right 10px center no-repeat !important;\r\n border-color: ${theme.colors.success};\r\n }\r\n `,\r\n required: (theme) => css`\r\n ${Label} {\r\n &:after {\r\n content: '*';\r\n color: ${theme.colors.primary};\r\n display: inline-block;\r\n margin-left: 4px;\r\n }\r\n }\r\n `\r\n}\r\n\r\nexport const Wrapper = styled.div`\r\n ${({ theme, disabled, error, success, required, checkout }) => css`\r\n ${disabled && wrapperModifiers.disabled(theme)};\r\n ${error && wrapperModifiers.error(theme)}\r\n ${success && wrapperModifiers.success(theme)}\r\n ${required && wrapperModifiers.required(theme)}\r\n\r\n margin-bottom: 20px;\r\n position: relative;\r\n\r\n ${checkout && css`\r\n margin-bottom: 0px;\r\n `}\r\n\r\n small {\r\n display: block;\r\n margin-bottom: 5px;\r\n }\r\n `}\r\n`\r\n","import { useState } from 'react'\r\n\r\nimport * as S from './styles'\r\n\r\nconst Option = ({ value, label, hidden, disabled }) => (\r\n \r\n)\r\n\r\nconst Select = ({\r\n label,\r\n labelFor = '',\r\n initialValue = '',\r\n onInput,\r\n required = false,\r\n disabled = false,\r\n success = false,\r\n error,\r\n multiple = false,\r\n options = [],\r\n checkout,\r\n save,\r\n ...props\r\n}) => {\r\n const [value, setValue] = useState(initialValue)\r\n\r\n const onChange = (e) => {\r\n const newValue = e.currentTarget.value\r\n setValue(newValue)\r\n !!save && save(newValue)\r\n !!onInput && onInput(newValue)\r\n }\r\n\r\n return (\r\n \r\n {!!label && {label}}\r\n \r\n \r\n {options.map(({ label, value, hidden, disabled }) => (\r\n \r\n {!!error && {error}}\r\n \r\n )\r\n}\r\n\r\nexport default Select\r\n","import styled from 'styled-components'\r\n\r\nexport const CardSvgWrapper = styled.div`\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n margin-left: 4px;\r\n\r\n img {\r\n width: 45px;\r\n }\r\n`\r\n","export default __webpack_public_path__ + \"static/media/cartao-visa.bd7ccdb6.svg\";","export default __webpack_public_path__ + \"static/media/cartao-amex.0224634d.svg\";","export default __webpack_public_path__ + \"static/media/cartao-mastercard.b2211a68.svg\";","export default __webpack_public_path__ + \"static/media/cartao-diners.3323e56e.svg\";","export default __webpack_public_path__ + \"static/media/cartao-elo.ab8a1eb7.svg\";","export default __webpack_public_path__ + \"static/media/cartao-default.e99f7bb5.svg\";","export default __webpack_public_path__ + \"static/media/boleto.73f85217.svg\";","export default __webpack_public_path__ + \"static/media/icon-pix.d2fd45e4.svg\";","import * as S from './styles'\r\nimport IconVisa from '../../../assets/img/pagamento/cartao-visa.svg'\r\nimport IconAmex from '../../../assets/img/pagamento/cartao-amex.svg'\r\nimport IconMaster from '../../../assets/img/pagamento/cartao-mastercard.svg'\r\nimport IconDiners from '../../../assets/img/pagamento/cartao-diners.svg'\r\nimport IconElo from '../../../assets/img/pagamento/cartao-elo.svg'\r\nimport IconCartao from '../../../assets/img/pagamento/cartao-default.svg'\r\nimport IconBoleto from '../../../assets/img/pagamento/boleto.svg'\r\nimport IconPix from '../../../assets/img/pagamento/icon-pix.svg'\r\n\r\nconst CreditCardImage = ({ cartao }) => {\r\n return (\r\n \r\n {cartao === 'Visa' && \"\"}\r\n {cartao === 'Amex' && \"\"}\r\n {cartao === 'Mastercard' && \"\"}\r\n {cartao === 'Diners' && \"\"}\r\n {cartao === 'Elo' && \"\"}\r\n {cartao === 'boleto' && \"\"}\r\n {cartao === 'pix' && \"\"}\r\n {!cartao && \"\"}\r\n \r\n )\r\n}\r\n\r\nexport default CreditCardImage\r\n","import IconRemove from '../../../assets/icons/icon-remove.svg'\r\nimport * as S from './styles'\r\nimport Select from '../../Select'\r\nimport { useEffect, useState } from 'react'\r\nimport { useDispatch, useSelector } from 'react-redux'\r\nimport {\r\n setCondicaoIndex,\r\n setCondicaoIndexF,\r\n setPagamento\r\n} from '../../../store/ducks/pagamento'\r\nimport CreditCardImage from '../CreditCardImage'\r\nimport { showFullFlagName } from '../../../utils/utils'\r\nimport { getFormas } from '../../../pages/Pagamento/fetch'\r\nimport { isPF } from '../../../api/auth/auth'\r\n\r\nconst CreditCard = ({\r\n data,\r\n type,\r\n check,\r\n setCheck,\r\n selectedParcela,\r\n setSelectedParcela,\r\n condicoes,\r\n removeCard,\r\n faturado\r\n}) => {\r\n const dispatch = useDispatch()\r\n const store = useSelector((store) => store)\r\n const [showOptions, setShowOptions] = useState({\r\n showOptions: false\r\n })\r\n\r\n const handleShowSelected = (cardDetail) => {\r\n setShowOptions({\r\n [cardDetail]: !showOptions[cardDetail]\r\n })\r\n }\r\n\r\n const parcelasOpt = () => {\r\n if (!!!faturado) {\r\n const condParcelas = store.pagamento.condicoes?.Parcelas?.map((e, i) => ({\r\n label: e.DescricaoPagamento,\r\n value: i\r\n })) || [{ label: '', value: '' }]\r\n return condParcelas\r\n } else {\r\n const condSellers =\r\n store.pagamento.pagamentoSeller?.Formas[0]?.Condicoes?.filter(\r\n (e) => e.Descricao === data.descricao\r\n )[0].Parcelas?.map((e, i) => ({\r\n label: e.DescricaoPagamento,\r\n value: i\r\n })) || [{ label: '', value: '' }]\r\n return condSellers\r\n }\r\n }\r\n\r\n const options = () => {\r\n return type === 'modal'\r\n ? condicoes?.Parcelas?.map((e, i) => ({\r\n label: e.DescricaoPagamento,\r\n value: i\r\n })) || [{ label: '', value: '' }]\r\n : parcelasOpt()\r\n }\r\n\r\n return (\r\n <>\r\n \r\n \r\n \r\n \r\n {\r\n setCheck(data)\r\n }}\r\n />\r\n \r\n \r\n\r\n \r\n\r\n \r\n

    \r\n {showFullFlagName(data?.bandeira)} Final{' '}\r\n {data?.numero}\r\n

    \r\n {check?.id === data?.id && (\r\n {\r\n if (type === 'modal') {\r\n setSelectedParcela(res)\r\n } else {\r\n if (!!faturado) {\r\n dispatch(setCondicaoIndexF(res))\r\n } else {\r\n dispatch(setCondicaoIndex(res))\r\n }\r\n }\r\n }}\r\n options={options()}\r\n value={\r\n !!faturado\r\n ? store.pagamento.condicaoIndexF\r\n : store.pagamento.condicaoIndex\r\n }\r\n >\r\n )}\r\n
    \r\n\r\n {\r\n removeCard(data?.id)\r\n }}\r\n >\r\n \"Remover\r\n \r\n
    \r\n
    \r\n
    \r\n \r\n )\r\n}\r\n\r\nexport default CreditCard\r\n","import styled, { css } from 'styled-components'\r\n\r\nexport const ProfileTitle = styled.h2`\r\n font-size: 22px;\r\n margin-bottom: 20px;\r\n color: #555;\r\n`\r\n\r\nexport const Wrapper = styled.div``\r\n\r\nexport const CardWrapper = styled.div`\r\n @media (min-width: 1170px) {\r\n .col-6 {\r\n width: 50%;\r\n }\r\n }\r\n`\r\n\r\nexport const CardBox = styled.div`\r\n background: #ffffff;\r\n padding: 10px 16px;\r\n /* height: 84px; */\r\n border: 1px solid #e5e5e5;\r\n border-radius: 4px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 20px;\r\n display: flex;\r\n flex-direction: column;\r\n justify-items: center;\r\n align-items: center;\r\n`\r\n\r\nexport const CardName = styled.div`\r\n width: 100%;\r\n display: flex;\r\n justify-content: space-between;\r\n margin-bottom: 8px;\r\n\r\n .title{\r\n display: flex;\r\n background-color: red;\r\n }\r\n\r\n h3 {\r\n position: relative;\r\n font-weight: 500;\r\n }\r\n\r\n strong {\r\n font-weight: 600;\r\n color: green;\r\n }\r\n`\r\n\r\nexport const InputArea = styled.div`\r\n display: flex;\r\n width: 100%;\r\n justify-content: space-between;\r\n align-items: center;\r\n\r\n input {\r\n ${({ theme }) => css`\r\n width: 100%;\r\n height: 40px;\r\n border: 1px solid #afaeae;\r\n border-radius: 5px;\r\n padding: 15px 15px;\r\n margin-right: 8px;\r\n\r\n transition: all 400ms;\r\n\r\n &::placeholder {\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 400;\r\n color: #afaeae;\r\n }\r\n\r\n &:focus {\r\n border-color: ${theme.colors.primary};\r\n }\r\n `}\r\n }\r\n`\r\n\r\n\r\n\r\nexport const ButtonApply = styled.button`\r\n${({theme}) => css`\r\n padding: 0px 13px;\r\n border-radius: 5px;\r\n text-align: center;\r\n font-family: 'Montserrat', sans-serif;\r\n font-size: 14px;\r\n font-weight: 600;\r\n transition: all 400ms;\r\n height: 40px;\r\n\r\n background: transparent;\r\n border: 2px solid ${theme.colors.primary};\r\n color: ${theme.colors.primary};\r\n cursor: pointer;\r\n\r\n &:hover {\r\n border-color: #4a4a4a;\r\n color: #4a4a4a;\r\n }\r\n\r\n`}\r\n`\r\n","//Keys\r\nexport const Types = {\r\n SETRESUMO: '@setResumo',\r\n SETPRODUTOS: '@setProdutos',\r\n SETFRETE: '@setFrete',\r\n SETFRETEPICK: '@setFretePick',\r\n RESETFRETEPICK: '@resetFretePick',\r\n SETDATE: '@setDate',\r\n SETTURNO: '@setTurno',\r\n RESETENVIO: '@resetEnvio'\r\n}\r\n\r\n//Reducer\r\nconst INITIAL_STATE = {\r\n resumo: {},\r\n produtos: {},\r\n frete: {},\r\n fretePick: {}\r\n}\r\n\r\nexport default function reducer(state = INITIAL_STATE, { type, payload }) {\r\n switch (type) {\r\n case Types.SETRESUMO:\r\n return { ...state, resumo: payload }\r\n case Types.SETPRODUTOS:\r\n return { ...state, produtos: payload }\r\n case Types.SETFRETE:\r\n return { ...state, frete: payload }\r\n case Types.SETFRETEPICK:\r\n return { ...state, fretePick: { ...state.fretePick, ...payload } }\r\n case Types.RESETFRETEPICK:\r\n return { ...state, fretePick: INITIAL_STATE.fretePick }\r\n case Types.SETDATE:\r\n return {\r\n ...state,\r\n fretePick: {\r\n ...state.fretePick,\r\n Agenda: { ...state.fretePick.Agenda, date: payload }\r\n }\r\n }\r\n case Types.SETTURNO:\r\n return {\r\n ...state,\r\n fretePick: {\r\n ...state.fretePick,\r\n Agenda: { ...state.fretePick.Agenda, turno: payload }\r\n }\r\n }\r\n case Types.RESETENVIO:\r\n return INITIAL_STATE\r\n default:\r\n return state\r\n }\r\n}\r\n\r\n//Actions\r\nexport const setResumo = (payload) => {\r\n return { type: Types.SETRESUMO, payload: payload }\r\n}\r\n\r\nexport const setProdutos = (payload) => {\r\n return { type: Types.SETPRODUTOS, payload: payload }\r\n}\r\n\r\nexport const setFrete = (payload) => {\r\n return { type: Types.SETFRETE, payload: payload }\r\n}\r\n\r\nexport const setFretePick = (seller, pick) => {\r\n return { type: Types.SETFRETEPICK, payload: { [seller]: pick } }\r\n}\r\n\r\nexport const resetFretePick = () => {\r\n return { type: Types.RESETFRETEPICK }\r\n}\r\n\r\nexport const setDate = (payload) => {\r\n return { type: Types.SETDATE, payload: payload }\r\n}\r\n\r\nexport const setTurno = (payload) => {\r\n return { type: Types.SETTURNO, payload: payload }\r\n}\r\n\r\nexport const resetEnvio = () => {\r\n return { type: Types.RESETENVIO }\r\n}\r\n","import { useEffect, useState } from 'react'\r\nimport Tooltip from '../../Tooltip'\r\nimport * as S from './styles'\r\nimport {\r\n getFormasCupom,\r\n limpaCupom,\r\n getGimplus,\r\n setGimplus,\r\n getPromotorVendas,\r\n preCupom\r\n} from './fetch'\r\nimport { useDispatch, useSelector } from 'react-redux'\r\nimport {\r\n setGimplusStore,\r\n setPagamento,\r\n setPromotor,\r\n setCondicoes,\r\n setPick,\r\n setST\r\n} from '../../../store/ducks/pagamento'\r\nimport { setResumo, setFrete, setFretePick } from '../../../store/ducks/envio'\r\nimport { useToast } from '../../../hooks/toast'\r\n\r\nimport {\r\n gimplusValue,\r\n onlyNumber,\r\n tokenMask,\r\n convertDecimalCurrency\r\n} from '../../../utils/utils'\r\nimport Loader from '../../Loader'\r\n\r\nconst GimbaCard = ({ gimplus, cupom, promotor }) => {\r\n const { addToast } = useToast()\r\n const store = useSelector((store) => store)\r\n const dispatch = useDispatch()\r\n const [load, setLoad] = useState(false)\r\n const [promotorError, setPromotorError] = useState('')\r\n\r\n useEffect(() => {\r\n if (gimplus) getGimplus((res) => dispatch(setGimplusStore(res)), setLoad)\r\n // eslint-disable-next-line react-hooks/exhaustive-deps\r\n }, [])\r\n\r\n const [gimplusField, setGimplusField] = useState('')\r\n const [tokenField, setTokenField] = useState('')\r\n const [promotorField, setPromotorField] = useState('')\r\n\r\n const promotorMessage = store.pagamento.promotor?.Mensagem\r\n\r\n // console.log(store.pagamento.promotor.Mensagem)\r\n\r\n // console.log(promotorError)\r\n // if (promotorError === '') {\r\n // console.log(promotorError, 'Vazio')\r\n // } else if (promotorError === null) {\r\n // console.log(promotorError, 'Sucesso')\r\n // } else {\r\n // console.log(promotorError, 'Erro')\r\n // }\r\n\r\n const resetCupom = () => {\r\n setTokenField('')\r\n dispatch(setCondicoes({}))\r\n }\r\n\r\n const verifyPromotor = (message) => {\r\n if (message === null) {\r\n addToast({\r\n type: 'success',\r\n title: 'Promotor aplicado com sucesso'\r\n })\r\n } else {\r\n addToast({\r\n type: 'error',\r\n title: `${message}`\r\n })\r\n }\r\n }\r\n\r\n return (\r\n <>\r\n {load && }\r\n \r\n \r\n {!!gimplus && (\r\n \r\n \r\n

    \r\n Gimplus\r\n }\r\n message=\"Utilize seu saldo Gimplus\"\r\n />\r\n

    \r\n

    \r\n Disponível:{' '}\r\n \r\n {convertDecimalCurrency(\r\n (store.pagamento.gimplus.Total || 0) -\r\n (store.pagamento.gimplus.Utilizado || 0)\r\n )}\r\n \r\n

    \r\n
    \r\n\r\n \r\n \r\n setGimplusField(gimplusValue(e.target.value))\r\n }\r\n />\r\n\r\n {store.pagamento.gimplus?.Utilizado === 0 ? (\r\n {\r\n setGimplus(\r\n gimplusField,\r\n store,\r\n (res) => dispatch(setGimplusStore(res)),\r\n store.endereco.padrao.id,\r\n store.envio.fretePick,\r\n (res) => dispatch(setPagamento(res)),\r\n setLoad,\r\n (\r\n msg = 'Gimplus aplicado com sucesso',\r\n type = 'success',\r\n timer = 4000\r\n ) =>\r\n addToast({\r\n type: type,\r\n title: msg,\r\n timer: timer\r\n })\r\n )\r\n setGimplusField('')\r\n // dispatch(setCondicoes({}))\r\n }}\r\n >\r\n Aplicar\r\n \r\n ) : (\r\n {\r\n setGimplus(\r\n 0,\r\n store,\r\n (res) => dispatch(setGimplusStore(res)),\r\n store.endereco.padrao.id,\r\n store.envio.fretePick,\r\n (res) => dispatch(setPagamento(res)),\r\n setLoad,\r\n (msg = 'Gimplus removido com sucesso') =>\r\n addToast({\r\n type: 'success',\r\n title: msg\r\n })\r\n )\r\n setGimplusField('')\r\n // dispatch(setCondicoes({}))\r\n }}\r\n >\r\n Remover\r\n \r\n )}\r\n \r\n
    \r\n )}\r\n\r\n {!!cupom && (\r\n \r\n \r\n

    Cupom de Desconto

    \r\n
    \r\n \r\n setTokenField(e.target.value)}\r\n />\r\n\r\n {store.pagamento?.pagamento?.Resumo?.ValorCupom === 0 ? (\r\n {\r\n preCupom(\r\n tokenField,\r\n store,\r\n (res) => dispatch(setResumo(res)),\r\n (res) => dispatch(setFrete(res)),\r\n (res) => dispatch(setFretePick('Gimba', res)),\r\n (res) => dispatch(setPagamento(res)),\r\n setLoad,\r\n addToast\r\n )\r\n\r\n resetCupom()\r\n }}\r\n >\r\n Aplicar\r\n \r\n ) : (\r\n {\r\n limpaCupom(\r\n store,\r\n (res) => dispatch(setResumo(res)),\r\n (res) => dispatch(setFrete(res)),\r\n (res) => dispatch(setFretePick('Gimba', res)),\r\n (res) => dispatch(setPagamento(res)),\r\n setLoad,\r\n addToast\r\n )\r\n resetCupom()\r\n }}\r\n >\r\n Limpar\r\n \r\n )}\r\n \r\n
    \r\n )}\r\n\r\n {!!promotor && (\r\n \r\n <>\r\n \r\n

    \r\n Promotor\r\n }\r\n message=\"Insira aqui seu Código Promotor Gimba\"\r\n />\r\n

    \r\n\r\n
    \r\n {!!store.pagamento.promotor?.promotor?.NomeCliente &&\r\n store.pagamento.promotor?.promotor?.NomeCliente}\r\n {!!store.pagamento.promotor?.codigoPromotorGimba}\r\n
    \r\n
    \r\n \r\n \r\n setPromotorField(e.target.value.toUpperCase())\r\n }\r\n />\r\n {\r\n getPromotorVendas(\r\n promotorField,\r\n (res) => dispatch(setPromotor(res)),\r\n setLoad,\r\n (message) => verifyPromotor(message)\r\n )\r\n setPromotorField('')\r\n }}\r\n >\r\n {!!store.pagamento.promotor?.promotor?.NomeCliente\r\n ? 'Alterar'\r\n : 'Aplicar'}\r\n \r\n \r\n \r\n
    \r\n )}\r\n
    \r\n
    \r\n \r\n )\r\n}\r\n\r\nexport default GimbaCard\r\n","import styled, { css } from 'styled-components'\r\n\r\nexport const Wrapper = styled.div`\r\n padding: 0;\r\n /* background-color: tomato; */\r\n\r\n .content-section {\r\n /* background-color: blue; */\r\n }\r\n\r\n .title-tooltip {\r\n h3 {\r\n position: relative;\r\n display: inline-block;\r\n }\r\n }\r\n\r\n .tributacao {\r\n margin-top: 12px;\r\n\r\n p {\r\n margin-bottom: 16px;\r\n margin-top: 8px;\r\n font-size: 15px;\r\n padding-right: 8px;\r\n }\r\n\r\n\r\n div {\r\n &:first-child {\r\n display: flex;\r\n align-items: center;\r\n }\r\n\r\n strong {\r\n font-size: 14px;\r\n margin-right: 8px;\r\n }\r\n\r\n label {\r\n margin-left: 8px;\r\n }\r\n }\r\n }\r\n\r\n .cards {\r\n display: flex;\r\n justify-content: space-between;\r\n flex-wrap: wrap;\r\n }\r\n\r\n`\r\n\r\nexport const SectionTitle = styled.h3`\r\n font-size: 16px;\r\n font-weight: 600;\r\n margin-bottom: 6px;\r\n\r\n &.large {\r\n font-size: 18px;\r\n font-weight: 500;\r\n }\r\n\r\n`\r\n\r\nexport const CardWrapper = styled.div`\r\n ${({theme}) => css`\r\n\r\n @media (min-width: ${theme.media.desktop}) {\r\n max-width: calc(50% - 16px);\r\n /* min-width: 400px; */\r\n width: 100%;\r\n\r\n &:nth-child(odd) {\r\n\r\n max-width: 50%;\r\n margin-right: 16px;\r\n }\r\n }\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n max-width: 100%;\r\n min-width: 300px;\r\n width: 100%;\r\n\r\n &:nth-child(odd) {\r\n /* margin-right: 16px; */\r\n\r\n }\r\n }\r\n\r\n @media (max-width: 400px) {\r\n max-width: 100%;\r\n\r\n &:nth-child(odd) {\r\n max-width: 100%;\r\n margin-right: 10px;\r\n }\r\n }\r\n\r\n .col-6 {\r\n width: 100% !important;\r\n margin-left: 10px;\r\n\r\n &:first-child {\r\n }\r\n\r\n &:nth-child(2) {\r\n }\r\n }\r\n\r\n `}\r\n`\r\n\r\nexport const ObservacaoNF = styled.div`\r\n${({theme}) => css`\r\n padding-left: 0;\r\n padding-right: 0;\r\n margin: 16px 0 20px 0;\r\n\r\n textarea {\r\n width: 100%;\r\n height: 120px;\r\n border-radius: 4px;\r\n padding: 16px;\r\n background: #FFFFFF;\r\n border: 1px solid #d2d2d2;\r\n box-sizing: border-box;\r\n resize: none;\r\n font-family: 'Montserrat';\r\n font-weight: 500;\r\n transition: all 400ms;\r\n\r\n &::placeholder {\r\n font-family: 'Montserrat';\r\n font-weight: 400;\r\n font-size: 14px;\r\n color: #afaeae;\r\n }\r\n\r\n &:focus {\r\n border-color: ${theme.colors.primary};\r\n }\r\n }\r\n\r\n\r\n `}\r\n\r\n`\r\n","import styled, { css } from 'styled-components'\r\n\r\nexport const ProfileTitle = styled.h2`\r\n font-size: 22px;\r\n margin-bottom: 20px;\r\n color: #555;\r\n`\r\n\r\nexport const Wrapper = styled.div``\r\n\r\nexport const CardWrapper = styled.div`\r\n @media (min-width: 1170px) {\r\n .col-6 {\r\n width: 50%;\r\n }\r\n }\r\n`\r\n\r\nexport const CardBox = styled.div`\r\n padding: 8px 16px;\r\n height: 100px;\r\n display: flex;\r\n align-items: center;\r\n justify-content: flex-start;\r\n position: relative;\r\n\r\n background: #ffffff;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 4px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 8px;\r\n\r\n .iconCredit {\r\n /* background-color: blue; */\r\n display: flex;\r\n align-items: center;\r\n padding-left: 2px;\r\n\r\n @media (max-width: 480px) {\r\n width: 32px;\r\n }\r\n }\r\n`\r\n\r\nexport const MainCard = styled.div`\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n position: relative;\r\n\r\n label {\r\n position: absolute;\r\n display: flex;\r\n align-items: center;\r\n margin-top: -17px;\r\n }\r\n`\r\n\r\nexport const CardInfo = styled.div`\r\n justify-self: left;\r\n font-size: 14px;\r\n margin-left: 16px;\r\n margin-right: 8px;\r\n width: 240px;\r\n flex: 1;\r\n\r\n strong {\r\n font-weight: 600;\r\n }\r\n\r\n select.parcelas {\r\n padding: 8px 30px 8px 16px;\r\n margin: 4px 8px -12px 0;\r\n max-width: 280px;\r\n color: #2e2e2e;\r\n\r\n @media (max-width: 545px) {\r\n max-width: calc(100% - 20px);\r\n }\r\n }\r\n`\r\n\r\nexport const CardIcon = styled.a`\r\n transition: all 400ms;\r\n right: 22px;\r\n /* flex: 1; */\r\n text-align: right;\r\n\r\n & img {\r\n width: 18px;\r\n height: 21px;\r\n cursor: pointer;\r\n\r\n &:hover {\r\n filter: invert(22%) sepia(78%) saturate(2710%) hue-rotate(341deg)\r\n brightness(88%) contrast(96%);\r\n }\r\n\r\n @media (max-width: 480px) {\r\n width: 16px;\r\n }\r\n }\r\n`\r\n","import IconRemove from '../../../assets/icons/icon-remove.svg'\nimport { ImBarcode } from 'react-icons/im'\nimport * as S from './styles'\nimport Select from '../../Select'\nimport { useEffect, useState } from 'react'\nimport {\n setCondicaoIndex,\n setCondicaoIndexF,\n setPagamento\n} from '../../../store/ducks/pagamento'\nimport CreditCardImage from '../CreditCardImage'\nimport { useSelector, useDispatch } from 'react-redux'\nimport { isPF } from '../../../api/auth/auth'\nimport { precoMask } from '../../../utils/utils'\n\nconst BoletoCard = ({\n type,\n check,\n setCheck,\n setSelectedParcela,\n condicoes,\n faturado\n}) => {\n const dispatch = useDispatch()\n const store = useSelector((store) => store)\n const [data, setData] = useState({ id: '' })\n\n const [showOptions, setShowOptions] = useState({\n showOptions: false\n })\n\n const handleShowSelected = (cardDetail) => {\n setShowOptions({\n [cardDetail]: !showOptions[cardDetail]\n })\n }\n\n useEffect(() => {\n if (!!store.pagamento.pagamento.Formas) {\n setData(store.pagamento.pagamento.Formas[1])\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [store.pagamento.pagamento.Formas])\n\n const parcelasOpt = () => {\n if (\n !!faturado ||\n store.envio.resumo?.Carrinho.filter((e) => e.SellerId === null).length ===\n 0\n )\n return [{ label: 'Boleto à vista', value: 0 }]\n const condParcelas = store.pagamento.condicoes?.Parcelas?.map((e, i) => ({\n label: e.DescricaoPagamento,\n value: i\n })) || [{ label: '', value: '' }]\n const condFaturado = !!!isPF()\n ? store.pagamento.condicaoFaturado?.Parcelas?.map((e, i) => ({\n label: e.DescricaoPagamento,\n value: i + 1\n })) || []\n : []\n return [...condParcelas, ...condFaturado]\n }\n\n const options = () => {\n return type === 'modal'\n ? condicoes?.Parcelas?.map((e, i) => ({\n label: e.DescricaoPagamento,\n value: i\n })) || [{ label: '', value: '' }]\n : parcelasOpt()\n }\n\n // console.log('store:', store.pagamento, parcelasOpt())\n // const checked = () => {\n // if (!!faturado) {\n // return store.pagamento.pickF?.id === 'boleto'\n // } else {\n // return store.pagamento.pick?.id === 'boleto'\n // }\n // }\n\n return (\n <>\n \n \n \n \n {\n setCheck({ id: 'boleto' })\n }}\n />\n \n \n\n \n\n \n

    \n {data.Descricao} \n

    \n\n {check?.id === 'boleto' && (\n {\n if (type === 'modal') {\n setSelectedParcela(res)\n } else {\n if (faturado) {\n dispatch(setCondicaoIndexF(res))\n } else {\n dispatch(setCondicaoIndex(res))\n }\n }\n }}\n options={options()}\n value={\n !!faturado\n ? store.pagamento.condicaoIndexF\n : store.pagamento.condicaoIndex\n }\n >\n )}\n
    \n
    \n
    \n
    \n \n )\n}\n\nexport default BoletoCard\n","import styled, { css } from 'styled-components'\r\n\r\nexport const ProfileTitle = styled.h2`\r\n font-size: 22px;\r\n margin-bottom: 20px;\r\n color: #555;\r\n`\r\n\r\nexport const Wrapper = styled.div``\r\n\r\nexport const CardWrapper = styled.div`\r\n @media (min-width: 1170px) {\r\n .col-6 {\r\n width: 50%;\r\n }\r\n }\r\n`\r\n\r\nexport const CardBox = styled.div`\r\n padding: 16px;\r\n margin-bottom: 8px;\r\n height: 100px;\r\n\r\n display: flex;\r\n align-items: center;\r\n justify-content: flex-start;\r\n position: relative;\r\n cursor: pointer;\r\n\r\n border: 1px solid #e5e5e5;\r\n background: #ffffff;\r\n border-radius: 4px;\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n\r\n .iconCredit {\r\n display: flex;\r\n align-items: center;\r\n margin-left: 28px;\r\n }\r\n`\r\n\r\nexport const CardInfo = styled.div`\r\n justify-self: left;\r\n font-size: 14px;\r\n margin-left: 16px;\r\n margin-right: 8px;\r\n width: 240px;\r\n flex: 1;\r\n\r\n p > p {\r\n color: #707070;\r\n }\r\n strong {\r\n font-weight: 600;\r\n }\r\n\r\n @media (max-width: 480px) {\r\n font-size: 14px;\r\n margin-left: 8px;\r\n }\r\n`\r\n","import * as S from './styles'\r\n\r\nimport CreditCardImage from '../CreditCardImage'\r\n\r\nconst NewCard = ({ addCreditCard, type, setPaymentModal }) => {\r\n return (\r\n <>\r\n {\r\n type === 'modal' ? setPaymentModal(1) : addCreditCard()\r\n }}\r\n >\r\n \r\n \r\n
    \r\n \r\n
    \r\n\r\n \r\n

    \r\n Novo Cartão de Crédito \r\n

    \r\n
    \r\n
    \r\n
    \r\n \r\n \r\n )\r\n}\r\n\r\nexport default NewCard\r\n","import styled from 'styled-components'\r\n\r\nexport const Container = styled.div`\r\n position: relative;\r\n padding: 20px 30px 16px 20px;\r\n border-radius: 5px;\r\n display: flex;\r\n align-items:center;\r\n border-left: 6px solid #ff9017;\r\n margin-bottom: 10px;\r\n margin-top: 10px;\r\n\r\n button {\r\n position: absolute;\r\n right: 10px;\r\n top: 15px;\r\n border: 0;\r\n background: transparent;\r\n color: inherit;\r\n cursor: pointer;\r\n }\r\n svg {\r\n margin: 4px 30px 0 10px;\r\n }\r\n div {\r\n flex: 1;\r\n p {\r\n margin-top: 4px;\r\n font-size: 14px;\r\n opacity: 0.8;\r\n line-height: 20px;\r\n }\r\n }\r\n background: #fff3e7;\r\n color: #ff9017;\r\n`\r\n","import * as S from './styles'\r\nimport IconAlertSuccess from '../../assets/icons/icon-alert-alert.svg'\r\n\r\nconst ToastFaturado = () => {\r\n return (\r\n \r\n \r\n\r\n

    \r\n Atenção! Essa forma de pagamento não é permitida para\r\n produtos de parceiros. Sendo assim, selecione abaixo uma forma de\r\n pagamento específica para esses produtos.\r\n
    \r\n
    \r\n \r\n Obs: Será gerado um pedido separado com os produtos de parceiro.\r\n \r\n

    \r\n
    \r\n )\r\n}\r\n\r\nexport default ToastFaturado\r\n","import styled, { css } from 'styled-components'\r\n\r\nexport const Wrapper = styled.div`\r\n padding: 0;\r\n /* background-color: tomato; */\r\n\r\n .content-section {\r\n /* background-color: blue; */\r\n }\r\n\r\n .title-tooltip {\r\n h3 {\r\n position: relative;\r\n display: inline-block;\r\n }\r\n }\r\n\r\n .tributacao {\r\n margin-top: 12px;\r\n\r\n p {\r\n margin-bottom: 16px;\r\n margin-top: 8px;\r\n font-size: 15px;\r\n padding-right: 8px;\r\n }\r\n\r\n\r\n div {\r\n &:first-child {\r\n display: flex;\r\n align-items: center;\r\n }\r\n\r\n strong {\r\n font-size: 14px;\r\n margin-right: 8px;\r\n }\r\n\r\n label {\r\n margin-left: 8px;\r\n }\r\n }\r\n }\r\n\r\n .cards {\r\n display: flex;\r\n justify-content: space-between;\r\n flex-wrap: wrap;\r\n }\r\n\r\n`\r\n\r\nexport const SectionTitle = styled.h3`\r\n font-size: 16px;\r\n font-weight: 600;\r\n margin-bottom: 6px;\r\n\r\n &.large {\r\n font-size: 18px;\r\n font-weight: 500;\r\n }\r\n\r\n`\r\n\r\nexport const CardWrapper = styled.div`\r\n ${({theme}) => css`\r\n\r\n @media (min-width: ${theme.media.desktop}) {\r\n max-width: calc(50% - 16px);\r\n /* min-width: 400px; */\r\n width: 100%;\r\n\r\n &:nth-child(odd) {\r\n\r\n max-width: 50%;\r\n margin-right: 16px;\r\n }\r\n }\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n max-width: 100%;\r\n min-width: 300px;\r\n width: 100%;\r\n\r\n &:nth-child(odd) {\r\n /* margin-right: 16px; */\r\n\r\n }\r\n }\r\n\r\n @media (max-width: 400px) {\r\n max-width: 100%;\r\n\r\n &:nth-child(odd) {\r\n max-width: 100%;\r\n margin-right: 10px;\r\n }\r\n }\r\n\r\n .col-6 {\r\n width: 100% !important;\r\n margin-left: 10px;\r\n\r\n &:first-child {\r\n }\r\n\r\n &:nth-child(2) {\r\n }\r\n }\r\n\r\n `}\r\n`\r\n\r\nexport const ObservacaoNF = styled.div`\r\n${({theme}) => css`\r\n padding-left: 0;\r\n padding-right: 0;\r\n margin: 16px 0 20px 0;\r\n\r\n textarea {\r\n width: 100%;\r\n height: 120px;\r\n border-radius: 4px;\r\n padding: 16px;\r\n background: #FFFFFF;\r\n border: 1px solid #d2d2d2;\r\n box-sizing: border-box;\r\n resize: none;\r\n font-family: 'Montserrat';\r\n font-weight: 500;\r\n transition: all 400ms;\r\n\r\n &::placeholder {\r\n font-family: 'Montserrat';\r\n font-weight: 400;\r\n font-size: 14px;\r\n color: #afaeae;\r\n }\r\n\r\n &:focus {\r\n border-color: ${theme.colors.primary};\r\n }\r\n }\r\n\r\n\r\n `}\r\n\r\n`\r\n","import carrinho from '../../api/carrinho'\r\nimport pagamento from '../../api/pagamento'\r\n\r\nexport const getResumoGimba = async (\r\n addressId,\r\n save,\r\n load,\r\n wg = () => undefined,\r\n error = () => undefined\r\n) => {\r\n load(true)\r\n try {\r\n let res = await carrinho.getResumo(addressId)\r\n if (!res.ok) error()\r\n res = await res.json()\r\n await save(res)\r\n wg()\r\n } catch (e) {\r\n error()\r\n }\r\n load(false)\r\n}\r\n\r\nexport const getFreteGimba = async (\r\n id,\r\n resumo,\r\n save,\r\n load,\r\n wg = () => undefined,\r\n error = () => undefined\r\n) => {\r\n load(true)\r\n\r\n // console.log('carrinho Reduzido: ', carrinhoReduzido)\r\n let body = {\r\n IdEndereco: id,\r\n ProdutosConcatenados: resumo.FreteCondicoes?.ProdutosConcatenados,\r\n tipoPedido: 'C'\r\n }\r\n let res = await carrinho.getFrete(body)\r\n if (!res.ok) error()\r\n res = await res.json()\r\n await save(res)\r\n wg()\r\n load(false)\r\n}\r\n\r\nexport const getFormasCotacao = async (\r\n idEndereço,\r\n fretePick,\r\n save,\r\n load = () => undefined,\r\n wg = () => undefined,\r\n error = () => undefined,\r\n store,\r\n activation = undefined,\r\n consumo = undefined\r\n) => {\r\n load(true)\r\n const periodo = (str) => {\r\n if (str === 'm') return 0\r\n if (str === 't') return 1\r\n if (str === 'n') return 2\r\n }\r\n\r\n const agendamento = (fretePick) => ({\r\n Selecionada: fretePick.Agenda?.id === 'agenda',\r\n Data: fretePick.Agenda?.id === 'agenda.teste' ? fretePick.Agenda?.date : '',\r\n Perido:\r\n fretePick.Agenda?.id === 'agenda' ? periodo(fretePick.Agenda?.turno) : 0\r\n })\r\n\r\n const body = {\r\n Frete: {\r\n FreteGimba: {\r\n IdTransportadora: fretePick?.Gimba?.id,\r\n Valor: fretePick.Gimba?.value,\r\n DiasParaEntrega: fretePick.Gimba?.time,\r\n Retira: false,\r\n FOB: false,\r\n Agendamento: {\r\n Selecionada: false,\r\n Data: '',\r\n Periodo: 0\r\n }\r\n }\r\n },\r\n SituacaoTributariaConsumo: consumo !== undefined ? consumo : true,\r\n SituacaoTributariaIcms:\r\n activation !== undefined\r\n ? activation\r\n : store.pagamento.st.icms !== undefined\r\n ? store.pagamento.st.icms\r\n : store.envio.resumo.SituacaoTributariaExibir,\r\n SituacaoTributariaSelecionada:\r\n activation !== undefined\r\n ? activation\r\n : store.pagamento.st.icms !== undefined,\r\n IdEnderecoSelecionado: idEndereço,\r\n DescricaoFormaPagamento: ''\r\n }\r\n\r\n let res = await pagamento.getFormasGimba(body)\r\n if (!res.ok) error()\r\n res = await res.json()\r\n await save(res)\r\n wg()\r\n load(false)\r\n}\r\n\r\nexport const postCotacao = async (\r\n store,\r\n save,\r\n load = () => undefined,\r\n modal = () => undefined,\r\n error = () => undefined\r\n) => {\r\n const dataAgendada = (type = 0) => {\r\n const fill = (n) => (String(n).length < 2 ? '0' + n : n)\r\n let data = ''\r\n let day, month, year\r\n if (!!store.envio.fretePick?.Agenda?.date) {\r\n data = new Date(store.envio.fretePick?.Agenda?.date)\r\n day = fill(data.getDate())\r\n month = fill(+data.getMonth() + 1)\r\n year = fill(data.getFullYear())\r\n } else {\r\n return null\r\n }\r\n if (type === 0) return `${day}/${month}/${year}`\r\n return `${year}-${month}-${day}T03:00:00.000Z`\r\n }\r\n\r\n load(true)\r\n const { condicoes, condicaoIndex, pick, st } = store.pagamento\r\n const condCartao = store.pagamento.pagamento.Formas[0]?.Condicoes.filter(\r\n (e) => e.Descricao === store.pagamento.condicoes\r\n )[0]\r\n\r\n // const condicoes = pick?.id === 'cartao' ? condCartao : condBoleto\r\n\r\n const { padrao } = store.endereco\r\n const { fretePick } = store.envio\r\n const freteGimba = store.envio.frete.Gimba.OpcoesFrete[0]\r\n\r\n const body = {\r\n CodigoPromotor: store.pagamento.promotor?.codigoPromotorGimba || '',\r\n TipoPedido: 'C',\r\n Cartao: {\r\n NomeTitular: '',\r\n NumeroCartao: '',\r\n CodigoSeguranca: '',\r\n ValidadeMes: '01',\r\n ValidadeAno: '2022',\r\n Token: '',\r\n Salvar: false\r\n },\r\n Pagamento: {\r\n Id: store.pagamento.condicoes.IdTipo,\r\n Descricao: store.pagamento.condicoes.Descricao,\r\n Status: true,\r\n Condicoes: [\r\n {\r\n Id: condicoes.Id,\r\n Descricao: condicoes.Descricao,\r\n UriImagem: condicoes.UriImagem,\r\n TipoPessoa: condicoes.TipoPessoa,\r\n CodigoERP: condicoes.CodigoERP,\r\n IdEmpresa: condicoes.IdEmpresa,\r\n Status: condicoes.Status,\r\n IdTipo: condicoes.IdTipo,\r\n Parcelas:\r\n pick.id === 'boleto' && condicaoIndex > 0\r\n ? [condicoes.Parcelas[condicaoIndex - 1]]\r\n : [condicoes.Parcelas[condicaoIndex]]\r\n }\r\n ]\r\n },\r\n Endereco: {\r\n Id: padrao.id,\r\n TipoEndereco: padrao.tipoEndereco,\r\n TipoLogradouro: padrao.tipoLogradouro || '',\r\n Endereco: padrao.logradouro,\r\n ApelidoEndereco: padrao.apelido,\r\n PontoReferencia: padrao.pontoReferencia,\r\n Numero: padrao.numero,\r\n Complemento: padrao.complemento,\r\n Bairro: padrao.bairro,\r\n Cidade: padrao.cidade,\r\n UF: padrao.uf,\r\n Cep: padrao.cep\r\n },\r\n FreteGimba: {\r\n Id: fretePick.Gimba?.id,\r\n RazaoSocial: fretePick.Gimba?.name,\r\n DiasParaEntrega: fretePick.Gimba?.time,\r\n ValorFrete: fretePick.Gimba?.value,\r\n ValorFreteAgendado: freteGimba?.ValorFreteAgendado,\r\n ValorFreteEmpresa: freteGimba?.ValorFreteEmpresa,\r\n ValorTda: freteGimba?.ValorTda,\r\n ValorTde: freteGimba?.ValorTde,\r\n ValorAdmFrete: freteGimba?.ValorAdmFrete,\r\n ValorFreteAteRedespacho: freteGimba?.ValorFreteAteRedespacho,\r\n ValorPercentualIcms: freteGimba?.ValorPercentualIcms,\r\n ValorTranslado: freteGimba?.ValorTranslado,\r\n CNPJTransportadoraRedespacho: freteGimba?.CNPJTransportadoraRedespacho,\r\n CNPJTranslado: freteGimba?.CNPJTranslado,\r\n Retira: freteGimba?.Retira,\r\n FOB: freteGimba?.FOB,\r\n DataAgendamento: freteGimba?.DataAgendamento,\r\n PeriodoAgendamento: freteGimba?.PeriodoAgendamento,\r\n ValorEmex: freteGimba?.ValorEmex\r\n },\r\n DemaisInformacoes: {\r\n IdPedido: 0,\r\n ObservacaoNF: st.observacao || '',\r\n ObservacaoNegociacao: '',\r\n SituacaoTributaria: st.icms !== undefined,\r\n SituacaoTributariaIcms: st.icms,\r\n SituacaoTributariaConsumo: st.destinoFiscal === 'revenda' ? false : true,\r\n SituacaoTributariaSelecionar: st.icms === true,\r\n PeriodoEntregaAgendada:\r\n fretePick.Agenda?.turno === 'n'\r\n ? 3\r\n : fretePick.Agenda?.turno === 't'\r\n ? 2\r\n : fretePick.Agenda?.turno === 'm'\r\n ? 1\r\n : '',\r\n DataEntregaAgendada: dataAgendada(1),\r\n DataAgendada: dataAgendada(),\r\n EntregaAgendada: store.envio.fretePick.Agenda?.id === 'agenda',\r\n ObservacaoCliente: st.observacaoCliente || ''\r\n }\r\n }\r\n try {\r\n // console.log(body)\r\n\r\n let cotacaoStatus = await carrinho.postCotacao(body)\r\n if (!cotacaoStatus.ok) {\r\n error()\r\n }\r\n let cotacao = await cotacaoStatus.json()\r\n await save(cotacao)\r\n if (cotacaoStatus.ok) {\r\n modal()\r\n }\r\n load(false)\r\n } catch (e) {\r\n load(false)\r\n }\r\n}\r\n","import carrinho from '../../api/carrinho'\r\nimport pagamento from '../../api/pagamento'\r\n\r\nexport const getResumoGimba = async (\r\n addressId,\r\n save,\r\n load,\r\n wg = () => undefined,\r\n error = () => undefined\r\n) => {\r\n load(true)\r\n let res = await carrinho.getResumo(addressId)\r\n if (!res.ok) error()\r\n res = await res.json()\r\n await save(res)\r\n wg()\r\n load(false)\r\n}\r\n\r\nexport const getFreteGimba = async (\r\n id,\r\n resumo,\r\n save,\r\n load,\r\n wg = () => undefined,\r\n error = () => undefined,\r\n store\r\n) => {\r\n load(true)\r\n // let carrinhoReduzido = resumo.Carrinho?.filter(\r\n // (e) => e.SellerId === null\r\n // ).reduce(\r\n // (acc, e) => ({\r\n // FreteFull: Boolean(acc.Fretefull * e.FreteFull),\r\n // PesoEspecialProdutos: acc.PesoEspecial + e.PesoEspecial || 0,\r\n // PesoProdutos: (acc.Peso || 0) + (e.Peso || 0),\r\n // PrazoEntregaEspecial:\r\n // (acc.PrazoEntregaEspecial || 0) + (e.PrazoEntregaEspecial || 0),\r\n // ProdutosConcatenados:\r\n // (acc.ProdutosConcatenados || ``) + `|${e.Id};${e.Quantidade}`,\r\n // QuantidadeDiasManuseio:\r\n // (acc.QuantidadeDiasManuseio || 0) + (e.QuantidadeDiasManuseio || 0),\r\n // TransporteEspecial: Boolean(\r\n // acc.TransporteEspecial + e.TransporteEspecial\r\n // ),\r\n // ValorProdutos: (acc.PrecoVenda || 0) + (e.PrecoVenda || 0)\r\n // }),\r\n // {}\r\n // )\r\n let body = {\r\n IdEndereco: id,\r\n ProdutosConcatenados: resumo.FreteCondicoes?.ProdutosConcatenados,\r\n tipoPedido: 'N'\r\n }\r\n let res = await carrinho.getFrete(body)\r\n if (!res.ok) error()\r\n res = await res.json()\r\n await save(res)\r\n wg()\r\n load(false)\r\n}\r\n\r\nexport const getFormasNegociacao = async (\r\n idEndereço,\r\n fretePick,\r\n save,\r\n load = () => undefined,\r\n wg = () => undefined,\r\n error = () => undefined,\r\n store,\r\n activation = undefined,\r\n consumo = undefined\r\n) => {\r\n load(true)\r\n\r\n const periodo = (str) => {\r\n if (str === 'm') return 0\r\n if (str === 't') return 1\r\n if (str === 'n') return 2\r\n }\r\n\r\n const agendamento = (fretePick) => ({\r\n Selecionada: fretePick.Agenda?.id === 'agenda',\r\n Data: fretePick.Agenda?.id === 'agenda.teste' ? fretePick.Agenda?.date : '',\r\n Perido:\r\n fretePick.Agenda?.id === 'agenda' ? periodo(fretePick.Agenda?.turno) : 0\r\n })\r\n\r\n const body = {\r\n Frete: {\r\n FreteGimba: {\r\n IdTransportadora: fretePick?.Gimba?.id,\r\n Valor: fretePick.Gimba?.value,\r\n DiasParaEntrega: fretePick.Gimba?.time,\r\n Retira: false,\r\n FOB: false,\r\n Agendamento: {\r\n Selecionada: false,\r\n Data: '',\r\n Periodo: 0\r\n }\r\n }\r\n },\r\n SituacaoTributariaConsumo: consumo !== undefined ? consumo : true,\r\n SituacaoTributariaIcms:\r\n activation !== undefined\r\n ? activation\r\n : store.pagamento.st.icms !== undefined\r\n ? store.pagamento.st.icms\r\n : store.envio.resumo.SituacaoTributariaExibir,\r\n SituacaoTributariaSelecionada:\r\n activation !== undefined\r\n ? activation\r\n : store.pagamento.st.icms !== undefined,\r\n IdEnderecoSelecionado: idEndereço,\r\n DescricaoFormaPagamento: ''\r\n }\r\n\r\n let res = await pagamento.getFormasGimba(body)\r\n if (!res.ok) error()\r\n res = await res.json()\r\n await save(res)\r\n wg()\r\n load(false)\r\n}\r\n\r\nexport const postNegociacao = async (\r\n store,\r\n save,\r\n load = () => undefined,\r\n modal = () => undefined,\r\n error = () => undefined\r\n) => {\r\n const dataAgendada = (type = 0) => {\r\n const fill = (n) => (String(n).length < 2 ? '0' + n : n)\r\n let data = ''\r\n let day, month, year\r\n if (!!store.envio.fretePick?.Agenda?.date) {\r\n data = new Date(store.envio.fretePick?.Agenda?.date)\r\n day = fill(data.getDate())\r\n month = fill(+data.getMonth() + 1)\r\n year = fill(data.getFullYear())\r\n } else {\r\n return null\r\n }\r\n if (type === 0) return `${day}/${month}/${year}`\r\n return `${year}-${month}-${day}T03:00:00.000Z`\r\n }\r\n\r\n load(true)\r\n const { condicoes, condicaoIndex, pick, st } = store.pagamento\r\n const condCartao = store.pagamento.pagamento.Formas[0]?.Condicoes?.filter(\r\n (e) => e.Descricao === store.pagamento.condicoes\r\n )[0]\r\n\r\n let condBoleto =\r\n condicaoIndex === 0\r\n ? store.pagamento.pagamento.Formas[1]?.Condicoes[0]\r\n : store.pagamento.pagamento.Formas[1]?.Condicoes[1]\r\n\r\n // const condicoes = pick?.id === 'cartao' ? condCartao : condBoleto\r\n const { padrao } = store.endereco\r\n const { fretePick } = store.envio\r\n const freteGimba = store.envio.frete.Gimba.OpcoesFrete[0]\r\n\r\n const body = {\r\n CodigoPromotor: store.pagamento.promotor?.codigoPromotorGimba || '',\r\n TipoPedido: 'N',\r\n Cartao: {\r\n NomeTitular: '',\r\n NumeroCartao: '',\r\n CodigoSeguranca: '',\r\n ValidadeMes: '01',\r\n ValidadeAno: '2022',\r\n Token: '',\r\n Salvar: false\r\n },\r\n Pagamento: {\r\n Id: store.pagamento.condicoes.IdTipo,\r\n Descricao: store.pagamento.condicoes.Descricao,\r\n Status: true,\r\n Condicoes: [\r\n {\r\n Id: condicoes.Id,\r\n Descricao: condicoes.Descricao,\r\n UriImagem: condicoes.UriImagem,\r\n TipoPessoa: condicoes.TipoPessoa,\r\n CodigoERP: condicoes.CodigoERP,\r\n IdEmpresa: condicoes.IdEmpresa,\r\n Status: condicoes.Status,\r\n IdTipo: condicoes.IdTipo,\r\n Parcelas:\r\n pick.id === 'boleto' && condicaoIndex > 0\r\n ? [condicoes.Parcelas[condicaoIndex - 1]]\r\n : [condicoes.Parcelas[condicaoIndex]]\r\n }\r\n ]\r\n },\r\n Endereco: {\r\n Id: padrao.id,\r\n TipoEndereco: padrao.tipoEndereco,\r\n TipoLogradouro: padrao.tipoLogradouro || '',\r\n Endereco: padrao.logradouro,\r\n ApelidoEndereco: padrao.apelido,\r\n PontoReferencia: padrao.pontoReferencia,\r\n Numero: padrao.numero,\r\n Complemento: padrao.complemento,\r\n Bairro: padrao.bairro,\r\n Cidade: padrao.cidade,\r\n UF: padrao.uf,\r\n Cep: padrao.cep\r\n },\r\n FreteGimba: {\r\n Id: fretePick.Gimba?.id,\r\n RazaoSocial: fretePick.Gimba?.name,\r\n DiasParaEntrega: fretePick.Gimba?.time,\r\n ValorFrete: fretePick.Gimba?.value,\r\n ValorFreteAgendado: freteGimba?.ValorFreteAgendado,\r\n ValorFreteEmpresa: freteGimba?.ValorFreteEmpresa,\r\n ValorTda: freteGimba?.ValorTda,\r\n ValorTde: freteGimba?.ValorTde,\r\n ValorAdmFrete: freteGimba?.ValorAdmFrete,\r\n ValorFreteAteRedespacho: freteGimba?.ValorFreteAteRedespacho,\r\n ValorPercentualIcms: freteGimba?.ValorPercentualIcms,\r\n ValorTranslado: freteGimba?.ValorTranslado,\r\n CNPJTransportadoraRedespacho: freteGimba?.CNPJTransportadoraRedespacho,\r\n CNPJTranslado: freteGimba?.CNPJTranslado,\r\n Retira: freteGimba?.Retira,\r\n FOB: freteGimba?.FOB,\r\n DataAgendamento: freteGimba?.DataAgendamento,\r\n PeriodoAgendamento: freteGimba?.PeriodoAgendamento,\r\n ValorEmex: freteGimba?.ValorEmex\r\n },\r\n DemaisInformacoes: {\r\n IdPedido: 0,\r\n ObservacaoNF: st.observacao,\r\n ObservacaoNegociacao: '',\r\n SituacaoTributaria: st.icms !== undefined,\r\n SituacaoTributariaIcms: st.icms,\r\n SituacaoTributariaConsumo: st.destinoFiscal === 'revenda' ? false : true,\r\n SituacaoTributariaSelecionar: st.icms === true,\r\n PeriodoEntregaAgendada:\r\n fretePick.Agenda?.turno === 'n'\r\n ? 3\r\n : fretePick.Agenda?.turno === 't'\r\n ? 2\r\n : fretePick.Agenda?.turno === 'm'\r\n ? 1\r\n : '',\r\n DataEntregaAgendada: dataAgendada(1),\r\n DataAgendada: dataAgendada(),\r\n EntregaAgendada: store.envio.fretePick.Agenda?.id === 'agenda',\r\n ObservacaoCliente: st.observacaoCliente\r\n }\r\n }\r\n try {\r\n // console.log(body)\r\n let cotacaoStatus = await carrinho.postCotacao(body)\r\n if (!cotacaoStatus.ok) error()\r\n let cotacao = await cotacaoStatus.json()\r\n await save(cotacao)\r\n console.log('negociacao post')\r\n if (cotacaoStatus.ok) {\r\n modal()\r\n }\r\n load(false)\r\n } catch (e) {\r\n load(false)\r\n }\r\n}\r\n","/* eslint-disable react-hooks/exhaustive-deps */\nimport { useEffect, useState } from 'react'\nimport * as S from './styles'\nimport { FormGroup } from '../../components/Form/styles'\nimport Tooltip from '../Tooltip'\nimport Loader from '../Loader'\nimport { useSelector, useDispatch } from 'react-redux'\nimport { isPF } from '../../api/auth/auth'\nimport { setST } from '../../store/ducks/pagamento'\nimport { getFormas } from '../../pages/Pagamento/fetch'\nimport { setPagamento } from '../../store/ducks/pagamento'\nimport {\n checkEstadoST,\n checkGovernoPj,\n checkRevendaPj\n} from '../../utils/validatePJ'\nimport { getFormasCotacao } from '../../pages/Cotacao/fetch'\nimport { getFormasNegociacao } from '../../pages/Negociacao/fetch'\n\nconst PerguntaST = ({ cotacao, negociacao }) => {\n const store = useSelector((store) => store)\n const dispatch = useDispatch()\n\n const [load, setLoad] = useState(false)\n const carrinhoGimbaBool =\n store.envio.resumo?.Carrinho?.filter((e) => e.SellerId === null).length > 0\n\n return (\n
    \n {load && }\n {!!!isPF() &&\n !checkGovernoPj(store.user.info) &&\n !!checkEstadoST(store) &&\n carrinhoGimbaBool ? (\n
    \n
    \n \n Substituição Tributária\n }\n message=\"Substituição Tributária\"\n />\n \n
    \n

    \n Atenção: Produtos sujeitos a Substituição\n Tributária no Estado ({store.endereco.padrao?.uf}), que implicará no\n Acréscimo do ICMS-ST no valor do pedido. O valor total aqui\n apresentado não está incluso o ICMS-ST. Por favor, confirme as\n informações abaixo para o cálculo e selecione a condição de\n pagamento. Caso os produtos sejam tributados, será exibida uma\n mensagem com o valor do ICMS-ST, que será incluído no valor total do\n pedido.\n

    \n\n \n Você é Contribuinte de ICMS?:\n\n {\n if (store.pagamento.st.icms !== true) {\n if (!!!checkRevendaPj(store.user.info)) {\n if (!!cotacao) {\n getFormasCotacao(\n store.endereco.padrao.id,\n store.envio.fretePick,\n (res) => dispatch(setPagamento(res)),\n setLoad,\n () => undefined,\n () => undefined,\n store,\n true,\n true,\n true\n )\n } else if (!!negociacao) {\n getFormasNegociacao(\n store.endereco.padrao.id,\n store.envio.fretePick,\n (res) => dispatch(setPagamento(res)),\n setLoad,\n () => undefined,\n () => undefined,\n store,\n true,\n true,\n true\n )\n } else {\n getFormas(\n store.endereco.padrao.id,\n store.envio.fretePick,\n (res) => dispatch(setPagamento(res)),\n setLoad,\n store,\n true,\n true,\n true\n )\n }\n }\n }\n dispatch(setST('icms', true))\n }}\n />\n \n\n {\n if (store.pagamento.st.icms !== false) {\n if (!!!checkRevendaPj(store.user.info)) {\n if (!!cotacao) {\n getFormasCotacao(\n store.endereco.padrao.id,\n store.envio.fretePick,\n (res) => dispatch(setPagamento(res)),\n setLoad,\n () => undefined,\n () => undefined,\n store,\n true,\n false,\n true\n )\n } else if (!!negociacao) {\n getFormasNegociacao(\n store.endereco.padrao.id,\n store.envio.fretePick,\n (res) => dispatch(setPagamento(res)),\n setLoad,\n () => undefined,\n () => undefined,\n store,\n true,\n false,\n true\n )\n } else {\n getFormas(\n store.endereco.padrao.id,\n store.envio.fretePick,\n (res) => dispatch(setPagamento(res)),\n setLoad,\n store,\n true,\n false,\n false\n )\n }\n }\n }\n dispatch(setST('icms', false))\n }}\n />\n \n \n {!!checkRevendaPj(store.user.info) ? (\n \n Os produtos comprados serão destinados a:\n {\n if (store.pagamento.st.destinoFiscal !== 'consumo') {\n if (!!cotacao) {\n getFormasCotacao(\n store.endereco.padrao.id,\n store.envio.fretePick,\n (res) => dispatch(setPagamento(res)),\n setLoad,\n () => undefined,\n () => undefined,\n store,\n true,\n true\n )\n } else if (!!negociacao) {\n getFormasNegociacao(\n store.endereco.padrao.id,\n store.envio.fretePick,\n (res) => dispatch(setPagamento(res)),\n setLoad,\n () => undefined,\n () => undefined,\n store,\n true,\n true\n )\n } else {\n getFormas(\n store.endereco.padrao.id,\n store.envio.fretePick,\n (res) => dispatch(setPagamento(res)),\n setLoad,\n store,\n true,\n true\n )\n }\n dispatch(setST('destinoFiscal', 'consumo'))\n }\n }}\n />\n \n\n {\n if (store.pagamento.st.destinoFiscal !== 'revenda') {\n if (!!cotacao) {\n getFormasCotacao(\n store.endereco.padrao.id,\n store.envio.fretePick,\n (res) => dispatch(setPagamento(res)),\n setLoad,\n () => undefined,\n () => undefined,\n store,\n true,\n false\n )\n } else if (!!negociacao) {\n getFormasNegociacao(\n store.endereco.padrao.id,\n store.envio.fretePick,\n (res) => dispatch(setPagamento(res)),\n setLoad,\n () => undefined,\n () => undefined,\n store,\n true,\n false\n )\n } else {\n getFormas(\n store.endereco.padrao.id,\n store.envio.fretePick,\n (res) => dispatch(setPagamento(res)),\n setLoad,\n store,\n true,\n false\n )\n }\n dispatch(setST('destinoFiscal', 'revenda'))\n }\n }}\n />\n \n \n ) : null}\n
    \n ) : null}\n {!!negociacao && (\n \n
    \n Observações\n
    \n \n dispatch(setST('observacaoCliente', e.target.value))\n }\n />\n
    \n )}\n \n
    \n \n Observação de Nota Fiscal\n }\n message=\"Observação na Nota Fiscal\"\n />\n \n
    \n dispatch(setST('observacao', e.target.value))}\n />\n
    \n
    \n )\n}\nexport default PerguntaST\n","import styled, { css } from 'styled-components'\r\n\r\nexport const ProfileTitle = styled.h2`\r\n font-size: 22px;\r\n margin-bottom: 20px;\r\n color: #555;\r\n`\r\n\r\nexport const Wrapper = styled.div``\r\n\r\nexport const CardWrapper = styled.div`\r\n @media (min-width: 1170px) {\r\n .col-6 {\r\n width: 50%;\r\n }\r\n }\r\n`\r\n\r\nexport const CardBox = styled.div`\r\n padding: 8px 16px;\r\n height: 100px;\r\n display: flex;\r\n align-items: center;\r\n justify-content: flex-start;\r\n position: relative;\r\n\r\n background: #ffffff;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 4px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 8px;\r\n\r\n .iconCredit {\r\n /* background-color: blue; */\r\n display: flex;\r\n align-items: center;\r\n padding-left: 2px;\r\n\r\n @media (max-width: 480px) {\r\n width: 32px;\r\n }\r\n }\r\n`\r\n\r\nexport const MainCard = styled.div`\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n position: relative;\r\n\r\n label {\r\n position: absolute;\r\n display: flex;\r\n align-items: center;\r\n margin-top: -17px;\r\n }\r\n`\r\n\r\nexport const CardInfo = styled.div`\r\n justify-self: left;\r\n font-size: 14px;\r\n margin-left: 16px;\r\n margin-right: 8px;\r\n width: 240px;\r\n flex: 1;\r\n\r\n strong {\r\n font-weight: 600;\r\n }\r\n\r\n select.parcelas {\r\n padding: 8px 30px 8px 16px;\r\n margin: 4px 8px -12px 0;\r\n max-width: 280px;\r\n color: #2e2e2e;\r\n\r\n @media (max-width: 545px) {\r\n max-width: calc(100% - 20px);\r\n }\r\n }\r\n`\r\n\r\nexport const CardIcon = styled.a`\r\n transition: all 400ms;\r\n right: 22px;\r\n /* flex: 1; */\r\n text-align: right;\r\n\r\n & img {\r\n width: 18px;\r\n height: 21px;\r\n cursor: pointer;\r\n\r\n &:hover {\r\n filter: invert(22%) sepia(78%) saturate(2710%) hue-rotate(341deg)\r\n brightness(88%) contrast(96%);\r\n }\r\n\r\n @media (max-width: 480px) {\r\n width: 16px;\r\n }\r\n }\r\n`\r\n","import IconRemove from '../../../assets/icons/icon-remove.svg'\r\nimport { ImBarcode } from 'react-icons/im'\r\nimport * as S from './styles'\r\nimport Select from '../../Select'\r\nimport { useEffect, useState } from 'react'\r\nimport {\r\n setCondicaoIndex,\r\n setCondicaoIndexF,\r\n setPagamento\r\n} from '../../../store/ducks/pagamento'\r\nimport CreditCardImage from '../CreditCardImage'\r\nimport { useSelector, useDispatch } from 'react-redux'\r\nimport { isPF } from '../../../api/auth/auth'\r\n\r\nconst PixCard = ({\r\n type,\r\n check,\r\n setCheck,\r\n setSelectedParcela,\r\n condicoes,\r\n faturado\r\n}) => {\r\n const dispatch = useDispatch()\r\n const store = useSelector((store) => store)\r\n const [data, setData] = useState({ id: '' })\r\n\r\n const [showOptions, setShowOptions] = useState({\r\n showOptions: false\r\n })\r\n\r\n const handleShowSelected = (cardDetail) => {\r\n setShowOptions({\r\n [cardDetail]: !showOptions[cardDetail]\r\n })\r\n }\r\n\r\n useEffect(() => {\r\n let pix = store.pagamento.pagamento?.Formas?.find(\r\n (forma) => forma.Descricao === 'PIX'\r\n )\r\n\r\n if (pix === undefined) {\r\n pix = store.pagamento.pagamentoSeller?.Formas?.find(\r\n (forma) => forma.Descricao === 'PIX'\r\n )\r\n }\r\n\r\n if (pix.Descricao === 'PIX') {\r\n setData(pix)\r\n }\r\n // eslint-disable-next-line react-hooks/exhaustive-deps\r\n }, [store.pagamento.pagamento.Formas])\r\n\r\n return (\r\n <>\r\n \r\n \r\n \r\n \r\n {\r\n setCheck({ id: 'pix' })\r\n }}\r\n />\r\n \r\n \r\n\r\n \r\n\r\n \r\n

    \r\n {data.Descricao}\r\n

    \r\n

    Aprovação imediata

    \r\n
    \r\n
    \r\n
    \r\n
    \r\n \r\n )\r\n}\r\n\r\nexport default PixCard\r\n","/* eslint-disable react-hooks/exhaustive-deps */\r\nimport CreditCard from './CreditCard'\r\nimport GimplusCard from './GimbaCard'\r\nimport * as S from './styles'\r\nimport { FormGroup } from '../../components/Form/styles'\r\nimport BoletoCard from './BoletoCard'\r\nimport NewCard from './NewCard'\r\nimport Tooltip from '../Tooltip'\r\nimport { useEffect, useState } from 'react'\r\nimport { useSelector, useDispatch } from 'react-redux'\r\nimport { isPF } from '../../api/auth/auth'\r\nimport {\r\n setPick,\r\n setPickF,\r\n setST,\r\n setCondicoes,\r\n setCondicaoIndex,\r\n setCondicaoIndexF,\r\n setCvv,\r\n setCondicaoFaturado\r\n} from '../../store/ducks/pagamento'\r\nimport MediaMatch from '../MediaMatch'\r\nimport GimbaCard from './GimbaCard'\r\nimport ToastFaturado from '../ToastFaturado'\r\nimport PerguntaST from '../PerguntasST'\r\nimport PixCard from './PixCard'\r\n\r\nconst PaymentForm = ({\r\n addCreditCard,\r\n cardData,\r\n cardDataSeller,\r\n formas,\r\n formasSeller,\r\n removeCard,\r\n revenda,\r\n governo,\r\n estadosST\r\n}) => {\r\n const store = useSelector((store) => store)\r\n const dispatch = useDispatch()\r\n\r\n const isFaturado = () => {\r\n return (\r\n store.pagamento.condicaoFaturado?.IdTipo === 3 &&\r\n +store.pagamento?.condicaoIndex > 0 &&\r\n store.envio.resumo?.Carrinho.filter((e) => e.SellerId === null).length >\r\n 0 &&\r\n store.envio.resumo?.Carrinho.filter((e) => e.SellerId !== null).length > 0\r\n )\r\n }\r\n\r\n const formasValidation = isFaturado() ? formasSeller : formas\r\n\r\n useEffect(() => {\r\n let cond\r\n\r\n if (!!formas && store.pagamento.pick?.id !== 'boleto') {\r\n cond = formas[0]?.Condicoes.filter(\r\n (e) => e.Descricao === store.pagamento.pick?.descricao\r\n )[0]\r\n if (!!formas[1]?.Condicoes[1]) dispatch(setCondicaoFaturado({}))\r\n }\r\n\r\n if (!!formas && store.pagamento.pick?.id === 'boleto') {\r\n const condFaturado = formas[1]?.Condicoes[1]\r\n cond = formas[1]?.Condicoes[0]\r\n if (!!condFaturado) {\r\n dispatch(setCondicaoFaturado(condFaturado))\r\n dispatch(setCondicaoIndexF('0'))\r\n }\r\n }\r\n\r\n if (!!formas && store.pagamento.pick?.id === 'pix') {\r\n // cond = formas[2]?.Condicoes[0]\r\n cond = formas.find((forma) => forma.Descricao === 'PIX')?.Condicoes[0]\r\n }\r\n\r\n dispatch(setCondicoes(cond))\r\n // console.log(cond, store.pagamento)\r\n }, [store.pagamento.pick, store.pagamento.pickF])\r\n\r\n const carrinhoGimbaBool =\r\n store.envio.resumo?.Carrinho?.filter((e) => e.SellerId === null).length > 0\r\n\r\n const descontao = () => {\r\n const gimbaN = store.envio.resumo.Carrinho?.filter(\r\n (e) => e.SellerId === null\r\n ).length\r\n\r\n if (gimbaN > 0)\r\n return (\r\n
    \r\n
    \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n
    \r\n
    \r\n )\r\n return null\r\n }\r\n\r\n return (\r\n \r\n {descontao()}\r\n
    \r\n Opções de Pagamento\r\n
    \r\n {cardData?.map((card) => {\r\n return (\r\n \r\n {\r\n dispatch(setCvv(''))\r\n dispatch(setPick(res))\r\n dispatch(setCondicaoIndex(0))\r\n }}\r\n >\r\n \r\n )\r\n })}\r\n\r\n \r\n addCreditCard()}>\r\n \r\n\r\n \r\n {\r\n dispatch(setPick(res))\r\n dispatch(setCondicaoIndex(0))\r\n }}\r\n >\r\n \r\n\r\n {/* {console.log({ formasSeller })} */}\r\n\r\n {formasValidation?.find((item) => item?.Descricao === 'PIX') !==\r\n undefined && (\r\n \r\n {\r\n dispatch(setPick(res))\r\n dispatch(setCondicaoIndex(0))\r\n }}\r\n />\r\n \r\n )}\r\n
    \r\n
    \r\n {/* {boleto faturado} */}\r\n {isFaturado() && (\r\n
    \r\n \r\n
    \r\n {cardDataSeller?.map((cardF) => {\r\n return (\r\n \r\n {\r\n dispatch(setPickF(res))\r\n dispatch(setCvv(''))\r\n }}\r\n >\r\n \r\n )\r\n })}\r\n \r\n addCreditCard()}>\r\n \r\n \r\n dispatch(setPickF(res))}\r\n >\r\n \r\n\r\n {/* {console.log({ formas })} */}\r\n\r\n {formasSeller?.find((item) => item.Descricao === 'PIX') !==\r\n undefined && (\r\n \r\n {\r\n dispatch(setPickF(res))\r\n // dispatch(setCondicaoIndexF(0))\r\n }}\r\n />\r\n \r\n )}\r\n
    \r\n
    \r\n )}\r\n {/* {boleto faturado} */}\r\n \r\n {!!isPF() && }\r\n \r\n \r\n
    \r\n )\r\n}\r\nexport default PaymentForm\r\n","import styled, { css } from 'styled-components'\r\n\r\nexport const SideContainer = styled.div`\r\n ${({ onlySeller }) => css`\r\n ${!!onlySeller\r\n ? css`\r\n margin-top: 25px;\r\n `\r\n : css`\r\n @media (min-width: 1171px) {\r\n margin-bottom: 45px;\r\n }\r\n `}\r\n `}\r\n`\r\n\r\nexport const CardBox = styled.div`\r\n background: #ffffff;\r\n padding: 16px;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 4px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 8px;\r\n\r\n .card-title {\r\n font-size: 18px;\r\n margin-bottom: 16px;\r\n font-weight: 500;\r\n }\r\n`\r\n\r\nexport const Total = styled.div`\r\n border-top: 1px solid rgba(187, 187, 187, 0.5);\r\n text-align: right;\r\n font-size: 14px;\r\n\r\n .total-value {\r\n display: flex;\r\n justify-content: space-between;\r\n margin-top: 8px;\r\n font-weight: 600;\r\n font-size: 14px;\r\n }\r\n\r\n @media (max-width: 800px) {\r\n border-top: none;\r\n\r\n .total-value {\r\n font-size: 16px;\r\n }\r\n }\r\n`\r\n\r\nexport const PedidoInfo = styled.ul`\r\n list-style: none;\r\n`\r\n\r\nexport const ItemInfo = styled.li`\r\n display: flex;\r\n justify-content: space-between;\r\n margin-bottom: 8px;\r\n font-size: 14px;\r\n\r\n p {\r\n position: relative;\r\n }\r\n`\r\n\r\nexport const MobileWrapper = styled.div`\r\n position: fixed;\r\n bottom: 0;\r\n width: 100vw;\r\n padding: 8px 4% 8px 2%;\r\n margin-left: -15px;\r\n display: flex;\r\n flex-direction: column;\r\n background-color: violet;\r\n background-color: #fbfbfb;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.2);\r\n`\r\n\r\nexport const Button = styled.button`\r\n ${({ theme }) => css`\r\n border-radius: 5px;\r\n border: 2px solid transparent;\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 500;\r\n font-size: 16px;\r\n padding: 15px 30px;\r\n margin-bottom: 10px;\r\n width: 100%;\r\n text-align: center;\r\n transition: ${theme.transition.default};\r\n cursor: pointer;\r\n background: ${theme.colors.primary};\r\n color: ${theme.colors.white};\r\n\r\n &:hover {\r\n background: #a71e26;\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: $MEDIA-IPAD) {\r\n font-size: 14px;\r\n }\r\n\r\n &.button-outline {\r\n background: transparent;\r\n border: 2px solid #8f8f8f;\r\n color: #8f8f8f;\r\n\r\n &:hover {\r\n border-color: #4a4a4a;\r\n color: #4a4a4a;\r\n }\r\n\r\n &:disabled {\r\n color: #7b7b7b;\r\n border-color: #7b7b7b;\r\n cursor: initial;\r\n }\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n & + .button {\r\n margin-left: 0;\r\n margin-top: 8px;\r\n }\r\n }\r\n `}\r\n`\r\n","import carrinho from '../../api/carrinho'\r\n\r\nexport const postPedido = async (\r\n store,\r\n save,\r\n load = () => undefined,\r\n msg = () => undefined,\r\n router = () => undefined,\r\n bloqueio = () => undefined\r\n) => {\r\n const dataAgendada = (type = 0) => {\r\n const fill = (n) => (String(n).length < 2 ? '0' + n : n)\r\n let data = ''\r\n let day, month, year\r\n if (!!store.envio.fretePick?.Agenda?.date) {\r\n data = new Date(store.envio.fretePick?.Agenda?.date)\r\n day = fill(data.getDate())\r\n month = fill(+data.getMonth() + 1)\r\n year = fill(data.getFullYear())\r\n } else {\r\n return null\r\n }\r\n if (type === 0) return `${day}/${month}/${year}`\r\n return `${year}-${month}-${day}T03:00:00.000Z`\r\n }\r\n\r\n load(true)\r\n const { condicoes, condicaoFaturado, condicaoIndex, pick, st } =\r\n store.pagamento\r\n const { padrao } = store.endereco\r\n const { fretePick } = store.envio\r\n const freteGimba = store.envio.frete.Gimba.OpcoesFrete[0]\r\n const StoredFreteSeller = Object.keys(fretePick)\r\n .filter((e) => e !== 'Gimba' && e !== 'Agenda')\r\n .map((e) => ({\r\n SellerId: fretePick[e].saveId,\r\n Valor: fretePick[e].value,\r\n PrazoEntrega: fretePick[e].time,\r\n IdNomeMetodoEntrega: fretePick[e].IdNomeMetodoEntrega,\r\n NomeMetodoEntrega: fretePick[e].NomeMetodoEntrega\r\n }))\r\n\r\n const body = {\r\n CodigoPromotor: store.pagamento.promotor?.codigoPromotorGimba || '',\r\n TipoPedido: 'P',\r\n Cartao: {\r\n NomeTitular: '',\r\n NumeroCartao: '',\r\n CodigoSeguranca: store.pagamento.cvv || '',\r\n ValidadeMes: '',\r\n ValidadeAno: '',\r\n Token: pick.id === 'boleto' ? '' : pick.id,\r\n Salvar: false\r\n },\r\n Pagamento: {\r\n Id: store.pagamento.condicoes.IdTipo,\r\n Descricao: store.pagamento.condicoes.Descricao,\r\n Status: true,\r\n Condicoes: [\r\n {\r\n Id: condicoes.Id,\r\n Descricao: condicoes.Descricao,\r\n UriImagem: condicoes.UriImagem,\r\n TipoPessoa: condicoes.TipoPessoa,\r\n CodigoERP: condicoes.CodigoERP,\r\n IdEmpresa: condicoes.IdEmpresa,\r\n Status: condicoes.Status,\r\n IdTipo: condicoes.IdTipo,\r\n Parcelas:\r\n pick.id === 'boleto' && condicaoIndex > 0\r\n ? [condicaoFaturado.Parcelas[condicaoIndex - 1]]\r\n : [condicoes.Parcelas[condicaoIndex]]\r\n }\r\n ]\r\n },\r\n Endereco: {\r\n Id: padrao.id,\r\n TipoEndereco: padrao.tipoEndereco,\r\n TipoLogradouro: padrao.tipoLogradouro,\r\n Endereco: padrao.logradouro,\r\n ApelidoEndereco: padrao.apelido,\r\n PontoReferencia: padrao.pontoReferencia,\r\n Numero: padrao.numero,\r\n Complemento: padrao.complemento,\r\n Bairro: padrao.bairro,\r\n Cidade: padrao.cidade,\r\n UF: padrao.uf,\r\n Cep: padrao.cep\r\n },\r\n FreteGimba: {\r\n Id: fretePick.Gimba?.id,\r\n RazaoSocial: fretePick.Gimba?.name,\r\n DiasParaEntrega: fretePick.Gimba?.time,\r\n ValorFrete: fretePick.Gimba?.value,\r\n ValorFreteAgendado: freteGimba?.ValorFreteAgendado,\r\n ValorFreteEmpresa: freteGimba?.ValorFreteEmpresa,\r\n ValorTda: freteGimba?.ValorTda,\r\n ValorTde: freteGimba?.ValorTde,\r\n ValorAdmFrete: freteGimba?.ValorAdmFrete,\r\n ValorFreteAteRedespacho: freteGimba?.ValorFreteAteRedespacho,\r\n ValorPercentualIcms: freteGimba?.ValorPercentualIcms,\r\n ValorTranslado: freteGimba?.ValorTranslado,\r\n CNPJTransportadoraRedespacho: freteGimba?.CNPJTransportadoraRedespacho,\r\n CNPJTranslado: freteGimba?.CNPJTranslado,\r\n Retira: freteGimba?.Retira,\r\n FOB: freteGimba?.FOB,\r\n DataAgendamento: freteGimba?.DataAgendamento,\r\n PeriodoAgendamento: freteGimba?.PeriodoAgendamento,\r\n ValorEmex: freteGimba?.ValorEmex\r\n },\r\n FreteSeller: StoredFreteSeller,\r\n DemaisInformacoes: {\r\n IdPedido: 0,\r\n ObservacaoNF: st.observacao,\r\n ObservacaoNegociacao: '',\r\n SituacaoTributaria: st.icms !== undefined,\r\n SituacaoTributariaIcms:\r\n st.icms !== undefined\r\n ? st.icms\r\n : store.envio.resumo.SituacaoTributariaExibir,\r\n SituacaoTributariaConsumo:\r\n store.pagamento.st.destinoFiscal === 'revenda' ? false : true,\r\n SituacaoTributariaSelecionar: st.icms !== undefined,\r\n PeriodoEntregaAgendada:\r\n fretePick.Agenda?.turno === 'n'\r\n ? 3\r\n : fretePick.Agenda?.turno === 't'\r\n ? 2\r\n : fretePick.Agenda?.turno === 'm'\r\n ? 1\r\n : '',\r\n DataEntregaAgendada: dataAgendada(1),\r\n DataAgendada: dataAgendada(),\r\n EntregaAgendada: store.envio.fretePick.Agenda?.id === 'agenda',\r\n ObservacaoCliente: ''\r\n }\r\n }\r\n\r\n try {\r\n let pedidoStatus = await carrinho.postPedido(body)\r\n let pedido = await pedidoStatus.json()\r\n await save(pedido)\r\n localStorage.setItem('finalizado', JSON.stringify(pedido))\r\n localStorage.setItem('pagamento', JSON.stringify(store.pagamento))\r\n sessionStorage.setItem('finalizado', JSON.stringify(pedido))\r\n sessionStorage.setItem('pagamento', JSON.stringify(store.pagamento))\r\n\r\n if (!!pedido?.Validation?.Errors?.length > 0) {\r\n let erro = 0\r\n if (pedido?.Validation?.Errors[0]?.Message.includes('fraude')) {\r\n erro = 403\r\n }\r\n msg(pedido?.Validation?.Errors[0]?.Message, erro)\r\n } else if (!!pedido?.Bloqueio?.Valid) {\r\n bloqueio()\r\n } else if (!!pedido.Id) {\r\n router()\r\n } else {\r\n msg(\r\n 'Erro ao processar o pedido - tente mais tarde novamente',\r\n pedidoStatus.status\r\n )\r\n }\r\n // console.log({ body, store })\r\n // console.log('pedido feito', pedido, 'body do pedido', body)\r\n } catch (e) {\r\n // console.log('deu ruim', e, 'body com erro?', body)\r\n }\r\n\r\n load(false)\r\n}\r\n\r\nexport const postPedidoFaturado = async (\r\n store,\r\n save,\r\n load = () => undefined,\r\n msg = () => undefined,\r\n router = () => undefined,\r\n bloqueio = () => undefined\r\n) => {\r\n load(true)\r\n const { condicaoIndex, condicaoIndexF, pick, pickF, st, condicaoFaturado } =\r\n store.pagamento\r\n const { padrao } = store.endereco\r\n const { fretePick } = store.envio\r\n const freteGimba = store.envio.frete.Gimba.OpcoesFrete[0]\r\n\r\n const bodyGimba = {\r\n CodigoPromotor: '',\r\n TipoPedido: 'P',\r\n Cartao: {\r\n NomeTitular: '',\r\n NumeroCartao: '',\r\n CodigoSeguranca: '',\r\n ValidadeMes: '01',\r\n ValidadeAno: '2022',\r\n Token: '',\r\n Salvar: false\r\n },\r\n Pagamento: {\r\n Id: 3,\r\n Descricao: 'Boleto Bancário',\r\n Status: true,\r\n Condicoes: [\r\n {\r\n Id: 6,\r\n Descricao: 'Boleto Bancário Gimba Faturado',\r\n UriImagem: '/Images/FormasPagamento/logo_boleto.jpg',\r\n TipoPessoa: 'A',\r\n CodigoERP: ' ',\r\n IdEmpresa: 1,\r\n Status: true,\r\n IdTipo: 3,\r\n Parcelas: [condicaoFaturado.Parcelas[condicaoIndex - 1]]\r\n }\r\n ]\r\n },\r\n Endereco: {\r\n Id: padrao.id,\r\n TipoEndereco: padrao.tipoEndereco,\r\n TipoLogradouro: padrao.tipoLogradouro,\r\n Endereco: padrao.logradouro,\r\n ApelidoEndereco: padrao.apelido,\r\n PontoReferencia: padrao.pontoReferencia,\r\n Numero: padrao.numero,\r\n Complemento: padrao.complemento,\r\n Bairro: padrao.bairro,\r\n Cidade: padrao.cidade,\r\n UF: padrao.uf,\r\n Cep: padrao.cep\r\n },\r\n FreteGimba: {\r\n Id: fretePick.Gimba?.id,\r\n RazaoSocial: fretePick.Gimba?.name,\r\n DiasParaEntrega: fretePick.Gimba?.time,\r\n ValorFrete: fretePick.Gimba?.value,\r\n ValorFreteAgendado: freteGimba?.ValorFreteAgendado,\r\n ValorFreteEmpresa: freteGimba?.ValorFreteEmpresa,\r\n ValorTda: freteGimba?.ValorTda,\r\n ValorTde: freteGimba?.ValorTde,\r\n ValorAdmFrete: freteGimba?.ValorAdmFrete,\r\n ValorFreteAteRedespacho: freteGimba?.ValorFreteAteRedespacho,\r\n ValorPercentualIcms: freteGimba?.ValorPercentualIcms,\r\n ValorTranslado: freteGimba?.ValorTranslado,\r\n CNPJTransportadoraRedespacho: freteGimba?.CNPJTransportadoraRedespacho,\r\n CNPJTranslado: freteGimba?.CNPJTranslado,\r\n Retira: freteGimba?.Retira,\r\n FOB: freteGimba?.FOB,\r\n DataAgendamento: freteGimba?.DataAgendamento,\r\n PeriodoAgendamento: freteGimba?.PeriodoAgendamento,\r\n ValorEmex: freteGimba?.ValorEmex\r\n },\r\n FreteSeller: [],\r\n DemaisInformacoes: {\r\n IdPedido: 0,\r\n ObservacaoNF: st.observacao,\r\n ObservacaoNegociacao: '',\r\n SituacaoTributaria: st.icms !== undefined,\r\n SituacaoTributariaIcms:\r\n st.icms !== undefined\r\n ? st.icms\r\n : store.envio.resumo.SituacaoTributariaExibir,\r\n SituacaoTributariaConsumo:\r\n store.pagamento.st.destinoFiscal === 'revenda' ? false : true,\r\n SituacaoTributariaSelecionar: st.icms !== undefined,\r\n PeriodoEntregaAgendada:\r\n fretePick.Agenda?.turno === 'n'\r\n ? 3\r\n : fretePick.Agenda?.turno === 't'\r\n ? 2\r\n : fretePick.Agenda?.turno === 'm'\r\n ? 1\r\n : '',\r\n DataEntregaAgendada: '',\r\n DataAgendada:\r\n fretePick.Agenda?.id === 'agenda' ? fretePick.Agenda?.date : '',\r\n EntregaAgendada: fretePick.Agenda?.id === 'agenda',\r\n ObservacaoCliente: ''\r\n }\r\n }\r\n\r\n const FormasSeller = store.pagamento.pagamentoSeller?.Formas\r\n\r\n // const Condicoes =\r\n // pickF.id === 'boleto'\r\n // ? FormasSeller[1]?.Condicoes[0]\r\n // : FormasSeller[0].Condicoes.filter(\r\n // (e) => e.Descricao === pickF.descricao\r\n // )[0]\r\n\r\n let Condicoes\r\n\r\n if (pickF.id === 'boleto') {\r\n Condicoes = FormasSeller[1]?.Condicoes[0]\r\n } else if (pickF.id === 'pix') {\r\n Condicoes = FormasSeller[2]?.Condicoes[0]\r\n } else {\r\n Condicoes = FormasSeller[0].Condicoes.filter(\r\n (e) => e.Descricao === pickF.descricao\r\n )[0]\r\n }\r\n\r\n // console.log({ store, Condicoes })\r\n\r\n const condicFaturado = [\r\n {\r\n Id: Condicoes.Id,\r\n Descricao: Condicoes.Descricao,\r\n UriImagem: Condicoes.UriImagem,\r\n TipoPessoa: Condicoes.TipoPessoa,\r\n CodigoERP: Condicoes.CodigoERP,\r\n IdEmpresa: Condicoes.IdEmpresa,\r\n Status: Condicoes.Status,\r\n IdTipo: Condicoes.IdTipo,\r\n Parcelas: [Condicoes.Parcelas[condicaoIndexF]]\r\n }\r\n ]\r\n //\r\n const StoredFreteSeller = Object.keys(fretePick)\r\n .filter((e) => e !== 'Gimba' && e !== 'Agenda')\r\n .map((e) => ({\r\n SellerId: fretePick[e].saveId,\r\n Valor: fretePick[e].value,\r\n PrazoEntrega: fretePick[e].time,\r\n IdNomeMetodoEntrega: fretePick[e].IdNomeMetodoEntrega,\r\n NomeMetodoEntrega: fretePick[e].NomeMetodoEntrega\r\n }))\r\n\r\n const bodySeller = {\r\n CodigoPromotor: '',\r\n TipoPedido: 'P',\r\n Cartao: {\r\n NomeTitular: '',\r\n NumeroCartao: '',\r\n CodigoSeguranca: store.pagamento.cvv || '',\r\n ValidadeMes: '',\r\n ValidadeAno: '',\r\n Token: pickF.id === 'boleto' ? '' : pickF.id,\r\n Salvar: false\r\n },\r\n Pagamento: {\r\n Id: Condicoes.IdTipo,\r\n Descricao: Condicoes.Descricao,\r\n Status: true,\r\n Condicoes: condicFaturado\r\n },\r\n Endereco: {\r\n Id: padrao.id,\r\n TipoEndereco: padrao.tipoEndereco,\r\n TipoLogradouro: padrao.tipoLogradouro,\r\n Endereco: padrao.logradouro,\r\n ApelidoEndereco: padrao.apelido,\r\n PontoReferencia: padrao.pontoReferencia,\r\n Numero: padrao.numero,\r\n Complemento: padrao.complemento,\r\n Bairro: padrao.bairro,\r\n Cidade: padrao.cidade,\r\n UF: padrao.uf,\r\n Cep: padrao.cep\r\n },\r\n FreteGimba: {},\r\n FreteSeller: StoredFreteSeller,\r\n DemaisInformacoes: {\r\n IdPedido: 0,\r\n ObservacaoNF: st.observacao,\r\n ObservacaoNegociacao: '',\r\n SituacaoTributaria: false,\r\n SituacaoTributariaIcms: false,\r\n SituacaoTributariaConsumo: true,\r\n SituacaoTributariaSelecionar: false,\r\n PeriodoEntregaAgendada: '',\r\n DataEntregaAgendada: '',\r\n DataAgendada:\r\n fretePick.Agenda?.id === 'agenda' ? fretePick.Agenda?.date : '',\r\n EntregaAgendada: fretePick.Agenda?.id === 'agenda',\r\n ObservacaoCliente: ''\r\n }\r\n }\r\n\r\n try {\r\n let pedidoStatus = await carrinho.postPedidoFaturado([\r\n bodyGimba,\r\n bodySeller\r\n ])\r\n let pedido = await pedidoStatus.json()\r\n await save(pedido)\r\n localStorage.setItem('finalizado', JSON.stringify(pedido))\r\n localStorage.setItem('pagamento', JSON.stringify(store.pagamento))\r\n sessionStorage.setItem('finalizado', JSON.stringify(pedido))\r\n sessionStorage.setItem('pagamento', JSON.stringify(store.pagamento))\r\n if (!!pedido?.Validation?.Errors?.length > 0) {\r\n msg(pedido?.Validation?.Errors[0]?.Message)\r\n } else if (!!pedido?.Bloqueio?.Valid) {\r\n bloqueio()\r\n } else if (!!pedido[0].Id) {\r\n router()\r\n } else {\r\n msg('Erro ao processar o pedido - tente mais tarde novamente')\r\n }\r\n // console.log({ bodySeller, bodyGimba })\r\n } catch (e) {\r\n // console.log('deu ruim', e, 'body com erro?', body)\r\n }\r\n\r\n load(false)\r\n}\r\n","//Keys\r\nexport const Types = {\r\n SETPEDIDO: '@setPedido',\r\n SETTIPO: '@setTipo',\r\n RESETFINALIZADO: '@resetFinalizado'\r\n}\r\n\r\n//Reducer\r\nconst INITIAL_STATE = { pedido: '', tipo: '' }\r\n\r\nexport default function reducer(state = INITIAL_STATE, { type, payload }) {\r\n switch (type) {\r\n case Types.SETPEDIDO:\r\n return { ...state, pedido: payload }\r\n case Types.SETTIPO:\r\n return { ...state, tipo: payload }\r\n case Types.RESETFINALIZADO:\r\n return INITIAL_STATE\r\n default:\r\n return state\r\n }\r\n}\r\n\r\n//Actions\r\nexport const setPedido = (payload) => {\r\n return { type: Types.SETPEDIDO, payload: payload }\r\n}\r\n\r\nexport const setTipo = (payload) => {\r\n return { type: Types.SETTIPO, payload: payload }\r\n}\r\n\r\nexport const resetFinalizado = () => {\r\n return { type: Types.RESETFINALIZADO }\r\n}\r\n","import styled from 'styled-components'\r\n\r\nexport const Container = styled.div`\r\n position: relative;\r\n padding: 20px 40px 16px 20px;\r\n border-radius: 5px;\r\n display: flex;\r\n align-items: center;\r\n border-left: 6px solid #ff9017;\r\n margin-bottom: 10px;\r\n margin-top: 10px;\r\n\r\n button {\r\n position: absolute;\r\n right: 0px;\r\n // top: 15px;\r\n border: 0;\r\n background: transparent;\r\n color: inherit;\r\n cursor: pointer;\r\n }\r\n svg {\r\n margin: 4px 16px 0 10px;\r\n }\r\n div {\r\n flex: 1;\r\n font-size: 12px;\r\n p {\r\n margin-top: 4px;\r\n opacity: 0.8;\r\n line-height: 20px;\r\n }\r\n }\r\n background: #fff3e7;\r\n color: #ff9017;\r\n`\r\n","import { useState } from 'react'\r\nimport * as S from './styles'\r\nimport IconAlertSuccess from '../../assets/icons/icon-alert-alert.svg'\r\nimport { HiX } from 'react-icons/hi'\r\n\r\nconst ToastAvisoBoleto = () => {\r\n const [display, setDisplay] = useState(true)\r\n\r\n if (!display) return
    \r\n return (\r\n \r\n \r\n\r\n

    \r\n

    \r\n O Gimba emite exclusivamente boletos do Banco Bradesco. Antes de\r\n pagar,\r\n
    \r\n confira se o código de barras começa com 237.{' '}\r\n \r\n Em caso de divergência,
    \r\n não pague e entre em contato com nosso atendimento em (11)\r\n 2763-5000\r\n
    \r\n
    \r\n

    \r\n\r\n \r\n
    \r\n )\r\n}\r\n\r\nexport default ToastAvisoBoleto\r\n","export const Gimbafy = (value) => (value === null ? 'Gimba' : value)","import { useHistory } from 'react-router-dom'\nimport GimbaCard from '../PaymentCards/GimbaCard'\nimport Tooltip from '../Tooltip'\nimport * as S from './styles'\nimport { useSelector, useDispatch } from 'react-redux'\nimport { convertDecimalCurrency, precoMask } from '../../utils/utils'\nimport { postPedido, postPedidoFaturado } from './fetch'\nimport { setPedido } from '../../store/ducks/finalizado'\nimport MediaMatch from '../MediaMatch'\nimport { useEffect, useState } from 'react'\nimport Loader from '../Loader'\nimport { useToast } from '../../hooks/toast'\nimport { isPF } from '../../api/auth/auth'\nimport * as auth from '../../api/auth/auth'\nimport ToastAvisoBoleto from '../ToastAvisoBoleto'\nimport { Gimbafy } from '../Sellers/masks'\n\nconst ResumoPedido = ({\n pagamento,\n envio,\n confirmacao,\n setCvvModal,\n revenda,\n governo,\n estadosST,\n setBloqueio\n}) => {\n const { addToast } = useToast()\n const router = useHistory()\n const store = useSelector((store) => store)\n const dispatch = useDispatch()\n const [load, setLoad] = useState(false)\n const [lock, setLock] = useState(false)\n const [descontoMarketplace, setDescontoMarketplace] = useState(0)\n\n const logout = () => {\n auth.logout()\n }\n\n const conFaturado = store.pagamento.pagamento?.Formas !== undefined && [\n ...(store.pagamento.pagamento?.Formas[1]?.Condicoes[0]?.Parcelas || []),\n ...(store.pagamento.pagamento?.Formas[1]?.Condicoes[1]?.Parcelas || [])\n ]\n const conIndex = store.pagamento?.condicaoIndex\n\n const [acrescimo, setAcrescimo] = useState(0)\n const [totalIPI, setTotalIPI] = useState(store.envio.resumo?.ValorIpi)\n\n //const condicoes = store.pagamento.condicoes?.Parcelas\n const condicoes =\n store.pagamento.condicoes?.Formas !== undefined &&\n store.pagamento.condicoes?.IdTipo === 3 &&\n !isPF() &&\n store.pagamento?.st.icms === false\n ? store.pagamento.condicoes?.Parcelas\n : conFaturado\n\n //const condicoes = store.pagamento.condicoes?.Parcelas\n const condicoesCartaoPJ =\n store.pagamento.pagamento?.Formas !== undefined &&\n store.pagamento.condicoes?.IdTipo === 1 &&\n !isPF()\n ? store.pagamento.condicoes?.Parcelas\n : null\n\n useEffect(() => {\n if (\n store.pagamento?.st.icms === true ||\n store.pagamento?.st.icms === false\n ) {\n if (condicoesCartaoPJ === null) {\n setAcrescimo(condicoes[conIndex].ValorSt)\n } else {\n setAcrescimo(condicoesCartaoPJ[conIndex].ValorSt)\n }\n\n //console.log('User Effect', condicoes[conIndex])\n } else {\n setAcrescimo(0)\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [\n condicoes,\n conIndex,\n store.pagamento?.st.icms,\n store.pagamento.condicoes?.IdTipo,\n acrescimo\n ])\n\n const carrinhoGimbaBool =\n store.envio.resumo?.Carrinho?.filter((e) => e.SellerId === null).length > 0\n\n const carrinhoSellerBool =\n store.envio.resumo?.Carrinho?.filter((e) => e.SellerId !== null).length > 0\n\n const sumFrete = () => {\n let keys = Object.keys(store.envio.fretePick)\n const pick = store.envio.fretePick\n\n keys = keys.reduce((acc, e, i) => {\n if (pick[e]?.id === 'agenda') {\n acc -= pick['Gimba']?.value\n }\n\n return acc + (pick[e]?.value || 0)\n }, 0)\n return keys || 0\n }\n\n const validFrete = () => {\n const estoque = !store.envio.resumo.Carrinho?.some(\n (produto) => produto.TemEstoque === false\n )\n\n let frete = true\n //verificar se frete Gimba é valido\n let carrinhoGimba =\n store.envio.resumo?.Carrinho?.filter((e) => e.SellerId === null).length >\n 0\n\n if (carrinhoGimba && store.envio.fretePick['Gimba']?.id === undefined)\n frete = false\n //Verificar se o frete de sellers é valido\n for (let key in store.envio.fretePick) {\n if (key === 'Agenda') continue\n if (key === 'Gimba') continue\n if (store.envio.fretePick[key]?.id === undefined) {\n frete = false\n break\n }\n }\n return estoque && frete\n }\n\n const checkFrete = () => {\n let carrinho = [\n ...new Set(store.envio.resumo?.Carrinho.map((e) => e.SellerId))\n ]\n\n let current = Object.keys(store.envio.fretePick).filter(\n (e) => e !== 'Agenda'\n ).length\n\n if (!!store.envio.fretePick.Gimba) {\n if (store.envio.fretePick.Gimba.id === undefined) current -= 1\n }\n if (carrinho.length === 0) {\n addToast({\n type: 'error',\n title: 'Carrinho vazio.'\n })\n } else if (store.envio.frete.Cep === undefined) {\n addToast({\n type: 'error',\n title: 'Erro ao calcular frete',\n description: 'Atualize a página e aguarde um instante.'\n })\n } else if (carrinho.length === current) {\n handleDatalayerEnvio()\n router.push('/pagamento')\n } else if (!!store.envio.frete.Message) {\n addToast({\n type: 'error',\n title:\n 'Não foi possível encontrar uma transportadora para o endereço selecionado.',\n description: 'Entre em contato com nossa central de atendimento.'\n })\n } else {\n addToast({\n type: 'error',\n title: 'Selecione uma das Opções de Entrega'\n })\n }\n }\n\n const checkPagamento = () => {\n if (\n !!!isPF() &&\n !governo &&\n !!estadosST() &&\n carrinhoGimbaBool &&\n store.pagamento.st.icms === undefined\n ) {\n addToast({\n type: 'error',\n title: 'Informe se você é contribuinte de ICMS'\n })\n } else if (\n !!!isPF() &&\n !governo &&\n !!estadosST() &&\n !!revenda &&\n carrinhoGimbaBool &&\n store.pagamento.st.destinoFiscal === undefined\n ) {\n addToast({\n type: 'error',\n title: 'Informe destino fiscal da mercadoria'\n })\n } else if (!!!store.pagamento.pick?.id) {\n addToast({\n type: 'error',\n title: 'Selecione uma forma de pagamento'\n })\n } else if (\n store.pagamento.condicaoFaturado?.IdTipo === 3 &&\n conIndex > 0 &&\n !!!store.pagamento.pickF.id &&\n store.envio.resumo?.Carrinho.filter((e) => e.SellerId !== null).length > 0\n ) {\n addToast({\n type: 'error',\n title: 'Selecione uma forma de pagamento para os itens de parceiros'\n })\n } else if (\n store.envio.resumo.Carrinho.some((e) => !!e.SellerId) &&\n store.pagamento.cvv === '' &&\n store.pagamento.pick.id !== 'boleto' &&\n store.pagamento.pick.id !== 'pix'\n ) {\n setCvvModal(true)\n } else if (\n store.pagamento.condicaoFaturado?.IdTipo === 3 &&\n conIndex > 0 &&\n store.pagamento.pick.id !== 'boleto' &&\n store.pagamento.pick.id !== 'pix' &&\n store.envio.resumo?.Carrinho.filter((e) => e.SellerId !== null).length > 0\n ) {\n setCvvModal(true)\n } else {\n handleDatalayerPagamento()\n router.push('/confirmacao')\n }\n }\n\n const postFinal = async () => {\n if (!lock) {\n if (\n store.pagamento.condicaoFaturado?.IdTipo === 3 &&\n conIndex > 0 &&\n !!store.pagamento.pickF.id\n ) {\n await setLock(true)\n await postPedidoFaturado(\n store,\n (res) => dispatch(setPedido(res)),\n setLoad,\n (msg) =>\n addToast({\n type: 'error',\n title: msg\n }),\n () =>\n (window.location.href = `${process.env.REACT_APP_URL_MAIN}/checkout/pedidoEfetuado`),\n //() => router.push('/finalizado'),\n () => setBloqueio(true)\n )\n await setLock(false)\n } else {\n await setLock(true)\n await postPedido(\n store,\n (res) => dispatch(setPedido(res)),\n setLoad,\n (msg, erro) => {\n addToast({\n type: 'error',\n title: msg\n })\n if (erro == 403) {\n setTimeout(function () {\n logout()\n window.location.href = `${process.env.REACT_APP_URL_MAIN}/MarketPlaceCliente/logout`\n }, 5000)\n }\n },\n () =>\n (window.location.href = `${process.env.REACT_APP_URL_MAIN}/checkout/pedidoEfetuado`),\n // () => router.push('/finalizado'),\n () => setBloqueio(true)\n )\n await setLock(false)\n }\n }\n }\n\n const verificarEAtualizarTotalIPI = (novoValorIPI) => {\n if (novoValorIPI !== totalIPI) {\n setTotalIPI(novoValorIPI)\n }\n }\n\n const condicoesBoleto = () => {\n if (\n store.pagamento.condicaoFaturado?.IdTipo === 3 &&\n conIndex > 0 &&\n carrinhoSellerBool\n ) {\n return ''\n }\n\n if (store.pagamento.condicoes?.IdTipo === 3 && conIndex <= 0) {\n verificarEAtualizarTotalIPI(\n store.pagamento.condicoes?.Parcelas[conIndex]?.ValorTotalIPI\n )\n return (\n
    \n

    {condicoes[conIndex]?.DescricaoPagamento}

    \n

    \n Valor com desconto:\n {precoMask(\n store.pagamento.condicoes?.Parcelas[conIndex]?.ValorParcela *\n store.pagamento.condicoes?.Parcelas[conIndex]?.NumeroParcela\n )}\n

    \n
    \n )\n }\n\n if (store.pagamento.condicoes?.IdTipo === 3 && conIndex > 0) {\n verificarEAtualizarTotalIPI(condicoes[conIndex]?.ValorTotalIPI)\n return (\n
    \n

    {condicoes[conIndex]?.DescricaoPagamento}

    \n {condicoes[conIndex]?.PercentualJuros > 0 && (\n

    \n Valor com acréscimo:{' '}\n {precoMask(\n condicoes[conIndex]?.ValorParcela *\n condicoes[conIndex]?.NumeroParcela\n )}\n

    \n )}\n
    \n )\n }\n\n return ''\n }\n const condicoesCartao = () => {\n if (store.pagamento.condicoes?.IdTipo === 1 && condicoes !== undefined) {\n if (isPF() === true) {\n verificarEAtualizarTotalIPI(\n store.pagamento.condicoes?.Parcelas[conIndex]?.ValorTotalIPI\n )\n return (\n
    \n {}\n

    \n em{' '}\n {\n store.pagamento.condicoes?.Parcelas[conIndex]\n ?.DescricaoPagamento\n }\n

    \n {store.pagamento.condicoes?.Parcelas[conIndex]?.PercentualJuros !==\n 0 && (\n

    \n Valor com acréscimo:{' '}\n {precoMask(\n store.pagamento.condicoes?.Parcelas[conIndex]?.ValorParcela *\n store.pagamento.condicoes?.Parcelas[conIndex]?.NumeroParcela\n )}\n

    \n )}\n
    \n )\n } else {\n verificarEAtualizarTotalIPI(condicoesCartaoPJ[conIndex]?.ValorTotalIPI)\n return (\n
    \n {' '}\n

    em {condicoesCartaoPJ[conIndex]?.DescricaoPagamento}

    \n {condicoesCartaoPJ[conIndex]?.PercentualJuros !== 0 && (\n

    \n Valor com acréscimo:{' '}\n {precoMask(\n condicoesCartaoPJ[conIndex]?.ValorParcela *\n condicoesCartaoPJ[conIndex]?.NumeroParcela\n )}\n

    \n )}\n
    \n )\n }\n }\n return ''\n }\n const condicoesPix = () => {\n if (store.pagamento.pick.id === 'pix' && condicoes !== undefined) {\n verificarEAtualizarTotalIPI(\n store.pagamento.condicoes?.Parcelas[conIndex]?.ValorTotalIPI\n )\n return (\n
    \n {store.pagamento.condicoes?.Parcelas[conIndex]?.PercentualDesconto ===\n 0 ? (\n

    \n {precoMask(\n store.pagamento.condicoes?.Parcelas[conIndex]?.ValorParcela *\n store.pagamento.condicoes?.Parcelas[conIndex]?.NumeroParcela\n )}\n

    \n ) : (\n <>\n

    \n {\n store.pagamento.condicoes?.Parcelas[conIndex]\n ?.DescricaoPagamento\n }\n

    \n

    \n Valor com desconto:{' '}\n {precoMask(\n store.pagamento.condicoes?.Parcelas[conIndex]?.ValorParcela *\n store.pagamento.condicoes?.Parcelas[conIndex]?.NumeroParcela\n )}\n

    \n \n )}\n
    \n )\n }\n }\n\n let quantidadeTotal = 0\n store.envio.resumo.Carrinho?.forEach((item) => {\n quantidadeTotal += item.Quantidade\n })\n\n const valorProdutosConsolidado = () =>\n store.envio.resumo.ValorProdutos + store.envio.resumo.ValorProdutosSeller\n // + (store.pagamento.pagamento?.DetalheSubstituicaoTributaria?.ValorSt || 0)\n\n // console.log('store: ', store.pagamento)\n\n function valorTotalEnvio() {\n return precoMask(\n valorProdutosConsolidado() +\n sumFrete() +\n (totalIPI || store.envio.resumo?.ValorIpi)\n )\n }\n\n function valorTotalPagamento() {\n return precoMask(\n store.envio.resumo.ValorProdutos +\n store.envio.resumo.ValorProdutosSeller +\n sumFrete() +\n (store.pagamento.pick.id === undefined ? 0 : acrescimo) +\n (totalIPI || store.envio.resumo?.ValorIpi) -\n (store.pagamento.pagamento.Resumo?.ValorGimplus || 0) -\n (store.pagamento.pagamento.Resumo?.ValorCupom || 0) -\n descontoMarketplace\n )\n }\n\n function handleDatalayerEnvio() {\n const ids = new Set()\n\n const sellers = store.envio.resumo.Carrinho?.map((e) => ({\n name: e.NomeSeller,\n id: e.SellerId,\n produtos: e\n })).filter((e) => {\n if (ids.has(e.id)) {\n return false\n }\n ids.add(e.id)\n return true\n })\n\n const carrinhoArray = store.envio.resumo.Carrinho\n const freteSelecionadoArray = store.envio.fretePick\n\n const remessas = sellers.map((seller) => {\n const produtos = carrinhoArray\n .filter((item) => item.NomeSeller === seller.name)\n .map((product) => {\n return product\n })\n\n const totalPorCarrinho = produtos.reduce(\n (acc, current) => acc + current.PrecoVenda * current.Quantidade,\n 0\n )\n\n const freteSelecionado = freteSelecionadoArray[Gimbafy(seller.name)]\n\n return {\n produtos: produtos,\n freteSelecionado: freteSelecionado,\n total: parseFloat(\n (totalPorCarrinho + freteSelecionado.value).toFixed(2)\n )\n }\n })\n\n // console.log(remessas)\n\n remessas.map((remessa) => {\n return window.dataLayer.push({\n event: 'add_shipping_info',\n ecommerce: {\n value: remessa.total,\n shipping_tier:\n remessa.freteSelecionado.NomeMetodoEntrega ||\n remessa.freteSelecionado.name,\n items: remessa.produtos.map((produto) => {\n return {\n item_id: produto.CodigoERP,\n item_name: produto.DescricaoResumida,\n price: produto.PrecoVenda,\n quantity: produto.Quantidade\n }\n })\n }\n })\n })\n }\n\n function handleDatalayerPagamento() {\n const ids = new Set()\n\n const sellers = store.envio.resumo.Carrinho?.map((e) => ({\n name: e.NomeSeller,\n id: e.SellerId\n })).filter((e) => {\n if (ids.has(e.id)) {\n return false\n }\n ids.add(e.id)\n return true\n })\n\n const carrinhoArray = store.envio.resumo.Carrinho\n const freteSelecionadoArray = store.envio.fretePick\n\n function isFaturado() {\n if (\n store.pagamento.condicaoFaturado?.IdTipo === 3 &&\n conIndex > 0 &&\n (!!store.pagamento.pickF.id || !!store.pagamento.pick.id)\n ) {\n return true\n } else {\n return false\n }\n }\n\n const remessas = sellers.map((seller) => {\n const produtos = carrinhoArray\n .filter((item) => item.NomeSeller === seller.name)\n .map((product) => {\n return product\n })\n\n const totalPorCarrinho = produtos.reduce(\n (acc, current) => acc + current.PrecoVenda * current.Quantidade,\n 0\n )\n\n const freteSelecionado = freteSelecionadoArray[Gimbafy(seller.name)]\n const sellerName = seller.name === null ? 'Gimba' : 'Seller'\n\n let pagamentoGimba\n let pagamentoSeller\n\n switch (isFaturado()) {\n case true:\n pagamentoGimba = store.pagamento.condicaoFaturado?.Descricao\n if (store.pagamento.pick.id === 'boleto') {\n pagamentoGimba = store.pagamento.condicaoFaturado?.Descricao\n }\n\n if (store.pagamento.pickF.id === 'boleto') {\n pagamentoSeller = store.pagamento.condicoes?.Descricao\n } else if (store.pagamento.pickF.id === 'pix') {\n pagamentoSeller = 'PIX'\n } else {\n pagamentoSeller = 'Cartão de Crédito'\n }\n break\n case false:\n pagamentoGimba = store.pagamento.condicoes?.Descricao\n pagamentoSeller = store.pagamento.condicoes?.Descricao\n default:\n break\n }\n\n return {\n produtos: produtos,\n seller: {\n name: sellerName,\n pagamento: sellerName === 'Gimba' ? pagamentoGimba : pagamentoSeller\n },\n total: parseFloat(\n (totalPorCarrinho + freteSelecionado.value).toFixed(2)\n )\n }\n })\n\n // console.log(remessas)\n // console.log(store)\n\n remessas.map((remessa) => {\n return window.dataLayer.push({\n event: 'add_payment_info',\n ecommerce: {\n value: remessa.total,\n payment_type: remessa.seller.pagamento,\n items: remessa.produtos.map((produto) => {\n return {\n item_id: produto.CodigoERP,\n item_name: produto.DescricaoResumida,\n price: produto.PrecoVenda,\n quantity: produto.Quantidade\n }\n })\n }\n })\n })\n }\n\n function filterPagamento(condicao) {\n if (condicao.descricao) {\n const idCondicaoCredito =\n store.pagamento.pagamento.Formas[0].Condicoes.filter(\n (item) => item.Descricao === condicao.descricao\n )\n return idCondicaoCredito[0].Id\n } else {\n let condicaoId\n switch (condicao.id) {\n case 'boleto':\n condicaoId = 3\n break\n case 'pix':\n condicaoId = 16\n default:\n break\n }\n return condicaoId\n }\n }\n\n function getCampanha(pagamento) {\n // const carrinhoArray = carrinhoMock\n const carrinhoArray = store.envio.resumo.Carrinho\n\n const pagamentoFiltered = filterPagamento(pagamento)\n\n const selectedCampanha = carrinhoArray\n .map((product) => {\n const campanha = product.Campanhas.filter(\n (campanha) => campanha.IdCondicaoPagamentoGimba === pagamentoFiltered\n )[0]\n\n return campanha !== undefined\n ? { ...campanha, PrecoVenda: product.PrecoVenda }\n : null\n })\n .filter((el) => el)\n\n const descontoTotalCampanha = selectedCampanha.reduce((acc, current) => {\n if (current?.Id)\n return acc + (current?.PrecoVenda - current?.ProdutoPrecoCampanha)\n }, 0)\n\n setDescontoMarketplace(descontoTotalCampanha)\n\n // console.log(carrinhoArray)\n\n // console.log(selectedCampanha)\n // console.log(descontoTotalCampanha)\n }\n\n useEffect(() => {\n if (store.pagamento.pick.id) {\n getCampanha(store.pagamento.pick)\n }\n }, [store.pagamento.pick.id])\n\n return (\n <>\n {load && }\n {!!pagamento && (\n <>\n \n {!!isPF() && (\n \n \n \n )}\n\n \n
    Resumo do pedido
    \n\n \n \n

    Produtos ({quantidadeTotal} itens)

    {' '}\n

    {convertDecimalCurrency(valorProdutosConsolidado())}

    \n
    \n \n {store.envio.resumo.Carrinho &&\n store.envio.resumo.Carrinho.some((item) => item.PossuiIPI) ? (\n <>\n

    \n IPI\n }\n message={\n 'Imposto federal aplicado sobre produtos industrializados. A taxa do IPI varia conforme a categoria do produto e é estabelecida pelo governo'\n }\n />{' '}\n

    \n

    \n {' '}\n {precoMask(\n totalIPI || store.envio.resumo?.ValorIpi\n )}{' '}\n

    \n \n ) : (\n ''\n )}\n
    \n \n

    Frete

    {precoMask(sumFrete())}

    \n
    \n\n {descontoMarketplace > 0 && (\n \n

    Desconto Marketplace

    {' '}\n

    {precoMask(descontoMarketplace)}

    \n
    \n )}\n\n {/* Exibir GIMPLUS apenas caso aplicado */}\n {store.pagamento.pagamento.Resumo?.ValorGimplus === 0 ? null : (\n \n

    \n Gimplus\n }\n message=\"Saldo Gimplus utilizado\"\n />\n

    {' '}\n

    \n {precoMask(\n store.pagamento.pagamento.Resumo?.ValorGimplus,\n true\n )}\n

    \n
    \n )}\n\n {/* Exibir CUPOM apenas caso aplicado */}\n {store.pagamento.pagamento.Resumo?.ValorCupom === 0 ? null : (\n \n

    Cupom

    {' '}\n

    \n {precoMask(\n store.pagamento.pagamento.Resumo?.ValorCupom,\n true\n )}\n

    \n
    \n )}\n {/*aplicar ST cando houver */}\n {acrescimo === 0 || store.pagamento.pick.id === undefined ? (\n ''\n ) : (\n \n

    ICMS-ST

    {precoMask(acrescimo)}

    \n
    \n )}\n
    \n\n \n
    \n

    Total

    {valorTotalPagamento()}

    \n
    \n\n {condicoesBoleto()}\n\n {condicoesCartao()}\n\n {condicoesPix()}\n
    \n
    \n\n {\n checkPagamento()\n // handleDatalayerPagamento()\n }}\n >\n Confirmar Pagamento\n \n\n \n \n Voltar para o carrinho\n \n \n
    \n\n \n \n {\n checkPagamento()\n // handleDatalayerPagamento()\n }}\n >\n Confirmar Pagamento\n \n\n \n
    \n

    Total

    {valorTotalPagamento()}

    \n
    \n

    Frete {precoMask(sumFrete())}

    \n {condicoesBoleto()}\n\n {condicoesCartao()}\n\n {condicoesPix()}\n
    \n
    \n
    \n \n )}\n\n {!!envio && (\n <>\n \n \n
    Resumo do pedido
    \n\n \n \n

    Produtos ({quantidadeTotal} itens)

    {' '}\n

    {precoMask(valorProdutosConsolidado())}

    \n
    \n \n {store.envio.resumo.Carrinho &&\n store.envio.resumo.Carrinho.some((item) => item.PossuiIPI) ? (\n <>\n

    \n IPI\n }\n message={\n 'Imposto federal aplicado sobre produtos industrializados. A taxa do IPI varia conforme a categoria do produto e é estabelecida pelo governo.'\n }\n />{' '}\n

    \n

    {precoMask(store.envio.resumo?.ValorIpi)}

    \n \n ) : (\n ''\n )}\n
    \n \n

    Frete

    {precoMask(sumFrete())}

    \n
    \n
    \n\n \n
    \n

    Total

    {valorTotalEnvio()}

    \n
    \n
    \n
    \n\n {validFrete() && (\n {\n checkFrete()\n // handleDatalayerEnvio()\n }}\n >\n Confirmar Entrega\n \n )}\n\n \n \n Voltar para o carrinho\n \n \n
    \n\n \n \n {/* */}\n {validFrete() ? (\n <>\n {\n checkFrete()\n // handleDatalayerEnvio()\n }}\n >\n Confirmar Entrega\n \n \n
    \n

    Total

    {valorTotalEnvio()}

    \n
    \n

    Frete {precoMask(sumFrete())}

    \n
    \n \n ) : (\n \n \n Voltar para o carrinho\n \n \n )}\n {/* */}\n
    \n
    \n \n )}\n\n {!!confirmacao && (\n <>\n \n
    Resumo do pedido
    \n\n \n \n

    Produtos ({quantidadeTotal} itens)

    {' '}\n

    {precoMask(valorProdutosConsolidado())}

    \n
    \n \n {store.envio.resumo.Carrinho &&\n store.envio.resumo.Carrinho.some((item) => item.PossuiIPI) ? (\n <>\n

    \n IPI\n }\n message={\n 'Imposto federal aplicado sobre produtos industrializados. A taxa do IPI varia conforme a categoria do produto e é estabelecida pelo governo.'\n }\n />{' '}\n

    \n

    \n {' '}\n {precoMask(totalIPI || store.envio.resumo?.ValorIpi)}{' '}\n

    \n \n ) : (\n ''\n )}\n
    \n \n

    Frete

    {precoMask(sumFrete())}

    \n
    \n\n {descontoMarketplace > 0 && (\n \n

    Desconto Marketplace

    {' '}\n

    {precoMask(descontoMarketplace)}

    \n
    \n )}\n\n {store.pagamento.pagamento.Resumo?.ValorGimplus === 0 ? null : (\n \n

    \n Gimplus\n }\n message=\"Saldo Gimplus utilizado\"\n />\n

    {' '}\n

    \n {precoMask(\n store.pagamento.pagamento.Resumo?.ValorGimplus,\n true\n )}\n

    \n
    \n )}\n\n {store.pagamento.pagamento.Resumo?.ValorCupom === 0 ? null : (\n \n

    Cupom

    {' '}\n

    \n {precoMask(\n store.pagamento.pagamento.Resumo?.ValorCupom,\n true\n )}\n

    \n
    \n )}\n\n {acrescimo === 0 ||\n store.pagamento.pick.id === undefined ? null : (\n \n

    ICMS-ST

    {precoMask(acrescimo)}

    \n
    \n )}\n
    \n\n \n
    \n

    Total

    {valorTotalPagamento()}

    \n
    \n\n {condicoesBoleto()}\n\n {condicoesCartao()}\n\n {condicoesPix()}\n
    \n
    \n\n {store.pagamento.pick.id === 'boleto' && }\n\n
    \n Finalizar Pedido\n
    \n \n )}\n \n )\n}\n\nexport default ResumoPedido\n","import styled, { css } from 'styled-components'\r\n\r\nexport const Wrapper = styled.div`\r\n text-align: center;\r\n`\r\n\r\nexport const SteptsList = styled.ul`\r\n counter-reset: steps;\r\n list-style-type: none;\r\n margin-bottom: 50px;\r\n text-align: center;\r\n position: relative;\r\n display: inline-block;\r\n`\r\n\r\nexport const StepsItem = styled.li`\r\n ${({ theme, active }) => css`\r\n counter-increment: steps;\r\n display: inline-block;\r\n color: #afaeae;\r\n text-align: center;\r\n margin: 0 30px;\r\n position: relative;\r\n width: 190px;\r\n vertical-align: top;\r\n\r\n &:before {\r\n content: counter(steps);\r\n background: #fbfbfb;\r\n font-size: 20px;\r\n line-height: 35px;\r\n font-weight: 400;\r\n display: block;\r\n border-radius: 50%;\r\n width: 40px;\r\n height: 40px;\r\n border: 3px solid #afaeae;\r\n margin: 0 auto 10px auto;\r\n }\r\n\r\n &:after {\r\n content: '';\r\n height: 3px;\r\n background: #afaeae;\r\n width: 120%;\r\n position: absolute;\r\n right: -151px;\r\n top: 19px;\r\n z-index: 0;\r\n }\r\n\r\n &:first-child {\r\n &:after {\r\n width: 120%;\r\n }\r\n }\r\n\r\n &:last-child {\r\n &:after {\r\n display: none;\r\n }\r\n }\r\n\r\n ${active &&\r\n css`\r\n color: ${theme.colors.primary};\r\n font-weight: bold;\r\n\r\n &:before {\r\n color: #ffffff;\r\n font-weight: 600;\r\n background: ${theme.colors.primary};\r\n border-color: ${theme.colors.primary};\r\n }\r\n\r\n &:after {\r\n background-color: ${theme.colors.primary};\r\n }\r\n `}\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n width: 150px;\r\n font-size: 14px;\r\n margin: 0 10px;\r\n\r\n &:before {\r\n font-size: 16px;\r\n line-height: 30px;\r\n width: 36px;\r\n height: 36px;\r\n border: 3px solid #afaeae;\r\n }\r\n\r\n &:after {\r\n width: 115%;\r\n }\r\n\r\n ${active &&\r\n css`\r\n color: ${theme.colors.primary};\r\n font-weight: bold;\r\n\r\n &:before {\r\n color: #ffffff;\r\n font-weight: 600;\r\n background: ${theme.colors.primary};\r\n border-color: ${theme.colors.primary};\r\n }\r\n\r\n &:after {\r\n background-color: ${theme.colors.primary};\r\n }\r\n `}\r\n\r\n &:after {\r\n right: -113px;\r\n top: 16px;\r\n }\r\n }\r\n\r\n @media (max-width: 540px) {\r\n width: 60px;\r\n font-size: 12px;\r\n margin: 0 10px;\r\n\r\n &:after {\r\n right: -55px;\r\n top: 15px;\r\n }\r\n }\r\n `}\r\n`\r\n","import * as S from './styles'\r\n\r\n\r\n\r\nconst Steps = ({ steps=[\r\n { stepId: 1, label: 'Meu Carrinho' },\r\n { stepId: 2, label: 'Envio e Pagamento' },\r\n { stepId: 3, label: 'Confirmação' }\r\n], activeStep }) => {\r\n return (\r\n \r\n \r\n {steps.map(({ stepId, label }, index) => (\r\n = stepId}>\r\n {label}\r\n \r\n ))}\r\n \r\n \r\n )\r\n}\r\n\r\nexport default Steps\r\n","import styled, { css, keyframes } from 'styled-components'\r\n\r\nconst showModal = keyframes`\r\n from {\r\n opacity: 0;\r\n } to {\r\n opacity: 1;\r\n }\r\n`\r\n\r\nexport const Background = styled.div`\r\n width: 100%;\r\n height: 100%;\r\n background: rgba(0, 0, 0, 0.7);\r\n transition: background 0.2s;\r\n position: fixed;\r\n display: flex;\r\n justify-content: center;\r\n align-items: center;\r\n z-index: 200;\r\n animation: ${showModal} 200ms;\r\n`\r\n\r\nexport const ModalWrapper = styled.div`\r\n max-width: 500px;\r\n width: 100%;\r\n padding: 32px 32px 8px 32px;\r\n box-shadow: 0 5px 16px rgba(0, 0, 0, 0.2);\r\n background: #fff;\r\n color: #000;\r\n position: relative;\r\n text-align: left;\r\n overflow: auto;\r\n max-height: 95%;\r\n\r\n z-index: 10;\r\n border-radius: 10px;\r\n\r\n @media (max-width: 560px) {\r\n max-width: 90%;\r\n margin: auto;\r\n }\r\n\r\n @media (max-height: 630px) {\r\n max-height: 95%;\r\n overflow-y: auto;\r\n }\r\n`\r\n\r\nexport const ContentWrapper = styled.div`\r\n h3 {\r\n margin-bottom: 16px;\r\n font-weight: 500;\r\n font-size: 24px;\r\n }\r\n\r\n .content {\r\n overflow-y: auto;\r\n height: calc(110px + (600 — 110) * ((70vh — 210px) / (1080 — 110)));\r\n }\r\n\r\n p.title {\r\n margin-bottom: 8px;\r\n font-weight: 600;\r\n }\r\n\r\n @media (max-height: 630px) {\r\n max-height: 95%;\r\n\r\n .content {\r\n overflow-y: scroll;\r\n height: 40vh;\r\n }\r\n }\r\n`\r\n\r\nexport const CardWrapper = styled.div`\r\n ${({ theme }) => css`\r\n width: 100%;\r\n\r\n .col-6 {\r\n width: 100%;\r\n }\r\n `}\r\n`\r\n\r\nexport const ProfileBoxFooter = styled.div`\r\n display: flex;\r\n padding: 0;\r\n align-items: center;\r\n margin-top: 8px;\r\n\r\n @media (max-width: 600px) {\r\n flex-direction: column;\r\n\r\n button,\r\n button.button-outline {\r\n max-width: 100%;\r\n margin-right: 0;\r\n }\r\n }\r\n`\r\n\r\nexport const Button = styled.button`\r\n ${({ theme }) => css`\r\n max-width: 170px;\r\n margin-right: 12px;\r\n\r\n border-radius: 5px;\r\n border: 2px solid transparent;\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 500;\r\n font-size: 16px;\r\n padding: 12px 30px;\r\n margin-bottom: 10px;\r\n width: 100%;\r\n text-align: center;\r\n transition: ${theme.transition.default};\r\n cursor: pointer;\r\n background: ${theme.colors.primary};\r\n color: ${theme.colors.white};\r\n\r\n &:hover {\r\n background: #a71e26;\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: $MEDIA-IPAD) {\r\n font-size: 14px;\r\n }\r\n\r\n &.button-outline {\r\n max-width: 146px;\r\n background: transparent;\r\n border: 2px solid #8f8f8f;\r\n color: #8f8f8f;\r\n\r\n &:hover {\r\n border-color: #4a4a4a;\r\n color: #4a4a4a;\r\n }\r\n\r\n &:disabled {\r\n color: #7b7b7b;\r\n border-color: #7b7b7b;\r\n cursor: initial;\r\n }\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n & + .button {\r\n margin-left: 0;\r\n margin-top: 8px;\r\n }\r\n }\r\n `}\r\n`\r\n\r\nexport const HeaderModalClose = styled.button`\r\n background: none;\r\n border: 0;\r\n position: absolute;\r\n top: 30px;\r\n right: 40px;\r\n transition: all 400ms;\r\n cursor: pointer;\r\n\r\n img {\r\n width: 18px;\r\n }\r\n\r\n &:hover {\r\n opacity: 0.6;\r\n }\r\n`\r\n","import styled, { css } from 'styled-components'\r\nimport IconAlertInfo from '../../assets/icons/icon-alert-info.svg'\r\nimport IconInputError from '../../assets/icons/icon-input-error.svg'\r\nimport IconInputSuccess from '../../assets/icons/icon-input-success.svg'\r\nimport IconVisa from '../../assets/img/pagamento/cartao-visa.svg'\r\nimport IconAmex from '../../assets/img/pagamento/cartao-amex.svg'\r\nimport IconMaster from '../../assets/img/pagamento/cartao-mastercard.svg'\r\nimport IconDiners from '../../assets/img/pagamento/cartao-diners.svg'\r\nimport IconElo from '../../assets/img/pagamento/cartao-elo.svg'\r\nimport IconCartao from '../../assets/img/pagamento/cartao-default.svg'\r\n\r\nexport const Register = styled.section`\r\n background: #fff;\r\n`\r\nexport const ProfileTitle = styled.h2`\r\n font-size: 22px;\r\n margin-bottom: 20px;\r\n color: #555;\r\n`\r\n\r\nexport const WrapperSmall = styled.div`\r\n max-width: 600px;\r\n width: 100%;\r\n /* padding: 100px 0; */\r\n /* margin: auto; */\r\n\r\n @media (max-width: 1170px) {\r\n /* max-width: 95%; */\r\n }\r\n`\r\n\r\nexport const RegisterCard = styled.div`\r\n p {\r\n margin-bottom: 20px;\r\n margin-top: 0;\r\n }\r\n\r\n label {\r\n font-weight: 500;\r\n\r\n @media (max-width: 600px) {\r\n font-size: 14px;\r\n }\r\n }\r\n\r\n small {\r\n margin-bottom: 5px;\r\n font-size: 13px;\r\n line-height: 22px;\r\n }\r\n\r\n h3 {\r\n font-size: 26px;\r\n font-weight: 500;\r\n margin-bottom: 16px;\r\n }\r\n\r\n form div {\r\n /* margin-bottom: 16px; */\r\n }\r\n\r\n [type='checkbox']:not(:checked) + label::after,\r\n [type='checkbox']:checked + label::after {\r\n left: 7px;\r\n }\r\n\r\n @media (max-width: 600px) {\r\n min-width: 100%;\r\n /* padding: 32px 20px 12px 20px; */\r\n }\r\n\r\n .inline {\r\n display: flex;\r\n\r\n svg {\r\n width: 60px;\r\n height: 60px;\r\n margin: -10px -10px -28px 0;\r\n }\r\n }\r\n\r\n .form-group {\r\n div {\r\n margin-bottom: 2px;\r\n }\r\n }\r\n\r\n .card-number {\r\n background-color: violet;\r\n display: flex;\r\n\r\n div > div {\r\n margin-bottom: 0;\r\n }\r\n\r\n input {\r\n width: 100%;\r\n max-width: 500px;\r\n }\r\n }\r\n\r\n .cvv {\r\n display: flex;\r\n align-items: center;\r\n\r\n i {\r\n top: 0;\r\n right: -6px;\r\n }\r\n }\r\n\r\n .tooltip {\r\n position: relative;\r\n margin-left: -16px;\r\n }\r\n\r\n .card-info {\r\n display: flex;\r\n align-items: baseline;\r\n /* margin-bottom: 16px; */\r\n\r\n input,\r\n select {\r\n width: 100px;\r\n margin-right: 16px;\r\n }\r\n }\r\n\r\n .save-card {\r\n max-height: 70px;\r\n margin-bottom: 16px;\r\n }\r\n`\r\n\r\nexport const Title = styled.h2`\r\n font-weight: 500;\r\n color: #333;\r\n margin-bottom: 12px;\r\n text-align: left;\r\n background-color: blue;\r\n font-size: 34px;\r\n\r\n @media (max-width: 1170px) {\r\n font-size: 18px;\r\n text-align: left;\r\n }\r\n`\r\n\r\nexport const CardImage = styled.div`\r\n ${({ cartao }) => css`\r\n background-repeat: no-repeat;\r\n background-size: cover;\r\n background-position: center;\r\n background-size: contain;\r\n display: flex;\r\n width: 81px;\r\n margin-left: 8px;\r\n margin-bottom: 0px !important;\r\n\r\n ${cartao === undefined || cartao === null\r\n ? css`\r\n background-image: url(${IconCartao});\r\n `\r\n : null}\r\n\r\n ${cartao === 'amex' &&\r\n css`\r\n background-image: url(${IconAmex});\r\n `}\r\n\r\n ${cartao === 'mastercard' &&\r\n css`\r\n background-image: url(${IconMaster});\r\n `}\r\n\r\n ${cartao === 'visa' &&\r\n css`\r\n background-image: url(${IconVisa});\r\n `}\r\n\r\n ${cartao === 'elo' &&\r\n css`\r\n background-image: url(${IconElo});\r\n `}\r\n\r\n ${cartao === 'diners' &&\r\n css`\r\n background-image: url(${IconDiners});\r\n `}\r\n `}\r\n`\r\n\r\nexport const Input = styled.input`\r\n ${({ theme }) => css`\r\n border: 1px solid #afaeae;\r\n border-radius: 6px;\r\n padding: 15px 15px;\r\n width: 100%;\r\n transition: all 400ms;\r\n\r\n &::placeholder {\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 400;\r\n color: #afaeae;\r\n }\r\n\r\n &:focus {\r\n border-color: ${theme.colors.primary};\r\n }\r\n\r\n // Feedbacks.\r\n &.input-success {\r\n background: ${theme.colors.backgroundSuccess} url(${IconInputSuccess})\r\n right 10px center no-repeat !important;\r\n border-color: ${theme.colors.success};\r\n }\r\n\r\n &.input-error {\r\n background: ${theme.colors.backgroundError} url(${IconInputError}) right\r\n 10px center no-repeat !important;\r\n border-color: ${theme.colors.error};\r\n }\r\n `}\r\n`\r\n\r\nexport const ProfileBoxFooter = styled.div`\r\n display: flex;\r\n padding: 0;\r\n align-items: center;\r\n\r\n @media (max-width: 600px) {\r\n flex-direction: column;\r\n\r\n button,\r\n button.button-outline {\r\n max-width: 100%;\r\n margin-right: 0;\r\n }\r\n }\r\n`\r\n\r\nexport const Button = styled.button`\r\n ${({ theme }) => css`\r\n max-width: 170px;\r\n margin-right: 12px;\r\n\r\n border-radius: 5px;\r\n border: 2px solid transparent;\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 500;\r\n font-size: 16px;\r\n padding: 12px 30px;\r\n margin-bottom: 10px;\r\n width: 100%;\r\n text-align: center;\r\n transition: ${theme.transition.default};\r\n cursor: pointer;\r\n background: ${theme.colors.primary};\r\n color: ${theme.colors.white};\r\n\r\n &:hover {\r\n background: #a71e26;\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: $MEDIA-IPAD) {\r\n font-size: 14px;\r\n }\r\n\r\n &.button-outline {\r\n max-width: 146px;\r\n background: transparent;\r\n border: 2px solid #8f8f8f;\r\n color: #8f8f8f;\r\n\r\n &:hover {\r\n border-color: #4a4a4a;\r\n color: #4a4a4a;\r\n }\r\n\r\n &:disabled {\r\n color: #7b7b7b;\r\n border-color: #7b7b7b;\r\n cursor: initial;\r\n }\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n & + .button {\r\n margin-left: 0;\r\n margin-top: 8px;\r\n }\r\n }\r\n `}\r\n`\r\nexport const CaptchaContainer = styled.div`\r\n margin-bottom: 16px;\r\n`\r\n\r\n","const acceptedCreditCards = {\r\n visa: /^4[0-9]{12}(?:[0-9]{3})?$/,\r\n mastercard:\r\n /^5[1-5]\\d{2}-?\\d{4}-?\\d{4}-?\\d{4}$|^2(?:2(?:2[1-9]|[3-9]\\d)|[3-6]\\d\\d|7(?:[01]\\d|20))-?\\d{4}-?\\d{4}-?\\d{4}$/,\r\n amex: /^3[47][0-9]{13}$/,\r\n discover:\r\n /^65[4-9][0-9]{13}|64[4-9][0-9]{13}|6011[0-9]{12}|(622(?:12[6-9]|1[3-9][0-9]|[2-8][0-9][0-9]|9[01][0-9]|92[0-5])[0-9]{10})$/,\r\n diners_club: /^3(?:0[0-5]|[68][0-9])[0-9]{11}$/,\r\n jcb: /^(?:2131|1800|35[0-9]{3})[0-9]{11}$/,\r\n //elo: /^(40117[8-9]|431274|438935|451416|457393|45763[1-2]|506(699|7[0-6][0-9]|77[0-8])|509\\d{3}|504175|627780|636297|636368|65003[1-3]|6500(3[5-9]|4[0-9]|5[0-1])|6504(0[5-9]|[1-3][0-9])|650(4[8-9][0-9]|5[0-2][0-9]|53[0-8])|6505(4[1-9]|[5-8][0-9]|9[0-8])|6507(0[0-9]|1[0-8])|65072[0-7]|6509(0[1-9]|1[0-9]|20)|6516(5[2-9]|[6-7][0-9])|6550([0-1][0-9]|2[1-9]|[3-4][0-9]|5[0-8]))/\r\n elo: /^4011(78|79)|^43(1274|8935)|^45(1416|7393|763(1|2))|^50(4175|6699|67[0-6][0-9]|677[0-8]|9[0-8][0-9]{2}|99[0-8][0-9]|999[0-9])|^627780|^63(6297|6368|6369)|^65(0(0(3([1-3]|[5-9])|4([0-9])|5[0-1])|4(0[5-9]|[1-3][0-9]|8[5-9]|9[0-9])|5([0-2][0-9]|3[0-8]|4[1-9]|[5-8][0-9]|9[0-8])|7(0[0-9]|1[0-8]|2[0-7])|9(0[1-9]|[1-6][0-9]|7[0-8]))|16(5[2-9]|[6-7][0-9])|50(0[0-9]|1[0-9]|2[1-9]|[3-4][0-9]|5[0-8]))/\r\n}\r\n\r\nconst cardFlagPrediction = {\r\n visa: /^4[0-9]*$/,\r\n mastercard: /^5[1-5]\\d{2}-?\\d{4}-?\\d{4}-?\\d{4}$|^2(?:2(?:2[1-9]|[3-9]\\d)|[3-6]\\d\\d|7(?:[01]\\d|20))-?\\d{4}-?\\d{4}-?\\d{4}$/,\r\n amex: /^3[47][0-9]*$/,\r\n diners: /^3(?:0[0-5]|[68][0-9])[0-9]*/,\r\n //elo: /^(40117[8-9]|431274|438935|451416|457393|45763[1-2]|506(699|7[0-6][0-9]|77[0-8])|509\\d{3}|504175|627780|636297|636368|65003[1-3]|6500(3[5-9]|4[0-9]|5[0-1])|6504(0[5-9]|[1-3][0-9])|650(4[8-9][0-9]|5[0-2][0-9]|53[0-8])|6505(4[1-9]|[5-8][0-9]|9[0-8])|6507(0[0-9]|1[0-8])|65072[0-7]|6509(0[1-9]|1[0-9]|20)|6516(5[2-9]|[6-7][0-9])|6550([0-1][0-9]|2[1-9]|[3-4][0-9]|5[0-8]))/\r\n elo: /^4011(78|79)|^43(1274|8935)|^45(1416|7393|763(1|2))|^50(4175|6699|67[0-6][0-9]|677[0-8]|9[0-8][0-9]{2}|99[0-8][0-9]|999[0-9])|^627780|^63(6297|6368|6369)|^65(0(0(3([1-3]|[5-9])|4([0-9])|5[0-1])|4(0[5-9]|[1-3][0-9]|8[5-9]|9[0-9])|5([0-2][0-9]|3[0-8]|4[1-9]|[5-8][0-9]|9[0-8])|7(0[0-9]|1[0-8]|2[0-7])|9(0[1-9]|[1-6][0-9]|7[0-8]))|16(5[2-9]|[6-7][0-9])|50(0[0-9]|1[0-9]|2[1-9]|[3-4][0-9]|5[0-8]))/\r\n}\r\n\r\nexport const validateCard = (cardNumber) => {\r\n if (/[^0-9-\\s]+/.test(cardNumber)) return false\r\n\r\n // Algorítmo de Luhn com a lógica de numeração de cartões\r\n let nCheck = 0,\r\n bEven = false\r\n cardNumber = cardNumber.replace(/\\D/g, '')\r\n\r\n for (let n = cardNumber.length - 1; n >= 0; n--) {\r\n let cDigit = cardNumber.charAt(n),\r\n nDigit = parseInt(cDigit, 10)\r\n\r\n if (bEven && (nDigit *= 2) > 9) nDigit -= 9\r\n\r\n nCheck += nDigit\r\n bEven = !bEven\r\n }\r\n\r\n let valid = nCheck % 10 == 0\r\n let accepted = false\r\n\r\n Object.keys(acceptedCreditCards).forEach((key) => {\r\n var regex = acceptedCreditCards[key]\r\n if (regex.test(cardNumber)) {\r\n accepted = true\r\n }\r\n })\r\n return valid && accepted\r\n}\r\n\r\nexport const getCardFlag = (cardNumber) => {\r\n cardNumber = cardNumber.replace(/[^0-9]+/g, '')\r\n let flag\r\n\r\n Object.keys(cardFlagPrediction).forEach((key) => {\r\n var regex = cardFlagPrediction[key]\r\n if (regex.test(cardNumber)) {\r\n flag = key\r\n }\r\n })\r\n return flag\r\n}\r\n\r\nexport const formatCardNumber = (cardNumber) => {\r\n let value = cardNumber.replace(/\\D/g, '')\r\n let formattedValue\r\n\r\n // CC American Express - 15 digits\r\n if (/^3[47]\\d{0,13}$/.test(value)) {\r\n formattedValue = value\r\n .replace(/\\D/g, '')\r\n .replace(/^(\\d{4})(\\d)/g, '$1 $2')\r\n .replace(/^(\\d{4})\\s(\\d{6})(\\d)/g, '$1 $2 $3')\r\n .replace(/^(\\d{4})\\s(\\d{6})\\s(\\d{5})(\\d)/g, '$1 $2 $3')\r\n } else if (/^3(?:0[0-5]|[68]\\d)\\d{0,11}$/.test(value)) {\r\n // CC Diner's club - 14 digitos\r\n formattedValue = value\r\n .replace(/\\D/g, '')\r\n .replace(/^(\\d{4})(\\d)/g, '$1 $2')\r\n .replace(/^(\\d{4})\\s(\\d{6})(\\d)/g, '$1 $2 $3')\r\n .replace(/^(\\d{4})\\s(\\d{6})\\s(\\d{4})(\\d)/g, '$1 $2 $3')\r\n } else if (/^\\d{0,16}$/.test(value)) {\r\n // CC padrão - 16 dígitos\r\n formattedValue = value\r\n .replace(/\\D/g, '')\r\n .replace(/^(\\d{4})(\\d)/g, '$1 $2')\r\n .replace(/^(\\d{4})\\s(\\d{4})(\\d)/g, '$1 $2 $3')\r\n .replace(/^(\\d{4})\\s(\\d{4})\\s(\\d{4})(\\d)/g, '$1 $2 $3 $4')\r\n }\r\n return formattedValue\r\n}\r\n\r\nexport const validateCVV = (cvv, cardFlag) => {\r\n cvv.replace(/\\D/g, '')\r\n\r\n if (cardFlag === undefined) {\r\n return false\r\n } else if (cardFlag !== undefined && /^\\d{3}$/.test(cvv)) {\r\n return true\r\n } else if (\r\n cardFlag === 'amex' ||\r\n (cardFlag === 'Amex' && /^\\d{4}$/.test(cvv))\r\n ) {\r\n return true\r\n }\r\n}\r\n","import pagamento from '../../api/pagamento'\r\nimport { getFormas } from '../../pages/Pagamento/fetch'\r\n\r\nexport const adicionarCartao = async (\r\n body,\r\n idEndereço,\r\n fretePick,\r\n sav,\r\n setLoad,\r\n store\r\n) => {\r\n let newBody = {\r\n NomeTitular: body.cardName,\r\n NumeroCartao: body.cardNumber,\r\n CodigoSeguranca: body.cardCvv,\r\n ValidadeMes: +body.cardMonth,\r\n ValidadeAno: +body.cardYear,\r\n Temporario: body.temporario,\r\n Bandeira: body.bandeira,\r\n TokenCaptcha: body.tokenCaptcha\r\n }\r\n\r\n setLoad(true)\r\n let res = await pagamento.addCartao(newBody)\r\n await getFormas(idEndereço, fretePick, sav, () => undefined, store)\r\n setLoad(false)\r\n return res\r\n}\r\n","const anoAtual = new Date().getFullYear()\r\nconst mesAtual = new Date().getMonth() + 1\r\n\r\nexport const monthsList = (cardYear) => {\r\n const mesesArray = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12]\r\n let newMonthArray = mesesArray.filter((month) => month >= mesAtual)\r\n let finalMonthArray\r\n\r\n const minDigit = (number) => {\r\n return (number < 10 ? '0' : '') + number\r\n }\r\n\r\n if (cardYear == anoAtual) {\r\n finalMonthArray = newMonthArray.map((item) => {\r\n return { label: `${minDigit(item)}`, value: `${item}` }\r\n })\r\n } else {\r\n finalMonthArray = mesesArray.map((item) => {\r\n return { label: `${minDigit(item)}`, value: `${item}` }\r\n })\r\n }\r\n\r\n finalMonthArray.splice(0, 0, {\r\n label: 'Mês',\r\n value: '',\r\n hidden: true,\r\n disabled: true\r\n })\r\n\r\n return finalMonthArray\r\n}\r\n\r\nexport const yearsList = (range) => {\r\n let arr = []\r\n for (let i = anoAtual; i <= anoAtual + range; i++) arr.push(i)\r\n\r\n let newArray = arr.map((item) => {\r\n return { label: `${item}`, value: `${item}` }\r\n })\r\n\r\n newArray.splice(0, 0, {\r\n label: 'Ano',\r\n value: '',\r\n hidden: true,\r\n disabled: true\r\n })\r\n\r\n return newArray\r\n}\r\n","import { useState } from 'react'\r\nimport { useToast } from '../../hooks/toast'\r\nimport defaultOptions from '../../api/defaultoption'\r\nimport * as Yup from 'yup'\r\n\r\nimport TextField from '../TextField'\r\nimport Loader from '../Loader'\r\nimport { FormGroup } from '../Form/styles'\r\nimport * as S from './styles'\r\nimport { HiCreditCard } from 'react-icons/hi'\r\nimport Select from '../Select'\r\nimport {\r\n formatCardNumber,\r\n getCardFlag,\r\n validateCard,\r\n validateCVV\r\n} from '../../utils/creditCardValidation'\r\nimport IconVisa from '../../assets/img/pagamento/cartao-visa.svg'\r\nimport IconCartao from '../../assets/img/pagamento/cartao-default.svg'\r\n\r\nimport { adicionarCartao } from './fetch'\r\nimport { useDispatch, useSelector } from 'react-redux'\r\nimport { setPick, setPagamento } from '../../store/ducks/pagamento'\r\nimport { capitalizeWord, onlyNumber } from '../../utils/utils'\r\nimport { months, monthsList, yearsList } from './cardDate'\r\nimport ReCAPTCHA from 'react-google-recaptcha'\r\n\r\nconst FormAddNewCreditCard = ({ type, cancelar, setPaymentModal }) => {\r\n const dispatch = useDispatch()\r\n const store = useSelector((store) => store)\r\n const { addToast } = useToast()\r\n\r\n const [saveCard, setSaveCard] = useState(false)\r\n const [values, setValues] = useState({\r\n cardNumber: '',\r\n cardName: '',\r\n cardMonth: '',\r\n cardYear: '',\r\n cardCvv: '',\r\n temporario: true,\r\n tokenCaptcha: ''\r\n })\r\n\r\n const [load, setLoad] = useState(false)\r\n const [inputErrors, setInputErrors] = useState(false)\r\n const [isCardNumberValid, setIsCardNumberValid] = useState(true)\r\n const [isCVVNumberValid, setIsCVVNumberValid] = useState(true)\r\n const [cardFlag, setCardFlag] = useState(null)\r\n\r\n const [captcha, setCaptcha] = useState({\r\n value: '',\r\n expired: false\r\n })\r\n\r\n const onCaptchaChange = (value) => {\r\n // console.log('Captcha:', value)\r\n\r\n if (value === null) {\r\n setCaptcha({\r\n value: value,\r\n expired: true\r\n })\r\n } else {\r\n setCaptcha({ value: value, expired: false })\r\n setValues({\r\n ...values,\r\n tokenCaptcha: value\r\n })\r\n }\r\n }\r\n\r\n const onBlurCardNumberChange = () => {\r\n //Validação e Mensagem de erro ao sair input\r\n if (values.cardNumber.length > 0)\r\n validateCard(values.cardNumber)\r\n ? setIsCardNumberValid(true)\r\n : setIsCardNumberValid(false)\r\n }\r\n\r\n const maxLengthCardNumber = () => {\r\n if (cardFlag === 'amex') return 17\r\n else if (cardFlag === 'diners_club') return 16\r\n else return 19\r\n }\r\n\r\n const handleNameChange = (e) => {\r\n const { name, value } = e.target\r\n setValues({\r\n ...values,\r\n [name]: value.replace(/[^a-zA-Z\\s]/g, '') // apenas letras\r\n // [name]: value.replace(/[^a-zA-ZÀ-ú]/g, '') permitindo acentos\r\n })\r\n\r\n setInputErrors({\r\n ...inputErrors,\r\n [name]: ''\r\n })\r\n }\r\n\r\n const handleNumberChange = (e) => {\r\n const { name, value } = e.target\r\n setValues({\r\n ...values,\r\n [name]: formatCardNumber(value.replace(/\\s+/g, ''))\r\n })\r\n\r\n //Validação e Mensagem de erro ao digitar\r\n // if (values.cardNumber.length > 14)\r\n // validateCard(value)\r\n // ? setIsCardNumberValid(true)\r\n // : setIsCardNumberValid(false)\r\n\r\n setCardFlag(getCardFlag(value))\r\n\r\n setInputErrors({\r\n ...inputErrors,\r\n [name]: ''\r\n })\r\n }\r\n\r\n const handleSaveCard = () => {\r\n setValues({\r\n ...values,\r\n temporario: !values.temporario\r\n })\r\n }\r\n\r\n const handleCVVChange = (e) => {\r\n const { name, value } = e.target\r\n setValues({\r\n ...values,\r\n [name]: onlyNumber(value)\r\n })\r\n\r\n if (values.cardCvv.length > 0) {\r\n validateCVV(value, cardFlag)\r\n ? setIsCVVNumberValid(true)\r\n : setIsCVVNumberValid(false)\r\n }\r\n\r\n setInputErrors({\r\n ...inputErrors,\r\n [name]: ''\r\n })\r\n }\r\n\r\n const setDispatch = async () => {\r\n let response = await adicionarCartao(\r\n { ...values, bandeira: capitalizeWord(cardFlag) },\r\n store.endereco.padrao.id,\r\n store.envio.fretePick,\r\n (res) => dispatch(setPagamento(res)),\r\n setLoad,\r\n store\r\n )\r\n\r\n if (response.status >= 200 && response.status < 300) {\r\n dispatch(setPick({ ...values, bandeira: capitalizeWord(cardFlag) }))\r\n addToast({\r\n title: 'Cartão adicionado corretamente',\r\n type: 'success'\r\n })\r\n return cancelar()\r\n } else {\r\n addToast({\r\n title: 'Problema ao adicionar o cartão',\r\n type: 'error',\r\n description: `${response.data}`\r\n })\r\n }\r\n\r\n // console.log('VALUES:', { ...values, bandeira: capitalizeWord(cardFlag) })\r\n }\r\n\r\n Yup.addMethod(Yup.string, 'creditCardFlag', function (errorMessage) {\r\n return this.test(`card-flag`, errorMessage, function () {\r\n const { path, createError } = this\r\n\r\n return (\r\n cardFlag !== undefined || createError({ path, message: errorMessage })\r\n )\r\n })\r\n })\r\n\r\n Yup.addMethod(Yup.string, 'creditCardNumber', function (errorMessage) {\r\n return this.test(`card-number`, errorMessage, function () {\r\n const { path, createError } = this\r\n\r\n return (\r\n isCardNumberValid === true ||\r\n createError({ path, message: errorMessage })\r\n )\r\n })\r\n })\r\n\r\n Yup.addMethod(Yup.string, 'creditCardCVV', function (errorMessage) {\r\n return this.test(`card-cvv`, errorMessage, function () {\r\n const { path, createError } = this\r\n\r\n return (\r\n isCVVNumberValid === true ||\r\n createError({ path, message: errorMessage })\r\n )\r\n })\r\n })\r\n\r\n const formData = {\r\n cardNumber: values.cardNumber,\r\n cardName: values.cardName,\r\n cardMonth: values.cardMonth,\r\n cardYear: values.cardYear,\r\n cardCvv: values.cardCvv,\r\n temporario: values.temporario,\r\n tokenCaptcha: captcha.value\r\n }\r\n\r\n const passSchema = Yup.object().shape({\r\n cardNumber: Yup.string()\r\n .creditCardNumber('Número Inválido')\r\n .creditCardFlag('Bandeira não suportada')\r\n .required('Campo obrigatório*'),\r\n cardName: Yup.string().required('Campo obrigatório*'),\r\n cardMonth: Yup.string().required('Campo obrigatório*'),\r\n cardYear: Yup.string().required('Campo obrigatório*'),\r\n cardCvv: Yup.string()\r\n .creditCardCVV('CVV Inválido')\r\n .required('Campo obrigatório*'),\r\n temporario: Yup.boolean()\r\n })\r\n\r\n const handleSubmit = async (event) => {\r\n event.preventDefault()\r\n // setLoad(true)\r\n\r\n try {\r\n await passSchema.validate(formData, {\r\n abortEarly: false\r\n })\r\n\r\n if (captcha.value === '') {\r\n addToast({\r\n type: 'error',\r\n title: 'Por favor, complete a verificação \"Não sou um Robô\"'\r\n })\r\n setLoad(false)\r\n } else if (captcha.expired === true) {\r\n addToast({\r\n type: 'error',\r\n title:\r\n 'Verificação expirada. Por favor, marque novamente a caixa de seleção'\r\n })\r\n setLoad(false)\r\n } else if (!!isCVVNumberValid && !!isCardNumberValid) {\r\n setDispatch()\r\n }\r\n } catch (err) {\r\n if (err) {\r\n setLoad(false)\r\n // console.log(err)\r\n\r\n // addToast({\r\n // title: 'Problema ao adicionar o cartão. Tente novamente',\r\n // type: 'error'\r\n // })\r\n }\r\n\r\n if (err instanceof Yup.ValidationError) {\r\n const emptyField = Object.values(err.value).every(\r\n (value) => value !== ''\r\n )\r\n\r\n if (!emptyField) {\r\n addToast({\r\n type: 'error',\r\n title: 'Todos os campos devem ser preenchidos'\r\n })\r\n\r\n const errorArray = err.inner.map(({ path, message }) => {\r\n return {\r\n name: path,\r\n message: message\r\n }\r\n })\r\n\r\n const objeto = errorArray.reduce((acc, d) => {\r\n acc[d.name] = d.message\r\n\r\n return acc\r\n }, {})\r\n\r\n setInputErrors(objeto)\r\n } else {\r\n setLoad(false)\r\n err.inner.map((error) => {\r\n addToast({\r\n type: 'error',\r\n title: `${error.message}`\r\n })\r\n })\r\n }\r\n }\r\n }\r\n }\r\n\r\n return (\r\n \r\n \r\n

    Cartão de Crédito

    \r\n\r\n {!!load && }\r\n\r\n
    \r\n \r\n \r\n\r\n handleNumberChange(e)}\r\n error={\r\n !isCardNumberValid ? 'Número inválido' : inputErrors.cardNumber\r\n }\r\n image={}\r\n maxlength={maxLengthCardNumber()}\r\n autoFocus\r\n />\r\n \r\n\r\n \r\n \r\n\r\n \r\n \r\n\r\n
    \r\n \r\n \r\n\r\n
    \r\n {\r\n setValues({\r\n ...values,\r\n cardMonth: e\r\n })\r\n\r\n setInputErrors({\r\n ...inputErrors,\r\n cardMonth: ''\r\n })\r\n }}\r\n options={monthsList(values.cardYear)}\r\n >\r\n {\r\n setValues({\r\n ...values,\r\n cardYear: e\r\n })\r\n\r\n setInputErrors({\r\n ...inputErrors,\r\n cardYear: ''\r\n })\r\n }}\r\n options={yearsList(10)}\r\n >\r\n
    \r\n
    \r\n\r\n \r\n \r\n\r\n
    \r\n \r\n
    \r\n
    \r\n
    \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {}}>\r\n Confirmar\r\n \r\n {\r\n type === 'insideModal' ? setPaymentModal(0) : cancelar()\r\n }}\r\n >\r\n Cancelar\r\n \r\n \r\n \r\n
    \r\n
    \r\n )\r\n}\r\n\r\nexport default FormAddNewCreditCard\r\n","import { useRef, useState, useEffect } from 'react'\r\nimport * as S from './styles'\r\nimport IconClose from '../../assets/icons/icon-close.svg'\r\nimport NewCard from '../PaymentCards/NewCard'\r\nimport CreditCard from '../PaymentCards/CreditCard'\r\nimport BoletoCard from '../PaymentCards/BoletoCard'\r\nimport FormAddNewCreditCard from '../FormAddNewCreditCard'\r\nimport { useDispatch, useSelector } from 'react-redux'\r\nimport {\r\n setCondicaoIndex,\r\n setCondicoes,\r\n setPick\r\n} from '../../store/ducks/pagamento'\r\n\r\nconst PaymentCardsModal = ({ showModal, setShowModal, cardData, formas }) => {\r\n const modalRef = useRef()\r\n const store = useSelector((store) => store)\r\n const dispatch = useDispatch()\r\n\r\n const [paymentModal, setPaymentModal] = useState(0)\r\n const [selectedParcela, setSelectedParcela] = useState('')\r\n const [selectedPaymentMethod, setSelectedPaymentMethod] = useState('')\r\n const [selectedCondicoes, setSelectedCondicoes] = useState('')\r\n\r\n const closeModal = (e) => {\r\n if (modalRef.current === e.target) {\r\n setShowModal(false)\r\n }\r\n }\r\n\r\n useEffect(() => {\r\n let cond\r\n if (!!formas && selectedPaymentMethod.id !== 'boleto') {\r\n cond = formas[0].Condicoes.filter(\r\n (e) => e.Descricao === selectedPaymentMethod.descricao\r\n )[0]\r\n }\r\n\r\n if (!!formas && selectedPaymentMethod.id === 'boleto') {\r\n cond = formas[1].Condicoes[0]\r\n }\r\n\r\n setSelectedCondicoes(cond)\r\n setSelectedParcela(0)\r\n // eslint-disable-next-line react-hooks/exhaustive-deps\r\n }, [selectedPaymentMethod])\r\n\r\n return (\r\n <>\r\n {showModal ? (\r\n \r\n \r\n {/* setShowModal((prev) => !prev)}\r\n /> */}\r\n\r\n {paymentModal === 0 && (\r\n \r\n

    Forma de Pagamento

    \r\n
    \r\n {cardData.map((card) => {\r\n return (\r\n \r\n \r\n \r\n )\r\n })}\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n
    \r\n\r\n \r\n {\r\n dispatch(setPick(selectedPaymentMethod))\r\n dispatch(setCondicoes(selectedCondicoes))\r\n dispatch(setCondicaoIndex(selectedParcela))\r\n setShowModal((prev) => !prev)\r\n }}\r\n >\r\n Confirmar\r\n \r\n setShowModal((prev) => !prev)}\r\n >\r\n Cancelar\r\n \r\n \r\n
    \r\n )}\r\n\r\n {paymentModal === 1 && (\r\n \r\n \r\n \r\n )}\r\n\r\n {\r\n setShowModal((prev) => !prev)\r\n setPaymentModal(0)\r\n }}\r\n >\r\n {/* */}\r\n \"\"\r\n \r\n
    \r\n
    \r\n ) : null}\r\n \r\n )\r\n}\r\n\r\nexport default PaymentCardsModal\r\n","import styled, { keyframes } from 'styled-components'\r\n\r\nconst showModal = keyframes`\r\n from {\r\n opacity: 0;\r\n } to {\r\n opacity: 1;\r\n }\r\n`\r\n\r\nexport const Background = styled.div`\r\n width: 100%;\r\n height: 100%;\r\n background: rgba(0, 0, 0, 0.7);\r\n transition: background 0.2s;\r\n position: fixed;\r\n display: flex;\r\n justify-content: center;\r\n align-items: center;\r\n z-index: 300;\r\n animation: ${showModal} 200ms;\r\n`\r\n\r\nexport const ModalWrapper = styled.div`\r\n max-width: 500px;\r\n width: 100%;\r\n box-shadow: 0 5px 16px rgba(0, 0, 0, 0.2);\r\n background: #fff;\r\n color: #000;\r\n position: relative;\r\n text-align: left;\r\n z-index: 10;\r\n border-radius: 10px;\r\n\r\n @media (max-width: 560px) {\r\n max-width: 90%;\r\n margin: auto;\r\n }\r\n\r\n @media (max-height: 550px) {\r\n max-height: 95%;\r\n overflow-y: scroll;\r\n padding: 0;\r\n }\r\n`\r\n\r\nexport const ModalContent = styled.div`\r\n background: #fff;\r\n padding: 32px 32px 12px 32px;\r\n border: 1px solid #eeeeee;\r\n border-radius: 10px;\r\n -webkit-box-shadow: 4px 3px 7px 2px rgba(0, 0, 0, 0.05);\r\n box-shadow: 4px 3px 7px 2px rgba(0, 0, 0, 0.05);\r\n\r\n @media (max-width: 600px) {\r\n padding: 16px;\r\n }\r\n`\r\n\r\nexport const HeaderModalClose = styled.button`\r\n background: none;\r\n border: 0;\r\n position: absolute;\r\n top: 30px;\r\n right: 40px;\r\n transition: all 400ms;\r\n cursor: pointer;\r\n\r\n &:hover {\r\n opacity: 0.6;\r\n }\r\n`\r\n","import styled, { css } from 'styled-components'\r\nimport { Button, ButtonBlock, ButtonPrimary } from '../Button/styles'\r\nimport IconAlertInfo from '../../assets/icons/icon-alert-info.svg'\r\n\r\nexport const Register = styled.section`\r\n background: #fff;\r\n\r\n`\r\nexport const ProfileTitle = styled.h2`\r\n font-size: 22px;\r\n margin-bottom: 20px;\r\n color: #555;\r\n`\r\n\r\nexport const WrapperSmall = styled.div`\r\n max-width: 600px;\r\n width: 100%;\r\n /* padding: 100px 0; */\r\n /* margin: auto; */\r\n\r\n @media (max-width: 1170px) {\r\n /* max-width: 95%; */\r\n }\r\n`\r\n\r\nexport const RegisterCard = styled.div`\r\n\r\n background: #fff;\r\n padding: 40px;\r\n border: 1px solid #eeeeee;\r\n border-radius: 10px;\r\n -webkit-box-shadow: 4px 3px 7px 2px rgba(0, 0, 0, 0.05);\r\n box-shadow: 4px 3px 7px 2px rgba(0, 0, 0, 0.05);\r\n\r\n p {\r\n margin-bottom: 20px;\r\n margin-top: 0;\r\n }\r\n\r\n small {\r\n margin-bottom: 5px;\r\n font-size: 13px;\r\n line-height: 22px;\r\n }\r\n\r\n @media (max-width: 600px){\r\n min-width: 100%;\r\n padding: 40px 20px;\r\n }\r\n\r\n .alert-info {\r\n background: #F1F8FF url(${IconAlertInfo}) left 20px center no-repeat;\r\n color: #1877F2;\r\n padding: 20px 60px 20px 70px;\r\n border-radius: 5px;\r\n font-size: 14px;\r\n line-height: 20px;\r\n margin: 20px 0 0 0;\r\n position: relative;\r\n }\r\n\r\n .alert-info svg {\r\n width: 22px;\r\n height: 22px;\r\n position: absolute;\r\n right: 30px;\r\n top: 50%;\r\n cursor: pointer;\r\n\r\n -webkit-transform: translateY(-50%);\r\n -moz-transform: translateY(-50%);\r\n -ms-transform: translateY(-50%);\r\n transform: translateY(-50%);\r\n -webkit-transition: all 400ms;\r\n -moz-transition: all 400ms;\r\n transition: all 400ms;\r\n }\r\n\r\n .alert-info svg:hover {\r\n opacity: 0.6;\r\n }\r\n\r\n ${({ type }) => css`\r\n ${type === \"modal\" ? css`\r\n\r\n /* form {\r\n @media (max-height: 480px){\r\n overflow-y: scroll;\r\n padding: 0;\r\n max-height: 70vh;\r\n }\r\n } */\r\n ` : css`\r\n form {\r\n @media (max-height: 480px){\r\n }\r\n }\r\n `}\r\n `}\r\n\r\n\r\n`\r\n\r\nexport const Title = styled.h3`\r\n font-size: 24px;\r\n font-weight: 500;\r\n color: #d22630;\r\n margin-bottom: 5px;\r\n text-align: left;\r\n\r\n @media (max-width: 1170px) {\r\n font-size: 18px;\r\n text-align: left;\r\n }\r\n`\r\nexport const ChangeButton = styled.button`\r\n ${({ theme, disabled }) => css`\r\n ${Button(theme)}\r\n ${ButtonPrimary(theme)}\r\n ${ButtonBlock}\r\n margin-top: 4px;\r\n cursor: pointer;\r\n\r\n ${disabled &&\r\n css`\r\n background: ${theme.colors.grey};\r\n `}\r\n `}\r\n`\r\n","import { useRef } from 'react'\r\nimport FormChangePassword from '../FormChangePassword'\r\nimport {\r\n Background,\r\n ModalWrapper,\r\n HeaderModalClose,\r\n ModalContent\r\n} from './styles'\r\nimport IconClose from '../../assets/icons/icon-close.svg'\r\nimport FormAddNewCreditCard from '../FormAddNewCreditCard'\r\n\r\nconst FormAddNewCreditCardModal = ({ showModal, setShowModal }) => {\r\n const modalRef = useRef()\r\n\r\n const closeModal = (e) => {\r\n if (modalRef.current === e.target) {\r\n setShowModal(false)\r\n }\r\n }\r\n\r\n return (\r\n <>\r\n {showModal ? (\r\n \r\n \r\n \r\n setShowModal((prev) => !prev)}\r\n />\r\n setShowModal((prev) => !prev)}\r\n >\r\n {/* */}\r\n \"\"\r\n \r\n \r\n \r\n \r\n ) : null}\r\n \r\n )\r\n}\r\n\r\nexport default FormAddNewCreditCardModal\r\n","import styled, { css, keyframes } from 'styled-components'\r\n\r\nconst showModal = keyframes`\r\n from {\r\n opacity: 0;\r\n } to {\r\n opacity: 1;\r\n }\r\n`\r\n\r\nexport const Background = styled.div`\r\n width: 100%;\r\n height: 100%;\r\n background: rgba(0, 0, 0, 0.7);\r\n transition: background 0.2s;\r\n position: fixed;\r\n display: flex;\r\n justify-content: center;\r\n align-items: center;\r\n z-index: 300;\r\n animation: ${showModal} 200ms;\r\n`\r\n\r\nexport const ModalWrapper = styled.div`\r\n ${({ current }) => css`\r\n width: 100%;\r\n padding: 32px 32px 8px 32px;\r\n box-shadow: 0 5px 16px rgba(0, 0, 0, 0.2);\r\n background: #fff;\r\n color: #000;\r\n position: relative;\r\n text-align: left;\r\n z-index: 10;\r\n overflow: auto;\r\n border-radius: 10px;\r\n max-height: 95%;\r\n\r\n @media (max-width: 560px) {\r\n max-width: 90%;\r\n margin: auto;\r\n padding: 16px 8px;\r\n }\r\n\r\n @media (max-height: 630px) {\r\n max-height: 95%;\r\n }\r\n\r\n ${current === 0 &&\r\n css`\r\n max-width: 500px;\r\n `}\r\n\r\n ${current === 1 &&\r\n css`\r\n max-width: 700px;\r\n `}\r\n\r\n ${current === 2 &&\r\n css`\r\n max-width: 700px;\r\n `}\r\n\r\n ${current === 3 &&\r\n css`\r\n max-width: 500px;\r\n `}\r\n `}\r\n`\r\n\r\nexport const ContentWrapper = styled.div`\r\n position: relative;\r\n\r\n h3 {\r\n margin-bottom: 16px;\r\n font-weight: 500;\r\n font-size: 24px;\r\n }\r\n\r\n .content {\r\n overflow-y: auto;\r\n height: calc(110px + (600 — 110) * ((70vh — 210px) / (1080 — 110)));\r\n display: flex;\r\n flex-direction: column;\r\n justify-content: space-between;\r\n }\r\n\r\n p.title {\r\n margin-bottom: 8px;\r\n font-weight: 600;\r\n }\r\n\r\n @media (max-width: 560px) {\r\n max-width: 90%;\r\n margin: auto;\r\n }\r\n\r\n @media (max-height: 630px) {\r\n max-height: 95%;\r\n\r\n .content {\r\n overflow-y: auto;\r\n height: 40vh;\r\n }\r\n }\r\n`\r\n\r\nexport const CardWrapper = styled.div`\r\n ${({ theme }) => css`\r\n width: 100%;\r\n\r\n .col-6 {\r\n width: 100%;\r\n }\r\n `}\r\n`\r\n\r\nexport const ProfileBoxFooter = styled.div`\r\n display: flex;\r\n padding: 0;\r\n align-items: center;\r\n margin-top: 8px;\r\n\r\n @media (max-width: 600px) {\r\n flex-direction: column;\r\n\r\n button,\r\n button.button-outline {\r\n max-width: 100%;\r\n margin-right: 0;\r\n }\r\n }\r\n`\r\n\r\nexport const Button = styled.button`\r\n ${({ theme }) => css`\r\n max-width: 170px;\r\n margin-right: 12px;\r\n\r\n border-radius: 5px;\r\n border: 2px solid transparent;\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 500;\r\n font-size: 16px;\r\n padding: 12px 30px;\r\n margin-bottom: 10px;\r\n width: 100%;\r\n text-align: center;\r\n transition: ${theme.transition.default};\r\n cursor: pointer;\r\n background: ${theme.colors.primary};\r\n color: ${theme.colors.white};\r\n\r\n &:hover {\r\n background: #a71e26;\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: $MEDIA-IPAD) {\r\n font-size: 14px;\r\n }\r\n\r\n &.button-outline {\r\n max-width: 146px;\r\n background: transparent;\r\n border: 2px solid #8f8f8f;\r\n color: #8f8f8f;\r\n\r\n &:hover {\r\n border-color: #4a4a4a;\r\n color: #4a4a4a;\r\n }\r\n\r\n &:disabled {\r\n color: #7b7b7b;\r\n border-color: #7b7b7b;\r\n cursor: initial;\r\n }\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n & + .button {\r\n margin-left: 0;\r\n margin-top: 8px;\r\n }\r\n }\r\n `}\r\n`\r\n\r\nexport const HeaderModalClose = styled.button`\r\n background: none;\r\n border: 0;\r\n position: absolute;\r\n top: 30px;\r\n right: 40px;\r\n transition: all 400ms;\r\n cursor: pointer;\r\n\r\n img {\r\n width: 18px;\r\n }\r\n\r\n &:hover {\r\n opacity: 0.6;\r\n }\r\n`\r\n","import styled from 'styled-components'\r\n\r\nexport const ProfileBox = styled.div`\r\n background: #ffffff;\r\n padding: 30px 30px 30px 30px;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 10px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 20px;\r\n`\r\n\r\nexport const ProfileTitle = styled.h2`\r\n font-size: 22px;\r\n margin-bottom: 20px;\r\n color: #555;\r\n`\r\n","import * as S from './styles'\r\n\r\nconst EmptyAdress = () => {\r\n return (\r\n <>\r\n \r\n

    \r\n Você ainda não tem endereços cadastrados :(\r\n

    \r\n
    \r\n \r\n )\r\n}\r\n\r\nexport default EmptyAdress\r\n","export default __webpack_public_path__ + \"static/media/icon-edit.01ec2fcf.svg\";","import styled, { css } from 'styled-components'\r\n// import IconEdit from '../../../assets/icons/icon-edit.svg'\r\n// import IconRemove from '../../../assets/icons/icon-remove.svg'\r\n\r\nexport const ProfileTitle = styled.h2`\r\n font-size: 22px;\r\n margin-bottom: 20px;\r\n color: #555;\r\n`\r\n\r\nexport const Wrapper = styled.div``\r\n\r\nexport const CardWrapper = styled.div`\r\n @media (min-width: 1170px) {\r\n .col-6 {\r\n width: 50%;\r\n }\r\n }\r\n`\r\n\r\nexport const CardBox = styled.div`\r\n background: #ffffff;\r\n padding: 8px 16px;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 4px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 20px;\r\n position: relative;\r\n\r\n .padrao {\r\n position: absolute;\r\n top: 23px;\r\n left: 16px;\r\n }\r\n\r\n .address-info {\r\n margin-left: 34px;\r\n }\r\n\r\n .endereco-card-title {\r\n font-size: 14px;\r\n font-weight: 400;\r\n display: block;\r\n margin-bottom: 2px;\r\n color: #707070;\r\n max-width: 80%;\r\n }\r\n\r\n .apelido {\r\n font-weight: 600;\r\n color: #2e2e2e;\r\n }\r\n .endereco-card-title span {\r\n font-weight: normal;\r\n }\r\n\r\n .endereco-card-description {\r\n margin-bottom: 8px;\r\n color: #707070;\r\n font-size: 14px;\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n .perfil-box {\r\n padding: 30px 20px 10px 20px;\r\n }\r\n }\r\n\r\n @media (min-width: 1170px) and (max-width: 1360px) {\r\n .endereco-card-title {\r\n font-size: 14px;\r\n }\r\n\r\n .endereco-card-description {\r\n font-size: 14px;\r\n }\r\n }\r\n`\r\n\r\nexport const CardConfig = styled.div`\r\n position: absolute;\r\n right: 16px;\r\n top: 16px;\r\n display: flex;\r\n`\r\n\r\nexport const CardLink = styled.a`\r\n transition: all 400ms;\r\n cursor: pointer;\r\n\r\n &:nth-child(2) {\r\n margin-left: 8px;\r\n }\r\n\r\n & img {\r\n width: 18px;\r\n height: 18px;\r\n\r\n &:hover {\r\n filter: invert(22%) sepia(78%) saturate(2710%) hue-rotate(341deg)\r\n brightness(88%) contrast(96%);\r\n }\r\n }\r\n`\r\n\r\nexport const CardAddressType = styled.h3`\r\n font-size: 16px;\r\n display: block;\r\n margin-bottom: 8px;\r\n`\r\nexport const Address = styled.h3``\r\n\r\nexport const ProfileBox = styled.div`\r\n background: #ffffff;\r\n padding: 30px;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 10px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 20px;\r\n`\r\n\r\nexport const ProfileBoxFooter = styled.div`\r\n margin: 10px 0 16px 0;\r\n\r\n button {\r\n border: none;\r\n cursor: pointer;\r\n font-family: Montserrat;\r\n font-weight: 500;\r\n font-size: 14px;\r\n background-color: #fff;\r\n text-decoration: underline;\r\n text-align: left;\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n display: flex;\r\n flex-direction: column;\r\n }\r\n`\r\n\r\nexport const ButtonAddNewAddress = styled.button`\r\n ${({ theme }) => css`\r\n border-radius: 5px;\r\n border: 2px solid transparent;\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 500;\r\n font-size: 16px;\r\n padding: 15px 30px;\r\n text-align: center;\r\n transition: ${theme.transition.default};\r\n cursor: pointer;\r\n background: ${theme.colors.primary};\r\n color: ${theme.colors.white};\r\n\r\n &:hover {\r\n background: #a71e26;\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: $MEDIA-IPAD) {\r\n font-size: 14px;\r\n }\r\n `}\r\n`\r\n","export const noMask = (value) => value.replace(/\\D/g, '')\r\n\r\nexport const cpfMask = (value) =>\r\n value\r\n .replace(/\\D/g, '')\r\n .replace(/(\\d{3})(\\d)/, '$1.$2')\r\n .replace(/(\\d{3})(\\d)/, '$1.$2')\r\n .replace(/(\\d{3})(\\d{1,2})/, '$1-$2')\r\n .replace(/(-\\d{2})\\d+?$/, '$1')\r\n\r\nexport const dateMask = (value) => {\r\n return value\r\n .replace(/\\D/g, '')\r\n .replace(/(\\d{2})(\\d)/, '$1/$2')\r\n .replace(/(\\d{2})(\\d)/, '$1/$2')\r\n .replace(/(\\d{2}\\/\\d{2}\\/\\d{4})\\d+?$/, '$1')\r\n}\r\n\r\nexport const cellMask = (value) => {\r\n if (typeof value === 'string')\r\n return value\r\n .replace(/\\D/g, '')\r\n .replace(/(\\d{2})(\\d)/, '($1) $2')\r\n .replace(/(\\d{5})(\\d)/, '$1-$2')\r\n .replace(/(\\(\\d{2}\\)\\s\\d{5}-\\d{4})\\d+?$/, '$1')\r\n return ''\r\n}\r\n\r\nexport const fixPhoneMask = (value) => {\r\n if (typeof value === 'string')\r\n return value\r\n .replace(/\\D/g, '')\r\n .replace(/(\\d{2})(\\d)/, '($1) $2')\r\n .replace(/(\\d{4})(\\d)/, '$1-$2')\r\n .replace(/(\\(\\d{2}\\)\\s\\d{4}-\\d{4})\\d+?$/, '$1')\r\n return ''\r\n}\r\n\r\nexport const dddString = (value) => noMask(value || '').substr(0, 2)\r\n\r\nexport const phoneString = (value) => noMask(value || '').substr(2)\r\n\r\nexport const dateString = (value) => {\r\n const date = value?.split('/') || ['01', '01', '2000']\r\n return `${date[2]}-${date[1]}-${date[0]}T20:29:13.070Z`\r\n}\r\n\r\nexport const dateFromString = (value) => {\r\n const date = value?.slice(0, 10).split('-') || ['01', '01', '2000']\r\n return `${date[2]}/${date[1]}/${date[0]}`\r\n}\r\n\r\nexport const cepMask = (value) =>\r\n value\r\n .replace(/\\D/g, '')\r\n .replace(/^(\\d{2})(\\d)/, '$1.$2')\r\n .replace(/\\.(\\d{3})(\\d)/, '.$1-$2')\r\n\r\nexport const addressNumber = (value) => {\r\n return value.replace(/\\D/g, '')\r\n}\r\n\r\nexport const noSpecialChars = (value) => {\r\n return value.replace(/[^a-z0-9àèìòùáéíóúâêîôûãõç\\s]/gi, '')\r\n}\r\n","import { useState } from 'react'\r\nimport EmptyAdress from '../../MyAddress/EmptyAdress'\r\n\r\nimport IconEdit from '../../../assets/icons/icon-edit.svg'\r\nimport IconRemove from '../../../assets/icons/icon-remove.svg'\r\nimport * as S from './styles'\r\nimport defaultOptions from '../../../api/defaultoption'\r\nimport { useToast } from '../../../hooks/toast'\r\nimport Loader from '../../Loader'\r\nimport { useSelector, useDispatch } from 'react-redux'\r\nimport { setEndereco, setPadrao } from '../../../store/ducks/endereco'\r\nimport clientes from '../../../api/clientes'\r\nimport { isPF } from '../../../api/auth/auth'\r\nimport { cepMask } from '../../FormPF/masks'\r\n\r\nconst AddressCardModal = ({\r\n setCurrent,\r\n deleteModal,\r\n userAddress,\r\n setCardId,\r\n current,\r\n loading,\r\n setLoading,\r\n setSelectedAddress,\r\n inscEstadualIsento,\r\n allowAddAdressPJ\r\n}) => {\r\n const { addToast } = useToast()\r\n const [checked, setChecked] = useState('')\r\n\r\n const dispatch = useDispatch()\r\n const store = useSelector((store) => store)\r\n\r\n const capitalize = (str) => {\r\n return str\r\n .toLowerCase()\r\n .split(' ')\r\n .map((word) => word.charAt(0).toUpperCase() + word.substring(1))\r\n .join(' ')\r\n }\r\n\r\n const isMaxAdressLimit = () => {\r\n if (userAddress.length >= 5) {\r\n addToast({\r\n type: 'error',\r\n title:\r\n 'Máximo de 4 endereços de entrega. Remova algum endereço para adicionar um novo'\r\n })\r\n return true\r\n }\r\n }\r\n\r\n const handleDeleteCard = async (id) => {\r\n setLoading(true)\r\n try {\r\n let response = await fetch(\r\n `${process.env.REACT_APP_API_ENDPOINT}clientes/clientes/enderecos/${id}`,\r\n {\r\n method: 'DELETE',\r\n headers: defaultOptions.headers\r\n }\r\n )\r\n if (response) setLoading(false)\r\n\r\n if (response.ok) {\r\n let get = await clientes.enderecos()\r\n get = await get.json()\r\n dispatch(setEndereco(get))\r\n addToast({\r\n type: 'success',\r\n title: 'Endereço excluído'\r\n })\r\n } else {\r\n addToast({\r\n type: 'error',\r\n title: 'Erro ao excluir endereço',\r\n description: 'Endereço de cobrança não pode ser excluído'\r\n })\r\n }\r\n\r\n current === 0 ? setCurrent(3) : setCurrent(0)\r\n } catch (error) {}\r\n }\r\n\r\n const handleSubmit = async (id) => {\r\n const item = await userAddress.find((element) => element.id === id)\r\n // setLoading(true)\r\n\r\n const formData = {\r\n ...item,\r\n padrao: true\r\n }\r\n\r\n setSelectedAddress(formData)\r\n }\r\n\r\n return (\r\n <>\r\n {loading ? : null}\r\n\r\n \r\n {userAddress.length ? (\r\n userAddress.map(\r\n (\r\n {\r\n padrao,\r\n apelido,\r\n tipoEndereco,\r\n id,\r\n tipoLogradouro,\r\n logradouro,\r\n numero,\r\n bairro,\r\n cidade,\r\n uf,\r\n cep\r\n },\r\n i\r\n ) => {\r\n return (\r\n <>\r\n \r\n \r\n \r\n {!isPF() && tipoEndereco === 'C' ? null : (\r\n {\r\n setCardId(id)\r\n setCurrent(2)\r\n }}\r\n >\r\n \"\"\r\n \r\n )}\r\n {tipoEndereco === 'E' && (\r\n handleDeleteCard(id)}\r\n >\r\n \"\"\r\n \r\n )}\r\n \r\n\r\n {console.log(cepMask(cep))}\r\n\r\n
    \r\n \r\n {capitalize(apelido)}\r\n \r\n {tipoLogradouro === logradouro.trim().split(' ')[0] ? (\r\n \r\n {capitalize(logradouro)} {numero}\r\n \r\n ) : (\r\n \r\n {capitalize(tipoLogradouro)}{' '}\r\n {capitalize(logradouro)} {numero}\r\n \r\n )}\r\n\r\n

    \r\n {capitalize(bairro)} - {capitalize(cidade)} / {uf} -{' '}\r\n {cepMask(cep)}\r\n

    \r\n
    \r\n\r\n
    \r\n {\r\n await setCardId(id)\r\n if (e.target.name == id) {\r\n setChecked(e.target.name)\r\n }\r\n handleSubmit(id)\r\n }}\r\n />\r\n\r\n \r\n
    \r\n
    \r\n
    \r\n \r\n )\r\n }\r\n )\r\n ) : (\r\n \r\n )}\r\n
    \r\n\r\n \r\n {\r\n // setCurrent(1)\r\n if (!isPF()) {\r\n allowAddAdressPJ()\r\n } else if (!isMaxAdressLimit()) {\r\n setCurrent(1)\r\n }\r\n }}\r\n >\r\n Adicionar novo endereço\r\n \r\n \r\n \r\n )\r\n}\r\n\r\nexport default AddressCardModal\r\n","const ceps = {\r\n getAddress(cep, params) {\r\n return fetch(`${process.env.REACT_APP_API_CEPS}${cep}`, params)\r\n }\r\n}\r\n\r\nexport default ceps\r\n","import styled, { css } from 'styled-components'\r\n\r\nexport const ProfileTitle = styled.h2`\r\n font-size: 22px;\r\n margin-bottom: 20px;\r\n color: #555;\r\n`\r\n\r\nexport const ProfileBox = styled.div`\r\n display: flex;\r\n margin: -10px;\r\n\r\n @media (max-width: 1170px) {\r\n flex-direction: column;\r\n\r\n .col-3 {\r\n display: block;\r\n }\r\n }\r\n`\r\n\r\nexport const ProfileBoxFooter = styled.div`\r\n margin: 10px 0 20px 0;\r\n\r\n @media (max-width: 1170px) {\r\n display: flex;\r\n flex-direction: column;\r\n }\r\n`\r\n\r\nexport const Button = styled.button`\r\n ${({ theme }) => css`\r\n border-radius: 5px;\r\n border: 2px solid transparent;\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 500;\r\n font-size: 16px;\r\n padding: 15px 30px;\r\n text-align: center;\r\n transition: ${theme.transition.default};\r\n cursor: pointer;\r\n background: ${theme.colors.primary};\r\n color: ${theme.colors.white};\r\n\r\n &:hover {\r\n background: #a71e26;\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: $MEDIA-IPAD) {\r\n font-size: 14px;\r\n }\r\n\r\n &.button-outline {\r\n background: transparent;\r\n border: 2px solid ${theme.colors.primary};\r\n color: ${theme.colors.primary};\r\n\r\n &:hover {\r\n border-color: #4a4a4a;\r\n color: #4a4a4a;\r\n }\r\n\r\n &:disabled {\r\n color: #7b7b7b;\r\n border-color: #7b7b7b;\r\n cursor: initial;\r\n }\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n & + .button {\r\n margin-left: 0;\r\n margin-top: 8px;\r\n }\r\n `}\r\n`\r\n","import { useEffect, useState } from 'react'\r\nimport * as Yup from 'yup'\r\nimport jwt from 'jsonwebtoken'\r\n\r\nimport * as auth from '../../../api/auth/auth'\r\nimport clientes from '../../../api/clientes'\r\nimport ceps from '../../../api/ceps'\r\nimport defaultOptions from '../../../api/defaultoption'\r\nimport { useToast } from '../../../hooks/toast'\r\nimport { useSelector, useDispatch } from 'react-redux'\r\n\r\nimport * as S from './styles'\r\n// import * as FormStyles from '../../Form/styles'\r\nimport { FormGroup } from '../../Form/styles'\r\nimport TextField from '../../TextField'\r\nimport {\r\n addressNumber,\r\n cepMask,\r\n noMask,\r\n noSpecialChars\r\n} from '../../FormPF/masks'\r\nimport Loader from '../../Loader'\r\nimport { setEndereco, setPadrao } from '../../../store/ducks/endereco'\r\n\r\nconst NewAddressFormModal = ({\r\n current,\r\n setCurrent,\r\n loading,\r\n setLoading,\r\n inscEstadualIsento,\r\n faturamentoUF\r\n}) => {\r\n const { addToast } = useToast()\r\n const dispatch = useDispatch()\r\n const store = useSelector((store) => store)\r\n\r\n const token = auth.getToken()\r\n const userTokenData = jwt.decode(token)\r\n const userId = parseInt(userTokenData.id)\r\n const [inputErrors, setInputErrors] = useState({})\r\n const [load, setLoad] = useState(false)\r\n\r\n const [isCepUnico, setIsCepUnico] = useState(false)\r\n\r\n const [values, setValues] = useState({\r\n padrao: false,\r\n id: userId,\r\n tipoEndereco: 'E',\r\n apelido: '',\r\n bairro: '',\r\n cep: '',\r\n cidade: '',\r\n complemento: '',\r\n logradouro: '',\r\n numero: '',\r\n pontoReferencia: '',\r\n tipoLogradouro: '',\r\n uf: ''\r\n })\r\n\r\n const checkNewAddressUF = (uf) => {\r\n if (\r\n !inscEstadualIsento &&\r\n (faturamentoUF === 'SP' || faturamentoUF === 'RJ')\r\n ) {\r\n if (uf === faturamentoUF) {\r\n return true\r\n } else {\r\n addToast({\r\n type: 'error',\r\n title:\r\n 'ATENÇÃO: Não é possível cadastrar ou selecionar endereço de entrega com Estado diferente do endereço de faturamento',\r\n timer: 5000\r\n })\r\n return false\r\n }\r\n } else if (inscEstadualIsento) {\r\n if (uf === faturamentoUF) {\r\n return true\r\n } else {\r\n addToast({\r\n type: 'error',\r\n title:\r\n 'ATENÇÃO: Não é possível cadastrar ou selecionar endereço de entrega com Estado diferente do endereço de faturamento',\r\n timer: 5000\r\n })\r\n return false\r\n }\r\n }\r\n }\r\n\r\n const checkCEPUnico = (cep) => {\r\n const lastDigits = cep.substr(-3)\r\n\r\n if (lastDigits == '000') {\r\n // console.log('CEP Unico:', lastDigits)\r\n setIsCepUnico(true)\r\n } else {\r\n // console.log('CEP Válido')\r\n setIsCepUnico(false)\r\n }\r\n }\r\n\r\n // const checkLogradouro = (logradouro, bairro) => {\r\n // if (logradouro === '' || logradouro === ' ' || logradouro.length === 0) {\r\n // setIsLogradouroDisabled(false)\r\n // } else {\r\n // setIsLogradouroDisabled(true)\r\n // }\r\n\r\n // bairro.length === 0 ? setIsBairroDisabled(false) : setIsBairroDisabled(true)\r\n // }\r\n\r\n async function onBlurCep() {\r\n // checkCEPUnico(values.cep)\r\n\r\n if (noMask(values.cep).length === 8) {\r\n setLoad(true)\r\n const data = await ceps\r\n .getAddress(noMask(values.cep), defaultOptions)\r\n .then((res) => {\r\n if (res.ok) {\r\n setLoad(false)\r\n return res.json()\r\n } else if (!res.body) {\r\n addToast({\r\n title: 'Cep não encontrado',\r\n type: 'error'\r\n })\r\n }\r\n })\r\n .catch(() => {\r\n setLoad(false)\r\n\r\n addToast({\r\n type: 'error',\r\n title: 'CEP inválido',\r\n description: `O CEP informado não foi encontrado`\r\n })\r\n setValues({\r\n ...values,\r\n bairro: '',\r\n cidade: '',\r\n complemento: '',\r\n logradouro: '',\r\n tipoLogradouro: '',\r\n uf: ''\r\n })\r\n })\r\n\r\n if (data) {\r\n const { bairro, cidade, complemento, endereco, tipoLogradouro, uf } =\r\n data\r\n\r\n if (endereco.trim() === '') {\r\n setIsCepUnico(true)\r\n } else {\r\n setIsCepUnico(false)\r\n }\r\n\r\n if (!auth.isPF()) {\r\n if (!!checkNewAddressUF(uf)) {\r\n // checkLogradouro(endereco, bairro)\r\n\r\n setValues({\r\n ...values,\r\n bairro: bairro,\r\n cidade: cidade,\r\n // complemento: complemento,\r\n logradouro: endereco,\r\n tipoLogradouro: tipoLogradouro,\r\n uf: uf\r\n })\r\n } else {\r\n setValues({\r\n ...values,\r\n bairro: '',\r\n cidade: '',\r\n complemento: '',\r\n logradouro: '',\r\n tipoLogradouro: '',\r\n uf: ''\r\n })\r\n }\r\n } else {\r\n // checkLogradouro(endereco, bairro)\r\n\r\n setValues({\r\n ...values,\r\n bairro: bairro,\r\n cidade: cidade,\r\n // complemento: complemento,\r\n // logradouro:\r\n // endereco === ''\r\n // ? `${tipoLogradouro}${endereco}`\r\n // : `${tipoLogradouro} ${endereco}`,\r\n logradouro: endereco,\r\n tipoLogradouro: tipoLogradouro,\r\n uf: uf\r\n })\r\n }\r\n }\r\n }\r\n\r\n if ((noMask(values.cep).length < 8) & (noMask(values.cep).length > 0)) {\r\n addToast({\r\n type: 'error',\r\n title: 'CEP inválido',\r\n description: `O CEP deve conter 8 dígitos`\r\n })\r\n setValues({\r\n ...values,\r\n bairro: '',\r\n cidade: '',\r\n complemento: '',\r\n logradouro: '',\r\n tipoLogradouro: '',\r\n uf: ''\r\n })\r\n }\r\n }\r\n\r\n const handleChange = (e) => {\r\n const { name, value } = e.target\r\n setValues({\r\n ...values,\r\n [name]:\r\n name === 'apelido'\r\n ? noSpecialChars(value.trimStart())\r\n : value.trimStart()\r\n })\r\n\r\n setInputErrors({\r\n ...inputErrors,\r\n [name]: ''\r\n })\r\n }\r\n\r\n const handleCEPChange = (e) => {\r\n const { name, value } = e.target\r\n\r\n setValues({\r\n ...values,\r\n [name]: cepMask(value)\r\n })\r\n\r\n setInputErrors({\r\n ...inputErrors,\r\n [name]: ''\r\n })\r\n }\r\n\r\n const handleNumberChange = (e) => {\r\n const { name, value } = e.target\r\n setValues({\r\n ...values,\r\n [name]: addressNumber(value)\r\n })\r\n\r\n setInputErrors({\r\n ...inputErrors,\r\n [name]: ''\r\n })\r\n }\r\n\r\n const handleBlur = (e) => {\r\n const { name, value } = e.target\r\n\r\n setValues({\r\n ...values,\r\n [name]: value.trimEnd().replace(/ +/g, ' ')\r\n })\r\n }\r\n\r\n const clearCEP = async () => {\r\n setValues({\r\n bairro: '',\r\n cidade: '',\r\n logradouro: '',\r\n numero: '',\r\n tipoLogradouro: '',\r\n uf: ''\r\n })\r\n }\r\n\r\n useEffect(() => {\r\n if (values.cep?.length > 9) {\r\n onBlurCep()\r\n }\r\n // else {\r\n // clearCEP()\r\n // }\r\n }, [values.cep])\r\n\r\n const handleSubmit = async (e) => {\r\n e.preventDefault()\r\n\r\n setLoad(true)\r\n const formData = {\r\n padrao: false,\r\n id: userId,\r\n tipoEndereco: 'E',\r\n apelido: values.apelido,\r\n // tipoLogradouro: values.logradouro.trim().split(' ')[0],\r\n tipoLogradouro: values.tipoLogradouro,\r\n logradouro: values.logradouro,\r\n numero: values.numero,\r\n complemento: values.complemento,\r\n pontoReferencia: values.pontoReferencia,\r\n bairro: values.bairro,\r\n cidade: values.cidade,\r\n uf: values.uf,\r\n cep: noMask(values.cep)\r\n }\r\n\r\n const addressSchema = Yup.object().shape({\r\n padrao: Yup.bool(),\r\n id: Yup.number(),\r\n tipoEndereco: Yup.string(),\r\n apelido: Yup.string().required('Apelido Obrigatório'),\r\n bairro: Yup.string().required('Bairro Obrigatório'),\r\n cep: Yup.string()\r\n .min(8, 'CEP deve conter 8 caracteres')\r\n .required('CEP Obrigatório'),\r\n cidade: Yup.string()\r\n .required('Cidade Obrigatório')\r\n .min(3, 'No mínimo 3 caracteres'),\r\n complemento: Yup.string(),\r\n tipoLogradouro: Yup.string(),\r\n logradouro: Yup.string().required('Logradouro é Obrigatório'),\r\n numero: Yup.string()\r\n .min(1, 'No mínimo 1 caractere')\r\n .required('Número Obrigatório'),\r\n uf: Yup.string().required('UF Obrigatório')\r\n })\r\n try {\r\n await addressSchema.validate(formData, {\r\n abortEarly: false\r\n })\r\n\r\n let res = await clientes.enderecos({\r\n method: 'POST',\r\n headers: defaultOptions.headers,\r\n body: JSON.stringify(formData)\r\n })\r\n setLoad(false)\r\n if (res.ok) {\r\n let get = await clientes.enderecos()\r\n get = await get.json()\r\n dispatch(setEndereco(get))\r\n addToast({\r\n type: 'success',\r\n title: `Endereço adicionado!`\r\n })\r\n } else {\r\n addToast({\r\n type: 'error',\r\n title: 'Erro ao adicionar endereço'\r\n })\r\n }\r\n\r\n current === 0 ? setCurrent(3) : setCurrent(0)\r\n } catch (err) {\r\n if (err) setLoad(false)\r\n\r\n if (err instanceof Yup.ValidationError) {\r\n const emptyField = Object.values(err.value).every(\r\n (value) => value !== ''\r\n )\r\n\r\n if (!emptyField) {\r\n addToast({\r\n type: 'error',\r\n title: 'Preencha todos os campos obrigatórios'\r\n })\r\n\r\n const errorArray = err.inner.map((error) => {\r\n return JSON.parse(\r\n `{\"name\": \"${error.path}\", \"message\": \"${error.message}\"}`\r\n )\r\n })\r\n\r\n const objeto = errorArray.reduce((acc, d) => {\r\n acc[d.name] = d.message\r\n\r\n return acc\r\n }, {})\r\n setInputErrors(objeto)\r\n } else {\r\n setLoad(false)\r\n err.inner.map((error) => {\r\n addToast({\r\n type: 'error',\r\n title: `Erro ao adicionar endereço`,\r\n description: `${error.message}`\r\n })\r\n })\r\n }\r\n }\r\n }\r\n }\r\n\r\n return (\r\n <>\r\n {load ? : null}\r\n \r\n
    \r\n
    \r\n \r\n \r\n handleCEPChange(e)}\r\n autoFocus\r\n />\r\n \r\n Não sei meu CEP\r\n \r\n \r\n
    \r\n\r\n
    \r\n \r\n \r\n handleChange(e)}\r\n />\r\n \r\n
    \r\n\r\n {/* {console.log(enableInput)} */}\r\n
    \r\n \r\n \r\n handleChange(e)}\r\n />\r\n \r\n
    \r\n\r\n
    \r\n \r\n \r\n handleNumberChange(e)}\r\n />\r\n \r\n
    \r\n\r\n
    \r\n \r\n \r\n handleChange(e)}\r\n />\r\n \r\n
    \r\n\r\n
    \r\n \r\n \r\n handleChange(e)}\r\n />\r\n \r\n
    \r\n\r\n
    \r\n \r\n \r\n handleChange(e)}\r\n />\r\n \r\n
    \r\n\r\n
    \r\n \r\n \r\n handleChange(e)}\r\n />\r\n \r\n
    \r\n\r\n
    \r\n \r\n \r\n handleChange(e)}\r\n />\r\n \r\n
    \r\n\r\n {/* \r\n {\r\n setValues({\r\n ...values,\r\n padrao: !values.padrao\r\n })\r\n }}\r\n />\r\n \r\n */}\r\n
    \r\n
    \r\n \r\n \r\n Salvar Endereço\r\n \r\n setCurrent(0)}\r\n >\r\n Cancelar\r\n \r\n \r\n \r\n )\r\n}\r\n\r\nexport default NewAddressFormModal\r\n","import styled, { css } from 'styled-components'\r\n\r\nexport const ProfileTitle = styled.h2`\r\n font-size: 22px;\r\n margin-bottom: 20px;\r\n color: #555;\r\n`\r\n\r\nexport const ProfileBox = styled.div`\r\n display: flex;\r\n\r\n @media (max-width: 1170px) {\r\n flex-direction: column;\r\n\r\n .col-3 {\r\n display: block;\r\n }\r\n }\r\n`\r\n\r\nexport const ProfileBoxFooter = styled.div`\r\n margin: 10px 0 20px 0;\r\n\r\n @media (max-width: 1170px) {\r\n display: flex;\r\n flex-direction: column;\r\n }\r\n`\r\n\r\nexport const Button = styled.button`\r\n ${({ theme }) => css`\r\n border-radius: 5px;\r\n border: 2px solid transparent;\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 500;\r\n font-size: 16px;\r\n padding: 15px 30px;\r\n text-align: center;\r\n transition: ${theme.transition.default};\r\n cursor: pointer;\r\n background: ${theme.colors.primary};\r\n color: ${theme.colors.white};\r\n\r\n &:hover {\r\n background: #a71e26;\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: $MEDIA-IPAD) {\r\n font-size: 14px;\r\n }\r\n\r\n &.button-outline {\r\n background: transparent;\r\n border: 2px solid ${theme.colors.primary};\r\n color: ${theme.colors.primary};\r\n\r\n &:hover {\r\n border-color: #4a4a4a;\r\n color: #4a4a4a;\r\n }\r\n\r\n &:disabled {\r\n color: #7b7b7b;\r\n border-color: #7b7b7b;\r\n cursor: initial;\r\n }\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n & + .button {\r\n margin-left: 0;\r\n margin-top: 8px;\r\n }\r\n }\r\n `}\r\n`\r\n","import { useState, useEffect } from 'react'\r\n\r\nimport clientes from '../../../api/clientes'\r\nimport * as auth from '../../../api/auth/auth'\r\nimport * as Yup from 'yup'\r\n\r\nimport * as S from './styles'\r\nimport { FormGroup } from '../../Form/styles'\r\nimport TextField from '../../TextField'\r\nimport {\r\n addressNumber,\r\n cepMask,\r\n noMask,\r\n noSpecialChars\r\n} from '../../FormPF/masks'\r\nimport { useToast } from '../../../hooks/toast'\r\nimport { useSelector, useDispatch } from 'react-redux'\r\nimport { setEndereco, setPadrao } from '../../../store/ducks/endereco'\r\nimport defaultOptions from '../../../api/defaultoption'\r\nimport jwt from 'jsonwebtoken'\r\n\r\nimport ceps from '../../../api/ceps'\r\nimport Loader from '../../Loader'\r\n\r\nconst EditAddressFormModal = ({\r\n current,\r\n setCurrent,\r\n cardId,\r\n userAddress,\r\n loading,\r\n setLoading,\r\n inscEstadualIsento,\r\n faturamentoUF\r\n}) => {\r\n const { addToast } = useToast()\r\n const dispatch = useDispatch()\r\n const store = useSelector((store) => store)\r\n\r\n const [load, setLoad] = useState(false)\r\n const [inputErrors, setInputErrors] = useState({})\r\n\r\n const [isLogradouroDisabled, setIsLogradouroDisabled] = useState(true)\r\n const [isBairroDisabled, setIsBairroDisabled] = useState(true)\r\n const [isCepUnico, setIsCepUnico] = useState(false)\r\n const [checkLogradouro, setCheckLogradouro] = useState('')\r\n\r\n const token = auth.getToken()\r\n const userTokenData = jwt.decode(token)\r\n const userId = parseInt(userTokenData.id)\r\n\r\n const [values, setValues] = useState({\r\n id: cardId,\r\n padrao: false,\r\n tipoEndereco: 'E',\r\n apelido: '',\r\n bairro: '',\r\n cep: '',\r\n cidade: '',\r\n complemento: '',\r\n logradouro: '',\r\n numero: '',\r\n pontoReferencia: '',\r\n tipoLogradouro: '',\r\n uf: ''\r\n })\r\n\r\n // const checkLogradouro = (logradouro, bairro) => {\r\n // if (logradouro === '' || logradouro === ' ' || logradouro.length === 0) {\r\n // setIsLogradouroDisabled(false)\r\n // } else {\r\n // setIsLogradouroDisabled(true)\r\n // }\r\n\r\n // bairro.length === 0 ? setIsBairroDisabled(false) : setIsBairroDisabled(true)\r\n // }\r\n\r\n const checkCEPUnico = (cep) => {\r\n const lastDigits = cep.substr(-3)\r\n\r\n if (lastDigits == '000') {\r\n // console.log('CEP Unico:', lastDigits)\r\n setIsCepUnico(true)\r\n } else {\r\n // console.log('CEP Válido')\r\n setIsCepUnico(false)\r\n }\r\n }\r\n\r\n const handleEditAddress = async () => {\r\n const item = userAddress.find((element) => element.id === cardId)\r\n setValues(item)\r\n }\r\n\r\n useEffect(() => {\r\n handleEditAddress()\r\n // eslint-disable-next-line react-hooks/exhaustive-deps\r\n }, [])\r\n\r\n const handleChange = (e) => {\r\n const { name, value } = e.target\r\n setValues({\r\n ...values,\r\n [name]:\r\n name === 'apelido'\r\n ? noSpecialChars(value.trimStart())\r\n : value.trimStart()\r\n })\r\n\r\n setInputErrors({\r\n ...inputErrors,\r\n [name]: ''\r\n })\r\n }\r\n\r\n const checkNewAddressUF = (uf) => {\r\n if (\r\n !inscEstadualIsento &&\r\n (faturamentoUF === 'SP' || faturamentoUF === 'RJ')\r\n ) {\r\n if (uf === faturamentoUF) {\r\n return true\r\n } else {\r\n addToast({\r\n type: 'error',\r\n title:\r\n 'ATENÇÃO: Não é possível cadastrar ou selecionar endereço de entrega com Estado diferente do endereço de faturamento',\r\n timer: 5000\r\n })\r\n return false\r\n }\r\n } else if (inscEstadualIsento) {\r\n if (uf === faturamentoUF) {\r\n return true\r\n } else {\r\n addToast({\r\n type: 'error',\r\n title:\r\n 'ATENÇÃO: Não é possível cadastrar ou selecionar endereço de entrega com Estado diferente do endereço de faturamento',\r\n timer: 15000\r\n })\r\n return false\r\n }\r\n }\r\n }\r\n\r\n const handleCEPChange = (e) => {\r\n const { name, value } = e.target\r\n setValues({\r\n ...values,\r\n [name]: cepMask(value)\r\n })\r\n\r\n setInputErrors({\r\n ...inputErrors,\r\n [name]: ''\r\n })\r\n }\r\n\r\n const handleNumberChange = (e) => {\r\n const { name, value } = e.target\r\n setValues({\r\n ...values,\r\n [name]: addressNumber(value)\r\n })\r\n\r\n setInputErrors({\r\n ...inputErrors,\r\n [name]: ''\r\n })\r\n }\r\n\r\n const handleBlur = (e) => {\r\n const { name, value } = e.target\r\n\r\n setValues({\r\n ...values,\r\n [name]: value.trimEnd().replace(/ +/g, ' ')\r\n })\r\n }\r\n\r\n async function checkCep(cep) {\r\n const data = await ceps\r\n .getAddress(noMask(cep), defaultOptions)\r\n .then((res) => {\r\n if (res.ok) {\r\n return res.json()\r\n }\r\n })\r\n\r\n if (data) {\r\n const { bairro, cidade, complemento, endereco, tipoLogradouro, uf } = data\r\n setCheckLogradouro(endereco)\r\n }\r\n }\r\n\r\n async function onBlurCep() {\r\n // checkCEPUnico(values.cep)\r\n\r\n if (noMask(values.cep).length === 8) {\r\n setLoad(true)\r\n const data = await ceps\r\n .getAddress(noMask(values.cep), defaultOptions)\r\n .then((res) => {\r\n if (res.ok) {\r\n setLoad(false)\r\n\r\n return res.json()\r\n } else if (!res.body) {\r\n addToast({\r\n title: 'Cep não encontrado',\r\n type: 'error'\r\n })\r\n }\r\n })\r\n .catch(() => {\r\n setLoad(false)\r\n\r\n addToast({\r\n type: 'error',\r\n title: 'Problema ao buscar CEP',\r\n description: `O CEP informado não foi encontrado`\r\n })\r\n setValues({\r\n ...values,\r\n bairro: '',\r\n cidade: '',\r\n complemento: '',\r\n logradouro: '',\r\n tipoLogradouro: '',\r\n uf: ''\r\n })\r\n })\r\n\r\n if (data) {\r\n const { bairro, cidade, complemento, endereco, tipoLogradouro, uf } =\r\n data\r\n\r\n // console.log(values.apelido)\r\n if (endereco.trim() === '') {\r\n setIsCepUnico(true)\r\n } else {\r\n setIsCepUnico(false)\r\n }\r\n\r\n if (!auth.isPF()) {\r\n if (!!checkNewAddressUF(uf)) {\r\n // checkLogradouro(endereco, bairro)\r\n\r\n setValues({\r\n ...values,\r\n bairro: bairro,\r\n cidade: cidade,\r\n // complemento: complemento,\r\n logradouro: endereco,\r\n uf: uf\r\n })\r\n } else {\r\n setValues({\r\n ...values,\r\n bairro: '',\r\n cidade: '',\r\n complemento: '',\r\n logradouro: '',\r\n tipoLogradouro: '',\r\n uf: ''\r\n })\r\n }\r\n } else {\r\n setValues({\r\n ...values,\r\n bairro: bairro,\r\n cidade: cidade,\r\n logradouro: endereco,\r\n tipoLogradouro: tipoLogradouro,\r\n uf: uf\r\n })\r\n }\r\n }\r\n }\r\n\r\n if ((noMask(values.cep).length < 8) & (noMask(values.cep).length > 0)) {\r\n addToast({\r\n type: 'error',\r\n title: 'CEP inválido',\r\n description: `O CEP deve conter 8 dígitos`\r\n })\r\n setValues({\r\n ...values,\r\n bairro: '',\r\n cidade: '',\r\n complemento: '',\r\n logradouro: '',\r\n tipoLogradouro: '',\r\n uf: ''\r\n })\r\n }\r\n }\r\n\r\n const clearCEP = async () => {\r\n setValues({\r\n bairro: '',\r\n cidade: '',\r\n logradouro: '',\r\n numero: '',\r\n tipoLogradouro: '',\r\n uf: ''\r\n })\r\n }\r\n\r\n\r\n\r\n useEffect(() => {\r\n if (values.cep?.length > 9) {\r\n onBlurCep()\r\n }\r\n // else {\r\n // clearCEP()\r\n // }\r\n }, [values.cep])\r\n\r\n const handleSubmit = async (e) => {\r\n e.preventDefault()\r\n\r\n setLoad(true)\r\n const formData = {\r\n id: cardId,\r\n padrao: values.padrao,\r\n tipoEndereco: values.tipoEndereco,\r\n apelido: values.apelido,\r\n // tipoLogradouro: values.logradouro.trim().split(' ')[0],\r\n tipoLogradouro: values.tipoLogradouro,\r\n logradouro: values.logradouro,\r\n numero: values.numero,\r\n complemento: values.complemento || '',\r\n pontoReferencia: values.pontoReferencia,\r\n bairro: values.bairro,\r\n cidade: values.cidade,\r\n uf: values.uf,\r\n cep: noMask(values.cep)\r\n }\r\n\r\n try {\r\n const addressSchema = Yup.object().shape({\r\n padrao: Yup.bool(),\r\n tipoEndereco: Yup.string(),\r\n apelido: Yup.string().required('Apelido Obrigatório'),\r\n bairro: Yup.string().required('Bairro Obrigatório'),\r\n cep: Yup.string()\r\n .required('CEP Obrigatório')\r\n .min(8, 'CEP deve conter 8 caracteres'),\r\n cidade: Yup.string()\r\n .required('Cidade Obrigatório')\r\n .min(3, 'No mínimo 3 caracteres'),\r\n complemento: Yup.string(),\r\n tipoLogradouro: Yup.string(),\r\n logradouro: Yup.string().required('Logradouro é Obrigatório'),\r\n numero: Yup.string()\r\n .min(1, 'No mínimo 1 caractere')\r\n .required('Número Obrigatório'),\r\n uf: Yup.string().required('UF Obrigatório')\r\n })\r\n\r\n await addressSchema.validate(formData, {\r\n abortEarly: false\r\n })\r\n\r\n \r\n\r\n let response = await fetch(\r\n `${process.env.REACT_APP_API_ENDPOINT}clientes/clientes/enderecos/${cardId}`,\r\n {\r\n method: 'PUT',\r\n headers: defaultOptions.headers,\r\n body: JSON.stringify(formData)\r\n }\r\n )\r\n if (response) setLoad(false)\r\n\r\n if (response.ok) {\r\n let get = await clientes.enderecos()\r\n get = await get.json()\r\n dispatch(setEndereco(get))\r\n addToast({\r\n type: 'success',\r\n title: `Endereço Alterado!`\r\n })\r\n } else {\r\n addToast({\r\n type: 'error',\r\n title: 'Erro ao editar endereço'\r\n })\r\n }\r\n\r\n setCurrent(0)\r\n } catch (err) {\r\n if (err) setLoad(false)\r\n\r\n if (err instanceof Yup.ValidationError) {\r\n const emptyField = Object.values(err.value).every(\r\n (value) => value !== ''\r\n )\r\n\r\n if (!emptyField) {\r\n addToast({\r\n type: 'error',\r\n title: 'Todos os campos devem ser preenchidos'\r\n })\r\n\r\n const errorArray = err.inner.map((error) => {\r\n return JSON.parse(\r\n `{\"name\": \"${error.path}\", \"message\": \"${error.message}\"}`\r\n )\r\n })\r\n\r\n const objeto = errorArray.reduce((acc, d) => {\r\n acc[d.name] = d.message\r\n\r\n return acc\r\n }, {})\r\n setInputErrors(objeto)\r\n } else {\r\n setLoad(false)\r\n err.inner.map((error) => {\r\n return addToast({\r\n type: 'error',\r\n title: `Erro ao editar endereço`,\r\n description: `${error.message}`\r\n })\r\n })\r\n }\r\n }\r\n }\r\n }\r\n\r\n useEffect(() => {\r\n values.cep !== '' && checkCep(values.cep)\r\n // checkCep()\r\n }, [values.cep])\r\n\r\n return (\r\n <>\r\n {load ? : null}\r\n \r\n
    \r\n
    \r\n \r\n \r\n handleCEPChange(e)}\r\n // autoFocus\r\n />\r\n \r\n Não sei meu CEP\r\n \r\n \r\n
    \r\n\r\n
    \r\n \r\n \r\n handleChange(e)}\r\n disabled={values.tipoEndereco === 'C'}\r\n />\r\n \r\n
    \r\n\r\n
    \r\n \r\n \r\n handleChange(e)}\r\n />\r\n \r\n
    \r\n\r\n
    \r\n \r\n \r\n handleNumberChange(e)}\r\n />\r\n \r\n
    \r\n\r\n
    \r\n \r\n \r\n handleChange(e)}\r\n />\r\n \r\n
    \r\n\r\n
    \r\n \r\n \r\n handleChange(e)}\r\n />\r\n \r\n
    \r\n\r\n
    \r\n \r\n \r\n handleChange(e)}\r\n />\r\n \r\n
    \r\n\r\n
    \r\n \r\n \r\n handleChange(e)}\r\n />\r\n \r\n
    \r\n
    \r\n \r\n \r\n handleChange(e)}\r\n />\r\n \r\n
    \r\n\r\n {/* \r\n {\r\n setValues({\r\n ...values,\r\n padrao: !values.padrao\r\n })\r\n }}\r\n />\r\n \r\n */}\r\n
    \r\n
    \r\n \r\n \r\n Salvar Endereço\r\n \r\n setCurrent(0)}\r\n >\r\n Cancelar\r\n \r\n \r\n \r\n )\r\n}\r\n\r\nexport default EditAddressFormModal\r\n","import { useEffect, useRef, useState } from 'react'\r\nimport * as S from './styles'\r\nimport IconClose from '../../assets/icons/icon-close.svg'\r\nimport defaultOptions from '../../api/defaultoption'\r\nimport clientes from '../../api/clientes'\r\nimport AddressCardModal from './AddressCardModal'\r\nimport NewAddressFormModal from './NewAddressFormModal'\r\nimport EditAdressFormModal from './EditAddressFormModal'\r\nimport { useSelector, useDispatch } from 'react-redux'\r\nimport { setEndereco, setPadrao } from '../../store/ducks/endereco'\r\nimport { useToast } from '../../hooks/toast'\r\nimport { isPF, token } from '../../api/auth/auth'\r\n\r\nimport jwt from 'jsonwebtoken'\r\nimport {\r\n allowAddEnderecoEntregaPJ,\r\n allowNewAddress,\r\n getFaturamentoUF,\r\n isInscricaoEstadualIsento\r\n} from '../../utils/validatePJ'\r\n\r\nconst MyAddressModal = ({\r\n showModal,\r\n setShowModal,\r\n setSelectedAddress,\r\n selectedAddress\r\n}) => {\r\n const modalRef = useRef()\r\n const { addToast } = useToast()\r\n\r\n const [loading, setLoading] = useState(false)\r\n const [current, setCurrent] = useState(0)\r\n const [cardId, setCardId] = useState('')\r\n\r\n const dispatch = useDispatch()\r\n const store = useSelector((store) => store)\r\n const addressList = store.endereco.enderecos\r\n\r\n const inscricaoEstadualIsento = store.user.info.inscricaoEstadual === 'ISENTO'\r\n const faturamentoUf = getFaturamentoUF(addressList)\r\n\r\n const closeModal = (e) => {\r\n if (modalRef.current === e.target) {\r\n setShowModal(false)\r\n }\r\n }\r\n\r\n const openModal = (id) => {\r\n setShowModal((prev) => !prev)\r\n setCardId(id)\r\n }\r\n\r\n const isMaxAdressLimit = () => {\r\n if (store.endereco.enderecos.length >= 5) {\r\n addToast({\r\n type: 'error',\r\n title:\r\n 'Máximo de 4 endereços de entrega. Remova algum endereço para adicionar um novo',\r\n timer: 5000\r\n })\r\n return true\r\n }\r\n }\r\n\r\n const validateAddNewAddress = () => {\r\n if (!isMaxAdressLimit()) {\r\n if (\r\n !isPF() &&\r\n !allowNewAddress(\r\n store.endereco.enderecos,\r\n store.user.info.inscricaoEstadual\r\n )\r\n ) {\r\n addToast({\r\n type: 'error',\r\n title:\r\n 'ATENÇÃO: Não é possível cadastrar ou selecionar endereço de entrega com Estado diferente do endereço de faturamento',\r\n timer: 5000\r\n })\r\n return false\r\n } else if (\r\n !isPF() &&\r\n !!allowNewAddress(\r\n store.endereco.enderecos,\r\n store.user.info.inscricaoEstadual\r\n )\r\n ) {\r\n // console.log('Permitir')\r\n setCurrent(1)\r\n } else {\r\n // console.log('Permitir Restante')\r\n setCurrent(1)\r\n }\r\n } else {\r\n addToast({\r\n type: 'error',\r\n title:\r\n 'Máximo de 4 endereços de entrega. Remova algum endereço para adicionar um novo',\r\n timer: 5000\r\n })\r\n }\r\n }\r\n\r\n // const getAddress = async () => {\r\n // let res = await clientes.enderecos(defaultOptions)\r\n // res = await res.json()\r\n // dispatch(setEndereco(res))\r\n // }\r\n\r\n return (\r\n <>\r\n {showModal ? (\r\n \r\n \r\n {/* setShowModal((prev) => !prev)}\r\n /> */}\r\n\r\n {current === 0 || current === 3 ? (\r\n \r\n

    Endereço de Entrega

    \r\n

    Meus Endereços

    \r\n
    \r\n openModal(id)}\r\n setCardId={setCardId}\r\n loading={loading}\r\n setLoading={setLoading}\r\n setSelectedAddress={setSelectedAddress}\r\n inscEstadualIsento={inscricaoEstadualIsento}\r\n allowAddAdressPJ={validateAddNewAddress}\r\n >\r\n
    \r\n\r\n \r\n {\r\n if (!isPF()) {\r\n if (selectedAddress.uf === faturamentoUf) {\r\n // console.log('permitir endereço selecionado')\r\n dispatch(setPadrao(selectedAddress))\r\n localStorage.setItem(\r\n 'localEndereco',\r\n JSON.stringify(selectedAddress)\r\n )\r\n sessionStorage.setItem(\r\n 'localEndereco',\r\n JSON.stringify(selectedAddress)\r\n )\r\n setSelectedAddress('')\r\n\r\n setShowModal((prev) => !prev)\r\n } else if (selectedAddress === '') {\r\n addToast({\r\n type: 'error',\r\n title: 'Selecione um endereço de entrega'\r\n })\r\n } else {\r\n // console.log('block endereço selecionado')\r\n addToast({\r\n type: 'error',\r\n title:\r\n 'ATENÇÃO: Não é possível cadastrar ou selecionar endereço de entrega com Estado diferente do endereço de faturamento',\r\n timer: 5500\r\n })\r\n }\r\n } else if (selectedAddress === '') {\r\n addToast({\r\n type: 'error',\r\n title: 'Selecione um endereço de entrega'\r\n })\r\n } else {\r\n dispatch(setPadrao(selectedAddress))\r\n localStorage.setItem(\r\n 'localEndereco',\r\n JSON.stringify(selectedAddress)\r\n )\r\n sessionStorage.setItem(\r\n 'localEndereco',\r\n JSON.stringify(selectedAddress)\r\n )\r\n setSelectedAddress('')\r\n setShowModal((prev) => !prev)\r\n }\r\n }}\r\n >\r\n Confirmar\r\n \r\n {\r\n setShowModal((prev) => !prev)\r\n }}\r\n >\r\n Cancelar\r\n \r\n \r\n
    \r\n ) : null}\r\n\r\n {current === 1 && (\r\n \r\n

    Adicionar Endereço

    \r\n openModal(id)}\r\n setCardId={setCardId}\r\n loading={loading}\r\n setLoading={setLoading}\r\n inscEstadualIsento={inscricaoEstadualIsento}\r\n faturamentoUF={faturamentoUf}\r\n >\r\n {/* \r\n Confirmar\r\n {\r\n // setShowModal((prev) => !prev)\r\n setCurrent(0)\r\n }}\r\n >\r\n Cancelar\r\n \r\n */}\r\n
    \r\n )}\r\n\r\n {current === 2 && (\r\n \r\n

    Alterar Endereço

    \r\n \r\n
    \r\n )}\r\n\r\n {\r\n setShowModal((prev) => !prev)\r\n setCurrent(0)\r\n }}\r\n >\r\n {/* */}\r\n \"\"\r\n \r\n
    \r\n
    \r\n ) : null}\r\n \r\n )\r\n}\r\n\r\nexport default MyAddressModal\r\n","import styled, { css } from 'styled-components'\r\n\r\nexport const CheckoutSection = styled.section`\r\n padding: 60px 0;\r\n`\r\n\r\nexport const Wrapper = styled.div`\r\n max-width: 1360px;\r\n margin: 0 auto;\r\n position: relative;\r\n width: 100%;\r\n\r\n @media (max-width: 1390px) {\r\n max-width: 95%;\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n .col-pagamento,\r\n .col-envio,\r\n .col-confirmacao,\r\n .col-cotacao,\r\n .col-negociacao {\r\n .col-3 {\r\n width: 35%;\r\n float: left;\r\n }\r\n\r\n .col-9 {\r\n width: 65%;\r\n float: left;\r\n }\r\n }\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n .col-confirmacao {\r\n .col-6 {\r\n width: 100%;\r\n\r\n &:first-child {\r\n padding-right: 0px;\r\n }\r\n\r\n &:nth-child(2) {\r\n padding-left: 0px;\r\n }\r\n }\r\n }\r\n }\r\n\r\n @media (max-width: 800px) {\r\n .col-pagamento,\r\n .col-envio,\r\n .col-confirmacao {\r\n .col-3 {\r\n z-index: 199;\r\n width: 100%;\r\n float: left;\r\n }\r\n\r\n .col-9 {\r\n width: 100%;\r\n float: left;\r\n }\r\n }\r\n }\r\n\r\n @media (max-width: 900px) {\r\n .col-cotacao,\r\n .col-negociacao {\r\n .col-3 {\r\n z-index: 199;\r\n width: 100%;\r\n float: left;\r\n }\r\n\r\n .col-9 {\r\n width: 100%;\r\n float: left;\r\n }\r\n }\r\n }\r\n`\r\n\r\nexport const PageTitle = styled.h2`\r\n font-size: 22px;\r\n font-weight: 500;\r\n margin-bottom: 10px;\r\n`\r\n\r\nexport const PageContent = styled.div`\r\n @media (max-width: 800px) {\r\n margin-bottom: 110px;\r\n }\r\n`\r\n\r\nexport const Tributacao = styled.div`\r\n padding: 0;\r\n /* background-color: tomato; */\r\n\r\n .content-section {\r\n /* background-color: blue; */\r\n }\r\n\r\n .title-tooltip {\r\n h3 {\r\n position: relative;\r\n display: inline-block;\r\n }\r\n }\r\n\r\n .tributacao {\r\n margin-top: 12px;\r\n\r\n p {\r\n margin-bottom: 16px;\r\n margin-top: 8px;\r\n font-size: 15px;\r\n padding-right: 8px;\r\n }\r\n\r\n div {\r\n &:first-child {\r\n display: flex;\r\n align-items: center;\r\n }\r\n\r\n strong {\r\n font-size: 14px;\r\n margin-right: 8px;\r\n }\r\n\r\n label {\r\n margin-left: 8px;\r\n }\r\n }\r\n }\r\n\r\n .cards {\r\n display: flex;\r\n justify-content: space-between;\r\n flex-wrap: wrap;\r\n }\r\n`\r\n\r\nexport const ColGroup = styled.div`\r\n .col-3 {\r\n width: 30%;\r\n }\r\n\r\n .col-9 {\r\n width: 70%;\r\n }\r\n\r\n .col-6 {\r\n padding: 0;\r\n\r\n &:first-child {\r\n padding-right: 8px;\r\n }\r\n\r\n &:nth-child(2) {\r\n padding-left: 10px;\r\n }\r\n }\r\n\r\n .col-resumo {\r\n position: sticky;\r\n top: 20px;\r\n /* right: 0; */\r\n }\r\n\r\n .col-cotacao {\r\n @media (max-width: 800px) {\r\n display: none;\r\n }\r\n }\r\n\r\n .content {\r\n @media (max-width: 800px) {\r\n -ms-box-orient: horizontal;\r\n display: -webkit-box;\r\n display: -moz-box;\r\n display: -ms-flexbox;\r\n display: -moz-flex;\r\n display: -webkit-flex;\r\n display: flex;\r\n\r\n -webkit-flex-flow: column;\r\n flex-flow: column;\r\n\r\n /* display: none; */\r\n\r\n -ms-box-orient: horizontal;\r\n display: -webkit-box;\r\n display: -moz-box;\r\n display: -ms-flexbox;\r\n display: -moz-flex;\r\n display: -webkit-flex;\r\n display: flex;\r\n\r\n -webkit-flex-flow: column;\r\n flex-flow: column;\r\n\r\n .content-item-parent:nth-of-type(1) {\r\n order: 2;\r\n }\r\n .content-item-parent:nth-of-type(2) {\r\n order: 1;\r\n }\r\n .content-item-parent:nth-of-type(3) {\r\n order: 3;\r\n }\r\n }\r\n }\r\n\r\n .col-resumo-confirmacao {\r\n position: sticky;\r\n top: 20px;\r\n\r\n @media (max-width: 800px) {\r\n display: none;\r\n }\r\n }\r\n\r\n .col-resumo-confirmacao-cotacao {\r\n @media (min-width: 801px) {\r\n position: sticky;\r\n top: 20px;\r\n }\r\n @media (max-width: 800px) {\r\n /* display: none; */\r\n\r\n -ms-box-orient: horizontal;\r\n display: -webkit-box;\r\n display: -moz-box;\r\n display: -ms-flexbox;\r\n display: -moz-flex;\r\n display: -webkit-flex;\r\n display: flex;\r\n\r\n -webkit-flex-flow: column;\r\n flex-flow: column;\r\n\r\n .content-item:nth-of-type(1) {\r\n // Resumo Cotação\r\n order: 4;\r\n display: none;\r\n }\r\n .content-item:nth-of-type(2) {\r\n // Endereço de Entrega\r\n order: 1;\r\n }\r\n .content-item:nth-of-type(3) {\r\n // Opções de Envio\r\n order: 2;\r\n }\r\n .content-item:nth-of-type(4) {\r\n // Gimplus\r\n order: 3;\r\n }\r\n .content-item:nth-of-type(5) {\r\n // Cupom de Desconto\r\n order: 3;\r\n }\r\n .content-item:nth-of-type(6) {\r\n //Forma de Pagamento\r\n order: 2;\r\n }\r\n .content-item:nth-of-type(7) {\r\n // Btn Concluir\r\n order: 4;\r\n display: none;\r\n }\r\n .content-item:nth-of-type(8) {\r\n // Btn Voltar\r\n order: 5;\r\n display: none;\r\n }\r\n .content-item:nth-of-type(9) {\r\n // Promotor\r\n order: 6;\r\n display: none;\r\n }\r\n .content-item:nth-of-type(10) {\r\n // Promotor Cotação\r\n order: 6;\r\n display: none;\r\n }\r\n }\r\n }\r\n\r\n .col-resumo-cotacao {\r\n position: sticky;\r\n top: 20px;\r\n\r\n @media (max-width: 800px) {\r\n /* display: none; */\r\n }\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n .col-3 {\r\n width: 100%;\r\n }\r\n\r\n .col-9 {\r\n width: 100%;\r\n }\r\n .col-6 {\r\n width: 50%;\r\n padding: 0;\r\n display: inline-block;\r\n }\r\n }\r\n\r\n @media (max-width: 700px) {\r\n .col-6 {\r\n width: 100%;\r\n padding: 0;\r\n display: block;\r\n\r\n &:first-child {\r\n padding-right: 0px;\r\n }\r\n\r\n &:nth-child(2) {\r\n padding-left: 0px;\r\n }\r\n }\r\n }\r\n`\r\n\r\nexport const CardBox = styled.div`\r\n background: #ffffff;\r\n padding: 10px;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 4px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 20px;\r\n`\r\nexport const Button = styled.button`\r\n ${({ theme, outline }) => css`\r\n border-radius: 5px;\r\n border: 2px solid transparent;\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 500;\r\n font-size: 16px;\r\n padding: 12px 30px;\r\n margin-bottom: 10px;\r\n width: 100%;\r\n text-align: center;\r\n transition: ${theme.transition.default};\r\n cursor: pointer;\r\n background: ${theme.colors.primary};\r\n color: ${theme.colors.white};\r\n\r\n &:hover {\r\n background: #a71e26;\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: $MEDIA-IPAD) {\r\n font-size: 14px;\r\n }\r\n\r\n &.button-outline {\r\n background: transparent;\r\n border: 2px solid ${theme.colors.primary};\r\n color: ${theme.colors.primary};\r\n\r\n &:hover {\r\n border-color: #4a4a4a;\r\n color: #4a4a4a;\r\n }\r\n\r\n &:disabled {\r\n color: #7b7b7b;\r\n border-color: #7b7b7b;\r\n cursor: initial;\r\n }\r\n }\r\n\r\n ${!!outline &&\r\n css`\r\n background: transparent;\r\n border: 2px solid ${theme.colors.primary};\r\n color: ${theme.colors.primary};\r\n cursor: pointer;\r\n\r\n &:hover {\r\n border-color: #4a4a4a;\r\n color: #4a4a4a;\r\n background: #fff;\r\n }\r\n `}\r\n\r\n @media (max-width: 1170px) {\r\n & + .button {\r\n margin-left: 0;\r\n margin-top: 8px;\r\n }\r\n }\r\n `}\r\n`\r\nexport const FinalizadoST = styled.p`\r\n ${({ theme }) => css`\r\n color: ${theme.colors.primary};\r\n margin: 10px;\r\n text-align: center;\r\n margin-bottom: 20px;\r\n `}\r\n`\r\n\r\nexport const AvaliacaoGimba = styled.div`\r\n display: flex;\r\n flex-direction: column;\r\n justify-content: center;\r\n align-items: center;\r\n\r\n #PesquisaTrackSales {\r\n width: 100%;\r\n display: block;\r\n max-width: 630px;\r\n }\r\n`\r\n","import styled, { css, keyframes } from 'styled-components'\r\nimport IconInputError from '../../assets/icons/icon-input-error.svg'\r\nimport IconInputSuccess from '../../assets/icons/icon-input-success.svg'\r\nimport IconVisa from '../../assets/img/pagamento/cartao-visa.svg'\r\nimport IconAmex from '../../assets/img/pagamento/cartao-amex.svg'\r\nimport IconMaster from '../../assets/img/pagamento/cartao-mastercard.svg'\r\nimport IconDiners from '../../assets/img/pagamento/cartao-diners.svg'\r\nimport IconElo from '../../assets/img/pagamento/cartao-elo.svg'\r\nimport IconCartao from '../../assets/img/pagamento/cartao-default.svg'\r\n\r\nexport const Register = styled.section`\r\n background: #fff;\r\n`\r\nexport const ProfileTitle = styled.h2`\r\n font-size: 22px;\r\n margin-bottom: 20px;\r\n color: #555;\r\n`\r\n\r\nconst showModal = keyframes`\r\n from {\r\n opacity: 0;\r\n } to {\r\n opacity: 1;\r\n }\r\n`\r\n\r\nexport const Background = styled.div`\r\n width: 100%;\r\n height: 100%;\r\n background: rgba(0, 0, 0, 0.7);\r\n transition: background 0.2s;\r\n position: fixed;\r\n top: 0;\r\n left: 0;\r\n display: flex;\r\n justify-content: center;\r\n align-items: center;\r\n z-index: 199;\r\n animation: ${showModal} 200ms;\r\n`\r\n\r\nexport const WrapperSmall = styled.div`\r\n ${({ theme }) => css`\r\n max-width: 400px;\r\n padding: 32px;\r\n position: relative;\r\n\r\n display: flex;\r\n flex-direction: column;\r\n border-radius: 5px;\r\n\r\n background: #fff;\r\n color: #000;\r\n box-shadow: 0 5px 16px rgba(0, 0, 0, 0.2);\r\n text-align: center;\r\n z-index: 200;\r\n\r\n @media (max-width: 560px) {\r\n max-width: 90%;\r\n margin: auto;\r\n }\r\n\r\n p {\r\n font-size: 16px;\r\n line-height: 20px;\r\n margin-bottom: 16px;\r\n\r\n &:last-child {\r\n margin-bottom: 0;\r\n }\r\n }\r\n\r\n strong {\r\n font-weight: 600;\r\n }\r\n\r\n .modal-title {\r\n font-size: 24px;\r\n font-weight: 600;\r\n margin-bottom: 16px;\r\n color: ${theme.colors.primary};\r\n }\r\n\r\n .numero {\r\n font-size: 24px;\r\n line-height: 30px;\r\n text-decoration: underline;\r\n }\r\n\r\n .cotacao-st {\r\n font-size: 14px;\r\n color: ${theme.colors.primary};\r\n }\r\n\r\n .modal-description {\r\n margin-bottom: 16px;\r\n }\r\n\r\n .button-container {\r\n display: flex;\r\n }\r\n `}\r\n`\r\n\r\nexport const RegisterCard = styled.div`\r\n ${({ theme, type }) => css`\r\n background: #ffffff;\r\n\r\n ${type === 'insideModal' &&\r\n css`\r\n border: none;\r\n box-shadow: none;\r\n padding: 0;\r\n margin-bottom: 0;\r\n `}\r\n\r\n p {\r\n margin-bottom: 20px;\r\n margin-top: 0;\r\n }\r\n\r\n label {\r\n font-weight: 500;\r\n text-align: left;\r\n\r\n @media (max-width: 600px) {\r\n font-size: 14px;\r\n }\r\n }\r\n\r\n small {\r\n margin-bottom: 5px;\r\n font-size: 13px;\r\n line-height: 22px;\r\n }\r\n\r\n h3 {\r\n font-size: 26px;\r\n font-weight: 500;\r\n margin-bottom: 16px;\r\n }\r\n\r\n form div {\r\n /* margin-bottom: 16px; */\r\n }\r\n\r\n form {\r\n .cvv p {\r\n font-size: 12px;\r\n text-align: left;\r\n }\r\n }\r\n\r\n [type='checkbox']:not(:checked) + label::after,\r\n [type='checkbox']:checked + label::after {\r\n left: 4px;\r\n }\r\n\r\n @media (max-width: 600px) {\r\n min-width: 100%;\r\n /* padding: 32px 20px 12px 20px; */\r\n }\r\n `}\r\n`\r\n\r\nexport const Title = styled.h2`\r\n font-weight: 500;\r\n color: #333;\r\n margin-bottom: 12px;\r\n text-align: left;\r\n background-color: blue;\r\n font-size: 34px;\r\n\r\n @media (max-width: 1170px) {\r\n font-size: 18px;\r\n text-align: left;\r\n }\r\n`\r\n\r\nexport const CardImage = styled.div`\r\n ${({ cartao }) => css`\r\n background-repeat: no-repeat;\r\n background-size: cover;\r\n background-position: center;\r\n background-size: contain;\r\n display: flex;\r\n width: 81px;\r\n margin-left: 8px;\r\n margin-bottom: 0px !important;\r\n\r\n ${cartao === undefined || cartao === null\r\n ? css`\r\n background-image: url(${IconCartao});\r\n `\r\n : null}\r\n\r\n ${cartao === 'amex' &&\r\n css`\r\n background-image: url(${IconAmex});\r\n `}\r\n\r\n ${cartao === 'mastercard' &&\r\n css`\r\n background-image: url(${IconMaster});\r\n `}\r\n\r\n ${cartao === 'visa' &&\r\n css`\r\n background-image: url(${IconVisa});\r\n `}\r\n\r\n ${cartao === 'elo' &&\r\n css`\r\n background-image: url(${IconElo});\r\n `}\r\n\r\n ${cartao === 'diners' &&\r\n css`\r\n background-image: url(${IconDiners});\r\n `}\r\n `}\r\n`\r\n\r\nexport const Input = styled.input`\r\n ${({ theme }) => css`\r\n border: 1px solid #afaeae;\r\n border-radius: 6px;\r\n padding: 15px 15px;\r\n width: 100%;\r\n transition: all 400ms;\r\n\r\n &::placeholder {\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 400;\r\n color: #afaeae;\r\n }\r\n\r\n &:focus {\r\n border-color: ${theme.colors.primary};\r\n }\r\n\r\n // Feedbacks.\r\n &.input-success {\r\n background: ${theme.colors.backgroundSuccess} url(${IconInputSuccess})\r\n right 10px center no-repeat !important;\r\n border-color: ${theme.colors.success};\r\n }\r\n\r\n &.input-error {\r\n background: ${theme.colors.backgroundError} url(${IconInputError}) right\r\n 10px center no-repeat !important;\r\n border-color: ${theme.colors.error};\r\n }\r\n `}\r\n`\r\n\r\nexport const ProfileBoxFooter = styled.div`\r\n display: flex;\r\n flex-direction: column;\r\n padding: 0;\r\n`\r\n\r\nexport const Button = styled.button`\r\n ${({ theme, type }) => css`\r\n max-width: 200px;\r\n width: 100%;\r\n\r\n border-radius: 5px;\r\n border: 2px solid transparent;\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 500;\r\n font-size: 16px;\r\n padding: 12px 30px;\r\n margin-bottom: 10px;\r\n width: 100%;\r\n text-align: center;\r\n transition: ${theme.transition.default};\r\n cursor: pointer;\r\n background: ${theme.colors.primary};\r\n color: ${theme.colors.white};\r\n\r\n &.white {\r\n background: #fff;\r\n color: #707070;\r\n font-weight: 400;\r\n\r\n &:hover {\r\n background: #fff;\r\n }\r\n }\r\n\r\n &:hover {\r\n background: #a71e26;\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: ${theme.media.cel}) {\r\n font-size: 14px;\r\n }\r\n\r\n &.button-outline {\r\n max-width: 146px;\r\n background: transparent;\r\n border: 2px solid #8f8f8f;\r\n color: #8f8f8f;\r\n\r\n &:hover {\r\n border-color: #4a4a4a;\r\n color: #4a4a4a;\r\n }\r\n\r\n &:disabled {\r\n color: #7b7b7b;\r\n border-color: #7b7b7b;\r\n cursor: initial;\r\n }\r\n }\r\n\r\n ${type === 'insideModal' &&\r\n css`\r\n max-width: 100%;\r\n background: ${theme.colors.cart};\r\n /* background: ${theme.colors.primary}; */\r\n margin-right: 0;\r\n margin-bottom: 0;\r\n\r\n &:hover {\r\n background: #33a161;\r\n /* background: #a71e26; */\r\n }\r\n `}\r\n\r\n @media (max-width: 1170px) {\r\n & + .button {\r\n margin-left: 0;\r\n margin-top: 8px;\r\n }\r\n }\r\n `}\r\n`\r\n","export default __webpack_public_path__ + \"static/media/icon-cvv.a003a49d.svg\";","import { useState } from 'react'\r\nimport { useToast } from '../../hooks/toast'\r\nimport * as Yup from 'yup'\r\nimport TextField from '../TextField'\r\nimport Loader from '../Loader'\r\nimport { FormGroup } from '../Form/styles'\r\nimport * as S from './styles'\r\n\r\nimport { onlyNumber } from '../../utils/utils'\r\nimport IconCVV from '../../assets/img/pagamento/icon-cvv.svg'\r\nimport { useSelector, useDispatch } from 'react-redux'\r\nimport { setCvv } from '../../store/ducks/pagamento'\r\nimport { validateCVV } from '../../utils/creditCardValidation'\r\n\r\nconst FormCVV = ({\r\n type,\r\n cancelar,\r\n setPaymentModal,\r\n current,\r\n router = () => undefined,\r\n setCurrent = () => undefined\r\n}) => {\r\n const { addToast } = useToast()\r\n const [values, setValues] = useState({\r\n cardCvv: ''\r\n })\r\n\r\n const [load, setLoad] = useState(false)\r\n const [inputErrors, setInputErrors] = useState(false)\r\n\r\n const [isCVVNumberValid, setIsCVVNumberValid] = useState(true)\r\n\r\n const store = useSelector((store) => store)\r\n const dispatch = useDispatch()\r\n\r\n // console.log(store)\r\n\r\n const handleCVVChange = (e) => {\r\n const { name, value } = e.target\r\n setValues({\r\n ...values,\r\n [name]: onlyNumber(value)\r\n })\r\n\r\n if (values.cardCvv.length > 0) {\r\n validateCVV(value, store?.pagamento?.pick?.bandeira)\r\n ? setIsCVVNumberValid(true)\r\n : setIsCVVNumberValid(false)\r\n }\r\n\r\n setInputErrors({\r\n ...inputErrors,\r\n [name]: ''\r\n })\r\n }\r\n\r\n const formData = {\r\n cardCvv: values.cardCvv\r\n }\r\n\r\n const passSchema = Yup.object().shape({\r\n cardCvv: Yup.string().required('Campo obrigatório*')\r\n })\r\n\r\n const handleSubmit = async (event) => {\r\n event.preventDefault()\r\n // setLoad(true)\r\n try {\r\n await passSchema.validate(formData, {\r\n abortEarly: false\r\n })\r\n if (!!isCVVNumberValid) {\r\n dispatch(setCvv(values.cardCvv))\r\n setCurrent()\r\n return router()\r\n }\r\n } catch (err) {\r\n if (err) setLoad(false)\r\n\r\n if (err instanceof Yup.ValidationError) {\r\n const emptyField = Object.values(err.value).every(\r\n (value) => value !== ''\r\n )\r\n\r\n if (!emptyField) {\r\n addToast({\r\n type: 'error',\r\n title: 'Todos os campos devem ser preenchidos'\r\n })\r\n\r\n const errorArray = err.inner.map(({ path, message }) => {\r\n return {\r\n name: path,\r\n message: message\r\n }\r\n })\r\n\r\n const objeto = errorArray.reduce((acc, d) => {\r\n acc[d.name] = d.message\r\n\r\n return acc\r\n }, {})\r\n\r\n setInputErrors(objeto)\r\n } else {\r\n setLoad(false)\r\n err.inner.map((error) => {\r\n addToast({\r\n type: 'error',\r\n title: `${error.message}`\r\n })\r\n })\r\n }\r\n }\r\n }\r\n }\r\n\r\n return (\r\n \r\n \r\n
    \r\n \"Ícone\r\n

    Código de Segurança

    \r\n
    \r\n

    \r\n Para concluir a transação, digite o{' '}\r\n código de segurança (CVV) do seu cartão.\r\n

    \r\n\r\n \r\n {!!load && }\r\n\r\n
    \r\n
    \r\n \r\n \r\n\r\n
    \r\n \r\n
    \r\n
    \r\n
    \r\n
    \r\n
    \r\n\r\n \r\n
    \r\n {\r\n handleSubmit(e)\r\n }}\r\n >\r\n Confirmar\r\n \r\n
    \r\n
    \r\n {\r\n setCurrent()\r\n }}\r\n >\r\n Voltar\r\n \r\n
    \r\n
    \r\n
    \r\n
    \r\n )\r\n}\r\n\r\nexport default FormCVV\r\n","import styled, { css, keyframes } from 'styled-components'\r\n\r\nconst showModal = keyframes`\r\n from {\r\n opacity: 0;\r\n } to {\r\n opacity: 1;\r\n }\r\n`\r\n\r\nexport const Background = styled.div`\r\n width: 100%;\r\n height: 100%;\r\n background: rgba(0, 0, 0, 0.7);\r\n transition: background 0.2s;\r\n position: fixed;\r\n display: flex;\r\n justify-content: center;\r\n align-items: center;\r\n z-index: 100;\r\n animation: ${showModal} 200ms;\r\n`\r\n\r\nexport const ModalWrapper = styled.div`\r\n max-width: 420px;\r\n width: 100%;\r\n display: flex;\r\n flex-direction: column;\r\n box-shadow: 0 5px 16px rgba(0, 0, 0, 0.2);\r\n background: #fff;\r\n color: #000;\r\n position: relative;\r\n text-align: left;\r\n z-index: 10;\r\n border-radius: 5px;\r\n padding: 24px;\r\n\r\n @media (max-width: 560px) {\r\n max-width: 90%;\r\n margin: auto;\r\n }\r\n\r\n ${({ theme }) => css`\r\n .title {\r\n display: flex;\r\n margin-bottom: 4px;\r\n }\r\n\r\n img {\r\n margin-right: 8px;\r\n width: 28px;\r\n height: 28px;\r\n filter: invert(22%) sepia(78%) saturate(2710%) hue-rotate(341deg)\r\n brightness(88%) contrast(96%);\r\n }\r\n\r\n .modal-title {\r\n font-size: 24px;\r\n font-weight: 500;\r\n margin-bottom: 4px;\r\n color: ${theme.colors.primary};\r\n }\r\n\r\n .modal-description {\r\n margin-bottom: 16px;\r\n }\r\n\r\n .button-container {\r\n display: flex;\r\n }\r\n `}\r\n`\r\n\r\nexport const Button = styled.button`\r\n ${({ theme }) => css`\r\n max-width: 200px;\r\n width: 100%;\r\n margin-right: 12px;\r\n\r\n border-radius: 5px;\r\n border: 2px solid transparent;\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 500;\r\n font-size: 16px;\r\n padding: 8px 40px;\r\n width: 100%;\r\n text-align: center;\r\n transition: ${theme.transition.default};\r\n cursor: pointer;\r\n background: ${theme.colors.primary};\r\n color: ${theme.colors.white};\r\n\r\n &:hover {\r\n background: #a71e26;\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: $MEDIA-IPAD) {\r\n font-size: 14px;\r\n }\r\n\r\n &.button-outline {\r\n background: transparent;\r\n border: 2px solid ${theme.colors.primary};\r\n color: ${theme.colors.primary};\r\n\r\n &:hover {\r\n border-color: #4a4a4a;\r\n color: #4a4a4a;\r\n }\r\n\r\n &:disabled {\r\n color: #7b7b7b;\r\n border-color: #7b7b7b;\r\n cursor: initial;\r\n }\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n & + .button {\r\n margin-left: 0;\r\n margin-top: 8px;\r\n }\r\n }\r\n `}\r\n`\r\n","import { useRef } from 'react'\r\nimport { useToast } from '../../../hooks/toast'\r\nimport { Background, ModalWrapper, Button } from './styles'\r\nimport IconAlert from '../../../assets/icons/icon-alert-alert.svg'\r\nimport pagamento from '../../../api/pagamento'\r\nimport { getFormas } from '../../../pages/Pagamento/fetch'\r\nimport { setPagamento } from '../../../store/ducks/pagamento'\r\nimport { useDispatch, useSelector } from 'react-redux'\r\n\r\nconst DeleteCardModal = ({\r\n showModal,\r\n setShowModal,\r\n setCurrent,\r\n current,\r\n cardId,\r\n setLoading\r\n}) => {\r\n const modalRef = useRef()\r\n const { addToast } = useToast()\r\n\r\n const dispatch = useDispatch()\r\n const store = useSelector((store) => store)\r\n\r\n const closeModal = (e) => {\r\n if (modalRef.current === e.target) {\r\n setShowModal(false)\r\n }\r\n }\r\n\r\n const handleMockDeleteCard = async () => {\r\n setLoading(true)\r\n\r\n await pagamento\r\n .delCartao(cardId)\r\n .then((response) => {\r\n if (response) setLoading(false)\r\n\r\n if (response.ok) {\r\n addToast({\r\n type: 'success',\r\n title: 'Cartão excluído'\r\n })\r\n getFormas(\r\n store.endereco.padrao.id,\r\n store.envio.fretePick,\r\n (res) => dispatch(setPagamento(res)),\r\n () => undefined,\r\n store\r\n )\r\n } else if (response.status !== 200) {\r\n setLoading(false)\r\n addToast({\r\n type: 'error',\r\n title: 'Erro ao excluir Cartão'\r\n })\r\n }\r\n })\r\n .catch((error) => {\r\n if (error) setLoading(false)\r\n addToast({\r\n type: 'error',\r\n title: 'Erro ao excluir Cartão',\r\n description: `${error}`\r\n })\r\n })\r\n setShowModal(false)\r\n }\r\n\r\n return (\r\n <>\r\n {showModal ? (\r\n \r\n \r\n
    \r\n

    Remover Cartão

    \r\n
    \r\n

    Deseja remover este cartão?

    \r\n
    \r\n \r\n setShowModal((prev) => !prev)}\r\n >\r\n Cancelar\r\n \r\n
    \r\n
    \r\n
    \r\n ) : null}\r\n \r\n )\r\n}\r\n\r\nexport default DeleteCardModal\r\n","/* eslint-disable react-hooks/exhaustive-deps */\r\nimport { useEffect, useState } from 'react'\r\nimport Header from '../../components/Header'\r\nimport MediaMatch from '../../components/MediaMatch'\r\nimport PaymentForm from '../../components/PaymentCards'\r\nimport ResumoPedido from '../../components/ResumoPedido'\r\nimport Steps from '../../components/Steps'\r\nimport PaymentCardsModal from '../../components/PaymentCardsModal'\r\nimport FormAddNewCreditCardModal from '../../components/FormAddNewCreditCardModal'\r\nimport MyAddressModal from '../../components/MyAddressModal'\r\nimport { useSelector, useDispatch } from 'react-redux'\r\nimport * as S from '../../styles/checkout'\r\nimport { getFormas, getFormasSeller } from './fetch'\r\nimport {\r\n setPagamento,\r\n setPagamentoSeller,\r\n setPick\r\n} from '../../store/ducks/pagamento'\r\nimport Loader from '../../components/Loader'\r\nimport FormCVV from '../../components/FormCVV'\r\nimport { useHistory } from 'react-router-dom'\r\nimport { token } from '../../api/auth/auth'\r\nimport DeleteCardModal from '../../components/PaymentCards/DeleteCardModal'\r\nimport jwt from 'jsonwebtoken'\r\nimport { estadosST } from '../../utils/estadosST'\r\nimport { checkGovernoPj, checkRevendaPj } from '../../utils/validatePJ'\r\nimport { getLocalStorageLog } from '../../utils/traceLogAcessos'\r\nimport { useLocation } from 'react-router-dom'\r\n\r\nconst Pagamento = () => {\r\n const router = useHistory()\r\n const [load, setLoad] = useState(false)\r\n const [retry, setRetry] = useState(0)\r\n const [showModal, setShowModal] = useState(false)\r\n const [showDeleteModal, setShowDeleteModal] = useState(false)\r\n const [cvvModal, setCvvModal] = useState(false)\r\n const [ipAddress, setIpAddress] = useState('')\r\n\r\n const [cardId, setCardId] = useState('')\r\n\r\n const openModal = () => {\r\n setShowModal((prev) => !prev)\r\n }\r\n\r\n const openDeleteModal = (id) => {\r\n setShowDeleteModal((prev) => !prev)\r\n setCardId(id)\r\n }\r\n\r\n const store = useSelector((store) => store)\r\n const dispatch = useDispatch()\r\n\r\n const user = jwt.decode(token())\r\n\r\n const checkEstadoST = () => {\r\n return estadosST.some((item) => item === store.endereco.padrao.uf)\r\n }\r\n\r\n const location = useLocation()\r\n\r\n useEffect(() => {\r\n window.dataLayer = window.dataLayer || []\r\n getLocalStorageLog(location.pathname)\r\n\r\n window.dataLayer.push({\r\n event: '/pagamento'\r\n })\r\n\r\n // console.log(window.dataLayer)\r\n }, [])\r\n\r\n useEffect(() => {\r\n if (!!!store.endereco.padrao.id) router.push(`/?token=${token()}`)\r\n getFormas(\r\n store.endereco.padrao.id,\r\n store.envio.fretePick,\r\n (res) => dispatch(setPagamento(res)),\r\n setLoad,\r\n store,\r\n store.pagamento.st.icms !== undefined,\r\n store.pagamento.st.destinoFiscal !== 'revenda'\r\n )\r\n setRetry(retry + 1)\r\n if (\r\n store.envio.resumo?.Carrinho?.filter((e) => e.SellerId == null).length > 0\r\n ) {\r\n getFormasSeller(\r\n store.endereco.padrao.id,\r\n store.envio.fretePick,\r\n (res) => dispatch(setPagamentoSeller(res)),\r\n setLoad,\r\n store\r\n )\r\n }\r\n // eslint-disable-next-line react-hooks/exhaustive-deps\r\n }, [])\r\n\r\n useEffect(() => {\r\n if (!!!store.pagamento.pagamento.Formas && retry > 0 && retry < 3) {\r\n getFormas(\r\n store.endereco.padrao.id,\r\n store.envio.fretePick,\r\n (res) => dispatch(setPagamento(res)),\r\n setLoad,\r\n store,\r\n store.pagamento.st.icms !== undefined,\r\n store.pagamento.st.destinoFiscal !== 'revenda'\r\n )\r\n setRetry(retry + 1)\r\n }\r\n if (store.pagamento.pick.id !== undefined) {\r\n dispatch(setPick({ ...store.pagamento.pick }))\r\n }\r\n // eslint-disable-next-line react-hooks/exhaustive-deps\r\n }, [store.pagamento.pagamento])\r\n\r\n useEffect(() => {\r\n getFormas(\r\n store.endereco.padrao.id,\r\n store.envio.fretePick,\r\n (res) => dispatch(setPagamento(res)),\r\n setLoad,\r\n store,\r\n store.pagamento.st.icms !== undefined,\r\n store.pagamento.st.destinoFiscal !== 'revenda'\r\n )\r\n }, [store.pagamento.condicaoIndex])\r\n\r\n const cartoes = store.pagamento.pagamento.CartoesSalvos?.map((e, i) => ({\r\n id: e.IdCartao,\r\n bandeira: e.Brand,\r\n descricao: e.DescricaoFormaPagamento,\r\n numero: e.MaskedNumber.slice(-4),\r\n vencimento: '',\r\n padrao: false\r\n }))\r\n\r\n const cartoesSeller = store.pagamento.pagamentoSeller.CartoesSalvos?.map(\r\n (e, i) => ({\r\n id: e.IdCartao,\r\n bandeira: e.Brand,\r\n descricao: e.DescricaoFormaPagamento,\r\n numero: e.MaskedNumber.slice(-4),\r\n vencimento: '',\r\n padrao: false\r\n })\r\n )\r\n\r\n const formas = store.pagamento.pagamento?.Formas\r\n const formasSeller = store.pagamento.pagamentoSeller?.Formas\r\n\r\n return (\r\n <>\r\n {load && }\r\n {cvvModal && (\r\n setCvvModal(false)}\r\n router={() => router.push('/confirmacao')}\r\n type=\"insideModal\"\r\n />\r\n )}\r\n\r\n \r\n\r\n \r\n\r\n
    \r\n \r\n \r\n\r\n \r\n Pagamento\r\n \r\n \r\n {/* CONTEÚDO PRINCIPAL DA PÁGINA */}\r\n openModal()}\r\n removeCard={openDeleteModal}\r\n cardData={cartoes}\r\n formas={formas}\r\n formasSeller={formasSeller}\r\n cardDataSeller={cartoesSeller}\r\n revenda={checkRevendaPj(store.user.info)}\r\n governo={checkGovernoPj(store.user.info)}\r\n estadosST={checkEstadoST}\r\n />\r\n {/* CONTEÚDO PRINCIPAL DA PÁGINA */}\r\n \r\n\r\n {/* COLUNA - RESUMO DO PEDIDO */}\r\n
    \r\n \r\n
    \r\n {/* COLUNA - RESUMO DO PEDIDO */}\r\n
    \r\n
    \r\n
    \r\n \r\n )\r\n}\r\nexport default Pagamento\r\n","import styled, { css } from 'styled-components'\r\n\r\nexport const ProfileTitle = styled.h2`\r\n font-size: 22px;\r\n margin-bottom: 20px;\r\n color: #555;\r\n`\r\n\r\nexport const Wrapper = styled.div``\r\n\r\nexport const CardWrapper = styled.div`\r\n @media (min-width: 1170px) {\r\n .col-6 {\r\n width: 50%;\r\n }\r\n }\r\n`\r\n\r\nexport const CardBox = styled.div`\r\n padding: 2px 16px;\r\n height: 70px;\r\n display: flex;\r\n align-items: center;\r\n\r\n background: #ffffff;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 5px;\r\n\r\n margin-bottom: 8px;\r\n\r\n .iconCredit {\r\n width: 40px;\r\n display: flex;\r\n align-items: center;\r\n }\r\n`\r\n\r\nexport const MainCard = styled.div`\r\n max-width: 40px;\r\n height: 100%;\r\n width: 100%;\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n position: relative;\r\n\r\n label {\r\n max-width: 40px;\r\n max-height: 40px;\r\n display: flex;\r\n align-items: center;\r\n margin-top: -18px;\r\n }\r\n`\r\n\r\nexport const CardInfo = styled.div`\r\n justify-self: left;\r\n font-size: 14px;\r\n margin-left: 8px;\r\n margin-right: 8px;\r\n width: 240px;\r\n\r\n p > p {\r\n color: #707070;\r\n }\r\n\r\n div {\r\n padding-right: 64px;\r\n line-height: 1.02;\r\n }\r\n\r\n strong {\r\n font-weight: 600;\r\n }\r\n\r\n select.parcelas {\r\n padding: 6px 30px 6px 16px;\r\n margin-bottom: -10px;\r\n }\r\n`\r\nexport const CardInfoTitle = styled.p`\r\n margin-bottom: 4px;\r\n color: #d22630;\r\n font-weight: 600;\r\n font-size: 15px;\r\n`\r\nexport const Gratis = styled.p`\r\n background-color: #d22630;\r\n color: white;\r\n padding: 3px 7px;\r\n border-radius: 5px;\r\n`\r\n\r\nexport const CardIcon = styled.a`\r\n transition: all 400ms;\r\n max-width: 60px;\r\n font-size: 14px;\r\n max-height: 21px;\r\n position: absolute;\r\n right: 27px;\r\n\r\n & img {\r\n width: 18px;\r\n height: 21px;\r\n cursor: pointer;\r\n\r\n &:hover {\r\n filter: invert(22%) sepia(78%) saturate(2710%) hue-rotate(341deg)\r\n brightness(88%) contrast(96%);\r\n }\r\n }\r\n`\r\n","import * as S from './styles'\r\nimport { precoMask } from '../../../utils/utils'\r\nimport { useDispatch } from 'react-redux'\r\nimport { setFretePick } from '../../../store/ducks/envio'\r\nimport { useToast } from '../../../hooks/toast'\r\n\r\nconst CreditCard = ({ data, agenda, check, setCheck, seller }) => {\r\n const dispatch = useDispatch()\r\n const { addToast } = useToast()\r\n\r\n const isFreteInvalid =\r\n seller !== 'Gimba' &&\r\n (!data?.NomeMetodoEntrega || !data?.IdNomeMetodoEntrega)\r\n\r\n return (\r\n <>\r\n \r\n \r\n \r\n \r\n {\r\n // console.log(data)\r\n if (isFreteInvalid) {\r\n addToast({\r\n type: 'error',\r\n title: `Opção de frete ${data?.name} indisponível`,\r\n description:\r\n 'Entre em contato com nossa central de atendimento.',\r\n timer: 6000,\r\n keep: true\r\n })\r\n } else {\r\n dispatch(setFretePick(seller, data))\r\n }\r\n }}\r\n />\r\n \r\n \r\n \r\n {data?.name}\r\n
    \r\n Em até {data?.time} dia(s) úteis, após liberação de crédito\r\n
    \r\n
    \r\n\r\n \r\n {seller !== 'Gimba' && isFreteInvalid ? (\r\n 'Frete inválido'\r\n ) : data?.value === 0 ? (\r\n Grátis\r\n ) : (\r\n

    {precoMask(data?.value)}

    \r\n )}\r\n
    \r\n
    \r\n
    \r\n
    \r\n \r\n )\r\n}\r\n\r\nexport default CreditCard\r\n","export default __webpack_public_path__ + \"static/media/icon-calendar.0cfd435d.svg\";","import { shade } from 'polished'\r\nimport styled, { css } from 'styled-components'\r\nimport IconCalendar from '../../assets/img/icon-calendar.svg'\r\n\r\nexport const CalendarWrapper = styled.aside`\r\n ${({ theme, rightSide }) => css`\r\n input {\r\n font-family: 'Montserrat';\r\n font-size: 13px;\r\n font-weight: 400;\r\n padding: 8px 16px 8px 8px;\r\n background: url(${IconCalendar}) right 16px center no-repeat;\r\n background-size: 15px;\r\n border-radius: 4px;\r\n border: 1px solid #ced4d4;\r\n\r\n &::placeholder {\r\n color: #707070;\r\n }\r\n }\r\n\r\n ${!!rightSide &&\r\n css`\r\n .react-datepicker-popper {\r\n z-index: 1000;\r\n\r\n @media (min-width: 800px) {\r\n left: -220px !important;\r\n }\r\n }\r\n `}\r\n\r\n .react-datepicker {\r\n font-size: 14px;\r\n font-family: 'MontSerrat';\r\n border: 0;\r\n border-radius: 0;\r\n filter: drop-shadow(0px 0px 4px rgba(0, 0, 0, 0.25));\r\n }\r\n\r\n //Exibir somente dias do mês vigente\r\n .react-datepicker__day--outside-month {\r\n visibility: hidden;\r\n }\r\n\r\n .react-datepicker__navigation {\r\n background: none;\r\n line-height: 1.7rem;\r\n text-align: center;\r\n cursor: pointer;\r\n position: absolute;\r\n top: 10px;\r\n width: 0;\r\n padding: 0;\r\n border: 0.75rem solid transparent;\r\n z-index: 1;\r\n height: 10px;\r\n width: 10px;\r\n text-indent: -999em;\r\n overflow: hidden;\r\n }\r\n\r\n ${!!rightSide &&\r\n css`\r\n .react-datepicker__triangle {\r\n @media (min-width: 800px) {\r\n left: 256px !important;\r\n }\r\n }\r\n `}\r\n\r\n .react-datepicker-popper[data-placement^='top']\r\n .react-datepicker__triangle::before,\r\n .react-datepicker__year-read-view--down-arrow::before,\r\n .react-datepicker__month-read-view--down-arrow::before,\r\n .react-datepicker__month-year-read-view--down-arrow::before {\r\n bottom: -1px;\r\n border-top-color: rgba(0, 0, 0, 0.05);\r\n }\r\n\r\n .react-datepicker-popper[data-placement^='bottom']\r\n .react-datepicker__triangle,\r\n .react-datepicker-popper[data-placement^='bottom']\r\n .react-datepicker__triangle::before {\r\n border-top: none;\r\n /* display: none; */\r\n border-bottom-color: ${theme.colors.primary};\r\n top: 2px;\r\n }\r\n\r\n .react-datepicker__navigation--next {\r\n border-left-color: white;\r\n }\r\n\r\n .react-datepicker__navigation--previous {\r\n border-right-color: white;\r\n }\r\n\r\n .react-datepicker__month-container {\r\n }\r\n\r\n .react-datepicker__header {\r\n text-align: center;\r\n background-color: ${theme.colors.primary};\r\n border-top-left-radius: 0.3rem;\r\n padding-top: 0px;\r\n position: relative;\r\n border: none;\r\n }\r\n\r\n .react-datepicker__current-month {\r\n font-size: 16px;\r\n color: #fff;\r\n font-weight: 500;\r\n text-transform: capitalize;\r\n padding: 8px;\r\n /* margin-top: -5px; */\r\n\r\n //Tirar cabeçalho mês\r\n /* display: none; */\r\n }\r\n\r\n .react-datepicker__day-names {\r\n padding: 8px;\r\n display: flex;\r\n justify-content: space-around;\r\n font-weight: 400;\r\n background-color: #fff;\r\n text-transform: capitalize;\r\n }\r\n\r\n .react-datepicker__day-name {\r\n color: #aab1c2;\r\n width: 36px;\r\n display: inline;\r\n }\r\n\r\n .react-datepicker__month {\r\n margin: 0 12px;\r\n }\r\n\r\n .react-datepicker__day {\r\n font-size: 16px;\r\n width: 36px;\r\n height: 36px;\r\n margin: 4px;\r\n font-weight: 500;\r\n line-height: 20px;\r\n display: inline-flex;\r\n justify-content: center;\r\n align-items: center;\r\n border-radius: 50%;\r\n }\r\n\r\n .react-datepicker__day--today {\r\n font-weight: 600;\r\n }\r\n\r\n .react-datepicker__day--today:focus {\r\n color: white;\r\n font-weight: 600;\r\n }\r\n\r\n .react-datepicker__day--disabled,\r\n .react-datepicker__month-text--disabled,\r\n .react-datepicker__quarter-text--disabled,\r\n .react-datepicker__year-text--disabled {\r\n color: #aab1c2;\r\n background: transparent !important;\r\n font-weight: 400;\r\n }\r\n\r\n .react-datepicker__day--disabled:hover,\r\n .react-datepicker__month-text--disabled:hover,\r\n .react-datepicker__quarter-text--disabled:hover,\r\n .react-datepicker__year-text--disabled:hover {\r\n color: #aab1c2;\r\n background-color: #fff;\r\n font-weight: 400;\r\n }\r\n\r\n .react-datepicker__day--selected,\r\n .react-datepicker__day--in-selecting-range,\r\n .react-datepicker__day--in-range,\r\n .react-datepicker__month-text--selected,\r\n .react-datepicker__month-text--in-selecting-range,\r\n .react-datepicker__month-text--in-range,\r\n .react-datepicker__quarter-text--selected,\r\n .react-datepicker__quarter-text--in-selecting-range,\r\n .react-datepicker__quarter-text--in-range,\r\n .react-datepicker__year-text--selected,\r\n .react-datepicker__year-text--in-selecting-range,\r\n .react-datepicker__year-text--in-range {\r\n border-radius: 50%;\r\n background-color: ${theme.colors.primary};\r\n }\r\n\r\n .react-datepicker__day--keyboard-selected,\r\n .react-datepicker__month-text--keyboard-selected,\r\n .react-datepicker__quarter-text--keyboard-selected,\r\n .react-datepicker__year-text--keyboard-selected {\r\n background: ${theme.colors.primary};\r\n border-radius: 50%;\r\n }\r\n\r\n .react-datepicker__day:hover,\r\n .react-datepicker__month-text:hover,\r\n .react-datepicker__quarter-text:hover,\r\n .react-datepicker__year-text:hover {\r\n border-radius: 50%;\r\n }\r\n `}\r\n`\r\n","import { getDay, addDays } from 'date-fns'\r\n\r\nexport const isWeekday = (date) => {\r\n const day = getDay(date)\r\n return day !== 0 && day !== 6\r\n}\r\n\r\nexport const checkWeekend = (date) => {\r\n const day = getDay(date)\r\n if (day === 0) {\r\n return addDays(date, 1)\r\n } else if (day === 6) {\r\n return addDays(date, 2)\r\n } else {\r\n return date\r\n }\r\n}\r\n","import { forwardRef, useEffect, useState } from 'react'\r\nimport DatePicker from 'react-datepicker'\r\nimport 'react-datepicker/dist/react-datepicker.css'\r\nimport { getDay, addBusinessDays, addDays } from 'date-fns'\r\nimport { useSelector, useDispatch } from 'react-redux'\r\nimport ptBR from 'date-fns/locale/pt-BR'\r\nimport { setDate } from '../../store/ducks/envio'\r\n\r\nimport * as S from './styles'\r\nimport { checkWeekend, isWeekday } from './utils'\r\n\r\nconst CalendarDatePicker = ({ periodo, rightSide }) => {\r\n const store = useSelector((store) => store)\r\n const dispatch = useDispatch()\r\n\r\n const minDate = addDays(new Date(), periodo + 12)\r\n const maxDate = addDays(\r\n checkWeekend(minDate),\r\n store.envio.resumo.QuantidadeDiasEntregaAgendada\r\n )\r\n const [selectedDate, setSelectedDate] = useState(minDate)\r\n\r\n useEffect(() => {\r\n dispatch(setDate(selectedDate))\r\n\r\n // eslint-disable-next-line react-hooks/exhaustive-deps\r\n }, [selectedDate])\r\n\r\n const CustomInput = forwardRef(({ value, onClick }, ref) => (\r\n \r\n ))\r\n\r\n return (\r\n \r\n setSelectedDate(date)}\r\n dateFormat=\"dd/MM/yyyy\"\r\n filterDate={isWeekday}\r\n minDate={checkWeekend(minDate)}\r\n maxDate={maxDate}\r\n locale={ptBR}\r\n customInput={}\r\n >\r\n \r\n )\r\n}\r\n\r\nexport default CalendarDatePicker\r\n","import styled, { css } from 'styled-components'\r\n\r\nexport const ProfileTitle = styled.h2`\r\n font-size: 22px;\r\n margin-bottom: 20px;\r\n color: #555;\r\n`\r\n\r\nexport const Wrapper = styled.div``\r\n\r\nexport const CardWrapper = styled.div`\r\n @media (min-width: 1170px) {\r\n .col-6 {\r\n width: 50%;\r\n }\r\n }\r\n`\r\n\r\nexport const CardBox = styled.div`\r\n padding: 8px 16px;\r\n display: flex;\r\n align-items: center;\r\n\r\n background: #ffffff;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 5px;\r\n\r\n margin-bottom: 8px;\r\n\r\n .iconCredit {\r\n width: 40px;\r\n display: flex;\r\n align-items: center;\r\n }\r\n`\r\n\r\nexport const MainCard = styled.div`\r\n max-width: 40px;\r\n height: 100%;\r\n width: 100%;\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n align-self: flex-start;\r\n margin-top: 12px;\r\n /* position: relative; */\r\n\r\n [type='checkbox']:not(:checked) + label:before {\r\n border: 1px solid #afaeae;\r\n }\r\n\r\n label {\r\n max-width: 40px;\r\n max-height: 40px;\r\n display: flex;\r\n align-items: center;\r\n\r\n /* margin-top: -18px; */\r\n }\r\n`\r\n\r\nexport const CardInfo = styled.div`\r\n ${({theme, check}) => css`\r\n justify-self: left;\r\n font-size: 14px;\r\n margin-left: 8px;\r\n margin-right: 8px;\r\n width: 240px;\r\n\r\n p > p {\r\n color: #707070;\r\n }\r\n strong {\r\n font-weight: 600;\r\n }\r\n\r\n select.parcelas {\r\n padding: 6px 30px 6px 16px;\r\n margin-bottom: -10px;\r\n }\r\n\r\n ${check?.name !== 'Agende sua Entrega' && css`\r\n p {\r\n color: #4A4A4A;\r\n }\r\n `}\r\n\r\n .agendamento {\r\n display: flex;\r\n gap: 8px;\r\n margin-top: 10px;\r\n\r\n input, select {\r\n width: 120px;\r\n height: 32px;\r\n font-family: 'Montserrat';\r\n font-size: 13px;\r\n border-radius: 4px;\r\n border: 1px solid #CED4D4;\r\n\r\n &::placeholder {\r\n color: #707070;\r\n }\r\n }\r\n\r\n select {\r\n padding-left: 8px;\r\n }\r\n }\r\n `}\r\n`\r\nexport const CardInfoTitle = styled.p`\r\n margin-bottom: 4px;\r\n color: #d22630;\r\n font-weight: 600;\r\n font-size: 15px;\r\n`\r\n\r\nexport const CardIcon = styled.a`\r\n transition: all 400ms;\r\n max-width: 60px;\r\n font-size: 14px;\r\n max-height: 21px;\r\n position: absolute;\r\n right: 27px;\r\n top: 20px;\r\n\r\n & img {\r\n width: 18px;\r\n height: 21px;\r\n cursor: pointer;\r\n\r\n &:hover {\r\n filter: invert(22%) sepia(78%) saturate(2710%) hue-rotate(341deg)\r\n brightness(88%) contrast(96%);\r\n }\r\n }\r\n`\r\n","import CalendarDatePicker from '../../CalendarDatePicker'\r\nimport { precoMask } from '../../../utils/utils'\r\nimport * as S from './styles'\r\nimport { useDispatch, useSelector } from 'react-redux'\r\nimport { setFretePick, setTurno } from '../../../store/ducks/envio'\r\nimport { useEffect } from 'react'\r\n\r\nconst CardFreteAgenda = ({ data, agenda, check, seller }) => {\r\n const dispatch = useDispatch()\r\n const store = useSelector((store) => store)\r\n\r\n useEffect(() => {\r\n dispatch(setTurno(''))\r\n // eslint-disable-next-line react-hooks/exhaustive-deps\r\n }, [])\r\n\r\n return (\r\n <>\r\n \r\n \r\n \r\n \r\n {\r\n if (store.envio.fretePick.Agenda?.id === 'agenda') {\r\n dispatch(\r\n setFretePick(seller, {\r\n id: 'no',\r\n name: '',\r\n time: 0,\r\n value: 0\r\n })\r\n )\r\n } else {\r\n dispatch(setFretePick(seller, data))\r\n }\r\n }}\r\n />\r\n \r\n \r\n \r\n {data?.name}\r\n

    Somente São Paulo/SP

    \r\n {check?.id === data.id && (\r\n
    \r\n \r\n dispatch(setTurno(e.target.value))}\r\n >\r\n {/* */}\r\n \r\n \r\n {/* */}\r\n \r\n
    \r\n )}\r\n
    \r\n
    \r\n
    \r\n
    \r\n \r\n )\r\n}\r\n\r\nexport default CardFreteAgenda\r\n","import styled, { css } from 'styled-components'\n\nexport const ProfileTitle = styled.h2`\n font-size: 22px;\n margin-bottom: 20px;\n color: #555;\n`\n\nexport const Wrapper = styled.div`\n margin-bottom: 8px;\n`\n\nexport const CardWrapper = styled.div`\n @media (min-width: 1170px) {\n .col-6 {\n width: 50%;\n }\n }\n`\n\nexport const CardBox = styled.div`\n display: flex;\n align-items: flex-start;\n margin-top: 16px;\n\n .iconCredit {\n width: 40px;\n display: flex;\n align-items: center;\n }\n`\n\nexport const MainCard = styled.div`\n align-items: flex-start;\n justify-content: center;\n width: 72px;\n height: 72px;\n /* margin-right: 15px; */\n\n label {\n max-width: 40px;\n max-height: 40px;\n display: flex;\n align-items: center;\n margin-top: -18px;\n }\n\n img {\n width: 100%;\n }\n`\n\nexport const CardInfo = styled.div`\n justify-self: left;\n font-size: 14px;\n margin-left: 12px;\n margin-right: 8px;\n max-width: 300px;\n\n p > p {\n color: #707070;\n }\n strong {\n font-weight: 600;\n }\n\n select.parcelas {\n padding: 6px 30px 6px 16px;\n margin-bottom: -10px;\n }\n`\n\nexport const CardInfoTitle = styled.p`\n margin-bottom: 2px;\n color: black;\n font-weight: 600;\n font-size: 15px;\n line-height: 17px;\n`\nexport const CardInfoLine = styled.div`\n display: flex;\n justify-content: flex-start;\n align-items: center;\n flex-wrap: wrap;\n margin-top: 4px;\n\n font-size: 12px;\n`\n\nexport const CardIcon = styled.a`\n transition: all 400ms;\n max-width: 60px;\n font-size: 14px;\n max-height: 21px;\n position: absolute;\n right: 27px;\n\n & img {\n width: 18px;\n height: 21px;\n cursor: pointer;\n\n &:hover {\n filter: invert(22%) sepia(78%) saturate(2710%) hue-rotate(341deg)\n brightness(88%) contrast(96%);\n }\n }\n`\n\nexport const Seller = styled.p`\n text-decoration: underline;\n margin-left: 5px;\n font-size: 13px;\n`\n\nexport const Price = styled.p`\n ${({ campanha }) => css`\n ${campanha\n ? css`\n font-weight: 600;\n font-size: 14px;\n text-decoration: line-through;\n color: #aaa;\n `\n : css`\n font-weight: 600;\n font-size: 15px;\n `}\n `}\n`\nexport const CardLinePrice = styled.div`\n display: flex;\n`\n\nexport const AliquotaIPI = styled.p`\n display: flex;\n flex-direction: column;\n justify-content: center;\n font-weight: 500;\n font-style: italic;\n font-size: 10px;\n text-overflow: hidden;\n`\n\nexport const IPI = styled.p`\n display: flex;\n flex-direction: column;\n justify-content: center;\n margin-left: 5px;\n font-weight: 500;\n font-style: italic;\n font-size: 10px;\n`\nexport const Quantidade = styled.p``\nexport const Alterar = styled.p`\n text-decoration: underline;\n margin-left: 10px;\n cursor: pointer;\n`\n","import * as S from './styles'\nimport {\n convertDecimalCurrency,\n formatarParaPorcentagem\n} from '../../../utils/utils'\nimport ImgMock from '../../../assets/img/relogio-thumb.png'\n\nconst CreditCard = ({ data }) => {\n const campanhaPreco = data?.campanha?.ProdutoPrecoCampanha\n return (\n <>\n \n \n \n \n {/* \"produto\" */}\n \n \n \n {data?.name}\n {data.PossuiIPI ? (\n \n Produto Importado com alíquota de IPI de{' '}\n {formatarParaPorcentagem(data.PercentualIPI)}\n \n ) : null}\n \n Vendido por:{data?.seller}\n \n \n
    \n {' '}\n \n \n {convertDecimalCurrency(data?.preco)}\n {' '}\n {convertDecimalCurrency(campanhaPreco)}{' '}\n {data.PossuiIPI ? (\n \n (Com IPI de{' '}\n {convertDecimalCurrency(data?.ValorProdutoUnitarioIPI)}{' '}\n já incluso)\n \n ) : (\n ''\n )}\n \n \n Quantidade: {data?.quantidade}\n \n \n Alterar\n \n \n \n
    \n
    \n
    \n
    \n
    \n
    \n \n )\n}\n\nexport default CreditCard\n","import styled, { css } from 'styled-components'\r\n\r\nexport const ProfileTitle = styled.h2`\r\n font-size: 22px;\r\n margin-bottom: 20px;\r\n color: #555;\r\n`\r\n\r\nexport const SellerWrapper = styled.div`\r\n border: 1px solid #e5e5e5;\r\n width: 100%;\r\n display: flex;\r\n margin: 10px 0px 20px 0px;\r\n\r\n background: #ffffff;\r\n padding: 16px;\r\n display: flex;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 5px;\r\n\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n\r\n .entrega-estimada {\r\n font-size: 14px;\r\n font-weight: 400;\r\n margin-top: 4px;\r\n\r\n & strong {\r\n font-weight: 600;\r\n }\r\n }\r\n\r\n hr {\r\n border: 0;\r\n border-top: 1px solid #e5e5e5;\r\n margin-bottom: 8px;\r\n }\r\n\r\n .col-7 {\r\n padding-left: 0;\r\n }\r\n\r\n .col-5 {\r\n padding-right: 0;\r\n }\r\n\r\n @media (max-width: 800px) {\r\n &:last-child {\r\n margin-bottom: 110px;\r\n }\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n flex-direction: column;\r\n\r\n .col-3 {\r\n display: block;\r\n }\r\n\r\n .col-7 {\r\n margin-bottom: 16px;\r\n }\r\n }\r\n`\r\n\r\nexport const SectionTitle = styled.h3`\r\n font-size: 16px;\r\n font-weight: 600;\r\n margin-bottom: 6px;\r\n\r\n &.large {\r\n font-size: 18px;\r\n font-weight: 500;\r\n }\r\n`\r\n\r\nexport const SectionTitle2 = styled.h3`\r\n font-size: 16px;\r\n font-weight: 500;\r\n margin-bottom: 8px;\r\n display: flex;\r\n justify-content: space-between;\r\n\r\n &.large {\r\n font-size: 18px;\r\n font-weight: 500;\r\n }\r\n`\r\n\r\nexport const TitleContainer = styled.div`\r\n display: flex;\r\n align-items: center;\r\n justify-content: flex-start;\r\n`\r\n\r\nexport const Seller = styled.h3`\r\n font-size: 16px;\r\n font-weight: 600;\r\n margin-bottom: 6px;\r\n text-decoration: underline;\r\n margin-left: 7px;\r\n`\r\nexport const Alterar = styled.p`\r\n text-decoration: underline;\r\n margin-left: 10px;\r\n cursor: pointer;\r\n`\r\n\r\nexport const ButtonAlterar = styled.button`\r\n ${({ theme }) => css`\r\n color: rgba(46, 46, 46, 1);\r\n font-family: 'Montserrat';\r\n font-size: 13px;\r\n font-weight: 400;\r\n background: transparent;\r\n border: 0;\r\n cursor: pointer;\r\n transition: all ease-in-out 400ms;\r\n text-decoration: underline;\r\n align-self: flex-start;\r\n\r\n &:hover {\r\n color: rgba(46, 46, 46, 0.7);\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: $MEDIA-IPAD) {\r\n font-size: 14px;\r\n }\r\n `}\r\n`\r\n","import { useSelector, useDispatch } from 'react-redux'\nimport CardFrete from './CardFrete'\nimport CardFreteAgenda from './CardFreteAgenda'\nimport CardProduto from './CardProduto'\nimport * as S from './styles'\nimport { Gimbafy } from './masks'\nimport { setFretePick } from '../../store/ducks/envio'\nimport { useEffect, useState } from 'react'\n\nconst Sellers = ({ carrinho, frete }) => {\n const ids = new Set()\n const sellers = carrinho\n ?.map((e) => ({ name: e.NomeSeller, id: e.SellerId }))\n .filter((e) => {\n if (ids.has(e.id)) {\n return false\n }\n ids.add(e.id)\n return true\n })\n\n const dispatch = useDispatch()\n const store = useSelector((store) => store)\n\n const noFrete = (valid = false) => {\n return valid ? (\n
    \n Não foi possível encontrar uma transportadora para o endereço\n selecionado. Entre em contato com nossa central de atendimento\n
    \n ) : null\n }\n\n const freteGimbaDisplay = (frete) => {\n return frete.Gimba?.OpcoesFrete?.map((e, i) => {\n let dataF = {\n id: e.Id,\n name: e.RazaoSocial,\n idMedia: e.IdObjetoMedia,\n time: e.DiasParaEntrega,\n value: e.ValorFrete,\n ValorFreteAgendado: e.ValorFreteAgendado\n }\n\n return e.Id ? (\n \n ) : (\n
    \n Não foi possível encontrar uma transportadora para o endereço\n selecionado. Entre em contato com nossa central de atendimento\n
    \n )\n })\n }\n const freteSellerDisplay = (frete, seller) => {\n let sellerObj = frete.Sellers?.filter((e) => e.SellerId === seller.id)[0]\n let sId = sellerObj?.SellerId\n return sellerObj?.OpcoesEntrega?.map((e, i) => {\n return (\n \n )\n })\n }\n\n useEffect(() => {\n if (store.endereco.padrao?.uf !== 'SP')\n dispatch(\n setFretePick('Agenda', {\n id: 'no',\n name: '',\n time: 0,\n value: 0\n })\n )\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [store.endereco.padrao])\n\n if (carrinho?.some((produto) => produto.TemEstoque === false))\n return (\n \n )\n\n const precoNovo = (data) => {\n let quant = data.ProdutosPercentualQuantidades || []\n const { PrecoVenda } = data\n if (quant.length === 0) return PrecoVenda\n\n let res = PrecoVenda\n quant = quant.sort((a, b) => a.Quantidade - b.Quantidade)\n for (let i = 0; i < quant.length; i++) {\n if (data.Quantidade >= quant[i].Quantidade) {\n res = quant[i].ValorNominal\n }\n }\n return res\n }\n\n return (\n
    \n {sellers?.map((seller, i) => (\n \n
    \n \n Enviado por\n {Gimbafy(seller.name)}\n \n {carrinho\n ?.filter((e) => e.NomeSeller === seller.name)\n .map((e) => (\n \n ))}\n
    \n\n
    \n Opção de Entrega\n {seller.name === null && freteGimbaDisplay(frete)}\n {seller.name === null &&\n noFrete(store.envio.frete?.Gimba?.OpcoesFrete.length === 0)}\n {seller.name === null &&\n store?.envio?.fretePick?.Gimba?.id !== undefined &&\n store?.endereco?.padrao?.uf === 'SP' && (\n
    \n
    \n \n
    \n )}\n\n {seller.name !== null && freteSellerDisplay(frete, seller)}\n {seller.name !== null &&\n noFrete(\n store.envio.frete?.Sellers?.length === 0\n ? true\n : store.envio.frete?.Sellers?.filter(\n (e) => e.SellerId === seller.id\n )[0]?.OpcoesEntrega.length === 0\n )}\n\n {!!store.envio.frete.Message && 'Frete Indisponível'}\n
    \n
    \n ))}\n
    \n )\n}\nexport default Sellers\n","import styled, { css } from 'styled-components'\r\n\r\nexport const CardBox = styled.div`\r\n background: #ffffff;\r\n padding: 16px;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 4px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 20px;\r\n\r\n .address {\r\n display: flex;\r\n justify-content: space-between;\r\n align-items: center;\r\n\r\n @media (max-width: 600px) {\r\n flex-direction: column;\r\n align-items: flex-start;\r\n\r\n button {\r\n margin-top: 10px;\r\n }\r\n }\r\n }\r\n\r\n .endereco-card-title {\r\n font-size: 16px;\r\n display: block;\r\n font-weight: 600;\r\n margin-bottom: 6px;\r\n }\r\n\r\n .endereco-card-title span {\r\n font-weight: normal;\r\n }\r\n\r\n .endereco-card-description {\r\n font-weight: 400;\r\n font-size: 15px;\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n .perfil-box {\r\n padding: 30px 20px 10px 20px;\r\n }\r\n }\r\n\r\n @media (min-width: 1170px) and (max-width: 1360px) {\r\n .endereco-card-title {\r\n font-size: 14px;\r\n }\r\n\r\n .endereco-card-description {\r\n font-size: 14px;\r\n }\r\n }\r\n`\r\n\r\n\r\nexport const CardAddressType = styled.h3`\r\n font-size: 16px;\r\n display: block;\r\n margin-bottom: 8px;\r\n`\r\nexport const Address = styled.h3``\r\n\r\nexport const ProfileBox = styled.div`\r\n background: #ffffff;\r\n padding: 30px 30px 30px 30px;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 10px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 20px;\r\n`\r\n\r\nexport const ProfileBoxFooter = styled.div`\r\n margin: 10px 0 20px 0;\r\n\r\n @media (max-width: 1170px) {\r\n display: flex;\r\n flex-direction: column;\r\n }\r\n`\r\n\r\nexport const ButtonChangeAddress = styled.button`\r\n ${({ theme }) => css`\r\n color: rgba(46, 46, 46, 1);\r\n font-family: 'Montserrat';\r\n font-size: 13px;\r\n font-weight: 400;\r\n background: transparent;\r\n border: 0;\r\n cursor: pointer;\r\n transition: all ease-in-out 400ms;\r\n text-decoration: underline;\r\n\r\n &:hover {\r\n color: rgba(46, 46, 46, 0.7);\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: $MEDIA-IPAD) {\r\n font-size: 14px;\r\n }\r\n `}\r\n`\r\n","import * as S from './styles'\nimport { capitalizePhrase } from '../../../utils/utils'\n\nconst AddressCardEnvio = ({ showModal, data, allowOtherAddress }) => {\n return (\n \n
    \n {!!data && (\n
    \n \n {capitalizePhrase(data.apelido)}\n \n {data.tipoLogradouro === data.logradouro?.trim().split(' ')[0] ? (\n \n {capitalizePhrase(data.logradouro)}, {data.numero} -{' '}\n {data.complemento}\n \n ) : (\n \n {capitalizePhrase(data.tipoLogradouro)}{' '}\n {capitalizePhrase(data.logradouro)}, {data.numero} -{' '}\n {data.complemento}\n {console.log(data)}\n \n )}\n\n

    \n {capitalizePhrase(data.bairro)} - {capitalizePhrase(data.cidade)}{' '}\n / {data.uf} - {data.cep}\n

    \n
    \n )}\n\n {!allowOtherAddress ? null : (\n showModal()}>\n Escolher outro endereço\n \n )}\n
    \n
    \n )\n}\n\nexport default AddressCardEnvio\n","import styled from 'styled-components'\r\n\r\nexport const Container = styled.div`\r\n position: relative;\r\n padding: 20px 30px 16px 20px;\r\n border-radius: 5px;\r\n display: flex;\r\n align-items:center;\r\n border-left: 6px solid #27ae60;\r\n margin-bottom: 20px;\r\n\r\n button {\r\n position: absolute;\r\n right: 10px;\r\n top: 15px;\r\n border: 0;\r\n background: transparent;\r\n color: inherit;\r\n cursor: pointer;\r\n }\r\n svg {\r\n margin: 4px 30px 0 10px;\r\n }\r\n div {\r\n flex: 1;\r\n p {\r\n margin-top: 4px;\r\n font-size: 14px;\r\n opacity: 0.8;\r\n line-height: 20px;\r\n }\r\n }\r\n background: #e5f7e7;\r\n color: #27ae60;\r\n`\r\n","import { useState } from 'react'\r\nimport { useSelector } from 'react-redux'\r\nimport * as S from './styles'\r\nimport IconAlertSuccess from '../../assets/icons/icon-alert-success.svg'\r\nimport { HiX } from 'react-icons/hi'\r\n\r\nconst ToastCotacao = () => {\r\n const store = useSelector((store) => store)\r\n const [display, setDisplay] = useState(true)\r\n\r\n if (!display) return
    \r\n\r\n return store.finalizado.tipo !== '' ? (\r\n \r\n \r\n \r\n {`${store.finalizado.tipo === 'c' ? 'Cotação' : 'Negociação'} Nº ${\r\n store.finalizado.pedido?.Id || 0\r\n } salva com sucesso! Finalize a compra dos demais itens.`}\r\n \r\n \r\n \r\n ) : null\r\n}\r\n\r\nexport default ToastCotacao\r\n","import styled from 'styled-components'\r\n\r\nexport const Container = styled.div`\r\n position: relative;\r\n padding: 20px 40px 16px 20px;\r\n border-radius: 5px;\r\n display: flex;\r\n align-items: center;\r\n border-left: 6px solid #ff9017;\r\n margin-bottom: 10px;\r\n margin-top: 10px;\r\n\r\n button {\r\n position: absolute;\r\n right: 0px;\r\n // top: 15px;\r\n border: 0;\r\n background: transparent;\r\n color: inherit;\r\n cursor: pointer;\r\n }\r\n svg {\r\n margin: 4px 16px 0 10px;\r\n }\r\n div {\r\n flex: 1;\r\n p {\r\n margin-top: 4px;\r\n font-size: 14px;\r\n opacity: 0.8;\r\n line-height: 20px;\r\n }\r\n }\r\n background: #fff3e7;\r\n color: #ff9017;\r\n`\r\n","import { useState } from 'react'\r\nimport * as S from './styles'\r\nimport IconAlertSuccess from '../../assets/icons/icon-alert-alert.svg'\r\nimport { HiX } from 'react-icons/hi'\r\n\r\nconst ToastEndereco = () => {\r\n const [display, setDisplay] = useState(true)\r\n\r\n if (!display) return
    \r\n return (\r\n \r\n \r\n\r\n

    \r\n \r\n Atenção, confirme seu endereço para evitar problemas de entrega.\r\n {' '}\r\n 😉\r\n

    \r\n\r\n \r\n
    \r\n )\r\n}\r\n\r\nexport default ToastEndereco\r\n","/* eslint-disable react-hooks/exhaustive-deps */\r\nimport { Button } from '../../components/Button/styles'\r\nimport Header from '../../components/Header'\r\nimport MediaMatch from '../../components/MediaMatch'\r\nimport Sellers from '../../components/Sellers'\r\nimport { CardBox } from '../../components/PaymentCards/CreditCard/styles'\r\nimport ResumoPedido from '../../components/ResumoPedido'\r\nimport Steps from '../../components/Steps'\r\nimport * as S from '../../styles/checkout'\r\nimport AddressCardEnvio from '../../components/MyAddress/AddressCardEnvio'\r\nimport MyAddressModal from '../../components/MyAddressModal'\r\nimport { useEffect, useState } from 'react'\r\nimport { useSelector, useDispatch } from 'react-redux'\r\nimport {\r\n setResumo,\r\n setFrete,\r\n resetFretePick,\r\n setFretePick\r\n} from '../../store/ducks/envio'\r\nimport { getFrete, getResumo } from './fetch'\r\nimport Loader from '../../components/Loader'\r\nimport { useHistory } from 'react-router-dom'\r\nimport { isPF, token } from '../../api/auth/auth'\r\nimport ToastCotacao from '../../components/ToastCotacao'\r\n\r\nimport { allowNewAddress } from '../../utils/validatePJ'\r\nimport { useToast } from '../../hooks/toast'\r\nimport { setPadrao } from '../../store/ducks/endereco'\r\nimport { fetchUser } from '../Auth/fetch'\r\nimport { setUserInfo } from '../../store/ducks/user'\r\nimport { getLocalStorageLog } from '../../utils/traceLogAcessos'\r\nimport { useLocation } from 'react-router-dom'\r\nimport ToastEndereco from '../../components/ToastEndereco'\r\nimport cookies from 'js-cookies'\r\nimport axios from 'axios'\r\n\r\nconst Envio = () => {\r\n const router = useHistory()\r\n const [showModalAddress, setShowModalAddress] = useState(false)\r\n const [selectedAddress, setSelectedAddress] = useState('')\r\n const [load0, setLoad0] = useState(false)\r\n const [load1, setLoad1] = useState(false)\r\n const [retry, setRetry] = useState(0)\r\n const [ipAddress, setIpAddress] = useState('')\r\n const [userData, setUserData] = useState('')\r\n\r\n // const freteMock = {\r\n // CodigoLocalidade: 86991,\r\n // Cep: '11721020',\r\n // Gimba: {\r\n // OpcoesFrete: [\r\n // {\r\n // Id: null,\r\n // RazaoSocial: 'Transportadora Teste',\r\n // DiasParaEntrega: 3,\r\n // ValorFrete: 17.05,\r\n // ValorFreteAgendado: 0,\r\n // ValorFreteEmpresa: 17.05,\r\n // ValorTda: 0,\r\n // ValorTde: 0,\r\n // ValorAdmFrete: 0,\r\n // ValorFreteAteRedespacho: 0,\r\n // ValorPercentualIcms: 2.0455,\r\n // ValorTranslado: 0,\r\n // CNPJTransportadoraRedespacho: null,\r\n // CNPJTranslado: null,\r\n // Retira: false,\r\n // FOB: false,\r\n // DataAgendamento: null,\r\n // PeriodoAgendamento: 0,\r\n // ValorEmex: 0,\r\n // FreteAgendamento: true\r\n // }\r\n // ]\r\n // },\r\n // Sellers: [],\r\n // Validation: {\r\n // Message: null,\r\n // IsValid: true,\r\n // Errors: []\r\n // }\r\n // }\r\n // console.log(freteMock)\r\n\r\n const openModalAddress = () => {\r\n setShowModalAddress((prev) => !prev)\r\n }\r\n const store = useSelector((store) => store)\r\n const dispatch = useDispatch()\r\n const { addToast } = useToast()\r\n\r\n //Carregar endereço de Faturamento selecionado por Default\r\n const enderecoFaturamento = store.endereco.enderecos.filter(\r\n (item) => item.tipoEndereco === 'C'\r\n )\r\n const location = useLocation()\r\n\r\n const getIpAddress = async () => {\r\n return await axios\r\n .get('https://geolocation-db.com/json/')\r\n .then((res) => setIpAddress(res.data.IPv4))\r\n .catch((err) => setIpAddress(null))\r\n .finally()\r\n }\r\n\r\n useEffect(() => {\r\n getLocalStorageLog(location.pathname)\r\n window.dataLayer = window.dataLayer || []\r\n\r\n getIpAddress()\r\n\r\n window.dataLayer.push({\r\n event: '/envio'\r\n })\r\n\r\n if (!isPF()) {\r\n dispatch(setPadrao(enderecoFaturamento[0]))\r\n }\r\n //user\r\n fetchUser(setUserData)\r\n //refresh\r\n if (!!!store.endereco.padrao.id) router.push(`/?token=${token()}`)\r\n }, [])\r\n\r\n //resumo\r\n useEffect(() => {\r\n if (store.endereco.padrao?.id !== undefined) {\r\n getResumo(\r\n store.endereco.padrao?.id,\r\n (res) => dispatch(setResumo(res)),\r\n setLoad0,\r\n token()\r\n )\r\n }\r\n dispatch(resetFretePick())\r\n }, [store.endereco.padrao])\r\n\r\n //frete preset\r\n useEffect(() => {\r\n if (store.envio.resumo.ProdutosConcatenados !== undefined) {\r\n getFrete(\r\n store.endereco.padrao.id,\r\n store.envio.resumo,\r\n // (res) => dispatch(setFrete(freteMock)),\r\n (res) => dispatch(setFrete(res)),\r\n setLoad1\r\n )\r\n // setRetry(retry + 1)\r\n }\r\n }, [store.envio.resumo])\r\n\r\n useEffect(() => {\r\n if (store.user.info.id === undefined && userData !== '') {\r\n dispatch(setUserInfo(userData))\r\n }\r\n }, [store.user.info, userData])\r\n\r\n //frete\r\n useEffect(() => {\r\n if (!!store.envio.frete.Message) {\r\n addToast({\r\n type: 'error',\r\n title:\r\n 'Não foi possível encontrar uma transportadora para o endereço selecionado.',\r\n description: 'Entre em contato com nossa central de atendimento.',\r\n timer: 6000,\r\n keep: true\r\n })\r\n }\r\n\r\n //retry\r\n if (!!!store.envio.frete.CodigoLocalidade && retry < 3 && retry < 0) {\r\n getFrete(\r\n store.endereco.padrao.id,\r\n store.envio.resumo,\r\n // (res) => dispatch(setFrete(freteMock)),\r\n (res) => dispatch(setFrete(res)),\r\n setLoad1\r\n )\r\n setRetry(retry + 1)\r\n } else if (retry >= 3) {\r\n router.push(`/?token=${token()}`)\r\n }\r\n //autopick\r\n if (\r\n Object.keys(store.envio.fretePick).length === 0 &&\r\n !!store.envio.frete.Cep\r\n ) {\r\n //Gimba\r\n const freteGimba = store.envio.frete?.Gimba\r\n const opcao = freteGimba?.OpcoesFrete.sort(\r\n (a, b) => a.ValorFrete - b.ValorFrete\r\n )[0]\r\n if (!!freteGimba && opcao?.Id) {\r\n dispatch(\r\n setFretePick('Gimba', {\r\n id: opcao?.Id,\r\n name: opcao?.RazaoSocial,\r\n time: opcao?.DiasParaEntrega,\r\n value: opcao?.ValorFrete,\r\n ValorFreteAgendado: opcao?.ValorFreteAgendado\r\n })\r\n )\r\n }\r\n //Sellers\r\n const ids = new Set()\r\n const sellers = store.envio.resumo?.Carrinho?.map((e) => ({\r\n nome: e.NomeSeller,\r\n id: e.SellerId\r\n })).filter((e) => {\r\n if (ids.has(e.id) || e.id === null) {\r\n return false\r\n }\r\n ids.add(e.id)\r\n return true\r\n })\r\n const freteSellers = store.envio.frete?.Sellers || []\r\n sellers.map((e) => {\r\n const opcoes = freteSellers.find((s) => s.SellerId === e.id)\r\n const opcao = opcoes?.OpcoesEntrega?.map((s, i) => ({\r\n ...s,\r\n posId: (s.NomeMetodoEntrega || 0) + e?.id + i\r\n }))\r\n .filter((item) => item.IdNomeMetodoEntrega && item.NomeMetodoEntrega)\r\n ?.sort((a, b) => a.CustoFinalEnvio - b.CustoFinalEnvio)[0]\r\n\r\n // console.log(opcao)\r\n if (!opcao?.IdNomeMetodoEntrega || !opcao?.NomeMetodoEntrega) {\r\n addToast({\r\n type: 'error',\r\n title:\r\n 'Uma ou mais opções de frete indisponíveis para seu endereço',\r\n description: 'Entre em contato com nossa central de atendimento.',\r\n timer: 6000,\r\n keep: true\r\n })\r\n } else {\r\n dispatch(\r\n setFretePick(e.nome, {\r\n id: opcao?.posId,\r\n saveId: e?.id,\r\n name: opcao?.Descricao,\r\n time: opcao?.EstimativaTransitoDiasUteis,\r\n value: opcao?.CustoFinalEnvio,\r\n IdNomeMetodoEntrega: opcao?.IdNomeMetodoEntrega,\r\n NomeMetodoEntrega: opcao?.NomeMetodoEntrega\r\n })\r\n )\r\n }\r\n\r\n return e\r\n })\r\n }\r\n }, [store.envio.frete])\r\n\r\n function sendUserDatalayer() {\r\n const nomeCompleto =\r\n store.user.info?.tipoCliente === 'F'\r\n ? store.user.info?.nome\r\n : store.user.info?.contato\r\n const nome = nomeCompleto?.split(' ')[0]\r\n const sobrenome =\r\n nomeCompleto?.split(' ')[nomeCompleto?.split(' ').length - 1]\r\n\r\n const userPF = {\r\n telefoneCliente:\r\n store.user.info.telefoneCelularDDD +\r\n store.user.info.telefoneCelularNumero,\r\n emailCliente: store.user.info.email,\r\n primeiroNomeCliente: nome,\r\n sobrenomeCliente: sobrenome,\r\n idCliente: store.user.info.id,\r\n userAgent: window.navigator.userAgent,\r\n userIP: ipAddress !== '' ? ipAddress : '',\r\n fbc: cookies.getItem('_fbc'),\r\n fbp: cookies.getItem('_fbp')\r\n }\r\n\r\n const userPJ = {\r\n telefoneCliente:\r\n store.user.info.dddTelefoneComercial.trim() +\r\n store.user.info.numeroTelefoneComercial,\r\n emailCliente: store.user.info.email,\r\n primeiroNomeCliente: nome,\r\n sobrenomeCliente: sobrenome,\r\n idCliente: store.user.info.id,\r\n userAgent: window.navigator.userAgent,\r\n userIP: ipAddress !== '' ? ipAddress : '',\r\n fbc: cookies.getItem('_fbc'),\r\n fbp: cookies.getItem('_fbp')\r\n }\r\n\r\n window.dataLayer.push({\r\n event: 'user_info',\r\n user: store.user.info?.tipoCliente === 'F' ? userPF : userPJ\r\n })\r\n }\r\n\r\n useEffect(() => {\r\n ipAddress !== '' && sendUserDatalayer()\r\n }, [ipAddress])\r\n\r\n return (\r\n <>\r\n {(load0 || load1) && }\r\n \r\n\r\n
    \r\n \r\n \r\n \r\n \r\n Endereço de Entrega\r\n\r\n \r\n {/* CONTEÚDO PRINCIPAL DA PÁGINA */}\r\n\r\n \r\n \r\n openModalAddress()}\r\n data={store.endereco.padrao}\r\n allowOtherAddress={allowNewAddress(\r\n store.endereco.enderecos,\r\n store.user.info.inscricaoEstadual\r\n )}\r\n />\r\n\r\n Opções de Envio\r\n \r\n \r\n {/* CONTEÚDO PRINCIPAL DA PÁGINA */}\r\n\r\n
    \r\n \r\n
    \r\n
    \r\n
    \r\n
    \r\n \r\n )\r\n}\r\nexport default Envio\r\n","import { useSelector } from 'react-redux'\nimport CardFrete from './CardFrete'\nimport CardFreteAgenda from './CardFreteAgenda'\nimport CardProduto from './CardProduto'\nimport * as S from './styles'\nimport { Gimbafy } from './masks'\nimport { useState } from 'react'\nimport CreditCardImage from '../PaymentCards/CreditCardImage'\n\nimport { getDay, addBusinessDays, addDays, format, parseISO } from 'date-fns'\nimport ptBr from 'date-fns/locale/pt-BR'\nimport { Link } from 'react-router-dom'\n\nconst Sellers = ({ carrinho, frete }) => {\n const [changeEntrega, setChangeEntrega] = useState({})\n\n const handleEntrega = (sellerName) => {\n setChangeEntrega({\n [sellerName]: !changeEntrega[sellerName]\n })\n }\n\n const ids = new Set()\n const sellers = carrinho\n ?.map((e) => ({ name: e.NomeSeller, id: e.SellerId }))\n .filter((e) => {\n if (ids.has(e.id)) {\n return false\n }\n ids.add(e.id)\n return true\n })\n\n const store = useSelector((store) => store)\n const agenda = store.envio.fretePick.Agenda\n // console.log(agenda)\n\n const turnoCompleto = () => {\n switch (agenda.turno) {\n case 'm':\n return 'manhã'\n case 't':\n return 'tarde'\n case 'n':\n return 'noite'\n default:\n break\n }\n }\n\n const checkSeller = (seller) => {\n if (seller.name !== null) {\n const estimativa = frete.Sellers?.filter((e) => e.SellerId === seller.id)\n .filter(\n (e) => e.SellerId === store.envio.fretePick[seller.name]?.saveId\n )\n .map((e) => e.OpcoesEntrega[0].EstimativaTransitoDiasUteis)\n\n const entregaEstimada = addBusinessDays(new Date(), estimativa)\n\n return format(entregaEstimada, 'dd MMMM yyyy', { locale: ptBr })\n } else {\n const estimativa = frete.Gimba?.OpcoesFrete?.filter(\n (e) => e.Id === store.envio.fretePick['Gimba']?.id\n ).map((e) => e.DiasParaEntrega)\n\n const entregaEstimada = addBusinessDays(new Date(), estimativa)\n\n return format(entregaEstimada, 'dd MMMM yyyy', { locale: ptBr })\n }\n }\n\n const freteSellerShowDisplay = (frete, seller) => {\n const disp = store.envio.fretePick[seller.name]\n\n return (\n \n )\n }\n\n const formatDate = () => {\n if (agenda.date !== null) {\n return format(agenda.date, 'dd MMMM yyyy', { locale: ptBr })\n } else {\n return null\n }\n }\n\n const precoNovo = (data) => {\n let quant = data.ProdutosPercentualQuantidades || []\n const { PrecoVenda } = data\n if (quant.length === 0) return PrecoVenda\n\n let res = PrecoVenda\n quant = quant.sort((a, b) => a.Quantidade - b.Quantidade)\n for (let i = 0; i < quant.length; i++) {\n if (data.Quantidade >= quant[i].Quantidade) {\n res = quant[i].ValorNominal\n }\n }\n return res\n }\n\n const campanhaSelecionada = (produto) =>\n produto.Campanhas.filter(\n (campanha) =>\n campanha.NomeCondicaoPagamentoOmnik.toLowerCase() ===\n store.pagamento.pick.id.toLowerCase()\n )[0]\n\n return (\n
    \n {sellers?.map((seller, i) => (\n \n
    \n \n Itens enviados por\n {Gimbafy(seller.name)}\n \n

    \n Entrega Estimada: {checkSeller(seller)}\n

    \n\n {carrinho\n ?.filter((e) => e.NomeSeller === seller.name)\n .map((e) => (\n \n ))}\n
    \n\n
    \n \n Opção de Entrega{' '}\n \n Alterar\n \n \n\n {seller.name === null &&\n frete.Gimba?.OpcoesFrete?.filter(\n (e) => e.Id === store.envio.fretePick['Gimba']?.id\n ).map((e) => (\n \n ))}\n\n {seller.name === null &&\n store?.envio?.fretePick?.Gimba &&\n store.endereco.padrao.uf === 'SP' ? (\n <>\n {agenda?.id !== 'no' && !!agenda.date ? (\n

    \n Entrega agendada:{' '}\n \n {formatDate()} | {turnoCompleto()}\n \n

    \n ) : null}\n \n ) : null}\n\n {seller.name !== null && freteSellerShowDisplay(frete, seller)}\n {store.pagamento.condicaoFaturado?.IdTipo === 3 &&\n +store.pagamento?.condicaoIndex > 0 &&\n !!store.pagamento.pickF.id &&\n seller.name === null && (\n
    \n \n Pagamento{' '}\n \n Alterar\n \n \n

    \n \n

    \n Boleto Faturado\n
    \n
    \n (\n {\n store.pagamento.condicaoFaturado?.Parcelas[\n +store.pagamento.condicaoIndex - 1\n ].DescricaoPagamento\n }\n )\n
    \n

    \n
    \n )}\n\n {store.pagamento.condicaoFaturado?.IdTipo === 3 &&\n +store.pagamento?.condicaoIndex > 0 &&\n !!store.pagamento.pickF.id &&\n seller.name !== null && (\n
    \n \n Pagamento{' '}\n \n Alterar\n \n \n\n

    \n \n\n {store.pagamento.pickF.bandeira !== undefined ? (\n

    \n
    \n (Crédito)\n
    \n
    \n {store.pagamento.pickF.bandeira}\n {' Final '}\n {store.pagamento.pickF.numero}\n
    \n
    \n ) : (\n
    \n
    \n {store.pagamento.pickF.id === 'pix'\n ? 'PIX'\n : store.pagamento.condicoes.Descricao}\n
    \n
    \n
    \n )}\n

    \n
    \n )}\n
    \n \n ))}\n
    \n )\n}\nexport default Sellers\n","import styled, { css } from 'styled-components'\r\n\r\nexport const CardBox = styled.div`\r\n background: #ffffff;\r\n padding: 16px;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 4px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 20px;\r\n\r\n .address {\r\n display: flex;\r\n justify-content: space-between;\r\n align-items: center;\r\n\r\n @media (max-width: 500px) {\r\n flex-direction: column;\r\n align-items: flex-start;\r\n\r\n /* button {\r\n margin-top: 10px;\r\n } */\r\n }\r\n }\r\n\r\n .endereco-card-title {\r\n font-size: 16px;\r\n display: block;\r\n font-weight: 500;\r\n margin-bottom: 8px;\r\n }\r\n\r\n .endereco-card-title span {\r\n font-weight: normal;\r\n }\r\n\r\n .endereco-card-description {\r\n font-weight: 400;\r\n font-size: 14px;\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n .perfil-box {\r\n padding: 30px 20px 10px 20px;\r\n }\r\n }\r\n\r\n @media (min-width: 1170px) and (max-width: 1360px) {\r\n .endereco-card-title {\r\n font-size: 14px;\r\n }\r\n\r\n .endereco-card-description {\r\n font-size: 14px;\r\n }\r\n }\r\n`\r\n\r\nexport const CardAddressType = styled.h3`\r\n font-size: 16px;\r\n display: block;\r\n margin-bottom: 8px;\r\n`\r\nexport const Address = styled.h3``\r\n\r\nexport const ProfileBox = styled.div`\r\n background: #ffffff;\r\n padding: 30px 30px 30px 30px;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 10px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 20px;\r\n`\r\n\r\nexport const ProfileBoxFooter = styled.div`\r\n margin: 10px 0 20px 0;\r\n\r\n @media (max-width: 1170px) {\r\n display: flex;\r\n flex-direction: column;\r\n }\r\n`\r\n\r\nexport const ButtonChangeAddress = styled.button`\r\n ${({ theme, confirmacao }) => css`\r\n color: rgba(46, 46, 46, 1);\r\n font-family: 'Montserrat';\r\n font-size: 13px;\r\n font-weight: 400;\r\n background: transparent;\r\n border: 0;\r\n cursor: pointer;\r\n transition: all ease-in-out 400ms;\r\n text-decoration: underline;\r\n align-self: flex-start;\r\n\r\n position: absolute;\r\n ${confirmacao\r\n ? css`\r\n right: 16px;\r\n `\r\n : css`\r\n right: 26px;\r\n `}\r\n\r\n @media (min-width: 1170px) {\r\n ${confirmacao &&\r\n css`\r\n right: 26px;\r\n `}\r\n }\r\n\r\n &:hover {\r\n color: rgba(46, 46, 46, 0.7);\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: $MEDIA-IPAD) {\r\n font-size: 14px;\r\n }\r\n `}\r\n`\r\n","import * as S from './styles'\nimport { capitalizePhrase } from '../../../utils/utils'\nimport { Link } from 'react-router-dom'\n\nconst AddressCardConfirmacao = ({\n showModal,\n data,\n cotacao,\n negociacao,\n allowOtherAddress\n}) => {\n return (\n \n
    \n
    \n \n Endereço de Entrega\n \n\n {data.tipoLogradouro === data.logradouro?.trim().split(' ')[0] ? (\n \n {!!cotacao ? '' : 'Entrega:'} {capitalizePhrase(data.logradouro)},{' '}\n {data.numero} - {capitalizePhrase(data.complemento)}{' '}\n

    \n {capitalizePhrase(data.bairro)} -{' '}\n {capitalizePhrase(data.cidade)} / {data.uf} - {data.cep}\n

    \n
    \n ) : (\n \n {!!cotacao ? '' : 'Entrega:'}{' '}\n {capitalizePhrase(data.tipoLogradouro)}{' '}\n {capitalizePhrase(data.logradouro)}, {data.numero} -{' '}\n {capitalizePhrase(data.complemento)}\n

    \n {capitalizePhrase(data.bairro)} -{' '}\n {capitalizePhrase(data.cidade)} / {data.uf} - {data.cep}\n

    \n
    \n )}\n
    \n\n {!!cotacao || !!negociacao ? (\n <>\n {!allowOtherAddress ? null : (\n showModal()}>\n Alterar\n \n )}\n \n ) : (\n \n Alterar\n \n )}\n
    \n
    \n )\n}\n\nexport default AddressCardConfirmacao\n","import styled, { css } from 'styled-components'\r\n\r\nexport const CardBox = styled.div`\r\n background: #ffffff;\r\n padding: 16px;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 4px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 20px;\r\n\r\n .address {\r\n display: flex;\r\n justify-content: space-between;\r\n align-items: center;\r\n\r\n button {\r\n position: absolute;\r\n right: 16px;\r\n }\r\n\r\n @media (max-width: 500px) {\r\n flex-direction: column;\r\n align-items: flex-start;\r\n\r\n /* button {\r\n margin-top: 10px;\r\n } */\r\n }\r\n }\r\n\r\n .endereco-card-title {\r\n font-size: 16px;\r\n display: block;\r\n font-weight: 500;\r\n margin-bottom: 8px;\r\n }\r\n\r\n .endereco-card-title span {\r\n font-weight: normal;\r\n }\r\n\r\n .endereco-card-description {\r\n font-weight: 400;\r\n font-size: 14px;\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n .perfil-box {\r\n padding: 30px 20px 10px 20px;\r\n }\r\n }\r\n\r\n @media (min-width: 1170px) and (max-width: 1360px) {\r\n .endereco-card-title {\r\n font-size: 14px;\r\n }\r\n\r\n .endereco-card-description {\r\n font-size: 14px;\r\n }\r\n }\r\n`\r\n\r\nexport const CardTitle = styled.h3`\r\n font-size: 16px;\r\n display: block;\r\n margin-bottom: 8px;\r\n`\r\nexport const CardInfo = styled.div`\r\n display: flex;\r\n\r\n img {\r\n margin-right: 8px;\r\n width: 40px;\r\n }\r\n`\r\n\r\nexport const ProfileBox = styled.div`\r\n background: #ffffff;\r\n padding: 30px 30px 30px 30px;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 10px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 20px;\r\n`\r\n\r\nexport const ProfileBoxFooter = styled.div`\r\n margin: 10px 0 20px 0;\r\n\r\n @media (max-width: 1170px) {\r\n display: flex;\r\n flex-direction: column;\r\n }\r\n`\r\n\r\nexport const ButtonChangeAddress = styled.button`\r\n ${({ theme }) => css`\r\n color: rgba(46, 46, 46, 1);\r\n font-family: 'Montserrat';\r\n font-size: 13px;\r\n font-weight: 400;\r\n background: transparent;\r\n border: 0;\r\n cursor: pointer;\r\n transition: all ease-in-out 400ms;\r\n text-decoration: underline;\r\n align-self: flex-start;\r\n\r\n &:hover {\r\n color: rgba(46, 46, 46, 0.7);\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: $MEDIA-IPAD) {\r\n font-size: 14px;\r\n }\r\n `}\r\n`\r\n","import * as S from './styles'\r\nimport { capitalizePhrase, showFullFlagName } from '../../../utils/utils'\r\nimport { HiCreditCard } from 'react-icons/hi'\r\nimport { useSelector } from 'react-redux'\r\nimport CreditCardImage from '../CreditCardImage'\r\nimport { Link } from 'react-router-dom'\r\n\r\nconst AddressCardConfirmacao = ({ showModal, cardData }) => {\r\n const store = useSelector((store) => store)\r\n\r\n const pickedMethod = store.pagamento?.pick\r\n const condicoes = store.pagamento.condicoes?.Parcelas\r\n const condicaoFaturado = store.pagamento.condicaoFaturado?.Parcelas\r\n const conIndex = store.pagamento?.condicaoIndex\r\n\r\n return (\r\n \r\n
    \r\n
    \r\n \r\n Forma de Pagamento\r\n \r\n\r\n {/* Case BOLETO */}\r\n\r\n {pickedMethod.id === 'boleto' && (\r\n \r\n \r\n
    \r\n (Boleto Bancário)\r\n {conIndex === 0 && (\r\n

    {condicoes[conIndex]?.DescricaoPagamento}

    \r\n )}\r\n {conIndex > 0 && (\r\n

    {condicaoFaturado[conIndex - 1]?.DescricaoPagamento}

    \r\n )}\r\n
    \r\n
    \r\n )}\r\n\r\n {/* Case PIX */}\r\n\r\n {pickedMethod.id === 'pix' && (\r\n \r\n \r\n
    \r\n PIX\r\n

    Aprovação imediata

    \r\n
    \r\n
    \r\n )}\r\n\r\n {/* Case Crédito */}\r\n\r\n {pickedMethod.bandeira && (\r\n \r\n \r\n
    \r\n (Crédito){' '}\r\n \r\n {showFullFlagName(pickedMethod.bandeira)} Final{' '}\r\n {pickedMethod.numero}\r\n \r\n

    \r\n

    \r\n Pagar em{' '}\r\n {condicoes[conIndex]?.PercentualJuros === 0\r\n ? `${condicoes[conIndex]?.DescricaoPagamento} sem juros`\r\n : condicoes[conIndex]?.DescricaoPagamento}\r\n

    \r\n

    \r\n
    \r\n
    \r\n )}\r\n
    \r\n\r\n \r\n Alterar\r\n \r\n
    \r\n
    \r\n )\r\n}\r\n\r\nexport default AddressCardConfirmacao\r\n","import styled, { css, keyframes } from 'styled-components'\r\n\r\nconst showModal = keyframes`\r\n from {\r\n opacity: 0;\r\n } to {\r\n opacity: 1;\r\n }\r\n`\r\n\r\nexport const Background = styled.div`\r\n width: 100%;\r\n height: 100%;\r\n background: rgba(0, 0, 0, 0.7);\r\n transition: background 0.2s;\r\n position: fixed;\r\n display: flex;\r\n justify-content: center;\r\n align-items: center;\r\n z-index: 1000;\r\n animation: ${showModal} 200ms;\r\n`\r\n\r\nexport const ModalWrapper = styled.div`\r\n max-width: 420px;\r\n width: 100%;\r\n display: flex;\r\n flex-direction: column;\r\n box-shadow: 0 5px 16px rgba(0, 0, 0, 0.2);\r\n background: #fff;\r\n color: #000;\r\n position: relative;\r\n text-align: left;\r\n z-index: 10;\r\n border-radius: 5px;\r\n padding: 24px;\r\n\r\n @media (max-width: 560px) {\r\n max-width: 90%;\r\n margin: auto;\r\n }\r\n\r\n ${({ theme }) => css`\r\n .title {\r\n display: flex;\r\n margin-bottom: 4px;\r\n }\r\n\r\n img {\r\n margin-right: 8px;\r\n width: 28px;\r\n height: 28px;\r\n filter: invert(22%) sepia(78%) saturate(2710%) hue-rotate(341deg)\r\n brightness(88%) contrast(96%);\r\n }\r\n\r\n .modal-title {\r\n font-size: 24px;\r\n font-weight: 500;\r\n margin-bottom: 4px;\r\n color: ${theme.colors.primary};\r\n }\r\n\r\n .modal-description {\r\n margin-bottom: 16px;\r\n }\r\n\r\n .button-container {\r\n display: flex;\r\n flex-direction: row-reverse;\r\n }\r\n\r\n .listed {\r\n margin-left: 15px;\r\n }\r\n `}\r\n`\r\n\r\nexport const Button = styled.button`\r\n ${({ theme }) => css`\r\n max-width: 150px;\r\n width: 100%;\r\n margin-right: 12px;\r\n margin-top: 12px;\r\n\r\n border-radius: 5px;\r\n border: 2px solid transparent;\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 500;\r\n font-size: 16px;\r\n padding: 8px 40px;\r\n width: 100%;\r\n text-align: center;\r\n transition: ${theme.transition.default};\r\n cursor: pointer;\r\n background: ${theme.colors.primary};\r\n color: ${theme.colors.white};\r\n\r\n &:hover {\r\n background: #a71e26;\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: $MEDIA-IPAD) {\r\n font-size: 14px;\r\n }\r\n\r\n &.button-outline {\r\n background: transparent;\r\n border: 2px solid ${theme.colors.primary};\r\n color: ${theme.colors.primary};\r\n\r\n &:hover {\r\n border-color: #4a4a4a;\r\n color: #4a4a4a;\r\n }\r\n\r\n &:disabled {\r\n color: #7b7b7b;\r\n border-color: #7b7b7b;\r\n cursor: initial;\r\n }\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n & + .button {\r\n margin-left: 0;\r\n margin-top: 8px;\r\n }\r\n }\r\n `}\r\n`\r\n","import { useRef } from 'react'\r\nimport { Background, ModalWrapper, Button } from './styles'\r\nimport { useDispatch, useSelector } from 'react-redux'\r\n\r\nconst BloqueioModal = ({\r\n showModal,\r\n setShowModal,\r\n setCurrent,\r\n current,\r\n cardId,\r\n setLoading\r\n}) => {\r\n const modalRef = useRef()\r\n\r\n const dispatch = useDispatch()\r\n const store = useSelector((store) => store)\r\n\r\n const closeModal = (e) => {\r\n if (modalRef.current === e.target) {\r\n setShowModal(false)\r\n }\r\n }\r\n\r\n const handleAction = () => {\r\n const id = store.finalizado.pedido?.Bloqueio?.Itens?.map(\r\n (el) => el.IdProduto\r\n ).join('|')\r\n const query = `${process.env.REACT_APP_URL_MAIN}/checkout/carrinho?id=${id}`\r\n window.location.href = query\r\n }\r\n\r\n return (\r\n <>\r\n {showModal ? (\r\n \r\n \r\n
    \r\n

    \r\n
    \r\n

    \r\n Alguns produtos selecionados são bloqueados para a região\r\n selecionada.\r\n

    \r\n

    \r\n Favor remover do carrinho os produtos abaixo:\r\n

    \r\n
      \r\n {store.finalizado.pedido?.Bloqueio?.Itens?.map((el) => (\r\n
    • {el.Descricao}
    • \r\n ))}\r\n
    \r\n
    \r\n {/* setShowModal((prev) => !prev)}\r\n >\r\n Cancelar\r\n */}\r\n \r\n
    \r\n
    \r\n
    \r\n ) : null}\r\n \r\n )\r\n}\r\n\r\nexport default BloqueioModal\r\n","/* eslint-disable react-hooks/exhaustive-deps */\r\nimport { useState, useEffect } from 'react'\r\nimport { useSelector } from 'react-redux'\r\nimport { useHistory } from 'react-router-dom'\r\nimport Header from '../../components/Header'\r\nimport MediaMatch from '../../components/MediaMatch'\r\nimport Sellers from '../../components/Sellers/show'\r\nimport ResumoPedido from '../../components/ResumoPedido'\r\nimport Steps from '../../components/Steps'\r\nimport MyAddressModal from '../../components/MyAddressModal'\r\nimport AddressCardConfirmacao from '../../components/MyAddress/AddressCardConfirmacao'\r\nimport PaymentMethodConfirmacao from '../../components/PaymentCards/PaymentMethodConfirmacao'\r\nimport PaymentCardsModal from '../../components/PaymentCardsModal'\r\nimport { token } from '../../api/auth/auth'\r\nimport BloqueioModal from '../../components/BloqueioModal'\r\nimport { getLocalStorageLog } from '../../utils/traceLogAcessos'\r\nimport { useLocation } from 'react-router-dom'\r\nimport cookies from 'js-cookies'\r\n\r\nimport * as S from '../../styles/checkout'\r\n\r\nconst Confirmacao = () => {\r\n const router = useHistory()\r\n const [showModalAddress, setShowModalAddress] = useState(false)\r\n const [showModalPayment, setShowModalPayment] = useState(false)\r\n const [ipAddress, setIpAddress] = useState('')\r\n\r\n const [selectedAddress, setSelectedAddress] = useState('')\r\n const [bloqueio, setBloqueio] = useState(false)\r\n\r\n const store = useSelector((store) => store)\r\n\r\n const openModalAddress = () => {\r\n setShowModalAddress((prev) => !prev)\r\n }\r\n\r\n const openModalPayment = () => {\r\n setShowModalPayment((prev) => !prev)\r\n }\r\n const location = useLocation()\r\n\r\n useEffect(() => {\r\n window.dataLayer = window.dataLayer || []\r\n getLocalStorageLog(location.pathname)\r\n\r\n window.dataLayer.push({\r\n event: '/confirmacao'\r\n })\r\n }, [])\r\n\r\n useEffect(() => {\r\n if (!!!store.endereco.padrao.id) router.push(`/?token=${token()}`)\r\n }, [store.finalizado.pedido])\r\n\r\n const cartoes = store.pagamento.pagamento.CartoesSalvos?.map((e, i) => ({\r\n id: e.IdCartao,\r\n bandeira: e.Brand,\r\n descricao: e.DescricaoFormaPagamento,\r\n numero: e.MaskedNumber.slice(-4),\r\n vencimento: '',\r\n padrao: false\r\n }))\r\n\r\n const formas = store.pagamento.pagamento.Formas\r\n\r\n return (\r\n <>\r\n \r\n \r\n\r\n \r\n\r\n
    \r\n \r\n \r\n\r\n \r\n Confira e Finalize seu Pedido\r\n\r\n \r\n \r\n
    \r\n \r\n
    \r\n
    \r\n\r\n \r\n {/* CONTEÚDO PRINCIPAL DA PÁGINA */}\r\n {store.pagamento.condicaoFaturado?.IdTipo === 3 &&\r\n +store.pagamento?.condicaoIndex > 0 &&\r\n !!store.pagamento.pickF.id ? (\r\n openModalAddress()}\r\n data={store.endereco.padrao}\r\n />\r\n ) : (\r\n
    \r\n
    \r\n openModalAddress()}\r\n data={store.endereco.padrao}\r\n />\r\n
    \r\n
    \r\n openModalPayment()}\r\n cardData={cartoes}\r\n />\r\n
    \r\n
    \r\n )}\r\n\r\n \r\n\r\n {/* CONTEÚDO PRINCIPAL DA PÁGINA */}\r\n
    \r\n\r\n {/* COLUNA - RESUMO DO PEDIDO */}\r\n
    \r\n \r\n
    \r\n {/* COLUNA - RESUMO DO PEDIDO */}\r\n
    \r\n
    \r\n
    \r\n \r\n )\r\n}\r\nexport default Confirmacao\r\n","import defaultOptions from './defaultoption'\r\n\r\nconst pedidos = {\r\n async cotacao(\r\n OpcaoFiltro,\r\n Numero,\r\n DataInicial,\r\n DataFinal,\r\n Page = 1,\r\n PageSize = 15\r\n ) {\r\n let page = !!Page ? `Page=${Page}` : ''\r\n let pagesize = !!PageSize ? `&PageSize=${PageSize}` : ''\r\n let opcaofiltro = !!OpcaoFiltro ? `&OpcaoFiltro=${OpcaoFiltro}` : ''\r\n let numero = !!Numero ? `&Numero=${Numero}` : ''\r\n let datainicial = !!DataInicial\r\n ? `&DataInicial=${DataInicial.replace('/', '%2F')}`\r\n : ''\r\n let datafinal = !!DataFinal\r\n ? `&DataFinal=${DataFinal.replace('/', '%2F')}`\r\n : ''\r\n\r\n return await fetch(\r\n `${process.env.REACT_APP_API_PEDIDOS}api/cotacao?${page}${pagesize}${opcaofiltro}${numero}${datainicial}${datafinal}`,\r\n {\r\n method: 'get',\r\n headers: defaultOptions.headers\r\n }\r\n )\r\n },\r\n\r\n async negociacao(\r\n OpcaoFiltro,\r\n Numero,\r\n DataInicial,\r\n DataFinal,\r\n Page = 1,\r\n PageSize = 15\r\n ) {\r\n let page = !!Page ? `Page=${Page}` : ''\r\n let pagesize = !!PageSize ? `&PageSize=${PageSize}` : ''\r\n let opcaofiltro = !!OpcaoFiltro ? `&OpcaoFiltro=${OpcaoFiltro}` : ''\r\n let numero = !!Numero ? `&Numero=${Numero}` : ''\r\n let datainicial = !!DataInicial\r\n ? `&DataInicial=${DataInicial.replace('/', '%2F')}`\r\n : ''\r\n let datafinal = !!DataFinal\r\n ? `&DataFinal=${DataFinal.replace('/', '%2F')}`\r\n : ''\r\n\r\n return await fetch(\r\n `${process.env.REACT_APP_API_PEDIDOS}api/negociacao?${page}${pagesize}${opcaofiltro}${numero}${datainicial}${datafinal}`,\r\n {\r\n method: 'get',\r\n headers: defaultOptions.headers\r\n }\r\n )\r\n },\r\n\r\n async vendaPromovida(\r\n CodigoPromotor,\r\n IdPedido,\r\n DataInicial,\r\n DataFinal,\r\n Page = 1,\r\n PageSize = 15\r\n ) {\r\n let page = !!Page ? `&Page=${Page}` : ''\r\n let pagesize = !!PageSize ? `&PageSize=${PageSize}` : ''\r\n let codigoPromotor = !!CodigoPromotor\r\n ? `CodigoPromotor=${CodigoPromotor}`\r\n : ''\r\n let idPedido = !!IdPedido ? `&IdPedido=${IdPedido}` : ''\r\n let datainicial = !!DataInicial\r\n ? `&DataInicial=${DataInicial.replace('/', '%2F')}`\r\n : ''\r\n let datafinal = !!DataFinal\r\n ? `&DataFinal=${DataFinal.replace('/', '%2F')}`\r\n : ''\r\n\r\n return await fetch(\r\n `${process.env.REACT_APP_API_PEDIDOS}api/venda-promovida?${codigoPromotor}${idPedido}${datainicial}${datafinal}${page}${pagesize}`,\r\n {\r\n method: 'get',\r\n headers: defaultOptions.headers\r\n }\r\n )\r\n },\r\n\r\n async tagPedido() {\r\n return await fetch(`${process.env.REACT_APP_URL_MAIN}/checkout/pedidoefetuado`, {\r\n method: 'get'\r\n })\r\n },\r\n\r\n async tagNegociacao() {\r\n return await fetch(\r\n `${process.env.REACT_APP_URL_MAIN}/checkout/negociacaoefetuada`,\r\n { method: 'get' }\r\n )\r\n },\r\n\r\n async tagCotacao() {\r\n return await fetch(`${process.env.REACT_APP_URL_MAIN}/checkout/cotacaoefetuada`, {\r\n method: 'get'\r\n })\r\n }\r\n}\r\n\r\nexport default pedidos\r\n\r\n//mock codigo promotor 'RH097'\r\n","import styled, { css, keyframes } from 'styled-components'\r\n\r\nconst showModal = keyframes`\r\nfrom {\r\n opacity: 0;\r\n} to {\r\n opacity: 1;\r\n}\r\n`\r\n\r\nexport const Background = styled.div`\r\n width: 100%;\r\n height: 100%;\r\n background: rgba(0, 0, 0, 0.7);\r\n transition: background 0.2s;\r\n position: fixed;\r\n display: flex;\r\n justify-content: center;\r\n align-items: center;\r\n z-index: 100;\r\n animation: ${showModal} 200ms;\r\n`\r\n\r\nexport const ModalWrapper = styled.div`\r\n max-width: 600px;\r\n width: 100%;\r\n box-shadow: 0 5px 16px rgba(0, 0, 0, 0.2);\r\n background: #fff;\r\n color: #000;\r\n position: relative;\r\n text-align: left;\r\n z-index: 10;\r\n border-radius: 4px;\r\n padding: 16px;\r\n margin-top: -256px;\r\n\r\n p {\r\n font-size: 14px;\r\n line-height: 17px;\r\n margin: 8px 0;\r\n }\r\n\r\n strong {\r\n font-weight: 600;\r\n font-size: 14px;\r\n }\r\n\r\n .form-fields {\r\n display: flex;\r\n align-items: center;\r\n gap: 8px;\r\n margin-bottom: -18px;\r\n }\r\n\r\n div {\r\n flex: 5;\r\n }\r\n\r\n .ddd:first-child {\r\n min-width: 60px !important;\r\n flex: 1;\r\n }\r\n\r\n @media (max-width: 560px) {\r\n max-width: 90%;\r\n margin: auto;\r\n }\r\n`\r\n\r\nexport const TitleHead = styled.div`\r\n ${({ theme }) => css`\r\n display: flex;\r\n align-items: center;\r\n\r\n h3 {\r\n font-size: 24px;\r\n font-weight: 500;\r\n margin-left: 8px;\r\n\r\n color: #27ae60;\r\n\r\n @media (max-width: 500px) {\r\n font-size: 18px;\r\n }\r\n }\r\n\r\n img {\r\n width: 50px;\r\n }\r\n `}\r\n`\r\n\r\nexport const Button = styled.button`\r\n ${({ theme, disabled }) => css`\r\n font-family: 'Montserrat', sans-serif;\r\n font-size: 14px;\r\n font-weight: 500;\r\n text-align: center;\r\n\r\n margin-top: 4px;\r\n padding: 10px 16px;\r\n border-radius: 4px;\r\n\r\n border: 2px solid transparent;\r\n color: ${theme.colors.white};\r\n background: #27ae60;\r\n\r\n transition: ${theme.transition.default};\r\n cursor: pointer;\r\n\r\n &:hover {\r\n background: #33a161;\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: $MEDIA-IPAD) {\r\n font-size: 14px;\r\n }\r\n\r\n ${disabled &&\r\n css`\r\n background-color: #8f8f8f;\r\n\r\n &:hover {\r\n background-color: #8f8f8f;\r\n }\r\n `}\r\n\r\n &.button-outline {\r\n max-width: 146px;\r\n background: transparent;\r\n border: 2px solid #8f8f8f;\r\n color: #8f8f8f;\r\n\r\n &:hover {\r\n border-color: #4a4a4a;\r\n color: #4a4a4a;\r\n }\r\n\r\n &:disabled {\r\n color: #7b7b7b;\r\n border-color: #7b7b7b;\r\n cursor: initial;\r\n }\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n & + .button {\r\n margin-left: 0;\r\n margin-top: 8px;\r\n }\r\n }\r\n `}\r\n`\r\n\r\nexport const HeaderModalClose = styled.button`\r\n justify-self: flex-end;\r\n background: none;\r\n border: 0;\r\n position: absolute;\r\n right: 16px;\r\n transition: all 400ms;\r\n cursor: pointer;\r\n opacity: 0.8;\r\n\r\n img {\r\n width: 20px;\r\n }\r\n\r\n &:hover {\r\n opacity: 0.6;\r\n }\r\n`\r\n","import styled, { css } from 'styled-components'\r\nimport { keyframes } from 'styled-components'\r\n\r\nexport const Wrapper = styled.div`\r\n width: 80%;\r\n max-width: 800px;\r\n background-color: #fff;\r\n margin: 0 auto;\r\n padding: 32px;\r\n\r\n display: flex;\r\n flex-direction: column;\r\n justify-content: center;\r\n align-items: center;\r\n\r\n border-radius: 4px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.2);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.2);\r\n\r\n .qr-code-button {\r\n position: relative;\r\n }\r\n`\r\n\r\nexport const Title = styled.div`\r\n ${({ theme }) => css`\r\n h2 {\r\n font-size: 24px;\r\n font-weight: 600;\r\n line-height: 29.26px;\r\n text-align: center;\r\n color: ${theme.colors.primary};\r\n }\r\n `}\r\n`\r\nconst showTooltip = keyframes`\r\n from {\r\n opacity: 0;\r\n top: 0;\r\n } to {\r\n opacity: 1;\r\n top: -25px;\r\n }\r\n`\r\n\r\nexport const CopyTooltip = styled.span`\r\n ${({ active }) => css`\r\n display: none;\r\n position: absolute;\r\n padding: 10px 15px;\r\n top: -25px;\r\n right: -30px;\r\n min-width: 130px;\r\n\r\n background: #ffffff;\r\n border: 1px solid #afaeae;\r\n border-radius: 5px;\r\n font-size: 11px;\r\n font-weight: bold;\r\n line-height: 15px;\r\n text-transform: initial;\r\n transition: all 400ms;\r\n\r\n ${active &&\r\n css`\r\n display: block;\r\n animation: ${showTooltip} 400ms ease;\r\n `}\r\n `}\r\n`\r\n\r\nexport const CopyButton = styled.input`\r\n ${({ theme }) => css`\r\n cursor: pointer;\r\n background: #ffffff;\r\n padding: 8px 10px;\r\n margin-left: 5px;\r\n border: 1px solid #cccccc;\r\n border-radius: 5px;\r\n font-weight: 800;\r\n position: relative;\r\n width: 100px;\r\n background-size: 16px;\r\n background-repeat: no-repeat;\r\n background-position: right;\r\n background-position-x: 70px;\r\n\r\n background: ${theme.colors.cart};\r\n margin-top: 16px;\r\n width: fit-content;\r\n padding: 12px 32px;\r\n\r\n &:hover {\r\n background: #33a161;\r\n }\r\n\r\n &::selection {\r\n background: #ffffff;\r\n }\r\n `}\r\n`\r\n\r\nexport const Info = styled.div`\r\n ${({ theme }) => css`\r\n display: flex;\r\n flex-direction: column;\r\n align-items: center;\r\n justify-content: center;\r\n gap: 16px;\r\n padding: 16px 28px;\r\n text-align: center;\r\n font-size: 14px;\r\n line-height: 20px;\r\n\r\n h3 {\r\n font-size: 16px;\r\n }\r\n\r\n .numero-pedido {\r\n strong {\r\n font-size: 16px;\r\n text-decoration: underline;\r\n }\r\n }\r\n\r\n .boleto-visualizar {\r\n color: ${theme.colors.primary};\r\n\r\n a {\r\n font-weight: 600;\r\n text-decoration: underline;\r\n }\r\n }\r\n\r\n .boleto-aviso {\r\n font-size: 12px;\r\n font-weight: 300;\r\n line-height: 15px;\r\n width: 300px;\r\n }\r\n\r\n .pix {\r\n display: flex;\r\n flex-direction: column;\r\n align-items: center;\r\n\r\n p {\r\n margin-top: 8px;\r\n }\r\n\r\n .qr-code {\r\n background-color: #d4d4d4;\r\n width: 200px;\r\n height: 200px;\r\n }\r\n\r\n .pix-info {\r\n margin-top: 8px;\r\n padding: 16px;\r\n background-color: ${theme.colors.grey};\r\n border-radius: 8px;\r\n\r\n ul {\r\n list-style: none;\r\n text-align: left;\r\n\r\n li + li {\r\n margin-top: 8px;\r\n }\r\n }\r\n }\r\n }\r\n `}\r\n`\r\n\r\nexport const Button = styled.button`\r\n ${({ theme }) => css`\r\n border-radius: 5px;\r\n border: 2px solid transparent;\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 600;\r\n font-size: 14px;\r\n padding: 12px;\r\n margin-bottom: 10px;\r\n width: 100%;\r\n text-align: center;\r\n transition: ${theme.transition.default};\r\n cursor: pointer;\r\n background: ${theme.colors.primary};\r\n color: ${theme.colors.white};\r\n\r\n &:hover {\r\n background: #a71e26;\r\n }\r\n\r\n &.green {\r\n background: ${theme.colors.cart};\r\n margin-top: 16px;\r\n width: fit-content;\r\n padding: 12px 32px;\r\n\r\n &:hover {\r\n background: #33a161;\r\n }\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n & + .button {\r\n margin-left: 0;\r\n margin-top: 8px;\r\n }\r\n }\r\n `}\r\n`\r\n\r\nexport const FinalizadoST = styled.p`\r\n ${({ theme }) => css`\r\n color: ${theme.colors.primary};\r\n margin: 10px;\r\n text-align: center;\r\n `}\r\n`\r\n","export default __webpack_public_path__ + \"static/media/icon-whatsapp.1b8834df.svg\";","import { iframeLink } from '../../utils/utils'\r\nimport * as S from './styles'\r\nimport QRCode from 'react-qr-code'\r\nimport { useRef, useState } from 'react'\r\n\r\nconst PedidoFinalizado = ({\r\n type,\r\n localPagamento,\r\n localFinalizado,\r\n pixData\r\n}) => {\r\n // const store = useSelector((store) => store)\r\n // const localPagamento = JSON.parse(sessionStorage.getItem('pagamento'))\r\n // const localFinalizado = JSON.parse(sessionStorage.getItem('finalizado'))\r\n\r\n const pedido = localFinalizado //store.finalizado.pedido\r\n const boletoAVista = localPagamento?.condicaoIndex //store.pagamento.condicaoIndex\r\n const pagamentoFaturado = localPagamento?.pickF?.id //store.pagamento.pickF.id === 'boleto'\r\n\r\n // const qrCodeValue =\r\n // '00020126360014BR.GOV.BCB.PIX011454651716001150520400005303986540510.005802BR5925SUPRICORP SUPRIMENTOS LTD6009Sao Paulo62070503***6304D5E6'\r\n\r\n const [copy, setCopy] = useState(false)\r\n const codeRef = useRef()\r\n\r\n const qrCodeValue = pixData?.QrCode\r\n const qrCodeUrl = pixData?.QrCodeUrl\r\n const pixValidade = pixData?.DataVencimento?.replace(' ', ' às ')\r\n\r\n const popBoleto = () => {\r\n window.open(\r\n `${process.env.REACT_APP_URL_MAIN}/bradesco/gerarboleto/?idpedido=${\r\n pedido?.Id || pedido[1]?.Id\r\n }`\r\n )\r\n }\r\n\r\n const copyToClipboard = (qrCodeValue) => {\r\n navigator.clipboard.writeText(qrCodeValue)\r\n\r\n setCopy(true)\r\n setTimeout(() => {\r\n setCopy(false)\r\n }, 3000)\r\n }\r\n\r\n // console.log('type', type, boletoAVista, localPagamento)\r\n\r\n const inicial = () => iframeLink(process.env.REACT_APP_URL_MAIN)\r\n\r\n return (\r\n <>\r\n {type === 'boleto' && (\r\n \r\n \r\n

    \r\n Pedido realizado\r\n
    \r\n com sucesso\r\n

    \r\n
    \r\n\r\n \r\n
    \r\n

    Obrigado por comprar no Gimba

    \r\n
    \r\n\r\n
    \r\n Você receberá um e-mail com a confirmação e
    todos os\r\n detalhes do seu pedido.\r\n
    \r\n\r\n
    \r\n Número do Pedido
    \r\n \r\n \r\n iframeLink(\r\n `${process.env.REACT_APP_URL_CLIENTE}/meus-pedidos/${pedido?.Id}`\r\n )\r\n }\r\n >\r\n {pedido?.Id || pedido?.Validation?.Errors[0] || ''}\r\n
    \r\n \r\n
    \r\n\r\n {boletoAVista === 0 && (\r\n <>\r\n
    \r\n Caso não consiga visualizar o boleto,{' '}\r\n popBoleto()}\r\n style={{\r\n textDecoration: 'underline',\r\n fontWseight: 'bold',\r\n cursor: 'pointer'\r\n }}\r\n >\r\n clique aqui\r\n
    \r\n
    \r\n\r\n
    \r\n O boleto é gerado automaticamente em uma nova janela.\r\n Verifique se o seu navegador não esteja bloqueando POP-UP\r\n
    \r\n \r\n )}\r\n \r\n\r\n inicial()}>Ir para Página Inicial\r\n \r\n )}\r\n\r\n {type === 'faturado' && (\r\n \r\n \r\n

    \r\n Pedido realizado\r\n
    \r\n com sucesso\r\n

    \r\n
    \r\n\r\n \r\n
    \r\n

    Obrigado por comprar no Gimba

    \r\n
    \r\n\r\n
    \r\n Você receberá um e-mail com a confirmação e
    todos os\r\n detalhes do seu pedido.\r\n
    \r\n\r\n
    \r\n Número do Pedido
    \r\n \r\n \r\n iframeLink(\r\n `${process.env.REACT_APP_URL_CLIENTE}/meus-pedidos/${pedido[0]?.Id}`\r\n )\r\n }\r\n >\r\n {pedido[0]?.Id || pedido?.Validation?.Errors[0] || ''}\r\n
    \r\n \r\n \r\n\r\n
    \r\n Número do Pedido
    \r\n \r\n \r\n iframeLink(\r\n `${process.env.REACT_APP_URL_CLIENTE}/meus-pedidos/${pedido[1]?.Id}`\r\n )\r\n }\r\n >\r\n {pedido[1]?.Id || pedido?.Validation?.Errors[0] || ''}\r\n
    \r\n \r\n \r\n\r\n {pagamentoFaturado === 'boleto' && (\r\n <>\r\n
    \r\n Caso não consiga visualizar o boleto,{' '}\r\n popBoleto()}\r\n style={{\r\n textDecoration: 'underline',\r\n fontWseight: 'bold',\r\n cursor: 'pointer'\r\n }}\r\n >\r\n clique aqui\r\n
    \r\n \r\n\r\n
    \r\n O boleto é gerado automaticamente em uma nova janela.\r\n Verifique se o seu navegador não esteja bloqueando POP-UP\r\n
    \r\n \r\n )}\r\n\r\n {pagamentoFaturado === 'pix' && (\r\n
    \r\n {qrCodeValue === null ? (\r\n \r\n O seu código Pix está em processamento! Aguarde alguns\r\n instantes. Você pode consultar o seu pedido aqui\r\n \r\n ) : (\r\n <>\r\n
    \r\n {qrCodeUrl ? (\r\n \"\"\r\n ) : (\r\n \r\n )}\r\n
    \r\n\r\n
    \r\n copyToClipboard(qrCodeValue)}\r\n >\r\n Copiar código do PIX\r\n \r\n\r\n \r\n Código copiado!\r\n \r\n
    \r\n\r\n O código é válido até {pixValidade}\r\n\r\n

    \r\n Se o pagamento não for confirmado até a validade acima,{' '}\r\n
    o pedido será cancelado automaticamente.\r\n

    \r\n
    \r\n
      \r\n
    • \r\n 1 - Abra o app ou banco da sua\r\n preferência. Escolha a opção pagar com código PIX \"\r\n copia e cola\", ou código QR.\r\n
    • \r\n\r\n
    • \r\n 2 - Copie e cole o código, ou\r\n escaneie o código QR com a câmera do seu celular.\r\n Confira todas as informações e autorize o pagamento.\r\n
    • \r\n\r\n
    • \r\n 3 - Você vai receber a confirmação do\r\n pagamento em seu email. E pronto!\r\n
    • \r\n
    \r\n
    \r\n \r\n )}\r\n
    \r\n )}\r\n
    \r\n\r\n inicial()}>Ir para Página Inicial\r\n
    \r\n )}\r\n\r\n {type === 'pix' && (\r\n \r\n \r\n

    \r\n Pedido realizado\r\n
    \r\n com sucesso\r\n

    \r\n
    \r\n\r\n \r\n
    \r\n

    Obrigado por comprar no Gimba

    \r\n
    \r\n\r\n
    \r\n Você receberá um e-mail com a confirmação e
    todos os\r\n detalhes do seu pedido.\r\n
    \r\n\r\n
    \r\n {!!pedido?.Id && 'Número do Pedido'}
    \r\n \r\n \r\n iframeLink(\r\n `${process.env.REACT_APP_URL_CLIENTE}/meus-pedidos/${pedido?.Id}`\r\n )\r\n }\r\n >\r\n {pedido?.Id || pedido?.Validation?.Errors[0] || ''}\r\n
    \r\n \r\n \r\n\r\n
    \r\n {qrCodeValue === null ? (\r\n \r\n O seu código Pix está em processamento! Aguarde alguns\r\n instantes. Você pode consultar o seu pedido aqui\r\n \r\n ) : (\r\n <>\r\n
    \r\n {qrCodeUrl ? (\r\n \"\"\r\n ) : (\r\n \r\n )}\r\n
    \r\n\r\n
    \r\n copyToClipboard(qrCodeValue)}\r\n >\r\n Copiar código do PIX\r\n \r\n\r\n \r\n Código copiado!\r\n \r\n
    \r\n\r\n O código é válido até {pixValidade}\r\n

    \r\n Se o pagamento não for confirmado até a validade acima,{' '}\r\n
    o pedido será cancelado automaticamente.\r\n

    \r\n
    \r\n
      \r\n
    • \r\n 1 - Abra o app ou banco da sua\r\n preferência. Escolha a opção pagar com código PIX \"\r\n copia e cola\", ou código QR.\r\n
    • \r\n\r\n
    • \r\n 2 - Copie e cole o código, ou escaneie\r\n o código QR com a câmera do seu celular. Confira todas\r\n as informações e autorize o pagamento.\r\n
    • \r\n\r\n
    • \r\n 3 - Você vai receber a confirmação do\r\n pagamento em seu email. E pronto!\r\n
    • \r\n
    \r\n
    \r\n \r\n )}\r\n
    \r\n
    \r\n\r\n inicial()}>Ir para Página Inicial\r\n
    \r\n )}\r\n\r\n {/* {type === 'pix' && (\r\n \r\n \r\n

    \r\n Pedido realizado\r\n
    \r\n com sucesso\r\n

    \r\n
    \r\n\r\n \r\n
    \r\n

    Obrigado por comprar no Gimba

    \r\n
    \r\n\r\n
    \r\n Você receberá um e-mail com a confirmação e
    todos os\r\n detalhes do seu pedido.\r\n
    \r\n\r\n
    \r\n {!!pedido?.Id && 'Número do Pedido'}
    \r\n \r\n \r\n iframeLink(\r\n `${process.env.REACT_APP_URL_CLIENTE}/meus-pedidos/${pedido?.Id}`\r\n )\r\n }\r\n >\r\n {pedido?.Id || pedido?.Validation?.Errors[0] || ''}\r\n
    \r\n \r\n \r\n\r\n
    \r\n
    \r\n \r\n
    \r\n\r\n Copiar código do PIX\r\n\r\n O código é válido até as 2:00\r\n\r\n

    \r\n Se o pagamento não for confirmado o pedido
    será cancelado\r\n automaticamente.\r\n

    \r\n\r\n
    \r\n
      \r\n
    • \r\n 1 - Abra o app ou banco da sua preferência.\r\n Escolha a opção pagar com código PIX \" copia e cola\", ou\r\n código QR.\r\n
    • \r\n\r\n
    • \r\n 2 - Copie e cole o código, ou escaneie o\r\n código QR com a câmera do seu celular. Confira todas as\r\n informações e autorize o pagamento.\r\n
    • \r\n\r\n
    • \r\n 3 - Você vai receber a confirmação do\r\n pagamento em seu email. E pronto!\r\n
    • \r\n
    \r\n
    \r\n
    \r\n
    \r\n\r\n inicial()}>Ir para Página Inicial\r\n
    \r\n )} */}\r\n\r\n {type === false && (\r\n \r\n \r\n

    \r\n Pedido realizado\r\n
    \r\n com sucesso\r\n

    \r\n
    \r\n\r\n \r\n
    \r\n

    Obrigado por comprar no Gimba

    \r\n
    \r\n\r\n
    \r\n Você receberá um e-mail com a confirmação e
    todos os\r\n detalhes do seu pedido.\r\n
    \r\n\r\n
    \r\n {!!pedido?.Id && 'Número do Pedido'}
    \r\n \r\n \r\n iframeLink(\r\n `${process.env.REACT_APP_URL_CLIENTE}/meus-pedidos/${pedido?.Id}`\r\n )\r\n }\r\n >\r\n {pedido?.Id || pedido?.Validation?.Errors[0] || ''}\r\n
    \r\n \r\n \r\n
    \r\n\r\n inicial()}>Ir para Página Inicial\r\n
    \r\n )}\r\n \r\n )\r\n}\r\n\r\nexport default PedidoFinalizado\r\n","import styled from 'styled-components'\r\n\r\nexport const BlocoPesquisa = styled.div`\r\n display: flex;\r\n justify-content: center;\r\n position: relative;\r\n\r\n button {\r\n position: absolute;\r\n top: 130px;\r\n z-index: 99;\r\n padding: 4px 10px;\r\n border-radius: 3px;\r\n font-weight: 600;\r\n border: 1px solid rgb(53, 64, 82);\r\n right: 23vw;\r\n }\r\n\r\n #track__widget {\r\n position: absolute;\r\n margin: 0px auto;\r\n top: 160px;\r\n box-shadow: 0 0 0 99999px rgba(0, 0, 0, 0.8);\r\n z-index: 90;\r\n width: 54vw;\r\n }\r\n\r\n @media (max-width: 1279px) {\r\n\r\n button {\r\n right: 19vw;\r\n }\r\n\r\n #track__widget {\r\n width: 62vw;\r\n }\r\n\r\n }\r\n\r\n @media (max-width: 1024px) {\r\n\r\n button {\r\n right: 9vw;\r\n }\r\n\r\n #track__widget {\r\n width: 82vw;\r\n }\r\n\r\n }\r\n`\r\n","import { BlocoPesquisa } from './styles'\r\nimport { useCallback, useEffect, useRef, useState } from 'react'\r\n\r\nconst ModalPesquisa = ({ showPeqModal, setShowPeqModal }) => {\r\n const pesqTrackSalesRef = useRef()\r\n const [mostrarPesquisa, setMostrarPesquisa] = useState(false)\r\n\r\n const closeModalButton = () => {\r\n setShowPeqModal(false)\r\n setMostrarPesquisa(false)\r\n }\r\n\r\n const keyPress = useCallback(\r\n (e) => {\r\n if (e.key === 'Escape' && showPeqModal) {\r\n setShowPeqModal(false)\r\n }\r\n },\r\n [setShowPeqModal, showPeqModal]\r\n )\r\n\r\n useEffect(() => {\r\n document.addEventListener('keydown', keyPress)\r\n return () => document.removeEventListener('keydown', keyPress)\r\n }, [keyPress])\r\n\r\n useEffect(() => {\r\n const observer = new MutationObserver((mutationsList) => {\r\n for (const mutation of mutationsList) {\r\n if (mutation.type === 'childList') {\r\n const children = pesqTrackSalesRef.current.children\r\n const isOnlyBtnFecharPesquisa =\r\n children.length === 1 && children[0].id === 'BtnFecharPesquisa'\r\n setMostrarPesquisa(!isOnlyBtnFecharPesquisa)\r\n }\r\n }\r\n })\r\n\r\n observer.observe(pesqTrackSalesRef.current, { childList: true })\r\n\r\n return () => {\r\n observer.disconnect()\r\n }\r\n // eslint-disable-next-line react-hooks/exhaustive-deps\r\n }, [])\r\n\r\n return (\r\n <>\r\n {showPeqModal ? (\r\n \r\n \r\n X FECHAR\r\n \r\n \r\n ) : null}\r\n \r\n )\r\n}\r\n\r\nexport default ModalPesquisa\r\n","/* eslint-disable react-hooks/exhaustive-deps */\r\nimport { useEffect, useState } from 'react'\r\nimport { useSelector } from 'react-redux'\r\nimport clientes from '../../api/clientes'\r\nimport pedidos from '../../api/pedidos'\r\nimport AcompanharPedidoModal from '../../components/AcompanharPedidoModal'\r\nimport Header from '../../components/Header'\r\nimport PedidoFinalizado from '../../components/PedidoFinalizado'\r\nimport { iframeLink } from '../../utils/utils'\r\nimport { getLocalStorageLog } from '../../utils/traceLogAcessos'\r\nimport { useLocation } from 'react-router-dom'\r\n\r\nimport * as S from '../../styles/checkout'\r\nimport { isMobileSafari } from 'react-device-detect'\r\nimport ModalPesquisa from '../../components/ModalPesquisa'\r\n\r\nconst Finalizacao = () => {\r\n const [showModal, setShowModal] = useState(true)\r\n\r\n const [showPeqModal, setShowPeqModal] = useState(true)\r\n\r\n const [news, setNews] = useState({\r\n receberNovidades: false,\r\n receberWhatsApp: false\r\n })\r\n\r\n const store = useSelector((store) => store)\r\n\r\n const localFinalizado = JSON.parse(sessionStorage.getItem('finalizado'))\r\n const localPagamento = JSON.parse(sessionStorage.getItem('pagamento'))\r\n const localEndereco = JSON.parse(sessionStorage.getItem('localEndereco'))\r\n const pickedMethod = localPagamento?.pick //store.pagamento.pick\r\n const pickedMethodF = localPagamento?.pickF //store.pagamento.pickF\r\n const boletoAVista = localPagamento?.condicaoIndex //store.pagamento.condicaoIndex\r\n\r\n const user = JSON.parse(sessionStorage.getItem('localUser'))\r\n const userCel = user?.telefoneCelularNumero\r\n console.log(userCel)\r\n\r\n // console.log(Array.isArray(localFinalizado))\r\n let pedidoPix\r\n\r\n if (pickedMethodF?.id === 'pix') {\r\n pedidoPix = localFinalizado\r\n .filter((pedido) => pedido.PixPagamento.QrCode !== null)\r\n .map((pedido) => pedido.PixPagamento)[0]\r\n } else {\r\n pedidoPix = localFinalizado.PixPagamento\r\n }\r\n\r\n const linkboleto = `${\r\n process.env.REACT_APP_URL_MAIN\r\n }/bradesco/gerarboleto/?idpedido=${\r\n localFinalizado?.Id || localFinalizado[0]?.Id\r\n }`\r\n\r\n const fetchGet = async (set) => {\r\n try {\r\n let response = await clientes.getNews()\r\n response = await response.json()\r\n set(response)\r\n } catch (e) {}\r\n }\r\n\r\n const location = useLocation()\r\n useEffect(() => {\r\n fetchGet(setNews)\r\n }, [])\r\n\r\n useEffect(() => {\r\n if (\r\n localPagamento?.condicoes?.Descricao === 'Boleto à vista' &&\r\n boletoAVista === 0\r\n ) {\r\n setTimeout(() => {\r\n // console.log('5 seg')\r\n window.open(linkboleto)\r\n }, 5000)\r\n }\r\n\r\n if (\r\n !!isMobileSafari &&\r\n localPagamento?.condicoes?.Descricao === 'Boleto à vista' &&\r\n boletoAVista === 0\r\n ) {\r\n window.addEventListener(\r\n 'click',\r\n () => {\r\n window.open(linkboleto)\r\n },\r\n { once: true }\r\n )\r\n }\r\n\r\n // eslint-disable-next-line react-hooks/exhaustive-deps\r\n }, [])\r\n\r\n // useEffect(() => {\r\n // if (!!!store.finalizado.pedido.Id && !!!store.finalizado.pedido[0]?.Id) {\r\n // window.location.href = process.env.REACT_APP_URL_MAIN\r\n // } else {\r\n // // //pedidos.tagPedido().catch((e) => console.log(e))\r\n // }\r\n // // eslint-disable-next-line react-hooks/exhaustive-deps\r\n // }, [store.finalizado.pedido])\r\n\r\n //iframe - tageamento\r\n useEffect(() => {\r\n const us = JSON.parse(sessionStorage.getItem('localUser'))\r\n ;(function (f, b, g) {\r\n var a = {\r\n key: 'i2fEcZdM',\r\n appendTo: 'PesquisaTrackSales',\r\n customer: {\r\n name: us?.nome,\r\n email: us?.email,\r\n phone: us?.numeroTelefonePrincipal,\r\n Estado: localEndereco.uf,\r\n RazaoSocial: us?.nome,\r\n Celular: us?.telefoneCelularNumero,\r\n Cnpj: us?.cpf ? us?.cpf : us?.cnpj,\r\n DddCel: us?.telefoneCelularDDD,\r\n Ddd: us?.dddTelefonePrincipal\r\n }\r\n }\r\n\r\n var e\r\n var c = f.getElementsByTagName(b)[0]\r\n if (f.getElementById(g)) {\r\n return\r\n }\r\n e = f.createElement(b)\r\n e.id = g\r\n e.src = 'https://app.track.co/widget.min.js'\r\n e.type = 'text/javascript'\r\n e.async = true\r\n e.onload = e.onreadystatechange = function () {\r\n var h = this.readyState\r\n if (h && h !== 'complete' && h !== 'loaded') {\r\n return\r\n }\r\n try {\r\n // eslint-disable-next-line no-undef\r\n var c = new TrackWidget()\r\n c.createWidget(a)\r\n } catch (i) {}\r\n }\r\n c.parentNode.insertBefore(e, c)\r\n })(document, 'script', 'trackwidget-js')\r\n }, [])\r\n\r\n return (\r\n <>\r\n {/* */}\r\n\r\n
    \r\n\r\n {\r\n setShowModal(true)\r\n }}\r\n >\r\n Abrir modal\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n {/*
    \r\n \r\n iframeLink(\r\n 'https://www.ebitempresa.com.br/bitrate/pesquisa1.asp?empresa=112315'\r\n )\r\n }\r\n >\r\n \r\n
    \r\n */}\r\n
    \r\n {/* `\r\n }}\r\n /> */}\r\n \r\n )\r\n}\r\nexport default Finalizacao\r\n","export default __webpack_public_path__ + \"static/media/icon-breadcrumb-right.f0bc9767.svg\";","import styled from 'styled-components'\r\nimport inconBreadcrumbRight from '../assets/img/icon-breadcrumb-right.svg'\r\n\r\nexport const Breadcrumb = styled.ul`\r\n margin-bottom: 8px;\r\n list-style-type: none;\r\n display: block;\r\n /* margin-block-start: 1em; */\r\n margin-block-end: 1em;\r\n margin-inline-start: 0px;\r\n margin-inline-end: 0px;\r\n`\r\n\r\nexport const BreadcrumbItem = styled.li`\r\n display: inline-block;\r\n font-size: 13px;\r\n opacity: 0.7;\r\n &:after {\r\n content: '';\r\n background: url(${inconBreadcrumbRight}) center no-repeat;\r\n display: inline-block;\r\n width: 10px;\r\n height: 10px;\r\n margin-left: 5px;\r\n margin-right: 5px;\r\n }\r\n &:last-child {\r\n opacity: 1;\r\n }\r\n &:last-child:after {\r\n display: none;\r\n }\r\n`\r\n","import styled, { css } from 'styled-components'\n\nexport const BoxContainer = styled.div`\n ${({ theme, showAllItems }) => css`\n background: #ffffff;\n padding: 16px;\n border: 1px solid #e5e5e5;\n border-radius: 4px;\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\n margin-bottom: 8px;\n overflow: hidden;\n position: relative;\n\n @media (max-width: 800px) {\n display: none;\n }\n\n ${!showAllItems &&\n css`\n max-height: 350px;\n `}\n\n display: flex;\n flex-direction: column;\n\n .title {\n font-size: 18px;\n margin-bottom: 16px;\n font-weight: 500;\n }\n\n .content {\n .col-group {\n margin-left: 0;\n margin-right: 0;\n }\n }\n\n .ver-mais {\n padding: 24px 0;\n cursor: pointer;\n background-color: #fff;\n position: absolute;\n width: calc(100% - 32px);\n bottom: 0;\n\n &:hover {\n .checkout-cotacao-product-ver-mais,\n .checkout-cotacao-product-itens-negociacao {\n background: ${theme.colors.primary};\n\n &:after {\n color: ${theme.colors.primary};\n }\n }\n }\n }\n\n .checkout-cotacao-product-ver-mais,\n .checkout-cotacao-product-itens-negociacao {\n font-size: 0;\n display: block;\n background: #707070;\n height: 1px;\n width: 100%;\n position: relative;\n transition: all 400ms;\n font-style: normal;\n\n cursor: pointer;\n\n &:after {\n ${!showAllItems\n ? css`\n content: 'Ver mais itens';\n `\n : css`\n content: 'Ver menos itens';\n `}\n color: #707070;\n font-size: 14px;\n background: #ffffff;\n padding: 0 10px;\n position: absolute;\n left: 50%;\n top: 50%;\n transform: translate(-50%, -50%);\n transition: all 400ms;\n }\n }\n `}\n`\n","import styled, { css } from 'styled-components'\n\nexport const ProfileTitle = styled.h2`\n font-size: 22px;\n margin-bottom: 20px;\n color: #555;\n`\n\nexport const Wrapper = styled.div`\n margin-bottom: 8px;\n`\n\nexport const CardWrapper = styled.div`\n @media (min-width: 1170px) {\n .col-6 {\n width: 50%;\n }\n }\n`\n\nexport const CardBox = styled.div`\n display: flex;\n align-items: flex-start;\n margin-bottom: 15px;\n\n .iconCredit {\n width: 40px;\n display: flex;\n align-items: center;\n }\n`\n\nexport const MainCard = styled.div`\n align-items: flex-start;\n justify-content: center;\n\n label {\n max-width: 40px;\n max-height: 40px;\n display: flex;\n align-items: center;\n margin-top: -18px;\n }\n\n img {\n width: 60px;\n height: 60px;\n }\n`\n\nexport const CardInfo = styled.div`\n justify-self: left;\n font-size: 14px;\n margin-left: 4px;\n margin-right: 8px;\n width: 300px;\n\n p > p {\n color: #707070;\n }\n strong {\n font-weight: 600;\n }\n\n select.parcelas {\n padding: 6px 30px 6px 16px;\n margin-bottom: -10px;\n }\n`\n\nexport const CardInfoTitle = styled.p`\n margin-bottom: 2px;\n color: black;\n font-weight: 600;\n font-size: 15px;\n line-height: 17px;\n`\nexport const CardInfoLine = styled.div`\n display: flex;\n justify-content: flex-start;\n align-items: center;\n\n font-size: 12px;\n`\n\nexport const Seller = styled.p`\n text-decoration: underline;\n margin-left: 5px;\n font-size: 13px;\n`\n\nexport const Price = styled.p`\n font-weight: 600;\n font-size: 14px;\n @media (max-width: 1170px) {\n font-size: 12px !important;\n }\n`\n\nexport const CardLinePrice = styled.div`\n display: flex;\n`\n\nexport const IPI = styled.p`\n display: flex;\n flex-direction: column;\n justify-content: center;\n margin-left: 5px;\n font-weight: 500;\n font-size: 10px;\n font-style: italic;\n @media (max-width: 1170px) {\n font-size: 8px !important;\n white-space: nowrap;\n }\n`\nexport const AliquotaIPI = styled.p`\n display: flex;\n flex-direction: column;\n justify-content: center;\n font-weight: 500;\n font-style: italic;\n font-size: 10px;\n height: 20px;\n text-overflow: hidden;\n span {\n color: #fff;\n font-size: 10px;\n }\n`\n\nexport const Quantidade = styled.p`\n font-size: 14px;\n`\nexport const Alterar = styled.p`\n text-decoration: underline;\n margin-left: 10px;\n cursor: pointer;\n`\n","import * as S from './styles'\nimport {\n convertDecimalCurrency,\n formatarParaPorcentagem\n} from '../../../utils/utils'\nimport ImgMock from '../../../assets/img/relogio-thumb.png'\n\nconst CotacaoItem = ({ data, agenda, check, setCheck }) => {\n return (\n <>\n \n \n \n \n \n {/* \"produto\" */}\n \n \n {data?.name}\n {data.PossuiIPI ? (\n \n Produto Importado com alíquota de IPI de{' '}\n {formatarParaPorcentagem(data.PercentualIPI)}\n \n ) : (\n ''\n )}\n \n Vendido por:{data?.seller}\n \n \n
    \n \n {convertDecimalCurrency(data?.preco)}{' '}\n {data.PossuiIPI ? (\n \n (Com IPI de{' '}\n {convertDecimalCurrency(data?.ValorProdutoUnitarioIPI)}{' '}\n já incluso)\n \n ) : (\n ''\n )}\n \n \n Quantidade: {data?.quantidade}{' '}\n \n
    \n
    \n {data.PossuiIPI ? (\n <>\n ) : (\n \n {'-'}{' '}\n \n )}{' '}\n
    \n
    \n
    \n
    \n \n )\n}\n\nexport default CotacaoItem\n","import { useEffect, useState } from 'react'\nimport * as S from './styles'\nimport CardProduto from './CardProduto'\nimport { useSelector, useDispatch } from 'react-redux'\nimport { setProdutos } from '../../store/ducks/envio'\n\nconst CotacaoItens = ({ negociacao }) => {\n const store = useSelector((store) => store)\n const dispatch = useDispatch()\n\n const [showAllItems, setShowAllItems] = useState(false)\n const [products, setProducts] = useState([])\n\n const handleShowAllItems = () => {\n setShowAllItems((prev) => !prev)\n }\n\n const precoNovo = (data) => {\n let quant = data.ProdutosPercentualQuantidades || []\n const { PrecoVenda } = data\n if (quant.length === 0) return PrecoVenda\n\n let res = PrecoVenda\n quant = quant.sort((a, b) => a.Quantidade - b.Quantidade)\n for (let i = 0; i < quant.length; i++) {\n if (data.Quantidade >= quant[i].Quantidade) {\n res = quant[i].ValorNominal\n }\n }\n return res\n }\n\n const carrinhoGimba =\n store.envio.resumo?.Carrinho?.filter((e) => e.SellerId === null) || []\n\n const items = carrinhoGimba?.map((e, i) => ({\n id: e.Id,\n name: e.DescricaoResumida,\n idMedia: e.IdObjetoMedia,\n seller: 'Gimba',\n preco: precoNovo(e),\n quantidade: e.Quantidade,\n ValorProdutoUnitarioIPI: e.ValorProdutoUnitarioIPI,\n PossuiIPI: e.PossuiIPI,\n PercentualIPI: e.PercentualIPI\n }))\n\n useEffect(() => {\n dispatch(setProdutos(items))\n }, [store.envio.resumo])\n\n return (\n \n

    \n Itens da {!!negociacao ? 'Negociação' : 'Cotação'}\n

    \n\n
    \n
    \n {items?.map((product) => {\n return (\n
    \n \n
    \n )\n })}\n
    \n
    \n\n {carrinhoGimba?.length > 4 && (\n
    \n \n
    \n )}\n
    \n )\n}\n\nexport default CotacaoItens\n","import styled, { css } from 'styled-components'\r\n\r\nexport const CardBox = styled.div`\r\n background: #ffffff;\r\n padding: 16px;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 4px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 16px;\r\n\r\n .card-title {\r\n font-size: 18px;\r\n margin-bottom: 16px;\r\n font-weight: 500;\r\n }\r\n`\r\n\r\nexport const Total = styled.div`\r\n border-top: 1px solid rgba(187, 187, 187, 0.5);\r\n text-align: right;\r\n font-size: 14px;\r\n\r\n .total-value {\r\n display: flex;\r\n justify-content: space-between;\r\n margin-top: 8px;\r\n font-weight: 600;\r\n font-size: 14px;\r\n }\r\n\r\n @media (max-width: 800px) {\r\n border-top: none;\r\n\r\n .total-value {\r\n font-size: 16px;\r\n }\r\n }\r\n`\r\n\r\nexport const PedidoInfo = styled.ul`\r\n list-style: none;\r\n`\r\n\r\nexport const ItemInfo = styled.li`\r\n display: flex;\r\n justify-content: space-between;\r\n margin-bottom: 8px;\r\n font-size: 14px;\r\n\r\n p {\r\n position: relative;\r\n }\r\n`\r\n\r\nexport const MobileWrapper = styled.div`\r\n position: fixed;\r\n bottom: 0;\r\n width: 100vw;\r\n padding: 8px 4% 8px 2%;\r\n margin-left: -15px;\r\n display: flex;\r\n flex-direction: column;\r\n background-color: violet;\r\n background-color: #fbfbfb;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.2);\r\n`\r\n\r\nexport const Button = styled.button`\r\n ${({ theme }) => css`\r\n border-radius: 5px;\r\n border: 2px solid transparent;\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 500;\r\n font-size: 16px;\r\n padding: 15px 30px;\r\n margin-bottom: 10px;\r\n width: 100%;\r\n text-align: center;\r\n transition: ${theme.transition.default};\r\n cursor: pointer;\r\n background: ${theme.colors.primary};\r\n color: ${theme.colors.white};\r\n\r\n &:hover {\r\n background: #a71e26;\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: $MEDIA-IPAD) {\r\n font-size: 14px;\r\n }\r\n\r\n &.button-outline {\r\n background: transparent;\r\n border: 2px solid #8f8f8f;\r\n color: #8f8f8f;\r\n\r\n &:hover {\r\n border-color: #4a4a4a;\r\n color: #4a4a4a;\r\n }\r\n\r\n &:disabled {\r\n color: #7b7b7b;\r\n border-color: #7b7b7b;\r\n cursor: initial;\r\n }\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n & + .button {\r\n margin-left: 0;\r\n margin-top: 8px;\r\n }\r\n }\r\n `}\r\n`\r\n","import { useHistory } from 'react-router-dom'\n//import GimbaCard from '../PaymentCards/GimbaCard'\nimport Tooltip from '../Tooltip'\nimport * as S from './styles'\nimport { useSelector } from 'react-redux'\nimport { precoMask } from '../../utils/utils'\nimport { postPedido } from './fetch'\nimport { isPF } from '../../api/auth/auth'\nimport { useEffect, useState } from 'react'\n\nconst ResumoCotacao = ({ pagamento, envio, cotacao, negociacao }) => {\n const router = useHistory()\n const store = useSelector((store) => store)\n\n const sumFrete = () => {\n let keys = Object.keys(store.envio.fretePick)\n const pick = store.envio.fretePick\n\n keys = keys.reduce((acc, e, i) => {\n if (pick[e]?.id === 'agenda') {\n acc -= pick['Gimba']?.value\n }\n\n return acc + (pick[e]?.value || 0)\n }, 0)\n return keys || 0\n }\n\n const postFinal = () => {\n postPedido(() => router.push('/finalizado'), store)\n }\n\n const conFaturado = store.pagamento.pagamento?.Formas !== undefined && [\n ...(store.pagamento.pagamento?.Formas[1]?.Condicoes[0]?.Parcelas || []),\n ...(store.pagamento.pagamento?.Formas[1]?.Condicoes[1]?.Parcelas || [])\n ]\n const conIndex = store.pagamento?.condicaoIndex\n\n const [acrescimo, setAcrescimo] = useState(0)\n const [totalIPI, setTotalIPI] = useState(store.envio.resumo?.ValorIpi)\n\n //const condicoes = store.pagamento.condicoes?.Parcelas\n const condicoes =\n store.pagamento.condicoes?.Formas !== undefined &&\n store.pagamento.condicoes?.IdTipo === 3 &&\n !isPF() &&\n store.pagamento?.st.icms === false\n ? store.pagamento.condicoes?.Parcelas\n : conFaturado\n\n //const condicoes = store.pagamento.condicoes?.Parcelas\n const condicoesCartaoPJ =\n store.pagamento.pagamento?.Formas !== undefined &&\n store.pagamento.condicoes?.IdTipo === 1 &&\n !isPF()\n ? store.pagamento.condicoes?.Parcelas\n : null\n\n useEffect(() => {\n if (\n store.pagamento?.st.icms === true ||\n store.pagamento?.st.icms === false\n ) {\n if (condicoesCartaoPJ === null) {\n setAcrescimo(condicoes[conIndex].ValorSt)\n } else {\n setAcrescimo(condicoesCartaoPJ[conIndex].ValorSt)\n }\n } else {\n setAcrescimo(0)\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [\n condicoes,\n conIndex,\n store.pagamento?.st.icms,\n store.pagamento.condicoes?.IdTipo,\n acrescimo\n ])\n\n const carrinhoGimbaBool =\n store.envio.resumo?.Carrinho?.filter((e) => e.SellerId === null).length > 0\n\n const carrinhoSellerBool =\n store.envio.resumo?.Carrinho?.filter((e) => e.SellerId !== null).length > 0\n\n const verificarEAtualizarTotalIPI = (novoValorIPI) => {\n if (novoValorIPI !== totalIPI) {\n setTotalIPI(novoValorIPI)\n }\n }\n\n const condicoesBoleto = () => {\n if (\n store.pagamento.condicaoFaturado?.IdTipo === 3 &&\n conIndex > 0 &&\n carrinhoSellerBool\n ) {\n return ''\n }\n if (store.pagamento.condicoes?.IdTipo === 3 && conIndex <= 0) {\n verificarEAtualizarTotalIPI(\n store.pagamento.condicoes?.Parcelas[conIndex]?.ValorTotalIPI\n )\n return (\n
    \n

    {condicoes[conIndex]?.DescricaoPagamento}

    \n

    \n Valor com desconto:{' '}\n {!!cotacao &&\n precoMask(\n store.pagamento.condicoes?.Parcelas[conIndex]?.ValorParcela *\n store.pagamento.condicoes?.Parcelas[conIndex]?.NumeroParcela\n )}\n {!!negociacao &&\n precoMask(\n store.pagamento.condicoes?.Parcelas[conIndex]?.ValorParcela *\n store.pagamento.condicoes?.Parcelas[conIndex]?.NumeroParcela\n )}\n

    \n
    \n )\n }\n if (store.pagamento.condicoes?.IdTipo === 3 && conIndex > 0) {\n verificarEAtualizarTotalIPI(condicoes[conIndex]?.ValorTotalIPI)\n return (\n
    \n

    {condicoes[conIndex]?.DescricaoPagamento}

    \n {condicoes[conIndex]?.PercentualJuros > 0 && (\n

    \n Valor com acréscimo:{' '}\n {!!cotacao &&\n precoMask(\n condicoes[conIndex]?.ValorParcela *\n condicoes[conIndex]?.NumeroParcela\n )}\n {!!negociacao &&\n precoMask(\n condicoes[conIndex]?.ValorParcela *\n condicoes[conIndex]?.NumeroParcela\n )}\n

    \n )}\n
    \n )\n }\n }\n\n const condicoesCartao = () => {\n if (store.pagamento.condicoes?.IdTipo === 1 && condicoes !== undefined) {\n if (isPF() === true) {\n verificarEAtualizarTotalIPI(\n store.pagamento.condicoes?.Parcelas[conIndex]?.ValorTotalIPI\n )\n return (\n
    \n {}\n

    \n em{' '}\n {\n store.pagamento.condicoes?.Parcelas[conIndex]\n ?.DescricaoPagamento\n }\n

    \n {store.pagamento.condicoes?.Parcelas[conIndex]?.PercentualJuros !==\n 0 && (\n

    \n Valor com acréscimo:{' '}\n {precoMask(\n store.pagamento.condicoes?.Parcelas[conIndex]?.ValorParcela *\n store.pagamento.condicoes?.Parcelas[conIndex]?.NumeroParcela\n )}\n

    \n )}\n
    \n )\n } else {\n verificarEAtualizarTotalIPI(condicoesCartaoPJ[conIndex]?.ValorTotalIPI)\n return (\n
    \n {' '}\n

    em {condicoesCartaoPJ[conIndex]?.DescricaoPagamento}

    \n {condicoesCartaoPJ[conIndex]?.PercentualJuros !== 0 && (\n

    \n Valor com acréscimo:{' '}\n {precoMask(\n condicoesCartaoPJ[conIndex]?.ValorParcela *\n condicoesCartaoPJ[conIndex]?.NumeroParcela\n )}\n

    \n )}\n
    \n )\n }\n }\n return ''\n }\n\n const condicoesPix = () => {\n if (store.pagamento.pick.id === 'pix' && condicoes !== undefined) {\n verificarEAtualizarTotalIPI(\n store.pagamento.condicoes?.Parcelas[conIndex]?.ValorTotalIPI\n )\n return (\n
    \n {store.pagamento.condicoes?.Parcelas[conIndex]?.PercentualDesconto ===\n 0 ? (\n

    \n {precoMask(\n store.pagamento.condicoes?.Parcelas[conIndex]?.ValorParcela *\n store.pagamento.condicoes?.Parcelas[conIndex]?.NumeroParcela\n )}\n

    \n ) : (\n <>\n

    \n {\n store.pagamento.condicoes?.Parcelas[conIndex]\n ?.DescricaoPagamento\n }\n

    \n

    \n Valor com desconto:{' '}\n {precoMask(\n store.pagamento.condicoes?.Parcelas[conIndex]?.ValorParcela *\n store.pagamento.condicoes?.Parcelas[conIndex]?.NumeroParcela\n )}\n

    \n \n )}\n
    \n )\n }\n }\n\n let quantidadeTotal = 0\n store.envio.resumo.Carrinho?.forEach((item) => {\n quantidadeTotal += item.Quantidade\n })\n const valorProdutosConsolidado = () =>\n store.envio.resumo.ValorProdutos + store.envio.resumo.ValorProdutosSeller\n\n const ValorFinalCotacao =\n valorProdutosConsolidado() +\n sumFrete() +\n (store.pagamento.pick.id === undefined ? 0 : acrescimo) +\n (totalIPI || store.envio.resumo?.ValorIpi) -\n (store.pagamento.pagamento.Resumo?.ValorGimplus || 0) -\n (store.pagamento.pagamento.Resumo?.ValorCupom || 0)\n\n const ValorFinalNegociacao =\n ValorFinalCotacao -\n (store.pagamento.pagamento.Resumo?.ValorDescontoNegociacao || 0)\n\n return (\n <>\n {!!cotacao && (\n <>\n \n
    Resumo da Cotação
    \n \n \n

    Produtos ({quantidadeTotal} itens)

    \n

    {precoMask(store.envio.resumo.ValorProdutos)}

    \n
    \n \n

    Frete

    {precoMask(sumFrete())}

    \n
    \n \n {store.envio.resumo.Carrinho &&\n store.envio.resumo.Carrinho.some((item) => item.PossuiIPI) ? (\n <>\n

    \n IPI\n }\n message={\n 'Imposto federal aplicado sobre produtos industrializados. A taxa do IPI varia conforme a categoria do produto e é estabelecida pelo governo.'\n }\n />{' '}\n

    \n

    \n {' '}\n {precoMask(totalIPI || store.envio.resumo?.ValorIpi)}{' '}\n

    \n \n ) : (\n ''\n )}\n
    \n\n {store.pagamento.pagamento.Resumo?.ValorGimplus === 0 ? null : (\n \n

    \n Gimplus\n }\n message=\"Saldo Gimplus utilizado\"\n />\n

    {' '}\n

    \n {precoMask(\n store.pagamento.pagamento.Resumo?.ValorGimplus,\n true\n )}\n

    \n
    \n )}\n {store.pagamento.pagamento.Resumo?.ValorCupom === 0 ? null : (\n \n

    Cupom

    {' '}\n

    \n {precoMask(\n store.pagamento.pagamento.Resumo?.ValorCupom,\n true\n )}\n

    \n
    \n )}\n {acrescimo === 0 ||\n store.pagamento.pick.id === undefined ? null : (\n \n

    ICMS-ST

    {precoMask(acrescimo)}

    \n
    \n )}\n
    \n\n \n
    \n

    Total

    {precoMask(ValorFinalCotacao)}

    \n
    \n {condicoesBoleto()}\n\n {condicoesCartao()}\n\n {condicoesPix()}\n
    \n
    \n \n )}\n\n {!!negociacao && (\n <>\n \n
    Resumo da Negociação
    \n\n \n \n

    Produtos ({quantidadeTotal} itens)

    \n

    \n {precoMask(store.pagamento.pagamento.Resumo?.ValorProdutos)}\n

    \n
    \n \n

    Frete

    {precoMask(sumFrete())}

    \n
    \n \n {store.envio.resumo.Carrinho &&\n store.envio.resumo.Carrinho.some((item) => item.PossuiIPI) ? (\n <>\n

    \n IPI\n }\n message={\n 'Imposto federal aplicado sobre produtos industrializados. A taxa do IPI varia conforme a categoria do produto e é estabelecida pelo governo.'\n }\n />\n

    \n

    \n {' '}\n {precoMask(totalIPI || store.envio.resumo?.ValorIpi)}{' '}\n

    \n \n ) : (\n ''\n )}{' '}\n
    \n \n {store.pagamento.pagamento.Resumo?.ValorDescontoNegociacao >\n 0 ? (\n <>\n

    Desconto

    \n

    \n {precoMask(\n store.pagamento.pagamento.Resumo\n ?.ValorDescontoNegociacao\n )}\n

    {' '}\n \n ) : (\n ''\n )}\n
    \n {store.pagamento.pagamento.Resumo?.ValorGimplus === 0 ? null : (\n \n

    \n Gimplus\n }\n message=\"Saldo Gimplus utilizado\"\n />\n

    {' '}\n

    \n {precoMask(\n store.pagamento.pagamento.Resumo?.ValorGimplus,\n true\n )}\n

    \n
    \n )}\n {/* Exibir CUPOM apenas caso aplicado */}\n {store.pagamento.pagamento.Resumo?.ValorCupom === 0 ? null : (\n \n

    Cupom

    {' '}\n

    \n {precoMask(\n store.pagamento.pagamento.Resumo?.ValorCupom,\n true\n )}\n

    \n
    \n )}\n {/*aplicar ST cando houver */}\n {acrescimo === 0 ||\n store.pagamento.pick.id === undefined ? null : (\n \n

    ICMS-ST

    {precoMask(acrescimo)}

    \n
    \n )}\n
    \n\n \n
    \n

    Total

    {precoMask(ValorFinalNegociacao)}

    \n
    \n\n {condicoesBoleto()}\n\n {condicoesCartao()}\n\n {condicoesPix()}\n
    \n
    \n \n )}\n \n )\n}\n\nexport default ResumoCotacao\n","import styled, { css } from 'styled-components'\r\n\r\nexport const CardBox = styled.div`\r\n background: #ffffff;\r\n padding: 16px;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 4px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 20px;\r\n\r\n .address {\r\n display: flex;\r\n flex-direction: column;\r\n align-items: flex-start;\r\n justify-content: space-between;\r\n\r\n /* @media (max-width: 500px) {\r\n button {\r\n margin-top: 10px;\r\n }\r\n } */\r\n\r\n .col-group {\r\n margin-left: 0;\r\n margin-right: 0;\r\n }\r\n }\r\n\r\n .endereco-card-title {\r\n font-size: 16px;\r\n display: block;\r\n font-weight: 500;\r\n }\r\n\r\n .endereco-card-title span {\r\n font-weight: normal;\r\n }\r\n\r\n .endereco-card-description {\r\n font-weight: 400;\r\n font-size: 14px;\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n .perfil-box {\r\n padding: 30px 20px 10px 20px;\r\n }\r\n }\r\n\r\n @media (min-width: 1170px) and (max-width: 1360px) {\r\n .endereco-card-title {\r\n font-size: 14px;\r\n }\r\n\r\n .endereco-card-description {\r\n font-size: 14px;\r\n }\r\n }\r\n`\r\n\r\nexport const CardAddressType = styled.div`\r\n font-size: 16px;\r\n display: flex;\r\n justify-content: space-between;\r\n margin-bottom: 8px;\r\n\r\n width: 100%;\r\n`\r\nexport const Address = styled.h3``\r\n\r\nexport const ProfileBox = styled.div`\r\n background: #ffffff;\r\n padding: 30px 30px 30px 30px;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 10px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 20px;\r\n`\r\n\r\nexport const ProfileBoxFooter = styled.div`\r\n margin: 10px 0 20px 0;\r\n\r\n @media (max-width: 1170px) {\r\n display: flex;\r\n flex-direction: column;\r\n }\r\n`\r\n\r\nexport const ButtonChangeAddress = styled.button`\r\n ${({ theme }) => css`\r\n color: rgba(46, 46, 46, 1);\r\n font-family: 'Montserrat';\r\n font-size: 13px;\r\n font-weight: 400;\r\n background: transparent;\r\n border: 0;\r\n cursor: pointer;\r\n transition: all ease-in-out 400ms;\r\n text-decoration: underline;\r\n align-self: flex-start;\r\n\r\n &:hover {\r\n color: rgba(46, 46, 46, 0.7);\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: $MEDIA-IPAD) {\r\n font-size: 14px;\r\n }\r\n `}\r\n`\r\n","import styled, { css } from 'styled-components'\r\n\r\nexport const ProfileTitle = styled.h2`\r\n font-size: 22px;\r\n margin-bottom: 20px;\r\n color: #555;\r\n`\r\n\r\nexport const Wrapper = styled.div`\r\n display: flex;\r\n align-items: center;\r\n\r\n margin-top: 8px;\r\n margin-left: 0px;\r\n`\r\n\r\nexport const CardWrapper = styled.div`\r\n @media (min-width: 1170px) {\r\n .col-6 {\r\n width: 50%;\r\n }\r\n }\r\n`\r\n\r\nexport const CardBox = styled.div`\r\n padding: 8px 16px;\r\n display: flex;\r\n align-items: center;\r\n\r\n background: #ffffff;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 5px;\r\n\r\n margin-bottom: 8px;\r\n\r\n .iconCredit {\r\n width: 40px;\r\n display: flex;\r\n align-items: center;\r\n }\r\n`\r\n\r\nexport const MainCard = styled.div`\r\n max-width: 40px;\r\n height: 100%;\r\n /* width: 100%; */\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n align-self: flex-start;\r\n\r\n /* position: relative; */\r\n\r\n [type='checkbox']:not(:checked) + label:before {\r\n border: 1px solid #afaeae;\r\n }\r\n\r\n label {\r\n max-width: 40px;\r\n max-height: 40px;\r\n display: flex;\r\n align-items: center;\r\n\r\n /* margin-top: -18px; */\r\n }\r\n`\r\n\r\nexport const CardInfo = styled.div`\r\n ${({ theme, check }) => css`\r\n justify-self: left;\r\n font-size: 14px;\r\n width: 240px;\r\n margin-left: 0px;\r\n\r\n p > p {\r\n color: #707070;\r\n }\r\n\r\n strong {\r\n font-weight: 600;\r\n }\r\n\r\n select.parcelas {\r\n padding: 6px 30px 6px 16px;\r\n margin-bottom: -10px;\r\n }\r\n\r\n p {\r\n color: #4a4a4a;\r\n }\r\n\r\n /* ${check?.name !== 'Entrega Agendada' &&\r\n css`\r\n p {\r\n color: #4a4a4a;\r\n }\r\n `} */\r\n\r\n .agendamento {\r\n display: flex;\r\n gap: 8px;\r\n margin-top: 10px;\r\n\r\n input,\r\n select {\r\n width: 120px;\r\n height: 32px;\r\n font-family: 'Montserrat';\r\n font-size: 13px;\r\n border-radius: 4px;\r\n border: 1px solid #ced4d4;\r\n\r\n &::placeholder {\r\n color: #707070;\r\n }\r\n }\r\n\r\n select {\r\n width: 80px;\r\n }\r\n\r\n select {\r\n padding-left: 8px;\r\n }\r\n }\r\n `}\r\n`\r\nexport const CardInfoTitle = styled.p`\r\n color: #d22630;\r\n font-weight: 400;\r\n font-size: 14px;\r\n position: relative;\r\n max-width: 156px;\r\n\r\n i {\r\n right: -12px;\r\n }\r\n`\r\n","import CalendarDatePicker from '../../CalendarDatePicker'\r\nimport { precoMask } from '../../../utils/utils'\r\nimport * as S from './styles'\r\nimport { useDispatch, useSelector } from 'react-redux'\r\nimport { setFretePick, setTurno } from '../../../store/ducks/envio'\r\nimport { useEffect } from 'react'\r\nimport Tooltip from '../../Tooltip'\r\n\r\nconst FreteAgendaCotacao = ({ data, agenda, check, seller }) => {\r\n const dispatch = useDispatch()\r\n const store = useSelector((store) => store)\r\n\r\n return (\r\n <>\r\n \r\n \r\n {\r\n if (store.envio.fretePick.Agenda?.id === 'agenda') {\r\n dispatch(\r\n setFretePick(seller, {\r\n id: 'no',\r\n name: '',\r\n time: 0,\r\n value: 0\r\n })\r\n )\r\n } else {\r\n dispatch(setFretePick(seller, data))\r\n }\r\n }}\r\n />\r\n \r\n \r\n\r\n \r\n \r\n {data?.name}\r\n\r\n }\r\n message=\"Somente Estado de São Paulo\"\r\n />\r\n \r\n\r\n {check?.id === data.id && (\r\n <>\r\n

    Somente Estado de São Paulo

    \r\n
    \r\n \r\n dispatch(setTurno(e.target.value))}\r\n >\r\n {/* */}\r\n \r\n \r\n {/* */}\r\n \r\n
    \r\n \r\n )}\r\n
    \r\n
    \r\n \r\n )\r\n}\r\n\r\nexport default FreteAgendaCotacao\r\n","import * as S from './styles'\r\nimport { useEffect, useState } from 'react'\r\nimport { capitalizePhrase } from '../../../utils/utils'\r\nimport CardFreteAgenda from '../../Sellers/CardFreteAgenda'\r\nimport FreteAgendaCotacao from '../CardFreteAgenda'\r\nimport { useSelector, useDispatch } from 'react-redux'\r\nimport { setFretePick } from '../../../store/ducks/envio'\r\nimport { precoMask } from '../../../utils/utils'\r\n\r\nconst OpcoesFrete = ({ showModal, data }) => {\r\n const store = useSelector((store) => store)\r\n const dispatch = useDispatch()\r\n\r\n const frete = store.envio.fretePick?.Gimba\r\n\r\n return (\r\n \r\n
    \r\n \r\n

    Opções de Envio

    \r\n\r\n showModal()}>\r\n Alterar\r\n \r\n
    \r\n\r\n \r\n

    {frete?.name || '-'}

    \r\n

    \r\n Frete:{' '}\r\n {frete?.value === 0 ? 'Grátis' : precoMask(frete?.value) || '-'} |{' '}\r\n Entrega: {' '}\r\n {!!frete?.time ? `${frete?.time} dias úteis` : '-'}\r\n

    \r\n
    \r\n {store.endereco.padrao?.uf === 'SP' && (\r\n \r\n )}\r\n
    \r\n
    \r\n )\r\n}\r\n\r\nexport default OpcoesFrete\r\n","import styled, { css } from 'styled-components'\r\n\r\nexport const ProfileTitle = styled.h2`\r\n font-size: 22px;\r\n margin-bottom: 20px;\r\n color: #555;\r\n`\r\n\r\nexport const Wrapper = styled.div`\r\n display: flex;\r\n align-items: flex-start;\r\n margin-left: 4px;\r\n margin-top: 8px;\r\n\r\n img {\r\n width: 40px;\r\n }\r\n\r\n .formas {\r\n margin-left: 16px;\r\n width: 100%;\r\n padding-top: 6px;\r\n\r\n select {\r\n padding: 8px;\r\n padding-right: 32px;\r\n margin-bottom: 4px;\r\n background-color: #fbfbfb;\r\n border: 1px solid #ced4da;\r\n color: #2e2e2e;\r\n }\r\n }\r\n\r\n h3 {\r\n font-size: 14px;\r\n font-weight: 600;\r\n margin-bottom: 8px;\r\n }\r\n`\r\n\r\nexport const CardWrapper = styled.div`\r\n @media (min-width: 1170px) {\r\n .col-6 {\r\n width: 50%;\r\n }\r\n }\r\n`\r\n\r\nexport const CardBox = styled.div`\r\n padding: 8px 16px;\r\n height: 100px;\r\n display: flex;\r\n align-items: center;\r\n justify-content: flex-start;\r\n position: relative;\r\n\r\n background: #ffffff;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 4px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 8px;\r\n\r\n .iconCredit {\r\n /* background-color: blue; */\r\n display: flex;\r\n align-items: center;\r\n padding-left: 2px;\r\n\r\n @media (max-width: 480px) {\r\n width: 32px;\r\n }\r\n }\r\n`\r\n\r\nexport const MainCard = styled.div`\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n\r\n label {\r\n position: absolute;\r\n display: flex;\r\n align-items: center;\r\n margin-top: 3px;\r\n }\r\n`\r\n\r\nexport const CardInfo = styled.div`\r\n justify-self: left;\r\n font-size: 14px;\r\n margin-left: 16px;\r\n margin-right: 8px;\r\n width: 240px;\r\n flex: 1;\r\n\r\n strong {\r\n font-weight: 600;\r\n }\r\n\r\n select.parcelas {\r\n padding: 8px 30px 8px 16px;\r\n margin: 4px 8px -12px 0;\r\n max-width: 280px;\r\n\r\n @media (max-width: 545px) {\r\n max-width: calc(100% - 20px);\r\n }\r\n }\r\n`\r\n\r\nexport const CardIcon = styled.a`\r\n transition: all 400ms;\r\n right: 22px;\r\n /* flex: 1; */\r\n text-align: right;\r\n position: relative;\r\n\r\n & img {\r\n width: 18px;\r\n height: 21px;\r\n cursor: pointer;\r\n\r\n &:hover {\r\n filter: invert(22%) sepia(78%) saturate(2710%) hue-rotate(341deg)\r\n brightness(88%) contrast(96%);\r\n }\r\n\r\n @media (max-width: 480px) {\r\n width: 16px;\r\n }\r\n }\r\n`\r\n","import * as S from './styles'\nimport Select from '../../../Select'\nimport { useEffect, useState } from 'react'\nimport {\n setCondicaoIndex,\n setPagamento,\n setCondicoes\n} from '../../../../store/ducks/pagamento'\nimport CreditCardImage from '../../../PaymentCards/CreditCardImage'\nimport { useSelector, useDispatch } from 'react-redux'\nimport { isPF } from '../../../../api/auth/auth'\nimport { formatarParaPorcentagem } from '../../../../utils/utils'\n\nconst BoletoCotacao = ({ check, setCheck }) => {\n const dispatch = useDispatch()\n const store = useSelector((store) => store)\n const [data, setData] = useState({ id: '' })\n\n const [showOptions, setShowOptions] = useState({\n showOptions: false\n })\n\n const handleShowSelected = (cardDetail) => {\n setShowOptions({\n [cardDetail]: !showOptions[cardDetail]\n })\n }\n\n const condicoes = store.pagamento.condicoes\n const pag = store.pagamento.pagamento\n const opcoes = !!pag.Formas ? pag?.Formas[1]?.Condicoes : []\n const parcelas = isPF()\n ? opcoes[0]?.Parcelas || []\n : [...(opcoes[0]?.Parcelas || []), ...(opcoes[1]?.Parcelas || [])]\n\n const { condicaoIndex } = store.pagamento\n\n let condBoleto\n\n if (store.pagamento.pagamento.Formas) {\n if (condicaoIndex === 0) {\n condBoleto = store.pagamento.pagamento.Formas[1]?.Condicoes[0]\n } else {\n condBoleto = store.pagamento.pagamento.Formas[1]?.Condicoes[1]\n }\n }\n\n // console.log(condBoleto)\n\n useEffect(() => {\n if (!!store.pagamento.pagamento.Formas) {\n setData(store.pagamento.pagamento.Formas[1])\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [store.pagamento.pagamento.Formas])\n\n useEffect(() => {\n if (store.pagamento.pick?.id === 'boleto') {\n condBoleto && dispatch(setCondicoes(condBoleto))\n // dispatch(setCondicaoIndex(0))\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [store.pagamento.pick])\n\n useEffect(() => {\n if (store.pagamento.pick?.id === 'boleto') {\n condBoleto && dispatch(setCondicoes(condBoleto))\n // dispatch(setCondicaoIndex(0))\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [condBoleto])\n\n return (\n <>\n \n \n {\n setCheck({ id: 'boleto' })\n dispatch(setCondicaoIndex(0))\n }}\n />\n \n \n\n \n\n
    \n

    Boleto Bancário

    \n {check?.id === 'boleto' && (\n {\n dispatch(setCondicaoIndex(Number(res)))\n }}\n options={\n parcelas.map((e, i) => ({\n label: e.DescricaoPagamento,\n value: i\n })) || [{ label: 'Selecione', value: '', hidden: true }]\n }\n >\n )}\n
    \n\n {/* \n

    \n {data.Descricao} \n

    \n
    */}\n
    \n \n )\n}\n\nexport default BoletoCotacao\n","/* eslint-disable react-hooks/exhaustive-deps */\r\nimport * as S from '../Boleto/styles'\r\nimport Select from '../../../Select'\r\nimport { useEffect, useState } from 'react'\r\nimport {\r\n setCondicaoIndex,\r\n setCondicoes\r\n} from '../../../../store/ducks/pagamento'\r\nimport CreditCardImage from '../../../PaymentCards/CreditCardImage'\r\nimport { useSelector, useDispatch } from 'react-redux'\r\n\r\nconst CartaoCotacao = ({ check, setCheck }) => {\r\n const dispatch = useDispatch()\r\n const store = useSelector((store) => store)\r\n const [data, setData] = useState({ id: '' })\r\n const [selectedCard, setSelectedCard] = useState('')\r\n\r\n const [showOptions, setShowOptions] = useState({\r\n showOptions: false\r\n })\r\n\r\n const handleShowSelected = (cardDetail) => {\r\n setShowOptions({\r\n [cardDetail]: !showOptions[cardDetail]\r\n })\r\n }\r\n\r\n const condicoes = store.pagamento.condicoes\r\n const pag = store.pagamento.pagamento\r\n const opcoes = !!pag.Formas ? pag?.Formas[0]?.Condicoes : []\r\n const parcelas =\r\n opcoes.filter((e) => e.Descricao == condicoes)[0]?.Parcelas || []\r\n\r\n const parcelasMock = opcoes.filter((e) => e.Descricao === selectedCard)[0]\r\n ?.Parcelas\r\n\r\n let condicao = opcoes.filter((opt) => opt.Descricao === selectedCard)[0]\r\n\r\n // console.log({ parcelas, parcelasMock, selectedCard })\r\n\r\n //get first credit card\r\n useEffect(() => {\r\n if (store.pagamento.pick?.id === 'cartao') {\r\n setSelectedCard(opcoes[0].Descricao)\r\n dispatch(setCondicoes(opcoes[0]))\r\n // dispatch(setCondicaoIndex(0))\r\n }\r\n }, [store.pagamento.pick])\r\n\r\n useEffect(() => {\r\n dispatch(setCondicoes(condicao))\r\n }, [selectedCard])\r\n\r\n return (\r\n <>\r\n \r\n \r\n {\r\n setCheck({ id: 'cartao' })\r\n dispatch(setCondicaoIndex(0))\r\n }}\r\n />\r\n \r\n \r\n\r\n \r\n\r\n
    \r\n

    Cartão de Crédito

    \r\n {check?.id === 'cartao' && (\r\n {\r\n setSelectedCard(value)\r\n // dispatch(setCondicoes(value))\r\n }}\r\n options={\r\n opcoes.map((e, i) => ({\r\n label: e.Descricao,\r\n value: e.Descricao\r\n })) || [{ label: 'Bandeira...', value: '' /* hidden: true */ }]\r\n }\r\n />\r\n )}\r\n\r\n {check?.id === 'cartao' && (\r\n dispatch(setCondicaoIndex(Number(res)))}\r\n options={\r\n parcelasMock?.map((e, i) => ({\r\n label: e.DescricaoPagamento,\r\n value: i\r\n })) || [{ label: 'Parcelas...', value: '' /* hidden: true */ }]\r\n }\r\n />\r\n )}\r\n
    \r\n
    \r\n \r\n )\r\n}\r\n\r\nexport default CartaoCotacao\r\n","import styled, { css } from 'styled-components'\r\n\r\nexport const ProfileTitle = styled.h2`\r\n font-size: 22px;\r\n margin-bottom: 20px;\r\n color: #555;\r\n`\r\n\r\nexport const Wrapper = styled.div`\r\n display: flex;\r\n align-items: flex-start;\r\n margin-left: 4px;\r\n margin-top: 8px;\r\n\r\n img {\r\n width: 40px;\r\n }\r\n\r\n .formas {\r\n margin-left: 16px;\r\n width: 100%;\r\n padding-top: 6px;\r\n\r\n select {\r\n padding: 8px;\r\n padding-right: 32px;\r\n margin-bottom: 4px;\r\n background-color: #fbfbfb;\r\n border: 1px solid #ced4da;\r\n color: #2e2e2e;\r\n }\r\n }\r\n\r\n h3 {\r\n font-size: 14px;\r\n font-weight: 600;\r\n margin-bottom: 8px;\r\n }\r\n`\r\n\r\nexport const CardWrapper = styled.div`\r\n @media (min-width: 1170px) {\r\n .col-6 {\r\n width: 50%;\r\n }\r\n }\r\n`\r\n\r\nexport const CardBox = styled.div`\r\n padding: 8px 16px;\r\n height: 100px;\r\n display: flex;\r\n align-items: center;\r\n justify-content: flex-start;\r\n position: relative;\r\n\r\n background: #ffffff;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 4px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 8px;\r\n\r\n .iconCredit {\r\n /* background-color: blue; */\r\n display: flex;\r\n align-items: center;\r\n padding-left: 2px;\r\n\r\n @media (max-width: 480px) {\r\n width: 32px;\r\n }\r\n }\r\n`\r\n\r\nexport const MainCard = styled.div`\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n\r\n label {\r\n position: absolute;\r\n display: flex;\r\n align-items: center;\r\n margin-top: 3px;\r\n }\r\n`\r\n\r\nexport const CardInfo = styled.div`\r\n justify-self: left;\r\n align-self: center;\r\n font-size: 14px;\r\n margin-left: 16px;\r\n margin-right: 8px;\r\n width: 240px;\r\n flex: 1;\r\n\r\n strong {\r\n font-weight: 600;\r\n }\r\n\r\n select.parcelas {\r\n padding: 8px 30px 8px 16px;\r\n margin: 4px 8px -12px 0;\r\n max-width: 280px;\r\n\r\n @media (max-width: 545px) {\r\n max-width: calc(100% - 20px);\r\n }\r\n }\r\n`\r\n\r\nexport const CardIcon = styled.a`\r\n transition: all 400ms;\r\n right: 22px;\r\n /* flex: 1; */\r\n text-align: right;\r\n position: relative;\r\n\r\n & img {\r\n width: 18px;\r\n height: 21px;\r\n cursor: pointer;\r\n\r\n &:hover {\r\n filter: invert(22%) sepia(78%) saturate(2710%) hue-rotate(341deg)\r\n brightness(88%) contrast(96%);\r\n }\r\n\r\n @media (max-width: 480px) {\r\n width: 16px;\r\n }\r\n }\r\n`\r\n","import * as S from './styles'\r\n\r\nimport { useEffect } from 'react'\r\nimport { useDispatch, useSelector } from 'react-redux'\r\nimport CreditCardImage from '../../../PaymentCards/CreditCardImage'\r\nimport {\r\n setCondicaoIndex,\r\n setCondicoes\r\n} from '../../../../store/ducks/pagamento'\r\n\r\nconst PixCotacao = ({ type, check, setCheck, faturado }) => {\r\n const dispatch = useDispatch()\r\n const store = useSelector((store) => store)\r\n\r\n let pix = store.pagamento.pagamento?.Formas?.find(\r\n (forma) => forma?.Descricao === 'PIX'\r\n )\r\n\r\n const condicoesPix = pix?.Condicoes[0]\r\n\r\n useEffect(() => {\r\n if (store.pagamento.pick?.id === 'pix') {\r\n dispatch(setCondicoes(condicoesPix))\r\n }\r\n }, [store.pagamento.pick])\r\n\r\n return (\r\n <>\r\n \r\n \r\n {\r\n setCheck({ id: 'pix' })\r\n dispatch(setCondicaoIndex(0))\r\n }}\r\n />\r\n \r\n \r\n\r\n \r\n\r\n \r\n

    \r\n PIX\r\n

    \r\n {check?.id === 'pix' &&\r\n condicoesPix?.Parcelas[0].PercentualDesconto > 0 ? (\r\n

    \r\n com desconto de {condicoesPix?.Parcelas[0].PercentualDesconto}%\r\n

    \r\n ) : null}\r\n
    \r\n
    \r\n \r\n )\r\n}\r\n\r\nexport default PixCotacao\r\n","import styled, { css } from 'styled-components'\r\n\r\nexport const CardBox = styled.div`\r\n background: #ffffff;\r\n padding: 16px;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 4px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 20px;\r\n\r\n .address {\r\n display: flex;\r\n justify-content: space-between;\r\n align-items: center;\r\n\r\n @media (max-width: 500px) {\r\n flex-direction: column;\r\n align-items: flex-start;\r\n\r\n button {\r\n margin-top: 10px;\r\n }\r\n }\r\n }\r\n\r\n .title {\r\n font-size: 16px;\r\n display: block;\r\n font-weight: 500;\r\n margin-bottom: 8px;\r\n }\r\n\r\n .endereco-card-title span {\r\n font-weight: normal;\r\n }\r\n\r\n .endereco-card-description {\r\n font-weight: 400;\r\n font-size: 14px;\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n .perfil-box {\r\n padding: 30px 20px 10px 20px;\r\n }\r\n }\r\n\r\n @media (min-width: 1170px) and (max-width: 1360px) {\r\n .endereco-card-title {\r\n font-size: 14px;\r\n }\r\n\r\n .endereco-card-description {\r\n font-size: 14px;\r\n }\r\n }\r\n`\r\n","import { useDispatch, useSelector } from 'react-redux'\r\nimport { setPick } from '../../../store/ducks/pagamento'\r\n\r\nimport BoletoCotacao from './Boleto'\r\nimport CartaoCotacao from './Cartao'\r\nimport PixCotacao from './Pix'\r\n\r\nimport * as S from './styles'\r\n\r\nconst FormaPagamento = () => {\r\n const dispatch = useDispatch()\r\n const store = useSelector((store) => store)\r\n\r\n const { pick } = store.pagamento\r\n const formas = store.pagamento.pagamento.Formas\r\n\r\n const pixEnabled = formas?.find(\r\n (item) => item?.Descricao.toLowerCase() === 'pix'\r\n )\r\n\r\n return (\r\n \r\n
    Forma de Pagamento
    \r\n\r\n dispatch}\r\n // condicoes={formas[0]}\r\n check={pick}\r\n setCheck={(res) => dispatch(setPick(res))}\r\n />\r\n\r\n dispatch(setPick(res))} />\r\n\r\n {pixEnabled && (\r\n {\r\n dispatch(setPick(res))\r\n // dispatch(setCondicaoIndex(0))\r\n }}\r\n />\r\n )}\r\n
    \r\n )\r\n}\r\n\r\nexport default FormaPagamento\r\n","import styled, { css, keyframes } from 'styled-components'\r\n\r\nconst showModal = keyframes`\r\n from {\r\n opacity: 0;\r\n } to {\r\n opacity: 1;\r\n }\r\n`\r\n\r\nexport const Background = styled.div`\r\n width: 100%;\r\n height: 100%;\r\n background: rgba(0, 0, 0, 0.7);\r\n transition: background 0.2s;\r\n position: fixed;\r\n display: flex;\r\n justify-content: center;\r\n align-items: center;\r\n z-index: 300;\r\n animation: ${showModal} 200ms;\r\n`\r\n\r\nexport const ModalWrapper = styled.div`\r\n ${({ current }) => css`\r\n width: 100%;\r\n padding: 32px 32px 8px 32px;\r\n box-shadow: 0 5px 16px rgba(0, 0, 0, 0.2);\r\n background: #fff;\r\n color: #000;\r\n position: relative;\r\n text-align: left;\r\n z-index: 10;\r\n overflow: auto;\r\n border-radius: 10px;\r\n max-height: 95%;\r\n\r\n @media (max-width: 560px) {\r\n max-width: 90%;\r\n margin: auto;\r\n padding: 16px 8px;\r\n }\r\n\r\n @media (max-height: 630px) {\r\n max-height: 95%;\r\n }\r\n\r\n ${current === 0 &&\r\n css`\r\n max-width: 500px;\r\n `}\r\n\r\n ${current === 1 &&\r\n css`\r\n max-width: 700px;\r\n `}\r\n\r\n ${current === 2 &&\r\n css`\r\n max-width: 700px;\r\n `}\r\n\r\n ${current === 3 &&\r\n css`\r\n max-width: 500px;\r\n `}\r\n `}\r\n`\r\n\r\nexport const ContentWrapper = styled.div`\r\n position: relative;\r\n\r\n h3 {\r\n margin-bottom: 16px;\r\n font-weight: 500;\r\n font-size: 24px;\r\n }\r\n\r\n .content {\r\n overflow-y: auto;\r\n height: calc(110px + (600 — 110) * ((70vh — 210px) / (1080 — 110)));\r\n }\r\n\r\n p.title {\r\n margin-bottom: 8px;\r\n font-weight: 600;\r\n }\r\n\r\n @media (max-width: 560px) {\r\n max-width: 90%;\r\n margin: auto;\r\n }\r\n\r\n @media (max-height: 630px) {\r\n max-height: 95%;\r\n\r\n .content {\r\n overflow-y: auto;\r\n height: 40vh;\r\n }\r\n }\r\n`\r\n\r\nexport const CardWrapper = styled.div`\r\n ${({ theme }) => css`\r\n width: 100%;\r\n\r\n .col-6 {\r\n width: 100%;\r\n }\r\n `}\r\n`\r\n\r\nexport const ProfileBoxFooter = styled.div`\r\n display: flex;\r\n padding: 0;\r\n align-items: center;\r\n margin-top: 8px;\r\n gap: 8px;\r\n\r\n button,\r\n button.button-outline {\r\n max-width: 100%;\r\n margin-right: 0;\r\n }\r\n\r\n @media (max-width: 600px) {\r\n flex-direction: column;\r\n }\r\n`\r\n\r\nexport const Button = styled.button`\r\n ${({ theme }) => css`\r\n max-width: 170px;\r\n margin-right: 12px;\r\n\r\n border-radius: 5px;\r\n border: 2px solid transparent;\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 500;\r\n font-size: 16px;\r\n padding: 12px 30px;\r\n margin-bottom: 10px;\r\n width: 100%;\r\n text-align: center;\r\n transition: ${theme.transition.default};\r\n cursor: pointer;\r\n background: ${theme.colors.primary};\r\n color: ${theme.colors.white};\r\n\r\n &:hover {\r\n background: #a71e26;\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: $MEDIA-IPAD) {\r\n font-size: 14px;\r\n }\r\n\r\n &.button-outline {\r\n max-width: 146px;\r\n background: transparent;\r\n border: 2px solid ${theme.colors.primary};\r\n color: ${theme.colors.primary};\r\n cursor: pointer;\r\n\r\n &:hover {\r\n border-color: #4a4a4a;\r\n color: #4a4a4a;\r\n background: #fff;\r\n }\r\n\r\n &:disabled {\r\n color: #7b7b7b;\r\n border-color: #7b7b7b;\r\n cursor: initial;\r\n }\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n & + .button {\r\n margin-left: 0;\r\n margin-top: 8px;\r\n }\r\n }\r\n `}\r\n`\r\n\r\nexport const HeaderModalClose = styled.button`\r\n background: none;\r\n border: 0;\r\n position: absolute;\r\n top: 30px;\r\n right: 40px;\r\n transition: all 400ms;\r\n cursor: pointer;\r\n\r\n img {\r\n width: 18px;\r\n }\r\n\r\n &:hover {\r\n opacity: 0.6;\r\n }\r\n`\r\n","import styled, { css } from 'styled-components'\r\n// import IconEdit from '../../../assets/icons/icon-edit.svg'\r\n// import IconRemove from '../../../assets/icons/icon-remove.svg'\r\n\r\nexport const ProfileTitle = styled.h2`\r\n font-size: 22px;\r\n margin-bottom: 20px;\r\n color: #555;\r\n`\r\n\r\nexport const Wrapper = styled.div``\r\n\r\nexport const CardWrapper = styled.div`\r\n @media (min-width: 1170px) {\r\n .col-6 {\r\n width: 50%;\r\n }\r\n }\r\n`\r\n\r\nexport const CardBox = styled.div`\r\n background: #ffffff;\r\n padding: 8px 16px;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 4px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 16px;\r\n position: relative;\r\n\r\n .padrao {\r\n position: absolute;\r\n top: 10px;\r\n left: 16px;\r\n }\r\n\r\n .address-info {\r\n margin-left: 34px;\r\n }\r\n\r\n .endereco-card-title {\r\n font-size: 14px;\r\n font-weight: 400;\r\n display: block;\r\n margin-bottom: 2px;\r\n color: #707070;\r\n max-width: 80%;\r\n }\r\n\r\n .apelido {\r\n font-weight: 600;\r\n color: #2e2e2e;\r\n }\r\n .endereco-card-title span {\r\n font-weight: normal;\r\n }\r\n\r\n .endereco-card-description {\r\n margin-bottom: 8px;\r\n color: #707070;\r\n font-size: 14px;\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n .perfil-box {\r\n padding: 30px 20px 10px 20px;\r\n }\r\n }\r\n\r\n @media (min-width: 1170px) and (max-width: 1360px) {\r\n .endereco-card-title {\r\n font-size: 14px;\r\n }\r\n\r\n .endereco-card-description {\r\n font-size: 14px;\r\n }\r\n }\r\n`\r\n\r\nexport const CardConfig = styled.div`\r\n position: absolute;\r\n right: 16px;\r\n top: 16px;\r\n display: flex;\r\n`\r\n\r\nexport const CardLink = styled.a`\r\n transition: all 400ms;\r\n cursor: pointer;\r\n\r\n &:first-child {\r\n margin-right: 8px;\r\n }\r\n\r\n & img {\r\n width: 18px;\r\n height: 18px;\r\n\r\n &:hover {\r\n filter: invert(22%) sepia(78%) saturate(2710%) hue-rotate(341deg)\r\n brightness(88%) contrast(96%);\r\n }\r\n }\r\n`\r\n\r\nexport const CardAddressType = styled.h3`\r\n font-size: 16px;\r\n display: block;\r\n margin-bottom: 8px;\r\n`\r\nexport const Address = styled.h3``\r\n\r\nexport const ProfileBox = styled.div`\r\n background: #ffffff;\r\n padding: 30px;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 10px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 20px;\r\n`\r\n\r\nexport const ProfileBoxFooter = styled.div`\r\n margin: 10px 0 20px 0;\r\n\r\n button {\r\n border: none;\r\n cursor: pointer;\r\n font-family: Montserrat;\r\n font-weight: 500;\r\n font-size: 14px;\r\n background-color: #fff;\r\n text-decoration: underline;\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n display: flex;\r\n flex-direction: column;\r\n }\r\n`\r\n\r\nexport const ButtonAddNewAddress = styled.button`\r\n ${({ theme }) => css`\r\n border-radius: 5px;\r\n border: 2px solid transparent;\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 500;\r\n font-size: 16px;\r\n padding: 15px 30px;\r\n text-align: center;\r\n transition: ${theme.transition.default};\r\n cursor: pointer;\r\n background: ${theme.colors.primary};\r\n color: ${theme.colors.white};\r\n\r\n &:hover {\r\n background: #a71e26;\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: $MEDIA-IPAD) {\r\n font-size: 14px;\r\n }\r\n `}\r\n`\r\n","import { useState } from 'react'\r\nimport EmptyAdress from '../../../MyAddress/EmptyAdress'\r\n\r\nimport IconEdit from '../../../../assets/icons/icon-edit.svg'\r\nimport IconRemove from '../../../../assets/icons/icon-remove.svg'\r\nimport * as S from './styles'\r\nimport defaultOptions from '../../../../api/defaultoption'\r\nimport { useSelector, useDispatch } from 'react-redux'\r\nimport { useToast } from '../../../../hooks/toast'\r\nimport Loader from '../../../Loader'\r\nimport { convertDecimalCurrency } from '../../../../utils/utils'\r\n\r\nconst FreteCards = ({\r\n setCurrent,\r\n deleteModal,\r\n // userAddress,\r\n setCardId,\r\n current,\r\n loading,\r\n setLoading,\r\n setSelectedFrete,\r\n setCache\r\n}) => {\r\n const { addToast } = useToast()\r\n const store = useSelector((store) => store)\r\n const dispatch = useDispatch()\r\n\r\n const [checked, setChecked] = useState('')\r\n\r\n const userAddress = store.envio.frete?.Gimba?.OpcoesFrete?.map((e) => ({\r\n name: e?.RazaoSocial || '',\r\n id: e?.Id?.trim(),\r\n value: e?.ValorFrete,\r\n time: e?.DiasParaEntrega,\r\n ValorFreteAgendado: e?.ValorFreteAgendado,\r\n padrao: true\r\n }))||[]\r\n const capitalize = (str) => {\r\n return str\r\n .toLowerCase()\r\n .split(' ')\r\n .map((word) => word.charAt(0).toUpperCase() + word.substring(1))\r\n .join(' ')\r\n }\r\n\r\n const handleSubmit = async (id) => {\r\n const item = await userAddress.find((element) => element.id === id)\r\n // setLoading(true)\r\n\r\n const formData = {\r\n ...item,\r\n padrao: true\r\n }\r\n setSelectedFrete(formData)\r\n }\r\n\r\n return (\r\n <>\r\n {loading ? : null}\r\n\r\n \r\n {!!userAddress.length ? (\r\n userAddress.map(\r\n ({ padrao, name, id, value, time, ValorFreteAgendado }, i) => {\r\n return (\r\n <>\r\n \r\n \r\n
    \r\n \r\n {name}\r\n \r\n\r\n

    \r\n Frete: {convertDecimalCurrency(value)} | Entrega:{' '}\r\n {time} dias úteis\r\n

    \r\n
    \r\n\r\n
    \r\n {\r\n if (e.target.name == id) {\r\n setChecked(e.target.name)\r\n setCache({\r\n name,\r\n id,\r\n value,\r\n time,\r\n ValorFreteAgendado: ValorFreteAgendado\r\n })\r\n }\r\n // handleSubmit(id)\r\n }}\r\n />\r\n\r\n \r\n
    \r\n
    \r\n
    \r\n \r\n )\r\n }\r\n )\r\n ) : (\r\n \r\n )}\r\n
    \r\n \r\n )\r\n}\r\n\r\nexport default FreteCards\r\n","import { useEffect, useRef, useState } from 'react'\r\nimport * as S from './styles'\r\nimport IconClose from '../../../assets/icons/icon-close.svg'\r\nimport defaultOptions from '../../../api/defaultoption'\r\nimport clientes from '../../../api/clientes'\r\n\r\nimport { useSelector, useDispatch } from 'react-redux'\r\nimport { setEndereco, setPadrao } from '../../../store/ducks/endereco'\r\nimport FreteCards from './FreteCards'\r\nimport { setFretePick } from '../../../store/ducks/envio'\r\n\r\nconst OpcoesFreteModal = ({\r\n showModal,\r\n setShowModal,\r\n setSelectedFrete,\r\n selectedFrete\r\n}) => {\r\n const modalRef = useRef()\r\n const [loading, setLoading] = useState(false)\r\n const [current, setCurrent] = useState(0)\r\n const [cardId, setCardId] = useState('')\r\n const [cache, setCache] = useState({})\r\n\r\n const dispatch = useDispatch()\r\n const store = useSelector((store) => store)\r\n\r\n const closeModal = (e) => {\r\n if (modalRef.current === e.target) {\r\n setShowModal(false)\r\n }\r\n }\r\n\r\n const openModal = (id) => {\r\n setShowModal((prev) => !prev)\r\n setCardId(id)\r\n }\r\n\r\n return (\r\n <>\r\n {showModal ? (\r\n \r\n \r\n \r\n

    Opções de envio

    \r\n\r\n \r\n\r\n \r\n {\r\n dispatch(setFretePick('Gimba', cache))\r\n setShowModal((prev) => !prev)\r\n }}\r\n >\r\n Confirmar\r\n \r\n {\r\n setShowModal((prev) => !prev)\r\n }}\r\n >\r\n Cancelar\r\n \r\n \r\n
    \r\n\r\n {\r\n setShowModal((prev) => !prev)\r\n setCurrent(0)\r\n }}\r\n >\r\n {/* */}\r\n \"\"\r\n \r\n
    \r\n
    \r\n ) : null}\r\n \r\n )\r\n}\r\n\r\nexport default OpcoesFreteModal\r\n","import styled, { css, keyframes } from 'styled-components'\r\n\r\nconst showModal = keyframes`\r\n from {\r\n opacity: 0;\r\n } to {\r\n opacity: 1;\r\n }\r\n`\r\n\r\nexport const Background = styled.div`\r\n width: 100%;\r\n height: 100%;\r\n background: rgba(0, 0, 0, 0.7);\r\n transition: background 0.2s;\r\n position: fixed;\r\n display: flex;\r\n justify-content: center;\r\n align-items: center;\r\n z-index: 1000;\r\n animation: ${showModal} 200ms;\r\n`\r\n\r\nexport const ModalWrapper = styled.div`\r\n ${({ theme }) => css`\r\n max-width: 400px;\r\n padding: 32px;\r\n position: relative;\r\n\r\n display: flex;\r\n flex-direction: column;\r\n border-radius: 5px;\r\n\r\n background: #fff;\r\n color: #000;\r\n box-shadow: 0 5px 16px rgba(0, 0, 0, 0.2);\r\n text-align: center;\r\n z-index: 100;\r\n\r\n @media (max-width: 560px) {\r\n max-width: 90%;\r\n margin: auto;\r\n }\r\n\r\n p {\r\n font-size: 16px;\r\n line-height: 20px;\r\n margin-bottom: 16px;\r\n\r\n &:last-child {\r\n margin-bottom: 0;\r\n }\r\n }\r\n\r\n strong {\r\n font-weight: 600;\r\n }\r\n\r\n .modal-title {\r\n font-size: 24px;\r\n font-weight: 600;\r\n margin-bottom: 16px;\r\n color: ${theme.colors.primary};\r\n }\r\n\r\n .numero {\r\n font-size: 24px;\r\n line-height: 30px;\r\n text-decoration: underline;\r\n }\r\n\r\n .cotacao-st {\r\n font-size: 14px;\r\n color: ${theme.colors.primary};\r\n }\r\n\r\n .modal-description {\r\n margin-bottom: 16px;\r\n }\r\n\r\n .button-container {\r\n display: flex;\r\n }\r\n `}\r\n`\r\n\r\nexport const TitleHead = styled.div`\r\n ${({ theme }) => css`\r\n display: flex;\r\n align-items: center;\r\n justify-content: center;\r\n\r\n h3 {\r\n font-size: 24px;\r\n font-weight: 500;\r\n margin-left: 8px;\r\n\r\n color: #27ae60;\r\n\r\n @media (max-width: 500px) {\r\n font-size: 18px;\r\n }\r\n }\r\n\r\n img {\r\n width: 50px;\r\n }\r\n `}\r\n`\r\n\r\nexport const HeaderModalClose = styled.button`\r\n position: absolute;\r\n right: 32px;\r\n top: 36px;\r\n\r\n justify-self: flex-end;\r\n background: none;\r\n border: 0;\r\n transition: all 400ms;\r\n cursor: pointer;\r\n opacity: 0.8;\r\n\r\n img {\r\n width: 20px;\r\n }\r\n\r\n &:hover {\r\n opacity: 0.6;\r\n }\r\n`\r\n\r\nexport const Button = styled.button`\r\n ${({ theme }) => css`\r\n max-width: 200px;\r\n width: 100%;\r\n margin-right: 12px;\r\n padding: 8px 40px;\r\n\r\n border-radius: 5px;\r\n border: 2px solid transparent;\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 500;\r\n font-size: 16px;\r\n width: 100%;\r\n text-align: center;\r\n transition: ${theme.transition.default};\r\n cursor: pointer;\r\n background: ${theme.colors.primary};\r\n color: ${theme.colors.white};\r\n\r\n &:hover {\r\n background: #a71e26;\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: $MEDIA-IPAD) {\r\n font-size: 14px;\r\n }\r\n\r\n &.button-outline {\r\n background: transparent;\r\n border: 2px solid ${theme.colors.primary};\r\n color: ${theme.colors.primary};\r\n\r\n &:hover {\r\n border-color: #4a4a4a;\r\n color: #4a4a4a;\r\n }\r\n\r\n &:disabled {\r\n color: #7b7b7b;\r\n border-color: #7b7b7b;\r\n cursor: initial;\r\n }\r\n }\r\n\r\n @media (max-width: 1170px) {\r\n & + .button {\r\n margin-left: 0;\r\n margin-top: 8px;\r\n }\r\n }\r\n `}\r\n`\r\n","/* eslint-disable react-hooks/exhaustive-deps */\r\nimport { useRef, useEffect, useState } from 'react'\r\nimport { useSelector, useDispatch } from 'react-redux'\r\n\r\nimport * as S from './styles'\r\nimport IconClose from '../../assets/icons/icon-close.svg'\r\nimport { token } from '../../api/auth/auth'\r\nimport { useHistory } from 'react-router-dom'\r\nimport { setTipo } from '../../store/ducks/finalizado'\r\nimport { resetFretePick, resetFrete, resetEnvio } from '../../store/ducks/envio'\r\nimport { resetPagamento } from '../../store/ducks/pagamento'\r\nimport { resetEndereco } from '../../store/ducks/endereco'\r\n\r\nconst CotacaoFinalizadaModal = ({\r\n showModal,\r\n setShowModal,\r\n setLoading,\r\n negociacao\r\n}) => {\r\n const store = useSelector((store) => store)\r\n const dispatch = useDispatch()\r\n const modalRef = useRef()\r\n const router = useHistory()\r\n const [acrescimo, setAcrescimo] = useState(0)\r\n\r\n const closeModal = (e) => {\r\n if (modalRef.current === e.target) {\r\n setShowModal(false)\r\n }\r\n }\r\n\r\n // const acrescimo =\r\n // store.finalizado.pedido?.DetahleSubstituicaoTributaria?.ValorSt || 0\r\n const numeroCotacao = store.finalizado?.pedido?.Id || '-'\r\n\r\n const msg = !!negociacao ? 'negociação' : 'cotação'\r\n\r\n useEffect(() => {\r\n //carrinhoGimbaBool carrinhoGimba.length === carrinho\r\n let carrinhoGimba = store.envio?.resumo?.Carrinho?.filter(\r\n (e) => e.SellerId === null\r\n )?.length\r\n let carrinho = store.envio?.resumo?.Carrinho?.length\r\n let carrinhoGimbaBool = carrinho === carrinhoGimba\r\n\r\n setAcrescimo(\r\n store.finalizado.pedido?.DetalheSubstituicaoTributaria?.ValorSt\r\n )\r\n if (showModal) {\r\n dispatch(resetFretePick())\r\n if (carrinhoGimbaBool) {\r\n setTimeout(() => {\r\n return (window.location.href = `${process.env.REACT_APP_URL_MAIN}/marketplacecliente/FinalizarCotacaoNegociacao`)\r\n }, 2000)\r\n } else {\r\n dispatch(setTipo(negociacao ? 'n' : 'c'))\r\n dispatch(resetEnvio())\r\n dispatch(resetPagamento())\r\n dispatch(resetEndereco())\r\n\r\n setTimeout(() => {\r\n return router.push(`/?token=${token()}`)\r\n }, 2000)\r\n }\r\n }\r\n }, [showModal])\r\n\r\n return (\r\n <>\r\n {showModal ? (\r\n \r\n \r\n \r\n

    \r\n {!!negociacao ? 'Negociação ' : 'Cotação '}Finalizada\r\n

    \r\n\r\n setShowModal((prev) => !prev)}\r\n >\r\n \"\"\r\n \r\n
    \r\n\r\n

    \r\n Sua {msg} foi gravada com sucesso\r\n

    \r\n\r\n

    Para visualizá-la, navegue até \"{msg}” no menu superior.

    \r\n\r\n

    \r\n Número da {msg}
    {' '}\r\n {numeroCotacao}\r\n

    \r\n\r\n {acrescimo > 0 && (\r\n

    \r\n Sua {`${msg}`} teve um acréscimo no valor.
    \r\n Valor do ICSM - ST calculado: R$ {acrescimo}\r\n

    \r\n )}\r\n
    \r\n
    \r\n ) : null}\r\n \r\n )\r\n}\r\n\r\nexport default CotacaoFinalizadaModal\r\n","/* eslint-disable react-hooks/exhaustive-deps */\r\nimport { useEffect, useState } from 'react'\r\nimport { useSelector } from 'react-redux'\r\n\r\nimport Header from '../../components/Header'\r\nimport MediaMatch from '../../components/MediaMatch'\r\n\r\nimport MyAddressModal from '../../components/MyAddressModal'\r\nimport AddressCardConfirmacao from '../../components/MyAddress/AddressCardConfirmacao'\r\nimport { useToast } from '../../hooks/toast'\r\n\r\nimport Tooltip from '../../components/Tooltip'\r\nimport { FormGroup } from '../../components/Form/styles'\r\nimport { useDispatch } from 'react-redux'\r\nimport { setPagamento, setST, setPick } from '../../store/ducks/pagamento'\r\nimport {\r\n ObservacaoNF,\r\n SectionTitle\r\n} from '../../components/PaymentCards/styles'\r\nimport { isPF } from '../../api/auth/auth'\r\nimport { Breadcrumb, BreadcrumbItem } from '../../styles/breadcrumb'\r\nimport * as S from '../../styles/checkout'\r\nimport CotacaoItens from '../../components/CotacaoCheckout'\r\nimport ResumoCotacao from '../../components/ResumoCotacao'\r\nimport GimbaCard from '../../components/PaymentCards/GimbaCard'\r\nimport OpcoesFrete from '../../components/CotacaoCheckout/OpcoesFrete'\r\nimport FormaPagamento from '../../components/CotacaoCheckout/FormaPagamento'\r\nimport OpcoesFreteModal from '../../components/CotacaoCheckout/OpcoesFreteModal/indes'\r\nimport { useHistory } from 'react-router-dom'\r\nimport { token } from '../../api/auth/auth'\r\nimport Loader from '../../components/Loader'\r\nimport { getLocalStorageLog } from '../../utils/traceLogAcessos'\r\nimport { useLocation } from 'react-router-dom'\r\n\r\nimport {\r\n getFreteGimba,\r\n getResumoGimba,\r\n getFormasCotacao,\r\n postCotacao\r\n} from './fetch'\r\nimport {\r\n setResumo,\r\n setFrete,\r\n resetFretePick,\r\n setFretePick\r\n} from '../../store/ducks/envio'\r\nimport { setPedido } from '../../store/ducks/finalizado'\r\nimport CotacaoFinalizadaModal from '../../components/CotacaoFinalizadaModal'\r\nimport { setPadrao } from '../../store/ducks/endereco'\r\nimport { allowNewAddress } from '../../utils/validatePJ'\r\nimport pedidos from '../../api/pedidos'\r\nimport { fetchUser } from '../Auth/fetch'\r\nimport { setUserInfo } from '../../store/ducks/user'\r\nimport PerguntaST from '../../components/PerguntasST'\r\nimport {\r\n checkGovernoPj,\r\n checkEstadoST,\r\n checkRevendaPj\r\n} from '../../utils/validatePJ'\r\n\r\nconst Cotacao = () => {\r\n const { addToast } = useToast()\r\n const router = useHistory()\r\n const [showModalAddress, setShowModalAddress] = useState(false)\r\n const [showModalFrete, setShowModalFrete] = useState(false)\r\n const [showModalCotacao, setShowModalCotacao] = useState(false)\r\n const [userData, setUserData] = useState('')\r\n\r\n const [load, setLoad] = useState(false)\r\n const [selectedAddress, setSelectedAddress] = useState('')\r\n const [selectedFrete, setSelectedFrete] = useState('')\r\n const store = useSelector((store) => store)\r\n const dispatch = useDispatch()\r\n const openModalAddress = () => {\r\n setShowModalAddress((prev) => !prev)\r\n }\r\n const openModalFrete = () => {\r\n setShowModalFrete((prev) => !prev)\r\n }\r\n\r\n const openModalCotacao = () => {\r\n setShowModalCotacao((prev) => !prev)\r\n }\r\n\r\n const [waitGroup, setWaitGroup] = useState(0)\r\n\r\n //check produtos Gimba\r\n const carrinhoGimbaBool =\r\n store.envio.resumo?.Carrinho?.filter((e) => e.SellerId === null).length > 0\r\n\r\n //Carregar endereço de Faturamento selecionado por Default\r\n const enderecoFaturamento = store.endereco.enderecos.filter(\r\n (item) => item.tipoEndereco === 'C'\r\n )\r\n\r\n const location = useLocation()\r\n\r\n useEffect(() => {\r\n getLocalStorageLog(location.pathname)\r\n }, [])\r\n\r\n useEffect(() => {\r\n if (!isPF()) {\r\n dispatch(setPadrao(enderecoFaturamento[0]))\r\n }\r\n //autenticador com base em endereço\r\n if (!!!store.endereco.padrao.id)\r\n router.push(`/?token=${token()}&tipo=cotacao`)\r\n //fetch user\r\n fetchUser(setUserData)\r\n }, [])\r\n\r\n //carregar resumo e carrinho -> depende de endereço na rota /\r\n useEffect(() => {\r\n if (store.endereco.padrao?.id !== undefined) {\r\n getResumoGimba(\r\n store.endereco.padrao?.id,\r\n (res) => dispatch(setResumo(res)),\r\n setLoad,\r\n () => setWaitGroup(1),\r\n () => router.push('/busy?tipo=cotacao')\r\n )\r\n }\r\n dispatch(resetFretePick())\r\n }, [store.endereco.padrao])\r\n\r\n //wait groups -> controle de sincronicidade de calls\r\n useEffect(() => {\r\n //carregar frete, depende de resumo e carrinho\r\n if (waitGroup === 1) {\r\n getFreteGimba(\r\n store.endereco.padrao.id,\r\n store.envio.resumo,\r\n (res) => dispatch(setFrete(res)),\r\n setLoad,\r\n () => setWaitGroup(2),\r\n () => router.push('/busy?tipo=cotacao')\r\n )\r\n }\r\n //autopick do primeiro frete, depende do frete\r\n if (waitGroup === 2) {\r\n let e = store.envio.frete?.Gimba?.OpcoesFrete[0] || {}\r\n dispatch(\r\n setFretePick('Gimba', {\r\n id: e.Id,\r\n name: e.RazaoSocial,\r\n time: e.DiasParaEntrega,\r\n value: e.ValorFrete,\r\n ValorFreteAgendado: e.ValorFreteAgendado\r\n })\r\n )\r\n setWaitGroup(3)\r\n }\r\n //cartões e condições -> getFormas\r\n if (waitGroup === 3) {\r\n getFormasCotacao(\r\n store.endereco.padrao.id,\r\n store.envio.fretePick,\r\n (res) => dispatch(setPagamento(res)),\r\n setLoad,\r\n () => setWaitGroup(4),\r\n () => router.push('/busy?tipo=cotacao'),\r\n store\r\n )\r\n }\r\n }, [waitGroup])\r\n\r\n useEffect(() => {\r\n if (store.user.info.id === undefined && userData !== '') {\r\n dispatch(setUserInfo(userData))\r\n }\r\n // eslint-disable-next-line react-hooks/exhaustive-deps\r\n }, [store.user.info, userData])\r\n\r\n //refresh pick store\r\n useEffect(() => {\r\n if (store.pagamento.pick.id !== undefined) {\r\n dispatch(setPick({ ...store.pagamento.pick }))\r\n }\r\n }, [store.pagamento.pagamento])\r\n\r\n //post cotação\r\n const finalizarCotacao = async () => {\r\n if (\r\n !!!isPF() &&\r\n !checkGovernoPj(store.user.info) &&\r\n !!checkEstadoST(store) &&\r\n carrinhoGimbaBool &&\r\n store.pagamento.st.icms === undefined\r\n ) {\r\n addToast({\r\n type: 'error',\r\n title: 'Informe se você é contribuinte de ICMS'\r\n })\r\n } else if (\r\n !!!isPF() &&\r\n !checkGovernoPj(store.user.info) &&\r\n !!checkEstadoST(store) &&\r\n !!checkRevendaPj(store.user.info) &&\r\n carrinhoGimbaBool &&\r\n store.pagamento.st.destinoFiscal === undefined\r\n ) {\r\n addToast({\r\n type: 'error',\r\n title: 'Informe destino fiscal da mercadoria'\r\n })\r\n } else if (store.pagamento.pick?.id === undefined) {\r\n addToast({\r\n type: 'error',\r\n title: 'Selecione uma forma de pagamento'\r\n })\r\n } else {\r\n postCotacao(\r\n store,\r\n (res) => dispatch(setPedido(res)),\r\n setLoad,\r\n () => openModalCotacao()\r\n )\r\n // await pedidos.tagCotacao().catch(e=>console.log(e))\r\n }\r\n }\r\n\r\n return (\r\n <>\r\n {load && }\r\n \r\n\r\n \r\n\r\n \r\n\r\n
    \r\n \r\n \r\n \r\n Inicio\r\n Meus Carrinho\r\n Fazer Cotação\r\n \r\n Salvar Cotação\r\n\r\n \r\n
    \r\n {/* CONTEÚDO PRINCIPAL DA PÁGINA */}\r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n {/* CONTEÚDO PRINCIPAL DA PÁGINA */}\r\n\r\n {/* COLUNA - RESUMO DO PEDIDO --> */}\r\n
    \r\n
    \r\n \r\n
    \r\n\r\n
    \r\n openModalAddress()}\r\n data={store.endereco.padrao}\r\n allowOtherAddress={allowNewAddress(\r\n store.endereco.enderecos,\r\n store.user.info.inscricaoEstadual\r\n )}\r\n cotacao\r\n />\r\n
    \r\n\r\n
    \r\n openModalFrete()}>\r\n
    \r\n\r\n
    \r\n \r\n
    \r\n\r\n
    \r\n \r\n
    \r\n\r\n
    \r\n \r\n
    \r\n\r\n
    \r\n finalizarCotacao()}>\r\n Salvar Cotação\r\n \r\n
    \r\n\r\n
    \r\n \r\n Negociar Preço\r\n \r\n
    \r\n\r\n
    \r\n \r\n Voltar para o carrinho\r\n \r\n
    \r\n\r\n
    \r\n {!!isPF() && }\r\n
    \r\n
    \r\n\r\n \r\n
    \r\n \r\n
    \r\n\r\n
    \r\n finalizarCotacao()}>\r\n Salvar Cotação\r\n \r\n
    \r\n\r\n
    \r\n \r\n Negociar Preço\r\n \r\n
    \r\n\r\n
    \r\n \r\n Voltar para o carrinho\r\n \r\n
    \r\n\r\n
    \r\n {!!isPF() && }\r\n
    \r\n
    \r\n {/* <-- COLUNA - RESUMO DO PEDIDO */}\r\n
    \r\n
    \r\n
    \r\n
    \r\n \r\n )\r\n}\r\n\r\nexport default Cotacao\r\n","/* eslint-disable react-hooks/exhaustive-deps */\r\nimport { useEffect, useState } from 'react'\r\nimport { useSelector } from 'react-redux'\r\n\r\nimport Header from '../../components/Header'\r\nimport MediaMatch from '../../components/MediaMatch'\r\nimport Sellers from '../../components/Sellers/show'\r\nimport ResumoPedido from '../../components/ResumoPedido'\r\nimport Steps from '../../components/Steps'\r\nimport MyAddressModal from '../../components/MyAddressModal'\r\nimport AddressCardConfirmacao from '../../components/MyAddress/AddressCardConfirmacao'\r\nimport PaymentMethodConfirmacao from '../../components/PaymentCards/PaymentMethodConfirmacao'\r\nimport PaymentCardsModal from '../../components/PaymentCardsModal'\r\n\r\nimport Tooltip from '../../components/Tooltip'\r\nimport { FormGroup } from '../../components/Form/styles'\r\nimport { useDispatch } from 'react-redux'\r\nimport {\r\n setFormas,\r\n setPagamento,\r\n setST,\r\n setPick\r\n} from '../../store/ducks/pagamento'\r\nimport {\r\n ObservacaoNF,\r\n SectionTitle\r\n} from '../../components/PaymentCards/styles'\r\nimport { isPF } from '../../api/auth/auth'\r\n\r\nimport { Breadcrumb, BreadcrumbItem } from '../../styles/breadcrumb'\r\nimport * as S from '../../styles/checkout'\r\nimport CotacaoItens from '../../components/CotacaoCheckout'\r\nimport ResumoCotacao from '../../components/ResumoCotacao'\r\nimport GimbaCard from '../../components/PaymentCards/GimbaCard'\r\nimport OpcoesFrete from '../../components/CotacaoCheckout/OpcoesFrete'\r\nimport FormaPagamento from '../../components/CotacaoCheckout/FormaPagamento'\r\nimport OpcoesFreteModal from '../../components/CotacaoCheckout/OpcoesFreteModal/indes'\r\nimport { useHistory } from 'react-router-dom'\r\nimport { token } from '../../api/auth/auth'\r\nimport Loader from '../../components/Loader'\r\nimport { useToast } from '../../hooks/toast'\r\n\r\nimport {\r\n getFreteGimba,\r\n getResumoGimba,\r\n getFormasNegociacao,\r\n postNegociacao\r\n} from './fetch'\r\nimport {\r\n setResumo,\r\n setFrete,\r\n resetFretePick,\r\n setFretePick\r\n} from '../../store/ducks/envio'\r\nimport { setPedido } from '../../store/ducks/finalizado'\r\n\r\nimport CotacaoFinalizadaModal from '../../components/CotacaoFinalizadaModal'\r\nimport { setPadrao } from '../../store/ducks/endereco'\r\nimport {\r\n allowNewAddress,\r\n checkEstadoST,\r\n checkGovernoPj,\r\n checkRevendaPj\r\n} from '../../utils/validatePJ'\r\nimport pedidos from '../../api/pedidos'\r\nimport { fetchUser } from '../Auth/fetch'\r\nimport { setUserInfo } from '../../store/ducks/user'\r\nimport PerguntaST from '../../components/PerguntasST'\r\nimport { getLocalStorageLog } from '../../utils/traceLogAcessos'\r\nimport { useLocation } from 'react-router-dom'\r\n\r\nconst Negociacao = () => {\r\n const { addToast } = useToast()\r\n const router = useHistory()\r\n const [showModalAddress, setShowModalAddress] = useState(false)\r\n const [showModalFrete, setShowModalFrete] = useState(false)\r\n const [showModalCotacao, setShowModalCotacao] = useState(false)\r\n const [userData, setUserData] = useState('')\r\n\r\n const [load, setLoad] = useState(false)\r\n const [selectedAddress, setSelectedAddress] = useState('')\r\n const [selectedFrete, setSelectedFrete] = useState('')\r\n const store = useSelector((store) => store)\r\n const dispatch = useDispatch()\r\n const openModalAddress = () => {\r\n setShowModalAddress((prev) => !prev)\r\n }\r\n const openModalFrete = () => {\r\n setShowModalFrete((prev) => !prev)\r\n }\r\n\r\n const openModalCotacao = () => {\r\n setShowModalCotacao((prev) => !prev)\r\n }\r\n\r\n const [waitGroup, setWaitGroup] = useState(0)\r\n\r\n //check produtos Gimba\r\n const carrinhoGimbaBool =\r\n store.envio.resumo?.Carrinho?.filter((e) => e.SellerId === null).length > 0\r\n\r\n //Carregar endereço de Faturamento selecionado por Default\r\n const enderecoFaturamento = store.endereco.enderecos.filter(\r\n (item) => item.tipoEndereco === 'C'\r\n )\r\n\r\n const location = useLocation()\r\n\r\n useEffect(() => {\r\n getLocalStorageLog(location.pathname)\r\n }, [])\r\n\r\n useEffect(() => {\r\n if (!isPF()) {\r\n dispatch(setPadrao(enderecoFaturamento[0]))\r\n }\r\n //autenticador com base em endereço\r\n if (!!!store.endereco.padrao.id)\r\n router.push(`/?token=${token()}&tipo=negociacao`)\r\n //fetch user\r\n fetchUser(setUserData)\r\n }, [])\r\n\r\n //carregar resumo e carrinho -> depende de endereço na rota /\r\n useEffect(() => {\r\n if (store.endereco.padrao?.id !== undefined) {\r\n getResumoGimba(\r\n store.endereco.padrao?.id,\r\n (res) => dispatch(setResumo(res)),\r\n setLoad,\r\n () => setWaitGroup(1),\r\n () => router.push('/busy?tipo=negociacao')\r\n )\r\n }\r\n dispatch(resetFretePick())\r\n }, [store.endereco.padrao])\r\n\r\n //wait groups -> controle de sincronicidade de calls\r\n useEffect(() => {\r\n //carregar frete, depende de resumo e carrinho\r\n if (waitGroup === 1) {\r\n getFreteGimba(\r\n store.endereco.padrao.id,\r\n store.envio.resumo,\r\n (res) => dispatch(setFrete(res)),\r\n setLoad,\r\n () => setWaitGroup(2),\r\n () => router.push('/busy?tipo=negociacao')\r\n )\r\n }\r\n //autopick do primeiro frete, depende do frete\r\n if (waitGroup === 2) {\r\n let e = store.envio.frete?.Gimba?.OpcoesFrete[0] || {}\r\n dispatch(\r\n setFretePick('Gimba', {\r\n id: e.Id,\r\n name: e.RazaoSocial,\r\n time: e.DiasParaEntrega,\r\n value: e.ValorFrete,\r\n ValorFreteAgendado: e.ValorFreteAgendado\r\n })\r\n )\r\n setWaitGroup(3)\r\n }\r\n //cartões e condições -> getFormas\r\n if (waitGroup === 3) {\r\n getFormasNegociacao(\r\n store.endereco.padrao.id,\r\n store.envio.fretePick,\r\n (res) => dispatch(setPagamento(res)),\r\n setLoad,\r\n () => setWaitGroup(4),\r\n () => router.push('/busy?tipo=negociacao'),\r\n store\r\n )\r\n }\r\n }, [waitGroup])\r\n\r\n useEffect(() => {\r\n if (store.user.info.id === undefined && userData !== '') {\r\n dispatch(setUserInfo(userData))\r\n }\r\n // eslint-disable-next-line react-hooks/exhaustive-deps\r\n }, [store.user.info, userData])\r\n\r\n //refresh pick store\r\n useEffect(() => {\r\n if (store.pagamento.pick.id !== undefined) {\r\n dispatch(setPick({ ...store.pagamento.pick }))\r\n }\r\n }, [store.pagamento.pagamento])\r\n\r\n //post\r\n const finalizar = async () => {\r\n if (\r\n !!!isPF() &&\r\n !checkGovernoPj(store.user.info) &&\r\n !!checkEstadoST(store) &&\r\n carrinhoGimbaBool &&\r\n store.pagamento.st.icms === undefined\r\n ) {\r\n addToast({\r\n type: 'error',\r\n title: 'Informe se você é contribuinte de ICMS'\r\n })\r\n } else if (\r\n !!!isPF() &&\r\n !checkGovernoPj(store.user.info) &&\r\n !!checkEstadoST(store) &&\r\n !!checkRevendaPj(store.user.info) &&\r\n carrinhoGimbaBool &&\r\n store.pagamento.st.destinoFiscal === undefined\r\n ) {\r\n addToast({\r\n type: 'error',\r\n title: 'Informe destino fiscal da mercadoria'\r\n })\r\n } else if (store.pagamento.pick?.id === undefined) {\r\n addToast({\r\n type: 'error',\r\n title: 'Selecione uma forma de pagamento'\r\n })\r\n } else {\r\n postNegociacao(\r\n store,\r\n (res) => dispatch(setPedido(res)),\r\n setLoad,\r\n () => openModalCotacao(),\r\n () => router.push('/busy?tipo=negociacao')\r\n )\r\n await pedidos.tagNegociacao().catch((e) => console.log(e))\r\n }\r\n }\r\n\r\n return (\r\n <>\r\n {load && }\r\n \r\n\r\n \r\n\r\n \r\n\r\n
    \r\n \r\n \r\n \r\n Inicio\r\n Meus Carrinho\r\n Fazer Negociação\r\n \r\n Negociação\r\n\r\n \r\n
    \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n {/* CONTEÚDO PRINCIPAL DA PÁGINA */}\r\n\r\n {/* COLUNA - RESUMO DO PEDIDO --> */}\r\n
    \r\n
    \r\n \r\n
    \r\n\r\n
    \r\n openModalAddress()}\r\n data={store.endereco.padrao}\r\n allowOtherAddress={allowNewAddress(\r\n store.endereco.enderecos,\r\n store.user.info.inscricaoEstadual\r\n )}\r\n cotacao\r\n />\r\n
    \r\n\r\n
    \r\n openModalFrete()}>\r\n
    \r\n\r\n
    \r\n \r\n
    \r\n\r\n
    \r\n \r\n
    \r\n\r\n
    \r\n \r\n
    \r\n\r\n
    \r\n finalizar()}>\r\n Concluir Negociação\r\n \r\n
    \r\n\r\n
    \r\n \r\n Voltar\r\n \r\n
    \r\n
    \r\n {!!isPF() && }\r\n
    \r\n
    \r\n\r\n \r\n
    \r\n \r\n
    \r\n\r\n
    \r\n finalizar()}>\r\n Concluir Negociação\r\n \r\n
    \r\n\r\n
    \r\n \r\n Voltar\r\n \r\n
    \r\n
    \r\n {!!isPF() && }\r\n
    \r\n
    \r\n
    \r\n
    \r\n
    \r\n
    \r\n \r\n )\r\n}\r\n\r\nexport default Negociacao\r\n","export default __webpack_public_path__ + \"static/media/icon-arrow-right.9ec4f1b4.svg\";","import {\r\n Button,\r\n ButtonBlock,\r\n ButtonOutline,\r\n ButtonPrimary\r\n} from '../../components/Button/styles'\r\nimport { HeaderModal } from '../../components/ProfileModal/styles'\r\nimport styled, { css } from 'styled-components'\r\n\r\nexport const Wrapper = styled(HeaderModal)`\r\n top: 60px;\r\n\r\n @media (max-width: 1170px) {\r\n top: 40px;\r\n }\r\n`\r\n\r\nexport const HeaderModalBox = styled.div`\r\n ${({ theme }) => css`\r\n background: #ffffff;\r\n border-radius: 0 10px 10px 10px;\r\n padding: 40px;\r\n position: relative;\r\n text-align: left;\r\n\r\n .header-modal-account & {\r\n width: 400px;\r\n }\r\n\r\n .header-modal-category & {\r\n min-width: 1000px;\r\n padding: 0;\r\n }\r\n\r\n .header-modal-cart & {\r\n width: 400px;\r\n border-radius: 10px 0 10px 10px;\r\n padding: 0;\r\n\r\n @media (max-width: ${theme.media.cel}) {\r\n width: 100%;\r\n }\r\n }\r\n\r\n .header-modal-local & {\r\n width: 360px;\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n width: 100%;\r\n }\r\n }\r\n\r\n .header-modal-search & {\r\n padding: 30px;\r\n }\r\n\r\n .header-modal-profile & {\r\n padding: 30px 30px 10px 30px;\r\n }\r\n\r\n p {\r\n font-size: 14px;\r\n margin: 15px 0;\r\n display: block;\r\n }\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n width: 100%;\r\n border-radius: 0 0 10px 10px;\r\n }\r\n `}\r\n`\r\n\r\nexport const HeaderModalClose = styled.button`\r\n width: 20px;\r\n height: 20px;\r\n background: none;\r\n border: 0;\r\n position: absolute;\r\n top: 30px;\r\n right: 40px;\r\n transition: all 400ms;\r\n cursor: pointer;\r\n\r\n img {\r\n width: 20px;\r\n height: 20px;\r\n }\r\n\r\n &:hover {\r\n opacity: 0.6;\r\n }\r\n`\r\n\r\nexport const HeaderModalSubtitle = styled.h4`\r\n font-size: 16px;\r\n font-weight: 400;\r\n line-height: 22px;\r\n margin-bottom: 20px;\r\n white-space: pre-wrap;\r\n`\r\n\r\nexport const LocalFormGroup = styled.div`\r\n ${({ theme }) => css`\r\n margin-bottom: 20px;\r\n position: relative;\r\n\r\n label {\r\n font-size: 15px;\r\n font-weight: 600;\r\n color: #4a4a4a;\r\n display: block;\r\n letter-spacing: -1px;\r\n margin-bottom: 5px;\r\n }\r\n\r\n small {\r\n display: block;\r\n margin-bottom: 5px;\r\n }\r\n\r\n &.required {\r\n label {\r\n &:after {\r\n content: '*';\r\n color: ${theme.colors.primary};\r\n display: inline-block;\r\n margin-left: 4px;\r\n }\r\n }\r\n }\r\n\r\n position: relative;\r\n\r\n .form-input {\r\n padding-left: 60px;\r\n }\r\n `}\r\n`\r\n\r\nexport const FormTextPlaceholder = styled.span`\r\n position: absolute;\r\n top: 50%;\r\n transform: translateY(-50%);\r\n left: 15px;\r\n`\r\n\r\nexport const ConsultButton = styled.button`\r\n ${({ theme }) => css`\r\n ${Button(theme)}\r\n ${ButtonPrimary(theme)}\r\n ${ButtonBlock}\r\n `}\r\n`\r\n\r\nexport const AccessButton = styled.button`\r\n ${({ theme }) => css`\r\n ${Button(theme)}\r\n ${ButtonOutline(theme)}\r\n ${ButtonBlock}\r\n `}\r\n`\r\n","import { HeaderModal } from '../../components/ProfileModal/styles'\r\nimport styled, { css } from 'styled-components'\r\nimport IconArrowRight from '../../assets/icons/icon-arrow-right.svg'\r\n\r\nexport const Wrapper = styled(HeaderModal)`\r\n top: 60px;\r\n`\r\n\r\nexport const HeaderModalBox = styled.div`\r\n ${({ theme }) => css`\r\n background: #ffffff;\r\n border-radius: 0 10px 10px 10px;\r\n padding: 40px;\r\n position: relative;\r\n text-align: left;\r\n\r\n .header-modal-account & {\r\n width: 400px;\r\n }\r\n\r\n .header-modal-category & {\r\n min-width: 1290px;\r\n padding: 0;\r\n\r\n @media (max-width: 1340px) {\r\n min-width: 1100px;\r\n }\r\n }\r\n\r\n .header-modal-cart & {\r\n width: 400px;\r\n border-radius: 10px 0 10px 10px;\r\n padding: 0;\r\n\r\n @media (max-width: ${theme.media.cel}) {\r\n width: 100%;\r\n }\r\n }\r\n\r\n .header-modal-local & {\r\n width: 360px;\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n width: 100%;\r\n }\r\n }\r\n\r\n .header-modal-search & {\r\n padding: 30px;\r\n }\r\n\r\n .header-modal-profile & {\r\n padding: 30px 30px 10px 30px;\r\n }\r\n\r\n p {\r\n font-size: 14px;\r\n margin: 15px 0;\r\n display: block;\r\n }\r\n `}\r\n`\r\n\r\nexport const CategoryColumns = styled.div`\r\n display: flex;\r\n`\r\n\r\nexport const CategoryColumn = styled.div`\r\npadding: 40px;\r\n\r\n&:first-child {\r\n width: 30%;\r\n box-shadow: 8px 6px 17px -4px rgba(0, 0, 0, .2);\r\n}\r\n&:last-child{\r\n width: 70%;\r\n}`\r\n\r\nexport const CategoryWrapper = styled.div`\r\n font-size: 0;\r\n width: 100%;\r\n`\r\n\r\nexport const CategoryTitle = styled.h4`\r\n ${({ theme }) => css`\r\n color: ${theme.colors.primary};\r\n font-weight: 600;\r\n font-size: 16px;\r\n margin-bottom: 40px;\r\n position: relative;\r\n\r\n &:after {\r\n content: '';\r\n width: 30%;\r\n height: 3px;\r\n background: ${theme.colors.primary};\r\n display: block;\r\n position: absolute;\r\n bottom: -10px;\r\n }\r\n `}\r\n`\r\n\r\nexport const CategoryMenuList = styled.ul``\r\n\r\nexport const CategoryMenuItem = styled.li`\r\n ${({ theme }) => css`\r\n margin-bottom: 18px;\r\n\r\n a {\r\n display: block;\r\n font-size: 15px;\r\n font-weight: 600;\r\n position: relative;\r\n transition: all 400ms;\r\n\r\n &:before {\r\n content: '';\r\n background: url(${IconArrowRight}) no-repeat;\r\n background-size: contain;\r\n width: 6px;\r\n height: 10px;\r\n position: absolute;\r\n transition: all 400ms;\r\n right: 0;\r\n }\r\n\r\n &._is-active,\r\n &:hover {\r\n color: ${theme.colors.primary};\r\n\r\n &:before {\r\n transform: rotate(90deg);\r\n transform-origin: center center;\r\n }\r\n }\r\n }\r\n `}\r\n`\r\n\r\nexport const SubmenuColumn = styled.div`\r\n display: inline-block;\r\n vertical-align: top;\r\n\r\n &:first-child {\r\n width: 65%;\r\n }\r\n &:last-child {\r\n width: 35%;\r\n }\r\n`\r\n\r\nexport const CategorySubtitle = styled.h4`\r\n ${({ theme }) => css`\r\n color: ${theme.colors.primary};\r\n font-weight: 600;\r\n font-size: 16px;\r\n margin-bottom: 40px;\r\n `}\r\n`\r\n\r\nexport const CategorySubmenu = styled.ul`\r\n display: flex;\r\n flex-wrap: wrap;\r\n`\r\n\r\nexport const CategorySubmenuItem = styled.li`\r\n ${({ theme }) => css`\r\n width: 50%;\r\n margin-bottom: 18px;\r\n\r\n a {\r\n font-size: 15px;\r\n transition: all 400ms;\r\n\r\n &:hover {\r\n color: ${theme.colors.primary};\r\n }\r\n }\r\n `}\r\n`\r\n\r\n\r\n\r\nexport const CategoryDestakImage = styled.div`\r\ntext-align: right;\r\n img{\r\n border-radius: 10px;\r\n width: 90%;\r\n }`\r\n\r\nexport const CategoryDestak = styled.div`\r\n display: inline-block;\r\n vertical-align: top;\r\n\r\n &:first-child {\r\n width: 65%;\r\n }\r\n &:last-child{\r\n width: 35%;\r\n }\r\n`\r\n\r\nexport const CategoryImageDestak = styled.img`\r\n\r\n`\r\n\r\nexport const CategoryThumbnail = styled.div`\r\n text-align: right;\r\n img {\r\n border-radius: 10px;\r\n width: 90%;\r\n }\r\n`\r\n","import styled, { css } from 'styled-components'\r\nimport IconArrowDown from '../../assets/icons/icon-arrow-down.svg'\r\n\r\nexport const Wrapper = styled.nav`\r\n ${({ theme }) => css`\r\n background: ${theme.colors.grey};\r\n border-top: 1px solid #bbbbbb;\r\n position: relative;\r\n\r\n @media(max-width: ${theme.media.ipad}) {\r\n //display: none;\r\n }\r\n `}\r\n`\r\n\r\nexport const MenuContent = styled.ul`\r\n ${({ theme }) => css`\r\n display: inline-block;\r\n\r\n @media(max-width: ${theme.media.ipad}) {\r\n display: block;\r\n }\r\n `}\r\n `\r\n\r\n\r\nexport const MenuItem = styled.li`\r\n ${({ theme, active }) => css`\r\n display: inline-block;\r\n position: relative;\r\n padding: 23px 12px;\r\n\r\n &._secondary {\r\n padding-left: 25px;\r\n\r\n @media (max-width: 1390px) {\r\n padding-left: 15px;\r\n }\r\n\r\n &:before {\r\n content: '';\r\n width: 1px;\r\n height: 30px;\r\n background: #bbbbbb;\r\n position: absolute;\r\n left: 0;\r\n top: 50%;\r\n transform: translateY(-50%);\r\n }\r\n }\r\n\r\n /* &:first-child {\r\n padding: 23px 12px 23px 12px;\r\n } */\r\n\r\n &:last-child {\r\n margin-right: 0;\r\n }\r\n\r\n ${active &&\r\n css`\r\n z-index: 200;\r\n background: #ffffff;\r\n border-radius: 10px 10px 0 0;\r\n `}\r\n\r\n @media (min-width: 1391px) {\r\n padding: 23px 15px;\r\n\r\n &.menu-item {\r\n padding: 23px 12px;\r\n }\r\n\r\n }\r\n\r\n @media (max-width: 1360px) {\r\n padding: 23px 15px;\r\n &.menu-item-destaque {\r\n padding: 23px 8px;\r\n }\r\n }\r\n\r\n @media(min-width: 1281px) {\r\n padding: 23px 5px;\r\n font-size: 14px;\r\n }\r\n\r\n @media(max-width: 1280px) {\r\n &.menu-item-destaque {\r\n &:last-child {\r\n display: none;\r\n }\r\n }\r\n\r\n &.menu-item {\r\n padding: 23px 8px;\r\n }\r\n }\r\n\r\n @media(max-width: 1351px) {\r\n &.menu-item-destaque {\r\n &:nth-child(2) {\r\n display: none;\r\n }\r\n }\r\n }\r\n\r\n @media(max-width: 1233px) {\r\n &.menu-item-destaque {\r\n padding: 23px 8px;\r\n }\r\n }\r\n\r\n @media(max-width: 1210px) {\r\n &.menu-item {\r\n padding: 23px 4px;\r\n }\r\n }\r\n\r\n @media(max-width: 1176px) {\r\n &.menu-item-destaque {\r\n padding: 23px 4px;\r\n }\r\n }\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n display: none;\r\n padding: 10px;\r\n\r\n &._menu-mobile-local {\r\n display: block;\r\n text-align: center;\r\n &:before {\r\n display: none;\r\n }\r\n }\r\n }\r\n `}\r\n`\r\n\r\nexport const MenuItemLink = styled.a`\r\n ${({ theme }) => css`\r\n font-size: 14px;\r\n transition: all 400ms;\r\n\r\n &:hover {\r\n color: ${theme.colors.primary}};\r\n }\r\n `}\r\n`\r\n\r\nexport const IconCep = styled.i`\r\n background-image: url(${IconArrowDown});\r\n background-size: contain;\r\n background-repeat: no-repeat;\r\n background-position: center;\r\n display: inline-block;\r\n width: 12px;\r\n height: 8px;\r\n border:0;\r\n margin-left: 3px;`\r\n\r\nexport const LinkICons = styled.div`\r\n ${({ theme }) => css`\r\n position: relative;\r\n vertical-align: middle;\r\n display: inline-block;\r\n margin-right: 6px;\r\n\r\n img {\r\n width: 25px;\r\n height: 25px;\r\n }\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n img {\r\n width: 20px;\r\n height: 20px;\r\n }\r\n }\r\n `}\r\n`\r\n\r\nexport const TextCep = styled.div`\r\n ${({ theme }) => css`\r\n display: inline-block;\r\n vertical-align: middle;\r\n\r\n strong {\r\n color: ${theme.colors.primary};\r\n display: block;\r\n font-size: 13px;\r\n }\r\n\r\n img {\r\n display: inline-block;\r\n }\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n text-align: left;\r\n\r\n strong {\r\n display: inline-block;\r\n }\r\n }\r\n `}\r\n`\r\nexport const MenuIcon = styled.div`\r\n ${({ theme }) => css`\r\n width: 30px;\r\n position: relative;\r\n top: -17px;\r\n margin-right: 10px;\r\n display: inline-block;\r\n\r\n span {\r\n display: block;\r\n position: absolute;\r\n height: 3px;\r\n width: 100%;\r\n background: ${theme.colors.primary};\r\n border-radius: 10px;\r\n opacity: 1;\r\n left: 0;\r\n transform: rotate(0deg);\r\n transition: 0.25s ease-in-out;\r\n\r\n &:nth-child(1) {\r\n top: 0;\r\n }\r\n\r\n &:nth-child(2) {\r\n top: 10px;\r\n }\r\n\r\n &:nth-child(3) {\r\n top: 20px;\r\n }\r\n }\r\n\r\n .menu-item-category:hover & {\r\n span {\r\n z-index: 999;\r\n &:nth-child(1) {\r\n top: 10px;\r\n transform: rotate(135deg);\r\n }\r\n\r\n &:nth-child(2) {\r\n opacity: 0;\r\n left: -60px;\r\n }\r\n\r\n &:nth-child(3) {\r\n top: 10px;\r\n transform: rotate(-135deg);\r\n }\r\n }\r\n }\r\n `}\r\n`\r\n","/* eslint-disable jsx-a11y/anchor-is-valid */\r\nimport React, { useState } from 'react'\r\nimport { Link } from 'react-router-dom'\r\nimport * as S from './styles'\r\n\r\nfunction Category({ active, categories }) {\r\n const [arraySubCategories, setOpenSubCategories] = useState([])\r\n const [activeLink, setActiveClass] = useState(1)\r\n const [htmlPublicidade, setHtmlPublicidade] = useState()\r\n\r\n function createMarkup(textHtml) {\r\n return {\r\n __html: textHtml\r\n }\r\n }\r\n\r\n const handleClick = (activeLink, arraySubCategories) => {\r\n const publicidadeMenu = categories.categorias.filter(\r\n (c) => c.id === activeLink\r\n )[0].publicidadeMenu\r\n\r\n let div = document.createElement('div')\r\n let newDiv = document.createElement('div')\r\n let newImage = document.createElement('img')\r\n\r\n div.innerHTML = publicidadeMenu\r\n\r\n let aElement = div.querySelector('a')\r\n if (aElement) {\r\n let imageSrc = div?.querySelector('img')?.getAttribute('src')\r\n \r\n aElement?.children[0]?.removeAttribute('src')\r\n aElement.removeAttribute('style')\r\n newImage.src = 'https://squadhomologacao.gimba.com.br' + imageSrc\r\n aElement.removeChild(aElement?.children[0])\r\n aElement.appendChild(newImage)\r\n newDiv.appendChild(aElement)\r\n }\r\n\r\n setActiveClass(activeLink)\r\n setOpenSubCategories(arraySubCategories)\r\n setHtmlPublicidade(newDiv.innerHTML)\r\n }\r\n return (\r\n \r\n \r\n \r\n \r\n \r\n \r\n Todas as Categorias\r\n \r\n \r\n {categories &&\r\n categories.categorias.map(function (item, i) {\r\n return (\r\n \r\n \r\n handleClick(item.id, item.subCategorias)\r\n }\r\n >\r\n {item.nome}\r\n \r\n \r\n )\r\n })}\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n {arraySubCategories &&\r\n arraySubCategories.map(function (itemSub, i) {\r\n return (\r\n \r\n \r\n {itemSub.nome}\r\n \r\n \r\n )\r\n })}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n )\r\n}\r\nexport default Category\r\n","import styled, { css } from 'styled-components'\r\n\r\nexport const FrameFooter = styled.iframe`\r\n height: 540px;\r\n\r\n @media (max-width: 1170px) {\r\n height: 230px;\r\n }\r\n`\r\n\r\nexport const Wrapper = styled.footer`\r\n /* ${({ theme }) => css`\r\n background: ${theme.colors.grey};\r\n padding: 30px 0;\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n display: none;\r\n }\r\n `} */\r\n`\r\n\r\nexport const FooterWrapper = styled.div`\r\n margin: auto;\r\n max-width: 1360px;\r\n position: relative;\r\n width: 100%;\r\n\r\n @media (max-width: 1450px) {\r\n max-width: 95%;\r\n }\r\n`\r\n\r\nexport const FooterColumns = styled.div`\r\n display: block;\r\n font-size: 0;\r\n width: 100%;\r\n`\r\n\r\nexport const FooterColumn = styled.div`\r\n ${({ theme }) => css`\r\n display: inline-block;\r\n width: 20%;\r\n vertical-align: top;\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n display: none;\r\n }\r\n `}\r\n`\r\n\r\nexport const FooterBox = styled.div`\r\n padding: 20px;\r\n`\r\n\r\nexport const FooterTitle = styled.h3`\r\n font-size: 20px;\r\n font-weight: bold;\r\n margin-bottom: 20px;\r\n color: #8f8f8f;\r\n`\r\n\r\nexport const FooterList = styled.ul``\r\n\r\nexport const FooterListItem = styled.li`\r\n ${({ theme }) => css`\r\n margin-bottom: 12px;\r\n\r\n a {\r\n font-size: 14px;\r\n transition: all 400ms;\r\n cursor: pointer;\r\n\r\n &:hover {\r\n color: ${theme.colors.primary};\r\n }\r\n }\r\n `}\r\n`\r\n\r\nexport const FooterSocialMediaItem = styled.ul`\r\n display: inline-block;\r\n margin: 5px 10px 5px 0;\r\n\r\n a {\r\n transition: all 400ms;\r\n\r\n &:hover {\r\n opacity: 0.5;\r\n }\r\n }\r\n`\r\n\r\nexport const FooterInformations = styled.div`\r\n padding: 0 20px;\r\n\r\n p {\r\n color: #8f8f8f;\r\n margin-bottom: 10px;\r\n font-size: 14px;\r\n }\r\n\r\n strong {\r\n margin-right: 10px;\r\n }\r\n`\r\nexport const FooterImage = styled.img`\r\n width: 100%;\r\n`\r\n","import * as S from './styles'\r\n\r\nimport { useRef, useState } from 'react'\r\n\r\nconst Footer = () => {\r\n return (\r\n \r\n \r\n \r\n\r\n // \r\n // \r\n // \r\n // \r\n // \r\n // Gimba\r\n // \r\n // {mock.content.gimba.map(({ name, link }, index) => (\r\n // \r\n // {name}\r\n // \r\n // ))}\r\n // \r\n // \r\n // \r\n\r\n // \r\n // \r\n // Para Você\r\n // \r\n // {mock.content.paravoce.map(({ name, link }, index) => (\r\n // \r\n // {name}\r\n // \r\n // ))}\r\n // \r\n // \r\n // \r\n\r\n // \r\n // \r\n // Serviços\r\n // \r\n // {mock.content.servicos.map(({ name, link }, index) => (\r\n // \r\n // {name}\r\n // \r\n // ))}\r\n // \r\n // \r\n // \r\n\r\n // \r\n // \r\n // Fornecedor\r\n // \r\n // {mock.content.fornecedor.map(({ name, link }, index) => (\r\n // \r\n // {name}\r\n // \r\n // ))}\r\n // \r\n // \r\n\r\n // \r\n // Corporativo\r\n // \r\n // {mock.content.corporativo.map(({ name, link }, index) => (\r\n // \r\n // {name}\r\n // \r\n // ))}\r\n // \r\n // \r\n // \r\n\r\n // \r\n // \r\n // \r\n // Compra segura\r\n // \r\n // \r\n // \r\n\r\n // \r\n // Pagamento\r\n // \r\n // \r\n // \r\n // \r\n\r\n // \r\n // \r\n // Redes Sociais\r\n // \r\n // \r\n // {mock.content.socialmedia.map(({ link, icon }, index) => (\r\n // \r\n // \r\n // \r\n // \r\n // \r\n // ))}\r\n // \r\n // \r\n // \r\n // \r\n // \r\n //

    \r\n // Razão Social:\r\n // Supricorp Suprimentos Ltda / CNPJ: 54.651.716/0011-50\r\n //

    \r\n //

    \r\n // Endereço:\r\n // Avenida Prefeito João Vilallobo Quero, 1160 - Jardim Belval - Barueri\r\n // - SP | CEP: 06422-122\r\n //

    \r\n //
    \r\n //
    \r\n //
    \r\n )\r\n}\r\n\r\nexport default Footer\r\n","import styled, { css } from 'styled-components'\r\n\r\nexport const Profile = styled.section`\r\n background-color: rgb(251, 251, 251);\r\n padding: 60px 0;\r\n`\r\n\r\nexport const PageContent = styled.div``\r\n\r\nexport const Wrapper = styled.div`\r\n max-width: 1360px;\r\n margin: 0 auto;\r\n position: relative;\r\n width: 100%;\r\n\r\n @media (max-width: 1390px) {\r\n max-width: 95%;\r\n }\r\n`\r\nexport const ColGroup = styled.div`\r\n max-width: 1360px;\r\n display: flex;\r\n justify-content: center;\r\n align-items: flex-start;\r\n\r\n @media (max-width: 1170px) {\r\n .col-3 {\r\n display: none;\r\n }\r\n\r\n .col-9 {\r\n width: 100%;\r\n }\r\n }\r\n`\r\nexport const ProfileContent = styled.div`\r\n`\r\n\r\nexport const ProfileMenu = styled.nav`\r\n margin-right: 15%;\r\n`\r\n\r\nexport const ProfileBox = styled.div`\r\n background: #ffffff;\r\n padding: 30px 30px 30px 30px;\r\n border: 1px solid #e5e5e5;\r\n border-radius: 10px;\r\n -webkit-box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n box-shadow: 0px 0px 4px rgba(0, 0, 0, 0.1);\r\n margin-bottom: 20px;\r\n`\r\n\r\nexport const ProfileBoxFooter = styled.div`\r\n margin: 10px 0 20px 0;\r\n`\r\n\r\nexport const ButtonAddNewAddress = styled.button`\r\n ${({ theme }) => css`\r\n border-radius: 5px;\r\n border: 2px solid transparent;\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 500;\r\n font-size: 16px;\r\n padding: 15px 30px;\r\n text-align: center;\r\n transition: ${theme.transition.default};\r\n cursor: pointer;\r\n background: ${theme.colors.primary};\r\n color: ${theme.colors.white};\r\n\r\n &:hover {\r\n background: #a71e26;\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n font-size: 14px;\r\n }\r\n `}\r\n`\r\n","import styled, { css } from 'styled-components'\r\n\r\nexport const ErrorBox = styled.div`\r\n margin: 0 auto;\r\n max-width: 800px;\r\n padding: 32px;\r\n display: flex;\r\n justify-content: space-between;\r\n\r\n img {\r\n width: 280px;\r\n }\r\n\r\n .error-info {\r\n display: flex;\r\n flex-direction: column;\r\n gap: 16px;\r\n text-align: center;\r\n\r\n h1 {\r\n font-weight: 500;\r\n font-size: 120px;\r\n margin: 0;\r\n }\r\n\r\n strong {\r\n font-weight: 600;\r\n font-size: 20px;\r\n margin-top: -32px;\r\n }\r\n\r\n p {\r\n font-weight: 400;\r\n font-size: 16px;\r\n margin-bottom: 12px;\r\n }\r\n\r\n button {\r\n }\r\n }\r\n\r\n @media (max-width: 800px) {\r\n justify-content: center;\r\n img {\r\n display: none;\r\n }\r\n }\r\n`\r\n\r\nexport const Button = styled.button`\r\n ${({ theme }) => css`\r\n border-radius: 4px;\r\n border: 2px solid transparent;\r\n font-family: 'Montserrat', sans-serif;\r\n font-weight: 500;\r\n font-size: 16px;\r\n padding: 10px 30px;\r\n text-align: center;\r\n transition: ${theme.transition.default};\r\n cursor: pointer;\r\n background: ${theme.colors.primary};\r\n color: ${theme.colors.white};\r\n\r\n &:hover {\r\n background: #a71e26;\r\n }\r\n\r\n & + .button {\r\n margin-left: 15px;\r\n }\r\n\r\n @media (max-width: ${theme.media.ipad}) {\r\n font-size: 14px;\r\n }\r\n `}\r\n`\r\n","export default __webpack_public_path__ + \"static/media/carrinho.4d596e43.png\";","import * as S from './styles'\r\nimport ImgCarrinho from '../../assets/products/carrinho.png'\r\nimport { Link } from 'react-router-dom'\r\n\r\nconst ErrorNotFound = () => {\r\n return (\r\n \r\n \"\"\r\n
    \r\n

    404

    \r\n Ops, página não encontrada\r\n

    \r\n Verifique o endereço ou utilize a barra\r\n
    \r\n de pesquisa, milhares de ofertas esperam por você\r\n

    \r\n \r\n Ir para página Inicial\r\n \r\n
    \r\n
    \r\n )\r\n}\r\n\r\nexport default ErrorNotFound\r\n","import Header from '../../components/Header'\r\nimport MediaMatch from '../../components/MediaMatch'\r\nimport Menu from '../../components/Menu'\r\nimport Footer from '../../components/Footer'\r\nimport * as S from '../../styles/page-profile'\r\nimport ErrorNotFound from '../../components/ErrorNotFound'\r\n\r\nfunction Erro404() {\r\n return (\r\n <>\r\n
    \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n