Help

欢迎!

该社区面向专业人士和我们产品和服务的爱好者。
分享和讨论最好的内容和新的营销理念,建立您的专业形象,一起成为更好的营销人员。


0

Can an underline be shown on fillable Form fields? Users need to hover to discover them. Labels and Selection fields look the same!

Avatar
odoo
Avatar
Discard
1 Answer
0
Avatar
odoo
Best Answer

A simple custom module can resolve this.

Versions - Odoo 16.0, 17.0, 18.0 and 19.0


Layout:

web_style
__init__.py
__manifest__.py
static/static/src/css/style.css


Contents:

__init__.py

(empty)


__manifest__.py

{
    'name': "Web Style: Underline Fields",
    'depends': ['web'],
    'license': 'LGPL-3',
    'assets': {
        'web.assets_backend': [
            'web_style/static/src/css/style.css',
        ],
    },
}


static/static/src/css/style.css

/* Add a soft underline to all fields in the form view */

.o_form_view:not(.o_field_highlight)

.o_field_widget:not(.o_field_invalid):not(.o_field_highlight)

.o_input:not(:hover):not(:focus) {

    --o-input-border-color: var(--o-input-border-color-default, #E7E9ED);


Result:






Avatar
Discard