From cbf7db74497271b7c5cf2e2201b445fb31661fe2 Mon Sep 17 00:00:00 2001 From: Josh Barnes Date: Fri, 1 Dec 2017 05:39:42 +0000 Subject: [PATCH] Compare non-specific language code for arabic numerals (#3055) Otherwise, country-specific locales like `ar-sa` (Arabic, Saudi Arabia), end up using the default numerals --- notebook/static/bidi/bidi.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/notebook/static/bidi/bidi.js b/notebook/static/bidi/bidi.js index 9ace652e0..4998dc80d 100644 --- a/notebook/static/bidi/bidi.js +++ b/notebook/static/bidi/bidi.js @@ -19,7 +19,7 @@ define(['bidi/numericshaping'], function(numericshaping) { console.log('Loaded moment locale', moment.locale(_uiLang())); }); - shaperType = _uiLang() == 'ar' ? 'national' : 'defaultNumeral'; + shaperType = _uiLang().split('-')[0] == 'ar' ? 'national' : 'defaultNumeral'; }; var _isMirroringEnabled = function() {