Skip to content

Commit

Permalink
fixed QR code page
Browse files Browse the repository at this point in the history
  • Loading branch information
Stephen-Gordon committed Mar 28, 2024
1 parent 605381f commit d0d8e1a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
8 changes: 5 additions & 3 deletions src/app/@auth/(.)receive/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,18 @@ import QRCode from 'react-qr-code';
// Redux
import { useSelector } from 'react-redux';
import Qr from '@/app/components/Qr/Qr';
import { DrawerHeader, DrawerTitle } from '@/app/components/ui/drawer';

export default function Page() {
const address = useSelector((state: string) => state.address.value);

return (
<>
<div className='grid'>
<div className='my-4 '>
<p className='my-4 text-center text-xl text-gray-300'>Receive</p>
</div>
<DrawerHeader>
<DrawerTitle>Receive</DrawerTitle>
</DrawerHeader>

<div className='grid justify-center'>
<div className='mt-4 '>
<Qr />
Expand Down
2 changes: 1 addition & 1 deletion src/app/components/Qr/Qr.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ export default function Qr() {
useEffect(() => {
function handleResize() {
const screenWidth = window.innerWidth; // Get the screen width
const tenPercentOfScreenWidth = screenWidth * 0.1; // Calculate 10% of the screen width
const tenPercentOfScreenWidth = screenWidth * 0.3; // Calculate 10% of the screen width
const screenWidthMinusTenPercent = screenWidth - tenPercentOfScreenWidth; // Subtract 10% from the screen width
setWindowWidth(screenWidthMinusTenPercent); // Set the state with the modified screen width
}
Expand Down

0 comments on commit d0d8e1a

Please sign in to comment.