eai-frontend-components 2.0.93 → 2.0.94
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.esm.js +2 -1
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +2 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -10179,7 +10179,8 @@ const NotFound = () => {
|
|
|
10179
10179
|
};
|
|
10180
10180
|
|
|
10181
10181
|
function NodeCard({ node, onNodeClick, isExpanded, hasChildren, onToggle, searchTerm }) {
|
|
10182
|
-
const isHighlighted = !!searchTerm?.trim() &&
|
|
10182
|
+
const isHighlighted = !!searchTerm?.trim() &&
|
|
10183
|
+
(node.title.toLowerCase().includes(searchTerm.toLowerCase()) || node.description?.toLowerCase().includes(searchTerm.toLowerCase()));
|
|
10183
10184
|
return (jsxRuntime.jsx(Card, { className: cn('w-44 border transition-colors', onNodeClick && 'cursor-pointer hover:border-primary', isHighlighted && 'border-primary bg-primary/10'), onClick: () => onNodeClick?.(node), children: jsxRuntime.jsxs(CardContent, { className: 'flex flex-col gap-1.5 p-3', children: [jsxRuntime.jsx("div", { className: 'flex items-start justify-between gap-1', children: jsxRuntime.jsx(TooltipProvider, { children: jsxRuntime.jsxs(Tooltip, { children: [jsxRuntime.jsx(TooltipTrigger, { asChild: true, children: jsxRuntime.jsx("span", { className: 'line-clamp-2 text-sm font-medium leading-snug', children: node.title }) }), jsxRuntime.jsx(TooltipContent, { side: 'top', children: node.title })] }) }) }), node.description && jsxRuntime.jsx("p", { className: 'line-clamp-1 text-xs text-muted-foreground', children: node.description }), node.badges && (jsxRuntime.jsx("div", { className: 'flex justify-between gap-2', children: node.badges.map((badge, index) => (jsxRuntime.jsxs(Badge, { variant: badge.variant ?? 'secondary', className: 'mt-0.5 shrink-0 text-xs', children: [badge.icon && jsxRuntime.jsx("span", { className: 'mr-1', children: badge.icon }), badge.label] }, index))) })), node.icon && jsxRuntime.jsx("div", { className: 'text-muted-foreground', children: node.icon }), hasChildren && (jsxRuntime.jsx("div", { className: 'flex justify-center pt-0.5', children: jsxRuntime.jsx(Button, { type: 'button', variant: 'ghost', size: 'icon', className: 'h-5 w-5', onClick: (e) => {
|
|
10184
10185
|
e.stopPropagation();
|
|
10185
10186
|
onToggle();
|