Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bump: chat-ui and tailwind v4 #509

Merged
merged 6 commits into from
Feb 25, 2025
Merged

Conversation

thucpn
Copy link
Collaborator

@thucpn thucpn commented Feb 24, 2025

Summary by CodeRabbit

  • New Features
    • Introduced a new patch entry for "create-llama" with version bumps for chat-ui and tailwind to version 4.
  • Refactor
    • Enhanced the DeepResearchCard component by removing external dependencies and simplifying state management.
    • Restructured the chat message rendering to utilize a static set of components.
  • Bug Fixes
    • Adjusted various component styles for improved visual consistency and focus behavior.
  • Chores
    • Updated dependencies in the project, including local package management for chat-ui and updates to tailwindcss.
    • Modified CSS integration to improve theming and utility styles.

Copy link

changeset-bot bot commented Feb 24, 2025

🦋 Changeset detected

Latest commit: 4c67434

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
create-llama Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link

coderabbitai bot commented Feb 24, 2025

Walkthrough

This PR introduces a new changeset file (.changeset/rare-eyes-protect.md) with a patch entry labeled "create-llama" that notes a version bump for both chat-ui and tailwind to v4. Additionally, the function used for retrieving tool annotations in the chat tools component has been renamed from getAnnotationData to getChatUIAnnotation. The @llamaindex/chat-ui dependency in the package configuration has been updated from version 0.0.14 to a caret version ^0.2.0, and several CSS class names have been modified across various components to adjust their styling.

Changes

File(s) Change Summary
.changeset/rare-eyes-protect.md Added new changeset file with patch entry "create-llama" and a version bump note for chat-ui and tailwind to v4.
templates/…/chat/tools/chat-tools.tsx Renamed function for tool annotation retrieval (getAnnotationDatagetChatUIAnnotation) and removed parameter from ToolAnnotations.
templates/…/package.json Updated @llamaindex/chat-ui dependency from "0.0.14" to "^0.2.0", removed autoprefixer, added @tailwindcss/postcss, and updated tailwindcss from ^3.3.6 to ^4.0.8.
templates/…/header.tsx
templates/…/button.tsx
templates/…/card.tsx
templates/…/chat/chat-avatar.tsx
templates/…/chat/message-content.tsx
templates/…/input.tsx
templates/…/select.tsx
templates/…/tabs.tsx
templates/…/textarea.tsx
Modified CSS class names for various components to adjust focus outlines and shadows (e.g., focus-visible:outline-nonefocus-visible:outline-hidden, shadowshadow-sm).
templates/…/deep-research-card.tsx Removed message prop from DeepResearchCardProps and updated logic to use useChatMessage hook.
templates/…/globals.css Restructured CSS framework integration, added custom theming, utility styles, and keyframe animations.
templates/…/postcss.config.js Updated PostCSS plugins configuration, replacing tailwindcss and autoprefixer with @tailwindcss/postcss.
templates/…/tailwind.config.ts Removed the tailwind.config.ts file.

Sequence Diagram(s)

(No sequence diagram generated as the changes do not alter the control flow.)

Possibly related PRs

Suggested reviewers

  • marcusschiesser

Poem

I'm a rabbit, hopping through code,
A "create-llama" patch lightens my load,
A function renamed in a gentle bound,
Chat tools and dependencies set sound,
With every hop and tweak so bright,
I celebrate changes from dawn till night 🐰✨.


📜 Recent review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 72bc13d and 4c67434.

📒 Files selected for processing (1)
  • templates/types/streaming/nextjs/package.json (2 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • templates/types/streaming/nextjs/package.json
⏰ Context from checks skipped due to timeout of 90000ms (45)
  • GitHub Check: typescript (20, 3.11, ubuntu-22.04, express, --llamacloud)
  • GitHub Check: typescript (20, 3.11, ubuntu-22.04, express, --example-file)
  • GitHub Check: typescript (20, 3.11, ubuntu-22.04, express, --no-files)
  • GitHub Check: typescript (20, 3.11, ubuntu-22.04, nextjs, --llamacloud)
  • GitHub Check: typescript (20, 3.11, ubuntu-22.04, nextjs, --example-file)
  • GitHub Check: typescript (20, 3.11, ubuntu-22.04, nextjs, --no-files)
  • GitHub Check: typescript (20, 3.11, windows-latest, express, --llamacloud)
  • GitHub Check: typescript (20, 3.11, windows-latest, express, --example-file)
  • GitHub Check: typescript (20, 3.11, windows-latest, express, --no-files)
  • GitHub Check: typescript (20, 3.11, windows-latest, nextjs, --llamacloud)
  • GitHub Check: typescript (20, 3.11, windows-latest, nextjs, --example-file)
  • GitHub Check: typescript (20, 3.11, windows-latest, nextjs, --no-files)
  • GitHub Check: typescript (20, 3.11, macos-latest, express, --llamacloud)
  • GitHub Check: typescript (20, 3.11, macos-latest, express, --example-file)
  • GitHub Check: typescript (20, 3.11, macos-latest, express, --no-files)
  • GitHub Check: typescript (20, 3.11, macos-latest, nextjs, --llamacloud)
  • GitHub Check: typescript (20, 3.11, macos-latest, nextjs, --example-file)
  • GitHub Check: typescript (20, 3.11, macos-latest, nextjs, --no-files)
  • GitHub Check: typescript (18, 3.11, ubuntu-22.04, express, --llamacloud)
  • GitHub Check: typescript (18, 3.11, ubuntu-22.04, express, --example-file)
  • GitHub Check: typescript (18, 3.11, ubuntu-22.04, express, --no-files)
  • GitHub Check: typescript (18, 3.11, ubuntu-22.04, nextjs, --llamacloud)
  • GitHub Check: typescript (18, 3.11, ubuntu-22.04, nextjs, --example-file)
  • GitHub Check: typescript (18, 3.11, ubuntu-22.04, nextjs, --no-files)
  • GitHub Check: typescript (18, 3.11, windows-latest, express, --llamacloud)
  • GitHub Check: typescript (18, 3.11, windows-latest, express, --example-file)
  • GitHub Check: typescript (18, 3.11, windows-latest, express, --no-files)
  • GitHub Check: typescript (18, 3.11, windows-latest, nextjs, --llamacloud)
  • GitHub Check: python (20, 3.11, ubuntu-22.04, fastapi, --llamacloud)
  • GitHub Check: typescript (18, 3.11, windows-latest, nextjs, --example-file)
  • GitHub Check: python (20, 3.11, ubuntu-22.04, fastapi, --example-file)
  • GitHub Check: typescript (18, 3.11, windows-latest, nextjs, --no-files)
  • GitHub Check: python (20, 3.11, ubuntu-22.04, fastapi, --no-files)
  • GitHub Check: typescript (18, 3.11, macos-latest, express, --llamacloud)
  • GitHub Check: python (20, 3.11, windows-latest, fastapi, --llamacloud)
  • GitHub Check: typescript (18, 3.11, macos-latest, express, --example-file)
  • GitHub Check: python (20, 3.11, windows-latest, fastapi, --example-file)
  • GitHub Check: typescript (18, 3.11, macos-latest, express, --no-files)
  • GitHub Check: python (20, 3.11, windows-latest, fastapi, --no-files)
  • GitHub Check: typescript (18, 3.11, macos-latest, nextjs, --llamacloud)
  • GitHub Check: python (20, 3.11, macos-latest, fastapi, --llamacloud)
  • GitHub Check: typescript (18, 3.11, macos-latest, nextjs, --example-file)
  • GitHub Check: python (20, 3.11, macos-latest, fastapi, --example-file)
  • GitHub Check: typescript (18, 3.11, macos-latest, nextjs, --no-files)
  • GitHub Check: python (20, 3.11, macos-latest, fastapi, --no-files)

Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR. (Beta)
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Nitpick comments (2)
templates/types/streaming/nextjs/app/globals.css (1)

64-73: Consider leveraging built-in container classes
Tailwind ships with a default .container utility. This custom rule is fine, but you could reduce complexity by extending Tailwind’s native container in your config.

templates/types/streaming/nextjs/app/components/ui/chat/custom/deep-research-card.tsx (1)

148-155: Consider updating useMemo dependencies.

The useMemo dependency array only includes message.annotations. Consider using the entire message object as a dependency to ensure the state is recalculated if other relevant parts of the message change.

  }, [message.annotations]);
+  }, [message]);
📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 1a63078 and 72bc13d.

📒 Files selected for processing (15)
  • templates/types/streaming/nextjs/app/components/header.tsx (1 hunks)
  • templates/types/streaming/nextjs/app/components/ui/button.tsx (1 hunks)
  • templates/types/streaming/nextjs/app/components/ui/card.tsx (1 hunks)
  • templates/types/streaming/nextjs/app/components/ui/chat/chat-avatar.tsx (1 hunks)
  • templates/types/streaming/nextjs/app/components/ui/chat/chat-message-content.tsx (1 hunks)
  • templates/types/streaming/nextjs/app/components/ui/chat/custom/deep-research-card.tsx (2 hunks)
  • templates/types/streaming/nextjs/app/components/ui/chat/tools/chat-tools.tsx (2 hunks)
  • templates/types/streaming/nextjs/app/components/ui/input.tsx (1 hunks)
  • templates/types/streaming/nextjs/app/components/ui/select.tsx (2 hunks)
  • templates/types/streaming/nextjs/app/components/ui/tabs.tsx (2 hunks)
  • templates/types/streaming/nextjs/app/components/ui/textarea.tsx (1 hunks)
  • templates/types/streaming/nextjs/app/globals.css (1 hunks)
  • templates/types/streaming/nextjs/package.json (2 hunks)
  • templates/types/streaming/nextjs/postcss.config.js (1 hunks)
  • templates/types/streaming/nextjs/tailwind.config.ts (0 hunks)
💤 Files with no reviewable changes (1)
  • templates/types/streaming/nextjs/tailwind.config.ts
✅ Files skipped from review due to trivial changes (4)
  • templates/types/streaming/nextjs/app/components/ui/card.tsx
  • templates/types/streaming/nextjs/app/components/ui/textarea.tsx
  • templates/types/streaming/nextjs/app/components/ui/chat/chat-avatar.tsx
  • templates/types/streaming/nextjs/app/components/header.tsx
🚧 Files skipped from review as they are similar to previous changes (2)
  • templates/types/streaming/nextjs/package.json
  • templates/types/streaming/nextjs/app/components/ui/chat/tools/chat-tools.tsx
🧰 Additional context used
📓 Path-based instructions (1)
`templates/**`: For files under the `templates` folder, do n...

templates/**: For files under the templates folder, do not report 'Missing Dependencies Detected' errors.

  • templates/types/streaming/nextjs/app/components/ui/button.tsx
  • templates/types/streaming/nextjs/app/components/ui/select.tsx
  • templates/types/streaming/nextjs/app/components/ui/input.tsx
  • templates/types/streaming/nextjs/app/components/ui/tabs.tsx
  • templates/types/streaming/nextjs/postcss.config.js
  • templates/types/streaming/nextjs/app/components/ui/chat/chat-message-content.tsx
  • templates/types/streaming/nextjs/app/globals.css
  • templates/types/streaming/nextjs/app/components/ui/chat/custom/deep-research-card.tsx
⏰ Context from checks skipped due to timeout of 90000ms (45)
  • GitHub Check: typescript (20, 3.11, ubuntu-22.04, express, --llamacloud)
  • GitHub Check: typescript (20, 3.11, ubuntu-22.04, express, --example-file)
  • GitHub Check: typescript (20, 3.11, ubuntu-22.04, express, --no-files)
  • GitHub Check: typescript (20, 3.11, ubuntu-22.04, nextjs, --llamacloud)
  • GitHub Check: typescript (20, 3.11, ubuntu-22.04, nextjs, --example-file)
  • GitHub Check: typescript (20, 3.11, ubuntu-22.04, nextjs, --no-files)
  • GitHub Check: typescript (20, 3.11, windows-latest, express, --llamacloud)
  • GitHub Check: typescript (20, 3.11, windows-latest, express, --example-file)
  • GitHub Check: typescript (20, 3.11, windows-latest, express, --no-files)
  • GitHub Check: typescript (20, 3.11, windows-latest, nextjs, --llamacloud)
  • GitHub Check: typescript (20, 3.11, windows-latest, nextjs, --example-file)
  • GitHub Check: typescript (20, 3.11, windows-latest, nextjs, --no-files)
  • GitHub Check: typescript (20, 3.11, macos-latest, express, --llamacloud)
  • GitHub Check: typescript (20, 3.11, macos-latest, express, --example-file)
  • GitHub Check: typescript (20, 3.11, macos-latest, express, --no-files)
  • GitHub Check: typescript (20, 3.11, macos-latest, nextjs, --llamacloud)
  • GitHub Check: typescript (20, 3.11, macos-latest, nextjs, --example-file)
  • GitHub Check: typescript (20, 3.11, macos-latest, nextjs, --no-files)
  • GitHub Check: typescript (18, 3.11, ubuntu-22.04, express, --llamacloud)
  • GitHub Check: typescript (18, 3.11, ubuntu-22.04, express, --example-file)
  • GitHub Check: typescript (18, 3.11, ubuntu-22.04, express, --no-files)
  • GitHub Check: typescript (18, 3.11, ubuntu-22.04, nextjs, --llamacloud)
  • GitHub Check: typescript (18, 3.11, ubuntu-22.04, nextjs, --example-file)
  • GitHub Check: typescript (18, 3.11, ubuntu-22.04, nextjs, --no-files)
  • GitHub Check: typescript (18, 3.11, windows-latest, express, --llamacloud)
  • GitHub Check: typescript (18, 3.11, windows-latest, express, --example-file)
  • GitHub Check: typescript (18, 3.11, windows-latest, express, --no-files)
  • GitHub Check: typescript (18, 3.11, windows-latest, nextjs, --llamacloud)
  • GitHub Check: python (20, 3.11, ubuntu-22.04, fastapi, --llamacloud)
  • GitHub Check: typescript (18, 3.11, windows-latest, nextjs, --example-file)
  • GitHub Check: python (20, 3.11, ubuntu-22.04, fastapi, --example-file)
  • GitHub Check: typescript (18, 3.11, windows-latest, nextjs, --no-files)
  • GitHub Check: python (20, 3.11, ubuntu-22.04, fastapi, --no-files)
  • GitHub Check: typescript (18, 3.11, macos-latest, express, --llamacloud)
  • GitHub Check: python (20, 3.11, windows-latest, fastapi, --llamacloud)
  • GitHub Check: typescript (18, 3.11, macos-latest, express, --example-file)
  • GitHub Check: python (20, 3.11, windows-latest, fastapi, --example-file)
  • GitHub Check: typescript (18, 3.11, macos-latest, express, --no-files)
  • GitHub Check: python (20, 3.11, windows-latest, fastapi, --no-files)
  • GitHub Check: typescript (18, 3.11, macos-latest, nextjs, --llamacloud)
  • GitHub Check: python (20, 3.11, macos-latest, fastapi, --llamacloud)
  • GitHub Check: typescript (18, 3.11, macos-latest, nextjs, --example-file)
  • GitHub Check: python (20, 3.11, macos-latest, fastapi, --example-file)
  • GitHub Check: typescript (18, 3.11, macos-latest, nextjs, --no-files)
  • GitHub Check: python (20, 3.11, macos-latest, fastapi, --no-files)
🔇 Additional comments (16)
templates/types/streaming/nextjs/app/components/ui/input.tsx (1)

14-14:

✅ Verification successful

Verify the validity of the outline-hidden class in Tailwind v4.

The change from focus-visible:outline-none to focus-visible:outline-hidden appears to be related to the Tailwind v4 upgrade. Let's verify if this is a valid class name in the new version.


🌐 Web query:

Does Tailwind CSS v4 support the `outline-hidden` class? What are the valid outline utility classes in Tailwind CSS?

💡 Result:

Yes, Tailwind CSS v4 introduces outline-hidden as a replacement utility class for outline-none from v3[1][4][7]. Here's how these utilities work in v4:

Key changes to outline utilities:

  • outline-hidden: Replaces outline-none behavior from v3 (visually hides while maintaining accessibility)
  • outline-none: Now completely removes outlines (including from forced colors mode)

Valid outline utility classes in Tailwind CSS v4:

outline-hidden      /* Replaces v3's outline-none behavior */
outline-none         /* Now actually removes all outlines */
outline              /* Default 1px solid currentColor */
outline-dashed
outline-dotted
outline-double
outline-{width}      (e.g., outline-2)
outline-offset-{n}   (e.g., outline-offset-2)
outline-{color}      (e.g., outline-blue-500)

Migration example from v3 → v4:

<!-- v3 -->
<input class="focus:outline-none">

<!-- v4 -->
<input class="focus:outline-hidden">

The change ensures proper accessibility support while clarifying intent:

  • Use outline-hidden when you want to hide focus rings visually but keep them accessible
  • Use outline-none only when completely removing outlines (not recommended for interactive elements)[4][9]

Other notable changes affecting outlines:

  1. Default ring width changed from 3px → 1px (use ring-3 to maintain previous size)[1][4]
  2. Outline transitions now include color changes by default[4]
  3. Forced colors mode support requires explicit color definitions[9]

Always test interactive elements after upgrading to ensure proper focus visibility for accessibility compliance[7][9].

Citations:


Tailwind v4 Outline Utility Validated

The change from focus-visible:outline-none to focus-visible:outline-hidden is correct according to Tailwind CSS v4 migration guidelines. In v4, outline-hidden replaces the previous outline-none behavior, ensuring that the element maintains accessibility while visually hiding the outline.

No further changes are required in this snippet.

templates/types/streaming/nextjs/app/components/ui/button.tsx (1)

8-8: Consistent change with input component.

The change from focus-visible:outline-none to focus-visible:outline-hidden matches the similar change in the input component, maintaining consistency across UI components.

templates/types/streaming/nextjs/postcss.config.js (1)

3-3:

✅ Verification successful

Verify PostCSS configuration for Tailwind v4.

The change consolidates the plugins under @tailwindcss/postcss. Let's verify if this is the correct configuration for Tailwind v4.


🌐 Web query:

What is the correct PostCSS configuration for Tailwind CSS v4? Is @tailwindcss/postcss the recommended plugin?

💡 Result:

For Tailwind CSS v4, @tailwindcss/postcss is indeed the recommended PostCSS plugin. Here's how to configure it:

Key Changes in Tailwind CSS v4

  • Dedicated PostCSS Package: The PostCSS integration moved from tailwindcss to @tailwindcss/postcss[3][10].
  • Simpler Configuration: No need for postcss-import or autoprefixer in most cases[3][9].

Step-by-Step Configuration

  1. Install Dependencies:

    npm install tailwindcss @tailwindcss/postcss postcss
  2. PostCSS Config (postcss.config.mjs):

    export default {
      plugins: {
        "@tailwindcss/postcss": {},
      },
    };

    This replaces the older tailwindcss: {} syntax used in v3[3][10].

  3. Import Tailwind CSS:
    Add this to your main CSS file:

    @import "tailwind";

Migration Notes

  • Remove autoprefixer from your configuration unless you need it for legacy browser support[3][9].
  • If migrating from v3:
    // Old (v3)
    - plugins: { tailwindcss: {}, autoprefixer: {} }
    
    // New (v4)
    + plugins: { "@tailwindcss/postcss": {} }

Framework-Specific Recommendations

For Vite users, Tailwind now recommends their dedicated Vite plugin instead of PostCSS:

// vite.config.js
import tailwind from '@tailwindjs/vite';
export default defineConfig({
  plugins: [tailwind()]
});

This provides better performance and developer experience[3][9].

The official documentation confirms this configuration approach as standard for Next.js, Angular, and other PostCSS-based setups[10].

Citations:


Tailwind v4 PostCSS configuration verified.

  • The code in templates/types/streaming/nextjs/postcss.config.js correctly uses @tailwindcss/postcss as recommended for Tailwind CSS v4.
  • The web query confirms that consolidating the configuration under @tailwindcss/postcss replaces the older combination of tailwindcss and autoprefixer.

No further changes are necessary.

templates/types/streaming/nextjs/app/components/ui/tabs.tsx (2)

31-31: Consistent outline change with other components.

The change from focus-visible:outline-none to focus-visible:outline-hidden maintains consistency with similar changes in other UI components.

The change from shadow to shadow-sm reduces the shadow depth, making it more subtle.


46-46: Consistent outline change in TabsContent.

The change from focus-visible:outline-none to focus-visible:outline-hidden maintains consistency with the TabsTrigger component and other UI components.

templates/types/streaming/nextjs/app/components/ui/select.tsx (2)

21-21: Confirm validity of 'focus:outline-hidden'
Tailwind v4 does not provide this utility out of the box. If it's a custom utility class, please ensure it's properly configured or documented to avoid confusion.


120-120: Likewise, confirm 'outline-hidden'
Similar to the above, verify that this custom utility is recognized in your Tailwind v4 setup or plugin configuration.

templates/types/streaming/nextjs/app/components/ui/chat/chat-message-content.tsx (2)

1-1: Check updated import
Ensure @llamaindex/chat-ui is correctly resolved in your build, especially if switching to a local file reference or different version.


7-17: Static subcomponent composition looks good
Rendering a fixed set of child components is simpler. Nice improvement.

templates/types/streaming/nextjs/app/globals.css (5)

1-1: Adopting @import for Tailwind
This approach is compatible with Tailwind v4. No concerns here.


3-3: Verify usage of @source
If this directive is a custom or plugin-specific feature, confirm it's recognized in your current configuration to properly scope styles from '@llamaindex/chat-ui'.


5-5: Check for dark mode conflicts
If you also rely on Tailwind’s built-in dark mode, verify that this custom @custom-variant dark (&:is(.dark *)); does not produce overlapping or conflicting rules.


7-62: Robust custom theme
Defining variables via @theme is a flexible approach. Looks well-structured.


75-91: Border color compatibility layer
Good practice for maintaining consistent visuals while upgrading to Tailwind v4. Keep track of elements that rely on the old default.

templates/types/streaming/nextjs/app/components/ui/chat/custom/deep-research-card.tsx (2)

3-3: LGTM! Import changes align with the component refactoring.

The updated imports correctly reflect the new dependencies needed after removing the message prop.


145-147: LGTM! Clean refactoring using the chat hook.

The use of useChatMessage hook improves the component's design by centralizing message access and reducing prop drilling.

@marcusschiesser marcusschiesser merged commit ee69ce7 into main Feb 25, 2025
47 checks passed
@marcusschiesser marcusschiesser deleted the tp/bump-chat-ui-and-tailwind-v4 branch February 25, 2025 02:38
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.

2 participants