Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: support Subgraph, Contract Updatable, Arweare #62

Open
wants to merge 31 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
e461467
feat: add subgraph
shixin-guo Sep 18, 2022
4745d18
feat: update dependence
shixin-guo Sep 20, 2022
8fc9424
feat: dependence update
shixin-guo Sep 20, 2022
6bcfc88
feat: add
shixin-guo Sep 25, 2022
32897d2
fix: add
shixin-guo Sep 25, 2022
14143c2
feat: add
shixin-guo Sep 26, 2022
f957d56
fix: bug
shixin-guo Sep 28, 2022
50560cb
fix: change code
shixin-guo Oct 1, 2022
fa99acf
feat: remove useless code
shixin-guo Oct 1, 2022
c03caf0
feat: support upload to arweare
shixin-guo Oct 2, 2022
4bc9772
fix: bug
shixin-guo Oct 3, 2022
44dce9a
fix: bug
shixin-guo Oct 3, 2022
fd5a49c
feat: format code
shixin-guo Oct 4, 2022
c595bd5
fix : remove useless code
shixin-guo Oct 8, 2022
cf19540
feat: add
shixin-guo Oct 9, 2022
c4f7923
fix: add symbol link
shixin-guo Oct 9, 2022
ee987c6
feat: update to goerli
shixin-guo Oct 10, 2022
9fd8552
feat: contract upgradable
shixin-guo Oct 10, 2022
4e1c4d4
feat: update dependence
shixin-guo Oct 11, 2022
be5091b
feat: export ABI file
shixin-guo Oct 11, 2022
eb7a0f2
fix: remove some todo
shixin-guo Oct 11, 2022
a0731ce
feat: deploy to goerli test net
shixin-guo Oct 16, 2022
58bb94e
feat: subgraph
shixin-guo Oct 18, 2022
8f4732f
fix: remove useless file
shixin-guo Oct 18, 2022
3d07ca6
feat: change entity
shixin-guo Oct 22, 2022
8da4f69
feat: subgraph v4
shixin-guo Oct 23, 2022
5d9a6b3
fix: ts error
shixin-guo Oct 23, 2022
f0d1aa0
fix: subgraph owner is null
shixin-guo Oct 24, 2022
f0113a4
fix: remove count
shixin-guo Oct 24, 2022
e8c6c62
fix: owner is null
shixin-guo Oct 25, 2022
697e262
fix: remove log
shixin-guo Oct 25, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions .env.template
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
NEXT_PUBLIC_FIREBASE_API_KEY=
NEXT_PUBLIC_FIREBASE_AUTH_DOMAIN=
NEXT_PUBLIC_FIREBASE_MEASUREMENT_ID=
NEXT_PUBLIC_FIREBASE_DATABASE_URL=
NEXT_PUBLIC_FIREBASE_PROJECT_ID=
NEXT_PUBLIC_FIREBASE_STORAGE_BUCKET=
NEXT_PUBLIC_FIREBASE_MESSAGING_SENDER_ID=
NEXT_PUBLIC_FIREBASE_APP_ID=

# for firebase-admin
FIREBASE_CLIENT_EMAIL=
FIREBASE_PRIVATE_KEY=


# NEXT_PUBLIC_MARKETPLACEADDRESS=

NEXT_PUBLIC_MARKETPLACEADDRESS= 0x5FbDB2315678afecb367f032d93F642f64180aa3

# NEXT_PUBLIC_BUNDLER_HTTP_ADDRESS = http://node1.bundlr.network
NEXT_PUBLIC_BUNDLER_HTTP_ADDRESS = https://devnet.bundlr.network

NEXT_PUBLIC_INFURA_RPC_URL = https://rinkeby.infura.io/v3/9aa3d95b3bc440fa88ea12eaa4456161

op_account_private_key =
infura_project_id =
30 changes: 27 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,8 @@ yarn-error.log*
.env.development.local
.env.test.local
.env.production.local

# use systemlink so sync env virable
!site/marketplace/.env
# vercel
.vercel

Expand All @@ -51,5 +52,28 @@ yarn-error.log*
packages/contract/cache/solidity-files-cache.json

#Hardhat files
# cache
# artifacts
artifacts
artifacts-ref/
hh-cache/
hh-cache-coverage/
hh-cache-ref/
temp-src-coverage/
packages/contract/abi/@openzeppelin
packages/contract/.openzeppelin/
packages/contract/cache/
!packages/contract/artifacts/contracts

# Directories used by tools like mocha & istanbul & openzeplinn
coverage
coverage.json
shippable
.openzeppelin/
eth-gas-reporter.log

###########################
generated/



# SUBGRAPH file. Because it's generated per each network
subgraph.yaml
14 changes: 13 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,17 @@
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true,
"css.lint.unknownAtRules": "ignore",
"cSpell.words": ["MARKETPLACEADDRESS"]
"cSpell.words": [
"arweare",
"Arweave",
"bundlr",
"codegen",
"connectkit",
"graphprotocol",
"MARKETPLACEADDRESS",
"Searchbar",
"sepolia",
"Treejer",
"znft"
]
}
2 changes: 1 addition & 1 deletion ISSUE_TEMPLATE/1.core_bug_report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ body:
- type: checkboxes
attributes:
label: Verify latest commit
description: `main` is the latest version of Next.js Commerce.
description: `main` is the latest version of Zoom NFT Marketplace.
options:
- label: I verified that the issue exists on `main`
required: true
Expand Down
2 changes: 1 addition & 1 deletion ISSUE_TEMPLATE/2.provider_bug_report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ body:
- type: checkboxes
attributes:
label: Verify latest commit
description: `main` is the latest version of Next.js Commerce.
description: `main` is the latest version of Zoom NFT Marketplace.
options:
- label: I verified that the issue exists on `main`
required: true
Expand Down
4 changes: 2 additions & 2 deletions ISSUE_TEMPLATE/4.docs_request.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: 'Docs Request for an Update or Improvement'
description: A request to update or improve Next.js Commerce documentation
description: A request to update or improve Zoom NFT Marketplace documentation
title: 'Docs: '
labels:
- 'template: documentation'
Expand All @@ -15,4 +15,4 @@ body:
label: Is there any context that might help us understand?
description: A clear description of any added context that might help us understand.
validations:
required: true
required: true
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ Feature Request:
3. Install the dependencies: `yarn`
4. Duplicate `site/.env.template` and rename it to `site/.env.local`
5. Add proper store values to `site/.env.local`
6. start local etherum node `yarn start:node`
7. open another terminal and deplop contract `yarn dev:deploy`
6. start local ethereum node `yarn start:node`
7. open another terminal and deploy contract `yarn dev:deploy`
8. start local UI project

## Work in progress
Expand Down
30 changes: 16 additions & 14 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,32 +1,28 @@
{
"name": "commerce",
"name": "znft-website",
"license": "MIT",
"private": true,
"workspaces": {
"packages": [
"packages/*",
"site/*"
],
"nohoist": [
"**/@nomiclabs/**"
]
},
"scripts": {
"build": "turbo run build --scope=next-commerce --include-dependencies --no-deps",
"build": "turbo run build --scope=marketplace --include-dependencies --no-deps",
"dev": "turbo run dev",
"dev:web": "turbo run dev --scope=next-commerce --include-dependencies --no-deps",
"start:node": "yarn workspace contract start:node",
"dev:deploy": "yarn workspace contract deploy:local",
"test:deploy": "yarn workspace contract deploy:rinkeby",
"start": "turbo run start",
"dev:ui": "turbo run dev --scope=marketplace --include-dependencies --no-deps",
"contract:start": "yarn workspace contract start:node",
"contract:local": "yarn workspace contract deploy:local",
"contract:goerli": "yarn workspace contract deploy:goerli",
"types": "turbo run types",
"prettier-fix": "prettier --write ."
},
"devDependencies": {
"husky": "7.0.4",
"lint-staged": "12.4.1",
"husky": "8.0.1",
"lint-staged": "12.5.0",
"prettier": "2.7.1",
"turbo": "1.3.1"
"turbo": "1.5.6"
},
"husky": {
"hooks": {
Expand All @@ -44,5 +40,11 @@
"git add"
]
},
"packageManager": "[email protected]"
"packageManager": "[email protected]",
"installConfig": {
"hoistingLimits": "**/@nomiclabs/**"
},
"dependencies": {
"dotenv": "^16.0.3"
}
}
8 changes: 4 additions & 4 deletions packages/commerce/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
}
},
"dependencies": {
"@vercel/fetch": "^6.1.1",
"@vercel/fetch": "^6.2.0",
"deepmerge": "^4.2.2",
"import-cwd": "^3.0.0",
"js-cookie": "^3.0.1",
Expand All @@ -64,13 +64,13 @@
"@taskr/watch": "1.1.0",
"@types/js-cookie": "3.0.2",
"@types/node": "17.0.45",
"@types/react": "17.0.45",
"next": "12.2.0",
"@types/react": "17.0.50",
"next": "12.3.1",
"prettier": "2.7.1",
"react": "17.0.2",
"react-dom": "17.0.2",
"taskr": "1.1.0",
"taskr-swc": "^0.0.1",
"typescript": "4.7.4"
"typescript": "4.8.3"
}
}
10 changes: 0 additions & 10 deletions packages/commerce/src/config.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -18,17 +18,7 @@ function withCommerceConfig(nextConfig = {}) {

const commerceNextConfig = importCwd(path.posix.join(provider, 'next.config'))
const config = merge(nextConfig, commerceNextConfig)
const features = merge(
config.commerce.features,
config.commerce[provider]?.features ?? {}
)

config.env = config.env || {}

Object.entries(features).forEach(([k, v]) => {
if (v) config.env[`COMMERCE_${k.toUpperCase()}_ENABLED`] = true
})

return config
}

Expand Down
79 changes: 0 additions & 79 deletions packages/contract/README.md

This file was deleted.

Loading