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

[Feature request] Rendering an initial count of arrays (listfields) #14

Closed
serkandurusoy opened this issue May 29, 2016 · 5 comments
Closed
Assignees
Labels
Type: Feature New features and feature requests

Comments

@serkandurusoy
Copy link
Contributor

TL:DR;
add an "initialCount" property for listfields


Autoform has a great feature with handling array structures where

  • if there are minCount and maxCount defined on the schema
    • autoform displays minimum of minCount children ready to be filled and no [-] button
    • allows maximum of maxCount children and does not display [+] button after the last child
  • if there is an initialCount defined as a property of the [Array] field
    • displays initialCount children in the first render (if it is not less than minCount)
  • if the array is not optional: true (meaning it should contain at least one child)
    • always displays at least one child

This allows for better UX design for forms with nested structures.

Uniforms does take into account minCount and maxCount but it lacks an "initialCount" feature.

Therefore, uniform's handling of such arrays of fields requires user interaction to be able to render the initial child input and users get confused about it when they don't see that first child input there and only a [+] button

@serkandurusoy serkandurusoy changed the title [Feature request] Rendering of arrays (listfields) [Feature request] Rendering an initial count of arrays (listfields) May 29, 2016
@radekmie radekmie self-assigned this May 29, 2016
@radekmie radekmie added the Type: Feature New features and feature requests label May 29, 2016
@serkandurusoy
Copy link
Contributor Author

Thank you!

@serkandurusoy
Copy link
Contributor Author

@radekmie could you push a release to npm?

@radekmie
Copy link
Contributor

I've published 1.0.0-rc.8.

@radekmie radekmie reopened this May 30, 2016
@radekmie
Copy link
Contributor

It's fixed in 1.0.0-rc.9.

@serkandurusoy
Copy link
Contributor Author

Thanks!

@Monteth Monteth added this to Closed in Open Source (migrated) Jul 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Feature New features and feature requests
Projects
Archived in project
Development

No branches or pull requests

2 participants