@pubinfo/module-auth 2.0.0-rc.2 → 2.0.0-rc.4

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.
@@ -0,0 +1,15 @@
1
+ export declare const LoginWithFourA: import('../../../../../node_modules/.pnpm/vue@3.5.17_typescript@5.8.3/node_modules/vue').DefineComponent<globalThis.ExtractPropTypes<{
2
+ color: {
3
+ type: StringConstructor;
4
+ default: string;
5
+ };
6
+ }>, () => globalThis.VNode<import('../../../../../node_modules/.pnpm/vue@3.5.17_typescript@5.8.3/node_modules/vue').RendererNode, import('../../../../../node_modules/.pnpm/vue@3.5.17_typescript@5.8.3/node_modules/vue').RendererElement, {
7
+ [key: string]: any;
8
+ }>, {}, {}, {}, import('../../../../../node_modules/.pnpm/vue@3.5.17_typescript@5.8.3/node_modules/vue').ComponentOptionsMixin, import('../../../../../node_modules/.pnpm/vue@3.5.17_typescript@5.8.3/node_modules/vue').ComponentOptionsMixin, {}, string, import('../../../../../node_modules/.pnpm/vue@3.5.17_typescript@5.8.3/node_modules/vue').PublicProps, Readonly<globalThis.ExtractPropTypes<{
9
+ color: {
10
+ type: StringConstructor;
11
+ default: string;
12
+ };
13
+ }>> & Readonly<{}>, {
14
+ color: string;
15
+ }, {}, {}, {}, string, import('../../../../../node_modules/.pnpm/vue@3.5.17_typescript@5.8.3/node_modules/vue').ComponentProvideOptions, true, {}, any>;
@@ -0,0 +1,11 @@
1
+ export declare const RedirectLogin: import('../../../../../node_modules/.pnpm/vue@3.5.17_typescript@5.8.3/node_modules/vue').DefineComponent<globalThis.ExtractPropTypes<{
2
+ id: StringConstructor;
3
+ src: StringConstructor;
4
+ color: StringConstructor;
5
+ }>, () => globalThis.VNode<import('../../../../../node_modules/.pnpm/vue@3.5.17_typescript@5.8.3/node_modules/vue').RendererNode, import('../../../../../node_modules/.pnpm/vue@3.5.17_typescript@5.8.3/node_modules/vue').RendererElement, {
6
+ [key: string]: any;
7
+ }>, {}, {}, {}, import('../../../../../node_modules/.pnpm/vue@3.5.17_typescript@5.8.3/node_modules/vue').ComponentOptionsMixin, import('../../../../../node_modules/.pnpm/vue@3.5.17_typescript@5.8.3/node_modules/vue').ComponentOptionsMixin, {}, string, import('../../../../../node_modules/.pnpm/vue@3.5.17_typescript@5.8.3/node_modules/vue').PublicProps, Readonly<globalThis.ExtractPropTypes<{
8
+ id: StringConstructor;
9
+ src: StringConstructor;
10
+ color: StringConstructor;
11
+ }>> & Readonly<{}>, {}, {}, {}, {}, string, import('../../../../../node_modules/.pnpm/vue@3.5.17_typescript@5.8.3/node_modules/vue').ComponentProvideOptions, true, {}, any>;
@@ -0,0 +1,3 @@
1
+ import { InternalContext } from './interface';
2
+ import { createContext } from 'pubinfo';
3
+ export declare const ctx: ReturnType<typeof createContext<InternalContext>>;
package/dist/core.d.ts ADDED
@@ -0,0 +1,30 @@
1
+ import { Recordable, ThirdParty } from './interface';
2
+ /**
3
+ * 获取指定的 `Provider`
4
+ * @param id
5
+ */
6
+ export declare function getProvider(id?: ThirdParty): import('./interface').ProviderConfig;
7
+ /**
8
+ * 前往登录
9
+ * @param id 唯一值
10
+ * @param options 登录时需要传递的参数
11
+ */
12
+ export declare function signIn(id: ThirdParty, options?: Recordable): Promise<any>;
13
+ /**
14
+ * 生成二维码
15
+ * @param id 第三方的唯一值
16
+ * @param options 生成二维码需要传递的参数
17
+ * @param options.id `getElementById`中指定的`id`
18
+ */
19
+ export declare function renderQRCode(id: ThirdParty, options: {
20
+ id: string;
21
+ } & Recordable): void;
22
+ /**
23
+ * 认证
24
+ * @param id 第三方的唯一值
25
+ */
26
+ export declare function authentication(id: ThirdParty): Promise<any>;
27
+ /**
28
+ * 重定向至统一登录页
29
+ */
30
+ export declare function redirect(): void;
package/dist/index.d.ts CHANGED
@@ -1,34 +1,6 @@
1
- import { AuthOptions, Authorization, Fn, FnApi, InternalContext, ProviderConfig, ProviderUserConfig, Recordable, ThirdParty } from "./interface-CqwWb8Fb.js";
2
- import { ModuleOptions } from "pubinfo";
3
-
4
- //#region src/core.d.ts
5
-
6
- /**
7
- * 前往登录
8
- * @param id 唯一值
9
- * @param options 登录时需要传递的参数
10
- */
11
- declare function signIn(id: ThirdParty, options?: Recordable): Promise<any>;
12
- /**
13
- * 生成二维码
14
- * @param id 第三方的唯一值
15
- * @param options 生成二维码需要传递的参数
16
- * @param options.id `getElementById`中指定的`id`
17
- */
18
- declare function renderQRCode(id: ThirdParty, options: {
19
- id: string;
20
- } & Recordable): void;
21
- /**
22
- * 认证
23
- * @param id 第三方的唯一值
24
- */
25
- declare function authentication(id: ThirdParty): Promise<any>;
26
- /**
27
- * 重定向至统一登录页
28
- */
29
- declare function redirect(): void;
30
- //#endregion
31
- //#region src/index.d.ts
32
- declare function auth(options: AuthOptions): ModuleOptions;
33
- //#endregion
34
- export { AuthOptions, Authorization, Fn, FnApi, InternalContext, ProviderConfig, ProviderUserConfig, Recordable, ThirdParty, auth, authentication, redirect, renderQRCode, signIn };
1
+ import { ModuleOptions } from 'pubinfo';
2
+ import { AuthOptions } from './interface';
3
+ export declare function auth(options: AuthOptions): ModuleOptions;
4
+ export { LoginWithFourA } from './components/LoginWithFourA';
5
+ export { authentication, redirect, renderQRCode, signIn, } from './core';
6
+ export * from './interface';