@luscii-healthtech/web-ui 2.43.0 → 2.44.0

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.
@@ -0,0 +1,12 @@
1
+ import React from "react";
2
+ export declare type CardProps = {
3
+ title: string;
4
+ children: React.ReactNode;
5
+ dataTestId?: string;
6
+ };
7
+ /**
8
+ * Card component that centralizes itself inside a container.
9
+ * Specific variant made with w-135 to suffice the use case needed,
10
+ * more variants can be added.
11
+ */
12
+ export declare const Card: React.FC<CardProps>;
package/dist/index.d.ts CHANGED
@@ -77,3 +77,4 @@ export { IconProps } from "./components/Icons/types/IconProps.type";
77
77
  export * from "./components/Icons";
78
78
  export { Divider } from "./components/Divider/Divider";
79
79
  export { FullPageModal } from "./components/Modal/FullPageModal";
80
+ export { Card, type CardProps } from "./components/Card/Card";
@@ -645,6 +645,12 @@ video {
645
645
  margin-left: calc(1rem * calc(1 - var(--space-x-reverse)));
646
646
  }
647
647
 
648
+ .space-y-6 > :not(template) ~ :not(template) {
649
+ --space-y-reverse: 0;
650
+ margin-top: calc(1.5rem * calc(1 - var(--space-y-reverse)));
651
+ margin-bottom: calc(1.5rem * var(--space-y-reverse));
652
+ }
653
+
648
654
  .space-x-6 > :not(template) ~ :not(template) {
649
655
  --space-x-reverse: 0;
650
656
  margin-right: calc(1.5rem * var(--space-x-reverse));
@@ -2218,6 +2224,10 @@ video {
2218
2224
  width: 33rem;
2219
2225
  }
2220
2226
 
2227
+ .w-135 {
2228
+ width: 33.75rem;
2229
+ }
2230
+
2221
2231
  .w-216 {
2222
2232
  width: 54rem;
2223
2233
  }
@@ -6796,7 +6796,7 @@ function GenericForm(_ref) {
6796
6796
  }, [defaultValues]);
6797
6797
  var handleSubmit = useFormReturn.handleSubmit;
6798
6798
  return /*#__PURE__*/React__default.createElement("div", {
6799
- className: "space-y-4"
6799
+ className: "space-y-6"
6800
6800
  }, /*#__PURE__*/React__default.createElement(Form, {
6801
6801
  fields: fields,
6802
6802
  useFormReturn: useFormReturn
@@ -6817,7 +6817,7 @@ function Form(_ref2) {
6817
6817
  var fields = _ref2.fields,
6818
6818
  useFormReturn = _ref2.useFormReturn;
6819
6819
  return /*#__PURE__*/React__default.createElement("div", {
6820
- className: "space-y-4"
6820
+ className: "space-y-6"
6821
6821
  }, fields.map(function (props) {
6822
6822
  return FormFieldMapper(props, useFormReturn);
6823
6823
  }));
@@ -7864,6 +7864,26 @@ var FullPageModal = function FullPageModal(_ref) {
7864
7864
  }, children)));
7865
7865
  };
7866
7866
 
7867
+ /**
7868
+ * Card component that centralizes itself inside a container.
7869
+ * Specific variant made with w-135 to suffice the use case needed,
7870
+ * more variants can be added.
7871
+ */
7872
+
7873
+ var Card = function Card(_ref) {
7874
+ var title = _ref.title,
7875
+ children = _ref.children,
7876
+ dataTestId = _ref.dataTestId;
7877
+ return /*#__PURE__*/React__default.createElement("div", {
7878
+ "data-test-id": dataTestId,
7879
+ className: "flex flex-col p-6 mx-auto bg-white rounded-lg w-135"
7880
+ }, /*#__PURE__*/React__default.createElement(Title, {
7881
+ className: "mb-6",
7882
+ type: "sm",
7883
+ text: title
7884
+ }), children);
7885
+ };
7886
+
7867
7887
  exports.AccordionList = AccordionList;
7868
7888
  exports.AddIcon = AddIcon;
7869
7889
  exports.AlertsIcon = AlertsIcon;
@@ -7872,6 +7892,7 @@ exports.Badge = Badge;
7872
7892
  exports.BellIcon = BellIcon;
7873
7893
  exports.Breadcrumbs = Breadcrumbs;
7874
7894
  exports.CRUDPage = CRUDPage;
7895
+ exports.Card = Card;
7875
7896
  exports.Carousel = Carousel;
7876
7897
  exports.CenteredHero = CenteredHero;
7877
7898
  exports.ChartIcon = ChartIcon;