mastowall/index.html
Ralf Stockmann 638c216eb4
Update index.html
- Dynamic hashtags via URL
2023-05-17 23:57:40 +02:00

30 lines
1.2 KiB
HTML

<!DOCTYPE html>
<html>
<head>
<title>Mastodon Wall</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css">
<link rel="stylesheet" href="styles.css">
</head>
<body>
<nav class="navbar navbar-light d-flex">
<span class="navbar-brand mb-0 h1" id="hashtag-container">
<!-- hashtags will be inserted here -->
</span>
<span class="navbar-info mb-0 h3">
<span class="hashtag">Mastowall V0.1 - written by ChatGPT4 - Prompting: Ralf Stockmann (rstockm)</span>
</span>
</nav>
<div id="wall" class="row masonry-grid"></div>
<script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/masonry/4.2.2/masonry.pkgd.min.js"></script>
<script src="script.js"></script>
<script>
// insert hashtags into the navbar
let hashtagContainer = document.getElementById('hashtag-container');
hashtagContainer.innerHTML = hashtagsArray.map(hashtag => `<span class="hashtag">#${hashtag}</span>`).join(' &nbsp; ');
</script>
</body>
</html>