mirror of
https://github.com/OCA/web.git
synced 2025-02-22 13:21:25 +02:00
[ADD] web_save_discard_button module
This commit is contained in:
@@ -0,0 +1,65 @@
|
||||
.o_form_status_indicator_buttons {
|
||||
margin-left: 10px;
|
||||
|
||||
.o_form_button_save,
|
||||
.o_form_button_cancel {
|
||||
width: 100%;
|
||||
|
||||
&.o_form_button_save {
|
||||
background-color: $primary;
|
||||
|
||||
&:hover {
|
||||
filter: brightness(0.9);
|
||||
}
|
||||
}
|
||||
|
||||
&.o_form_button_cancel {
|
||||
margin-left: 5px;
|
||||
|
||||
&:hover {
|
||||
background-color: #f6f7fa;
|
||||
border-color: #e0e2e6;
|
||||
}
|
||||
}
|
||||
|
||||
.save_button {
|
||||
width: 100%;
|
||||
font-weight: 500;
|
||||
color: white;
|
||||
display: inline-block;
|
||||
text-align: center;
|
||||
vertical-align: middle;
|
||||
user-select: none;
|
||||
background-color: transparent;
|
||||
border: 1px solid transparent;
|
||||
padding: 0.3rem 2px;
|
||||
font-size: 1.08333333rem;
|
||||
line-height: 1.5;
|
||||
border-radius: 0;
|
||||
transition: none;
|
||||
width: 100%;
|
||||
text-transform: uppercase;
|
||||
font-family: $o-system-fonts;
|
||||
}
|
||||
|
||||
.discard_button {
|
||||
width: 100%;
|
||||
font-weight: 500;
|
||||
color: white;
|
||||
display: inline-block;
|
||||
text-align: center;
|
||||
vertical-align: middle;
|
||||
user-select: none;
|
||||
color: $primary;
|
||||
background-color: transparent;
|
||||
padding: 0.3rem 2px;
|
||||
font-size: 1.08333333rem;
|
||||
line-height: 1.5;
|
||||
border-radius: 0;
|
||||
transition: none;
|
||||
width: 100%;
|
||||
text-transform: uppercase;
|
||||
font-family: $o-system-fonts;
|
||||
}
|
||||
}
|
||||
}
|
||||
17
web_save_discard_button/static/src/xml/template.xml
Normal file
17
web_save_discard_button/static/src/xml/template.xml
Normal file
@@ -0,0 +1,17 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!-- Save and Discard Button-->
|
||||
<templates>
|
||||
<t
|
||||
t-name="web_save_discard_button.FormStatusIndicator"
|
||||
t-inherit="web.FormStatusIndicator"
|
||||
t-inherit-mode="extension"
|
||||
owl="1"
|
||||
>
|
||||
<xpath expr="//button/i[(hasclass('fa-cloud-upload'))]" position="replace">
|
||||
<span class="save_button">Save</span>
|
||||
</xpath>
|
||||
<xpath expr="//button/i[(hasclass('fa-undo'))]" position="replace">
|
||||
<span class="discard_button">Discard</span>
|
||||
</xpath>
|
||||
</t>
|
||||
</templates>
|
||||
Reference in New Issue
Block a user