cloud-b2b 1.0.2 → 1.0.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.
Files changed (60) hide show
  1. package/es/Area/Area.js +166 -0
  2. package/es/Area/package.json +6 -0
  3. package/es/Control/Control.js +27 -1
  4. package/es/Header/Header.js +1 -1
  5. package/es/Header/Header.less +12 -11
  6. package/es/HomeHeader/Header.less +1 -1
  7. package/es/LayoutLink/LayoutLink.js +2 -2
  8. package/es/Sidebar/Sidebar.js +2 -2
  9. package/es/Sidebar/Sidebar.less +10 -9
  10. package/es/Sidebar2/Sidebar.js +1 -1
  11. package/es/SuperForm/SuperForm.js +76 -29
  12. package/es/SuperTable/DragSortRow.js +125 -0
  13. package/es/SuperTable/DragSortRow.less +17 -0
  14. package/es/SuperTable/FilterDropDown.js +188 -0
  15. package/es/SuperTable/FilterDropDown.less +30 -0
  16. package/es/SuperTable/SuperTable.js +933 -0
  17. package/es/SuperTable/SuperTable.less +132 -0
  18. package/es/SuperTable/fixed.js +42 -0
  19. package/es/SuperTable/package.json +6 -0
  20. package/es/SuperTable2/SuperTable2.js +700 -0
  21. package/es/SuperTable2/SuperTable2.less +100 -0
  22. package/es/SuperTable2/SuperTableCell.js +215 -0
  23. package/es/SuperTable2/package.json +6 -0
  24. package/es/Title/Title.less +35 -35
  25. package/es/Title/package.json +6 -6
  26. package/es/Viewer/Viewer.js +1 -1
  27. package/es/adjust.less +89 -0
  28. package/es/index.js +4 -1
  29. package/es/style.less +20 -1
  30. package/lib/Area/Area.js +194 -0
  31. package/lib/Area/package.json +6 -0
  32. package/lib/Control/Control.js +29 -1
  33. package/lib/Header/Header.js +1 -1
  34. package/lib/Header/Header.less +12 -11
  35. package/lib/HomeHeader/Header.less +1 -1
  36. package/lib/LayoutLink/LayoutLink.js +2 -2
  37. package/lib/Sidebar/Sidebar.js +2 -2
  38. package/lib/Sidebar/Sidebar.less +10 -9
  39. package/lib/Sidebar2/Sidebar.js +1 -1
  40. package/lib/SuperForm/SuperForm.js +74 -29
  41. package/lib/SuperTable/DragSortRow.js +142 -0
  42. package/lib/SuperTable/DragSortRow.less +17 -0
  43. package/lib/SuperTable/FilterDropDown.js +205 -0
  44. package/lib/SuperTable/FilterDropDown.less +30 -0
  45. package/lib/SuperTable/SuperTable.js +937 -0
  46. package/lib/SuperTable/SuperTable.less +132 -0
  47. package/lib/SuperTable/fixed.js +55 -0
  48. package/lib/SuperTable/package.json +6 -0
  49. package/lib/SuperTable2/SuperTable2.js +725 -0
  50. package/lib/SuperTable2/SuperTable2.less +100 -0
  51. package/lib/SuperTable2/SuperTableCell.js +231 -0
  52. package/lib/SuperTable2/package.json +6 -0
  53. package/lib/Title/Title.less +35 -35
  54. package/lib/Title/package.json +6 -6
  55. package/lib/Viewer/Viewer.js +1 -1
  56. package/lib/adjust.less +89 -0
  57. package/lib/index.js +28 -1
  58. package/lib/index.less +5 -0
  59. package/lib/style.less +20 -1
  60. package/package.json +1 -1
@@ -0,0 +1,132 @@
1
+ @import '../variables.less';
2
+
3
+ .@{cloudlink-prefix}-SuperTable {
4
+ border-spacing: 0;
5
+ cursor: default;
6
+
7
+ table {
8
+ white-space: pre;
9
+
10
+ :global(.ant-checkbox-input) {
11
+ z-index: -1;
12
+ }
13
+ }
14
+
15
+ :global(.ant-table-placeholder) {
16
+ padding: 0;
17
+
18
+ > div {
19
+ margin: 0;
20
+ }
21
+ }
22
+
23
+ .select {
24
+ background-color: @primary-1;
25
+ }
26
+
27
+ .center {
28
+ text-align: center !important;
29
+ }
30
+
31
+ .left {
32
+ text-align: left !important;
33
+ }
34
+
35
+ .right {
36
+ text-align: right !important;
37
+ }
38
+
39
+ .emphasizedSelectRow{
40
+ background-color: @table-row-hover-bg;
41
+ color :#000;
42
+ font-weight: 700;
43
+ }
44
+ .emphasizedUnselectRow{
45
+ color :#000;
46
+ font-weight: 700;
47
+ }
48
+
49
+ .weakenedSelectRow{
50
+ background-color: @table-row-hover-bg;
51
+ color :#999;
52
+ }
53
+ .weakenedUnselectRow{
54
+ color :#999;
55
+ }
56
+
57
+ .warningRow{
58
+ color: red;
59
+ }
60
+
61
+ .noTransition{
62
+ tr {
63
+ transition: all 0s!important;
64
+ >td{
65
+ transition: all 0s!important;
66
+ }
67
+ }
68
+ }
69
+
70
+ .noWrap{
71
+ white-space: nowrap;
72
+ }
73
+
74
+ .totalRow {
75
+ color: #222!important;
76
+ background-color: #f0f0f0!important;
77
+ transition: all 0s!important;
78
+ td {
79
+ border-top: 1px solid #ddd!important;
80
+ background-color: #f0f0f0!important;
81
+ border-bottom: 0!important;
82
+ transition: all 0s!important;
83
+ }
84
+ }
85
+
86
+ :global(.ant-table-footer) {
87
+ padding: 0!important;
88
+ }
89
+
90
+ .footer {
91
+ vertical-align: middle;
92
+ overflow: auto;
93
+ scrollbar-width: none;
94
+ -ms-overflow-style: none;
95
+ scrollbar-color: transparent transparent;
96
+ scrollbar-track-color: transparent;
97
+ -ms-scrollbar-track-color: transparent;
98
+ .footerItem {
99
+ white-space: pre;
100
+ > span {
101
+ display: inline-block;
102
+ color: #222;
103
+ position: relative;
104
+ vertical-align: middle;
105
+ border-top: 1px solid #dedede;
106
+ display: inline-block;
107
+ box-sizing: border-box;
108
+ height: 35px;
109
+ padding: 8px 8px 7px !important;
110
+ border-right: 1px solid transparent;
111
+ }
112
+ .ghost {
113
+ opacity: 0;
114
+ filter: alpha(opacity=0);
115
+ }
116
+ .content {
117
+ position: absolute;
118
+ left: 0;
119
+ }
120
+ }
121
+ }
122
+
123
+ .footer::-webkit-scrollbar {
124
+ display: none;
125
+ width: 0!important;
126
+ height: 0!important;
127
+ opacity: 0;
128
+ filter: alpha(opacity=0);
129
+ }
130
+ }
131
+
132
+
@@ -0,0 +1,42 @@
1
+ import _indexOfInstanceProperty from "@babel/runtime-corejs3/core-js-stable/instance/index-of";
2
+
3
+ var isFirefox = function isFirefox() {
4
+ var _context;
5
+
6
+ return _indexOfInstanceProperty(_context = navigator.userAgent).call(_context, 'Firefox') > 0;
7
+ };
8
+
9
+ var getComputedStyle = function getComputedStyle(element) {
10
+ return window.getComputedStyle ? window.getComputedStyle(element, null) : element.currentStyle;
11
+ };
12
+
13
+ var fixed = function fixed(container, header, maxHeight) {
14
+ var totalFooter = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {};
15
+ container.style.overflowY = 'auto';
16
+ container.style.maxHeight = maxHeight;
17
+
18
+ if (isFirefox()) {
19
+ container.style.position = 'relative';
20
+ header.style.top = '0';
21
+ header.style.position = 'sticky';
22
+ header.style.zIndex = '1';
23
+ } else {
24
+ header.parentNode.appendChild(header);
25
+ }
26
+
27
+ var containerHeight = Number(getComputedStyle(container).height.replace('px', ''));
28
+ var translateHeight = containerHeight - 10 - container.scrollHeight;
29
+ var pageTotalElement = totalFooter.pageTotalElement,
30
+ searchTotalElement = totalFooter.searchTotalElement;
31
+ pageTotalElement && (pageTotalElement.style.transform = "translateY(".concat(translateHeight + container.scrollTop, "px)"));
32
+ searchTotalElement && (searchTotalElement.style.transform = "translateY(".concat(translateHeight + container.scrollTop, "px)"));
33
+
34
+ container.onscroll = function () {
35
+ if (container.scrollTop + containerHeight - 10 > container.scrollHeight) return;
36
+ !isFirefox() && (header.style.transform = "translateY(".concat(container.scrollTop, "px)"));
37
+ pageTotalElement && (pageTotalElement.style.transform = "translateY(".concat(translateHeight + container.scrollTop, "px)"));
38
+ searchTotalElement && (searchTotalElement.style.transform = "translateY(".concat(translateHeight + container.scrollTop, "px)"));
39
+ };
40
+ };
41
+
42
+ export default fixed;
@@ -0,0 +1,6 @@
1
+ {
2
+ "name": "SuperTable",
3
+ "version": "0.0.0",
4
+ "private": true,
5
+ "main": "./SuperTable.js"
6
+ }