apigitlabs / apigit-support

APIGIT is a native Git based collaboration platform for API design, document, mock and share.
https://apigit.com
3 stars 0 forks source link

Ability to “filter” the source view #37

Closed Stwissel closed 2 weeks ago

Stwissel commented 3 weeks ago

Is there an existing request for this feature?

Is your feature request related to a problem?

When switching from form mode to source mode the context “where was I “ gets lost and one needs to scroll to find the element being worked on. This slows productivity and increases the risk of accidentally editing the wrong element

Describe the solution you'd like

Some mechanism to retain context. No particular preference here, a few ideas:

Describe alternatives you've considered

Use CTRL+F 🤪

Additional context

Love your work

apigitlabs commented 2 weeks ago

hi @Stwissel, our form view and code view are independent instead of side by side, so we don't bring over the context to the other side . another thing is when the spec is json based API spec, it is also not possible to identify where i am. I am not sure there any better solution for this, please let us know if you have any good idea.

Stwissel commented 2 weeks ago

I see the challenge. You might peek at Apicur.io 0.2 how they approached it. There, when you switched to code, you only got the element in focus unless your focus was on the top level, then you got all.

One possible idea: add a button "Code for this entry" (that's the working title, not the actual label 😄 ) somewhere, that only edits the given element. Could be on hover over an entry (where you have up/down/clone/delete) or somewhere on the form.

What would make an interesting experience: then open the code, render everything not in focus as content and the focus part inside a Monaco editor (I presume that's driving the editor). A expand button could then switch to the full edit mode as you have it today.

Love your work!

apigitlabs commented 2 weeks ago

thanks @Stwissel, we will do some more research and see how to improve it

Stwissel commented 2 weeks ago

Happy to beta test if that helps. Btw you already have an area with "inline source edit" -> when you edit an object schema.

apigitlabs commented 2 weeks ago

hi @Stwissel , we have get it supported for path level, please refresh browser to have a try, hopes you like it.

Stwissel commented 2 weeks ago

Your velocity is impressive. Hope you don't mind if I keep the feedback coming

apigitlabs commented 2 weeks ago

hi @Stwissel , no worry at all !! All your valuable suggestions are always greatly appreciated!

Stwissel commented 2 weeks ago

Looks nice, works well. Little suggestion for consistency: In path you have the toggle (o ), while in Schema there's a button < > in a button group. You might settle for one.

apigitlabs commented 1 week ago

Looks nice, works well. Little suggestion for consistency: In path you have the toggle (o ), while in Schema there's a button < > in a button group. You might settle for one.

thanks @Stwissel , the in-consistency issue was fixed.