Add more explicit types to docs for TouchBar

This commit is contained in:
Samuel Attard 2017-03-04 16:14:41 +11:00
parent e315116336
commit f97ee56c9f
No known key found for this signature in database
GPG key ID: 273DC1869D8F13EF
5 changed files with 15 additions and 13 deletions

View file

@ -19,15 +19,15 @@ The following properties are available on instances of `TouchBarButton`:
#### `touchBarButton.label` #### `touchBarButton.label`
The button's current text. Changing this value immediately updates the button A `String` representing the button's current text. Changing this value immediately updates the button
in the touch bar. in the touch bar.
#### `touchBarButton.backgroundColor` #### `touchBarButton.backgroundColor`
The button's current background color. Changing this value immediately updates A `String` hex code representing the button's current background color. Changing this value immediately updates
the button in the touch bar. the button in the touch bar.
#### `touchBarButton.icon` #### `touchBarButton.icon`
The button's current icon. Changing this value immediately updates the button A `NativeImage` representing the button's current icon. Changing this value immediately updates the button
in the touch bar. in the touch bar.

View file

@ -12,6 +12,7 @@ Process: [Main](../tutorial/quick-start.md#main-process)
* `selectedColor` String (optional) - The selected hex color in the picker, * `selectedColor` String (optional) - The selected hex color in the picker,
i.e `#ABCDEF`. i.e `#ABCDEF`.
* `change` Function (optional) - Function to call when a color is selected. * `change` Function (optional) - Function to call when a color is selected.
* `color` String - The color that the user selected from the picker
### Instance Properties ### Instance Properties
@ -19,10 +20,10 @@ The following properties are available on instances of `TouchBarColorPicker`:
#### `touchBarColorPicker.availableColors` #### `touchBarColorPicker.availableColors`
The color picker's available colors to select. Changing this value immediately A `String[]` array representing the color picker's available colors to select. Changing this value immediately
updates the color picker in the touch bar. updates the color picker in the touch bar.
#### `touchBarColorPicker.selectedColor` #### `touchBarColorPicker.selectedColor`
The color picker's currently selected color. Changing this value immediately A `String` hex code representing the color picker's currently selected color. Changing this value immediately
updates the color picker in the touch bar. updates the color picker in the touch bar.

View file

@ -16,10 +16,10 @@ The following properties are available on instances of `TouchBarLabel`:
#### `touchBarLabel.label` #### `touchBarLabel.label`
The label's current text. Changing this value immediately updates the label in A `String` representing the label's current text. Changing this value immediately updates the label in
the touch bar. the touch bar.
#### `touchBarLabel.textColor` #### `touchBarLabel.textColor`
The label's current text color. Changing this value immediately updates the A `String` hex code representing the label's current text color. Changing this value immediately updates the
label in the touch bar. label in the touch bar.

View file

@ -19,10 +19,10 @@ The following properties are available on instances of `TouchBarPopover`:
#### `touchBarPopover.label` #### `touchBarPopover.label`
The popover's current button text. Changing this value immediately updates the A `String` representing the popover's current button text. Changing this value immediately updates the
popover in the touch bar. popover in the touch bar.
#### `touchBarPopover.icon` #### `touchBarPopover.icon`
The popover's current button icon. Changing this value immediately updates the A `NativeImage` representing the popover's current button icon. Changing this value immediately updates the
popover in the touch bar. popover in the touch bar.

View file

@ -12,6 +12,7 @@ Process: [Main](../tutorial/quick-start.md#main-process)
* `minValue` Integer (optional) - Minimum value. * `minValue` Integer (optional) - Minimum value.
* `maxValue` Integer (optional) - Maximum value. * `maxValue` Integer (optional) - Maximum value.
* `change` Function (optional) - Function to call when the slider is changed. * `change` Function (optional) - Function to call when the slider is changed.
* `newValue` Number - The value that the user selected on the Slider
### Instance Properties ### Instance Properties
@ -19,20 +20,20 @@ The following properties are available on instances of `TouchBarSlider`:
#### `touchBarSlider.label` #### `touchBarSlider.label`
The slider's current text. Changing this value immediately updates the slider A `String` representing the slider's current text. Changing this value immediately updates the slider
in the touch bar. in the touch bar.
#### `touchBarSlider.value` #### `touchBarSlider.value`
The slider's current value. Changing this value immediately updates the slider A `Number` representing the slider's current value. Changing this value immediately updates the slider
in the touch bar. in the touch bar.
#### `touchBarSlider.minValue` #### `touchBarSlider.minValue`
The slider's current minimum value. Changing this value immediately updates the A `Number` representing the slider's current minimum value. Changing this value immediately updates the
slider in the touch bar. slider in the touch bar.
#### `touchBarSlider.maxValue` #### `touchBarSlider.maxValue`
The slider's current maximum value. Changing this value immediately updates the A `Number` representing the slider's current maximum value. Changing this value immediately updates the
slider in the touch bar. slider in the touch bar.