component-shipinlv 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (100) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +4 -0
  3. package/dist/AuthClient/index.d.ts +10 -0
  4. package/dist/AuthClient/index.js +24 -0
  5. package/dist/AuthClient/login-reg.d.ts +9 -0
  6. package/dist/AuthClient/login-reg.js +62 -0
  7. package/dist/AuthClient/login-reg.less +13 -0
  8. package/dist/AuthClient/login.d.ts +7 -0
  9. package/dist/AuthClient/login.js +159 -0
  10. package/dist/AuthClient/login.less +52 -0
  11. package/dist/AuthClient/qr/index.d.ts +13 -0
  12. package/dist/AuthClient/qr/index.js +315 -0
  13. package/dist/AuthClient/qr/index.less +84 -0
  14. package/dist/AuthClient/qr/typings.d.ts +22 -0
  15. package/dist/AuthClient/qr/ws.d.ts +20 -0
  16. package/dist/AuthClient/qr/ws.js +253 -0
  17. package/dist/AuthClient/reg.d.ts +7 -0
  18. package/dist/AuthClient/reg.js +170 -0
  19. package/dist/AuthClient/reg.less +3 -0
  20. package/dist/Buy/index.d.ts +14 -0
  21. package/dist/Buy/index.js +91 -0
  22. package/dist/Buy/index.less +26 -0
  23. package/dist/Buy/qr.d.ts +11 -0
  24. package/dist/Buy/qr.js +185 -0
  25. package/dist/Buy/qr.less +69 -0
  26. package/dist/Login/index.d.ts +2 -0
  27. package/dist/Login/index.js +5 -0
  28. package/dist/Product/index.d.ts +4 -0
  29. package/dist/Product/index.js +34 -0
  30. package/dist/Product/index.less +84 -0
  31. package/dist/UI/DialogDrawer.d.ts +8 -0
  32. package/dist/UI/DialogDrawer.js +67 -0
  33. package/dist/UI/DialogDrawer.less +10 -0
  34. package/dist/UI/DialogDrawerFooter.d.ts +7 -0
  35. package/dist/UI/DialogDrawerFooter.js +23 -0
  36. package/dist/UI/DialogDrawerFooter.less +19 -0
  37. package/dist/UI/LoadError.d.ts +10 -0
  38. package/dist/UI/LoadError.js +37 -0
  39. package/dist/UI/LoadError.less +18 -0
  40. package/dist/UI/PageContentWarp.d.ts +16 -0
  41. package/dist/UI/PageContentWarp.js +46 -0
  42. package/dist/UI/PageContentWarp.less +11 -0
  43. package/dist/VipCompare/commend.d.ts +7 -0
  44. package/dist/VipCompare/commend.js +29 -0
  45. package/dist/VipCompare/commend.less +7 -0
  46. package/dist/VipCompare/index.d.ts +9 -0
  47. package/dist/VipCompare/index.js +320 -0
  48. package/dist/VipCompare/index.less +26 -0
  49. package/dist/component/product-dict.d.ts +10 -0
  50. package/dist/component/product-dict.js +11 -0
  51. package/dist/component/product-type.d.ts +6 -0
  52. package/dist/component/product-type.js +19 -0
  53. package/dist/component/websocket/index.d.ts +22 -0
  54. package/dist/component/websocket/index.js +139 -0
  55. package/dist/config/apiUrls.d.ts +9 -0
  56. package/dist/config/apiUrls.js +25 -0
  57. package/dist/index.d.ts +5 -0
  58. package/dist/index.js +5 -0
  59. package/dist/lib/Tool.d.ts +201 -0
  60. package/dist/lib/Tool.js +1086 -0
  61. package/dist/lib/call-mini-url.d.ts +2 -0
  62. package/dist/lib/call-mini-url.js +8 -0
  63. package/dist/lib/getApiUrl.d.ts +5 -0
  64. package/dist/lib/getApiUrl.js +56 -0
  65. package/dist/lib/goAuth.d.ts +1 -0
  66. package/dist/lib/goAuth.js +28 -0
  67. package/dist/lib/js-error.d.ts +2 -0
  68. package/dist/lib/js-error.js +27 -0
  69. package/dist/lib/notification.d.ts +9 -0
  70. package/dist/lib/notification.js +42 -0
  71. package/dist/lib/platform.d.ts +12 -0
  72. package/dist/lib/platform.js +48 -0
  73. package/dist/lib/postMessage.d.ts +3 -0
  74. package/dist/lib/postMessage.js +8 -0
  75. package/dist/lib/request.d.ts +3 -0
  76. package/dist/lib/request.js +97 -0
  77. package/dist/service/api/AuthController.d.ts +16 -0
  78. package/dist/service/api/AuthController.js +75 -0
  79. package/dist/service/api/JsErrorController.d.ts +5 -0
  80. package/dist/service/api/JsErrorController.js +27 -0
  81. package/dist/service/api/ProductController.d.ts +7 -0
  82. package/dist/service/api/ProductController.js +53 -0
  83. package/dist/service/api/TradeController.d.ts +7 -0
  84. package/dist/service/api/TradeController.js +52 -0
  85. package/dist/service/api/UserController.d.ts +2 -0
  86. package/dist/service/api/UserController.js +52 -0
  87. package/dist/service/api/VipController.d.ts +6 -0
  88. package/dist/service/api/VipController.js +50 -0
  89. package/dist/service/typing.d.ts +12 -0
  90. package/dist/typings/Product.d.ts +25 -0
  91. package/dist/typings/Product.js +0 -0
  92. package/dist/typings/Trade.d.ts +29 -0
  93. package/dist/typings/Trade.js +0 -0
  94. package/dist/typings/User.d.ts +54 -0
  95. package/dist/typings/User.js +0 -0
  96. package/dist/typings/Vip.d.ts +15 -0
  97. package/dist/typings/Vip.js +0 -0
  98. package/dist/typings.d.ts +66 -0
  99. package/dist/window.d.ts +9 -0
  100. package/package.json +88 -0
@@ -0,0 +1,201 @@
1
+ /// <reference types="react" />
2
+ import { useRequest } from '@umijs/hooks';
3
+ interface EventItem {
4
+ name: string;
5
+ fn: (data?: any) => void;
6
+ }
7
+ declare const Tool: {
8
+ event: {
9
+ run(name: string, data?: any): void;
10
+ on(name: string, fn: (data: any) => void, isGlobalOnly?: boolean): void;
11
+ one(name: string, fn: (data: any) => void): void;
12
+ off(name: string): void;
13
+ events: EventItem[];
14
+ };
15
+ formatTime(time: number | string, format?: string): string;
16
+ openWindow(url: string): Promise<void>;
17
+ getFriendlyTime(str: string | number | undefined, now: number | string): string;
18
+ getFriendlyTimeFuture(time?: number): string;
19
+ /**
20
+ * 天 级别
21
+ * @param str 指定的时间字符串,如yyyy-MM-dd HH:mm:ss
22
+ * @param now 当前时间,允许时间戳,GMT时间,如果该参数为undefined,则使用浏览器时间。
23
+ */
24
+ getFriendlyDay(dayString: string | number, now?: string | number, format?: string): string;
25
+ getQuery: (name: string, url?: string) => string;
26
+ getQueryAll(url?: string): {
27
+ [name: string]: string;
28
+ };
29
+ extend(arg1: any, arg2: any): any;
30
+ string: {
31
+ repeat: (word: string, length?: number, end?: string) => string;
32
+ addPre: (pre: string, word: string, size: number) => string;
33
+ trim: (text: string) => string;
34
+ replace: (str: string, re: any) => string;
35
+ };
36
+ math: {
37
+ randInt: (num1: number, num2: number) => number;
38
+ randWord: (wordLen: number, baseWord?: string) => string;
39
+ /**加法运算
40
+ * @说明:解决两个浮点数相加时会出现误差的问题
41
+ * @参数1: number n1
42
+ * @参数2: number n2
43
+ * @示例:add(n1,n2)
44
+ * @返回:string n1+n2
45
+ */
46
+ add: (n1: number, n2: number) => number;
47
+ /**减法运算
48
+ * @说明:解决两个浮点数相减时会出现误差的问题
49
+ * @参数1: number n1
50
+ * @参数2: number n2
51
+ * @示例:subtract(n1,n2)
52
+ * @返回:string n1-n2
53
+ */
54
+ subtract: (n1: any, n2: any) => number;
55
+ /**乘法运算
56
+ * @说明:解决两个浮点数相乘时会出现误差的问题
57
+ * @参数1: number n1
58
+ * @参数2: number n2
59
+ * @示例:multiply(n1,n2)
60
+ * @返回:string n1*n2
61
+ */
62
+ multiply: (n1: any, n2: any) => number;
63
+ /**除法运算
64
+ * @说明:解决两个浮点数相除时会出现误差的问题
65
+ * @参数1: number n1
66
+ * @参数2: number n2
67
+ * @示例:divide(n1,n2)
68
+ * @返回:number n1/n2
69
+ */
70
+ divide: (n1: any, n2: any) => number;
71
+ /**预处理加减运算 , 外界不调用
72
+ * @参数1: number n1
73
+ * @参数2: number n2
74
+ * @示例:preAddSubtract (n1,n2)
75
+ * @返回:object
76
+ */ preAddSubtract: (n1: any, n2: any) => number | {
77
+ s1: any;
78
+ s2: any;
79
+ n1: number;
80
+ n2: number;
81
+ d1: any;
82
+ d2: any;
83
+ };
84
+ /**预处理四则运算参数 , 外界不调用
85
+ * @参数1: number n1
86
+ * @参数2: number n2
87
+ * @示例:preHandle(n1,n2)
88
+ * @返回:object
89
+ */
90
+ preHandle: (n1: any, n2: any) => number | {
91
+ s1: string;
92
+ s2: string;
93
+ n1: number;
94
+ n2: number;
95
+ d1: number;
96
+ d2: number;
97
+ };
98
+ };
99
+ store: {
100
+ get(name: string): any;
101
+ set(name: string, value: any): void;
102
+ };
103
+ toast(content?: string, duration?: number, onClose?: () => void): "" | import("antd/es/message/interface").MessageType;
104
+ toastError(content?: string, duration?: number, onClose?: () => void): "" | import("antd/es/message/interface").MessageType;
105
+ pageDialogBox: never[];
106
+ pageDialog(opt: any): {
107
+ destroy: () => void;
108
+ update: (configUpdate: import("antd").ModalFuncProps | ((prevConfig: import("antd").ModalFuncProps) => import("antd").ModalFuncProps)) => void;
109
+ };
110
+ pageDialogCloseAll(): void;
111
+ param(query?: {
112
+ [name: string]: string | number;
113
+ }): string;
114
+ downloadImage(url: any): void;
115
+ getFileExt(fileUrl: string): string;
116
+ inArray: (t: string | number, arr: any[]) => boolean;
117
+ inArrayIndex: (t: string | number, arr?: never[]) => number;
118
+ moneySimple(money?: number, isTip?: boolean): string | number | import("react/jsx-runtime").JSX.Element;
119
+ isLowIe9(): boolean;
120
+ iEVersion(): number;
121
+ arrayDictionary($lists: any, $keyLevel1: any, $itemName1: any, $keyLevel2: any): {};
122
+ dictionaryArray($object: any, keyName?: string, valueName?: string): {}[];
123
+ stringToIntArray(value?: string, splitWord?: string, delZero?: boolean): any[];
124
+ getHashShow(hash?: string, showLength?: number, $dotCount?: number): string;
125
+ localTimePos: number;
126
+ getLocalTimePos(serverTime?: number): void;
127
+ getNow(): number;
128
+ sitesConfig: null;
129
+ getClientLowServerTime(serverTime: any): void;
130
+ array: {
131
+ index: (t: any, arr: any) => any;
132
+ getKey: (data: any) => string[];
133
+ random(arrays: any): any;
134
+ unique: (array: any) => any;
135
+ max: (array: any) => number;
136
+ min: (array: any) => number;
137
+ remove: (array: any, value: any) => any;
138
+ empty: (array: any) => any;
139
+ removeAt: (array: any, index: any) => any;
140
+ shuffle: (arr: any) => any;
141
+ };
142
+ siteCode(webview: any, fnName: any, detailData: any, query?: {}): void;
143
+ clearLocalLogin(): void;
144
+ onWindowError(): void;
145
+ drawer(query?: any): {
146
+ destroy(): void;
147
+ };
148
+ drawerAllClose(): void;
149
+ sleep(second: number): Promise<boolean>;
150
+ offset(curEle: HTMLElement, parentDom?: HTMLElement): {
151
+ left: number;
152
+ top: number;
153
+ };
154
+ makeQrUrl(url: string, foreground?: string, size?: number): any;
155
+ onLogin(): void;
156
+ getObjectURL(file: File): string;
157
+ onDownFile(url: string): void;
158
+ onInviteIn(inviteKey?: string): void;
159
+ isLogin(): string | false;
160
+ getTimeOffset(): any;
161
+ setTimeOffset(serverTime: number): void;
162
+ getTime(): number;
163
+ h5Pay(query: Pay.H5PayQuery): void;
164
+ notification(type: "success" | "info" | "warning" | "error", message: string, description?: import("react").ReactNode, options?: NotificationOptions): void;
165
+ notificationSuccess(message: string, description?: import("react").ReactNode, options?: NotificationOptions): void;
166
+ notificationError(message: string, description?: import("react").ReactNode, options?: NotificationOptions): void;
167
+ notificationWarning(message: string, description?: import("react").ReactNode, options?: NotificationOptions): void;
168
+ notificationInfo(message: string, description?: import("react").ReactNode, options?: NotificationOptions): void;
169
+ notificationDestroy(): void;
170
+ version: any;
171
+ useRequest: typeof useRequest;
172
+ GData: {
173
+ [name: string]: any;
174
+ };
175
+ data(key: string, value: any): any;
176
+ getInviteUserId(): any;
177
+ getLocalUserInfo(): UserAuth.UserInfo;
178
+ setLocalUserInfo(data?: {}): {
179
+ id: number;
180
+ sid: string;
181
+ shareId: number;
182
+ nickname: string;
183
+ isLogin: boolean;
184
+ avatarUrl: string;
185
+ userIdKey: string;
186
+ gender: number;
187
+ fromChannel: string;
188
+ weQrUrl: string;
189
+ canWithdraw: number;
190
+ douzhuliId36: string;
191
+ userVip?: {
192
+ [productName: string]: {
193
+ vipLevel: number;
194
+ isVip: boolean;
195
+ expired: number;
196
+ };
197
+ } | undefined;
198
+ };
199
+ getLocalSiteInfo(): Site.BaseInfo;
200
+ };
201
+ export default Tool;