{"version":3,"sources":["services/api.ts","services/apis.ts","constants/others/states.ts","utils/validations.ts","utils/format.tsx","utils/mask.ts","utils/date.ts","services/apiBolsa.ts","utils/utils.ts","utils/business-day.ts","services/msDarf.ts","services/apiPlan.ts","services/apiVeloPro.ts","assets/ssl-secure.svg","services/apiExterior.ts","services/apiPayment.ts","services/rendimentos.ts","services/apiBolsaVelotax.ts","services/apiIrpf2023.ts","components/Button/styles.ts","components/Button/index.tsx","components/UserPlanModal/UserPlan/styles.ts","components/UserPlanModal/UserPlan/index.tsx","services/handleTag.ts","constants/plans/index.tsx","components/PlanModal/styles.ts","components/CopyText/index.tsx","pages/SSO/styles.ts","assets/velotax/velotax-light.svg","pages/SSO/index.tsx","pages/Home/styles.ts","services/apiCrypto.ts","components/LoadingIntegration/index.tsx","contexts/B3IntegrationContext.tsx","pages/Home/index.tsx","styles/LoginSignUp/authContainer.ts","utils/formValidations.ts","pages/Login/index.tsx","pages/Cadastro/index.tsx","pages/Sucesso/styles.ts","pages/Sucesso/index.tsx","pages/Carteira/styles.ts","components/Loading/index.tsx","components/ChartBar/index.tsx","components/Proventos/styles.ts","components/ProventosModal/styles.ts","components/DrawerModal/index.tsx","components/ReportType/styles.ts","components/ReportType/ReportType.tsx","assets/icons/filtro.svg","constants/darf/index.tsx","components/ProventosModal/index.tsx","contexts/NotificationContext.tsx","components/Proventos/index.tsx","contexts/CarteiraContext.tsx","utils/walletCharts.ts","components/MeusInvestimentos/styles.ts","utils/patrimonio.ts","components/FooterModal/index.tsx","constants/inputs/index.tsx","constants/formItems/index.ts","constants/darfBolsa/index.tsx","utils/getDolarQuote.ts","pages/HistoricBolsa/utils.ts","components/MeusInvestimentos/PosicaoCard/styles.ts","constants/rendimentos/index.tsx","components/MeusInvestimentos/PosicaoCard/index.tsx","components/MeusInvestimentos/index.tsx","components/Notification/styles.ts","assets/notification.svg","components/Notification/Notification.tsx","components/MeusInvestimentos/Avisos/styles.ts","components/MeusInvestimentos/DrawerModal/index.tsx","components/MeusInvestimentos/IntegrationModal/styles.ts","assets/Integracao_XP_B3.gif","assets/integracao_warren_exterior.gif","components/MeusInvestimentos/IntegrationModal/index.tsx","components/MeusInvestimentos/Avisos/index.tsx","pages/Carteira/index.tsx","pages/MinhaConta/styles.ts","pages/MinhaConta/MeuPlano/index.tsx","pages/MinhaConta/index.tsx","pages/Regulation/styles.ts","constants/regulation/index.tsx","pages/Regulation/index.tsx","pages/Darf/styles.ts","components/FormModal/index.tsx","pages/Darf/Components/IntegrationModal/index.tsx","pages/Darf/Components/DatePickerExtraFooter/index.tsx","components/DeleteConfirmationModal/index.tsx","pages/Darf/Components/DatePickerMonthCell/index.tsx","pages/Darf/index.tsx","pages/Exterior/Cards/styles.ts","pages/Exterior/Cards/index.tsx","pages/Bolsa/itensBolsa.tsx","pages/Crypto/itensCrypto.tsx","components/PageInfo/styles.ts","components/PageInfo/index.tsx","components/PlanModal/Plan/styles.ts","components/PlanModal/Plan/index.tsx","components/Payment/CreditCardStep/components/Footer/index.tsx","components/CardList/styles.ts","constants/taxes/index.ts","utils/getInstallmentsListByPrice.tsx","components/CardList/index.tsx","components/Payment/CreditCardStep/index.tsx","components/Payment/CreditCardStep/components/CardForm/index.tsx","services/cep.ts","components/Payment/CreditCardStep/components/AddressForm/index.tsx","components/Payment/CreditCardStep/components/ResultScreen/components/ErrorScreen/index.tsx","components/Payment/CreditCardStep/components/ResultScreen/components/ConfirmScreen/index.tsx","components/Payment/CreditCardStep/components/ResultScreen/index.tsx","components/Payment/CreditCardStep/components/ResultScreen/components/PendingScreen/index.tsx","constants/identification/index.tsx","components/PlanModal/index.tsx","pages/MeiDas/styles.ts","pages/Darf/Components/PayTags/styles.ts","constants/das/index.tsx","pages/DarfExterior/InterestModalContent/index.tsx","pages/Historic/styles.ts","pages/DarfExterior/InterestModalContent/styles.ts","pages/DarfExterior/ExteriorModalContent/index.tsx","components/BackButton/styles.ts","components/BackButton/index.tsx","pages/DarfExterior/ExteriorModalContent/styles.ts","pages/IntegrationBolsa/NotasHistoricoModal/index.tsx","pages/DarfExterior/index.tsx","pages/DarfExterior/useDarfExterior.ts","components/CardXP/style.ts","components/CardXP/index.tsx","pages/HistoricBolsa/PayButton/index.tsx","pages/Exterior/itensExterior.tsx","assets/icons/check.svg","pages/HistoricBolsa/PayDarfButton/styles.ts","pages/HistoricBolsa/PayDarfButton/index.tsx","services/msCalc.ts","pages/Settings/SelectBoxes/styles.ts","pages/Settings/SelectBoxes/index.tsx","pages/Settings/styles.ts","pages/DarfBolsa/styles.ts","contexts/OldTransactionsContext.tsx","utils/handleDownloadSheet.ts","components/ModalZeroBuyPrice/index.tsx","pages/DarfBolsa/index.tsx","pages/MeiReport/styles.ts","pages/ReportBolsa/items.tsx","pages/ReportBolsa/styles.ts","pages/ReportBolsa/index.tsx","pages/Integration/styles.ts","pages/Darf/Components/OldTransactions/styles.ts","pages/Darf/Components/OldTransactions/index.tsx","pages/BolsaManual/items.tsx","pages/BolsaManual/styles.ts","pages/PrePreenchidaModal/styles.ts","components/UploadVelotax/styles.ts","components/UploadVelotax/index.tsx","contexts/UploadDecContext.tsx","assets/govbr.svg","pages/DecPrepreenchida/styles.ts","contexts/YearContext.tsx","pages/DecPrepreenchida/index.tsx","pages/PrePreenchidaModal/index.tsx","pages/MeiIdentification/styles.ts","pages/Rendimentos/styles.ts","pages/AnnualReport/styles.ts","pages/HistoricBolsa/styles.ts","contexts/TransferenciaCustodiaContext.tsx","pages/IntegrationBolsa/NotasCorretagem/useNotasCorretagem.ts","pages/ReportExterior/items.tsx","pages/ReportExterior/styles.ts","pages/ReportExterior/index.tsx","pages/DividendosBolsa/styles.ts","utils/sendEmailSheet.ts","pages/DividendosBolsa/modal.tsx","pages/DividendosBolsa/dataSourceList.ts","constants/dividendos/index.tsx","pages/IntegrationBolsa/styles.ts","assets/b3-logo-white.svg","components/IntegrationComponents/IntegrationButton/styles.ts","components/IntegrationComponents/IntegrationButton/index.tsx","pages/IntegrationBolsa/B3IntegrationButtons/index.tsx","pages/IntegrationCrypto/styles.ts","pages/IntegrationCrypto/NotasCorretagem/useNotasCorretagem.ts","pages/IntegrationCrypto/NotasCorretagem/index.tsx","pages/DividendosExterior/dataSourceList.ts","components/DividendosModal/index.tsx","pages/DividendosExterior/styles.ts","pages/AutonomosDarf/styles.ts","pages/AutonomosDarf/index.tsx","pages/IntegrationExterior/styles.ts","components/IntegrationComponents/PassfolioIntegration/PassfolioIntegrationModal.tsx","assets/warren-logo.svg","components/IntegrationComponents/PassfolioIntegration/index.tsx","components/IntegrationComponents/ExteriorIntegration/index.tsx","pages/IntegrationExteriorXP/styles.ts","pages/TransferenciaCustodia/styles.ts","pages/TransferenciaCustodia/formItems.tsx","pages/DoacoesHeranca/Components/DoacoesHerancas/styles.ts","pages/DoacoesHeranca/Components/DoacoesHerancas/index.tsx","pages/DoacoesHeranca/items.tsx","pages/DoacoesHeranca/styles.ts","constants/brokers/pages.tsx","pages/Bolsa/index.tsx","pages/Crypto/index.tsx","pages/MeiDas/index.tsx","pages/Exterior/index.tsx","pages/Historic/index.tsx","pages/Settings/index.tsx","pages/MeiReport/index.tsx","pages/Integration/index.tsx","pages/BolsaManual/index.tsx","pages/DoacoesHeranca/index.tsx","pages/Rendimentos/index.tsx","pages/AnnualReport/index.tsx","pages/HistoricBolsa/index.tsx","pages/MeiIdentification/index.tsx","pages/DividendosBolsa/index.tsx","pages/IntegrationBolsa/index.tsx","pages/IntegrationCrypto/index.tsx","pages/DividendosExterior/index.tsx","pages/IntegrationExterior/index.tsx","pages/TransferenciaCustodia/index.tsx","pages/IntegrationExteriorXP/index.tsx","pages/Planos/styles.ts","assets/icons/selo-play-store.svg","assets/icons/selo-app-store.svg","pages/Planos/planos.tsx","assets/icons/selo-7-dias.svg","assets/icons/selo-garantia.svg","pages/Planos/index.tsx","constants/managerAccess/index.tsx","pages/ManagerAccess/styles.ts","components/PermissaoAssessorModal/styles.ts","components/PermissaoAssessorModal/index.tsx","contexts/RequireAccessContext.tsx","pages/ManagerAccess/index.tsx","pages/PGBLSimulator/items.tsx","pages/PGBLSimulator/styles.ts","pages/PGBLSimulator/index.tsx","pages/ForgotPassword/index.tsx","pages/ChangePassword/index.tsx","assets/icons/sidebar/bolsa.svg","assets/icons/sidebar/exterior.svg","components/PaymentModal/index.tsx","constants/brokers/index.tsx","assets/warren-favicon.png","assets/velotax/velologo.svg","components/LoadingSession/index.tsx","components/NameNotification/index.tsx","contexts/BrokerContext.tsx","components/Payment/PixPaymentStep/index.tsx","components/PaymentModal/style.ts","components/UserPlanModal/index.tsx","contexts/AuthContext.tsx","routes/PrivateRoutes.tsx","routes/OnlyPublicRoute.tsx","assets/velotax/veloicon.svg","pages/PageNotFound/index.tsx","components/Header/styles.ts","contexts/HistoryContext.tsx","components/Header/index.tsx","components/Logo/styles.ts","components/Logo/index.tsx","components/PoweredByVelotax/index.tsx","assets/icons/sidebar/sair.svg","assets/icons/sidebar/irpf.svg","assets/icons/sidebar/conta.svg","components/Sidebar/styles.ts","components/Sidebar/index.tsx","components/PageWrapper/styles.ts","components/TabNavigator/styles.ts","assets/calculadoras/bolsa-de-valores.svg","assets/calculadoras/ativos-no-exterior.svg","components/TabNavigator/index.tsx","pages/Home/IRPFBanner/styles.ts","pages/Home/IRPFBanner/index.tsx","components/PageWrapper/index.tsx","components/PublicWrapper/Header/styles.ts","components/PublicWrapper/Header/index.tsx","components/PublicWrapper/styles.ts","components/PublicWrapper/index.tsx","routes/index.tsx","styles/global.ts","styles/warren.ts","services/chatApi.ts","components/ChatGPT/styles.ts","components/ChatGPT/index.tsx","styles/container.ts","styles/drawer-modal.ts","contexts/ContextWrapper.tsx","styles/historic-list.ts","components/ErrorBoundary/index.tsx","components/Support/styles.ts","components/Support/index.tsx","App.tsx","reportWebVitals.ts","assets/fonts/WarrenText-Bold.ttf","assets/fonts/WarrenText-Regular.ttf","assets/fonts/WarrenDisplay-Bold.ttf","index.tsx"],"names":["api","axios","create","baseURL","process","headers","apis","NOT_AUTHORIZED","states","isValidCNPJ","cnpj","validateBr","isValidPhone","phone","yup","isValidSync","replace","length","isValidDate","date","test","checkDateExpiration","limit","value","split","day","month","year","Date","Number","removeSpecialCharacters","normalize","formatCurrency","prefix","decimalScale","displayType","decimalSeparator","thousandSeparator","fixedDecimalScale","toLocaleString","minimumFractionDigits","maximumFractionDigits","numberToPercentage","toFixed","number","numberToPercentageWallet","currencyToNumber","replaceDotByComma","String","zero","n","formatDate","dateString","getFullYear","getDate","getMonth","formatDateHour","moment","format","cpfInputMask","maskCpf","cpf","includes","cpfArray","splice","join","maskCnpj","cnpjArray","getInitialYear","months","monthsExtended","antDatePickerLocale","lang","placeholder","CalendarLocale","timePickerLocale","B3AuthURL","isSafari","navigator","userAgent","iOSList","isMobile","platform","userAgentData","maxTouchPoints","isIOS","errorMessage","download","link","window","location","href","downloadPDF","base64","fileName","linkSource","downloadLink","document","createElement","now","click","getMuiInputCss","querySelector","classList","find","c","getZeroBuyPrice","data","hasZero","apiBolsa","get","donations","pos2019","element","code","toLowerCase","market","buyPrice","reasonDictionary","text","textLink","hasDonations","filter","op","orders","ord","push","hasPos2019","reason","price","elementsRepeat","item","isBusinessDay","require","getLastBusinessDay","lastDayOfTheMonth","holidays","tz","setDate","REACT_APP_MS_DARF_URL","apiPlan","apiVeloPro","apiPayment","REACT_APP_BACKEND_RENDIMENTOS_URL","ButtonStyled","styled","Button","props","type","css","size","disabled","typed","children","Container","div","PlanModalStyled","Modal","UserPlan","plan","planBuyed","handleSelect","cupomMsg","checkIfCupomIsValid","cupomInfo","buttonLoading","codeSave","setCode","showInputCupom","user","useAuth","useState","acceptTerms","setAcceptTerms","isActive","userPlanInfoVelotax","active","hasPlan","free","isPlanSelected","useMemo","isMonth","interval","planPrice","discountValue","Title","level","title","className","style","width","display","justifyContent","toLocaleLowerCase","originalPrice","Text","delete","color","percentDiscount","discountText","marginTop","includedFeatures","map","feature","name","secondaryIcon","icon","descriptions","opacity","checked","label","info","onChange","terms","target","rel","onClick","e","message","warning","loading","HandleTag","activeCampaignTagId","post","then","catch","err","PlanEnum","UserPlanEnum","OtherFeatures","UserPlans","VELOTAX_MAIN_PRO","instalments","maskValue","overlayStyle","backgroundColor","fontSize","fontWeight","Plans","BASIC_V1","discount","otherFeatures","slice","PRO_V1","Content","Loading","CopyText","selection","range","body","createTextRange","moveToElementText","getElementById","id","select","getSelection","createRange","selectNode","removeAllRanges","addRange","selectText","SSO","token","useParams","navigate","useNavigate","search","useLocation","setLocalStorageWithAuthData","setLoadingSession","showUserPlanModal","setLoading","useEffect","res","success","authorization","retPlanInfo","query","URLSearchParams","redirect","setTimeout","error","src","veloLogo","alt","LoadingOutlined","htmlType","HomeContainer","LoadingIntegration","show","hasError","integrationInBackground","useB3Integration","timer","setTimer","close","setClose","finishTimer","useRef","initialTimer","undefined","current","setInterval","clearInterval","clsx","B3IntegrationContext","createContext","B3IntegrationProvider","b3Authorized","setB3Authorized","useBroker","integration","initIntegration","handleIntegrationInit","timeOver","setTimeOver","loadingIntegration","setLoadingIntegration","loadingAuthorization","setLoadingAuthorization","checkingAuhtorization","setCheckingAuhtorization","setIntegrationInBackground","historicoNotasCorretagem","setHistoricoNotasCorretagem","loadingHistoricoNotasCorretagem","setLoadingHistoricoNotasCorretagem","showHistoricoNotasCorretagemModal","setShowHistoricoNotasCorretagemModal","timerInterval","openWithLink","downloadNotaCorretagem","path","crypto","apiCrypto","params","url","open","getHistoricoNotasCorretagem","a","filters","filterDay","filterMonth","filterYear","nota","openB3Window","useCallback","integrate","onlyPrepareBolsa","email","response","finally","verifyUserIsAuthorized","once","autoError","autoSuccess","count","requestUserAuthorization","firstTime","isAuthorized","resetB3IntegrationContext","handleIntegrate","integrated","Provider","notas","useContext","Home","allPaths","pathBackup","currentBroker","lastUpdate","justify","AuthContainer","section","validationCpf","required","validator","_","Promise","resolve","reject","Error","validationCnpj","validationFullName","rule","trim","validationEmail","validationPhone","validationPhoneRequired","validationDateNotRequired","validationDate","validationDateIsOnReferenceMonth","momentDate","start","startOf","end","endOf","isBetween","isDateOnReferenceMonth","validationDateIsOnReferenceMonthCompra","today","pastLimit","getTime","validationFieldRequired","validationNumberField","min","max","validationNumberAllowNegativeField","validationNumberFieldPositive","validationStateAddress","toUpperCase","isValidStateAddress","validationCardShelfLife","currentMonth","currentYear","substring","monthYearTime","valueTime","reverse","isValidShelfLife","validationCep","cep","validationAmexCVV","validationCVV","validationPassword","validationPassConfirmation","getFieldValue","validationCreditCardNumber","Payment","fns","validateCardNumber","isValidCreditCard","MaskCPF","React","forwardRef","ref","mask","Login","Form","useForm","form","handleSignIn","getIntegrationStatus","fieldsError","setFieldsError","onFinish","onValuesChange","changed","values","setFieldsValue","onFieldsChange","getFieldsError","reduce","acc","cur","errors","Item","rules","TextField","variant","InputProps","inputComponent","startIcon","Cadastro","handleSignUp","showPassword","setShowPassword","FormControl","fullWidth","InputLabel","htmlFor","FilledInput","endAdornment","InputAdornment","position","IconButton","aria-label","onMouseDown","preventDefault","edge","getValueFromEvent","Sucesso","Paragraph","ChartBar","monthReport","proventos","yearProventos","typeProventos","hideValues","setDataChart","bars","setBars","totalDiv","setTotalDiv","totalJscp","setTotalJscp","totalBonds","setTotalBonds","totalRendi","setTotalRendi","totalAmort","setTotalAmort","chartColors","background","getProviderColor","provider","index","proventoByMonth","juros","dividendo","rendimento","amortizacao","bonds","groupedProventos","groupBy","key","operations","forEach","el","corporateActionTypeDescription","grossAmount","barsChart","corretora","futuro","liquidado","types","isFuturo","labelFormatter","ResponsiveContainer","height","BarChart","margin","top","left","XAxis","dataKey","YAxis","axisLine","tick","Tooltip","content","payload","verificacaoValorFinal","acumulador","total","keys","Object","Legend","fill","align","layout","iconType","verticalAlign","formatter","entry","Bar","stackId","BlurContent","ContainerProventos","ContainerModal","DrawerModal","visible","onCancel","destroyOnClose","placement","onClose","footer","ReportTypeContainer","ReportTypeDrawer","setType","closeIcon","cursor","InfoCircleOutlined","_extends","assign","bind","i","arguments","source","prototype","hasOwnProperty","call","apply","this","_objectWithoutProperties","excluded","sourceKeys","indexOf","_objectWithoutPropertiesLoose","getOwnPropertySymbols","sourceSymbolKeys","propertyIsEnumerable","d","strokeWidth","strokeLinecap","strokeLinejoin","SvgFiltro","_ref","svgRef","titleId","viewBox","xmlns","FormCurrencyMode","FormMovimentTypeMode","FormMovimentTypeModeNew","ForwardRef","Jan","Fev","Mar","Abr","Mai","Jun","Jul","Ago","Set","Out","Nov","Dez","ProventosModal","setOpenModal","proventosLoading","setYearProventos","setMonthProventos","dateFormat","dateBeginRef","setData","setTotal","setFilters","dataModalPDF","setDataModalPDF","originalData","setOriginalData","dateBeginFilter","setDateBeginFilter","appliedFilters","setAppliedFilters","showFilterModal","setShowFilterModal","reportDrawerProventos","setReportDrawerProventos","dateEndFilter","setDateEndFilter","downloadRelatorioProventos","fileUrl","file","escritorioId","username","ret","workbook","XLSX","book_new","worksheet","json_to_sheet","book_append_sheet","reportPDFData","capitalize","quantity","unitPrice","monthNumber","dataFiltered","monthOp","yearOp","dataSerialized","Produto","Pagamento","Tipo","Instituição","getCorretFilters","newCorret","maskClosable","defaultValue","minWidth","getPopupContainer","trigger","parentElement","options","m","y","dataSource","pagination","defaultPageSize","defaultCurrent","showSizeChanger","columns","dataIndex","zIndex","gutter","span","strong","Group","corretoras","dropdownClassName","marginBottom","block","dataFinal","corret","dateBegin","toDate","dateEnd","datePagamento","getProventosWithFilter","NotificationContext","NotificationProvider","notification","setNotification","fetched","setFetched","getNotification","defaults","common","useNotification","Proventos","hasPremiunPlan","hasPermissionExterior","hasPermissionGeneral","openModal","setProventos","monthProventos","loadingDownload","setLoadingDownload","setProventosLoading","loadingReport","setLoadingReport","setTypeProventos","updated","downloadExcel","serializedData","serializeDataExcel","downloadRelatorio","newProventos","padding","some","p","toString","existsProvCurrentMonth","autoAdjustOverflow","CarteiraContext","CarteiraProvider","setLastUpdate","carteira","setCarteira","posicoesFilter","setPosicoesFilter","getCarteira","refresh","status","updateFilter","posicoes","patch","console","log","getPatrimonios","useCarteira","IsentCardStyled","getNomeCorretora","shortName","getCategoriaShortName","categoria","calculaSaldoCorretoras","posicao2019","agrupadoPorCorretora","saldosCorretoras","saldo","prev","curr","posicao","calculaPorgentagensCategorias","getTodasAsCorretoras","calculaClassesAtivos","agrupadoPorCategoria","saldosCategorias","totalSaldos","percentage","calculaPorcentagemPosicoes","patrimonioTotal","posicoesOrdenadas","sort","b","porcentagens","hasPosition2019","porcentagem","codigo","porcentagensOrdenadas","somatorioDasMaioresPorcentagens","somatorioDosMaioresValores","po","FooterModal","onOk","dark","saveButtonText","cancelButtonText","TextInput","InputLabelProps","shrink","SelectLabled","rest","Select","labelId","option","MenuItem","NumberInput","maxLength","allowNegative","NumberFormatCustom","getInputRef","MaskInput","MaskedCustom","RadioInput","MaskFormItem","input","DateFormItem","TextFormItem","SelectFormItem","RadioFormItem","NumberFormItem","CurrencyFormItem","yearConfigPL4173","historicoVendasEmptyText","YearResumeStatusFromBackEnum","YearResumeStatusCSSClassEnum","YearResumeStatusColorEnum","YearResumeStatusTextEnum","defaultDarf","totalAlienado","impostoDevido","impostoAcumulado","totalImpostoDevido","aliquotaDevida","totalGanho","multa","memoriaCalculo","minDarfPrice","maxDarfPrice","maxPixPayment","maxCreditCardPayment","MultaModalProps","JurosModalProps","MinPriceModalProps","AliquotaModalProps","DarfModal","reemit","ReemitirDarfModalProps","EmitirDarfModalProps","DarfResultDescriptionsExterior","Component","view","Math","paddingLeft","setDataBolsa","setDataCripto","currentPage","edit","setEdit","editForm","handleEditValueCancel","resetFields","isEditting","handleEditValue","handleEdit","DarfResultDescriptions","DarfImpostosDevidosDescriptions","render","FormItemsCrypto","hidden","precoVenda","custoCompra","avgBuyPrice","taxas","feeB3","ativo","quantidade","ganho","operacao","mercado","FormItemsExterior","movimentType","setMovimentType","fromApi","VENDA","JUROS","DIVIDENDOS","OUTROS","valueOriginBRA","valueOriginEUA","dataCompra","cotacaoCompra","quotations","keycompra","isComplete","subtract","venda","fee","dataVenda","dataVendaFee","cotacaoVenda","keyvenda","compra","cotacaoVendaFee","dataFee","quotes","newDate15Day","newDateLastMonth","setMonth","isRuning","lastBusinessDay","getQuoteFortnight","A","B","C","cambioCompra","D","valor","E","F","cambioVenda","ganhoFee","cambioVendaFee","valorNewModel","capitalGain","capitalGainBRL","sellPrice_BRL","buyPrice_BRL","fee_BRL","valueOriginBRL","feeBRL","DarfFormItemRows","userIrrfComum","userIrrfDayTrade","userIrrfFII","ExteriorFormItemRows","editAsset","asset","ExteriorNewFormItemRows","fator","sellPrice","vendasTotais","transactions","t","exteriorTransactionsFilter","operation","manual","vendasIsentas","codigosIsentos","mercadoIsento","valueIsGreaterThanMin","impostoComumFinal","impostoDTFinal","impostoFIIFinal","showPayButton","impostoTotalFinal","valueIsLessThanMax","payed","impostoCharge","valorPrincipal","multaAux","jurosAux","PosicaoCardStyled","Collapse","Panel","defaultDarfBolsa","alienacoesComum","alienacoesDT","alienacoesFII","buffer","impostoTotal","irrfComum","irrfDayTrade","irrfFII","irrfTotal","mercadoOpcoesDT","mercadoOutrosComum","mercadoOutrosDT","mercadoVistaComum","mercadoVistaDT","prejuizoComum","prejuizoDayTrade","prejuizoFII","CustoMedioModal","to","IRRFModalProps","getTaxes","setEditedAccumulatedTax","textAlign","FormItemsBolsa","avgBuyPriceGOV","mustUpdate","marketCorrect","lendingSide","FormItemsDoacoesHerancas","_id","dateView","DateFormItem2","PrejuFormItems","CorretagemFormItems","IrrfFormItem","userIrrfTotal","IrrfFormItemRows","CorretagemFormItemRows","DarfBolsaFormItemRows","DarfBolsaTabs","class","tabs","varTotaisComum","varTotaisDT","varTotaisFII","ganhoComum","ganhoDT","ganhoFII","handleEditPreju","userPrejuizoComum","userPrejuizoDayTrade","userPrejuizoFII","negativeToPositive","signal","LucroPrejuizo","cotacao","HidenValue","currency","PosicaoHeader","flexGrow","lucroPrejuizoTotal","lucroPrejuizoDiario","precoAtual","lucroPrejuizoTotalPercentual","lucroPrejuizoDiarioPercentual","PosicaoBody","setHelpModal","details","loan","typeLoan","custoMedio","marketCap","beta","peRatio","earningDate","dividendYield","targetPrice","enterpriseValueRevenue","enterpriseValueEbitda","chart","AreaChart","right","bottom","x1","y1","x2","y2","offset","stopColor","stopOpacity","tickCount","tickFormatter","v","orientation","CartesianGrid","strokeDasharray","Area","stroke","fillOpacity","PosicaoCard","header","ExpandIcon","Months","0","1","2","3","4","5","6","7","8","9","10","11","Carteira","helpModal","chartType","setChartType","classesAtivosChart","setClassesAtivosChart","corretorasAtivosChart","setCorretorasAtivosChart","ativosChart","setAtivosChart","vendasBolsa","setVendasBolsa","setCorretoras","corretorasSemFiltro","setCorretorasSemFiltro","vendasExterior","setVendasExterior","checkboxCorretoras","setCheckboxCorretoras","selectedCorretoras","setSelectedCorretoras","reportDrawerWallet","setReportDrawerWallet","vendasRestantesBolsa","setVendasRestantesBolsa","filterCorretoraAtivo","setFilterCorretoraAtivo","vendasRestantesExterior","setVendasRestantesExterior","showCorretoraFilterModal","setShowCorretoraFilterModal","activeKeys","setActiveKeys","setDetailedActiveKeys","detailedLoadingIndex","setDetailedLoadingIndex","detailedPositions","setDetailedPositions","checkAll","indeterminate","largeChart","carteiraCategorizada","posicoesSemFiltro","carteiraCategorizadaFiltered","patrimonioTotalFiltrado","retornoFiltrado","lucroPrejuizoDiarioPercentualNumerator","resumo","lucroPrejuizoDiarioPercentualDenominator","lucroPrejuizoTotalPercentualNumerator","lucroPrejuizoTotalPercentualDenominator","onChangeActiveKeys","isOpenEvent","lastOpened","replaceAll","detailedActiveKeys","exterior","positions","isentas","apiExterior","vendasTotaisExt","itemPatrimonio","corretoraFilter","posicoesFiltradas","corretoraNames","patrimonio","classesAtivos","serializePatrimonio","downloadAction","queryCorretoras","JSON","stringify","renderIsentCard","vendas","restante","tipVendas","complete","borderBottomRightRadius","borderTopRightRadius","xs","sm","PieChart","Pie","cx","cy","innerRadius","outerRadius","labelLine","legendType","midAngle","percent","RADIAN","PI","radius","x","cos","sin","colors","textAnchor","dominantBaseline","Cell","Intl","NumberFormat","numberToCurrency","Option","expandIconPosition","defaultActiveKey","expandIcon","activeKey","collapsible","Array","from","utc","local","bodyStyle","paddingTop","mode","allowClear","NotificationContainer","NotificationDrawer","loadingIndex","setLoadingIndex","lidas","viewed","naoLidas","removeNotification","notifications","viewedDate","notificationImage","toLocaleDateString","AvisosContainer","getContainer","closable","B3Link","CopyLink","button","Instructions","b3Link","IntegrationModal","integrationModal","setIntegrationModal","b3IntegrationExample","warrenIntegrationExample","clipboard","writeText","Avisos","dismissBolsa","setDismissBolsa","dismissExterior","setDismissExterior","getCloseBanner","closeBannerBolsaXp","closeBannerExteriorXp","handleDismissBolsa","put","handleDismissExterior","spinning","isIntegratedBolsa","isIntegratedExterior","Wallet","notificationDrawerOpen","setNotificationDrawerOpen","setHideValues","showZero","erroB3","TabPane","tab","KEY_PASS","MeuPlano","getUserInfo","cancelModal","showCancelModal","pendingCancel","signature","useDate","changeCardModal","showChangeCardModal","formKey","keyPass","setKeyPass","planBasicInfo","isVelopro","setVelopro","hasCreditCardInfo","setCreditCardInfo","isPlanVelopro","currentPlan","VELOTAX_MAIN_BASIC","VELOTAX_MAIN_BASIC_MONTH","VELOTAX_MAIN_PRO_MONTH","VELOTAX_MAIN_CONCIERGE","VELOTAX_MAIN_CONCIERGE_MONTH","WARREN_BASIC","WARREN_BASIC_MONTH","WARREN_PRO","WARREN_PRO_MONTH","WARREN_CONCIERGE","WARREN_CONCIERGE_MONTH","showChangeCardButton","paymentForm","fromAccountant","getData","planStatus","contentStyle","alignItems","borderRadius","next_billing_at","start_at","dueDate","pix","credit_card","card","lastFourDigits","hideDarfDownload","closeModal","changeCardAction","onSuccessGeneral","planCurrent","hidePixButton","blockListCard","paymentData","isPlan","callDarf","customInstallments","cancelText","okText","userId","event","MaskBirth","MaskPhone","MinhaConta","setUser","signOut","warningDeleteModal","showWarningDeleteModal","modalParametrizacaoOpen","setModalParametrizacaoOpen","isMesa","setIsMesa","birthdate","cellphone","getMesaOperacoes","pass","currentPass","config","endIcon","CheckOutlined","CompaniesExemptList","italic","Regulation","showListModal","setShowListModal","handleListModal","accordion","Link","FormModal","add","rows","visibility","itemToEdit","disableButtons","preFormChildren","hideFooter","setUpdate","update","changedValues","inputs","flat","taxaCambio","dataEntries","entries","setFields","row","getFieldsValue","hide","array","alignSelf","integrationDate","apiUrl","marginLeft","DatePickerExtraFooter","DeleteConfirmationModal","updateData","setVisibility","buttonLabel","showToast","successMessage","finish","DatePickerMonthCell","yearResume","list","Darf","darf","viewEdit","userPlanModal","state","queryYear","queryMonth","initialMonth","initialYear","currentDate","history","replaceState","setAsset","emitting","setEmitting","darfModal","setDarfModal","paymentModal","setPaymentModal","setPaymentData","setYear","showAssetModal","setShowAssetModal","showDeleteModal","setShowDeleteModal","setYearResume","gettingYearResume","setGettingYearResume","datePickerYear","setDatePickerYear","notAuthorized","setNotAuthorized","setShowNotAuthorizedModal","loadingDarfButton","setLoadingDarfButton","transactionFeature","features","taxFeature","yearResumeFeature","emitted","monthResume","resume","PAYED","NOT_PAYED","getDarf","getYearResume","force","findIndex","handleDarf","justSave","onCloseDarfModal","paymentInfo","clientInfo","insertPix","darfUrl","onChangeMonth","parseInt","unsetAsset","handleCloseDeleteModal","handleCloseAssetModal","handleOpenPaymentModal","handlePlanModal","handleSaveMonth","hasExteriorCalcActive","permissions","handleEventDarfButton","handleLabelButton","handleNavigateToHistoric","settings","historicUrl","dataToPayment","direction","newYear","picker","inputReadOnly","suffixIcon","locale","onSelect","onPanelChange","renderExtraFooter","disabledDate","monthCellRender","fullPath","record","bordered","column","description","ghost","stopPropagation","PlusOutlined","itemLayout","renderItem","actions","handleRemove","Meta","ativoTranslated","marginRight","regular","fromDarf","disablePixOption","disableCreditCardOption","maxPixValue","maxCCValue","selectedYear","CardContainer","Card","ButtonBase","disableTouchRipple","itensBolsa","premium","ContainerRendimentosCell","YearReport","RendimentoFormItems","impostoPagoExterior","tipo","impostoPagoExteriorUsd","valorRendimentoUsd","valorRendimento","cpfPagador","cpfBeneficiario","ExteriorValueProps","RendimentoFormItemRows","ImpostoTotalRendimentosAutonomos","impostoPrincipal","gastosExterior","monthStock","setImpostos","setId","getRendimentos","handleEditValueConfirm","userCode","totalRendimentos","baseTributaria","totalDependentes","totalDespesas","totalPrevidencia","totalPensao","totalDeducoes","ImpostoTotalRendimentos","RendimentosImpostosDevidos","ModalAutonomos","ModalDependentes","ModalPensao","ModalPrevidencia","itensCrypto","PageInfo","subtitle","Plan","buyed","f","desc","Footer","currentStep","setCurrentStep","handleProceed","typePurchase","backtoRoot","hideTerms","selectedCardId","md","step","CardContent","NewCardContent","Row","taxes","getInstallments","fixedInstallments","_installments","valorTaxa","_valueTmp","_value","plural","ETypePurchase","CardList","onSelectCard","onChangeInstallments","installmentSelected","cardList","setCardList","SelectInput","installments","getInstallmentsByPrice","textTransform","preview","cvc","holder_name","expiry","exp_month","exp_year","first_six_digits","last_four_digits","valid","callback","issuer","isValid","CreditCardNumber","CreditCardNumberDiner","CreditCardNumberAmex","ExpiryInput","PhoneInput","CPFInput","CVVAmexInput","CVVInput","CardForm","setCvc","setName","setPhone","setNumber","setExpiry","setFocused","setHolderDocument","setIsValidCardForm","uniqueValue","handleBack","addInfo","cardType","getInstallmentsListByPrice","cvv","holderName","validateFields","onPaste","setAttribute","clipboardData","getAttribute","removeAttribute","method","AddressForm","setIsValidAddressForm","CEPInput","onValueChange","street","logradouro","neighborhood","bairro","city","localidade","uf","getAddressSuggestion","inputProps","ErrorScreen","cb","ConfirmedScreen","hideLoading","ResultScreen","PendingScreen","MEIAtividadePrincipalEnum","CreditCardStep","handleClosableModal","darfData","handleSuccess","handleIdBack","backToRoot","cupom","closeMainModal","cardForm","addressForm","setStatus","focused","holderDocument","setInstallments","selectedCard","setSelectedCard","isValidCardForm","isValidAddressForm","getCardInfo","addressInfo","monthExp","monthYear","cardInfo","cardId","card_id","line_1","zip_code","getCustomerInfo","customerInfo","customer_id","changeCardService","getConditionToDisable","changeInstallments","aceitouCGV","naoPossuiPendencia","country","createMeiPayment","createUniquePayment","cupomCode","paymentId","paymentRecurringId","createPlanMainVelotax","PlanModal","modalPlans","plans","setPlan","setClosable","handleDeselectPlan","initialized","MEI","setInitialized","getCardCurrentStep","handleSelectPlan","ConfirmModal","StyledTag","Tag","MeiReportDasStatusEnum","MeiReportStatusTextEnum","MeiDasStatusTextEnum","MeiDasStatusColorEnum","MEIAtividadePrincipalValue","61.6","COMERCIO_INDUSTRIA","65.6","SERVICO","validateIdentification","companyCode","mainActivity","identificationQuestions","formItems","FormItem","tabIndex","onKeyDown","ExteriorOperationType","DasHelpModal","TitleContainer","ExteriorModalContainer","InterestModal","rendimentoAplicacao","BackButton","ExteriorModalContent","TRADE","DEPOSIT","WITHDRAW","cambioReferencia","ganho2","DarfExterior","openPrejuizoModal","setOpenPrejuizoModal","gainKeys","sellPriceKeys","buyPriceKeys","feeKeys","getByKey","isOldModel","k","getBuyPrice","getGain","getSellPrice","getFee","useDarfExterior","oldModel","currentDarfDate","dateAllowedOnBasic","hideOnBasic","setQuotations","showNotAuthorizedModal","memoriaCalculoFiltered","atualizouImpostoAcumulado","getQuotations","cotacoes","pojo","dataHoraCotacao","dataToEdit","hasntPlan","cupomDueDate","calcReturn","qtt","irrfExterior","isExceedTax","additionalTax","verifyFromApi","saldoBRA","emptyText","dataToCreate","dataFeeToCreate","closeDarfModal","CardXP","PayButton","isReport","itensExterior","showToBasic","basic","PayDarfButtonContainer","check","PayDarfButton","checkedChildren","unCheckedChildren","instanceMsCalc","Authorization","VelotaxCalculatorsSelect","SelectBoxes","saveModules","setValues","isArray","handleSetValue","moduleName","deleted","vl","CalculatorsSelect","BolsaOperations","OldTransactionsContext","OldTransactionsProvider","setChanged","loadingGet","setLoadingGet","loadingPut","setLoadingPut","oldPositionEdit","setOldPositionEdit","doacaoHerancaEdit","setDoacaoHerancaEdit","oldPositionList","setOldPositionList","doacoesHerancas","setDoacoesHerancas","showAddPositionModal","setShowAddPositionModal","saveOldPositions","saveDoacoesHerancas","newOrders","or","downloadOldTransactionsExcel","responseType","downloadDoacoesHerancasExcel","getOldTransactionsInit","setShowModalPrePreenchida","getDoacoesHerancasInit","addOldPosition","listOldPosition","newPostion","institution","v4","addDoacaoHeranca","addItem","newDate","retExisting","totalValue","totalFeeNota","expirationDate","operationType","newOperation","createdAt","updatedAt","editOldPosition","editItem","listOldPositions","editDoacaoHeranca","handleEditOldPosition","handleRemoveOldPosition","handleRemoveDoacaoHeranca","itemParam","handleEditDoacaoHeranca","useOldTransactions","handleDownloadSheet","Uint8Array","blob","Blob","FileSaver","saveAs","ModalZeroBuyPrice","dataZeroBuyPrice","setModalZeroBuyPrice","setIgnoreZeroBuyPrice","whiteSpace","wordWrap","DarfBolsa","darfBolsaRef","hasPremiumPlan","hasItems","sethasItems","dataToEditPreju","setDataToEditPreju","setBuffer","editedAccumulatedTax","showEditPrejuConfirmation","setShowEditPrejuConfirmation","useImperativeHandle","thirdBusinessDayAndMonth","disableCurrentMonth","isoWeekday","firstDayOfMonth","businessDaysCount","isBefore","isAntesTerceiroDiaUtil","hideOldPositionsText","prejuizoFeature","irrfFeature","nAtualizarDarfsPassadas","nAtualizarIrrf","nAtualizarPrejuizosAcumulados","atualizarTotalmente","atualizouCorretagem","memoCalc","originalDate","setTab","bolsaOperationsRef","handleNext","scrollBy","clientWidth","handlePrev","resetedPreju","setResetedPreju","showPrejuModal","setShowPrejuModal","showCorretagemModal","setShowCorretagemModal","loadingResetPreju","loadingEditPreju","setLoadingEditPreju","ignoreZeroBuyPrice","setDataZeroBuyPrice","modalZeroBuyPrice","preju","custoCorretagem","userCustoCorretagemComum","userCustoCorretagemDT","userCustoCorretagemFII","handleClosePrejuModal","handleCloseCorretagemModal","showIrrfModal","setShowIrrfModal","irrf","handleEditIrrf","handleCloseIrrfModal","hasZeroBuyPrice","handleEditCorretagem","container","rowIndex","colIndex","paddingRight","QuestionCircleOutlined","avgSellPrice","handleEditPrejuData","removeAsset","cards","ReportContainer","ReportAlertTitle","columnGap","lineHeight","OldTransactions","hasLandingSide","hasLendingPosition","setHasLendingPosition","downloading","setDownloading","URL","createObjectURL","appendChild","remove","flex","justifySelf","DownloadOutlined","PlusCircleOutlined","oldPosition","questions","subTitle","BolsaManualContainer","UploadVelotax","descText","customText","UploadDecContext","UploadDecProvider","loadingSkip","confirmarModal","setConfirmarModal","beforeUpload","nameSplitted","isDec","customRequest","formData","FormData","append","apiIrpf2023","processamantoDec2019","reponse","useUploadDec","DecUploadContent","GovBrIcon","DecPrepreenchidaContent","Step","PrePreenchidaModal","showModal","setShowModal","forceRender","showArrow","accept","QuestionContainer","Question","BottomAdvice","AttentionIconContainer","TransferenciaCustodiaContext","TransferenciaCustodiaProvider","pathname","setAtivo","ativos","setAtivos","indexAtivo","setIndexAtivo","redirected","setRedirected","showFormModal","setShowFormModal","isInvalidItem","valorCompraUSDOrigemBRA","valorCompraUSDOrigemEUA","handleLoading","closeFormModal","closeDeleteModal","getAtivos","useTransferenciaCustodia","handleAdd","saveAtivos","isValidFile","useNotasCorretagem","sameNameFiles","loadingSend","setLoadingSend","setNotas","showNotasCorretagemModal","setShowNotasCorretagemModal","sendNotas","originFileObj","sendNotasCustodyTransfer","uploadProps","fileList","multiple","listType","onRemove","uid","files","sameNameFile","Upload","LIST_IGNORE","showUploadList","showRemoveIcon","showPreviewIcon","showDownloadIcon","dayFilters","yearFilters","NotasHistoricoModal","rowKey","simple","filterReset","filterIcon","ModalStyled","sendEmailSheet","dateInfo","dolarQuote","DividendosModal","ticker","referenceDate","monthList","monthName","handleValue","variable","handleValueBolsa","handleItem","imgHeight","IntegrationButton","logo","integrado","isB3LinkRedirect","handleClick","setIntegrationModalVisible","isB3","CheckCircleTwoTone","twoToneColor","B3IntegrationButtons","showIntegrationButton","b3Logo","NotasCorretagem","xtageIntegration","getXtageIntegrationStatus","CalcAutonomosDarfItem","sidebar","component","object","setObject","checkType","getTotal","auxTotal","totalRendimento","totalRendimentoReal","totalImposto","totalImpostoReal","valorRendimentoReal","impostoPagoExteriorReal","groupBycode","aux","FlexDiv","AutonomosDarf","yearView","monthView","isSaveItens","itemIndex","setItemIndex","setMonthStock","showRendimentoModal","setShowRendimentoModal","setItem","impostos","valorImpostoTotal","generateDarf","handleOpenDarfModal","ActionButtons","handleRegularize","buildCalcTaxBody","numeroDependentes","gastosAutonomos","gastosPrevidencia","gastosPensao","calcTaxes","deducoes","rendimentos","currentValue","setPayData","valueToCharge","valueCharge","currentImpostos","getRendimento","buildNewImpostos","saveItems","newImpostos","pixValue","MsDarf","handleCloseItemModal","unsetItem","changeInputState","auxValue","warn","notEditable","controls","onBlur","PassfolioIntegrationModal","setVisible","integrationData","secret","integrationParams","setParams","onReset","authenticatorId","PassfolioIntegration","dependentId","integrationCallback","integrationModalVisible","setIntegrado","setIntegrationData","getEstadoIntegracao","providerExists","WarrenLogo","ExteriorIntegration","TransferenciaCustodiaFormItems","yearLimit","monthLimit","dayLimit","checkDateLimit","DoacoesHerancas","setOrders","ordersLocal","Pages","Bolsa","infoModal","toggleModal","reportCount","setReportCount","reportIsReady","setReportIsReady","userPlanInfoStatus","handleAnualReport","concierge","reportCountInterval","itvl","isProcessing","reportFinishCountInterval","checkProcessorAction","Crypto","MeiDas","showHelpModal","setShowHelpModal","showPlanModal","setShowPlanModal","yearOptions","dasMonths","getDasList","responseItem","pay","das","checkIfPayed","inssBeneficiary","handleModal","handleEmit","handleHelpModal","CheckCircleOutlined","CloseCircleOutlined","inssAction","issueDate","requestDate","keyboard","Exterior","hasPermissionExteriorPlanos","reportLoading","setReportLoading","setReportDisabled","hasYearlyReportsCalcActive","blockHandle","notified","errorDates","Historic","setHolidays","itemToPay","setItemToPay","showErrorCard","setShowErrorCard","setErrorDates","showCalcModal","setShowCalcModal","isBasic","historicFeature","payFeature","downloadFeature","isCripto","isExterior","backend","getDowloadLinks","dataLinks","allSettled","getHistoric","payAction","editAction","noPlanMode","calc","handleOpenPlanModal","handlePayButton","obj","handleCloseCalcModal","darfId","exteriorTransactionsFilterCalc","handleFinalValue","ImpostoAPagarNoPlan","ErrorCard","ImpostoAPagarWithPlan","getHolidays","dataFormated","defineMovement","ultimoDiaUtilDoMes","vencimento","checkMonth","ed","minHeight","showNavigateToIntegrationButton","integrationUrl","Settings","MeiReport","contentElement","loadingReports","setLoadingReports","reports","setReports","getReports","requiredMark","annualInvoicing","EMITTED","hasEmployee","scrollIntoView","behavior","ReportBolsa","ssoToken","stateYear","action","setAction","loadingLinks","Action","ACTION","handleActionButton","show2024Report","localStorage","getItem","Integration","BolsaManual","currentQuestion","showAlertModal","setShowAlertModal","showModalPrePreenchida","handleAlertModalVisibility","handleSubmit","overflow","question","DoacoesHeranca","Rendimentos","itemprops","Dependentes","Autonomos","Previdencia","Pensao","apiRendimentos","goToHistoric","currentArray","DollarCircleOutlined","PENDING","AnnualReport","fileLink","HistoricBolsa","integrouHoje","handleOpenNotas","backgroundIntegration","lastUpdateDate","backgroundIntegrationDisabled","wordSpacing","letterSpacing","onClickCard","isIntegration","isManual","hasPlanUpgraded","integrationPath","textDecoration","ReportExterior","setInitialYear","loadingError","setLoadingError","reportDisabled","transactionsFeature","darfFeature","downloadDarf","noSendMail","Identification","handleProviderExists","saving","setSaving","isEditing","setIsEditing","setCurrentQuestion","handleNav","formItem","newValue","realValue","offsetTop","scrollTo","addEventListener","removeEventListener","DividendosBolsa","setIndex","backendBolsa","isBolsa","DividendosTabs","IntegrationBolsa","cameFromRegister","setCameFromRegister","bolsa","IntegrationCrypto","DividendosExterior","showModalAutonomos","setShowModalAutonomos","setQuotes","sortedData","totalData","acumulatorImpostoPagoExterior","acumulatorValorRendimento","orderObj","backendExterior","newData","IntegrationExterior","TransferenciaCustodia","at","orderId","IntegrationExteriorXP","setIntegrated","isIntegrated","XP_logo","PlanosContainer","LogoContainer","gradientUnits","SvgSeloPlayStore","SvgSeloAppStore","UserPlanUpgradeEnum","planos","for","benefits","popular","planUpgrade","BASIC_TO_PRO","BASIC_TO_CONCIERGE","PRO_TO_CONCIERGE","getPlanPrice","fillRule","clipRule","SvgSelo7Dias","SvgSeloGarantia","getStatus","StatusCSSClassEnum","StatusTextEnum","Planos","selectedPlan","setSelectedPlan","setPlanUpgrade","checkWasPaid","delay","attempts","isAd","actionTypeText","isUpgrade","benefit","onSucessPix","onSucessCreditCard","stopIntervalPix","Field","Typography","Value","PermissaoAssessorModal","dataContent","changePermission","useRequireAccess","handleCancel","escritorio","assessor","RequireAccessContext","RequireAccessProvider","escritorioLiberados","setEscritorioLiberados","assessoresLiberados","setAssessoresLiberados","solicitantesAcesso","setSolicitantesAcesso","solicitacaoModal","s","checkPermissionUser","assessorId","listRequiredAccess","solicitantes","authorize","preventNotification","ManagerAccess","officeName","TabFormItem","tabBarExtraContent","SalarioText","listStyle","EducacaoText","AnualMensalText","HelpModalTexts","rendaBrutaMensal","gastoMensalSaude","gastoMensalEducacao","possuiDependentes","pagaPensaoAlimenticia","rendaAnualMensal","saudeAnualMensal","educacaoAnualMensal","pensaoAnualMensal","pgblQuestions","hideQuestionNumber","rendaBrutaMensalMode","possuiGastoMensalSaudeDependente","gastoMensalSaudeDependenteMode","possuiGastoMensalEducacaoDependente","gastoMensalEducacaoDependenteMode","gastoPensaoAlimenticiaMode","PGBLSimulator","setResume","editting","setEditting","autorizacao","setAutorizacao","backupValues","setBackupValues","setQuestions","getResume","resumoSimulacao","possuiGastoMensalSaude","possuiGastoMensalEducacao","quantidadeDependente","gastoMensalSaudeDependente","gastoMensalEducacaoDependente","formValidate","formNavigate","gastoMensalSaudeMode","gastoMensalEducacaoMode","gastoPensaoAlimenticia","backupKeys","pre","changedKeys","updateKeys","o","completa","valorRestituicao","simplificada","ForgotPassword","ChangePassword","SvgBolsa","SvgExterior","EPlanStep","brokers","dns","useSSO","usePGBL","useSettings","hideCalculadoras","hideJuridicMessage","primary","secondary","sidebarSelectedColor","sidebarSelectedColorDark","html","favicon","iconAlternative","iconStyle","iconAlternativeStyle","hidePoweredBy","defaultPath","defaultProviderExistsPath","pages","calcId","integratedOnly","showOnSidebar","subPages","darfComponent","LoadingSession","NameNotification","loadingIntegrationStatus","loadingSession","updateUserInfo","showNameModal","setShowNameModal","showed","setShowed","defaultIntegration","BrokerContext","BrokerProvider","hostname","setPathBackup","setInitIntegration","setIntegration","setXtageIntegration","integrations","setIntegrations","setLoadingIntegrationStatus","brokerList","broker","dnsBroker","isAfter","sidebarPages","page","pathnameWindowArray","pathnameWindow","abledPages","publicRoutes","privateRoutes","brokerRoutes","Element","privatePaths","publicPaths","abledPagesPaths","getElementsByTagName","innerHTML","rendimentosBackend","pixTaxesByInsitution","PixPaymentStep","onSucess","backStep","brCode","setBrCode","qrCodeLink","setQRCodeLink","qrCodeLinkUrl","setQRCodeLinkUrl","serviceTax","callUserPlanPayment","callDarfPix","qrCode","br_code","payment","plano","totalPrice","flexDirection","wordBreak","maxWidth","CardButton","blockMultipleReq","debounce","PaymentModal","setCupom","installment","setInstallment","loadingPayment","setLoadingPayment","loadingCards","setLoadingCards","CHOOSE_PAYMENT","setStep","check_id","FINISHED","changePaymentId","LOADING","purchaseType","UNIQUE","plansContentDisplay","CC_PAYMENT","PIX_PAYMENT","cancelActions","UserPlanModal","tabPlanActive","textCupomErr","setTextCupomErr","setButtonLoading","setShowInputCupom","MinusOutlined","onKeyPress","clearTimeout","AuthContext","AuthProvider","decUrl","setDecUrl","chatOpen","setChatOpen","showDrawer","setShowDrawer","showDbkModal","setShowDbkModal","wasMessageSent","setWasMessageSent","showPhoneModal","setShowPhoneModal","showIndicarModal","setShowIndicarModal","chatNotificationQtt","setChatNotificationQtt","userPlanModalTitle","forceUpdateTabNavigator","setForceUpdateTabNavigator","planInfo","planInfoToHasPlan","handleCalcs","calcs","navigateTo","visibleCalcs","getUserInformation","backnedRendimentos","msDarf","isBlocked","userFromApi","cpfProtegido","profileId","dependents","visibleModules","modulesStatus","answeredStepDec","showContratarMalhaFina","cellphoneFilled","showAccountantPremiumButton","showContratarContador","isAccountant","apiBolsaVelotax","parse","updateUserDec","updatedUser","removeItem","reload","interceptors","use","mostrouRecomendacao","authAccountantSSOCnpj","signUpData","onboardingData","hiringData","policiesAccepted","modules","goods","incomeTypes","operationTypes","set","irpfBannerActive","setSsoToken","signed","sslSecure","PrivateRoute","OnlyPublicRoute","SvgVeloicon","PageNotFound","extra","LayoutHeader","Layout","Header","HistoryContext","HistoryProvider","setHistory","handleBackHistory","last","flexWrap","LogoStyled","Logo","VelotaxLogo","PoweredByVelotax","VelotaxLogoWhite","SvgSair","SvgConta","ContentButton","DrawerSider","Drawer","LayoutSider","Sider","Modules","Menu","Module","sidebarselectedcolor","SupportContainerIcon","SideBarContainer","theme","Sidebar","pagePath","openKeys","setOpenKeys","handleNavigate","focus","cripto","subPage","loginInSupport","urlSupportSSO","selectedKeys","poweredBy","AntLayout","nav","SvgBolsaDeValores","SvgAtivosNoExterior","TabNavigator","setActiveKey","menuItems","matchItem","disabledOverflow","IRPFBannerContainer","IRPFBanner","setShow","PageWrapper","sideBar","scrollRef","useScroll","showIrpfBanner","setShowIrpfBanner","REACT_APP_SHOW_B3_BANNER","HeaderContainer","PublicWrapper","Routes","lastPath","setLastPath","ConfigProvider","primaryColor","infoColor","successColor","route","createGlobalStyle","chatApi","ChatButton","ChatWindow","KEY","KEY_TIMESTAMP","defaultMsg","ChatGPT","storage","chatBodyRef","textareaRef","msg","setMsg","scrolled","setScrolled","firstLoading","setFirstLoading","msgs","setMsgs","scrollToBottom","scrollHeight","after24H","timestamp","loadMsgs","threadId","userMessage","formattedGptAnswer","DOMPurify","sanitize","botResponse","sendMsg","dangerouslySetInnerHTML","__html","textarea","ContextWrapper","FallbackUI","ErrorBoundaryRollbar","ErrorBoundary","fallbackUI","SupportButton","Support","setLoadingLogin","App","createTheme","palette","main","ThemeProvider","ptBR","renderEmpty","reportWebVitals","onPerfEntry","Function","getCLS","getFID","getFCP","getLCP","getTTFB","ReactDOM","StrictMode"],"mappings":"8UASeA,EAPHC,IAAMC,OAAO,CACvBC,QAASC,iCACTC,QAAS,CACP,iBAAkB,YCHhBC,EAAOL,IAAMC,OAAO,CACxBC,QAASC,8CAGEG,EAAiB,iB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B,cAAC,GAAoB,UACnB,cAAC,IAAc,CACb1sC,OAAQmyC,IACRC,YAAa,iBAAM,0BAAyB,SAE5C,cAAC,IAAM,UACL,eAAC,GAAc,WACb,cAAC,GAAM,IACP,cAAC,GAAY,IACb,cAAC,GAAY,IACb,cAAC,GAAe,IAChB,cAAC,GAAiB,IAClB,cAAC,GAAkB,IACnB,cAAC,GAAO,IACR,cAAC,GAAO,gBC7CPC,GAZS,SAACC,GACnBA,GAAeA,aAAuBC,UACxC,+BAAqBz+E,MAAK,YAAkD,IAA/C0+E,EAAM,EAANA,OAAQC,EAAM,EAANA,OAAQC,EAAM,EAANA,OAAQC,EAAM,EAANA,OAAQC,EAAO,EAAPA,QAC3DJ,EAAOF,GACPG,EAAOH,GACPI,EAAOJ,GACPK,EAAOL,GACPM,EAAQN,O,QCTC,ICAA,ICAA,I,gBCWfO,IAASl3D,OACP,cAAC,IAAMm3D,WAAU,UACf,cAAC,GAAG,MAEN/mF,SAAS2J,eAAe,SAM1B28E,O","file":"static/js/main.7bc3280a.chunk.js","sourcesContent":["import axios from \"axios\";\n\nconst api = axios.create({\n baseURL: process.env.REACT_APP_IRPF_URL || \"http://localhost:3333\",\n headers: {\n \"x-api-provider\": \"WARREN\",\n },\n});\n\nexport default api;\n","import axios from \"axios\";\n\nconst apis = axios.create({\n baseURL: process.env.REACT_APP_URL || \"http://localhost:8888\",\n});\n\nexport const NOT_AUTHORIZED = \"not authorized\";\n\nexport default apis;\n","export const states = [\n \"AC\",\n \"AL\",\n \"AP\",\n \"AM\",\n \"BA\",\n \"CE\",\n \"DF\",\n \"ES\",\n \"GO\",\n \"MA\",\n \"MT\",\n \"MS\",\n \"MG\",\n \"PA\",\n \"PB\",\n \"PR\",\n \"PE\",\n \"PI\",\n \"RR\",\n \"RO\",\n \"RJ\",\n \"RN\",\n \"RS\",\n \"SC\",\n \"SP\",\n \"SE\",\n \"TO\",\n];\n","import * as yup from \"yup\";\nimport \"yup-phone\";\nimport moment from \"moment\";\nimport Payment from \"payment\";\nimport { validateBr } from \"js-brasil\";\nimport { states } from \"../constants/others/states\";\n\nexport const isValidCPF = (cpf: string) => validateBr.cpf(cpf || \"\");\n\nexport const isValidCNPJ = (cnpj: string) => validateBr.cnpj(cnpj || \"\");\n\nexport const isValidRenavam = (renavam?: string) =>\n renavam && validateBr.renavam(renavam);\n\nexport const isValidFullName = (name: string) =>\n name.trim().split(\" \").length > 1;\n\nexport const isValidEmail = (email?: string) =>\n email && yup.string().email().isValidSync(email);\n\nexport const isValidPhone = (phone?: string) =>\n phone &&\n yup.string().phone(\"BR\").isValidSync(phone) &&\n phone.replace(/[^0-9\\\\.]+/g, \"\").length === 11;\n\nexport const isValidDate = (date?: string) =>\n date &&\n /^((0?[1-9]|[12][0-9]|3[01])[/](0?[1-9]|1[012])[/](19|20)[0-9]{2})*$/.test(\n date\n );\n\nexport const isDateOnReferenceMonth = (\n month: number,\n year: number,\n date?: string\n) => {\n if (date && isValidDate(date)) {\n try {\n const momentDate = moment(date, \"DD/MM/YYYY\");\n const start = moment(`${year}-${month + 1}`, \"YYYY-M\", true).startOf(\"M\");\n const end = moment(`${year}-${month + 1}`, \"YYYY-M\", true).endOf(\"M\");\n return moment(momentDate).isBetween(start, end, undefined, \"[]\");\n } catch (err) {\n return false;\n }\n }\n return false;\n};\n\nexport const isNonDateOnFuture = (\n month: number,\n year: number,\n date?: string\n) => {\n if (date && isValidDate(date)) {\n try {\n const momentDate = moment(date, \"DD/MM/YYYY\");\n const end = moment(`${year}-${month + 1}`, \"YYYY-M\", true).endOf(\"M\");\n return moment(momentDate).isSameOrBefore(end);\n } catch (err) {\n return false;\n }\n }\n return false;\n};\n\nexport const isValidVoterCard = (voterCard?: string) =>\n voterCard && voterCard.replace(/[._]/g, \"\").length === 12;\n\nexport const isValidCEP = (cep?: string) => cep && validateBr.cep(cep);\n\nexport const checkDateExpiration = (limit: string, value: string) => {\n const [day, month, year] = value.split(\"/\");\n const date = new Date(\n Number(year),\n Number(month) - 1,\n Number(day),\n 23,\n 59,\n 59\n );\n return date <= new Date(limit);\n};\n\nexport const checkDateLimit = (limit: string, value: string) => {\n const [day, month, year] = value.split(\"/\");\n const [yearLimit, monthLimit, dayLimit] = limit.split(\"-\");\n const date = new Date(Number(year), Number(month) - 1, Number(day), 0, 0, 0);\n const dateLimit = new Date(\n Number(yearLimit),\n Number(monthLimit) - 1,\n Number(dayLimit),\n 0,\n 0,\n 0\n );\n return date > dateLimit;\n};\n\nexport const isValidIPTU = (value?: string) =>\n !value ||\n String(value || \"\").length === 0 ||\n (String(value || \"\").length >= 8 && String(value || \"\").length <= 30);\n\nexport const isValidDeclarationReceipt = (value: string) =>\n !value || value.length === 10 || value.length === 12;\n\nexport const removeSpecialCharacters = (value: string) => {\n if (!value) return \"\";\n return value?.normalize(\"NFD\").replace(/[^a-zA-Zs]/g, \"\");\n};\n\nexport const isValidStateAddress = (value: string) => {\n return states.includes(value.toUpperCase());\n};\n\nexport const isValidShelfLife = (value: string) => {\n let currentMonth: number | string | undefined = new Date().getMonth() + 1;\n let currentYear = (new Date().getFullYear() + \"\")?.substring(2);\n currentMonth = currentMonth < 10 ? `0${currentMonth}` : currentMonth;\n let monthYearTime = `${currentYear}${currentMonth}`;\n let valueTime = value?.split(\"/\").reverse().join().replace(\",\", \"\");\n return (\n !!value &&\n (valueTime < monthYearTime ||\n !/\\b(0[1-9]|1[0-2])\\/?([0-9]{4}|[0-9]{2})\\b/.test(value))\n );\n};\n\nexport const isValidCreditCard = (value: string) =>\n Payment.fns.validateCardNumber(value);\n","import moment from \"moment\";\nimport { Tooltip } from \"antd\";\nimport { BiErrorCircle } from \"react-icons/bi\";\nimport NumberFormat from \"react-number-format\";\n\nexport const removeLiNumbers = (t: string) => t.replace(/^([\\d]+\\.*)+/, \"\");\n\nexport const onlyNumbersToPhone = (value: string) =>\n value.replace(/[()_.%-/\\s/]/g, \"\");\n\nexport const formatCurrency = (value: number, prefix = \"R$ \") => {\n return (\n \n );\n};\n\nexport const numberToCurrency = (value: number) => {\n const formatter = new Intl.NumberFormat('pt-BR', {\n style: 'currency',\n currency: 'BRL',\n })\n\n return formatter.format(value)\n}\n\nexport const numberToPercentage = (value?: number, toFixed = 2) => {\n const number = typeof value === \"number\" ? value : 0;\n return `${Number(number * (number < 1 ? 100 : 1)).toLocaleString(\"pt-br\", {\n minimumFractionDigits: toFixed,\n maximumFractionDigits: toFixed,\n })}%`;\n};\n\nexport const numberToPercentageWallet = (value?: number, toFixed = 2) => {\n const number = typeof value === \"number\" ? value : 0;\n return `${Number(number * 100).toLocaleString(\"pt-br\", {\n minimumFractionDigits: toFixed,\n maximumFractionDigits: toFixed,\n })}%`;\n};\n\nexport const currencyToNumber = (value: string, prefix = \"R$\") =>\n Number(\n value\n ?.replace(prefix, \"\")\n .replace(/\\./g, \"\")\n .replace(/,/g, \".\")\n .replace(/\\s/g, \"\")\n ) || 0;\n\nexport const replaceDotByComma = (value: number) => {\n return String(value).replace(/\\./g, \",\");\n};\n\nexport const ErrorIcon = (\n \n \n \n);\n\nexport const zero = (n: number) => (n < 10 ? `0${n}` : `${n}`);\n\nexport const formatDate = (dateString: string) => {\n const date = new Date(dateString);\n const year = date.getFullYear();\n const day = zero(date.getDate());\n const month = zero(date.getMonth() + 1);\n return `${day}/${month}/${year}`;\n};\n\nexport const formatDateHour = (dateString: string) =>\n `${moment(dateString).format(\"DD/MM/YYYY\")} às ${moment(dateString).format(\n \"HH:mm\"\n )}`;\n","export const cpfInputMask = \"999.999.999-99\";\nexport const cnpjInputMask = \"99.999.999/9999-99\";\n\nexport const maskCpf = (cpf = \"\") => {\n if (!cpf) return \"\";\n if (cpf.includes(\".\")) return cpf;\n const cpfArray = cpf.split(\"\");\n cpfArray.splice(3, 0, \".\");\n cpfArray.splice(7, 0, \".\");\n cpfArray.splice(11, 0, \"-\");\n return cpfArray.join(\"\");\n};\n\nexport const maskNitPisPasep = (nitpispasep = \"\") => {\n if (!nitpispasep) return \"\";\n if (nitpispasep.includes(\".\")) return nitpispasep;\n const array = nitpispasep.split(\"\");\n array.splice(3, 0, \".\");\n array.splice(9, 0, \".\");\n array.splice(12, 0, \"-\");\n return array.join(\"\");\n};\n\nexport const maskCnpj = (cnpj = \"\") => {\n if (!cnpj) return \"\";\n if (cnpj.includes(\".\")) return cnpj;\n const cnpjArray = cnpj.split(\"\");\n cnpjArray.splice(2, 0, \".\");\n cnpjArray.splice(6, 0, \".\");\n cnpjArray.splice(10, 0, \"/\");\n cnpjArray.splice(15, 0, \"-\");\n return cnpjArray.join(\"\");\n};\n\nexport const maskCep = (cep = \"\") => {\n if (!cep) return \"\";\n if (cep.includes(\"-\")) return cep;\n const cepArray = cep.split(\"\");\n cepArray.splice(5, 0, \"-\");\n return cepArray.join(\"\");\n};\n\nexport const maskVoterCard = (voterCard = \"\") => {\n if (!voterCard) return \"\";\n const voterCardArray = voterCard.split(\"\");\n voterCardArray.splice(4, 0, \" \");\n voterCardArray.splice(9, 0, \" \");\n return voterCardArray.join(\"\");\n};\n\nexport const maskPhone = (phone = \"\") => {\n if (!phone) return \"\";\n const phoneArray = phone.split(\"\");\n if (phone.substring(0, 2) === \"55\") {\n phoneArray.splice(0, 0, \"+\");\n }\n if (phoneArray[0] === \"+\") {\n phoneArray.splice(3, 0, \" (\");\n phoneArray.splice(6, 0, \") \");\n phoneArray.splice(12, 0, \"-\");\n } else {\n phoneArray.splice(0, 0, \"(\");\n phoneArray.splice(3, 0, \") \");\n phoneArray.splice(9, 0, \"-\");\n }\n return phoneArray.join(\"\");\n};\n","import CalendarLocale from \"rc-picker/lib/locale/pt_BR\";\n\nexport const getInitialYear = (year: number, month: number) =>\n // year - (month === 0 ? 1 : 0);\n year;\n\nexport const months = [\n \"Jan\",\n \"Fev\",\n \"Mar\",\n \"Abr\",\n \"Mai\",\n \"Jun\",\n \"Jul\",\n \"Ago\",\n \"Set\",\n \"Out\",\n \"Nov\",\n \"Dez\",\n];\n\nexport const monthsExtended = [\n \"Janeiro\",\n \"Fevereiro\",\n \"Março\",\n \"Abril\",\n \"Maio\",\n \"Junho\",\n \"Julho\",\n \"Agosto\",\n \"Setembro\",\n \"Outubro\",\n \"Novembro\",\n \"Dezembro\",\n];\n\nexport const antDatePickerLocale = {\n lang: {\n placeholder: \"\",\n ...CalendarLocale,\n },\n timePickerLocale: {},\n};\n","import axios from \"axios\";\n\nconst api = axios.create({\n baseURL: process.env.REACT_APP_BOLSA_URL || \"http://localhost:8888\",\n headers: {\n \"x-api-provider\": \"warren\",\n },\n});\n\nexport default api;\n","import { UserPlanEnum } from \"../constants/plans\";\nimport apiBolsa from \"../services/apiBolsa\";\n\nexport const B3AuthURL =\n \"https://b3Investidor.b2clogin.com/b3Investidor.onmicrosoft.com/oauth2/v2.0/authorize?p=B2C_1A_FINTECH&client_id=069ecfdf-7471-48eb-be82-d50799c99e5c&nonce=defaultNonce&redirect_uri=https%3A%2F%2Fwww.investidor.b3.com.br&scope=openid&response_type=code&prompt=login\";\n\nexport const getQuizLabel = (username: string, message: string): string => {\n return username !== \"Declarante\"\n ? `${username} ${message}`\n : `Você ${message}`;\n};\n\nexport const isSafari = /^((?!chrome|android).)*safari/i.test(\n navigator.userAgent\n);\n\nconst iOSList = [\n \"iPad Simulator\",\n \"iPhone Simulator\",\n \"iPod Simulator\",\n \"iPad\",\n \"iPhone\",\n \"iPod\",\n];\n\nexport const isIOS = () =>\n iOSList.includes(navigator.platform) ||\n iOSList.includes((navigator as any).userAgentData?.platform) ||\n navigator.userAgent.includes(\"Mac\") ||\n (navigator.platform === \"MacIntel\" && navigator.maxTouchPoints > 1);\n\nexport const isIOSWebView = isIOS() && !isSafari;\n\n// export const isAndroidWebView = ?????\n\nexport const isMobile = (): boolean => {\n return /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(\n navigator.userAgent\n );\n};\n\nexport const isExternalLink = (link: string): boolean => {\n return /http:\\/\\/|https:\\/\\//i.test(link);\n};\n\nexport const errorMessage =\n \"Algo inesperado aconteceu! Tente novamente mais tarde.\";\n\nexport const tenteIntegrarNovamente = \"Tente integrar novamente.\";\n\nexport const reintegrateMessage =\n \"Faça novamente a integração para buscar dados mais novos\";\n\nexport const download = (link: string) => {\n window.location.href = link;\n};\n\nexport const downloadPDF = (base64: string, fileName?: string) => {\n const linkSource = `data:application/pdf;base64,${base64}`;\n const downloadLink = document.createElement(\"a\");\n fileName = fileName ?? `Relatório-${Date.now()}.pdf`;\n\n downloadLink.href = linkSource;\n downloadLink.download = fileName;\n downloadLink.click();\n};\n\nexport const getMuiInputCss = () =>\n document\n .querySelector(\"input.MuiInputBase-input\")\n ?.classList.value.split(\" \")\n .find((c) => c.includes(\"css\")) ?? \"\";\n\n\nexport const planInfoToHasPlan = (planInfo: any, hasPermissionGeneral: any) => \n (!!planInfo?.type && !!planInfo?.active) || !!hasPermissionGeneral\n ? {\n basic: !!planInfo?.type || !!hasPermissionGeneral,\n // premium: [\n // UserPlanEnum.XP_PRO,\n // UserPlanEnum.XP_PRO_MONTH,\n // UserPlanEnum.XP_CONCIERGE,\n // UserPlanEnum.VELOTAX_MAIN_PRO,\n // UserPlanEnum.VELOTAX_MAIN_PRO_MONTH,\n // UserPlanEnum.XP_CONCIERGE\n // ].includes(planInfo?.type) || !!hasPermissionGeneral,\n // concierge: [UserPlanEnum.XP_CONCIERGE, UserPlanEnum.VELOTAX_MAIN_CONCIERGE].includes(planInfo?.type),\n premium: planInfo?.type?.includes('PRO'),\n concierge: planInfo?.type?.includes('CONCIERGE'),\n }\n : false;\n\nexport const getZeroBuyPrice = async (data: any) => {\n let hasZero: any[] = [];\n const donations = await apiBolsa.get(\"/operation/donations?operationType=Credito\", {});\n const pos2019 = await apiBolsa.get(\"/operation?month=12&year=2019\", {});\n\n for (const element of data) {\n const code = element?.code;\n const isTaxa = (code.toLowerCase()).includes('taxa');\n if (isTaxa) continue;\n const market = element?.market;\n const buyPrice = element?.buyPrice;\n\n if (market.includes('opções') || market.includes('Opção')) continue;\n const reasonDictionary = [\n { text: \"Preencha o custo de compra do ativo na aba\", textLink: \"Doações e heranças\", link: \"/warren/bolsa-doacoes-heranca\" },\n { text: \"Preencha o custo de compra do ativo na aba\", textLink: \"Posição 31/12/2019\", link: \"/warren/bolsa-insert-manual\" }\n ];\n const hasDonations: any[] = [];\n donations?.data?.filter((op: any) => {\n op?.orders?.filter((ord: any) => {\n if (code === ord?.code) {\n hasDonations.push(ord);\n return;\n }\n else return;\n })\n })\n const hasPos2019: any[] = [];\n pos2019?.data?.filter((op: any) => {\n op?.orders?.filter((ord: any) => {\n if (code === ord?.code) {\n hasPos2019.push(ord);\n return;\n }\n else return;\n })\n })\n const reason = hasDonations.length ? 0 : (hasPos2019.length ? 1 : \"\");\n // Para quando o ativo não estiver zerado no mês, mas estiver zerado em doações e heranças\n if (hasDonations.length > 0 && hasDonations[0]?.price == 0) {\n hasZero.push({ code: code, reason: reason !== \"\" ? reasonDictionary[reason] : \"\" });\n }\n else if ((buyPrice == 0 || !buyPrice)\n && ((hasDonations.length > 0 && hasDonations[0]?.price == 0)\n || (hasPos2019.length > 0 && hasPos2019[0]?.price == 0))) {\n hasZero.push({ code: code, reason: reason !== \"\" ? reasonDictionary[reason] : \"\" });\n }\n else if ((buyPrice == 0 || !buyPrice) && hasDonations.length == 0 && hasPos2019.length == 0) {\n hasZero.push({ code: code, reason: \"\" });\n }\n }\n let elementsRepeat: string[] = [];\n hasZero = hasZero.filter((item) => {\n if (!elementsRepeat.includes(item.code)) {\n elementsRepeat.push(item.code);\n return item;\n }\n else return;\n });\n\n return hasZero;\n}","import moment from \"moment-timezone\";\n\n/* eslint-disable @typescript-eslint/no-var-requires */\nconst isBusinessDay = require(\"eh-dia-util\");\n// import ehDiaUtilSlim from 'eh-dia-util-slim';\n\nexport const getLastBusinessDay = (lastDayOfTheMonth: Date, holidays?: any) => {\n const date = lastDayOfTheMonth;\n while (!isBusinessDay(date) || holidays?.includes(moment(date).tz('Europe/London').format('MM-DD'))) {\n date.setDate(date.getDate() - 1);\n }\n return date;\n};\n\n/** @description Function to return if the day that passed is a business/week day */\nexport const isWeekday = (year: number, month: number, day: number) => {\n const dayReturn = new Date(year, month, day).getDay();\n if (dayReturn === 0 || dayReturn === 6) return false;\n return true;\n};\n\n/** @description Function to return the array of business/week days in that month */\nexport const weekDays = (dateParam: Date) => {\n const year = dateParam.getFullYear();\n const month = dateParam.getMonth();\n const days = new Date(year, month + 1, 0).getDate();\n let weekdays: any[] = [];\n for (let i = 1; i <= days; i++) {\n if (isWeekday(year, month, i)) weekdays.push(i);\n }\n return weekdays;\n};\n\n/** @description Function to get the second business/week day and check if it's true */\nexport const isSecondBusinessDay = (dateParam: Date) => {\n const currentDay = dateParam.getDate();\n const arrayOfWeekDays = weekDays(dateParam);\n return arrayOfWeekDays.indexOf(currentDay) > 2 ? true : false;\n};\n","import axios from 'axios';\n\nconst api = axios.create({\n baseURL: process.env.REACT_APP_MS_DARF_URL || 'http://localhost:5002',\n});\n\nexport default api;","import axios from \"axios\";\n\nexport const apiPlan = axios.create({\n baseURL: process.env.REACT_APP_PLAN_URL || \"http://localhost:8002\",\n});\n","import axios from \"axios\";\n\nconst apiVeloPro = axios.create({\n baseURL: process.env.REACT_APP_VELOPRO_URL || \"http://localhost:8888\",\n});\n\nexport default apiVeloPro;\n","export default __webpack_public_path__ + \"static/media/ssl-secure.dd09a1ee.svg\";","import axios from \"axios\";\n\nconst api = axios.create({\n baseURL: process.env.REACT_APP_EXTERIOR_URL || \"http://localhost:8888\",\n headers: {\n \"ngrok-skip-browser-warning\": \"69420\",\n \"x-api-provider\": \"exterior-warren\",\n },\n});\n\nexport default api;\n","import axios from \"axios\";\n\nexport const apiPayment = axios.create({\n baseURL:\n process.env.REACT_APP_PAYMENT_AUTH || \"http://localhost:4000\",\n headers: {\n \"x-api-provider\": \"warren\",\n },\n});\n","import axios from 'axios';\n\nconst api = axios.create({\n baseURL: process.env.REACT_APP_BACKEND_RENDIMENTOS_URL || 'http://localhost:5003',\n});\n\nexport default api;","import axios from \"axios\";\n\nconst api = axios.create({\n baseURL: process.env.REACT_APP_BOLSA_VELOTAX_URL || \"http://localhost:8004\",\n headers: {\n \"x-api-provider\": \"bolsa-velotax\",\n },\n});\n\nexport default api;\n","import axios from \"axios\";\n\nconst api = axios.create({\n baseURL: process.env.REACT_APP_IRPF2023_URL || \"http://localhost:3333\",\n});\n\nexport default api;\n","import { Button, ButtonProps } from \"antd\";\nimport styled, { css } from \"styled-components\";\n\nexport interface IButtonProps extends ButtonProps {\n typed?: \"underlined\";\n}\n\nexport const ButtonStyled = styled(Button)`\n &.ant-btn {\n display: flex;\n align-items: center;\n justify-content: center;\n border-radius: 0;\n border: 0;\n font-weight: 500;\n column-gap: 8px;\n }\n &[disabled] {\n border-color: var(--velotax-ghost) !important;\n color: var(--velotax-font-color-ghost) !important;\n background-color: var(--velotax-ghost) !important;\n }\n ${(props) =>\n props.type === \"primary\" &&\n css`\n color: var(--black);\n svg {\n fill: var(--black);\n }\n :focus,\n :hover {\n color: var(--black);\n }\n `}\n\n ${(props) =>\n props.size === \"large\" &&\n css`\n height: 56px;\n `}\n \n ${(props) =>\n props.disabled &&\n css`\n svg {\n fill: var(--velotax-font-color-ghost) !important;\n }\n `}\n\n ${(props) =>\n props.typed === \"underlined\" &&\n css`\n color: var(--white);\n border-bottom: 1px solid var(--ant-primary-color);\n :focus,\n :hover {\n border-bottom: 1px solid var(--ant-primary-color-active);\n }\n `}\n`;\n","import { ButtonStyled, IButtonProps } from \"./styles\";\n\nconst Button: React.FC = (props) => (\n {props.children}\n);\n\nexport default Button;\n","import styled from \"styled-components\";\nimport { Modal } from \"antd\";\n\nexport const Container = styled.div`\n width: 100%;\n height: 100%;\n padding: 16px;\n border-radius: 8px;\n border: 1px solid var(--velotax-background-color-ghost);\n span.ant-checkbox {\n top: 0;\n }\n h3 {\n margin: 0;\n font-size: 16px;\n font-weight: 600;\n text-transform: uppercase;\n color: var(--velotax-font-color-ghost);\n }\n .original-price {\n display: grid;\n max-width: 150px;\n }\n .price {\n display: flex;\n width: 100%;\n column-gap: 8px;\n align-items: center;\n justify-content: space-between;\n margin-bottom: 24px;\n h4 {\n font-size: 22px;\n margin: 8px 0 !important;\n color: var(--ant-primary-color);\n del,\n span.per-month {\n font-size: 14px;\n }\n span.cupom-discount {\n font-size: 12px;\n color: var(--velotax-disabled);\n }\n\n del {\n opacity: 0.8;\n color: var(--velotax-font-color);\n }\n }\n .ant-typography-danger {\n font-size: 11px;\n text-align: right;\n max-width: 120px;\n }\n }\n .ant-divider.ant-divider-horizontal {\n margin: 16px 0;\n }\n .other-features,\n .included-features-user {\n .feature {\n display: flex;\n align-items: center;\n justify-content: space-between;\n opacity: 0.7;\n margin: 6px 0;\n column-gap: 16px;\n span {\n font-weight: 500;\n display: flex;\n column-gap: 4px;\n align-items: center;\n svg {\n min-width: 20px;\n min-height: 20px;\n }\n }\n svg.fill {\n fill: var(--velotax-font-color);\n }\n svg:not(.fill) {\n stroke: var(--velotax-font-color);\n }\n &.disabled {\n opacity: 0.4;\n }\n .feature-desc {\n display: block;\n font-size: 10px;\n font-weight: 400;\n }\n }\n }\n .other-features {\n margin-bottom: 24px;\n }\n\n .checkbox-terms {\n font-size: 12px;\n line-height: 16px;\n display: flex;\n column-gap: 4px;\n align-items: flex-start;\n }\n\n @media only screen and (max-device-width: 812px) {\n .original-price {\n font-size: 14px;\n max-width: 100px;\n\n .per-month {\n font-size: 12px !important;\n }\n }\n }\n`;\n\nexport const PlanModalStyled = styled(Modal)`\n .ant-modal-body {\n padding: 32px !important;\n }\n\n .ant-tabs {\n width: 100%;\n }\n\n .ant-tabs-nav {\n margin: 0 auto 8px !important;\n width: calc(100% - 16px) !important;\n }\n\n .click-here {\n cursor: pointer;\n font-weight: 500;\n color: var(--ant-primary-color);\n display: flex;\n align-items: center;\n margin-top: 12px;\n\n svg {\n margin-right: 8px;\n color: var(--ant-primary-color);\n }\n }\n\n .cupom-content {\n .description-cupom-valid {\n font-size: 12px;\n }\n .input-content {\n display: flex;\n column-gap: 4px;\n align-items: center;\n margin-top: 10px;\n .icon-cupom {\n width: 24px;\n height: 24px;\n display: flex;\n align-items: center;\n justify-content: center;\n }\n .input-cupom {\n height: 40px;\n max-width: 200px;\n }\n }\n .cupom-msg {\n margin-top: 4px;\n display: inline-block;\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n .ant-modal-body {\n padding: 16px !important;\n }\n }\n`;\n","import { Checkbox, Col, Divider, message, Row, Typography } from \"antd\";\nimport Button from \"../../Button\";\nimport { Container } from \"./styles\";\nimport { formatCurrency } from \"../../../utils\";\nimport { UserPlan as IUserPlan } from \"../../../constants/plans\";\nimport { useAuth } from \"../../../contexts/AuthContext\";\nimport { useMemo, useState } from \"react\";\n\ninterface PlanProps {\n plan: IUserPlan;\n planBuyed: string;\n handleSelect: React.MouseEventHandler;\n checkIfCupomIsValid: (code: string) => void;\n cupomMsg: string;\n cupomInfo: any;\n codeSave: string;\n setCode: any;\n showInputCupom: boolean;\n buttonLoading?: boolean;\n}\n\nexport const UserPlan: React.FC = ({\n plan,\n planBuyed,\n handleSelect,\n checkIfCupomIsValid,\n cupomMsg,\n cupomInfo,\n codeSave,\n setCode,\n showInputCupom,\n buttonLoading,\n}) => {\n const { user } = useAuth();\n const [acceptTerms, setAcceptTerms] = useState(false);\n const isActive = user?.user?.userPlanInfoVelotax?.active;\n const hasPlan = (planBuyed && isActive) || !!plan.free;\n const isPlanSelected =\n planBuyed && isActive && plan.type === user.user.userPlanInfoVelotax.type;\n\n const handleTerm = () => {\n setAcceptTerms((terms) => !terms);\n };\n\n const price = useMemo(() => {\n var isMonth = plan.interval === \"Mensal\";\n var planPrice = !isMonth ? plan.price * 12 : plan.price;\n\n if (cupomMsg !== \"valid\") return !isMonth ? planPrice / 12 : planPrice;\n\n if (cupomInfo?.type === \"absolute\") {\n planPrice = planPrice - Number(cupomInfo.discountValue);\n } else if (cupomInfo?.type === \"percent\") {\n planPrice = planPrice - planPrice * Number(cupomInfo.discountValue / 100);\n }\n\n planPrice = Number(planPrice.toFixed(2));\n\n return !isMonth ? planPrice / 12 : planPrice;\n }, [plan.price, cupomInfo, cupomMsg, plan.interval]);\n\n return (\n \n {plan.title}\n
\n \n {plan.free ? (\n Gratuito\n ) : (\n
\n {formatCurrency(price)} / mês\n
\n \n {\" \"}\n plano {plan?.interval.toLocaleLowerCase()}\n \n
\n {cupomInfo?.type && (\n \n {\" \"}\n cupom de desconto de{\" \"}\n {cupomInfo?.type === \"percent\"\n ? `${cupomInfo?.discountValue}%`\n : formatCurrency(cupomInfo?.discountValue)}\n \n )}\n
\n )}\n
\n {!plan.free && plan.originalPrice !== plan.price && (\n
\n \n {formatCurrency(plan.originalPrice)}{\" \"}\n \n {`${plan.percentDiscount}% de desconto ${\n plan.discountText ? plan.discountText : \"\"\n }`}\n
\n )}\n \n
\n \n {plan.includedFeatures.map((feature: any) => (\n
\n \n {feature.name}\n {feature?.secondaryIcon}\n \n {feature.icon}\n
\n ))}\n \n \n
\n {plan.descriptions.map((feature: any) => (\n
\n \n {feature.label}\n {feature.info}\n \n {feature.icon}\n
\n ))}\n
\n \n {!isPlanSelected && !hasPlan && (\n \n \n Li, entendi e estou de acordo com o{\" \"}\n \n Termo de Contratação\n \n \n \n )}\n \n \n {\n if (!acceptTerms) {\n message.warning(\"Você precisa aceitar o Termo de Contratação\");\n } else {\n handleSelect(e);\n }\n }}\n loading={buttonLoading}\n disabled={hasPlan}\n >\n {isPlanSelected ? \"Plano Selecionado!\" : \"Selecionar\"}\n \n \n
\n );\n};\n","import api from './apiBolsa';\n\nexport default async function HandleTag(activeCampaignTagId: string) {\n await api\n .post(\n \"/ac\",\n {\n activeCampaignTagId,\n },\n )\n .then()\n .catch((err) => {})\n };","import { Tooltip } from \"antd\";\nimport { BiCopy } from \"react-icons/bi\";\nimport { RiDivideFill, RiStockLine } from \"react-icons/ri\";\nimport { GrTextAlignFull } from \"react-icons/gr\";\nimport { AiFillQuestionCircle } from \"react-icons/ai\";\nimport { HiOutlineDocumentReport } from \"react-icons/hi\";\nimport {\n MdOutlineAlternateEmail,\n MdOutlineAttachMoney,\n MdDone,\n} from \"react-icons/md\";\n\ninterface Feature {\n name: string;\n desc?: string;\n icon?: JSX.Element;\n secondaryIcon?: JSX.Element;\n secondaryLabel?: string;\n}\n\nexport enum PlanEnum {\n BASIC_V1 = \"BASIC_V1\",\n PRO_V1 = \"PRO_V1\",\n}\n\nexport interface Plan {\n type: PlanEnum | UserPlanEnum;\n title: string;\n price: number;\n discount: number;\n originalPrice: number;\n includedFeatures: Feature[];\n otherFeatures: Feature[];\n}\n\nexport const OtherFeatures: Feature[] = [\n {\n name: \"Emissão de relatório anual (DASN-MEI)\",\n },\n {\n name: \"Emissão de guias mensais (DAS)\",\n },\n];\n\nexport enum UserPlanEnum {\n VELOTAX_MAIN_BASIC = \"VELOTAX_MAIN_BASIC\",\n VELOTAX_MAIN_BASIC_MONTH = \"VELOTAX_MAIN_BASIC_MONTH\",\n VELOTAX_MAIN_FREE = \"VELOTAX_MAIN_FREE\",\n VELOTAX_MAIN_PRO = \"VELOTAX_MAIN_PRO\",\n VELOTAX_MAIN_PRO_MONTH = \"VELOTAX_MAIN_PRO_MONTH\",\n VELOTAX_MAIN_CONCIERGE = \"VELOTAX_MAIN_CONCIERGE\",\n WARREN_BASIC = \"WARREN_BASIC\",\n WARREN_PRO = \"WARREN_PRO\",\n WARREN_CONCIERGE = \"WARREN_CONCIERGE\",\n WARREN_PRO_MONTH = \"WARREN_PRO_MONTH\",\n}\n\nexport interface UserPlan {\n type: UserPlanEnum;\n interval: \"Anual\" | \"Mensal\";\n title: string;\n price: number;\n instalments: number;\n discount?: number;\n originalPrice: number;\n includedFeatures: Feature[];\n otherFeatures?: Feature[];\n free?: boolean;\n maskValue?: boolean;\n percentDiscount: number;\n descriptions?: any;\n discountText?: string;\n}\n\nconst overlayStyle = {\n opacity: 0.9,\n backgroundColor: \"#000000\",\n fontSize: 14,\n fontWeight: 500,\n};\n\nexport const UserPlans: UserPlan[] = [\n // {\n // type: UserPlanEnum.VELOTAX_MAIN_FREE,\n // title: \"Rede\",\n // free: true,\n // price: 0.00,\n // originalPrice: 0.00,\n // percentDiscount: 0,\n // includedFeatures: [\n // {\n // name: \"Módulos ilimitados\",\n // icon: ,\n // },\n // {\n // name: \"Não inclui emissão de DARFs\",\n // icon: ,\n // },\n // {\n // name: \"Suporte por e-mail\",\n // icon: ,\n // },\n // ],\n // descriptions: [\n // { label: 'Integração com B3 e corretoras', checked: true, icon: },\n // { label: 'Cálculos automáticos, com multa e juros', checked: true, icon: },\n // {\n // label: 'Emissão de DARF corrente e retroativo',\n // checked: false, icon: \n // },\n // {\n // label: 'Pagamento dos impostos via PIX ',\n // checked: false, icon: \n // },\n // {\n // label: 'Parcelamento em 4x no cartão de crédito',\n // checked: false, icon: \n // },\n // { label: 'Suporte com especialista em IR ao vivo', checked: false, icon: },\n // ]\n // },\n // {\n // type: UserPlanEnum.VELOTAX_MAIN_BASIC,\n // title: \"Basic\",\n // price: 29.9,\n // originalPrice: 79.9,\n // percentDiscount: 60,\n // maskValue: true,\n // includedFeatures: [\n // {\n // name: \"Módulos ilimitados\",\n // icon: ,\n // },\n // {\n // name: \"Emissão de DARFs ilimitados\",\n // icon: ,\n // },\n // {\n // name: \"Suporte por e-mail\",\n // icon: ,\n // },\n // ],\n // descriptions: [\n // {\n // label: \"Integração com B3 e corretoras\",\n // checked: true,\n // icon: ,\n // },\n // {\n // label: \"Cálculos automáticos, com multa e juros\",\n // checked: true,\n // icon: ,\n // },\n // {\n // label: \"Emissão de DARF corrente e retroativo\",\n // info: (\n // \n // \n // \n // ),\n // checked: true,\n // icon: ,\n // },\n // {\n // label: \"Pagamento dos impostos via PIX \",\n // info: (\n // \n // \n // \n // ),\n // checked: true,\n // icon: ,\n // },\n // {\n // label: \"Parcelamento em 4x no cartão de crédito\",\n // info: (\n // \n // \n // \n // ),\n // checked: true,\n // icon: ,\n // },\n // {\n // label: \"Suporte com especialista em IR ao vivo\",\n // checked: false,\n // icon: ,\n // },\n // ],\n // },\n {\n type: UserPlanEnum.VELOTAX_MAIN_PRO,\n interval: \"Anual\",\n title: \"PREMIUM\",\n price: 19.9,\n originalPrice: 19.9,\n percentDiscount: 0,\n instalments: 12,\n // discountText: \"ou 4 meses grátis\",\n maskValue: true,\n includedFeatures: [\n {\n name: \"Módulos de renda variável e exterior\",\n icon: ,\n },\n {\n name: \"Emissão de DARF ilimitados\",\n icon: ,\n secondaryIcon: (\n \n \n \n ),\n },\n {\n name: \"Relatórios auxiliares para declaração de IRPF\",\n icon: ,\n },\n {\n name: \"Pagamento de DARF por PIX ou cartão de crédito\",\n icon: ,\n },\n {\n name: \"Parcelamento dos impostos em até 12x\",\n icon: ,\n },\n ],\n descriptions: [\n {\n label: \"Integração com B3\",\n checked: true,\n icon: ,\n },\n {\n label: \"Cálculos automáticos, com multa e juros\",\n checked: true,\n icon: ,\n },\n {\n label: \"Integração com Warren Internacional\",\n checked: true,\n icon: ,\n },\n // {\n // label: \"Emissão de DARF corrente e retroativo\",\n // info: (\n // \n // \n // \n // ),\n // checked: true,\n // icon: ,\n // },\n // {\n // label: \"Pagamento dos impostos via PIX \",\n // info: (\n // \n // \n // \n // ),\n // checked: true,\n // icon: ,\n // },\n // {\n // label: \"Parcelamento em 4x no cartão de crédito\",\n // info: (\n // \n // \n // \n // ),\n // checked: true,\n // icon: ,\n // },\n // {\n // label: \"Suporte com especialista em IR ao vivo\",\n // info: (\n // \n // \n // \n // ),\n // checked: true,\n // icon: ,\n // },\n ],\n },\n // {\n // type: UserPlanEnum.XP_PRO_MONTH,\n // title: \"PREMIUM\",\n // interval: \"Mensal\",\n // price: 29.9,\n // originalPrice: 29.9,\n // percentDiscount: 0,\n // maskValue: true,\n // includedFeatures: [\n // {\n // name: \"Módulos de renda variável e exterior\",\n // icon: ,\n // },\n // {\n // name: \"Emissão de DARF ilimitados\",\n // icon: ,\n // secondaryIcon: (\n // \n // \n // \n // ),\n // },\n // {\n // name: \"Relatórios auxiliares para declaração de IRPF\",\n // icon: ,\n // },\n // {\n // name: \"Pagamento de DARF por PIX ou cartão de crédito\",\n // icon: ,\n // },\n // {\n // name: \"Parcelamento dos impostos em até 12x\",\n // icon: ,\n // },\n // ],\n // descriptions: [\n // {\n // label: \"Integração com B3\",\n // checked: true,\n // icon: ,\n // },\n // {\n // label: \"Cálculos automáticos, com multa e juros\",\n // checked: true,\n // icon: ,\n // },\n // {\n // label: \"Integração com Warren Internacional\",\n // checked: true,\n // icon: ,\n // },\n // // {\n // // label: \"Emissão de DARF corrente e retroativo\",\n // // info: (\n // // \n // // \n // // \n // // ),\n // // checked: true,\n // // icon: ,\n // // },\n // // {\n // // label: \"Pagamento dos impostos via PIX \",\n // // info: (\n // // \n // // \n // // \n // // ),\n // // checked: true,\n // // icon: ,\n // // },\n // // {\n // // label: \"Parcelamento em 4x no cartão de crédito\",\n // // info: (\n // // \n // // \n // // \n // // ),\n // // checked: true,\n // // icon: ,\n // // },\n // // {\n // // label: \"Suporte com especialista em IR ao vivo\",\n // // info: (\n // // \n // // \n // // \n // // ),\n // // checked: true,\n // // icon: ,\n // // },\n // ],\n // },\n];\n\nexport const Plans: Plan[] = [\n {\n type: PlanEnum.BASIC_V1,\n title: \"basic\",\n price: 29.9,\n discount: 75,\n originalPrice: 119.9,\n includedFeatures: [\n {\n name: \"Emissão de DASN ilimitados\",\n icon: ,\n },\n {\n name: \"Suporte por email\",\n icon: ,\n },\n ],\n otherFeatures: OtherFeatures.slice(0, 1),\n },\n {\n type: PlanEnum.PRO_V1,\n title: \"plus\",\n price: 39.9,\n discount: 75,\n originalPrice: 149.9,\n includedFeatures: [\n {\n name: \"Emissão de DAS e DASN ilimitados\",\n icon: ,\n },\n {\n name: \"Suporte por email\",\n icon: ,\n },\n ],\n otherFeatures: OtherFeatures,\n },\n];\n","import { Modal } from \"antd\";\nimport styled from \"styled-components\";\n\nexport const PlanModalStyled = styled(Modal)`\n min-width: 760px;\n .ant-modal-body {\n padding: 32px !important;\n }\n @media only screen and (max-width: 812px) {\n width: calc(100vw - 32px);\n min-width: unset;\n }\n`;\n\nexport const Content = styled.div`\n display: flex;\n column-gap: 16px;\n position: relative;\n justify-content: center;\n flex-direction: row;\n @media only screen and (max-width: 812px) {\n row-gap: 16px;\n flex-direction: column;\n }\n`;\n\nexport const Loading = styled.div`\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n display: flex;\n border-radius: 8px;\n position: absolute;\n align-items: center;\n justify-content: center;\n background-color: var(--velotax-shadow-default);\n`;\n","import { HTMLAttributes } from \"react\";\n\ninterface CopyTextProps extends HTMLAttributes {\n id: string;\n}\n\nexport const CopyText: React.FC = ({ children, ...props }) => {\n const selectText = () => {\n if ((document as any).selection) {\n // Internet Explorer\n const range = (document.body as any).createTextRange?.();\n range?.moveToElementText?.(document.getElementById(props.id)!);\n range?.select();\n } else if (window.getSelection) {\n const range = document.createRange?.();\n range?.selectNode?.(document.getElementById(props.id)!);\n window.getSelection?.()?.removeAllRanges?.();\n window.getSelection?.()?.addRange?.(range);\n }\n };\n\n return (\n {\n selectText();\n props.onClick?.(e);\n }}\n >\n {children}\n \n );\n};\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n display: flex;\n align-items: center;\n justify-content: center;\n background: var(--ant-info-color);\n height: 100%;\n\n .sso-wrapper {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n\n img {\n max-width: 230px;\n margin-bottom: 40px;\n }\n\n .sso-area {\n background: var(--velotax-background-color);\n border-radius: 8px;\n padding: 20px;\n width: 500px;\n min-height: 100px;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n\n h4 {\n margin-bottom: 20px;\n }\n\n .anticon {\n width: 40px;\n height: 40px;\n color: var(--ant-info-color);\n\n svg {\n width: 100%;\n height: 100%;\n }\n }\n }\n }\n`;\n","export default __webpack_public_path__ + \"static/media/velotax-light.9bb89f4f.svg\";","import { message } from \"antd\";\nimport React, { useEffect, useState } from \"react\";\nimport { LoadingOutlined } from \"@ant-design/icons\";\nimport { useLocation, useNavigate, useParams } from \"react-router-dom\";\nimport api from \"../../services/api\";\nimport { Container } from \"./styles\";\nimport Button from \"../../components/Button\";\nimport { useAuth } from \"../../contexts/AuthContext\";\nimport { apiPayment } from \"../../services/apiPayment\";\nimport veloLogo from \"../../assets/velotax/velotax-light.svg\";\n\nconst SSO: React.FC = () => {\n const { token } = useParams();\n const navigate = useNavigate();\n const { search } = useLocation();\n const { setLocalStorageWithAuthData, setLoadingSession, showUserPlanModal } =\n useAuth();\n const [loading, setLoading] = useState(true);\n\n useEffect(() => {\n api\n .post(\"/session/sso\", {\n token,\n })\n .then(async (res) => {\n message.success(\"Logado com sucesso!\");\n let retPlanInfo = await apiPayment.get(\"/user-plan/plan-info\", {\n headers: {\n authorization: `Bearer ${res?.data?.token}`,\n },\n });\n setLoading(false);\n setLocalStorageWithAuthData({\n ...(res.data || {}),\n userPlanInfoVelotax: retPlanInfo?.data || {},\n });\n const query = new URLSearchParams(search);\n const redirect = query.get(\"redirect\");\n setTimeout(() => {\n setLoadingSession(false);\n if (redirect === \"pagamento\") {\n setTimeout(() => {\n showUserPlanModal(true, \"Contrate o plano\");\n setTimeout(() => {\n document.querySelector(\".checkbox-terms\")?.click();\n document\n .querySelector(\n \".ant-modal-body .ant-btn-primary\"\n )\n ?.click();\n }, 100);\n }, 100);\n }\n }, 500);\n })\n .catch((err) => {\n message.error(\"Algo deu errado, tente novamente mais tarde.\");\n setLoading(false);\n });\n // eslint-disable-next-line\n }, [token, search]);\n\n return (\n \n
\n \"velologo\"\n
\n {loading ? (\n <>\n

Logando...

\n \n \n ) : (\n navigate(\"/p/login\")}\n >\n Tentar fazer login manualmente\n \n )}\n
\n
\n
\n );\n};\n\nexport default SSO;\n","import styled from \"styled-components\";\n\nexport const HomeContainer = styled.div`\n height: 100%;\n display: flex;\n padding: 64px 32px 32px 48px;\n\n & > .content {\n margin: 0 auto;\n width: 700px;\n display: flex;\n flex-direction: column;\n justify-content: space-between;\n\n &.bolsa,\n &.exterior {\n .cards.cards-2 > div {\n width: 100%;\n }\n }\n }\n\n h1 {\n font-weight: 400;\n font-size: 2rem;\n position: relative;\n line-height: 2.5rem;\n padding-bottom: 1rem;\n margin-bottom: 3rem;\n color: var(--velotax-font-color-light);\n\n :after {\n content: \"\";\n position: absolute;\n left: 0;\n bottom: 0;\n height: 2px;\n width: 100px;\n background-color: var(--ant-primary-color);\n }\n }\n\n div.ant-typography {\n font-size: 1rem;\n line-height: 1.5rem;\n color: var(--velotax-font-color-light);\n\n strong {\n font-weight: 500;\n }\n }\n\n .ant-typography.destak {\n margin: 0 0 24px;\n display: block;\n font-weight: 300;\n font-size: 1rem;\n line-height: 1.5rem;\n color: var(--velotax-font-color-light);\n }\n\n .cards {\n margin: 0;\n padding-bottom: 32px;\n width: 100%;\n display: grid;\n row-gap: 1rem;\n column-gap: 1rem;\n grid-template-columns: repeat(4, 1fr);\n\n &.cards-3 {\n grid-template-columns: repeat(3, 1fr);\n }\n\n &.cards-2 {\n grid-template-columns: repeat(2, 1fr);\n }\n\n &.cards-5 {\n display: grid;\n grid-template-columns: repeat(2, 1fr);\n grid-template-rows: auto auto;\n gap: 1rem;\n }\n &.cards-5 > :nth-child(3) {\n grid-column: 1 / span 2;\n height: 80px;\n display: flex;\n }\n &.cards-5 > :nth-child(3) > button {\n display: flex;\n flex-direction: row;\n align-items: center;\n gap: 5px;\n }\n }\n\n .home-footer {\n opacity: 0.75;\n font-size: 12px;\n font-style: italic;\n line-height: 16px;\n letter-spacing: 0.625px;\n }\n\n @media only screen and (max-device-width: 812px) {\n height: auto;\n padding: 24px 24px 64px;\n & > .content {\n width: 100%;\n max-width: 100%;\n &.bolsa,\n &.exterior {\n width: 100%;\n .cards.cards-2 > div {\n width: 100%;\n }\n }\n }\n\n .cards {\n width: 100%;\n grid-template-columns: repeat(2, 1fr) !important;\n\n > div {\n width: auto;\n }\n }\n }\n`;\n","import axios from \"axios\";\n\nconst api = axios.create({\n baseURL: process.env.REACT_APP_CRYPTO_URL || \"http://localhost:8888\",\n headers: {\n \"x-api-provider\": \"crypto-warren\",\n },\n});\n\nexport default api;\n","import clsx from \"clsx\";\nimport { Typography } from \"antd\";\nimport styled from \"styled-components\";\nimport { useState, useEffect, useRef } from \"react\";\nimport { LoadingOutlined } from \"@ant-design/icons\";\nimport { useB3Integration } from \"../../contexts/B3IntegrationContext\";\n\nconst Container = styled.div`\n top: 0;\n left: 0;\n width: 100%;\n height: 100vh;\n position: fixed;\n display: flex;\n row-gap: 16px;\n align-items: center;\n flex-direction: column;\n justify-content: center;\n background-color: #fffd;\n backdrop-filter: blur(1px);\n z-index: 99999;\n h3 {\n width: 100%;\n font-size: 2rem;\n text-align: center;\n position: relative;\n margin: 0 !important;\n span.timer-text {\n left: 0;\n opacity: 0;\n width: 100%;\n position: absolute;\n transition-delay: 400ms;\n transition-duration: 800ms;\n transition-property: opacity;\n transition-timing-function: ease-in-out;\n &.active {\n opacity: 1;\n }\n }\n }\n .loader {\n display: flex;\n align-items: center;\n color: var(--velotax-font-color-dark);\n .timer {\n font-weight: 500;\n font-size: 1.125rem;\n margin-left: 16px;\n }\n .anticon.anticon-loading.anticon-spin {\n width: 40px;\n height: 40px;\n svg {\n width: 40px;\n height: 40px;\n fill: var(--ant-primary-color);\n }\n }\n }\n @media only screen and (max-device-width: 812px) {\n h3 {\n font-size: 1.5rem;\n }\n }\n`;\n\ninterface LoadingIntegrationProps {\n show: boolean;\n hasError?: boolean;\n}\n\nexport const LoadingIntegration: React.FC = ({\n show,\n hasError,\n}) => {\n const { integrationInBackground } = useB3Integration();\n const [timer, setTimer] = useState(0);\n const [close, setClose] = useState();\n const finishTimer = useRef | null>(null);\n const initialTimer = useRef | null>(null);\n\n useEffect(() => {\n if (show && close === undefined) {\n setClose(false);\n initialTimer.current = setInterval(() => {\n setTimer((timer) => (timer + 1 >= 100 ? 100 : timer + 1));\n }, 1500);\n }\n if (!show && close === false) {\n if (initialTimer.current) {\n clearInterval(initialTimer.current);\n }\n finishTimer.current = setInterval(() => {\n setTimer((timer) => {\n if (finishTimer.current && timer >= 100) {\n setClose(undefined);\n clearInterval(finishTimer.current);\n return 100;\n }\n return timer + 1;\n });\n }, 25);\n }\n if (!show && close === undefined) {\n setTimer(0);\n finishTimer.current = null;\n initialTimer.current = null;\n }\n }, [show, close]);\n\n useEffect(() => {\n if (timer === 100) {\n setClose(true);\n // message.info({\n // content:\n // \"Você possui um número alto de operações realizadas na bolsa de valores. Por isso, precisaremos de um pouco mais de tempo para finalizar os seus cálculos de imposto de renda. Volte novamente em 30 minutos.\",\n // duration: 40,\n // });\n }\n }, [timer]);\n\n return !integrationInBackground && close === false && hasError !== true ? (\n \n
\n \n {timer} %\n
\n \n \n Lendo suas transações...\n \n = 2 && timer < 4 })}\n >\n Conferindo seus impostos...\n \n = 4 && timer < 6 })}\n >\n Gerando seus DARFs...\n \n = 6 })}>\n Preparando seu painel de controle...\n \n \n
\n ) : null;\n};\n","import { message } from \"antd\";\nimport {\n createContext,\n Dispatch,\n SetStateAction,\n useCallback,\n useContext,\n useEffect,\n useRef,\n useState,\n} from \"react\";\nimport { useAuth } from \"./AuthContext\";\nimport apiBolsa from \"../services/apiBolsa\";\nimport { useBroker } from \"./BrokerContext\";\nimport apiCrypto from \"../services/apiCrypto\";\nimport HandleTag from \"../services/handleTag\";\nimport { B3AuthURL, errorMessage, isMobile } from \"../utils\";\nimport { LoadingIntegration } from \"../components/LoadingIntegration\";\n\ninterface HandleIntegrationProps {\n integrationInBackground?: boolean;\n onlyPrepareBolsa?: boolean;\n}\n\ninterface IB3IntegrationContext {\n timer: number;\n timeOver: boolean;\n openWithLink: boolean;\n b3Authorized: boolean;\n loadingIntegration: boolean;\n loadingAuthorization: boolean;\n checkingAuhtorization: boolean;\n integrationInBackground: boolean;\n integrate: (onlyPrepareBolsa?: boolean) => void;\n handleIntegrate: (props?: HandleIntegrationProps) => void;\n resetB3IntegrationContext: () => void;\n verifyUserIsAuthorized: (\n once?: boolean,\n autoError?: boolean,\n autoSuccess?: boolean\n ) => void;\n interval: React.MutableRefObject;\n notas: {\n downloadNotaCorretagem: (\n path: string,\n month: number,\n year: number,\n crypto?: boolean\n ) => void;\n historicoNotasCorretagem: any[];\n getHistoricoNotasCorretagem: (params: {\n crypto?: boolean;\n filters: any;\n }) => void;\n loadingHistoricoNotasCorretagem: boolean;\n showHistoricoNotasCorretagemModal: boolean;\n setHistoricoNotasCorretagem: Dispatch>;\n setShowHistoricoNotasCorretagemModal: Dispatch>;\n };\n}\n\nexport const B3IntegrationContext = createContext(\n {} as IB3IntegrationContext\n);\n\nexport const B3IntegrationProvider: React.FC = ({ children }) => {\n const { user, b3Authorized, setB3Authorized } = useAuth();\n const { integration, initIntegration, handleIntegrationInit } = useBroker();\n\n const [timer, setTimer] = useState(0);\n const [timeOver, setTimeOver] = useState(false);\n const [loadingIntegration, setLoadingIntegration] = useState(false);\n const [loadingAuthorization, setLoadingAuthorization] = useState(false);\n const [checkingAuhtorization, setCheckingAuhtorization] = useState(false);\n const [integrationInBackground, setIntegrationInBackground] = useState(false);\n const [historicoNotasCorretagem, setHistoricoNotasCorretagem] = useState<\n any[]\n >([]);\n const [loadingHistoricoNotasCorretagem, setLoadingHistoricoNotasCorretagem] =\n useState(false);\n const [\n showHistoricoNotasCorretagemModal,\n setShowHistoricoNotasCorretagemModal,\n ] = useState(false);\n const interval = useRef>();\n const timerInterval = useRef>();\n\n const openWithLink =\n !timeOver && !checkingAuhtorization && !b3Authorized && isMobile();\n\n useEffect(() => {\n if (checkingAuhtorization) {\n setTimer(90);\n timerInterval.current && clearInterval(timerInterval.current);\n timerInterval.current = setInterval(() => {\n setTimer((timer) => (timer - 1 <= 0 ? 0 : timer - 1));\n }, 1000);\n } else {\n setTimer(0);\n timerInterval.current && clearInterval(timerInterval.current);\n }\n return () => {\n timerInterval.current && clearInterval(timerInterval.current);\n };\n }, [checkingAuhtorization]);\n\n const downloadNotaCorretagem = async (\n path: string,\n month: number,\n year: number,\n crypto?: boolean\n ) => {\n try {\n const { data } = await (crypto ? apiCrypto : apiBolsa).get(\n \"/brokerage-notes/download\",\n {\n params: { path: path.replace(\"notas/\", \"\"), month, year },\n }\n );\n if (data.url) {\n window.open(data.url);\n }\n } catch (error) {\n message.error(\"Algo errado aconteceu. Tente novamente mais tarde.\");\n }\n };\n\n const getHistoricoNotasCorretagem = async ({\n filters,\n crypto,\n }: {\n crypto?: boolean;\n filters: any;\n }) => {\n setLoadingHistoricoNotasCorretagem(true);\n const filterDay = filters?.day || null;\n const filterMonth = filters?.month || null;\n const filterYear = filters?.year || null;\n try {\n const { data } = await (crypto ? apiCrypto : apiBolsa).get(\n `/brokerage-notes/history`,\n {\n params: {\n day: filterDay,\n month: filterMonth,\n year: filterYear,\n },\n }\n );\n if (data?.message) {\n message.error(data.message);\n } else {\n setHistoricoNotasCorretagem(\n data.map((nota: any) => ({\n ...nota,\n id: `${nota.month}${nota.year}`,\n }))\n );\n }\n } catch (error: any) {\n message.error(\"Algo errado aconteceu. Tente novamente mais tarde.\");\n } finally {\n setLoadingHistoricoNotasCorretagem(false);\n }\n };\n\n const openB3Window = useCallback(() => {\n window.open(\n B3AuthURL,\n \"_blank\",\n \"location=yes,height=570,width=520,scrollbars=yes,status=yes\"\n );\n }, []);\n\n const integrate = useCallback(\n (onlyPrepareBolsa?: boolean) => {\n HandleTag(\"50\");\n setLoadingIntegration(true);\n apiBolsa\n .post(\"/warren/integrate\", {\n email: user.user.email,\n onlyPrepareBolsa,\n })\n .then(() => handleIntegrationInit())\n .catch((err) => {\n if (err?.response?.data?.message?.includes(\"Aguarde\")) {\n message.error(err?.response?.data?.message);\n } else {\n message.error(errorMessage);\n }\n })\n .finally(() => setLoadingIntegration(false));\n },\n [handleIntegrationInit, user?.user?.email]\n );\n\n const verifyUserIsAuthorized = useCallback(\n (once?: boolean, autoError?: boolean, autoSuccess?: boolean) => {\n let count = 0;\n\n const requestUserAuthorization = (\n interval?: NodeJS.Timeout,\n firstTime?: boolean\n ) =>\n apiBolsa\n .get(\"/warren/verify-user\")\n .then((response) => {\n count += 1;\n if (response?.data?.isAuthorized) {\n setB3Authorized(true);\n setCheckingAuhtorization(false);\n (interval || firstTime) &&\n message.success(\"Permissão concedida com sucesso!\", 5);\n (interval || firstTime || autoSuccess) && integrate();\n interval && clearInterval(interval);\n } else if (autoError) {\n resetB3IntegrationContext();\n // openB3Window();\n // setCheckingAuhtorization(true);\n // verifyUserIsAuthorized();\n }\n if (interval && count > 12) {\n setTimeOver(true);\n clearInterval(interval);\n setCheckingAuhtorization(false);\n }\n return response;\n })\n .catch((err) => {\n if (err?.response?.data?.message) {\n message.error(err?.response?.data?.message);\n }\n if (interval) {\n setTimeOver(true);\n clearInterval(interval);\n setCheckingAuhtorization(false);\n }\n });\n\n if (once && autoError && autoSuccess) {\n setLoadingAuthorization(true);\n }\n requestUserAuthorization(undefined, !once)\n .then((response) => {\n if (!once && !response?.data?.isAuthorized) {\n if (interval.current) {\n clearInterval(interval.current);\n }\n interval.current = setInterval(() => {\n requestUserAuthorization(interval.current);\n }, 6000);\n }\n })\n .finally(() => {\n setLoadingAuthorization(false);\n });\n },\n [integrate, setB3Authorized]\n );\n\n const handleIntegrate = useCallback(\n (props?: HandleIntegrationProps) => {\n if (!checkingAuhtorization) {\n if (timeOver && !b3Authorized) {\n verifyUserIsAuthorized(true, true, true);\n } else if (b3Authorized) {\n setIntegrationInBackground(!!props?.integrationInBackground);\n integrate(props?.onlyPrepareBolsa);\n } else {\n !openWithLink && openB3Window();\n setCheckingAuhtorization(true);\n verifyUserIsAuthorized();\n }\n } else {\n openB3Window();\n }\n },\n [\n timeOver,\n b3Authorized,\n integrate,\n verifyUserIsAuthorized,\n openWithLink,\n openB3Window,\n checkingAuhtorization,\n ]\n );\n\n const resetB3IntegrationContext = () => {\n setTimeOver(false);\n setLoadingIntegration(false);\n setLoadingAuthorization(false);\n setCheckingAuhtorization(false);\n interval.current && clearInterval(interval.current);\n };\n\n useEffect(() => {\n if (initIntegration && (integration.hasError || integration.integrated)) {\n resetB3IntegrationContext();\n verifyUserIsAuthorized(true, integration.hasError);\n }\n }, [\n initIntegration,\n integration.hasError,\n integration.integrated,\n verifyUserIsAuthorized,\n ]);\n\n useEffect(() => {\n !!user.token && !b3Authorized && verifyUserIsAuthorized(true);\n }, [user.token, b3Authorized, verifyUserIsAuthorized]);\n\n useEffect(() => {\n return () => {\n interval.current && clearInterval(interval.current);\n };\n }, []);\n\n return (\n \n {children}\n \n \n );\n};\n\nexport const useB3Integration = () => useContext(B3IntegrationContext);\n","import { Col, Row } from \"antd\";\nimport { useEffect } from \"react\";\nimport { useNavigate } from \"react-router-dom\";\nimport { LoadingOutlined } from \"@ant-design/icons\";\nimport { HomeContainer } from \"./styles\";\nimport { useBroker } from \"../../contexts/BrokerContext\";\nimport { useB3Integration } from \"../../contexts/B3IntegrationContext\";\n\nexport const Home = () => {\n const navigate = useNavigate();\n const { b3Authorized } = useB3Integration();\n const { allPaths, pathBackup, integration, currentBroker } = useBroker();\n\n useEffect(() => {\n // NÃO APAGAR O CÓDIGO: Lógica de redirecionamento comentada por conta do IRPF.\n if (integration.lastUpdate !== \"\") {\n if (allPaths.includes(pathBackup)) {\n if (pathBackup?.includes(\"bolsa\")) {\n if (b3Authorized) {\n navigate(pathBackup ?? \"/carteira\");\n } else {\n navigate(`/${currentBroker.path}/bolsa-integration`);\n }\n } else {\n navigate(pathBackup ?? \"/carteira\");\n }\n } else {\n navigate(\"/carteira\");\n }\n }\n // navigate(\"/declaracao-irpf\");\n }, [\n allPaths,\n navigate,\n pathBackup,\n b3Authorized,\n currentBroker?.path,\n integration?.lastUpdate,\n ]);\n\n return (\n \n \n \n \n \n \n \n );\n};\n","import styled from \"styled-components\";\n\nexport const AuthContainer = styled.section`\n margin: 80px auto 0;\n height: calc(100% - 80px);\n box-sizing: border-box;\n overflow-y: auto;\n overflow-x: hidden;\n background-color: var(--white);\n\n .auth-content {\n min-height: 100%;\n margin: 0 auto;\n max-width: calc(100% - 128px);\n padding: 48px 0;\n position: relative;\n box-sizing: border-box;\n display: flex;\n align-items: center;\n flex-direction: column;\n\n h1 {\n font-weight: 400;\n font-size: 2rem;\n line-height: 2rem;\n color: var(--velotax-font-color-dark);\n margin: 0 0 32px;\n }\n\n p {\n font-weight: 500;\n font-size: 1rem;\n line-height: 1.5rem;\n color: var(--velotax-font-color-dark);\n margin: 0 0 32px;\n text-align: center;\n }\n\n .form-container {\n width: 420px;\n\n form {\n row-gap: 0;\n display: flex;\n flex-direction: column;\n }\n\n .bottom-acessar {\n display: flex;\n justify-content: center;\n }\n }\n }\n\n .buttons {\n margin: 16px 0 8px;\n display: flex;\n column-gap: 16px;\n align-items: center;\n justify-content: space-between;\n }\n\n .btn-underlined {\n padding: 0;\n height: 32px;\n font-weight: 600;\n border-radius: 0;\n border-bottom: 2px dashed var(--ant-primary-color);\n }\n\n .footer {\n display: flex;\n column-gap: 16px;\n align-items: center;\n width: 100%;\n padding: 16px 0;\n margin: 24px auto 0;\n color: var(--velotax-font-color-dark);\n border-top: 1px solid rgba(0, 0, 0, 0.42);\n }\n\n .ant-checkbox-wrapper {\n a,\n span {\n color: var(--velotax-font-color-dark);\n }\n a {\n font-weight: 600;\n }\n }\n\n .checkbox {\n margin-top: 8px;\n }\n\n @media screen and (max-width: 576px) {\n .auth-content {\n border-left: none;\n padding: 64px 24px 0;\n\n :before {\n display: none;\n }\n\n .form-container {\n width: 100%;\n }\n }\n\n .buttons {\n button {\n width: 100%;\n }\n\n button + button {\n display: none;\n }\n }\n\n .footer {\n margin: 48px auto 0;\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n .auth-content {\n max-width: 100%;\n padding: 48px 24px 64px;\n border-left: none;\n }\n }\n`;\n","import { Rule } from \"antd/lib/form\";\nimport {\n checkDateExpiration,\n isDateOnReferenceMonth,\n isNonDateOnFuture,\n isValidCEP,\n isValidCNPJ,\n isValidCPF,\n isValidCreditCard,\n isValidDate,\n isValidDeclarationReceipt,\n isValidEmail,\n isValidFullName,\n isValidIPTU,\n isValidPhone,\n isValidRenavam,\n isValidShelfLife,\n isValidStateAddress,\n isValidVoterCard,\n months,\n} from \".\";\n\nconst dataLimite = \"2021-12-31 23:59:59\";\n\nexport const validationCpf: Rule[] = [\n {\n required: true,\n validator: (_: any, value: string) =>\n !value || !isValidCPF(value)\n ? Promise.reject(new Error(\"Informe um CPF válido\"))\n : Promise.resolve(),\n },\n];\n\nexport const validationCnpj: Rule[] = [\n {\n validator: (_: any, value: string) =>\n !value || !isValidCNPJ(value)\n ? Promise.reject(new Error(\"Informe um CNPJ válido\"))\n : Promise.resolve(),\n },\n];\n\nexport const validationCnpjNotRequired: Rule[] = [\n {\n validator: (_: any, value: string) =>\n value && !isValidCNPJ(value)\n ? Promise.reject(new Error(\"Informe um CNPJ válido\"))\n : Promise.resolve(),\n },\n];\n\nexport const validationFullName: Rule[] = [\n {\n validator: (rule, value) =>\n !value || !isValidFullName(value)\n ? Promise.reject(\n new Error(\"Seu nome deve possuir duas palavras ou mais\")\n )\n : Promise.resolve(),\n },\n];\n\nexport const validationEmail: Rule[] = [\n {\n validator: (rule, value) =>\n !value || !isValidEmail(value)\n ? Promise.reject(new Error(\"Informe um email válido\"))\n : Promise.resolve(),\n },\n];\n\nexport const validationPhone: Rule[] = [\n {\n validator: (rule, value) =>\n !value || isValidPhone(value)\n ? Promise.resolve()\n : Promise.reject(new Error(\"Informe um telefone válido\")),\n },\n];\n\nexport const validationPhoneRequired: Rule[] = [\n {\n required: true,\n validator: (rule, value) =>\n !value || !isValidPhone(value)\n ? Promise.reject(new Error(\"Informe um telefone válido\"))\n : Promise.resolve(),\n },\n];\n\nexport const validationDateNotRequired: Rule[] = [\n {\n validator: (rule, value) =>\n !value || isValidDate(value)\n ? Promise.resolve()\n : Promise.reject(new Error(\"Informe uma data válida\")),\n },\n];\n\nexport const validationDate: Rule[] = [\n {\n required: true,\n validator: (rule, value) =>\n !isValidDate(value)\n ? Promise.reject(new Error(\"Informe uma data válida\"))\n : Promise.resolve(),\n },\n];\n\nexport const validationDateIsOnReferenceMonth: (\n month: number,\n year: number\n) => Rule[] = (month, year) => [\n {\n validator: (_: any, value: string) =>\n isDateOnReferenceMonth(month, year, value)\n ? Promise.resolve()\n : Promise.reject(\n new Error(\n `Informe uma data válida do mês de ${months[month]} de ${year}`\n )\n ),\n },\n];\n\nexport const validationDateIsOnReferenceMonthCompra: Rule[] = [\n {\n validator: async (_: any, value: string) => {\n if (!value) return Promise.reject(new Error(`Informe uma data válida`));\n const today = new Date();\n const pastLimit = today.getFullYear() - 5;\n const [day, month, year] = value.split(\"/\");\n const date = new Date(Number(year), Number(month) - 1, Number(day));\n return value.length < 10 || (value.length === 10 && !isValidDate(value))\n ? Promise.reject(new Error(`Informe uma data válida`))\n : Number(year) < pastLimit\n ? Promise.reject(new Error(`Informe um ano superior a ${pastLimit}`))\n : date.getTime() > today.getTime()\n ? Promise.reject(new Error(\"Não é permitida uma data futura\"))\n : Promise.resolve();\n },\n },\n];\n\nexport const validationDateIsOnFuture: (\n month: number,\n year: number\n) => Rule[] = (month, year) => [\n {\n validator: (_: any, value: string) =>\n isNonDateOnFuture(month, year, value)\n ? Promise.resolve()\n : Promise.reject(\n new Error(\n `Informe uma data menor ou igual ao mês de ${months[month]} de ${year}`\n )\n ),\n },\n];\n\nexport const validationIPTU: Rule[] = [\n {\n validator: (rule, value) =>\n isValidIPTU(value)\n ? Promise.resolve()\n : Promise.reject(\n new Error(\"O número do IPTU precisa ter entre 8 e 30 caracteres.\")\n ),\n },\n];\n\nexport const validationDateNotRequired2021: Rule[] = [\n {\n validator: (rule, value) =>\n value && !isValidDate(value)\n ? Promise.reject(new Error(\"Informe uma data válida\"))\n : value && !checkDateExpiration(dataLimite, value)\n ? Promise.reject(new Error(\"Informe uma data até 31/12/2021\"))\n : Promise.resolve(),\n },\n];\n\nexport const validationDate2021: Rule[] = [\n {\n required: true,\n validator: (rule, value) =>\n !isValidDate(value)\n ? Promise.reject(new Error(\"Informe uma data válida\"))\n : !checkDateExpiration(dataLimite, value)\n ? Promise.reject(new Error(\"Informe uma data até 31/12/2021\"))\n : Promise.resolve(),\n },\n];\n\nexport const validationVoterCard: Rule[] = [\n {\n validator: (rule, value) =>\n !value || isValidVoterCard(value)\n ? Promise.resolve()\n : Promise.reject(new Error(\"Informe um Título de Eleitor válido\")),\n },\n];\n\nexport const validationRenavam: Rule[] = [\n {\n validator: (rule, value) =>\n !value || isValidRenavam(value)\n ? Promise.resolve()\n : Promise.reject(new Error(\"Informe um Renavam válido\")),\n },\n];\n\nexport const validationFieldRequired: Rule[] = [\n {\n required: true,\n message: \"Este campo é obrigatório\",\n },\n];\n\nexport const validationNumberPercentageField: Rule[] = [\n ...validationFieldRequired,\n {\n min: 0.0001,\n type: \"number\",\n message: \"O valor deve ser maior que 0,0001\",\n },\n {\n max: 100,\n type: \"number\",\n message: \"O valor deve ser menor que 100 (cem)\",\n },\n];\n\nexport const validationNumberPercentageFieldPositive: Rule[] = [\n ...validationFieldRequired,\n {\n min: 0,\n type: \"number\",\n message: \"O valor deve estar entre 0 (zero) e 100 (cem)\",\n },\n {\n max: 100,\n type: \"number\",\n message: \"O valor deve estar entre 0 (zero) e 100 (cem)\",\n },\n];\n\nexport const validationNumberField: Rule[] = [\n ...validationFieldRequired,\n {\n min: 0.01,\n type: \"number\",\n message: \"O valor deve ser maior que 0 (zero)\",\n },\n];\n\nexport const validationNumberAllowNegativeField: Rule[] = [\n ...validationFieldRequired,\n {\n type: \"number\",\n message: \"Não é um número válido\",\n },\n];\n\nexport const validationNumberFieldPositive: Rule[] = [\n ...validationFieldRequired,\n {\n min: 0,\n type: \"number\",\n message: \"O valor deve ser positivo\",\n },\n];\n\nexport const validationQuantityCryptoField: Rule[] = [\n ...validationFieldRequired,\n {\n min: 0,\n type: \"number\",\n message: \"O valor deve ser positivo\",\n },\n];\n\nexport const validationDeclarationReceipt: Rule[] = [\n {\n validator: (rule, value) =>\n isValidDeclarationReceipt(value)\n ? Promise.resolve()\n : Promise.reject(\n new Error(\"O número da declaração deve ter 10 ou 12 dígitos\")\n ),\n },\n];\n\nexport const validationStateAddress: Rule[] = [\n {\n required: true,\n validator: (rule, value) =>\n value && isValidStateAddress(value)\n ? Promise.resolve()\n : Promise.reject(new Error(\"Informe um Estado válido\")),\n },\n];\n\nexport const validationCardShelfLife: Rule[] = [\n {\n required: true,\n validator: (rule, value) =>\n isValidShelfLife(value)\n ? Promise.reject(new Error(\"Informe uma data válida\"))\n : Promise.resolve(),\n },\n];\n\nexport const validationCep: Rule[] = [\n {\n required: true,\n validator: (rule, value) =>\n isValidCEP(value ?? \"\")\n ? Promise.resolve()\n : Promise.reject(new Error(\"Informe um CEP válido\")),\n },\n];\n\nexport const validationAmexCVV: Rule[] = [\n {\n required: true,\n validator: (rule, value) =>\n (value?.replace(/[_]/g, \"\") ?? \"\")?.length === 4\n ? Promise.resolve()\n : Promise.reject(new Error(\"Insira um código de segurança válido\")),\n },\n];\n\nexport const validationCVV: Rule[] = [\n {\n required: true,\n validator: (rule, value) =>\n (value?.replace(/[_]/g, \"\") ?? \"\")?.length === 3\n ? Promise.resolve()\n : Promise.reject(new Error(\"Insira um código de segurança válido\")),\n },\n];\n\nexport const validationPasswordNotRequired: Rule[] = [\n { min: 6, message: \"A senha deve ter pelo menos 6 caracteres\" },\n];\n\nexport const validationPassword: Rule[] = [\n { required: true, message: \"Informe uma senha\" },\n { min: 6, message: \"A senha deve ter pelo menos 6 caracteres\" },\n];\n\nexport const validationPassConfirmation: Rule[] = [\n ({ getFieldValue }) => ({\n validator: (_: any, value: string) =>\n value === getFieldValue(\"pass\")\n ? Promise.resolve()\n : Promise.reject(new Error(\"As senhas não coincidem\")),\n }),\n];\n\nexport const validationCreditCardNumber: Rule[] = [\n {\n validator: (rule, value: string) =>\n isValidCreditCard(value?.replace(/[^0-9\\\\.]+/g, \"\"))\n ? Promise.resolve()\n : Promise.reject(new Error(\"Número de cartão inválido\")),\n },\n];\n","import { Form } from \"antd\";\nimport React, { useState } from \"react\";\nimport ReactInputMask from \"react-input-mask\";\nimport { useNavigate } from \"react-router-dom\";\nimport { Button, TextField } from \"@mui/material\";\nimport { LoadingOutlined } from \"@ant-design/icons\";\nimport { cpfInputMask } from \"../../utils\";\nimport { useAuth } from \"../../contexts/AuthContext\";\nimport { useBroker } from \"../../contexts/BrokerContext\";\nimport { AuthContainer } from \"../../styles/LoginSignUp/authContainer\";\nimport {\n validationCpf,\n validationFieldRequired,\n} from \"../../utils/formValidations\";\n\ninterface IData {\n cpf: string;\n pass: string;\n}\n\nconst MaskCPF = React.forwardRef((props, ref) => (\n \n));\n\nexport const Login: React.FC = () => {\n const navigate = useNavigate();\n const [form] = Form.useForm();\n const { handleSignIn, loading } = useAuth();\n const { getIntegrationStatus } = useBroker();\n const [fieldsError, setFieldsError] = useState<{ [key: string]: string[] }>(\n {}\n );\n\n const onFinish = async (data: IData) => {\n try {\n await handleSignIn(data);\n getIntegrationStatus({ firstTime: true });\n } catch (err: any) {\n return;\n }\n };\n\n const onValuesChange = (changed: any, values: any) => {\n const cpf = changed.cpf ? changed.cpf.replace(/[_.-/-]/g, \"\") : values.cpf;\n form.setFieldsValue({\n ...values,\n cpf,\n });\n };\n\n const onFieldsChange = () => {\n setFieldsError(\n form\n .getFieldsError()\n .reduce((acc, cur) => ({ ...acc, [cur.name?.[0]]: cur.errors }), {})\n );\n };\n\n const handleNavigate = () => {\n navigate(\"/p/cadastrar\");\n };\n\n return (\n \n
\n
\n

Acesse sua conta

\n \n \n 0}\n InputProps={{ inputComponent: MaskCPF as any }}\n />\n \n\n \n 0}\n />\n \n\n
\n }\n >\n Entrar\n \n
\n
\n navigate(\"/p/forgot-password\")}\n >\n Esqueci minha senha\n \n
\n \n\n
\n Ainda não possui uma conta?\n \n
\n
\n
\n
\n );\n};\n","import { Checkbox, Form } from \"antd\";\nimport React, { useState } from \"react\";\nimport ReactInputMask from \"react-input-mask\";\nimport { useNavigate } from \"react-router-dom\";\nimport { LoadingOutlined } from \"@ant-design/icons\";\nimport { MdVisibility, MdVisibilityOff } from \"react-icons/md\";\nimport {\n Button,\n FormControl,\n IconButton,\n FilledInput,\n InputAdornment,\n InputLabel,\n TextField,\n} from \"@mui/material\";\nimport { cpfInputMask } from \"../../utils\";\nimport { useAuth } from \"../../contexts/AuthContext\";\nimport { AuthContainer } from \"../../styles/LoginSignUp/authContainer\";\nimport {\n validationCpf,\n validationEmail,\n validationFullName,\n validationPassword,\n} from \"../../utils/formValidations\";\n\ninterface IData {\n email: string;\n pass: string;\n passConfirmation: string;\n cpf: string;\n name: string;\n}\n\ninterface IProps {\n className?: string;\n}\n\nconst MaskCPF = React.forwardRef((props, ref) => (\n \n));\n\nconst Cadastro: React.FC = () => {\n const navigate = useNavigate();\n const [form] = Form.useForm();\n const { handleSignUp, loading } = useAuth();\n const [showPassword, setShowPassword] = useState(false);\n const [fieldsError, setFieldsError] = useState<{ [key: string]: string[] }>(\n {}\n );\n\n const onFinish = (data: IData) => {\n handleSignUp(data, {});\n };\n\n const onValuesChange = (changed: any, values: any) => {\n const cpf = changed.cpf ? changed.cpf.replace(/[_.-/-]/g, \"\") : values.cpf;\n form.setFieldsValue({\n ...values,\n cpf,\n });\n };\n\n const onFieldsChange = () => {\n setFieldsError(\n form\n .getFieldsError()\n .reduce((acc, cur) => ({ ...acc, [cur.name?.[0]]: cur.errors }), {})\n );\n };\n\n return (\n \n
\n
\n

Faça seu cadastro

\n \n \n 0}\n />\n \n\n \n 0}\n InputProps={{ inputComponent: MaskCPF as any }}\n />\n \n\n \n 0}\n />\n \n\n \n \n Senha\n 0}\n endAdornment={\n \n e.preventDefault()}\n onClick={() => setShowPassword((show) => !show)}\n edge=\"end\"\n >\n {showPassword ? : }\n \n \n }\n />\n \n \n\n e.target.checked}\n >\n \n \n Li, entendi e estou de acordo com os{\" \"}\n \n Termos de Uso\n \n ,{\" \"}\n \n Política de Privacidade\n {\" \"}\n e{\" \"}\n \n Política de Cookies\n {\" \"}\n do Velotax\n \n \n \n\n
\n }\n >\n Começar\n \n
\n \n\n
\n Já possui uma conta?\n navigate(\"/p/login\")}\n >\n Entrar\n \n
\n
\n
\n
\n );\n};\n\nexport default Cadastro;\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n .velotax-content {\n display: flex;\n align-items: center;\n flex-direction: column;\n justify-content: center;\n\n .success {\n width: 80px;\n height: 80px;\n display: flex;\n margin-top: 64px;\n position: relative;\n border-radius: 50%;\n align-items: center;\n justify-content: center;\n background-color: var(--ant-primary-color);\n :after,\n :before {\n content: \"\";\n position: absolute;\n border-radius: 50%;\n background-color: var(--ant-primary-color);\n }\n :before {\n top: -16px;\n left: -16px;\n width: 112px;\n height: 112px;\n opacity: 0.1;\n }\n :after {\n top: -28px;\n left: -28px;\n width: 136px;\n height: 136px;\n opacity: 0.08;\n }\n svg {\n width: 40px;\n height: 40px;\n fill: var(--white);\n }\n }\n\n h1 {\n font-size: 24px;\n font-weight: 700;\n line-height: 32px;\n font-style: normal;\n margin: 48px 0 8px;\n letter-spacing: -0.24px;\n color: var(--velotax-font-color-light);\n }\n\n div.ant-typography {\n font-size: 16px;\n font-weight: 400;\n max-width: 450px;\n line-height: 24px;\n font-style: normal;\n text-align: center;\n margin-bottom: 40px;\n color: var(--velotax-font-color-light);\n }\n\n .ant-btn-primary {\n width: 200px;\n margin-bottom: 64px;\n }\n\n .expert-xp {\n padding: 16px 24px;\n border-radius: 8px;\n margin-bottom: 24px;\n background-color: var(--white);\n .ant-typography {\n display: block;\n text-align: center;\n font-size: 16px;\n font-weight: 400;\n line-height: 24px;\n color: var(--velotax-font-color-dark);\n text-shadow: 0px 0px var(--velotax-font-color-dark);\n a {\n text-decoration: underline;\n text-shadow: 0px 0px var(--ant-primary-color);\n }\n strong {\n font-style: italic;\n }\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n .velotax-content {\n .success {\n margin-top: 32px;\n }\n div.ant-typography {\n margin-bottom: 32px;\n }\n .ant-btn-primary {\n margin-bottom: 32px;\n }\n }\n }\n`;\n","import { Typography } from \"antd\";\nimport { HiCheck } from \"react-icons/hi\";\nimport { useNavigate } from \"react-router\";\nimport { Container } from \"./styles\";\nimport Button from \"../../components/Button\";\n\nexport const Sucesso = () => {\n const navigate = useNavigate();\n return (\n \n
\n
\n \n
\n Sucesso!\n \n Agora você já consegue acessar todos os módulos da plataforma e emitir\n DARFs ilimitados sem custo adicional.\n \n {\n navigate(\"/carteira\");\n }}\n >\n Continuar\n \n {/*
\n \n Você ganhou um cupom de desconto para adquirir seu ingresso Expert\n Warren 2023.\n \n \n Acesse{\" \"}\n \n www.expertxp.com.br\n {\" \"}\n e utilize o cupom \"VelotaxNaExpertXP\".\n \n
*/}\n
\n
\n );\n};\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n .velotax-content.carteira {\n width: 840px;\n\n .erroB3 {\n font-size: 16px;\n font-weight: 500;\n text-align: center;\n }\n }\n .header {\n display: flex;\n align-items: flex-start;\n width: 100%;\n width: 840px;\n\n h1 {\n flex-grow: 1;\n }\n .hide-values-btn {\n svg {\n margin-top: 1rem;\n transition: 0.3s;\n &:hover {\n fill: var(--ant-primary-3) !important;\n transition: 0.3s;\n }\n }\n }\n .notification-button {\n button {\n width: 52px;\n height: 52px;\n transition: 0.3s;\n border-radius: 50%;\n background-color: var(--ant-primary-color);\n\n &:hover {\n background-color: var(--ant-primary-5);\n box-shadow: 0 2px 10px 1px rgba(0, 0, 0, 0.1) !important;\n transition: 0.3s;\n }\n\n svg {\n font-size: 28px;\n fill: var(--black);\n }\n }\n }\n }\n .ant-tabs-nav-list {\n width: 100%;\n border-bottom: 1px solid #efefef;\n .ant-tabs-ink-bar {\n bottom: -1px;\n }\n }\n .ant-tabs-ink-bar {\n max-width: 50% !important;\n width: 100% !important;\n }\n .ant-tabs-tab {\n width: 100%;\n display: flex;\n justify-content: center;\n }\n .success {\n color: var(--ant-success-color);\n }\n .error {\n color: red;\n }\n .page-title {\n display: flex;\n align-items: baseline;\n }\n .hide-values-btn {\n width: 24px;\n margin-left: 12px;\n border-radius: 4px;\n display: inline-flex;\n height: 32px !important;\n background-color: transparent;\n svg {\n width: 20px;\n height: 20px;\n fill: var(--ant-primary-color) !important;\n }\n }\n\n .patrimonio {\n width: 100%;\n margin-bottom: -48px;\n\n h1:not(.page-title) {\n padding-bottom: 0;\n font-size: 2.25rem;\n margin: 0 !important;\n color: var(--velotax-font-color-light);\n\n span {\n font-weight: 800;\n }\n\n :after {\n display: none;\n }\n }\n\n h2 {\n font-weight: 400;\n line-height: 1rem;\n font-size: 0.875rem;\n margin: 0 !important;\n color: var(--velotax-font-color-light);\n }\n\n .lucro-prejuizo {\n padding: 16px 0 16px 16px;\n border-left: 2px solid #efefef;\n\n .anticon.anticon-loading.anticon-spin {\n width: 14px;\n height: 14px;\n margin-left: 4px;\n svg {\n width: 14px;\n height: 14px;\n }\n }\n\n div.ant-typography {\n margin: 0.5rem 0;\n font-size: 0.875rem;\n span {\n font-weight: 600;\n white-space: nowrap;\n }\n }\n }\n }\n\n .list-empty {\n padding: 16px;\n margin-top: -16px;\n border-radius: 8px;\n color: var(--velotax-font-color);\n background-color: #efefef;\n }\n\n .last-update {\n display: flex;\n margin-top: 32px;\n align-items: center;\n font-size: 0.75rem;\n line-height: 1.5rem;\n color: var(--ant-primary-color);\n .button-refresh-wallet {\n width: 20px;\n height: 20px;\n border: none;\n box-shadow: none;\n margin-right: 8px;\n background-color: #efefef;\n color: var(--ant-primary-color) !important;\n svg {\n width: 10px !important;\n height: 10px !important;\n * {\n stroke: var(--ant-primary-color) !important;\n }\n }\n }\n }\n\n .messages {\n margin-top: 16px;\n font-weight: 400;\n padding-top: 16px;\n line-height: 1rem;\n font-size: 0.75rem;\n color: var(--velotax-font-color);\n border-top: 2px solid #efefef;\n li {\n padding-left: 16px;\n margin-bottom: 6px;\n position: relative;\n .anticon-info-circle {\n left: 0;\n top: 1px;\n position: absolute;\n color: var(--velotax-font-color);\n }\n }\n }\n\n .select-container {\n top: 0;\n right: 0;\n width: 41.6666%; // 41.6666% para alinhar com o prejuizo (10/24 = 41.6666)\n position: absolute;\n .ant-select {\n min-width: 180px;\n height: 40px !important;\n .ant-select-selector {\n height: 40px !important;\n }\n }\n }\n .recharts-layer.recharts-pie-labels text {\n font-size: 14px !important;\n font-weight: 600 !important;\n }\n @media only screen and (min-device-width: 813px) {\n .velotax-content.largeChart {\n .recharts-responsive-container {\n margin: 0 auto 80px;\n }\n }\n .recharts-responsive-container {\n margin: 0 auto 48px;\n position: relative;\n .recharts-wrapper {\n width: 100% !important;\n > .recharts-surface {\n margin-left: 80px;\n }\n .recharts-legend-wrapper {\n right: 0px !important;\n .recharts-legend-item {\n margin: 4px 0;\n .recharts-surface {\n width: 16px;\n height: 16px;\n border-radius: 2px;\n }\n .recharts-legend-item-text {\n /* margin-left: 12px; */\n span {\n font-size: 14px;\n font-weight: 500;\n color: var(--velotax-font-color) !important;\n }\n }\n }\n }\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n .velotax-content.carteira {\n width: 100%;\n }\n .header {\n width: 100%;\n padding-right: 16px;\n align-items: center;\n .page-title {\n font-size: 22px;\n align-items: center;\n }\n .hide-values-btn {\n svg {\n margin: 0;\n }\n }\n }\n .patrimonio {\n margin-bottom: -48px;\n\n .lucro-prejuizo {\n padding: 4px 0 0;\n border: none;\n margin-top: 16px;\n border-top: 2px solid #efefef;\n\n .anticon.anticon-loading.anticon-spin {\n width: 10px;\n height: 10px;\n margin-left: 4px;\n svg {\n width: 10px;\n height: 10px;\n }\n }\n\n div.ant-typography {\n margin: 0.25rem 0;\n font-size: 0.75rem;\n }\n }\n }\n\n h1 {\n width: calc(100% - 48px);\n margin: 0 24px 1.5rem;\n padding: 24px 0 1rem;\n }\n\n .recharts-responsive-container {\n position: relative;\n margin: 32px auto;\n .select-container {\n top: -32px;\n width: 100%;\n .ant-select {\n min-width: 210px;\n }\n }\n .recharts-legend-wrapper {\n width: 98px !important;\n right: -24px !important;\n .recharts-legend-item {\n margin: 4px 0;\n align-items: start;\n display: flex !important;\n margin-right: 0 !important;\n .recharts-surface {\n border-radius: 2px;\n margin-top: 1px;\n }\n .recharts-legend-item-text {\n max-width: 80px;\n font-size: 13px;\n line-height: 14px;\n white-space: normal;\n display: inline-block;\n span {\n color: var(--velotax-font-color) !important;\n }\n }\n }\n }\n }\n }\n`;\n\nexport const Content = styled.div`\n .ant-tabs-tabpane {\n display: flex;\n justify-content: center;\n }\n .range {\n display: flex;\n justify-content: space-between;\n\n div.ant-typography {\n font-size: 13px;\n }\n }\n .isentometro {\n margin-bottom: 5px;\n font-size: 14px;\n }\n .box {\n margin: 50px 0px;\n }\n .overview {\n color: var(--ant-primary-color);\n font-size: 18px;\n font-weight: bold;\n }\n .ant-progress-success-bg {\n background-color: var(--ant-primary-color);\n height: 13px !important;\n }\n .ant-progress-inner {\n height: 13px !important;\n }\n .ant-progress-bg {\n height: 13px !important;\n }\n & > .ant-collapse {\n border: none;\n & > .ant-collapse-item.ativos-categoria {\n margin-bottom: 48px;\n &:last-of-type {\n margin-bottom: 0;\n }\n & > .ant-collapse-header {\n padding: 0;\n align-items: center;\n .ant-collapse-arrow {\n right: 0;\n }\n h2 {\n margin: 0;\n font-weight: 700;\n font-size: 1.125rem;\n line-height: 1.5rem;\n color: var(--ant-primary-color);\n }\n .collapse-title-divider {\n flex-grow: 1;\n display: block;\n margin: 0 16px;\n border-bottom: 2px solid #efefef;\n }\n .collapse-title-hidden {\n width: 24px;\n height: 24px;\n display: block;\n visibility: hidden;\n }\n }\n & > .ant-collapse-content {\n border: none;\n background-color: transparent;\n & > .ant-collapse-content-box {\n padding: 24px 0 0;\n & > .ant-collapse {\n border: none;\n }\n & > div {\n font-size: 13px;\n }\n }\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n width: 100%;\n margin-bottom: 0;\n border-radius: 0;\n padding: 32px 24px;\n\n h1,\n h2 {\n padding: 0;\n }\n }\n`;\n\nexport const BlurContent = styled.div`\n margin-top: 8px;\n position: relative;\n user-select: none;\n border-radius: 4px;\n border: 2px solid #efefef;\n .blur-content {\n opacity: 0.5;\n filter: blur(4px);\n }\n .blur-content-title {\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n padding: 0 100px;\n font-weight: 500;\n font-size: 1.25rem;\n text-align: center;\n row-gap: 16px;\n display: flex;\n align-items: center;\n flex-direction: column;\n justify-content: center;\n color: var(--velotax-font-color-light);\n }\n\n @media only screen and (max-device-width: 812px) {\n .blur-content-title {\n padding: 0 16px;\n font-size: 1rem;\n }\n }\n`;\n\nexport const Toolbar = styled.div`\n display: flex;\n flex-direction: column;\n width: 700px;\n margin: 0 auto 1.5rem;\n justify-content: space-between;\n\n @media only screen and (max-device-width: 812px) {\n width: 100%;\n }\n`;\n\nexport const IsentCardStyled = styled.div`\n margin-bottom: 4px;\n height: 110px;\n padding: 23px;\n border: none !important;\n border-radius: 4px !important;\n background-color: var(--velotax-background-color-ghost);\n text-align: center;\n gap: 12px;\n flex-direction: column;\n display: flex;\n\n .overviewTitleIsent {\n color: var(--ant-primary-color);\n font-size: 13px;\n }\n`;\n","import React from \"react\";\nimport styled from \"styled-components\";\nimport { LoadingOutlined } from \"@ant-design/icons\";\n\nconst Container = styled.div`\n display: flex;\n align-items: flex-start;\n justify-content: center;\n padding: 64px 32px 0;\n height: calc(100vh - 64px);\n .anticon.anticon-loading.anticon-spin {\n width: 48px;\n height: 48px;\n svg {\n width: 48px;\n height: 48px;\n fill: var(--ant-primary-color);\n }\n }\n`;\n\nconst Loading: React.FC = () => {\n return (\n \n \n \n );\n};\n\nexport default Loading;\n","import _ from \"lodash\";\nimport moment from \"moment\";\nimport { useEffect, useState } from \"react\";\nimport {\n Bar,\n BarChart,\n Legend,\n ResponsiveContainer,\n XAxis,\n YAxis,\n Tooltip,\n} from \"recharts\";\nimport Loading from \"../Loading\";\nimport { isMobile } from \"../../utils\";\n\nexport const ChartBar = ({\n monthReport,\n proventos,\n yearProventos,\n typeProventos,\n hideValues,\n}: any) => {\n const [data, setDataChart] = useState([]);\n const [bars, setBars] = useState([]);\n const [loading, setLoading] = useState(false);\n const [totalDiv, setTotalDiv] = useState(0);\n const [totalJscp, setTotalJscp] = useState(0);\n const [totalBonds, setTotalBonds] = useState(0);\n const [totalRendi, setTotalRendi] = useState(0);\n const [totalAmort, setTotalAmort] = useState(0);\n\n const chartColors = [\n { background: \"#FCC102\", label: \"white\" },\n { background: \"#C8D200\", label: \"black\" },\n { background: \"#FF2B01\", label: \"white\" },\n { background: \"#4B0082\", label: \"white\" },\n { background: \"#CC13AF\", label: \"white\" },\n { background: \"#0204a8\", label: \"white\" },\n { background: \"#79002B\", label: \"white\" },\n { background: \"#0A9E5A\", label: \"white\" },\n { background: \"#FF7F00\", label: \"white\" },\n ];\n\n const getProviderColor = (provider: string, index: number) => {\n while (index > 8) {\n const differnce = index - 8;\n index = differnce - 1;\n }\n return chartColors[index].background;\n };\n\n useEffect(() => {\n setLoading(true);\n let totalJscp = 0;\n let totalDiv = 0;\n let totalBonds = 0;\n let totalRendi = 0;\n let totalAmort = 0;\n if (typeProventos === \"provento\") {\n const proventoByMonth: any = [\n {\n name: \"Jan\",\n juros: 0,\n dividendo: 0,\n rendimento: 0,\n amortizacao: 0,\n bonds: 0,\n },\n {\n name: \"Fev\",\n juros: 0,\n dividendo: 0,\n rendimento: 0,\n amortizacao: 0,\n bonds: 0,\n },\n {\n name: \"Mar\",\n juros: 0,\n dividendo: 0,\n rendimento: 0,\n amortizacao: 0,\n bonds: 0,\n },\n {\n name: \"Abr\",\n juros: 0,\n dividendo: 0,\n rendimento: 0,\n amortizacao: 0,\n bonds: 0,\n },\n {\n name: \"Mai\",\n juros: 0,\n dividendo: 0,\n rendimento: 0,\n amortizacao: 0,\n bonds: 0,\n },\n {\n name: \"Jun\",\n juros: 0,\n dividendo: 0,\n rendimento: 0,\n amortizacao: 0,\n bonds: 0,\n },\n {\n name: \"Jul\",\n juros: 0,\n dividendo: 0,\n rendimento: 0,\n amortizacao: 0,\n bonds: 0,\n },\n {\n name: \"Ago\",\n juros: 0,\n dividendo: 0,\n rendimento: 0,\n amortizacao: 0,\n bonds: 0,\n },\n {\n name: \"Set\",\n juros: 0,\n dividendo: 0,\n rendimento: 0,\n amortizacao: 0,\n bonds: 0,\n },\n {\n name: \"Out\",\n juros: 0,\n dividendo: 0,\n rendimento: 0,\n amortizacao: 0,\n bonds: 0,\n },\n {\n name: \"Nov\",\n juros: 0,\n dividendo: 0,\n rendimento: 0,\n amortizacao: 0,\n bonds: 0,\n },\n {\n name: \"Dez\",\n juros: 0,\n dividendo: 0,\n rendimento: 0,\n amortizacao: 0,\n bonds: 0,\n },\n ];\n\n const groupedProventos = _.groupBy(proventos, (item) => {\n return moment(item.date).format(\"YYYY-MM\");\n });\n\n for (const key in groupedProventos) {\n const year = +moment(key).format(\"Y\");\n const month = +moment(key).format(\"M\");\n const operations = groupedProventos[key];\n if (Number(year) === yearProventos) {\n operations.forEach((el: any) => {\n if (\n el?.corporateActionTypeDescription?.toLowerCase() === \"rendimento\"\n ) {\n proventoByMonth[month - 1].rendimento =\n proventoByMonth[month - 1]?.rendimento + el.grossAmount;\n }\n if (\n el?.corporateActionTypeDescription?.toLowerCase() === \"dividendo\" ||\n el?.corporateActionTypeDescription?.toLowerCase() === \"dividendos\"\n ) {\n proventoByMonth[month - 1].dividendo =\n proventoByMonth[month - 1]?.dividendo + el.grossAmount;\n }\n if (\n el?.corporateActionTypeDescription?.toLowerCase() ===\n \"juros sobre capital próprio\"\n ) {\n proventoByMonth[month - 1].juros =\n proventoByMonth[month - 1]?.juros + el.grossAmount;\n }\n if (\n el?.corporateActionTypeDescription?.toLowerCase() ===\n \"amortização\"\n ) {\n proventoByMonth[month - 1].amortizacao =\n proventoByMonth[month - 1]?.amortizacao + el.grossAmount;\n }\n if (\n el?.corporateActionTypeDescription?.toLowerCase() ===\n \"cupom\"\n ) {\n proventoByMonth[month - 1].bonds =\n proventoByMonth[month - 1]?.bonds + el.grossAmount;\n }\n });\n }\n }\n for (const el of proventoByMonth) {\n totalAmort += el.amortizacao || 0;\n totalJscp += el.juros || 0;\n totalDiv += el.dividendo || 0;\n totalBonds += el.bonds || 0;\n totalRendi += el.rendimento || 0;\n }\n\n setTotalAmort(totalAmort);\n setTotalBonds(totalBonds);\n setTotalDiv(totalDiv);\n setTotalJscp(totalJscp);\n setTotalRendi(totalRendi);\n setDataChart(proventoByMonth);\n }\n if (typeProventos === \"corretora\") {\n const proventoByMonth: any = [\n {\n name: \"Jan\",\n },\n {\n name: \"Fev\",\n },\n {\n name: \"Mar\",\n },\n {\n name: \"Abr\",\n },\n {\n name: \"Mai\",\n },\n {\n name: \"Jun\",\n },\n {\n name: \"Jul\",\n },\n {\n name: \"Ago\",\n },\n {\n name: \"Set\",\n },\n {\n name: \"Out\",\n },\n {\n name: \"Nov\",\n },\n {\n name: \"Dez\",\n },\n ];\n const barsChart: any = [];\n\n const groupedProventos = _.groupBy(proventos, (item) => {\n return item.corretora;\n });\n\n for (const key in groupedProventos) {\n barsChart.push(key);\n const operations = groupedProventos[key];\n operations.forEach((el: any) => {\n if (Number(moment(el.date).format(\"YYYY\")) === yearProventos) {\n const month = Number(moment(el.date).format(\"M\"));\n if (\n el?.corporateActionTypeDescription?.toLowerCase() === \"rendimento\"\n ) {\n proventoByMonth[month - 1][key] =\n (proventoByMonth[month - 1][key] || 0) + el.grossAmount;\n }\n if (\n el?.corporateActionTypeDescription?.toLowerCase() === \"dividendo\" ||\n el?.corporateActionTypeDescription?.toLowerCase() === \"dividendos\"\n ) {\n proventoByMonth[month - 1][key] =\n (proventoByMonth[month - 1][key] || 0) + el.grossAmount;\n }\n if (\n el?.corporateActionTypeDescription?.toLowerCase() ===\n \"juros sobre capital próprio\"\n ) {\n proventoByMonth[month - 1][key] =\n (proventoByMonth[month - 1][key] || 0) + el.grossAmount;\n }\n if (\n el?.corporateActionTypeDescription?.toLowerCase() ===\n \"amortização\"\n ) {\n proventoByMonth[month - 1][key] =\n (proventoByMonth[month - 1][key] || 0) + el.grossAmount;\n }\n if (\n el?.corporateActionTypeDescription?.toLowerCase() ===\n \"cupom\"\n ) {\n proventoByMonth[month - 1][key] =\n (proventoByMonth[month - 1][key] || 0) + el.grossAmount;\n }\n }\n });\n }\n\n setBars(barsChart);\n setDataChart(proventoByMonth);\n }\n if (typeProventos === \"data\") {\n const proventoByMonth: any = [\n {\n name: \"Jan\",\n futuro: 0,\n liquidado: 0,\n },\n {\n name: \"Fev\",\n futuro: 0,\n liquidado: 0,\n },\n {\n name: \"Mar\",\n futuro: 0,\n liquidado: 0,\n },\n {\n name: \"Abr\",\n futuro: 0,\n liquidado: 0,\n },\n {\n name: \"Mai\",\n futuro: 0,\n liquidado: 0,\n },\n {\n name: \"Jun\",\n futuro: 0,\n liquidado: 0,\n },\n {\n name: \"Jul\",\n futuro: 0,\n liquidado: 0,\n },\n {\n name: \"Ago\",\n futuro: 0,\n liquidado: 0,\n },\n {\n name: \"Set\",\n futuro: 0,\n liquidado: 0,\n },\n {\n name: \"Out\",\n futuro: 0,\n liquidado: 0,\n },\n {\n name: \"Nov\",\n futuro: 0,\n liquidado: 0,\n },\n {\n name: \"Dez\",\n futuro: 0,\n liquidado: 0,\n },\n ];\n const types = [\n \"rendimento\",\n \"juros sobre capital próprio\",\n \"dividendo\",\n \"dividendos\",\n \"amortização\",\n \"cupom\",\n \"cupom\",\n ];\n\n proventos?.forEach((el: any) => {\n const year = Number(moment(el.date).format(\"Y\"));\n if (\n year === yearProventos &&\n types.includes(el.corporateActionTypeDescription.toLowerCase())\n ) {\n const month = Number(moment(el.date).format(\"M\"));\n if (el.isFuturo) {\n proventoByMonth[month - 1].futuro += el.grossAmount;\n } else {\n proventoByMonth[month - 1].liquidado += el.grossAmount;\n }\n }\n });\n setDataChart(proventoByMonth);\n }\n setLoading(false);\n }, [yearProventos, typeProventos, proventos]);\n\n const renderLegend = (value: string, entry: any) => {\n return {value};\n };\n\n const labelFormatter = (value: any) => {\n return value > 0\n ? hideValues\n ? \"R$ ***\"\n : \"R$ \" +\n value?.toLocaleString(\"pt-br\", {\n minimumFractionDigits: 2,\n maximumFractionDigits: 2,\n })\n : \"\";\n };\n\n const renderTooltip = (value: any) => {\n const { payload } = value;\n\n const verificacaoValorFinal = payload?.reduce(\n (acumulador: any, item: any) => {\n if (item.value !== undefined) {\n return acumulador + item.value;\n }\n return acumulador;\n },\n 0\n );\n\n if (\n typeProventos === \"provento\" &&\n payload?.[0] &&\n verificacaoValorFinal !== 0\n ) {\n const total =\n payload[0]?.payload?.dividendo +\n payload[0]?.payload?.rendimento +\n payload[0]?.payload?.juros +\n payload[0]?.payload?.amortizacao +\n payload[0]?.payload?.bonds;\n return (\n <>\n
\n {payload[0]?.payload?.dividendo > 0 && (\n \n Dividendos: R${\" \"}\n {payload[0]?.payload?.dividendo.toLocaleString(\"pt-br\", {\n minimumFractionDigits: 2,\n maximumFractionDigits: 2,\n })}{\" \"}\n (\n {total > 0\n ? ((payload[0]?.payload?.dividendo * 100) / total).toFixed(2)\n : 0}\n %)\n \n )}\n {payload[0]?.payload?.rendimento > 0 && (\n \n Rendimento: R${\" \"}\n {payload[0]?.payload?.rendimento.toLocaleString(\"pt-br\", {\n minimumFractionDigits: 2,\n maximumFractionDigits: 2,\n })}{\" \"}\n (\n {total > 0\n ? ((payload[0]?.payload?.rendimento * 100) / total).toFixed(2)\n : 0}\n %)\n \n )}\n {payload[0]?.payload?.juros > 0 && (\n \n Juros sobre capital próprio: R${\" \"}\n {payload[0]?.payload?.juros.toLocaleString(\"pt-br\", {\n minimumFractionDigits: 2,\n maximumFractionDigits: 2,\n })}{\" \"}\n (\n {total > 0\n ? ((payload[0]?.payload?.juros * 100) / total).toFixed(2)\n : 0}\n %)\n \n )}\n {payload[0]?.payload?.amortizacao > 0 && (\n \n Amortização: R${\" \"}\n {payload[0]?.payload?.amortizacao.toLocaleString(\"pt-br\", {\n minimumFractionDigits: 2,\n maximumFractionDigits: 2,\n })}{\" \"}\n (\n {total > 0\n ? ((payload[0]?.payload?.amortizacao * 100) / total).toFixed(\n 2\n )\n : 0}\n %)\n \n )}\n {payload[0]?.payload?.bonds > 0 && (\n \n Cupom: R${\" \"}\n {payload[0]?.payload?.bonds.toLocaleString(\"pt-br\", {\n minimumFractionDigits: 2,\n maximumFractionDigits: 2,\n })}{\" \"}\n (\n {total > 0\n ? ((payload[0]?.payload?.bonds * 100) / total).toFixed(2)\n : 0}\n %)\n \n )}\n
\n \n );\n }\n if (typeProventos === \"corretora\" && payload?.[0]) {\n const keys = Object.keys(payload[0]?.payload || {});\n let total = 0;\n keys.forEach((el) => {\n if (el !== \"name\") {\n total += payload[0]?.payload[el] || 0;\n }\n });\n\n return (\n
\n {keys.map((el) => {\n if (el !== \"name\") {\n return (\n \n {el}: R${\" \"}\n {payload[0]?.payload[el].toLocaleString(\"pt-br\", {\n minimumFractionDigits: 2,\n maximumFractionDigits: 2,\n })}{\" \"}\n (\n {total > 0\n ? ((payload[0]?.payload[el] * 100) / total).toFixed(2)\n : 0}\n %)\n \n );\n }\n return <>;\n })}\n
\n );\n }\n if (typeProventos === \"data\" && payload?.[0]) {\n const total =\n payload[0]?.payload?.futuro + payload[0]?.payload?.liquidado;\n return (\n <>\n
\n \n Futuro: R${\" \"}\n {payload[0]?.payload?.futuro?.toLocaleString(\"pt-br\", {\n minimumFractionDigits: 2,\n maximumFractionDigits: 2,\n })}{\" \"}\n (\n {total > 0\n ? ((payload[0]?.payload?.futuro * 100) / total).toFixed(2)\n : 0}\n %)\n \n \n Liquidado: R${\" \"}\n {payload[0]?.payload?.liquidado.toLocaleString(\"pt-br\", {\n minimumFractionDigits: 2,\n maximumFractionDigits: 2,\n })}{\" \"}\n (\n {total > 0\n ? ((payload[0]?.payload?.liquidado * 100) / total).toFixed(2)\n : 0}\n %)\n \n
\n \n );\n }\n return <>;\n };\n return loading ? (\n \n ) : (\n \n \n \n \n \n \n {typeProventos === \"provento\" && (\n <>\n {totalJscp > 0 && (\n \n )}\n {totalRendi > 0 && (\n \n )}\n {totalDiv > 0 && (\n \n )}\n {totalAmort > 0 && (\n \n )}\n {totalBonds > 0 && (\n \n )}\n {!isMobile() && (\n \n )}\n \n )}\n {typeProventos === \"corretora\" && (\n <>\n {bars.map((el, index) => {\n return (\n \n );\n })}\n {!isMobile() && (\n \n )}\n \n )}\n {typeProventos === \"data\" && (\n <>\n \n \n {!isMobile() && (\n \n )}\n \n )}\n \n \n );\n};\n","import styled from \"styled-components\";\n\nexport const BlurContent: any = styled.div`\n .recharts-responsive-container {\n filter: ${(props: any) => (!props.hasPlan ? \"blur(10px)\" : \"\")};\n }\n height: 100%;\n margin-top: 8px;\n position: relative;\n user-select: none;\n border-radius: 4px;\n .blur-content {\n opacity: 0.5;\n filter: blur(4px);\n }\n .blur-content-title {\n z-index: 1;\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n padding: 0 100px;\n font-weight: 500;\n font-size: 1.25rem;\n text-align: center;\n row-gap: 16px;\n display: flex;\n align-items: center;\n flex-direction: column;\n justify-content: center;\n color: var(--velotax-font-color-light);\n }\n\n @media only screen and (max-device-width: 812px) {\n .blur-content-title {\n padding: 0 16px;\n font-size: 1rem;\n }\n }\n`;\n\nexport const ContainerProventos: any = styled.div`\n @media only screen and (max-device-width: 812px) {\n .recharts-responsive-container\n .recharts-legend-wrapper\n .recharts-legend-item\n .recharts-legend-item-text {\n max-width: 100%;\n }\n }\n height: 400px;\n width: 100%;\n .container-tooltip {\n width: 350px;\n display: flex;\n flex-direction: column;\n background-color: white;\n margin-top: 5px;\n padding: 5px;\n }\n .recharts-default-legend {\n display: inline !important;\n li {\n margin-right: 15px !important;\n }\n }\n .recharts-bar-rectangle {\n cursor: pointer;\n }\n .ant-select-selection-placeholder {\n display: flex;\n align-items: center;\n }\n\n .recharts-surface {\n margin-left: 0px !important;\n }\n\n span.recharts-legend-item-text span {\n color: white !important;\n }\n\n .recharts-legend-wrapper {\n left: 10px !important;\n }\n\n .recharts-responsive-container .recharts-wrapper .recharts-legend-wrapper {\n width: 100% !important;\n }\n\n .recharts-layer > text {\n font-size: 12px;\n font-weight: 400;\n fill: black;\n }\n .ant-btn {\n border-radius: 10px;\n align-items: center;\n display: flex;\n }\n .filter-proventos {\n width: 100%;\n display: flex;\n margin-bottom: 16px;\n button.ant-btn.ant-btn-default {\n height: 40px;\n svg.fill {\n fill: var(--ant-primary-color);\n }\n }\n .ant-select {\n height: 38px;\n font-size: 16px;\n margin-right: 8px;\n .ant-select-selector {\n height: 38px;\n }\n }\n .ant-select:not(:first-of-type) {\n margin-right: auto;\n }\n .proventos-btns {\n display: flex;\n column-gap: 8px;\n align-items: center;\n button.ant-btn {\n min-width: 32px;\n font-size: 14px;\n font-weight: 500;\n padding: 5px 12px;\n border-radius: 4px;\n border-radius: 24px;\n display: inline-flex;\n height: 38px !important;\n background-color: var(--white);\n color: var(--velotax-font-color-dark);\n border: 2px solid var(--velotax-ghost-white) !important;\n svg {\n width: 18px;\n height: 18px;\n fill: var(--ant-primary-color);\n stroke: var(--ant-primary-color);\n &.fill {\n path {\n stroke: var(--ant-primary-color);\n }\n }\n }\n }\n }\n }\n @media only screen and (max-device-width: 812px) {\n .filter-proventos {\n flex-wrap: wrap;\n .ant-select:first-of-type {\n width: 25%;\n }\n .ant-select:not(:first-of-type) {\n margin-right: 0;\n width: calc(75% - 8px);\n }\n .proventos-btns {\n width: 100%;\n margin-top: 8px;\n button.ant-btn.ant-btn-text {\n width: 50%;\n }\n }\n }\n }\n`;\n\nexport const Content = styled.div`\n width: 100% !important;\n .ant-tooltip {\n z-index: 999;\n }\n &.velotax-content {\n padding: 24px 0 48px !important;\n }\n .download-report-btn {\n padding: 5px;\n border-radius: 4px;\n display: inline-flex;\n height: 32px !important;\n background-color: var(--white);\n color: var(--velotax-font-color-dark);\n width: auto;\n border: 1px solid var(--white);\n border-radius: 60px;\n svg {\n width: 20px;\n height: 20px;\n fill: var(--ant-primary-color) !important;\n }\n }\n .range {\n display: flex;\n justify-content: space-between;\n\n div.ant-typography {\n font-size: 13px;\n }\n }\n .isentometro {\n margin-bottom: 5px;\n font-size: 14px;\n }\n .box {\n margin: 50px 0px;\n }\n .overview {\n color: var(--ant-primary-color);\n font-size: 18px;\n font-weight: bold;\n }\n .ant-progress-success-bg {\n background-color: var(--ant-primary-color);\n height: 13px !important;\n }\n .ant-progress-inner {\n height: 13px !important;\n }\n .ant-progress-bg {\n height: 13px !important;\n }\n & > .ant-collapse {\n border: none;\n & > .ant-collapse-item.ativos-categoria {\n margin-bottom: 48px;\n &:last-of-type {\n margin-bottom: 0;\n }\n & > .ant-collapse-header {\n padding: 0;\n align-items: center;\n .ant-collapse-arrow {\n right: 0;\n }\n h2 {\n margin: 0;\n font-weight: 700;\n font-size: 1.125rem;\n line-height: 1.5rem;\n color: var(--ant-primary-color);\n }\n .collapse-title-divider {\n flex-grow: 1;\n display: block;\n margin: 0 16px;\n border-bottom: 2px solid #efefef;\n }\n .collapse-title-hidden {\n width: 24px;\n height: 24px;\n display: block;\n visibility: hidden;\n }\n }\n & > .ant-collapse-content {\n border: none;\n background-color: transparent;\n & > .ant-collapse-content-box {\n padding: 24px 0 0;\n & > .ant-collapse {\n border: none;\n }\n & > div {\n font-size: 13px;\n }\n }\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n width: 100%;\n margin-bottom: 0;\n border-radius: 0;\n &.velotax-content {\n padding: 24px 0 96px !important;\n }\n\n h1,\n h2 {\n padding: 0;\n }\n }\n`;\n","import styled from \"styled-components\";\n\nexport const ContainerModal: any = styled.div`\n width: 100%;\n .ant-typography {\n color: var(--velotax-font-color-dark);\n }\n .container-table {\n width: 100%;\n overflow-y: auto;\n .ant-table-thead {\n .ant-table-cell {\n font-weight: bold;\n }\n }\n }\n .year-resume {\n width: 100%;\n display: flex;\n margin: 16px 0;\n padding: 20px 24px;\n border-radius: 12px;\n background-color: #ededed;\n justify-content: space-between;\n .ant-typography {\n font-size: 15px;\n margin: 0px;\n font-weight: 900;\n }\n }\n .container-1 {\n gap: 8px;\n width: 100%;\n display: flex;\n justify-content: space-between;\n .ant-btn {\n display: flex;\n align-items: center;\n border-radius: 10px;\n }\n .ant-select {\n color: var(--velotax-font-color-dark) !important;\n .ant-select-arrow {\n .anticon {\n color: var(--velotax-font-color-dark);\n }\n }\n .ant-select-selector {\n height: 40px;\n border-radius: 4px !important;\n border: 1px solid #e8e8e8 !important;\n background-color: #e8e8e8 !important;\n .ant-select-selection-search,\n .ant-select-selection-item,\n .ant-select-selection-search input {\n font-size: 15px !important;\n font-weight: 900 !important;\n }\n }\n .ant-select-dropdown {\n border: none;\n border-radius: 2px;\n background-color: var(--white) !important;\n box-shadow: 0 3px 6px -4px rgba(0, 0, 0, 0.12),\n 0 6px 16px 0 rgba(0, 0, 0, 0.08), 0 9px 28px 8px rgba(0, 0, 0, 0.05);\n .ant-select-item {\n background-color: var(--white);\n color: var(--velotax-font-color-dark);\n :hover {\n background-color: #e8e8e8 !important;\n }\n }\n .ant-select-item-option-selected {\n font-weight: bold;\n background-color: #abaaa8 !important;\n color: var(--velotax-font-color-dark) !important;\n :hover {\n background-color: #abaaa8 !important;\n }\n }\n }\n }\n }\n .client-wallet-header-btns {\n display: flex;\n column-gap: 8px;\n align-items: center;\n .ant-btn {\n height: 32px;\n min-width: 32px;\n font-weight: 500;\n box-shadow: none;\n border-radius: 24px;\n border: 1px solid #e8e8e8;\n &.filtro-aplicado {\n color: var(--ant-primary-color);\n border: 1px solid var(--ant-primary-color);\n background-color: var(--ant-primary-1);\n }\n svg {\n fill: none;\n width: 18px;\n height: 18px;\n stroke: var(--ant-primary-color);\n &.fill {\n path {\n stroke: var(--ant-primary-color);\n }\n }\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n .container-1 {\n flex-direction: column;\n .client-wallet-header-btns {\n width: 100%;\n .ant-select {\n width: 35%;\n }\n .ant-select:first-of-type {\n width: calc(65% - 8px);\n }\n .ant-btn {\n width: calc(50% - 4px);\n }\n }\n }\n .container-table {\n .ant-pagination.ant-table-pagination {\n right: 24px;\n position: fixed;\n }\n }\n }\n`;\n","import { Drawer, DrawerProps, Modal, ModalProps } from \"antd\";\nimport { isMobile } from \"../../utils\";\ntype getContainerFunc = () => HTMLElement;\n\nexport interface DrawerModalProps\n extends Omit,\n Omit {\n visible?: boolean;\n getContainer?: string | HTMLElement | getContainerFunc | false;\n onCancel?: (e: any) => void;\n}\n\nexport const DrawerModal: React.FC = ({\n height,\n visible,\n onCancel,\n children,\n className,\n ...props\n}) => {\n return isMobile() ? (\n \n {children}\n \n ) : (\n \n {children}\n \n );\n};\n","import styled from \"styled-components\";\n\nexport const ReportTypeContainer = styled.div`\n display: flex;\n flex-direction: column;\n gap: 20px;\n width: 100%;\n height: 100%;\n\n .divider {\n width: 100%;\n max-width: 80px;\n background-color: var(--ant-primary-color);\n height: 2px;\n margin-bottom: 1rem;\n }\n\n .loading {\n display: flex;\n\n h5 {\n margin-left: 1rem;\n }\n }\n\n .textInfo {\n display: flex;\n align-items: start;\n gap: 12px;\n padding: 2px;\n font-size: 11px;\n color: var(--gray-2);\n svg {\n fill: var(--black) !important;\n }\n }\n\n button.MuiButtonBase-root.buttonDownload {\n font-size: 12px !important;\n text-transform: none !important;\n }\n\n button.MuiButtonBase-root.white {\n font-size: 12px !important;\n text-transform: none !important;\n svg {\n fill: var(--white) !important;\n }\n }\n`;\n","import { Button } from \"@mui/material\";\nimport { Drawer, Typography } from \"antd\";\nimport { AiOutlineArrowLeft, AiOutlineDownload } from \"react-icons/ai\";\nimport { InfoCircleOutlined, LoadingOutlined } from \"@ant-design/icons\";\nimport { isMobile } from \"../../utils\";\nimport { ReportTypeContainer } from \"./styles\";\n\ninterface IProps {\n open: boolean;\n loading?: boolean;\n setType: Function;\n onClose:\n | ((\n e: React.MouseEvent | React.KeyboardEvent\n ) => void)\n | undefined;\n}\n\nexport const ReportTypeDrawer = ({\n open,\n loading,\n setType,\n onClose,\n}: IProps) => {\n return (\n }\n title={\n
\n Voltar\n
\n }\n {...(isMobile() ? { width: \"100%\" } : { width: \"420px\" })}\n >\n \n
\n \n Baixar\n \n
\n
\n
\n \n Qual tipo de arquivo deseja baixar?\n \n
\n
\n \n \n {\" \"}\n O arquivo baixado mostrará suas informações de acordo com os filtros\n selecionados no momento do download.\n \n
\n setType(\"pdf\")}\n startIcon={}\n >\n \n Arquivo em PDF \n {!isMobile() ? \" para simples conferência de dados.\" : \"\"}\n \n \n setType(\"xlsx\")}\n startIcon={}\n >\n \n Arquivo em Excel \n {!isMobile() ? \" para ser importado em planilhas.\" : \"\"}\n \n \n {loading && (\n \n )}\n \n \n );\n};\n","function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\nfunction _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\nimport * as React from \"react\";\nvar _ref2 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M12 3.33333H14M2 3.33333H9.33333M6.66667 8H14M2 8H4M12 12.6667H14M2 12.6667H9.33333M11.6095 2.39052C12.1302 2.91122 12.1302 3.75544 11.6095 4.27614C11.0888 4.79684 10.2445 4.79684 9.72385 4.27614C9.20315 3.75545 9.20315 2.91122 9.72385 2.39052C10.2445 1.86983 11.0888 1.86983 11.6095 2.39052ZM6.27614 7.0572C6.79684 7.5779 6.79684 8.42212 6.27614 8.94282C5.75544 9.46352 4.91122 9.46352 4.39052 8.94282C3.86982 8.42212 3.86982 7.5779 4.39052 7.0572C4.91122 6.5365 5.75544 6.5365 6.27614 7.0572ZM11.6095 11.7239C12.1302 12.2446 12.1302 13.0888 11.6095 13.6095C11.0888 14.1302 10.2445 14.1302 9.72385 13.6095C9.20315 13.0888 9.20315 12.2446 9.72385 11.7239C10.2445 11.2032 11.0888 11.2032 11.6095 11.7239Z\",\n strokeWidth: 1.2,\n strokeLinecap: \"round\",\n strokeLinejoin: \"round\"\n});\nfunction SvgFiltro(_ref, svgRef) {\n var title = _ref.title,\n titleId = _ref.titleId,\n props = _objectWithoutProperties(_ref, [\"title\", \"titleId\"]);\n return /*#__PURE__*/React.createElement(\"svg\", _extends({\n width: 16,\n height: 16,\n viewBox: \"0 0 16 16\",\n fill: \"none\",\n xmlns: \"http://www.w3.org/2000/svg\",\n ref: svgRef,\n \"aria-labelledby\": titleId\n }, props), title ? /*#__PURE__*/React.createElement(\"title\", {\n id: titleId\n }, title) : null, _ref2);\n}\nvar ForwardRef = /*#__PURE__*/React.forwardRef(SvgFiltro);\nexport default __webpack_public_path__ + \"static/media/filtro.d769fa77.svg\";\nexport { ForwardRef as ReactComponent };","import clsx from \"clsx\";\nimport moment from \"moment\";\nimport React, { useState } from \"react\";\nimport { Form, List, message, Typography } from \"antd\";\nimport { VscClose } from \"react-icons/vsc\";\nimport { FaRegEdit } from \"react-icons/fa\";\nimport NumberFormat from \"react-number-format\";\nimport { InfoCircleOutlined } from \"@ant-design/icons\";\nimport apis from \"../../services/apis\";\nimport Button from \"../../components/Button\";\nimport { FooterModal } from \"../../components/FooterModal\";\nimport {\n currencyToNumber,\n errorMessage,\n formatCurrency,\n months,\n numberToPercentage,\n replaceDotByComma,\n zero,\n isValidDate,\n isMobile,\n getQuoteFortnight\n} from \"../../utils\";\nimport {\n validationDateIsOnReferenceMonth,\n validationDateIsOnReferenceMonthCompra,\n validationFieldRequired,\n validationNumberAllowNegativeField,\n validationNumberFieldPositive,\n} from \"../../utils/formValidations\";\nimport {\n CurrencyFormItem,\n DateFormItem,\n NumberFormItem,\n TextFormItem,\n SelectFormItem,\n} from \"../formItems\";\nimport { useBroker } from \"../../contexts/BrokerContext\";\n\n// import euaFlag from \"../../assets/united-states-of-america.png\";\n// import brazilFlag from \"../../assets/brazil.png\";\n\nexport const yearConfigPL4173 = 2024\n\nexport const historicoVendasEmptyText =\n \"Nenhuma operação de venda realizada neste mês\";\n\nexport enum FormCurrencyMode {\n BRL = \"R$\",\n USD = \"US$\",\n}\n\nexport enum FormMovimentTypeMode {\n VENDA = \"Venda de ativos\",\n JUROS = \"Juros de aplicações\",\n}\n\nexport enum FormMovimentTypeModeNew {\n VENDA = \"Venda de ativos\",\n JUROS = \"Juros de bonds\",\n DIVIDENDOS = \"Dividendos\",\n OUTROS = \"Outros rendimentos\",\n}\n\nexport const TipoMercado: { [key: string]: string } = {\n mercado: \"Mercado à vista\",\n mercadoAVista: \"Mercado a Vista\",\n mercadoOpcoes: \"Mercado de opções\",\n outros: \"Outros mercados\",\n mercadoFracionario: \"Merc. Fracionário\",\n opcaoCompra: \"Opção de Compra\",\n opcaoVenda: \"Opção de Venda\",\n dayTrade: \"Day Trade\",\n};\n\nexport const TipoOperacao: { [key: string]: string } = {\n comum: \"Comum\",\n daytrade: \"Day Trade\",\n fii: \"FII\",\n};\n\nexport enum YearResumeStatusFromBackEnum {\n PAYED = \"PAYED\",\n PENDING = \"PENDING\",\n REGULAR = \"REGULAR\",\n NOT_PAYED = \"NOT_PAYED\",\n}\n\nexport enum YearResumeStatusCSSClassEnum {\n PAYED = \"payed\",\n PENDING = \"pending\",\n REGULAR = \"not-payed\",\n NOT_PAYED = \"not-payed\",\n}\n\nexport enum YearResumeStatusColorEnum {\n PAYED = \"var(--ant-success-color)\",\n PENDING = \"var(--ant-error-color)\",\n REGULAR = \"var(--ant-info-color-disabled)\",\n NOT_PAYED = \"var(--ant-info-color-disabled)\",\n}\n\nexport enum YearResumeStatusTextEnum {\n PAYED = \"Imposto apurado\",\n PENDING = \"Imposto devido\",\n REGULAR = \"Não há imposto devido\",\n NOT_PAYED = \"DARF Emitido e não pago\",\n}\n\n\nexport interface IDarf {\n payed?: boolean;\n emitted?: boolean;\n multa: number;\n juros: number;\n totalAlienado: number;\n totalGanho: number;\n aliquotaDevida: number;\n impostoDevido: number;\n impostoAcumulado: number;\n totalImpostoDevido: number;\n memoriaCalculo: any[];\n regular?: boolean;\n status?: keyof typeof YearResumeStatusFromBackEnum;\n irrfExterior?: number; \n}\n\nexport interface IQuote {\n venda: number;\n compra: number;\n}\n\nexport interface IQuotes {\n [key: string]: IQuote;\n}\n\nexport const defaultDarf: IDarf = {\n totalAlienado: 0,\n impostoDevido: 0,\n impostoAcumulado: 0,\n totalImpostoDevido: 0,\n aliquotaDevida: 0,\n totalGanho: 0,\n juros: 0,\n multa: 0,\n memoriaCalculo: [],\n status: \"REGULAR\",\n};\n\nexport interface IDarfBolsa {\n payed?: boolean;\n emitted?: boolean;\n aliquotaComum?: number;\n aliquotaDT?: number;\n aliquotaFII?: number;\n alienacoesComum?: number;\n alienacoesDT?: number;\n alienacoesFII?: number;\n ganhoComum?: number;\n ganhoDT?: number;\n ganhoFII?: number;\n impostoComumFinal?: number;\n impostoDTFinal?: number;\n impostoFIIFinal?: number;\n impostoTotal?: number;\n impostoTotalFinal?: number;\n irrfComum?: number;\n irrfDayTrade?: number;\n irrfFII?: number;\n irrfTotal?: number;\n irrfExterior?: number;\n jurosAux?: number;\n mercadoOpcoesComum?: number;\n mercadoOpcoesDT?: number;\n mercadoOutrosComum?: number;\n mercadoOutrosDT?: number;\n mercadoOutrosFII?: number;\n mercadoVistaComum?: number;\n mercadoVistaDT?: number;\n multaAux?: number;\n memoriaCalculo: any[];\n impostoAcumulado?: number;\n impostoDevido?: number;\n multa?: number;\n juros?: number;\n prejuizoComum?: number;\n prejuizoDayTrade?: number;\n prejuizoFII?: number;\n userPrejuizoComum?: number;\n userPrejuizoDayTrade?: number;\n userPrejuizoFII?: number;\n userIrrfComum?: number;\n userIrrfDayTrade?: number;\n userIrrfFII?: number;\n userIrrfTotal?: number;\n varTotaisComum?: number;\n varTotaisDT?: number;\n varTotaisFII?: number;\n}\n\nexport const defaultDarfBolsa: IDarfBolsa = {\n alienacoesComum: 0,\n alienacoesDT: 0,\n alienacoesFII: 0,\n impostoComumFinal: 0,\n impostoDTFinal: 0,\n impostoFIIFinal: 0,\n impostoTotal: 0,\n impostoTotalFinal: 0,\n irrfComum: 0,\n irrfDayTrade: 0,\n irrfFII: 0,\n irrfTotal: 0,\n jurosAux: 0,\n mercadoOpcoesDT: 0,\n mercadoOutrosComum: 0,\n mercadoOutrosDT: 0,\n mercadoVistaComum: 0,\n mercadoVistaDT: 0,\n multaAux: 0,\n memoriaCalculo: [],\n impostoAcumulado: 0,\n prejuizoComum: 0,\n prejuizoDayTrade: 0,\n prejuizoFII: 0,\n};\n\nexport const minDarfPrice = 10;\nexport const maxDarfPrice = 10000;\nexport const maxPixValue = 10000;\nexport const maxPixPayment = 10000;\nexport const maxCreditCardPayment = 10000;\n\nconst MultaModalProps = {\n title: \"Multa de Atraso\",\n content: (\n
\n

\n O pagamento dos impostos deve ser feito sempre até o último dia útil do\n mês subsequente aos ganhos realizados.\n

\n

\n Caso você tenha atrasado no pagamento do seu DARF, a sua multa de atraso\n será de 0,33% por dia de atraso (chegando, no máximo, a 20%) sobre o\n valor do principal, calculados a partir do primeiro dia útil depois do\n dia do vencimento do DARF.\n

\n
\n ),\n};\n\nconst JurosModalProps = {\n title: \"Juros de Atraso\",\n content: (\n
\n

\n O pagamento dos impostos deve ser feito sempre até o último dia útil do\n mês subsequente aos ganhos realizados.\n

\n

\n Caso você tenha atrasado no pagamento do seu DARF, os seus juros de\n atraso serão equivalentes a taxa Selic acumulada até o mês anterior ao\n do pagamento, mais 1% no mês do pagamento, sobre o valor principal,\n contados a partir do mês subsequente ao vencimento do DARF.\n

\n
\n ),\n};\n\nexport const MinPriceModalProps = {\n title: <>DARF abaixo de {formatCurrency(minDarfPrice)},\n content: (\n
\n

\n O sistema da Receita Federal não permite a emissão de um único DARF com\n valor abaixo de {formatCurrency(minDarfPrice)}.\n

\n

\n Caso seu DARF tenha ficado com um valor abaixo de{\" \"}\n {formatCurrency(minDarfPrice)}, o valor será repassado automaticamente\n para o mês seguinte e ficará visível no campo{\" \"}\n \n DARFs passados abaixo de {formatCurrency(minDarfPrice)}\n \n .\n

\n
\n ),\n};\n\nconst AliquotaModalProps = {\n title: \"Alíquota sobre ganhos com ativos no exterior\",\n content: (\n
\n

\n Caso o valor total vendido no mês seja superior a R$ 35 mil, os ganhos\n obtidos serão tributados a título de ganho de capital. As alíquotas\n (percentuais) aplicadas sobre o lucro são progressivas:\n

\n \n \n a) 15% sobre a parcela dos ganhos que não ultrapassar R$ 5.000.000,00;\n \n \n b) 17,5% sobre a parcela dos ganhos que exceder R$ 5.000.000,00 e não\n ultrapassar R$ 10.000.000,00;\n \n \n c) 20% sobre a parcela dos ganhos que exceder R$ 10.000.000,00 e não\n ultrapassar R$ 30.000.000,00; e\n \n \n d) 22,5% sobre a parcela dos ganhos que ultrapassar R$ 30.000.000,00.\n \n \n
\n ),\n};\n\nconst EmitirDarfModalProps = (onCancel: () => void, onOk: () => void) => ({\n title: \"Você confirma a emissão do DARF?\",\n footer: ,\n content: (\n
\n

\n O arquivo gerado ficará disponível na aba Histórico e será enviado para\n o seu e-mail cadastrado.\n

\n
\n ),\n});\n\nconst ReemitirDarfModalProps = (onCancel: () => void, onOk: () => void) => ({\n title: \"Você confirma a emissão de um novo DARF?\",\n footer: ,\n content: (\n
\n

\n Ao confirmar, o DARF anterior será substituido. O arquivo gerado\n ficará disponível na aba Histórico e será enviado para o seu e-mail\n cadastrado.\n

\n
\n ),\n});\n\nexport const DarfModal = (\n reemit: boolean,\n onCancel: () => void,\n onOk: () => void\n) =>\n reemit\n ? ReemitirDarfModalProps(onCancel, onOk)\n : EmitirDarfModalProps(onCancel, onOk);\n\ninterface IEdit {\n value: any;\n id: string;\n isEditting: boolean;\n}\ninterface DarfResultDescriptionsProps {\n id: string;\n label: (onClick: Function) => React.ReactNode;\n Component: React.FC<{\n data: IDarf | IDarfBolsa;\n url: string;\n year: number;\n month: number;\n loading: boolean;\n disabled: boolean;\n view?: boolean;\n handleEdit?: Function;\n setDataCripto?: React.Dispatch>;\n setDataBolsa?: React.Dispatch>;\n }>;\n}\n\nexport const DarfResultDescriptionsExterior: DarfResultDescriptionsProps[] = [\n {\n id: \"impostoDevido\",\n label: () => \"(+) Valor do principal\",\n Component: ({ data, view, year, month }) =>\n formatCurrency(\n Math.max((Number(data[\"impostoDevido\"] || 0) + ((year < yearConfigPL4173 || month == 0) ? Number(data[\"impostoAcumulado\"] || 0) : 0\n )) - Number(data[\"irrfExterior\"] || 0), 0)\n ),\n },\n {\n id: \"impostoDevido\",\n label: () => (\n \n (+) Imposto devido\n
\n ),\n Component: ({ data, view }) =>\n formatCurrency(Number(data[\"impostoDevido\"] || 0)),\n },\n {\n id: \"impostoAcumulado\",\n label: (onClick: any) => (\n \n (+) DARFs passados abaixo de R$ {minDarfPrice}\n }\n onClick={() => onClick(MinPriceModalProps)}\n />\n \n ),\n Component: ({\n data,\n year,\n month,\n loading,\n disabled,\n setDataBolsa,\n setDataCripto,\n url,\n }) => {\n const { currentPage } = useBroker();\n const [edit, setEdit] = useState();\n const [editForm] = Form.useForm();\n const handleEditValue = (id: string) => {\n const value = data[id as keyof (IDarf | IDarfBolsa)];\n setEdit({ id, isEditting: true, value });\n editForm.setFieldsValue({ [id]: value });\n };\n\n const handleEditValueCancel = () => {\n setEdit(undefined);\n editForm.resetFields();\n };\n const handleEditValueConfirm = () => {\n if (edit && edit.value >= 0 && edit.value < minDarfPrice) {\n (currentPage?.api || apis)\n .post(`${url}/updateDataDarf`, {\n year,\n month: month + 1,\n [edit.id]: edit.value,\n })\n .then(() =>\n (setDataCripto ?? setDataBolsa)?.((data: any) => ({\n ...data,\n [edit.id]: edit.value,\n }))\n )\n .catch(() => message.error(errorMessage))\n .finally(() => handleEditValueCancel());\n } else {\n handleEditValueCancel();\n }\n };\n return edit && edit.isEditting && edit.id === \"impostoAcumulado\" ? (\n
\n {!isMobile() && (\n \n {isMobile() && (\n
\n ) : (\n \n {formatCurrency(Number(data.impostoAcumulado || 0))}\n {(disabled && year < yearConfigPL4173) && (\n }\n onClick={() => handleEditValue(\"impostoAcumulado\")}\n />\n )}\n \n );\n },\n },\n {\n id: \"irrfTotal\",\n label: () => (\n \n (-) Imposto de Renda Retido na Fonte\n \n ),\n Component: ({ data, handleEdit }) => (\n
\n {formatCurrency(\n Number(\n (data as IDarfBolsa)[\"userIrrfTotal\"] ||\n (data as IDarfBolsa)[\"irrfTotal\"] ||\n 0\n )\n )}\n }\n onClick={() => handleEdit?.()}\n />\n
\n ),\n },\n {\n id: \"irrfExterior\",\n label: () => (\n \n (-) Imposto de Renda Retido na Fonte\n \n ),\n Component: ({ data, handleEdit }) => {\n return (\n
\n {formatCurrency(\n Number(\n (data as IDarfBolsa)[\"irrfExterior\"] ||\n 0\n )\n )}\n {/* }\n onClick={() => handleEdit?.()}\n /> */}\n
\n )},\n },\n {\n id: \"multa\",\n label: (onClick: any) => (\n
\n (+) Multa de atraso{\" \"}\n }\n onClick={() => onClick(MultaModalProps)}\n />\n
\n ),\n Component: ({ data }) =>\n formatCurrency(\n (data[\"impostoDevido\"] || 0) + (data[\"impostoAcumulado\"] || 0) - (data[\"irrfExterior\"] || 0) >=\n minDarfPrice\n ? Number(data[\"multa\"])\n : 0\n ),\n },\n {\n id: \"juros\",\n label: (onClick: any) => (\n
\n (+) Juros e/ou encargos de atraso{\" \"}\n }\n onClick={() => onClick(JurosModalProps)}\n />\n
\n ),\n Component: ({ data }) =>\n formatCurrency(\n (data[\"impostoDevido\"] || 0) + (data[\"impostoAcumulado\"] || 0) - (data[\"irrfExterior\"] || 0) >=\n minDarfPrice\n ? Number(data[\"juros\"])\n : 0\n ),\n },\n];\n\nexport const DarfResultDescriptions: DarfResultDescriptionsProps[] = [\n {\n id: \"impostoDevido\",\n label: () => \"(+) Valor do principal\",\n Component: ({ data, view }) =>\n formatCurrency(\n Number(data[\"impostoDevido\"] || 0) +\n Number(data[\"impostoAcumulado\"] || 0)\n ),\n },\n {\n id: \"impostoDevido\",\n label: () => (\n \n (+) Imposto devido\n \n ),\n Component: ({ data, view }) =>\n formatCurrency(Number(data[\"impostoDevido\"] || 0)),\n },\n {\n id: \"impostoAcumulado\",\n label: (onClick: any) => (\n \n (+) DARFs passados abaixo de R$ {minDarfPrice}\n }\n onClick={() => onClick(MinPriceModalProps)}\n />\n \n ),\n Component: ({\n data,\n year,\n month,\n loading,\n disabled,\n setDataBolsa,\n setDataCripto,\n url,\n }) => {\n const { currentPage } = useBroker();\n const [edit, setEdit] = useState();\n const [editForm] = Form.useForm();\n const handleEditValue = (id: string) => {\n const value = data[id as keyof (IDarf | IDarfBolsa)];\n setEdit({ id, isEditting: true, value });\n editForm.setFieldsValue({ [id]: value });\n };\n\n const handleEditValueCancel = () => {\n setEdit(undefined);\n editForm.resetFields();\n };\n const handleEditValueConfirm = () => {\n if (edit && edit.value >= 0 && edit.value < minDarfPrice) {\n (currentPage?.api || apis)\n .post(`${url}/updateDataDarf`, {\n year,\n month: month + 1,\n [edit.id]: edit.value,\n })\n .then(() =>\n (setDataCripto ?? setDataBolsa)?.((data: any) => ({\n ...data,\n [edit.id]: edit.value,\n }))\n )\n .catch(() => message.error(errorMessage))\n .finally(() => handleEditValueCancel());\n } else {\n handleEditValueCancel();\n }\n };\n return edit && edit.isEditting && edit.id === \"impostoAcumulado\" ? (\n
\n {!isMobile() && (\n \n {isMobile() && (\n
\n ) : (\n \n {formatCurrency(Number(data.impostoAcumulado || 0))}\n {disabled && (\n }\n onClick={() => handleEditValue(\"impostoAcumulado\")}\n />\n )}\n \n );\n },\n },\n {\n id: \"irrfTotal\",\n label: () => (\n \n (-) Imposto de Renda Retido na Fonte\n \n ),\n Component: ({ data, handleEdit }) => (\n
\n {formatCurrency(\n Number(\n (data as IDarfBolsa)[\"userIrrfTotal\"] ||\n (data as IDarfBolsa)[\"irrfTotal\"] ||\n 0\n )\n )}\n }\n onClick={() => handleEdit?.()}\n />\n
\n ),\n },\n {\n id: \"multa\",\n label: (onClick: any) => (\n
\n (+) Multa de atraso{\" \"}\n }\n onClick={() => onClick(MultaModalProps)}\n />\n
\n ),\n Component: ({ data }) =>\n formatCurrency(\n (data[\"impostoDevido\"] || 0) + (data[\"impostoAcumulado\"] || 0) >=\n minDarfPrice\n ? Number(data[\"multa\"])\n : 0\n ),\n },\n {\n id: \"juros\",\n label: (onClick: any) => (\n
\n (+) Juros e/ou encargos de atraso{\" \"}\n }\n onClick={() => onClick(JurosModalProps)}\n />\n
\n ),\n Component: ({ data }) =>\n formatCurrency(\n (data[\"impostoDevido\"] || 0) + (data[\"impostoAcumulado\"] || 0) >=\n minDarfPrice\n ? Number(data[\"juros\"])\n : 0\n ),\n },\n];\n\nexport const DarfImpostosDevidosDescriptions = [\n {\n id: \"totalGanho\",\n label: () => \"Ganho total\",\n },\n {\n id: \"prejuizoExterior\",\n label: () => \"(-) Prejuízos a compensar\",\n render: (data: any, view?: boolean, year?: number) => {\n return formatCurrency(Number(data[\"prejuizoExterior\"] || 0))\n },\n },\n {\n id: \"aliquotaDevida\",\n label: (onClick: any, year?: number) => (\n
\n (x) Alíquota devida\n {(year || 0) < yearConfigPL4173 && }\n onClick={() => onClick(AliquotaModalProps)}\n />}\n
\n ),\n render: (data: any, view?: any, year?: number) =>\n `${replaceDotByComma(\n Number(((year || 0) >= yearConfigPL4173 ? 15 : (data[\"aliquotaDevida\"] || 0)).toFixed(2))\n )} %`,\n },\n {\n id: \"impostoDevido\",\n label: () => \"Imposto devido\",\n render: (data: any, view?: boolean, year?: number) =>\n formatCurrency(\n !view\n ? Math.max(Number(data[\"impostoDevido\"]) || 0, 0) || Math.max(Number(data[\"totalImpostoDevido\"]) || 0, 0)\n : Math.max(Number(data[\"impostoDevido\"]) || 0, 0) || Math.max(Number(data[\"totalImpostoDevido\"]) || 0, 0)\n )\n },\n];\n\nconst FormItemsBolsa = {\n id: TextFormItem({\n name: \"id\",\n label: \"Id\",\n hidden: true,\n }),\n date: (month: number, year: number) =>\n DateFormItem({\n name: \"date\",\n label: `Dia do mês de ${months[month]}/${year}`,\n placeholder: `01/${zero(month + 1)}/${year}`,\n mask: `99/${zero(month + 1).replace(/[9]/g, `\\\\9`)}/${year\n .toString()\n .replace(/[9]/g, `\\\\9`)}`,\n rules: validationDateIsOnReferenceMonth(month, year),\n }),\n code: (placeholder: string) =>\n TextFormItem({\n name: \"code\",\n label: \"Ativo\",\n placeholder,\n rules: validationFieldRequired,\n }),\n quantity: (placeholder: string) =>\n NumberFormItem({\n name: \"quantity\",\n label: \"Quantidade\",\n placeholder,\n decimalScale: 12,\n rules: validationNumberFieldPositive,\n }),\n avgBuyPrice: CurrencyFormItem({\n name: \"avgBuyPrice\",\n label: \"Custo de compra\",\n }),\n price: CurrencyFormItem({ name: \"price\", label: \"Preço de venda\" }),\n feeB3: CurrencyFormItem({ name: \"feeB3\", label: \"Taxas\" }),\n capitalGain: CurrencyFormItem({\n name: \"capitalGain\",\n label: \"Ganho\",\n disabled: true,\n allowNegative: true,\n rules: validationNumberAllowNegativeField,\n onChange: (changed, values) => {\n const precoVenda = changed.price\n ? currencyToNumber(changed.price)\n : values.price;\n const custoCompra = changed.avgBuyPrice\n ? currencyToNumber(changed.avgBuyPrice)\n : values.avgBuyPrice;\n const taxas = changed.feeB3\n ? currencyToNumber(changed.feeB3)\n : values.feeB3;\n return Number(values.quantity) * (precoVenda - custoCompra) - taxas;\n },\n }),\n operacao: SelectFormItem({\n name: \"operacao\",\n label: \"Operação\",\n placeholder: \"Selecione\",\n options: [\n { label: \"Comum\", value: \"Comum\" },\n { label: \"Day Trade\", value: \"Day Trade\" },\n { label: \"Fundos Imobiliários\", value: \"FII\" },\n ],\n }),\n market: ({ data }: any) =>\n SelectFormItem({\n name: \"market\",\n label: \"Mercado\",\n placeholder: \"Selecione\",\n options: [\n { label: \"Mercado à vista\", value: \"Mercado a Vista\" },\n ...(data.operacao !== \"FII\"\n ? [\n { label: \"Mercado de opções\", value: \"Mercado de opções\" },\n { label: \"Outros mercados\", value: \"Outros mercados\" },\n ]\n : []),\n ],\n onChange: (changed, values) =>\n values.operacao === \"FII\" && values.market !== \"Mercado a Vista\"\n ? \"Mercado a Vista\"\n : values.market,\n }),\n};\n\n// const exchange = ({\n// changed,\n// values,\n// modeProp,\n// prop,\n// cotacaoProp,\n// }: {\n// changed: any;\n// values: any;\n// modeProp: string;\n// prop: string;\n// cotacaoProp: string;\n// }) => {\n// return changed.hasOwnProperty(modeProp)\n// ? values[cotacaoProp] && changed[modeProp]\n// ? values[prop] * values[cotacaoProp]\n// : values[prop] / values[cotacaoProp]\n// : changed[prop]\n// ? currencyToNumber(\n// changed[prop],\n// values[modeProp] !== false ? FormCurrencyMode.BRL : FormCurrencyMode.USD\n// )\n// : values[prop];\n// };\n\nconst FormItemsCrypto = {\n id: TextFormItem({\n name: \"id\",\n label: \"Id\",\n hidden: true,\n }),\n data: (month: number, year: number) =>\n DateFormItem({\n name: \"data\",\n label: `Dia do mês de ${months[month]}/${year}`,\n placeholder: `01/${zero(month + 1)}/${year}`,\n mask: `99/${zero(month + 1).replace(/[9]/g, `\\\\9`)}/${year\n .toString()\n .replace(/[9]/g, `\\\\9`)}`,\n rules: validationDateIsOnReferenceMonth(month, year),\n }),\n ativo: (placeholder: string) =>\n TextFormItem({\n name: \"ativo\",\n label: \"Ativo\",\n placeholder,\n rules: validationFieldRequired,\n }),\n quantidade: (placeholder: string) =>\n NumberFormItem({\n name: \"quantidade\",\n label: \"Quantidade\",\n placeholder,\n decimalScale: 12,\n rules: validationNumberFieldPositive,\n }),\n precoVenda: CurrencyFormItem({ name: \"precoVenda\", label: \"Preço de venda\" }),\n custoCompra: CurrencyFormItem({\n name: \"custoCompra\",\n label: \"Custo de compra\",\n }),\n taxas: CurrencyFormItem({ name: \"taxas\", label: \"Taxas\" }),\n ganho: CurrencyFormItem({\n name: \"ganho\",\n label: \"Ganho\",\n disabled: true,\n onChange: (changed, values) => {\n const precoVenda = changed.precoVenda\n ? currencyToNumber(changed.precoVenda)\n : values.precoVenda;\n const custoCompra = changed.custoCompra\n ? currencyToNumber(changed.custoCompra)\n : values.custoCompra;\n const taxas = changed.taxas\n ? currencyToNumber(changed.taxas)\n : values.taxas;\n return Number(\n Math.max(\n 0,\n Number(values.quantidade) * (precoVenda - custoCompra) - taxas\n ).toFixed(2)\n );\n },\n }),\n operacao: SelectFormItem({\n name: \"operacao\",\n label: \"Operação\",\n placeholder: \"Selecione\",\n options: [\n { label: \"Comum\", value: \"comum\" },\n { label: \"Day Trade\", value: \"daytrade\" },\n ],\n }),\n mercado: SelectFormItem({\n name: \"mercado\",\n label: \"Mercado\",\n placeholder: \"Selecione\",\n options: [\n { label: \"Mercado à vista\", value: \"mercado\" },\n { label: \"Mercado de opções\", value: \"mercadoOpcoes\" },\n { label: \"Outros mercados\", value: \"outros\" },\n ],\n }),\n};\n\nconst FormItemsExterior = {\n id: TextFormItem({\n name: \"id\",\n label: \"Id\",\n hidden: true,\n }),\n movimentType: (movimentType: any, setMovimentType: any, year: number, fromApi?: boolean) =>\n SelectFormItem({\n name: \"movimentType\",\n label: \"Tipo de movimentação\",\n value: movimentType,\n disabled: fromApi,\n defaultValue: FormMovimentTypeMode.VENDA,\n rules: [],\n options: year < yearConfigPL4173 \n ? [\n { label: \"Venda de ativos\", value: FormMovimentTypeMode.VENDA },\n { label: \"Juros de aplicações\", value: FormMovimentTypeMode.JUROS },\n ] \n : [\n { label: \"Venda de ativos\", value: FormMovimentTypeModeNew.VENDA },\n { label: \"Juros de bonds\", value: FormMovimentTypeModeNew.JUROS },\n { label: \"Dividendos\", value: FormMovimentTypeModeNew.DIVIDENDOS },\n { label: \"Outros rendimentos\", value: FormMovimentTypeModeNew.OUTROS },\n ],\n onChange(changed, values) {\n setMovimentType(\n changed.movimentType !== undefined\n ? changed.movimentType\n : movimentType\n );\n return changed.movimentType !== undefined\n ? changed.movimentType\n : movimentType;\n },\n }),\n ativo: (placeholder: string, fromApi?: boolean) =>\n TextFormItem({\n name: \"ativo\",\n label: \"Ativo\",\n disabled: fromApi,\n placeholder,\n rules: validationFieldRequired,\n }),\n valueOriginBRA: CurrencyFormItem({\n prefix: \"US$ \",\n name: \"valueOriginBRA\",\n label: \"Origem BRA (US$)\",\n placeholder: \"US$ 0,00\",\n }),\n valueOriginEUA: CurrencyFormItem({\n prefix: \"US$ \",\n name: \"valueOriginEUA\",\n label: \"Origem USA (US$)\",\n placeholder: \"US$ 0,00\",\n }),\n dataCompra: () =>\n DateFormItem({\n name: \"dataCompra\",\n label: \"Data da Liquidação\",\n placeholder: \"DD/MM/YYYY\",\n mask: `99/99/9999`,\n rules: validationDateIsOnReferenceMonthCompra,\n }),\n cotacaoCompra: (quotations: IQuotes) =>\n TextFormItem({\n disabled: true,\n name: \"cambioCompra\",\n label: \"Cotação dólar\",\n onChange: (changed, values) => {\n if (isValidDate(values.dataCompra)) {\n let i = 0;\n let keycompra = changed.dataCompra || values.dataCompra;\n const isComplete = !String(keycompra).includes(\"_\");\n if (!keycompra || !isComplete) return values.cotacaoCompra;\n while (isComplete && !quotations[keycompra] && i <= 10) {\n keycompra = moment(keycompra, \"DD/MM/YYYY\")\n .subtract(1, \"days\")\n .format(\"DD/MM/YYYY\");\n i++;\n }\n const { venda } = quotations[keycompra] || { venda: 0 };\n return venda;\n }\n },\n }),\n precoVenda: CurrencyFormItem({\n prefix: \"US$ \",\n name: \"valor\",\n placeholder: \"US$ 0,00\",\n label: \"Valor Bruto (US$)\",\n }),\n fee: CurrencyFormItem({\n name: \"fee\",\n label: \"Taxa de corretagem (US$)\",\n placeholder: \"US$ 0,00\",\n prefix: \"US$ \",\n }),\n dataVenda: (month: number, year: number) =>\n DateFormItem({\n name: \"data\",\n label: \"Data da Liquidação\",\n placeholder: `01/${zero(month + 1)}/${year}`,\n mask: `99/${zero(month + 1).replace(/[9]/g, `\\\\9`)}/${year\n .toString()\n .replace(/[9]/g, `\\\\9`)}`,\n rules: validationDateIsOnReferenceMonth(month, year),\n }),\n dataVendaFee: (month: number, year: number) =>\n DateFormItem({\n name: \"dataFee\",\n label: \"Data da Liquidação\",\n placeholder: `01/${zero(month + 1)}/${year}`,\n mask: `99/${zero(month + 1).replace(/[9]/g, `\\\\9`)}/${year\n .toString()\n .replace(/[9]/g, `\\\\9`)}`,\n rules: validationDateIsOnReferenceMonth(month, year),\n }),\n cotacaoVenda: (quotations: IQuotes) =>\n TextFormItem({\n disabled: true,\n name: \"cambioVenda\",\n label: \"Cotação dólar\",\n onChange: (changed, values) => {\n if (isValidDate(values.data)) {\n let i = 0;\n let keyvenda = changed.data || values.data;\n const isComplete = !String(keyvenda).includes(\"_\");\n if (!keyvenda || !isComplete) return values.cotacaoVenda;\n while ((isComplete && !quotations[keyvenda]) || i === 5) {\n keyvenda = moment(keyvenda, \"DD/MM/YYYY\")\n .subtract(1, \"days\")\n .format(\"DD/MM/YYYY\");\n i++;\n }\n const { compra } = quotations[keyvenda] || { compra: 0 };\n return compra;\n }\n },\n }),\n cotacaoVendaFee: (quotations: IQuotes) =>\n TextFormItem({\n disabled: true,\n name: \"cambioVendaFee\",\n label: \"Cotação dólar\",\n onChange: (changed, values) => {\n if (isValidDate(values.dataFee)) {\n let i = 0;\n let keyvenda = changed.dataFee || values.dataFee;\n const isComplete = !String(keyvenda).includes(\"_\");\n if (!keyvenda || !isComplete) return values.cotacaoVendaFee;\n while ((isComplete && !quotations[keyvenda]) || i === 5) {\n keyvenda = moment(keyvenda, \"DD/MM/YYYY\")\n .subtract(1, \"days\")\n .format(\"DD/MM/YYYY\");\n i++;\n }\n\n if (values.movimentType == 'Dividendos') {\n const day = keyvenda.split('/')[0];\n const month = keyvenda.split('/')[1];\n const year = keyvenda.split('/')[2];\n const dateToQuote = new Date(`${month}/${day}/${year}`);\n const cotacaoCompra = getQuoteFortnight(dateToQuote, quotations);\n return cotacaoCompra;\n }\n\n const { venda } = quotations[keyvenda] || { venda: 0 };\n return venda;\n }\n },\n }),\n ganho: CurrencyFormItem({\n name: \"ganho\",\n label: `Ganho (R$)`,\n disabled: true,\n rules: [],\n onChange: (changed, values) => {\n // TODO Atualmente há perda de centavos entre a conversão sucessiva entre BRL e USD\n let A = changed.valueOriginBRA\n ? currencyToNumber(changed.valueOriginBRA, \"US$\")\n : values.valueOriginBRA || 0;\n let B = changed.valueOriginEUA\n ? currencyToNumber(changed.valueOriginEUA, \"US$\")\n : values.valueOriginEUA || 0;\n const C = values.cambioCompra || 1;\n const D = changed.valor\n ? currencyToNumber(changed.valor, \"US$\")\n : values.valor || 0;\n const E = changed.fee\n ? currencyToNumber(changed.fee, \"US$\")\n : values.fee || 0;\n const F = values.cambioVenda || 1;\n\n const correctionZero = 1e-50;\n if (A === 0) A = correctionZero;\n if (B === 0) B = correctionZero;\n\n const ganho =\n (A / (A + B)) * (D - E) * F - A * C + ((B / (A + B)) * (D - E) - B) * F;\n\n return Number(Math.max(ganho, 0).toFixed(2));\n },\n }),\n ganhoFee: CurrencyFormItem({\n name: \"ganhoFee\",\n label: `Rendimento (R$)`,\n disabled: true,\n rules: [],\n onChange: (changed, values) => {\n // TODO Atualmente há perda de centavos entre a conversão sucessiva entre BRL e USD\n const A = values.cambioVendaFee || 1;\n\n const B = changed.valor\n ? currencyToNumber(changed.valor, \"US$\")\n : values.valor || 0;\n\n const C = changed.fee\n ? currencyToNumber(changed.fee, \"US$\")\n : values.fee || 0;\n\n const ganho = (B - C) * A;\n return Number(Math.max(ganho, 0).toFixed(2));\n },\n }),\n date: (month: number, year: number, fromApi?: boolean) =>\n DateFormItem({\n name: \"data\",\n disabled: fromApi,\n label: `Dia do mês de ${months[month]}/${year}`,\n placeholder: `01/${zero(month + 1)}/${year}`,\n mask: `99/${zero(month + 1).replace(/[9]/g, `\\\\9`)}/${year\n .toString()\n .replace(/[9]/g, `\\\\9`)}`,\n rules: validationDateIsOnReferenceMonth(month, year),\n }),\n quantidade: (placeholder: string, fromApi?: boolean) =>\n NumberFormItem({\n disabled: fromApi,\n name: \"quantidade\",\n label: \"Quantidade\",\n placeholder,\n decimalScale: 12,\n rules: validationNumberFieldPositive,\n }),\n valor: CurrencyFormItem({ name: \"sellPrice_BRL\", label: \"Preço de venda\" }),\n valorNewModel: (fromApi?: boolean) => \n CurrencyFormItem({ name: \"sellPrice_BRL\", disabled: fromApi, label: \"Preço de venda\" }),\n capitalGain: CurrencyFormItem({\n name: \"ganho\",\n label: \"Ganho\",\n disabled: true,\n allowNegative: true,\n rules: validationNumberAllowNegativeField,\n onChange: (changed, values) => {\n const precoVenda = changed.valor\n ? currencyToNumber(changed.valor)\n : values.valor;\n const custoCompra = changed.valueOriginBRA\n ? currencyToNumber(changed.valueOriginBRA)\n : values.valueOriginBRA;\n const taxas = changed.fee\n ? currencyToNumber(changed.fee)\n : values.fee;\n return Number(values.quantidade) * (precoVenda - custoCompra) - taxas;\n },\n }),\n capitalGainBRL: CurrencyFormItem({\n name: \"varTotalBRL\",\n label: \"Ganho\",\n disabled: true,\n allowNegative: true,\n rules: validationNumberAllowNegativeField,\n onChange: (changed, values) => {\n const precoVenda = changed.sellPrice_BRL\n ? currencyToNumber(changed.sellPrice_BRL)\n : values.sellPrice_BRL;\n const custoCompra = changed.buyPrice_BRL\n ? currencyToNumber(changed.buyPrice_BRL)\n : values.buyPrice_BRL;\n const taxas = changed.fee_BRL\n ? currencyToNumber(changed.fee_BRL)\n : values.fee_BRL;\n return Number(values.quantidade) * (precoVenda - custoCompra) - taxas;\n },\n }),\n valueOriginBRL: (fromApi?: boolean) => CurrencyFormItem({\n disabled: fromApi,\n prefix: \"R$ \",\n name: \"buyPrice_BRL\",\n label: \"Custo de Compra (R$)\",\n placeholder: \"R$ 0,00\",\n }),\n feeBRL: (fromApi?: boolean) => CurrencyFormItem({\n disabled: fromApi,\n name: \"fee_BRL\",\n label: \"Taxa de corretagem (R$)\",\n placeholder: \"R$ 0,00\",\n prefix: \"R$ \",\n }),\n};\n\nconst PrejuFormItems = {\n userPrejuizoComum: CurrencyFormItem({\n name: \"userPrejuizoComum\",\n label: \"Prejuízo Comum\",\n }),\n userPrejuizoDayTrade: CurrencyFormItem({\n name: \"userPrejuizoDayTrade\",\n label: \"Prejuízo Day Trade\",\n }),\n userPrejuizoFII: CurrencyFormItem({\n name: \"userPrejuizoFII\",\n label: \"Prejuízo FII\",\n }),\n};\n\nconst IrrfFormItem = {\n userIrrfComum: CurrencyFormItem({\n name: \"userIrrfComum\",\n label: \"IRRF Comum\",\n }),\n userIrrfDayTrade: CurrencyFormItem({\n name: \"userIrrfDayTrade\",\n label: \"IRRF Day Trade\",\n }),\n userIrrfFII: CurrencyFormItem({\n name: \"userIrrfFII\",\n label: \"IRRF FII\",\n }),\n userIrrfTotal: CurrencyFormItem({\n name: \"userIrrfTotal\",\n label: \"IRRF Total (Comum + Day Trade + FII)\",\n disabled: true,\n onChange: (changed, values) => {\n const userIrrfComum = changed.userIrrfComum\n ? currencyToNumber(changed.userIrrfComum)\n : values.userIrrfComum;\n const userIrrfDayTrade = changed.userIrrfDayTrade\n ? currencyToNumber(changed.userIrrfDayTrade)\n : values.userIrrfDayTrade;\n const userIrrfFII = changed.userIrrfFII\n ? currencyToNumber(changed.userIrrfFII)\n : values.userIrrfFII;\n return (\n Number(userIrrfComum ?? 0) +\n Number(userIrrfDayTrade ?? 0) +\n Number(userIrrfFII ?? 0)\n );\n },\n }),\n};\n\nexport const IrrfFormItemRows = [\n [IrrfFormItem.userIrrfComum],\n [IrrfFormItem.userIrrfDayTrade],\n [IrrfFormItem.userIrrfFII],\n [IrrfFormItem.userIrrfTotal],\n];\n\nexport const PrejuFormItemRows = [\n [PrejuFormItems.userPrejuizoComum],\n [PrejuFormItems.userPrejuizoDayTrade],\n [PrejuFormItems.userPrejuizoFII],\n];\n\nexport const DarfFormItemRows = (month: number, year: number) => [\n [FormItemsCrypto.id],\n [FormItemsCrypto.data(month, year), FormItemsCrypto.ativo(\"Ex: BTC\")],\n [FormItemsCrypto.quantidade(\"Ex: 0,00101\")],\n [FormItemsCrypto.precoVenda, FormItemsCrypto.custoCompra],\n [FormItemsCrypto.taxas],\n [FormItemsCrypto.ganho],\n];\n\nexport const ExteriorFormItemRows = (\n month: number,\n year: number,\n quotations: IQuotes,\n editAsset: any,\n asset: any,\n movimentType: string,\n setMovimentType: React.Dispatch>\n) => {\n return [\n asset && !asset?.valueOriginBRA\n ? []\n : asset\n ? [FormItemsExterior.ativo(\"Ex: Warren\")]\n : [\n FormItemsExterior.movimentType(movimentType, setMovimentType, year),\n FormItemsExterior.ativo(\"Ex: Warren\"),\n ],\n asset && !asset?.valueOriginBRA\n ? []\n : [\n {\n label: \"\",\n name: \"\",\n input: (\n
\n {movimentType === \"Juros de aplicações\" ? \"Juros\" : \"Compra\"}\n
\n ),\n },\n ],\n asset && !asset?.valueOriginBRA\n ? []\n : movimentType !== \"Juros de aplicações\"\n ? [FormItemsExterior.valueOriginBRA, FormItemsExterior.valueOriginEUA]\n : [],\n asset && !asset?.valueOriginBRA\n ? []\n : movimentType !== \"Juros de aplicações\"\n ? [\n FormItemsExterior.dataCompra(),\n FormItemsExterior.cotacaoCompra(quotations),\n ]\n : [],\n asset && !asset?.valueOriginBRA\n ? []\n : movimentType !== \"Juros de aplicações\"\n ? [\n {\n label: \"\",\n name: \"\",\n input:
Venda
,\n },\n ]\n : [],\n asset && !asset?.valueOriginBRA\n ? []\n : [FormItemsExterior.precoVenda, FormItemsExterior.fee],\n asset && !asset?.valueOriginBRA\n ? []\n : movimentType !== \"Juros de aplicações\"\n ? [\n FormItemsExterior.dataVenda(month, year),\n FormItemsExterior.cotacaoVenda(quotations),\n ]\n : [\n FormItemsExterior.dataVendaFee(month, year),\n FormItemsExterior.cotacaoVendaFee(quotations),\n ],\n asset && !asset?.valueOriginBRA\n ? []\n : movimentType !== \"Juros de aplicações\"\n ? [FormItemsExterior.ganho]\n : [FormItemsExterior.ganhoFee],\n ];\n};\n\nexport const ExteriorNewFormItemRows = (\n month: number,\n year: number,\n quotations: IQuotes,\n editAsset: any,\n asset: any,\n movimentType: string,\n setMovimentType: React.Dispatch>,\n fromApi?: boolean\n) => {\n return [\n asset ? [FormItemsExterior.ativo(\"Ex: GOOG\", fromApi)]\n : movimentType === \"Venda de ativos\" ? [FormItemsExterior.movimentType(movimentType, setMovimentType, year, fromApi)] \n : [\n FormItemsExterior.movimentType(movimentType, setMovimentType, year, fromApi),\n FormItemsExterior.ativo(\"Ex: GOOG\", fromApi),\n ],\n movimentType === \"Venda de ativos\" ? [] : [\n {\n label: \"\",\n name: \"\",\n input: (\n
\n {\n ['Juros de bonds'].includes(movimentType || '') ? \"Juros\" \n : ['Dividendos'].includes(movimentType || '') ? \"Dividendos\" \n : \"Rendimentos\"}\n
\n ),\n },\n ],\n movimentType === \"Venda de ativos\"\n ? [FormItemsExterior.date(month, year, fromApi), FormItemsExterior.ativo(\"Ex: GOOG\", fromApi)]\n : [],\n movimentType === \"Venda de ativos\"\n ? [\n FormItemsExterior.quantidade(\"Ex: 100\", fromApi),\n FormItemsExterior.valorNewModel(fromApi),\n ]\n : [],\n movimentType === 'Venda de ativos' ? [FormItemsExterior.valueOriginBRL(fromApi), FormItemsExterior.feeBRL(fromApi)]\n : [FormItemsExterior.precoVenda, FormItemsExterior.fee],\n movimentType === \"Venda de ativos\"\n ? [\n FormItemsExterior.capitalGainBRL,\n ]\n : [\n FormItemsExterior.dataVendaFee(month, year),\n FormItemsExterior.cotacaoVendaFee(quotations),\n ],\n movimentType === \"Venda de ativos\"\n ? []\n : [FormItemsExterior.ganhoFee],\n ];\n};\n\nexport const DarfBolsaFormItemRows = (month: number, year: number) => [\n [FormItemsBolsa.id],\n [FormItemsBolsa.operacao, FormItemsBolsa.market],\n [FormItemsBolsa.date(month, year), FormItemsBolsa.code(\"Ex: PETR3\")],\n [FormItemsBolsa.quantity(\"Ex: 100\"), FormItemsBolsa.price],\n [FormItemsBolsa.avgBuyPrice, FormItemsBolsa.feeB3],\n [FormItemsBolsa.capitalGain],\n];\n\nexport const DarfBolsaTabs: (\n data: IDarfBolsa,\n rest: any\n) => { class: string; tabs: { content: React.ReactNode }[] }[] = (\n data,\n rest\n) => [\n {\n class: \"header\",\n tabs: [\n {\n content: \"\",\n },\n {\n content: \"Comum\",\n },\n {\n content: \"Day Trade\",\n },\n {\n content: \"FII\",\n },\n ],\n },\n {\n class: \"sub-header strong\",\n tabs: [\n {\n content: \"Ganhos e perdas totais\",\n },\n {\n content: formatCurrency(data.varTotaisComum ?? 0),\n },\n {\n content: formatCurrency(data.varTotaisDT ?? 0),\n },\n {\n content: formatCurrency(data.varTotaisFII ?? 0),\n },\n ],\n },\n {\n class: \"sub-header strong\",\n tabs: [\n {\n content: \"Ganhos tributáveis\",\n },\n {\n content: formatCurrency(data.ganhoComum ?? 0),\n },\n {\n content: formatCurrency(data.ganhoDT ?? 0),\n },\n {\n content: formatCurrency(data.ganhoFII ?? 0),\n },\n ],\n },\n {\n class: \"sub-header opacity\",\n tabs: [\n {\n content: (\n <>\n (-) Prejuízos a compensar\n {!rest.view && (\n }\n onClick={rest.handleEditPreju}\n />\n )}\n \n ),\n },\n {\n content: formatCurrency(\n data.userPrejuizoComum ?? data.prejuizoComum ?? 0\n ),\n },\n {\n content: formatCurrency(\n data.userPrejuizoDayTrade ?? data.prejuizoDayTrade ?? 0\n ),\n },\n {\n content: formatCurrency(data.userPrejuizoFII ?? data.prejuizoFII ?? 0),\n },\n ],\n },\n {\n class: \"sub-header strong\",\n tabs: [\n {\n content: \"Base de cálculo\",\n },\n {\n content: formatCurrency(\n Math.max(\n (data.ganhoComum ?? 0) -\n (data.userPrejuizoComum\n ? data.userPrejuizoComum ?? 0\n : data.prejuizoComum ?? 0),\n 0\n )\n ),\n },\n {\n content: formatCurrency(\n Math.max(\n (data.ganhoDT ?? 0) -\n (data.userPrejuizoDayTrade\n ? data.userPrejuizoDayTrade ?? 0\n : data.prejuizoDayTrade ?? 0),\n 0\n )\n ),\n },\n {\n content: formatCurrency(\n Math.max(\n (data.ganhoFII ?? 0) -\n (data.userPrejuizoFII\n ? data.userPrejuizoFII ?? 0\n : data.prejuizoFII ?? 0),\n 0\n )\n ),\n },\n ],\n },\n {\n class: \"sub-header opacity\",\n tabs: [\n {\n content: \"(x) Alíquota devida\",\n },\n {\n content: numberToPercentage(15, 0),\n },\n {\n content: numberToPercentage(20, 0),\n },\n {\n content: numberToPercentage(20, 0),\n },\n ],\n },\n {\n class: \"sub-header strong\",\n tabs: [\n {\n content: \"Imposto devido\",\n },\n {\n content: formatCurrency(data.impostoComumFinal ?? 0),\n },\n {\n content: formatCurrency(data.impostoDTFinal ?? 0),\n },\n {\n content: formatCurrency(data.impostoFIIFinal ?? 0),\n },\n ],\n },\n];\n\nexport const FreeLimitText = (\n \n {\" \"}\n \n Você atingiu o limite de DARFS emitidos/salvos no plano gratuito.{\" \"}\n Atualize o seu plano\n \n \n);\n\nexport const SuportPremiumText = (\n \n {\" \"}\n \n O suporte ao vivo está disponível apenas para usuários do Plano PREMIUM.{\" \"}\n Atualize o seu plano\n \n \n);\n","import _ from \"lodash\";\nimport moment from \"moment\";\nimport * as XLSX from \"xlsx\";\nimport { HiOutlineDownload } from \"react-icons/hi\";\nimport React, { useEffect, useRef, useState } from \"react\";\nimport {\n Checkbox,\n Col,\n DatePicker,\n Modal,\n Row,\n Select,\n Table,\n Typography,\n message,\n} from \"antd\";\nimport { ContainerModal } from \"./styles\";\nimport Button from \"../../components/Button\";\nimport { DrawerModal } from \"../DrawerModal\";\nimport apiVeloPro from \"../../services/apiVeloPro\";\nimport { ReportTypeDrawer } from \"../ReportType/ReportType\";\nimport { ReactComponent as FiltroIcon } from \"../../assets/icons/filtro.svg\";\nimport {\n download,\n downloadPDF,\n formatCurrency,\n isMobile,\n monthsExtended,\n} from \"../../utils\";\nimport { useAuth } from \"../../contexts/AuthContext\";\n\nconst months: any = {\n Jan: 1,\n Fev: 2,\n Mar: 3,\n Abr: 4,\n Mai: 5,\n Jun: 6,\n Jul: 7,\n Ago: 8,\n Set: 9,\n Out: 10,\n Nov: 11,\n Dez: 12,\n};\n\nexport const ProventosModal: React.FC = ({\n open,\n month,\n proventos,\n setOpenModal,\n yearProventos,\n proventosLoading,\n setYearProventos,\n setMonthProventos,\n}) => {\n const date = new Date();\n const dateFormat = \"DD/MM/YYYY\";\n const selectYears = [1, 0, -1, -2, -3];\n const dateBeginRef = useRef(null);\n const [data, setData] = useState([]);\n const [total, setTotal] = useState(0);\n const [loading, setLoading] = useState(false);\n const [filters, setFilters] = useState({});\n const [dataModalPDF, setDataModalPDF] = useState([]);\n const [originalData, setOriginalData] = useState([]);\n const [dateBeginFilter, setDateBeginFilter] = useState(\"\");\n const [appliedFilters, setAppliedFilters] = useState({});\n const [showFilterModal, setShowFilterModal] = useState(false);\n const [reportDrawerProventos, setReportDrawerProventos] = useState(false);\n const [dateEndFilter, setDateEndFilter] = useState(\n moment().format(dateFormat)\n );\n\n const { user } = useAuth();\n\n const downloadRelatorioProventos = async (type: string) => {\n try {\n const escritorioId = null;\n setLoading(true);\n if (type === \"pdf\") {\n let fileUrl = \"\";\n let file = \"\";\n const ret = await apiVeloPro.post(\n \"/calc/downloadRelatorioProventos\",\n {\n proventos: dataModalPDF,\n escritorioId: escritorioId,\n username: user?.user?.cpf\n }\n );\n if (ret) {\n fileUrl = ret?.data?.fileUrl;\n file = ret?.data?.file;\n }\n if (fileUrl && !isMobile()) {\n download(fileUrl);\n } else if (file && !isMobile()) {\n downloadPDF(file, \"Proventos\");\n }\n setLoading(false);\n message.success(\"O relatório foi enviado para o seu e-mail\");\n }\n if (type === \"xlsx\") {\n if (!isMobile()) {\n const workbook = XLSX.utils.book_new();\n const worksheet = XLSX.utils.json_to_sheet(data);\n XLSX.utils.book_append_sheet(workbook, worksheet, \"Proventos\");\n XLSX.writeFile(workbook, \"Proventos.xlsx\");\n }\n setLoading(false);\n message.success(\"O relatório foi enviado para o seu e-mail\");\n }\n } catch (err: any) {\n setLoading(false);\n message.error(\n \"Não foi possível baixar o relatório de proventos. Tente novamente mais tarde\"\n );\n }\n };\n\n const reportPDFData = (data: any, type: string) => {\n const formatModalPDF = data.map((el: any) => {\n if (type === \"prov\") {\n return {\n code: el.code || \"\",\n date: moment(el?.date).format(dateFormat),\n corporateActionTypeDescription: _.capitalize(\n el?.corporateActionTypeDescription\n ),\n corretora: el?.corretora,\n quantity: el?.quantity || \"-\",\n unitPrice: el?.unitPrice || \"-\",\n grossAmount: el?.grossAmount,\n };\n } else if (type === \"other\") {\n return {\n code: el[\"Produto\"] || \"\",\n date: el[\"Pagamento\"],\n corporateActionTypeDescription: _.capitalize(el[\"Tipo\"]),\n corretora: el[\"Instituição\"],\n quantity: el[\"Qtde.\"] || \"-\",\n unitPrice: el[\"Preço unit.\"] || \"-\",\n grossAmount: el[\"Valor líquido\"],\n };\n }\n return {};\n });\n return formatModalPDF;\n };\n\n useEffect(() => {\n let total = 0;\n const monthNumber = months[month];\n\n const dataFiltered = proventos.filter((el: any) => {\n const monthOp = Number(moment(el?.date).format(\"M\"));\n const yearOp = Number(moment(el?.date).format(\"YYYY\"));\n if (monthNumber === monthOp && yearProventos === yearOp) {\n return true;\n }\n return false;\n });\n setDataModalPDF(reportPDFData(dataFiltered, \"prov\"));\n const dataSerialized = dataFiltered.map((el: any) => {\n total += el?.grossAmount;\n\n return {\n Produto: el?.code,\n Pagamento: moment(el?.date).format(dateFormat),\n Tipo: _.capitalize(el?.corporateActionTypeDescription),\n Instituição: el?.corretora,\n \"Qtde.\": el?.quantity || \"-\",\n \"Preço unit.\": !el?.unitPrice\n ? \"-\"\n : \"R$ \" +\n el?.unitPrice?.toLocaleString(\"pt-br\", {\n minimumFractionDigits: 2,\n maximumFractionDigits: 2,\n }),\n \"Valor líquido\":\n \"R$ \" +\n el?.grossAmount?.toLocaleString(\"pt-br\", {\n minimumFractionDigits: 2,\n maximumFractionDigits: 2,\n }),\n };\n });\n setTotal(total);\n setData(dataSerialized);\n setOriginalData(dataSerialized);\n }, [month, yearProventos, proventos]);\n\n useEffect(() => {\n if (Object.keys(filters).length > 0 || (dateBeginFilter && dateEndFilter))\n setData(originalData);\n }, [filters, dateBeginFilter, dateEndFilter, originalData]);\n\n const handleOpenFilterModal = () => {\n setShowFilterModal(true);\n };\n\n const getCorretFilters = () => {\n const newCorret: any[] = [];\n if (originalData && originalData.length > 0)\n originalData.forEach((el: any) => {\n if (newCorret.includes(el[\"Instituição\"])) {\n } else {\n newCorret.push(el[\"Instituição\"]);\n }\n });\n return newCorret;\n };\n\n return (\n setOpenModal(false)}\n >\n \n
\n \n setMonthProventos({ name })}\n getPopupContainer={(trigger) => trigger.parentElement!}\n options={Object.keys(months).map((m, i) => ({\n value: m,\n label: monthsExtended[i],\n }))}\n />\n setYearProventos(e)}\n getPopupContainer={(trigger) => trigger.parentElement!}\n options={selectYears.map((y) => ({\n value: date.getFullYear() + y,\n label: date.getFullYear() + y,\n }))}\n />\n \n \n \n }\n onClick={() => {\n setReportDrawerProventos(true);\n }}\n >\n Baixar\n \n \n
\n \n
\n Total recebido no mês:\n {formatCurrency(total)}\n
\n
\n \n
\n \n
\n
\n
\n {\n setFilters(appliedFilters);\n setShowFilterModal(false);\n }}\n >\n \n \n \n {getCorretFilters().length > 0 &&\n <>\n \n Instituição\n \n \n {\n setFilters((filters: any) => ({ ...filters, corretoras }));\n }}\n >\n \n {getCorretFilters().map((el: any) => {\n const value = `${el.split(\" \")[0]}_${el.split(\" \")[1]}`;\n return (\n \n {el}\n \n );\n })}\n \n \n \n \n }\n \n Período de pagamento\n \n \n Data inicial\n setDateBeginFilter(\"\")}\n dropdownClassName=\"original-date-picker\"\n onChange={(el) => {\n if (el) setDateBeginFilter(moment(el).format(dateFormat));\n }}\n style={{\n width: \"50%\",\n marginTop: \"5px\",\n marginBottom: \"10px\",\n }}\n />\n Data final\n setDateEndFilter(\"\")}\n dropdownClassName=\"original-date-picker\"\n onChange={(el) => {\n if (el) setDateEndFilter(moment(el).format(dateFormat));\n }}\n style={{\n width: \"50%\",\n marginTop: \"5px\",\n marginBottom: \"10px\",\n }}\n />\n \n \n \n \n {\n setAppliedFilters(filters);\n const getProventosWithFilter = (filters: any) => {\n const corretoras = filters?.corretoras || [];\n const dataFiltered: any = [];\n const dataFinal: any = [];\n if (corretoras.length > 0) {\n corretoras.forEach((corret: string) => {\n data.forEach((el: any) => {\n const corretEl = `corret_${\n el[\"Instituição\"]?.split(\" \")[0]\n }_${el[\"Instituição\"]?.split(\" \")[1]}`;\n if (corretEl === corret) dataFiltered.push(el);\n });\n });\n setData(dataFiltered);\n if (dateBeginFilter && dateEndFilter) {\n const dateBegin = moment(\n dateBeginFilter,\n dateFormat\n ).toDate();\n const dateEnd = moment(\n dateEndFilter,\n dateFormat\n ).toDate();\n dataFiltered.forEach((el: any) => {\n const datePagamento = moment(\n el[\"Pagamento\"],\n dateFormat\n ).toDate();\n if (\n datePagamento >= dateBegin &&\n datePagamento <= dateEnd\n )\n dataFinal.push(el);\n });\n setData(dataFinal);\n }\n setDataModalPDF(\n reportPDFData(\n dataFinal.length === 0 ? dataFiltered : dataFinal,\n \"other\"\n )\n );\n return;\n } else if (dateBeginFilter && dateEndFilter) {\n const dateBegin = moment(\n dateBeginFilter,\n dateFormat\n ).toDate();\n const dateEnd = moment(dateEndFilter, dateFormat).toDate();\n data.forEach((el: any) => {\n const datePagamento = moment(\n el[\"Pagamento\"],\n dateFormat\n ).toDate();\n if (\n datePagamento >= dateBegin &&\n datePagamento <= dateEnd\n )\n dataFinal.push(el);\n });\n setData(dataFinal);\n setDataModalPDF(reportPDFData(dataFinal, \"other\"));\n return;\n }\n setData(originalData);\n };\n getProventosWithFilter(filters);\n setTimeout(() => {\n setShowFilterModal(false);\n }, 500);\n }}\n >\n Aplicar\n \n \n \n \n setReportDrawerProventos(false)}\n setType={(type: string) => downloadRelatorioProventos(type)}\n />\n \n );\n};\n","import { SetStateAction, createContext, useCallback, useContext, useEffect, useState } from \"react\";\nimport api from \"../services/apiBolsa\";\nimport { message } from \"antd\";\nimport { useAuth } from \"./AuthContext\";\n\ninterface INotification {\n message: string;\n type: string;\n date: Date;\n viewed: boolean;\n viewedDate?: Date;\n meta: any;\n}\n\ninterface INotificationContext {\n notification: INotification[];\n setNotification: React.Dispatch>\n loading: boolean;\n getNotification: () => void;\n}\n\nexport const NotificationContext = createContext(\n {} as INotificationContext\n);\n\nexport const NotificationProvider: React.FC = ({ children }) => {\n const [notification, setNotification] = useState([]);\n const [loading, setLoading] = useState(false);\n const [fetched, setFetched] = useState(false);\n\n const { user } = useAuth()\n\n const getNotification = useCallback(() => {\n if(user?.token) {\n setLoading(true)\n api.defaults.headers.common[\"Authorization\"] = `Bearer ${user?.token}`;\n api.get(`/warren/notification`)\n .then((res) => {\n setFetched(true)\n setNotification(res.data)\n })\n .catch(err => message.error('Não foi possível buscar notificações'))\n .finally(() => setLoading(false))\n }\n }, [user?.token])\n\n useEffect(() => {\n if(!fetched) {\n getNotification()\n }\n }, [fetched, getNotification]);\n\n return (\n \n {children}\n \n );\n};\n\nexport const useNotification = () => useContext(NotificationContext);\n","import _ from \"lodash\";\nimport moment from \"moment\";\nimport * as XLSX from \"xlsx\";\nimport { useState } from \"react\";\nimport { useEffect } from \"react\";\nimport { BsDownload } from \"react-icons/bs\";\nimport { Select, Tooltip, message } from \"antd\";\nimport { LoadingOutlined } from \"@ant-design/icons\";\nimport { AiOutlineLock, AiOutlineSearch } from \"react-icons/ai\";\nimport Loading from \"../Loading\";\nimport { ChartBar } from \"../ChartBar\";\nimport { BlurContent } from \"./styles\";\nimport api from \"../../services/apiBolsa\";\nimport AntButton from \"../../components/Button\";\nimport HandleTag from \"../../services/handleTag\";\nimport { ProventosModal } from \"../ProventosModal\";\nimport apiVeloPro from \"../../services/apiVeloPro\";\nimport { useAuth } from \"../../contexts/AuthContext\";\nimport { ContainerProventos, Content } from \"./styles\";\nimport { ReportTypeDrawer } from \"../ReportType/ReportType\";\nimport { download, downloadPDF, isMobile } from \"../../utils\";\nimport { useNotification } from \"../../contexts/NotificationContext\";\nimport { useNavigate } from \"react-router-dom\";\n\nexport const Proventos = ({ hideValues }: any) => {\n const { getNotification } = useNotification();\n\n const {\n user,\n showUserPlanModal,\n hasPlan: hasPremiunPlan,\n hasPermissionExterior,\n hasPermissionGeneral,\n } = useAuth();\n\n const navigate = useNavigate();\n const [openModal, setOpenModal] = useState(false);\n const [proventos, setProventos] = useState([]);\n const [monthProventos, setMonthProventos] = useState({});\n const [loadingDownload, setLoadingDownload] = useState(false);\n // const [appliedFilters, setAppliedFilters] = useState({});\n const [proventosLoading, setProventosLoading] = useState({});\n const [loadingReport, setLoadingReport] = useState(false);\n const [typeProventos, setTypeProventos] = useState(\"provento\");\n const [reportDrawerProventos, setReportDrawerProventos] = useState(false);\n const [yearProventos, setYearProventos] = useState(\n new Date().getFullYear()\n );\n\n const hasPlan =\n (hasPremiunPlan || hasPermissionExterior || hasPermissionGeneral)\n && !user?.user?.userPlanInfoVelotax?.type.includes('BASIC');\n\n useEffect(() => {\n setProventosLoading(true);\n api\n .get(`/warren/get-proventos`, {\n params: { year: yearProventos },\n })\n .then((res) => {\n if (!res?.data?.proventos) setProventos([])\n setProventos(res?.data?.proventos);\n if (res?.data?.updated) {\n getNotification();\n }\n })\n .finally(() => setProventosLoading(false));\n }, [user?.user?.cpf, getNotification, yearProventos]);\n\n const monthReport = (data?: any, index?: any) => {\n setOpenModal(true);\n if (data) {\n setMonthProventos(data);\n } else {\n const date = new Date();\n const y = date.getFullYear();\n const m = date.toLocaleString(\"pt-BR\", { month: \"short\" });\n const name = `${m[0].toUpperCase()}${m.substring(1, 3)}`;\n setMonthProventos({ name });\n setYearProventos(y);\n }\n };\n\n const serializeDataExcel = (data: any) => {\n return data\n .filter(\n (el: any) => yearProventos === Number(moment(el?.date).format(\"Y\"))\n )\n .map((el: any) => {\n return {\n Produto: el?.code,\n Pagamento: moment(el?.date).format(\"DD/MM/YYYY\"),\n Tipo: _.capitalize(el?.corporateActionTypeDescription),\n Instituição: el?.corretora,\n \"Qtde.\": el?.quantity || \"-\",\n \"Preço unit.\":\n el?.corporateActionTypeDescription.toLowerCase() === \"dividendo\" ||\n el?.corporateActionTypeDescription.toLowerCase() === \"dividendos\" ||\n el?.corporateActionTypeDescription.toLowerCase() === \"cupom\"\n ? \"-\"\n : \"R$ \" +\n el?.unitPrice?.toLocaleString(\"pt-br\", {\n minimumFractionDigits: 2,\n maximumFractionDigits: 2,\n }),\n \"Valor líquido\":\n \"R$ \" +\n el?.grossAmount?.toLocaleString(\"pt-br\", {\n minimumFractionDigits: 2,\n maximumFractionDigits: 2,\n }),\n };\n });\n };\n\n const downloadExcel = (data: any) => {\n const serializedData = serializeDataExcel(data);\n setLoadingReport(true);\n api\n .post(\"/warren/wallet/report-proventos\", {\n data: serializedData,\n })\n .then(() => {\n if (!isMobile()) {\n const worksheet = XLSX.utils.json_to_sheet(serializedData);\n const workbook = XLSX.utils.book_new();\n XLSX.utils.book_append_sheet(workbook, worksheet, \"Proventos\");\n XLSX.writeFile(workbook, \"Proventos.xlsx\");\n }\n })\n .finally(() => {\n message.success(\"O relatório foi enviado para o seu e-mail\");\n setLoadingReport(false);\n });\n };\n\n const downloadRelatorio = async (type: string, item: any) => {\n try {\n setLoadingDownload(true);\n if (type === \"pdf\") {\n let fileUrl = \"\";\n let file = \"\";\n const escritorioId = null;\n const newProventos = proventos.map((el: any) => {\n return {\n code: el.code || \"\",\n date: moment(el?.date).format(\"DD/MM/YYYY\"),\n corporateActionTypeDescription: _.capitalize(\n el?.corporateActionTypeDescription\n ),\n corretora: el?.corretora,\n quantity: el?.quantity || \"-\",\n unitPrice: el?.unitPrice,\n grossAmount: el?.grossAmount,\n };\n });\n const ret = await apiVeloPro.post(\n \"/calc/downloadRelatorioProventos\",\n {\n proventos: newProventos,\n escritorioId: escritorioId,\n username: user?.user?.cpf\n }\n );\n if (ret) {\n fileUrl = ret?.data?.fileUrl;\n file = ret?.data?.file;\n }\n if (fileUrl && !isMobile()) {\n download(fileUrl);\n } else if (file) {\n downloadPDF(file, \"Proventos\");\n }\n message.success(\"O relatório foi enviado para o seu e-mail\");\n } else if (type === \"xlsx\") {\n downloadExcel(proventos);\n }\n setLoadingDownload(false);\n } catch (err: any) {\n setLoadingDownload(false);\n message.error(\n \"Não foi possível baixar o relatório de Proventos. Tente novamente mais tarde\"\n );\n }\n };\n\n const existsProvCurrentMonth = () => {\n const currentMonth = (new Date().getMonth() + 1);\n return (proventos.some((p: any) => {\n if ((p?.date?.split('-')[1] == currentMonth.toString())) return true;\n }))\n }\n\n return (\n \n \n \n {!hasPlan ? (\n proventosLoading ? (\n \n ) : (\n \n
\n Contrate o plano premium para ver a lista completa de\n proventos\n }\n onClick={() => {\n navigate('/planos')\n HandleTag(\"54\");\n }}\n >\n PREMIUM\n \n
\n \n
\n )\n ) : (\n <>\n
\n setYearProventos(e)}\n options={[\n {\n value: new Date().getFullYear() + 1,\n label: new Date().getFullYear() + 1,\n },\n {\n value: new Date().getFullYear(),\n label: new Date().getFullYear(),\n },\n {\n value: new Date().getFullYear() - 1,\n label: new Date().getFullYear() - 1,\n },\n {\n value: new Date().getFullYear() - 2,\n label: new Date().getFullYear() - 2,\n },\n {\n value: new Date().getFullYear() - 3,\n label: new Date().getFullYear() - 3,\n },\n ]}\n />\n setTypeProventos(e)}\n options={[\n {\n label: \"Por tipo de provento\",\n value: \"provento\",\n },\n {\n label: \"Por corretora\",\n value: \"corretora\",\n },\n {\n label: \"Por data de recebimento\",\n value: \"data\",\n },\n ]}\n />\n
\n {existsProvCurrentMonth() && \n monthReport()}\n icon={}\n disabled={proventosLoading || loadingReport}\n >\n Ver detalhes\n \n }\n target.parentElement!}\n >\n {\n setReportDrawerProventos(true);\n }}\n disabled={proventosLoading || loadingReport}\n icon={\n loadingReport ? : \n }\n >\n Baixar\n \n \n
\n
\n {proventosLoading ? (\n \n ) : (\n \n )}\n \n \n )}\n
\n
\n setReportDrawerProventos(false)}\n setType={(type: string) => downloadRelatorio(type, proventos)}\n />\n
\n );\n};\n","import { message } from \"antd\";\nimport { useNavigate } from \"react-router-dom\";\nimport { Dispatch, SetStateAction, createContext, useCallback, useContext, useState } from \"react\";\nimport apiBolsa from \"../services/apiBolsa\";\nimport apiVeloPro from \"../services/apiVeloPro\";\nimport { useAuth } from \"./AuthContext\";\n\nexport interface Posicao {\n categoria: string;\n codigo: string;\n posicao: number;\n quantidade: number;\n precoAtual: number;\n precoVenda: number;\n loan?: {\n isLoan?: boolean;\n typeLoan?: string;\n };\n custoMedio: number;\n lucroPrejuizoTotal: number;\n lucroPrejuizoDiario: number;\n lucroPrejuizoTotalPercentual: number;\n lucroPrejuizoDiarioPercentual: number;\n hasPosition2019: boolean;\n corretora: string;\n resumo: any;\n}\n\ninterface Carteira {\n posicoes: Posicao[];\n posicoesSemFiltro: Posicao[];\n patrimonioTotal: number;\n lucroPrejuizoTotal: number;\n lucroPrejuizoDiario: number;\n lucroPrejuizoTotalPercentual: number;\n lucroPrejuizoDiarioPercentual: number;\n filter?: string[];\n erroB3?: boolean;\n cotacaoVenda: number;\n}\n\ninterface ICarteiraContext {\n carteira: Carteira;\n loading: boolean;\n lastUpdate: Date;\n getCarteira: (refresh?: boolean) => void;\n getPatrimonios: (cpf: string) => Promise;\n updateFilter: (posicoes: string[]) => Promise;\n posicoesFilter: any;\n setPosicoesFilter: Dispatch>;\n}\n\nexport const CarteiraContext = createContext(\n {} as ICarteiraContext\n);\n\nexport const CarteiraProvider: React.FC = ({ children }) => {\n const navigate = useNavigate();\n const [loading, setLoading] = useState(false);\n const [lastUpdate, setLastUpdate] = useState(new Date());\n const [carteira, setCarteira] = useState({});\n const [posicoesFilter, setPosicoesFilter] = useState(carteira.filter);\n const { user } = useAuth();\n\n const getCarteira = useCallback(\n (refresh?: boolean) => {\n setLoading(true);\n apiBolsa\n .get(\"/warren/wallet\", {\n params: {\n refresh,\n },\n })\n .then(({ data }) => {\n setCarteira(data);\n setPosicoesFilter(data?.filter)\n setLastUpdate(new Date());\n })\n .catch((error) => {\n if (error.response?.data?.status === 400) {\n message.info(\"Refaça sua integração com a B3 e tente novamente.\");\n setTimeout(() => {\n navigate(\"warren/bolsa-integration\");\n }, 1000);\n }\n })\n .finally(() => {\n setLoading(false);\n });\n },\n [navigate]\n );\n\n const updateFilter = async (posicoes: string[]) => {\n apiBolsa.patch('/warren/wallet/filter', {posicoes})\n .then(() => {\n getCarteira(true)\n })\n .catch((err) => {\n console.log(err)\n })\n }\n\n const getPatrimonios = async (cpf: string) => {\n const { data } = await apiVeloPro.get('/calc/get-patrimonios', {\n params: {\n email: user?.user?.email,\n name: user?.user?.name\n }\n });\n return data;\n };\n\n return (\n \n {children}\n \n );\n};\n\nexport const useCarteira = () => useContext(CarteiraContext);\n","import { months } from \"./date\";\nimport { Posicao } from \"../contexts/CarteiraContext\";\n\nconst colors: any = [\n \"var(--ant-primary-color)\",\n \"#121212\",\n \"#AABBCC\",\n \"var(--ant-primary-8)\",\n \"var(--ant-primary-4)\",\n \"#000058\",\n];\n\nexport const chartColors = [\n { background: \"#FCC102\", label: \"white\" },\n { background: \"#C8D200\", label: \"black\" },\n { background: \"#FF2B01\", label: \"white\" },\n { background: \"#E50045\", label: \"white\" },\n { background: \"#CC13AF\", label: \"white\" },\n { background: \"#5B0084\", label: \"white\" },\n { background: \"#79002B\", label: \"white\" },\n { background: \"#125E22\", label: \"white\" },\n { background: \"#FF7F00\", label: \"white\" },\n]\nexport const getProviderColor = (provider: string, index: number) => {\n while (index > 8) {\n const differnce = index - 8;\n index = differnce - 1;\n }\n return chartColors[index].background;\n}\n\nexport const getFontColor = (bc: string) => {\n const hex = /^#?([a-f\\d]{2})([a-f\\d]{2})([a-f\\d]{2})$/i.exec(bc);\n const rgb = hex\n ? [parseInt(hex[1], 16), parseInt(hex[2], 16), parseInt(hex[3], 16)]\n : [0, 0, 0];\n\n const brightness = Math.round(\n (rgb[0] * 299 + rgb[1] * 587 + rgb[2] * 114) / 1000\n );\n return brightness > 200 ? \"#000000\" : \"#FFFFFF\";\n};\n\nexport const getRandomDarkColor = () => {\n let color = \"#\";\n for (let i = 0; i < 6; i++) {\n color += Math.floor(Math.random() * 10);\n }\n return color;\n};\n\nexport const getClassesAtivosChart = (carteiraCategorizada: {\n [key: string]: Posicao[];\n}) => {\n const getCategoriaAtivos = (categoria: string) => {\n switch (categoria) {\n case \"FII - Fundo de Investimento Imobiliário\":\n return \"FIIs\";\n case \"Fundos de Investimentos\":\n return \"FIs\";\n case \"ETF - Exchange Traded Fund\":\n return \"ETFs\";\n case \"BDR - Brazilian Depositary Receipts\":\n return \"BDRs\";\n case \"Opcao\":\n return \"Opções\";\n case \"Exterior\":\n return \"Warren International\";\n case \"TesouroDireto\":\n return \"Tesouro Direto\";\n case \"undefined\":\n return \"Outros\";\n default:\n return categoria;\n }\n };\n\n let i = 0;\n let classes: any[] = [];\n for (let index in carteiraCategorizada) {\n const sum = carteiraCategorizada[index].reduce((acc, cur) => {\n return acc + cur.posicao;\n }, 0);\n const name = getCategoriaAtivos(index);\n classes.push({\n name,\n value: sum,\n color: colors[i % colors.length],\n });\n i += 1;\n }\n return classes;\n};\n\nexport const getCorretoraAtivosChart = (carteiraCategorizada: {\n [key: string]: Posicao[];\n}) => {\n const getCorretora = (corretora: string) => {\n switch (corretora) {\n case \"XP INVESTIMENTOS CCTVM S/A\":\n return \"XP\";\n case \"BANCO BTG PACTUAL S/A\":\n return \"BTG Pactual\";\n case \"Warren International\":\n return \"Warren International\";\n case \"undefined\":\n return \"Warren International\";\n default:\n return corretora;\n }\n };\n let corretoras: any = [];\n for (let ativos of Object.values(carteiraCategorizada)) {\n for (let ativo of ativos) {\n corretoras[ativo.corretora] =\n (corretoras[ativo.corretora] || 0) + ativo.posicao;\n }\n }\n let i = 0;\n let result = [];\n for (let index in corretoras) {\n result.push({\n name: getCorretora(index),\n value: corretoras[index],\n color: colors[i % colors.length],\n });\n i += 1;\n }\n return result;\n};\n\nexport const getLineChartData = (arr: any[]) => {\n if (!arr) return [];\n const previousDate = arr[0].date.split(\"/\").map((num: any) => Number(num));\n const currentDate = arr[arr.length - 1].date\n .split(\"/\")\n .map((num: any) => Number(num));\n\n let response = arr.map((i) => {\n return { name: \"\", value: i.value };\n });\n\n response[0].name = `${previousDate[0]} ${months[previousDate[1] - 1]} ${previousDate[2]\n }`;\n response[response.length - 1].name = `${currentDate[0]} ${months[currentDate[1] - 1]\n } ${currentDate[2]}`;\n\n return response;\n};\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n width: 100%;\n .progress_container {\n width: 100%;\n background-color: var(--velotax-border-color);\n height: 15px;\n position: relative;\n border-radius: 50px;\n }\n\n .loading_bar {\n height: 100%;\n background-color: var(--ant-primary-color);\n border-top-left-radius: 50px;\n border-bottom-left-radius: 50px;\n display: flex; /* Para que os elementos dentro da barra de progresso se alinhem corretamente */\n align-items: center; /* Para centralizar verticalmente o texto */\n justify-content: center; /* Para alinhar o texto à esquerda dentro da barra de progresso */\n padding-left: 10px; /* Adicione o padding necessário para dar espaço ao texto na barra */\n }\n\n .progress_container_text_align_center {\n /* Estilos para o texto (se necessário) */\n font-size: 11px;\n font-weight: 700;\n }\n .recharts-responsive-container {\n height: auto !important;\n }\n .success {\n color: var(--ant-success-color);\n }\n .error {\n color: red;\n }\n .page-title {\n display: flex;\n align-items: baseline;\n }\n .hide-values-btn {\n width: 24px;\n margin-left: 12px;\n border-radius: 4px;\n display: inline-flex;\n height: 32px !important;\n background-color: transparent;\n svg {\n width: 20px;\n height: 20px;\n fill: var(--ant-primary-color) !important;\n }\n }\n\n .patrimonio {\n width: 100%;\n margin-top: -32px;\n margin-bottom: -32px;\n\n h1:not(.page-title) {\n padding-bottom: 0;\n padding-left: 40px;\n font-size: 2.25rem;\n margin: 0 !important;\n color: var(--velotax-font-color-light);\n\n span {\n font-weight: 800;\n }\n\n :after {\n display: none;\n }\n }\n\n h2 {\n font-weight: 400;\n line-height: 1rem;\n padding-left: 40px;\n font-size: 0.875rem;\n margin: 0 !important;\n color: var(--velotax-font-color-light);\n }\n\n .lucro-prejuizo {\n padding: 16px 0 16px 16px;\n border-left: 2px solid #efefef;\n\n .anticon.anticon-loading.anticon-spin {\n width: 14px;\n height: 14px;\n margin-left: 4px;\n svg {\n width: 14px;\n height: 14px;\n }\n }\n\n div.ant-typography {\n margin: 0.5rem 0;\n font-size: 0.875rem;\n span {\n font-weight: 600;\n white-space: nowrap;\n }\n & > span {\n display: block;\n &.error {\n margin: 0;\n }\n }\n }\n }\n }\n\n .list-empty {\n padding: 16px;\n margin-top: -16px;\n border-radius: 8px;\n color: var(--velotax-font-color);\n background-color: #efefef;\n }\n\n .last-update {\n display: flex;\n margin-top: 32px;\n align-items: center;\n font-size: 0.75rem;\n line-height: 1.5rem;\n color: var(--ant-primary-color);\n .button-refresh-wallet {\n width: 20px;\n height: 20px;\n border: none;\n box-shadow: none;\n margin-right: 8px;\n background-color: #efefef;\n color: var(--ant-primary-color) !important;\n svg {\n width: 10px !important;\n height: 10px !important;\n * {\n stroke: var(--ant-primary-color) !important;\n }\n }\n }\n }\n\n .messages {\n margin-top: 16px;\n font-weight: 400;\n padding-top: 16px;\n line-height: 1rem;\n font-size: 0.75rem;\n color: var(--velotax-font-color);\n border-top: 2px solid #efefef;\n li {\n padding-left: 16px;\n margin-bottom: 6px;\n position: relative;\n .anticon-info-circle {\n left: 0;\n top: 1px;\n position: absolute;\n color: var(--velotax-font-color);\n }\n }\n }\n\n .select-container {\n top: 0;\n right: 0;\n width: 41.6666%; // 41.6666% para alinhar com o prejuizo (10/24 = 41.6666)\n position: absolute;\n .ant-select {\n min-width: 180px;\n height: 40px !important;\n .ant-select-selector {\n height: 40px !important;\n }\n }\n }\n .recharts-layer.recharts-pie-labels text {\n font-size: 14px !important;\n font-weight: 600 !important;\n }\n @media only screen and (min-device-width: 813px) {\n .velotax-content.largeChart {\n .recharts-responsive-container {\n margin: 0 auto 80px;\n }\n }\n .recharts-responsive-container {\n margin: 0 auto 48px;\n position: relative;\n .recharts-wrapper {\n width: 100% !important;\n > .recharts-surface {\n margin-left: 40px;\n }\n .recharts-legend-wrapper {\n right: 0px !important;\n width: 41.6666% !important; // 41.6666% para alinhar com o prejuizo (10/24 = 41.6666)\n top: calc(48px + 20px) !important;\n .recharts-legend-item {\n margin: 4px 0;\n .recharts-surface {\n width: 16px;\n height: 16px;\n border-radius: 2px;\n }\n .recharts-legend-item-text {\n /* margin-left: 12px; */\n span {\n font-size: 14px;\n font-weight: 500;\n color: var(--velotax-font-color) !important;\n }\n }\n }\n }\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n .page-title {\n align-items: center;\n justify-content: space-between;\n }\n .patrimonio {\n margin-top: 32px;\n margin-bottom: -24px;\n\n h1,\n h2 {\n padding-left: 0 !important;\n }\n\n .lucro-prejuizo {\n padding: 4px 0 0;\n border: none;\n margin-top: 16px;\n border-top: 2px solid #efefef;\n\n .anticon.anticon-loading.anticon-spin {\n width: 10px;\n height: 10px;\n margin-left: 4px;\n svg {\n width: 10px;\n height: 10px;\n }\n }\n\n div.ant-typography {\n margin: 0.25rem 0;\n font-size: 0.75rem;\n }\n }\n }\n\n h1 {\n width: calc(100% - 48px);\n margin: 0 24px 1.5rem;\n padding: 24px 0 1rem;\n }\n\n .recharts-responsive-container {\n position: relative;\n margin: 32px auto;\n .select-container {\n top: -32px;\n width: 100%;\n .ant-select {\n min-width: 210px;\n }\n }\n .recharts-legend-wrapper {\n width: 98px !important;\n right: -24px !important;\n .recharts-legend-item {\n margin: 4px 0;\n align-items: start;\n display: flex !important;\n margin-right: 0 !important;\n .recharts-surface {\n border-radius: 2px;\n margin-top: 1px;\n }\n .recharts-legend-item-text {\n max-width: 80px;\n font-size: 13px;\n line-height: 14px;\n white-space: normal;\n display: inline-block;\n span {\n color: var(--velotax-font-color) !important;\n }\n }\n }\n }\n }\n }\n`;\n\nexport const Content = styled.div`\n .ant-tooltip {\n z-index: 999;\n .ant-tooltip-inner {\n width: auto;\n white-space: nowrap;\n }\n }\n &.velotax-content {\n width: 100% !important;\n padding: 16px 0 48px !important;\n }\n .container-btn {\n display: flex;\n justify-content: flex-end;\n margin-bottom: 32px;\n }\n .download-report-btn {\n padding: 5px;\n width: 24px;\n z-index: 1;\n font-size: 14px;\n border-radius: 4px;\n display: inline-flex;\n height: 32px !important;\n background-color: var(--white);\n color: var(--velotax-font-color-dark);\n width: 32px;\n border: 2px solid var(--velotax-ghost-white);\n border-radius: 60px;\n svg {\n width: 16px;\n height: 16px;\n fill: var(--ant-primary-color) !important;\n }\n &.filter-btn {\n width: auto;\n margin-right: 8px;\n padding: 5px 12px;\n svg {\n stroke: var(--ant-primary-color) !important;\n fill: none !important;\n }\n }\n }\n .range {\n display: flex;\n justify-content: space-between;\n\n div.ant-typography {\n font-size: 13px;\n }\n }\n .ant-tabs-tabpane {\n min-height: 547px;\n }\n .isentometro {\n margin-bottom: 5px;\n font-size: 14px;\n }\n .box {\n margin: 50px 0px;\n }\n .overview {\n color: var(--ant-primary-color);\n font-size: 18px;\n font-weight: bold;\n }\n .ant-progress-success-bg {\n background-color: var(--ant-primary-color);\n height: 13px !important;\n }\n .ant-progress-inner {\n height: 13px !important;\n }\n .ant-progress-bg {\n height: 13px !important;\n }\n & > .ant-collapse {\n border: none;\n & > .ant-collapse-item.ativos-categoria {\n margin-bottom: 48px;\n &:last-of-type {\n margin-bottom: 0;\n }\n & > .ant-collapse-header {\n padding: 0;\n align-items: center;\n .ant-collapse-arrow {\n right: 0;\n }\n h2 {\n margin: 0;\n font-weight: 700;\n font-size: 1.125rem;\n line-height: 1.5rem;\n color: var(--ant-primary-color);\n }\n .collapse-title-divider {\n flex-grow: 1;\n display: block;\n margin: 0 16px;\n border-bottom: 2px solid #efefef;\n }\n .collapse-title-hidden {\n width: 24px;\n height: 24px;\n display: block;\n visibility: hidden;\n }\n }\n & > .ant-collapse-content {\n border: none;\n background-color: transparent;\n & > .ant-collapse-content-box {\n padding: 24px 0 0;\n & > .ant-collapse {\n border: none;\n }\n & > div {\n font-size: 13px;\n }\n }\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n width: 100%;\n margin-bottom: 0;\n border-radius: 0;\n padding: 32px 24px;\n\n h1,\n h2 {\n padding: 0;\n }\n }\n`;\n\nexport const BlurContent: any = styled.div`\n margin-top: 8px;\n position: relative;\n user-select: none;\n border-radius: 4px;\n border: 2px solid #efefef;\n .blur-content {\n opacity: 0.5;\n filter: blur(4px);\n }\n .blur-content-title {\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n padding: 0 100px;\n font-weight: 500;\n font-size: 1.25rem;\n text-align: center;\n row-gap: 16px;\n display: flex;\n align-items: center;\n flex-direction: column;\n justify-content: center;\n color: var(--velotax-font-color-light);\n }\n\n @media only screen and (max-device-width: 812px) {\n .blur-content-title {\n padding: 0 16px;\n font-size: 1rem;\n }\n }\n`;\n\nexport const Toolbar = styled.div`\n display: flex;\n flex-direction: column;\n width: 700px;\n margin: 0 auto 1.5rem;\n justify-content: space-between;\n\n @media only screen and (max-device-width: 812px) {\n width: 100%;\n }\n`;\n\nexport const IsentCardStyled = styled.div`\n margin-bottom: 4px;\n height: 110px;\n padding: 23px;\n border: none !important;\n border-radius: 4px !important;\n background-color: var(--velotax-background-color-ghost);\n text-align: center;\n gap: 12px;\n flex-direction: column;\n display: flex;\n\n .overviewTitleIsent {\n color: var(--ant-primary-color);\n font-size: 13px;\n }\n\n .ant-tooltip-inner {\n display: flex;\n justify-content: center;\n width: 315px;\n padding: 5px;\n }\n`;\n","import _ from \"lodash\";\n\nexport const serializePatrimonio = (\n itemPatrimonio: any,\n corretoraFilter?: string[]\n) => {\n let posicoesFiltradas = itemPatrimonio?.posicoes || [];\n const corretoras = getTodasAsCorretoras(posicoesFiltradas);\n const corretorasSemFiltro = getTodasAsCorretoras(itemPatrimonio?.posicoesSemFiltro)\n if(corretoraFilter && corretoraFilter.length > 0) {\n const corretoraNames = corretoraFilter.map(c => getNomeCorretora({shortName: c}))\n posicoesFiltradas = posicoesFiltradas?.filter((p: any) => corretoraNames.includes(p.corretora))\n }\n\n const patrimonio = calculaSaldoCorretoras(\n posicoesFiltradas,\n itemPatrimonio?.posicao2019 || {}\n );\n\n const classesAtivos = calculaClassesAtivos(\n posicoesFiltradas,\n itemPatrimonio?.posicao2019 || {}\n );\n const posicoes = calculaPorcentagemPosicoes(posicoesFiltradas);\n\n return { patrimonio, classesAtivos, posicoes, corretoras, corretorasSemFiltro };\n};\n\nexport const getNomeCorretora = ({\n name,\n shortName,\n}: {\n name?: string;\n shortName?: string;\n}) => {\n const corretoras = [\n {\n name: \"XP INVESTIMENTOS CCTVM S/A\",\n shortName: \"XP Investimentos\",\n },\n {\n name: \"NU INVEST CORRETORA DE VALORES S.A.\",\n shortName: \"Nubank\",\n },\n {\n name: \"INTER DISTRIBUIDORA DE TITULOS E VALORES MOBILIARIOS LTDA\",\n shortName: \"Inter\",\n },\n {\n name: \"ORAMA DTVM S.A.\",\n shortName: \"Orama\",\n },\n {\n name: \"CLEAR CORRETORA - GRUPO XP\",\n shortName: \"Clear Corretora\",\n },\n {\n name: \"Exterior\",\n shortName: \"Warren Internacional\",\n },\n {\n name: \"Warren Internacional\",\n shortName: \"Warren Internacional\",\n },\n ];\n\n if (name) return corretoras.find((c) => c.name === name)?.shortName || name;\n if (shortName)\n return corretoras.find((c) => c.shortName === shortName)?.name || shortName;\n return \"\";\n};\n\nconst getCategoriaShortName = (categoria: string) => {\n if (categoria.includes(\"Fundos de Investimentos\")) return \"FIs\";\n if (categoria.includes(\"FII\")) return \"FIIs\";\n if (categoria.includes(\"BDR\")) return \"BDRs\";\n if (categoria.includes(\"ETF\")) return \"ETFs\";\n if (categoria.includes(\"Empréstimo de Ativos (Doador)\")) return \"Empréstimos (Doador)\";\n if (categoria.includes(\"Empréstimo de Ativos (Tomador)\")) return \"Empréstimos (Tomador)\";\n if (categoria.includes(\"TesouroDireto\")) return \"Tesouro Direto\";\n return categoria;\n};\n\nconst calculaSaldoCorretoras = (posicoes: any, posicao2019: any) => {\n const agrupadoPorCorretora = _.groupBy(posicoes, (p) => p.corretora);\n const saldosCorretoras = [];\n for (const corretora in agrupadoPorCorretora) {\n const saldo = agrupadoPorCorretora[corretora].reduce((prev, curr) => {\n return (prev || 0) + (curr?.posicao || 0);\n }, 0);\n saldosCorretoras.push({\n name: getNomeCorretora({ name: corretora }),\n value: saldo,\n });\n }\n\n return calculaPorgentagensCategorias(saldosCorretoras);\n};\n\nconst getTodasAsCorretoras = (posicoes: any) => {\n const agrupadoPorCorretora = _.groupBy(posicoes, (p) => p.corretora);\n const corretoras = Object.keys(agrupadoPorCorretora);\n return corretoras.map((c) => getNomeCorretora({ name: c }));\n};\n\nconst calculaClassesAtivos = (posicoes: any, posicao2019: any) => {\n const agrupadoPorCategoria = _.groupBy(posicoes, (p) => p.categoria);\n const saldosCategorias = [];\n for (const categoria in agrupadoPorCategoria) {\n const saldo = agrupadoPorCategoria[categoria].reduce((prev, curr) => {\n return (prev || 0) + (curr?.posicao || 0);\n }, 0);\n saldosCategorias.push({\n name: getCategoriaShortName(categoria),\n value: saldo,\n });\n }\n\n return calculaPorgentagensCategorias(saldosCategorias);\n};\n\nconst calculaPorgentagensCategorias = (\n saldosCategorias: Array<{ name: string; value: number }>\n) => {\n const totalSaldos = saldosCategorias.reduce(\n (acc, curr) => acc + curr.value,\n 0\n );\n\n const porcentagens = saldosCategorias.map((categoria) => ({\n name: categoria.name,\n value: categoria.value,\n percentage: Number(((categoria.value / totalSaldos) * 100).toFixed(1)),\n }));\n\n return porcentagens;\n};\n\nconst calculaPorcentagemPosicoes = (\n posicoes: {\n codigo: string;\n posicao: number;\n custoMedio: number;\n precoAtual: number;\n precoVenda: number;\n quantidade: number;\n categoria: string;\n corretora: string;\n hasPosition2019: boolean;\n }[]\n) => {\n if (!posicoes || posicoes.length === 0) return [];\n\n const patrimonioTotal = Number(\n posicoes.reduce((prev, curr) => prev + curr.posicao, 0).toFixed(2)\n );\n\n const posicoesOrdenadas = posicoes.sort((a, b) => {\n return b.posicao - a.posicao;\n });\n const quantidadeDeAtivosMostrados = 8;\n const porcentagens = [];\n\n for (\n let i = 0;\n i <\n (posicoesOrdenadas.length < quantidadeDeAtivosMostrados\n ? posicoesOrdenadas.length\n : quantidadeDeAtivosMostrados);\n i++\n ) {\n const posicao = posicoesOrdenadas[i];\n if (posicao.categoria === \"Exterior\" || !posicao.hasPosition2019) {\n const porcentagem = (posicao.posicao / patrimonioTotal) * 100;\n porcentagens.push({\n name: posicao.codigo,\n value: Number(posicao.posicao),\n percentage: Number(porcentagem.toFixed(1)),\n });\n }\n }\n\n let porcentagensOrdenadas = porcentagens.sort(\n (a, b) => a.percentage - b.percentage\n );\n\n if (porcentagensOrdenadas.length > quantidadeDeAtivosMostrados) {\n porcentagensOrdenadas = porcentagensOrdenadas.slice(\n 0,\n quantidadeDeAtivosMostrados\n );\n }\n\n let somatorioDasMaioresPorcentagens = 0;\n let somatorioDosMaioresValores = 0;\n for (const po of porcentagensOrdenadas) {\n somatorioDasMaioresPorcentagens += po.percentage;\n somatorioDosMaioresValores += po.value;\n }\n\n const ret = porcentagensOrdenadas.sort((a, b) => b.percentage - a.percentage);\n\n if (somatorioDasMaioresPorcentagens < 100) {\n ret.push({\n name: \"Outros\",\n value: patrimonioTotal - somatorioDosMaioresValores,\n percentage: Number((100 - somatorioDasMaioresPorcentagens).toFixed(2)),\n });\n }\n\n return ret;\n};\n","import { Col, Row } from \"antd\";\nimport { Button } from \"@mui/material\";\nimport { LoadingOutlined } from \"@ant-design/icons\";\n\ninterface FooterModalProps {\n disabled?: boolean;\n onCancel: () => void;\n onOk?: () => void;\n loading?: boolean;\n cancelButtonText?: string;\n saveButtonText?: string;\n dark?: boolean;\n}\n\nexport const FooterModal: React.FC = ({\n onOk,\n dark,\n loading,\n disabled,\n onCancel,\n saveButtonText,\n cancelButtonText,\n}) => {\n return (\n \n \n \n {cancelButtonText || \"Cancelar\"}\n \n \n \n \n {saveButtonText || \"Salvar\"}\n {loading && }\n \n \n \n );\n};\n","import { Radio } from \"antd\";\nimport Masked from \"react-input-mask\";\nimport { forwardRef, ReactNode } from \"react\";\nimport NumberFormat from \"react-number-format\";\nimport { FormControl, InputLabel, MenuItem, Select, TextField } from \"@mui/material\";\nimport { getMuiInputCss, isMobile } from \"../../utils\";\n\ninterface InputParams {\n label?: ReactNode;\n disabled?: boolean;\n placeholder?: string;\n maxLength?: number;\n className?: string;\n}\n\ninterface MaskInputParams extends InputParams {\n mask?: string;\n}\n\ninterface NumberInputParams extends InputParams {\n prefix?: string;\n decimalScale?: number;\n allowNegative?: boolean;\n}\n\ninterface SelectInputParams extends InputParams {\n defaultValue?: any;\n options?: { label: ReactNode; value: any }[];\n value?: any;\n}\n\ninterface RadioInputParams extends SelectInputParams {}\n\nexport const TextInput = ({ label, placeholder, disabled }: InputParams) => (\n \n);\n\nexport const SelectLabled = ({\n options,\n label,\n disabled,\n value,\n defaultValue,\n ...rest\n}: SelectInputParams & {\n onChange?: Function;\n value?: any;\n defaultValue?: any;\n}) => {\n const handleChange = (e: any) => {\n rest.onChange?.(e.target.value);\n };\n\n return (\n \n {label}\n \n {options?.map((option) => (\n \n {option.label}\n \n ))}\n \n \n );\n};\n\nexport const SelectInput = (props: SelectInputParams) => {\n return ;\n};\n\nexport const NumberInput = ({\n label,\n maxLength,\n className,\n prefix = \"\",\n disabled = false,\n decimalScale = 2,\n placeholder = \"\",\n allowNegative = false,\n}: NumberInputParams) => {\n const NumberFormatCustom = forwardRef((props, ref) => (\n \n ));\n\n return (\n \n );\n};\n\nexport const MaskInput = ({\n label,\n mask = \"\",\n placeholder = \"\",\n disabled = false,\n}: MaskInputParams) => {\n const MaskedCustom = forwardRef((props, ref) => (\n \n ));\n\n return (\n \n );\n};\n\nexport const RadioInput = ({ options, disabled }: RadioInputParams) => {\n return (\n \n {(\n options || [\n { value: true, label: \"Sim\" },\n { value: false, label: \"Não\" },\n ]\n ).map((option) => (\n \n {option.label}\n \n ))}\n \n );\n};\n","import { ReactNode } from \"react\";\nimport { FormItemProps } from \"antd\";\nimport { currencyToNumber } from \"../../utils\";\nimport {\n MaskInput,\n NumberInput,\n TextInput,\n SelectInput,\n RadioInput,\n} from \"../inputs\";\nimport {\n validationFieldRequired,\n validationDate,\n validationNumberFieldPositive,\n} from \"../../utils/formValidations\";\n\ninterface FormItemParams extends FormItemProps {\n name: string;\n span?: number;\n align?: \"end\";\n disabled?: boolean;\n placeholder?: string;\n onChange?: (changed: any, values: any) => any;\n hide?: ((data: any) => boolean) | boolean;\n}\n\ninterface NumberFormItemParams extends FormItemParams {\n prefix?: string;\n decimalScale?: number;\n allowNegative?: boolean;\n maxLength?: number;\n}\n\ninterface MaskFormItemParams extends FormItemParams {\n mask?: string;\n}\n\ninterface SelectFormItemParams extends FormItemParams {\n options: { label: ReactNode; value: any }[];\n renderItem?: any;\n defaultValue?: any;\n mustUpdate?: boolean;\n value?: any;\n}\n\ninterface RadioFormItemParams extends Omit {\n options?: { label: ReactNode; value: any }[];\n}\n\nexport const MaskFormItem = ({\n mask,\n label,\n placeholder,\n disabled,\n ...rest\n}: MaskFormItemParams) => ({\n ...rest,\n getValueFromEvent: undefined,\n input: MaskInput({\n mask,\n label,\n placeholder,\n disabled,\n }),\n});\n\nexport const DateFormItem = ({\n rules,\n label,\n placeholder,\n disabled,\n mask,\n ...rest\n}: MaskFormItemParams) => ({\n ...rest,\n getValueFromEvent: undefined,\n rules: rules ? rules : validationDate,\n input: MaskInput({\n mask: mask ?? \"99/99/9999\",\n placeholder: placeholder || \"01/01/2021\",\n disabled,\n label,\n }),\n});\n\nexport const DateFormItem2 = ({\n rules,\n label,\n placeholder,\n disabled,\n mask,\n ...rest\n}: MaskFormItemParams) => ({\n ...rest,\n getValueFromEvent: undefined,\n rules: rules ? rules : validationDate,\n input: MaskInput({\n mask: mask ?? \"9999/99/99\",\n disabled,\n label,\n }),\n});\n\nexport const TextFormItem = ({\n rules,\n placeholder,\n disabled,\n label,\n ...rest\n}: FormItemParams) => ({\n ...rest,\n rules: rules || [],\n getValueFromEvent: undefined,\n input: TextInput({ placeholder, disabled, label }),\n});\n\nexport const SelectFormItem = ({\n placeholder,\n disabled,\n options,\n label,\n rules,\n value,\n defaultValue,\n ...rest\n}: SelectFormItemParams) => ({\n ...rest,\n getValueFromEvent: undefined,\n rules: rules ?? validationFieldRequired,\n input: SelectInput({\n placeholder,\n disabled,\n options,\n label,\n defaultValue,\n value,\n }),\n});\n\nexport const RadioFormItem = ({\n disabled,\n options,\n label,\n rules,\n defaultValue,\n ...rest\n}: RadioFormItemParams) => ({\n ...rest,\n getValueFromEvent: undefined,\n rules: rules ?? validationFieldRequired,\n input: RadioInput({ disabled, options, defaultValue }),\n});\n\nexport const NumberFormItem = ({\n name,\n label,\n maxLength,\n rules = [],\n prefix = \"\",\n disabled = false,\n placeholder = \"\",\n decimalScale = 2,\n allowNegative = false,\n onChange,\n}: NumberFormItemParams) => ({\n name,\n label,\n rules,\n placeholder,\n getValueFromEvent: undefined,\n input: NumberInput({\n prefix,\n decimalScale,\n placeholder,\n allowNegative,\n disabled,\n label,\n maxLength,\n }),\n onChange: onChange\n ? onChange\n : (changed: any, values: any) =>\n changed[name]\n ? Number(changed[name].replace(/\\./g, \"\").replace(\",\", \".\")) || 0\n : values[name],\n});\n\nexport const CurrencyFormItem = ({\n name,\n label,\n rules,\n prefix = \"R$ \",\n disabled = false,\n decimalScale = 2,\n placeholder = \"R$ 0,00\",\n allowNegative = false,\n onChange,\n className,\n ...rest\n}: NumberFormItemParams) => ({\n ...rest,\n name,\n label,\n placeholder,\n getValueFromEvent: undefined,\n rules: rules === undefined ? validationNumberFieldPositive : rules,\n input: NumberInput({\n prefix,\n decimalScale,\n placeholder,\n allowNegative,\n disabled,\n label,\n className,\n }),\n onChange: onChange\n ? onChange\n : (changed: any, values: any) =>\n changed[name] ? currencyToNumber(changed[name], prefix) : values[name],\n});\n","import clsx from \"clsx\";\nimport { useState } from \"react\";\nimport { VscClose } from \"react-icons/vsc\";\nimport { FaRegEdit } from \"react-icons/fa\";\nimport NumberFormat from \"react-number-format\";\nimport { Form, List, message } from \"antd\";\nimport { InfoCircleOutlined } from \"@ant-design/icons\";\nimport apis from \"../../services/apis\";\nimport Button from \"../../components/Button\";\nimport { FooterModal } from \"../../components/FooterModal\";\nimport { Link } from \"react-router-dom\";\nimport {\n currencyToNumber,\n errorMessage,\n formatCurrency,\n isMobile,\n months,\n numberToPercentage,\n replaceDotByComma,\n zero,\n} from \"../../utils\";\nimport {\n validationDateIsOnReferenceMonth,\n validationFieldRequired,\n validationNumberAllowNegativeField,\n validationNumberFieldPositive,\n} from \"../../utils/formValidations\";\nimport {\n CurrencyFormItem,\n DateFormItem,\n NumberFormItem,\n TextFormItem,\n SelectFormItem,\n DateFormItem2,\n} from \"../formItems\";\nimport { useBroker } from \"../../contexts/BrokerContext\";\n\nexport const TipoMercado: { [key: string]: string } = {\n mercado: \"Mercado à vista\",\n mercadoAVista: \"Mercado a Vista\",\n mercadoOpcoes: \"Mercado de opções\",\n outros: \"Outros mercados\",\n mercadoFracionario: \"Merc. Fracionário\",\n opcaoCompra: \"Opção de Compra\",\n opcaoVenda: \"Opção de Venda\",\n dayTrade: \"Day Trade\",\n};\n\nexport const TipoOperacao: { [key: string]: string } = {\n comum: \"Comum\",\n daytrade: \"Day Trade\",\n fii: \"FII\",\n};\n\nexport enum YearResumeStatusFromBackEnum {\n PAYED = \"PAYED\",\n PENDING = \"PENDING\",\n REGULAR = \"REGULAR\",\n NOT_PAYED = \"NOT_PAYED\",\n}\n\nexport enum YearResumeStatusCSSClassEnum {\n PAYED = \"payed\",\n PENDING = \"pending\",\n REGULAR = \"not-payed\",\n NOT_PAYED = \"not-payed\",\n}\n\nexport enum YearResumeStatusColorEnum {\n PAYED = \"var(--ant-success-color)\",\n PENDING = \"var(--ant-error-color)\",\n REGULAR = \"var(--ant-info-color-disabled)\",\n NOT_PAYED = \"var(--ant-warning-color)\",\n}\n\nexport enum YearResumeStatusTextEnum {\n PAYED = \"Imposto apurado\",\n PENDING = \"Imposto devido\",\n REGULAR = \"Não há imposto devido\",\n NOT_PAYED = \"DARF Emitido e não pago\",\n}\n\nexport interface IDarf {\n payed?: boolean;\n emitted?: boolean;\n multa: number;\n juros: number;\n buffer?: any;\n totalAlienado: number;\n totalGanho: number;\n aliquotaDevida: number;\n impostoDevido: number;\n impostoTotal: number;\n impostoAcumulado: number;\n totalImpostoDevido: number;\n memoriaCalculo: any[];\n impostoComumFinal?: number;\n impostoDTFinal?: number;\n impostoFIIFinal?: number;\n regular?: boolean;\n status?: keyof typeof YearResumeStatusFromBackEnum;\n}\n\nexport const defaultDarf: IDarf = {\n totalAlienado: 0,\n impostoDevido: 0,\n impostoTotal: 0,\n impostoAcumulado: 0,\n totalImpostoDevido: 0,\n aliquotaDevida: 0,\n totalGanho: 0,\n juros: 0,\n multa: 0,\n buffer: {},\n memoriaCalculo: [],\n status: \"REGULAR\",\n};\n\nexport interface IDarfBolsa {\n payed?: boolean;\n buffer?: any;\n emitted?: boolean;\n aliquotaComum?: number;\n aliquotaDT?: number;\n aliquotaFII?: number;\n alienacoesComum?: number;\n alienacoesDT?: number;\n alienacoesFII?: number;\n ganhoComum?: number;\n ganhoDT?: number;\n ganhoFII?: number;\n impostoComumFinal?: number;\n impostoDTFinal?: number;\n impostoFIIFinal?: number;\n impostoTotal?: number;\n impostoTotalFinal?: number;\n irrfComum?: number;\n irrfDayTrade?: number;\n irrfFII?: number;\n irrfTotal?: number;\n jurosAux?: number;\n mercadoOpcoesComum?: number;\n mercadoOpcoesDT?: number;\n mercadoOutrosComum?: number;\n mercadoOutrosDT?: number;\n mercadoOutrosFII?: number;\n mercadoVistaComum?: number;\n mercadoVistaDT?: number;\n multaAux?: number;\n memoriaCalculo: any[];\n impostoAcumulado?: number;\n impostoDevido?: number;\n multa?: number;\n juros?: number;\n prejuizoComum?: number;\n prejuizoDayTrade?: number;\n prejuizoFII?: number;\n userPrejuizoComum?: number;\n userPrejuizoDayTrade?: number;\n userPrejuizoFII?: number;\n userIrrfComum?: number;\n userIrrfDayTrade?: number;\n userIrrfFII?: number;\n userIrrfTotal?: number;\n varTotaisComum?: number;\n varTotaisDT?: number;\n varTotaisFII?: number;\n userCustoCorretagemComum?: number;\n userCustoCorretagemDT?: number;\n userCustoCorretagemFII?: number;\n}\n\nexport const defaultDarfBolsa: IDarfBolsa = {\n alienacoesComum: 0,\n alienacoesDT: 0,\n alienacoesFII: 0,\n buffer: {},\n impostoComumFinal: 0,\n impostoDTFinal: 0,\n impostoFIIFinal: 0,\n impostoTotal: 0,\n impostoTotalFinal: 0,\n irrfComum: 0,\n irrfDayTrade: 0,\n irrfFII: 0,\n irrfTotal: 0,\n jurosAux: 0,\n mercadoOpcoesDT: 0,\n mercadoOutrosComum: 0,\n mercadoOutrosDT: 0,\n mercadoVistaComum: 0,\n mercadoVistaDT: 0,\n multaAux: 0,\n memoriaCalculo: [],\n impostoAcumulado: 0,\n prejuizoComum: 0,\n prejuizoDayTrade: 0,\n prejuizoFII: 0,\n};\n\nexport const minDarfPrice = 10;\nexport const maxDarfPrice = 10000;\nexport const maxPixValue = 10000;\n\nconst MultaModalProps = {\n title: \"Multa de Atraso\",\n content: (\n
\n

\n O pagamento dos impostos deve ser feito sempre até o último dia útil do\n mês subsequente aos ganhos realizados.\n

\n

\n Caso você tenha atrasado no pagamento do seu DARF, a sua multa de atraso\n será de 0,33% por dia de atraso (chegando, no máximo, a 20%) sobre o\n valor do principal, calculados a partir do primeiro dia útil depois do\n dia do vencimento do DARF.\n

\n
\n ),\n};\n\nconst JurosModalProps = {\n title: \"Juros de Atraso\",\n content: (\n
\n

\n O pagamento dos impostos deve ser feito sempre até o último dia útil do\n mês subsequente aos ganhos realizados.\n

\n

\n Caso você tenha atrasado no pagamento do seu DARF, os seus juros de\n atraso serão equivalentes a taxa Selic acumulada até o mês anterior ao\n do pagamento, mais 1% no mês do pagamento, sobre o valor principal,\n contados a partir do mês subsequente ao vencimento do DARF.\n

\n
\n ),\n};\n\nexport const CorretagemModalProps = {\n title: \"Taxas de corretagem\",\n content: (\n
\n

\n A Receita Federal admite a dedução dos custos de corretagem na apuração\n do ganho líquido em operações de renda variável. Entretanto, não há\n obrigatoriedade do usufruto do benefício da dedução por parte dos\n investidores (Instrução Normativa RFB nº 1.585, de 31 de agosto de 2015,\n art. 56, § 3º). As informações advindas somente da integração com a B3\n não consideram o benefício da dedução dos custos de corretagem da Warren,\n incluindo somente as tarifas de liquidação, registro, termo/opções e\n emolumentos da B3. Caso deseje descontar os seus custos de corretagem\n dos ganhos tributáveis, você pode adicionar manualmente as taxas de\n corretagem em cada operação no campo “Taxas” ou inserir manualmente a\n soma das taxas de corretagem do mês neste campo.\n

\n
\n ),\n};\n\nexport const CustoMedioModal = {\n title: \"Custo Médio\",\n content: (\n
\n

\n Preencha o custo médio do ativo na aba{\" \"}\n \n Posição 31-12-2019\n \n .\n

\n
\n ),\n};\n\nconst MinPriceModalProps = {\n title: <>DARF abaixo de {formatCurrency(minDarfPrice)},\n content: (\n
\n

\n O sistema da Receita Federal não permite a emissão de um único DARF com\n valor abaixo de {formatCurrency(minDarfPrice)}.\n

\n

\n Caso seu DARF tenha ficado com um valor abaixo de{\" \"}\n {formatCurrency(minDarfPrice)}, o valor será repassado automaticamente\n para o mês seguinte e ficará visível no campo{\" \"}\n \n DARFs passados abaixo de {formatCurrency(minDarfPrice)}\n \n .\n

\n
\n ),\n};\n\nconst IRRFModalProps = {\n title: <>IRRF (Imposto de Renda Retido na Fonte),\n content: (\n
\n

\n Operações Comuns e FIIs: As operações comuns realizadas em bolsas de\n valores, de mercadorias, de futuros e de FIIs estão sujeitas à retenção\n do imposto sobre a renda incidente na fonte à alíquota de 0,005% sobre o\n volume alienado.\n

\n

\n Operações Day Trade: As operações de Day Trade estão sujeitas à retenção\n do imposto sobre a renda incidente na fonte à alíquota de 1% do ganho,\n independente do volume alienado no mês.\n

\n
\n ),\n};\n\nconst AliquotaModalProps = {\n title: \"Alíquota sobre ganhos com criptoativos\",\n content: (\n
\n

\n Caso o valor total vendido no mês seja superior a R$ 35 mil, os ganhos\n obtidos serão tributados a título de ganho de capital. As alíquotas\n (percentuais) aplicadas sobre o lucro são progressivas:\n

\n \n \n a) 15% sobre a parcela dos ganhos que não ultrapassar R$ 5.000.000,00;\n \n \n b) 17,5% sobre a parcela dos ganhos que exceder R$ 5.000.000,00 e não\n ultrapassar R$ 10.000.000,00;\n \n \n c) 20% sobre a parcela dos ganhos que exceder R$ 10.000.000,00 e não\n ultrapassar R$ 30.000.000,00; e\n \n \n d) 22,5% sobre a parcela dos ganhos que ultrapassar R$ 30.000.000,00.\n \n \n
\n ),\n};\n\nconst EmitirDarfModalProps = (onCancel: () => void, onOk: () => void) => ({\n title: \"Você confirma a emissão do DARF?\",\n footer: ,\n content: (\n
\n

\n O arquivo gerado ficará disponível na aba Histórico e será enviado para\n o seu e-mail cadastrado.\n

\n
\n ),\n});\n\nconst ReemitirDarfModalProps = (onCancel: () => void, onOk: () => void) => ({\n title: \"Você confirma a emissão de um novo DARF?\",\n footer: ,\n content: (\n
\n

\n Ao confirmar, o DARF anterior será substituido. O arquivo gerado\n ficará disponível na aba Histórico e será enviado para o seu e-mail\n cadastrado.\n

\n
\n ),\n});\n\nexport const DarfModal = (\n reemit: boolean,\n onCancel: () => void,\n onOk: () => void\n) =>\n reemit\n ? ReemitirDarfModalProps(onCancel, onOk)\n : EmitirDarfModalProps(onCancel, onOk);\n\ninterface IEdit {\n value: any;\n id: string;\n isEditting: boolean;\n}\ninterface DarfResultDescriptionsProps {\n id: string;\n label: (onClick: Function) => React.ReactNode;\n Component: React.FC<{\n data: IDarfBolsa;\n url: string;\n year: number;\n month: number;\n loading: boolean;\n disabled: boolean;\n view?: boolean;\n handleEdit?: Function;\n setDataCripto?: React.Dispatch>;\n setDataBolsa?: React.Dispatch>;\n valorPrincipal?: number;\n setEditedAccumulatedTax?: React.Dispatch>;\n getTaxes?: (\n a?: boolean,\n b?: boolean,\n atualizouImpostoAcumulado?: boolean,\n nAtualizarPrejuizosAcumulados?: boolean\n ) => void;\n }>;\n}\n\nexport const DarfResultDescriptions: DarfResultDescriptionsProps[] = [\n {\n id: \"impostoTotal\",\n label: () => \"(+) Valor do principal\",\n Component: ({ data, view }) => {\n return formatCurrency(\n Math.max(\n 0,\n Number(\n (data.impostoComumFinal || 0) +\n (data.impostoDTFinal || 0) +\n (data.impostoFIIFinal || 0)\n ) +\n (Number(data[\"impostoAcumulado\"] || 0) -\n Number(data[\"irrfTotal\"] || 0))\n )\n );\n },\n },\n {\n id: \"impostoTotal\",\n label: () => (\n \n (+) Imposto devido\n \n ),\n Component: ({ data, view }) => {\n return formatCurrency(\n Number(\n (data.impostoComumFinal || 0) +\n (data.impostoDTFinal || 0) +\n (data.impostoFIIFinal || 0)\n )\n );\n },\n },\n {\n id: \"impostoAcumulado\",\n label: (onClick: any) => (\n \n (+) DARFs passados abaixo de R$ {minDarfPrice}\n }\n onClick={() => onClick(MinPriceModalProps)}\n />\n \n ),\n Component: ({\n data,\n year,\n month,\n loading,\n disabled,\n setDataBolsa,\n setDataCripto,\n url,\n getTaxes,\n setEditedAccumulatedTax,\n }) => {\n const { currentPage } = useBroker();\n const [edit, setEdit] = useState();\n const [editForm] = Form.useForm();\n const handleEditValue = (id: string) => {\n const value = data[id as keyof (IDarf | IDarfBolsa)];\n setEdit({ id, isEditting: true, value });\n editForm.setFieldsValue({ [id]: value });\n };\n\n const handleEditValueCancel = () => {\n setEdit(undefined);\n editForm.resetFields();\n };\n const handleEditValueConfirm = () => {\n if (edit && edit.value >= 0 && edit.value < minDarfPrice) {\n (currentPage?.api || apis)\n .post(`${url}/updateDataDarf`, {\n year,\n month: month + 1,\n [edit.id]: edit.value,\n })\n .then(() => {\n getTaxes?.(true, true, true, true);\n setEditedAccumulatedTax?.(true);\n return (setDataCripto ?? setDataBolsa)?.((data: any) => ({\n ...data,\n [edit.id]: edit.value,\n }));\n })\n .catch(() => message.error(errorMessage))\n .finally(() => handleEditValueCancel());\n } else {\n handleEditValueCancel();\n }\n };\n return edit && edit.isEditting && edit.id === \"impostoAcumulado\" ? (\n
\n {!isMobile() && (\n \n {isMobile() && (\n
\n ) : (\n \n {formatCurrency(Number(data.impostoAcumulado || 0))}\n {disabled && (\n }\n onClick={() => handleEditValue(\"impostoAcumulado\")}\n />\n )}\n \n );\n },\n },\n {\n id: \"irrfTotal\",\n label: (onClick: any) => (\n \n (-) Imposto de Renda Retido na Fonte\n }\n onClick={() => onClick(IRRFModalProps)}\n />\n \n ),\n Component: ({ data, handleEdit, view }) => (\n \n {formatCurrency(Number((data as IDarfBolsa)[\"irrfTotal\"] || 0))}\n {!view && (\n }\n onClick={() => handleEdit?.()}\n />\n )}\n \n ),\n },\n {\n id: \"multa\",\n label: (onClick: any) => (\n
\n (+) Multa de atraso{\" \"}\n }\n onClick={() => onClick(MultaModalProps)}\n />\n
\n ),\n Component: ({ data, view, valorPrincipal }) =>\n // view\n // ? formatCurrency(data[\"multa\"] || 0)\n // :\n formatCurrency(\n (valorPrincipal || 0) < minDarfPrice ? 0 : data[\"multa\"] || 0\n ),\n },\n {\n id: \"juros\",\n label: (onClick: any) => (\n
\n (+) Juros e/ou encargos de atraso{\" \"}\n }\n onClick={() => onClick(JurosModalProps)}\n />\n
\n ),\n Component: ({ data, view, valorPrincipal }) =>\n // view\n // ? formatCurrency(data[\"juros\"] || 0)\n // :\n formatCurrency(\n (valorPrincipal || 0) < minDarfPrice ? 0 : Number(data[\"juros\"] || 0)\n ),\n },\n];\n\nexport const DarfImpostosDevidosDescriptions = [\n {\n id: \"totalGanho\",\n label: () => \"Ganho total\",\n },\n {\n id: \"aliquotaDevida\",\n label: (onClick: any) => (\n
\n (x) Alíquota devida\n }\n onClick={() => onClick(AliquotaModalProps)}\n />\n
\n ),\n render: (data: any) =>\n `${replaceDotByComma(\n Number((data[\"aliquotaDevida\"] || 0).toFixed(2))\n )} %`,\n },\n {\n id: \"impostoDevido\",\n label: () => \"Imposto devido\",\n render: (data: any, view?: boolean) =>\n formatCurrency(\n !view\n ? Number(data[\"impostoDevido\"] || 0)\n : Number(data[\"impostoDevido\"] || 0) -\n Number(data[\"impostoDevido\"] ? data[\"impostoAcumulado\"] || 0 : 0)\n ),\n },\n];\n\nexport const AddTransactionGOVFormItemRows = (hasLandingSide: boolean) => {\n if (!hasLandingSide)\n return [\n [FormItemsBolsa.id],\n [FormItemsBolsa.code(\"Ex: PETR3\")],\n [FormItemsBolsa.quantity(\"Ex: 100\")],\n [FormItemsBolsa.avgBuyPriceGOV],\n ];\n\n return [\n [FormItemsBolsa.id],\n [FormItemsBolsa.code(\"Ex: PETR3\")],\n [FormItemsBolsa.quantity(\"Ex: 100\")],\n [FormItemsBolsa.avgBuyPriceGOV],\n [FormItemsBolsa.lendingSide],\n ];\n};\n\nexport const AddTransactionFormItemRows = (hasLandingSide: boolean) => {\n if (!hasLandingSide)\n return [\n [FormItemsBolsa.id],\n [FormItemsBolsa.code(\"Ex: PETR3\")],\n [FormItemsBolsa.quantity(\"Ex: 100\")],\n [FormItemsBolsa.avgBuyPrice],\n ];\n\n return [\n [FormItemsBolsa.id],\n [FormItemsBolsa.code(\"Ex: PETR3\")],\n [FormItemsBolsa.quantity(\"Ex: 100\")],\n [FormItemsBolsa.avgBuyPrice],\n [FormItemsBolsa.lendingSide],\n ];\n};\n\nconst FormItemsBolsa = {\n id: TextFormItem({\n name: \"id\",\n label: \"Id\",\n hidden: true,\n }),\n date: (month: number, year: number) =>\n DateFormItem({\n name: \"date\",\n label: `Dia do mês de ${months[month]}/${year}`,\n placeholder: `01/${zero(month + 1)}/${year}`,\n mask: `99/${zero(month + 1).replace(/[9]/g, `\\\\9`)}/${year\n .toString()\n .replace(/[9]/g, `\\\\9`)}`,\n rules: validationDateIsOnReferenceMonth(month, year),\n }),\n code: (placeholder: string) =>\n TextFormItem({\n name: \"code\",\n label: \"Ativo\",\n placeholder,\n rules: validationFieldRequired,\n }),\n quantity: (placeholder: string) =>\n NumberFormItem({\n name: \"quantity\",\n label: \"Quantidade\",\n placeholder,\n decimalScale: 12,\n rules: validationNumberFieldPositive,\n }),\n avgBuyPrice: CurrencyFormItem({\n name: \"avgBuyPrice\",\n label: \"Custo de compra\",\n }),\n avgBuyPriceGOV: CurrencyFormItem({\n name: \"avgBuyPrice\",\n label: \"Custo médio de compra (por ação)\",\n }),\n price: CurrencyFormItem({ name: \"price\", label: \"Preço de venda\" }),\n feeB3: CurrencyFormItem({ name: \"feeB3\", label: \"Taxas\" }),\n capitalGain: CurrencyFormItem({\n name: \"capitalGain\",\n label: \"Ganho\",\n disabled: true,\n allowNegative: true,\n rules: validationNumberAllowNegativeField,\n onChange: (changed, values) => {\n const precoVenda = changed.price\n ? currencyToNumber(changed.price)\n : values.price;\n const custoCompra = changed.avgBuyPrice\n ? currencyToNumber(changed.avgBuyPrice)\n : values.avgBuyPrice;\n const taxas = changed.feeB3\n ? currencyToNumber(changed.feeB3)\n : values.feeB3;\n return Number(values.quantity) * (precoVenda - custoCompra) - taxas;\n },\n }),\n operacao: SelectFormItem({\n name: \"operacao\",\n label: \"Operação\",\n placeholder: \"Selecione\",\n mustUpdate: true,\n options: [\n { label: \"Comum\", value: \"Comum\" },\n { label: \"Day Trade\", value: \"Day Trade\" },\n { label: \"Fundos Imobiliários\", value: \"FII\" },\n ],\n }),\n market: ({ data }: any) => {\n const marketCorrect =\n data.market === \"Mercado a Vista Exercido\" ||\n data.market === \"Merc. Fracionário\";\n\n return SelectFormItem({\n name: \"market\",\n label: \"Mercado\",\n placeholder: \"Selecione\",\n options: [\n ...(marketCorrect ? [{ label: data.market, value: data.market }] : []),\n { label: \"Mercado à vista\", value: \"Mercado a Vista\" },\n ...(data.operacao !== \"FII\"\n ? [\n { label: \"Mercado de opções\", value: \"Mercado de opções\" },\n { label: \"Outros mercados\", value: \"Outros mercados\" },\n ]\n : []),\n ],\n onChange: (changed, values) =>\n values.operacao === \"FII\" && values.market !== \"Mercado a Vista\"\n ? \"Mercado a Vista\"\n : values.market,\n });\n },\n lendingSide: SelectFormItem({\n name: \"lendingSide\",\n label: \"Posição\",\n placeholder: \"Selecione\",\n options: [\n { label: \"Doador\", value: \"Doador\" },\n { label: \"Tomador\", value: \"Tomador\" },\n ],\n }),\n};\n\nconst FormItemsDoacoesHerancas = {\n _id: TextFormItem({\n name: \"_id\",\n label: \"Id\",\n hidden: true,\n }),\n dateView: DateFormItem2({\n name: \"dateView\",\n label: \"Data\",\n mask: '99/99/9999',\n }),\n code: (placeholder: string) =>\n TextFormItem({\n name: \"code\",\n label: \"Ativo\",\n placeholder,\n rules: validationFieldRequired,\n }),\n quantity: (placeholder: string) =>\n NumberFormItem({\n name: \"quantity\",\n label: \"Quantidade\",\n placeholder,\n decimalScale: 12,\n rules: validationNumberFieldPositive,\n }),\n price: CurrencyFormItem({ name: \"price\", label: \"Custo médio de compra (por ação)\" }),\n};\n\nconst FormItemsCrypto = {\n id: TextFormItem({\n name: \"id\",\n label: \"Id\",\n hidden: true,\n }),\n data: (month: number, year: number) =>\n DateFormItem({\n name: \"data\",\n label: `Dia do mês de ${months[month]}/${year}`,\n placeholder: `01/${zero(month + 1)}/${year}`,\n mask: `99/${zero(month + 1).replace(/[9]/g, `\\\\9`)}/${year\n .toString()\n .replace(/[9]/g, `\\\\9`)}`,\n rules: validationDateIsOnReferenceMonth(month, year),\n }),\n ativo: (placeholder: string) =>\n TextFormItem({\n name: \"ativo\",\n label: \"Ativo\",\n placeholder,\n rules: validationFieldRequired,\n }),\n quantidade: (placeholder: string) =>\n NumberFormItem({\n name: \"quantidade\",\n label: \"Quantidade\",\n placeholder,\n decimalScale: 12,\n rules: validationNumberFieldPositive,\n }),\n precoVenda: CurrencyFormItem({ name: \"precoVenda\", label: \"Preço de venda\" }),\n custoCompra: CurrencyFormItem({\n name: \"custoCompra\",\n label: \"Custo de compra\",\n }),\n taxas: CurrencyFormItem({ name: \"taxas\", label: \"Taxas\" }),\n ganho: CurrencyFormItem({\n name: \"ganho\",\n label: \"Ganho\",\n disabled: true,\n onChange: (changed, values) => {\n const precoVenda = changed.precoVenda\n ? currencyToNumber(changed.precoVenda)\n : values.precoVenda;\n const custoCompra = changed.custoCompra\n ? currencyToNumber(changed.custoCompra)\n : values.custoCompra;\n const taxas = changed.taxas\n ? currencyToNumber(changed.taxas)\n : values.taxas;\n return Number(\n Math.max(\n 0,\n Number(values.quantidade) * (precoVenda - custoCompra) - taxas\n ).toFixed(2)\n );\n },\n }),\n operacao: SelectFormItem({\n name: \"operacao\",\n label: \"Operação\",\n placeholder: \"Selecione\",\n options: [\n { label: \"Comum\", value: \"comum\" },\n { label: \"Day Trade\", value: \"daytrade\" },\n ],\n }),\n mercado: SelectFormItem({\n name: \"mercado\",\n label: \"Mercado\",\n placeholder: \"Selecione\",\n options: [\n { label: \"Mercado à vista\", value: \"mercado\" },\n { label: \"Mercado de opções\", value: \"mercadoOpcoes\" },\n { label: \"Outros mercados\", value: \"outros\" },\n ],\n }),\n};\n\nconst PrejuFormItems = {\n userPrejuizoComum: (disabled: boolean) =>\n CurrencyFormItem({\n disabled,\n name: \"userPrejuizoComum\",\n label: \"Prejuízo Comum\",\n }),\n userPrejuizoDayTrade: (disabled: boolean) =>\n CurrencyFormItem({\n disabled,\n name: \"userPrejuizoDayTrade\",\n label: \"Prejuízo Day Trade\",\n }),\n userPrejuizoFII: (disabled: boolean) =>\n CurrencyFormItem({\n disabled,\n name: \"userPrejuizoFII\",\n label: \"Prejuízo FII\",\n }),\n};\n\nconst CorretagemFormItems = {\n userCustoCorretagemComum: (disabled: boolean) =>\n CurrencyFormItem({\n disabled,\n name: \"userCustoCorretagemComum\",\n label: \"Operações Comum\",\n }),\n userCustoCorretagemDT: (disabled: boolean) =>\n CurrencyFormItem({\n disabled,\n name: \"userCustoCorretagemDT\",\n label: \"Operações Day Trade\",\n }),\n userCustoCorretagemFII: (disabled: boolean) =>\n CurrencyFormItem({\n disabled,\n name: \"userCustoCorretagemFII\",\n label: \"Operações FII\",\n }),\n};\n\nconst IrrfFormItem = {\n userIrrfComum: CurrencyFormItem({\n name: \"userIrrfComum\",\n label: \"IRRF Comum\",\n }),\n userIrrfDayTrade: CurrencyFormItem({\n name: \"userIrrfDayTrade\",\n label: \"IRRF Day Trade\",\n }),\n userIrrfFII: CurrencyFormItem({\n name: \"userIrrfFII\",\n label: \"IRRF FII\",\n }),\n userIrrfTotal: CurrencyFormItem({\n name: \"userIrrfTotal\",\n label: \"IRRF Total (Comum + Day Trade + FII)\",\n disabled: true,\n onChange: (changed, values) => {\n const userIrrfComum = changed.userIrrfComum\n ? currencyToNumber(changed.userIrrfComum)\n : values.userIrrfComum;\n const userIrrfDayTrade = changed.userIrrfDayTrade\n ? currencyToNumber(changed.userIrrfDayTrade)\n : values.userIrrfDayTrade;\n const userIrrfFII = changed.userIrrfFII\n ? currencyToNumber(changed.userIrrfFII)\n : values.userIrrfFII;\n return (\n Number(userIrrfComum ?? 0) +\n Number(userIrrfDayTrade ?? 0) +\n Number(userIrrfFII ?? 0)\n );\n },\n }),\n};\n\nexport const IrrfFormItemRows = [\n [IrrfFormItem.userIrrfComum],\n [IrrfFormItem.userIrrfDayTrade],\n [IrrfFormItem.userIrrfFII],\n [IrrfFormItem.userIrrfTotal],\n];\n\nexport const PrejuFormItemRows = (disabled: boolean) => [\n [PrejuFormItems.userPrejuizoComum(disabled)],\n [PrejuFormItems.userPrejuizoDayTrade(disabled)],\n [PrejuFormItems.userPrejuizoFII(disabled)],\n];\n\nexport const CorretagemFormItemRows = (disabled: boolean) => [\n [CorretagemFormItems.userCustoCorretagemComum(disabled)],\n [CorretagemFormItems.userCustoCorretagemDT(disabled)],\n [CorretagemFormItems.userCustoCorretagemFII(disabled)],\n];\n\nexport const DarfFormItemRows = (month: number, year: number) => [\n [FormItemsCrypto.id],\n [FormItemsCrypto.data(month, year), FormItemsCrypto.ativo(\"Ex: BTC\")],\n [FormItemsCrypto.quantidade(\"Ex: 0,00101\")],\n [FormItemsCrypto.precoVenda, FormItemsCrypto.custoCompra],\n [FormItemsCrypto.taxas],\n [FormItemsCrypto.ganho],\n];\n\nexport const DarfBolsaFormItemRows = (month: number, year: number) => [\n [FormItemsBolsa.id],\n [FormItemsBolsa.operacao, FormItemsBolsa.market],\n [FormItemsBolsa.date(month, year), FormItemsBolsa.code(\"Ex: PETR3\")],\n [FormItemsBolsa.quantity(\"Ex: 100\"), FormItemsBolsa.price],\n [FormItemsBolsa.avgBuyPrice, FormItemsBolsa.feeB3],\n [FormItemsBolsa.capitalGain],\n];\n\nexport const DoacoesHerancasRows = () => [\n [FormItemsDoacoesHerancas._id],\n [FormItemsDoacoesHerancas.code(\"Ex: PETR3\")],\n [FormItemsDoacoesHerancas.dateView],\n [FormItemsDoacoesHerancas.quantity(\"Ex: 100\")],\n [FormItemsDoacoesHerancas.price],\n];\n\nexport const DarfBolsaTabs: (\n data: IDarfBolsa,\n rest: any\n) => { class: string; tabs: { content: React.ReactNode }[] }[] = (\n data,\n rest\n) => {\n return [\n {\n class: \"header\",\n tabs: [\n {\n content: \"\",\n },\n {\n content: \"Comum\",\n },\n {\n content: \"Day Trade\",\n },\n {\n content: \"FII\",\n },\n ],\n },\n {\n class: \"sub-header\",\n tabs: [\n {\n content: \"Resultado\",\n },\n {\n content: formatCurrency(data.varTotaisComum ?? 0),\n },\n {\n content: formatCurrency(data.varTotaisDT ?? 0),\n },\n {\n content: formatCurrency(data.varTotaisFII ?? 0),\n },\n ],\n },\n {\n class: \"sub-header\",\n tabs: [\n {\n content: \"Ganhos tributáveis\",\n },\n {\n content: formatCurrency(data.ganhoComum ?? 0),\n },\n {\n content: formatCurrency(data.ganhoDT ?? 0),\n },\n {\n content: formatCurrency(data.ganhoFII ?? 0),\n },\n ],\n },\n {\n class: \"sub-header opacity\",\n tabs: [\n {\n content: (\n <>\n (-) Prejuízos a compensar\n {!rest.view && (\n }\n onClick={rest.handleEditPreju}\n />\n )}\n \n ),\n },\n {\n content: formatCurrency(\n data.userPrejuizoComum ?? data.prejuizoComum ?? 0\n ),\n },\n {\n content: formatCurrency(\n data.userPrejuizoDayTrade ?? data.prejuizoDayTrade ?? 0\n ),\n },\n {\n content: formatCurrency(\n data.userPrejuizoFII ?? data.prejuizoFII ?? 0\n ),\n },\n ],\n },\n {\n class: \"sub-header opacity\",\n tabs: [\n {\n content: \"(x) Alíquota devida\",\n },\n {\n content: numberToPercentage(15, 0),\n },\n {\n content: numberToPercentage(20, 0),\n },\n {\n content: numberToPercentage(20, 0),\n },\n ],\n },\n {\n class: \"sub-header strong\",\n tabs: [\n {\n content: \"Imposto devido\",\n },\n {\n content: formatCurrency(data.impostoComumFinal ?? 0),\n },\n {\n content: formatCurrency(data.impostoDTFinal ?? 0),\n },\n {\n content: formatCurrency(data.impostoFIIFinal ?? 0),\n },\n ],\n },\n ];\n};\n","import { getLastBusinessDay } from \"../utils\";\n\nexport const getDolarQuote = (date: Date, quotes: any[]) => {\n const newDate15Day = new Date(new Date(date).setDate(15));\n let newDateLastMonth = new Date(\n newDate15Day.setMonth(newDate15Day.getMonth() - 1),\n );\n let isRuning = true;\n let count = 0;\n\n while (isRuning) {\n const lastBusinessDay = getLastBusinessDay(newDateLastMonth);\n const day =\n lastBusinessDay.getDate() <= 9\n ? `0${lastBusinessDay.getDate()}`\n : lastBusinessDay.getDate();\n const month =\n lastBusinessDay.getMonth() + 1 <= 9\n ? `0${lastBusinessDay.getMonth() + 1}`\n : lastBusinessDay.getMonth() + 1;\n const year = lastBusinessDay.getFullYear();\n\n const cotacaoCompra = quotes.find(q => `${day}/${month}/${year}` === q.dataHoraCotacao)?.cotacaoCompra\n if (cotacaoCompra || count === 5) {\n isRuning = false;\n return cotacaoCompra || 0;\n } else {\n newDateLastMonth = new Date(\n newDateLastMonth.setDate(newDateLastMonth.getDate() - 1),\n );\n }\n count += 1;\n\n }\n};\n\nexport const getQuoteFortnight = (date: Date, quotes: any) => {\n const newDate15Day = new Date(new Date(date).setDate(15));\n let newDateLastMonth = new Date(\n newDate15Day.setMonth(newDate15Day.getMonth() - 1),\n );\n let isRuning = true;\n let count = 0;\n\n while (isRuning) {\n const lastBusinessDay = getLastBusinessDay(newDateLastMonth);\n const day =\n lastBusinessDay.getDate() <= 9\n ? `0${lastBusinessDay.getDate()}`\n : lastBusinessDay.getDate();\n const month =\n lastBusinessDay.getMonth() + 1 <= 9\n ? `0${lastBusinessDay.getMonth() + 1}`\n : lastBusinessDay.getMonth() + 1;\n const year = lastBusinessDay.getFullYear();\n\n let cotacaoCompra;\n for (const key in quotes) {\n if (`${day}/${month}/${year}` === key) {\n cotacaoCompra = quotes[key]?.compra;\n }\n }\n if (cotacaoCompra || count === 5) {\n isRuning = false;\n return cotacaoCompra || 0;\n } else {\n newDateLastMonth = new Date(\n newDateLastMonth.setDate(newDateLastMonth.getDate() - 1),\n );\n }\n count += 1;\n\n }\n};\n","import { maxDarfPrice, minDarfPrice } from \"../../constants/darf\";\n\nexport const fator = (item: any) => {\n const value = (item.quantity || 0) * (item.sellPrice || 0);\n const code = item.code?.substring(0, 3)?.toUpperCase() || \"\";\n switch (code) {\n case \"WIN\":\n return value * 5;\n case \"WDO\":\n return value / 10;\n case \"DOL\":\n return value / 50;\n case \"IAP\":\n return value / 25;\n case \"ETN\":\n return value / 30;\n case \"ETH\":\n {\n if (item.code?.substring(3, 4)?.toUpperCase() == \"E\") return value\n else return value / 30\n }\n case \"SOY\":\n return value / 34;\n case \"CNY\":\n return value / 35;\n case \"EUR\":\n return value / 50;\n case \"ICF\":\n return value / 100;\n case \"KFE\":\n return value / 100;\n case \"OZ1\":\n return value / 250;\n case \"CCM\":\n {\n if (item.code?.substring(3, 4)?.toUpperCase() == \"E\") return value\n else return value / 450\n }\n case \"SFI\":\n return value / 450;\n case \"SJC\":\n return value / 450;\n case \"ACF\":\n return value / 508;\n case \"BGI\":\n return value / 330;\n case \"BIT\":\n {\n if (item.code?.substring(3, 4)?.toUpperCase() == \"H\") return value\n else return value / 0.1\n }\n default:\n return value;\n }\n};\n\nexport const vendasTotais = (item: any) => \n item.transactions.reduce((a: number, t: any) => a + fator(t), 0);\n\nconst exteriorTransactionsFilter = (el: any) =>\n (el.operation === \"SELL\" && !el?.type) ||\n (el.operation === \"SELL\" && el.manual) ||\n (el.operation === \"SELL\" &&\n (el.type === \"TRADE\" || el.type === \"WITHDRAW\")) ||\n el.type === \"INTEREST\";\n\nexport const vendasTotaisExt = (item: any) => {\n const vendasTotais = item.transactions?.filter(exteriorTransactionsFilter).reduce((a: number, t: any) => a + t.valor * t.cambioVenda, 0)\n \n return item.transactions ? vendasTotais : 0\n}\n \n\nexport const vendasIsentas = (item: any) => {\n const codigosIsentos = [\n \"FRTA3\",\n \"FRTA3F\",\n \"GSHP3\",\n \"GSHP3F\",\n \"NUTR3\",\n \"NUTR3F\",\n \"CRDE3\",\n \"CRDE3F\",\n \"PRNR3\",\n \"PRNR3F\",\n ];\n const vendasMercadoIsento = item.mercadoIsento || 0;\n const vendasMercadoComum =\n item.transactions\n ?.filter(\n (t: any) =>\n t.operacao === \"Comum\" &&\n !codigosIsentos.includes(t.code.toUpperCase())\n )\n ?.reduce((a: number, t: any) => a + fator(t), 0) || 0;\n return (\n vendasMercadoIsento + vendasMercadoComum\n );\n};\n\nexport const valueIsGreaterThanMin = (item: any) =>\n Math.max(\n 0,\n Number(\n (item?.impostoComumFinal || 0) +\n (item?.impostoDTFinal || 0) +\n (item?.impostoFIIFinal || 0)\n ) +\n (Number(item?.[\"impostoAcumulado\"] || 0) -\n Number(item?.[\"irrfTotal\"] || 0))\n ) >= minDarfPrice;\n\nexport const valueIsLessThanMax = (item: any) =>\n (item?.impostoTotalFinal || 0) <= maxDarfPrice;\n\nexport const showPayButton = (item: any) =>\n valueIsGreaterThanMin(item) &&\n valueIsLessThanMax(item) &&\n (item.status !== \"PAYED\" || !item.payed);\n\nexport const impostoCharge = (data?: any) => {\n const valorPrincipal = Math.max(\n 0,\n Number(\n (data?.impostoComumFinal || 0) +\n (data?.impostoDTFinal || 0) +\n (data?.impostoFIIFinal || 0)\n ) +\n (Number(data?.[\"impostoAcumulado\"] || 0) -\n Number(data?.[\"irrfTotal\"] || 0))\n );\n return (\n valorPrincipal +\n (valorPrincipal < minDarfPrice\n ? 0\n : (data?.multaAux ?? 0) + (data?.jurosAux ?? 0))\n );\n};\n","import { Collapse } from \"antd\";\nimport styled from \"styled-components\";\n\nexport const PosicaoCardStyled = styled(Collapse.Panel)`\n margin-bottom: 4px;\n border: none !important;\n border-radius: 4px !important;\n background-color: var(--velotax-background-color-ghost);\n\n &:last-of-type {\n margin-bottom: 0;\n }\n\n .ant-collapse-header {\n height: 72px;\n background-color: transparent;\n padding: 24px 72px 24px 32px !important;\n .ant-collapse-arrow {\n right: 32px !important;\n }\n\n .header {\n width: 100%;\n height: 24px;\n display: flex;\n align-items: center;\n justify-content: space-between;\n\n .title {\n font-weight: 700;\n font-size: 1.125rem;\n line-height: 1.5rem;\n color: var(--velotax-font-color-light);\n\n span {\n margin-left: 8px;\n font-weight: 600;\n font-size: 0.875rem;\n }\n }\n\n .posicao {\n font-weight: 600;\n font-size: 1.125rem;\n color: var(--velotax-font-color-light);\n }\n }\n }\n\n .ant-collapse-content {\n border: none;\n background-color: transparent;\n border-radius: 0 0 4px 4px !important;\n\n .ant-collapse-content-box {\n padding: 0 32px 32px;\n color: var(--velotax-font-color);\n & > div {\n & > span:first-child {\n width: 160px;\n display: inline-block;\n }\n & > span:not(:first-child) {\n margin-left: 16px;\n }\n }\n }\n }\n\n .hr-datails {\n margin: 15px 10px;\n opacity: 0.3;\n }\n\n .row-section {\n width: 100%;\n display: flex;\n flex-wrap: nowrap;\n\n .recharts-wrapper {\n transform: translateX(12px);\n }\n }\n .chart-section {\n flex-grow: 1;\n width: 300px;\n overflow: visible;\n margin: 1rem 0 0 2rem;\n\n .recharts-surface {\n margin-left: 0 !important;\n }\n\n .recharts-text {\n font-weight: 300;\n font-size: 13px;\n }\n }\n\n .recharts-surface {\n overflow: visible;\n }\n\n .chart-tooltip {\n width: 200px;\n height: 60px;\n background-color: white;\n box-shadow: 0 1px 4px 0 rgba(0, 0, 0, 0.2);\n padding: 0.5rem 1rem;\n display: flex;\n flex-direction: column;\n\n text {\n &:first-of-type {\n font-weight: 500;\n }\n &:last-of-type {\n color: var(--ant-primary-8);\n }\n }\n }\n\n .info-section {\n margin-top: 8px;\n div {\n display: flex;\n span {\n &:first-of-type {\n width: 160px;\n }\n &:not(:first-of-type) {\n margin-left: 16px;\n }\n }\n }\n h5 {\n color: var(--velotax-font-color-light);\n }\n }\n\n .info-title {\n font-size: 13px;\n margin: 1rem 0 0 0;\n\n &:first-of-type {\n margin: 0;\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n .ant-collapse-header {\n height: 64px;\n padding: 20px 48px 20px 16px !important;\n .ant-collapse-arrow {\n right: 16px !important;\n }\n .header {\n .title {\n min-width: 100px;\n font-size: 1rem;\n span {\n margin-left: 8px;\n font-size: 0.675rem;\n }\n }\n .posicao {\n font-size: 0.875rem;\n }\n }\n }\n .row-section {\n flex-wrap: wrap;\n .chart-section {\n margin: 0;\n }\n }\n .ant-collapse-content {\n .ant-collapse-content-box {\n padding: 0 16px 24px 16px;\n & > div {\n & > span:first-child {\n width: 128px;\n font-size: 0.75rem;\n letter-spacing: -0.5px;\n }\n & > span:not(:first-child) {\n font-size: 0.75rem;\n letter-spacing: -0.8px;\n }\n }\n }\n }\n }\n`;\n","import clsx from \"clsx\";\nimport { cpfInputMask, formatCurrency, isMobile, zero } from \"../../utils\";\nimport { VscClose } from \"react-icons/vsc\";\nimport { useState } from \"react\";\nimport api from \"../../services/api\";\nimport apiExterior from \"../../services/apiExterior\"\nimport { FaRegEdit } from \"react-icons/fa\";\nimport NumberFormat from \"react-number-format\";\nimport {\n validationCpf,\n validationDateIsOnReferenceMonth,\n validationFieldRequired,\n} from \"../../utils/formValidations\";\nimport { currencyToNumber } from \"../../utils\";\nimport { InfoCircleOutlined } from \"@ant-design/icons\";\nimport Button from \"../../components/Button\";\nimport { List, Form, message } from \"antd\";\nimport {\n CurrencyFormItem,\n DateFormItem,\n MaskFormItem,\n TextFormItem,\n} from \"../formItems\";\n\nconst ContainerRendimentosCell = ({ children }: { children: any }) => (\n
{children}
\n);\n\nexport const YearReport = 2023;\n\nconst minDarfPrice = 10;\n\nconst RendimentoFormItems = {\n id: TextFormItem({\n name: \"id\",\n label: \"Id\",\n hidden: true,\n }),\n date: (month: number, year: number) =>\n DateFormItem({\n required: true,\n placeholder: `01/${zero(month + 1)}/${year}`,\n mask: `99/${zero(month + 1).replace(/[9]/g, `\\\\9`)}/${year\n .toString()\n .replace(/[9]/g, `\\\\9`)}`,\n rules: validationDateIsOnReferenceMonth(month, year),\n name: \"date\",\n label: \"Data\",\n }),\n taxaCambio: MaskFormItem({\n name: \"taxaCambio\",\n label: \"Taxa de câmbio\",\n disabled: true,\n }),\n ativo: MaskFormItem({\n rules: validationFieldRequired,\n name: \"ativo\",\n label: \"Ativo\",\n }),\n impostoPagoExterior: CurrencyFormItem({\n name: \"impostoPagoExterior\",\n label: \"Imposto Pago no Exterior\",\n hide: ({ data }: any) => data?.tipo !== \"Exterior\",\n }),\n impostoPagoExteriorUsd: CurrencyFormItem({\n prefix: \"US$\",\n name: \"impostoPagoExteriorUsd\",\n label: \"Imposto pago no exterior (USD)\",\n }),\n valorRendimentoUsd: CurrencyFormItem({\n placeholder: \"US$ 0,00\",\n prefix: \"US$\",\n name: \"valorRendimentoUsd\",\n label: \"Valor bruto (USD)\",\n }),\n valorRendimento: CurrencyFormItem({\n name: \"valorRendimento\",\n label: \"Rendimento\",\n }),\n cpfPagador: MaskFormItem({\n mask: cpfInputMask,\n rules: validationCpf,\n name: \"cpfPagador\",\n label: \"CPF do pagador\",\n hide: ({ data }: any) => data?.tipo !== \"Trabalho Autônomo\",\n onChange: (changed: any, values: any) =>\n changed.cpfPagador\n ? changed.cpfPagador.replace(/[_.-]/g, \"\")\n : values.cpfPagador,\n }),\n cpfBeneficiario: MaskFormItem({\n mask: cpfInputMask,\n rules: validationCpf,\n name: \"cpfBeneficiario\",\n label: \"CPF do beneficiário\",\n hide: ({ data }: any) => data?.tipo !== \"Trabalho Autônomo\",\n onChange: (changed: any, values: any) =>\n changed.cpfBeneficiario\n ? changed.cpfBeneficiario.replace(/[_.-]/g, \"\")\n : values.cpfBeneficiario,\n }),\n};\n\ninterface IEdit {\n value: any;\n id: string;\n isEditting: boolean;\n}\n\nexport enum YearResumeStatusFromBackEnum {\n PAYED = \"PAYED\",\n PENDING = \"PENDING\",\n REGULAR = \"REGULAR\",\n NOT_PAYED = \"NOT_PAYED\",\n}\n\nexport interface IDarf {\n payed?: boolean;\n emitted?: boolean;\n multa: number;\n juros: number;\n totalAlienado: number;\n totalGanho: number;\n aliquotaDevida: number;\n impostoDevido: number;\n impostoAcumulado: number;\n totalImpostoDevido: number;\n memoriaCalculo: any[];\n regular?: boolean;\n status?: keyof typeof YearResumeStatusFromBackEnum;\n}\nexport interface IDarfBolsa {\n payed?: boolean;\n emitted?: boolean;\n aliquotaComum?: number;\n aliquotaDT?: number;\n aliquotaFII?: number;\n alienacoesComum?: number;\n alienacoesDT?: number;\n alienacoesFII?: number;\n ganhoComum?: number;\n ganhoDT?: number;\n ganhoFII?: number;\n impostoComumFinal?: number;\n impostoDTFinal?: number;\n impostoFIIFinal?: number;\n impostoTotal?: number;\n impostoTotalFinal?: number;\n irrfComum?: number;\n irrfDayTrade?: number;\n irrfFII?: number;\n irrfTotal?: number;\n jurosAux?: number;\n mercadoOpcoesComum?: number;\n mercadoOpcoesDT?: number;\n mercadoOutrosComum?: number;\n mercadoOutrosDT?: number;\n mercadoOutrosFII?: number;\n mercadoVistaComum?: number;\n mercadoVistaDT?: number;\n multaAux?: number;\n memoriaCalculo: any[];\n impostoAcumulado?: number;\n impostoDevido?: number;\n multa?: number;\n juros?: number;\n prejuizoComum?: number;\n prejuizoDayTrade?: number;\n prejuizoFII?: number;\n userPrejuizoComum?: number;\n userPrejuizoDayTrade?: number;\n userPrejuizoFII?: number;\n userIrrfComum?: number;\n userIrrfDayTrade?: number;\n userIrrfFII?: number;\n userIrrfTotal?: number;\n varTotaisComum?: number;\n varTotaisDT?: number;\n varTotaisFII?: number;\n}\n\nexport const MinPriceModalProps = {\n title: <>DARF abaixo de {formatCurrency(minDarfPrice)},\n content: (\n
\n

\n O sistema da Receita Federal não permite a emissão de um único DARF com\n valor abaixo de {formatCurrency(minDarfPrice)}.\n

\n

\n Caso seu DARF tenha ficado com um valor abaixo de{\" \"}\n {formatCurrency(minDarfPrice)}, o valor será repassado automaticamente\n para o mês seguinte e ficará visível no campo{\" \"}\n \n DARFs passados abaixo de {formatCurrency(minDarfPrice)}\n \n .\n

\n
\n ),\n};\n\nconst MultaModalProps = {\n title: \"Multa de Atraso\",\n content: (\n
\n

\n O pagamento dos impostos deve ser feito sempre até o último dia útil do\n mês subsequente aos ganhos realizados.\n

\n

\n Caso você tenha atrasado no pagamento do seu DARF, a sua multa de atraso\n será de 0,33% por dia de atraso (chegando, no máximo, a 20%) sobre o\n valor do principal, calculados a partir do primeiro dia útil depois do\n dia do vencimento do DARF.\n

\n
\n ),\n};\n\nexport const ExteriorValueProps = {\n title: <>Impostos Pagos no Exterior,\n content: (\n
\n

\n Valor total dos impostos retidos e/ou pagos no exterior no mês\n selecionado\n

\n
\n ),\n};\n\nconst JurosModalProps = {\n title: \"Juros de Atraso\",\n content: (\n
\n

\n O pagamento dos impostos deve ser feito sempre até o último dia útil do\n mês subsequente aos ganhos realizados.\n

\n

\n Caso você tenha atrasado no pagamento do seu DARF, os seus juros de\n atraso serão equivalentes a taxa Selic acumulada até o mês anterior ao\n do pagamento, mais 1% no mês do pagamento, sobre o valor principal,\n contados a partir do mês subsequente ao vencimento do DARF.\n

\n
\n ),\n};\n\nexport const RendimentoFormItemRows = (month: number, year: number) => [\n [RendimentoFormItems.id],\n [RendimentoFormItems.date(month, year)],\n [RendimentoFormItems.taxaCambio],\n [RendimentoFormItems.ativo],\n [RendimentoFormItems.valorRendimentoUsd],\n [RendimentoFormItems.impostoPagoExteriorUsd],\n // [RendimentoFormItems.valorRendimento],\n // [RendimentoFormItems.cpfPagador],\n // [RendimentoFormItems.cpfBeneficiario],\n // [RendimentoFormItems.impostoPagoExterior],\n];\n\nexport const ImpostoTotalRendimentosAutonomos = [\n {\n id: \"impostoDevido\",\n label: () => \"(+) Valor do principal\",\n Component: ({ data }: any) => {\n const impostoPrincipal =\n (data?.impostoDevido ?? 0) + (data?.impostoAcumulado ?? 0) - (data?.gastosExterior ?? 0);\n\n return (\n \n {formatCurrency(impostoPrincipal)}\n \n );\n },\n },\n {\n id: \"impostoDevido\",\n label: () => (\n \n (+) Imposto devido\n \n ),\n Component: ({ data }: any) => (\n \n {formatCurrency(Number(data?.impostoDevido || 0))}\n \n ),\n },\n {\n id: \"impostoAcumulado\",\n label: (onClick: any) => (\n \n (+) DARFs passados abaixo de R$ 10\n }\n onClick={() => onClick(MinPriceModalProps)}\n />\n \n ),\n Component: ({\n data,\n year,\n month,\n loading,\n disabled,\n setDataBolsa,\n setDataCripto,\n id,\n monthStock,\n user,\n setImpostos,\n setId,\n getRendimentos,\n }: any) => {\n const [edit, setEdit] = useState();\n const [editForm] = Form.useForm();\n const handleEditValue = (id: string) => {\n const value = data?.[id as keyof (IDarf | IDarfBolsa)];\n setEdit({ id, isEditting: true, value });\n editForm.setFieldsValue({ [id]: value });\n };\n\n const handleEditValueCancel = () => {\n setEdit(undefined);\n editForm.resetFields();\n };\n const handleEditValueConfirm = async () => {\n if (edit && edit.value >= 0 && edit.value < minDarfPrice) {\n if (id !== \"\") {\n apiExterior\n .put(\"dividendos/rendimentos\", {\n _id: id,\n userCode: user.user.cpf,\n year,\n month: month + 1,\n monthStock,\n [edit.id]: edit.value,\n })\n .then(() => {\n setImpostos((data: any) => ({\n ...data,\n [edit.id]: edit.value,\n }));\n })\n .catch(() =>\n message.error(\n \"Algo inesperado aconteceu! Tente novamente mais tarde.\"\n )\n )\n .finally(() => {\n handleEditValueCancel();\n // getRendimentos();\n });\n } else {\n apiExterior\n .post(\"dividendos/rendimentos\", {\n monthStock,\n year,\n month: month + 1,\n juros: data.juros,\n multa: data.multa,\n userCode: user.user.cpf,\n total: data.impostoTotal,\n impostoDevido: data.impostoDevido,\n totalRendimentos: data.totalRendimentos,\n baseTributaria: data.baseTributaria,\n aliquotaDevida: data.aliquotaDevida,\n totalDependentes: data.totalDependentes,\n totalDespesas: data.totalDespesas,\n totalPrevidencia: data.totalPrevidencia,\n totalPensao: data.totalPensao,\n totalDeducoes: data.totalDeducoes,\n [edit.id]: edit.value,\n })\n .then(({ data }) => {\n (setDataCripto ?? setDataBolsa)?.((data: any) => ({\n ...data,\n [edit.id]: edit.value,\n }));\n setId(data._id);\n })\n .catch(() =>\n message.error(\n \"Algo inesperado aconteceu! Tente novamente mais tarde.\"\n )\n )\n .finally(() => handleEditValueCancel());\n }\n } else {\n handleEditValueCancel();\n }\n };\n return edit && edit.isEditting && edit.id === \"impostoAcumulado\" ? (\n
\n {!isMobile() && (\n \n {isMobile() && (\n
\n ) : (\n \n {formatCurrency(Number(data?.impostoAcumulado || 0))}\n {disabled && (\n }\n onClick={() => handleEditValue(\"impostoAcumulado\")}\n />\n )}\n \n );\n },\n },\n {\n id: \"gastosExterior\",\n label: (onClick: any) => (\n \n (-) Imposto Pago no Exterior\n }\n onClick={() => onClick(ExteriorValueProps)}\n />\n \n ),\n Component: ({\n data,\n year,\n month,\n loading,\n disabled,\n setDataBolsa,\n setDataCripto,\n id,\n monthStock,\n user,\n getRendimentos,\n setId,\n }: any) => {\n const [edit, setEdit] = useState();\n const [editForm] = Form.useForm();\n // const handleEditValue = (id: string) => {\n // const value = data?.[id as keyof (IDarf | IDarfBolsa)];\n // setEdit({ id, isEditting: true, value });\n // editForm.setFieldsValue({ [id]: value });\n // };\n\n const handleEditValueCancel = () => {\n setEdit(undefined);\n editForm.resetFields();\n };\n return edit && edit.isEditting && edit.id === \"gastosExterior\" ? (\n
\n */}\n
\n ) : (\n \n >\n {formatCurrency(Number(data?.gastosExterior || 0))}\n {/* {disabled && (\n }\n onClick={() => handleEditValue(\"gastosExterior\")}\n />\n )} */}\n \n );\n },\n },\n {\n id: \"multa\",\n label: (onClick: any) => (\n
\n (+) Multa de atraso{\" \"}\n }\n onClick={() => onClick(MultaModalProps)}\n />\n
\n ),\n Component: ({ data }: any) => (\n \n {formatCurrency(\n Number(data?.[\"impostoDevido\"] || 0) +\n Number(data?.[\"impostoAcumulado\"] || 0) <\n minDarfPrice\n ? 0\n : Number(data?.[\"multa\"] || 0)\n )}\n \n ),\n },\n {\n id: \"juros\",\n label: (onClick: any) => (\n
\n (+) Juros e/ou encargos de atraso{\" \"}\n }\n onClick={() => onClick(JurosModalProps)}\n />\n
\n ),\n Component: ({ data }: any) => (\n \n {formatCurrency(\n Number(data?.[\"impostoDevido\"] || 0) +\n Number(data?.[\"impostoAcumulado\"] || 0) <\n minDarfPrice\n ? 0\n : Number(data?.[\"juros\"] || 0)\n )}\n \n ),\n },\n];\n\nexport const ImpostoTotalRendimentos = [\n {\n id: \"impostoDevido\",\n label: () => \"(+) Valor do principal\",\n Component: ({ data }: any) => {\n const impostoPrincipal =\n (data?.impostoDevido ?? 0) + (data?.impostoAcumulado ?? 0) - (data?.impostoPagoExterior ?? 0);\n\n return (\n \n {formatCurrency(impostoPrincipal)}\n \n );\n },\n },\n {\n id: \"impostoDevido\",\n label: () => (\n \n (+) Imposto devido\n \n ),\n Component: ({ data }: any) => (\n \n {formatCurrency(Number(data?.impostoDevido || 0))}\n \n ),\n },\n {\n id: \"impostoAcumulado\",\n label: (onClick: any) => (\n \n (+) DARFs passados abaixo de R$ 10\n }\n onClick={() => onClick(MinPriceModalProps)}\n />\n \n ),\n Component: ({\n data,\n year,\n month,\n loading,\n disabled,\n setDataBolsa,\n setDataCripto,\n id,\n monthStock,\n user,\n }: any) => {\n const [edit, setEdit] = useState();\n const [editForm] = Form.useForm();\n const handleEditValue = (id: string) => {\n const value = data?.[id as keyof (IDarf | IDarfBolsa)];\n setEdit({ id, isEditting: true, value });\n editForm.setFieldsValue({ [id]: value });\n };\n\n const handleEditValueCancel = () => {\n setEdit(undefined);\n editForm.resetFields();\n };\n const handleEditValueConfirm = () => {\n if (edit && edit.value >= 0 && edit.value < minDarfPrice) {\n if (id !== \"\") {\n api\n .put(\"dividendos/rendimentos\", {\n _id: id,\n year,\n month: month + 1,\n [edit.id]: edit.value,\n })\n .then(() =>\n (setDataCripto ?? setDataBolsa)?.((data: any) => ({\n ...data,\n [edit.id]: edit.value,\n }))\n )\n .catch(() =>\n message.error(\n \"Algo inesperado aconteceu! Tente novamente mais tarde.\"\n )\n )\n .finally(() => handleEditValueCancel());\n } else {\n api\n .post(\"dividendos/rendimentos\", {\n monthStock,\n year,\n month: month + 1,\n juros: data.juros,\n multa: data.multa,\n userCode: user.user.cpf,\n total: data.impostoTotal,\n impostoDevido: data.impostoDevido,\n totalRendimentos: data.totalRendimentos,\n baseTributaria: data.baseTributaria,\n aliquotaDevida: data.aliquotaDevida,\n totalDependentes: data.totalDependentes,\n totalDespesas: data.totalDespesas,\n totalPrevidencia: data.totalPrevidencia,\n totalPensao: data.totalPensao,\n totalDeducoes: data.totalDeducoes,\n [edit.id]: edit.value,\n })\n .then(() =>\n (setDataCripto ?? setDataBolsa)?.((data: any) => ({\n ...data,\n [edit.id]: edit.value,\n }))\n )\n .catch(() =>\n message.error(\n \"Algo inesperado aconteceu! Tente novamente mais tarde.\"\n )\n )\n .finally(() => handleEditValueCancel());\n }\n } else {\n handleEditValueCancel();\n }\n };\n return edit && edit.isEditting && edit.id === \"impostoAcumulado\" ? (\n
\n \n
\n ) : (\n \n \n {formatCurrency(Number(data?.impostoAcumulado || 0))}\n \n {disabled && (\n }\n onClick={() => handleEditValue(\"impostoAcumulado\")}\n />\n )}\n \n );\n },\n },\n {\n id: \"multa\",\n label: (onClick: any) => (\n
\n (+) Multa de atraso{\" \"}\n }\n onClick={() => onClick(MultaModalProps)}\n />\n
\n ),\n Component: ({ data }: any) => (\n \n {formatCurrency(\n Number(data?.[\"impostoDevido\"] || 0) +\n Number(data?.[\"impostoAcumulado\"] || 0) <\n minDarfPrice\n ? 0\n : Number(data?.[\"multa\"] || 0)\n )}\n \n ),\n },\n {\n id: \"juros\",\n label: (onClick: any) => (\n
\n (+) Juros e/ou encargos de atraso{\" \"}\n }\n onClick={() => onClick(JurosModalProps)}\n />\n
\n ),\n Component: ({ data }: any) => (\n \n {formatCurrency(\n Number(data?.[\"impostoDevido\"] || 0) +\n Number(data?.[\"impostoAcumulado\"] || 0) <\n minDarfPrice\n ? 0\n : Number(data?.[\"juros\"] || 0)\n )}\n \n ),\n },\n];\n\nexport const RendimentosImpostosDevidos = [\n {\n id: \"totalRendimentos\",\n label: () => \"Total rendimentos\",\n render: (data: any) => (\n \n {formatCurrency(data?.totalRendimentos ?? 0)}\n \n ),\n },\n {\n id: \"aliquotaDevida\",\n label: (onClick: any) => (\n
\n (x) Alíquota devida\n }\n onClick={() => onClick(AliquotaModalProps)}\n />\n
\n ),\n render: (data: any) => (\n \n {((data?.aliquotaDevida as number) ?? 0).toFixed(2)}%\n \n ),\n },\n {\n id: \"impostoDevido\",\n label: () => \"Imposto devido\",\n render: (data: any) => (\n \n {formatCurrency(data?.impostoDevido ?? 0)}\n \n ),\n },\n];\n\nconst AliquotaModalProps = {\n title: \"Alíquota sobre Ganho Carnê-Leão\",\n content: (\n
\n

\n O imposto sobre rendimentos é calculado sobre o total recebido no mês,\n mediante a aplicação da seguinte tabela progressiva mensal:\n

\n \n a) Até R$ 2.112,00 não há impostos a pagar;\n \n b) De R$ 2.112,01 até R$ 2.826,65, a alíquota é de 7,5% sobre os\n rendimentos, com parcela a deduzir de R$ 142,80;\n \n \n c) De R$ 2.826,66 até R$ 3.751,05, a alíquota é de 15% sobre os\n rendimentos, com parcela a deduzir de R$ 354,80;\n \n \n d) De R$ 3.751,06 até R$ 4.664,68, a alíquota é de 22,5% sobre os\n rendimentos, com parcela a deduzir de R$ 636,13; e\n \n \n e) Acima de R$ 4.664,68, a alíquota é de 27,5% sobre os rendimentos,\n com parcela a deduzir de R$ 869,36.\n \n \n
\n ),\n};\n\nexport const ModalAutonomos = {\n title: \"Despesas de Autônomos\",\n content: (\n
\n

\n As seguintes despesas poderão ser deduzidas dos rendimentos recebidos de\n pessoas físicas por autônomos:\n

\n

- Aluguel do escritório/consultório

\n

- Água do escritório/consultório

\n

- Contribuições obrigatórias a entidades de classe

\n

- Condomínio do escritório/consultório

\n

- Emolumentos pagos a terceiros

\n

- Cópia e autenticação de documentos

\n

- Energia do escritório/consultório

\n

- Gás do escritório/consultório

\n

- IPTU do escritório/consultório quando pago pelo contribuinte

\n

- ISS

\n

- Material de conservação e limpeza do escritório/consultório

\n

- Material de escritório

\n

\n - Remuneração paga a terceiros, com vínculo empregatício, INSS e FGTS\n

\n

- Telefone do escritório/consultório

\n
\n ),\n};\n\nexport const ModalDependentes = {\n title: \"Dependentes\",\n content: (\n
\n

A Receita Federal considera como dependentes, mas não só:

\n

\n - Companheiro(a) com quem o contribuinte tenha filho ou viva há mais de\n 5 anos, ou cônjuge;\n

\n

- Filho(a) ou enteado(a), até 21 anos de idade;

\n

\n - Filho(a) ou enteado(a), se ainda estiverem cursando estabelecimento de\n ensino superior ou escola técnica de segundo grau, até 24 anos de idade;\n

\n

\n - Irmão(ã), neto(a) ou bisneto(a), sem arrimo dos pais, de quem o\n contribuinte detenha a guarda judicial, até 21 anos, ou em qualquer\n idade, quando incapacitado física ou mentalmente para o trabalho;\n

\n

\n - Irmão(ã), neto(a) ou bisneto(a), sem arrimo dos pais, com idade de 21\n anos até 24 anos, se ainda estiver cursando estabelecimento de ensino\n superior ou escola técnica de segundo grau, desde que o contribuinte\n tenha detido sua guarda judicial até os 21 anos;\n

\n

\n - Irmão(ã), neto(a) ou bisneto(a) com deficiência, sem arrimo dos pais,\n do(a) qual o contribuinte detém a guarda judicial, em qualquer idade,\n quando a sua remuneração não exceder as deduções autorizadas por lei\n (tendo em vista a decisão do Supremo Tribunal Federal – STF, na Ação\n Direta de Inconstitucionalidade nº 5.583/DF);\n

\n

\n - Pais, avós e bisavós que, em 2021, tenham recebido rendimentos,\n tributáveis ou não, até R$ 22.847,76;\n

\n

\n – Pessoa absolutamente incapaz, da qual o contribuinte seja\n tutor ou curador.\n

\n
\n ),\n};\n\nexport const ModalPensao = {\n title: \"Despesas com Pensão Alimentícia\",\n content: (\n
\n

\n Despesas com alimentos ou pensões, quando em cumprimento de decisão\n judicial ou acordo homologado judicialmente, são dedutíveis da base de\n cálculo do imposto sobre rendimentos.\n

\n

\n As despesas médicas e as de instrução, pagas em decorrência de decisão\n judicial ou acordo homologado na Justiça, não podem ser deduzidas na\n determinação da base de cálculo mensal. Esses pagamentos são dedutíveis\n apenas na Declaração de Ajuste Anual, obedecido o limite anual para os\n gastos com instrução.\n

\n
\n ),\n};\n\nexport const ModalPrevidencia = {\n title: \"Despesas com Previdência\",\n content: (\n
\n

\n Despesas com contribuição para a Previdência Social da União, dos\n Estados, do Distrito Federal e dos Municípios são dedutíveis da base de\n cálculo do imposto sobre rendimentos.\n

\n

\n As contribuições para as entidades de previdência privada domiciliadas\n no País, bem como as contribuições destinadas ao Fundo de Aposentadoria\n Programada Individual (FAPI), não podem ser deduzidas na determinação da\n base de cálculo mensal. Esses pagamentos são dedutíveis apenas na\n Declaração de Ajuste Anual.\n

\n
\n ),\n};\n","import moment from \"moment\";\nimport { Typography } from \"antd\";\nimport { InfoCircleOutlined } from \"@ant-design/icons\";\nimport React, { Dispatch, SetStateAction } from \"react\";\nimport { AiOutlineMinusCircle, AiOutlinePlusCircle } from \"react-icons/ai\";\nimport Loading from \"../../Loading\";\nimport { PosicaoCardStyled } from \"./styles\";\nimport { Posicao } from \"../../../contexts/CarteiraContext\";\nimport { CustoMedioModal } from \"../../../constants/darfBolsa\";\nimport { formatCurrency, numberToPercentageWallet } from \"../../../utils\";\nimport {\n Area,\n AreaChart,\n CartesianGrid,\n ResponsiveContainer,\n Tooltip,\n XAxis,\n YAxis,\n} from \"recharts\";\n\nconst negativeToPositive = (n: number) => (n < 0 ? n * -1 : n);\n\nconst signal = (n: number) => (n > 0 ? \"+\" : n < 0 ? \"-\" : \"\");\n\nconst className = (n: number) => (n === 0 ? \"\" : n > 0 ? \"success\" : \"error\");\n\nexport const LucroPrejuizo: React.FC<{\n n?: number;\n p?: number;\n cotacao?: number;\n}> = ({ n, p, cotacao }) => (\n \n {signal(n || 0)}\n {formatCurrency(negativeToPositive(n || 0))} ({signal(n || 0)}\n {numberToPercentageWallet(negativeToPositive(p || 0))})\n {cotacao && (\n \n {signal(n || 0)}\n {formatCurrency(negativeToPositive(n ? n / cotacao : 0), \"US$ \")}\n \n )}\n \n);\n\nexport const HidenValue: React.FC<{\n block?: boolean;\n strong?: boolean;\n currency?: boolean;\n}> = ({ block, strong, currency = true }) => {\n const value = `${currency ? \"R$ \" : \"\"}****`;\n const content = strong ? {value} : value;\n return block ?
{content}
: {content};\n};\n\ninterface PosicaoCardProps {\n key: string;\n posicao?: Partial;\n hideValues?: boolean;\n setHelpModal: Dispatch>;\n details?: any;\n loading?: boolean;\n cotacaoVenda?: number;\n}\n\nexport const PosicaoHeader = (\n posicao?: Partial,\n hideValues?: boolean\n) => {\n return (\n
\n
\n {posicao?.codigo || \"GOOGL\"}\n
\n
\n {hideValues ? (\n \n ) : (\n (posicao?.precoAtual || posicao?.posicao)\n ? formatCurrency(\n posicao?.categoria === \"TesouroDireto\"\n ? posicao?.precoAtual || 0\n : posicao?.posicao || 0\n )\n : formatCurrency(negativeToPositive(posicao?.lucroPrejuizoTotal || 0))\n )}\n
\n
\n );\n};\n\nexport const PosicaoBody = (\n posicao: Partial,\n setHelpModal: Dispatch>,\n hideValues?: boolean,\n details?: any,\n loading?: boolean,\n cotacaoVenda?: number\n) => {\n return (\n <>\n
\n Quantidade:\n \n {hideValues ? : posicao.quantidade}\n \n
\n \n
\n {posicao?.loan?.typeLoan === \"Tomador\" && (\n <>\n Preço de venda:\n \n {hideValues ? (\n \n ) : (\n formatCurrency(posicao.precoVenda || 0)\n )}\n \n \n )}\n
\n {posicao.hasPosition2019 && posicao?.loan?.typeLoan !== \"Tomador\" && (\n \n posicao.custoMedio === 0 || !posicao.custoMedio\n ? setHelpModal(CustoMedioModal)\n : null\n }\n >\n Custo médio de compra: \n \n {posicao.custoMedio === 0 || !posicao.custoMedio ? (\n \n ) : (\n formatCurrency(posicao.custoMedio)\n )}\n {cotacaoVenda && posicao.custoMedio && (\n \n {formatCurrency(\n posicao.custoMedio ? posicao.custoMedio / cotacaoVenda : 0,\n \"US$ \"\n )}\n \n )}\n \n \n )}\n {!posicao.hasPosition2019 && posicao?.loan?.typeLoan !== \"Tomador\" && (\n
\n {posicao.categoria === \"TesouroDireto\" ? (\n Valor Aplicado:\n ) : (\n Custo médio de compra:\n )}\n \n {posicao.custoMedio === 0 || !posicao.custoMedio ? (\n \"N/A\"\n ) : hideValues ? (\n \n ) : (\n formatCurrency(posicao.custoMedio)\n )}\n {cotacaoVenda && posicao.custoMedio && (\n \n {formatCurrency(\n posicao.custoMedio ? posicao.custoMedio / cotacaoVenda : 0,\n \"US$ \"\n )}\n \n )}\n \n
\n )}\n {posicao.categoria !== \"TesouroDireto\" &&\n posicao.categoria !== \"Bonds\" && (\n \n )}\n {posicao.hasPosition2019 && (\n \n posicao.lucroPrejuizoTotal === 0 || !posicao.lucroPrejuizoTotal\n ? setHelpModal(CustoMedioModal)\n : null\n }\n >\n Lucro/prejuízo total:{\" \"}\n {posicao.lucroPrejuizoTotal === 0 || !posicao.lucroPrejuizoTotal ? (\n \n ) : (\n \n )}\n \n )}\n {!posicao.hasPosition2019 && (\n \n )}\n {details &&\n (details?.marketCap !== \"N/A\" ||\n details?.beta !== \"N/A\" ||\n details?.peRatio !== \"N/A\" ||\n details?.earningDate !== \"N/A\" ||\n details?.dividendYield !== \"N/A\" ||\n details?.targetPrice !== \"N/A\" ||\n details?.enterpriseValueRevenue !== \"N/A\" ||\n details?.enterpriseValueEbitda !== \"N/A\") && (\n <>\n
\n
\n
\n \n Negociação\n \n
\n Captalização de mercado:\n \n {hideValues ? (\n \n ) : (\n <>\n {formatCurrency(\n Number(details?.marketCap || 0) / 1000000000\n )}{\" \"}\n B\n \n )}\n \n
\n
\n Preço-alvo da ação:\n \n {hideValues ? (\n \n ) : typeof details?.targetPrice === \"string\" ? (\n details?.targetPrice\n ) : (\n formatCurrency(details?.targetPrice)\n )}\n \n
\n
\n Dividend yield (1YFW):\n \n {hideValues ? (\n \n ) : typeof details?.dividendYield === \"string\" ? (\n details?.dividendYield\n ) : (\n `${(details?.dividendYield * 100)?.toFixed(2)}%`\n )}\n \n
\n
\n Divulgação de resultados:\n \n {hideValues ? (\n \n ) : (\n details?.earningDate\n )}\n \n
\n \n Avaliação\n \n {/*
\n Beta:\n \n {hideValues ? : typeof details?.beta !== 'string' ? details?.beta?.toFixed(2) : details?.beta}\n \n
*/}\n
\n EV/Receita (1YFW):\n \n {hideValues ? (\n \n ) : (\n `${\n typeof details?.enterpriseValueRevenue !== \"string\"\n ? `${details?.enterpriseValueRevenue?.toFixed(1)} x`\n : details?.enterpriseValueRevenue\n }`\n )}\n \n
\n
\n EV/EBITDA (1YFW):\n \n {hideValues ? (\n \n ) : (\n `${\n typeof details?.enterpriseValueEbitda !== \"string\"\n ? `${details?.enterpriseValueEbitda?.toFixed(1)} x`\n : details?.enterpriseValueEbitda\n }`\n )}\n \n
\n
\n P/E (1YFW):\n \n {hideValues ? (\n \n ) : (\n `${\n typeof details?.peRatio !== \"string\"\n ? `${details?.peRatio?.toFixed(1)}`\n : details?.peRatio\n } x`\n )}\n \n
\n
\n {details?.chart?.length && (\n
\n \n \n \n \n \n \n \n \n {\n const date = new Date(v);\n return `${date.getMonth() + 1}/${date.getFullYear()}`;\n }}\n />\n \n \n (\n
\n \n {moment(new Date(label)).format(\"DD/MM/YYYY\")}\n \n \n Cotação:{\" \"}\n {formatCurrency(Number(payload?.[0]?.value || 0))}\n \n
\n )}\n />\n \n \n
\n
\n )}\n
\n \n )}\n {loading && (\n
\n \n
\n )}\n \n );\n};\n\nexport const PosicaoCard = ({\n key,\n posicao,\n hideValues,\n setHelpModal,\n details,\n loading,\n cotacaoVenda,\n}: PosicaoCardProps) => (\n \n {posicao\n ? PosicaoBody(\n posicao,\n setHelpModal,\n hideValues,\n details,\n loading,\n cotacaoVenda\n )\n : null}\n \n);\n\nexport const ExpandIcon = ({ isActive }: { isActive?: boolean }) =>\n isActive ? (\n \n ) : (\n \n );\n","import clsx from \"clsx\";\nimport moment from \"moment\";\nimport { BiCheck } from \"react-icons/bi\";\nimport { GrUpdate } from \"react-icons/gr\";\nimport { BsDownload } from \"react-icons/bs\";\nimport { AiOutlineLock } from \"react-icons/ai\";\nimport { Fragment, useEffect, useMemo, useState } from \"react\";\nimport { InfoCircleOutlined, LoadingOutlined } from \"@ant-design/icons\";\nimport {\n Col,\n Collapse,\n Modal,\n Row,\n Typography,\n message,\n Select,\n Tooltip,\n Checkbox,\n} from \"antd\";\nimport {\n PieChart,\n Pie,\n Cell,\n Legend,\n ResponsiveContainer,\n Tooltip as RechartsTooltip,\n} from \"recharts\";\nimport Button from \"../../components/Button\";\nimport { DrawerModal } from \"../DrawerModal\";\nimport apiBolsa from \"../../services/apiBolsa\";\nimport AntButton from \"../../components/Button\";\nimport HandleTag from \"../../services/handleTag\";\nimport apiVeloPro from \"../../services/apiVeloPro\";\nimport { useAuth } from \"../../contexts/AuthContext\";\nimport apiExterior from \"../../services/apiExterior\";\nimport { ReportTypeDrawer } from \"../ReportType/ReportType\";\nimport { Posicao, useCarteira } from \"../../contexts/CarteiraContext\";\nimport { chartColors, getProviderColor } from \"../../utils/walletCharts\";\nimport { BlurContent, Container, Content, IsentCardStyled } from \"./styles\";\nimport { ReactComponent as FiltroIcon } from \"../../assets/icons/filtro.svg\";\nimport { getNomeCorretora, serializePatrimonio } from \"../../utils/patrimonio\";\nimport {\n vendasIsentas,\n vendasTotaisExt,\n} from \"../../pages/HistoricBolsa/utils\";\nimport {\n ExpandIcon,\n HidenValue,\n LucroPrejuizo,\n PosicaoCard,\n} from \"./PosicaoCard\";\nimport {\n download,\n downloadPDF,\n formatCurrency,\n isMobile,\n numberToCurrency,\n} from \"../../utils\";\nimport { useNavigate } from \"react-router-dom\";\n\ntype ChartType = \"classe\" | \"posicoes\" | \"corretora\";\n\ninterface CarteiraProps {\n hideValues: boolean;\n}\n\nconst Months: any = {\n 0: \"Janeiro\",\n 1: \"Fevereiro\",\n 2: \"Março\",\n 3: \"Abril\",\n 4: \"Maio\",\n 5: \"Junho\",\n 6: \"Julho\",\n 7: \"Agosto\",\n 8: \"Setembro\",\n 9: \"Outubro\",\n 10: \"Novembro\",\n 11: \"Dezembro\",\n};\n\nexport const Carteira: React.FC = ({ hideValues }: any) => {\n const {\n user,\n showUserPlanModal,\n hasPlan: hasPremiunPlan,\n hasPermissionExterior,\n hasPermissionGeneral,\n } = useAuth();\n const hasPlan =\n (hasPremiunPlan || hasPermissionExterior || hasPermissionGeneral)\n && !user?.user?.userPlanInfoVelotax?.type.includes('BASIC');\n const { carteira, lastUpdate, loading, getCarteira, getPatrimonios, updateFilter, posicoesFilter, setPosicoesFilter } =\n useCarteira();\n\n const navigate = useNavigate();\n const [helpModal, setHelpModal] = useState();\n const [loadingReport, setLoadingReport] = useState(false);\n const [chartType, setChartType] = useState(\"classe\");\n const [classesAtivosChart, setClassesAtivosChart] = useState();\n const [corretorasAtivosChart, setCorretorasAtivosChart] = useState();\n const [ativosChart, setAtivosChart] = useState();\n const [vendasBolsa, setVendasBolsa] = useState(0);\n const [corretoras, setCorretoras] = useState([]);\n const [corretorasSemFiltro, setCorretorasSemFiltro] = useState([]);\n const [vendasExterior, setVendasExterior] = useState(0);\n const [checkboxCorretoras, setCheckboxCorretoras] = useState([]);\n const [selectedCorretoras, setSelectedCorretoras] = useState([]);\n const [reportDrawerWallet, setReportDrawerWallet] = useState(false);\n const [vendasRestantesBolsa, setVendasRestantesBolsa] = useState(0);\n const [filterCorretoraAtivo, setFilterCorretoraAtivo] = useState(\n []\n );\n const [vendasRestantesExterior, setVendasRestantesExterior] =\n useState(0);\n const [showCorretoraFilterModal, setShowCorretoraFilterModal] =\n useState(false);\n const [showPosicoesFilterModal, setShowPosicoesFilterModal] = useState(false);\n const [activeKeys, setActiveKeys] = useState([]);\n const [, setDetailedActiveKeys] = useState([]);\n const [detailedLoadingIndex, setDetailedLoadingIndex] = useState<\n number | undefined\n >(undefined);\n const [detailedPositions, setDetailedPositions] = useState([]);\n\n const checkAll = corretoras.length === checkboxCorretoras.length;\n const indeterminate =\n checkboxCorretoras.length > 0 &&\n checkboxCorretoras.length < corretoras.length;\n\n const onCloseHelpModal = () => setHelpModal(undefined);\n\n const largeChart =\n [\n ...(chartType === \"classe\"\n ? classesAtivosChart || []\n : chartType === \"corretora\"\n ? corretorasAtivosChart || []\n : ativosChart || []),\n ].length > 7;\n\n const carteiraCategorizada = useMemo(\n () =>\n (carteira?.posicoesSemFiltro || []).reduce(\n (acc, cur) => ({\n ...acc,\n [cur.categoria]: [...(acc[cur.categoria] || []), cur],\n }),\n {} as { [key: string]: Posicao[] }\n ) || {},\n [carteira.posicoesSemFiltro]\n );\n const carteiraCategorizadaFiltered = useMemo(\n () =>\n (carteira?.posicoes || []).reduce(\n (acc, cur) => ({\n ...acc,\n [cur.categoria]: [...(acc[cur.categoria] || []), cur],\n }),\n {} as { [key: string]: Posicao[] }\n ) || {},\n [carteira.posicoes]\n );\n\n const patrimonioTotalFiltrado = useMemo(\n () =>\n carteira?.posicoes?.reduce(\n (acc, cur) =>\n filterCorretoraAtivo.includes(cur.corretora)\n ? acc + cur.posicao\n : acc,\n 0\n ) || 0,\n [carteira?.posicoes, filterCorretoraAtivo]\n );\n\n const retornoFiltrado = useMemo(\n () =>\n carteira?.posicoes?.reduce(\n (acc, cur) =>\n filterCorretoraAtivo.includes(cur.corretora)\n ? {\n lucroPrejuizoDiario:\n acc.lucroPrejuizoDiario + cur.lucroPrejuizoDiario,\n lucroPrejuizoDiarioPercentualNumerator:\n acc.lucroPrejuizoDiarioPercentualNumerator +\n (cur.categoria === \"TesouroDireto\"\n ? 0\n : cur.resumo?.lucroPrejuizoDiarioPercentualNumerator),\n lucroPrejuizoDiarioPercentualDenominator:\n acc.lucroPrejuizoDiarioPercentualDenominator +\n (cur.categoria === \"TesouroDireto\"\n ? 0\n : cur.resumo?.lucroPrejuizoDiarioPercentualDenominator),\n lucroPrejuizoTotal:\n acc.lucroPrejuizoTotal + cur.lucroPrejuizoTotal,\n lucroPrejuizoTotalPercentualNumerator:\n acc.lucroPrejuizoTotalPercentualNumerator +\n cur.resumo?.lucroPrejuizoTotalPercentualNumerator,\n lucroPrejuizoTotalPercentualDenominator:\n acc.lucroPrejuizoTotalPercentualDenominator +\n cur.resumo?.lucroPrejuizoTotalPercentualDenominator,\n }\n : acc,\n {\n lucroPrejuizoDiario: 0,\n lucroPrejuizoDiarioPercentualNumerator: 0,\n lucroPrejuizoDiarioPercentualDenominator: 0,\n lucroPrejuizoTotal: 0,\n lucroPrejuizoTotalPercentualNumerator: 0,\n lucroPrejuizoTotalPercentualDenominator: 0,\n }\n ) || {\n lucroPrejuizoDiario: 0,\n lucroPrejuizoDiarioPercentualNumerator: 0,\n lucroPrejuizoDiarioPercentualDenominator: 0,\n lucroPrejuizoTotal: 0,\n lucroPrejuizoTotalPercentualNumerator: 0,\n lucroPrejuizoTotalPercentualDenominator: 0,\n },\n [carteira?.posicoes, filterCorretoraAtivo]\n );\n\n const onChangeActiveKeys = (keys: string | string[]) => {\n const isOpenEvent = keys.length > activeKeys.length;\n const lastOpened = keys[keys.length - 1];\n\n setActiveKeys(keys as string[]);\n let codigo =\n lastOpened?.replaceAll(\" \", \"\").split(\"-\")[3] ||\n lastOpened?.replaceAll(\" \", \"\").split(\"-\")[2];\n let market =\n lastOpened?.replaceAll(\" \", \"\").split(\"-\")[0] ||\n lastOpened?.replaceAll(\" \", \"\").split(\"-\")[1];\n let index = lastOpened?.replaceAll(\" \", \"\").split(\"-\")[1];\n if (\n lastOpened.includes(\"Imobiliário\") ||\n lastOpened.includes(\"Traded\") ||\n lastOpened.includes(\"Brazilian\")\n ) {\n codigo = lastOpened?.replaceAll(\" \", \"\").replace(\"-\", \"\").split(\"-\")[2];\n index = lastOpened?.replaceAll(\" \", \"\").replace(\"-\", \"\").split(\"-\")[1];\n }\n\n if (lastOpened && isOpenEvent) {\n setDetailedActiveKeys((detailedActiveKeys) => {\n if (\n !detailedActiveKeys.includes(lastOpened) &&\n keys.length > detailedActiveKeys.length\n ) {\n setDetailedLoadingIndex(Number(index));\n apiBolsa\n .get(`/warren/detalied/${codigo}`, {\n params: {\n exterior:\n market.toLowerCase() === \"exterior\" ? true : undefined,\n },\n })\n .then(({ data }: any) => {\n setDetailedPositions((positions) => [\n ...positions,\n {\n index,\n codigo: codigo,\n details: data,\n },\n ]);\n return [...detailedActiveKeys, lastOpened];\n })\n .finally(() => {\n setDetailedLoadingIndex(undefined);\n });\n }\n return detailedActiveKeys;\n });\n }\n };\n\n useEffect(() => {\n getCarteira();\n }, [getCarteira]);\n\n useEffect(() => {\n apiBolsa\n .get(\"/velotax/historic\", {\n params: {\n month: new Date().getMonth() + 1,\n },\n })\n .then((res) => {\n const isentas = vendasIsentas(res?.data);\n setVendasBolsa(isentas);\n setVendasRestantesBolsa(20000 - isentas);\n });\n }, []);\n\n useEffect(() => {\n apiExterior\n .get(\"/velotax/exterior/historic\", {\n params: {\n month: new Date().getMonth() + 1,\n },\n })\n .then((res) => {\n const isentas = vendasTotaisExt(res?.data)\n setVendasExterior(isentas);\n setVendasRestantesExterior(35000 - isentas);\n });\n }, []);\n\n useEffect(() => {\n const { classesAtivos, patrimonio, posicoes, corretoras, corretorasSemFiltro } =\n serializePatrimonio(carteira, selectedCorretoras);\n setClassesAtivosChart(classesAtivos);\n setCorretorasAtivosChart(patrimonio);\n setAtivosChart(posicoes);\n setCorretoras(corretoras);\n setCorretorasSemFiltro(corretorasSemFiltro)\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [loading, selectedCorretoras]);\n\n const downloadAction = async (type: string) => {\n try {\n setLoadingReport(true);\n if (type === \"pdf\") {\n const queryCorretoras =\n filterCorretoraAtivo?.length > 0\n ? `?corretoras=${JSON.stringify(filterCorretoraAtivo).replace(\n /\\]|\"|\\[/g,\n \"\"\n )}`\n : \"\";\n const res = await apiBolsa.get(\n `/warren/wallet/report${queryCorretoras}`\n );\n if (res.data.file && !isMobile()) {\n downloadPDF(res.data.file, \"Meus investimentos\");\n } else if (res.data.fileUrl && !isMobile()) {\n download(res.data.fileUrl);\n }\n message.success(\"O relatório foi enviado para o seu e-mail\");\n } else if (type === \"xlsx\") {\n if (filterCorretoraAtivo?.length > 0) {\n const res = await apiVeloPro.post(\n \"/calc/downloadRelatorioPatrimonioXlsx\",\n {\n username: user.user.cpf,\n corretoras: filterCorretoraAtivo,\n }\n );\n if (!isMobile()) download(res?.data?.fileUrl);\n message.success(\"O relatório foi enviado para o seu e-mail\");\n } else {\n const data = await getPatrimonios(user?.user?.cpf);\n if (!isMobile()) download(data.fileUrl);\n message.success(\"O relatório foi enviado para o seu e-mail\");\n }\n }\n } catch (err: any) {\n message.error(\n `Não foi possível baixar o relatório de investimentos. Tente novamente mais tarde`\n );\n } finally {\n setLoadingReport(false);\n }\n };\n\n const renderLegend = (value: string, entry: any) => {\n return {value};\n };\n\n const renderIsentCard = (categoria: string) => {\n if (categoria === \"Ações\" || categoria === \"Exterior\") {\n const vendas = categoria === \"Ações\" ? vendasBolsa : vendasExterior;\n const restante =\n categoria === \"Ações\" ? vendasRestantesBolsa : vendasRestantesExterior;\n const limit = categoria === \"Ações\" ? 20000 : 35000;\n const tipVendas = vendas\n ? `R$ ${String(\n vendas.toLocaleString(\"pt-br\", {\n minimumFractionDigits: 2,\n maximumFractionDigits: 2,\n })\n )}`\n : \"R$ 0,00\";\n const complete = vendas ? (vendas / limit) * 100 : 0;\n\n return (\n \n {restante <= 0 ? (\n \n O seu limite de vendas isentas foi atingido neste mês\n \n ) : (\n \n Você ainda possui{\" \"}\n \n {formatCurrency(restante)}{\" \"}\n {\" \"}\n em vendas isentas em{\" \"}\n \n {Months[new Date().getMonth()]} {new Date().getFullYear()}\n \n \n )}\n
\n target.parentElement!}\n >\n = 100 ? 100 : complete}%`,\n borderBottomRightRadius: complete >= 100 ? \"50px\" : 0,\n borderTopRightRadius: complete >= 100 ? \"50px\" : 0,\n }}\n >\n
\n {vendas > 5000 ? formatCurrency(vendas) : \"\"}\n
\n
\n \n \n {/* */}\n
\n );\n }\n };\n\n const renderCustomizedLabel = ({\n cx,\n cy,\n midAngle,\n innerRadius,\n outerRadius,\n percent,\n payload,\n }: any) => {\n const RADIAN = Math.PI / 180;\n const radius = innerRadius + (outerRadius - innerRadius) * 0.5;\n const x = cx + radius * Math.cos(-midAngle * RADIAN);\n const y = cy + radius * Math.sin(-midAngle * RADIAN);\n let fill = chartColors.find(\n (colors) => colors.background === payload.fill\n )?.label;\n if (payload.fill === \"#FCC102\") fill = \"#5a4709\";\n\n return (\n \n {percent * 100 > 5 && `${(percent * 100).toFixed(0)}%`}\n \n );\n };\n\n return (\n \n {/* \n Meus investimentos\n {hasPlan && (\n : }\n onClick={() => downloadAction()}\n />\n )}\n : }\n />\n */}\n {/* \n \n */}\n \n
\n }\n className=\"download-report-btn filter-btn\"\n onClick={() => setShowCorretoraFilterModal(true)}\n >\n Filtrar\n \n {hasPlan && target.parentElement!}\n >\n : }\n onClick={() => setReportDrawerWallet(true)}\n />\n }\n
\n \n \n Investimento total:\n \n {loading ? (\n \n ) : !hideValues ? (\n formatCurrency(\n filterCorretoraAtivo.length > 0\n ? patrimonioTotalFiltrado\n : carteira.patrimonioTotal\n )\n ) : (\n \n )}\n \n \n \n \n \n \n Retorno diário:{\" \"}\n {loading ? (\n \n ) : !hideValues ? (\n 0\n ? retornoFiltrado.lucroPrejuizoDiario\n : carteira.lucroPrejuizoDiario\n }\n p={\n filterCorretoraAtivo.length > 0\n ? retornoFiltrado.lucroPrejuizoDiarioPercentualNumerator /\n retornoFiltrado.lucroPrejuizoDiarioPercentualDenominator\n : carteira.lucroPrejuizoDiarioPercentual\n }\n />\n ) : (\n \n )}\n \n \n \n \n Retorno total:{\" \"}\n {loading ? (\n \n ) : !hideValues ? (\n 0\n ? retornoFiltrado.lucroPrejuizoTotal\n : carteira.lucroPrejuizoTotal\n }\n p={\n filterCorretoraAtivo.length > 0\n ? retornoFiltrado.lucroPrejuizoTotalPercentualNumerator /\n retornoFiltrado.lucroPrejuizoTotalPercentualDenominator\n : carteira.lucroPrejuizoTotalPercentual\n }\n />\n ) : (\n \n )}\n \n \n \n \n \n downloadAction(type)}\n onClose={() => setReportDrawerWallet(false)}\n />\n
\n \n {loading ? (\n \n \n \n ) : carteira?.posicoes?.length > 0 ? (\n <>\n {!loading ? (\n \n <>\n \n \n \n {(chartType === \"classe\"\n ? classesAtivosChart\n : chartType === \"posicoes\"\n ? ativosChart\n : corretorasAtivosChart\n )?.map((entry: any, index: number) => (\n \n ))}\n \n {\n return `${numberToCurrency(Number(value))} (${String(\n payload.percentage\n ).replace(\".\", \",\")}%)`;\n }}\n />\n \n
\n setChartType(value)}\n getPopupContainer={(target) => target.parentElement!}\n >\n \n Por classe de ativo\n \n \n Por corretora\n \n Por ativo\n \n
\n \n
\n ) : undefined}\n {!hasPlan ? (\n <>\n ExpandIcon({ isActive })}\n >\n {carteira.posicoes.slice(0, 1).map((posicao, index) => (\n \n {PosicaoCard({\n key: index.toString(),\n posicao,\n hideValues,\n setHelpModal,\n })}\n \n ))}\n \n \n ExpandIcon({ isActive })}\n >\n {Array.from(Array(3).keys()).map((index) => (\n \n {PosicaoCard({\n key: index.toString(),\n hideValues,\n setHelpModal,\n posicao: {\n lucroPrejuizoDiario: 0.01,\n },\n })}\n \n ))}\n \n
\n Contrate o plano premium para ver a lista completa de ativos\n }\n onClick={() => {\n // showUserPlanModal(true);\n navigate('/planos')\n HandleTag(\"54\");\n }}\n >\n PREMIUM\n \n
\n
\n \n ) : (\n ExpandIcon({ isActive })}\n >\n {(filterCorretoraAtivo.length > 0\n ? Object.keys(carteiraCategorizadaFiltered).filter(\n (categoria) =>\n carteiraCategorizadaFiltered[categoria].filter((item: any) =>\n filterCorretoraAtivo.includes(item?.corretora)\n ).length > 0\n )\n : Object.keys(carteiraCategorizadaFiltered)\n ).map((categoria) => (\n \n \n {categoria === \"TesouroDireto\"\n ? \"Tesouro Direto\"\n : categoria}\n \n \n \n \n }\n >\n ExpandIcon({ isActive })}\n onChange={onChangeActiveKeys}\n >\n {categoria !== \"Exterior\" && renderIsentCard(categoria)}\n {(filterCorretoraAtivo.length > 0\n ? carteiraCategorizadaFiltered[categoria].filter((item: any) =>\n filterCorretoraAtivo.includes(item?.corretora)\n )\n : carteiraCategorizadaFiltered[categoria]\n )\n .sort(\n (a, b) =>\n ((b.categoria === \"TesouroDireto\"\n ? b.precoAtual\n : b.posicao) || 0) -\n ((a.categoria === \"TesouroDireto\"\n ? a.precoAtual\n : a.posicao) || 0)\n )\n .map((posicao, index) => (\n \n {PosicaoCard({\n key: `${categoria}-${index}-${posicao.codigo}`,\n posicao,\n hideValues,\n setHelpModal,\n cotacaoVenda:\n categoria === \"Exterior\" &&\n carteira.cotacaoVenda > 0\n ? carteira.cotacaoVenda\n : undefined,\n details: detailedPositions?.find(\n (el: any) =>\n el.codigo === posicao.codigo &&\n Number(el.index) === index\n )?.details,\n loading: detailedLoadingIndex === index,\n })}\n \n ))}\n \n \n ))}\n \n )}\n \n ) : (\n \n Nenhuma posição encontrada\n \n )}\n\n \n : }\n onClick={() => getCarteira(true)}\n className=\"button-refresh-wallet\"\n />\n Atualizado em{\" \"}\n {moment(lastUpdate).utc().local().format(\"DD/MM/YYYY à[s] HH:mm\")}\n \n\n {hasPlan && carteira.posicoes?.length > 0 && (\n
    \n
  • \n \n As posições são atualizadas em até quatro dias úteis após sua\n negociação (D+4)\n
  • \n
  • \n \n Bonds e/ou operações fora da bolsa de valores não são apresentadas\n na listagem acima.\n
  • \n {/*
  • \n \n Os preços dos ativos custodiados no exterior são convertidos para\n reais pela cotação do dólar de compra fixada pelo Banco Central do\n Brasil (PTAX) na data do último fechamento.\n
  • \n
  • \n O custo médio de compra de ativos no\n exterior é apresentado para fins ilustrativos de acompanhamento de\n carteira apenas. Para cálculo de imposto de renda, utilizar\n valores de aquisição considerando a origem dos recursos para\n cálculo de ganho de capital.\n
  • */}\n
\n )}\n
\n \n {helpModal?.content}\n \n {\n setShowCorretoraFilterModal(false);\n }}\n bodyStyle={{paddingTop: '1rem'}}\n footer={\n }\n onClick={() => {\n setShowCorretoraFilterModal(false);\n setSelectedCorretoras(checkboxCorretoras);\n setFilterCorretoraAtivo(\n checkboxCorretoras.map((corretora: string) =>\n getNomeCorretora({ shortName: corretora })\n )\n );\n updateFilter(posicoesFilter || [])\n }}\n >\n Confirmar\n \n }\n >\n \n \n \n \n Corretoras\n \n \n {\n setPosicoesFilter([])\n setCheckboxCorretoras(e.target.checked ? corretorasSemFiltro : []);\n }}\n >\n Todas as corretoras\n \n {\n setPosicoesFilter([])\n setCheckboxCorretoras(e);\n }}\n >\n \n {corretorasSemFiltro.map((corretora, i) => (\n \n {corretora}\n \n ))}\n \n \n \n \n \n \n
\n
\n Filtrar por posições\n
\n
\n {\n setCheckboxCorretoras([])\n setPosicoesFilter(e)\n }}\n options={Object.keys(carteiraCategorizada).map((categoria) => ({\n label: categoria,\n options: carteiraCategorizada[categoria].map((c: any) => ({\n label: c.codigo,\n value: c.codigo,\n }))\n }))}\n />\n \n
\n );\n};\n","import styled from \"styled-components\";\n\nexport const NotificationContainer = styled.div`\n h3 {\n border-bottom: 2px solid var(--gray-2);\n padding-bottom: 0.5rem;\n color: var(--velotax-font-color-light);\n }\n\n .divider {\n width: 100%;\n max-width: 80px;\n background-color: var(--ant-primary-color);\n height: 2px;\n margin-bottom: 1rem;\n }\n\n .illustration {\n display: flex;\n justify-content: center;\n align-items: center;\n flex-direction: column;\n position: relative;\n margin-top: 4rem;\n\n span {\n margin-right: 1rem;\n color: var(--gray-2);\n }\n\n h5 {\n font-weight: 500;\n color: var(--velotax-font-color-light);\n }\n\n button, span {\n display: flex;\n justify-content: center;\n align-items: center;\n color: black !important;\n }\n span {\n margin: 0 0 0 0.5rem;\n }\n button {\n max-width: 160px;\n height: 52px;\n margin-right: auto;\n margin-top: 1rem;\n }\n }\n\n .loading {\n display: flex; \n \n h5 {\n margin-left: 1rem;\n }\n }\n\n .card {\n background-color: var(--ant-primary-1);\n box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.15);\n border-radius: 6px;\n margin-bottom: 1rem;\n padding: 1rem;\n position: relative;\n cursor: pointer;\n\n &:hover {\n transition: 0.3s;\n background-color: var(--ant-primary-2);\n }\n\n .loading {\n width: 100%;\n height: 100%;\n position: absolute;\n top: 0;\n left: 0;\n background-color: rgba(0, 0, 0, 0.2);\n display: flex;\n justify-content: center;\n align-items: center;\n }\n\n .header {\n display: flex;\n align-items: center;\n width: 100%;\n margin-bottom: 8px;\n\n h5 {\n flex-grow: 1;\n margin-bottom: 0;\n }\n\n svg {\n color: var(--ant-primary-color);\n font-size: 20px;\n margin-right: 4px;\n }\n\n span {\n color: var(--velotax-font-color-ghost);\n }\n\n .actionButton {\n color: var(--gray-2);\n margin: 0;\n transition: 0.3s;\n cursor: pointer;\n\n &:hover {\n color: var(--ant-primary-color);\n transition: 0.3s;\n }\n }\n }\n\n .body {\n span {\n margin: 0;\n color: var(--black);\n font-weight: 400;\n }\n }\n }\n\n .viewed {\n background-color: var(--velotax-ghost);\n cursor: default;\n h5,\n svg,\n span {\n color: var(--velotax-font-color-ghost) !important;\n }\n &:hover {\n background-color: var(--velotax-ghost);\n }\n }\n\n .section {\n display: flex;\n justify-content: space-between;\n align-items: center;\n margin-top: 2rem;\n\n h5 {\n text-transform: uppercase;\n font-size: 14px;\n color: var(--velotax-font-color-light);\n }\n\n button {\n color: var(--gray-2);\n transition: 0.3s;\n text-transform: uppercase;\n font-size: 13px;\n font-weight: 500;\n &:hover {\n color: var(--ant-primary-color);\n transition: 0.3s;\n }\n }\n }\n`;\n","export default __webpack_public_path__ + \"static/media/notification.d3262cf7.svg\";","import { useState } from \"react\";\nimport { Drawer, Typography, message } from \"antd\";\nimport { LoadingOutlined } from \"@ant-design/icons\";\nimport { AiOutlineArrowLeft } from \"react-icons/ai\";\nimport { HiOutlineCurrencyDollar } from \"react-icons/hi\";\nimport api from \"../../services/apiBolsa\";\nimport { NotificationContainer } from \"./styles\";\nimport { isMobile } from \"../../utils\";\nimport notificationImage from \"../../assets/notification.svg\";\nimport { useNotification } from \"../../contexts/NotificationContext\";\n\ninterface IProps {\n open: boolean;\n onClose:\n | ((\n e: React.MouseEvent | React.KeyboardEvent\n ) => void)\n | undefined;\n}\n\nexport const NotificationDrawer = ({ open, onClose }: IProps) => {\n const { notification, setNotification, loading } = useNotification();\n const [loadingIndex, setLoadingIndex] = useState(2);\n const lidas = (notification || []).filter((n) => n.viewed);\n const naoLidas = (notification || []).filter((n) => !n.viewed);\n\n const removeNotification = (index?: number) => {\n const notifications = notification.map((n, i: number) => {\n if (index === undefined || index === i)\n return { ...n, viewed: true, viewedDate: new Date() };\n return n;\n });\n\n setLoadingIndex(index === undefined ? \"all\" : index);\n api\n .patch(`/warren/notification`, {\n notifications,\n })\n .then(() => {\n setNotification(notifications);\n setLoadingIndex(null);\n })\n .catch(() => {\n message.error(\"Não foi possível remover notificação\");\n });\n };\n\n return (\n }\n title={\n
\n Voltar\n
\n }\n {...(isMobile() ? { width: \"100%\" } : {})}\n >\n \n
\n Notificações\n
\n
\n\n {(loading || !notification?.length) && (\n
\n \"Notificações\"\n {loading ? (\n
\n \n \n Buscando notificações\n \n
\n ) : !notification?.length ? (\n \n Você não possui novas notificações.\n \n ) : (\n <>\n )}\n
\n )}\n\n {}\n {!!naoLidas?.length && !loading && (\n
\n Não lidas\n \n
\n )}\n {!loading &&\n (notification || [])?.map((item, i) => {\n if (item.viewed) return <>;\n return (\n
\n {\n if (!(loadingIndex === i || loadingIndex === \"all\"))\n removeNotification(i);\n }}\n >\n {(loadingIndex === i || loadingIndex === \"all\") && (\n
\n \n
\n )}\n
\n \n \n Rendimentos a receber\n \n {item?.date && (\n \n {new Date(item?.date)?.toLocaleDateString(\"pt-BR\", {\n year: \"numeric\",\n month: \"2-digit\",\n day: \"2-digit\",\n })}\n \n )}\n
\n
\n {item.message}\n
\n
\n
\n );\n })}\n\n {/* Notificações Lidas */}\n {!!lidas?.length && !loading && (\n
\n Lidas\n
\n )}\n {!loading &&\n (notification || [])?.map((item, i) => {\n if (!item.viewed) return <>;\n return (\n
\n
\n
\n \n \n Rendimentos a receber\n \n {item?.date && (\n \n {new Date(item?.date)?.toLocaleDateString(\"pt-BR\", {\n year: \"numeric\",\n month: \"2-digit\",\n day: \"2-digit\",\n })}\n \n )}\n
\n
\n {item.message}\n
\n
\n
\n );\n })}\n
\n \n );\n};\n","import styled from \"styled-components\";\n\nexport const AvisosContainer = styled.div`\n display: flex;\n justify-content: center;\n align-items: center;\n\n .client-integration-card {\n padding: 24px;\n border-radius: 8px;\n background-color: var(--ant-primary-1);\n border: 1px solid var(--ant-primary-color);\n display: flex;\n align-items: start;\n margin-bottom: 1rem;\n &:last-of-type {\n /* margin-bottom: 48px; */\n }\n & > svg {\n min-width: 32px;\n min-height: 32px;\n color: var(--ant-primary-color);\n stroke: var(--ant-primary-color);\n &.fill {\n fill: var(--ant-primary-color);\n }\n }\n\n .client-integration-card-content {\n width: 100%;\n margin-left: 16px;\n h3 {\n color: #000;\n font-size: 16px;\n font-weight: 600;\n line-height: 24px;\n margin-bottom: 8px;\n }\n div.ant-typography {\n color: #000;\n font-size: 14px;\n font-weight: 300;\n line-height: 20px;\n width: calc(100% - 48px);\n }\n .ant-btn {\n padding: 0;\n border: none;\n height: 40px;\n font-size: 14px;\n font-weight: 500;\n margin: -12px 0;\n }\n button {\n display: flex;\n align-items: center;\n\n svg {\n margin-left: 4px;\n }\n }\n }\n }\n\n div:first-of-type {\n width: 100%;\n }\n\n .title {\n h3 {\n font-weight: 600;\n }\n }\n .divider {\n width: 100%;\n background-color: var(--ant-primary-color);\n height: 2px;\n margin-bottom: 2rem;\n }\n\n .plan-boxes {\n flex-wrap: nowrap;\n margin-top: 1rem !important;\n margin-bottom: 1rem !important;\n }\n\n .ant-divider {\n margin: 8px 0;\n }\n\n .ant-btn {\n height: 56px;\n\n span {\n font-weight: 500;\n svg {\n display: none;\n }\n }\n }\n .total-contratado {\n display: none;\n }\n .dismiss {\n cursor: pointer;\n transition: 0.3s;\n &:hover {\n color: var(--ant-primary-7);\n transition: 0.3s;\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n .ant-card-body {\n padding: 16px;\n }\n }\n`;\n","import { Drawer, DrawerProps, Modal, ModalProps } from \"antd\";\nimport { isMobile } from \"../../../utils\";\n\nexport interface DrawerModalProps\n extends Omit,\n Omit {\n visible?: boolean;\n onCancel?: (e: any) => void;\n}\n\nexport const DrawerModal: React.FC = ({\n height,\n visible,\n onCancel,\n children,\n className,\n getContainer,\n ...props\n}) => {\n return isMobile() ? (\n \n {children}\n \n ) : (\n \n {children}\n \n );\n};\n","import styled from \"styled-components\";\n\nexport const B3Link = styled.a`\n margin: auto;\n font-size: 10px;\n text-align: center;\n white-space: normal;\n display: inline-block;\n word-break: break-all;\n color: rgb(1, 103, 153);\n\n &:hover {\n text-decoration: underline;\n color: rgb(1, 103, 153);\n }\n`;\n\nexport const CopyLink = styled.button`\n color: #0566cd;\n font-weight: 500;\n text-decoration: underline;\n\n &:hover {\n text-decoration: underline;\n color: #06417f;\n }\n`;\n\nexport const ShareItem = styled.div`\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n margin-right: 1rem;\n cursor: pointer;\n\n &:hover {\n text-decoration: underline;\n color: #06417f;\n }\n\n img {\n width: 40px;\n height: 40px;\n }\n\n p {\n font-size: 11px;\n margin: 0.5rem 0;\n }\n`;\n\nexport const Instructions = styled.p`\n font-size: 13px;\n margin-bottom: 4px;\n`;\n","export default __webpack_public_path__ + \"static/media/Integracao_XP_B3.635b7422.gif\";","export default __webpack_public_path__ + \"static/media/integracao_warren_exterior.abe871c7.gif\";","import { Typography, Image, message } from \"antd\";\nimport { DrawerModal } from \"../DrawerModal\";\nimport { B3Link, CopyLink, Instructions } from \"./styles\";\nimport b3IntegrationExample from \"../../../assets/Integracao_XP_B3.gif\";\nimport warrenIntegrationExample from \"../../../assets/integracao_warren_exterior.gif\";\n\nexport type TIntegrationModal = \"B3\" | \"Warren Internacional\" | null;\ninterface IProps {\n integrationModal: TIntegrationModal;\n setIntegrationModal: React.Dispatch>;\n}\n\nconst b3Link =\n \"https://b3investidor.b2clogin.com/b3Investidor.onmicrosoft.com/oauth2/v2.0/authorize?p=B2C_1A_FINTECH&client_id=069ecfdf-7471-48eb-be82-d50799c99e5c&nonce=defaultNonce&redirect_uri=https%3A%2F%2Fwww.investidor.b3.com.br&scope=openid&response_type=code&prompt=login\";\n// const b3Encoded =\n// \"https%3A%2F%2Fb3investidor.b2clogin.com%2Fb3Investidor.onmicrosoft.com%2Foauth2%2Fv2.0%2Fauthorize%3Fp%3DB2C_1A_FINTECH%26client_id%3D069ecfdf-7471-48eb-be82-d50799c99e5c%26nonce%3DdefaultNonce%26redirect_uri%3Dhttps%253A%252F%252Fwww.investidor.b3.com.br%26scope%3Dopenid%26response_type%3Dcode%26prompt%3Dlogin\";\n\nexport const IntegrationModal = ({\n integrationModal,\n setIntegrationModal,\n}: IProps) => {\n return (\n {\n setIntegrationModal(null);\n }}\n >\n {integrationModal === \"B3\" ? (\n \n Permita a conexão entre Velotax e B3 para leitura das operações\n realizadas na bolsa de valores.\n \n ) : (\n \n Permita a conexão entre Velotax e Warren Internacional para leitura das\n operações realizadas.\n \n )}\n \n \n \n\n {integrationModal === \"B3\" ? (\n <>\n \n {b3Link}\n \n\n \n {\n navigator.clipboard.writeText(b3Link);\n message.success(\"Link copiado\");\n }}\n >\n Copiar link\n \n \n \n ) : (\n <>\n \n Instruções\n \n
\n \n Passo 1. Acesse a aba de{\" \"}\n Investimento Global dentro do aplicativo da Warren\n \n \n Passo 2. Deslize a tela para baixo e clique em{\" \"}\n Imposto de Renda e DARF\n \n \n Passo 3. Clique em{\" \"}\n Calcular Imposto de Renda e aceite os termos\n \n
\n \n )}\n \n );\n};\n","// Config\n// Components\nimport moment from \"moment\";\nimport { AvisosContainer } from \"./styles\";\nimport { useEffect, useState } from \"react\";\nimport { Button, Spin, Typography, message } from \"antd\";\nimport { FiArrowRight } from \"react-icons/fi\";\nimport { AiOutlineLink } from \"react-icons/ai\";\nimport { BiX } from \"react-icons/bi\";\nimport api from \"../../../services/api\";\nimport { useAuth } from \"../../../contexts/AuthContext\";\nimport { IntegrationModal } from \"../IntegrationModal\";\n// Assets\n\n// Types\ninterface IProps {\n}\nexport type TIntegrationModal = \"B3\" | \"Warren Internacional\" | null;\n\nexport const Avisos = ({\n}: IProps) => {\n const { user } = useAuth();\n const [dismissBolsa, setDismissBolsa] = useState(false);\n const [dismissExterior, setDismissExterior] = useState(false);\n const [loading, setLoading] = useState(false);\n const [integrationModal, setIntegrationModal] = useState<\"B3\" | \"Warren Internacional\" | null>(null); \n const getCloseBanner = async () => {\n try {\n setLoading(true);\n const { data } = await api.post(\"user/xp/close-banner\", { cpf: user?.user?.cpf })\n setDismissBolsa(data.closeBannerBolsaXp)\n setDismissExterior(data.closeBannerExteriorXp)\n } catch (error) {\n message.error(\"Algo deu errado, tente mais tarde!\");\n } finally {\n setLoading(false);\n }\n }\n\n const handleDismissBolsa = async () => {\n try {\n setLoading(true);\n setDismissBolsa(true);\n const { data } = await api.put(\"user/xp/close-banner\", { cpf: user?.user?.cpf, closeBannerBolsaXp: true })\n setDismissBolsa(data.closeBannerBolsaXp)\n } catch (error) {\n message.error(\"Algo deu errado, tente mais tarde!\");\n } finally {\n setLoading(false);\n }\n }\n\n const handleDismissExterior = async () => {\n try {\n setLoading(true);\n setDismissExterior(true);\n const { data } = await api.put(\"user/xp/close-banner\", { cpf: user?.user?.cpf, closeBannerExteriorXp: true })\n setDismissExterior(data.closeBannerExteriorXp)\n } catch (error) {\n message.error(\"Algo deu errado, tente mais tarde!\");\n } finally {\n setLoading(false);\n }\n }\n\n useEffect(() => {\n getCloseBanner()\n }, []);\n \n return (\n \n
\n \n { user.user.isIntegratedBolsa || !dismissBolsa && (\n
\n \n
\n \n Integração com bolsa pendente\n \n \n Conceda a permissão na B3 para que seja\n possível acessar suas operações da bolsa de valores de forma\n automática.\n \n { setIntegrationModal(\"B3\") }}\n >\n Saiba mais\n \n \n
\n { handleDismissBolsa() }}\n />\n
\n )}\n { user.user.isIntegratedExterior || !dismissExterior && (\n
\n \n
\n \n Conecte com a Warren Internacional\n \n \n Conceda a permissão na Warren Internacional\n para que seja possível acessar suas operações no exterior de\n forma automática.\n \n {\n console.log('caiu aqui');\n setIntegrationModal(\"Warren Internacional\");\n }}\n >\n Saiba mais\n \n \n
\n { handleDismissExterior() }}\n />\n
\n )}\n
\n
\n \n
\n );\n};\n","import { useState } from \"react\";\nimport { BiBell } from \"react-icons/bi\";\nimport { Badge, Tabs, Typography } from \"antd\";\nimport { BsEye, BsEyeSlash } from \"react-icons/bs\";\nimport { Container, Content } from \"./styles\";\nimport AntButton from \"../../components/Button\";\nimport { useAuth } from \"../../contexts/AuthContext\";\nimport { Proventos } from \"../../components/Proventos\";\nimport { Carteira } from \"../../components/MeusInvestimentos/index\";\nimport { useNotification } from \"../../contexts/NotificationContext\";\nimport { NotificationDrawer } from \"../../components/Notification/Notification\";\nimport { Avisos } from \"../../components/MeusInvestimentos/Avisos\";\nimport { useBroker } from \"../../contexts/BrokerContext\";\nimport { useCarteira } from \"../../contexts/CarteiraContext\";\n\ninterface CarteiraProps { }\n\nexport const Wallet: React.FC = () => {\n const { notification } = useNotification();\n const { integration } = useBroker();\n const {\n user,\n hasPlan: hasPremiunPlan,\n hasPermissionExterior,\n hasPermissionGeneral,\n } = useAuth();\n const hasPlan =\n (hasPremiunPlan || hasPermissionExterior || hasPermissionGeneral) && !user?.user?.userPlanInfoVelotax?.type.includes('BASIC');\n\n const { carteira } = useCarteira();\n\n const [notificationDrawerOpen, setNotificationDrawerOpen] = useState(false);\n const [hideValues, setHideValues] = useState(false);\n\n return (\n \n
\n \n Meus investimentos\n : }\n onClick={() => setHideValues((value) => !value)}\n />\n \n {hasPlan && (\n
\n !n.viewed)?.length || 0}\n >\n }\n onClick={() => {\n setNotificationDrawerOpen(true);\n }}\n />\n \n
\n )}\n
\n \n {carteira.erroB3\n ? No momento nossa integração com os sistemas da B3 está instável.
Tente novamente mais tarde.
\n : <>\n \n {(!integration.integrated && !user.user.isIntegratedExterior) ? (<>) : (\n \n \n \n \n \n \n \n \n )}\n \n }\n
\n setNotificationDrawerOpen(false)}\n />\n
\n );\n};\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n .page-title.conta {\n display: flex;\n align-items: baseline;\n justify-content: space-between;\n button {\n display: flex;\n align-items: center;\n height: 48px;\n padding: 0 24px;\n background-color: var(--velotax-background-color);\n svg {\n fill: var(--ant-primary-color);\n }\n }\n }\n p {\n width: 700px;\n margin: 0 auto 0.3rem;\n font-size: 1rem;\n line-height: 1.5rem;\n color: var(--velotax-font-color-light);\n\n span {\n cursor: pointer;\n font-weight: 500;\n color: var(--ant-primary-color);\n }\n }\n\n h4 {\n color: var(--velotax-font-color-light);\n }\n\n .ant-descriptions:last-of-type {\n .ant-descriptions-item {\n padding-bottom: 0;\n }\n }\n\n .ant-descriptions {\n h4,\n .ant-descriptions-item-content {\n color: var(--velotax-font-color-dark);\n }\n .ant-descriptions-header {\n margin-bottom: 0px;\n }\n }\n\n .excluir-conta-container {\n width: 700px;\n margin: 16px auto 0 auto;\n }\n\n .parametrizar-custos-container {\n width: 700px;\n margin: 0px auto;\n button { \n color: var(--ant-primary-color);\n background-color: var(--velotax-background-color);\n padding: 0.5rem 1rem;\n transition: .3s;\n \n &:hover{\n color: var(--ant-primary-color-hover);\n transition: .3s;\n }\n\n svg {\n margin-right: 0.5rem;\n transform: translateY(-1px);\n }\n }\n }\n\n .cancelar-plano-container {\n width: 700px;\n margin: -32px auto 32px;\n }\n\n .content-button {\n display: flex;\n margin: 16px auto 0;\n align-items: center;\n justify-content: right;\n }\n\n .velotax-content.conta {\n background-color: var(--white);\n }\n\n @media only screen and (max-device-width: 812px) {\n .page-title.conta {\n margin-bottom: 80px;\n button {\n left: 0;\n width: 100%;\n bottom: -64px;\n position: absolute;\n }\n }\n p {\n margin: 0 24px 24px;\n width: calc(100% - 48px);\n }\n .excluir-conta-container {\n width: 100%;\n padding: 0 8px;\n }\n .cancelar-plano-container {\n width: 100%;\n padding: 0 8px;\n margin: -12px auto 24px;\n }\n }\n`;\n","import { Button } from \"@mui/material\";\nimport { LoadingOutlined } from \"@ant-design/icons\";\nimport { useEffect, useState, useMemo } from \"react\";\nimport { AiFillWarning, AiOutlineUnlock } from \"react-icons/ai\";\nimport {\n Col,\n Descriptions,\n Form,\n Input,\n message,\n Modal,\n Row,\n Typography,\n} from \"antd\";\nimport { formatDate } from \"../../../utils\";\nimport HandleTag from \"../../../services/handleTag\";\nimport { UserPlans } from \"../../../constants/plans\";\nimport { useAuth } from \"../../../contexts/AuthContext\";\nimport { apiPayment } from \"../../../services/apiPayment\";\nimport { PaymentModal } from \"../../../components/PaymentModal\";\nimport apiVeloPro from \"../../../services/apiVeloPro\";\nimport { useNavigate } from \"react-router-dom\";\n\nconst KEY_PASS = \"DELETAR\";\n\nexport const MeuPlano: React.FC = () => {\n const navigate = useNavigate();\n const { user, getUserInfo, showUserPlanModal } = useAuth();\n const [data, setData] = useState();\n const [loading, setLoading] = useState(false);\n const [cancelModal, showCancelModal] = useState(false);\n const pendingCancel =\n data?.signature?.useDate > 0 &&\n (!data?.signature?.status || data?.signature?.status === \"canceled\");\n\n const [changeCardModal, showChangeCardModal] = useState(false);\n\n const [formKey] = Form.useForm();\n const [keyPass, setKeyPass] = useState(\"\");\n\n const planBasicInfo = user?.user?.userPlanInfoVelotax;\n const [isVelopro, setVelopro] = useState(false);\n const [hasCreditCardInfo, setCreditCardInfo] = useState(true);\n\n const checkPlanVelopro = () => {\n apiVeloPro\n .get('/calc/hasPlanActive/')\n .then(({ data }) => {\n if (data?.isPlanVelopro) setVelopro(true);\n else setVelopro(false);\n })\n .catch(() =>\n message.error(\"Ocorreu um erro, tente novamente mais tarde.\")\n );\n return;\n };\n\n useEffect(() => {\n checkPlanVelopro();\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [isVelopro]);\n\n const currentPlan = useMemo(() => {\n const plansTypes: Record = {\n VELOTAX_MAIN_BASIC: \"Velotax Basic Anual\",\n VELOTAX_MAIN_BASIC_MONTH: \"Velotax Basic Mensal\",\n VELOTAX_MAIN_PRO: \"Velotax Premium Anual\",\n VELOTAX_MAIN_PRO_MONTH: \"Velotax Premium Mensal\",\n VELOTAX_MAIN_CONCIERGE: \"Velotax Concierge Anual\",\n VELOTAX_MAIN_CONCIERGE_MONTH: \"Velotax Concierge Mensal\",\n WARREN_BASIC: \"WARREN Basic Anual\",\n WARREN_BASIC_MONTH: \"WARREN Basic Mensal\",\n WARREN_PRO: \"WARREN Premium Anual\",\n WARREN_PRO_MONTH: \"WARREN Premium Mensal\",\n WARREN_CONCIERGE: \"WARREN Concierge Anual\",\n WARREN_CONCIERGE_MONTH: \"WARREN Concierge Mensal\",\n };\n if (\n planBasicInfo.type === \"VELOTAX_MAIN_PRO\" ||\n planBasicInfo.type === \"VELOTAX_MAIN_BASIC\" ||\n planBasicInfo.type === \"VELOTAX_MAIN_PRO_MONTH\"\n ) {\n setCreditCardInfo(false);\n }\n return (\n (planBasicInfo?.active && plansTypes[planBasicInfo.type]) || \"Gratuito\"\n );\n }, [planBasicInfo]);\n\n const showChangeCardButton = useMemo(\n () =>\n currentPlan !== \"Gratuito\" &&\n !pendingCancel &&\n data?.signature?.paymentForm !== \"pix\" &&\n !data?.signature?.fromAccountant,\n [\n currentPlan,\n pendingCancel,\n data?.signature?.fromAccountant,\n data?.signature?.paymentForm,\n ]\n );\n\n const getData = () => {\n setLoading(true);\n apiPayment\n .get(\"/user-plan/get-plan-details\")\n .then((ret) => {\n setLoading(false);\n setData(ret.data);\n })\n .catch(() => {\n message.error(\n \"Houve um erro ao buscar os detalhes contate nosso suporte\"\n );\n });\n };\n\n const cancelPlan = () => {\n HandleTag(\"60\");\n if (keyPass.toLowerCase() !== KEY_PASS.toLowerCase()) {\n message.error(`Digite ${KEY_PASS} corretamente!`);\n return;\n }\n\n if (isVelopro) {\n apiVeloPro\n .put(`/calc/cancelRecuring/${user.user.userId}`)\n .then(() => {\n message.success(\"Plano cancelado\");\n showCancelModal(false);\n getUserInfo();\n getData();\n })\n .catch(() =>\n message.error(\n \"Ocorreu um erro ao cancelar a recorrência, tente novamente mais tarde.\"\n )\n );\n return;\n }\n\n apiPayment\n .post(\"/user-plan/cancel_signature\")\n .then((ret) => {\n message.success(\"Plano cancelado\");\n showCancelModal(false);\n getUserInfo();\n getData();\n })\n .catch(() => {\n message.error(\"Ocorreu um erro. Contate nosso suporte\");\n });\n };\n\n useEffect(() => {\n getData();\n }, []);\n\n const payForm: Record = {\n pix: \"Pix\",\n credit_card: \"Cartão de Crédito\",\n };\n\n const planStatus = useMemo(\n () =>\n currentPlan === \"Gratuito\"\n ? \"Ativo\"\n : planBasicInfo?.active\n ? \"Ativo\"\n : \"Inativo\",\n [planBasicInfo?.active, currentPlan]\n );\n\n const isActive = useMemo(() => planStatus === \"Ativo\", [planStatus]);\n\n const onDeleteCancel = () => {\n showCancelModal(false);\n formKey.resetFields();\n setKeyPass(\"\");\n };\n\n const contentStyle = {\n fontSize: 15,\n marginBottom: 0,\n };\n\n return (\n <>\n

Dados do plano

\n {loading ? (\n
\n {\" \"}\n
\n ) : (\n <>\n
\n {\"Plano Atual\"}}\n >\n {currentPlan}\n \n Status do Plano}\n >\n \n \n {planStatus}\n
\n {/* {pendingCancel && (\n \n \n \n )} */}\n \n \n {data?.signature?.next_billing_at &&\n planBasicInfo?.active &&\n !pendingCancel && (\n {\"Próxima Cobrança\"}}\n >\n \n {formatDate(data?.signature?.next_billing_at)}\n \n \n )}\n {data?.signature?.start_at && planBasicInfo?.active && (\n {\"Data da Assinatura\"}}\n >\n {data?.signature?.start_at && (\n \n {formatDate(data?.signature?.start_at)}\n \n )}\n \n )}\n {data?.signature?.dueDate && planBasicInfo?.active && (\n {\"Vencimento da Assinatura\"}}\n >\n {data?.signature?.dueDate && (\n \n {formatDate(data?.signature?.dueDate)}\n \n )}\n \n )}\n {data?.signature?.paymentForm &&\n planBasicInfo?.active &&\n hasCreditCardInfo && (\n Forma de pagamento}\n >\n {data?.signature?.paymentForm && (\n \n {<>{payForm[data?.signature?.paymentForm]}}\n \n )}\n \n )}\n\n {data?.signature?.paymentForm !== \"pix\" &&\n planBasicInfo?.active &&\n hasCreditCardInfo &&\n data?.signature?.card?.lastFourDigits && (\n {\"Cartão de cobrança\"}}\n >\n \n {\n <>\n **** **** **** {data?.signature?.card?.lastFourDigits}\n \n }\n \n \n )}\n\n {/* {currentPlan === \"Gratuito\" && (\n
\n {\n showUserPlanModal(true);\n }}\n size=\"medium\"\n color=\"secondary\"\n variant=\"contained\"\n style={{\n display: \"flex\",\n justifyContent: \"right\",\n fontSize: 12,\n }}\n >\n CONTRATAR PLANO\n \n
\n )} */}\n\n {currentPlan === \"Gratuito\" && (\n
\n }\n onClick={() => {\n // showUserPlanModal(true);\n navigate('/planos')\n }}\n >\n CONTRATAR PLANO PREMIUM\n \n
\n )}\n\n {showChangeCardButton && (\n \n \n {\n showChangeCardModal(true);\n }}\n >\n Alterar cartão de cobrança\n \n \n \n )}\n \n {((currentPlan !== \"Gratuito\" &&\n !pendingCancel &&\n data?.signature?.paymentForm !== \"pix\") ||\n isVelopro) && (\n \n \n {\n HandleTag(\"59\");\n showCancelModal(true);\n }}\n style={{\n opacity: 0.8,\n color: \"var(--ant-error-color)\",\n }}\n >\n Cancelar Recorrência\n \n \n \n )}\n \n )}\n\n {changeCardModal && (\n {\n showChangeCardModal(false);\n getData();\n }}\n changeCardAction\n onSuccessGeneral={() => {\n showChangeCardModal(false);\n getData();\n }}\n planCurrent={UserPlans.find(\n (plan) => plan?.type === user?.user?.userPlanInfoVelotax?.type\n )}\n hidePixButton\n blockListCard={[data?.signature?.card?.id]}\n show={changeCardModal}\n onCancel={() => showChangeCardModal(false)}\n paymentData={{\n type: planBasicInfo.type,\n isPlan: true,\n }}\n callDarf={(value: boolean) => null}\n customInstallments={12}\n />\n )}\n\n \n

Deseja realmente cancelar o plano ?

\n \n \n \n \n \n \n Deseja realmente cancelar seu plano?\n \n \n Atenção: todos os seus dados de impostos,\n inclusive a memória dos cálculos e o histórico dos DARFs pagos,\n serão excluídos definitivamente da plataforma. Você poderá ser\n obrigado pela Receita Federal a apresentar tais informações, caso\n seja questionado.\n \n \n \n \n Digite {KEY_PASS} para prosseguir:\n \n \n \n {\n setKeyPass(event.target.value);\n }}\n >\n \n \n \n \n \n \n \n \n );\n};\n","import ReactInputMask from \"react-input-mask\";\nimport { FaUserShield } from \"react-icons/fa\";\nimport { useNavigate } from \"react-router-dom\";\nimport { AiFillWarning } from \"react-icons/ai\";\nimport { Button, TextField } from \"@mui/material\";\nimport React, { useCallback, useEffect, useState } from \"react\";\nimport { CheckOutlined, LoadingOutlined } from \"@ant-design/icons\";\nimport { Col, Form, message, Row, Modal, Input, Typography, Select } from \"antd\";\nimport api from \"../../services/api\";\nimport apiBolsa from '../../services/apiBolsa'\nimport { Container } from \"./styles\";\nimport { MeuPlano } from \"./MeuPlano\";\nimport { cpfInputMask } from \"../../utils\";\nimport { useAuth } from \"../../contexts/AuthContext\";\nimport {\n validationCpf,\n validationDateNotRequired,\n validationEmail,\n validationFieldRequired,\n validationFullName,\n validationPassword,\n validationPhone,\n} from \"../../utils/formValidations\";\nimport { BsFillGearFill, BsInfoCircleFill } from \"react-icons/bs\";\nimport { useB3Integration } from \"../../contexts/B3IntegrationContext\";\n\nconst KEY_PASS = \"DELETAR\";\n\nconst MaskCPF = React.forwardRef((props, ref) => (\n \n));\n\nconst MaskBirth = React.forwardRef((props, ref) => (\n \n));\n\nconst MaskPhone = React.forwardRef((props, ref) => (\n \n));\n\nexport const MinhaConta: React.FC = () => {\n const { user, setUser, signOut } = useAuth();\n const {\n handleIntegrate,\n loadingIntegration,\n } = useB3Integration();\n const [form] = Form.useForm();\n const [warningDeleteModal, showWarningDeleteModal] = useState(false);\n const navigate = useNavigate();\n const [formKey] = Form.useForm();\n const [loading, setLoading] = useState(loadingIntegration);\n const [showPassword, setShowPassword] = useState(false);\n const [keyPass, setKeyPass] = useState(\"\");\n const [fieldsError, setFieldsError] = useState<{ [key: string]: string[] }>(\n {}\n );\n const [modalParametrizacaoOpen, setModalParametrizacaoOpen] = useState(false);\n const [isMesa, setIsMesa] = useState(false);\n\n useEffect(() => {\n if (user?.user) {\n form.setFieldsValue({\n cpf: user.user.cpf,\n name: user.user.name,\n email: user.user.email,\n birthdate: user.user.birthdate ?? \"\",\n cellphone: user.user.cellphone ?? \"\",\n });\n }\n }, [user.user, form]);\n\n const getMesaOperacoes = useCallback(() => {\n apiBolsa.get('/warren/mesaOperacoes')\n .then((res) => {\n setIsMesa(res?.data?.isMesa || false)\n })\n .catch((err) => {\n message.error('Não foi possível consultar informações de mesa de operações')\n })\n }, [])\n\n useEffect(() => {\n if(modalParametrizacaoOpen){\n getMesaOperacoes()\n }\n }, [getMesaOperacoes, modalParametrizacaoOpen]);\n\n const setMesaOperacoes = () => {\n apiBolsa.post('/warren/mesaOperacoes', { isMesa })\n .then((res) => {\n if(res?.status === 202) {\n message.warning(res?.data?.message)\n } else {\n message.success('Suas informações foram salvas')\n getMesaOperacoes()\n handleIntegrate({onlyPrepareBolsa: true})\n }\n })\n .catch(() => {\n message.error('Não foi possível atualizar suas informações de mesa de operações')\n })\n }\n\n const onFinish = (data: any) => {\n if (loading) {\n return;\n }\n setLoading(true);\n api\n .put(\"/configuracoes/minhaConta\", {\n email: data.email,\n birthdate: data.birthdate,\n cellphone: data.cellphone,\n name: data.name,\n ...(showPassword\n ? {\n pass: data.pass,\n currentPass: data.currentPass,\n }\n : {}),\n })\n .then(() => {\n message.config({\n top: 50,\n });\n message.success(\"Dados atualizados com sucesso\");\n setLoading(false);\n setUser({\n ...user,\n user: {\n ...user.user,\n email: data.email,\n birthdate: data.birthdate,\n cellphone: data.cellphone,\n name: data.name,\n },\n });\n })\n .catch((err) => {\n message.error(\n err.response?.data?.message ||\n \"Erro ao atualizar dados. Tente novamente mais tarde!\"\n );\n setLoading(false);\n });\n };\n\n const removeAccount = () => {\n showWarningDeleteModal(true);\n };\n\n const onFieldsChange = () => {\n setFieldsError(\n form\n .getFieldsError()\n .reduce((acc, cur) => ({ ...acc, [cur.name?.[0]]: cur.errors }), {})\n );\n };\n\n const onCancel = () => {\n if (loading) {\n return;\n }\n navigate(\"/carteira\");\n };\n\n const handlePassword = () => {\n setShowPassword((show) => !show);\n };\n\n const sendDeleteReq = () => {\n if (keyPass.toLowerCase() !== KEY_PASS.toLowerCase()) {\n message.error(`Digite ${KEY_PASS} corretamente!`);\n return;\n }\n api\n .post(\"/user/remove-user\", {\n from: \"WARREN\",\n pass: keyPass,\n cpf: user.user.cpf,\n })\n .then(() => {\n message.success(\"Conta excluída com sucesso\");\n signOut();\n })\n .catch((err) => {\n message.error(err?.response?.data?.message);\n });\n };\n\n const onDeleteCancel = () => {\n showWarningDeleteModal(false);\n formKey.resetFields();\n setKeyPass(\"\");\n };\n\n return (\n \n \n

\n Dados do usuário\n navigate(\"/gestaoacesso\")}\n startIcon={}\n >\n Gestão de acessos\n \n

\n
\n \n \n 0}\n />\n \n\n \n \n \n\n \n 0}\n InputProps={{ inputComponent: MaskBirth as any }}\n InputLabelProps={{ shrink: true }}\n />\n \n\n \n \n \n\n \n 0}\n InputProps={{ inputComponent: MaskPhone as any }}\n InputLabelProps={{ shrink: true }}\n />\n \n\n \n {showPassword ? \"Não alterar senha\" : \"ALTERAR SENHA\"}\n \n\n {showPassword && (\n \n \n \n 0}\n />\n \n \n \n \n 0}\n />\n \n \n \n )}\n\n
\n
\n\n \n \n \n Cancelar\n \n \n \n }\n startIcon={loading && }\n >\n Salvar\n \n \n \n \n
\n \n \n \n EXCLUIR CONTA\n \n \n \n {/* \n \n \n \n */}\n setModalParametrizacaoOpen(false)}\n bodyStyle={{ paddingTop: '1rem' }}\n visible={modalParametrizacaoOpen}\n className=\"parametrizacao-modal\"\n >\n \n \n \n \n Funcionalidade exclusiva para investidores que realizam suas operações via Mesa de Operações (assessor).\n \n \n \n \n \n \n Selecione a parametrização de custos de corretagem:\n \n\n \n \n \n \n {setIsMesa(e === 'Mesa de operações' ? true : false)}}\n options={[\n { label: 'Não considerar', value: 'Não considerar' },\n { label: 'Mesa de operações', value: 'Mesa de operações' }\n ]}\n defaultValue={isMesa ? 'Mesa de operações' : 'Não considerar'} />\n \n \n \n \n }\n startIcon={loading && }\n onClick={() => {\n setMesaOperacoes()\n setModalParametrizacaoOpen(false)\n }}\n >\n Salvar\n \n \n \n \n \n \n \n \n \n \n \n Deseja realmente excluir sua conta?\n \n \n Lembre-se de que todos os seus dados também serão excluídos. Caso\n possua um plano ativo, você também perderá todas as\n funcionalidades.\n \n \n \n \n Digite {KEY_PASS} para prosseguir:\n \n \n \n {\n setKeyPass(event.target.value);\n }}\n >\n \n \n \n \n \n \n \n
\n );\n};\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n padding: 64px 32px 128px;\n h1 {\n font-weight: 400;\n font-size: 1.5rem;\n line-height: 2rem;\n color: var(--velotax-font-color-light);\n width: 700px;\n margin: 0 auto 16px;\n padding-bottom: 16px;\n position: relative;\n\n &::after {\n content: \"\";\n left: 0;\n bottom: 0;\n width: 100px;\n height: 2px;\n position: absolute;\n background-color: var(--ant-primary-color);\n }\n }\n p {\n font-size: 1rem;\n line-height: 1.5rem;\n color: var(--velotax-font-color-light);\n width: 700px;\n margin: 0 auto 32px;\n }\n @media only screen and (max-device-width: 812px) {\n min-height: 100%;\n padding: 24px 0 0;\n h1 {\n width: calc(100% - 48px);\n margin: 0 24px 16px;\n }\n p {\n width: calc(100% - 48px);\n padding: 0 0 24px;\n margin: 0 24px;\n }\n }\n`;\n\nexport const Content = styled.div`\n padding: 24px;\n margin: 0 auto;\n width: 700px;\n border-radius: 4px;\n background-color: var(--velotax-background-color);\n\n h3 {\n color: var(--velotax-font-color);\n }\n\n span.link {\n cursor: pointer;\n color: var(--ant-primary-color);\n }\n\n .ant-typography:not(h3) {\n text-align: justify;\n }\n\n a.ant-typography,\n .ant-typography a {\n color: var(--ant-primary-color);\n }\n\n .ant-typography i strong {\n font-size: 13px;\n letter-spacing: 0.625px;\n word-spacing: 0.625px;\n }\n\n iframe {\n max-width: 100%;\n }\n\n .ant-list {\n margin-bottom: 1em;\n }\n\n .ant-collapse,\n .ant-collapse.ant-collapse-borderless {\n border-radius: 8px;\n background-color: transparent;\n border: 1px solid var(--velotax-font-color-ghost);\n .ant-collapse-item {\n .ant-collapse-header {\n padding: 16px;\n font-size: 1.125rem;\n color: var(--velotax-font-color-light);\n .ant-collapse-arrow {\n font-size: 0.875rem;\n }\n }\n .ant-collapse-content {\n border-bottom: 1px solid;\n color: var(--velotax-font-color-light);\n background-color: var(--velotax-background-color);\n border-color: var(--velotax-font-color-ghost);\n }\n }\n\n .ant-collapse-item:last-child {\n .ant-collapse-content {\n border-bottom: none;\n border-radius: 0 0 8px 8px;\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n padding: 0;\n width: 100%;\n border-radius: 0;\n\n .ant-collapse,\n .ant-collapse.ant-collapse-borderless {\n border-radius: 0;\n border: none;\n }\n }\n`;\n","import { Divider, Typography } from \"antd\";\n\nexport const CompaniesExemptList = {\n title: \"Lista de empresas isentas\",\n content: (
\n \n \n Lista de ações que, se vendidas com lucro até o dia 31/12/2023, \n são isentas de Impostos de Renda com base na lei 13.043, de 13 de novembro de 2014:\n \n \n \n - NUTRIPLANT (NUTR3)
\n - PETRORIO (PRIO3)*
\n - GENERAL SHOPPING (GSHP3)
\n - POMIFRUTAS (FRTA3)
\n - CR2 EMPREENDIMENTOS IMOBILIÁRIOS (CRDE3)
\n - SINQIA (SQIA3)*
\n - BRASIL AGRO (AGRO3)
\n - PRINER (PRNR3)\n
\n \n \n * Válido para ações compradas antes do follow-on. A Sinqia e a Petrorio \n fizeram uma oferta de ações em setembro de 2019 e fevereiro de 2021, \n respectivamente. Caso você tenha comprado essas ações antes das datas das \n respectivas ofertas, você tem direito a isenção de imposto de renda sobre seus ganhos.\n \n
)\n};","import { useState } from \"react\";\nimport { List, Typography, Modal, Collapse } from \"antd\";\nimport { Container, Content } from \"./styles\";\nimport { CompaniesExemptList } from \"../../constants/regulation\";\n\ninterface RegulationProps {}\n\nexport const Regulation: React.FC = () => {\n const [showListModal, setShowListModal] = useState(false);\n\n const handleListModal = () => {\n setShowListModal((show) => !show);\n };\n return (\n \n

Regras de IR utilizadas pelo Velotax

\n

\n Entenda quais são as normativas da Receita Federal que utilizamos para\n calcular automaticamente o seu imposto de renda\n

\n \n \n \n \n Entendendo o que é renda variável\n \n \n O mercado de renda variável compreende ativos cuja remuneração ou\n retorno de capital não pode ser dimensionado no momento da\n aplicação. São eles as ações, quotas ou quinhões de capital, o\n ouro, ativo financeiro, e os contratos negociados nas bolsas de\n valores, de mercadorias, de futuros e assemelhadas.\n \n \n (Instrução Normativa RFB nº 1.585, de 31 de agosto de 2015, arts.\n 56, 58 e 60 a 62)\n \n \n Qual imposto de renda incide sobre operações de renda variável\n \n \n O ganhos líquidos são constituídos pela diferença positiva entre o\n valor de venda do ativo e o seu custo de aquisição. Os ganhos\n líquidos auferidos em operações realizadas em bolsas de valores,\n de mercadorias, de futuros, e assemelhadas, inclusive day trade,\n serão tributados às seguintes alíquotas:\n \n \n \n a) 15%, nas operações realizadas nos mercados à vista, a termo,\n de opções e de futuros;\n \n b) 20%, no caso de operação day trade;\n \n c) 20%, no caso de operação com fundos imobiliários (FIIs).\n \n \n \n (Lei nº 11.033, de 21 de dezembro de 2004, art. 2º, caput, incisos\n I e II, e §§ 1º e 2º; e Instrução Normativa RFB nº 1.585, de 31 de\n agosto de 2015, arts. 57, 63 e 65)\n \n \n Quando o imposto deve ser pago\n \n \n O imposto sobre a renda deve ser pago até o último dia útil do mês\n subsequente àquele em que os ganhos houverem sido apurados.\n
\n
O código a ser utilizado no Documento de Arrecadação das\n Receitas Federais (DARF) para pagamento desse tributo é 6015.\n
\n \n (Instrução Normativa RFB nº 1.585, de 31 de agosto de 2015, art.\n 56, § 5º)\n \n \n Operações isentas de imposto de renda\n \n \n A isenção de imposto de renda aplica-se para transações realizadas\n em mercados comuns e que se encaixem nas situações abaixo:\n \n \n \n a) com ações, no mercado à vista de bolsas de valores ou mercado\n de balcão, se o total das alienações desse ativo, realizadas no\n mês, não exceder a R$ 20.000,00 (vinte mil reais);\n \n \n b) com ações de pequenas e médias empresas a que se refere o\n art. 16 da Lei nº 13.043, de 13 de novembro de 2014;\n
\n \n Clique aqui para ver a lista de empresas isentas\n \n
\n \n c) com ouro, ativo financeiro, se o total das alienações desse\n ativo, realizadas no mês, não exceder a R$ 20.000,00 (vinte mil\n reais);\n \n
\n \n A isenção acima não se aplica, entre outras, às operações de day\n trade, às negociações de cotas de fundos de investimentos\n imobiliários (FIIs) e fundos de investimento em índice de ações,\n aos resgates de cotas de fundos ou clubes de investimento em ações\n e à alienação de ações efetivada em operações de exercício de\n opções e no vencimento ou liquidação antecipada de contratos a\n termo.\n \n \n (Lei nº 11.033, de 21 de dezembro de 2004, art.3º, inciso I; Lei\n nº 13.043, de 13 de novembro de 2014, art. 16; e Instrução\n Normativa RFB nº 1.585 , de 31 de agosto de 2015, art. 59, incisos\n I e II e § 2º)\n \n \n O que é operação day trade\n \n \n Considera-se day trade a operação ou a conjugação de operações\n iniciadas e encerradas em um mesmo dia, com o mesmo ativo,{\" \"}\n em uma mesma instituição intermediadora (isto é, corretora)\n , em que a quantidade negociada tenha sido liquidada, total ou\n parcialmente. Na apuração do resultado da operação day trade são\n considerados, pela ordem, o primeiro negócio de compra com o\n primeiro de venda ou o primeiro negócio de venda com o primeiro de\n compra, sucessivamente.\n \n \n (Lei nº 9.959, de 27 de janeiro de 2000, art. 8º; Lei nº 12.350,\n de 20 de dezembro de 2010, art. 45; e Instrução Normativa RFB nº\n 1.585, de 31 de agosto de 2015, art. 65)\n \n \n Compensação de perdas passadas\n \n \n As perdas incorridas nas operações de renda variável nos mercados\n à vista, de opções, futuros, a termo e assemelhados, poderão ser\n compensadas com os ganhos líquidos auferidos, no próprio mês ou\n nos meses subsequentes, em outras operações realizadas em qualquer\n das modalidades operacionais previstas nesses mercados.\n \n \n Atenção: as perdas incorridas em operações\n comuns, somente poderão ser compensadas com ganhos líquidos\n auferidos em operações da mesma espécie (comuns), realizadas no\n mês ou meses subsequentes. Do mesmo modo, as perdas incorridas em\n operações day trade somente são compensáveis com os ganhos\n líquidos auferidos nessas operações, e perdas incorridas em FIIs\n são compensáveis com os ganhos líquidos auferidos em FIIs.\n \n \n (Regulamento do Imposto sobre a Renda – RIR/2018, art. 841, §§ 1º\n e 2º, aprovado pelo Decreto nº 9.580, de 22 de novembro de 2018; e\n Instrução Normativa RFB nº 1.585, de 31 de agosto de 2015, art.\n 64)\n \n \n Dedução de despesas operacionais\n \n \n As despesas efetivamente pagas destacadas na nota de corretagem ou\n no extrato da conta-corrente para a realização de operações de\n compra ou venda (corretagens, emolumentos etc.) podem ser\n consideradas na apuração do ganho líquido, sendo acrescidas ao\n preço de compra e deduzidas do preço de venda dos ativos ou\n contratos negociados.\n \n \n (Lei nº 8.383, de 30 de dezembro de 1991, art. 27; e Regulamento\n do Imposto sobre a Renda - RIR/2018, art. 841, caput e § 2º,\n aprovado pelo Decreto nº 9.580, de 22 de novembro de 2018; e\n Instrução Normativa RFB nº 1.585, de 31 de agosto de 2015, art.\n 56, § 3º)\n \n \n O que é o Portal da B3\n \n \n O Portal da B3 armazena os saldos e os históricos de transação de\n forma consolidada para os investidores da bolsa de valores.\n
\n
\n Caso você nunca tenha se cadastrado no Portal da B3, faça o seu{\" \"}\n \n cadastro aqui\n \n . Só precisa ter o seu CPF e a data de nascimento em mãos.\n
\n {/*Remover os vídeos do passo a posso pois são baseados na calculadora antiga*/}\n {/* \n Ajustando manualmente o Velotax\n \n \n Apesar do sistema do Velotax ser o mais automático possível, algumas\n informações não estão disponíveis na B3. Portanto os investidores\n devem ter atenção para ajustar manualmente na{\" \"}\n Calculadora os pontos\n abaixo.\n */}\n {/* \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n */}\n \n Ainda tem dúvidas? Acesse:\n \n \n Central de Ajuda\n \n , onde nosso time de suporte responde suas dúvidas\n
\n\n \n \n Entendendo o que são criptoativos\n \n \n Os criptoativos são a representação digital de valor denominada em\n sua própria unidade de conta, cujo preço pode ser expresso em\n moeda soberana local ou estrangeira, transacionado eletronicamente\n com a utilização de criptografia e de tecnologias de registros\n distribuídos, que pode ser utilizado como forma de investimento,\n instrumento de transferência de valores ou acesso a serviços, e\n que não constitui moeda de curso legal.\n \n \n Alguns exemplos de criptoativos são Bitcoins, Altcoins (Ether,\n Ripple, Litecoin, entre outros) e Payment Tokens (Chiliz, Binance\n Coin, Chainlink, entre outros). Eles podem ser equiparados a\n ativos financeiros sujeitos a ganho de capital e devem ser\n declarados pelo seu valor de aquisição.\n \n \n (Instrução Normativa RFB nº 1.888, de 3 de maio de 2019)\n \n \n Qual imposto de renda incide sobre ganhos com criptoativos\n \n \n Os ganhos obtidos com a alienação de criptoativos cujo total\n alienado no mês seja superior a R$ 35.000,00 são tributados, a\n título de ganho de capital, segundo alíquotas progressivas\n estabelecidas em função do lucro:\n \n \n \n a) 15% sobre a parcela dos ganhos que não ultrapassar R$\n 5.000.000,00;\n \n \n b) 17,5% sobre a parcela dos ganhos que exceder R$ 5.000.000,00\n e não ultrapassar R$ 10.000.000,00;\n \n \n c) 20% sobre a parcela dos ganhos que exceder R$ 10.000.000,00 e\n não ultrapassar R$ 30.000.000,00; e\n \n \n d) 22,5% sobre a parcela dos ganhos que ultrapassar R$\n 30.000.000,00.\n \n \n \n (Lei nº 5.172, de 25 de outubro de 1966 - Código Tributário\n Nacional - CTN, art. 118; Lei nº 8.981, de 20 de janeiro de 1995,\n art. 21; Instrução Normativa SRF nº 84, de 11 de outubro de 2001;\n Instrução Normativa SRF nº 599, de 28 de dezembro de 2005; e Ato\n Declaratório Interpretativo RFB nº 3, de 27 de abril de 2016)\n \n \n Quando o imposto deve ser pago\n \n \n O recolhimento do imposto sobre a renda deve ser feito até o\n último dia útil do mês seguinte ao da transação de venda.\n \n \n O código a ser utilizado no Documento de Arrecadação das Receitas\n Federais (DARF) para pagamento desse tributo é 4600.\n \n \n (Lei nº 5.172, de 25 de outubro de 1966 - Código Tributário\n Nacional - CTN, art. 118; Lei nº 8.981, de 20 de janeiro de 1995,\n art. 21; Instrução Normativa SRF nº 84, de 11 de outubro de 2001;\n Instrução Normativa SRF nº 599, de 28 de dezembro de 2005; e Ato\n Declaratório Interpretativo RFB nº 3, de 27 de abril de 2016)\n \n \n Operações isentas de imposto de renda\n \n \n A isenção relativa às alienações de até R$ 35.000,00 mensais deve\n observar o conjunto de criptoativos ou moedas virtuais alienados\n no Brasil ou no exterior, independente de seu nome (bitcoin,\n ethereum, litecoin, tether ...). Caso o total alienado no mês\n ultrapasse esse valor, o ganho de capital relativo a todas as\n alienações estará sujeito à tributação.\n \n \n (Lei nº 5.172, de 25 de outubro de 1966 - Código Tributário\n Nacional - CTN, art. 118; Lei nº 8.981, de 20 de janeiro de 1995,\n art. 21; Instrução Normativa SRF nº 84, de 11 de outubro de 2001;\n Instrução Normativa SRF nº 599, de 28 de dezembro de 2005; e Ato\n Declaratório Interpretativo RFB nº 3, de 27 de abril de 2016)\n \n \n Como converter de dólares (US$) para reais (R$)\n \n \n Para a conversão de valores em reais, o valor expresso em moeda\n estrangeira deve ser convertido em dólar dos Estados Unidos da\n América e convertido em moeda nacional pela cotação do dólar dos\n Estados Unidos da América fixada, para venda, pelo Banco Central\n do Brasil (BCB) para a data da operação ou saldo, extraída do\n boletim de fechamento PTAX divulgado pelo BCB.\n \n \n (Instrução Normativa RFB nº 1.888, de 3 de maio de 2019)\n \n \n Compensação de perdas passadas\n \n \n Como os ganhos em criptoativos estão sujeitos as regulações de\n ganho de capital, as perdas passadas em criptoativos não podem ser\n compensadas dos ganhos futuros. As operações em criptoativos são\n tratadas de maneira singular, não sendo possível compensar os\n prejuízos de algumas operações com lucros de outras.\n \n \n Mesmo para operações no mesmo mês, de forma conservadora, valem as\n disposições acima: informar cada operação de venda, sem compensar\n lucros com perdas.\n \n \n (Instrução Normativa SRF nº 84, de 11 de outubro de 2001, art. 2º,\n parágrafo único)\n \n \n Dedução de despesas operacionais\n \n \n As despesas com corretagem na venda de criptoativos podem ser\n abatidas do ganho de capital a ser tributado.\n \n \n Ainda tem dúvidas? Acesse:\n \n -{\" \"}\n \n Central de Ajuda\n \n , onde nosso time de suporte responde suas dúvidas\n \n\n \n \n Entendendo quais ativos no exterior estão sujeitos a tributação\n \n \n A alienação de bens ou direitos e liquidação ou resgate de\n aplicações financeiras, de propriedade de pessoa física,\n adquiridos em moeda estrangeira estarão sujeitos as regras de\n tributação sobre ganho de capital.\n \n \n Caso você tenha realizado operações que importem na alienação\n (venda) de bens ou direitos adquiridos em moeda estrangeira, como\n ações e outros ativos financeiros em bolsa de valores, de\n mercadorias, de futuros ou assemelhadas, você deverá efetuar o\n cálculo de ganho de capital tributável e o recolhimento do imposto\n devido segundo as alíquotas progressivas estabelecidas em função\n do lucro.\n \n \n (Lei nº 13.254, de 13 de janeiro de 2016; Lei nº 13.428, de 30 de\n março de 2017; Instrução Normativa SRF nº 118, de 27 de dezembro\n de 2000; Instrução Normativa SRF nº 84, de 11 de outubro de 2001,\n art. 3º; Instrução Normativa RFB nº 1.627, de 11 de março de 2016;\n e Instrução Normativa RFB nº 1.704, de 31 de março de 2017)\n \n \n Qual imposto de renda incide sobre ganhos na venda de ativos no\n exterior\n \n \n Os ganhos obtidos com a alienação de investimentos no exterior\n cujo total alienado no mês seja superior a R$ 35.000,00 são\n tributados, a título de ganho de capital, segundo alíquotas\n progressivas estabelecidas em função do lucro:\n \n \n \n a) 15% sobre a parcela dos ganhos que não ultrapassar R$\n 5.000.000,00;\n \n \n b) 17,5% sobre a parcela dos ganhos que exceder R$ 5.000.000,00\n e não ultrapassar R$ 10.000.000,00;\n \n \n c) 20% sobre a parcela dos ganhos que exceder R$ 10.000.000,00 e\n não ultrapassar R$ 30.000.000,00;\n \n \n d) 22,5% sobre a parcela dos ganhos que ultrapassar R$\n 30.000.000,00.\n \n \n \n (Lei nº 8.981, de 20 de janeiro de 1995, art. 21; Lei nº 13.259,\n de 16 de março de 2016; e Ato Declaratório Interpretativo RFB nº\n 3, de 27 de abril de 2016)\n \n \n Quando o imposto deve ser pago\n \n \n O recolhimento do imposto sobre a renda deve ser feito até o\n último dia útil do mês seguinte ao da transação de venda.\n \n \n O código a ser utilizado no Documento de Arrecadação das Receitas\n Federais (DARF) para pagamento desse tributo é 8523.\n \n \n (Lei nº 5.172, de 25 de outubro de 1966 - Código Tributário\n Nacional - CTN, art. 118; Lei nº 8.981, de 20 de janeiro de 1995,\n art. 21; Instrução Normativa SRF nº 84, de 11 de outubro de 2001;\n Instrução Normativa SRF nº 599, de 28 de dezembro de 2005; e Ato\n Declaratório Interpretativo RFB nº 3, de 27 de abril de 2016)\n \n \n Operações isentas de imposto de renda\n \n \n A isenção relativa às alienações de até R$ 35.000,00 mensais deve\n observar o conjunto de instrumentos financeiros negociados em\n bolsa de valores no exterior, como ETFs (Exchange Traded Funds),\n REITs (Real Estate Investment Trust), ADRs (American Depositary\n Receipt) e Stocks (ações). Caso o total alienado no mês ultrapasse\n esse valor, o ganho de capital relativo a todas as alienações\n estará sujeito à tributação.\n \n \n (Lei nº 9.250, de 26 de dezembro de 1995, art. 22, I e II; Lei nº\n 10.406, de 10 de janeiro de 2002, art. 1.725; Instrução Normativa\n SRF nº 599, de 28 de dezembro de 2005, art. 1º; Solução de\n Consulta Cosit nº 320, de 20 de junho de 2017; e Solução de\n Consulta Cosit nº 264, de 24 de junho de 2019)\n \n \n Como funciona o cálculo do imposto de renda no exterior\n \n \n Na hipótese de bens ou direitos adquiridos e aplicações\n financeiras realizadas em moeda estrangeira com rendimentos\n auferidos originariamente em reais, o ganho de capital corresponde\n à diferença positiva, em reais, entre o valor de venda e o custo\n de aquisição da aplicação financeira.\n \n \n Neste caso, o valor de venda deve ser convertido para reais pela\n cotação do dólar fixada para compra, pelo Banco Central do Brasil,\n para a data do recebimento. Já o custo de aquisição deve ser\n convertido em reais pela cotação do dólar fixada para venda para a\n data do pagamento.\n \n \n Caso os rendimentos auferidos utilizados na aquisição sejam\n originariamente em moeda estrangeira, o ganho de capital\n corresponde à diferença positiva, em dólares dos Estados Unidos da\n América, entre o valor de venda e o custo de aquisição da\n aplicação, convertida em moeda nacional mediante a utilização da\n cotação do dólar fixada, para compra, pelo Banco Central do\n Brasil, para a data do recebimento\n \n \n (Medida Provisória nº 2.158-35, de 24 de agosto de 2001, art. 24;\n Lei nº 8.981, de 20 de janeiro de 1995, art. 21; Instrução\n Normativa SRF nº 208, de 27 de setembro de 2002; Instrução\n Normativa SRF nº 118, de 27 de dezembro de 2000; Solução de\n Consulta Interna Cosit nº 5, de 15 de fevereiro de 2013; e Solução\n de Consulta Cosit nº 33, de 26 de fevereiro de 2015)\n \n \n Como converter de dólares (US$) para reais (R$)\n \n \n Para a conversão de valores em reais, o valor expresso em moeda\n estrangeira deve ser convertido em dólar dos Estados Unidos da\n América e convertido em moeda nacional pela cotação do dólar dos\n Estados Unidos da América fixada, para compra ou venda, pelo Banco\n Central do Brasil (BCB) para a data da operação ou saldo, extraída\n do boletim de fechamento PTAX divulgado pelo BCB.\n \n \n (Instrução Normativa RFB nº 1.888, de 3 de maio de 2019)\n \n \n Compensação de perdas passadas\n \n \n Como os ganhos na venda de ativos no exterior estão sujeitos as\n regulações de ganho de capital, as perdas passadas em ativos no\n exterior não podem ser compensadas dos ganhos futuros. As\n operações com ativos no exterior são tratadas de maneira singular,\n não sendo possível compensar os prejuízos de algumas operações com\n lucros de outras.\n \n \n Mesmo para operações no mesmo mês, de forma conservadora, valem as\n disposições acima: informar cada operação de venda, sem compensar\n lucros com perdas.\n \n \n (Instrução Normativa SRF nº 84, de 11 de outubro de 2001, art. 2º,\n parágrafo único)\n \n \n Dedução de despesas operacionais\n \n \n As despesas com corretagem na venda de ativos no exterior podem\n ser abatidas do ganho de capital a ser tributado.\n \n \n Ainda tem dúvidas? Acesse:\n \n -{\" \"}\n \n Central de Ajuda\n \n , onde nosso time de suporte responde suas dúvidas\n \n\n {/* \n \n Imposto de Renda sobre Rendimentos\n \n \n Os rendimentos recebidos de outras pessoas físicas ou de fontes no\n exterior que ultrapassem o valor isento de R$1.903,98 por mês\n estarão sujeitos ao recolhimento mensal do imposto de renda.\n \n \n Nessa categoria, os principais rendimentos tributados incluem,\n entre outros:\n \n \n \n a) Autônomos, incluindo trabalhos sem vínculo empregatício;\n \n \n b) Aluguéis, incluindo a locação e sublocação de bens móveis e\n imóveis;\n \n \n c) Pensão, incluindo pensão alimentícia e alimentos\n provisionais;\n \n \n d) Exterior, incluindo quaisquer valores recebidos de fontes do\n exterior.\n \n \n \n (Regulamento do Imposto sobre a Renda - RIR/2018, arts. 118 a 121\n e art. 123, aprovado pelo Decreto nº 9.580, de 22 de novembro de\n 2018; Instrução Normativa RFB nº 1.500, de 29 de outubro de 2014,\n arts. 24, § 4º, 53 e 54; Instrução Normativa RFB nº 1.531, de 19\n de dezembro de 2014)\n \n Autônomos\n \n Inclui os profissionais não-assalariados que recebem de outras\n pessoas físicas, e que possuem rendimentos advindos da prestação\n de serviços de representante comercial autônomo, intermediação na\n realização de negócios por conta de terceiros, prestação de\n serviços de transporte de passageiros, prestação de serviços de\n transporte de cargas, entre outros trabalhos sem vínculo\n empregatício.\n \n Aluguéis\n \n Inclui proprietários de imóveis que possuem rendimentos de\n aluguéis, considerando que:\n \n \n \n (a) Apenas o valor líquido do aluguel é tributado. As despesas\n de IPTU, condomínio, cobrança/recebimento e aluguel no caso de\n imóvel sublocado podem ser descontadas do rendimento;\n \n \n (b) Se você tiver mais de um imóvel e receber mais de um aluguel\n por mês, será necessário considerar a quantia total dos aluguéis\n recebidos.\n \n \n \n A data do pagamento, para efeito de incidência do imposto, será\n considerada aquela em que o locatário pagar o aluguel ao\n proprietário do bem ou à administradora.\n \n Pensão Alimentícia\n \n Inclui os alimentandos que recebem pensão alimentícia. A pensão\n alimentícia pode ser recebida não apenas pelos filhos, mas por\n qualquer pessoa que tenha recebido esse benefício por decisão\n judicial, acordo homologado judicialmente ou por escritura\n pública. O contribuinte é o beneficiário da pensão, ainda que\n tenha sido paga a seu representante legal.\n \n Exterior\n \n Inclui pessoas físicas com rendimentos ou quaisquer outros valores\n recebidos de fontes do exterior. Neste caso, é importante observar\n a possível existência de{\" \"}\n \n acordos, convenções e tratados internacionais\n {\" \"}\n firmados entre o Brasil e o país de origem dos rendimentos para\n evitar a bitributação.\n \n \n Qual imposto de renda incide\n \n \n O imposto sobre rendimentos é calculado sobre o total recebido no\n mês, mediante a aplicação da seguinte tabela progressiva mensal:\n \n \n \n a) Até R$ 1.903,98 não há impostos a pagar;\n \n \n b) De R$ 1.903,99 até R$ 2.826,65, a alíquota é de 7,5% sobre os\n rendimentos, com parcela a deduzir de R$ 142,80;\n \n \n c) De R$ 2.826,66 até R$ 3.751,05, a alíquota é de 15% sobre os\n rendimentos, com parcela a deduzir de R$ 354,80;\n \n \n d) De R$ 3.751,06 até R$ 4.664,68, a alíquota é de 22,5% sobre\n os rendimentos, com parcela a deduzir de R$ 636,13;\n \n \n e) Acima de R$ 4.664,68, a alíquota é de 27,5% sobre os\n rendimentos, com parcela a deduzir de R$ 869,36.\n \n \n \n (Lei nº 11.482, de 31 de maio de 2007, arts. 1º e 3º; Lei nº\n 12.024, de 27 de agosto de 2009, art. 3º; Regulamento do Imposto\n sobre a Renda - RIR/2018, art. 121, aprovado pelo Decreto nº\n 9.580, de 22 de novembro de 2018; Instrução Normativa RFB nº\n 1.500, de 29 de outubro de 2014, arts. 53 a 57 e 65; Solução de\n Consulta Interna Cosit nº 3, de 8 de fevereiro de 2012; e Solução\n de Consulta Interna Cosit nº 6, de 25 de maio de 2015)\n \n \n Quando o imposto deve ser pago\n \n \n O recolhimento do imposto de renda deve ser feito até o último dia\n útil do mês seguinte ao recebimento dos rendimentos.\n \n \n O código a ser utilizado no Documento de Arrecadação das Receitas\n Federais (DARF) para pagamento desse tributo é 0190.\n \n \n (Lei nº 8.383, de 30 de dezembro de 1991, art. 7º; e Instrução\n Normativa RFB nº 1.500, de 29 de outubro de 2014, arts. 53 a 57 e\n 67)\n \n \n \n \n \n Deduções no imposto de renda\n \n \n São admitidas as seguintes deduções na base de cálculo do imposto\n sobre rendimentos:\n \n \n \n a) Contribuição previdenciária oficial, o INSS;\n \n \n b) Dependentes, sendo R$ 189,59 por dependente a partir do ano\n 2021;\n \n \n c) Pensão alimentícia, quando paga em cumprimento de decisão\n judicial, inclusive os alimentos provisionais, de acordo\n homologado judicialmente ou de escritura pública; e\n \n \n d) Despesas relacionadas à atividade do profissional autônomo\n \n \n \n No caso de autônomos, somente as seguintes categorias de despesas\n podem ser deduzidas da base tributária:\n \n \n \n i) Despesas trabalhistas;\n \n \n ii) Serviços de terceiros;\n \n \n iii) Despesas com custeio e funcionamento;\n \n \n iv) Propaganda, assinatura de jornais e revistas;\n \n v) Roupas especiais;\n \n vi) Contribuições a sindicatos, associações ou conselhos;\n \n \n vii) Despesas com congressos e seminários;\n \n \n viii) Honorários profissionais;\n \n \n ix) Imóvel residencial ou profissional;\n \n \n x) Manutenção e conservação;\n \n \n xi) Correios e transporte;\n \n \n xii) Instalações, máquinas e equipamentos;\n \n \n xii) Despesas Comuns como rateio sob forma de Condomínio;\n \n \n xiv) Outras despesas necessárias à atividade específica e\n individual de cada contribuinte não contempladas anteriormente.\n \n \n \n (Lei nº 7.290, de 19 de dezembro de 1984; Lei nº 7.713, de 22 de\n dezembro de 1988, art. 9º; Regulamento do Imposto sobre a Renda -\n RIR/2018, arts. 39 e 158, § 1º, aprovado pelo Decreto nº 9.580, de\n 22 de novembro de 2018; e Parecer Normativo CST nº 122, de 8 de\n junho de 1974)\n \n \n Utilizando o Velotax para IR em Rendimentos\n \n \n A{\" \"}\n navigate(`/${currentBroker.path}/autonomos`)}\n >\n Calculadora\n {\" \"}\n do Velotax para cálculo e pagamento de IR sobre rendimentos de\n pessoas físicas ou fontes no exterior permite a inclusão manual de\n operações, e realiza os cálculos automaticamente seguindo as\n regras da Receita Federal.\n \n \n Após inserir os seus rendimentos do mês, o Velotax calculará os\n seus impostos devidos de acordo com as regras acima e emitirá o\n seu DARF para pagamento.\n \n \n Caso você esteja pagando em atraso, o Velotax também incluirá\n automaticamente os juros e multa devidos no seu DARF.\n \n \n Ainda tem dúvidas? Acesse:\n \n \n -{\" \"}\n \n Fórum\n {\" \"}\n , onde nossa comunidade de usuários responde suas dúvidas\n \n */}\n
\n
\n\n \n {CompaniesExemptList?.content}\n \n
\n );\n};\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n padding: 64px 32px 128px;\n &.view-edit {\n padding: 0;\n }\n &.view {\n padding: 0;\n }\n\n h1 {\n width: 700px;\n margin: 0 auto 1.5rem;\n font-weight: 400;\n font-size: 2rem;\n position: relative;\n line-height: 2.5rem;\n padding-bottom: 1rem;\n color: var(--velotax-font-color-light);\n\n :after {\n content: \"\";\n position: absolute;\n left: 0;\n bottom: 0;\n height: 2px;\n width: 100px;\n background-color: var(--ant-primary-color);\n }\n }\n\n .juridic-messages-container {\n opacity: 0.8;\n margin: 0 auto;\n padding: 24px 0 0;\n max-width: 700px;\n\n .message {\n display: flex;\n flex-direction: row;\n align-items: center;\n margin-bottom: 1rem;\n }\n\n p {\n font-size: 0.85rem;\n font-weight: 400;\n text-align: justify;\n line-height: 1.5rem;\n color: var(--velotax-font-color-light);\n margin-bottom: 0;\n\n i {\n font-weight: bold;\n color: var(--velotax-font-color-light);\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n padding: 0 0 64px;\n\n h1 {\n max-width: calc(100% - 48px);\n margin: 0 24px 1.5rem;\n padding: 24px 0 1rem;\n }\n\n .juridic-messages-container {\n margin: 0;\n width: 100%;\n p {\n margin-left: 0;\n }\n }\n }\n`;\n\nexport const Content = styled.div`\n padding: 32px;\n &.second.view,\n &.second.view-edit {\n padding: 0 32px 32px;\n }\n &.second {\n padding: 32px;\n }\n margin: 0 auto;\n max-width: 700px;\n border-radius: 4px;\n background-color: var(--velotax-background-color);\n h3 {\n display: flex;\n align-items: center;\n font-size: 20px;\n column-gap: 16px;\n color: var(--velotax-font-color-light);\n margin-bottom: 0;\n user-select: none;\n }\n h3.date-title {\n font-size: 24px;\n font-weight: 700;\n }\n .month-chevron {\n width: 32px;\n height: 32px;\n cursor: pointer;\n &.disabled {\n opacity: 0.15;\n cursor: default;\n }\n }\n .desc-label {\n display: flex;\n align-items: center;\n svg {\n fill: var(--ant-primary-color);\n }\n }\n .desc-content {\n display: flex;\n align-items: flex-start;\n justify-content: center;\n column-gap: 8px;\n svg {\n fill: var(--ant-primary-color);\n }\n span {\n align-self: center;\n }\n button {\n min-width: 32px;\n }\n }\n .ml-40 {\n margin-left: 40px;\n }\n .add {\n float: right;\n min-width: 128px;\n margin-bottom: 16px;\n }\n .ant-descriptions-view {\n border-radius: 4px !important;\n }\n .ant-descriptions-item-label {\n width: 50%;\n color: var(--velotax-font-color-light) !important;\n }\n .ant-descriptions-item-content {\n text-align: center;\n background-color: var(--velotax-background-color-ghost) !important;\n span {\n color: var(--velotax-font-color-light) !important;\n }\n }\n .ant-list.ant-list-split {\n clear: both;\n padding: 0 16px;\n background-color: var(--velotax-ghost);\n border: 1px solid var(--velotax-ghost);\n border-radius: 4px;\n .ant-list-item-action > li {\n padding: 0;\n }\n }\n .ant-list-item-action > li,\n .ant-list-item-meta-title,\n .ant-list-item-meta-description {\n color: var(--velotax-font-color-light);\n }\n .ant-list-item-meta-description {\n opacity: 0.75;\n }\n .list-description {\n display: flex;\n flex-direction: column;\n }\n .min-darf-price {\n margin-top: 24px;\n display: flex;\n align-items: center;\n column-gap: 8px;\n }\n .text-center {\n display: block;\n text-align: center;\n }\n .ant-collapse-header {\n padding: 12px 0 !important;\n }\n .ant-collapse-content-box {\n padding: 16px 0 !important;\n }\n .ant-collapse\n > .ant-collapse-item\n > .ant-collapse-header\n .ant-collapse-arrow\n svg {\n transform: rotate(-90deg);\n }\n .ant-collapse-item-disabled {\n & > .ant-collapse-header {\n cursor: default;\n .ant-collapse-arrow {\n opacity: 0;\n }\n }\n }\n .ant-collapse-header-text {\n width: 100%;\n }\n .total-tax-header {\n width: calc(100% - 48px);\n display: flex;\n align-items: center;\n justify-content: space-between;\n &.original {\n h3:last-of-type {\n width: 40%;\n }\n }\n h3 {\n margin: 0 0 8px;\n }\n }\n\n .no-plan-container {\n position: absolute;\n top: 0;\n left: 50%;\n width: 50%;\n z-index: 3;\n height: 100%;\n padding: 8px;\n display: flex;\n font-size: 16px;\n font-weight: 500;\n text-align: center;\n align-items: center;\n flex-direction: column;\n justify-content: center;\n background-color: #fff4;\n border-radius: 0 8px 8px 0;\n backdrop-filter: blur(4px);\n border: 1px solid var(--velotax-background-color-ghost);\n border-left: none;\n .ant-btn {\n margin-top: 8px;\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n width: 100%;\n padding: 24px;\n border-radius: 0;\n &.first {\n padding: 24px;\n }\n &.second {\n padding: 24px !important;\n border-top: 1px solid #efefef;\n }\n h3 {\n font-size: 18px;\n }\n .no-plan-container {\n font-size: 14px;\n line-height: 18px;\n }\n .anticon.anticon-right.ant-collapse-arrow {\n top: 24px;\n }\n .desc-content {\n column-gap: 2px;\n flex-direction: row;\n &.is-editting {\n row-gap: 8px;\n flex-direction: column;\n button {\n width: 100%;\n }\n }\n &:not(.is-editting) {\n span {\n line-height: 32px;\n }\n button {\n margin-top: -2px;\n }\n }\n &.ml-40 {\n margin-left: 0;\n }\n }\n }\n`;\n","import { useEffect, useState } from \"react\";\nimport { Col, Form, Modal, Row } from \"antd\";\nimport { FooterModal } from \"../FooterModal\";\nimport api from \"../../services/apiExterior\";\n\ninterface FormModalProps {\n add: any;\n edit: any;\n title: string;\n onCancel: any;\n itemToEdit: any;\n visibility: boolean;\n hideFooter?: boolean;\n rows: any[];\n disableButtons?: boolean;\n preFormChildren?: React.ReactNode;\n loading?: boolean;\n cancelButtonText?: string;\n saveButtonText?: string;\n}\n\nexport const FormModal: React.FC = ({\n add,\n edit,\n rows,\n title,\n onCancel,\n visibility,\n itemToEdit,\n children,\n disableButtons,\n preFormChildren,\n hideFooter,\n loading,\n cancelButtonText,\n saveButtonText\n}) => {\n const [form] = Form.useForm();\n const [, setUpdate] = useState(false);\n\n useEffect(() => {\n if (!visibility) {\n form.resetFields();\n } else if (itemToEdit) {\n setUpdate((update) => !update);\n form.setFieldsValue(itemToEdit);\n }\n }, [visibility, form, itemToEdit]);\n\n const onValuesChange = async (changedValues: any, values: any) => {\n const inputs = rows\n .flat()\n .map((input) =>\n typeof input === \"function\" ? input({ data: values }) : input\n );\n if (\n inputs\n .filter((item) => item.mustUpdate)\n .map((item) => item.name)\n .includes(Object.keys(changedValues)[0])\n ) {\n setUpdate((update) => !update);\n }\n let data;\n if (changedValues?.date?.replace(\"_\", \"\").length === 10) {\n const response = await api.get(\"/dividendos/get-cambio\", {\n params: { date: changedValues.date }\n });\n values.taxaCambio = response?.data;\n }\n data = {\n ...values,\n ...inputs\n .filter((input) => input.onChange)\n .reduce(\n (acc, cur) => ({\n ...acc,\n [cur.name]: cur.onChange?.(changedValues, { ...values, ...acc }),\n }),\n {}\n ),\n };\n const dataEntries = Object.entries(data);\n form.setFields(dataEntries.map(([name, value]) => ({ name, value })));\n form.resetFields(\n dataEntries\n .filter(([, value]) => value === undefined || value === null)\n .map(([name]) => name)\n );\n };\n\n const onFinish = (data: any) => {\n if (itemToEdit) {\n edit(data);\n } else {\n add(data);\n }\n };\n\n return (\n \n {preFormChildren}\n \n {rows.map((row, index) => (\n \n {row\n .map((input: any) =>\n typeof input === \"function\"\n ? input({ data: form.getFieldsValue() })\n : input\n )\n .filter(\n (input: any) =>\n !(\n typeof input.hide === \"function\" &&\n input.hide({ data: form.getFieldsValue() })\n )\n )\n .map((input: any, index: number, array: any[]) => (\n \n \n ))}\n {children}\n
\n {!hideFooter && (\n \n )}\n \n \n );\n};\n","import { useState } from \"react\";\nimport { useNavigate } from \"react-router-dom\";\nimport { Divider, message, Modal, Typography } from \"antd\";\nimport apis from \"../../../../services/apis\";\nimport Button from \"../../../../components/Button\";\nimport { useAuth } from \"../../../../contexts/AuthContext\";\nimport { useBroker } from \"../../../../contexts/BrokerContext\";\nimport { errorMessage, monthsExtended } from \"../../../../utils\";\n\ninterface IntegrationModalProps {\n visible: boolean;\n onCancel: () => void;\n}\n\nexport const IntegrationModal: React.FC = ({\n visible,\n onCancel,\n}) => {\n const { user } = useAuth();\n const navigate = useNavigate();\n const [loading, setLoading] = useState(false);\n const { currentBroker, integration, handleIntegrationInit, currentPage } =\n useBroker();\n\n const integrationDate = new Date(integration.lastUpdate);\n\n const handleIntegrate = () => {\n if (integration.key) {\n setLoading(true);\n (currentPage?.api || apis)\n .post(`${currentBroker.apiUrl}/integrate`, {\n key: integration.key,\n email: user.user.email,\n })\n .then(() => {\n setLoading(false);\n handleIntegrationInit();\n })\n .catch((err) => {\n setLoading(false);\n if (err?.response?.data?.message?.includes(\"Aguarde\")) {\n message.error(err?.response?.data?.message);\n } else {\n message.error(errorMessage);\n }\n });\n } else {\n navigate(`/${currentBroker.path}/integration`);\n }\n };\n\n return (\n \n \n A sua última integração foi feita no mês de{\" \"}\n {monthsExtended[integrationDate.getMonth()]} de{\" \"}\n {integrationDate.getFullYear()}. Para gerenciar operações e gerar DARFs\n dos meses seguintes ao da última integração, você precisa integrar\n novamente.\n \n \n \n Integrar\n \n \n );\n};\n","import { Typography } from \"antd\";\n\nexport const DatePickerExtraFooter: React.FC = () => {\n return (\n <>\n Situação:\n
\n Imposto apurado\n
\n
\n Imposto devido\n
\n \n );\n};\n","import React, { useState } from \"react\";\nimport { LoadingOutlined } from \"@ant-design/icons\";\nimport { Col, Divider, message, Modal, Row } from \"antd\";\nimport { Button } from \"@mui/material\";\n\ninterface IDeleteConfirmationModalProps {\n title: string;\n visibility: boolean;\n body: React.ReactNode;\n onCancel: () => void;\n onOk?: () => Promise;\n updateData?: () => void;\n setVisibility: (param: any) => void;\n buttonLabel?: string;\n showToast?: boolean;\n successMessage?: string;\n}\n\nconst DeleteConfirmationModal: React.FC = ({\n title,\n visibility,\n onCancel,\n onOk,\n body,\n updateData,\n setVisibility,\n buttonLabel,\n showToast = true,\n successMessage\n}) => {\n const [loading, setLoading] = useState(false);\n const handleOnOk = () => {\n setLoading(true);\n const finish = () => {\n setLoading(false);\n updateData?.();\n setVisibility(false);\n showToast && message.success(successMessage || \"Deletado com sucesso\");\n };\n if (onOk) {\n onOk()\n .then(() => finish())\n .catch((err) => {\n showToast && message.error(\"Algo deu errado\");\n setLoading(false);\n });\n } else {\n finish();\n }\n };\n return (\n \n

{body}

\n \n \n \n \n Cancelar\n \n \n \n \n {loading && }\n {buttonLabel || \"Deletar\"}\n \n \n \n \n );\n};\n\nexport default DeleteConfirmationModal;\n","import clsx from \"clsx\";\nimport { months } from \"../../../../utils\";\nimport {\n YearResumeStatusCSSClassEnum,\n YearResumeStatusFromBackEnum,\n} from \"../../../../constants/darf\";\n\nexport interface YearResume {\n year: number;\n months: {\n month: number;\n payed: boolean;\n status: keyof typeof YearResumeStatusFromBackEnum;\n }[];\n}\n\ninterface DatePickerMonthCellProps {\n event: moment.Moment;\n yearResume: YearResume[];\n}\n\nexport const DatePickerMonthCell: React.FC = ({\n event,\n yearResume,\n}) => {\n const date = new Date();\n const year = event.year();\n const month = event.month();\n const item = yearResume\n .find((list) => list.year === year)\n ?.months.find((item) => item.month - 1 === month);\n const disabled = year === date.getFullYear() && month >= date.getMonth();\n return (\n \n {months[month]}\n \n );\n};\n","import clsx from \"clsx\";\nimport moment from \"moment\";\nimport { Button } from \"@mui/material\";\nimport { FaRegEdit } from \"react-icons/fa\";\nimport { BsCalendar3, BsDownload } from \"react-icons/bs\";\nimport { useLocation, useNavigate } from \"react-router-dom\";\nimport { BiChevronLeft, BiChevronRight } from \"react-icons/bi\";\nimport { AiOutlineDelete, AiOutlineLock } from \"react-icons/ai\";\nimport { useCallback, useEffect, useMemo, useState, ReactNode } from \"react\";\nimport { LoadingOutlined, PlusOutlined } from \"@ant-design/icons\";\nimport {\n Col,\n Collapse,\n DatePicker,\n Descriptions,\n List,\n message,\n Modal,\n Row,\n Skeleton,\n Space,\n Spin,\n Tooltip,\n Typography,\n} from \"antd\";\nimport { Container, Content } from \"./styles\";\nimport { Page } from \"../../constants/brokers\";\nimport AntButton from \"../../components/Button\";\nimport { useAuth } from \"../../contexts/AuthContext\";\nimport { FormModal } from \"../../components/FormModal\";\nimport { apiPayment } from \"../../services/apiPayment\";\nimport { useBroker } from \"../../contexts/BrokerContext\";\nimport apis, { NOT_AUTHORIZED } from \"../../services/apis\";\nimport { PaymentModal } from \"../../components/PaymentModal\";\nimport { IntegrationModal } from \"./Components/IntegrationModal\";\nimport { DatePickerExtraFooter } from \"./Components/DatePickerExtraFooter\";\nimport DeleteConfirmationModal from \"../../components/DeleteConfirmationModal\";\nimport {\n DatePickerMonthCell,\n YearResume,\n} from \"./Components/DatePickerMonthCell\";\nimport {\n antDatePickerLocale,\n download,\n errorMessage,\n formatCurrency,\n isMobile,\n monthsExtended,\n} from \"../../utils\";\nimport {\n DarfResultDescriptions,\n DarfFormItemRows,\n defaultDarf,\n DarfModal,\n IDarf,\n DarfImpostosDevidosDescriptions,\n minDarfPrice,\n maxDarfPrice,\n YearResumeStatusFromBackEnum,\n} from \"../../constants/darf\";\n\ninterface DarfProps {\n item: Page;\n view?: boolean;\n viewEdit?: boolean;\n closeModal?: () => void;\n darf?: {\n id: string;\n fullPath?: string;\n };\n date?: {\n year?: number;\n month?: number;\n };\n}\n\nexport const Darf: React.FC = ({\n item,\n view,\n date,\n darf,\n viewEdit,\n closeModal,\n}) => {\n const {\n user,\n hasPlan: hasPremiunPlan,\n showUserPlanModal,\n userPlanModal,\n } = useAuth();\n const hasPlan = hasPremiunPlan;\n\n const navigate = useNavigate();\n const { state } = useLocation();\n const { currentBroker, currentPage } = useBroker();\n const today = new Date();\n const queryYear = (state as any)?.year as number;\n const queryMonth = (state as any)?.month as number;\n const currentMonth = today.getMonth();\n const currentYear = today.getFullYear();\n const maxPixPayment = 10000;\n const maxCreditCardPayment = 10000;\n\n const initialMonth = queryMonth\n ? queryMonth - 1\n : today.getMonth() - 1 >= 0\n ? today.getMonth() - 1\n : 11;\n const initialYear = queryYear\n ? queryYear\n : today.getMonth() - 1 >= 0\n ? today.getFullYear()\n : today.getFullYear() - 1;\n const defaultValue = moment({ month: initialMonth, year: initialYear });\n const currentDate = moment({\n month: currentMonth,\n year: currentYear,\n }).subtract(1, \"M\");\n window.history.replaceState({}, document.title);\n\n const year = date?.year ?? initialYear;\n const month = date?.month ?? initialMonth;\n\n const [asset, setAsset] = useState();\n const [loading, setLoading] = useState(true);\n const [emitting, setEmitting] = useState(false);\n const [darfModal, setDarfModal] = useState();\n const [helpModal, setHelpModal] = useState();\n const [paymentModal, setPaymentModal] = useState(false);\n const [paymentData, setPaymentData] = useState();\n const [, setYear] = useState(initialYear);\n const [, setMonth] = useState(initialMonth);\n const [data, setData] = useState(defaultDarf);\n const [showAssetModal, setShowAssetModal] = useState(false);\n const [showDeleteModal, setShowDeleteModal] = useState(false);\n const [yearResume, setYearResume] = useState([]);\n const [gettingYearResume, setGettingYearResume] = useState(false);\n const [datePickerYear, setDatePickerYear] = useState(initialYear);\n const [notAuthorized, setNotAuthorized] = useState(false);\n const [showNotAuthorizedModal, setShowNotAuthorizedModal] = useState(false);\n const [loadingDarfButton, setLoadingDarfButton] = useState(false);\n\n const transactionFeature = item.features[0];\n const taxFeature = item.features[1];\n const yearResumeFeature = item.features[2];\n\n // const userPlanInfoStatus = useMemo(\n // () => user.user.userPlanInfoVelotax,\n // [user.user.userPlanInfoVelotax]\n // );\n\n const { emitted } = useMemo(() => {\n if (gettingYearResume) {\n }\n const monthResume = yearResume\n .find((resume) => resume.year === year)\n ?.months.find((m) => m.month - 1 === month);\n return {\n emitted:\n monthResume?.status === YearResumeStatusFromBackEnum.PAYED ||\n monthResume?.status === YearResumeStatusFromBackEnum.NOT_PAYED,\n payed: !!monthResume?.payed,\n status: monthResume?.status,\n };\n }, [yearResume, year, month, gettingYearResume]);\n\n const getDarf = useCallback(\n (id: string) => {\n view && setLoading(true);\n view &&\n (currentPage?.api || apis)\n .get(`${taxFeature.apiUrl}/${id}`)\n .then((response) => {\n setYear(response.data?.year);\n setMonth(response.data?.month - 1);\n setData({\n ...response.data,\n emitted: true,\n });\n })\n .catch(() => message.error(errorMessage))\n .finally(() => setLoading(false));\n },\n [view, taxFeature.apiUrl, currentPage]\n );\n\n const getYearResume = useCallback(\n (year: number, force?: boolean, url?: string) => {\n setGettingYearResume(true);\n !view &&\n year <= new Date().getFullYear() &&\n year >= currentBroker.initialYear &&\n (force ||\n (!yearResumeFeature.disabled &&\n !yearResume.find((resume) => resume.year === year))) &&\n (currentPage?.api || apis)\n .get(yearResumeFeature.apiUrl, { params: { year } })\n .then((response) => {\n const index = yearResume.findIndex(\n (resume) => resume.year === year\n );\n if (index >= 0) {\n setYearResume((yearResume) => {\n yearResume.splice(index, 1, response.data);\n return yearResume;\n });\n } else {\n setYearResume((yearResume) => [...yearResume, response.data]);\n }\n\n if (url && !isMobile()) {\n download(url);\n }\n })\n .catch((err) => console.log(err))\n .finally(() => setGettingYearResume(false));\n },\n [\n yearResumeFeature,\n yearResume,\n view,\n currentBroker.initialYear,\n currentPage,\n ]\n );\n\n const getTaxes = useCallback(() => {\n (!hasPlan || !view) && setLoading(true);\n (!hasPlan || !view) &&\n (currentPage?.api || apis)\n .get(transactionFeature.apiUrl, { params: { month: month + 1, year } })\n .then((response) => {\n setData(response.data);\n setNotAuthorized(false);\n })\n .catch((err) => {\n setData(defaultDarf);\n if (err?.response?.data === NOT_AUTHORIZED) {\n setNotAuthorized(true);\n setShowNotAuthorizedModal(true);\n } else {\n setNotAuthorized(false);\n message.error(errorMessage);\n }\n })\n .finally(() => setLoading(false));\n }, [view, currentPage?.api, transactionFeature.apiUrl, month, year, hasPlan]);\n\n const handleDarf = (justSave?: boolean) => {\n setEmitting(true);\n onCloseDarfModal();\n (currentPage?.api || apis)\n .post(taxFeature.apiUrl, {\n ...data,\n year,\n month: month + 1,\n name: user.user.name,\n memoriaCalculo: [],\n transactions: data.memoriaCalculo,\n paymentInfo: {\n clientInfo: {\n name: user?.user?.name,\n email: user?.user?.email,\n document: user?.user?.cpf,\n },\n },\n insertPix: true,\n justSave,\n payed: false,\n })\n .then((res) => {\n setData((data) => ({ ...data, emitted: true }));\n getYearResume(year, true, justSave ? \"\" : res.data.darfUrl);\n setEmitting(false);\n closeModal?.();\n if (!justSave) {\n message.success(\"O DARF foi enviado para o seu e-mail\");\n }\n })\n .catch((err) => {\n message.error(err?.response?.data?.message || errorMessage);\n setEmitting(false);\n });\n };\n\n const handleRegularize = (regular: boolean) => {\n setEmitting(true);\n (currentPage?.api || apis)\n .post(\"transaction/regularize\", {\n year,\n month: month + 1,\n regular,\n impostoDevido: data.impostoDevido,\n totalImpostoDevido: data.totalImpostoDevido,\n })\n .then((res) => {\n getYearResume(year, true, res.data.darfUrl);\n getTaxes();\n message.success(\"Dados salvos\");\n handleNavigateToHistoric();\n })\n .catch(() => message.error(errorMessage))\n .finally(() => setEmitting(false));\n };\n\n const onChangeMonth = (value: moment.Moment | null, dateString: string) => {\n const [month, year] = dateString.split(\"-\");\n setMonth(parseInt(month) - 1);\n setYear(parseInt(year));\n };\n\n const unsetAsset = () => {\n setAsset(undefined);\n };\n\n const handleCloseDeleteModal = () => {\n setShowDeleteModal(false);\n unsetAsset();\n };\n\n const handleCloseAssetModal = () => {\n setShowAssetModal(false);\n unsetAsset();\n };\n\n const onCloseHelpModal = () => {\n setHelpModal(undefined);\n };\n\n const onCloseDarfModal = () => {\n setDarfModal(undefined);\n };\n\n const handleOpenDarfModal = () => {\n setDarfModal(DarfModal(emitted, onCloseDarfModal, () => handleDarf()));\n };\n\n const handleOpenPaymentModal = () => {\n setPaymentModal(!paymentModal);\n };\n\n const handleAdd = (event: React.MouseEvent) => {\n event.stopPropagation();\n setShowAssetModal(true);\n };\n\n const handleEdit = (item: any, index: number) => {\n setShowAssetModal(true);\n setAsset({\n ...item,\n data: moment.utc(item.data.toLocaleString()).format(\"DD/MM/YYYY\"),\n dataVenda: moment\n .utc(item?.dataVenda?.toLocaleString())\n ?.format(\"DD/MM/YYYY\"),\n dataCompra: moment\n .utc(item?.dataCompra?.toLocaleString())\n ?.format(\"DD/MM/YYYY\"),\n });\n };\n\n const handleRemove = (item: any, index: number) => {\n setShowDeleteModal(true);\n setAsset(item);\n };\n\n const addAsset = (asset: any) => {\n setLoading(true);\n (currentPage?.api || apis)\n .post(`${transactionFeature.apiUrl}?manual=true`, asset, {\n headers: {\n \"x-email\": user.user.email,\n },\n })\n .then(() => {\n getTaxes();\n getYearResume(year, true);\n })\n .catch(() => message.error(errorMessage))\n .finally(() => {\n setLoading(false);\n handleCloseAssetModal();\n });\n };\n\n const editAsset = (data: any) => {\n setLoading(true);\n (currentPage?.api || apis)\n .put(`${transactionFeature.apiUrl}/${data.id}`, data)\n .then(() => {\n getTaxes();\n getYearResume(year, true);\n })\n .catch(() => message.error(errorMessage))\n .finally(() => {\n setLoading(false);\n handleCloseAssetModal();\n });\n };\n\n const removeAsset = () => {\n setLoading(true);\n (currentPage?.api || apis)\n .delete(`${transactionFeature.apiUrl}/${asset.id}`)\n .then(() => {\n getTaxes();\n getYearResume(year, true);\n })\n .catch(() => message.error(errorMessage))\n .finally(() => {\n setLoading(false);\n handleCloseDeleteModal();\n });\n };\n\n const handlePlanModal = () => {\n navigate('/planos')\n };\n\n const handleSaveMonth = async () => {\n setLoadingDarfButton(true);\n try {\n const retPlanInfo = await apiPayment.get(\"/user-plan/plan-info\");\n const hasExteriorCalcActive =\n retPlanInfo?.data?.permissions?.[\"crypto-warren\"];\n\n retPlanInfo.data.active || hasExteriorCalcActive\n ? handleDarf(true)\n : handlePlanModal();\n } catch (err) {\n console.error(err);\n }\n setLoadingDarfButton(false);\n };\n\n const handleEventDarfButton = async () => {\n setLoadingDarfButton(true);\n let retPlanInfo = {\n data: {\n active: false,\n },\n };\n try {\n retPlanInfo = await apiPayment.get(\"/user-plan/plan-info\");\n } catch (err) {\n console.error(err);\n }\n setLoadingDarfButton(false);\n\n !retPlanInfo.data.active ? handlePlanModal() : handleOpenPaymentModal();\n };\n\n const handleLabelButton: ReactNode = useMemo(() => {\n // if (!userPlanInfoStatus) return \"Assinar Plano Emissão de DARF\";\n\n if (data?.totalImpostoDevido <= maxDarfPrice) return \"Pagar DARF\";\n else {\n if (emitted) return \"Pagar DARF\";\n else return taxFeature?.buttonLabel;\n }\n }, [data?.totalImpostoDevido, emitted, taxFeature?.buttonLabel]);\n\n const downloadAction = (record: any) => {\n (currentPage?.api || apis)\n .get(`/darf/download/${record._id}`)\n .then((res) => {\n if (res.data.url) {\n download(res.data.url);\n }\n });\n };\n\n const handleNavigateToHistoric = () => {\n navigate(item.settings?.historicUrl ?? `/${currentBroker.path}/historic`, {\n state: { year },\n });\n };\n\n useEffect(() => {\n getTaxes();\n }, [getTaxes, month, year]);\n\n useEffect(() => {\n if (view && darf) {\n getDarf(darf.id);\n }\n }, [getDarf, view, darf]);\n\n useEffect(() => {\n getYearResume(year);\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n\n useEffect(() => {\n const dataToPayment = {\n ...data,\n year,\n month: month + 1,\n name: user.user.name,\n memoriaCalculo: [],\n transactions: data.memoriaCalculo,\n };\n\n setPaymentData(dataToPayment);\n }, [data.totalImpostoDevido, data, month, user.user.name, year]);\n\n const impostoCharge = useMemo(() => {\n return !view\n ? data.impostoDevido +\n data.impostoAcumulado +\n (data.impostoDevido + data.impostoAcumulado < minDarfPrice\n ? 0\n : data.multa + data.juros)\n : Math.max(\n (data.impostoDevido || 0) +\n (data.impostoAcumulado || 0) +\n ((data.impostoDevido || 0) + (data.impostoAcumulado || 0) <\n minDarfPrice\n ? 0\n : data.multa + data.juros),\n 0\n );\n }, [data, view]);\n\n return (\n \n \n \n \n \n \n \n {!view && !viewEdit && (\n <>\n {currentBroker.initialYear === year && month === 0 ? (\n
\n ) : (\n {\n if (month === 0) {\n setYear((year: number) => {\n const newYear = year - 1;\n getYearResume(newYear);\n setDatePickerYear(newYear);\n return newYear;\n });\n setMonth(11);\n } else {\n setMonth((month) => month - 1);\n }\n }}\n />\n )}\n \n )}\n {monthsExtended[month]} de {year}\n {!view && !viewEdit && (\n <>\n {currentYear === year && currentMonth - 1 === month ? (\n
\n ) : (\n {\n if (month === 11) {\n setYear((year) => {\n const newYear = year + 1;\n getYearResume(newYear);\n setDatePickerYear(newYear);\n return newYear;\n });\n setMonth(0);\n } else {\n setMonth((month) => month + 1);\n }\n }}\n />\n )}\n \n )}\n \n \n {!view && !viewEdit && (\n \n }\n defaultValue={defaultValue}\n locale={antDatePickerLocale}\n value={moment({ year: datePickerYear, month })}\n onSelect={(e) => {\n if (e.month() === month && year !== datePickerYear) {\n onChangeMonth(e, `${month + 1}-${datePickerYear}`);\n }\n }}\n onPanelChange={(e) => {\n getYearResume(e.year());\n setDatePickerYear(e.year());\n }}\n getPopupContainer={(trigger) => trigger.parentElement!}\n renderExtraFooter={() =>\n yearResumeFeature.disabled ? (\n <>\n ) : (\n \n )\n }\n disabledDate={(current) =>\n current &&\n (current > currentDate.endOf(\"month\") ||\n current < moment(`${currentBroker.initialYear}-01-01`) ||\n current < moment(`2020-01-01`))\n }\n monthCellRender={(e) => (\n \n )}\n />\n \n )}\n \n \n \n \n \n {hasPlan && view && darf?.fullPath && (\n \n \n downloadAction(darf)}\n startIcon={\n \n }\n >\n BAIXAR DARF\n \n \n \n )}\n\n
\n {!hasPlan && (\n
\n \n Contrate o plano premium para ver os impostos devidos\n \n }\n onClick={() => {\n handlePlanModal();\n closeModal?.();\n }}\n >\n PREMIUM\n \n
\n )}\n\n \n {DarfImpostosDevidosDescriptions.map((description) => (\n \n {loading ? (\n \n ) : description.render ? (\n description.render(data, view)\n ) : (\n formatCurrency(\n Number(data[description.id as keyof IDarf] || 0)\n )\n )}\n \n ))}\n \n
\n\n
\n\n \n \n Vendas realizadas no mês\n \n }\n >\n {!notAuthorized && !view && (\n }\n >\n Adicionar\n \n )}\n (\n handleEdit(item, index)}\n icon={}\n />,\n handleRemove(item, index)}\n icon={}\n />,\n ]\n }\n >\n \n \n {item.ativoTranslated\n ? item.ativoTranslated\n : item.ativo}\n \n }\n description={\n
\n
\n Data de liquidação:{\" \"}\n {moment\n .utc(item?.data?.toLocaleString())\n .format(\"DD/MM/YYYY\")}\n
\n {/*
\n Data de liquidação:{\" \"}\n \n {formatCurrency(\n item.ganho ??\n item.quantidade *\n (item.precoVenda - item.custoCompra) -\n item.taxas ??\n 0\n )}\n \n
*/}\n {item.quantidade && (\n
Quantidade: {item.quantidade}
\n )}\n {view && (\n <>\n
\n Valor de venda:{\" \"}\n \n {formatCurrency(item.precoVenda)}\n \n
\n
\n Valor de compra:{\" \"}\n \n {formatCurrency(item.custoCompra)}\n \n
\n
\n Taxas:{\" \"}\n {formatCurrency(item.taxas)}\n
\n \n )}\n
Ganho: {formatCurrency(item.ganho)}
\n
\n }\n />\n
\n \n )}\n />\n \n \n\n {hasPlan &&
}\n\n {hasPlan && (\n \n Imposto total\n \n {loading ? (\n \n ) : (\n formatCurrency(impostoCharge)\n )}\n \n
\n )}\n\n {hasPlan && (\n \n {DarfResultDescriptions.map((description, i) => (\n \n {loading ? (\n \n ) : description.Component ? (\n \n ) : (\n formatCurrency(\n Number(data[description.id as keyof IDarf] || 0)\n )\n )}\n \n ))}\n \n )}\n\n {!notAuthorized && !view && (\n <>\n \n {!(month === currentMonth && year === currentYear) &&\n (data.impostoDevido + data.impostoAcumulado ?? 0) <\n minDarfPrice &&\n data.memoriaCalculo.filter(\n (el: any) =>\n (el.operation === \"SELL\" &&\n (el.type === \"TRADE\" || el.type === \"WITHDRAW\")) ||\n el.type === \"INTEREST\"\n )?.length > 0 && (\n \n
\n \n O valor do imposto devido é menor que{\" \"}\n {formatCurrency(minDarfPrice)}. Você não precisa\n emitir um DARF para este mês.\n \n }\n >\n handleRegularize(true)}\n startIcon={emitting && }\n >\n Salvar sem emitir DARF\n \n \n \n )}\n {data.impostoDevido + data.impostoAcumulado >= minDarfPrice && (\n \n
\n target.parentElement!}\n title={\n month === currentMonth && year === currentYear\n ? \"Aguarde o encerramento do mês para pagar seu DARF\"\n : \"\"\n }\n >\n \n }\n disabled={\n loading ||\n emitting ||\n loadingDarfButton ||\n (month === currentMonth && year === currentYear)\n }\n >\n {handleLabelButton}\n {\" \"}\n \n \n )}\n \n {!(month === currentMonth && year === currentYear) && (\n \n \n }\n >\n Salvar apenas\n \n \n \n )}\n \n )}\n {!view && false && (\n <>\n setShowNotAuthorizedModal(false)}\n />\n
\n
\n

\n (1) Os cálculos de imposto de renda foram realizados levando\n em consideração somente as operações de compra e venda\n realizadas na Xtage. Caso você tenha realizado operações com\n criptoativos em outras corretoras, realize as alterações\n manualmente.\n

\n
\n
\n

\n (2) Caso você tenha realizado a transferência de custódia de\n outras corretoras de criptoativos para a Xtage, realize\n manualmente a inserção do custo médio de compra dos\n respectivos ativos transferidos.\n

\n
\n
\n

\n (3) O Usuário é exclusivamente responsável pela conferência\n e validação das informações utilizadas na apuração do\n imposto devido, conforme{\" \"}\n \n Termos e Condições Gerais de Uso.\n \n

\n
\n
\n \n )}\n \n \n\n \n {helpModal?.content}\n \n \n {darfModal?.content}\n \n \n maxPixPayment}\n disableCreditCardOption={\n data?.totalImpostoDevido > maxCreditCardPayment\n }\n onCancel={handleOpenPaymentModal}\n paymentData={{\n ...paymentData,\n impostoTotalFinal: data.totalImpostoDevido + data.impostoAcumulado,\n }}\n callDarf={() => {\n // HandleTag(\"67\");\n handleOpenDarfModal();\n }}\n maxPixValue={maxPixPayment}\n maxCCValue={maxCreditCardPayment}\n selectedYear={year}\n />\n Promise.resolve(removeAsset())}\n body=\"Você realmente quer deletar esse ativo?\"\n />\n \n );\n};\n","import styled from \"styled-components\";\n\nexport const CardContainer = styled.div`\n width: 160px;\n height: 180px;\n border-radius: 8px;\n transition: opacity 0.3s ease-in-out;\n background-color: var(--velotax-background-color);\n cursor: pointer;\n position: relative;\n box-shadow: 0px 2px 10px 0px rgba(0, 0, 0, 0.15);\n\n &.disabled {\n cursor: default;\n :before {\n content: \"Em breve!\";\n top: 6px;\n left: -6px;\n position: absolute;\n color: #000;\n width: auto;\n height: auto;\n padding: 4px 8px;\n font-size: 12px;\n font-weight: 600;\n display: flex;\n align-items: center;\n justify-content: center;\n background-color: var(--ant-primary-color);\n }\n }\n\n &,\n a,\n .MuiButtonBase-root {\n display: flex;\n align-items: flex-start;\n justify-content: flex-start;\n flex-direction: column;\n border-radius: 8px;\n }\n\n a,\n .MuiButtonBase-root {\n width: 100%;\n height: 100%;\n padding: 16px;\n }\n\n figure {\n margin: 0 0 4px;\n\n svg {\n width: 32px;\n height: 32px;\n &:not(.no-fill) {\n fill: var(--ant-primary-color);\n }\n }\n }\n\n .ant-btn.ant-btn-primary.btn-premium {\n top: 16px;\n right: -6px;\n }\n\n &#irpf {\n box-shadow: none;\n animation-name: irpf-card;\n animation-duration: 1.75s;\n animation-direction: alternate;\n animation-iteration-count: infinite;\n animation-timing-function: cubic-bezier(0.68, -0.55, 0.265, 1.55);\n }\n\n @keyframes irpf-card {\n 0% {\n box-shadow: 0px 0px 8px 4px var(--ant-primary-color-outline);\n }\n 50% {\n box-shadow: 0px 0px 1px 1px var(--ant-primary-color-outline);\n }\n 100% {\n box-shadow: 0px 0px 8px 4px var(--ant-primary-color-outline);\n }\n }\n\n .content {\n font-weight: 600;\n font-size: 0.875rem;\n line-height: 1.125rem;\n color: var(--velotax-font-color-light);\n\n .ant-typography {\n color: inherit;\n position: relative;\n text-align: left;\n text-transform: uppercase;\n\n .available-until {\n position: absolute;\n bottom: -24px;\n left: 8px;\n width: calc(100% - 16px);\n opacity: 0.8;\n font-weight: 300;\n font-size: 0.5625rem;\n letter-spacing: 0.25px;\n line-height: 11px;\n text-align: center;\n }\n }\n\n .description {\n left: 16px;\n bottom: 16px;\n position: absolute;\n opacity: 0.7;\n font-size: 13px;\n font-weight: 300;\n max-width: calc(100% - 32px);\n text-align: left;\n .ant-typography {\n text-transform: none;\n }\n\n .warning {\n transform: translateY(4px);\n color: var(--ant-warning-color);\n margin-right: 4px;\n font-size: 16px;\n }\n }\n }\n\n &.add {\n background-color: var(--velotax-background-color-ghost);\n border: 2px solid var(--velotax-background-color);\n svg {\n fill: var(--velotax-font-color-ghost);\n }\n .content {\n color: var(--velotax-font-color-ghost);\n }\n }\n`;\n","import { ReactNode } from \"react\";\nimport { ButtonBase } from \"@mui/material\";\nimport { useNavigate } from \"react-router-dom\";\nimport { CardContainer } from \"./styles\";\nimport { isMobile } from \"../../../utils\";\n\ninterface CardProps {\n id: string;\n icon: ReactNode;\n children: ReactNode;\n link?: string;\n className?: string;\n disabled?: boolean;\n onClick?: () => void;\n}\n\nconst Container: React.FC> = ({ children, link }) => {\n return link && link.includes(\"http\") ? (\n \n {children}\n \n ) : (\n <>{children}\n );\n};\n\nexport const Card = ({\n id,\n icon,\n link,\n onClick,\n children,\n disabled,\n className,\n}: CardProps) => {\n const navigate = useNavigate();\n\n const handleClick = () => {\n if (disabled) return;\n if (onClick) {\n onClick();\n } else if (link && !link.includes(\"http\")) {\n navigate(link);\n }\n };\n\n return (\n \n \n \n
{icon}
\n
{children}
\n
\n
\n
\n );\n};\n","import { Typography } from \"antd\";\nimport { GiProfit } from \"react-icons/gi\";\nimport { AiOutlineApi } from \"react-icons/ai\";\nimport { RiFileList3Line } from \"react-icons/ri\";\nimport { HiOutlineCalculator } from \"react-icons/hi\";\nimport { MdSwapVerticalCircle } from \"react-icons/md\";\nimport { isMobile } from \"../../utils\";\nimport { FaHandHoldingUsd } from \"react-icons/fa\";\n\nexport const itensBolsa = [\n {\n id: \"darf\",\n link: \"/warren/bolsa-historic\",\n content: Calculadora de DARF,\n description: Cálculo de IR e emissão de DARF,\n icon: (\n \n ),\n },\n // {\n // premium: true,\n // id: \"anual-report\",\n // link: \"/warren/bolsa-report\",\n // content: Informe de rendimentos ({YearReport}),\n // description: Relatório para declaração do IRPF,\n // icon: (\n // \n // ),\n // },\n {\n id: \"report\",\n premium: true,\n link: \"/warren/bolsa-report\",\n content: (\n \n Relatórios {!isMobile() && \"(padrão Receita Federal)\"}\n \n ),\n icon: (\n \n ),\n description: (\n Relatórios auxiliares para declaração de IR\n ),\n },\n {\n id: \"dividendos\",\n link: \"/warren/bolsa-dividendos\",\n premium: true,\n content: Dividendos,\n description: Gestão dos dividendos recebidos,\n icon: ,\n },\n {\n premium: true,\n id: \"insert-manual\",\n link: \"/warren/bolsa-insert-manual\",\n content: Posição 31/12/2019,\n icon: (\n \n ),\n },\n {\n id: \"doacoes-heranca\",\n link: \"/warren/bolsa-doacoes-heranca\",\n content: Doações e heranças,\n icon: (\n \n ),\n },\n {\n id: \"integration\",\n link: \"/warren/bolsa-integration\",\n content: Notas de corretagem,\n icon: ,\n },\n];\n","import { Typography } from \"antd\";\n// import { GiProfit } from \"react-icons/gi\";\nimport { AiOutlineApi } from \"react-icons/ai\";\n// import { RiFileList3Line } from \"react-icons/ri\";\nimport { HiOutlineCalculator } from \"react-icons/hi\";\n// import { MdSwapVerticalCircle } from \"react-icons/md\";\n// import { isMobile } from \"../../utils\";\n\nexport const itensCrypto = [\n {\n premium: false,\n id: \"darf\",\n link: \"/warren/cripto-historic\",\n content: Calculadora de DARF,\n description: Cálculo de IR e emissão de DARF,\n icon: (\n \n ),\n },\n // {\n // premium: true,\n // id: \"anual-report\",\n // link: \"/warren/bolsa-report\",\n // content: Informe de rendimentos ({YearReport}),\n // description: Relatório para declaração do IRPF,\n // icon: (\n // \n // ),\n // },\n // {\n // premium: true,\n // id: \"report\",\n // link: \"/warren/cripto-report\",\n // content: (\n // \n // Relatórios {!isMobile() && \"(padrão Receita Federal)\"}\n // \n // ),\n // icon: (\n // \n // ),\n // description: (\n // Relatórios auxiliares para declaração de IR\n // ),\n // },\n // {\n // id: \"dividendos\",\n // link: \"/warren/bolsa-dividendos\",\n // premium: true,\n // content: Dividendos,\n // description: Gestão dos dividendos recebidos,\n // icon: ,\n // },\n // {\n // premium: true,\n // id: \"insert-manual\",\n // link: \"/warren/bolsa-insert-manual\",\n // content: Posição 31/12/2019,\n // icon: (\n // \n // ),\n // },\n {\n id: \"integration\",\n premium: false,\n link: \"/warren/cripto-integration\",\n content: Notas de corretagem,\n description: Carregar notas de corretagem,\n\n icon: ,\n },\n];\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n padding: 16px;\n .ant-typography {\n text-align: center;\n color: var(--velotax-font-color);\n }\n h1 {\n font-size: 32px;\n }\n div.ant-typography {\n font-size: 18px;\n }\n @media only screen and (max-device-width: 812px) {\n h1 {\n font-size: 24px;\n }\n div.ant-typography {\n font-size: 14px;\n }\n }\n`;\n","import { Typography } from \"antd\";\nimport { Container } from \"./styles\";\n\ninterface PageInfoProps {\n title: React.ReactNode;\n subtitle?: React.ReactNode;\n}\n\nexport const PageInfo: React.FC = ({ title, subtitle }) => {\n return (\n \n {title}\n {subtitle && {subtitle}}\n \n );\n};\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n width: 100%;\n padding: 16px;\n border-radius: 8px;\n border: 1px solid var(--velotax-background-color-ghost);\n h3 {\n margin: 0;\n font-size: 16px;\n font-weight: 600;\n text-transform: uppercase;\n color: var(--velotax-font-color-ghost);\n }\n .price {\n display: flex;\n column-gap: 8px;\n align-items: center;\n justify-content: space-between;\n margin-bottom: 24px;\n h4 {\n font-size: 22px;\n margin: 8px 0 !important;\n color: var(--ant-primary-color);\n del,\n span.per-month {\n font-size: 14px;\n }\n del {\n opacity: 0.8;\n color: var(--velotax-font-color);\n }\n }\n .ant-typography-danger {\n font-size: 11px;\n text-align: right;\n max-width: 120px;\n }\n }\n .ant-divider.ant-divider-horizontal {\n margin: 16px 0;\n }\n .other-features,\n .included-features {\n .feature {\n display: flex;\n align-items: center;\n justify-content: space-between;\n span {\n font-weight: 500;\n }\n svg.fill {\n fill: var(--velotax-font-color);\n }\n svg:not(.fill) {\n stroke: var(--velotax-font-color);\n }\n &.disabled {\n opacity: 0.4;\n }\n .feature-desc {\n display: block;\n font-size: 10px;\n font-weight: 400;\n }\n }\n }\n .other-features {\n margin-bottom: 24px;\n }\n`;\n","import clsx from \"clsx\";\nimport { BiCheck, BiX } from \"react-icons/bi\";\nimport { Divider, Row, Typography } from \"antd\";\nimport Button from \"../../Button\";\nimport { Container } from \"./styles\";\nimport { formatCurrency } from \"../../../utils\";\nimport { OtherFeatures, Plan as IPlan } from \"../../../constants/plans\";\n\ninterface PlanProps {\n plan: IPlan;\n buyed: boolean;\n handleSelect: React.MouseEventHandler;\n}\n\nexport const Plan: React.FC = ({ plan, buyed, handleSelect }) => {\n return (\n \n {plan.title}\n
\n \n {formatCurrency(plan.price)} / mês\n
\n \n {formatCurrency(plan.originalPrice)}{\" \"}\n / mês\n \n
\n \n {plan.discount}% de desconto no plano anual\n \n
\n
\n {plan.includedFeatures.map((feature) => (\n
\n {feature.name}\n {feature.icon}\n
\n ))}\n
\n \n
\n {OtherFeatures.map((feature) => (\n feature.name === f.name) <\n 0,\n })}\n >\n \n {feature.name}\n {feature.desc && (\n {feature.desc}\n )}\n \n \n {plan.otherFeatures.findIndex((f) => feature.name === f.name) <\n 0 ? (\n \n ) : (\n \n )}\n \n
\n ))}\n
\n \n {!buyed ? (\n \n ) : (\n \n )}\n \n
\n );\n};","import { Col, Row } from \"antd\";\nimport Button from \"../../../../Button\";\nimport React, { Dispatch, SetStateAction } from \"react\";\n\ninterface IFooterProps {\n currentStep: number;\n handleProceed: () => void;\n setCurrentStep: Dispatch>;\n typePurchase: string;\n hideTerms: boolean;\n backtoRoot?: any;\n selectedCardId?: string;\n}\n\nconst Footer: React.FC = ({\n currentStep,\n setCurrentStep,\n handleProceed,\n typePurchase,\n hideTerms,\n selectedCardId,\n backtoRoot,\n}) => {\n return (\n <>\n {/*\n {currentStep !== 2 && !hideTerms && (\n \n \n Ao realizar o pagamento você concorda com as{\" \"}\n \n \n )} \n */}\n \n \n \n {currentStep !== 3 && currentStep !== 4 && (\n \n \n {currentStep === 1\n ? \"PROSSEGUIR\"\n : typePurchase === \"UNIQUE\"\n ? \"FINALIZAR PAGAMENTO\"\n : \"FINALIZAR COMPRA\"}\n \n \n )}\n {currentStep <= 2 && (\n \n {\n if (currentStep === 1) {\n backtoRoot();\n return;\n }\n\n setCurrentStep((step) => step - 1);\n }}\n >\n Voltar\n \n \n )}\n \n \n \n \n );\n};\n\nexport default Footer;\n","import styled from \"styled-components\";\nimport { Row } from \"antd\";\n\nexport const CardContent = styled.div`\n display: flex;\n background-color: transparent;\n align-items: center;\n width: 100%;\n justify-content: center;\n height: 115px;\n border-radius: 7px;\n margin-top: 10px;\n cursor: pointer;\n\n .full-container {\n margin: auto;\n\n .card-number {\n display: flex;\n }\n }\n`;\n\nexport const NewCardContent = styled.div`\n display: flex;\n justify-content: center;\n align-items: center;\n cursor: pointer;\n\n h3 {\n color: var(--ant-primary-color);\n }\n`;\n\nexport const Content = styled(Row)`\n margin-top: 4%;\n\n .list-cards-content {\n height: 400px;\n width: auto;\n display: grid;\n grid-template-columns: 1fr;\n overflow-y: auto;\n }\n\n .rccs {\n transform: scale(55%);\n }\n`;\n","export const taxes: Array = [\n 1.065, 1.105, 1.125, 1.145, 1.165, 1.185, 1.205, 1.225, 1.245, 1.265, 1.285,\n 1.305,\n];","import { Col, Row } from \"antd\";\nimport { taxes } from \"../constants/taxes\";\nimport { formatCurrency, numberToPercentage } from \"../utils\";\n\nexport default function getInstallments(\n value: number, // valor\n isPlan: boolean, // caso seja plano irá alterar a descrição\n fixedInstallments?: number //número de parcela fixo\n) {\n var _installments = [];\n var customInstallments = 12;\n\n if (value) {\n if (isPlan) {\n _installments.push({\n value: 12,\n label: (\n \n R$ {(value / 12).toFixed(2)}\n \n ),\n });\n } else if (fixedInstallments) {\n _installments.push({\n value: 12,\n label: (\n \n {fixedInstallments}x R${\" \"}\n {(value / fixedInstallments).toFixed(2)}\n \n ),\n });\n } else {\n\n let valorTaxa=0;\n if(value >=10 && value <=499.99){\n valorTaxa = 9.9\n }\n if(value >=500 && value <=999.99){\n valorTaxa = 14.9\n }\n if(value >=1000 && value <=1499.99){\n valorTaxa = 19.9\n }\n if(value >=1500 && value <=10000){\n valorTaxa = 29.9\n }\n\n const _valueTmp = value+valorTaxa;\n\n for (let i = 0; i < (customInstallments || 12); i++) {\n let _value = formatCurrency(((_valueTmp * taxes[i])) / (i + 1));\n let plural = i > 0 ? \"parcelas\" : \"parcela\";\n\n _installments.push({\n value: i + 1,\n label: (\n \n \n {i + 1}x {plural} - {_value.props.prefix} {_value.props.value}\n \n \n Taxa de serviço: {numberToPercentage((taxes[i] - 1) * 100)}\n \n \n ),\n });\n }\n }\n }\n\n return _installments;\n}\n","import React, { useEffect, useState, useMemo, forwardRef } from \"react\";\nimport { message, Typography, Col, Form, Row } from \"antd\";\nimport { CardContent, NewCardContent, Content } from './styles'\nimport { apiPayment } from \"../../services/apiPayment\";\nimport Cards from \"react-credit-cards\";\nimport { LoadingOutlined } from \"@ant-design/icons\";\nimport { Plan as IPlan, UserPlan } from \"../../constants/plans\";\nimport getInstallmentsByPrice from '../../utils/getInstallmentsListByPrice';\nimport { formatCurrency } from '../../utils/format';\nimport { SelectLabled } from \"../../constants/inputs\";\n\ninterface ICardList {\n onSelectCard: (card: any) => void;\n selectedCardId: string;\n amount?: string;\n plan?: IPlan | UserPlan;\n value: number;\n onChangeInstallments?: (value: number) => void;\n installmentSelected?: number;\n}\n\nexport interface cardAttributes {\n id: string;\n first_six_digits: string;\n last_four_digits: string;\n brand: string;\n customer_id: string;\n holder_name: string;\n exp_month: number;\n exp_year: number;\n status: string;\n type: string;\n created_at: Date;\n updated_at: Date;\n billing_address: {\n street: string;\n zip_code: string;\n city: string;\n state: string;\n country: string;\n line_1: string;\n };\n}\n\nexport const CardList: React.FC = ({\n onSelectCard,\n selectedCardId,\n value,\n plan,\n onChangeInstallments,\n installmentSelected\n}) => {\n const [cardList, setCardList] = useState([]);\n const [loading, setLoading] = useState(false);\n\n\n const SelectInput = forwardRef((props, ref) => (\n \n ));\n\n const getCardList = () => {\n setLoading(true);\n apiPayment.get(`/payment/list_cards`).then((ret) => {\n setCardList(ret?.data?.list || []);\n\n if (ret?.data?.list?.length === 0 || !ret?.data?.list) {\n onSelectCard(undefined);\n }\n setLoading(false);\n }).catch((err) => {\n message.error('Ocorreu um erro ao buscar cartões');\n setLoading(false);\n });\n\n };\n\n useEffect(() => {\n getCardList();\n // eslint-disable-next-line\n }, []);\n\n\n const fixedInstallments = useMemo(() => !!plan?.type ? 12 : undefined, [plan?.type])\n\n const installments = useMemo(() => getInstallmentsByPrice(value, !!plan?.type, fixedInstallments), [plan, value, fixedInstallments]);\n\n\n return (\n \n
\n {!loading &&\n <>\n \n {/* {getMessage()} */}\n \n {value ? (\n {formatCurrency(value ?? 0)}\n ) : undefined}\n\n \n \n onSelectCard(undefined)}>

Novo Cartão

\n \n \n {cardList && cardList?.length > 0 && cardList?.map((card: cardAttributes) =>\n \n onSelectCard(card)}>\n {\n console.log('cb issuer isvalid', issuer, isValid)\n }}\n />\n \n \n )}\n \n \n {value ? (\n \n \n \n \n \n ) : (\n \"\"\n )}\n \n }\n
\n );\n};\n","import { Focused } from \"react-credit-cards\";\nimport { Form, message, Spin } from \"antd\";\nimport React, {\n Dispatch,\n SetStateAction,\n useEffect,\n useState,\n useMemo,\n} from \"react\";\nimport Footer from \"./components/Footer\";\nimport { CardList } from \"../../CardList\";\nimport { CardForm } from \"./components/CardForm\";\nimport AddressForm from \"./components/AddressForm\";\nimport { apiPlan } from \"../../../services/apiPlan\";\nimport { useAuth } from \"../../../contexts/AuthContext\";\nimport { ResultScreen } from \"./components/ResultScreen\";\nimport { removeSpecialCharacters } from \"../../../utils\";\nimport { Plan as IPlan, UserPlan } from \"../../../constants/plans\";\nimport { PendingScreen } from \"./components/ResultScreen/components/PendingScreen\";\nimport { useBroker } from \"../../../contexts/BrokerContext\";\nimport { apiPayment } from \"../../../services/apiPayment\";\nimport HandleTag from \"../../../services/handleTag\";\nimport { AxiosInstance } from \"axios\";\n\nexport enum ETypePurchase {\n MEI = \"MEI\",\n UNIQUE = \"UNIQUE\",\n VELOTAX_MAIN_BASIC = \"VELOTAX_MAIN_BASIC\",\n VELOTAX_MAIN_BASIC_MONTH = \"VELOTAX_MAIN_BASIC_MONTH\",\n VELOTAX_MAIN_PRO = \"VELOTAX_MAIN_PRO\",\n VELOTAX_MAIN_PRO_MONTH = \"VELOTAX_MAIN_PRO_MONTH\",\n VELOTAX_MAIN_CONCIERGE = \"VELOTAX_MAIN_CONCIERGE\",\n}\n\ninterface ICreditCardStepProps {\n status: string;\n initialized: boolean;\n handleBack?: () => void;\n typePurchase: ETypePurchase;\n handleSuccess?: (res: any) => void;\n setInitialized: Dispatch>;\n handleClosableModal: Dispatch>;\n plan?: IPlan | UserPlan;\n darfData?: any;\n getCardCurrentStep?: (value: number) => void;\n handleIdBack?: (event: any) => void;\n customInstallments?: number;\n backToRoot?: () => void;\n cupom?: any;\n changeCardAction?: boolean;\n closeMainModal?: () => void;\n api?: AxiosInstance;\n}\n\nexport const CreditCardStep: React.FC = ({\n plan,\n api,\n handleBack,\n handleClosableModal,\n typePurchase,\n darfData,\n handleSuccess,\n handleIdBack,\n customInstallments,\n backToRoot,\n cupom,\n changeCardAction,\n closeMainModal,\n}) => {\n const [cardForm] = Form.useForm();\n const [addressForm] = Form.useForm();\n\n const { user } = useAuth();\n const [cvc, setCvc] = useState(\"\");\n const [name, setName] = useState(\"\");\n const [phone, setPhone] = useState(\"\");\n const [status, setStatus] = useState(\"\");\n const [number, setNumber] = useState(\"\");\n const [expiry, setExpiry] = useState(\"\");\n const [focused, setFocused] = useState();\n const [holderDocument, setHolderDocument] = useState(\"\");\n const [installments, setInstallments] = useState(1);\n\n const [selectedCard, setSelectedCard] = useState();\n\n const [loading, setLoading] = useState(false);\n const [currentStep, setCurrentStep] = useState(1);\n const [isValidCardForm, setIsValidCardForm] = useState(false);\n const [isValidAddressForm, setIsValidAddressForm] = useState(false);\n\n const isPlan = useMemo(() => {\n return [\n \"VELOTAX_MAIN_BASIC\",\n \"VELOTAX_MAIN_PRO\",\n \"VELOTAX_MAIN_PRO_MONTH\",\n \"VELOTAX_MAIN_CONCIERGE\",\n ].includes(plan?.type || \"\");\n }, [plan]);\n\n const value = useMemo(() => {\n if (isPlan) {\n var isMonth = (plan as any).interval === \"Mensal\";\n\n var planPrice = (!isMonth ? (plan?.price || 0) * 12 : plan?.price) || 0;\n\n if (cupom?.type === \"absolute\") {\n planPrice = planPrice - Number(cupom?.discountValue);\n } else if (cupom?.type === \"percent\") {\n planPrice = planPrice - planPrice * Number(cupom?.discountValue / 100);\n }\n\n planPrice = Number(planPrice.toFixed(2));\n\n return planPrice && isMonth ? planPrice * 12 : planPrice;\n }\n\n return darfData?.impostoTotalFinal;\n }, [\n darfData?.impostoTotalFinal,\n plan,\n isPlan,\n cupom?.discountValue,\n cupom?.type,\n ]);\n\n const { currentPage } = useBroker();\n\n const getCardInfo = () => {\n const addressInfo = addressForm.getFieldsValue();\n const monthExp = expiry?.split(\"/\")?.[0];\n const monthYear = expiry?.split(\"/\")?.[1];\n\n let cardInfo: any = {};\n\n const cardId = selectedCard?.id;\n\n if (cardId) {\n cardInfo.card_id = cardId;\n } else {\n cardInfo = {\n line_1: `${addressInfo?.neighborhood} - ${addressInfo?.street} - ${addressInfo?.number}`,\n zip_code: addressInfo?.cep?.replace(\"-\", \"\"),\n city: addressInfo?.city,\n state: addressInfo?.state.toUpperCase(),\n holder_name: removeSpecialCharacters(name),\n number,\n exp_month: monthExp,\n exp_year: monthYear,\n holderDocument,\n cvv: cvc,\n };\n }\n\n return cardInfo;\n };\n\n useEffect(() => {\n if (currentStep < 0) {\n backToRoot && backToRoot();\n }\n }, [currentStep, backToRoot]);\n\n const getCustomerInfo = () => {\n let customerInfo;\n if (selectedCard?.customer_id) {\n customerInfo = { customer_id: selectedCard?.customer_id };\n } else {\n customerInfo = {\n name: user?.user?.name,\n email: user?.user?.email,\n document: user?.user?.cpf,\n phone,\n };\n }\n\n return customerInfo;\n };\n\n const createMeiPayment = () => {\n const addressInfo = addressForm.getFieldsValue();\n\n const url = \"/payment/plan/create_payment\";\n const monthExp = expiry?.split(\"/\")?.[0];\n const monthYear = expiry?.split(\"/\")?.[1];\n\n setLoading(true);\n handleClosableModal(false);\n (currentPage?.api || apiPlan)\n .post(url, {\n type: plan?.type,\n aceitouCGV: true,\n naoPossuiPendencia: true,\n paymentForm: \"credit_card\",\n clientInfo: {\n name: user?.user?.name,\n email: user?.user?.email,\n document: user?.user?.cpf,\n phone,\n },\n cardInfo: {\n cvv: cvc,\n holderDocument,\n number: number,\n exp_year: monthYear,\n exp_month: monthExp,\n holder_name: removeSpecialCharacters(name),\n country: \"BR\",\n city: addressInfo?.city,\n state: addressInfo?.state.toUpperCase(),\n zip_code: addressInfo?.cep?.replace(\"-\", \"\"),\n line_1: `${addressInfo?.neighborhood} - ${addressInfo?.street} - ${addressInfo?.number}`,\n },\n })\n .then((res: any) => {\n setCurrentStep(2);\n if (res?.data?.status?.toLowerCase() === \"active\") {\n setStatus(\"active\");\n }\n })\n .catch((err) => {\n message.error(err.response?.data?.message);\n })\n .finally(() => {\n setLoading(false);\n handleClosableModal(true);\n });\n };\n\n const createPlanMainVelotax = () => {\n const url = \"/user-plan\";\n\n let cardInfo: any = getCardInfo();\n let clientInfo: any = getCustomerInfo();\n\n setLoading(true);\n handleClosableModal(false);\n\n apiPayment\n .post(url, {\n ...darfData,\n type: plan?.type,\n from: \"WARREN\",\n cupomCode: cupom?.cupomCode.toUpperCase(),\n paymentForm: \"credit_card\",\n installments: 12,\n cardInfo,\n clientInfo,\n acceptTerms: true,\n })\n .then((res: any) => {\n if (res.data.paymentId || res.data.paymentRecurringId) {\n handleSuccess && handleSuccess(res.data);\n if(cupom?.cupomCode.toUpperCase() === 'VELOTAXER20') {\n HandleTag('171')\n }\n }\n setCurrentStep(4);\n })\n .catch((err) => {\n message.error(err.response?.data?.message);\n })\n .finally(() => {\n setLoading(false);\n handleClosableModal(true);\n });\n };\n const createUniquePayment = () => {\n let url = \"/darf\";\n\n let cardInfo: any = getCardInfo();\n let clientInfo: any = getCustomerInfo();\n\n setLoading(true);\n handleClosableModal(false);\n\n (api || currentPage?.api || apiPlan)\n .post(url, {\n ...darfData,\n paymentForm: \"credit_card\",\n paymentInfo: {\n installments: installments,\n cardInfo: cardInfo,\n clientInfo: clientInfo,\n },\n })\n .then((res: any) => {\n if (handleIdBack) handleIdBack(res?.data);\n setCurrentStep(3);\n })\n .catch((err) => {\n message.error(err.response?.data?.message);\n })\n .finally(() => {\n setLoading(false);\n handleClosableModal(true);\n });\n };\n\n const changeCardService = async () => {\n let cardInfo: any = getCardInfo();\n\n setLoading(true);\n\n apiPayment\n .post(`/user-plan/change_signature_card`, {\n card: cardInfo,\n })\n .then((ret) => {\n message.success(\"Cartão atualizado com sucesso\");\n })\n .catch((err) => {\n message.error(\"Ocorreu um erro ao alterar cartão\");\n })\n .finally(() => {\n setLoading(false);\n closeMainModal && closeMainModal();\n });\n };\n\n const handleNextStep = () => {\n if (getConditionToDisable()) {\n if (currentStep === 1) cardForm.validateFields();\n if (currentStep === 2) addressForm.validateFields();\n message.warning(\"Preencha corretamente o formulário\");\n return;\n }\n if (currentStep === 1) {\n if (!darfData?.impostoTotalFinal) {\n HandleTag(\"57\");\n }\n setCurrentStep(2);\n } else if (currentStep === 2 || currentStep === 0) {\n if (changeCardAction) {\n changeCardService();\n } else if (typePurchase === \"MEI\") {\n createMeiPayment();\n } else if (typePurchase === \"UNIQUE\") {\n createUniquePayment();\n } else if ([\"VELOTAX_MAIN_BASIC\", \"VELOTAX_MAIN_PRO\", \"VELOTAX_MAIN_PRO_MONTH\", \"VELOTAX_MAIN_CONCIERGE\"].includes(typePurchase)) {\n createPlanMainVelotax();\n }\n }\n };\n\n const getConditionToDisable = () => {\n if (currentStep === 0 && !selectedCard?.id) return true;\n if (currentStep === 1 && !isValidCardForm) return true;\n if (currentStep === 2 && !isValidAddressForm) return true;\n return false;\n };\n\n const changeInstallments = (value: any) => {\n setInstallments(value);\n };\n\n return (\n
\n \n {currentStep === 0 && (\n <>\n {\n setSelectedCard(card);\n\n if (!card) setCurrentStep(1);\n }}\n />\n \n )}\n\n {currentStep === 1 && (\n <>\n
\n \n \n )}\n\n {currentStep === 2 && (\n <>\n
\n \n \n )}\n\n {currentStep === 3 && (\n \n )}\n\n {currentStep === 4 && }\n \n
\n
\n );\n};\n\nexport default CreditCardStep;\n","import Payment from \"payment\";\nimport Masked from \"react-input-mask\";\nimport { TextField } from \"@mui/material\";\nimport { Focused } from \"react-credit-cards\";\nimport NumberFormat from \"react-number-format\";\nimport React, { forwardRef, useMemo } from \"react\";\nimport { Col, Form, FormInstance, Row } from \"antd\";\nimport { SelectLabled } from \"../../../../../constants/inputs\";\nimport getInstallmentsListByPrice from \"../../../../../utils/getInstallmentsListByPrice\";\nimport { cpfInputMask, getMuiInputCss } from \"../../../../../utils\";\nimport {\n validationAmexCVV,\n validationCardShelfLife,\n validationCpf,\n validationCreditCardNumber,\n validationCVV,\n validationFieldRequired,\n validationPhoneRequired,\n} from \"../../../../../utils/formValidations\";\n\ninterface ICardFormProps {\n number: string;\n focused?: Focused;\n form: FormInstance;\n uniqueValue?: number;\n setCvc: (cvc: string) => void;\n setName: (name: string) => void;\n setPhone: (value: string) => void;\n setNumber: (number: string) => void;\n setExpiry: (expiry: string) => void;\n setFocused: (focused: Focused) => void;\n setHolderDocument: (value: string) => void;\n setIsValidCardForm: (isValidCardForm: boolean) => void;\n handleBack: (event: any) => void;\n fixedInstallments?: number;\n signature?: boolean;\n installmentSelected?: number;\n customInstallments?: number;\n addInfo?: Record;\n}\n\nconst CreditCardNumber = forwardRef((props, ref) => (\n \n));\n\nconst CreditCardNumberDiner = forwardRef((props, ref) => (\n \n));\n\nconst CreditCardNumberAmex = forwardRef((props, ref) => (\n \n));\n\nconst ExpiryInput = forwardRef((props, ref) => (\n \n));\n\nconst PhoneInput = forwardRef((props, ref) => (\n \n));\n\nconst CPFInput = forwardRef((props, ref) => (\n \n));\n\nconst CVVAmexInput = forwardRef((props, ref) => (\n \n));\n\nconst CVVInput = forwardRef((props, ref) => (\n \n));\n\nexport const CardForm: React.FC = ({\n form,\n number,\n setCvc,\n setName,\n setPhone,\n setNumber,\n setExpiry,\n setFocused,\n setHolderDocument,\n setIsValidCardForm,\n uniqueValue,\n fixedInstallments,\n handleBack,\n signature,\n installmentSelected,\n customInstallments,\n addInfo\n}) => {\n const cardType = useMemo(() => Payment.fns.cardType(number), [number]);\n\n let installments = useMemo(\n () =>\n getInstallmentsListByPrice(\n uniqueValue || 0,\n !!signature,\n fixedInstallments\n ),\n [signature, fixedInstallments, uniqueValue]\n );\n\n const onValuesChange = (changed: any, values: any) => {\n setCvc(values.cvv ?? \"\");\n setExpiry(values.expiry ?? \"\");\n setName(values.holderName ?? \"\");\n setHolderDocument(values.cpf?.replace(/[_.-]/g, \"\") ?? \"\");\n setPhone(values.phone?.replace(/[()_-]/g, \"\").replace(\" \", \"\") ?? \"\");\n const key = Object.keys(changed)[0];\n setFocused(\n (key === \"holderName\" ? \"name\" : key === \"cvv\" ? \"cvc\" : key) as Focused\n );\n form.setFieldsValue({\n ...values,\n cpf: values.cpf?.replace(/[_.-]/g, \"\") ?? \"\",\n phone: values.phone?.replace(/[()_-]/g, \"\").replace(\" \", \"\") ?? \"\",\n });\n\n setTimeout(() => {\n form\n .validateFields()\n .then(() => setIsValidCardForm(true))\n .catch(() => setIsValidCardForm(false));\n }, 500);\n };\n\n const SelectInput = forwardRef((props, ref) => (\n \n ));\n\n return (\n <>\n \n \n \n \n {\n (e.target as HTMLElement).setAttribute(\"pasted\", \"true\");\n const value = e.clipboardData.getData(\"text/plain\");\n setNumber(value);\n }}\n onChange={(e) => {\n if ((e.target as HTMLElement).getAttribute(\"pasted\")) {\n (e.target as HTMLElement).removeAttribute(\"pasted\");\n } else {\n setNumber(e.target.value);\n }\n }}\n InputProps={{\n inputComponent: (cardType === \"dinersclub\"\n ? CreditCardNumberDiner\n : cardType === \"amex\"\n ? CreditCardNumberAmex\n : CreditCardNumber) as any,\n }}\n />\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n {uniqueValue && !addInfo?.isPlan ? (\n \n \n \n \n \n ) : (\n \"\"\n )}\n \n \n \n );\n};\n","import axios from \"axios\";\n\nconst cep = axios.create({\n method: \"GET\",\n baseURL: \"https://viacep.com.br/ws/\",\n});\n\nexport default cep;\n","import React, { forwardRef } from \"react\";\nimport { TextField } from \"@mui/material\";\nimport NumberFormat from \"react-number-format\";\nimport { Col, Form, FormInstance, Row } from \"antd\";\nimport cep from \"../../../../../services/cep\";\nimport { getMuiInputCss } from \"../../../../../utils\";\nimport {\n validationCep,\n validationFieldRequired,\n validationStateAddress,\n} from \"../../../../../utils/formValidations\";\n\ninterface IAddressFormProps {\n form: FormInstance;\n setLoading: (loading: boolean) => void;\n setIsValidAddressForm: (isValidAddressForm: boolean) => void;\n}\n\nconst AddressForm: React.FC = ({\n form,\n setLoading,\n setIsValidAddressForm,\n}) => {\n const getAddressSuggestion = (value: string) => {\n if (value?.length === 8) {\n setLoading(true);\n cep\n .get(`${value}/json`)\n .then((res) => {\n const data = res.data;\n\n if (data.cep) {\n form.setFieldsValue({\n street: data.logradouro,\n neighborhood: data.bairro,\n city: data.localidade,\n state: data.uf,\n });\n } else {\n throw Error();\n }\n })\n .catch(() => {\n form.setFieldsValue({\n street: undefined,\n neighborhood: undefined,\n city: undefined,\n state: undefined,\n number: undefined,\n });\n })\n .finally(() => {\n onFieldsChange();\n setLoading(false);\n });\n }\n };\n\n const onFieldsChange = () => {\n form\n .validateFields()\n .then(() => setIsValidAddressForm(true))\n .catch(() => setIsValidAddressForm(false));\n };\n\n const CEPInput = forwardRef((props, ref) => (\n getAddressSuggestion(value?.value)}\n >\n ));\n\n return (\n <>\n \n \n \n \n \n \n \n \n \n \n \n \n \n\n \n \n \n \n \n \n \n \n \n \n \n \n\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n );\n};\n\nexport default AddressForm;\n","import React from \"react\";\nimport { BiErrorAlt } from \"react-icons/bi\";\nimport { Col, Row, Typography } from \"antd\";\nimport Button from \"../../../../../../Button\";\n\ninterface IErrorScreenProps {\n setCurrentStep: (currentStep: number) => void;\n}\n\nexport const ErrorScreen: React.FC = ({\n setCurrentStep,\n}) => {\n const callBack = (cb: Function) => {\n setCurrentStep(0);\n setTimeout(() => cb(), 200);\n };\n\n return (\n \n \n \n \n\n \n \n Ocorreu um erro durante a confirmação do pagamento.\n \n \n\n {\n callBack(() => {});\n }}\n >\n Escolher outra forma de pagamento\n \n \n );\n};\n","import React, { useEffect } from \"react\";\nimport { MdCheck } from \"react-icons/md\";\nimport { Col, Row, Typography } from \"antd\";\nimport { Plan } from \"../../../../../../../constants/plans\";\nimport { useAuth } from \"../../../../../../../contexts/AuthContext\";\nimport { useBroker } from \"../../../../../../../contexts/BrokerContext\";\n\ninterface ConfirmedScreenProps {\n plan?: Plan;\n}\n\nexport const ConfirmedScreen: React.FC = ({ plan }) => {\n const {\n user: { token },\n } = useAuth();\n const { getIntegrationStatus } = useBroker();\n\n useEffect(() => {\n getIntegrationStatus({ token, hideLoading: true });\n }, [getIntegrationStatus, token]);\n\n return (\n \n \n \n \n \n \n {plan\n ? `Pagamento confirmado com sucesso! Parabéns você contratou o plano '\n ${plan?.title.toUpperCase()}'`\n : \"Pagamento realizado com sucesso!\"}\n \n \n \n );\n};\n","import React, { Dispatch, SetStateAction } from \"react\";\nimport { Plan } from \"../../../../../constants/plans\";\nimport { ErrorScreen } from \"./components/ErrorScreen\";\nimport { ConfirmedScreen } from \"./components/ConfirmScreen\";\n\ninterface IResultScreen {\n plan?: Plan;\n setCurrentStep: Dispatch>;\n status?: string;\n}\n\nexport const ResultScreen: React.FC = ({\n plan,\n setCurrentStep,\n status = \"pending\",\n}) => {\n return (\n <>\n {status === \"active\" ? (\n \n ) : (\n \n )}\n \n );\n};\n","import React from \"react\";\nimport { Col, Row, Typography } from \"antd\";\nimport { BsClockHistory } from \"react-icons/bs\";\n\ninterface IPendingScreenProps {}\n\nexport const PendingScreen: React.FC = () => {\n const getMessage = () =>\n \"Aguardando confirmação de pagamento no cartão, assim que confirmado o plano será ativado automaticamente.\";\n\n return (\n \n \n \n \n\n \n \n {getMessage()}\n \n \n \n );\n};\n","import { Form, Select } from \"antd\";\nimport React, { KeyboardEvent } from \"react\";\nimport ReactInputMask from \"react-input-mask\";\nimport { cnpjInputMask, isValidCNPJ } from \"../../utils\";\nimport {\n validationCnpj,\n validationFieldRequired,\n} from \"../../utils/formValidations\";\n\nexport enum MEIAtividadePrincipalEnum {\n SERVICO = \"Serviço\",\n COMERCIO_INDUSTRIA = \"Comércio e Indústria\",\n // COMERCIO_SERVICOS = \"Comércio e Serviços\",\n}\n\nexport const MEIAtividadePrincipalValue: {\n [key: number]: MEIAtividadePrincipalEnum;\n} = {\n 61.6: MEIAtividadePrincipalEnum.COMERCIO_INDUSTRIA,\n 65.6: MEIAtividadePrincipalEnum.SERVICO,\n // 66.6: MEIAtividadePrincipalEnum.COMERCIO_SERVICOS,\n};\n\nexport interface IdentificationData {\n companyCode: string;\n mainActivity: MEIAtividadePrincipalEnum;\n}\n\nexport const isValidAtividadePrincipal = (value: string) =>\n Object.values(MEIAtividadePrincipalEnum).includes(\n value as MEIAtividadePrincipalEnum\n );\n\nexport const validateIdentification = (data: IdentificationData) =>\n isValidCNPJ(data.companyCode) && isValidAtividadePrincipal(data.mainActivity);\n\ninterface Question {\n id: string;\n title: React.ReactNode;\n formItems: { name: string; FormItem: React.FC<{ tabIndex?: number }> }[];\n}\n\nexport const identificationQuestions: Question[] = [\n {\n id: \"companyCode\",\n title: \"Qual é o CNPJ do seu MEI?\",\n formItems: [\n {\n name: \"companyCode\",\n FormItem: ({ tabIndex }) => (\n \n \n \n ),\n },\n ],\n },\n {\n id: \"mainActivity\",\n title: \"Qual é a atividade principal do seu MEI?\",\n formItems: [\n {\n name: \"mainActivity\",\n FormItem: ({ tabIndex }) => (\n \n ) => {\n if (event.key === \"Enter\") {\n event.stopPropagation();\n }\n }}\n >\n \n {MEIAtividadePrincipalEnum.SERVICO}\n \n \n {MEIAtividadePrincipalEnum.COMERCIO_INDUSTRIA}\n \n \n \n ),\n },\n ],\n },\n];\n","import { useState } from \"react\";\nimport { ModalProps } from \"antd\";\nimport { LoadingOutlined } from \"@ant-design/icons\";\nimport { Plan } from \"./Plan\";\nimport { useBroker } from \"../../contexts/BrokerContext\";\nimport { Content, PlanModalStyled, Loading } from \"./styles\";\nimport { Plans, Plan as IPlan } from \"../../constants/plans\";\nimport CreditCardStep, { ETypePurchase } from \"../Payment/CreditCardStep\";\n\ninterface PlanModalProps extends ModalProps {\n modalPlans?: IPlan[];\n}\n\nexport const PlanModal: React.FC = ({\n title,\n modalPlans,\n onCancel,\n ...rest\n}) => {\n const {\n integration: { plans },\n } = useBroker();\n\n const [plan, setPlan] = useState();\n const [loading, setLoading] = useState(false);\n const [closable, setClosable] = useState(true);\n\n const handleSelectPlan = (plan?: IPlan) => {\n setLoading(true);\n setTimeout(() => {\n setPlan(plan);\n setLoading(false);\n }, 500);\n };\n\n const handleDeselectPlan = () => {\n setPlan(undefined);\n };\n\n return (\n {\n handleDeselectPlan();\n onCancel?.(e);\n }}\n {...rest}\n >\n \n {loading && (\n \n \n \n )}\n {!plan ? (\n (modalPlans || Plans).map((plan) => (\n handleSelectPlan(plan)}\n buyed={\n (plans?.name === plan.type && plans.status === \"active\") ??\n false\n }\n />\n ))\n ) : (\n {}}\n setInitialized={() => {}}\n getCardCurrentStep={(value: number) => {}}\n />\n )}\n \n \n );\n};\n","import { Modal } from \"antd\";\nimport styled from \"styled-components\";\n\nexport const Container = styled.div`\n padding: 0 32px 128px;\n @media only screen and (max-device-width: 812px) {\n padding: 0 16px 128px;\n }\n`;\n\nexport const Content = styled.div`\n padding: 32px;\n margin: 0 auto;\n max-width: 600px;\n border-radius: 16px;\n background-color: var(--velotax-background-color);\n h1 {\n margin: 0 0 8px;\n font-size: 20px;\n color: var(--velotax-font-color);\n }\n h2 {\n margin: 0;\n font-size: 16px;\n font-weight: 400;\n color: var(--velotax-font-color);\n }\n .ant-list.ant-list-split {\n margin: 24px 0 0;\n padding: 0 16px;\n background-color: var(--velotax-ghost);\n border: 1px solid var(--velotax-ghost);\n border-radius: 8px;\n .ant-list-item-action > li {\n padding: 0;\n button {\n margin: 0 auto;\n }\n }\n .ant-list-item-meta-description {\n opacity: 0.75;\n }\n .ant-list-item-action > li,\n .ant-list-item-meta-title,\n .ant-list-item-meta-description {\n color: var(--velotax-font-color);\n }\n .ant-list-item-action-split {\n opacity: 0;\n }\n }\n @media only screen and (max-device-width: 812px) {\n padding: 24px;\n .ant-list.ant-list-split {\n .ant-list-item-action {\n display: grid;\n align-items: end;\n grid-template-rows: 1fr 0.75fr;\n grid-template-columns: 1fr 1fr;\n }\n }\n }\n`;\n\nexport const ConfirmModal = styled(Modal)`\n .p {\n font-size: 16px;\n strong {\n font-weight: 500;\n color: var(--ant-primary-color);\n }\n }\n`;\n","import { Tag } from \"antd\";\nimport styled from \"styled-components\";\n\nexport const Container = styled.div`\n display: flex;\n column-gap: 8px;\n`;\n\nexport const StyledTag = styled(Tag)`\n margin: 0;\n height: 32px;\n border-radius: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n cursor: default;\n font-size: 12px;\n font-weight: 500;\n`;\n","import { Divider, Typography } from \"antd\";\nimport { InfoCircleOutlined } from \"@ant-design/icons\";\n\nexport enum MeiReportDasStatusEnum {\n EMITTED = \"EMITTED\",\n REQUESTED = \"REQUESTED\",\n}\n\nexport enum MeiReportStatusTextEnum {\n EMITTED = \"Emitido\",\n REQUESTED = \"Solicitado\",\n}\n\nexport enum MeiDasStatusTextEnum {\n EMITTED = \"Guia Emitida\",\n REQUESTED = \"Guia Solicitada\",\n}\n\nexport enum MeiDasStatusColorEnum {\n EMITTED = \"var(--ant-success-color)\",\n REQUESTED = \"var(--ant-primary-color)\",\n}\n\nexport const DasHelpModal = {\n title: \"Lista de guias MEI (DAS)\",\n content: (\n
\n \n Confirme manualmente sempre que um DAS for pago com sucesso. Esta\n funcionalidade te ajuda a manter o controle dos seus pagamentos\n realizados.\n \n \n \n \n   Atenção: a confirmação de pagamento é feita manualmente pelo\n usuário. O Velotax não realiza este monitoramento automaticamente.\n \n
\n ),\n};\n","import { Col, Row, Typography } from \"antd\";\nimport { ExteriorModalContainer } from \"./styles\";\nimport { formatCurrency, replaceDotByComma } from \"../../../utils\";\n\nexport enum ExteriorOperationType {\n TRADE = \"TRADE\",\n DEPOSIT = \"DEPOSIT\",\n WITHDRAW = \"WITHDRAW\",\n}\n\ninterface ExteriorModalContentProps {\n asset: any;\n}\n\nexport const InterestModal = ({ asset }: ExteriorModalContentProps) => {\n return (\n \n \n \n \n {asset.type === \"DIVIDEND\" ? \"Dividendos\" : \"Juros\"} recebidos\n \n \n Valor bruto:\n \n {formatCurrency(asset.valor, \"US$ \")}\n \n Taxa de corretagem:\n \n {formatCurrency(asset.fee, \"US$ \")}\n \n Data de liquidação:\n \n {asset.data}\n \n Cotação dólar:\n \n {replaceDotByComma(asset.cambioVenda)}\n \n \n
\n Rendimento total:   \n {formatCurrency(asset.rendimentoAplicacao)}\n
\n \n
\n
\n );\n};\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n padding: 64px 32px 128px;\n\n .errorCard {\n display: flex;\n flex-direction: column;\n justify-content: center;\n background-color: var(--ant-primary-1);\n height: 150px;\n margin-top: 35px;\n border-radius: 16px;\n border: 1px solid var(--ant-primary-color);\n padding-left: 30px;\n\n .errorTitle {\n color: #000;\n font-weight: 600;\n font-size: 18px;\n }\n\n .errorText {\n color: #000;\n }\n }\n\n h1 {\n width: 700px;\n margin: 0 auto 1.5rem;\n font-weight: 400;\n font-size: 2rem;\n position: relative;\n line-height: 2.5rem;\n padding-bottom: 1rem;\n color: var(--velotax-font-color-light);\n\n :after {\n content: \"\";\n position: absolute;\n left: 0;\n bottom: 0;\n height: 2px;\n width: 100px;\n background-color: var(--ant-primary-color);\n }\n }\n\n h2.ant-typography {\n display: flex;\n align-items: center;\n column-gap: 8px;\n width: 700px;\n margin: 0 auto 1.5rem;\n font-size: 1rem;\n font-weight: 400;\n line-height: 1.5rem;\n color: var(--velotax-font-color-light);\n\n &.info {\n align-items: flex-start;\n font-size: 0.875rem;\n line-height: 1.125rem;\n opacity: 0.85;\n margin: 0 auto 2.5rem;\n svg {\n margin-top: 4px;\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n padding: 0;\n\n h1 {\n width: calc(100% - 48px);\n margin: 0 24px 1.5rem;\n padding: 24px 0 1rem;\n }\n\n h2.ant-typography {\n width: 100%;\n margin: 0 auto 1.5rem;\n padding: 0 24px;\n }\n }\n`;\n\nexport const Content = styled.div`\n padding: 32px;\n margin: 0 auto;\n width: 700px;\n border-radius: 4px;\n background-color: var(--velotax-background-color);\n h1 {\n margin: 0 0 8px;\n font-size: 20px;\n color: var(--velotax-font-color);\n }\n h2 {\n margin: 0;\n font-size: 16px;\n font-weight: 400;\n color: var(--velotax-font-color);\n }\n @media only screen and (max-device-width: 812px) {\n padding: 24px 24px;\n border-radius: 0;\n width: 100%;\n .ant-list.ant-list-split {\n .ant-list-item-action {\n display: grid;\n align-items: end;\n grid-template-rows: 1fr 0.75fr;\n grid-template-columns: 1fr 1fr;\n }\n }\n }\n\n .monthError {\n text-align: center;\n .warning {\n transform: translateY(2px);\n color: var(--ant-warning-color);\n margin-right: 6px;\n font-size: 16px;\n }\n }\n`;\n\nexport const TitleContainer = styled.div`\n width: 100%;\n display: flex;\n align-items: center;\n justify-content: space-between;\n`","import styled from \"styled-components\";\n\nexport const ExteriorModalContainer = styled.div`\n font-size: 1rem;\n color: var(--velotax-font-color-dark);\n\n strong {\n font-weight: 600;\n }\n\n .exterior-capital-gain {\n padding: 8px;\n margin: 24px auto;\n text-align: center;\n background-color: #eee;\n }\n`;\n","import { Col, Row, Typography } from \"antd\";\nimport { ExteriorModalContainer } from \"./styles\";\nimport { formatCurrency, replaceDotByComma } from \"../../../utils\";\n\nexport enum ExteriorOperationType {\n TRADE = \"TRADE\",\n DEPOSIT = \"DEPOSIT\",\n WITHDRAW = \"WITHDRAW\",\n}\n\ninterface ExteriorModalContentProps {\n asset: any;\n}\n\nexport const ExteriorModalContent = ({ asset }: ExteriorModalContentProps) => {\n return (\n \n \n \n Quantidade: {asset.quantidade}\n \n \n \n {asset.type === ExteriorOperationType.TRADE\n ? \"Compra\"\n : asset.type === ExteriorOperationType.DEPOSIT\n ? \"Depósito\"\n : asset.type === ExteriorOperationType.WITHDRAW\n ? \"Resgate\"\n : \"Compra\"}\n \n \n Origem BRA:\n \n {formatCurrency(asset.valueOriginBRA, \"US$ \")}\n \n Origem USA:\n \n {formatCurrency(asset.valueOriginEUA, \"US$ \")}\n \n {asset.type === ExteriorOperationType.TRADE && (\n \n \n Venda\n \n \n )}\n {asset.type === ExteriorOperationType.TRADE && (\n <>\n Valor bruto:\n \n {formatCurrency(asset.valor, \"US$ \")}\n \n \n )}\n Taxa de corretagem:\n \n {formatCurrency(asset.fee, \"US$ \")}\n \n Data de liquidação:\n \n {asset.data}\n \n Cotação dólar:\n \n {replaceDotByComma(asset.cambioVenda)}\n \n {(asset.type === ExteriorOperationType.DEPOSIT ||\n asset.type === ExteriorOperationType.WITHDRAW) && (\n <>\n Cotação dólar Referência:\n \n {replaceDotByComma(asset.cambioReferencia.toFixed(4))}\n \n \n )}\n \n
\n Ganho de capital:   \n {formatCurrency(asset.type === \"INTEREST\" ? asset.ganho2 : asset.ganho)}\n
\n \n
\n
\n );\n};\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n margin: 0 auto;\n width: 700px;\n\n button {\n padding-left: 0px !important;\n padding-right: 0px !important;\n min-width: auto;\n }\n\n &.darf-bolsa,\n &.darf-exterior,\n &.historic-bolsa,\n &.integration-exterior,\n &.historic-exterior {\n margin-top: 24px;\n }\n\n &.dividendos-exterior {\n margin-top: -24px;\n }\n\n @media only screen and (max-device-width: 812px) {\n width: 100%;\n &.darf-bolsa,\n &.report-bolsa,\n &.dividendos-exterior,\n &.report-exterior,\n &.darf-exterior {\n padding: 0 24px;\n }\n }\n`;\n","import { Button } from \"@mui/material\";\nimport { useNavigate } from \"react-router-dom\";\nimport { Container } from \"./styles\";\n\ninterface BackButtonProps {\n to: string;\n className?: string;\n}\n\nexport const BackButton: React.FC = ({ to, className }) => {\n const navigate = useNavigate();\n return (\n \n {\n navigate(to);\n }}\n >\n Voltar\n \n \n );\n};\n","import styled from \"styled-components\";\n\nexport const ExteriorModalContainer = styled.div`\n font-size: 1rem;\n color: var(--velotax-font-color-dark);\n\n strong {\n font-weight: 600;\n }\n\n .exterior-capital-gain {\n padding: 8px;\n margin: 24px auto;\n text-align: center;\n background-color: #eee;\n }\n`;\n","import { Table } from \"antd\";\nimport { IoMdOptions } from \"react-icons/io\";\nimport Button from \"../../../components/Button\";\nimport { monthsExtended } from \"../../../utils\";\nimport { DrawerModal } from \"../../../components/DrawerModal\";\nimport { useB3Integration } from \"../../../contexts/B3IntegrationContext\";\n\nconst initialYear = 2020;\n\nexport const dayFilters: Array = [];\nfor (let d = 1; d <= 31; d++) {\n dayFilters.push({\n text: d.toString(),\n value: d,\n });\n}\n\nconst yearFilters = Array.from(\n Array(new Date().getFullYear() + 1 - initialYear)\n)\n .map((y, i) => ({ value: initialYear + i, text: `${initialYear + i}` }))\n .reverse();\n\ninterface NotasHistoricoModalProps {\n crypto?: boolean;\n}\n\nexport const NotasHistoricoModal: React.FC = ({\n crypto,\n}) => {\n const {\n notas: {\n downloadNotaCorretagem,\n historicoNotasCorretagem,\n getHistoricoNotasCorretagem,\n setHistoricoNotasCorretagem,\n loadingHistoricoNotasCorretagem,\n showHistoricoNotasCorretagemModal,\n setShowHistoricoNotasCorretagemModal,\n },\n } = useB3Integration();\n\n return (\n {\n setShowHistoricoNotasCorretagemModal(false);\n setHistoricoNotasCorretagem([]);\n }}\n >\n {\n getHistoricoNotasCorretagem({ filters, crypto });\n }}\n locale={{\n filterReset: \"Limpar\",\n }}\n columns={[\n {\n align: \"center\",\n title: \"Dia\",\n dataIndex: \"day\",\n filterIcon: ,\n filters: dayFilters,\n render: (status, item) => <>{status},\n },\n {\n align: \"center\",\n title: \"Mês\",\n dataIndex: \"month\",\n filterIcon: ,\n filters: monthsExtended.map((m, i) => ({\n text: m,\n value: i + 1,\n })),\n render: (status, item) => <>{status},\n },\n {\n align: \"center\",\n title: \"Ano\",\n dataIndex: \"year\",\n filterIcon: ,\n filters: yearFilters,\n render: (status, item) => <>{status},\n },\n {\n className: \"actionColumn\",\n render: (status, item) => (\n \n downloadNotaCorretagem(\n item.path,\n item.month,\n item.year,\n crypto\n )\n }\n >\n Ver nota\n \n ),\n },\n ]}\n />\n \n );\n};\n","import clsx from \"clsx\";\nimport moment from \"moment\";\nimport { Button } from \"@mui/material\";\nimport { FaRegEdit } from \"react-icons/fa\";\nimport { useLocation, useNavigate } from \"react-router-dom\";\nimport { BiChevronLeft, BiChevronRight } from \"react-icons/bi\";\nimport { AiOutlineDelete, AiOutlineLock } from \"react-icons/ai\";\nimport { BsCalendar3, BsDownload, BsEye } from \"react-icons/bs\";\nimport { LoadingOutlined, PlusOutlined } from \"@ant-design/icons\";\nimport { useCallback, useEffect, useMemo, useState, ReactNode } from \"react\";\nimport {\n Col,\n Collapse,\n DatePicker,\n Descriptions,\n List,\n message,\n Modal,\n Row,\n Skeleton,\n Space,\n Spin,\n Tooltip,\n Typography,\n} from \"antd\";\nimport { Page } from \"../../constants/brokers\";\nimport AntButton from \"../../components/Button\";\nimport HandleTag from \"../../services/handleTag\";\nimport { Container, Content } from \"../Darf/styles\";\nimport { useAuth } from \"../../contexts/AuthContext\";\nimport { FormModal } from \"../../components/FormModal\";\nimport { apiPayment } from \"../../services/apiPayment\";\nimport { InterestModal } from \"./InterestModalContent\";\nimport { useBroker } from \"../../contexts/BrokerContext\";\nimport { BackButton } from \"../../components/BackButton\";\nimport apis, { NOT_AUTHORIZED } from \"../../services/apis\";\nimport { PaymentModal } from \"../../components/PaymentModal\";\nimport { ExteriorModalContent } from \"./ExteriorModalContent\";\nimport { IntegrationModal } from \"../Darf/Components/IntegrationModal\";\nimport DeleteConfirmationModal from \"../../components/DeleteConfirmationModal\";\nimport { DatePickerExtraFooter } from \"../Darf/Components/DatePickerExtraFooter\";\nimport {\n DatePickerMonthCell,\n YearResume,\n} from \"../Darf/Components/DatePickerMonthCell\";\nimport {\n antDatePickerLocale,\n download,\n errorMessage,\n formatCurrency,\n isMobile,\n monthsExtended,\n numberToPercentageWallet,\n} from \"../../utils\";\nimport {\n DarfResultDescriptionsExterior,\n ExteriorFormItemRows,\n defaultDarf,\n DarfModal,\n IDarf,\n DarfImpostosDevidosDescriptions,\n minDarfPrice,\n maxDarfPrice,\n YearResumeStatusFromBackEnum,\n IQuotes,\n historicoVendasEmptyText,\n maxPixPayment,\n maxCreditCardPayment,\n yearConfigPL4173,\n ExteriorNewFormItemRows,\n} from \"../../constants/darf\";\nimport { CurrencyFormItem } from \"../../constants/formItems\";\nimport { useDarfExterior } from \"./useDarfExterior\";\n\ninterface DarfProps {\n item: Page;\n view?: boolean;\n viewEdit?: boolean;\n closeModal?: () => void;\n darf?: {\n id: string;\n fullPath?: string;\n };\n date?: {\n year?: number;\n month?: number;\n };\n selectedYear?: number;\n}\n\nconst PrejuFormItems = {\n userPrejuizoExterior: (disabled: boolean) =>\n CurrencyFormItem({\n disabled,\n name: \"prejuizoExterior\",\n label: \"Prejuízo Exterior\",\n }),\n};\n\nexport const PrejuFormItemRows = (disabled: boolean) => [\n [PrejuFormItems.userPrejuizoExterior(disabled)],\n];\n\nexport const DarfExterior: React.FC = ({\n view,\n item,\n date,\n darf,\n viewEdit,\n closeModal,\n selectedYear\n}) => {\n const { state } = useLocation();\n const { currentBroker, currentPage } = useBroker();\n const [openPrejuizoModal, setOpenPrejuizoModal] = useState(false);\n const navigate = useNavigate()\n const { user, hasPlan: hasPremiunPlan, hasPermissionExterior, hasPermissionGeneral } = useAuth();\n const { getBuyPrice, getFee, getGain, getSellPrice } = useDarfExterior()\n\n const today = new Date();\n const queryYear = (state as any)?.year as number;\n const queryMonth = (state as any)?.month as number;\n const currentMonth = today.getMonth();\n const currentYear = today.getFullYear();\n const initialMonth = queryMonth\n ? queryMonth - 1\n : today.getMonth() - 1 >= 0\n ? today.getMonth() - 1\n : 11;\n const initialYear = queryYear\n ? queryYear\n : today.getMonth() - 1 >= 0\n ? today.getFullYear()\n : today.getFullYear() - 1;\n const defaultValue = moment({ month: initialMonth, year: initialYear });\n const currentDate = moment({\n month: currentMonth,\n year: currentYear,\n }).subtract(1, \"M\");\n window.history.replaceState({}, document.title);\n\n const year = date?.year ?? initialYear;\n const month = date?.month ?? initialMonth;\n const oldModel = year < yearConfigPL4173;\n const currentDarfDate = new Date(year, month, 15)\n const dateAllowedOnBasic = new Date(today.getFullYear(), today.getMonth() - 1, 1)\n const hideOnBasic = (currentDarfDate.getTime() < dateAllowedOnBasic.getTime() && user.user?.userPlanInfoVelotax?.type?.includes('BASIC'))\n const hasPlan = (hasPremiunPlan || hasPermissionExterior || hasPermissionGeneral) && !hideOnBasic;\n\n const [asset, setAsset] = useState();\n const [loading, setLoading] = useState(false);\n const [, setYear] = useState(initialYear);\n const [, setMonth] = useState(initialMonth);\n const [emitting, setEmitting] = useState(false);\n const [darfModal, setDarfModal] = useState();\n const [helpModal, setHelpModal] = useState();\n const [data, setData] = useState(defaultDarf);\n const [paymentModal, setPaymentModal] = useState(false);\n const [paymentData, setPaymentData] = useState();\n const [quotations, setQuotations] = useState({});\n const [notAuthorized, setNotAuthorized] = useState(false);\n const [movimentType, setMovimentType] = useState(\"Venda de ativos\");\n const [showAssetModal, setShowAssetModal] = useState(false);\n const [showDeleteModal, setShowDeleteModal] = useState(false);\n const [yearResume, setYearResume] = useState([]);\n const [datePickerYear, setDatePickerYear] = useState(initialYear);\n const [gettingYearResume, setGettingYearResume] = useState(false);\n const [loadingDarfButton, setLoadingDarfButton] = useState(false);\n const [showNotAuthorizedModal, setShowNotAuthorizedModal] = useState(false);\n\n const transactionFeature = item.features[0];\n const taxFeature = item.features[1];\n const yearResumeFeature = item.features[2];\n\n const memoriaCalculoFiltered = data.memoriaCalculo.filter(\n (el: any) =>\n (el.operation === \"SELL\" &&\n (el.type === \"TRADE\" || (el.type === \"WITHDRAW\" || el.type === \"WITHDRAWAL\"))) ||\n el.type === \"INTEREST\" ||\n (el.type === \"DIVIDEND\" && !oldModel)\n );\n\n const { emitted } = useMemo(() => {\n if (gettingYearResume) {\n }\n const monthResume = yearResume\n .find((resume) => resume.year === year)\n ?.months.find((m) => m.month - 1 === month);\n return {\n emitted:\n monthResume?.status === YearResumeStatusFromBackEnum.PAYED ||\n monthResume?.status === YearResumeStatusFromBackEnum.NOT_PAYED,\n payed: !!monthResume?.payed,\n status: monthResume?.status,\n };\n }, [yearResume, year, month, gettingYearResume]);\n\n const getDarf = useCallback(\n (id: string) => {\n view && setLoading(true);\n view &&\n (currentPage?.api || apis)\n .get(`${taxFeature.apiUrl}/${id}`)\n .then((response) => {\n setYear(response.data?.year);\n setMonth(response.data?.month - 1);\n setData({\n ...response.data,\n emitted: true,\n });\n })\n .catch(() => message.error(errorMessage))\n .finally(() => setLoading(false));\n },\n [view, taxFeature.apiUrl, currentPage]\n );\n\n const getYearResume = useCallback(\n (year: number, force?: boolean, url?: string) => {\n setGettingYearResume(true);\n !view &&\n year <= new Date().getFullYear() &&\n year >= currentBroker.initialYear &&\n (force ||\n (!yearResumeFeature.disabled &&\n !yearResume.find((resume) => resume.year === year))) &&\n (currentPage?.api || apis)\n .get(yearResumeFeature.apiUrl, { params: { year } })\n .then((response) => {\n const index = yearResume.findIndex(\n (resume) => resume.year === year\n );\n if (index >= 0) {\n setYearResume((yearResume) => {\n yearResume.splice(index, 1, response.data);\n return yearResume;\n });\n } else {\n setYearResume((yearResume) => [...yearResume, response.data]);\n }\n\n if (url && !isMobile()) {\n download(url);\n }\n })\n .catch((err) => console.log(err))\n .finally(() => setGettingYearResume(false));\n },\n [\n yearResumeFeature,\n yearResume,\n view,\n currentBroker.initialYear,\n currentPage,\n ]\n );\n\n const getTaxes = useCallback(() => {\n (!hasPlan || !view) && setLoading(true);\n (!hasPlan || !view) &&\n (currentPage?.api || apis)\n .get(transactionFeature.apiUrl, { params: { month: month + 1, year, atualizouImpostoAcumulado: true } })\n .then((response) => {\n setData(response.data);\n setNotAuthorized(false);\n })\n .catch((err) => {\n setData(defaultDarf);\n if (err?.response?.data === NOT_AUTHORIZED) {\n setNotAuthorized(true);\n setShowNotAuthorizedModal(true);\n } else {\n setNotAuthorized(false);\n message.error(errorMessage);\n }\n })\n .finally(() => setLoading(false));\n }, [hasPlan, view, currentPage?.api, transactionFeature.apiUrl, month, year]);\n\n const getQuotations = useCallback(() => {\n !view &&\n (currentPage?.api || apis)\n .get(\"/warren/get-cotacoes\")\n .then((response) => {\n const { value: cotacoes } = response.data;\n const pojo = {};\n for (let cotacao of cotacoes) {\n const {\n dataHoraCotacao,\n cotacaoCompra: compra,\n cotacaoVenda: venda,\n } = cotacao;\n const [year, month, day] = String(dataHoraCotacao)\n .split(\"T\")[0]\n .split(\"-\");\n Object.assign(pojo, {\n [`${day}/${month}/${year}`]: {\n compra,\n venda,\n },\n });\n }\n setQuotations(pojo);\n })\n .catch((err) => {\n setData(defaultDarf);\n if (err?.response?.data === NOT_AUTHORIZED) {\n setNotAuthorized(true);\n setShowNotAuthorizedModal(true);\n } else {\n setNotAuthorized(false);\n message.error(errorMessage);\n }\n });\n // eslint-disable-next-line\n }, [view]);\n\n const handleDarf = (justSave?: boolean) => {\n setEmitting(true);\n onCloseDarfModal();\n (currentPage?.api || apis)\n .post(taxFeature.apiUrl, {\n ...data,\n year,\n month: month + 1,\n name: user.user.name,\n memoriaCalculo: [],\n transactions: data.memoriaCalculo,\n paymentInfo: {\n clientInfo: {\n name: user?.user?.name,\n email: user?.user?.email,\n document: user?.user?.cpf,\n },\n },\n insertPix: true,\n justSave,\n payed: false,\n })\n .then((res) => {\n setData((data) => ({ ...data, emitted: true }));\n getYearResume(year, true, justSave ? \"\" : res.data.darfUrl);\n setEmitting(false);\n closeModal?.();\n if (!justSave) {\n oldModel\n ? message.success(\"O DARF foi enviado para o seu e-mail\")\n : message.success(\"O Relatório foi enviado para o seu e-mail\"); \n }\n })\n .catch((err) => {\n message.error(err?.response?.data?.message || errorMessage);\n setEmitting(false);\n });\n };\n\n const handleRegularize = (regular: boolean) => {\n setEmitting(true);\n (currentPage?.api || apis)\n .post(\"transaction/regularize\", {\n year,\n month: month + 1,\n regular,\n impostoDevido: data.impostoDevido,\n totalImpostoDevido: data.totalImpostoDevido,\n })\n .then((res) => {\n getYearResume(year, true, res.data.darfUrl);\n getTaxes();\n closeModal?.();\n message.success(\"Dados salvos\");\n })\n .catch(() => message.error(errorMessage))\n .finally(() => setEmitting(false));\n };\n\n const onChangeMonth = (value: moment.Moment | null, dateString: string) => {\n const [month, year] = dateString.split(\"-\");\n setMonth(parseInt(month) - 1);\n setYear(parseInt(year));\n };\n\n const unsetAsset = () => {\n setAsset(undefined);\n };\n\n const handleCloseDeleteModal = () => {\n setShowDeleteModal(false);\n unsetAsset();\n };\n\n const handleCloseAssetModal = () => {\n setMovimentType(\"Venda de ativos\");\n setShowAssetModal(false);\n unsetAsset();\n };\n\n const onCloseHelpModal = () => {\n setHelpModal(undefined);\n };\n\n const onCloseDarfModal = () => {\n setDarfModal(undefined);\n };\n\n const handleOpenDarfModal = () => {\n setDarfModal(DarfModal(emitted, onCloseDarfModal, () => handleDarf()));\n };\n\n const handleOpenPaymentModal = () => {\n setPaymentModal(!paymentModal);\n };\n\n const handleAdd = (event: React.MouseEvent) => {\n event.stopPropagation();\n setShowAssetModal(true);\n };\n\n const handleEdit = (item: any, index: number) => {\n setShowAssetModal(true);\n const data = moment.utc(item.data.toLocaleString()).format(\"DD/MM/YYYY\");\n let i = 0;\n let key = data;\n while (!quotations[key] && i <= 7) {\n key = moment(key, \"DD/MM/YYYY\").subtract(1, \"days\").format(\"DD/MM/YYYY\");\n i++;\n }\n\n setAsset({\n ...item,\n data,\n cotacaoVenda: quotations[key]?.venda,\n cotacaoCompra: quotations[key]?.compra,\n dataVenda: moment\n .utc(item?.dataVenda?.toLocaleString())\n ?.format(\"DD/MM/YYYY\"),\n dataCompra: moment\n .utc(item?.dataCompra?.toLocaleString())\n ?.format(\"DD/MM/YYYY\"),\n });\n };\n\n const handleRemove = (item: any, index: number) => {\n setShowDeleteModal(true);\n setAsset(item);\n };\n\n const addAsset = (asset: any) => {\n setLoading(true);\n\n const ganho = getGain(asset, oldModel)\n const sellPrice = getSellPrice(asset, oldModel)\n const buyPrice = getBuyPrice(asset, oldModel)\n const fee = getFee(asset, oldModel)\n\n const dataToCreate = {\n ...{[sellPrice.key]: sellPrice.value},\n ...{[fee.key]: fee.value},\n ...{[ganho.key]: ganho.value},\n ...{[buyPrice.key]: buyPrice.value},\n data: asset.data, // date liquidação venda\n dataCompra: asset.dataCompra, // pegar a cotação\n operation: \"SELL\", // fixo\n type: \"TRADE\", // fixo\n ativo: asset.ativo, // Tiker que o usuário colocar (Ativo)\n year,\n month,\n quantidade: asset.quantidade,\n // \"saldoBRA\": 10000,\n // \"saldoEUA\": 870.7999999999993,\n // \"capitalGainBRA_BRL\": 0, (colocar no ganho)\n // \"capitalGainEUA_BRL\": 0,\n // ganho: asset.ganho, // (capitalGainBRA_BRL)\n cambioVenda: asset.cambioVenda, // (C) o cambio venda na pagina 1 ta na venda\n cambioCompra: asset.cambioCompra, // (C) o cambio venda na pagina 1 ta na venda\n // \"cambioReferencia\": 0,\n valueOriginEUA: asset.valueOriginEUA, // Origem USA (US$) ??\n movimentType: asset.movimentType\n };\n\n const dataFeeToCreate = {\n ...{[ganho.key]: ganho.value},\n // ganho: asset.ganhoFee,\n ...{[sellPrice.key]: sellPrice.value},\n valor: asset.valor, // (Valor Bruto (US$))\n ...{[fee.key]: fee.value}, // TODO: VALIDATE THIS\n fee: asset.fee, // (Taxa de Corretagem (US$)) \n //\n ativo: asset.ativo, // Tiker que o usuário colocar (Ativo)\n data: asset.dataFee,\n dataCompra: asset.dataFee, // date liquidação venda\n operation: \"BUY\", // fixo\n type: asset.movimentType === 'Dividendos' ? \"DIVIDEND\" : \"INTEREST\", // fixo\n year,\n month,\n rendimentoAplicacao: asset.ganhoFee, // (capitalGainBRA_BRL)\n cambioVenda: asset.cambioVendaFee, // (C) o cambio venda na pagina 1 ta na venda\n movimentType: asset.movimentType\n };\n \n (currentPage?.api || apis)\n .post(\n `${transactionFeature.apiUrl}?manual=true`,\n asset.movimentType !== \"Venda de ativos\"\n ? dataFeeToCreate\n : dataToCreate,\n {\n headers: {\n \"x-email\": user.user.email,\n },\n }\n )\n .then(() => {\n getTaxes();\n getYearResume(year, true);\n })\n .catch(() => message.error(errorMessage))\n .finally(() => {\n setLoading(false);\n handleCloseAssetModal();\n });\n };\n\n const editAsset = (data: any) => {\n const ganho = getGain(data);\n const sellPrice = getSellPrice(data, oldModel)\n const buyPrice = getBuyPrice(data, oldModel)\n const fee = getFee(data, oldModel)\n // ...{[sellPrice.key]: sellPrice.value},\n // ...{[fee.key]: fee.value},\n // ...{[ganho.key]: ganho.value},\n // ...{[buyPrice.key]: buyPrice.value},\n const dataToEdit = {\n ...{[ganho.key]: ganho.value}, // (capitalGainBRA_BRL)\n ...{[fee.key]: fee.value},\n fee: data.fee, // (Taxa de Corretagem (US$))\n ...{[sellPrice.key]: sellPrice.value},\n valor: data.valor, // (Valor Bruto (US$))\n ...{[buyPrice.key]: buyPrice.value},\n valueOriginBRA: data.valueOriginBRA, // Origem BRA (US$) ??\n valueOriginEUA: data.valueOriginEUA, // Origem USA (US$) ??\n //\n data: data.data, // date liquidação venda\n dataCompra: data.dataCompra, // pegar a cotação\n operation: \"SELL\", // fixo\n type: \"TRADE\", // fixo\n ativo: data.ativo, // Tiker que o usuário colocar (Ativo)\n quantidade: data.quantidade,\n // \"saldoBRA\": 10000,\n // \"saldoEUA\": 870.7999999999993,\n // \"capitalGainBRA_BRL\": 0, (colocar no ganho)\n // \"capitalGainEUA_BRL\": 0,\n cambioVenda: data.cambioVenda, // (C) o cambio venda na pagina 1 ta na venda\n cambioCompra: data.cambioCompra, // (C) o cambio venda na pagina 1 ta na venda\n // \"cambioReferencia\": 0,\n };\n setLoading(true);\n (currentPage?.api || apis)\n .put(`${transactionFeature.apiUrl}/${asset._id}`, dataToEdit)\n .then(() => {\n getTaxes();\n getYearResume(year, true);\n })\n .catch(() => message.error(errorMessage))\n .finally(() => {\n setLoading(false);\n handleCloseAssetModal();\n });\n };\n\n const removeAsset = () => {\n setLoading(true);\n (currentPage?.api || apis)\n .delete(`${transactionFeature.apiUrl}/${asset._id}`)\n .then(() => {\n getTaxes();\n getYearResume(year, true);\n })\n .catch(() => message.error(errorMessage))\n .finally(() => {\n setLoading(false);\n handleCloseDeleteModal();\n });\n };\n\n const handlePlanModal = () => {\n navigate('/planos')\n };\n\n const handleSaveMonth = async () => {\n setLoadingDarfButton(true);\n try {\n const retPlanInfo = await apiPayment.get(\"/user-plan/plan-info\");\n const hasExteriorCalcActive = retPlanInfo?.data?.permissions?.[\"exterior-warren\"];\n\n retPlanInfo.data.active || hasExteriorCalcActive || hasPermissionGeneral\n ? handleDarf(true)\n : handlePlanModal();\n } catch (err) {\n console.error(err);\n }\n setLoadingDarfButton(false);\n };\n\n const handleEventDarfButton = async () => {\n setLoadingDarfButton(true);\n let retPlanInfo = {\n data: {\n active: false,\n permissions: {\n \"exterior-warren\": false,\n },\n },\n };\n try {\n retPlanInfo = await apiPayment.get(\"/user-plan/plan-info\");\n } catch (err) {\n console.error(err);\n }\n setLoadingDarfButton(false);\n\n const hasntPlan = !retPlanInfo.data.active;\n const hasExteriorCalcActive = retPlanInfo.data.permissions[\"exterior-warren\"];\n\n //@ts-ignore\n hasntPlan && !hasExteriorCalcActive && !retPlanInfo.data.cupomDueDate\n ? handlePlanModal()\n : handleOpenPaymentModal();\n };\n\n const handleLabelButton: ReactNode = useMemo(() => {\n if(!oldModel) return \"Emitir relatório\"\n else if (data?.totalImpostoDevido <= maxDarfPrice) return \"Pagar DARF\";\n else {\n if (emitted) return \"Emitir novo DARF\";\n else return taxFeature?.buttonLabel;\n }\n }, [data?.totalImpostoDevido, emitted, oldModel, taxFeature?.buttonLabel]);\n\n const downloadAction = (record: any) => {\n (currentPage?.api || apis)\n .get(`/darf/download/${record._id}`)\n .then((res) => {\n if (res.data.url) {\n download(res.data.url);\n }\n });\n };\n\n const calcReturn = (\n sellPrice: number,\n buyPrice: number,\n quantity: number,\n fee: number,\n ganho?: number\n ) => {\n let ret = 0\n if(ganho) {\n const qtt = quantity ? quantity : 1;\n ret =\n sellPrice && buyPrice\n ? (sellPrice * qtt - (fee || 0)) / (buyPrice * qtt) - 1\n : 0;\n }\n return (\n = 0\n ? \"var(--velotax-green-amount)\"\n : \"var(--velotax-red-prejuizo)\"\n }`,\n }}\n >\n {ret ? numberToPercentageWallet(ret) : \"-\"}\n \n );\n };\n\n useEffect(() => {\n getTaxes();\n }, [getTaxes, month, year]);\n\n useEffect(() => {\n getQuotations();\n }, [getQuotations, month, year, item]);\n\n useEffect(() => {\n if (view && darf) {\n getDarf(darf.id);\n }\n }, [getDarf, view, darf]);\n\n useEffect(() => {\n getYearResume(year);\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n\n useEffect(() => {\n const dataToPayment = {\n ...data,\n year,\n month: month + 1,\n name: user.user.name,\n memoriaCalculo: [],\n transactions: data.memoriaCalculo,\n };\n\n setPaymentData(dataToPayment);\n }, [data.totalImpostoDevido, data, month, user.user.name, year]);\n\n const impostoCharge = useMemo(() => {\n // Para verificar se é janeiro (month == 0) e antes de 2024\n const taxes = (oldModel || month == 0)\n ? ((data.impostoDevido ?? 0) + (data.impostoAcumulado ?? 0)) - (data.irrfExterior ?? 0) \n : (data.impostoDevido ?? 0) - (data.irrfExterior ?? 0);\n const isExceedTax = taxes < minDarfPrice;\n const additionalTax = oldModel ? data.multa + data.juros : 0;\n return !view\n ? taxes +\n (isExceedTax ? 0 : additionalTax) \n : Math.max(\n taxes +\n (isExceedTax ? 0 : additionalTax) ,\n 0\n );\n }, [data, view, oldModel]);\n\n const verifyFromApi = (item = {} as any) => {\n return (Object.values(item).includes(item.saldoBRA) \n || Object.values(item).includes(item.rendimentoAplicacao)) && oldModel\n }\n\n return (\n \n \n \n \n {selectedYear && selectedYear <= 2023 && \n \n \n {!view && !viewEdit && (\n <>\n {currentBroker.initialYear === year && month === 0 ? (\n
\n ) : (\n {\n if (month === 0) {\n setYear((year) => {\n const newYear = year - 1;\n getYearResume(newYear);\n setDatePickerYear(newYear);\n return newYear;\n });\n setMonth(11);\n } else {\n setMonth((month) => month - 1);\n }\n }}\n />\n )}\n \n )}\n {monthsExtended[month]} de {year}\n {!view && !viewEdit && (\n <>\n {currentYear === year && currentMonth - 1 === month ? (\n
\n ) : (\n {\n if (month === 11) {\n setYear((year) => {\n const newYear = year + 1;\n getYearResume(newYear);\n setDatePickerYear(newYear);\n return newYear;\n });\n setMonth(0);\n } else {\n setMonth((month) => month + 1);\n }\n }}\n />\n )}\n \n )}\n \n }\n {!view && !viewEdit && (\n \n }\n defaultValue={defaultValue}\n locale={antDatePickerLocale}\n value={moment({ year: datePickerYear, month })}\n onSelect={(e) => {\n if (e.month() === month && year !== datePickerYear) {\n onChangeMonth(e, `${month + 1}-${datePickerYear}`);\n }\n }}\n onPanelChange={(e) => {\n getYearResume(e.year());\n setDatePickerYear(e.year());\n }}\n getPopupContainer={(trigger) => trigger.parentElement!}\n renderExtraFooter={() =>\n yearResumeFeature.disabled ? (\n <>\n ) : (\n \n )\n }\n disabledDate={(current) =>\n current &&\n (current > currentDate.endOf(\"month\") ||\n current < moment(`${currentBroker.initialYear}-01-01`) ||\n current < moment(`2020-01-01`))\n }\n monthCellRender={(e) => (\n \n )}\n />\n \n )}\n \n \n \n\n \n \n {hasPlan && view && darf?.fullPath && (\n \n \n downloadAction(darf)}\n startIcon={\n \n }\n >\n BAIXAR DARF\n \n \n \n )}\n\n {selectedYear && selectedYear <= 2023 &&
\n {(!hasPlan || hideOnBasic) && (\n
\n \n Contrate o plano premium para ver os impostos devidos\n \n }\n onClick={() => {\n handlePlanModal();\n closeModal?.();\n }}\n >\n PREMIUM\n \n
\n )}\n \n {DarfImpostosDevidosDescriptions.map((description) => {\n if (description.id === 'prejuizoExterior' && oldModel) return null\n\n return (\n {setOpenPrejuizoModal(true)}\n )}\n >\n {loading ? (\n \n ) : description.render ? (\n description.render(data, view, year)\n ) : (\n formatCurrency(\n Number(data[description.id as keyof IDarf] || 0)\n )\n )}\n \n )\n })}\n \n
}\n\n
\n \n \n { selectedYear && selectedYear <= 2023?' Vendas realizadas no mês': 'Movimentações'}\n \n }\n >\n {!notAuthorized && !view && (\n }\n >\n Adicionar\n \n )}\n (\n handleEdit(item, index)}\n icon={\n verifyFromApi(item) || (item.type !== 'TRADE' && !oldModel) ? (\n \n ) : (\n \n )\n }\n />,\n handleRemove(item, index)}\n icon={}\n />,\n ]\n }\n >\n {oldModel ? \n {item.ativoTranslated ? item.ativoTranslated : item.ativo}\n }\n description={\n
\n
\n Data de liquidação:{\" \"}\n {moment\n .utc(item?.data?.toLocaleString())\n .format(\"DD/MM/YYYY\")}\n
\n
\n {item.type !== \"INTEREST\"\n ? \"Ganho\"\n : \"Rendimento total\"}\n :{\" \"}\n \n {formatCurrency(\n item.type === \"INTEREST\"\n ? item.rendimentoAplicacao\n : getGain(item, oldModel).value\n )}\n \n
\n {view && (\n <>\n
\n {item.type !== \"INTEREST\"\n ? \"Valor de venda\"\n : \"Valor bruto\"}\n :{\" \"}\n \n {formatCurrency(getSellPrice(item).value, \"US$ \")}\n \n
\n
\n Taxa de corretagem:{\" \"}\n \n {formatCurrency(getFee(item).value, \"US$ \")}\n \n
\n
\n Cotação dólar:{\" \"}\n {item.cambioVenda}\n
\n {item.type !== \"INTEREST\" && (\n <>\n
\n Valor de compra (Origem BRA):{\" \"}\n \n {formatCurrency(\n item.valueOriginBRA,\n \"US$ \"\n )}\n \n
\n
\n Valor de compra (Origem EUA):{\" \"}\n \n {formatCurrency(\n item.valueOriginEUA,\n \"US$ \"\n )}\n \n
\n \n )}\n \n )}\n
\n }\n />\n
: \n {item.ativoTranslated ? item.ativoTranslated : item.ativo}\n }\n description={\n
\n
\n Data:{\" \"}\n {moment\n .utc(item?.data?.toLocaleString())\n .format(\"DD/MM/YYYY\")}\n
\n {item.type === \"TRADE\" &&
Quantidade: {item.quantidade}
}\n
\n {item.type === \"TRADE\"\n ? \"Ganho\"\n : \"Rendimento total\"}\n :{\" \"}\n \n {formatCurrency(\n item.type !== \"TRADE\"\n ? item.rendimentoAplicacao\n : getGain(item, oldModel).value\n )}\n \n
\n {item.type === 'TRADE' &&
\n Retorno: {calcReturn(\n getSellPrice(item, oldModel).value,\n getBuyPrice(item, oldModel).value,\n item.quantidade,\n getFee(item, oldModel).value,\n getGain(item, oldModel).value\n )}\n
}\n
\n }\n />\n
}\n \n )}\n />\n \n \n\n {hasPlan &&
}\n\n {hasPlan && selectedYear && selectedYear <= 2023 && (\n \n Imposto total\n \n {loading ? (\n \n ) : (\n formatCurrency(Math.max(impostoCharge, 0))\n )}\n \n
\n )}\n\n {hasPlan && selectedYear && selectedYear <= 2023 && (\n \n {DarfResultDescriptionsExterior.map((description, i) => {\n if(['multa', 'juros'].includes(description.id) && !oldModel) return <>\n if(['impostoAcumulado'].includes(description.id) && !oldModel && month !== 0) return <>\n return (\n \n {loading ? (\n \n ) : description.Component ? (\n \n ) : (\n formatCurrency(\n Number(data[description.id as keyof IDarf] || 0)\n )\n )}\n \n )\n })}\n \n )}\n\n {!notAuthorized && !view && (\n <>\n \n {!(month === currentMonth && year === currentYear) &&\n oldModel &&\n (data.impostoDevido + data.impostoAcumulado - (data?.irrfExterior ?? 0) ?? 0) <\n minDarfPrice &&\n memoriaCalculoFiltered?.length > 0 && (\n \n
\n \n O valor do imposto devido é menor que{\" \"}\n {formatCurrency(minDarfPrice)}. Você não precisa\n emitir um DARF para este mês.\n \n }\n >\n handleRegularize(true)}\n startIcon={emitting && }\n >\n Salvar sem emitir DARF\n \n \n \n )}\n {(((data.impostoDevido + data.impostoAcumulado - (data?.irrfExterior ?? 0)) >= minDarfPrice) || (!oldModel && memoriaCalculoFiltered.length > 0 )) && (\n <>{selectedYear && selectedYear <= 2023 && \n
\n target.parentElement!}\n title={\n month === currentMonth && year === currentYear && oldModel\n ? \"Aguarde o encerramento do mês para pagar seu DARF\"\n : \"\"\n }\n >\n {\n oldModel \n ? handleEventDarfButton()\n : handleDarf()\n }}\n startIcon={\n (emitting || loadingDarfButton) && \n }\n disabled={\n loading ||\n emitting ||\n loadingDarfButton ||\n (month === currentMonth && year === currentYear && oldModel)\n }\n >\n {handleLabelButton}\n {\" \"}\n \n }\n )}\n \n {/* {!oldModel && ()} */}\n {(!(month === currentMonth && year === currentYear) && oldModel) && (\n \n \n }\n >\n Salvar apenas\n \n \n \n )}\n \n )}\n\n {!view && (\n <>\n setShowNotAuthorizedModal(false)}\n />\n
\n
\n

\n (1) Os cálculos de imposto de renda foram realizados levando\n em consideração somente as operações de compra e venda\n realizadas na Warren Internacional. Caso você tenha realizado\n operações com ativos no exterior em outras corretoras,\n realize as alterações manualmente.\n

\n
\n {selectedYear && selectedYear <= 2023 &&
\n

\n (2) Caso você tenha realizado a transferência de custódia de\n outras corretoras de ativos no exterior para a Warren\n Internacional, realize manualmente a inserção do custo médio\n de compra dos respectivos ativos transferidos.\n

\n
}\n {/*
\n

\n (3) O Usuário é exclusivamente responsável pela conferência e\n validação das informações utilizadas na apuração do imposto\n devido, conforme{\" \"}\n \n Termos e Condições Gerais de Uso.\n \n

\n
*/}\n
\n \n )}\n {!view && !viewEdit && (\n \n )}\n \n \n \n {helpModal?.content}\n \n \n {darfModal?.content}\n \n \n ) : (\n Object.values(asset).includes(asset.saldoBRA) && oldModel && (\n \n )\n )\n }\n />\n {/* {setOpenPrejuizoModal(false)}} \n onCancel={() => {setOpenPrejuizoModal(false)}}>\n Prejuízo a compensar\n \n */}\n {}}\n edit={() => {}}\n onCancel={() => {setOpenPrejuizoModal(false)}}\n itemToEdit={{}}\n rows={PrejuFormItemRows(false)}\n />\n maxPixPayment}\n callDarf={() => {\n HandleTag(\"67\");\n handleOpenDarfModal();\n }}\n disableCreditCardOption={\n data?.totalImpostoDevido > maxCreditCardPayment\n }\n paymentData={{\n ...paymentData,\n impostoTotalFinal: data.totalImpostoDevido + data.impostoAcumulado,\n }}\n />\n Promise.resolve(removeAsset())}\n body=\"Você realmente quer deletar esse ativo?\"\n />\n \n );\n};\n","// Retorno: {calcReturn(item.valor ?? item.sellPrice_BRL, item.valueOriginBRA ?? item.buyPrice_BRL, item.quantidade, item.fee ?? item.fee_BRL, item.ganho ?? item.varTotalBRL)}\n\nexport function useDarfExterior() {\n const gainKeys = ['ganho', 'varTotalBRL'];\n const sellPriceKeys = ['valor', 'sellPrice_BRL'];\n const buyPriceKeys = ['valueOriginBRA', 'buyPrice_BRL'];\n const feeKeys = ['fee', 'fee_BRL'];\n\n function getByKey(item: any, keys: string[], isOldModel?: boolean) {\n if (isOldModel !== undefined) {\n if (isOldModel) {\n return { key: keys[0], value: item[keys[0]] ?? null };\n }\n return { key: keys[1], value: item[keys[1]] ?? null };\n }\n const k = keys.find((key) => item[key] !== null && item[key] !== undefined);\n const value = k ? item[k] : null;\n const key = k ?? keys[0];\n return { key, value };\n }\n\n function getGain(item: any, isOldModel?: boolean) {\n return getByKey(item, gainKeys, isOldModel)\n }\n\n function getSellPrice(item: any, isOldModel?: boolean) {\n return getByKey(item, sellPriceKeys, isOldModel)\n }\n\n function getBuyPrice(item: any, isOldModel?: boolean) {\n return getByKey(item, buyPriceKeys, isOldModel)\n }\n\n function getFee(item: any, isOldModel?: boolean) {\n return getByKey(item, feeKeys, isOldModel)\n }\n\n return { getBuyPrice, getGain, getSellPrice, getFee }\n}","import styled from \"styled-components\";\n\nexport const CardContainer = styled.div`\n width: 100%;\n height: 64px;\n cursor: pointer;\n position: relative;\n background-color: transparent;\n border-bottom: 1px solid var(--velotax-border-color);\n\n &,\n a,\n .MuiButtonBase-root {\n display: flex;\n align-items: center;\n justify-content: space-between;\n\n & > svg {\n width: 20px;\n height: 20px;\n stroke: var(--velotax-font-color-light);\n }\n }\n\n a,\n .MuiButtonBase-root {\n width: 100%;\n height: 100%;\n padding: 12px 12px 12px 0;\n }\n\n figure {\n margin: 0 16px 0 0;\n\n svg {\n width: 24px;\n height: 24px;\n &:not(.no-fill) {\n fill: var(--ant-primary-color);\n }\n }\n }\n\n .content {\n flex-grow: 1;\n display: flex;\n align-items: center;\n font-weight: 400;\n font-size: 1rem;\n line-height: 1.125rem;\n color: var(--velotax-font-color-light);\n\n .ant-typography {\n color: inherit;\n position: relative;\n text-align: left;\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n &.not-free {\n .content {\n .content-children {\n width: 100%;\n .ant-row {\n width: 100%;\n .ant-col {\n width: 100%;\n .ant-typography {\n width: calc(100% - 64px);\n }\n }\n }\n }\n }\n }\n }\n`;\n","import { ReactNode } from \"react\";\nimport { ButtonBase } from \"@mui/material\";\nimport { useNavigate } from \"react-router-dom\";\nimport { HiOutlineChevronRight } from \"react-icons/hi\";\nimport { isMobile } from \"../../utils\";\nimport { CardContainer } from \"./style\";\n\ninterface CardXPProps {\n id: string;\n icon: ReactNode;\n children: ReactNode;\n link?: string;\n className?: string;\n disabled?: boolean;\n onClick?: () => void;\n}\n\nconst Container: React.FC> = ({ children, link }) => {\n return link && link.includes(\"http\") ? (\n \n {children}\n \n ) : (\n <>{children}\n );\n};\n\nexport const CardXP: React.FC = ({\n id,\n icon,\n link,\n onClick,\n children,\n disabled,\n className,\n}) => {\n const navigate = useNavigate();\n\n const handleClick = () => {\n if (disabled) return;\n if (onClick) {\n onClick();\n } else if (link && !link.includes(\"http\")) {\n navigate(link);\n }\n };\n\n return (\n \n \n \n
\n
{icon}
\n
{children}
\n
\n \n
\n
\n
\n );\n};\n","import { Tooltip } from \"antd\";\nimport { Button } from \"@mui/material\";\n\nexport const PayButton: React.FC<{\n fullWidth?: boolean;\n onClick?: () => void;\n disabled?: boolean;\n title?: React.ReactNode;\n isReport?: boolean\n}> = ({ onClick, fullWidth, disabled, title, isReport }) => (\n target.parentElement!}>\n \n {isReport ? 'Emitir relatório' : 'Pagar'}\n {\" \"}\n \n);\n","import { Typography } from \"antd\";\nimport { GiProfit } from \"react-icons/gi\";\nimport { AiOutlineApi } from \"react-icons/ai\";\nimport { BiTransferAlt } from \"react-icons/bi\";\nimport { RiFileList3Line } from \"react-icons/ri\";\nimport { HiOutlineCalculator } from \"react-icons/hi\";\nimport { isMobile } from \"../../utils\";\n\nexport const itensExterior = [\n {\n id: \"darf\",\n premium: true,\n showToBasic: false,\n link: \"/warren/exterior-historic\",\n content: Calculadora de DARF,\n description: Cálculo de IR e mensal para o ano de 2023,\n icon: (\n \n ),\n },\n // {\n // premium: true,\n // id: \"anual-report\",\n // link: \"/warren/exterior-report\",\n // content: Informe de rendimentos ({YearReport}),\n // description: Relatório para declaração do IRPF,\n // icon: (\n // \n // ),\n // },\n {\n id: \"report\",\n basic: true,\n premium: true,\n link: \"/warren/exterior-report\",\n content: (\n \n Informe de rendimentos\n \n ),\n description: (\n Relatórios auxiliares para declaração de IR\n ),\n icon: (\n \n ),\n },\n // {\n // id: \"report\",\n // basic: true,\n // premium: true,\n // link: \"/warren/exterior-report\",\n // content: (\n // \n // Relatórios {!isMobile() && \"(padrão Receita Federal)\"}\n // \n // ),\n // description: (\n // Relatórios auxiliares para declaração de IR\n // ),\n // icon: (\n // \n // ),\n // },\n // {\n // id: \"dividendos\",\n // premium: true,\n // link: \"/warren/exterior-dividendos\",\n // content: Dividendos,\n // icon: ,\n // description: Gestão dos dividendos recebidos,\n // },\n // {\n // id: \"insert-manual\",\n // link: \"/warren/transferencia-custodia\",\n // content: Transferência de custódia,\n // icon: (\n // \n // ),\n // },\n // {\n // id: \"integration\",\n // link: \"/warren/exterior-integration\",\n // content: Integração com Warren,\n // icon: ,\n // },\n {\n id: \"insert-manual\",\n premium: false,\n link: \"/warren/transferencia-custodia\",\n content: Transferência de custódia,\n icon: (\n \n ),\n // description: Gestão de transferências de custódia,\n }\n];\n","export default __webpack_public_path__ + \"static/media/check.d361ff1f.svg\";","import styled from \"styled-components\";\nimport check from \"../../../assets/icons/check.svg\";\n\nexport const PayDarfButtonContainer = styled.div`\n display: flex;\n cursor: pointer;\n position: relative;\n align-items: center;\n justify-content: center;\n font-size: 12px;\n font-weight: 600;\n line-height: 16px;\n color: var(--white);\n height: 24px;\n border-radius: 12px;\n transition: filter 0.3s;\n padding: 4px 24px 4px 12px;\n background-color: var(--em-aberto);\n\n :hover {\n filter: contrast(0.75) brightness(1.15);\n }\n\n :after {\n content: \"\";\n top: 6px;\n right: 6px;\n width: 12px;\n height: 12px;\n border-radius: 50%;\n position: absolute;\n background-color: var(--white);\n }\n\n &.checked {\n background-color: var(--green);\n &::after {\n top: 5px;\n width: 14px;\n height: 14px;\n background-size: 100%;\n background-position: center;\n background-repeat: no-repeat;\n background-color: var(--green);\n background-image: url(${check});\n }\n }\n`;\n","import clsx from \"clsx\";\nimport { Tooltip } from \"antd\";\nimport { PayDarfButtonContainer } from \"./styles\";\n\ninterface PayDarfButtonProps {\n checked?: boolean;\n onChange?: () => void;\n checkedChildren?: React.ReactNode;\n unCheckedChildren?: React.ReactNode;\n}\n\nexport const PayDarfButton: React.FC = ({\n checked,\n onChange,\n checkedChildren,\n unCheckedChildren,\n}) => {\n return (\n \n \n {checked ? checkedChildren : unCheckedChildren}\n \n \n );\n};\n","import axios from 'axios';\n\nexport const instanceMsCalc = axios.create({\n baseURL: process.env.REACT_APP_MS_CALC_URL ?? 'http://localhost:5001',\n headers: { Authorization: process.env.REACT_APP_AUTH_TOKEN ?? '' },\n});","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n display: flex;\n flex-direction: column;\n svg {\n width: 20px;\n height: 20px;\n min-width: 20px;\n }\n .ant-checkbox {\n margin-top: -2px;\n }\n\n .checkbox-wrapper {\n display: flex;\n align-items: center;\n margin-left: 12px;\n\n .label {\n margin-left: 6px;\n }\n }\n\n .loading-wrapper {\n display: flex;\n align-items: center;\n margin-left: -2px;\n svg {\n width: 20px;\n height: 20px;\n }\n }\n\n .ant-checkbox-wrapper {\n margin-left: 0;\n display: flex;\n align-items: center;\n\n & + label {\n margin-top: 12px;\n }\n\n .ant-checkbox-checked .ant-checkbox-inner {\n background-color: var(--ant-primary-color);\n border-color: var(--ant-primary-color);\n }\n\n .ant-checkbox-inner {\n background: transparent;\n border: 2px solid var(--ant-primary-color);\n width: 20px;\n height: 20px;\n border-radius: 2px;\n }\n }\n\n .ant-checkbox + span {\n margin-left: -10px;\n }\n`;\n","import { Checkbox, Row } from \"antd\";\nimport { IoMdGlobe } from \"react-icons/io\";\nimport { BiHomeAlt } from \"react-icons/bi\";\nimport { IconBaseProps } from \"react-icons\";\nimport { RiStockLine } from \"react-icons/ri\";\nimport React, { useEffect, useState } from \"react\";\nimport { BsCurrencyBitcoin } from \"react-icons/bs\";\nimport { LoadingOutlined } from \"@ant-design/icons\";\nimport { Container } from \"./styles\";\n\ninterface IProps {\n data: string[];\n saveModules: (\n modules: string[],\n moduleName: string,\n deleted: boolean\n ) => void;\n loading: any;\n}\n\ninterface ISelect {\n id: string;\n icon: IconBaseProps;\n label: string;\n}\n\nconst VelotaxCalculatorsSelect: ISelect[] = [\n {\n id: \"bolsa\",\n icon: ,\n label: \"Investimentos na Bolsa de Valores\",\n },\n {\n id: \"cripto\",\n icon: ,\n label: \"Investimentos em Criptoativos\",\n },\n {\n id: \"exterior\",\n icon: ,\n label: \"Investimentos no exterior\",\n },\n {\n id: \"autonomos\",\n icon: ,\n label: \"Autônomos e Aluguel\",\n },\n];\n\nexport const SelectBoxes: React.FC = ({\n data = {},\n saveModules,\n loading,\n}) => {\n const [values, setValues] = useState((data || []) as string[]);\n\n useEffect(() => {\n if (Array.isArray(data)) {\n setValues(data);\n }\n }, [data]);\n\n const handleSetValue = (\n array: string[],\n moduleName: string,\n deleted: boolean\n ) => {\n setValues(array);\n saveModules(array, moduleName, deleted);\n };\n\n const handleChange = (value: string): void => {\n if (values.includes(value)) {\n handleSetValue(\n values.filter((vl) => vl !== value),\n value,\n true\n );\n } else {\n handleSetValue([...values, value], value, false);\n }\n };\n\n return (\n \n {VelotaxCalculatorsSelect.map((op: any, index: number) => (\n \n {loading?.[op.id] === true ? (\n
\n \n \n {op.icon && op.icon}\n
{op.label}
\n
\n
\n ) : (\n loading[key] === true\n )}\n checked={values.includes(op.id)}\n onChange={() => handleChange(op.id)}\n >\n
\n {op.icon && op.icon}\n
{op.label}
\n
\n \n )}\n
\n ))}\n
\n );\n};\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n padding: 64px 32px 128px;\n @media only screen and (max-device-width: 812px) {\n padding: 0;\n }\n`;\n\nexport const Content = styled.div`\n padding: 32px;\n margin: 0 auto;\n max-width: 600px;\n border-radius: 16px;\n background-color: var(--velotax-background-color);\n h1 {\n font-size: 24px;\n margin: 0 0 24px;\n position: relative;\n color: var(--velotax-font-color);\n\n &::before {\n content: \"\";\n top: 0;\n width: 4px;\n left: -32px;\n height: 100%;\n position: absolute;\n background-color: var(--ant-primary-color);\n }\n }\n @media only screen and (max-device-width: 812px) {\n padding: 24px;\n border-radius: 0;\n min-height: calc(100vh - 64px);\n h2 {\n &::before {\n left: -24px;\n }\n }\n }\n`;\n\nexport const CalculatorsSelect = styled.div`\n h2 {\n font-size: 18px;\n font-weight: 500;\n margin: 0 0 24px;\n color: var(--velotax-font-color);\n }\n`;\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n padding: 64px 32px 128px;\n &.view-edit {\n padding: 0;\n }\n &.view {\n padding: 0;\n }\n\n h1 {\n width: 700px;\n margin: 0 auto 1.5rem;\n font-weight: 400;\n font-size: 2rem;\n position: relative;\n line-height: 2.5rem;\n padding-bottom: 1rem;\n color: var(--velotax-font-color-light);\n\n :after {\n content: \"\";\n position: absolute;\n left: 0;\n bottom: 0;\n height: 2px;\n width: 100px;\n background-color: var(--ant-primary-color);\n }\n }\n\n & > span.ant-typography {\n display: block;\n width: 700px;\n margin: 0 auto 1rem;\n font-size: 1rem;\n line-height: 1.5rem;\n color: var(--velotax-font-color-light);\n\n span {\n cursor: pointer;\n font-weight: 500;\n color: var(--ant-primary-color);\n }\n }\n\n .edition-button-corretagem {\n display: flex;\n align-items: center;\n margin-top: 12px;\n background: var(--velotax-background-color);\n\n button {\n display: flex;\n align-items: center;\n\n span {\n margin-left: 8px;\n }\n }\n }\n\n .juridic-messages-container {\n width: 100%;\n opacity: 0.8;\n padding: 24px 0 0;\n\n .message {\n display: flex;\n flex-direction: row;\n justify-content: flex-start;\n margin-bottom: 1rem;\n }\n\n p {\n font-size: 0.75rem;\n font-weight: 400;\n text-align: justify;\n line-height: 1.4rem;\n color: var(--velotax-font-color-light);\n margin-bottom: 0;\n\n i {\n font-weight: bold;\n color: var(--velotax-font-color-light);\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n padding: 0 0 64px;\n\n .juridic-messages-container {\n margin: 0;\n width: 100%;\n p {\n margin-left: 0;\n }\n }\n\n h1 {\n max-width: calc(100% - 48px);\n margin: 0 24px 1.5rem;\n padding: 24px 0 1rem;\n }\n\n & > span.ant-typography {\n width: 100%;\n margin: 0 auto 1rem;\n padding: 0 24px;\n }\n }\n`;\n\nexport const ButtonContent = styled.div`\n width: 700px;\n margin: 0 auto 8px;\n div {\n display: flex;\n justify-content: flex-end;\n }\n\n @media only screen and (max-device-width: 812px) {\n width: 100%;\n div {\n width: 100%;\n padding: 16px 24px 0;\n button {\n span {\n font-size: 11px;\n white-space: nowrap;\n text-overflow: ellipsis;\n }\n }\n }\n }\n\n @media only screen and (max-device-width: 576px) {\n div {\n button {\n width: 100%;\n }\n }\n }\n`;\n\nexport const Content = styled.div`\n padding: 32px;\n &.second.view,\n &.second.view-edit {\n padding: 0 32px 32px;\n }\n &.second {\n padding: 32px;\n border: none;\n background-color: transparent;\n }\n .ant-divider {\n margin: 8px 0 24px;\n }\n h3.date-title {\n font-size: 24px;\n font-weight: 700;\n }\n margin: 0 auto;\n max-width: 700px;\n border-radius: 4px;\n background-color: var(--velotax-background-color);\n h3 {\n display: flex;\n align-items: center;\n column-gap: 16px;\n font-size: 20px;\n color: var(--velotax-font-color-light);\n margin-bottom: 0;\n user-select: none;\n }\n .desc-label {\n display: flex;\n align-items: center;\n svg {\n fill: var(--ant-primary-color);\n }\n }\n .month-chevron {\n width: 32px;\n height: 32px;\n cursor: pointer;\n &.disabled {\n opacity: 0.15;\n cursor: default;\n }\n }\n .desc-content {\n display: flex;\n align-items: flex-start;\n justify-content: center;\n column-gap: 8px;\n svg {\n fill: var(--ant-primary-color);\n }\n span {\n align-self: center;\n }\n button {\n min-width: 32px;\n }\n }\n .market {\n opacity: 0.6;\n font-weight: bold;\n }\n .ml-40 {\n margin-left: 40px;\n }\n .btn-icon {\n padding: 0;\n width: 48px;\n display: flex;\n .MuiTouchRipple-root {\n width: 48px;\n }\n }\n .add {\n float: right;\n min-width: 128px;\n margin-bottom: 16px;\n }\n .ant-descriptions-view {\n border-radius: 4px !important;\n .ant-descriptions-item-label {\n width: 60%;\n padding: 10px 16px;\n color: var(--velotax-font-color-light) !important;\n }\n .ant-descriptions-item-content {\n padding: 10px 16px;\n text-align: center;\n background-color: var(--velotax-border-color) !important;\n span {\n color: var(--velotax-font-color-light) !important;\n }\n }\n }\n .ant-list.ant-list-split {\n clear: both;\n padding: 0 16px;\n background-color: var(--velotax-ghost);\n border: 1px solid var(--velotax-ghost);\n border-radius: 4px;\n .ant-list-item-action > li {\n padding: 0;\n }\n }\n .ant-list-item-action > li,\n .ant-list-item-meta-title,\n .ant-list-item-meta-description {\n color: var(--velotax-font-color-light);\n }\n .ant-list-item-meta-description {\n opacity: 0.75;\n }\n .list-description {\n display: flex;\n flex-direction: column;\n }\n .min-darf-price {\n margin-top: 24px;\n display: flex;\n align-items: center;\n column-gap: 8px;\n }\n .text-center {\n display: block;\n text-align: center;\n }\n .ant-collapse-header {\n padding: 12px 0 !important;\n }\n .ant-collapse-content-box {\n padding: 16px 0 !important;\n }\n .ant-collapse\n > .ant-collapse-item\n > .ant-collapse-header\n .ant-collapse-arrow\n svg {\n transform: rotate(-90deg);\n }\n .ant-collapse-item-disabled {\n & > .ant-collapse-header {\n cursor: default;\n .ant-collapse-arrow {\n opacity: 0;\n }\n }\n }\n .ant-collapse-header-text {\n width: 100%;\n }\n .total-tax-header {\n width: calc(100% - 48px);\n display: flex;\n align-items: center;\n justify-content: space-between;\n &.original {\n h3:last-of-type {\n width: 40%;\n }\n }\n h3 {\n margin: 0 0 8px;\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n width: 100%;\n padding: 24px;\n border-radius: 0;\n &.first {\n padding: 24px;\n }\n &.second {\n padding: 24px !important;\n border-top: 1px solid #efefef;\n }\n h3 {\n font-size: 18px;\n }\n .anticon.anticon-right.ant-collapse-arrow {\n top: 24px;\n }\n .desc-content {\n column-gap: 2px;\n flex-direction: row;\n &.is-editting {\n row-gap: 8px;\n flex-direction: column;\n button {\n width: 100%;\n }\n }\n &:not(.is-editting) {\n span {\n line-height: 32px;\n }\n button {\n margin-top: -2px;\n }\n }\n &.ml-40 {\n margin-left: 0;\n }\n }\n .market {\n font-size: 11px;\n letter-spacing: -0.1px;\n }\n }\n`;\n\nexport const BolsaOperations = styled.div`\n border-radius: 4px;\n position: relative;\n color: var(--velotax-font-color-light);\n background-color: var(--velotax-ghost);\n border: 1px solid var(--velotax-background-color-ghost);\n\n .no-plan {\n span {\n user-select: none;\n }\n }\n\n .no-plan-container {\n position: absolute;\n top: 55px;\n left: 40%;\n width: 60%;\n z-index: 3;\n display: flex;\n padding: 8px;\n font-size: 16px;\n font-weight: 500;\n text-align: center;\n align-items: center;\n flex-direction: column;\n justify-content: center;\n background-color: #fff4;\n border-radius: 0 0 8px 0;\n height: calc(100% - 55px);\n backdrop-filter: blur(4px);\n border-left: 1px solid var(--velotax-background-color-ghost);\n .ant-btn {\n margin-top: 8px;\n }\n }\n\n div.strong span {\n font-weight: 700 !important;\n }\n div.opacity {\n opacity: 0.8;\n }\n\n div.header,\n div.sub-header,\n div.row {\n display: grid;\n grid-template-columns: 2fr 1fr 1fr 1fr;\n span + span {\n text-align: center;\n justify-content: center;\n }\n }\n\n div.sub-header,\n div.row {\n height: auto;\n min-height: 48px;\n border-top: none;\n & + div.sub-header {\n border-top: 1px solid var(--velotax-background-color-ghost);\n }\n & > span + span {\n background-color: var(--velotax-border-color);\n }\n & > span {\n padding: 8px 16px;\n display: flex;\n align-items: center;\n border-left: none;\n & + span {\n border-left: 1px solid var(--velotax-background-color-ghost);\n }\n }\n &:last-of-type > span:last-of-type {\n border-radius: 0 0 4px 0;\n }\n }\n\n div.header {\n padding: 16px;\n border-radius: 4px 4px 0 0;\n background-color: var(--velotax-background-color-ghost);\n span {\n font-weight: 700;\n }\n button {\n display: none;\n }\n }\n\n div.sub-header {\n font-size: 14px;\n & > span {\n font-weight: 300;\n }\n }\n\n div.row {\n opacity: 0.85;\n font-size: 13px;\n border-top: 1px solid var(--velotax-background-color-ghost);\n }\n\n @media only screen and (max-device-width: 812px) {\n position: relative;\n overflow-x: hidden;\n span {\n font-size: 12px;\n button {\n max-width: 24px;\n min-width: 24px;\n }\n }\n .no-plan-container {\n left: 50%;\n width: 50%;\n font-size: 14px;\n line-height: 18px;\n }\n div.header,\n div.sub-header,\n div.row {\n width: 200%;\n height: auto;\n min-height: 48px;\n grid-template-columns: 1fr 1fr 1fr 1fr;\n }\n div.sub-header,\n div.row {\n & > span {\n padding: 12px;\n }\n }\n\n div.header {\n padding: 16px 0;\n }\n div.header > span + span {\n padding: 0 8px;\n justify-content: space-between;\n }\n\n div.header > span:first-of-type,\n div.sub-header > span:first-of-type {\n position: sticky;\n left: 0;\n }\n div.header > span.show,\n div.sub-header > span.show {\n opacity: 1;\n z-index: 2;\n }\n div.header > span,\n div.sub-header > span {\n opacity: 0;\n z-index: 1;\n }\n div.header > span {\n display: flex;\n align-items: center;\n justify-content: center;\n column-gap: 8px;\n }\n div.header {\n button {\n display: flex;\n }\n }\n div.header > span.show svg polyline {\n stroke: var(--velotax-font-color);\n }\n }\n`;\n","import { v4 } from \"uuid\";\nimport { message } from \"antd\";\nimport { useNavigate } from \"react-router-dom\";\nimport {\n Dispatch,\n SetStateAction,\n createContext,\n useCallback,\n useContext,\n useEffect,\n useState,\n} from \"react\";\nimport { errorMessage } from \"../utils\";\nimport apiBolsa from \"../services/apiBolsa\";\nimport { useAuth } from \"../contexts/AuthContext\";\nimport { useBroker } from \"../contexts/BrokerContext\";\nimport moment from \"moment\";\n\ninterface IOldTransactionsContext {\n changed: boolean;\n loadingPut: boolean;\n loadingGet: boolean;\n setLoadingPut: Dispatch>;\n setLoadingGet: Dispatch>;\n oldPositionEdit: any;\n doacaoHerancaEdit: any;\n oldPositionList: any[];\n doacoesHerancas: any[];\n showAddPositionModal: boolean;\n setOldPositionEdit: Dispatch>;\n setDoacaoHerancaEdit: Dispatch>;\n setShowAddPositionModal: Dispatch>;\n downloadOldTransactionsExcel: () => Promise;\n downloadDoacoesHerancasExcel: () => Promise;\n saveOldPositions: () => void;\n saveDoacoesHerancas: () => void;\n addOldPosition: (item: any) => void;\n addDoacaoHeranca: (item: any) => void;\n editOldPosition: (item: any) => void;\n editDoacaoHeranca: (item: any) => void;\n handleEditOldPosition: (item: any, index: number) => void;\n handleRemoveOldPosition: (item: any, index: number) => void;\n handleRemoveDoacaoHeranca: (item: any, index: number) => void;\n handleEditDoacaoHeranca: (item: any, index: number) => void;\n getOldTransactionsInit: () => void;\n getDoacoesHerancasInit: () => void;\n}\n\nconst OldTransactionsContext = createContext({} as IOldTransactionsContext);\n\nexport const OldTransactionsProvider: React.FC = ({ children }) => {\n const { user } = useAuth();\n const navigate = useNavigate();\n const { initIntegration, currentBroker } = useBroker();\n const [changed, setChanged] = useState(false);\n const [loadingGet, setLoadingGet] = useState(false);\n const [loadingPut, setLoadingPut] = useState(false);\n const [oldPositionEdit, setOldPositionEdit] = useState({});\n const [doacaoHerancaEdit, setDoacaoHerancaEdit] = useState({});\n const [oldPositionList, setOldPositionList] = useState(null);\n const [doacoesHerancas, setDoacoesHerancas] = useState(null);\n const [showAddPositionModal, setShowAddPositionModal] = useState(false);\n\n const handleEditOldPosition = (item: any, index: number) => {\n setShowAddPositionModal(true);\n setOldPositionEdit(item);\n };\n\n const handleEditDoacaoHeranca = (item: any, index: number) => {\n setShowAddPositionModal(true);\n setDoacaoHerancaEdit(item);\n };\n\n const handleRemoveOldPosition = (item: any, index: number) => {\n const pojo = oldPositionList\n .filter((e: any) =>\n \"lendingSide\" in item ? e.lendingSide : !e.lendingSide\n )\n .find((item: any, i: number) => i === index);\n const listOldPosition = oldPositionList.filter(\n (item: any) => JSON.stringify(pojo) !== JSON.stringify(item)\n );\n setOldPositionList(listOldPosition);\n setChanged(true);\n };\n\n const handleRemoveDoacaoHeranca = (item: any, index: number) => {\n const itemParam = item;\n const list = doacoesHerancas.map(\n (item: any) => {\n const newOrders = item?.orders.filter((or: any) => {\n delete or.dateView;\n if (JSON.stringify(itemParam) !== JSON.stringify(or)) return or;\n })\n return { ...item, orders: newOrders };\n }\n );\n setDoacoesHerancas(list);\n setChanged(true);\n }\n\n const editOldPosition = (editItem: any) => {\n const listOldPositions = oldPositionList.map((item: any) =>\n editItem.id === item.id\n ? {\n ...item,\n ...editItem,\n price: editItem?.avgBuyPrice,\n operation:\n editItem?.lendingSide && editItem?.lendingSide === \"Tomador\"\n ? \"V\"\n : \"C\",\n }\n : item\n );\n setOldPositionList(listOldPositions);\n setShowAddPositionModal(false);\n setOldPositionEdit({});\n setChanged(true);\n };\n\n const editDoacaoHeranca = (editItem: any) => {\n const list = doacoesHerancas.map((item: any) => {\n const newOrders = item?.orders.map((or: any) => {\n delete or.dateView;\n const newDate = new Date(\n `${moment(editItem?.dateView, 'DD/MM/YYYY', true).format(\n 'YYYY-MM-DD',\n )}T03:00:00.000Z`);\n return editItem?._id === or?._id\n ? {\n ...or,\n date: newDate,\n code: editItem?.code,\n price: editItem?.price,\n quantity: editItem?.quantity,\n totalValue: editItem?.price * editItem?.quantity,\n }\n : or\n })\n return { ...item, orders: newOrders };\n }\n );\n setDoacoesHerancas(list);\n setShowAddPositionModal(false);\n setDoacaoHerancaEdit({});\n setChanged(true);\n };\n\n const addOldPosition = (item: any) => {\n const listOldPosition: any[] = [...oldPositionList];\n const newPostion = {\n operation:\n item?.lendingSide && item?.lendingSide === \"Tomador\" ? \"V\" : \"C\",\n avgBuyPrice: item?.avgBuyPrice,\n price: item?.avgBuyPrice,\n code: item?.code,\n feeB3: item?.feeB3 || 0,\n institution: \"Desconhecida\",\n date: new Date(2019, 11, 31),\n market: \"Mercado a Vista\",\n quantity: item?.quantity,\n month: 11,\n year: 2019,\n id: v4(),\n };\n\n if (item.lendingSide)\n Object.assign(newPostion, { lendingSide: item?.lendingSide });\n listOldPosition.push(newPostion);\n\n setOldPositionList(listOldPosition);\n setShowAddPositionModal(false);\n setChanged(true);\n };\n\n const addDoacaoHeranca = (addItem: any) => {\n const list = [...doacoesHerancas];\n const month = Number((addItem?.dateView)?.split('/')[1]);\n const year = Number((addItem?.dateView)?.split('/')[2]);\n const now = new Date();\n const newDate = new Date(\n `${moment(addItem?.dateView, 'DD/MM/YYYY', true).format(\n 'YYYY-MM-DD',\n )}T03:00:00.000Z`);\n const retExisting = doacoesHerancas.filter((item: any) => {\n const newOrders = item?.orders;\n if (item?.month == month && item?.year == year) {\n newOrders.push(\n {\n code: addItem?.code,\n operation: \"C\",\n date: newDate,\n quantity: addItem?.quantity,\n price: addItem?.price,\n totalValue: addItem?.price * addItem?.quantity,\n totalFeeNota: 0,\n name: addItem?.code,\n market: \"Mercado a Vista\",\n expirationDate: null,\n institution: \"Desconhecida\",\n operationType: \"Credito\"\n }\n )\n return { ...item, orders: newOrders };\n }\n })\n if (!retExisting || retExisting.length == 0) {\n const newOperation = {\n cpf: user?.user?.cpf,\n month: month,\n year: year,\n provider: 'b3',\n createdAt: now,\n updatedAt: now,\n orders: [\n {\n code: addItem?.code,\n operation: \"C\",\n date: newDate,\n quantity: addItem?.quantity,\n price: addItem?.price,\n totalValue: addItem?.price * addItem?.quantity,\n totalFeeNota: 0,\n name: addItem?.code,\n market: \"Mercado a Vista\",\n expirationDate: null,\n institution: \"Desconhecida\",\n operationType: \"Credito\"\n }\n ]\n };\n \n list.push(newOperation);\n }\n\n setDoacoesHerancas(list);\n setShowAddPositionModal(false);\n setChanged(true);\n };\n\n const saveOldPositions = useCallback(async () => {\n const orders = oldPositionList.map((item: any) => ({\n ...item,\n id: undefined,\n }));\n try {\n setLoadingPut(true);\n await apiBolsa.post(\"/operation\", { orders });\n // message.success(\"Dados salvos com sucesso!\");\n navigate(`/${currentBroker?.path}/bolsa-historic`);\n } catch (err) {\n message.error(errorMessage);\n throw Error;\n } finally {\n setLoadingPut(false);\n }\n }, [oldPositionList, currentBroker, navigate]);\n\n const saveDoacoesHerancas = useCallback(async () => {\n const operations = doacoesHerancas.map((item: any) => {\n const newOrders = item?.orders.map((or: any) => {\n return { ...or }\n })\n return { ...item, orders: newOrders };\n }\n )\n try {\n setLoadingPut(true);\n await apiBolsa.post(\"/operation/donations\", { operations });\n message.success(\"Dados salvos com sucesso!\");\n } catch (err) {\n message.error(errorMessage);\n throw Error;\n } finally {\n navigate(`/${currentBroker?.path}/bolsa-historic`);\n setLoadingPut(false);\n }\n }, [doacoesHerancas, currentBroker, navigate]);\n\n const downloadOldTransactionsExcel = async () => {\n return await apiBolsa\n .get(\"/operation/download?month=12&year=2019\", {\n responseType: \"blob\",\n })\n .then((res) => {\n return res.data\n })\n .catch(() => {\n message.error(errorMessage);\n return null\n })\n }\n\n const downloadDoacoesHerancasExcel = async () => {\n return await apiBolsa\n .get(\"/operation/download/donations?operationType=Credito\", {\n responseType: \"blob\",\n })\n .then((res) => {\n return res.data\n })\n .catch(() => {\n message.error(errorMessage);\n return null\n })\n }\n\n const getOldTransactionsInit = useCallback(\n (setShowModalPrePreenchida?: (p: boolean) => void) => {\n setLoadingGet(true);\n apiBolsa\n .get(\"/operation?month=12&year=2019\", {})\n .then((response) => {\n setOldPositionList(\n response.data?.[0]?.orders.length\n ? response.data?.[0].orders.map((item: any) => ({\n ...item,\n avgBuyPrice: item.price,\n id: item._id,\n }))\n : []\n );\n setLoadingGet(false);\n })\n .catch(() => {\n setLoadingGet(false);\n setOldPositionList([]);\n message.error(errorMessage);\n })\n .finally(() => setShowModalPrePreenchida?.(false));\n },\n [setOldPositionList]\n );\n\n const getDoacoesHerancasInit = useCallback(\n (setShowModalPrePreenchida?: (p: boolean) => void) => {\n setLoadingGet(true);\n apiBolsa\n .get(\"/operation/donations?operationType=Credito\", {})\n .then((response) => {\n setDoacoesHerancas(response.data || []);\n setLoadingGet(false);\n })\n .catch(() => {\n setLoadingGet(false);\n setDoacoesHerancas([]);\n message.error(errorMessage);\n })\n .finally(() => setShowModalPrePreenchida?.(false));\n },\n [setDoacoesHerancas]\n );\n\n useEffect(() => {\n if (user?.user?.cpf) {\n getOldTransactionsInit();\n }\n }, [getOldTransactionsInit, initIntegration, user.user]);\n\n return (\n \n {children}\n \n );\n};\nexport const useOldTransactions = () => useContext(OldTransactionsContext);","import FileSaver from \"file-saver\";\nimport { message } from \"antd\";\n\nexport const handleDownloadSheet = async (buffer: any, title: string) => {\n try {\n const data = Uint8Array.from(buffer)\n const blob = new Blob([data], { type: 'attach.contentType' });\n FileSaver.saveAs(blob, `${title}.xlsx`);\n } catch (error: any) {\n message.error(error)\n }\n}\n","import { Table, Typography } from \"antd\";\nimport { DrawerModal } from \"../DrawerModal\";\nimport Button from \"../Button\";\nimport { useNavigate } from \"react-router-dom\";\n\ninterface ModalZeroBuyPrice {\n title?: string;\n visible?: boolean;\n dataZeroBuyPrice: any[];\n setModalZeroBuyPrice: Function;\n setIgnoreZeroBuyPrice: Function;\n}\n\nexport const ModalZeroBuyPrice: React.FC = ({\n title,\n visible,\n dataZeroBuyPrice,\n setModalZeroBuyPrice,\n setIgnoreZeroBuyPrice\n}) => {\n const navigate = useNavigate();\n\n return (\n setModalZeroBuyPrice(false)}\n >\n \n Neste mês, verificamos que alguns de seus ativos estão com custo de compra igual a zero.\n \n (\n {value}\n ),\n },\n {\n align: \"center\",\n title: \"Motivo\",\n dataIndex: \"reason\",\n render: (value) => (\n <>\n {value?.text ?\n <>\n {value?.text}\n { navigate(value?.link) }} target=\"_blank\" rel=\"noreferrer\">\n {\" \"} {value?.textLink} {\" \"}\n \n \n :\n <>\n Entre em contato através de\n \n {\" \"} suporte@velotax.com.br {\" \"}\n \n para avaliarmos a situação.\n \n }\n \n ),\n },\n ]}\n />\n {\n setIgnoreZeroBuyPrice(true);\n setModalZeroBuyPrice(false);\n }}\n >\n ESTOU CIENTE. EMITIR DARF, MESMO COM O CUSTO DE COMPRA ZERADO.\n \n \n )\n}","import clsx from \"clsx\";\nimport moment from \"moment\";\nimport { Button } from \"@mui/material\";\nimport { FaRegEdit } from \"react-icons/fa\";\nimport { BsCalendar3, BsDownload } from \"react-icons/bs\";\nimport { useLocation, useNavigate } from \"react-router-dom\";\nimport { GrFormNext, GrFormPrevious } from \"react-icons/gr\";\nimport { BiChevronLeft, BiChevronRight } from \"react-icons/bi\";\nimport {\n AiOutlineDelete,\n AiOutlineDownload,\n AiOutlineLock,\n} from \"react-icons/ai\";\nimport {\n LoadingOutlined,\n PlusOutlined,\n QuestionCircleOutlined,\n} from \"@ant-design/icons\";\nimport {\n ReactNode,\n useCallback,\n useEffect,\n useImperativeHandle,\n useMemo,\n useRef,\n useState,\n} from \"react\";\nimport {\n Col,\n Collapse,\n DatePicker,\n Descriptions,\n List,\n message,\n Modal,\n Row,\n Skeleton,\n Space,\n Spin,\n Tooltip,\n Typography,\n} from \"antd\";\nimport apis from \"../../services/apis\";\nimport apiBolsa from \"../../services/apiBolsa\";\nimport { Page } from \"../../constants/brokers\";\nimport AntButton from \"../../components/Button\";\nimport HandleTag from \"../../services/handleTag\";\nimport { useAuth } from \"../../contexts/AuthContext\";\nimport { FormModal } from \"../../components/FormModal\";\nimport { apiPayment } from \"../../services/apiPayment\";\nimport { useBroker } from \"../../contexts/BrokerContext\";\nimport { BackButton } from \"../../components/BackButton\";\nimport { PaymentModal } from \"../../components/PaymentModal\";\nimport { Container, Content, BolsaOperations } from \"./styles\";\nimport { historicoVendasEmptyText } from \"../../constants/darf\";\nimport { IntegrationModal } from \"../Darf/Components/IntegrationModal\";\nimport { useOldTransactions } from \"../../contexts/OldTransactionsContext\";\nimport DeleteConfirmationModal from \"../../components/DeleteConfirmationModal\";\nimport { DatePickerExtraFooter } from \"../Darf/Components/DatePickerExtraFooter\";\nimport {\n DatePickerMonthCell,\n YearResume,\n} from \"../Darf/Components/DatePickerMonthCell\";\nimport {\n DarfModal,\n DarfResultDescriptions,\n minDarfPrice,\n maxDarfPrice,\n IDarfBolsa,\n defaultDarfBolsa,\n DarfBolsaFormItemRows,\n PrejuFormItemRows,\n YearResumeStatusFromBackEnum,\n DarfBolsaTabs,\n IrrfFormItemRows,\n CorretagemFormItemRows,\n} from \"../../constants/darfBolsa\";\nimport {\n antDatePickerLocale,\n download,\n errorMessage,\n formatCurrency,\n getZeroBuyPrice,\n isMobile,\n monthsExtended,\n numberToPercentageWallet,\n} from \"../../utils\";\nimport { handleDownloadSheet } from \"../../utils/handleDownloadSheet\";\nimport { ModalZeroBuyPrice } from \"../../components/ModalZeroBuyPrice\";\n\ninterface DarfBolsaProps {\n item: Page;\n view?: boolean;\n viewEdit?: boolean;\n closeModal?: () => void;\n darf?: {\n id: string;\n fullPath?: string;\n };\n date?: {\n year?: number;\n month?: number;\n };\n darfBolsaRef: React.MutableRefObject;\n}\n\nexport const DarfBolsa: React.FC = ({\n view,\n item,\n date,\n darf,\n viewEdit,\n closeModal,\n darfBolsaRef,\n}) => {\n const navigate = useNavigate();\n const { state } = useLocation();\n const { oldPositionList } = useOldTransactions();\n const { currentBroker, currentPage } = useBroker();\n const {\n user,\n showUserPlanModal,\n userPlanModal,\n hasPlan: hasPremiumPlan,\n hasPermissionGeneral,\n } = useAuth();\n const today = new Date();\n const queryYear = (state as any)?.year as number;\n const queryMonth = (state as any)?.month as number;\n const currentMonth = today.getMonth();\n const currentYear = today.getFullYear();\n const [hasItems, sethasItems] = useState(false);\n const maxPixPayment = 10000;\n const maxCreditCardPayment = 10000;\n\n const initialMonth = queryMonth\n ? queryMonth - 1\n : today.getMonth() - 1 >= 0\n ? today.getMonth() - 1\n : 11;\n const initialYear = queryYear\n ? queryYear\n : today.getMonth() - 1 >= 0\n ? today.getFullYear()\n : today.getFullYear() - 1;\n const defaultValue = moment({ month: initialMonth, year: initialYear });\n const currentDate = moment({\n month: currentMonth,\n year: currentYear,\n }).subtract(1, \"M\");\n window.history.replaceState({}, document.title);\n\n const year = date?.year ?? initialYear;\n const month = date?.month ?? initialMonth;\n const currentDarfDate = new Date(year, month, 15)\n const dateAllowedOnBasic = new Date(today.getFullYear(), today.getMonth() - 1, 1)\n const hideOnBasic = (currentDarfDate.getTime() < dateAllowedOnBasic.getTime() && user.user?.userPlanInfoVelotax?.type?.includes('BASIC'))\n const hasPlan = (hasPremiumPlan || hasPermissionGeneral) && !hideOnBasic;\n\n\n const [asset, setAsset] = useState();\n const [, setYear] = useState(initialYear);\n const [, setMonth] = useState(initialMonth);\n const [loading, setLoading] = useState(false);\n const [emitting, setEmitting] = useState(false);\n const [darfModal, setDarfModal] = useState();\n const [helpModal, setHelpModal] = useState();\n const [paymentModal, setPaymentModal] = useState(false);\n const [dataToEditPreju, setDataToEditPreju] = useState();\n const [showAssetModal, setShowAssetModal] = useState(false);\n const [paymentData, setPaymentData] = useState();\n const [showDeleteModal, setShowDeleteModal] = useState(false);\n const [data, setData] = useState(defaultDarfBolsa);\n const [buffer, setBuffer] = useState>();\n const [yearResume, setYearResume] = useState([]);\n const [gettingYearResume, setGettingYearResume] = useState(false);\n const [datePickerYear, setDatePickerYear] = useState(initialYear);\n const [editedAccumulatedTax, setEditedAccumulatedTax] = useState(false);\n const [showNotAuthorizedModal, setShowNotAuthorizedModal] = useState(false);\n const [loadingDarfButton, setLoadingDarfButton] = useState(false);\n const [showEditPrejuConfirmation, setShowEditPrejuConfirmation] =\n useState(false);\n\n useImperativeHandle(darfBolsaRef, () => {\n return {\n editedAccumulatedTax,\n setEditedAccumulatedTax,\n handleDarf: (justSave?: boolean) => {\n handleDarf(justSave);\n },\n };\n });\n\n const isAntesTerceiroDiaUtil = () => {\n const today = moment();\n // Verifica se a data de hoje é um sábado\n if (today.isoWeekday() === 6) {\n return false;\n }\n // Verifica se a data de hoje é anterior ao terceiro dia útil\n const firstDayOfMonth = moment(today).startOf(\"month\");\n let businessDaysCount = 0;\n while (businessDaysCount < 2) {\n if (firstDayOfMonth.isoWeekday() < 6) {\n businessDaysCount++;\n }\n firstDayOfMonth.add(1, \"day\");\n }\n return today.isBefore(firstDayOfMonth);\n };\n\n const thirdBusinessDayAndMonth = (item: any) => {\n if (disableCurrentMonth(item))\n return { disabled: true, title: \"Aguarde o encerramento do mês para pagar seu DARF\" }\n else if (item.month + 1 == currentMonth && item.year == currentYear && isAntesTerceiroDiaUtil())\n return { disabled: true, title: \"Aguarde o terceiro dia útil deste mês para pagar seu DARF\" }\n else return { disabled: false, title: \"\" }\n }\n\n const hideOldPositionsText =\n oldPositionList?.length < 1 || oldPositionList === null;\n\n const valorPrincipal = Math.max(\n 0,\n Number(\n (data.impostoComumFinal || 0) +\n (data.impostoDTFinal || 0) +\n (data.impostoFIIFinal || 0)\n ) +\n (Number(data[\"impostoAcumulado\"] || 0) - Number(data[\"irrfTotal\"] || 0))\n );\n const impostoCharge = useMemo(() => {\n return (\n valorPrincipal +\n (valorPrincipal < minDarfPrice\n ? 0\n : (data.multaAux ?? 0) + (data.jurosAux ?? 0))\n );\n }, [data, valorPrincipal]);\n\n const transactionFeature = item.features[0];\n const taxFeature = item.features[1];\n const yearResumeFeature = item.features[2];\n const prejuizoFeature = item.features[3];\n const irrfFeature = item.features[4];\n\n const { emitted } = useMemo(() => {\n if (gettingYearResume) {\n }\n const monthResume = yearResume\n .find((resume) => resume.year === year)\n ?.months.find((m) => m.month - 1 === month);\n return {\n emitted:\n monthResume?.status === YearResumeStatusFromBackEnum.PAYED ||\n monthResume?.status === YearResumeStatusFromBackEnum.NOT_PAYED,\n payed: !!monthResume?.payed,\n status: monthResume?.status,\n };\n }, [yearResume, year, month, gettingYearResume]);\n\n const handleLabelButton: ReactNode = useMemo(() => {\n // if (!userPlanInfoStatus) return \"Assinar Plano Emissão de DARF\";\n\n if ((data?.impostoTotalFinal || 0) <= maxDarfPrice) return \"Pagar DARF\";\n else {\n if (emitted) return \"Emitir novo DARF\";\n else return taxFeature?.buttonLabel;\n }\n }, [data?.impostoTotalFinal, taxFeature?.buttonLabel, emitted]);\n\n const getDarf = useCallback(\n (id: string) => {\n view && setLoading(true);\n view &&\n (currentPage?.api || apis)\n .get(`${taxFeature.apiUrl}/${id}`)\n .then((response) => {\n setYear(response.data?.year);\n setMonth(response.data?.month - 1);\n setData({\n ...response.data,\n emitted: true,\n });\n })\n .catch((err) => {\n message.error(err.response?.data?.message || errorMessage);\n })\n .finally(() => setLoading(false));\n },\n [view, taxFeature.apiUrl, currentPage]\n );\n\n const getYearResume = useCallback(\n (year: number, force?: boolean, url?: string) => {\n setGettingYearResume(true);\n !view &&\n year <= new Date().getFullYear() &&\n year >= moment(`2020-01-01`).get(\"year\") &&\n (force ||\n (!yearResumeFeature.disabled &&\n !yearResume.find((resume) => resume.year === year))) &&\n (currentPage?.api || apis)\n .get(yearResumeFeature.apiUrl, { params: { year } })\n .then((response) => {\n const index = yearResume.findIndex(\n (resume) => resume.year === year\n );\n if (index >= 0) {\n setYearResume((yearResume) => {\n yearResume.splice(index, 1, response.data);\n return yearResume;\n });\n } else {\n setYearResume((yearResume) => [...yearResume, response.data]);\n }\n if (url && !isMobile()) {\n download(url);\n }\n })\n .catch((err) => console.log(err))\n .finally(() => setGettingYearResume(false));\n },\n [yearResumeFeature, yearResume, view, currentPage]\n );\n\n const getTaxes = useCallback(\n (\n nAtualizarDarfsPassadas?: boolean,\n nAtualizarIrrf?: boolean,\n atualizouImpostoAcumulado?: boolean,\n nAtualizarPrejuizosAcumulados?: boolean,\n atualizarTotalmente?: boolean,\n atualizouCorretagem?: boolean\n ) => {\n (!hasPlan || !view) && setLoading(true);\n (!hasPlan || !view) &&\n (currentPage?.api || apis)\n .get(transactionFeature.apiUrl, {\n params: {\n month: month + 1,\n year,\n nAtualizarDarfsPassadas: nAtualizarDarfsPassadas || false,\n nAtualizarIrrf: nAtualizarIrrf || false,\n atualizouImpostoAcumulado: atualizouImpostoAcumulado || false,\n nAtualizarPrejuizosAcumulados:\n nAtualizarPrejuizosAcumulados || false,\n atualizarTotalmente: atualizarTotalmente || false,\n atualizouCorretagem: atualizouCorretagem || false,\n },\n })\n .then((response) => {\n if (response.data.memoriaCalculo) {\n setData({\n ...response.data,\n multa: response.data.multaAux,\n juros: response.data.jurosAux,\n impostoDevido: response.data.impostoTotal,\n memoriaCalculo: response.data.memoriaCalculo.map(\n (memoCalc: any) => ({\n ...memoCalc,\n date: moment(memoCalc.date.slice(0, 10)).format(\n \"DD/MM/YYYY\"\n ),\n originalDate: memoCalc.date,\n market:\n memoCalc.market === \"Opção de Compra\" ||\n memoCalc.market === \"Opção de Venda\"\n ? \"Mercado de opções\"\n : memoCalc.market,\n })\n ),\n });\n }\n // setNotAuthorized(false);\n })\n .catch((err) => {\n setData(defaultDarfBolsa);\n if (err?.response?.data === \"NOT_AUTHORIZED\") {\n // setNotAuthorized(true);\n setShowNotAuthorizedModal(true);\n } else {\n // setNotAuthorized(false);\n message.error(errorMessage);\n }\n })\n .finally(() => setLoading(false));\n },\n [month, year, transactionFeature, view, hasPlan, currentPage]\n );\n\n const handleDarf = (justSave?: boolean) => {\n setEmitting(true);\n onCloseDarfModal();\n (currentPage?.api || apis)\n .post(taxFeature.apiUrl, {\n ...data,\n memoriaCalculo: [],\n transactions: data.memoriaCalculo,\n totalImpostoDevido: data.impostoTotalFinal,\n impostoDevido: data.impostoTotal,\n juros: data.jurosAux,\n multa: data?.multaAux,\n year,\n month: month + 1,\n name: user.user.name,\n insertPix: true,\n paymentInfo: {\n clientInfo: {\n name: user?.user?.name,\n email: user?.user?.email,\n document: user?.user?.cpf,\n },\n },\n justSave,\n payed: false,\n })\n .then((res) => {\n setData((data) => ({ ...data, emitted: true }));\n getYearResume(year, true, justSave ? \"\" : res.data.darfUrl);\n setEmitting(false);\n closeModal?.();\n if (!justSave) {\n message.success(\"O DARF foi enviado para o seu e-mail\");\n }\n })\n .catch((err) => {\n message.error(err.response?.data?.message || errorMessage);\n setEmitting(false);\n });\n };\n\n const handleRegularize = (regular: boolean) => {\n setEmitting(true);\n (currentPage?.api || apis)\n .post(\"transaction/regularize\", {\n year,\n month: month + 1,\n regular,\n impostoAcumulado:\n (data.impostoTotal ?? 0) + (data.impostoAcumulado ?? 0),\n })\n .then((res) => {\n getYearResume(year, true, res.data.darfUrl);\n getTaxes(false, false, false, true);\n message.success(\"Dados salvos\");\n closeModal?.();\n })\n .catch(() => message.error(errorMessage))\n .finally(() => setEmitting(false));\n };\n\n const onChangeMonth = (value: moment.Moment | null, dateString: string) => {\n const [month, year] = dateString.split(\"-\");\n setMonth(parseInt(month) - 1);\n setYear(parseInt(year));\n };\n\n const unsetAsset = () => {\n setAsset(undefined);\n };\n\n const handleCloseDeleteModal = () => {\n setShowDeleteModal(false);\n unsetAsset();\n };\n\n const handleCloseAssetModal = () => {\n setShowAssetModal(false);\n unsetAsset();\n };\n\n const onCloseHelpModal = () => {\n setHelpModal(undefined);\n };\n\n const onCloseDarfModal = () => {\n setDarfModal(undefined);\n };\n\n const handleOpenDarfModal = () => {\n setDarfModal(DarfModal(emitted, onCloseDarfModal, () => handleDarf()));\n };\n\n const handleOpenPaymentModal = () => {\n setPaymentModal(!paymentModal);\n };\n\n const handleAdd = (event: React.MouseEvent) => {\n event.stopPropagation();\n setShowAssetModal(true);\n };\n\n const handleEdit = (item: any, index: number) => {\n setShowAssetModal(true);\n setAsset({\n ...item,\n id: item._id,\n feeB3: item.fee,\n price: item.sellPrice,\n avgBuyPrice: item.buyPrice,\n data: moment.utc(item.date.toLocaleString()).format(\"DD/MM/YYYY\"),\n });\n };\n\n const handleRemove = (item: any, index: number) => {\n setShowDeleteModal(true);\n setAsset(item);\n };\n\n const addAsset = (asset: any) => {\n setLoading(true);\n (currentPage?.api || apis)\n .post(transactionFeature.apiUrl, {\n ...asset,\n operation: \"V\",\n avgSellPrice: asset.price,\n totalValue: asset.price * asset.quantity,\n })\n .then(() => {\n getTaxes(true, false, false, true, true);\n getYearResume(year, true);\n })\n .catch(() => message.error(errorMessage))\n .finally(() => {\n setLoading(false);\n handleCloseAssetModal();\n });\n };\n\n const editAsset = (asset: any) => {\n setLoading(true);\n (currentPage?.api || apis)\n .put(`${transactionFeature.apiUrl}/${asset.id}`, {\n ...asset,\n operation: \"V\",\n avgSellPrice: asset.price,\n totalValue: asset.price * asset.quantity,\n })\n .then(() => {\n getTaxes(true, false, false, true, true);\n getYearResume(year, true);\n })\n .catch(() => message.error(errorMessage))\n .finally(() => {\n setLoading(false);\n handleCloseAssetModal();\n });\n };\n\n const removeAsset = () => {\n setLoading(true);\n (currentPage?.api || apis)\n .delete(`${transactionFeature.apiUrl}/${asset.id ?? asset._id}`, {\n params: {\n year,\n month,\n },\n })\n .then(() => {\n getTaxes(true, false, false, true, true);\n getYearResume(year, true);\n })\n .catch(() => message.error(errorMessage))\n .finally(() => {\n setLoading(false);\n handleCloseDeleteModal();\n });\n };\n\n /* Manipular as tabs de imposto no mobile */\n const [tab, setTab] = useState(1);\n const bolsaOperationsRef = useRef(null);\n\n const handleNext = () => {\n setTab((tab) => tab + 1);\n const span = document.querySelector(\"div.sub-header > span.show\");\n bolsaOperationsRef.current?.scrollBy({ left: span?.clientWidth ?? 155 });\n };\n\n const handlePrev = () => {\n setTab((tab) => tab - 1);\n const span = document.querySelector(\"div.sub-header > span.show\");\n bolsaOperationsRef.current?.scrollBy({ left: -(span?.clientWidth ?? 155) });\n };\n /* Fim da manipulação das tabs de imposto no mobile */\n\n /* Editar prejuízo acumulado */\n const [resetedPreju, setResetedPreju] = useState(false);\n const [showPrejuModal, setShowPrejuModal] = useState(false);\n const [showCorretagemModal, setShowCorretagemModal] = useState(false);\n const [loadingResetPreju] = useState(false);\n const [loadingEditPreju, setLoadingEditPreju] = useState(false);\n const [ignoreZeroBuyPrice, setIgnoreZeroBuyPrice] = useState(false);\n const [dataZeroBuyPrice, setDataZeroBuyPrice] = useState([]);\n const [modalZeroBuyPrice, setModalZeroBuyPrice] = useState(false);\n\n const preju = useMemo(\n () => ({\n userPrejuizoComum: resetedPreju\n ? data.prejuizoComum\n : data.userPrejuizoComum ?? data.prejuizoComum,\n userPrejuizoDayTrade: resetedPreju\n ? data.prejuizoDayTrade\n : data.userPrejuizoDayTrade ?? data.prejuizoDayTrade,\n userPrejuizoFII: resetedPreju\n ? data.prejuizoFII\n : data.userPrejuizoFII ?? data.prejuizoFII,\n }),\n [data, resetedPreju]\n );\n\n const custoCorretagem = useMemo(\n () => ({\n userCustoCorretagemComum: data.userCustoCorretagemComum || 0,\n userCustoCorretagemDT: data.userCustoCorretagemDT || 0,\n userCustoCorretagemFII: data.userCustoCorretagemFII || 0,\n }),\n [data]\n );\n\n // const handleResetPreju = () => {\n // setResetedPreju(true);\n // };\n\n // const handleResetPreju = () => {\n // setLoadingResetPreju(true);\n // (currentPage?.api || apis)\n // .put(`${prejuizoFeature.apiUrl}/update-all?month=${month + 1}&year=${year}`)\n // .then(() => {\n // message.success('Prejuízos resetados com sucesso.');\n // getTaxes(false, false, false, true, true);\n // })\n // .catch(() => {\n // message.error(\"Não foi possível resetar os valores\");\n // })\n // .finally(() => {\n // setLoadingResetPreju(false);\n // handleClosePrejuModal();\n // });\n // };\n\n const handleEditPreju = () => {\n setResetedPreju(false);\n setShowPrejuModal(true);\n };\n\n const handleEditPrejuData = (preju: any) => {\n setDataToEditPreju(preju);\n setShowEditPrejuConfirmation(true);\n };\n\n const handleEditCorretagem = () => {\n setShowCorretagemModal(true);\n };\n\n const handleClosePrejuModal = () => {\n setShowPrejuModal(false);\n };\n\n const handleCloseCorretagemModal = () => {\n setShowCorretagemModal(false);\n };\n\n const editPreju = () => {\n setLoadingEditPreju(true);\n setShowEditPrejuConfirmation(false);\n\n (currentPage?.api || apis)\n .put(\n `${prejuizoFeature.apiUrl}?month=${month + 1}&year=${year}`,\n dataToEditPreju\n )\n .then((res) => {\n message.success(\"Dados salvos\");\n getTaxes(true, true, false, true);\n setLoadingEditPreju(false);\n handleClosePrejuModal();\n })\n .catch(() => {\n message.error(errorMessage);\n setLoadingEditPreju(false);\n handleClosePrejuModal();\n });\n };\n\n const editCorretagem = (data: any) => {\n handleCloseCorretagemModal();\n (currentPage?.api || apis)\n .put(\n `/warren/custoCorretagem?month=${month + 1}&year=${year}`,\n data\n )\n .then((res) => {\n message.success(\"Dados salvos\");\n getTaxes(true, true, false, true, false, true);\n })\n .catch(() => {\n message.error(errorMessage);\n });\n };\n /* Fim do editar prejuízo acumulado */\n\n /* Editar IRRF */\n const [showIrrfModal, setShowIrrfModal] = useState(false);\n\n const irrf = useMemo(\n () => ({\n userIrrfComum: data.irrfComum,\n userIrrfDayTrade: data.irrfDayTrade,\n userIrrfFII: data.irrfFII,\n userIrrfTotal: data.irrfTotal,\n }),\n [data]\n );\n\n // const handleResetIrrf = () => {\n // setResetedIrrf(true);\n // };\n\n const handleEditIrrf = () => {\n setShowIrrfModal(true);\n };\n\n const handleCloseIrrfModal = () => {\n setShowIrrfModal(false);\n };\n\n const editIrrf = (data: any) => {\n handleCloseIrrfModal();\n (currentPage?.api || apis)\n .put(`${irrfFeature.apiUrl}?month=${month + 1}&year=${year}`, data)\n .then((response) => {\n message.success(\"Dados salvos\");\n getTaxes(true, true, false, true);\n })\n .catch(() => {\n message.error(errorMessage);\n });\n };\n /* Fim do editar prejuízo acumulado */\n\n useEffect(() => {\n // if (month === 0) {\n getTaxes(true, true, false, true, false);\n // } else {\n // getTaxes(false, false, false, false, true);\n // }\n }, [getTaxes, month, year]);\n\n useEffect(() => {\n if (view && darf) {\n getDarf(darf.id);\n }\n }, [getDarf, view, darf]);\n\n useEffect(() => {\n getYearResume(year);\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n\n useEffect(() => {\n const dataToPayment = {\n ...data,\n year,\n month: month + 1,\n name: user.user.name,\n memoriaCalculo: [],\n transactions: data.memoriaCalculo,\n };\n\n setPaymentData(dataToPayment);\n }, [data.impostoTotalFinal, data, month, user.user.name, year]);\n\n useEffect(() => {\n if (data?.memoriaCalculo?.length > 0) sethasItems(!hideOnBasic);\n setBuffer(data?.buffer?.data);\n }, [data, hideOnBasic]);\n\n const handlePlanModal = () => {\n navigate('/planos')\n };\n\n useEffect(()=> {\n if (ignoreZeroBuyPrice) handleEventDarfButton();\n }, [ignoreZeroBuyPrice])\n\n const handleEventDarfButton = async () => {\n setLoadingDarfButton(true);\n let retPlanInfo = {\n data: {\n active: false,\n },\n };\n try {\n retPlanInfo = await apiPayment.get(\"/user-plan/plan-info\");\n } catch (err) {\n console.error(err);\n }\n setLoadingDarfButton(false);\n\n if (!ignoreZeroBuyPrice) {\n const hasZeroBuyPrice = await getZeroBuyPrice(data?.memoriaCalculo);\n if (hasZeroBuyPrice.length > 0) {\n setModalZeroBuyPrice(true);\n setDataZeroBuyPrice(hasZeroBuyPrice);\n return;\n }\n }\n\n //@ts-ignore\n !retPlanInfo.data.active && !retPlanInfo.data.cupomDueDate\n ? handlePlanModal()\n : handleOpenPaymentModal();\n };\n\n const handleSaveMonth = async () => {\n setLoadingDarfButton(true);\n try {\n const retPlanInfo = await apiPayment.get(\"/user-plan/plan-info\");\n\n retPlanInfo.data.active || hasPermissionGeneral\n ? handleDarf(true)\n : handlePlanModal();\n } catch (err) {\n console.error(err);\n }\n setLoadingDarfButton(false);\n };\n\n const downloadAction = (record: any) => {\n apiBolsa.get(`/darf/download/${record._id}`).then((res) => {\n if (res.data.url && !isMobile) {\n download(res.data.url);\n }\n });\n };\n\n const calcReturn = (\n sellPrice: number,\n buyPrice: number,\n quantity: number,\n fee: number\n ) => {\n const qtt = quantity ? quantity : 1;\n const ret =\n sellPrice && buyPrice\n ? (sellPrice * qtt - (fee || 0)) / (buyPrice * qtt) - 1\n : 0;\n return (\n = 0\n ? \"var(--velotax-green-amount)\"\n : \"var(--velotax-red-prejuizo)\"\n }`,\n }}\n >\n {ret ? numberToPercentageWallet(ret) : \"-\"}\n \n );\n };\n\n const disableCurrentMonth = (item: any) =>\n item.year === currentYear && item.month === currentMonth;\n\n return (\n \n \n \n \n \n \n \n {!view && !viewEdit && (\n <>\n {currentBroker.initialYear === year && month === 0 ? (\n
\n ) : (\n {\n if (month === 0) {\n setYear((year) => {\n const newYear = year - 1;\n getYearResume(newYear);\n setDatePickerYear(newYear);\n return newYear;\n });\n setMonth(11);\n } else {\n setMonth((month) => month - 1);\n }\n }}\n />\n )}\n \n )}\n {monthsExtended[month]} de {year}\n {!view && !viewEdit && (\n <>\n {currentYear === year && currentMonth - 1 === month ? (\n
\n ) : (\n {\n if (month === 11) {\n setYear((year) => {\n const newYear = year + 1;\n getYearResume(newYear);\n setDatePickerYear(newYear);\n return newYear;\n });\n setMonth(0);\n } else {\n setMonth((month) => month + 1);\n }\n }}\n />\n )}\n \n )}\n \n \n {!view && !viewEdit && (\n \n }\n defaultValue={defaultValue}\n locale={antDatePickerLocale}\n value={moment({ year: datePickerYear, month })}\n onSelect={(e) => {\n if (e.month() === month && year !== datePickerYear) {\n onChangeMonth(e, `${month + 1}-${datePickerYear}`);\n }\n }}\n onPanelChange={(e) => {\n getYearResume(e.year());\n setDatePickerYear(e.year());\n }}\n getPopupContainer={(trigger) => trigger.parentElement!}\n renderExtraFooter={() =>\n yearResumeFeature.disabled ? (\n <>\n ) : (\n \n )\n }\n disabledDate={(current) =>\n current &&\n (current > currentDate.endOf(\"month\") ||\n current < moment(`${currentBroker.initialYear}-01-01`) ||\n current < moment(`2020-01-01`))\n }\n monthCellRender={(e) => (\n \n )}\n />\n \n )}\n \n \n \n\n \n \n {hasPlan && view && darf?.fullPath && (\n \n \n {\n downloadAction(darf)\n }}\n startIcon={\n \n }\n >\n BAIXAR DARF\n \n \n \n )}\n \n {(!hasPlan || hideOnBasic) && (\n
\n \n Contrate o plano premium para ver os impostos devidos\n \n }\n onClick={() => {\n handlePlanModal();\n closeModal?.();\n }}\n >\n PREMIUM\n \n
\n )}\n {DarfBolsaTabs(data, {\n handleEditPreju,\n handleEditCorretagem,\n view,\n month,\n year,\n }).map((container, rowIndex) => (\n
\n {container.tabs.map((item, colIndex) => (\n 0 && colIndex > 0,\n }\n )}\n >\n {rowIndex === 0 && (\n }\n onClick={\n !hasPlan || colIndex === 0 || tab === 1\n ? undefined\n : handlePrev\n }\n style={{\n visibility:\n !hasPlan || colIndex === 0 || tab === 1\n ? \"hidden\"\n : \"visible\",\n }}\n />\n )}\n {!hasPlan && rowIndex > 0 && colIndex > 0\n ? formatCurrency(13443)\n : isMobile() && !hasPlan && rowIndex === 0\n ? \"\"\n : item.content}\n {rowIndex === 0 && (\n }\n onClick={\n !hasPlan || colIndex === 0 || tab === 3\n ? undefined\n : handleNext\n }\n style={{\n visibility:\n !hasPlan || colIndex === 0 || tab === 3\n ? \"hidden\"\n : \"visible\",\n }}\n />\n )}\n \n ))}\n
\n ))}\n
\n\n {/*
\n \n {!view && (\n \n )}\n
*/}\n\n
\n\n \n \n Vendas realizadas no mês\n \n }\n >\n {hasItems && (\n handleDownloadSheet(buffer, \"Vendas\")}\n style={{\n alignItems: \"center\",\n fontSize: \"13px\",\n paddingRight: \"0\",\n justifyContent: \"end\",\n backgroundColor: \"transparent\",\n color: \"#e02b57\",\n }}\n startIcon={\n \n }\n >\n Baixar planilha\n \n )}\n {!view && !hideOnBasic && (\n }\n >\n Adicionar\n \n )}\n \n new Date(b.originalDate).getTime() -\n new Date(a.originalDate).getTime()\n )}\n renderItem={(item, index) => (\n handleEdit(item, index)}\n icon={}\n />,\n handleRemove(item, index)}\n icon={}\n />,\n ]\n }\n >\n \n {item.code}}\n description={\n
\n
\n Data:{\" \"}\n {moment(item.date, [\n \"DD/MM/YYYY\",\n \"YYYY-MM-DD\",\n ]).format(\"DD/MM/YYYY\")}\n
\n
Quantidade: {item.quantity}
\n {view && (\n <>\n
\n Custo médio de compra:{\" \"}\n \n {formatCurrency(item.buyPrice)}\n \n
\n
\n Preço de venda:{\" \"}\n \n {formatCurrency(item.sellPrice)}\n \n
\n \n )}\n
\n Ganho:{\" \"}\n \n {formatCurrency(item.capitalGain)}\n \n
\n
\n Retorno:{\" \"}\n {calcReturn(\n item?.sellPrice,\n item?.buyPrice,\n item?.quantity,\n item?.fee\n )}\n
\n
\n }\n />\n
\n \n )}\n />\n \n \n\n {hasPlan &&
}\n\n {hasPlan && (\n \n Imposto total\n \n {loading ? (\n \n ) : (\n formatCurrency(impostoCharge)\n )}\n \n
\n )}\n\n {hasPlan && (\n \n {DarfResultDescriptions.map((description) => (\n \n {loading ? (\n \n ) : description.Component ? (\n \n ) : (\n formatCurrency(\n Number(data[description.id as keyof IDarfBolsa] || 0)\n )\n )}\n \n ))}\n \n )}\n\n {!view && !hideOnBasic && (\n <>\n \n {!(month === currentMonth && year === currentYear) &&\n valorPrincipal < minDarfPrice &&\n data?.memoriaCalculo?.length > 0 && (\n \n
\n \n O valor do imposto devido é menor que{\" \"}\n {formatCurrency(minDarfPrice)}. Você não precisa\n emitir um DARF para este mês.\n \n }\n >\n }\n // onClick={() => {\n // handleRegularize(true);\n // }}\n onClick={handleSaveMonth}\n >\n Salvar sem emitir DARF\n \n \n \n )}\n {valorPrincipal >= minDarfPrice && (\n \n
\n target.parentElement!}\n title={\n thirdBusinessDayAndMonth(date).title\n }\n >\n handleEventDarfButton()}\n startIcon={\n (emitting || loadingDarfButton) && \n }\n disabled={\n loading ||\n emitting ||\n loadingDarfButton ||\n thirdBusinessDayAndMonth(date).disabled\n }\n >\n {handleLabelButton}\n {\" \"}\n \n \n )}\n \n {!(month === currentMonth && year === currentYear) && (\n \n \n }\n >\n Salvar apenas\n \n \n \n )}\n \n )}\n\n {!view && (\n
\n
\n {!hideOldPositionsText && (\n

\n Você tinha investimentos em\n 31/12/2019 e ainda não preencheu o seu custo médio?{\" \"}\n \n navigate(`/${currentBroker.path}/bolsa-insert-manual`)\n }\n style={{\n cursor: \"pointer\",\n color: \"var(--ant-primary-color)\",\n }}\n >\n Clique aqui.\n \n

\n )}\n
\n {/*
\n

\n ({hideOldPositionsText ? 1 : 2}) A Receita Federal admite a\n dedução dos custos de corretagem na apuração do ganho líquido\n em operações de renda variável. Entretanto, não há\n obrigatoriedade do usufruto do benefício da dedução por parte\n dos investidores (Instrução Normativa RFB nº 1.585, de 31 de\n agosto de 2015, art. 56, § 3º). As informações advindas\n somente da integração com a B3 não consideram o benefício da\n dedução dos custos de corretagem da Warren, incluindo somente as\n tarifas de liquidação, registro, termo/opções e emolumentos da\n B3. Caso deseje descontar os seus custos de corretagem dos\n ganhos tributáveis, você pode adicionar manualmente as taxas\n de corretagem em cada operação no campo “Taxas” ou carregar\n suas\n \n navigate(\n item.settings?.integrationPath ??\n `/${currentBroker.path}/integration`\n )\n }\n style={{\n cursor: \"pointer\",\n color: \"var(--ant-primary-color)\",\n }}\n >\n {\" \"}\n notas de corretagem.\n \n

\n
*/}\n {/*
*/}\n {/*

\n ({hideOldPositionsText ? 2 : 3}) As taxas apresentadas incluem\n somente as tarifas de liquidação, registro, termo/opções e\n emolumentos da B3. Caso deseje, você pode adicionar manualmente as\n taxas de corretagem em cada operação.\n

*/}\n {/*
*/}\n {/*
\n

\n ({hideOldPositionsText ? 2 : 3}) Para preencher\n automaticamente os seus prejuízos acumulados, você deve salvar\n os meses na ordem do mais antigo para o mais recente.\n

\n
*/}\n {/*
\n

\n ({hideOldPositionsText ? 3 : 4}) O Usuário é\n exclusivamente responsável pela conferência e validação\n das informações utilizadas na apuração do imposto devido,\n conforme{\" \"}\n \n Termos e Condições Gerais de Uso.\n \n

\n
*/}\n
\n )}\n \n \n \n {helpModal?.content}\n \n\n { }}\n rows={[]}\n itemToEdit={null}\n visibility={showEditPrejuConfirmation}\n saveButtonText={\"Sim\"}\n title={\"Editar prejuízos\"}\n onCancel={() => setShowEditPrejuConfirmation(false)}\n >\n \n Você tem certeza que deseja editar os valores calculados de prejuízos\n acumulados?\n
\n \n\n \n {darfModal?.content}\n \n \n { }}\n edit={(data: any) => handleEditPrejuData(data)}\n itemToEdit={preju}\n loading={loadingEditPreju}\n disableButtons={loadingResetPreju || loadingEditPreju}\n rows={PrejuFormItemRows(loadingResetPreju || loadingEditPreju)}\n visibility={showPrejuModal}\n onCancel={handleClosePrejuModal}\n title=\"Editar prejuízos a compensar\"\n // preFormChildren={\n // }\n // style={{ display: \"flex\", margin: \"0 0 16px auto\" }}\n // >\n // Resetar valores\n // \n // }\n />\n\n { }}\n edit={editCorretagem}\n itemToEdit={custoCorretagem}\n rows={CorretagemFormItemRows(!!view)}\n visibility={showCorretagemModal}\n onCancel={handleCloseCorretagemModal}\n title=\"Taxas de corretagem\"\n hideFooter={view}\n >\n {/* \n \n \n \n Caso altere algum desses valores, você pode voltar aos valores\n calculados automaticamente pelo sistema (clique em aplicar e\n salvar):\n \n \n \n \n Prejuízo Comum:\n {formatCurrency(data.prejuizoComum ?? 0)}\n Prejuízo Day Trade:\n {formatCurrency(data.prejuizoDayTrade ?? 0)}\n Prejuízo FII:\n {formatCurrency(data.prejuizoFII ?? 0)}\n \n \n \n \n \n */}\n \n { }}\n edit={editIrrf}\n itemToEdit={irrf}\n rows={IrrfFormItemRows}\n visibility={showIrrfModal}\n onCancel={handleCloseIrrfModal}\n title=\"Editar IRRF\"\n >\n {/* \n \n \n \n Caso altere algum desses valores, você pode voltar aos valores\n calculados automaticamente pelo sistema (clique em aplicar e\n salvar):\n \n \n \n \n IRRF Comum:\n {formatCurrency(data.irrfComum ?? 0)}\n IRRF Day Trade:\n {formatCurrency(data.irrfDayTrade ?? 0)}\n IRRF FII:\n {formatCurrency(data.irrfFII ?? 0)}\n IRRF Total:\n {formatCurrency(data.irrfTotal ?? 0)}\n \n \n \n \n \n */}\n \n maxPixPayment}\n paymentData={{ ...paymentData, impostoTotalFinal: impostoCharge }}\n disableCreditCardOption={\n (data?.impostoTotalFinal || 0) > maxCreditCardPayment\n }\n callDarf={() => {\n HandleTag(\"64\");\n handleOpenDarfModal();\n }}\n />\n Promise.resolve(removeAsset())}\n body=\"Você realmente quer deletar esse ativo?\"\n />\n setShowNotAuthorizedModal(false)}\n />\n {!view && !viewEdit && (\n \n )}\n \n
\n \n );\n};\n","import { Modal } from \"antd\";\nimport styled from \"styled-components\";\n\nexport const Container = styled.div`\n display: flex;\n align-items: center;\n flex-direction: column;\n padding: 0 32px 128px;\n @media only screen and (max-device-width: 812px) {\n padding: 0 16px 128px;\n }\n`;\n\nexport const Content = styled.div`\n padding: 32px;\n min-width: 40vw;\n max-width: 500px;\n border-radius: 16px;\n background-color: var(--velotax-background-color);\n\n h2 {\n font-size: 24px;\n position: relative;\n color: var(--velotax-font-color);\n &::before {\n content: \"\";\n position: absolute;\n width: 4px;\n top: 0;\n left: -32px;\n height: 100%;\n background-color: var(--ant-primary-color);\n }\n }\n h3 {\n font-size: 20px;\n display: flex;\n align-items: center;\n column-gap: 8px;\n color: var(--velotax-font-color);\n }\n\n .ant-list.ant-list-split {\n margin-top: 24px;\n padding: 0 0 0 16px;\n background-color: var(--velotax-ghost);\n border: 1px solid var(--velotax-ghost);\n border-radius: 8px;\n .ant-list-item-meta-title,\n .ant-list-item-meta-description {\n color: var(--velotax-font-color);\n }\n .ant-list-item-meta-description {\n opacity: 0.75;\n }\n }\n .list-description {\n display: flex;\n flex-direction: column;\n }\n @media only screen and (max-device-width: 812px) {\n padding: 24px;\n h2 {\n &::before {\n left: -24px;\n }\n }\n }\n`;\n\nexport const ConfirmModal = styled(Modal)`\n .p {\n font-size: 16px;\n strong {\n font-weight: 500;\n color: var(--ant-primary-color);\n }\n }\n`;\n","import { Typography } from \"antd\";\nimport { RiMoneyDollarCircleLine, RiFileSearchLine } from \"react-icons/ri\";\nimport { YearReport } from \"../../constants/rendimentos\";\n\nexport const cards = [\n // {\n // id: \"irpf\",\n // icon: (\n // \n // ),\n // content: (\n // \n // Declaração IRPF\n //
\n // 2023 no Velotax\n //
\n // ),\n // },\n {\n id: \"anual-report\",\n icon: (\n \n ),\n content: RELATÓRIOS ANUAIS,\n description: (\n \n Relatórios auxiliares para preenchimento da DIRPF\n \n ),\n },\n {\n id: \"gain\",\n icon: (\n \n ),\n content: INFORMES DE GANHO DE CAPITAL,\n description: (\n \n Relatórios auxiliares para acompanhamento do ganho de capital (GCAP)\n \n ),\n },\n];\n","import styled from \"styled-components\";\n\nexport const ReportContainer = styled.div`\n height: 100%;\n display: flex;\n padding: 64px 32px;\n\n & > .content {\n margin: 0 auto;\n width: 700px;\n }\n\n h1 {\n width: 700px;\n margin: 0 auto 1.5rem;\n font-weight: 400;\n font-size: 2rem;\n position: relative;\n line-height: 2.5rem;\n padding-bottom: 1rem;\n color: var(--velotax-font-color-light);\n\n :after {\n content: \"\";\n position: absolute;\n left: 0;\n bottom: 0;\n height: 2px;\n width: 100px;\n background-color: var(--ant-primary-color);\n }\n }\n\n h3 {\n display: flex;\n align-items: center;\n column-gap: 16px;\n color: var(--velotax-font-color-light);\n margin-bottom: 0;\n }\n\n div.ant-typography {\n font-size: 1rem;\n line-height: 1.5rem;\n color: var(--velotax-font-color);\n }\n\n .ant-typography.destak {\n margin: 48px 0;\n display: block;\n font-weight: 700;\n font-size: 1rem;\n line-height: 1.5rem;\n color: var(--velotax-font-color);\n padding-left: 16px;\n border-left: 4px solid var(--ant-primary-color);\n }\n\n .cards {\n margin: 32px 0 0;\n padding-bottom: 32px;\n width: 100%;\n display: grid;\n row-gap: 1rem;\n column-gap: 1rem;\n grid-template-columns: repeat(2, 1fr);\n\n & > div {\n width: 100%;\n }\n\n .card-antd {\n position: relative;\n\n a {\n top: 0;\n left: 0;\n position: absolute;\n width: 100%;\n height: 100%;\n color: var(--velotax-font-color);\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n height: auto;\n padding: 24px 0 0;\n\n & > .content {\n width: 100%;\n h1 {\n width: 100%;\n padding: 0 24px 12px;\n margin: 0 auto 1.5rem;\n :after {\n left: 24px;\n }\n }\n\n & > div.ant-typography {\n padding: 0 24px;\n }\n }\n\n .cards {\n width: 100%;\n padding: 0 24px;\n margin: 32px 0;\n grid-template-columns: repeat(2, 1fr);\n\n & > div {\n width: auto;\n height: 240px;\n }\n }\n }\n`;\n\nexport const Container = styled.div`\n h1 {\n width: 700px;\n margin: 0 auto 1.5rem;\n font-weight: 400;\n font-size: 2rem;\n position: relative;\n line-height: 2.5rem;\n padding-bottom: 1rem;\n color: var(--velotax-font-color-light);\n\n :after {\n content: \"\";\n position: absolute;\n left: 0;\n bottom: 0;\n height: 2px;\n width: 100px;\n background-color: var(--ant-primary-color);\n }\n }\n\n h2.ant-typography {\n display: flex;\n align-items: center;\n column-gap: 8px;\n width: 700px;\n margin: 0 auto 1.5rem;\n font-size: 1rem;\n font-weight: 400;\n line-height: 1.5rem;\n color: var(--velotax-font-color-light);\n\n &.info {\n align-items: flex-start;\n font-size: 0.875rem;\n line-height: 1.125rem;\n opacity: 0.85;\n margin: 0 auto 2.5rem;\n svg {\n margin-top: 4px;\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n padding: 0;\n\n h1 {\n width: calc(100% - 48px);\n margin: 0 24px 1.5rem;\n padding: 24px 0 1rem;\n }\n\n h2.ant-typography {\n width: 100%;\n margin: 0 auto 1.5rem;\n padding: 0 24px;\n }\n }\n`;\n\nexport const Content = styled.div`\n padding: 32px;\n width: 700px;\n border-radius: 4px;\n background-color: var(--velotax-background-color);\n\n .ant-list.ant-list-split {\n margin: 24px 0 0;\n padding: 0 16px;\n background-color: var(--velotax-ghost);\n border: 1px solid var(--velotax-ghost);\n border-radius: 4px;\n .ant-list-item-action > li {\n padding: 0;\n }\n .ant-list-item-meta-description {\n opacity: 0.75;\n }\n .ant-list-item-action > li > button {\n font-size: 16px;\n color: var(--ant-primary-color);\n }\n .ant-list-item-meta-title,\n .ant-list-item-meta-description {\n font-size: 16px;\n color: var(--velotax-font-color-light);\n }\n .ant-list-item-action-split {\n opacity: 0;\n }\n }\n .historic-month-status {\n font-weight: 500;\n padding: 4px 8px;\n border-radius: 0;\n color: var(--black);\n display: flex;\n &.payed,\n &.regular {\n background-color: var(--ant-success-color);\n }\n &.pending {\n background-color: var(--ant-error-color);\n }\n &.not-payed {\n background-color: var(--ant-warning-color);\n }\n }\n .ant-btn.ant-btn-text {\n color: var(--ant-primary-color);\n }\n @media only screen and (max-device-width: 812px) {\n padding: 24px 24px 32px;\n border-radius: 0;\n width: 100%;\n .ant-list.ant-list-split {\n .ant-list-item-action {\n align-items: end;\n grid-template-rows: 1fr 0.75fr;\n grid-template-columns: 1fr 1fr;\n }\n }\n }\n`;\n","import { RiDownloadCloudLine } from \"react-icons/ri\";\nimport { Button as MaterialButton } from \"@mui/material\";\nimport { Link, useLocation, useNavigate } from \"react-router-dom\";\nimport { useCallback, useEffect, useMemo, useState } from \"react\";\nimport { InfoCircleOutlined, LoadingOutlined } from \"@ant-design/icons\";\nimport {\n Col,\n List,\n message,\n Modal,\n Row,\n Select,\n Skeleton,\n Typography,\n} from \"antd\";\nimport { cards } from \"./items\";\nimport apis from \"../../services/apis\";\nimport { Card } from \"../Exterior/Cards\";\nimport Button from \"../../components/Button\";\nimport { Page } from \"../../constants/brokers\";\nimport { useAuth } from \"../../contexts/AuthContext\";\nimport { UserPlanEnum } from \"../../constants/plans\";\nimport { useBroker } from \"../../contexts/BrokerContext\";\nimport { BackButton } from \"../../components/BackButton\";\nimport { ReportContainer, Container, Content } from \"./styles\";\nimport {\n download,\n errorMessage,\n getInitialYear,\n isMobile,\n monthsExtended,\n zero,\n} from \"../../utils\";\nimport api from \"../../services/apiBolsa\";\nimport { YearReport } from \"../../constants/rendimentos\";\nimport { DrawerModal } from \"../../components/DrawerModal\";\ninterface ReportProps {\n item: Page;\n}\n\nconst ReportAlertTitle = (\n \n {\" \"}\n \n Os relatórios estão disponíveis somente no plano premium.{\" \"}\n Contrate o seu plano.\n \n \n);\n\nexport const ReportBolsa: React.FC = ({ item }) => {\n const {\n user,\n showUserPlanModal,\n userPlanModal,\n hasPlan,\n ssoToken,\n hasPermissionGeneral,\n } = useAuth();\n const { state } = useLocation();\n const navigate = useNavigate();\n\n const today = new Date();\n const currentMonth = today.getMonth();\n const currentYear = today.getFullYear();\n const stateYear = (state as any)?.year;\n const initialYear = getInitialYear(currentYear, currentMonth);\n window.history.replaceState({}, document.title);\n\n const { currentPage } = useBroker();\n\n const [action, setAction] = useState();\n\n const [data, setData] = useState();\n const [infoModal, toggleModal] = useState(null);\n const [loading, setLoading] = useState(false);\n const [downloading, setDownloading] = useState(false);\n const [loadingLinks] = useState(false);\n const [year, setYear] = useState(stateYear ?? initialYear);\n\n const historicFeature = item.features[0];\n const downloadFeature = item.features[1];\n // const sendEmailFeature = item.features[2];\n\n const userPlanInfoStatus = useMemo(\n () => user.user?.userPlanInfoVelotax,\n [user.user?.userPlanInfoVelotax]\n );\n\n const yearOptions = Array.from(Array(initialYear - 2020 + 1))\n .map((y, i) => ({\n value: 2020 + i,\n label: `${2020 + i}`,\n }))\n .reverse();\n\n const onChangeYear = (value: string) => {\n setYear(parseInt(value));\n };\n\n const getHistoric = useCallback(() => {\n if (!action) return;\n if (action === \"anual-report\")\n return setData(\n Array.from(Array(new Date().getFullYear() - 2022))\n .map((y, i) => ({\n year: 2022 + i,\n label: `${2022 + i}`,\n }))\n .reverse()\n );\n\n setLoading(true);\n (currentPage?.api || apis)\n .get(historicFeature.apiUrl, { params: { year } })\n .then((response) => setData((response.data ?? []).reverse()))\n .catch(() => message.error(errorMessage))\n .finally(() => setLoading(false));\n }, [historicFeature, year, currentPage, action]);\n\n // const getDowloadLinks = useCallback(\n // (data: any[], action: string) => {\n // setLoadingLinks(true);\n // const dataLinks = data.map((item) =>\n // !!item._id\n // ? (currentPage?.api || apis).post(\n // `${downloadFeature.apiUrl}/${action}`,\n // {\n // id: item._id,\n // year: item.year,\n // month: item.month,\n // }\n // )\n // : Promise.resolve({ data: item })\n // );\n // Promise.allSettled(dataLinks).then((response) => {\n // setData(\n // response.map((item, index) =>\n // item.status === \"fulfilled\" && item.value.data?.file\n // ? {\n // ...data?.[index],\n // url: `data:application/pdf;base64,${item.value.data.file}`,\n // }\n // : data?.[index]\n // )\n // );\n // setLoadingLinks(false);\n // });\n // },\n // [currentPage, downloadFeature]\n // );\n\n // const sendDarfToEmail = (reportId: string) => {\n // (currentPage?.api || apis)\n // .get(`${sendEmailFeature.apiUrl}/${reportId}`)\n // .then(() => {\n // message.success(\"O DARF foi enviado para o seu e-mail\");\n // })\n // .catch((error) => {\n // console.log(error);\n // });\n // };\n\n const downloadAction = (record: any, Action?: string) => {\n const ACTION = Action || action;\n setDownloading(true);\n (currentPage?.api || apis)\n .post(`${downloadFeature.apiUrl}/${ACTION}`, {\n from: \"warren\",\n id: record._id,\n month: record.month,\n year: record.year,\n })\n .then((res) => {\n if (res.data.fileUrl && !isMobile()) {\n download(res.data.fileUrl);\n }\n if (res.data.file) {\n // downloadPDF(res.data.file);\n }\n message.success(\"Relatório enviado para o seu e-mail\");\n })\n .catch(({ response }) =>\n message.error(response?.data?.message ?? errorMessage)\n )\n .finally(() => {\n setDownloading(false);\n toggleModal(null);\n });\n };\n\n const checkProcessorAction = (record: any) => {\n setLoading(true);\n let showToast = false;\n toggleModal(record);\n const itvl = setInterval(() => {\n api\n .get(`${downloadFeature.apiUrl}/anual-report?year=${record.year}`)\n .then((res) => {\n const { data } = res;\n const { year, status } = data;\n const isProcessing = record.year === year && status === \"processing\";\n if (isProcessing && showToast) return;\n if (isProcessing && !showToast) {\n showToast = true;\n return message.success(\n \"O seu Informe de Rendimentos está em geração. Aguarde alguns minutos.\"\n );\n }\n setLoading(false);\n clearInterval(itvl);\n })\n .catch(({ response }) => {\n const { data, status } = response;\n if (status === 401)\n setTimeout(\n () => navigate(\"/warren/bolsa-integration\"),\n 2000\n );\n message.error(data?.message ?? errorMessage);\n setLoading(false);\n clearInterval(itvl);\n });\n }, 5000);\n };\n\n const handlePlanModal = () => {\n showUserPlanModal(!userPlanModal, ReportAlertTitle);\n };\n\n const handleActionButton = (id: string) => {\n if (!hasPlan) {\n handlePlanModal();\n } else {\n setAction(id);\n }\n };\n\n useEffect(() => {\n getHistoric();\n }, [getHistoric, year]);\n\n return (\n \n
\n Relatórios\n \n Confira os relatórios{\" \"}\n {action !== \"anual-report\" ? \"auxiliares\" : \"anuais\"} para a\n declaração do seu IR na bolsa de valores.\n \n\n {!action && (\n
\n {cards.map((item) => (\n \n ) : (\n item.icon\n )\n }\n onClick={() => !loading && handleActionButton(item.id)}\n >\n {item.id === \"irpf\" ? (\n <>\n \n {\" \"}\n \n {item.content}\n \n ) : (\n <>\n {item.content}\n {item.description && (\n
{item.description}
\n )}\n \n )}\n \n ))}\n
\n )}\n {!action && (\n \n )}\n {action && (\n \n \n Selecione o ano:\n {action !== \"anual-report\" && (\n \n )}\n \n action === \"anual-report\" ||\n item.year === year ||\n item.year === currentYear\n ) ?? []\n }\n itemLayout=\"horizontal\"\n renderItem={(item, index) => {\n const show2024Report = localStorage.getItem('show2024Report') === 'show';\n if ((item.year ===2025) && action === \"anual-report\" && !show2024Report) return <>\n // if ((item.year === 2024 || item.year ===2025) && action === \"anual-report\" && !show2024Report) return <>\n return \n action === \"anual-report\"\n ? checkProcessorAction(item)\n : downloadAction(\n item\n ) /*sendDarfToEmail(item._id)*/\n }\n download={`Relatório-${item.year}-${zero(\n item.month\n )}.pdf`}\n >\n Baixar\n {loadingLinks ? (\n \n ) : (\n \n )}\n ,\n ]}\n >\n \n \n \n \n }}\n />\n handleActionButton(\"\")}\n style={{ marginTop: \"1rem\" }}\n >\n Voltar\n \n \n \n )}\n {\n toggleModal(null);\n }}\n footer={false}\n >\n \n \n {\n if (!loading && !downloading) {\n downloadAction(infoModal, \"anual-report\");\n }\n }}\n >\n {loading || downloading ? (\n <>\n \n  {downloading ? \"Baixando\" : \"Gerando\"} informe\n \n ) : isMobile() ? (\n \"Enviar informe por email\"\n ) : (\n \"Baixar informe\"\n )}\n \n \n \n {\n if (!loading && !downloading) {\n navigate(\"/warren/bolsa-historic\");\n }\n }}\n >\n Ir para calculadora de DARF\n \n \n \n \n
\n
\n );\n};\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n display: flex;\n align-items: center;\n flex-direction: column;\n padding: 64px 32px 128px;\n @media only screen and (max-device-width: 812px) {\n padding: 0;\n }\n`;\nexport const Content = styled.div`\n padding: 32px;\n min-width: 40vw;\n max-width: 500px;\n border-radius: 16px;\n background-color: var(--velotax-background-color);\n\n h2 {\n font-size: 24px;\n position: relative;\n &::before {\n content: \"\";\n position: absolute;\n width: 4px;\n top: 0;\n left: -32px;\n height: 100%;\n background-color: var(--ant-primary-color);\n }\n }\n .last-update {\n letter-spacing: 1px;\n }\n div.ant-typography {\n font-size: 18px;\n }\n .ant-typography {\n color: var(--velotax-font-color);\n }\n @media only screen and (max-device-width: 812px) {\n padding: 24px;\n border-radius: 0;\n min-height: calc(100vh - 64px);\n h2 {\n &::before {\n left: -24px;\n }\n }\n }\n`;\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n .ant-list {\n padding: 0;\n border-radius: 4px;\n background-color: var(--velotax-background-color-ghost);\n .ant-list-item {\n padding: 16px;\n &.error-border {\n border: 1px solid var(--ant-error-color);\n }\n :first-child {\n border-radius: 4px 4px 0 0;\n }\n :last-child {\n border-radius: 0 0 4px 4px;\n }\n }\n .error-border + .error-border {\n border-top: none;\n }\n .ant-list-item-action > li {\n padding: 0;\n }\n }\n .ant-list-item-action > li,\n .ant-list-item-meta-title,\n .ant-list-item-meta-description {\n color: var(--velotax-font-color-light);\n }\n .ant-list-item-meta-description {\n opacity: 0.75;\n }\n\n .alert-icon {\n fill: var(--ant-error-color) !important;\n }\n\n .row-margin {\n margin-top: 24px;\n }\n`;\n","import { Button } from \"@mui/material\";\nimport { FaRegEdit } from \"react-icons/fa\";\nimport { Col, List, Row, Skeleton, Tooltip, Typography } from \"antd\";\nimport { Dispatch, SetStateAction, useEffect, useState } from \"react\";\nimport { AiOutlineDelete, AiOutlineInfoCircle } from \"react-icons/ai\";\nimport {\n LoadingOutlined,\n PlusCircleOutlined,\n DownloadOutlined,\n} from \"@ant-design/icons\";\nimport { Container } from \"./styles\";\nimport { formatCurrency } from \"../../../../utils\";\nimport AntButton from \"../../../../components/Button\";\nimport { FormModal } from \"../../../../components/FormModal\";\nimport { AddTransactionGOVFormItemRows } from \"../../../../constants/darfBolsa\";\n\nexport interface OldTransactionsProps {\n changed: boolean;\n loadingPut: boolean;\n loadingGet: boolean;\n setLoadingPut: Dispatch>;\n setLoadingGet: Dispatch>;\n oldPositionEdit: any;\n oldPositionList: any[];\n showAddPositionModal: boolean;\n downloadOldTransactionsExcel: () => Promise;\n setOldPositionEdit: Dispatch>;\n setShowAddPositionModal: Dispatch>;\n saveOldPositions: () => void;\n addOldPosition: (item: any) => void;\n editOldPosition: (item: any) => void;\n handleEditOldPosition: (item: any, index: number) => void;\n handleRemoveOldPosition: (item: any, index: number) => void;\n getOldTransactionsInit: () => void;\n}\n\nexport const OldTransactions: React.FC = ({\n loadingGet,\n loadingPut,\n oldPositionList,\n downloadOldTransactionsExcel,\n setOldPositionEdit,\n setShowAddPositionModal,\n handleEditOldPosition,\n handleRemoveOldPosition,\n addOldPosition,\n editOldPosition,\n showAddPositionModal,\n oldPositionEdit,\n}) => {\n const [hasLendingPosition, setHasLendingPosition] = useState(false);\n const [downloading, setDownloading] = useState(false);\n\n useEffect(() => {\n if (oldPositionEdit?._id || oldPositionEdit?.id) {\n if (oldPositionEdit?.lendingSide) {\n setHasLendingPosition(true);\n } else {\n setHasLendingPosition(false);\n }\n }\n }, [oldPositionEdit]);\n\n async function handleDownloadOldTransactions() {\n setDownloading(true);\n const file = await downloadOldTransactionsExcel();\n if (file) {\n const blob = new Blob([file], { type: \"xlsx\" });\n const element = document.createElement(\"a\");\n element.href = URL.createObjectURL(blob);\n element.download = \"carteira_31-12-19.xlsx\";\n document.body.appendChild(element);\n element.click();\n element.remove();\n }\n setDownloading(false);\n }\n\n return (\n \n \n \n \n Ativos em carteira\n \n \n \n \n {oldPositionList.length === 0 ? (\n
\n ) : (\n \n ) : (\n \n )\n }\n onClick={handleDownloadOldTransactions}>\n BAIXAR EXCEL\n \n )}\n {\n setOldPositionEdit({});\n setHasLendingPosition(false);\n setShowAddPositionModal(true);\n }}\n startIcon={\n loadingPut || loadingGet ? (\n \n ) : (\n \n )\n }>\n Adicionar Posição\n \n \n \n \n !oldPosition.lendingSide\n ) ?? []\n }\n renderItem={(item, index) => (\n \n \n }\n type=\"text\"\n />\n ,\n ]\n : []),\n }\n onClick={() => handleEditOldPosition(item, index)}\n />,\n }\n onClick={() => handleRemoveOldPosition(item, index)}\n />,\n ]}>\n \n {item.code}
}\n description={\n <>\n
\n
\n Quantidade: {item.quantity}\n
\n
\n Custo médio:{\" \"}\n {formatCurrency(item.price ?? 0)}\n
\n
\n \n }\n />\n \n \n )}\n />\n \n
\n \n \n Empréstimo de ativos\n \n \n \n ) : (\n \n )\n }\n onClick={() => {\n setOldPositionEdit({});\n setHasLendingPosition(true);\n setShowAddPositionModal(true);\n }}>\n Adicionar Posição\n \n \n \n oldPosition.lendingSide\n ) ?? []\n }\n renderItem={(item, index) => (\n \n \n }\n type=\"text\"\n />\n ,\n ]\n : []),\n }\n onClick={() => handleEditOldPosition(item, index)}\n />,\n }\n onClick={() => handleRemoveOldPosition(item, index)}\n />,\n ]}>\n \n {item.code}}\n description={\n <>\n
\n
\n Quantidade: {item.quantity}\n
\n
\n Custo médio:{\" \"}\n {formatCurrency(item.price ?? 0)}\n
\n
\n \n }\n />\n
\n \n )}\n />\n \n
\n\n {\n setShowAddPositionModal(false);\n setHasLendingPosition(false);\n }}\n title={\n oldPositionEdit?._id || oldPositionEdit?.id\n ? \"Editar ativo\"\n : \"Adicionar ativo\"\n }\n itemToEdit={\n oldPositionEdit.id || oldPositionEdit._id\n ? oldPositionEdit\n : undefined\n }\n />\n
\n );\n};\n","import { Typography } from \"antd\";\nimport { InfoCircleOutlined } from \"@ant-design/icons\";\nimport { BolsaManualData, Question } from \"./interfaces\";\nimport {\n OldTransactions,\n OldTransactionsProps,\n} from \"../Darf/Components/OldTransactions\";\n\nexport const validateBolsaManualData = (data: BolsaManualData) => {\n return true;\n};\n\nexport const questions: Question[] = [\n // {\n // id: \"possuiInvestimentosBolsa2019\",\n // title: \"Você tinha investimentos em 31/12/2019?\",\n // formItems: [\n // {\n // name: \"possuiInvestimentosBolsa2019\",\n // FormItem: () => (\n // \n // \n // Sim\n // Não\n // \n // \n // ),\n // },\n // ],\n // },\n {\n id: \"posicoesBolsa2019\",\n title: \"Complete sua carteira de 31/12/2019\",\n subTitle: (\n <>\n \n  A B3 armazena dados somente a partir de 2020. Por isso, você precisará preencher manualmente o custo médio dos\n seus investimentos em 31/12/2019. Você pode encontrar essas informações na sua Declaração de Imposto de Renda de 2019/2020.\n \n ),\n children: (\n \n Lembre-se de clicar em finalizar para salvar seus dados\n \n ),\n formItems: [\n {\n name: \"posicoesBolsa2019\",\n FormItem: ({ rest }) => (\n \n ),\n },\n ],\n },\n];\n","import styled from \"styled-components\";\n\nexport const BolsaManualContainer = styled.div`\n height: 100%;\n overflow-y: hidden;\n .btn-preencher-pos2019 {\n margin-bottom: 3rem;\n }\n`;\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n .ant-collapse {\n border: none;\n\n .ant-collapse-item {\n margin-bottom: 8px;\n border-radius: 4px;\n background-color: var(--velotax-ghost-white);\n border: 2px solid var(--velotax-ghost-white);\n &.ant-collapse-item-active {\n .ant-collapse-header {\n border-radius: 4px 4px 0 0;\n background-color: var(--velotax-background-color);\n .ant-typography {\n color: var(--ant-primary-color);\n button {\n svg {\n fill: var(--ant-primary-color);\n }\n }\n }\n }\n }\n &.ant-collapse-item-disabled {\n .ant-collapse-header {\n cursor: pointer;\n }\n }\n &.collapse-skip-btn {\n .ant-spin-nested-loading {\n width: 100%;\n }\n .ant-collapse-header {\n padding: 0;\n .collapse-skip-btn-content {\n padding: 24px 32px;\n }\n }\n }\n .ant-collapse-header {\n border-radius: 4px;\n padding: 24px 32px;\n background-color: var(--velotax-ghost-white);\n .ant-typography {\n width: 100%;\n display: flex;\n align-items: center;\n justify-content: space-between;\n font-size: 1rem;\n font-weight: bold;\n line-height: 32px;\n color: var(--velotax-font-color-dark);\n & > div {\n display: flex;\n align-items: center;\n }\n button {\n display: inline-flex;\n height: 32px !important;\n svg {\n width: 20px;\n height: 20px;\n fill: var(--velotax-font-color-dark);\n }\n }\n .opcao-recomendada {\n padding: 2px 4px;\n font-weight: 400;\n font-size: 0.75rem;\n line-height: 1rem;\n color: var(--white);\n white-space: nowrap;\n border-radius: 4px;\n display: flex;\n align-items: center;\n background-color: var(--ant-success-color);\n svg {\n margin-right: 4px;\n }\n }\n }\n .sub-title {\n font-size: 0.8125rem;\n color: var(--ant-primary-color);\n }\n }\n .ant-collapse-content {\n border: none;\n border-radius: 0 0 8px 8px;\n background-color: var(--velotax-background-color);\n .ant-collapse-content-box {\n padding: 16px 16px 32px;\n .ant-steps-item-title {\n margin-top: 0.25rem;\n /* font-size: 0.875rem; */\n line-height: 1.5rem;\n }\n .ant-btn {\n font-size: 14px;\n }\n }\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n .ant-collapse {\n .ant-collapse-item {\n &.collapse-skip-btn {\n .ant-collapse-header {\n .collapse-skip-btn-content {\n padding: 8px 16px;\n .ant-typography {\n font-size: 0.95rem;\n line-height: 1.25rem;\n flex-direction: column;\n align-items: flex-start;\n }\n .sub-title {\n margin-top: 4px;\n font-size: 0.75rem;\n }\n }\n }\n }\n .ant-collapse-header {\n padding: 8px 16px;\n .ant-typography {\n font-size: 0.95rem;\n line-height: 1.5rem;\n flex-direction: column;\n align-items: flex-start;\n }\n }\n }\n }\n }\n`;\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n .income-report-uploader {\n height: auto;\n display: block;\n margin-bottom: 16px;\n\n .ant-upload {\n width: 100%;\n height: 200px;\n\n .upload-text-icon {\n height: 100%;\n cursor: pointer;\n font-size: 20px;\n display: flex;\n align-items: center;\n flex-direction: column;\n justify-content: center;\n\n svg {\n fill: var(--ant-primary-color);\n }\n\n .upload-text-desc {\n font-size: 14px;\n text-align: center;\n }\n }\n\n .loading-container {\n height: 100%;\n display: flex;\n align-items: center;\n flex-direction: column;\n justify-content: center;\n\n .anticon {\n width: 40px;\n height: 40px;\n margin-bottom: 12px;\n\n svg {\n width: 100%;\n height: 100%;\n fill: var(--ant-primary-color);\n }\n }\n }\n }\n }\n`;\n","import React from \"react\";\nimport { Upload } from \"antd\";\nimport { UploadProps } from \"antd/lib/upload\";\nimport { LoadingOutlined } from \"@ant-design/icons\";\nimport { AiOutlineCloudUpload } from \"react-icons/ai\";\nimport { Container } from \"./styles\";\n\nexport interface IUploadProps extends UploadProps {\n loading?: boolean;\n descText?: string;\n customText?: string;\n tabIndex?:number;\n}\n\nconst UploadVelotax: React.FC = ({\n loading,\n descText,\n disabled,\n customText = \"Arraste ou clique\",\n ...props\n}) => {\n return (\n \n \n {loading ? (\n
\n \n Isso pode demorar alguns minutos, aguarde\n
\n ) : (\n
\n \n {customText}\n {descText && {descText}}\n
\n )}\n \n
\n );\n};\n\nexport default UploadVelotax;\n","import { message } from \"antd\";\nimport { RcFile } from \"antd/lib/upload\";\nimport { UploadRequestOption as RcCustomRequestOptions } from \"rc-upload/lib/interface\";\nimport {\n createContext,\n Dispatch,\n SetStateAction,\n useContext,\n useState\n} from \"react\";\nimport apiIrpf2023 from '../services/apiIrpf2023';\nimport { useOldTransactions } from \"./OldTransactionsContext\";\n\ninterface IUploadDecContext {\n loading: boolean;\n loadingSkip: boolean;\n confirmarModal: boolean;\n beforeUpload: (file: RcFile) => boolean;\n customRequest: (params: RcCustomRequestOptions) => void;\n setConfirmarModal: Dispatch>;\n}\n\nconst UploadDecContext = createContext({} as IUploadDecContext);\n\nexport const UploadDecProvider: React.FC = ({ children }) => {\n const [loading, setLoading] = useState(false);\n const [loadingSkip] = useState(false);\n const [confirmarModal, setConfirmarModal] = useState(false);\n const {getOldTransactionsInit} = useOldTransactions();\n\n const beforeUpload = (file: RcFile) => {\n const nameSplitted = file.name.split(\".\");\n const isDec = nameSplitted[nameSplitted.length - 1].toLowerCase() === \"dec\";\n\n if (!isDec) {\n message.error(\"Você só pode fazer upload de arquivos .dec\");\n }\n\n return isDec;\n };\n\n const customRequest = ({ file }: RcCustomRequestOptions) => {\n const formData = new FormData();\n formData.append(\"file\", file);\n setLoading(true);\n\n apiIrpf2023\n .post(\"/receitaFederal/processarDec2019IRPF\", formData)\n .then(async () => {\n message.success(\"Arquivo .dec importado com sucesso!\");\n let interval: NodeJS.Timeout | null = null;\n if (loading) {\n\n interval = setInterval( ()=>{\n\n apiIrpf2023.get(`/receitaFederal/checkStatusRecuperarDecIRPF`).then( ({data})=>{\n if(data?.processamantoDec2019){\n setLoading(false);\n getOldTransactionsInit();\n\n return clearInterval(interval as unknown as NodeJS.Timeout);\n }\n })\n\n },2000);\n }else {\n if (interval) {\n clearInterval(interval);\n }\n }\n setLoading(false);\n \n })\n .catch((err:any) => {\n const errorMessage =\n err.reponse?.message?.error ||\n \"Não foi possivel importar o arquivo .dec!\";\n message.error(errorMessage);\n setLoading(false);\n });\n };\n\n return (\n \n {children}\n \n );\n};\n\nexport const useUploadDec = () => useContext(UploadDecContext);","export default __webpack_public_path__ + \"static/media/govbr.16bc87af.svg\";","import styled from \"styled-components\";\nimport GovBrIcon from \"../../assets/govbr.svg\";\n\nexport const Container = styled.div`\n min-height: 100%;\n padding: 64px 32px;\n background-color: var(--velotax-ghost);\n\n @media only screen and (max-device-width: 812px) {\n padding: 0;\n background-color: var(--velotax-background-color);\n }\n`;\n\nexport const Content = styled.div`\n padding: 48px;\n width: fit-content;\n max-width: 720px;\n margin: 0 auto;\n border-radius: 16px;\n border: 1px solid var(--velotax-background-color-ghost);\n background-color: var(--velotax-background-color);\n\n h1 {\n display: flex;\n align-items: center;\n margin: 0 0 24px;\n font-size: 22px;\n line-height: 30px;\n font-weight: bold;\n position: relative;\n color: var(--velotax-font-color);\n\n .gov-logo {\n width: 64px;\n height: 40px;\n margin-left: 8px;\n display: inline-block;\n background-size: contain;\n background-position: center;\n background-repeat: no-repeat;\n background-image: url(${GovBrIcon});\n }\n\n button {\n display: inline-flex;\n height: 32px !important;\n svg {\n width: 20px;\n height: 20px;\n }\n }\n\n &::before {\n content: \"\";\n top: 0;\n width: 4px;\n left: -48px;\n height: 100%;\n position: absolute;\n background-color: var(--ant-primary-color);\n }\n }\n\n h5 {\n margin-bottom: 24px;\n }\n\n a.ant-btn.ant-btn-primary.ant-btn-lg {\n padding-top: 6.4px !important;\n }\n\n div.ant-typography {\n font-size: 1rem;\n }\n\n .upload-dec-info {\n margin: 24px 0 16px;\n font-weight: 500;\n font-size: 1.125rem;\n line-height: 1.5rem;\n color: var(--ant-primary-color);\n svg {\n width: 20px;\n height: 20px;\n margin: 0 0 -2px 4px;\n fill: var(--ant-primary-color);\n }\n }\n\n .ant-divider {\n margin: 24px 0 0;\n }\n\n .skip-btn {\n padding: 0;\n margin: 0 0 -16px auto;\n svg {\n margin: 0;\n }\n }\n\n \n\n .ant-steps {\n margin-top: 24px;\n .ant-steps-item:nth-of-type(3),\n .ant-steps-item:nth-of-type(4) {\n .ant-steps-item-container {\n .ant-steps-item-content {\n padding-bottom: 48px;\n }\n }\n }\n \n .ant-steps-item {\n \n &.ant-steps-item-wait {\n .ant-steps-item-title {\n opacity: 0.8;\n }\n }\n &.ant-steps-item-active {\n .ant-steps-item-title {\n background-color: red;\n font-weight: 500;\n color: var(--velotax-font-color) !important;\n }\n }\n .ant-steps-item-container {\n .ant-steps-item-content {\n padding-bottom: 24px;\n .ant-steps-item-title {\n }\n }\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n width: 100%;\n border: none;\n border-radius: 0;\n padding: 32px 24px 96px;\n h1 {\n font-size: 1.2rem;\n letter-spacing: -0.35px;\n .gov-logo {\n width: 58px;\n height: 38px;\n margin-left: 6px;\n }\n button {\n margin-top: -4px;\n height: 40px !important;\n }\n }\n .skip-btn {\n bottom: 24px;\n font-size: 13px;\n position: fixed;\n margin: 0;\n }\n }\n`;\n\nexport const DecUploadContent = styled.div`\n display: flex;\n align-items: center;\n flex-direction: column;\n justify-content: center;\n .dec-icon {\n width: 48px;\n height: 48px;\n font-size: 24px;\n margin: 0 0 16px;\n border-radius: 8px;\n color: var(--ant-primary-color);\n border: 2px solid var(--ant-primary-color);\n display: flex;\n position: relative;\n align-items: center;\n flex-direction: column;\n justify-content: center;\n svg {\n margin-top: -4px;\n }\n &:before {\n content: \"\";\n height: 2px;\n bottom: 8px;\n position: absolute;\n width: calc(100% - 24px);\n background-color: var(--ant-primary-color);\n }\n }\n span.ant-typography {\n font-size: 16px;\n font-weight: 500;\n max-width: 320px;\n color: var(--ant-primary-color);\n }\n`;\n","import { createContext, useContext, useState } from \"react\";\n\nexport const today = new Date();\n\nconst year = today.getFullYear();\n\nconst anoCalendario = year - 1;\n\ninterface IYearContext {\n year: number;\n currentMonth: number;\n anoCalendario: number;\n changeYear: (year: number) => void;\n}\n\nconst YearContext = createContext({} as IYearContext);\n\nexport const YearProvider: React.FC = ({ children }) => {\n const [Year, setYear] = useState(year);\n const [AnoCalendario, setAnoCalendario] = useState(anoCalendario);\n\n const changeYear = (year: number) => {\n setYear(year);\n setAnoCalendario(year - 1);\n };\n\n return (\n \n {children}\n \n );\n};\n\nexport const useYear = () => useContext(YearContext);","import { useState } from \"react\";\nimport { Divider, Steps, Typography } from \"antd\";\nimport { AiOutlineArrowRight } from \"react-icons/ai\";\nimport { LoadingOutlined, QuestionCircleOutlined } from \"@ant-design/icons\";\nimport Button from \"../../components/Button\";\nimport { Container, Content } from \"./styles\";\nimport { useEcac } from \"../../contexts/EcacContext\";\nimport { useYear } from \"../../contexts/YearContext\";\nimport apiIrpf2023 from '../../services/apiIrpf2023';\nimport { useOldTransactions } from \"../../contexts/OldTransactionsContext\";\n\n\ninterface DecPrepreenchidaProps {\n successCallback?: () => void;\n setShowModalPrePreenchida: (p:boolean) => void;\n}\n\nexport const DecPrepreenchidaContent: React.FC = ({\n\n setShowModalPrePreenchida\n}) => {\n const [currentStep,setCurrentStep] = useState(0);\n const [loading, setLoading] = useState(true);\n\n const {getOldTransactionsInit} = useOldTransactions();\n \n const programLink = \n process.env.REACT_APP_NODE_ENV === \"development\"\n ? \"https://velotax-programas.s3.amazonaws.com/posicao-2019-dev/velotax.msi\"\n : \"https://velotax-programas.s3.amazonaws.com/posicao-2019/velotax.msi\";\n\n return (\n \n \n {\n setCurrentStep(1);\n setCurrentStep(2);\n setLoading(true);\n let interval: NodeJS.Timeout | null = null;\n if (loading) {\n\n interval = setInterval( ()=>{\n\n apiIrpf2023.get(`/receitaFederal/checkStatusRecuperarDecIRPF`).then( ({data})=>{\n if(data?.processamantoDec2019){\n setLoading(false);\n setShowModalPrePreenchida(false);\n\n getOldTransactionsInit();\n // window.location.reload();\n\n return clearInterval(interval as unknown as NodeJS.Timeout);\n }\n })\n\n },1000);\n }else {\n if (interval) {\n clearInterval(interval);\n }\n }\n }}\n >\n Clique aqui\n {\" \"}\n {\"para baixar o arquivo de conexão\"}\n \n }\n />\n \n : ''}\n title={\n <>\n Execute o atalho Velotax no seu desktop, faça\n o login no gov.br e aguarde alguns minutos.\n \n }\n />\n \n )\n};\n\nexport const DecPrepreenchida = () => {\n const { year } = useYear();\n const { loadingEcac, handleSkipEcacStep, clearEcacInterval } =\n useEcac();\n\n return (\n \n \n \n Conecte sua conta \n }\n />\n \n\n \n Você terá acesso a sua declaração de IRPF {year} pré-preenchida\n \n\n \n {\n clearEcacInterval();\n await handleSkipEcacStep();\n // updateUserEcac();\n }}\n loading={loadingEcac.skipStep}\n disabled={loadingEcac.postLogin}\n >\n Não utilizar o gov.br \n {!loadingEcac.skipStep && }\n \n \n \n );\n};\n","import { useState } from \"react\";\nimport { Collapse, Spin, Typography, } from \"antd\";\nimport { QuestionCircleOutlined } from \"@ant-design/icons\";\nimport { AiOutlineArrowUp, AiOutlineCheck } from \"react-icons/ai\";\nimport { Container } from \"./styles\";\nimport { DrawerModal, DrawerModalProps } from \"../../components/DrawerModal\";\nimport Button from \"../../components/Button\";\nimport UploadVelotax from \"../../components/UploadVelotax\";\nimport { useUploadDec } from \"../../contexts/UploadDecContext\";\nimport { DecUploadContent } from \"../DecPrepreenchida/styles\";\nimport { DecPrepreenchidaContent } from \"../DecPrepreenchida\";\nimport { UploadRequestOption as RcCustomRequestOptions } from \"rc-upload/lib/interface\";\ninterface PrePreenchidaModalProps extends DrawerModalProps {\n setShowModalPrePreenchida: (b: boolean) => void;\n}\n\nexport const PrePreenchidaModal: React.FC = ({\n visible,\n setShowModalPrePreenchida,\n ...props\n}) => {\n const [showModal, setShowModal] = useState(true);\n const [loadingSkip] = useState(false);\n const { loading, beforeUpload, customRequest } = useUploadDec();\n\n const onCancel = () => {\n setShowModal(false);\n };\n\n return (\n \n \n \n Você pode conectar a sua conta gov.br ou carregar o arquivo DEC da sua\n declaração de 2019/2020. Selecione uma das opções abaixo:\n \n\n \n \n
\n \n Conecte sua conta gov.br\n \n }\n onClick={(e) => {\n e.stopPropagation();\n // openHelpDrawer();\n }}\n />\n
\n
\n \n Opção recomendada\n
\n \n }\n >\n \n \n \n \n\n \n
\n Carregue arquivo .DEC referente ao IR de 2019/2020\n }\n onClick={(e) => {\n e.stopPropagation();\n }}\n />\n
\n \n }\n >\n ) => {\n customRequest(params);\n setShowModalPrePreenchida(false);\n }}\n >\n \n
\n \n
\n \n Arraste aqui sua declaração do ano passado (formato .DEC)\n \n
\n \n \n
\n
\n \n );\n};\n","import styled, { css } from \"styled-components\";\n\nexport const Container = styled.div`\n height: calc(100vh - 64px);\n overflow: hidden;\n`;\n\nexport const QuestionContainer = styled.div<{ width?: string | number }>`\n display: flex;\n height: 100%;\n overflow-y: auto;\n align-items: center;\n flex-direction: column;\n h2 {\n font-size: 2rem;\n font-weight: 400;\n line-height: 2.5rem;\n position: relative;\n color: var(--velotax-text-color);\n margin: 64px auto 0;\n padding: 0 0 1rem;\n ${({ width }) =>\n width\n ? css`\n width: ${width} !important;\n `\n : \"\"}\n &::after {\n content: \"\";\n left: 0;\n bottom: 0;\n width: 100px;\n height: 2px;\n position: absolute;\n background-color: var(--ant-primary-color);\n }\n }\n\n @media only screen and (max-width: 812px) {\n padding: 32px 0 0;\n h2 {\n width: 100% !important;\n padding: 0 24px 12px;\n margin: 0;\n &::after {\n left: 24px;\n }\n }\n }\n`;\n\nexport const Question = styled.div<{ width?: string | number }>`\n height: fit-content;\n padding: 32px;\n margin: 24px 0 96px;\n border-radius: 4px;\n background-color: var(--velotax-background-color);\n border: 1px solid var(--velotax-background-color-ghost);\n ${({ width }) =>\n width\n ? css`\n width: ${width} !important;\n `\n : \"\"}\n h2 {\n font-size: 24px;\n padding-bottom: 12px;\n font-weight: 400;\n position: relative;\n color: var(--velotax-text-color);\n margin: 32px 0 0;\n &::after {\n content: \"\";\n left: 0;\n bottom: 0;\n width: 100px;\n height: 2px;\n position: absolute;\n background-color: var(--ant-primary-color);\n }\n }\n @media only screen and (min-width: 1025px) {\n width: 48%;\n }\n @media only screen and (max-width: 1024px) {\n width: 72% !important;\n padding: 32px;\n h2 {\n &::before {\n left: -32px;\n }\n }\n }\n @media only screen and (max-width: 812px) {\n width: 100% !important;\n padding: 24px 24px 48px;\n border: none;\n border-radius: 0;\n margin: 24px 0 0;\n h2 {\n padding: 0 0 12px;\n &::before {\n left: -24px;\n }\n }\n .ant-descriptions {\n .ant-descriptions-item-content {\n font-size: 12px;\n }\n .ant-descriptions-item-label {\n width: 30%;\n font-size: 12px;\n }\n }\n }\n`;\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n padding: 64px 32px 128px;\n @media only screen and (max-device-width: 812px) {\n padding: 0 0 64px;\n }\n &.view {\n padding: 0;\n }\n\n .juridic-messages-container {\n opacity: 0.8;\n padding: 32px;\n margin: 0 auto;\n max-width: 600px;\n border-radius: 16px;\n\n .message {\n display: flex;\n flex-direction: row;\n align-items: center;\n margin-bottom: 1rem;\n }\n\n p {\n font-size: 0.85rem;\n font-weight: 400;\n text-align: justify;\n line-height: 1.4;\n color: var(--velotax-font-color);\n margin-bottom: 0;\n margin-left: 0.5rem;\n\n i {\n font-weight: bold;\n color: var(--velotax-font-color);\n }\n }\n }\n`;\n\nexport const Content = styled.div`\n padding: 32px;\n &.view {\n padding: 0;\n }\n margin: 0 auto;\n max-width: 600px;\n border-radius: 16px;\n background-color: var(--velotax-background-color);\n h3 {\n display: flex;\n align-items: center;\n column-gap: 16px;\n color: var(--velotax-font-color);\n margin-bottom: 0;\n }\n .desc-label {\n display: flex;\n align-items: center;\n svg {\n fill: var(--ant-primary-color);\n }\n }\n .desc-content {\n display: flex;\n align-items: flex-start;\n justify-content: center;\n column-gap: 8px;\n svg {\n fill: var(--ant-primary-color);\n }\n span {\n align-self: center;\n }\n button {\n min-width: 32px;\n }\n }\n .ml-40 {\n margin-left: 40px;\n }\n .add {\n min-width: 128px;\n margin: 0 0 16px auto;\n }\n .ant-descriptions-item-label {\n width: 60%;\n }\n .ant-descriptions-item-content {\n text-align: center;\n }\n .ant-list.ant-list-split {\n padding: 0 16px;\n background-color: var(--velotax-ghost);\n border: 1px solid var(--velotax-ghost);\n border-radius: 8px;\n .ant-list-item-action > li {\n padding: 0;\n }\n }\n .ant-list-item-action > li,\n .ant-list-item-meta-title,\n .ant-list-item-meta-description {\n color: var(--velotax-font-color);\n }\n .ant-list-item-meta-description {\n opacity: 0.75;\n }\n .list-description {\n display: flex;\n flex-direction: column;\n }\n .min-darf-price {\n margin-top: 24px;\n display: flex;\n align-items: center;\n column-gap: 8px;\n }\n .text-center {\n display: block;\n text-align: center;\n }\n .ant-collapse-header {\n padding: 12px 0 !important;\n }\n .ant-collapse-content-box {\n padding: 16px 0 !important;\n }\n .ant-collapse\n > .ant-collapse-item\n > .ant-collapse-header\n .ant-collapse-arrow\n svg {\n transform: rotate(-90deg);\n }\n .ant-collapse-header-text {\n width: 100%;\n }\n .total-tax-header {\n width: calc(100% - 48px);\n display: flex;\n align-items: center;\n justify-content: space-between;\n h3 {\n margin: 0;\n }\n }\n\n h5 {\n margin: 0px;\n }\n\n @media only screen and (max-device-width: 812px) {\n padding: 24px;\n border-radius: 0;\n h3 {\n font-size: 18px;\n }\n .anticon.anticon-right.ant-collapse-arrow {\n top: 24px;\n }\n .desc-content {\n row-gap: 8px;\n flex-direction: column;\n button {\n width: 100%;\n }\n &.ml-40 {\n margin-left: 0;\n }\n }\n }\n`;\n\nexport const BolsaOperations = styled.div`\n display: grid;\n grid-template-columns: 2fr 1fr;\n border-radius: 8px;\n color: var(--velotax-font-color);\n background-color: var(--velotax-ghost);\n\n div.body-deducoes-tributarias {\n display: flex;\n flex-direction: column;\n padding: 0 8px;\n border-radius: 0 8px 8px 0;\n border: 1px solid var(--velotax-ghost);\n background-color: var(--velotax-background-color);\n span {\n height: 48px;\n display: flex;\n font-weight: 700;\n align-items: center;\n column-gap: 8px;\n }\n }\n\n div.header-deducoes-tributarias {\n display: flex;\n flex-direction: column;\n padding: 0 16px;\n border-radius: 8px 0 0 8px;\n background-color: var(--velotax-ghost);\n span {\n height: 48px;\n display: flex;\n font-weight: 700;\n align-items: center;\n column-gap: 8px;\n border-top: none;\n + span {\n border-top: 1px solid var(--velotax-background-color-ghost);\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n grid-template-columns: 1.6fr 1fr;\n span {\n font-size: 12px;\n button {\n max-width: 24px;\n min-width: 24px;\n }\n }\n }\n`;\n","import { Modal } from \"antd\";\nimport styled from \"styled-components\";\n\nexport const Container = styled.div`\n display: flex;\n align-items: center;\n flex-direction: column;\n padding: 64px 32px 128px;\n @media only screen and (max-device-width: 812px) {\n padding: 0;\n }\n`;\n\nexport const Content = styled.div`\n padding: 32px;\n min-width: 40vw;\n max-width: 500px;\n border-radius: 16px;\n background-color: var(--velotax-background-color);\n\n h2 {\n font-size: 24px;\n position: relative;\n color: var(--velotax-font-color);\n &::before {\n content: \"\";\n position: absolute;\n width: 4px;\n top: 0;\n left: -32px;\n height: 100%;\n background-color: var(--ant-primary-color);\n }\n }\n h3 {\n font-size: 20px;\n display: flex;\n align-items: center;\n column-gap: 8px;\n color: var(--velotax-font-color);\n }\n\n .ant-list.ant-list-split {\n margin-top: 24px;\n padding: 0 0 0 16px;\n background-color: var(--velotax-ghost);\n border: 1px solid var(--velotax-ghost);\n border-radius: 8px;\n .ant-list-item-meta-title,\n .ant-list-item-meta-description {\n color: var(--velotax-font-color);\n }\n .ant-list-item-meta-description {\n opacity: 0.75;\n }\n }\n .list-description {\n display: flex;\n flex-direction: column;\n }\n @media only screen and (max-device-width: 812px) {\n padding: 24px 24px 128px;\n border-radius: 0;\n h2 {\n &::before {\n left: -24px;\n }\n }\n }\n`;\n\nexport const ConfirmModal = styled(Modal)`\n .p {\n font-size: 20px;\n strong {\n font-weight: 500;\n color: var(--ant-primary-color);\n }\n }\n`;\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n padding: 64px 32px 128px;\n\n h2.ant-typography {\n display: flex;\n align-items: center;\n column-gap: 8px;\n width: 700px;\n margin: 0 auto 1.5rem;\n font-size: 1rem;\n font-weight: 400;\n line-height: 1.5rem;\n color: var(--velotax-font-color-light);\n\n &.info {\n align-items: flex-start;\n font-size: 0.875rem;\n line-height: 1.125rem;\n opacity: 0.85;\n margin: 0 auto 2.5rem;\n svg {\n margin-top: 4px;\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n padding: 0;\n\n h2.ant-typography {\n width: 100%;\n margin: 0 auto 1.5rem;\n padding: 0 24px;\n }\n }\n`;\n\nexport const Content = styled.div`\n padding: 32px;\n margin: 0 auto;\n width: 700px;\n border-radius: 4px;\n background-color: var(--velotax-background-color);\n\n /* .ant-list.ant-list-split {\n margin: 24px 0 0;\n padding: 0 16px;\n background-color: var(--velotax-ghost);\n border: 1px solid var(--velotax-ghost);\n border-radius: 4px;\n .ant-list-item-action > li {\n padding: 0;\n }\n .ant-list-item-meta-description {\n opacity: 0.75;\n }\n .ant-list-item-action > li,\n .ant-list-item-meta-title,\n .ant-list-item-meta-description {\n color: var(--velotax-font-color);\n }\n .ant-list-item-action-split {\n opacity: 0;\n }\n } */\n @media only screen and (max-device-width: 812px) {\n width: 100%;\n padding: 24px;\n border-radius: 0;\n /* .ant-list.ant-list-split {\n .ant-list-item-action {\n display: grid;\n align-items: end;\n grid-template-rows: 1fr 0.75fr;\n grid-template-columns: 1fr 1fr;\n }\n } */\n }\n`;\n\nexport const BottomAdvice = styled.div`\n margin-top: 40px;\n width: 700px;\n\n line-height: 24px;\n\n @media only screen and (max-device-width: 812px) {\n width: 100%;\n padding: 24px;\n }\n`;\n\nexport const AttentionIconContainer = styled.div`\n position: relative;\n display: inline;\n margin-right: 3px;\n width: 14px;\n\n & svg {\n position: relative;\n top: 2px;\n }\n`;","import moment from \"moment\";\nimport { message } from \"antd\";\nimport { useNavigate, useLocation } from \"react-router-dom\";\nimport {\n createContext,\n useCallback,\n useContext,\n useEffect,\n useState,\n} from \"react\";\nimport { useAuth } from \"./AuthContext\";\nimport { errorMessage } from \"../utils\";\nimport apiExterior from \"../services/apiExterior\";\nimport { useBroker } from \"./BrokerContext\";\n\ntype LoadingOperation = \"get\" | \"put\" | \"delete\";\n\ntype Loading = {\n get: boolean;\n put: boolean;\n delete: boolean;\n};\n\ninterface Ativo {\n id: string;\n codigo: string;\n quantidade: number;\n dataCompra?: string;\n valorCompraUSDOrigemBRA?: number;\n valorCompraUSDOrigemEUA?: number;\n orderId: string;\n type: string;\n}\n\ninterface ITransferenciaCustodiaContext {\n ativo?: Ativo;\n ativos: Ativo[];\n loading: Loading;\n getAtivos: any;\n showFormModal: boolean;\n showDeleteModal: boolean;\n closeFormModal: () => void;\n closeDeleteModal: () => void;\n handleAdd: () => void;\n handleEdit: (item: Ativo, index: number) => void;\n handleRemove: (item: Ativo, index: number) => void;\n add: (item: Ativo) => void;\n edit: (item: Ativo) => void;\n remove: (item: Ativo) => void;\n saveAtivos: () => void;\n isInvalidItem: (item: Ativo) => boolean;\n}\n\nexport const TransferenciaCustodiaContext =\n createContext(\n {} as ITransferenciaCustodiaContext\n );\n\nexport const TransferenciaCustodiaProvider: React.FC = ({ children }) => {\n const { user } = useAuth();\n const { currentBroker } = useBroker();\n const navigate = useNavigate();\n const { pathname } = useLocation();\n const [ativo, setAtivo] = useState();\n const [ativos, setAtivos] = useState([]);\n const [indexAtivo, setIndexAtivo] = useState(-1);\n const [redirected, setRedirected] = useState(false);\n const [showFormModal, setShowFormModal] = useState(false);\n const [showDeleteModal, setShowDeleteModal] = useState(false);\n const [loading, setLoading] = useState({\n get: false,\n put: false,\n delete: false,\n });\n\n const isInvalidItem = (item: Ativo) =>\n !item.dataCompra ||\n (!item.valorCompraUSDOrigemBRA && !item.valorCompraUSDOrigemEUA);\n\n const handleLoading = (operation: LoadingOperation, value: boolean) => {\n setLoading((loading) => ({ ...loading, [operation]: value }));\n };\n\n const closeFormModal = () => {\n setShowFormModal(false);\n setAtivo(undefined);\n setIndexAtivo(-1);\n };\n\n const closeDeleteModal = () => {\n setShowDeleteModal(false);\n setAtivo(undefined);\n setIndexAtivo(-1);\n };\n\n const handleAdd = () => {\n setShowFormModal(true);\n };\n\n const handleEdit = (item: Ativo, index: number) => {\n setShowFormModal(true);\n setIndexAtivo(index);\n const dataCompra = !item.dataCompra\n ? \"\"\n : item.dataCompra.includes(\"/\")\n ? item.dataCompra\n : moment.utc(item.dataCompra)?.format(\"DD/MM/YYYY\");\n setAtivo({\n ...item,\n dataCompra,\n });\n };\n\n const handleRemove = (item: Ativo, index: number) => {\n setShowDeleteModal(true);\n setIndexAtivo(index);\n setAtivo(item);\n };\n\n const getAtivos = useCallback(() => {\n handleLoading(\"get\", true);\n apiExterior\n .get(\"/warren/custodia\")\n .then(({ data }) => {\n setAtivos(data || []);\n closeFormModal();\n })\n .catch(() => {\n message.error(errorMessage);\n })\n .finally(() => {\n handleLoading(\"get\", false);\n });\n }, []);\n\n const saveAtivos = () => {\n handleLoading(\"put\", true);\n apiExterior\n .post(\"/warren/custodia\", ativos)\n .then(({ data }) => {\n setAtivos(data ?? []);\n navigate(\"/warren/exterior-historic\");\n })\n .catch(() => {\n message.error(errorMessage);\n })\n .finally(() => {\n handleLoading(\"put\", false);\n });\n };\n\n const add = (item: Ativo) => {\n setAtivos((ativos) => [...ativos, item]);\n closeFormModal();\n };\n\n const edit = (item: Ativo) => {\n setAtivos((ativos) =>\n ativos.map((ativo, index) =>\n index === indexAtivo ? { ...item, type: ativo.type } : ativo\n )\n );\n closeFormModal();\n };\n\n const remove = () => {\n setAtivos((ativos) =>\n ativos.filter((ativo, index) => index !== indexAtivo)\n );\n closeDeleteModal();\n };\n\n useEffect(() => {\n if (\n !redirected &&\n pathname.includes(\"exterior\") &&\n ativos.filter((item: Ativo) => isInvalidItem(item)).length > 0\n ) {\n navigate(\"/warren/transferencia-custodia\");\n setRedirected(true);\n }\n }, [pathname, navigate, ativos, redirected]);\n\n useEffect(() => {\n if (user.user && currentBroker.useTransferenciaCustodia) {\n getAtivos();\n }\n }, [user.user, currentBroker.useTransferenciaCustodia, getAtivos]);\n\n return (\n \n {children}\n \n );\n};\n\nexport const useTransferenciaCustodia = () =>\n useContext(TransferenciaCustodiaContext);\n","import { message } from \"antd\";\nimport { useRef, useState } from \"react\";\nimport { useNavigate } from \"react-router-dom\";\nimport Upload, { RcFile } from \"antd/lib/upload\";\nimport {\n UploadFile,\n UploadFileStatus,\n UploadProps,\n} from \"antd/lib/upload/interface\";\nimport apiBolsa from \"../../../services/apiBolsa\";\nimport apiExterior from \"../../../services/apiExterior\";\nimport { useTransferenciaCustodia } from \"../../../contexts/TransferenciaCustodiaContext\";\n\nconst isValidFile = (file: UploadFile) => file.type === \"application/pdf\";\nconst sameNameFile = (file: UploadFile, files: UploadFile[]) =>\n files.findIndex((item) => item.name === file.name) >= 0;\n\nexport const useNotasCorretagem = () => {\n const navigate = useNavigate();\n const sameNameFiles = useRef([]);\n const [loadingSend, setLoadingSend] = useState(false);\n const [notas, setNotas] = useState[]>([]);\n const [showNotasCorretagemModal, setShowNotasCorretagemModal] =\n useState(false);\n\n const { getAtivos } = useTransferenciaCustodia();\n\n const beforeUploadNota = (file: RcFile) => {\n if (!isValidFile(file)) {\n message.error(\"Você só pode fazer upload de arquivos pdf\");\n return Upload.LIST_IGNORE;\n }\n if (sameNameFile(file, notas)) {\n sameNameFiles.current.push(file.name);\n message.error(\"Este arquivo já foi adicionado\");\n return Upload.LIST_IGNORE;\n }\n };\n\n const onChangeNotas = ({\n file,\n fileList,\n }: {\n file: UploadFile;\n fileList: UploadFile[];\n }) => {\n if (file && file.status === \"removed\") return;\n if (!isValidFile(file)) return;\n if (sameNameFiles.current.includes(file.name)) {\n sameNameFiles.current = sameNameFiles.current.filter(\n (name) => name !== file.name\n );\n return;\n }\n setNotas(\n fileList\n .filter((file) => file.status !== \"removed\")\n .map((file) => ({ ...file, status: \"done\" as UploadFileStatus }))\n );\n };\n\n const onRemoveNota = (file: UploadFile) => {\n setNotas((notas) => notas.filter((nota) => nota.uid !== file.uid));\n };\n\n const sendNotas = () => {\n const formData = new FormData();\n notas.forEach((nota) => {\n formData.append(\"files\", nota.originFileObj as File);\n });\n setLoadingSend(true);\n apiBolsa\n .post(\"/brokerage-notes/read\", formData)\n .then(() => {\n message.success(\"Informações extraídas com sucesso\");\n navigate(\"/warren/bolsa-historic\");\n })\n .catch((err) => {\n const errorMessage =\n err.reponse?.message?.error || \"Não foi possivel extrair informações\";\n message.error(errorMessage);\n })\n .finally(() => {\n setLoadingSend(false);\n });\n };\n\n const sendNotasCustodyTransfer = (setLoadingSend: any, setShowNotasCorretagemModal: any) => {\n const formData = new FormData();\n notas.forEach((nota) => {\n formData.append(\"files\", nota.originFileObj as File);\n });\n setLoadingSend(true);\n apiExterior\n .post(\"/warren/custodia/notes\", formData)\n .then(() => {\n message.success(\"Informações extraídas com sucesso\");\n })\n .catch((err) => {\n const errorMessage =\n err.reponse?.message?.error || \"Não foi possivel extrair informações\";\n message.error(errorMessage);\n })\n .finally(() => {\n getAtivos();\n setShowNotasCorretagemModal(false);\n setLoadingSend(false);\n });\n };\n\n const uploadProps: UploadProps = {\n fileList: notas,\n multiple: true,\n listType: \"text\",\n accept: \"application/pdf\",\n onRemove: onRemoveNota,\n onChange: onChangeNotas,\n beforeUpload: beforeUploadNota,\n customRequest: () => {},\n showUploadList: {\n showRemoveIcon: true,\n showPreviewIcon: false,\n showDownloadIcon: false,\n },\n };\n\n return {\n sendNotas,\n loadingSend,\n sendNotasCustodyTransfer,\n uploadProps,\n showNotasCorretagemModal,\n setShowNotasCorretagemModal,\n };\n};\n","import { Typography } from \"antd\";\nimport {\n RiMoneyDollarCircleLine,\n RiHandCoinLine,\n RiFileSearchLine,\n} from \"react-icons/ri\";\nimport { YearReport } from \"../../constants/rendimentos\";\n\nexport const cards = [\n // {\n // id: \"irpf\",\n // icon: (\n // \n // ),\n // content: (\n // \n // Declaração IRPF\n //
\n // 2023 no Velotax\n //
\n // ),\n // },\n {\n id: \"anual-report\",\n icon: (\n \n ),\n content: Relatórios anuais,\n description: (\n \n Relatório auxiliar para preenchimento da DIRPF\n \n ),\n },\n {\n id: \"gain\",\n icon: (\n \n ),\n content: INFORMES DE GANHO DE CAPITAL,\n description: (\n \n Relatórios auxiliares para acompanhamento do ganho de capital (GCAP)\n \n ),\n },\n {\n id: \"income\",\n icon: (\n \n ),\n content: INFORMES DE DIVIDENDOS,\n description: (\n \n Relatórios auxiliares para acompanhamento dos dividendos recebidos no\n exterior (carnê-leão)\n \n ),\n },\n];\n","import styled from \"styled-components\";\n\nexport const ReportContainer = styled.div`\n height: 100%;\n display: flex;\n padding: 64px 32px;\n\n & > .content {\n margin: 0 auto;\n width: 700px;\n }\n\n h1 {\n width: 700px;\n margin: 0 auto 1.5rem;\n font-weight: 400;\n font-size: 2rem;\n position: relative;\n line-height: 2.5rem;\n padding-bottom: 1rem;\n color: var(--velotax-font-color-light);\n\n :after {\n content: \"\";\n position: absolute;\n left: 0;\n bottom: 0;\n height: 2px;\n width: 100px;\n background-color: var(--ant-primary-color);\n }\n }\n\n h3 {\n display: flex;\n align-items: center;\n column-gap: 16px;\n color: var(--velotax-font-color-light);\n margin-bottom: 0;\n }\n\n div.ant-typography {\n font-size: 1rem;\n line-height: 1.5rem;\n color: var(--velotax-font-color);\n }\n\n .ant-typography.destak {\n margin: 48px 0;\n display: block;\n font-weight: 700;\n font-size: 1rem;\n line-height: 1.5rem;\n color: var(--velotax-font-color);\n padding-left: 16px;\n border-left: 4px solid var(--ant-primary-color);\n }\n\n .cards {\n margin: 32px 0 0;\n padding-bottom: 32px;\n width: 100%;\n display: grid;\n row-gap: 1rem;\n column-gap: 1rem;\n grid-template-columns: repeat(2, 1fr);\n\n & > div {\n width: 100%;\n }\n\n .card-antd {\n position: relative;\n\n a {\n top: 0;\n left: 0;\n position: absolute;\n width: 100%;\n height: 100%;\n color: var(--velotax-font-color);\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n height: auto;\n padding: 24px 0 0;\n\n & > .content {\n width: 100%;\n h1 {\n width: 100%;\n padding: 0 24px 12px;\n margin: 0 auto 1.5rem;\n :after {\n left: 24px;\n }\n }\n\n & > div.ant-typography {\n padding: 0 24px;\n }\n }\n\n .cards {\n width: 100%;\n padding: 0 24px;\n margin: 32px 0;\n grid-template-columns: repeat(2, 1fr);\n\n & > div {\n width: auto;\n height: 240px;\n }\n }\n }\n`;\n\nexport const Container = styled.div`\n h1 {\n width: 700px;\n margin: 0 auto 1.5rem;\n font-weight: 400;\n font-size: 2rem;\n position: relative;\n line-height: 2.5rem;\n padding-bottom: 1rem;\n color: var(--velotax-font-color-light);\n\n :after {\n content: \"\";\n position: absolute;\n left: 0;\n bottom: 0;\n height: 2px;\n width: 100px;\n background-color: var(--ant-primary-color);\n }\n }\n\n h2.ant-typography {\n display: flex;\n align-items: center;\n column-gap: 8px;\n width: 700px;\n margin: 0 auto 1.5rem;\n font-size: 1rem;\n font-weight: 400;\n line-height: 1.5rem;\n color: var(--velotax-font-color-light);\n\n &.info {\n align-items: flex-start;\n font-size: 0.875rem;\n line-height: 1.125rem;\n opacity: 0.85;\n margin: 0 auto 2.5rem;\n svg {\n margin-top: 4px;\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n padding: 0;\n\n h1 {\n width: calc(100% - 48px);\n margin: 0 24px 1.5rem;\n padding: 24px 0 1rem;\n }\n\n h2.ant-typography {\n width: 100%;\n margin: 0 auto 1.5rem;\n padding: 0 24px;\n }\n }\n`;\n\nexport const Content = styled.div`\n padding: 32px;\n width: 700px;\n border-radius: 4px;\n background-color: var(--velotax-background-color);\n\n .ant-list.ant-list-split {\n margin: 24px 0 0;\n padding: 0 16px;\n background-color: var(--velotax-ghost);\n border: 1px solid var(--velotax-ghost);\n border-radius: 4px;\n .ant-list-item-action > li {\n padding: 0;\n }\n .ant-list-item-meta-description {\n opacity: 0.75;\n }\n .ant-list-item-action > li > button {\n font-size: 16px;\n color: var(--ant-primary-color);\n }\n .ant-list-item-meta-title,\n .ant-list-item-meta-description {\n font-size: 16px;\n color: var(--velotax-font-color-light);\n }\n .ant-list-item-action-split {\n opacity: 0;\n }\n }\n .historic-month-status {\n font-weight: 500;\n padding: 4px 8px;\n border-radius: 0;\n color: var(--black);\n display: flex;\n &.payed,\n &.regular {\n background-color: var(--ant-success-color);\n }\n &.pending {\n background-color: var(--ant-error-color);\n }\n &.not-payed {\n background-color: var(--ant-warning-color);\n }\n }\n .ant-btn.ant-btn-text {\n color: var(--ant-primary-color);\n }\n @media only screen and (max-device-width: 812px) {\n padding: 24px 24px 32px;\n border-radius: 0;\n width: 100%;\n .ant-list.ant-list-split {\n .ant-list-item-action {\n align-items: end;\n grid-template-rows: 1fr 0.75fr;\n grid-template-columns: 1fr 1fr;\n }\n }\n }\n`;\n","import { RiDownloadCloudLine } from \"react-icons/ri\";\nimport { Button as MaterialButton } from \"@mui/material\";\nimport { useCallback, useEffect, useState } from \"react\";\nimport { useLocation, useNavigate } from \"react-router-dom\";\nimport { InfoCircleOutlined, LoadingOutlined } from \"@ant-design/icons\";\nimport {\n Col,\n List,\n message,\n Modal,\n Row,\n Select,\n Skeleton,\n Typography,\n} from \"antd\";\nimport { cards } from \"./items\";\nimport apis from \"../../services/apis\";\nimport { Card } from \"../Exterior/Cards\";\nimport Button from \"../../components/Button\";\nimport { Page } from \"../../constants/brokers\";\nimport { useAuth } from \"../../contexts/AuthContext\";\nimport { apiPayment } from \"../../services/apiPayment\";\nimport { useBroker } from \"../../contexts/BrokerContext\";\nimport { BackButton } from \"../../components/BackButton\";\nimport { ReportContainer, Container, Content } from \"./styles\";\nimport {\n download,\n errorMessage,\n getInitialYear,\n isMobile,\n monthsExtended,\n zero,\n} from \"../../utils\";\nimport apiExterior from \"../../services/apiExterior\";\nimport { YearReport } from \"../../constants/rendimentos\";\ninterface ReportProps {\n item: Page;\n}\n\nexport const ReportAlertTitle = (\n \n {\" \"}\n \n Os relatórios estão disponíveis somente no plano premium.{\" \"}\n Contrate o seu plano\n \n \n);\n\nexport const ReportExterior: React.FC = ({ item }) => {\n const navigate = useNavigate();\n const {\n showUserPlanModal,\n userPlanModal,\n ssoToken,\n hasPlan,\n user,\n hasPermissionExteriorPlanos,\n hasPermissionGeneral,\n } = useAuth();\n const today = new Date();\n const currentMonth = today.getMonth();\n const currentYear = today.getFullYear();\n const [initialYear, setInitialYear] = useState(currentYear);\n window.history.replaceState({}, document.title);\n\n const { currentPage } = useBroker();\n\n const [action, setAction] = useState('anual-report');\n // const [action, setAction] = useState();\n\n const [data, setData] = useState();\n const [infoModal, toggleModal] = useState(null);\n const [loading, setLoading] = useState(false);\n const [loadingError, setLoadingError] = useState(true);\n\n const [loadingLinks] = useState(false);\n const [year, setYear] = useState(initialYear);\n\n const [reportDisabled, setReportDisabled] = useState(false);\n\n const historicFeature = item.features[0];\n const downloadFeature = item.features[1];\n // const sendEmailFeature = item.features[2];\n const transactionsFeature = item.features[3];\n const darfFeature = item.features[4];\n\n const yearOptions = Array.from(Array(initialYear - 2020 + 1))\n .map((y, i) => ({\n value: 2020 + i,\n label: `${2020 + i}`,\n }))\n .reverse();\n\n const onChangeYear = (value: string) => {\n setYear(parseInt(value));\n };\n\n const getHistoric = useCallback(() => {\n if (!action) return;\n if (action === \"anual-report\")\n return setData(\n Array.from(Array(new Date().getFullYear() - 2022))\n .map((y, i) => ({\n year: 2022 + i,\n label: `${2022 + i}`,\n }))\n .reverse()\n );\n\n setLoading(true);\n (currentPage?.api || apis)\n .get(`${historicFeature.apiUrl}/${action || \"gain\"}`, {\n params: { year },\n })\n .then((response) => {\n const data = (response.data ?? []).reverse();\n setData(data);\n // getDowloadLinks(data, action || \"gain\");\n })\n .catch(() => message.error(errorMessage))\n .finally(() => setLoading(false));\n }, [historicFeature, year, currentPage, action /*, getDowloadLinks*/]);\n\n const downloadAction = (record: any): Promise => {\n setLoading(true);\n return (currentPage?.api || apis)\n .post(`${downloadFeature.apiUrl}/${action || \"anual-report\"}`, {\n id: record._id,\n month: record.month,\n year: record.year,\n })\n .then((res) => {\n if (res.data.fileUrl && !isMobile()) {\n download(res.data.fileUrl);\n }\n if (res.data.file) {\n // downloadPDF(res.data.file);\n message.success(\"Relatório enviado para o seu e-mail\");\n }\n })\n .catch(({ response }) =>\n message.error(response?.data?.message ?? errorMessage)\n )\n .finally(() => setLoading(false));\n };\n\n const downloadDarf = async (data: any) => {\n setLoading(true);\n\n (currentPage?.api || apis).post(`${darfFeature.apiUrl}`, data)\n .then((res) => {\n if (!res?.data?.darfUrl ) {\n return message.error(\"Houve um erro ao baixar seu relatório!\")\n }\n download(res.data.darfUrl);\n message.success(\"Relatório emitido com sucesso\");\n })\n .catch(({ response }) =>\n message.error(response?.data?.message)\n )\n .finally(() => {\n setLoading(false);\n });\n };\n\n const handlePlanModal = () => {\n showUserPlanModal(!userPlanModal, ReportAlertTitle);\n };\n\n \n const checkDarf = (record: any) => {\n setLoading(true);\n (currentPage?.api || apis).get(`${transactionsFeature.apiUrl}`, { params: { year: record.year} })\n .then((res) => {\n const darf = res.data.find((d: any)=> {\n if (record?.month == d?.month) return d;\n })\n if (!darf || !darf?._id) {\n message.info(\"Cliente não possui relatório para este mês.\");\n setLoading(false);\n return;\n }\n delete darf?.transactions;\n const data = {\n ...darf,\n year: record.year,\n month: record.month,\n name: user?.user?.name,\n memoriaCalculo: [],\n justSave: false,\n payed: false,\n noSendMail: true,\n paymentInfo: {\n clientInfo: {\n name: user?.user?.name,\n email: user?.user?.email,\n document: user?.user?.cpf,\n },\n },\n };\n setLoading(false);\n downloadDarf(data);\n })\n .catch(({ response }) => {\n const { data, status } = response;\n if (status === 401) message.error(data?.message);\n setLoading(false);\n });\n }\n\n const handleActionButton = (id: string) => {\n if (!hasPlan) {\n handlePlanModal();\n } else {\n setAction(id);\n switch (id) {\n case \"anual-report\":\n case \"income\":\n setYear(2023);\n setInitialYear(2023);\n break;\n case \"gain\":\n setYear(2024);\n setInitialYear(2024);\n break;\n }\n }\n };\n\n const handleActionButtonBack = (id: any) => {\n setAction(id);\n };\n\n const getErrors = () => {\n apiExterior\n .get(`/transaction/hasError`, { params: { notified: true } })\n .then((res: any) => {\n setReportDisabled((res?.data?.error?.errorDates || []).length > 0)\n })\n .catch(() => {\n console.log(\"Erro no error\");\n })\n .finally(() => setLoadingError(false))\n }\n\n useEffect(() => {\n getErrors()\n }, [])\n\n useEffect(() => {\n getHistoric();\n }, [getHistoric, year]);\n\n return (\n \n
\n Relatórios\n {action == \"anual-report\" &&\n \n Confira os relatórios anuais de operações no\n exterior para a declaração do seu IR.\n A sua declaração de IRPF pré-preenchida com as informações da Warren está\n disponível.\n \n }\n\n {loadingError ? : reportDisabled ?\n
\n \n Não foi possível carregar as suas operações.
\n Entre em contato através do e-mail suporte@velotax.com.br.\n
\n
\n : !action && (\n
\n {cards.map((item) => (\n : item.icon}\n onClick={\n item.id === \"irpf\"\n ? () => { }\n : () => !loading && handleActionButton(item.id)\n }\n >\n {item.id === \"irpf\" ? (\n <>\n \n {\" \"}\n \n {item.content}\n \n ) : (\n <>\n {item.content}\n {item.description && (\n
{item.description}
\n )}\n \n )}\n \n ))}\n
\n )}\n {/* {!action && (\n \n )} */}\n {action && (\n \n \n Selecione o ano:\n {action !== \"anual-report\" && (\n trigger.parentElement}\n />\n )}\n \n action === \"anual-report\" ||\n item.year === year ||\n item.year === currentYear\n ) ?? []\n }\n itemLayout=\"horizontal\"\n renderItem={(item, index) => {\n // const show2024Report = localStorage.getItem('show2024Report') === 'show';\n if ((item.year ===2025) && action === \"anual-report\") return <>\n return (\n \n {\n (action === \"anual-report\")\n ? toggleModal(item)\n : ((action === \"gain\") && year === 2024)\n ? checkDarf(item)\n : downloadAction(item)\n }\n }\n download={`Relatório-${item.year}-${zero(\n item.month\n )}.pdf`}\n >\n Baixar\n {loadingLinks ? (\n \n ) : (\n \n )}\n ,\n ]}\n >\n \n \n \n \n )\n }}\n />\n navigate(\"/warren/exterior\")}\n style={{ marginTop: \"0.5rem\" }}\n >\n Voltar\n \n {/* {!action || action ==='anual-report' && (\n \n )} */}\n \n \n )}\n {\n toggleModal(null);\n }}\n footer={\n \n \n {\n downloadAction(infoModal);\n toggleModal(null);\n }}\n >\n Continuar\n \n \n \n {\n navigate(\"/warren/exterior-historic\");\n }}\n >\n Ir para calculadora de DARF\n \n \n \n }\n >\n \n \n Caso você tenha realizado operações de venda de ativos ou recebido\n cupom de bonds em {year},\n {\" \"}\n certifique-se de que todos os meses estejam com a situação \"Regular\"\n na Calculadora de DARF.\n \n \n
\n
\n );\n};\n","import styled from \"styled-components\";\nimport { DrawerModal } from \"../../components/DrawerModal\";\n\nexport const ModalStyled = styled(DrawerModal)`\n &.ant-modal {\n div.ant-modal-content {\n background-color: var(--white);\n .ant-modal-close {\n top: 0;\n right: 0;\n }\n .ant-modal-close-icon {\n color: var(--ant-primary-color);\n }\n .ant-modal-header {\n padding: 48px 64px 24px 48px;\n background-color: var(--white);\n .ant-modal-title {\n font-size: 24px;\n color: var(--velotax-font-color-dark);\n }\n }\n .ant-modal-body {\n padding: 8px 48px 48px;\n }\n }\n }\n .ant-table {\n width: 100%;\n }\n .mobile-list {\n display: none;\n }\n .table-total {\n padding: 16px;\n display: flex;\n align-items: center;\n background-color: #f0f0f0;\n justify-content: space-between;\n h3 {\n margin: 0;\n font-size: 14px;\n }\n span.ant-typography {\n font-weight: 600;\n width: 116px;\n }\n &.exterior {\n margin-bottom: 16px;\n span.ant-typography {\n width: calc(30% - 22px);\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n &.ant-drawer {\n .ant-drawer-content-wrapper {\n .ant-drawer-content {\n background-color: var(--white) !important;\n .ant-drawer-wrapper-body {\n .ant-drawer-header {\n .ant-drawer-header-title {\n .ant-drawer-title {\n color: var(--velotax-font-color-dark) !important;\n }\n }\n }\n }\n }\n }\n }\n .ant-table {\n display: none;\n }\n .mobile-list {\n width: 100%;\n display: flex;\n margin: 24px 0 0;\n flex-direction: column;\n .list-item {\n width: 100%;\n padding: 16px 24px;\n border-top: 1px solid #e8e8e8;\n :last-of-type {\n border-bottom: 1px solid #e8e8e8;\n }\n p {\n font-size: 16px;\n font-weight: 600;\n margin-bottom: 4px;\n }\n .list-item-label {\n width: 48px;\n font-weight: 500;\n display: inline-block;\n }\n .list-item-value {\n width: calc(100% - 48px);\n display: inline-block;\n }\n }\n .list-empty {\n padding: 16px 0;\n margin-top: -24px;\n text-align: center;\n background-color: #e8e8e8;\n }\n &.exterior {\n .list-item-label {\n width: 100px;\n }\n .list-item-value {\n width: calc(100% - 100px);\n }\n }\n }\n .table-total {\n padding: 24px;\n span.ant-typography {\n width: auto !important;\n text-align: right;\n }\n }\n }\n`;\n\nexport const BolsaOperations = styled.div`\n margin-top: 20px;\n border-radius: 8px;\n color: var(--velotax-font-color-light);\n background-color: var(--velotax-ghost);\n border: 1px solid var(--velotax-background-color-ghost);\n\n div.strong span {\n font-weight: 700 !important;\n }\n div.opacity {\n opacity: 0.8;\n }\n\n span.dividendos-header {\n background-color: var(--velotax-background-color-ghost) !important;\n font-weight: 700 !important;\n }\n div.header,\n div.sub-header,\n div.row {\n display: grid;\n grid-template-columns: 0.7fr 1fr 0.5fr;\n span {\n text-align: center;\n justify-content: center;\n }\n }\n\n div.sub-header,\n div.row {\n height: auto;\n min-height: 48px;\n border-top: none;\n & + div.sub-header {\n border-top: 1px solid var(--velotax-background-color-ghost);\n }\n & > span + span {\n background-color: var(--velotax-background-color);\n }\n & > span {\n display: flex;\n align-items: center;\n border-left: none;\n }\n &:last-of-type > span:last-of-type {\n border-radius: 0 0 8px 0;\n }\n }\n\n div.header {\n padding: 16px;\n border-radius: 8px 8px 0 0;\n background-color: var(--velotax-background-color-ghost);\n span {\n font-weight: 700;\n }\n button {\n display: none;\n }\n }\n\n div.sub-header {\n font-size: 14px;\n & > span {\n font-weight: 300;\n }\n }\n\n div.row {\n opacity: 0.85;\n font-size: 13px;\n border-top: 1px solid var(--velotax-background-color-ghost);\n }\n\n @media only screen and (max-device-width: 812px) {\n div.sub-header {\n font-size: 12px;\n }\n }\n`;\n\nexport const Container = styled.div`\n width: 100%;\n display: flex;\n flex-direction: column;\n &,\n h4,\n .ant-typography {\n color: var(--velotax-font-color-dark);\n }\n .MuiButtonBase-root {\n height: 40px;\n margin: -60px 0 32px auto;\n border: 1px solid #e8e8e8;\n border-radius: 24px !important;\n text-transform: none !important;\n .MuiButton-startIcon {\n width: 18px;\n height: 18px;\n display: flex;\n margin-right: 6px;\n align-items: center;\n svg {\n fill: var(--ant-primary-color);\n }\n }\n }\n @media only screen and (max-device-width: 812px) {\n .MuiButtonBase-root {\n width: 60%;\n margin: -16px 0 0 0;\n }\n }\n`;\n","import { message } from \"antd\";\nimport apiBolsa from \"../services/apiBolsa\";\nimport apiExterior from \"../services/apiExterior\";\n\nexport const sendEmailSheet = async (type: string, orders: any, dateInfo: any, dolarQuote: any, user: any, title: string) => {\n try {\n const api = (type == 'bolsa') ? apiBolsa : apiExterior;\n api\n .post(\"/dividendos/sheet-email\", {\n orders: orders,\n dolarQuote: dolarQuote,\n title: title,\n user: user,\n month: dateInfo?.month,\n year: dateInfo?.year\n })\n .then(() => {\n message.success(\"Planilha enviada por e-mail!\");\n })\n .catch((err) => {\n message.error(err?.response?.data?.message);\n })\n .finally(() => {\n return;\n });\n } catch (error: any) {\n message.error(error)\n }\n}\n","import moment from \"moment\";\nimport { Button } from \"@mui/material\";\nimport { Table, Typography } from \"antd\";\nimport { AiOutlineDownload } from \"react-icons/ai\";\nimport { Container } from \"./styles\";\nimport { formatCurrency, isMobile } from \"../../utils\";\nimport { handleDownloadSheet } from \"../../utils/handleDownloadSheet\";\nimport { sendEmailSheet } from \"../../utils/sendEmailSheet\";\nimport { useAuth } from \"../../contexts/AuthContext\";\n\nexport const DividendosModal = ({ item, year }: any) => {\n const { user } = useAuth();\n const dateInfo = {year: year, month: item?.month}\n return (\n \n {item?.operations?.length > 0 && (\n }\n onClick={() => {\n if (isMobile()) \n {\n sendEmailSheet('bolsa', item?.operations, dateInfo, '', user, \"Dividendos\");\n }\n else {\n handleDownloadSheet(item?.buffer?.data, \"Dividendos\")\n }\n }}\n >\n Baixar planilha\n \n )}\n (\n {value}\n ),\n },\n {\n align: \"left\",\n title: \"Data\",\n dataIndex: \"referenceDate\",\n render: (value) => moment(value).format(\"DD/MM/YYYY\"),\n },\n {\n align: \"left\",\n dataIndex: \"tipo\",\n title: \"Tipo de rendimento\",\n },\n {\n align: \"left\",\n title: \"Valor\",\n width: \"150px\",\n dataIndex: \"valor\",\n render: (value) => formatCurrency(value ?? 0, \"R$ \"),\n },\n ]}\n />\n
\n {item?.operations?.map((op: any, index: number) => (\n
\n

{op.ticker}

\n Tipo:\n {op.tipo}\n Data:\n \n {moment(op.referenceDate).format(\"DD/MM/YYYY\")}\n \n Valor:\n \n {formatCurrency(op.valor ?? 0, \"R$ \")}\n \n
\n ))}\n {!item?.operations?.length && (\n
Nenhum dividendo recebido neste mês
\n )}\n
\n {item?.operations?.length > 0 && (\n
\n Total recebido no mês:\n {formatCurrency(item.value)}\n
\n )}\n
\n );\n};\n","import { monthsExtended } from \"../../utils\";\n\nexport const monthList = Array.from(Array(12))\n .map((_, i) => ({\n month: i + 1,\n monthName: monthsExtended[i],\n value: 0,\n // impostoPagoExterior: 0,\n }))\n .reverse();\n","import { Spin } from \"antd\";\nimport { BsEye } from \"react-icons/bs\";\nimport { formatCurrency } from \"../../utils\";\nimport { CurrencyFormItem, TextFormItem } from \"../formItems\";\n\nconst DividendosItem = {\n id: TextFormItem({\n name: \"id\",\n label: \"Id\",\n hidden: true,\n }),\n valorRendimento: CurrencyFormItem({\n name: \"valorRendimento\",\n label: \"Rendimento\",\n }),\n impostoPagoExterior: CurrencyFormItem({\n name: \"impostoPagoExterior\",\n label: \"Imposto Pago no Exterior\",\n }),\n};\n\nexport const DividendosRows = [\n [DividendosItem.id],\n [DividendosItem.valorRendimento],\n [DividendosItem.impostoPagoExterior],\n];\n\nexport const handleValue = (\n item: any,\n index: number,\n variable: string,\n data: any\n) => {\n const dividendo = data?.find((el: any) => el.month === 12 - index);\n if (dividendo) {\n return dividendo[variable] * dividendo.dolarQuote;\n } else {\n return item[variable];\n }\n};\n\nexport const handleValueBolsa = (item: any, data: any) => {\n const month = data.find((el: any) => el.month === item.month);\n return month?.value || 0;\n};\n\nexport const handleItem = (index: number, data: any, item: any) => {\n return data?.find((el: any) => el.month === 12 - index) ?? item;\n};\n\nexport const DividendosTabs: (\n item: any,\n index: number,\n data: any,\n loading: boolean,\n setShowModal: Function,\n setItem: Function,\n setIndex: Function,\n isBolsa?: boolean\n) => { class: string; tabs: { content: React.ReactNode }[] }[] = (\n item,\n index,\n data,\n loading,\n setShowModal,\n setItem,\n setIndex,\n isBolsa\n) => [\n {\n class: \"sub-header\",\n tabs: [\n {\n content:
{item.monthName}
,\n },\n {\n content: loading ? (\n \n ) : (\n formatCurrency(\n isBolsa\n ? handleValueBolsa(item, data)\n : handleValue(item, index, \"valorRendimento\", data)\n )\n ),\n },\n ...(!isBolsa\n ? [\n {\n content: loading ? (\n \n ) : (\n formatCurrency(\n handleValue(item, index, \"impostoPagoExterior\", data)\n )\n ),\n },\n ]\n : []),\n {\n content: (\n {\n setShowModal(true);\n setItem(handleItem(index, data, item));\n setIndex(index);\n }}\n />\n ),\n },\n ],\n },\n];\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n display: flex;\n align-items: center;\n flex-direction: column;\n padding: 64px 32px 64px;\n\n .juridic-messages-container {\n opacity: 0.8;\n width: 700px;\n margin: 0 auto;\n padding: 32px 0 32px 0;\n\n .message {\n display: flex;\n flex-direction: row;\n align-items: center;\n margin-bottom: 1rem;\n }\n\n p {\n font-size: 0.85rem;\n font-weight: 400;\n text-align: justify;\n line-height: 1.4rem;\n color: var(--velotax-font-color-light);\n margin-bottom: 0px;\n\n i {\n font-weight: bold;\n color: var(--velotax-font-color-light);\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n padding: 0;\n min-height: 100%;\n\n .page-title {\n font-size: 1.25rem;\n line-height: 1.75rem;\n padding-bottom: 1rem;\n }\n\n .juridic-messages-container {\n width: calc(100% - 48px);\n margin: 0 24px 48px;\n p {\n margin-left: 0;\n }\n }\n }\n`;\n\nexport const Content = styled.div`\n padding: 32px;\n width: 700px;\n border-radius: 4px;\n background-color: var(--velotax-background-color);\n\n .destak {\n font-size: 14px;\n font-weight: 400;\n color: var(--velotax-font-color);\n }\n\n button.text-small,\n button.text-small:hover,\n button.text-small:focus,\n button.text-small:active,\n button.text-small:visited {\n color: var(--velotax-font-color-dark) !important;\n }\n @media only screen and (max-device-width: 812px) {\n padding: 24px;\n border-radius: 0;\n width: 100%;\n .text-small {\n font-size: 11px;\n }\n h2 {\n &::before {\n left: -24px;\n }\n }\n }\n`;\n","export default __webpack_public_path__ + \"static/media/b3-logo-white.19776928.svg\";","import styled, { css } from \"styled-components\";\n\nexport const Container = styled.div<{ imgHeight?: boolean }>`\n display: flex;\n align-items: center;\n flex-direction: column;\n justify-content: center;\n width: 100%;\n height: 150px;\n padding: 32px;\n cursor: pointer;\n background: var(--velotax-background-color);\n border-radius: 6px;\n position: relative;\n border: 2px solid var(--velotax-ghost-white);\n position: relative;\n transition: 0.3s;\n\n :hover {\n opacity: 0.9;\n filter: contrast(0.9);\n }\n\n img {\n ${(props) =>\n props.imgHeight\n ? css`\n height: 100%;\n `\n : css`\n width: 100%;\n `}\n }\n\n .loading-animation {\n display: flex;\n align-items: center;\n flex-direction: column;\n justify-content: center;\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n padding: 8px;\n border-radius: 6px;\n backdrop-filter: blur(4px);\n background: var(--ant-info-color-outline);\n span {\n font-size: 14px;\n line-height: 16px;\n font-weight: bold;\n text-align: center;\n }\n .anticon-spin {\n margin: 4px 8px 4px 0;\n font-size: 28px;\n color: var(--white);\n\n svg {\n margin: 0;\n }\n }\n }\n\n &.integrado {\n border: 2px solid var(--ant-success-color);\n }\n\n .integrado-check {\n bottom: 12px;\n right: 12px;\n font-size: 22px;\n position: absolute;\n }\n\n .click-here {\n margin: 16px 0 0;\n font-size: 11px !important;\n font-weight: 500;\n line-height: 20px;\n color: var(--velotax-font-color);\n opacity: 0.8;\n }\n\n a.b3-link {\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n opacity: 0;\n }\n`;\n","import clsx from \"clsx\";\nimport React from \"react\";\nimport { useLocation } from \"react-use\";\nimport { Tooltip, Typography } from \"antd\";\nimport { CheckCircleTwoTone, LoadingOutlined } from \"@ant-design/icons\";\nimport { Container } from \"./styles\";\nimport { useB3Integration } from \"../../../contexts/B3IntegrationContext\";\n\ninterface IIntegrationButtonProps {\n alt: string;\n loading: boolean;\n integrado: boolean;\n setIntegrationModalVisible: Function;\n logo?: string;\n imgHeight?: boolean;\n handleClick?: () => void;\n b3Link?: string;\n isB3LinkRedirect?: boolean;\n}\n\nconst IntegrationButton: React.FC = ({\n alt,\n logo,\n b3Link,\n loading,\n integrado,\n imgHeight,\n isB3LinkRedirect,\n handleClick = () => {},\n setIntegrationModalVisible,\n}) => {\n const location = useLocation();\n const { timer } = useB3Integration();\n const isB3 = location.pathname === \"/warren/bolsa-integration\";\n\n const onClick = () => {\n if (isB3 || location.pathname === \"/warren/exterior-integration\") {\n handleClick();\n } else if (!loading) {\n setIntegrationModalVisible(true);\n }\n };\n return (\n \n \n {isB3LinkRedirect && b3Link && (\n \n .\n \n )}\n {alt}\n \n Clique aqui\n \n {!loading && integrado && (\n
\n \n
\n )}\n {isB3 && loading && (\n
\n \n Verificando autorização com a B3 ({timer} s)\n
\n )}\n {!isB3 && loading && (\n
\n \n Isso pode demorar alguns minutos, aguarde\n
\n )}\n \n \n );\n};\n\nexport default IntegrationButton;\n","import { Button } from \"@mui/material\";\nimport { AiOutlineArrowDown } from \"react-icons/ai\";\nimport { B3AuthURL } from \"../../../utils\";\nimport b3Logo from \"../../../assets/b3-logo-white.svg\";\nimport { useB3Integration } from \"../../../contexts/B3IntegrationContext\";\nimport IntegrationButton from \"../../../components/IntegrationComponents/IntegrationButton\";\n\ninterface B3IntegrationButtonsProps {\n showIntegrationButton?: boolean;\n}\n\nexport const B3IntegrationButtons: React.FC = ({\n showIntegrationButton,\n}) => {\n const {\n openWithLink,\n b3Authorized,\n handleIntegrate,\n loadingIntegration,\n loadingAuthorization,\n checkingAuhtorization,\n } = useB3Integration();\n\n return (\n <>\n {showIntegrationButton && (\n <>\n {}}\n handleClick={() => handleIntegrate()}\n isB3LinkRedirect={openWithLink}\n loading={\n checkingAuhtorization ||\n loadingIntegration ||\n loadingAuthorization\n }\n />\n
\n \n )}\n handleIntegrate()}\n startIcon={}\n disabled={loadingIntegration || loadingAuthorization}\n {...(openWithLink ? { href: B3AuthURL } : {})}\n >\n Conectar com a B3\n \n \n );\n};\n","import styled from \"styled-components\";\n\nexport const Container = styled.div``;\n\nexport const Content = styled.div``;\n","import { message } from \"antd\";\nimport { useRef, useState } from \"react\";\nimport Upload, { RcFile } from \"antd/lib/upload\";\nimport {\n UploadFile,\n UploadFileStatus,\n UploadProps,\n} from \"antd/lib/upload/interface\";\nimport apiCrypto from \"../../../services/apiCrypto\";\nimport { useBroker } from \"../../../contexts/BrokerContext\";\n\nconst isValidFile = (file: UploadFile) => file.type === \"application/pdf\";\nconst sameNameFile = (file: UploadFile, files: UploadFile[]) =>\n files.findIndex((item) => item.name === file.name) >= 0;\n\nexport const useNotasCorretagem = () => {\n const sameNameFiles = useRef([]);\n const [loadingSend, setLoadingSend] = useState(false);\n const [notas, setNotas] = useState[]>([]);\n const [showNotasCorretagemModal, setShowNotasCorretagemModal] =\n useState(false);\n\n const { getXtageIntegrationStatus } = useBroker();\n\n const beforeUploadNota = (file: RcFile) => {\n if (!isValidFile(file)) {\n message.error(\"Você só pode fazer upload de arquivos pdf\");\n return Upload.LIST_IGNORE;\n }\n if (sameNameFile(file, notas)) {\n sameNameFiles.current.push(file.name);\n message.error(\"Este arquivo já foi adicionado\");\n return Upload.LIST_IGNORE;\n }\n };\n\n const onChangeNotas = ({\n file,\n fileList,\n }: {\n file: UploadFile;\n fileList: UploadFile[];\n }) => {\n if (file && file.status === \"removed\") return;\n if (!isValidFile(file)) return;\n if (sameNameFiles.current.includes(file.name)) {\n sameNameFiles.current = sameNameFiles.current.filter(\n (name) => name !== file.name\n );\n return;\n }\n setNotas(\n fileList\n .filter((file) => file.status !== \"removed\")\n .map((file) => ({ ...file, status: \"done\" as UploadFileStatus }))\n );\n };\n\n const onRemoveNota = (file: UploadFile) => {\n setNotas((notas) => notas.filter((nota) => nota.uid !== file.uid));\n };\n\n const sendNotas = () => {\n const formData = new FormData();\n notas.forEach((nota) => {\n formData.append(\"files\", nota.originFileObj as File);\n });\n setLoadingSend(true);\n apiCrypto\n .post(\"/brokerage-notes/read\", formData)\n .then(() => {\n message.success(\"Informações extraídas com sucesso\");\n getXtageIntegrationStatus({\n redirect: true,\n });\n // navigate(\"/warren/cripto\");\n // navigate(\"/warren/cripto-historic\");\n })\n .catch((err) => {\n const errorMessage =\n err.reponse?.message?.error || \"Não foi possivel extrair informações\";\n message.error(errorMessage);\n })\n .finally(() => {\n setLoadingSend(false);\n });\n };\n\n const uploadProps: UploadProps = {\n fileList: notas,\n multiple: true,\n listType: \"text\",\n accept: \"application/pdf\",\n onRemove: onRemoveNota,\n onChange: onChangeNotas,\n beforeUpload: beforeUploadNota,\n customRequest: () => {},\n showUploadList: {\n showRemoveIcon: true,\n showPreviewIcon: false,\n showDownloadIcon: false,\n },\n };\n\n return {\n sendNotas,\n loadingSend,\n uploadProps,\n showNotasCorretagemModal,\n setShowNotasCorretagemModal,\n };\n};\n","import { Col, Row } from \"antd\";\nimport { Button } from \"@mui/material\";\nimport { useNavigate } from \"react-router\";\nimport { useNotasCorretagem } from \"./useNotasCorretagem\";\nimport { useBroker } from \"../../../contexts/BrokerContext\";\nimport UploadVelotax from \"../../../components/UploadVelotax\";\n\ninterface NotasCorretagemProps {}\n\nexport const NotasCorretagem: React.FC = () => {\n const navigate = useNavigate();\n const { xtageIntegration } = useBroker();\n const { sendNotas, loadingSend, uploadProps } = useNotasCorretagem();\n\n return (\n <>\n \n \n {xtageIntegration && (\n \n navigate(\"/warren/cripto\")}\n >\n Voltar\n \n \n )}\n \n sendNotas()}\n >\n Enviar\n \n \n \n \n );\n};\n","import { monthsExtended } from \"../../utils\";\n\nexport const monthList = Array.from(Array(12))\n .map((_, i) => ({\n month: i + 1,\n monthName: monthsExtended[i],\n valorRendimento: 0,\n impostoPagoExterior: 0,\n }))\n .reverse();\n\nexport const CalcAutonomosDarfItem = {\n header: true,\n sidebar: true,\n component: \"Rendimentos\",\n path: \"/velotax/autonomos-darf\",\n name: \"Calculadora\",\n title: \"\",\n features: [\n {\n apiUrl: \"/transaction\",\n },\n {\n apiUrl: \"/darf\",\n buttonLabel: \"Emitir DARF\",\n },\n {\n apiUrl: \"/darf/year\",\n },\n ],\n}","import { Button } from \"@mui/material\";\nimport { Typography, Spin, Table } from \"antd\";\nimport { AiOutlineDownload } from \"react-icons/ai\";\nimport { useCallback, useEffect, useState } from \"react\";\nimport { formatCurrency, formatDate, isMobile } from \"../../utils\";\nimport { Container } from \"../../pages/DividendosBolsa/styles\";\nimport { handleDownloadSheet } from \"../../utils/handleDownloadSheet\";\nimport { sendEmailSheet } from \"../../utils/sendEmailSheet\";\nimport { useAuth } from \"../../contexts/AuthContext\";\n\nexport const DividendosModal = ({ item, year, quotes }: any) => {\n const [total, setTotal] = useState({});\n const [object, setObject] = useState({});\n const [loading, setLoading] = useState(false);\n const dateInfo = {year: year, month: item?.month}\n const { user } = useAuth();\n\n const checkType = (el: any) => {\n if (el.type === \"DIVIDEND\" && el.operation === \"BUY\") {\n return \"valorRendimento\";\n } else return \"impostoPagoExterior\";\n };\n\n const getTotal = useCallback(async () => {\n let auxTotal: any = {\n totalRendimento: 0,\n totalRendimentoReal: 0,\n totalImposto: 0,\n totalImpostoReal: 0,\n };\n Object.keys(object).forEach((item: any) => {\n auxTotal = {\n ...auxTotal,\n totalRendimento:\n (auxTotal.totalRendimento ?? 0) + (object[item].valorRendimento ?? 0),\n totalRendimentoReal:\n (auxTotal.totalRendimentoReal ?? 0) +\n (object[item].valorRendimentoReal ?? 0),\n totalImposto:\n (auxTotal.totalImposto ?? 0) +\n (object[item].impostoPagoExterior ?? 0),\n totalImpostoReal:\n (auxTotal.totalImpostoReal ?? 0) +\n (object[item].impostoPagoExteriorReal ?? 0),\n };\n });\n\n setTotal(auxTotal);\n }, [object]);\n\n const groupBycode = useCallback(async () => {\n setLoading(true);\n const aux: any = {};\n for (const el of item.orders ?? []) {\n if (!aux[el.code]) {\n if (checkType(el) === \"valorRendimento\") {\n aux[el.code] = {\n valorRendimento: el.value,\n valorRendimentoReal: el.value * item.dolarQuote,\n date: formatDate(el.date),\n };\n } else {\n aux[el.code] = {\n impostoPagoExterior: el.value,\n impostoPagoExteriorReal: el.value * item.dolarQuote,\n date: formatDate(el.date),\n };\n }\n } else {\n if (checkType(el) === \"valorRendimento\") {\n aux[el.code] = {\n ...aux[el.code],\n valorRendimento: (aux[el.code]?.valorRendimento ?? 0) + el.value,\n valorRendimentoReal:\n (aux[el.code]?.valorRendimentoReal ?? 0) +\n el.value * item.dolarQuote,\n };\n } else {\n aux[el.code] = {\n ...aux[el.code],\n impostoPagoExterior:\n (aux[el.code]?.impostoPagoExterior ?? 0) + el.value,\n impostoPagoExteriorReal:\n (aux[el.code]?.impostoPagoExteriorReal ?? 0) +\n el.value * item.dolarQuote,\n };\n }\n }\n }\n\n setObject(aux);\n setLoading(false);\n }, [item.orders, item.dolarQuote]);\n\n useEffect(() => {\n groupBycode();\n }, [groupBycode, item.month, year]);\n\n useEffect(() => {\n getTotal();\n }, [getTotal, object]);\n\n return (\n \n {loading ? (\n \n ) : (\n <>\n {Object.keys(object)?.length > 0 && (\n }\n onClick={() =>\n {\n if (isMobile()) \n {\n sendEmailSheet('exterior', item?.orders, dateInfo, item?.dolarQuote, user, \"Dividendos\");\n }\n else \n {\n handleDownloadSheet(\n item?.buffer?.data,\n `Dividendos-${year}-${item.month}`\n )\n }\n }\n }\n >\n Baixar planilha\n \n )}\n ({\n ...object[key],\n ticker: key,\n }))}\n locale={{ emptyText: \"Nenhum dividendo recebido neste mês\" }}\n columns={[\n {\n align: \"left\",\n title: \"Ativo\",\n dataIndex: \"ticker\",\n render: (value) => (\n {value}\n ),\n },\n {\n align: \"left\",\n title: \"Data\",\n dataIndex: \"date\",\n },\n {\n width: \"30%\",\n align: \"left\",\n dataIndex: \"valorRendimento\",\n title: \"Valor em USD\",\n render: (value) => formatCurrency(value ?? 0, \"US$ \"),\n },\n {\n width: \"30%\",\n align: \"left\",\n dataIndex: \"valorRendimentoReal\",\n title: \"Valor em BRL\",\n render: (value) => formatCurrency(value ?? 0, \"R$ \"),\n },\n ]}\n />\n
\n {Object.keys(object)\n .map((key) => ({\n ...object[key],\n ticker: key,\n }))\n ?.map((op: any, index: number) => (\n
\n

{op.ticker}

\n Data:\n {op.date}\n Valor em USD:\n \n {formatCurrency(op.valorRendimento ?? 0, \"US$ \")}\n \n Valor em BRL:\n \n {formatCurrency(op.valorRendimentoReal ?? 0, \"R$ \")}\n \n
\n ))}\n {!Object.keys(object).length && (\n
\n Nenhum dividendo recebido neste mês\n
\n )}\n
\n {Object.keys(object).length > 0 && (\n
\n \n Total recebido no mês:\n \n \n {formatCurrency(total.totalRendimentoReal ?? 0)}\n \n
\n )}\n \n )}\n
\n );\n};\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n padding: 64px 32px 32px;\n\n h1 {\n width: 700px;\n margin: 0 auto 1.5rem;\n font-weight: 400;\n font-size: 2rem;\n position: relative;\n line-height: 2.5rem;\n padding-bottom: 1rem;\n color: var(--velotax-font-color-light);\n\n :after {\n content: \"\";\n position: absolute;\n left: 0;\n bottom: 0;\n height: 2px;\n width: 100px;\n background-color: var(--ant-primary-color);\n }\n }\n\n span.ant-typography {\n opacity: 0.8;\n font-weight: 400;\n font-size: 0.85rem;\n line-height: 1.5rem;\n text-align: justify;\n color: var(--velotax-font-color-light);\n }\n\n h2.ant-typography {\n display: flex;\n align-items: center;\n column-gap: 8px;\n width: 700px;\n margin: 0 auto 2.5rem;\n font-size: 1rem;\n font-weight: 400;\n line-height: 1.5rem;\n color: var(--velotax-font-color-light);\n }\n\n @media only screen and (max-device-width: 812px) {\n padding: 0 0 32px;\n\n h1 {\n width: calc(100% - 48px);\n margin: 0 24px 1.5rem;\n padding: 24px 0 1rem;\n }\n\n h2.ant-typography {\n width: 100%;\n margin: 0 auto 1.5rem;\n padding: 0 24px;\n }\n }\n`;\n\nexport const FlexDiv = styled.div`\n display: flex;\n justify-content: center;\n flex-direction: column;\n`;\n\nexport const BolsaOperations = styled.div`\n margin-top: 20px;\n border-radius: 4px;\n color: var(--velotax-font-color-light);\n background-color: var(--velotax-ghost);\n border: 1px solid var(--velotax-background-color-ghost);\n\n .flex-actions {\n display: flex;\n justify-content: center;\n align-items: center;\n min-width: 170px;\n display: flex;\n }\n\n div.strong span {\n font-weight: 700 !important;\n }\n div.opacity {\n opacity: 0.8;\n }\n\n span.dividendos-header {\n background-color: var(--velotax-background-color-ghost) !important;\n font-weight: 700 !important;\n }\n div.header,\n div.sub-header,\n div.row {\n display: grid;\n grid-template-columns: 1fr 1fr 1fr 0.5fr;\n span {\n text-align: center;\n justify-content: center;\n }\n }\n\n table.table-month-operations {\n width: 100%;\n thead {\n height: auto;\n border-top: none;\n }\n tr {\n height: 48px;\n }\n td.table-vertical-head {\n background-color: var(--velotax-background-color-ghost);\n }\n td {\n min-width: 120px;\n text-align: center;\n }\n }\n\n div.sub-header,\n div.row {\n height: auto;\n min-height: 48px;\n border-top: none;\n & + div.sub-header {\n border-top: 1px solid var(--velotax-background-color-ghost);\n }\n & > span + span {\n background-color: var(--velotax-border-color);\n }\n & > span {\n display: flex;\n align-items: center;\n border-left: none;\n }\n &:last-of-type > span:last-of-type {\n border-radius: 0 0 4px 0;\n }\n }\n\n div.header {\n padding: 16px;\n border-radius: 4px 4px 0 0;\n background-color: var(--velotax-background-color-ghost);\n span {\n font-weight: 700;\n }\n button {\n display: none;\n }\n }\n\n div.sub-header {\n font-size: 14px;\n & > span {\n font-weight: 300;\n }\n }\n\n div.row {\n opacity: 0.85;\n font-size: 13px;\n border-top: 1px solid var(--velotax-background-color-ghost);\n }\n\n @media only screen and (max-device-width: 812px) {\n div.sub-header {\n font-size: 12px;\n }\n }\n`;\n\nexport const Content = styled.div`\n padding: 32px;\n margin: 0 auto;\n width: 700px;\n border-radius: 4px;\n background-color: var(--velotax-background-color);\n &.notas {\n padding: 32px 0;\n background-color: transparent;\n svg {\n fill: var(--ant-primary-color);\n }\n }\n h1 {\n margin: 0 0 8px;\n font-size: 20px;\n color: var(--velotax-font-color);\n }\n h2 {\n margin: 0;\n font-size: 16px;\n font-weight: 400;\n color: var(--velotax-font-color);\n }\n .ant-list.ant-list-split {\n margin: 24px 0 0;\n padding: 0 16px;\n background-color: var(--velotax-ghost);\n border: 1px solid var(--velotax-ghost);\n border-radius: 8px;\n .ant-list-item-action > li {\n padding: 0;\n }\n .ant-list-item-meta-description {\n opacity: 0.75;\n }\n .ant-list-item-action > li,\n .ant-list-item-meta-title,\n .ant-list-item-meta-description {\n color: var(--velotax-font-color);\n }\n .ant-list-item-action-split {\n opacity: 0;\n }\n }\n .historic-month-status {\n font-weight: 500;\n padding: 4px 8px;\n border-radius: 4px;\n color: var(--black);\n display: flex;\n &.payed,\n &.regular {\n background-color: var(--ant-success-color);\n }\n &.pending {\n background-color: var(--ant-error-color);\n }\n &.not-payed {\n background-color: var(--velotax-font-color);\n }\n }\n @media only screen and (max-device-width: 812px) {\n padding: 24px 24px 32px;\n border-radius: 0;\n width: 100%;\n &.notas {\n padding: 32px 24px;\n }\n .ant-list.ant-list-split {\n .ant-list-item-action {\n display: grid;\n align-items: end;\n grid-template-rows: 1fr 0.75fr;\n grid-template-columns: 1fr 1fr;\n }\n }\n }\n`;\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n padding: 64px 32px 128px;\n @media only screen and (max-device-width: 812px) {\n padding: 0;\n min-height: 100%;\n background-color: var(--velotax-background-color);\n }\n &.view,\n &.view-edit {\n padding: 0;\n }\n`;\n\nexport const Content = styled.div`\n padding: 32px;\n /* &:not(.view):not(.view-edit) {\n border: 1px solid var(--velotax-background-color-ghost);\n } */\n &.second.view,\n &.second.view-edit {\n margin-top: -24px;\n padding: 0 32px 32px;\n }\n &.second {\n padding: 32px;\n border: none;\n background-color: transparent;\n }\n margin: 0 auto;\n border-radius: 16px;\n background-color: var(--velotax-background-color);\n\n .no-plan-container {\n position: absolute;\n top: 0;\n left: 50%;\n width: 50%;\n z-index: 3;\n height: 100%;\n padding: 8px;\n display: flex;\n font-size: 16px;\n font-weight: 500;\n text-align: center;\n align-items: center;\n flex-direction: column;\n justify-content: center;\n background-color: #fff4;\n border-radius: 0 8px 8px 0;\n backdrop-filter: blur(4px);\n border: 1px solid var(--velotax-background-color-ghost);\n border-left: none;\n .ant-btn {\n margin-top: 8px;\n }\n }\n\n h3.date-title {\n font-size: 24px;\n font-weight: 700;\n }\n\n h3 {\n display: flex;\n align-items: center;\n font-size: 20px;\n column-gap: 16px;\n color: var(--velotax-font-color);\n margin-bottom: 0;\n }\n .month-chevron {\n width: 32px;\n height: 32px;\n cursor: pointer;\n &.empty {\n cursor: default;\n }\n }\n .desc-label {\n display: flex;\n align-items: center;\n svg {\n fill: var(--ant-primary-color);\n }\n }\n .desc-content {\n display: flex;\n align-items: flex-start;\n justify-content: center;\n column-gap: 8px;\n svg {\n fill: var(--ant-primary-color);\n }\n span {\n align-self: center;\n }\n button {\n min-width: 32px;\n }\n }\n .ml-40 {\n margin-left: 40px;\n }\n .add {\n min-width: 128px;\n margin: 0 0 16px auto;\n }\n .ant-descriptions-item-label {\n width: 50%;\n background-color: var(--velotax-ghost) !important;\n }\n .ant-descriptions-item-content {\n text-align: center;\n background-color: var(--velotax-background-color) !important;\n }\n .ant-list.ant-list-split {\n padding: 0 16px;\n background-color: var(--velotax-ghost) !important;\n border: 1px solid var(--velotax-background-color-ghost);\n border-radius: 8px;\n .ant-list-item-action > li {\n padding: 0;\n }\n }\n .ant-list-item-action > li,\n .ant-list-item-meta-title,\n .ant-list-item-meta-description {\n color: var(--velotax-font-color);\n }\n .ant-list-item-meta-description {\n opacity: 0.75;\n }\n .list-description {\n display: flex;\n flex-direction: column;\n }\n .min-darf-price {\n margin-top: 24px;\n display: flex;\n align-items: center;\n column-gap: 8px;\n }\n .text-center {\n display: block;\n text-align: center;\n }\n .ant-collapse-header {\n padding: 12px 0 !important;\n }\n .ant-collapse-content-box {\n padding: 16px 0 !important;\n }\n .ant-collapse\n > .ant-collapse-item\n > .ant-collapse-header\n .ant-collapse-arrow\n svg {\n transform: rotate(-90deg);\n }\n .ant-collapse-header-text {\n width: 100%;\n }\n .ant-collapse-item-disabled {\n & > .ant-collapse-header {\n cursor: default;\n .ant-collapse-arrow {\n opacity: 0;\n }\n }\n }\n .total-tax-header {\n width: calc(100% - 48px);\n display: flex;\n align-items: center;\n justify-content: space-between;\n &.original {\n h3:last-of-type {\n width: 40%;\n margin-bottom: 2px;\n }\n }\n h3 {\n margin: 0 0 6px;\n }\n }\n\n &.view .total-tax-header.impostos-devidos h3:first-of-type {\n max-width: 60%;\n font-size: 18px;\n margin-left: 4px;\n line-height: 22px;\n }\n\n h5 {\n margin: 0px;\n }\n\n @media only screen and (max-device-width: 812px) {\n width: 100%;\n border-radius: 0;\n padding: 24px 24px 48px;\n border: none !important;\n &.second {\n margin-top: -24px;\n padding: 0 24px 48px !important;\n background-color: var(--velotax-background-color);\n }\n h3 {\n font-size: 18px;\n column-gap: 8px;\n }\n .no-plan-container {\n font-size: 14px;\n line-height: 18px;\n }\n .total-tax-header {\n width: calc(100% - 20px);\n h3.text-center {\n span {\n font-size: 16px;\n }\n }\n }\n .anticon.anticon-right.ant-collapse-arrow {\n top: 24px;\n right: 0;\n }\n .desc-content {\n column-gap: 2px;\n flex-direction: row;\n &.is-editting {\n row-gap: 8px;\n flex-direction: column;\n button {\n width: 100%;\n }\n }\n &:not(.is-editting) {\n span {\n line-height: 32px;\n }\n button {\n margin-top: -2px;\n }\n }\n &.ml-40 {\n margin-left: 0;\n }\n }\n }\n`;\n\nexport const BolsaOperations = styled.div`\n display: grid;\n grid-template-columns: 2fr 1fr;\n border-radius: 8px;\n color: var(--velotax-font-color);\n background-color: var(--velotax-background-color);\n border: 1px solid var(--velotax-background-color-ghost);\n\n div.body-deducoes-tributarias {\n display: flex;\n flex-direction: column;\n padding: 0 8px;\n border-radius: 0 8px 8px 0;\n background-color: var(--velotax-background-color);\n border-left: 1px solid var(--velotax-background-color-ghost);\n span {\n height: 48px;\n display: flex;\n font-weight: 700;\n align-items: center;\n column-gap: 8px;\n }\n }\n\n div.header-deducoes-tributarias {\n display: flex;\n flex-direction: column;\n padding: 0 16px;\n border-radius: 8px 0 0 8px;\n background-color: var(--velotax-ghost);\n span {\n height: 48px;\n display: flex;\n font-weight: 700;\n align-items: center;\n column-gap: 8px;\n border-top: none;\n + span {\n border-top: 1px solid var(--velotax-background-color-ghost);\n }\n }\n }\n\n @media only screen and (max-device-width: 812px) {\n grid-template-columns: 1.6fr 1fr;\n span {\n font-size: 12px;\n button {\n max-width: 24px;\n min-width: 24px;\n }\n }\n }\n`;\n","import clsx from \"clsx\";\nimport { FaRegEdit } from \"react-icons/fa\";\nimport NumberFormat from \"react-number-format\";\nimport { useLocation, useNavigate } from \"react-router-dom\";\nimport { PlusOutlined } from \"@ant-design/icons\";\nimport { InfoCircleOutlined } from \"@ant-design/icons\";\nimport { AiOutlineDelete, AiOutlineLock } from \"react-icons/ai\";\nimport {\n useState,\n useEffect,\n useCallback,\n useRef,\n useMemo,\n ReactNode,\n} from \"react\";\nimport {\n Typography,\n Row,\n Col,\n Space,\n Descriptions,\n Spin,\n InputNumber,\n Collapse,\n List,\n Skeleton,\n Tooltip,\n message,\n} from \"antd\";\nimport MsDarf from \"../../services/msDarf\";\nimport Button from \"../../components/Button\";\nimport { Page } from \"../../constants/brokers\";\nimport { useAuth } from \"../../contexts/AuthContext\";\nimport { FormModal } from \"../../components/FormModal\";\nimport { apiPayment } from \"../../services/apiPayment\";\nimport { DrawerModal } from \"../../components/DrawerModal\";\nimport { PaymentModal } from \"../../components/PaymentModal\";\nimport { Content, BolsaOperations } from \"./styles\";\nimport DeleteConfirmationModal from \"../../components/DeleteConfirmationModal\";\nimport {\n ImpostoTotalRendimentosAutonomos,\n ModalAutonomos,\n ModalDependentes,\n ModalPensao,\n ModalPrevidencia,\n RendimentoFormItemRows,\n RendimentosImpostosDevidos,\n} from \"../../constants/rendimentos\";\nimport {\n formatCurrency,\n maskCpf,\n currencyToNumber,\n download,\n errorMessage,\n} from \"../../utils\";\nimport {\n minDarfPrice,\n maxDarfPrice,\n maxPixPayment,\n maxCreditCardPayment,\n} from \"../../constants/darf\";\nimport { IMonthStock, Iimpostos } from \"./interfaces\";\nimport api from \"../../services/apiExterior\";\n\ninterface DarfBolsaProps {\n item: Page;\n yearView: number;\n monthView: number;\n closeModal: () => void;\n view?: boolean;\n viewEdit?: boolean;\n}\n\nexport const AutonomosDarf: React.FC = ({\n view,\n viewEdit,\n yearView,\n monthView,\n closeModal,\n}) => {\n const navigate = useNavigate()\n const { state } = useLocation();\n const { user, showUserPlanModal, userPlanModal, hasPlan } = useAuth();\n\n const today = new Date();\n const queryYear = (state as any)?.year as number;\n const queryMonth = (state as any)?.month as number;\n const currentMonth = today.getMonth();\n const currentYear = today.getFullYear();\n const initialMonth = queryMonth\n ? queryMonth - 1\n : typeof monthView === \"number\"\n ? monthView\n : today.getMonth();\n const initialYear = queryYear\n ? queryYear\n : typeof yearView === \"number\"\n ? yearView\n : today.getFullYear();\n window.history.replaceState({}, document.title);\n\n const month = initialMonth;\n const year = initialYear;\n const isSaveItens = useRef(false);\n const [darf, setDarf] = useState<{ id: string }>();\n const [id, setId] = useState(\"\");\n const [loading, setLoading] = useState(false);\n const [itemIndex, setItemIndex] = useState(0);\n const [emitting, setEmitting] = useState(false);\n const [helpModal, setHelpModal] = useState();\n const [paymentData, setPaymentData] = useState();\n const [paymentModal, setPaymentModal] = useState(false);\n const [showDeleteModal, setShowDeleteModal] = useState(false);\n const [monthStock, setMonthStock] = useState([]);\n const [showRendimentoModal, setShowRendimentoModal] = useState(false);\n const [loadingDarfButton, setLoadingDarfButton] = useState(false);\n const [item, setItem] = useState({\n valorRendimento: 0,\n taxaCambio: 2.5,\n tipo: \"Dividendos no exterior\",\n });\n const [impostos, setImpostos] = useState({\n totalRendimentos: 0,\n baseTributaria: 0,\n aliquotaDevida: 0,\n impostoDevido: 0,\n impostoTotal: 0,\n totalDeducoes: 0,\n totalDependentes: 0,\n totalDespesas: 0,\n totalPensao: 0,\n totalPrevidencia: 0,\n impostoAcumulado: 0,\n juros: 0,\n multa: 0,\n gastosExterior: 0,\n payed: false,\n emitted: false,\n });\n\n const valorImpostoTotal =\n Number(\n Math.max(\n 0,\n impostos.impostoDevido +\n (impostos.impostoAcumulado || 0) -\n (impostos.gastosExterior || 0) +\n (impostos.multa || 0) +\n (impostos.juros || 0)\n )\n ) ?? 0;\n\n const handlePlanModal = () => {\n navigate('/planos')\n };\n\n const handleSaveMonth = () => {\n handleEventDarfButton(true);\n };\n\n const handleEventDarfButton = async (justSave?: boolean) => {\n setLoadingDarfButton(true);\n let retPlanInfo = {\n data: {\n active: false,\n type: \"\",\n },\n };\n try {\n retPlanInfo = await apiPayment.get(\"/user-plan/plan-info\");\n } catch (err) {\n console.error(err);\n }\n\n if (!retPlanInfo.data?.active && !retPlanInfo.data?.type) {\n handlePlanModal()\n setLoadingDarfButton(false);\n return\n }\n if (justSave) {\n generateDarf(true, true)\n setLoadingDarfButton(false);\n return\n }\n if (impostos.impostoDevido || 0 <= maxDarfPrice) {\n handleOpenPaymentModal()\n setLoadingDarfButton(false);\n return\n }\n\n // !retPlanInfo.data?.active && !retPlanInfo.data?.type\n // ? handlePlanModal()\n // : justSave\n // ? generateDarf(true, true)\n // : impostos.impostoDevido || 0 <= maxDarfPrice\n // ? handleOpenPaymentModal()\n // : handleOpenDarfModal();\n handleOpenDarfModal()\n setLoadingDarfButton(false);\n };\n\n const handleLabelButton: ReactNode = useMemo(() => {\n if ((impostos?.impostoDevido || 0) <= maxDarfPrice) return \"Pagar DARF\";\n else return \"Emitir DARF\";\n }, [impostos?.impostoDevido]);\n\n const ActionButtons = (\n \n {!view && (\n \n {!(month === currentMonth && year === currentYear) &&\n (valorImpostoTotal ?? 0) < minDarfPrice &&\n (!view\n ? monthStock.filter((m) => m.tipo !== \"Pensão Alimentícia\")\n : monthStock\n )?.length > 0 && (\n \n
\n \n O valor do imposto devido é menor que{\" \"}\n {formatCurrency(minDarfPrice)}. Você não precisa emitir\n uma DARF para este mês. Clique aqui para regularizar este\n mês.\n \n }>\n {\n handleRegularize(true);\n }}>\n Salvar sem emitir DARF\n \n \n \n )}\n {valorImpostoTotal >= minDarfPrice && (\n \n
\n target.parentElement!}\n title={\n month === currentMonth && year === currentYear\n ? \"Aguarde o encerramento do mês para pagar seu DARF\"\n : \"\"\n }>\n handleEventDarfButton()}\n disabled={\n loading ||\n emitting ||\n (month === currentMonth && year === currentYear)\n }>\n {handleLabelButton}\n {\" \"}\n \n \n )}\n
\n )}\n {!(month === currentMonth && year === currentYear) && (\n \n \n \n Salvar apenas\n \n \n \n )}\n \n );\n\n const buildCalcTaxBody = useCallback(() => {\n return {\n numeroDependentes: impostos.totalDependentes,\n gastosAutonomos: impostos.totalDespesas,\n gastosPrevidencia: impostos.totalPrevidencia,\n gastosPensao: impostos.totalPensao,\n gastosExterior: impostos.gastosExterior,\n };\n }, [\n impostos.totalDependentes,\n impostos.totalDespesas,\n impostos.totalPensao,\n impostos.totalPrevidencia,\n impostos.gastosExterior,\n ]);\n\n const calcTaxes = useCallback(async () => {\n setLoading(true);\n if (!view) {\n const deducoes = buildCalcTaxBody();\n const response = await api.post(\"/rendimentos/calc-tax\", {\n ...deducoes,\n rendimentos: monthStock,\n year,\n month: month + 1,\n impostoAcumulado: impostos.impostoAcumulado,\n gastosExterior: impostos.gastosExterior,\n });\n const { data } = response;\n setImpostos((currentValue) => {\n return {\n ...currentValue,\n aliquotaDevida: data.aliquotaDevida,\n baseTributaria: data.baseTributaria,\n impostoDevido: data.impostoDevido,\n impostoTotal: data.impostoTotal,\n juros: data.juros,\n multa: data.multa,\n totalDeducoes: data.totalDeducoes,\n totalRendimentos: data.totalRendimentos,\n };\n });\n }\n setLoading(false);\n }, [\n view,\n buildCalcTaxBody,\n monthStock,\n year,\n month,\n impostos.impostoAcumulado,\n impostos.gastosExterior,\n ]);\n\n const setPayData = useCallback(() => {\n const valueToCharge = Math.max(\n 0,\n (impostos?.impostoDevido || 0) +\n (impostos.impostoAcumulado || 0) -\n (impostos.gastosExterior || 0) +\n (impostos.juros || 0) +\n (impostos.multa || 0)\n );\n\n const dataToPayment = {\n cpf: user.user.cpf,\n name: user.user.name,\n valueCharge: valueToCharge,\n institution: \"velotax-rendimentos\",\n impostoDevido: impostos.impostoDevido,\n totalImpostoDevido: impostos.impostoTotal,\n impostoTotalFinal: valueToCharge,\n totalRendimentos: impostos.totalRendimentos,\n baseTributaria: impostos.baseTributaria,\n totalDependentes: impostos.totalDependentes,\n totalDespesas: impostos.totalDespesas,\n totalPrevidencia: impostos.totalPrevidencia,\n totalPensao: impostos.totalPensao,\n totalDeducoes: impostos.totalDeducoes,\n aliquotaDevida: impostos.aliquotaDevida,\n impostoAcumulado: impostos.impostoAcumulado,\n gastosExterior: impostos.gastosExterior,\n juros: impostos.juros,\n multa: impostos.multa,\n transactions: monthStock,\n year,\n month: month + 1,\n };\n\n setPaymentData(dataToPayment);\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [impostos, month, year]);\n\n const getRendimentos = useCallback(async () => {\n if (!monthView && !yearView) return;\n setLoading(true);\n const response = await api.get(`/dividendos/rendimentos`, {\n params: { year, month: month + 1 },\n });\n const { data } = response;\n setId(data._id || \"\");\n setMonthStock(data.monthStock || []);\n const currentImpostos = {\n totalRendimentos: data?.totalRendimentos || 0,\n baseTributaria: data?.baseTributaria || 0,\n aliquotaDevida: data?.aliquotaDevida || 0,\n impostoDevido: data?.impostoDevido || 0,\n totalDeducoes: data?.totalDeducoes || 0,\n totalDependentes: data?.totalDependentes || 0,\n totalDespesas: data?.totalDespesas || 0,\n totalPensao: data?.totalPensao || 0,\n totalPrevidencia: data?.totalPrevidencia || 0,\n juros: data?.juros || 0,\n multa: data?.multa || 0,\n impostoTotal:\n (data.impostoDevido || 0) + (data.juros || 0) + (data.multa || 0),\n impostoAcumulado: data?.impostoAcumulado || 0,\n gastosExterior: data?.gastosExterior || 0,\n payed: data?.payed || false,\n emitted: data?.emitted || false,\n };\n setImpostos(currentImpostos);\n setLoading(false);\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n\n const getRendimento = useCallback(async () => {\n setLoading(true);\n const response = await api.get(\"/darf/getById\", {\n params: { id: darf?.id },\n });\n const { data } = response;\n setMonthStock(data.transactions || []);\n const currentImpostos = {\n totalRendimentos: data.totalRendimentos || 0,\n baseTributaria: data.baseTributaria || 0,\n aliquotaDevida: data.aliquotaDevida || 0,\n impostoDevido: data.impostoDevido || 0,\n totalDeducoes: data.totalDeducoes || 0,\n totalDependentes: data.totalDependentes || 0,\n totalDespesas: data.totalDespesas || 0,\n totalPensao: data.totalPensao || 0,\n totalPrevidencia: data.totalPrevidencia || 0,\n juros: data.juros || 0,\n multa: data.multa || 0,\n impostoAcumulado: data.impostoAcumulado || 0,\n impostoTotal:\n (data.impostoDevido || 0) + (data.juros || 0) + (data.multa || 0),\n gastosExterior: data.gastosExterior || 0,\n payed: data.payed || false,\n emitted: data.emitted || false,\n };\n setImpostos(currentImpostos);\n setLoading(false);\n }, [darf]);\n\n useEffect(() => {\n setPayData();\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [setPayData, impostos]);\n\n useEffect(() => {\n if (view && darf) getRendimento();\n else getRendimentos();\n }, [getRendimentos, getRendimento, view, darf]);\n\n const buildNewImpostos = useCallback(() => {\n return {\n monthStock,\n year,\n month: month + 1,\n juros: impostos.juros,\n multa: impostos.multa,\n userCode: user.user.cpf,\n total: impostos.impostoTotal,\n impostoDevido: impostos.impostoDevido,\n totalRendimentos: impostos.totalRendimentos,\n baseTributaria: impostos.baseTributaria,\n aliquotaDevida: impostos.aliquotaDevida,\n totalDependentes: impostos.totalDependentes,\n totalDespesas: impostos.totalDespesas,\n totalPrevidencia: impostos.totalPrevidencia,\n totalPensao: impostos.totalPensao,\n totalDeducoes: impostos.totalDeducoes,\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [impostos, year, month, user]);\n\n const saveItems = useCallback(\n async (rendimentos, variable?, value?) => {\n setLoading(true);\n const newImpostos = buildNewImpostos();\n if (id !== \"\") {\n await api.put(\"/dividendos/rendimentos/\", {\n _id: id,\n ...newImpostos,\n monthStock: rendimentos || monthStock,\n [variable]: value,\n });\n } else {\n const { data } = await api.post(\"/rendimentos\", {\n ...newImpostos,\n monthStock: rendimentos || monthStock,\n [variable]: value,\n });\n setId(data._id);\n }\n setLoading(false);\n getRendimentos();\n },\n // eslint-disable-next-line react-hooks/exhaustive-deps\n [id, buildNewImpostos, getRendimentos, year]\n );\n\n const generateDarf = async (pixValue: boolean, justSave?: boolean) => {\n setLoading(true);\n const { data } = await MsDarf.post(\"/darf\", {\n month: month + 1,\n year,\n cpf: user.user.cpf,\n name: user.user.name,\n paymentInfo: {\n clientInfo: {\n document: user.user.cpf,\n email: user.user.email,\n name: user.user.name,\n phone: \"\",\n },\n },\n insertPix: pixValue,\n valueCharge: Math.max(\n 0,\n impostos.impostoDevido +\n impostos.impostoAcumulado -\n impostos.gastosExterior +\n impostos.juros +\n impostos.multa\n ),\n institution: \"exterior-warren\",\n impostoDevido: impostos.impostoDevido,\n totalImpostoDevido: impostos.impostoDevido,\n totalRendimentos: impostos.totalRendimentos,\n baseTributaria: impostos.baseTributaria,\n totalDependentes: impostos.totalDependentes,\n totalDespesas: impostos.totalDespesas,\n totalPrevidencia: impostos.totalPrevidencia,\n totalPensao: impostos.totalPensao,\n totalDeducoes: impostos.totalDeducoes,\n aliquotaDevida: impostos.aliquotaDevida,\n impostoAcumulado: impostos.impostoAcumulado,\n juros: impostos.juros,\n multa: impostos.multa,\n transactions: monthStock,\n from: 18,\n gastosExterior: impostos.gastosExterior,\n justSave,\n });\n\n if (!justSave) {\n window.location.href = data.darfUrl;\n }\n setLoading(false);\n closeModal();\n // if (impostos.impostoTotal <= maxDarfPrice) {\n // handleOpenPaymentModal();\n // }\n };\n\n const handleRegularize = (regular: boolean) => {\n setLoading(true);\n setEmitting(true);\n api\n .post(\"transaction/regularize\", {\n year,\n month: month + 1,\n regular,\n })\n .then((res) => {\n if (res.data?.darfUrl) {\n download(res.data.darfUrl);\n }\n closeModal();\n message.success(\"Dados salvos\");\n })\n .catch(() => message.error(errorMessage))\n .catch((err) => console.log(\"err\", err))\n .finally(() => {\n setEmitting(false);\n setLoading(false);\n });\n };\n\n const handleCloseItemModal = useCallback(() => {\n setShowRendimentoModal(false);\n unsetItem();\n }, []);\n\n const addItem = async (data: IMonthStock) => {\n data.tipo = \"Dividendos no exterior\"\n // if (data.tipo === \"Exterior\") {\n // data.impostoPagoExterior = data?.impostoPagoExterior || 0;\n // }\n const rendimentos = [...monthStock, data];\n setMonthStock(rendimentos);\n saveItems(rendimentos);\n handleCloseItemModal();\n };\n\n const editItem = (data: IMonthStock) => {\n data.tipo = \"Dividendos no exterior\"\n // if (data.tipo === \"Exterior\") {\n // data.impostoPagoExterior = data?.impostoPagoExterior || 0;\n // }\n const aux = [...monthStock];\n aux.splice(itemIndex, 1, data);\n setMonthStock(aux);\n saveItems(aux);\n handleCloseItemModal();\n };\n\n const removeAsset = async () => {\n const aux = [...monthStock];\n aux.splice(itemIndex, 1);\n setMonthStock(aux);\n saveItems(aux);\n if (!isSaveItens.current) isSaveItens.current = true;\n };\n\n const handleAdd = (event: React.MouseEvent) => {\n event.stopPropagation();\n unsetItem();\n setShowRendimentoModal(true);\n };\n\n const handleEdit = (item: IMonthStock, index: number) => {\n setShowRendimentoModal(true);\n setItemIndex(index);\n setItem(item);\n };\n\n const handleRemove = (item: IMonthStock, index: number) => {\n setShowDeleteModal(true);\n setItemIndex(index);\n setItem(item);\n };\n\n const unsetItem = () => {\n setItem(null);\n };\n\n const handleCloseDeleteModal = () => {\n setShowDeleteModal(false);\n unsetItem();\n };\n\n const onCloseHelpModal = () => {\n setHelpModal(undefined);\n };\n\n const handleOpenDarfModal = (value?: boolean) => {\n const pixValue = value ?? false;\n generateDarf(pixValue);\n };\n\n const handleOpenPaymentModal = () => {\n setPaymentModal(true);\n };\n\n const handleClosePaymentModal = () => {\n setPaymentModal(false);\n };\n\n const changeInputState = (variable: string, value: string) => {\n const auxValue =\n variable !== \"totalDependentes\" ? currencyToNumber(value) : Number(value);\n setImpostos((currentValue) => {\n return {\n ...currentValue,\n [variable]: auxValue,\n };\n });\n saveItems(undefined, variable, auxValue);\n };\n\n return (\n \n \n \n
\n {!hasPlan && (\n
\n \n Contrate o plano premium para ver os impostos devidos\n \n }\n onClick={() => {\n try {\n handlePlanModal();\n closeModal();\n } catch (error) {\n console.warn(error);\n }\n }}>\n PREMIUM\n \n
\n )}\n \n {RendimentosImpostosDevidos.map((description) => (\n \n {loading ? : description.render(impostos)}\n \n ))}\n \n
\n\n
\n\n \n Rendimentos\n }>\n {hasPlan && !view ? (\n }>\n Adicionar\n \n ) : null}\n m.tipo !== \"Pensão Alimentícia\")\n : monthStock\n }\n renderItem={(item, index) => (\n handleEdit(item, index)}\n icon={}\n />,\n handleRemove(item, index)}\n icon={}\n />,\n ]\n }>\n \n Rendimento #{index + 1}}\n description={\n
\n
Tipo: {item.tipo}
\n
\n Valor: {formatCurrency(item.valorRendimento || 0)}\n
\n {item.cpfPagador && (\n
\n CPF do pagador: {maskCpf(item.cpfPagador)}\n
\n )}\n {item.cpfBeneficiario && (\n
\n CPF do beneficiário:{\" \"}\n {maskCpf(item.cpfBeneficiario)}\n
\n )}\n {(item?.tipo === \"Exterior\" ||\n item?.tipo === \"Dividendos no exterior\") && (\n
\n Imposto Pago no Exterior:{\" \"}\n {formatCurrency(item.impostoPagoExterior ?? 0)}\n
\n )}\n {item?.tipo === \"Dividendos no exterior\" && (\n <>\n
Ativo: {item.ativo ?? \"\"}
\n \n )}\n
\n }\n />\n
\n \n )}\n />\n \n \n\n {hasPlan &&
}\n\n {hasPlan && (\n <>\n
\n \n Deduções Tributárias\n \n
\n \n
\n \n setHelpModal(ModalDependentes)}\n />\n Dependentes\n \n\n \n setHelpModal(ModalAutonomos)}\n />\n Gastos Autônomos\n \n\n \n setHelpModal(ModalPrevidencia)}\n />\n Gastos Previdência\n \n\n \n setHelpModal(ModalPensao)}\n />\n Gastos Pensão\n \n
\n
\n
\n \n {\n changeInputState(\"totalDependentes\", e);\n }}\n />\n \n \n \n changeInputState(\"totalDespesas\", e.target.value)\n }\n />\n \n \n \n changeInputState(\"totalPrevidencia\", e.target.value)\n }\n />\n \n \n \n changeInputState(\"totalPensao\", e.target.value)\n }\n />\n \n
\n
\n
\n \n )}\n\n {hasPlan &&
}\n\n {hasPlan && (\n <>\n \n Imposto total\n \n {loading ? (\n \n ) : (\n formatCurrency(valorImpostoTotal)\n )}\n \n \n \n {ImpostoTotalRendimentosAutonomos.map((description: any) => (\n \n {loading ? (\n \n ) : description.Component ? (\n \n ) : (\n formatCurrency(\n Number(impostos[description.id as keyof Iimpostos] || 0)\n )\n )}\n \n ))}\n \n \n )}\n\n {!view && hasPlan && {ActionButtons}}\n
\n \n\n maxPixPayment}\n disableCreditCardOption={\n (paymentData?.valueCharge || 0) > maxCreditCardPayment\n }\n show={paymentModal}\n onCancel={handleClosePaymentModal}\n paymentData={paymentData}\n callDarf={(value: boolean) => handleOpenDarfModal(value)}\n maxPixValue={maxPixPayment}\n maxCCValue={maxCreditCardPayment}\n selectedYear={year}\n closeDarfModal={closeModal}\n />\n \n {helpModal?.content}\n \n \n Promise.resolve(removeAsset())}\n body=\"Você realmente quer deletar esse ativo?\"\n />\n \n );\n};\n","import styled from \"styled-components\";\n\nexport const Container = styled.div`\n padding: 64px 32px 128px;\n @media only screen and (max-device-width: 812px) {\n padding: 0;\n }\n`;\n\nexport const Content = styled.div`\n background-color: var(--velotax-background-color);\n border-radius: 16px;\n margin: 0 auto;\n padding: 32px;\n min-width: 500px;\n max-width: 800px;\n h1 {\n font-size: 24px;\n position: relative;\n margin-bottom: 32px;\n color: var(--velotax-font-color);\n &::before {\n content: \"\";\n position: absolute;\n width: 4px;\n top: 0;\n left: -32px;\n height: 100%;\n background-color: var(--ant-primary-color);\n }\n }\n @media only screen and (max-device-width: 812px) {\n border-radius: 0;\n min-width: 100%;\n padding: 16px;\n padding-bottom: 32px;\n h1 {\n &::before {\n display: none;\n }\n }\n }\n`;\n","import React, { Dispatch, SetStateAction, useEffect, useState } from \"react\";\nimport { Col, Divider, Form, Input, message, Modal, Row } from \"antd\";\nimport Button from \"../../Button\";\nimport apis from \"../../../services/apiExterior\";\nimport { useAuth } from \"../../../contexts/AuthContext\";\n// import passfolioLogo from \"../../../assets/passfolio-logo.png\";\nimport { validationFieldRequired } from \"../../../utils/formValidations\";\nimport { IntegrationData } from \"../interfaces\";\n\ninterface IPassfolioIntegrationModalProps {\n visible: boolean;\n dependentId?: string;\n setVisible: Dispatch>;\n setLoadingIntegration: Dispatch>;\n integrationData?: IntegrationData;\n}\n\nconst PassfolioIntegrationModal: React.FC = ({\n visible,\n setVisible,\n setLoadingIntegration,\n integrationData,\n}) => {\n const { user } = useAuth();\n const [form] = Form.useForm();\n const [integrationParams, setParams] = useState({\n key: \"\",\n userId: \"\",\n secret: \"\",\n token: \"\",\n });\n\n useEffect(() => {\n if (integrationData && visible) {\n form.setFieldsValue({\n key: integrationData.key,\n secret: integrationData.secret,\n userId: integrationData.userId,\n });\n }\n }, [form, integrationData, visible]);\n\n const onCancel = () => {\n setVisible(false);\n form.resetFields();\n };\n\n const onFinish = (values: any) => {\n setLoadingIntegration(true);\n apis\n .post(\n \"/passfolio/authenticate\",\n {\n ...values,\n },\n {\n headers: {\n \"x-api-provider\": \"exterior-velotax\",\n },\n }\n )\n .then((response) => {\n const { data } = response;\n const { token, authenticatorId } = data;\n const { key, secret } = values;\n\n setParams({ key, secret, userId: authenticatorId, token });\n })\n .catch((err) => {\n if (err.response?.data?.message) {\n message.error(\n err.response?.data?.message ||\n \"Algo deu errado, tente novamente mais tarde\"\n );\n }\n setLoadingIntegration(false);\n });\n };\n\n const onClick = (values: any) => {\n setLoadingIntegration(true);\n setVisible(false);\n apis\n .post(\n \"/passfolio/integrate\",\n {\n ...values,\n ...integrationParams,\n email: user.user.email,\n },\n {\n headers: {\n \"x-api-provider\": \"exterior-velotax\",\n },\n }\n )\n .catch((err) => {\n if (err.response?.data?.message) {\n message.error(\n err.response?.data?.message ||\n \"Algo deu errado, tente novamente mais tarde\"\n );\n }\n setParams({\n key: \"\",\n userId: \"\",\n secret: \"\",\n token: \"\",\n });\n setLoadingIntegration(false);\n });\n };\n\n return (\n \n \n Integrar com a Warren\n \n }\n >\n \n