chore: bump deps

This commit is contained in:
apotdevin 2021-09-03 14:40:47 +02:00
parent f7cb1a1b76
commit 464b0595bd
No known key found for this signature in database
GPG key ID: 4403F1DFBE779457
18 changed files with 2724 additions and 27525 deletions

30126
package-lock.json generated

File diff suppressed because it is too large Load diff

View file

@ -36,7 +36,7 @@
"author": "",
"license": "MIT",
"dependencies": {
"@apollo/client": "^3.4.9",
"@apollo/client": "^3.4.10",
"@emotion/babel-plugin": "^11.3.0",
"@visx/axis": "^2.1.0",
"@visx/chord": "^2.1.0",
@ -48,7 +48,7 @@
"@visx/shape": "^2.1.0",
"@visx/tooltip": "^2.1.0",
"apollo-server-micro": "^2.25.2",
"balanceofsatoshis": "^10.9.2",
"balanceofsatoshis": "^10.10.2",
"bcryptjs": "^2.4.3",
"bech32": "^2.0.0",
"bip32": "^2.0.6",
@ -60,16 +60,16 @@
"d3-array": "^2.12.1",
"d3-time-format": "^3.0.0",
"date-fns": "^2.23.0",
"graphql": "^15.5.1",
"graphql": "^15.5.2",
"graphql-iso-date": "^3.6.1",
"graphql-middleware": "^6.1.4",
"graphql-middleware": "^6.1.5",
"graphql-rate-limit": "^3.1.0",
"js-cookie": "^3.0.0",
"js-cookie": "^3.0.1",
"js-yaml": "^4.1.0",
"jsonwebtoken": "^8.5.1",
"ln-service": "^52.0.2",
"ln-service": "^52.1.0",
"lodash": "^4.17.21",
"next": "^11.1.0",
"next": "^11.1.2",
"node-fetch": "^2.6.1",
"numeral": "^2.0.6",
"qrcode.react": "^1.0.1",
@ -78,14 +78,14 @@
"react-copy-to-clipboard": "^5.0.4",
"react-dom": "^17.0.2",
"react-feather": "^2.0.9",
"react-grid-layout": "^1.2.5",
"react-grid-layout": "^1.3.0",
"react-qr-reader": "^2.2.1",
"react-select": "^4.3.1",
"react-slider": "^1.3.1",
"react-spinners": "^0.11.0",
"react-spring": "^9.2.4",
"react-table": "^7.7.0",
"react-toastify": "^8.0.0",
"react-toastify": "^8.0.2",
"react-tooltip": "^4.2.21",
"secp256k1": "^4.0.2",
"socks-proxy-agent": "^6.0.0",
@ -96,7 +96,7 @@
"winston": "^3.3.3"
},
"devDependencies": {
"@babel/core": "^7.15.0",
"@babel/core": "^7.15.4",
"@commitlint/cli": "^13.1.0",
"@commitlint/config-conventional": "^13.1.0",
"@graphql-codegen/add": "^3.1.0",
@ -119,7 +119,7 @@
"@types/js-cookie": "^2.2.7",
"@types/js-yaml": "^4.0.3",
"@types/jsonwebtoken": "^8.5.5",
"@types/node": "^16.7.2",
"@types/node": "^16.7.10",
"@types/node-fetch": "^2.5.12",
"@types/numeral": "^2.0.1",
"@types/qrcode.react": "^1.0.2",
@ -135,26 +135,26 @@
"@types/styled-react-modal": "^1.2.1",
"@types/styled-theming": "^2.2.5",
"@types/uuid": "^8.3.1",
"@typescript-eslint/eslint-plugin": "^4.29.3",
"@typescript-eslint/parser": "^4.29.3",
"@typescript-eslint/eslint-plugin": "^4.30.0",
"@typescript-eslint/parser": "^4.30.0",
"apollo-server": "^2.25.2",
"apollo-server-testing": "^2.25.2",
"babel-jest": "^27.0.6",
"babel-jest": "^27.1.0",
"babel-loader": "^8.2.2",
"babel-plugin-inline-react-svg": "^2.0.1",
"babel-plugin-styled-components": "^1.13.2",
"babel-preset-react-app": "^10.0.0",
"eslint": "^7.32.0",
"eslint-config-next": "^11.1.0",
"eslint-config-next": "^11.1.2",
"eslint-config-prettier": "^8.3.0",
"eslint-plugin-import": "^2.24.2",
"eslint-plugin-jest": "^24.4.0",
"eslint-plugin-jsx-a11y": "^6.4.1",
"eslint-plugin-prettier": "^3.4.1",
"eslint-plugin-react": "^7.24.0",
"eslint-plugin-prettier": "^4.0.0",
"eslint-plugin-react": "^7.25.1",
"eslint-plugin-react-hooks": "^4.2.0",
"husky": "^7.0.2",
"jest": "^27.0.6",
"jest": "^27.1.0",
"jest-fetch-mock": "^3.0.3",
"lint-staged": "^11.1.2",
"prettier": "^2.3.2",

View file

@ -16,6 +16,7 @@ export default class MyDocument extends Document {
try {
ctx.renderPage = () =>
originalRenderPage({
// eslint-disable-next-line react/display-name
enhanceApp: App => props => sheet.collectStyles(<App {...props} />),
});

12
pages/_error.tsx Normal file
View file

@ -0,0 +1,12 @@
import Error from 'next/error';
function Page({ statusCode }: any) {
return <Error statusCode={statusCode}></Error>;
}
Page.getInitialProps = ({ res, err }: any) => {
const statusCode = res ? res.statusCode : err ? err.statusCode : 404;
return { statusCode };
};
export default Page;

View file

@ -6,7 +6,7 @@ export const BoltzApi = {
getPairs: async () => {
try {
const response = await fetchWithProxy(`${appUrls.boltz}/getpairs`);
return await response.json();
return (await response.json()) as any;
} catch (error: any) {
logger.error('Error getting pairs from Boltz: %o', error);
throw new Error('ErrorGettingBoltzPairs');
@ -17,7 +17,7 @@ export const BoltzApi = {
const response = await fetchWithProxy(
`${appUrls.boltz}/getfeeestimation`
);
return await response.json();
return (await response.json()) as any;
} catch (error: any) {
logger.error('Error getting fee estimations from Boltz: %o', error);
throw new Error(error);
@ -31,7 +31,7 @@ export const BoltzApi = {
body: JSON.stringify(body),
headers: { 'Content-Type': 'application/json' },
});
return await response.json();
return (await response.json()) as any;
} catch (error: any) {
logger.error('Error getting fee estimations from Boltz: %o', error);
throw new Error(error);
@ -56,7 +56,7 @@ export const BoltzApi = {
body: JSON.stringify(body),
headers: { 'Content-Type': 'application/json' },
});
return await response.json();
return (await response.json()) as any;
} catch (error: any) {
logger.error('Error getting fee estimations from Boltz: %o', error);
throw new Error(error);
@ -76,7 +76,7 @@ export const BoltzApi = {
headers: { 'Content-Type': 'application/json' },
}
);
return await response.json();
return (await response.json()) as any;
} catch (error: any) {
logger.error('Error broadcasting transaction from Boltz: %o', error);
throw new Error(error);

View file

@ -11,7 +11,7 @@ export const LnMarketsApi = {
Authorization: `Bearer ${token}`,
},
});
return await response.json();
return (await response.json()) as any;
} catch (error: any) {
logger.error(
`Error getting user info from ${appUrls.lnMarkets}/user. Error: %o`,
@ -34,7 +34,7 @@ export const LnMarketsApi = {
body: JSON.stringify({ amount, unit: 'sat' }),
}
);
return await response.json();
return (await response.json()) as any;
} catch (error: any) {
logger.error(
`Error getting invoice to deposit from LnMarkets. Error: %o`,
@ -57,7 +57,7 @@ export const LnMarketsApi = {
body: JSON.stringify({ amount, unit: 'sat', invoice }),
}
);
return await response.json();
return (await response.json()) as any;
} catch (error: any) {
logger.error(`Error withdrawing from LnMarkets. Error: %o`, error);
throw new Error('ProblemWithdrawingFromLnMarkets');

View file

@ -112,7 +112,7 @@ export const getLnMarketsAuth = async (
const response = await fetchWithProxy(`${appUrls.lnMarkets}/lnurl/auth`, {
method: 'post',
});
const json = await response.json();
const json = (await response.json()) as any;
logger.debug('Get lnUrl from LnMarkets response: %o', json);
lnUrl = json?.lnurl;
@ -132,7 +132,7 @@ export const getLnMarketsAuth = async (
// Try to authenticate with lnMarkets
try {
const response = await fetchWithProxy(`${finalUrl}&jwt=true&expiry=3600`);
const json = await response.json();
const json = (await response.json()) as any;
logger.debug('LnUrlAuth response: %o', json);

View file

@ -32,7 +32,7 @@ export const bitcoinResolvers = {
try {
const response = await fetchWithProxy(appUrls.fees);
const json = await response.json();
const json = (await response.json()) as any;
if (json) {
const { fastestFee, halfHourFee, hourFee, minimumFee } = json;

View file

@ -84,7 +84,7 @@ export const lnUrlResolvers = {
try {
const response = await fetchWithProxy(finalUrl);
const json = await response.json();
const json = (await response.json()) as any;
logger.debug('LnUrlAuth response: %o', json);
@ -107,7 +107,7 @@ export const lnUrlResolvers = {
try {
const response = await fetchWithProxy(url);
const json = await response.json();
const json = (await response.json()) as any;
if (json.status === 'ERROR') {
throw new Error(json.reason || 'LnServiceError');
@ -149,7 +149,7 @@ export const lnUrlResolvers = {
try {
const response = await fetchWithProxy(finalUrl);
lnServiceResponse = await response.json();
lnServiceResponse = (await response.json()) as any;
if (lnServiceResponse.status === 'ERROR') {
throw new Error(lnServiceResponse.reason || 'LnServiceError');
@ -231,7 +231,7 @@ export const lnUrlResolvers = {
try {
const response = await fetchWithProxy(finalUrl);
const json = await response.json();
const json = (await response.json()) as any;
logger.debug('LnUrlWithdraw response: %o', json);
@ -273,7 +273,7 @@ export const lnUrlResolvers = {
try {
const response = await fetchWithProxy(finalUrl);
const json = await response.json();
const json = (await response.json()) as any;
logger.debug('LnUrlChannel response: %o', json);

View file

@ -32,7 +32,7 @@ export const graphqlFetchWithProxy = async (
headers: { Accept: 'application/json' },
body: JSON.stringify({ query, variables }),
})
.then(res => res.json())
.then(res => res.json() as any)
.then(data => data)
.catch(error => {
logger.error('Error doing graphql fetch: %o', error);

View file

@ -48,8 +48,8 @@ const options = [
];
const typeOptions = [
{ label: 'Amount', value: 'amount' },
{ label: 'Tokens', value: 'tokens' },
{ label: 'Count', value: 'amount' },
{ label: 'Amount', value: 'tokens' },
{ label: 'Fees', value: 'fee' },
];

View file

@ -51,8 +51,8 @@ const options = [
];
const typeOptions = [
{ label: 'Amount', value: 'amount' },
{ label: 'Tokens', value: 'tokens' },
{ label: 'Count', value: 'amount' },
{ label: 'Amount', value: 'tokens' },
];
export const InvoicesGraph = () => {

View file

@ -48,8 +48,8 @@ const options = [
];
const typeOptions = [
{ label: 'Amount', value: 'amount' },
{ label: 'Tokens', value: 'tokens' },
{ label: 'Count', value: 'amount' },
{ label: 'Amount', value: 'tokens' },
];
export const PaymentsGraph = () => {

View file

@ -48,8 +48,8 @@ const options = [
];
const typeOptions = [
{ label: 'Amount', value: 'amount' },
{ label: 'Tokens', value: 'tokens' },
{ label: 'Count', value: 'amount' },
{ label: 'Amount', value: 'tokens' },
];
export const TransactionsGraph = () => {

View file

@ -47,8 +47,8 @@ const options = [
];
const typeOptions = [
{ label: 'Amount', value: 'amount' },
{ label: 'Tokens', value: 'tokens' },
{ label: 'Count', value: 'amount' },
{ label: 'Amount', value: 'tokens' },
];
export const FlowBox = () => {
@ -142,7 +142,7 @@ export const FlowBox = () => {
<Card>
{renderLine(
'Invoices',
type.value === 'amount' ? (
type.value === 'tokens' ? (
<Price amount={reduced.invoiceAmount} />
) : (
reduced.invoices
@ -150,7 +150,7 @@ export const FlowBox = () => {
)}
{renderLine(
'Payments',
type.value === 'amount' ? (
type.value === 'tokens' ? (
<Price amount={reduced.paymentAmount} />
) : (
reduced.payments

View file

@ -35,7 +35,7 @@ export const RouteTable: FC<RouteTableProps> = ({ order, forwardArray }) => {
case 'fee':
return 'Fee (sats)';
case 'tokens':
return 'Tokens (sats)';
return 'Amount (sats)';
default:
return 'Count';
}
@ -76,7 +76,7 @@ export const ChannelTable: FC<ChannelTableProps> = ({
case 'fee':
return 'Fee (sats)';
case 'tokens':
return 'Tokens (sats)';
return 'Amount (sats)';
default:
return 'Count';
}

View file

@ -41,8 +41,8 @@ export const options = [
];
export const typeOptions = [
{ label: 'Amount', value: 'amount' },
{ label: 'Tokens', value: 'tokens' },
{ label: 'Count', value: 'amount' },
{ label: 'Amount', value: 'tokens' },
{ label: 'Fees', value: 'fee' },
];

View file

@ -94,8 +94,8 @@ export const PeersCard = ({
return (
<>
<Separation />
{renderLine('Tokens Received:', formatReceived)}
{renderLine('Tokens Sent:', formatSent)}
{renderLine('Amount Received:', formatReceived)}
{renderLine('Amount Sent:', formatSent)}
{renderLine('bytes Received:', bytes_received)}
{renderLine('bytes Sent:', bytes_sent)}
{renderLine('Public Key:', getNodeLink(public_key))}
@ -162,8 +162,8 @@ export const PeersCard = ({
effect={'solid'}
place={'bottom'}
>
{renderLine('Tokens Received', formatReceived)}
{renderLine('Tokens Sent', formatSent)}
{renderLine('Amount Received', formatReceived)}
{renderLine('Amount Sent', formatSent)}
</ReactTooltip>
<Modal isOpen={modalOpen} closeCallback={() => setModalOpen(false)}>
<RemovePeerModal