@worktile/theia 13.0.23 → 13.0.26
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/editor.module.d.ts +27 -26
- package/esm2020/editor.module.mjs +5 -4
- package/esm2020/interfaces/editor.mjs +1 -1
- package/esm2020/plugins/code/code.component.mjs +4 -4
- package/esm2020/plugins/table/components/table.component.mjs +39 -10
- package/esm2020/plugins/table/components/td/td.component.mjs +13 -9
- package/esm2020/plugins/table/components/toolbar/table-toolbar.component.mjs +6 -3
- package/esm2020/plugins/table/table.service.mjs +3 -2
- package/esm2020/plugins/table/table.store.mjs +7 -1
- package/fesm2015/worktile-theia.mjs +84 -42
- package/fesm2015/worktile-theia.mjs.map +1 -1
- package/fesm2020/worktile-theia.mjs +84 -42
- package/fesm2020/worktile-theia.mjs.map +1 -1
- package/interfaces/editor.d.ts +2 -1
- package/package.json +1 -1
- package/plugins/table/components/table.component.d.ts +5 -2
- package/plugins/table/components/table.component.scss +119 -17
- package/plugins/table/components/td/td.component.d.ts +2 -1
- package/plugins/table/components/toolbar/table-toolbar.component.d.ts +1 -0
- package/plugins/table/table.store.d.ts +1 -0
- package/styles/typo.scss +1 -1
package/interfaces/editor.d.ts
CHANGED
|
@@ -73,8 +73,9 @@ export declare enum TheMode {
|
|
|
73
73
|
default = "default",
|
|
74
74
|
print = "print"
|
|
75
75
|
}
|
|
76
|
+
export declare type TheModeType = TheMode | string;
|
|
76
77
|
export declare class TheModeConfig {
|
|
77
|
-
mode:
|
|
78
|
+
mode: TheModeType;
|
|
78
79
|
}
|
|
79
80
|
export declare const THE_MODE_TOKEN: InjectionToken<TheModeConfig>;
|
|
80
81
|
export declare const THE_MODE_PROVIDER: {
|
package/package.json
CHANGED
|
@@ -9,6 +9,7 @@ import { TheTableContextMenuService } from '../../../services/table-contextmenu.
|
|
|
9
9
|
import { TheBaseElementComponent } from '../../../interfaces/view-base';
|
|
10
10
|
import { TableCellElement, TableElement } from '../../../custom-types';
|
|
11
11
|
import { TheTableColumn } from '../table.types';
|
|
12
|
+
import { ScrollDispatcher } from '@angular/cdk/scrolling';
|
|
12
13
|
import * as i0 from "@angular/core";
|
|
13
14
|
export declare class TheTableComponent extends TheBaseElementComponent<TableElement, Editor> implements OnInit, AfterViewInit, OnDestroy {
|
|
14
15
|
eventDispatcher: TableCellEventDispatcher;
|
|
@@ -18,6 +19,7 @@ export declare class TheTableComponent extends TheBaseElementComponent<TableElem
|
|
|
18
19
|
ngZone: NgZone;
|
|
19
20
|
tableService: TableService;
|
|
20
21
|
private theTableContextMenuService;
|
|
22
|
+
private scrollDispatcher;
|
|
21
23
|
destroy$: Subject<any>;
|
|
22
24
|
rowControls: {
|
|
23
25
|
height: number;
|
|
@@ -29,15 +31,16 @@ export declare class TheTableComponent extends TheBaseElementComponent<TableElem
|
|
|
29
31
|
get nativeElement(): HTMLElement;
|
|
30
32
|
get tbodyNativeElement(): HTMLElement;
|
|
31
33
|
get isSelectedAllCell(): boolean;
|
|
32
|
-
tableWrapper: ElementRef
|
|
34
|
+
tableWrapper: ElementRef<HTMLElement>;
|
|
33
35
|
theTableElement: ElementRef;
|
|
34
36
|
tbodyElement: ElementRef;
|
|
35
37
|
handleMousedown(event: MouseEvent): void;
|
|
36
38
|
onContextChange(): void;
|
|
37
|
-
constructor(elementRef: ElementRef, eventDispatcher: TableCellEventDispatcher, resizeNotifier: ColumnResizeNotifierSource, tableStore: TableStore, cdr: ChangeDetectorRef, ngZone: NgZone, tableService: TableService, theTableContextMenuService: TheTableContextMenuService);
|
|
39
|
+
constructor(elementRef: ElementRef, eventDispatcher: TableCellEventDispatcher, resizeNotifier: ColumnResizeNotifierSource, tableStore: TableStore, cdr: ChangeDetectorRef, ngZone: NgZone, tableService: TableService, theTableContextMenuService: TheTableContextMenuService, scrollDispatcher: ScrollDispatcher);
|
|
38
40
|
ngOnInit(): void;
|
|
39
41
|
getWrapperWidth(): number;
|
|
40
42
|
ngAfterViewInit(): void;
|
|
43
|
+
bindTableScrollingShadow(): void;
|
|
41
44
|
subscribeCellPositionChange(): void;
|
|
42
45
|
subscribeCellsChange(): void;
|
|
43
46
|
useRowControls(): void;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
@use 'sass:math';
|
|
2
2
|
@use 'ngx-tethys/styles/variables.scss';
|
|
3
|
-
@use '../../../styles/variables.scss'
|
|
4
|
-
@use '../../../styles/mixins.scss'
|
|
3
|
+
@use '../../../styles/variables.scss'as theVariables;
|
|
4
|
+
@use '../../../styles/mixins.scss'as mixins;
|
|
5
5
|
|
|
6
6
|
$expand-size: 12px;
|
|
7
7
|
$controls-border: 1px solid variables.$gray-300;
|
|
@@ -16,6 +16,7 @@ $control-corner-width: 12px;
|
|
|
16
16
|
|
|
17
17
|
.slate-element-table {
|
|
18
18
|
display: block;
|
|
19
|
+
|
|
19
20
|
.the-table {
|
|
20
21
|
border-spacing: 0;
|
|
21
22
|
word-wrap: break-word;
|
|
@@ -37,6 +38,7 @@ $control-corner-width: 12px;
|
|
|
37
38
|
padding: 8px;
|
|
38
39
|
position: relative;
|
|
39
40
|
cursor: text;
|
|
41
|
+
|
|
40
42
|
&::after {
|
|
41
43
|
display: block;
|
|
42
44
|
position: absolute;
|
|
@@ -77,12 +79,16 @@ $control-corner-width: 12px;
|
|
|
77
79
|
}
|
|
78
80
|
}
|
|
79
81
|
}
|
|
80
|
-
|
|
82
|
+
|
|
83
|
+
.focused-cell,
|
|
84
|
+
.selected-cell {
|
|
81
85
|
z-index: 10;
|
|
82
86
|
}
|
|
87
|
+
|
|
83
88
|
tbody {
|
|
84
89
|
tr {
|
|
85
90
|
height: 41px;
|
|
91
|
+
|
|
86
92
|
td:first-child {
|
|
87
93
|
border-left: $controls-border;
|
|
88
94
|
}
|
|
@@ -97,11 +103,79 @@ $control-corner-width: 12px;
|
|
|
97
103
|
box-sizing: border-box;
|
|
98
104
|
margin: 0 auto 16px;
|
|
99
105
|
|
|
106
|
+
&.the-table-right-shadow::after {
|
|
107
|
+
bottom: 0;
|
|
108
|
+
right: 0;
|
|
109
|
+
top: $expand-size * 2 + 10px;
|
|
110
|
+
content: ' ';
|
|
111
|
+
position: absolute;
|
|
112
|
+
pointer-events: none;
|
|
113
|
+
width: 8px;
|
|
114
|
+
z-index: 2;
|
|
115
|
+
background: -webkit-gradient(linear, left, right, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.1));
|
|
116
|
+
background: linear-gradient(to right, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.1));
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
&.the-table-left-shadow::before {
|
|
120
|
+
bottom: 0;
|
|
121
|
+
top: $expand-size * 2 + 10px;
|
|
122
|
+
left: 0;
|
|
123
|
+
content: ' ';
|
|
124
|
+
position: absolute;
|
|
125
|
+
pointer-events: none;
|
|
126
|
+
width: 8px;
|
|
127
|
+
z-index: 2;
|
|
128
|
+
background: -webkit-gradient(linear, right, left, from(rgba(0, 0, 0, 0)), to(rgba(0, 0, 0, 0.1)));
|
|
129
|
+
background: linear-gradient(to left, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.1));
|
|
130
|
+
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
&.the-table-with-controls {
|
|
134
|
+
&.the-table-right-shadow::after {
|
|
135
|
+
top: $expand-size + 10px + 1;
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
&.the-table-left-shadow::before {
|
|
139
|
+
top: $expand-size + 10px + 1;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
&.the-table-left-shadow {
|
|
143
|
+
.the-table-row-controls-wrapper {
|
|
144
|
+
&::after {
|
|
145
|
+
top: 0;
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
.the-table-wrapper {
|
|
151
|
+
margin-left: -11px;
|
|
152
|
+
padding-left: 11px;
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
&.the-numbered-column-container {
|
|
157
|
+
&.the-table-left-shadow {
|
|
158
|
+
&::before {
|
|
159
|
+
left: 44px;
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
&.the-table-with-controls {
|
|
164
|
+
.the-table-wrapper {
|
|
165
|
+
margin-left: -55px;
|
|
166
|
+
padding-left: 55px;
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
.the-table-wrapper {
|
|
171
|
+
margin-left: -44px;
|
|
172
|
+
padding-left: 44px;
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
|
|
100
176
|
.the-table-wrapper {
|
|
101
177
|
padding-top: 10px;
|
|
102
178
|
margin-top: -10px;
|
|
103
|
-
padding-bottom: 15px;
|
|
104
|
-
margin-bottom: -15px;
|
|
105
179
|
z-index: 0;
|
|
106
180
|
position: relative;
|
|
107
181
|
overflow: auto;
|
|
@@ -121,6 +195,7 @@ $control-corner-width: 12px;
|
|
|
121
195
|
}
|
|
122
196
|
|
|
123
197
|
.the-table-with-controls {
|
|
198
|
+
|
|
124
199
|
.the-table-row-controls,
|
|
125
200
|
.the-table-controls-insert-wrapper {
|
|
126
201
|
display: block;
|
|
@@ -132,27 +207,36 @@ $control-corner-width: 12px;
|
|
|
132
207
|
border-top: $controls-border;
|
|
133
208
|
background-clip: padding-box;
|
|
134
209
|
cursor: pointer;
|
|
135
|
-
|
|
210
|
+
|
|
211
|
+
&:first-child {
|
|
136
212
|
border-left: $controls-border;
|
|
137
213
|
}
|
|
214
|
+
|
|
138
215
|
&:last-child {
|
|
139
216
|
.the-table-controls-insert-wrapper {
|
|
140
217
|
right: 0;
|
|
218
|
+
|
|
141
219
|
&:after {
|
|
142
220
|
left: 9px;
|
|
143
221
|
}
|
|
144
222
|
}
|
|
223
|
+
|
|
145
224
|
.the-table-controls-insert-wrapper:hover {
|
|
146
225
|
&:after {
|
|
147
226
|
left: 0;
|
|
148
227
|
}
|
|
228
|
+
|
|
149
229
|
.the-table-controls-insert-line[data-dot-type='column'] {
|
|
150
230
|
left: $dot-size;
|
|
151
231
|
}
|
|
152
232
|
}
|
|
153
233
|
}
|
|
154
|
-
|
|
155
|
-
|
|
234
|
+
|
|
235
|
+
&.active,
|
|
236
|
+
&.dangerous {
|
|
237
|
+
|
|
238
|
+
&::before,
|
|
239
|
+
&::after {
|
|
156
240
|
content: '';
|
|
157
241
|
position: absolute;
|
|
158
242
|
width: 1px;
|
|
@@ -160,13 +244,16 @@ $control-corner-width: 12px;
|
|
|
160
244
|
background: variables.$primary;
|
|
161
245
|
top: -1px;
|
|
162
246
|
}
|
|
163
|
-
|
|
247
|
+
|
|
248
|
+
&::before {
|
|
164
249
|
left: -1px;
|
|
165
250
|
}
|
|
166
|
-
|
|
251
|
+
|
|
252
|
+
&::after {
|
|
167
253
|
right: -1px;
|
|
168
254
|
}
|
|
169
255
|
}
|
|
256
|
+
|
|
170
257
|
&.active {
|
|
171
258
|
@include mixins.controlSelected;
|
|
172
259
|
z-index: 11;
|
|
@@ -175,7 +262,9 @@ $control-corner-width: 12px;
|
|
|
175
262
|
&.dangerous {
|
|
176
263
|
@include mixins.controlDangerous;
|
|
177
264
|
z-index: 11;
|
|
178
|
-
|
|
265
|
+
|
|
266
|
+
&::before,
|
|
267
|
+
&::after {
|
|
179
268
|
background: variables.$danger;
|
|
180
269
|
}
|
|
181
270
|
}
|
|
@@ -187,6 +276,7 @@ $control-corner-width: 12px;
|
|
|
187
276
|
height: $control-corner-width;
|
|
188
277
|
position: relative;
|
|
189
278
|
visibility: hidden;
|
|
279
|
+
|
|
190
280
|
.the-table-corner-button {
|
|
191
281
|
position: absolute;
|
|
192
282
|
top: 0;
|
|
@@ -214,6 +304,7 @@ $control-corner-width: 12px;
|
|
|
214
304
|
|
|
215
305
|
&.active {
|
|
216
306
|
z-index: 1;
|
|
307
|
+
|
|
217
308
|
.the-table-corner-button {
|
|
218
309
|
@include mixins.controlSelected;
|
|
219
310
|
}
|
|
@@ -221,6 +312,7 @@ $control-corner-width: 12px;
|
|
|
221
312
|
|
|
222
313
|
&.dangerous {
|
|
223
314
|
z-index: 1;
|
|
315
|
+
|
|
224
316
|
.the-table-corner-button {
|
|
225
317
|
@include mixins.controlDangerous;
|
|
226
318
|
}
|
|
@@ -264,6 +356,7 @@ $control-corner-width: 12px;
|
|
|
264
356
|
}
|
|
265
357
|
|
|
266
358
|
&:not(.disabled) {
|
|
359
|
+
|
|
267
360
|
&:hover:after,
|
|
268
361
|
&:hover:before {
|
|
269
362
|
background-color: variables.$white !important;
|
|
@@ -315,6 +408,7 @@ $control-corner-width: 12px;
|
|
|
315
408
|
.the-table-row-controls-button-wrap {
|
|
316
409
|
position: relative;
|
|
317
410
|
margin-top: -1px;
|
|
411
|
+
|
|
318
412
|
.the-table-controls-button {
|
|
319
413
|
display: block;
|
|
320
414
|
outline: none;
|
|
@@ -330,6 +424,7 @@ $control-corner-width: 12px;
|
|
|
330
424
|
|
|
331
425
|
&.active {
|
|
332
426
|
z-index: 1;
|
|
427
|
+
|
|
333
428
|
.the-table-controls-button,
|
|
334
429
|
.the-table-numbered-controls-button {
|
|
335
430
|
@include mixins.controlSelected;
|
|
@@ -386,21 +481,25 @@ $control-corner-width: 12px;
|
|
|
386
481
|
width: 45px;
|
|
387
482
|
margin-left: 10px;
|
|
388
483
|
cursor: pointer;
|
|
484
|
+
|
|
389
485
|
.the-table-numbered-controls-button {
|
|
390
486
|
background-color: variables.$gray-100;
|
|
391
487
|
border: $controls-border;
|
|
392
488
|
border-right: none;
|
|
393
489
|
}
|
|
394
490
|
}
|
|
491
|
+
|
|
395
492
|
.the-table-focus {
|
|
396
493
|
.the-table-row-controls {
|
|
397
494
|
width: 55px;
|
|
398
495
|
margin-left: 0;
|
|
399
496
|
}
|
|
497
|
+
|
|
400
498
|
.the-table-corner-controls-insert-column-marker .the-table-controls-insert-wrapper {
|
|
401
499
|
left: 46px;
|
|
402
500
|
}
|
|
403
501
|
}
|
|
502
|
+
|
|
404
503
|
.row-number {
|
|
405
504
|
float: right;
|
|
406
505
|
width: 45px;
|
|
@@ -410,19 +509,22 @@ $control-corner-width: 12px;
|
|
|
410
509
|
}
|
|
411
510
|
}
|
|
412
511
|
|
|
413
|
-
.safari{
|
|
414
|
-
.the-table-row-controls{
|
|
512
|
+
.safari {
|
|
513
|
+
.the-table-row-controls {
|
|
415
514
|
top: 1px;
|
|
416
515
|
}
|
|
417
516
|
}
|
|
418
517
|
|
|
419
518
|
|
|
420
|
-
.the-editor-readonly{
|
|
421
|
-
|
|
519
|
+
.the-editor-readonly {
|
|
520
|
+
|
|
521
|
+
.the-table-row-controls,
|
|
522
|
+
.the-table-col-controls {
|
|
422
523
|
cursor: default;
|
|
423
524
|
}
|
|
424
|
-
|
|
425
|
-
|
|
525
|
+
|
|
526
|
+
.safari {
|
|
527
|
+
.the-table-row-controls {
|
|
426
528
|
top: 0px;
|
|
427
529
|
}
|
|
428
530
|
}
|
|
@@ -38,9 +38,10 @@ export declare class TheTdComponent extends TheBaseElementComponent<TableCellEle
|
|
|
38
38
|
get resizeNotifier(): ColumnResizeNotifierSource;
|
|
39
39
|
get tableElement(): HTMLElement;
|
|
40
40
|
get scrollableElementTop(): number;
|
|
41
|
-
get scrollableElementLeft():
|
|
41
|
+
get scrollableElementLeft(): number;
|
|
42
42
|
get isXAxisHover(): boolean;
|
|
43
43
|
get rowResizeClass(): string[];
|
|
44
|
+
get tableToolbarOption(): import("../../../../interfaces").ThePluginOption<{}>;
|
|
44
45
|
dotWrapperHovered: boolean;
|
|
45
46
|
resizeRef: ResizeRef;
|
|
46
47
|
backgroundColor: string;
|
|
@@ -18,6 +18,7 @@ export declare class TheTableToolbarComponent implements OnInit, OnDestroy {
|
|
|
18
18
|
isActiveSelect: boolean;
|
|
19
19
|
tableElement: TableElement;
|
|
20
20
|
get editor(): Editor;
|
|
21
|
+
get singleSelecting(): boolean;
|
|
21
22
|
cellMenuList: MenuEntity[];
|
|
22
23
|
get isShowSplitLine(): boolean;
|
|
23
24
|
get tableOptions(): import("../../../../interfaces").ThePluginOption<{}>;
|