mirror of
https://git.proxmox.com/git/pmg-gui
synced 2025-06-04 21:29:15 +00:00

As the <b> tag in combination with extjs resulted in a "font-weight: bolder" setting which was not rendered correctly in Firefox. Use our own css class to set font-weight to bold. Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
35 lines
683 B
JavaScript
35 lines
683 B
JavaScript
Ext.define('PMG.MailInfoBox', {
|
|
extend: 'Ext.container.Container',
|
|
xtype: 'pmgMailInfo',
|
|
|
|
cls: 'x-toolbar-default',
|
|
style: {
|
|
'border-left': '0px',
|
|
'border-right': '0px',
|
|
},
|
|
|
|
update: function(data) {
|
|
let me = this;
|
|
let escaped = {};
|
|
for (const [key, value] of Object.entries(data)) {
|
|
escaped[key] = Ext.htmlEncode(value);
|
|
}
|
|
me.items.each((item) => item.update(escaped));
|
|
},
|
|
|
|
layout: {
|
|
type: 'vbox',
|
|
align: 'stretch',
|
|
},
|
|
|
|
defaults: {
|
|
xtype: 'tbtext',
|
|
margin: '2 2 0 0 ',
|
|
},
|
|
|
|
items: [
|
|
{ tpl: `<b class="bold">${gettext("From")}:</b> {from}` },
|
|
{ tpl: `<b class="bold">${gettext("Subject")}:</b> {subject}` },
|
|
],
|
|
});
|