@7shifts/sous-chef 3.3.5 → 3.3.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.
- package/dist/index.js +10 -13
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +10 -13
- package/dist/index.modern.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -578,15 +578,16 @@ var Tooltip = function Tooltip(_ref, forwardedRef) {
|
|
|
578
578
|
};
|
|
579
579
|
|
|
580
580
|
var anchorElements = React__default.Children.count(children);
|
|
581
|
+
var isTableCell = anchorElements === 1 && children.props.role === 'cell';
|
|
581
582
|
|
|
582
|
-
if (!overlay && !header || anchorElements === 0) {
|
|
583
|
+
if (!overlay && !header && !isTableCell || anchorElements === 0) {
|
|
583
584
|
return children;
|
|
584
585
|
}
|
|
585
586
|
|
|
586
587
|
var anchorPosition = typeof containerRef !== 'function' && (containerRef === null || containerRef === void 0 ? void 0 : (_containerRef$current = containerRef.current) === null || _containerRef$current === void 0 ? void 0 : _containerRef$current.getBoundingClientRect());
|
|
587
588
|
|
|
588
589
|
var Overlay = function Overlay() {
|
|
589
|
-
return isVisible && anchorPosition ? React__default.createElement(TooltipOverlay, {
|
|
590
|
+
return overlay && isVisible && anchorPosition ? React__default.createElement(TooltipOverlay, {
|
|
590
591
|
anchorPosition: anchorPosition,
|
|
591
592
|
placement: placement,
|
|
592
593
|
theme: theme,
|
|
@@ -5404,7 +5405,8 @@ var DataTableEditableCellElement = function DataTableEditableCellElement(_ref, r
|
|
|
5404
5405
|
};
|
|
5405
5406
|
var EditableCell = React__default.createElement("div", {
|
|
5406
5407
|
className: classnames((_classnames = {}, _classnames[styles$n['data-table-editable-cell--currency']] = type === 'currency', _classnames), styles$n['data-table-editable-cell']),
|
|
5407
|
-
"data-testid": testId
|
|
5408
|
+
"data-testid": testId,
|
|
5409
|
+
role: "cell"
|
|
5408
5410
|
}, React__default.createElement(Field, Object.assign({}, fieldProps), React__default.createElement(AffixContainer, {
|
|
5409
5411
|
prefix: prefix,
|
|
5410
5412
|
suffix: suffix
|
|
@@ -5425,16 +5427,11 @@ var DataTableEditableCellElement = function DataTableEditableCellElement(_ref, r
|
|
|
5425
5427
|
onBlur: controllers.onBlur,
|
|
5426
5428
|
ref: ref
|
|
5427
5429
|
}))));
|
|
5428
|
-
|
|
5429
|
-
|
|
5430
|
-
|
|
5431
|
-
|
|
5432
|
-
|
|
5433
|
-
theme: "white"
|
|
5434
|
-
}, EditableCell);
|
|
5435
|
-
}
|
|
5436
|
-
|
|
5437
|
-
return EditableCell;
|
|
5430
|
+
return React__default.createElement(Tooltip$1, {
|
|
5431
|
+
overlay: errorMessage,
|
|
5432
|
+
placement: "top",
|
|
5433
|
+
theme: "white"
|
|
5434
|
+
}, EditableCell);
|
|
5438
5435
|
};
|
|
5439
5436
|
|
|
5440
5437
|
var DataTableEditableCell = React.forwardRef(DataTableEditableCellElement);
|