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`
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.
#### `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.
#### `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.

View file

@ -12,6 +12,7 @@ Process: [Main](../tutorial/quick-start.md#main-process)
* `selectedColor` String (optional) - The selected hex color in the picker,
i.e `#ABCDEF`.
* `change` Function (optional) - Function to call when a color is selected.
* `color` String - The color that the user selected from the picker
### Instance Properties
@ -19,10 +20,10 @@ The following properties are available on instances of `TouchBarColorPicker`:
#### `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.
#### `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.

View file

@ -16,10 +16,10 @@ The following properties are available on instances of `TouchBarLabel`:
#### `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.
#### `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.

View file

@ -19,10 +19,10 @@ The following properties are available on instances of `TouchBarPopover`:
#### `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.
#### `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.

View file

@ -12,6 +12,7 @@ Process: [Main](../tutorial/quick-start.md#main-process)
* `minValue` Integer (optional) - Minimum value.
* `maxValue` Integer (optional) - Maximum value.
* `change` Function (optional) - Function to call when the slider is changed.
* `newValue` Number - The value that the user selected on the Slider
### Instance Properties
@ -19,20 +20,20 @@ The following properties are available on instances of `TouchBarSlider`:
#### `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.
#### `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.
#### `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.
#### `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.