https://github.com/caffeinalab/ti.siriwave
SiriwaveJS porting for Titanium as Alloy widget.
https://github.com/caffeinalab/ti.siriwave
Last synced: 6 months ago
JSON representation
SiriwaveJS porting for Titanium as Alloy widget.
- Host: GitHub
- URL: https://github.com/caffeinalab/ti.siriwave
- Owner: caffeinalab
- License: apache-2.0
- Created: 2014-06-09T11:04:27.000Z (about 12 years ago)
- Default Branch: master
- Last Pushed: 2016-10-20T17:35:14.000Z (over 9 years ago)
- Last Synced: 2024-11-15T23:31:43.404Z (over 1 year ago)
- Language: JavaScript
- Homepage:
- Size: 16.6 KB
- Stars: 14
- Watchers: 10
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Ti.SiriWave
[](https://gitter.im/CaffeinaLab/Ti.SiriWave?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
### com.caffeinalab.titanium.siriwave
####[Watch the original script in JS](https://github.com/CaffeinaLab/SiriWaveJS)

## Installation
#### Via Gittio
```
gittio install com.caffeinalab.titanium.siriwave
```
#### Via Github
Download the latest release, unzip in `app/widgets`, and in your *config.json*, under `dependencies` add:
```
"dependencies": {
"com.caffeinalab.titanium.siriwave": "*"
}
```
## Usage
### Require in the View
```xml
```
And stylize globally via *app.tss*:
```javascript
"#caffeinaSiriWave" : {
width: 320,
height: 150,
backgroundColor: 'black',
noise: 0.5
}
```
## Properties
#### `[speed]` (Number, from `0` to `1`, default: `0.1`)
The speed of the wave.
#### `[amplitude]` (Number, from `0` to `1`, default: `1`)
The noise (amplitude) of the wave.
#### `[frequency]` (Number, from `0` to `N`, default: `1`)
The noise (amplitude) of the wave.
#### `[color]` (String, Color, default: `#fff')
The color of the wave, in hexadecimal form (`#336699`, `#FF0`)
## API
#### `set(property, value)`
Set the property at runtime
#### `start()`
Start the wave
#### `stop()`
Stop the wave