|
1 | | -#nyaBsConfigProvider |
| 1 | +# nyaBsConfigProvider |
2 | 2 |
|
3 | 3 | This provider help the developer configure the default text appearance of nya-bs-select base on user-agent localization. Default implementation of the locale text is `en-us`. |
4 | 4 |
|
@@ -32,29 +32,41 @@ There are three default text can be configured. Each one has two form, pure text |
32 | 32 | <p>**To show a count of selected items. this text string or template should contains a `%d` which will be replaced with number**</p> |
33 | 33 | </td> |
34 | 34 | </tr> |
| 35 | +<tr> |
| 36 | + <td>selectAll</td> |
| 37 | + <td>selectAllTpl</td> |
| 38 | + <td>selectAll is the action button to select all options by a single click. It is available by setting actions-box="true"</td> |
| 39 | +</tr> |
| 40 | +<tr> |
| 41 | + <td>deselectAll</td> |
| 42 | + <td>deselectAllTpl</td> |
| 43 | + <td>deselectAll is the action button to deselect all options by a single click. It is available by setting actions-box="true"</td> |
| 44 | +</tr> |
35 | 45 | </tbody> |
36 | 46 | </table> |
37 | 47 |
|
38 | 48 | >NOTE: You shouldn't use any angular directive or expression in template, it will not be parsed. |
39 | 49 |
|
40 | | -###Methods |
| 50 | +### Methods |
41 | 51 |
|
42 | | -####`setLocalizedText(localeId, configObj);` |
| 52 | +#### `setLocalizedText(localeId, configObj);` |
43 | 53 |
|
44 | 54 | Register a new locale configuration or override an existing locale configuration. |
45 | 55 |
|
46 | 56 | - `localeId` a string formatted as languageId-countryId, e.g. en-us |
47 | | -- `configObj` a localized configuration object. should contain one of the three properties. |
| 57 | +- `configObj` a localized configuration object. should contain one of the five properties. |
48 | 58 |
|
49 | 59 | ```javascript |
50 | 60 | { |
51 | 61 | defaultNoneSelection: 'Nothing selected', |
52 | 62 | noSearchResult: 'NO SEARCH RESULT', |
53 | | - numberItemSelected: '%d item selected' |
| 63 | + numberItemSelected: '%d item selected', |
| 64 | + selectAll: 'Select All', |
| 65 | + deselectAll: 'Deselect All' |
54 | 66 | } |
55 | 67 | ``` |
56 | 68 |
|
57 | | -####`useLocale(localeId);` |
| 69 | +#### `useLocale(localeId);` |
58 | 70 |
|
59 | 71 | Force to use a special locale configuration with given localeId. |
60 | 72 |
|
|
0 commit comments