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: New readOnly property in the component's API #173

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

green2k
Copy link

@green2k green2k commented Sep 16, 2017

Using this new property, we can set the component as readOnly, so no custom text-input will be allowed.

@coveralls
Copy link

Coverage Status

Coverage remained the same at 88.316% when pulling f877909 on green2k:property-readOnly into d3f7072 on furqanZafar:master.

@elisherer
Copy link
Contributor

You can do inputProps={ readOnly: true } instead, I think this PR is just a syntactic sugar.

@green2k
Copy link
Author

green2k commented Oct 8, 2017

This PR actually adds the readOnly property into the SimpleSelect & MultiSelect components, so we can properly use it. If there's already some other options about how to mark the input element as read only, then it's maybe missing in the API documentation. However, I've migrated to react-select a couple of days ago, so this issue can be closed 🙂

@joevo2
Copy link

joevo2 commented Oct 23, 2017

@elisherer inputProps is a valid property? doesn't seems to exists in SimpleSelect though.

@elisherer
Copy link
Contributor

@joevo2 , it does:

groups, groups-as-columns, hide-reset-button, name, input-props, on-blur-resets-input, render-toggle-button,

@joevo2
Copy link

joevo2 commented Oct 23, 2017

@elisherer I see... cause I couldn't find it here. and my tslint is being annoying. any idea why? sorry for the trouble though 😢
screen shot 2017-10-23 at 4 03 51 pm

update: oh you guys forget to update this file? 😄 https://github.com/furqanZafar/react-selectize/blob/master/src/index.d.ts

@green2k
Copy link
Author

green2k commented Oct 23, 2017

You're right, the inputProperty property is not valid, as it's not specified in the type definition.

@joevo2
Copy link

joevo2 commented Oct 24, 2017

@green2k I just need to add the type definition into this file then it should work? send a PR? https://github.com/furqanZafar/react-selectize/blob/master/src/index.d.ts sorry im kinda new with ts and oss stuff 😅

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.

4 participants