diff options
| author | Samuel Johnson <[email protected]> | 2025-11-26 00:58:34 -0500 |
|---|---|---|
| committer | Samuel Johnson <[email protected]> | 2025-11-26 00:58:34 -0500 |
| commit | c72dfab37fd6f0d739ea70d42779b2a8c85e9915 (patch) | |
| tree | 365fd790550a395daa762f746d6d82b2d1cfbd00 /ui | |
| parent | 350170e0f2a2d26a79924d24b32468057719cf60 (diff) | |
Add Youtube RSS parser
Diffstat (limited to 'ui')
| -rw-r--r-- | ui/html/base.tmpl.html | 1 | ||||
| -rw-r--r-- | ui/html/pages/feed.tmpl.html | 15 | ||||
| -rw-r--r-- | ui/html/pages/feed_index.tmpl.html | 37 |
3 files changed, 53 insertions, 0 deletions
diff --git a/ui/html/base.tmpl.html b/ui/html/base.tmpl.html index 628994e..5d69616 100644 --- a/ui/html/base.tmpl.html +++ b/ui/html/base.tmpl.html @@ -22,6 +22,7 @@ <a href="https://git.paterissa.net" class="nav_tag">Git</a> <a href="https://starless.paterissa.net" class="nav_tag">Starless</a> <a href="https://charts.paterissa.net" class="nav_tag">Parliament Builder</a> + <a href="/feeds" class="nav_tag">Feeds</a> </nav> </header> <hr> diff --git a/ui/html/pages/feed.tmpl.html b/ui/html/pages/feed.tmpl.html new file mode 100644 index 0000000..83332f2 --- /dev/null +++ b/ui/html/pages/feed.tmpl.html @@ -0,0 +1,15 @@ +{{define "title"}}{{.Feed.Name}}{{end}} +{{define "description"}}"Recent videos from {{.Feed.Name}}"{{end}} + +{{define "main"}} + {{range .Videos}} + <div class="card"> + <div class="header"> + <h4><b>{{.Title}} - {{.Published}}</b></h4> + <iframe class="video" src="{{.Link}}"></iframe> + </div> + <p>{{.Description}}</p> + </div> + {{end}} +{{end}} + diff --git a/ui/html/pages/feed_index.tmpl.html b/ui/html/pages/feed_index.tmpl.html new file mode 100644 index 0000000..59b37d4 --- /dev/null +++ b/ui/html/pages/feed_index.tmpl.html @@ -0,0 +1,37 @@ +{{define "title"}}RSS Feeds{{end}} +{{define "description"}}"alternative to social media platforms"{{end}} + +{{define "main"}} + <div class="flex_between"> + <div class="topline"> + <h2>Feeds</h2> + <p>Alternative to social media platforms</p> + </div> + <div class="spacer"></div> + {{if .IsAuth}} + <a href="/logout" class="nav_tag right">Logout</a> + {{else}} + <a href="/login" class="nav_tag right">Login</a> + {{end}} + </div> + {{if .IsAuth}} + <div class="card"> + <form class="url_form center" action="/feeds/new" method="POST"> + <label for="name">Channel Name:</label> + <input type="text" id="name" name="name"> + <label for="url">URL:</label> + <input type="text" id="url" name="url"> + <div class="right"> + <input type="submit" value="Submit"> + </div> + </form> + </div> + {{end}} + {{range .Rows}} + <div class="card"> + <div class="header"> + <h4><a href="/feed?id={{.Id}}">{{.Name}} - added by {{.User}}</a></h4> + </div> + </div> + {{end}} +{{end}} |
