Giter Site home page Giter Site logo

Comments (10)

irony avatar irony commented on September 7, 2024

+1

from tcomb-form-native.

carbureted avatar carbureted commented on September 7, 2024

+1

from tcomb-form-native.

davidlivingrooms avatar davidlivingrooms commented on September 7, 2024

👍

from tcomb-form-native.

alvaromb avatar alvaromb commented on September 7, 2024

Can you provide a visual example for that @aksonov ?

I think that what you're trying to do is completely doable right now. You can use this other component to render the item cell https://github.com/APSL/react-native-item-cell and use tcomb-form-native for the forms itself.

from tcomb-form-native.

alvaromb avatar alvaromb commented on September 7, 2024

Also keep in mind that what you're trying to do involves some Navigator or NavigatorIOS around, and in my opinion that's not what this library tries to solve. You can easily create validated forms with tcomb-form-native and wrap 'em into whatever view hierarchy or flux you want, but I'm not sure this library should auto-generate a more complex view navigation.

Small libs to solve concrete problems is the way. If you want to auto-generate that form with navigation, you should create a library on top of tcomb-form-native in order to provide that functionality. Please ping me if you need help doing that, I'm open to collaborate :)

from tcomb-form-native.

davidlivingrooms avatar davidlivingrooms commented on September 7, 2024

I can't speak for @aksonov but I personally imagine something like this. The Gender and Country options open up a new 'modal' screen with the widget instead of it being on the same page.

The view navigation may not be so complex since it is really just pushing and then popping the same scene? I am new to react native so maybe it would not be so easy. You make a good point @alvaromb and it's possible that this is outside the goal of this lib.

This is just my opinion but in tcomb-form for the web it makes sense for the form to be all on one page most of the time but for phone apps where modals are more common it would be nice if there was an isModal prop for each widget or something like that. For my use case, I would be happy with an example of how to integrate/recreate this interaction with tcomb-form-native. Either way, I'll keep trying to get something to work. I'll update this if I make any progress.

from tcomb-form-native.

alvaromb avatar alvaromb commented on September 7, 2024

You actually can do that, @GrumpyPants, the only thing is that tcomb-form-native doesn't provide those templates for you. I have done this by myself in two apps without any problem. You need a Navigator in order to make that transition, and my point is that this library shouldn't enforce you to use it. Don't get me wrong, react-native-gifted-form is very cool, but I think that the goal of this library is another one.

If you look closely to the gif you posted, the modal transition is wrong, because the navigation bar simulates a push-like transition when the contained view in the modal is opening bottom-to-top, not left-to-right.

Anyway, we could try to offer different templates with similar behaviour, but keep in mind that offering great templates with good customization involves a lot of things in this case: NavigationBar, Button's for the navbar, transition, the touchable component that triggers the modal opening...

from tcomb-form-native.

bchoddny avatar bchoddny commented on September 7, 2024

+1

from tcomb-form-native.

alvaromb avatar alvaromb commented on September 7, 2024

How do you feel about this @gcanti? Maybe we could stick something into the docs, but it is out of the scope of this library IMHO.

from tcomb-form-native.

gcanti avatar gcanti commented on September 7, 2024

but it is out of the scope of this library IMHO

I agree, going to close this.

from tcomb-form-native.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.