@coldsmirk/ledger-mantine 0.5.1 → 0.6.0

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/styles.css CHANGED
@@ -18,11 +18,19 @@
18
18
  * degrades to content height when the parent is indefinite. min-width/min-height: 0
19
19
  * pre-defuse the flex/grid min-size:auto shrink trap; overflow only ever appears on the
20
20
  * internal scroller.
21
+ *
22
+ * The root is a one-column grid, the elastic row first and the pagination bar under it — not
23
+ * a flex column: under a max height (`mah`) a grid resolves its `1fr` row against the cap
24
+ * (CSS Grid §12.7.1), so the main region stretched into it has a definite height, and so does
25
+ * the scroller's viewport (`height: 100%`). A flex column leaves that height indefinite: the
26
+ * viewport grows to its content and nothing scrolls. A definite parent's row fills it, and an
27
+ * indefinite parent's follows the content, as before.
21
28
  * ------------------------------------------------------------------------------------------ */
22
29
  .ledger-root {
23
30
  position: relative;
24
- display: flex;
25
- flex-direction: column;
31
+ display: grid;
32
+ grid-template-rows: minmax(0, 1fr) auto;
33
+ grid-template-columns: minmax(0, 1fr);
26
34
  width: 100%;
27
35
  min-width: 0;
28
36
  height: 100%;
@@ -58,7 +66,6 @@
58
66
  its box, and the row-drag ghost is portaled to the body. */
59
67
  .ledger-main {
60
68
  display: flex;
61
- flex: 1 1 auto;
62
69
  flex-direction: column;
63
70
  min-width: 0;
64
71
  min-height: 0;
@@ -120,7 +127,7 @@
120
127
  .ledger-header-cell {
121
128
  position: relative;
122
129
  vertical-align: middle;
123
- background-color: var(--ledger-header-bg, var(--mantine-color-body));
130
+ background-color: var(--ledger-header-bg, var(--ledger-body-bg, var(--mantine-color-body)));
124
131
  }
125
132
 
126
133
  .ledger-header-cell[data-pinned] {
@@ -309,7 +316,7 @@
309
316
  * their hover step < the cursor inside a selection < pinned < the editing row (below).
310
317
  * ------------------------------------------------------------------------------------------ */
311
318
  .ledger-row {
312
- --ledger-pinned-bg: var(--ledger-row-bg, var(--mantine-color-body));
319
+ --ledger-pinned-bg: var(--ledger-row-bg, var(--ledger-body-bg, var(--mantine-color-body)));
313
320
  }
314
321
 
315
322
  .ledger-row > td {
@@ -360,7 +367,7 @@
360
367
  /* Sticky pinned rows sit at the body scroller's edges, above the flow (the header lives
361
368
  outside the scroller, so top offsets start at 0). */
362
369
  .ledger-row[data-pinned-row] {
363
- --ledger-row-bg: var(--mantine-color-body);
370
+ --ledger-row-bg: var(--ledger-body-bg, var(--mantine-color-body));
364
371
  position: sticky;
365
372
  z-index: 2;
366
373
  }
@@ -389,7 +396,7 @@
389
396
  .ledger-footer-cell[data-pinned] {
390
397
  position: sticky;
391
398
  z-index: 2;
392
- background-color: var(--ledger-pinned-bg, var(--mantine-color-body));
399
+ background-color: var(--ledger-pinned-bg, var(--ledger-body-bg, var(--mantine-color-body)));
393
400
  }
394
401
 
395
402
  /* Pinned-edge scroll shadows, visible only while content is actually scrolled past. */
@@ -555,7 +562,7 @@
555
562
  z-index: var(--mantine-z-index-popover);
556
563
  overflow: hidden;
557
564
  pointer-events: none;
558
- background-color: var(--mantine-color-body);
565
+ background-color: var(--ledger-body-bg, var(--mantine-color-body));
559
566
  border: 1px solid var(--mantine-color-default-border);
560
567
  border-radius: var(--mantine-radius-default);
561
568
  box-shadow: var(--mantine-shadow-md);
@@ -570,7 +577,7 @@
570
577
 
571
578
  .ledger-footer-cell {
572
579
  font-weight: 600;
573
- background-color: var(--mantine-color-body);
580
+ background-color: var(--ledger-body-bg, var(--mantine-color-body));
574
581
  }
575
582
 
576
583
  /* Overlaid on the whole body region (the scroller is its positioning context): centered in
@@ -600,7 +607,7 @@
600
607
  rows survive as a ghost that says "still here, not current". */
601
608
  .ledger-empty[data-over-rows] {
602
609
  z-index: 2;
603
- background-color: color-mix(in srgb, var(--mantine-color-body) 92%, transparent);
610
+ background-color: color-mix(in srgb, var(--ledger-body-bg, var(--mantine-color-body)) 92%, transparent);
604
611
  }
605
612
 
606
613
  .ledger-loader-row td {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@coldsmirk/ledger-mantine",
3
- "version": "0.5.1",
3
+ "version": "0.6.0",
4
4
  "description": "Mantine-native <DataTable> on TanStack Table and TanStack Virtual: sorting, filtering, pagination, selection, pinning, inline editing, and adaptive row virtualization.",
5
5
  "keywords": [
6
6
  "data-table",