OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 /** | 5 /** |
6 * @fileoverview | 6 * @fileoverview |
7 * 'cr-settings-ui' implements the UI for the Settings page. | 7 * 'cr-settings-ui' implements the UI for the Settings page. |
8 * | 8 * |
9 * Example: | 9 * Example: |
10 * | 10 * |
11 * <cr-settings-ui prefs="{{prefs}}"></cr-settings-ui> | 11 * <cr-settings-ui></cr-settings-ui> |
12 * | 12 * |
13 * @group Chrome Settings Elements | 13 * @group Chrome Settings Elements |
14 * @element cr-settings-ui | 14 * @element cr-settings-ui |
15 */ | 15 */ |
16 Polymer('cr-settings-ui', { | 16 Polymer('cr-settings-ui', { |
17 publish: { | 17 publish: { |
18 /** | 18 /** |
19 * Preferences state. | 19 * Preferences state. |
20 * | 20 * |
21 * @attribute prefs | 21 * @attribute prefs |
22 * @type CrSettingsPrefsElement | 22 * @type CrSettingsPrefsElement |
23 * @default null | 23 * @default null |
24 */ | 24 */ |
25 prefs: null, | 25 prefs: null, |
26 | 26 |
27 /** | 27 /** |
28 * Ordered list of settings pages available to the user. Do not edit | 28 * Ordered list of settings pages available to the user. Do not edit |
29 * this variable directly. | 29 * this variable directly. |
30 * | 30 * |
31 * @attribute pages | 31 * @attribute pages |
32 * @type Array<!Object> | 32 * @type Array<!CrSettingsPage> |
33 * @default null | 33 * @default null |
34 */ | 34 */ |
35 pages: null, | 35 pages: null, |
36 }, | 36 }, |
37 | 37 |
| 38 /** |
| 39 * Index of the currently selected page in the menu. |
| 40 * |
| 41 * @attribute selectedPageIndex |
| 42 * @type number |
| 43 * @default 0 |
| 44 */ |
| 45 selectedPageIndex: 0, |
| 46 |
38 /** @override */ | 47 /** @override */ |
39 created: function() { | 48 created: function() { |
40 this.pages = []; | 49 this.pages = []; |
41 }, | 50 }, |
42 }); | 51 }); |
OLD | NEW |