@true-engineering/true-react-common-ui-kit 4.0.0-alpha24 → 4.0.0-alpha25
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/package.json
CHANGED
|
@@ -121,10 +121,8 @@ export const WithPopup: FC<IWithPopupProps> = ({
|
|
|
121
121
|
|
|
122
122
|
const handleToggle = (isActive: boolean, event?: IWithPopupToggleEvent) => {
|
|
123
123
|
event?.stopPropagation();
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
setIsOpen(isActive);
|
|
127
|
-
}
|
|
124
|
+
onToggle?.(isActive, event);
|
|
125
|
+
setIsOpen(isActive);
|
|
128
126
|
};
|
|
129
127
|
|
|
130
128
|
const handleClose = (event?: IWithPopupToggleEvent) => {
|
|
@@ -132,7 +130,7 @@ export const WithPopup: FC<IWithPopupProps> = ({
|
|
|
132
130
|
};
|
|
133
131
|
|
|
134
132
|
const { refs, floatingStyles, context } = useFloating({
|
|
135
|
-
open: isOpen,
|
|
133
|
+
open: isOpen && !isDisabled,
|
|
136
134
|
middleware: [
|
|
137
135
|
offset(popupOffset),
|
|
138
136
|
canBeFlipped && flip({ fallbackAxisSideDirection: 'start' }),
|