"use client";
import { jsxs as d, jsx as e } from "react/jsx-runtime";
/* empty css                                                                       */
/* empty css                                                                                   */
/* empty css                                                                                   */
import { Navigation as f } from "swiper/modules";
import { Swiper as g, SwiperSlide as N } from "swiper/react";
import { EIconName as v } from "../../components/Icon/constants.es.js";
import { Label as k } from "../../components/Label/Label.es.js";
import { TextButton as x } from "../../components/TextButton/TextButton.es.js";
import { useSwiper as C } from "../../utils/useSwiper/useSwiper.es.js";
import i from "../../modules/FollowTheScience/followTheScience.module.css";
import { ProgressButton as a } from "../../components/ProgressButton/ProgressButton.es.js";
import { Benefit as R } from "../../components/Benefit/Benefit.es.js";
const B = [f];
function _({ labelText: c, benefits: m }) {
  const {
    setIsEnd: p,
    isEnd: r,
    isBeginning: t,
    hideNav: s,
    handleSlideChange: h,
    handlePrevClick: n,
    handleNextClick: l,
    onSwiperInit: u,
    handleSwiperResize: w
  } = C();
  return /* @__PURE__ */ d("section", { className: i.container, children: [
    /* @__PURE__ */ d("div", { className: i.heading, children: [
      /* @__PURE__ */ e(k, { color: "white", size: "lg", children: c }),
      !s && /* @__PURE__ */ e("div", { className: i.progressButtons, "data-device": "desktop", children: /* @__PURE__ */ e(
        a,
        {
          left: {
            onClick: n,
            disabled: t
          },
          right: {
            disabled: r,
            onClick: l
          }
        }
      ) })
    ] }),
    /* @__PURE__ */ e("div", { className: i.content, children: /* @__PURE__ */ e(
      g,
      {
        onSwiper: u,
        onResize: w,
        onSlideChange: h,
        onReachEnd: () => p(!0),
        modules: B,
        spaceBetween: 0,
        slidesPerView: "auto",
        className: i.swiper,
        children: m.map((o, S) => /* @__PURE__ */ e(N, { className: i.swiperSlide, children: /* @__PURE__ */ e(
          R,
          {
            title: o.title,
            description: o.description,
            button: o.link && o.buttonText ? /* @__PURE__ */ e(
              x,
              {
                as: "a",
                size: "sm",
                color: "white",
                suffixIcon: v.ARROW_FORWARD,
                href: o.link,
                children: o.buttonText
              }
            ) : void 0
          }
        ) }, S))
      }
    ) }),
    !s && /* @__PURE__ */ e("div", { className: i.progressButtons, "data-device": "mobile", children: /* @__PURE__ */ e(
      a,
      {
        left: {
          onClick: n,
          disabled: t
        },
        right: {
          onClick: l,
          disabled: r
        }
      }
    ) })
  ] });
}
export {
  _ as FollowTheScience
};
