Closed aymericdelab closed 5 days ago
The latest updates on your projects. Learn more about Vercel for Git โ๏ธ
Name | Status | Preview | Comments | Updated (UTC) |
---|---|---|---|---|
eternum | โ Ready (Inspect) | Visit Preview | ๐ฌ Add feedback | Jun 28, 2024 1:00pm |
โฑ๏ธ Estimated effort to review [1-5] | 4 |
๐งช Relevant tests | No |
๐ Security concerns | No |
โก Key issues to review |
Possible Bug: The removal of the BankAccounts component and related hooks might cause issues if there are still references to them elsewhere in the code that were not updated or removed in this PR. It's crucial to ensure that all dependencies and references are appropriately handled to avoid runtime errors. |
Performance Concern: The new slippage calculation in MarketManager.ts introduces more complex arithmetic operations which could impact performance, especially if called frequently. It's important to assess the performance impact of these changes, possibly through profiling or adding performance benchmarks. | |
Data Handling: The addition of entity_id in various liquidity and swap operations suggests changes in how entities are identified and managed. This should be carefully reviewed to ensure that it does not introduce any inconsistencies or errors in entity management. |
Failed to generate code suggestions for PR
Just run prettier please
PR Type
Enhancement, Bug fix
Description
BankAccounts
component and related hooks and logic.MarketManager
slippage calculation.entity_id
parameter to liquidity and swap operations.EternumGlobalConfig
for bank fees.Changes walkthrough ๐
19 files
contractComponents.ts
Remove `BankAccounts` component definition.
client/src/dojo/contractComponents.ts - Removed `BankAccounts` component definition.
MarketManager.ts
Update slippage calculation logic in `MarketManager`.
client/src/dojo/modelManager/MarketManager.ts
slippage
method to includeisSellingResource
parameter.useBanks.tsx
Remove `useBanks` hook and related logic.
client/src/hooks/helpers/useBanks.tsx - Removed `useBanks` hook and related logic.
useEntities.tsx
Remove `BankAccounts` references and adjust entity queries.
client/src/hooks/helpers/useEntities.tsx
BankAccounts
component.useResources.tsx
Remove `useGetBankAccountOnPosition` hook.
client/src/hooks/helpers/useResources.tsx - Removed `useGetBankAccountOnPosition` hook.
AddLiquidity.tsx
Add `entity_id` parameter to `add_liquidity` call.
client/src/ui/components/bank/AddLiquidity.tsx - Added `entity_id` parameter to `add_liquidity` call.
BankList.tsx
Update `BankPanel` and remove unused components.
client/src/ui/components/bank/BankList.tsx
OpenBankAccount
andBankEntityList
components.BankPanel
to userealmEntityId
.LiquidityResourceRow.tsx
Add `entityId` parameter to `remove_liquidity` call.
client/src/ui/components/bank/LiquidityResourceRow.tsx - Added `entityId` parameter to `remove_liquidity` call.
LiquidityTable.tsx
Add `entity_id` parameter to `LiquidityResourceRow` component.
client/src/ui/components/bank/LiquidityTable.tsx - Added `entity_id` parameter to `LiquidityResourceRow` component.
OpenBankAccount.tsx
Remove `OpenBankAccount` component.
client/src/ui/components/bank/OpenBankAccount.tsx - Removed `OpenBankAccount` component.
ResourceBar.tsx
Add margin to `TextInput` component.
client/src/ui/components/bank/ResourceBar.tsx - Added margin to `TextInput` component.
Swap.tsx
Update swap operations and fee constants.
client/src/ui/components/bank/Swap.tsx
EternumGlobalConfig
.entity_id
parameter to swap operations.Config.tsx
Remove `Banks` from `OSWindows` type.
client/src/ui/components/navigation/Config.tsx - Removed `Banks` from `OSWindows` type.
MarketModal.tsx
Update `MarketModal` to use `useGetBanks` hook.
client/src/ui/components/trading/MarketModal.tsx
MarketModal
to useuseGetBanks
hook.index.ts
Add script for setting up admin bank.
config/bank/index.ts - Added script for setting up admin bank.
global.ts
Update `EternumGlobalConfig` for bank fees.
sdk/packages/eternum/src/constants/global.ts - Updated `EternumGlobalConfig` for bank fees.
index.ts
Add `create_admin_bank` method and update liquidity/swap methods.
sdk/packages/eternum/src/provider/index.ts
create_admin_bank
method.entity_id
.provider.ts
Add `CreateAdminBankProps` and update interfaces.
sdk/packages/eternum/src/types/provider.ts
CreateAdminBankProps
interface.entity_id
.set_admin_bank.sh
Add script for setting up admin bank.
scripts/set_admin_bank.sh - Added script for setting up admin bank.
1 files
contracts.sh
Update contract addresses for bank systems.
contracts/scripts/contracts.sh - Updated contract addresses for bank systems.