@atlaskit/editor-plugin-table 5.3.5 → 5.3.7

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.
Files changed (43) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/dist/cjs/plugins/table/types.js +1 -0
  3. package/dist/cjs/plugins/table/ui/DragHandle/index.js +66 -8
  4. package/dist/cjs/plugins/table/ui/DragPreview/index.js +1 -1
  5. package/dist/cjs/plugins/table/ui/TableFloatingControls/RowControls/DragControls.js +8 -4
  6. package/dist/cjs/plugins/table/ui/TableFloatingControls/index.js +1 -1
  7. package/dist/cjs/plugins/table/ui/common-styles.js +1 -1
  8. package/dist/cjs/plugins/table/ui/icons/DragHandleIcon.js +63 -0
  9. package/dist/es2019/plugins/table/types.js +1 -0
  10. package/dist/es2019/plugins/table/ui/DragHandle/index.js +62 -9
  11. package/dist/es2019/plugins/table/ui/DragPreview/index.js +1 -1
  12. package/dist/es2019/plugins/table/ui/TableFloatingControls/RowControls/DragControls.js +8 -4
  13. package/dist/es2019/plugins/table/ui/TableFloatingControls/index.js +1 -1
  14. package/dist/es2019/plugins/table/ui/common-styles.js +9 -0
  15. package/dist/es2019/plugins/table/ui/icons/DragHandleIcon.js +54 -0
  16. package/dist/esm/plugins/table/types.js +1 -0
  17. package/dist/esm/plugins/table/ui/DragHandle/index.js +66 -9
  18. package/dist/esm/plugins/table/ui/DragPreview/index.js +1 -1
  19. package/dist/esm/plugins/table/ui/TableFloatingControls/RowControls/DragControls.js +8 -4
  20. package/dist/esm/plugins/table/ui/TableFloatingControls/index.js +1 -1
  21. package/dist/esm/plugins/table/ui/common-styles.js +1 -1
  22. package/dist/esm/plugins/table/ui/icons/DragHandleIcon.js +55 -0
  23. package/dist/types/plugins/table/types.d.ts +1 -0
  24. package/dist/types/plugins/table/ui/DragHandle/index.d.ts +5 -1
  25. package/dist/types/plugins/table/ui/icons/DragHandleIcon.d.ts +7 -0
  26. package/dist/types-ts4.5/plugins/table/types.d.ts +1 -0
  27. package/dist/types-ts4.5/plugins/table/ui/DragHandle/index.d.ts +5 -1
  28. package/dist/types-ts4.5/plugins/table/ui/icons/DragHandleIcon.d.ts +7 -0
  29. package/package.json +2 -3
  30. package/src/plugins/table/types.ts +1 -1
  31. package/src/plugins/table/ui/DragHandle/index.tsx +70 -9
  32. package/src/plugins/table/ui/DragPreview/index.tsx +1 -1
  33. package/src/plugins/table/ui/TableFloatingControls/RowControls/DragControls.tsx +9 -3
  34. package/src/plugins/table/ui/TableFloatingControls/index.tsx +1 -1
  35. package/src/plugins/table/ui/common-styles.ts +9 -0
  36. package/src/plugins/table/ui/icons/DragHandleIcon.tsx +74 -0
  37. package/tsconfig.app.json +0 -3
  38. /package/dist/cjs/plugins/table/ui/{Icons → icons}/DragInMotionIcon.js +0 -0
  39. /package/dist/es2019/plugins/table/ui/{Icons → icons}/DragInMotionIcon.js +0 -0
  40. /package/dist/esm/plugins/table/ui/{Icons → icons}/DragInMotionIcon.js +0 -0
  41. /package/dist/types/plugins/table/ui/{Icons → icons}/DragInMotionIcon.d.ts +0 -0
  42. /package/dist/types-ts4.5/plugins/table/ui/{Icons → icons}/DragInMotionIcon.d.ts +0 -0
  43. /package/src/plugins/table/ui/{Icons → icons}/DragInMotionIcon.tsx +0 -0
@@ -702,6 +702,15 @@ export const tableStyles = (
702
702
  display: grid;
703
703
  align-items: center;
704
704
  position: absolute;
705
+ left: -4px;
706
+ }
707
+
708
+ .${ClassName.DRAG_HANDLE_BUTTON_CONTAINER} {
709
+ cursor: grab;
710
+ width: max-content;
711
+ padding: 0;
712
+ border: none;
713
+ background: none;
705
714
  }
706
715
 
707
716
  ${floatingColumnControls(props)}
@@ -0,0 +1,74 @@
1
+ /* eslint-disable @atlaskit/design-system/ensure-design-token-usage */
2
+ import React from 'react';
3
+
4
+ interface DragHandleIconProps {
5
+ backgroundColor?: string;
6
+ foregroundColor?: string;
7
+ }
8
+
9
+ export const DragHandleIcon = ({
10
+ backgroundColor,
11
+ foregroundColor,
12
+ }: DragHandleIconProps) => (
13
+ <svg
14
+ width="28"
15
+ height="20"
16
+ viewBox="0 0 28 20"
17
+ fill="none"
18
+ xmlns="http://www.w3.org/2000/svg"
19
+ >
20
+ <rect
21
+ x="1"
22
+ y="1"
23
+ width="26"
24
+ height="18"
25
+ rx="5"
26
+ fill={backgroundColor || '#F1F2F4'}
27
+ />
28
+ <g clipPath="url(#clip0_125_45007)">
29
+ <path
30
+ d="M11 12C11 11.4477 10.5523 11 10 11C9.44772 11 9 11.4477 9 12C9 12.5523 9.44772 13 10 13C10.5523 13 11 12.5523 11 12Z"
31
+ fill={foregroundColor || '#626F86'}
32
+ />
33
+ <path
34
+ d="M11 8C11 7.44772 10.5523 7 10 7C9.44772 7 9 7.44772 9 8C9 8.55228 9.44772 9 10 9C10.5523 9 11 8.55228 11 8Z"
35
+ fill={foregroundColor || '#626F86'}
36
+ />
37
+ <path
38
+ d="M19 12C19 11.4477 18.5523 11 18 11C17.4477 11 17 11.4477 17 12C17 12.5523 17.4477 13 18 13C18.5523 13 19 12.5523 19 12Z"
39
+ fill={foregroundColor || '#626F86'}
40
+ />
41
+ <path
42
+ d="M19 8C19 7.44772 18.5523 7 18 7C17.4477 7 17 7.44772 17 8C17 8.55228 17.4477 9 18 9C18.5523 9 19 8.55228 19 8Z"
43
+ fill={foregroundColor || '#626F86'}
44
+ />
45
+ <path
46
+ d="M15 12C15 11.4477 14.5523 11 14 11C13.4477 11 13 11.4477 13 12C13 12.5523 13.4477 13 14 13C14.5523 13 15 12.5523 15 12Z"
47
+ fill={foregroundColor || '#626F86'}
48
+ />
49
+ <path
50
+ d="M15 8C15 7.44772 14.5523 7 14 7C13.4477 7 13 7.44772 13 8C13 8.55228 13.4477 9 14 9C14.5523 9 15 8.55228 15 8Z"
51
+ fill={foregroundColor || '#626F86'}
52
+ />
53
+ </g>
54
+ <rect
55
+ x="1"
56
+ y="1"
57
+ width="26"
58
+ height="18"
59
+ rx="5"
60
+ stroke="white"
61
+ strokeWidth="2"
62
+ />
63
+ <defs>
64
+ <clipPath id="clip0_125_45007">
65
+ <rect
66
+ width="16"
67
+ height="24"
68
+ fill="white"
69
+ transform="matrix(0 -1 1 0 2 18)"
70
+ />
71
+ </clipPath>
72
+ </defs>
73
+ </svg>
74
+ );
package/tsconfig.app.json CHANGED
@@ -75,9 +75,6 @@
75
75
  {
76
76
  "path": "../../pragmatic-drag-and-drop/hitbox/tsconfig.app.json"
77
77
  },
78
- {
79
- "path": "../../pragmatic-drag-and-drop/react-accessibility/tsconfig.app.json"
80
- },
81
78
  {
82
79
  "path": "../../design-system/primitives/tsconfig.app.json"
83
80
  },