- **refactor(main):** migrate static HTML to React components
- **feat(ui):** implement `AcknowledgeButton` component for acknowledging images - **feat(stats):** add dashboard stats for total images, pending updates, and acknowledged status - **chore(deps):** introduce `bun` dependency management and add required libraries - **style(ui):** enhance UI with Tailwind-based components and modularity improvements - **chore:** add drag-and-drop tag assignment using `@dnd-kit/core`
This commit is contained in:
@@ -13,6 +13,10 @@ import (
|
||||
)
|
||||
|
||||
func main() {
|
||||
if err := diun.InitDB("./diun.db"); err != nil {
|
||||
log.Fatalf("InitDB: %v", err)
|
||||
}
|
||||
|
||||
port := os.Getenv("PORT")
|
||||
if port == "" {
|
||||
port = "8080"
|
||||
@@ -20,8 +24,12 @@ func main() {
|
||||
|
||||
mux := http.NewServeMux()
|
||||
mux.HandleFunc("/webhook", diun.WebhookHandler)
|
||||
mux.HandleFunc("/api/updates/", diun.DismissHandler)
|
||||
mux.HandleFunc("/api/updates", diun.UpdatesHandler)
|
||||
mux.Handle("/", http.FileServer(http.Dir("./static")))
|
||||
mux.HandleFunc("/api/tags", diun.TagsHandler)
|
||||
mux.HandleFunc("/api/tags/", diun.TagByIDHandler)
|
||||
mux.HandleFunc("/api/tag-assignments", diun.TagAssignmentHandler)
|
||||
mux.Handle("/", http.FileServer(http.Dir("./frontend/dist")))
|
||||
|
||||
srv := &http.Server{
|
||||
Addr: ":" + port,
|
||||
|
||||
Reference in New Issue
Block a user