@pdg/react-table 1.0.42 → 1.0.43
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/InfoTable/InfoTable.types.d.ts +3 -1
- package/dist/index.esm.js +3 -2
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +3 -2
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -41,6 +41,8 @@ export interface InfoTableProps<T = InfoTableInfo> {
|
|
|
41
41
|
xl?: InfoTableCols;
|
|
42
42
|
};
|
|
43
43
|
spacing?: GridProps['spacing'];
|
|
44
|
+
columnSpacing?: GridProps['spacing'];
|
|
45
|
+
rowSpacing?: GridProps['spacing'];
|
|
44
46
|
className?: string;
|
|
45
47
|
style?: CommonSxProps['style'];
|
|
46
48
|
sx?: CommonSxProps['sx'];
|
|
@@ -57,4 +59,4 @@ export interface InfoTableProps<T = InfoTableInfo> {
|
|
|
57
59
|
items: InfoTableItems<T>;
|
|
58
60
|
onCopyToClipboard?(item: InfoTableItem<T>, text: string): void;
|
|
59
61
|
}
|
|
60
|
-
export declare const InfoTableDefaultProps: Pick<InfoTableProps, 'spacing' | 'labelColor'>;
|
|
62
|
+
export declare const InfoTableDefaultProps: Pick<InfoTableProps, 'spacing' | 'columnSpacing' | 'rowSpacing' | 'labelColor'>;
|
package/dist/index.esm.js
CHANGED
|
@@ -9830,6 +9830,7 @@ TableButton.defaultProps = TableButtonDefaultProps;var TableMenuButtonDefaultPro
|
|
|
9830
9830
|
TableMenuButton.displayName = 'TableMenuButton';
|
|
9831
9831
|
TableMenuButton.defaultProps = TableMenuButtonDefaultProps;var InfoTableDefaultProps = {
|
|
9832
9832
|
spacing: 2,
|
|
9833
|
+
rowSpacing: 3,
|
|
9833
9834
|
labelColor: 'primary',
|
|
9834
9835
|
};var Label = styled(Box)(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n font-size: 12px;\n font-weight: bold;\n"], ["\n font-size: 12px;\n font-weight: bold;\n"])));
|
|
9835
9836
|
var ValueWrap = styled(Box)(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n margin-top: 3px;\n position: relative;\n display: flex;\n flex-direction: row;\n"], ["\n margin-top: 3px;\n position: relative;\n display: flex;\n flex-direction: row;\n"])));
|
|
@@ -10102,7 +10103,7 @@ _defineProperty(CopyToClipboard$1, "defaultProps", {
|
|
|
10102
10103
|
|
|
10103
10104
|
CopyToClipboard.CopyToClipboard = CopyToClipboard;
|
|
10104
10105
|
var lib = CopyToClipboard;var InfoTable = function (_a) {
|
|
10105
|
-
var cols = _a.cols, spacing = _a.spacing, className = _a.className, style = _a.style, sx = _a.sx, labelClassName = _a.labelClassName, labelColor = _a.labelColor, labelStyle = _a.labelStyle, labelSx = _a.labelSx, valueClassName = _a.valueClassName, valueStyle = _a.valueStyle, valueSx = _a.valueSx, ellipsis = _a.ellipsis, valueUnderline = _a.valueUnderline, info = _a.info, items = _a.items, onCopyToClipboard = _a.onCopyToClipboard;
|
|
10106
|
+
var cols = _a.cols, spacing = _a.spacing, columnSpacing = _a.columnSpacing, rowSpacing = _a.rowSpacing, className = _a.className, style = _a.style, sx = _a.sx, labelClassName = _a.labelClassName, labelColor = _a.labelColor, labelStyle = _a.labelStyle, labelSx = _a.labelSx, valueClassName = _a.valueClassName, valueStyle = _a.valueStyle, valueSx = _a.valueSx, ellipsis = _a.ellipsis, valueUnderline = _a.valueUnderline, info = _a.info, items = _a.items, onCopyToClipboard = _a.onCopyToClipboard;
|
|
10106
10107
|
var sizeProps = useMemo(function () {
|
|
10107
10108
|
var value = {};
|
|
10108
10109
|
if (typeof cols === 'number') {
|
|
@@ -10122,7 +10123,7 @@ var lib = CopyToClipboard;var InfoTable = function (_a) {
|
|
|
10122
10123
|
}
|
|
10123
10124
|
return value;
|
|
10124
10125
|
}, [cols]);
|
|
10125
|
-
return (React__default.createElement(Grid, { container: true, spacing: spacing, className: classNames('InfoTable', className), style: style, sx: sx }, items.map(function (item, idx) {
|
|
10126
|
+
return (React__default.createElement(Grid, { container: true, spacing: spacing, columnSpacing: columnSpacing, rowSpacing: rowSpacing, className: classNames('InfoTable', className), style: style, sx: sx }, items.map(function (item, idx) {
|
|
10126
10127
|
if (item) {
|
|
10127
10128
|
var finalLabelColor = typographyColorToSxColor(item.labelColor || labelColor);
|
|
10128
10129
|
var finalLabelSx = combineSx(labelSx, item.labelSx, !!finalLabelColor && { color: finalLabelColor });
|