PluginProbe
TablePress – Tables in WordPress made easy / 3.3.1
TablePress – Tables in WordPress made easy v3.3.1
3.3.4 3.3.3 3.3.2 3.3.1 trunk 1.12 1.14 1.9.2 2.0.4 2.1.7 2.1.8 2.2 2.2.1 2.2.2 2.2.3 2.2.4 2.2.5 2.3 2.3.1 2.3.2 2.4 2.4.1 2.4.2 2.4.3 2.4.4 All 44 releases
tablepress / admin / css / edit.scss

edit.scss in TablePress – Tables in WordPress made easy 3.3.1, at admin/css/edit.scss

298 lines 7.5 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 /**
2 * CSS code for the "Edit" screen
3 *
4 * @package TablePress
5 * @subpackage Views CSS
6 * @author Tobias Bäthge
7 * @since 1.0.0
8 */
9
10 /* Container for Advanced Editor and Help Box dialogs. */
11 .hidden-container {
12 display: none;
13 }
14
15 .postbox {
16 scroll-margin-top: 72px;
17 }
18
19 /* Positioning of the "Help" button in the header section of a postbox. */
20 .postbox .postbox-header .hndle {
21 &:has(> .help-container) {
22 justify-content: flex-start;
23 gap: 12px;
24 }
25
26 > .help-container {
27 height: 24px;
28 }
29 }
30
31 /* Allow wide postboxes to scroll sideways. */
32 body,
33 div#post-body.metabox-holder.columns-1 {
34 overflow: visible !important;
35 }
36
37 /* Add space between the screen options fieldsets. */
38 #tablepress-screen-options {
39 margin-top: 20px;
40 }
41
42 /* Move backdrop of the wpLink dialog above the "Advanced Editor" dialog. */
43 body #wp-link-backdrop {
44 z-index: 100103;
45 }
46
47 /* Fix height of the wpLink dialog, to prevent vertical scrolling in WP 7.0+. */
48 body[class*="branch-7-"]*="branch-7-""] #wp-link-wrap {
49 height: 642px;
50 margin-top: -321px;
51 }
52
53 /* Header Bar. */
54 #tablepress-header-bar-section {
55 margin-bottom: 20px;
56 padding: 8px 12px;
57 border: 1px solid #c3c4c7;
58 background: #ffffff;
59
60 /* Sticky at top of page. */
61 @media screen and (min-width: 601px) {
62 position: sticky;
63 top: calc(var(--wp-admin--admin-bar--height, 32px) - 1px); /* 1px offset to remove top border. */
64 z-index: 9989; /* Above the table editor, but below the admin menu and WP Pointers. */
65 }
66 /* Full width on smaller screens, to prevent the table editor from being visible near the right edge when scrolling. */
67 @media screen and (min-width: 601px) and (max-width: 782px) {
68 margin-left: -11px;
69 margin-right: -21px;
70 }
71 }
72
73 /* Table name and ID display in header. */
74 .tablepress-header-table-name,
75 .tablepress-header-table-id {
76 white-space: nowrap;
77 overflow: hidden;
78 text-overflow: ellipsis;
79 }
80
81 /* Background color for the readonly Shortcode text field. */
82 #table-information-shortcode {
83 &,
84 + .components-input-control__suffix {
85 background-color: #f0f0f1;
86 }
87 }
88
89 /* Styling and positioning of buttons in wpdialogs. */
90 .ui-dialog {
91 .button {
92 box-shadow: none;
93 }
94 .ui-dialog-buttonset {
95 width: 100%;
96 }
97 .button-cancel,
98 .button-cancel:hover {
99 color: #b32d2e;
100 border-color: transparent;
101 background-color: transparent;
102 text-decoration: underline;
103 }
104 .button-ok {
105 float: right;
106 }
107 }
108
109 /* Content of the Advanced Editor wpdialog. */
110 #advanced-editor {
111 padding: 5px;
112
113 .wp-editor-container {
114 border: none;
115 }
116 }
117
118 #tablepress-page #tablepress_edit-table-data {
119 display: inline-block; /* Stretch to the width of the table... */
120 min-width: calc(100% - 2px); /* but use the full width, minus 2px to account for the borders. */
121 }
122
123 #tablepress_edit-table-manipulation .column-1,
124 #tablepress_edit-table-manipulation .column-2 {
125 width: 50%;
126 }
127
128 /* Jspreadsheet CSS. */
129
130 #table-editor {
131 font-size: 14px;
132 }
133
134 /* Minimum row height, using :after to keep resize animation. */
135 .jexcel > tbody > tr:after {
136 content: "";
137 display: inline-block;
138 min-height: 22px;
139 }
140
141 .jexcel > thead > tr > td {
142 text-align: center !important;
143 z-index: 22; /* Prevent drag corner from floating above fixed header. */
144
145 /* Use custom sorting arrow icons. */
146 &:not(:first-child,.dragging,.dragging-left,.dragging-right) {
147 /* stylelint-disable-next-line function-url-quotes */
148 background-image: url("data:image/svg+xml,%3Csvg width='14' height='14' viewBox='0 0 1792 1792' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill='%23999' d='M1408 1088q0 26-19 45l-448 448q-19 19-45 19t-45-19l-448-448q-19-19-19-45t19-45 45-19h896q26 0 45 19t19 45zm0-384q0 26-19 45t-45 19h-896q-26 0-45-19t-19-45 19-45l448-448q19-19 45-19t45 19l448 448q19 19 19 45z'/%3E%3C/svg%3E");
149 background-position: center right 10px;
150 background-repeat: no-repeat;
151 }
152 &.arrow-up:not(.dragging,.dragging-left,.dragging-right) {
153 /* stylelint-disable-next-line function-url-quotes */
154 background-image: url("data:image/svg+xml,%3Csvg width='14' height='14' viewBox='0 0 1792 1792' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1408 1088q0 26-19 45l-448 448q-19 19-45 19t-45-19l-448-448q-19-19-19-45t19-45 45-19h896q26 0 45 19t19 45z'/%3E%3C/svg%3E");
155 }
156 &.arrow-down:not(.dragging,.dragging-left,.dragging-right) {
157 /* stylelint-disable-next-line function-url-quotes */
158 background-image: url("data:image/svg+xml,%3Csvg width='14' height='14' viewBox='0 0 1792 1792' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1408 704q0 26-19 45t-45 19h-896q-26 0-45-19t-19-45 19-45l448-448q19-19 45-19t45 19l448 448q19 19 19 45z'/%3E%3C/svg%3E");
159 }
160 }
161
162 /* Override default opacity, to not have text shine through when the header row/column is fixed to the top/left of the screen. */
163 .jexcel > thead > tr > td.dragging,
164 .jexcel > tbody > tr.dragging > td {
165 background-color: #ffffff;
166 opacity: 1;
167 }
168
169 .jexcel > tbody > tr > td {
170 vertical-align: top;
171 word-break: break-word;
172 padding: 0;
173
174 &:first-child {
175 padding: 4px;
176 }
177
178 /* Show all lines of text in an edited cell. */
179 &.editing {
180 --table-editor-line-clamp-editing: 0;
181 }
182
183 > div {
184 display: -webkit-box;
185 -webkit-line-clamp: var(--table-editor-line-clamp-editing, var(--table-editor-line-clamp));
186 -webkit-box-orient: vertical;
187 overflow: hidden;
188 padding: 4px;
189 }
190 }
191
192 /* Fixed header. */
193 .admin-bar .jexcel > thead > tr > td {
194 @media screen and (min-width: 601px) {
195 top: calc(var(--wp-admin--admin-bar--height) + 59px); /* Offset of 61px for the Header Bar and 2px to remove top and bottom border. */
196 }
197 @media screen and (min-width: 783px) {
198 top: calc(var(--wp-admin--admin-bar--height) + 52px); /* Offset of 54px for the Header Bar and 2px to remove top and bottom border. */
199 }
200 }
201
202 /* Fixed left column, taking into account the width of the admin bar. */
203 .jexcel > tbody > tr > .jexcel_row {
204 body & {
205 position: sticky;
206 z-index: 21; /* Prevent drag corner from floating above fixed left column. */
207 left: 160px;
208 }
209 body.folded & {
210 left: 36px;
211 }
212 body.auto-fold & {
213 @media only screen and (max-width: 960px) {
214 left: 36px;
215 }
216 @media screen and (max-width: 782px) {
217 left: 0;
218 }
219 }
220 }
221
222 .jexcel tbody tr:nth-child(even) td:not(.jexcel_row) {
223 background-color: #f9f9f9;
224 }
225
226 .jexcel_container .jexcel tbody tr td.highlight {
227 background-color: rgba(0, 94, 255, 0.05);
228 }
229
230 .jexcel_container .jexcel tbody tr.head-row td:not(.jexcel_row):not(.column-hidden),
231 .jexcel_container .jexcel tbody tr.foot-row td:not(.jexcel_row):not(.column-hidden) {
232 background-color: #d9edf7;
233 }
234
235 .jexcel_container .jexcel tbody tr.row-hidden td:not(.jexcel_row),
236 .jexcel_container .jexcel tbody tr td.column-hidden {
237 background-color: rgba(255, 224, 224, 0.7);
238 }
239
240 .jexcel > tbody > tr > .highlight {
241 &-top {
242 border-top: 1px solid rgb(82, 146, 247);
243 }
244 &-left {
245 border-left: 1px solid rgb(82, 146, 247);
246 }
247 &-right {
248 border-right: 1px solid rgb(82, 146, 247);
249 }
250 &-bottom {
251 border-bottom: 1px solid rgb(82, 146, 247);
252 }
253 }
254
255 .jexcel_corner {
256 background-color: rgb(82, 146, 247);
257 }
258
259 .jexcel > tbody > tr > td > textarea {
260 font-size: inherit;
261 box-shadow: none;
262 padding: 3px !important;
263 line-height: 1 !important;
264 }
265
266 /* Fullscreen mode. */
267 .admin-bar .jexcel_container.fullscreen .jexcel > thead > tr > td {
268 top: 0;
269 }
270 .jexcel_container.fullscreen {
271 z-index: 99999;
272 }
273
274 /* Context menu. */
275 .jcontextmenu {
276 margin: 1px; /* Don't trigger actions by accident */
277 z-index: 99999; /* Hover above WP Admin bar */
278
279 > div.header {
280 display: none !important;
281 }
282 > div a {
283 color: #111111;
284 font-size: 14px;
285 }
286 > div {
287 padding: 4px 4px 4px 16px;
288 }
289 > .jcontextmenu-disabled,
290 > .jcontextmenu-disabled a {
291 color: #999999;
292 cursor: default;
293 }
294 > div.jcontextmenu-disabled:hover {
295 background: transparent;
296 }
297 }
298