Share reward and less robot load on shared links
The first visit of a shared link by someone else earns the sharer one free natal analysis, once per user. The share page reports visits from the visitor's browser; robots, the logged-in sharer and the address the link was made at do not count. The share button is a proper card that says so in small print; /v1/me tells whether the reward is used up. Robots: reading a share writes nothing (view_count counts people only), the frontend keeps shared content for five minutes (cleared when a link is revoked), and robots.txt turns away the known AI crawlers while leaving the link preview robots alone. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012vLHzh5qUhFtmJhzkcTbXL
This commit is contained in:
@@ -25,6 +25,7 @@ export function ChartSummary({
|
||||
initial,
|
||||
detailedDone = false,
|
||||
isAdmin = false,
|
||||
shareRewardGranted = false,
|
||||
}: {
|
||||
chartId: string;
|
||||
initial: Analysis | null;
|
||||
@@ -32,6 +33,8 @@ export function ChartSummary({
|
||||
detailedDone?: boolean;
|
||||
/** Admins can write the summary again. */
|
||||
isAdmin?: boolean;
|
||||
/** The free analysis for sharing is used up. */
|
||||
shareRewardGranted?: boolean;
|
||||
}) {
|
||||
const [summary, setSummary] = useState<Analysis | null>(initial);
|
||||
const [gaveUp, setGaveUp] = useState(false);
|
||||
@@ -82,7 +85,7 @@ export function ChartSummary({
|
||||
<p className="summary-text" lang={summary?.language}>
|
||||
<Rich text={content.summary ?? ""} />
|
||||
</p>
|
||||
<ShareChart chartId={chartId} />
|
||||
<ShareChart chartId={chartId} rewardGranted={shareRewardGranted} />
|
||||
<a
|
||||
href="#elemzes"
|
||||
className="summary-more"
|
||||
|
||||
Reference in New Issue
Block a user