@para-ui/core 4.0.39 → 4.0.40

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/Selector/index.js CHANGED
@@ -65,8 +65,8 @@ var zh = {
65
65
  };
66
66
 
67
67
  var localeJson = {
68
- zh,
69
- en
68
+ zh: zh,
69
+ en: en
70
70
  };
71
71
 
72
72
  var css_248z$3 = "@charset \"UTF-8\";\n/**\n* @author linhd\n* @date 2023/4/11 14:16\n* @description 最新色卡\n*/\n.paraui-v4-selector-node {\n display: flex;\n justify-content: space-between;\n align-items: center;\n cursor: pointer;\n}\n.paraui-v4-selector-node:hover {\n background-color: rgb(247, 248, 250);\n}\n.paraui-v4-selector-node > .selector-node-left {\n display: flex;\n align-items: center;\n flex: 1;\n overflow: hidden;\n padding-right: 10px;\n}\n.paraui-v4-selector-node > .selector-node-left > .selector-node-radio {\n margin-right: 8px;\n display: flex;\n align-items: center;\n padding: 0;\n}\n.paraui-v4-selector-node > .selector-node-left > .selector-node-radio .radio-box {\n top: 0;\n}\n.paraui-v4-selector-node > .selector-node-left > .selector-node-check {\n margin-right: 8px;\n display: flex;\n align-items: center;\n padding: 0;\n}\n.paraui-v4-selector-node > .selector-node-left > .selector-node-check .checkbox-box {\n top: 0;\n}\n.paraui-v4-selector-node > .selector-node-left > .node-img {\n display: inline-block;\n width: 30px;\n height: 30px;\n margin-right: 8px;\n}\n.paraui-v4-selector-node > .selector-node-left > .node-img img {\n width: 30px;\n height: 30px;\n border-radius: 50%;\n}\n.paraui-v4-selector-node.paraui-v4-selector-node-branch {\n height: 30px;\n padding: 0 10px;\n}\n.paraui-v4-selector-node.paraui-v4-selector-node-branch.paraui-v4-selector-node-img {\n height: 44px;\n}\n.paraui-v4-selector-node.paraui-v4-selector-node-branch > .selector-node-left > .main-title {\n font-size: 14px;\n color: rgb(29, 33, 38);\n white-space: nowrap;\n height: 20px;\n line-height: 20px;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n.paraui-v4-selector-node.paraui-v4-selector-node-branch > .selector-node-left > .sub-title {\n margin-left: 8px;\n font-size: 14px;\n color: rgb(161, 168, 179);\n white-space: nowrap;\n height: 20px;\n line-height: 20px;\n overflow: hidden;\n text-overflow: ellipsis;\n min-width: 30px;\n}\n.paraui-v4-selector-node.paraui-v4-selector-node-branch > .selector-node-left > .tag {\n margin-left: 8px;\n background-color: rgba(46, 101, 230, 0.1);\n color: rgb(46, 101, 230);\n border-radius: 2px;\n font-size: 12px;\n padding: 0px 6px;\n white-space: nowrap;\n height: 20px;\n line-height: 20px;\n}\n.paraui-v4-selector-node.paraui-v4-selector-node-leaf {\n padding: 0px 10px;\n height: 44px;\n}\n.paraui-v4-selector-node.paraui-v4-selector-node-leaf > .selector-node-left > .title-box {\n flex: 1;\n overflow: hidden;\n}\n.paraui-v4-selector-node.paraui-v4-selector-node-leaf > .selector-node-left > .title-box > .main-title-box {\n display: flex;\n align-items: center;\n white-space: nowrap;\n}\n.paraui-v4-selector-node.paraui-v4-selector-node-leaf > .selector-node-left > .title-box > .main-title-box > .main-title {\n font-size: 14px;\n color: rgb(29, 33, 38);\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n.paraui-v4-selector-node.paraui-v4-selector-node-leaf > .selector-node-left > .title-box > .main-title-box > .tag {\n margin-left: 8px;\n background-color: rgba(46, 101, 230, 0.1);\n color: rgb(46, 101, 230);\n border-radius: 2px;\n font-size: 12px;\n padding: 0px 6px;\n white-space: nowrap;\n height: 20px;\n line-height: 20px;\n}\n.paraui-v4-selector-node.paraui-v4-selector-node-leaf > .selector-node-left > .title-box > .sub-title {\n font-size: 12px;\n color: rgb(161, 168, 179);\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n.paraui-v4-selector-node > .selector-node-right {\n display: flex;\n align-items: center;\n height: 100%;\n}\n.paraui-v4-selector-node > .selector-node-right > .detail {\n font-size: 14px;\n color: rgb(46, 101, 230);\n white-space: nowrap;\n padding: 0 4px;\n cursor: pointer;\n height: 24px;\n line-height: 24px;\n border-radius: 2px;\n}\n.paraui-v4-selector-node > .selector-node-right > .detail:hover {\n background-color: rgba(212, 218, 227, 0.4);\n}\n.paraui-v4-selector-node > .selector-node-right > .line {\n border-left: 1px solid rgb(213, 224, 250);\n margin: 0 8px;\n content: \"\";\n display: inline-block;\n height: 12px;\n}\n.paraui-v4-selector-node > .selector-node-right > .lower-child {\n font-size: 14px;\n color: rgb(46, 101, 230);\n white-space: nowrap;\n padding: 0 4px;\n cursor: pointer;\n height: 24px;\n line-height: 24px;\n border-radius: 2px;\n}\n.paraui-v4-selector-node > .selector-node-right > .lower-child:hover {\n background-color: rgb(234, 236, 241);\n}\n.paraui-v4-selector-node > .selector-node-right > .close {\n display: flex;\n align-items: center;\n color: rgb(46, 101, 230);\n white-space: nowrap;\n padding: 0 4px;\n cursor: pointer;\n height: 24px;\n line-height: 24px;\n border-radius: 2px;\n}\n.paraui-v4-selector-node > .selector-node-right > .close:hover > svg {\n color: rgb(46, 101, 230);\n}\n.paraui-v4-selector-node > .selector-node-right > .close > svg {\n font-size: 16px;\n color: rgb(92, 101, 115);\n}\n.paraui-v4-selector-node.paraui-v4-selector-node-edit > .selector-node-right > .detail, .paraui-v4-selector-node.paraui-v4-selector-node-edit > .selector-node-right > .lower-child {\n color: rgb(92, 101, 115);\n}\n.paraui-v4-selector-node.paraui-v4-selector-node-edit > .selector-node-right > .detail:hover, .paraui-v4-selector-node.paraui-v4-selector-node-edit > .selector-node-right > .lower-child:hover {\n color: rgb(46, 101, 230);\n}\n.paraui-v4-selector-node.paraui-v4-selector-node-disabled {\n cursor: not-allowed;\n}\n.paraui-v4-selector-node.paraui-v4-selector-node-disabled.paraui-v4-selector-node-branch > .selector-node-left > .main-title {\n color: rgb(161, 168, 179);\n}\n.paraui-v4-selector-node.paraui-v4-selector-node-disabled.paraui-v4-selector-node-leaf > .selector-node-left > .title-box > .main-title-box > .main-title {\n color: rgb(161, 168, 179);\n}\n.paraui-v4-selector-node.paraui-v4-selector-node-disabled > .selector-node-right > .lower-child {\n cursor: not-allowed;\n color: rgb(161, 168, 179);\n}\n.paraui-v4-selector-node.paraui-v4-selector-node-disabled-child > .selector-node-right > .lower-child {\n cursor: not-allowed;\n color: rgb(161, 168, 179);\n}\n\n.paraui-v4-selector-detail .selector-detail-popover-content.selector-detail-popover-content-loading {\n min-width: 100px;\n min-height: 50px;\n}";
@@ -329,57 +329,63 @@ var SelectorNode = function SelectorNode(props) {
329
329
  var css_248z$2 = "@charset \"UTF-8\";\n/**\n* @author linhd\n* @date 2023/4/11 14:16\n* @description 最新色卡\n*/\n.paraui-v4-selector-main {\n display: flex;\n flex-direction: column;\n height: 100%;\n width: 100%;\n}\n.paraui-v4-selector-main > .selectot-main-search {\n margin-bottom: 16px;\n border-bottom: 1px solid rgb(234, 236, 241);\n}\n.paraui-v4-selector-main > .selectot-main-search .text-field-content {\n border: none;\n height: 32px;\n}\n.paraui-v4-selector-main > .selectot-main-search .text-field-content .text-field-content-within-input {\n height: 32px !important;\n}\n.paraui-v4-selector-main > .selectot-main-search .text-field-content .text-field-content-within-input .text-field-label-placeholder {\n line-height: 32px !important;\n}\n.paraui-v4-selector-main > .selector-main-box {\n position: relative;\n width: 100%;\n height: 100%;\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content {\n display: flex;\n flex-direction: column;\n height: 100%;\n width: 100%;\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content > .nav-box {\n padding: 0 6px;\n margin-bottom: 4px;\n margin-top: 10px;\n line-height: 0;\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content > .selector-main-list-no-data {\n width: 100%;\n height: 100%;\n display: flex;\n align-items: center;\n justify-content: center;\n padding-bottom: 16px;\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content > .selector-main-list {\n overflow-y: hidden;\n display: flex;\n flex-direction: column;\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content > .selector-main-list > .selector-all-check {\n position: relative;\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content > .selector-main-list > .selector-all-check + .selector-group-title.selector-group-title-first {\n margin-top: 4px;\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content > .selector-main-list > .selector-main-list-content {\n overflow-y: hidden;\n position: relative;\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content > .selector-main-list > .selector-main-list-content:before {\n content: \"\";\n position: absolute;\n height: 30px;\n width: 100%;\n pointer-events: none;\n top: 0;\n left: 0;\n z-index: 1;\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content > .selector-main-list > .selector-main-list-content:after {\n content: \"\";\n position: absolute;\n height: 30px;\n width: 100%;\n pointer-events: none;\n bottom: 0;\n left: 0;\n z-index: 1;\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content > .selector-main-list > .selector-main-list-content.selector-main-list-scroll-top:after {\n box-shadow: inset 0px -10px 10px -8px rgba(0, 0, 0, 0.05);\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content > .selector-main-list > .selector-main-list-content.selector-main-list-scroll-middle:before {\n box-shadow: inset 0px 10px 10px -8px rgba(0, 0, 0, 0.05);\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content > .selector-main-list > .selector-main-list-content.selector-main-list-scroll-middle:after {\n box-shadow: inset 0px -10px 10px -8px rgba(0, 0, 0, 0.05);\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content > .selector-main-list > .selector-main-list-content.selector-main-list-scroll-bottom:before {\n box-shadow: inset 0px 10px 10px -8px rgba(0, 0, 0, 0.05);\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content > .selector-main-list > .selector-main-list-content > .selector-main-list-content-box {\n height: 100%;\n overflow-y: auto;\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content > .selector-main-list > .selector-main-list-content > .selector-main-list-content-box > .selector-group-title {\n padding: 0 12px;\n margin-top: 16px;\n margin-bottom: 4px;\n font-size: 14px;\n color: rgb(161, 168, 179);\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content > .selector-main-list > .selector-main-list-content > .selector-main-list-content-box > .selector-group-title.selector-group-title-first {\n margin-top: 0;\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content > .selector-main-list > .selector-main-list-more {\n padding: 0 10px;\n cursor: pointer;\n font-size: 14px;\n color: rgb(46, 101, 230);\n line-height: 30px;\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content > .selector-main-list > .selector-main-list-more:hover {\n color: rgb(87, 131, 235);\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content.selector-main-search-content {\n /*position: absolute;\n left: 0;\n top: 0;*/\n width: 100%;\n height: 100%;\n background-color: white;\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content.selector-main-content-all-check > .selector-main-list > .selector-main-list-content {\n max-height: calc(100% - 30px);\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content.selector-main-content-load-more > .selector-main-list > .selector-main-list-content {\n max-height: calc(100% - 30px);\n}\n.paraui-v4-selector-main > .selector-main-box > .selector-main-content.selector-main-content-all-check.selector-main-content-load-more > .selector-main-list > .selector-main-list-content {\n max-height: calc(100% - 30px - 30px);\n}\n.paraui-v4-selector-main.paraui-v4-selector-main-show-search > .selector-main-box {\n height: calc(100% - 49px);\n}\n.paraui-v4-selector-main.paraui-v4-selector-main-show-search > .selector-main-box > .selector-main-content.selector-main-list-box {\n display: none;\n}\n.paraui-v4-selector-main.paraui-v4-selector-main-search > .selector-main-box {\n height: calc(100% - 49px);\n}\n.paraui-v4-selector-main.paraui-v4-selector-main-search > .selector-main-box .selector-main-content .nav-box {\n margin-top: 0;\n}";
330
330
  styleInject(css_248z$2);
331
331
 
332
- const SelectorMainContent = props => {
333
- const {
334
- className,
335
- value,
336
- rowKey = 'key',
337
- nodeMode = 'branch',
338
- selectMode,
339
- loadMore = false,
340
- isAllCheck = false,
341
- detail,
342
- detailRender,
343
- isLazy,
344
- list,
345
- groupType,
346
- breadcrumbs,
347
- breadcrumbsSeparator = '-',
348
- breadcrumbsList = [],
349
- fieldConfig,
350
- disabled,
351
- disabledChild,
352
- emptyProps,
353
- loading,
354
- onClickBreadcrumbs,
355
- onLevel,
356
- onSelect,
357
- onLoad,
358
- onAllCheck
359
- } = props;
360
- const intl = useFormatMessage('Selector', localeJson);
361
- const [listCom, setListCom] = useState({});
362
- const constData = useRef({
332
+ var SelectorMainContent = function SelectorMainContent(props) {
333
+ var className = props.className,
334
+ value = props.value;
335
+ props.rowKey;
336
+ var _props$nodeMode = props.nodeMode,
337
+ nodeMode = _props$nodeMode === void 0 ? 'branch' : _props$nodeMode,
338
+ selectMode = props.selectMode,
339
+ _props$loadMore = props.loadMore,
340
+ loadMore = _props$loadMore === void 0 ? false : _props$loadMore,
341
+ _props$isAllCheck = props.isAllCheck,
342
+ isAllCheck = _props$isAllCheck === void 0 ? false : _props$isAllCheck,
343
+ detail = props.detail,
344
+ detailRender = props.detailRender,
345
+ isLazy = props.isLazy,
346
+ list = props.list,
347
+ groupType = props.groupType,
348
+ breadcrumbs = props.breadcrumbs,
349
+ _props$breadcrumbsSep = props.breadcrumbsSeparator,
350
+ breadcrumbsSeparator = _props$breadcrumbsSep === void 0 ? '-' : _props$breadcrumbsSep,
351
+ _props$breadcrumbsLis = props.breadcrumbsList,
352
+ breadcrumbsList = _props$breadcrumbsLis === void 0 ? [] : _props$breadcrumbsLis,
353
+ fieldConfig = props.fieldConfig,
354
+ disabled = props.disabled,
355
+ disabledChild = props.disabledChild,
356
+ emptyProps = props.emptyProps,
357
+ loading = props.loading,
358
+ onClickBreadcrumbs = props.onClickBreadcrumbs,
359
+ _onLevel = props.onLevel,
360
+ _onSelect = props.onSelect,
361
+ onLoad = props.onLoad,
362
+ onAllCheck = props.onAllCheck;
363
+ var intl = useFormatMessage('Selector', localeJson);
364
+ var _useState = useState({}),
365
+ _useState2 = _slicedToArray(_useState, 2),
366
+ listCom = _useState2[0],
367
+ setListCom = _useState2[1];
368
+ var constData = useRef({
363
369
  listTypeJson: {},
364
370
  fieldConfig: {},
365
371
  resizeTimer: null
366
372
  });
367
- const scrolltRef = useRef(null);
368
- const contentRef = useRef(null);
373
+ var scrolltRef = useRef(null);
374
+ var contentRef = useRef(null);
369
375
  constData.current.listTypeJson = ArrayToObject('value', groupType);
370
376
  constData.current.fieldConfig = fieldConfig || {};
371
- useEffect(() => {
377
+ useEffect(function () {
372
378
  changeResize();
373
- return () => {
379
+ return function () {
374
380
  clearTimeout(constData.current.resizeTimer);
375
381
  };
376
382
  }, []);
377
- useEffect(() => {
383
+ useEffect(function () {
378
384
  if (list && groupType && groupType.length > 0) {
379
- const json = {};
380
- for (let i = 0, l = list.length; i < l; i++) {
381
- const item = list[i];
382
- const type = item.type;
385
+ var json = {};
386
+ for (var i = 0, l = list.length; i < l; i++) {
387
+ var item = list[i];
388
+ var type = item.type;
383
389
  if (!json[type]) json[type] = [];
384
390
  json[type].push(item);
385
391
  }
@@ -387,17 +393,17 @@ const SelectorMainContent = props => {
387
393
  }
388
394
  }, [list]);
389
395
  /** 屏幕发生改变 */
390
- const changeResize = () => {
396
+ var changeResize = function changeResize() {
391
397
  clearTimeout(constData.current.resizeTimer);
392
- constData.current.resizeTimer = setTimeout(() => {
398
+ constData.current.resizeTimer = setTimeout(function () {
393
399
  onScroll();
394
400
  }, 100);
395
401
  };
396
402
  /** 滚动 */
397
- const onScroll = () => {
403
+ var onScroll = function onScroll() {
398
404
  if (!contentRef.current || !scrolltRef.current) return;
399
- const scrollBox = scrolltRef.current;
400
- const contentBox = contentRef.current;
405
+ var scrollBox = scrolltRef.current;
406
+ var contentBox = contentRef.current;
401
407
  contentBox.classList.remove('selector-main-list-scroll-top', 'selector-main-list-scroll-bottom', 'selector-main-list-scroll-middle');
402
408
  if (scrollBox.scrollHeight <= scrollBox.clientHeight) return;
403
409
  // 滚动条初始化
@@ -414,17 +420,17 @@ const SelectorMainContent = props => {
414
420
  contentBox.classList.add('selector-main-list-scroll-middle');
415
421
  };
416
422
  /** 判断是否全选,半选 */
417
- const handAllCheckFunc = () => {
418
- const json = {
423
+ var handAllCheckFunc = function handAllCheckFunc() {
424
+ var json = {
419
425
  checked: false,
420
426
  indeterminate: false
421
427
  };
422
428
  // 不存在value, 没有数据, 全选没转态
423
429
  if (!value || !list || list.length === 0) return json;
424
- for (let i = 0, l = list.length; i < l; i++) {
425
- const item = list[i];
426
- const key = item.key;
427
- const disabledItem = handDisabled(item);
430
+ for (var i = 0, l = list.length; i < l; i++) {
431
+ var item = list[i];
432
+ var key = item.key;
433
+ var disabledItem = handDisabled(item);
428
434
  if (disabledItem) {
429
435
  if (value[key]) json.checked = true;
430
436
  continue;
@@ -448,7 +454,7 @@ const SelectorMainContent = props => {
448
454
  return json;
449
455
  };
450
456
  /** 处理禁用状态 */
451
- const handDisabled = item => {
457
+ var handDisabled = function handDisabled(item) {
452
458
  if (disabled) {
453
459
  if (disabled === true) return true;
454
460
  if (disabled instanceof Array) {
@@ -461,7 +467,7 @@ const SelectorMainContent = props => {
461
467
  return false;
462
468
  };
463
469
  /** 处理禁用下级状态 */
464
- const handDisabledChild = item => {
470
+ var handDisabledChild = function handDisabledChild(item) {
465
471
  if (disabledChild) {
466
472
  if (disabledChild === true) return true;
467
473
  if (disabledChild instanceof Array) {
@@ -474,12 +480,12 @@ const SelectorMainContent = props => {
474
480
  return false;
475
481
  };
476
482
  /** 全选 */
477
- const handAllCheck = () => {
483
+ var handAllCheck = function handAllCheck() {
478
484
  // 只存在复选框模式
479
485
  if (!isAllCheck || selectMode !== 'check') return null;
480
- const checkJson = handAllCheckFunc();
481
- const onAllCheckCom = () => {
482
- let bol = true;
486
+ var checkJson = handAllCheckFunc();
487
+ var onAllCheckCom = function onAllCheckCom() {
488
+ var bol = true;
483
489
  if (checkJson.checked) bol = false;
484
490
  onAllCheck && onAllCheck(bol);
485
491
  };
@@ -496,11 +502,11 @@ const SelectorMainContent = props => {
496
502
  }));
497
503
  };
498
504
  /** 点击查看更多 */
499
- const clickLoad = () => {
505
+ var clickLoad = function clickLoad() {
500
506
  onLoad && onLoad();
501
507
  };
502
508
  /** 查看更多 */
503
- const handLoadMore = () => {
509
+ var handLoadMore = function handLoadMore() {
504
510
  if (!loadMore) return null;
505
511
  return jsx("div", Object.assign({
506
512
  className: "selector-main-list-more",
@@ -516,29 +522,33 @@ const SelectorMainContent = props => {
516
522
  }));
517
523
  };
518
524
  /** 判断是否选中 */
519
- const handCheck = item => {
520
- let bol = false;
525
+ var handCheck = function handCheck(item) {
526
+ var bol = false;
521
527
  if (value && value[item.key]) bol = true;
522
528
  return bol;
523
529
  };
524
530
  /** 处理每个节点的配置 */
525
- const handNodeConfig = item => {
526
- const json = {
531
+ var handNodeConfig = function handNodeConfig(item) {
532
+ var json = {
527
533
  useCase: 'view',
528
- detail,
529
- nodeMode,
534
+ detail: detail,
535
+ nodeMode: nodeMode,
530
536
  disabled: handDisabled(item),
531
537
  disabledChild: handDisabledChild(item),
532
- onLevel: () => onLevel && onLevel(item),
533
- onSelect: () => onSelect && onSelect(item),
538
+ onLevel: function onLevel() {
539
+ return _onLevel && _onLevel(item);
540
+ },
541
+ onSelect: function onSelect() {
542
+ return _onSelect && _onSelect(item);
543
+ },
534
544
  checked: handCheck(item)
535
545
  };
536
546
  /** 节点类型 */
537
547
  if (item.leaf !== undefined) json.nodeMode = item.leaf ? 'leaf' : 'branch';
538
548
  /** 渲染字段 */
539
- const arr = ['img', 'mainTitle', 'subTitle', 'tag', 'tagStyle'];
540
- for (let i = 0, l = arr.length; i < l; i++) {
541
- const key = arr[i];
549
+ var arr = ['img', 'mainTitle', 'subTitle', 'tag', 'tagStyle'];
550
+ for (var i = 0, l = arr.length; i < l; i++) {
551
+ var key = arr[i];
542
552
  json[key] = item[key];
543
553
  }
544
554
  /** 判断是否具有选择 */
@@ -552,7 +562,7 @@ const SelectorMainContent = props => {
552
562
  json.child = item.child;
553
563
  } else {
554
564
  // 全量数据
555
- const children = item.children || [];
565
+ var children = item.children || [];
556
566
  if (children && children.length > 0) {
557
567
  json.child = true;
558
568
  }
@@ -561,29 +571,43 @@ const SelectorMainContent = props => {
561
571
  }
562
572
  /** 详情render */
563
573
  if (detailRender) {
564
- json.detailRender = () => __awaiter(void 0, void 0, void 0, function* () {
565
- const Dom = yield detailRender(item, true);
566
- return Dom;
567
- });
574
+ json.detailRender = function () {
575
+ return __awaiter(void 0, void 0, void 0, /*#__PURE__*/regenerator.mark(function _callee() {
576
+ var Dom;
577
+ return regenerator.wrap(function _callee$(_context) {
578
+ while (1) switch (_context.prev = _context.next) {
579
+ case 0:
580
+ _context.next = 2;
581
+ return detailRender(item, true);
582
+ case 2:
583
+ Dom = _context.sent;
584
+ return _context.abrupt("return", Dom);
585
+ case 4:
586
+ case "end":
587
+ return _context.stop();
588
+ }
589
+ }, _callee);
590
+ }));
591
+ };
568
592
  }
569
593
  if (item.detail !== undefined) json.detail = item.detail;
570
594
  return json;
571
595
  };
572
596
  /** 渲染list节点 */
573
- const handListNode = arr => {
574
- return arr === null || arr === void 0 ? void 0 : arr.map((item, index) => {
597
+ var handListNode = function handListNode(arr) {
598
+ return arr === null || arr === void 0 ? void 0 : arr.map(function (item, index) {
575
599
  return jsx(SelectorNode, Object.assign({}, handNodeConfig(item)), index);
576
600
  });
577
601
  };
578
602
  /** 处理节点dom */
579
- const handNode = () => {
603
+ var handNode = function handNode() {
580
604
  // 分组渲染
581
605
  if (groupType && groupType.length > 0) {
582
606
  return jsx(Fragment, {
583
- children: groupType.map((item, index) => {
584
- const type = item.value;
585
- const listData = listCom[type] || [];
586
- let str = 'selector-group-title';
607
+ children: groupType.map(function (item, index) {
608
+ var type = item.value;
609
+ var listData = listCom[type] || [];
610
+ var str = 'selector-group-title';
587
611
  if (index === 0) str += ' selector-group-title-first';
588
612
  return jsxs(Fragment$1, {
589
613
  children: [listData.length > 0 && jsx("div", Object.assign({
@@ -598,11 +622,11 @@ const SelectorMainContent = props => {
598
622
  return handListNode(list || []);
599
623
  };
600
624
  /** 点击面包屑 */
601
- const onClickBreadcrums = item => {
625
+ var onClickBreadcrums = function onClickBreadcrums(item) {
602
626
  onClickBreadcrumbs && onClickBreadcrumbs(item);
603
627
  };
604
628
  /** 面包屑dom */
605
- const handBreadcrumbs = () => {
629
+ var handBreadcrumbs = function handBreadcrumbs() {
606
630
  if (!breadcrumbs || breadcrumbsList.length === 0) return null;
607
631
  return jsx("div", Object.assign({
608
632
  className: "nav-box"
@@ -615,7 +639,7 @@ const SelectorMainContent = props => {
615
639
  }));
616
640
  };
617
641
  /** 处理内容 */
618
- const handContent = () => {
642
+ var handContent = function handContent() {
619
643
  if ((list === null || list === void 0 ? void 0 : list.length) === 0 && !loading) {
620
644
  // 空状态
621
645
  return jsx("div", Object.assign({
@@ -643,8 +667,8 @@ const SelectorMainContent = props => {
643
667
  })), handLoadMore()]
644
668
  }));
645
669
  };
646
- const handClass = () => {
647
- let str = 'selector-main-content';
670
+ var handClass = function handClass() {
671
+ var str = 'selector-main-content';
648
672
  if (className) str += " ".concat(className);
649
673
  if (disabled) str += ' selector-main-content-disabled';
650
674
  if (isAllCheck && selectMode === 'check') str += ' selector-main-content-all-check';
@@ -658,87 +682,99 @@ const SelectorMainContent = props => {
658
682
  children: [handBreadcrumbs(), handContent()]
659
683
  }));
660
684
  };
661
- const SelectorMain = props => {
662
- const {
663
- className,
664
- style,
665
- url,
666
- value,
667
- rowKey = 'key',
668
- nodeMode = 'branch',
669
- selectMode,
670
- loadMore = false,
671
- searchLoadMore = false,
672
- isAllCheck = false,
673
- disabled,
674
- disabledChild,
675
- detail,
676
- detailRender,
677
- isLazy,
678
- list,
679
- groupType,
680
- groupRange,
681
- search,
682
- searchVal = '',
683
- searchPlaceholder,
684
- searchTrigger,
685
- searchLoading,
686
- searchList,
687
- loading,
688
- breadcrumbs,
689
- breadcrumbsSeparator = '-',
690
- breadcrumbsList = [],
691
- fieldConfig,
692
- onClickBreadcrumbs,
693
- onLevel,
694
- onSelect,
695
- onLoad,
696
- onAllCheck,
697
- onSearch,
698
- onRefresh
699
- } = props;
700
- const intl = useFormatMessage('Selector', localeJson);
701
- const [showSearch, setShowSearch] = useState(false); // 显示搜索/
702
- const [searchStr, setSearchStr] = useState('');
703
- const constData = useRef({
685
+ var SelectorMain = function SelectorMain(props) {
686
+ var className = props.className,
687
+ style = props.style,
688
+ url = props.url,
689
+ value = props.value,
690
+ _props$rowKey2 = props.rowKey,
691
+ rowKey = _props$rowKey2 === void 0 ? 'key' : _props$rowKey2,
692
+ _props$nodeMode2 = props.nodeMode,
693
+ nodeMode = _props$nodeMode2 === void 0 ? 'branch' : _props$nodeMode2,
694
+ selectMode = props.selectMode,
695
+ _props$loadMore2 = props.loadMore,
696
+ loadMore = _props$loadMore2 === void 0 ? false : _props$loadMore2,
697
+ _props$searchLoadMore = props.searchLoadMore,
698
+ searchLoadMore = _props$searchLoadMore === void 0 ? false : _props$searchLoadMore,
699
+ _props$isAllCheck2 = props.isAllCheck,
700
+ isAllCheck = _props$isAllCheck2 === void 0 ? false : _props$isAllCheck2,
701
+ disabled = props.disabled,
702
+ disabledChild = props.disabledChild,
703
+ detail = props.detail,
704
+ detailRender = props.detailRender,
705
+ isLazy = props.isLazy,
706
+ list = props.list,
707
+ groupType = props.groupType,
708
+ groupRange = props.groupRange,
709
+ search = props.search,
710
+ _props$searchVal = props.searchVal,
711
+ searchVal = _props$searchVal === void 0 ? '' : _props$searchVal,
712
+ searchPlaceholder = props.searchPlaceholder,
713
+ searchTrigger = props.searchTrigger,
714
+ searchLoading = props.searchLoading,
715
+ searchList = props.searchList,
716
+ loading = props.loading,
717
+ breadcrumbs = props.breadcrumbs,
718
+ _props$breadcrumbsSep2 = props.breadcrumbsSeparator,
719
+ breadcrumbsSeparator = _props$breadcrumbsSep2 === void 0 ? '-' : _props$breadcrumbsSep2,
720
+ _props$breadcrumbsLis2 = props.breadcrumbsList,
721
+ breadcrumbsList = _props$breadcrumbsLis2 === void 0 ? [] : _props$breadcrumbsLis2,
722
+ fieldConfig = props.fieldConfig,
723
+ onClickBreadcrumbs = props.onClickBreadcrumbs,
724
+ onLevel = props.onLevel,
725
+ onSelect = props.onSelect,
726
+ onLoad = props.onLoad,
727
+ onAllCheck = props.onAllCheck,
728
+ onSearch = props.onSearch,
729
+ onRefresh = props.onRefresh;
730
+ var intl = useFormatMessage('Selector', localeJson);
731
+ var _useState3 = useState(false),
732
+ _useState4 = _slicedToArray(_useState3, 2),
733
+ showSearch = _useState4[0],
734
+ setShowSearch = _useState4[1]; // 显示搜索/
735
+ var _useState5 = useState(''),
736
+ _useState6 = _slicedToArray(_useState5, 2),
737
+ searchStr = _useState6[0],
738
+ setSearchStr = _useState6[1];
739
+ var constData = useRef({
704
740
  searchTimer: null,
705
741
  searchStr: ''
706
742
  });
707
- useEffect(() => {
743
+ useEffect(function () {
708
744
  if (!searchVal) return;
709
745
  constData.current.searchStr = searchVal.val;
710
746
  setSearchStr(searchVal.val);
711
747
  if (searchVal.val !== '') setShowSearch(true);
712
748
  }, [searchVal]);
713
749
  /** 改变搜索框 */
714
- const changeSearch = val => {
750
+ var changeSearch = function changeSearch(val) {
715
751
  setSearchStr(val);
716
752
  constData.current.searchStr = val;
717
753
  if (searchTrigger !== 'onEnter') onSearchCom();
718
754
  };
719
755
  /** 搜索框回车事件 */
720
- const onEnterSearch = () => {
756
+ var onEnterSearch = function onEnterSearch() {
721
757
  onSearchCom(true);
722
758
  };
723
759
  /** 点击搜索按钮 */
724
- const onClickRightIcon = () => {
760
+ var onClickRightIcon = function onClickRightIcon() {
725
761
  onSearchCom(true);
726
762
  };
727
763
  /** 点击清除按钮 */
728
- const onClear = () => {
764
+ var onClear = function onClear() {
729
765
  onSearchCom();
730
766
  };
731
767
  /** 向外抛出搜索事件 */
732
- const onSearchCom = bol => {
768
+ var onSearchCom = function onSearchCom(bol) {
733
769
  clearTimeout(constData.current.searchTimer);
734
- constData.current.searchTimer = setTimeout(() => {
770
+ constData.current.searchTimer = setTimeout(function () {
735
771
  setShowSearch(!!constData.current.searchStr);
736
772
  onSearch && onSearch(constData.current.searchStr, !!bol);
737
773
  }, 300);
738
774
  };
739
775
  /** 搜索dom */
740
- const handSearchDom = () => {
741
- const handSearchIcon = () => {
776
+ var handSearchDom = function handSearchDom() {
777
+ var handSearchIcon = function handSearchIcon() {
742
778
  if (!searchStr) {
743
779
  // 本地数据且没有自定义刷新事件
744
780
  if (!url && !onRefresh) {
@@ -769,23 +805,27 @@ const SelectorMain = props => {
769
805
  /** 点击下级
770
806
  * @param isSearch {boolean}
771
807
  * */
772
- const onLevelCom = isSearch => item => {
773
- if (isSearch) {
774
- constData.current.searchStr = '';
775
- setSearchStr('');
776
- setShowSearch(false);
777
- }
778
- onLevel && onLevel(item, isSearch);
808
+ var onLevelCom = function onLevelCom(isSearch) {
809
+ return function (item) {
810
+ if (isSearch) {
811
+ constData.current.searchStr = '';
812
+ setSearchStr('');
813
+ setShowSearch(false);
814
+ }
815
+ onLevel && onLevel(item, isSearch);
816
+ };
779
817
  };
780
818
  /**
781
819
  * 加载更多
782
820
  * @param isSearch {boolean} 是否搜索
783
821
  * */
784
- const onLoadCom = isSearch => () => {
785
- onLoad && onLoad(isSearch);
822
+ var onLoadCom = function onLoadCom(isSearch) {
823
+ return function () {
824
+ onLoad && onLoad(isSearch);
825
+ };
786
826
  };
787
827
  /** 渲染列表 */
788
- const handListDom = () => {
828
+ var handListDom = function handListDom() {
789
829
  return jsx(SelectorMainContent, {
790
830
  className: "selector-main-list-box",
791
831
  value: value,
@@ -814,7 +854,7 @@ const SelectorMain = props => {
814
854
  }, "list");
815
855
  };
816
856
  /** 渲染搜索列表 */
817
- const handSearchList = () => {
857
+ var handSearchList = function handSearchList() {
818
858
  if (!showSearch) return;
819
859
  return jsx(SelectorMainContent, {
820
860
  className: 'selector-main-search-content',
@@ -839,14 +879,14 @@ const SelectorMain = props => {
839
879
  }, "search");
840
880
  };
841
881
  /** 处理loading */
842
- const handLoading = () => {
882
+ var handLoading = function handLoading() {
843
883
  if (searchLoading || loading) {
844
884
  return jsx(Loading, {});
845
885
  }
846
886
  };
847
887
  // 处理class
848
- const handClass = () => {
849
- let str = "".concat($prefixCls, "-selector-main");
888
+ var handClass = function handClass() {
889
+ var str = "".concat($prefixCls, "-selector-main");
850
890
  if (className) str += " ".concat(className);
851
891
  if (selectMode === 'check') str += " ".concat($prefixCls, "-selector-main-select");
852
892
  if (showSearch) str += " ".concat($prefixCls, "-selector-main-show-search");
@@ -869,38 +909,40 @@ const SelectorMain = props => {
869
909
  var css_248z$1 = "@charset \"UTF-8\";\n/**\n* @author linhd\n* @date 2023/4/11 14:16\n* @description 最新色卡\n*/\n.paraui-v4-selector-data.paraui-v4-selector-data-node > .selector-data-node-box {\n padding: 10px 0 10px 0;\n display: flex;\n flex-direction: column;\n height: 100%;\n}\n.paraui-v4-selector-data.paraui-v4-selector-data-node > .selector-data-node-box > .title {\n font-size: 14px;\n color: rgb(29, 33, 38);\n padding: 0 10px;\n margin-bottom: 10px;\n}\n.paraui-v4-selector-data.paraui-v4-selector-data-node > .selector-data-node-box > .title > .title-content {\n margin-left: 8px;\n}\n.paraui-v4-selector-data.paraui-v4-selector-data-node > .selector-data-node-box > .content {\n overflow-y: auto;\n}\n.paraui-v4-selector-data.paraui-v4-selector-data-tag > .selector-data-tag-box {\n padding-top: 10px;\n height: 100%;\n display: flex;\n flex-direction: column;\n}\n.paraui-v4-selector-data.paraui-v4-selector-data-tag > .selector-data-tag-box > .title {\n font-size: 14px;\n color: rgb(29, 33, 38);\n padding: 0 10px;\n}\n.paraui-v4-selector-data.paraui-v4-selector-data-tag > .selector-data-tag-box > .content {\n padding: 0 10px 10px 10px;\n overflow: auto;\n}\n.paraui-v4-selector-data.paraui-v4-selector-data-tag > .selector-data-tag-box > .content > .content-tag {\n display: inline-flex;\n height: 24px;\n align-items: center;\n padding: 0 10px;\n border-radius: 4px;\n background-color: rgb(234, 236, 241);\n margin-right: 4px;\n margin-top: 4px;\n max-width: calc(100% - 8px);\n}\n.paraui-v4-selector-data.paraui-v4-selector-data-tag > .selector-data-tag-box > .content > .content-tag > span {\n font-size: 14px;\n color: rgb(29, 33, 38);\n overflow: hidden;\n}\n.paraui-v4-selector-data.paraui-v4-selector-data-tag > .selector-data-tag-box > .content > .content-tag > svg {\n font-size: 16px;\n margin-left: 4px;\n color: rgb(29, 33, 38);\n cursor: pointer;\n}\n.paraui-v4-selector-data.paraui-v4-selector-data-tag > .selector-data-tag-box > .content > .content-tag > svg:hover {\n color: rgb(46, 101, 230);\n}";
870
910
  styleInject(css_248z$1);
871
911
 
872
- const SelectorData = props => {
873
- const {
874
- className,
875
- layout = 'node',
876
- style,
877
- list,
878
- groupType,
879
- nodeMode,
880
- backDataFieldConfig,
881
- detail,
882
- detailRender,
883
- disabled,
884
- handSelectorNodeInfo,
885
- selectDataTitleRender,
886
- selectRenderItem,
887
- selectRender,
888
- onClose
889
- } = props;
890
- const intl = useFormatMessage('Selector', localeJson);
891
- const [listCom, setListCom] = useState({});
892
- const constData = useRef({
912
+ var SelectorData = function SelectorData(props) {
913
+ var className = props.className,
914
+ _props$layout = props.layout,
915
+ layout = _props$layout === void 0 ? 'node' : _props$layout,
916
+ style = props.style,
917
+ list = props.list,
918
+ groupType = props.groupType,
919
+ nodeMode = props.nodeMode,
920
+ backDataFieldConfig = props.backDataFieldConfig,
921
+ detail = props.detail,
922
+ detailRender = props.detailRender,
923
+ disabled = props.disabled,
924
+ handSelectorNodeInfo = props.handSelectorNodeInfo,
925
+ selectDataTitleRender = props.selectDataTitleRender,
926
+ selectRenderItem = props.selectRenderItem,
927
+ selectRender = props.selectRender,
928
+ _onClose = props.onClose;
929
+ var intl = useFormatMessage('Selector', localeJson);
930
+ var _useState = useState({}),
931
+ _useState2 = _slicedToArray(_useState, 2),
932
+ listCom = _useState2[0],
933
+ setListCom = _useState2[1];
934
+ var constData = useRef({
893
935
  listTypeJson: {},
894
936
  backDataFieldConfig: {}
895
937
  });
896
938
  constData.current.listTypeJson = ArrayToObject('value', groupType);
897
939
  constData.current.backDataFieldConfig = backDataFieldConfig || {};
898
- useEffect(() => {
940
+ useEffect(function () {
899
941
  if (list && groupType && groupType.length > 0) {
900
- const json = {};
901
- for (let i = 0, l = list.length; i < l; i++) {
902
- const item = list[i];
903
- const type = item[constData.current.backDataFieldConfig.type || ''];
942
+ var json = {};
943
+ for (var i = 0, l = list.length; i < l; i++) {
944
+ var item = list[i];
945
+ var type = item[constData.current.backDataFieldConfig.type || ''];
904
946
  if (!json[type]) json[type] = [];
905
947
  json[type].push(item);
906
948
  }
@@ -908,12 +950,12 @@ const SelectorData = props => {
908
950
  }
909
951
  }, [list]);
910
952
  /** 处理禁用 */
911
- const handDisabled = itemConfig => {
953
+ var handDisabled = function handDisabled(itemConfig) {
912
954
  if (disabled) {
913
955
  if (disabled === true) return true;
914
956
  if (disabled instanceof Array) {
915
- const keyStr = (backDataFieldConfig === null || backDataFieldConfig === void 0 ? void 0 : backDataFieldConfig.key) || '';
916
- const val = itemConfig[keyStr];
957
+ var keyStr = (backDataFieldConfig === null || backDataFieldConfig === void 0 ? void 0 : backDataFieldConfig.key) || '';
958
+ var val = itemConfig[keyStr];
917
959
  if (disabled.indexOf(val) !== -1) {
918
960
  return true;
919
961
  }
@@ -922,40 +964,56 @@ const SelectorData = props => {
922
964
  return false;
923
965
  };
924
966
  /** 处理每个节点的配置 */
925
- const handNodeConfig = (itemConfig, index) => {
926
- let item = itemConfig;
967
+ var handNodeConfig = function handNodeConfig(itemConfig, index) {
968
+ var item = itemConfig;
927
969
  if (handSelectorNodeInfo) item = handSelectorNodeInfo(itemConfig);
928
- const disabledItem = handDisabled(itemConfig);
929
- const json = {
970
+ var disabledItem = handDisabled(itemConfig);
971
+ var json = {
930
972
  useCase: 'edit',
931
973
  close: !disabledItem,
932
- detail,
974
+ detail: detail,
933
975
  data: item,
934
- nodeMode,
935
- onClose: () => onClose && onClose(item, index),
976
+ nodeMode: nodeMode,
977
+ onClose: function onClose() {
978
+ return _onClose && _onClose(item, index);
979
+ },
936
980
  disabled: handDisabled(itemConfig),
937
981
  tagStyle: item.tagStyle
938
982
  };
939
983
  if (selectRenderItem) {
940
- json.leftRender = () => {
984
+ json.leftRender = function () {
941
985
  return selectRenderItem(itemConfig);
942
986
  };
943
987
  }
944
988
  /** 节点类型 */
945
989
  if (item.leaf !== undefined) json.nodeMode = item.leaf ? 'leaf' : 'branch';
946
990
  /** 渲染字段 */
947
- const arr = ['img', 'mainTitle', 'subTitle', 'tag'];
948
- for (let i = 0, l = arr.length; i < l; i++) {
949
- const key = arr[i] || '';
950
- const backName = backDataFieldConfig && backDataFieldConfig[key] || '';
991
+ var arr = ['img', 'mainTitle', 'subTitle', 'tag'];
992
+ for (var i = 0, l = arr.length; i < l; i++) {
993
+ var key = arr[i] || '';
994
+ var backName = backDataFieldConfig && backDataFieldConfig[key] || '';
951
995
  json[key] = item[backName];
952
996
  }
953
997
  /** 详情render */
954
998
  if (detailRender) {
955
- json.detailRender = () => __awaiter(void 0, void 0, void 0, function* () {
956
- const Dom = yield detailRender(item, false);
957
- return Dom;
958
- });
999
+ json.detailRender = function () {
1000
+ return __awaiter(void 0, void 0, void 0, /*#__PURE__*/regenerator.mark(function _callee() {
1001
+ var Dom;
1002
+ return regenerator.wrap(function _callee$(_context) {
1003
+ while (1) switch (_context.prev = _context.next) {
1004
+ case 0:
1005
+ _context.next = 2;
1006
+ return detailRender(item, false);
1007
+ case 2:
1008
+ Dom = _context.sent;
1009
+ return _context.abrupt("return", Dom);
1010
+ case 4:
1011
+ case "end":
1012
+ return _context.stop();
1013
+ }
1014
+ }, _callee);
1015
+ }));
1016
+ };
959
1017
  }
960
1018
  if (item.detail !== undefined) json.detail = item.detail;
961
1019
  /** 是否具有删除 */
@@ -963,23 +1021,23 @@ const SelectorData = props => {
963
1021
  return json;
964
1022
  };
965
1023
  /** 处理节点 */
966
- const handNode = () => {
1024
+ var handNode = function handNode() {
967
1025
  if (selectRender) {
968
1026
  return selectRender(list || []);
969
1027
  }
970
- return list === null || list === void 0 ? void 0 : list.map((item, index) => {
1028
+ return list === null || list === void 0 ? void 0 : list.map(function (item, index) {
971
1029
  return jsx(SelectorNode, Object.assign({}, handNodeConfig(item, index)), index);
972
1030
  });
973
1031
  };
974
1032
  /** 处理标题 */
975
- const handTitle = () => {
976
- const handTitleTag = () => {
1033
+ var handTitle = function handTitle() {
1034
+ var handTitleTag = function handTitleTag() {
977
1035
  if (selectDataTitleRender) return selectDataTitleRender(list);
978
1036
  if (groupType) {
979
1037
  return jsx(Fragment, {
980
- children: groupType.map((item, index) => {
981
- let num = 0;
982
- const val = item.value;
1038
+ children: groupType.map(function (item, index) {
1039
+ var num = 0;
1040
+ var val = item.value;
983
1041
  if (listCom[val]) num = listCom[val].length;
984
1042
  if (num === 0) return;
985
1043
  return jsxs("span", Object.assign({
@@ -1004,7 +1062,7 @@ const SelectorData = props => {
1004
1062
  }));
1005
1063
  };
1006
1064
  // 处理节点内容
1007
- const handContentNode = () => {
1065
+ var handContentNode = function handContentNode() {
1008
1066
  return jsxs("div", Object.assign({
1009
1067
  className: "selector-data-node-box"
1010
1068
  }, {
@@ -1016,13 +1074,13 @@ const SelectorData = props => {
1016
1074
  }));
1017
1075
  };
1018
1076
  // 处理内容
1019
- const handDetailTagContent = () => {
1077
+ var handDetailTagContent = function handDetailTagContent() {
1020
1078
  if (selectRender) {
1021
1079
  return selectRender(list || []);
1022
1080
  }
1023
1081
  return jsx(Fragment, {
1024
- children: list === null || list === void 0 ? void 0 : list.map((item, index) => {
1025
- const disabledItem = handDisabled(item);
1082
+ children: list === null || list === void 0 ? void 0 : list.map(function (item, index) {
1083
+ var disabledItem = handDisabled(item);
1026
1084
  return jsxs("span", Object.assign({
1027
1085
  className: "content-tag"
1028
1086
  }, {
@@ -1031,14 +1089,16 @@ const SelectorData = props => {
1031
1089
  children: item[(backDataFieldConfig === null || backDataFieldConfig === void 0 ? void 0 : backDataFieldConfig.mainTitle) || ''] || item[(backDataFieldConfig === null || backDataFieldConfig === void 0 ? void 0 : backDataFieldConfig.key) || '']
1032
1090
  })
1033
1091
  }), !disabledItem && jsx(CloseIcon, {
1034
- onClick: () => onClose && onClose(item, index)
1092
+ onClick: function onClick() {
1093
+ return _onClose && _onClose(item, index);
1094
+ }
1035
1095
  })]
1036
1096
  }), index);
1037
1097
  })
1038
1098
  });
1039
1099
  };
1040
1100
  // 处理tag内容
1041
- const handContentTag = () => {
1101
+ var handContentTag = function handContentTag() {
1042
1102
  return jsxs("div", Object.assign({
1043
1103
  className: "selector-data-tag-box"
1044
1104
  }, {
@@ -1049,8 +1109,8 @@ const SelectorData = props => {
1049
1109
  }))]
1050
1110
  }));
1051
1111
  };
1052
- const handClass = () => {
1053
- let str = "".concat($prefixCls, "-selector-data");
1112
+ var handClass = function handClass() {
1113
+ var str = "".concat($prefixCls, "-selector-data");
1054
1114
  if (layout) str += " ".concat($prefixCls, "-selector-data-").concat(layout);
1055
1115
  if (disabled === true) str += " ".concat($prefixCls, "-selector-data-disabled");
1056
1116
  if (className) str += " ".concat(className);
@@ -1068,11 +1128,9 @@ const SelectorData = props => {
1068
1128
  * 发送请求
1069
1129
  * @param obj {ReqFuncProps} 请求信息
1070
1130
  */
1071
- const reqFunc = obj => {
1072
- const {
1073
- method,
1074
- data
1075
- } = obj,
1131
+ var reqFunc = function reqFunc(obj) {
1132
+ var method = obj.method,
1133
+ data = obj.data,
1076
1134
  otherProps = __rest(obj, ["method", "data"]);
1077
1135
  if (method === 'Get') {
1078
1136
  return Get(Object.assign({
@@ -1081,7 +1139,7 @@ const reqFunc = obj => {
1081
1139
  }
1082
1140
  if (method === 'Post') {
1083
1141
  return Post(Object.assign({
1084
- data
1142
+ data: data
1085
1143
  }, otherProps));
1086
1144
  }
1087
1145
  };