@pisell/materials 6.5.8 → 6.5.9

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 (217) hide show
  1. package/build/lowcode/assets-daily.json +11 -11
  2. package/build/lowcode/assets-dev.json +2 -2
  3. package/build/lowcode/assets-prod.json +11 -11
  4. package/build/lowcode/meta.js +1 -1
  5. package/es/components/appVersionControl/index.d.ts +0 -1
  6. package/es/components/cardPro/index.d.ts +3 -0
  7. package/es/components/dataSourceComponents/dataSourceTable/hooks/useDataSourceKey.d.ts +2 -3
  8. package/es/components/dataSourceComponents/dataSourceTable/hooks/useTableProps.d.ts +3 -3
  9. package/es/components/dataSourceComponents/fields/Input.Json/ReadPretty.d.ts +0 -1
  10. package/es/components/dataSourceComponents/fields/Input.Password/ReadPretty.d.ts +0 -1
  11. package/es/components/dataSourceComponents/fields/Upload/CameraPopover.d.ts +0 -1
  12. package/es/components/dataSourceComponents/fields/Upload/ReadPretty.d.ts +0 -1
  13. package/es/components/dataSourceComponents/fields/Upload/utils.d.ts +1 -1
  14. package/es/components/dataSourceComponents/fields/index.d.ts +6 -6
  15. package/es/components/dataSourceComponents/provider/variables/VariablesProvider.d.ts +4 -0
  16. package/es/components/date-picker/datePickerCpt.d.ts +0 -1
  17. package/es/components/drag-sort-tree/TreeItem/index.d.ts +18 -0
  18. package/es/components/lowCodePage/index.d.ts +0 -1
  19. package/es/components/page/index.d.ts +8 -0
  20. package/es/components/pisell-config-provider/index.d.ts +13 -0
  21. package/es/components/pisellAdjustPrice/index.d.ts +4 -0
  22. package/es/components/pisellCheckboxGroup/index.d.ts +40 -0
  23. package/es/components/pisellInformationEntry/Scan/index.d.ts +0 -1
  24. package/es/components/pisellInput/components/Copy/index.d.ts +0 -1
  25. package/es/components/pisellInput/index.d.ts +0 -1
  26. package/es/components/pisellLoading/index.d.ts +0 -1
  27. package/es/components/pisellModal/components/IpadModal/index.d.ts +0 -1
  28. package/es/components/pisellModal/components/MobileModal/index.d.ts +0 -1
  29. package/es/components/pisellModal/components/index.d.ts +0 -1
  30. package/es/components/pisellQRScanner/index.d.ts +24 -0
  31. package/es/components/pisellText/components/Amount/index.d.ts +20 -0
  32. package/es/components/pisellToast/index.d.ts +17 -0
  33. package/es/components/productCard/cartSkuCard/components/AmountFooter/index.d.ts +3 -0
  34. package/es/components/productCard/cartSkuCard/components/MultiDay/index.d.ts +3 -0
  35. package/es/components/productCard/cartSkuCard/components/Note/index.d.ts +3 -0
  36. package/es/components/productCard/cartSkuCard/components/basicInfo/index.d.ts +27 -0
  37. package/es/components/productCard/cartSkuCard/components/discountReason/index.d.ts +2 -0
  38. package/es/components/productCard/cartSkuCard/components/holders/index.d.ts +3 -0
  39. package/es/components/productCard/cartSkuCard/components/packages/index.d.ts +10 -0
  40. package/es/components/productCard/cartSkuCard/components/packages/utils.d.ts +20 -0
  41. package/es/components/productCard/cartSkuCard/components/resources/index.d.ts +3 -0
  42. package/es/components/productCard/cartSkuCard/components/sales/index.d.ts +12 -0
  43. package/es/components/productCard/cartSkuCard/components/specs/index.d.ts +3 -0
  44. package/es/components/productCard/cartSkuCard/components/timeRange/index.d.ts +6 -0
  45. package/es/components/productCard/cartSkuCard/index.d.ts +10 -0
  46. package/es/components/productCard/components/AmountFooter/index.d.ts +0 -1
  47. package/es/components/productCard/components/Header/EditButton/index.d.ts +0 -1
  48. package/es/components/productCard/components/Header/index.d.ts +3 -0
  49. package/es/components/productCard/components/MultiDay/index.d.ts +0 -1
  50. package/es/components/productCard/components/Note/index.d.ts +0 -1
  51. package/es/components/productCard/components/Packages/components/collapsibleList/utils.d.ts +0 -1
  52. package/es/components/productCard/components/Packages/components/options/index.d.ts +0 -1
  53. package/es/components/productCard/components/Packages/index.d.ts +0 -1
  54. package/es/components/productCard/components/Packages/utils.d.ts +1 -1
  55. package/es/components/productCard/components/Sales/index.d.ts +3 -0
  56. package/es/components/productCard/components/Time/components/SelectHolder/index.d.ts +0 -1
  57. package/es/components/productCard/components/Time/components/SelectHolderModal/index.d.ts +13 -0
  58. package/es/components/productCard/components/Time/components/SelectHolderMultiple/index.d.ts +0 -1
  59. package/es/components/productCard/components/Time/components/SelectResource/index.d.ts +0 -1
  60. package/es/components/productCard/components/Time/index.d.ts +0 -1
  61. package/es/components/qrcode/index.d.ts +0 -1
  62. package/es/components/select-time/index.d.ts +0 -1
  63. package/es/components/table/Actions/component/ColumnsSetting/index.d.ts +0 -1
  64. package/es/components/table/Actions/component/Group/PopoverContent.d.ts +0 -1
  65. package/es/components/table/Gallery/components/GalleryItem/components/RenderFields/index.d.ts +0 -1
  66. package/es/components/table/Gallery/components/VirtualGrid/useGapSize.d.ts +2 -2
  67. package/es/components/table/Table/SelectField/index.d.ts +1 -0
  68. package/es/components/table/Table/fields/date/Show/index.d.ts +0 -1
  69. package/es/components/table/Table/fields/date/index.d.ts +0 -1
  70. package/es/components/table/Table/fields/image/Show/index.d.ts +0 -1
  71. package/es/components/table/Table/fields/image/index.d.ts +0 -1
  72. package/es/components/table/Table/fields/link/Show/index.d.ts +0 -1
  73. package/es/components/table/Table/fields/link/index.d.ts +0 -1
  74. package/es/components/table/Table/fields/number/Show/index.d.ts +0 -1
  75. package/es/components/table/Table/fields/number/index.d.ts +0 -1
  76. package/es/components/table/Table/fields/numberRange/Show/index.d.ts +0 -1
  77. package/es/components/table/Table/fields/numberRange/index.d.ts +0 -1
  78. package/es/components/table/Table/fields/oldRangePicker/index.d.ts +0 -1
  79. package/es/components/table/Table/fields/pSwitch/Show/index.d.ts +0 -1
  80. package/es/components/table/Table/fields/pSwitch/index.d.ts +0 -1
  81. package/es/components/table/Table/fields/rangePicker/index.d.ts +0 -1
  82. package/es/components/table/Table/fields/search/Show/index.d.ts +0 -1
  83. package/es/components/table/Table/fields/search/index.d.ts +0 -1
  84. package/es/components/table/Table/fields/select/filterUtil/index.d.ts +1 -1
  85. package/es/components/table/Table/fields/select/index.d.ts +0 -1
  86. package/es/components/table/Table/fields/treeSelect/filterUtil/index.d.ts +1 -1
  87. package/es/components/table/Table/fields/treeSelect/index.d.ts +0 -1
  88. package/es/components/table/Table/utils.d.ts +161 -0
  89. package/es/components/versionSelect/index.d.ts +0 -1
  90. package/es/components/virtual-keyboard/Amount/index.d.ts +5 -0
  91. package/es/components/virtual-keyboard/Amount/types.d.ts +44 -0
  92. package/es/components/virtual-keyboard/BaseNumberKeyboard/index.d.ts +25 -0
  93. package/es/components/virtual-keyboard/Number/index.d.ts +5 -0
  94. package/es/components/virtual-keyboard/index.d.ts +25 -0
  95. package/es/utils/index.d.ts +1 -1
  96. package/es/utils/platform.d.ts +1 -1
  97. package/lib/components/appVersionControl/index.d.ts +0 -1
  98. package/lib/components/cardPro/index.d.ts +3 -0
  99. package/lib/components/dataSourceComponents/dataSourceTable/hooks/useDataSourceKey.d.ts +2 -3
  100. package/lib/components/dataSourceComponents/dataSourceTable/hooks/useTableProps.d.ts +3 -3
  101. package/lib/components/dataSourceComponents/fields/Input.Json/ReadPretty.d.ts +0 -1
  102. package/lib/components/dataSourceComponents/fields/Input.Password/ReadPretty.d.ts +0 -1
  103. package/lib/components/dataSourceComponents/fields/Upload/CameraPopover.d.ts +0 -1
  104. package/lib/components/dataSourceComponents/fields/Upload/ReadPretty.d.ts +0 -1
  105. package/lib/components/dataSourceComponents/fields/Upload/utils.d.ts +1 -1
  106. package/lib/components/dataSourceComponents/fields/index.d.ts +6 -6
  107. package/lib/components/dataSourceComponents/provider/variables/VariablesProvider.d.ts +4 -0
  108. package/lib/components/date-picker/datePickerCpt.d.ts +0 -1
  109. package/lib/components/drag-sort-tree/TreeItem/index.d.ts +18 -0
  110. package/lib/components/lowCodePage/index.d.ts +0 -1
  111. package/lib/components/page/index.d.ts +8 -0
  112. package/lib/components/pisell-config-provider/index.d.ts +13 -0
  113. package/lib/components/pisellAdjustPrice/index.d.ts +4 -0
  114. package/lib/components/pisellCheckboxGroup/index.d.ts +40 -0
  115. package/lib/components/pisellInformationEntry/Scan/index.d.ts +0 -1
  116. package/lib/components/pisellInput/components/Copy/index.d.ts +0 -1
  117. package/lib/components/pisellInput/index.d.ts +0 -1
  118. package/lib/components/pisellLoading/index.d.ts +0 -1
  119. package/lib/components/pisellModal/components/IpadModal/index.d.ts +0 -1
  120. package/lib/components/pisellModal/components/MobileModal/index.d.ts +0 -1
  121. package/lib/components/pisellModal/components/index.d.ts +0 -1
  122. package/lib/components/pisellQRScanner/index.d.ts +24 -0
  123. package/lib/components/pisellText/components/Amount/index.d.ts +20 -0
  124. package/lib/components/pisellToast/index.d.ts +17 -0
  125. package/lib/components/productCard/cartSkuCard/components/AmountFooter/index.d.ts +3 -0
  126. package/lib/components/productCard/cartSkuCard/components/MultiDay/index.d.ts +3 -0
  127. package/lib/components/productCard/cartSkuCard/components/Note/index.d.ts +3 -0
  128. package/lib/components/productCard/cartSkuCard/components/basicInfo/index.d.ts +27 -0
  129. package/lib/components/productCard/cartSkuCard/components/discountReason/index.d.ts +2 -0
  130. package/lib/components/productCard/cartSkuCard/components/holders/index.d.ts +3 -0
  131. package/lib/components/productCard/cartSkuCard/components/packages/index.d.ts +10 -0
  132. package/lib/components/productCard/cartSkuCard/components/packages/utils.d.ts +20 -0
  133. package/lib/components/productCard/cartSkuCard/components/resources/index.d.ts +3 -0
  134. package/lib/components/productCard/cartSkuCard/components/sales/index.d.ts +12 -0
  135. package/lib/components/productCard/cartSkuCard/components/specs/index.d.ts +3 -0
  136. package/lib/components/productCard/cartSkuCard/components/timeRange/index.d.ts +6 -0
  137. package/lib/components/productCard/cartSkuCard/index.d.ts +10 -0
  138. package/lib/components/productCard/components/AmountFooter/index.d.ts +0 -1
  139. package/lib/components/productCard/components/Header/EditButton/index.d.ts +0 -1
  140. package/lib/components/productCard/components/Header/index.d.ts +3 -0
  141. package/lib/components/productCard/components/MultiDay/index.d.ts +0 -1
  142. package/lib/components/productCard/components/Note/index.d.ts +0 -1
  143. package/lib/components/productCard/components/Packages/components/collapsibleList/utils.d.ts +0 -1
  144. package/lib/components/productCard/components/Packages/components/options/index.d.ts +0 -1
  145. package/lib/components/productCard/components/Packages/index.d.ts +0 -1
  146. package/lib/components/productCard/components/Packages/utils.d.ts +1 -1
  147. package/lib/components/productCard/components/Sales/index.d.ts +3 -0
  148. package/lib/components/productCard/components/Time/components/SelectHolder/index.d.ts +0 -1
  149. package/lib/components/productCard/components/Time/components/SelectHolderModal/index.d.ts +13 -0
  150. package/lib/components/productCard/components/Time/components/SelectHolderMultiple/index.d.ts +0 -1
  151. package/lib/components/productCard/components/Time/components/SelectResource/index.d.ts +0 -1
  152. package/lib/components/productCard/components/Time/index.d.ts +0 -1
  153. package/lib/components/qrcode/index.d.ts +0 -1
  154. package/lib/components/select-time/index.d.ts +0 -1
  155. package/lib/components/table/Actions/component/ColumnsSetting/index.d.ts +0 -1
  156. package/lib/components/table/Actions/component/Group/PopoverContent.d.ts +0 -1
  157. package/lib/components/table/Gallery/components/GalleryItem/components/RenderFields/index.d.ts +0 -1
  158. package/lib/components/table/Gallery/components/VirtualGrid/useGapSize.d.ts +2 -2
  159. package/lib/components/table/Table/SelectField/index.d.ts +1 -0
  160. package/lib/components/table/Table/fields/date/Show/index.d.ts +0 -1
  161. package/lib/components/table/Table/fields/date/index.d.ts +0 -1
  162. package/lib/components/table/Table/fields/image/Show/index.d.ts +0 -1
  163. package/lib/components/table/Table/fields/image/index.d.ts +0 -1
  164. package/lib/components/table/Table/fields/link/Show/index.d.ts +0 -1
  165. package/lib/components/table/Table/fields/link/index.d.ts +0 -1
  166. package/lib/components/table/Table/fields/number/Show/index.d.ts +0 -1
  167. package/lib/components/table/Table/fields/number/index.d.ts +0 -1
  168. package/lib/components/table/Table/fields/numberRange/Show/index.d.ts +0 -1
  169. package/lib/components/table/Table/fields/numberRange/index.d.ts +0 -1
  170. package/lib/components/table/Table/fields/oldRangePicker/index.d.ts +0 -1
  171. package/lib/components/table/Table/fields/pSwitch/Show/index.d.ts +0 -1
  172. package/lib/components/table/Table/fields/pSwitch/index.d.ts +0 -1
  173. package/lib/components/table/Table/fields/rangePicker/index.d.ts +0 -1
  174. package/lib/components/table/Table/fields/search/Show/index.d.ts +0 -1
  175. package/lib/components/table/Table/fields/search/index.d.ts +0 -1
  176. package/lib/components/table/Table/fields/select/filterUtil/index.d.ts +1 -1
  177. package/lib/components/table/Table/fields/select/index.d.ts +0 -1
  178. package/lib/components/table/Table/fields/treeSelect/filterUtil/index.d.ts +1 -1
  179. package/lib/components/table/Table/fields/treeSelect/index.d.ts +0 -1
  180. package/lib/components/table/Table/utils.d.ts +161 -0
  181. package/lib/components/versionSelect/index.d.ts +0 -1
  182. package/lib/components/virtual-keyboard/Amount/index.d.ts +5 -0
  183. package/lib/components/virtual-keyboard/Amount/types.d.ts +44 -0
  184. package/lib/components/virtual-keyboard/BaseNumberKeyboard/index.d.ts +25 -0
  185. package/lib/components/virtual-keyboard/Number/index.d.ts +5 -0
  186. package/lib/components/virtual-keyboard/index.d.ts +25 -0
  187. package/lib/utils/index.d.ts +1 -1
  188. package/lib/utils/platform.d.ts +1 -1
  189. package/package.json +1 -1
  190. package/es/components/dataSourceComponents/dataSourceTable/type.d.ts +0 -84
  191. package/es/components/dataSourceComponents/fields/Input.Mobile/serve.d.ts +0 -24
  192. package/es/components/dataSourceComponents/fields/Input.Phone/serve.d.ts +0 -24
  193. package/es/components/dataSourceComponents/hooks/usePlatform.d.ts +0 -3
  194. package/es/components/drag-sort-tree/index.d.ts +0 -5
  195. package/es/components/filter/types.d.ts +0 -45
  196. package/es/components/login-and-register/index.d.ts +0 -82
  197. package/es/components/pisellEmpty/index.d.ts +0 -19
  198. package/es/components/productCard/components/Header/DeleteButton/index.d.ts +0 -4
  199. package/es/components/select/index.d.ts +0 -9
  200. package/es/components/table/Actions/component/ExportImport/components/ExportTable/function.d.ts +0 -7
  201. package/es/components/table/Actions/index.d.ts +0 -17
  202. package/es/components/table/serve.d.ts +0 -13
  203. package/es/components/table/types.d.ts +0 -268
  204. package/lib/components/dataSourceComponents/dataSourceTable/type.d.ts +0 -84
  205. package/lib/components/dataSourceComponents/fields/Input.Mobile/serve.d.ts +0 -24
  206. package/lib/components/dataSourceComponents/fields/Input.Phone/serve.d.ts +0 -24
  207. package/lib/components/dataSourceComponents/hooks/usePlatform.d.ts +0 -3
  208. package/lib/components/drag-sort-tree/index.d.ts +0 -5
  209. package/lib/components/filter/types.d.ts +0 -45
  210. package/lib/components/login-and-register/index.d.ts +0 -82
  211. package/lib/components/pisellEmpty/index.d.ts +0 -19
  212. package/lib/components/productCard/components/Header/DeleteButton/index.d.ts +0 -4
  213. package/lib/components/select/index.d.ts +0 -9
  214. package/lib/components/table/Actions/component/ExportImport/components/ExportTable/function.d.ts +0 -7
  215. package/lib/components/table/Actions/index.d.ts +0 -17
  216. package/lib/components/table/serve.d.ts +0 -13
  217. package/lib/components/table/types.d.ts +0 -268
@@ -0,0 +1,161 @@
1
+ import { GroupValue } from "../Actions/component/Group/PopoverContent";
2
+ import { FilterItemProps, FilterType } from "../../filter/types";
3
+ import { ColumnSettingType, DataSourceGroupType, GallerySettingValueType, ModeType, SortType } from "../types";
4
+ export declare const getHash: (obj: any) => any;
5
+ export declare const calcFilterSort: ({ dataSource, filter, sort, columns }: any) => any;
6
+ /**
7
+ * 合并列设置
8
+ * @param defaultColumns 默认列设置
9
+ * @param tableId 表ID
10
+ * @returns 合并后的列设置
11
+ */
12
+ export declare const mergeColumnSetting: ({ columns, tableId, currentViewMode, }: {
13
+ columns: Record<string, any>[];
14
+ tableId?: string | undefined;
15
+ currentViewMode: ModeType;
16
+ }) => {
17
+ isShow: boolean;
18
+ }[] | ({
19
+ width: any;
20
+ isShow: any;
21
+ sortIndex: number;
22
+ } | {
23
+ isShow: boolean;
24
+ sortIndex: number;
25
+ })[];
26
+ /**
27
+ * 对数据源进行排序
28
+ * @param dataSource 数据源数组
29
+ * @param sortObj 排序对象,包含排序的键、值和类型
30
+ * @returns 排序后的数据源数组
31
+ */
32
+ export declare const sortDataSource: (dataSource: Record<string, any>[], sortObj: {
33
+ sortKey: string;
34
+ sortValue: "asc" | "desc";
35
+ sortType: "date" | "string" | "number";
36
+ }) => Record<string, any>[];
37
+ /**
38
+ * 根据行键获取 ID
39
+ * @param item 记录对象
40
+ * @param rowKey 行键,可以是字符串或函数
41
+ * @returns 返回 ID
42
+ */
43
+ export declare const getIdByRowKey: (item: Record<string, any>, rowKey: string | ((params: any) => string)) => any;
44
+ /**
45
+ * 根据分组条件对数据源进行分组
46
+ * @param dataSource 数据源
47
+ * @param group 分组条件
48
+ * @param rowKey 行键生成函数或字符串
49
+ * @returns 返回分组后的数据源
50
+ */
51
+ export declare const groupDataSource: (dataSource: Record<string, any>[], group: GroupValue, rowKey: string | ((params: any) => string)) => Record<string, any>[];
52
+ declare type ViewSetting = {
53
+ order_by: string;
54
+ group_by: GroupValue;
55
+ column_setting: Record<string, any>[];
56
+ gallery_setting: GallerySettingValueType;
57
+ filters: any;
58
+ filter_setting: {
59
+ quickFilter: FilterItemProps[];
60
+ otherFilter: FilterItemProps[];
61
+ };
62
+ };
63
+ /**
64
+ * 本地存储的表格设置对象
65
+ */
66
+ declare type TableSettingObjType = {
67
+ view_mode: ModeType;
68
+ currentSettingHash: string;
69
+ } & {
70
+ [K in ModeType]: ViewSetting;
71
+ };
72
+ /**
73
+ * 将表格设置保存到本地存储
74
+ * @param tableId 表格id
75
+ * @param tableSettingObj 表格设置对象
76
+ */
77
+ export declare const setTableSettingToLocalStorage: ({ tableId, tableSettingObj, currentViewMode, currentSettingHash, }: {
78
+ tableId: string;
79
+ tableSettingObj: Partial<ViewSetting & {
80
+ view_mode: ModeType;
81
+ }>;
82
+ currentViewMode: ModeType;
83
+ currentSettingHash: string;
84
+ }) => void;
85
+ export declare const clearTableSettingToLocalStorage: (tableId?: string) => void;
86
+ /**
87
+ * 从本地存储中获取表格设置, 全部配置
88
+ * @param tableId 表格ID
89
+ * @returns 表格设置对象
90
+ */
91
+ export declare const getTableSettingFromLocalStorage: (tableId?: string) => Partial<TableSettingObjType>;
92
+ /**
93
+ * 从LocalStorage读取表当前视图模式
94
+ * @param tableId
95
+ */
96
+ export declare const getCurrentViewModeFromLocalStorage: (tableId?: string) => ModeType | undefined;
97
+ /**
98
+ * 根据视图模式获取配置
99
+ * @param tableId
100
+ * @param currentViewMode
101
+ */
102
+ export declare const getTableSettingByCurrentViewMode: (tableId: string, currentViewMode: ModeType) => ViewSetting | undefined;
103
+ /**
104
+ * 将表单值保存到本地存储中
105
+ * @param tableId 表单ID
106
+ * @param allValues 表单所有值
107
+ * @param keys 存储的键名
108
+ */
109
+ export declare const setFormValuesToLocalStorage: ({ tableId, allValues, keys, currentViewMode, currentSettingHash, }: {
110
+ tableId?: string | undefined;
111
+ allValues?: Record<string, any> | undefined;
112
+ keys?: string[] | undefined;
113
+ currentViewMode: ModeType;
114
+ currentSettingHash: string;
115
+ }) => void;
116
+ /**
117
+ * 合并筛选设置
118
+ * @param list 列表数据
119
+ * @param quickFilterMaxLength 快速筛选最大长度
120
+ * @param tableId 表ID
121
+ * @returns 返回合并后的筛选设置
122
+ */
123
+ export declare const mergeFilterSetting: ({ list, quickFilterMaxLength, tableId, sortButtonShow, currentViewMode, }: {
124
+ list: FilterItemProps[];
125
+ quickFilterMaxLength: number;
126
+ tableId?: string | undefined;
127
+ sortButtonShow: boolean;
128
+ currentViewMode: ModeType;
129
+ }) => {
130
+ quickFilter: FilterItemProps[];
131
+ otherFilter: FilterItemProps[];
132
+ notSortFilter: FilterItemProps[];
133
+ };
134
+ /**
135
+ * 过滤数据源
136
+ * @param dataSource 数据源
137
+ * @param filters 过滤条件
138
+ * @param filterLocalArr 本地过滤项
139
+ * @returns 过滤后的数据源
140
+ */
141
+ export declare const filterDataSource: (dataSource: Record<string, any>[], filters: Record<string, any>, filterLocalArr: FilterItemProps[]) => Record<string, any>[];
142
+ /**
143
+ * 根据模式获取设置键数组
144
+ * @param filter 筛选器
145
+ * @param columnSetting 列设置
146
+ * @param dataSourceGroup 数据源分组
147
+ * @param sort 排序
148
+ * @param mode 模式,可选值为 "localStorage" 或 "remote"
149
+ * @returns 返回设置键数组
150
+ */
151
+ export declare const getSettingKeyArrByMode: ({ filter, columnSetting, dataSourceGroup, sort, mode, currentViewMode, }: {
152
+ filter?: FilterType | undefined;
153
+ columnSetting?: ColumnSettingType | undefined;
154
+ dataSourceGroup?: DataSourceGroupType | undefined;
155
+ sort?: SortType | undefined;
156
+ mode: "" | "localStorage" | "remote";
157
+ currentViewMode: ModeType;
158
+ }) => ("filters" | "column_setting" | "gallery_setting" | "order_by" | "group_by" | "filter_setting" | "view_mode")[];
159
+ export declare const omit: (obj: Record<string, any>, keys: string[]) => Record<string, any>;
160
+ export declare const stringify: (obj: Record<string, any>) => string;
161
+ export {};
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { SelectProps } from 'antd';
3
2
  import './index.less';
4
3
  export interface Version {
@@ -0,0 +1,5 @@
1
+ import { AmountProps, RightItemsStyleProps } from './types';
2
+ import './index.less';
3
+ export type { AmountProps, RightItemsStyleProps };
4
+ declare const Amount: (props: AmountProps) => JSX.Element;
5
+ export default Amount;
@@ -0,0 +1,44 @@
1
+ /// <reference types="react" />
2
+ import { BaseNumberKeyboardProps } from '../BaseNumberKeyboard';
3
+ export interface RightItemsStyleProps {
4
+ buttonBackgroundColor?: string;
5
+ textColor?: string;
6
+ resetButtonBackgroundColor?: string;
7
+ resetButtonTextColor?: string;
8
+ isDoneButtonFollowTheme?: boolean;
9
+ doneButtonBackgroundColor?: string;
10
+ doneButtonTextColor?: string;
11
+ }
12
+ export interface AmountProps {
13
+ max?: number;
14
+ min?: number;
15
+ doneText?: string;
16
+ resetText?: string;
17
+ defaultValue?: string | number;
18
+ placeholder?: string;
19
+ amountProps?: {
20
+ showCurrencySymbol: boolean;
21
+ useThousandsSeparator: boolean;
22
+ };
23
+ presets?: BaseNumberKeyboardProps['presets'];
24
+ value?: string | number;
25
+ onChange?: (val: string | number) => void;
26
+ onEnter?: (val: string | number) => void;
27
+ defaultSelect?: boolean;
28
+ inputFormat?: (_v: string) => React.ReactNode | null;
29
+ rightItemsStyle?: RightItemsStyleProps;
30
+ selectType?: 'light' | 'dark';
31
+ backgroundColor?: string;
32
+ containerBackgroundColor?: string;
33
+ buttonBackgroundColor?: string;
34
+ textColor?: string;
35
+ resetButtonBackgroundColor?: string;
36
+ resetButtonTextColor?: string;
37
+ isDoneButtonFollowTheme?: boolean;
38
+ doneButtonBackgroundColor?: string;
39
+ doneButtonTextColor?: string;
40
+ keyboardBackgroundColor?: string;
41
+ keyboardButtonBackgroundColor?: string;
42
+ keyboardButtonTextColor?: string;
43
+ keyboardButtonHoverColor?: string;
44
+ }
@@ -0,0 +1,25 @@
1
+ import React from 'react';
2
+ import { PresetsProps } from './Presets';
3
+ import { KeyboardProps } from '../Keyboard';
4
+ import { RightItemsStyleProps } from '../Amount';
5
+ import './index.less';
6
+ export interface BaseNumberKeyboardProps {
7
+ placeholder?: string;
8
+ format?: (val: string) => React.ReactNode;
9
+ defaultValue?: string | number;
10
+ doneText?: string;
11
+ resetText?: string;
12
+ onChange?: (val: string) => void;
13
+ onEnter?: (val: string) => void;
14
+ value?: string | number;
15
+ max?: number;
16
+ min?: number;
17
+ presets?: PresetsProps['presets'];
18
+ defaultSelect?: boolean;
19
+ rightItemsStyle?: RightItemsStyleProps;
20
+ customDisplay?: React.ReactNode | ((props: any) => React.ReactNode);
21
+ keyboardProps?: KeyboardProps;
22
+ style?: React.CSSProperties;
23
+ }
24
+ declare const BaseNumberKeyboard: (props: BaseNumberKeyboardProps) => JSX.Element;
25
+ export default BaseNumberKeyboard;
@@ -0,0 +1,5 @@
1
+ import { NumberProps } from './types';
2
+ import './index.less';
3
+ export type { NumberProps };
4
+ declare const Number: (props: NumberProps) => JSX.Element;
5
+ export default Number;
@@ -0,0 +1,25 @@
1
+ import React from "react";
2
+ import { KeyboardProps } from "./Keyboard";
3
+ import { VirtualKeyInputProps } from "./VirtualKeyInput";
4
+ import "./index.less";
5
+ interface VirtualKeyboardProps extends React.HTMLAttributes<HTMLDivElement> {
6
+ keyboardProps?: KeyboardProps;
7
+ virtualKeyInputProps?: VirtualKeyInputProps;
8
+ rightPanel?: React.ReactNode;
9
+ style?: React.CSSProperties;
10
+ onChange?: (value?: any) => void;
11
+ value?: string;
12
+ selectType?: 'light' | 'dark';
13
+ backgroundColor?: string;
14
+ containerBackgroundColor?: string;
15
+ buttonBackgroundColor?: string;
16
+ textColor?: string;
17
+ keyboardBackgroundColor?: string;
18
+ keyboardButtonBackgroundColor?: string;
19
+ keyboardButtonTextColor?: string;
20
+ keyboardButtonHoverColor?: string;
21
+ primaryButtonBackgroundColor?: string;
22
+ primaryButtonTextColor?: string;
23
+ }
24
+ declare const VirtualKeyboard: (props: VirtualKeyboardProps) => JSX.Element;
25
+ export default VirtualKeyboard;
@@ -1,4 +1,4 @@
1
1
  export declare const isBrowser: boolean;
2
- export declare const getCssNumber: (val: string | number) => string;
2
+ export declare const getCssNumber: (val: string | number) => string | number;
3
3
  export declare function uuid(): string;
4
4
  export * from './mergeWith';
@@ -1 +1 @@
1
- export declare const isMobile: () => boolean;
1
+ export declare const isMobile: () => any;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pisell/materials",
3
- "version": "6.5.8",
3
+ "version": "6.5.9",
4
4
  "scripts": {
5
5
  "dev": "father dev",
6
6
  "build": "father build",
@@ -1,84 +0,0 @@
1
- /// <reference types="react" />
2
- import { ColumnType } from 'antd/es/table';
3
- import { LocalSettingsType } from '../../table/types';
4
- import { DataSourceType } from '../provider/dataSource/DataSourceContext';
5
- export declare type OperationItem = {
6
- label?: string;
7
- openMode: 'modal' | 'drawer' | 'custom';
8
- openContentSize: 'small' | 'middle' | 'large';
9
- openTitle: string;
10
- actionType: 'detail' | 'edit' | 'delete' | 'custom';
11
- key: string;
12
- buttonProps?: any;
13
- onClick?: (record: any) => void;
14
- afterClose?: () => void;
15
- };
16
- export interface DataSourceTableProps {
17
- __id?: string;
18
- currentComponentId?: string;
19
- currentSettingKey?: string;
20
- title?: string | React.ReactNode | (() => React.ReactNode);
21
- subTitle?: string | React.ReactNode | (() => React.ReactNode);
22
- titleButtons?: {
23
- show: boolean;
24
- maxCount: number;
25
- items: OperationItem[];
26
- };
27
- tableButtons?: {
28
- show: boolean;
29
- maxCount: number;
30
- items: OperationItem[];
31
- };
32
- buttons?: any[];
33
- operation?: {
34
- show: boolean;
35
- title: string;
36
- width: number;
37
- align: 'left' | 'center' | 'right';
38
- fixed: 'left' | 'right' | false;
39
- type: 'link' | 'button';
40
- items: OperationItem[];
41
- };
42
- operationContent?: {
43
- [key: string]: React.ReactNode;
44
- };
45
- dataSource: DataSourceType;
46
- columns: ColumnType<any>[];
47
- filter: any;
48
- search?: {
49
- show: boolean;
50
- placeholder: string;
51
- };
52
- __designMode: string;
53
- componentId: string;
54
- clickToDetail?: {
55
- show: boolean;
56
- useCustomAction: boolean;
57
- actionType: string;
58
- openMode: 'modal' | 'drawer';
59
- openContentSize: 'small' | 'middle' | 'large';
60
- openTitle: string;
61
- key: string;
62
- };
63
- onRow?: any;
64
- filterBy?: Record<string, any>;
65
- sortBy: string;
66
- tabs?: {
67
- show: boolean;
68
- type: string;
69
- items: {
70
- name: string;
71
- filterBy: Record<string, any>;
72
- sortBy: string;
73
- }[];
74
- };
75
- onValuesChange?: (changedValues: any, values: any) => void;
76
- extraParams?: {
77
- list?: Record<string, any>;
78
- get?: Record<string, any>;
79
- update?: Record<string, any>;
80
- create?: Record<string, any>;
81
- destroy?: Record<string, any>;
82
- };
83
- localSettings?: LocalSettingsType;
84
- }
@@ -1,24 +0,0 @@
1
- /**
2
- * 获取nocobase数据列表
3
- */
4
- export declare const getCountryDataList: () => Promise<any>;
5
- export interface Country {
6
- id: number;
7
- name: {
8
- en: string;
9
- "zh-CN": string;
10
- "zh-HK": string;
11
- original: string;
12
- };
13
- code: string;
14
- calling_code: string;
15
- currency_code: string;
16
- sort: number;
17
- status: string;
18
- created_at: string;
19
- updated_at: string;
20
- prefix: string;
21
- }
22
- export declare const useCountries: () => {
23
- data: Country[];
24
- };
@@ -1,24 +0,0 @@
1
- /**
2
- * 获取nocobase数据列表
3
- */
4
- export declare const getCountryDataList: () => Promise<any>;
5
- export interface Country {
6
- id: number;
7
- name: {
8
- en: string;
9
- "zh-CN": string;
10
- "zh-HK": string;
11
- original: string;
12
- };
13
- code: string;
14
- calling_code: string;
15
- currency_code: string;
16
- sort: number;
17
- status: string;
18
- created_at: string;
19
- updated_at: string;
20
- prefix: string;
21
- }
22
- export declare const useCountries: () => {
23
- data: Country[];
24
- };
@@ -1,3 +0,0 @@
1
- declare const usePlatform: () => any;
2
- declare const useIsShop: () => boolean;
3
- export { usePlatform, useIsShop };
@@ -1,5 +0,0 @@
1
- /// <reference types="react" />
2
- import './index.less';
3
- import { SortType } from './types';
4
- declare const DragSortTree: (props: SortType) => JSX.Element;
5
- export default DragSortTree;
@@ -1,45 +0,0 @@
1
- import { ModeType } from "../table/types";
2
- /**
3
- * 筛选总配置
4
- */
5
- export declare type FilterType = {
6
- /** 筛选是否展示 */
7
- show: boolean;
8
- /** 筛选项排序按钮是否展示 */
9
- sortButtonShow: boolean;
10
- /** 筛选列表 */
11
- list: FilterItemProps[];
12
- items?: string[];
13
- __items: string[];
14
- /** 快速筛选最大长度 */
15
- quickFilterMaxLength: number;
16
- /** 配置存储模式 */
17
- storageMode: "" | "localStorage";
18
- };
19
- /**
20
- * 筛选列表项配置
21
- */
22
- export declare type FilterItemProps = {
23
- type: "single" | "input" | "datePicker" | "rangePicker" | "search";
24
- name?: string | string[];
25
- key: string;
26
- props: object;
27
- label?: string;
28
- sort?: boolean;
29
- localFilter?: boolean;
30
- other: Record<string, any>;
31
- isCustom?: boolean;
32
- columnKey?: string;
33
- isHidden?: boolean;
34
- };
35
- /**
36
- * 筛选组件属性
37
- */
38
- export interface FilterProps {
39
- filter: FilterType;
40
- isRenderFormContent: boolean;
41
- onValuesChange?: () => void;
42
- tableId?: string;
43
- viewMode?: ModeType;
44
- isMobile?: boolean;
45
- }
@@ -1,82 +0,0 @@
1
- import React from 'react';
2
- import './index.less';
3
- /**
4
- * loginAndRegister组件的属性接口
5
- */
6
- export interface loginAndRegisterProps {
7
- /** Logo相关配置 */
8
- showLogo?: boolean;
9
- logo?: string;
10
- logoPosition?: 'left' | 'center' | 'right';
11
- logoSize?: {
12
- width?: number;
13
- height?: number;
14
- };
15
- /** 标题相关配置 */
16
- title?: string;
17
- showTitle?: boolean;
18
- titleAlign?: 'left' | 'center' | 'right';
19
- /** 副标题相关配置 */
20
- subtitle?: string;
21
- showSubtitle?: boolean;
22
- subtitleAlign?: 'left' | 'center' | 'right';
23
- /** 登录方式配置 */
24
- loginMethods?: ('email' | 'google' | 'facebook' | 'apple')[];
25
- defaultLoginMethod?: 'email' | 'google' | 'facebook' | 'apple';
26
- /** 表单配置 */
27
- emailLabel?: string;
28
- passwordLabel?: string;
29
- emailPlaceholder?: string;
30
- passwordPlaceholder?: string;
31
- emailRules?: any[];
32
- buttonText?: string;
33
- rememberMeText?: string;
34
- forgotPasswordText?: string;
35
- showRememberMe?: boolean;
36
- showForgotPassword?: boolean;
37
- /** 社交登录配置 */
38
- socialLoginTexts?: {
39
- google?: string;
40
- facebook?: string;
41
- apple?: string;
42
- };
43
- /** 底部配置 */
44
- showFooter?: boolean;
45
- showSignUp?: boolean;
46
- signUpText?: string;
47
- signUpLink?: string;
48
- signUpPosition?: 'left' | 'center' | 'right';
49
- otherLinks?: Array<{
50
- text: string;
51
- url: string;
52
- }>;
53
- otherLinksPosition?: 'left' | 'center' | 'right';
54
- /** 登录/注册切换配置 */
55
- showTabs?: boolean;
56
- loginTabText?: string;
57
- registerTabText?: string;
58
- /** 注册表单配置 */
59
- registerEmailPlaceholder?: string;
60
- registerPasswordPlaceholder?: string;
61
- registerButtonText?: string;
62
- /** 事件回调 */
63
- onLogin?: (values: {
64
- email: string;
65
- loginMethod: string;
66
- }) => void;
67
- onSocialLogin?: (type: 'google' | 'facebook' | 'apple') => void;
68
- onSignUp?: () => void;
69
- onRegister?: (values: {
70
- email: string;
71
- password: string;
72
- }) => void;
73
- /** 新增背景图片属性 */
74
- backgroundImage?: string;
75
- }
76
- /**
77
- * Saas登录组件
78
- * @param props - 组件属性
79
- * @returns React组件
80
- */
81
- declare const loginAndRegister: React.FC<loginAndRegisterProps>;
82
- export default loginAndRegister;
@@ -1,19 +0,0 @@
1
- import React from 'react';
2
- import { EmptyProps } from 'antd';
3
- import { PisellContextType } from '../pisell-config-provider/context';
4
- import './index.less';
5
- export interface PisellEmptyProps extends EmptyProps {
6
- /** 平台 */
7
- platform?: PisellContextType['platform'];
8
- /** 额外内容描述 */
9
- extraDescription?: React.ReactNode;
10
- /** 额外内容描述 */
11
- icon?: React.ReactNode;
12
- /** 自定义底部额外操作区域 */
13
- footer?: React.ReactNode;
14
- [key: string]: any;
15
- /** 最大宽度 */
16
- maxWidth?: number;
17
- }
18
- declare const PisellEmpty: (props: PisellEmptyProps) => JSX.Element;
19
- export default PisellEmpty;
@@ -1,4 +0,0 @@
1
- /// <reference types="react" />
2
- import './index.less';
3
- declare const DeleteButton: ({ onDelete }: any) => JSX.Element;
4
- export default DeleteButton;
@@ -1,9 +0,0 @@
1
- import React from 'react';
2
- import { Select as OriginalSelect } from 'antd';
3
- import type { SelectProps } from 'antd';
4
- import './index.less';
5
- interface CompoundedComponent extends React.ForwardRefExoticComponent<SelectProps> {
6
- Option: typeof OriginalSelect.Option;
7
- }
8
- declare const Select: CompoundedComponent;
9
- export default Select;
@@ -1,7 +0,0 @@
1
- interface IExportParams {
2
- type: string;
3
- originDataSource: any[];
4
- currentDataSource: any[];
5
- }
6
- export declare const batchExport: (exportParams: IExportParams, exportImport: any) => Promise<true | undefined>;
7
- export {};
@@ -1,17 +0,0 @@
1
- import { FilterType } from "../../filter/types";
2
- import { ColumnSettingType, DataSourceGroupType, ExportImportType, GallerySettingType, GridViewType, SortType } from "../types";
3
- import "./index.less";
4
- declare type ActionsProps = {
5
- filter: FilterType;
6
- tableId?: string;
7
- columnSetting?: ColumnSettingType;
8
- dataSourceGroup?: DataSourceGroupType;
9
- sort: SortType;
10
- localPagination?: boolean;
11
- buttons: any[];
12
- view: GridViewType;
13
- gallery: GallerySettingType;
14
- exportImport?: ExportImportType;
15
- };
16
- declare const Actions: ({ filter, sort, columnSetting, dataSourceGroup, tableId, localPagination, buttons, view, gallery, exportImport, }: ActionsProps) => JSX.Element | null;
17
- export default Actions;
@@ -1,13 +0,0 @@
1
- declare type exportParams = {
2
- ids?: Array<string | number>;
3
- file_name?: string;
4
- form_id?: string | number;
5
- code?: string;
6
- url?: string;
7
- };
8
- export declare const exportData: (params: exportParams) => Promise<any>;
9
- export declare const batchImport: (params: any) => Promise<any>;
10
- export declare const importTemplate: (params: exportParams) => Promise<any>;
11
- export declare const getExportFile: (params: any) => Promise<any>;
12
- export declare const getImportLog: (params: any) => Promise<any>;
13
- export {};