@m4l/components 9.2.63-JT14072025.beta.1 → 9.2.63-JT15072025.beta.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.
|
@@ -263,6 +263,9 @@ const dataGridStyles = {
|
|
|
263
263
|
border: theme.vars.size.borderStroke.container,
|
|
264
264
|
borderColor: theme.vars.palette?.border.secondary,
|
|
265
265
|
"& .rdg ": {
|
|
266
|
+
display: "grid",
|
|
267
|
+
contain: "content",
|
|
268
|
+
boxSizing: "border-box",
|
|
266
269
|
border: "none",
|
|
267
270
|
background: theme.vars.palette.background.default,
|
|
268
271
|
gridColumnGap: theme.vars.size.baseSpacings.sp0,
|
|
@@ -291,6 +294,19 @@ const dataGridStyles = {
|
|
|
291
294
|
boxShadow: `inset 0 0.5px 0 0 ${theme.vars.palette?.border.secondary}`
|
|
292
295
|
}
|
|
293
296
|
},
|
|
297
|
+
"&.MeasuringCell": {
|
|
298
|
+
contain: "strict",
|
|
299
|
+
gridRow: "1",
|
|
300
|
+
visibility: "hidden"
|
|
301
|
+
},
|
|
302
|
+
"&::before": {
|
|
303
|
+
content: "''",
|
|
304
|
+
gridColumn: "1/-1",
|
|
305
|
+
gridRow: "1/-1"
|
|
306
|
+
},
|
|
307
|
+
'& [role="row"], & .rdg-row, & .rdg-header-row, & .rdg-summary-row': {
|
|
308
|
+
display: "contents"
|
|
309
|
+
},
|
|
294
310
|
'& [role="columnheader"]': {
|
|
295
311
|
justifyContent: "center",
|
|
296
312
|
alignItems: "center",
|
|
@@ -306,6 +322,13 @@ const dataGridStyles = {
|
|
|
306
322
|
}
|
|
307
323
|
},
|
|
308
324
|
"& .rdg-row": {
|
|
325
|
+
display: "contents",
|
|
326
|
+
'&[aria-selected="true"]': {
|
|
327
|
+
backgroundColor: theme.vars.palette.primary.toneOpacity,
|
|
328
|
+
"&:hover": {
|
|
329
|
+
backgroundColor: theme.vars.palette.primary.toneOpacity
|
|
330
|
+
}
|
|
331
|
+
},
|
|
309
332
|
"& .rdg-cell": {
|
|
310
333
|
backgroundColor: theme.vars.palette.background.default
|
|
311
334
|
},
|
|
@@ -329,19 +352,29 @@ const dataGridStyles = {
|
|
|
329
352
|
backgroundColor: "transparent"
|
|
330
353
|
},
|
|
331
354
|
"& .rdg-cell": {
|
|
355
|
+
overflow: "clip",
|
|
356
|
+
position: "sticky",
|
|
357
|
+
outline: "none",
|
|
332
358
|
color: theme.vars.palette.text.primary,
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
359
|
+
paddingBlock: 0,
|
|
360
|
+
paddingInline: "8px",
|
|
361
|
+
borderInlineEnd: "1px solid var(--rdg-border-color)",
|
|
362
|
+
borderBlockEnd: "1px solid var(--rdg-border-color)",
|
|
363
|
+
gridRowStart: "var(--rdg-grid-row-start)",
|
|
364
|
+
alignContent: "center",
|
|
365
|
+
backgroundColor: "inherit",
|
|
366
|
+
whiteSpace: "nowrap",
|
|
367
|
+
textOverflow: "ellipsis",
|
|
339
368
|
...getTypographyStyles(
|
|
340
369
|
theme.generalSettings.isMobile,
|
|
341
370
|
ownerState?.size || "medium",
|
|
342
371
|
"body"
|
|
343
372
|
),
|
|
344
373
|
lineHeight: "var(--rdg-row-height)!important",
|
|
374
|
+
'&[aria-selected="true"]': {
|
|
375
|
+
outline: `2px solid var(--rdg-selection-color)`,
|
|
376
|
+
outlineOffset: "-2px"
|
|
377
|
+
},
|
|
345
378
|
"& .checkbox-checked": {
|
|
346
379
|
"& path:first-of-type": {
|
|
347
380
|
fill: theme.vars.palette.primary.main
|
|
@@ -403,6 +436,11 @@ const dataGridStyles = {
|
|
|
403
436
|
height: "100%"
|
|
404
437
|
},
|
|
405
438
|
'&[role="columnheader"]': {
|
|
439
|
+
position: "sticky",
|
|
440
|
+
top: 0,
|
|
441
|
+
zIndex: 2,
|
|
442
|
+
justifyContent: "center",
|
|
443
|
+
alignItems: "center",
|
|
406
444
|
'&[aria-colindex="1"]': {
|
|
407
445
|
borderTopLeftRadius: theme.vars.size.baseSpacings.sp2
|
|
408
446
|
}
|
|
@@ -501,7 +539,16 @@ const dataGridStyles = {
|
|
|
501
539
|
borderColor: theme.vars.palette.background.surface
|
|
502
540
|
},
|
|
503
541
|
"& .rdg-header-row": {
|
|
504
|
-
|
|
542
|
+
display: "contents",
|
|
543
|
+
backgroundColor: theme.vars.palette.background.base,
|
|
544
|
+
fontWeight: "bold",
|
|
545
|
+
"& > .rdg-cell": {
|
|
546
|
+
zIndex: 2,
|
|
547
|
+
position: "sticky"
|
|
548
|
+
},
|
|
549
|
+
"& > .rdg-cell.rdg-cell-frozen": {
|
|
550
|
+
zIndex: 3
|
|
551
|
+
}
|
|
505
552
|
},
|
|
506
553
|
// Estilado de celdas de la cabecera
|
|
507
554
|
"& .rdg-header-row .rdg-cell": {
|
|
@@ -510,9 +557,13 @@ const dataGridStyles = {
|
|
|
510
557
|
boxShadow: "unset!important",
|
|
511
558
|
borderBottom: theme.vars.size.borderStroke.container,
|
|
512
559
|
borderColor: `${theme.vars.palette?.background.surface}!important`,
|
|
560
|
+
cursor: "pointer",
|
|
513
561
|
"&:hover": {
|
|
514
562
|
boxShadow: `inset 1px 0 0 0 ${theme.vars.palette?.border.default}, inset -1px 0 0 0 ${theme.vars.palette?.border.default}!important `
|
|
515
563
|
},
|
|
564
|
+
"&[data-resize]": {
|
|
565
|
+
touchAction: "none"
|
|
566
|
+
},
|
|
516
567
|
'& [draggable="true"]': {
|
|
517
568
|
fontSize: theme.typography.body
|
|
518
569
|
},
|
|
@@ -534,6 +585,15 @@ const dataGridStyles = {
|
|
|
534
585
|
// Modificar el tamaño de la flecha
|
|
535
586
|
"& .rdg-sort-arrow": {}
|
|
536
587
|
},
|
|
588
|
+
// Estilo específico para el resize handle generado por react-data-grid
|
|
589
|
+
'& [class*="r1y6ywlx"]': {
|
|
590
|
+
cursor: "col-resize",
|
|
591
|
+
position: "absolute",
|
|
592
|
+
insetBlockStart: 0,
|
|
593
|
+
insetInlineEnd: 0,
|
|
594
|
+
insetBlockEnd: 0,
|
|
595
|
+
inlineSize: "10px"
|
|
596
|
+
},
|
|
537
597
|
// Estilado de la ultima celda Header
|
|
538
598
|
"& .rdg-header-row :last-child.rdg-cell": {
|
|
539
599
|
borderTopRightRadius: theme.vars.size.baseSpacings.sp0,
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { useMemo, useState, useRef, useEffect } from "react";
|
|
3
3
|
import DataGrid from "react-data-grid";
|
|
4
|
-
import "react-data-grid/lib/styles.css";
|
|
5
4
|
import { DndProvider } from "react-dnd";
|
|
6
5
|
import { HTML5Backend } from "react-dnd-html5-backend";
|
|
7
6
|
import { C as CheckboxFormatter } from "./subcomponents/CheckboxFormatter.js";
|