feat!: prepare 0.7.0 release with peer-dep migration and consumer polish#70
Merged
Conversation
Contributor
Deploying with
|
| Status | Name | Latest Commit | Preview URL | Updated (UTC) |
|---|---|---|---|---|
| ✅ Deployment successful! View logs |
block-kitchen | cb6d2a2 | Commit Preview URL Branch Preview URL |
May 19 2026, 02:54 PM |
8a05802 to
a8fa601
Compare
Exits the 0.6.x-alpha line. Tightens up the consumer-facing surface ahead of
the first stable 0.x release.
BREAKING CHANGE: A narrow set of dependencies moved from `dependencies` to
`peerDependencies` — specifically the ones a typical consumer is likely
to already have, where deduplication gives them a real win (single copy of
Radix → consistent React context across `<TooltipProvider>` etc.; single
copy of `lucide-react`):
- react, react-dom
- @radix-ui/react-{dialog,label,popover,radio-group,slot,tooltip}
- lucide-react
Modern package managers (pnpm 8+, npm 7+, yarn berry) auto-install peers,
so most consumers will not need to change anything. Older tooling can
follow the explicit install command in the README.
`@dnd-kit/*`, `@tiptap/*`, `slack-blocks-to-jsx`, and
`@tightknitai/slack-block-kit-validator` stay as direct dependencies —
most consumers don't already have these, so peer would only add
version-skew surface with no dedupe upside.
`slack-web-api-client` is now a devDependency (type-only consumer; stays
in tsup's `external` list).
What's new:
- feat(exports): subpath entries for headless usage
- `@tightknitai/block-kitchen/helpers` (~4.5 KB) — `toSlackBlocks`,
`encode/decodeBlocksFromString` and supporting types, with no
React dependency cone. Safe for backends (Workers, Lambdas).
- `@tightknitai/block-kitchen/palette` — `defaultPalette`,
`legacyInputVariants`, `extraAlertVariant`, and `buildVariantById`
without pulling in the builder.
The root entry still re-exports everything, so existing imports are
unaffected.
- feat(palette): `disabledBlockTypes` prop on `<BlockKitchen>`. Filters
at the variant level — mixed-type sections (e.g. "Structure") keep
the variants whose types aren't disabled and sections that go empty
drop out. Convenient when you want the default palette minus a few
block types without rebuilding it.
- refactor(styles): scope the package's Tailwind theme and utility
imports in named cascade layers (`bk-theme`, `bk-utilities`) so
consumer utilities win against the package's on class-name
collisions without source-order luck. Consumers can override layer
order explicitly if they want — documented in the README.
- docs(readme): bundlephobia minzip badge; framework recipes for
Next.js (App + Pages Router), Remix, Vite, and Astro; portal-
stylesheet pitfall callout (import at app root, not in a route);
subpath-export examples; cascade-layer ordering snippet;
`disabledBlockTypes` row in the props table; explanation of the
narrow peer-dep set and the deliberate cut-off.
- chore(release): version bumped to 0.7.0 in package.json and
.release-please-manifest.json.
Verification: typecheck ✓, 217/217 tests ✓, library build ✓, demo install +
build ✓, demo dev server renders with no console errors and themed surface
intact.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
a8fa601 to
cb6d2a2
Compare
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.
Summary
Exits the
0.6.x-alphaline and tightens the consumer-facing surface aheadof the first stable
0.xrelease. The big change is the dependency model:a narrow set of runtime deps move to peer so shadcn/Radix and lucide
consumers dedupe instead of getting duplicate copies.
Why
block-kitchenis built to be embedded into someone else's app, and aquick audit of how it handles that today surfaced a few rough edges:
node_modules(Radix in particular risks
TooltipProvider/PopoverContextmismatchwhen two copies are present).
toSlackBlockswas forced through the root entry and its full React component tree.
imageortableblock from the default palette was to rebuild the whole array.utilities both compiled into
@layer utilities, leaving conflictresolution to source-import order.
'use client',portal placement, or where to import the stylesheet.
This PR addresses all six.
Breaking change
A narrow set of dependencies moved from
dependenciestopeerDependencies— just the ones a typical consumer is likely toalready have, where dedupe gives them a real win:
react,react-dom@radix-ui/react-{dialog,label,popover,radio-group,slot,tooltip}—shadcn/ui audience already has these, and peer avoids the React-
context split bug from two Radix copies.
lucide-react— universal in modern React UI stacks.Everything else stays as a regular dependency.
@dnd-kit/*,@tiptap/*,slack-blocks-to-jsx, and@tightknitai/slack-block-kit-validatorare specialty — most consumersdon't already have them, so peer would only add version-skew surface
with no dedupe upside.
Modern package managers (pnpm 8+, npm 7+, yarn berry) auto-install
peers — most consumers won't need to change anything. Older tooling
can use the explicit command added to the README:
slack-web-api-clientis now adevDependency(type-only consumer; staysin tsup's
externallist).What's in the PR
feat(exports)— subpath entries:@tightknitai/block-kitchen/helpers(4.5 KB) for headless backendusage of
toSlackBlocks,encodeBlocksToString,decodeBlocksFromString.@tightknitai/block-kitchen/palettefor tools that needdefaultPalette/legacyInputVariants/extraAlertVariant/buildVariantByIdwithout the builder.existing imports.
feat(palette)— newdisabledBlockTypes?: SupportedBlockType[]prop on
<BlockKitchen>. Filters at the variant level (sections thatmix types keep variants whose types aren't disabled; sections that
empty out drop entirely).
refactor(styles)— package's compiled Tailwind utilities nowlive in named cascade layers (
bk-theme,bk-utilities) so consumerutilities win on collisions without source-order luck. Layer order
documented in the README for consumers who want explicit control.
docs(readme)— bundlephobia badge; framework recipes for Next(App + Pages Router), Remix, Vite, Astro; portal-stylesheet pitfall
callout; subpath-export examples; cascade-layer ordering snippet;
disabledBlockTypesrow in the props table; explanation of thenarrow peer-dep set and the deliberate cut-off.
chore(release)—package.jsonand.release-please-manifest.jsonbumped from
0.6.2-alpha.0to0.7.0. Pre-1.0 minor bump perrelease-please config (
bump-minor-pre-major: true) signals thebreaking peer-dep migration.
Test plan
pnpm typecheckpnpm test— 217/217 passingpnpm build— clean, ESM + CJS + types for all three entriespnpm --dir demo install && pnpm --dir demo build— demo links tosource and still builds against the new dep layout
pnpm demo:dev) renders palette + surface +templates panel with no console errors after the cascade-layer
rename
pnpm storybookMode: darktoggle in demoheader)
Notes for reviewer
0.7.0bump in.release-please-manifest.jsonis intentional —it's the mechanism that gets the package out of the
-alpha.Xsuffixon the next release-please run.
consumers'
node_modulessize drops meaningfully when they shareRadix / lucide with the rest of their app. The biggest remaining
bundle win —
React.lazyper-block-editor code splitting — isdeliberately deferred; it's a real refactor, not a release-prep fix.
0.7.0lands onnpm. Until then it'll render as "no data" on bundlephobia.
(which also included
@dnd-kit/*,@tiptap/*,slack-blocks-to-jsx)after deciding those don't carry the dedupe / context-mismatch
justification that Radix and lucide do — they're specialty deps the
typical consumer wouldn't already have, so peer would just add skew
warnings.
🤖 Generated with Claude Code