Skip to content

fix(skills): port remaining support-assistant fixes after 0.2.0 - #23

Open
hitesh-shetty-cstk wants to merge 1 commit into
contentstack:nextfrom
hitesh-shetty-cstk:fix/visual-editor-support-assistant-followups
Open

hitesh-shetty-cstk wants to merge 1 commit into
contentstack:nextfrom
hitesh-shetty-cstk:fix/visual-editor-support-assistant-followups

Conversation

@hitesh-shetty-cstk

Copy link
Copy Markdown
Contributor

Summary

Follow-up to #21. Eight fixes to cms-live-preview-visual-editor-support-assistant landed on the original branch (#18) after it was folded into the 0.2.0 release, so they never reached it. This ports them onto the merged text and skips everything #21 already covered (hash presence checks, Management Token scope, Onboarding Check before "what changed", SSR evidence from server logs).

Changes

  • Open in New Tab is scoped to Live Preview in faq-integration.md and contact-support.md. Visual Editor does not support it and always renders the site in its canvas iframe, so recommending it for an SSO-gated Visual Editor site sends users down a dead end.
  • Missing navigation entry: the Support row now checks the stack's Live Preview setting first, matching visual-experience-navigation-missing-for-the-stack.
  • CORS: the entry no longer states that no Contentstack-side allowlist exists (not verified), and the verification notes that curl does not enforce CORS.
  • GraphQL preview: keep access_token and Content-Type on every request; the preview headers are added, not swapped in.
  • livePreviewQuery: live_preview is the only required key, an empty one resets the instance to published content, and both content_type_uid and contentTypeUid spellings are accepted (checked against contentstack-typescript src/stack/stack.ts).
  • Edit button: the exclude config is applied only by init(), so builds that import the SDK without calling init() need the purge flag or a preview-only import.
  • Caching: app and CDN caches are separated from SDK caching. The legacy contentstack v3 SDK forces NETWORK_ELSE_CACHE once a real hash is set, and the hash rotates on a 24-hour timer, not on edits.
  • stackSdk: the framework examples note that stack.config is for @contentstack/delivery-sdk and the legacy SDK takes the Stack instance.

Test plan

  • node scripts/validate.mjs passes (23 skills, 7 manifests)
  • Every edited passage reads correctly against the surrounding text on next
  • No Jira keys, internal links or customer identifiers in the diff

🤖 Generated with Claude Code

…erge

These were made on the original branch after it was folded into the
0.2.0 release, so they did not reach it:

- Open in New Tab is scoped to Live Preview; Visual Editor does not
  support it and always renders in its canvas iframe.
- Missing Visual Experience navigation checks the stack's Live Preview
  setting before treating it as provisioning.
- The CORS entry no longer rules out a Contentstack-side cause, and its
  verification says curl does not enforce CORS.
- GraphQL preview requests keep access_token and Content-Type.
- livePreviewQuery: live_preview is the only required key and an empty
  one resets the instance; both key spellings are accepted.
- The editButton exclude config applies only where init() runs.
- Cache guidance separates app and CDN caches from SDK caching and says
  the hash rotates on a timer rather than on edits.
- The framework examples say which stackSdk to pass per Delivery SDK.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@hitesh-shetty-cstk
hitesh-shetty-cstk requested a review from a team as a code owner October 14, 2026 12:58
@snyk-io

snyk-io Bot commented Oct 14, 2026

Copy link
Copy Markdown

✅ Snyk checks have passed. No issues have been found so far.

Status Scan Engine Critical High Medium Low Total (0)
✅ Code Security 0 0 0 0 0 issues

💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse.

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