Skip to content

xcode 12 -Ios14 -colorpicker triangle single color inside triangle  #38

@RupamShaw

Description

@RupamShaw

xcode 12
expo init AwesomeProject

    "react-native-color-picker": "^0.6.0",
constructor(props) {
    super(props)
    this.state = { color: toHsv('red') }
    this.onColorChange = this.onColorChange.bind(this)
  }

  onColorChange(color) {
    console.log("color", color)
    this.setState({ color })
  }
 render(){
  return (
       <View style={styles.container}>
        <Text>Open up App.js to start working on your app!</Text>
        <StatusBar style="auto" />
        <View style={{flex: 1, padding: 45, backgroundColor: "#212021"}}>
          <Text style={{color: "white"}}>
            React Native Color Picker - Controlled
          </Text>
          <TriangleColorPicker
            oldColor="purple"
            color={this.state.color}
            onColorChange={this.onColorChange}
            onColorSelected={color => alert(`Color selected: ${color}`)}
            onOldColorSelected={color => alert(`Old color selected: ${color}`)}
            style={{flex: 1}}
          />
        </View>
      </View>

Screen Shot 2020-09-23 at 4 38 32 pm

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions