Skip to content

Add homepage draft mode and Web Previews support#2

Open
marcelofinamorvieira wants to merge 1 commit into
mainfrom
feat/visual-editing
Open

Add homepage draft mode and Web Previews support#2
marcelofinamorvieira wants to merge 1 commit into
mainfrom
feat/visual-editing

Conversation

@marcelofinamorvieira
Copy link
Copy Markdown
Collaborator

@marcelofinamorvieira marcelofinamorvieira commented Mar 14, 2026

Description

This PR adds homepage-only DatoCMS draft mode support, Web Previews endpoints, realtime preview updates, and a visual editing toggle. It also updates the homepage rendering flow so draft mode stays visually aligned with the published experience and documents the remaining setup steps in the README.

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update
  • Code refactor
  • Performance improvement
  • Dependencies update

Testing

Verified locally with:

  • bun run build

  • bun run type-check

  • bun run test

  • manual verification of draft mode entry, realtime preview wiring, visual editing toggle behavior, and exit draft flow on the homepage

  • I have added tests that prove my fix is effective or that my feature works

  • All new and existing tests passed

Screenshots

  • Visual editing hover state:
83750
  • Draft toolbar:
31446

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have checked my code and corrected any misspellings

Related Issues

N/A

Additional Notes

  • Scope is intentionally limited to the homepage (/) for now.
  • The preview-links endpoint currently returns homepage draft and published links only.
  • Draft mode requires DRAFT_MODE_SECRET, separate published/draft CDA tokens, and a full DATOCMS_BASE_EDITING_URL environment URL.

Type: feature
Build: ✅ Verified

Notes: Includes realtime preview, visual editing toggle, and README setup instructions.
@netlify
Copy link
Copy Markdown

netlify Bot commented Mar 14, 2026

Deploy Preview for lr-onyx ready!

Name Link
🔨 Latest commit 59c9a53
🔍 Latest deploy log https://app.netlify.com/projects/lr-onyx/deploys/69b4b60eac7e22000827c50c
😎 Deploy Preview https://deploy-preview-2--lr-onyx.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
Lighthouse
Lighthouse
1 paths audited
Performance: 99 (🔴 down 1 from production)
Accessibility: 97 (no change from production)
Best Practices: 92 (🔴 down 8 from production)
SEO: 100 (no change from production)
PWA: 78 (no change from production)
View the detailed breakdown and full score reports

To edit notification comments on pull requests, go to your Netlify project configuration.

@netlify
Copy link
Copy Markdown

netlify Bot commented Mar 14, 2026

Deploy Preview for theonxyproject ready!

Name Link
🔨 Latest commit 59c9a53
🔍 Latest deploy log https://app.netlify.com/projects/theonxyproject/deploys/69b4b60e1587b9000803c70f
😎 Deploy Preview https://deploy-preview-2--theonxyproject.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
Lighthouse
Lighthouse
1 paths audited
Performance: 99
Accessibility: 97
Best Practices: 92
SEO: 100
PWA: 78
View the detailed breakdown and full score reports

To edit notification comments on pull requests, go to your Netlify project configuration.

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