mirror of
https://github.com/phuoc-ng/csslayout.git
synced 2025-08-06 14:16:50 +02:00
Tweak sidebar
This commit is contained in:
@@ -15,9 +15,10 @@ interface ProductProps {
|
||||
|
||||
const Product: React.FC<ProductProps> = ({ product }) => {
|
||||
return (
|
||||
<div className="product">
|
||||
<div className="product" style={{ backgroundColor: product.themeColor }}>
|
||||
<a href={product.url}>
|
||||
<img className="product__logo" src={`/assets/${slug(product.name)}.png`} alt={`${product.name} - ${product.description}`} />
|
||||
<h3 className="product__name">{product.name}</h3>
|
||||
<div className="product__desc">{product.description}</div>
|
||||
</a>
|
||||
</div>
|
||||
|
@@ -4,19 +4,27 @@
|
||||
*/
|
||||
|
||||
.product {
|
||||
border: 1px solid rgba(0, 0, 0, .3);
|
||||
border-radius: 0.5rem;
|
||||
color: #FFF;
|
||||
margin: 1rem 0;
|
||||
overflow: hidden;
|
||||
padding: 1rem;
|
||||
}
|
||||
.product a {
|
||||
color: #FFF;
|
||||
text-align: center;
|
||||
text-decoration: none;
|
||||
}
|
||||
.product__logo {
|
||||
display: flex;
|
||||
height: auto;
|
||||
width: 100%;
|
||||
margin: 0 auto;
|
||||
width: 6rem;
|
||||
}
|
||||
.product__name {
|
||||
font-size: 1.5rem;
|
||||
margin: 1rem;
|
||||
}
|
||||
.product__desc {
|
||||
padding: 0.5rem;
|
||||
text-align: center;
|
||||
}
|
@@ -59,9 +59,8 @@ a {
|
||||
justify-content: center;
|
||||
}
|
||||
.hero__logo img {
|
||||
height: 12rem;
|
||||
object-fit: cover;
|
||||
width: 20rem;
|
||||
width: 16rem;
|
||||
}
|
||||
.hero__heading {
|
||||
color: var(--color-gray-9);
|
||||
@@ -154,13 +153,13 @@ pre {
|
||||
}
|
||||
@media (min-width: 768px) {
|
||||
.sidebar {
|
||||
flex-basis: 10rem;
|
||||
flex-basis: 12rem;
|
||||
margin-left: 1rem;
|
||||
}
|
||||
}
|
||||
@media (min-width: 1024px) {
|
||||
.sidebar {
|
||||
flex-basis: 12rem;
|
||||
flex-basis: 16rem;
|
||||
margin-left: 2rem;
|
||||
}
|
||||
}
|
@@ -43,7 +43,8 @@ const HomePage = () => {
|
||||
<div className="hero">
|
||||
<div className="container">
|
||||
<div className="hero__logo"><img src="/assets/logo.png" alt="CSS Layout" /></div>
|
||||
<h1 className="hero__heading">Popular Layouts & patterns made with CSS</h1>
|
||||
<h1 className="home__heading">CSS Layout</h1>
|
||||
<h2 className="hero__subheading">Popular Layouts & patterns made with CSS</h2>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
@@ -44,9 +44,10 @@
|
||||
}
|
||||
.home__heading {
|
||||
color: var(--color-gray-9);
|
||||
font-size: 4rem;
|
||||
font-size: 3rem;
|
||||
font-weight: 600;
|
||||
margin-bottom: 1rem;
|
||||
margin: 1rem;
|
||||
text-align: center;
|
||||
}
|
||||
.home__explore {
|
||||
background-color: var(--background-color);
|
||||
|
Reference in New Issue
Block a user