@zat-design/sisyphus-react 3.6.6 → 3.6.7-beta.1
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.css +9 -0
- package/dist/less.esm.css +9 -0
- package/es/ProAction/index.js +4 -4
- package/es/ProDownload/index.d.ts +1 -1
- package/es/ProEditTable/components/ActionButton/index.d.ts +1 -1
- package/es/ProEditTable/components/RcTable/BaseTable.d.ts +6 -0
- package/es/ProEditTable/components/RcTable/BaseTable.js +75 -0
- package/es/ProEditTable/components/RcTable/DraggableTable.d.ts +7 -0
- package/es/ProEditTable/components/RcTable/DraggableTable.js +90 -0
- package/es/ProEditTable/components/RcTable/VirtualTable.d.ts +6 -0
- package/es/ProEditTable/components/RcTable/VirtualTable.js +166 -0
- package/es/ProEditTable/components/RcTable/index.d.ts +6 -0
- package/es/ProEditTable/components/RcTable/index.js +6 -0
- package/es/ProEditTable/components/RenderField/index.d.ts +1 -1
- package/es/ProEditTable/components/RenderField/index.js +27 -19
- package/es/ProEditTable/components/RenderToolbar/index.d.ts +1 -1
- package/es/ProEditTable/components/RenderToolbar/index.js +8 -6
- package/es/ProEditTable/components/Summary/index.d.ts +1 -1
- package/es/ProEditTable/index.js +33 -56
- package/es/ProEditTable/propsType.d.ts +11 -0
- package/es/ProEditTable/utils/config.d.ts +1 -1
- package/es/ProEditTable/utils/index.js +1 -1
- package/es/ProEditTable/utils/tools.js +3 -3
- package/es/ProEnum/components/Group.d.ts +1 -1
- package/es/ProEnum/components/Tag.d.ts +1 -1
- package/es/ProEnum/index.d.ts +2 -2
- package/es/ProEnum/utils/eventCenter.js +1 -2
- package/es/ProEnum/utils/getEnumLabel.d.ts +1 -1
- package/es/ProForm/components/base/Input/index.d.ts +1 -1
- package/es/ProForm/components/base/InputNumber/index.js +8 -2
- package/es/ProForm/components/combination/ProCascader/index.d.ts +1 -1
- package/es/ProForm/components/combination/ProCascader/index.js +9 -7
- package/es/ProForm/components/old/InputRange/index.d.ts +1 -1
- package/es/ProForm/components/old/InputWithSuffix/index.d.ts +1 -1
- package/es/ProForm/components/old/ProAddress/index.d.ts +1 -2
- package/es/ProForm/components/old/ProRangeBox/index.d.ts +1 -2
- package/es/ProForm/utils/index.js +14 -10
- package/es/ProForm/utils/useWatch.d.ts +1 -2
- package/es/ProIcon/utils/index.js +4 -3
- package/es/ProLayout/components/Layout/Menu/OpenMenu/index.d.ts +1 -1
- package/es/ProLayout/components/Layout/Menu/OpenMenu/index.js +3 -3
- package/es/ProLayout/components/ProCollapse/index.d.ts +1 -1
- package/es/ProLayout/components/ProFooter/index.d.ts +1 -1
- package/es/ProLayout/components/ProHeader/components/Copy/index.d.ts +1 -1
- package/es/ProLayout/components/ProHeader/index.d.ts +1 -1
- package/es/ProLayout/index.d.ts +4 -4
- package/es/ProLayout/utils/index.js +9 -9
- package/es/ProSelect/components/AdaptiveTooltip.d.ts +1 -1
- package/es/ProSelect/index.d.ts +1 -1
- package/es/ProSelect/index.js +1 -1
- package/es/ProStep/components/Anchor/index.d.ts +1 -1
- package/es/ProStep/components/Item/index.d.ts +1 -1
- package/es/ProStep/components/Step/index.d.ts +1 -1
- package/es/ProStep/index.d.ts +2 -2
- package/es/ProTable/components/DndWrapper/index.d.ts +2 -1
- package/es/ProTable/components/DndWrapper/index.js +49 -10
- package/es/ProTable/components/DndWrapper/utils/index.d.ts +8 -0
- package/es/ProTable/components/DndWrapper/utils/index.js +165 -0
- package/es/ProTable/components/DndWrapper/utils/propsType.d.ts +61 -0
- package/es/ProTable/components/DndWrapper/utils/propsType.js +1 -0
- package/es/ProTable/components/ResizableLine/index.d.ts +1 -1
- package/es/ProTable/components/TableResizable/index.d.ts +1 -1
- package/es/ProTable/index.d.ts +1 -1
- package/es/ProTable/index.js +1 -0
- package/es/ProTable/propsType.d.ts +2 -1
- package/es/ProTable/style/index.less +9 -0
- package/es/ProTable/useAntdTable.d.ts +2 -2
- package/es/ProTable/useAntdTable.js +17 -3
- package/es/ProTable/utils.js +3 -3
- package/es/ProTabs/components/Card/index.d.ts +1 -1
- package/es/ProThemeTools/component/PrdTools/index.d.ts +1 -1
- package/es/ProThemeTools/index.d.ts +1 -1
- package/es/ProTooltip/index.d.ts +1 -1
- package/es/ProTree/components/CloseIcon.d.ts +1 -2
- package/es/ProTree/components/List.d.ts +1 -1
- package/es/ProTree/components/ProTree.d.ts +1 -1
- package/es/ProTree/components/ProTreeSelect/index.d.ts +1 -1
- package/es/ProTree/components/ProTreeSelect/index.js +18 -18
- package/es/ProTree/components/SearchTitle.d.ts +1 -1
- package/es/ProTree/components/Tree.d.ts +1 -1
- package/es/ProTree/components/Tree.js +3 -3
- package/es/ProTree/index.d.ts +1 -1
- package/es/ProTree/utils.js +12 -11
- package/es/ProTreeModal/components/Cascader.d.ts +1 -1
- package/es/ProTreeModal/components/CloseIcon.d.ts +1 -2
- package/es/ProTreeModal/components/SearchTitle.d.ts +1 -1
- package/es/ProTreeModal/components/Tree.js +6 -6
- package/es/ProTreeModal/components/Trigger.d.ts +1 -1
- package/es/ProTreeModal/index.d.ts +1 -1
- package/es/ProTreeModal/utils.js +12 -11
- package/es/ProUpload/components/DraggableUploadListItem.d.ts +1 -1
- package/lib/ProAction/index.js +4 -4
- package/lib/ProDownload/index.d.ts +1 -1
- package/lib/ProEditTable/components/ActionButton/index.d.ts +1 -1
- package/lib/ProEditTable/components/RcTable/BaseTable.d.ts +6 -0
- package/lib/ProEditTable/components/RcTable/BaseTable.js +81 -0
- package/lib/ProEditTable/components/RcTable/DraggableTable.d.ts +7 -0
- package/lib/ProEditTable/components/RcTable/DraggableTable.js +96 -0
- package/lib/ProEditTable/components/RcTable/VirtualTable.d.ts +6 -0
- package/lib/ProEditTable/components/RcTable/VirtualTable.js +172 -0
- package/lib/ProEditTable/components/RcTable/index.d.ts +6 -0
- package/lib/ProEditTable/components/RcTable/index.js +27 -0
- package/lib/ProEditTable/components/RenderField/index.d.ts +1 -1
- package/lib/ProEditTable/components/RenderField/index.js +27 -19
- package/lib/ProEditTable/components/RenderToolbar/index.d.ts +1 -1
- package/lib/ProEditTable/components/RenderToolbar/index.js +7 -5
- package/lib/ProEditTable/components/Summary/index.d.ts +1 -1
- package/lib/ProEditTable/index.js +32 -53
- package/lib/ProEditTable/propsType.d.ts +11 -0
- package/lib/ProEditTable/utils/config.d.ts +1 -1
- package/lib/ProEditTable/utils/index.js +1 -1
- package/lib/ProEditTable/utils/tools.js +3 -3
- package/lib/ProEnum/components/Group.d.ts +1 -1
- package/lib/ProEnum/components/Tag.d.ts +1 -1
- package/lib/ProEnum/index.d.ts +2 -2
- package/lib/ProEnum/utils/eventCenter.js +1 -2
- package/lib/ProEnum/utils/getEnumLabel.d.ts +1 -1
- package/lib/ProForm/components/base/Input/index.d.ts +1 -1
- package/lib/ProForm/components/base/InputNumber/index.js +8 -2
- package/lib/ProForm/components/combination/ProCascader/index.d.ts +1 -1
- package/lib/ProForm/components/combination/ProCascader/index.js +9 -7
- package/lib/ProForm/components/old/InputRange/index.d.ts +1 -1
- package/lib/ProForm/components/old/InputWithSuffix/index.d.ts +1 -1
- package/lib/ProForm/components/old/ProAddress/index.d.ts +1 -2
- package/lib/ProForm/components/old/ProRangeBox/index.d.ts +1 -2
- package/lib/ProForm/utils/index.js +10 -10
- package/lib/ProForm/utils/useWatch.d.ts +1 -2
- package/lib/ProIcon/utils/index.js +3 -3
- package/lib/ProLayout/components/Layout/Menu/OpenMenu/index.d.ts +1 -1
- package/lib/ProLayout/components/Layout/Menu/OpenMenu/index.js +3 -3
- package/lib/ProLayout/components/ProCollapse/index.d.ts +1 -1
- package/lib/ProLayout/components/ProFooter/index.d.ts +1 -1
- package/lib/ProLayout/components/ProHeader/components/Copy/index.d.ts +1 -1
- package/lib/ProLayout/components/ProHeader/index.d.ts +1 -1
- package/lib/ProLayout/index.d.ts +4 -4
- package/lib/ProLayout/utils/index.js +9 -9
- package/lib/ProSelect/components/AdaptiveTooltip.d.ts +1 -1
- package/lib/ProSelect/index.d.ts +1 -1
- package/lib/ProSelect/index.js +1 -1
- package/lib/ProStep/components/Anchor/index.d.ts +1 -1
- package/lib/ProStep/components/Item/index.d.ts +1 -1
- package/lib/ProStep/components/Step/index.d.ts +1 -1
- package/lib/ProStep/index.d.ts +2 -2
- package/lib/ProTable/components/DndWrapper/index.d.ts +2 -1
- package/lib/ProTable/components/DndWrapper/index.js +48 -9
- package/lib/ProTable/components/DndWrapper/utils/index.d.ts +8 -0
- package/lib/ProTable/components/DndWrapper/utils/index.js +177 -0
- package/lib/ProTable/components/DndWrapper/utils/propsType.d.ts +61 -0
- package/lib/ProTable/components/DndWrapper/utils/propsType.js +5 -0
- package/lib/ProTable/components/ResizableLine/index.d.ts +1 -1
- package/lib/ProTable/components/TableResizable/index.d.ts +1 -1
- package/lib/ProTable/index.d.ts +1 -1
- package/lib/ProTable/index.js +1 -0
- package/lib/ProTable/propsType.d.ts +2 -1
- package/lib/ProTable/style/index.less +9 -0
- package/lib/ProTable/useAntdTable.d.ts +2 -2
- package/lib/ProTable/useAntdTable.js +16 -2
- package/lib/ProTable/utils.js +3 -3
- package/lib/ProTabs/components/Card/index.d.ts +1 -1
- package/lib/ProThemeTools/component/PrdTools/index.d.ts +1 -1
- package/lib/ProThemeTools/index.d.ts +1 -1
- package/lib/ProTooltip/index.d.ts +1 -1
- package/lib/ProTree/components/CloseIcon.d.ts +1 -2
- package/lib/ProTree/components/List.d.ts +1 -1
- package/lib/ProTree/components/ProTree.d.ts +1 -1
- package/lib/ProTree/components/ProTreeSelect/index.d.ts +1 -1
- package/lib/ProTree/components/ProTreeSelect/index.js +18 -18
- package/lib/ProTree/components/SearchTitle.d.ts +1 -1
- package/lib/ProTree/components/Tree.d.ts +1 -1
- package/lib/ProTree/components/Tree.js +3 -3
- package/lib/ProTree/index.d.ts +1 -1
- package/lib/ProTree/utils.js +11 -11
- package/lib/ProTreeModal/components/Cascader.d.ts +1 -1
- package/lib/ProTreeModal/components/CloseIcon.d.ts +1 -2
- package/lib/ProTreeModal/components/SearchTitle.d.ts +1 -1
- package/lib/ProTreeModal/components/Tree.js +6 -6
- package/lib/ProTreeModal/components/Trigger.d.ts +1 -1
- package/lib/ProTreeModal/index.d.ts +1 -1
- package/lib/ProTreeModal/utils.js +11 -11
- package/lib/ProUpload/components/DraggableUploadListItem.d.ts +1 -1
- package/package.json +6 -3
    
        package/es/ProEditTable/index.js
    CHANGED
    
    | @@ -1,7 +1,5 @@ | |
| 1 1 | 
             
            import "antd/es/affix/style";
         | 
| 2 2 | 
             
            import _Affix from "antd/es/affix";
         | 
| 3 | 
            -
            import "antd/es/table/style";
         | 
| 4 | 
            -
            import _Table from "antd/es/table";
         | 
| 5 3 | 
             
            import _typeof from "@babel/runtime/helpers/esm/typeof";
         | 
| 6 4 | 
             
            import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
         | 
| 7 5 | 
             
            import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
         | 
| @@ -11,7 +9,7 @@ import _toConsumableArray from "@babel/runtime/helpers/esm/toConsumableArray"; | |
| 11 9 | 
             
            import "antd/es/form/style";
         | 
| 12 10 | 
             
            import _Form from "antd/es/form";
         | 
| 13 11 | 
             
            import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
         | 
| 14 | 
            -
            var _excluded = ["value", "onChange", "onDrag", "className", "columns", "type", "mode", "stripe", "draggable", "disabled", "insertType", "emptyBtnText", "actionWidth", "actionProps", "toolbarProps", "toolbarSticky", "rowSelection", "onlyOneLineMsg", "deletePoConfirmMsg", "mulDeletePoConfirmMsg", "requiredAlign", "summary", "max", "headerRender", "pagination", "originalValues", "originalDiffTip", "rowKey", "rowDisabled", "rowDraggable", "footerRender", "scroll", "actionDirection"];
         | 
| 12 | 
            +
            var _excluded = ["value", "onChange", "onDrag", "className", "columns", "type", "mode", "stripe", "draggable", "virtual", "disabled", "insertType", "emptyBtnText", "actionWidth", "actionProps", "toolbarProps", "toolbarSticky", "rowSelection", "onlyOneLineMsg", "deletePoConfirmMsg", "mulDeletePoConfirmMsg", "requiredAlign", "summary", "max", "headerRender", "pagination", "originalValues", "originalDiffTip", "rowKey", "rowDisabled", "rowDraggable", "footerRender", "scroll", "actionDirection"];
         | 
| 15 13 | 
             
            import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
         | 
| 16 14 | 
             
            import React, { forwardRef, useCallback, useEffect, useImperativeHandle, useMemo, useRef } from 'react';
         | 
| 17 15 | 
             
            import { get, isArray, isBoolean } from 'lodash';
         | 
| @@ -19,12 +17,13 @@ import { useDeepCompareEffect, useLocalStorageState, useSetState } from 'ahooks' | |
| 19 17 | 
             
            import classnames from 'classnames';
         | 
| 20 18 | 
             
            import { transformColumns } from './utils';
         | 
| 21 19 | 
             
            import { getRandom, getNamePath } from './utils/tools';
         | 
| 22 | 
            -
            import {  | 
| 20 | 
            +
            import { Validator, Summary, RenderToolbar } from './components';
         | 
| 23 21 | 
             
            import ProForm from '../ProForm';
         | 
| 24 22 | 
             
            import Empty from '../assets/empty.png';
         | 
| 25 23 | 
             
            import locale, { formatMessage } from '../locale';
         | 
| 24 | 
            +
            import { BaseTable, DraggableTable, VirtualTable } from './components/RcTable';
         | 
| 26 25 | 
             
            var ProEditTable = function ProEditTable(_ref, ref) {
         | 
| 27 | 
            -
              var _resetProps$id, _resetProps$id$split, _themeConfig$data2 | 
| 26 | 
            +
              var _resetProps$id, _resetProps$id$split, _themeConfig$data2;
         | 
| 28 27 | 
             
              var value = _ref.value,
         | 
| 29 28 | 
             
                onChange = _ref.onChange,
         | 
| 30 29 | 
             
                onDrag = _ref.onDrag,
         | 
| @@ -34,6 +33,7 @@ var ProEditTable = function ProEditTable(_ref, ref) { | |
| 34 33 | 
             
                mode = _ref.mode,
         | 
| 35 34 | 
             
                stripe = _ref.stripe,
         | 
| 36 35 | 
             
                draggable = _ref.draggable,
         | 
| 36 | 
            +
                virtual = _ref.virtual,
         | 
| 37 37 | 
             
                disabled = _ref.disabled,
         | 
| 38 38 | 
             
                insertType = _ref.insertType,
         | 
| 39 39 | 
             
                emptyBtnText = _ref.emptyBtnText,
         | 
| @@ -244,7 +244,7 @@ var ProEditTable = function ProEditTable(_ref, ref) { | |
| 244 244 | 
             
                    children: disabled || isForbiddenBtn('add') ? locale.ProEditTable.noData : _jsxs(_Fragment, {
         | 
| 245 245 | 
             
                      children: [locale.ProEditTable.noData, "\uFF0C", _jsx(RenderToolbar, _objectSpread({}, _objectSpread(_objectSpread({}, config), {}, {
         | 
| 246 246 | 
             
                        toolbarProps: toolbarProps === null || toolbarProps === void 0 ? void 0 : (_toolbarProps$filter = toolbarProps.filter) === null || _toolbarProps$filter === void 0 ? void 0 : _toolbarProps$filter.call(toolbarProps, function (item) {
         | 
| 247 | 
            -
                          return item.type === 'add';
         | 
| 247 | 
            +
                          return item.type === 'add' || (item === null || item === void 0 ? void 0 : item.persistence);
         | 
| 248 248 | 
             
                        }),
         | 
| 249 249 | 
             
                        dataSource: []
         | 
| 250 250 | 
             
                      })))]
         | 
| @@ -326,62 +326,38 @@ var ProEditTable = function ProEditTable(_ref, ref) { | |
| 326 326 | 
             
                  rowSelection: renderRowSelection()
         | 
| 327 327 | 
             
                });
         | 
| 328 328 | 
             
              } : summary;
         | 
| 329 | 
            +
              var TableComponent = draggable ? DraggableTable : virtual ? VirtualTable : BaseTable;
         | 
| 329 330 | 
             
              return _jsxs(_Fragment, {
         | 
| 330 331 | 
             
                children: [_jsxs(_ConfigProvider, {
         | 
| 331 332 | 
             
                  renderEmpty: (value === null || value === void 0 ? void 0 : value.length) ? undefined : empty,
         | 
| 332 | 
            -
                  children: [ | 
| 333 | 
            -
                     | 
| 334 | 
            -
             | 
| 335 | 
            -
             | 
| 336 | 
            -
             | 
| 337 | 
            -
                     | 
| 338 | 
            -
                     | 
| 339 | 
            -
                       | 
| 340 | 
            -
                       | 
| 341 | 
            -
             | 
| 342 | 
            -
                      ref: tableRef,
         | 
| 333 | 
            +
                  children: [_jsx(TableComponent, _objectSpread(_objectSpread({}, resetProps), {}, {
         | 
| 334 | 
            +
                    draggableProps: {
         | 
| 335 | 
            +
                      onChange: onChange,
         | 
| 336 | 
            +
                      onDrag: onDrag,
         | 
| 337 | 
            +
                      draggable: draggable
         | 
| 338 | 
            +
                    },
         | 
| 339 | 
            +
                    tableProps: {
         | 
| 340 | 
            +
                      value: value,
         | 
| 341 | 
            +
                      headerRender: headerRender,
         | 
| 342 | 
            +
                      tableRef: tableRef,
         | 
| 343 343 | 
             
                      className: _className,
         | 
| 344 | 
            -
                      dataSource: (value === null || value === void 0 ? void 0 : (_value$ = value[0]) === null || _value$ === void 0 ? void 0 : _value$.rowKey) ? value : undefined,
         | 
| 345 344 | 
             
                      columns: _columns,
         | 
| 346 | 
            -
                       | 
| 345 | 
            +
                      renderRowSelection: renderRowSelection,
         | 
| 347 346 | 
             
                      rowClassName: _rowClassName,
         | 
| 348 | 
            -
                       | 
| 349 | 
            -
             | 
| 350 | 
            -
             | 
| 351 | 
            -
             | 
| 352 | 
            -
                       | 
| 353 | 
            -
                       | 
| 354 | 
            -
             | 
| 355 | 
            -
             | 
| 356 | 
            -
             | 
| 357 | 
            -
             | 
| 358 | 
            -
             | 
| 359 | 
            -
             | 
| 360 | 
            -
             | 
| 361 | 
            -
             | 
| 362 | 
            -
                      pagination: pagination ? _objectSpread({
         | 
| 363 | 
            -
                        current: page.pageNum,
         | 
| 364 | 
            -
                        pageSize: page.pageSize,
         | 
| 365 | 
            -
                        showSizeChanger: false,
         | 
| 366 | 
            -
                        showQuickJumper: true,
         | 
| 367 | 
            -
                        total: value === null || value === void 0 ? void 0 : value.length,
         | 
| 368 | 
            -
                        showTotal: function showTotal(total) {
         | 
| 369 | 
            -
                          var _locale$ProEditTable;
         | 
| 370 | 
            -
                          if (!total) return;
         | 
| 371 | 
            -
                          return formatMessage(locale === null || locale === void 0 ? void 0 : (_locale$ProEditTable = locale.ProEditTable) === null || _locale$ProEditTable === void 0 ? void 0 : _locale$ProEditTable.total, {
         | 
| 372 | 
            -
                            total: total
         | 
| 373 | 
            -
                          });
         | 
| 374 | 
            -
                        },
         | 
| 375 | 
            -
                        onChange: handlePageChange
         | 
| 376 | 
            -
                      }, pagination) : false,
         | 
| 377 | 
            -
                      rowKey: "rowKey",
         | 
| 378 | 
            -
                      scroll: {
         | 
| 379 | 
            -
                        x: scroll === null || scroll === void 0 ? void 0 : scroll.x,
         | 
| 380 | 
            -
                        y: (value === null || value === void 0 ? void 0 : value.length) ? scroll === null || scroll === void 0 ? void 0 : scroll.y : undefined
         | 
| 381 | 
            -
                      },
         | 
| 382 | 
            -
                      summary: _summary
         | 
| 383 | 
            -
                    }))]
         | 
| 384 | 
            -
                  }), !isView && (value === null || value === void 0 ? void 0 : value.length) ? toolbarSticky ? _jsx(_Affix, _objectSpread(_objectSpread({
         | 
| 347 | 
            +
                      disabled: disabled,
         | 
| 348 | 
            +
                      virtualKey: virtualKey,
         | 
| 349 | 
            +
                      editingKeys: editingKeys,
         | 
| 350 | 
            +
                      isHideCheckBox: isHideCheckBox,
         | 
| 351 | 
            +
                      rowDraggable: rowDraggable,
         | 
| 352 | 
            +
                      pagination: pagination,
         | 
| 353 | 
            +
                      scroll: scroll,
         | 
| 354 | 
            +
                      summary: _summary,
         | 
| 355 | 
            +
                      page: page,
         | 
| 356 | 
            +
                      formatMessage: formatMessage,
         | 
| 357 | 
            +
                      locale: locale,
         | 
| 358 | 
            +
                      handlePageChange: handlePageChange
         | 
| 359 | 
            +
                    }
         | 
| 360 | 
            +
                  })), !isView && (value === null || value === void 0 ? void 0 : value.length) ? toolbarSticky ? _jsx(_Affix, _objectSpread(_objectSpread({
         | 
| 385 361 | 
             
                    ref: affixRef
         | 
| 386 362 | 
             
                  }, _toolbarSticky), {}, {
         | 
| 387 363 | 
             
                    children: _jsx("div", {
         | 
| @@ -414,6 +390,7 @@ ForwardProEditTable.defaultProps = { | |
| 414 390 | 
             
              toolbarProps: [],
         | 
| 415 391 | 
             
              disabled: false,
         | 
| 416 392 | 
             
              draggable: false,
         | 
| 393 | 
            +
              virtual: false,
         | 
| 417 394 | 
             
              stripe: true,
         | 
| 418 395 | 
             
              emptyBtnText: locale.ProEditTable.clickAdd,
         | 
| 419 396 | 
             
              onlyOneLineMsg: locale.ProEditTable.onlyOneLineMsg,
         | 
| @@ -45,6 +45,11 @@ export interface BaseActionProps<T = any> { | |
| 45 45 | 
             
                 * @default           true
         | 
| 46 46 | 
             
                 */
         | 
| 47 47 | 
             
                show?: boolean | ShowFunction<T>;
         | 
| 48 | 
            +
                /**
         | 
| 49 | 
            +
               * @description       是否持久化(一直显示)操作按钮
         | 
| 50 | 
            +
               * @default           true
         | 
| 51 | 
            +
               */
         | 
| 52 | 
            +
                persistence?: boolean;
         | 
| 48 53 | 
             
                /**
         | 
| 49 54 | 
             
                 * @description       是否禁止操作
         | 
| 50 55 | 
             
                 * @default           true
         | 
| @@ -100,6 +105,7 @@ export interface ProColumnsProps<Values = any, T = any> extends Omit<FormItemPro | |
| 100 105 | 
             
                hiddenNames?: NamePath[] | NamePath[][];
         | 
| 101 106 | 
             
                rules?: ProRule[] | RulesFn<T>;
         | 
| 102 107 | 
             
                confirm?: boolean | ModalFuncProps | FunctionArgs<Values, boolean | ModalFuncProps | void>;
         | 
| 108 | 
            +
                validateTrigger?: string | string[];
         | 
| 103 109 | 
             
                [key: string]: any;
         | 
| 104 110 | 
             
            }
         | 
| 105 111 | 
             
            export type ProEditTableColumnsProps<K = any> = ProColumnsProps & ColumnPropsMap<K, 'ProEditTable'>;
         | 
| @@ -191,6 +197,11 @@ export interface ProEditTableProps<T = any> extends Omit<TableProps<T>, 'onChang | |
| 191 197 | 
             
                 * @default           -
         | 
| 192 198 | 
             
                 */
         | 
| 193 199 | 
             
                draggable?: boolean;
         | 
| 200 | 
            +
                /**
         | 
| 201 | 
            +
               * @description       是否开启虚拟列表(scroll,x,y必须为固定值)
         | 
| 202 | 
            +
               * @default           -
         | 
| 203 | 
            +
               */
         | 
| 204 | 
            +
                virtual?: boolean;
         | 
| 194 205 | 
             
                /**
         | 
| 195 206 | 
             
                 * @description       空列表状态时,自定义添加按钮
         | 
| 196 207 | 
             
                 * @default          点击添加
         | 
| @@ -9,7 +9,7 @@ export declare const defaultBtnNameMap: { | |
| 9 9 | 
             
                custom: any;
         | 
| 10 10 | 
             
            };
         | 
| 11 11 | 
             
            export declare const iconMap: {
         | 
| 12 | 
            -
                add: JSX.Element;
         | 
| 12 | 
            +
                add: import("react/jsx-runtime").JSX.Element;
         | 
| 13 13 | 
             
            };
         | 
| 14 14 | 
             
            export declare const defaultSingleActionKeys: string[];
         | 
| 15 15 | 
             
            export declare const defaultMultipleActionKeys: string[];
         | 
| @@ -121,7 +121,7 @@ var getActionColumn = function getActionColumn(config) { | |
| 121 121 | 
             
                        case 20:
         | 
| 122 122 | 
             
                          result = _context.sent;
         | 
| 123 123 | 
             
                        case 21:
         | 
| 124 | 
            -
                          if (result && type !== 'custom') {
         | 
| 124 | 
            +
                          if (result !== false && type !== 'custom') {
         | 
| 125 125 | 
             
                            actions[type](_objectSpread(_objectSpread({}, config), {}, {
         | 
| 126 126 | 
             
                              rowName: [].concat(_toConsumableArray(name), [index]),
         | 
| 127 127 | 
             
                              virtualRowName: rowName,
         | 
| @@ -5,14 +5,14 @@ export var getRandom = function getRandom() { | |
| 5 5 | 
             
            };
         | 
| 6 6 | 
             
            // 深层次对比两个对象且取出来差异值
         | 
| 7 7 | 
             
            export var difference = function difference(object, base) {
         | 
| 8 | 
            -
              var  | 
| 8 | 
            +
              var _changes = function changes(object, base) {
         | 
| 9 9 | 
             
                return transform(object, function (result, value, key) {
         | 
| 10 10 | 
             
                  if (!isEqual(value, base[key])) {
         | 
| 11 | 
            -
                    result[key] = isObject(value) && isObject(base[key]) ?  | 
| 11 | 
            +
                    result[key] = isObject(value) && isObject(base[key]) ? _changes(value, base[key]) : value;
         | 
| 12 12 | 
             
                  }
         | 
| 13 13 | 
             
                });
         | 
| 14 14 | 
             
              };
         | 
| 15 | 
            -
              return  | 
| 15 | 
            +
              return _changes(object, base);
         | 
| 16 16 | 
             
            };
         | 
| 17 17 | 
             
            // 数组字段循环校验,解决validateFields无法批量校验的问题
         | 
| 18 18 | 
             
            export var customValidate = function customValidate(validateKeys, form, rowName) {
         | 
| @@ -6,5 +6,5 @@ interface Props extends Pick<ProEnum, 'id' | 'value' | 'onChange' | 'dataSource' | |
| 6 6 | 
             
                allowClear?: boolean;
         | 
| 7 7 | 
             
                button?: boolean;
         | 
| 8 8 | 
             
            }
         | 
| 9 | 
            -
            declare const Group: (props: Props) => JSX.Element;
         | 
| 9 | 
            +
            declare const Group: (props: Props) => import("react/jsx-runtime").JSX.Element;
         | 
| 10 10 | 
             
            export default Group;
         | 
| @@ -3,5 +3,5 @@ interface Props extends Pick<ProEnum, 'id' | 'value' | 'onChange' | 'dataSource' | |
| 3 3 | 
             
                fieldValue: string;
         | 
| 4 4 | 
             
                fieldLabel: string;
         | 
| 5 5 | 
             
            }
         | 
| 6 | 
            -
            declare const ProEnumTag: (props: Props) => JSX.Element;
         | 
| 6 | 
            +
            declare const ProEnumTag: (props: Props) => import("react/jsx-runtime").JSX.Element;
         | 
| 7 7 | 
             
            export default ProEnumTag;
         | 
    
        package/es/ProEnum/index.d.ts
    CHANGED
    
    | @@ -2,8 +2,8 @@ import useEnum from './hooks/useEnum'; | |
| 2 2 | 
             
            import { ProEnumProps } from './propsType';
         | 
| 3 3 | 
             
            import './style/index.less';
         | 
| 4 4 | 
             
            declare const ProEnum: {
         | 
| 5 | 
            -
                (props: ProEnumProps): JSX.Element;
         | 
| 6 | 
            -
                getEnumLabel: (code: string | string[], value: any, compose?: boolean, fieldNameLabel?: string, fieldNameValue?: string) => JSX.Element;
         | 
| 5 | 
            +
                (props: ProEnumProps): import("react/jsx-runtime").JSX.Element;
         | 
| 6 | 
            +
                getEnumLabel: (code: string | string[], value: any, compose?: boolean, fieldNameLabel?: string, fieldNameValue?: string) => import("react/jsx-runtime").JSX.Element;
         | 
| 7 7 | 
             
                useEnum: typeof useEnum;
         | 
| 8 8 | 
             
            };
         | 
| 9 9 | 
             
            export default ProEnum;
         | 
| @@ -7,7 +7,7 @@ var SimpleEventCenter = /*#__PURE__*/function () { | |
| 7 7 | 
             
                this.events = void 0;
         | 
| 8 8 | 
             
                this.events = new Map();
         | 
| 9 9 | 
             
              }
         | 
| 10 | 
            -
              _createClass(SimpleEventCenter, [{
         | 
| 10 | 
            +
              return _createClass(SimpleEventCenter, [{
         | 
| 11 11 | 
             
                key: "subscribe",
         | 
| 12 12 | 
             
                value: function subscribe(eventName, callback) {
         | 
| 13 13 | 
             
                  if (!this.events.has(eventName)) {
         | 
| @@ -34,6 +34,5 @@ var SimpleEventCenter = /*#__PURE__*/function () { | |
| 34 34 | 
             
                  }
         | 
| 35 35 | 
             
                }
         | 
| 36 36 | 
             
              }]);
         | 
| 37 | 
            -
              return SimpleEventCenter;
         | 
| 38 37 | 
             
            }(); // 将 eventCenter 实例添加到 window 对象上
         | 
| 39 38 | 
             
            window.eventCenter = new SimpleEventCenter();
         | 
| @@ -1,2 +1,2 @@ | |
| 1 | 
            -
            declare const getEnumLabel: (code: string | string[], value: any, compose?: boolean, fieldNameLabel?: string, fieldNameValue?: string) => JSX.Element;
         | 
| 1 | 
            +
            declare const getEnumLabel: (code: string | string[], value: any, compose?: boolean, fieldNameLabel?: string, fieldNameValue?: string) => import("react/jsx-runtime").JSX.Element;
         | 
| 2 2 | 
             
            export default getEnumLabel;
         | 
| @@ -240,9 +240,15 @@ var InputNumber = function InputNumber(props) { | |
| 240 240 | 
             
              }
         | 
| 241 241 | 
             
              // 失去焦点时处理数字,
         | 
| 242 242 | 
             
              var handleBlur = function handleBlur(e) {
         | 
| 243 | 
            -
                var _e$target, _props$precision5, _valueProps3, _e$ | 
| 243 | 
            +
                var _e$target, _props$precision5, _valueProps3, _e$target3;
         | 
| 244 244 | 
             
                activateRef.current = false;
         | 
| 245 245 | 
             
                var value = e === null || e === void 0 ? void 0 : (_e$target = e.target) === null || _e$target === void 0 ? void 0 : _e$target.value;
         | 
| 246 | 
            +
                //  为空直接返回
         | 
| 247 | 
            +
                if (value === '') {
         | 
| 248 | 
            +
                  var _e$target2;
         | 
| 249 | 
            +
                  onBlur === null || onBlur === void 0 ? void 0 : onBlur(value, e === null || e === void 0 ? void 0 : (_e$target2 = e.target) === null || _e$target2 === void 0 ? void 0 : _e$target2.value);
         | 
| 250 | 
            +
                  return false;
         | 
| 251 | 
            +
                }
         | 
| 246 252 | 
             
                if (_max !== undefined && value > _max) {
         | 
| 247 253 | 
             
                  value = _max;
         | 
| 248 254 | 
             
                }
         | 
| @@ -269,7 +275,7 @@ var InputNumber = function InputNumber(props) { | |
| 269 275 | 
             
                    value = limitNumber(value, limit);
         | 
| 270 276 | 
             
                    break;
         | 
| 271 277 | 
             
                }
         | 
| 272 | 
            -
                onBlur === null || onBlur === void 0 ? void 0 : onBlur(value, Number(e === null || e === void 0 ? void 0 : (_e$ | 
| 278 | 
            +
                onBlur === null || onBlur === void 0 ? void 0 : onBlur(value, Number(e === null || e === void 0 ? void 0 : (_e$target3 = e.target) === null || _e$target3 === void 0 ? void 0 : _e$target3.value));
         | 
| 273 279 | 
             
              };
         | 
| 274 280 | 
             
              // 获得焦点
         | 
| 275 281 | 
             
              var handleFocus = function handleFocus(e) {
         | 
| @@ -1,4 +1,4 @@ | |
| 1 1 | 
             
            /// <reference types="react" />
         | 
| 2 2 | 
             
            import { ProCascaderProps } from './propsType';
         | 
| 3 | 
            -
            declare const _default: import("react").MemoExoticComponent<(props: ProCascaderProps) => JSX.Element>;
         | 
| 3 | 
            +
            declare const _default: import("react").MemoExoticComponent<(props: ProCascaderProps) => import("react/jsx-runtime").JSX.Element>;
         | 
| 4 4 | 
             
            export default _default;
         | 
| @@ -28,9 +28,9 @@ var defaultFieldNames = { | |
| 28 28 | 
             
              value: 'code',
         | 
| 29 29 | 
             
              children: 'children'
         | 
| 30 30 | 
             
            };
         | 
| 31 | 
            -
            var  | 
| 31 | 
            +
            var _filterDataSource = function filterDataSource(dataSource, level, fieldNames) {
         | 
| 32 32 | 
             
              return dataSource === null || dataSource === void 0 ? void 0 : dataSource.map(function (item) {
         | 
| 33 | 
            -
                return _objectSpread(_objectSpread({}, item), {}, _defineProperty({}, (fieldNames === null || fieldNames === void 0 ? void 0 : fieldNames.children) || 'children', level === 1 ? [] :  | 
| 33 | 
            +
                return _objectSpread(_objectSpread({}, item), {}, _defineProperty({}, (fieldNames === null || fieldNames === void 0 ? void 0 : fieldNames.children) || 'children', level === 1 ? [] : _filterDataSource(item === null || item === void 0 ? void 0 : item[(fieldNames === null || fieldNames === void 0 ? void 0 : fieldNames.children) || 'children'], level - 1, fieldNames)));
         | 
| 34 34 | 
             
              });
         | 
| 35 35 | 
             
            };
         | 
| 36 36 | 
             
            var getViewLabel = function getViewLabel(_ref) {
         | 
| @@ -94,7 +94,7 @@ var ProCascader = function ProCascader(props) { | |
| 94 94 | 
             
                enumDataSource = _ref5$ === void 0 ? [] : _ref5$;
         | 
| 95 95 | 
             
              var realDataSource = useMemo(function () {
         | 
| 96 96 | 
             
                var innerDataSource = dataSource || (addressCode ? enumDataSource : []);
         | 
| 97 | 
            -
                var result = isAddressMode && realLevel === 2 ?  | 
| 97 | 
            +
                var result = isAddressMode && realLevel === 2 ? _filterDataSource(innerDataSource, level, fieldNames) : innerDataSource;
         | 
| 98 98 | 
             
                return transformDataName(result, fieldNames);
         | 
| 99 99 | 
             
              }, [isAddressMode, addressCode, realLevel, dataSource, enumDataSource === null || enumDataSource === void 0 ? void 0 : enumDataSource.length]);
         | 
| 100 100 | 
             
              var _useRequest = _objectSpread({}, useRequest),
         | 
| @@ -129,7 +129,7 @@ var ProCascader = function ProCascader(props) { | |
| 129 129 | 
             
                          value: fieldNames.value,
         | 
| 130 130 | 
             
                          children: (fieldNames === null || fieldNames === void 0 ? void 0 : fieldNames.children) || 'children'
         | 
| 131 131 | 
             
                        });
         | 
| 132 | 
            -
                        serviceData = isAddressMode && realLevel === 2 ?  | 
| 132 | 
            +
                        serviceData = isAddressMode && realLevel === 2 ? _filterDataSource(transFormData, level, fieldNames) : transFormData;
         | 
| 133 133 | 
             
                        setServiceData(serviceData);
         | 
| 134 134 | 
             
                      case 9:
         | 
| 135 135 | 
             
                      case "end":
         | 
| @@ -194,7 +194,7 @@ var ProCascader = function ProCascader(props) { | |
| 194 194 | 
             
              })) === null || _ref7$filter === void 0 ? void 0 : _ref7$filter.join(separator)) || '-' : (defaultLabel === null || defaultLabel === void 0 ? void 0 : (_defaultLabel$filter = defaultLabel.filter(function (item) {
         | 
| 195 195 | 
             
                return !!item;
         | 
| 196 196 | 
             
              })) === null || _defaultLabel$filter === void 0 ? void 0 : _defaultLabel$filter.join(separator)) || '-';
         | 
| 197 | 
            -
              var  | 
| 197 | 
            +
              var _findSelectedOptions = function findSelectedOptions(options, value) {
         | 
| 198 198 | 
             
                var path = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : [];
         | 
| 199 199 | 
             
                var _value = value !== null && value !== void 0 ? value : [];
         | 
| 200 200 | 
             
                // 基准情况:如果 value 数组为空,且 path 不为空,说明找到了完整的路径
         | 
| @@ -213,7 +213,7 @@ var ProCascader = function ProCascader(props) { | |
| 213 213 | 
             
                if (foundOption) {
         | 
| 214 214 | 
             
                  // 如果找到了匹配的选项,并且还有更多的 value 需要匹配,递归地在子选项中查找
         | 
| 215 215 | 
             
                  if (_value.length > 1 && foundOption.children) {
         | 
| 216 | 
            -
                    return  | 
| 216 | 
            +
                    return _findSelectedOptions(foundOption.children, _value.slice(1), [].concat(_toConsumableArray(path), [foundOption]));
         | 
| 217 217 | 
             
                  }
         | 
| 218 218 | 
             
                  // 如果没有更多的 value 需要匹配,返回当前选项(以及之前的路径)
         | 
| 219 219 | 
             
                  return [].concat(_toConsumableArray(path), [foundOption]);
         | 
| @@ -221,7 +221,9 @@ var ProCascader = function ProCascader(props) { | |
| 221 221 | 
             
                // 如果没有在当前层级的选项中找到匹配的 value,返回 null
         | 
| 222 222 | 
             
                return null;
         | 
| 223 223 | 
             
              };
         | 
| 224 | 
            -
              var _selectedOptions =  | 
| 224 | 
            +
              var _selectedOptions = useMemo(function () {
         | 
| 225 | 
            +
                return _findSelectedOptions(service ? serviceData : realDataSource, addressValue);
         | 
| 226 | 
            +
              }, [service, serviceData, realDataSource, addressValue]);
         | 
| 225 227 | 
             
              var handleAddressChange = function handleAddressChange(e) {
         | 
| 226 228 | 
             
                var cascaderValue = value === null || value === void 0 ? void 0 : value.slice(0, realLevel);
         | 
| 227 229 | 
             
                if (onChange) {
         | 
| @@ -12,5 +12,5 @@ export interface InputRangeProps { | |
| 12 12 | 
             
                isPositiveInteger?: boolean;
         | 
| 13 13 | 
             
                precision?: number;
         | 
| 14 14 | 
             
            }
         | 
| 15 | 
            -
            declare const InputRange: ({ value, onChange, min, max, group, disabled, precision, isPositiveInteger, }: InputRangeProps) => JSX.Element;
         | 
| 15 | 
            +
            declare const InputRange: ({ value, onChange, min, max, group, disabled, precision, isPositiveInteger, }: InputRangeProps) => import("react/jsx-runtime").JSX.Element;
         | 
| 16 16 | 
             
            export default InputRange;
         | 
| @@ -1,4 +1,3 @@ | |
| 1 | 
            -
            /// <reference types="react" />
         | 
| 2 1 | 
             
            import { ProAddressPropsType } from './propsTypes';
         | 
| 3 2 | 
             
            export declare const transferAddressInfoToRegion: () => {
         | 
| 4 3 | 
             
                normalize: (value: any) => {
         | 
| @@ -24,5 +23,5 @@ export declare const transferAddressInfoToRegion: () => { | |
| 24 23 | 
             
                    };
         | 
| 25 24 | 
             
                };
         | 
| 26 25 | 
             
            };
         | 
| 27 | 
            -
            export declare function ProAddress({ ...props }: ProAddressPropsType): JSX.Element;
         | 
| 26 | 
            +
            export declare function ProAddress({ ...props }: ProAddressPropsType): import("react/jsx-runtime").JSX.Element;
         | 
| 28 27 | 
             
            export default ProAddress;
         | 
| @@ -1,3 +1,2 @@ | |
| 1 | 
            -
            /// <reference types="react" />
         | 
| 2 1 | 
             
            import { ProRangeBoxPropsType } from './propsType';
         | 
| 3 | 
            -
            export default function ProRangeBox({ configOption }: ProRangeBoxPropsType): JSX.Element;
         | 
| 2 | 
            +
            export default function ProRangeBox({ configOption }: ProRangeBoxPropsType): import("react/jsx-runtime").JSX.Element;
         | 
| @@ -121,7 +121,7 @@ export var splitNameStr = function splitNameStr(name) { | |
| 121 121 | 
             
              });
         | 
| 122 122 | 
             
            };
         | 
| 123 123 | 
             
            // 过滤掉字段名中包含 '-' 的字段
         | 
| 124 | 
            -
             | 
| 124 | 
            +
            var _filterInternalFields = function filterInternalFields(values, optimize) {
         | 
| 125 125 | 
             
              if (optimize) {
         | 
| 126 126 | 
             
                return values;
         | 
| 127 127 | 
             
              }
         | 
| @@ -135,20 +135,21 @@ export var filterInternalFields = function filterInternalFields(values, optimize | |
| 135 135 | 
             
              }
         | 
| 136 136 | 
             
              if (Array.isArray(nextValues)) {
         | 
| 137 137 | 
             
                return nextValues.map(function (item) {
         | 
| 138 | 
            -
                  return  | 
| 138 | 
            +
                  return _filterInternalFields(item);
         | 
| 139 139 | 
             
                });
         | 
| 140 140 | 
             
              }
         | 
| 141 141 | 
             
              if (isObject(nextValues)) {
         | 
| 142 142 | 
             
                var result = {};
         | 
| 143 143 | 
             
                Object.keys(nextValues).forEach(function (key) {
         | 
| 144 144 | 
             
                  if (key.includes('-')) return;
         | 
| 145 | 
            -
                  result[key] =  | 
| 145 | 
            +
                  result[key] = _filterInternalFields(nextValues[key]);
         | 
| 146 146 | 
             
                });
         | 
| 147 147 | 
             
                return result;
         | 
| 148 148 | 
             
              }
         | 
| 149 149 | 
             
              return nextValues;
         | 
| 150 150 | 
             
            };
         | 
| 151 | 
            -
            export  | 
| 151 | 
            +
            export { _filterInternalFields as filterInternalFields };
         | 
| 152 | 
            +
            var _getAllNamePath = function getAllNamePath(object) {
         | 
| 152 153 | 
             
              var currentPath = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
         | 
| 153 154 | 
             
              var keys = Object.keys(object);
         | 
| 154 155 | 
             
              var resultKeys = [];
         | 
| @@ -162,13 +163,14 @@ export var getAllNamePath = function getAllNamePath(object) { | |
| 162 163 | 
             
                }
         | 
| 163 164 | 
             
                // 深度获取对象key
         | 
| 164 165 | 
             
                if (isObject(value)) {
         | 
| 165 | 
            -
                  resultKeys.concat( | 
| 166 | 
            +
                  resultKeys.concat(_getAllNamePath(value, [].concat(_toConsumableArray(currentPath), [key])));
         | 
| 166 167 | 
             
                }
         | 
| 167 168 | 
             
                resultKeys.push([].concat(_toConsumableArray(currentPath), [key]));
         | 
| 168 169 | 
             
              });
         | 
| 169 170 | 
             
              return resultKeys;
         | 
| 170 171 | 
             
            };
         | 
| 171 172 | 
             
            // 判断一个字段值是否算空
         | 
| 173 | 
            +
            export { _getAllNamePath as getAllNamePath };
         | 
| 172 174 | 
             
            var nullList = [undefined, 'null', '""', '[]'];
         | 
| 173 175 | 
             
            export var isNullValue = function isNullValue(value) {
         | 
| 174 176 | 
             
              return nullList.includes(JSON.stringify(value));
         | 
| @@ -353,7 +355,7 @@ export var customEqualForFun = function customEqualForFun(value, other) { | |
| 353 355 | 
             
            /**
         | 
| 354 356 | 
             
             * 查询数据中是否包含rowKey
         | 
| 355 357 | 
             
             */
         | 
| 356 | 
            -
             | 
| 358 | 
            +
            var _hasRowKey = function hasRowKey(obj) {
         | 
| 357 359 | 
             
              if (_typeof(obj) !== 'object' || obj === null) {
         | 
| 358 360 | 
             
                return false;
         | 
| 359 361 | 
             
              }
         | 
| @@ -363,12 +365,13 @@ export var hasRowKey = function hasRowKey(obj) { | |
| 363 365 | 
             
                return true;
         | 
| 364 366 | 
             
              }
         | 
| 365 367 | 
             
              return keys.some(function (key) {
         | 
| 366 | 
            -
                return  | 
| 368 | 
            +
                return _hasRowKey(obj[key]);
         | 
| 367 369 | 
             
              });
         | 
| 368 370 | 
             
            };
         | 
| 369 371 | 
             
            /**
         | 
| 370 372 | 
             
             * 查询数据中是否包含rowKey
         | 
| 371 373 | 
             
             */
         | 
| 374 | 
            +
            export { _hasRowKey as hasRowKey };
         | 
| 372 375 | 
             
            export var view = function view(obj) {
         | 
| 373 376 | 
             
              if (_typeof(obj) !== 'object' || obj === null) {
         | 
| 374 377 | 
             
                return false;
         | 
| @@ -379,7 +382,7 @@ export var view = function view(obj) { | |
| 379 382 | 
             
                return true;
         | 
| 380 383 | 
             
              }
         | 
| 381 384 | 
             
              return keys.some(function (key) {
         | 
| 382 | 
            -
                return  | 
| 385 | 
            +
                return _hasRowKey(obj[key]);
         | 
| 383 386 | 
             
              });
         | 
| 384 387 | 
             
            };
         | 
| 385 388 | 
             
            /**
         | 
| @@ -415,7 +418,7 @@ export var deleteForPath = function deleteForPath(values, namePath) { | |
| 415 418 | 
             
             * @param value 选中值
         | 
| 416 419 | 
             
             * @returns {}
         | 
| 417 420 | 
             
             */
         | 
| 418 | 
            -
             | 
| 421 | 
            +
            var _findOptionByValue = function findOptionByValue(treeData, value, fieldNames) {
         | 
| 419 422 | 
             
              if (isObject(value)) {
         | 
| 420 423 | 
             
                return value;
         | 
| 421 424 | 
             
              }
         | 
| @@ -425,7 +428,7 @@ export var findOptionByValue = function findOptionByValue(treeData, value, field | |
| 425 428 | 
             
                  return omit(node, ['children', fieldNames === null || fieldNames === void 0 ? void 0 : fieldNames.children]);
         | 
| 426 429 | 
             
                }
         | 
| 427 430 | 
             
                if (node.children) {
         | 
| 428 | 
            -
                  var foundNode =  | 
| 431 | 
            +
                  var foundNode = _findOptionByValue(node[(fieldNames === null || fieldNames === void 0 ? void 0 : fieldNames.children) || 'children'], value, fieldNames);
         | 
| 429 432 | 
             
                  if (foundNode) {
         | 
| 430 433 | 
             
                    return omit(foundNode, ['children', fieldNames === null || fieldNames === void 0 ? void 0 : fieldNames.children]);
         | 
| 431 434 | 
             
                  }
         | 
| @@ -435,6 +438,7 @@ export var findOptionByValue = function findOptionByValue(treeData, value, field | |
| 435 438 | 
             
            /**
         | 
| 436 439 | 
             
             * 对比依赖列表中的 值是否变更
         | 
| 437 440 | 
             
             */
         | 
| 441 | 
            +
            export { _findOptionByValue as findOptionByValue };
         | 
| 438 442 | 
             
            export var equalDependencies = function equalDependencies(dependencies, prevValues, currentValues) {
         | 
| 439 443 | 
             
              if (dependencies === null || dependencies === void 0 ? void 0 : dependencies.length) {
         | 
| 440 444 | 
             
                return dependencies.some(function (namePath) {
         | 
| @@ -2,6 +2,5 @@ import { InternalNamePath, FormInstance, NamePath } from 'rc-field-form/es/inter | |
| 2 2 | 
             
            export declare function toArray<T>(value?: T | T[] | null): T[];
         | 
| 3 3 | 
             
            export declare function getNamePath(path: NamePath | null): InternalNamePath;
         | 
| 4 4 | 
             
            export declare function stringify(value: any): string | number;
         | 
| 5 | 
            -
            declare function useWatch(dependencies: string, form?: FormInstance, wait?: number): any;
         | 
| 6 | 
            -
            declare function useWatch(dependencies: NamePath[], form?: FormInstance, wait?: number): any[];
         | 
| 5 | 
            +
            declare function useWatch(dependencies: string | NamePath[], form?: FormInstance, wait?: number): any;
         | 
| 7 6 | 
             
            export default useWatch;
         | 
| @@ -1,6 +1,6 @@ | |
| 1 1 | 
             
            import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
         | 
| 2 2 | 
             
            import { themeMap, themeFillMap } from '../config';
         | 
| 3 | 
            -
             | 
| 3 | 
            +
            var _recurseGetNodes = function recurseGetNodes(type, node, queue) {
         | 
| 4 4 | 
             
              switch (type) {
         | 
| 5 5 | 
             
                // 渐变
         | 
| 6 6 | 
             
                case 'gradation':
         | 
| @@ -19,10 +19,11 @@ export var recurseGetNodes = function recurseGetNodes(type, node, queue) { | |
| 19 19 | 
             
              }
         | 
| 20 20 | 
             
              if (node.childNodes) {
         | 
| 21 21 | 
             
                for (var i = 0; i < node.childNodes.length; i++) {
         | 
| 22 | 
            -
                   | 
| 22 | 
            +
                  _recurseGetNodes(type, node.childNodes[i], queue);
         | 
| 23 23 | 
             
                }
         | 
| 24 24 | 
             
              }
         | 
| 25 25 | 
             
            };
         | 
| 26 | 
            +
            export { _recurseGetNodes as recurseGetNodes };
         | 
| 26 27 | 
             
            export var onBeforeInjection = function onBeforeInjection(_ref) {
         | 
| 27 28 | 
             
              var svg = _ref.svg,
         | 
| 28 29 | 
             
                actionMap = _ref.actionMap,
         | 
| @@ -49,7 +50,7 @@ export var onBeforeInjection = function onBeforeInjection(_ref) { | |
| 49 50 | 
             
                // 目前只支持处理渐变及fill填充
         | 
| 50 51 | 
             
                var types = Reflect.ownKeys(nodeMap !== null && nodeMap !== void 0 ? nodeMap : {});
         | 
| 51 52 | 
             
                types.forEach(function (typeKey) {
         | 
| 52 | 
            -
                   | 
| 53 | 
            +
                  _recurseGetNodes(typeKey, svg, nodeMap[typeKey]);
         | 
| 53 54 | 
             
                });
         | 
| 54 55 | 
             
                if ((gradList === null || gradList === void 0 ? void 0 : gradList.length) > 0) {
         | 
| 55 56 | 
             
                  nodeMap.gradation.forEach(function (item, index) {
         | 
| @@ -50,7 +50,7 @@ var OpenMenu = function OpenMenu(props) { | |
| 50 50 | 
             
                if (!Array.isArray(result) || !result.length) {
         | 
| 51 51 | 
             
                  return [];
         | 
| 52 52 | 
             
                }
         | 
| 53 | 
            -
                var  | 
| 53 | 
            +
                var _menuDeep = function menuDeep(data) {
         | 
| 54 54 | 
             
                  data.forEach(function (item) {
         | 
| 55 55 | 
             
                    var _item$keyIdPath, _item$keyIdPath2, _item$children;
         | 
| 56 56 | 
             
                    // 是否是第一级菜单,展开模式一级菜单有icon, 收起模式二级菜单有icon
         | 
| @@ -91,7 +91,7 @@ var OpenMenu = function OpenMenu(props) { | |
| 91 91 | 
             
                      if ((_item === null || _item === void 0 ? void 0 : _item.hideInMenu) || ['TAB', 'QUERY', 'BUTTON'].includes(_item === null || _item === void 0 ? void 0 : _item.type)) {
         | 
| 92 92 | 
             
                        delete item.children;
         | 
| 93 93 | 
             
                      } else {
         | 
| 94 | 
            -
                         | 
| 94 | 
            +
                        _menuDeep(item.children);
         | 
| 95 95 | 
             
                      }
         | 
| 96 96 | 
             
                    } else {
         | 
| 97 97 | 
             
                      delete item.children;
         | 
| @@ -99,7 +99,7 @@ var OpenMenu = function OpenMenu(props) { | |
| 99 99 | 
             
                  });
         | 
| 100 100 | 
             
                  return data;
         | 
| 101 101 | 
             
                };
         | 
| 102 | 
            -
                 | 
| 102 | 
            +
                _menuDeep(result);
         | 
| 103 103 | 
             
                return result;
         | 
| 104 104 | 
             
              }, [dataSource]);
         | 
| 105 105 | 
             
              useDeepCompareEffect(function () {
         | 
| @@ -1,4 +1,4 @@ | |
| 1 1 | 
             
            /// <reference types="react" />
         | 
| 2 2 | 
             
            import { ProFooterProps } from './PropTypes';
         | 
| 3 | 
            -
            declare const _default: import("react").MemoExoticComponent<(props: ProFooterProps) => JSX.Element>;
         | 
| 3 | 
            +
            declare const _default: import("react").MemoExoticComponent<(props: ProFooterProps) => import("react/jsx-runtime").JSX.Element>;
         | 
| 4 4 | 
             
            export default _default;
         | 
| @@ -1,4 +1,4 @@ | |
| 1 1 | 
             
            import React from 'react';
         | 
| 2 2 | 
             
            import type { ProHeaderProps } from './PropTypes';
         | 
| 3 | 
            -
            declare const _default: React.MemoExoticComponent<(props: ProHeaderProps) => JSX.Element>;
         | 
| 3 | 
            +
            declare const _default: React.MemoExoticComponent<(props: ProHeaderProps) => import("react/jsx-runtime").JSX.Element>;
         | 
| 4 4 | 
             
            export default _default;
         | 
    
        package/es/ProLayout/index.d.ts
    CHANGED
    
    | @@ -5,7 +5,7 @@ export declare const LayoutContext: import("react").Context<{ | |
| 5 5 | 
             
                onSelected: (params: any) => void;
         | 
| 6 6 | 
             
            }>;
         | 
| 7 7 | 
             
            declare const ProLayout: {
         | 
| 8 | 
            -
                (props: ProLayoutProps): JSX.Element;
         | 
| 8 | 
            +
                (props: ProLayoutProps): import("react/jsx-runtime").JSX.Element;
         | 
| 9 9 | 
             
                defaultProps: {
         | 
| 10 10 | 
             
                    menus: any[];
         | 
| 11 11 | 
             
                    iconfontUrl: string;
         | 
| @@ -17,8 +17,8 @@ declare const ProLayout: { | |
| 17 17 | 
             
                    headerHeight: number;
         | 
| 18 18 | 
             
                    contentStyle: {};
         | 
| 19 19 | 
             
                };
         | 
| 20 | 
            -
                ProCollapse: (props: import("./components/ProCollapse/PropTypes").ProCollapseProps) => JSX.Element;
         | 
| 21 | 
            -
                ProFooter: import("react").MemoExoticComponent<(props: import("./components/ProFooter/PropTypes").ProFooterProps) => JSX.Element>;
         | 
| 22 | 
            -
                ProHeader: import("react").MemoExoticComponent<(props: import("./components/ProHeader/PropTypes").ProHeaderProps) => JSX.Element>;
         | 
| 20 | 
            +
                ProCollapse: (props: import("./components/ProCollapse/PropTypes").ProCollapseProps) => import("react/jsx-runtime").JSX.Element;
         | 
| 21 | 
            +
                ProFooter: import("react").MemoExoticComponent<(props: import("./components/ProFooter/PropTypes").ProFooterProps) => import("react/jsx-runtime").JSX.Element>;
         | 
| 22 | 
            +
                ProHeader: import("react").MemoExoticComponent<(props: import("./components/ProHeader/PropTypes").ProHeaderProps) => import("react/jsx-runtime").JSX.Element>;
         | 
| 23 23 | 
             
            };
         | 
| 24 24 | 
             
            export default ProLayout;
         |