调整 form 表单的 只读模式下的 状态.

This commit is contained in:
sunjie
2025-07-15 23:48:18 +08:00
parent 093f211ba7
commit f15104d054
@@ -23,6 +23,23 @@
.o_input {
background: transparent !important;font-size: 14px !important;border-bottom: 2px solid $primaryColor;
}
}
/** 只读模式下的数据 **/
.o_form_readonly {
.o_field_widget {
&:not(.o_field_boolean){
border: 1.5px solid rgba(0, 0, 0, .15);transition: all .7s ease;box-shadow: 0 1px 15px 1px rgba(69 ,65, 78 , 0.08);outline: none;background-color: #fff;padding: 6px 10px;border-radius: 5px;position: relative;margin-bottom: 5px !important;
}
}
.o_field_empty{
span{
height: 20px;
display: block;
}
}
}
}
@if $form_element_style == 'style_2'{
@@ -70,6 +87,23 @@
--o-input-border-color: #dc3545 !important;--o-caret-color: #dc3545 !important;
}
}
/** 只读模式下的数据 **/
.o_form_readonly {
.o_field_widget {
&:not(.o_field_boolean){
border: 1.5px solid rgba(0, 0, 0, .15);transition: all .7s ease;box-shadow: 0 1px 15px 1px rgba(69 ,65, 78 , 0.08);outline: none;background-color: #fff;padding: 6px 10px;border-radius: 5px;position: relative;margin-bottom: 5px !important;
}
}
.o_field_empty{
span{
height: 20px;
display: block;
}
}
}
}
@if $form_element_style == 'style_3'{
@@ -135,6 +169,23 @@
--o-input-border-color: #dc3545 !important;--o-caret-color: #dc3545 !important;
}
}
/** 只读模式下的数据 **/
.o_form_readonly {
.o_field_widget {
&:not(.o_field_boolean){
border: 1.5px solid rgba(0, 0, 0, .15);transition: all .7s ease;box-shadow: 0 1px 15px 1px rgba(69 ,65, 78 , 0.08);outline: none;background-color: #fff;padding: 6px 10px;border-radius: 5px;position: relative;margin-bottom: 5px !important;
}
}
.o_field_empty{
span{
height: 20px;
display: block;
}
}
}
}
@if $form_element_style == 'style_4'{
.o_input {
@@ -173,6 +224,23 @@
}
}
/** 只读模式下的数据 **/
.o_form_readonly {
.o_field_widget {
&:not(.o_field_boolean){
border: 1.5px solid rgba(0, 0, 0, .15);transition: all .7s ease;box-shadow: 0 1px 15px 1px rgba(69 ,65, 78 , 0.08);outline: none;background-color: #fff;padding: 6px 10px;border-radius: 5px;position: relative;margin-bottom: 5px !important;
}
}
.o_field_empty{
span{
height: 20px;
display: block;
}
}
}
}
@if $form_element_style == 'style_5'{
.o_input {
@@ -211,6 +279,23 @@
border-radius: 0px 15px 0px 15px !important;
}
/** 只读模式下的数据 **/
.o_form_readonly {
.o_field_widget {
&:not(.o_field_boolean){
border: 1.5px solid rgba(0, 0, 0, .15);transition: all .7s ease;box-shadow: 0 1px 15px 1px rgba(69 ,65, 78 , 0.08);outline: none;background-color: #fff;padding: 6px 10px;border-radius: 5px;position: relative;margin-bottom: 5px !important;
}
}
.o_field_empty{
span{
height: 20px;
display: block;
}
}
}
}
@if $form_element_style == 'style_6'{
.o_input {
@@ -249,10 +334,27 @@
}
}
/** 只读模式下的数据 **/
.o_form_readonly {
.o_field_widget {
&:not(.o_field_boolean){
border: 1.5px solid rgba(0, 0, 0, .15);transition: all .7s ease;box-shadow: 0 1px 15px 1px rgba(69 ,65, 78 , 0.08);outline: none;background-color: #fff;padding: 6px 10px;border-radius: 5px;position: relative;margin-bottom: 5px !important;
}
}
.o_field_empty{
span{
height: 20px;
display: block;
}
}
}
}
@if $form_element_style == 'style_7'{
.o_input {
line-height: 34px;background-color: #fff;-webkit-border-radius: 0px;-moz-border-radius: 0px;border-radius: 0px;padding: 0 20px;color: #666;-webkit-transition: all .7s ease;-o-transition: all .7s ease;-moz-transition: all .7s ease;transition: all .7s ease;margin-bottom: 5px !important;border: 1px solid #ccc;border-top: 2px solid #ccc;align-items: center !important;
line-height: 34px;background-color: #fff;-webkit-border-radius: 0px;-moz-border-radius: 0px;border-radius: 0px;padding: 0 20px;color: #666;-webkit-transition: all .7s ease;-o-transition: all .7s ease;-moz-transition: all .7s ease;transition: all .7s ease;margin-bottom: 5px !important;border: 2px solid #ccc;border-top: 2px solid #ccc;align-items: center !important;
&:focus {
border-top: 2px solid $primaryColor !important;
}
@@ -287,6 +389,23 @@
}
}
/** 只读模式下的数据 **/
.o_form_readonly {
.o_field_widget {
&:not(.o_field_boolean){
border: 1.5px solid rgba(0, 0, 0, .15);transition: all .7s ease;box-shadow: 0 1px 15px 1px rgba(69 ,65, 78 , 0.08);outline: none;background-color: #fff;padding: 6px 10px;border-radius: 5px;position: relative;margin-bottom: 5px !important;
}
}
.o_field_empty{
span{
height: 20px;
display: block;
}
}
}
}
@if $form_element_style == 'style_8'{
.o_input {
@@ -363,4 +482,21 @@
border-radius: 20px !important;
}
/** 只读模式下的数据 **/
.o_form_readonly {
.o_field_widget {
&:not(.o_field_boolean){
border: 1.5px solid rgba(0, 0, 0, .15);transition: all .7s ease;box-shadow: 0 1px 15px 1px rgba(69 ,65, 78 , 0.08);outline: none;background-color: #fff;padding: 6px 10px;border-radius: 5px;position: relative;margin-bottom: 5px !important;
}
}
.o_field_empty{
span{
height: 20px;
display: block;
}
}
}
}