@neo4j-ndl/react 2.7.0 → 2.7.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/CHANGELOG.md +13 -0
- package/lib/cjs/drawer/Drawer.js +17 -13
- package/lib/cjs/drawer/Drawer.js.map +1 -1
- package/lib/esm/drawer/Drawer.js +16 -11
- package/lib/esm/drawer/Drawer.js.map +1 -1
- package/lib/types/drawer/Drawer.d.ts +7 -7
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,18 @@
|
|
|
1
1
|
# Change Log
|
|
2
2
|
|
|
3
|
+
## 2.7.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [[`d65fdd5623085a9dcd4e95d333e54da8bd83eb54`](https://github.com/neo4j/needle/commit/d65fdd5623085a9dcd4e95d333e54da8bd83eb54)]:
|
|
8
|
+
- @neo4j-ndl/base@2.6.1
|
|
9
|
+
|
|
10
|
+
## 2.7.1
|
|
11
|
+
|
|
12
|
+
### Patch Changes
|
|
13
|
+
|
|
14
|
+
- [#745](https://github.com/neo4j/needle/pull/745) [`0e0ac8860b4dabb2922aa2fb2d78cbcf520bcba5`](https://github.com/neo4j/needle/commit/0e0ac8860b4dabb2922aa2fb2d78cbcf520bcba5) Thanks [@daugerdas](https://github.com/daugerdas)! - add ref to Drawer
|
|
15
|
+
|
|
3
16
|
## 2.7.0
|
|
4
17
|
|
|
5
18
|
### Minor Changes
|
package/lib/cjs/drawer/Drawer.js
CHANGED
|
@@ -14,7 +14,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
14
14
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
exports.Drawer = void 0;
|
|
17
|
+
exports.Drawer = exports.DrawerComponent = void 0;
|
|
18
18
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
19
19
|
/**
|
|
20
20
|
*
|
|
@@ -40,10 +40,11 @@ const defaultImports_1 = require("../_common/defaultImports");
|
|
|
40
40
|
const react_1 = require("react");
|
|
41
41
|
const re_resizable_1 = require("re-resizable");
|
|
42
42
|
const button_1 = require("../button");
|
|
43
|
+
const helpers_1 = require("../helpers");
|
|
43
44
|
const icons_1 = require("../icons");
|
|
44
45
|
const ConditionalWrap_1 = __importDefault(require("../_common/ConditionalWrap"));
|
|
45
46
|
const react_2 = require("@floating-ui/react");
|
|
46
|
-
|
|
47
|
+
exports.DrawerComponent = (0, helpers_1.forwardRef)(function DrawerComponent(_a, ref) {
|
|
47
48
|
var { children, className = '', expanded, onExpandedChange, position = 'left', type = 'overlay', isResizeable = false, resizeableProps, closeable = true, isPortaled = false, portalProps = {} } = _a, restProps = __rest(_a, ["children", "className", "expanded", "onExpandedChange", "position", "type", "isResizeable", "resizeableProps", "closeable", "isPortaled", "portalProps"]);
|
|
48
49
|
const setOnExpandedChange = (0, react_1.useCallback)(() => {
|
|
49
50
|
if (onExpandedChange)
|
|
@@ -72,28 +73,31 @@ const Drawer = (_a) => {
|
|
|
72
73
|
bottomRight: false,
|
|
73
74
|
bottomLeft: false,
|
|
74
75
|
topLeft: false,
|
|
75
|
-
}, children: [children, (0, jsx_runtime_1.jsx)(Close, {})] })) }));
|
|
76
|
+
}, ref: ref, children: [children, (0, jsx_runtime_1.jsx)(Close, {})] })) }));
|
|
76
77
|
}
|
|
77
|
-
return ((0, jsx_runtime_1.jsx)(ConditionalWrap_1.default, { condition: renderInPortal, wrap: (wrapChildren) => ((0, jsx_runtime_1.jsx)(react_2.FloatingPortal, Object.assign({ preserveTabOrder: true }, portalProps, { children: wrapChildren }))), children: (0, jsx_runtime_1.jsxs)("div", Object.assign({}, restProps, { className: classes, children: [children, (0, jsx_runtime_1.jsx)(Close, {})] })) }));
|
|
78
|
-
};
|
|
79
|
-
|
|
80
|
-
const Header = (_a) => {
|
|
78
|
+
return ((0, jsx_runtime_1.jsx)(ConditionalWrap_1.default, { condition: renderInPortal, wrap: (wrapChildren) => ((0, jsx_runtime_1.jsx)(react_2.FloatingPortal, Object.assign({ preserveTabOrder: true }, portalProps, { children: wrapChildren }))), children: (0, jsx_runtime_1.jsxs)("div", Object.assign({}, restProps, { className: classes, ref: ref, children: [children, (0, jsx_runtime_1.jsx)(Close, {})] })) }));
|
|
79
|
+
});
|
|
80
|
+
const DrawerHeader = (_a) => {
|
|
81
81
|
var { children, className = '' } = _a, restProps = __rest(_a, ["children", "className"]);
|
|
82
82
|
const classes = (0, defaultImports_1.classNames)('ndl-drawer-header', className);
|
|
83
83
|
return ((0, jsx_runtime_1.jsx)("h5", Object.assign({}, restProps, { className: classes, children: children })));
|
|
84
84
|
};
|
|
85
|
-
exports.
|
|
86
|
-
const
|
|
85
|
+
exports.DrawerComponent.displayName = 'Drawer';
|
|
86
|
+
const DrawerActions = (_a) => {
|
|
87
87
|
var { children, className = '' } = _a, restProps = __rest(_a, ["children", "className"]);
|
|
88
88
|
const classes = (0, defaultImports_1.classNames)('ndl-drawer-actions', className);
|
|
89
89
|
return ((0, jsx_runtime_1.jsx)("div", Object.assign({}, restProps, { className: classes, children: children })));
|
|
90
90
|
};
|
|
91
|
-
|
|
92
|
-
const Body = (_a) => {
|
|
91
|
+
const DrawerBody = (_a) => {
|
|
93
92
|
var { children, className = '' } = _a, restProps = __rest(_a, ["children", "className"]);
|
|
94
93
|
const classes = (0, defaultImports_1.classNames)('ndl-drawer-body', className);
|
|
95
94
|
return ((0, jsx_runtime_1.jsx)("div", { className: "ndl-drawer-body-wrapper", children: (0, jsx_runtime_1.jsx)("div", Object.assign({}, restProps, { className: classes, children: children })) }));
|
|
96
95
|
};
|
|
97
|
-
|
|
98
|
-
|
|
96
|
+
// Issue with TypeScript forwardRef and subcomponents: https://github.com/DefinitelyTyped/DefinitelyTyped/issues/34757#issuecomment-894053907
|
|
97
|
+
const Drawer = Object.assign(exports.DrawerComponent, {
|
|
98
|
+
Header: DrawerHeader,
|
|
99
|
+
Actions: DrawerActions,
|
|
100
|
+
Body: DrawerBody,
|
|
101
|
+
});
|
|
102
|
+
exports.Drawer = Drawer;
|
|
99
103
|
//# sourceMappingURL=Drawer.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Drawer.js","sourceRoot":"","sources":["../../../src/drawer/Drawer.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,8DAAuD;AACvD,
|
|
1
|
+
{"version":3,"file":"Drawer.js","sourceRoot":"","sources":["../../../src/drawer/Drawer.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,8DAAuD;AACvD,iCAKe;AACf,+CAA8D;AAC9D,sCAAuC;AACvC,wCAIoB;AACpB,oCAA4C;AAC5C,iFAAyD;AACzD,8CAAoD;AAsCvC,QAAA,eAAe,GAAG,IAAA,oBAAU,EAAC,SAAS,eAAe,CAChE,EAac,EACd,GAA6C;QAd7C,EACE,QAAQ,EACR,SAAS,GAAG,EAAE,EACd,QAAQ,EACR,gBAAgB,EAChB,QAAQ,GAAG,MAAM,EACjB,IAAI,GAAG,SAAS,EAChB,YAAY,GAAG,KAAK,EACpB,eAAe,EACf,SAAS,GAAG,IAAI,EAChB,UAAU,GAAG,KAAK,EAClB,WAAW,GAAG,EAAE,OAEJ,EADT,SAAS,cAZd,0JAaC,CADa;IAId,MAAM,mBAAmB,GAAG,IAAA,mBAAW,EAAC,GAAG,EAAE;QAC3C,IAAI,gBAAgB;YAAE,gBAAgB,CAAC,CAAC,QAAQ,CAAC,CAAC;IACpD,CAAC,EAAE,CAAC,QAAQ,EAAE,gBAAgB,CAAC,CAAC,CAAC;IAEjC,MAAM,OAAO,GAAG,IAAA,2BAAU,EAAC,YAAY,EAAE,SAAS,EAAE;QAClD,qBAAqB,EAAE,QAAQ;QAC/B,iBAAiB,EAAE,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F,EAAE,EAAE;QAJF,EAClB,QAAQ,EACR,SAAS,GAAG,EAAE,OAEE,EADb,SAAS,cAHM,yBAInB,CADa;IAEZ,MAAM,OAAO,GAAG,IAAA,2BAAU,EAAC,iBAAiB,EAAE,SAAS,CAAC,CAAC;IAEzD,OAAO,CACL,gCAAK,SAAS,EAAC,yBAAyB,YACtC,gDAAS,SAAS,IAAE,SAAS,EAAE,OAAO,YACnC,QAAQ,IACL,GACF,CACP,CAAC;AACJ,CAAC,CAAC;AAEF,6IAA6I;AAC7I,MAAM,MAAM,GAAG,MAAM,CAAC,MAAM,CAAC,uBAAe,EAAE;IAC5C,MAAM,EAAE,YAAY;IACpB,OAAO,EAAE,aAAa;IACtB,IAAI,EAAE,UAAU;CACjB,CAAC,CAAC;AAEM,wBAAM"}
|
package/lib/esm/drawer/Drawer.js
CHANGED
|
@@ -34,10 +34,11 @@ import { classNames } from '../_common/defaultImports';
|
|
|
34
34
|
import { useCallback, } from 'react';
|
|
35
35
|
import { Resizable } from 're-resizable';
|
|
36
36
|
import { IconButton } from '../button';
|
|
37
|
+
import { forwardRef, } from '../helpers';
|
|
37
38
|
import { XMarkIconOutline } from '../icons';
|
|
38
39
|
import ConditionalWrap from '../_common/ConditionalWrap';
|
|
39
40
|
import { FloatingPortal } from '@floating-ui/react';
|
|
40
|
-
export const
|
|
41
|
+
export const DrawerComponent = forwardRef(function DrawerComponent(_a, ref) {
|
|
41
42
|
var { children, className = '', expanded, onExpandedChange, position = 'left', type = 'overlay', isResizeable = false, resizeableProps, closeable = true, isPortaled = false, portalProps = {} } = _a, restProps = __rest(_a, ["children", "className", "expanded", "onExpandedChange", "position", "type", "isResizeable", "resizeableProps", "closeable", "isPortaled", "portalProps"]);
|
|
42
43
|
const setOnExpandedChange = useCallback(() => {
|
|
43
44
|
if (onExpandedChange)
|
|
@@ -66,27 +67,31 @@ export const Drawer = (_a) => {
|
|
|
66
67
|
bottomRight: false,
|
|
67
68
|
bottomLeft: false,
|
|
68
69
|
topLeft: false,
|
|
69
|
-
}, children: [children, _jsx(Close, {})] })) }));
|
|
70
|
+
}, ref: ref, children: [children, _jsx(Close, {})] })) }));
|
|
70
71
|
}
|
|
71
|
-
return (_jsx(ConditionalWrap, { condition: renderInPortal, wrap: (wrapChildren) => (_jsx(FloatingPortal, Object.assign({ preserveTabOrder: true }, portalProps, { children: wrapChildren }))), children: _jsxs("div", Object.assign({}, restProps, { className: classes, children: [children, _jsx(Close, {})] })) }));
|
|
72
|
-
};
|
|
73
|
-
const
|
|
72
|
+
return (_jsx(ConditionalWrap, { condition: renderInPortal, wrap: (wrapChildren) => (_jsx(FloatingPortal, Object.assign({ preserveTabOrder: true }, portalProps, { children: wrapChildren }))), children: _jsxs("div", Object.assign({}, restProps, { className: classes, ref: ref, children: [children, _jsx(Close, {})] })) }));
|
|
73
|
+
});
|
|
74
|
+
const DrawerHeader = (_a) => {
|
|
74
75
|
var { children, className = '' } = _a, restProps = __rest(_a, ["children", "className"]);
|
|
75
76
|
const classes = classNames('ndl-drawer-header', className);
|
|
76
77
|
return (_jsx("h5", Object.assign({}, restProps, { className: classes, children: children })));
|
|
77
78
|
};
|
|
78
|
-
|
|
79
|
-
const
|
|
79
|
+
DrawerComponent.displayName = 'Drawer';
|
|
80
|
+
const DrawerActions = (_a) => {
|
|
80
81
|
var { children, className = '' } = _a, restProps = __rest(_a, ["children", "className"]);
|
|
81
82
|
const classes = classNames('ndl-drawer-actions', className);
|
|
82
83
|
return (_jsx("div", Object.assign({}, restProps, { className: classes, children: children })));
|
|
83
84
|
};
|
|
84
|
-
|
|
85
|
-
const Body = (_a) => {
|
|
85
|
+
const DrawerBody = (_a) => {
|
|
86
86
|
var { children, className = '' } = _a, restProps = __rest(_a, ["children", "className"]);
|
|
87
87
|
const classes = classNames('ndl-drawer-body', className);
|
|
88
88
|
return (_jsx("div", { className: "ndl-drawer-body-wrapper", children: _jsx("div", Object.assign({}, restProps, { className: classes, children: children })) }));
|
|
89
89
|
};
|
|
90
|
-
|
|
91
|
-
|
|
90
|
+
// Issue with TypeScript forwardRef and subcomponents: https://github.com/DefinitelyTyped/DefinitelyTyped/issues/34757#issuecomment-894053907
|
|
91
|
+
const Drawer = Object.assign(DrawerComponent, {
|
|
92
|
+
Header: DrawerHeader,
|
|
93
|
+
Actions: DrawerActions,
|
|
94
|
+
Body: DrawerBody,
|
|
95
|
+
});
|
|
96
|
+
export { Drawer };
|
|
92
97
|
//# sourceMappingURL=Drawer.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Drawer.js","sourceRoot":"","sources":["../../../src/drawer/Drawer.tsx"],"names":[],"mappings":";;;;;;;;;;;;AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AACvD,OAAO,EACL,WAAW,
|
|
1
|
+
{"version":3,"file":"Drawer.js","sourceRoot":"","sources":["../../../src/drawer/Drawer.tsx"],"names":[],"mappings":";;;;;;;;;;;;AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AACvD,OAAO,EACL,WAAW,GAIZ,MAAM,OAAO,CAAC;AACf,OAAO,EAAE,SAAS,EAAuB,MAAM,cAAc,CAAC;AAC9D,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AACvC,OAAO,EAEL,UAAU,GAEX,MAAM,YAAY,CAAC;AACpB,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAC5C,OAAO,eAAe,MAAM,4BAA4B,CAAC;AACzD,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AAsCpD,MAAM,CAAC,MAAM,eAAe,GAAG,UAAU,CAAC,SAAS,eAAe,CAChE,EAac,EACd,GAA6C;QAd7C,EACE,QAAQ,EACR,SAAS,GAAG,EAAE,EACd,QAAQ,EACR,gBAAgB,EAChB,QAAQ,GAAG,MAAM,EACjB,IAAI,GAAG,SA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ACN,CAAC;AACJ,CAAC,CAAC;AAED,eAAsD,CAAC,WAAW,GAAG,QAAQ,CAAC;AAI/E,MAAM,aAAa,GAAG,CAAC,EAIF,EAAE,EAAE;QAJF,EACrB,QAAQ,EACR,SAAS,GAAG,EAAE,OAEK,EADhB,SAAS,cAHS,yBAItB,CADa;IAEZ,MAAM,OAAO,GAAG,UAAU,CAAC,oBAAoB,EAAE,SAAS,CAAC,CAAC;IAE5D,OAAO,CACL,8BAAS,SAAS,IAAE,SAAS,EAAE,OAAO,YACnC,QAAQ,IACL,CACP,CAAC;AACJ,CAAC,CAAC;AAIF,MAAM,UAAU,GAAG,CAAC,EAIF,EAAE,EAAE;QAJF,EAClB,QAAQ,EACR,SAAS,GAAG,EAAE,OAEE,EADb,SAAS,cAHM,yBAInB,CADa;IAEZ,MAAM,OAAO,GAAG,UAAU,CAAC,iBAAiB,EAAE,SAAS,CAAC,CAAC;IAEzD,OAAO,CACL,cAAK,SAAS,EAAC,yBAAyB,YACtC,8BAAS,SAAS,IAAE,SAAS,EAAE,OAAO,YACnC,QAAQ,IACL,GACF,CACP,CAAC;AACJ,CAAC,CAAC;AAEF,6IAA6I;AAC7I,MAAM,MAAM,GAAG,MAAM,CAAC,MAAM,CAAC,eAAe,EAAE;IAC5C,MAAM,EAAE,YAAY;IACpB,OAAO,EAAE,aAAa;IACtB,IAAI,EAAE,UAAU;CACjB,CAAC,CAAC;AAEH,OAAO,EAAE,MAAM,EAAE,CAAC"}
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
20
20
|
*/
|
|
21
21
|
import { type ComponentPropsWithoutRef, type ComponentProps } from 'react';
|
|
22
|
-
import { type ResizableProps } from 're-resizable';
|
|
22
|
+
import { Resizable, type ResizableProps } from 're-resizable';
|
|
23
23
|
import { type ElementBase } from '../helpers';
|
|
24
24
|
import { FloatingPortal } from '@floating-ui/react';
|
|
25
25
|
export type DrawerPosition = 'left' | 'right';
|
|
@@ -47,13 +47,13 @@ export interface DrawerProps extends ElementBase<HTMLDivElement> {
|
|
|
47
47
|
*/
|
|
48
48
|
portalProps?: ComponentProps<typeof FloatingPortal>;
|
|
49
49
|
}
|
|
50
|
-
export declare const
|
|
51
|
-
|
|
50
|
+
export declare const DrawerComponent: (props: DrawerProps & import("react").RefAttributes<HTMLDivElement & Resizable>) => import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>> | null;
|
|
51
|
+
type DrawerHeaderProps = ComponentPropsWithoutRef<'h5'>;
|
|
52
|
+
type DrawerActionsProps = ComponentPropsWithoutRef<'div'>;
|
|
53
|
+
type DrawerBodyProps = ComponentPropsWithoutRef<'div'>;
|
|
54
|
+
declare const Drawer: ((props: DrawerProps & import("react").RefAttributes<HTMLDivElement & Resizable>) => import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>> | null) & {
|
|
52
55
|
Header: ({ children, className, ...restProps }: DrawerHeaderProps) => import("react/jsx-runtime").JSX.Element;
|
|
53
56
|
Actions: ({ children, className, ...restProps }: DrawerActionsProps) => import("react/jsx-runtime").JSX.Element;
|
|
54
57
|
Body: ({ children, className, ...restProps }: DrawerBodyProps) => import("react/jsx-runtime").JSX.Element;
|
|
55
58
|
};
|
|
56
|
-
|
|
57
|
-
type DrawerActionsProps = ComponentPropsWithoutRef<'div'>;
|
|
58
|
-
type DrawerBodyProps = ComponentPropsWithoutRef<'div'>;
|
|
59
|
-
export default Drawer;
|
|
59
|
+
export { Drawer };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@neo4j-ndl/react",
|
|
3
|
-
"version": "2.7.
|
|
3
|
+
"version": "2.7.2",
|
|
4
4
|
"sideEffects": false,
|
|
5
5
|
"description": "React implementation of Neo4j Design System",
|
|
6
6
|
"keywords": [
|
|
@@ -93,7 +93,7 @@
|
|
|
93
93
|
"@floating-ui/react": "0.25.1",
|
|
94
94
|
"@heroicons/react": "2.0.13",
|
|
95
95
|
"@neo4j-cypher/react-codemirror": "^1.0.1",
|
|
96
|
-
"@neo4j-ndl/base": "^2.6.
|
|
96
|
+
"@neo4j-ndl/base": "^2.6.1",
|
|
97
97
|
"@table-nav/core": "0.0.7",
|
|
98
98
|
"@table-nav/react": "0.0.7",
|
|
99
99
|
"@tanstack/react-table": "^8.9.3",
|