UNPKG

@postenbring/hedwig-react

Version:

React components for [Hedwig Design System](https://github.com/bring/hedwig-design-system).

35 lines (33 loc) 955 B
import { __objRest, __spreadProps, __spreadValues } from "./chunk-YOSPWY5K.mjs"; // src/layout/container/container.tsx import { clsx } from "@postenbring/hedwig-css/typed-classname"; import { Slot } from "@radix-ui/react-slot"; import { forwardRef } from "react"; import { jsx } from "react/jsx-runtime"; var Container = forwardRef( (_a, ref) => { var _b = _a, { as: Tag = "div", asChild, className, children, variant } = _b, rest = __objRest(_b, ["as", "asChild", "className", "children", "variant"]); const Component = asChild ? Slot : Tag; return /* @__PURE__ */ jsx( Component, __spreadProps(__spreadValues({}, rest), { className: clsx( "hds-container", { "hds-container--slim": variant === "slim" }, className ), ref, children }) ); } ); Container.displayName = "Container"; export { Container }; //# sourceMappingURL=chunk-4QZR2H72.mjs.map