vuetify icon indicating copy to clipboard operation
vuetify copied to clipboard

fix(VTextField): new-password of autocomplete doesn't behave correctly on chrome

Open baotx opened this issue 1 year ago • 3 comments

Description

fixes #19559

Markup:

<template>
  <v-app>
    <v-container>
      <v-responsive
        class="mx-auto"
        width="344"
      >
        <v-form>
          <v-label>Vuetify field</v-label>
          <v-text-field
            autocomplete="new-password"
            label="Password"
            name="password"
            type="password"
          />
          <v-text-field
            autocomplete="new-password"
            label="Confirm Password"
            name="confirm password"
            type="password"
          />
        </v-form>
        <!-- <form class="pure-form">
          <fieldset>
            <legend>Confirm password with HTML5</legend>

            <input id="password" placeholder="Password" type="password" required>
            <input id="confirm_password" placeholder="Confirm Password" type="password" required>

            <button class="mx-1" type="submit">Confirm</button>
          </fieldset>
        </form> -->
      </v-responsive>
    </v-container>
  </v-app>
</template>

<script>
  export default {
    name: 'Playground',
    setup () {
      return {
        //
      }
    },
  }
</script>

baotx avatar Apr 09 '24 08:04 baotx

This seems like it would cause issues, why was the code you're removing put there in the first place?

johnleider avatar Apr 09 '24 14:04 johnleider

Ah i see, the code is being used to focus on the TextField when we click or clear. Let me know if reverting the focus event to the before of this PR #14504 - feat(VSelect): port to v3 makes any sense.

What we're trying to do is to streamline our sign up page, and making password suggestion works better helps with that.

baotx avatar Apr 09 '24 23:04 baotx

Is there a different way that we can approach it without causing a regression?

johnleider avatar Apr 11 '24 13:04 johnleider