First working version

This commit is contained in:
Semubico 2025-07-03 15:16:21 +03:00
commit 8bc7556cf8
6 changed files with 246 additions and 0 deletions

80
assets/index.html Normal file
View file

@ -0,0 +1,80 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>MyReadingRSS</title>
<style>
body {
font-family: Arial, sans-serif;
margin: 0;
padding: 20px;
background-color: #f4f4f4;
color: #333;
}
h1 {
text-align: center;
}
.tree {
list-style-type: none;
padding-left: 20px;
}
.folder {
cursor: pointer;
margin: 5px 0;
font-weight: bold;
}
.folder.show::before {
content: "▼";
}
.folder::before {
content: "▶";
}
.feed {
display: none; /* Hidden by default */
margin: 5px 0 10px 20px;
padding: 10px;
background: white;
border-radius: 5px;
box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}
.feed.show {
display: block;
}
.feed-item {
border-bottom: 1px solid #eaeaea;
padding: 5px 0 0 10px;
}
.feed-item:last-child {
border-bottom: none;
}
.feed-item h2 {
margin: 0;
font-size: 1.2em;
}
.feed-item a {
text-decoration: none;
color: #0073e6;
}
.feed-item a:hover {
text-decoration: underline;
}
</style>
</head>
<body>
<h1>RSS feeds I read</h1>
<ul class="tree" onlick="toggleFeed()">
{{{content}}}
</ul>
<script defer>
window.addEventListener('click', (e) => {
if (!e.srcElement.classList.contains("folder")) return true;
e.srcElement.classList.toggle('show');
e.srcElement.nextElementSibling.classList.toggle('show');
});
</script>
</body>
</html>

11
assets/item.html Normal file
View file

@ -0,0 +1,11 @@
<div class="folder">{{title.content}}</div>
<div id="subfeed1" class="feed">
{{#each entries}}
<div class="feed-item">
<h2><a href="{{this.id}}">{{this.title.content}}</a></h2>
<p>By: {{this.authors.0.name}}</p>
<p>Published on: <time datetime="{{this.updated}}">{{this.updated}}</time></p>
<p>{{summary.content}}</p>
</div>
{{/each}}
</div>