[IMP] website: reduce space between icons in Rating snippet

Part of https://github.com/odoo/odoo/pull/46809
task-2182909
This commit is contained in:
Cocographique
2020-03-24 13:14:14 +00:00
committed by qsm-odoo
parent 3eb7314870
commit 5dc2af38c3
2 changed files with 8 additions and 8 deletions
@@ -46,7 +46,7 @@ options.registry.Rating = options.Class.extend({
this._saving = false;
dialog.on('save', this, function (attachments) {
this._saving = true;
const customClass = 'fa fa-fw ' + attachments.className;
const customClass = 'fa ' + attachments.className;
const $activeIcons = this.$target.find('.s_rating_active_icons > i');
const $inactiveIcons = this.$target.find('.s_rating_inactive_icons > i');
const $icons = params.customActiveIcon === 'true' ? $activeIcons : $inactiveIcons;
@@ -140,8 +140,8 @@ options.registry.Rating = options.Class.extend({
'fa-square': 'fa-square-o',
'fa-heart': 'fa-heart-o'
};
const faClassActiveIcons = (this.iconType === "custom") ? this.faClassActiveCustomIcons : 'fa fa-fw ' + this.iconType;
const faClassInactiveIcons = (this.iconType === "custom") ? this.faClassInactiveCustomIcons : 'fa fa-fw ' + icons[this.iconType];
const faClassActiveIcons = (this.iconType === "custom") ? this.faClassActiveCustomIcons : 'fa ' + this.iconType;
const faClassInactiveIcons = (this.iconType === "custom") ? this.faClassInactiveCustomIcons : 'fa ' + icons[this.iconType];
const $activeIcons = this.$target.find('.s_rating_active_icons > i');
const $inactiveIcons = this.$target.find('.s_rating_inactive_icons > i');
$activeIcons.removeClass().addClass(faClassActiveIcons);
+5 -5
View File
@@ -6,13 +6,13 @@
<h4 class="s_rating_title">Quality</h4>
<div class="s_rating_icons o_not_editable">
<span class="s_rating_active_icons">
<i class="fa fa-fw fa-star"/>
<i class="fa fa-fw fa-star"/>
<i class="fa fa-fw fa-star"/>
<i class="fa fa-star"/>
<i class="fa fa-star"/>
<i class="fa fa-star"/>
</span>
<span class="s_rating_inactive_icons">
<i class="fa fa-fw fa-star-o"/>
<i class="fa fa-fw fa-star-o"/>
<i class="fa fa-star-o"/>
<i class="fa fa-star-o"/>
</span>
</div>
</div>