Skip to content

Commit

Permalink
Merge pull request #5 from ghcloudai/dev/xiaoli
Browse files Browse the repository at this point in the history
fixed the layout code
  • Loading branch information
xiaoliwe authored Jan 31, 2024
2 parents cf47e12 + 30e41c0 commit 506636b
Show file tree
Hide file tree
Showing 2 changed files with 64 additions and 18 deletions.
59 changes: 44 additions & 15 deletions _assets/main.css
Original file line number Diff line number Diff line change
@@ -1,16 +1,45 @@
/* _assets/main.css */
/* Your styles go here */
/* main.css */
body {
font-family: Arial, sans-serif;
margin: 0;
padding: 0;
}

header {
background-color: #333;
color: #fff;
padding: 10px;
}

nav ul {
list-style: none;
padding: 0;
margin: 0;
}

nav ul li {
display: inline;
margin-right: 10px;
}

.container {
display: flex;
}

.sidebar {
background-color: #f4f4f4;
padding: 20px;
width: 200px;
}

main {
flex: 1;
padding: 20px;
}
display: flex;
}

.sidebar {
background-color: #f4f4f4;
padding: 20px;
width: 200px;
}

main {
flex: 1;
padding: 20px;
}

footer {
background-color: #333;
color: #fff;
text-align: center;
padding: 10px;
}
23 changes: 20 additions & 3 deletions _layouts/default.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,13 @@
</head>
<body>
<header>
<!-- Your header content goes here -->
<nav>
<ul>
<li><a href="#section1">Section 1</a></li>
<li><a href="#section2">Section 2</a></li>
<li><a href="#section3">Section 3</a></li>
</ul>
</nav>
</header>

<div class="container">
Expand All @@ -20,12 +26,23 @@
</nav>

<main>
{{ content }}
<section id="section1">
<h2>Section 1</h2>
<p>This is the content of section 1.</p>
</section>
<section id="section2">
<h2>Section 2</h2>
<p>This is the content of section 2.</p>
</section>
<section id="section3">
<h2>Section 3</h2>
<p>This is the content of section 3.</p>
</section>
</main>
</div>

<footer>
<!-- Your footer content goes here -->
<p>Footer content goes here</p>
</footer>
</body>
</html>

0 comments on commit 506636b

Please sign in to comment.