Firefox 和 Angular:Textarea 占位符直到第一个焦点才出现 [英] Firefox and Angular: Textarea placeholder doesn't appear until first focus
问题描述
我有一个超级简单的 Angular 应用:
<ul><textarea placeholder='Hello'></textarea>
就是这样.没有 JS/CSS.
在 FF(OSX 上的 34.0)中,Textarea 中的占位符在 textarea 聚焦之前不会显示.
到目前为止我发现了什么:
- 它仅在 textarea 上.文本输入没问题.
- 仅当它在子 $scope 内时.如果
ng-if
不存在,问题就会消失.
试试看这里.
我没有想法了.任何帮助将不胜感激!:)
这是 Gecko 中的一个错误,已解决:https://bugzilla.mozilla.org/show_bug.cgi?id=1088158
修复程序应该会在几个月内稳定发布,但同时,对于给您带来的不便,我们深表歉意.
I have a super-simple Angular app:
<div ng-app>
<ul>
<li ng_if='true'>
<textarea placeholder='Hello'></textarea>
</li>
</ul>
</div>
That's it. No JS / CSS.
In FF (34.0 on OSX), the placeholder in the Textarea will not show up until the textarea is focused.
What I've discovered thus far:
- It's only on textarea. Text inputs are fine.
- It's only when it's within a child $scope. If the
ng-if
wasn't there, the issue would disappear.
Play around with it here.
I'm out of ideas. Any help would be super appreciated! :)
This is a bug in Gecko, which has been resolved: https://bugzilla.mozilla.org/show_bug.cgi?id=1088158
The fix should be shipped in stable in a few months, but in the meantime, sorry for the inconvenience.
这篇关于Firefox 和 Angular:Textarea 占位符直到第一个焦点才出现的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!