wui-components-v2 1.1.98 → 1.2.1

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.
@@ -4,23 +4,31 @@ import { defineOptions, defineProps } from 'vue'
4
4
  import loginFormBox from '../login-form-box/login-form-box.vue'
5
5
  import { useManualTheme } from '../../composables/useManualTheme'
6
6
  import type { TabbarItem } from '../../composables/useTabbar'
7
+ import companyLogo from '../../static/companyLogo.png'
7
8
 
8
9
  defineOptions({
9
10
  name: 'WuiLogin',
10
11
  })
11
12
 
12
- const props = defineProps<Props>()
13
13
  // 定义 Props 类型
14
14
  interface Props {
15
15
  tabbarItems: TabbarItem[]
16
- loginlog: any
16
+ loginlog: string
17
17
  showRagister?: boolean
18
- gurl?: string// 获取验证码接口
19
- url?: string// 手机号登录接口
18
+ gurl?: string // 获取验证码接口
19
+ url?: string // 手机号登录接口
20
+ showLoginImg?: boolean // 是否显示登录图片
21
+ customLoginImg?: string // 自定义登录图片(默认使用 companyLogo)
20
22
  }
21
- const {
22
- currentThemeColor,
23
- } = useManualTheme()
23
+
24
+ const props = withDefaults(defineProps<Props>(), {
25
+ showRagister: false,
26
+ gurl: '',
27
+ url: '',
28
+ showLoginImg: false,
29
+ customLoginImg: companyLogo,
30
+ })
31
+ const { currentThemeColor } = useManualTheme()
24
32
  </script>
25
33
 
26
34
  <template>
@@ -37,7 +45,15 @@ const {
37
45
  <image class="h-250px w-250px" src="./footerImg.png" />
38
46
  </view>
39
47
  <view class="flex-1 border-rd-t-2 p-y-2 bg-white dark:bg-[var(--wot-dark-background2)]">
40
- <loginFormBox :tabbar-items="props.tabbarItems" :show-ragister="showRagister" :gurl="props.gurl" :url="props.url" />
48
+ <view class="flex items-center justify-center" v-if="showLoginImg">
49
+ <image class="h-120px w-120px" :src="customLoginImg" />
50
+ </view>
51
+ <loginFormBox
52
+ :tabbar-items="props.tabbarItems"
53
+ :show-ragister="showRagister"
54
+ :gurl="props.gurl"
55
+ :url="props.url"
56
+ />
41
57
  </view>
42
58
  </view>
43
59
  </template>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "wui-components-v2",
3
- "version": "1.1.98",
3
+ "version": "1.2.1",
4
4
  "description": "wui 组件库",
5
5
  "author": "wgxshh",
6
6
  "license": "MIT",
Binary file