Skip to content

Form validation messages always display in English #5811

@webfiltered

Description

@webfiltered

Prerequisites

  • I am running the latest version of ComfyUI
  • I have searched existing issues to make sure this isn't a duplicate
  • I have tested with all custom nodes disabled

What happened?

Validation error messages in sign-in/sign-up forms always display in English, regardless of the selected language setting.

Image

Steps to Reproduce

  1. Change language to any non-English language (e.g., French, Japanese, Chinese)
  2. Go to sign-in form
  3. Leave email field empty and try to submit
  4. Validation message shows "Invalid email address" in English instead of the selected language

How is this affecting you?

Personally? I mean, it's blocking me from merging #5810. This is only a little annoying. Also I feel bad for people who don't speak English.

ComfyUI Frontend Version

Latest

Browser

Chrome/Chromium

Console Errors

None

Additional Context

The issue is in /src/schemas/signInSchema.ts where the t() translation function is called at module import time, causing translations to be evaluated once at startup rather than dynamically when validation occurs.

My general thought here is that this should not be happening in schemas at all. To my mind, a JSON schema is not a place where we should be dynamically generating content at all.

┆Issue is synchronized with this Notion page by Unito

Metadata

Metadata

Assignees

Labels

Potential BugUntriaged bugarea:i18nAnything related to translation

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions