@joza/joza-ui-kit 0.1.10 → 0.1.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -77,8 +77,11 @@ const Button2 = ({ label, size = "", style = "", disabled = false, icon: Icon, c
77
77
 
78
78
  var styles$b = {"carousel":"carousel-module_carousel__wqzvf","carousel__track":"carousel-module_carousel__track__tYeyk","carousel__logo":"carousel-module_carousel__logo__Rm8zv"};
79
79
 
80
- const Carousel = ({ imgs }) => {
81
- return (jsxRuntime.jsx("div", { className: styles$b.carousel, children: jsxRuntime.jsx("div", { className: styles$b.carousel__track, children: imgs.map((item, index) => (jsxRuntime.jsx("div", { className: styles$b.carousel__logo, children: jsxRuntime.jsx("img", { src: item.src, alt: item.alt }) }, `first-${index}`))) }) }));
80
+ const Carousel = (props) => {
81
+ const { imgs, ImageComponent } = props;
82
+ // Pas de "as any" : au pire un cast sûr vers ElementType (pas d'any)
83
+ const Img = ImageComponent ?? "img";
84
+ return (jsxRuntime.jsx("div", { className: styles$b.carousel, children: jsxRuntime.jsx("div", { className: styles$b.carousel__track, children: imgs.map((imgProps, index) => (jsxRuntime.jsx("div", { className: styles$b.carousel__logo, children: jsxRuntime.jsx(Img, { ...imgProps }) }, `img-${index}`))) }) }));
82
85
  };
83
86
 
84
87
  /**
@@ -383,7 +386,7 @@ const Section = ({ id, dark = false, backgroundImg, children }) => {
383
386
  const onBackgroundCss = backgroundImg ? `${styles$1.Section__on_background}` : "";
384
387
  const onBackgroundContentCss = backgroundImg ? `${styles$1.Section__on_background__content}` : "";
385
388
  return (jsxRuntime.jsxs("section", { id: id, className: `${darkCss} ${styles$1.Section} ${onBackgroundCss}`, children: [backgroundImg &&
386
- (jsxRuntime.jsxs("div", { className: styles$1.Section__background_img, children: [jsxRuntime.jsx("img", { src: backgroundImg }), jsxRuntime.jsx("div", { className: styles$1.Section__overlay }), jsxRuntime.jsx("div", { className: styles$1.Section__accentGlow })] })), jsxRuntime.jsx("div", { className: styles$1.Section__container + " " + onBackgroundContentCss, children: children })] }));
389
+ (jsxRuntime.jsxs("div", { className: styles$1.Section__background_img, children: [jsxRuntime.jsx("img", { src: backgroundImg.src, alt: backgroundImg.alt }), jsxRuntime.jsx("div", { className: styles$1.Section__overlay }), jsxRuntime.jsx("div", { className: styles$1.Section__accentGlow })] })), jsxRuntime.jsx("div", { className: styles$1.Section__container + " " + onBackgroundContentCss, children: children })] }));
387
390
  };
388
391
 
389
392
  var styles = {"TwoColumns__grid":"two-columns-module_TwoColumns__grid__qsens"};