jk-vue-comps 0.2.11 → 0.2.13
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.
- package/dist/chunks/{math-BbxxKXFw.js → math-Dcn-34Qj.js} +1 -1
- package/dist/components/GoogleAuth.d.ts +1 -83
- package/dist/components/GoogleAuth.js +0 -1
- package/dist/components/TelegramAuth.d.ts +1 -88
- package/dist/components/TelegramAuth.js +0 -1
- package/dist/components/index.d.ts +1 -2
- package/dist/components/index.js +0 -1
- package/dist/hooks/index.d.ts +1 -3
- package/dist/hooks/useCopyToClipboard.d.ts +1 -9
- package/dist/hooks/useFormKeypressEnter.d.ts +1 -2
- package/dist/hooks/useMemo.d.ts +1 -2
- package/dist/index.d.ts +1 -226
- package/dist/index.js +1 -1
- package/dist/src/components/GoogleAuth.d.ts +83 -0
- package/dist/src/components/TelegramAuth.d.ts +88 -0
- package/dist/src/components/index.d.ts +2 -0
- package/dist/src/hooks/index.d.ts +3 -0
- package/dist/src/hooks/useCopyToClipboard.d.ts +9 -0
- package/dist/src/hooks/useFormKeypressEnter.d.ts +2 -0
- package/dist/src/hooks/useMemo.d.ts +2 -0
- package/dist/src/index.d.ts +226 -0
- package/dist/src/utils/index.d.ts +55 -0
- package/dist/src/utils/is.d.ts +59 -0
- package/dist/src/utils/lodash.d.ts +39 -0
- package/dist/src/utils/math.d.ts +113 -0
- package/dist/src/utils/timeZone.d.ts +9 -0
- package/dist/src/utils/vuePropTypes.d.ts +17 -0
- package/dist/src/utils/withInstall.d.ts +3 -0
- package/dist/utils/index.d.ts +1 -55
- package/dist/utils/index.js +1 -1
- package/dist/utils/is.d.ts +1 -59
- package/dist/utils/lodash.d.ts +1 -39
- package/dist/utils/lodash.js +1 -4
- package/dist/utils/math.d.ts +1 -113
- package/dist/utils/math.js +1 -1
- package/dist/utils/timeZone.d.ts +1 -9
- package/dist/utils/vuePropTypes.d.ts +1 -17
- package/dist/utils/withInstall.d.ts +1 -3
- package/package.json +7 -7
|
@@ -192,7 +192,7 @@ function d(e) {
|
|
|
192
192
|
return a;
|
|
193
193
|
}
|
|
194
194
|
function n(e, t, n, r) {
|
|
195
|
-
for (var i = 0; n--;) e[n] -= i, i = e[n] < t[n]
|
|
195
|
+
for (var i = 0; n--;) e[n] -= i, i = +(e[n] < t[n]), e[n] = i * r + e[n] - t[n];
|
|
196
196
|
for (; !e[0] && e.length > 1; e.splice(0, 1));
|
|
197
197
|
}
|
|
198
198
|
return function(i, s, c, l, u) {
|
|
@@ -1,83 +1 @@
|
|
|
1
|
-
|
|
2
|
-
/** 跳转谷歌身份检查 */
|
|
3
|
-
export declare function toGoogleAuth(clientId: string, redirectUri: string): void;
|
|
4
|
-
type GetPopupContainerFn = () => HTMLElement | Element;
|
|
5
|
-
declare const _comp_props: {
|
|
6
|
-
clientId: StringConstructor;
|
|
7
|
-
redirectUri: StringConstructor;
|
|
8
|
-
defaultLoad: BooleanConstructor;
|
|
9
|
-
getPopupContainer: {
|
|
10
|
-
type: PropType<GetPopupContainerFn>;
|
|
11
|
-
};
|
|
12
|
-
onCallback: {
|
|
13
|
-
type: PropType<(data: {
|
|
14
|
-
code: string;
|
|
15
|
-
}) => void>;
|
|
16
|
-
};
|
|
17
|
-
onRejectCallback: {
|
|
18
|
-
type: PropType<(error: any) => void>;
|
|
19
|
-
};
|
|
20
|
-
};
|
|
21
|
-
export type GoogleAuthProps = Partial<ExtractPropTypes<typeof _comp_props>>;
|
|
22
|
-
/** 谷歌身份检查 */
|
|
23
|
-
export declare const GoogleAuth: {
|
|
24
|
-
new (...args: any[]): CreateComponentPublicInstanceWithMixins<Readonly<Partial<ExtractPropTypes<{
|
|
25
|
-
clientId: StringConstructor;
|
|
26
|
-
redirectUri: StringConstructor;
|
|
27
|
-
defaultLoad: BooleanConstructor;
|
|
28
|
-
getPopupContainer: {
|
|
29
|
-
type: PropType<GetPopupContainerFn>;
|
|
30
|
-
};
|
|
31
|
-
onCallback: {
|
|
32
|
-
type: PropType<(data: {
|
|
33
|
-
code: string;
|
|
34
|
-
}) => void>;
|
|
35
|
-
};
|
|
36
|
-
onRejectCallback: {
|
|
37
|
-
type: PropType<(error: any) => void>;
|
|
38
|
-
};
|
|
39
|
-
}>>> & Readonly<{}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, PublicProps, {}, false, {}, {}, GlobalComponents, GlobalDirectives, string, {}, any, ComponentProvideOptions, {
|
|
40
|
-
P: {};
|
|
41
|
-
B: {};
|
|
42
|
-
D: {};
|
|
43
|
-
C: {};
|
|
44
|
-
M: {};
|
|
45
|
-
Defaults: {};
|
|
46
|
-
}, Readonly<Partial<ExtractPropTypes<{
|
|
47
|
-
clientId: StringConstructor;
|
|
48
|
-
redirectUri: StringConstructor;
|
|
49
|
-
defaultLoad: BooleanConstructor;
|
|
50
|
-
getPopupContainer: {
|
|
51
|
-
type: PropType<GetPopupContainerFn>;
|
|
52
|
-
};
|
|
53
|
-
onCallback: {
|
|
54
|
-
type: PropType<(data: {
|
|
55
|
-
code: string;
|
|
56
|
-
}) => void>;
|
|
57
|
-
};
|
|
58
|
-
onRejectCallback: {
|
|
59
|
-
type: PropType<(error: any) => void>;
|
|
60
|
-
};
|
|
61
|
-
}>>> & Readonly<{}>, {}, {}, {}, {}, {}>;
|
|
62
|
-
__isFragment?: never;
|
|
63
|
-
__isTeleport?: never;
|
|
64
|
-
__isSuspense?: never;
|
|
65
|
-
} & ComponentOptionsBase<Readonly<Partial<ExtractPropTypes<{
|
|
66
|
-
clientId: StringConstructor;
|
|
67
|
-
redirectUri: StringConstructor;
|
|
68
|
-
defaultLoad: BooleanConstructor;
|
|
69
|
-
getPopupContainer: {
|
|
70
|
-
type: PropType<GetPopupContainerFn>;
|
|
71
|
-
};
|
|
72
|
-
onCallback: {
|
|
73
|
-
type: PropType<(data: {
|
|
74
|
-
code: string;
|
|
75
|
-
}) => void>;
|
|
76
|
-
};
|
|
77
|
-
onRejectCallback: {
|
|
78
|
-
type: PropType<(error: any) => void>;
|
|
79
|
-
};
|
|
80
|
-
}>>> & Readonly<{}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, {}, {}, string, {}, GlobalComponents, GlobalDirectives, string, ComponentProvideOptions> & VNodeProps & AllowedComponentProps & ComponentCustomProps & {
|
|
81
|
-
readonly toGoogleAuth: typeof toGoogleAuth;
|
|
82
|
-
} & Plugin;
|
|
83
|
-
export default GoogleAuth;
|
|
1
|
+
export {}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { isInMobileBrowser as e } from "../utils/is.js";
|
|
2
|
-
import "../chunks/math-BbxxKXFw.js";
|
|
3
2
|
import { withInstall as t } from "../utils/withInstall.js";
|
|
4
3
|
import "../utils/index.js";
|
|
5
4
|
import { computed as n, createVNode as r, defineComponent as i, onMounted as a } from "vue";
|
|
@@ -1,88 +1 @@
|
|
|
1
|
-
|
|
2
|
-
/** 跳转Telegram身份检查 */
|
|
3
|
-
export declare function toTelegramAuth(botId: number, toPath: string): void;
|
|
4
|
-
/** 获取路由中的Telegram身份检查回调参数 */
|
|
5
|
-
export declare function getTelegramAuthUrlParams(): TgUserData | null;
|
|
6
|
-
/** tg用户信息 */
|
|
7
|
-
export interface TgUserData {
|
|
8
|
-
auth_date: number;
|
|
9
|
-
first_name: string;
|
|
10
|
-
hash: string;
|
|
11
|
-
id: number;
|
|
12
|
-
last_name: string;
|
|
13
|
-
photo_url: string;
|
|
14
|
-
username: string;
|
|
15
|
-
}
|
|
16
|
-
type GetPopupContainerFn = () => HTMLElement | Element;
|
|
17
|
-
declare const _comp_props: {
|
|
18
|
-
botId: NumberConstructor;
|
|
19
|
-
toPath: StringConstructor;
|
|
20
|
-
defaultLoad: BooleanConstructor;
|
|
21
|
-
getPopupContainer: {
|
|
22
|
-
type: PropType<GetPopupContainerFn>;
|
|
23
|
-
};
|
|
24
|
-
onCallback: {
|
|
25
|
-
type: PropType<(user: TgUserData) => void>;
|
|
26
|
-
};
|
|
27
|
-
onRejectCallback: {
|
|
28
|
-
type: PropType<() => void>;
|
|
29
|
-
};
|
|
30
|
-
};
|
|
31
|
-
export type TelegramAuthProps = Partial<ExtractPropTypes<typeof _comp_props>>;
|
|
32
|
-
/** Telegram身份检查 */
|
|
33
|
-
export declare const TelegramAuth: {
|
|
34
|
-
new (...args: any[]): CreateComponentPublicInstanceWithMixins<Readonly<Partial<ExtractPropTypes<{
|
|
35
|
-
botId: NumberConstructor;
|
|
36
|
-
toPath: StringConstructor;
|
|
37
|
-
defaultLoad: BooleanConstructor;
|
|
38
|
-
getPopupContainer: {
|
|
39
|
-
type: PropType<GetPopupContainerFn>;
|
|
40
|
-
};
|
|
41
|
-
onCallback: {
|
|
42
|
-
type: PropType<(user: TgUserData) => void>;
|
|
43
|
-
};
|
|
44
|
-
onRejectCallback: {
|
|
45
|
-
type: PropType<() => void>;
|
|
46
|
-
};
|
|
47
|
-
}>>> & Readonly<{}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, PublicProps, {}, false, {}, {}, GlobalComponents, GlobalDirectives, string, {}, any, ComponentProvideOptions, {
|
|
48
|
-
P: {};
|
|
49
|
-
B: {};
|
|
50
|
-
D: {};
|
|
51
|
-
C: {};
|
|
52
|
-
M: {};
|
|
53
|
-
Defaults: {};
|
|
54
|
-
}, Readonly<Partial<ExtractPropTypes<{
|
|
55
|
-
botId: NumberConstructor;
|
|
56
|
-
toPath: StringConstructor;
|
|
57
|
-
defaultLoad: BooleanConstructor;
|
|
58
|
-
getPopupContainer: {
|
|
59
|
-
type: PropType<GetPopupContainerFn>;
|
|
60
|
-
};
|
|
61
|
-
onCallback: {
|
|
62
|
-
type: PropType<(user: TgUserData) => void>;
|
|
63
|
-
};
|
|
64
|
-
onRejectCallback: {
|
|
65
|
-
type: PropType<() => void>;
|
|
66
|
-
};
|
|
67
|
-
}>>> & Readonly<{}>, {}, {}, {}, {}, {}>;
|
|
68
|
-
__isFragment?: never;
|
|
69
|
-
__isTeleport?: never;
|
|
70
|
-
__isSuspense?: never;
|
|
71
|
-
} & ComponentOptionsBase<Readonly<Partial<ExtractPropTypes<{
|
|
72
|
-
botId: NumberConstructor;
|
|
73
|
-
toPath: StringConstructor;
|
|
74
|
-
defaultLoad: BooleanConstructor;
|
|
75
|
-
getPopupContainer: {
|
|
76
|
-
type: PropType<GetPopupContainerFn>;
|
|
77
|
-
};
|
|
78
|
-
onCallback: {
|
|
79
|
-
type: PropType<(user: TgUserData) => void>;
|
|
80
|
-
};
|
|
81
|
-
onRejectCallback: {
|
|
82
|
-
type: PropType<() => void>;
|
|
83
|
-
};
|
|
84
|
-
}>>> & Readonly<{}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, {}, {}, string, {}, GlobalComponents, GlobalDirectives, string, ComponentProvideOptions> & VNodeProps & AllowedComponentProps & ComponentCustomProps & {
|
|
85
|
-
readonly toTelegramAuth: typeof toTelegramAuth;
|
|
86
|
-
readonly getTelegramAuthUrlParams: typeof getTelegramAuthUrlParams;
|
|
87
|
-
} & Plugin;
|
|
88
|
-
export default TelegramAuth;
|
|
1
|
+
export {}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { isInMobileBrowser as e } from "../utils/is.js";
|
|
2
|
-
import "../chunks/math-BbxxKXFw.js";
|
|
3
2
|
import { withInstall as t } from "../utils/withInstall.js";
|
|
4
3
|
import { getWebsiteUrl as n } from "../utils/index.js";
|
|
5
4
|
import { computed as r, createVNode as i, defineComponent as a, onMounted as o } from "vue";
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
export
|
|
2
|
-
export * from './TelegramAuth';
|
|
1
|
+
export {}
|
package/dist/components/index.js
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { t as e } from "../chunks/chunk-cBPL4W67.js";
|
|
2
|
-
import "../chunks/math-BbxxKXFw.js";
|
|
3
2
|
import { GoogleAuth as t, toGoogleAuth as n } from "./GoogleAuth.js";
|
|
4
3
|
import { TelegramAuth as r, getTelegramAuthUrlParams as i, toTelegramAuth as a } from "./TelegramAuth.js";
|
|
5
4
|
//#region src/components/index.ts
|
package/dist/hooks/index.d.ts
CHANGED
|
@@ -1,9 +1 @@
|
|
|
1
|
-
|
|
2
|
-
export declare function useCopyToClipboard(initial?: string): {
|
|
3
|
-
clipboardRef: Ref<string, string>;
|
|
4
|
-
isSuccessRef: Ref<boolean, boolean>;
|
|
5
|
-
copiedRef: Ref<boolean, boolean>;
|
|
6
|
-
};
|
|
7
|
-
export declare function copyTextToClipboard(input: string, { target }?: {
|
|
8
|
-
target?: HTMLElement;
|
|
9
|
-
}): boolean;
|
|
1
|
+
export {}
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
export declare function useFormKeypressEnter<T extends (...args: any[]) => any, L extends WatchSource<boolean>>(fn: T, loading: L): (...args: any[]) => any;
|
|
1
|
+
export {}
|
package/dist/hooks/useMemo.d.ts
CHANGED
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
export declare function useMemo<T>(getValue: () => T, condition: (WatchSource<unknown> | object)[], shouldUpdate?: (prev: any[], next: any[]) => boolean): Ref<T, T>;
|
|
1
|
+
export {}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,226 +1 @@
|
|
|
1
|
-
|
|
2
|
-
import { BigNumber } from 'bignumber.js';
|
|
3
|
-
import { default as __DTS_DEFAULT_0__ } from './utils/vuePropTypes';
|
|
4
|
-
import * as Comps from './components';
|
|
5
|
-
import * as Hooks from './hooks';
|
|
6
|
-
import * as Utils from './utils';
|
|
7
|
-
export * from './components';
|
|
8
|
-
export * from './hooks';
|
|
9
|
-
export * from './utils';
|
|
10
|
-
declare const JKVUEComps: {
|
|
11
|
-
Comps: typeof Comps;
|
|
12
|
-
Hooks: typeof Hooks;
|
|
13
|
-
Utils: typeof Utils;
|
|
14
|
-
evalPro(str: string): any;
|
|
15
|
-
filterInputNum(eventVal: string | number, type?: "int" | "float", maxDecimal?: number): string;
|
|
16
|
-
generateFilterInputNumFn<T extends Recordable, K extends keyof T>(obj: T, key: K, fn?: () => void, type?: "float" | "int", maxDecimal?: number): (e: ChangeEvent) => void;
|
|
17
|
-
renderHtmlStr(html: string): string | VNode<RendererNode, RendererElement, {
|
|
18
|
-
[key: string]: any;
|
|
19
|
-
}>;
|
|
20
|
-
getWebsiteUrl(): string;
|
|
21
|
-
getRouterParams(): Recordable<any> | undefined;
|
|
22
|
-
removeWhitespace(str: any): string;
|
|
23
|
-
deepMerge<T = any>(src?: any, target?: any): T;
|
|
24
|
-
desensitization(str?: string | number, number?: number, { showPrefix, showSuffix, middleStr }?: {
|
|
25
|
-
showPrefix?: boolean;
|
|
26
|
-
showSuffix?: boolean;
|
|
27
|
-
middleStr?: string;
|
|
28
|
-
}): string | undefined;
|
|
29
|
-
toStyleUnit(str?: string | number | null, unit?: string): string | undefined;
|
|
30
|
-
toStyleObject(style?: string | Recordable | null): Recordable<any>;
|
|
31
|
-
is(val: unknown, type: string): boolean;
|
|
32
|
-
isDef<T = unknown>(val?: T): val is T;
|
|
33
|
-
isUnDef<T = unknown>(val?: T): val is T;
|
|
34
|
-
isObject(val: any): val is Record<any, any>;
|
|
35
|
-
isDate(val: unknown): val is Date;
|
|
36
|
-
isNull(val: unknown): val is null;
|
|
37
|
-
isNullAndUnDef(val: unknown): val is null | undefined;
|
|
38
|
-
isNullOrUnDef(val: unknown): val is null | undefined;
|
|
39
|
-
isNumber(val: unknown): val is number;
|
|
40
|
-
isString(val: unknown): val is string;
|
|
41
|
-
isFunction(val: unknown): val is (...args: any[]) => any;
|
|
42
|
-
isBoolean(val: unknown): val is boolean;
|
|
43
|
-
isRegExp(val: unknown): val is RegExp;
|
|
44
|
-
isArray(val: any): val is Array<any>;
|
|
45
|
-
isEmpty<T = unknown>(val: T): val is T;
|
|
46
|
-
isPromise<T = any>(val: unknown): val is Promise<T>;
|
|
47
|
-
isPromiseLink<T>(it: T | PromiseLike<T>): it is PromiseLike<T>;
|
|
48
|
-
isWindow(val: any): val is Window;
|
|
49
|
-
isElement(val: unknown): val is Element;
|
|
50
|
-
isMap(val: unknown): val is Map<any, any>;
|
|
51
|
-
isServer(): boolean;
|
|
52
|
-
isClient(): boolean;
|
|
53
|
-
isUrl(path: string): boolean;
|
|
54
|
-
isIp(ip: string): boolean;
|
|
55
|
-
isEmail(v: any): boolean;
|
|
56
|
-
isValidPhoneNumber(phoneNumber: string): boolean;
|
|
57
|
-
isInMobileBrowser(): false | RegExpMatchArray | null;
|
|
58
|
-
isZhLang(lang: string): boolean;
|
|
59
|
-
isEdgeBrowser(): boolean;
|
|
60
|
-
isHtmlStr(str: string): boolean;
|
|
61
|
-
helper(val: Utils.BigNumValType): Utils.BigNumObj;
|
|
62
|
-
isBool(val: any): val is boolean;
|
|
63
|
-
isBigNum(val: any): val is Utils.BigNumObj;
|
|
64
|
-
isNum(val: any): val is number;
|
|
65
|
-
isNanValue(val: any): boolean;
|
|
66
|
-
isInt(val: any): boolean;
|
|
67
|
-
isGreaterThan(num1: Utils.BigNumVal, num2: Utils.BigNumVal): boolean;
|
|
68
|
-
isLessThan(num1: Utils.BigNumVal, num2: Utils.BigNumVal): boolean;
|
|
69
|
-
isEqualTo(num1: Utils.BigNumVal, num2: Utils.BigNumVal): boolean;
|
|
70
|
-
isGreaterThanOrEqualTo(num1: Utils.BigNumVal, num2: Utils.BigNumVal): boolean;
|
|
71
|
-
isLessThanOrEqualTo(num1: Utils.BigNumVal, num2: Utils.BigNumVal): boolean;
|
|
72
|
-
toBigNum(val: Utils.BigNumValType): BigNumber;
|
|
73
|
-
toNum(val: Utils.BigNumValType): number;
|
|
74
|
-
toInt(val: Utils.BigNumValType, isUp?: boolean): number;
|
|
75
|
-
toString(val: Utils.BigNumValType): string;
|
|
76
|
-
toDecimalPlaces(val: Utils.BigNumValType, decimal?: number, isUp?: boolean): number;
|
|
77
|
-
toLocaleString(val: Utils.BigNumValType): string;
|
|
78
|
-
add(...vals: Utils.BigNumValType[]): number;
|
|
79
|
-
subtract(...vals: Utils.BigNumValType[]): number;
|
|
80
|
-
multiply(...vals: Utils.BigNumValType[]): number;
|
|
81
|
-
divide(...vals: Utils.BigNumValType[]): number;
|
|
82
|
-
power(base: Utils.BigNumValType, exponent: Utils.BigNumValType): number;
|
|
83
|
-
formatRate(val: Utils.BigNumValType, unit?: string): string;
|
|
84
|
-
unFormatRate(val: Utils.BigNumValType): number;
|
|
85
|
-
DOWN: 1;
|
|
86
|
-
UP: 0;
|
|
87
|
-
BigNumber: BigNumber;
|
|
88
|
-
gt: typeof Utils.isGreaterThan;
|
|
89
|
-
gte: typeof Utils.isGreaterThanOrEqualTo;
|
|
90
|
-
lt: typeof Utils.isLessThan;
|
|
91
|
-
lte: typeof Utils.isLessThanOrEqualTo;
|
|
92
|
-
eq: typeof Utils.isEqualTo;
|
|
93
|
-
isNan: typeof Utils.isNanValue;
|
|
94
|
-
propTypes: __DTS_DEFAULT_0__;
|
|
95
|
-
timeZoneOptions: Utils.TimeZoneItem[];
|
|
96
|
-
withInstall<T>(component: T, alias?: string): T & Plugin;
|
|
97
|
-
useCopyToClipboard(initial?: string): {
|
|
98
|
-
clipboardRef: Ref<string, string>;
|
|
99
|
-
isSuccessRef: Ref<boolean, boolean>;
|
|
100
|
-
copiedRef: Ref<boolean, boolean>;
|
|
101
|
-
};
|
|
102
|
-
copyTextToClipboard(input: string, { target }?: {
|
|
103
|
-
target?: HTMLElement;
|
|
104
|
-
}): boolean;
|
|
105
|
-
useFormKeypressEnter<T extends (...args: any[]) => any, L extends WatchSource<boolean>>(fn: T, loading: L): (...args: any[]) => any;
|
|
106
|
-
useMemo<T>(getValue: () => T, condition: ( WatchSource<unknown> | object)[], shouldUpdate?: (prev: any[], next: any[]) => boolean): Ref<T, T>;
|
|
107
|
-
toGoogleAuth(clientId: string, redirectUri: string): void;
|
|
108
|
-
GoogleAuth: {
|
|
109
|
-
new (...args: any[]): CreateComponentPublicInstanceWithMixins<Readonly<Partial< ExtractPropTypes<{
|
|
110
|
-
clientId: StringConstructor;
|
|
111
|
-
redirectUri: StringConstructor;
|
|
112
|
-
defaultLoad: BooleanConstructor;
|
|
113
|
-
getPopupContainer: {
|
|
114
|
-
type: PropType<() => HTMLElement | Element>;
|
|
115
|
-
};
|
|
116
|
-
onCallback: {
|
|
117
|
-
type: PropType<(data: {
|
|
118
|
-
code: string;
|
|
119
|
-
}) => void>;
|
|
120
|
-
};
|
|
121
|
-
onRejectCallback: {
|
|
122
|
-
type: PropType<(error: any) => void>;
|
|
123
|
-
};
|
|
124
|
-
}>>> & Readonly<{}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, PublicProps, {}, false, {}, {}, GlobalComponents, GlobalDirectives, string, {}, any, ComponentProvideOptions, {
|
|
125
|
-
P: {};
|
|
126
|
-
B: {};
|
|
127
|
-
D: {};
|
|
128
|
-
C: {};
|
|
129
|
-
M: {};
|
|
130
|
-
Defaults: {};
|
|
131
|
-
}, Readonly<Partial< ExtractPropTypes<{
|
|
132
|
-
clientId: StringConstructor;
|
|
133
|
-
redirectUri: StringConstructor;
|
|
134
|
-
defaultLoad: BooleanConstructor;
|
|
135
|
-
getPopupContainer: {
|
|
136
|
-
type: PropType<() => HTMLElement | Element>;
|
|
137
|
-
};
|
|
138
|
-
onCallback: {
|
|
139
|
-
type: PropType<(data: {
|
|
140
|
-
code: string;
|
|
141
|
-
}) => void>;
|
|
142
|
-
};
|
|
143
|
-
onRejectCallback: {
|
|
144
|
-
type: PropType<(error: any) => void>;
|
|
145
|
-
};
|
|
146
|
-
}>>> & Readonly<{}>, {}, {}, {}, {}, {}>;
|
|
147
|
-
__isFragment?: never;
|
|
148
|
-
__isTeleport?: never;
|
|
149
|
-
__isSuspense?: never;
|
|
150
|
-
} & ComponentOptionsBase<Readonly<Partial< ExtractPropTypes<{
|
|
151
|
-
clientId: StringConstructor;
|
|
152
|
-
redirectUri: StringConstructor;
|
|
153
|
-
defaultLoad: BooleanConstructor;
|
|
154
|
-
getPopupContainer: {
|
|
155
|
-
type: PropType<() => HTMLElement | Element>;
|
|
156
|
-
};
|
|
157
|
-
onCallback: {
|
|
158
|
-
type: PropType<(data: {
|
|
159
|
-
code: string;
|
|
160
|
-
}) => void>;
|
|
161
|
-
};
|
|
162
|
-
onRejectCallback: {
|
|
163
|
-
type: PropType<(error: any) => void>;
|
|
164
|
-
};
|
|
165
|
-
}>>> & Readonly<{}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, {}, {}, string, {}, GlobalComponents, GlobalDirectives, string, ComponentProvideOptions> & VNodeProps & AllowedComponentProps & ComponentCustomProps & {
|
|
166
|
-
readonly toGoogleAuth: typeof Comps.toGoogleAuth;
|
|
167
|
-
} & Plugin;
|
|
168
|
-
toTelegramAuth(botId: number, toPath: string): void;
|
|
169
|
-
getTelegramAuthUrlParams(): Comps.TgUserData | null;
|
|
170
|
-
TelegramAuth: {
|
|
171
|
-
new (...args: any[]): CreateComponentPublicInstanceWithMixins<Readonly<Partial< ExtractPropTypes<{
|
|
172
|
-
botId: NumberConstructor;
|
|
173
|
-
toPath: StringConstructor;
|
|
174
|
-
defaultLoad: BooleanConstructor;
|
|
175
|
-
getPopupContainer: {
|
|
176
|
-
type: PropType<() => HTMLElement | Element>;
|
|
177
|
-
};
|
|
178
|
-
onCallback: {
|
|
179
|
-
type: PropType<(user: Comps.TgUserData) => void>;
|
|
180
|
-
};
|
|
181
|
-
onRejectCallback: {
|
|
182
|
-
type: PropType<() => void>;
|
|
183
|
-
};
|
|
184
|
-
}>>> & Readonly<{}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, PublicProps, {}, false, {}, {}, GlobalComponents, GlobalDirectives, string, {}, any, ComponentProvideOptions, {
|
|
185
|
-
P: {};
|
|
186
|
-
B: {};
|
|
187
|
-
D: {};
|
|
188
|
-
C: {};
|
|
189
|
-
M: {};
|
|
190
|
-
Defaults: {};
|
|
191
|
-
}, Readonly<Partial< ExtractPropTypes<{
|
|
192
|
-
botId: NumberConstructor;
|
|
193
|
-
toPath: StringConstructor;
|
|
194
|
-
defaultLoad: BooleanConstructor;
|
|
195
|
-
getPopupContainer: {
|
|
196
|
-
type: PropType<() => HTMLElement | Element>;
|
|
197
|
-
};
|
|
198
|
-
onCallback: {
|
|
199
|
-
type: PropType<(user: Comps.TgUserData) => void>;
|
|
200
|
-
};
|
|
201
|
-
onRejectCallback: {
|
|
202
|
-
type: PropType<() => void>;
|
|
203
|
-
};
|
|
204
|
-
}>>> & Readonly<{}>, {}, {}, {}, {}, {}>;
|
|
205
|
-
__isFragment?: never;
|
|
206
|
-
__isTeleport?: never;
|
|
207
|
-
__isSuspense?: never;
|
|
208
|
-
} & ComponentOptionsBase<Readonly<Partial< ExtractPropTypes<{
|
|
209
|
-
botId: NumberConstructor;
|
|
210
|
-
toPath: StringConstructor;
|
|
211
|
-
defaultLoad: BooleanConstructor;
|
|
212
|
-
getPopupContainer: {
|
|
213
|
-
type: PropType<() => HTMLElement | Element>;
|
|
214
|
-
};
|
|
215
|
-
onCallback: {
|
|
216
|
-
type: PropType<(user: Comps.TgUserData) => void>;
|
|
217
|
-
};
|
|
218
|
-
onRejectCallback: {
|
|
219
|
-
type: PropType<() => void>;
|
|
220
|
-
};
|
|
221
|
-
}>>> & Readonly<{}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, {}, {}, string, {}, GlobalComponents, GlobalDirectives, string, ComponentProvideOptions> & VNodeProps & AllowedComponentProps & ComponentCustomProps & {
|
|
222
|
-
readonly toTelegramAuth: typeof Comps.toTelegramAuth;
|
|
223
|
-
readonly getTelegramAuthUrlParams: typeof Comps.getTelegramAuthUrlParams;
|
|
224
|
-
} & Plugin;
|
|
225
|
-
};
|
|
226
|
-
export default JKVUEComps;
|
|
1
|
+
export {}
|
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { is as ee, isArray as e, isBoolean as te, isClient as ne, isDate as re, isDef as t, isEdgeBrowser as n, isElement as r, isEmail as i, isEmpty as a, isFunction as o, isHtmlStr as s, isInMobileBrowser as c, isIp as l, isMap as u, isNull as d, isNullAndUnDef as f, isNullOrUnDef as p, isNumber as m, isObject as h, isPromise as g, isPromiseLink as _, isRegExp as v, isServer as y, isString as b, isUnDef as x, isUrl as S, isValidPhoneNumber as C, isWindow as w, isZhLang as T } from "./utils/is.js";
|
|
2
|
-
import { A as E, C as D, D as O, E as k, M as A, N as j, O as M, S as N, T as P, _ as F, a as I, b as L, c as R, d as z, f as B, g as V, h as H, i as U, j as W, k as G, l as K, m as q, n as J, o as Y, p as X, r as ie, s as ae, t as oe, u as se, v as ce, w as le, x as ue, y as de } from "./chunks/math-
|
|
2
|
+
import { A as E, C as D, D as O, E as k, M as A, N as j, O as M, S as N, T as P, _ as F, a as I, b as L, c as R, d as z, f as B, g as V, h as H, i as U, j as W, k as G, l as K, m as q, n as J, o as Y, p as X, r as ie, s as ae, t as oe, u as se, v as ce, w as le, x as ue, y as de } from "./chunks/math-Dcn-34Qj.js";
|
|
3
3
|
import { propTypes as fe } from "./utils/vuePropTypes.js";
|
|
4
4
|
import { timeZoneOptions as pe } from "./utils/timeZone.js";
|
|
5
5
|
import { withInstall as me } from "./utils/withInstall.js";
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import { PropType, ExtractPropTypes, CreateComponentPublicInstanceWithMixins, ComponentOptionsMixin, PublicProps, GlobalComponents, GlobalDirectives, ComponentProvideOptions, ComponentOptionsBase, VNodeProps, AllowedComponentProps, ComponentCustomProps, Plugin } from 'vue';
|
|
2
|
+
/** 跳转谷歌身份检查 */
|
|
3
|
+
export declare function toGoogleAuth(clientId: string, redirectUri: string): void;
|
|
4
|
+
type GetPopupContainerFn = () => HTMLElement | Element;
|
|
5
|
+
declare const _comp_props: {
|
|
6
|
+
clientId: StringConstructor;
|
|
7
|
+
redirectUri: StringConstructor;
|
|
8
|
+
defaultLoad: BooleanConstructor;
|
|
9
|
+
getPopupContainer: {
|
|
10
|
+
type: PropType<GetPopupContainerFn>;
|
|
11
|
+
};
|
|
12
|
+
onCallback: {
|
|
13
|
+
type: PropType<(data: {
|
|
14
|
+
code: string;
|
|
15
|
+
}) => void>;
|
|
16
|
+
};
|
|
17
|
+
onRejectCallback: {
|
|
18
|
+
type: PropType<(error: any) => void>;
|
|
19
|
+
};
|
|
20
|
+
};
|
|
21
|
+
export type GoogleAuthProps = Partial<ExtractPropTypes<typeof _comp_props>>;
|
|
22
|
+
/** 谷歌身份检查 */
|
|
23
|
+
export declare const GoogleAuth: {
|
|
24
|
+
new (...args: any[]): CreateComponentPublicInstanceWithMixins<Readonly<Partial<ExtractPropTypes<{
|
|
25
|
+
clientId: StringConstructor;
|
|
26
|
+
redirectUri: StringConstructor;
|
|
27
|
+
defaultLoad: BooleanConstructor;
|
|
28
|
+
getPopupContainer: {
|
|
29
|
+
type: PropType<GetPopupContainerFn>;
|
|
30
|
+
};
|
|
31
|
+
onCallback: {
|
|
32
|
+
type: PropType<(data: {
|
|
33
|
+
code: string;
|
|
34
|
+
}) => void>;
|
|
35
|
+
};
|
|
36
|
+
onRejectCallback: {
|
|
37
|
+
type: PropType<(error: any) => void>;
|
|
38
|
+
};
|
|
39
|
+
}>>> & Readonly<{}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, PublicProps, {}, false, {}, {}, GlobalComponents, GlobalDirectives, string, {}, any, ComponentProvideOptions, {
|
|
40
|
+
P: {};
|
|
41
|
+
B: {};
|
|
42
|
+
D: {};
|
|
43
|
+
C: {};
|
|
44
|
+
M: {};
|
|
45
|
+
Defaults: {};
|
|
46
|
+
}, Readonly<Partial<ExtractPropTypes<{
|
|
47
|
+
clientId: StringConstructor;
|
|
48
|
+
redirectUri: StringConstructor;
|
|
49
|
+
defaultLoad: BooleanConstructor;
|
|
50
|
+
getPopupContainer: {
|
|
51
|
+
type: PropType<GetPopupContainerFn>;
|
|
52
|
+
};
|
|
53
|
+
onCallback: {
|
|
54
|
+
type: PropType<(data: {
|
|
55
|
+
code: string;
|
|
56
|
+
}) => void>;
|
|
57
|
+
};
|
|
58
|
+
onRejectCallback: {
|
|
59
|
+
type: PropType<(error: any) => void>;
|
|
60
|
+
};
|
|
61
|
+
}>>> & Readonly<{}>, {}, {}, {}, {}, {}>;
|
|
62
|
+
__isFragment?: never;
|
|
63
|
+
__isTeleport?: never;
|
|
64
|
+
__isSuspense?: never;
|
|
65
|
+
} & ComponentOptionsBase<Readonly<Partial<ExtractPropTypes<{
|
|
66
|
+
clientId: StringConstructor;
|
|
67
|
+
redirectUri: StringConstructor;
|
|
68
|
+
defaultLoad: BooleanConstructor;
|
|
69
|
+
getPopupContainer: {
|
|
70
|
+
type: PropType<GetPopupContainerFn>;
|
|
71
|
+
};
|
|
72
|
+
onCallback: {
|
|
73
|
+
type: PropType<(data: {
|
|
74
|
+
code: string;
|
|
75
|
+
}) => void>;
|
|
76
|
+
};
|
|
77
|
+
onRejectCallback: {
|
|
78
|
+
type: PropType<(error: any) => void>;
|
|
79
|
+
};
|
|
80
|
+
}>>> & Readonly<{}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, {}, {}, string, {}, GlobalComponents, GlobalDirectives, string, ComponentProvideOptions> & VNodeProps & AllowedComponentProps & ComponentCustomProps & {
|
|
81
|
+
readonly toGoogleAuth: typeof toGoogleAuth;
|
|
82
|
+
} & Plugin;
|
|
83
|
+
export default GoogleAuth;
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
import { PropType, ExtractPropTypes, CreateComponentPublicInstanceWithMixins, ComponentOptionsMixin, PublicProps, GlobalComponents, GlobalDirectives, ComponentProvideOptions, ComponentOptionsBase, VNodeProps, AllowedComponentProps, ComponentCustomProps, Plugin } from 'vue';
|
|
2
|
+
/** 跳转Telegram身份检查 */
|
|
3
|
+
export declare function toTelegramAuth(botId: number, toPath: string): void;
|
|
4
|
+
/** 获取路由中的Telegram身份检查回调参数 */
|
|
5
|
+
export declare function getTelegramAuthUrlParams(): TgUserData | null;
|
|
6
|
+
/** tg用户信息 */
|
|
7
|
+
export interface TgUserData {
|
|
8
|
+
auth_date: number;
|
|
9
|
+
first_name: string;
|
|
10
|
+
hash: string;
|
|
11
|
+
id: number;
|
|
12
|
+
last_name: string;
|
|
13
|
+
photo_url: string;
|
|
14
|
+
username: string;
|
|
15
|
+
}
|
|
16
|
+
type GetPopupContainerFn = () => HTMLElement | Element;
|
|
17
|
+
declare const _comp_props: {
|
|
18
|
+
botId: NumberConstructor;
|
|
19
|
+
toPath: StringConstructor;
|
|
20
|
+
defaultLoad: BooleanConstructor;
|
|
21
|
+
getPopupContainer: {
|
|
22
|
+
type: PropType<GetPopupContainerFn>;
|
|
23
|
+
};
|
|
24
|
+
onCallback: {
|
|
25
|
+
type: PropType<(user: TgUserData) => void>;
|
|
26
|
+
};
|
|
27
|
+
onRejectCallback: {
|
|
28
|
+
type: PropType<() => void>;
|
|
29
|
+
};
|
|
30
|
+
};
|
|
31
|
+
export type TelegramAuthProps = Partial<ExtractPropTypes<typeof _comp_props>>;
|
|
32
|
+
/** Telegram身份检查 */
|
|
33
|
+
export declare const TelegramAuth: {
|
|
34
|
+
new (...args: any[]): CreateComponentPublicInstanceWithMixins<Readonly<Partial<ExtractPropTypes<{
|
|
35
|
+
botId: NumberConstructor;
|
|
36
|
+
toPath: StringConstructor;
|
|
37
|
+
defaultLoad: BooleanConstructor;
|
|
38
|
+
getPopupContainer: {
|
|
39
|
+
type: PropType<GetPopupContainerFn>;
|
|
40
|
+
};
|
|
41
|
+
onCallback: {
|
|
42
|
+
type: PropType<(user: TgUserData) => void>;
|
|
43
|
+
};
|
|
44
|
+
onRejectCallback: {
|
|
45
|
+
type: PropType<() => void>;
|
|
46
|
+
};
|
|
47
|
+
}>>> & Readonly<{}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, PublicProps, {}, false, {}, {}, GlobalComponents, GlobalDirectives, string, {}, any, ComponentProvideOptions, {
|
|
48
|
+
P: {};
|
|
49
|
+
B: {};
|
|
50
|
+
D: {};
|
|
51
|
+
C: {};
|
|
52
|
+
M: {};
|
|
53
|
+
Defaults: {};
|
|
54
|
+
}, Readonly<Partial<ExtractPropTypes<{
|
|
55
|
+
botId: NumberConstructor;
|
|
56
|
+
toPath: StringConstructor;
|
|
57
|
+
defaultLoad: BooleanConstructor;
|
|
58
|
+
getPopupContainer: {
|
|
59
|
+
type: PropType<GetPopupContainerFn>;
|
|
60
|
+
};
|
|
61
|
+
onCallback: {
|
|
62
|
+
type: PropType<(user: TgUserData) => void>;
|
|
63
|
+
};
|
|
64
|
+
onRejectCallback: {
|
|
65
|
+
type: PropType<() => void>;
|
|
66
|
+
};
|
|
67
|
+
}>>> & Readonly<{}>, {}, {}, {}, {}, {}>;
|
|
68
|
+
__isFragment?: never;
|
|
69
|
+
__isTeleport?: never;
|
|
70
|
+
__isSuspense?: never;
|
|
71
|
+
} & ComponentOptionsBase<Readonly<Partial<ExtractPropTypes<{
|
|
72
|
+
botId: NumberConstructor;
|
|
73
|
+
toPath: StringConstructor;
|
|
74
|
+
defaultLoad: BooleanConstructor;
|
|
75
|
+
getPopupContainer: {
|
|
76
|
+
type: PropType<GetPopupContainerFn>;
|
|
77
|
+
};
|
|
78
|
+
onCallback: {
|
|
79
|
+
type: PropType<(user: TgUserData) => void>;
|
|
80
|
+
};
|
|
81
|
+
onRejectCallback: {
|
|
82
|
+
type: PropType<() => void>;
|
|
83
|
+
};
|
|
84
|
+
}>>> & Readonly<{}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, {}, {}, string, {}, GlobalComponents, GlobalDirectives, string, ComponentProvideOptions> & VNodeProps & AllowedComponentProps & ComponentCustomProps & {
|
|
85
|
+
readonly toTelegramAuth: typeof toTelegramAuth;
|
|
86
|
+
readonly getTelegramAuthUrlParams: typeof getTelegramAuthUrlParams;
|
|
87
|
+
} & Plugin;
|
|
88
|
+
export default TelegramAuth;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Ref } from 'vue';
|
|
2
|
+
export declare function useCopyToClipboard(initial?: string): {
|
|
3
|
+
clipboardRef: Ref<string, string>;
|
|
4
|
+
isSuccessRef: Ref<boolean, boolean>;
|
|
5
|
+
copiedRef: Ref<boolean, boolean>;
|
|
6
|
+
};
|
|
7
|
+
export declare function copyTextToClipboard(input: string, { target }?: {
|
|
8
|
+
target?: HTMLElement;
|
|
9
|
+
}): boolean;
|