linkmore-design 1.1.27 → 1.1.28-alpha.6

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 (141) hide show
  1. package/dist/LmEditTable/DndContainer.d.ts +6 -3
  2. package/dist/LmEditTable/EditTable.d.ts +15 -5
  3. package/dist/LmEditTable/components/DraggableContainer.d.ts +10 -0
  4. package/dist/LmEditTable/components/QuickOpetate.d.ts +12 -0
  5. package/dist/LmEditTable/components/bottomOpetateComponent.d.ts +13 -0
  6. package/dist/LmEditTable/components/customRenderEmpty.d.ts +2 -0
  7. package/dist/LmEditTable/components/index.d.ts +17 -0
  8. package/dist/LmEditTable/hooks/useForkRef.d.ts +2 -0
  9. package/dist/LmEditTable/rowSort/DndContainerRow.d.ts +10 -0
  10. package/dist/LmEditTable/sortableItem.d.ts +3 -2
  11. package/dist/LmEditTable/util.d.ts +10 -0
  12. package/dist/LmEditTable/virtual/VirtualRow.d.ts +7 -0
  13. package/dist/LmEditTable/virtual/VirtualRow2.d.ts +7 -0
  14. package/dist/LmEditTable/virtual/VirtualTable.d.ts +3 -0
  15. package/dist/LmEditTable/virtual/VirtualWrapper.d.ts +3 -0
  16. package/dist/LmEditTable/virtual/context.d.ts +13 -0
  17. package/dist/LmEditTable/virtual/index.d.ts +4 -0
  18. package/dist/LmTable/virTual/VirtualRow.d.ts +1 -1
  19. package/dist/index.d.ts +1 -2
  20. package/dist/index.umd.js +1909 -679
  21. package/dist/index.umd.min.js +21 -21
  22. package/dist/variables.css +115 -2
  23. package/es/CardTable/style/index.css +3 -2
  24. package/es/CardTable/style/variables.css +3 -2
  25. package/es/CustomTableOption/columnsSort.js +41 -18
  26. package/es/CustomTableOption/filterSort.js +14 -6
  27. package/es/CustomTableOption/style/index.css +3 -0
  28. package/es/CustomTableOption/style/variables.css +3 -0
  29. package/es/Form/FormItem/index.js +5 -1
  30. package/es/InputNumber/index.js +7 -9
  31. package/es/LmEditTable/DndContainer.d.ts +6 -3
  32. package/es/LmEditTable/DndContainer.js +70 -10
  33. package/es/LmEditTable/DragHandle.js +1 -1
  34. package/es/LmEditTable/EditTable.d.ts +15 -5
  35. package/es/LmEditTable/EditTable.js +696 -361
  36. package/es/LmEditTable/components/DraggableContainer.d.ts +10 -0
  37. package/es/LmEditTable/components/DraggableContainer.js +39 -0
  38. package/es/LmEditTable/components/QuickOpetate.d.ts +12 -0
  39. package/es/LmEditTable/components/QuickOpetate.js +82 -0
  40. package/es/LmEditTable/components/bottomOpetateComponent.d.ts +13 -0
  41. package/es/LmEditTable/components/bottomOpetateComponent.js +23 -0
  42. package/es/LmEditTable/components/customRenderEmpty.d.ts +2 -0
  43. package/es/LmEditTable/components/customRenderEmpty.js +20 -0
  44. package/es/LmEditTable/components/index.d.ts +17 -0
  45. package/es/LmEditTable/components/index.js +8 -0
  46. package/es/LmEditTable/hooks/useForkRef.d.ts +2 -0
  47. package/es/LmEditTable/hooks/useForkRef.js +22 -0
  48. package/es/LmEditTable/rowSort/DndContainerRow.d.ts +10 -0
  49. package/es/LmEditTable/rowSort/DndContainerRow.js +83 -0
  50. package/es/LmEditTable/sortableItem.d.ts +3 -2
  51. package/es/LmEditTable/sortableItem.js +16 -4
  52. package/es/LmEditTable/sortableItemCol.js +40 -10
  53. package/es/LmEditTable/style/index.css +109 -0
  54. package/es/LmEditTable/style/variables.css +109 -0
  55. package/es/LmEditTable/util.d.ts +10 -0
  56. package/es/LmEditTable/util.js +158 -9
  57. package/es/LmEditTable/virtual/VirtualRow.d.ts +7 -0
  58. package/es/LmEditTable/virtual/VirtualRow.js +148 -0
  59. package/es/LmEditTable/virtual/VirtualRow2.d.ts +7 -0
  60. package/es/LmEditTable/virtual/VirtualRow2.js +62 -0
  61. package/es/LmEditTable/virtual/VirtualTable.d.ts +3 -0
  62. package/es/LmEditTable/virtual/VirtualTable.js +64 -0
  63. package/es/LmEditTable/virtual/VirtualWrapper.d.ts +3 -0
  64. package/es/LmEditTable/virtual/VirtualWrapper.js +60 -0
  65. package/es/LmEditTable/virtual/context.d.ts +13 -0
  66. package/es/LmEditTable/virtual/context.js +66 -0
  67. package/es/LmEditTable/virtual/index.d.ts +4 -0
  68. package/es/LmEditTable/virtual/index.js +4 -0
  69. package/es/LmFilter/baseFilter/index.js +3 -2
  70. package/es/LmFilter/filterFns/index.js +4 -2
  71. package/es/LmTable/virTual/VirtualRow.d.ts +1 -1
  72. package/es/LmTable/virTual/VirtualRow.js +82 -48
  73. package/es/LmTable/virTual/VirtualTable.js +17 -9
  74. package/es/LmTable/virTual/context.js +14 -2
  75. package/es/LmUpload/body/UploadCore.js +1 -1
  76. package/es/LmUpload/fns/index.js +1 -1
  77. package/es/Radio/index.js +9 -1
  78. package/es/Switch/index.js +7 -2
  79. package/es/hooks/useEvent/index.js +1 -1
  80. package/es/index.d.ts +1 -2
  81. package/es/styles/variables.css +115 -2
  82. package/lib/CardTable/style/index.css +3 -2
  83. package/lib/CardTable/style/variables.css +3 -2
  84. package/lib/CustomTableOption/columnsSort.js +48 -22
  85. package/lib/CustomTableOption/filterSort.js +19 -10
  86. package/lib/CustomTableOption/style/index.css +3 -0
  87. package/lib/CustomTableOption/style/variables.css +3 -0
  88. package/lib/Form/FormItem/index.js +5 -1
  89. package/lib/InputNumber/index.js +9 -9
  90. package/lib/LmEditTable/DndContainer.d.ts +6 -3
  91. package/lib/LmEditTable/DndContainer.js +74 -9
  92. package/lib/LmEditTable/DragHandle.js +1 -1
  93. package/lib/LmEditTable/EditTable.d.ts +15 -5
  94. package/lib/LmEditTable/EditTable.js +694 -358
  95. package/lib/LmEditTable/components/DraggableContainer.d.ts +10 -0
  96. package/lib/LmEditTable/components/DraggableContainer.js +52 -0
  97. package/lib/LmEditTable/components/QuickOpetate.d.ts +12 -0
  98. package/lib/LmEditTable/components/QuickOpetate.js +96 -0
  99. package/lib/LmEditTable/components/bottomOpetateComponent.d.ts +13 -0
  100. package/lib/LmEditTable/components/bottomOpetateComponent.js +34 -0
  101. package/lib/LmEditTable/components/customRenderEmpty.d.ts +2 -0
  102. package/lib/LmEditTable/components/customRenderEmpty.js +32 -0
  103. package/lib/LmEditTable/components/index.d.ts +17 -0
  104. package/lib/LmEditTable/components/index.js +45 -0
  105. package/lib/LmEditTable/hooks/useForkRef.d.ts +2 -0
  106. package/lib/LmEditTable/hooks/useForkRef.js +29 -0
  107. package/lib/LmEditTable/rowSort/DndContainerRow.d.ts +10 -0
  108. package/lib/LmEditTable/rowSort/DndContainerRow.js +100 -0
  109. package/lib/LmEditTable/sortableItem.d.ts +3 -2
  110. package/lib/LmEditTable/sortableItem.js +19 -5
  111. package/lib/LmEditTable/sortableItemCol.js +37 -8
  112. package/lib/LmEditTable/style/index.css +109 -0
  113. package/lib/LmEditTable/style/variables.css +109 -0
  114. package/lib/LmEditTable/util.d.ts +10 -0
  115. package/lib/LmEditTable/util.js +167 -8
  116. package/lib/LmEditTable/virtual/VirtualRow.d.ts +7 -0
  117. package/lib/LmEditTable/virtual/VirtualRow.js +164 -0
  118. package/lib/LmEditTable/virtual/VirtualRow2.d.ts +7 -0
  119. package/lib/LmEditTable/virtual/VirtualRow2.js +78 -0
  120. package/lib/LmEditTable/virtual/VirtualTable.d.ts +3 -0
  121. package/lib/LmEditTable/virtual/VirtualTable.js +81 -0
  122. package/lib/LmEditTable/virtual/VirtualWrapper.d.ts +3 -0
  123. package/lib/LmEditTable/virtual/VirtualWrapper.js +73 -0
  124. package/lib/LmEditTable/virtual/context.d.ts +13 -0
  125. package/lib/LmEditTable/virtual/context.js +76 -0
  126. package/lib/LmEditTable/virtual/index.d.ts +4 -0
  127. package/lib/LmEditTable/virtual/index.js +31 -0
  128. package/lib/LmFilter/baseFilter/index.js +3 -2
  129. package/lib/LmFilter/filterFns/index.js +4 -2
  130. package/lib/LmTable/virTual/VirtualRow.d.ts +1 -1
  131. package/lib/LmTable/virTual/VirtualRow.js +81 -48
  132. package/lib/LmTable/virTual/VirtualTable.js +16 -8
  133. package/lib/LmTable/virTual/context.js +14 -2
  134. package/lib/LmUpload/body/UploadCore.js +1 -1
  135. package/lib/LmUpload/fns/index.js +1 -1
  136. package/lib/Radio/index.js +9 -1
  137. package/lib/Switch/index.js +9 -2
  138. package/lib/hooks/useEvent/index.js +1 -1
  139. package/lib/index.d.ts +1 -2
  140. package/lib/styles/variables.css +115 -2
  141. package/package.json +7 -9
@@ -1,5 +1,8 @@
1
- declare const DndContainer: ({ children, move }: {
1
+ import React from 'react';
2
+ declare const _default: React.MemoExoticComponent<({ children, move, options, rowKey }: {
2
3
  children: any;
3
4
  move: any;
4
- }) => JSX.Element;
5
- export default DndContainer;
5
+ options: any;
6
+ rowKey: any;
7
+ }) => JSX.Element>;
8
+ export default _default;
@@ -5,6 +5,7 @@ interface ILmEditTable extends TableProps<any> {
5
5
  isEdit?: boolean;
6
6
  isAdd?: boolean;
7
7
  rowKey?: string;
8
+ disabled?: boolean;
8
9
  rowHoverEdit?: boolean;
9
10
  isUseForm?: boolean;
10
11
  isHoverEdit?: boolean;
@@ -13,6 +14,8 @@ interface ILmEditTable extends TableProps<any> {
13
14
  sortOpen?: boolean;
14
15
  size?: TableProps<any>['size'];
15
16
  colSortOpen?: boolean;
17
+ indexCol?: boolean | Record<string, any>;
18
+ autoSizer?: boolean;
16
19
  filterChange?: (data: TableProps<any>['columns']) => void;
17
20
  recordCreatorProps?: {
18
21
  creatorButtonText?: string;
@@ -25,13 +28,18 @@ interface ILmEditTable extends TableProps<any> {
25
28
  rowSelection?: TableProps<any>['rowSelection'] & {
26
29
  selectedRows?: Record<string, any>;
27
30
  };
31
+ rowDisabled?: {
32
+ disabledRows?: Record<string, any>;
33
+ };
28
34
  }
29
35
  export interface CountdownHandle {
30
36
  setRow: (data: any) => void;
31
37
  getCheckboxRecords: () => any[];
32
38
  clearSelect: () => void;
33
39
  customSetCheckboxRecords: (data: any[]) => void;
34
- valid: () => void;
40
+ deleteRowData: (record: string | Record<string, any>) => void;
41
+ addRowData: (record: string | Record<string, any>, defaultValue?: Record<string, any> | Record<string, any>[], addInChild?: boolean | 'replace') => void;
42
+ verify: () => Promise<any>;
35
43
  }
36
44
  interface ILmColumns extends TableColumnType<any> {
37
45
  editable?: 'input' | 'number' | 'inputRange' | 'date' | 'select' | 'multiple' | 'checkbox' | 'radio' | 'switch' | 'upload' | 'operate' | 'lm_edit_opetate' | 'render';
@@ -43,12 +51,14 @@ interface ILmColumns extends TableColumnType<any> {
43
51
  componentProps?: Record<string, any>;
44
52
  relevanceCols?: boolean;
45
53
  }
46
- export declare type TLmEditTable = ILmEditTable & {
54
+ export declare type TLmEditTable = {
47
55
  onChange?: (data: any[]) => void;
48
56
  columns: ILmColumns[];
49
- };
50
- declare const _default: React.MemoExoticComponent<React.ForwardRefExoticComponent<ILmEditTable & {
57
+ virtual?: boolean;
58
+ } & ILmEditTable;
59
+ declare const _default: React.MemoExoticComponent<React.ForwardRefExoticComponent<{
51
60
  onChange?: (data: any[]) => void;
52
61
  columns: ILmColumns[];
53
- } & React.RefAttributes<CountdownHandle>>>;
62
+ virtual?: boolean;
63
+ } & ILmEditTable & React.RefAttributes<CountdownHandle>>>;
54
64
  export default _default;
@@ -0,0 +1,10 @@
1
+ declare const DraggableContainer: ({ keys, onSortEnd, virtual, rowKey, options, tableWidth, ...props }: {
2
+ [x: string]: any;
3
+ keys: any;
4
+ onSortEnd: any;
5
+ virtual: any;
6
+ rowKey: any;
7
+ options: any;
8
+ tableWidth: any;
9
+ }) => JSX.Element;
10
+ export default DraggableContainer;
@@ -0,0 +1,12 @@
1
+ import { FC } from 'react';
2
+ interface IOpetateProps {
3
+ record: Record<string, any>;
4
+ rowKey?: string;
5
+ handleAdd?: (row?: any, addInChildren?: boolean) => void;
6
+ handleDelete?: (rowKey?: string) => void;
7
+ options?: string[];
8
+ getLength?: number;
9
+ quickOpetateClearAll?: boolean;
10
+ }
11
+ declare const QuickOpetate: FC<IOpetateProps>;
12
+ export default QuickOpetate;
@@ -0,0 +1,13 @@
1
+ interface IBottomOpetateCompoentProps {
2
+ isShowAddAction?: boolean;
3
+ handleAdd?: () => void;
4
+ recordCreatorProps?: {
5
+ creatorButtonText?: string;
6
+ style?: Record<string, any>;
7
+ initData?: Record<string, any> | (() => Record<string, any>);
8
+ customAddClick?: () => void;
9
+ };
10
+ disabled?: boolean;
11
+ }
12
+ declare const BottomOpetateComponent: (props: IBottomOpetateCompoentProps) => JSX.Element;
13
+ export default BottomOpetateComponent;
@@ -0,0 +1,2 @@
1
+ declare const CustomizeRenderEmpty: () => JSX.Element;
2
+ export default CustomizeRenderEmpty;
@@ -0,0 +1,17 @@
1
+ import DraggableContainer from './DraggableContainer';
2
+ import BottomOpetateComponent from './bottomOpetateComponent';
3
+ import QuickOpetate from './QuickOpetate';
4
+ import CustomizeRenderEmpty from './customRenderEmpty';
5
+ export { DraggableContainer, BottomOpetateComponent, QuickOpetate, CustomizeRenderEmpty };
6
+ declare const _default: {
7
+ DraggableContainer: ({ keys, onSortEnd, virtual, rowKey, options, tableWidth, ...props }: {
8
+ [x: string]: any;
9
+ keys: any;
10
+ onSortEnd: any;
11
+ virtual: any;
12
+ rowKey: any;
13
+ options: any;
14
+ tableWidth: any;
15
+ }) => JSX.Element;
16
+ };
17
+ export default _default;
@@ -0,0 +1,2 @@
1
+ import { Ref } from 'react';
2
+ export default function useForkRef<InstanceA, InstanceB>(refA: Ref<InstanceA> | null | undefined, refB: Ref<InstanceB> | null | undefined): Ref<InstanceA & InstanceB> | null;
@@ -0,0 +1,10 @@
1
+ import React from 'react';
2
+ declare const _default: React.MemoExoticComponent<({ children, options, move, rowKey, items, tableWidth }: {
3
+ children: any;
4
+ options: any;
5
+ move: any;
6
+ rowKey: any;
7
+ items: any;
8
+ tableWidth: any;
9
+ }) => JSX.Element>;
10
+ export default _default;
@@ -1,2 +1,3 @@
1
- declare const SortableItem: (props: any) => JSX.Element;
2
- export default SortableItem;
1
+ import React from 'react';
2
+ declare const _default: React.MemoExoticComponent<(props: any) => JSX.Element>;
3
+ export default _default;
@@ -2,6 +2,16 @@ export declare function isObjEmpty(obj: Record<string, any>): boolean;
2
2
  export declare function deepDataSourcePreKeys(dataSource: any[], rowKey: string): any;
3
3
  export declare function isExpandRow(children: any): boolean;
4
4
  export declare function checkRowKeyByDataSource(dataSource: any, rowKey: any): any;
5
+ export declare function getExpandStatus(children: any): any;
6
+ export declare function checkMemoShouldUploadSpecialFun(prev: any, next: any): any;
7
+ export declare function checkExpandIconColumnIndex({ rowSelection, sortOpen, indexCol }: {
8
+ rowSelection: any;
9
+ sortOpen: any;
10
+ indexCol: any;
11
+ }): number;
12
+ export declare function checkDataSourceIsEmpty(config: any, dataSource: any, scrollInfo: any): any;
13
+ /** 根据传入的disabedRows, 得出最终需要disabed的rowKeys */
14
+ export declare function checkTableRowIsDisable(deepDataSource: any, disabledRows: any, rowKey: any): any[];
5
15
  declare const _default: {
6
16
  isObjEmpty: typeof isObjEmpty;
7
17
  };
@@ -0,0 +1,7 @@
1
+ import React from 'react';
2
+ interface rowProps {
3
+ children?: any;
4
+ pref?: any;
5
+ }
6
+ declare const VirtualRow: React.NamedExoticComponent<rowProps>;
7
+ export default VirtualRow;
@@ -0,0 +1,7 @@
1
+ import React from 'react';
2
+ interface rowProps {
3
+ children?: any;
4
+ pref?: any;
5
+ }
6
+ declare const VirtualRow: React.NamedExoticComponent<rowProps>;
7
+ export default VirtualRow;
@@ -0,0 +1,3 @@
1
+ import React, { PropsWithChildren } from 'react';
2
+ declare const VirtualTable: React.MemoExoticComponent<(tableProps: PropsWithChildren<any>) => JSX.Element>;
3
+ export default VirtualTable;
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ declare const VirtualWrapper: React.MemoExoticComponent<(wrapperProps: React.PropsWithChildren<any>) => JSX.Element>;
3
+ export default VirtualWrapper;
@@ -0,0 +1,13 @@
1
+ /// <reference types="react" />
2
+ declare const TableContext: import("react").Context<{
3
+ state: any;
4
+ dispatch: any;
5
+ instance: any;
6
+ }>;
7
+ declare const useStore: () => {
8
+ state: any;
9
+ dispatch: any;
10
+ instance: any;
11
+ };
12
+ declare const useRealive: () => [any, import("react").Dispatch<any>];
13
+ export { TableContext, useStore, useRealive };
@@ -0,0 +1,4 @@
1
+ import VirtualTable from './VirtualTable';
2
+ import VirtualWrapper from './VirtualWrapper';
3
+ import VirtualRow from './VirtualRow';
4
+ export { VirtualTable, VirtualWrapper, VirtualRow };
@@ -1,6 +1,6 @@
1
1
  import React from 'react';
2
2
  interface rowProps {
3
- children: any;
3
+ children?: any;
4
4
  }
5
5
  declare const VirtualRow: React.NamedExoticComponent<rowProps>;
6
6
  export default VirtualRow;
package/dist/index.d.ts CHANGED
@@ -51,10 +51,9 @@ export type { TooltipProps } from './Tooltip';
51
51
  export { default as Form } from './Form';
52
52
  export { default as Spin } from './Spin';
53
53
  export { default as LmEditTable } from './LmEditTable';
54
- export type { CountdownHandle, TLmEditTable } from './LmEditTable/EditTable';
54
+ export type { TLmEditTable, CountdownHandle } from './LmEditTable/EditTable';
55
55
  export { default as List } from './List';
56
56
  export { default as LMQuickMenu } from './QuickMenu';
57
- export type { IMenuData, IQuickMenuProps } from './QuickMenu';
58
57
  export { default as DatePicker } from './DatePicker';
59
58
  export type { DatePickerProps, MonthPickerProps, WeekPickerProps, RangePickerProps } from './DatePicker';
60
59
  export { default as Popover } from './Popover';