在显示表单和编辑表单上为多个行字段添加替代颜色 [英] add alternative color to multiple lines field on display form and edit form

查看:86
本文介绍了在显示表单和编辑表单上为多个行字段添加替代颜色的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个名为'Comments'的字段,其中包含多行并附加。 该字段是增强的富文本。 我写了一个css代码,在每个人的条目上都有替代颜色(人名和评论)。 它有效,见下面的代码。


.myClass-comments div:nth-​​child(even){


    background-color:lightgrey;


}


按要求将字段更改为纯文本后,备用颜色不再有效。  ;有没有人有建议?


谢谢,


Jen

解决方案

< blockquote>


渲染不同以增强丰富的纯文本格式,您可以使用开发人员工具进行检查(浏览器中的F12)。


如果您需要帮助要自定义背景颜色,您可以提供字段内容和所需的结果屏幕截图,以便我们尝试进行测试。








最好的问候,


Lee


I have a field named as 'Comments' with multiple lines and appended.  The field is enhanced rich text.  I write a css code to have alternative color on every one's entry (person's name and comment).  It works, see code below.

.myClass-comments div:nth-child(even) {

    background-color: lightgrey;

}

After I change the field to plain text by requirement, the alternate color doesn't work anymore.  Does anyone have a suggestion?

Thanks,

Jen

解决方案

Hi,

The render is different for enhanced rich and plain text format, you could use developer tool to check it(F12 in browser).

If you need assistance to custom the background-color, you could provide the field content and desired result screenshot so we could try to test.



Best Regards,

Lee


这篇关于在显示表单和编辑表单上为多个行字段添加替代颜色的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆