@fox-js/foxui-pc 4.0.1-3 → 4.0.1-30

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
 
@@ -286,6 +277,15 @@ export default _default;
286
277
  */
287
278
  export declare function defineBroadcast(name?: string, callbacks?: Record<string, BroadcastCallback>, proxy?: FoxComponentPublicInstance): Broadcast | null;
288
279
 
280
+ /**
281
+ * 安装config domain
282
+ * @param name 名称
283
+ * @param props 属性
284
+ * @param ignores 忽略的属性
285
+ * @returns
286
+ */
287
+ export declare function defineConfigDomain(name: string | null, props: Record<string, any>, ignores?: any[]): Domain;
288
+
289
289
  /**
290
290
  * 定义domain data item
291
291
  * @returns
@@ -342,6 +342,8 @@ export declare interface Descriptor {
342
342
 
343
343
  export declare const DialogItem: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
344
344
 
345
+ declare type Direction = '' | 'vertical' | 'horizontal';
346
+
345
347
  /**
346
348
  * 禁用属性
347
349
  * @param source
@@ -459,6 +461,8 @@ export declare interface DomainItem {
459
461
  */
460
462
  export declare const DomainKey: unique symbol;
461
463
 
464
+ export declare const DomainProvider: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
465
+
462
466
  /**
463
467
  * event listener
464
468
  */
@@ -474,7 +478,14 @@ declare interface EventListener_2 {
474
478
  */
475
479
  export declare function excludeProps(src: Record<string, any>, ...excludeTemplates: Record<string, any>[]): Record<string, any>;
476
480
 
477
- export { extend }
481
+ /**
482
+ * 继承(是否深度拷贝,dest,src1,src2,src3...)
483
+ *
484
+ * @returns
485
+ */
486
+ export declare function extend(...args: any[]): any;
487
+
488
+ export declare const ExtIcon: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
478
489
 
479
490
  export declare const floatData: (format: any, dataOp: any, mapOps: any) => any;
480
491
 
@@ -681,7 +692,7 @@ declare interface FoxUI {
681
692
  * @param app
682
693
  * @param options
683
694
  */
684
- install(app: App, options: FoxUIOptions): void;
695
+ install(app: App, options: FoxUIOptions): any;
685
696
  /**
686
697
  * 初始化page Layout
687
698
  *
@@ -729,6 +740,7 @@ declare interface FoxUI {
729
740
  * UI Options
730
741
  */
731
742
  declare interface FoxUIOptions {
743
+ install?: boolean;
732
744
  headerBarHeight?: number;
733
745
  footerBarHeight?: number;
734
746
  safeAreaInset?: SafeAreaInset;
@@ -768,7 +780,7 @@ declare class FoxUIVue implements FoxUI {
768
780
  * @param app
769
781
  * @param options
770
782
  */
771
- install(app: App, options?: FoxUIOptions): void;
783
+ install(app: App, options?: FoxUIOptions): any;
772
784
  /**
773
785
  * 初始化page Layout
774
786
  *
@@ -881,6 +893,11 @@ declare interface GroupLayout {
881
893
  gutter: number;
882
894
  }
883
895
 
896
+ /**
897
+ * 是否支持symbol
898
+ */
899
+ export declare const hasSymbol: boolean;
900
+
884
901
  export declare const HeaderBar: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
885
902
 
886
903
  export declare const HintText: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
@@ -901,8 +918,12 @@ export declare function includeProps(src: Record<string, any>, ...includeTemplat
901
918
  */
902
919
  export declare function indexOf(x: unknown, arr: unknown[]): number;
903
920
 
921
+ export declare const Indicator: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
922
+
904
923
  export declare const InputItem: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
905
924
 
925
+ export declare const InputNumberItem: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
926
+
906
927
  /**
907
928
  * 安装函数
908
929
  */
@@ -916,14 +937,29 @@ declare interface Installer {
916
937
  */
917
938
  export declare function integerLength(value: string | number): number;
918
939
 
919
- export { isArray }
940
+ /**
941
+ * 是否数组
942
+ */
943
+ export declare const isArray: (arg: any) => arg is any[];
944
+
945
+ /**
946
+ * 是否为类数组
947
+ * @param obj
948
+ * @returns {boolean}
949
+ */
950
+ export declare function isArrayLike(obj: any): boolean;
920
951
 
921
952
  /**
922
953
  * 是否为浏览器环境
923
954
  */
924
955
  export declare const isBrowser: boolean;
925
956
 
926
- export { isDate }
957
+ /**
958
+ * 是否为Date
959
+ * @param val
960
+ * @returns
961
+ */
962
+ export declare const isDate: (val: unknown) => val is Date;
927
963
 
928
964
  /**
929
965
  * 是否空字符串
@@ -932,11 +968,27 @@ export { isDate }
932
968
  */
933
969
  export declare const isEmptyString: (v: unknown) => boolean;
934
970
 
935
- export { isEqual }
971
+ /**
972
+ * 判断两个对象是否一致
973
+ * @param x
974
+ * @param y
975
+ * @return
976
+ */
977
+ export declare function isEqual(x: any, y: any): boolean;
936
978
 
937
- export { isESModule }
979
+ /**
980
+ * 是否为es module
981
+ * @param obj
982
+ * @returns
983
+ */
984
+ export declare function isESModule(obj: any): obj is Object;
938
985
 
939
- export { isFunction }
986
+ /**
987
+ * 是否为函数
988
+ * @param val
989
+ * @returns
990
+ */
991
+ export declare const isFunction: (val: unknown) => val is Function;
940
992
 
941
993
  /**
942
994
  * 是否为内嵌页面
@@ -947,7 +999,12 @@ export { isFunction }
947
999
  */
948
1000
  export declare function isInnerPage(domain: Domain, proxy: any): boolean;
949
1001
 
950
- export { isMap }
1002
+ /**
1003
+ * 是否为Map
1004
+ * @param val
1005
+ * @returns
1006
+ */
1007
+ export declare const isMap: (val: unknown) => val is Map<any, any>;
951
1008
 
952
1009
  /**
953
1010
  * 是否为数字字符串
@@ -956,11 +1013,24 @@ export { isMap }
956
1013
  */
957
1014
  export declare function isNumberString(value: string): boolean;
958
1015
 
959
- export { isObject }
1016
+ /**
1017
+ * 是否为object
1018
+ */
1019
+ export declare const isObject: (val: unknown) => val is Record<any, any>;
960
1020
 
961
- export { isPlainObject }
1021
+ /**
1022
+ * 是否为plain对象
1023
+ * @param val
1024
+ * @returns
1025
+ */
1026
+ export declare const isPlainObject: (val: unknown) => val is object;
962
1027
 
963
- export { isPromise }
1028
+ /**
1029
+ * 是否为promise
1030
+ * @param val
1031
+ * @returns
1032
+ */
1033
+ export declare const isPromise: <T = any>(val: unknown) => val is Promise<T>;
964
1034
 
965
1035
  /**
966
1036
  * 判断是否为正则表达式
@@ -969,9 +1039,19 @@ export { isPromise }
969
1039
  */
970
1040
  export declare function isRegExp(v: unknown): v is RegExp;
971
1041
 
972
- export { isSet }
1042
+ /**
1043
+ * 是否为Set
1044
+ * @param val
1045
+ * @returns
1046
+ */
1047
+ export declare const isSet: (val: unknown) => val is Set<any>;
973
1048
 
974
- export { isString }
1049
+ /**
1050
+ * 是否为字符串
1051
+ * @param val
1052
+ * @returns
1053
+ */
1054
+ export declare const isString: (val: unknown) => val is string;
975
1055
 
976
1056
  /**
977
1057
  * 是否子页面
@@ -979,7 +1059,18 @@ export { isString }
979
1059
  */
980
1060
  export declare function isSubPage(domain: Domain): boolean;
981
1061
 
982
- export { isSymbol }
1062
+ /**
1063
+ * 是否为symbol
1064
+ * @param val
1065
+ * @returns
1066
+ */
1067
+ export declare const isSymbol: (val: unknown) => val is symbol;
1068
+
1069
+ /**
1070
+ * 是否是window对象
1071
+ * @param obj
1072
+ */
1073
+ export declare function isWindow(obj: any): boolean;
983
1074
 
984
1075
  export declare const Item: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
985
1076
 
@@ -991,6 +1082,14 @@ export declare const Item: DefineComponent<unknown, object, {}, ComputedOptions,
991
1082
  */
992
1083
  export declare function lastIndexOf(x: unknown, arr: unknown[]): number;
993
1084
 
1085
+ /**
1086
+ * 创建数组
1087
+ * @param arr
1088
+ * @param results
1089
+ * @return
1090
+ */
1091
+ export declare function makeArray(arr: any, results?: any[]): any[];
1092
+
994
1093
  export declare const Mapping: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
995
1094
 
996
1095
  /**
@@ -1004,14 +1103,36 @@ export declare interface Matched {
1004
1103
  level?: number;
1005
1104
  }
1006
1105
 
1106
+ /**
1107
+ * 合并数组
1108
+ * @param first
1109
+ * @param second
1110
+ * @return
1111
+ */
1112
+ export declare function merge(first: any[], second: any[]): any[];
1113
+
1007
1114
  export declare const MoneyItem: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
1008
1115
 
1009
1116
  export { multiply }
1010
1117
 
1011
1118
  export { negate }
1012
1119
 
1120
+ /**
1121
+ * 下一个事件周期中执行函数
1122
+ * @param fn
1123
+ * @param args
1124
+ */
1125
+ export declare function nextTick(fn: {
1126
+ (...args: any[]): void;
1127
+ }, ...args: any[]): void;
1128
+
1013
1129
  export { numberFormat }
1014
1130
 
1131
+ /**
1132
+ * 对象类型
1133
+ */
1134
+ export declare const objectToString: () => string;
1135
+
1015
1136
  /**
1016
1137
  * padding
1017
1138
  */
@@ -1029,7 +1150,7 @@ export declare const Page: DefineComponent<unknown, object, {}, ComputedOptions,
1029
1150
  */
1030
1151
  export declare interface PageLayout {
1031
1152
  width: number | string;
1032
- height: number | string;
1153
+ height?: number | string;
1033
1154
  headerHeight: number | string;
1034
1155
  footerHeight: number | string;
1035
1156
  headerPadding?: Padding;
@@ -1184,6 +1305,9 @@ export declare const TableItem: DefineComponent<unknown, object, {}, ComputedOpt
1184
1305
 
1185
1306
  export declare const TableMappingColumn: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
1186
1307
 
1308
+ declare const Text_2: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
1309
+ export { Text_2 as Text }
1310
+
1187
1311
  /**
1188
1312
  * 节流函数
1189
1313
  * @param func 函数
@@ -1196,9 +1320,19 @@ export declare const TimeItem: DefineComponent<unknown, object, {}, ComputedOpti
1196
1320
 
1197
1321
  export declare const TimeSelectItem: DefineComponent<unknown, object, {}, ComputedOptions, MethodOptions, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<unknown>, {}>;
1198
1322
 
1199
- export { toBoolean }
1323
+ /**
1324
+ * 转换为boolean值
1325
+ * @param val
1326
+ * @returns
1327
+ */
1328
+ export declare function toBoolean(val: unknown): boolean;
1200
1329
 
1201
- export { toNumber }
1330
+ /**
1331
+ * 转换为number值
1332
+ * @param val
1333
+ * @returns
1334
+ */
1335
+ export declare function toNumber(val: unknown): number;
1202
1336
 
1203
1337
  /**
1204
1338
  * 转换为number rect
@@ -1220,7 +1354,7 @@ export declare function toPx(value: number | string, size?: number): number;
1220
1354
  */
1221
1355
  export declare const toPxDesc: (value: string | number, size?: number) => string;
1222
1356
 
1223
- export { toTypeString }
1357
+ export declare const toTypeString: (value: unknown) => string;
1224
1358
 
1225
1359
  /**
1226
1360
  * to model value
@@ -1230,6 +1364,13 @@ export { toTypeString }
1230
1364
  */
1231
1365
  export declare function toValue(props: UnwrapRef<Record<string, any>>, name?: string, format?: ValueFormat<any, any>): Ref;
1232
1366
 
1367
+ /**
1368
+ * 判断类型
1369
+ * @param obj
1370
+ * @returns any
1371
+ */
1372
+ export declare function typeOf(obj: any): string;
1373
+
1233
1374
  export declare class UniqueID {
1234
1375
  /**
1235
1376
  * seed id
@@ -1292,6 +1433,25 @@ export declare const usePosition: (elementRef: (Element | Window) | Ref<Element
1292
1433
 
1293
1434
  export declare const useRect: (elementRef: (Element | Window) | Ref<Element | Window | undefined>) => Rect_2;
1294
1435
 
1436
+ export declare function useTouch(): {
1437
+ move: EventListener;
1438
+ start: EventListener;
1439
+ reset: () => void;
1440
+ startX: Ref<number>;
1441
+ startY: Ref<number>;
1442
+ startTime: Ref<number>;
1443
+ duration: Ref<number>;
1444
+ moveX: Ref<number>;
1445
+ moveY: Ref<number>;
1446
+ deltaX: Ref<number>;
1447
+ deltaY: Ref<number>;
1448
+ offsetX: Ref<number>;
1449
+ offsetY: Ref<number>;
1450
+ direction: Ref<Direction>;
1451
+ isVertical: () => boolean;
1452
+ isHorizontal: () => boolean;
1453
+ };
1454
+
1295
1455
  /**
1296
1456
  * 校验条件
1297
1457
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fox-js/foxui-pc",
3
- "version": "4.0.1-3",
3
+ "version": "4.0.1-30",
4
4
  "description": "FoxUI PC端组件库",
5
5
  "author": "jiangcheng",
6
6
  "main": "dist/index.umd.js",
@@ -27,8 +27,9 @@
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
- "repository": ""
33
+ "repository": "",
34
+ "dependencies": {}
34
35
  }