Skip to content

plain-text buttons are not customizable #3

Description

@sam1463

Description

It seems like plain-text alerts use hard-coded button options. They display with these values, and those are not the values I've specified.
screen shot 2018-08-20 at 2 12 39 pm

Reproduction

I'm opening an alert like this:

Alert.alert(
        '<Prompt text>',
        '<Prompt text 2>',
        [
          {
            text: 'Confirm',
            style: 'default',
            onPress: (text) => { console.log('Pressed confirm with text: ', text); },
          },
          {
            text: 'Cancel',
            style: 'cancel',
            onPress: () => { console.log('Pressed cancel'); },
          }
        ],
        'plain-text',
        '',
        0,
      )

Solution

Alerts of style plain-text should honor the button text and style specified by users, rather than always using hard-coded values

Additional Information

  • React Native version: 0.55.4
  • Platform: currently using iOS, although this is likely an issue on both
  • Operating System: MacOS
  • Package Version: 0.1.2

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