ai-tool-elements ships a bundled CSS file built with Tailwind CSS v4. Importing it once sets up all the card styles. You can override or extend those styles with your own Tailwind utility classes via theDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/omavashia2005/ai-tool-elements/llms.txt
Use this file to discover all available pages before exploring further.
className prop, or by redefining the underlying CSS custom properties that the card components rely on.
Importing the bundled styles
The bundled stylesheet must be imported once in your application’s entry point before anyToolCard is rendered. Without it, the cards will have no default visual styles.
app/layout.tsx:
src/main.tsx:
Overriding styles with className
ToolCard forwards all props it does not consume directly to the underlying Card element, including className. Any Tailwind utilities or custom classes you pass are merged on top of the default card styles using tailwind-merge, so conflicting utilities resolve predictably.
tailwind-merge internally, passing a utility that targets the same property as a built-in class (e.g. a different border color) will correctly override it rather than producing duplicate declarations.
CSS custom properties
The card’s colors are driven by four CSS custom properties that map to shadcn/ui design tokens. You can redefine them at:root or at any parent scope to change the palette for all cards in that subtree:
| Variable | Controls |
|---|---|
--card | Card background fill |
--card-foreground | Primary text inside the card |
--border | Card border and footer divider |
--muted-foreground | Secondary text: field descriptions and Required/Optional badges |
Dark mode
The bundledstyles.css only declares light-mode defaults for the four CSS custom properties — it does not include a built-in dark-mode block. To support dark mode in your application, redefine the variables under your dark-mode selector or media query in your own stylesheet:
ToolCard on the page.
Card dimensions
ToolCard is fluid by default — it stretches to fill the width of its containing block. To control layout, wrap cards in a grid or flexbox container:
max-w-sm or similar on individual cards when you need a fixed maximum width without a grid.
The library uses Tailwind CSS v4 internally. If your app also uses Tailwind,
the bundled CSS and your app’s CSS coexist without conflict because both
compile to standard CSS — there is no shared runtime or global state between
the two Tailwind instances.