@cashub/ui 0.42.0 → 0.42.1
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
|
@@ -232,6 +232,7 @@ const InfiniteGridTable = _ref => {
|
|
|
232
232
|
"data-index": index,
|
|
233
233
|
style: {
|
|
234
234
|
position: 'absolute',
|
|
235
|
+
display: 'flex',
|
|
235
236
|
left: 0,
|
|
236
237
|
top: "".concat(top, "px")
|
|
237
238
|
},
|
|
@@ -324,36 +325,31 @@ const TableWrapper = _styledComponents.default.div(_templateObject || (_template
|
|
|
324
325
|
return backgroundReverse ? 'var(--color-background1)' : 'var(--color-background2)';
|
|
325
326
|
});
|
|
326
327
|
const ResponsiveTable = _styledComponents.default.table(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n /* make fixed width work */\n position: relative;\n width: 0px;\n color: var(--font-on-background);\n table-layout: fixed;\n border-collapse: collapse;\n"])));
|
|
327
|
-
const TD = _styledComponents.default.td(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n
|
|
328
|
+
const TD = _styledComponents.default.td(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n align-content: center;\n width: ", ";\n height: 48px;\n padding: 0 var(--spacing-xs);\n border-top: 1px solid var(--border-color);\n border-right: 1px solid var(--border-color);\n border-bottom: 1px solid var(--border-color);\n text-align: ", ";\n background: ", ";\n\n &:last-child {\n border-right: none;\n padding: 0;\n }\n\n > span {\n display: inline-block;\n width: 100%;\n padding: 0 2px;\n overflow: hidden;\n white-space: pre;\n text-overflow: ellipsis;\n }\n"])), _ref3 => {
|
|
328
329
|
let {
|
|
329
330
|
$width
|
|
330
331
|
} = _ref3;
|
|
331
332
|
return $width;
|
|
332
333
|
}, _ref4 => {
|
|
333
|
-
let {
|
|
334
|
-
$width
|
|
335
|
-
} = _ref4;
|
|
336
|
-
return $width;
|
|
337
|
-
}, _ref5 => {
|
|
338
334
|
let {
|
|
339
335
|
center
|
|
340
|
-
} =
|
|
336
|
+
} = _ref4;
|
|
341
337
|
return center ? 'center' : 'left';
|
|
342
|
-
},
|
|
338
|
+
}, _ref5 => {
|
|
343
339
|
let {
|
|
344
340
|
backgroundReverse
|
|
345
|
-
} =
|
|
341
|
+
} = _ref5;
|
|
346
342
|
return backgroundReverse ? 'var(--color-background1)' : 'var(--color-background2)';
|
|
347
343
|
});
|
|
348
|
-
const Scrollbar = _styledComponents.default.div(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n position: sticky;\n bottom: 0;\n width: 100%;\n overflow: auto;\n background: ", ";\n\n ::before {\n display: block;\n content: '';\n width: ", ";\n height: 1px;\n }\n\n ", "\n"])),
|
|
344
|
+
const Scrollbar = _styledComponents.default.div(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n position: sticky;\n bottom: 0;\n width: 100%;\n overflow: auto;\n background: ", ";\n\n ::before {\n display: block;\n content: '';\n width: ", ";\n height: 1px;\n }\n\n ", "\n"])), _ref6 => {
|
|
349
345
|
let {
|
|
350
346
|
backgroundReverse
|
|
351
|
-
} =
|
|
347
|
+
} = _ref6;
|
|
352
348
|
return backgroundReverse ? 'var(--color-background1)' : 'var(--color-background2)';
|
|
353
|
-
},
|
|
349
|
+
}, _ref7 => {
|
|
354
350
|
let {
|
|
355
351
|
width
|
|
356
|
-
} =
|
|
352
|
+
} = _ref7;
|
|
357
353
|
return "".concat(width, "px");
|
|
358
354
|
}, (0, _scrollbar.default)({
|
|
359
355
|
size: 'large'
|
|
@@ -19,7 +19,10 @@ const Resizer = _ref => {
|
|
|
19
19
|
const handleMouseMove = (0, _react.useCallback)(event => {
|
|
20
20
|
event.stopPropagation();
|
|
21
21
|
event.preventDefault();
|
|
22
|
-
|
|
22
|
+
let targetWidth = event.clientX - parentNode.getBoundingClientRect().left;
|
|
23
|
+
if (targetWidth < 1) {
|
|
24
|
+
targetWidth = 1;
|
|
25
|
+
}
|
|
23
26
|
parentNode.style.width = "".concat(targetWidth, "px");
|
|
24
27
|
if (typeof onResize === 'function') {
|
|
25
28
|
onResize(index, targetWidth);
|