constelation / monorepo

Mono repo for constelation's Components, functions, and CONSTANTS
https://constelation.github.io/monorepo/
MIT License
12 stars 3 forks source link

Event_ with pressEffect & opacity affects placement of components it wraps #66

Open heaversm opened 7 years ago

heaversm commented 7 years ago

The following code displays properly:

<Event_
  onPress={this.handlePressTout}
>
  {toutComponent}
</Event_>

where toutComponent is

<Image
  source={this.props.image}
  width='100%'
  center
>
  <Style_
    backgroundColor='transparent'
  >
    <Header
      size={18}
      color='WHITE'
    >
      {this.props.title}
    </Header>
  </Style_>
</Image>

However, if I add the pressEffect:

<Event_
  onPress={this.handlePressTout}
  pressEffect='opacity'
  activeOpacity={0.8}
>
  {toutComponent}
</Event_>

The issue can be resolved by switching to Event vs Event_

mikehobi commented 7 years ago

Could you share a screenshot? I'm not sure how the placement is being affected

heaversm commented 7 years ago
screen shot 2017-03-31 at 4 19 34 pm screen shot 2017-03-31 at 4 19 55 pm