@atlaskit/editor-plugin-table 9.4.1 → 9.5.5
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/CHANGELOG.md +53 -0
- package/dist/cjs/nodeviews/TableRow.js +86 -14
- package/dist/cjs/nodeviews/TableStickyScrollbar.js +9 -5
- package/dist/cjs/nodeviews/lazy-node-views.js +9 -4
- package/dist/cjs/pm-plugins/utils/paste.js +15 -11
- package/dist/cjs/ui/common-styles.js +9 -8
- package/dist/es2019/nodeviews/TableRow.js +78 -13
- package/dist/es2019/nodeviews/TableStickyScrollbar.js +8 -5
- package/dist/es2019/nodeviews/lazy-node-views.js +9 -4
- package/dist/es2019/pm-plugins/utils/paste.js +13 -8
- package/dist/es2019/ui/common-styles.js +55 -23
- package/dist/esm/nodeviews/TableRow.js +86 -14
- package/dist/esm/nodeviews/TableStickyScrollbar.js +9 -5
- package/dist/esm/nodeviews/lazy-node-views.js +9 -4
- package/dist/esm/pm-plugins/utils/paste.js +15 -11
- package/dist/esm/ui/common-styles.js +9 -8
- package/dist/types/nodeviews/TableRow.d.ts +1 -0
- package/dist/types-ts4.5/nodeviews/TableRow.d.ts +1 -0
- package/package.json +20 -5
- package/src/nodeviews/TableRow.ts +92 -20
- package/src/nodeviews/TableStickyScrollbar.ts +13 -5
- package/src/nodeviews/lazy-node-views.ts +21 -4
- package/src/pm-plugins/utils/paste.ts +9 -8
- package/src/ui/common-styles.ts +57 -23
package/src/ui/common-styles.ts
CHANGED
|
@@ -24,6 +24,7 @@ import {
|
|
|
24
24
|
SelectionStyle,
|
|
25
25
|
} from '@atlaskit/editor-shared-styles';
|
|
26
26
|
import { scrollbarStyles } from '@atlaskit/editor-shared-styles/scrollbar';
|
|
27
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
27
28
|
import { N0, N40A, R500 } from '@atlaskit/theme/colors';
|
|
28
29
|
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
29
30
|
import { token } from '@atlaskit/tokens';
|
|
@@ -195,34 +196,67 @@ const breakoutWidthStyling = () => {
|
|
|
195
196
|
};
|
|
196
197
|
|
|
197
198
|
const viewModeSortStyles = () => {
|
|
198
|
-
return
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
199
|
+
return fg('platform_editor_nested_tables_view_mode_sort')
|
|
200
|
+
? css`
|
|
201
|
+
// new styles
|
|
202
|
+
th {
|
|
203
|
+
.${SORTING_ICON_CLASS_NAME} {
|
|
204
|
+
+ p {
|
|
205
|
+
margin-top: 0 !important;
|
|
206
|
+
}
|
|
207
|
+
}
|
|
205
208
|
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
209
|
+
&:has(.is-active) {
|
|
210
|
+
.${SORTABLE_COLUMN_ICON_CLASSNAME} {
|
|
211
|
+
opacity: 1;
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
.${SORTABLE_COLUMN_ICON_CLASSNAME} {
|
|
216
|
+
opacity: 0;
|
|
217
|
+
&:focus {
|
|
218
|
+
opacity: 1;
|
|
219
|
+
}
|
|
220
|
+
}
|
|
211
221
|
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
222
|
+
&:hover:not(:has(.${ClassName.TABLE_CONTAINER}:hover)) {
|
|
223
|
+
> .${SORTING_ICON_CLASS_NAME} {
|
|
224
|
+
.${SORTABLE_COLUMN_ICON_CLASSNAME} {
|
|
225
|
+
opacity: 1;
|
|
226
|
+
}
|
|
227
|
+
}
|
|
228
|
+
}
|
|
216
229
|
}
|
|
217
|
-
|
|
230
|
+
`
|
|
231
|
+
: css`
|
|
232
|
+
// old styles
|
|
233
|
+
th {
|
|
234
|
+
.${SORTING_ICON_CLASS_NAME} {
|
|
235
|
+
+ p {
|
|
236
|
+
margin-top: 0 !important;
|
|
237
|
+
}
|
|
238
|
+
}
|
|
218
239
|
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
240
|
+
&:has(.is-active) {
|
|
241
|
+
.${SORTABLE_COLUMN_ICON_CLASSNAME} {
|
|
242
|
+
opacity: 1;
|
|
243
|
+
}
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
.${SORTABLE_COLUMN_ICON_CLASSNAME} {
|
|
247
|
+
opacity: 0;
|
|
248
|
+
&:focus {
|
|
249
|
+
opacity: 1;
|
|
250
|
+
}
|
|
251
|
+
}
|
|
252
|
+
|
|
253
|
+
&:hover {
|
|
254
|
+
.${SORTABLE_COLUMN_ICON_CLASSNAME} {
|
|
255
|
+
opacity: 1;
|
|
256
|
+
}
|
|
257
|
+
}
|
|
222
258
|
}
|
|
223
|
-
|
|
224
|
-
}
|
|
225
|
-
`;
|
|
259
|
+
`;
|
|
226
260
|
};
|
|
227
261
|
|
|
228
262
|
const tableBorderStyles = () => {
|