@guiexpert/table 1.1.94 → 1.1.96
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/README.md +12 -0
- package/css/main.css +192 -0
- package/css/table-calc.css +7 -0
- package/css/table-color-vars.css +46 -0
- package/css/table-fill-batch.css +58 -0
- package/css/table-row-drag.css +81 -0
- package/index.cjs +39 -37
- package/index.d.ts +28 -0
- package/index.js +5501 -1934
- package/lib/table/action/action-id.type.d.ts +1 -1
- package/lib/table/aria/aria-texts.d.ts +11 -0
- package/lib/table/aria/aria-texts.if.d.ts +87 -0
- package/lib/table/batch-edit/batch-edit-options.d.ts +21 -0
- package/lib/table/batch-edit/batch-edit-options.if.d.ts +20 -0
- package/lib/table/batch-edit/batch-edit-service.d.ts +104 -0
- package/lib/table/batch-edit/cell-change.if.d.ts +39 -0
- package/lib/table/batch-edit/cell-value-change.if.d.ts +18 -0
- package/lib/table/batch-edit/pending-cell-changes.d.ts +104 -0
- package/lib/table/calc/column-values.d.ts +55 -0
- package/lib/table/calc/show-values-as-internals.d.ts +4 -0
- package/lib/table/calc/show-values-as.d.ts +87 -0
- package/lib/table/calc/show-values-as.type.d.ts +55 -0
- package/lib/table/calc/value-getter-context.if.d.ts +35 -0
- package/lib/table/calc/value-getter.type.d.ts +36 -0
- package/lib/table/data/common/event/ge-batch-edit-event.d.ts +46 -0
- package/lib/table/data/common/event/ge-model-change-event.d.ts +27 -1
- package/lib/table/data/common/event/ge-row-drag-event.d.ts +89 -0
- package/lib/table/data/options/table-options.d.ts +6 -0
- package/lib/table/data/options/table-options.if.d.ts +44 -0
- package/lib/table/data/tablemodel/areamodel/abstract-area-model.d.ts +66 -0
- package/lib/table/data/tablemodel/areamodel/area-model-aggregate-footer.d.ts +5 -0
- package/lib/table/data/tablemodel/areamodel/area-model-array-of-arrays.d.ts +24 -0
- package/lib/table/data/tablemodel/areamodel/area-model-object-array.d.ts +70 -0
- package/lib/table/data/tablemodel/areamodel/area-model-pivot.d.ts +31 -0
- package/lib/table/data/tablemodel/areamodel/area-model-row-groups.d.ts +23 -1
- package/lib/table/data/tablemodel/areamodel/area-model-tree.d.ts +83 -0
- package/lib/table/data/tablemodel/areamodel/area-model.if.d.ts +55 -0
- package/lib/table/data/tablemodel/column/column-def.d.ts +31 -1
- package/lib/table/data/tablemodel/column/column-def.if.d.ts +86 -0
- package/lib/table/event-adapter.d.ts +7 -0
- package/lib/table/event-listener.if.d.ts +32 -0
- package/lib/table/factory/table-factory.d.ts +11 -0
- package/lib/table/fill/compute-fill-changes.d.ts +67 -0
- package/lib/table/fill/fill-direction.type.d.ts +7 -0
- package/lib/table/fill/fill-handle-options.d.ts +29 -0
- package/lib/table/fill/fill-handle-options.if.d.ts +35 -0
- package/lib/table/fill/fill-handle-service.d.ts +55 -0
- package/lib/table/fill/fill-series.d.ts +60 -0
- package/lib/table/fill/fill-value-context.if.d.ts +36 -0
- package/lib/table/formula/compile-formula.d.ts +86 -0
- package/lib/table/formula/evaluator.d.ts +19 -0
- package/lib/table/formula/formula-ast.if.d.ts +42 -0
- package/lib/table/formula/formula-error.d.ts +59 -0
- package/lib/table/formula/formula-options.if.d.ts +41 -0
- package/lib/table/formula/formula-values.d.ts +13 -0
- package/lib/table/formula/functions.d.ts +18 -0
- package/lib/table/formula/parser.d.ts +10 -0
- package/lib/table/formula/tokenizer.d.ts +22 -0
- package/lib/table/pivot/pivot-value.type.d.ts +13 -0
- package/lib/table/render-scope.d.ts +81 -0
- package/lib/table/renderer/edit/input-cell-renderer.d.ts +1 -1
- package/lib/table/renderer/edit/select-cell-renderer.d.ts +1 -1
- package/lib/table/row-drag/move-rows.d.ts +157 -0
- package/lib/table/row-drag/row-drag-options.d.ts +28 -0
- package/lib/table/row-drag/row-drag-options.if.d.ts +36 -0
- package/lib/table/row-drag/row-drag-service.d.ts +130 -0
- package/lib/table/row-drag/row-drop-target.if.d.ts +29 -0
- package/lib/table/service/excel-service.d.ts +6 -0
- package/lib/table/service/excel-service.if.d.ts +35 -0
- package/lib/table/table-api.d.ts +277 -2
- package/lib/table/table-scope.d.ts +121 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -42,6 +42,18 @@ This is the UI-agnostic table component for your next web app. 😊
|
|
|
42
42
|
= a multi-row header with collapsible groups) × aggregated values, total column and total row, filter before the
|
|
43
43
|
aggregation, pivot again at runtime (`PivotFactory.createTableModel({ rows, rowFields, columnFields, values })`,
|
|
44
44
|
`tableApi.setPivotConfig()`, engine `pivotRows()`) – since 1.1.94
|
|
45
|
+
- Calculated columns (`ColumnDef.valueGetter` – sorting, filter via `tableApi.getRowValue()`, copy, Excel, totals and
|
|
46
|
+
row grouping use the computed value), „Show values as“ (`showValuesAs`: share of the column / row / grand / parent
|
|
47
|
+
total, running total, difference, rank – also per pivot value) and formulas (`formula: "[price] * [quantity] * 1.19"`,
|
|
48
|
+
own parser and interpreter without `eval`, functions like `ROUND`, `IF`, `SUM([x])`, error values `#DIV/0!`,
|
|
49
|
+
`tableApi.setColumnFormula()`) – since 1.1.95
|
|
50
|
+
- Row drag: drag handle per row (`ColumnDef.rowDrag` or `rowDrag: true` in the factory), mouse, touch and pen, ghost,
|
|
51
|
+
drop marker, auto-scroll, Escape, keyboard alternative Ctrl+Alt+↑/↓, several selected rows, trees; the table moves
|
|
52
|
+
the rows (managed) or only reports the drop (`rowDragOptions: { managed: false }`, `onRowDragEnd`) – since 1.1.95
|
|
53
|
+
- Fill handle and batch edit: a square at the corner of the selected range copies values or continues series (numbers,
|
|
54
|
+
dates, `Item 1` → `Item 2`; ⌥/Alt switches, Ctrl/⌘+D, Ctrl/⌘+R), batch edit collects changes (`ge-table-cell-pending`)
|
|
55
|
+
until `tableApi.commitBatchEdit()` / `cancelBatchEdit()`, `ColumnDef.validate`, one `onModelChanged` per change with
|
|
56
|
+
old and new values (`tableOptions.fillHandle`, `tableOptions.batchEdit`) – since 1.1.96
|
|
45
57
|
- Custom Filtering
|
|
46
58
|
- In-place Cell Editing
|
|
47
59
|
- Userdefined Key and Mouse Events
|
package/css/main.css
CHANGED
|
@@ -1,3 +1,10 @@
|
|
|
1
|
+
/* Calculated columns, „Show values as“, formulas (since 1.1.95) */
|
|
2
|
+
|
|
3
|
+
/* a cell with a formula error (#DIV/0!, #NAME? …): the message is the tooltip */
|
|
4
|
+
.ge-table-col-div.ge-table-cell-error {
|
|
5
|
+
color: var(--ge-table-cell-error-color);
|
|
6
|
+
font-variant-numeric: tabular-nums;
|
|
7
|
+
}
|
|
1
8
|
/* Defaults for the host element. :where() = zero specificity, so the app's own rules always win –
|
|
2
9
|
e.g. ".table-div { height: 500px }" no longer depends on the order in which the stylesheets are bundled. */
|
|
3
10
|
:where(.ge-table) {
|
|
@@ -446,6 +453,9 @@
|
|
|
446
453
|
--ge-table-pivot-total-font-weight: 600;
|
|
447
454
|
--ge-table-pivot-empty-text: #6b7280;
|
|
448
455
|
|
|
456
|
+
/* Formulas: error values #DIV/0!, #NAME? … (since 1.1.95) */
|
|
457
|
+
--ge-table-cell-error-color: #b91c1c;
|
|
458
|
+
|
|
449
459
|
/* Overlays "Loading…" / "No rows" (since 1.1.92) */
|
|
450
460
|
--ge-table-overlay-bg: rgba(255, 255, 255, 0.7);
|
|
451
461
|
--ge-table-overlay-content-bg: #fff;
|
|
@@ -457,6 +467,26 @@
|
|
|
457
467
|
/* Row numbers (since 1.1.93): like the header, muted digits (#555 on the header gray ≈ 6.9 : 1) */
|
|
458
468
|
--ge-table-row-number-bg: var(--ge-table-header-west-bg);
|
|
459
469
|
--ge-table-row-number-color: #555;
|
|
470
|
+
|
|
471
|
+
/* Row drag (since 1.1.95): handle ≥ 3 : 1 against white (WCAG 1.4.11), marker, ghost */
|
|
472
|
+
--ge-table-row-drag-handle-color: #6b7280;
|
|
473
|
+
--ge-table-row-drop-indicator-color: #1a73e8;
|
|
474
|
+
--ge-table-row-drop-inside-bg: rgba(26, 115, 232, 0.12);
|
|
475
|
+
--ge-table-row-drag-ghost-bg: #fff;
|
|
476
|
+
--ge-table-row-drag-ghost-text: #1f2937;
|
|
477
|
+
--ge-table-row-drag-ghost-border: #1a73e8;
|
|
478
|
+
--ge-table-row-dragging-opacity: 0.4;
|
|
479
|
+
|
|
480
|
+
/* Fill handle and batch edit (since 1.1.96): handle and preview like the selection, pending = yellow, invalid = red */
|
|
481
|
+
--ge-table-fill-handle-color: #0a6ebd;
|
|
482
|
+
--ge-table-fill-handle-border: #fff;
|
|
483
|
+
--ge-table-fill-preview-border: #0a6ebd;
|
|
484
|
+
--ge-table-cell-pending-bg: #fff3c4;
|
|
485
|
+
--ge-table-cell-pending-text: #3d2e00;
|
|
486
|
+
--ge-table-cell-pending-marker: #c27c00;
|
|
487
|
+
--ge-table-cell-invalid-bg: #fde2e1;
|
|
488
|
+
--ge-table-cell-invalid-text: #8a1c14;
|
|
489
|
+
--ge-table-cell-invalid-border: #d93025;
|
|
460
490
|
}
|
|
461
491
|
|
|
462
492
|
|
|
@@ -544,6 +574,9 @@ html[data-theme="dark"] {
|
|
|
544
574
|
--ge-table-pivot-total-font-weight: 600;
|
|
545
575
|
--ge-table-pivot-empty-text: #9ca3af;
|
|
546
576
|
|
|
577
|
+
/* Formulas: error values #DIV/0!, #NAME? … (since 1.1.95) */
|
|
578
|
+
--ge-table-cell-error-color: #f87171;
|
|
579
|
+
|
|
547
580
|
/* Overlays "Loading…" / "No rows" (since 1.1.92) */
|
|
548
581
|
--ge-table-overlay-bg: rgba(17, 24, 39, 0.7); /* --ge-table-bg of the dark theme */
|
|
549
582
|
--ge-table-overlay-content-bg: #1f2937;
|
|
@@ -555,6 +588,84 @@ html[data-theme="dark"] {
|
|
|
555
588
|
/* Row numbers (since 1.1.93) */
|
|
556
589
|
--ge-table-row-number-bg: var(--ge-table-header-west-bg);
|
|
557
590
|
--ge-table-row-number-color: #aaa;
|
|
591
|
+
|
|
592
|
+
/* Row drag (since 1.1.95) */
|
|
593
|
+
--ge-table-row-drag-handle-color: #9ca3af;
|
|
594
|
+
--ge-table-row-drop-indicator-color: #8ab4f8;
|
|
595
|
+
--ge-table-row-drop-inside-bg: rgba(138, 180, 248, 0.16);
|
|
596
|
+
--ge-table-row-drag-ghost-bg: #1f2937;
|
|
597
|
+
--ge-table-row-drag-ghost-text: #f3f4f6;
|
|
598
|
+
--ge-table-row-drag-ghost-border: #8ab4f8;
|
|
599
|
+
--ge-table-row-dragging-opacity: 0.4;
|
|
600
|
+
|
|
601
|
+
/* Fill handle and batch edit (since 1.1.96) */
|
|
602
|
+
--ge-table-fill-handle-color: #8ab4f8;
|
|
603
|
+
--ge-table-fill-handle-border: #1e1e1e;
|
|
604
|
+
--ge-table-fill-preview-border: #8ab4f8;
|
|
605
|
+
--ge-table-cell-pending-bg: #4a3b0b;
|
|
606
|
+
--ge-table-cell-pending-text: #fde68a;
|
|
607
|
+
--ge-table-cell-pending-marker: #f5b82e;
|
|
608
|
+
--ge-table-cell-invalid-bg: #5c1d1a;
|
|
609
|
+
--ge-table-cell-invalid-text: #fecaca;
|
|
610
|
+
--ge-table-cell-invalid-border: #f28b82;
|
|
611
|
+
}
|
|
612
|
+
/* Fill handle and batch edit (since 1.1.96) – colors in table-color-vars.css (--ge-table-fill-*, --ge-table-cell-*) */
|
|
613
|
+
|
|
614
|
+
/* the square at the bottom right corner of the selected range; its center sits on the corner */
|
|
615
|
+
.ge-table-fill-handle {
|
|
616
|
+
position: absolute;
|
|
617
|
+
z-index: 9000; /* above the cells, below the overlay (10000) */
|
|
618
|
+
width: 7px;
|
|
619
|
+
height: 7px;
|
|
620
|
+
margin: -4px 0 0 -4px;
|
|
621
|
+
box-sizing: border-box;
|
|
622
|
+
background: var(--ge-table-fill-handle-color);
|
|
623
|
+
border: 1px solid var(--ge-table-fill-handle-border);
|
|
624
|
+
cursor: crosshair;
|
|
625
|
+
touch-action: none; /* touch drags the handle instead of scrolling */
|
|
626
|
+
}
|
|
627
|
+
|
|
628
|
+
/* a bigger target for touch and pen (the visible square stays small) */
|
|
629
|
+
.ge-table-fill-handle::after {
|
|
630
|
+
content: "";
|
|
631
|
+
position: absolute;
|
|
632
|
+
inset: -8px;
|
|
633
|
+
}
|
|
634
|
+
|
|
635
|
+
/* the cells a fill will cover */
|
|
636
|
+
.ge-table-fill-preview {
|
|
637
|
+
position: absolute;
|
|
638
|
+
z-index: 8999;
|
|
639
|
+
box-sizing: border-box;
|
|
640
|
+
border: 2px dashed var(--ge-table-fill-preview-border);
|
|
641
|
+
pointer-events: none;
|
|
642
|
+
}
|
|
643
|
+
|
|
644
|
+
.ge-table-fill-active,
|
|
645
|
+
.ge-table-fill-active * {
|
|
646
|
+
cursor: crosshair !important;
|
|
647
|
+
user-select: none;
|
|
648
|
+
}
|
|
649
|
+
|
|
650
|
+
/* batch edit: a value that is not saved yet – a colored cell and a small corner mark (not color only, WCAG 1.4.1) */
|
|
651
|
+
.ge-table-col-div.ge-table-cell-pending {
|
|
652
|
+
background-image: linear-gradient(225deg, var(--ge-table-cell-pending-marker) 6px, transparent 6px);
|
|
653
|
+
}
|
|
654
|
+
|
|
655
|
+
/* the color only while the cell is not selected – a selected cell keeps the selection color (and the corner mark) */
|
|
656
|
+
.ge-table-col-div.ge-table-cell-pending:not([class*="-selected-range"]) {
|
|
657
|
+
background-color: var(--ge-table-cell-pending-bg);
|
|
658
|
+
color: var(--ge-table-cell-pending-text);
|
|
659
|
+
}
|
|
660
|
+
|
|
661
|
+
/* an invalid value (ColumnDef.validate): the message is the tooltip */
|
|
662
|
+
.ge-table-col-div.ge-table-cell-invalid:not([class*="-selected-range"]) {
|
|
663
|
+
background-color: var(--ge-table-cell-invalid-bg);
|
|
664
|
+
color: var(--ge-table-cell-invalid-text);
|
|
665
|
+
}
|
|
666
|
+
|
|
667
|
+
.ge-table-col-div.ge-table-cell-invalid {
|
|
668
|
+
box-shadow: inset 0 0 0 2px var(--ge-table-cell-invalid-border);
|
|
558
669
|
}
|
|
559
670
|
/* Pivot tables (PivotFactory / AreaModelPivot, since 1.1.94) */
|
|
560
671
|
|
|
@@ -598,6 +709,87 @@ html[data-theme="dark"] {
|
|
|
598
709
|
.ge-table-pivot-header.ge-table-pivot-header-column {
|
|
599
710
|
text-align: end;
|
|
600
711
|
}
|
|
712
|
+
/* Row drag (since 1.1.95): handle, ghost, drop marker – colors in table-color-vars.css (--ge-table-row-drag-*) */
|
|
713
|
+
|
|
714
|
+
/* the cell with the handle: room for the grip at the start (a tree cell has its indent already) */
|
|
715
|
+
.ge-table-row-drag-cell:not(.ge-table-col-tree) {
|
|
716
|
+
box-sizing: border-box;
|
|
717
|
+
padding-inline-start: 16px;
|
|
718
|
+
}
|
|
719
|
+
|
|
720
|
+
/* the grip: 2 × 3 dots, drawn with CSS (no text, no image); touch-action: none = touch drags instead of scrolling */
|
|
721
|
+
.ge-table-row-drag-handle {
|
|
722
|
+
position: absolute;
|
|
723
|
+
inset-inline-start: 2px;
|
|
724
|
+
top: 50%;
|
|
725
|
+
width: 12px;
|
|
726
|
+
height: 18px;
|
|
727
|
+
margin-top: -9px;
|
|
728
|
+
cursor: grab;
|
|
729
|
+
touch-action: none;
|
|
730
|
+
border-radius: 3px;
|
|
731
|
+
background-image: radial-gradient(circle, var(--ge-table-row-drag-handle-color) 1.5px, transparent 1.6px);
|
|
732
|
+
background-size: 6px 6px;
|
|
733
|
+
background-position: 0 0;
|
|
734
|
+
}
|
|
735
|
+
|
|
736
|
+
.ge-table-row-drag-handle:hover {
|
|
737
|
+
background-color: rgba(128, 128, 128, 0.15);
|
|
738
|
+
}
|
|
739
|
+
|
|
740
|
+
/* managed drag while the table is sorted or filtered */
|
|
741
|
+
.ge-table-row-drag-handle.ge-table-row-drag-handle-disabled {
|
|
742
|
+
cursor: not-allowed;
|
|
743
|
+
opacity: 0.35;
|
|
744
|
+
}
|
|
745
|
+
|
|
746
|
+
/* the dragged rows while the drag runs */
|
|
747
|
+
.ge-table-row-dragging {
|
|
748
|
+
opacity: var(--ge-table-row-dragging-opacity);
|
|
749
|
+
}
|
|
750
|
+
|
|
751
|
+
.ge-table-row-drag-active,
|
|
752
|
+
.ge-table-row-drag-active * {
|
|
753
|
+
cursor: grabbing !important;
|
|
754
|
+
}
|
|
755
|
+
|
|
756
|
+
.ge-table-row-drag-active.ge-table-row-drag-invalid,
|
|
757
|
+
.ge-table-row-drag-active.ge-table-row-drag-invalid * {
|
|
758
|
+
cursor: no-drop !important;
|
|
759
|
+
}
|
|
760
|
+
|
|
761
|
+
.ge-table-row-drag-ghost {
|
|
762
|
+
position: absolute;
|
|
763
|
+
z-index: 10001; /* above the overlay (10000) */
|
|
764
|
+
pointer-events: none;
|
|
765
|
+
max-width: 280px;
|
|
766
|
+
padding: 4px 10px;
|
|
767
|
+
overflow: hidden;
|
|
768
|
+
white-space: nowrap;
|
|
769
|
+
text-overflow: ellipsis;
|
|
770
|
+
font-size: 0.9em;
|
|
771
|
+
line-height: 1.5;
|
|
772
|
+
color: var(--ge-table-row-drag-ghost-text);
|
|
773
|
+
background: var(--ge-table-row-drag-ghost-bg);
|
|
774
|
+
border: 1px solid var(--ge-table-row-drag-ghost-border);
|
|
775
|
+
border-radius: 4px;
|
|
776
|
+
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
|
|
777
|
+
}
|
|
778
|
+
|
|
779
|
+
.ge-table-row-drop-indicator {
|
|
780
|
+
position: absolute;
|
|
781
|
+
display: none;
|
|
782
|
+
z-index: 10000;
|
|
783
|
+
pointer-events: none;
|
|
784
|
+
background: var(--ge-table-row-drop-indicator-color);
|
|
785
|
+
}
|
|
786
|
+
|
|
787
|
+
/* tree: drop into the row (becomes its child) */
|
|
788
|
+
.ge-table-row-drop-indicator.ge-table-row-drop-indicator-inside {
|
|
789
|
+
box-sizing: border-box;
|
|
790
|
+
background: var(--ge-table-row-drop-inside-bg);
|
|
791
|
+
border: 2px solid var(--ge-table-row-drop-indicator-color);
|
|
792
|
+
}
|
|
601
793
|
/* Row grouping (RowGroupFactory / AreaModelRowGroups, since 1.1.94) */
|
|
602
794
|
|
|
603
795
|
/* every cell of a group row */
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/* Calculated columns, „Show values as“, formulas (since 1.1.95) */
|
|
2
|
+
|
|
3
|
+
/* a cell with a formula error (#DIV/0!, #NAME? …): the message is the tooltip */
|
|
4
|
+
.ge-table-col-div.ge-table-cell-error {
|
|
5
|
+
color: var(--ge-table-cell-error-color);
|
|
6
|
+
font-variant-numeric: tabular-nums;
|
|
7
|
+
}
|
package/css/table-color-vars.css
CHANGED
|
@@ -96,6 +96,9 @@ html, html[data-theme="light"] {
|
|
|
96
96
|
--ge-table-pivot-total-font-weight: 600;
|
|
97
97
|
--ge-table-pivot-empty-text: #6b7280;
|
|
98
98
|
|
|
99
|
+
/* Formulas: error values #DIV/0!, #NAME? … (since 1.1.95) */
|
|
100
|
+
--ge-table-cell-error-color: #b91c1c;
|
|
101
|
+
|
|
99
102
|
/* Overlays "Loading…" / "No rows" (since 1.1.92) */
|
|
100
103
|
--ge-table-overlay-bg: rgba(255, 255, 255, 0.7);
|
|
101
104
|
--ge-table-overlay-content-bg: #fff;
|
|
@@ -107,6 +110,26 @@ html, html[data-theme="light"] {
|
|
|
107
110
|
/* Row numbers (since 1.1.93): like the header, muted digits (#555 on the header gray ≈ 6.9 : 1) */
|
|
108
111
|
--ge-table-row-number-bg: var(--ge-table-header-west-bg);
|
|
109
112
|
--ge-table-row-number-color: #555;
|
|
113
|
+
|
|
114
|
+
/* Row drag (since 1.1.95): handle ≥ 3 : 1 against white (WCAG 1.4.11), marker, ghost */
|
|
115
|
+
--ge-table-row-drag-handle-color: #6b7280;
|
|
116
|
+
--ge-table-row-drop-indicator-color: #1a73e8;
|
|
117
|
+
--ge-table-row-drop-inside-bg: rgba(26, 115, 232, 0.12);
|
|
118
|
+
--ge-table-row-drag-ghost-bg: #fff;
|
|
119
|
+
--ge-table-row-drag-ghost-text: #1f2937;
|
|
120
|
+
--ge-table-row-drag-ghost-border: #1a73e8;
|
|
121
|
+
--ge-table-row-dragging-opacity: 0.4;
|
|
122
|
+
|
|
123
|
+
/* Fill handle and batch edit (since 1.1.96): handle and preview like the selection, pending = yellow, invalid = red */
|
|
124
|
+
--ge-table-fill-handle-color: #0a6ebd;
|
|
125
|
+
--ge-table-fill-handle-border: #fff;
|
|
126
|
+
--ge-table-fill-preview-border: #0a6ebd;
|
|
127
|
+
--ge-table-cell-pending-bg: #fff3c4;
|
|
128
|
+
--ge-table-cell-pending-text: #3d2e00;
|
|
129
|
+
--ge-table-cell-pending-marker: #c27c00;
|
|
130
|
+
--ge-table-cell-invalid-bg: #fde2e1;
|
|
131
|
+
--ge-table-cell-invalid-text: #8a1c14;
|
|
132
|
+
--ge-table-cell-invalid-border: #d93025;
|
|
110
133
|
}
|
|
111
134
|
|
|
112
135
|
|
|
@@ -194,6 +217,9 @@ html[data-theme="dark"] {
|
|
|
194
217
|
--ge-table-pivot-total-font-weight: 600;
|
|
195
218
|
--ge-table-pivot-empty-text: #9ca3af;
|
|
196
219
|
|
|
220
|
+
/* Formulas: error values #DIV/0!, #NAME? … (since 1.1.95) */
|
|
221
|
+
--ge-table-cell-error-color: #f87171;
|
|
222
|
+
|
|
197
223
|
/* Overlays "Loading…" / "No rows" (since 1.1.92) */
|
|
198
224
|
--ge-table-overlay-bg: rgba(17, 24, 39, 0.7); /* --ge-table-bg of the dark theme */
|
|
199
225
|
--ge-table-overlay-content-bg: #1f2937;
|
|
@@ -205,4 +231,24 @@ html[data-theme="dark"] {
|
|
|
205
231
|
/* Row numbers (since 1.1.93) */
|
|
206
232
|
--ge-table-row-number-bg: var(--ge-table-header-west-bg);
|
|
207
233
|
--ge-table-row-number-color: #aaa;
|
|
234
|
+
|
|
235
|
+
/* Row drag (since 1.1.95) */
|
|
236
|
+
--ge-table-row-drag-handle-color: #9ca3af;
|
|
237
|
+
--ge-table-row-drop-indicator-color: #8ab4f8;
|
|
238
|
+
--ge-table-row-drop-inside-bg: rgba(138, 180, 248, 0.16);
|
|
239
|
+
--ge-table-row-drag-ghost-bg: #1f2937;
|
|
240
|
+
--ge-table-row-drag-ghost-text: #f3f4f6;
|
|
241
|
+
--ge-table-row-drag-ghost-border: #8ab4f8;
|
|
242
|
+
--ge-table-row-dragging-opacity: 0.4;
|
|
243
|
+
|
|
244
|
+
/* Fill handle and batch edit (since 1.1.96) */
|
|
245
|
+
--ge-table-fill-handle-color: #8ab4f8;
|
|
246
|
+
--ge-table-fill-handle-border: #1e1e1e;
|
|
247
|
+
--ge-table-fill-preview-border: #8ab4f8;
|
|
248
|
+
--ge-table-cell-pending-bg: #4a3b0b;
|
|
249
|
+
--ge-table-cell-pending-text: #fde68a;
|
|
250
|
+
--ge-table-cell-pending-marker: #f5b82e;
|
|
251
|
+
--ge-table-cell-invalid-bg: #5c1d1a;
|
|
252
|
+
--ge-table-cell-invalid-text: #fecaca;
|
|
253
|
+
--ge-table-cell-invalid-border: #f28b82;
|
|
208
254
|
}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
/* Fill handle and batch edit (since 1.1.96) – colors in table-color-vars.css (--ge-table-fill-*, --ge-table-cell-*) */
|
|
2
|
+
|
|
3
|
+
/* the square at the bottom right corner of the selected range; its center sits on the corner */
|
|
4
|
+
.ge-table-fill-handle {
|
|
5
|
+
position: absolute;
|
|
6
|
+
z-index: 9000; /* above the cells, below the overlay (10000) */
|
|
7
|
+
width: 7px;
|
|
8
|
+
height: 7px;
|
|
9
|
+
margin: -4px 0 0 -4px;
|
|
10
|
+
box-sizing: border-box;
|
|
11
|
+
background: var(--ge-table-fill-handle-color);
|
|
12
|
+
border: 1px solid var(--ge-table-fill-handle-border);
|
|
13
|
+
cursor: crosshair;
|
|
14
|
+
touch-action: none; /* touch drags the handle instead of scrolling */
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
/* a bigger target for touch and pen (the visible square stays small) */
|
|
18
|
+
.ge-table-fill-handle::after {
|
|
19
|
+
content: "";
|
|
20
|
+
position: absolute;
|
|
21
|
+
inset: -8px;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
/* the cells a fill will cover */
|
|
25
|
+
.ge-table-fill-preview {
|
|
26
|
+
position: absolute;
|
|
27
|
+
z-index: 8999;
|
|
28
|
+
box-sizing: border-box;
|
|
29
|
+
border: 2px dashed var(--ge-table-fill-preview-border);
|
|
30
|
+
pointer-events: none;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.ge-table-fill-active,
|
|
34
|
+
.ge-table-fill-active * {
|
|
35
|
+
cursor: crosshair !important;
|
|
36
|
+
user-select: none;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
/* batch edit: a value that is not saved yet – a colored cell and a small corner mark (not color only, WCAG 1.4.1) */
|
|
40
|
+
.ge-table-col-div.ge-table-cell-pending {
|
|
41
|
+
background-image: linear-gradient(225deg, var(--ge-table-cell-pending-marker) 6px, transparent 6px);
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
/* the color only while the cell is not selected – a selected cell keeps the selection color (and the corner mark) */
|
|
45
|
+
.ge-table-col-div.ge-table-cell-pending:not([class*="-selected-range"]) {
|
|
46
|
+
background-color: var(--ge-table-cell-pending-bg);
|
|
47
|
+
color: var(--ge-table-cell-pending-text);
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
/* an invalid value (ColumnDef.validate): the message is the tooltip */
|
|
51
|
+
.ge-table-col-div.ge-table-cell-invalid:not([class*="-selected-range"]) {
|
|
52
|
+
background-color: var(--ge-table-cell-invalid-bg);
|
|
53
|
+
color: var(--ge-table-cell-invalid-text);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.ge-table-col-div.ge-table-cell-invalid {
|
|
57
|
+
box-shadow: inset 0 0 0 2px var(--ge-table-cell-invalid-border);
|
|
58
|
+
}
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
/* Row drag (since 1.1.95): handle, ghost, drop marker – colors in table-color-vars.css (--ge-table-row-drag-*) */
|
|
2
|
+
|
|
3
|
+
/* the cell with the handle: room for the grip at the start (a tree cell has its indent already) */
|
|
4
|
+
.ge-table-row-drag-cell:not(.ge-table-col-tree) {
|
|
5
|
+
box-sizing: border-box;
|
|
6
|
+
padding-inline-start: 16px;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
/* the grip: 2 × 3 dots, drawn with CSS (no text, no image); touch-action: none = touch drags instead of scrolling */
|
|
10
|
+
.ge-table-row-drag-handle {
|
|
11
|
+
position: absolute;
|
|
12
|
+
inset-inline-start: 2px;
|
|
13
|
+
top: 50%;
|
|
14
|
+
width: 12px;
|
|
15
|
+
height: 18px;
|
|
16
|
+
margin-top: -9px;
|
|
17
|
+
cursor: grab;
|
|
18
|
+
touch-action: none;
|
|
19
|
+
border-radius: 3px;
|
|
20
|
+
background-image: radial-gradient(circle, var(--ge-table-row-drag-handle-color) 1.5px, transparent 1.6px);
|
|
21
|
+
background-size: 6px 6px;
|
|
22
|
+
background-position: 0 0;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
.ge-table-row-drag-handle:hover {
|
|
26
|
+
background-color: rgba(128, 128, 128, 0.15);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
/* managed drag while the table is sorted or filtered */
|
|
30
|
+
.ge-table-row-drag-handle.ge-table-row-drag-handle-disabled {
|
|
31
|
+
cursor: not-allowed;
|
|
32
|
+
opacity: 0.35;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/* the dragged rows while the drag runs */
|
|
36
|
+
.ge-table-row-dragging {
|
|
37
|
+
opacity: var(--ge-table-row-dragging-opacity);
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
.ge-table-row-drag-active,
|
|
41
|
+
.ge-table-row-drag-active * {
|
|
42
|
+
cursor: grabbing !important;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.ge-table-row-drag-active.ge-table-row-drag-invalid,
|
|
46
|
+
.ge-table-row-drag-active.ge-table-row-drag-invalid * {
|
|
47
|
+
cursor: no-drop !important;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.ge-table-row-drag-ghost {
|
|
51
|
+
position: absolute;
|
|
52
|
+
z-index: 10001; /* above the overlay (10000) */
|
|
53
|
+
pointer-events: none;
|
|
54
|
+
max-width: 280px;
|
|
55
|
+
padding: 4px 10px;
|
|
56
|
+
overflow: hidden;
|
|
57
|
+
white-space: nowrap;
|
|
58
|
+
text-overflow: ellipsis;
|
|
59
|
+
font-size: 0.9em;
|
|
60
|
+
line-height: 1.5;
|
|
61
|
+
color: var(--ge-table-row-drag-ghost-text);
|
|
62
|
+
background: var(--ge-table-row-drag-ghost-bg);
|
|
63
|
+
border: 1px solid var(--ge-table-row-drag-ghost-border);
|
|
64
|
+
border-radius: 4px;
|
|
65
|
+
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
.ge-table-row-drop-indicator {
|
|
69
|
+
position: absolute;
|
|
70
|
+
display: none;
|
|
71
|
+
z-index: 10000;
|
|
72
|
+
pointer-events: none;
|
|
73
|
+
background: var(--ge-table-row-drop-indicator-color);
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
/* tree: drop into the row (becomes its child) */
|
|
77
|
+
.ge-table-row-drop-indicator.ge-table-row-drop-indicator-inside {
|
|
78
|
+
box-sizing: border-box;
|
|
79
|
+
background: var(--ge-table-row-drop-inside-bg);
|
|
80
|
+
border: 2px solid var(--ge-table-row-drop-indicator-color);
|
|
81
|
+
}
|