Improved post view

This commit is contained in:
Eduard Urbach 2018-04-25 19:12:47 +02:00
parent 3ebd4b0856
commit d331e15363
5 changed files with 10 additions and 8 deletions

View File

@ -53,7 +53,7 @@ import (
"github.com/animenotifier/notify.moe/pages/notifications" "github.com/animenotifier/notify.moe/pages/notifications"
"github.com/animenotifier/notify.moe/pages/paypal" "github.com/animenotifier/notify.moe/pages/paypal"
"github.com/animenotifier/notify.moe/pages/popular" "github.com/animenotifier/notify.moe/pages/popular"
"github.com/animenotifier/notify.moe/pages/posts" "github.com/animenotifier/notify.moe/pages/post"
"github.com/animenotifier/notify.moe/pages/profile" "github.com/animenotifier/notify.moe/pages/profile"
"github.com/animenotifier/notify.moe/pages/profile/profilecharacters" "github.com/animenotifier/notify.moe/pages/profile/profilecharacters"
"github.com/animenotifier/notify.moe/pages/profile/profilequotes" "github.com/animenotifier/notify.moe/pages/profile/profilequotes"
@ -102,7 +102,7 @@ func Configure(app *aero.Application) {
l.Page("/forum", forum.Get) l.Page("/forum", forum.Get)
l.Page("/forum/:tag", forum.Get) l.Page("/forum/:tag", forum.Get)
l.Page("/thread/:id", thread.Get) l.Page("/thread/:id", thread.Get)
l.Page("/post/:id", posts.Get) l.Page("/post/:id", post.Get)
l.Page("/new/thread", newthread.Get) l.Page("/new/thread", newthread.Get)
// User lists // User lists

View File

@ -1,4 +1,4 @@
package posts package post
import ( import (
"net/http" "net/http"

7
pages/post/post.pixy Normal file
View File

@ -0,0 +1,7 @@
component Post(post *arn.Post, user *arn.User)
.thread
.posts
Postable(post.ToPostable(), user, "")
.side-note.mountable
a(href=post.Thread().Link())= post.Thread().Title

View File

@ -1,5 +0,0 @@
component Post(post *arn.Post, user *arn.User)
Postable(post.ToPostable(), user, "")
.side-note
a(href=post.Thread().Link())= post.Thread().Title