aboutsummaryrefslogtreecommitdiffstats
path: root/AGENTS.md
diff options
context:
space:
mode:
authorgrm <grm@eyesin.space>2026-09-14 22:58:08 +0300
committergrm <grm@eyesin.space>2026-09-14 22:58:08 +0300
commit5f9fc2a8667a9438b6336d75026f9a455fc9c4ce (patch)
tree8fa0009b2487e35219bfdbb34f9802704007076e /AGENTS.md
parente14a4250efb828262347f5a4bbc4067cd71d885f (diff)
downloadblogspace-5f9fc2a8667a9438b6336d75026f9a455fc9c4ce.tar.gz
blogspace-5f9fc2a8667a9438b6336d75026f9a455fc9c4ce.tar.bz2
blogspace-5f9fc2a8667a9438b6336d75026f9a455fc9c4ce.zip
Let the blogger set a post's date, when writing it and afterwards
The post date is posts.created_at: it already drives ordering, the archive, the feed and the displayed dates, so making it editable is a form field rather than a new column. The datetime-local input degrades to a text box on old browsers, so the server also accepts the value typed by hand; blank keeps the current date. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Sd8UPWrvyYCLj97JexNw3A
Diffstat (limited to 'AGENTS.md')
-rw-r--r--AGENTS.md7
1 files changed, 7 insertions, 0 deletions
diff --git a/AGENTS.md b/AGENTS.md
index 97798dc..09d9b7d 100644
--- a/AGENTS.md
+++ b/AGENTS.md
@@ -218,6 +218,13 @@ internal/web/ server.go (host router, middleware, render helpers)
Adding a language: an entry in `i18n.languages`, a catalog file, a month
table in `monthTables` (nominative, in-date and short forms), and the test
gets a copy per language if its rules differ.
+- **Post date** is `posts.created_at` — there is no separate "published
+ at": the blogger sets it on the post form (`posted_at`, a
+ `datetime-local` input that degrades to a text box; `parsePostDate`
+ accepts `YYYY-MM-DD[THH:MM]`), for new and existing posts alike, and it
+ drives ordering, the archive, the feed and the displayed dates. Blank keeps
+ the current value; a new post starts at now. Times are in the server's
+ zone, which is also the one dates are rendered in.
- **Slugs**: auto-generated from the title; on collision generated slugs
get `-2`, `-3`…, user-typed slugs return a 409 with a message.
- **Errors**: `store.ErrNotFound` / `store.ErrConflict` are the sentinels