Prop | Type | Default |
---|---|---|
stations | Array<Station> |
- |
onSelect | Function |
item => console.info('RadioWidget. [onSelect] ', item) |
onDecrease | Function |
item => console.info('RadioWidget. [onDecrease] ', item) |
onIncrease | Function |
item => console.info('RadioWidget. [onIncrease] ', item) |
onSwitch | Function |
() => console.info('RadioWidget. [onSwitch]') |
onBack | Function |
() => console.info('RadioWidget. [onBack]') |
emptyListPlaceholder | String |
No stations are available :( |
headerTitle | String |
STATIONS |
footerTitle | String |
Currently playing |
keepAspectRatio | Boolean |
false |
type Station {
uuid: String,
name: String,
image: String(URL/PATH),
mhz: String,
}
<View style={{flex: 1, justifyContent: 'center'}}>
<View style={{flexDirection: 'row', flex: 1}}>
<RadioWidget stations={mockData} />
<RadioWidget />
</View>
<View style={{flex: 1, justifyContent: 'center', alignItems: 'center'}}>
<RadioWidget keepAspectRatio stations={mockData} />
</View>
</View>
<View style={{flex: 1, justifyContent: 'center'}}>
<View style={{flexDirection: 'row', flex: 1}}>
<RadioWidget stations={mockData} />
<RadioWidget />
</View>
<View style={{flex: 1, justifyContent: 'center'}}>
<RadioWidget stations={mockData} />
</View>
</View>
<RadioWidget stations={mockData} />