Skip to content

Commit

Permalink
🎨 Improved layoutGenerator function
Browse files Browse the repository at this point in the history
  • Loading branch information
migueravila committed Feb 8, 2022
1 parent fa9be44 commit e32578e
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 6 deletions.
15 changes: 13 additions & 2 deletions app.css
Original file line number Diff line number Diff line change
Expand Up @@ -205,14 +205,24 @@ body {
color: var(--fg);
}

.linksBlockLeft {
.linksBlock {
grid-row: 3 / span 2;
grid-column: 1 / span 4;
display: grid;
grid-template-columns: repeat(4, 1fr);
grid-template-rows: repeat(2, 1fr);
grid-gap: 30px;
}

.linksBlockLeft {
grid-row: 1 / span 2;
grid-column: 1 / span 2;
display: grid;
grid-template-columns: repeat(3, 1fr);
grid-template-rows: repeat(2, 1fr);
grid-gap: 30px;
padding: 20px;

}

.button {
Expand Down Expand Up @@ -260,13 +270,14 @@ body {
}

.linksBlockRight {
grid-row: 3 / span 2;
grid-row: 1 / span 2;
grid-column: 3 / span 2;
display: grid;
grid-template-columns: repeat(2, 1fr);
grid-template-rows: repeat(2, 1fr);
grid-gap: 30px;
padding: 0.3rem;

}

.list {
Expand Down
3 changes: 1 addition & 2 deletions assets/js/layout.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,7 @@ const generateLayout = () => {
</div>
<div class="linksBlockRight" id="linksBlockRight">
<div class="card list list__1" id="list_1"></div>
<div class="card list list__2" id="list_2"></div>
</div>
`;
let listLayout = `
Expand Down
4 changes: 2 additions & 2 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,8 @@
<script src="assets/js/greeting.js"></script>
<script src="assets/js/weather.js"></script>

<script src="assets/js/buttons.js"></script>
<script src="assets/js/lists.js"></script>
<!-- <script src="assets/js/buttons.js"></script>
<script src="assets/js/lists.js"></script> -->

<!-- Icons -->
<script>
Expand Down

0 comments on commit e32578e

Please sign in to comment.