Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(ReactPickerView): Add ReactPickerView #265

Merged
merged 4 commits into from
Mar 21, 2016
Merged

feat(ReactPickerView): Add ReactPickerView #265

merged 4 commits into from
Mar 21, 2016

Conversation

ebragge
Copy link
Contributor

@ebragge ebragge commented Mar 16, 2016

ReactPicker provides access to native selector UI Components for React Native JavaScript applications.

Fixes #231

@ebragge
Copy link
Contributor Author

ebragge commented Mar 16, 2016

Basic functionality works - labels, colors, value change, style

`<View

        <Switch 
            onValueChange={(value) => this.setState({eventSwitchIsOn: value}) }
            value={this.state.eventSwitchIsOn}/>            
        <Picker
            selectedValue={this.state.language}
            onValueChange={(lang) => this.setState({language: lang})}>   
            <Picker.Item label="Java" value="java" color='blue' testID='1'/>
            <Picker.Item label="JavaScript" value="js" color='red' testID='2'/>
            <Picker.Item label="C++" value="cpp" color='green' testID='3'/>
            <Picker.Item label="C#" value="cs" color='yellow' testID='4'/>
            <Picker.Item label="C" value="c" color='magenta' testID='5'/>
        </Picker>
        <Picker
            style={{width: 100, height: 40}}
            selectedValue={this.state.language}
            enabled={this.state.eventSwitchIsOn}
            onValueChange={(lang) => this.setState({language: lang})}>   
            <Picker.Item label="Java" value="java" color='blue' testID='1'/>
            <Picker.Item label="JavaScript" value="js" color='red' testID='2'/>
            <Picker.Item label="C++" value="cpp" color='green' testID='3'/>
            <Picker.Item label="C#" value="cs" color='yellow' testID='4'/>
            <Picker.Item label="C" value="c" color='magenta' testID='5'/>
        </Picker>

`

...

@ebragge ebragge changed the title feat(ReactPickerView): add ReactPickerView feat(ReactPickerView): Add ReactPickerView Mar 17, 2016
@@ -13,8 +13,9 @@
'use strict';

var ColorPropType = require('ColorPropType');
var PickerIOS = require('PickerIOS');
var PickerAndroid = require('PickerAndroid');
//var PickerIOS = require('PickerIOS');
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We have to keep everything working on iOS and Android, I don't think we can comment these out.

ReactPicker provides access to native selector UI Components for React
Native JavaScript applications. Selector is implemented as ComboBox.

Fixes #231
ReactPicker provides access to native selector UI components for React
Native JavaScript applications.
- PR comments implemented

Fixes #231
*
* @providesModule PickerIOS
*/
'use strict';
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you also make sure this outputs an "UnimplementedView", i.e.:
module.exports = require('UnimplementedView');


In reply to: 56820832 [](ancestors = 56820832)

// surrounding view to ensure it gets rendered.
// TODO would be better to export a native constant for this,
// like in iOS the RCTDatePickerManager.m
height: 40,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need this constant, since it has custom measurement? #Closed

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed

@rozele
Copy link
Collaborator

rozele commented Mar 18, 2016

👍

ebragge added 2 commits March 21, 2016 15:23
ReactPicker provides access to native selector UI components for React Native JavaScript applications.
- PR comments #2 implemented

Fixes #231
…edView

ReactPicker provides access to native selector UI components for React Native JavaScript applications.

Fixes #231
ebragge added a commit that referenced this pull request Mar 21, 2016
feat(ReactPickerView): Add ReactPickerView
@ebragge ebragge merged commit 02b9ded into ReactWindows Mar 21, 2016
@ebragge ebragge deleted the issue231 branch March 21, 2016 16:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants