Git Product home page Git Product logo

Comments (3)

awaisabir avatar awaisabir commented on June 26, 2024

I believe we can do this 1 of two ways:

  1. pass the functions to set the state for this collapsible panel within advanced options, and we could set it directly, Although I think this might cause issues.

  2. on the advanced options side, we can set the errorMessage state on initial mount (maybe check for empty value) which would then trigger a re-render and prompt you to open up Advanced options. I am more in favor of this approach.

Let me know what you thing 💭

from jupyter-scheduler.

JasonWeill avatar JasonWeill commented on June 26, 2024

Personally, I prefer the idea of letting the user collapse the expandable section, and then if there's an error in advanced options, provide an indicator like ⚠️ or ⛔ to suggest that there is an error in it.

We have errors which is a simple key-value store, but this may not be sufficient, since we don't know which keys in errors correspond with the advanced options section. We could have the advanced options extension point include a list of inputs, or we could have a separate list of errors specifically for the advanced options section. That separate list would give you more direct control, but it'd also require us to check two different errors objects to determine whether the "Create" submit button is active.

from jupyter-scheduler.

awaisabir avatar awaisabir commented on June 26, 2024

I like the idea of keeping two separate error state objects actually. That way we can make sure the advanced options don't mess with the default available options error states. But it does have a caveat of you having to iterate over two objects and checking for validity.

It would, however, also let you better identify on whether or not to show the ⚠️ or ⛔ icons based on which iterated object has the error 🤔

from jupyter-scheduler.

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.