-
Notifications
You must be signed in to change notification settings - Fork 0
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
shane0
committed
Dec 28, 2024
1 parent
58cb22a
commit 7cbdd40
Showing
3 changed files
with
230 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
<!DOCTYPE html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="UTF-8" /> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> | ||
<title>Text Loop with Fade</title> | ||
<style> | ||
body { | ||
font-family: Arial, sans-serif; | ||
display: flex; | ||
justify-content: center; | ||
align-items: center; | ||
height: 100vh; | ||
margin: 0; | ||
background-color: black; /* Changed to black */ | ||
color: white; /* Text color changed to white for contrast */ | ||
} | ||
|
||
.fade-text { | ||
font-size: 24px; | ||
text-align: center; | ||
opacity: 0; | ||
transition: opacity 1s ease-in-out; | ||
position: absolute; | ||
} | ||
|
||
a { | ||
color: #00aaff; /* Lighter blue for better visibility on dark background */ | ||
text-decoration: none; | ||
} | ||
|
||
a:hover { | ||
text-decoration: underline; | ||
} | ||
</style> | ||
</head> | ||
<body> | ||
<div id="text-container"></div> | ||
|
||
<script> | ||
const texts = [ | ||
"coming soon...", | ||
"all the meditions...", | ||
"create your own page like this...", | ||
"memorization apps...", | ||
'<a href="https://shanenull.com/buddhism/2025/heart_sutra/" target="_blank">heart sutra</a>', | ||
'<a href="https://shanenull.com/buddhism/2025/diamond_sutra/" target="_blank">diamond sutra</a>', | ||
'<a href="https://shanenull.com/buddhism/2025/prajnaparamita/" target="_blank">prajna paramita</a>', | ||
]; | ||
|
||
let currentIndex = 0; | ||
|
||
function fadeText() { | ||
const container = document.getElementById("text-container"); | ||
const textElement = document.createElement("div"); | ||
textElement.classList.add("fade-text"); | ||
textElement.innerHTML = texts[currentIndex]; | ||
|
||
container.innerHTML = ""; // Clear the previous text | ||
container.appendChild(textElement); | ||
|
||
setTimeout(() => { | ||
textElement.style.opacity = 1; | ||
}, 50); // Give it a small delay to apply the fade-in | ||
|
||
setTimeout(() => { | ||
textElement.style.opacity = 0; | ||
}, 3000); // Fade out after 3 seconds | ||
|
||
currentIndex = (currentIndex + 1) % texts.length; // Loop through the text array | ||
} | ||
|
||
setInterval(fadeText, 4000); // Change text every 4 seconds | ||
|
||
// Initial call to show the first text | ||
fadeText(); | ||
</script> | ||
</body> | ||
</html> |
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,148 @@ | ||
<!DOCTYPE html> | ||
<html lang="en"> | ||
|
||
<head> | ||
<meta charset="UTF-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | ||
<title>vim online</title> | ||
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet"> | ||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.65.9/codemirror.min.css"> | ||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.65.9/theme/dracula.min.css"> | ||
<style> | ||
body { | ||
background-color: black; | ||
color: green; | ||
} | ||
|
||
#editor-container { | ||
box-shadow: 0 0 10px rgba(0, 0, 0, 0.5); | ||
} | ||
|
||
.CodeMirror { | ||
height: 100%; | ||
width: 100%; | ||
font-size: 1.1rem; | ||
} | ||
</style> | ||
</head> | ||
|
||
<body> | ||
<!-- Navbar --> | ||
<nav class="navbar navbar-expand-lg navbar-dark bg-dark"> | ||
<div class="container-fluid"> | ||
<a class="navbar-brand" href="#">vim online</a> | ||
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav" | ||
aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation"> | ||
<span class="navbar-toggler-icon"></span> | ||
</button> | ||
<div class="collapse navbar-collapse" id="navbarNav"> | ||
<ul class="navbar-nav"> | ||
<li class="nav-item"> | ||
<a class="nav-link active" href="https://shanenull.com/buddhism/2025/">Home</a> | ||
</li> | ||
</div> | ||
</div> | ||
</nav> | ||
|
||
<!-- Grid Layout --> | ||
<div class="container"> | ||
<div class="row"> | ||
<div class="col-9"> | ||
|
||
<h1>vim editor</h1> | ||
<div id="editor-container"> | ||
<textarea id="editor"> | ||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
</textarea> | ||
</div> | ||
</div> | ||
|
||
<div class="col-3"> | ||
<h1>notes</h1> | ||
<div class="card bg-light text-dark"> | ||
<div class="card-body"> | ||
next | ||
</div> | ||
</div> | ||
<p></p> | ||
<div class="card bg-dark text-warning"> | ||
<div class="card-body"> | ||
heart sutra | ||
</div> | ||
</div> | ||
<p></p> | ||
<div class="card bg-success text-warning"> | ||
<div class="card-body"> | ||
diamond sutra | ||
</div> | ||
</div> | ||
<p></p> | ||
<div class="card bg-dark text-warning"> | ||
<div class="card-body"> | ||
prajnaparamita | ||
</div> | ||
</div> | ||
<p></p> | ||
<div class="card bg-success text-warning"> | ||
<div class="card-body"> | ||
mind ground | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
|
||
</div> | ||
|
||
</div> | ||
|
||
<!-- Footer --> | ||
|
||
<footer class="bg-dark text-white text-center py-3 mt-4 flex-shrink-0"> | ||
<p>© 2024 <a href="https://www.vim.org/">learn more at vim.org</a> | ||
</p> | ||
</footer> | ||
|
||
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/js/bootstrap.bundle.min.js"></script> | ||
<!-- CodeMirror JS --> | ||
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.65.9/codemirror.min.js"></script> | ||
<!-- Keymap for Vim --> | ||
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.65.9/keymap/vim.min.js"></script> | ||
<!-- JavaScript Mode --> | ||
<script src="https://cdnjs.cloudflare.com/ajax/libs/codemirror/5.65.9/mode/javascript/javascript.min.js"></script> | ||
|
||
<script> | ||
// Initialize CodeMirror | ||
const editor = CodeMirror.fromTextArea(document.getElementById("editor"), { | ||
lineNumbers: true, | ||
mode: "markdown", | ||
theme: "dracula", | ||
keyMap: "vim", | ||
lineWrapping: true | ||
}); | ||
</script> | ||
</body> | ||
|
||
</html> |
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