-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
albios
committed
May 3, 2023
1 parent
24d44a4
commit 7f88822
Showing
3 changed files
with
52 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
<!DOCTYPE html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="UTF-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | ||
<title>Gitloaf</title> | ||
<link rel="stylesheet" href="styles.css"> | ||
<link href="https://fonts.googleapis.com/css?family=Roboto|Roboto+Mono&display=swap" rel="stylesheet"> | ||
<link rel="preconnect" href="https://fonts.googleapis.com"> | ||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin> | ||
<link href="https://fonts.googleapis.com/css2?family=Barlow:wght@800&family=Cabin:wght@500&family=Montserrat:wght@600&family=Noto+Sans:wght@500&family=Roboto:wght@500&display=swap" rel="stylesheet"> | ||
</head> | ||
<body> | ||
<div class="main-container"> | ||
<center> | ||
<h1 class="title"> <b>Gitloaf</b> version:</h1> | ||
<p><b>BETA 1.0.1</b></p> | ||
<p>- Changed Cache time from 5 to 10 minutes</p> | ||
<p>- Fixed jsDelivr/Cloudflare CDN</p> | ||
<br> | ||
<p><b>BETA 1.0.0</b></p> | ||
<p>RELEASE!!!</p> | ||
</center> | ||
<script> | ||
(function () { | ||
const urlPath = window.location.pathname; | ||
const pathSegments = urlPath.split('/').filter(segment => segment.length > 0); | ||
const [, user, repo, branch] = pathSegments; | ||
const cdnPrefix = `/cdn/${user}/${repo}/${branch}`; | ||
|
||
const scriptTags = document.querySelectorAll('script[src^="/js/"]'); | ||
scriptTags.forEach((script) => { | ||
const src = script.getAttribute('src'); | ||
script.setAttribute('src', cdnPrefix + src); | ||
}); | ||
|
||
const styleTags = document.querySelectorAll('link[href^="/css/"][rel="stylesheet"]'); | ||
styleTags.forEach((style) => { | ||
const href = style.getAttribute('href'); | ||
style.setAttribute('href', cdnPrefix + href); | ||
}); | ||
})(); | ||
</script> | ||
|
||
<script src="scripts.js"></script> | ||
</body> | ||
</html> |