Compare commits

..

11 Commits

Author SHA1 Message Date
Henry
b9c8dcbc1b chore: update compiled translations 2025-11-19 21:32:40 +00:00
Henry
b41815ba62 feat: display attachments on public boards 2025-11-19 20:42:22 +00:00
Henry
b7974750e0 chore: build lang 2025-11-17 22:20:30 +00:00
Henry
b2af405cb2 feat: update compose and readme 2025-11-17 22:16:55 +00:00
Henry
f495ca3505 feat: add file viewer and downloads 2025-11-17 22:16:55 +00:00
Henry
070fc373f2 feat: add download and delete button 2025-11-17 22:16:55 +00:00
Henry
313f913ba4 feat: add thumbnails and attachment viewer 2025-11-17 22:16:55 +00:00
Henry
0bf2182252 feat: add upload button 2025-11-17 22:16:55 +00:00
Henry
99a05e3337 feat: add attachments router and repo funcs 2025-11-17 22:16:55 +00:00
Henry
4294ee3811 feat: setup s3 util funcs 2025-11-17 22:16:55 +00:00
Henry
772cd177a1 feat: add card attachment schema 2025-11-17 22:16:55 +00:00
2 changed files with 15 additions and 26 deletions

View File

@@ -303,10 +303,6 @@ export function Auth({ setIsMagicLinkSent, isSignUp }: AuthProps) {
const password = watch("password"); const password = watch("password");
const isMagicLinkAvailable = useMemo(() => {
return isCloudEnv || (isEmailSendingEnabled && !isSignUp);
}, [isCloudEnv, isEmailSendingEnabled, isSignUp]);
// Determine if we should operate in magic link mode for current form state (login only) // Determine if we should operate in magic link mode for current form state (login only)
const isMagicLinkMode = useMemo(() => { const isMagicLinkMode = useMemo(() => {
// Magic link only viable when email sending enabled AND not sign up. // Magic link only viable when email sending enabled AND not sign up.
@@ -394,7 +390,7 @@ export function Auth({ setIsMagicLinkSent, isSignUp }: AuthProps) {
)} )}
</div> </div>
)} )}
{(isCredentialsEnabled || isMagicLinkAvailable) && ( {isCredentialsEnabled && (
<> <>
<div> <div>
<Input <Input
@@ -408,28 +404,26 @@ export function Auth({ setIsMagicLinkSent, isSignUp }: AuthProps) {
)} )}
</div> </div>
{isCredentialsEnabled && ( <div>
<div> <Input
<Input type="password"
type="password" {...register("password", { required: true })}
{...register("password", { required: true })} placeholder={t`Enter your password`}
placeholder={t`Enter your password`} />
/> {errors.password && (
{errors.password && ( <p className="mt-2 text-xs text-red-400">
<p className="mt-2 text-xs text-red-400"> {errors.password.message ??
{errors.password.message ?? t`Please enter a valid password`}
t`Please enter a valid password`} </p>
</p> )}
)} </div>
</div>
)}
</> </>
)} )}
{loginError && ( {loginError && (
<p className="mt-2 text-xs text-red-400">{loginError}</p> <p className="mt-2 text-xs text-red-400">{loginError}</p>
)} )}
</div> </div>
{(isCredentialsEnabled || isMagicLinkAvailable) && ( {isCredentialsEnabled && (
<div className="mt-[1.5rem] flex items-center gap-4"> <div className="mt-[1.5rem] flex items-center gap-4">
<Button <Button
isLoading={isLoginWithEmailPending} isLoading={isLoginWithEmailPending}

View File

@@ -129,11 +129,6 @@ export const initAuth = (db: dbClient) => {
user: schema.users, user: schema.users,
}, },
}), }),
session: {
expiresIn: 60 * 60 * 24 * 30, // 30 days
updateAge: 60 * 60 * 24 * 2, // Update session expiry every 48 hours if user is active
freshAge: 0,
},
emailAndPassword: { emailAndPassword: {
enabled: env("NEXT_PUBLIC_ALLOW_CREDENTIALS")?.toLowerCase() === "true", enabled: env("NEXT_PUBLIC_ALLOW_CREDENTIALS")?.toLowerCase() === "true",
disableSignUp: disableSignUp: