Skip to content

Commit 1059c8d

Browse files
committed
chore(Example): add emptied example and cnahe min max values
1 parent a22d78e commit 1059c8d

File tree

1 file changed

+17
-3
lines changed

1 file changed

+17
-3
lines changed

Example/App.js

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -165,13 +165,13 @@ export default class App extends Component {
165165
</View>
166166
<View style={styles.col}>
167167
<Text style={styles.text}>
168-
Min & Max colors (min 0, max 2)
168+
Min & Max colors (min 5, max 10)
169169
</Text>
170170
<InputSpinner
171171
value={this.state.value + 1}
172172
style={styles.spinner}
173-
min={0}
174-
max={2}
173+
min={5}
174+
max={10}
175175
colorMax={"#f04048"}
176176
colorMin={"#82cc62"}
177177
/>
@@ -326,6 +326,20 @@ export default class App extends Component {
326326
}}
327327
/>
328328
</View>
329+
<View style={styles.col}>
330+
<Text style={styles.text}>Emptied ({this.state.value == null ? "null" : this.state.value})</Text>
331+
<InputSpinner
332+
style={styles.spinner}
333+
step={1}
334+
max={10}
335+
min={1}
336+
emptied={true}
337+
value={this.state.value}
338+
onChange={(value) => {
339+
this.setState({value: value});
340+
}}
341+
/>
342+
</View>
329343
<Text style={styles.title}>List</Text>
330344
<FlatList
331345
style={{height: 500}}

0 commit comments

Comments
 (0)