Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Hooke
/
mlaj
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
hookehuyr
2025-03-27 11:14:02 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
55b3b1e660ba5c0c301f3adcdb6450ee3f8ca689
55b3b1e6
1 parent
8337f243
style(登录页面): 为手机号和密码输入框添加必填标记和占位符
为提升用户体验,在手机号和密码输入框前添加红色星号标记表示必填项,并添加占位符提示用户输入格式
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
src/views/auth/LoginPage.vue
src/views/auth/LoginPage.vue
View file @
55b3b1e
...
...
@@ -19,7 +19,7 @@
<form class="space-y-6" @submit.prevent="handleSubmit">
<div>
<label for="mobile" class="block text-sm font-medium text-gray-700">
手机号
手机号
<span class="text-red-500">*</span>
</label>
<input
id="mobile"
...
...
@@ -30,6 +30,7 @@
required
pattern="^1[3-9]\d{9}$"
maxlength="11"
placeholder="请输入手机号"
@input="mobile = $event.target.value.replace(/\D/g, '')"
@focus="handleInputFocus"
class="mt-1 block w-full px-3 py-2 border border-gray-300 rounded-md shadow-sm focus:outline-none focus:ring-green-500 focus:border-green-500"
...
...
@@ -38,7 +39,7 @@
<div>
<label for="password" class="block text-sm font-medium text-gray-700">
密码
密码
<span class="text-red-500">*</span>
</label>
<input
id="password"
...
...
@@ -47,6 +48,7 @@
type="password"
autocomplete="current-password"
required
placeholder="请输入6位密码"
class="mt-1 block w-full px-3 py-2 border border-gray-300 rounded-md shadow-sm focus:outline-none focus:ring-green-500 focus:border-green-500"
/>
</div>
...
...
Please
register
or
login
to post a comment