Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lykhoyda/transfer balance #55

Merged
merged 14 commits into from
Jan 8, 2025
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
update bg
Lykhoyda committed Jan 6, 2025

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
commit 03b1f60e15340c1c5c88775b38a9ffcfe5e01c21
11 changes: 9 additions & 2 deletions packages/web-wallet/src/App.tsx
Original file line number Diff line number Diff line change
@@ -1,13 +1,20 @@
import { useInterval } from 'usehooks-ts';
import { useWebZjsActions } from '@hooks/useWebzjsActions.ts';
import Layout from '@components/Layout/Layout.tsx';
import { Outlet } from 'react-router-dom';
import { Outlet, useLocation } from 'react-router-dom';
import { RESCAN_INTERVAL } from './config/constants.ts';
import { useEffect } from 'react';

function App() {
const { triggerRescan } = useWebZjsActions();
const location = useLocation();

useEffect(() => {
// Add custom background to home page
document.body.classList.remove('home-page-bg');
if (location.pathname === '/') document.body.classList.add('home-page-bg');
}, [location]);

// rescan the wallet periodically
useInterval(() => {
triggerRescan();
}, RESCAN_INTERVAL);
Binary file added packages/web-wallet/src/assets/diamond-bg.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
52 changes: 28 additions & 24 deletions packages/web-wallet/src/styles/index.css
Original file line number Diff line number Diff line change
@@ -27,32 +27,36 @@

body {
position: relative;
background: linear-gradient(180deg, #fff 0%, #bcefef 187.66%);
overflow: hidden;
background: #FAFAFA url('../assets/diamond-bg.png') no-repeat center center fixed;

/* Noise background */
&:before {
content: '';
position: absolute;
width: 100vw;
height: 100vh;
z-index: -1;
opacity: 0.25;
background: url('../assets/noise.png') lightgray 0 0 / 15px 15px repeat;
mix-blend-mode: color-burn;
}
&.home-page-bg {
background: linear-gradient(180deg, #fff 0%, #bcefef 187.66%);

/* Noise background */
&:before {
content: '';
position: absolute;
width: 100vw;
height: 100vh;
z-index: -1;
opacity: 0.25;
background: url('../assets/noise.png') lightgray 0 0 / 15px 15px repeat;
mix-blend-mode: color-burn;
}

/* Yellow oval shape background */
&:after {
content: '';
position: absolute;
width: 75.5vw;
height: 88.1875rem;
top: 20rem;
left: 2.5rem;
z-index: -1;
border-radius: 88.1875rem;
background: rgba(187, 160, 17, 0.5);
filter: blur(274px);
/* Yellow oval shape background */
&:after {
content: '';
position: absolute;
width: 75.5vw;
height: 88.1875rem;
top: 20rem;
left: 2.5rem;
z-index: -1;
border-radius: 88.1875rem;
background: rgba(187, 160, 17, 0.5);
filter: blur(274px);
}
}
}