@marvalt/cadapter
v0.1.7
Published
Standalone React adapter for embedding and managing Calendly widgets in DigiVAlt applications.
Readme
@marvalt/cadapter
React components and hooks for embedding Calendly scheduling in DigiValt applications.
When you need it
Use when the site offers book-a-call flows without WordPress or CRM form integration. Works standalone; no @marvalt/digivalt-core required.
Installation
npm install @marvalt/cadapterPeers: React 18+, React DOM 18+.
Environment
| Variable | Required | Notes |
|----------|----------|-------|
| VITE_CALENDLY_URL | Recommended | Default event URL when component url prop is omitted |
Entry points
import { CalendlyInline, CalendlyPopup, useCalendlyScript } from '@marvalt/cadapter';Documentation
- After install:
node_modules/@marvalt/cadapter/docs/README.md
Features
useCalendlyScript: Loads Calendlywidget.jsasynchronously.<CalendlyInline />: Full inline scheduler on a page.<CalendlyPopup />: Floating badge + popup scheduler.
Inline Widget
import { CalendlyInline } from '@marvalt/cadapter';
export default function BookingPage() {
return (
<div className="container py-10">
<h1 className="text-3xl font-bold mb-6">Book a Strategy Call</h1>
<CalendlyInline className="rounded-xl border shadow-lg overflow-hidden" />
</div>
);
}Popup Widget
import { CalendlyPopup } from '@marvalt/cadapter';
export default function Layout() {
return (
<main>
<CalendlyPopup text="Schedule time with me" color="#0069ff" textColor="#ffffff" />
</main>
);
}