[all] function to check 'isRtl' flag
This commit is contained in:
parent
7146701873
commit
15ce921714
|
@ -167,10 +167,15 @@ Common.Locale = new(function() {
|
|||
} else require(polyfills, _requireLang);
|
||||
} else _requireLang();
|
||||
|
||||
const _isCurrentRtl = function () {
|
||||
return false;
|
||||
};
|
||||
|
||||
return {
|
||||
apply: _applyLocalization,
|
||||
get: _get,
|
||||
getCurrentLanguage: _getCurrentLanguage
|
||||
getCurrentLanguage: _getCurrentLanguage,
|
||||
isCurrentLanguageRtl: _isCurrentRtl
|
||||
};
|
||||
|
||||
})();
|
||||
|
|
|
@ -1091,4 +1091,13 @@ Common.Utils.getKeyByValue = function(obj, value) {
|
|||
return prop;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
Common.UI.isRTL = function () {
|
||||
if ( window.isrtl == undefined ) {
|
||||
window.isrtl = Common.localStorage.itemExists('ui-rtl') ?
|
||||
Common.localStorage.getBool("ui-rtl") : Common.Locale.isCurrentLanguageRtl();
|
||||
}
|
||||
|
||||
return window.isrtl;
|
||||
};
|
Loading…
Reference in a new issue