diff options
Diffstat (limited to 'support/doc/plugins')
-rw-r--r-- | support/doc/plugins/guide.md | 23 |
1 files changed, 16 insertions, 7 deletions
diff --git a/support/doc/plugins/guide.md b/support/doc/plugins/guide.md index 85aaf9f02..072c7c6ca 100644 --- a/support/doc/plugins/guide.md +++ b/support/doc/plugins/guide.md | |||
@@ -180,6 +180,15 @@ function register (...) { | |||
180 | type: 'input', | 180 | type: 'input', |
181 | // type: 'input' | 'input-checkbox' | 'input-password' | 'input-textarea' | 'markdown-text' | 'markdown-enhanced' | 'select' | 'html' | 181 | // type: 'input' | 'input-checkbox' | 'input-password' | 'input-textarea' | 'markdown-text' | 'markdown-enhanced' | 'select' | 'html' |
182 | 182 | ||
183 | // If type: 'select', give the select available options | ||
184 | options: [ | ||
185 | { label: 'Label 1', value: 'value1' }, | ||
186 | { label: 'Label 2', value: 'value2' } | ||
187 | ], | ||
188 | |||
189 | // If type: 'html', set the HTML that will be injected in the page | ||
190 | html: '<strong class="...">Hello</strong><br /><br />' | ||
191 | |||
183 | // Optional | 192 | // Optional |
184 | descriptionHTML: 'The purpose of this field is...', | 193 | descriptionHTML: 'The purpose of this field is...', |
185 | 194 | ||
@@ -196,7 +205,7 @@ function register (...) { | |||
196 | result['admin-name] | 205 | result['admin-name] |
197 | 206 | ||
198 | settingsManager.onSettingsChange(settings => { | 207 | settingsManager.onSettingsChange(settings => { |
199 | settings['admin-name]) | 208 | settings['admin-name'] |
200 | }) | 209 | }) |
201 | } | 210 | } |
202 | ``` | 211 | ``` |
@@ -237,12 +246,12 @@ function register ({ | |||
237 | You can add/delete video categories, licences or languages using the appropriate constant managers: | 246 | You can add/delete video categories, licences or languages using the appropriate constant managers: |
238 | 247 | ||
239 | ```js | 248 | ```js |
240 | function register ({ | 249 | function register ({ |
241 | videoLanguageManager, | 250 | videoLanguageManager, |
242 | videoCategoryManager, | 251 | videoCategoryManager, |
243 | videoLicenceManager, | 252 | videoLicenceManager, |
244 | videoPrivacyManager, | 253 | videoPrivacyManager, |
245 | playlistPrivacyManager | 254 | playlistPrivacyManager |
246 | }) { | 255 | }) { |
247 | videoLanguageManager.addConstant('al_bhed', 'Al Bhed') | 256 | videoLanguageManager.addConstant('al_bhed', 'Al Bhed') |
248 | videoLanguageManager.deleteConstant('fr') | 257 | videoLanguageManager.deleteConstant('fr') |