Skip to content

feat(PreviewBanner): brand-controlled approval banner for Pliosoft preview deploys - #4

Merged
clord merged 5 commits into
mainfrom
preview-banner
Apr 20, 2026
Merged

clord merged 5 commits into
mainfrom
preview-banner

Conversation

@clord

@clord clord commented Apr 20, 2026

Copy link
Copy Markdown
Member
  • udpate publish script
  • release: 0.1.6
  • feat(PreviewBanner): brand-controlled approval banner for Pliosoft preview deploys

clord and others added 5 commits April 18, 2026 12:50
…eview deploys

New component for Pliosoft's hosted-platform preview-deploy flow. Renders
only when the build was invoked with PLIOSOFT_PREVIEW=1 (the platform's
build pipeline sets these env vars per-PR); production builds emit
nothing.

UX:
- Always visible: "Preview" eyebrow, PR title, Approve & Reject buttons.
- Tucked behind a <details> toggle: PR number with link to GitHub,
  branch, sha. (PR title is the most important context; metadata is
  one click away.)
- Self-contained Pliosoft branding (warm paper bg, orange accent rule)
  that overrides the customer theme — the banner is platform UI, not
  customer UI.

Build-time env vars consumed:
  PLIOSOFT_PREVIEW              "1" enables rendering
  PLIOSOFT_PREVIEW_PR           PR number
  PLIOSOFT_PREVIEW_TITLE        human-readable PR title
  PLIOSOFT_PREVIEW_BRANCH       branch under preview
  PLIOSOFT_PREVIEW_SHA          commit sha (truncated to 7 for display)
  PLIOSOFT_PREVIEW_PR_URL       full PR URL on github.com
  PLIOSOFT_PREVIEW_JWT          single-use JWT signed by orchestrator
  PLIOSOFT_PREVIEW_API          orchestrator base (defaults sites.pliosoft.co)

Buttons POST the JWT to <api>/_preview/approve or /reject. The
orchestrator verifies, marks the nonce used, and merges or closes the
PR via the GitHub App.

If a customer ejects from the platform, env vars are never set and the
component is a no-op — safe to include unconditionally in any layout.

Bumps to 0.2.0.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@clord
clord merged commit 433292f into main Apr 20, 2026
1 check passed

This branch had an error being deployed

1 failed deployment
production 69651d61 Deployed Jul 26, 2026 by clord via publish #10
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