Skip to content

Commit

Permalink
New bridge app + explorer
Browse files Browse the repository at this point in the history
  • Loading branch information
zeekay committed Dec 30, 2023
0 parents commit ae12a44
Show file tree
Hide file tree
Showing 437 changed files with 73,865 additions and 0 deletions.
15 changes: 15 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"extends": [
"next/core-web-vitals",
"plugin:storybook/recommended"
],
"plugins": [
"no-conditional-literals-in-jsx"
],
"rules": {
"no-conditional-literals-in-jsx/no-conditional-literals-in-jsx": "error",
"no-conditional-literals-in-jsx/no-unwrapped-jsx-text": "error",
"react-hooks/exhaustive-deps": "off",
"react/display-name": "off"
}
}
26 changes: 26 additions & 0 deletions .github/workflows/chromatic.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# .github/workflows/chromatic.yml

# Workflow name
name: 'Chromatic'

# Event for the workflow
on: push

# List of jobs
jobs:
chromatic-deployment:
# Operating System
runs-on: ubuntu-latest
# Job steps
steps:
- uses: actions/checkout@v1
- name: Install dependencies
# 👇 Install dependencies with the same package manager used in the project (replace it as needed), e.g. yarn, npm, pnpm
run: yarn
# 👇 Adds Chromatic as a step in the workflow
- name: Publish to Chromatic
uses: chromaui/action@v1
# Chromatic GitHub Action options
with:
# 👇 Chromatic projectToken, refer to the manage page to obtain it.
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
39 changes: 39 additions & 0 deletions .github/workflows/rebase-dev-prod-stage.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Dev to dev-prod && dev-stage
on:
push:
branches: [dev]
permissions:
contents: write
jobs:
rebase-dev-prod:
timeout-minutes: 2
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set Git config
run: |
git config --local user.email "[email protected]"
git config --local user.name "Github Actions"
- name: Merge dev to dev-prod
run: |
git fetch --unshallow
git checkout dev-prod
git rebase dev
git push
rebase-dev-stage:
timeout-minutes: 2
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set Git config
run: |
git config --local user.email "[email protected]"
git config --local user.name "Github Actions"
- name: Merge dev to dev-stage
run: |
git fetch --unshallow
git checkout dev-stage
git rebase dev
git push
22 changes: 22 additions & 0 deletions .github/workflows/rebase-main-sandbox.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Main to main-sandbox
on:
push:
branches: [main]
permissions:
contents: write
jobs:
rebase-main-sandbox:
timeout-minutes: 2
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set Git config
run: |
git config --local user.email "[email protected]"
git config --local user.name "Github Actions"
- name: Merge main to main-sandbox
run: |
git fetch --unshallow
git checkout main-sandbox
git rebase main
git push
38 changes: 38 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
*node_modules
/.pnp
.pnp.js

# testing
/coverage

# next.js
/.next/
/out/

# production
/build

# misc
.DS_Store

# debug
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# local env files
.env
.env.local
.env.development.local
.env.test.local
.env.production.local
.vercel

# Moving to yarn
package-lock.json
storybook-static/*
# Sentry Config File
.sentryclirc
32 changes: 32 additions & 0 deletions .storybook/main.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
import type { StorybookConfig } from "@storybook/nextjs";

const config: StorybookConfig = {
stories: [
"../stories/**/*.mdx",
"../stories/**/*.stories.@(js|jsx|mjs|ts|tsx)",
],
addons: [
"@storybook/addon-links",
"@storybook/addon-essentials",
"@storybook/addon-onboarding",
"@storybook/addon-interactions",
"@storybook/addon-mdx-gfm",
"storybook-addon-mock"
],
framework: {
name: "@storybook/nextjs",
options: {},
},
docs: {
autodocs: "tag",
},
webpackFinal: async (config) => {
config.module?.rules?.push({
test: /\.scss$/,
use: ["style-loader", "css-loader", "postcss-loader", "sass-loader"],
});

return config;
},
};
export default config;
32 changes: 32 additions & 0 deletions .storybook/main.ts.sedbak
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
import type { StorybookConfig } from "@storybook/nextjs";

const config: StorybookConfig = {
stories: [
"../stories/**/*.mdx",
"../stories/**/*.stories.@(js|jsx|mjs|ts|tsx)",
],
addons: [
"@storybook/addon-links",
"@storybook/addon-essentials",
"@storybook/addon-onboarding",
"@storybook/addon-interactions",
"@storybook/addon-mdx-gfm",
"storybook-addon-mock"
],
framework: {
name: "@storybook/nextjs",
options: {},
},
docs: {
autodocs: "tag",
},
webpackFinal: async (config) => {
config.module?.rules?.push({
test: /\.scss$/,
use: ["style-loader", "css-loader", "postcss-loader", "sass-loader"],
});

return config;
},
};
export default config;
25 changes: 25 additions & 0 deletions .storybook/preview.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
import type { Preview } from "@storybook/react";
import "../styles/globals.css";

export const parameters = {
actions: { argTypesRegex: "^on[A-Z].*" },
};

const preview: Preview = {
loaders: [
async () => ({
settings: await (await fetch(`https://bridge-api.bridge.lux.network/api/settings?version=sandbox`)).json(),
}),
],
parameters: {
actions: { argTypesRegex: "^on[A-Z].*" },
controls: {
matchers: {
color: /(background|color)$/i,
date: /Date$/,
},
},
},
};

export default preview;
25 changes: 25 additions & 0 deletions .storybook/preview.ts.sedbak
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
import type { Preview } from "@storybook/react";
import "../styles/globals.css";

export const parameters = {
actions: { argTypesRegex: "^on[A-Z].*" },
};

const preview: Preview = {
loaders: [
async () => ({
settings: await (await fetch(`https://bridge-api.bridge.lux.network/api/settings?version=sandbox`)).json(),
}),
],
parameters: {
actions: { argTypesRegex: "^on[A-Z].*" },
controls: {
matchers: {
color: /(background|color)$/i,
date: /Date$/,
},
},
},
};

export default preview;
39 changes: 39 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "Next.js: debug server-side",
"type": "node-terminal",
"request": "launch",
"command": "npm run debug"
},
{
"name": "Next.js: debug client-side",
"type": "chrome",
"request": "launch",
"url": "http://localhost:3000"
},
{
"name": "Next.js: debug full stack",
"type": "node-terminal",
"request": "launch",
"command": "npm run debug",
"serverReadyAction": {
"pattern": "started server on .+, url: (https?://.+)",
"uriFormat": "%s",
"action": "debugWithChrome"
}
}
],
"tasks": [
{
"type": "npm",
"script": "errors",
"problemMatcher": "$tsc-watch",
"isBackground": true,
"presentation": {
"revealProblems": "never"
}
}
]
}
39 changes: 39 additions & 0 deletions .vscode/launch.json.sedbak
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "Next.js: debug server-side",
"type": "node-terminal",
"request": "launch",
"command": "npm run debug"
},
{
"name": "Next.js: debug client-side",
"type": "chrome",
"request": "launch",
"url": "http://localhost:3000"
},
{
"name": "Next.js: debug full stack",
"type": "node-terminal",
"request": "launch",
"command": "npm run debug",
"serverReadyAction": {
"pattern": "started server on .+, url: (https?://.+)",
"uriFormat": "%s",
"action": "debugWithChrome"
}
}
],
"tasks": [
{
"type": "npm",
"script": "errors",
"problemMatcher": "$tsc-watch",
"isBackground": true,
"presentation": {
"revealProblems": "never"
}
}
]
}
39 changes: 39 additions & 0 deletions .vscode/launch.json.sedbak.sedbak
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "Next.js: debug server-side",
"type": "node-terminal",
"request": "launch",
"command": "npm run debug"
},
{
"name": "Next.js: debug client-side",
"type": "chrome",
"request": "launch",
"url": "http://localhost:3000"
},
{
"name": "Next.js: debug full stack",
"type": "node-terminal",
"request": "launch",
"command": "npm run debug",
"serverReadyAction": {
"pattern": "started server on .+, url: (https?://.+)",
"uriFormat": "%s",
"action": "debugWithChrome"
}
}
],
"tasks": [
{
"type": "npm",
"script": "errors",
"problemMatcher": "$tsc-watch",
"isBackground": true,
"presentation": {
"revealProblems": "never"
}
}
]
}
Loading

0 comments on commit ae12a44

Please sign in to comment.