@rehagro/ui 0.1.0 → 0.1.1

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.
package/dist/index.d.mts CHANGED
@@ -336,6 +336,85 @@ type TooltipProps = {
336
336
  };
337
337
  declare const Tooltip: React$1.ForwardRefExoticComponent<TooltipProps & React$1.RefAttributes<HTMLDivElement>>;
338
338
 
339
+ type ContainerProps = React$1.HTMLAttributes<HTMLDivElement> & {
340
+ /**
341
+ * Remove o padding horizontal lateral.
342
+ * Use quando o conteúdo deve ocupar toda a largura disponível.
343
+ */
344
+ fluid?: boolean;
345
+ };
346
+ declare const Container: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLDivElement> & {
347
+ /**
348
+ * Remove o padding horizontal lateral.
349
+ * Use quando o conteúdo deve ocupar toda a largura disponível.
350
+ */
351
+ fluid?: boolean;
352
+ } & React$1.RefAttributes<HTMLDivElement>>;
353
+
354
+ type GridContainerProps = React$1.HTMLAttributes<HTMLDivElement> & {
355
+ /**
356
+ * Override do número de colunas.
357
+ * Padrão: 4 no mobile, 12 no desktop (desktop-xs+).
358
+ */
359
+ columns?: 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12;
360
+ /**
361
+ * Gap entre as colunas em pixels.
362
+ * Padrão: 16px no mobile, 24px no desktop.
363
+ */
364
+ spacing?: number;
365
+ };
366
+ declare const GridContainer: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLDivElement> & {
367
+ /**
368
+ * Override do número de colunas.
369
+ * Padrão: 4 no mobile, 12 no desktop (desktop-xs+).
370
+ */
371
+ columns?: 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12;
372
+ /**
373
+ * Gap entre as colunas em pixels.
374
+ * Padrão: 16px no mobile, 24px no desktop.
375
+ */
376
+ spacing?: number;
377
+ } & React$1.RefAttributes<HTMLDivElement>>;
378
+
379
+ type GridSpan = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12;
380
+ type MobileSpan = 1 | 2 | 3 | 4;
381
+ type GridItemProps = React$1.HTMLAttributes<HTMLDivElement> & {
382
+ /** Span base no mobile (320px+). Padrão: 4 (full width das 4 colunas). */
383
+ mobile?: MobileSpan;
384
+ /** Span a partir de mobile-sm (360px+). */
385
+ mobileSm?: MobileSpan;
386
+ /** Span a partir de mobile-md (390px+). */
387
+ mobileMd?: MobileSpan;
388
+ /** Span a partir de mobile-lg (430px+). */
389
+ mobileLg?: MobileSpan;
390
+ /** Span a partir de desktop-xs (768px+). Padrão: 12 (full width das 12 colunas). */
391
+ desktop?: GridSpan;
392
+ /** Span a partir de desktop-sm (1024px+). */
393
+ desktopSm?: GridSpan;
394
+ /** Span a partir de desktop-md (1280px+). */
395
+ desktopMd?: GridSpan;
396
+ /** Span a partir de desktop-lg (1440px+). */
397
+ desktopLg?: GridSpan;
398
+ };
399
+ declare const GridItem: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLDivElement> & {
400
+ /** Span base no mobile (320px+). Padrão: 4 (full width das 4 colunas). */
401
+ mobile?: MobileSpan;
402
+ /** Span a partir de mobile-sm (360px+). */
403
+ mobileSm?: MobileSpan;
404
+ /** Span a partir de mobile-md (390px+). */
405
+ mobileMd?: MobileSpan;
406
+ /** Span a partir de mobile-lg (430px+). */
407
+ mobileLg?: MobileSpan;
408
+ /** Span a partir de desktop-xs (768px+). Padrão: 12 (full width das 12 colunas). */
409
+ desktop?: GridSpan;
410
+ /** Span a partir de desktop-sm (1024px+). */
411
+ desktopSm?: GridSpan;
412
+ /** Span a partir de desktop-md (1280px+). */
413
+ desktopMd?: GridSpan;
414
+ /** Span a partir de desktop-lg (1440px+). */
415
+ desktopLg?: GridSpan;
416
+ } & React$1.RefAttributes<HTMLDivElement>>;
417
+
339
418
  type IconProps = React$1.SVGAttributes<SVGSVGElement>;
340
419
 
341
420
  declare const DeleteIcon: (props: IconProps) => react_jsx_runtime.JSX.Element;
@@ -358,4 +437,4 @@ declare const NeutralIcon: (props: IconProps) => react_jsx_runtime.JSX.Element;
358
437
 
359
438
  declare const CloseIcon: (props: IconProps) => react_jsx_runtime.JSX.Element;
360
439
 
361
- export { Button, type ButtonProps, type ButtonRadius, type ButtonSize, type ButtonVariant, Checkbox, type CheckboxProps, type CheckboxSize, CloseIcon, DeleteIcon, EditIcon, ErrorIcon, IconButton, type IconButtonColor, type IconButtonProps, type IconButtonRadius, type IconButtonSize, type IconButtonVariant, type IconProps, InfoIcon, NeutralIcon, PlusIcon, RehagroProvider, type RehagroProviderProps, type RehagroTheme, SearchIcon, Select, type SelectMultipleProps, type SelectOption, type SelectProps, type SelectRadius, type SelectSingleProps, type SelectSize, type SelectStatus, SuccessIcon, TextInput, type TextInputProps, type TextInputRadius, type TextInputSize, type TextInputStatus, Toast, type ToastAppearance, ToastContainer, type ToastFn, type ToastItem, type ToastLink, type ToastOptions, type ToastPosition, type ToastProps, ToastProvider, type ToastProviderProps, type ToastVariant, Tooltip, type TooltipPlacement, type TooltipProps, type TooltipSize, type TooltipVariant, WarningIcon, useToast };
440
+ export { Button, type ButtonProps, type ButtonRadius, type ButtonSize, type ButtonVariant, Checkbox, type CheckboxProps, type CheckboxSize, CloseIcon, Container, type ContainerProps, DeleteIcon, EditIcon, ErrorIcon, GridContainer, type GridContainerProps, GridItem, type GridItemProps, type GridSpan, IconButton, type IconButtonColor, type IconButtonProps, type IconButtonRadius, type IconButtonSize, type IconButtonVariant, type IconProps, InfoIcon, type MobileSpan, NeutralIcon, PlusIcon, RehagroProvider, type RehagroProviderProps, type RehagroTheme, SearchIcon, Select, type SelectMultipleProps, type SelectOption, type SelectProps, type SelectRadius, type SelectSingleProps, type SelectSize, type SelectStatus, SuccessIcon, TextInput, type TextInputProps, type TextInputRadius, type TextInputSize, type TextInputStatus, Toast, type ToastAppearance, ToastContainer, type ToastFn, type ToastItem, type ToastLink, type ToastOptions, type ToastPosition, type ToastProps, ToastProvider, type ToastProviderProps, type ToastVariant, Tooltip, type TooltipPlacement, type TooltipProps, type TooltipSize, type TooltipVariant, WarningIcon, useToast };
package/dist/index.d.ts CHANGED
@@ -336,6 +336,85 @@ type TooltipProps = {
336
336
  };
337
337
  declare const Tooltip: React$1.ForwardRefExoticComponent<TooltipProps & React$1.RefAttributes<HTMLDivElement>>;
338
338
 
339
+ type ContainerProps = React$1.HTMLAttributes<HTMLDivElement> & {
340
+ /**
341
+ * Remove o padding horizontal lateral.
342
+ * Use quando o conteúdo deve ocupar toda a largura disponível.
343
+ */
344
+ fluid?: boolean;
345
+ };
346
+ declare const Container: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLDivElement> & {
347
+ /**
348
+ * Remove o padding horizontal lateral.
349
+ * Use quando o conteúdo deve ocupar toda a largura disponível.
350
+ */
351
+ fluid?: boolean;
352
+ } & React$1.RefAttributes<HTMLDivElement>>;
353
+
354
+ type GridContainerProps = React$1.HTMLAttributes<HTMLDivElement> & {
355
+ /**
356
+ * Override do número de colunas.
357
+ * Padrão: 4 no mobile, 12 no desktop (desktop-xs+).
358
+ */
359
+ columns?: 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12;
360
+ /**
361
+ * Gap entre as colunas em pixels.
362
+ * Padrão: 16px no mobile, 24px no desktop.
363
+ */
364
+ spacing?: number;
365
+ };
366
+ declare const GridContainer: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLDivElement> & {
367
+ /**
368
+ * Override do número de colunas.
369
+ * Padrão: 4 no mobile, 12 no desktop (desktop-xs+).
370
+ */
371
+ columns?: 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12;
372
+ /**
373
+ * Gap entre as colunas em pixels.
374
+ * Padrão: 16px no mobile, 24px no desktop.
375
+ */
376
+ spacing?: number;
377
+ } & React$1.RefAttributes<HTMLDivElement>>;
378
+
379
+ type GridSpan = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12;
380
+ type MobileSpan = 1 | 2 | 3 | 4;
381
+ type GridItemProps = React$1.HTMLAttributes<HTMLDivElement> & {
382
+ /** Span base no mobile (320px+). Padrão: 4 (full width das 4 colunas). */
383
+ mobile?: MobileSpan;
384
+ /** Span a partir de mobile-sm (360px+). */
385
+ mobileSm?: MobileSpan;
386
+ /** Span a partir de mobile-md (390px+). */
387
+ mobileMd?: MobileSpan;
388
+ /** Span a partir de mobile-lg (430px+). */
389
+ mobileLg?: MobileSpan;
390
+ /** Span a partir de desktop-xs (768px+). Padrão: 12 (full width das 12 colunas). */
391
+ desktop?: GridSpan;
392
+ /** Span a partir de desktop-sm (1024px+). */
393
+ desktopSm?: GridSpan;
394
+ /** Span a partir de desktop-md (1280px+). */
395
+ desktopMd?: GridSpan;
396
+ /** Span a partir de desktop-lg (1440px+). */
397
+ desktopLg?: GridSpan;
398
+ };
399
+ declare const GridItem: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTMLDivElement> & {
400
+ /** Span base no mobile (320px+). Padrão: 4 (full width das 4 colunas). */
401
+ mobile?: MobileSpan;
402
+ /** Span a partir de mobile-sm (360px+). */
403
+ mobileSm?: MobileSpan;
404
+ /** Span a partir de mobile-md (390px+). */
405
+ mobileMd?: MobileSpan;
406
+ /** Span a partir de mobile-lg (430px+). */
407
+ mobileLg?: MobileSpan;
408
+ /** Span a partir de desktop-xs (768px+). Padrão: 12 (full width das 12 colunas). */
409
+ desktop?: GridSpan;
410
+ /** Span a partir de desktop-sm (1024px+). */
411
+ desktopSm?: GridSpan;
412
+ /** Span a partir de desktop-md (1280px+). */
413
+ desktopMd?: GridSpan;
414
+ /** Span a partir de desktop-lg (1440px+). */
415
+ desktopLg?: GridSpan;
416
+ } & React$1.RefAttributes<HTMLDivElement>>;
417
+
339
418
  type IconProps = React$1.SVGAttributes<SVGSVGElement>;
340
419
 
341
420
  declare const DeleteIcon: (props: IconProps) => react_jsx_runtime.JSX.Element;
@@ -358,4 +437,4 @@ declare const NeutralIcon: (props: IconProps) => react_jsx_runtime.JSX.Element;
358
437
 
359
438
  declare const CloseIcon: (props: IconProps) => react_jsx_runtime.JSX.Element;
360
439
 
361
- export { Button, type ButtonProps, type ButtonRadius, type ButtonSize, type ButtonVariant, Checkbox, type CheckboxProps, type CheckboxSize, CloseIcon, DeleteIcon, EditIcon, ErrorIcon, IconButton, type IconButtonColor, type IconButtonProps, type IconButtonRadius, type IconButtonSize, type IconButtonVariant, type IconProps, InfoIcon, NeutralIcon, PlusIcon, RehagroProvider, type RehagroProviderProps, type RehagroTheme, SearchIcon, Select, type SelectMultipleProps, type SelectOption, type SelectProps, type SelectRadius, type SelectSingleProps, type SelectSize, type SelectStatus, SuccessIcon, TextInput, type TextInputProps, type TextInputRadius, type TextInputSize, type TextInputStatus, Toast, type ToastAppearance, ToastContainer, type ToastFn, type ToastItem, type ToastLink, type ToastOptions, type ToastPosition, type ToastProps, ToastProvider, type ToastProviderProps, type ToastVariant, Tooltip, type TooltipPlacement, type TooltipProps, type TooltipSize, type TooltipVariant, WarningIcon, useToast };
440
+ export { Button, type ButtonProps, type ButtonRadius, type ButtonSize, type ButtonVariant, Checkbox, type CheckboxProps, type CheckboxSize, CloseIcon, Container, type ContainerProps, DeleteIcon, EditIcon, ErrorIcon, GridContainer, type GridContainerProps, GridItem, type GridItemProps, type GridSpan, IconButton, type IconButtonColor, type IconButtonProps, type IconButtonRadius, type IconButtonSize, type IconButtonVariant, type IconProps, InfoIcon, type MobileSpan, NeutralIcon, PlusIcon, RehagroProvider, type RehagroProviderProps, type RehagroTheme, SearchIcon, Select, type SelectMultipleProps, type SelectOption, type SelectProps, type SelectRadius, type SelectSingleProps, type SelectSize, type SelectStatus, SuccessIcon, TextInput, type TextInputProps, type TextInputRadius, type TextInputSize, type TextInputStatus, Toast, type ToastAppearance, ToastContainer, type ToastFn, type ToastItem, type ToastLink, type ToastOptions, type ToastPosition, type ToastProps, ToastProvider, type ToastProviderProps, type ToastVariant, Tooltip, type TooltipPlacement, type TooltipProps, type TooltipSize, type TooltipVariant, WarningIcon, useToast };
package/dist/index.js CHANGED
@@ -1684,13 +1684,184 @@ var Tooltip = React8.forwardRef(
1684
1684
  );
1685
1685
  }
1686
1686
  );
1687
+ var Container = React8.forwardRef(
1688
+ function Container2({ fluid = false, className = "", children, ...rest }, ref) {
1689
+ return /* @__PURE__ */ jsxRuntime.jsx(
1690
+ "div",
1691
+ {
1692
+ ref,
1693
+ className: [
1694
+ "rh-w-full rh-mx-auto",
1695
+ "rh-max-w-[1440px]",
1696
+ !fluid ? "rh-px-grid-margin-mobile desktop-xs:rh-px-grid-margin-desktop" : "",
1697
+ className
1698
+ ].filter(Boolean).join(" "),
1699
+ ...rest,
1700
+ children
1701
+ }
1702
+ );
1703
+ }
1704
+ );
1705
+ var colsClasses = {
1706
+ 1: "rh-grid-cols-1",
1707
+ 2: "rh-grid-cols-2",
1708
+ 3: "rh-grid-cols-3",
1709
+ 4: "rh-grid-cols-4",
1710
+ 5: "rh-grid-cols-5",
1711
+ 6: "rh-grid-cols-6",
1712
+ 7: "rh-grid-cols-7",
1713
+ 8: "rh-grid-cols-8",
1714
+ 9: "rh-grid-cols-9",
1715
+ 10: "rh-grid-cols-10",
1716
+ 11: "rh-grid-cols-11",
1717
+ 12: "rh-grid-cols-12"
1718
+ };
1719
+ var GridContainer = React8.forwardRef(
1720
+ function GridContainer2({ columns, spacing, className = "", style, children, ...rest }, ref) {
1721
+ const colClass = columns ? colsClasses[columns] : "rh-grid-cols-4 desktop-xs:rh-grid-cols-12";
1722
+ const gapStyle = spacing !== void 0 ? { gap: `${spacing}px`, ...style } : style;
1723
+ return /* @__PURE__ */ jsxRuntime.jsx(
1724
+ "div",
1725
+ {
1726
+ ref,
1727
+ style: gapStyle,
1728
+ className: [
1729
+ "rh-grid",
1730
+ colClass,
1731
+ spacing === void 0 ? "rh-gap-grid-gutter-mobile desktop-xs:rh-gap-grid-gutter-desktop" : "",
1732
+ className
1733
+ ].filter(Boolean).join(" "),
1734
+ ...rest,
1735
+ children
1736
+ }
1737
+ );
1738
+ }
1739
+ );
1740
+ var mobileSpanClasses = {
1741
+ 1: "rh-col-span-1",
1742
+ 2: "rh-col-span-2",
1743
+ 3: "rh-col-span-3",
1744
+ 4: "rh-col-span-4"
1745
+ };
1746
+ var mobileSmSpanClasses = {
1747
+ 1: "mobile-sm:rh-col-span-1",
1748
+ 2: "mobile-sm:rh-col-span-2",
1749
+ 3: "mobile-sm:rh-col-span-3",
1750
+ 4: "mobile-sm:rh-col-span-4"
1751
+ };
1752
+ var mobileMdSpanClasses = {
1753
+ 1: "mobile-md:rh-col-span-1",
1754
+ 2: "mobile-md:rh-col-span-2",
1755
+ 3: "mobile-md:rh-col-span-3",
1756
+ 4: "mobile-md:rh-col-span-4"
1757
+ };
1758
+ var mobileLgSpanClasses = {
1759
+ 1: "mobile-lg:rh-col-span-1",
1760
+ 2: "mobile-lg:rh-col-span-2",
1761
+ 3: "mobile-lg:rh-col-span-3",
1762
+ 4: "mobile-lg:rh-col-span-4"
1763
+ };
1764
+ var desktopSpanClasses = {
1765
+ 1: "desktop-xs:rh-col-span-1",
1766
+ 2: "desktop-xs:rh-col-span-2",
1767
+ 3: "desktop-xs:rh-col-span-3",
1768
+ 4: "desktop-xs:rh-col-span-4",
1769
+ 5: "desktop-xs:rh-col-span-5",
1770
+ 6: "desktop-xs:rh-col-span-6",
1771
+ 7: "desktop-xs:rh-col-span-7",
1772
+ 8: "desktop-xs:rh-col-span-8",
1773
+ 9: "desktop-xs:rh-col-span-9",
1774
+ 10: "desktop-xs:rh-col-span-10",
1775
+ 11: "desktop-xs:rh-col-span-11",
1776
+ 12: "desktop-xs:rh-col-span-12"
1777
+ };
1778
+ var desktopSmSpanClasses = {
1779
+ 1: "desktop-sm:rh-col-span-1",
1780
+ 2: "desktop-sm:rh-col-span-2",
1781
+ 3: "desktop-sm:rh-col-span-3",
1782
+ 4: "desktop-sm:rh-col-span-4",
1783
+ 5: "desktop-sm:rh-col-span-5",
1784
+ 6: "desktop-sm:rh-col-span-6",
1785
+ 7: "desktop-sm:rh-col-span-7",
1786
+ 8: "desktop-sm:rh-col-span-8",
1787
+ 9: "desktop-sm:rh-col-span-9",
1788
+ 10: "desktop-sm:rh-col-span-10",
1789
+ 11: "desktop-sm:rh-col-span-11",
1790
+ 12: "desktop-sm:rh-col-span-12"
1791
+ };
1792
+ var desktopMdSpanClasses = {
1793
+ 1: "desktop-md:rh-col-span-1",
1794
+ 2: "desktop-md:rh-col-span-2",
1795
+ 3: "desktop-md:rh-col-span-3",
1796
+ 4: "desktop-md:rh-col-span-4",
1797
+ 5: "desktop-md:rh-col-span-5",
1798
+ 6: "desktop-md:rh-col-span-6",
1799
+ 7: "desktop-md:rh-col-span-7",
1800
+ 8: "desktop-md:rh-col-span-8",
1801
+ 9: "desktop-md:rh-col-span-9",
1802
+ 10: "desktop-md:rh-col-span-10",
1803
+ 11: "desktop-md:rh-col-span-11",
1804
+ 12: "desktop-md:rh-col-span-12"
1805
+ };
1806
+ var desktopLgSpanClasses = {
1807
+ 1: "desktop-lg:rh-col-span-1",
1808
+ 2: "desktop-lg:rh-col-span-2",
1809
+ 3: "desktop-lg:rh-col-span-3",
1810
+ 4: "desktop-lg:rh-col-span-4",
1811
+ 5: "desktop-lg:rh-col-span-5",
1812
+ 6: "desktop-lg:rh-col-span-6",
1813
+ 7: "desktop-lg:rh-col-span-7",
1814
+ 8: "desktop-lg:rh-col-span-8",
1815
+ 9: "desktop-lg:rh-col-span-9",
1816
+ 10: "desktop-lg:rh-col-span-10",
1817
+ 11: "desktop-lg:rh-col-span-11",
1818
+ 12: "desktop-lg:rh-col-span-12"
1819
+ };
1820
+ var GridItem = React8.forwardRef(
1821
+ function GridItem2({
1822
+ mobile = 4,
1823
+ mobileSm,
1824
+ mobileMd,
1825
+ mobileLg,
1826
+ desktop = 12,
1827
+ desktopSm,
1828
+ desktopMd,
1829
+ desktopLg,
1830
+ className = "",
1831
+ children,
1832
+ ...rest
1833
+ }, ref) {
1834
+ return /* @__PURE__ */ jsxRuntime.jsx(
1835
+ "div",
1836
+ {
1837
+ ref,
1838
+ className: [
1839
+ mobileSpanClasses[mobile],
1840
+ mobileSm !== void 0 ? mobileSmSpanClasses[mobileSm] : "",
1841
+ mobileMd !== void 0 ? mobileMdSpanClasses[mobileMd] : "",
1842
+ mobileLg !== void 0 ? mobileLgSpanClasses[mobileLg] : "",
1843
+ desktopSpanClasses[desktop],
1844
+ desktopSm !== void 0 ? desktopSmSpanClasses[desktopSm] : "",
1845
+ desktopMd !== void 0 ? desktopMdSpanClasses[desktopMd] : "",
1846
+ desktopLg !== void 0 ? desktopLgSpanClasses[desktopLg] : "",
1847
+ className
1848
+ ].filter(Boolean).join(" "),
1849
+ ...rest,
1850
+ children
1851
+ }
1852
+ );
1853
+ }
1854
+ );
1687
1855
 
1688
1856
  exports.Button = Button;
1689
1857
  exports.Checkbox = Checkbox;
1690
1858
  exports.CloseIcon = CloseIcon;
1859
+ exports.Container = Container;
1691
1860
  exports.DeleteIcon = DeleteIcon;
1692
1861
  exports.EditIcon = EditIcon;
1693
1862
  exports.ErrorIcon = ErrorIcon;
1863
+ exports.GridContainer = GridContainer;
1864
+ exports.GridItem = GridItem;
1694
1865
  exports.IconButton = IconButton;
1695
1866
  exports.InfoIcon = InfoIcon;
1696
1867
  exports.NeutralIcon = NeutralIcon;