From e44397dcbb9454f89b8263738d5ccf1e20a12074 Mon Sep 17 00:00:00 2001 From: Vikas Kushwaha Date: Tue, 11 Feb 2025 17:50:21 +0530 Subject: Substituted 'article' with 'project' in filenames --- .../templates/projects/partials/comments-card.tmpl | 25 +++++++++++++ .../templates/projects/partials/comments-form.tmpl | 18 ++++++++++ .../projects/partials/comments-wrapper.tmpl | 26 ++++++++++++++ .../projects/partials/detail-post-meta.tmpl | 42 ++++++++++++++++++++++ .../projects/partials/favorite-button.tmpl | 15 ++++++++ .../templates/projects/partials/follow-button.tmpl | 17 +++++++++ 6 files changed, 143 insertions(+) create mode 100644 cmd/web/templates/projects/partials/comments-card.tmpl create mode 100644 cmd/web/templates/projects/partials/comments-form.tmpl create mode 100644 cmd/web/templates/projects/partials/comments-wrapper.tmpl create mode 100644 cmd/web/templates/projects/partials/detail-post-meta.tmpl create mode 100644 cmd/web/templates/projects/partials/favorite-button.tmpl create mode 100644 cmd/web/templates/projects/partials/follow-button.tmpl (limited to 'cmd/web/templates/projects/partials') diff --git a/cmd/web/templates/projects/partials/comments-card.tmpl b/cmd/web/templates/projects/partials/comments-card.tmpl new file mode 100644 index 0000000..1e6062a --- /dev/null +++ b/cmd/web/templates/projects/partials/comments-card.tmpl @@ -0,0 +1,25 @@ +
+
+

{{ .Comment.Body }}

+
+ +
\ No newline at end of file diff --git a/cmd/web/templates/projects/partials/comments-form.tmpl b/cmd/web/templates/projects/partials/comments-form.tmpl new file mode 100644 index 0000000..c88cac6 --- /dev/null +++ b/cmd/web/templates/projects/partials/comments-form.tmpl @@ -0,0 +1,18 @@ +
+
+ +
+ +
\ No newline at end of file diff --git a/cmd/web/templates/projects/partials/comments-wrapper.tmpl b/cmd/web/templates/projects/partials/comments-wrapper.tmpl new file mode 100644 index 0000000..2f401de --- /dev/null +++ b/cmd/web/templates/projects/partials/comments-wrapper.tmpl @@ -0,0 +1,26 @@ +
+ {{ range $comment := .Project.Comments }} + {{ template "projects/partials/comments-card" Dict "Comment" $comment }} + {{ end }} +
+ +{{ if .IsAuthenticated }} +
+ + {{ template "projects/partials/comments-form" . }} +{{ else }} +
+ + Sign in + + or + + sign up + + to add comments on this project. +
+{{ end }} \ No newline at end of file diff --git a/cmd/web/templates/projects/partials/detail-post-meta.tmpl b/cmd/web/templates/projects/partials/detail-post-meta.tmpl new file mode 100644 index 0000000..eb957b4 --- /dev/null +++ b/cmd/web/templates/projects/partials/detail-post-meta.tmpl @@ -0,0 +1,42 @@ +
+ +
+ + {{ .Project.User.Name }} + + {{ .Project.GetFormattedCreatedAt }} +
+ + {{ if .IsSelf }} + + + + + + {{ else }} + + {{ template "projects/partials/follow-button" . }} + + {{ template "projects/partials/favorite-button" . }} + + {{ end }} +
\ No newline at end of file diff --git a/cmd/web/templates/projects/partials/favorite-button.tmpl b/cmd/web/templates/projects/partials/favorite-button.tmpl new file mode 100644 index 0000000..f72a320 --- /dev/null +++ b/cmd/web/templates/projects/partials/favorite-button.tmpl @@ -0,0 +1,15 @@ + \ No newline at end of file diff --git a/cmd/web/templates/projects/partials/follow-button.tmpl b/cmd/web/templates/projects/partials/follow-button.tmpl new file mode 100644 index 0000000..73cd023 --- /dev/null +++ b/cmd/web/templates/projects/partials/follow-button.tmpl @@ -0,0 +1,17 @@ + \ No newline at end of file -- cgit v1.2.3