Use fallback font stack for Lucida font
This commit is contained in:
@@ -140,5 +140,12 @@ define('handlebars_helpers', ['handlebars'], function(Handlebars) {
|
||||
return parseInt(string, 10);
|
||||
});
|
||||
|
||||
Handlebars.registerHelper('fontWithFallback', function(font) {
|
||||
switch(font) {
|
||||
case 'Lucida': return new Handlebars.SafeString("'Lucida Sans Unicode', 'Lucida Grande', sans-serif");
|
||||
default: return font;
|
||||
}
|
||||
});
|
||||
|
||||
window.Handlebars = Handlebars;
|
||||
});
|
||||
|
@@ -1,5 +1,5 @@
|
||||
<div class="mailpoet_tools"></div>
|
||||
<div class="mailpoet_content">
|
||||
<a href="{{ model.url }}" class="mailpoet_editor_button" style="{{#ifCond model.styles.block.textAlign '==' 'left'}}margin: 0 auto 0 0; {{/ifCond}}{{#ifCond model.styles.block.textAlign '==' 'center'}}margin: auto; {{/ifCond}}{{#ifCond model.styles.block.textAlign '==' 'right'}}margin: 0 0 0 auto; {{/ifCond}}line-height: {{ model.styles.block.lineHeight }}; width: {{ model.styles.block.width }}; background-color: {{ model.styles.block.backgroundColor }}; color: {{ model.styles.block.fontColor }}; font-family: {{ model.styles.block.fontFamily }}; font-size: {{ model.styles.block.fontSize }}; font-weight: {{ model.styles.block.fontWeight }}; border: {{ model.styles.block.borderWidth }} {{ model.styles.block.borderStyle }} {{ model.styles.block.borderColor }}; border-radius: {{ model.styles.block.borderRadius }};" onClick="return false;">{{ model.text }}</a>
|
||||
<a href="{{ model.url }}" class="mailpoet_editor_button" style="{{#ifCond model.styles.block.textAlign '==' 'left'}}margin: 0 auto 0 0; {{/ifCond}}{{#ifCond model.styles.block.textAlign '==' 'center'}}margin: auto; {{/ifCond}}{{#ifCond model.styles.block.textAlign '==' 'right'}}margin: 0 0 0 auto; {{/ifCond}}line-height: {{ model.styles.block.lineHeight }}; width: {{ model.styles.block.width }}; background-color: {{ model.styles.block.backgroundColor }}; color: {{ model.styles.block.fontColor }}; font-family: {{fontWithFallback model.styles.block.fontFamily }}; font-size: {{ model.styles.block.fontSize }}; font-weight: {{ model.styles.block.fontWeight }}; border: {{ model.styles.block.borderWidth }} {{ model.styles.block.borderStyle }} {{ model.styles.block.borderColor }}; border-radius: {{ model.styles.block.borderRadius }};" onClick="return false;">{{ model.text }}</a>
|
||||
</div>
|
||||
<div class="mailpoet_block_highlight"></div>
|
||||
|
@@ -3,7 +3,7 @@
|
||||
.mailpoet_editor_view_{{ viewCid }} .mailpoet_content,
|
||||
.mailpoet_editor_view_{{ viewCid }} .mailpoet_content p {
|
||||
color: {{ model.styles.text.fontColor }};
|
||||
font-family: {{ model.styles.text.fontFamily }};
|
||||
font-family: {{fontWithFallback model.styles.text.fontFamily }};
|
||||
font-size: {{ model.styles.text.fontSize }};
|
||||
background-color: {{ model.styles.block.backgroundColor }};
|
||||
text-align: {{ model.styles.text.textAlign }};
|
||||
|
@@ -3,7 +3,7 @@
|
||||
.mailpoet_editor_view_{{ viewCid }} .mailpoet_content,
|
||||
.mailpoet_editor_view_{{ viewCid }} .mailpoet_content p {
|
||||
color: {{ model.styles.text.fontColor }};
|
||||
font-family: {{ model.styles.text.fontFamily }};
|
||||
font-family: {{fontWithFallback model.styles.text.fontFamily }};
|
||||
font-size: {{ model.styles.text.fontSize }};
|
||||
background-color: {{ model.styles.block.backgroundColor }};
|
||||
text-align: {{ model.styles.text.textAlign }};
|
||||
|
@@ -3,22 +3,22 @@
|
||||
.mailpoet_text_block .mailpoet_content p {
|
||||
color: {{ text.fontColor }};
|
||||
font-size: {{ text.fontSize }};
|
||||
font-family: {{ text.fontFamily }};
|
||||
font-family: {{fontWithFallback text.fontFamily }};
|
||||
}
|
||||
.mailpoet_text_block .mailpoet_content h1 {
|
||||
color: {{ h1.fontColor }};
|
||||
font-size: {{ h1.fontSize }};
|
||||
font-family: {{ h1.fontFamily }};
|
||||
font-family: {{fontWithFallback h1.fontFamily }};
|
||||
}
|
||||
.mailpoet_text_block .mailpoet_content h2 {
|
||||
color: {{ h2.fontColor }};
|
||||
font-size: {{ h2.fontSize }};
|
||||
font-family: {{ h2.fontFamily }};
|
||||
font-family: {{fontWithFallback h2.fontFamily }};
|
||||
}
|
||||
.mailpoet_text_block .mailpoet_content h3 {
|
||||
color: {{ h3.fontColor }};
|
||||
font-size: {{ h3.fontSize }};
|
||||
font-family: {{ h3.fontFamily }};
|
||||
font-family: {{fontWithFallback h3.fontFamily }};
|
||||
}
|
||||
.mailpoet_content a {
|
||||
color: {{ link.fontColor }};
|
||||
|
Reference in New Issue
Block a user