You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Required Schema Properties have an appended red asterisk as a span element and include an additional .star class on said span element
Required Path Parameters have a red asterisk (and an ::after element with the content required) that indicates its importance but are missing the .star class that required Schema properties possess
To reproduce...
Steps to reproduce the behavior:
Use the provided OpenAPI definitions and load them as the spec value in the Swagger-UI configuration option (make sure to also provide a valid dom_id)
Click on the GET /a/{id} path and navigate to the PARAMETERS list
Inspect the red asterisk on the id field
Observe the missing .star class on the span element
Navigate to the Schemas List and open/click on the SomeObject schema definition
Inspect the red asterisk on the id field
Observe the .star class on the span element
Expected behavior
The red asterisk after required path parameters should also include the .star class for consistency
Screenshots
Required Path Parameter
Required Schema Property
Additional context or thoughts
As part of a customization of some of the design elements, i wanted to adjust the way required properties & fields look
During that process i noticed that i would need to style their red asterisk the following way
Instead of being able to just address them via .star
This is extremely minor and easy to work around, but i still think that it should be resolved for the sake of consistency - albeit with a pretty low priority
Q&A
Content & configuration
Required Path Parameter
Required Schema Property
Example Swagger/OpenAPI definition:
Swagger-UI configuration options:
Describe the bug you're encountering
Required
Schema Properties
have an appended red asterisk as a span element and include an additional.star
class on said span elementRequired
Path Parameters
have a red asterisk (and an ::after element with the content required) that indicates its importance but are missing the.star
class that required Schema properties possessTo reproduce...
Steps to reproduce the behavior:
/a/{id}
path and navigate to the PARAMETERS list.star
class on the span elementSomeObject
schema definition.star
class on the span elementExpected behavior
The red asterisk after required path parameters should also include the
.star
class for consistencyScreenshots
Required Path Parameter
Required Schema Property
Additional context or thoughts
As part of a customization of some of the design elements, i wanted to adjust the way required properties & fields look
During that process i noticed that i would need to style their red asterisk the following way
Instead of being able to just address them via
.star
This is extremely minor and easy to work around, but i still think that it should be resolved for the sake of consistency - albeit with a pretty low priority
I think that this is caused by this specific line
swagger-ui/src/core/components/parameter-row.jsx
Line 276 in 8d94b55
The text was updated successfully, but these errors were encountered: