mirror of
https://github.com/ONLYOFFICE/web-apps.git
synced 2026-07-24 06:08:33 +08:00
[SSE] Fix insert function icon for scaling 250
This commit is contained in:
@ -84,6 +84,11 @@ define([
|
||||
title : this.tipFormula,
|
||||
placement : 'cursor'
|
||||
});
|
||||
this.$btnfunc.attr('ratio', 'ratio');
|
||||
this.applyScaling(Common.UI.Scaling.currentRatio());
|
||||
this.$btnfunc.on('app:scaling', function (e, info) {
|
||||
me.applyScaling(info.ratio);
|
||||
});
|
||||
|
||||
return this;
|
||||
},
|
||||
@ -99,6 +104,14 @@ define([
|
||||
this.btnNamedRanges.setDisabled(disabled);
|
||||
},
|
||||
|
||||
applyScaling: function (ratio) {
|
||||
if (ratio > 2 && !this.$btnfunc.find('svg.icon').length) {
|
||||
var icon_name = 'btn-function',
|
||||
svg_icon = '<svg class="icon"><use class="zoom-int" href="#%iconname"></use></svg>'.replace('%iconname', icon_name);
|
||||
this.$btnfunc.find('i.icon').after(svg_icon);
|
||||
}
|
||||
},
|
||||
|
||||
tipFormula: 'Insert Function',
|
||||
textManager: 'Manager'
|
||||
}, SSE.Views.CellEditor || {}));
|
||||
|
||||
Reference in New Issue
Block a user