Skip to content

chore: remove tailwind-merge dependency#254

Merged
aidenybai merged 2 commits intomainfrom
chore/remove-tailwind-merge
Mar 19, 2026
Merged

chore: remove tailwind-merge dependency#254
aidenybai merged 2 commits intomainfrom
chore/remove-tailwind-merge

Conversation

@aidenybai
Copy link
Copy Markdown
Owner

@aidenybai aidenybai commented Mar 19, 2026

Summary

  • Remove tailwind-merge from dependencies and noExternal in tsup config
  • Simplify cn utility to use clsx only
  • Fix tailwindcss import with source(".") directive
  • Add meta.json to .gitignore

Test plan

  • Verify build succeeds without tailwind-merge
  • Confirm styles render correctly with clsx-only cn

Made with Cursor


Note

Medium Risk
Moderate risk because cn no longer resolves Tailwind class conflicts via tailwind-merge, which can subtly change styling in components relying on override ordering. Build/config changes are otherwise straightforward dependency cleanup.

Overview
Removes tailwind-merge from react-grab (dependency + tsup bundling config) and simplifies the cn helper to use clsx only.

Updates Tailwind CSS entry import to @import "tailwindcss" source(".") for correct source resolution, tweaks repo hygiene/docs by adding meta.json to .gitignore, and trims agent/development notes in AGENTS.md.

Written by Cursor Bugbot for commit aa7bc22. This will update automatically on new commits. Configure here.


Summary by cubic

Removed tailwind-merge and migrated react-grab to solid-js 2.0.0-beta.3 with @solidjs/web for a smaller build and simpler reactivity. Also fixed async effect errors and timing/state edge cases.

  • Refactors

    • Upgraded to Solid 2: use @solidjs/web, replace onMount/onCleanup with onSettled (return cleanup), split createEffect into compute/apply, and switch Index to For.
    • Moved to draft-first setStore with storePath; removed batch, on, and createResource with signal+effect replacements.
    • Simplified cn to clsx only; removed tailwind-merge (deps and tsup noExternal), kept solid-js and bippy as no-externals.
    • Fixed styles/build: @import "tailwindcss" source(".") and ignored meta.json.
    • Docs: renamed AGENTS.md section title and removed stale flaky test note.
  • Bug Fixes

    • Added .catch() handlers to async effect replacements for context menu component name/file path lookups.
    • Rebuilt holding timer effect to include keyHoldDuration in compute so timers restart on duration changes.
    • Restored updateLabelInstance to a single atomic draft setter for consistent status/error updates.

Written for commit aa7bc22. Summary will update on new commits.

Simplify cn utility to use clsx only, fix tailwindcss import with
source("."), and gitignore meta.json.

Made-with: Cursor
@vercel
Copy link
Copy Markdown
Contributor

vercel bot commented Mar 19, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
react-grab-website Ready Ready Preview, Comment Mar 19, 2026 11:38pm

@pullfrog
Copy link
Copy Markdown
Contributor

pullfrog bot commented Mar 19, 2026

Error

agent completed without reporting progress

Pullfrog  | Rerun failed job ➔View workflow run | Triggered by Pullfrogpullfrog.com𝕏

@pkg-pr-new
Copy link
Copy Markdown

pkg-pr-new bot commented Mar 19, 2026

Open in StackBlitz

@react-grab/cli

npm i https://pkg.pr.new/aidenybai/react-grab/@react-grab/cli@254

grab

npm i https://pkg.pr.new/aidenybai/react-grab/grab@254

@react-grab/amp

npm i https://pkg.pr.new/aidenybai/react-grab/@react-grab/amp@254

@react-grab/claude-code

npm i https://pkg.pr.new/aidenybai/react-grab/@react-grab/claude-code@254

@react-grab/codex

npm i https://pkg.pr.new/aidenybai/react-grab/@react-grab/codex@254

@react-grab/copilot

npm i https://pkg.pr.new/aidenybai/react-grab/@react-grab/copilot@254

@react-grab/cursor

npm i https://pkg.pr.new/aidenybai/react-grab/@react-grab/cursor@254

@react-grab/droid

npm i https://pkg.pr.new/aidenybai/react-grab/@react-grab/droid@254

@react-grab/gemini

npm i https://pkg.pr.new/aidenybai/react-grab/@react-grab/gemini@254

@react-grab/opencode

npm i https://pkg.pr.new/aidenybai/react-grab/@react-grab/opencode@254

react-grab

npm i https://pkg.pr.new/aidenybai/react-grab@254

@react-grab/relay

npm i https://pkg.pr.new/aidenybai/react-grab/@react-grab/relay@254

@react-grab/utils

npm i https://pkg.pr.new/aidenybai/react-grab/@react-grab/utils@254

commit: aa7bc22

Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 6 files

Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

7 issues found across 22 files (changes from recent commits).

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="packages/react-grab/src/components/tooltip.tsx">

<violation number="1" location="packages/react-grab/src/components/tooltip.tsx:28">
P0: Malformed `createEffect` call. The visibility logic is passed as the initial value instead of the effect function, so the tooltip will never appear.</violation>
</file>

<file name="packages/react-grab/src/utils/create-anchored-dropdown.ts">

<violation number="1" location="packages/react-grab/src/utils/create-anchored-dropdown.ts:1">
P1: Restore the `onCleanup` import. SolidJS requires `onCleanup` for effect cleanups, unlike React which uses returned functions.</violation>

<violation number="2" location="packages/react-grab/src/utils/create-anchored-dropdown.ts:63">
P0: This effect will never run because its logic is passed as the initial value argument. SolidJS `createEffect` requires a single callback, and cleanups must be registered with `onCleanup`.</violation>
</file>

<file name="packages/react-grab/src/components/renderer.tsx">

<violation number="1" location="packages/react-grab/src/components/renderer.tsx:1">
P0: Revert the `<For>` components back to `<Index>`. The change to `<For>` will cause runtime `TypeError` crashes because the inner code expects list items to be accessor functions, which only `<Index>` provides.</violation>
</file>

<file name="packages/react-grab/src/components/toolbar/index.tsx">

<violation number="1" location="packages/react-grab/src/components/toolbar/index.tsx:219">
P1: Returning a function from `createEffect` does not register it as a cleanup in SolidJS. You must use `onCleanup`.</violation>

<violation number="2" location="packages/react-grab/src/components/toolbar/index.tsx:353">
P1: Returning a function from `createEffect` does not register a cleanup in SolidJS. You must use `onCleanup`.</violation>

<violation number="3" location="packages/react-grab/src/components/toolbar/index.tsx:467">
P1: Returning a function from `createEffect` does not register a cleanup in SolidJS. You must use `onCleanup`.</violation>
</file>

Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.

clearTimeout(delayTimeoutId);
delayTimeoutId = undefined;
}
() => props.visible,
Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai bot Mar 19, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P0: Malformed createEffect call. The visibility logic is passed as the initial value instead of the effect function, so the tooltip will never appear.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At packages/react-grab/src/components/tooltip.tsx, line 28:

<comment>Malformed `createEffect` call. The visibility logic is passed as the initial value instead of the effect function, so the tooltip will never appear.</comment>

<file context>
@@ -25,32 +25,30 @@ export const Tooltip: Component<TooltipProps> = (props) => {
-          clearTimeout(delayTimeoutId);
-          delayTimeoutId = undefined;
-        }
+    () => props.visible,
+    (isVisible) => {
+      if (delayTimeoutId !== undefined) {
</file context>
Fix with Cubic

}
onCleanup(clearAnimationHandles);
});
createEffect(
Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai bot Mar 19, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P0: This effect will never run because its logic is passed as the initial value argument. SolidJS createEffect requires a single callback, and cleanups must be registered with onCleanup.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At packages/react-grab/src/utils/create-anchored-dropdown.ts, line 63:

<comment>This effect will never run because its logic is passed as the initial value argument. SolidJS `createEffect` requires a single callback, and cleanups must be registered with `onCleanup`.</comment>

<file context>
@@ -60,51 +60,55 @@ export const createAnchoredDropdown = (
-    }
-    onCleanup(clearAnimationHandles);
-  });
+  createEffect(
+    () => anchorAccessor(),
+    (anchor) => {
</file context>
Fix with Cubic

@@ -1,4 +1,4 @@
import { Show, Index } from "solid-js";
import { Show, For } from "solid-js";
Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai bot Mar 19, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P0: Revert the <For> components back to <Index>. The change to <For> will cause runtime TypeError crashes because the inner code expects list items to be accessor functions, which only <Index> provides.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At packages/react-grab/src/components/renderer.tsx, line 1:

<comment>Revert the `<For>` components back to `<Index>`. The change to `<For>` will cause runtime `TypeError` crashes because the inner code expects list items to be accessor functions, which only `<Index>` provides.</comment>

<file context>
@@ -1,4 +1,4 @@
-import { Show, Index } from "solid-js";
+import { Show, For } from "solid-js";
 import type { Component } from "solid-js";
 import type { AgentSession, ReactGrabRendererProps } from "../types.js";
</file context>
Fix with Cubic

@@ -1,4 +1,4 @@
import { createSignal, createEffect, createMemo, onCleanup } from "solid-js";
import { createSignal, createEffect, createMemo } from "solid-js";
Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai bot Mar 19, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1: Restore the onCleanup import. SolidJS requires onCleanup for effect cleanups, unlike React which uses returned functions.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At packages/react-grab/src/utils/create-anchored-dropdown.ts, line 1:

<comment>Restore the `onCleanup` import. SolidJS requires `onCleanup` for effect cleanups, unlike React which uses returned functions.</comment>

<file context>
@@ -1,4 +1,4 @@
-import { createSignal, createEffect, createMemo, onCleanup } from "solid-js";
+import { createSignal, createEffect, createMemo } from "solid-js";
 import type { Accessor } from "solid-js";
 import type { DropdownAnchor } from "../types.js";
</file context>
Fix with Cubic

Comment on lines +467 to +471
return () => {
clearTimeout(timerId);
setIsHistoryTooltipVisible(false);
};
},
Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai bot Mar 19, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1: Returning a function from createEffect does not register a cleanup in SolidJS. You must use onCleanup.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At packages/react-grab/src/components/toolbar/index.tsx, line 467:

<comment>Returning a function from `createEffect` does not register a cleanup in SolidJS. You must use `onCleanup`.</comment>

<file context>
@@ -460,51 +450,49 @@ export const Toolbar: Component<ToolbarProps> = (props) => {
+        clockFlashRef?.classList.remove("animate-clock-flash");
+        setIsHistoryTooltipVisible(false);
+      }, FEEDBACK_DURATION_MS);
+      return () => {
+        clearTimeout(timerId);
+        setIsHistoryTooltipVisible(false);
</file context>
Suggested change
return () => {
clearTimeout(timerId);
setIsHistoryTooltipVisible(false);
};
},
onCleanup(() => {
if (historyItemCountTimeout) {
clearTimeout(historyItemCountTimeout);
}
});
Fix with Cubic

shakeTooltipTimeout = setTimeout(() => {
setIsShakeTooltipVisible(false);
}, TOOLBAR_SHAKE_TOOLTIP_DURATION_MS);
return () => clearShakeTooltipTimeout();
Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai bot Mar 19, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1: Returning a function from createEffect does not register a cleanup in SolidJS. You must use onCleanup.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At packages/react-grab/src/components/toolbar/index.tsx, line 353:

<comment>Returning a function from `createEffect` does not register a cleanup in SolidJS. You must use `onCleanup`.</comment>

<file context>
@@ -342,47 +340,39 @@ export const Toolbar: Component<ToolbarProps> = (props) => {
+        shakeTooltipTimeout = setTimeout(() => {
+          setIsShakeTooltipVisible(false);
+        }, TOOLBAR_SHAKE_TOOLTIP_DURATION_MS);
+        return () => clearShakeTooltipTimeout();
+      }
+    },
</file context>
Suggested change
return () => clearShakeTooltipTimeout();
onCleanup(() => clearShakeTooltipTimeout());
Fix with Cubic

(previousIndex) => (previousIndex + 1) % SELECTION_HINT_COUNT,
);
}, SELECTION_HINT_CYCLE_INTERVAL_MS);
return () => clearInterval(intervalId);
Copy link
Copy Markdown
Contributor

@cubic-dev-ai cubic-dev-ai bot Mar 19, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1: Returning a function from createEffect does not register it as a cleanup in SolidJS. You must use onCleanup.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At packages/react-grab/src/components/toolbar/index.tsx, line 219:

<comment>Returning a function from `createEffect` does not register it as a cleanup in SolidJS. You must use `onCleanup`.</comment>

<file context>
@@ -206,22 +205,21 @@ export const Toolbar: Component<ToolbarProps> = (props) => {
+          (previousIndex) => (previousIndex + 1) % SELECTION_HINT_COUNT,
+        );
+      }, SELECTION_HINT_CYCLE_INTERVAL_MS);
+      return () => clearInterval(intervalId);
+    },
+    undefined,
</file context>
Suggested change
return () => clearInterval(intervalId);
onCleanup(() => clearInterval(intervalId));
Fix with Cubic

Copy link
Copy Markdown

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 2 potential issues.

Fix All in Cursor

Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Copy link
Copy Markdown
Contributor

@vercel vercel bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Additional Suggestions:

  1. The design-system package uses outdated Solid 1.9.10 dependencies and imports from non-existent 'solid-js/web' path, causing build failures when bundling upgraded react-grab code that was migrated to Solid 2.0.0-beta.3
  1. Missing @solidjs/web in design-system's tsup noExternal configuration causing bundle resolution failures after react-grab was updated to Solid 2.0

Fix on Vercel

Rename "Cursor Cloud specific instructions" to "Development instructions"
and remove outdated "Known flaky test" section.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@aidenybai aidenybai force-pushed the chore/remove-tailwind-merge branch from 122b66a to aa7bc22 Compare March 19, 2026 23:37
@aidenybai aidenybai mentioned this pull request Mar 19, 2026
4 tasks
@aidenybai aidenybai merged commit 633c5f2 into main Mar 19, 2026
15 checks passed
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