#Background linear gradient is not fully occupied
55 messages ยท Page 1 of 1 (latest)
I tried to use background-image: linear-gradient(to right, #672280, #A626D3)
still aint working
@sand pelican
that image
it seems you have placed the image outside of this background image container
talking about logo
can i see the code
import React from "react";
export default function Header() {
return (
<header className="header">
<img className="h_image" src = "../images/trollface.png" alt = "troll" />
<h2 className="h_title">Meme Generator</h2>
<h4 className="h_project"> React Course - Project 3</h4>
</header>
)
}
sending code like this is not good is there any way to send code properly so that it can be readable
screenshots are good
what are the styles for them?
.header {
display: flex;
height: 65px;
align-items: center;
color: white;
background: linear-gradient(90deg, #672280 1.18%, #A626D3 100%);
}
<header className='header'>
<div>
<img src='your_image_path' />
<h1>Meme Generator<h1>
</div>
<p>React Course-Project 3</p>
</header>
.header{
display:flex;
justify-content: space-between;
}
this should work
add the background now
your background color should work in your code as well, it seems you may have done something with other class styles , like maybe h_image, your logo is placed outside of the header container! but in your code the image is inside the header container
.h_image {
height: 100%;
margin-right: 6px;
}
.h_title {
font-size: 22px;
margin-right: auto;
}
.h_project {
font-size: 15px;
font-weight: 600;
}
these are other styles
actually i got that image from internet not from figma file
did your whole header container got the background color now
try re downloading it
is it from the figma?
yeah
sometimes its coming black and sometimes white
weird
@Sai can you set it as normal background color like red and see if its being applied to whole container
now its fine bruh all set now actually i tried to download from the image itself in figma but now i downloaded from file its good now
also add some padding in .header
from all sides, so there should be breating room for content
yeah i remember now thnx for helping out all time ๐
no problem! ๐
can u go through this figma link see that button get a new meme same side u can see little image how can i get it
its looking like this
perfect
@sand pelican is there anything like that if i click on the link it should open project
what you want to do
you can add a anchor tag and set the href to project url
i mean if i want to open project without vs code is there anything like that like domain or something
netlify
oh yea you need to host your site on Netlify
ohh k alr