Skip to content

Cells ​

Merged cells and long text that runs over empty neighbors make the table read like an Excel sheet.

Merged cells ​

The merges prop merges cells: each { from, to } rectangle becomes one cell with the content and style of its first cell. wrap from cellStyle wraps long text inside it.

Rows and columns are counted as in v-model:ranges: by the row number on the current page and the position among visible data columns.

The cursor lands on a merged cell as a whole and leaves it from its far edge. A selection extends to cover merged cells completely, while selections of whole rows and columns stay as they are. An edit changes the value of the first cell.

Paste, fill and clear leave the cells under a merged cell alone: their values are not seen. A paste counts such cells as skipped.

When your own commands takes the edits, a block arrives whole with its area. The owner of the data then decides what happens to the merges.

When a merged cell reaches into a pinned column, it is split at the edge of that column. A cell spanning several rows gets no hover or row selection highlight and no stripe color. Merging does not work with grouping, in a tree or with row details.

Program of the day

Time
Hall A
Hall B
Hall C
10:00
Opening
11:00
Forms without pain
Table workshop
Accessibility
12:00
Themes and tokens
Icons on demand
13:00
Lunch
14:00
Virtual lists
Editor
Questions and answers

Text over neighboring cells ​

With overflow in cellStyle long text continues over the following empty cells, as in spreadsheets. The text runs up to the first filled cell, a merged cell or the edge of the pinned columns. Text aligned to the end of the line runs the other way.

Centered text spreads to both sides, and wrap wraps the text inside its cell. A cell with its own slot, a tree, detail or drag grip, or an open editor keeps its text inside.

The cells under the text stay separate: a click on the text over a neighboring cell lands in that cell. Grid lines under the text are not drawn.

Plans, ₽

Plan
Per month
Per year
Start
990
9,900
Team
2,490
24,900
The 20 % discount for yearly payment ends this month
Business
4,990
49,900

Frozen rows ​

The frozenRows prop keeps the first rows in place under the header while the rest scroll under them. These are ordinary data rows: they can be selected, copied and edited.

Freezing works only with height. Groups, a tree, row details and source turn it off. Rows that are not part of the data are pinned with pinnedRows.

Your plan and the options to switch to

Plan
Cores
Memory, GB
Disk, GB
₽ per month
Your plan
2
4
60
890
Mini
1
1
20
290
Start
1
2
30
390
Blog
2
2
40
590
Site
2
4
80
790
Shop
2
8
80
1,190
Team
4
8
120
1,590
Studio
4
16
160
2,390
Agency
6
16
240
2,990
Business
8
32
320
4,790
Corporate
12
48
480
7,190
Cluster
16
64
640
9,590

Sheet from cells ​

For an Excel-like sheet pass the result of tableCells(source) to the table. The source holds the row count rows, the column count cols and the cellAt(row, col) function. That function returns the text and style of a cell.

Sheet rows get numbers, and columns get letters from A to XFD. The table asks only for visible cells and creates no objects per row or column.

Ctrl with an arrow moves to the edge of the data. When the storage knows where its empty areas are, its nextEdge function finds the edge without walking over cells. Its lastCell function names the last used cell, and Ctrl+End goes there instead of the last cell of the sheet.

When data changes outside the table, for example after formulas are recalculated, call the invalidate(ranges) method on the table ref. It redraws the rows of those ranges, or every row without an argument.

Team costs, thousand ₽

Row numbers
A
B
C
D
E
F
G
H
I
J
K
L
1
Item
Jan
Feb
Mar
Apr
May
Jun
Jul
Aug
Sep
Oct
Nov
2
Rent
100
123
146
169
192
55
78
101
124
147
170
3
Phone
137
160
183
46
69
92
115
138
161
184
47
4
Cloud
174
197
60
83
106
129
152
175
198
61
84
5
Ads
51
74
97
120
143
166
189
52
75
98
121
6
Subscriptions
88
111
134
157
180
43
66
89
112
135
158
7
Training
125
148
171
194
57
80
103
126
149
172
195
8
Travel
162
185
48
71
94
117
140
163
186
49
72
9
Hardware
199
62
85
108
131
154
177
40
63
86
109
10
Stationery
76
99
122
145
168
191
54
77
100
123
146
11
Delivery
113
136
159
182
45
68
91
114
137
160
183
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30

Layer over the cells ​

The overlay slot draws content over the cells that scrolls with them: reference highlights, images, charts. The slot receives the rectOf(range) function, which returns the position of a range, and window with the rendered rows and columns.

The slot renders in the scrolling part of the table and again in the pinned columns and the frozenRows rows, and pane names the part. The header covers the layer, and clicks pass through it to the cells. The table ref has the same rectOf and cellFromPoint(x, y), which finds the cell under a point on screen.

The layer takes row heights from rowHeight and the rowHeights model. In a table without height and with rowHeight="auto" it places marks by the measured rows, including rows that grew because of wrapped text. In a table without height the pinnedRows are measured too.

Sales by quarter, million ₽

Region
Q1
Q2
Q3
Q4
North
120
135
150
170
South
90
95
110
105
West
140
150
145
160
East
70
85
90
100
Total
420
465
495
535

Peer frames ​

NuiTablePeers draws frames in the overlay layer around the cells other people work in, with their names. Each person needs a key, a name, a colour number and a cell, and areas adds their selection. On the first row the name sits under the frame so the header does not cover it.

Keep the cell of a person by its row key and column key: the row number changes with sorting and filters. keyOf(position) on the table ref returns such a key. positionOf(key) finds the cell in the current view, or returns undefined for a row hidden by a filter.

A computed value over positionOf updates itself when the rows move.

tableRectStyle(rect) gives the position styles for your own marks in the layer.

Sprint tasks

Task
Owner
Hours
Shared work: calls, code reviews and help for the other teams
Team
10
Sign-in screen
Olga
6
Catalog search
Igor
12
Card payment
Anna
8
Monthly report
Boris
4

Edit this page

Search

Esc