Update webfonts and uls libs from upstream
Change-Id: I338950789e94e1638069ca97cf29cea2d78cf3b8
This commit is contained in:
@@ -12,7 +12,7 @@
|
|||||||
"uls-region-EU": "\u0415\u0432\u0440\u043e\u043f\u0430",
|
"uls-region-EU": "\u0415\u0432\u0440\u043e\u043f\u0430",
|
||||||
"uls-region-AS": "\u0410\u0437\u0438\u0458\u0430",
|
"uls-region-AS": "\u0410\u0437\u0438\u0458\u0430",
|
||||||
"uls-region-ME": "\u0411\u043b\u0438\u0437\u043e\u043a \u0418\u0441\u0442\u043e\u043a",
|
"uls-region-ME": "\u0411\u043b\u0438\u0437\u043e\u043a \u0418\u0441\u0442\u043e\u043a",
|
||||||
"uls-region-PA": "\u041f\u0430\u0446\u0438\u0444\u0438\u043a",
|
"uls-region-PA": "\u041e\u043a\u0435\u0430\u043d\u0438\u0458\u0430",
|
||||||
"uls-no-results-found": "\u041d\u0435 \u043f\u0440\u043e\u043d\u0430\u0458\u0434\u043e\u0432 \u043d\u0438\u0448\u0442\u043e",
|
"uls-no-results-found": "\u041d\u0435 \u043f\u0440\u043e\u043d\u0430\u0458\u0434\u043e\u0432 \u043d\u0438\u0448\u0442\u043e",
|
||||||
"uls-common-languages": "\u041f\u043e\u0437\u0430\u0441\u0442\u0430\u043f\u0435\u043d\u0438 \u0458\u0430\u0437\u0438\u0446\u0438",
|
"uls-common-languages": "\u041f\u043e\u0437\u0430\u0441\u0442\u0430\u043f\u0435\u043d\u0438 \u0458\u0430\u0437\u0438\u0446\u0438",
|
||||||
"uls-no-results-suggestion-title": "\u041c\u043e\u0436\u0435 \u0434\u0430 \u0432\u0435 \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u0438\u0440\u0430\u0430\u0442:",
|
"uls-no-results-suggestion-title": "\u041c\u043e\u0436\u0435 \u0434\u0430 \u0432\u0435 \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u0438\u0440\u0430\u0430\u0442:",
|
||||||
|
|||||||
@@ -16,7 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
( function( $, window, document, undefined ) {
|
( function( $, window, document, undefined ) {
|
||||||
"use strict";
|
'use strict';
|
||||||
|
|
||||||
var WebFonts = function( element, options ) {
|
var WebFonts = function( element, options ) {
|
||||||
// Load defaults
|
// Load defaults
|
||||||
@@ -252,50 +252,50 @@
|
|||||||
|
|
||||||
base = this.repository.base;
|
base = this.repository.base;
|
||||||
version = fontconfig.version;
|
version = fontconfig.version;
|
||||||
versionSuffix = "?version=" + version + '&20120101';
|
versionSuffix = '?version=' + version + '&20120101';
|
||||||
styleString = "@font-face { font-family: '" + fontFamily + "';\n";
|
styleString = '@font-face { font-family: \'' + fontFamily + '\';\\n';
|
||||||
userAgent = window.navigator.userAgent;
|
userAgent = window.navigator.userAgent;
|
||||||
fontStyle = fontconfig.fontstyle || 'normal';
|
fontStyle = fontconfig.fontstyle || 'normal';
|
||||||
fontFormats = [];
|
fontFormats = [];
|
||||||
|
|
||||||
if ( fontconfig.eot ) {
|
if ( fontconfig.eot ) {
|
||||||
styleString += "\tsrc: url('" + base + fontconfig.eot + versionSuffix + "');\n";
|
styleString += '\\tsrc: url(\'' + base + fontconfig.eot + versionSuffix + '\');\\n';
|
||||||
}
|
}
|
||||||
styleString += "\tsrc: ";
|
styleString += '\\tsrc: ';
|
||||||
// If the font is present locally, use it.
|
// If the font is present locally, use it.
|
||||||
if ( userAgent.match( /Android 2\.3/ ) === null ) {
|
if ( userAgent.match( /Android 2\.3/ ) === null ) {
|
||||||
// Android 2.3.x does not respect local() syntax.
|
// Android 2.3.x does not respect local() syntax.
|
||||||
// http://code.google.com/p/android/issues/detail?id=10609
|
// http://code.google.com/p/android/issues/detail?id=10609
|
||||||
styleString += "local('" + fontFamily + "'),";
|
styleString += 'local(\'' + fontFamily + '\'),';
|
||||||
}
|
}
|
||||||
if ( fontconfig.woff ) {
|
if ( fontconfig.woff ) {
|
||||||
fontFormats.push( "\t\turl('" + base + fontconfig.woff + versionSuffix
|
fontFormats.push( '\\t\\turl(\'' + base + fontconfig.woff + versionSuffix
|
||||||
+ "') format('woff')" );
|
+ '\') format(\'woff\')' );
|
||||||
}
|
}
|
||||||
if ( fontconfig.svg ) {
|
if ( fontconfig.svg ) {
|
||||||
fontFormats.push( "\t\turl('" + base + fontconfig.svg + versionSuffix + "#"
|
fontFormats.push( '\\t\\turl(\'' + base + fontconfig.svg + versionSuffix + '#'
|
||||||
+ fontFamily + "') format('svg')" );
|
+ fontFamily + '\') format(\'svg\')' );
|
||||||
}
|
}
|
||||||
if ( fontconfig.ttf ) {
|
if ( fontconfig.ttf ) {
|
||||||
fontFormats.push( "\t\turl('" + base + fontconfig.ttf + versionSuffix
|
fontFormats.push( '\\t\\turl(\'' + base + fontconfig.ttf + versionSuffix
|
||||||
+ "') format('truetype')" );
|
+ '\') format(\'truetype\')' );
|
||||||
}
|
}
|
||||||
styleString += fontFormats.join() + ";\n";
|
styleString += fontFormats.join() + ';\\n';
|
||||||
if ( fontconfig.fontweight ) {
|
if ( fontconfig.fontweight ) {
|
||||||
styleString += "\tfont-weight:" + fontconfig.fontweight + ";";
|
styleString += '\\tfont-weight:' + fontconfig.fontweight + ';';
|
||||||
}
|
}
|
||||||
styleString += "\tfont-style:" + fontStyle + ";";
|
styleString += '\\tfont-style:' + fontStyle + ';';
|
||||||
|
|
||||||
if ( fontconfig.fontweight !== undefined ) {
|
if ( fontconfig.fontweight !== undefined ) {
|
||||||
styleString += "\tfont-weight:" + fontconfig.fontweight + ";";
|
styleString += '\font-weight:' + fontconfig.fontweight + ';';
|
||||||
}
|
}
|
||||||
if ( fontconfig.fontstyle !== undefined ) {
|
if ( fontconfig.fontstyle !== undefined ) {
|
||||||
styleString += "\tfont-style:" + fontconfig.fontstyle + ";";
|
styleString += '\\tfont-style:' + fontconfig.fontstyle + ';';
|
||||||
} else {
|
} else {
|
||||||
styleString += "\tfont-style: normal;";
|
styleString += '\\tfont-style: normal;';
|
||||||
}
|
}
|
||||||
|
|
||||||
styleString += "}";
|
styleString += '}';
|
||||||
|
|
||||||
if ( fontconfig.variants !== undefined ) {
|
if ( fontconfig.variants !== undefined ) {
|
||||||
$.each( fontconfig.variants, function ( variant, variantFontFamily ) {
|
$.each( fontconfig.variants, function ( variant, variantFontFamily ) {
|
||||||
|
|||||||
Reference in New Issue
Block a user