chore: version packages#28
Merged
Merged
Conversation
4989401 to
784cb83
Compare
784cb83 to
a19903d
Compare
2e54c8f to
1e10411
Compare
c574a25 to
3f8a72d
Compare
d3b0b89 to
24879fc
Compare
c6c9aba to
11516f2
Compare
11516f2 to
7158c5b
Compare
7f62b68 to
ddbf047
Compare
Deploying with
|
| Status | Name | Latest Commit | Preview URL | Updated (UTC) |
|---|---|---|---|---|
| ✅ Deployment successful! View logs |
simplepdf-webhooks | 46ad8d0 | Commit Preview URL Branch Preview URL |
Jun 29 2026, 09:03 AM |
861109d to
09935fd
Compare
bendersej
approved these changes
Jun 29, 2026
09935fd to
46ad8d0
Compare
bendersej
added a commit
that referenced
this pull request
Jun 29, 2026
…#40) ## Background Merging the Version PR (#28) triggered the publish, but it **failed before shipping anything** (npm still at `@simplepdf/embed@0.4.0` / `@simplepdf/react-embed-pdf@1.10.0`). `release.yaml` has no build step — it relies on `changeset publish`'s `prepublishOnly` hooks. But those don't build in dependency order: `react`'s `prepublishOnly` (`rollup -c`) runs before `@simplepdf/embed`'s type declarations exist, so `rpt2` can't resolve `@simplepdf/embed` / `/tools` / `/ai-sdk` (TS7016) and the whole publish aborts. `dist` is gitignored, so CI must build it — and the ordering can't be left to the publish hooks. ## Changes - `release.yaml` builds all workspaces in dependency order (`embed → react → web`) before the publish step, so each package's types exist before the next builds. ## Notes Verified locally from a clean `dist`: `npm run build --workspaces --if-present` builds embed (8 `.d.ts`) then react with no TS7016, exit 0. Merging this re-runs `release.yaml` on `main` (the changesets are already consumed, so it takes the publish path) → builds → publishes `0.5.0` / `1.11.0`.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR was opened by the Changesets release GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated.
Releases
@simplepdf/embed@0.5.0
Minor Changes
980906d: camelCase SDK surface grouped into
actions/events/lifecycle,companyIdentifier, and direct loading of SimplePDF documents URLs.createEmbedreturns{ actions, events, lifecycle }—embed.actions.*(operations),embed.events.on(type, handler)(subscriptions),embed.lifecycle.dispose()(teardown).embed.actions.getFields(),embed.actions.setFieldValue({ fieldId, value }),embed.actions.submit({ downloadCopy }),tools.getDocumentContent). The editor's snake_case wire is generated fromembed-api.jsonand transformed at the postMessage boundary — consumers never see it.embed.events.on(type, handler)delivers the editor's outbound payloads VERBATIM (snake_case fields, e.g.document_id) forEDITOR_READY/DOCUMENT_LOADED/PAGE_FOCUSED/SUBMISSION_SENT, so the React layer'sonEmbedEventis unchanged.companyIdentifierreplacestenantincreateEmbed(it is the consumer's own SimplePDF subdomain —tenantread as if SimplePDF were multi-tenant per consumer).document.urlis a<tenant>.<baseDomain>/documents/<id>URL (https, single tenant label),createEmbednavigates the iframe straight to it (carrying?context=) instead of host-fetching — so prefilled/stored documents open as themselves.@simplepdf/react-embed-pdf(the/reactsubpath is removed); the editor iframe is grantedclipboard-read; clipboard-writeby default.@simplepdf/react-embed-pdf@1.11.0
Minor Changes
980906d: Rebuilt on the
@simplepdf/embedcore, adding an AI-SDK-native agentic surface — a non-breaking superset of the existing component API.@simplepdf/react-embed-pdfno longer hand-rolls its own iframe bridge; it is a thin React layer over the shared@simplepdf/embedcore (the same coreweb-embed-pdfand future framework adapters sit on).The existing
<EmbedPDF>contract is preserved (drop-in): the props (companyIdentifier,documentURL,mode— still defaulting to"modal",onEmbedEvent,locale,baseDomain,context,className,style) and, crucially,onEmbedEventstill emits the editor's events VERBATIM:{ type: 'EDITOR_READY' | 'DOCUMENT_LOADED' | 'PAGE_FOCUSED' | 'SUBMISSION_SENT', data }with snake_case payloads.useEmbed()still returns{ embedRef, actions }.New (additive):
@simplepdf/react-embed-pdf/ai-sdksubpath exposes the agentic surface:useEmbedTools(embedRef)binds the tool registry to the live editor for the Vercel AI SDK (useChat({ tools })), plussimplePDFToolDefinitions(server) andcreateSimplePDFExecutor. It mirrors@simplepdf/embed's/ai-sdk, so the package root stays zod-free.useEmbed().actionsnow exposes the FULL editor surface (camelCase):createField,getFields,setFieldValue,focusField,movePage,rotatePage,deletePages,download, … — not just the original six.documentprop ({ url } | { dataUrl } | { file }), the same shape ascreateEmbed. It also accepts data URLs and File/Blob, and a SimplePDF documents URL loads directly (prefill etc.).documentURLis now@deprecated(still works) in favor of it.loggerprop surfaces the bridge's structured lifecycle/error logging.ref(embedRef.current) stays the flat actions handle —embedRef.current.selectTool(...), etc. — now exposing the full camelCase action set. (The framework-free@simplepdf/embedcore groups its handle asembed.actions/embed.events/embed.lifecycle; the React layer flattens it to keep the existing ref contract.)Imperative actions stay backward-compatible.
selectToolandsubmitgained camelCase argument shapes to match the rest of the SDK (selectTool({ tool }),submit({ downloadCopy })), but the previous forms —selectTool(toolType)andsubmit({ downloadCopyOnDevice })— still work as deprecated overloads that normalize to the new shape, so existinguseEmbed().actionscallers don't change. A relativedocumentURL/ triggerhref(e.g./form.pdf) is still accepted — it is resolved against the page URL, as before.One behavioral note: calling an action before
<EmbedPDF>has mounted now resolves to{ success: false, error: { code: 'unexpected:iframe_not_mounted' } }(the previous form returnedbad_request:embed_ref_not_available). Code that checksresult.successis unaffected; only code branching on the exact pre-mount error string needs updating.Packaging is preserved: still dual CJS + ESM, so
require()consumers keep working.zodremains a peer dependency, now required only by the agentic/ai-sdksubpath (it validates tool input) — the package root (<EmbedPDF>,useEmbed) is zod-free, so a non-agentic app never loads it. Installzodonly if you import/ai-sdk; npm 7+ adds it automatically, pnpm / Yarn PnP users add it explicitly.Patch Changes