build(deps): upgrade package dependencies#2654
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
📝 WalkthroughWalkthroughChanged many package manifests (dev tooling bumps, Shiki Changes
Sequence Diagram(s)sequenceDiagram
participant Editor as Editor
participant Extension as Extension
participant Store as Store
participant Yjs as YjsThreadStore
Editor->>Extension: mount()
Extension->>Store: createStore(initialState)
Extension->>Store: subscribe(onChange)
Store-->>Extension: notify(stateChange)
Extension->>Editor: editor.transact(setMeta(...))
Editor->>Yjs: addComment(...)
Yjs->>Yjs: generate id via uuidv4()
Yjs-->>Store: update thread/comment state
Estimated code review effort🎯 4 (Complex) | ⏱️ ~45 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
🧹 Nitpick comments (1)
packages/core/src/extensions/ShowSelection/ShowSelection.ts (1)
50-54: Use the updater'sprevargument instead of readingstore.state.Since you've switched to a functional updater, derive the next state from the callback argument rather than re-reading
store.stateinside it — otherwise the functional form offers no benefit over passing an object.♻️ Proposed refactor
- store.setState(() => ({ + store.setState((prev) => ({ enabledSet: shouldShow - ? new Set([...store.state.enabledSet, key]) - : new Set([...store.state.enabledSet].filter((k) => k !== key)), + ? new Set([...prev.enabledSet, key]) + : new Set([...prev.enabledSet].filter((k) => k !== key)), }));🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@packages/core/src/extensions/ShowSelection/ShowSelection.ts` around lines 50 - 54, The updater passed to store.setState currently reads store.state inside the functional updater; change it to use the updater argument (commonly named prev) to derive the new enabledSet so you don't re-read external state. In the store.setState callback for ShowSelection, compute enabledSet from prev.enabledSet (e.g., create a new Set from prev.enabledSet, add or remove key based on shouldShow) and return that object instead of referencing store.state.enabledSet.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@packages/core/src/comments/extension.ts`:
- Around line 100-108: The new store.subscribe created next to
prevSelectedThreadId must be cleaned up on unmount: move the subscription
registration into mount() (alongside threadStore.subscribe and
onSelectionChange) or capture the unsubscribe function returned by
store.subscribe and store it so it can be called during the existing teardown;
ensure you keep the same logic that compares prevSelectedThreadId and calls
editor.transact(tr => tr.setMeta(PLUGIN_KEY, true)), but save the unsubscribe
and invoke it during the mount() cleanup so the listener does not outlive the
extension/editor.
In `@packages/core/src/extensions/ShowSelection/ShowSelection.ts`:
- Around line 17-19: Move the store.subscribe call out of the top-level and into
the ShowSelection extension's mount method so the returned unsubscribe function
can be cleaned up with the provided AbortSignal; inside mount, call
store.subscribe(() => editor.transact((tr) => tr.setMeta(PLUGIN_KEY, {}))) and
capture the unsubscribe function, then either listen to
signal.addEventListener('abort', ...) to call unsubscribe or return an OnDestroy
callback that calls unsubscribe so the subscription is disposed when the
extension is destroyed.
---
Nitpick comments:
In `@packages/core/src/extensions/ShowSelection/ShowSelection.ts`:
- Around line 50-54: The updater passed to store.setState currently reads
store.state inside the functional updater; change it to use the updater argument
(commonly named prev) to derive the new enabledSet so you don't re-read external
state. In the store.setState callback for ShowSelection, compute enabledSet from
prev.enabledSet (e.g., create a new Set from prev.enabledSet, add or remove key
based on shouldShow) and return that object instead of referencing
store.state.enabledSet.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 4f718a90-3704-480f-8f44-2d750250fc96
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (123)
docs/package.jsonexamples/01-basic/01-minimal/package.jsonexamples/01-basic/02-block-objects/package.jsonexamples/01-basic/03-multi-column/package.jsonexamples/01-basic/04-default-blocks/package.jsonexamples/01-basic/05-removing-default-blocks/package.jsonexamples/01-basic/06-block-manipulation/package.jsonexamples/01-basic/07-selection-blocks/package.jsonexamples/01-basic/08-ariakit/package.jsonexamples/01-basic/09-shadcn/package.jsonexamples/01-basic/10-localization/package.jsonexamples/01-basic/11-custom-placeholder/package.jsonexamples/01-basic/12-multi-editor/package.jsonexamples/01-basic/13-custom-paste-handler/package.jsonexamples/01-basic/14-editor-scrollable/package.jsonexamples/01-basic/15-shadowdom/package.jsonexamples/01-basic/16-read-only-editor/package.jsonexamples/01-basic/testing/package.jsonexamples/02-backend/01-file-uploading/package.jsonexamples/02-backend/02-saving-loading/package.jsonexamples/02-backend/03-s3/package.jsonexamples/02-backend/04-rendering-static-documents/package.jsonexamples/03-ui-components/01-ui-elements-remove/package.jsonexamples/03-ui-components/02-formatting-toolbar-buttons/package.jsonexamples/03-ui-components/03-formatting-toolbar-block-type-items/package.jsonexamples/03-ui-components/04-side-menu-buttons/package.jsonexamples/03-ui-components/05-side-menu-drag-handle-items/package.jsonexamples/03-ui-components/06-suggestion-menus-slash-menu-items/package.jsonexamples/03-ui-components/07-suggestion-menus-slash-menu-component/package.jsonexamples/03-ui-components/08-suggestion-menus-emoji-picker-columns/package.jsonexamples/03-ui-components/09-suggestion-menus-emoji-picker-component/package.jsonexamples/03-ui-components/10-suggestion-menus-grid-mentions/package.jsonexamples/03-ui-components/11-uppy-file-panel/package.jsonexamples/03-ui-components/12-static-formatting-toolbar/package.jsonexamples/03-ui-components/13-custom-ui/package.jsonexamples/03-ui-components/14-experimental-mobile-formatting-toolbar/package.jsonexamples/03-ui-components/15-advanced-tables/package.jsonexamples/03-ui-components/16-link-toolbar-buttons/package.jsonexamples/03-ui-components/17-advanced-tables-2/package.jsonexamples/03-ui-components/18-drag-n-drop/package.jsonexamples/04-theming/01-theming-dom-attributes/package.jsonexamples/04-theming/02-changing-font/package.jsonexamples/04-theming/03-theming-css/package.jsonexamples/04-theming/04-theming-css-variables/package.jsonexamples/04-theming/05-theming-css-variables-code/package.jsonexamples/04-theming/06-code-block/package.jsonexamples/04-theming/07-custom-code-block/package.jsonexamples/05-interoperability/01-converting-blocks-to-html/package.jsonexamples/05-interoperability/02-converting-blocks-from-html/package.jsonexamples/05-interoperability/03-converting-blocks-to-md/package.jsonexamples/05-interoperability/04-converting-blocks-from-md/package.jsonexamples/05-interoperability/05-converting-blocks-to-pdf/package.jsonexamples/05-interoperability/06-converting-blocks-to-docx/package.jsonexamples/05-interoperability/07-converting-blocks-to-odt/package.jsonexamples/05-interoperability/08-converting-blocks-to-react-email/package.jsonexamples/05-interoperability/09-blocks-to-html-static-render/package.jsonexamples/05-interoperability/10-static-html-render/package.jsonexamples/06-custom-schema/01-alert-block/package.jsonexamples/06-custom-schema/02-suggestion-menus-mentions/package.jsonexamples/06-custom-schema/03-font-style/package.jsonexamples/06-custom-schema/04-pdf-file-block/package.jsonexamples/06-custom-schema/05-alert-block-full-ux/package.jsonexamples/06-custom-schema/06-toggleable-blocks/package.jsonexamples/06-custom-schema/07-configuring-blocks/package.jsonexamples/06-custom-schema/draggable-inline-content/package.jsonexamples/06-custom-schema/react-custom-blocks/package.jsonexamples/06-custom-schema/react-custom-inline-content/package.jsonexamples/06-custom-schema/react-custom-styles/package.jsonexamples/07-collaboration/01-partykit/package.jsonexamples/07-collaboration/02-liveblocks/package.jsonexamples/07-collaboration/03-y-sweet/package.jsonexamples/07-collaboration/04-electric-sql/package.jsonexamples/07-collaboration/05-comments/package.jsonexamples/07-collaboration/06-comments-with-sidebar/package.jsonexamples/07-collaboration/07-ghost-writer/package.jsonexamples/07-collaboration/08-forking/package.jsonexamples/08-extensions/01-tiptap-arrow-conversion/package.jsonexamples/09-ai/01-minimal/package.jsonexamples/09-ai/02-playground/package.jsonexamples/09-ai/03-custom-ai-menu-items/package.jsonexamples/09-ai/04-with-collaboration/package.jsonexamples/09-ai/05-manual-execution/package.jsonexamples/09-ai/06-client-side-transport/package.jsonexamples/09-ai/07-server-persistence/package.jsonexamples/vanilla-js/react-vanilla-custom-blocks/package.jsonexamples/vanilla-js/react-vanilla-custom-inline-content/package.jsonexamples/vanilla-js/react-vanilla-custom-styles/package.jsonpackage.jsonpackages/ariakit/package.jsonpackages/code-block/package.jsonpackages/core/package.jsonpackages/core/src/comments/extension.tspackages/core/src/comments/threadstore/yjs/YjsThreadStore.test.tspackages/core/src/comments/threadstore/yjs/YjsThreadStore.tspackages/core/src/editor/BlockNoteExtension.tspackages/core/src/extensions/Collaboration/ForkYDoc.tspackages/core/src/extensions/FilePanel/FilePanel.tspackages/core/src/extensions/FormattingToolbar/FormattingToolbar.tspackages/core/src/extensions/Placeholder/Placeholder.tspackages/core/src/extensions/ShowSelection/ShowSelection.tspackages/core/src/extensions/SideMenu/SideMenu.tspackages/core/src/extensions/SuggestionMenu/SuggestionMenu.tspackages/core/src/extensions/TableHandles/TableHandles.tspackages/core/src/extensions/tiptap-extensions/UniqueID/UniqueID.tspackages/mantine/package.jsonpackages/react/package.jsonpackages/react/src/components/FormattingToolbar/DefaultButtons/AddCommentButton.tsxpackages/react/src/components/FormattingToolbar/DefaultButtons/CreateLinkButton.tsxpackages/react/src/components/FormattingToolbar/FormattingToolbarController.tsxpackages/react/src/hooks/useExtension.tspackages/server-util/package.jsonpackages/shadcn/package.jsonpackages/xl-ai-server/package.jsonpackages/xl-ai/package.jsonpackages/xl-ai/src/AIExtension.tspackages/xl-ai/src/components/FormattingToolbar/AIToolbarButton.tsxpackages/xl-docx-exporter/package.jsonpackages/xl-email-exporter/package.jsonpackages/xl-multi-column/package.jsonpackages/xl-odt-exporter/package.jsonpackages/xl-pdf-exporter/package.jsonplayground/package.jsontests/package.json
@blocknote/ariakit
@blocknote/code-block
@blocknote/core
@blocknote/mantine
@blocknote/react
@blocknote/server-util
@blocknote/shadcn
@blocknote/xl-ai
@blocknote/xl-docx-exporter
@blocknote/xl-email-exporter
@blocknote/xl-multi-column
@blocknote/xl-odt-exporter
@blocknote/xl-pdf-exporter
commit: |
…ures During fresh install (no lockfile), @vitest/runner ^4.1.2 resolves to 4.1.4 while vitest@4.1.2 (pinned by override) bundles its own @vitest/runner@4.1.2. Two separate singleton instances cause getCurrentTest() to return a test object without suite context, breaking msw-snapshot's createSnapshotPath in xl-ai streaming tests.
aa006b3 to
6dfcadd
Compare
Replace the blunt 'rm pnpm-lock.yaml' approach with targeted 'pnpm update --prod' for all published packages. This only re-resolves production dependencies, keeping devDependencies pinned to the lockfile so test tooling churn doesn't cause false positives. A node one-liner dynamically discovers non-private workspace packages, so no workflow changes are needed when packages are added or removed.
After pnpm update --prod rewrites inter-workspace deps to workspace:*, npm pack preserves the protocol literally in tarballs. npm install then fails because it doesn't understand workspace:*. pnpm pack correctly resolves workspace:* to actual version numbers during packing.
f3c7163 to
32be46b
Compare
32be46b to
dd6ae2c
Compare
Summary
uuidwithlib0/randomfor UUID generation and fix corresponding test mock@tanstack/storeto 0.10.0 and@tanstack/react-storeto 0.10.0@blocknote/coreDetails
Batch dependency upgrade covering multiple packages. All core tests pass (325/325, 3 skipped). The
uuidpackage has been replaced withlib0/random'suuidv4, which was already a transitive dependency via Yjs, removing an unnecessary direct dependency.Summary by CodeRabbit
Chores
Refactor