@credithub/harlan-components 1.25.0 → 1.26.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/@types/domain/index.d.ts +35 -0
- package/dist/assets/icones/chequesSemFundo.d.ts +1 -1
- package/dist/assets/icones/consultaSimples.d.ts +1 -1
- package/dist/assets/icones/contasBancarias.d.ts +1 -1
- package/dist/assets/icones/contato.d.ts +1 -1
- package/dist/assets/icones/dividasVencidasSerasa.d.ts +1 -1
- package/dist/assets/icones/dividasVencidasSerasa.js +1 -1
- package/dist/assets/icones/dominios.d.ts +1 -1
- package/dist/assets/icones/dominios.js +1 -1
- package/dist/assets/icones/endereco.d.ts +1 -1
- package/dist/assets/icones/endereco.js +1 -1
- package/dist/assets/icones/imoveis.d.ts +1 -1
- package/dist/assets/icones/imoveis.js +1 -1
- package/dist/assets/icones/pefinRefinBoaVista.d.ts +1 -1
- package/dist/assets/icones/pefinRefinBoaVista.js +1 -1
- package/dist/assets/icones/pefinRefinSerasa.d.ts +1 -1
- package/dist/assets/icones/pefinRefinSerasa.js +1 -1
- package/dist/assets/icones/processosJuridicos.d.ts +1 -1
- package/dist/assets/icones/processosJuridicos.js +1 -1
- package/dist/assets/icones/protestos.d.ts +1 -1
- package/dist/assets/icones/protestos.js +1 -1
- package/dist/assets/icones/protestosCredito.d.ts +1 -1
- package/dist/assets/icones/protestosCredito.js +1 -1
- package/dist/assets/icones/protestosGerais.d.ts +1 -1
- package/dist/assets/icones/protestosGerais.js +1 -1
- package/dist/assets/icones/protestosImpostos.d.ts +1 -1
- package/dist/assets/icones/protestosImpostos.js +1 -1
- package/dist/assets/icones/quadroSocietario.d.ts +1 -1
- package/dist/assets/icones/resumoNegativacoes.d.ts +1 -1
- package/dist/assets/icones/resumoNegativacoes.js +1 -1
- package/dist/assets/icones/scoreBoaVista.d.ts +1 -1
- package/dist/assets/icones/scoreBoaVista.js +1 -1
- package/dist/assets/icones/scr.d.ts +1 -1
- package/dist/assets/icones/scr.js +1 -1
- package/dist/assets/icones/ultimaMovimentacao.d.ts +1 -1
- package/dist/assets/icones/ultimaMovimentacao.js +1 -1
- package/dist/assets/icones/veiculos.d.ts +1 -1
- package/dist/assets/icones/veiculos.js +1 -1
- package/dist/components/adresses/addresses.d.ts +0 -12
- package/dist/components/adresses/addresses.js +26 -5
- package/dist/components/bank-accounts/bank-accounts.js +40 -10
- package/dist/components/ccf/ccf.js +12 -4
- package/dist/components/ccf/ccfList.d.ts +1 -7
- package/dist/components/ccf/ccfList.js +3 -3
- package/dist/components/consultaSimplesSection/consultaSimplesSection.js +2 -2
- package/dist/components/consultasComplementares.d.ts +1 -4
- package/dist/components/consultasComplementares.js +0 -1
- package/dist/components/contacts/contactLikeDislikeSection.d.ts +1 -1
- package/dist/components/contacts/contactLikeDislikeSection.js +4 -3
- package/dist/components/contacts/contacts.d.ts +0 -8
- package/dist/components/contacts/contacts.js +42 -11
- package/dist/components/dividasPublicas/dividasPublicas.js +39 -48
- package/dist/components/dividasPublicas/dividasPublicasList.d.ts +6 -0
- package/dist/components/dividasPublicas/dividasPublicasList.js +20 -0
- package/dist/components/dossie/dossie.js +28 -8
- package/dist/components/dossie/dossieData.d.ts +2 -0
- package/dist/components/dossie/dossieData.js +59 -0
- package/dist/components/imoveis/imoveisService.js +25 -7
- package/dist/components/interface/header.d.ts +1 -1
- package/dist/components/interface/header.js +2 -2
- package/dist/components/liminar/liminar.js +21 -3
- package/dist/components/partners/partners.js +27 -9
- package/dist/components/pep/pep.js +21 -3
- package/dist/components/processos-juridicos/envolvidosList.d.ts +1 -1
- package/dist/components/processos-juridicos/processosJuridicos.js +9 -2
- package/dist/components/processos-juridicos/processosJuridicosList.d.ts +1 -1
- package/dist/components/protestos/protestos.js +15 -4
- package/dist/components/protestos/protestosList.d.ts +0 -26
- package/dist/components/protestos/protestosList.js +4 -19
- package/dist/components/reclameAqui/reclameAquiCarousel.js +27 -47
- package/dist/components/reclameAqui/styles.d.ts +14 -0
- package/dist/components/reclameAqui/styles.js +17 -0
- package/dist/components/refinBoaVista/refinBoaVista.js +28 -13
- package/dist/components/refinSerasa/refinSerasa.js +15 -8
- package/dist/components/score/scoreService.js +29 -7
- package/dist/components/scr/getResumoDeCreditos.d.ts +1 -1
- package/dist/components/scr/getResumoDeCreditos.js +1 -1
- package/dist/components/scr/getResumoDeModalidades.d.ts +1 -1
- package/dist/components/scr/getResumoDeModalidades.js +1 -1
- package/dist/components/scr/scr.js +19 -5
- package/dist/components/veiculos/veiculos.d.ts +2 -19
- package/dist/components/veiculos/veiculos.js +50 -30
- package/dist/components/webservice.d.ts +4 -3
- package/dist/components/webservice.js +0 -3
- package/dist/constants/reclameAqui.d.ts +9 -0
- package/dist/constants/reclameAqui.js +9 -0
- package/dist/consultaSimples.js +1 -1
- package/dist/contexts/globalDataContext.d.ts +2 -1
- package/lib/cjs/index.js +1180 -853
- package/lib/esm/index.js +1180 -853
- package/package.json +1 -1
- package/dist/components/imoveis/types.d.ts +0 -24
- package/dist/components/liminar/types.d.ts +0 -3
- package/dist/components/liminar/types.js +0 -1
- package/dist/components/processos-juridicos/types.d.ts +0 -27
- package/dist/components/processos-juridicos/types.js +0 -1
- package/dist/components/reclameAqui/types.d.ts +0 -31
- package/dist/components/reclameAqui/types.js +0 -1
- package/dist/components/refinBoaVista/types.d.ts +0 -48
- package/dist/components/refinBoaVista/types.js +0 -4
- package/dist/components/refinSerasa/types.d.ts +0 -48
- package/dist/components/refinSerasa/types.js +0 -1
- package/dist/components/score/types.d.ts +0 -12
- package/dist/components/score/types.js +0 -1
- package/dist/components/scr/types.d.ts +0 -87
- package/dist/components/scr/types.js +0 -1
- package/dist/components/veiculos/types.d.ts +0 -0
- package/dist/components/veiculos/types.js +0 -0
- package/dist/types/globalState.d.ts +0 -8
- package/dist/types/globalState.js +0 -1
- /package/dist/{components/imoveis/types.js → @types/domain/index.js} +0 -0
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/// <reference types="@/@types/domain/addressesTypes" />
|
|
2
|
+
/// <reference types="@/@types/domain/bankAccountTypes" />
|
|
3
|
+
/// <reference types="@/@types/domain/ccfTypes" />
|
|
4
|
+
/// <reference types="@/@types/domain/contactTypes" />
|
|
5
|
+
/// <reference types="@/@types/domain/dividasTypes" />
|
|
6
|
+
/// <reference types="@/@types/domain/dossieTypes" />
|
|
7
|
+
/// <reference types="@/@types/domain/imoveisTypes" />
|
|
8
|
+
/// <reference types="@/@types/domain/liminarTypes" />
|
|
9
|
+
/// <reference types="@/@types/domain/partnersTypes" />
|
|
10
|
+
/// <reference types="@/@types/domain/pepTypes" />
|
|
11
|
+
/// <reference types="@/@types/domain/processosJuridicosTypes" />
|
|
12
|
+
/// <reference types="@/@types/domain/protestosTypes" />
|
|
13
|
+
/// <reference types="@/@types/domain/refinBoaVistaTypes" />
|
|
14
|
+
/// <reference types="@/@types/domain/refinSerasaTypes" />
|
|
15
|
+
/// <reference types="@/@types/domain/scoreTypes" />
|
|
16
|
+
/// <reference types="@/@types/domain/scrTypes" />
|
|
17
|
+
/// <reference types="@/@types/domain/veiculosTypes" />
|
|
18
|
+
export type { Address, AddressesState } from '@/@types/domain/addressesTypes';
|
|
19
|
+
export type { BankAccount, BankAccountsState } from '@/@types/domain/bankAccountTypes';
|
|
20
|
+
export type { CCFData, CCFState } from '@/@types/domain/ccfTypes';
|
|
21
|
+
export type { Contact, ContactsState } from '@/@types/domain/contactsTypes';
|
|
22
|
+
export type { Divida, DividasPublicasState } from '@/@types/domain/dividasTypes';
|
|
23
|
+
export type { CarouselState, DossieState, SummaryState, TransactionTableState } from '@/@types/domain/dossieTypes';
|
|
24
|
+
export type { IPTUItem, ImoveisConsultaResponse } from '@/@types/domain/imoveisTypes';
|
|
25
|
+
export type { LiminarResponse } from '@/@types/domain/liminarTypes';
|
|
26
|
+
export type { Partner, PartnersState } from '@/@types/domain/partnersTypes';
|
|
27
|
+
export type { PepData, PepState } from '@/@types/domain/pepTypes';
|
|
28
|
+
export type { EnvolvidoUltimaMovimentacao, ProcessoJuridicoResume, ProcessosJuridicosState } from '@/@types/domain/processosJuridicosTypes';
|
|
29
|
+
export type { ProtestoData, ProtestosState } from '@/@types/domain/protestosTypes';
|
|
30
|
+
export type { ReclameAquiResponse, ReclameAquiState } from '@/@types/domain/reclameAquiTypes';
|
|
31
|
+
export type { RefinBoaVistaResponse, RefinBoaVistaState, Spc } from '@/@types/domain/refinBoaVistaTypes';
|
|
32
|
+
export type { PefinRefinSerasaResponse, RefinSerasaState } from '@/@types/domain/refinSerasaTypes';
|
|
33
|
+
export type { ScoreResponse, ScoreState } from '@/@types/domain/scoreTypes';
|
|
34
|
+
export type { Detalhamento, ResumoListProps, SCRListProps, SCRQuery, SCRResponse, SCRState, Vencimento } from '@/@types/domain/scrTypes';
|
|
35
|
+
export type { RegistroVeiculo, VeiculosState } from '@/@types/domain/veiculosTypes';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import theme from '../../components/interface/theme';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
var DividasVencidasSerasaIcon = function (_a) {
|
|
4
4
|
var _b = _a.className, className = _b === void 0 ? '' : _b, _c = _a.size, size = _c === void 0 ? 30 : _c, _d = _a.circleFill, circleFill = _d === void 0 ? theme.colors.azulCredithub : _d;
|
|
5
5
|
return (React.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: size, height: size, fill: "none", viewBox: "0 0 30 30", className: className },
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import theme from '../../components/interface/theme';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
var DominiosIcon = function (_a) {
|
|
4
4
|
var _b = _a.className, className = _b === void 0 ? '' : _b, _c = _a.size, size = _c === void 0 ? 30 : _c, _d = _a.circleFill, circleFill = _d === void 0 ? theme.colors.azulCredithub : _d;
|
|
5
5
|
return (React.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: size, height: size, fill: "none", viewBox: "0 0 30 30", className: className },
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import theme from '../../components/interface/theme';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
function EnderecoIcon(_a) {
|
|
4
4
|
var _b = _a.className, className = _b === void 0 ? '' : _b, _c = _a.size, size = _c === void 0 ? 30 : _c, _d = _a.circleFill, circleFill = _d === void 0 ? theme.colors.azulCredithub : _d;
|
|
5
5
|
return (React.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: size, height: size, className: className, fill: "none", viewBox: "0 0 30 30" },
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import theme from '../../components/interface/theme';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
var ImoveisIcon = function (_a) {
|
|
4
4
|
var _b = _a.className, className = _b === void 0 ? '' : _b, _c = _a.size, size = _c === void 0 ? 30 : _c, _d = _a.circleFill, circleFill = _d === void 0 ? theme.colors.azulCredithub : _d;
|
|
5
5
|
return (React.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: size, height: size, fill: "none", viewBox: "0 0 30 30", className: className },
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import theme from '../../components/interface/theme';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
var PefinRefinBoaVistaIcon = function (_a) {
|
|
4
4
|
var _b = _a.className, className = _b === void 0 ? '' : _b, _c = _a.size, size = _c === void 0 ? 30 : _c, _d = _a.circleFill, circleFill = _d === void 0 ? theme.colors.azulCredithub : _d;
|
|
5
5
|
return (React.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: size, height: size, fill: "none", viewBox: "0 0 30 30", className: className },
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import theme from '../../components/interface/theme';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
var PefinRefinSerasaIcon = function (_a) {
|
|
4
4
|
var _b = _a.className, className = _b === void 0 ? '' : _b, _c = _a.size, size = _c === void 0 ? 30 : _c, _d = _a.circleFill, circleFill = _d === void 0 ? theme.colors.azulCredithub : _d;
|
|
5
5
|
return (React.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: size, height: size, fill: "none", viewBox: "0 0 30 30", className: className },
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import theme from '../../components/interface/theme';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
var ProcessosJuridicosIcon = function (_a) {
|
|
4
4
|
var _b = _a.className, className = _b === void 0 ? '' : _b, _c = _a.size, size = _c === void 0 ? 30 : _c, _d = _a.circleFill, circleFill = _d === void 0 ? theme.colors.azulCredithub : _d;
|
|
5
5
|
return (React.createElement("svg", { width: size, height: size, viewBox: "0 0 30 30", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: className },
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import theme from '../../components/interface/theme';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
var ProtestosIcon = function (_a) {
|
|
4
4
|
var _b = _a.className, className = _b === void 0 ? '' : _b, _c = _a.size, size = _c === void 0 ? 30 : _c, _d = _a.circleFill, circleFill = _d === void 0 ? theme.colors.azulCredithub : _d;
|
|
5
5
|
return (React.createElement("svg", { width: size, height: size, viewBox: "0 0 30 30", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: className },
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import theme from '../../components/interface/theme';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
var ProtestosCreditoIcon = function (_a) {
|
|
4
4
|
var _b = _a.className, className = _b === void 0 ? '' : _b, _c = _a.size, size = _c === void 0 ? 30 : _c, _d = _a.circleFill, circleFill = _d === void 0 ? theme.colors.azulCredithub : _d;
|
|
5
5
|
return (React.createElement("svg", { width: size, height: size, viewBox: "0 0 30 30", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: className },
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import theme from '../../components/interface/theme';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
var ProtestosGeraisIcon = function (_a) {
|
|
4
4
|
var _b = _a.className, className = _b === void 0 ? '' : _b, _c = _a.size, size = _c === void 0 ? 30 : _c, _d = _a.circleFill, circleFill = _d === void 0 ? theme.colors.azulCredithub : _d;
|
|
5
5
|
return (React.createElement("svg", { width: size, height: size, viewBox: "0 0 30 30", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: className },
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import theme from '../../components/interface/theme';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
var ProtestosImpostosIcon = function (_a) {
|
|
4
4
|
var _b = _a.className, className = _b === void 0 ? '' : _b, _c = _a.size, size = _c === void 0 ? 30 : _c, _d = _a.circleFill, circleFill = _d === void 0 ? theme.colors.azulCredithub : _d;
|
|
5
5
|
return (React.createElement("svg", { width: size, height: size, viewBox: "0 0 30 30", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: className },
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import theme from '../../components/interface/theme';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
var ResumoDeNegativacoesIcon = function (_a) {
|
|
4
4
|
var _b = _a.className, className = _b === void 0 ? '' : _b, _c = _a.size, size = _c === void 0 ? 30 : _c, _d = _a.circleFill, circleFill = _d === void 0 ? theme.colors.azulCredithub : _d;
|
|
5
5
|
return (React.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: size, height: size, fill: "none", viewBox: "0 0 30 30", className: className },
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import theme from '../../components/interface/theme';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
var ScoreBoaVistaIcon = function (_a) {
|
|
4
4
|
var _b = _a.className, className = _b === void 0 ? '' : _b, _c = _a.size, size = _c === void 0 ? 30 : _c, _d = _a.circleFill, circleFill = _d === void 0 ? theme.colors.azulCredithub : _d;
|
|
5
5
|
return (React.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: size, height: size, fill: "none", viewBox: "0 0 30 30", className: className },
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import theme from '../../components/interface/theme';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
var ScrIcon = function (_a) {
|
|
4
4
|
var _b = _a.className, className = _b === void 0 ? '' : _b, _c = _a.size, size = _c === void 0 ? 30 : _c, _d = _a.circleFill, circleFill = _d === void 0 ? theme.colors.azulCredithub : _d;
|
|
5
5
|
return (React.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: size, height: size, fill: "none", viewBox: "0 0 30 30", className: className },
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import theme from '../../components/interface/theme';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
var UltimaMovimentacaoIcon = function (_a) {
|
|
4
4
|
var _b = _a.className, className = _b === void 0 ? '' : _b, _c = _a.size, size = _c === void 0 ? 30 : _c, _d = _a.circleFill, circleFill = _d === void 0 ? theme.colors.azulCredithub : _d;
|
|
5
5
|
return (React.createElement("svg", { width: size, height: size, viewBox: "0 0 30 30", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: className },
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
1
|
import theme from '../../components/interface/theme';
|
|
2
|
+
import React from 'react';
|
|
3
3
|
var VeiculosIcon = function (_a) {
|
|
4
4
|
var _b = _a.className, className = _b === void 0 ? '' : _b, _c = _a.size, size = _c === void 0 ? 30 : _c, _d = _a.circleFill, circleFill = _d === void 0 ? theme.colors.azulCredithub : _d;
|
|
5
5
|
return (React.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: size, height: size, fill: "none", viewBox: "0 0 30 30", className: className },
|
|
@@ -1,16 +1,4 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
export type Address = {
|
|
3
|
-
type: string;
|
|
4
|
-
address: string;
|
|
5
|
-
number: string;
|
|
6
|
-
zipcode: string;
|
|
7
|
-
district: string;
|
|
8
|
-
city: string;
|
|
9
|
-
state: string;
|
|
10
|
-
urlMaps: string;
|
|
11
|
-
urlImage: string;
|
|
12
|
-
main?: boolean;
|
|
13
|
-
};
|
|
14
2
|
interface Addresses {
|
|
15
3
|
apiKey: string;
|
|
16
4
|
rfbResponse?: Document;
|
|
@@ -1,3 +1,14 @@
|
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
|
2
|
+
__assign = Object.assign || function(t) {
|
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
4
|
+
s = arguments[i];
|
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
6
|
+
t[p] = s[p];
|
|
7
|
+
}
|
|
8
|
+
return t;
|
|
9
|
+
};
|
|
10
|
+
return __assign.apply(this, arguments);
|
|
11
|
+
};
|
|
1
12
|
var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
|
|
2
13
|
if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
|
|
3
14
|
if (ar || !(i in from)) {
|
|
@@ -7,18 +18,21 @@ var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
|
|
|
7
18
|
}
|
|
8
19
|
return to.concat(ar || Array.prototype.slice.call(from));
|
|
9
20
|
};
|
|
10
|
-
import React, { useContext } from 'react';
|
|
11
|
-
import { Result, ResultContent } from '../interface/result';
|
|
12
|
-
import AddItemField from '../common/addItem';
|
|
13
|
-
import { Queries } from '../webservice';
|
|
14
|
-
import XPathUtils from '../../utils/xpath';
|
|
15
21
|
import EnderecoIcon from '../../assets/icones/endereco';
|
|
22
|
+
import { useGlobalData } from '../../contexts/globalDataContext';
|
|
16
23
|
import { useConsultaRfb } from '../../hooks/useConsultaRfb';
|
|
24
|
+
import XPathUtils from '../../utils/xpath';
|
|
25
|
+
import React, { useContext, useState } from 'react';
|
|
17
26
|
import { uniq } from 'underscore';
|
|
27
|
+
import AddItemField from '../common/addItem';
|
|
28
|
+
import { Result, ResultContent } from '../interface/result';
|
|
29
|
+
import { Queries } from '../webservice';
|
|
18
30
|
var Addresses = function () {
|
|
19
31
|
var ctx = useContext(Queries.Finder);
|
|
20
32
|
var Section = ctx.Section;
|
|
21
33
|
var rfbResponse = useConsultaRfb().rfbResponse;
|
|
34
|
+
var setData = useGlobalData().setData;
|
|
35
|
+
var _a = useState(false), dataUpdated = _a[0], setDataUpdated = _a[1];
|
|
22
36
|
var response = function (data) {
|
|
23
37
|
var _addresses = __spreadArray(__spreadArray([], ((data && XPathUtils.select('//enderecos/enderecos', data)) ||
|
|
24
38
|
[]), true), ((!data &&
|
|
@@ -36,6 +50,13 @@ var Addresses = function () {
|
|
|
36
50
|
urlImage: '',
|
|
37
51
|
urlMaps: ''
|
|
38
52
|
}); }), function (e) { return e.address + e.district; });
|
|
53
|
+
if (!dataUpdated && addresses.length > 0) {
|
|
54
|
+
var addressState_1 = {
|
|
55
|
+
addresses: addresses
|
|
56
|
+
};
|
|
57
|
+
setData(function (prevState) { return (__assign(__assign({}, prevState), { addresses: addressState_1 })); });
|
|
58
|
+
setDataUpdated(true);
|
|
59
|
+
}
|
|
39
60
|
return (React.createElement(Result, { resultContentStriped: true, className: "address" }, addresses === null || addresses === void 0 ? void 0 : addresses.map(function (address, index) { return (React.createElement(ResultContent, { desktop: "repeat(7, 1fr)", tablet: "repeat(4, 1fr)", mobile: "repeat(2, 1fr)", key: index },
|
|
40
61
|
React.createElement(AddItemField, { name: "Tipo", value: address.type, style: { display: 'inline-block' } }),
|
|
41
62
|
React.createElement(AddItemField, { name: "Endere\u00E7o", value: address.address, style: { display: 'inline-block' } }),
|
|
@@ -1,27 +1,57 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
var __assign = (this && this.__assign) || function () {
|
|
2
|
+
__assign = Object.assign || function(t) {
|
|
3
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
4
|
+
s = arguments[i];
|
|
5
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
6
|
+
t[p] = s[p];
|
|
7
|
+
}
|
|
8
|
+
return t;
|
|
9
|
+
};
|
|
10
|
+
return __assign.apply(this, arguments);
|
|
11
|
+
};
|
|
7
12
|
import ContasBancariasIcon from '../../assets/icones/contasBancarias';
|
|
13
|
+
import { useGlobalData } from '../../contexts/globalDataContext';
|
|
14
|
+
import XPathUtils from '../../utils/xpath';
|
|
15
|
+
import React, { useContext, useState } from 'react';
|
|
16
|
+
import AddItemField from '../common/addItem';
|
|
17
|
+
import { Result, ResultContent } from '../interface/result';
|
|
8
18
|
import StatusMessage from '../interface/statusMessage';
|
|
9
19
|
import theme from '../interface/theme';
|
|
20
|
+
import { Queries } from '../webservice';
|
|
10
21
|
var BankAccounts = function () {
|
|
11
22
|
var ctx = useContext(Queries.Finder);
|
|
12
23
|
var Section = ctx.Section;
|
|
24
|
+
var setData = useGlobalData().setData;
|
|
25
|
+
var _a = useState(false), dataUpdated = _a[0], setDataUpdated = _a[1];
|
|
26
|
+
var extractBankAccountData = function (data) {
|
|
27
|
+
var accounts = XPathUtils.selectArray('//bank-info/node', data);
|
|
28
|
+
return accounts.map(function (account) { return ({
|
|
29
|
+
banco: XPathUtils.select('string(banco)', account),
|
|
30
|
+
agencia: XPathUtils.select('string(agencia)', account),
|
|
31
|
+
conta: XPathUtils.select('string(conta)', account)
|
|
32
|
+
}); });
|
|
33
|
+
};
|
|
13
34
|
return (React.createElement(Section, { title: 'Informações de Contas Bancárias', subtitle: 'Vejas as informações disponíveis de contas bancárias.', icon: ContasBancariasIcon, ctx: ctx, minimized: false, onSuccess: function (data) {
|
|
14
|
-
var accounts =
|
|
35
|
+
var accounts = extractBankAccountData(data);
|
|
15
36
|
var message = (accounts === null || accounts === void 0 ? void 0 : accounts.length)
|
|
16
37
|
? (accounts === null || accounts === void 0 ? void 0 : accounts.length) > 1
|
|
17
38
|
? "Encontrada ".concat(accounts === null || accounts === void 0 ? void 0 : accounts.length, " contas banc\u00E1rias")
|
|
18
39
|
: 'Encontrada 1 conta bancária'
|
|
19
40
|
: 'Não foram encontradas ocorrências';
|
|
41
|
+
if (!dataUpdated) {
|
|
42
|
+
if (accounts.length > 0) {
|
|
43
|
+
var bankAccountsData_1 = {
|
|
44
|
+
bankAccounts: accounts
|
|
45
|
+
};
|
|
46
|
+
setData(function (prevState) { return (__assign(__assign({}, prevState), { bankAccountsData: bankAccountsData_1 })); });
|
|
47
|
+
}
|
|
48
|
+
setDataUpdated(true);
|
|
49
|
+
}
|
|
20
50
|
return {
|
|
21
51
|
children: accounts.length ? (React.createElement(Result, null, accounts.map(function (account, key) { return (React.createElement(ResultContent, { key: key },
|
|
22
|
-
React.createElement(AddItemField, { name: "Banco", value:
|
|
23
|
-
React.createElement(AddItemField, { name: "Ag\u00EAncia", value:
|
|
24
|
-
React.createElement(AddItemField, { name: "Conta", value:
|
|
52
|
+
React.createElement(AddItemField, { name: "Banco", value: account.banco }),
|
|
53
|
+
React.createElement(AddItemField, { name: "Ag\u00EAncia", value: account.agencia }),
|
|
54
|
+
React.createElement(AddItemField, { name: "Conta", value: account.conta }))); }))) : null,
|
|
25
55
|
description: React.createElement(StatusMessage, null, message),
|
|
26
56
|
iconProps: {
|
|
27
57
|
circleFill: (accounts === null || accounts === void 0 ? void 0 : accounts.length) ? theme.colors.erro : ''
|
|
@@ -12,7 +12,7 @@ var __assign = (this && this.__assign) || function () {
|
|
|
12
12
|
import ChequesSemFundoIcon from '../../assets/icones/chequesSemFundo';
|
|
13
13
|
import { useGlobalData } from '../../contexts/globalDataContext';
|
|
14
14
|
import XPathUtils from '../../utils/xpath';
|
|
15
|
-
import React, { useContext } from 'react';
|
|
15
|
+
import React, { useCallback, useContext, useState } from 'react';
|
|
16
16
|
import { Result } from '../interface/result';
|
|
17
17
|
import StatusMessage from '../interface/statusMessage';
|
|
18
18
|
import { Queries } from '../webservice';
|
|
@@ -21,13 +21,14 @@ var CCF = function () {
|
|
|
21
21
|
var ctx = useContext(Queries.CCF);
|
|
22
22
|
var Section = ctx.Section;
|
|
23
23
|
var setData = useGlobalData().setData;
|
|
24
|
-
var
|
|
24
|
+
var _a = useState(false), dataUpdated = _a[0], setDataUpdated = _a[1];
|
|
25
|
+
var mapNodeToCCFData = useCallback(function (node) { return ({
|
|
25
26
|
banco: XPathUtils.select('string(./banco)', node),
|
|
26
27
|
agencia: XPathUtils.select('string(./agencia)', node),
|
|
27
28
|
quantidadeDeOcorrencias: parseInt(XPathUtils.select('string(./qteOcorrencias)', node), 10),
|
|
28
29
|
ultimaOcorrencia: XPathUtils.select('string(./ultimo)', node),
|
|
29
30
|
motivo: XPathUtils.select('string(./motivo)', node)
|
|
30
|
-
}); };
|
|
31
|
+
}); }, []);
|
|
31
32
|
return (React.createElement(Section, { ctx: ctx, title: "Cheques sem Fundos em Institui\u00E7\u00E3o Banc\u00E1ria", subtitle: "Detalhes acerca de cheques sem fundos emitidos.", icon: ChequesSemFundoIcon, onSuccess: function (data) {
|
|
32
33
|
var allItems = XPathUtils.selectArray('//list/*', data);
|
|
33
34
|
var filteredItems = allItems.filter(function (node) {
|
|
@@ -36,7 +37,14 @@ var CCF = function () {
|
|
|
36
37
|
var ccfData = filteredItems.map(mapNodeToCCFData);
|
|
37
38
|
var totalOcorrencias = XPathUtils.select('number(//sumQteOcorrencias)', data);
|
|
38
39
|
var ultimoRegistro = XPathUtils.select('string(//ultimo)', data);
|
|
39
|
-
|
|
40
|
+
if (!dataUpdated &&
|
|
41
|
+
(totalOcorrencias !== 0 ||
|
|
42
|
+
ultimoRegistro.length > 0 ||
|
|
43
|
+
ccfData.length > 0)) {
|
|
44
|
+
var ccfState_1 = { ccfData: ccfData };
|
|
45
|
+
setData(function (prevState) { return (__assign(__assign({}, prevState), { ccfData: ccfState_1, ccf: totalOcorrencias || 0, ultimoRegistroCCF: ultimoRegistro || '' })); });
|
|
46
|
+
setDataUpdated(true);
|
|
47
|
+
}
|
|
40
48
|
var children = (ccfData === null || ccfData === void 0 ? void 0 : ccfData.length) ? (React.createElement(Result, null, ccfData.map(function (ccf, key) { return (React.createElement(CCFList, { key: key, data: [ccf] })); }))) : null;
|
|
41
49
|
return {
|
|
42
50
|
children: children,
|
|
@@ -1,11 +1,5 @@
|
|
|
1
|
+
import { CCFData } from '../../@types/domain';
|
|
1
2
|
import React from 'react';
|
|
2
|
-
export type CCFData = {
|
|
3
|
-
banco: string;
|
|
4
|
-
agencia: string;
|
|
5
|
-
quantidadeDeOcorrencias: number;
|
|
6
|
-
ultimaOcorrencia: string;
|
|
7
|
-
motivo: string;
|
|
8
|
-
};
|
|
9
3
|
declare const CCFList: React.FC<{
|
|
10
4
|
data: CCFData[];
|
|
11
5
|
}>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import React, { memo } from 'react';
|
|
2
|
-
import { ResultContent } from '../interface/result';
|
|
3
|
-
import AddCffField from '../common/addItem';
|
|
4
1
|
import { formatDistance } from 'date-fns';
|
|
5
2
|
import { ptBR } from 'date-fns/locale';
|
|
3
|
+
import React, { memo } from 'react';
|
|
4
|
+
import AddCffField from '../common/addItem';
|
|
5
|
+
import { ResultContent } from '../interface/result';
|
|
6
6
|
var CCFItem = memo(function (_a) {
|
|
7
7
|
var ccf = _a.ccf;
|
|
8
8
|
var startDate = new Date(ccf.ultimaOcorrencia.split('/').reverse().join('-'));
|
|
@@ -24,11 +24,11 @@ import ConsultaSimplesIcon from '../../assets/icones/consultaSimples';
|
|
|
24
24
|
import { useGlobalData } from '../../contexts/globalDataContext';
|
|
25
25
|
import { formatMoney } from '../../utils/number';
|
|
26
26
|
import { formatDocument } from '../../utils/string';
|
|
27
|
+
import { format } from 'date-fns';
|
|
27
28
|
import React, { useContext } from 'react';
|
|
28
29
|
import Section from '../interface/section';
|
|
29
30
|
import StatusMessage from '../interface/statusMessage';
|
|
30
31
|
import { Queries, RequestStatus } from '../webservice';
|
|
31
|
-
import { formatDate } from 'date-fns';
|
|
32
32
|
var getPossuiPendenciaText = function (_a) {
|
|
33
33
|
var ccf = _a.ccf, ultimoRegistroCCF = _a.ultimoRegistroCCF, dividasPublicas = _a.dividasPublicas, protestos = _a.protestos, processosJuridicos = _a.processosJuridicos;
|
|
34
34
|
return [
|
|
@@ -67,7 +67,7 @@ var ConsultaSimplesSection = function (_a) {
|
|
|
67
67
|
? 'error'
|
|
68
68
|
: 'success';
|
|
69
69
|
return (React.createElement(Section, __assign({ title: "Consulta Simples", subtitle: "Consulta de informa\u00E7\u00F5es do documento.", description: React.createElement(React.Fragment, null,
|
|
70
|
-
React.createElement(StatusMessage, null,
|
|
70
|
+
React.createElement(StatusMessage, null, format(new Date(), "dd/MM/yyyy 'às' HH:mm")),
|
|
71
71
|
React.createElement(StatusMessage, { type: "found" }, formatDocument(documento)),
|
|
72
72
|
isError && (React.createElement(StatusMessage, { type: statusType }, ctx === null || ctx === void 0 ? void 0 : ctx.error.message)),
|
|
73
73
|
possuiPendenciaText.length ? (possuiPendenciaText.map(function (text) { return (React.createElement(StatusMessage, { key: text, type: "error" }, text)); })) : (React.createElement(StatusMessage, { type: statusType }, "Nenhum registro encontrado"))), onClose: onClose, icon: ConsultaSimplesIcon, variant: isLoading ? 'loading' : 'default' }, rest), children));
|
|
@@ -1,9 +1,6 @@
|
|
|
1
|
+
import { ImoveisConsultaResponse, PefinRefinSerasaResponse, RefinBoaVistaResponse, ScoreResponse } from '../@types/domain';
|
|
1
2
|
import React, { PropsWithChildren } from 'react';
|
|
2
3
|
import { ParsedResponse } from './webservice';
|
|
3
|
-
import { RefinBoaVistaResponse } from './refinBoaVista/types';
|
|
4
|
-
import { PefinRefinSerasaResponse } from './refinSerasa/types';
|
|
5
|
-
import { ImoveisConsultaResponse } from './imoveis/types';
|
|
6
|
-
import { ScoreResponse } from './score/types';
|
|
7
4
|
type QueryType<DataType = any> = {
|
|
8
5
|
consultaRealizada: boolean;
|
|
9
6
|
data?: ParsedResponse<DataType> | null;
|
|
@@ -14,10 +14,10 @@ var __assign = (this && this.__assign) || function () {
|
|
|
14
14
|
return __assign.apply(this, arguments);
|
|
15
15
|
};
|
|
16
16
|
import React, { memo, useEffect, useState } from 'react';
|
|
17
|
+
import styled from 'styled-components';
|
|
17
18
|
import AddItemField from '../common/addItem';
|
|
18
|
-
import ContactsLikeDislike from './contactsLikeDislike';
|
|
19
19
|
import { useMutation, useQuery } from '../webservice';
|
|
20
|
-
import
|
|
20
|
+
import ContactsLikeDislike from './contactsLikeDislike';
|
|
21
21
|
var ContactsLikeDislikeWrapper = styled.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n margin-top: 15px;\n"], ["\n margin-top: 15px;\n"])));
|
|
22
22
|
var ContactLikeDislikeSection = function (props) {
|
|
23
23
|
var _a, _b, _c;
|
|
@@ -60,9 +60,10 @@ var ContactLikeDislikeSection = function (props) {
|
|
|
60
60
|
return (React.createElement(ContactField, __assign({}, props, { likes: likesDislikes === null || likesDislikes === void 0 ? void 0 : likesDislikes.likes, dislikes: likesDislikes === null || likesDislikes === void 0 ? void 0 : likesDislikes.dislikes, onClickLike: function () { return handleLikeDislike(mutateLike, 'likes'); }, onClickDislike: function () { return handleLikeDislike(mutateDislike, 'dislikes'); } })));
|
|
61
61
|
};
|
|
62
62
|
var ContactField = memo(function (contact) {
|
|
63
|
+
var _a, _b;
|
|
63
64
|
return (React.createElement(AddItemField, { name: contact.type, value: contact.value },
|
|
64
65
|
React.createElement(ContactsLikeDislikeWrapper, null,
|
|
65
|
-
React.createElement(ContactsLikeDislike, { likes: contact === null || contact === void 0 ? void 0 : contact.likes, dislikes: contact === null || contact === void 0 ? void 0 : contact.dislikes, onClickLike: contact.onClickLike, onClickDislike: contact.onClickDislike }))));
|
|
66
|
+
React.createElement(ContactsLikeDislike, { likes: contact === null || contact === void 0 ? void 0 : contact.likes, dislikes: contact === null || contact === void 0 ? void 0 : contact.dislikes, onClickLike: (_a = contact.onClickLike) !== null && _a !== void 0 ? _a : (function () { }), onClickDislike: (_b = contact.onClickDislike) !== null && _b !== void 0 ? _b : (function () { }) }))));
|
|
66
67
|
});
|
|
67
68
|
export default ContactLikeDislikeSection;
|
|
68
69
|
var templateObject_1;
|