Hide draft articles from the front page and mark drafts when viewed directly #140
Loading…
Reference in a new issue
No description provided.
Delete branch "draft_posts_page_tweak"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Article::published()scope and uses it on the front page, the/bloglisting and the JSON/JF2 feeds. The front page was the only place that showed drafts; the others already filtered onpublishedand now share the scope.[Draft]prefix in the page title,noindex, nofollowrobots meta tag.@stack('head')to the master layout so individual views can push tags into<head>.publishedwith1because the column is asmallintin Postgres.Testing
/blog; a draft shows the notice, title prefix and noindex tag; a published article shows none of them.sail test: 384 passed.npm run build(lint + CSS/JS build + compression) is clean; the rebuilt assets inpublic/assets/cssare included.🤖 Generated with Claude Code