-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This merge commit merges the PR #11, which adds custom views to the menu and scenes.
- Loading branch information
Showing
30 changed files
with
1,685 additions
and
197 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
# Menu - Add custom button | ||
|
||
## Description | ||
|
||
Adds a custom button to the menu. | ||
|
||
## Syntax | ||
|
||
```js | ||
menu.addCustomButton(menu, { | ||
text: 'Hello world!', | ||
color: 'FFFFFF', | ||
fontSize: 12, | ||
position: { | ||
side: 'left', | ||
margins: { | ||
side: 10, | ||
top: 10 | ||
} | ||
} | ||
}) | ||
``` | ||
|
||
## Parameters | ||
|
||
- `menu`: The menu configurations from the `init` function. | ||
- `options`: The options of the custom button. An object with the following properties: | ||
- `text`: The text of the button. | ||
- `color`: The color of the button. | ||
- `fontSize`: The font size of the text. | ||
- `height`: The height of the button. Must be either `match`, `wrap` or a `number`. (dp) | ||
- `width`: The width of the button. Must be either `match`, `wrap` or a `number`. (dp) | ||
- `position`: The position of the button. An object with the following properties: | ||
- `side`: The side of the button can be `left`, `right` or `center`. | ||
- `margins`: The margin of the button can be any number. An object with the following properties: (Not required if side == center) | ||
- `side`: The margin of the side of the button. (dp) | ||
- `top`: The margin of the top of the button. (dp) | ||
|
||
|
||
## Return value | ||
|
||
This function will return the scene configurations if the addition was successful, otherwise, it will execute `new Error` to terminate the generation process. | ||
|
||
## Platform support | ||
|
||
- [x] Android | ||
- [ ] iOS | ||
- [ ] Windows | ||
- [ ] Linux distros | ||
- [ ] MacOS | ||
- [ ] Web |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
# Menu - Add custom image | ||
|
||
## Description | ||
|
||
Adds a custom image to the menu. | ||
|
||
## Syntax | ||
|
||
```js | ||
menu.addCustomImage(menu, { | ||
image: 'background_thanking', | ||
height: 'match', | ||
width: 'match', | ||
position: { | ||
side: 'left', | ||
margins: { | ||
side: 10, | ||
top: 10 | ||
} | ||
} | ||
}) | ||
``` | ||
|
||
## Parameters | ||
|
||
- `menu`: The menu configurations from the `init` function. | ||
- `options`: The options of the custom text. An object with the following properties: | ||
- `image`: The image of the text. | ||
- `height`: The height of the text. Must be either `match`, `wrap` or a `number`. (dp) | ||
- `width`: The width of the text. Must be either `match`, `wrap` or a `number`. (dp) | ||
- `position`: The position of the text. An object with the following properties: | ||
- `side`: The side of the text can be `left`, `right` or `center`. | ||
- `margins`: The margin of the text can be any number. An object with the following properties: (Not required if side == center) | ||
- `side`: The margin of the side of the text. (dp) | ||
- `top`: The margin of the top of the text. (dp) | ||
|
||
|
||
## Return value | ||
|
||
This function will return the scene configurations if the addition was successful, otherwise, it will execute `new Error` to terminate the generation process. | ||
|
||
## Platform support | ||
|
||
- [x] Android | ||
- [ ] iOS | ||
- [ ] Windows | ||
- [ ] Linux distros | ||
- [ ] MacOS | ||
- [ ] Web |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
# Menu - Add custom button | ||
|
||
## Description | ||
|
||
Adds a custom rectangle to the menu. | ||
|
||
## Syntax | ||
|
||
```js | ||
menu.addCustomRectangle(menu, { | ||
color: 'FFFFFF', | ||
opacity: 0.8, | ||
height: 'match', | ||
width: 'match', | ||
position: { | ||
side: 'left', | ||
margins: { | ||
side: 10, | ||
top: 10 | ||
} | ||
} | ||
}) | ||
``` | ||
|
||
## Parameters | ||
|
||
- `menu`: The menu configurations from the `init` function. | ||
- `options`: The options of the custom rectangle. An object with the following properties: | ||
- `color`: The color of the rectangle. | ||
- `opacity`: The opacity of the rectangle. | ||
- `height`: The height of the rectangle. Must be either `match`, `wrap` or a `number`. (dp) | ||
- `width`: The width of the rectangle. Must be either `match`, `wrap` or a `number`. (dp) | ||
- `position`: The position of the rectangle. An object with the following properties: | ||
- `side`: The side of the rectangle can be `left`, `right` or `center`. | ||
- `margins`: The margin of the rectangle can be any number. An object with the following properties: (Not required if side == center) | ||
- `side`: The margin of the side of the rectangle. (dp) | ||
- `top`: The margin of the top of the rectangle. (dp) | ||
|
||
## Return value | ||
|
||
This function will return the scene configurations if the addition was successful, otherwise, it will execute `new Error` to terminate the generation process. | ||
|
||
## Platform support | ||
|
||
- [x] Android | ||
- [ ] iOS | ||
- [ ] Windows | ||
- [ ] Linux distros | ||
- [ ] MacOS | ||
- [ ] Web |
Oops, something went wrong.