component-shipinlv 1.0.36 → 1.0.50

Sign up to get free protection for your applications and to get access to all the features.
Files changed (66) hide show
  1. package/dist/UI/LayoutContent.d.ts +18 -0
  2. package/dist/UI/LayoutContent.js +73 -0
  3. package/dist/UI/LayoutContent.less +60 -0
  4. package/dist/UI/PageContentWarp.less +1 -1
  5. package/dist/UI/PageLoading.d.ts +3 -0
  6. package/dist/UI/PageLoading.js +11 -0
  7. package/dist/UI/PageLoading.less +7 -0
  8. package/dist/VideoPublish/account-manage/home.d.ts +9 -0
  9. package/dist/VideoPublish/account-manage/home.js +170 -0
  10. package/dist/VideoPublish/account-manage/home.less +58 -0
  11. package/dist/VideoPublish/account-manage/index.d.ts +3 -0
  12. package/dist/VideoPublish/account-manage/index.js +56 -0
  13. package/dist/VideoPublish/account-manage/index.less +59 -0
  14. package/dist/VideoPublish/account-manage/list.d.ts +10 -0
  15. package/dist/VideoPublish/account-manage/list.js +430 -0
  16. package/dist/VideoPublish/account-manage/list.less +162 -0
  17. package/dist/VideoPublish/account-manage/setting/index.d.ts +6 -0
  18. package/dist/VideoPublish/account-manage/setting/index.js +69 -0
  19. package/dist/VideoPublish/account-manage/setting/index.less +9 -0
  20. package/dist/VideoPublish/index.d.ts +1 -0
  21. package/dist/VideoPublish/index.js +43 -13
  22. package/dist/VideoPublish/index.less +4 -4
  23. package/dist/VideoPublish/log/index.d.ts +2 -0
  24. package/dist/VideoPublish/log/index.js +122 -0
  25. package/dist/VideoPublish/log/index.less +83 -0
  26. package/dist/VideoPublish/video-account/index.less +1 -0
  27. package/dist/VideoPublish/video-account/query.js +1 -0
  28. package/dist/component/markdown/github-markdown-light.less +1102 -0
  29. package/dist/component/markdown/index.d.ts +8 -0
  30. package/dist/component/markdown/index.js +69 -0
  31. package/dist/component/markdown/index.less +55 -0
  32. package/dist/component/video-platform/logo.d.ts +1 -0
  33. package/dist/component/video-platform/logo.js +6 -0
  34. package/dist/config/apiUrls.js +1 -1
  35. package/dist/lib/accountManageSettingConfig.d.ts +2 -0
  36. package/dist/lib/accountManageSettingConfig.js +15 -0
  37. package/dist/lib/event.d.ts +7 -0
  38. package/dist/lib/event.js +59 -0
  39. package/dist/lib/getLocalUserInfo.d.ts +2 -0
  40. package/dist/lib/getLocalUserInfo.js +19 -0
  41. package/dist/lib/math.d.ts +38 -0
  42. package/dist/lib/math.js +146 -0
  43. package/dist/lib/sleep.d.ts +2 -0
  44. package/dist/lib/sleep.js +23 -0
  45. package/dist/lib/store.d.ts +7 -0
  46. package/dist/lib/store.js +36 -0
  47. package/dist/lib/toast.d.ts +2 -0
  48. package/dist/lib/toast.js +8 -0
  49. package/dist/lib/toastError.d.ts +2 -0
  50. package/dist/lib/toastError.js +8 -0
  51. package/dist/service/api/VideoPublishController.js +1 -0
  52. package/dist/service/api/VideoPublishVideoAccountController.d.ts +13 -0
  53. package/dist/service/api/VideoPublishVideoAccountController.js +140 -0
  54. package/dist/types/PublishNpm.d.ts +36 -0
  55. package/dist/types/PublishNpm.js +0 -0
  56. package/dist/types/PublishTaskPlan.d.ts +41 -0
  57. package/dist/types/PublishTaskPlan.js +0 -0
  58. package/dist/types/User.d.ts +83 -0
  59. package/dist/types/VideoPublishLog.d.ts +32 -0
  60. package/dist/types/VideoPublishLog.js +0 -0
  61. package/dist/typings/VideoPublishAccountManageSetting.d.ts +5 -0
  62. package/dist/typings/VideoPublishAccountManageSetting.js +0 -0
  63. package/dist/typings/VideoPublishVideoAccount.d.ts +69 -0
  64. package/dist/typings/VideoPublishVideoAccount.js +0 -0
  65. package/dist/window.d.ts +9 -0
  66. package/package.json +2 -1
@@ -0,0 +1,430 @@
1
+ import _regeneratorRuntime from "@babel/runtime/helpers/esm/regeneratorRuntime";
2
+ import _asyncToGenerator from "@babel/runtime/helpers/esm/asyncToGenerator";
3
+ import _toConsumableArray from "@babel/runtime/helpers/esm/toConsumableArray";
4
+ import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
5
+ import React, { useEffect, useState, useRef } from 'react';
6
+ import { Avatar, Button, Divider, Dropdown, Empty, Input, Popconfirm, Space, Tooltip } from 'antd';
7
+ import "./list.less";
8
+ import { PlusCircleOutlined, SearchOutlined, CloseOutlined } from '@ant-design/icons';
9
+ import { useRequest } from "@umijs/hooks";
10
+ import * as VideoPublishVideoAccountController from "../../service/api/VideoPublishVideoAccountController";
11
+ import PageContentWarp from "../../UI/PageContentWarp";
12
+ // import goAuth from "../../lib/goAuth";
13
+ import getLocalUserInfo from "../../lib/getLocalUserInfo";
14
+ import event from "../../lib/event";
15
+ import VideoPlatformLogo, { VideoPlatformList } from "../../component/video-platform/logo";
16
+ import toast from "../../lib/toast";
17
+ import Notification from "../../lib/notification";
18
+ import Money from "../../UI/Money";
19
+ import AccountManageSettingConfig from "../../lib/accountManageSettingConfig";
20
+ import VideoPlatform from "../../component/video-platform/logo";
21
+ import { jsx as _jsx } from "react/jsx-runtime";
22
+ import { jsxs as _jsxs } from "react/jsx-runtime";
23
+ import { Fragment as _Fragment } from "react/jsx-runtime";
24
+ var HomePageAccountList = function HomePageAccountList(_ref) {
25
+ var apiUrl = _ref.apiUrl,
26
+ env = _ref.env,
27
+ _ref$onListData = _ref.onListData,
28
+ onListData = _ref$onListData === void 0 ? function () {} : _ref$onListData,
29
+ _ref$onCurrent = _ref.onCurrent,
30
+ onCurrent = _ref$onCurrent === void 0 ? function () {} : _ref$onCurrent;
31
+ var _useState = useState(getLocalUserInfo()),
32
+ _useState2 = _slicedToArray(_useState, 2),
33
+ userInfo = _useState2[0],
34
+ setUserInfo = _useState2[1];
35
+ var _useState3 = useState(0),
36
+ _useState4 = _slicedToArray(_useState3, 2),
37
+ currentId = _useState4[0],
38
+ setCurrentId = _useState4[1];
39
+ var _useState5 = useState(true),
40
+ _useState6 = _slicedToArray(_useState5, 2),
41
+ isOpen = _useState6[0],
42
+ setIsOpen = _useState6[1];
43
+ var _useState7 = useState([]),
44
+ _useState8 = _slicedToArray(_useState7, 2),
45
+ keywordList = _useState8[0],
46
+ setKeywordList = _useState8[1];
47
+ var _useState9 = useState(240),
48
+ _useState10 = _slicedToArray(_useState9, 2),
49
+ width = _useState10[0],
50
+ setWidth = _useState10[1];
51
+ var listDataRef = useRef([]);
52
+ var _useState11 = useState([]),
53
+ _useState12 = _slicedToArray(_useState11, 2),
54
+ platformMenuItems = _useState12[0],
55
+ setPlatformMenuItems = _useState12[1];
56
+ var _useState13 = useState(listDataRef.current),
57
+ _useState14 = _slicedToArray(_useState13, 2),
58
+ listData = _useState14[0],
59
+ setListData = _useState14[1];
60
+ var _useRequest = useRequest(function () {
61
+ return VideoPublishVideoAccountController.list({
62
+ current: 1,
63
+ pageSize: 100
64
+ }, {
65
+ env: env
66
+ });
67
+ }, {
68
+ manual: !userInfo.isLogin,
69
+ onSuccess: function onSuccess(result) {
70
+ listDataRef.current = result.list;
71
+ setListData(result.list);
72
+ onListData(result.list);
73
+ }
74
+ }),
75
+ loading = _useRequest.loading,
76
+ error = _useRequest.error,
77
+ run = _useRequest.run;
78
+ var _useRequest2 = useRequest(function (id) {
79
+ return VideoPublishVideoAccountController.del({
80
+ id: id
81
+ }, {
82
+ env: env
83
+ });
84
+ }, {
85
+ manual: true,
86
+ onSuccess: function onSuccess(result) {
87
+ var index = listDataRef.current.findIndex(function (item) {
88
+ return item.id == result.id;
89
+ });
90
+ if (index > -1) {
91
+ listDataRef.current.splice(index, 1);
92
+ }
93
+ setListData(_toConsumableArray(listDataRef.current));
94
+ onListData(_toConsumableArray(listDataRef.current));
95
+ }
96
+ }),
97
+ loadingDel = _useRequest2.loading,
98
+ runDel = _useRequest2.run;
99
+ var onCurrentId = function onCurrentId(id) {
100
+ if (id === currentId) {
101
+ setCurrentId(0);
102
+ onCurrent({
103
+ id: 0,
104
+ userId: 0,
105
+ platform: 'd',
106
+ groupId: 0,
107
+ uniqueId: 0,
108
+ accountId: '',
109
+ avatar: '',
110
+ bindPhone: '',
111
+ nickname: '',
112
+ signature: '',
113
+ isLoginValid: false,
114
+ followerCount: 0,
115
+ followingCount: 0,
116
+ favoritedCount: 0,
117
+ videoCount: 0,
118
+ created: 0,
119
+ updated: 0
120
+ });
121
+ return;
122
+ }
123
+ var index = listDataRef.current.findIndex(function (item) {
124
+ return item.id === id;
125
+ });
126
+ setCurrentId(id);
127
+ onCurrent(listDataRef.current[index]);
128
+ };
129
+ var _useRequest3 = useRequest(function (data) {
130
+ return VideoPublishVideoAccountController.create(data, {
131
+ env: env
132
+ });
133
+ }, {
134
+ manual: true,
135
+ onSuccess: function onSuccess(result) {
136
+ toast('已经添加账户');
137
+ onSearch();
138
+ }
139
+ }),
140
+ loadingCreate = _useRequest3.loading,
141
+ runCreate = _useRequest3.run;
142
+ var onSearch = function onSearch(keyword) {
143
+ var _keyword$replace;
144
+ var list = (keyword === null || keyword === void 0 || (_keyword$replace = keyword.replace(/\s+/g, '')) === null || _keyword$replace === void 0 ? void 0 : _keyword$replace.split('')) || [];
145
+ setKeywordList(list);
146
+ };
147
+ var onAdd = /*#__PURE__*/function () {
148
+ var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(platform) {
149
+ var _window$bridge;
150
+ var settingConfig, addAccountResult, postData;
151
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
152
+ while (1) switch (_context.prev = _context.next) {
153
+ case 0:
154
+ // if ( ! userInfo.isLogin ){
155
+ // const authResult = await goAuth()?.catch( err => {
156
+ //
157
+ // });
158
+ // if( ! authResult ){
159
+ // console.log('登录失败' );
160
+ // return;
161
+ // }
162
+ // }
163
+
164
+ console.log('onAdd:', platform);
165
+ toast('正在启动浏览器,请扫码登录', 12);
166
+
167
+ // const platformName = platform ; // == 'kuaishou' ? 'kwai' : '';
168
+ // const eventName = `amz-${ platform }-publish--add-account`;
169
+ // console.log('eventName:', eventName );
170
+ // window.bridge.ipcRenderer.sendMessage( eventName ); // 添加抖音账号
171
+ settingConfig = AccountManageSettingConfig();
172
+ _context.next = 5;
173
+ return (_window$bridge = window.bridge()) === null || _window$bridge === void 0 ? void 0 : _window$bridge.ipcRenderer.invoke('shipinlv-video-account-add', platform, settingConfig.isChromeOpen).catch(function (err) {
174
+ Notification.notificationError('获取账号信息错误' + ((err === null || err === void 0 ? void 0 : err.message) || JSON.stringify(err)));
175
+ });
176
+ case 5:
177
+ addAccountResult = _context.sent;
178
+ if (addAccountResult) {
179
+ _context.next = 8;
180
+ break;
181
+ }
182
+ return _context.abrupt("return");
183
+ case 8:
184
+ console.log('addAccountResult:', addAccountResult, env);
185
+ postData = {
186
+ detail: addAccountResult
187
+ };
188
+ runCreate(postData);
189
+ case 11:
190
+ case "end":
191
+ return _context.stop();
192
+ }
193
+ }, _callee);
194
+ }));
195
+ return function onAdd(_x) {
196
+ return _ref2.apply(this, arguments);
197
+ };
198
+ }();
199
+ useEffect(function () {
200
+ var platformMenuItems = [];
201
+ VideoPlatformList.forEach(function (item) {
202
+ platformMenuItems.push({
203
+ label: item.name,
204
+ key: item.platform,
205
+ disabled: item.disabled,
206
+ icon: /*#__PURE__*/_jsx(VideoPlatform, {
207
+ platform: item.platform,
208
+ showName: false
209
+ })
210
+ });
211
+ });
212
+ setPlatformMenuItems(platformMenuItems);
213
+ }, []);
214
+ var addButton = function addButton() {
215
+ return /*#__PURE__*/_jsx("div", {
216
+ className: "addButton",
217
+ children: /*#__PURE__*/_jsx(Dropdown, {
218
+ placement: "top",
219
+ menu: {
220
+ items: platformMenuItems,
221
+ onClick: function onClick(e) {
222
+ return onAdd(e.key);
223
+ }
224
+ },
225
+ children: /*#__PURE__*/_jsx(Button, {
226
+ icon: /*#__PURE__*/_jsx(PlusCircleOutlined, {}),
227
+ type: "primary",
228
+ children: "\u6DFB\u52A0\u89C6\u9891\u8D26\u53F7"
229
+ })
230
+ })
231
+ });
232
+ };
233
+ var onDel = function onDel(id) {
234
+ runDel(id);
235
+ };
236
+ useEffect(function () {
237
+ // 更新列表
238
+ event.on('account-list-update', function () {
239
+ run();
240
+ });
241
+ setInterval(function () {
242
+ run();
243
+ }, 5 * 60 * 1e3);
244
+ }, []);
245
+ useEffect(function () {
246
+ event.on('login', function () {
247
+ setUserInfo(getLocalUserInfo());
248
+ run();
249
+ });
250
+ event.on('logout', function () {
251
+ setUserInfo(getLocalUserInfo());
252
+ });
253
+
254
+ // window.bridge.ipcRenderer.on("amz-douyin-publish--account", (data: PublishNpm.AccountResult) => {
255
+ // console.log("账号日志 douyin: ", data);
256
+ // onAccountLogin( data );
257
+ // });
258
+ // window.bridge.ipcRenderer.on("amz-douyin-publish--log", (str: string) => {
259
+ // console.log("发布视频日志: ", str);
260
+ // });
261
+ // window.bridge.ipcRenderer.on("amz-douyin-publish--err", (error: PublishNpm.IpcRendererError ) => {
262
+ // console.log("发布视频错误日志: ", error );
263
+ // Notification.notificationError( '抖音-出现问题' , error.msg )
264
+ // });
265
+ //
266
+ // window.bridge.ipcRenderer.on("amz-kwai-publish--account", (data: PublishNpm.AccountResult) => {
267
+ // console.log("账号日志 kwai : ", data);
268
+ // onAccountLogin( data );
269
+ // });
270
+ // window.bridge.ipcRenderer.on("amz-kwai-publish--log", (str: string) => {
271
+ // console.log("发布视频日志: ", str)
272
+ // });
273
+ // window.bridge.ipcRenderer.on("amz-kwai-publish--err", (error: PublishNpm.IpcRendererError ) => {
274
+ // console.log("发布视频错误日志: ", error )
275
+ // });
276
+ }, []);
277
+ var loginValidAmount = listData.filter(function (item) {
278
+ return item.isLoginValid;
279
+ }).length;
280
+ var notLoginValidAmount = listData.filter(function (item) {
281
+ return !item.isLoginValid;
282
+ }).length;
283
+ return /*#__PURE__*/_jsx("div", {
284
+ className: "videoPublishAccountList",
285
+ style: {
286
+ width: width
287
+ },
288
+ children: userInfo.isLogin ? /*#__PURE__*/_jsxs(_Fragment, {
289
+ children: [/*#__PURE__*/_jsx("div", {
290
+ className: "search",
291
+ children: isOpen ? /*#__PURE__*/_jsxs(Space, {
292
+ size: 3,
293
+ children: [/*#__PURE__*/_jsx(Input, {
294
+ size: "small",
295
+ placeholder: "\u641C\u7D22\u8D26\u53F7\u540D\u79F0",
296
+ allowClear: true,
297
+ onChange: function onChange(e) {
298
+ onSearch(e.target.value);
299
+ }
300
+ }), /*#__PURE__*/_jsx(Divider, {
301
+ type: "vertical"
302
+ }), /*#__PURE__*/_jsx("a", {
303
+ className: "onList",
304
+ onClick: function onClick() {
305
+ return run();
306
+ },
307
+ children: /*#__PURE__*/_jsx(SearchOutlined, {})
308
+ })]
309
+ }) : /*#__PURE__*/_jsx("a", {
310
+ className: "onList",
311
+ onClick: function onClick() {
312
+ return run();
313
+ },
314
+ children: /*#__PURE__*/_jsx(SearchOutlined, {})
315
+ })
316
+ }), /*#__PURE__*/_jsxs(PageContentWarp, {
317
+ loading: loading,
318
+ error: error,
319
+ onReload: run,
320
+ className: "list ".concat(isOpen ? '' : "listMini"),
321
+ children: [listData.length > 0 && /*#__PURE__*/_jsx("section", {
322
+ children: listData.map(function (item, index) {
323
+ var shopName = [];
324
+ if (keywordList.length === 0) {
325
+ shopName.push(item.nickname);
326
+ } else {
327
+ var isSearchMatch = false;
328
+ item.nickname.split('').map(function (letter) {
329
+ if (keywordList.includes(letter)) {
330
+ isSearchMatch = true;
331
+ shopName.push( /*#__PURE__*/_jsx("span", {
332
+ className: "high",
333
+ children: letter
334
+ }, letter));
335
+ } else {
336
+ shopName.push(letter);
337
+ }
338
+ });
339
+ // 未搜索到
340
+ if (!isSearchMatch) {
341
+ return null;
342
+ }
343
+ }
344
+ return /*#__PURE__*/_jsxs("article", {
345
+ className: "".concat(item.isLoginValid ? "valid" : "invalid", " ").concat(currentId == item.id ? "active" : ''),
346
+ onClick: function onClick() {
347
+ return onCurrentId(item.id);
348
+ },
349
+ children: [/*#__PURE__*/_jsx("i", {
350
+ className: "index",
351
+ children: index + 1
352
+ }), /*#__PURE__*/_jsx(Popconfirm, {
353
+ title: "\u5220\u9664\u8D26\u6237",
354
+ description: "\u786E\u5B9A\u5220\u9664\u8D26\u6237\uFF1F\u5220\u9664\u4E4B\u540E\u4E0D\u80FD\u53D1\u5E03\u89C6\u9891\u4E86",
355
+ onConfirm: function onConfirm() {
356
+ return onDel(item.id);
357
+ },
358
+ children: /*#__PURE__*/_jsx("a", {
359
+ className: "del",
360
+ children: /*#__PURE__*/_jsx(CloseOutlined, {})
361
+ })
362
+ }), /*#__PURE__*/_jsxs("div", {
363
+ className: "avatar",
364
+ children: [/*#__PURE__*/_jsx(Avatar, {
365
+ className: "avatarUrl",
366
+ size: 46,
367
+ src: item.avatar || 'data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7'
368
+ }), /*#__PURE__*/_jsx(Tooltip, {
369
+ title: item.isLoginValid ? '登录有效' : '登录失效',
370
+ children: /*#__PURE__*/_jsx("div", {
371
+ className: "isLoginValid"
372
+ })
373
+ })]
374
+ }), /*#__PURE__*/_jsxs("div", {
375
+ className: "shopName",
376
+ children: [/*#__PURE__*/_jsx(VideoPlatformLogo, {
377
+ platform: item.platform,
378
+ size: 14
379
+ }), shopName, /*#__PURE__*/_jsx("div", {
380
+ className: "uniqueId",
381
+ children: item.uniqueId
382
+ })]
383
+ })]
384
+ }, item.id);
385
+ })
386
+ }), listData.length == 0 && /*#__PURE__*/_jsxs("div", {
387
+ className: "empty",
388
+ children: [/*#__PURE__*/_jsx(Empty, {
389
+ description: "\u6682\u65E0\u7ED1\u5B9A\u8D26\u53F7",
390
+ image: Empty.PRESENTED_IMAGE_SIMPLE
391
+ }), addButton()]
392
+ })]
393
+ }), /*#__PURE__*/_jsxs("div", {
394
+ className: "submits",
395
+ children: [/*#__PURE__*/_jsx("div", {
396
+ className: "amount",
397
+ children: /*#__PURE__*/_jsx(Tooltip, {
398
+ title: /*#__PURE__*/_jsxs(_Fragment, {
399
+ children: ["\u672A\u767B\u5F55\uFF1A", notLoginValidAmount, " \u4E2A ", /*#__PURE__*/_jsx(Divider, {
400
+ type: "vertical"
401
+ }), " \u5DF2\u767B\u5F55 ", loginValidAmount, " \u4E2A"]
402
+ }),
403
+ children: /*#__PURE__*/_jsxs(Space, {
404
+ children: [/*#__PURE__*/_jsx("strong", {
405
+ className: "notLoginValid",
406
+ children: notLoginValidAmount
407
+ }), "/", /*#__PURE__*/_jsx("span", {
408
+ className: "loginValid",
409
+ children: /*#__PURE__*/_jsx(Money, {
410
+ pre: "",
411
+ value: loginValidAmount,
412
+ precision: 0,
413
+ end: "\u4E2A"
414
+ })
415
+ })]
416
+ })
417
+ })
418
+ }), listData.length > 0 && addButton()]
419
+ })]
420
+ }) : /*#__PURE__*/_jsxs(_Fragment, {
421
+ children: [/*#__PURE__*/_jsx("div", {
422
+ className: "list"
423
+ }), /*#__PURE__*/_jsx("div", {
424
+ className: "submits",
425
+ children: addButton()
426
+ })]
427
+ })
428
+ });
429
+ };
430
+ export default HomePageAccountList;
@@ -0,0 +1,162 @@
1
+ .videoPublishAccountList{
2
+ width: 200px;
3
+ display: flex;
4
+ flex-direction: column;
5
+ height: calc( 100vh - 56px - 28px );
6
+ border-right: 1px solid #E8E8E8;
7
+ position: relative;
8
+ transition: width 0.3s ease-in-out;
9
+
10
+ .search{
11
+ margin: 10px;
12
+ .onList{
13
+ color: #999;
14
+ font-size: 15px;
15
+ text-align: center;
16
+ display: block;
17
+ margin: 0 auto;
18
+ &:hover{
19
+ color: #722ed1;
20
+ }
21
+ }
22
+ }
23
+
24
+ .list{
25
+ flex: 2;
26
+ height: 100%; // calc(100vh - 10px);
27
+ overflow-y: auto;
28
+ padding: 10px;
29
+ &::-webkit-scrollbar {
30
+ width: 2px; /* 滚动条的宽度 */
31
+ }
32
+ &::-webkit-scrollbar-thumb {
33
+ background-color: #DDD; /* 滑块的颜色 */
34
+ border-radius: 4px; /* 滑块的圆角 */
35
+ }
36
+ .high{
37
+ color: #C00;
38
+ font-weight: bold;
39
+ }
40
+ .empty{
41
+ margin: 40% auto 0;
42
+ }
43
+ section{
44
+ padding: 5px;
45
+ article{
46
+ position: relative;
47
+ display: flex;
48
+ flex-direction: row;
49
+ cursor: pointer;
50
+ padding: 6px 10px;
51
+ margin: 3px 0;
52
+ border-radius: 5px;
53
+ .index{
54
+ position: absolute;
55
+ top: 10px;
56
+ right: 4px;
57
+ font-size: 12px;
58
+ font-style: normal;
59
+ opacity: 0.3;
60
+ }
61
+ .del{
62
+ position: absolute;
63
+ bottom: 7px;
64
+ right: 4px;
65
+ padding: 3px;
66
+ font-size: 12px;
67
+ color: #FFF;
68
+ border-radius: 3px;
69
+ background-color: #C00;
70
+ line-height: 1em;
71
+ display: none;
72
+ }
73
+ &:hover{
74
+ background-color: #dcf0f6;
75
+ .del{
76
+ display: inline-block;
77
+ }
78
+ }
79
+ &.active{
80
+ background-color: #b6e5f6;
81
+ color: #0063ed;
82
+ font-weight: bold;
83
+ }
84
+ &.valid{
85
+ .isLoginValid{
86
+ background-color: #00bc00;
87
+ }
88
+ .shopName{
89
+ color: #005a00;
90
+ }
91
+ }
92
+ &.invalid{
93
+ background-color: #e1e1e1;
94
+ .isLoginValid{
95
+ background-color: red;
96
+ }
97
+ .shopName{
98
+ color: #999;
99
+ font-weight: 300;
100
+ }
101
+ .avatarUrl{
102
+ opacity: 0.5;
103
+ filter: grayscale(100%);
104
+ }
105
+ }
106
+ .avatar{
107
+ position: relative;
108
+ width: 40px;
109
+ //box-shadow: 0 0 5px #EEE;
110
+ .isLoginValid{
111
+ position: absolute;
112
+ left: 35px;
113
+ top: 35px;
114
+ width: 8px;
115
+ height: 8px;
116
+ border-radius: 100px;
117
+ }
118
+ }
119
+ .shopName{
120
+ max-width: 150px;
121
+ color: #666;
122
+ display: inline-block;
123
+ text-overflow: ellipsis;
124
+ //line-height: 30px;
125
+ font-size: 14px;
126
+ padding: 4px 0 0 12px;
127
+ word-break: keep-all;
128
+ white-space: nowrap;
129
+ overflow: hidden;
130
+ }
131
+ .uniqueId{
132
+ padding: 3px 0 0;
133
+ font-size: 12px;
134
+ opacity: 0.6;
135
+ }
136
+ }
137
+ }
138
+ }
139
+ .submits{
140
+ //box-shadow: 0 0 5px #EEE;
141
+ text-align: center;
142
+ padding: 12px 0 ;
143
+ display: flex;
144
+ margin: 0 12px 0 0;
145
+ flex-direction: row;
146
+ .amount{
147
+ flex: 2;
148
+ text-align: left;
149
+ font-size: 12px;
150
+ line-height: 32px;
151
+ .notLoginValid{
152
+ color: #C00;
153
+ }
154
+ .loginValid{
155
+ color: #00bc00;
156
+ }
157
+ }
158
+ }
159
+ .addButton{
160
+ text-align: center;
161
+ }
162
+ }
@@ -0,0 +1,6 @@
1
+ import React from 'react';
2
+ import './index.less';
3
+ interface Props {
4
+ }
5
+ declare const AccountManageSettingPage: React.FC<Props>;
6
+ export default AccountManageSettingPage;
@@ -0,0 +1,69 @@
1
+ import _regeneratorRuntime from "@babel/runtime/helpers/esm/regeneratorRuntime";
2
+ import _asyncToGenerator from "@babel/runtime/helpers/esm/asyncToGenerator";
3
+ import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
4
+ import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
5
+ import _objectDestructuringEmpty from "@babel/runtime/helpers/esm/objectDestructuringEmpty";
6
+ import React, { useEffect, useState } from 'react';
7
+ import { Form, Switch } from 'antd';
8
+ import "./index.less";
9
+ import LayoutContent from "../../../UI/LayoutContent";
10
+ import AccountManageSettingConfig from "../../../lib/accountManageSettingConfig";
11
+ import { jsx as _jsx } from "react/jsx-runtime";
12
+ var AccountManageSettingPage = function AccountManageSettingPage(_ref) {
13
+ _objectDestructuringEmpty(_ref);
14
+ var _Form$useForm = Form.useForm(),
15
+ _Form$useForm2 = _slicedToArray(_Form$useForm, 1),
16
+ form = _Form$useForm2[0];
17
+ var _useState = useState(_objectSpread({}, AccountManageSettingConfig())),
18
+ _useState2 = _slicedToArray(_useState, 2),
19
+ formData = _useState2[0],
20
+ setFormData = _useState2[1];
21
+ var onFinish = function onFinish(data) {
22
+ AccountManageSettingConfig(data);
23
+ };
24
+ var onInit = /*#__PURE__*/function () {
25
+ var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
26
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
27
+ while (1) switch (_context.prev = _context.next) {
28
+ case 0:
29
+ case "end":
30
+ return _context.stop();
31
+ }
32
+ }, _callee);
33
+ }));
34
+ return function onInit() {
35
+ return _ref2.apply(this, arguments);
36
+ };
37
+ }();
38
+ useEffect(function () {
39
+ onInit();
40
+ }, []);
41
+ return /*#__PURE__*/_jsx(LayoutContent, {
42
+ title: "\u8BBE\u7F6E",
43
+ subtitle: "",
44
+ className: "videoPublishAccountManageSetting",
45
+ children: /*#__PURE__*/_jsx(Form, {
46
+ form: form,
47
+ labelCol: {
48
+ span: 4
49
+ },
50
+ autoComplete: "off",
51
+ initialValues: _objectSpread({}, formData),
52
+ children: /*#__PURE__*/_jsx(Form.Item, {
53
+ label: "\u662F\u5426\u663E\u793A\u6D4F\u89C8\u5668",
54
+ name: "isChromeOpen",
55
+ extra: "\u8C03\u8BD5\u6D4B\u8BD5\u65F6\u6253\u5F00\uFF0C\u6B63\u5E38\u60C5\u51B5\u4E0B \u9690\u85CF\u6D4F\u89C8\u5668",
56
+ children: /*#__PURE__*/_jsx(Switch, {
57
+ checkedChildren: "\u663E\u793A\u6D4F\u89C8\u5668",
58
+ unCheckedChildren: "\u9690\u85CF\u6D4F\u89C8\u5668",
59
+ onChange: function onChange(isChromeOpen) {
60
+ formData.isChromeOpen = isChromeOpen;
61
+ setFormData(_objectSpread({}, formData));
62
+ onFinish(formData);
63
+ }
64
+ })
65
+ })
66
+ })
67
+ });
68
+ };
69
+ export default AccountManageSettingPage;
@@ -0,0 +1,9 @@
1
+ .videoPublishAccountManageSetting{
2
+
3
+ }
4
+
5
+ .select{
6
+ small{
7
+ color: #999;
8
+ }
9
+ }
@@ -2,6 +2,7 @@ import React from "react";
2
2
  import "./index.less";
3
3
  interface Props {
4
4
  disabled?: boolean;
5
+ canPublish: boolean;
5
6
  contentHeight?: number | string;
6
7
  productType: VideoPublish.ProductType;
7
8
  apiUrl: string;