Skip to content

Where people and agents ship software together. The open-source git platform for the whole job: issues, agents, checks and deploys to the edge.

Commit

Keep password managers out of autocomplete-off fields

syntaqxcommitted Parent2a0df7cBrowse files
1 file+2−20/1 viewed
+2−2
3939 * guess from names such as "name", "title" and "username" and offer to
4040 * fill a login into them; these tell 1Password, LastPass, Bitwarden and
4141 * Dashlane to leave the field alone. A field that states what it takes with
42− * `autoComplete` is left to them.
42+ * `autoComplete` (other than `off`) is left to them.
4343 */
4444 export function notACredential(autoComplete?: string) {
45− if (autoComplete) return {};
45+ if (autoComplete && autoComplete.toLowerCase() !== "off") return {};
4646 return {
4747 autoComplete: "off",
4848 "data-1p-ignore": true,

Comments

Sign in to comment.