BibliothecaDAO / eternum

onchain eternal game
https://alpha-eternum.realms.world
MIT License
36 stars 30 forks source link

Loaf fix 4 #1031

Closed ponderingdemocritus closed 6 days ago

ponderingdemocritus commented 6 days ago

PR Type

Enhancement, Dependencies


Description


Changes walkthrough ๐Ÿ“

Relevant files
Enhancement
useTrade.tsx
Simplify useSetMarket hook by removing userHistory logic 

client/src/hooks/helpers/useTrade.tsx
  • Removed userHistory related code and logic.
  • Simplified the useSetMarket hook by removing unnecessary computations.

  • +0/-11   
    MarketModal.tsx
    Update MarketModal to exclude userHistory                               

    client/src/ui/components/trading/MarketModal.tsx
  • Removed userHistory from the useSetMarket hook usage.
  • Updated MarketTradingHistory component usage to exclude userHistory.
  • +2/-4     
    MarketTradingHistory.tsx
    Simplify MarketTradingHistory component by removing userTradingHistory

    client/src/ui/components/trading/MarketTradingHistory.tsx - Removed `userTradingHistory` prop and related rendering logic.
    +1/-11   
    RightNavigationModule.tsx
    Clean up RightNavigationModule by removing unused code     

    client/src/ui/modules/navigation/RightNavigationModule.tsx - Removed unused imports and variables.
    +1/-23   
    realms.tsx
    Refactor realm utility functions for better readability   

    client/src/ui/utils/realms.tsx
  • Refactored getRealmIdByPosition to use Object.entries and simplify
    logic.
  • Consolidated attribute value extraction logic in getRealm.
  • +24/-47 
    utils.tsx
    Update getResourceIdsFromPackedNumber to accept string input

    client/src/ui/utils/utils.tsx
  • Changed getResourceIdsFromPackedNumber to accept a string and convert
    it to BigInt.
  • +3/-2     
    Dependencies
    package.json
    Update @dojoengine dependencies to 0.7.9-alpha.1                 

    client/package.json - Updated `@dojoengine` dependencies to version `0.7.9-alpha.1`.
    +5/-5     
    pnpm-lock.yaml
    Update pnpm-lock.yaml for dependency changes                         

    pnpm-lock.yaml - Updated lock file to reflect new dependency versions.
    +44/-44 

    ๐Ÿ’ก PR-Agent usage: Comment /help on the PR to get a list of all available PR-Agent tools and their descriptions

    vercel[bot] commented 6 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 27, 2024 9:30am
    github-actions[bot] commented 6 days ago

    PR Reviewer Guide ๐Ÿ”

    โฑ๏ธ Estimated effort to review [1-5] 3
    ๐Ÿงช Relevant tests No
    ๐Ÿ”’ Security concerns No
    โšก Key issues to review Possible Bug:
    The removal of userHistory related code in useTrade.tsx and related components (MarketModal.tsx and MarketTradingHistory.tsx) might affect features that rely on user history data. Ensure that this removal does not unintentionally impact other functionalities that might be expecting userHistory data.
    Refactoring Impact:
    Significant refactoring and removal of code in multiple files could lead to unintended side effects or bugs if not thoroughly tested, especially in dynamic UI components and state management logic.
    github-actions[bot] commented 6 days ago

    Failed to generate code suggestions for PR