Skip to content

fix(public): add JSON-LD structured data to trust and support pages - #26

Merged
nish3451 merged 2 commits into
mainfrom
fix/public-trust-support-structured-data
Aug 9, 2026
Merged

fix(public): add JSON-LD structured data to trust and support pages#26
nish3451 merged 2 commits into
mainfrom
fix/public-trust-support-structured-data

Conversation

@nish3451

@nish3451 nish3451 commented Aug 9, 2026

Copy link
Copy Markdown
Collaborator

What

Six trust/support pages carried no JSON-LD structured data while the other six public pages did. This PR closes the gap so every public page on tinystudio.in exposes source-bound structured data.

Changed pages

Page Schema type
/privacy/ WebPage
/terms/ WebPage
/privacy-choices/ WebPage
/drishti/privacy/ WebPage
/drishti/support/ ContactPage
/promptly/support/ ContactPage

Each page gains the same truthful @graph block used elsewhere: a stable Tiny Studio Organization reference plus the page node (isPartOf the website, about the organization). Every JSON-LD value (url, name, description) is copied verbatim from the page's canonical, <title>, and meta description, matching the pattern established in #19. Support pages use ContactPage to mirror the existing /support/ and /contact/ pages.

Tests

scripts/test-public-structured-data.mjs now covers all eight audited pages and adds an invariant that every public HTML page carries exactly one application/ld+json block (all 12 pages), so a future page cannot ship without structured data again.

Verification

  • test-gate npm test — exit 0
  • test-gate npm run ci — exit 0
  • git diff --check — clean
  • node --check scripts/test-public-structured-data.mjs — clean
  • node scripts/test-public-structured-data.mjs — 127 checks, 0 failures

Summary by CodeRabbit

  • New Features

    • Added structured metadata to privacy, terms, support, and privacy-choice pages to improve how they are represented in search results and shared links.
    • Added organization and page details for clearer page identification.
  • Tests

    • Expanded validation to automatically discover public pages and confirm each contains exactly one structured-data block.

@greptile-apps greptile-apps Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nish3451 has reached the 50-credit limit for trial accounts. To continue receiving code reviews, upgrade your plan.

@coderabbitai

coderabbitai Bot commented Aug 9, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@nish3451, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 3 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 93689157-e8df-4080-a0e9-a2b3cc8d0fda

📥 Commits

Reviewing files that changed from the base of the PR and between f5a82e3 and c52d514.

📒 Files selected for processing (9)
  • package.json
  • public/drishti/privacy/index.html
  • public/drishti/support/index.html
  • public/privacy-choices/index.html
  • public/privacy/index.html
  • public/promptly/privacy/index.html
  • public/promptly/support/index.html
  • public/terms/index.html
  • scripts/test-public-social-preview.mjs
📝 Walkthrough

Walkthrough

The pull request adds Schema.org JSON-LD metadata to six public pages. It also updates the structured-data test to cover explicit pages and recursively validate every public index.html file.

Changes

Structured data coverage

Layer / File(s) Summary
Page metadata
public/drishti/privacy/index.html, public/drishti/support/index.html, public/privacy-choices/index.html, public/privacy/index.html, public/promptly/support/index.html, public/terms/index.html
Each page now includes JSON-LD entries for Tiny Studio and the page, with identifiers, URLs, names, descriptions, and relationships.
Structured-data validation
scripts/test-public-structured-data.mjs
The test covers the added pages, recursively discovers public index.html files, and verifies that each page contains exactly one JSON-LD block.

Estimated code review effort: 2 (Simple) | ~10 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly summarizes the main change: adding JSON-LD structured data to the affected trust and support pages.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/public-trust-support-structured-data

Comment @coderabbitai help to get the list of available commands.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: f5a82e335a

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

readdirSync(join(ROOT, dir), { withFileTypes: true }).flatMap((entry) => {
const path = join(dir, entry.name)
if (entry.isDirectory()) return publicHtmlFiles(path)
if (entry.isFile() && entry.name === "index.html") return [path]

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Scan every HTML file, not just index pages

When a standalone public page such as public/404.html is added, this filter silently excludes it, so the new “every public HTML page” invariant passes even if that page has no JSON-LD. Match all .html files rather than only files named index.html so CI enforces the stated invariant for every deployed HTML document.

Useful? React with 👍 / 👎.

Seven of the 12 public pages (privacy, privacy-choices, terms, the
Promptly and Drishti support/privacy pairs) declared no og:image or
twitter:image, so shared links rendered as bare text cards. This class
gap was left behind after the closed /promptly heading work touched the
same page families.

Add the full og:image block (secure_url, type, 1200x630 dimensions, alt)
and the matching twitter summary_large_image card to all 7 pages, reusing
the per-family social art that already exists: tiny-studio-social.png for
studio pages, promptly-social.png for /promptly/*, and drishti-social.png
for /drishti/*. The 5 pages that already had imagery are unchanged.

Adds scripts/test-public-social-preview.mjs, wired into npm test and npm
run ci, asserting every one of the 12 public pages declares the complete
og:image and twitter:image blocks, that twitter:image matches og:image,
and that every referenced image ships in public/social/.

verify: /home/nish/.local/bin/test-gate npm test; git diff --check; node --check scripts/test-public-social-preview.mjs
The structured data pass in #19 covered only the contact page and the
Promptly privacy page, leaving the other six public pages - studio
privacy, terms, privacy choices, Drishti privacy, Drishti support, and
Promptly support - without any JSON-LD. Every public page should expose
source-bound structured data so search engines get consistent page
metadata across the site.

Add the same truthful @graph blocks used elsewhere: a stable Tiny Studio
Organization reference plus the page node. Privacy, terms, and privacy
choices pages are declared as WebPage (matching the Promptly privacy
pattern); the two app support pages are declared as ContactPage with an
isPartOf/about relationship to the site and organization, mirroring the
existing /support/ and /contact/ pages. All JSON-LD values (url, name,
description) are copied from each page's canonical, title, and meta
description so the data stays truthful to the page.

Extends scripts/test-public-structured-data.mjs to cover all eight
audited pages and adds an invariant that every public HTML page carries
exactly one application/ld+json block, so a future page can never ship
without structured data again.

verify: /home/nish/.local/bin/test-gate npm test; /home/nish/.local/bin/test-gate npm run ci; git diff --check; node --check scripts/test-public-structured-data.mjs; node scripts/test-public-structured-data.mjs shows 127 checks, 0 failures across all 12 public pages
@nish3451
nish3451 force-pushed the fix/public-trust-support-structured-data branch from f5a82e3 to c52d514 Compare August 9, 2026 06:14

@greptile-apps greptile-apps Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nish3451 has reached the 50-credit limit for trial accounts. To continue receiving code reviews, upgrade your plan.

@nish3451
nish3451 merged commit ffe6e1f into main Aug 9, 2026
3 checks passed

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: c52d5142be

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

}

// Every public page (canonical list, mirrors test-public-footer-targets.mjs).
const PUBLIC_PAGES = [

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Discover public HTML pages instead of hard-coding them

When a new deployed page such as public/404.html is added, this fixed list omits it, so npm test remains green even if the page has no Open Graph or Twitter image metadata. Recursively discover every .html file under public/ so the stated every-page social-preview invariant automatically covers future standalone and nested pages.

Useful? React with 👍 / 👎.

nish3451 added a commit that referenced this pull request Aug 14, 2026
…ive blocked on missing Cloudflare token

Lane 1 verification report: the 7-page social preview imagery fix is already
merged to main (PR #26, ffe6e1f) and test-public-social-preview.mjs guards the
static files. The live tinystudio.in still serves the stale bundle with exactly
the 7 pages from the item missing og:image, and live delivery is blocked only by
the missing CLOUDFLARE_API_TOKEN secret (NEEDS-NISH, deploy-pipeline item).

Co-authored-by: CommandCodeBot <noreply@commandcode.ai>
nish3451 added a commit that referenced this pull request Aug 15, 2026
… already complete in PR #26, live blocked on missing Cloudflare token (#182)

Dogfood finding 82771ab0cb63 flags /promptly/privacy's social share image
as incomplete. Verified on lane resume: the full og:image block and
twitter:image are already merged on main via PR #26 (commit ffe6e1f) and
test-pinned (137 checks, 0 failures); live tinystudio.in/promptly/privacy/
still serves zero og:image tags because every deploy run fails at the
fail-closed missing CLOUDFLARE_API_TOKEN step. NEEDS-NISH: provision the
secret.

Co-authored-by: CommandCodeBot <noreply@commandcode.ai>
nish3451 added a commit that referenced this pull request Aug 22, 2026
… on main (PR #26 ffe6e1f) and live (PR #127 607e99e) (#215)

Co-authored-by: minimax-vps <minimax-vps@nish.local>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant