Ver código fonte

dev: WantedModal

Roxas 4 anos atrás
pai
commit
3b555694fb
88 arquivos alterados com 83686 adições e 60168 exclusões
  1. 27
    24
      eslib/AllocWantedModal/index.d.ts
  2. 317
    195
      eslib/AllocWantedModal/index.js
  3. 1
    1
      eslib/AllocWantedModal/index.js.map
  4. 1
    3
      eslib/BraftEditor/index.d.ts
  5. 39879
    28961
      eslib/BraftEditor/index.js
  6. 1
    1
      eslib/BraftEditor/index.js.map
  7. 5
    5
      eslib/Common/index.js
  8. 21
    21
      eslib/ConsumeListView/index.d.ts
  9. 168
    129
      eslib/ConsumeListView/index.js
  10. 1
    1
      eslib/ConsumeListView/index.js.map
  11. 7
    7
      eslib/Editor/index.js
  12. 6
    6
      eslib/Modal/index.d.ts
  13. 86
    52
      eslib/Modal/index.js
  14. 1
    1
      eslib/Modal/index.js.map
  15. 35
    18
      eslib/PayPlatformOptions/index.d.ts
  16. 223
    140
      eslib/PayPlatformOptions/index.js
  17. 1
    1
      eslib/PayPlatformOptions/index.js.map
  18. 18
    18
      eslib/Payment/index.js
  19. 33
    18
      eslib/PriceOptions/index.d.ts
  20. 192
    136
      eslib/PriceOptions/index.js
  21. 1
    1
      eslib/PriceOptions/index.js.map
  22. 8
    8
      eslib/WaitPayInfoView/index.d.ts
  23. 100
    52
      eslib/WaitPayInfoView/index.js
  24. 1
    1
      eslib/WaitPayInfoView/index.js.map
  25. 27
    0
      eslib/WantedPublishModal/index.d.ts
  26. 164
    0
      eslib/WantedPublishModal/index.js
  27. 1
    0
      eslib/WantedPublishModal/index.js.map
  28. 25
    14
      eslib/WantedPublishPopover/index.d.ts
  29. 173
    129
      eslib/WantedPublishPopover/index.js
  30. 1
    1
      eslib/WantedPublishPopover/index.js.map
  31. 16
    13
      eslib/WantedPublishView/index.d.ts
  32. 155
    95
      eslib/WantedPublishView/index.js
  33. 1
    1
      eslib/WantedPublishView/index.js.map
  34. 15
    4
      eslib/_commonjsHelpers-97e6d7b1.js
  35. 43
    44
      eslib/index-c9837619.js
  36. 18
    18
      eslib/index.js
  37. 28
    10
      eslib/inherits-6cb67931.js
  38. 14
    3
      eslib/slicedToArray-4cd9e6d3.js
  39. 8
    6
      eslib/style-inject.es-1f59c1d0.js
  40. 23
    10
      eslib/utils-6b513b37.d.ts
  41. 16
    10
      eslib/utils-6b513b37.js
  42. 1
    1
      eslib/utils-6b513b37.js.map
  43. 27
    24
      lib/AllocWantedModal/index.d.ts
  44. 316
    198
      lib/AllocWantedModal/index.js
  45. 1
    1
      lib/AllocWantedModal/index.js.map
  46. 1
    3
      lib/BraftEditor/index.d.ts
  47. 39654
    28625
      lib/BraftEditor/index.js
  48. 1
    1
      lib/BraftEditor/index.js.map
  49. 7
    9
      lib/Common/index.js
  50. 21
    21
      lib/ConsumeListView/index.d.ts
  51. 165
    130
      lib/ConsumeListView/index.js
  52. 1
    1
      lib/ConsumeListView/index.js.map
  53. 9
    11
      lib/Editor/index.js
  54. 6
    6
      lib/Modal/index.d.ts
  55. 84
    55
      lib/Modal/index.js
  56. 1
    1
      lib/Modal/index.js.map
  57. 35
    18
      lib/PayPlatformOptions/index.d.ts
  58. 228
    143
      lib/PayPlatformOptions/index.js
  59. 1
    1
      lib/PayPlatformOptions/index.js.map
  60. 20
    22
      lib/Payment/index.js
  61. 33
    18
      lib/PriceOptions/index.d.ts
  62. 201
    139
      lib/PriceOptions/index.js
  63. 1
    1
      lib/PriceOptions/index.js.map
  64. 8
    8
      lib/WaitPayInfoView/index.d.ts
  65. 107
    56
      lib/WaitPayInfoView/index.js
  66. 1
    1
      lib/WaitPayInfoView/index.js.map
  67. 27
    0
      lib/WantedPublishModal/index.d.ts
  68. 167
    0
      lib/WantedPublishModal/index.js
  69. 1
    0
      lib/WantedPublishModal/index.js.map
  70. 25
    14
      lib/WantedPublishPopover/index.d.ts
  71. 172
    132
      lib/WantedPublishPopover/index.js
  72. 1
    1
      lib/WantedPublishPopover/index.js.map
  73. 16
    13
      lib/WantedPublishView/index.d.ts
  74. 162
    98
      lib/WantedPublishView/index.js
  75. 1
    1
      lib/WantedPublishView/index.js.map
  76. 16
    5
      lib/_commonjsHelpers-72d386ba.js
  77. 1
    1
      lib/defineProperty-ba7cd53d.js
  78. 44
    45
      lib/index-44e17595.js
  79. 20
    22
      lib/index.js
  80. 21
    10
      lib/inherits-c86d64c1.js
  81. 15
    4
      lib/slicedToArray-172f4624.js
  82. 9
    7
      lib/style-inject.es-dcee06b6.js
  83. 23
    10
      lib/utils-b800dc99.d.ts
  84. 18
    12
      lib/utils-b800dc99.js
  85. 1
    1
      lib/utils-b800dc99.js.map
  86. 2
    1
      stats.html
  87. 1
    139
      stories/Payment.stories.tsx
  88. 152
    0
      stories/Wanted.stories.tsx

+ 27
- 24
eslib/AllocWantedModal/index.d.ts Ver arquivo

@@ -3,32 +3,35 @@ import React from "react";
3 3
 import { RefObject } from "react";
4 4
 import { Input } from "antd";
5 5
 interface AllocWantedModalProps {
6
-    allocValue: string | number | null;
7
-    sendValueRange: Array<string | number>;
8
-    sendRequest: Function;
9
-    sendGiftData: {
10
-        answerId: string | number;
11
-        questionId: string | number;
12
-        toUserId: string | number;
13
-    };
14
-    handleVisibleChange: (visible: boolean) => void;
6
+  allocValue: string | number | null;
7
+  sendValueRange: Array<string | number>;
8
+  sendRequest: Function;
9
+  sendGiftData: {
10
+    answerId: string | number;
11
+    questionId: string | number;
12
+    toUserId: string | number;
13
+  };
14
+  handleVisibleChange: (visible: boolean) => void;
15 15
 }
16 16
 interface AllocWantedModalState {
17
-    visible: boolean;
18
-    outRangeTip: boolean;
19
-    sendValue: string | number;
17
+  visible: boolean;
18
+  outRangeTip: boolean;
19
+  sendValue: string | number;
20 20
 }
21
-declare class AllocWantedModal extends React.Component<AllocWantedModalProps, AllocWantedModalState> {
22
-    ModalInputRef: RefObject<Input>;
23
-    ModalContentRef: RefObject<any>;
24
-    constructor(props: AllocWantedModalProps);
25
-    handleSendValueChange: (v: React.ReactText) => void;
26
-    checkSendValue: () => boolean;
27
-    handleCloseAction: () => void;
28
-    handleShowAction: () => void;
29
-    handleConfirm: () => null | undefined;
30
-    renderCloseButton: () => JSX.Element;
31
-    renderModalContent: () => JSX.Element;
32
-    render(): JSX.Element;
21
+declare class AllocWantedModal extends React.Component<
22
+  AllocWantedModalProps,
23
+  AllocWantedModalState
24
+> {
25
+  ModalInputRef: RefObject<Input>;
26
+  ModalContentRef: RefObject<any>;
27
+  constructor(props: AllocWantedModalProps);
28
+  handleSendValueChange: (v: React.ReactText) => void;
29
+  checkSendValue: () => boolean;
30
+  handleCloseAction: () => void;
31
+  handleShowAction: () => void;
32
+  handleConfirm: () => null | undefined;
33
+  renderCloseButton: () => JSX.Element;
34
+  renderModalContent: () => JSX.Element;
35
+  render(): JSX.Element;
33 36
 }
34 37
 export { AllocWantedModal as default };

+ 317
- 195
eslib/AllocWantedModal/index.js Ver arquivo

@@ -1,226 +1,348 @@
1
-import { a as _inherits, b as _classCallCheck, c as _possibleConstructorReturn, d as _getPrototypeOf, e as _createClass } from '../inherits-6cb67931.js';
2
-import React from 'react';
3
-import 'react-dom';
4
-import { Modal } from '../Modal/index.js';
5
-import { s as styleInject } from '../style-inject.es-1f59c1d0.js';
6
-import { Tooltip, Input, Button, Popover } from 'antd';
1
+import {
2
+  a as _inherits,
3
+  b as _classCallCheck,
4
+  c as _possibleConstructorReturn,
5
+  d as _getPrototypeOf,
6
+  e as _createClass
7
+} from "../inherits-6cb67931.js";
8
+import React from "react";
9
+import "react-dom";
10
+import { Modal } from "../Modal/index.js";
11
+import { s as styleInject } from "../style-inject.es-1f59c1d0.js";
12
+import { Tooltip, Input, Button, Popover } from "antd";
7 13
 
8
-var img = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABMAAAATCAYAAAByUDbMAAACMUlEQVQ4T52Uz4tSURTHPxP9oCkKy0UuIqvZSAsrHHgLEaFSDCJoU0GpQaBgqOCmP6AWKrR5kIELNzZZUUQLlReFFowOboQK2oyLkgExsxqJoprixlx5yXs1dXbvnO/93HPPO+dM8WfbCuwANgNfgA/A0OzIlElgH3AIsBrEl4EXwEvguz4+CdsIHAV2/yVjEX4PVFez/SXXwzYAJ4GdawBJyWfggQTqYSKj/f8AklKR4V1gRcJ2rWY1Zvl8PqumaW8n4YFAwFqpVCb988BzCTsCzMiDDodjut1uX11YWGh4PJ470p/L5ZRIJHI+kUhcU1V1UXfRR+CWhF0ARPHHpqrqbCwWC7darXm32z2Xz+fdoVDobL1ef+z1eu8ZlOO2gIkeChrVKpPJHEylUhd7vd5rm822V9O0it/vf2hS16qAbQfOmBW+3W6HnU6nMhgMlux2+5XRaLRion0iYJuAsJGgWq2e8Pv9x5vN5lOXy6V0Op1XiqLkh8PhNwN9WdbsHLBFL6jVaqc8Hs+xYrE4FwwGnyWTyZl0On2p2+0uKopyo9/vf9XpfwA3JcwNHND/zUajcblUKpWj0WhT+qPRqD2bzUbi8fj1QqHwRgfrA/clbBtwGlgnBRaLZb3Rc0z8j4COfgJmgcP/MQEiw/LkbAqwGCmxMdZq7wDRKmI9/Tbo8ltk6NQ/2YTcAWrA+EeY7TPRewK4B5jWwcRB8Syxy5YmLzGD6XViQuSm/QSINjC0n/ltqZBTCKFgAAAAAElFTkSuQmCC";
14
+var img =
15
+  "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABMAAAATCAYAAAByUDbMAAACMUlEQVQ4T52Uz4tSURTHPxP9oCkKy0UuIqvZSAsrHHgLEaFSDCJoU0GpQaBgqOCmP6AWKrR5kIELNzZZUUQLlReFFowOboQK2oyLkgExsxqJoprixlx5yXs1dXbvnO/93HPPO+dM8WfbCuwANgNfgA/A0OzIlElgH3AIsBrEl4EXwEvguz4+CdsIHAV2/yVjEX4PVFez/SXXwzYAJ4GdawBJyWfggQTqYSKj/f8AklKR4V1gRcJ2rWY1Zvl8PqumaW8n4YFAwFqpVCb988BzCTsCzMiDDodjut1uX11YWGh4PJ470p/L5ZRIJHI+kUhcU1V1UXfRR+CWhF0ARPHHpqrqbCwWC7darXm32z2Xz+fdoVDobL1ef+z1eu8ZlOO2gIkeChrVKpPJHEylUhd7vd5rm822V9O0it/vf2hS16qAbQfOmBW+3W6HnU6nMhgMlux2+5XRaLRion0iYJuAsJGgWq2e8Pv9x5vN5lOXy6V0Op1XiqLkh8PhNwN9WdbsHLBFL6jVaqc8Hs+xYrE4FwwGnyWTyZl0On2p2+0uKopyo9/vf9XpfwA3JcwNHND/zUajcblUKpWj0WhT+qPRqD2bzUbi8fj1QqHwRgfrA/clbBtwGlgnBRaLZb3Rc0z8j4COfgJmgcP/MQEiw/LkbAqwGCmxMdZq7wDRKmI9/Tbo8ltk6NQ/2YTcAWrA+EeY7TPRewK4B5jWwcRB8Syxy5YmLzGD6XViQuSm/QSINjC0n/ltqZBTCKFgAAAAAElFTkSuQmCC";
9 16
 
10
-var css = ".AllocWantedModal_wantedModalContent__1VodF {\n  background-color: white;\n  width: 360px;\n  height: 314px;\n  padding: 22px 28px;\n  border-radius: 7px;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_title__31i9F {\n  font-size: 18px;\n  font-weight: 400;\n  text-align: center;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_wantedValueText___uNQe {\n  color: #565656;\n  margin-top: 48px;\n  font-size: 14px;\n  line-height: 20px;\n  text-align: center;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_wantedInputNumber__3MyO5 {\n  margin: 11px auto;\n  text-align: center;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_wantedInputNumber__3MyO5 .ant-input {\n  color: #FB4B56;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_wantedValueTipBottom__3WBt0 {\n  margin: 0 auto;\n  font-size: 12px;\n  text-align: center;\n  width: 208px;\n  color: #9B9B9B;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX {\n  display: flex;\n  justify-content: center;\n  align-items: center;\n  margin-top: 23px;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX .AllocWantedModal_confirmButton__1yXDN {\n  color: white;\n  background-color: #71C135;\n  width: 170px;\n  height: 36px;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX .AllocWantedModal_confirmButton__1yXDN:hover,\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX .AllocWantedModal_confirmButton__1yXDN:focus {\n  outline: none;\n  border-color: #8cd158;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX .AllocWantedModal_tipsButton__UmFpw {\n  margin-left: 22px;\n  width: 20px;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX .AllocWantedModal_tipsButton__UmFpw .schedule {\n  font-size: 18px;\n  cursor: pointer;\n}\n.AllocWantedModal_closeButton__1d4p- {\n  position: absolute;\n  right: 10px;\n  top: 10px;\n  display: block;\n  width: 20px;\n  height: 20px;\n  border-radius: 50%;\n  cursor: pointer;\n}\n.AllocWantedModal_closeButton__1d4p- img {\n  width: 100%;\n  height: 100%;\n}\n.AllocWantedModal_tipsView__3my0J h6 {\n  margin: 0;\n  font-size: 12px;\n  line-height: 22px;\n  color: #3D3D3D;\n}\n.AllocWantedModal_tipsView__3my0J div {\n  font-size: 12px;\n}\n.AllocWantedModal_outRangeTextTip__3R4mw .ant-tooltip-inner {\n  color: red;\n}\n";
17
+var css =
18
+  ".AllocWantedModal_wantedModalContent__1VodF {\n  background-color: white;\n  width: 360px;\n  height: 314px;\n  padding: 22px 28px;\n  border-radius: 7px;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_title__31i9F {\n  font-size: 18px;\n  font-weight: 400;\n  text-align: center;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_wantedValueText___uNQe {\n  color: #565656;\n  margin-top: 48px;\n  font-size: 14px;\n  line-height: 20px;\n  text-align: center;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_wantedInputNumber__3MyO5 {\n  margin: 11px auto;\n  text-align: center;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_wantedInputNumber__3MyO5 .ant-input {\n  color: #FB4B56;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_wantedValueTipBottom__3WBt0 {\n  margin: 0 auto;\n  font-size: 12px;\n  text-align: center;\n  width: 208px;\n  color: #9B9B9B;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX {\n  display: flex;\n  justify-content: center;\n  align-items: center;\n  margin-top: 23px;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX .AllocWantedModal_confirmButton__1yXDN {\n  color: white;\n  background-color: #71C135;\n  width: 170px;\n  height: 36px;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX .AllocWantedModal_confirmButton__1yXDN:hover,\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX .AllocWantedModal_confirmButton__1yXDN:focus {\n  outline: none;\n  border-color: #8cd158;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX .AllocWantedModal_tipsButton__UmFpw {\n  margin-left: 22px;\n  width: 20px;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX .AllocWantedModal_tipsButton__UmFpw .schedule {\n  font-size: 18px;\n  cursor: pointer;\n}\n.AllocWantedModal_closeButton__1d4p- {\n  position: absolute;\n  right: 10px;\n  top: 10px;\n  display: block;\n  width: 20px;\n  height: 20px;\n  border-radius: 50%;\n  cursor: pointer;\n}\n.AllocWantedModal_closeButton__1d4p- img {\n  width: 100%;\n  height: 100%;\n}\n.AllocWantedModal_tipsView__3my0J h6 {\n  margin: 0;\n  font-size: 12px;\n  line-height: 22px;\n  color: #3D3D3D;\n}\n.AllocWantedModal_tipsView__3my0J div {\n  font-size: 12px;\n}\n.AllocWantedModal_outRangeTextTip__3R4mw .ant-tooltip-inner {\n  color: red;\n}\n";
11 19
 var styles = {
12
-  "wantedModalContent": "AllocWantedModal_wantedModalContent__1VodF",
13
-  "title": "AllocWantedModal_title__31i9F",
14
-  "wantedValueText": "AllocWantedModal_wantedValueText___uNQe",
15
-  "wantedInputNumber": "AllocWantedModal_wantedInputNumber__3MyO5",
16
-  "wantedValueTipBottom": "AllocWantedModal_wantedValueTipBottom__3WBt0",
17
-  "buttonRow": "AllocWantedModal_buttonRow__FegZX",
18
-  "confirmButton": "AllocWantedModal_confirmButton__1yXDN",
19
-  "tipsButton": "AllocWantedModal_tipsButton__UmFpw",
20
-  "closeButton": "AllocWantedModal_closeButton__1d4p-",
21
-  "tipsView": "AllocWantedModal_tipsView__3my0J",
22
-  "outRangeTextTip": "AllocWantedModal_outRangeTextTip__3R4mw"
20
+  wantedModalContent: "AllocWantedModal_wantedModalContent__1VodF",
21
+  title: "AllocWantedModal_title__31i9F",
22
+  wantedValueText: "AllocWantedModal_wantedValueText___uNQe",
23
+  wantedInputNumber: "AllocWantedModal_wantedInputNumber__3MyO5",
24
+  wantedValueTipBottom: "AllocWantedModal_wantedValueTipBottom__3WBt0",
25
+  buttonRow: "AllocWantedModal_buttonRow__FegZX",
26
+  confirmButton: "AllocWantedModal_confirmButton__1yXDN",
27
+  tipsButton: "AllocWantedModal_tipsButton__UmFpw",
28
+  closeButton: "AllocWantedModal_closeButton__1d4p-",
29
+  tipsView: "AllocWantedModal_tipsView__3my0J",
30
+  outRangeTextTip: "AllocWantedModal_outRangeTextTip__3R4mw"
23 31
 };
24 32
 styleInject(css);
25 33
 
26 34
 var AllocWantedModal =
27
-/*#__PURE__*/
28
-function (_React$Component) {
29
-  _inherits(AllocWantedModal, _React$Component);
35
+  /*#__PURE__*/
36
+  (function(_React$Component) {
37
+    _inherits(AllocWantedModal, _React$Component);
30 38
 
31
-  function AllocWantedModal(props) {
32
-    var _this;
39
+    function AllocWantedModal(props) {
40
+      var _this;
33 41
 
34
-    _classCallCheck(this, AllocWantedModal);
42
+      _classCallCheck(this, AllocWantedModal);
35 43
 
36
-    _this = _possibleConstructorReturn(this, _getPrototypeOf(AllocWantedModal).call(this, props));
44
+      _this = _possibleConstructorReturn(
45
+        this,
46
+        _getPrototypeOf(AllocWantedModal).call(this, props)
47
+      );
48
+
49
+      _this.handleSendValueChange = function(v) {
50
+        if (_this.state.outRangeTip) {
51
+          _this.setState({
52
+            outRangeTip: !_this.checkSendValue()
53
+          });
54
+        }
37 55
 
38
-    _this.handleSendValueChange = function (v) {
39
-      if (_this.state.outRangeTip) {
40 56
         _this.setState({
41
-          outRangeTip: !_this.checkSendValue()
57
+          sendValue: v
42 58
         });
43
-      }
59
+      };
44 60
 
45
-      _this.setState({
46
-        sendValue: v
47
-      });
48
-    };
61
+      _this.checkSendValue = function() {
62
+        var sendValueRange = _this.props.sendValueRange;
63
+        var sendValue = _this.state.sendValue;
64
+        var min = 0;
65
+        var max = Number(_this.props.allocValue);
49 66
 
50
-    _this.checkSendValue = function () {
51
-      var sendValueRange = _this.props.sendValueRange;
52
-      var sendValue = _this.state.sendValue;
53
-      var min = 0;
54
-      var max = Number(_this.props.allocValue);
67
+        if (sendValueRange) {
68
+          min = Number(sendValueRange[0]);
69
+          max = Number(sendValueRange[1]);
70
+        }
55 71
 
56
-      if (sendValueRange) {
57
-        min = Number(sendValueRange[0]);
58
-        max = Number(sendValueRange[1]);
59
-      }
72
+        if (sendValue > max) {
73
+          _this.setState({
74
+            outRangeTip: true
75
+          });
60 76
 
61
-      if (sendValue > max) {
62
-        _this.setState({
63
-          outRangeTip: true
64
-        });
77
+          return false;
78
+        } else if (sendValue < min) {
79
+          _this.setState({
80
+            outRangeTip: true
81
+          });
65 82
 
66
-        return false;
67
-      } else if (sendValue < min) {
68
-        _this.setState({
69
-          outRangeTip: true
83
+          return false;
84
+        }
85
+
86
+        return true;
87
+      };
88
+
89
+      _this.handleCloseAction = function() {
90
+        _this.setState(
91
+          {
92
+            visible: false,
93
+            sendValue: 0,
94
+            outRangeTip: false
95
+          },
96
+          function() {
97
+            _this.props.handleVisibleChange(false);
98
+          }
99
+        );
100
+      };
101
+
102
+      _this.handleShowAction = function() {
103
+        _this.setState(
104
+          {
105
+            visible: true
106
+          },
107
+          function() {
108
+            _this.props.handleVisibleChange(true);
109
+          }
110
+        );
111
+      };
112
+
113
+      _this.handleConfirm = function() {
114
+        var sendGiftData = _this.props.sendGiftData;
115
+
116
+        var checkResult = _this.checkSendValue();
117
+
118
+        if (!checkResult) {
119
+          return null;
120
+        }
121
+
122
+        Promise.resolve(
123
+          _this.props.sendRequest({
124
+            business_type: 14,
125
+            ref_id: sendGiftData.answerId.toString(),
126
+            origin_id: sendGiftData.questionId,
127
+            to_user: sendGiftData.toUserId,
128
+            goods_id: 2,
129
+            num: Number(_this.state.sendValue)
130
+          })
131
+        ).then(function(res) {
132
+          console.log("res: ", res);
133
+
134
+          if (res) {
135
+            _this.handleCloseAction();
136
+          } else {
137
+            _this.handleCloseAction();
138
+          }
70 139
         });
140
+      };
71 141
 
72
-        return false;
73
-      }
142
+      _this.renderCloseButton = function() {
143
+        return React.createElement(
144
+          "div",
145
+          {
146
+            role: "button",
147
+            tabIndex: -1,
148
+            className: styles.closeButton,
149
+            onClick: function onClick() {
150
+              _this.handleCloseAction();
151
+            }
152
+          },
153
+          React.createElement("img", {
154
+            src: img,
155
+            alt: "close button for send wanted"
156
+          })
157
+        );
158
+      };
74 159
 
75
-      return true;
76
-    };
160
+      _this.renderModalContent = function() {
161
+        return React.createElement(
162
+          "div",
163
+          {
164
+            className: styles.wantedModalContent,
165
+            ref: _this.ModalContentRef
166
+          },
167
+          _this.renderCloseButton(),
168
+          React.createElement(
169
+            "h4",
170
+            {
171
+              className: styles.title
172
+            },
173
+            "\u5206\u914D\u60AC\u8D4F\u5956\u91D1"
174
+          ),
175
+          React.createElement(
176
+            "div",
177
+            {
178
+              className: styles.wantedValueText
179
+            },
180
+            "\u5269\u4F59\u53EF\u5206\u914D ".concat(
181
+              _this.props.allocValue,
182
+              "\u5143"
183
+            )
184
+          ),
185
+          React.createElement(
186
+            Tooltip,
187
+            {
188
+              visible: _this.state.outRangeTip,
189
+              title: "\u8D85\u8FC7\u8303\u56F4\u503C",
190
+              placement: "bottom",
191
+              overlayClassName: styles.outRangeTextTip,
192
+              getTooltipContainer: function getTooltipContainer() {
193
+                return _this.ModalContentRef && _this.ModalContentRef.current;
194
+              }
195
+            },
196
+            React.createElement(Input, {
197
+              ref: _this.ModalInputRef,
198
+              className: styles.wantedInputNumber,
199
+              suffix: "\u5143",
200
+              value: _this.state.sendValue,
201
+              onChange: function onChange(e) {
202
+                return _this.handleSendValueChange(e.target.value);
203
+              },
204
+              onFocus: function onFocus(e) {
205
+                return e.target.setSelectionRange(
206
+                  0,
207
+                  String(_this.state.sendValue).length
208
+                );
209
+              }
210
+            })
211
+          ),
212
+          React.createElement(
213
+            "div",
214
+            {
215
+              className: styles.wantedValueTipBottom
216
+            },
217
+            "\u9700\u8981\u5728\u60AC\u8D4F\u65F6\u95F4\u7ED3\u675F\u524D\u5C06\u5956\u91D1\u5206\u914D\u5B8C\u6210, \u5426\u5219\u5C06\u6309\u7167\u89C4\u5219\u81EA\u52A8\u5206\u914D"
218
+          ),
219
+          React.createElement(
220
+            "div",
221
+            {
222
+              className: styles.buttonRow
223
+            },
224
+            React.createElement("div", {
225
+              className: styles.tipsButton
226
+            }),
227
+            React.createElement(
228
+              Button,
229
+              {
230
+                className: styles.confirmButton,
231
+                onClick: _this.handleConfirm
232
+              },
233
+              "\u786E\u8BA4"
234
+            ),
235
+            React.createElement(
236
+              "div",
237
+              {
238
+                className: styles.tipsButton
239
+              },
240
+              React.createElement(
241
+                Popover,
242
+                {
243
+                  placement: "bottom",
244
+                  trigger: "click",
245
+                  getPopupContainer: function getPopupContainer() {
246
+                    return (
247
+                      _this.ModalContentRef && _this.ModalContentRef.current
248
+                    );
249
+                  },
250
+                  overlayStyle: {
251
+                    width: "320px"
252
+                  },
253
+                  content: React.createElement(
254
+                    "div",
255
+                    {
256
+                      className: styles.tipsView
257
+                    },
258
+                    React.createElement(
259
+                      "h6",
260
+                      null,
261
+                      "1\u3001\u5982\u4F55\u53C2\u4E0E\u60AC\u8D4F\uFF1F"
262
+                    ),
263
+                    React.createElement(
264
+                      "div",
265
+                      null,
266
+                      "\u60AC\u8D4F\u95EE\u9898\u7686\u6709\u6709\u6548\u671F\uFF0C\u9ED8\u8BA4\u4E3A120\u5C0F\u65F6\uFF085\u5929\uFF09\uFF0C\u5728\u6709\u6548\u671F\u5185\u56DE\u590D\u7684\u7B54\u6848\uFF0C\u624D\u6709\u8D44\u683C\u88AB\u9009\u4E3A\u6700\u4F73\u7B54\u6848\uFF0C\u4EE5\u53CA\u5206\u5F97\u8D4F\u91D1\u3002"
267
+                    ),
268
+                    React.createElement(
269
+                      "h6",
270
+                      null,
271
+                      "2\u3001\u8D4F\u91D1\u5982\u4F55\u5206\uFF1F"
272
+                    ),
273
+                    React.createElement(
274
+                      "div",
275
+                      null,
276
+                      "\u60AC\u8D4F\u65F6\u95F4\u7ED3\u675F\u524D\uFF0C\u63D0\u95EE\u8005\u53EF\u968F\u65F6\u9009\u51FA\u6700\u4F18\u7B54\u6848\uFF0C\u5E76\u5BF9\u8D4F\u91D1\u8FDB\u884C\u5206\u914D\uFF0C\u76F4\u81F3\u8D4F\u91D1\u88AB\u5206\u5B8C\u6216\u65F6\u95F4\u5230\u671F\u4E3A\u6B62\u3002\u82E5\u60AC\u8D4F\u65F6\u95F4\u5230\u671F\uFF0C\u60AC\u8D4F\u8005\u4ECD\u672A\u5206\u914D\u8D4F\u91D1\uFF0C\u4E14\u56DE\u7B54\u6570\u5927\u4E8E\u7B49\u4E8E2\uFF0C\u7CFB\u7EDF\u5219\u9ED8\u8BA4\u5C06\u8D4F\u91D1\u5E73\u5206\u7ED9\u70B9\u8D5E\u6570\u524D3\u540D\u7684\u56DE\u7B54\u3002"
277
+                    ),
278
+                    React.createElement(
279
+                      "h6",
280
+                      null,
281
+                      "3\u3001\u8D4F\u91D1\u80FD\u9000\u6B3E\u5417\uFF1F"
282
+                    ),
283
+                    React.createElement(
284
+                      "div",
285
+                      null,
286
+                      "\u8D4F\u91D1\u53EA\u4F1A\u5728\u4EE5\u4E0B2\u79CD\u60C5\u51B5\u8FDB\u884C\u9000\u6B3E\uFF1A\u4E00\u3001\u60AC\u8D4F\u65F6\u95F4\u5230\u671F\uFF0C\u56DE\u7B54\u6570\u5C0F\u4E8E2\uFF0C\u8D4F\u91D1\u5C06\u81EA\u52A8\u9000\u8FD8\u81F3\u63D0\u95EE\u8005\u7684\u94B1\u5305\uFF1B\u4E8C\u3001\u60AC\u8D4F\u65F6\u95F4\u5230\u671F\uFF0C\u60AC\u8D4F\u8005\u672A\u5206\u914D\u5B8C\u8D4F\u91D1\uFF0C\u7CFB\u7EDF\u81EA\u52A8\u5C06\u5269\u4F59\u7684\u8D4F\u91D1\u9000\u8FD8\u81F3\u63D0\u95EE\u8005\u7684\u94B1\u5305\u3002"
287
+                    )
288
+                  )
289
+                },
290
+                React.createElement("i", {
291
+                  className: "schedule schedule-icon_rewardtips"
292
+                })
293
+              )
294
+            )
295
+          )
296
+        );
297
+      };
77 298
 
78
-    _this.handleCloseAction = function () {
79
-      _this.setState({
299
+      _this.state = {
80 300
         visible: false,
81 301
         sendValue: 0,
82 302
         outRangeTip: false
83
-      }, function () {
84
-        _this.props.handleVisibleChange(false);
85
-      });
86
-    };
87
-
88
-    _this.handleShowAction = function () {
89
-      _this.setState({
90
-        visible: true
91
-      }, function () {
92
-        _this.props.handleVisibleChange(true);
93
-      });
94
-    };
95
-
96
-    _this.handleConfirm = function () {
97
-      var sendGiftData = _this.props.sendGiftData;
98
-
99
-      var checkResult = _this.checkSendValue();
100
-
101
-      if (!checkResult) {
102
-        return null;
103
-      }
303
+      };
304
+      _this.ModalContentRef = React.createRef();
305
+      _this.ModalInputRef = React.createRef();
306
+      return _this;
307
+    }
104 308
 
105
-      Promise.resolve(_this.props.sendRequest({
106
-        business_type: 14,
107
-        ref_id: sendGiftData.answerId.toString(),
108
-        origin_id: sendGiftData.questionId,
109
-        to_user: sendGiftData.toUserId,
110
-        goods_id: 2,
111
-        num: Number(_this.state.sendValue)
112
-      })).then(function (res) {
113
-        console.log("res: ", res);
114
-
115
-        if (res) {
116
-          _this.handleCloseAction();
117
-        } else {
118
-          _this.handleCloseAction();
119
-        }
120
-      });
121
-    };
122
-
123
-    _this.renderCloseButton = function () {
124
-      return React.createElement("div", {
125
-        role: "button",
126
-        tabIndex: -1,
127
-        className: styles.closeButton,
128
-        onClick: function onClick() {
129
-          _this.handleCloseAction();
130
-        }
131
-      }, React.createElement("img", {
132
-        src: img,
133
-        alt: "close button for send wanted"
134
-      }));
135
-    };
136
-
137
-    _this.renderModalContent = function () {
138
-      return React.createElement("div", {
139
-        className: styles.wantedModalContent,
140
-        ref: _this.ModalContentRef
141
-      }, _this.renderCloseButton(), React.createElement("h4", {
142
-        className: styles.title
143
-      }, "\u5206\u914D\u60AC\u8D4F\u5956\u91D1"), React.createElement("div", {
144
-        className: styles.wantedValueText
145
-      }, "\u5269\u4F59\u53EF\u5206\u914D ".concat(_this.props.allocValue, "\u5143")), React.createElement(Tooltip, {
146
-        visible: _this.state.outRangeTip,
147
-        title: "\u8D85\u8FC7\u8303\u56F4\u503C",
148
-        placement: "bottom",
149
-        overlayClassName: styles.outRangeTextTip,
150
-        getTooltipContainer: function getTooltipContainer() {
151
-          return _this.ModalContentRef && _this.ModalContentRef.current;
152
-        }
153
-      }, React.createElement(Input, {
154
-        ref: _this.ModalInputRef,
155
-        className: styles.wantedInputNumber,
156
-        suffix: "\u5143",
157
-        value: _this.state.sendValue,
158
-        onChange: function onChange(e) {
159
-          return _this.handleSendValueChange(e.target.value);
160
-        },
161
-        onFocus: function onFocus(e) {
162
-          return e.target.setSelectionRange(0, String(_this.state.sendValue).length);
163
-        }
164
-      })), React.createElement("div", {
165
-        className: styles.wantedValueTipBottom
166
-      }, "\u9700\u8981\u5728\u60AC\u8D4F\u65F6\u95F4\u7ED3\u675F\u524D\u5C06\u5956\u91D1\u5206\u914D\u5B8C\u6210, \u5426\u5219\u5C06\u6309\u7167\u89C4\u5219\u81EA\u52A8\u5206\u914D"), React.createElement("div", {
167
-        className: styles.buttonRow
168
-      }, React.createElement("div", {
169
-        className: styles.tipsButton
170
-      }), React.createElement(Button, {
171
-        className: styles.confirmButton,
172
-        onClick: _this.handleConfirm
173
-      }, "\u786E\u8BA4"), React.createElement("div", {
174
-        className: styles.tipsButton
175
-      }, React.createElement(Popover, {
176
-        placement: "bottom",
177
-        trigger: "click",
178
-        getPopupContainer: function getPopupContainer() {
179
-          return _this.ModalContentRef && _this.ModalContentRef.current;
180
-        },
181
-        overlayStyle: {
182
-          width: "320px"
183
-        },
184
-        content: React.createElement("div", {
185
-          className: styles.tipsView
186
-        }, React.createElement("h6", null, "1\u3001\u5982\u4F55\u53C2\u4E0E\u60AC\u8D4F\uFF1F"), React.createElement("div", null, "\u60AC\u8D4F\u95EE\u9898\u7686\u6709\u6709\u6548\u671F\uFF0C\u9ED8\u8BA4\u4E3A120\u5C0F\u65F6\uFF085\u5929\uFF09\uFF0C\u5728\u6709\u6548\u671F\u5185\u56DE\u590D\u7684\u7B54\u6848\uFF0C\u624D\u6709\u8D44\u683C\u88AB\u9009\u4E3A\u6700\u4F73\u7B54\u6848\uFF0C\u4EE5\u53CA\u5206\u5F97\u8D4F\u91D1\u3002"), React.createElement("h6", null, "2\u3001\u8D4F\u91D1\u5982\u4F55\u5206\uFF1F"), React.createElement("div", null, "\u60AC\u8D4F\u65F6\u95F4\u7ED3\u675F\u524D\uFF0C\u63D0\u95EE\u8005\u53EF\u968F\u65F6\u9009\u51FA\u6700\u4F18\u7B54\u6848\uFF0C\u5E76\u5BF9\u8D4F\u91D1\u8FDB\u884C\u5206\u914D\uFF0C\u76F4\u81F3\u8D4F\u91D1\u88AB\u5206\u5B8C\u6216\u65F6\u95F4\u5230\u671F\u4E3A\u6B62\u3002\u82E5\u60AC\u8D4F\u65F6\u95F4\u5230\u671F\uFF0C\u60AC\u8D4F\u8005\u4ECD\u672A\u5206\u914D\u8D4F\u91D1\uFF0C\u4E14\u56DE\u7B54\u6570\u5927\u4E8E\u7B49\u4E8E2\uFF0C\u7CFB\u7EDF\u5219\u9ED8\u8BA4\u5C06\u8D4F\u91D1\u5E73\u5206\u7ED9\u70B9\u8D5E\u6570\u524D3\u540D\u7684\u56DE\u7B54\u3002"), React.createElement("h6", null, "3\u3001\u8D4F\u91D1\u80FD\u9000\u6B3E\u5417\uFF1F"), React.createElement("div", null, "\u8D4F\u91D1\u53EA\u4F1A\u5728\u4EE5\u4E0B2\u79CD\u60C5\u51B5\u8FDB\u884C\u9000\u6B3E\uFF1A\u4E00\u3001\u60AC\u8D4F\u65F6\u95F4\u5230\u671F\uFF0C\u56DE\u7B54\u6570\u5C0F\u4E8E2\uFF0C\u8D4F\u91D1\u5C06\u81EA\u52A8\u9000\u8FD8\u81F3\u63D0\u95EE\u8005\u7684\u94B1\u5305\uFF1B\u4E8C\u3001\u60AC\u8D4F\u65F6\u95F4\u5230\u671F\uFF0C\u60AC\u8D4F\u8005\u672A\u5206\u914D\u5B8C\u8D4F\u91D1\uFF0C\u7CFB\u7EDF\u81EA\u52A8\u5C06\u5269\u4F59\u7684\u8D4F\u91D1\u9000\u8FD8\u81F3\u63D0\u95EE\u8005\u7684\u94B1\u5305\u3002"))
187
-      }, React.createElement("i", {
188
-        className: "schedule schedule-icon_rewardtips"
189
-      })))));
190
-    };
191
-
192
-    _this.state = {
193
-      visible: false,
194
-      sendValue: 0,
195
-      outRangeTip: false
196
-    };
197
-    _this.ModalContentRef = React.createRef();
198
-    _this.ModalInputRef = React.createRef();
199
-    return _this;
200
-  }
201
-
202
-  _createClass(AllocWantedModal, [{
203
-    key: "render",
204
-    value: function render() {
205
-      var _this2 = this;
206
-
207
-      var children = this.props.children;
208
-      return React.createElement(React.Fragment, null, React.createElement("div", {
209
-        className: styles.wrapper,
210
-        onClick: function onClick() {
211
-          return _this2.handleShowAction();
212
-        }
213
-      }, children), React.createElement(Modal, {
214
-        visible: this.state.visible,
215
-        onCancel: function onCancel() {
216
-          return _this2.handleCloseAction();
309
+    _createClass(AllocWantedModal, [
310
+      {
311
+        key: "render",
312
+        value: function render() {
313
+          var _this2 = this;
314
+
315
+          var children = this.props.children;
316
+          return React.createElement(
317
+            React.Fragment,
318
+            null,
319
+            React.createElement(
320
+              "div",
321
+              {
322
+                className: styles.wrapper,
323
+                onClick: function onClick() {
324
+                  return _this2.handleShowAction();
325
+                }
326
+              },
327
+              children
328
+            ),
329
+            React.createElement(
330
+              Modal,
331
+              {
332
+                visible: this.state.visible,
333
+                onCancel: function onCancel() {
334
+                  return _this2.handleCloseAction();
335
+                }
336
+              },
337
+              this.renderModalContent()
338
+            )
339
+          );
217 340
         }
218
-      }, this.renderModalContent()));
219
-    }
220
-  }]);
341
+      }
342
+    ]);
221 343
 
222
-  return AllocWantedModal;
223
-}(React.Component);
344
+    return AllocWantedModal;
345
+  })(React.Component);
224 346
 
225 347
 export default AllocWantedModal;
226 348
 //# sourceMappingURL=index.js.map

+ 1
- 1
eslib/AllocWantedModal/index.js.map
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 1
- 3
eslib/BraftEditor/index.d.ts Ver arquivo

@@ -1,5 +1,3 @@
1 1
 /// <reference types="react" />
2
-declare const BarftEditorPage: ({ value, }: {
3
-    value: string;
4
-}) => JSX.Element;
2
+declare const BarftEditorPage: ({ value }: { value: string }) => JSX.Element;
5 3
 export { BarftEditorPage as default, BarftEditorPage };

+ 39879
- 28961
eslib/BraftEditor/index.js
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 1
- 1
eslib/BraftEditor/index.js.map
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 5
- 5
eslib/Common/index.js Ver arquivo

@@ -1,6 +1,6 @@
1
-import '../inherits-6cb67931.js';
2
-import 'react';
3
-import 'react-dom';
4
-export { default as Modal } from '../Modal/index.js';
5
-import '../style-inject.es-1f59c1d0.js';
1
+import "../inherits-6cb67931.js";
2
+import "react";
3
+import "react-dom";
4
+export { default as Modal } from "../Modal/index.js";
5
+import "../style-inject.es-1f59c1d0.js";
6 6
 //# sourceMappingURL=index.js.map

+ 21
- 21
eslib/ConsumeListView/index.d.ts Ver arquivo

@@ -1,29 +1,29 @@
1 1
 /// <reference types="react" />
2
-import { Component, MouseEvent } from 'react';
2
+import { Component, MouseEvent } from "react";
3 3
 interface dataItem {
4
-    id?: string | number;
5
-    user_avatar?: string;
6
-    bill_price?: number;
4
+  id?: string | number;
5
+  user_avatar?: string;
6
+  bill_price?: number;
7 7
 }
8 8
 interface Props {
9
-    isToggle: boolean;
10
-    onToggleChange: Function;
11
-    onConsumeItemClick: (e: MouseEvent, clickData: any) => any;
12
-    dataSource: Array<dataItem>;
13
-    listLength: number;
14
-    showLength: number;
15
-    options: {
16
-        avatarSize: number;
17
-        avatarMarginLeftAndRight: number;
18
-        kingdomWidth: number;
19
-        kingdomHeight: number;
20
-        kingdomPosition: [number, number];
21
-    };
9
+  isToggle: boolean;
10
+  onToggleChange: Function;
11
+  onConsumeItemClick: (e: MouseEvent, clickData: any) => any;
12
+  dataSource: Array<dataItem>;
13
+  listLength: number;
14
+  showLength: number;
15
+  options: {
16
+    avatarSize: number;
17
+    avatarMarginLeftAndRight: number;
18
+    kingdomWidth: number;
19
+    kingdomHeight: number;
20
+    kingdomPosition: [number, number];
21
+  };
22 22
 }
23 23
 declare class ConsumeListView extends Component<Props, {}> {
24
-    static defaultProps: Props;
25
-    renderConsumeItem(): JSX.Element[];
26
-    renderToggleButton(): JSX.Element | null;
27
-    render(): JSX.Element;
24
+  static defaultProps: Props;
25
+  renderConsumeItem(): JSX.Element[];
26
+  renderToggleButton(): JSX.Element | null;
27
+  render(): JSX.Element;
28 28
 }
29 29
 export { ConsumeListView as default };

+ 168
- 129
eslib/ConsumeListView/index.js Ver arquivo

@@ -1,150 +1,189 @@
1
-import { a as _inherits, b as _classCallCheck, c as _possibleConstructorReturn, d as _getPrototypeOf, e as _createClass } from '../inherits-6cb67931.js';
2
-import React, { Component } from 'react';
3
-import { s as styleInject } from '../style-inject.es-1f59c1d0.js';
4
-import { _ as _defineProperty } from '../defineProperty-18999f8e.js';
5
-import '../_commonjsHelpers-97e6d7b1.js';
6
-import { c as classnames } from '../index-c9837619.js';
7
-import { a as addImageProcess } from '../utils-6b513b37.js';
8
-
9
-var img = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAYAAABWzo5XAAABvklEQVQ4T62UTygEcRTHv29MIsqfk6OL5CYH5aKd9WfjwqxEnBzExYWTCEWJJGove5H8OTA1uwdCrOWAi83ZwUXJiSj5u+Z5s0msmd2SX81h+r33ee/7fW+G8E+H/srhqEcFCjphve1RzcaVK4j3mmoB5YxqQzdOxTji1wE2QZglb2jAEcT7/g4wr0rQugS1OYJ26nOg5nYDr4ZrR7yrl0FBAKBlqjEX3eRLwSXAmidvOJbSI47oF9LVKaCOkNc4/w7kSPOoFBqDwjpp4XA60LUkF8nzbsuERQt4ejtGdsYwiAYTYIV6STOD6UB3EpqXJC0u7zKxz0Mk3Zrj7lOLerJg5T9K+2lWhALiYx8xS9NbDZnUuPXy0wN/hYw3lnbPiNfE7HaSfTAloRqKWkya8WAnMrdmIBqfBqM/BehJAo+gKHMibdMGzUhqKUiZAHGVXJYLwPdpshPnRDRM4fl5+7uKL/0c1WXdOSie5Dh3wZcyoR7SQttO9z+M5MOWEsStFQmsTAoOwVK7qM64d5P6ayKJj9EqHBa5Q4kx2/ujqR1Exnsq493HH2muFN98oNtJ0g7s3Ul5/vwbSab+G+gDqFybE11pYkYAAAAASUVORK5CYII=";
10
-
11
-var css = ".ConsumeListView_wrapper__wlJjh {\n  display: flex;\n  justify-content: center;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR {\n  padding: 0;\n  margin: 0;\n  display: flex;\n  flex-wrap: wrap;\n  padding-top: 10px;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR li {\n  list-style: none;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_consumeItem__1QGpJ {\n  margin: 0 6px 10px;\n  text-align: center;\n  position: relative;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_consumeItem__1QGpJ .ConsumeListView_kingdomIcon__1nBe5 {\n  position: absolute;\n  width: 24px;\n  height: 22px;\n  left: -6px;\n  top: -12px;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_consumeItem__1QGpJ .ConsumeListView_avatar__1H-E5 {\n  margin: 0 auto 4px;\n  width: 36px;\n  height: 36px;\n  background-size: cover;\n  border-radius: 50%;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_consumeItem__1QGpJ .ConsumeListView_gray__3do1I {\n  color: #9b9b9b;\n  font-size: 12px;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_toggle__3eBTC {\n  margin: 0 6px 10px;\n  width: 36px;\n  height: 36px;\n  line-height: 36px;\n  background-color: #ececec;\n  border-radius: 50%;\n  color: #a8adb6;\n  cursor: pointer;\n  background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB4AAAAeCAYAAAA7MK6iAAACv0lEQVRIS8WXTW8SURSGzzAYNSYCA7SCUEqBioLtohvjD9CN7ozG36AmXfsRafxYN9b+BqNx50r3GjddqEVRRgSRVr4GWmOsERjfOwEzVYa5lAokEwJzznnOe865d+4IxPFRVXVPrVY73Wq1TgmCMIffYbjZ2q4b+E/GfysWi+WZw+F4it+/zMIKvQwAszcajXnYXEIwl1kwdh8JVPC1bLVaF5FE3cjHEFytVs8hyH04jvMAu9gUkexlp9P5uJv/P2DABCi9hbJehUPPinAkpKL8d6H8BpJQ9fbbAjOooigP8H2BIyi3CaAPJUm6qIdvAwN6G0qvcUfswxDK7wB+vePyB9zu6aNdKK9ROioUn+/0XAOz6W02m6kBBolXe1EUxSibdg0MtQn09Sav9yB2UL0A1QmBbQ6VSmWNd50OAu2sc5fL5WVTfAYD9WTQgP34Y9DOClB7D05X+nHcBdslAf19jnKfNAr2cmWVDuzfR7HoFCFTUyaqR8lUhr7/2KITc/Gu9mjrC6a4iLtjRhHfvv9Ea1/L5JLsNBML94Qz6OukTBWlTt5Dbjp2JGgUtsTAW7i713DxqSql0jkqrJfIKdloNhbpCmfQV8k0VZUNOuwZo2gkQFBmFPanKVibRFxpOUefC0VyOmw0E4+QqCt7s8mgH0ipbdKEb5wiIUB7N0UD9yy13l/O5CmbXyfJfpBm49MkihbSoKuA1jdpcsJD4aDfdA5gUDIdrr+jZLIFyuQK5AD8+NEQvXknU63+jUKTPgoGvDxQ1gJtuPpeTkw1U8+mnPU2MuWngN/DBW0bLe14A8mj3x+zX7TS+ryGi6JrMtoGMrItk6VULpcTqPtQHhIQuuB2uxOjfSwy1SM5CHQmYCRHn/azcjSHvQ586Mdb/aIb+oFeD2eHQOxM87j6eoXBBrGMa2evMPoE/sdL22+mI4T0ou1LqAAAAABJRU5ErkJggg==);\n  background-position: center;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_toggle__3eBTC.ConsumeListView_expand__3l80q {\n  transform: rotate(180deg);\n}\n";
1
+import {
2
+  a as _inherits,
3
+  b as _classCallCheck,
4
+  c as _possibleConstructorReturn,
5
+  d as _getPrototypeOf,
6
+  e as _createClass
7
+} from "../inherits-6cb67931.js";
8
+import React, { Component } from "react";
9
+import { s as styleInject } from "../style-inject.es-1f59c1d0.js";
10
+import { _ as _defineProperty } from "../defineProperty-18999f8e.js";
11
+import "../_commonjsHelpers-97e6d7b1.js";
12
+import { c as classnames } from "../index-c9837619.js";
13
+import { a as addImageProcess } from "../utils-6b513b37.js";
14
+
15
+var img =
16
+  "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAYAAABWzo5XAAABvklEQVQ4T62UTygEcRTHv29MIsqfk6OL5CYH5aKd9WfjwqxEnBzExYWTCEWJJGove5H8OTA1uwdCrOWAi83ZwUXJiSj5u+Z5s0msmd2SX81h+r33ee/7fW+G8E+H/srhqEcFCjphve1RzcaVK4j3mmoB5YxqQzdOxTji1wE2QZglb2jAEcT7/g4wr0rQugS1OYJ26nOg5nYDr4ZrR7yrl0FBAKBlqjEX3eRLwSXAmidvOJbSI47oF9LVKaCOkNc4/w7kSPOoFBqDwjpp4XA60LUkF8nzbsuERQt4ejtGdsYwiAYTYIV6STOD6UB3EpqXJC0u7zKxz0Mk3Zrj7lOLerJg5T9K+2lWhALiYx8xS9NbDZnUuPXy0wN/hYw3lnbPiNfE7HaSfTAloRqKWkya8WAnMrdmIBqfBqM/BehJAo+gKHMibdMGzUhqKUiZAHGVXJYLwPdpshPnRDRM4fl5+7uKL/0c1WXdOSie5Dh3wZcyoR7SQttO9z+M5MOWEsStFQmsTAoOwVK7qM64d5P6ayKJj9EqHBa5Q4kx2/ujqR1Exnsq493HH2muFN98oNtJ0g7s3Ul5/vwbSab+G+gDqFybE11pYkYAAAAASUVORK5CYII=";
17
+
18
+var css =
19
+  ".ConsumeListView_wrapper__wlJjh {\n  display: flex;\n  justify-content: center;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR {\n  padding: 0;\n  margin: 0;\n  display: flex;\n  flex-wrap: wrap;\n  padding-top: 10px;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR li {\n  list-style: none;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_consumeItem__1QGpJ {\n  margin: 0 6px 10px;\n  text-align: center;\n  position: relative;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_consumeItem__1QGpJ .ConsumeListView_kingdomIcon__1nBe5 {\n  position: absolute;\n  width: 24px;\n  height: 22px;\n  left: -6px;\n  top: -12px;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_consumeItem__1QGpJ .ConsumeListView_avatar__1H-E5 {\n  margin: 0 auto 4px;\n  width: 36px;\n  height: 36px;\n  background-size: cover;\n  border-radius: 50%;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_consumeItem__1QGpJ .ConsumeListView_gray__3do1I {\n  color: #9b9b9b;\n  font-size: 12px;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_toggle__3eBTC {\n  margin: 0 6px 10px;\n  width: 36px;\n  height: 36px;\n  line-height: 36px;\n  background-color: #ececec;\n  border-radius: 50%;\n  color: #a8adb6;\n  cursor: pointer;\n  background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB4AAAAeCAYAAAA7MK6iAAACv0lEQVRIS8WXTW8SURSGzzAYNSYCA7SCUEqBioLtohvjD9CN7ozG36AmXfsRafxYN9b+BqNx50r3GjddqEVRRgSRVr4GWmOsERjfOwEzVYa5lAokEwJzznnOe865d+4IxPFRVXVPrVY73Wq1TgmCMIffYbjZ2q4b+E/GfysWi+WZw+F4it+/zMIKvQwAszcajXnYXEIwl1kwdh8JVPC1bLVaF5FE3cjHEFytVs8hyH04jvMAu9gUkexlp9P5uJv/P2DABCi9hbJehUPPinAkpKL8d6H8BpJQ9fbbAjOooigP8H2BIyi3CaAPJUm6qIdvAwN6G0qvcUfswxDK7wB+vePyB9zu6aNdKK9ROioUn+/0XAOz6W02m6kBBolXe1EUxSibdg0MtQn09Sav9yB2UL0A1QmBbQ6VSmWNd50OAu2sc5fL5WVTfAYD9WTQgP34Y9DOClB7D05X+nHcBdslAf19jnKfNAr2cmWVDuzfR7HoFCFTUyaqR8lUhr7/2KITc/Gu9mjrC6a4iLtjRhHfvv9Ea1/L5JLsNBML94Qz6OukTBWlTt5Dbjp2JGgUtsTAW7i713DxqSql0jkqrJfIKdloNhbpCmfQV8k0VZUNOuwZo2gkQFBmFPanKVibRFxpOUefC0VyOmw0E4+QqCt7s8mgH0ipbdKEb5wiIUB7N0UD9yy13l/O5CmbXyfJfpBm49MkihbSoKuA1jdpcsJD4aDfdA5gUDIdrr+jZLIFyuQK5AD8+NEQvXknU63+jUKTPgoGvDxQ1gJtuPpeTkw1U8+mnPU2MuWngN/DBW0bLe14A8mj3x+zX7TS+ryGi6JrMtoGMrItk6VULpcTqPtQHhIQuuB2uxOjfSwy1SM5CHQmYCRHn/azcjSHvQ586Mdb/aIb+oFeD2eHQOxM87j6eoXBBrGMa2evMPoE/sdL22+mI4T0ou1LqAAAAABJRU5ErkJggg==);\n  background-position: center;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_toggle__3eBTC.ConsumeListView_expand__3l80q {\n  transform: rotate(180deg);\n}\n";
12 20
 var styles = {
13
-  "wrapper": "ConsumeListView_wrapper__wlJjh",
14
-  "consumelist": "ConsumeListView_consumelist__2dMCR",
15
-  "consumeItem": "ConsumeListView_consumeItem__1QGpJ",
16
-  "kingdomIcon": "ConsumeListView_kingdomIcon__1nBe5",
17
-  "avatar": "ConsumeListView_avatar__1H-E5",
18
-  "gray": "ConsumeListView_gray__3do1I",
19
-  "toggle": "ConsumeListView_toggle__3eBTC",
20
-  "expand": "ConsumeListView_expand__3l80q"
21
+  wrapper: "ConsumeListView_wrapper__wlJjh",
22
+  consumelist: "ConsumeListView_consumelist__2dMCR",
23
+  consumeItem: "ConsumeListView_consumeItem__1QGpJ",
24
+  kingdomIcon: "ConsumeListView_kingdomIcon__1nBe5",
25
+  avatar: "ConsumeListView_avatar__1H-E5",
26
+  gray: "ConsumeListView_gray__3do1I",
27
+  toggle: "ConsumeListView_toggle__3eBTC",
28
+  expand: "ConsumeListView_expand__3l80q"
21 29
 };
22 30
 styleInject(css);
23 31
 
24
-var DEFAULT_AVATAR = '//links-comment.oss-cn-beijing.aliyuncs.com/comment/20180820/Kgka4_oU1.jpeg';
32
+var DEFAULT_AVATAR =
33
+  "//links-comment.oss-cn-beijing.aliyuncs.com/comment/20180820/Kgka4_oU1.jpeg";
25 34
 
26 35
 var ConsumeListView =
27
-/*#__PURE__*/
28
-function (_Component) {
29
-  _inherits(ConsumeListView, _Component);
36
+  /*#__PURE__*/
37
+  (function(_Component) {
38
+    _inherits(ConsumeListView, _Component);
30 39
 
31
-  function ConsumeListView() {
32
-    _classCallCheck(this, ConsumeListView);
40
+    function ConsumeListView() {
41
+      _classCallCheck(this, ConsumeListView);
33 42
 
34
-    return _possibleConstructorReturn(this, _getPrototypeOf(ConsumeListView).apply(this, arguments));
35
-  }
36
-
37
-  _createClass(ConsumeListView, [{
38
-    key: "renderConsumeItem",
39
-    value: function renderConsumeItem() {
40
-      var _this$props = this.props,
41
-          dataSource = _this$props.dataSource,
42
-          isToggle = _this$props.isToggle,
43
-          onConsumeItemClick = _this$props.onConsumeItemClick,
44
-          showLength = _this$props.showLength,
45
-          listLength = _this$props.listLength,
46
-          options = _this$props.options;
47
-      var kingdomWidth = options.kingdomWidth,
48
-          kingdomHeight = options.kingdomHeight,
49
-          kingdomPosition = options.kingdomPosition,
50
-          avatarSize = options.avatarSize,
51
-          avatarMarginLeftAndRight = options.avatarMarginLeftAndRight;
52
-      var renderData = dataSource;
53
-
54
-      if (!isToggle && listLength > showLength) {
55
-        renderData = dataSource.slice(0, showLength - 1);
56
-      }
43
+      return _possibleConstructorReturn(
44
+        this,
45
+        _getPrototypeOf(ConsumeListView).apply(this, arguments)
46
+      );
47
+    }
57 48
 
58
-      return renderData.map(function (v, i) {
59
-        var kingdom = null;
49
+    _createClass(ConsumeListView, [
50
+      {
51
+        key: "renderConsumeItem",
52
+        value: function renderConsumeItem() {
53
+          var _this$props = this.props,
54
+            dataSource = _this$props.dataSource,
55
+            isToggle = _this$props.isToggle,
56
+            onConsumeItemClick = _this$props.onConsumeItemClick,
57
+            showLength = _this$props.showLength,
58
+            listLength = _this$props.listLength,
59
+            options = _this$props.options;
60
+          var kingdomWidth = options.kingdomWidth,
61
+            kingdomHeight = options.kingdomHeight,
62
+            kingdomPosition = options.kingdomPosition,
63
+            avatarSize = options.avatarSize,
64
+            avatarMarginLeftAndRight = options.avatarMarginLeftAndRight;
65
+          var renderData = dataSource;
66
+
67
+          if (!isToggle && listLength > showLength) {
68
+            renderData = dataSource.slice(0, showLength - 1);
69
+          }
60 70
 
61
-        if (i === 0) {
62
-          kingdom = React.createElement("img", {
63
-            className: styles.kingdomIcon,
64
-            src: img,
65
-            alt: "reward top user",
66
-            style: {
67
-              width: "".concat(kingdomWidth, "px"),
68
-              height: "".concat(kingdomHeight, "px"),
69
-              left: "".concat(kingdomPosition[0], "px"),
70
-              top: "".concat(kingdomPosition[1], "px")
71
+          return renderData.map(function(v, i) {
72
+            var kingdom = null;
73
+
74
+            if (i === 0) {
75
+              kingdom = React.createElement("img", {
76
+                className: styles.kingdomIcon,
77
+                src: img,
78
+                alt: "reward top user",
79
+                style: {
80
+                  width: "".concat(kingdomWidth, "px"),
81
+                  height: "".concat(kingdomHeight, "px"),
82
+                  left: "".concat(kingdomPosition[0], "px"),
83
+                  top: "".concat(kingdomPosition[1], "px")
84
+                }
85
+              });
71 86
             }
87
+
88
+            return React.createElement(
89
+              "li",
90
+              {
91
+                key: v.id,
92
+                className: styles.consumeItem,
93
+                style: {
94
+                  margin: "0 ".concat(avatarMarginLeftAndRight, "px 10px")
95
+                }
96
+              },
97
+              kingdom,
98
+              React.createElement("div", {
99
+                className: styles.avatar,
100
+                onClick: function onClick(e) {
101
+                  return onConsumeItemClick(e, v);
102
+                },
103
+                style: {
104
+                  backgroundImage: "url(".concat(
105
+                    addImageProcess(v.user_avatar || DEFAULT_AVATAR, {
106
+                      small: true
107
+                    }),
108
+                    ")"
109
+                  ),
110
+                  width: "".concat(avatarSize, "px"),
111
+                  height: "".concat(avatarSize, "px")
112
+                }
113
+              }),
114
+              React.createElement("span", {
115
+                className: styles.gray
116
+              })
117
+            );
72 118
           });
73 119
         }
74
-
75
-        return React.createElement("li", {
76
-          key: v.id,
77
-          className: styles.consumeItem,
78
-          style: {
79
-            margin: "0 ".concat(avatarMarginLeftAndRight, "px 10px")
120
+      },
121
+      {
122
+        key: "renderToggleButton",
123
+        value: function renderToggleButton() {
124
+          var _this$props2 = this.props,
125
+            isToggle = _this$props2.isToggle,
126
+            onToggleChange = _this$props2.onToggleChange,
127
+            listLength = _this$props2.listLength,
128
+            showLength = _this$props2.showLength,
129
+            options = _this$props2.options;
130
+          var avatarSize = options.avatarSize,
131
+            avatarMarginLeftAndRight = options.avatarMarginLeftAndRight;
132
+
133
+          if (listLength <= showLength) {
134
+            return null;
80 135
           }
81
-        }, kingdom, React.createElement("div", {
82
-          className: styles.avatar,
83
-          onClick: function onClick(e) {
84
-            return onConsumeItemClick(e, v);
85
-          },
86
-          style: {
87
-            backgroundImage: "url(".concat(addImageProcess(v.user_avatar || DEFAULT_AVATAR, {
88
-              small: true
89
-            }), ")"),
90
-            width: "".concat(avatarSize, "px"),
91
-            height: "".concat(avatarSize, "px")
92
-          }
93
-        }), React.createElement("span", {
94
-          className: styles.gray
95
-        }));
96
-      });
97
-    }
98
-  }, {
99
-    key: "renderToggleButton",
100
-    value: function renderToggleButton() {
101
-      var _this$props2 = this.props,
102
-          isToggle = _this$props2.isToggle,
103
-          onToggleChange = _this$props2.onToggleChange,
104
-          listLength = _this$props2.listLength,
105
-          showLength = _this$props2.showLength,
106
-          options = _this$props2.options;
107
-      var avatarSize = options.avatarSize,
108
-          avatarMarginLeftAndRight = options.avatarMarginLeftAndRight;
109
-
110
-      if (listLength <= showLength) {
111
-        return null;
112
-      }
113 136
 
114
-      return React.createElement("li", {
115
-        onClick: function onClick() {
116
-          return onToggleChange();
117
-        },
118
-        className: classnames(styles.toggle, _defineProperty({}, styles.expand, isToggle)),
119
-        style: {
120
-          width: "".concat(avatarSize, "px"),
121
-          height: "".concat(avatarSize, "px"),
122
-          lineHeight: "".concat(avatarSize, "px"),
123
-          margin: "0 ".concat(avatarMarginLeftAndRight, "px 10px")
137
+          return React.createElement("li", {
138
+            onClick: function onClick() {
139
+              return onToggleChange();
140
+            },
141
+            className: classnames(
142
+              styles.toggle,
143
+              _defineProperty({}, styles.expand, isToggle)
144
+            ),
145
+            style: {
146
+              width: "".concat(avatarSize, "px"),
147
+              height: "".concat(avatarSize, "px"),
148
+              lineHeight: "".concat(avatarSize, "px"),
149
+              margin: "0 ".concat(avatarMarginLeftAndRight, "px 10px")
150
+            }
151
+          });
124 152
         }
125
-      });
126
-    }
127
-  }, {
128
-    key: "render",
129
-    value: function render() {
130
-      var _this$props3 = this.props,
131
-          showLength = _this$props3.showLength,
132
-          options = _this$props3.options;
133
-      var avatarSize = options.avatarSize,
134
-          avatarMarginLeftAndRight = options.avatarMarginLeftAndRight;
135
-      return React.createElement("div", {
136
-        className: styles.wrapper
137
-      }, React.createElement("ul", {
138
-        className: styles.consumelist,
139
-        style: {
140
-          width: "calc(".concat(avatarMarginLeftAndRight * 2 + avatarSize, "px * ").concat(showLength, ")")
153
+      },
154
+      {
155
+        key: "render",
156
+        value: function render() {
157
+          var _this$props3 = this.props,
158
+            showLength = _this$props3.showLength,
159
+            options = _this$props3.options;
160
+          var avatarSize = options.avatarSize,
161
+            avatarMarginLeftAndRight = options.avatarMarginLeftAndRight;
162
+          return React.createElement(
163
+            "div",
164
+            {
165
+              className: styles.wrapper
166
+            },
167
+            React.createElement(
168
+              "ul",
169
+              {
170
+                className: styles.consumelist,
171
+                style: {
172
+                  width: "calc("
173
+                    .concat(avatarMarginLeftAndRight * 2 + avatarSize, "px * ")
174
+                    .concat(showLength, ")")
175
+                }
176
+              },
177
+              this.renderConsumeItem(),
178
+              this.renderToggleButton()
179
+            )
180
+          );
141 181
         }
142
-      }, this.renderConsumeItem(), this.renderToggleButton()));
143
-    }
144
-  }]);
182
+      }
183
+    ]);
145 184
 
146
-  return ConsumeListView;
147
-}(Component);
185
+    return ConsumeListView;
186
+  })(Component);
148 187
 
149 188
 ConsumeListView.defaultProps = {
150 189
   isToggle: false,

+ 1
- 1
eslib/ConsumeListView/index.js.map
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 7
- 7
eslib/Editor/index.js Ver arquivo

@@ -1,8 +1,8 @@
1
-import 'react';
2
-import 'react-dom';
3
-import '../style-inject.es-1f59c1d0.js';
4
-import '../_commonjsHelpers-97e6d7b1.js';
5
-import '../slicedToArray-4cd9e6d3.js';
6
-export { default as BraftEditor } from '../BraftEditor/index.js';
7
-import 'react-dom/server';
1
+import "react";
2
+import "react-dom";
3
+import "../style-inject.es-1f59c1d0.js";
4
+import "../_commonjsHelpers-97e6d7b1.js";
5
+import "../slicedToArray-4cd9e6d3.js";
6
+export { default as BraftEditor } from "../BraftEditor/index.js";
7
+import "react-dom/server";
8 8
 //# sourceMappingURL=index.js.map

+ 6
- 6
eslib/Modal/index.d.ts Ver arquivo

@@ -1,12 +1,12 @@
1 1
 /// <reference types="react" />
2
-import React from 'react';
2
+import React from "react";
3 3
 interface ModalProps {
4
-    visible: boolean;
5
-    onCancel: (e: any) => void;
6
-    container?: HTMLElement | null;
4
+  visible: boolean;
5
+  onCancel: (e: any) => void;
6
+  container?: HTMLElement | null;
7 7
 }
8 8
 declare class Modal extends React.PureComponent<ModalProps> {
9
-    static hasShowWarning: boolean;
10
-    render(): false | React.ReactPortal | null;
9
+  static hasShowWarning: boolean;
10
+  render(): false | React.ReactPortal | null;
11 11
 }
12 12
 export { Modal as default, Modal, ModalProps };

+ 86
- 52
eslib/Modal/index.js Ver arquivo

@@ -1,74 +1,108 @@
1
-import { _ as _typeof, a as _inherits, b as _classCallCheck, c as _possibleConstructorReturn, d as _getPrototypeOf, e as _createClass } from '../inherits-6cb67931.js';
2
-import React from 'react';
3
-import { createPortal } from 'react-dom';
4
-import { s as styleInject } from '../style-inject.es-1f59c1d0.js';
1
+import {
2
+  _ as _typeof,
3
+  a as _inherits,
4
+  b as _classCallCheck,
5
+  c as _possibleConstructorReturn,
6
+  d as _getPrototypeOf,
7
+  e as _createClass
8
+} from "../inherits-6cb67931.js";
9
+import React from "react";
10
+import { createPortal } from "react-dom";
11
+import { s as styleInject } from "../style-inject.es-1f59c1d0.js";
5 12
 
6 13
 function isBrowser() {
7
-  return !((typeof window === "undefined" ? "undefined" : _typeof(window)) === undefined);
14
+  return !(
15
+    (typeof window === "undefined" ? "undefined" : _typeof(window)) ===
16
+    undefined
17
+  );
8 18
 }
9 19
 
10
-var css = ".Modal_wrapper__2hzaC {\n  position: fixed;\n  width: 100vw;\n  height: 100vh;\n  top: 0;\n  left: 0;\n  z-index: 1000;\n}\n.Modal_overlay__3iNdm {\n  width: 100vw;\n  height: 100vh;\n  background: #000;\n  animation: Modal_overlayer__1zSH9 0.3s forwards;\n}\n.Modal_container__2veos {\n  position: absolute;\n  top: 20%;\n  left: 50%;\n  animation: Modal_container__2veos 0.3s forwards;\n}\n@keyframes Modal_overlayer__1zSH9 {\n  from {\n    opacity: 0;\n  }\n  to {\n    opacity: 0.3;\n  }\n}\n@keyframes Modal_container__2veos {\n  from {\n    transform: translateX(-50%) scale(0, 0);\n  }\n  to {\n    transform: translateX(-50%) scale(1, 1);\n  }\n}\n";
20
+var css =
21
+  ".Modal_wrapper__2hzaC {\n  position: fixed;\n  width: 100vw;\n  height: 100vh;\n  top: 0;\n  left: 0;\n  z-index: 1000;\n}\n.Modal_overlay__3iNdm {\n  width: 100vw;\n  height: 100vh;\n  background: #000;\n  animation: Modal_overlayer__1zSH9 0.3s forwards;\n}\n.Modal_container__2veos {\n  position: absolute;\n  top: 20%;\n  left: 50%;\n  animation: Modal_container__2veos 0.3s forwards;\n}\n@keyframes Modal_overlayer__1zSH9 {\n  from {\n    opacity: 0;\n  }\n  to {\n    opacity: 0.3;\n  }\n}\n@keyframes Modal_container__2veos {\n  from {\n    transform: translateX(-50%) scale(0, 0);\n  }\n  to {\n    transform: translateX(-50%) scale(1, 1);\n  }\n}\n";
11 22
 var styles = {
12
-  "wrapper": "Modal_wrapper__2hzaC",
13
-  "overlay": "Modal_overlay__3iNdm",
14
-  "overlayer": "Modal_overlayer__1zSH9",
15
-  "container": "Modal_container__2veos"
23
+  wrapper: "Modal_wrapper__2hzaC",
24
+  overlay: "Modal_overlay__3iNdm",
25
+  overlayer: "Modal_overlayer__1zSH9",
26
+  container: "Modal_container__2veos"
16 27
 };
17 28
 styleInject(css);
18 29
 
19 30
 var Modal =
20
-/*#__PURE__*/
21
-function (_React$PureComponent) {
22
-  _inherits(Modal, _React$PureComponent);
31
+  /*#__PURE__*/
32
+  (function(_React$PureComponent) {
33
+    _inherits(Modal, _React$PureComponent);
23 34
 
24
-  function Modal() {
25
-    _classCallCheck(this, Modal);
35
+    function Modal() {
36
+      _classCallCheck(this, Modal);
26 37
 
27
-    return _possibleConstructorReturn(this, _getPrototypeOf(Modal).apply(this, arguments));
28
-  }
38
+      return _possibleConstructorReturn(
39
+        this,
40
+        _getPrototypeOf(Modal).apply(this, arguments)
41
+      );
42
+    }
29 43
 
30
-  _createClass(Modal, [{
31
-    key: "render",
32
-    value: function render() {
33
-      if (!isBrowser()) return null;
34
-      var DEFAULT_CONTAINER = document.getElementById('container');
35
-      var _this$props = this.props,
36
-          children = _this$props.children,
37
-          visible = _this$props.visible,
38
-          onCancel = _this$props.onCancel,
39
-          _this$props$container = _this$props.container,
40
-          container = _this$props$container === void 0 ? DEFAULT_CONTAINER : _this$props$container;
41
-      var finalMountContainer = document.body;
44
+    _createClass(Modal, [
45
+      {
46
+        key: "render",
47
+        value: function render() {
48
+          if (!isBrowser()) return null;
49
+          var DEFAULT_CONTAINER = document.getElementById("container");
50
+          var _this$props = this.props,
51
+            children = _this$props.children,
52
+            visible = _this$props.visible,
53
+            onCancel = _this$props.onCancel,
54
+            _this$props$container = _this$props.container,
55
+            container =
56
+              _this$props$container === void 0
57
+                ? DEFAULT_CONTAINER
58
+                : _this$props$container;
59
+          var finalMountContainer = document.body;
42 60
 
43
-      if (!container) {
44
-        if (!DEFAULT_CONTAINER) {
45
-          if (!Modal.hasShowWarning) {
46
-            Modal.hasShowWarning = true;
47
-          }
61
+          if (!container) {
62
+            if (!DEFAULT_CONTAINER) {
63
+              if (!Modal.hasShowWarning) {
64
+                Modal.hasShowWarning = true;
65
+              }
66
+
67
+              finalMountContainer = document.body;
68
+            } else {
69
+              if (!Modal.hasShowWarning) {
70
+                Modal.hasShowWarning = true;
71
+              }
48 72
 
49
-          finalMountContainer = document.body;
50
-        } else {
51
-          if (!Modal.hasShowWarning) {
52
-            Modal.hasShowWarning = true;
73
+              finalMountContainer = DEFAULT_CONTAINER;
74
+            }
53 75
           }
54 76
 
55
-          finalMountContainer = DEFAULT_CONTAINER;
77
+          return (
78
+            visible &&
79
+            createPortal(
80
+              React.createElement(
81
+                "div",
82
+                {
83
+                  className: styles.wrapper
84
+                },
85
+                React.createElement("div", {
86
+                  className: styles.overlay,
87
+                  onClick: onCancel
88
+                }),
89
+                React.createElement(
90
+                  "div",
91
+                  {
92
+                    className: styles.container
93
+                  },
94
+                  children
95
+                )
96
+              ),
97
+              finalMountContainer
98
+            )
99
+          );
56 100
         }
57 101
       }
102
+    ]);
58 103
 
59
-      return visible && createPortal(React.createElement("div", {
60
-        className: styles.wrapper
61
-      }, React.createElement("div", {
62
-        className: styles.overlay,
63
-        onClick: onCancel
64
-      }), React.createElement("div", {
65
-        className: styles.container
66
-      }, children)), finalMountContainer);
67
-    }
68
-  }]);
69
-
70
-  return Modal;
71
-}(React.PureComponent);
104
+    return Modal;
105
+  })(React.PureComponent);
72 106
 Modal.hasShowWarning = false;
73 107
 
74 108
 export default Modal;

+ 1
- 1
eslib/Modal/index.js.map Ver arquivo

@@ -1 +1 @@
1
-{"version":3,"file":"index.js","sources":["../../src/components/Common/Utils/utils.ts","../../src/components/Common/Modal/index.tsx"],"sourcesContent":["export function isBrowser() {\r\n  return !(typeof window === undefined);\r\n}","import React from 'react';\r\nimport { createPortal } from 'react-dom';\r\nimport { isBrowser } from '../Utils/utils';\r\n\r\nimport styles from './Modal.less';\r\n\r\nexport interface ModalProps {\r\n  visible: boolean\r\n  onCancel: (e: any) => void\r\n  container?: HTMLElement | null\r\n}\r\n\r\nexport class Modal extends React.PureComponent<ModalProps> {\r\n  static hasShowWarning = false;\r\n\r\n  render() {\r\n    if (!isBrowser()) return null; // 服务端无需渲染下列代码,渲染也会出错\r\n    const DEFAULT_CONTAINER: HTMLElement | null = document.getElementById('container');\r\n    const { children, visible, onCancel, container = DEFAULT_CONTAINER } = this.props\r\n    let finalMountContainer: HTMLElement = document.body;\r\n    if (!container) {\r\n      if (!DEFAULT_CONTAINER) {\r\n        if (!Modal.hasShowWarning) {\r\n          Modal.hasShowWarning = true;\r\n        }\r\n        finalMountContainer = document.body;\r\n      } else {\r\n        if (!Modal.hasShowWarning) {\r\n          Modal.hasShowWarning = true;\r\n        }\r\n        finalMountContainer = DEFAULT_CONTAINER;\r\n      }\r\n    }\r\n    return visible && createPortal(\r\n      <div className={ styles.wrapper }>\r\n        <div\r\n          className={ styles.overlay }\r\n          onClick={ onCancel }\r\n        />\r\n        <div\r\n          className={ styles.container }\r\n        >\r\n          { children }\r\n        </div>\r\n      </div>,\r\n      finalMountContainer,\r\n    )\r\n  }\r\n}\r\n\r\nexport default Modal;"],"names":["isBrowser","window","undefined","Modal","DEFAULT_CONTAINER","document","getElementById","props","children","visible","onCancel","container","finalMountContainer","body","hasShowWarning","createPortal","React","createElement","className","styles","wrapper","overlay","onClick","PureComponent"],"mappings":";;;;;AAAM,SAAUA,SAAV,GAAmB;SAChB,EAAE,QAAOC,+CAAAA,OAAP,MAAkBC,SAApB;;;;;;;;;;;;ICWIC,KAAb;AAAA;AAAA,8BAAA;;;;;;;;;;;6BAGQ;UACA,CAACH,SAAS,IAAI,OAAO,IAAP;UACZI,iBAAiB,GAAuBC,QAAQ,CAACC,cAAT,CAAwB,WAAxB;wBACyB,KAAKC;UAApEC,QAHJ,eAGIA;UAAUC,OAHd,eAGcA;UAASC,QAHvB,eAGuBA;8CAAUC;UAAAA,SAHjC,sCAG6CP;UAC7CQ,mBAAmB,GAAgBP,QAAQ,CAACQ;;UAC5C,CAACF,WAAW;YACV,CAACP,mBAAmB;cAClB,CAACD,KAAK,CAACW,gBAAgB;AACzBX,YAAAA,KAAK,CAACW,cAAN,GAAuB,IAAvB;;;AAEFF,UAAAA,mBAAmB,GAAGP,QAAQ,CAACQ,IAA/B;AAJF,eAKO;cACD,CAACV,KAAK,CAACW,gBAAgB;AACzBX,YAAAA,KAAK,CAACW,cAAN,GAAuB,IAAvB;;;AAEFF,UAAAA,mBAAmB,GAAGR,iBAAtB;;;;aAGGK,OAAO,IAAIM,YAAY,CAC5BC,KAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AAAKC,QAAAA,SAAS,EAAGC,MAAM,CAACC;AAAxB,OAAA,EACEJ,KAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AACEC,QAAAA,SAAS,EAAGC,MAAM,CAACE,OADrB;AAEEC,QAAAA,OAAO,EAAGZ;AAFZ,OAAA,CADF,EAKEM,KAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AACEC,QAAAA,SAAS,EAAGC,MAAM,CAACR;AADrB,OAAA,EAGIH,QAHJ,CALF,CAD4B,EAY5BI,mBAZ4B;;;;;CArBlC,CAA2BI,KAAK,CAACO,aAAjC;AACSpB,KAAA,CAAAW,cAAA,GAAiB,KAAjB;;;;;"}
1
+{"version":3,"file":"index.js","sources":["../../src/components/Common/Utils/utils.ts","../../src/components/Common/Modal/index.tsx"],"sourcesContent":["export function isBrowser() {\n  return !(typeof window === undefined);\n}","import React from 'react';\nimport { createPortal } from 'react-dom';\nimport { isBrowser } from '../Utils/utils';\n\nimport styles from './Modal.less';\n\nexport interface ModalProps {\n  visible: boolean\n  onCancel: (e: any) => void\n  container?: HTMLElement | null\n}\n\nexport class Modal extends React.PureComponent<ModalProps> {\n  static hasShowWarning = false;\n\n  render() {\n    if (!isBrowser()) return null; // 服务端无需渲染下列代码,渲染也会出错\n    const DEFAULT_CONTAINER: HTMLElement | null = document.getElementById('container');\n    const { children, visible, onCancel, container = DEFAULT_CONTAINER } = this.props\n    let finalMountContainer: HTMLElement = document.body;\n    if (!container) {\n      if (!DEFAULT_CONTAINER) {\n        if (!Modal.hasShowWarning) {\n          Modal.hasShowWarning = true;\n        }\n        finalMountContainer = document.body;\n      } else {\n        if (!Modal.hasShowWarning) {\n          Modal.hasShowWarning = true;\n        }\n        finalMountContainer = DEFAULT_CONTAINER;\n      }\n    }\n    return visible && createPortal(\n      <div className={ styles.wrapper }>\n        <div\n          className={ styles.overlay }\n          onClick={ onCancel }\n        />\n        <div\n          className={ styles.container }\n        >\n          { children }\n        </div>\n      </div>,\n      finalMountContainer,\n    )\n  }\n}\n\nexport default Modal;"],"names":["isBrowser","window","undefined","Modal","DEFAULT_CONTAINER","document","getElementById","props","children","visible","onCancel","container","finalMountContainer","body","hasShowWarning","createPortal","React","createElement","className","styles","wrapper","overlay","onClick","PureComponent"],"mappings":";;;;;AAAM,SAAUA,SAAV,GAAmB;SAChB,EAAE,QAAOC,+CAAAA,OAAP,MAAkBC,SAApB;;;;;;;;;;;;ICWIC,KAAb;AAAA;AAAA,8BAAA;;;;;;;;;;;6BAGQ;UACA,CAACH,SAAS,IAAI,OAAO,IAAP;UACZI,iBAAiB,GAAuBC,QAAQ,CAACC,cAAT,CAAwB,WAAxB;wBACyB,KAAKC;UAApEC,QAHJ,eAGIA;UAAUC,OAHd,eAGcA;UAASC,QAHvB,eAGuBA;8CAAUC;UAAAA,SAHjC,sCAG6CP;UAC7CQ,mBAAmB,GAAgBP,QAAQ,CAACQ;;UAC5C,CAACF,WAAW;YACV,CAACP,mBAAmB;cAClB,CAACD,KAAK,CAACW,gBAAgB;AACzBX,YAAAA,KAAK,CAACW,cAAN,GAAuB,IAAvB;;;AAEFF,UAAAA,mBAAmB,GAAGP,QAAQ,CAACQ,IAA/B;AAJF,eAKO;cACD,CAACV,KAAK,CAACW,gBAAgB;AACzBX,YAAAA,KAAK,CAACW,cAAN,GAAuB,IAAvB;;;AAEFF,UAAAA,mBAAmB,GAAGR,iBAAtB;;;;aAGGK,OAAO,IAAIM,YAAY,CAC5BC,KAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AAAKC,QAAAA,SAAS,EAAGC,MAAM,CAACC;AAAxB,OAAA,EACEJ,KAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AACEC,QAAAA,SAAS,EAAGC,MAAM,CAACE,OADrB;AAEEC,QAAAA,OAAO,EAAGZ;AAFZ,OAAA,CADF,EAKEM,KAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AACEC,QAAAA,SAAS,EAAGC,MAAM,CAACR;AADrB,OAAA,EAGIH,QAHJ,CALF,CAD4B,EAY5BI,mBAZ4B;;;;;CArBlC,CAA2BI,KAAK,CAACO,aAAjC;AACSpB,KAAA,CAAAW,cAAA,GAAiB,KAAjB;;;;;"}

+ 35
- 18
eslib/PayPlatformOptions/index.d.ts Ver arquivo

@@ -1,28 +1,45 @@
1 1
 /// <reference types="react" />
2
-type PAY_CHANNEL_VALUE = "PAYPAL_PAYPAL" | "ALI_WEB" | "ALI_WAP" | "WX_WAP" | "WX_NATIVE";
2
+type PAY_CHANNEL_VALUE =
3
+  | "PAYPAL_PAYPAL"
4
+  | "ALI_WEB"
5
+  | "ALI_WAP"
6
+  | "WX_WAP"
7
+  | "WX_NATIVE";
3 8
 type PAY_CHANNEL_CATEGORY_VALUE = "Alipay" | "Wechat" | "Paypal";
4 9
 interface PAY_CHANNEL_TYPE {
5
-    PAYPAL: PAY_CHANNEL_VALUE;
6
-    ALI_WEB: PAY_CHANNEL_VALUE;
7
-    ALI_WAP: PAY_CHANNEL_VALUE;
8
-    WX_WAP: PAY_CHANNEL_VALUE;
9
-    WX_NATIVE: PAY_CHANNEL_VALUE;
10
+  PAYPAL: PAY_CHANNEL_VALUE;
11
+  ALI_WEB: PAY_CHANNEL_VALUE;
12
+  ALI_WAP: PAY_CHANNEL_VALUE;
13
+  WX_WAP: PAY_CHANNEL_VALUE;
14
+  WX_NATIVE: PAY_CHANNEL_VALUE;
10 15
 }
11 16
 interface PAY_CHANNEL_CATEGORY {
12
-    ALI: PAY_CHANNEL_CATEGORY_VALUE;
13
-    WX: PAY_CHANNEL_CATEGORY_VALUE;
14
-    PAYPAL: PAY_CHANNEL_CATEGORY_VALUE;
17
+  ALI: PAY_CHANNEL_CATEGORY_VALUE;
18
+  WX: PAY_CHANNEL_CATEGORY_VALUE;
19
+  PAYPAL: PAY_CHANNEL_CATEGORY_VALUE;
15 20
 }
16 21
 interface Props {
17
-    payChannel: PAY_CHANNEL_VALUE;
18
-    onPayChannelChange: (value: PAY_CHANNEL_VALUE) => void;
19
-    isMobile: boolean;
20
-    size: "small" | "normal" | "large";
21
-    withTitle: boolean;
22
-    titleText?: string;
23
-    locale: "zh" | "en";
22
+  payChannel: PAY_CHANNEL_VALUE;
23
+  onPayChannelChange: (value: PAY_CHANNEL_VALUE) => void;
24
+  isMobile: boolean;
25
+  size: "small" | "normal" | "large";
26
+  withTitle: boolean;
27
+  titleText?: string;
28
+  locale: "zh" | "en";
24 29
 }
25 30
 declare const PAY_CHANNEL: PAY_CHANNEL_TYPE;
26 31
 declare const PAY_CHANNEL_CATEGORY$0: PAY_CHANNEL_CATEGORY;
27
-declare const PayPlatformOptions: ({ payChannel, onPayChannelChange, size, isMobile, withTitle, titleText, locale }: Props) => JSX.Element;
28
-export { PayPlatformOptions as default, PAY_CHANNEL, PAY_CHANNEL_CATEGORY$0 as PAY_CHANNEL_CATEGORY };
32
+declare const PayPlatformOptions: ({
33
+  payChannel,
34
+  onPayChannelChange,
35
+  size,
36
+  isMobile,
37
+  withTitle,
38
+  titleText,
39
+  locale
40
+}: Props) => JSX.Element;
41
+export {
42
+  PayPlatformOptions as default,
43
+  PAY_CHANNEL,
44
+  PAY_CHANNEL_CATEGORY$0 as PAY_CHANNEL_CATEGORY
45
+};

+ 223
- 140
eslib/PayPlatformOptions/index.js
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 1
- 1
eslib/PayPlatformOptions/index.js.map
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 18
- 18
eslib/Payment/index.js Ver arquivo

@@ -1,19 +1,19 @@
1
-import '../inherits-6cb67931.js';
2
-import 'react';
3
-import 'react-dom';
4
-import '../Modal/index.js';
5
-import '../style-inject.es-1f59c1d0.js';
6
-import '../defineProperty-18999f8e.js';
7
-import '../_commonjsHelpers-97e6d7b1.js';
8
-import '../index-c9837619.js';
9
-import '../utils-6b513b37.js';
10
-export { default as ConsumeListView } from '../ConsumeListView/index.js';
11
-export { default as PayPlatformOptions } from '../PayPlatformOptions/index.js';
12
-import '../slicedToArray-4cd9e6d3.js';
13
-import 'antd';
14
-export { default as PriceOptions } from '../PriceOptions/index.js';
15
-export { default as WaitPayInfoView } from '../WaitPayInfoView/index.js';
16
-export { default as AllocWantedModal } from '../AllocWantedModal/index.js';
17
-export { default as WantedPublishView } from '../WantedPublishView/index.js';
18
-export { default as WantedPublishPopover } from '../WantedPublishPopover/index.js';
1
+import "../inherits-6cb67931.js";
2
+import "react";
3
+import "react-dom";
4
+import "../Modal/index.js";
5
+import "../style-inject.es-1f59c1d0.js";
6
+import "../defineProperty-18999f8e.js";
7
+import "../_commonjsHelpers-97e6d7b1.js";
8
+import "../index-c9837619.js";
9
+import "../utils-6b513b37.js";
10
+export { default as ConsumeListView } from "../ConsumeListView/index.js";
11
+export { default as PayPlatformOptions } from "../PayPlatformOptions/index.js";
12
+import "../slicedToArray-4cd9e6d3.js";
13
+import "antd";
14
+export { default as PriceOptions } from "../PriceOptions/index.js";
15
+export { default as WaitPayInfoView } from "../WaitPayInfoView/index.js";
16
+export { default as AllocWantedModal } from "../AllocWantedModal/index.js";
17
+export { default as WantedPublishView } from "../WantedPublishView/index.js";
18
+export { default as WantedPublishPopover } from "../WantedPublishPopover/index.js";
19 19
 //# sourceMappingURL=index.js.map

+ 33
- 18
eslib/PriceOptions/index.d.ts Ver arquivo

@@ -1,23 +1,38 @@
1 1
 /// <reference types="react" />
2 2
 import React from "react";
3 3
 interface Props {
4
-    rowMode: "single" | "multi";
5
-    price: number;
6
-    onPriceChange: (v: number) => void;
7
-    size: "small" | "normal" | "large";
8
-    focusScroll: boolean;
9
-    withTitle: boolean;
10
-    titleText?: string | JSX.Element[] | JSX.Element;
11
-    inputPlaceholderText?: string;
12
-    priceOptions?: Array<any>;
13
-    priceRender?: Function;
14
-    inputPriceRender?: Function;
15
-    inputSuffix?: string | JSX.Element[] | JSX.Element;
16
-    injectOptions?: {
17
-        priceBtnClass: (isActive: boolean) => any;
18
-        priceInputClass: Function;
19
-    };
20
-    inputRef: React.RefObject<any>;
4
+  rowMode: "single" | "multi";
5
+  price: number;
6
+  onPriceChange: (v: number) => void;
7
+  size: "small" | "normal" | "large";
8
+  focusScroll: boolean;
9
+  withTitle: boolean;
10
+  titleText?: string | JSX.Element[] | JSX.Element;
11
+  inputPlaceholderText?: string;
12
+  priceOptions?: Array<any>;
13
+  priceRender?: Function;
14
+  inputPriceRender?: Function;
15
+  inputSuffix?: string | JSX.Element[] | JSX.Element;
16
+  injectOptions?: {
17
+    priceBtnClass: (isActive: boolean) => any;
18
+    priceInputClass: Function;
19
+  };
20
+  inputRef: React.RefObject<any>;
21 21
 }
22
-declare const PriceOptions: ({ price, onPriceChange, rowMode, size, focusScroll, withTitle, titleText, inputPlaceholderText, priceOptions, priceRender, inputPriceRender, inputSuffix, injectOptions, inputRef }: Props) => JSX.Element;
22
+declare const PriceOptions: ({
23
+  price,
24
+  onPriceChange,
25
+  rowMode,
26
+  size,
27
+  focusScroll,
28
+  withTitle,
29
+  titleText,
30
+  inputPlaceholderText,
31
+  priceOptions,
32
+  priceRender,
33
+  inputPriceRender,
34
+  inputSuffix,
35
+  injectOptions,
36
+  inputRef
37
+}: Props) => JSX.Element;
23 38
 export { PriceOptions as default };

+ 192
- 136
eslib/PriceOptions/index.js Ver arquivo

@@ -1,22 +1,23 @@
1
-import React, { useState } from 'react';
2
-import { s as styleInject } from '../style-inject.es-1f59c1d0.js';
3
-import { _ as _defineProperty } from '../defineProperty-18999f8e.js';
4
-import '../_commonjsHelpers-97e6d7b1.js';
5
-import { c as classnames } from '../index-c9837619.js';
6
-import { e as exportStyleSizeClass } from '../utils-6b513b37.js';
7
-import { _ as _slicedToArray } from '../slicedToArray-4cd9e6d3.js';
8
-import { Input } from 'antd';
9
-
10
-var css = ".PriceOptions_options__ifYbC p {\n  font-size: 14px;\n  font-weight: 400;\n  color: #616a79;\n  margin-bottom: 20px;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx {\n  padding-right: 0;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx .PriceOptions_priceItem__3CPe3 {\n  background: rgba(243, 243, 243, 0.14);\n  border-radius: 4px;\n  border: 1px solid #cfcfcf;\n  font-size: 14px;\n  font-weight: 600;\n  color: #616a79;\n  display: inline-block;\n  text-align: center;\n  vertical-align: top;\n  height: 30px;\n  width: 70px;\n  line-height: 30px;\n  cursor: pointer;\n  margin: 6px;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx .PriceOptions_priceItem__3CPe3.PriceOptions_active__154by {\n  background: rgba(255, 50, 102, 0.1);\n  border-radius: 4px;\n  border: 1px solid #ff3266;\n  color: #616a79;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx .PriceOptions_priceInput__2JFc0 {\n  display: inline-block;\n  min-width: 70px;\n  height: 72px;\n  width: auto;\n  margin: 6px;\n  text-align: center;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx button {\n  border-top-left-radius: 0;\n  border-bottom-left-radius: 0;\n  height: 30px;\n  width: 50px;\n  vertical-align: top;\n  padding: 0 5px;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx .PriceOptions_rate__17U-9 {\n  margin-left: 10px;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx .PriceOptions_rate__17U-9 i {\n  margin-right: 5px;\n  color: #1790FF;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z p {\n  font-size: 14px;\n  font-weight: 400;\n  color: #616a79;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z .PriceOptions_infoItem__246mx {\n  padding-right: 0;\n  display: flex;\n  flex-direction: column;\n  justify-content: center;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z .PriceOptions_infoItem__246mx .PriceOptions_priceBtn__1UaE8 {\n  display: flex;\n  justify-content: space-between;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z .PriceOptions_infoItem__246mx .PriceOptions_priceItem__3CPe3 {\n  display: inline-block;\n  background-color: #fff;\n  border-radius: 4px;\n  border: 1px solid #cfcfcf;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z .PriceOptions_infoItem__246mx .PriceOptions_priceItem__3CPe3.PriceOptions_active__154by {\n  background-color: #fff;\n  color: #FF3266FF;\n  border: 1px solid #ff3266;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z .PriceOptions_infoItem__246mx .PriceOptions_priceInput__2JFc0 {\n  width: 222px;\n  width: auto;\n}\n";
1
+import React, { useState } from "react";
2
+import { s as styleInject } from "../style-inject.es-1f59c1d0.js";
3
+import { _ as _defineProperty } from "../defineProperty-18999f8e.js";
4
+import "../_commonjsHelpers-97e6d7b1.js";
5
+import { c as classnames } from "../index-c9837619.js";
6
+import { e as exportStyleSizeClass } from "../utils-6b513b37.js";
7
+import { _ as _slicedToArray } from "../slicedToArray-4cd9e6d3.js";
8
+import { Input } from "antd";
9
+
10
+var css =
11
+  ".PriceOptions_options__ifYbC p {\n  font-size: 14px;\n  font-weight: 400;\n  color: #616a79;\n  margin-bottom: 20px;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx {\n  padding-right: 0;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx .PriceOptions_priceItem__3CPe3 {\n  background: rgba(243, 243, 243, 0.14);\n  border-radius: 4px;\n  border: 1px solid #cfcfcf;\n  font-size: 14px;\n  font-weight: 600;\n  color: #616a79;\n  display: inline-block;\n  text-align: center;\n  vertical-align: top;\n  height: 30px;\n  width: 70px;\n  line-height: 30px;\n  cursor: pointer;\n  margin: 6px;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx .PriceOptions_priceItem__3CPe3.PriceOptions_active__154by {\n  background: rgba(255, 50, 102, 0.1);\n  border-radius: 4px;\n  border: 1px solid #ff3266;\n  color: #616a79;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx .PriceOptions_priceInput__2JFc0 {\n  display: inline-block;\n  min-width: 70px;\n  height: 72px;\n  width: auto;\n  margin: 6px;\n  text-align: center;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx button {\n  border-top-left-radius: 0;\n  border-bottom-left-radius: 0;\n  height: 30px;\n  width: 50px;\n  vertical-align: top;\n  padding: 0 5px;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx .PriceOptions_rate__17U-9 {\n  margin-left: 10px;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx .PriceOptions_rate__17U-9 i {\n  margin-right: 5px;\n  color: #1790FF;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z p {\n  font-size: 14px;\n  font-weight: 400;\n  color: #616a79;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z .PriceOptions_infoItem__246mx {\n  padding-right: 0;\n  display: flex;\n  flex-direction: column;\n  justify-content: center;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z .PriceOptions_infoItem__246mx .PriceOptions_priceBtn__1UaE8 {\n  display: flex;\n  justify-content: space-between;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z .PriceOptions_infoItem__246mx .PriceOptions_priceItem__3CPe3 {\n  display: inline-block;\n  background-color: #fff;\n  border-radius: 4px;\n  border: 1px solid #cfcfcf;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z .PriceOptions_infoItem__246mx .PriceOptions_priceItem__3CPe3.PriceOptions_active__154by {\n  background-color: #fff;\n  color: #FF3266FF;\n  border: 1px solid #ff3266;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z .PriceOptions_infoItem__246mx .PriceOptions_priceInput__2JFc0 {\n  width: 222px;\n  width: auto;\n}\n";
11 12
 var styles = {
12
-  "options": "PriceOptions_options__ifYbC",
13
-  "infoItem": "PriceOptions_infoItem__246mx",
14
-  "priceItem": "PriceOptions_priceItem__3CPe3",
15
-  "active": "PriceOptions_active__154by",
16
-  "priceInput": "PriceOptions_priceInput__2JFc0",
17
-  "rate": "PriceOptions_rate__17U-9",
18
-  "multi": "PriceOptions_multi__2fM8z",
19
-  "priceBtn": "PriceOptions_priceBtn__1UaE8"
13
+  options: "PriceOptions_options__ifYbC",
14
+  infoItem: "PriceOptions_infoItem__246mx",
15
+  priceItem: "PriceOptions_priceItem__3CPe3",
16
+  active: "PriceOptions_active__154by",
17
+  priceInput: "PriceOptions_priceInput__2JFc0",
18
+  rate: "PriceOptions_rate__17U-9",
19
+  multi: "PriceOptions_multi__2fM8z",
20
+  priceBtn: "PriceOptions_priceBtn__1UaE8"
20 21
 };
21 22
 styleInject(css);
22 23
 
@@ -25,9 +26,10 @@ function ownKeys(object, enumerableOnly) {
25 26
 
26 27
   if (Object.getOwnPropertySymbols) {
27 28
     var symbols = Object.getOwnPropertySymbols(object);
28
-    if (enumerableOnly) symbols = symbols.filter(function (sym) {
29
-      return Object.getOwnPropertyDescriptor(object, sym).enumerable;
30
-    });
29
+    if (enumerableOnly)
30
+      symbols = symbols.filter(function(sym) {
31
+        return Object.getOwnPropertyDescriptor(object, sym).enumerable;
32
+      });
31 33
     keys.push.apply(keys, symbols);
32 34
   }
33 35
 
@@ -39,14 +41,18 @@ function _objectSpread(target) {
39 41
     var source = arguments[i] != null ? arguments[i] : {};
40 42
 
41 43
     if (i % 2) {
42
-      ownKeys(Object(source), true).forEach(function (key) {
44
+      ownKeys(Object(source), true).forEach(function(key) {
43 45
         _defineProperty(target, key, source[key]);
44 46
       });
45 47
     } else if (Object.getOwnPropertyDescriptors) {
46 48
       Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
47 49
     } else {
48
-      ownKeys(Object(source)).forEach(function (key) {
49
-        Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
50
+      ownKeys(Object(source)).forEach(function(key) {
51
+        Object.defineProperty(
52
+          target,
53
+          key,
54
+          Object.getOwnPropertyDescriptor(source, key)
55
+        );
50 56
       });
51 57
     }
52 58
   }
@@ -56,122 +62,172 @@ function _objectSpread(target) {
56 62
 
57 63
 var PriceOptions = function PriceOptions(_ref) {
58 64
   var price = _ref.price,
59
-      onPriceChange = _ref.onPriceChange,
60
-      _ref$rowMode = _ref.rowMode,
61
-      rowMode = _ref$rowMode === void 0 ? "single" : _ref$rowMode,
62
-      _ref$size = _ref.size,
63
-      size = _ref$size === void 0 ? "normal" : _ref$size,
64
-      _ref$focusScroll = _ref.focusScroll,
65
-      focusScroll = _ref$focusScroll === void 0 ? true : _ref$focusScroll,
66
-      _ref$withTitle = _ref.withTitle,
67
-      withTitle = _ref$withTitle === void 0 ? true : _ref$withTitle,
68
-      _ref$titleText = _ref.titleText,
69
-      titleText = _ref$titleText === void 0 ? "Price" : _ref$titleText,
70
-      _ref$inputPlaceholder = _ref.inputPlaceholderText,
71
-      inputPlaceholderText = _ref$inputPlaceholder === void 0 ? "Others" : _ref$inputPlaceholder,
72
-      _ref$priceOptions = _ref.priceOptions,
73
-      priceOptions = _ref$priceOptions === void 0 ? [100, 600, 800] : _ref$priceOptions,
74
-      _ref$priceRender = _ref.priceRender,
75
-      priceRender = _ref$priceRender === void 0 ? function (i) {
76
-    return i / 100;
77
-  } : _ref$priceRender,
78
-      _ref$inputPriceRender = _ref.inputPriceRender,
79
-      inputPriceRender = _ref$inputPriceRender === void 0 ? function (i) {
80
-    return i ? i / 100 : "";
81
-  } : _ref$inputPriceRender,
82
-      _ref$inputSuffix = _ref.inputSuffix,
83
-      inputSuffix = _ref$inputSuffix === void 0 ? "¥" : _ref$inputSuffix,
84
-      _ref$injectOptions = _ref.injectOptions,
85
-      injectOptions = _ref$injectOptions === void 0 ? {
86
-    priceBtnClass: function priceBtnClass() {
87
-      return undefined;
88
-    },
89
-    priceInputClass: function priceInputClass() {
90
-      return undefined;
91
-    }
92
-  } : _ref$injectOptions,
93
-      inputRef = _ref.inputRef;
65
+    onPriceChange = _ref.onPriceChange,
66
+    _ref$rowMode = _ref.rowMode,
67
+    rowMode = _ref$rowMode === void 0 ? "single" : _ref$rowMode,
68
+    _ref$size = _ref.size,
69
+    size = _ref$size === void 0 ? "normal" : _ref$size,
70
+    _ref$focusScroll = _ref.focusScroll,
71
+    focusScroll = _ref$focusScroll === void 0 ? true : _ref$focusScroll,
72
+    _ref$withTitle = _ref.withTitle,
73
+    withTitle = _ref$withTitle === void 0 ? true : _ref$withTitle,
74
+    _ref$titleText = _ref.titleText,
75
+    titleText = _ref$titleText === void 0 ? "Price" : _ref$titleText,
76
+    _ref$inputPlaceholder = _ref.inputPlaceholderText,
77
+    inputPlaceholderText =
78
+      _ref$inputPlaceholder === void 0 ? "Others" : _ref$inputPlaceholder,
79
+    _ref$priceOptions = _ref.priceOptions,
80
+    priceOptions =
81
+      _ref$priceOptions === void 0 ? [100, 600, 800] : _ref$priceOptions,
82
+    _ref$priceRender = _ref.priceRender,
83
+    priceRender =
84
+      _ref$priceRender === void 0
85
+        ? function(i) {
86
+            return i / 100;
87
+          }
88
+        : _ref$priceRender,
89
+    _ref$inputPriceRender = _ref.inputPriceRender,
90
+    inputPriceRender =
91
+      _ref$inputPriceRender === void 0
92
+        ? function(i) {
93
+            return i ? i / 100 : "";
94
+          }
95
+        : _ref$inputPriceRender,
96
+    _ref$inputSuffix = _ref.inputSuffix,
97
+    inputSuffix = _ref$inputSuffix === void 0 ? "¥" : _ref$inputSuffix,
98
+    _ref$injectOptions = _ref.injectOptions,
99
+    injectOptions =
100
+      _ref$injectOptions === void 0
101
+        ? {
102
+            priceBtnClass: function priceBtnClass() {
103
+              return undefined;
104
+            },
105
+            priceInputClass: function priceInputClass() {
106
+              return undefined;
107
+            }
108
+          }
109
+        : _ref$injectOptions,
110
+    inputRef = _ref.inputRef;
94 111
   var defaultOptions = priceOptions;
95 112
 
96 113
   var _useState = useState(false),
97
-      _useState2 = _slicedToArray(_useState, 2),
98
-      inputStatus = _useState2[0],
99
-      setInputStatus = _useState2[1];
100
-
101
-  var _useState3 = useState(''),
102
-      _useState4 = _slicedToArray(_useState3, 2),
103
-      inputPrice = _useState4[0],
104
-      setInputPrice = _useState4[1];
105
-
106
-  return React.createElement("div", {
107
-    className: classnames(styles.options, _objectSpread(_defineProperty({}, styles.multi, rowMode === "multi"), exportStyleSizeClass(styles, size)))
108
-  }, withTitle ? titleText || null : null, React.createElement("div", {
109
-    className: styles.infoItem
110
-  }, React.createElement("span", {
111
-    className: styles.priceBtn
112
-  }, defaultOptions.map(function (item) {
113
-    var _objectSpread3;
114
-
115
-    return React.createElement("span", {
116
-      className: classnames(_objectSpread((_objectSpread3 = {}, _defineProperty(_objectSpread3, styles.priceItem, true), _defineProperty(_objectSpread3, styles.active, price === item && !inputStatus), _objectSpread3), injectOptions.priceBtnClass(price === item && !inputStatus))),
117
-      key: item,
118
-      onClick: function onClick() {
119
-        onPriceChange(item);
120
-        setInputStatus(false);
121
-      }
122
-    }, priceRender(item));
123
-  })), React.createElement(Input, {
124
-    ref: inputRef,
125
-    className: classnames(styles.priceInput, _objectSpread({}, injectOptions.priceInputClass())),
126
-    onMouseEnter: function onMouseEnter() {
127
-      if (inputStatus && inputRef && inputRef.current) {
128
-        inputRef.current.focus();
129
-        inputRef.current.select();
130
-      }
131
-    },
132
-    suffix: inputSuffix,
133
-    value: inputStatus ? inputPriceRender(inputPrice) : "",
134
-    placeholder: inputPlaceholderText,
135
-    onChange: function onChange(e) {
136
-      var n = +e.target.value;
137
-
138
-      if (Number.isNaN(n)) {
139
-        return;
140
-      }
141
-
142
-      setInputPrice("".concat(n * 100));
143
-      onPriceChange(n * 100);
114
+    _useState2 = _slicedToArray(_useState, 2),
115
+    inputStatus = _useState2[0],
116
+    setInputStatus = _useState2[1];
117
+
118
+  var _useState3 = useState(""),
119
+    _useState4 = _slicedToArray(_useState3, 2),
120
+    inputPrice = _useState4[0],
121
+    setInputPrice = _useState4[1];
122
+
123
+  return React.createElement(
124
+    "div",
125
+    {
126
+      className: classnames(
127
+        styles.options,
128
+        _objectSpread(
129
+          _defineProperty({}, styles.multi, rowMode === "multi"),
130
+          exportStyleSizeClass(styles, size)
131
+        )
132
+      )
144 133
     },
145
-    onClick: function onClick(e) {
146
-      if (!inputStatus) {
147
-        setInputPrice('');
148
-        setInputStatus(true);
149
-      }
150
-    },
151
-    onFocus: function onFocus(e) {
152
-      e.target.placeholder = "";
153
-
154
-      if (inputStatus) {
155
-        setInputPrice("".concat(price));
156
-      } else {
157
-        setInputPrice('');
158
-        setInputStatus(true);
159
-      }
160
-
161
-      if (focusScroll) {
162
-        e.target.scrollIntoView();
163
-      }
164
-    },
165
-    onBlur: function onBlur(e) {
166
-      e.target.placeholder = inputPlaceholderText;
167
-
168
-      if (inputPrice) {
169
-        setInputStatus(true);
170
-      } else {
171
-        setInputStatus(false);
172
-      }
173
-    }
174
-  })));
134
+    withTitle ? titleText || null : null,
135
+    React.createElement(
136
+      "div",
137
+      {
138
+        className: styles.infoItem
139
+      },
140
+      React.createElement(
141
+        "span",
142
+        {
143
+          className: styles.priceBtn
144
+        },
145
+        defaultOptions.map(function(item) {
146
+          var _objectSpread3;
147
+
148
+          return React.createElement(
149
+            "span",
150
+            {
151
+              className: classnames(
152
+                _objectSpread(
153
+                  ((_objectSpread3 = {}),
154
+                  _defineProperty(_objectSpread3, styles.priceItem, true),
155
+                  _defineProperty(
156
+                    _objectSpread3,
157
+                    styles.active,
158
+                    price === item && !inputStatus
159
+                  ),
160
+                  _objectSpread3),
161
+                  injectOptions.priceBtnClass(price === item && !inputStatus)
162
+                )
163
+              ),
164
+              key: item,
165
+              onClick: function onClick() {
166
+                onPriceChange(item);
167
+                setInputStatus(false);
168
+              }
169
+            },
170
+            priceRender(item)
171
+          );
172
+        })
173
+      ),
174
+      React.createElement(Input, {
175
+        ref: inputRef,
176
+        className: classnames(
177
+          styles.priceInput,
178
+          _objectSpread({}, injectOptions.priceInputClass())
179
+        ),
180
+        onMouseEnter: function onMouseEnter() {
181
+          if (inputStatus && inputRef && inputRef.current) {
182
+            inputRef.current.focus();
183
+            inputRef.current.select();
184
+          }
185
+        },
186
+        suffix: inputSuffix,
187
+        value: inputStatus ? inputPriceRender(inputPrice) : "",
188
+        placeholder: inputPlaceholderText,
189
+        onChange: function onChange(e) {
190
+          var n = +e.target.value;
191
+
192
+          if (Number.isNaN(n)) {
193
+            return;
194
+          }
195
+
196
+          setInputPrice("".concat(n * 100));
197
+          onPriceChange(n * 100);
198
+        },
199
+        onClick: function onClick(e) {
200
+          if (!inputStatus) {
201
+            setInputPrice("");
202
+            setInputStatus(true);
203
+          }
204
+        },
205
+        onFocus: function onFocus(e) {
206
+          e.target.placeholder = "";
207
+
208
+          if (inputStatus) {
209
+            setInputPrice("".concat(price));
210
+          } else {
211
+            setInputPrice("");
212
+            setInputStatus(true);
213
+          }
214
+
215
+          if (focusScroll) {
216
+            e.target.scrollIntoView();
217
+          }
218
+        },
219
+        onBlur: function onBlur(e) {
220
+          e.target.placeholder = inputPlaceholderText;
221
+
222
+          if (inputPrice) {
223
+            setInputStatus(true);
224
+          } else {
225
+            setInputStatus(false);
226
+          }
227
+        }
228
+      })
229
+    )
230
+  );
175 231
 };
176 232
 
177 233
 export default PriceOptions;

+ 1
- 1
eslib/PriceOptions/index.js.map
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 8
- 8
eslib/WaitPayInfoView/index.d.ts Ver arquivo

@@ -1,14 +1,14 @@
1 1
 /// <reference types="react" />
2
-import { Component } from 'react';
2
+import { Component } from "react";
3 3
 interface Props {
4
-    onClickPayed?: Function;
5
-    onClickProblem?: Function;
4
+  onClickPayed?: Function;
5
+  onClickProblem?: Function;
6 6
 }
7 7
 declare class WaitPayInfoView extends Component<Props, {}> {
8
-    static defaultProps: {
9
-        onClickPayed: () => void;
10
-        onClickProblem: () => void;
11
-    };
12
-    render(): JSX.Element;
8
+  static defaultProps: {
9
+    onClickPayed: () => void;
10
+    onClickProblem: () => void;
11
+  };
12
+  render(): JSX.Element;
13 13
 }
14 14
 export { WaitPayInfoView as default, WaitPayInfoView };

+ 100
- 52
eslib/WaitPayInfoView/index.js Ver arquivo

@@ -1,19 +1,31 @@
1
-import { a as _inherits, b as _classCallCheck, c as _possibleConstructorReturn, d as _getPrototypeOf, e as _createClass } from '../inherits-6cb67931.js';
2
-import React, { Component } from 'react';
3
-import { s as styleInject } from '../style-inject.es-1f59c1d0.js';
4
-import '../_commonjsHelpers-97e6d7b1.js';
5
-import { c as classnames } from '../index-c9837619.js';
1
+import {
2
+  a as _inherits,
3
+  b as _classCallCheck,
4
+  c as _possibleConstructorReturn,
5
+  d as _getPrototypeOf,
6
+  e as _createClass
7
+} from "../inherits-6cb67931.js";
8
+import React, { Component } from "react";
9
+import { s as styleInject } from "../style-inject.es-1f59c1d0.js";
10
+import "../_commonjsHelpers-97e6d7b1.js";
11
+import { c as classnames } from "../index-c9837619.js";
6 12
 
7
-var css = ".WaitPayInfoView_waitingContainer__3pU2F {\n  display: flex;\n  flex-direction: column;\n  justify-content: center;\n  align-items: center;\n}\n";
13
+var css =
14
+  ".WaitPayInfoView_waitingContainer__3pU2F {\n  display: flex;\n  flex-direction: column;\n  justify-content: center;\n  align-items: center;\n}\n";
8 15
 var styles = {
9
-  "waitingContainer": "WaitPayInfoView_waitingContainer__3pU2F"
16
+  waitingContainer: "WaitPayInfoView_waitingContainer__3pU2F"
10 17
 };
11 18
 styleInject(css);
12 19
 
13
-var img = "data:image/svg+xml,%3c%3fxml version='1.0' encoding='UTF-8'%3f%3e%3csvg width='48px' height='43px' viewBox='0 0 48 43' version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3e %3c!-- Generator: Sketch 50.2 (55047) - http://www.bohemiancoding.com/sketch --%3e %3ctitle%3ekcxq_popovers_icon_tanhao%3c/title%3e %3cdesc%3eCreated with Sketch.%3c/desc%3e %3cdefs%3e%3c/defs%3e %3cg id='Page-1' stroke='none' stroke-width='1' fill='none' fill-rule='evenodd'%3e %3cg id='%e5%8f%a6%e5%ae%a2%e7%bd%91_%e7%9b%b4%e6%92%ad%e8%af%be_%e8%af%be%e7%a8%8b%e4%bb%8b%e7%bb%8d%e8%af%a6%e6%83%85_%e8%b4%ad%e4%b9%b0%e6%8f%90%e7%a4%ba%e5%bc%b9%e7%aa%97' transform='translate(-936.000000%2c -190.000000)' fill-rule='nonzero'%3e %3cg id='Group-22' transform='translate(690.000000%2c 110.000000)'%3e %3cg id='kcxq_popovers_icon_tanhao' transform='translate(246.000000%2c 80.000000)'%3e %3cpath d='M48%2c21.5 C48%2c33.3736626 38.3645756%2c43 26.4797048%2c43 C21.1306273%2c43 17.0391144%2c42.1506173 13.2841328%2c38.9300412 C11.8140221%2c37.6736626 1.700369%2c43.2123457 0.177121771%2c39.2839506 C-1.06273063%2c36.0987654 5.95129151%2c29.2506173 5.31365314%2c27.0740741 C4.76457565%2c25.1806584 4.95940959%2c23.5703704 4.95940959%2c21.5 C4.95940959%2c9.62633745 14.5948339%2c0 26.4797048%2c0 C38.3645756%2c0 48%2c9.62633745 48%2c21.5 Z' id='Shape' fill='%231790FF'%3e%3c/path%3e %3cg id='Group' transform='translate(23.848708%2c 8.193416)' fill='white'%3e %3cpath d='M2.5%2c27.4971098 C1.13235294%2c27.4971098 0%2c26.3794628 0%2c24.9971098 C0%2c23.6147569 1.13235294%2c22.4971098 2.5%2c22.4971098 C3.86764706%2c22.4971098 5%2c23.6147569 5%2c24.9971098 C5%2c26.3794628 3.86764706%2c27.4971098 2.5%2c27.4971098 Z M2.5%2c19.4219653 C1.13235294%2c19.4219653 0%2c18.1919075 0%2c16.6705202 L0%2c2.75144509 C0%2c1.24624277 1.13235294%2c0 2.5%2c0 C3.86764706%2c0 5%2c1.2300578 5%2c2.75144509 L5%2c16.6705202 C5%2c18.1919075 3.86764706%2c19.4219653 2.5%2c19.4219653 Z' id='Shape'%3e%3c/path%3e %3c/g%3e %3c/g%3e %3c/g%3e %3c/g%3e %3c/g%3e%3c/svg%3e";
20
+var img =
21
+  "data:image/svg+xml,%3c%3fxml version='1.0' encoding='UTF-8'%3f%3e%3csvg width='48px' height='43px' viewBox='0 0 48 43' version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3e %3c!-- Generator: Sketch 50.2 (55047) - http://www.bohemiancoding.com/sketch --%3e %3ctitle%3ekcxq_popovers_icon_tanhao%3c/title%3e %3cdesc%3eCreated with Sketch.%3c/desc%3e %3cdefs%3e%3c/defs%3e %3cg id='Page-1' stroke='none' stroke-width='1' fill='none' fill-rule='evenodd'%3e %3cg id='%e5%8f%a6%e5%ae%a2%e7%bd%91_%e7%9b%b4%e6%92%ad%e8%af%be_%e8%af%be%e7%a8%8b%e4%bb%8b%e7%bb%8d%e8%af%a6%e6%83%85_%e8%b4%ad%e4%b9%b0%e6%8f%90%e7%a4%ba%e5%bc%b9%e7%aa%97' transform='translate(-936.000000%2c -190.000000)' fill-rule='nonzero'%3e %3cg id='Group-22' transform='translate(690.000000%2c 110.000000)'%3e %3cg id='kcxq_popovers_icon_tanhao' transform='translate(246.000000%2c 80.000000)'%3e %3cpath d='M48%2c21.5 C48%2c33.3736626 38.3645756%2c43 26.4797048%2c43 C21.1306273%2c43 17.0391144%2c42.1506173 13.2841328%2c38.9300412 C11.8140221%2c37.6736626 1.700369%2c43.2123457 0.177121771%2c39.2839506 C-1.06273063%2c36.0987654 5.95129151%2c29.2506173 5.31365314%2c27.0740741 C4.76457565%2c25.1806584 4.95940959%2c23.5703704 4.95940959%2c21.5 C4.95940959%2c9.62633745 14.5948339%2c0 26.4797048%2c0 C38.3645756%2c0 48%2c9.62633745 48%2c21.5 Z' id='Shape' fill='%231790FF'%3e%3c/path%3e %3cg id='Group' transform='translate(23.848708%2c 8.193416)' fill='white'%3e %3cpath d='M2.5%2c27.4971098 C1.13235294%2c27.4971098 0%2c26.3794628 0%2c24.9971098 C0%2c23.6147569 1.13235294%2c22.4971098 2.5%2c22.4971098 C3.86764706%2c22.4971098 5%2c23.6147569 5%2c24.9971098 C5%2c26.3794628 3.86764706%2c27.4971098 2.5%2c27.4971098 Z M2.5%2c19.4219653 C1.13235294%2c19.4219653 0%2c18.1919075 0%2c16.6705202 L0%2c2.75144509 C0%2c1.24624277 1.13235294%2c0 2.5%2c0 C3.86764706%2c0 5%2c1.2300578 5%2c2.75144509 L5%2c16.6705202 C5%2c18.1919075 3.86764706%2c19.4219653 2.5%2c19.4219653 Z' id='Shape'%3e%3c/path%3e %3c/g%3e %3c/g%3e %3c/g%3e %3c/g%3e %3c/g%3e%3c/svg%3e";
14 22
 
15 23
 var Button = function Button() {
16
-  for (var _len = arguments.length, props = new Array(_len), _key = 0; _key < _len; _key++) {
24
+  for (
25
+    var _len = arguments.length, props = new Array(_len), _key = 0;
26
+    _key < _len;
27
+    _key++
28
+  ) {
17 29
     props[_key] = arguments[_key];
18 30
   }
19 31
 
@@ -21,54 +33,90 @@ var Button = function Button() {
21 33
 };
22 34
 
23 35
 var WaitPayInfoView =
24
-/*#__PURE__*/
25
-function (_Component) {
26
-  _inherits(WaitPayInfoView, _Component);
36
+  /*#__PURE__*/
37
+  (function(_Component) {
38
+    _inherits(WaitPayInfoView, _Component);
27 39
 
28
-  function WaitPayInfoView() {
29
-    _classCallCheck(this, WaitPayInfoView);
40
+    function WaitPayInfoView() {
41
+      _classCallCheck(this, WaitPayInfoView);
30 42
 
31
-    return _possibleConstructorReturn(this, _getPrototypeOf(WaitPayInfoView).apply(this, arguments));
32
-  }
43
+      return _possibleConstructorReturn(
44
+        this,
45
+        _getPrototypeOf(WaitPayInfoView).apply(this, arguments)
46
+      );
47
+    }
33 48
 
34
-  _createClass(WaitPayInfoView, [{
35
-    key: "render",
36
-    value: function render() {
37
-      var _this$props = this.props,
38
-          onClickPayed = _this$props.onClickPayed,
39
-          onClickProblem = _this$props.onClickProblem;
40
-      return React.createElement("div", {
41
-        className: styles.waitingContainer
42
-      }, React.createElement("div", {
43
-        className: styles.infoIconImgContainer
44
-      }, React.createElement("img", {
45
-        src: img,
46
-        alt: "info label icon"
47
-      })), React.createElement("div", null, React.createElement("div", {
48
-        className: styles.pay_text
49
-      }, "live.course_info.pay.notification"), React.createElement("div", {
50
-        className: styles.btn_row
51
-      }, React.createElement(Button, {
52
-        className: classnames(styles.pay_btn, styles.btn_default),
53
-        size: "small",
54
-        onClick: function onClick() {
55
-          onClickPayed && onClickPayed();
49
+    _createClass(WaitPayInfoView, [
50
+      {
51
+        key: "render",
52
+        value: function render() {
53
+          var _this$props = this.props,
54
+            onClickPayed = _this$props.onClickPayed,
55
+            onClickProblem = _this$props.onClickProblem;
56
+          return React.createElement(
57
+            "div",
58
+            {
59
+              className: styles.waitingContainer
60
+            },
61
+            React.createElement(
62
+              "div",
63
+              {
64
+                className: styles.infoIconImgContainer
65
+              },
66
+              React.createElement("img", {
67
+                src: img,
68
+                alt: "info label icon"
69
+              })
70
+            ),
71
+            React.createElement(
72
+              "div",
73
+              null,
74
+              React.createElement(
75
+                "div",
76
+                {
77
+                  className: styles.pay_text
78
+                },
79
+                "live.course_info.pay.notification"
80
+              ),
81
+              React.createElement(
82
+                "div",
83
+                {
84
+                  className: styles.btn_row
85
+                },
86
+                React.createElement(
87
+                  Button,
88
+                  {
89
+                    className: classnames(styles.pay_btn, styles.btn_default),
90
+                    size: "small",
91
+                    onClick: function onClick() {
92
+                      onClickPayed && onClickPayed();
93
+                    }
94
+                  },
95
+                  "live.course_info.pay.payed"
96
+                ),
97
+                React.createElement(
98
+                  Button,
99
+                  {
100
+                    className: styles.btn_default,
101
+                    size: "small",
102
+                    style: {
103
+                      marginLeft: "16px"
104
+                    },
105
+                    onClick: function onClick() {
106
+                      onClickProblem && onClickProblem();
107
+                    }
108
+                  },
109
+                  "live.course_info.pay.help"
110
+                )
111
+              )
112
+            )
113
+          );
56 114
         }
57
-      }, "live.course_info.pay.payed"), React.createElement(Button, {
58
-        className: styles.btn_default,
59
-        size: "small",
60
-        style: {
61
-          marginLeft: '16px'
62
-        },
63
-        onClick: function onClick() {
64
-          onClickProblem && onClickProblem();
65
-        }
66
-      }, "live.course_info.pay.help"))));
67
-    }
68
-  }]);
115
+      }
116
+    ]);
69 117
 
70
-  return WaitPayInfoView;
71
-}(Component);
118
+    return WaitPayInfoView;
119
+  })(Component);
72 120
 WaitPayInfoView.defaultProps = {
73 121
   onClickPayed: function onClickPayed() {
74 122
     console.log("onClickPayed");

+ 1
- 1
eslib/WaitPayInfoView/index.js.map
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 27
- 0
eslib/WantedPublishModal/index.d.ts Ver arquivo

@@ -0,0 +1,27 @@
1
+/// <reference types="react" />
2
+import { Component } from "react";
3
+import { ModalProps } from "../Modal/index";
4
+interface WantedPublishModalProps {
5
+  modalConfig?: ModalProps;
6
+  handleConfirm?: Function;
7
+}
8
+interface WantedPublishModalState {
9
+  modalVisible: boolean;
10
+  current_wanted: number | string | null;
11
+}
12
+declare class WantedPublishModal extends Component<
13
+  WantedPublishModalProps,
14
+  WantedPublishModalState
15
+> {
16
+  constructor(props: WantedPublishModalProps);
17
+  handleModalShow: () => void;
18
+  handleClose: () => void;
19
+  handleUpdateCurrentWanted: (
20
+    value: string | number | null,
21
+    afterUpdate?: Function | undefined
22
+  ) => void;
23
+  clearCurrentWanted: (cb: Function) => void;
24
+  renderMain(): JSX.Element;
25
+  render(): JSX.Element;
26
+}
27
+export { WantedPublishModal as default, WantedPublishModal };

+ 164
- 0
eslib/WantedPublishModal/index.js Ver arquivo

@@ -0,0 +1,164 @@
1
+import {
2
+  a as _inherits,
3
+  b as _classCallCheck,
4
+  c as _possibleConstructorReturn,
5
+  d as _getPrototypeOf,
6
+  e as _createClass
7
+} from "../inherits-6cb67931.js";
8
+import React, { Component } from "react";
9
+import "react-dom";
10
+import Modal from "../Modal/index.js";
11
+import { s as styleInject } from "../style-inject.es-1f59c1d0.js";
12
+import "../defineProperty-18999f8e.js";
13
+import "../_commonjsHelpers-97e6d7b1.js";
14
+import "../index-c9837619.js";
15
+import "antd";
16
+import WantedPublishView from "../WantedPublishView/index.js";
17
+
18
+var css =
19
+  ".WantedPublishModal_modalBg__3OlNh {\n  background: white;\n  display: flex;\n  justify-content: center;\n  flex-direction: column;\n  align-items: center;\n  padding: 16px;\n  text-align: center;\n  border-radius: 4px;\n}\n";
20
+var styles = {
21
+  modalBg: "WantedPublishModal_modalBg__3OlNh"
22
+};
23
+styleInject(css);
24
+
25
+var WantedPublishModal =
26
+  /*#__PURE__*/
27
+  (function(_Component) {
28
+    _inherits(WantedPublishModal, _Component);
29
+
30
+    function WantedPublishModal(props) {
31
+      var _this;
32
+
33
+      _classCallCheck(this, WantedPublishModal);
34
+
35
+      _this = _possibleConstructorReturn(
36
+        this,
37
+        _getPrototypeOf(WantedPublishModal).call(this, props)
38
+      );
39
+
40
+      _this.handleModalShow = function() {};
41
+
42
+      _this.handleClose = function() {
43
+        var handleConfirm = _this.props.handleConfirm;
44
+
45
+        if (handleConfirm) {
46
+          _this.handleUpdateCurrentWanted(_this.state.current_wanted, function(
47
+            value
48
+          ) {
49
+            handleConfirm(Number(value).toFixed(2));
50
+          });
51
+        }
52
+
53
+        _this.setState({
54
+          modalVisible: false
55
+        });
56
+      };
57
+
58
+      _this.handleUpdateCurrentWanted = function(value, afterUpdate) {
59
+        if (!value) return;
60
+        var result;
61
+        result = value;
62
+
63
+        if (parseInt("".concat(value), 10) === value) {
64
+          result = Number(value);
65
+        }
66
+
67
+        if (!result) return;
68
+        if (result > 10000) result = 10000;
69
+        if (result < 5) result = 5;
70
+
71
+        _this.setState(
72
+          {
73
+            current_wanted: result
74
+          },
75
+          function() {
76
+            return afterUpdate && afterUpdate(result);
77
+          }
78
+        );
79
+      };
80
+
81
+      _this.clearCurrentWanted = function(cb) {
82
+        _this.setState(
83
+          {
84
+            current_wanted: null
85
+          },
86
+          function() {
87
+            return cb();
88
+          }
89
+        );
90
+      };
91
+
92
+      _this.state = {
93
+        modalVisible: false,
94
+        current_wanted: null
95
+      };
96
+      return _this;
97
+    }
98
+
99
+    _createClass(WantedPublishModal, [
100
+      {
101
+        key: "renderMain",
102
+        value: function renderMain() {
103
+          var _this2 = this;
104
+
105
+          var current_wanted = this.state.current_wanted;
106
+          return React.createElement(WantedPublishView, {
107
+            wrapperClass: styles.modalBg,
108
+            current_wanted: current_wanted,
109
+            InputWantedValueChange: function InputWantedValueChange(v) {
110
+              return _this2.setState({
111
+                current_wanted: v
112
+              });
113
+            },
114
+            InputWantedPressEnter: function InputWantedPressEnter(v) {
115
+              return _this2.handleUpdateCurrentWanted(v, _this2.handleClose);
116
+            },
117
+            InputWantedOnBlur: function InputWantedOnBlur(v) {
118
+              return _this2.handleUpdateCurrentWanted(v);
119
+            },
120
+            InputWantedClear: function InputWantedClear() {
121
+              return _this2.clearCurrentWanted(_this2.handleClose);
122
+            },
123
+            CloseFunction: this.handleClose
124
+          });
125
+        }
126
+      },
127
+      {
128
+        key: "render",
129
+        value: function render() {
130
+          var _this3 = this;
131
+
132
+          return React.createElement(
133
+            React.Fragment,
134
+            null,
135
+            React.createElement(
136
+              "div",
137
+              {
138
+                onClick: function onClick() {
139
+                  return _this3.setState({
140
+                    modalVisible: true
141
+                  });
142
+                }
143
+              },
144
+              this.props.children
145
+            ),
146
+            React.createElement(
147
+              Modal,
148
+              {
149
+                visible: this.state.modalVisible,
150
+                onCancel: this.handleClose
151
+              },
152
+              this.renderMain()
153
+            )
154
+          );
155
+        }
156
+      }
157
+    ]);
158
+
159
+    return WantedPublishModal;
160
+  })(Component);
161
+
162
+export default WantedPublishModal;
163
+export { WantedPublishModal };
164
+//# sourceMappingURL=index.js.map

+ 1
- 0
eslib/WantedPublishModal/index.js.map
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 25
- 14
eslib/WantedPublishPopover/index.d.ts Ver arquivo

@@ -1,20 +1,31 @@
1 1
 /// <reference types="react" />
2
-import React from 'react';
3
-import { PopoverProps } from 'antd/lib/popover';
2
+import React from "react";
3
+import { PopoverProps } from "antd/lib/popover";
4 4
 interface WantedPublishPopoverProp {
5
-    popoverConfig?: PopoverProps;
6
-    handleConfirm?: Function;
5
+  popoverConfig?: PopoverProps;
6
+  handleConfirm?: Function;
7 7
 }
8 8
 interface WantedPublishPopoverState {
9
-    visible: boolean;
10
-    current_wanted: number | string | null;
9
+  visible: boolean;
10
+  current_wanted: number | string | null;
11 11
 }
12
-declare class WantedPublishPopover extends React.Component<WantedPublishPopoverProp, WantedPublishPopoverState> {
13
-    constructor(props: WantedPublishPopoverProp);
14
-    handleClose: () => void;
15
-    clearCurrentWanted: (cb: Function) => void;
16
-    handleUpdateCurrentWanted: (value: string | number | null, afterUpdate?: Function | undefined) => void;
17
-    renderInitView(): JSX.Element;
18
-    render(): JSX.Element;
12
+declare class WantedPublishPopover extends React.Component<
13
+  WantedPublishPopoverProp,
14
+  WantedPublishPopoverState
15
+> {
16
+  constructor(props: WantedPublishPopoverProp);
17
+  handleClose: () => void;
18
+  clearCurrentWanted: (cb: Function) => void;
19
+  handleUpdateCurrentWanted: (
20
+    value: string | number | null,
21
+    afterUpdate?: Function | undefined
22
+  ) => void;
23
+  renderInitView(): JSX.Element;
24
+  render(): JSX.Element;
19 25
 }
20
-export { WantedPublishPopover as default, WantedPublishPopover, WantedPublishPopoverProp, WantedPublishPopoverState };
26
+export {
27
+  WantedPublishPopover as default,
28
+  WantedPublishPopover,
29
+  WantedPublishPopoverProp,
30
+  WantedPublishPopoverState
31
+};

+ 173
- 129
eslib/WantedPublishPopover/index.js Ver arquivo

@@ -1,151 +1,195 @@
1
-import { a as _inherits, b as _classCallCheck, c as _possibleConstructorReturn, d as _getPrototypeOf, e as _createClass } from '../inherits-6cb67931.js';
2
-import React from 'react';
3
-import { s as styleInject } from '../style-inject.es-1f59c1d0.js';
4
-import '../defineProperty-18999f8e.js';
5
-import '../_commonjsHelpers-97e6d7b1.js';
6
-import '../index-c9837619.js';
7
-import { Popover } from 'antd';
8
-import WantedPublishView from '../WantedPublishView/index.js';
9
-
10
-var img = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACYAAAAmCAYAAACoPemuAAAFNElEQVRYR82Yf0jcdRjH33enp1NbTQ3FdKhTY64hTTsURc6keQeSqIPSQJIiMHM3zj8ST/BE/And+c8wmSSMomHl4EaaP2aeuq/R1MwrraEgLVbLXcvpReY847l9v3I7774/LKUHjuN79/k8z+v7+fG8n89Hhv+pyf4F1xEAxwE8BSAIQDAAPwB/AnCwnzsAVgHsSI0jFcwfwEkA8QAiRAYj0BUACwDsIvtALJgcwLMA0tjREevfs90tADcBbAg5EAN2FEAegFAhZyL/3wYwBeB7vvZCYFEAzgIIEBlUSjMCYwA4vXXiA6N1lAuApvGg7DaAL7zB+QILB1DA7rKDguL80shNegbxBkZbv4jd/gcNxfmfYHftbjxvYDR9CYdFxMahDfExm/tcP3mC0RQWHzIUF+5HAGPcgydYPoBn+MCSk5ODm5ubs4qKigadTq8b6rHuFRUVcYmJicf0ev2swAuTOnwC4L7niD0J4FW+zvHx8YEMw+gjIiKOz8zM3MjIyPhwa2vLp9xUV1cntra2VioUCv+WlpYug8EwLwD3HYAbnmApANL5OlZVVZ0wm806hUKhpHbz8/Nfq1Sqns3NzT1wdXV1J41GYwXXdnZ2lklNTb0sAEaK8JEnGKWHSKH1xY2Cn59fILVdXFz8RqVSXdrY2Nid16amptM1NTVvyeVy0laIGV23uJ+SpnJrTAHgTSEo7v/Kyso4k8l0XqlUUoWBpaUlW3p6epfdbn9oMpnO6HS6N+RyOfnE1NTUWFZW1hUx65H1T3I1z4E9AaBULBi1Ky8vj+ns7NQFBASE0PPKysqi1WqdKSsrK5XJZC61sFqtw2q1+jMpfgmK3ocDoymkqZRkJSUlUd3d3ReCgoJI6B+zwcHBzzUazTVJDh81XgJwnQOLY8Vasp+CgoKI3t7ed5VKJSmGy4aGhvrz8vIskp096kDF5TUOjCpR7X4c9fX1nS0sLCQJ27XV1dXbubm5HTabjSpZqfYTgAEOLAzAOake+vv787VaLSVlsh2Hw/EgODiY8iHsdvsdjUbTMT09/UCi3x9oeXJgtLvKpDgYHR0tzMnJoQISOzs7zq6urss9PT0LAwMDF0JDQ6mOw9ra2t38/Hzz5OTkHxJ8k0Lc5MDo+3UArsTJZ3K5HOPj469kZmbmsFDbHR0dH+j1+hl6TklJCRkZGdGFh4fH0PP6+vq94uJi8/DwsNh6/0sAt9y18kUAiXxQ/v7+MoZhXktLS8uidk6n82FbW9ul2trab937JSUlBVmt1vORkZGx9LvD4bhfWlpqtlgsvwm8NykIqcNf7mBUsb7E19FoNJ6qr6+vojbb29t/NzY2vt/Q0ECnnz0WGxsbODEx8U50dLSrhFpeXrYlJCRcFAD7BYBrN7uDkXzQOqOzoU+zWCwarVarNRgMF9vb2+nU49OioqKUDMO8HRIScjQ7O/u9hYUFoV1KZwCbJxg9vwDgjNA6U6vVx8bGxlzliZCFhYX5xcTEHJmbm1sXaEvnzysAtryB0eIvAeAS6EO2caoJuJjeSutTAFyL+xDtdwCkqbsViq9T0mHW/ZsArlLacx8IX2C0AV4G8PQBjxqlh34AP3vG4TvwkihrDhCOTkZ0+KBqYo8JXRHQyKkBnPiPR4524CAAnwlXCIzjOc3e9AhKlogXoCspOnnz5jSxYBSPLlaeB/AcAFfZLNHuAvgKwK9i+kkB4/xRjqP6jXSQhJpPKUi4aYToc08MEF8ek9KfRo675qRv7qqTu+6kVLAv28+I7SuQ1E7/AHTQdDZ7M6+KAAAAAElFTkSuQmCC";
11
-
12
-var css = ".WantedPublishPopover_wantedWrapper__3CrCz {\n  width: 366px;\n  height: 424px;\n  font-size: 18px;\n  text-align: center;\n}\n.WantedPublishPopover_wantedWrapper__3CrCz .WantedPublishPopover_closeBtnWrapper__1KV58 {\n  position: absolute;\n  top: 10px;\n  right: 16px;\n  width: 20px;\n  height: 20px;\n}\n.WantedPublishPopover_wantedWrapper__3CrCz .WantedPublishPopover_closeBtnWrapper__1KV58:focus {\n  outline: none;\n}\n.WantedPublishPopover_wantedWrapper__3CrCz .WantedPublishPopover_closeBtnWrapper__1KV58 > div.WantedPublishPopover_closeBtn__1aBMB {\n  border: none;\n  padding: 0px;\n  margin: 0px;\n  cursor: pointer;\n}\n.WantedPublishPopover_wantedWrapper__3CrCz .WantedPublishPopover_closeBtnWrapper__1KV58 > div.WantedPublishPopover_closeBtn__1aBMB > img {\n  width: 100%;\n}\n";
1
+import {
2
+  a as _inherits,
3
+  b as _classCallCheck,
4
+  c as _possibleConstructorReturn,
5
+  d as _getPrototypeOf,
6
+  e as _createClass
7
+} from "../inherits-6cb67931.js";
8
+import React from "react";
9
+import { s as styleInject } from "../style-inject.es-1f59c1d0.js";
10
+import "../defineProperty-18999f8e.js";
11
+import "../_commonjsHelpers-97e6d7b1.js";
12
+import "../index-c9837619.js";
13
+import { Popover } from "antd";
14
+import WantedPublishView from "../WantedPublishView/index.js";
15
+
16
+var img =
17
+  "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACYAAAAmCAYAAACoPemuAAAFNElEQVRYR82Yf0jcdRjH33enp1NbTQ3FdKhTY64hTTsURc6keQeSqIPSQJIiMHM3zj8ST/BE/And+c8wmSSMomHl4EaaP2aeuq/R1MwrraEgLVbLXcvpReY847l9v3I7774/LKUHjuN79/k8z+v7+fG8n89Hhv+pyf4F1xEAxwE8BSAIQDAAPwB/AnCwnzsAVgHsSI0jFcwfwEkA8QAiRAYj0BUACwDsIvtALJgcwLMA0tjREevfs90tADcBbAg5EAN2FEAegFAhZyL/3wYwBeB7vvZCYFEAzgIIEBlUSjMCYwA4vXXiA6N1lAuApvGg7DaAL7zB+QILB1DA7rKDguL80shNegbxBkZbv4jd/gcNxfmfYHftbjxvYDR9CYdFxMahDfExm/tcP3mC0RQWHzIUF+5HAGPcgydYPoBn+MCSk5ODm5ubs4qKigadTq8b6rHuFRUVcYmJicf0ev2swAuTOnwC4L7niD0J4FW+zvHx8YEMw+gjIiKOz8zM3MjIyPhwa2vLp9xUV1cntra2VioUCv+WlpYug8EwLwD3HYAbnmApANL5OlZVVZ0wm806hUKhpHbz8/Nfq1Sqns3NzT1wdXV1J41GYwXXdnZ2lklNTb0sAEaK8JEnGKWHSKH1xY2Cn59fILVdXFz8RqVSXdrY2Nid16amptM1NTVvyeVy0laIGV23uJ+SpnJrTAHgTSEo7v/Kyso4k8l0XqlUUoWBpaUlW3p6epfdbn9oMpnO6HS6N+RyOfnE1NTUWFZW1hUx65H1T3I1z4E9AaBULBi1Ky8vj+ns7NQFBASE0PPKysqi1WqdKSsrK5XJZC61sFqtw2q1+jMpfgmK3ocDoymkqZRkJSUlUd3d3ReCgoJI6B+zwcHBzzUazTVJDh81XgJwnQOLY8Vasp+CgoKI3t7ed5VKJSmGy4aGhvrz8vIskp096kDF5TUOjCpR7X4c9fX1nS0sLCQJ27XV1dXbubm5HTabjSpZqfYTgAEOLAzAOake+vv787VaLSVlsh2Hw/EgODiY8iHsdvsdjUbTMT09/UCi3x9oeXJgtLvKpDgYHR0tzMnJoQISOzs7zq6urss9PT0LAwMDF0JDQ6mOw9ra2t38/Hzz5OTkHxJ8k0Lc5MDo+3UArsTJZ3K5HOPj469kZmbmsFDbHR0dH+j1+hl6TklJCRkZGdGFh4fH0PP6+vq94uJi8/DwsNh6/0sAt9y18kUAiXxQ/v7+MoZhXktLS8uidk6n82FbW9ul2trab937JSUlBVmt1vORkZGx9LvD4bhfWlpqtlgsvwm8NykIqcNf7mBUsb7E19FoNJ6qr6+vojbb29t/NzY2vt/Q0ECnnz0WGxsbODEx8U50dLSrhFpeXrYlJCRcFAD7BYBrN7uDkXzQOqOzoU+zWCwarVarNRgMF9vb2+nU49OioqKUDMO8HRIScjQ7O/u9hYUFoV1KZwCbJxg9vwDgjNA6U6vVx8bGxlzliZCFhYX5xcTEHJmbm1sXaEvnzysAtryB0eIvAeAS6EO2caoJuJjeSutTAFyL+xDtdwCkqbsViq9T0mHW/ZsArlLacx8IX2C0AV4G8PQBjxqlh34AP3vG4TvwkihrDhCOTkZ0+KBqYo8JXRHQyKkBnPiPR4524CAAnwlXCIzjOc3e9AhKlogXoCspOnnz5jSxYBSPLlaeB/AcAFfZLNHuAvgKwK9i+kkB4/xRjqP6jXSQhJpPKUi4aYToc08MEF8ek9KfRo675qRv7qqTu+6kVLAv28+I7SuQ1E7/AHTQdDZ7M6+KAAAAAElFTkSuQmCC";
18
+
19
+var css =
20
+  ".WantedPublishPopover_wantedWrapper__3CrCz {\n  width: 366px;\n  height: 424px;\n  font-size: 18px;\n  text-align: center;\n}\n.WantedPublishPopover_wantedWrapper__3CrCz .WantedPublishPopover_closeBtnWrapper__1KV58 {\n  position: absolute;\n  top: 10px;\n  right: 16px;\n  width: 20px;\n  height: 20px;\n}\n.WantedPublishPopover_wantedWrapper__3CrCz .WantedPublishPopover_closeBtnWrapper__1KV58:focus {\n  outline: none;\n}\n.WantedPublishPopover_wantedWrapper__3CrCz .WantedPublishPopover_closeBtnWrapper__1KV58 > div.WantedPublishPopover_closeBtn__1aBMB {\n  border: none;\n  padding: 0px;\n  margin: 0px;\n  cursor: pointer;\n}\n.WantedPublishPopover_wantedWrapper__3CrCz .WantedPublishPopover_closeBtnWrapper__1KV58 > div.WantedPublishPopover_closeBtn__1aBMB > img {\n  width: 100%;\n}\n";
13 21
 var styles = {
14
-  "wantedWrapper": "WantedPublishPopover_wantedWrapper__3CrCz",
15
-  "closeBtnWrapper": "WantedPublishPopover_closeBtnWrapper__1KV58",
16
-  "closeBtn": "WantedPublishPopover_closeBtn__1aBMB"
22
+  wantedWrapper: "WantedPublishPopover_wantedWrapper__3CrCz",
23
+  closeBtnWrapper: "WantedPublishPopover_closeBtnWrapper__1KV58",
24
+  closeBtn: "WantedPublishPopover_closeBtn__1aBMB"
17 25
 };
18 26
 styleInject(css);
19 27
 
20 28
 var WantedPublishPopover =
21
-/*#__PURE__*/
22
-function (_React$Component) {
23
-  _inherits(WantedPublishPopover, _React$Component);
29
+  /*#__PURE__*/
30
+  (function(_React$Component) {
31
+    _inherits(WantedPublishPopover, _React$Component);
24 32
 
25
-  function WantedPublishPopover(props) {
26
-    var _this;
33
+    function WantedPublishPopover(props) {
34
+      var _this;
27 35
 
28
-    _classCallCheck(this, WantedPublishPopover);
36
+      _classCallCheck(this, WantedPublishPopover);
29 37
 
30
-    _this = _possibleConstructorReturn(this, _getPrototypeOf(WantedPublishPopover).call(this, props));
38
+      _this = _possibleConstructorReturn(
39
+        this,
40
+        _getPrototypeOf(WantedPublishPopover).call(this, props)
41
+      );
31 42
 
32
-    _this.handleClose = function () {
33
-      var handleConfirm = _this.props.handleConfirm;
43
+      _this.handleClose = function() {
44
+        var handleConfirm = _this.props.handleConfirm;
34 45
 
35
-      if (handleConfirm) {
36
-        _this.handleUpdateCurrentWanted(_this.state.current_wanted, function (value) {
37
-          handleConfirm(Number(value).toFixed(2));
46
+        if (handleConfirm) {
47
+          _this.handleUpdateCurrentWanted(_this.state.current_wanted, function(
48
+            value
49
+          ) {
50
+            handleConfirm(Number(value).toFixed(2));
51
+          });
52
+        }
53
+
54
+        _this.setState({
55
+          visible: false
38 56
         });
39
-      }
57
+      };
58
+
59
+      _this.clearCurrentWanted = function(cb) {
60
+        _this.setState(
61
+          {
62
+            current_wanted: null
63
+          },
64
+          function() {
65
+            return cb();
66
+          }
67
+        );
68
+      };
40 69
 
41
-      _this.setState({
42
-        visible: false
43
-      });
44
-    };
70
+      _this.handleUpdateCurrentWanted = function(value, afterUpdate) {
71
+        if (!value) return;
72
+        var result;
73
+        result = value;
45 74
 
46
-    _this.clearCurrentWanted = function (cb) {
47
-      _this.setState({
48
-        current_wanted: null
49
-      }, function () {
50
-        return cb();
51
-      });
52
-    };
53
-
54
-    _this.handleUpdateCurrentWanted = function (value, afterUpdate) {
55
-      if (!value) return;
56
-      var result;
57
-      result = value;
58
-
59
-      if (parseInt("".concat(value), 10) === value) {
60
-        result = Number(value);
61
-      }
75
+        if (parseInt("".concat(value), 10) === value) {
76
+          result = Number(value);
77
+        }
62 78
 
63
-      if (!result) return;
64
-      if (result > 10000) result = 10000;
65
-      if (result < 5) result = 5;
66
-
67
-      _this.setState({
68
-        current_wanted: result
69
-      }, function () {
70
-        return afterUpdate && afterUpdate(result);
71
-      });
72
-    };
73
-
74
-    _this.state = {
75
-      visible: false,
76
-      current_wanted: null
77
-    };
78
-    return _this;
79
-  }
80
-
81
-  _createClass(WantedPublishPopover, [{
82
-    key: "renderInitView",
83
-    value: function renderInitView() {
84
-      var _this2 = this;
85
-
86
-      var current_wanted = this.state.current_wanted;
87
-      return React.createElement(WantedPublishView, {
88
-        type: "pop",
89
-        current_wanted: current_wanted,
90
-        InputWantedValueChange: function InputWantedValueChange(v) {
91
-          return _this2.setState({
92
-            current_wanted: v
93
-          });
94
-        },
95
-        InputWantedPressEnter: function InputWantedPressEnter(v) {
96
-          return _this2.handleUpdateCurrentWanted(v, _this2.handleClose);
97
-        },
98
-        InputWantedOnBlur: function InputWantedOnBlur(v) {
99
-          return _this2.handleUpdateCurrentWanted(v);
100
-        },
101
-        InputWantedClear: function InputWantedClear() {
102
-          return _this2.clearCurrentWanted(_this2.handleClose);
103
-        },
104
-        CloseFunction: this.handleClose
105
-      });
106
-    }
107
-  }, {
108
-    key: "render",
109
-    value: function render() {
110
-      var _this3 = this;
111
-
112
-      var _this$props = this.props,
113
-          children = _this$props.children,
114
-          _this$props$popoverCo = _this$props.popoverConfig,
115
-          popoverConfig = _this$props$popoverCo === void 0 ? {} : _this$props$popoverCo;
116
-      return React.createElement(Popover, Object.assign({
117
-        placement: "left",
118
-        trigger: "click",
119
-        visible: this.state.visible,
120
-        onVisibleChange: function onVisibleChange(value) {
121
-          if (!value) {
122
-            _this3.handleClose();
79
+        if (!result) return;
80
+        if (result > 10000) result = 10000;
81
+        if (result < 5) result = 5;
82
+
83
+        _this.setState(
84
+          {
85
+            current_wanted: result
86
+          },
87
+          function() {
88
+            return afterUpdate && afterUpdate(result);
123 89
           }
90
+        );
91
+      };
92
+
93
+      _this.state = {
94
+        visible: false,
95
+        current_wanted: null
96
+      };
97
+      return _this;
98
+    }
124 99
 
125
-          _this3.setState({
126
-            visible: value
100
+    _createClass(WantedPublishPopover, [
101
+      {
102
+        key: "renderInitView",
103
+        value: function renderInitView() {
104
+          var _this2 = this;
105
+
106
+          var current_wanted = this.state.current_wanted;
107
+          return React.createElement(WantedPublishView, {
108
+            type: "pop",
109
+            current_wanted: current_wanted,
110
+            InputWantedValueChange: function InputWantedValueChange(v) {
111
+              return _this2.setState({
112
+                current_wanted: v
113
+              });
114
+            },
115
+            InputWantedPressEnter: function InputWantedPressEnter(v) {
116
+              return _this2.handleUpdateCurrentWanted(v, _this2.handleClose);
117
+            },
118
+            InputWantedOnBlur: function InputWantedOnBlur(v) {
119
+              return _this2.handleUpdateCurrentWanted(v);
120
+            },
121
+            InputWantedClear: function InputWantedClear() {
122
+              return _this2.clearCurrentWanted(_this2.handleClose);
123
+            },
124
+            CloseFunction: this.handleClose
127 125
           });
128 126
         }
129
-      }, popoverConfig, {
130
-        content: React.createElement("div", {
131
-          className: styles.wantedWrapper
132
-        }, React.createElement("div", {
133
-          role: "button",
134
-          tabIndex: 1,
135
-          className: styles.closeBtnWrapper
136
-        }, React.createElement("div", {
137
-          className: styles.closeBtn,
138
-          onClick: this.handleClose
139
-        }, React.createElement("img", {
140
-          src: img,
141
-          alt: "close wanted button"
142
-        }))), this.renderInitView())
143
-      }), children);
144
-    }
145
-  }]);
127
+      },
128
+      {
129
+        key: "render",
130
+        value: function render() {
131
+          var _this3 = this;
132
+
133
+          var _this$props = this.props,
134
+            children = _this$props.children,
135
+            _this$props$popoverCo = _this$props.popoverConfig,
136
+            popoverConfig =
137
+              _this$props$popoverCo === void 0 ? {} : _this$props$popoverCo;
138
+          return React.createElement(
139
+            Popover,
140
+            Object.assign(
141
+              {
142
+                placement: "left",
143
+                trigger: "click",
144
+                visible: this.state.visible,
145
+                onVisibleChange: function onVisibleChange(value) {
146
+                  if (!value) {
147
+                    _this3.handleClose();
148
+                  }
149
+
150
+                  _this3.setState({
151
+                    visible: value
152
+                  });
153
+                }
154
+              },
155
+              popoverConfig,
156
+              {
157
+                content: React.createElement(
158
+                  "div",
159
+                  {
160
+                    className: styles.wantedWrapper
161
+                  },
162
+                  React.createElement(
163
+                    "div",
164
+                    {
165
+                      role: "button",
166
+                      tabIndex: 1,
167
+                      className: styles.closeBtnWrapper
168
+                    },
169
+                    React.createElement(
170
+                      "div",
171
+                      {
172
+                        className: styles.closeBtn,
173
+                        onClick: this.handleClose
174
+                      },
175
+                      React.createElement("img", {
176
+                        src: img,
177
+                        alt: "close wanted button"
178
+                      })
179
+                    )
180
+                  ),
181
+                  this.renderInitView()
182
+                )
183
+              }
184
+            ),
185
+            children
186
+          );
187
+        }
188
+      }
189
+    ]);
146 190
 
147
-  return WantedPublishPopover;
148
-}(React.Component);
191
+    return WantedPublishPopover;
192
+  })(React.Component);
149 193
 
150 194
 export default WantedPublishPopover;
151 195
 export { WantedPublishPopover };

+ 1
- 1
eslib/WantedPublishPopover/index.js.map
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 16
- 13
eslib/WantedPublishView/index.d.ts Ver arquivo

@@ -1,20 +1,23 @@
1 1
 /// <reference types="react" />
2
-import React from 'react';
2
+import React from "react";
3 3
 interface WantedPublishViewProps {
4
-    type?: 'pop' | 'modal';
5
-    wrapperClass?: string;
6
-    current_wanted: number | string | null;
7
-    InputWantedValueChange: Function;
8
-    InputWantedPressEnter: Function;
9
-    InputWantedOnBlur: Function;
10
-    InputWantedClear: Function;
11
-    CloseFunction: Function;
4
+  type?: "pop" | "modal";
5
+  wrapperClass?: string;
6
+  current_wanted: number | string | null;
7
+  InputWantedValueChange: Function;
8
+  InputWantedPressEnter: Function;
9
+  InputWantedOnBlur: Function;
10
+  InputWantedClear: Function;
11
+  CloseFunction: Function;
12 12
 }
13 13
 interface WantedPublishViewState {
14
-    payment?: number;
14
+  payment?: number;
15 15
 }
16
-declare class WantedPublishView extends React.Component<WantedPublishViewProps, WantedPublishViewState> {
17
-    constructor(props: WantedPublishViewProps);
18
-    render(): JSX.Element;
16
+declare class WantedPublishView extends React.Component<
17
+  WantedPublishViewProps,
18
+  WantedPublishViewState
19
+> {
20
+  constructor(props: WantedPublishViewProps);
21
+  render(): JSX.Element;
19 22
 }
20 23
 export { WantedPublishView as default };

+ 155
- 95
eslib/WantedPublishView/index.js
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 1
- 1
eslib/WantedPublishView/index.js.map
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 15
- 4
eslib/_commonjsHelpers-97e6d7b1.js Ver arquivo

@@ -1,11 +1,22 @@
1
-var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
1
+var commonjsGlobal =
2
+  typeof globalThis !== "undefined"
3
+    ? globalThis
4
+    : typeof window !== "undefined"
5
+    ? window
6
+    : typeof global !== "undefined"
7
+    ? global
8
+    : typeof self !== "undefined"
9
+    ? self
10
+    : {};
2 11
 
3
-function unwrapExports (x) {
4
-	return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
12
+function unwrapExports(x) {
13
+  return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, "default")
14
+    ? x["default"]
15
+    : x;
5 16
 }
6 17
 
7 18
 function createCommonjsModule(fn, module) {
8
-	return module = { exports: {} }, fn(module, module.exports), module.exports;
19
+  return (module = { exports: {} }), fn(module, module.exports), module.exports;
9 20
 }
10 21
 
11 22
 export { commonjsGlobal as a, createCommonjsModule as c, unwrapExports as u };

+ 43
- 44
eslib/index-c9837619.js Ver arquivo

@@ -1,52 +1,51 @@
1
-import { c as createCommonjsModule } from './_commonjsHelpers-97e6d7b1.js';
1
+import { c as createCommonjsModule } from "./_commonjsHelpers-97e6d7b1.js";
2 2
 
3
-var classnames = createCommonjsModule(function (module) {
4
-/*!
3
+var classnames = createCommonjsModule(function(module) {
4
+  /*!
5 5
   Copyright (c) 2017 Jed Watson.
6 6
   Licensed under the MIT License (MIT), see
7 7
   http://jedwatson.github.io/classnames
8 8
 */
9
-/* global define */
10
-
11
-(function () {
12
-
13
-	var hasOwn = {}.hasOwnProperty;
14
-
15
-	function classNames () {
16
-		var classes = [];
17
-
18
-		for (var i = 0; i < arguments.length; i++) {
19
-			var arg = arguments[i];
20
-			if (!arg) continue;
21
-
22
-			var argType = typeof arg;
23
-
24
-			if (argType === 'string' || argType === 'number') {
25
-				classes.push(arg);
26
-			} else if (Array.isArray(arg) && arg.length) {
27
-				var inner = classNames.apply(null, arg);
28
-				if (inner) {
29
-					classes.push(inner);
30
-				}
31
-			} else if (argType === 'object') {
32
-				for (var key in arg) {
33
-					if (hasOwn.call(arg, key) && arg[key]) {
34
-						classes.push(key);
35
-					}
36
-				}
37
-			}
38
-		}
39
-
40
-		return classes.join(' ');
41
-	}
42
-
43
-	if ( module.exports) {
44
-		classNames.default = classNames;
45
-		module.exports = classNames;
46
-	} else {
47
-		window.classNames = classNames;
48
-	}
49
-}());
9
+  /* global define */
10
+
11
+  (function() {
12
+    var hasOwn = {}.hasOwnProperty;
13
+
14
+    function classNames() {
15
+      var classes = [];
16
+
17
+      for (var i = 0; i < arguments.length; i++) {
18
+        var arg = arguments[i];
19
+        if (!arg) continue;
20
+
21
+        var argType = typeof arg;
22
+
23
+        if (argType === "string" || argType === "number") {
24
+          classes.push(arg);
25
+        } else if (Array.isArray(arg) && arg.length) {
26
+          var inner = classNames.apply(null, arg);
27
+          if (inner) {
28
+            classes.push(inner);
29
+          }
30
+        } else if (argType === "object") {
31
+          for (var key in arg) {
32
+            if (hasOwn.call(arg, key) && arg[key]) {
33
+              classes.push(key);
34
+            }
35
+          }
36
+        }
37
+      }
38
+
39
+      return classes.join(" ");
40
+    }
41
+
42
+    if (module.exports) {
43
+      classNames.default = classNames;
44
+      module.exports = classNames;
45
+    } else {
46
+      window.classNames = classNames;
47
+    }
48
+  })();
50 49
 });
51 50
 
52 51
 export { classnames as c };

+ 18
- 18
eslib/index.js Ver arquivo

@@ -1,19 +1,19 @@
1
-import './inherits-6cb67931.js';
2
-import 'react';
3
-import 'react-dom';
4
-export { default as Modal } from './Modal/index.js';
5
-import './style-inject.es-1f59c1d0.js';
6
-import './defineProperty-18999f8e.js';
7
-import './_commonjsHelpers-97e6d7b1.js';
8
-import './index-c9837619.js';
9
-import './utils-6b513b37.js';
10
-export { default as ConsumeListView } from './ConsumeListView/index.js';
11
-export { default as PayPlatformOptions } from './PayPlatformOptions/index.js';
12
-import './slicedToArray-4cd9e6d3.js';
13
-import 'antd';
14
-export { default as PriceOptions } from './PriceOptions/index.js';
15
-export { default as WaitPayInfoView } from './WaitPayInfoView/index.js';
16
-export { default as AllocWantedModal } from './AllocWantedModal/index.js';
17
-export { default as WantedPublishView } from './WantedPublishView/index.js';
18
-export { default as WantedPublishPopover } from './WantedPublishPopover/index.js';
1
+import "./inherits-6cb67931.js";
2
+import "react";
3
+import "react-dom";
4
+export { default as Modal } from "./Modal/index.js";
5
+import "./style-inject.es-1f59c1d0.js";
6
+import "./defineProperty-18999f8e.js";
7
+import "./_commonjsHelpers-97e6d7b1.js";
8
+import "./index-c9837619.js";
9
+import "./utils-6b513b37.js";
10
+export { default as ConsumeListView } from "./ConsumeListView/index.js";
11
+export { default as PayPlatformOptions } from "./PayPlatformOptions/index.js";
12
+import "./slicedToArray-4cd9e6d3.js";
13
+import "antd";
14
+export { default as PriceOptions } from "./PriceOptions/index.js";
15
+export { default as WaitPayInfoView } from "./WaitPayInfoView/index.js";
16
+export { default as AllocWantedModal } from "./AllocWantedModal/index.js";
17
+export { default as WantedPublishView } from "./WantedPublishView/index.js";
18
+export { default as WantedPublishPopover } from "./WantedPublishPopover/index.js";
19 19
 //# sourceMappingURL=index.js.map

+ 28
- 10
eslib/inherits-6cb67931.js Ver arquivo

@@ -29,7 +29,12 @@ function _typeof(obj) {
29 29
     };
30 30
   } else {
31 31
     _typeof = function _typeof(obj) {
32
-      return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
32
+      return obj &&
33
+        typeof Symbol === "function" &&
34
+        obj.constructor === Symbol &&
35
+        obj !== Symbol.prototype
36
+        ? "symbol"
37
+        : typeof obj;
33 38
     };
34 39
   }
35 40
 
@@ -38,7 +43,9 @@ function _typeof(obj) {
38 43
 
39 44
 function _assertThisInitialized(self) {
40 45
   if (self === void 0) {
41
-    throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
46
+    throw new ReferenceError(
47
+      "this hasn't been initialised - super() hasn't been called"
48
+    );
42 49
   }
43 50
 
44 51
   return self;
@@ -53,17 +60,21 @@ function _possibleConstructorReturn(self, call) {
53 60
 }
54 61
 
55 62
 function _getPrototypeOf(o) {
56
-  _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) {
57
-    return o.__proto__ || Object.getPrototypeOf(o);
58
-  };
63
+  _getPrototypeOf = Object.setPrototypeOf
64
+    ? Object.getPrototypeOf
65
+    : function _getPrototypeOf(o) {
66
+        return o.__proto__ || Object.getPrototypeOf(o);
67
+      };
59 68
   return _getPrototypeOf(o);
60 69
 }
61 70
 
62 71
 function _setPrototypeOf(o, p) {
63
-  _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {
64
-    o.__proto__ = p;
65
-    return o;
66
-  };
72
+  _setPrototypeOf =
73
+    Object.setPrototypeOf ||
74
+    function _setPrototypeOf(o, p) {
75
+      o.__proto__ = p;
76
+      return o;
77
+    };
67 78
 
68 79
   return _setPrototypeOf(o, p);
69 80
 }
@@ -83,5 +94,12 @@ function _inherits(subClass, superClass) {
83 94
   if (superClass) _setPrototypeOf(subClass, superClass);
84 95
 }
85 96
 
86
-export { _typeof as _, _inherits as a, _classCallCheck as b, _possibleConstructorReturn as c, _getPrototypeOf as d, _createClass as e };
97
+export {
98
+  _typeof as _,
99
+  _inherits as a,
100
+  _classCallCheck as b,
101
+  _possibleConstructorReturn as c,
102
+  _getPrototypeOf as d,
103
+  _createClass as e
104
+};
87 105
 //# sourceMappingURL=inherits-6cb67931.js.map

+ 14
- 3
eslib/slicedToArray-4cd9e6d3.js Ver arquivo

@@ -3,7 +3,12 @@ function _arrayWithHoles(arr) {
3 3
 }
4 4
 
5 5
 function _iterableToArrayLimit(arr, i) {
6
-  if (!(Symbol.iterator in Object(arr) || Object.prototype.toString.call(arr) === "[object Arguments]")) {
6
+  if (
7
+    !(
8
+      Symbol.iterator in Object(arr) ||
9
+      Object.prototype.toString.call(arr) === "[object Arguments]"
10
+    )
11
+  ) {
7 12
     return;
8 13
   }
9 14
 
@@ -13,7 +18,11 @@ function _iterableToArrayLimit(arr, i) {
13 18
   var _e = undefined;
14 19
 
15 20
   try {
16
-    for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) {
21
+    for (
22
+      var _i = arr[Symbol.iterator](), _s;
23
+      !(_n = (_s = _i.next()).done);
24
+      _n = true
25
+    ) {
17 26
       _arr.push(_s.value);
18 27
 
19 28
       if (i && _arr.length === i) break;
@@ -37,7 +46,9 @@ function _nonIterableRest() {
37 46
 }
38 47
 
39 48
 function _slicedToArray(arr, i) {
40
-  return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest();
49
+  return (
50
+    _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest()
51
+  );
41 52
 }
42 53
 
43 54
 export { _slicedToArray as _ };

+ 8
- 6
eslib/style-inject.es-1f59c1d0.js Ver arquivo

@@ -1,14 +1,16 @@
1 1
 function styleInject(css, ref) {
2
-  if ( ref === void 0 ) ref = {};
2
+  if (ref === void 0) ref = {};
3 3
   var insertAt = ref.insertAt;
4 4
 
5
-  if (!css || typeof document === 'undefined') { return; }
5
+  if (!css || typeof document === "undefined") {
6
+    return;
7
+  }
6 8
 
7
-  var head = document.head || document.getElementsByTagName('head')[0];
8
-  var style = document.createElement('style');
9
-  style.type = 'text/css';
9
+  var head = document.head || document.getElementsByTagName("head")[0];
10
+  var style = document.createElement("style");
11
+  style.type = "text/css";
10 12
 
11
-  if (insertAt === 'top') {
13
+  if (insertAt === "top") {
12 14
     if (head.firstChild) {
13 15
       head.insertBefore(style, head.firstChild);
14 16
     } else {

+ 23
- 10
eslib/utils-6b513b37.d.ts Ver arquivo

@@ -2,16 +2,29 @@ declare const IMAGE_PROCESS = "?x-oss-process=image/resize,h_350";
2 2
 declare const IMAGE_PROCESS_SMALL = "?x-oss-process=image/resize,h_100";
3 3
 declare const IMAGE_PROCESS_LARGE = "?x-oss-process=image/resize,h_500";
4 4
 interface AddImageProcessOptions {
5
-    small?: boolean;
6
-    large?: boolean;
7
-    custom?: boolean;
8
-    width?: string;
9
-    height?: string;
5
+  small?: boolean;
6
+  large?: boolean;
7
+  custom?: boolean;
8
+  width?: string;
9
+  height?: string;
10 10
 }
11
-declare function addImageProcess(url: string, options?: AddImageProcessOptions): string;
11
+declare function addImageProcess(
12
+  url: string,
13
+  options?: AddImageProcessOptions
14
+): string;
12 15
 declare function formatMoney(input: any, fuzz?: number): any;
13
-type classSize = 'small' | 'normal' | 'large';
14
-declare function exportStyleSizeClass(styles: any, size: classSize): {
15
-    [x: number]: boolean;
16
+type classSize = "small" | "normal" | "large";
17
+declare function exportStyleSizeClass(
18
+  styles: any,
19
+  size: classSize
20
+): {
21
+  [x: number]: boolean;
22
+};
23
+export {
24
+  IMAGE_PROCESS,
25
+  IMAGE_PROCESS_SMALL,
26
+  IMAGE_PROCESS_LARGE,
27
+  addImageProcess,
28
+  formatMoney,
29
+  exportStyleSizeClass
16 30
 };
17
-export { IMAGE_PROCESS, IMAGE_PROCESS_SMALL, IMAGE_PROCESS_LARGE, addImageProcess, formatMoney, exportStyleSizeClass };

+ 16
- 10
eslib/utils-6b513b37.js Ver arquivo

@@ -1,15 +1,18 @@
1
-import { _ as _defineProperty } from './defineProperty-18999f8e.js';
1
+import { _ as _defineProperty } from "./defineProperty-18999f8e.js";
2 2
 
3
-var IMAGE_PROCESS = '?x-oss-process=image/resize,h_350';
4
-var IMAGE_PROCESS_SMALL = '?x-oss-process=image/resize,h_100';
5
-var IMAGE_PROCESS_LARGE = '?x-oss-process=image/resize,h_500';
3
+var IMAGE_PROCESS = "?x-oss-process=image/resize,h_350";
4
+var IMAGE_PROCESS_SMALL = "?x-oss-process=image/resize,h_100";
5
+var IMAGE_PROCESS_LARGE = "?x-oss-process=image/resize,h_500";
6 6
 function addImageProcess(url) {
7
-  var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {
8
-    width: '36px',
9
-    height: '36px'
10
-  };
7
+  var options =
8
+    arguments.length > 1 && arguments[1] !== undefined
9
+      ? arguments[1]
10
+      : {
11
+          width: "36px",
12
+          height: "36px"
13
+        };
11 14
 
12
-  if (url && url.indexOf('x-oss-process') > -1) {
15
+  if (url && url.indexOf("x-oss-process") > -1) {
13 16
     return url;
14 17
   }
15 18
 
@@ -22,7 +25,10 @@ function addImageProcess(url) {
22 25
   }
23 26
 
24 27
   if (options.custom) {
25
-    return "".concat(url, "?x-oss-process=image/resize,limit_0,m_fill,w_").concat(options.width, ",h_").concat(options.height);
28
+    return ""
29
+      .concat(url, "?x-oss-process=image/resize,limit_0,m_fill,w_")
30
+      .concat(options.width, ",h_")
31
+      .concat(options.height);
26 32
   }
27 33
 
28 34
   return url + IMAGE_PROCESS;

+ 1
- 1
eslib/utils-6b513b37.js.map Ver arquivo

@@ -1 +1 @@
1
-{"version":3,"file":"utils-6b513b37.js","sources":["../src/components/Payment/Utils/utils.ts"],"sourcesContent":["\r\nexport const IMAGE_PROCESS = '?x-oss-process=image/resize,h_350';\r\nexport const IMAGE_PROCESS_SMALL = '?x-oss-process=image/resize,h_100';\r\nexport const IMAGE_PROCESS_LARGE = '?x-oss-process=image/resize,h_500';\r\n\r\ninterface AddImageProcessOptions {\r\n  small?: boolean;\r\n  large?: boolean;\r\n  custom?: boolean;\r\n  width?: string;\r\n  height?: string;\r\n}\r\n\r\nexport function addImageProcess(url: string, options: AddImageProcessOptions = { width: '36px', height: '36px' }) {\r\n  // 防止重复添加导致的url不正确\r\n  if (url && url.indexOf('x-oss-process') > -1) {\r\n    return url;\r\n  }\r\n  if (options.small) {\r\n    return url + IMAGE_PROCESS_SMALL;\r\n  }\r\n  if (options.large) {\r\n    return url + IMAGE_PROCESS_LARGE;\r\n  }\r\n  if (options.custom) {\r\n    return `${url}?x-oss-process=image/resize,limit_0,m_fill,w_${options.width},h_${options.height}`;\r\n  }\r\n  return url + IMAGE_PROCESS;\r\n}\r\n\r\nexport function formatMoney(input: any, fuzz = 2) {\r\n  if (isNaN(+input)) {\r\n    return input;\r\n  }\r\n  return (+input).toFixed(fuzz);\r\n}\r\n\r\ntype classSize = 'small'|'normal'|'large';\r\n\r\nexport function exportStyleSizeClass(styles: any, size: classSize) {\r\n  return {\r\n    [styles[size]]: true,\r\n  }\r\n}"],"names":["IMAGE_PROCESS","IMAGE_PROCESS_SMALL","IMAGE_PROCESS_LARGE","addImageProcess","url","options","width","height","indexOf","small","large","custom","exportStyleSizeClass","styles","size"],"mappings":";;AACO,IAAMA,aAAa,GAAG,mCAAtB;AACA,IAAMC,mBAAmB,GAAG,mCAA5B;AACA,IAAMC,mBAAmB,GAAG,mCAA5B;AAUD,SAAUC,eAAV,CAA0BC,GAA1B,EAA0G;MAAnEC,OAAmE,uEAAjC;AAAEC,IAAAA,KAAK,EAAE,MAAT;AAAiBC,IAAAA,MAAM,EAAE;AAAzB;;MAEzEH,GAAG,IAAIA,GAAG,CAACI,OAAJ,CAAY,eAAZ,IAA+B,CAAC,GAAG;WACrCJ;;;MAELC,OAAO,CAACI,OAAO;WACVL,GAAG,GAAGH;;;MAEXI,OAAO,CAACK,OAAO;WACVN,GAAG,GAAGF;;;MAEXG,OAAO,CAACM,QAAQ;qBACRP,6DAAmDC,OAAO,CAACC,qBAAWD,OAAO,CAACE;;;SAEnFH,GAAG,GAAGJ;;AAYT,SAAUY,oBAAV,CAA+BC,MAA/B,EAA4CC,IAA5C,EAA2D;6BAE5DD,MAAM,CAACC,IAAD,GAAS;;;;;"}
1
+{"version":3,"file":"utils-6b513b37.js","sources":["../src/components/Payment/Utils/utils.ts"],"sourcesContent":["\nexport const IMAGE_PROCESS = '?x-oss-process=image/resize,h_350';\nexport const IMAGE_PROCESS_SMALL = '?x-oss-process=image/resize,h_100';\nexport const IMAGE_PROCESS_LARGE = '?x-oss-process=image/resize,h_500';\n\ninterface AddImageProcessOptions {\n  small?: boolean;\n  large?: boolean;\n  custom?: boolean;\n  width?: string;\n  height?: string;\n}\n\nexport function addImageProcess(url: string, options: AddImageProcessOptions = { width: '36px', height: '36px' }) {\n  // 防止重复添加导致的url不正确\n  if (url && url.indexOf('x-oss-process') > -1) {\n    return url;\n  }\n  if (options.small) {\n    return url + IMAGE_PROCESS_SMALL;\n  }\n  if (options.large) {\n    return url + IMAGE_PROCESS_LARGE;\n  }\n  if (options.custom) {\n    return `${url}?x-oss-process=image/resize,limit_0,m_fill,w_${options.width},h_${options.height}`;\n  }\n  return url + IMAGE_PROCESS;\n}\n\nexport function formatMoney(input: any, fuzz = 2) {\n  if (isNaN(+input)) {\n    return input;\n  }\n  return (+input).toFixed(fuzz);\n}\n\ntype classSize = 'small'|'normal'|'large';\n\nexport function exportStyleSizeClass(styles: any, size: classSize) {\n  return {\n    [styles[size]]: true,\n  }\n}"],"names":["IMAGE_PROCESS","IMAGE_PROCESS_SMALL","IMAGE_PROCESS_LARGE","addImageProcess","url","options","width","height","indexOf","small","large","custom","exportStyleSizeClass","styles","size"],"mappings":";;AACO,IAAMA,aAAa,GAAG,mCAAtB;AACA,IAAMC,mBAAmB,GAAG,mCAA5B;AACA,IAAMC,mBAAmB,GAAG,mCAA5B;AAUD,SAAUC,eAAV,CAA0BC,GAA1B,EAA0G;MAAnEC,OAAmE,uEAAjC;AAAEC,IAAAA,KAAK,EAAE,MAAT;AAAiBC,IAAAA,MAAM,EAAE;AAAzB;;MAEzEH,GAAG,IAAIA,GAAG,CAACI,OAAJ,CAAY,eAAZ,IAA+B,CAAC,GAAG;WACrCJ;;;MAELC,OAAO,CAACI,OAAO;WACVL,GAAG,GAAGH;;;MAEXI,OAAO,CAACK,OAAO;WACVN,GAAG,GAAGF;;;MAEXG,OAAO,CAACM,QAAQ;qBACRP,6DAAmDC,OAAO,CAACC,qBAAWD,OAAO,CAACE;;;SAEnFH,GAAG,GAAGJ;;AAYT,SAAUY,oBAAV,CAA+BC,MAA/B,EAA4CC,IAA5C,EAA2D;6BAE5DD,MAAM,CAACC,IAAD,GAAS;;;;;"}

+ 27
- 24
lib/AllocWantedModal/index.d.ts Ver arquivo

@@ -3,32 +3,35 @@ import React from "react";
3 3
 import { RefObject } from "react";
4 4
 import { Input } from "antd";
5 5
 interface AllocWantedModalProps {
6
-    allocValue: string | number | null;
7
-    sendValueRange: Array<string | number>;
8
-    sendRequest: Function;
9
-    sendGiftData: {
10
-        answerId: string | number;
11
-        questionId: string | number;
12
-        toUserId: string | number;
13
-    };
14
-    handleVisibleChange: (visible: boolean) => void;
6
+  allocValue: string | number | null;
7
+  sendValueRange: Array<string | number>;
8
+  sendRequest: Function;
9
+  sendGiftData: {
10
+    answerId: string | number;
11
+    questionId: string | number;
12
+    toUserId: string | number;
13
+  };
14
+  handleVisibleChange: (visible: boolean) => void;
15 15
 }
16 16
 interface AllocWantedModalState {
17
-    visible: boolean;
18
-    outRangeTip: boolean;
19
-    sendValue: string | number;
17
+  visible: boolean;
18
+  outRangeTip: boolean;
19
+  sendValue: string | number;
20 20
 }
21
-declare class AllocWantedModal extends React.Component<AllocWantedModalProps, AllocWantedModalState> {
22
-    ModalInputRef: RefObject<Input>;
23
-    ModalContentRef: RefObject<any>;
24
-    constructor(props: AllocWantedModalProps);
25
-    handleSendValueChange: (v: React.ReactText) => void;
26
-    checkSendValue: () => boolean;
27
-    handleCloseAction: () => void;
28
-    handleShowAction: () => void;
29
-    handleConfirm: () => null | undefined;
30
-    renderCloseButton: () => JSX.Element;
31
-    renderModalContent: () => JSX.Element;
32
-    render(): JSX.Element;
21
+declare class AllocWantedModal extends React.Component<
22
+  AllocWantedModalProps,
23
+  AllocWantedModalState
24
+> {
25
+  ModalInputRef: RefObject<Input>;
26
+  ModalContentRef: RefObject<any>;
27
+  constructor(props: AllocWantedModalProps);
28
+  handleSendValueChange: (v: React.ReactText) => void;
29
+  checkSendValue: () => boolean;
30
+  handleCloseAction: () => void;
31
+  handleShowAction: () => void;
32
+  handleConfirm: () => null | undefined;
33
+  renderCloseButton: () => JSX.Element;
34
+  renderModalContent: () => JSX.Element;
35
+  render(): JSX.Element;
33 36
 }
34 37
 export { AllocWantedModal as default };

+ 316
- 198
lib/AllocWantedModal/index.js Ver arquivo

@@ -1,233 +1,351 @@
1
-'use strict';
1
+"use strict";
2 2
 
3
-Object.defineProperty(exports, '__esModule', { value: true });
3
+Object.defineProperty(exports, "__esModule", { value: true });
4 4
 
5
-function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
5
+function _interopDefault(ex) {
6
+  return ex && typeof ex === "object" && "default" in ex ? ex["default"] : ex;
7
+}
6 8
 
7
-var inherits = require('../inherits-c86d64c1.js');
8
-var React = require('react');
9
+var inherits = require("../inherits-c86d64c1.js");
10
+var React = require("react");
9 11
 var React__default = _interopDefault(React);
10
-require('react-dom');
11
-var Modal = require('../Modal/index.js');
12
-var styleInject_es = require('../style-inject.es-dcee06b6.js');
13
-var antd = require('antd');
12
+require("react-dom");
13
+var Modal = require("../Modal/index.js");
14
+var styleInject_es = require("../style-inject.es-dcee06b6.js");
15
+var antd = require("antd");
14 16
 
15
-var img = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABMAAAATCAYAAAByUDbMAAACMUlEQVQ4T52Uz4tSURTHPxP9oCkKy0UuIqvZSAsrHHgLEaFSDCJoU0GpQaBgqOCmP6AWKrR5kIELNzZZUUQLlReFFowOboQK2oyLkgExsxqJoprixlx5yXs1dXbvnO/93HPPO+dM8WfbCuwANgNfgA/A0OzIlElgH3AIsBrEl4EXwEvguz4+CdsIHAV2/yVjEX4PVFez/SXXwzYAJ4GdawBJyWfggQTqYSKj/f8AklKR4V1gRcJ2rWY1Zvl8PqumaW8n4YFAwFqpVCb988BzCTsCzMiDDodjut1uX11YWGh4PJ470p/L5ZRIJHI+kUhcU1V1UXfRR+CWhF0ARPHHpqrqbCwWC7darXm32z2Xz+fdoVDobL1ef+z1eu8ZlOO2gIkeChrVKpPJHEylUhd7vd5rm822V9O0it/vf2hS16qAbQfOmBW+3W6HnU6nMhgMlux2+5XRaLRion0iYJuAsJGgWq2e8Pv9x5vN5lOXy6V0Op1XiqLkh8PhNwN9WdbsHLBFL6jVaqc8Hs+xYrE4FwwGnyWTyZl0On2p2+0uKopyo9/vf9XpfwA3JcwNHND/zUajcblUKpWj0WhT+qPRqD2bzUbi8fj1QqHwRgfrA/clbBtwGlgnBRaLZb3Rc0z8j4COfgJmgcP/MQEiw/LkbAqwGCmxMdZq7wDRKmI9/Tbo8ltk6NQ/2YTcAWrA+EeY7TPRewK4B5jWwcRB8Syxy5YmLzGD6XViQuSm/QSINjC0n/ltqZBTCKFgAAAAAElFTkSuQmCC";
17
+var img =
18
+  "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABMAAAATCAYAAAByUDbMAAACMUlEQVQ4T52Uz4tSURTHPxP9oCkKy0UuIqvZSAsrHHgLEaFSDCJoU0GpQaBgqOCmP6AWKrR5kIELNzZZUUQLlReFFowOboQK2oyLkgExsxqJoprixlx5yXs1dXbvnO/93HPPO+dM8WfbCuwANgNfgA/A0OzIlElgH3AIsBrEl4EXwEvguz4+CdsIHAV2/yVjEX4PVFez/SXXwzYAJ4GdawBJyWfggQTqYSKj/f8AklKR4V1gRcJ2rWY1Zvl8PqumaW8n4YFAwFqpVCb988BzCTsCzMiDDodjut1uX11YWGh4PJ470p/L5ZRIJHI+kUhcU1V1UXfRR+CWhF0ARPHHpqrqbCwWC7darXm32z2Xz+fdoVDobL1ef+z1eu8ZlOO2gIkeChrVKpPJHEylUhd7vd5rm822V9O0it/vf2hS16qAbQfOmBW+3W6HnU6nMhgMlux2+5XRaLRion0iYJuAsJGgWq2e8Pv9x5vN5lOXy6V0Op1XiqLkh8PhNwN9WdbsHLBFL6jVaqc8Hs+xYrE4FwwGnyWTyZl0On2p2+0uKopyo9/vf9XpfwA3JcwNHND/zUajcblUKpWj0WhT+qPRqD2bzUbi8fj1QqHwRgfrA/clbBtwGlgnBRaLZb3Rc0z8j4COfgJmgcP/MQEiw/LkbAqwGCmxMdZq7wDRKmI9/Tbo8ltk6NQ/2YTcAWrA+EeY7TPRewK4B5jWwcRB8Syxy5YmLzGD6XViQuSm/QSINjC0n/ltqZBTCKFgAAAAAElFTkSuQmCC";
16 19
 
17
-var css = ".AllocWantedModal_wantedModalContent__1VodF {\n  background-color: white;\n  width: 360px;\n  height: 314px;\n  padding: 22px 28px;\n  border-radius: 7px;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_title__31i9F {\n  font-size: 18px;\n  font-weight: 400;\n  text-align: center;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_wantedValueText___uNQe {\n  color: #565656;\n  margin-top: 48px;\n  font-size: 14px;\n  line-height: 20px;\n  text-align: center;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_wantedInputNumber__3MyO5 {\n  margin: 11px auto;\n  text-align: center;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_wantedInputNumber__3MyO5 .ant-input {\n  color: #FB4B56;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_wantedValueTipBottom__3WBt0 {\n  margin: 0 auto;\n  font-size: 12px;\n  text-align: center;\n  width: 208px;\n  color: #9B9B9B;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX {\n  display: flex;\n  justify-content: center;\n  align-items: center;\n  margin-top: 23px;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX .AllocWantedModal_confirmButton__1yXDN {\n  color: white;\n  background-color: #71C135;\n  width: 170px;\n  height: 36px;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX .AllocWantedModal_confirmButton__1yXDN:hover,\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX .AllocWantedModal_confirmButton__1yXDN:focus {\n  outline: none;\n  border-color: #8cd158;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX .AllocWantedModal_tipsButton__UmFpw {\n  margin-left: 22px;\n  width: 20px;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX .AllocWantedModal_tipsButton__UmFpw .schedule {\n  font-size: 18px;\n  cursor: pointer;\n}\n.AllocWantedModal_closeButton__1d4p- {\n  position: absolute;\n  right: 10px;\n  top: 10px;\n  display: block;\n  width: 20px;\n  height: 20px;\n  border-radius: 50%;\n  cursor: pointer;\n}\n.AllocWantedModal_closeButton__1d4p- img {\n  width: 100%;\n  height: 100%;\n}\n.AllocWantedModal_tipsView__3my0J h6 {\n  margin: 0;\n  font-size: 12px;\n  line-height: 22px;\n  color: #3D3D3D;\n}\n.AllocWantedModal_tipsView__3my0J div {\n  font-size: 12px;\n}\n.AllocWantedModal_outRangeTextTip__3R4mw .ant-tooltip-inner {\n  color: red;\n}\n";
20
+var css =
21
+  ".AllocWantedModal_wantedModalContent__1VodF {\n  background-color: white;\n  width: 360px;\n  height: 314px;\n  padding: 22px 28px;\n  border-radius: 7px;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_title__31i9F {\n  font-size: 18px;\n  font-weight: 400;\n  text-align: center;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_wantedValueText___uNQe {\n  color: #565656;\n  margin-top: 48px;\n  font-size: 14px;\n  line-height: 20px;\n  text-align: center;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_wantedInputNumber__3MyO5 {\n  margin: 11px auto;\n  text-align: center;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_wantedInputNumber__3MyO5 .ant-input {\n  color: #FB4B56;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_wantedValueTipBottom__3WBt0 {\n  margin: 0 auto;\n  font-size: 12px;\n  text-align: center;\n  width: 208px;\n  color: #9B9B9B;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX {\n  display: flex;\n  justify-content: center;\n  align-items: center;\n  margin-top: 23px;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX .AllocWantedModal_confirmButton__1yXDN {\n  color: white;\n  background-color: #71C135;\n  width: 170px;\n  height: 36px;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX .AllocWantedModal_confirmButton__1yXDN:hover,\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX .AllocWantedModal_confirmButton__1yXDN:focus {\n  outline: none;\n  border-color: #8cd158;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX .AllocWantedModal_tipsButton__UmFpw {\n  margin-left: 22px;\n  width: 20px;\n}\n.AllocWantedModal_wantedModalContent__1VodF .AllocWantedModal_buttonRow__FegZX .AllocWantedModal_tipsButton__UmFpw .schedule {\n  font-size: 18px;\n  cursor: pointer;\n}\n.AllocWantedModal_closeButton__1d4p- {\n  position: absolute;\n  right: 10px;\n  top: 10px;\n  display: block;\n  width: 20px;\n  height: 20px;\n  border-radius: 50%;\n  cursor: pointer;\n}\n.AllocWantedModal_closeButton__1d4p- img {\n  width: 100%;\n  height: 100%;\n}\n.AllocWantedModal_tipsView__3my0J h6 {\n  margin: 0;\n  font-size: 12px;\n  line-height: 22px;\n  color: #3D3D3D;\n}\n.AllocWantedModal_tipsView__3my0J div {\n  font-size: 12px;\n}\n.AllocWantedModal_outRangeTextTip__3R4mw .ant-tooltip-inner {\n  color: red;\n}\n";
18 22
 var styles = {
19
-  "wantedModalContent": "AllocWantedModal_wantedModalContent__1VodF",
20
-  "title": "AllocWantedModal_title__31i9F",
21
-  "wantedValueText": "AllocWantedModal_wantedValueText___uNQe",
22
-  "wantedInputNumber": "AllocWantedModal_wantedInputNumber__3MyO5",
23
-  "wantedValueTipBottom": "AllocWantedModal_wantedValueTipBottom__3WBt0",
24
-  "buttonRow": "AllocWantedModal_buttonRow__FegZX",
25
-  "confirmButton": "AllocWantedModal_confirmButton__1yXDN",
26
-  "tipsButton": "AllocWantedModal_tipsButton__UmFpw",
27
-  "closeButton": "AllocWantedModal_closeButton__1d4p-",
28
-  "tipsView": "AllocWantedModal_tipsView__3my0J",
29
-  "outRangeTextTip": "AllocWantedModal_outRangeTextTip__3R4mw"
23
+  wantedModalContent: "AllocWantedModal_wantedModalContent__1VodF",
24
+  title: "AllocWantedModal_title__31i9F",
25
+  wantedValueText: "AllocWantedModal_wantedValueText___uNQe",
26
+  wantedInputNumber: "AllocWantedModal_wantedInputNumber__3MyO5",
27
+  wantedValueTipBottom: "AllocWantedModal_wantedValueTipBottom__3WBt0",
28
+  buttonRow: "AllocWantedModal_buttonRow__FegZX",
29
+  confirmButton: "AllocWantedModal_confirmButton__1yXDN",
30
+  tipsButton: "AllocWantedModal_tipsButton__UmFpw",
31
+  closeButton: "AllocWantedModal_closeButton__1d4p-",
32
+  tipsView: "AllocWantedModal_tipsView__3my0J",
33
+  outRangeTextTip: "AllocWantedModal_outRangeTextTip__3R4mw"
30 34
 };
31 35
 styleInject_es.styleInject(css);
32 36
 
33 37
 var AllocWantedModal =
34
-/*#__PURE__*/
35
-function (_React$Component) {
36
-  inherits._inherits(AllocWantedModal, _React$Component);
38
+  /*#__PURE__*/
39
+  (function(_React$Component) {
40
+    inherits._inherits(AllocWantedModal, _React$Component);
37 41
 
38
-  function AllocWantedModal(props) {
39
-    var _this;
42
+    function AllocWantedModal(props) {
43
+      var _this;
40 44
 
41
-    inherits._classCallCheck(this, AllocWantedModal);
45
+      inherits._classCallCheck(this, AllocWantedModal);
42 46
 
43
-    _this = inherits._possibleConstructorReturn(this, inherits._getPrototypeOf(AllocWantedModal).call(this, props));
47
+      _this = inherits._possibleConstructorReturn(
48
+        this,
49
+        inherits._getPrototypeOf(AllocWantedModal).call(this, props)
50
+      );
51
+
52
+      _this.handleSendValueChange = function(v) {
53
+        if (_this.state.outRangeTip) {
54
+          _this.setState({
55
+            outRangeTip: !_this.checkSendValue()
56
+          });
57
+        }
44 58
 
45
-    _this.handleSendValueChange = function (v) {
46
-      if (_this.state.outRangeTip) {
47 59
         _this.setState({
48
-          outRangeTip: !_this.checkSendValue()
60
+          sendValue: v
49 61
         });
50
-      }
62
+      };
51 63
 
52
-      _this.setState({
53
-        sendValue: v
54
-      });
55
-    };
64
+      _this.checkSendValue = function() {
65
+        var sendValueRange = _this.props.sendValueRange;
66
+        var sendValue = _this.state.sendValue;
67
+        var min = 0;
68
+        var max = Number(_this.props.allocValue);
56 69
 
57
-    _this.checkSendValue = function () {
58
-      var sendValueRange = _this.props.sendValueRange;
59
-      var sendValue = _this.state.sendValue;
60
-      var min = 0;
61
-      var max = Number(_this.props.allocValue);
70
+        if (sendValueRange) {
71
+          min = Number(sendValueRange[0]);
72
+          max = Number(sendValueRange[1]);
73
+        }
62 74
 
63
-      if (sendValueRange) {
64
-        min = Number(sendValueRange[0]);
65
-        max = Number(sendValueRange[1]);
66
-      }
75
+        if (sendValue > max) {
76
+          _this.setState({
77
+            outRangeTip: true
78
+          });
67 79
 
68
-      if (sendValue > max) {
69
-        _this.setState({
70
-          outRangeTip: true
71
-        });
80
+          return false;
81
+        } else if (sendValue < min) {
82
+          _this.setState({
83
+            outRangeTip: true
84
+          });
72 85
 
73
-        return false;
74
-      } else if (sendValue < min) {
75
-        _this.setState({
76
-          outRangeTip: true
86
+          return false;
87
+        }
88
+
89
+        return true;
90
+      };
91
+
92
+      _this.handleCloseAction = function() {
93
+        _this.setState(
94
+          {
95
+            visible: false,
96
+            sendValue: 0,
97
+            outRangeTip: false
98
+          },
99
+          function() {
100
+            _this.props.handleVisibleChange(false);
101
+          }
102
+        );
103
+      };
104
+
105
+      _this.handleShowAction = function() {
106
+        _this.setState(
107
+          {
108
+            visible: true
109
+          },
110
+          function() {
111
+            _this.props.handleVisibleChange(true);
112
+          }
113
+        );
114
+      };
115
+
116
+      _this.handleConfirm = function() {
117
+        var sendGiftData = _this.props.sendGiftData;
118
+
119
+        var checkResult = _this.checkSendValue();
120
+
121
+        if (!checkResult) {
122
+          return null;
123
+        }
124
+
125
+        Promise.resolve(
126
+          _this.props.sendRequest({
127
+            business_type: 14,
128
+            ref_id: sendGiftData.answerId.toString(),
129
+            origin_id: sendGiftData.questionId,
130
+            to_user: sendGiftData.toUserId,
131
+            goods_id: 2,
132
+            num: Number(_this.state.sendValue)
133
+          })
134
+        ).then(function(res) {
135
+          console.log("res: ", res);
136
+
137
+          if (res) {
138
+            _this.handleCloseAction();
139
+          } else {
140
+            _this.handleCloseAction();
141
+          }
77 142
         });
143
+      };
78 144
 
79
-        return false;
80
-      }
145
+      _this.renderCloseButton = function() {
146
+        return React__default.createElement(
147
+          "div",
148
+          {
149
+            role: "button",
150
+            tabIndex: -1,
151
+            className: styles.closeButton,
152
+            onClick: function onClick() {
153
+              _this.handleCloseAction();
154
+            }
155
+          },
156
+          React__default.createElement("img", {
157
+            src: img,
158
+            alt: "close button for send wanted"
159
+          })
160
+        );
161
+      };
81 162
 
82
-      return true;
83
-    };
163
+      _this.renderModalContent = function() {
164
+        return React__default.createElement(
165
+          "div",
166
+          {
167
+            className: styles.wantedModalContent,
168
+            ref: _this.ModalContentRef
169
+          },
170
+          _this.renderCloseButton(),
171
+          React__default.createElement(
172
+            "h4",
173
+            {
174
+              className: styles.title
175
+            },
176
+            "\u5206\u914D\u60AC\u8D4F\u5956\u91D1"
177
+          ),
178
+          React__default.createElement(
179
+            "div",
180
+            {
181
+              className: styles.wantedValueText
182
+            },
183
+            "\u5269\u4F59\u53EF\u5206\u914D ".concat(
184
+              _this.props.allocValue,
185
+              "\u5143"
186
+            )
187
+          ),
188
+          React__default.createElement(
189
+            antd.Tooltip,
190
+            {
191
+              visible: _this.state.outRangeTip,
192
+              title: "\u8D85\u8FC7\u8303\u56F4\u503C",
193
+              placement: "bottom",
194
+              overlayClassName: styles.outRangeTextTip,
195
+              getTooltipContainer: function getTooltipContainer() {
196
+                return _this.ModalContentRef && _this.ModalContentRef.current;
197
+              }
198
+            },
199
+            React__default.createElement(antd.Input, {
200
+              ref: _this.ModalInputRef,
201
+              className: styles.wantedInputNumber,
202
+              suffix: "\u5143",
203
+              value: _this.state.sendValue,
204
+              onChange: function onChange(e) {
205
+                return _this.handleSendValueChange(e.target.value);
206
+              },
207
+              onFocus: function onFocus(e) {
208
+                return e.target.setSelectionRange(
209
+                  0,
210
+                  String(_this.state.sendValue).length
211
+                );
212
+              }
213
+            })
214
+          ),
215
+          React__default.createElement(
216
+            "div",
217
+            {
218
+              className: styles.wantedValueTipBottom
219
+            },
220
+            "\u9700\u8981\u5728\u60AC\u8D4F\u65F6\u95F4\u7ED3\u675F\u524D\u5C06\u5956\u91D1\u5206\u914D\u5B8C\u6210, \u5426\u5219\u5C06\u6309\u7167\u89C4\u5219\u81EA\u52A8\u5206\u914D"
221
+          ),
222
+          React__default.createElement(
223
+            "div",
224
+            {
225
+              className: styles.buttonRow
226
+            },
227
+            React__default.createElement("div", {
228
+              className: styles.tipsButton
229
+            }),
230
+            React__default.createElement(
231
+              antd.Button,
232
+              {
233
+                className: styles.confirmButton,
234
+                onClick: _this.handleConfirm
235
+              },
236
+              "\u786E\u8BA4"
237
+            ),
238
+            React__default.createElement(
239
+              "div",
240
+              {
241
+                className: styles.tipsButton
242
+              },
243
+              React__default.createElement(
244
+                antd.Popover,
245
+                {
246
+                  placement: "bottom",
247
+                  trigger: "click",
248
+                  getPopupContainer: function getPopupContainer() {
249
+                    return (
250
+                      _this.ModalContentRef && _this.ModalContentRef.current
251
+                    );
252
+                  },
253
+                  overlayStyle: {
254
+                    width: "320px"
255
+                  },
256
+                  content: React__default.createElement(
257
+                    "div",
258
+                    {
259
+                      className: styles.tipsView
260
+                    },
261
+                    React__default.createElement(
262
+                      "h6",
263
+                      null,
264
+                      "1\u3001\u5982\u4F55\u53C2\u4E0E\u60AC\u8D4F\uFF1F"
265
+                    ),
266
+                    React__default.createElement(
267
+                      "div",
268
+                      null,
269
+                      "\u60AC\u8D4F\u95EE\u9898\u7686\u6709\u6709\u6548\u671F\uFF0C\u9ED8\u8BA4\u4E3A120\u5C0F\u65F6\uFF085\u5929\uFF09\uFF0C\u5728\u6709\u6548\u671F\u5185\u56DE\u590D\u7684\u7B54\u6848\uFF0C\u624D\u6709\u8D44\u683C\u88AB\u9009\u4E3A\u6700\u4F73\u7B54\u6848\uFF0C\u4EE5\u53CA\u5206\u5F97\u8D4F\u91D1\u3002"
270
+                    ),
271
+                    React__default.createElement(
272
+                      "h6",
273
+                      null,
274
+                      "2\u3001\u8D4F\u91D1\u5982\u4F55\u5206\uFF1F"
275
+                    ),
276
+                    React__default.createElement(
277
+                      "div",
278
+                      null,
279
+                      "\u60AC\u8D4F\u65F6\u95F4\u7ED3\u675F\u524D\uFF0C\u63D0\u95EE\u8005\u53EF\u968F\u65F6\u9009\u51FA\u6700\u4F18\u7B54\u6848\uFF0C\u5E76\u5BF9\u8D4F\u91D1\u8FDB\u884C\u5206\u914D\uFF0C\u76F4\u81F3\u8D4F\u91D1\u88AB\u5206\u5B8C\u6216\u65F6\u95F4\u5230\u671F\u4E3A\u6B62\u3002\u82E5\u60AC\u8D4F\u65F6\u95F4\u5230\u671F\uFF0C\u60AC\u8D4F\u8005\u4ECD\u672A\u5206\u914D\u8D4F\u91D1\uFF0C\u4E14\u56DE\u7B54\u6570\u5927\u4E8E\u7B49\u4E8E2\uFF0C\u7CFB\u7EDF\u5219\u9ED8\u8BA4\u5C06\u8D4F\u91D1\u5E73\u5206\u7ED9\u70B9\u8D5E\u6570\u524D3\u540D\u7684\u56DE\u7B54\u3002"
280
+                    ),
281
+                    React__default.createElement(
282
+                      "h6",
283
+                      null,
284
+                      "3\u3001\u8D4F\u91D1\u80FD\u9000\u6B3E\u5417\uFF1F"
285
+                    ),
286
+                    React__default.createElement(
287
+                      "div",
288
+                      null,
289
+                      "\u8D4F\u91D1\u53EA\u4F1A\u5728\u4EE5\u4E0B2\u79CD\u60C5\u51B5\u8FDB\u884C\u9000\u6B3E\uFF1A\u4E00\u3001\u60AC\u8D4F\u65F6\u95F4\u5230\u671F\uFF0C\u56DE\u7B54\u6570\u5C0F\u4E8E2\uFF0C\u8D4F\u91D1\u5C06\u81EA\u52A8\u9000\u8FD8\u81F3\u63D0\u95EE\u8005\u7684\u94B1\u5305\uFF1B\u4E8C\u3001\u60AC\u8D4F\u65F6\u95F4\u5230\u671F\uFF0C\u60AC\u8D4F\u8005\u672A\u5206\u914D\u5B8C\u8D4F\u91D1\uFF0C\u7CFB\u7EDF\u81EA\u52A8\u5C06\u5269\u4F59\u7684\u8D4F\u91D1\u9000\u8FD8\u81F3\u63D0\u95EE\u8005\u7684\u94B1\u5305\u3002"
290
+                    )
291
+                  )
292
+                },
293
+                React__default.createElement("i", {
294
+                  className: "schedule schedule-icon_rewardtips"
295
+                })
296
+              )
297
+            )
298
+          )
299
+        );
300
+      };
84 301
 
85
-    _this.handleCloseAction = function () {
86
-      _this.setState({
302
+      _this.state = {
87 303
         visible: false,
88 304
         sendValue: 0,
89 305
         outRangeTip: false
90
-      }, function () {
91
-        _this.props.handleVisibleChange(false);
92
-      });
93
-    };
94
-
95
-    _this.handleShowAction = function () {
96
-      _this.setState({
97
-        visible: true
98
-      }, function () {
99
-        _this.props.handleVisibleChange(true);
100
-      });
101
-    };
102
-
103
-    _this.handleConfirm = function () {
104
-      var sendGiftData = _this.props.sendGiftData;
105
-
106
-      var checkResult = _this.checkSendValue();
107
-
108
-      if (!checkResult) {
109
-        return null;
110
-      }
306
+      };
307
+      _this.ModalContentRef = React__default.createRef();
308
+      _this.ModalInputRef = React__default.createRef();
309
+      return _this;
310
+    }
111 311
 
112
-      Promise.resolve(_this.props.sendRequest({
113
-        business_type: 14,
114
-        ref_id: sendGiftData.answerId.toString(),
115
-        origin_id: sendGiftData.questionId,
116
-        to_user: sendGiftData.toUserId,
117
-        goods_id: 2,
118
-        num: Number(_this.state.sendValue)
119
-      })).then(function (res) {
120
-        console.log("res: ", res);
121
-
122
-        if (res) {
123
-          _this.handleCloseAction();
124
-        } else {
125
-          _this.handleCloseAction();
126
-        }
127
-      });
128
-    };
129
-
130
-    _this.renderCloseButton = function () {
131
-      return React__default.createElement("div", {
132
-        role: "button",
133
-        tabIndex: -1,
134
-        className: styles.closeButton,
135
-        onClick: function onClick() {
136
-          _this.handleCloseAction();
137
-        }
138
-      }, React__default.createElement("img", {
139
-        src: img,
140
-        alt: "close button for send wanted"
141
-      }));
142
-    };
143
-
144
-    _this.renderModalContent = function () {
145
-      return React__default.createElement("div", {
146
-        className: styles.wantedModalContent,
147
-        ref: _this.ModalContentRef
148
-      }, _this.renderCloseButton(), React__default.createElement("h4", {
149
-        className: styles.title
150
-      }, "\u5206\u914D\u60AC\u8D4F\u5956\u91D1"), React__default.createElement("div", {
151
-        className: styles.wantedValueText
152
-      }, "\u5269\u4F59\u53EF\u5206\u914D ".concat(_this.props.allocValue, "\u5143")), React__default.createElement(antd.Tooltip, {
153
-        visible: _this.state.outRangeTip,
154
-        title: "\u8D85\u8FC7\u8303\u56F4\u503C",
155
-        placement: "bottom",
156
-        overlayClassName: styles.outRangeTextTip,
157
-        getTooltipContainer: function getTooltipContainer() {
158
-          return _this.ModalContentRef && _this.ModalContentRef.current;
159
-        }
160
-      }, React__default.createElement(antd.Input, {
161
-        ref: _this.ModalInputRef,
162
-        className: styles.wantedInputNumber,
163
-        suffix: "\u5143",
164
-        value: _this.state.sendValue,
165
-        onChange: function onChange(e) {
166
-          return _this.handleSendValueChange(e.target.value);
167
-        },
168
-        onFocus: function onFocus(e) {
169
-          return e.target.setSelectionRange(0, String(_this.state.sendValue).length);
170
-        }
171
-      })), React__default.createElement("div", {
172
-        className: styles.wantedValueTipBottom
173
-      }, "\u9700\u8981\u5728\u60AC\u8D4F\u65F6\u95F4\u7ED3\u675F\u524D\u5C06\u5956\u91D1\u5206\u914D\u5B8C\u6210, \u5426\u5219\u5C06\u6309\u7167\u89C4\u5219\u81EA\u52A8\u5206\u914D"), React__default.createElement("div", {
174
-        className: styles.buttonRow
175
-      }, React__default.createElement("div", {
176
-        className: styles.tipsButton
177
-      }), React__default.createElement(antd.Button, {
178
-        className: styles.confirmButton,
179
-        onClick: _this.handleConfirm
180
-      }, "\u786E\u8BA4"), React__default.createElement("div", {
181
-        className: styles.tipsButton
182
-      }, React__default.createElement(antd.Popover, {
183
-        placement: "bottom",
184
-        trigger: "click",
185
-        getPopupContainer: function getPopupContainer() {
186
-          return _this.ModalContentRef && _this.ModalContentRef.current;
187
-        },
188
-        overlayStyle: {
189
-          width: "320px"
190
-        },
191
-        content: React__default.createElement("div", {
192
-          className: styles.tipsView
193
-        }, React__default.createElement("h6", null, "1\u3001\u5982\u4F55\u53C2\u4E0E\u60AC\u8D4F\uFF1F"), React__default.createElement("div", null, "\u60AC\u8D4F\u95EE\u9898\u7686\u6709\u6709\u6548\u671F\uFF0C\u9ED8\u8BA4\u4E3A120\u5C0F\u65F6\uFF085\u5929\uFF09\uFF0C\u5728\u6709\u6548\u671F\u5185\u56DE\u590D\u7684\u7B54\u6848\uFF0C\u624D\u6709\u8D44\u683C\u88AB\u9009\u4E3A\u6700\u4F73\u7B54\u6848\uFF0C\u4EE5\u53CA\u5206\u5F97\u8D4F\u91D1\u3002"), React__default.createElement("h6", null, "2\u3001\u8D4F\u91D1\u5982\u4F55\u5206\uFF1F"), React__default.createElement("div", null, "\u60AC\u8D4F\u65F6\u95F4\u7ED3\u675F\u524D\uFF0C\u63D0\u95EE\u8005\u53EF\u968F\u65F6\u9009\u51FA\u6700\u4F18\u7B54\u6848\uFF0C\u5E76\u5BF9\u8D4F\u91D1\u8FDB\u884C\u5206\u914D\uFF0C\u76F4\u81F3\u8D4F\u91D1\u88AB\u5206\u5B8C\u6216\u65F6\u95F4\u5230\u671F\u4E3A\u6B62\u3002\u82E5\u60AC\u8D4F\u65F6\u95F4\u5230\u671F\uFF0C\u60AC\u8D4F\u8005\u4ECD\u672A\u5206\u914D\u8D4F\u91D1\uFF0C\u4E14\u56DE\u7B54\u6570\u5927\u4E8E\u7B49\u4E8E2\uFF0C\u7CFB\u7EDF\u5219\u9ED8\u8BA4\u5C06\u8D4F\u91D1\u5E73\u5206\u7ED9\u70B9\u8D5E\u6570\u524D3\u540D\u7684\u56DE\u7B54\u3002"), React__default.createElement("h6", null, "3\u3001\u8D4F\u91D1\u80FD\u9000\u6B3E\u5417\uFF1F"), React__default.createElement("div", null, "\u8D4F\u91D1\u53EA\u4F1A\u5728\u4EE5\u4E0B2\u79CD\u60C5\u51B5\u8FDB\u884C\u9000\u6B3E\uFF1A\u4E00\u3001\u60AC\u8D4F\u65F6\u95F4\u5230\u671F\uFF0C\u56DE\u7B54\u6570\u5C0F\u4E8E2\uFF0C\u8D4F\u91D1\u5C06\u81EA\u52A8\u9000\u8FD8\u81F3\u63D0\u95EE\u8005\u7684\u94B1\u5305\uFF1B\u4E8C\u3001\u60AC\u8D4F\u65F6\u95F4\u5230\u671F\uFF0C\u60AC\u8D4F\u8005\u672A\u5206\u914D\u5B8C\u8D4F\u91D1\uFF0C\u7CFB\u7EDF\u81EA\u52A8\u5C06\u5269\u4F59\u7684\u8D4F\u91D1\u9000\u8FD8\u81F3\u63D0\u95EE\u8005\u7684\u94B1\u5305\u3002"))
194
-      }, React__default.createElement("i", {
195
-        className: "schedule schedule-icon_rewardtips"
196
-      })))));
197
-    };
198
-
199
-    _this.state = {
200
-      visible: false,
201
-      sendValue: 0,
202
-      outRangeTip: false
203
-    };
204
-    _this.ModalContentRef = React__default.createRef();
205
-    _this.ModalInputRef = React__default.createRef();
206
-    return _this;
207
-  }
208
-
209
-  inherits._createClass(AllocWantedModal, [{
210
-    key: "render",
211
-    value: function render() {
212
-      var _this2 = this;
213
-
214
-      var children = this.props.children;
215
-      return React__default.createElement(React__default.Fragment, null, React__default.createElement("div", {
216
-        className: styles.wrapper,
217
-        onClick: function onClick() {
218
-          return _this2.handleShowAction();
219
-        }
220
-      }, children), React__default.createElement(Modal.Modal, {
221
-        visible: this.state.visible,
222
-        onCancel: function onCancel() {
223
-          return _this2.handleCloseAction();
312
+    inherits._createClass(AllocWantedModal, [
313
+      {
314
+        key: "render",
315
+        value: function render() {
316
+          var _this2 = this;
317
+
318
+          var children = this.props.children;
319
+          return React__default.createElement(
320
+            React__default.Fragment,
321
+            null,
322
+            React__default.createElement(
323
+              "div",
324
+              {
325
+                className: styles.wrapper,
326
+                onClick: function onClick() {
327
+                  return _this2.handleShowAction();
328
+                }
329
+              },
330
+              children
331
+            ),
332
+            React__default.createElement(
333
+              Modal.Modal,
334
+              {
335
+                visible: this.state.visible,
336
+                onCancel: function onCancel() {
337
+                  return _this2.handleCloseAction();
338
+                }
339
+              },
340
+              this.renderModalContent()
341
+            )
342
+          );
224 343
         }
225
-      }, this.renderModalContent()));
226
-    }
227
-  }]);
344
+      }
345
+    ]);
228 346
 
229
-  return AllocWantedModal;
230
-}(React__default.Component);
347
+    return AllocWantedModal;
348
+  })(React__default.Component);
231 349
 
232 350
 exports.default = AllocWantedModal;
233 351
 //# sourceMappingURL=index.js.map

+ 1
- 1
lib/AllocWantedModal/index.js.map
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 1
- 3
lib/BraftEditor/index.d.ts Ver arquivo

@@ -1,5 +1,3 @@
1 1
 /// <reference types="react" />
2
-declare const BarftEditorPage: ({ value, }: {
3
-    value: string;
4
-}) => JSX.Element;
2
+declare const BarftEditorPage: ({ value }: { value: string }) => JSX.Element;
5 3
 export { BarftEditorPage as default, BarftEditorPage };

+ 39654
- 28625
lib/BraftEditor/index.js
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 1
- 1
lib/BraftEditor/index.js.map
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 7
- 9
lib/Common/index.js Ver arquivo

@@ -1,14 +1,12 @@
1
-'use strict';
2
-
3
-Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
-require('../inherits-c86d64c1.js');
6
-require('react');
7
-require('react-dom');
8
-var Modal = require('../Modal/index.js');
9
-require('../style-inject.es-dcee06b6.js');
1
+"use strict";
10 2
 
3
+Object.defineProperty(exports, "__esModule", { value: true });
11 4
 
5
+require("../inherits-c86d64c1.js");
6
+require("react");
7
+require("react-dom");
8
+var Modal = require("../Modal/index.js");
9
+require("../style-inject.es-dcee06b6.js");
12 10
 
13 11
 exports.Modal = Modal.default;
14 12
 //# sourceMappingURL=index.js.map

+ 21
- 21
lib/ConsumeListView/index.d.ts Ver arquivo

@@ -1,29 +1,29 @@
1 1
 /// <reference types="react" />
2
-import { Component, MouseEvent } from 'react';
2
+import { Component, MouseEvent } from "react";
3 3
 interface dataItem {
4
-    id?: string | number;
5
-    user_avatar?: string;
6
-    bill_price?: number;
4
+  id?: string | number;
5
+  user_avatar?: string;
6
+  bill_price?: number;
7 7
 }
8 8
 interface Props {
9
-    isToggle: boolean;
10
-    onToggleChange: Function;
11
-    onConsumeItemClick: (e: MouseEvent, clickData: any) => any;
12
-    dataSource: Array<dataItem>;
13
-    listLength: number;
14
-    showLength: number;
15
-    options: {
16
-        avatarSize: number;
17
-        avatarMarginLeftAndRight: number;
18
-        kingdomWidth: number;
19
-        kingdomHeight: number;
20
-        kingdomPosition: [number, number];
21
-    };
9
+  isToggle: boolean;
10
+  onToggleChange: Function;
11
+  onConsumeItemClick: (e: MouseEvent, clickData: any) => any;
12
+  dataSource: Array<dataItem>;
13
+  listLength: number;
14
+  showLength: number;
15
+  options: {
16
+    avatarSize: number;
17
+    avatarMarginLeftAndRight: number;
18
+    kingdomWidth: number;
19
+    kingdomHeight: number;
20
+    kingdomPosition: [number, number];
21
+  };
22 22
 }
23 23
 declare class ConsumeListView extends Component<Props, {}> {
24
-    static defaultProps: Props;
25
-    renderConsumeItem(): JSX.Element[];
26
-    renderToggleButton(): JSX.Element | null;
27
-    render(): JSX.Element;
24
+  static defaultProps: Props;
25
+  renderConsumeItem(): JSX.Element[];
26
+  renderToggleButton(): JSX.Element | null;
27
+  render(): JSX.Element;
28 28
 }
29 29
 export { ConsumeListView as default };

+ 165
- 130
lib/ConsumeListView/index.js Ver arquivo

@@ -1,157 +1,192 @@
1
-'use strict';
1
+"use strict";
2 2
 
3
-Object.defineProperty(exports, '__esModule', { value: true });
3
+Object.defineProperty(exports, "__esModule", { value: true });
4 4
 
5
-function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
5
+function _interopDefault(ex) {
6
+  return ex && typeof ex === "object" && "default" in ex ? ex["default"] : ex;
7
+}
6 8
 
7
-var inherits = require('../inherits-c86d64c1.js');
8
-var React = require('react');
9
+var inherits = require("../inherits-c86d64c1.js");
10
+var React = require("react");
9 11
 var React__default = _interopDefault(React);
10
-var styleInject_es = require('../style-inject.es-dcee06b6.js');
11
-var defineProperty = require('../defineProperty-ba7cd53d.js');
12
-require('../_commonjsHelpers-72d386ba.js');
13
-var index = require('../index-44e17595.js');
14
-var utils = require('../utils-b800dc99.js');
12
+var styleInject_es = require("../style-inject.es-dcee06b6.js");
13
+var defineProperty = require("../defineProperty-ba7cd53d.js");
14
+require("../_commonjsHelpers-72d386ba.js");
15
+var index = require("../index-44e17595.js");
16
+var utils = require("../utils-b800dc99.js");
15 17
 
16
-var img = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAYAAABWzo5XAAABvklEQVQ4T62UTygEcRTHv29MIsqfk6OL5CYH5aKd9WfjwqxEnBzExYWTCEWJJGove5H8OTA1uwdCrOWAi83ZwUXJiSj5u+Z5s0msmd2SX81h+r33ee/7fW+G8E+H/srhqEcFCjphve1RzcaVK4j3mmoB5YxqQzdOxTji1wE2QZglb2jAEcT7/g4wr0rQugS1OYJ26nOg5nYDr4ZrR7yrl0FBAKBlqjEX3eRLwSXAmidvOJbSI47oF9LVKaCOkNc4/w7kSPOoFBqDwjpp4XA60LUkF8nzbsuERQt4ejtGdsYwiAYTYIV6STOD6UB3EpqXJC0u7zKxz0Mk3Zrj7lOLerJg5T9K+2lWhALiYx8xS9NbDZnUuPXy0wN/hYw3lnbPiNfE7HaSfTAloRqKWkya8WAnMrdmIBqfBqM/BehJAo+gKHMibdMGzUhqKUiZAHGVXJYLwPdpshPnRDRM4fl5+7uKL/0c1WXdOSie5Dh3wZcyoR7SQttO9z+M5MOWEsStFQmsTAoOwVK7qM64d5P6ayKJj9EqHBa5Q4kx2/ujqR1Exnsq493HH2muFN98oNtJ0g7s3Ul5/vwbSab+G+gDqFybE11pYkYAAAAASUVORK5CYII=";
18
+var img =
19
+  "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAYAAABWzo5XAAABvklEQVQ4T62UTygEcRTHv29MIsqfk6OL5CYH5aKd9WfjwqxEnBzExYWTCEWJJGove5H8OTA1uwdCrOWAi83ZwUXJiSj5u+Z5s0msmd2SX81h+r33ee/7fW+G8E+H/srhqEcFCjphve1RzcaVK4j3mmoB5YxqQzdOxTji1wE2QZglb2jAEcT7/g4wr0rQugS1OYJ26nOg5nYDr4ZrR7yrl0FBAKBlqjEX3eRLwSXAmidvOJbSI47oF9LVKaCOkNc4/w7kSPOoFBqDwjpp4XA60LUkF8nzbsuERQt4ejtGdsYwiAYTYIV6STOD6UB3EpqXJC0u7zKxz0Mk3Zrj7lOLerJg5T9K+2lWhALiYx8xS9NbDZnUuPXy0wN/hYw3lnbPiNfE7HaSfTAloRqKWkya8WAnMrdmIBqfBqM/BehJAo+gKHMibdMGzUhqKUiZAHGVXJYLwPdpshPnRDRM4fl5+7uKL/0c1WXdOSie5Dh3wZcyoR7SQttO9z+M5MOWEsStFQmsTAoOwVK7qM64d5P6ayKJj9EqHBa5Q4kx2/ujqR1Exnsq493HH2muFN98oNtJ0g7s3Ul5/vwbSab+G+gDqFybE11pYkYAAAAASUVORK5CYII=";
17 20
 
18
-var css = ".ConsumeListView_wrapper__wlJjh {\n  display: flex;\n  justify-content: center;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR {\n  padding: 0;\n  margin: 0;\n  display: flex;\n  flex-wrap: wrap;\n  padding-top: 10px;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR li {\n  list-style: none;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_consumeItem__1QGpJ {\n  margin: 0 6px 10px;\n  text-align: center;\n  position: relative;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_consumeItem__1QGpJ .ConsumeListView_kingdomIcon__1nBe5 {\n  position: absolute;\n  width: 24px;\n  height: 22px;\n  left: -6px;\n  top: -12px;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_consumeItem__1QGpJ .ConsumeListView_avatar__1H-E5 {\n  margin: 0 auto 4px;\n  width: 36px;\n  height: 36px;\n  background-size: cover;\n  border-radius: 50%;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_consumeItem__1QGpJ .ConsumeListView_gray__3do1I {\n  color: #9b9b9b;\n  font-size: 12px;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_toggle__3eBTC {\n  margin: 0 6px 10px;\n  width: 36px;\n  height: 36px;\n  line-height: 36px;\n  background-color: #ececec;\n  border-radius: 50%;\n  color: #a8adb6;\n  cursor: pointer;\n  background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB4AAAAeCAYAAAA7MK6iAAACv0lEQVRIS8WXTW8SURSGzzAYNSYCA7SCUEqBioLtohvjD9CN7ozG36AmXfsRafxYN9b+BqNx50r3GjddqEVRRgSRVr4GWmOsERjfOwEzVYa5lAokEwJzznnOe865d+4IxPFRVXVPrVY73Wq1TgmCMIffYbjZ2q4b+E/GfysWi+WZw+F4it+/zMIKvQwAszcajXnYXEIwl1kwdh8JVPC1bLVaF5FE3cjHEFytVs8hyH04jvMAu9gUkexlp9P5uJv/P2DABCi9hbJehUPPinAkpKL8d6H8BpJQ9fbbAjOooigP8H2BIyi3CaAPJUm6qIdvAwN6G0qvcUfswxDK7wB+vePyB9zu6aNdKK9ROioUn+/0XAOz6W02m6kBBolXe1EUxSibdg0MtQn09Sav9yB2UL0A1QmBbQ6VSmWNd50OAu2sc5fL5WVTfAYD9WTQgP34Y9DOClB7D05X+nHcBdslAf19jnKfNAr2cmWVDuzfR7HoFCFTUyaqR8lUhr7/2KITc/Gu9mjrC6a4iLtjRhHfvv9Ea1/L5JLsNBML94Qz6OukTBWlTt5Dbjp2JGgUtsTAW7i713DxqSql0jkqrJfIKdloNhbpCmfQV8k0VZUNOuwZo2gkQFBmFPanKVibRFxpOUefC0VyOmw0E4+QqCt7s8mgH0ipbdKEb5wiIUB7N0UD9yy13l/O5CmbXyfJfpBm49MkihbSoKuA1jdpcsJD4aDfdA5gUDIdrr+jZLIFyuQK5AD8+NEQvXknU63+jUKTPgoGvDxQ1gJtuPpeTkw1U8+mnPU2MuWngN/DBW0bLe14A8mj3x+zX7TS+ryGi6JrMtoGMrItk6VULpcTqPtQHhIQuuB2uxOjfSwy1SM5CHQmYCRHn/azcjSHvQ586Mdb/aIb+oFeD2eHQOxM87j6eoXBBrGMa2evMPoE/sdL22+mI4T0ou1LqAAAAABJRU5ErkJggg==);\n  background-position: center;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_toggle__3eBTC.ConsumeListView_expand__3l80q {\n  transform: rotate(180deg);\n}\n";
21
+var css =
22
+  ".ConsumeListView_wrapper__wlJjh {\n  display: flex;\n  justify-content: center;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR {\n  padding: 0;\n  margin: 0;\n  display: flex;\n  flex-wrap: wrap;\n  padding-top: 10px;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR li {\n  list-style: none;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_consumeItem__1QGpJ {\n  margin: 0 6px 10px;\n  text-align: center;\n  position: relative;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_consumeItem__1QGpJ .ConsumeListView_kingdomIcon__1nBe5 {\n  position: absolute;\n  width: 24px;\n  height: 22px;\n  left: -6px;\n  top: -12px;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_consumeItem__1QGpJ .ConsumeListView_avatar__1H-E5 {\n  margin: 0 auto 4px;\n  width: 36px;\n  height: 36px;\n  background-size: cover;\n  border-radius: 50%;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_consumeItem__1QGpJ .ConsumeListView_gray__3do1I {\n  color: #9b9b9b;\n  font-size: 12px;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_toggle__3eBTC {\n  margin: 0 6px 10px;\n  width: 36px;\n  height: 36px;\n  line-height: 36px;\n  background-color: #ececec;\n  border-radius: 50%;\n  color: #a8adb6;\n  cursor: pointer;\n  background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB4AAAAeCAYAAAA7MK6iAAACv0lEQVRIS8WXTW8SURSGzzAYNSYCA7SCUEqBioLtohvjD9CN7ozG36AmXfsRafxYN9b+BqNx50r3GjddqEVRRgSRVr4GWmOsERjfOwEzVYa5lAokEwJzznnOe865d+4IxPFRVXVPrVY73Wq1TgmCMIffYbjZ2q4b+E/GfysWi+WZw+F4it+/zMIKvQwAszcajXnYXEIwl1kwdh8JVPC1bLVaF5FE3cjHEFytVs8hyH04jvMAu9gUkexlp9P5uJv/P2DABCi9hbJehUPPinAkpKL8d6H8BpJQ9fbbAjOooigP8H2BIyi3CaAPJUm6qIdvAwN6G0qvcUfswxDK7wB+vePyB9zu6aNdKK9ROioUn+/0XAOz6W02m6kBBolXe1EUxSibdg0MtQn09Sav9yB2UL0A1QmBbQ6VSmWNd50OAu2sc5fL5WVTfAYD9WTQgP34Y9DOClB7D05X+nHcBdslAf19jnKfNAr2cmWVDuzfR7HoFCFTUyaqR8lUhr7/2KITc/Gu9mjrC6a4iLtjRhHfvv9Ea1/L5JLsNBML94Qz6OukTBWlTt5Dbjp2JGgUtsTAW7i713DxqSql0jkqrJfIKdloNhbpCmfQV8k0VZUNOuwZo2gkQFBmFPanKVibRFxpOUefC0VyOmw0E4+QqCt7s8mgH0ipbdKEb5wiIUB7N0UD9yy13l/O5CmbXyfJfpBm49MkihbSoKuA1jdpcsJD4aDfdA5gUDIdrr+jZLIFyuQK5AD8+NEQvXknU63+jUKTPgoGvDxQ1gJtuPpeTkw1U8+mnPU2MuWngN/DBW0bLe14A8mj3x+zX7TS+ryGi6JrMtoGMrItk6VULpcTqPtQHhIQuuB2uxOjfSwy1SM5CHQmYCRHn/azcjSHvQ586Mdb/aIb+oFeD2eHQOxM87j6eoXBBrGMa2evMPoE/sdL22+mI4T0ou1LqAAAAABJRU5ErkJggg==);\n  background-position: center;\n}\n.ConsumeListView_wrapper__wlJjh .ConsumeListView_consumelist__2dMCR .ConsumeListView_toggle__3eBTC.ConsumeListView_expand__3l80q {\n  transform: rotate(180deg);\n}\n";
19 23
 var styles = {
20
-  "wrapper": "ConsumeListView_wrapper__wlJjh",
21
-  "consumelist": "ConsumeListView_consumelist__2dMCR",
22
-  "consumeItem": "ConsumeListView_consumeItem__1QGpJ",
23
-  "kingdomIcon": "ConsumeListView_kingdomIcon__1nBe5",
24
-  "avatar": "ConsumeListView_avatar__1H-E5",
25
-  "gray": "ConsumeListView_gray__3do1I",
26
-  "toggle": "ConsumeListView_toggle__3eBTC",
27
-  "expand": "ConsumeListView_expand__3l80q"
24
+  wrapper: "ConsumeListView_wrapper__wlJjh",
25
+  consumelist: "ConsumeListView_consumelist__2dMCR",
26
+  consumeItem: "ConsumeListView_consumeItem__1QGpJ",
27
+  kingdomIcon: "ConsumeListView_kingdomIcon__1nBe5",
28
+  avatar: "ConsumeListView_avatar__1H-E5",
29
+  gray: "ConsumeListView_gray__3do1I",
30
+  toggle: "ConsumeListView_toggle__3eBTC",
31
+  expand: "ConsumeListView_expand__3l80q"
28 32
 };
29 33
 styleInject_es.styleInject(css);
30 34
 
31
-var DEFAULT_AVATAR = '//links-comment.oss-cn-beijing.aliyuncs.com/comment/20180820/Kgka4_oU1.jpeg';
35
+var DEFAULT_AVATAR =
36
+  "//links-comment.oss-cn-beijing.aliyuncs.com/comment/20180820/Kgka4_oU1.jpeg";
32 37
 
33 38
 var ConsumeListView =
34
-/*#__PURE__*/
35
-function (_Component) {
36
-  inherits._inherits(ConsumeListView, _Component);
39
+  /*#__PURE__*/
40
+  (function(_Component) {
41
+    inherits._inherits(ConsumeListView, _Component);
37 42
 
38
-  function ConsumeListView() {
39
-    inherits._classCallCheck(this, ConsumeListView);
43
+    function ConsumeListView() {
44
+      inherits._classCallCheck(this, ConsumeListView);
40 45
 
41
-    return inherits._possibleConstructorReturn(this, inherits._getPrototypeOf(ConsumeListView).apply(this, arguments));
42
-  }
43
-
44
-  inherits._createClass(ConsumeListView, [{
45
-    key: "renderConsumeItem",
46
-    value: function renderConsumeItem() {
47
-      var _this$props = this.props,
48
-          dataSource = _this$props.dataSource,
49
-          isToggle = _this$props.isToggle,
50
-          onConsumeItemClick = _this$props.onConsumeItemClick,
51
-          showLength = _this$props.showLength,
52
-          listLength = _this$props.listLength,
53
-          options = _this$props.options;
54
-      var kingdomWidth = options.kingdomWidth,
55
-          kingdomHeight = options.kingdomHeight,
56
-          kingdomPosition = options.kingdomPosition,
57
-          avatarSize = options.avatarSize,
58
-          avatarMarginLeftAndRight = options.avatarMarginLeftAndRight;
59
-      var renderData = dataSource;
60
-
61
-      if (!isToggle && listLength > showLength) {
62
-        renderData = dataSource.slice(0, showLength - 1);
63
-      }
46
+      return inherits._possibleConstructorReturn(
47
+        this,
48
+        inherits._getPrototypeOf(ConsumeListView).apply(this, arguments)
49
+      );
50
+    }
64 51
 
65
-      return renderData.map(function (v, i) {
66
-        var kingdom = null;
52
+    inherits._createClass(ConsumeListView, [
53
+      {
54
+        key: "renderConsumeItem",
55
+        value: function renderConsumeItem() {
56
+          var _this$props = this.props,
57
+            dataSource = _this$props.dataSource,
58
+            isToggle = _this$props.isToggle,
59
+            onConsumeItemClick = _this$props.onConsumeItemClick,
60
+            showLength = _this$props.showLength,
61
+            listLength = _this$props.listLength,
62
+            options = _this$props.options;
63
+          var kingdomWidth = options.kingdomWidth,
64
+            kingdomHeight = options.kingdomHeight,
65
+            kingdomPosition = options.kingdomPosition,
66
+            avatarSize = options.avatarSize,
67
+            avatarMarginLeftAndRight = options.avatarMarginLeftAndRight;
68
+          var renderData = dataSource;
69
+
70
+          if (!isToggle && listLength > showLength) {
71
+            renderData = dataSource.slice(0, showLength - 1);
72
+          }
67 73
 
68
-        if (i === 0) {
69
-          kingdom = React__default.createElement("img", {
70
-            className: styles.kingdomIcon,
71
-            src: img,
72
-            alt: "reward top user",
73
-            style: {
74
-              width: "".concat(kingdomWidth, "px"),
75
-              height: "".concat(kingdomHeight, "px"),
76
-              left: "".concat(kingdomPosition[0], "px"),
77
-              top: "".concat(kingdomPosition[1], "px")
74
+          return renderData.map(function(v, i) {
75
+            var kingdom = null;
76
+
77
+            if (i === 0) {
78
+              kingdom = React__default.createElement("img", {
79
+                className: styles.kingdomIcon,
80
+                src: img,
81
+                alt: "reward top user",
82
+                style: {
83
+                  width: "".concat(kingdomWidth, "px"),
84
+                  height: "".concat(kingdomHeight, "px"),
85
+                  left: "".concat(kingdomPosition[0], "px"),
86
+                  top: "".concat(kingdomPosition[1], "px")
87
+                }
88
+              });
78 89
             }
90
+
91
+            return React__default.createElement(
92
+              "li",
93
+              {
94
+                key: v.id,
95
+                className: styles.consumeItem,
96
+                style: {
97
+                  margin: "0 ".concat(avatarMarginLeftAndRight, "px 10px")
98
+                }
99
+              },
100
+              kingdom,
101
+              React__default.createElement("div", {
102
+                className: styles.avatar,
103
+                onClick: function onClick(e) {
104
+                  return onConsumeItemClick(e, v);
105
+                },
106
+                style: {
107
+                  backgroundImage: "url(".concat(
108
+                    utils.addImageProcess(v.user_avatar || DEFAULT_AVATAR, {
109
+                      small: true
110
+                    }),
111
+                    ")"
112
+                  ),
113
+                  width: "".concat(avatarSize, "px"),
114
+                  height: "".concat(avatarSize, "px")
115
+                }
116
+              }),
117
+              React__default.createElement("span", {
118
+                className: styles.gray
119
+              })
120
+            );
79 121
           });
80 122
         }
81
-
82
-        return React__default.createElement("li", {
83
-          key: v.id,
84
-          className: styles.consumeItem,
85
-          style: {
86
-            margin: "0 ".concat(avatarMarginLeftAndRight, "px 10px")
87
-          }
88
-        }, kingdom, React__default.createElement("div", {
89
-          className: styles.avatar,
90
-          onClick: function onClick(e) {
91
-            return onConsumeItemClick(e, v);
92
-          },
93
-          style: {
94
-            backgroundImage: "url(".concat(utils.addImageProcess(v.user_avatar || DEFAULT_AVATAR, {
95
-              small: true
96
-            }), ")"),
97
-            width: "".concat(avatarSize, "px"),
98
-            height: "".concat(avatarSize, "px")
123
+      },
124
+      {
125
+        key: "renderToggleButton",
126
+        value: function renderToggleButton() {
127
+          var _this$props2 = this.props,
128
+            isToggle = _this$props2.isToggle,
129
+            onToggleChange = _this$props2.onToggleChange,
130
+            listLength = _this$props2.listLength,
131
+            showLength = _this$props2.showLength,
132
+            options = _this$props2.options;
133
+          var avatarSize = options.avatarSize,
134
+            avatarMarginLeftAndRight = options.avatarMarginLeftAndRight;
135
+
136
+          if (listLength <= showLength) {
137
+            return null;
99 138
           }
100
-        }), React__default.createElement("span", {
101
-          className: styles.gray
102
-        }));
103
-      });
104
-    }
105
-  }, {
106
-    key: "renderToggleButton",
107
-    value: function renderToggleButton() {
108
-      var _this$props2 = this.props,
109
-          isToggle = _this$props2.isToggle,
110
-          onToggleChange = _this$props2.onToggleChange,
111
-          listLength = _this$props2.listLength,
112
-          showLength = _this$props2.showLength,
113
-          options = _this$props2.options;
114
-      var avatarSize = options.avatarSize,
115
-          avatarMarginLeftAndRight = options.avatarMarginLeftAndRight;
116
-
117
-      if (listLength <= showLength) {
118
-        return null;
119
-      }
120 139
 
121
-      return React__default.createElement("li", {
122
-        onClick: function onClick() {
123
-          return onToggleChange();
124
-        },
125
-        className: index.classnames(styles.toggle, defineProperty._defineProperty({}, styles.expand, isToggle)),
126
-        style: {
127
-          width: "".concat(avatarSize, "px"),
128
-          height: "".concat(avatarSize, "px"),
129
-          lineHeight: "".concat(avatarSize, "px"),
130
-          margin: "0 ".concat(avatarMarginLeftAndRight, "px 10px")
140
+          return React__default.createElement("li", {
141
+            onClick: function onClick() {
142
+              return onToggleChange();
143
+            },
144
+            className: index.classnames(
145
+              styles.toggle,
146
+              defineProperty._defineProperty({}, styles.expand, isToggle)
147
+            ),
148
+            style: {
149
+              width: "".concat(avatarSize, "px"),
150
+              height: "".concat(avatarSize, "px"),
151
+              lineHeight: "".concat(avatarSize, "px"),
152
+              margin: "0 ".concat(avatarMarginLeftAndRight, "px 10px")
153
+            }
154
+          });
131 155
         }
132
-      });
133
-    }
134
-  }, {
135
-    key: "render",
136
-    value: function render() {
137
-      var _this$props3 = this.props,
138
-          showLength = _this$props3.showLength,
139
-          options = _this$props3.options;
140
-      var avatarSize = options.avatarSize,
141
-          avatarMarginLeftAndRight = options.avatarMarginLeftAndRight;
142
-      return React__default.createElement("div", {
143
-        className: styles.wrapper
144
-      }, React__default.createElement("ul", {
145
-        className: styles.consumelist,
146
-        style: {
147
-          width: "calc(".concat(avatarMarginLeftAndRight * 2 + avatarSize, "px * ").concat(showLength, ")")
156
+      },
157
+      {
158
+        key: "render",
159
+        value: function render() {
160
+          var _this$props3 = this.props,
161
+            showLength = _this$props3.showLength,
162
+            options = _this$props3.options;
163
+          var avatarSize = options.avatarSize,
164
+            avatarMarginLeftAndRight = options.avatarMarginLeftAndRight;
165
+          return React__default.createElement(
166
+            "div",
167
+            {
168
+              className: styles.wrapper
169
+            },
170
+            React__default.createElement(
171
+              "ul",
172
+              {
173
+                className: styles.consumelist,
174
+                style: {
175
+                  width: "calc("
176
+                    .concat(avatarMarginLeftAndRight * 2 + avatarSize, "px * ")
177
+                    .concat(showLength, ")")
178
+                }
179
+              },
180
+              this.renderConsumeItem(),
181
+              this.renderToggleButton()
182
+            )
183
+          );
148 184
         }
149
-      }, this.renderConsumeItem(), this.renderToggleButton()));
150
-    }
151
-  }]);
185
+      }
186
+    ]);
152 187
 
153
-  return ConsumeListView;
154
-}(React.Component);
188
+    return ConsumeListView;
189
+  })(React.Component);
155 190
 
156 191
 ConsumeListView.defaultProps = {
157 192
   isToggle: false,

+ 1
- 1
lib/ConsumeListView/index.js.map
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 9
- 11
lib/Editor/index.js Ver arquivo

@@ -1,16 +1,14 @@
1
-'use strict';
2
-
3
-Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
-require('react');
6
-require('react-dom');
7
-require('../style-inject.es-dcee06b6.js');
8
-require('../_commonjsHelpers-72d386ba.js');
9
-require('../slicedToArray-172f4624.js');
10
-var BraftEditor = require('../BraftEditor/index.js');
11
-require('react-dom/server');
1
+"use strict";
12 2
 
3
+Object.defineProperty(exports, "__esModule", { value: true });
13 4
 
5
+require("react");
6
+require("react-dom");
7
+require("../style-inject.es-dcee06b6.js");
8
+require("../_commonjsHelpers-72d386ba.js");
9
+require("../slicedToArray-172f4624.js");
10
+var BraftEditor = require("../BraftEditor/index.js");
11
+require("react-dom/server");
14 12
 
15 13
 exports.BraftEditor = BraftEditor.default;
16 14
 //# sourceMappingURL=index.js.map

+ 6
- 6
lib/Modal/index.d.ts Ver arquivo

@@ -1,12 +1,12 @@
1 1
 /// <reference types="react" />
2
-import React from 'react';
2
+import React from "react";
3 3
 interface ModalProps {
4
-    visible: boolean;
5
-    onCancel: (e: any) => void;
6
-    container?: HTMLElement | null;
4
+  visible: boolean;
5
+  onCancel: (e: any) => void;
6
+  container?: HTMLElement | null;
7 7
 }
8 8
 declare class Modal extends React.PureComponent<ModalProps> {
9
-    static hasShowWarning: boolean;
10
-    render(): false | React.ReactPortal | null;
9
+  static hasShowWarning: boolean;
10
+  render(): false | React.ReactPortal | null;
11 11
 }
12 12
 export { Modal as default, Modal, ModalProps };

+ 84
- 55
lib/Modal/index.js Ver arquivo

@@ -1,82 +1,111 @@
1
-'use strict';
1
+"use strict";
2 2
 
3
-Object.defineProperty(exports, '__esModule', { value: true });
3
+Object.defineProperty(exports, "__esModule", { value: true });
4 4
 
5
-function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
5
+function _interopDefault(ex) {
6
+  return ex && typeof ex === "object" && "default" in ex ? ex["default"] : ex;
7
+}
6 8
 
7
-var inherits = require('../inherits-c86d64c1.js');
8
-var React = require('react');
9
+var inherits = require("../inherits-c86d64c1.js");
10
+var React = require("react");
9 11
 var React__default = _interopDefault(React);
10
-var reactDom = require('react-dom');
12
+var reactDom = require("react-dom");
11 13
 var reactDom__default = _interopDefault(reactDom);
12
-var styleInject_es = require('../style-inject.es-dcee06b6.js');
14
+var styleInject_es = require("../style-inject.es-dcee06b6.js");
13 15
 
14 16
 function isBrowser() {
15
-  return !((typeof window === "undefined" ? "undefined" : inherits._typeof(window)) === undefined);
17
+  return !(
18
+    (typeof window === "undefined" ? "undefined" : inherits._typeof(window)) ===
19
+    undefined
20
+  );
16 21
 }
17 22
 
18
-var css = ".Modal_wrapper__2hzaC {\n  position: fixed;\n  width: 100vw;\n  height: 100vh;\n  top: 0;\n  left: 0;\n  z-index: 1000;\n}\n.Modal_overlay__3iNdm {\n  width: 100vw;\n  height: 100vh;\n  background: #000;\n  animation: Modal_overlayer__1zSH9 0.3s forwards;\n}\n.Modal_container__2veos {\n  position: absolute;\n  top: 20%;\n  left: 50%;\n  animation: Modal_container__2veos 0.3s forwards;\n}\n@keyframes Modal_overlayer__1zSH9 {\n  from {\n    opacity: 0;\n  }\n  to {\n    opacity: 0.3;\n  }\n}\n@keyframes Modal_container__2veos {\n  from {\n    transform: translateX(-50%) scale(0, 0);\n  }\n  to {\n    transform: translateX(-50%) scale(1, 1);\n  }\n}\n";
23
+var css =
24
+  ".Modal_wrapper__2hzaC {\n  position: fixed;\n  width: 100vw;\n  height: 100vh;\n  top: 0;\n  left: 0;\n  z-index: 1000;\n}\n.Modal_overlay__3iNdm {\n  width: 100vw;\n  height: 100vh;\n  background: #000;\n  animation: Modal_overlayer__1zSH9 0.3s forwards;\n}\n.Modal_container__2veos {\n  position: absolute;\n  top: 20%;\n  left: 50%;\n  animation: Modal_container__2veos 0.3s forwards;\n}\n@keyframes Modal_overlayer__1zSH9 {\n  from {\n    opacity: 0;\n  }\n  to {\n    opacity: 0.3;\n  }\n}\n@keyframes Modal_container__2veos {\n  from {\n    transform: translateX(-50%) scale(0, 0);\n  }\n  to {\n    transform: translateX(-50%) scale(1, 1);\n  }\n}\n";
19 25
 var styles = {
20
-  "wrapper": "Modal_wrapper__2hzaC",
21
-  "overlay": "Modal_overlay__3iNdm",
22
-  "overlayer": "Modal_overlayer__1zSH9",
23
-  "container": "Modal_container__2veos"
26
+  wrapper: "Modal_wrapper__2hzaC",
27
+  overlay: "Modal_overlay__3iNdm",
28
+  overlayer: "Modal_overlayer__1zSH9",
29
+  container: "Modal_container__2veos"
24 30
 };
25 31
 styleInject_es.styleInject(css);
26 32
 
27 33
 var Modal =
28
-/*#__PURE__*/
29
-function (_React$PureComponent) {
30
-  inherits._inherits(Modal, _React$PureComponent);
34
+  /*#__PURE__*/
35
+  (function(_React$PureComponent) {
36
+    inherits._inherits(Modal, _React$PureComponent);
31 37
 
32
-  function Modal() {
33
-    inherits._classCallCheck(this, Modal);
38
+    function Modal() {
39
+      inherits._classCallCheck(this, Modal);
34 40
 
35
-    return inherits._possibleConstructorReturn(this, inherits._getPrototypeOf(Modal).apply(this, arguments));
36
-  }
41
+      return inherits._possibleConstructorReturn(
42
+        this,
43
+        inherits._getPrototypeOf(Modal).apply(this, arguments)
44
+      );
45
+    }
37 46
 
38
-  inherits._createClass(Modal, [{
39
-    key: "render",
40
-    value: function render() {
41
-      if (!isBrowser()) return null;
42
-      var DEFAULT_CONTAINER = document.getElementById('container');
43
-      var _this$props = this.props,
44
-          children = _this$props.children,
45
-          visible = _this$props.visible,
46
-          onCancel = _this$props.onCancel,
47
-          _this$props$container = _this$props.container,
48
-          container = _this$props$container === void 0 ? DEFAULT_CONTAINER : _this$props$container;
49
-      var finalMountContainer = document.body;
47
+    inherits._createClass(Modal, [
48
+      {
49
+        key: "render",
50
+        value: function render() {
51
+          if (!isBrowser()) return null;
52
+          var DEFAULT_CONTAINER = document.getElementById("container");
53
+          var _this$props = this.props,
54
+            children = _this$props.children,
55
+            visible = _this$props.visible,
56
+            onCancel = _this$props.onCancel,
57
+            _this$props$container = _this$props.container,
58
+            container =
59
+              _this$props$container === void 0
60
+                ? DEFAULT_CONTAINER
61
+                : _this$props$container;
62
+          var finalMountContainer = document.body;
50 63
 
51
-      if (!container) {
52
-        if (!DEFAULT_CONTAINER) {
53
-          if (!Modal.hasShowWarning) {
54
-            Modal.hasShowWarning = true;
55
-          }
64
+          if (!container) {
65
+            if (!DEFAULT_CONTAINER) {
66
+              if (!Modal.hasShowWarning) {
67
+                Modal.hasShowWarning = true;
68
+              }
56 69
 
57
-          finalMountContainer = document.body;
58
-        } else {
59
-          if (!Modal.hasShowWarning) {
60
-            Modal.hasShowWarning = true;
70
+              finalMountContainer = document.body;
71
+            } else {
72
+              if (!Modal.hasShowWarning) {
73
+                Modal.hasShowWarning = true;
74
+              }
75
+
76
+              finalMountContainer = DEFAULT_CONTAINER;
77
+            }
61 78
           }
62 79
 
63
-          finalMountContainer = DEFAULT_CONTAINER;
80
+          return (
81
+            visible &&
82
+            reactDom.createPortal(
83
+              React__default.createElement(
84
+                "div",
85
+                {
86
+                  className: styles.wrapper
87
+                },
88
+                React__default.createElement("div", {
89
+                  className: styles.overlay,
90
+                  onClick: onCancel
91
+                }),
92
+                React__default.createElement(
93
+                  "div",
94
+                  {
95
+                    className: styles.container
96
+                  },
97
+                  children
98
+                )
99
+              ),
100
+              finalMountContainer
101
+            )
102
+          );
64 103
         }
65 104
       }
105
+    ]);
66 106
 
67
-      return visible && reactDom.createPortal(React__default.createElement("div", {
68
-        className: styles.wrapper
69
-      }, React__default.createElement("div", {
70
-        className: styles.overlay,
71
-        onClick: onCancel
72
-      }), React__default.createElement("div", {
73
-        className: styles.container
74
-      }, children)), finalMountContainer);
75
-    }
76
-  }]);
77
-
78
-  return Modal;
79
-}(React__default.PureComponent);
107
+    return Modal;
108
+  })(React__default.PureComponent);
80 109
 Modal.hasShowWarning = false;
81 110
 
82 111
 exports.Modal = Modal;

+ 1
- 1
lib/Modal/index.js.map Ver arquivo

@@ -1 +1 @@
1
-{"version":3,"file":"index.js","sources":["../../src/components/Common/Utils/utils.ts","../../src/components/Common/Modal/index.tsx"],"sourcesContent":["export function isBrowser() {\r\n  return !(typeof window === undefined);\r\n}","import React from 'react';\r\nimport { createPortal } from 'react-dom';\r\nimport { isBrowser } from '../Utils/utils';\r\n\r\nimport styles from './Modal.less';\r\n\r\nexport interface ModalProps {\r\n  visible: boolean\r\n  onCancel: (e: any) => void\r\n  container?: HTMLElement | null\r\n}\r\n\r\nexport class Modal extends React.PureComponent<ModalProps> {\r\n  static hasShowWarning = false;\r\n\r\n  render() {\r\n    if (!isBrowser()) return null; // 服务端无需渲染下列代码,渲染也会出错\r\n    const DEFAULT_CONTAINER: HTMLElement | null = document.getElementById('container');\r\n    const { children, visible, onCancel, container = DEFAULT_CONTAINER } = this.props\r\n    let finalMountContainer: HTMLElement = document.body;\r\n    if (!container) {\r\n      if (!DEFAULT_CONTAINER) {\r\n        if (!Modal.hasShowWarning) {\r\n          Modal.hasShowWarning = true;\r\n        }\r\n        finalMountContainer = document.body;\r\n      } else {\r\n        if (!Modal.hasShowWarning) {\r\n          Modal.hasShowWarning = true;\r\n        }\r\n        finalMountContainer = DEFAULT_CONTAINER;\r\n      }\r\n    }\r\n    return visible && createPortal(\r\n      <div className={ styles.wrapper }>\r\n        <div\r\n          className={ styles.overlay }\r\n          onClick={ onCancel }\r\n        />\r\n        <div\r\n          className={ styles.container }\r\n        >\r\n          { children }\r\n        </div>\r\n      </div>,\r\n      finalMountContainer,\r\n    )\r\n  }\r\n}\r\n\r\nexport default Modal;"],"names":["isBrowser","window","undefined","Modal","DEFAULT_CONTAINER","document","getElementById","props","children","visible","onCancel","container","finalMountContainer","body","hasShowWarning","createPortal","React","createElement","className","styles","wrapper","overlay","onClick","PureComponent"],"mappings":";;;;;;;;;;;;;AAAM,SAAUA,SAAV,GAAmB;SAChB,EAAE,QAAOC,wDAAAA,OAAP,MAAkBC,SAApB;;;;;;;;;;;;ICWIC,KAAb;AAAA;AAAA,8BAAA;;;;;;;;;;;6BAGQ;UACA,CAACH,SAAS,IAAI,OAAO,IAAP;UACZI,iBAAiB,GAAuBC,QAAQ,CAACC,cAAT,CAAwB,WAAxB;wBACyB,KAAKC;UAApEC,QAHJ,eAGIA;UAAUC,OAHd,eAGcA;UAASC,QAHvB,eAGuBA;8CAAUC;UAAAA,SAHjC,sCAG6CP;UAC7CQ,mBAAmB,GAAgBP,QAAQ,CAACQ;;UAC5C,CAACF,WAAW;YACV,CAACP,mBAAmB;cAClB,CAACD,KAAK,CAACW,gBAAgB;AACzBX,YAAAA,KAAK,CAACW,cAAN,GAAuB,IAAvB;;;AAEFF,UAAAA,mBAAmB,GAAGP,QAAQ,CAACQ,IAA/B;AAJF,eAKO;cACD,CAACV,KAAK,CAACW,gBAAgB;AACzBX,YAAAA,KAAK,CAACW,cAAN,GAAuB,IAAvB;;;AAEFF,UAAAA,mBAAmB,GAAGR,iBAAtB;;;;aAGGK,OAAO,IAAIM,qBAAY,CAC5BC,cAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AAAKC,QAAAA,SAAS,EAAGC,MAAM,CAACC;AAAxB,OAAA,EACEJ,cAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AACEC,QAAAA,SAAS,EAAGC,MAAM,CAACE,OADrB;AAEEC,QAAAA,OAAO,EAAGZ;AAFZ,OAAA,CADF,EAKEM,cAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AACEC,QAAAA,SAAS,EAAGC,MAAM,CAACR;AADrB,OAAA,EAGIH,QAHJ,CALF,CAD4B,EAY5BI,mBAZ4B;;;;;CArBlC,CAA2BI,cAAK,CAACO,aAAjC;AACSpB,KAAA,CAAAW,cAAA,GAAiB,KAAjB;;;;;"}
1
+{"version":3,"file":"index.js","sources":["../../src/components/Common/Utils/utils.ts","../../src/components/Common/Modal/index.tsx"],"sourcesContent":["export function isBrowser() {\n  return !(typeof window === undefined);\n}","import React from 'react';\nimport { createPortal } from 'react-dom';\nimport { isBrowser } from '../Utils/utils';\n\nimport styles from './Modal.less';\n\nexport interface ModalProps {\n  visible: boolean\n  onCancel: (e: any) => void\n  container?: HTMLElement | null\n}\n\nexport class Modal extends React.PureComponent<ModalProps> {\n  static hasShowWarning = false;\n\n  render() {\n    if (!isBrowser()) return null; // 服务端无需渲染下列代码,渲染也会出错\n    const DEFAULT_CONTAINER: HTMLElement | null = document.getElementById('container');\n    const { children, visible, onCancel, container = DEFAULT_CONTAINER } = this.props\n    let finalMountContainer: HTMLElement = document.body;\n    if (!container) {\n      if (!DEFAULT_CONTAINER) {\n        if (!Modal.hasShowWarning) {\n          Modal.hasShowWarning = true;\n        }\n        finalMountContainer = document.body;\n      } else {\n        if (!Modal.hasShowWarning) {\n          Modal.hasShowWarning = true;\n        }\n        finalMountContainer = DEFAULT_CONTAINER;\n      }\n    }\n    return visible && createPortal(\n      <div className={ styles.wrapper }>\n        <div\n          className={ styles.overlay }\n          onClick={ onCancel }\n        />\n        <div\n          className={ styles.container }\n        >\n          { children }\n        </div>\n      </div>,\n      finalMountContainer,\n    )\n  }\n}\n\nexport default Modal;"],"names":["isBrowser","window","undefined","Modal","DEFAULT_CONTAINER","document","getElementById","props","children","visible","onCancel","container","finalMountContainer","body","hasShowWarning","createPortal","React","createElement","className","styles","wrapper","overlay","onClick","PureComponent"],"mappings":";;;;;;;;;;;;;AAAM,SAAUA,SAAV,GAAmB;SAChB,EAAE,QAAOC,wDAAAA,OAAP,MAAkBC,SAApB;;;;;;;;;;;;ICWIC,KAAb;AAAA;AAAA,8BAAA;;;;;;;;;;;6BAGQ;UACA,CAACH,SAAS,IAAI,OAAO,IAAP;UACZI,iBAAiB,GAAuBC,QAAQ,CAACC,cAAT,CAAwB,WAAxB;wBACyB,KAAKC;UAApEC,QAHJ,eAGIA;UAAUC,OAHd,eAGcA;UAASC,QAHvB,eAGuBA;8CAAUC;UAAAA,SAHjC,sCAG6CP;UAC7CQ,mBAAmB,GAAgBP,QAAQ,CAACQ;;UAC5C,CAACF,WAAW;YACV,CAACP,mBAAmB;cAClB,CAACD,KAAK,CAACW,gBAAgB;AACzBX,YAAAA,KAAK,CAACW,cAAN,GAAuB,IAAvB;;;AAEFF,UAAAA,mBAAmB,GAAGP,QAAQ,CAACQ,IAA/B;AAJF,eAKO;cACD,CAACV,KAAK,CAACW,gBAAgB;AACzBX,YAAAA,KAAK,CAACW,cAAN,GAAuB,IAAvB;;;AAEFF,UAAAA,mBAAmB,GAAGR,iBAAtB;;;;aAGGK,OAAO,IAAIM,qBAAY,CAC5BC,cAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AAAKC,QAAAA,SAAS,EAAGC,MAAM,CAACC;AAAxB,OAAA,EACEJ,cAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AACEC,QAAAA,SAAS,EAAGC,MAAM,CAACE,OADrB;AAEEC,QAAAA,OAAO,EAAGZ;AAFZ,OAAA,CADF,EAKEM,cAAA,CAAAC,aAAA,CAAA,KAAA,EAAA;AACEC,QAAAA,SAAS,EAAGC,MAAM,CAACR;AADrB,OAAA,EAGIH,QAHJ,CALF,CAD4B,EAY5BI,mBAZ4B;;;;;CArBlC,CAA2BI,cAAK,CAACO,aAAjC;AACSpB,KAAA,CAAAW,cAAA,GAAiB,KAAjB;;;;;"}

+ 35
- 18
lib/PayPlatformOptions/index.d.ts Ver arquivo

@@ -1,28 +1,45 @@
1 1
 /// <reference types="react" />
2
-type PAY_CHANNEL_VALUE = "PAYPAL_PAYPAL" | "ALI_WEB" | "ALI_WAP" | "WX_WAP" | "WX_NATIVE";
2
+type PAY_CHANNEL_VALUE =
3
+  | "PAYPAL_PAYPAL"
4
+  | "ALI_WEB"
5
+  | "ALI_WAP"
6
+  | "WX_WAP"
7
+  | "WX_NATIVE";
3 8
 type PAY_CHANNEL_CATEGORY_VALUE = "Alipay" | "Wechat" | "Paypal";
4 9
 interface PAY_CHANNEL_TYPE {
5
-    PAYPAL: PAY_CHANNEL_VALUE;
6
-    ALI_WEB: PAY_CHANNEL_VALUE;
7
-    ALI_WAP: PAY_CHANNEL_VALUE;
8
-    WX_WAP: PAY_CHANNEL_VALUE;
9
-    WX_NATIVE: PAY_CHANNEL_VALUE;
10
+  PAYPAL: PAY_CHANNEL_VALUE;
11
+  ALI_WEB: PAY_CHANNEL_VALUE;
12
+  ALI_WAP: PAY_CHANNEL_VALUE;
13
+  WX_WAP: PAY_CHANNEL_VALUE;
14
+  WX_NATIVE: PAY_CHANNEL_VALUE;
10 15
 }
11 16
 interface PAY_CHANNEL_CATEGORY {
12
-    ALI: PAY_CHANNEL_CATEGORY_VALUE;
13
-    WX: PAY_CHANNEL_CATEGORY_VALUE;
14
-    PAYPAL: PAY_CHANNEL_CATEGORY_VALUE;
17
+  ALI: PAY_CHANNEL_CATEGORY_VALUE;
18
+  WX: PAY_CHANNEL_CATEGORY_VALUE;
19
+  PAYPAL: PAY_CHANNEL_CATEGORY_VALUE;
15 20
 }
16 21
 interface Props {
17
-    payChannel: PAY_CHANNEL_VALUE;
18
-    onPayChannelChange: (value: PAY_CHANNEL_VALUE) => void;
19
-    isMobile: boolean;
20
-    size: "small" | "normal" | "large";
21
-    withTitle: boolean;
22
-    titleText?: string;
23
-    locale: "zh" | "en";
22
+  payChannel: PAY_CHANNEL_VALUE;
23
+  onPayChannelChange: (value: PAY_CHANNEL_VALUE) => void;
24
+  isMobile: boolean;
25
+  size: "small" | "normal" | "large";
26
+  withTitle: boolean;
27
+  titleText?: string;
28
+  locale: "zh" | "en";
24 29
 }
25 30
 declare const PAY_CHANNEL: PAY_CHANNEL_TYPE;
26 31
 declare const PAY_CHANNEL_CATEGORY$0: PAY_CHANNEL_CATEGORY;
27
-declare const PayPlatformOptions: ({ payChannel, onPayChannelChange, size, isMobile, withTitle, titleText, locale }: Props) => JSX.Element;
28
-export { PayPlatformOptions as default, PAY_CHANNEL, PAY_CHANNEL_CATEGORY$0 as PAY_CHANNEL_CATEGORY };
32
+declare const PayPlatformOptions: ({
33
+  payChannel,
34
+  onPayChannelChange,
35
+  size,
36
+  isMobile,
37
+  withTitle,
38
+  titleText,
39
+  locale
40
+}: Props) => JSX.Element;
41
+export {
42
+  PayPlatformOptions as default,
43
+  PAY_CHANNEL,
44
+  PAY_CHANNEL_CATEGORY$0 as PAY_CHANNEL_CATEGORY
45
+};

+ 228
- 143
lib/PayPlatformOptions/index.js
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 1
- 1
lib/PayPlatformOptions/index.js.map
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 20
- 22
lib/Payment/index.js Ver arquivo

@@ -1,27 +1,25 @@
1
-'use strict';
2
-
3
-Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
-require('../inherits-c86d64c1.js');
6
-require('react');
7
-require('react-dom');
8
-require('../Modal/index.js');
9
-require('../style-inject.es-dcee06b6.js');
10
-require('../defineProperty-ba7cd53d.js');
11
-require('../_commonjsHelpers-72d386ba.js');
12
-require('../index-44e17595.js');
13
-require('../utils-b800dc99.js');
14
-var ConsumeListView = require('../ConsumeListView/index.js');
15
-var PayPlatformOptions = require('../PayPlatformOptions/index.js');
16
-require('../slicedToArray-172f4624.js');
17
-require('antd');
18
-var PriceOptions = require('../PriceOptions/index.js');
19
-var WaitPayInfoView = require('../WaitPayInfoView/index.js');
20
-var AllocWantedModal = require('../AllocWantedModal/index.js');
21
-var WantedPublishView = require('../WantedPublishView/index.js');
22
-var WantedPublishPopover = require('../WantedPublishPopover/index.js');
1
+"use strict";
23 2
 
3
+Object.defineProperty(exports, "__esModule", { value: true });
24 4
 
5
+require("../inherits-c86d64c1.js");
6
+require("react");
7
+require("react-dom");
8
+require("../Modal/index.js");
9
+require("../style-inject.es-dcee06b6.js");
10
+require("../defineProperty-ba7cd53d.js");
11
+require("../_commonjsHelpers-72d386ba.js");
12
+require("../index-44e17595.js");
13
+require("../utils-b800dc99.js");
14
+var ConsumeListView = require("../ConsumeListView/index.js");
15
+var PayPlatformOptions = require("../PayPlatformOptions/index.js");
16
+require("../slicedToArray-172f4624.js");
17
+require("antd");
18
+var PriceOptions = require("../PriceOptions/index.js");
19
+var WaitPayInfoView = require("../WaitPayInfoView/index.js");
20
+var AllocWantedModal = require("../AllocWantedModal/index.js");
21
+var WantedPublishView = require("../WantedPublishView/index.js");
22
+var WantedPublishPopover = require("../WantedPublishPopover/index.js");
25 23
 
26 24
 exports.ConsumeListView = ConsumeListView.default;
27 25
 exports.PayPlatformOptions = PayPlatformOptions.default;

+ 33
- 18
lib/PriceOptions/index.d.ts Ver arquivo

@@ -1,23 +1,38 @@
1 1
 /// <reference types="react" />
2 2
 import React from "react";
3 3
 interface Props {
4
-    rowMode: "single" | "multi";
5
-    price: number;
6
-    onPriceChange: (v: number) => void;
7
-    size: "small" | "normal" | "large";
8
-    focusScroll: boolean;
9
-    withTitle: boolean;
10
-    titleText?: string | JSX.Element[] | JSX.Element;
11
-    inputPlaceholderText?: string;
12
-    priceOptions?: Array<any>;
13
-    priceRender?: Function;
14
-    inputPriceRender?: Function;
15
-    inputSuffix?: string | JSX.Element[] | JSX.Element;
16
-    injectOptions?: {
17
-        priceBtnClass: (isActive: boolean) => any;
18
-        priceInputClass: Function;
19
-    };
20
-    inputRef: React.RefObject<any>;
4
+  rowMode: "single" | "multi";
5
+  price: number;
6
+  onPriceChange: (v: number) => void;
7
+  size: "small" | "normal" | "large";
8
+  focusScroll: boolean;
9
+  withTitle: boolean;
10
+  titleText?: string | JSX.Element[] | JSX.Element;
11
+  inputPlaceholderText?: string;
12
+  priceOptions?: Array<any>;
13
+  priceRender?: Function;
14
+  inputPriceRender?: Function;
15
+  inputSuffix?: string | JSX.Element[] | JSX.Element;
16
+  injectOptions?: {
17
+    priceBtnClass: (isActive: boolean) => any;
18
+    priceInputClass: Function;
19
+  };
20
+  inputRef: React.RefObject<any>;
21 21
 }
22
-declare const PriceOptions: ({ price, onPriceChange, rowMode, size, focusScroll, withTitle, titleText, inputPlaceholderText, priceOptions, priceRender, inputPriceRender, inputSuffix, injectOptions, inputRef }: Props) => JSX.Element;
22
+declare const PriceOptions: ({
23
+  price,
24
+  onPriceChange,
25
+  rowMode,
26
+  size,
27
+  focusScroll,
28
+  withTitle,
29
+  titleText,
30
+  inputPlaceholderText,
31
+  priceOptions,
32
+  priceRender,
33
+  inputPriceRender,
34
+  inputSuffix,
35
+  injectOptions,
36
+  inputRef
37
+}: Props) => JSX.Element;
23 38
 export { PriceOptions as default };

+ 201
- 139
lib/PriceOptions/index.js Ver arquivo

@@ -1,29 +1,32 @@
1
-'use strict';
1
+"use strict";
2 2
 
3
-Object.defineProperty(exports, '__esModule', { value: true });
3
+Object.defineProperty(exports, "__esModule", { value: true });
4 4
 
5
-function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
5
+function _interopDefault(ex) {
6
+  return ex && typeof ex === "object" && "default" in ex ? ex["default"] : ex;
7
+}
6 8
 
7
-var React = require('react');
9
+var React = require("react");
8 10
 var React__default = _interopDefault(React);
9
-var styleInject_es = require('../style-inject.es-dcee06b6.js');
10
-var defineProperty = require('../defineProperty-ba7cd53d.js');
11
-require('../_commonjsHelpers-72d386ba.js');
12
-var index = require('../index-44e17595.js');
13
-var utils = require('../utils-b800dc99.js');
14
-var slicedToArray = require('../slicedToArray-172f4624.js');
15
-var antd = require('antd');
16
-
17
-var css = ".PriceOptions_options__ifYbC p {\n  font-size: 14px;\n  font-weight: 400;\n  color: #616a79;\n  margin-bottom: 20px;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx {\n  padding-right: 0;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx .PriceOptions_priceItem__3CPe3 {\n  background: rgba(243, 243, 243, 0.14);\n  border-radius: 4px;\n  border: 1px solid #cfcfcf;\n  font-size: 14px;\n  font-weight: 600;\n  color: #616a79;\n  display: inline-block;\n  text-align: center;\n  vertical-align: top;\n  height: 30px;\n  width: 70px;\n  line-height: 30px;\n  cursor: pointer;\n  margin: 6px;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx .PriceOptions_priceItem__3CPe3.PriceOptions_active__154by {\n  background: rgba(255, 50, 102, 0.1);\n  border-radius: 4px;\n  border: 1px solid #ff3266;\n  color: #616a79;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx .PriceOptions_priceInput__2JFc0 {\n  display: inline-block;\n  min-width: 70px;\n  height: 72px;\n  width: auto;\n  margin: 6px;\n  text-align: center;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx button {\n  border-top-left-radius: 0;\n  border-bottom-left-radius: 0;\n  height: 30px;\n  width: 50px;\n  vertical-align: top;\n  padding: 0 5px;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx .PriceOptions_rate__17U-9 {\n  margin-left: 10px;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx .PriceOptions_rate__17U-9 i {\n  margin-right: 5px;\n  color: #1790FF;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z p {\n  font-size: 14px;\n  font-weight: 400;\n  color: #616a79;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z .PriceOptions_infoItem__246mx {\n  padding-right: 0;\n  display: flex;\n  flex-direction: column;\n  justify-content: center;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z .PriceOptions_infoItem__246mx .PriceOptions_priceBtn__1UaE8 {\n  display: flex;\n  justify-content: space-between;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z .PriceOptions_infoItem__246mx .PriceOptions_priceItem__3CPe3 {\n  display: inline-block;\n  background-color: #fff;\n  border-radius: 4px;\n  border: 1px solid #cfcfcf;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z .PriceOptions_infoItem__246mx .PriceOptions_priceItem__3CPe3.PriceOptions_active__154by {\n  background-color: #fff;\n  color: #FF3266FF;\n  border: 1px solid #ff3266;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z .PriceOptions_infoItem__246mx .PriceOptions_priceInput__2JFc0 {\n  width: 222px;\n  width: auto;\n}\n";
11
+var styleInject_es = require("../style-inject.es-dcee06b6.js");
12
+var defineProperty = require("../defineProperty-ba7cd53d.js");
13
+require("../_commonjsHelpers-72d386ba.js");
14
+var index = require("../index-44e17595.js");
15
+var utils = require("../utils-b800dc99.js");
16
+var slicedToArray = require("../slicedToArray-172f4624.js");
17
+var antd = require("antd");
18
+
19
+var css =
20
+  ".PriceOptions_options__ifYbC p {\n  font-size: 14px;\n  font-weight: 400;\n  color: #616a79;\n  margin-bottom: 20px;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx {\n  padding-right: 0;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx .PriceOptions_priceItem__3CPe3 {\n  background: rgba(243, 243, 243, 0.14);\n  border-radius: 4px;\n  border: 1px solid #cfcfcf;\n  font-size: 14px;\n  font-weight: 600;\n  color: #616a79;\n  display: inline-block;\n  text-align: center;\n  vertical-align: top;\n  height: 30px;\n  width: 70px;\n  line-height: 30px;\n  cursor: pointer;\n  margin: 6px;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx .PriceOptions_priceItem__3CPe3.PriceOptions_active__154by {\n  background: rgba(255, 50, 102, 0.1);\n  border-radius: 4px;\n  border: 1px solid #ff3266;\n  color: #616a79;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx .PriceOptions_priceInput__2JFc0 {\n  display: inline-block;\n  min-width: 70px;\n  height: 72px;\n  width: auto;\n  margin: 6px;\n  text-align: center;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx button {\n  border-top-left-radius: 0;\n  border-bottom-left-radius: 0;\n  height: 30px;\n  width: 50px;\n  vertical-align: top;\n  padding: 0 5px;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx .PriceOptions_rate__17U-9 {\n  margin-left: 10px;\n}\n.PriceOptions_options__ifYbC .PriceOptions_infoItem__246mx .PriceOptions_rate__17U-9 i {\n  margin-right: 5px;\n  color: #1790FF;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z p {\n  font-size: 14px;\n  font-weight: 400;\n  color: #616a79;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z .PriceOptions_infoItem__246mx {\n  padding-right: 0;\n  display: flex;\n  flex-direction: column;\n  justify-content: center;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z .PriceOptions_infoItem__246mx .PriceOptions_priceBtn__1UaE8 {\n  display: flex;\n  justify-content: space-between;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z .PriceOptions_infoItem__246mx .PriceOptions_priceItem__3CPe3 {\n  display: inline-block;\n  background-color: #fff;\n  border-radius: 4px;\n  border: 1px solid #cfcfcf;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z .PriceOptions_infoItem__246mx .PriceOptions_priceItem__3CPe3.PriceOptions_active__154by {\n  background-color: #fff;\n  color: #FF3266FF;\n  border: 1px solid #ff3266;\n}\n.PriceOptions_options__ifYbC.PriceOptions_multi__2fM8z .PriceOptions_infoItem__246mx .PriceOptions_priceInput__2JFc0 {\n  width: 222px;\n  width: auto;\n}\n";
18 21
 var styles = {
19
-  "options": "PriceOptions_options__ifYbC",
20
-  "infoItem": "PriceOptions_infoItem__246mx",
21
-  "priceItem": "PriceOptions_priceItem__3CPe3",
22
-  "active": "PriceOptions_active__154by",
23
-  "priceInput": "PriceOptions_priceInput__2JFc0",
24
-  "rate": "PriceOptions_rate__17U-9",
25
-  "multi": "PriceOptions_multi__2fM8z",
26
-  "priceBtn": "PriceOptions_priceBtn__1UaE8"
22
+  options: "PriceOptions_options__ifYbC",
23
+  infoItem: "PriceOptions_infoItem__246mx",
24
+  priceItem: "PriceOptions_priceItem__3CPe3",
25
+  active: "PriceOptions_active__154by",
26
+  priceInput: "PriceOptions_priceInput__2JFc0",
27
+  rate: "PriceOptions_rate__17U-9",
28
+  multi: "PriceOptions_multi__2fM8z",
29
+  priceBtn: "PriceOptions_priceBtn__1UaE8"
27 30
 };
28 31
 styleInject_es.styleInject(css);
29 32
 
@@ -32,9 +35,10 @@ function ownKeys(object, enumerableOnly) {
32 35
 
33 36
   if (Object.getOwnPropertySymbols) {
34 37
     var symbols = Object.getOwnPropertySymbols(object);
35
-    if (enumerableOnly) symbols = symbols.filter(function (sym) {
36
-      return Object.getOwnPropertyDescriptor(object, sym).enumerable;
37
-    });
38
+    if (enumerableOnly)
39
+      symbols = symbols.filter(function(sym) {
40
+        return Object.getOwnPropertyDescriptor(object, sym).enumerable;
41
+      });
38 42
     keys.push.apply(keys, symbols);
39 43
   }
40 44
 
@@ -46,14 +50,18 @@ function _objectSpread(target) {
46 50
     var source = arguments[i] != null ? arguments[i] : {};
47 51
 
48 52
     if (i % 2) {
49
-      ownKeys(Object(source), true).forEach(function (key) {
53
+      ownKeys(Object(source), true).forEach(function(key) {
50 54
         defineProperty._defineProperty(target, key, source[key]);
51 55
       });
52 56
     } else if (Object.getOwnPropertyDescriptors) {
53 57
       Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
54 58
     } else {
55
-      ownKeys(Object(source)).forEach(function (key) {
56
-        Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
59
+      ownKeys(Object(source)).forEach(function(key) {
60
+        Object.defineProperty(
61
+          target,
62
+          key,
63
+          Object.getOwnPropertyDescriptor(source, key)
64
+        );
57 65
       });
58 66
     }
59 67
   }
@@ -63,122 +71,176 @@ function _objectSpread(target) {
63 71
 
64 72
 var PriceOptions = function PriceOptions(_ref) {
65 73
   var price = _ref.price,
66
-      onPriceChange = _ref.onPriceChange,
67
-      _ref$rowMode = _ref.rowMode,
68
-      rowMode = _ref$rowMode === void 0 ? "single" : _ref$rowMode,
69
-      _ref$size = _ref.size,
70
-      size = _ref$size === void 0 ? "normal" : _ref$size,
71
-      _ref$focusScroll = _ref.focusScroll,
72
-      focusScroll = _ref$focusScroll === void 0 ? true : _ref$focusScroll,
73
-      _ref$withTitle = _ref.withTitle,
74
-      withTitle = _ref$withTitle === void 0 ? true : _ref$withTitle,
75
-      _ref$titleText = _ref.titleText,
76
-      titleText = _ref$titleText === void 0 ? "Price" : _ref$titleText,
77
-      _ref$inputPlaceholder = _ref.inputPlaceholderText,
78
-      inputPlaceholderText = _ref$inputPlaceholder === void 0 ? "Others" : _ref$inputPlaceholder,
79
-      _ref$priceOptions = _ref.priceOptions,
80
-      priceOptions = _ref$priceOptions === void 0 ? [100, 600, 800] : _ref$priceOptions,
81
-      _ref$priceRender = _ref.priceRender,
82
-      priceRender = _ref$priceRender === void 0 ? function (i) {
83
-    return i / 100;
84
-  } : _ref$priceRender,
85
-      _ref$inputPriceRender = _ref.inputPriceRender,
86
-      inputPriceRender = _ref$inputPriceRender === void 0 ? function (i) {
87
-    return i ? i / 100 : "";
88
-  } : _ref$inputPriceRender,
89
-      _ref$inputSuffix = _ref.inputSuffix,
90
-      inputSuffix = _ref$inputSuffix === void 0 ? "¥" : _ref$inputSuffix,
91
-      _ref$injectOptions = _ref.injectOptions,
92
-      injectOptions = _ref$injectOptions === void 0 ? {
93
-    priceBtnClass: function priceBtnClass() {
94
-      return undefined;
95
-    },
96
-    priceInputClass: function priceInputClass() {
97
-      return undefined;
98
-    }
99
-  } : _ref$injectOptions,
100
-      inputRef = _ref.inputRef;
74
+    onPriceChange = _ref.onPriceChange,
75
+    _ref$rowMode = _ref.rowMode,
76
+    rowMode = _ref$rowMode === void 0 ? "single" : _ref$rowMode,
77
+    _ref$size = _ref.size,
78
+    size = _ref$size === void 0 ? "normal" : _ref$size,
79
+    _ref$focusScroll = _ref.focusScroll,
80
+    focusScroll = _ref$focusScroll === void 0 ? true : _ref$focusScroll,
81
+    _ref$withTitle = _ref.withTitle,
82
+    withTitle = _ref$withTitle === void 0 ? true : _ref$withTitle,
83
+    _ref$titleText = _ref.titleText,
84
+    titleText = _ref$titleText === void 0 ? "Price" : _ref$titleText,
85
+    _ref$inputPlaceholder = _ref.inputPlaceholderText,
86
+    inputPlaceholderText =
87
+      _ref$inputPlaceholder === void 0 ? "Others" : _ref$inputPlaceholder,
88
+    _ref$priceOptions = _ref.priceOptions,
89
+    priceOptions =
90
+      _ref$priceOptions === void 0 ? [100, 600, 800] : _ref$priceOptions,
91
+    _ref$priceRender = _ref.priceRender,
92
+    priceRender =
93
+      _ref$priceRender === void 0
94
+        ? function(i) {
95
+            return i / 100;
96
+          }
97
+        : _ref$priceRender,
98
+    _ref$inputPriceRender = _ref.inputPriceRender,
99
+    inputPriceRender =
100
+      _ref$inputPriceRender === void 0
101
+        ? function(i) {
102
+            return i ? i / 100 : "";
103
+          }
104
+        : _ref$inputPriceRender,
105
+    _ref$inputSuffix = _ref.inputSuffix,
106
+    inputSuffix = _ref$inputSuffix === void 0 ? "¥" : _ref$inputSuffix,
107
+    _ref$injectOptions = _ref.injectOptions,
108
+    injectOptions =
109
+      _ref$injectOptions === void 0
110
+        ? {
111
+            priceBtnClass: function priceBtnClass() {
112
+              return undefined;
113
+            },
114
+            priceInputClass: function priceInputClass() {
115
+              return undefined;
116
+            }
117
+          }
118
+        : _ref$injectOptions,
119
+    inputRef = _ref.inputRef;
101 120
   var defaultOptions = priceOptions;
102 121
 
103 122
   var _useState = React.useState(false),
104
-      _useState2 = slicedToArray._slicedToArray(_useState, 2),
105
-      inputStatus = _useState2[0],
106
-      setInputStatus = _useState2[1];
107
-
108
-  var _useState3 = React.useState(''),
109
-      _useState4 = slicedToArray._slicedToArray(_useState3, 2),
110
-      inputPrice = _useState4[0],
111
-      setInputPrice = _useState4[1];
112
-
113
-  return React__default.createElement("div", {
114
-    className: index.classnames(styles.options, _objectSpread(defineProperty._defineProperty({}, styles.multi, rowMode === "multi"), utils.exportStyleSizeClass(styles, size)))
115
-  }, withTitle ? titleText || null : null, React__default.createElement("div", {
116
-    className: styles.infoItem
117
-  }, React__default.createElement("span", {
118
-    className: styles.priceBtn
119
-  }, defaultOptions.map(function (item) {
120
-    var _objectSpread3;
121
-
122
-    return React__default.createElement("span", {
123
-      className: index.classnames(_objectSpread((_objectSpread3 = {}, defineProperty._defineProperty(_objectSpread3, styles.priceItem, true), defineProperty._defineProperty(_objectSpread3, styles.active, price === item && !inputStatus), _objectSpread3), injectOptions.priceBtnClass(price === item && !inputStatus))),
124
-      key: item,
125
-      onClick: function onClick() {
126
-        onPriceChange(item);
127
-        setInputStatus(false);
128
-      }
129
-    }, priceRender(item));
130
-  })), React__default.createElement(antd.Input, {
131
-    ref: inputRef,
132
-    className: index.classnames(styles.priceInput, _objectSpread({}, injectOptions.priceInputClass())),
133
-    onMouseEnter: function onMouseEnter() {
134
-      if (inputStatus && inputRef && inputRef.current) {
135
-        inputRef.current.focus();
136
-        inputRef.current.select();
137
-      }
123
+    _useState2 = slicedToArray._slicedToArray(_useState, 2),
124
+    inputStatus = _useState2[0],
125
+    setInputStatus = _useState2[1];
126
+
127
+  var _useState3 = React.useState(""),
128
+    _useState4 = slicedToArray._slicedToArray(_useState3, 2),
129
+    inputPrice = _useState4[0],
130
+    setInputPrice = _useState4[1];
131
+
132
+  return React__default.createElement(
133
+    "div",
134
+    {
135
+      className: index.classnames(
136
+        styles.options,
137
+        _objectSpread(
138
+          defineProperty._defineProperty({}, styles.multi, rowMode === "multi"),
139
+          utils.exportStyleSizeClass(styles, size)
140
+        )
141
+      )
138 142
     },
139
-    suffix: inputSuffix,
140
-    value: inputStatus ? inputPriceRender(inputPrice) : "",
141
-    placeholder: inputPlaceholderText,
142
-    onChange: function onChange(e) {
143
-      var n = +e.target.value;
144
-
145
-      if (Number.isNaN(n)) {
146
-        return;
147
-      }
148
-
149
-      setInputPrice("".concat(n * 100));
150
-      onPriceChange(n * 100);
151
-    },
152
-    onClick: function onClick(e) {
153
-      if (!inputStatus) {
154
-        setInputPrice('');
155
-        setInputStatus(true);
156
-      }
157
-    },
158
-    onFocus: function onFocus(e) {
159
-      e.target.placeholder = "";
160
-
161
-      if (inputStatus) {
162
-        setInputPrice("".concat(price));
163
-      } else {
164
-        setInputPrice('');
165
-        setInputStatus(true);
166
-      }
167
-
168
-      if (focusScroll) {
169
-        e.target.scrollIntoView();
170
-      }
171
-    },
172
-    onBlur: function onBlur(e) {
173
-      e.target.placeholder = inputPlaceholderText;
174
-
175
-      if (inputPrice) {
176
-        setInputStatus(true);
177
-      } else {
178
-        setInputStatus(false);
179
-      }
180
-    }
181
-  })));
143
+    withTitle ? titleText || null : null,
144
+    React__default.createElement(
145
+      "div",
146
+      {
147
+        className: styles.infoItem
148
+      },
149
+      React__default.createElement(
150
+        "span",
151
+        {
152
+          className: styles.priceBtn
153
+        },
154
+        defaultOptions.map(function(item) {
155
+          var _objectSpread3;
156
+
157
+          return React__default.createElement(
158
+            "span",
159
+            {
160
+              className: index.classnames(
161
+                _objectSpread(
162
+                  ((_objectSpread3 = {}),
163
+                  defineProperty._defineProperty(
164
+                    _objectSpread3,
165
+                    styles.priceItem,
166
+                    true
167
+                  ),
168
+                  defineProperty._defineProperty(
169
+                    _objectSpread3,
170
+                    styles.active,
171
+                    price === item && !inputStatus
172
+                  ),
173
+                  _objectSpread3),
174
+                  injectOptions.priceBtnClass(price === item && !inputStatus)
175
+                )
176
+              ),
177
+              key: item,
178
+              onClick: function onClick() {
179
+                onPriceChange(item);
180
+                setInputStatus(false);
181
+              }
182
+            },
183
+            priceRender(item)
184
+          );
185
+        })
186
+      ),
187
+      React__default.createElement(antd.Input, {
188
+        ref: inputRef,
189
+        className: index.classnames(
190
+          styles.priceInput,
191
+          _objectSpread({}, injectOptions.priceInputClass())
192
+        ),
193
+        onMouseEnter: function onMouseEnter() {
194
+          if (inputStatus && inputRef && inputRef.current) {
195
+            inputRef.current.focus();
196
+            inputRef.current.select();
197
+          }
198
+        },
199
+        suffix: inputSuffix,
200
+        value: inputStatus ? inputPriceRender(inputPrice) : "",
201
+        placeholder: inputPlaceholderText,
202
+        onChange: function onChange(e) {
203
+          var n = +e.target.value;
204
+
205
+          if (Number.isNaN(n)) {
206
+            return;
207
+          }
208
+
209
+          setInputPrice("".concat(n * 100));
210
+          onPriceChange(n * 100);
211
+        },
212
+        onClick: function onClick(e) {
213
+          if (!inputStatus) {
214
+            setInputPrice("");
215
+            setInputStatus(true);
216
+          }
217
+        },
218
+        onFocus: function onFocus(e) {
219
+          e.target.placeholder = "";
220
+
221
+          if (inputStatus) {
222
+            setInputPrice("".concat(price));
223
+          } else {
224
+            setInputPrice("");
225
+            setInputStatus(true);
226
+          }
227
+
228
+          if (focusScroll) {
229
+            e.target.scrollIntoView();
230
+          }
231
+        },
232
+        onBlur: function onBlur(e) {
233
+          e.target.placeholder = inputPlaceholderText;
234
+
235
+          if (inputPrice) {
236
+            setInputStatus(true);
237
+          } else {
238
+            setInputStatus(false);
239
+          }
240
+        }
241
+      })
242
+    )
243
+  );
182 244
 };
183 245
 
184 246
 exports.default = PriceOptions;

+ 1
- 1
lib/PriceOptions/index.js.map
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 8
- 8
lib/WaitPayInfoView/index.d.ts Ver arquivo

@@ -1,14 +1,14 @@
1 1
 /// <reference types="react" />
2
-import { Component } from 'react';
2
+import { Component } from "react";
3 3
 interface Props {
4
-    onClickPayed?: Function;
5
-    onClickProblem?: Function;
4
+  onClickPayed?: Function;
5
+  onClickProblem?: Function;
6 6
 }
7 7
 declare class WaitPayInfoView extends Component<Props, {}> {
8
-    static defaultProps: {
9
-        onClickPayed: () => void;
10
-        onClickProblem: () => void;
11
-    };
12
-    render(): JSX.Element;
8
+  static defaultProps: {
9
+    onClickPayed: () => void;
10
+    onClickProblem: () => void;
11
+  };
12
+  render(): JSX.Element;
13 13
 }
14 14
 export { WaitPayInfoView as default, WaitPayInfoView };

+ 107
- 56
lib/WaitPayInfoView/index.js Ver arquivo

@@ -1,81 +1,132 @@
1
-'use strict';
1
+"use strict";
2 2
 
3
-Object.defineProperty(exports, '__esModule', { value: true });
3
+Object.defineProperty(exports, "__esModule", { value: true });
4 4
 
5
-function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
5
+function _interopDefault(ex) {
6
+  return ex && typeof ex === "object" && "default" in ex ? ex["default"] : ex;
7
+}
6 8
 
7
-var inherits = require('../inherits-c86d64c1.js');
8
-var React = require('react');
9
+var inherits = require("../inherits-c86d64c1.js");
10
+var React = require("react");
9 11
 var React__default = _interopDefault(React);
10
-var styleInject_es = require('../style-inject.es-dcee06b6.js');
11
-require('../_commonjsHelpers-72d386ba.js');
12
-var index = require('../index-44e17595.js');
12
+var styleInject_es = require("../style-inject.es-dcee06b6.js");
13
+require("../_commonjsHelpers-72d386ba.js");
14
+var index = require("../index-44e17595.js");
13 15
 
14
-var css = ".WaitPayInfoView_waitingContainer__3pU2F {\n  display: flex;\n  flex-direction: column;\n  justify-content: center;\n  align-items: center;\n}\n";
16
+var css =
17
+  ".WaitPayInfoView_waitingContainer__3pU2F {\n  display: flex;\n  flex-direction: column;\n  justify-content: center;\n  align-items: center;\n}\n";
15 18
 var styles = {
16
-  "waitingContainer": "WaitPayInfoView_waitingContainer__3pU2F"
19
+  waitingContainer: "WaitPayInfoView_waitingContainer__3pU2F"
17 20
 };
18 21
 styleInject_es.styleInject(css);
19 22
 
20
-var img = "data:image/svg+xml,%3c%3fxml version='1.0' encoding='UTF-8'%3f%3e%3csvg width='48px' height='43px' viewBox='0 0 48 43' version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3e %3c!-- Generator: Sketch 50.2 (55047) - http://www.bohemiancoding.com/sketch --%3e %3ctitle%3ekcxq_popovers_icon_tanhao%3c/title%3e %3cdesc%3eCreated with Sketch.%3c/desc%3e %3cdefs%3e%3c/defs%3e %3cg id='Page-1' stroke='none' stroke-width='1' fill='none' fill-rule='evenodd'%3e %3cg id='%e5%8f%a6%e5%ae%a2%e7%bd%91_%e7%9b%b4%e6%92%ad%e8%af%be_%e8%af%be%e7%a8%8b%e4%bb%8b%e7%bb%8d%e8%af%a6%e6%83%85_%e8%b4%ad%e4%b9%b0%e6%8f%90%e7%a4%ba%e5%bc%b9%e7%aa%97' transform='translate(-936.000000%2c -190.000000)' fill-rule='nonzero'%3e %3cg id='Group-22' transform='translate(690.000000%2c 110.000000)'%3e %3cg id='kcxq_popovers_icon_tanhao' transform='translate(246.000000%2c 80.000000)'%3e %3cpath d='M48%2c21.5 C48%2c33.3736626 38.3645756%2c43 26.4797048%2c43 C21.1306273%2c43 17.0391144%2c42.1506173 13.2841328%2c38.9300412 C11.8140221%2c37.6736626 1.700369%2c43.2123457 0.177121771%2c39.2839506 C-1.06273063%2c36.0987654 5.95129151%2c29.2506173 5.31365314%2c27.0740741 C4.76457565%2c25.1806584 4.95940959%2c23.5703704 4.95940959%2c21.5 C4.95940959%2c9.62633745 14.5948339%2c0 26.4797048%2c0 C38.3645756%2c0 48%2c9.62633745 48%2c21.5 Z' id='Shape' fill='%231790FF'%3e%3c/path%3e %3cg id='Group' transform='translate(23.848708%2c 8.193416)' fill='white'%3e %3cpath d='M2.5%2c27.4971098 C1.13235294%2c27.4971098 0%2c26.3794628 0%2c24.9971098 C0%2c23.6147569 1.13235294%2c22.4971098 2.5%2c22.4971098 C3.86764706%2c22.4971098 5%2c23.6147569 5%2c24.9971098 C5%2c26.3794628 3.86764706%2c27.4971098 2.5%2c27.4971098 Z M2.5%2c19.4219653 C1.13235294%2c19.4219653 0%2c18.1919075 0%2c16.6705202 L0%2c2.75144509 C0%2c1.24624277 1.13235294%2c0 2.5%2c0 C3.86764706%2c0 5%2c1.2300578 5%2c2.75144509 L5%2c16.6705202 C5%2c18.1919075 3.86764706%2c19.4219653 2.5%2c19.4219653 Z' id='Shape'%3e%3c/path%3e %3c/g%3e %3c/g%3e %3c/g%3e %3c/g%3e %3c/g%3e%3c/svg%3e";
23
+var img =
24
+  "data:image/svg+xml,%3c%3fxml version='1.0' encoding='UTF-8'%3f%3e%3csvg width='48px' height='43px' viewBox='0 0 48 43' version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink'%3e %3c!-- Generator: Sketch 50.2 (55047) - http://www.bohemiancoding.com/sketch --%3e %3ctitle%3ekcxq_popovers_icon_tanhao%3c/title%3e %3cdesc%3eCreated with Sketch.%3c/desc%3e %3cdefs%3e%3c/defs%3e %3cg id='Page-1' stroke='none' stroke-width='1' fill='none' fill-rule='evenodd'%3e %3cg id='%e5%8f%a6%e5%ae%a2%e7%bd%91_%e7%9b%b4%e6%92%ad%e8%af%be_%e8%af%be%e7%a8%8b%e4%bb%8b%e7%bb%8d%e8%af%a6%e6%83%85_%e8%b4%ad%e4%b9%b0%e6%8f%90%e7%a4%ba%e5%bc%b9%e7%aa%97' transform='translate(-936.000000%2c -190.000000)' fill-rule='nonzero'%3e %3cg id='Group-22' transform='translate(690.000000%2c 110.000000)'%3e %3cg id='kcxq_popovers_icon_tanhao' transform='translate(246.000000%2c 80.000000)'%3e %3cpath d='M48%2c21.5 C48%2c33.3736626 38.3645756%2c43 26.4797048%2c43 C21.1306273%2c43 17.0391144%2c42.1506173 13.2841328%2c38.9300412 C11.8140221%2c37.6736626 1.700369%2c43.2123457 0.177121771%2c39.2839506 C-1.06273063%2c36.0987654 5.95129151%2c29.2506173 5.31365314%2c27.0740741 C4.76457565%2c25.1806584 4.95940959%2c23.5703704 4.95940959%2c21.5 C4.95940959%2c9.62633745 14.5948339%2c0 26.4797048%2c0 C38.3645756%2c0 48%2c9.62633745 48%2c21.5 Z' id='Shape' fill='%231790FF'%3e%3c/path%3e %3cg id='Group' transform='translate(23.848708%2c 8.193416)' fill='white'%3e %3cpath d='M2.5%2c27.4971098 C1.13235294%2c27.4971098 0%2c26.3794628 0%2c24.9971098 C0%2c23.6147569 1.13235294%2c22.4971098 2.5%2c22.4971098 C3.86764706%2c22.4971098 5%2c23.6147569 5%2c24.9971098 C5%2c26.3794628 3.86764706%2c27.4971098 2.5%2c27.4971098 Z M2.5%2c19.4219653 C1.13235294%2c19.4219653 0%2c18.1919075 0%2c16.6705202 L0%2c2.75144509 C0%2c1.24624277 1.13235294%2c0 2.5%2c0 C3.86764706%2c0 5%2c1.2300578 5%2c2.75144509 L5%2c16.6705202 C5%2c18.1919075 3.86764706%2c19.4219653 2.5%2c19.4219653 Z' id='Shape'%3e%3c/path%3e %3c/g%3e %3c/g%3e %3c/g%3e %3c/g%3e %3c/g%3e%3c/svg%3e";
21 25
 
22 26
 var Button = function Button() {
23
-  for (var _len = arguments.length, props = new Array(_len), _key = 0; _key < _len; _key++) {
27
+  for (
28
+    var _len = arguments.length, props = new Array(_len), _key = 0;
29
+    _key < _len;
30
+    _key++
31
+  ) {
24 32
     props[_key] = arguments[_key];
25 33
   }
26 34
 
27
-  return React__default.createElement("button", Object.assign({}, props), "button");
35
+  return React__default.createElement(
36
+    "button",
37
+    Object.assign({}, props),
38
+    "button"
39
+  );
28 40
 };
29 41
 
30 42
 var WaitPayInfoView =
31
-/*#__PURE__*/
32
-function (_Component) {
33
-  inherits._inherits(WaitPayInfoView, _Component);
43
+  /*#__PURE__*/
44
+  (function(_Component) {
45
+    inherits._inherits(WaitPayInfoView, _Component);
34 46
 
35
-  function WaitPayInfoView() {
36
-    inherits._classCallCheck(this, WaitPayInfoView);
47
+    function WaitPayInfoView() {
48
+      inherits._classCallCheck(this, WaitPayInfoView);
37 49
 
38
-    return inherits._possibleConstructorReturn(this, inherits._getPrototypeOf(WaitPayInfoView).apply(this, arguments));
39
-  }
50
+      return inherits._possibleConstructorReturn(
51
+        this,
52
+        inherits._getPrototypeOf(WaitPayInfoView).apply(this, arguments)
53
+      );
54
+    }
40 55
 
41
-  inherits._createClass(WaitPayInfoView, [{
42
-    key: "render",
43
-    value: function render() {
44
-      var _this$props = this.props,
45
-          onClickPayed = _this$props.onClickPayed,
46
-          onClickProblem = _this$props.onClickProblem;
47
-      return React__default.createElement("div", {
48
-        className: styles.waitingContainer
49
-      }, React__default.createElement("div", {
50
-        className: styles.infoIconImgContainer
51
-      }, React__default.createElement("img", {
52
-        src: img,
53
-        alt: "info label icon"
54
-      })), React__default.createElement("div", null, React__default.createElement("div", {
55
-        className: styles.pay_text
56
-      }, "live.course_info.pay.notification"), React__default.createElement("div", {
57
-        className: styles.btn_row
58
-      }, React__default.createElement(Button, {
59
-        className: index.classnames(styles.pay_btn, styles.btn_default),
60
-        size: "small",
61
-        onClick: function onClick() {
62
-          onClickPayed && onClickPayed();
56
+    inherits._createClass(WaitPayInfoView, [
57
+      {
58
+        key: "render",
59
+        value: function render() {
60
+          var _this$props = this.props,
61
+            onClickPayed = _this$props.onClickPayed,
62
+            onClickProblem = _this$props.onClickProblem;
63
+          return React__default.createElement(
64
+            "div",
65
+            {
66
+              className: styles.waitingContainer
67
+            },
68
+            React__default.createElement(
69
+              "div",
70
+              {
71
+                className: styles.infoIconImgContainer
72
+              },
73
+              React__default.createElement("img", {
74
+                src: img,
75
+                alt: "info label icon"
76
+              })
77
+            ),
78
+            React__default.createElement(
79
+              "div",
80
+              null,
81
+              React__default.createElement(
82
+                "div",
83
+                {
84
+                  className: styles.pay_text
85
+                },
86
+                "live.course_info.pay.notification"
87
+              ),
88
+              React__default.createElement(
89
+                "div",
90
+                {
91
+                  className: styles.btn_row
92
+                },
93
+                React__default.createElement(
94
+                  Button,
95
+                  {
96
+                    className: index.classnames(
97
+                      styles.pay_btn,
98
+                      styles.btn_default
99
+                    ),
100
+                    size: "small",
101
+                    onClick: function onClick() {
102
+                      onClickPayed && onClickPayed();
103
+                    }
104
+                  },
105
+                  "live.course_info.pay.payed"
106
+                ),
107
+                React__default.createElement(
108
+                  Button,
109
+                  {
110
+                    className: styles.btn_default,
111
+                    size: "small",
112
+                    style: {
113
+                      marginLeft: "16px"
114
+                    },
115
+                    onClick: function onClick() {
116
+                      onClickProblem && onClickProblem();
117
+                    }
118
+                  },
119
+                  "live.course_info.pay.help"
120
+                )
121
+              )
122
+            )
123
+          );
63 124
         }
64
-      }, "live.course_info.pay.payed"), React__default.createElement(Button, {
65
-        className: styles.btn_default,
66
-        size: "small",
67
-        style: {
68
-          marginLeft: '16px'
69
-        },
70
-        onClick: function onClick() {
71
-          onClickProblem && onClickProblem();
72
-        }
73
-      }, "live.course_info.pay.help"))));
74
-    }
75
-  }]);
125
+      }
126
+    ]);
76 127
 
77
-  return WaitPayInfoView;
78
-}(React.Component);
128
+    return WaitPayInfoView;
129
+  })(React.Component);
79 130
 WaitPayInfoView.defaultProps = {
80 131
   onClickPayed: function onClickPayed() {
81 132
     console.log("onClickPayed");

+ 1
- 1
lib/WaitPayInfoView/index.js.map
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 27
- 0
lib/WantedPublishModal/index.d.ts Ver arquivo

@@ -0,0 +1,27 @@
1
+/// <reference types="react" />
2
+import { Component } from "react";
3
+import { ModalProps } from "../Modal/index";
4
+interface WantedPublishModalProps {
5
+  modalConfig?: ModalProps;
6
+  handleConfirm?: Function;
7
+}
8
+interface WantedPublishModalState {
9
+  modalVisible: boolean;
10
+  current_wanted: number | string | null;
11
+}
12
+declare class WantedPublishModal extends Component<
13
+  WantedPublishModalProps,
14
+  WantedPublishModalState
15
+> {
16
+  constructor(props: WantedPublishModalProps);
17
+  handleModalShow: () => void;
18
+  handleClose: () => void;
19
+  handleUpdateCurrentWanted: (
20
+    value: string | number | null,
21
+    afterUpdate?: Function | undefined
22
+  ) => void;
23
+  clearCurrentWanted: (cb: Function) => void;
24
+  renderMain(): JSX.Element;
25
+  render(): JSX.Element;
26
+}
27
+export { WantedPublishModal as default, WantedPublishModal };

+ 167
- 0
lib/WantedPublishModal/index.js Ver arquivo

@@ -0,0 +1,167 @@
1
+"use strict";
2
+
3
+Object.defineProperty(exports, "__esModule", { value: true });
4
+
5
+function _interopDefault(ex) {
6
+  return ex && typeof ex === "object" && "default" in ex ? ex["default"] : ex;
7
+}
8
+
9
+var inherits = require("../inherits-c86d64c1.js");
10
+var React = require("react");
11
+var React__default = _interopDefault(React);
12
+require("react-dom");
13
+var Modal = require("../Modal/index.js");
14
+var styleInject_es = require("../style-inject.es-dcee06b6.js");
15
+require("../defineProperty-ba7cd53d.js");
16
+require("../_commonjsHelpers-72d386ba.js");
17
+require("../index-44e17595.js");
18
+require("antd");
19
+var WantedPublishView = require("../WantedPublishView/index.js");
20
+
21
+var css =
22
+  ".WantedPublishModal_modalBg__3OlNh {\n  background: white;\n  display: flex;\n  justify-content: center;\n  flex-direction: column;\n  align-items: center;\n  padding: 16px;\n  text-align: center;\n  border-radius: 4px;\n}\n";
23
+var styles = {
24
+  modalBg: "WantedPublishModal_modalBg__3OlNh"
25
+};
26
+styleInject_es.styleInject(css);
27
+
28
+var WantedPublishModal =
29
+  /*#__PURE__*/
30
+  (function(_Component) {
31
+    inherits._inherits(WantedPublishModal, _Component);
32
+
33
+    function WantedPublishModal(props) {
34
+      var _this;
35
+
36
+      inherits._classCallCheck(this, WantedPublishModal);
37
+
38
+      _this = inherits._possibleConstructorReturn(
39
+        this,
40
+        inherits._getPrototypeOf(WantedPublishModal).call(this, props)
41
+      );
42
+
43
+      _this.handleModalShow = function() {};
44
+
45
+      _this.handleClose = function() {
46
+        var handleConfirm = _this.props.handleConfirm;
47
+
48
+        if (handleConfirm) {
49
+          _this.handleUpdateCurrentWanted(_this.state.current_wanted, function(
50
+            value
51
+          ) {
52
+            handleConfirm(Number(value).toFixed(2));
53
+          });
54
+        }
55
+
56
+        _this.setState({
57
+          modalVisible: false
58
+        });
59
+      };
60
+
61
+      _this.handleUpdateCurrentWanted = function(value, afterUpdate) {
62
+        if (!value) return;
63
+        var result;
64
+        result = value;
65
+
66
+        if (parseInt("".concat(value), 10) === value) {
67
+          result = Number(value);
68
+        }
69
+
70
+        if (!result) return;
71
+        if (result > 10000) result = 10000;
72
+        if (result < 5) result = 5;
73
+
74
+        _this.setState(
75
+          {
76
+            current_wanted: result
77
+          },
78
+          function() {
79
+            return afterUpdate && afterUpdate(result);
80
+          }
81
+        );
82
+      };
83
+
84
+      _this.clearCurrentWanted = function(cb) {
85
+        _this.setState(
86
+          {
87
+            current_wanted: null
88
+          },
89
+          function() {
90
+            return cb();
91
+          }
92
+        );
93
+      };
94
+
95
+      _this.state = {
96
+        modalVisible: false,
97
+        current_wanted: null
98
+      };
99
+      return _this;
100
+    }
101
+
102
+    inherits._createClass(WantedPublishModal, [
103
+      {
104
+        key: "renderMain",
105
+        value: function renderMain() {
106
+          var _this2 = this;
107
+
108
+          var current_wanted = this.state.current_wanted;
109
+          return React__default.createElement(WantedPublishView.default, {
110
+            wrapperClass: styles.modalBg,
111
+            current_wanted: current_wanted,
112
+            InputWantedValueChange: function InputWantedValueChange(v) {
113
+              return _this2.setState({
114
+                current_wanted: v
115
+              });
116
+            },
117
+            InputWantedPressEnter: function InputWantedPressEnter(v) {
118
+              return _this2.handleUpdateCurrentWanted(v, _this2.handleClose);
119
+            },
120
+            InputWantedOnBlur: function InputWantedOnBlur(v) {
121
+              return _this2.handleUpdateCurrentWanted(v);
122
+            },
123
+            InputWantedClear: function InputWantedClear() {
124
+              return _this2.clearCurrentWanted(_this2.handleClose);
125
+            },
126
+            CloseFunction: this.handleClose
127
+          });
128
+        }
129
+      },
130
+      {
131
+        key: "render",
132
+        value: function render() {
133
+          var _this3 = this;
134
+
135
+          return React__default.createElement(
136
+            React__default.Fragment,
137
+            null,
138
+            React__default.createElement(
139
+              "div",
140
+              {
141
+                onClick: function onClick() {
142
+                  return _this3.setState({
143
+                    modalVisible: true
144
+                  });
145
+                }
146
+              },
147
+              this.props.children
148
+            ),
149
+            React__default.createElement(
150
+              Modal.default,
151
+              {
152
+                visible: this.state.modalVisible,
153
+                onCancel: this.handleClose
154
+              },
155
+              this.renderMain()
156
+            )
157
+          );
158
+        }
159
+      }
160
+    ]);
161
+
162
+    return WantedPublishModal;
163
+  })(React.Component);
164
+
165
+exports.WantedPublishModal = WantedPublishModal;
166
+exports.default = WantedPublishModal;
167
+//# sourceMappingURL=index.js.map

+ 1
- 0
lib/WantedPublishModal/index.js.map
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 25
- 14
lib/WantedPublishPopover/index.d.ts Ver arquivo

@@ -1,20 +1,31 @@
1 1
 /// <reference types="react" />
2
-import React from 'react';
3
-import { PopoverProps } from 'antd/lib/popover';
2
+import React from "react";
3
+import { PopoverProps } from "antd/lib/popover";
4 4
 interface WantedPublishPopoverProp {
5
-    popoverConfig?: PopoverProps;
6
-    handleConfirm?: Function;
5
+  popoverConfig?: PopoverProps;
6
+  handleConfirm?: Function;
7 7
 }
8 8
 interface WantedPublishPopoverState {
9
-    visible: boolean;
10
-    current_wanted: number | string | null;
9
+  visible: boolean;
10
+  current_wanted: number | string | null;
11 11
 }
12
-declare class WantedPublishPopover extends React.Component<WantedPublishPopoverProp, WantedPublishPopoverState> {
13
-    constructor(props: WantedPublishPopoverProp);
14
-    handleClose: () => void;
15
-    clearCurrentWanted: (cb: Function) => void;
16
-    handleUpdateCurrentWanted: (value: string | number | null, afterUpdate?: Function | undefined) => void;
17
-    renderInitView(): JSX.Element;
18
-    render(): JSX.Element;
12
+declare class WantedPublishPopover extends React.Component<
13
+  WantedPublishPopoverProp,
14
+  WantedPublishPopoverState
15
+> {
16
+  constructor(props: WantedPublishPopoverProp);
17
+  handleClose: () => void;
18
+  clearCurrentWanted: (cb: Function) => void;
19
+  handleUpdateCurrentWanted: (
20
+    value: string | number | null,
21
+    afterUpdate?: Function | undefined
22
+  ) => void;
23
+  renderInitView(): JSX.Element;
24
+  render(): JSX.Element;
19 25
 }
20
-export { WantedPublishPopover as default, WantedPublishPopover, WantedPublishPopoverProp, WantedPublishPopoverState };
26
+export {
27
+  WantedPublishPopover as default,
28
+  WantedPublishPopover,
29
+  WantedPublishPopoverProp,
30
+  WantedPublishPopoverState
31
+};

+ 172
- 132
lib/WantedPublishPopover/index.js Ver arquivo

@@ -1,158 +1,198 @@
1
-'use strict';
1
+"use strict";
2 2
 
3
-Object.defineProperty(exports, '__esModule', { value: true });
3
+Object.defineProperty(exports, "__esModule", { value: true });
4 4
 
5
-function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
5
+function _interopDefault(ex) {
6
+  return ex && typeof ex === "object" && "default" in ex ? ex["default"] : ex;
7
+}
6 8
 
7
-var inherits = require('../inherits-c86d64c1.js');
8
-var React = require('react');
9
+var inherits = require("../inherits-c86d64c1.js");
10
+var React = require("react");
9 11
 var React__default = _interopDefault(React);
10
-var styleInject_es = require('../style-inject.es-dcee06b6.js');
11
-require('../defineProperty-ba7cd53d.js');
12
-require('../_commonjsHelpers-72d386ba.js');
13
-require('../index-44e17595.js');
14
-var antd = require('antd');
15
-var WantedPublishView = require('../WantedPublishView/index.js');
16
-
17
-var img = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACYAAAAmCAYAAACoPemuAAAFNElEQVRYR82Yf0jcdRjH33enp1NbTQ3FdKhTY64hTTsURc6keQeSqIPSQJIiMHM3zj8ST/BE/And+c8wmSSMomHl4EaaP2aeuq/R1MwrraEgLVbLXcvpReY847l9v3I7774/LKUHjuN79/k8z+v7+fG8n89Hhv+pyf4F1xEAxwE8BSAIQDAAPwB/AnCwnzsAVgHsSI0jFcwfwEkA8QAiRAYj0BUACwDsIvtALJgcwLMA0tjREevfs90tADcBbAg5EAN2FEAegFAhZyL/3wYwBeB7vvZCYFEAzgIIEBlUSjMCYwA4vXXiA6N1lAuApvGg7DaAL7zB+QILB1DA7rKDguL80shNegbxBkZbv4jd/gcNxfmfYHftbjxvYDR9CYdFxMahDfExm/tcP3mC0RQWHzIUF+5HAGPcgydYPoBn+MCSk5ODm5ubs4qKigadTq8b6rHuFRUVcYmJicf0ev2swAuTOnwC4L7niD0J4FW+zvHx8YEMw+gjIiKOz8zM3MjIyPhwa2vLp9xUV1cntra2VioUCv+WlpYug8EwLwD3HYAbnmApANL5OlZVVZ0wm806hUKhpHbz8/Nfq1Sqns3NzT1wdXV1J41GYwXXdnZ2lklNTb0sAEaK8JEnGKWHSKH1xY2Cn59fILVdXFz8RqVSXdrY2Nid16amptM1NTVvyeVy0laIGV23uJ+SpnJrTAHgTSEo7v/Kyso4k8l0XqlUUoWBpaUlW3p6epfdbn9oMpnO6HS6N+RyOfnE1NTUWFZW1hUx65H1T3I1z4E9AaBULBi1Ky8vj+ns7NQFBASE0PPKysqi1WqdKSsrK5XJZC61sFqtw2q1+jMpfgmK3ocDoymkqZRkJSUlUd3d3ReCgoJI6B+zwcHBzzUazTVJDh81XgJwnQOLY8Vasp+CgoKI3t7ed5VKJSmGy4aGhvrz8vIskp096kDF5TUOjCpR7X4c9fX1nS0sLCQJ27XV1dXbubm5HTabjSpZqfYTgAEOLAzAOake+vv787VaLSVlsh2Hw/EgODiY8iHsdvsdjUbTMT09/UCi3x9oeXJgtLvKpDgYHR0tzMnJoQISOzs7zq6urss9PT0LAwMDF0JDQ6mOw9ra2t38/Hzz5OTkHxJ8k0Lc5MDo+3UArsTJZ3K5HOPj469kZmbmsFDbHR0dH+j1+hl6TklJCRkZGdGFh4fH0PP6+vq94uJi8/DwsNh6/0sAt9y18kUAiXxQ/v7+MoZhXktLS8uidk6n82FbW9ul2trab937JSUlBVmt1vORkZGx9LvD4bhfWlpqtlgsvwm8NykIqcNf7mBUsb7E19FoNJ6qr6+vojbb29t/NzY2vt/Q0ECnnz0WGxsbODEx8U50dLSrhFpeXrYlJCRcFAD7BYBrN7uDkXzQOqOzoU+zWCwarVarNRgMF9vb2+nU49OioqKUDMO8HRIScjQ7O/u9hYUFoV1KZwCbJxg9vwDgjNA6U6vVx8bGxlzliZCFhYX5xcTEHJmbm1sXaEvnzysAtryB0eIvAeAS6EO2caoJuJjeSutTAFyL+xDtdwCkqbsViq9T0mHW/ZsArlLacx8IX2C0AV4G8PQBjxqlh34AP3vG4TvwkihrDhCOTkZ0+KBqYo8JXRHQyKkBnPiPR4524CAAnwlXCIzjOc3e9AhKlogXoCspOnnz5jSxYBSPLlaeB/AcAFfZLNHuAvgKwK9i+kkB4/xRjqP6jXSQhJpPKUi4aYToc08MEF8ek9KfRo675qRv7qqTu+6kVLAv28+I7SuQ1E7/AHTQdDZ7M6+KAAAAAElFTkSuQmCC";
18
-
19
-var css = ".WantedPublishPopover_wantedWrapper__3CrCz {\n  width: 366px;\n  height: 424px;\n  font-size: 18px;\n  text-align: center;\n}\n.WantedPublishPopover_wantedWrapper__3CrCz .WantedPublishPopover_closeBtnWrapper__1KV58 {\n  position: absolute;\n  top: 10px;\n  right: 16px;\n  width: 20px;\n  height: 20px;\n}\n.WantedPublishPopover_wantedWrapper__3CrCz .WantedPublishPopover_closeBtnWrapper__1KV58:focus {\n  outline: none;\n}\n.WantedPublishPopover_wantedWrapper__3CrCz .WantedPublishPopover_closeBtnWrapper__1KV58 > div.WantedPublishPopover_closeBtn__1aBMB {\n  border: none;\n  padding: 0px;\n  margin: 0px;\n  cursor: pointer;\n}\n.WantedPublishPopover_wantedWrapper__3CrCz .WantedPublishPopover_closeBtnWrapper__1KV58 > div.WantedPublishPopover_closeBtn__1aBMB > img {\n  width: 100%;\n}\n";
12
+var styleInject_es = require("../style-inject.es-dcee06b6.js");
13
+require("../defineProperty-ba7cd53d.js");
14
+require("../_commonjsHelpers-72d386ba.js");
15
+require("../index-44e17595.js");
16
+var antd = require("antd");
17
+var WantedPublishView = require("../WantedPublishView/index.js");
18
+
19
+var img =
20
+  "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACYAAAAmCAYAAACoPemuAAAFNElEQVRYR82Yf0jcdRjH33enp1NbTQ3FdKhTY64hTTsURc6keQeSqIPSQJIiMHM3zj8ST/BE/And+c8wmSSMomHl4EaaP2aeuq/R1MwrraEgLVbLXcvpReY847l9v3I7774/LKUHjuN79/k8z+v7+fG8n89Hhv+pyf4F1xEAxwE8BSAIQDAAPwB/AnCwnzsAVgHsSI0jFcwfwEkA8QAiRAYj0BUACwDsIvtALJgcwLMA0tjREevfs90tADcBbAg5EAN2FEAegFAhZyL/3wYwBeB7vvZCYFEAzgIIEBlUSjMCYwA4vXXiA6N1lAuApvGg7DaAL7zB+QILB1DA7rKDguL80shNegbxBkZbv4jd/gcNxfmfYHftbjxvYDR9CYdFxMahDfExm/tcP3mC0RQWHzIUF+5HAGPcgydYPoBn+MCSk5ODm5ubs4qKigadTq8b6rHuFRUVcYmJicf0ev2swAuTOnwC4L7niD0J4FW+zvHx8YEMw+gjIiKOz8zM3MjIyPhwa2vLp9xUV1cntra2VioUCv+WlpYug8EwLwD3HYAbnmApANL5OlZVVZ0wm806hUKhpHbz8/Nfq1Sqns3NzT1wdXV1J41GYwXXdnZ2lklNTb0sAEaK8JEnGKWHSKH1xY2Cn59fILVdXFz8RqVSXdrY2Nid16amptM1NTVvyeVy0laIGV23uJ+SpnJrTAHgTSEo7v/Kyso4k8l0XqlUUoWBpaUlW3p6epfdbn9oMpnO6HS6N+RyOfnE1NTUWFZW1hUx65H1T3I1z4E9AaBULBi1Ky8vj+ns7NQFBASE0PPKysqi1WqdKSsrK5XJZC61sFqtw2q1+jMpfgmK3ocDoymkqZRkJSUlUd3d3ReCgoJI6B+zwcHBzzUazTVJDh81XgJwnQOLY8Vasp+CgoKI3t7ed5VKJSmGy4aGhvrz8vIskp096kDF5TUOjCpR7X4c9fX1nS0sLCQJ27XV1dXbubm5HTabjSpZqfYTgAEOLAzAOake+vv787VaLSVlsh2Hw/EgODiY8iHsdvsdjUbTMT09/UCi3x9oeXJgtLvKpDgYHR0tzMnJoQISOzs7zq6urss9PT0LAwMDF0JDQ6mOw9ra2t38/Hzz5OTkHxJ8k0Lc5MDo+3UArsTJZ3K5HOPj469kZmbmsFDbHR0dH+j1+hl6TklJCRkZGdGFh4fH0PP6+vq94uJi8/DwsNh6/0sAt9y18kUAiXxQ/v7+MoZhXktLS8uidk6n82FbW9ul2trab937JSUlBVmt1vORkZGx9LvD4bhfWlpqtlgsvwm8NykIqcNf7mBUsb7E19FoNJ6qr6+vojbb29t/NzY2vt/Q0ECnnz0WGxsbODEx8U50dLSrhFpeXrYlJCRcFAD7BYBrN7uDkXzQOqOzoU+zWCwarVarNRgMF9vb2+nU49OioqKUDMO8HRIScjQ7O/u9hYUFoV1KZwCbJxg9vwDgjNA6U6vVx8bGxlzliZCFhYX5xcTEHJmbm1sXaEvnzysAtryB0eIvAeAS6EO2caoJuJjeSutTAFyL+xDtdwCkqbsViq9T0mHW/ZsArlLacx8IX2C0AV4G8PQBjxqlh34AP3vG4TvwkihrDhCOTkZ0+KBqYo8JXRHQyKkBnPiPR4524CAAnwlXCIzjOc3e9AhKlogXoCspOnnz5jSxYBSPLlaeB/AcAFfZLNHuAvgKwK9i+kkB4/xRjqP6jXSQhJpPKUi4aYToc08MEF8ek9KfRo675qRv7qqTu+6kVLAv28+I7SuQ1E7/AHTQdDZ7M6+KAAAAAElFTkSuQmCC";
21
+
22
+var css =
23
+  ".WantedPublishPopover_wantedWrapper__3CrCz {\n  width: 366px;\n  height: 424px;\n  font-size: 18px;\n  text-align: center;\n}\n.WantedPublishPopover_wantedWrapper__3CrCz .WantedPublishPopover_closeBtnWrapper__1KV58 {\n  position: absolute;\n  top: 10px;\n  right: 16px;\n  width: 20px;\n  height: 20px;\n}\n.WantedPublishPopover_wantedWrapper__3CrCz .WantedPublishPopover_closeBtnWrapper__1KV58:focus {\n  outline: none;\n}\n.WantedPublishPopover_wantedWrapper__3CrCz .WantedPublishPopover_closeBtnWrapper__1KV58 > div.WantedPublishPopover_closeBtn__1aBMB {\n  border: none;\n  padding: 0px;\n  margin: 0px;\n  cursor: pointer;\n}\n.WantedPublishPopover_wantedWrapper__3CrCz .WantedPublishPopover_closeBtnWrapper__1KV58 > div.WantedPublishPopover_closeBtn__1aBMB > img {\n  width: 100%;\n}\n";
20 24
 var styles = {
21
-  "wantedWrapper": "WantedPublishPopover_wantedWrapper__3CrCz",
22
-  "closeBtnWrapper": "WantedPublishPopover_closeBtnWrapper__1KV58",
23
-  "closeBtn": "WantedPublishPopover_closeBtn__1aBMB"
25
+  wantedWrapper: "WantedPublishPopover_wantedWrapper__3CrCz",
26
+  closeBtnWrapper: "WantedPublishPopover_closeBtnWrapper__1KV58",
27
+  closeBtn: "WantedPublishPopover_closeBtn__1aBMB"
24 28
 };
25 29
 styleInject_es.styleInject(css);
26 30
 
27 31
 var WantedPublishPopover =
28
-/*#__PURE__*/
29
-function (_React$Component) {
30
-  inherits._inherits(WantedPublishPopover, _React$Component);
32
+  /*#__PURE__*/
33
+  (function(_React$Component) {
34
+    inherits._inherits(WantedPublishPopover, _React$Component);
35
+
36
+    function WantedPublishPopover(props) {
37
+      var _this;
31 38
 
32
-  function WantedPublishPopover(props) {
33
-    var _this;
39
+      inherits._classCallCheck(this, WantedPublishPopover);
34 40
 
35
-    inherits._classCallCheck(this, WantedPublishPopover);
41
+      _this = inherits._possibleConstructorReturn(
42
+        this,
43
+        inherits._getPrototypeOf(WantedPublishPopover).call(this, props)
44
+      );
36 45
 
37
-    _this = inherits._possibleConstructorReturn(this, inherits._getPrototypeOf(WantedPublishPopover).call(this, props));
46
+      _this.handleClose = function() {
47
+        var handleConfirm = _this.props.handleConfirm;
38 48
 
39
-    _this.handleClose = function () {
40
-      var handleConfirm = _this.props.handleConfirm;
49
+        if (handleConfirm) {
50
+          _this.handleUpdateCurrentWanted(_this.state.current_wanted, function(
51
+            value
52
+          ) {
53
+            handleConfirm(Number(value).toFixed(2));
54
+          });
55
+        }
41 56
 
42
-      if (handleConfirm) {
43
-        _this.handleUpdateCurrentWanted(_this.state.current_wanted, function (value) {
44
-          handleConfirm(Number(value).toFixed(2));
57
+        _this.setState({
58
+          visible: false
45 59
         });
46
-      }
60
+      };
61
+
62
+      _this.clearCurrentWanted = function(cb) {
63
+        _this.setState(
64
+          {
65
+            current_wanted: null
66
+          },
67
+          function() {
68
+            return cb();
69
+          }
70
+        );
71
+      };
47 72
 
48
-      _this.setState({
49
-        visible: false
50
-      });
51
-    };
73
+      _this.handleUpdateCurrentWanted = function(value, afterUpdate) {
74
+        if (!value) return;
75
+        var result;
76
+        result = value;
52 77
 
53
-    _this.clearCurrentWanted = function (cb) {
54
-      _this.setState({
55
-        current_wanted: null
56
-      }, function () {
57
-        return cb();
58
-      });
59
-    };
60
-
61
-    _this.handleUpdateCurrentWanted = function (value, afterUpdate) {
62
-      if (!value) return;
63
-      var result;
64
-      result = value;
65
-
66
-      if (parseInt("".concat(value), 10) === value) {
67
-        result = Number(value);
68
-      }
78
+        if (parseInt("".concat(value), 10) === value) {
79
+          result = Number(value);
80
+        }
69 81
 
70
-      if (!result) return;
71
-      if (result > 10000) result = 10000;
72
-      if (result < 5) result = 5;
73
-
74
-      _this.setState({
75
-        current_wanted: result
76
-      }, function () {
77
-        return afterUpdate && afterUpdate(result);
78
-      });
79
-    };
80
-
81
-    _this.state = {
82
-      visible: false,
83
-      current_wanted: null
84
-    };
85
-    return _this;
86
-  }
87
-
88
-  inherits._createClass(WantedPublishPopover, [{
89
-    key: "renderInitView",
90
-    value: function renderInitView() {
91
-      var _this2 = this;
92
-
93
-      var current_wanted = this.state.current_wanted;
94
-      return React__default.createElement(WantedPublishView.default, {
95
-        type: "pop",
96
-        current_wanted: current_wanted,
97
-        InputWantedValueChange: function InputWantedValueChange(v) {
98
-          return _this2.setState({
99
-            current_wanted: v
100
-          });
101
-        },
102
-        InputWantedPressEnter: function InputWantedPressEnter(v) {
103
-          return _this2.handleUpdateCurrentWanted(v, _this2.handleClose);
104
-        },
105
-        InputWantedOnBlur: function InputWantedOnBlur(v) {
106
-          return _this2.handleUpdateCurrentWanted(v);
107
-        },
108
-        InputWantedClear: function InputWantedClear() {
109
-          return _this2.clearCurrentWanted(_this2.handleClose);
110
-        },
111
-        CloseFunction: this.handleClose
112
-      });
113
-    }
114
-  }, {
115
-    key: "render",
116
-    value: function render() {
117
-      var _this3 = this;
118
-
119
-      var _this$props = this.props,
120
-          children = _this$props.children,
121
-          _this$props$popoverCo = _this$props.popoverConfig,
122
-          popoverConfig = _this$props$popoverCo === void 0 ? {} : _this$props$popoverCo;
123
-      return React__default.createElement(antd.Popover, Object.assign({
124
-        placement: "left",
125
-        trigger: "click",
126
-        visible: this.state.visible,
127
-        onVisibleChange: function onVisibleChange(value) {
128
-          if (!value) {
129
-            _this3.handleClose();
82
+        if (!result) return;
83
+        if (result > 10000) result = 10000;
84
+        if (result < 5) result = 5;
85
+
86
+        _this.setState(
87
+          {
88
+            current_wanted: result
89
+          },
90
+          function() {
91
+            return afterUpdate && afterUpdate(result);
130 92
           }
93
+        );
94
+      };
131 95
 
132
-          _this3.setState({
133
-            visible: value
96
+      _this.state = {
97
+        visible: false,
98
+        current_wanted: null
99
+      };
100
+      return _this;
101
+    }
102
+
103
+    inherits._createClass(WantedPublishPopover, [
104
+      {
105
+        key: "renderInitView",
106
+        value: function renderInitView() {
107
+          var _this2 = this;
108
+
109
+          var current_wanted = this.state.current_wanted;
110
+          return React__default.createElement(WantedPublishView.default, {
111
+            type: "pop",
112
+            current_wanted: current_wanted,
113
+            InputWantedValueChange: function InputWantedValueChange(v) {
114
+              return _this2.setState({
115
+                current_wanted: v
116
+              });
117
+            },
118
+            InputWantedPressEnter: function InputWantedPressEnter(v) {
119
+              return _this2.handleUpdateCurrentWanted(v, _this2.handleClose);
120
+            },
121
+            InputWantedOnBlur: function InputWantedOnBlur(v) {
122
+              return _this2.handleUpdateCurrentWanted(v);
123
+            },
124
+            InputWantedClear: function InputWantedClear() {
125
+              return _this2.clearCurrentWanted(_this2.handleClose);
126
+            },
127
+            CloseFunction: this.handleClose
134 128
           });
135 129
         }
136
-      }, popoverConfig, {
137
-        content: React__default.createElement("div", {
138
-          className: styles.wantedWrapper
139
-        }, React__default.createElement("div", {
140
-          role: "button",
141
-          tabIndex: 1,
142
-          className: styles.closeBtnWrapper
143
-        }, React__default.createElement("div", {
144
-          className: styles.closeBtn,
145
-          onClick: this.handleClose
146
-        }, React__default.createElement("img", {
147
-          src: img,
148
-          alt: "close wanted button"
149
-        }))), this.renderInitView())
150
-      }), children);
151
-    }
152
-  }]);
130
+      },
131
+      {
132
+        key: "render",
133
+        value: function render() {
134
+          var _this3 = this;
135
+
136
+          var _this$props = this.props,
137
+            children = _this$props.children,
138
+            _this$props$popoverCo = _this$props.popoverConfig,
139
+            popoverConfig =
140
+              _this$props$popoverCo === void 0 ? {} : _this$props$popoverCo;
141
+          return React__default.createElement(
142
+            antd.Popover,
143
+            Object.assign(
144
+              {
145
+                placement: "left",
146
+                trigger: "click",
147
+                visible: this.state.visible,
148
+                onVisibleChange: function onVisibleChange(value) {
149
+                  if (!value) {
150
+                    _this3.handleClose();
151
+                  }
152
+
153
+                  _this3.setState({
154
+                    visible: value
155
+                  });
156
+                }
157
+              },
158
+              popoverConfig,
159
+              {
160
+                content: React__default.createElement(
161
+                  "div",
162
+                  {
163
+                    className: styles.wantedWrapper
164
+                  },
165
+                  React__default.createElement(
166
+                    "div",
167
+                    {
168
+                      role: "button",
169
+                      tabIndex: 1,
170
+                      className: styles.closeBtnWrapper
171
+                    },
172
+                    React__default.createElement(
173
+                      "div",
174
+                      {
175
+                        className: styles.closeBtn,
176
+                        onClick: this.handleClose
177
+                      },
178
+                      React__default.createElement("img", {
179
+                        src: img,
180
+                        alt: "close wanted button"
181
+                      })
182
+                    )
183
+                  ),
184
+                  this.renderInitView()
185
+                )
186
+              }
187
+            ),
188
+            children
189
+          );
190
+        }
191
+      }
192
+    ]);
153 193
 
154
-  return WantedPublishPopover;
155
-}(React__default.Component);
194
+    return WantedPublishPopover;
195
+  })(React__default.Component);
156 196
 
157 197
 exports.WantedPublishPopover = WantedPublishPopover;
158 198
 exports.default = WantedPublishPopover;

+ 1
- 1
lib/WantedPublishPopover/index.js.map
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 16
- 13
lib/WantedPublishView/index.d.ts Ver arquivo

@@ -1,20 +1,23 @@
1 1
 /// <reference types="react" />
2
-import React from 'react';
2
+import React from "react";
3 3
 interface WantedPublishViewProps {
4
-    type?: 'pop' | 'modal';
5
-    wrapperClass?: string;
6
-    current_wanted: number | string | null;
7
-    InputWantedValueChange: Function;
8
-    InputWantedPressEnter: Function;
9
-    InputWantedOnBlur: Function;
10
-    InputWantedClear: Function;
11
-    CloseFunction: Function;
4
+  type?: "pop" | "modal";
5
+  wrapperClass?: string;
6
+  current_wanted: number | string | null;
7
+  InputWantedValueChange: Function;
8
+  InputWantedPressEnter: Function;
9
+  InputWantedOnBlur: Function;
10
+  InputWantedClear: Function;
11
+  CloseFunction: Function;
12 12
 }
13 13
 interface WantedPublishViewState {
14
-    payment?: number;
14
+  payment?: number;
15 15
 }
16
-declare class WantedPublishView extends React.Component<WantedPublishViewProps, WantedPublishViewState> {
17
-    constructor(props: WantedPublishViewProps);
18
-    render(): JSX.Element;
16
+declare class WantedPublishView extends React.Component<
17
+  WantedPublishViewProps,
18
+  WantedPublishViewState
19
+> {
20
+  constructor(props: WantedPublishViewProps);
21
+  render(): JSX.Element;
19 22
 }
20 23
 export { WantedPublishView as default };

+ 162
- 98
lib/WantedPublishView/index.js
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 1
- 1
lib/WantedPublishView/index.js.map
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 16
- 5
lib/_commonjsHelpers-72d386ba.js Ver arquivo

@@ -1,13 +1,24 @@
1
-'use strict';
1
+"use strict";
2 2
 
3
-var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
3
+var commonjsGlobal =
4
+  typeof globalThis !== "undefined"
5
+    ? globalThis
6
+    : typeof window !== "undefined"
7
+    ? window
8
+    : typeof global !== "undefined"
9
+    ? global
10
+    : typeof self !== "undefined"
11
+    ? self
12
+    : {};
4 13
 
5
-function unwrapExports (x) {
6
-	return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
14
+function unwrapExports(x) {
15
+  return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, "default")
16
+    ? x["default"]
17
+    : x;
7 18
 }
8 19
 
9 20
 function createCommonjsModule(fn, module) {
10
-	return module = { exports: {} }, fn(module, module.exports), module.exports;
21
+  return (module = { exports: {} }), fn(module, module.exports), module.exports;
11 22
 }
12 23
 
13 24
 exports.commonjsGlobal = commonjsGlobal;

+ 1
- 1
lib/defineProperty-ba7cd53d.js Ver arquivo

@@ -1,4 +1,4 @@
1
-'use strict';
1
+"use strict";
2 2
 
3 3
 function _defineProperty(obj, key, value) {
4 4
   if (key in obj) {

+ 44
- 45
lib/index-44e17595.js Ver arquivo

@@ -1,54 +1,53 @@
1
-'use strict';
1
+"use strict";
2 2
 
3
-var _commonjsHelpers = require('./_commonjsHelpers-72d386ba.js');
3
+var _commonjsHelpers = require("./_commonjsHelpers-72d386ba.js");
4 4
 
5
-var classnames = _commonjsHelpers.createCommonjsModule(function (module) {
6
-/*!
5
+var classnames = _commonjsHelpers.createCommonjsModule(function(module) {
6
+  /*!
7 7
   Copyright (c) 2017 Jed Watson.
8 8
   Licensed under the MIT License (MIT), see
9 9
   http://jedwatson.github.io/classnames
10 10
 */
11
-/* global define */
12
-
13
-(function () {
14
-
15
-	var hasOwn = {}.hasOwnProperty;
16
-
17
-	function classNames () {
18
-		var classes = [];
19
-
20
-		for (var i = 0; i < arguments.length; i++) {
21
-			var arg = arguments[i];
22
-			if (!arg) continue;
23
-
24
-			var argType = typeof arg;
25
-
26
-			if (argType === 'string' || argType === 'number') {
27
-				classes.push(arg);
28
-			} else if (Array.isArray(arg) && arg.length) {
29
-				var inner = classNames.apply(null, arg);
30
-				if (inner) {
31
-					classes.push(inner);
32
-				}
33
-			} else if (argType === 'object') {
34
-				for (var key in arg) {
35
-					if (hasOwn.call(arg, key) && arg[key]) {
36
-						classes.push(key);
37
-					}
38
-				}
39
-			}
40
-		}
41
-
42
-		return classes.join(' ');
43
-	}
44
-
45
-	if ( module.exports) {
46
-		classNames.default = classNames;
47
-		module.exports = classNames;
48
-	} else {
49
-		window.classNames = classNames;
50
-	}
51
-}());
11
+  /* global define */
12
+
13
+  (function() {
14
+    var hasOwn = {}.hasOwnProperty;
15
+
16
+    function classNames() {
17
+      var classes = [];
18
+
19
+      for (var i = 0; i < arguments.length; i++) {
20
+        var arg = arguments[i];
21
+        if (!arg) continue;
22
+
23
+        var argType = typeof arg;
24
+
25
+        if (argType === "string" || argType === "number") {
26
+          classes.push(arg);
27
+        } else if (Array.isArray(arg) && arg.length) {
28
+          var inner = classNames.apply(null, arg);
29
+          if (inner) {
30
+            classes.push(inner);
31
+          }
32
+        } else if (argType === "object") {
33
+          for (var key in arg) {
34
+            if (hasOwn.call(arg, key) && arg[key]) {
35
+              classes.push(key);
36
+            }
37
+          }
38
+        }
39
+      }
40
+
41
+      return classes.join(" ");
42
+    }
43
+
44
+    if (module.exports) {
45
+      classNames.default = classNames;
46
+      module.exports = classNames;
47
+    } else {
48
+      window.classNames = classNames;
49
+    }
50
+  })();
52 51
 });
53 52
 
54 53
 exports.classnames = classnames;

+ 20
- 22
lib/index.js Ver arquivo

@@ -1,27 +1,25 @@
1
-'use strict';
2
-
3
-Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
-require('./inherits-c86d64c1.js');
6
-require('react');
7
-require('react-dom');
8
-var Modal = require('./Modal/index.js');
9
-require('./style-inject.es-dcee06b6.js');
10
-require('./defineProperty-ba7cd53d.js');
11
-require('./_commonjsHelpers-72d386ba.js');
12
-require('./index-44e17595.js');
13
-require('./utils-b800dc99.js');
14
-var ConsumeListView = require('./ConsumeListView/index.js');
15
-var PayPlatformOptions = require('./PayPlatformOptions/index.js');
16
-require('./slicedToArray-172f4624.js');
17
-require('antd');
18
-var PriceOptions = require('./PriceOptions/index.js');
19
-var WaitPayInfoView = require('./WaitPayInfoView/index.js');
20
-var AllocWantedModal = require('./AllocWantedModal/index.js');
21
-var WantedPublishView = require('./WantedPublishView/index.js');
22
-var WantedPublishPopover = require('./WantedPublishPopover/index.js');
1
+"use strict";
23 2
 
3
+Object.defineProperty(exports, "__esModule", { value: true });
24 4
 
5
+require("./inherits-c86d64c1.js");
6
+require("react");
7
+require("react-dom");
8
+var Modal = require("./Modal/index.js");
9
+require("./style-inject.es-dcee06b6.js");
10
+require("./defineProperty-ba7cd53d.js");
11
+require("./_commonjsHelpers-72d386ba.js");
12
+require("./index-44e17595.js");
13
+require("./utils-b800dc99.js");
14
+var ConsumeListView = require("./ConsumeListView/index.js");
15
+var PayPlatformOptions = require("./PayPlatformOptions/index.js");
16
+require("./slicedToArray-172f4624.js");
17
+require("antd");
18
+var PriceOptions = require("./PriceOptions/index.js");
19
+var WaitPayInfoView = require("./WaitPayInfoView/index.js");
20
+var AllocWantedModal = require("./AllocWantedModal/index.js");
21
+var WantedPublishView = require("./WantedPublishView/index.js");
22
+var WantedPublishPopover = require("./WantedPublishPopover/index.js");
25 23
 
26 24
 exports.Modal = Modal.default;
27 25
 exports.ConsumeListView = ConsumeListView.default;

+ 21
- 10
lib/inherits-c86d64c1.js Ver arquivo

@@ -1,4 +1,4 @@
1
-'use strict';
1
+"use strict";
2 2
 
3 3
 function _classCallCheck(instance, Constructor) {
4 4
   if (!(instance instanceof Constructor)) {
@@ -31,7 +31,12 @@ function _typeof(obj) {
31 31
     };
32 32
   } else {
33 33
     _typeof = function _typeof(obj) {
34
-      return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
34
+      return obj &&
35
+        typeof Symbol === "function" &&
36
+        obj.constructor === Symbol &&
37
+        obj !== Symbol.prototype
38
+        ? "symbol"
39
+        : typeof obj;
35 40
     };
36 41
   }
37 42
 
@@ -40,7 +45,9 @@ function _typeof(obj) {
40 45
 
41 46
 function _assertThisInitialized(self) {
42 47
   if (self === void 0) {
43
-    throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
48
+    throw new ReferenceError(
49
+      "this hasn't been initialised - super() hasn't been called"
50
+    );
44 51
   }
45 52
 
46 53
   return self;
@@ -55,17 +62,21 @@ function _possibleConstructorReturn(self, call) {
55 62
 }
56 63
 
57 64
 function _getPrototypeOf(o) {
58
-  _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) {
59
-    return o.__proto__ || Object.getPrototypeOf(o);
60
-  };
65
+  _getPrototypeOf = Object.setPrototypeOf
66
+    ? Object.getPrototypeOf
67
+    : function _getPrototypeOf(o) {
68
+        return o.__proto__ || Object.getPrototypeOf(o);
69
+      };
61 70
   return _getPrototypeOf(o);
62 71
 }
63 72
 
64 73
 function _setPrototypeOf(o, p) {
65
-  _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {
66
-    o.__proto__ = p;
67
-    return o;
68
-  };
74
+  _setPrototypeOf =
75
+    Object.setPrototypeOf ||
76
+    function _setPrototypeOf(o, p) {
77
+      o.__proto__ = p;
78
+      return o;
79
+    };
69 80
 
70 81
   return _setPrototypeOf(o, p);
71 82
 }

+ 15
- 4
lib/slicedToArray-172f4624.js Ver arquivo

@@ -1,11 +1,16 @@
1
-'use strict';
1
+"use strict";
2 2
 
3 3
 function _arrayWithHoles(arr) {
4 4
   if (Array.isArray(arr)) return arr;
5 5
 }
6 6
 
7 7
 function _iterableToArrayLimit(arr, i) {
8
-  if (!(Symbol.iterator in Object(arr) || Object.prototype.toString.call(arr) === "[object Arguments]")) {
8
+  if (
9
+    !(
10
+      Symbol.iterator in Object(arr) ||
11
+      Object.prototype.toString.call(arr) === "[object Arguments]"
12
+    )
13
+  ) {
9 14
     return;
10 15
   }
11 16
 
@@ -15,7 +20,11 @@ function _iterableToArrayLimit(arr, i) {
15 20
   var _e = undefined;
16 21
 
17 22
   try {
18
-    for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) {
23
+    for (
24
+      var _i = arr[Symbol.iterator](), _s;
25
+      !(_n = (_s = _i.next()).done);
26
+      _n = true
27
+    ) {
19 28
       _arr.push(_s.value);
20 29
 
21 30
       if (i && _arr.length === i) break;
@@ -39,7 +48,9 @@ function _nonIterableRest() {
39 48
 }
40 49
 
41 50
 function _slicedToArray(arr, i) {
42
-  return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest();
51
+  return (
52
+    _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest()
53
+  );
43 54
 }
44 55
 
45 56
 exports._slicedToArray = _slicedToArray;

+ 9
- 7
lib/style-inject.es-dcee06b6.js Ver arquivo

@@ -1,16 +1,18 @@
1
-'use strict';
1
+"use strict";
2 2
 
3 3
 function styleInject(css, ref) {
4
-  if ( ref === void 0 ) ref = {};
4
+  if (ref === void 0) ref = {};
5 5
   var insertAt = ref.insertAt;
6 6
 
7
-  if (!css || typeof document === 'undefined') { return; }
7
+  if (!css || typeof document === "undefined") {
8
+    return;
9
+  }
8 10
 
9
-  var head = document.head || document.getElementsByTagName('head')[0];
10
-  var style = document.createElement('style');
11
-  style.type = 'text/css';
11
+  var head = document.head || document.getElementsByTagName("head")[0];
12
+  var style = document.createElement("style");
13
+  style.type = "text/css";
12 14
 
13
-  if (insertAt === 'top') {
15
+  if (insertAt === "top") {
14 16
     if (head.firstChild) {
15 17
       head.insertBefore(style, head.firstChild);
16 18
     } else {

+ 23
- 10
lib/utils-b800dc99.d.ts Ver arquivo

@@ -2,16 +2,29 @@ declare const IMAGE_PROCESS = "?x-oss-process=image/resize,h_350";
2 2
 declare const IMAGE_PROCESS_SMALL = "?x-oss-process=image/resize,h_100";
3 3
 declare const IMAGE_PROCESS_LARGE = "?x-oss-process=image/resize,h_500";
4 4
 interface AddImageProcessOptions {
5
-    small?: boolean;
6
-    large?: boolean;
7
-    custom?: boolean;
8
-    width?: string;
9
-    height?: string;
5
+  small?: boolean;
6
+  large?: boolean;
7
+  custom?: boolean;
8
+  width?: string;
9
+  height?: string;
10 10
 }
11
-declare function addImageProcess(url: string, options?: AddImageProcessOptions): string;
11
+declare function addImageProcess(
12
+  url: string,
13
+  options?: AddImageProcessOptions
14
+): string;
12 15
 declare function formatMoney(input: any, fuzz?: number): any;
13
-type classSize = 'small' | 'normal' | 'large';
14
-declare function exportStyleSizeClass(styles: any, size: classSize): {
15
-    [x: number]: boolean;
16
+type classSize = "small" | "normal" | "large";
17
+declare function exportStyleSizeClass(
18
+  styles: any,
19
+  size: classSize
20
+): {
21
+  [x: number]: boolean;
22
+};
23
+export {
24
+  IMAGE_PROCESS,
25
+  IMAGE_PROCESS_SMALL,
26
+  IMAGE_PROCESS_LARGE,
27
+  addImageProcess,
28
+  formatMoney,
29
+  exportStyleSizeClass
16 30
 };
17
-export { IMAGE_PROCESS, IMAGE_PROCESS_SMALL, IMAGE_PROCESS_LARGE, addImageProcess, formatMoney, exportStyleSizeClass };

+ 18
- 12
lib/utils-b800dc99.js Ver arquivo

@@ -1,17 +1,20 @@
1
-'use strict';
1
+"use strict";
2 2
 
3
-var defineProperty = require('./defineProperty-ba7cd53d.js');
3
+var defineProperty = require("./defineProperty-ba7cd53d.js");
4 4
 
5
-var IMAGE_PROCESS = '?x-oss-process=image/resize,h_350';
6
-var IMAGE_PROCESS_SMALL = '?x-oss-process=image/resize,h_100';
7
-var IMAGE_PROCESS_LARGE = '?x-oss-process=image/resize,h_500';
5
+var IMAGE_PROCESS = "?x-oss-process=image/resize,h_350";
6
+var IMAGE_PROCESS_SMALL = "?x-oss-process=image/resize,h_100";
7
+var IMAGE_PROCESS_LARGE = "?x-oss-process=image/resize,h_500";
8 8
 function addImageProcess(url) {
9
-  var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {
10
-    width: '36px',
11
-    height: '36px'
12
-  };
13
-
14
-  if (url && url.indexOf('x-oss-process') > -1) {
9
+  var options =
10
+    arguments.length > 1 && arguments[1] !== undefined
11
+      ? arguments[1]
12
+      : {
13
+          width: "36px",
14
+          height: "36px"
15
+        };
16
+
17
+  if (url && url.indexOf("x-oss-process") > -1) {
15 18
     return url;
16 19
   }
17 20
 
@@ -24,7 +27,10 @@ function addImageProcess(url) {
24 27
   }
25 28
 
26 29
   if (options.custom) {
27
-    return "".concat(url, "?x-oss-process=image/resize,limit_0,m_fill,w_").concat(options.width, ",h_").concat(options.height);
30
+    return ""
31
+      .concat(url, "?x-oss-process=image/resize,limit_0,m_fill,w_")
32
+      .concat(options.width, ",h_")
33
+      .concat(options.height);
28 34
   }
29 35
 
30 36
   return url + IMAGE_PROCESS;

+ 1
- 1
lib/utils-b800dc99.js.map Ver arquivo

@@ -1 +1 @@
1
-{"version":3,"file":"utils-6b513b37.js","sources":["../src/components/Payment/Utils/utils.ts"],"sourcesContent":["\r\nexport const IMAGE_PROCESS = '?x-oss-process=image/resize,h_350';\r\nexport const IMAGE_PROCESS_SMALL = '?x-oss-process=image/resize,h_100';\r\nexport const IMAGE_PROCESS_LARGE = '?x-oss-process=image/resize,h_500';\r\n\r\ninterface AddImageProcessOptions {\r\n  small?: boolean;\r\n  large?: boolean;\r\n  custom?: boolean;\r\n  width?: string;\r\n  height?: string;\r\n}\r\n\r\nexport function addImageProcess(url: string, options: AddImageProcessOptions = { width: '36px', height: '36px' }) {\r\n  // 防止重复添加导致的url不正确\r\n  if (url && url.indexOf('x-oss-process') > -1) {\r\n    return url;\r\n  }\r\n  if (options.small) {\r\n    return url + IMAGE_PROCESS_SMALL;\r\n  }\r\n  if (options.large) {\r\n    return url + IMAGE_PROCESS_LARGE;\r\n  }\r\n  if (options.custom) {\r\n    return `${url}?x-oss-process=image/resize,limit_0,m_fill,w_${options.width},h_${options.height}`;\r\n  }\r\n  return url + IMAGE_PROCESS;\r\n}\r\n\r\nexport function formatMoney(input: any, fuzz = 2) {\r\n  if (isNaN(+input)) {\r\n    return input;\r\n  }\r\n  return (+input).toFixed(fuzz);\r\n}\r\n\r\ntype classSize = 'small'|'normal'|'large';\r\n\r\nexport function exportStyleSizeClass(styles: any, size: classSize) {\r\n  return {\r\n    [styles[size]]: true,\r\n  }\r\n}"],"names":["IMAGE_PROCESS","IMAGE_PROCESS_SMALL","IMAGE_PROCESS_LARGE","addImageProcess","url","options","width","height","indexOf","small","large","custom","exportStyleSizeClass","styles","size"],"mappings":";;;;AACO,IAAMA,aAAa,GAAG,mCAAtB;AACA,IAAMC,mBAAmB,GAAG,mCAA5B;AACA,IAAMC,mBAAmB,GAAG,mCAA5B;AAUD,SAAUC,eAAV,CAA0BC,GAA1B,EAA0G;MAAnEC,OAAmE,uEAAjC;AAAEC,IAAAA,KAAK,EAAE,MAAT;AAAiBC,IAAAA,MAAM,EAAE;AAAzB;;MAEzEH,GAAG,IAAIA,GAAG,CAACI,OAAJ,CAAY,eAAZ,IAA+B,CAAC,GAAG;WACrCJ;;;MAELC,OAAO,CAACI,OAAO;WACVL,GAAG,GAAGH;;;MAEXI,OAAO,CAACK,OAAO;WACVN,GAAG,GAAGF;;;MAEXG,OAAO,CAACM,QAAQ;qBACRP,6DAAmDC,OAAO,CAACC,qBAAWD,OAAO,CAACE;;;SAEnFH,GAAG,GAAGJ;;AAYT,SAAUY,oBAAV,CAA+BC,MAA/B,EAA4CC,IAA5C,EAA2D;4CAE5DD,MAAM,CAACC,IAAD,GAAS;;;;;;"}
1
+{"version":3,"file":"utils-6b513b37.js","sources":["../src/components/Payment/Utils/utils.ts"],"sourcesContent":["\nexport const IMAGE_PROCESS = '?x-oss-process=image/resize,h_350';\nexport const IMAGE_PROCESS_SMALL = '?x-oss-process=image/resize,h_100';\nexport const IMAGE_PROCESS_LARGE = '?x-oss-process=image/resize,h_500';\n\ninterface AddImageProcessOptions {\n  small?: boolean;\n  large?: boolean;\n  custom?: boolean;\n  width?: string;\n  height?: string;\n}\n\nexport function addImageProcess(url: string, options: AddImageProcessOptions = { width: '36px', height: '36px' }) {\n  // 防止重复添加导致的url不正确\n  if (url && url.indexOf('x-oss-process') > -1) {\n    return url;\n  }\n  if (options.small) {\n    return url + IMAGE_PROCESS_SMALL;\n  }\n  if (options.large) {\n    return url + IMAGE_PROCESS_LARGE;\n  }\n  if (options.custom) {\n    return `${url}?x-oss-process=image/resize,limit_0,m_fill,w_${options.width},h_${options.height}`;\n  }\n  return url + IMAGE_PROCESS;\n}\n\nexport function formatMoney(input: any, fuzz = 2) {\n  if (isNaN(+input)) {\n    return input;\n  }\n  return (+input).toFixed(fuzz);\n}\n\ntype classSize = 'small'|'normal'|'large';\n\nexport function exportStyleSizeClass(styles: any, size: classSize) {\n  return {\n    [styles[size]]: true,\n  }\n}"],"names":["IMAGE_PROCESS","IMAGE_PROCESS_SMALL","IMAGE_PROCESS_LARGE","addImageProcess","url","options","width","height","indexOf","small","large","custom","exportStyleSizeClass","styles","size"],"mappings":";;;;AACO,IAAMA,aAAa,GAAG,mCAAtB;AACA,IAAMC,mBAAmB,GAAG,mCAA5B;AACA,IAAMC,mBAAmB,GAAG,mCAA5B;AAUD,SAAUC,eAAV,CAA0BC,GAA1B,EAA0G;MAAnEC,OAAmE,uEAAjC;AAAEC,IAAAA,KAAK,EAAE,MAAT;AAAiBC,IAAAA,MAAM,EAAE;AAAzB;;MAEzEH,GAAG,IAAIA,GAAG,CAACI,OAAJ,CAAY,eAAZ,IAA+B,CAAC,GAAG;WACrCJ;;;MAELC,OAAO,CAACI,OAAO;WACVL,GAAG,GAAGH;;;MAEXI,OAAO,CAACK,OAAO;WACVN,GAAG,GAAGF;;;MAEXG,OAAO,CAACM,QAAQ;qBACRP,6DAAmDC,OAAO,CAACC,qBAAWD,OAAO,CAACE;;;SAEnFH,GAAG,GAAGJ;;AAYT,SAAUY,oBAAV,CAA+BC,MAA/B,EAA4CC,IAA5C,EAA2D;4CAE5DD,MAAM,CAACC,IAAD,GAAS;;;;;;"}

+ 2
- 1
stats.html
Diferenças do arquivo suprimidas por serem muito extensas
Ver arquivo


+ 1
- 139
stories/Payment.stories.tsx Ver arquivo

@@ -23,17 +23,13 @@ import PriceOptions from "@/components/Payment/PriceOptions";
23 23
 import PriceOptionsDoc from "@components/Payment/PriceOptions/README.md";
24 24
 import WaitPayInfoView from "@/components/Payment/WaitPayInfoView";
25 25
 import WaitPayInfoViewDoc from "@components/Payment/WaitPayInfoView/README.md";
26
-import AllocWantedModal from "@/components/Payment/AllocWantedModal";
27
-import WantedPublishView from "@/components/Payment/WantedPublishView";
28
-import WantedPublishPopover from "@/components/Payment/WantedPublishPopover";
29
-import WantedPublishModal from "@/components/Payment/WantedPublishModal";
30 26
 import { formatMoney } from "@components/Payment/Utils/utils";
31 27
 
32 28
 import { consumeList } from "./data/consumeList.json";
33 29
 
34 30
 const consumeData: any = consumeList;
35 31
 
36
-const stories = storiesOf("Payment", module);
32
+const stories = storiesOf("Payment/Common", module);
37 33
 stories.addDecorator(storyFn => (
38 34
   <div style={{ padding: "0px 40px" }}>{storyFn()}</div>
39 35
 ));
@@ -178,137 +174,3 @@ stories.add(
178 174
     }
179 175
   }
180 176
 );
181
-
182
-stories.add(
183
-  "AllocWantedModal",
184
-  () => {
185
-    return (
186
-      <AllocWantedModal
187
-        allocValue={number("allocValue", 100)}
188
-        sendValueRange={[number("minValue", 0), number("maxValue", 100)]}
189
-        sendRequest={(...args: any) => {
190
-          console.log(args);
191
-        }}
192
-        sendGiftData={{
193
-          answerId: text("answerId", "1"),
194
-          questionId: text("questionId", "1"),
195
-          toUserId: text("toUserId", "1")
196
-        }}
197
-        handleVisibleChange={visiable => {
198
-          console.log(visiable);
199
-        }}
200
-      >
201
-        <Button>Click it</Button>
202
-      </AllocWantedModal>
203
-    );
204
-  },
205
-  {
206
-    info: { inline: true },
207
-    notes: "A very simple example of addon notes"
208
-  }
209
-);
210
-
211
-stories.add(
212
-  "WantedPushView",
213
-  () => {
214
-    const [currentWanted, setCurrentWanted] = React.useState(0);
215
-    return (
216
-      <>
217
-        <WantedPublishView
218
-          type={select(
219
-            "type",
220
-            {
221
-              POP: "pop",
222
-              Modal: "modal"
223
-            },
224
-            "pop"
225
-          )}
226
-          wrapperClass="test_wrapper"
227
-          current_wanted={currentWanted}
228
-          InputWantedValueChange={(value: any) => setCurrentWanted(value)}
229
-          InputWantedOnBlur={(blurValue: any) => setCurrentWanted(blurValue)}
230
-          InputWantedClear={() => setCurrentWanted(0)}
231
-          InputWantedPressEnter={(enterValue: any) =>
232
-            setCurrentWanted(enterValue)
233
-          }
234
-          CloseFunction={() => {
235
-            console.log("Close Button");
236
-          }}
237
-        />
238
-        <Divider />
239
-        <div>currentWanted: {currentWanted}</div>
240
-      </>
241
-    );
242
-  },
243
-  {
244
-    info: { inline: true },
245
-    notes: "A very simple example of addon notes"
246
-  }
247
-);
248
-
249
-stories.add(
250
-  "WantedPublishPopover And Modal",
251
-  () => {
252
-    const [wanted, setWanted] = React.useState("");
253
-    return (
254
-      <div>
255
-        <div>
256
-          <WantedPublishModal>
257
-            <div>ModalClick</div>
258
-          </WantedPublishModal>
259
-        </div>
260
-        <Divider />
261
-        <div>
262
-          <WantedPublishPopover
263
-            popoverConfig={{
264
-              placement: select(
265
-                "popoverConfigPlacement",
266
-                {
267
-                  Undefined: undefined,
268
-                  Left: "left",
269
-                  Right: "right",
270
-                  Top: "top",
271
-                  Bottom: "bottom",
272
-                  TopLeft: "topLeft",
273
-                  TopRight: "topRight",
274
-                  BottomLeft: "bottomLeft",
275
-                  BottomRight: "bottomRight",
276
-                  LeftTop: "leftTop",
277
-                  LeftBottom: "leftBottom",
278
-                  RightTop: "rightTop",
279
-                  RightBottom: "rightBottom"
280
-                },
281
-                undefined
282
-              ),
283
-              trigger: select(
284
-                "popoverConfigTrigger",
285
-                {
286
-                  Undefined: undefined,
287
-                  Hover: "hover",
288
-                  Click: "click",
289
-                  Focus: "focus",
290
-                  ContextMenu: "contextMenu"
291
-                },
292
-                undefined
293
-              )
294
-            }}
295
-            handleConfirm={(value: any) => {
296
-              setWanted(value);
297
-            }}
298
-          >
299
-            <Button>HoverIt{wanted}</Button>
300
-          </WantedPublishPopover>
301
-        </div>
302
-        <Divider />
303
-        {/* 下面用于分割wanted值的渲染,防止Error */}
304
-        {(wanted => (
305
-          <div>wanted{wanted}</div>
306
-        ))(wanted)}
307
-      </div>
308
-    );
309
-  },
310
-  {
311
-    info: { inline: true },
312
-    notes: "A very simple example of addon notes"
313
-  }
314
-);

+ 152
- 0
stories/Wanted.stories.tsx Ver arquivo

@@ -0,0 +1,152 @@
1
+import { storiesOf } from "@storybook/react";
2
+import { number, select, text, withKnobs } from "@storybook/addon-knobs";
3
+import { withInfo } from "@storybook/addon-info";
4
+import { addReadme } from "storybook-readme";
5
+import React from "react";
6
+import AllocWantedModal from "@components/Payment/AllocWantedModal";
7
+import { Button, Divider } from "antd";
8
+import WantedPublishView from "@components/Payment/WantedPublishView";
9
+import WantedPublishModal from "@components/Payment/WantedPublishModal";
10
+import WantedPublishPopover from "@components/Payment/WantedPublishPopover";
11
+
12
+const stories = storiesOf("Payment/Wanted", module);
13
+stories.addDecorator(storyFn => (
14
+  <div style={{ padding: "0px 40px" }}>{storyFn()}</div>
15
+));
16
+stories.addDecorator(withKnobs);
17
+stories.addDecorator(withInfo);
18
+stories.addDecorator(addReadme);
19
+
20
+stories.add(
21
+  "AllocWantedModal",
22
+  () => {
23
+    return (
24
+      <AllocWantedModal
25
+        allocValue={number("allocValue", 100)}
26
+        sendValueRange={[number("minValue", 0), number("maxValue", 100)]}
27
+        sendRequest={(...args: any) => {
28
+          console.log(args);
29
+        }}
30
+        sendGiftData={{
31
+          answerId: text("answerId", "1"),
32
+          questionId: text("questionId", "1"),
33
+          toUserId: text("toUserId", "1")
34
+        }}
35
+        handleVisibleChange={visiable => {
36
+          console.log(visiable);
37
+        }}
38
+      >
39
+        <Button>Click it</Button>
40
+      </AllocWantedModal>
41
+    );
42
+  },
43
+  {
44
+    info: { inline: true },
45
+    notes: "A very simple example of addon notes"
46
+  }
47
+);
48
+
49
+stories.add(
50
+  "WantedPushView",
51
+  () => {
52
+    const [currentWanted, setCurrentWanted] = React.useState(0);
53
+    return (
54
+      <div style={{ border: "4px solid black", padding: "4px" }}>
55
+        <WantedPublishView
56
+          type={select(
57
+            "type",
58
+            {
59
+              POP: "pop",
60
+              Modal: "modal"
61
+            },
62
+            "pop"
63
+          )}
64
+          wrapperClass="test_wrapper"
65
+          current_wanted={currentWanted}
66
+          InputWantedValueChange={(value: any) => setCurrentWanted(value)}
67
+          InputWantedOnBlur={(blurValue: any) => setCurrentWanted(blurValue)}
68
+          InputWantedClear={() => setCurrentWanted(0)}
69
+          InputWantedPressEnter={(enterValue: any) =>
70
+            setCurrentWanted(enterValue)
71
+          }
72
+          CloseFunction={() => {
73
+            console.log("Close Button");
74
+          }}
75
+        />
76
+        <Divider />
77
+        <div>currentWanted: {currentWanted}</div>
78
+      </div>
79
+    );
80
+  },
81
+  {
82
+    info: { inline: true },
83
+    notes: "A very simple example of addon notes"
84
+  }
85
+);
86
+
87
+stories.add(
88
+  "WantedPublishPopover And Modal",
89
+  () => {
90
+    const [wanted, setWanted] = React.useState("");
91
+    return (
92
+      <div>
93
+        <div>
94
+          <WantedPublishModal>
95
+            <div>ModalClick</div>
96
+          </WantedPublishModal>
97
+        </div>
98
+        <Divider />
99
+        <div>
100
+          <WantedPublishPopover
101
+            popoverConfig={{
102
+              placement: select(
103
+                "popoverConfigPlacement",
104
+                {
105
+                  Undefined: undefined,
106
+                  Left: "left",
107
+                  Right: "right",
108
+                  Top: "top",
109
+                  Bottom: "bottom",
110
+                  TopLeft: "topLeft",
111
+                  TopRight: "topRight",
112
+                  BottomLeft: "bottomLeft",
113
+                  BottomRight: "bottomRight",
114
+                  LeftTop: "leftTop",
115
+                  LeftBottom: "leftBottom",
116
+                  RightTop: "rightTop",
117
+                  RightBottom: "rightBottom"
118
+                },
119
+                undefined
120
+              ),
121
+              trigger: select(
122
+                "popoverConfigTrigger",
123
+                {
124
+                  Undefined: undefined,
125
+                  Hover: "hover",
126
+                  Click: "click",
127
+                  Focus: "focus",
128
+                  ContextMenu: "contextMenu"
129
+                },
130
+                undefined
131
+              )
132
+            }}
133
+            handleConfirm={(value: any) => {
134
+              setWanted(value);
135
+            }}
136
+          >
137
+            <Button>HoverIt{wanted}</Button>
138
+          </WantedPublishPopover>
139
+        </div>
140
+        <Divider />
141
+        {/* 下面用于分割wanted值的渲染,防止Error */}
142
+        {(wanted => (
143
+          <div>wanted{wanted}</div>
144
+        ))(wanted)}
145
+      </div>
146
+    );
147
+  },
148
+  {
149
+    info: { inline: true },
150
+    notes: "A very simple example of addon notes"
151
+  }
152
+);