Skip to content

Commit 84c2d4c

Browse files
authored
feat: goerli (#30)
1 parent 5fa9c63 commit 84c2d4c

22 files changed

Lines changed: 1355 additions & 310 deletions

.github/workflows/create-deploy-production.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,19 @@ on:
55
tags:
66
- "*"
77

8+
concurrency:
9+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
10+
cancel-in-progress: true
11+
812
jobs:
913
build-deploy-production:
1014
runs-on: ubuntu-latest
1115
steps:
1216
- uses: actions/checkout@master
13-
- name: Use Node.js 14.x
17+
- name: Use Node.js 16.x
1418
uses: actions/setup-node@v1
1519
with:
16-
node-version: 14.x
20+
node-version: 16.x
1721
- name: yarn install & build
1822
run: |
1923
# https://github.com/yarnpkg/yarn/issues/2629

.github/workflows/create-deploy-staging.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,19 @@ name: "[Create] Deploy to staging"
22

33
on: [push]
44

5+
concurrency:
6+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
7+
cancel-in-progress: true
8+
59
jobs:
610
build:
711
runs-on: ubuntu-latest
812
steps:
913
- uses: actions/checkout@master
10-
- name: Use Node.js 14.x
14+
- name: Use Node.js 16.x
1115
uses: actions/setup-node@v1
1216
with:
13-
node-version: 14.x
17+
node-version: 16.x
1418
- name: yarn install & build
1519
run: |
1620
# https://github.com/yarnpkg/yarn/issues/2629

.github/workflows/pay-deploy-production.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,19 @@ on:
55
tags:
66
- "*"
77

8+
concurrency:
9+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
10+
cancel-in-progress: true
11+
812
jobs:
913
build-deploy-production:
1014
runs-on: ubuntu-latest
1115
steps:
1216
- uses: actions/checkout@master
13-
- name: Use Node.js 14.x
17+
- name: Use Node.js 16.x
1418
uses: actions/setup-node@v1
1519
with:
16-
node-version: 14.x
20+
node-version: 16.x
1721
- name: yarn install & build
1822
run: |
1923
# https://github.com/yarnpkg/yarn/issues/2629

.github/workflows/pay-deploy-staging.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,19 @@ name: "[Pay] Deploy to staging"
22

33
on: [push]
44

5+
concurrency:
6+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
7+
cancel-in-progress: true
8+
59
jobs:
610
build:
711
runs-on: ubuntu-latest
812
steps:
913
- uses: actions/checkout@master
10-
- name: Use Node.js 14.x
14+
- name: Use Node.js 16.x
1115
uses: actions/setup-node@v1
1216
with:
13-
node-version: 14.x
17+
node-version: 16.x
1418
- name: yarn install & build
1519
run: |
1620
# https://github.com/yarnpkg/yarn/issues/2629

packages/create/package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@
66
"@material-ui/core": "^4.9.7",
77
"@material-ui/icons": "^4.9.1",
88
"@material-ui/lab": "^4.0.0-alpha.46",
9+
"@requestnetwork/currency": "0.8.1-next.1787",
910
"@web3-react/core": "^6.0.7",
1011
"@web3-react/injected-connector": "^6.0.7",
11-
"@requestnetwork/currency": "^0.8.1-next.1581",
1212
"ethers": "5.5.1",
1313
"export-to-csv": "^0.2.1",
1414
"formik": "^2.1.4",
@@ -48,7 +48,7 @@
4848
]
4949
},
5050
"devDependencies": {
51-
"@requestnetwork/types": "^0.35.1-next.1581",
51+
"@requestnetwork/types": "0.35.1-next.1787",
5252
"@testing-library/jest-dom": "^5.15.1",
5353
"@testing-library/react": "^12.1.2",
5454
"@testing-library/user-event": "^13.5.0",
@@ -61,4 +61,4 @@
6161
"@types/testing-library__react": "^10.2.0",
6262
"@types/yup": "^0.26.3"
6363
}
64-
}
64+
}

packages/create/src/components/CreateRequest.tsx

Lines changed: 10 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,6 @@ import Dot from "./Dot";
3131
import { useWeb3React } from "@web3-react/core";
3232
import { ChangeChainLink } from "./ChangeChainLink";
3333

34-
export type PaymentChain = "mainnet" | "xdai" | "matic" | "rinkeby";
35-
3634
export interface IFormData {
3735
amount?: number;
3836
payer?: string;
@@ -53,7 +51,7 @@ export interface IProps {
5351
loading: boolean;
5452
}
5553

56-
const useHeaderStyles = makeStyles(theme => ({
54+
const useHeaderStyles = makeStyles((theme) => ({
5755
container: {
5856
height: 124,
5957
width: "100%",
@@ -135,7 +133,7 @@ const Header = ({
135133
);
136134
};
137135

138-
const useBodyStyles = makeStyles(theme => ({
136+
const useBodyStyles = makeStyles((theme) => ({
139137
container: {
140138
minHeight: 290,
141139
width: "100%",
@@ -192,7 +190,7 @@ const CurrencyPicker = ({ className }: { className?: string }) => {
192190
error={Boolean(meta.error)}
193191
helperText={Boolean(meta.error) ? meta.error : " "}
194192
SelectProps={{
195-
renderValue: val => {
193+
renderValue: (val) => {
196194
const currency = currencyManager.fromId(val as string)!;
197195
return (
198196
<CurrencyPickerItem
@@ -208,7 +206,7 @@ const CurrencyPicker = ({ className }: { className?: string }) => {
208206
}}
209207
>
210208
{getCurrenciesForPicker({
211-
currencyFilter: ({ network }) => chainId === 4 || network !== "rinkeby",
209+
currencyFilter: ({ network }) => chainId === 5 || network !== "goerli",
212210
})}
213211
</TextField>
214212
);
@@ -309,9 +307,8 @@ const Footer = ({
309307
account?: string;
310308
disabled?: boolean;
311309
}) => {
312-
const { submitForm, isValid, values, isSubmitting } = useFormikContext<
313-
IFormData
314-
>();
310+
const { submitForm, isValid, values, isSubmitting } =
311+
useFormikContext<IFormData>();
315312
return (
316313
<>
317314
<Hidden xsDown>
@@ -344,7 +341,7 @@ export const schema = Yup.object().shape<IFormData>({
344341
payer: Yup.string().test(
345342
"is-valid-recipient",
346343
"Please enter a valid ENS or ETH address",
347-
async function(value: string) {
344+
async function (value: string) {
348345
return (
349346
!value ||
350347
CurrencyManager.validateAddress(value, { type: "ETH" } as any) ||
@@ -356,14 +353,14 @@ export const schema = Yup.object().shape<IFormData>({
356353
reason: Yup.string().test(
357354
"is-valid-reason",
358355
"Reason contains unsupported characters or symbols.",
359-
val => {
356+
(val) => {
360357
return !val || isSimpleAscii(val);
361358
}
362359
),
363360
paymentAddress: Yup.string().required("Required"),
364361
});
365362

366-
const useStyles = makeStyles(theme => ({
363+
const useStyles = makeStyles((theme) => ({
367364
container: {
368365
width: "100%",
369366
background: "white",
@@ -409,7 +406,7 @@ export const CreateRequestForm = ({
409406
onSubmit={onSubmit}
410407
enableReinitialize
411408
initialValues={{
412-
currency: !network || network === 4 ? "FAU-rinkeby" : "DAI-mainnet",
409+
currency: !network || network === 5 ? "FAU-goerli" : "DAI-mainnet",
413410
amount: "" as any,
414411
payer: "",
415412
reason: "",

packages/create/src/connectors.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { InjectedConnector } from "@web3-react/injected-connector";
22

33
export const injected = new InjectedConnector({
4-
supportedChainIds: [1, 4, 100],
4+
supportedChainIds: [1, 5, 100],
55
});

packages/gnosis-safe/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"@material-ui/core": "^4.9.7",
99
"@material-ui/icons": "^4.9.1",
1010
"@material-ui/lab": "^4.0.0-alpha.46",
11-
"@requestnetwork/types": "^0.35.1-next.1581",
11+
"@requestnetwork/types": "^0.35.1-next.1787",
1212
"@testing-library/jest-dom": "^4.2.4",
1313
"@testing-library/react": "^9.3.2",
1414
"@testing-library/user-event": "^7.1.2",
@@ -54,4 +54,4 @@
5454
"last 1 safari version"
5555
]
5656
}
57-
}
57+
}
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
import { InjectedConnector } from "@web3-react/injected-connector";
22

3-
export const injected = new InjectedConnector({ supportedChainIds: [1, 4] });
3+
export const injected = new InjectedConnector({ supportedChainIds: [1, 5] });

packages/pay/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
"@material-ui/core": "^4.9.7",
77
"@material-ui/icons": "^4.9.1",
88
"@material-ui/lab": "^4.0.0-alpha.46",
9-
"@requestnetwork/payment-processor": "^0.37.1-next.1581",
10-
"@requestnetwork/request-client.js": "^0.39.1-next.1581",
9+
"@requestnetwork/payment-processor": "^0.37.1-next.1787",
10+
"@requestnetwork/request-client.js": "^0.39.1-next.1787",
1111
"@web3-react/core": "^6.0.7",
1212
"@web3-react/injected-connector": "^6.0.7",
1313
"@web3-react/walletconnect-connector": "^6.0.7",

0 commit comments

Comments
 (0)