CSS Grid - Grid Template Areas
How do I make an css grid - grid template areas?
What is a css grid - grid template areas? How do you make a css grid - grid template areas? This script and codes were developed by Ajay Karwal on 26 December 2022, Monday.
CSS Grid - Grid Template Areas - Script Codes HTML Codes
<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>CSS Grid - Grid Template Areas</title> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/5.0.0/normalize.min.css"> <link rel="stylesheet" href="css/style.css">
</head>
<body> <div class="grid"> <div class="grid-item header">Header</div> <div class="grid-item sidebar">Sidebar</div> <div class="grid-item content">Content</div> <div class="grid-item aside">Aside</div> <div class="grid-item footer">Footer</div>
</div>
<small class="credit">Made with ♥ by <a href="https://twitter.com/ajaykarwal" target="_blank">Ajay Karwal</a></small>
</body>
</html>
CSS Grid - Grid Template Areas - Script Codes CSS Codes
.header { grid-area: h;
}
.sidebar { grid-area: s;
}
.content { grid-area: c;
}
.footer { grid-area: f;
}
.aside { grid-area: a;
}
.grid { display: grid; grid-template-columns: 1fr 3fr 1fr; grid-template-rows: 80px minmax(400px, auto) 50px; grid-gap: 1em; grid-template-areas: "h h h" "s c a" "f f f";
}
.grid-item { display: grid; align-items: center; justify-content: center;
}
body { margin: 2rem;
}
.grid-item { background-color: indianred; color: papayawhip; padding: 1rem; border-radius: 10px; font-size: 1rem; font-weight: bold;
}
.credit { display: block; margin: 20px 0; font-size: 11px; color: #666;
}
.credit a { color: inherit;
}
Developer | Ajay Karwal |
Username | ajaykarwal |
Uploaded | December 26, 2022 |
Rating | 3 |
Size | 2,314 Kb |
Views | 16,192 |
Find the perfect freelance services for your business! Fiverr's mission is to change how the world works together. Fiverr connects businesses with freelancers offering digital services in 500+ categories. Find Developer!
Name | Size |
Palindrome Checker | 2,246 Kb |
Template 1 | 1,987 Kb |
Pen Credit | 1,698 Kb |
Custom animated checkboxes | 2,818 Kb |
How to make the perfect diffused drop shadow | 2,868 Kb |
Background Color Switcher - ReactJS Component | 4,580 Kb |
ToDo List - Vanilla JS | 3,546 Kb |
Skew Test | 1,753 Kb |
React Button variants test | 3,319 Kb |
Find PI to the Nth Digit | 1,516 Kb |
Jasper is the AI Content Generator that helps you and your team break through creative blocks to create amazing, original content 10X faster. Discover all the ways the Jasper AI Content Platform can help streamline your creative workflows. Start For Free!
Name | Username | Size |
Website Concept | Sagoza | 3,104 Kb |
Slick Slider | Wearebold | 5,913 Kb |
Ball Physics | Getsetbro | 3,149 Kb |
RWD Conversion Practice | Jxqr97 | 2,743 Kb |
Image Stack Test SCSS | CalvinMorett | 2,799 Kb |
Knockout Lists | Marinru | 2,531 Kb |
Perforated foil | 0x04 | 2,617 Kb |
Coburg Banks SVG Logo | Mjtweaver | 3,875 Kb |
Sassy Buttons | Elyseholladay | 2,299 Kb |
Particle Motion trajectories | Sniejadlik | 5,899 Kb |
Surf anonymously, prevent hackers from acquiring your IP address, send anonymous email, and encrypt your Internet connection. High speed, ultra secure, and easy to use. Instant setup. Hide Your IP Now!