Fix bug 52949

This commit is contained in:
JuliaSvinareva 2021-10-05 21:58:41 +03:00
parent acd44354ee
commit 3c29838872
2 changed files with 8 additions and 6 deletions

View file

@ -463,7 +463,9 @@ Common.UI.HintManager = new(function() {
} }
} }
} }
if (curr.prop('id') === 'btn-goback' || curr.closest('.btn-slot').prop('id') === 'slot-btn-options' || curr.prop('id') === 'left-btn-thumbs' || curr.hasClass('scroll')) { if (curr.prop('id') === 'btn-goback' || curr.closest('.btn-slot').prop('id') === 'slot-btn-options' ||
curr.closest('.btn-slot').prop('id') === 'slot-btn-mode' || curr.prop('id') === 'btn-favorite' || curr.parent().prop('id') === 'tlb-box-users' ||
curr.prop('id') === 'left-btn-thumbs' || curr.hasClass('scroll')) {
_resetToDefault(); _resetToDefault();
return; return;
} }

View file

@ -476,14 +476,14 @@ define([
getPanel: function (role, config) { getPanel: function (role, config) {
var me = this; var me = this;
function createTitleButton(iconid, slot, disabled) { function createTitleButton(iconid, slot, disabled, hintDirection, hintOffset) {
return (new Common.UI.Button({ return (new Common.UI.Button({
cls: 'btn-header', cls: 'btn-header',
iconCls: iconid, iconCls: iconid,
disabled: disabled === true, disabled: disabled === true,
dataHint:'0', dataHint:'0',
dataHintDirection: 'left', dataHintDirection: hintDirection ? hintDirection : 'left',
dataHintOffset: '10, 10' dataHintOffset: hintOffset ? hintOffset : '10, 10'
})).render(slot); })).render(slot);
} }
@ -546,7 +546,7 @@ define([
if (!config.isEdit || config.customization && !!config.customization.compactHeader) { if (!config.isEdit || config.customization && !!config.customization.compactHeader) {
if (config.user.guest && config.canRenameAnonymous) if (config.user.guest && config.canRenameAnonymous)
me.btnUserName = createTitleButton('toolbar__icon icon--inverse btn-user', $html.findById('#slot-btn-user-name')); me.btnUserName = createTitleButton('toolbar__icon icon--inverse btn-user', $html.findById('#slot-btn-user-name'), undefined, 'bottom', 'big');
else { else {
me.elUserName = $html.find('.btn-current-user'); me.elUserName = $html.find('.btn-current-user');
me.elUserName.removeClass('hidden'); me.elUserName.removeClass('hidden');
@ -562,7 +562,7 @@ define([
if ( !!window.DE ) { if ( !!window.DE ) {
var mode_cls = Common.UI.Themes.isContentThemeDark() ? 'btn-mode-light' : 'btn-mode-dark'; var mode_cls = Common.UI.Themes.isContentThemeDark() ? 'btn-mode-light' : 'btn-mode-dark';
me.btnContentMode = createTitleButton('toolbar__icon icon--inverse ' + mode_cls, $html.findById('#slot-btn-mode')); me.btnContentMode = createTitleButton('toolbar__icon icon--inverse ' + mode_cls, $html.findById('#slot-btn-mode'), undefined, 'bottom', 'big');
me.btnContentMode.setVisible(Common.UI.Themes.isDarkTheme()); me.btnContentMode.setVisible(Common.UI.Themes.isDarkTheme());
} }