Commit 41fdc7a4 authored by Johnny's avatar Johnny

chore: fix frontend linter

parent a3de61a1
......@@ -52,7 +52,9 @@ const CalendarCell = memo(
if (!dayInfo.isCurrentMonth) {
return (
<div className={cn("w-6 h-6 text-xs lg:text-[13px] flex justify-center items-center cursor-default opacity-60 text-muted-foreground")}>
<div
className={cn("w-6 h-6 text-xs lg:text-[13px] flex justify-center items-center cursor-default opacity-60 text-muted-foreground")}
>
{dayInfo.day}
</div>
);
......
......@@ -18,11 +18,7 @@ const DateTimeInput: React.FC<Props> = ({ value, onChange }) => {
return (
<input
type="text"
className={cn(
"px-1 bg-transparent rounded text-xs transition-all",
"border-transparent outline-none focus:border-border",
"border",
)}
className={cn("px-1 bg-transparent rounded text-xs transition-all", "border-transparent outline-none focus:border-border", "border")}
defaultValue={formatDate(value)}
onBlur={(e) => {
const inputValue = e.target.value;
......
......@@ -9,10 +9,7 @@ const Spoiler: React.FC<Props> = ({ content }: Props) => {
const [isRevealed, setIsRevealed] = useState(false);
return (
<span
className={cn("inline cursor-pointer select-none", isRevealed ? "" : "bg-muted")}
onClick={() => setIsRevealed(!isRevealed)}
>
<span className={cn("inline cursor-pointer select-none", isRevealed ? "" : "bg-muted")} onClick={() => setIsRevealed(!isRevealed)}>
<span className={cn(isRevealed ? "opacity-100" : "opacity-0")}>{content}</span>
</span>
);
......
......@@ -57,12 +57,7 @@ const ReactionSelector = observer((props: Props) => {
return (
<Popover open={open} onOpenChange={setOpen}>
<PopoverTrigger asChild>
<span
className={cn(
"h-7 w-7 flex justify-center items-center rounded-full border hover:opacity-70 cursor-pointer",
className,
)}
>
<span className={cn("h-7 w-7 flex justify-center items-center rounded-full border hover:opacity-70 cursor-pointer", className)}>
<SmilePlusIcon className="w-4 h-4 mx-auto text-muted-foreground" />
</span>
</PopoverTrigger>
......
......@@ -103,9 +103,7 @@ const AccessTokenSection = () => {
<ClipboardIcon className="w-4 h-auto text-muted-foreground" />
</Button>
</td>
<td className="whitespace-nowrap py-2 pl-4 pr-3 text-sm text-foreground">
{userAccessToken.description}
</td>
<td className="whitespace-nowrap py-2 pl-4 pr-3 text-sm text-foreground">{userAccessToken.description}</td>
<td className="whitespace-nowrap px-3 py-2 text-sm text-muted-foreground">
{userAccessToken.issuedAt?.toLocaleString()}
</td>
......
......@@ -135,7 +135,9 @@ const UserSessionsSection = () => {
: t("setting.user-sessions-section.revoke-session")
}
>
<TrashIcon className={`w-4 h-auto ${isCurrentSession(userSession) ? "text-muted-foreground" : "text-destructive"}`} />
<TrashIcon
className={`w-4 h-auto ${isCurrentSession(userSession) ? "text-muted-foreground" : "text-destructive"}`}
/>
</Button>
</td>
</tr>
......
......@@ -44,9 +44,7 @@ const WebhookSection = () => {
<div className="w-full flex flex-col justify-start items-start">
<div className="w-full flex justify-between items-center">
<div className="flex-auto space-y-1">
<p className="flex flex-row justify-start items-center font-medium text-muted-foreground">
{t("setting.webhook-section.title")}
</p>
<p className="flex flex-row justify-start items-center font-medium text-muted-foreground">{t("setting.webhook-section.title")}</p>
</div>
<div>
<Button
......
......@@ -11,9 +11,7 @@ const AdminSignIn = observer(() => {
<div className="w-full py-4 grow flex flex-col justify-center items-center">
<div className="w-full flex flex-row justify-center items-center mb-6">
<img className="h-14 w-auto rounded-full shadow" src={workspaceGeneralSetting.customProfile?.logoUrl || "/logo.webp"} alt="" />
<p className="ml-2 text-5xl text-foreground opacity-80">
{workspaceGeneralSetting.customProfile?.title || "Memos"}
</p>
<p className="ml-2 text-5xl text-foreground opacity-80">{workspaceGeneralSetting.customProfile?.title || "Memos"}</p>
</div>
<p className="w-full text-xl font-medium text-muted-foreground">Sign in with admin accounts</p>
<PasswordSignInForm />
......
......@@ -60,9 +60,7 @@ const SignIn = observer(() => {
<div className="w-full py-4 grow flex flex-col justify-center items-center">
<div className="w-full flex flex-row justify-center items-center mb-6">
<img className="h-14 w-auto rounded-full shadow" src={workspaceGeneralSetting.customProfile?.logoUrl || "/logo.webp"} alt="" />
<p className="ml-2 text-5xl text-foreground opacity-80">
{workspaceGeneralSetting.customProfile?.title || "Memos"}
</p>
<p className="ml-2 text-5xl text-foreground opacity-80">{workspaceGeneralSetting.customProfile?.title || "Memos"}</p>
</div>
{!workspaceGeneralSetting.disallowPasswordAuth ? (
<PasswordSignInForm />
......
......@@ -72,9 +72,7 @@ const SignUp = observer(() => {
<div className="w-full py-4 grow flex flex-col justify-center items-center">
<div className="w-full flex flex-row justify-center items-center mb-6">
<img className="h-14 w-auto rounded-full shadow" src={workspaceGeneralSetting.customProfile?.logoUrl || "/logo.webp"} alt="" />
<p className="ml-2 text-5xl text-foreground opacity-80">
{workspaceGeneralSetting.customProfile?.title || "Memos"}
</p>
<p className="ml-2 text-5xl text-foreground opacity-80">{workspaceGeneralSetting.customProfile?.title || "Memos"}</p>
</div>
{!workspaceGeneralSetting.disallowUserRegistration ? (
<>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment