Go to file
tjs 10cf640f11 update prettier pkgs, config, and reformat 2023-08-17 19:47:11 -04:00
.github/workflows chore: prettier 2023-01-26 15:30:54 +00:00
.husky reorder husky precommit 2023-02-13 22:35:07 -05:00
apis Merge pull request #174 from blockworks-foundation/stop-orders 2023-08-18 08:08:21 +10:00
components update prettier pkgs, config, and reformat 2023-08-17 19:47:11 -04:00
fonts add custom theme font support 2023-06-08 20:41:23 +10:00
hooks show details of used accounts in settings and hook for data 2023-08-15 13:06:00 +10:00
pages update prettier pkgs, config, and reformat 2023-08-17 19:47:11 -04:00
public Merge pull request #174 from blockworks-foundation/stop-orders 2023-08-18 08:08:21 +10:00
store remove saving chart settings and fix latest price chart flicker 2023-08-17 12:58:35 +10:00
styles set bg color in trading view widget 2023-08-17 16:36:25 -04:00
types remove saving chart settings and fix latest price chart flicker 2023-08-17 12:58:35 +10:00
utils update prettier pkgs, config, and reformat 2023-08-17 19:47:11 -04:00
vendor update trading_view; add tradingview files to gitignore 2022-12-06 11:06:15 -05:00
.eslintignore mango v4 sandbox 2022-05-04 00:25:54 -04:00
.eslintrc.json add next and tailwind eslint plugins 2023-08-17 17:16:23 -04:00
.gitignore add glitchtip 2023-07-11 17:25:06 -04:00
.prettierignore add network concurrency for vercel builds 2023-01-28 14:41:13 -05:00
.yarnrc auto pin deps going forward 2023-01-26 12:32:11 +00:00
.yarnrc.yml deny scripts 2023-01-25 15:02:51 +00:00
LICENSE Initial commit 2022-04-08 12:35:55 -04:00
README.md update copy 2023-06-14 20:13:26 +10:00
next-env.d.ts Initial commit from Create Next App 2022-05-04 00:25:32 -04:00
next-i18next.config.js add russian translation files 2022-10-10 14:59:23 +11:00
next.config.js use latest prettier 2023-07-21 14:47:53 -04:00
package.json update prettier pkgs, config, and reformat 2023-08-17 19:47:11 -04:00
postcss.config.js mango v4 sandbox 2022-05-04 00:25:54 -04:00
prettier.config.js update prettier pkgs, config, and reformat 2023-08-17 19:47:11 -04:00
sentry.client.config.ts Disable sentry autoSessionTracking 2023-07-20 17:48:14 +01:00
sentry.edge.config.ts add glitchtip 2023-07-11 17:25:06 -04:00
sentry.server.config.ts add glitchtip 2023-07-11 17:25:06 -04:00
tailwind.config.js add the remaining theme elements 2023-08-10 13:31:47 +10:00
tsconfig.json use latest v4 npm pkg 2023-02-19 15:52:25 -05:00
yarn.lock update prettier pkgs, config, and reformat 2023-08-17 19:47:11 -04:00

README.md

This is a Next.js project bootstrapped with create-next-app.

Dependency Management

When updating dependencies, there are various files that must be kept up-to-date. Newly added, or updated dependencies can introduce unwanted/malicious scripts that can introduce risks for users and/or developers. The lavamoat allow-scripts feature allows us to deny by default, but adds some additional steps to the usual workflow.

yarn.lock:

  • Instead of running yarn or yarn install, run yarn setup to ensure the yarn.lock file is in sync and that dependency scripts are run according to the allowScripts policy (set in packages.json)
  • If lavamoat detects new scripts that are not explicitely allowed/denied, it'll throw and error with details (see below)
  • Running yarn setup will also dedupe the yarn.lock file to reduce the dependency tree. Note CI will fail if there are dupes in yarn.lock!

The allowScripts configuration in package.json:

  • There are two ways to configure script policies:
    1. Update the allow-scripts section manually by adding the missing package in the allowScripts section in package.json
    2. Run yarn allow-scripts auto to update the allowScripts configuration automatically
  • Review each new package to determine whether the install script needs to run or not, testing if necessary.
  • Use npx can-i-ignore-scripts to help assessing whether scripts are needed

Getting Started

First, run the development server:

npm run dev
# or
yarn dev

Open http://localhost:3000 with your browser to see the result.

You can start editing the page by modifying pages/index.tsx. The page auto-updates as you edit the file.

API routes can be accessed on http://localhost:3000/api/hello. This endpoint can be edited in pages/api/hello.ts.

The pages/api directory is mapped to /api/*. Files in this directory are treated as API routes instead of React pages.

Learn More

To learn more about Next.js, take a look at the following resources:

You can check out the Next.js GitHub repository - your feedback and contributions are welcome!

Deploy on Vercel

The easiest way to deploy your Next.js app is to use the Vercel Platform from the creators of Next.js.

Check out our Next.js deployment documentation for more details.

Creating Color Themes

  1. Copy one of the other color themes in tailwind.config.js (starting line 25)
  2. Modify the colors. For the variables bkg-* and fgd-* pick a base color for bkg-1 and fgd-1 then adjust the lightness for 2-4. Use this same process to create dark/hover variations for the colors that have these properties. The base color can be anything that works for your theme.
  3. Add your corresponding theme values here. The format needs to be converted to HEX, you can paste the HSL values into Coolors to do this.
  4. Copy one of the other themes in global.css and modify to match your theme name in tailwind.config.js
  5. Add a translation variable for your theme name in locales. Theme names are to be added to settings.json and make sure to add this to each locale (they can all be in English to start with). Make sure the value matches data-theme from your css vars in global.css
  6. Add your theme to the THEMES array in display settings. It should go after mango-classic then in alphabetical order. You need to use the translation key you added to the locales.