@zat-design/sisyphus-react 4.3.4-beta.1 → 4.3.4

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.
@@ -75,35 +75,39 @@ export declare const useFormItemProps: (column: FlexibleGroupColumnType, context
75
75
  confirm?: boolean | import("antd").ModalFuncProps | import("../../../render/propsType").FunctionArgs<any, boolean | import("antd").ModalFuncProps>;
76
76
  show?: boolean | ReactiveFunction<any, boolean>;
77
77
  component?: React.ReactNode | ReactiveFunction<any, React.ReactNode>;
78
- status?: "" | "warning" | "error" | "success" | "validating";
79
- className?: string;
80
- hidden?: boolean;
81
- id?: string;
78
+ trigger?: string;
82
79
  style?: React.CSSProperties;
80
+ hidden?: boolean;
81
+ layout?: import("antd/es/form/Form").FormItemLayout;
82
+ help?: React.ReactNode;
83
+ vertical?: boolean;
84
+ preserve?: boolean;
83
85
  children?: React.ReactNode | ((form: FormInstance<any>) => React.ReactNode);
84
- onReset?: () => void;
85
- prefixCls?: string;
86
- rootClassName?: string;
87
86
  isView?: boolean;
88
- vertical?: boolean;
89
87
  trim?: boolean;
90
88
  normalize?: (value: any, prevValue: any, allValues: import("@rc-component/form/lib/interface").Store) => any;
91
- trigger?: string;
92
- htmlFor?: string;
89
+ className?: string;
90
+ status?: "" | "warning" | "error" | "success" | "validating";
91
+ prefixCls?: string;
92
+ rootClassName?: string;
93
+ id?: string;
94
+ onReset?: () => void;
95
+ getValueProps?: ((value: any) => Record<string, unknown>) & ((value: any) => Record<string, unknown>);
96
+ desensitization?: [number, number] | ReactiveFunction<any, [number, number]>;
97
+ validateTrigger?: string | false | string[];
93
98
  clearNotShow?: boolean;
94
- colon?: boolean;
95
99
  labelAlign?: import("antd/es/form/interface").FormLabelAlign;
100
+ colon?: boolean;
96
101
  labelCol?: import("antd").ColProps;
102
+ wrapperCol?: import("antd").ColProps;
103
+ htmlFor?: string;
97
104
  getValueFromEvent?: (...args: import("@rc-component/form/lib/interface").EventArgs) => any;
98
105
  shouldUpdate?: import("@rc-component/form/lib/Field").ShouldUpdate<any>;
99
- validateTrigger?: string | false | string[];
100
106
  validateDebounce?: number;
101
107
  valuePropName?: string;
102
- getValueProps?: ((value: any) => Record<string, unknown>) & ((value: any) => Record<string, unknown>);
103
108
  messageVariables?: Record<string, string>;
104
109
  initialValue?: any;
105
110
  onMetaChange?: (meta: import("@rc-component/form/lib/Field").MetaEvent) => void;
106
- preserve?: boolean;
107
111
  isListField?: boolean;
108
112
  isList?: boolean;
109
113
  noStyle?: boolean;
@@ -111,9 +115,6 @@ export declare const useFormItemProps: (column: FlexibleGroupColumnType, context
111
115
  icons: import("antd/es/form/FormItem").FeedbackIcons;
112
116
  };
113
117
  validateStatus?: "" | "warning" | "error" | "success" | "validating";
114
- layout?: import("antd/es/form/Form").FormItemLayout;
115
- wrapperCol?: import("antd").ColProps;
116
- help?: React.ReactNode;
117
118
  fieldId?: string;
118
119
  valueType?: import("../../../render/propsType").ProFormValueType;
119
120
  switchValue?: [any, any];
@@ -126,7 +127,6 @@ export declare const useFormItemProps: (column: FlexibleGroupColumnType, context
126
127
  upperCase?: boolean;
127
128
  toISOString?: boolean;
128
129
  toCSTString?: boolean;
129
- desensitization?: [number, number] | ReactiveFunction<any, [number, number]>;
130
130
  name: any;
131
131
  dependencies: any[];
132
132
  tooltip: string | {
@@ -141,7 +141,7 @@ export declare const useFormItemProps: (column: FlexibleGroupColumnType, context
141
141
  * 创建组件属性
142
142
  */
143
143
  export declare const createComponentProps: (column: FlexibleGroupColumnType, formItemProps: any) => {
144
- componentProps: import("lodash").Omit<any, "clearNotShow" | "format" | "valueType" | "switchValue" | "dependNames" | "toISOString" | "toCSTString" | "precision">;
144
+ componentProps: import("lodash").Omit<any, "format" | "clearNotShow" | "valueType" | "switchValue" | "dependNames" | "toISOString" | "toCSTString" | "precision">;
145
145
  formItemTransform: {
146
146
  getValueProps: any;
147
147
  normalize: any;
@@ -59,6 +59,7 @@ export const Step = ({
59
59
  size: 32,
60
60
  actionMap: {}
61
61
  }), onOff && /*#__PURE__*/_jsx("div", {
62
+ className: "pro-step-menu-name",
62
63
  children: locale?.ProStep?.catalogue
63
64
  })]
64
65
  }), options.map(item => {
@@ -22,10 +22,14 @@
22
22
  > .pro-step-menu {
23
23
  display: flex;
24
24
  align-items: center;
25
+ padding-left: 8px;
25
26
  width: 100%;
26
27
  height: 48px;
27
28
  font-size: var(--zaui-font-size-lg, 16px);
28
29
  border-bottom: 1px solid var(--zaui-line, #dddddd);
30
+ .pro-step-menu-name{
31
+ margin-left: 8px;
32
+ }
29
33
  > .anticon {
30
34
  display: flex;
31
35
  align-items: center;
@@ -100,7 +100,7 @@
100
100
  }
101
101
  .pro-table-drag-wrapper {
102
102
  display: flex;
103
- justify-content: flex-end;
103
+ justify-content: center;
104
104
  margin-right: 8px;
105
105
  .@{ant-prefix}-btn:hover {
106
106
  background: #fff !important;
@@ -293,7 +293,7 @@ const ProTreeModal = props => {
293
293
  /**
294
294
  * clear all checked
295
295
  */
296
- const handleClearAll = () => {
296
+ const handleClearAll = (immediateSubmit = false) => {
297
297
  // 处理 ProTable 场景下 disabled 的不需要被清理
298
298
  const _checkedValues = span ? state.flatTreeData.filter(item => item.disabled)?.map(item => item[fieldNameValue]) : [];
299
299
  setState({
@@ -303,11 +303,12 @@ const ProTreeModal = props => {
303
303
  treeViewData: [],
304
304
  checkAll: false
305
305
  });
306
- // 通知父组件更新 value prop,确保清空操作被正确保存
307
- if (labelInValue) {
308
- onChange?.([]);
309
- } else {
310
- onChange?.(_checkedValues);
306
+ if (immediateSubmit) {
307
+ if (labelInValue) {
308
+ onChange?.([]);
309
+ } else {
310
+ onChange?.(_checkedValues);
311
+ }
311
312
  }
312
313
  };
313
314
 
@@ -580,7 +581,7 @@ const ProTreeModal = props => {
580
581
  allValue: allValue,
581
582
  label: props?.otherProps?.label,
582
583
  handleClick: handleClick,
583
- handleClearAll: handleClearAll,
584
+ handleClearAll: () => handleClearAll(true),
584
585
  appointChange: appointChange,
585
586
  appointProps: appointProps
586
587
  });
@@ -798,7 +799,7 @@ const ProTreeModal = props => {
798
799
  }), !isView ? /*#__PURE__*/_jsx(Button, {
799
800
  disabled: disabled,
800
801
  type: "link",
801
- onClick: handleClearAll,
802
+ onClick: () => handleClearAll(false),
802
803
  children: locale?.ProTreeModal?.clearAll
803
804
  }) : null]
804
805
  }), /*#__PURE__*/_jsx("div", {
@@ -328,7 +328,7 @@
328
328
  }
329
329
  .checked-item.checked-item-0.disabled {
330
330
  .disabled-icon {
331
- margin: 4px 0 0 2px;
331
+ margin: 2px 0 0 2px;
332
332
  }
333
333
  }
334
334
  .checked-item {
@@ -351,6 +351,14 @@
351
351
  }
352
352
  }
353
353
 
354
+ &.dragable:not(.disabled) {
355
+ .pro-icon,
356
+ .pro-icon > div,
357
+ .pro-icon svg {
358
+ cursor: move;
359
+ }
360
+ }
361
+
354
362
  &:first-child {
355
363
  margin-top: 0;
356
364
  }
@@ -375,8 +383,8 @@
375
383
 
376
384
  .disabled-icon {
377
385
  height: 20px;
378
- margin-right: var(--zaui-space-size-xs, 4px);
379
- margin-left: 6px;
386
+ margin-right: 0;
387
+ margin-left: 2px;
380
388
  margin-top: 2px;
381
389
  }
382
390
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zat-design/sisyphus-react",
3
- "version": "4.3.4-beta.1",
3
+ "version": "4.3.4",
4
4
  "license": "MIT",
5
5
  "files": [
6
6
  "es",
@@ -98,15 +98,13 @@
98
98
  "react-docgen-typescript-dumi-tmp": {
99
99
  "typescript": "^4.9.5"
100
100
  },
101
- "esbuild": "0.21.4",
102
- "@umijs/bundler-utils": "^4.6.35"
101
+ "esbuild": "0.21.4"
103
102
  },
104
103
  "resolutions": {
105
104
  "react-resizable/react-draggable": "<4.5.0",
106
105
  "@babel/core": "^7.26.0",
107
106
  "react-docgen-typescript-dumi-tmp/typescript": "^4.9.5",
108
- "esbuild": "0.21.4",
109
- "@umijs/bundler-utils": "^4.6.35"
107
+ "esbuild": "0.21.4"
110
108
  },
111
109
  "dependencies": {
112
110
  "@dnd-kit/core": "^6.0.8",
@@ -137,6 +135,7 @@
137
135
  "@babel/runtime": "^7.28.4",
138
136
  "@commitlint/cli": "^12.1.1",
139
137
  "@commitlint/config-conventional": "^12.1.1",
138
+ "@locator/babel-jsx": "^0.5.1",
140
139
  "@testing-library/dom": "^10.0.0",
141
140
  "@testing-library/jest-dom": "^6.0.0",
142
141
  "@testing-library/react": "^16.0.0",