[IMP] google_calendar: change color of synced pill.

This commit is contained in:
Aurélien (avd)
2021-01-18 09:23:19 +00:00
parent bace7e66de
commit f20edbbe74
3 changed files with 10 additions and 2 deletions
@@ -192,7 +192,7 @@ const GoogleCalendarRenderer = CalendarRenderer.include({
_initGooglePillButton: function() {
this.$googleStopButton.css({"cursor":"pointer", "font-size":"0.9em"});
var switchBadgeClass = (elem) => {elem.toggleClass('badge-success'); elem.toggleClass('badge-danger');};
var switchBadgeClass = (elem) => {elem.toggleClass('badge-primary'); elem.toggleClass('badge-danger');};
this.$('.o_stop_google_sync_button').hover(() => {
switchBadgeClass(this.$googleStopButton);
this.$googleStopButton.html("<i class='fa mr-2 fa-times'/>".concat(_t("Stop the Synchronization")));
@@ -213,7 +213,7 @@ const GoogleCalendarRenderer = CalendarRenderer.include({
_getGoogleStopButton: function () {
return $('<span/>', {
html: _t("Synched with Google"),
class: 'w-100 badge badge-pill badge-success border-0 o_stop_google_sync_button'
class: 'w-100 badge badge-pill badge-primary border-0 o_stop_google_sync_button'
})
.prepend($('<i/>', {class: "fa mr-2 fa-check"}));
},
@@ -0,0 +1,5 @@
.o_calendar_sidebar {
.badge-primary {
background-color: $o-enterprise-primary-color;
}
}
@@ -5,6 +5,9 @@
<script type="text/javascript" src="/google_calendar/static/src/js/google_calendar_popover.js"></script>
<script type="text/javascript" src="/google_calendar/static/src/js/google_calendar.js"></script>
</xpath>
<xpath expr="link[last()]" position="after">
<link rel="stylesheet" type="text/scss" href="/google_calendar/static/src/scss/google_calendar.scss"/>
</xpath>
</template>
<template id="qunit_suite" name="google_calendar_tests" inherit_id="web.qunit_suite_tests">