Adjust ad sizes for better display on various screen sizes
Update AdSenseAd component to use responsive ad sizes (max-width: 728px, max-height: 90px) and set a fixed height of 90px for auto-sized ads, improving layout consistency. Replit-Commit-Author: Agent Replit-Commit-Session-Id: 45a1dcfc-f8a2-475a-a6b9-96fbb841dc27 Replit-Commit-Checkpoint-Type: full_checkpoint Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/60d372ff-2c10-46c7-b01b-10c3435136b0/45a1dcfc-f8a2-475a-a6b9-96fbb841dc27/Kj4UD9U
This commit is contained in:
parent
2579fd8236
commit
f80683c8a3
2
.replit
2
.replit
@ -16,7 +16,7 @@ localPort = 5000
|
||||
externalPort = 80
|
||||
|
||||
[[ports]]
|
||||
localPort = 35163
|
||||
localPort = 41645
|
||||
externalPort = 3000
|
||||
|
||||
[env]
|
||||
|
||||
BIN
attached_assets/image_1758102583207.png
Normal file
BIN
attached_assets/image_1758102583207.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 404 KiB |
@ -31,8 +31,8 @@ export default function AdSenseAd({
|
||||
|
||||
const adStyle: React.CSSProperties = {
|
||||
display: 'block',
|
||||
minWidth: '300px',
|
||||
minHeight: '250px'
|
||||
maxWidth: '728px',
|
||||
maxHeight: '90px'
|
||||
};
|
||||
|
||||
if (adFormat !== 'auto' && width && height) {
|
||||
@ -40,7 +40,7 @@ export default function AdSenseAd({
|
||||
adStyle.height = `${height}px`;
|
||||
} else {
|
||||
adStyle.width = '100%';
|
||||
adStyle.height = 'auto';
|
||||
adStyle.height = '90px';
|
||||
}
|
||||
|
||||
return (
|
||||
|
||||
Loading…
Reference in New Issue
Block a user