@kmkf-fe-packages/basic-components 0.25.0-alpha.0 → 0.25.0-alpha.3
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.
package/dist/index.esm.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React, { useRef, useState, useEffect, forwardRef, useImperativeHandle, useMemo } from 'react';
|
|
2
2
|
import { Cascader, DatePicker, InputNumber, Input, Select, Upload, Image, message, Radio, Space, Spin, Modal, Button, Checkbox, Row, Col, Slider, Rate, Form, Tabs, ConfigProvider, Pagination, Popover, Table } from 'antd';
|
|
3
|
-
import { EyeOutlined, DeleteOutlined,
|
|
3
|
+
import { EyeOutlined, DeleteOutlined, CaretUpOutlined } from '@ant-design/icons';
|
|
4
4
|
import request, { extend as extend$1 } from 'umi-request';
|
|
5
5
|
import { CopyToClipboard } from 'react-copy-to-clipboard';
|
|
6
6
|
import { AddressData, BsAddressData, toTree, request as request$1, ExpressData, uuid, LogisticsAddressData } from '@kmkf-fe-packages/kmkf-utils';
|
|
@@ -516,8 +516,18 @@ function ApaasInput(props) {
|
|
|
516
516
|
var isNumber = props.isNumber,
|
|
517
517
|
replaceWarn = props.replaceWarn,
|
|
518
518
|
other = _objectWithoutProperties(props, _excluded$1);
|
|
519
|
+
var handleBlur = function handleBlur(e) {
|
|
520
|
+
// 去除头尾空格
|
|
521
|
+
e.target.value = e.target.value.trim();
|
|
522
|
+
var onChange = props.onChange,
|
|
523
|
+
onBlur = props.onBlur;
|
|
524
|
+
typeof onChange === 'function' && onChange(e);
|
|
525
|
+
typeof onBlur === 'function' && onBlur(e);
|
|
526
|
+
};
|
|
519
527
|
// @ts-ignore
|
|
520
|
-
return isNumber ? /*#__PURE__*/React.createElement(InputNumber, _objectSpread2({}, other)) : /*#__PURE__*/React.createElement(Input, _objectSpread2({}, other)
|
|
528
|
+
return isNumber ? /*#__PURE__*/React.createElement(InputNumber, _objectSpread2({}, other)) : /*#__PURE__*/React.createElement(Input, _objectSpread2(_objectSpread2({}, other), {}, {
|
|
529
|
+
onBlur: handleBlur
|
|
530
|
+
}));
|
|
521
531
|
}
|
|
522
532
|
|
|
523
533
|
function ApaasInputNumber(props) {
|
|
@@ -9725,6 +9735,7 @@ var LogisticsInterception = function LogisticsInterception(props) {
|
|
|
9725
9735
|
var address = AddressData.getInstance();
|
|
9726
9736
|
var _props$value = props.value,
|
|
9727
9737
|
value = _props$value === void 0 ? {} : _props$value,
|
|
9738
|
+
_props$logisticsOptio = props.logisticsOptions,
|
|
9728
9739
|
_props$expressInterce = props.expressInterceptData,
|
|
9729
9740
|
expressInterceptData = _props$expressInterce === void 0 ? [] : _props$expressInterce,
|
|
9730
9741
|
_props$required = props.required,
|
|
@@ -10016,62 +10027,6 @@ var LogisticsInterception = function LogisticsInterception(props) {
|
|
|
10016
10027
|
})));
|
|
10017
10028
|
};
|
|
10018
10029
|
|
|
10019
|
-
var LogisticsMoreInterception = function LogisticsMoreInterception(props) {
|
|
10020
|
-
var required = props.required,
|
|
10021
|
-
expressInterceptData = props.expressInterceptData,
|
|
10022
|
-
_props$value = props.value,
|
|
10023
|
-
value = _props$value === void 0 ? [] : _props$value,
|
|
10024
|
-
disabled = props.disabled,
|
|
10025
|
-
onChange = props.onChange,
|
|
10026
|
-
isEditing = props.isEditing;
|
|
10027
|
-
var _useState = useState(0),
|
|
10028
|
-
_useState2 = _slicedToArray(_useState, 2),
|
|
10029
|
-
changeIndex = _useState2[0],
|
|
10030
|
-
setChangeIndex = _useState2[1];
|
|
10031
|
-
var handleChange = function handleChange(val, index) {
|
|
10032
|
-
var newValue = cloneDeep(value);
|
|
10033
|
-
newValue.splice(index, 1, val);
|
|
10034
|
-
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
10035
|
-
};
|
|
10036
|
-
var handleDelete = function handleDelete(index) {
|
|
10037
|
-
var newValue = cloneDeep(value);
|
|
10038
|
-
newValue.splice(index, 1);
|
|
10039
|
-
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
10040
|
-
};
|
|
10041
|
-
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Space, {
|
|
10042
|
-
wrap: true
|
|
10043
|
-
}, (value || []).map(function (item, index) {
|
|
10044
|
-
return /*#__PURE__*/React.createElement("span", {
|
|
10045
|
-
style: {
|
|
10046
|
-
position: 'relative',
|
|
10047
|
-
color: changeIndex === index ? '#4569d4' : 'black',
|
|
10048
|
-
cursor: 'pointer'
|
|
10049
|
-
},
|
|
10050
|
-
onClick: function onClick() {
|
|
10051
|
-
return setChangeIndex(index);
|
|
10052
|
-
}
|
|
10053
|
-
}, "\u5305\u88F9".concat(index + 1), !disabled ? /*#__PURE__*/React.createElement(CloseCircleOutlined, {
|
|
10054
|
-
style: {
|
|
10055
|
-
position: 'absolute',
|
|
10056
|
-
right: '-7px',
|
|
10057
|
-
top: '-10px'
|
|
10058
|
-
},
|
|
10059
|
-
onClick: function onClick() {
|
|
10060
|
-
return handleDelete(index);
|
|
10061
|
-
}
|
|
10062
|
-
}) : null);
|
|
10063
|
-
})), /*#__PURE__*/React.createElement(LogisticsInterception, {
|
|
10064
|
-
required: required,
|
|
10065
|
-
expressInterceptData: expressInterceptData,
|
|
10066
|
-
value: value[changeIndex],
|
|
10067
|
-
disabled: disabled,
|
|
10068
|
-
isEditing: isEditing,
|
|
10069
|
-
onChange: function onChange(val) {
|
|
10070
|
-
return handleChange(val, changeIndex);
|
|
10071
|
-
}
|
|
10072
|
-
}));
|
|
10073
|
-
};
|
|
10074
|
-
|
|
10075
10030
|
var LogisticsTrajectory = function LogisticsTrajectory(props) {
|
|
10076
10031
|
var showField = props.showField,
|
|
10077
10032
|
_props$value = props.value,
|
|
@@ -12908,4 +12863,4 @@ var CalculationInput = function CalculationInput(props) {
|
|
|
12908
12863
|
}, config === null || config === void 0 ? void 0 : config.unit));
|
|
12909
12864
|
};
|
|
12910
12865
|
|
|
12911
|
-
export { ApaasAddress as Address, AliPay, Province as ApaasAddress, ApaasCascader, ApaasCheckbox, ApaasDate, withFormItem as ApaasHoc, ApaasInput, ApaasInputNumber, ApaasLogistics, ApaasMultipleSelect, ApaasPosting, ApaasRadio, ApaasRate, ApaasSelect, ApaasSlider, ApaasTextArea, ApaasUpload, index as ApaasUploadAsync, ApaasUploadFile, BsExchange, BsGoods, BsReissue, BsReturnGoods as BsReturn, index$1 as BsSystemOrder, BuyerNick, CalculationInput, ChooseBaby, CommonSystemOrder$1 as CommonMultiStatus, CommonStatus, CommonSystemOrder, ExpressLogistics, Goods, index$2 as GoodsTable, IdentifyAddress, Invoice, jstGoods as JstGoods, ItemList as JstItemList, LogisticsInterception,
|
|
12866
|
+
export { ApaasAddress as Address, AliPay, Province as ApaasAddress, ApaasCascader, ApaasCheckbox, ApaasDate, withFormItem as ApaasHoc, ApaasInput, ApaasInputNumber, ApaasLogistics, ApaasMultipleSelect, ApaasPosting, ApaasRadio, ApaasRate, ApaasSelect, ApaasSlider, ApaasTextArea, ApaasUpload, index as ApaasUploadAsync, ApaasUploadFile, BsExchange, BsGoods, BsReissue, BsReturnGoods as BsReturn, index$1 as BsSystemOrder, BuyerNick, CalculationInput, ChooseBaby, CommonSystemOrder$1 as CommonMultiStatus, CommonStatus, CommonSystemOrder, ExpressLogistics, Goods, index$2 as GoodsTable, IdentifyAddress, Invoice, jstGoods as JstGoods, ItemList as JstItemList, LogisticsInterception, LogisticsMoreTrajectory, LogisticsTrajectory, MsgStatus, ParseLogistics, Payment, RemarkInput as Remark, ExpressLogistics as ReturnLogistics, ShopNameSelect as ShopName, Status, Supplier, TBGoodId, TBGoodSerial, TradeId, WlnGoods };
|
package/dist/index.js
CHANGED
|
@@ -527,8 +527,18 @@ function ApaasInput(props) {
|
|
|
527
527
|
var isNumber = props.isNumber,
|
|
528
528
|
replaceWarn = props.replaceWarn,
|
|
529
529
|
other = _objectWithoutProperties(props, _excluded$1);
|
|
530
|
+
var handleBlur = function handleBlur(e) {
|
|
531
|
+
// 去除头尾空格
|
|
532
|
+
e.target.value = e.target.value.trim();
|
|
533
|
+
var onChange = props.onChange,
|
|
534
|
+
onBlur = props.onBlur;
|
|
535
|
+
typeof onChange === 'function' && onChange(e);
|
|
536
|
+
typeof onBlur === 'function' && onBlur(e);
|
|
537
|
+
};
|
|
530
538
|
// @ts-ignore
|
|
531
|
-
return isNumber ? /*#__PURE__*/React__default['default'].createElement(antd.InputNumber, _objectSpread2({}, other)) : /*#__PURE__*/React__default['default'].createElement(antd.Input, _objectSpread2({}, other)
|
|
539
|
+
return isNumber ? /*#__PURE__*/React__default['default'].createElement(antd.InputNumber, _objectSpread2({}, other)) : /*#__PURE__*/React__default['default'].createElement(antd.Input, _objectSpread2(_objectSpread2({}, other), {}, {
|
|
540
|
+
onBlur: handleBlur
|
|
541
|
+
}));
|
|
532
542
|
}
|
|
533
543
|
|
|
534
544
|
function ApaasInputNumber(props) {
|
|
@@ -9736,6 +9746,7 @@ var LogisticsInterception = function LogisticsInterception(props) {
|
|
|
9736
9746
|
var address = kmkfUtils.AddressData.getInstance();
|
|
9737
9747
|
var _props$value = props.value,
|
|
9738
9748
|
value = _props$value === void 0 ? {} : _props$value,
|
|
9749
|
+
_props$logisticsOptio = props.logisticsOptions,
|
|
9739
9750
|
_props$expressInterce = props.expressInterceptData,
|
|
9740
9751
|
expressInterceptData = _props$expressInterce === void 0 ? [] : _props$expressInterce,
|
|
9741
9752
|
_props$required = props.required,
|
|
@@ -10027,62 +10038,6 @@ var LogisticsInterception = function LogisticsInterception(props) {
|
|
|
10027
10038
|
})));
|
|
10028
10039
|
};
|
|
10029
10040
|
|
|
10030
|
-
var LogisticsMoreInterception = function LogisticsMoreInterception(props) {
|
|
10031
|
-
var required = props.required,
|
|
10032
|
-
expressInterceptData = props.expressInterceptData,
|
|
10033
|
-
_props$value = props.value,
|
|
10034
|
-
value = _props$value === void 0 ? [] : _props$value,
|
|
10035
|
-
disabled = props.disabled,
|
|
10036
|
-
onChange = props.onChange,
|
|
10037
|
-
isEditing = props.isEditing;
|
|
10038
|
-
var _useState = React.useState(0),
|
|
10039
|
-
_useState2 = _slicedToArray(_useState, 2),
|
|
10040
|
-
changeIndex = _useState2[0],
|
|
10041
|
-
setChangeIndex = _useState2[1];
|
|
10042
|
-
var handleChange = function handleChange(val, index) {
|
|
10043
|
-
var newValue = lodash.cloneDeep(value);
|
|
10044
|
-
newValue.splice(index, 1, val);
|
|
10045
|
-
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
10046
|
-
};
|
|
10047
|
-
var handleDelete = function handleDelete(index) {
|
|
10048
|
-
var newValue = lodash.cloneDeep(value);
|
|
10049
|
-
newValue.splice(index, 1);
|
|
10050
|
-
onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
|
|
10051
|
-
};
|
|
10052
|
-
return /*#__PURE__*/React__default['default'].createElement(React__default['default'].Fragment, null, /*#__PURE__*/React__default['default'].createElement(antd.Space, {
|
|
10053
|
-
wrap: true
|
|
10054
|
-
}, (value || []).map(function (item, index) {
|
|
10055
|
-
return /*#__PURE__*/React__default['default'].createElement("span", {
|
|
10056
|
-
style: {
|
|
10057
|
-
position: 'relative',
|
|
10058
|
-
color: changeIndex === index ? '#4569d4' : 'black',
|
|
10059
|
-
cursor: 'pointer'
|
|
10060
|
-
},
|
|
10061
|
-
onClick: function onClick() {
|
|
10062
|
-
return setChangeIndex(index);
|
|
10063
|
-
}
|
|
10064
|
-
}, "\u5305\u88F9".concat(index + 1), !disabled ? /*#__PURE__*/React__default['default'].createElement(icons.CloseCircleOutlined, {
|
|
10065
|
-
style: {
|
|
10066
|
-
position: 'absolute',
|
|
10067
|
-
right: '-7px',
|
|
10068
|
-
top: '-10px'
|
|
10069
|
-
},
|
|
10070
|
-
onClick: function onClick() {
|
|
10071
|
-
return handleDelete(index);
|
|
10072
|
-
}
|
|
10073
|
-
}) : null);
|
|
10074
|
-
})), /*#__PURE__*/React__default['default'].createElement(LogisticsInterception, {
|
|
10075
|
-
required: required,
|
|
10076
|
-
expressInterceptData: expressInterceptData,
|
|
10077
|
-
value: value[changeIndex],
|
|
10078
|
-
disabled: disabled,
|
|
10079
|
-
isEditing: isEditing,
|
|
10080
|
-
onChange: function onChange(val) {
|
|
10081
|
-
return handleChange(val, changeIndex);
|
|
10082
|
-
}
|
|
10083
|
-
}));
|
|
10084
|
-
};
|
|
10085
|
-
|
|
10086
10041
|
var LogisticsTrajectory = function LogisticsTrajectory(props) {
|
|
10087
10042
|
var showField = props.showField,
|
|
10088
10043
|
_props$value = props.value,
|
|
@@ -12958,7 +12913,6 @@ exports.Invoice = Invoice;
|
|
|
12958
12913
|
exports.JstGoods = jstGoods;
|
|
12959
12914
|
exports.JstItemList = ItemList;
|
|
12960
12915
|
exports.LogisticsInterception = LogisticsInterception;
|
|
12961
|
-
exports.LogisticsMoreInterception = LogisticsMoreInterception;
|
|
12962
12916
|
exports.LogisticsMoreTrajectory = LogisticsMoreTrajectory;
|
|
12963
12917
|
exports.LogisticsTrajectory = LogisticsTrajectory;
|
|
12964
12918
|
exports.MsgStatus = MsgStatus;
|
package/dist/src/index.d.ts
CHANGED
|
@@ -32,7 +32,6 @@ export { default as Invoice } from './business/Invoice';
|
|
|
32
32
|
export { default as Status } from './business/Status';
|
|
33
33
|
export { default as Payment } from './business/Payment';
|
|
34
34
|
export { default as LogisticsInterception } from './business/LogisticsInterception';
|
|
35
|
-
export { default as LogisticsMoreInterception } from './business/LogisticsMoreInterception';
|
|
36
35
|
export { default as LogisticsTrajectory } from './business/LogisticsTrajectory';
|
|
37
36
|
export { default as LogisticsMoreTrajectory } from './business/LogisticsMoreTrajectory';
|
|
38
37
|
export { default as Goods } from './common/Goods';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kmkf-fe-packages/basic-components",
|
|
3
|
-
"version": "0.25.0-alpha.
|
|
3
|
+
"version": "0.25.0-alpha.3",
|
|
4
4
|
"description": "> TODO: description",
|
|
5
5
|
"homepage": "",
|
|
6
6
|
"license": "ISC",
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"watch": "nodemon --ignore dist/ --ignore node_modules/ --watch src/ -C -e ts,tsx,less --debug -x 'yarn async'"
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@kmkf-fe-packages/kmkf-utils": "^0.
|
|
23
|
+
"@kmkf-fe-packages/kmkf-utils": "^0.24.1",
|
|
24
24
|
"ahooks": "^3.7.4",
|
|
25
25
|
"kmkf-monitor": "^0.8.8",
|
|
26
26
|
"lodash": "^4.17.21",
|
|
@@ -64,5 +64,5 @@
|
|
|
64
64
|
"publishConfig": {
|
|
65
65
|
"access": "public"
|
|
66
66
|
},
|
|
67
|
-
"gitHead": "
|
|
67
|
+
"gitHead": "0746b0db23513d40fb7ee8a71672560bdb7c57ed"
|
|
68
68
|
}
|