UNPKG

@adyen/adyen-platform-experience-web

Version:

![Platform Experience header](https://github.com/Adyen/adyen-platform-experience-web/assets/7926613/18094965-9e01-450e-8dc9-ea84e6b22c2b)

51 lines (50 loc) 1.41 kB
import { jsx as s } from "../../../external/preact/jsx-runtime/dist/jsxRuntime.module.js"; import { CARD_HEADER as h, CARD_HEADER_CONTENT as o, CARD_TITLE as I, CARD_SUBTITLE as L, CARD_BODY as p, CARD_BODY_WITH_TITLE as n, CARD_FOOTER as d, CARD_BASE_CLASS as f, CARD_NO_PADDING as t, CARD_NO_OUTLINE as B, CARD_FILLED as S } from "./constants.js"; import m from "classnames"; /* empty css */ const Y = ({ title: D, subTitle: _, children: C, footer: A, el: R, renderHeader: a, renderFooter: c, filled: N, noOutline: E, noPadding: i, classNameModifiers: T, testId: l }) => { const O = R || "header"; return /* @__PURE__ */ s( "section", { className: m( f, { [S]: N, [B]: E, [t]: i }, T ), "data-testid": l, children: [ (D || a) && /* @__PURE__ */ s(O, { className: h, children: (D || a) && /* @__PURE__ */ s("div", { className: o, children: [ a || /* @__PURE__ */ s("span", { className: I, children: D }), _ && /* @__PURE__ */ s("div", { className: L, children: _ }) ] }) }), /* @__PURE__ */ s( "div", { className: m(p, { [n]: D || a }), children: C } ), (A || c) && /* @__PURE__ */ s("footer", { className: d, children: c || A }) ] } ); }; export { Y as default };