ep_data_tables 0.0.7 → 0.0.9
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/package.json +1 -1
- package/static/css/datatables-editor.css +69 -108
- package/static/js/client_hooks.js +1096 -977
package/package.json
CHANGED
|
@@ -1,167 +1,128 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* CSS rules specifically for styling tables within the Etherpad editor iframe.
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
/* Prevent default background highlight on the TD itself if an author class is present */
|
|
6
1
|
.dataTable td[class*="author-"] {
|
|
7
|
-
|
|
8
|
-
|
|
2
|
+
background-color: transparent !important;
|
|
3
|
+
border: 1px solid transparent;
|
|
9
4
|
}
|
|
10
5
|
|
|
11
|
-
/* Ensure the author span (added by acePostWriteDomLineHTML) displays correctly */
|
|
12
6
|
.dataTable td span[data-author-span="true"] {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
/* Text color should ideally be inherited or applied dynamically if Etherpad supports it,
|
|
16
|
-
otherwise, it might need to be handled explicitly in acePostWriteDomLineHTML if this CSS isn't sufficient.
|
|
17
|
-
The aceSetAuthorStyle hook returning true aims to stop the default background color,
|
|
18
|
-
allowing text color styling (potentially handled by core etherpad based on author class) to take precedence. */
|
|
7
|
+
display: inline;
|
|
8
|
+
text-decoration: none !important;
|
|
19
9
|
}
|
|
20
10
|
|
|
21
|
-
/* NEW STYLES FOR ATTRIBUTE-BASED TABLES */
|
|
22
|
-
|
|
23
|
-
/* Applied directly to the rendered table */
|
|
24
11
|
.dataTable {
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
border-top: none; /* REMOVE top border to prevent double lines between rows */
|
|
12
|
+
width: 100%;
|
|
13
|
+
border-collapse: collapse;
|
|
14
|
+
table-layout: fixed;
|
|
15
|
+
border: 1px solid black;
|
|
16
|
+
border-top: none;
|
|
31
17
|
}
|
|
32
18
|
|
|
33
|
-
/* Restore top border ONLY for the first table row in a block */
|
|
34
19
|
.dataTable.dataTable-first-row {
|
|
35
|
-
|
|
20
|
+
border-top: 1px solid black;
|
|
36
21
|
}
|
|
37
22
|
|
|
38
|
-
|
|
23
|
+
|
|
39
24
|
.dataTable tr {
|
|
40
|
-
|
|
41
|
-
|
|
25
|
+
height: 36px;
|
|
26
|
+
min-height: 36px;
|
|
42
27
|
}
|
|
43
28
|
|
|
44
29
|
.dataTable td {
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
30
|
+
vertical-align: top;
|
|
31
|
+
white-space: normal;
|
|
32
|
+
word-break: break-word;
|
|
33
|
+
overflow-wrap: anywhere;
|
|
34
|
+
border-left: 1px solid black;
|
|
35
|
+
border-right: 1px solid black;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.dataTable td * {
|
|
39
|
+
white-space: inherit;
|
|
40
|
+
word-break: inherit;
|
|
41
|
+
overflow-wrap: inherit;
|
|
53
42
|
}
|
|
54
43
|
|
|
55
|
-
/* Remove outer border from first/last cells if table border is set */
|
|
56
44
|
.dataTable td:first-child {
|
|
57
|
-
|
|
45
|
+
border-left: none;
|
|
58
46
|
}
|
|
59
47
|
.dataTable td:last-child {
|
|
60
|
-
|
|
48
|
+
border-right: none;
|
|
61
49
|
}
|
|
62
50
|
|
|
63
|
-
/* Style the line DIV as a table row */
|
|
64
|
-
/* Commenting out previous attempt as block/inline-block above is simpler for now
|
|
65
|
-
.ep-table-row {
|
|
66
|
-
display: table-row !important;
|
|
67
|
-
width: 100%;
|
|
68
|
-
}
|
|
69
|
-
*/
|
|
70
|
-
|
|
71
|
-
/* Style the cell wrapper spans as table cells */
|
|
72
|
-
/* Commenting out previous attempt
|
|
73
|
-
.ep-table-cell {
|
|
74
|
-
display: table-cell !important;
|
|
75
|
-
padding: 2px 4px;
|
|
76
|
-
border: 1px solid #ccc;
|
|
77
|
-
vertical-align: inherit;
|
|
78
|
-
height: auto;
|
|
79
|
-
}
|
|
80
|
-
*/
|
|
81
51
|
|
|
82
|
-
/* Ensure delimiters themselves are not visible */
|
|
83
52
|
.table-cell-delimiter {
|
|
84
|
-
|
|
53
|
+
display: none !important;
|
|
85
54
|
}
|
|
86
55
|
|
|
87
56
|
.ep-table-row-line > .list-bullet,
|
|
88
57
|
.list-table-row > .list-bullet {
|
|
89
|
-
|
|
58
|
+
display: none !important;
|
|
90
59
|
}
|
|
91
60
|
|
|
92
|
-
/* Hide the injected delimiter span */
|
|
93
61
|
.ep-data_tables-delim {
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
62
|
+
font-size:0;
|
|
63
|
+
line-height:0;
|
|
64
|
+
color:transparent;
|
|
65
|
+
pointer-events:none;
|
|
66
|
+
user-select:none;
|
|
67
|
+
caret-color:transparent;
|
|
100
68
|
}
|
|
101
69
|
|
|
102
|
-
/* NEW: Column resize handle styles */
|
|
103
70
|
.ep-data_tables-resize-handle {
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
71
|
+
position: absolute;
|
|
72
|
+
top: 0;
|
|
73
|
+
right: -2px;
|
|
74
|
+
width: 4px;
|
|
75
|
+
height: 100%;
|
|
76
|
+
cursor: col-resize;
|
|
77
|
+
background: transparent;
|
|
78
|
+
z-index: 10;
|
|
79
|
+
opacity: 0;
|
|
80
|
+
transition: opacity 0.2s ease;
|
|
114
81
|
}
|
|
115
82
|
|
|
116
83
|
|
|
117
|
-
|
|
118
|
-
/* Show resize handles on hover */
|
|
119
84
|
.dataTable tr:first-child td:hover .ep-data_tables-resize-handle,
|
|
120
85
|
.dataTable tr:first-child .ep-data_tables-resize-handle:hover {
|
|
121
|
-
|
|
122
|
-
|
|
86
|
+
opacity: 0.3;
|
|
87
|
+
background: #007cff;
|
|
123
88
|
}
|
|
124
89
|
|
|
125
|
-
/* Visual feedback during resize */
|
|
126
90
|
.dataTable.ep-data_tables-resizing {
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
91
|
+
user-select: none;
|
|
92
|
+
-webkit-user-select: none;
|
|
93
|
+
-moz-user-select: none;
|
|
94
|
+
-ms-user-select: none;
|
|
95
|
+
pointer-events: none;
|
|
132
96
|
}
|
|
133
97
|
|
|
134
98
|
.dataTable.ep-data_tables-resizing td {
|
|
135
|
-
|
|
136
|
-
|
|
99
|
+
transition: none !important;
|
|
100
|
+
pointer-events: none;
|
|
137
101
|
}
|
|
138
102
|
|
|
139
103
|
.dataTable.ep-data_tables-resizing .ep-data_tables-resize-handle {
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
104
|
+
opacity: 0.7 !important;
|
|
105
|
+
background: #007cff !important;
|
|
106
|
+
pointer-events: auto;
|
|
143
107
|
}
|
|
144
108
|
|
|
145
|
-
/* Improve resize handle visibility on first row */
|
|
146
109
|
.dataTable.dataTable-first-row tr:first-child td {
|
|
147
|
-
|
|
110
|
+
position: relative;
|
|
148
111
|
}
|
|
149
112
|
|
|
150
|
-
/* Ensure resize handles don't interfere with text selection */
|
|
151
113
|
.ep-data_tables-resize-handle:hover {
|
|
152
|
-
|
|
153
|
-
|
|
114
|
+
background: #007cff !important;
|
|
115
|
+
opacity: 0.5 !important;
|
|
154
116
|
}
|
|
155
117
|
|
|
156
|
-
/* Add a visual indicator during resize */
|
|
157
118
|
.dataTable.ep-data_tables-resizing::after {
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
119
|
+
content: '';
|
|
120
|
+
position: absolute;
|
|
121
|
+
top: 0;
|
|
122
|
+
left: 0;
|
|
123
|
+
right: 0;
|
|
124
|
+
bottom: 0;
|
|
125
|
+
background: rgba(0, 124, 255, 0.05);
|
|
126
|
+
pointer-events: none;
|
|
127
|
+
z-index: 5;
|
|
167
128
|
}
|