diff --git a/demo/swagger.yaml b/demo/swagger.yaml index 47cad699..86abb4f6 100644 --- a/demo/swagger.yaml +++ b/demo/swagger.yaml @@ -819,6 +819,7 @@ definitions: type: string pattern: "^\\+(?:[0-9]-?){6,14}[0-9]$" example: +1-202-555-0192 + x-nullable: true userStatus: description: User status type: integer diff --git a/lib/components/JsonSchema/_json-schema-common.scss b/lib/components/JsonSchema/_json-schema-common.scss index 26b41559..d50ad788 100644 --- a/lib/components/JsonSchema/_json-schema-common.scss +++ b/lib/components/JsonSchema/_json-schema-common.scss @@ -63,6 +63,14 @@ $sub-schema-offset: ($bullet-size / 2) + $bullet-margin; font-weight: bold; } +.param-nullable { + vertical-align: middle; + line-height: $param-name-height; + color: #3195a6; + font-size: 12px; + font-weight: bold; +} + .param-type { vertical-align: middle; line-height: $param-name-height; diff --git a/lib/components/JsonSchema/json-schema.html b/lib/components/JsonSchema/json-schema.html index 9b16818d..e5228e5f 100644 --- a/lib/components/JsonSchema/json-schema.html +++ b/lib/components/JsonSchema/json-schema.html @@ -70,6 +70,7 @@ {{prop._range}} Required + Nullable