@fox-js/foxui-pc 4.0.1-4 → 4.0.1-40

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.
@@ -1,6 +1,5 @@
1
1
  import type { AllowedComponentProps } from 'vue';
2
2
  import { App } from 'vue';
3
- import { clone } from '@fox-js/fox';
4
3
  import { compareTo } from '@fox-js/big-decimal';
5
4
  import type { ComponentCustomProps } from 'vue';
6
5
  import { ComponentInternalInstance } from 'vue';
@@ -10,7 +9,6 @@ import type { ComputedOptions } from 'vue';
10
9
  import type { DefineComponent } from 'vue';
11
10
  import { divide } from '@fox-js/big-decimal';
12
11
  import { ExecuteValidator } from '@fox-js/validator';
13
- import { extend } from '@fox-js/fox';
14
12
  import { ElAffix as FoxAffix } from 'element-plus';
15
13
  import { ElAlert as FoxAlert } from 'element-plus';
16
14
  import { ElAside as FoxAside } from 'element-plus';
@@ -105,27 +103,12 @@ import { ElTree as FoxTree } from 'element-plus';
105
103
  import { ElTreeSelect as FoxTreeSelect } from 'element-plus';
106
104
  import { ElTreeV2 as FoxTreeV2 } from 'element-plus';
107
105
  import { ElUpload as FoxUpload } from 'element-plus';
108
- import { isArray } from '@fox-js/fox';
109
- import { isDate } from '@fox-js/fox';
110
- import { isEqual } from '@fox-js/fox';
111
- import { isESModule } from '@fox-js/fox';
112
- import { isFunction } from '@fox-js/fox';
113
- import { isMap } from '@fox-js/fox';
114
- import { isObject } from '@fox-js/fox';
115
- import { isPlainObject } from '@fox-js/fox';
116
- import { isPromise } from '@fox-js/fox';
117
- import { isSet } from '@fox-js/fox';
118
- import { isString } from '@fox-js/fox';
119
- import { isSymbol } from '@fox-js/fox';
120
106
  import type { MethodOptions } from 'vue';
121
107
  import { multiply } from '@fox-js/big-decimal';
122
108
  import { negate } from '@fox-js/big-decimal';
123
109
  import { numberFormat } from '@fox-js/big-decimal';
124
110
  import { Ref } from 'vue';
125
111
  import { Rule } from '@fox-js/validator';
126
- import { toBoolean } from '@fox-js/fox';
127
- import { toNumber } from '@fox-js/fox';
128
- import { toTypeString } from '@fox-js/fox';
129
112
  import { unNumberFormat } from '@fox-js/big-decimal';
130
113
  import { UnwrapNestedRefs } from 'vue';
131
114
  import { UnwrapRef } from 'vue';
@@ -228,7 +211,15 @@ export declare const CheckboxItem: DefineComponent<unknown, object, {}, Computed
228
211
  */
229
212
  export declare function clearNonNumber(value: string, allowDot?: boolean, allowMinus?: boolean): string;
230
213
 
231
- export { clone }
214
+ /**
215
+ * 克隆对象
216
+ * @param target
217
+ * @param source
218
+ * @param plain
219
+ *
220
+ * @returns
221
+ */
222
+ export declare function clone(target: any, source: any, plain?: boolean): any;
232
223
 
233
224
  export { compareTo }
234
225
 
@@ -264,10 +255,17 @@ export declare const DateItem: DefineComponent<unknown, object, {}, ComputedOpti
264
255
  /**
265
256
  * 防抖函数
266
257
  * @param func 函数
267
- * @param time 防止抖动毫秒数
258
+ * @param delay 防止抖动毫秒数
268
259
  * @returns
269
260
  */
270
- export declare function debounce(func: GenericFunction, time: number): GenericFunction;
261
+ export declare function debounce(func: GenericFunction, delay: number): GenericFunction;
262
+
263
+ /**
264
+ * 防抖Ref
265
+ * @param value
266
+ * @param delay
267
+ */
268
+ export declare function debounceRef<T>(value: T, delay: number): Ref<T>;
271
269
 
272
270
  /**
273
271
  * 获取小数长度
@@ -286,6 +284,15 @@ export default _default;
286
284
  */
287
285
  export declare function defineBroadcast(name?: string, callbacks?: Record<string, BroadcastCallback>, proxy?: FoxComponentPublicInstance): Broadcast | null;
288
286
 
287
+ /**
288
+ * 安装config domain
289
+ * @param name 名称
290
+ * @param props 属性
291
+ * @param ignores 忽略的属性
292
+ * @returns
293
+ */
294
+ export declare function defineConfigDomain(name: string | null, props: Record<string, any>, ignores?: any[]): Domain;
295
+
289
296
  /**
290
297
  * 定义domain data item
291
298
  * @returns
@@ -342,6 +349,8 @@ export declare interface Descriptor {
342
349
 
343
350
  export declare const DialogItem: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
344
351
 
352
+ declare type Direction = '' | 'vertical' | 'horizontal';
353
+
345
354
  /**
346
355
  * 禁用属性
347
356
  * @param source
@@ -459,6 +468,8 @@ export declare interface DomainItem {
459
468
  */
460
469
  export declare const DomainKey: unique symbol;
461
470
 
471
+ export declare const DomainProvider: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
472
+
462
473
  /**
463
474
  * event listener
464
475
  */
@@ -474,7 +485,14 @@ declare interface EventListener_2 {
474
485
  */
475
486
  export declare function excludeProps(src: Record<string, any>, ...excludeTemplates: Record<string, any>[]): Record<string, any>;
476
487
 
477
- export { extend }
488
+ /**
489
+ * 继承(是否深度拷贝,dest,src1,src2,src3...)
490
+ *
491
+ * @returns
492
+ */
493
+ export declare function extend(...args: any[]): any;
494
+
495
+ export declare const ExtIcon: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
478
496
 
479
497
  export declare const floatData: (format: any, dataOp: any, mapOps: any) => any;
480
498
 
@@ -681,7 +699,7 @@ declare interface FoxUI {
681
699
  * @param app
682
700
  * @param options
683
701
  */
684
- install(app: App, options: FoxUIOptions): void;
702
+ install(app: App, options: FoxUIOptions): any;
685
703
  /**
686
704
  * 初始化page Layout
687
705
  *
@@ -729,6 +747,7 @@ declare interface FoxUI {
729
747
  * UI Options
730
748
  */
731
749
  declare interface FoxUIOptions {
750
+ install?: boolean;
732
751
  headerBarHeight?: number;
733
752
  footerBarHeight?: number;
734
753
  safeAreaInset?: SafeAreaInset;
@@ -768,7 +787,7 @@ declare class FoxUIVue implements FoxUI {
768
787
  * @param app
769
788
  * @param options
770
789
  */
771
- install(app: App, options?: FoxUIOptions): void;
790
+ install(app: App, options?: FoxUIOptions): any;
772
791
  /**
773
792
  * 初始化page Layout
774
793
  *
@@ -881,6 +900,11 @@ declare interface GroupLayout {
881
900
  gutter: number;
882
901
  }
883
902
 
903
+ /**
904
+ * 是否支持symbol
905
+ */
906
+ export declare const hasSymbol: boolean;
907
+
884
908
  export declare const HeaderBar: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
885
909
 
886
910
  export declare const HintText: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
@@ -901,8 +925,12 @@ export declare function includeProps(src: Record<string, any>, ...includeTemplat
901
925
  */
902
926
  export declare function indexOf(x: unknown, arr: unknown[]): number;
903
927
 
928
+ export declare const Indicator: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
929
+
904
930
  export declare const InputItem: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
905
931
 
932
+ export declare const InputNumberItem: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
933
+
906
934
  /**
907
935
  * 安装函数
908
936
  */
@@ -910,20 +938,41 @@ declare interface Installer {
910
938
  (app: App, options?: any): void;
911
939
  }
912
940
 
941
+ /**
942
+ * 安装校验规则
943
+ * @param proxy
944
+ */
945
+ export declare function installRules(proxy: FoxComponentPublicInstance, validateScheme: ValidateSchema, name: string): void;
946
+
913
947
  /**
914
948
  * 获取整数长度
915
949
  * @param value
916
950
  */
917
951
  export declare function integerLength(value: string | number): number;
918
952
 
919
- export { isArray }
953
+ /**
954
+ * 是否数组
955
+ */
956
+ export declare const isArray: (arg: any) => arg is any[];
957
+
958
+ /**
959
+ * 是否为类数组
960
+ * @param obj
961
+ * @returns {boolean}
962
+ */
963
+ export declare function isArrayLike(obj: any): boolean;
920
964
 
921
965
  /**
922
966
  * 是否为浏览器环境
923
967
  */
924
968
  export declare const isBrowser: boolean;
925
969
 
926
- export { isDate }
970
+ /**
971
+ * 是否为Date
972
+ * @param val
973
+ * @returns
974
+ */
975
+ export declare const isDate: (val: unknown) => val is Date;
927
976
 
928
977
  /**
929
978
  * 是否空字符串
@@ -932,11 +981,33 @@ export { isDate }
932
981
  */
933
982
  export declare const isEmptyString: (v: unknown) => boolean;
934
983
 
935
- export { isEqual }
984
+ /**
985
+ * 判断两个对象是否一致
986
+ * @param x
987
+ * @param y
988
+ * @return
989
+ */
990
+ export declare function isEqual(x: any, y: any): boolean;
936
991
 
937
- export { isESModule }
992
+ /**
993
+ * 是否为es module
994
+ * @param obj
995
+ * @returns
996
+ */
997
+ export declare function isESModule(obj: any): obj is Object;
998
+
999
+ /**
1000
+ * 是否为函数
1001
+ * @param val
1002
+ * @returns
1003
+ */
1004
+ export declare const isFunction: (val: unknown) => val is Function;
938
1005
 
939
- export { isFunction }
1006
+ /**
1007
+ * 是否是隐藏element
1008
+ * @param el
1009
+ */
1010
+ export declare function isHidden(el: any): boolean;
940
1011
 
941
1012
  /**
942
1013
  * 是否为内嵌页面
@@ -947,7 +1018,12 @@ export { isFunction }
947
1018
  */
948
1019
  export declare function isInnerPage(domain: Domain, proxy: any): boolean;
949
1020
 
950
- export { isMap }
1021
+ /**
1022
+ * 是否为Map
1023
+ * @param val
1024
+ * @returns
1025
+ */
1026
+ export declare const isMap: (val: unknown) => val is Map<any, any>;
951
1027
 
952
1028
  /**
953
1029
  * 是否为数字字符串
@@ -956,11 +1032,24 @@ export { isMap }
956
1032
  */
957
1033
  export declare function isNumberString(value: string): boolean;
958
1034
 
959
- export { isObject }
1035
+ /**
1036
+ * 是否为object
1037
+ */
1038
+ export declare const isObject: (val: unknown) => val is Record<any, any>;
960
1039
 
961
- export { isPlainObject }
1040
+ /**
1041
+ * 是否为plain对象
1042
+ * @param val
1043
+ * @returns
1044
+ */
1045
+ export declare const isPlainObject: (val: unknown) => val is object;
962
1046
 
963
- export { isPromise }
1047
+ /**
1048
+ * 是否为promise
1049
+ * @param val
1050
+ * @returns
1051
+ */
1052
+ export declare const isPromise: <T = any>(val: unknown) => val is Promise<T>;
964
1053
 
965
1054
  /**
966
1055
  * 判断是否为正则表达式
@@ -969,9 +1058,19 @@ export { isPromise }
969
1058
  */
970
1059
  export declare function isRegExp(v: unknown): v is RegExp;
971
1060
 
972
- export { isSet }
1061
+ /**
1062
+ * 是否为Set
1063
+ * @param val
1064
+ * @returns
1065
+ */
1066
+ export declare const isSet: (val: unknown) => val is Set<any>;
973
1067
 
974
- export { isString }
1068
+ /**
1069
+ * 是否为字符串
1070
+ * @param val
1071
+ * @returns
1072
+ */
1073
+ export declare const isString: (val: unknown) => val is string;
975
1074
 
976
1075
  /**
977
1076
  * 是否子页面
@@ -979,7 +1078,18 @@ export { isString }
979
1078
  */
980
1079
  export declare function isSubPage(domain: Domain): boolean;
981
1080
 
982
- export { isSymbol }
1081
+ /**
1082
+ * 是否为symbol
1083
+ * @param val
1084
+ * @returns
1085
+ */
1086
+ export declare const isSymbol: (val: unknown) => val is symbol;
1087
+
1088
+ /**
1089
+ * 是否是window对象
1090
+ * @param obj
1091
+ */
1092
+ export declare function isWindow(obj: any): boolean;
983
1093
 
984
1094
  export declare const Item: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
985
1095
 
@@ -991,6 +1101,14 @@ export declare const Item: DefineComponent<unknown, object, {}, ComputedOptions,
991
1101
  */
992
1102
  export declare function lastIndexOf(x: unknown, arr: unknown[]): number;
993
1103
 
1104
+ /**
1105
+ * 创建数组
1106
+ * @param arr
1107
+ * @param results
1108
+ * @return
1109
+ */
1110
+ export declare function makeArray(arr: any, results?: any[]): any[];
1111
+
994
1112
  export declare const Mapping: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
995
1113
 
996
1114
  /**
@@ -1004,14 +1122,38 @@ export declare interface Matched {
1004
1122
  level?: number;
1005
1123
  }
1006
1124
 
1125
+ /**
1126
+ * 合并数组
1127
+ * @param first
1128
+ * @param second
1129
+ * @return
1130
+ */
1131
+ export declare function merge(first: any[], second: any[]): any[];
1132
+
1007
1133
  export declare const MoneyItem: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
1008
1134
 
1135
+ export declare const MoreButton: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
1136
+
1009
1137
  export { multiply }
1010
1138
 
1011
1139
  export { negate }
1012
1140
 
1141
+ /**
1142
+ * 下一个事件周期中执行函数
1143
+ * @param fn
1144
+ * @param args
1145
+ */
1146
+ export declare function nextTick(fn: {
1147
+ (...args: any[]): void;
1148
+ }, ...args: any[]): void;
1149
+
1013
1150
  export { numberFormat }
1014
1151
 
1152
+ /**
1153
+ * 对象类型
1154
+ */
1155
+ export declare const objectToString: () => string;
1156
+
1015
1157
  /**
1016
1158
  * padding
1017
1159
  */
@@ -1029,7 +1171,7 @@ export declare const Page: DefineComponent<unknown, object, {}, ComputedOptions,
1029
1171
  */
1030
1172
  export declare interface PageLayout {
1031
1173
  width: number | string;
1032
- height: number | string;
1174
+ height?: number | string;
1033
1175
  headerHeight: number | string;
1034
1176
  footerHeight: number | string;
1035
1177
  headerPadding?: Padding;
@@ -1184,21 +1326,36 @@ export declare const TableItem: DefineComponent<unknown, object, {}, ComputedOpt
1184
1326
 
1185
1327
  export declare const TableMappingColumn: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
1186
1328
 
1329
+ export declare const TableRadioColumn: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
1330
+
1331
+ declare const Text_2: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
1332
+ export { Text_2 as Text }
1333
+
1187
1334
  /**
1188
1335
  * 节流函数
1189
1336
  * @param func 函数
1190
- * @param time 延迟执行毫秒数
1337
+ * @param delay 延迟执行毫秒数
1191
1338
  * @returns
1192
1339
  */
1193
- export declare function throttle(func: GenericFunction, time: number): GenericFunction;
1340
+ export declare function throttle(func: GenericFunction, delay: number): GenericFunction;
1194
1341
 
1195
1342
  export declare const TimeItem: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
1196
1343
 
1197
1344
  export declare const TimeSelectItem: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
1198
1345
 
1199
- export { toBoolean }
1346
+ /**
1347
+ * 转换为boolean值
1348
+ * @param val
1349
+ * @returns
1350
+ */
1351
+ export declare function toBoolean(val: unknown): boolean;
1200
1352
 
1201
- export { toNumber }
1353
+ /**
1354
+ * 转换为number值
1355
+ * @param val
1356
+ * @returns
1357
+ */
1358
+ export declare function toNumber(val: unknown): number;
1202
1359
 
1203
1360
  /**
1204
1361
  * 转换为number rect
@@ -1220,7 +1377,7 @@ export declare function toPx(value: number | string, size?: number): number;
1220
1377
  */
1221
1378
  export declare const toPxDesc: (value: string | number, size?: number) => string;
1222
1379
 
1223
- export { toTypeString }
1380
+ export declare const toTypeString: (value: unknown) => string;
1224
1381
 
1225
1382
  /**
1226
1383
  * to model value
@@ -1230,6 +1387,15 @@ export { toTypeString }
1230
1387
  */
1231
1388
  export declare function toValue(props: UnwrapRef<Record<string, any>>, name?: string, format?: ValueFormat<any, any>): Ref;
1232
1389
 
1390
+ export declare const TreeSelectItem: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
1391
+
1392
+ /**
1393
+ * 判断类型
1394
+ * @param obj
1395
+ * @returns any
1396
+ */
1397
+ export declare function typeOf(obj: any): string;
1398
+
1233
1399
  export declare class UniqueID {
1234
1400
  /**
1235
1401
  * seed id
@@ -1268,7 +1434,7 @@ export declare function useBroadcast(proxy?: FoxComponentPublicInstance | null):
1268
1434
  * 获取当前domain
1269
1435
  * @returns
1270
1436
  */
1271
- export declare function useDomain(instance?: ComponentInternalInstance | null): Domain | null;
1437
+ export declare function useDomain(proxy?: ComponentPublicInstance | null): Domain | null;
1272
1438
 
1273
1439
  /**
1274
1440
  * use expose
@@ -1292,12 +1458,33 @@ export declare const usePosition: (elementRef: (Element | Window) | Ref<Element
1292
1458
 
1293
1459
  export declare const useRect: (elementRef: (Element | Window) | Ref<Element | Window | undefined>) => Rect_2;
1294
1460
 
1461
+ export declare function useTouch(): {
1462
+ move: EventListener;
1463
+ start: EventListener;
1464
+ reset: () => void;
1465
+ startX: Ref<number>;
1466
+ startY: Ref<number>;
1467
+ startTime: Ref<number>;
1468
+ duration: Ref<number>;
1469
+ moveX: Ref<number>;
1470
+ moveY: Ref<number>;
1471
+ deltaX: Ref<number>;
1472
+ deltaY: Ref<number>;
1473
+ offsetX: Ref<number>;
1474
+ offsetY: Ref<number>;
1475
+ direction: Ref<Direction>;
1476
+ isVertical: () => boolean;
1477
+ isHorizontal: () => boolean;
1478
+ };
1479
+
1295
1480
  /**
1296
1481
  * 校验条件
1297
1482
  */
1298
1483
  export declare interface ValidateCondition {
1299
- exclude?: string[];
1484
+ deep?: boolean;
1300
1485
  include?: string[];
1486
+ exclude?: string[];
1487
+ ignoreHidden?: boolean;
1301
1488
  }
1302
1489
 
1303
1490
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fox-js/foxui-pc",
3
- "version": "4.0.1-4",
3
+ "version": "4.0.1-40",
4
4
  "description": "FoxUI PC端组件库",
5
5
  "author": "jiangcheng",
6
6
  "main": "dist/index.umd.js",
@@ -27,7 +27,7 @@
27
27
  "access": "public"
28
28
  },
29
29
  "scripts": {
30
- "publish:next": "npm version prerelease && npm publish --tag next"
30
+ "publish:next": "npm version prerelease && npm publish --tag next --no-git-checks"
31
31
  },
32
32
  "license": "",
33
33
  "repository": "",