Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Support configurable login form selectors for non-standard label names

未关闭
#202 0 条评论 1 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
3/5
预计耗时
1-2 天
新手友好度
55/100
Issue 类型
功能
描述清晰度
基本清楚
活跃度
冷清
技术栈
typescript

调研方向

从 auth action 入手,其中 getByLabel(/user ?name/i) 和 getByLabel(/password/i) 会定位登录字段,然后检查可选输入是如何定义的。支持可配置的 username_selector 和 password_selector 值以及提议的 input-type 回退方案,并验证能够检测到非标准表单或没有标签的表单,并在已认证状态下对其进行扫描。

由索引模型根据 Issue 内容生成。

描述

Problem

The auth action finds login fields using getByLabel(/user ?name/i) and getByLabel(/password/i). This misses common login forms:

  • Email-based login: "Email", "E-Mail" don't match /user ?name/i
  • Non-English apps: "Benutzername", "Mot de passe" don't match
  • No visible labels: Forms using only placeholder attributes

When no match is found, the login form is not detected and the scanner proceeds unauthenticated.

Suggested fix

  1. Fall back to input types when label matching fails: input[type="password"] for the password field, and the closest preceding input[type="text"] or input[type="email"] for the username field.
  2. Make selectors configurable via optional inputs like username_selector and password_selector, so users can specify their own labels, placeholders, or CSS selectors for non-standard forms.
主要语言
TypeScript
星标
375
派生
42
平均合并
1 天 7 小时
30 天内合并 PR
6

环境准备

  • 没有 Dockerfile 或 Docker Compose 文件
  • 没有 Pull Request 模板
  • 阅读贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

github/accessibility-scanner 的其他 Issue

查看 github/accessibility-scanner 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。