@trail-ui/react
Version:
22 lines (19 loc) • 737 B
JavaScript
import {
CardContext
} from "./chunk-PLEBMEPB.mjs";
// src/card/card-footer.tsx
import { clsx } from "@trail-ui/shared-utils";
import { forwardRef, useContext } from "react";
import { jsx } from "react/jsx-runtime";
function CardFooter(props, ref) {
var _a;
const { elementType, className, ...otherProps } = props;
const Component = elementType || "div";
const { slots, classNames } = useContext(CardContext);
const footerStyles = clsx(classNames == null ? void 0 : classNames.footer, className);
return /* @__PURE__ */ jsx(Component, { ref, className: (_a = slots.footer) == null ? void 0 : _a.call(slots, { class: footerStyles }), ...otherProps });
}
var _CardFooter = forwardRef(CardFooter);
export {
_CardFooter
};