@marcoschwartz/lite-ui 0.26.0 → 0.26.2

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
@@ -713,6 +713,8 @@ interface LineChartProps {
713
713
  responsive?: boolean;
714
714
  /** Aspect ratio for responsive mode (default: 2 = width is 2x height) */
715
715
  aspectRatio?: number;
716
+ /** Maximum height constraint for responsive mode */
717
+ maxHeight?: number | string;
716
718
  /** @internal - Set by ResponsiveContainer to indicate resize (skip animation) */
717
719
  _isResizing?: boolean;
718
720
  /** Padding inside the chart */
@@ -797,6 +799,8 @@ interface BarChartProps {
797
799
  responsive?: boolean;
798
800
  /** Aspect ratio for responsive mode (default: 2 = width is 2x height) */
799
801
  aspectRatio?: number;
802
+ /** Maximum height constraint for responsive mode */
803
+ maxHeight?: number | string;
800
804
  /** @internal - Set by ResponsiveContainer to indicate resize (skip animation) */
801
805
  _isResizing?: boolean;
802
806
  /** Padding inside the chart */
@@ -884,6 +888,8 @@ interface AreaChartProps {
884
888
  responsive?: boolean;
885
889
  /** Aspect ratio for responsive mode (default: 2 = width is 2x height) */
886
890
  aspectRatio?: number;
891
+ /** Maximum height constraint for responsive mode */
892
+ maxHeight?: number | string;
887
893
  /** @internal - Set by ResponsiveContainer to indicate resize (skip animation) */
888
894
  _isResizing?: boolean;
889
895
  /** Padding inside the chart */
@@ -961,6 +967,8 @@ interface PieChartProps {
961
967
  responsive?: boolean;
962
968
  /** Aspect ratio for responsive mode (default: 1 for square pie charts) */
963
969
  aspectRatio?: number;
970
+ /** Maximum height constraint for responsive mode */
971
+ maxHeight?: number | string;
964
972
  /** @internal - Set by ResponsiveContainer to indicate resize (skip animation) */
965
973
  _isResizing?: boolean;
966
974
  /** Inner radius for donut chart (0 for pie) */
@@ -1037,6 +1045,8 @@ interface ScatterChartProps {
1037
1045
  responsive?: boolean;
1038
1046
  /** Aspect ratio for responsive mode (default: 2 = width is 2x height) */
1039
1047
  aspectRatio?: number;
1048
+ /** Maximum height constraint for responsive mode */
1049
+ maxHeight?: number | string;
1040
1050
  /** @internal - Set by ResponsiveContainer to indicate resize (skip animation) */
1041
1051
  _isResizing?: boolean;
1042
1052
  /** Padding inside the chart */
package/dist/index.d.ts CHANGED
@@ -713,6 +713,8 @@ interface LineChartProps {
713
713
  responsive?: boolean;
714
714
  /** Aspect ratio for responsive mode (default: 2 = width is 2x height) */
715
715
  aspectRatio?: number;
716
+ /** Maximum height constraint for responsive mode */
717
+ maxHeight?: number | string;
716
718
  /** @internal - Set by ResponsiveContainer to indicate resize (skip animation) */
717
719
  _isResizing?: boolean;
718
720
  /** Padding inside the chart */
@@ -797,6 +799,8 @@ interface BarChartProps {
797
799
  responsive?: boolean;
798
800
  /** Aspect ratio for responsive mode (default: 2 = width is 2x height) */
799
801
  aspectRatio?: number;
802
+ /** Maximum height constraint for responsive mode */
803
+ maxHeight?: number | string;
800
804
  /** @internal - Set by ResponsiveContainer to indicate resize (skip animation) */
801
805
  _isResizing?: boolean;
802
806
  /** Padding inside the chart */
@@ -884,6 +888,8 @@ interface AreaChartProps {
884
888
  responsive?: boolean;
885
889
  /** Aspect ratio for responsive mode (default: 2 = width is 2x height) */
886
890
  aspectRatio?: number;
891
+ /** Maximum height constraint for responsive mode */
892
+ maxHeight?: number | string;
887
893
  /** @internal - Set by ResponsiveContainer to indicate resize (skip animation) */
888
894
  _isResizing?: boolean;
889
895
  /** Padding inside the chart */
@@ -961,6 +967,8 @@ interface PieChartProps {
961
967
  responsive?: boolean;
962
968
  /** Aspect ratio for responsive mode (default: 1 for square pie charts) */
963
969
  aspectRatio?: number;
970
+ /** Maximum height constraint for responsive mode */
971
+ maxHeight?: number | string;
964
972
  /** @internal - Set by ResponsiveContainer to indicate resize (skip animation) */
965
973
  _isResizing?: boolean;
966
974
  /** Inner radius for donut chart (0 for pie) */
@@ -1037,6 +1045,8 @@ interface ScatterChartProps {
1037
1045
  responsive?: boolean;
1038
1046
  /** Aspect ratio for responsive mode (default: 2 = width is 2x height) */
1039
1047
  aspectRatio?: number;
1048
+ /** Maximum height constraint for responsive mode */
1049
+ maxHeight?: number | string;
1040
1050
  /** @internal - Set by ResponsiveContainer to indicate resize (skip animation) */
1041
1051
  _isResizing?: boolean;
1042
1052
  /** Padding inside the chart */
package/dist/index.js CHANGED
@@ -6125,6 +6125,7 @@ function useBreakpoint() {
6125
6125
  function useResponsiveChart({
6126
6126
  responsive = false,
6127
6127
  aspectRatio,
6128
+ maxHeight,
6128
6129
  providedWidth,
6129
6130
  providedHeight,
6130
6131
  defaultWidth = 800,
@@ -6143,7 +6144,7 @@ function useResponsiveChart({
6143
6144
  height = providedHeight || defaultHeight;
6144
6145
  effectiveAspectRatio = width / height;
6145
6146
  }
6146
- const containerStyle = responsive ? { width: "100%", aspectRatio: `${effectiveAspectRatio}` } : { width, height: "auto" };
6147
+ const containerStyle = responsive ? maxHeight !== void 0 ? { width: "100%", height: maxHeight } : { width: "100%", aspectRatio: `${effectiveAspectRatio}` } : { width, height: "auto" };
6147
6148
  const svgStyle = responsive ? { width: "100%", height: "100%", display: "block" } : {};
6148
6149
  const svgWidth = responsive ? "100%" : width;
6149
6150
  const svgHeight = responsive ? "100%" : height;
@@ -7024,6 +7025,7 @@ var LineChart = ({
7024
7025
  height: providedHeight,
7025
7026
  responsive = false,
7026
7027
  aspectRatio = 2,
7028
+ maxHeight,
7027
7029
  _isResizing = false,
7028
7030
  padding: customPadding,
7029
7031
  showGrid = true,
@@ -7068,6 +7070,7 @@ var LineChart = ({
7068
7070
  } = useResponsiveChart({
7069
7071
  responsive,
7070
7072
  aspectRatio,
7073
+ maxHeight,
7071
7074
  providedWidth,
7072
7075
  providedHeight
7073
7076
  });
@@ -7517,6 +7520,7 @@ var BarChart = ({
7517
7520
  height: providedHeight,
7518
7521
  responsive = false,
7519
7522
  aspectRatio = 2,
7523
+ maxHeight,
7520
7524
  _isResizing = false,
7521
7525
  padding: customPadding,
7522
7526
  showGrid = true,
@@ -7559,6 +7563,7 @@ var BarChart = ({
7559
7563
  } = useResponsiveChart({
7560
7564
  responsive,
7561
7565
  aspectRatio,
7566
+ maxHeight,
7562
7567
  providedWidth,
7563
7568
  providedHeight
7564
7569
  });
@@ -7941,6 +7946,7 @@ var AreaChart = ({
7941
7946
  height: providedHeight,
7942
7947
  responsive = false,
7943
7948
  aspectRatio = 2,
7949
+ maxHeight,
7944
7950
  _isResizing = false,
7945
7951
  padding: customPadding,
7946
7952
  showGrid = true,
@@ -7982,6 +7988,7 @@ var AreaChart = ({
7982
7988
  } = useResponsiveChart({
7983
7989
  responsive,
7984
7990
  aspectRatio,
7991
+ maxHeight,
7985
7992
  providedWidth,
7986
7993
  providedHeight
7987
7994
  });
@@ -8412,6 +8419,7 @@ var PieChart = ({
8412
8419
  height: providedHeight,
8413
8420
  responsive = false,
8414
8421
  aspectRatio = 1,
8422
+ maxHeight,
8415
8423
  _isResizing = false,
8416
8424
  innerRadius: providedInnerRadius,
8417
8425
  outerRadius: providedOuterRadius,
@@ -8452,6 +8460,7 @@ var PieChart = ({
8452
8460
  } = useResponsiveChart({
8453
8461
  responsive,
8454
8462
  aspectRatio,
8463
+ maxHeight,
8455
8464
  providedWidth,
8456
8465
  providedHeight,
8457
8466
  defaultWidth: 400,
@@ -8802,6 +8811,7 @@ var ScatterChart = ({
8802
8811
  height: providedHeight,
8803
8812
  responsive = false,
8804
8813
  aspectRatio = 2,
8814
+ maxHeight,
8805
8815
  _isResizing = false,
8806
8816
  padding: customPadding,
8807
8817
  showGrid = true,
@@ -8846,6 +8856,7 @@ var ScatterChart = ({
8846
8856
  } = useResponsiveChart({
8847
8857
  responsive,
8848
8858
  aspectRatio,
8859
+ maxHeight,
8849
8860
  providedWidth,
8850
8861
  providedHeight
8851
8862
  });