@titaui/pc 1.13.2-beta.17 → 1.13.2-beta.18

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -70,7 +70,6 @@ var ScrollContainer = /*#__PURE__*/function (_PureComponent) {
70
70
  clientHeight = _e$target.clientHeight,
71
71
  scrollHeight = _e$target.scrollHeight,
72
72
  scrollTop = _e$target.scrollTop;
73
- console.log("".concat(clientHeight, " + ").concat(scrollTop, " >= ").concat(scrollHeight, " - 50"));
74
73
  if (clientHeight + scrollTop >= scrollHeight - 50) _this.props.onScrollBottom(e);
75
74
  _this.scrolling = false;
76
75
 
@@ -41,7 +41,7 @@
41
41
  .search-input-box > input {
42
42
  background: #ffffff;
43
43
  border: 1px solid #e9edf0;
44
- border-radius: 999px;
44
+ border-radius: 18px;
45
45
  width: 100%;
46
46
  height: 100%;
47
47
  padding: 0 44px 0 11px;
@@ -254,6 +254,15 @@ var UploadMode = function UploadMode(_ref) {
254
254
  var onLocalUploadSuccessHandler = (0, _react.useCallback)(function (localFileList) {
255
255
  setLocalFileData(localFileList);
256
256
  }, []);
257
+ var onSelfUploadUploadSuccess = (0, _react.useCallback)(function (dragFileList) {
258
+ setAllFileData([].concat(_toConsumableArray(allFileData), _toConsumableArray(dragFileList.map(function (item) {
259
+ return {
260
+ key: item.uid,
261
+ type: 'drag',
262
+ fileData: item
263
+ };
264
+ }))));
265
+ }, [allFileData]);
257
266
  var onClickFileHandler = (0, _react.useCallback)(function (index, options) {
258
267
  var currentFile = allFileData[index];
259
268
 
@@ -264,7 +273,7 @@ var UploadMode = function UploadMode(_ref) {
264
273
  });
265
274
  qqFileData.splice(removeIndex, 1);
266
275
  setQQFileData(_toConsumableArray(qqFileData));
267
- } else {
276
+ } else if (currentFile.type === 'local') {
268
277
  var _removeIndex = localFileData.findIndex(function (item) {
269
278
  return item.uid === currentFile.key;
270
279
  });
@@ -316,6 +325,7 @@ var UploadMode = function UploadMode(_ref) {
316
325
  onUploadSuccess: onLocalUploadSuccessHandler
317
326
  });
318
327
  }, [restProps, onLocalUploadSuccessHandler]);
328
+ var onSelfUploadSubmit = (0, _react.useCallback)(function () {}, []);
319
329
  return /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, /*#__PURE__*/_react["default"].createElement(_dialogUploadType["default"], {
320
330
  uploadProps: uploadProps,
321
331
  onSelectQQDocs: onShowDialogQQDocs,
@@ -327,6 +337,12 @@ var UploadMode = function UploadMode(_ref) {
327
337
  visible: dialogQQDocsVidible,
328
338
  onClose: onHideDialogQQDocs,
329
339
  onSubmit: onSelectQQDocsFileHandler
340
+ }), /*#__PURE__*/_react["default"].createElement(_upload["default"], {
341
+ action: restProps.action,
342
+ dragFilesList: restProps.dragFilesList,
343
+ submitStatus: 1,
344
+ onSubmit: onSelfUploadSubmit,
345
+ onUploadSuccess: onSelfUploadUploadSuccess
330
346
  }), /*#__PURE__*/_react["default"].createElement(_titaUi.Tooltip, {
331
347
  container: document.body,
332
348
  content: /*#__PURE__*/_react["default"].createElement("p", {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@titaui/pc",
3
- "version": "1.13.2-beta.17",
3
+ "version": "1.13.2-beta.18",
4
4
  "nameCN": "",
5
5
  "description": "",
6
6
  "main": "lib/index.js",