Socket
Socket
Sign inDemoInstall

@nkey-ui/collapse

Package Overview
Dependencies
Maintainers
1
Versions
49
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@nkey-ui/collapse - npm Package Compare versions

Comparing version 1.1.10 to 1.1.13

dist/chunk-7KSW5EPX.mjs

4

dist/collapse.d.ts
import * as react from 'react';
import { ComponentPropsWithoutRef } from 'react';
import { MergeTypes } from '@nkey-ui/shared-utils';
import { CollapseVariantProps } from '@nkey-ui/theme';
interface CollapseProps extends Omit<ComponentPropsWithoutRef<'div'>, 'onChange'> {
interface CollapseProps extends MergeTypes<ComponentPropsWithoutRef<'div'>, CollapseVariantProps, 'onChange'> {
open: boolean;

@@ -6,0 +8,0 @@ onChange?(open: boolean): void;

@@ -32,3 +32,3 @@ "use client";

var timeout;
var Collapse = (0, import_react.forwardRef)(function Collapse2({ children, open, onChange, className, classNames = {}, ...rest }, ref) {
var Collapse = (0, import_react.forwardRef)(function Collapse2({ children, open, animation, onChange, className, classNames = {}, ...rest }, ref) {
const [height, setHeight] = (0, import_react.useState)(0);

@@ -48,3 +48,3 @@ const childrenRef = (0, import_react.useRef)(null);

}, [open, onChange]);
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { ref, className: (0, import_theme.collapse)({ className: classNames.wrapper }), style: { height }, ...rest, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { ref: childrenRef, className: classNames.content || className, children }) });
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { ref, className: (0, import_theme.collapse)({ animation, className: classNames.wrapper }), style: { height }, ...rest, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { ref: childrenRef, className: classNames.content || className, children }) });
});

@@ -51,0 +51,0 @@ Collapse.displayName = "NkeyUI.Collapse";

export { default as Collapse, CollapseProps } from './collapse.js';
import 'react';
import '@nkey-ui/shared-utils';
import '@nkey-ui/theme';

@@ -34,3 +34,3 @@ "use client";

var timeout;
var Collapse = (0, import_react.forwardRef)(function Collapse2({ children, open, onChange, className, classNames = {}, ...rest }, ref) {
var Collapse = (0, import_react.forwardRef)(function Collapse2({ children, open, animation, onChange, className, classNames = {}, ...rest }, ref) {
const [height, setHeight] = (0, import_react.useState)(0);

@@ -50,3 +50,3 @@ const childrenRef = (0, import_react.useRef)(null);

}, [open, onChange]);
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { ref, className: (0, import_theme.collapse)({ className: classNames.wrapper }), style: { height }, ...rest, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { ref: childrenRef, className: classNames.content || className, children }) });
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { ref, className: (0, import_theme.collapse)({ animation, className: classNames.wrapper }), style: { height }, ...rest, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { ref: childrenRef, className: classNames.content || className, children }) });
});

@@ -53,0 +53,0 @@ Collapse.displayName = "NkeyUI.Collapse";

{
"name": "@nkey-ui/collapse",
"version": "1.1.10",
"version": "1.1.13",
"description": "A React component to collapse content with animations.",

@@ -27,3 +27,4 @@ "keywords": [

"@nkey-ui/react-utils": "1.0.4",
"@nkey-ui/theme": "1.0.39"
"@nkey-ui/shared-utils": "1.0.12",
"@nkey-ui/theme": "1.0.42"
},

@@ -30,0 +31,0 @@ "clean-package": "../../../clean-package.config.json",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc