@@ -47,6 +47,7 @@ UI designs will be updated following the WeChat update in anytime.
47
47
* [ Usage] ( #usage- )
48
48
* [ Simple usage] ( #simple-usage )
49
49
* [ Detailed usage] ( #detailed-usage )
50
+ * [ Localizations] ( #localizations )
50
51
* [ Using custom delegate] ( #using-custom-delegate )
51
52
* [ Display selected assets] ( #display-selected-assets )
52
53
* [ Register assets change observe callback] ( #register-assets-change-observe-callback )
@@ -249,6 +250,27 @@ Fields in `AssetPickerConfig`:
249
250
TL;DR, we've put multiple common usage
250
251
with the packages in the [ example] ( example ) .
251
252
253
+ ### Localizations
254
+
255
+ When you're picking assets, the package will obtain the ` Locale? `
256
+ from your ` BuildContext ` , and return the corresponding text delegate
257
+ of the current language.
258
+ Make sure you have a valid ` Locale ` in your widget tree that can be accessed
259
+ from the ` BuildContext ` . Otherwise, ** the default Chinese delegate will be used.**
260
+
261
+ Embedded text delegates languages are:
262
+ * 简体中文 (default)
263
+ * English
264
+ * העברית
265
+ * Deutsche
266
+ * Локализация
267
+ * 日本語
268
+ * مة العربية
269
+ * Délégué
270
+
271
+ If you want to use a custom/fixed text delegate, pass it through the
272
+ ` AssetPickerConfig.textDelegate ` .
273
+
252
274
### Using custom delegate
253
275
254
276
You can use the ` keepScrollOffset ` feature
@@ -421,7 +443,7 @@ Many thanks to these wonderful people ([emoji key](https://allcontributors.org/d
421
443
<td align="center"><a href="https://github.com/maxzod"><img src="https://avatars.githubusercontent.com/u/47630729?v=4?s=50" width="50px;" alt="Ahmed Masoud "/><br /><sub><b>Ahmed Masoud </b></sub></a><br /><a href="#translation-maxzod" title="Translation">🌍</a></td>
422
444
<td align="center"><a href="https://github.com/luomo-pro"><img src="https://avatars.githubusercontent.com/u/41097395?v=4?s=50" width="50px;" alt="luomo-pro"/><br /><sub><b>luomo-pro</b></sub></a><br /><a href="#a11y-luomo-pro" title="Accessibility">️️️️♿️</a> <a href="https://github.com/fluttercandies/flutter_wechat_assets_picker/issues?q=author%3Aluomo-pro" title="Bug reports">🐛</a></td>
423
445
<td align="center"><a href="https://github.com/paigupai"><img src="https://avatars.githubusercontent.com/u/44311361?v=4?s=50" width="50px;" alt="paigupai"/><br /><sub><b>paigupai</b></sub></a><br /><a href="#translation-paigupai" title="Translation">🌍</a></td>
424
- <td align="center"><a href="http ://taqi.me "><img src="https://avatars.githubusercontent.com/u/30410316?v=4?s=50" width="50px;" alt="Muhammad Taqi Abdul Aziz"/><br /><sub><b>Muhammad Taqi Abdul Aziz</b></sub></a><br /><a href="https://github.com/fluttercandies/flutter_wechat_assets_picker/commits?author=taqiabdulaziz" title="Documentation">📖</a></td>
446
+ <td align="center"><a href="https ://github.com/taqiabdulaziz "><img src="https://avatars.githubusercontent.com/u/30410316?v=4?s=50" width="50px;" alt="Muhammad Taqi Abdul Aziz"/><br /><sub><b>Muhammad Taqi Abdul Aziz</b></sub></a><br /><a href="https://github.com/fluttercandies/flutter_wechat_assets_picker/commits?author=taqiabdulaziz" title="Documentation">📖</a></td>
425
447
<td align="center"><a href="http://blog.1qa.link"><img src="https://avatars.githubusercontent.com/u/8766034?v=4?s=50" width="50px;" alt="何锦余"/><br /><sub><b>何锦余</b></sub></a><br /><a href="https://github.com/fluttercandies/flutter_wechat_assets_picker/issues?q=author%3Ahellohejinyu" title="Bug reports">🐛</a></td>
426
448
</tr>
427
449
</tbody >
0 commit comments