Skip to content

Commit

Permalink
优化访问码输入框
Browse files Browse the repository at this point in the history
  • Loading branch information
code-october committed Oct 11, 2024
1 parent c5074f0 commit c98dc31
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions app/components/auth.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import Logo from "../icons/logo.svg";
import { useMobileScreen } from "@/app/utils";
import BotIcon from "../icons/bot.svg";
import { getClientConfig } from "../config/client";
import { PasswordInput } from "./ui-lib";
import LeftIcon from "@/app/icons/left.svg";
import { safeLocalStorage } from "@/app/utils";
import {
Expand Down Expand Up @@ -60,17 +61,20 @@ export function AuthPage() {
<div className={styles["auth-title"]}>{Locale.Auth.Title}</div>
<div className={styles["auth-tips"]}>{Locale.Auth.Tips}</div>

<input
className={styles["auth-input"]}
type="password"
placeholder={Locale.Auth.Input}
<PasswordInput
style={{ marginTop: "3vh", marginBottom: "3vh" }}
aria={Locale.Settings.ShowPassword}
aria-label={Locale.Auth.Input}
value={accessStore.accessCode}
type="text"
placeholder={Locale.Auth.Input}
onChange={(e) => {
accessStore.update(
(access) => (access.accessCode = e.currentTarget.value),
);
}}
/>

{!accessStore.hideUserApiKey ? (
<>
<div className={styles["auth-tips"]}>{Locale.Auth.SubTips}</div>
Expand Down

0 comments on commit c98dc31

Please sign in to comment.