GraphQL Endpoint field UX

I am using Slash GraphQL for the first time

At first it seems like GraphQL EP is editable and i can change the name according to my use, but field is not editable

Screenshot 2020-08-21 at 7.11.17 PM

1 Like

It looks similar to Google Drive’s ui, hence not really an issue!

Makes it look like you are free to select the text!

Screenshot from 2020-08-21 19-50-24

P.S. Try making a text field read-only in HTML and this is what you’ll get.

Hey Mohit,

Do you have a suggestion? Earlier it was disabled instead of readonly, but firefox users weren’t able to copy from it. Should we remove the border for readonly fields so that people realize you can’t edit it?

@gja

We can remove the input if readonly is an issue in firefox, instead we can use div with a copy icon, something like below

Screenshot 2020-08-24 at 12.06.06 PM

@mbj36 We are planning to show a copy link button with the endpoint which would just acknowledge with a toaster once the link is copied. Can you please suggest a toaster library that would work well with react?

@arpan It seems like Slash Graphql is using react bootstrap already, so probably don;t need a new toaster library for just one use case

React bootstrap has this alert component - https://react-bootstrap.github.io/components/alerts

Toaster library - https://github.com/fkhadra/react-toastify

1 Like

@mbj36 I guess the alert component does not automatically go away and needs a user click to hide the alert.

Also, it might just not be one use-case and I can see it helpful for many other places throughout the application where we are showing browser alerts and increasing the number of clicks for the user.

But yes, as far as I can see, react-bootstrap has toasts as well. So, I think we can avoid a new library for it. Thanks for the suggestion.

1 Like

My favorite toast library as of now:

Used to be React Toastify

IMHO, React bootstrap lacks taste.

1 Like

Hey @mbj36,

The UX has just changed. You also have a copy link button now.

2 Likes