UNPKG

@llamaindex/ui

Version:

A comprehensive UI component library built with React, TypeScript, and Tailwind CSS for LlamaIndex applications

86 lines (83 loc) 2.47 kB
import { cn } from './chunk-MG2ARK3A.mjs'; import { __objRest, __spreadValues } from './chunk-JD6AELXS.mjs'; import { jsx } from 'react/jsx-runtime'; function Card(_a) { var _b = _a, { className } = _b, props = __objRest(_b, ["className"]); return /* @__PURE__ */ jsx( "div", __spreadValues({ "data-slot": "card", className: cn( "bg-card text-card-foreground flex flex-col gap-6 rounded-xl border py-6 shadow-sm", className ) }, props) ); } function CardHeader(_a) { var _b = _a, { className } = _b, props = __objRest(_b, ["className"]); return /* @__PURE__ */ jsx( "div", __spreadValues({ "data-slot": "card-header", className: cn( "@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-start gap-1.5 px-6 has-data-[slot=card-action]:grid-cols-[1fr_auto] [.border-b]:pb-6", className ) }, props) ); } function CardTitle(_a) { var _b = _a, { className } = _b, props = __objRest(_b, ["className"]); return /* @__PURE__ */ jsx( "div", __spreadValues({ "data-slot": "card-title", className: cn("leading-none font-semibold", className) }, props) ); } function CardDescription(_a) { var _b = _a, { className } = _b, props = __objRest(_b, ["className"]); return /* @__PURE__ */ jsx( "div", __spreadValues({ "data-slot": "card-description", className: cn("text-muted-foreground text-sm", className) }, props) ); } function CardAction(_a) { var _b = _a, { className } = _b, props = __objRest(_b, ["className"]); return /* @__PURE__ */ jsx( "div", __spreadValues({ "data-slot": "card-action", className: cn( "col-start-2 row-span-2 row-start-1 self-start justify-self-end", className ) }, props) ); } function CardContent(_a) { var _b = _a, { className } = _b, props = __objRest(_b, ["className"]); return /* @__PURE__ */ jsx( "div", __spreadValues({ "data-slot": "card-content", className: cn("px-6", className) }, props) ); } function CardFooter(_a) { var _b = _a, { className } = _b, props = __objRest(_b, ["className"]); return /* @__PURE__ */ jsx( "div", __spreadValues({ "data-slot": "card-footer", className: cn("flex items-center px-6 [.border-t]:pt-6", className) }, props) ); } export { Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle };