Giter VIP home page Giter VIP logo

Comments (9)

fidian avatar fidian commented on June 16, 2024

Would you tell me more information? For instance, is it in all browsers or a specific browser/version that you are seeing this behavior?

from angular-placeholder.

oliverbenns avatar oliverbenns commented on June 16, 2024

Hey. Yep I'm experiencing this in Chrome, so I'm expecting all browsers.

So the original placeholder appears as normal, I click the input field, the placeholder disappears as expected.

However, it fails to remove the .placeholder class, giving me .placeholder styles.

Then, if I blur the input, and refocus into it, any text that I've entered into it is removed (acting like a placeholder).

from angular-placeholder.

fidian avatar fidian commented on June 16, 2024

Before I try to replicate the behavior with a fiddle of my own, do you have somewhere online that I can see this behavior? Also, what OS are you using and what version of Chrome are you running? It shouldn't matter, but I'd like to make sure that I test with as similar of an environment as possible.

from angular-placeholder.

oliverbenns avatar oliverbenns commented on June 16, 2024

Yeah absolutely.

Browser: Chrome 38.0.2125.104
Angular: v1.2.0
OS: Mac Yosemite

Unfortunately I can't upload it as it's a company project. We defaulted to a type=text field in the end (client deadlines). But you can view the test environment here: url removed 9/4/2015 . It'll be up for a week or so, hope this helps.

from angular-placeholder.

fidian avatar fidian commented on June 16, 2024

Interestingly, this is because of the validation associated with <input type="email">. I found discussion on this as Angular issue #1426. I guess I can't use the model's value and instead much check if the element has a value. I have a demo up on Plunker that really shows this off well. Enter a valid email and the form below updates. Any time the email is invalid, the value on the model is empty.

from angular-placeholder.

fidian avatar fidian commented on June 16, 2024

I made a change that works for me - could you test the issue-5 branch to see how well it works for you?

from angular-placeholder.

CullenShane avatar CullenShane commented on June 16, 2024

Issue-5 branch is working quite nicely for this issue.

from angular-placeholder.

vitvad avatar vitvad commented on June 16, 2024

Issue-5 branch fix this issue and seems fix issues/9

from angular-placeholder.

fidian avatar fidian commented on June 16, 2024

Merged.

from angular-placeholder.

Related Issues (12)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.