Skip to content

Commit

Permalink
Merge pull request #3 from YK911/feature-redesign-yk
Browse files Browse the repository at this point in the history
fix paths
  • Loading branch information
YK911 authored Apr 22, 2024
2 parents adf8a74 + b5f4647 commit 500d1eb
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 19 deletions.
10 changes: 5 additions & 5 deletions src/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,18 @@
<link rel="icon" type="image/svg+xml" href="/favicon.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Vanilla App Template</title>
<link rel="stylesheet" href="css/styles.css" />
<link rel="stylesheet" href="./css/styles.css" />
</head>
<body>
<load src="/partials/header.html" icon-path="img/sprite.svg#logo" />
<load src="./partials/header.html" icon-path="img/sprite.svg#logo" />

<main>
<!-- Loads the specified .html file -->
<load src="/partials/vite-promo.html" />
<load src="/partials/badges.html" />
<load src="./partials/vite-promo.html" />
<load src="./partials/badges.html" />
</main>

<load src="/partials/footer.html" />
<load src="./partials/footer.html" />

<script type="module" src="main.js"></script>
</body>
Expand Down
10 changes: 5 additions & 5 deletions src/page-2.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Page 2</title>
<link rel="stylesheet" href="/css/styles.css" />
<link rel="stylesheet" href="./css/styles.css" />
</head>
<body>
<load
src="/partials/header.html"
icon-path="/img/sprite.svg#logo"
src="./partials/header.html"
icon-path="./img/sprite.svg#logo"
highlight-act="active"
/>

Expand All @@ -19,10 +19,10 @@
<h1 class="main-title">
<span class="main-title-gradient">Welcome</span> to page 2
</h1>
<load src="/partials/back-link.html" />
<load src="./partials/back-link.html" />
</div>
</main>

<load src="/partials/footer.html" />
<load src="./partials/footer.html" />
</body>
</html>
10 changes: 5 additions & 5 deletions src/page-3.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Page 3</title>
<link rel="stylesheet" href="/css/styles.css" />
<link rel="stylesheet" href="./css/styles.css" />
</head>
<body>
<load
src="/partials/header.html"
icon-path="/img/sprite.svg#logo"
src="./partials/header.html"
icon-path="./img/sprite.svg#logo"
highlight-curr="active"
/>

Expand All @@ -19,10 +19,10 @@
<h1 class="main-title">
<span class="main-title-gradient">Welcome</span> to page 3
</h1>
<load src="/partials/back-link.html" />
<load src="./partials/back-link.html" />
</div>
</main>

<load src="/partials/footer.html" />
<load src="./partials/footer.html" />
</body>
</html>
2 changes: 1 addition & 1 deletion src/partials/back-link.html
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<a class="back-link" href="/index.html">Go back</a>
<a class="back-link" href="./index.html">Go back</a>
6 changes: 3 additions & 3 deletions src/partials/header.html
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
<header class="header">
<div class="container">
<nav class="nav">
<a class="nav-logo" href="/index.html" aria-label="Site logo">
<a class="nav-logo" href="./index.html" aria-label="Site logo">
<svg class="nav-logo-icon" width="100" height="30">
<use href="{=$icon-path}"></use>
</svg>
</a>
<ul class="nav-list">
<li class="nav-item">
<a class="nav-link {=$highlight-act}" href="/page-2.html">Page 2</a>
<a class="nav-link {=$highlight-act}" href="./page-2.html">Page 2</a>
</li>
<li class="nav-item">
<a class="nav-link {=$highlight-curr}" href="/page-3.html">Page 3</a>
<a class="nav-link {=$highlight-curr}" href="./page-3.html">Page 3</a>
</li>
</ul>
</nav>
Expand Down

0 comments on commit 500d1eb

Please sign in to comment.