Skip to content

Commit

Permalink
Add arbitrum goerli network (#74)
Browse files Browse the repository at this point in the history
* feat: added debt surplus and collateral auctions (#44)

* feat: add auction route

* chore: fix some texts and add temporary surplus image

* feat: add autions to navbar

* chore: add auction types

* feat: add auction components

* feat: add temporary useAuction hook

* chore: fix surplus icon

* feat: use hook for mocked values

* fix: error loading vaults with outdated sdk

* chore: add console.error

* feat: add call to sdk for events

* feat: add more auction files

* chore: remove example values and use sdk auction call

* feat: add approve token logic, temporary disabled

* feat: add more mocked values for auction state

* fix: logs and wallet error

* fix: helper function

* chore: remove temporary values from AuctionBlock

* chore: add new temporary value on auctionModel

* chore: better mocking on the auction hook

* chore: remove temporary commented code

* chore: remove temporary commented code

* chore: remove temporary commented code in AuctionsList

* chore: add space on AuctionBlock

* feat: search surplus and debt auctions separately

* feat: update sdk

* chore: use geb hook (#52)

* feat: implement auctions data  (#54)

* chore: use geb hook

* fix: approve logic

* feat: auctions config data fetch

* feat: accounting engine data

* feat: safeEngine data

* feat: implement surplus auction data

* feat: surplus bid functionality

* feat: debt auctions

* chore: fix buy and sell decimals on useAuction

* fix: start auction logic

* feat: update user hai and kite balances

* fix: approve logic and update list after bidding

* feat: get internal values

* fix: formatNumber function

* fix: bid in debt auctions

* fix: auctionPayments logic

* feat: batch coin protocol balance (#55)

* feat: batch coin protocol balance

* feat: save fetched values

---------

Co-authored-by: Ardy <ardy@defi.sucks>

---------

Co-authored-by: shaito <shaito@defi.sucks>
Co-authored-by: shaito <106555513+0xShaito@users.noreply.github.com>

* feat: update sdk

* feat: settle auctions from the UI (#58)

* feat: use proxy when claim and fix debt error bug

* feat: settle auctions from the ui

* chore: log proxy address

* feat: update auctions after an action

* feat: fetch collateral auction data (#57)

* feat: fetch collateral auction data

* feat: implement collateral auctions section (#59)

* feat: update sdk + set empty list on change

* fix: undefined geb

* feat: auctions loading (#60)

* feat: auctions on state (#63)

* feat: auctions on state

* feat: switch statement

* feat: collateral auctions dropdown (#62)

* feat: auctions loading

* chore: temporary mocked auctions

* feat: collaterals dropdown

* feat: improve buy collateral modals

* feat: auctions on state

* feat: switch statement

* feat: update get collateral price contract

* fix: switch functions

* fix: contract variable names

* chore: update fetchCollateralAuctionData function

---------

Co-authored-by: shaito <shaito@defi.sucks>

* feat: auctions timeout (#68)

* fix: empty auctions (#65)

* fix: empty auctions

* feat: empty auctions

* feat: claiming hai and kite (#67)

* feat: get collateral data implementation (#69)

* feat: add collateralData into state

* feat: store collateral and hai input amounts

* fix: typo

* feat: get prices

* fix: typo

* feat: fill collateral auction data

* chore: update sdk

* feat: remove temporary any

* feat: initial amount

---------

Co-authored-by: shaito <shaito@defi.sucks>

* feat: collateral auction max discount time

---------

Co-authored-by: Ardy <116569704+0xArdy@users.noreply.github.com>

* feat: collateral modals (#70)

* feat: auctions timeout (#68)

* fix: empty auctions (#65)

* fix: empty auctions

* feat: empty auctions

* feat: claiming hai and kite (#67)

* feat: add collateralData into state

* feat: store collateral and hai input amounts

* fix: typo

* feat: get prices

* fix: typo

* feat: fill collateral auction data

* chore: update sdk

* feat: approval logic

* feat: collateral auction checks

* feat: update state after buy collateral

* fix: remove redundant code

* chore: remove unused code

* feat: cooldown text

* fix: cooldown text

* feat: collateral FAQ

* chore: remove comments

* chore: run prettier

* chore: update sdk

* fix: undo sellAmountParsed function changes

* fix: remove collateral conditionals on AuctionBlock component

---------

Co-authored-by: shaito <shaito@defi.sucks>
Co-authored-by: shaito <106555513+0xShaito@users.noreply.github.com>

* chore: remove staked_token things and unused variables (#71)

* feat: update state after buy collateral

* fix: remove redundant code

* chore: remove unused code

* feat: cooldown text

* fix: cooldown text

* feat: collateral FAQ

* chore: remove comments

* chore: remove staked_tokens things

* fix: remove unused vars

* chore: run prettier

* feat: optimize stone image

* feat: set isSubmitting to false when tx fails

---------

Co-authored-by: shaito <shaito@defi.sucks>
Co-authored-by: shaito <106555513+0xShaito@users.noreply.github.com>

* fix: decimals, duplicated buy rows and update branch with dev (#72)

* style: improve buttons feedback (#46)

* feat: low decimals

* feat: fix token pricing

* fix: modify safe token price + hai balance

* fix: create safe token pricing

* style: add opacity on hover in safeList, back, deposit and repay buttons

* feat: fix back button logic and set deposit as default

---------

Co-authored-by: shaito <shaito@defi.sucks>

* feat: airdrop claimer (#51)

* feat: airdrop claimer

* feat: better tx management

* fix: text

* fix: text

* fix: handle tx reject

* feat: fetch collateral auction data

* feat: implement collateral auctions section (#59)

* feat: update sdk + set empty list on change

* fix: undefined geb

* feat: auctions loading (#60)

* feat: auctions on state (#63)

* feat: auctions on state

* feat: switch statement

* feat: collateral auctions dropdown (#62)

* feat: auctions loading

* chore: temporary mocked auctions

* feat: collaterals dropdown

* feat: improve buy collateral modals

* feat: auctions on state

* feat: switch statement

* feat: update get collateral price contract

* fix: switch functions

* fix: contract variable names

* chore: update fetchCollateralAuctionData function

---------

Co-authored-by: shaito <shaito@defi.sucks>

* feat: auctions timeout (#68)

* fix: empty auctions (#65)

* fix: empty auctions

* feat: empty auctions

* feat: claiming hai and kite (#67)

* feat: add collateralData into state

* feat: store collateral and hai input amounts

* fix: typo

* feat: get prices

* fix: typo

* feat: fill collateral auction data

* chore: update sdk

* feat: approval logic

* feat: collateral auction checks

* feat: update state after buy collateral

* fix: remove redundant code

* chore: remove unused code

* feat: cooldown text

* fix: cooldown text

* feat: collateral FAQ

* chore: remove comments

* chore: remove staked_tokens things

* fix: remove unused vars

* chore: run prettier

* feat: optimize stone image

* feat: set isSubmitting to false when tx fails

* feat: remove duplicated buy items

* fix: remove more than 18 decimals on inputs

* chore: remove erc20 hai balance from coin internal balance

* chore: remove unused function

* fix: build

* fix: collateral input

* fix: remove log

* chore: rename variables

* fix: max buttons on buy collateral auctions

* fix: result values

* fix: auctions navbar on mobile

* chore: update pkg

* fix: debt bids

---------

Co-authored-by: shaito <shaito@defi.sucks>
Co-authored-by: shaito <106555513+0xShaito@users.noreply.github.com>

* chore: remove logs

---------

Co-authored-by: shaito <shaito@defi.sucks>
Co-authored-by: shaito <106555513+0xShaito@users.noreply.github.com>

* fix: modify safe inputs

* feat: updating sdk (#75)

* feat: virtually taxing collaterals before state querying (#64)

* feat: remove starter bidder and add Max texts (#78)

* feat: remove starter bidder

* feat: max texts on buy collateral modals

* feat: liquidate own safe (#77)

* feat: liquidate own safe

* feat: liquidate vault

* feat: liquidate vault

* feat: sdk

* feat: liquidate vault

* feat: liquidatable text + other hardcoded variables

* feat: pr fixes

* feat: wrap ether (#74)

* fix: modify safe inputs

* feat: wrap ether setup

* fix: close modal after deposit

* feat: use eth balance and update weth balance after wrap

* feat: leave 0.01 eth when the user click max

* feat: show eth balance on modal

* fix: remove classname

* fix: texts

* chore: rename files

* feat: better collateral auction max 

* feat: better cah max

* feat: better cah max

* feat: analytics tab 

* feat: analytics setup

* chore: remove some class names and add comments

* feat: adding batch analytics query contract

* feat: tables

* chore: remove log

* fix: list keys

* feat: use virtual analytic contract to fetch data

* fix: filter undefined contracts

* feat: adding debtAmount per collat (#82)

* feat: adding debtAmount per collat

* fix: typo

* feat: adding redemption rate query

* feat: debt column (#83)

* feat: adding debtAmount per collat

* fix: typo

* feat: adding redemption rate query

* feat: debt column

* feat: format numbers

* feat: use format function

* chore: hide locked amount

* style: cards

* style: cards width

* feat: adding descriptions to market and redemption prices

---------

Co-authored-by: Weißer Hase <wei3erHase@protonmail.com>

* feat: adding redemption rates to stats (#86)

* feat: adding partial rr to analytics script

* refactor: standarizing decoded vars declaration

* fix: typo in sol file

* feat: adding stability fee to collat analytics

* fix: typo

* feat: redemption rate cards (#87)

* feat: adding partial rr to analytics script

* refactor: standarizing decoded vars declaration

* fix: typo in sol file

* feat: adding stability fee to collat analytics

* fix: typo

* feat: redemption rate cards and remove some  unused code

* feat: add iRate, pRate and improve ststyles and code

---------

Co-authored-by: Weißer Hase <wei3erHase@protonmail.com>

* feat: bump sdk version

* feat: cleaning texts and adding cah faq 

* feat: cleaning texts and adding cah faq

* fix: rm empty

* feat: added borrow rates to collats (#88)

* feat: added borrow rates to collats

* feat: improve hai prices precision

* feat: add erc20 link in collaterals table

* feat: added button to auction debt (#91)

* feat: added button to auction debt

* fix: typos

* fix: debt amount to start auction

* fix: debt calculation

* fix: rm negative surplus

* fix: debt calculation

* fix: typo

* fix: types on useStartAuction hook

---------

Co-authored-by: Ardy <116569704+0xArdy@users.noreply.github.com>

* fix: faq typo and linter run (#93)

* fix: faq typo

* chore: run prettier

* feat: added collateral and global stats (#92)

* feat: added erc20 balance and debts

* feat: querying debt ceilings

* feat: added delayed oracle

* feat: added oracle title

* feat: improved rate multiplication calc

* feat: added collateral debt utilization

* feat: add collateralization ratio and debt utilization

* feat: querying SF in treasury

* feat: add scroll in collateral table

* feat: fix wad percentages

* feat: reordered table

* feat: add tooltips on collat table (#97)

* feat: add scroll in collateral table

* feat add tooltip on collat table

* feat: added descriptions

* fix: run prettier

---------

Co-authored-by: Weißer Hase <wei3erHase@protonmail.com>

* feat: added description and fixed typo

---------

Co-authored-by: Ardy <116569704+0xArdy@users.noreply.github.com>

* feat: add contract descriptions (#98)

* feat: add contract descriptions

* feat: fix contract descriptions

* fix: addressing comments in pr

---------

Co-authored-by: Weißer Hase <wei3erHase@protonmail.com>

* feat: fixes for rc-1.1 (#85)

* chore: use canary release

* fix: package.json

* fix: build

* fix: build

* fix: pkg

* feat: fixing interfaces for clean deployment

* feat: add example.env file

* feat: working with linked sdk

* feat: adding lockedAmount from safe engine

* fix: fetch user safes data

* fix: solidity interfaces

* feat: redeploy airdropper

* feat: canary sdk release

* fix: cah auctions card

* fix: batch scripting

* fix: systemCoin contract description

* fix: systemCoin contract description linter

* fix: collateral bid in recent txs

* fix: stability fee calc on safes

* chore: importing sdk v1.1

---------

Co-authored-by: Weißer Hase <wei3erHase@protonmail.com>

* fix: surplus calculation (#102)

* fix: surplus calculation

* fix: rm gasLimit

* feat: mv solidity virtual contracts to sdk (#103)

* feat: mv solidity virtual contracts to sdk

* chore: bumping sdk version

* fix: bump sdk

* new modal opening, no qr codes appearing

* modals working, added more chains, added provider as replacement for library

* connect wallet modal now has old styles, making sure network is set in env, hardcode project id for wallet connect, remove ens logic

* more bug fixes, cleanup

* fix connectwithselect errors

* persist wallet, no console log, fix etherscan links

* connector modal opens on change, overlapping divs bug fix, no disconnect when MM

* license info, prettier

* modal fixes

* never show blank screen

* feat: implementing rc-1.2 sdk (#104)

* add arbitrum goerli network option

* update getProxy

* Using virtual data from sdk

* change create facilitator text

* remove yarn link

* Add FTRG

* Update earthly

---------

Co-authored-by: Ardy <116569704+0xArdy@users.noreply.github.com>
Co-authored-by: shaito <shaito@defi.sucks>
Co-authored-by: shaito <106555513+0xShaito@users.noreply.github.com>
Co-authored-by: Weißer Hase <wei3erHase@protonmail.com>
Co-authored-by: jahabeebs <jahgoreds@gmail.com>
  • Loading branch information
6 people committed Aug 22, 2023
1 parent d2f70e6 commit 4431859
Show file tree
Hide file tree
Showing 88 changed files with 2,879 additions and 2,949 deletions.
3 changes: 1 addition & 2 deletions Earthfile
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ deps:
COPY .yarnrc.yml .yarnrc.yml
COPY .yarn .yarn
COPY src src
COPY solidity solidity
COPY craco.config.js craco.config.js
COPY tsconfig.json tsconfig.json
COPY public public
Expand All @@ -29,4 +28,4 @@ build-app:
FROM +deps
ARG ENVIRONMENT='local'
ARG VERSION='latest'
RUN yarn prebuild && yarn build
RUN yarn build
25 changes: 13 additions & 12 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,17 +1,9 @@
{
"name": "@hai-on-op/app",
"version": "0.0.0",
"homepage": ".",
"name": "@usekeyp/od-app",
"version": "1.2.0",
"private": true,
"workspaces": {
"packages": [
".",
"solidity"
]
},
"scripts": {
"start": "craco start",
"prebuild": "cd ./solidity && yarn compile",
"build": "craco build",
"test": "craco test",
"eject": "craco eject",
Expand All @@ -29,6 +21,7 @@
},
"dependencies": {
"@apollo/client": "^3.7.17",
"@coinbase/wallet-sdk": "^3.7.1",
"@craco/craco": "7.1.0",
"@ethersproject/address": "^5.0.10",
"@ethersproject/experimental": "5.4.0",
Expand All @@ -42,16 +35,23 @@
"@types/node": "^12.0.0",
"@types/react": "^17.0.2",
"@types/react-dom": "^17.0.1",
"@usekeyp/od-sdk": "^1.1.0-rc.2",
"@usekeyp/od-sdk": "^1.2.0-rc.3",
"@walletconnect/web3-provider": "1.8.0",
"@web3-react/core": "^6.0.9",
"@web3-react/coinbase-wallet": "^8.2.0",
"@web3-react/core": "^8.2.0",
"@web3-react/injected-connector": "^6.0.7",
"@web3-react/metamask": "^8.2.1",
"@web3-react/network": "^8.2.0",
"@web3-react/url": "^8.2.0",
"@web3-react/walletconnect": "^8.2.0",
"@web3-react/walletconnect-connector": "6.2.4",
"@web3-react/walletconnect-v2": "^8.3.7",
"@web3-react/walletlink-connector": "6.2.3",
"@webflow/webflow-cli": "^1.5.1",
"async-retry": "^1.3.1",
"autoprefixer": "^9",
"axios": "^0.27.2",
"buffer": "^6.0.3",
"classnames": "^2.2.6",
"comma-number": "^2.1.0",
"dayjs": "^1.9.4",
Expand Down Expand Up @@ -88,6 +88,7 @@
"styled-components": "^5.2.0",
"tailwindcss": "^3.3.3",
"typescript": "^4.4.3",
"util": "^0.12.5",
"walletlink": "^2.1.0",
"web3-react-types": "npm:@web3-react/types@^6.0.7"
},
Expand Down
2 changes: 0 additions & 2 deletions solidity/.gitignore

This file was deleted.

33 changes: 0 additions & 33 deletions solidity/contracts/TokensData.sol

This file was deleted.

164 changes: 0 additions & 164 deletions solidity/contracts/VirtualAnalyticsData.sol

This file was deleted.

Loading

0 comments on commit 4431859

Please sign in to comment.