@ballistix.digital/react-components 0.4.104 → 0.4.105
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.ts +2 -1
- package/dist/index.esm.js +4 -4
- package/dist/index.js +4 -4
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -105,7 +105,7 @@ type TProps$c = {
|
|
|
105
105
|
trigger?: ReactNode;
|
|
106
106
|
type?: 'button' | 'compact';
|
|
107
107
|
direction?: 'bottom-left' | 'bottom-right' | 'top-left' | 'top-right';
|
|
108
|
-
|
|
108
|
+
isEscapingOverflow?: boolean;
|
|
109
109
|
styles?: TDropdownElementStyles;
|
|
110
110
|
};
|
|
111
111
|
declare const DropdownElement: {
|
|
@@ -529,6 +529,7 @@ type TNavigationItemProps$1 = {
|
|
|
529
529
|
isInitial?: boolean;
|
|
530
530
|
onClick?: ((accessor: MouseEvent) => void) | any;
|
|
531
531
|
styles?: Pick<TTabNavigationStyles, 'tab'>;
|
|
532
|
+
isLoading?: boolean;
|
|
532
533
|
};
|
|
533
534
|
type TViewProps$1 = {
|
|
534
535
|
children: ReactNode;
|
package/dist/index.esm.js
CHANGED
|
@@ -3382,7 +3382,7 @@ var styles$k = {
|
|
|
3382
3382
|
};
|
|
3383
3383
|
|
|
3384
3384
|
var Container$3 = function (props) {
|
|
3385
|
-
var children = props.children, label = props.label, trigger = props.trigger, _a = props.type, type = _a === void 0 ? 'button' : _a, _b = props.direction, direction = _b === void 0 ? 'bottom-left' : _b, _c = props.
|
|
3385
|
+
var children = props.children, label = props.label, trigger = props.trigger, _a = props.type, type = _a === void 0 ? 'button' : _a, _b = props.direction, direction = _b === void 0 ? 'bottom-left' : _b, _c = props.isEscapingOverflow, isEscapingOverflow = _c === void 0 ? false : _c, stylesOverrides = props.styles;
|
|
3386
3386
|
var handleGenerateStyle = function () {
|
|
3387
3387
|
var result = deepCopyObject(styles$j.base);
|
|
3388
3388
|
var keys = calculateNestedKeys(styles$j.base);
|
|
@@ -3392,7 +3392,7 @@ var Container$3 = function (props) {
|
|
|
3392
3392
|
return result;
|
|
3393
3393
|
};
|
|
3394
3394
|
var styles = handleGenerateStyle();
|
|
3395
|
-
return (jsxs(Menu, __assign({ as: "div", className: toClassName(styles.container, !
|
|
3395
|
+
return (jsxs(Menu, __assign({ as: "div", className: toClassName(styles.container, !isEscapingOverflow && 'relative') }, { children: [jsxs("div", { children: [type === 'button' &&
|
|
3396
3396
|
(!trigger ? (jsxs(Menu.Button, __assign({ className: styles.button }, { children: [label, jsx(ChevronDownIcon, { className: "-mr-1 ml-2 h-5 w-5", "aria-hidden": "true" })] }))) : (jsx(Menu.Button, { children: trigger }))), type === 'compact' && (jsxs(Menu.Button, __assign({ className: styles.compact }, { children: [jsx("span", __assign({ className: "sr-only" }, { children: label })), jsx(EllipsisVerticalIcon, { className: styles.dots, "aria-hidden": "true" })] })))] }), jsx(Transition, __assign({ as: Fragment, enter: "transition ease-out duration-100", enterFrom: "transform opacity-0 scale-95", enterTo: "transform opacity-100 scale-100", leave: "transition ease-in duration-75", leaveFrom: "transform opacity-100 scale-100", leaveTo: "transform opacity-0 scale-95" }, { children: jsx(Menu.Items, __assign({ className: styles.items }, { children: children })) }))] })));
|
|
3397
3397
|
};
|
|
3398
3398
|
var DropdownElement = {
|
|
@@ -4612,7 +4612,7 @@ var List$1 = function (props) {
|
|
|
4612
4612
|
}) }))] })), jsx("div", __assign({ className: styles.list.body }, { children: jsx("nav", __assign({ className: styles.list.navigation }, { children: children })) }))] })));
|
|
4613
4613
|
};
|
|
4614
4614
|
var Item$2 = function (props) {
|
|
4615
|
-
var children = props.children, _a = props.as, LinkComponent = _a === void 0 ? 'a' : _a, _b = props.type, type = _b === void 0 ? 'underline' : _b, href = props.href, isCurrent = props.isCurrent, onClick = props.onClick, stylesOverrides = props.styles;
|
|
4615
|
+
var children = props.children, _a = props.as, LinkComponent = _a === void 0 ? 'a' : _a, _b = props.type, type = _b === void 0 ? 'underline' : _b, href = props.href, isCurrent = props.isCurrent, onClick = props.onClick, stylesOverrides = props.styles, _c = props.isLoading, isLoading = _c === void 0 ? true : _c;
|
|
4616
4616
|
var handleGenerateStyle = function () {
|
|
4617
4617
|
var result = deepCopyObject(styles$7.base);
|
|
4618
4618
|
var keys = calculateNestedKeys(styles$7.base);
|
|
@@ -4625,7 +4625,7 @@ var Item$2 = function (props) {
|
|
|
4625
4625
|
if (href && LinkComponent) {
|
|
4626
4626
|
return (jsx(LinkComponent, __assign({ href: href, className: toClassName(styles.tab.base, isCurrent ? styles.tab.active : styles.tab.inactive), onClick: onClick }, { children: children })));
|
|
4627
4627
|
}
|
|
4628
|
-
return (jsx("div", __assign({ className: toClassName(styles.tab.base, isCurrent ? styles.tab.active : styles.tab.inactive), onClick: onClick }, { children: children })));
|
|
4628
|
+
return (jsx("div", __assign({ className: toClassName(styles.tab.base, isCurrent ? styles.tab.active : styles.tab.inactive, isLoading && 'opacity-30 !text-gray-300 !cursor-default', isLoading && styles.tab.inactive), onClick: !isLoading ? onClick : function () { return null; } }, { children: children })));
|
|
4629
4629
|
};
|
|
4630
4630
|
var View$1 = function (props) {
|
|
4631
4631
|
var children = props.children;
|
package/dist/index.js
CHANGED
|
@@ -3393,7 +3393,7 @@ var styles$k = {
|
|
|
3393
3393
|
};
|
|
3394
3394
|
|
|
3395
3395
|
var Container$3 = function (props) {
|
|
3396
|
-
var children = props.children, label = props.label, trigger = props.trigger, _a = props.type, type = _a === void 0 ? 'button' : _a, _b = props.direction, direction = _b === void 0 ? 'bottom-left' : _b, _c = props.
|
|
3396
|
+
var children = props.children, label = props.label, trigger = props.trigger, _a = props.type, type = _a === void 0 ? 'button' : _a, _b = props.direction, direction = _b === void 0 ? 'bottom-left' : _b, _c = props.isEscapingOverflow, isEscapingOverflow = _c === void 0 ? false : _c, stylesOverrides = props.styles;
|
|
3397
3397
|
var handleGenerateStyle = function () {
|
|
3398
3398
|
var result = deepCopyObject(styles$j.base);
|
|
3399
3399
|
var keys = calculateNestedKeys(styles$j.base);
|
|
@@ -3403,7 +3403,7 @@ var Container$3 = function (props) {
|
|
|
3403
3403
|
return result;
|
|
3404
3404
|
};
|
|
3405
3405
|
var styles = handleGenerateStyle();
|
|
3406
|
-
return (jsxRuntime.jsxs(react.Menu, __assign({ as: "div", className: toClassName(styles.container, !
|
|
3406
|
+
return (jsxRuntime.jsxs(react.Menu, __assign({ as: "div", className: toClassName(styles.container, !isEscapingOverflow && 'relative') }, { children: [jsxRuntime.jsxs("div", { children: [type === 'button' &&
|
|
3407
3407
|
(!trigger ? (jsxRuntime.jsxs(react.Menu.Button, __assign({ className: styles.button }, { children: [label, jsxRuntime.jsx(solid.ChevronDownIcon, { className: "-mr-1 ml-2 h-5 w-5", "aria-hidden": "true" })] }))) : (jsxRuntime.jsx(react.Menu.Button, { children: trigger }))), type === 'compact' && (jsxRuntime.jsxs(react.Menu.Button, __assign({ className: styles.compact }, { children: [jsxRuntime.jsx("span", __assign({ className: "sr-only" }, { children: label })), jsxRuntime.jsx(solid.EllipsisVerticalIcon, { className: styles.dots, "aria-hidden": "true" })] })))] }), jsxRuntime.jsx(react.Transition, __assign({ as: React.Fragment, enter: "transition ease-out duration-100", enterFrom: "transform opacity-0 scale-95", enterTo: "transform opacity-100 scale-100", leave: "transition ease-in duration-75", leaveFrom: "transform opacity-100 scale-100", leaveTo: "transform opacity-0 scale-95" }, { children: jsxRuntime.jsx(react.Menu.Items, __assign({ className: styles.items }, { children: children })) }))] })));
|
|
3408
3408
|
};
|
|
3409
3409
|
var DropdownElement = {
|
|
@@ -4623,7 +4623,7 @@ var List$1 = function (props) {
|
|
|
4623
4623
|
}) }))] })), jsxRuntime.jsx("div", __assign({ className: styles.list.body }, { children: jsxRuntime.jsx("nav", __assign({ className: styles.list.navigation }, { children: children })) }))] })));
|
|
4624
4624
|
};
|
|
4625
4625
|
var Item$2 = function (props) {
|
|
4626
|
-
var children = props.children, _a = props.as, LinkComponent = _a === void 0 ? 'a' : _a, _b = props.type, type = _b === void 0 ? 'underline' : _b, href = props.href, isCurrent = props.isCurrent, onClick = props.onClick, stylesOverrides = props.styles;
|
|
4626
|
+
var children = props.children, _a = props.as, LinkComponent = _a === void 0 ? 'a' : _a, _b = props.type, type = _b === void 0 ? 'underline' : _b, href = props.href, isCurrent = props.isCurrent, onClick = props.onClick, stylesOverrides = props.styles, _c = props.isLoading, isLoading = _c === void 0 ? true : _c;
|
|
4627
4627
|
var handleGenerateStyle = function () {
|
|
4628
4628
|
var result = deepCopyObject(styles$7.base);
|
|
4629
4629
|
var keys = calculateNestedKeys(styles$7.base);
|
|
@@ -4636,7 +4636,7 @@ var Item$2 = function (props) {
|
|
|
4636
4636
|
if (href && LinkComponent) {
|
|
4637
4637
|
return (jsxRuntime.jsx(LinkComponent, __assign({ href: href, className: toClassName(styles.tab.base, isCurrent ? styles.tab.active : styles.tab.inactive), onClick: onClick }, { children: children })));
|
|
4638
4638
|
}
|
|
4639
|
-
return (jsxRuntime.jsx("div", __assign({ className: toClassName(styles.tab.base, isCurrent ? styles.tab.active : styles.tab.inactive), onClick: onClick }, { children: children })));
|
|
4639
|
+
return (jsxRuntime.jsx("div", __assign({ className: toClassName(styles.tab.base, isCurrent ? styles.tab.active : styles.tab.inactive, isLoading && 'opacity-30 !text-gray-300 !cursor-default', isLoading && styles.tab.inactive), onClick: !isLoading ? onClick : function () { return null; } }, { children: children })));
|
|
4640
4640
|
};
|
|
4641
4641
|
var View$1 = function (props) {
|
|
4642
4642
|
var children = props.children;
|