thunderhub/src/client/next.config.js
AmbossKeegan 0f893bddad
Echarts implementation (#536)
* feat: implement the payments graph with echarts

* fix: improve echarts import in next.config.js

* fix: formatting

* fix: no-implicity-any

* fix: tidy up inconsistencies in echarts implementation

* feat: improve a number of aspects about echarts implementation as per suggestions

* feat: move forwards chart to echarts

* chore: move invoice, payment, forward graphs to new BarChart. move liquidityGraph to new HorizontalBarChart

* chore: remove V2 from new graphs

* feat: implement Sankey chart for forwards

* chore: change justification on Sankey Graph

* feat: add Sankey graph

* chore: remove chord graph

* chore: remove chord graph and update package.json

* chore: remove stray console log

* chore: format numbers on y axis to be integer values

* feat: tidy echarts implementation

* feat: revamp tooltip

* feat: bound the size of the sankey chart

* feat: provide function that creates a mock sankey dataset of arbitrary size

* fix: missing memo dependencies and css

* chore: small changes

---------

Co-authored-by: Anthony Potdevin <potdevin.anthony@gmail.com>
Co-authored-by: Anthony Potdevin <31413433+apotdevin@users.noreply.github.com>
Co-authored-by: secondl1ght <secondl1ght@protonmail.com>
2023-08-18 18:15:29 +02:00

32 lines
1.3 KiB
JavaScript

// eslint-disable-next-line @typescript-eslint/no-var-requires
const path = require('path');
// eslint-disable-next-line @typescript-eslint/no-var-requires
const dotenv = require('dotenv');
dotenv.config({ path: path.resolve(process.cwd(), '.env.local') });
dotenv.config({ path: path.resolve(process.cwd(), '.env') });
module.exports = {
reactStrictMode: true,
poweredByHeader: false,
basePath: process.env.BASE_PATH || '',
transpilePackages: ['echarts', 'zrender'],
compiler: {
styledComponents: true,
},
publicRuntimeConfig: {
mempoolUrl: process.env.MEMPOOL_URL || 'https://mempool.space',
disable2FA: process.env.DISABLE_TWOFA === 'true',
apiUrl: `${process.env.BASE_PATH || ''}/graphql`,
basePath: process.env.BASE_PATH || '',
npmVersion: process.env.npm_package_version || '0.0.0',
defaultTheme: process.env.THEME || 'dark',
defaultCurrency: process.env.CURRENCY || 'sat',
fetchPrices: process.env.FETCH_PRICES === 'false' ? false : true,
fetchFees: process.env.FETCH_FEES === 'false' ? false : true,
disableLinks: process.env.DISABLE_LINKS === 'true',
disableLnMarkets: process.env.DISABLE_LNMARKETS === 'true',
noVersionCheck: process.env.NO_VERSION_CHECK === 'true',
logoutUrl: process.env.LOGOUT_URL || '',
},
};