mirror of
https://github.com/snowykami/neo-blog.git
synced 2025-09-05 16:56:22 +00:00
⚡️ feat: add main page layout with navigation and footer
feat: create random labels page feat: implement login page with OpenID Connect support feat: add Gravatar component for user avatars feat: create Navbar component with navigation menu chore: create Sidebar component placeholder feat: implement login form with OIDC and email/password options feat: add reusable button component feat: create card component for structured content display feat: implement input component for forms feat: create label component for form labels feat: add navigation menu component for site navigation chore: add configuration file for site metadata feat: implement device context for responsive design feat: add utility functions for class name management feat: define OIDC configuration model feat: define base response model for API responses feat: define user model for user data feat: implement i18n for internationalization support feat: add English and Chinese translations for login chore: create index for locale resources chore: add blog home view placeholder
This commit is contained in:
@ -8,5 +8,6 @@ type AdminOidcConfigDto struct {
|
||||
DisplayName string `json:"display_name"`
|
||||
Icon string `json:"icon"`
|
||||
OidcDiscoveryUrl string `json:"oidc_discovery_url"`
|
||||
Type string `json:"type"` // oauth2 or misskey
|
||||
Enabled bool `json:"enabled"`
|
||||
}
|
||||
|
@ -1,11 +1,16 @@
|
||||
package dto
|
||||
|
||||
type PostDto struct {
|
||||
UserID uint `json:"user_id"` // 发布者的用户ID
|
||||
Title string `json:"title"` // 帖子标题
|
||||
Content string `json:"content"`
|
||||
Labels []LabelDto `json:"labels"` // 关联的标签
|
||||
IsPrivate bool `json:"is_private"` // 是否为私密帖子
|
||||
ID uint `json:"id"` // 帖子ID
|
||||
UserID uint `json:"user_id"` // 发布者的用户ID
|
||||
Title string `json:"title"` // 帖子标题
|
||||
Content string `json:"content"`
|
||||
Labels []LabelDto `json:"labels"` // 关联的标签
|
||||
IsPrivate bool `json:"is_private"` // 是否为私密帖子
|
||||
LikeCount uint64 `json:"like_count"` // 点赞数
|
||||
CommentCount uint64 `json:"comment_count"` // 评论数
|
||||
ViewCount uint64 `json:"view_count"` // 浏览数
|
||||
Heat uint64 `json:"heat"` // 热度
|
||||
}
|
||||
|
||||
type CreateOrUpdatePostReq struct {
|
||||
@ -14,3 +19,18 @@ type CreateOrUpdatePostReq struct {
|
||||
IsPrivate bool `json:"is_private"`
|
||||
Labels []uint `json:"labels"` // 标签ID列表
|
||||
}
|
||||
|
||||
type ListPostReq struct {
|
||||
Keywords []string `json:"keywords"` // 关键词列表
|
||||
OrderedBy string `json:"ordered_by"` // 排序方式
|
||||
Page uint64 `json:"page"` // 页码
|
||||
Size uint64 `json:"size"`
|
||||
Reverse bool `json:"reverse"`
|
||||
}
|
||||
|
||||
type ListPostResp struct {
|
||||
Posts []PostDto `json:"posts"`
|
||||
Total uint64 `json:"total"` // 总数
|
||||
OrderedBy string `json:"ordered_by"` // 排序方式
|
||||
Reverse bool `json:"reverse"`
|
||||
}
|
||||
|
Reference in New Issue
Block a user