Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 16 additions & 8 deletions Wireframe/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,23 +10,31 @@
<header>
<h1>Wireframe</h1>
<p>
This is the default, provided code and no changes have been made yet.
This is a webpage developed by Divine.
</p>
</header>
<main>
<article>
<img src="placeholder.svg" alt="" />
<h2>Title</h2>
<article class = "Article-One">
<h2>Article One: The Purpose of a README file</h2>
<p>
Lorem ipsum dolor sit amet consectetur adipisicing elit. Quisquam,
voluptates. Quisquam, voluptates.
It displays an overview to the repository and provides instructions on how to use.
</p>
<a href="">Read more</a>
<a href="#">Read more</a>
</article>
<article class = "Article-Two">
<h2>Article Two: The Purpose of a Wireframe</h2>
<p>The wireframe gives the structural layout of a page - it defines where elements (buttons, images, etc.) go</p>
<a href="#">Read more</a>
</article>
<article class = "Article-Three">
<h2>Article Three: What are branches in Git?</h2>
<p>A branch is like a separate workspace where you can make changes and try new ideas without affecting the main project.</p>
<a href = "#"> Read More</a>
</article>
</main>
<footer>
<p>
This is the default, provided code and no changes have been made yet.
This is the changed code
</p>
</footer>
</body>
Expand Down
49 changes: 42 additions & 7 deletions Wireframe/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -24,23 +24,27 @@ As well as useful links to learn more */
--line: 1px solid;
--container: 1280px;
}

/* ====== Base Elements ======
General rules for basic HTML elements in any context */
body {
background: var(--paper);
color: var(--ink);
font: var(--font);
}

a {
padding: var(--space);
border: var(--line);
max-width: fit-content;
}

img,
svg {
width: 100%;
object-fit: cover;
}

/* ====== Site Layout ======
Setting the overall rules for page regions
https://www.w3.org/WAI/tutorials/page-structure/regions/
Expand All @@ -49,11 +53,13 @@ main {
max-width: var(--container);
margin: 0 auto calc(var(--space) * 4) auto;
}

footer {
position: fixed;
bottom: 0;
text-align: center;
}

/* ====== Articles Grid Layout ====
Setting the rules for how articles are placed in the main element.
Inspect this in Devtools and click the "grid" button in the Elements view
Expand All @@ -65,10 +71,12 @@ main {
display: grid;
grid-template-columns: 1fr 1fr;
gap: var(--space);
> *:first-child {

>*:first-child {
grid-column: span 2;
}
}

/* ====== Article Layout ======
Setting the rules for how elements are placed in the article.
Now laying out just the INSIDE of the repeated card/article design.
Expand All @@ -80,10 +88,37 @@ article {
text-align: left;
display: grid;
grid-template-columns: var(--space) 1fr var(--space);
> * {
grid-column: 2/3;
}
> img {
grid-column: span 3;
}
color: white;
background-size: cover;
background-position: center;
position: relative;
}

article::before {
content: "";
position: absolute;
inset: 0;
background: rgba(0, 0, 0, 0.6);
}

article > * {
grid-column: 2 / 3;
position: relative;
}

article > img {
grid-column: span 3;
}


.Article-One {
background-image: url("https://images.unsplash.com/photo-1555066931-4365d14bab8c?q=80&w=870&auto=format&fit=crop&ixlib=rb-4.1.0&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D");
}

.Article-Two {
background-image: url("https://images.unsplash.com/photo-1607706189992-eae578626c86?q=80&w=870&auto=format&fit=crop&ixlib=rb-4.1.0&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D");
}

.Article-Three {
background-image: url("https://images.unsplash.com/photo-1518773553398-650c184e0bb3?q=80&w=870&auto=format&fit=crop&ixlib=rb-4.1.0&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D");
}