我是SCSS的新手。我试图将我的占位符文本从浅灰色转换为深灰色。 附件是html代码:无法在Scss中设置占位符文本的样式
<div class="form-group">
<textarea class="thread-textarea" ng-maxlength="255" maxlength="255" ng-model="newMessage.Content" ng-keyup="keycount($event)"placeholder="If this is an emergency, call 911. Otherwise, type your message here. We try to respond within 24 hours."title="Type your message" spellcheck="true" aria-labelledby="typeYourMessage"></textarea>
<span class="aria-hidden" id="typeYourMessage">Type your message</span>
</div>
附件是我的相关SCSS代码。
$darkgrey: #333333;
textarea{
@include placeholder
{
color: $darkgrey;
}
}
我想将占位符的颜色从灰色改为深灰色。任何帮助将不胜感激。
您使用的是波旁威士忌吗? –
这不是您选择输入占位符的方式。看到这里:http://stackoverflow.com/questions/2610497/change-an-inputs-html5-placeholder-color-with-css – Turnip
@Turnip与波旁威士忌它会这样工作:http://bourbon.io/docs /#placeholder我的猜测是波旁没有正确设置。 –