@banmao/blocks 0.0.1-alpha.0 → 0.0.1-alpha.10
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/README.md +16 -37
- package/dist/components/Login/index.d.ts +3 -0
- package/dist/components/Login/src/components/LoginForm.d.ts +70 -0
- package/dist/components/Login/src/index.d.ts +94 -0
- package/dist/components/Login/src/types.d.ts +110 -0
- package/dist/components/index.d.ts +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.css +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.js +246 -196
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
# @banmao/
|
|
1
|
+
# @banmao/blocks
|
|
2
2
|
|
|
3
|
-
基于 Naive UI
|
|
3
|
+
基于 Naive UI 封装的登录组件。
|
|
4
4
|
|
|
5
5
|
## 特性
|
|
6
6
|
|
|
@@ -12,52 +12,31 @@
|
|
|
12
12
|
## 安装
|
|
13
13
|
|
|
14
14
|
```bash
|
|
15
|
-
# 安装
|
|
16
|
-
pnpm add
|
|
17
|
-
|
|
18
|
-
# 安装 @banmao/procomponent
|
|
19
|
-
pnpm add @banmao/procomponent
|
|
15
|
+
# 安装 @banmao/blocks
|
|
16
|
+
pnpm add @banmao/blocks
|
|
20
17
|
```
|
|
21
18
|
|
|
22
19
|
## 使用
|
|
23
20
|
|
|
24
|
-
```
|
|
25
|
-
|
|
26
|
-
import {
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
const app = createApp()
|
|
35
|
-
|
|
36
|
-
// 注册需要使用的组件
|
|
37
|
-
app.use(ProLayout)
|
|
38
|
-
app.use(ProTable)
|
|
39
|
-
app.use(ProForm)
|
|
40
|
-
app.use(DrawerForm)
|
|
41
|
-
app.use(ModalForm)
|
|
21
|
+
```vue
|
|
22
|
+
<script setup lang="ts">
|
|
23
|
+
import { Login } from '@banmao/blocks'
|
|
24
|
+
|
|
25
|
+
</script>
|
|
26
|
+
|
|
27
|
+
<template>
|
|
28
|
+
<Login />
|
|
29
|
+
</template>
|
|
42
30
|
```
|
|
43
31
|
|
|
44
32
|
## 组件列表
|
|
45
33
|
|
|
46
|
-
-
|
|
47
|
-
- ModalForm - 弹窗表单组件
|
|
48
|
-
- ProForm - 表单组件
|
|
49
|
-
- ProLayout - 布局组件
|
|
50
|
-
- ProTable - 表格组件
|
|
51
|
-
- ProText - 文本组件
|
|
52
|
-
- ProDescriptions - 描述列表组件
|
|
53
|
-
- ProList - 列表组件
|
|
54
|
-
- Tour - 漫游式引导组件
|
|
55
|
-
- Watermark - 水印组件
|
|
34
|
+
- Login - 登录表单组件
|
|
56
35
|
|
|
57
36
|
## 文档
|
|
58
37
|
|
|
59
|
-
访问 [ProComponent 文档](https://procomponent.banmao.cc/) 了解更多使用细节。
|
|
38
|
+
访问 [ProComponent 文档](https://procomponent.banmao.cc/blocks) 了解更多使用细节。
|
|
60
39
|
|
|
61
40
|
## License
|
|
62
41
|
|
|
63
|
-
[MIT](./LICENSE)
|
|
42
|
+
[MIT](./LICENSE)
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
declare const _default: import('vue').DefineComponent<globalThis.ExtractPropTypes<{
|
|
2
|
+
title: {
|
|
3
|
+
type: PropType<LoginProps["title"]>;
|
|
4
|
+
default: string;
|
|
5
|
+
};
|
|
6
|
+
subTitle: {
|
|
7
|
+
type: PropType<LoginProps["subTitle"]>;
|
|
8
|
+
default: string;
|
|
9
|
+
};
|
|
10
|
+
forgotUrl: {
|
|
11
|
+
type: PropType<LoginProps["forgotUrl"]>;
|
|
12
|
+
default: string;
|
|
13
|
+
};
|
|
14
|
+
signUpUrl: {
|
|
15
|
+
type: PropType<LoginProps["signUpUrl"]>;
|
|
16
|
+
default: string;
|
|
17
|
+
};
|
|
18
|
+
radius: {
|
|
19
|
+
type: (NumberConstructor | BooleanConstructor)[];
|
|
20
|
+
default: number;
|
|
21
|
+
};
|
|
22
|
+
shadow: {
|
|
23
|
+
type: BooleanConstructor;
|
|
24
|
+
default: boolean;
|
|
25
|
+
};
|
|
26
|
+
actions: {
|
|
27
|
+
type: PropType<LoginProps["actions"]>;
|
|
28
|
+
};
|
|
29
|
+
}>, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, (keyof globalThis.LoginEmits)[], keyof globalThis.LoginEmits, import('vue').PublicProps, Readonly<globalThis.ExtractPropTypes<{
|
|
30
|
+
title: {
|
|
31
|
+
type: PropType<LoginProps["title"]>;
|
|
32
|
+
default: string;
|
|
33
|
+
};
|
|
34
|
+
subTitle: {
|
|
35
|
+
type: PropType<LoginProps["subTitle"]>;
|
|
36
|
+
default: string;
|
|
37
|
+
};
|
|
38
|
+
forgotUrl: {
|
|
39
|
+
type: PropType<LoginProps["forgotUrl"]>;
|
|
40
|
+
default: string;
|
|
41
|
+
};
|
|
42
|
+
signUpUrl: {
|
|
43
|
+
type: PropType<LoginProps["signUpUrl"]>;
|
|
44
|
+
default: string;
|
|
45
|
+
};
|
|
46
|
+
radius: {
|
|
47
|
+
type: (NumberConstructor | BooleanConstructor)[];
|
|
48
|
+
default: number;
|
|
49
|
+
};
|
|
50
|
+
shadow: {
|
|
51
|
+
type: BooleanConstructor;
|
|
52
|
+
default: boolean;
|
|
53
|
+
};
|
|
54
|
+
actions: {
|
|
55
|
+
type: PropType<LoginProps["actions"]>;
|
|
56
|
+
};
|
|
57
|
+
}>> & Readonly<{
|
|
58
|
+
onFinish?: ((...args: any[]) => any) | undefined;
|
|
59
|
+
onError?: ((...args: any[]) => any) | undefined;
|
|
60
|
+
onCaptcha?: ((...args: any[]) => any) | undefined;
|
|
61
|
+
onWechatFinish?: ((...args: any[]) => any) | undefined;
|
|
62
|
+
}>, {
|
|
63
|
+
title: string | undefined;
|
|
64
|
+
subTitle: string | undefined;
|
|
65
|
+
forgotUrl: string | undefined;
|
|
66
|
+
signUpUrl: string | undefined;
|
|
67
|
+
radius: number | boolean;
|
|
68
|
+
shadow: boolean;
|
|
69
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
70
|
+
export default _default;
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
declare const _default: import('vue').DefineComponent<globalThis.ExtractPropTypes<{
|
|
2
|
+
title: {
|
|
3
|
+
type: PropType<LoginProps["title"]>;
|
|
4
|
+
default: string;
|
|
5
|
+
};
|
|
6
|
+
subTitle: {
|
|
7
|
+
type: PropType<LoginProps["subTitle"]>;
|
|
8
|
+
default: string;
|
|
9
|
+
};
|
|
10
|
+
layout: {
|
|
11
|
+
type: PropType<LoginProps["layout"]>;
|
|
12
|
+
default: string;
|
|
13
|
+
};
|
|
14
|
+
bg: {
|
|
15
|
+
type: PropType<LoginProps["bg"]>;
|
|
16
|
+
default: string;
|
|
17
|
+
};
|
|
18
|
+
forgotUrl: {
|
|
19
|
+
type: PropType<LoginProps["forgotUrl"]>;
|
|
20
|
+
default: string;
|
|
21
|
+
};
|
|
22
|
+
signUpUrl: {
|
|
23
|
+
type: PropType<LoginProps["signUpUrl"]>;
|
|
24
|
+
default: string;
|
|
25
|
+
};
|
|
26
|
+
bgImageUrl: {
|
|
27
|
+
type: PropType<LoginProps["bgImageUrl"]>;
|
|
28
|
+
default: string;
|
|
29
|
+
};
|
|
30
|
+
logo: {
|
|
31
|
+
type: PropType<LoginProps["logo"]>;
|
|
32
|
+
};
|
|
33
|
+
imagePosition: {
|
|
34
|
+
type: PropType<LoginProps["imagePosition"]>;
|
|
35
|
+
default: string;
|
|
36
|
+
};
|
|
37
|
+
actions: {
|
|
38
|
+
type: PropType<LoginProps["actions"]>;
|
|
39
|
+
};
|
|
40
|
+
}>, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, (keyof globalThis.LoginEmits)[], keyof globalThis.LoginEmits, import('vue').PublicProps, Readonly<globalThis.ExtractPropTypes<{
|
|
41
|
+
title: {
|
|
42
|
+
type: PropType<LoginProps["title"]>;
|
|
43
|
+
default: string;
|
|
44
|
+
};
|
|
45
|
+
subTitle: {
|
|
46
|
+
type: PropType<LoginProps["subTitle"]>;
|
|
47
|
+
default: string;
|
|
48
|
+
};
|
|
49
|
+
layout: {
|
|
50
|
+
type: PropType<LoginProps["layout"]>;
|
|
51
|
+
default: string;
|
|
52
|
+
};
|
|
53
|
+
bg: {
|
|
54
|
+
type: PropType<LoginProps["bg"]>;
|
|
55
|
+
default: string;
|
|
56
|
+
};
|
|
57
|
+
forgotUrl: {
|
|
58
|
+
type: PropType<LoginProps["forgotUrl"]>;
|
|
59
|
+
default: string;
|
|
60
|
+
};
|
|
61
|
+
signUpUrl: {
|
|
62
|
+
type: PropType<LoginProps["signUpUrl"]>;
|
|
63
|
+
default: string;
|
|
64
|
+
};
|
|
65
|
+
bgImageUrl: {
|
|
66
|
+
type: PropType<LoginProps["bgImageUrl"]>;
|
|
67
|
+
default: string;
|
|
68
|
+
};
|
|
69
|
+
logo: {
|
|
70
|
+
type: PropType<LoginProps["logo"]>;
|
|
71
|
+
};
|
|
72
|
+
imagePosition: {
|
|
73
|
+
type: PropType<LoginProps["imagePosition"]>;
|
|
74
|
+
default: string;
|
|
75
|
+
};
|
|
76
|
+
actions: {
|
|
77
|
+
type: PropType<LoginProps["actions"]>;
|
|
78
|
+
};
|
|
79
|
+
}>> & Readonly<{
|
|
80
|
+
onFinish?: ((...args: any[]) => any) | undefined;
|
|
81
|
+
onError?: ((...args: any[]) => any) | undefined;
|
|
82
|
+
onCaptcha?: ((...args: any[]) => any) | undefined;
|
|
83
|
+
onWechatFinish?: ((...args: any[]) => any) | undefined;
|
|
84
|
+
}>, {
|
|
85
|
+
title: string | undefined;
|
|
86
|
+
subTitle: string | undefined;
|
|
87
|
+
layout: globalThis.LoginLayout | undefined;
|
|
88
|
+
bg: string | undefined;
|
|
89
|
+
forgotUrl: string | undefined;
|
|
90
|
+
signUpUrl: string | undefined;
|
|
91
|
+
bgImageUrl: string | undefined;
|
|
92
|
+
imagePosition: "left" | "right" | undefined;
|
|
93
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
94
|
+
export default _default;
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
import { PropType, VNodeChild } from 'vue';
|
|
2
|
+
export type LoginLayout = "simple" | "column" | "muted" | "card";
|
|
3
|
+
export interface Action {
|
|
4
|
+
name: "Weixin";
|
|
5
|
+
label: string;
|
|
6
|
+
config: Record<string, any>;
|
|
7
|
+
}
|
|
8
|
+
export interface LoginProps {
|
|
9
|
+
/**
|
|
10
|
+
* 登录页方式,默认为 simple
|
|
11
|
+
* - simple: 一个简单的登录样式,表单居中,无背景图片
|
|
12
|
+
* - column: 两列布局的登录页面,需要配合 bg 属性
|
|
13
|
+
* - muted: 在简单样式基础上,使用柔和的颜色作为背景图,需要配合 bg 属性
|
|
14
|
+
* - card: 以卡片的形式展示两列布局的登录布局,需要配合 bg 属性
|
|
15
|
+
*/
|
|
16
|
+
layout?: LoginLayout;
|
|
17
|
+
/** 登录页的背景图,仅当 layout = column 或 card */
|
|
18
|
+
bg?: string;
|
|
19
|
+
/** 登录页的描述语,默认为 Login to your account */
|
|
20
|
+
subTitle?: string;
|
|
21
|
+
/** title 登录页标题, 默认为 Welcome back */
|
|
22
|
+
title?: string;
|
|
23
|
+
/** 忘记登录密码,当设置了忘记登录密码,显示 "忘记密码?" 超链接 */
|
|
24
|
+
forgotUrl?: string;
|
|
25
|
+
/** 立即注册的地址,默认为 /signup */
|
|
26
|
+
signUpUrl?: string;
|
|
27
|
+
/** 授权登录 */
|
|
28
|
+
actions?: Action[];
|
|
29
|
+
bgImageUrl?: string;
|
|
30
|
+
logo?: () => VNodeChild;
|
|
31
|
+
imagePosition?: 'left' | 'right';
|
|
32
|
+
}
|
|
33
|
+
export interface LoginEmits {
|
|
34
|
+
/** 表单登录提交 */
|
|
35
|
+
finish: (values: Record<string, string>) => void;
|
|
36
|
+
error: (error: any) => void;
|
|
37
|
+
captcha: () => Record<string, string>;
|
|
38
|
+
wechatFinish: (values: Record<string, any>) => void;
|
|
39
|
+
}
|
|
40
|
+
export type LoginEmitsType = keyof LoginEmits;
|
|
41
|
+
export declare const loginEmits: LoginEmitsType[];
|
|
42
|
+
export declare const loginProps: {
|
|
43
|
+
title: {
|
|
44
|
+
type: PropType<LoginProps["title"]>;
|
|
45
|
+
default: string;
|
|
46
|
+
};
|
|
47
|
+
subTitle: {
|
|
48
|
+
type: PropType<LoginProps["subTitle"]>;
|
|
49
|
+
default: string;
|
|
50
|
+
};
|
|
51
|
+
layout: {
|
|
52
|
+
type: PropType<LoginProps["layout"]>;
|
|
53
|
+
default: string;
|
|
54
|
+
};
|
|
55
|
+
bg: {
|
|
56
|
+
type: PropType<LoginProps["bg"]>;
|
|
57
|
+
default: string;
|
|
58
|
+
};
|
|
59
|
+
forgotUrl: {
|
|
60
|
+
type: PropType<LoginProps["forgotUrl"]>;
|
|
61
|
+
default: string;
|
|
62
|
+
};
|
|
63
|
+
signUpUrl: {
|
|
64
|
+
type: PropType<LoginProps["signUpUrl"]>;
|
|
65
|
+
default: string;
|
|
66
|
+
};
|
|
67
|
+
bgImageUrl: {
|
|
68
|
+
type: PropType<LoginProps["bgImageUrl"]>;
|
|
69
|
+
default: string;
|
|
70
|
+
};
|
|
71
|
+
logo: {
|
|
72
|
+
type: PropType<LoginProps["logo"]>;
|
|
73
|
+
};
|
|
74
|
+
imagePosition: {
|
|
75
|
+
type: PropType<LoginProps["imagePosition"]>;
|
|
76
|
+
default: string;
|
|
77
|
+
};
|
|
78
|
+
actions: {
|
|
79
|
+
type: PropType<LoginProps["actions"]>;
|
|
80
|
+
};
|
|
81
|
+
};
|
|
82
|
+
export declare const loginFormProps: {
|
|
83
|
+
title: {
|
|
84
|
+
type: PropType<LoginProps["title"]>;
|
|
85
|
+
default: string;
|
|
86
|
+
};
|
|
87
|
+
subTitle: {
|
|
88
|
+
type: PropType<LoginProps["subTitle"]>;
|
|
89
|
+
default: string;
|
|
90
|
+
};
|
|
91
|
+
forgotUrl: {
|
|
92
|
+
type: PropType<LoginProps["forgotUrl"]>;
|
|
93
|
+
default: string;
|
|
94
|
+
};
|
|
95
|
+
signUpUrl: {
|
|
96
|
+
type: PropType<LoginProps["signUpUrl"]>;
|
|
97
|
+
default: string;
|
|
98
|
+
};
|
|
99
|
+
radius: {
|
|
100
|
+
type: (NumberConstructor | BooleanConstructor)[];
|
|
101
|
+
default: number;
|
|
102
|
+
};
|
|
103
|
+
shadow: {
|
|
104
|
+
type: BooleanConstructor;
|
|
105
|
+
default: boolean;
|
|
106
|
+
};
|
|
107
|
+
actions: {
|
|
108
|
+
type: PropType<LoginProps["actions"]>;
|
|
109
|
+
};
|
|
110
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './Login';
|
package/dist/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
require('./index.css');"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),
|
|
1
|
+
require('./index.css');"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),i=require("naive-ui"),x=["finish","error","captcha","wechatFinish"],I={title:{type:String,default:"Welcome back"},subTitle:{type:String,default:"Login to your account"},layout:{type:String,default:"simple"},bg:{type:String,default:""},forgotUrl:{type:String,default:""},signUpUrl:{type:String,default:""},bgImageUrl:{type:String,default:""},logo:{type:Function},imagePosition:{type:String,default:"right"},actions:{type:Array}},U={title:{type:String,default:"Welcome back"},subTitle:{type:String,default:"Login to your account"},forgotUrl:{type:String,default:""},signUpUrl:{type:String,default:""},radius:{type:[Number,Boolean],default:8},shadow:{type:Boolean,default:!0},actions:{type:Array}},m=e.defineComponent({name:"LoginForm",props:U,emits:x,setup(r,{emit:n,slots:a}){const{actions:g,title:w,subTitle:l,signUpUrl:V,forgotUrl:d,shadow:c,radius:f}=r,u=e.reactive({username:"",password:""}),N=e.ref(!1),v={username:[{required:!0,message:"请输入用户名",trigger:"blur"},{min:3,max:10,message:"长度在 3 到 10 个字符",trigger:"blur"}],password:[{required:!0,message:"请输入密码",trigger:"blur"},{min:6,max:20,message:"长度在 6 到 20 个字符",trigger:"blur"}]},p=e.ref(null),h=()=>{var t;(t=p.value)==null||t.validate(o=>{o?(console.error(o),n("error",o)):n("finish",e.toRaw(u))})},y=()=>{console.error("Weixin login is not supported yet."),n("wechatFinish")};return()=>e.createVNode("div",{class:["login-form",{"login-form-shadow":c}],style:[{borderRadius:f?`${f}px`:"none"}]},[e.createVNode("div",{class:"title"},[w]),e.createVNode("div",{class:"sub-title"},[l]),a.default?a.default():e.createVNode(i.NForm,{ref:p,model:u,rules:v,size:"large","show-require-mark":!1},{default:()=>[e.createVNode(i.NFormItem,{label:"用户名",path:"username"},{default:()=>[e.createVNode(i.NInput,{value:u.username,"onUpdate:value":t=>u.username=t,placeholder:"请输入用户名"},null)]}),e.createVNode(i.NFormItem,{label:"密码",path:"password"},{default:()=>[e.createVNode(i.NInput,{value:u.password,"onUpdate:value":t=>u.password=t,placeholder:"请输入密码",type:"password"},null)]}),e.createVNode("div",{class:"password-forgot"},[e.createVNode(i.NCheckbox,{checked:N.value,"onUpdate:checked":t=>N.value=t,label:"记住密码"},null),d&&e.createVNode("a",{href:d},[e.createTextVNode("忘记密码?")])]),e.createVNode(i.NFormItem,{showLabel:!1},{default:()=>[e.createVNode(i.NButton,{"attr-type":"button",type:"primary",block:!0,onClick:()=>h()},{default:()=>[e.createTextVNode("登录")]})]}),g&&e.createVNode(i.NFormItem,{showLabel:!1},{default:()=>[e.createVNode(i.NButton,{color:"#02E16E",ghost:!0,block:!0,onClick:()=>y()},{default:()=>[e.createTextVNode("微信登录")]})]})]}),V&&e.createVNode("div",{class:"signUp"},[e.createTextVNode("还没有账号?"),e.createVNode("a",{href:V},[e.createTextVNode("立即注册")])])])}});function F(r){return typeof r=="function"||Object.prototype.toString.call(r)==="[object Object]"&&!e.isVNode(r)}const S=e.defineComponent({name:"LoginPage",props:I,emits:x,setup(r,{emit:n,slots:a}){const{layout:g,bg:w,bgImageUrl:l,imagePosition:V,...d}=r,c=e.computed(()=>V==="right");return()=>{var f,u,N,v,p,h,y,t;if(a.default){let o;if(g==="column"){let s;return e.createVNode("div",{class:["container","column"]},[e.createVNode("div",{class:"column-item",style:{order:c.value?1:2}},[c.value&&e.createVNode("div",{class:"logo"},[(f=a.logo)==null?void 0:f.call(a)]),e.createVNode(m,e.mergeProps(d,{shadow:!1,radius:!1,onFinish:b=>n("finish",b)}),F(s=a.default())?s:{default:()=>[s]})]),e.createVNode("div",{class:"column-muted",style:{order:c.value?2:1}},[!c.value&&e.createVNode("div",{class:"logo"},[(u=a.logo)==null?void 0:u.call(a)]),r.bgImageUrl&&e.createVNode("img",{src:r.bgImageUrl,alt:"Image",class:"column-muted-image"},null)])])}if(g==="card"){let s;return e.createVNode("div",{class:["container","flex-center","card-login-wrapper"],style:{backgroundImage:l?`url(${l})`:"transparent"}},[e.createVNode("div",{class:"logo"},[(N=a.logo)==null?void 0:N.call(a)]),e.createVNode("div",{class:"card-img-cover"},null),e.createVNode("div",{class:"card"},[e.createVNode("div",{class:["card-column-item","flex-1"],style:{"flex-direction":c.value?"column":"column-reverse"}},[e.createVNode(m,e.mergeProps(d,{shadow:!1,radius:!1,onFinish:b=>n("finish",b)}),F(s=a.default())?s:{default:()=>[s]})]),e.createVNode("div",{class:["card-column-muted","flex-1"],style:{width:"350px","flex-direction":c.value?"column-reverse":"column"}},[l&&e.createVNode("img",{src:l,alt:"Image",class:"column-muted-image"},null)])])])}return e.createVNode("div",{class:["container","flex-center"],style:{backgroundImage:`url(${l})`,backgroundSize:"cover"}},[e.createVNode("div",{class:["flex-col","space-y-4"]},[(v=a.logo)==null?void 0:v.call(a),e.createVNode(m,e.mergeProps(d,{onFinish:s=>n("finish",s)}),F(o=a.default())?o:{default:()=>[o]})])])}else return g==="column"?e.createVNode("div",{class:["container","column",{"column-reverse":r.imagePosition==="left"}]},[e.createVNode("div",{class:"column-item"},[c.value&&e.createVNode("div",{class:"logo"},[(p=a.logo)==null?void 0:p.call(a)]),e.createVNode(m,e.mergeProps(d,{shadow:!1,radius:!1,onFinish:o=>n("finish",o)}),null)]),e.createVNode("div",{class:"column-muted"},[!c.value&&e.createVNode("div",{class:"logo"},[(h=a.logo)==null?void 0:h.call(a)]),r.bgImageUrl&&e.createVNode("img",{src:r.bgImageUrl,alt:"Image",class:"column-muted-image"},null)])]):g==="card"?e.createVNode("div",{class:["container","flex-center"]},[e.createVNode("div",{class:"logo"},[(y=a.logo)==null?void 0:y.call(a)]),e.createVNode("div",{class:"card"},[e.createVNode("div",{class:["card-column-item","flex-1"]},[e.createVNode(m,e.mergeProps(d,{shadow:!1,radius:!1,onFinish:o=>n("finish",o)}),null)]),e.createVNode("div",{class:["card-column-muted","flex-1"],style:{width:"350px"}},[l&&e.createVNode("img",{src:l,alt:"Image",class:"column-muted-image"},null)])])]):e.createVNode("div",{class:["container","flex-center"],style:{backgroundImage:`url(${l})`,backgroundSize:"cover"}},[e.createVNode("div",{class:["flex-col","space-y-4"]},[(t=a.logo)==null?void 0:t.call(a),e.createVNode(m,d,null)])])}}});exports.Login=S;exports.loginEmits=x;exports.loginFormProps=U;exports.loginProps=I;
|
package/dist/index.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.
|
|
1
|
+
:root{--color-link: hsl(221 100% 58%);--color-text: hsl(240 5% 96%);--color-section-text: hsl(240 6% 90%);--img-cover-color: oklch(1 0 none / .6);--img-cover-color-dark: oklch(.3 0 none / .6);--bg-color: oklch(1 0 none / .8);--bg-color-dark: oklch(.25 0 none / .8);--login-shadow: oklch(0 0 none / .2);--bg-muted: oklch(.25 .003 24)}.container{position:relative;width:100%;height:100svh}.flex-center{display:flex;align-items:center;justify-content:center}.flex-col{display:flex;flex-direction:column;justify-content:center;align-items:center}.space-y-4{gap:16px}.login-form{padding:32px 32px 24px;min-width:350px;background:var(--bg-color);-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px);box-sizing:border-box}.card .login-form{width:100%}.column .login-form,.dark .column .login-form{background:transparent}.login-form-shadow{box-shadow:0 2px 12px 0 var(--login-shadow)}.title{font-size:20px;font-weight:700;color:var(--color-text)}.sub-title{font-size:16px;color:var(--color-section-text);margin-bottom:32px}.signUp{text-align:center;color:var(--color-text)}.signUp a,.link{color:var(--color-link);text-decoration:none}.password-forgot{width:100%;display:flex;justify-content:space-between;align-items:center;margin-bottom:16px}.password-forgot a{color:var(--color-link);text-decoration:none}.column,.grid{display:grid}.column-reverse{direction:rtl}.column-reverse>*{direction:ltr}.card{width:100%;max-width:48rem;display:flex;box-sizing:border-box;box-shadow:0 2px 12px 0 var(--login-shadow);border-radius:.5rem;overflow:hidden}.card-column-item{display:flex;flex-direction:column;justify-content:center;align-items:center}.card-column-muted{width:100%;position:relative;display:none;background-color:var(--bg-muted)}.flex-1{flex:1}.logo{position:absolute;top:20px;left:20px;z-index:9;height:64px;min-width:64px}.column-item{position:relative;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:1rem}.column-muted{width:100%;position:relative;display:none;background-color:var(--bg-muted)}.column-muted-image{position:absolute;top:0;right:0;bottom:0;left:0;height:100%;width:100%;object-fit:cover}@media screen and (max-width: 1199px){.column-item{padding:40px}}@media screen and (max-width: 1200){.card{max-width:24rem}}@media screen and (min-width: 1200px){.column{grid-template-columns:repeat(2,minmax(0,1fr))}.column-muted,.card-column-muted{display:block}}.dark .column-muted-image{filter:brightness(.2)}.dark .column-muted-image{filter:grayscale(40%)}.dark .login-form{background-color:var(--bg-color-dark)}@media (prefers-color-scheme: light){:root{--color-text: #333;--color-section-text: #4f4f4f}.login-form{background:var(--bg-color)}.sub-title{color:var(--color-section-text)}}.card-login-wrapper{background-size:cover}.card-img-cover{position:absolute;top:0;width:100%;height:100%;background:var(--img-cover-color);z-index:0;-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px)}.dark .card-img-cover{background:var(--img-cover-color-dark)}
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './components';
|
package/dist/index.js
CHANGED
|
@@ -1,26 +1,6 @@
|
|
|
1
|
-
import './index.css';import { defineComponent as
|
|
2
|
-
import {
|
|
3
|
-
const
|
|
4
|
-
container: T,
|
|
5
|
-
"flex-center": "_flex-center_17dip_7",
|
|
6
|
-
"flex-col": "_flex-col_17dip_13",
|
|
7
|
-
"space-y-4": "_space-y-4_17dip_20",
|
|
8
|
-
title: W,
|
|
9
|
-
description: A,
|
|
10
|
-
signUp: D,
|
|
11
|
-
link: q,
|
|
12
|
-
"password-forgot": "_password-forgot_17dip_46",
|
|
13
|
-
column: R,
|
|
14
|
-
grid: j,
|
|
15
|
-
"column-reverse": "_column-reverse_17dip_63",
|
|
16
|
-
card: z,
|
|
17
|
-
"flex-1": "_flex-1_17dip_80",
|
|
18
|
-
logo: V,
|
|
19
|
-
"column-item": "_column-item_17dip_93",
|
|
20
|
-
"column-muted": "_column-muted_17dip_103",
|
|
21
|
-
"column-muted-image": "_column-muted-image_17dip_110",
|
|
22
|
-
dark: $
|
|
23
|
-
}, S = ["finish", "error", "captcha", "wechatFinish"], G = {
|
|
1
|
+
import './index.css';import { defineComponent as L, reactive as P, ref as k, createVNode as e, createTextVNode as v, toRaw as E, computed as A, mergeProps as h, isVNode as D } from "vue";
|
|
2
|
+
import { NForm as W, NFormItem as x, NInput as B, NCheckbox as R, NButton as C } from "naive-ui";
|
|
3
|
+
const N = ["finish", "error", "captcha", "wechatFinish"], T = {
|
|
24
4
|
title: {
|
|
25
5
|
type: String,
|
|
26
6
|
default: "Welcome back"
|
|
@@ -59,7 +39,7 @@ const T = "_container_17dip_1", W = "_title_17dip_26", A = "_description_17dip_3
|
|
|
59
39
|
actions: {
|
|
60
40
|
type: Array
|
|
61
41
|
}
|
|
62
|
-
},
|
|
42
|
+
}, _ = {
|
|
63
43
|
title: {
|
|
64
44
|
type: String,
|
|
65
45
|
default: "Welcome back"
|
|
@@ -76,6 +56,10 @@ const T = "_container_17dip_1", W = "_title_17dip_26", A = "_description_17dip_3
|
|
|
76
56
|
type: String,
|
|
77
57
|
default: ""
|
|
78
58
|
},
|
|
59
|
+
radius: {
|
|
60
|
+
type: [Number, Boolean],
|
|
61
|
+
default: 8
|
|
62
|
+
},
|
|
79
63
|
shadow: {
|
|
80
64
|
type: Boolean,
|
|
81
65
|
default: !0
|
|
@@ -83,47 +67,26 @@ const T = "_container_17dip_1", W = "_title_17dip_26", A = "_description_17dip_3
|
|
|
83
67
|
actions: {
|
|
84
68
|
type: Array
|
|
85
69
|
}
|
|
86
|
-
},
|
|
87
|
-
name: "CardTitle",
|
|
88
|
-
props: {
|
|
89
|
-
title: {
|
|
90
|
-
type: String,
|
|
91
|
-
default: "Welcome back"
|
|
92
|
-
},
|
|
93
|
-
description: {
|
|
94
|
-
type: String,
|
|
95
|
-
default: "Login to your account"
|
|
96
|
-
}
|
|
97
|
-
},
|
|
98
|
-
setup(l) {
|
|
99
|
-
const {
|
|
100
|
-
title: r,
|
|
101
|
-
description: o
|
|
102
|
-
} = l;
|
|
103
|
-
return () => e("div", null, [e("div", {
|
|
104
|
-
class: t.title
|
|
105
|
-
}, [r]), e("div", {
|
|
106
|
-
class: t.description
|
|
107
|
-
}, [o])]);
|
|
108
|
-
}
|
|
109
|
-
}), v = /* @__PURE__ */ b({
|
|
70
|
+
}, g = /* @__PURE__ */ L({
|
|
110
71
|
name: "LoginForm",
|
|
111
|
-
props:
|
|
112
|
-
emits:
|
|
72
|
+
props: _,
|
|
73
|
+
emits: N,
|
|
113
74
|
setup(l, {
|
|
114
|
-
emit:
|
|
75
|
+
emit: t,
|
|
76
|
+
slots: a
|
|
115
77
|
}) {
|
|
116
78
|
const {
|
|
117
|
-
actions:
|
|
118
|
-
title:
|
|
119
|
-
subTitle:
|
|
120
|
-
signUpUrl:
|
|
121
|
-
forgotUrl:
|
|
122
|
-
shadow:
|
|
123
|
-
|
|
79
|
+
actions: s,
|
|
80
|
+
title: S,
|
|
81
|
+
subTitle: u,
|
|
82
|
+
signUpUrl: y,
|
|
83
|
+
forgotUrl: o,
|
|
84
|
+
shadow: n,
|
|
85
|
+
radius: m
|
|
86
|
+
} = l, c = P({
|
|
124
87
|
username: "",
|
|
125
88
|
password: ""
|
|
126
|
-
}),
|
|
89
|
+
}), f = k(!1), b = {
|
|
127
90
|
username: [{
|
|
128
91
|
required: !0,
|
|
129
92
|
message: "请输入用户名",
|
|
@@ -144,160 +107,247 @@ const T = "_container_17dip_1", W = "_title_17dip_26", A = "_description_17dip_3
|
|
|
144
107
|
message: "长度在 6 到 20 个字符",
|
|
145
108
|
trigger: "blur"
|
|
146
109
|
}]
|
|
147
|
-
},
|
|
148
|
-
var
|
|
149
|
-
(
|
|
150
|
-
|
|
110
|
+
}, p = k(null), F = () => {
|
|
111
|
+
var r;
|
|
112
|
+
(r = p.value) == null || r.validate((i) => {
|
|
113
|
+
i ? (console.error(i), t("error", i)) : t("finish", E(c));
|
|
151
114
|
});
|
|
152
|
-
},
|
|
153
|
-
console.error("Weixin login is not supported yet."),
|
|
115
|
+
}, w = () => {
|
|
116
|
+
console.error("Weixin login is not supported yet."), t("wechatFinish");
|
|
154
117
|
};
|
|
155
|
-
return () => e(
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
}, null),
|
|
118
|
+
return () => e("div", {
|
|
119
|
+
class: ["login-form", {
|
|
120
|
+
"login-form-shadow": n
|
|
121
|
+
}],
|
|
160
122
|
style: [{
|
|
161
|
-
|
|
162
|
-
}
|
|
163
|
-
|
|
164
|
-
|
|
123
|
+
borderRadius: m ? `${m}px` : "none"
|
|
124
|
+
}]
|
|
125
|
+
}, [e("div", {
|
|
126
|
+
class: "title"
|
|
127
|
+
}, [S]), e("div", {
|
|
128
|
+
class: "sub-title"
|
|
129
|
+
}, [u]), a.default ? a.default() : e(W, {
|
|
130
|
+
ref: p,
|
|
131
|
+
model: c,
|
|
132
|
+
rules: b,
|
|
133
|
+
size: "large",
|
|
134
|
+
"show-require-mark": !1
|
|
165
135
|
}, {
|
|
166
|
-
default: () => [e(
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
rules: m,
|
|
170
|
-
size: "large",
|
|
171
|
-
"show-require-mark": !1
|
|
136
|
+
default: () => [e(x, {
|
|
137
|
+
label: "用户名",
|
|
138
|
+
path: "username"
|
|
172
139
|
}, {
|
|
173
|
-
default: () => [e(
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
140
|
+
default: () => [e(B, {
|
|
141
|
+
value: c.username,
|
|
142
|
+
"onUpdate:value": (r) => c.username = r,
|
|
143
|
+
placeholder: "请输入用户名"
|
|
144
|
+
}, null)]
|
|
145
|
+
}), e(x, {
|
|
146
|
+
label: "密码",
|
|
147
|
+
path: "password"
|
|
148
|
+
}, {
|
|
149
|
+
default: () => [e(B, {
|
|
150
|
+
value: c.password,
|
|
151
|
+
"onUpdate:value": (r) => c.password = r,
|
|
152
|
+
placeholder: "请输入密码",
|
|
153
|
+
type: "password"
|
|
154
|
+
}, null)]
|
|
155
|
+
}), e("div", {
|
|
156
|
+
class: "password-forgot"
|
|
157
|
+
}, [e(R, {
|
|
158
|
+
checked: f.value,
|
|
159
|
+
"onUpdate:checked": (r) => f.value = r,
|
|
160
|
+
label: "记住密码"
|
|
161
|
+
}, null), o && e("a", {
|
|
162
|
+
href: o
|
|
163
|
+
}, [v("忘记密码?")])]), e(x, {
|
|
164
|
+
showLabel: !1
|
|
165
|
+
}, {
|
|
166
|
+
default: () => [e(C, {
|
|
167
|
+
"attr-type": "button",
|
|
168
|
+
type: "primary",
|
|
169
|
+
block: !0,
|
|
170
|
+
onClick: () => F()
|
|
202
171
|
}, {
|
|
203
|
-
default: () => [
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
172
|
+
default: () => [v("登录")]
|
|
173
|
+
})]
|
|
174
|
+
}), s && e(x, {
|
|
175
|
+
showLabel: !1
|
|
176
|
+
}, {
|
|
177
|
+
default: () => [e(C, {
|
|
178
|
+
color: "#02E16E",
|
|
179
|
+
ghost: !0,
|
|
180
|
+
block: !0,
|
|
181
|
+
onClick: () => w()
|
|
213
182
|
}, {
|
|
214
|
-
default: () => [
|
|
215
|
-
color: "#02E16E",
|
|
216
|
-
ghost: !0,
|
|
217
|
-
block: !0,
|
|
218
|
-
onClick: () => d()
|
|
219
|
-
}, {
|
|
220
|
-
default: () => [g("微信登录")]
|
|
221
|
-
})]
|
|
183
|
+
default: () => [v("微信登录")]
|
|
222
184
|
})]
|
|
223
|
-
})
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
});
|
|
185
|
+
})]
|
|
186
|
+
}), y && e("div", {
|
|
187
|
+
class: "signUp"
|
|
188
|
+
}, [v("还没有账号?"), e("a", {
|
|
189
|
+
href: y
|
|
190
|
+
}, [v("立即注册")])])]);
|
|
229
191
|
}
|
|
230
|
-
})
|
|
192
|
+
});
|
|
193
|
+
function I(l) {
|
|
194
|
+
return typeof l == "function" || Object.prototype.toString.call(l) === "[object Object]" && !D(l);
|
|
195
|
+
}
|
|
196
|
+
const q = /* @__PURE__ */ L({
|
|
231
197
|
name: "LoginPage",
|
|
232
|
-
props:
|
|
233
|
-
emits:
|
|
198
|
+
props: T,
|
|
199
|
+
emits: N,
|
|
234
200
|
setup(l, {
|
|
235
|
-
emit:
|
|
236
|
-
slots:
|
|
201
|
+
emit: t,
|
|
202
|
+
slots: a
|
|
237
203
|
}) {
|
|
238
204
|
const {
|
|
239
|
-
layout:
|
|
240
|
-
bg:
|
|
241
|
-
bgImageUrl:
|
|
242
|
-
|
|
243
|
-
...
|
|
244
|
-
} = l,
|
|
205
|
+
layout: s,
|
|
206
|
+
bg: S,
|
|
207
|
+
bgImageUrl: u,
|
|
208
|
+
imagePosition: y,
|
|
209
|
+
...o
|
|
210
|
+
} = l, n = A(() => y === "right");
|
|
245
211
|
return () => {
|
|
246
|
-
var c,
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
212
|
+
var m, c, f, b, p, F, w, r;
|
|
213
|
+
if (a.default) {
|
|
214
|
+
let i;
|
|
215
|
+
if (s === "column") {
|
|
216
|
+
let d;
|
|
217
|
+
return e("div", {
|
|
218
|
+
class: ["container", "column"]
|
|
219
|
+
}, [e("div", {
|
|
220
|
+
class: "column-item",
|
|
221
|
+
style: {
|
|
222
|
+
order: n.value ? 1 : 2
|
|
223
|
+
}
|
|
224
|
+
}, [n.value && e("div", {
|
|
225
|
+
class: "logo"
|
|
226
|
+
}, [(m = a.logo) == null ? void 0 : m.call(a)]), e(g, h(o, {
|
|
227
|
+
shadow: !1,
|
|
228
|
+
radius: !1,
|
|
229
|
+
onFinish: (U) => t("finish", U)
|
|
230
|
+
}), I(d = a.default()) ? d : {
|
|
231
|
+
default: () => [d]
|
|
232
|
+
})]), e("div", {
|
|
233
|
+
class: "column-muted",
|
|
234
|
+
style: {
|
|
235
|
+
order: n.value ? 2 : 1
|
|
236
|
+
}
|
|
237
|
+
}, [!n.value && e("div", {
|
|
238
|
+
class: "logo"
|
|
239
|
+
}, [(c = a.logo) == null ? void 0 : c.call(a)]), l.bgImageUrl && e("img", {
|
|
240
|
+
src: l.bgImageUrl,
|
|
241
|
+
alt: "Image",
|
|
242
|
+
class: "column-muted-image"
|
|
243
|
+
}, null)])]);
|
|
244
|
+
}
|
|
245
|
+
if (s === "card") {
|
|
246
|
+
let d;
|
|
247
|
+
return e("div", {
|
|
248
|
+
class: ["container", "flex-center", "card-login-wrapper"],
|
|
249
|
+
style: {
|
|
250
|
+
backgroundImage: u ? `url(${u})` : "transparent"
|
|
251
|
+
}
|
|
252
|
+
}, [e("div", {
|
|
253
|
+
class: "logo"
|
|
254
|
+
}, [(f = a.logo) == null ? void 0 : f.call(a)]), e("div", {
|
|
255
|
+
class: "card-img-cover"
|
|
256
|
+
}, null), e("div", {
|
|
257
|
+
class: "card"
|
|
258
|
+
}, [e("div", {
|
|
259
|
+
class: ["card-column-item", "flex-1"],
|
|
260
|
+
style: {
|
|
261
|
+
"flex-direction": n.value ? "column" : "column-reverse"
|
|
262
|
+
}
|
|
263
|
+
}, [e(g, h(o, {
|
|
264
|
+
shadow: !1,
|
|
265
|
+
radius: !1,
|
|
266
|
+
onFinish: (U) => t("finish", U)
|
|
267
|
+
}), I(d = a.default()) ? d : {
|
|
268
|
+
default: () => [d]
|
|
269
|
+
})]), e("div", {
|
|
270
|
+
class: ["card-column-muted", "flex-1"],
|
|
271
|
+
style: {
|
|
272
|
+
width: "350px",
|
|
273
|
+
"flex-direction": n.value ? "column-reverse" : "column"
|
|
274
|
+
}
|
|
275
|
+
}, [u && e("img", {
|
|
276
|
+
src: u,
|
|
277
|
+
alt: "Image",
|
|
278
|
+
class: "column-muted-image"
|
|
279
|
+
}, null)])])]);
|
|
291
280
|
}
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
281
|
+
return e("div", {
|
|
282
|
+
class: ["container", "flex-center"],
|
|
283
|
+
style: {
|
|
284
|
+
backgroundImage: `url(${u})`,
|
|
285
|
+
backgroundSize: "cover"
|
|
286
|
+
}
|
|
287
|
+
}, [e("div", {
|
|
288
|
+
class: ["flex-col", "space-y-4"]
|
|
289
|
+
}, [(b = a.logo) == null ? void 0 : b.call(a), e(g, h(o, {
|
|
290
|
+
onFinish: (d) => t("finish", d)
|
|
291
|
+
}), I(i = a.default()) ? i : {
|
|
292
|
+
default: () => [i]
|
|
293
|
+
})])]);
|
|
294
|
+
} else
|
|
295
|
+
return s === "column" ? e("div", {
|
|
296
|
+
class: ["container", "column", {
|
|
297
|
+
"column-reverse": l.imagePosition === "left"
|
|
298
|
+
}]
|
|
299
|
+
}, [e("div", {
|
|
300
|
+
class: "column-item"
|
|
301
|
+
}, [n.value && e("div", {
|
|
302
|
+
class: "logo"
|
|
303
|
+
}, [(p = a.logo) == null ? void 0 : p.call(a)]), e(g, h(o, {
|
|
304
|
+
shadow: !1,
|
|
305
|
+
radius: !1,
|
|
306
|
+
onFinish: (i) => t("finish", i)
|
|
307
|
+
}), null)]), e("div", {
|
|
308
|
+
class: "column-muted"
|
|
309
|
+
}, [!n.value && e("div", {
|
|
310
|
+
class: "logo"
|
|
311
|
+
}, [(F = a.logo) == null ? void 0 : F.call(a)]), l.bgImageUrl && e("img", {
|
|
312
|
+
src: l.bgImageUrl,
|
|
313
|
+
alt: "Image",
|
|
314
|
+
class: "column-muted-image"
|
|
315
|
+
}, null)])]) : s === "card" ? e("div", {
|
|
316
|
+
class: ["container", "flex-center"]
|
|
317
|
+
}, [e("div", {
|
|
318
|
+
class: "logo"
|
|
319
|
+
}, [(w = a.logo) == null ? void 0 : w.call(a)]), e("div", {
|
|
320
|
+
class: "card"
|
|
321
|
+
}, [e("div", {
|
|
322
|
+
class: ["card-column-item", "flex-1"]
|
|
323
|
+
}, [e(g, h(o, {
|
|
324
|
+
shadow: !1,
|
|
325
|
+
radius: !1,
|
|
326
|
+
onFinish: (i) => t("finish", i)
|
|
327
|
+
}), null)]), e("div", {
|
|
328
|
+
class: ["card-column-muted", "flex-1"],
|
|
329
|
+
style: {
|
|
330
|
+
width: "350px"
|
|
331
|
+
}
|
|
332
|
+
}, [u && e("img", {
|
|
333
|
+
src: u,
|
|
334
|
+
alt: "Image",
|
|
335
|
+
class: "column-muted-image"
|
|
336
|
+
}, null)])])]) : e("div", {
|
|
337
|
+
class: ["container", "flex-center"],
|
|
338
|
+
style: {
|
|
339
|
+
backgroundImage: `url(${u})`,
|
|
340
|
+
backgroundSize: "cover"
|
|
341
|
+
}
|
|
342
|
+
}, [e("div", {
|
|
343
|
+
class: ["flex-col", "space-y-4"]
|
|
344
|
+
}, [(r = a.logo) == null ? void 0 : r.call(a), e(g, o, null)])]);
|
|
295
345
|
};
|
|
296
346
|
}
|
|
297
347
|
});
|
|
298
348
|
export {
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
349
|
+
q as Login,
|
|
350
|
+
N as loginEmits,
|
|
351
|
+
_ as loginFormProps,
|
|
352
|
+
T as loginProps
|
|
303
353
|
};
|