Skip to content

Commit 81713d3

Browse files
Revert club changes and fix ticker speed
Reverted the changes made to the Clubs section and addressed the CoinGecko ticker speed issue.
1 parent d6c8481 commit 81713d3

File tree

1 file changed

+15
-1
lines changed

1 file changed

+15
-1
lines changed

src/components/PriceTicker.tsx

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,21 @@ const PriceTicker = () => {
3939
widgetElement.setAttribute('outlined', 'true');
4040
widgetElement.setAttribute('coin-ids', 'bitcoin,tether-gold,ethereum,binancecoin,bitcoin-cash,bittensor,aave,solana,hyperliquid,avalanche-2,chainlink,injective-protocol,uniswap,internet-computer,aptos,cosmos,bitget-token,polkadot,sui,the-open-network,near,celestia,nexo,pi-network,tron,polygon-ecosystem-token,pancakeswap-token,osmosis,crypto-com-chain');
4141
widgetElement.setAttribute('initial-currency', 'usd');
42-
widgetElement.setAttribute('speed', '0.1'); // Extremely slow speed for better readability
42+
// Note: CoinGecko speed attribute doesn't always work, so we'll use CSS override
43+
widgetElement.setAttribute('speed', '1');
44+
45+
// Add custom CSS to slow down the animation
46+
const style = document.createElement('style');
47+
style.textContent = `
48+
gecko-coin-price-marquee-widget * {
49+
animation-duration: 120s !important;
50+
animation-timing-function: linear !important;
51+
}
52+
gecko-coin-price-marquee-widget [class*="marquee"] {
53+
animation-duration: 120s !important;
54+
}
55+
`;
56+
document.head.appendChild(style);
4357

4458
containerRef.current.appendChild(widgetElement);
4559

0 commit comments

Comments
 (0)