Skip to content
This repository was archived by the owner on Jan 22, 2026. It is now read-only.

Conversation

@clottman
Copy link
Contributor

@clottman clottman commented Mar 20, 2020

  • Adds Wrapping Text Input to the shared components library
  • Adds OptimisticTextInput & OptimisticInput to shared components
    • OptimisticTextInput is just like src/components/fields/optimistic-text-input.js from community
    • OptimisticInput is so we can create all the other components community uses that are optimistic; we might have <OptimisticInput Component={MarkdownInput} .. /> to replace optimistic-markdown-input, <OptimisticInput Component={WrappingTextInput} .. /> to replace optimistic-wrapping-input, etc.

After this is released, we can remove the hooks related to optimistic values and the various components from the community site and replace them with these.

@clottman clottman requested a review from GregWeil March 20, 2020 19:45
Copy link
Contributor

@GregWeil GregWeil left a comment

Choose a reason for hiding this comment

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

Looks good, left a small comment on proptypes (since it wraps onBlur before passing it along)

OptimisticInput.propTypes = {
value: PropTypes.string.isRequired,
onChange: PropTypes.func.isRequired,
Component: PropTypes.elementType.isRequired,
Copy link
Contributor

Choose a reason for hiding this comment

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

This should include onBlur as an optional function

@keithk
Copy link
Contributor

keithk commented Nov 10, 2020

🚀 PR was released in v0.19.0 🚀

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants