-
Notifications
You must be signed in to change notification settings - Fork 388
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
add descriptions for services, methods, and fields #166
Conversation
- service, method are to the right of selection drop-downs and can be hidden - field descriptions are tool-tips - TODO: descriptions for oneofs, message, and enum types
@@ -34,8 +80,7 @@ | |||
|
|||
#grpc-request-response li.ui-tabs-tab { | |||
border: 1px solid #ccc; | |||
margin: 0; | |||
margin-right: -1px; | |||
margin: 0 -1px 0 0; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This and the one below were cleanup suggested by my IDE.
@@ -174,7 +218,7 @@ table#grpc-request-metadata-form { | |||
|
|||
#grpc-request-form td { | |||
padding: 16px 0 0 16px; | |||
font-size: 13.2px; | |||
font-size: 13px; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ditto, this and the change at the bottom were cleanup suggested by the IDE (due to not all browsers supporting fractional pixels).
<table class="grpc-desc"> | ||
<tr> | ||
<td> | ||
<table id="grpc-desc-selects"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I hate adding a nested table. But I played around with the layout quite a lot, and I could not figure out how to preserve the existing look without doing this. I tried floating divs and simpler tables with more divs inside and fewer table cells and no nesting. But I just couldn't figure out how to get the look and layout behavior I was aiming for without this.
@@ -110,8 +110,8 @@ github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ | |||
github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= | |||
github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= | |||
github.com/jhump/protoreflect v1.10.3/go.mod h1:7GcYQDdMU/O/BBrl/cX6PNHpXh6cenjd8pneu5yW7Tg= | |||
github.com/jhump/protoreflect v1.10.4-0.20220210001327-6224817bacc5 h1:KIpt99Cgc9Vv3Hjbx/ke8ZQAzcH7AzM7/HxFCumGI7s= | |||
github.com/jhump/protoreflect v1.10.4-0.20220210001327-6224817bacc5/go.mod h1:U7aMIjN0NWq9swDP7xDdoMfRHb35uiuTd3Z9nFXJf5E= | |||
github.com/jhump/protoreflect v1.11.0 h1:bvACHUD1Ua/3VxY4aAMpItKMhhwbimlKFJKsLsVgDjU= |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This version includes a fix for printing methods: without it, comments on option statements were never included.
The "descriptions" come in the form of proto source -- showing the service, method, and field in source form (though not necessary exactly as was present in the original source file, but close, including options and whatever comments are preserved in the descriptor).
Still to do: descriptions for oneofs, message, and enum types. This could also be done as tool tips over type names and over the oneof name. However, much of the information is redundant -- oneofs and messages don't need to show their full body since all of the fields are already expanded in the web form. Enums could still show their full contents, as that is the only way for a user to see comments and options on particular enum values.
This supersedes #79 and #148.