@gx-design-vue/pro-table 0.2.0-beta.122 → 0.2.0-beta.124

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.
@@ -31,8 +31,8 @@ export declare function useFetchData({ rowKey, polling, request, postData, dataS
31
31
  dataSource: ComputedRef<RecordType[]>;
32
32
  isTreeDataRef: ComputedRef<boolean>;
33
33
  reSetDataList: (list: RecordType[]) => void;
34
- changeDataValue: ({ key, type, params, value }: {
35
- params?: Partial<RecordType> | undefined;
34
+ changeDataValue: ({ key, type, row, value }: {
35
+ row?: Partial<RecordType> | undefined;
36
36
  key?: string | undefined;
37
37
  value?: any;
38
38
  type?: "update" | "push" | "delete" | "unshift";
@@ -1,5 +1,5 @@
1
1
  import type { RecordType } from '@gx-design-vue/pro-utils';
2
- import type { ComputedRef, MaybeRef, Ref } from 'vue';
2
+ import type { ComputedRef, MaybeRef, Reactive, Ref } from 'vue';
3
3
  import type { BaseTableProps } from '../props';
4
4
  import type { ProColumnsType, ProSearchMap } from '../types/ColumnTypings';
5
5
  import type { ProCoreActionType, ProCoreFormType, ProTableProps, ProTableRef, ProTableRowSelection, RequestConfig, RequestFunction } from '../types/TableTypings';
@@ -17,7 +17,7 @@ export type ProTableState<T extends object = RecordType, R extends object = Reco
17
17
  };
18
18
  export type BaseTableState<T extends object = RecordType, R extends object = RecordType> = Omit<ProTableProps<T, R>, 'request'>;
19
19
  export declare function useTable<T extends object = RecordType, R extends object = RecordType>(tableRef: Ref<ProTableRef<T> | undefined>, options?: {
20
- state?: MaybeRef<BaseTableState<T, R>>;
20
+ state?: MaybeRef<BaseTableState<T, R>> | Reactive<BaseTableState<T, R>>;
21
21
  request?: RequestFunction<T, R>;
22
22
  }): {
23
23
  loading: Ref<boolean>;
@@ -35,6 +35,6 @@ export declare function useTable<T extends object = RecordType, R extends object
35
35
  setLoading: ProCoreActionType<T, R>['setLoading'];
36
36
  actionRef: ComputedRef<Partial<ProCoreActionType<T, R>>>;
37
37
  formRef: ComputedRef<ProCoreFormType<R>>;
38
- tableState: ProTableState<T, R>;
38
+ tableState: Reactive<ProTableState<T, R>>;
39
39
  updateSearchMap: (key: keyof R | keyof T, value: Partial<any>) => void;
40
40
  };