@titaui/pc 1.6.14 → 1.6.15

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 (116) hide show
  1. package/lib/components/button/icon-btn/index.css +2 -0
  2. package/lib/components/button/rect-btn/index.css +21 -0
  3. package/lib/components/button/rect-btn/index.js +8 -8
  4. package/lib/components/button/text-btn/index.css +33 -0
  5. package/lib/components/button/text-btn/index.js +52 -2
  6. package/lib/components/dynamic/components/title/index.css +2 -2
  7. package/lib/components/dynamic/constant.js +2 -1
  8. package/lib/components/dynamic/dynamic-item/dynamic-milestone/img/dynamic-milestone.png +0 -0
  9. package/lib/components/dynamic/dynamic-item/dynamic-milestone/index.css +7 -1
  10. package/lib/components/dynamic/dynamic-item/dynamic-milestone/index.js +4 -21
  11. package/lib/components/dynamic/dynamic-item/dynamic-progress/index.css +4 -0
  12. package/lib/components/dynamic/dynamic-item/dynamic-progress/index.js +4 -2
  13. package/lib/components/dynamic/dynamic-item/dynamic-project/img/dynamic-project.png +0 -0
  14. package/lib/components/dynamic/dynamic-item/dynamic-project/index.css +7 -1
  15. package/lib/components/dynamic/dynamic-item/dynamic-project/index.js +4 -7
  16. package/lib/components/dynamic/dynamic-item/dynamic-task/constant.js +1 -35
  17. package/lib/components/dynamic/dynamic-item/dynamic-task/img/dynamic-task.png +0 -0
  18. package/lib/components/dynamic/dynamic-item/dynamic-task/index.css +7 -1
  19. package/lib/components/dynamic/dynamic-item/dynamic-task/index.js +17 -7
  20. package/lib/components/dynamic/dynamic-like-ranking/index.css +1 -2
  21. package/lib/components/dynamic/dynamic-like-ranking/index.js +11 -6
  22. package/lib/components/dynamic/dynamic-liking/index.css +0 -1
  23. package/lib/components/dynamic/dynamic-liking/item.js +2 -20
  24. package/lib/components/dynamic/dynamic.js +4 -1
  25. package/lib/components/dynamic/new-ui.css +206 -0
  26. package/lib/components/dynamic/quick-operation/components/create-announcement/index.js +2 -2
  27. package/lib/components/dynamic/quick-operation/components/create-okr/index.js +2 -2
  28. package/lib/components/dynamic/quick-operation/components/create-share/index.js +2 -2
  29. package/lib/components/dynamic/quick-operation/components/create-task/index.js +2 -2
  30. package/lib/components/dynamic/quick-operation/img/okr.png +0 -0
  31. package/lib/components/dynamic/quick-operation/img/send-announcement.png +0 -0
  32. package/lib/components/dynamic/quick-operation/img/send-share.png +0 -0
  33. package/lib/components/dynamic/quick-operation/img/task.png +0 -0
  34. package/lib/components/dynamic/util.js +1 -1
  35. package/lib/components/file-list/components/single-file/index.css +2 -2
  36. package/lib/components/file-list/components/single-file/index.js +1 -1
  37. package/lib/components/form/form-fields/radios/index.css +5 -0
  38. package/lib/components/form/form-fields/radios/index.js +34 -5
  39. package/lib/components/help-card/index.css +13 -13
  40. package/lib/components/help-card/index.js +35 -31
  41. package/lib/components/help-card/request-api.js +2 -2
  42. package/lib/components/img-viewer/index.css +4 -0
  43. package/lib/components/img-viewer/index.js +2 -1
  44. package/lib/components/menus/components/flip-menu-card/index.js +1 -1
  45. package/lib/components/menus/components/menu-tree/tree-node/depart-node/index.js +7 -3
  46. package/lib/components/menus/components/menu-tree/tree-node/follower-node/index.css +6 -2
  47. package/lib/components/menus/components/menu-tree/tree-node/follower-node/index.js +15 -2
  48. package/lib/components/menus/components/menu-tree/tree-node/index.css +1 -0
  49. package/lib/components/menus/components/menu-tree/tree-node/user-concern-node.js +7 -3
  50. package/lib/components/menus/export-modules/depart-menus/index.js +34 -7
  51. package/lib/components/menus/export-modules/okr-menus/datas.js +43 -0
  52. package/lib/components/menus/export-modules/okr-menus/index.css +0 -2
  53. package/lib/components/menus/export-modules/okr-menus/index.js +27 -3
  54. package/lib/components/menus/export-modules/subordinate-menus/index.js +3 -2
  55. package/lib/components/menus/request-apis.js +22 -5
  56. package/lib/components/nav-top/components/user-message/components/inform/index.css +20 -6
  57. package/lib/components/nav-top/components/user-message/components/inform/index.js +111 -13
  58. package/lib/components/nav-top/components/user-message/components/remind/index.css +17 -6
  59. package/lib/components/nav-top/components/user-message/components/remind/index.js +57 -11
  60. package/lib/components/nav-top/components/user-message/components/reply/index.css +19 -5
  61. package/lib/components/nav-top/components/user-message/components/reply/index.js +110 -12
  62. package/lib/components/nav-top/components/user-message/components/tab-title/index.js +4 -8
  63. package/lib/components/nav-top/components/user-message/components/todos/index.css +19 -5
  64. package/lib/components/nav-top/components/user-message/components/todos/index.js +99 -21
  65. package/lib/components/nav-top/components/user-message/constant.js +11 -1
  66. package/lib/components/nav-top/components/user-message/images/loading.gif +0 -0
  67. package/lib/components/nav-top/components/user-message/index.css +37 -0
  68. package/lib/components/nav-top/components/user-message/index.js +32 -7
  69. package/lib/components/nav-top/components/user-message/msg/index.js +14 -93
  70. package/lib/components/nav-top/components/user-message/utils.js +14 -0
  71. package/lib/components/nav-top/components/user-own-menu/index.js +3 -4
  72. package/lib/components/nav-top/components/user-own-menu/utils.js +77 -0
  73. package/lib/components/nav-top/constant.js +1 -1
  74. package/lib/components/nav-top/request.apis.js +29 -3
  75. package/lib/components/nav-top/utils.js +1 -72
  76. package/lib/components/okr-filter-drawer/filter-button.js +1 -0
  77. package/lib/components/okr-filter-drawer/filter-form.js +163 -0
  78. package/lib/components/okr-filter-drawer/index.css +45 -0
  79. package/lib/components/okr-filter-drawer/index.js +42 -0
  80. package/lib/components/pagination/index.css +6 -12
  81. package/lib/components/tree/index.js +0 -2
  82. package/lib/hooks/useLocalStorage.js +37 -0
  83. package/lib/index.js +10 -2
  84. package/lib/pages/aha2021/index.css +9 -1
  85. package/lib/pages/new-okr-list/context.js +14 -0
  86. package/lib/pages/new-okr-list/header/create-okr.js +61 -0
  87. package/lib/pages/new-okr-list/header/depart-title.js +19 -0
  88. package/lib/pages/new-okr-list/header/filter.js +58 -0
  89. package/lib/pages/new-okr-list/header/index.css +31 -0
  90. package/lib/pages/new-okr-list/header/index.js +94 -0
  91. package/lib/pages/new-okr-list/header/user-title.js +19 -0
  92. package/lib/pages/new-okr-list/index.css +10 -0
  93. package/lib/pages/new-okr-list/index.js +127 -0
  94. package/lib/pages/new-okr-list/keyword-search/index.css +71 -0
  95. package/lib/pages/new-okr-list/keyword-search/index.js +100 -0
  96. package/lib/pages/new-okr-list/list/index.css +0 -0
  97. package/lib/pages/new-okr-list/list/index.js +48 -0
  98. package/lib/pages/new-okr-list/precls.js +8 -0
  99. package/lib/pages/new-okr-list/request-api.js +57 -0
  100. package/lib/pages/new-okr-list/theme.css +3 -0
  101. package/package.json +2 -1
  102. package/lib/components/dynamic/dynamic-item/components/icon/index.css +0 -10
  103. package/lib/components/dynamic/dynamic-item/components/icon/index.js +0 -35
  104. package/lib/components/dynamic/dynamic-item/dynamic-milestone/img/milestone.png +0 -0
  105. package/lib/components/dynamic/dynamic-item/dynamic-project/img/project.png +0 -0
  106. package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-cancel.png +0 -0
  107. package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-delay.png +0 -0
  108. package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-done.png +0 -0
  109. package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-pause.png +0 -0
  110. package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-progress.png +0 -0
  111. package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-unaccept.png +0 -0
  112. package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-unstart.png +0 -0
  113. package/lib/components/dynamic/quick-operation/img/create-announcement.png +0 -0
  114. package/lib/components/dynamic/quick-operation/img/create-okr.png +0 -0
  115. package/lib/components/dynamic/quick-operation/img/create-share.png +0 -0
  116. package/lib/components/dynamic/quick-operation/img/create-task.png +0 -0
@@ -0,0 +1,206 @@
1
+ .titaui-new-ui-dynamic {
2
+ position: relative;
3
+ display: flex;
4
+ flex-direction: column;
5
+ font-family: -apple-system, Arial, Verdana, Helvetica Neue, Helvetica, sans-serif, PingFang SC, Microsoft YaHei;
6
+ min-width: 970px;
7
+ height: 100%;
8
+ }
9
+
10
+ .titaui-new-ui-dynamic__header {
11
+ position: absolute;
12
+ display: flex;
13
+ justify-content: space-between;
14
+ height: 68px;
15
+ background: #ffffff;
16
+ box-shadow: 0px 0px 24px 0px rgba(127, 145, 180, 0.2);
17
+ padding: 0 24px;
18
+ width: calc(100% - 14px);
19
+ box-sizing: border-box;
20
+ z-index: 3;
21
+ border-radius: 12px;
22
+ }
23
+
24
+ .titaui-new-ui-dynamic__header--content-scroll {
25
+ background: rgba(255, 255, 255, 0.92);
26
+ backdrop-filter: blur(4px);
27
+ }
28
+
29
+ .titaui-new-ui-dynamic__header-tab {
30
+ display: inline-flex;
31
+ align-items: center;
32
+ height: 100%;
33
+ position: relative;
34
+ font-size: 16px;
35
+ color: #141c28;
36
+ line-height: 24px;
37
+ cursor: pointer;
38
+ margin-right: 36px;
39
+ white-space: nowrap;
40
+ word-break: keep-all;
41
+ overflow: hidden;
42
+ text-overflow: ellipsis;
43
+ font-weight: 400;
44
+ }
45
+
46
+ .titaui-new-ui-dynamic__header-tab--active {
47
+ color: #2879ff;
48
+ font-weight: 600;
49
+ }
50
+
51
+ .titaui-new-ui-dynamic__header-tab--active::before {
52
+ content: "";
53
+ display: inline-block;
54
+ position: absolute;
55
+ bottom: 0;
56
+ left: 50%;
57
+ transform: translateX(-50%);
58
+ width: 24px;
59
+ height: 4px;
60
+ background: linear-gradient(90deg, #4e90ff 0%, #2879ff 100%);
61
+ border-radius: 2px;
62
+ }
63
+
64
+ .titaui-new-ui-dynamic__header-search {
65
+ display: flex;
66
+ align-items: center;
67
+ }
68
+
69
+ .titaui-new-ui-dynamic__content {
70
+ position: relative;
71
+ display: flex;
72
+ flex: 1;
73
+ overflow: auto;
74
+ overflow: overlay;
75
+ padding: 88px 0 0 0;
76
+ box-sizing: border-box;
77
+ background: #f0f4fa;
78
+ }
79
+
80
+ .titaui-new-ui-dynamic__content-left {
81
+ display: flex;
82
+ flex-direction: column;
83
+ width: calc(100% - 288px);
84
+ }
85
+
86
+ .titaui-new-ui-dynamic__content-left-tabs {
87
+ display: flex;
88
+ align-items: center;
89
+ min-height: 48px;
90
+ max-height: 48px;
91
+ background: #ffffff;
92
+ box-shadow: 0px 0px 8px 0px rgba(127, 145, 180, 0.1);
93
+ border-radius: 12px;
94
+ padding-left: 20px;
95
+ margin-bottom: 10px;
96
+ }
97
+
98
+ .titaui-new-ui-dynamic__content-left-tab {
99
+ display: inline-flex;
100
+ align-items: center;
101
+ height: 30px;
102
+ padding: 4px 12px;
103
+ background: #ffffff;
104
+ border-radius: 15px;
105
+ font-size: 14px;
106
+ color: #3f4755;
107
+ line-height: 22px;
108
+ box-sizing: border-box;
109
+ cursor: pointer;
110
+ white-space: nowrap;
111
+ word-break: keep-all;
112
+ overflow: hidden;
113
+ text-overflow: ellipsis;
114
+ }
115
+
116
+ .titaui-new-ui-dynamic__content-left-tab--active {
117
+ background: rgba(40, 121, 255, 0.1);
118
+ color: #2879ff;
119
+ }
120
+
121
+ .titaui-new-ui-dynamic__content-left-loading {
122
+ margin: 0 auto;
123
+ background-image: url("./img/dynamic-loading.gif");
124
+ background-repeat: no-repeat;
125
+ background-size: 100px 40px;
126
+ padding-bottom: 60px;
127
+ width: 100px;
128
+ }
129
+
130
+ .titaui-new-ui-dynamic__content-right {
131
+ margin-left: 10px;
132
+ background: #f0f4fa;
133
+ margin-right: 14px;
134
+ }
135
+
136
+ .titaui-new-ui-dynamic__loading {
137
+ position: absolute;
138
+ width: 100%;
139
+ height: 100%;
140
+ z-index: 4;
141
+ background: #f0f4fa;
142
+ }
143
+
144
+ .titaui-new-ui-dynamic__loading-img {
145
+ width: 100px;
146
+ position: relative;
147
+ top: 50%;
148
+ left: 50%;
149
+ transform: translate(-50%, -50%);
150
+ }
151
+
152
+ .titaui-new-ui-dynamic__empty-loading-block {
153
+ height: 160px;
154
+ }
155
+
156
+ .titaui-new-ui-dynamic__no-more-data {
157
+ display: flex;
158
+ justify-content: center;
159
+ align-items: center;
160
+ padding-bottom: 20px;
161
+ font-size: 14px;
162
+ color: #6f7886;
163
+ line-height: 22px;
164
+ }
165
+
166
+ .titaui-new-ui-dynamic__no-more-data::before {
167
+ content: "";
168
+ display: inline-block;
169
+ margin-right: 12px;
170
+ width: 192px;
171
+ height: 2px;
172
+ background: linear-gradient(90deg, #f0f4fa 0%, #b8c3d5 100%);
173
+ border-radius: 1px;
174
+ }
175
+
176
+ .titaui-new-ui-dynamic__no-more-data::after {
177
+ content: "";
178
+ display: inline-block;
179
+ margin-left: 12px;
180
+ width: 192px;
181
+ height: 2px;
182
+ background: linear-gradient(90deg, #b8c3d5 0%, #f0f4fa 100%);
183
+ border-radius: 1px;
184
+ }
185
+
186
+ .titaui-new-ui-dynamic__go-to-top {
187
+ position: fixed;
188
+ bottom: 28px;
189
+ right: 28px;
190
+ display: flex;
191
+ align-items: center;
192
+ justify-content: center;
193
+ width: 52px;
194
+ height: 52px;
195
+ background: rgba(255, 255, 255, 0.86);
196
+ box-shadow: 0px 4px 12px 0px rgba(127, 145, 180, 0.2);
197
+ border-radius: 50%;
198
+ cursor: pointer;
199
+ }
200
+
201
+ .titaui-new-ui-dynamic__go-to-top-img {
202
+ display: inline-block;
203
+ width: 24px;
204
+ height: 24px;
205
+ background: url("./img/dynamic-top.svg") no-repeat;
206
+ }
@@ -7,7 +7,7 @@ exports["default"] = void 0;
7
7
 
8
8
  var _react = _interopRequireDefault(require("react"));
9
9
 
10
- var _createAnnouncement = _interopRequireDefault(require("../../img/create-announcement.png"));
10
+ var _sendAnnouncement = _interopRequireDefault(require("../../img/send-announcement.png"));
11
11
 
12
12
  require("./index.css");
13
13
 
@@ -27,7 +27,7 @@ var CreateAnnouncement = function CreateAnnouncement(_ref) {
27
27
  onClick: handleCreateAnnouncementClick
28
28
  }, /*#__PURE__*/_react["default"].createElement("img", {
29
29
  className: "".concat(prefix, "__img animate__rubberBand"),
30
- src: _createAnnouncement["default"]
30
+ src: _sendAnnouncement["default"]
31
31
  }), /*#__PURE__*/_react["default"].createElement("span", {
32
32
  className: prefix + '__text'
33
33
  }, "\u53D1\u516C\u544A"));
@@ -7,7 +7,7 @@ exports["default"] = void 0;
7
7
 
8
8
  var _react = _interopRequireDefault(require("react"));
9
9
 
10
- var _createOkr = _interopRequireDefault(require("../../img/create-okr.png"));
10
+ var _okr = _interopRequireDefault(require("../../img/okr.png"));
11
11
 
12
12
  require("./index.css");
13
13
 
@@ -27,7 +27,7 @@ var CreateOKr = function CreateOKr(_ref) {
27
27
  onClick: handleCreateOKrClick
28
28
  }, /*#__PURE__*/_react["default"].createElement("img", {
29
29
  className: "".concat(prefix, "__img animate__rubberBand"),
30
- src: _createOkr["default"]
30
+ src: _okr["default"]
31
31
  }), /*#__PURE__*/_react["default"].createElement("span", {
32
32
  className: prefix + '__text'
33
33
  }, "\u65B0\u5EFAOKR"));
@@ -7,7 +7,7 @@ exports["default"] = void 0;
7
7
 
8
8
  var _react = _interopRequireDefault(require("react"));
9
9
 
10
- var _createShare = _interopRequireDefault(require("../../img/create-share.png"));
10
+ var _sendShare = _interopRequireDefault(require("../../img/send-share.png"));
11
11
 
12
12
  require("./index.css");
13
13
 
@@ -27,7 +27,7 @@ var CreateShare = function CreateShare(_ref) {
27
27
  onClick: handleCreateShareClick
28
28
  }, /*#__PURE__*/_react["default"].createElement("img", {
29
29
  className: "".concat(prefix, "__img animate__rubberBand"),
30
- src: _createShare["default"]
30
+ src: _sendShare["default"]
31
31
  }), /*#__PURE__*/_react["default"].createElement("span", {
32
32
  className: prefix + "__text"
33
33
  }, "\u53D1\u5206\u4EAB"));
@@ -9,7 +9,7 @@ exports["default"] = void 0;
9
9
 
10
10
  var _react = _interopRequireWildcard(require("react"));
11
11
 
12
- var _createTask = _interopRequireDefault(require("../../img/create-task.png"));
12
+ var _task = _interopRequireDefault(require("../../img/task.png"));
13
13
 
14
14
  require("./index.css");
15
15
 
@@ -33,7 +33,7 @@ var CreateTask = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
33
33
  ref: ref
34
34
  }, /*#__PURE__*/_react["default"].createElement("img", {
35
35
  className: "".concat(prefix, "__img animate__rubberBand"),
36
- src: _createTask["default"]
36
+ src: _task["default"]
37
37
  }), /*#__PURE__*/_react["default"].createElement("span", {
38
38
  className: prefix + '__text'
39
39
  }, "\u65B0\u5EFA\u4EFB\u52A1"));
@@ -74,7 +74,7 @@ var getFeedTypeAndTypeColor = function getFeedTypeAndTypeColor(feedType) {
74
74
 
75
75
  if (feedType === _constant.EFeedType.Task) {
76
76
  feedTypeText = '任务';
77
- feedTypeColor = 'linear-gradient(90deg, #BB4DFF 0%, #EAC7FF 100%)';
77
+ feedTypeColor = 'linear-gradient(90deg, #00D685 0%, #9EFFDA 100%)';
78
78
  }
79
79
 
80
80
  return {
@@ -14,8 +14,8 @@
14
14
  }
15
15
 
16
16
  .titaui-new-file-list-single-file__file-preview-img {
17
- width: 180px;
18
- height: 180px;
17
+ max-width: 180px;
18
+ max-height: 180px;
19
19
  border-radius: 8px;
20
20
  }
21
21
 
@@ -97,7 +97,7 @@ var SingleFile = function SingleFile(_ref) {
97
97
  }
98
98
  }, isImg && /*#__PURE__*/_react["default"].createElement("img", {
99
99
  className: prefix + "__file-preview-img",
100
- src: data.bigImageUrl || data.smallImageUrl
100
+ src: data.previewUrl || data.bigImageUrl
101
101
  }), !isImg && /*#__PURE__*/_react["default"].createElement("div", {
102
102
  className: prefix + "__file-preview-other"
103
103
  }, /*#__PURE__*/_react["default"].createElement("img", {
@@ -14,6 +14,11 @@
14
14
  color: red;
15
15
  }
16
16
 
17
+ .form-field-radio__radios {
18
+ display: flex;
19
+ flex-wrap: wrap;
20
+ }
21
+
17
22
  .form-field-radio__radios .tita-radio {
18
23
  margin-right: 8px;
19
24
  }
@@ -17,6 +17,18 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
17
17
 
18
18
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
19
19
 
20
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
21
+
22
+ function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
23
+
24
+ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
25
+
26
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
27
+
28
+ function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"]; if (_i == null) return; var _arr = []; var _n = true; var _d = false; var _s, _e; try { for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
29
+
30
+ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
31
+
20
32
  var prefixCls = 'form-field-radio';
21
33
 
22
34
  var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
@@ -26,7 +38,22 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
26
38
  onChange = props.onChange,
27
39
  radios = props.radios,
28
40
  require = props.require,
29
- value = props.value;
41
+ value = props.value,
42
+ radioClass = props.radioClass;
43
+
44
+ var _useState = (0, _react.useState)(value),
45
+ _useState2 = _slicedToArray(_useState, 2),
46
+ activedValue = _useState2[0],
47
+ setActivedValue = _useState2[1];
48
+
49
+ var onChangeHandler = function onChangeHandler(activedkey) {
50
+ onChange && onChange(activedkey);
51
+ setActivedValue(activedkey);
52
+ };
53
+
54
+ (0, _react.useEffect)(function () {
55
+ setActivedValue(value);
56
+ }, [value]);
30
57
  (0, _react.useImperativeHandle)(ref, function () {
31
58
  return {};
32
59
  });
@@ -41,12 +68,14 @@ var _default = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
41
68
  }, "*")), /*#__PURE__*/_react["default"].createElement("div", {
42
69
  className: "".concat(prefixCls, "__radios")
43
70
  }, radios.map(function (radio) {
44
- return /*#__PURE__*/_react["default"].createElement(_radio.Radio, {
71
+ return /*#__PURE__*/_react["default"].createElement("div", {
72
+ className: "".concat(prefixCls, "__radios-item ").concat(radioClass)
73
+ }, /*#__PURE__*/_react["default"].createElement(_radio.Radio, {
45
74
  key: radio.value,
46
75
  value: radio.value,
47
- onChange: onChange,
48
- checked: radio.value == value
49
- }, radio.label);
76
+ onChange: onChangeHandler,
77
+ checked: radio.value == activedValue
78
+ }, radio.label));
50
79
  })));
51
80
  });
52
81
 
@@ -36,7 +36,7 @@
36
36
  box-shadow: 0px 0px 16px 0px rgba(127, 145, 180, 0.1);
37
37
  }
38
38
 
39
- .help-card-header {
39
+ .help-card__header {
40
40
  width: 332px;
41
41
  height: 72px;
42
42
  background: #5C8EFF;
@@ -48,7 +48,7 @@
48
48
  color: #FFFFFF;
49
49
  }
50
50
 
51
- .help-card-header-avatar {
51
+ .help-card__header-avatar {
52
52
  width: 40px;
53
53
  height: 40px;
54
54
  background: #03C2FC;
@@ -57,13 +57,13 @@
57
57
  border-radius: 50%;
58
58
  }
59
59
 
60
- .help-card-body {
60
+ .help-card__body {
61
61
  box-sizing: border-box;
62
62
  padding: 0 20px;
63
63
  margin: 24px 0 30px;
64
64
  }
65
65
 
66
- .help-card-body-item {
66
+ .help-card__body-item {
67
67
  box-sizing: border-box;
68
68
  width: 292px;
69
69
  height: 148px;
@@ -73,13 +73,13 @@
73
73
  background: rgba(240, 244, 250, 0.6) url("./image/question.svg") 100% 100% no-repeat;
74
74
  }
75
75
 
76
- .help-card-body-item-title {
76
+ .help-card__body-item-title {
77
77
  display: flex;
78
78
  justify-content: space-between;
79
79
  align-items: center;
80
80
  }
81
81
 
82
- .help-card-body-item-title-left {
82
+ .help-card__body-item-title-left {
83
83
  width: 64px;
84
84
  height: 24px;
85
85
  font-size: 16px;
@@ -89,7 +89,7 @@
89
89
  position: relative;
90
90
  }
91
91
 
92
- .help-card-body-item-title-left::before {
92
+ .help-card__body-item-title-left::before {
93
93
  content: '';
94
94
  width: 81px;
95
95
  height: 7px;
@@ -100,7 +100,7 @@
100
100
  bottom: 0;
101
101
  }
102
102
 
103
- .help-card-body-item-title-right {
103
+ .help-card__body-item-title-right {
104
104
  cursor: pointer;
105
105
  font-size: 12px;
106
106
  font-weight: 400;
@@ -108,11 +108,11 @@
108
108
  line-height: 22px;
109
109
  }
110
110
 
111
- .help-card-body-item-title-right > .tu-icon-gengxin1 {
111
+ .help-card__body-item-title-right > .tu-icon-gengxin1 {
112
112
  margin-right: 4px;
113
113
  }
114
114
 
115
- .help-card-body-item-content-item {
115
+ .help-card__body-item-content-item {
116
116
  cursor: pointer;
117
117
  margin-top: 12px;
118
118
  font-weight: 400;
@@ -121,7 +121,7 @@
121
121
  line-height: 22px;
122
122
  }
123
123
 
124
- .help-card-footer {
124
+ .help-card__footer {
125
125
  width: 332px;
126
126
  height: 86px;
127
127
  background: #FFFFFF;
@@ -133,7 +133,7 @@
133
133
  justify-content: space-between;
134
134
  }
135
135
 
136
- .help-card-footer-item {
136
+ .help-card__footer-item {
137
137
  width: 77px;
138
138
  height: 62px;
139
139
  display: flex;
@@ -147,7 +147,7 @@
147
147
  cursor: pointer;
148
148
  }
149
149
 
150
- .help-card-footer-item > img {
150
+ .help-card__footer-item > img {
151
151
  width: 20px;
152
152
  height: 20px;
153
153
  margin-bottom: 5px;
@@ -53,20 +53,25 @@ var HelpCard = function HelpCard(_ref) {
53
53
  visible = _useState2[0],
54
54
  setVisible = _useState2[1];
55
55
 
56
- var _useState3 = (0, _react.useState)(false),
56
+ var _useState3 = (0, _react.useState)(1),
57
57
  _useState4 = _slicedToArray(_useState3, 2),
58
- pointVisible = _useState4[0],
59
- setPointVisible = _useState4[1];
58
+ pageNum = _useState4[0],
59
+ setPageNum = _useState4[1];
60
60
 
61
- var _useState5 = (0, _react.useState)([]),
61
+ var _useState5 = (0, _react.useState)(false),
62
62
  _useState6 = _slicedToArray(_useState5, 2),
63
- listType1 = _useState6[0],
64
- setListType1 = _useState6[1];
63
+ pointVisible = _useState6[0],
64
+ setPointVisible = _useState6[1];
65
65
 
66
66
  var _useState7 = (0, _react.useState)([]),
67
67
  _useState8 = _slicedToArray(_useState7, 2),
68
- listType2 = _useState8[0],
69
- setListType2 = _useState8[1];
68
+ listType1 = _useState8[0],
69
+ setListType1 = _useState8[1];
70
+
71
+ var _useState9 = (0, _react.useState)([]),
72
+ _useState10 = _slicedToArray(_useState9, 2),
73
+ listType2 = _useState10[0],
74
+ setListType2 = _useState10[1];
70
75
 
71
76
  var isTrial = (0, _bsGlobal.getVersion)() == 1;
72
77
  var userId = window.BSGlobal && window.BSGlobal.loginUserInfo.Id || 0;
@@ -105,9 +110,8 @@ var HelpCard = function HelpCard(_ref) {
105
110
  };
106
111
 
107
112
  (0, _react.useEffect)(function () {
108
- (0, _requestApi.getQuestionList)().then(function (res) {
109
- console.log(res);
110
- formatQuestionList(res.Data);
113
+ (0, _requestApi.getQuestionList)(pageNum).then(function (res) {
114
+ console.log(res); // formatQuestionList(res.Data);
111
115
  });
112
116
  }, []);
113
117
 
@@ -175,76 +179,76 @@ var HelpCard = function HelpCard(_ref) {
175
179
  return /*#__PURE__*/_react["default"].createElement("div", {
176
180
  className: preCls
177
181
  }, /*#__PURE__*/_react["default"].createElement("div", {
178
- className: "".concat(preCls, "-header")
182
+ className: "".concat(preCls, "__header")
179
183
  }, /*#__PURE__*/_react["default"].createElement("div", {
180
- className: "".concat(preCls, "-header-avatar")
184
+ className: "".concat(preCls, "__header-avatar")
181
185
  }), "Tita\u5C0F\u52A9\u624B"), /*#__PURE__*/_react["default"].createElement("div", {
182
- className: "".concat(preCls, "-body")
186
+ className: "".concat(preCls, "__body")
183
187
  }, /*#__PURE__*/_react["default"].createElement("div", {
184
- className: "".concat(preCls, "-body-item")
188
+ className: "".concat(preCls, "__body-item")
185
189
  }, /*#__PURE__*/_react["default"].createElement("div", {
186
- className: "".concat(preCls, "-body-item-title")
190
+ className: "".concat(preCls, "__body-item-title")
187
191
  }, /*#__PURE__*/_react["default"].createElement("div", {
188
- className: "".concat(preCls, "-body-item-title-left")
192
+ className: "".concat(preCls, "__body-item-title-left")
189
193
  }, "\u731C\u4F60\u60F3\u95EE"), /*#__PURE__*/_react["default"].createElement("div", {
190
- className: "".concat(preCls, "-body-item-title-right")
194
+ className: "".concat(preCls, "__body-item-title-right")
191
195
  }, /*#__PURE__*/_react["default"].createElement("span", {
192
196
  className: "tu-icon-gengxin1",
193
197
  onClick: chageBatch
194
198
  }), "\u6362\u4E00\u6279")), /*#__PURE__*/_react["default"].createElement("div", {
195
- className: "".concat(preCls, "-body-item-content")
199
+ className: "".concat(preCls, "__body-item-content")
196
200
  }, listType1.map(function (item, key) {
197
201
  return /*#__PURE__*/_react["default"].createElement("div", {
198
- className: "".concat(preCls, "-body-item-content-item"),
202
+ className: "".concat(preCls, "__body-item-content-item"),
199
203
  onClick: function onClick() {
200
204
  return handleSkip(item.questionUrl);
201
205
  },
202
206
  key: key
203
207
  }, item.questionName);
204
208
  }))), /*#__PURE__*/_react["default"].createElement("div", {
205
- className: "".concat(preCls, "-body-item")
209
+ className: "".concat(preCls, "__body-item")
206
210
  }, /*#__PURE__*/_react["default"].createElement("div", {
207
- className: "".concat(preCls, "-body-item-title")
211
+ className: "".concat(preCls, "__body-item-title")
208
212
  }, /*#__PURE__*/_react["default"].createElement("div", {
209
- className: "".concat(preCls, "-body-item-title-left")
213
+ className: "".concat(preCls, "__body-item-title-left")
210
214
  }, "\u5E38\u89C1\u95EE\u9898")), /*#__PURE__*/_react["default"].createElement("div", {
211
- className: "".concat(preCls, "-body-item-content")
215
+ className: "".concat(preCls, "__body-item-content")
212
216
  }, listType2.map(function (item, key) {
213
217
  return /*#__PURE__*/_react["default"].createElement("div", {
214
- className: "".concat(preCls, "-body-item-content-item"),
218
+ className: "".concat(preCls, "__body-item-content-item"),
215
219
  onClick: function onClick() {
216
220
  return handleSkip(item.questionUrl);
217
221
  },
218
222
  key: key
219
223
  }, item.questionName);
220
224
  })))), /*#__PURE__*/_react["default"].createElement("div", {
221
- className: "".concat(preCls, "-footer")
225
+ className: "".concat(preCls, "__footer")
222
226
  }, isTrial && /*#__PURE__*/_react["default"].createElement("div", {
223
- className: "".concat(preCls, "-footer-item"),
227
+ className: "".concat(preCls, "__footer-item"),
224
228
  onClick: handlePoint
225
229
  }, /*#__PURE__*/_react["default"].createElement("img", {
226
230
  src: require("./image/yuyueyanshi.svg"),
227
231
  alt: "\u9884\u7EA6\u6F14\u793A"
228
232
  }), "\u9884\u7EA6\u6F14\u793A"), /*#__PURE__*/_react["default"].createElement("div", {
229
- className: "".concat(preCls, "-footer-item"),
233
+ className: "".concat(preCls, "__footer-item"),
230
234
  onClick: handleHelpCenter
231
235
  }, /*#__PURE__*/_react["default"].createElement("img", {
232
236
  src: require("./image/helpzx.svg"),
233
237
  alt: "\u5E2E\u52A9\u4E2D\u5FC3"
234
238
  }), "\u5E2E\u52A9\u4E2D\u5FC3"), !isTrial && /*#__PURE__*/_react["default"].createElement("div", {
235
- className: "".concat(preCls, "-footer-item"),
239
+ className: "".concat(preCls, "__footer-item"),
236
240
  onClick: handleUpgrade
237
241
  }, /*#__PURE__*/_react["default"].createElement("img", {
238
242
  src: require("./image/yuyueyanshi.svg"),
239
243
  alt: "\u5347\u7EA7\u901A\u77E5"
240
244
  }), "\u5347\u7EA7\u901A\u77E5"), !(0, _openData.isPlatform)("feishu") && /*#__PURE__*/_react["default"].createElement("div", {
241
- className: "".concat(preCls, "-footer-item"),
245
+ className: "".concat(preCls, "__footer-item"),
242
246
  onClick: handleKnowledgeCommunity
243
247
  }, /*#__PURE__*/_react["default"].createElement("img", {
244
248
  src: require("./image/okr-shequ.svg"),
245
249
  alt: "\u77E5\u8BC6\u793E\u533A"
246
250
  }), "\u77E5\u8BC6\u793E\u533A"), !(0, _openData.isPlatform)("feishu") && !(0, _openData.isPlatform)("dd") && /*#__PURE__*/_react["default"].createElement("div", {
247
- className: "".concat(preCls, "-footer-item"),
251
+ className: "".concat(preCls, "__footer-item"),
248
252
  onClick: handleCustomerService
249
253
  }, /*#__PURE__*/_react["default"].createElement("img", {
250
254
  src: require("./image/kefu1.svg"),
@@ -19,14 +19,14 @@ var requestDomain = function requestDomain() {
19
19
  return "".concat(location.protocol, "//www.tita.gift");
20
20
  };
21
21
 
22
- var getQuestionList = function getQuestionList() {
22
+ var getQuestionList = function getQuestionList(pageNum) {
23
23
  var source = (0, _bsGlobal.getSource)();
24
24
 
25
25
  if (source !== 860 || source !== 861 || source !== 862) {
26
26
  source = 0;
27
27
  }
28
28
 
29
- return _axios["default"].get("".concat(requestDomain(), "/api/v1/").concat(tenantId, "/").concat(userId, "/const/question?source=").concat(source)).then(function (res) {
29
+ return _axios["default"].get("".concat(requestDomain(), "/api/v1/").concat(tenantId, "/").concat(userId, "/const/question?source=").concat(source, "&pageSize=", 3, "&pageNum=").concat(pageNum)).then(function (res) {
30
30
  return res.data;
31
31
  });
32
32
  };