// ../src/helpers/formatClassString.ts
var formatClassString = (classesArray) => {
  return classesArray.filter((x) => !!x).join(" ");
};

// ../src/foundations/icons/sprite.svg
import { h } from "preact";
import { jsx, jsxs } from "preact/jsx-runtime";

// ../src/components/icon-sprite/icon-sprite.tsx
import { jsx as jsx2 } from "preact/jsx-runtime";
var IconUse = ({ iconName, classNames, attributes }) => {
  const componentClassName = "ds-icon";
  const classes = formatClassString([
    componentClassName,
    `${componentClassName}--sprite`,
    `${componentClassName}--${iconName}`,
    classNames
  ]);
  return /* @__PURE__ */ jsx2("i", { className: classes, ...attributes, children: /* @__PURE__ */ jsx2("svg", { children: /* @__PURE__ */ jsx2("use", { xlinkHref: `#ds-${iconName}` }) }) });
};

// ../src/components/teaser-dot/teaser-dot.tsx
import { jsx as jsx3 } from "preact/jsx-runtime";

// ../src/helpers/teaser.tsx
import { Fragment, jsx as jsx4, jsxs as jsxs2 } from "preact/jsx-runtime";
var Media = ({ media, rounded, isSquareImage }) => {
  const classNames = formatClassString([
    "ds-teaser__media",
    rounded && "ds-teaser__media--rounded",
    isSquareImage && "ds-teaser__media--square-image"
  ]);
  return media ? /* @__PURE__ */ jsx4("div", { className: classNames, children: media }) : null;
};
var Content = ({ children, bylinePicture }) => {
  return /* @__PURE__ */ jsxs2("div", { className: "ds-teaser__content", children: [
    /* @__PURE__ */ jsx4("div", { className: "ds-teaser__content-inner", children }),
    bylinePicture && /* @__PURE__ */ jsx4("div", { className: "ds-teaser__byline", children: bylinePicture })
  ] });
};
var Title = ({ title, highlight, isItalicHeadline }) => {
  return title ? /* @__PURE__ */ jsxs2("h2", { className: `ds-teaser__title ${isItalicHeadline ? "ds-teaser__title--italic" : ""}`, children: [
    highlight && /* @__PURE__ */ jsxs2("span", { className: "ds-teaser__highlight", children: [
      highlight,
      " "
    ] }),
    title
  ] }) : null;
};
var Vignette = ({ vignette, variant }) => {
  return vignette ? /* @__PURE__ */ jsxs2("div", { className: "ds-teaser__vignette", children: [
    variant === "podcast" && /* @__PURE__ */ jsx4(IconUse, { iconName: "headphones" }),
    vignette
  ] }) : null;
};

// ../src/components/teaser-card/teaser-card.tsx
import { jsx as jsx5 } from "preact/jsx-runtime";
var TeaserCard = ({ areaType, targetLink, theme, classNames, attributes, children }) => {
  const componentClassName = "ds-teaser";
  const classes = formatClassString([
    componentClassName,
    areaType && areaType !== "main" && `${componentClassName}--${areaType}`,
    areaType == "bauta" && "ds-dark",
    theme && `ds-theme--${theme}`,
    classNames
  ]);
  if (targetLink) {
    return /* @__PURE__ */ jsx5("a", { className: classes, href: targetLink, ...attributes, children });
  }
  return /* @__PURE__ */ jsx5("div", { className: classes, ...attributes, children });
};

// ../src/components/teaser-longlife/teaser-longlife.tsx
import { jsx as jsx6, jsxs as jsxs3 } from "preact/jsx-runtime";
var TeaserLonglife = (props) => {
  const { title, targetLink, vignette, media, attributes, classNames } = props;
  const classes = formatClassString(["ds-teaser--longlife", classNames]);
  return /* @__PURE__ */ jsxs3(TeaserCard, { areaType: "right", targetLink, classNames: classes, attributes, children: [
    /* @__PURE__ */ jsx6(Media, { media }),
    /* @__PURE__ */ jsxs3(Content, { children: [
      /* @__PURE__ */ jsx6(Vignette, { vignette }),
      /* @__PURE__ */ jsx6(Title, { title })
    ] })
  ] });
};
export {
  TeaserLonglife
};
//# sourceMappingURL=teaser-longlife.js.map
