22from appconf import AppConf
33from django .conf import settings # NOQA
44
5- __all__ = (' settings' , ' Select2Conf' )
5+ __all__ = (" settings" , " Select2Conf" )
66
77
88class Select2Conf (AppConf ):
99 """Settings for Django-Select2."""
1010
11- LIB_VERSION = ' 4.0.12'
11+ LIB_VERSION = " 4.0.12"
1212 """Version of the Select2 library."""
1313
14- CACHE_BACKEND = ' default'
14+ CACHE_BACKEND = " default"
1515 """
1616 Django-Select2 uses Django's cache to sure a consistent state across multiple machines.
1717
@@ -49,14 +49,16 @@ class Select2Conf(AppConf):
4949 how long a browser session can last.
5050 Once widget is dropped from the cache the json response view will return a 404.
5151 """
52- CACHE_PREFIX = ' select2_'
52+ CACHE_PREFIX = " select2_"
5353 """
5454 If you caching backend does not support multiple databases
5555 you can isolate select2 using the cache prefix setting.
5656 It has set `select2_` as a default value, which you can change if needed.
5757 """
5858
59- JS = 'https://cdnjs.cloudflare.com/ajax/libs/select2/{version}/js/select2.min.js' .format (version = LIB_VERSION )
59+ JS = "https://cdnjs.cloudflare.com/ajax/libs/select2/{version}/js/select2.min.js" .format (
60+ version = LIB_VERSION
61+ )
6062 """
6163 The URI for the Select2 JS file. By default this points to the Cloudflare CDN.
6264
@@ -74,7 +76,9 @@ class Select2Conf(AppConf):
7476 develop without an Internet connection.
7577 """
7678
77- CSS = 'https://cdnjs.cloudflare.com/ajax/libs/select2/{version}/css/select2.min.css' .format (version = LIB_VERSION )
79+ CSS = "https://cdnjs.cloudflare.com/ajax/libs/select2/{version}/css/select2.min.css" .format (
80+ version = LIB_VERSION
81+ )
7882 """
7983 The URI for the Select2 CSS file. By default this points to the Cloudflare CDN.
8084
@@ -92,7 +96,9 @@ class Select2Conf(AppConf):
9296 develop without an Internet connection.
9397 """
9498
95- I18N_PATH = 'https://cdnjs.cloudflare.com/ajax/libs/select2/{version}/js/i18n' .format (version = LIB_VERSION )
99+ I18N_PATH = "https://cdnjs.cloudflare.com/ajax/libs/select2/{version}/js/i18n" .format (
100+ version = LIB_VERSION
101+ )
96102 """
97103 The base URI for the Select2 i18n files. By default this points to the Cloudflare CDN.
98104
@@ -106,53 +112,53 @@ class Select2Conf(AppConf):
106112 """
107113
108114 I18N_AVAILABLE_LANGUAGES = [
109- 'ar' ,
110- 'az' ,
111- 'bg' ,
112- 'ca' ,
113- 'cs' ,
114- 'da' ,
115- 'de' ,
116- 'el' ,
117- 'en' ,
118- 'es' ,
119- 'et' ,
120- 'eu' ,
121- 'fa' ,
122- 'fi' ,
123- 'fr' ,
124- 'gl' ,
125- 'he' ,
126- 'hi' ,
127- 'hr' ,
128- 'hu' ,
129- 'id' ,
130- 'is' ,
131- 'it' ,
132- 'ja' ,
133- 'km' ,
134- 'ko' ,
135- 'lt' ,
136- 'lv' ,
137- 'mk' ,
138- 'ms' ,
139- 'nb' ,
140- 'nl' ,
141- 'pl' ,
142- ' pt-BR' ,
143- 'pt' ,
144- 'ro' ,
145- 'ru' ,
146- 'sk' ,
147- ' sr-Cyrl' ,
148- 'sr' ,
149- 'sv' ,
150- 'th' ,
151- 'tr' ,
152- 'uk' ,
153- 'vi' ,
154- ' zh-CN' ,
155- ' zh-TW' ,
115+ "ar" ,
116+ "az" ,
117+ "bg" ,
118+ "ca" ,
119+ "cs" ,
120+ "da" ,
121+ "de" ,
122+ "el" ,
123+ "en" ,
124+ "es" ,
125+ "et" ,
126+ "eu" ,
127+ "fa" ,
128+ "fi" ,
129+ "fr" ,
130+ "gl" ,
131+ "he" ,
132+ "hi" ,
133+ "hr" ,
134+ "hu" ,
135+ "id" ,
136+ "is" ,
137+ "it" ,
138+ "ja" ,
139+ "km" ,
140+ "ko" ,
141+ "lt" ,
142+ "lv" ,
143+ "mk" ,
144+ "ms" ,
145+ "nb" ,
146+ "nl" ,
147+ "pl" ,
148+ " pt-BR" ,
149+ "pt" ,
150+ "ro" ,
151+ "ru" ,
152+ "sk" ,
153+ " sr-Cyrl" ,
154+ "sr" ,
155+ "sv" ,
156+ "th" ,
157+ "tr" ,
158+ "uk" ,
159+ "vi" ,
160+ " zh-CN" ,
161+ " zh-TW" ,
156162 ]
157163 """
158164 List of available translations.
@@ -177,4 +183,4 @@ class Select2Conf(AppConf):
177183 class Meta :
178184 """Prefix for all Django-Select2 settings."""
179185
180- prefix = ' SELECT2'
186+ prefix = " SELECT2"
0 commit comments