- Sign in with a Reddit web app; access tokens refresh automatically, and an app-only token reads rules before sign-in. - Reddit drafts: a title and text for one subreddit, chosen when writing. The subreddit's guidelines and rules go into the prompt, which asks for a community member's post that discloses the affiliation and avoids marketing language. - The Inbox shows the subreddit's rules (cached for a day, with Refresh) and warns, without blocking, about promotion rules, restricted subreddits, link-only subreddits, posting in the same subreddit within a week, more than 1 in 10 recent posts linking to the company's sites, and new accounts. - Publishing makes a text post with the source link at the end, or a link post where the subreddit takes only links. - Migration 4 adds the draft's title and subreddit, and the rules cache. Publishers now take a Post, which carries the title and subreddit. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
28 lines
987 B
HTML
28 lines
987 B
HTML
{{define "content"}}{{with .Data}}
|
|
<nav class="tabs">
|
|
<a href="/content">Sources</a>
|
|
<a href="/content/scheduled">Scheduled</a>
|
|
<a href="/content/published" aria-current="page">Published</a>
|
|
</nav>
|
|
<h1>Published</h1>
|
|
<p class="lede">The last 200 posts Supermarket published.</p>
|
|
|
|
{{if .Drafts}}
|
|
<table class="list">
|
|
<thead><tr><th>When</th><th>Channel</th><th>Entry</th><th>Post</th></tr></thead>
|
|
<tbody>
|
|
{{range .Drafts}}
|
|
<tr>
|
|
<td>{{.PublishedAt.Local.Format "2 Jan 2006 15:04"}}</td>
|
|
<td>{{.Where}}</td>
|
|
<td>{{.InventoryName}}</td>
|
|
<td class="post-text">{{if .PostURL}}<a href="{{.PostURL}}" target="_blank" rel="noopener noreferrer">{{if .Title}}<strong>{{.Title}}</strong> {{end}}{{truncate 200 .Content}}</a>{{else}}{{if .Title}}<strong>{{.Title}}</strong> {{end}}{{truncate 200 .Content}}{{end}}</td>
|
|
</tr>
|
|
{{end}}
|
|
</tbody>
|
|
</table>
|
|
{{else}}
|
|
<section class="card empty"><p>Nothing published yet.</p></section>
|
|
{{end}}
|
|
{{end}}{{end}}
|