@zat-design/sisyphus-react 4.5.7 → 4.5.8-beta.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (88) hide show
  1. package/dist/index.esm.css +1 -1
  2. package/dist/less.esm.css +1 -1
  3. package/es/ProAction/components/CheckModalContent/index.d.ts +2 -1
  4. package/es/ProDownload/index.d.ts +2 -1
  5. package/es/ProDrawerForm/hooks/useConfirmClose.d.ts +1 -0
  6. package/es/ProEditTable/components/ActionButton/index.d.ts +2 -1
  7. package/es/ProEditTable/components/RcTable/BaseTable.d.ts +2 -1
  8. package/es/ProEditTable/components/RcTable/DraggableTable.d.ts +1 -1
  9. package/es/ProEditTable/components/RenderField/index.d.ts +1 -1
  10. package/es/ProEditTable/components/RenderToolbar/index.d.ts +2 -1
  11. package/es/ProEditTable/components/Summary/index.d.ts +2 -1
  12. package/es/ProEditTable/components/Validator/index.d.ts +1 -0
  13. package/es/ProEditTable/utils/config.d.ts +2 -1
  14. package/es/ProEditTable/utils/tools.d.ts +1 -1
  15. package/es/ProEditTable/utils/transform.d.ts +2 -2
  16. package/es/ProEnum/components/Group.d.ts +2 -1
  17. package/es/ProEnum/components/Tag.d.ts +2 -1
  18. package/es/ProEnum/index.d.ts +3 -2
  19. package/es/ProEnum/utils/getEnumLabel.d.ts +2 -1
  20. package/es/ProForm/components/FormFooter/propsType.d.ts +1 -0
  21. package/es/ProForm/components/base/Input/index.d.ts +2 -1
  22. package/es/ProForm/components/combination/FormList/components/Empty.d.ts +2 -1
  23. package/es/ProForm/components/combination/Group/utils/index.d.ts +1 -0
  24. package/es/ProForm/components/combination/ProCascader/index.d.ts +2 -1
  25. package/es/ProForm/components/combination/ProNumberRange/index.d.ts +1 -0
  26. package/es/ProForm/components/combination/ProTimeLimit/hooks/useControlled.d.ts +2 -1
  27. package/es/ProForm/index.d.ts +1 -1
  28. package/es/ProForm/utils/index.d.ts +1 -1
  29. package/es/ProForm/utils/reactiveValues.d.ts +1 -0
  30. package/es/ProForm/utils/transformValue.d.ts +1 -1
  31. package/es/ProLayout/components/Layout/Menu/OpenMenu/index.d.ts +2 -1
  32. package/es/ProLayout/components/Layout/Notice/index.d.ts +5 -2
  33. package/es/ProLayout/components/Layout/Notice/index.js +3 -1
  34. package/es/ProLayout/components/ProCollapse/index.d.ts +2 -1
  35. package/es/ProLayout/components/ProFooter/index.d.ts +2 -1
  36. package/es/ProLayout/components/ProHeader/components/Copy/index.d.ts +2 -1
  37. package/es/ProLayout/components/ProHeader/components/Describe/index.d.ts +4 -4
  38. package/es/ProLayout/components/ProHeader/index.d.ts +1 -1
  39. package/es/ProLayout/components/ProHeader/index.js +5 -2
  40. package/es/ProLayout/components/ProHeader/utils/index.d.ts +1 -1
  41. package/es/ProLayout/components/TabsManager/components/TabContextMenu.d.ts +2 -1
  42. package/es/ProLayout/components/TabsManager/components/TabItem.js +0 -1
  43. package/es/ProLayout/components/TabsManager/components/TabsContext.d.ts +1 -0
  44. package/es/ProLayout/components/TabsManager/components/TabsHeader.d.ts +2 -1
  45. package/es/ProLayout/components/TabsManager/hooks/useTabsState.js +30 -7
  46. package/es/ProLayout/components/TabsManager/index.d.ts +1 -0
  47. package/es/ProLayout/components/TabsManager/index.js +16 -26
  48. package/es/ProLayout/components/TabsManager/utils/index.d.ts +6 -2
  49. package/es/ProLayout/components/TabsManager/utils/index.js +23 -0
  50. package/es/ProLayout/index.d.ts +6 -5
  51. package/es/ProLayout/index.js +45 -7
  52. package/es/ProLayout/propTypes.d.ts +4 -0
  53. package/es/ProLayout/style/index.less +15 -2
  54. package/es/ProSelect/components/AdaptiveTooltip.d.ts +2 -1
  55. package/es/ProSelect/index.d.ts +1 -1
  56. package/es/ProStep/components/Step/index.d.ts +3 -2
  57. package/es/ProStep/components/Step/index.js +6 -3
  58. package/es/ProStep/index.d.ts +2 -2
  59. package/es/ProStep/propsType.d.ts +2 -2
  60. package/es/ProTable/components/FormatColumn/index.d.ts +1 -1
  61. package/es/ProTable/components/RcTable/components/BaseTable/index.d.ts +1 -0
  62. package/es/ProTable/components/RcTable/components/DraggableTable/components/DndWrapper/index.d.ts +1 -1
  63. package/es/ProTable/components/RcTable/components/DraggableTable/index.d.ts +1 -0
  64. package/es/ProTable/components/RenderFooter/index.d.ts +2 -1
  65. package/es/ProTable/components/RenderTableHeader/index.d.ts +2 -1
  66. package/es/ProTable/components/RenderTabs/index.d.ts +2 -1
  67. package/es/ProTable/components/TableResizable/index.d.ts +2 -1
  68. package/es/ProTable/index.d.ts +1 -1
  69. package/es/ProTabs/components/Card/index.d.ts +2 -1
  70. package/es/ProThemeTools/component/ProTools/index.d.ts +2 -1
  71. package/es/ProThemeTools/index.d.ts +2 -1
  72. package/es/ProTooltip/index.d.ts +2 -1
  73. package/es/ProTree/components/AdaptiveTooltip.d.ts +2 -1
  74. package/es/ProTree/components/CloseIcon.d.ts +2 -1
  75. package/es/ProTree/components/List.d.ts +1 -1
  76. package/es/ProTree/components/ProTree.d.ts +2 -1
  77. package/es/ProTree/components/ProTreeSelect/index.d.ts +1 -1
  78. package/es/ProTree/components/SearchTitle.d.ts +2 -1
  79. package/es/ProTree/components/Tree.d.ts +2 -2
  80. package/es/ProTree/index.d.ts +2 -1
  81. package/es/ProTreeModal/components/Cascader.d.ts +1 -1
  82. package/es/ProTreeModal/components/CloseIcon.d.ts +2 -1
  83. package/es/ProTreeModal/components/SearchTitle.d.ts +2 -1
  84. package/es/ProTreeModal/components/Trigger.d.ts +1 -1
  85. package/es/ProTreeModal/index.d.ts +2 -1
  86. package/es/ProUpload/components/DraggableUploadListItem.d.ts +2 -1
  87. package/es/hooks/useDraggableRow.d.ts +1 -1
  88. package/package.json +4 -19
@@ -107,6 +107,29 @@ export const flattenMenuData = (menus = []) => {
107
107
  return flatMenus;
108
108
  };
109
109
 
110
+ /**
111
+ * 将公开 addTab 参数解析为内部菜单项,统一 initialTabs 与实例 API 的匹配规则。
112
+ */
113
+ export const resolveTabMenuItem = (params, menus = []) => {
114
+ const matchedMenu = flattenMenuData(menus).find(item => item.code === params.code);
115
+ if (matchedMenu) {
116
+ return {
117
+ ...matchedMenu,
118
+ name: params.name || matchedMenu.name,
119
+ extra: params.extra ?? matchedMenu.extra,
120
+ relationKey: params.relationKey ?? matchedMenu.relationKey
121
+ };
122
+ }
123
+ return {
124
+ id: Date.now(),
125
+ code: params.code,
126
+ name: params.name,
127
+ url: `/${params.code}`,
128
+ extra: params.extra,
129
+ relationKey: params.relationKey
130
+ };
131
+ };
132
+
110
133
  /**
111
134
  * 判断菜单项是否为最后一级(叶子节点)
112
135
  * 只有当菜单项没有子菜单或子菜单为空时,才认为是叶子节点
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import type { ProLayoutStatesType, ProLayoutType } from './propTypes';
2
3
  import { useProLayoutTabs } from './components/TabsManager/hooks/useProLayoutTabs';
3
4
  import { useActiveTab } from './components/TabsManager/hooks/useActiveTab';
@@ -8,12 +9,12 @@ interface LayoutContextValue {
8
9
  }
9
10
  export declare const LayoutContext: import("react").Context<LayoutContextValue>;
10
11
  declare const ProLayout: {
11
- (props: ProLayoutType): import("react/jsx-runtime").JSX.Element;
12
- ProCollapse: (props: import("../index").ProCollapseType) => import("react/jsx-runtime").JSX.Element;
13
- ProFooter: import("react").MemoExoticComponent<(props: import("../index").ProFooterType) => import("react/jsx-runtime").JSX.Element>;
14
- ProHeader: import("react").MemoExoticComponent<(props: import("../index").ProHeaderType) => import("react/jsx-runtime").JSX.Element>;
12
+ (props: ProLayoutType): import("react").JSX.Element;
13
+ ProCollapse: (props: import("@/ProLayout/components/ProCollapse/PropTypes").ProCollapseType) => import("react").JSX.Element;
14
+ ProFooter: import("react").MemoExoticComponent<(props: import("@/ProLayout/components/ProFooter/PropTypes").ProFooterType) => import("react").JSX.Element>;
15
+ ProHeader: import("react").MemoExoticComponent<(props: import("@/ProLayout/components/ProHeader/PropTypes").ProHeaderType) => import("react").JSX.Element>;
15
16
  useProLayoutTabs: typeof useProLayoutTabs;
16
- useActiveTab: () => import("./propTypes").TabItem | undefined;
17
+ useActiveTab: () => import("./propTypes").TabItem;
17
18
  };
18
19
  export { useProLayoutTabs, useActiveTab };
19
20
  export default ProLayout;
@@ -1,6 +1,6 @@
1
1
  /* eslint-disable func-call-spacing */
2
2
  /* eslint-disable no-spaced-func */
3
- import { createContext, useMemo, useRef, useCallback } from 'react';
3
+ import { createContext, useMemo, useRef, useCallback, useLayoutEffect, useState } from 'react';
4
4
  import classNames from 'classnames';
5
5
  import { useSetState, useToggle, useDeepCompareEffect, useScroll } from 'ahooks';
6
6
  import { ProWaterMark } from "../index";
@@ -66,14 +66,22 @@ const ProLayout = props => {
66
66
  const setTabsBarElRef = useCallback(el => setTabsState({
67
67
  tabsBarEl: el
68
68
  }), []);
69
- // TabsManager 会在 effect 中调用这两个回调;保持引用稳定,避免父组件每次
70
- // render 都让 effect 重新执行并再次 setState,形成无限更新循环。
69
+ // TabsManager 会在 layout effect 中调用这两个回调;保持引用稳定,避免父组件每次
70
+ // render 都让 layout effect 重新执行并再次 setState,形成无限更新循环。
71
71
  const handleTabsChange = useCallback(v => setTabsState({
72
72
  hasTabs: v
73
73
  }), []);
74
74
  const handleIframePureChange = useCallback(v => setTabsState({
75
75
  isIframePure: v
76
76
  }), []);
77
+ const noticeElRef = useRef(null);
78
+ const setNoticeElRef = useCallback(el => {
79
+ noticeElRef.current = el;
80
+ }, []);
81
+ const [stickyHeights, setStickyHeights] = useState({
82
+ notice: 0,
83
+ tabsBar: 0
84
+ });
77
85
 
78
86
  // 仅 tabs 模式需要感知滚动位置(用于控制右上角圆弧伪元素的显隐)
79
87
  // 非 tabs 模式传 null,useScroll 不挂载监听器
@@ -88,6 +96,32 @@ const ProLayout = props => {
88
96
  menus: [],
89
97
  selectedPath: ''
90
98
  });
99
+ useLayoutEffect(() => {
100
+ const noticeEl = notice && !isIframePure ? noticeElRef.current : null;
101
+ const visibleTabsBarEl = isTabsLayout && hasTabs && !isIframePure ? tabsBarEl : null;
102
+ let active = true;
103
+ const measureStickyElements = () => {
104
+ if (!active) return;
105
+ const nextHeights = {
106
+ notice: noticeEl?.getBoundingClientRect().height ?? 0,
107
+ tabsBar: visibleTabsBarEl?.getBoundingClientRect().height ?? 0
108
+ };
109
+ setStickyHeights(currentHeights => currentHeights.notice === nextHeights.notice && currentHeights.tabsBar === nextHeights.tabsBar ? currentHeights : nextHeights);
110
+ };
111
+ measureStickyElements();
112
+ const observedElements = [noticeEl, visibleTabsBarEl].filter(element => element !== null);
113
+ if (observedElements.length === 0 || typeof ResizeObserver === 'undefined') {
114
+ return () => {
115
+ active = false;
116
+ };
117
+ }
118
+ const resizeObserver = new ResizeObserver(measureStickyElements);
119
+ observedElements.forEach(element => resizeObserver.observe(element));
120
+ return () => {
121
+ active = false;
122
+ resizeObserver.disconnect();
123
+ };
124
+ }, [hasTabs, isIframePure, isTabsLayout, notice, tabsBarEl]);
91
125
  const [collapsed, {
92
126
  toggle,
93
127
  set
@@ -214,11 +248,12 @@ const ProLayout = props => {
214
248
  'pro-layout-row-top-pure': typeof pure !== 'boolean' && pure.topMenu,
215
249
  'pro-layout-row-left-pure': typeof pure !== 'boolean' && pure.leftMenu
216
250
  });
217
- const noticeHeight = notice ? 32 : 0;
251
+ const noticeHeight = stickyHeights.notice;
218
252
 
219
253
  // pure 模式下 Header 不渲染,有效头部高度为 0
220
254
  const isPureHeader = typeof pure === 'boolean' ? pure : !!pure?.topMenu;
221
255
  const effectiveHeaderHeight = isPureHeader ? 0 : headerHeight;
256
+ const contentStickyTop = effectiveHeaderHeight + noticeHeight + (hasTabs ? stickyHeights.tabsBar : 0);
222
257
 
223
258
  // 为Header组件创建专门的props对象
224
259
  const headerProps = {
@@ -234,9 +269,10 @@ const ProLayout = props => {
234
269
 
235
270
  // 为Notice组件创建专门的props对象
236
271
  const noticeProps = {
237
- headerHeight,
272
+ headerHeight: effectiveHeaderHeight,
238
273
  notice,
239
- onCancel: onCancelNotice
274
+ onCancel: onCancelNotice,
275
+ noticeRef: setNoticeElRef
240
276
  };
241
277
 
242
278
  // 为Menu组件创建专门的props对象
@@ -278,7 +314,9 @@ const ProLayout = props => {
278
314
  }),
279
315
  style: {
280
316
  '--header-bg-image': `url(${headerBg})`,
281
- '--pro-layout-header-height': `${effectiveHeaderHeight}px`
317
+ '--pro-layout-header-height': `${effectiveHeaderHeight}px`,
318
+ '--pro-layout-notice-height': `${noticeHeight}px`,
319
+ '--pro-layout-content-sticky-top': `${contentStickyTop}px`
282
320
  },
283
321
  children: [/*#__PURE__*/_jsx(Header, {
284
322
  ...headerProps
@@ -519,6 +519,10 @@ export interface TabsConfig {
519
519
  max?: number;
520
520
  storage?: TabsStorageStrategy;
521
521
  cacheKey?: string;
522
+ /**
523
+ * @description 普通初始标签页。无缓存时每次 ProLayout 挂载只初始化一次;关闭全部后本次挂载期间不会重新添加
524
+ */
525
+ initialTabs?: AddTabParams[];
522
526
  onTabChange?: (activeKey: string, activeTab: TabItem | undefined, allTabs: TabItem[]) => void;
523
527
  /**
524
528
  * @description 是否允许标签页拖拽排序
@@ -293,9 +293,9 @@
293
293
  margin-right: var(--zaui-space-size-md, 16px);
294
294
  margin-left: 48px;
295
295
  padding: 0;
296
- // 滚动时固定在 header 正下方
296
+ // 滚动时固定在 header 和 notice 正下方
297
297
  position: sticky;
298
- top: var(--pro-layout-header-height, 64px);
298
+ top: calc(var(--pro-layout-header-height, 64px) + var(--pro-layout-notice-height, 0px));
299
299
  z-index: 89;
300
300
  // 与 ::before 渐变层像素级对齐:滚动时遮住上滚的白色内容,同时保持渐变背景可见
301
301
  // background-color 作为实体打底,防止渐变图片浅色区域透出白色内容
@@ -322,6 +322,12 @@
322
322
  grid-template-rows: 1fr;
323
323
  }
324
324
 
325
+ // 页面顶部的圆角会向内容区延伸,此时放到 content 层级下方,
326
+ // 让内容区内的 ProStep 能完整遮住圆角;滚动后恢复上方的 89 保持 sticky 遮挡。
327
+ &.tabs-at-top {
328
+ z-index: 9;
329
+ }
330
+
325
331
  // Grid 子元素需要 overflow: hidden 才能实现 0fr 收起
326
332
  > * {
327
333
  overflow: hidden;
@@ -388,6 +394,13 @@
388
394
 
389
395
  .pro-layout-tabs-content {
390
396
  > .tab-pane {
397
+ // ProStep 以 ProHeader 开头时,去掉 tabs 内容区的顶部/右侧外层留白。
398
+ // ProStep 保持默认 right: 0,内容与收起态步骤条保留 16px 间距;左侧缩进不变。
399
+ > .pro-step-wrapper:has(> .pro-header:first-child) {
400
+ margin-top: calc(-1px - var(--zaui-space-size-md, 16px));
401
+ margin-right: calc(-1px - var(--zaui-space-size-md, 16px));
402
+ }
403
+
391
404
  > .pro-header.pro-header-no-describe:first-child {
392
405
  padding: 0 !important;
393
406
 
@@ -1,4 +1,5 @@
1
+ /// <reference types="react" />
1
2
  declare const AdaptiveTooltip: ({ children }: {
2
3
  children: any;
3
- }) => import("react/jsx-runtime").JSX.Element;
4
+ }) => import("react").JSX.Element;
4
5
  export default AdaptiveTooltip;
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
2
  import type { PropSelectType, ProSelectActionType } from './propsType';
3
- export declare const ProSelect: (props: PropSelectType, ref: React.Ref<ProSelectActionType> | undefined) => import("react/jsx-runtime").JSX.Element;
3
+ export declare const ProSelect: (props: PropSelectType, ref: React.Ref<ProSelectActionType> | undefined) => React.JSX.Element;
4
4
  declare const _default: React.ForwardRefExoticComponent<PropSelectType & React.RefAttributes<ProSelectActionType>>;
5
5
  export default _default;
@@ -1,5 +1,6 @@
1
+ import React from 'react';
1
2
  import { ProStepType } from '../../propsType';
2
- export declare const Step: ({ fixedTop, dataSource, activeKey, errorCollection, style, targetOffset, scrollToError, }: ProStepType & {
3
+ export declare const Step: ({ fixedTop, dataSource, activeKey, errorCollection, style, targetOffset, scrollToError, }: import("../../propsType").ProStepPropsType & {
3
4
  errorCollection: object;
4
- }) => import("react/jsx-runtime").JSX.Element;
5
+ }) => React.JSX.Element;
5
6
  export default Step;
@@ -5,8 +5,10 @@ import catalogSvg from "../../../assets/catalog.svg";
5
5
  import Anchor from "../Anchor";
6
6
  import locale from "../../../locale";
7
7
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
8
+ const DEFAULT_FIXED_TOP = 'var(--pro-layout-content-sticky-top, 64px)';
9
+ const toCssLength = value => typeof value === 'number' ? `${value}px` : value;
8
10
  export const Step = ({
9
- fixedTop = 64,
11
+ fixedTop = DEFAULT_FIXED_TOP,
10
12
  dataSource = [],
11
13
  activeKey,
12
14
  errorCollection,
@@ -15,6 +17,7 @@ export const Step = ({
15
17
  scrollToError
16
18
  }) => {
17
19
  const [onOff, setOnOff] = useState(false);
20
+ const fixedTopCss = toCssLength(fixedTop);
18
21
  const options = useMemo(() => {
19
22
  const nextDataSource = _cloneDeep(dataSource);
20
23
  let activeIndex;
@@ -45,8 +48,8 @@ export const Step = ({
45
48
  return /*#__PURE__*/_jsxs("div", {
46
49
  className: `pro-step ${onOff ? 'pro-step-open' : 'pro-step-closed'}`,
47
50
  style: {
48
- top: fixedTop ?? 0,
49
- maxHeight: `calc(100vh - ${fixedTop}px)`,
51
+ top: fixedTopCss,
52
+ maxHeight: `calc(100vh - ${fixedTopCss})`,
50
53
  ...style
51
54
  },
52
55
  onMouseEnter: handleMouseEnter,
@@ -5,7 +5,7 @@ export declare const useStep: () => Partial<ProStepContextType>;
5
5
  declare const ProStep: {
6
6
  ({ children, ...resetProps }: ProStepType): ReactNode;
7
7
  useStep: () => Partial<ProStepContextType>;
8
- Item: ({ id, title, collapse: collapseItem, children, lazyLoad: stepLazyLoad, order, ...restProps }: import("./propsType").ProStepItemType) => ReactNode;
9
- Listener: ({ children, delayTime, excludes, ...props }: import("./propsType").ListenerProps) => import("react").ReactElement;
8
+ Item: ({ id, title, collapse: collapseItem, children, lazyLoad: stepLazyLoad, order, ...restProps }: import("./propsType").ProStepItemPropsType) => ReactNode;
9
+ Listener: ({ children, delayTime, excludes, ...props }: import("./propsType").ListenerProps) => import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>>;
10
10
  };
11
11
  export default ProStep;
@@ -37,8 +37,8 @@ export type LoadedMapType = LoadedMapPropsType;
37
37
  export interface ProStepPropsType {
38
38
  /** 步骤条配置项 */
39
39
  dataSource?: ItemType[];
40
- /** 距离顶部的偏移量(单位:像素) */
41
- fixedTop: number;
40
+ /** 距离顶部的偏移量,支持像素值或 CSS 长度 */
41
+ fixedTop?: string | number;
42
42
  /** 当前激活的步骤标识 */
43
43
  activeKey?: string;
44
44
  /** 子组件内容 */
@@ -13,7 +13,7 @@ export declare const formatColumn: ({ column, originalObj, rowKey, wrapToolTipPr
13
13
  scroll?: any;
14
14
  isInNewRow?: any;
15
15
  diffConfig: any;
16
- editMode?: "per-cell-form" | "shared-form";
16
+ editMode?: 'per-cell-form' | 'shared-form';
17
17
  sharedForm?: FormInstance;
18
18
  }) => void;
19
19
  /**
@@ -1,2 +1,3 @@
1
+ /// <reference types="react" />
1
2
  declare const _default: import("react").NamedExoticComponent<Omit<any, "ref"> & import("react").RefAttributes<any>>;
2
3
  export default _default;
@@ -14,5 +14,5 @@ declare const DndWrapper: ({ draggable, value, onChange, disabled, children, row
14
14
  rowKey: any;
15
15
  onDragStartGuard: any;
16
16
  onDragEndGuard: any;
17
- }) => import("react/jsx-runtime").JSX.Element;
17
+ }) => React.JSX.Element;
18
18
  export default DndWrapper;
@@ -1,2 +1,3 @@
1
+ /// <reference types="react" />
1
2
  declare const _default: import("react").NamedExoticComponent<Omit<any, "ref"> & import("react").RefAttributes<any>>;
2
3
  export default _default;
@@ -1,2 +1,3 @@
1
- declare const RenderFooter: (props: any) => import("react/jsx-runtime").JSX.Element;
1
+ /// <reference types="react" />
2
+ declare const RenderFooter: (props: any) => import("react").JSX.Element;
2
3
  export default RenderFooter;
@@ -1,2 +1,3 @@
1
- declare const RenderTableHeader: (props: any) => import("react/jsx-runtime").JSX.Element;
1
+ /// <reference types="react" />
2
+ declare const RenderTableHeader: (props: any) => import("react").JSX.Element;
2
3
  export default RenderTableHeader;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import type { ProTableTabsType } from '../../propsType';
2
- declare const _default: import("react").MemoExoticComponent<(props: ProTableTabsType) => import("react/jsx-runtime").JSX.Element>;
3
+ declare const _default: import("react").MemoExoticComponent<(props: ProTableTabsType) => import("react").JSX.Element>;
3
4
  export default _default;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  declare const _default: {
2
3
  components: {
3
4
  header: {
@@ -6,7 +7,7 @@ declare const _default: {
6
7
  onDrag: any;
7
8
  width: number;
8
9
  minwidth?: number;
9
- }) => import("react/jsx-runtime").JSX.Element;
10
+ }) => import("react").JSX.Element;
10
11
  };
11
12
  };
12
13
  };
@@ -6,7 +6,7 @@ export declare const defaultPage: {
6
6
  pageNum: number;
7
7
  pageSize: number;
8
8
  };
9
- declare const ProTable: React.ForwardRefExoticComponent<ProTableType & React.RefAttributes<any>> & {
9
+ declare const ProTable: React.ForwardRefExoticComponent<ProTableType<any> & React.RefAttributes<any>> & {
10
10
  useAntdTable: typeof useAntdTable;
11
11
  SELECTION_ALL: typeof SELECTION_ALL;
12
12
  CURRENT_PAGE: typeof CURRENT_PAGE;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { CardType } from '../../propType';
2
- declare const Card: (props: CardType) => import("react/jsx-runtime").JSX.Element;
3
+ declare const Card: (props: CardType) => import("react").JSX.Element;
3
4
  export default Card;
@@ -1,3 +1,4 @@
1
+ import React from 'react';
1
2
  import type { DevToolsPropsType } from '../../propsType';
2
- declare const ProTools: ({ onReset, onClose, setState, open, state, tableBorder, tableStripe, }: DevToolsPropsType) => import("react/jsx-runtime").JSX.Element;
3
+ declare const ProTools: ({ onReset, onClose, setState, open, state, tableBorder, tableStripe, }: DevToolsPropsType) => React.JSX.Element;
3
4
  export default ProTools;
@@ -1,6 +1,7 @@
1
+ /// <reference types="react" />
1
2
  import type { ProThemeToolsType } from './propsType';
2
3
  declare const ProThemeTools: {
3
- ({ size, className, cacheTime, color, mode, iconFollowTheme, prefixCls, tableBorder, tableStripe, theme, onChange, ...props }: ProThemeToolsType): import("react/jsx-runtime").JSX.Element;
4
+ ({ size, className, cacheTime, color, mode, iconFollowTheme, prefixCls, tableBorder, tableStripe, theme, onChange, ...props }: ProThemeToolsType): import("react").JSX.Element;
4
5
  setThemes: (themes: import("./utils/index").ThemesProps) => boolean;
5
6
  };
6
7
  export default ProThemeTools;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import type { ProTooltipType } from './propsType';
2
- declare const ProTooltip: (props: ProTooltipType) => import("react/jsx-runtime").JSX.Element;
3
+ declare const ProTooltip: (props: ProTooltipType) => import("react").JSX.Element;
3
4
  export default ProTooltip;
@@ -1,4 +1,5 @@
1
+ /// <reference types="react" />
1
2
  declare const AdaptiveTooltip: ({ children }: {
2
3
  children: any;
3
- }) => import("react/jsx-runtime").JSX.Element;
4
+ }) => import("react").JSX.Element;
4
5
  export default AdaptiveTooltip;
@@ -1,2 +1,3 @@
1
- declare function CloseIcon(props: any): import("react/jsx-runtime").JSX.Element;
1
+ /// <reference types="react" />
2
+ declare function CloseIcon(props: any): import("react").JSX.Element;
2
3
  export default CloseIcon;
@@ -12,6 +12,6 @@ interface ListProps {
12
12
  handleFilterClose?: (code: string) => void;
13
13
  optionRender?: (item: any, searchStr?: string) => string | ReactNode;
14
14
  }
15
- declare function List(props: ListProps): import("react/jsx-runtime").JSX.Element;
15
+ declare function List(props: ListProps): import("react").JSX.Element;
16
16
  declare const _default: import("react").MemoExoticComponent<typeof List>;
17
17
  export default _default;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import type { ProTreeType } from '../propsType';
2
- declare const ProTree: (props: ProTreeType) => import("react/jsx-runtime").JSX.Element;
3
+ declare const ProTree: (props: ProTreeType) => import("react").JSX.Element;
3
4
  export default ProTree;
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
2
  import type { ProTreeSelectType } from './propsType';
3
- export declare const ProTreeSelect: (props: ProTreeSelectType, ref: React.Ref<unknown> | undefined) => import("react/jsx-runtime").JSX.Element;
3
+ export declare const ProTreeSelect: (props: ProTreeSelectType, ref: React.Ref<unknown> | undefined) => React.JSX.Element;
4
4
  declare const _default: React.ForwardRefExoticComponent<ProTreeSelectType & React.RefAttributes<unknown>>;
5
5
  export default _default;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import type { ProFormOtherType } from '../../ProForm/propsType';
2
3
  declare function SearchTitle(props: {
3
4
  searchStr?: string;
@@ -5,6 +6,6 @@ declare function SearchTitle(props: {
5
6
  showEllipse?: boolean;
6
7
  ellipseWidth?: string;
7
8
  otherProps?: ProFormOtherType;
8
- }): import("react/jsx-runtime").JSX.Element;
9
+ }): import("react").JSX.Element;
9
10
  declare const _default: import("react").MemoExoticComponent<typeof SearchTitle>;
10
11
  export default _default;
@@ -1,4 +1,4 @@
1
- import { ReactNode } from 'react';
1
+ import React, { ReactNode } from 'react';
2
2
  import type { ProTreeFieldNamesType, ProTreeType } from '../propsType';
3
3
  interface ListProps extends ProTreeType {
4
4
  disabled?: boolean;
@@ -23,5 +23,5 @@ interface ListProps extends ProTreeType {
23
23
  handleFilterClose?: (code: string, node?: any) => void;
24
24
  [key: string]: any;
25
25
  }
26
- declare function List(props: ListProps): import("react/jsx-runtime").JSX.Element;
26
+ declare function List(props: ListProps): React.JSX.Element;
27
27
  export default List;
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import type { ProTreeType } from './propsType';
2
- declare const ProTreeHandle: (props: ProTreeType) => import("react/jsx-runtime").JSX.Element;
3
+ declare const ProTreeHandle: (props: ProTreeType) => import("react").JSX.Element;
3
4
  export default ProTreeHandle;
@@ -10,5 +10,5 @@ interface CascaderProps {
10
10
  handleOnChange?: (e: any, value: string) => void;
11
11
  optionRender?: (item: any, searchStr: string) => string | ReactNode;
12
12
  }
13
- declare const Cascader: (props: CascaderProps) => import("react/jsx-runtime").JSX.Element;
13
+ declare const Cascader: (props: CascaderProps) => import("react").JSX.Element;
14
14
  export default Cascader;
@@ -1,2 +1,3 @@
1
- declare function CloseIcon(props: any): import("react/jsx-runtime").JSX.Element;
1
+ /// <reference types="react" />
2
+ declare function CloseIcon(props: any): import("react").JSX.Element;
2
3
  export default CloseIcon;
@@ -1,6 +1,7 @@
1
+ /// <reference types="react" />
1
2
  declare function SearchTitle(props: {
2
3
  searchStr: string;
3
4
  label: string;
4
- }): import("react/jsx-runtime").JSX.Element;
5
+ }): import("react").JSX.Element;
5
6
  declare const _default: import("react").MemoExoticComponent<typeof SearchTitle>;
6
7
  export default _default;
@@ -17,5 +17,5 @@ interface TriggerProps {
17
17
  handleClearAll: () => void;
18
18
  appointChange: (appoint?: boolean) => void;
19
19
  }
20
- declare function Trigger(props: TriggerProps): import("react/jsx-runtime").JSX.Element;
20
+ declare function Trigger(props: TriggerProps): import("react").JSX.Element;
21
21
  export default Trigger;
@@ -1,4 +1,5 @@
1
+ import React from 'react';
1
2
  import type { ProTreeModalType } from './propsType';
2
3
  export declare const CASCADER = "CASCADER";
3
- declare const ProTreeModal: (props: ProTreeModalType) => import("react/jsx-runtime").JSX.Element;
4
+ declare const ProTreeModal: (props: ProTreeModalType) => React.JSX.Element;
4
5
  export default ProTreeModal;
@@ -1,2 +1,3 @@
1
+ import React from 'react';
1
2
  import type { DraggableUploadListItemType } from '../propsType';
2
- export declare const DraggableUploadListItem: ({ file, children }: DraggableUploadListItemType) => import("react/jsx-runtime").JSX.Element;
3
+ export declare const DraggableUploadListItem: ({ file, children }: DraggableUploadListItemType) => React.JSX.Element;
@@ -10,7 +10,7 @@ export interface UseDraggableRowStateOptions {
10
10
  disabled?: boolean;
11
11
  }
12
12
  export declare const useDraggableRowState: ({ id, disabled }: UseDraggableRowStateOptions) => {
13
- setNodeRef: (node: HTMLElement | null) => void;
13
+ setNodeRef: (node: HTMLElement) => void;
14
14
  style: React.CSSProperties;
15
15
  listeners: import("@dnd-kit/core/dist/hooks/utilities").SyntheticListenerMap;
16
16
  attributes: import("@dnd-kit/core").DraggableAttributes;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zat-design/sisyphus-react",
3
- "version": "4.5.7",
3
+ "version": "4.5.8-beta.3",
4
4
  "license": "MIT",
5
5
  "publishConfig": {
6
6
  "access": "public",
@@ -101,22 +101,6 @@
101
101
  "Firefox ESR",
102
102
  "> 1%"
103
103
  ],
104
- "overrides": {
105
- "react-resizable": {
106
- "react-draggable": "<4.5.0"
107
- },
108
- "@babel/core": "^7.26.0",
109
- "react-docgen-typescript-dumi-tmp": {
110
- "typescript": "^4.9.5"
111
- },
112
- "esbuild": "0.21.4"
113
- },
114
- "resolutions": {
115
- "react-resizable/react-draggable": "<4.5.0",
116
- "@babel/core": "^7.26.0",
117
- "react-docgen-typescript-dumi-tmp/typescript": "^4.9.5",
118
- "esbuild": "0.21.4"
119
- },
120
104
  "dependencies": {
121
105
  "@dnd-kit/core": "^6.0.8",
122
106
  "@dnd-kit/sortable": "^7.0.2",
@@ -129,7 +113,7 @@
129
113
  "idb-keyval": "^6.2.2",
130
114
  "lodash": "^4.17.21",
131
115
  "react-intersection-observer": "^9.13.0",
132
- "react-resizable": "^3.0.5",
116
+ "react-resizable": "^3.1.3",
133
117
  "react-svg": "^17.2.4"
134
118
  },
135
119
  "peerDependencies": {
@@ -188,7 +172,8 @@
188
172
  "react-router-dom": "^6.0.0",
189
173
  "stylelint": "^16.0.0",
190
174
  "stylelint-checkstyle-formatter": "0.1.2",
191
- "typescript": "^5.4.0"
175
+ "typescript": "^5.4.0",
176
+ "typescript-dumi1": "npm:typescript@4.9.5"
192
177
  },
193
178
  "checkFiles": [
194
179
  "src/**/*.js*",