lecom-ui 4.6.4 → 4.6.6

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.
@@ -14,7 +14,6 @@ const NotificationCallout = ({ ...props }) => {
14
14
  const refCollapse = React.useRef(null);
15
15
  const contentRef = React.useRef(null);
16
16
  React.useEffect(() => {
17
- console.log("React.useEffect", !!props.isCollapsed);
18
17
  setIsCollapsed(!!props.isCollapsed);
19
18
  }, [props.isCollapsed]);
20
19
  React.useEffect(() => {
@@ -36,7 +35,13 @@ const NotificationCallout = ({ ...props }) => {
36
35
  refCollapse.current?.style.setProperty("transform", "rotate(0deg)");
37
36
  }
38
37
  }, [isCollapsed]);
39
- const handleCollapse = () => setIsCollapsed(!isCollapsed);
38
+ const handleCollapse = () => {
39
+ if (props.onCollapseChange) {
40
+ props.onCollapseChange(!isCollapsed);
41
+ } else {
42
+ setIsCollapsed(!isCollapsed);
43
+ }
44
+ };
40
45
  const defaultVariant = props.variant ?? "information";
41
46
  const getGridColumns = () => {
42
47
  if (props.fullWidth) {
package/dist/index.d.ts CHANGED
@@ -450,7 +450,7 @@ interface ErrorEmptyDisplayProps {
450
450
  render?: React.ReactNode;
451
451
  }
452
452
  declare const ErrorEmptyDisplay: {
453
- ({ className, classContent, image, title, description, footer, render, }: ErrorEmptyDisplayProps): string | number | bigint | true | React$1.JSX.Element | Iterable<React$1.ReactNode> | Promise<string | number | bigint | boolean | React$1.ReactPortal | React$1.ReactElement<unknown, string | React$1.JSXElementConstructor<any>> | Iterable<React$1.ReactNode> | null | undefined>;
453
+ ({ className, classContent, image, title, description, footer, render, }: ErrorEmptyDisplayProps): string | number | bigint | true | Iterable<React$1.ReactNode> | Promise<string | number | bigint | boolean | React$1.ReactPortal | React$1.ReactElement<unknown, string | React$1.JSXElementConstructor<any>> | Iterable<React$1.ReactNode> | null | undefined> | React$1.JSX.Element;
454
454
  displayName: string;
455
455
  };
456
456
 
@@ -540,9 +540,9 @@ interface HeaderProps extends React$1.HTMLAttributes<HTMLElement>, VariantProps<
540
540
  }
541
541
 
542
542
  declare const inputVariants: (props?: ({
543
- variant?: "filled" | "default" | "borderless" | null | undefined;
544
- size?: "small" | "large" | "default" | null | undefined;
545
- radius?: "small" | "large" | "default" | null | undefined;
543
+ variant?: "default" | "filled" | "borderless" | null | undefined;
544
+ size?: "default" | "small" | "large" | null | undefined;
545
+ radius?: "default" | "small" | "large" | null | undefined;
546
546
  } & class_variance_authority_types.ClassProp) | undefined) => string;
547
547
  interface InputProps extends Omit<React$1.InputHTMLAttributes<HTMLInputElement>, 'size' | 'sufix' | 'prefix'>, VariantProps<typeof inputVariants> {
548
548
  sufix?: React$1.ReactNode;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lecom-ui",
3
- "version": "4.6.4",
3
+ "version": "4.6.6",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "module": "dist/index.js",