Giter VIP home page Giter VIP logo

pancake-frontend's Introduction

🥞 Pancake Frontend

This project contains the main features of the pancake application.

If you want to contribute, please refer to the contributing guidelines of this project.

Documentation

Install dependencies using pnpm

apps/web

How to start
pnpm i

start the development server

pnpm dev

build with production mode

pnpm build

# start the application after build
pnpm start

apps/aptos

How to start
pnpm dev:aptos
pnpm build:aptos

apps/blog

How to start
pnpm dev:blog
pnpm build:blog

apps/games

How to start
pnpm dev:games
pnpm build:games

Packages

Package Description
sdk An SDK for building applications on top of Pancakeswap
aptos-swap-sdk Aptos version of Swap SDK
swap-sdk-core Swap SDK Shared code
wagmi Extension for wagmi, including bsc chain and binance wallet connector
awgmi Connect to Aptos with similar wagmi React hooks.
smart-router An SDK for getting best trade routes.
multicall Enhanced multicall sdk to safely make multicalls within the gas limit.
v3-sdk An SDK for building applications on top of Pancakeswap V3.

pancake-frontend's People

Contributors

0xcorgi avatar aosiepcs avatar chef-cheems avatar chef-chungus avatar chef-jojo avatar chef-yogi avatar chefbingbong avatar chefhutch avatar chefilip avatar chefjackson avatar chefjerry avatar chefkai avatar chefmomota avatar chefnomi avatar chefwind avatar ciruz avatar dependabot[bot] avatar github-actions[bot] avatar hachiojidev avatar imgbot[bot] avatar memoyil avatar mustard-cake avatar pancake-swap avatar pancakeswap-bot avatar pancakeswap-github-bot avatar rabbitdoge avatar richardpk avatar serhioromano avatar sunopar avatar woody810 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

pancake-frontend's Issues

Bug : Multiple issues / correct ABI ?

CAKE to Harvest: not loading --> 0.0000
APR / Cake rate not loading
etc...

JS error in console :
4.2e516208.chunk.js:1 Uncaught (in promise) Error: Returned values aren't valid, did it run Out of Gas? You might also see this error if you are not using the correct ABI for the contract you are retrieving data from, requesting data from a block number that does not exist, or querying a node which is not fully synced.
at l.decodeParametersWith (4.2e516208.chunk.js:1)
at l.decodeParameters (4.2e516208.chunk.js:1)
at j.h._decodeMethodReturn (4.2e516208.chunk.js:1)
at h.outputFormatter (4.2e516208.chunk.js:1)
at h.formatOutput (4.2e516208.chunk.js:1)
at s (4.2e516208.chunk.js:1)
at 4.2e516208.chunk.js:1
at XMLHttpRequest.i.onreadystatechange (4.2e516208.chunk.js:1)

Wrong Spanish translation of "compound"

Is your feature request related to a problem? Please describe.
Compound in spanish is Reinvertir.
The word Calcular means do the math.

Describe the solution you'd like
Change Calcular by Reinvertir

Current:
imagen

Should be:
imagen

APY vs APR

Pankake Syrup pooling used the word APY everywhere but technically it is APR as we can read here:
https://www.investopedia.com/personal-finance/apr-apy-bank-hopes-cant-tell-difference/

APR does not take into account the compounding of interest within a specific year. It is calculated by multiplying the periodic interest rate by the number of periods in a year in which the periodic rate is applied. It does not indicate how many times the rate is applied to the balance.

Unlike APR, APY does take into account the frequency with which the interest is applied—the effects of intra-year compounding.

I can easily change the code to replace APY in Syrup pools with APR if needed

bMXX Pool

Could you check this pool configuration ?
Farming looks unexpectedly low. (something like /100)
Thanks

Translations not approved and translations missing

The Crowdin translation PR: #16 implements all changes currently within Crowdin.

Issues

  • All translations in the origin-UI file need to be approved again, currently there are no approved translations for any language (meaning fallbacks will be used across the site).
  • The source string for 1 CAKE = 1 SYRUP is wrong @Chef-Chungus https://crowdin.com/translate/pancakeswap/8/en-en#326
  • All translations within the file origin-UI.csv as of 14:27 UTC 10/20 have been implemented. But - there is definitely text in the app that isn't included in that file.
    Note: I have included details in the readme of how to add a translation to the code once it has been added to Crowdin

Staking liquidity before approving the contract can make the LP disappear?

Bug Description
Staking liquidity to a pool seems possible in the liquidity screen without approving the contract first.

Steps to Reproduce

  1. I bought a smaller coin
  2. Added that with BNB to a liquidity pool
  3. Confirmed
  4. Staked the LP pair directly from the liquidity page
  5. Checked the farms and did not find the LP staked.

Expected Behavior
If you have the option to stake it at the liquidity page, you would expect that everything else works. If the contract first should be approved, that should be prompted.

Perhaps I there is another issue but I think I just lost LP tokens.

Additional Context
I use Firefox on Ubuntu with the Binance Chain plug-in on the Binance Smart Chain Network.

I wanna see stacked amount value in cake or in USD

Is your feature request related to a problem? Please describe.
as a user, I want to view the evolution of the value of my stacked assets.

Describe the solution you'd like

I wanna see the current value of my coin in a pool or liquidity pair in a farm.
Example :
image

It could be an awesome to see the evolution of every assets.

In farm it would be nice to see the value of pairs in cake to remember how much i have stacked on this or this farm

So ! pancakeswap is awesome ! Thanks you so much

Nothing happens if we want to add stake in Farm or deposit tokens in pool

image

I am using Binance Smart Chain as wallet on Chrome browser

Attached image where UI get's stuck nothing happens after approving from wallet

Steps:
Go to Farm
Example Cake-BNB LP
Click on + button to which opens Stake LP tokens
Enter number of stake click on confirm
Which opens wallet, Approve transaction in wallet
Nothing happens after approval

Thanks

No 'approve' state on the dashboard lottery modal.

approve.button.lottery.dashboard.mov

Bug Description
On the dashboard there is no approve state, so a user is unable to approve contract interaction and when clicking "buy tickets" they are unable to buy tickets.

Steps to Reproduce

  1. Go to dashboard on a new wallet
  2. Click on buy tickets

Expected Behavior
Buy tickets would not show, the approve button should.

[Bounty] Update slider component to new design

Reward allocation:
$250 in CAKE

Description:
Our current site slider component is a little boring, we want to add some fun to it.
Task is to replace the existing slider component with the bunny version (please see figma for more design details)
You will need to do this in the UI Kit & apply it to the respective areas on the website (exchange & main site)
Design:
image

Resources:
https://www.figma.com/file/q5dKq3BuQZ4YzV5pR0Mt2M/Design-System-UI?node-id=3840%3A95164

Pancakeswap exchange cannot be embedded in an iframe

Bug Description
When https://exchange.pancakeswap.finance/#/swap is embedded within an iframe on a parent page, the embedded Pancakeswap page fails to load.

In the console, there are some warnings and errors thrown, and I think the issue is because pancakeswap uses a package called redux-localstorage-simple to sync redux state and localstorage. However, pages within an iframe cannot interact with localstorage if they are not on the same domain.

Minimal reproducible example: https://jsfiddle.net/fv93q4sg/

Steps to Reproduce

  1. Go to https://jsfiddle.net/fv93q4sg/

Expected Behavior
The Pancakeswap exchange site should work when embedded in an iframe. Uniswap's exchange works this way, and we are able to embed it on https://app.moontools.io/pairs/0x02f14c27037bd30f18a6578590fd40fafd3376ff for example, under the "Swap" tab.

QA Results: #482 (Tableview)

Relevant PR: #482

  1. Harvest button is disabled but should be enabled when there are funds earned.
    image

  2. Cake earned and amount staked - incorrect font color (numbers should not be black font)
    image

  3. Liquidity incorrect font color (numbers should not be black)
    image

  4. In dark mode, liquidity, earned and staked are wrong font color
    image

  5. Sort by & search are not adjusting to their dark variants
    image

  6. [lower priority] - Add soft drawer opening animation rather than just opening it suddenly. A short transition will be good.

  7. Strange compression of the 'table header' when shrinking the screen
    image

  8. At 340px wide viewport, the dividers extend beyond the table
    image

  9. IOS Safari/Chrome/Brave - The table rows are really thick. Unable to reproduce on emulated version of Iphone in chrome, consistent issue on real iphones
    image

  10. Search placeholder gets cut off on smaller viewports
    image

  11. The 'earned' sorting doesn't always work as expected (notice EGLD in this screenshot)
    image

  12. Missing spacing between the multiplier and the tooltip '?'
    image

Problem installing code

Bug Description
problem installing the node modules after downloading code.

npm ERR! While resolving: [email protected]
npm ERR! Found: [email protected]
npm ERR! node_modules/react
npm ERR! react@"^17.0.1" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react@"^16.12.0" from @binance-chain/[email protected]
npm ERR! node_modules/@binance-chain/bsc-use-wallet

Expected Behavior
I want it to download successfully so i can run the project

Feat: ability to filter deposited farms

Is your feature request related to a problem? Please describe.
As a pancakeswap user, time to time, I want to review how my staked LP tokens are doing. So I'm navigating to https://pancakeswap.finance/farms and now have to find few deposited farms out of the whole list of active farms. (Currently 57 items). It's a lot of scrolling and distraction.

Describe the solution you'd like
Add a staked button to secondary navigation. This will navigate the user to page/view with a list of farms where his/her LP tokens are staked
Screenshot 2021-02-02 at 23 20 21

Describe alternatives you've considered
Add a new filter bar, like the one https://app.beefy.finance/ having to filter list on the existing page.
Screenshot 2021-02-02 at 23 23 55

Additional context
This would dramatically improve the user experience for all the stakers.

Farms Table QA

QA result of: #336

image1

  • When entering “a” in the search box, the page crashes with the following errors.

image2

  • There shouldn’t be a margin on the text which moves the button. The button position should be fixed.

image3

  • Expand body width to 1200 max width, ensuring 24px margins

image4

image5

  • Scrollbar and table header should be fixed when the user scrolls down the table, so desktop users can scroll horizontally easily
  • The coin icon column should be fixed to the left when scrolling horizontally, and the section header and scrollbar are indented to account for it. (helps users to know what they’re looking at on mobile, that way)

image6

  • There is no spacing between the buttons and the text, compared with the figma on the right.
  • The [-] and [+] buttons are too wide, compared to the figma on the right.

image7

  • Need to add placeholder and search button for the search

image8

  • harvest button should be disabled when wallet is locked

image
image
Update wording:

  • Pool --> Farm
  • APY --> APR
  • View on BscScan --> BscScan
  • View on Info Site --> Info

image

  • Add toggle between table view and card view

[solved] liquidity remove not working

for 2 days, I was trying to remove a liquidity-Pair, which was not going through, because the confirm-button did nothing.

it boild down to a false date/time in that linux/debian VM, which I use for crypto-realted stuff only (walltes, & isolated browser).
the KVM-VM did get suspended at one time and did not reset the time to actual when it came online again.
there was no error-msg or hint from PCS-wsite.
after fixing this issue, rebooted the VM, every thing went back to normal.
might this info help sb, and/or maybe you guys can prg. some error-msg into your fabulous WS.

PC-Swap_2021-02-20_06-30

thx a lot for your dedication & work
guenter

Infite loop on binance chain wallet - can't approve contract

Bug Description
Can't approve contract in farm space

Steps to Reproduce

  1. Go to /farms
  2. Click unlock wallet
  3. if previouss step work Click on approve contract

On capture approve contact has been clicked

Screenshot 2021-03-02 at 14 38 04

Here the console (network tab):

Screenshot 2021-03-02 at 14 40 44

  1. Approve contract on binance chain wallet extension appear after about 5 min

    ...

Expected Behavior

Enter an amount of CAKE and start farm.

Additional Context

  • Chrome 88 on Mac OS Big sur 11.2.2
  • Ublock origin sometimes enabled

Developers Turned Scammers?

image

Hello, how is it that there's $16,559,214 in volume for BUNNY/WBNB on PancakeSwap but the general public can't trade it? I'm going to be contacting lawyers soon if the situation is not resolved.

Wallet disconnecting when going between <Trade> and other navigations in menu

Bug Description
Wallet disconnecting when going between and other navigations in menu

Steps to Reproduce

  1. Login (connect wallet)
  2. Click on Trade > Exchange for example
  3. You are logged off, so you need to login again

Expected Behavior
You are logged in whole time whenever you click in menu

Additional Context
Looks like wrong cookies scope as the items navigate to exchange.pancakeswap.finance, while other items navigate to pancakeswap.finance

After rejecting the wallet connect request by clicking close button, It cannot be shown again until restart

Bug Description
After rejecting the wallet connect request by clicking close button. It cannot be shown again until restart in PC

Steps to Reproduce

  1. Click Connect
  2. Click Wallet Connect
  3. Click close button without using qr
  4. See User rejected popup
  5. Then try to click WalletConnect again, you will see nothing happens
  6. After restart the page, first thing that you would see is the qr code strangely.

Expected Behavior
A consistent behaviour that everytime I should see the wallet connect qr code.

Additional Context
It is reproducible in pc

QA: Web3 React integration

Regarding: #346

MetaMask

FARMS

  • Modal doesn't close when funds are deposited despite transaction being confirmed, stays in "Pending confirmation" state.
  • Modal doesn't close when funds are withdrawn despite transaction being confirmed, stays in "Pending confirmation" state.
  • Harvest OK
  • Deposit OK
  • Withdraw OK
  • Approve OK

image

POOLS

  • Your stake - NaN
  • Cake earned - NaN
  • NaN cake Available when unstaking CAKE
  • Modal doesn't close when funds are unstaked despite transaction being confirmed, stays in "Pending confirmation" state.
  • Modal doesn't close when funds are staked despite transaction being confirmed, stays in "Pending confirmation" state.
  • Staking OK
  • Unstaking OK
  • Can't harvest due to NaN Cake Earned
    image
    image

Add pagination in farms to optimize resources [change to enhancement please]

Is your feature request related to a problem? Please describe.
At this moment pancakeswap have 63 farms in 3 columns, the scroll of page is large and hard to read with so many items. Also having so many elements also implies more calculations, therefore more consumption of resources for low end devices.

Describe the solution you'd like
Pagination of 12 or 24 items maybe? a select with options (6, 12, 24, 48)?
Less items, less resource consumption and therefore faster loading speed.

I want to collaborate with this project but I need the REACT_APP_CROWDIN_APIKEY and REACT_APP_CROWDIN_PROJECTID. Could someone send me the keys to try to help?

Congratulations for the project and thank you for sharing pancake-frontend on github! 🥞🙌

Best!

Harvest all count

Bug Description
Im actually in 2 farms / 2 pools
On home : harvest all (3)

Steps to Reproduce

Expected Behavior
On home : harvest all (4)

Additional Context
Im in the CAKE pool / COMP
Maybe related

Pool and Farming Pages Bugs

Situation

Android10
Trust Wallet ver1.19.21
DApps browser in Trust Wallet

Bug details

https://i.imgur.com/iwBYcNO.png
This bug occurs when the Pool page (or Farming) is continuously displayed for more than 30 seconds under the above conditions.
The token display in stakes changes to zero. Or it becomes NaN.
Reloading does not fix it.

How to resolve it.

Forced to change the IP
For example, if you have a WiFi connection, you can fix it by switching to a 5G or 4G line (mobile line).

My Thoughts.

How would the user feel if the token amount shows 0 immediately after staking a large sum of money?
Perhaps users will not invest any more money.
This kind of precarious situation leads directly to credit problems.
Please deal with it as soon as possible.

Warning when open Info->Pairs

Bug Description
Warning: The data on this site has only synced to Binance Smart Chain block 4928512 (out of 4932297). Please check back soon.

Steps to Reproduce

  1. Go to Info
  2. Go to Pairs

Expected Behavior
To see the pairs

UI elements wrong (lottery countdown time)

Bug Description
'Until ticket sale' times on lottery page are not reflecting the correct hour number (always 0).

Steps to Reproduce

  1. Go to lottery page
  2. See 'Until ticket sale' time wrong

Expected Behavior
Time to reflect correctly.

I am not sure what the correct time is meant to be for the ticket sale but this keeps rolling over to 59 minutes after it counts to zero. So im assuming the hour is just not reflecting correctly
Only seen on desktop. Have not checked on mobile.
MacOS, Chrome Browser version 88.0.4324.150.

image

Lottery document is now obsolote

Bug Description
Lottery document is now obsolote

Steps to Reproduce

  1. Go to lottery
  2. Click on read more
  3. It says Lottery Ticket Fee for 1 ticket: 10 CAKE

Expected Behavior
Lottery Ticket Fee for 1 ticket: 1 CAKE and more other changes

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.