mirror of
https://github.com/Redocly/redoc.git
synced 2024-11-24 09:33:44 +03:00
Merge commit '2ac8b3af3cf42f2b6139e7c3c0779592ec253a90' into releases
This commit is contained in:
commit
aaf651a7aa
|
@ -1,12 +0,0 @@
|
||||||
engines:
|
|
||||||
eslint:
|
|
||||||
enabled: true
|
|
||||||
scss-lint:
|
|
||||||
enabled: true
|
|
||||||
fixme:
|
|
||||||
enabled: true
|
|
||||||
ratings:
|
|
||||||
paths:
|
|
||||||
- "lib/**"
|
|
||||||
exclude_paths:
|
|
||||||
- "**.spec.js"
|
|
|
@ -32,7 +32,7 @@ before_script:
|
||||||
after_script:
|
after_script:
|
||||||
- kill %1 # kill e2e server
|
- kill %1 # kill e2e server
|
||||||
before_deploy:
|
before_deploy:
|
||||||
- npm run build:prod-module
|
- if [[ ! -z "$TRAVIS_TAG" ]]; then npm run build:prod-module; fi
|
||||||
deploy:
|
deploy:
|
||||||
- provider: npm
|
- provider: npm
|
||||||
skip_cleanup: true
|
skip_cleanup: true
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
# ReDoc
|
# ReDoc
|
||||||
**OpenAPI/Swagger-generated API Reference Documentation**
|
**OpenAPI/Swagger-generated API Reference Documentation**
|
||||||
|
|
||||||
[![Build Status](https://travis-ci.org/Rebilly/ReDoc.svg?branch=master)](https://travis-ci.org/Rebilly/ReDoc) [![Coverage Status](https://coveralls.io/repos/Rebilly/ReDoc/badge.svg?branch=master&service=github)](https://coveralls.io/github/Rebilly/ReDoc?branch=master) [![Tested on APIs.guru](http://api.apis.guru/badges/tested_on.svg)](https://APIs.guru) [![Code Climate](https://codeclimate.com/github/Rebilly/ReDoc/badges/gpa.svg)](https://codeclimate.com/github/Rebilly/ReDoc) [![dependencies Status](https://david-dm.org/Rebilly/ReDoc/status.svg)](https://david-dm.org/Rebilly/ReDoc) [![devDependencies Status](https://david-dm.org/Rebilly/ReDoc/dev-status.svg)](https://david-dm.org/Rebilly/ReDoc#info=devDependencies) [![Stories in Ready](https://badge.waffle.io/Rebilly/ReDoc.png?label=ready&title=Ready)](https://waffle.io/Rebilly/ReDoc)
|
[![Build Status](https://travis-ci.org/Rebilly/ReDoc.svg?branch=master)](https://travis-ci.org/Rebilly/ReDoc) [![Coverage Status](https://coveralls.io/repos/Rebilly/ReDoc/badge.svg?branch=master&service=github)](https://coveralls.io/github/Rebilly/ReDoc?branch=master) [![Tested on APIs.guru](http://api.apis.guru/badges/tested_on.svg)](https://APIs.guru) [![dependencies Status](https://david-dm.org/Rebilly/ReDoc/status.svg)](https://david-dm.org/Rebilly/ReDoc) [![devDependencies Status](https://david-dm.org/Rebilly/ReDoc/dev-status.svg)](https://david-dm.org/Rebilly/ReDoc#info=devDependencies) [![Stories in Ready](https://badge.waffle.io/Rebilly/ReDoc.png?label=ready&title=Ready)](https://waffle.io/Rebilly/ReDoc)
|
||||||
|
|
||||||
[![npm](http://img.shields.io/npm/v/redoc.svg)](https://www.npmjs.com/package/redoc) [![Bower](http://img.shields.io/bower/v/redoc.svg)](http://bower.io/) [![License](https://img.shields.io/npm/l/redoc.svg)](https://github.com/Rebilly/ReDoc/blob/master/LICENSE)
|
[![npm](http://img.shields.io/npm/v/redoc.svg)](https://www.npmjs.com/package/redoc) [![Bower](http://img.shields.io/bower/v/redoc.svg)](http://bower.io/) [![License](https://img.shields.io/npm/l/redoc.svg)](https://github.com/Rebilly/ReDoc/blob/master/LICENSE)
|
||||||
|
|
||||||
|
@ -112,6 +112,7 @@ ReDoc makes use of the following [vendor extensions](http://swagger.io/specifica
|
||||||
* **selector**: selector of the element to be used for specifying the offset. The distance from the top of the page to the element's bottom will be used as offset;
|
* **selector**: selector of the element to be used for specifying the offset. The distance from the top of the page to the element's bottom will be used as offset;
|
||||||
* **function**: A getter function. Must return a number representing the offset (in pixels);
|
* **function**: A getter function. Must return a number representing the offset (in pixels);
|
||||||
* `suppress-warnings` - if set, warnings are not rendered at the top of documentation (they still are logged to the console).
|
* `suppress-warnings` - if set, warnings are not rendered at the top of documentation (they still are logged to the console).
|
||||||
|
* `hide-hostname` - if set, the protocol and hostname is not shown in the method definition.
|
||||||
|
|
||||||
## Advanced usage
|
## Advanced usage
|
||||||
Instead of adding `spec-url` attribute to the `<redoc>` element you can initialize ReDoc via globally exposed `Redoc` object:
|
Instead of adding `spec-url` attribute to the `<redoc>` element you can initialize ReDoc via globally exposed `Redoc` object:
|
||||||
|
@ -139,3 +140,5 @@ Redoc.init('http://petstore.swagger.io/v2/swagger.json', {
|
||||||
- Start the server
|
- Start the server
|
||||||
`npm start`
|
`npm start`
|
||||||
- Open `http://localhost:9000`
|
- Open `http://localhost:9000`
|
||||||
|
|
||||||
|
Alternatively, Docker can be used by just running `docker-compose up`.
|
||||||
|
|
|
@ -8,8 +8,7 @@ const IS_PRODUCTION = process.env.NODE_ENV === "production";
|
||||||
// TODO Refactor common parts of config
|
// TODO Refactor common parts of config
|
||||||
|
|
||||||
module.exports = {
|
module.exports = {
|
||||||
context: root(),
|
devtool: '#inline-source-map',
|
||||||
devtool: 'source-map',
|
|
||||||
|
|
||||||
resolve: {
|
resolve: {
|
||||||
extensions: ['.ts', '.js', '.json', '.css'],
|
extensions: ['.ts', '.js', '.json', '.css'],
|
||||||
|
@ -51,7 +50,9 @@ module.exports = {
|
||||||
path: root('dist'),
|
path: root('dist'),
|
||||||
filename: '[name].js',
|
filename: '[name].js',
|
||||||
sourceMapFilename: '[name].[id].map',
|
sourceMapFilename: '[name].[id].map',
|
||||||
chunkFilename: '[id].chunk.js'
|
chunkFilename: '[id].chunk.js',
|
||||||
|
// devtoolModuleFilenameTemplate: "[resource-path]",
|
||||||
|
// devtoolFallbackModuleFilenameTemplate: "[resource-path]?[hash]",
|
||||||
},
|
},
|
||||||
|
|
||||||
module: {
|
module: {
|
||||||
|
|
|
@ -3,7 +3,6 @@ const webpack = require('webpack');
|
||||||
const VERSION = JSON.stringify(require('../package.json').version);
|
const VERSION = JSON.stringify(require('../package.json').version);
|
||||||
|
|
||||||
const root = require('./helpers').root;
|
const root = require('./helpers').root;
|
||||||
const CopyWebpackPlugin = require('copy-webpack-plugin');
|
|
||||||
const BANNER =
|
const BANNER =
|
||||||
`ReDoc - OpenAPI/Swagger-generated API Reference Documentation
|
`ReDoc - OpenAPI/Swagger-generated API Reference Documentation
|
||||||
-------------------------------------------------------------
|
-------------------------------------------------------------
|
||||||
|
|
|
@ -26,6 +26,14 @@ info:
|
||||||
This API features Cross-Origin Resource Sharing (CORS) implemented in compliance with [W3C spec](https://www.w3.org/TR/cors/).
|
This API features Cross-Origin Resource Sharing (CORS) implemented in compliance with [W3C spec](https://www.w3.org/TR/cors/).
|
||||||
And that allows cross-domain communication from the browser.
|
And that allows cross-domain communication from the browser.
|
||||||
All responses have a wildcard same-origin which makes them completely public and accessible to everyone, including any code on any site.
|
All responses have a wildcard same-origin which makes them completely public and accessible to everyone, including any code on any site.
|
||||||
|
# Authentication
|
||||||
|
Petstore offers two forms of authentication:
|
||||||
|
- API Key
|
||||||
|
- OAuth2
|
||||||
|
|
||||||
|
OAuth2 - an open protocol to allow secure authorization in a simple
|
||||||
|
and standard method from web, mobile and desktop applications.
|
||||||
|
<!-- ReDoc-Inject: <security-definitions> -->
|
||||||
version: 1.0.0
|
version: 1.0.0
|
||||||
title: Swagger Petstore
|
title: Swagger Petstore
|
||||||
termsOfService: 'http://swagger.io/terms/'
|
termsOfService: 'http://swagger.io/terms/'
|
||||||
|
@ -48,6 +56,9 @@ tags:
|
||||||
description: Operations about user
|
description: Operations about user
|
||||||
securityDefinitions:
|
securityDefinitions:
|
||||||
petstore_auth:
|
petstore_auth:
|
||||||
|
description: |
|
||||||
|
Get access to data while protecting your account credentials.
|
||||||
|
OAuth2 is also a safer and more secure way to give you access.
|
||||||
type: oauth2
|
type: oauth2
|
||||||
authorizationUrl: 'http://petstore.swagger.io/api/oauth/dialog'
|
authorizationUrl: 'http://petstore.swagger.io/api/oauth/dialog'
|
||||||
flow: implicit
|
flow: implicit
|
||||||
|
@ -55,6 +66,8 @@ securityDefinitions:
|
||||||
'write:pets': modify pets in your account
|
'write:pets': modify pets in your account
|
||||||
'read:pets': read your pets
|
'read:pets': read your pets
|
||||||
api_key:
|
api_key:
|
||||||
|
description: |
|
||||||
|
For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||||
type: apiKey
|
type: apiKey
|
||||||
name: api_key
|
name: api_key
|
||||||
in: header
|
in: header
|
||||||
|
|
8
docker-compose.yml
Normal file
8
docker-compose.yml
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
dev:
|
||||||
|
image: node:7
|
||||||
|
command: sh -c "npm install; npm start -- --host=0.0.0.0"
|
||||||
|
ports:
|
||||||
|
- "9000:9000"
|
||||||
|
volumes:
|
||||||
|
- "./:/code"
|
||||||
|
working_dir: /code
|
|
@ -1,5 +1,5 @@
|
||||||
<div>
|
<div class="api-info-wrapper">
|
||||||
<h1 class="api-info-header">{{info.title}} ({{info.version}})</h1>
|
<h1>{{info.title}} ({{info.version}})</h1>
|
||||||
<p>
|
<p>
|
||||||
Download OpenAPI (fka Swagger) specification:
|
Download OpenAPI (fka Swagger) specification:
|
||||||
<a class="openapi-button" target="_blank" attr.href='{{specUrl}}'> Download </a>
|
<a class="openapi-button" target="_blank" attr.href='{{specUrl}}'> Download </a>
|
||||||
|
@ -17,5 +17,7 @@
|
||||||
<span *ngIf="!info.license.url"> {{info.license.name}} </span>
|
<span *ngIf="!info.license.url"> {{info.license.name}} </span>
|
||||||
</span>
|
</span>
|
||||||
</p>
|
</p>
|
||||||
|
<span class="redoc-markdown-block">
|
||||||
<dynamic-ng2-viewer [html]="info['x-redoc-html-description']"></dynamic-ng2-viewer>
|
<dynamic-ng2-viewer [html]="info['x-redoc-html-description']"></dynamic-ng2-viewer>
|
||||||
|
</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -1,28 +1,24 @@
|
||||||
@import '../../shared/styles/variables';
|
@import '../../shared/styles/variables';
|
||||||
|
|
||||||
.api-info-header {
|
:host > .api-info-wrapper {
|
||||||
font-weight: normal;
|
|
||||||
}
|
|
||||||
|
|
||||||
:host > div {
|
|
||||||
width: 60%;
|
|
||||||
padding: 40px;
|
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
|
padding: $section-spacing;
|
||||||
|
width: 60%;
|
||||||
|
|
||||||
|
|
||||||
@media (max-width: $right-panel-squash-breakpoint) {
|
@media (max-width: $right-panel-squash-breakpoint) {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
a.openapi-button {
|
.openapi-button {
|
||||||
padding: 3px 8px 4px 8px;
|
|
||||||
color: $primary-color;
|
|
||||||
border: 1px solid $primary-color;
|
border: 1px solid $primary-color;
|
||||||
margin-left: 0.5em;
|
color: $primary-color;
|
||||||
font-weight: normal;
|
font-weight: normal;
|
||||||
|
margin-left: 0.5em;
|
||||||
|
padding: 3px 8px 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
:host /deep/ [section] {
|
:host /deep/ [section] {
|
||||||
padding-top: 60px;
|
padding-top: 2 * $section-spacing;
|
||||||
margin-top: 20px;
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,14 @@
|
||||||
@import '../../shared/styles/variables';
|
@import '../../shared/styles/variables';
|
||||||
|
|
||||||
|
:host {
|
||||||
|
display: block;
|
||||||
|
text-align: center;
|
||||||
|
|
||||||
|
@media (max-width: $side-menu-mobile-breakpoint) {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
img {
|
img {
|
||||||
max-height: 150px;
|
max-height: 150px;
|
||||||
width: auto;
|
width: auto;
|
||||||
|
|
|
@ -5,26 +5,16 @@ $cell-spacing: 25px;
|
||||||
$cell-padding: 10px;
|
$cell-padding: 10px;
|
||||||
$bullet-margin: 10px;
|
$bullet-margin: 10px;
|
||||||
$line-border: $lines-width solid $tree-lines-color;
|
$line-border: $lines-width solid $tree-lines-color;
|
||||||
$line-border-erase: ($lines-width + 1px) solid #fff;
|
$line-border-erase: ($lines-width + 1px) solid $background-color;
|
||||||
|
|
||||||
|
$border-color: lighten($secondary-color, 50%);
|
||||||
|
$nullable-color: #3195a6;
|
||||||
|
$hint-border: 1px dotted rgba(38, 50, 56, 0.4);
|
||||||
|
|
||||||
$param-name-height: 20px;
|
$param-name-height: 20px;
|
||||||
|
|
||||||
$sub-schema-offset: ($bullet-size / 2) + $bullet-margin;
|
$sub-schema-offset: ($bullet-size / 2) + $bullet-margin;
|
||||||
|
|
||||||
.param-name {
|
|
||||||
position: relative;
|
|
||||||
border-left: $line-border;
|
|
||||||
padding: $cell-padding 0;
|
|
||||||
vertical-align: top;
|
|
||||||
line-height: $param-name-height;
|
|
||||||
|
|
||||||
white-space: nowrap;
|
|
||||||
font-size: 0.929em;
|
|
||||||
font-weight: $regular;
|
|
||||||
|
|
||||||
box-sizing: border-box;
|
|
||||||
}
|
|
||||||
|
|
||||||
.param-name-wrap {
|
.param-name-wrap {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
padding-right: $cell-spacing;
|
padding-right: $cell-spacing;
|
||||||
|
@ -32,10 +22,9 @@ $sub-schema-offset: ($bullet-size / 2) + $bullet-margin;
|
||||||
}
|
}
|
||||||
|
|
||||||
.param-info {
|
.param-info {
|
||||||
border-bottom: 1px solid #ccc;
|
border-bottom: 1px solid $border-color;
|
||||||
padding: $cell-padding 0;
|
padding: $cell-padding 0;
|
||||||
width: 75%;
|
width: 75%;
|
||||||
line-height: 1em;
|
|
||||||
|
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
}
|
}
|
||||||
|
@ -46,7 +35,7 @@ $sub-schema-offset: ($bullet-size / 2) + $bullet-margin;
|
||||||
margin-right: 6px;
|
margin-right: 6px;
|
||||||
margin-left: 6px;
|
margin-left: 6px;
|
||||||
border-radius: $border-radius;
|
border-radius: $border-radius;
|
||||||
background-color: rgba($primary-color, .1);
|
background-color: rgba($primary-color, 0.1);
|
||||||
padding: 0 4px;
|
padding: 0 4px;
|
||||||
color: rgba($primary-color, 0.7);
|
color: rgba($primary-color, 0.7);
|
||||||
}
|
}
|
||||||
|
@ -58,7 +47,7 @@ $sub-schema-offset: ($bullet-size / 2) + $bullet-margin;
|
||||||
.param-required {
|
.param-required {
|
||||||
vertical-align: middle;
|
vertical-align: middle;
|
||||||
line-height: $param-name-height;
|
line-height: $param-name-height;
|
||||||
color: #f00;
|
color: $red;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
}
|
}
|
||||||
|
@ -66,7 +55,7 @@ $sub-schema-offset: ($bullet-size / 2) + $bullet-margin;
|
||||||
.param-nullable {
|
.param-nullable {
|
||||||
vertical-align: middle;
|
vertical-align: middle;
|
||||||
line-height: $param-name-height;
|
line-height: $param-name-height;
|
||||||
color: #3195a6;
|
color: $nullable-color;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
}
|
}
|
||||||
|
@ -77,116 +66,164 @@ $sub-schema-offset: ($bullet-size / 2) + $bullet-margin;
|
||||||
color: rgba($black, 0.4);
|
color: rgba($black, 0.4);
|
||||||
font-size: 0.929em;
|
font-size: 0.929em;
|
||||||
font-weight: normal;
|
font-weight: normal;
|
||||||
}
|
|
||||||
|
|
||||||
.param-type.array:before {
|
&.array::before {
|
||||||
content: "Array of ";
|
content: $array-text;
|
||||||
color: $black;
|
color: $black;
|
||||||
font-weight: $base-font-weight;
|
font-weight: $base-font-weight;
|
||||||
}
|
}
|
||||||
|
|
||||||
.param-type.tuple:before {
|
&.tuple::before {
|
||||||
content: "Tuple";
|
content: $tuple-text;
|
||||||
color: $black;
|
color: $black;
|
||||||
font-weight: $base-font-weight;
|
font-weight: $base-font-weight;
|
||||||
}
|
}
|
||||||
|
|
||||||
.param-type.with-hint {
|
&.with-hint {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
margin-bottom: 0.4em;
|
margin-bottom: 0.4em;
|
||||||
border-bottom: 1px dotted rgba(38,50,56,0.4);
|
border-bottom: $hint-border;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
cursor: help;
|
cursor: help;
|
||||||
}
|
}
|
||||||
|
|
||||||
.param-type-trivial {
|
&-trivial {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
}
|
}
|
||||||
|
|
||||||
.param-type-file {
|
&-file {
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
text-transform: capitalize;
|
text-transform: capitalize;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* tree */
|
// tree
|
||||||
|
|
||||||
// Bullet
|
// Bullet
|
||||||
|
|
||||||
.param-name > span:before {
|
.param-name {
|
||||||
content: "";
|
border-left: $line-border;
|
||||||
|
box-sizing: border-box;
|
||||||
|
position: relative;
|
||||||
|
|
||||||
|
padding: $cell-padding 0;
|
||||||
|
vertical-align: top;
|
||||||
|
line-height: $param-name-height;
|
||||||
|
|
||||||
|
white-space: nowrap;
|
||||||
|
font-size: 0.929em;
|
||||||
|
font-weight: $regular;
|
||||||
|
|
||||||
|
> span::before {
|
||||||
|
content: '';
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
width: $bullet-size;
|
width: $bullet-size;
|
||||||
height: $bullet-size + 6;
|
height: $bullet-size + 6;
|
||||||
background-color: $primary-color;
|
background-color: $primary-color;
|
||||||
margin: 0 $bullet-margin;
|
margin: 0 $bullet-margin;
|
||||||
vertical-align: middle;
|
vertical-align: middle;
|
||||||
}
|
}
|
||||||
|
|
||||||
.param-name > span:after {
|
> span::after {
|
||||||
content: "";
|
content: '';
|
||||||
position: absolute;
|
position: absolute;
|
||||||
border-top: $line-border;
|
border-top: $line-border;
|
||||||
width: $bullet-margin;
|
width: $bullet-margin;
|
||||||
left: 0;
|
left: 0;
|
||||||
top: ($param-name-height/2) + $cell-padding + 1;
|
top: ($param-name-height / 2) + $cell-padding + 1;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.param:first-of-type > .param-name:before {
|
.param:first-of-type {
|
||||||
content: "";
|
|
||||||
|
> .param-name::before {
|
||||||
|
content: '';
|
||||||
display: block;
|
display: block;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
left: -$lines-width;
|
left: -$lines-width;
|
||||||
top: 0;
|
top: 0;
|
||||||
border-left: $line-border-erase;
|
border-left: $line-border-erase;
|
||||||
height: ($param-name-height/2) + $cell-padding + 1;
|
height: ($param-name-height / 2) + $cell-padding + 1;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.param:last-of-type > .param-name, .param.last > .param-name {
|
.param:last-of-type,
|
||||||
|
.param.last {
|
||||||
|
|
||||||
|
> .param-name {
|
||||||
position: relative;
|
position: relative;
|
||||||
|
|
||||||
&:after {
|
&::after {
|
||||||
content: "";
|
content: '';
|
||||||
display: block;
|
display: block;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
left: -$lines-width - 1px;
|
left: -$lines-width - 1px;
|
||||||
border-left: $line-border-erase;
|
border-left: $line-border-erase;
|
||||||
top: ($param-name-height/2) + $cell-padding + $lines-width + 1;
|
top: ($param-name-height / 2) + $cell-padding + $lines-width + 1;
|
||||||
background-color: white;
|
background-color: $background-color;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.param-wrap:last-of-type > .param-schema {
|
.param-wrap:last-of-type > .param-schema {
|
||||||
border-left-color: transparent;
|
border-left-color: transparent;
|
||||||
}
|
}
|
||||||
|
|
||||||
.param-schema .param-wrap:first-of-type .param-name:before {
|
.param-schema {
|
||||||
display: none !important;
|
.param-wrap:first-of-type {
|
||||||
|
.param-name::before {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.param-schema.last > td {
|
.param-schema.last {
|
||||||
|
> td {
|
||||||
border-left: 0;
|
border-left: 0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.param-enum {
|
.param-enum {
|
||||||
color: $text-color;
|
color: $text-color;
|
||||||
font-size: 13px;
|
font-size: 0.95em;
|
||||||
|
|
||||||
&:before {
|
&::before {
|
||||||
content: 'Values: {';
|
content: 'Valid values: ';
|
||||||
}
|
|
||||||
|
|
||||||
&:after {
|
|
||||||
content: '}';
|
|
||||||
}
|
|
||||||
|
|
||||||
> .enum-value {
|
|
||||||
&:after {
|
|
||||||
content: ", ";
|
|
||||||
}
|
|
||||||
|
|
||||||
&:last-of-type:after {
|
|
||||||
content: none;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.param-pattern {
|
||||||
|
color: $nullable-color;
|
||||||
|
white-space: nowrap;
|
||||||
|
|
||||||
|
&::before,
|
||||||
|
&::after {
|
||||||
|
content: '/';
|
||||||
|
margin: 0 3px;
|
||||||
|
font-size: 1.2em;
|
||||||
|
font-weight: bold;
|
||||||
|
vertical-align: bottom;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.param-default {
|
||||||
|
font-size: 0.95em;
|
||||||
|
|
||||||
|
&::before {
|
||||||
|
content: 'Default: ';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.param-enum-value,
|
||||||
|
.param-default-value {
|
||||||
|
background-color: $background-color;
|
||||||
|
border: 1px solid rgba($secondary-color, 0.2);
|
||||||
|
margin: 2px 3px;
|
||||||
|
padding: 0 5px;
|
||||||
|
border-radius: 2px;
|
||||||
|
color: $secondary-color;
|
||||||
|
display: inline-block;
|
||||||
|
min-width: 20px;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
|
@ -23,8 +23,9 @@
|
||||||
</span>
|
</span>
|
||||||
<span *ngIf="schema['x-nullable']" class="param-nullable">Nullable</span>
|
<span *ngIf="schema['x-nullable']" class="param-nullable">Nullable</span>
|
||||||
<div *ngIf="schema.enum" class="param-enum">
|
<div *ngIf="schema.enum" class="param-enum">
|
||||||
<span *ngFor="let enumItem of schema.enum" class="enum-value {{enumItem.type}}"> {{enumItem.val | json}} </span>
|
<span *ngFor="let enumItem of schema.enum" class="param-enum-value {{enumItem.type}}"> {{enumItem.val | json}} </span>
|
||||||
</div>
|
</div>
|
||||||
|
<span *ngIf="schema.pattern" class="param-pattern">{{schema.pattern}}</span>
|
||||||
</span>
|
</span>
|
||||||
</template>
|
</template>
|
||||||
<template ngSwitchCase="tuple">
|
<template ngSwitchCase="tuple">
|
||||||
|
@ -57,7 +58,7 @@
|
||||||
<span class="param-name-wrap" (click)="subSchema.toggle()">
|
<span class="param-name-wrap" (click)="subSchema.toggle()">
|
||||||
<span class="param-name-content">
|
<span class="param-name-content">
|
||||||
{{prop._name}}
|
{{prop._name}}
|
||||||
<span class="param-enum-value" [hidden]="!prop._enumItem"> {{prop._enumItem?.val | json}} </span>
|
<span class="param-name-enumvalue" [hidden]="!prop._enumItem"> {{prop._enumItem?.val | json}} </span>
|
||||||
</span>
|
</span>
|
||||||
<svg *ngIf="prop._pointer" xmlns="http://www.w3.org/2000/svg" version="1.1" x="0" y="0" viewBox="0 0 24 24" xml:space="preserve">
|
<svg *ngIf="prop._pointer" xmlns="http://www.w3.org/2000/svg" version="1.1" x="0" y="0" viewBox="0 0 24 24" xml:space="preserve">
|
||||||
<polygon points="17.3 8.3 12 13.6 6.7 8.3 5.3 9.7 12 16.4 18.7 9.7 "/>
|
<polygon points="17.3 8.3 12 13.6 6.7 8.3 5.3 9.7 12 16.4 18.7 9.7 "/>
|
||||||
|
@ -72,14 +73,16 @@
|
||||||
</span>
|
</span>
|
||||||
<span *ngIf="prop._required" class="param-required">Required</span>
|
<span *ngIf="prop._required" class="param-required">Required</span>
|
||||||
<span *ngIf="prop['x-nullable']" class="param-nullable">Nullable</span>
|
<span *ngIf="prop['x-nullable']" class="param-nullable">Nullable</span>
|
||||||
<div *ngIf="prop.default != null">Default: {{prop.default | json}}</div>
|
<div class="param-default" *ngIf="prop.default != null">
|
||||||
<div *ngIf="prop.enum && !prop.isDiscriminator" class="param-enum">
|
<span class="param-default-value">{{prop.default | json}}</span>
|
||||||
<span *ngFor="let enumItem of prop.enum" class="enum-value {{enumItem.type}}"> {{enumItem.val | json}} </span>
|
|
||||||
</div>
|
</div>
|
||||||
|
<div *ngIf="prop.enum && !prop.isDiscriminator" class="param-enum">
|
||||||
|
<span *ngFor="let enumItem of prop.enum" class="param-enum-value {{enumItem.type}}"> {{enumItem.val | json}} </span>
|
||||||
|
</div>
|
||||||
|
<span *ngIf="prop.pattern" class="param-pattern">{{prop.pattern}}</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="param-description" [innerHtml]="prop.description | marked"></div>
|
<div class="param-description" [innerHtml]="prop.description | marked"></div>
|
||||||
<div class="discriminator-info" *ngIf="prop.isDiscriminator">
|
<div class="discriminator-info" *ngIf="prop.isDiscriminator">
|
||||||
<span>This field value determines the exact schema:</span>
|
|
||||||
<drop-down (change)="selectDescendant($event)">
|
<drop-down (change)="selectDescendant($event)">
|
||||||
<option *ngFor="let descendant of descendants; let i=index"
|
<option *ngFor="let descendant of descendants; let i=index"
|
||||||
[value]="i" [attr.selected]="descendant.active ? '' : null" >{{descendant.name}}</option>
|
[value]="i" [attr.selected]="descendant.active ? '' : null" >{{descendant.name}}</option>
|
||||||
|
|
|
@ -1,8 +1,9 @@
|
||||||
@import 'json-schema-common';
|
@import 'json-schema-common';
|
||||||
|
|
||||||
/* styles for array-schema for array */
|
// styles for array-schema for array
|
||||||
$array-marker-font-sz: 13px;
|
$array-marker-font-sz: 13px;
|
||||||
$array-marker-line-height: 1.5;
|
$array-marker-line-height: 1.5;
|
||||||
|
|
||||||
:host {
|
:host {
|
||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
||||||
|
@ -15,6 +16,7 @@ $array-marker-line-height: 1.5;
|
||||||
.derived-schema {
|
.derived-schema {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
.derived-schema.active {
|
.derived-schema.active {
|
||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
||||||
|
@ -156,13 +158,7 @@ table {
|
||||||
}
|
}
|
||||||
|
|
||||||
.discriminator-info {
|
.discriminator-info {
|
||||||
font-weight: $regular;
|
margin-top: 5px;
|
||||||
margin-bottom: 10px;
|
|
||||||
|
|
||||||
> span {
|
|
||||||
font-size: 0.9em;
|
|
||||||
font-weight: $light;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.discriminator-wrap:not(.empty) > td {
|
.discriminator-wrap:not(.empty) > td {
|
||||||
|
@ -214,7 +210,7 @@ li:before {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.param-enum-value {
|
.param-name-enumvalue {
|
||||||
padding: 2px;
|
padding: 2px;
|
||||||
background-color: #e6ebf6;
|
background-color: #e6ebf6;
|
||||||
|
|
||||||
|
|
|
@ -13,12 +13,12 @@
|
||||||
<responses-list pointer="{{pointer}}/responses"> </responses-list>
|
<responses-list pointer="{{pointer}}/responses"> </responses-list>
|
||||||
</div>
|
</div>
|
||||||
<div class="method-samples">
|
<div class="method-samples">
|
||||||
<h5>Definition</h5>
|
<h4 class="method-params-subheader">Definition</h4>
|
||||||
|
|
||||||
<div class="method-endpoint">
|
<div class="method-endpoint">
|
||||||
<h5 class="http-method" [ngClass]="method.httpMethod">{{method.httpMethod}}</h5>
|
<h5 class="http-method" [ngClass]="method.httpMethod">{{method.httpMethod}}</h5>
|
||||||
<span select-on-click><!--
|
<span select-on-click><!--
|
||||||
--><span class="api-url">{{method.apiUrl}}</span><span class="path">{{method.path}}</span><!--
|
--><span class="method-api-url">{{method.apiUrl}}</span><span class="method-api-url-path">{{method.path}}</span><!--
|
||||||
--></span>
|
--></span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
|
@ -12,14 +12,6 @@
|
||||||
border-bottom: 0;
|
border-bottom: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
h2 {
|
|
||||||
color: $secondary-color;
|
|
||||||
}
|
|
||||||
|
|
||||||
responses-list, params-list {
|
|
||||||
display: block;
|
|
||||||
}
|
|
||||||
|
|
||||||
.method-header {
|
.method-header {
|
||||||
margin-bottom: .9em;
|
margin-bottom: .9em;
|
||||||
}
|
}
|
||||||
|
@ -35,7 +27,7 @@ responses-list, params-list {
|
||||||
overflow-x: auto;
|
overflow-x: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
.method-endpoint > h5 {
|
.method-endpoint > .method-params-subheader {
|
||||||
padding-top: 1px;
|
padding-top: 1px;
|
||||||
padding-bottom: 0;
|
padding-bottom: 0;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
|
@ -46,43 +38,42 @@ responses-list, params-list {
|
||||||
border-radius: $border-radius;
|
border-radius: $border-radius;
|
||||||
}
|
}
|
||||||
|
|
||||||
.api-url {
|
.method-api-url {
|
||||||
color: rgba(#ffffff, .6);
|
color: rgba(#ffffff, .6);
|
||||||
margin-left: 10px;
|
margin-left: 10px;
|
||||||
margin-top: 2px;
|
margin-top: 2px;
|
||||||
position: relative;
|
position: relative;
|
||||||
top: 1px;
|
top: 1px;
|
||||||
font-family: $headers-font, $headers-font-family;
|
font-family: $headers-font, $headers-font-family;
|
||||||
font-size: 0.929em!important;
|
font-size: 0.929em;
|
||||||
}
|
|
||||||
|
|
||||||
.path {
|
&-path {
|
||||||
font-family: $headers-font, $headers-font-family;
|
font-family: $headers-font, $headers-font-family;
|
||||||
position: relative;
|
position: relative;
|
||||||
top: 1px;
|
top: 1px;
|
||||||
color: #ffffff;
|
color: #ffffff;
|
||||||
font-size: 0.929em!important;
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.method-tags {
|
.method-tags {
|
||||||
margin-top: 20px;
|
margin-top: 20px;
|
||||||
}
|
|
||||||
|
|
||||||
.method-tags a {
|
> a {
|
||||||
font-size: 16px;
|
font-size: 16px;
|
||||||
color: #999;
|
color: #999;
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
padding: 0 0.5em;
|
padding: 0 0.5em;
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
}
|
|
||||||
|
|
||||||
.method-tags a:before {
|
&:before {
|
||||||
content: '#';
|
content: '#';
|
||||||
margin-right: -0.4em;
|
margin-right: -0.4em;
|
||||||
}
|
}
|
||||||
|
|
||||||
.method-tags a:first-of-type {
|
&:first-of-type {
|
||||||
padding: 0;
|
padding: 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.method-content, .method-samples {
|
.method-content, .method-samples {
|
||||||
|
@ -93,20 +84,16 @@ responses-list, params-list {
|
||||||
|
|
||||||
.method-content {
|
.method-content {
|
||||||
width: 100% - $samples-panel-width;
|
width: 100% - $samples-panel-width;
|
||||||
padding: 40px;
|
padding: $section-spacing;
|
||||||
}
|
}
|
||||||
|
|
||||||
.method-samples {
|
.method-samples {
|
||||||
color: $sample-panel-color;
|
color: $sample-panel-color;
|
||||||
width: 40%;
|
width: 40%;
|
||||||
padding: 40px;
|
padding: $section-spacing;
|
||||||
background: $samples-panel-bg-color;
|
background: $samples-panel-bg-color;
|
||||||
}
|
}
|
||||||
|
|
||||||
responses-samples {
|
|
||||||
display: block;
|
|
||||||
}
|
|
||||||
|
|
||||||
.method-samples header,
|
.method-samples header,
|
||||||
.method-samples > h5 {
|
.method-samples > h5 {
|
||||||
color: $sample-panel-headers-color;
|
color: $sample-panel-headers-color;
|
||||||
|
@ -137,6 +124,8 @@ responses-samples {
|
||||||
background: #ffffff;
|
background: #ffffff;
|
||||||
padding: 3px 10px;
|
padding: 3px 10px;
|
||||||
text-transform: uppercase;
|
text-transform: uppercase;
|
||||||
|
display: inline-block;
|
||||||
|
margin: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
[select-on-click] {
|
[select-on-click] {
|
||||||
|
|
|
@ -3,6 +3,7 @@ import { Input, Component, OnInit, ChangeDetectionStrategy } from '@angular/core
|
||||||
import JsonPointer from '../../utils/JsonPointer';
|
import JsonPointer from '../../utils/JsonPointer';
|
||||||
import { BaseComponent, SpecManager } from '../base';
|
import { BaseComponent, SpecManager } from '../base';
|
||||||
import { SchemaHelper } from '../../services/schema-helper.service';
|
import { SchemaHelper } from '../../services/schema-helper.service';
|
||||||
|
import { OptionsService } from '../../services/options.service';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'method',
|
selector: 'method',
|
||||||
|
@ -16,13 +17,17 @@ export class Method extends BaseComponent implements OnInit {
|
||||||
|
|
||||||
method:any;
|
method:any;
|
||||||
|
|
||||||
constructor(specMgr:SpecManager) {
|
constructor(specMgr:SpecManager, private optionsService: OptionsService) {
|
||||||
super(specMgr);
|
super(specMgr);
|
||||||
}
|
}
|
||||||
|
|
||||||
init() {
|
init() {
|
||||||
this.method = {};
|
this.method = {};
|
||||||
|
if (this.optionsService.options.hideHostname) {
|
||||||
|
this.method.apiUrl = this.specMgr.basePath;
|
||||||
|
} else {
|
||||||
this.method.apiUrl = this.specMgr.apiUrl;
|
this.method.apiUrl = this.specMgr.apiUrl;
|
||||||
|
}
|
||||||
this.method.httpMethod = JsonPointer.baseName(this.pointer);
|
this.method.httpMethod = JsonPointer.baseName(this.pointer);
|
||||||
this.method.path = JsonPointer.baseName(this.pointer, 2);
|
this.method.path = JsonPointer.baseName(this.pointer, 2);
|
||||||
this.method.info = this.componentSchema;
|
this.method.info = this.componentSchema;
|
||||||
|
|
|
@ -1,7 +1,11 @@
|
||||||
@import '../../shared/styles/variables';
|
@import '../../shared/styles/variables';
|
||||||
|
|
||||||
|
:host {
|
||||||
|
display: block;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
.tag-info {
|
.tag-info {
|
||||||
padding: 40px;
|
padding: $section-spacing;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
background-color: white;
|
background-color: white;
|
||||||
width: 60%;
|
width: 60%;
|
||||||
|
|
|
@ -16,10 +16,13 @@
|
||||||
title="{{param._displayTypeHint}}"> {{param._displayType}} {{param._displayFormat}}</span>
|
title="{{param._displayTypeHint}}"> {{param._displayType}} {{param._displayFormat}}</span>
|
||||||
<span class="param-range" *ngIf="param._range"> {{param._range}} </span>
|
<span class="param-range" *ngIf="param._range"> {{param._range}} </span>
|
||||||
<span *ngIf="param.required" class="param-required">Required</span>
|
<span *ngIf="param.required" class="param-required">Required</span>
|
||||||
<div class="default" *ngIf="param.default != null">Default: {{param.default | json}}</div>
|
<div class="param-default" *ngIf="param.default != null">
|
||||||
<div *ngIf="param.enum" class="param-enum">
|
<span class="param-default-value">{{param.default | json}}</span>
|
||||||
<span *ngFor="let enumItem of param.enum" class="enum-value {{enumItem.type}}"> {{enumItem.val | json}} </span>
|
|
||||||
</div>
|
</div>
|
||||||
|
<div *ngIf="param.enum" class="param-enum">
|
||||||
|
<span *ngFor="let enumItem of param.enum" class="param-enum-value {{enumItem.type}}"> {{enumItem.val | json}} </span>
|
||||||
|
</div>
|
||||||
|
<span *ngIf="param.pattern" class="param-pattern">{{param.pattern}}</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="param-description" [innerHtml]="param.description | marked"></div>
|
<div class="param-description" [innerHtml]="param.description | marked"></div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
<api-logo> </api-logo>
|
<api-logo> </api-logo>
|
||||||
<side-menu> </side-menu>
|
<side-menu> </side-menu>
|
||||||
</div>
|
</div>
|
||||||
<div id="api-content">
|
<div class="api-content">
|
||||||
<warnings></warnings>
|
<warnings></warnings>
|
||||||
<api-info></api-info>
|
<api-info></api-info>
|
||||||
<methods-list> </methods-list>
|
<methods-list> </methods-list>
|
||||||
|
|
|
@ -36,30 +36,6 @@
|
||||||
color: $text-color;
|
color: $text-color;
|
||||||
}
|
}
|
||||||
|
|
||||||
side-menu {
|
|
||||||
display: block;
|
|
||||||
box-sizing: border-box;
|
|
||||||
}
|
|
||||||
|
|
||||||
methods-list {
|
|
||||||
display: block;
|
|
||||||
overflow: hidden;
|
|
||||||
}
|
|
||||||
|
|
||||||
api-info, .side-bar {
|
|
||||||
display: block;
|
|
||||||
padding: 10px 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
api-logo {
|
|
||||||
display: block;
|
|
||||||
text-align: center;
|
|
||||||
|
|
||||||
@media (max-width: $side-menu-mobile-breakpoint) {
|
|
||||||
display: none;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
[sticky-sidebar] {
|
[sticky-sidebar] {
|
||||||
width: $side-bar-width;
|
width: $side-bar-width;
|
||||||
background-color: $side-bar-bg-color;
|
background-color: $side-bar-bg-color;
|
||||||
|
@ -73,7 +49,7 @@ api-logo {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#api-content {
|
.api-content {
|
||||||
margin-left: $side-bar-width;
|
margin-left: $side-bar-width;
|
||||||
position: relative;
|
position: relative;
|
||||||
@media (max-width: $side-menu-mobile-breakpoint) {
|
@media (max-width: $side-menu-mobile-breakpoint) {
|
||||||
|
@ -82,7 +58,7 @@ api-logo {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#api-content:before {
|
.api-content:before {
|
||||||
content: "";
|
content: "";
|
||||||
background: $samples-panel-bg-color;
|
background: $samples-panel-bg-color;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
|
@ -91,28 +67,43 @@ api-logo {
|
||||||
right: 0;
|
right: 0;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
z-index: -1;
|
z-index: -1;
|
||||||
|
|
||||||
|
@media (max-width: $right-panel-squash-breakpoint) {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@media (max-width: $right-panel-squash-breakpoint) {
|
.redoc-error {
|
||||||
#api-content:before {
|
padding: 20px;
|
||||||
display: none;
|
text-align: center;
|
||||||
|
color: $red;
|
||||||
|
> h2 {
|
||||||
|
color: $red;
|
||||||
|
font-size: 40px;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.redoc-error-details {
|
||||||
|
max-width: 750px;
|
||||||
|
margin: 0 auto;
|
||||||
|
font-size: 18px;
|
||||||
|
}
|
||||||
|
|
||||||
/* global redoc styles */
|
/* global redoc styles */
|
||||||
|
|
||||||
@for $index from 1 through 5 {
|
@for $index from 1 through 5 {
|
||||||
:host /deep/ h#{$index}{
|
:host /deep/ h#{$index}{
|
||||||
margin-top: 0;
|
margin-top: 0;
|
||||||
font-family: $headers-font, $headers-font-family;
|
font-family: $headers-font, $headers-font-family;
|
||||||
color: $headers-color;
|
color: $secondary-color;
|
||||||
font-weight: $headers-font-weight;
|
font-weight: $headers-font-weight;
|
||||||
|
line-height: 1.4em;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
:host /deep/ {
|
:host /deep/ {
|
||||||
h1 { font-size: $h1; }
|
h1 { font-size: $h1; color: $headers-color; }
|
||||||
h2 { font-size: $h2; }
|
h2 { font-size: $h2; }
|
||||||
h3 { font-size: $h3; }
|
h3 { font-size: $h3; }
|
||||||
h4 { font-size: $h4; }
|
h4 { font-size: $h4; }
|
||||||
|
@ -153,7 +144,7 @@ api-logo {
|
||||||
footer {
|
footer {
|
||||||
position: relative;
|
position: relative;
|
||||||
text-align: right;
|
text-align: right;
|
||||||
padding: 10px 40px;
|
padding: 10px $section-spacing;
|
||||||
font-size: 15px;
|
font-size: 15px;
|
||||||
margin-top: -35px;
|
margin-top: -35px;
|
||||||
color: white;
|
color: white;
|
||||||
|
@ -256,19 +247,3 @@ footer {
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.redoc-error {
|
|
||||||
padding: 20px;
|
|
||||||
text-align: center;
|
|
||||||
color: #cc0000;
|
|
||||||
> h2 {
|
|
||||||
color: #cc0000;
|
|
||||||
font-size: 40px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.redoc-error-details {
|
|
||||||
max-width: 750px;
|
|
||||||
margin: 0 auto;
|
|
||||||
font-size: 18px;
|
|
||||||
}
|
|
||||||
|
|
|
@ -2,6 +2,7 @@
|
||||||
|
|
||||||
:host {
|
:host {
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
display: block;
|
||||||
}
|
}
|
||||||
|
|
||||||
.action-buttons {
|
.action-buttons {
|
||||||
|
@ -70,7 +71,7 @@ header {
|
||||||
padding-top: 10px;
|
padding-top: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
pre {
|
.code-sample pre {
|
||||||
overflow-x: auto;
|
overflow-x: auto;
|
||||||
word-break: break-all;
|
word-break: break-all;
|
||||||
word-wrap: break-word;
|
word-wrap: break-word;
|
||||||
|
|
|
@ -1,14 +1,14 @@
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
import { Component, ViewChildren, QueryList, Input,
|
import { Component, ViewChildren, QueryList, Input,
|
||||||
ChangeDetectionStrategy, OnInit, HostBinding } from '@angular/core';
|
ChangeDetectionStrategy, OnInit, HostBinding, ElementRef, NgZone } from '@angular/core';
|
||||||
|
|
||||||
import { Subject } from 'rxjs/Subject';
|
import { Subject } from 'rxjs/Subject';
|
||||||
|
|
||||||
import { BaseComponent, SpecManager } from '../base';
|
import { BaseComponent, SpecManager } from '../base';
|
||||||
import JsonPointer from '../../utils/JsonPointer';
|
import JsonPointer from '../../utils/JsonPointer';
|
||||||
import { Tabs } from '../../shared/components/index';
|
import { Tabs } from '../../shared/components/index';
|
||||||
import { AppStateService } from '../../services/index';
|
import { AppStateService, ScrollService } from '../../services/index';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'request-samples',
|
selector: 'request-samples',
|
||||||
|
@ -26,14 +26,26 @@ export class RequestSamples extends BaseComponent implements OnInit {
|
||||||
selectedLang: Subject<any>;
|
selectedLang: Subject<any>;
|
||||||
samples: Array<any>;
|
samples: Array<any>;
|
||||||
|
|
||||||
constructor(specMgr:SpecManager, public appState:AppStateService) {
|
constructor(
|
||||||
|
specMgr:SpecManager,
|
||||||
|
public appState:AppStateService,
|
||||||
|
private scrollService: ScrollService,
|
||||||
|
private el: ElementRef,
|
||||||
|
private zone: NgZone
|
||||||
|
) {
|
||||||
super(specMgr);
|
super(specMgr);
|
||||||
|
|
||||||
this.selectedLang = this.appState.samplesLanguage;
|
this.selectedLang = this.appState.samplesLanguage;
|
||||||
}
|
}
|
||||||
|
|
||||||
changeLangNotify(lang) {
|
changeLangNotify(lang) {
|
||||||
|
let relativeScrollPos = this.scrollService.relativeScrollPos(this.el.nativeElement);
|
||||||
this.selectedLang.next(lang);
|
this.selectedLang.next(lang);
|
||||||
|
// do scroll in the end of VM turn to have it seamless
|
||||||
|
let subscription = this.zone.onMicrotaskEmpty.subscribe(() => {
|
||||||
|
this.scrollService.scrollTo(this.el.nativeElement, relativeScrollPos);
|
||||||
|
subscription.unsubscribe();
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
init() {
|
init() {
|
||||||
|
|
|
@ -1,9 +1,13 @@
|
||||||
@import '../../shared/styles/variables';
|
@import '../../shared/styles/variables';
|
||||||
|
|
||||||
|
:host {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
|
||||||
.responses-list-header {
|
.responses-list-header {
|
||||||
font-size: 18px;
|
font-size: 18px;
|
||||||
padding: 0.2em 0;
|
padding: 0.2em 0;
|
||||||
margin: 3em 0 1.1em 0;
|
margin: 3em 0 1.1em;
|
||||||
color: #253137;
|
color: #253137;
|
||||||
font-weight: normal;
|
font-weight: normal;
|
||||||
}
|
}
|
||||||
|
@ -45,13 +49,13 @@ header {
|
||||||
margin-right: 6px;
|
margin-right: 6px;
|
||||||
margin-left: 6px;
|
margin-left: 6px;
|
||||||
border-radius: $border-radius;
|
border-radius: $border-radius;
|
||||||
background-color: rgba($primary-color, .1);
|
background-color: rgba($primary-color, 0.1);
|
||||||
padding: 0 4px;
|
padding: 0 4px;
|
||||||
color: rgba($primary-color, 0.7);
|
color: rgba($primary-color, 0.7);
|
||||||
}
|
}
|
||||||
|
|
||||||
.header-type.array:before {
|
.header-type.array::before {
|
||||||
content: "Array of ";
|
content: $array-text;
|
||||||
color: $black;
|
color: $black;
|
||||||
font-weight: $base-font-weight;
|
font-weight: $base-font-weight;
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,13 +2,6 @@
|
||||||
|
|
||||||
:host {
|
:host {
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
}
|
|
||||||
|
|
||||||
tab, tabs {
|
|
||||||
display: block;
|
|
||||||
}
|
|
||||||
|
|
||||||
schema-sample {
|
|
||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,9 @@
|
||||||
@import '../../shared/styles/variables';
|
@import '../../shared/styles/variables';
|
||||||
|
|
||||||
|
:host {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
|
||||||
pre {
|
pre {
|
||||||
background-color: transparent;
|
background-color: transparent;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
|
|
|
@ -2,8 +2,7 @@
|
||||||
<h2 class="sharable-header" attr.section="section/Authentication/{{def.name}}">
|
<h2 class="sharable-header" attr.section="section/Authentication/{{def.name}}">
|
||||||
<a class="share-link" href="#section/Authentication/{{def.name}}"></a>{{def.name}}</h2>
|
<a class="share-link" href="#section/Authentication/{{def.name}}"></a>{{def.name}}</h2>
|
||||||
<div [innerHTML]="def.details.description | marked"></div>
|
<div [innerHTML]="def.details.description | marked"></div>
|
||||||
<div class="redoc-markdown-block"> <!-- apply md styles to table -->
|
<table class="security-details">
|
||||||
<table class="details">
|
|
||||||
<tr>
|
<tr>
|
||||||
<th> Security scheme type: </th>
|
<th> Security scheme type: </th>
|
||||||
<td> {{def.details._displayType}} </td>
|
<td> {{def.details._displayType}} </td>
|
||||||
|
@ -29,12 +28,11 @@
|
||||||
</table>
|
</table>
|
||||||
<template [ngIf]="def.details.type === 'oauth2'">
|
<template [ngIf]="def.details.type === 'oauth2'">
|
||||||
<h3> OAuth2 Scopes </h3>
|
<h3> OAuth2 Scopes </h3>
|
||||||
<table class="scopes">
|
<table class="security-scopes-details">
|
||||||
<tr *ngFor="let scopeName of def.details.scopes | keys">
|
<tr *ngFor="let scopeName of def.details.scopes | keys">
|
||||||
<th> {{scopeName}} </th>
|
<th> {{scopeName}} </th>
|
||||||
<td> {{def.details.scopes[scopeName]}} </td>
|
<td> {{def.details.scopes[scopeName]}} </td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
</template>
|
</template>
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -1,16 +1,16 @@
|
||||||
@import '../../shared/styles/variables';
|
@import '../../shared/styles/variables';
|
||||||
|
|
||||||
|
:host {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
|
||||||
.security-definition:not(:last-of-type) {
|
.security-definition:not(:last-of-type) {
|
||||||
border-bottom: 1px solid rgba($text-color, .3);
|
border-bottom: 1px solid rgba($text-color, .3);
|
||||||
padding-bottom: 20px;
|
padding-bottom: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
h2, h3 {
|
|
||||||
color: $secondary-color;
|
|
||||||
}
|
|
||||||
|
|
||||||
:host h2 {
|
:host h2 {
|
||||||
padding-top: 40px;
|
padding-top: $section-spacing;
|
||||||
}
|
}
|
||||||
|
|
||||||
h3 {
|
h3 {
|
||||||
|
@ -18,7 +18,7 @@ h3 {
|
||||||
font-size: 1em;
|
font-size: 1em;
|
||||||
}
|
}
|
||||||
|
|
||||||
:host .redoc-markdown-block table {
|
:host .security-scopes-details, :host .security-details {
|
||||||
margin-top: 20px;
|
margin-top: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,11 @@
|
||||||
@import '../../shared/styles/variables';
|
@import '../../shared/styles/variables';
|
||||||
$mobile-menu-compact-breakpoint: 550px;
|
$mobile-menu-compact-breakpoint: 550px;
|
||||||
|
|
||||||
|
:host {
|
||||||
|
display: block;
|
||||||
|
box-sizing: border-box;
|
||||||
|
}
|
||||||
|
|
||||||
.menu-header {
|
.menu-header {
|
||||||
text-transform: uppercase;
|
text-transform: uppercase;
|
||||||
color: $headers-color;
|
color: $headers-color;
|
||||||
|
|
|
@ -27,11 +27,14 @@ export class ContentProjector {
|
||||||
}
|
}
|
||||||
|
|
||||||
let parentCompRef = parentView.createComponent(componentFactory, null, contextInjector, [projectedNodes]);
|
let parentCompRef = parentView.createComponent(componentFactory, null, contextInjector, [projectedNodes]);
|
||||||
|
|
||||||
|
// using private property to get AppElement instance
|
||||||
let appElement = (<any>parentView)._element;
|
let appElement = (<any>parentView)._element;
|
||||||
appElement.nestedViews = appElement.nestedViews || [];
|
appElement.nestedViews = appElement.nestedViews || [];
|
||||||
for (let i=0; i < componentRefs.length; i++) {
|
for (let i=0; i < componentRefs.length; i++) {
|
||||||
let compRef = componentRefs[i];
|
let compRef = componentRefs[i];
|
||||||
appElement.nestedViews.push((<any>compRef.hostView).internalView);
|
appElement.nestedViews.push((<any>compRef.hostView).internalView);
|
||||||
|
// attach appElement to parentView change detector
|
||||||
(<any>compRef.hostView).internalView.addToContentChildren(appElement);
|
(<any>compRef.hostView).internalView.addToContentChildren(appElement);
|
||||||
}
|
}
|
||||||
return parentCompRef;
|
return parentCompRef;
|
||||||
|
|
|
@ -8,7 +8,7 @@ const defaults = {
|
||||||
disableLazySchemas: false
|
disableLazySchemas: false
|
||||||
};
|
};
|
||||||
|
|
||||||
const OPTION_NAMES = new Set(['scrollYOffset', 'disableLazySchemas', 'specUrl', 'suppressWarnings']);
|
const OPTION_NAMES = new Set(['scrollYOffset', 'disableLazySchemas', 'specUrl', 'suppressWarnings', 'hideHostname']);
|
||||||
|
|
||||||
@Injectable()
|
@Injectable()
|
||||||
export class OptionsService {
|
export class OptionsService {
|
||||||
|
@ -69,5 +69,6 @@ export class OptionsService {
|
||||||
|
|
||||||
if (isString(this._options.disableLazySchemas)) this._options.disableLazySchemas = true;
|
if (isString(this._options.disableLazySchemas)) this._options.disableLazySchemas = true;
|
||||||
if (isString(this._options.suppressWarnings)) this._options.suppressWarnings = true;
|
if (isString(this._options.suppressWarnings)) this._options.suppressWarnings = true;
|
||||||
|
if (isString(this._options.hideHostname)) this._options.hideHostname = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -42,17 +42,22 @@ export class ScrollService {
|
||||||
return INVIEW_POSITION.INVIEW;
|
return INVIEW_POSITION.INVIEW;
|
||||||
}
|
}
|
||||||
|
|
||||||
scrollTo($el) {
|
scrollTo($el, offset:number = 0) {
|
||||||
// TODO: rewrite this to use offsetTop as more reliable solution
|
// TODO: rewrite this to use offsetTop as more reliable solution
|
||||||
let subjRect = $el.getBoundingClientRect();
|
let subjRect = $el.getBoundingClientRect();
|
||||||
let offset = this.scrollY() + subjRect.top - this.scrollYOffset() + 1;
|
let posY = this.scrollY() + subjRect.top - this.scrollYOffset() + offset + 1;
|
||||||
if (this.$scrollParent.scrollTo) {
|
if (this.$scrollParent.scrollTo) {
|
||||||
this.$scrollParent.scrollTo(0, offset);
|
this.$scrollParent.scrollTo(0, posY);
|
||||||
} else {
|
} else {
|
||||||
this.$scrollParent.scrollTop = offset;
|
this.$scrollParent.scrollTop = posY;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
relativeScrollPos($el) {
|
||||||
|
let subjRect = $el.getBoundingClientRect();
|
||||||
|
return - subjRect.top + this.scrollYOffset() - 1;
|
||||||
|
}
|
||||||
|
|
||||||
scrollHandler(evt) {
|
scrollHandler(evt) {
|
||||||
let isScrolledDown = (this.scrollY() - this.prevOffsetY > 0);
|
let isScrolledDown = (this.scrollY() - this.prevOffsetY > 0);
|
||||||
this.prevOffsetY = this.scrollY();
|
this.prevOffsetY = this.scrollY();
|
||||||
|
|
|
@ -1,5 +1,9 @@
|
||||||
@import '../../styles/variables';
|
@import '../../styles/variables';
|
||||||
|
|
||||||
|
:host {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
|
||||||
ul {
|
ul {
|
||||||
display: block;
|
display: block;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
|
@ -12,9 +16,6 @@ li {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
li.active {
|
|
||||||
}
|
|
||||||
|
|
||||||
.tab-success, .tab-error, .tab-redirect, .tab-info {
|
.tab-success, .tab-error, .tab-redirect, .tab-info {
|
||||||
&:before {
|
&:before {
|
||||||
content: "";
|
content: "";
|
||||||
|
|
|
@ -50,6 +50,12 @@ $zippy-redirect-bg-color: rgba($zippy-redirect-color, .08);
|
||||||
.zippy-indicator svg {
|
.zippy-indicator svg {
|
||||||
height: 1.2em;
|
height: 1.2em;
|
||||||
vertical-align: middle;
|
vertical-align: middle;
|
||||||
|
transition: all 0.3s ease;
|
||||||
|
transform: rotateZ(-180deg);
|
||||||
|
}
|
||||||
|
|
||||||
|
.zippy-hidden > .zippy-title svg {
|
||||||
|
transform: rotateZ(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,48 +1,52 @@
|
||||||
// Colors
|
// Colors
|
||||||
// ---------------------------
|
// ---------------------------
|
||||||
$primary-color : #0033a0;
|
$primary-color: #0033a0;
|
||||||
$secondary-color : #263238;
|
$secondary-color: #263238;
|
||||||
$black : #263238;
|
$black: #263238;
|
||||||
$green : #00aa13;
|
$green: #00aa13;
|
||||||
$yellow : #f1c400;
|
$yellow: #f1c400;
|
||||||
$red : #e53935;
|
$red: #e53935;
|
||||||
|
$background-color: #fff;
|
||||||
|
|
||||||
$em-size : 14px;
|
$em-size: 14px;
|
||||||
|
|
||||||
// Font weights
|
// Font weights
|
||||||
// ---------------------------
|
// ---------------------------
|
||||||
$light : 300;
|
$light: 300;
|
||||||
$regular : 400;
|
$regular: 400;
|
||||||
$bold : 700;
|
$bold: 700;
|
||||||
|
|
||||||
// Base Font
|
// Base Font
|
||||||
// ---------------------------
|
// ---------------------------
|
||||||
$base-font : Roboto;
|
$base-font: Roboto;
|
||||||
$base-font-family : sans-serif;
|
$base-font-family: sans-serif;
|
||||||
$base-font-weight : $light;
|
$base-font-weight: $light;
|
||||||
$base-font-size : 1em;
|
$base-font-size: 1em;
|
||||||
$base-line-height : 1.55em;
|
$base-line-height: 1.55em;
|
||||||
$text-color : $black;
|
$text-color: $black;
|
||||||
|
|
||||||
// Heading Font
|
// Heading Font
|
||||||
// ---------------------------
|
// ---------------------------
|
||||||
$headers-font : Montserrat;
|
$headers-font: Montserrat;
|
||||||
$headers-font-family : sans-serif;
|
$headers-font-family: sans-serif;
|
||||||
$headers-font-weight : $regular;
|
$headers-font-weight: $regular;
|
||||||
$headers-color : $primary-color;
|
$headers-color: $primary-color;
|
||||||
$method-headers-color : $primary-color;
|
$method-headers-color: $primary-color;
|
||||||
$h1: 1.85714285714286em;
|
$h1: 1.85714285714286em;
|
||||||
$h2: 1.5714285714285714em;
|
$h2: 1.5714285714285714em;
|
||||||
$h3: 1.2857142857142858em;
|
$h3: 1.2857142857142858em;
|
||||||
$h4: 1.1428571428571428em;
|
$h4: 1.1428571428571428em;
|
||||||
$h5: 0.929em;
|
$h5: 0.929em;
|
||||||
|
|
||||||
|
// spacings
|
||||||
|
$section-spacing: 40px;
|
||||||
|
|
||||||
// Side Bar
|
// Side Bar
|
||||||
// ---------------------------
|
// ---------------------------
|
||||||
$side-bar-width: 260px;
|
$side-bar-width: 260px;
|
||||||
$side-bar-bg-color: #FAFAFA;
|
$side-bar-bg-color: #fafafa;
|
||||||
$side-menu-item-color: #384248;
|
$side-menu-item-color: #384248;
|
||||||
$side-menu-even-bg-color: #F0F0F0;
|
$side-menu-even-bg-color: #f0f0f0;
|
||||||
$side-menu-active-bg-color: #f0f0f0;
|
$side-menu-active-bg-color: #f0f0f0;
|
||||||
$side-menu-item-hpadding: 20px;
|
$side-menu-item-hpadding: 20px;
|
||||||
$side-menu-item-vpadding: 5px;
|
$side-menu-item-vpadding: 5px;
|
||||||
|
@ -54,7 +58,7 @@ $samples-panel-width: 40%;
|
||||||
$sample-panel-headers-color: lighten($black, 50%);
|
$sample-panel-headers-color: lighten($black, 50%);
|
||||||
$sample-panel-color: lighten($black, 80%);
|
$sample-panel-color: lighten($black, 80%);
|
||||||
|
|
||||||
$tree-lines-color: rgba($primary-color, .5);
|
$tree-lines-color: rgba($primary-color, 0.5);
|
||||||
|
|
||||||
$side-menu-mobile-breakpoint: 1000px;
|
$side-menu-mobile-breakpoint: 1000px;
|
||||||
$right-panel-squash-breakpoint: 1100px;
|
$right-panel-squash-breakpoint: 1100px;
|
||||||
|
@ -62,3 +66,7 @@ $right-panel-squash-breakpoint: 1100px;
|
||||||
// Border Radius
|
// Border Radius
|
||||||
// ---------------------------
|
// ---------------------------
|
||||||
$border-radius: 2px;
|
$border-radius: 2px;
|
||||||
|
|
||||||
|
// texts
|
||||||
|
$array-text: 'Array of ';
|
||||||
|
$tuple-text: 'Tuple ';
|
||||||
|
|
|
@ -10,6 +10,7 @@ import { MdRenderer } from './md-renderer';
|
||||||
export class SpecManager {
|
export class SpecManager {
|
||||||
public _schema: any = {};
|
public _schema: any = {};
|
||||||
public apiUrl: string;
|
public apiUrl: string;
|
||||||
|
public basePath: string;
|
||||||
|
|
||||||
public spec = new BehaviorSubject<any|null>(null);
|
public spec = new BehaviorSubject<any|null>(null);
|
||||||
private _instance: any;
|
private _instance: any;
|
||||||
|
@ -65,8 +66,8 @@ export class SpecManager {
|
||||||
}
|
}
|
||||||
|
|
||||||
let host = this._schema.host || urlParts.host;
|
let host = this._schema.host || urlParts.host;
|
||||||
let basePath = this._schema.basePath || '/';
|
this.basePath = this._schema.basePath || '/';
|
||||||
this.apiUrl = protocol + '://' + host + basePath;
|
this.apiUrl = protocol + '://' + host + this.basePath;
|
||||||
if (this.apiUrl.endsWith('/')) {
|
if (this.apiUrl.endsWith('/')) {
|
||||||
this.apiUrl = this.apiUrl.substr(0, this.apiUrl.length - 1);
|
this.apiUrl = this.apiUrl.substr(0, this.apiUrl.length - 1);
|
||||||
}
|
}
|
||||||
|
|
10
package.json
10
package.json
|
@ -1,7 +1,7 @@
|
||||||
{
|
{
|
||||||
"name": "redoc",
|
"name": "redoc",
|
||||||
"description": "Swagger-generated API Reference Documentation",
|
"description": "Swagger-generated API Reference Documentation",
|
||||||
"version": "1.5.0",
|
"version": "1.5.1",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "git://github.com/Rebilly/ReDoc"
|
"url": "git://github.com/Rebilly/ReDoc"
|
||||||
|
@ -61,10 +61,9 @@
|
||||||
"branch-release": "^1.0.3",
|
"branch-release": "^1.0.3",
|
||||||
"chalk": "^1.1.3",
|
"chalk": "^1.1.3",
|
||||||
"codelyzer": "^1.0.0-beta.3",
|
"codelyzer": "^1.0.0-beta.3",
|
||||||
"copy-webpack-plugin": "^3.0.1",
|
|
||||||
"core-js": "^2.4.1",
|
"core-js": "^2.4.1",
|
||||||
"coveralls": "^2.11.9",
|
"coveralls": "^2.11.9",
|
||||||
"css-loader": "^0.24.0",
|
"css-loader": "^0.25.0",
|
||||||
"deploy-to-gh-pages": "^1.1.2",
|
"deploy-to-gh-pages": "^1.1.2",
|
||||||
"http-server": "^0.9.0",
|
"http-server": "^0.9.0",
|
||||||
"istanbul-instrumenter-loader": "^0.2.0",
|
"istanbul-instrumenter-loader": "^0.2.0",
|
||||||
|
@ -96,16 +95,15 @@
|
||||||
"style-loader": "^0.13.1",
|
"style-loader": "^0.13.1",
|
||||||
"ts-helpers": "^1.1.1",
|
"ts-helpers": "^1.1.1",
|
||||||
"tslint": "^3.15.1",
|
"tslint": "^3.15.1",
|
||||||
"tslint-stylish": "^2.1.0-beta",
|
|
||||||
"typescript": "^2.0.3",
|
"typescript": "^2.0.3",
|
||||||
"webpack": "^2.1.0-beta.25",
|
"webpack": "^2.1.0-beta.25",
|
||||||
"webpack-dev-server": "^2.1.0-beta.6",
|
"webpack-dev-server": "^2.1.0-beta.10",
|
||||||
"zone.js": "^0.6.25"
|
"zone.js": "^0.6.25"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"dropkickjs": "^2.1.10",
|
"dropkickjs": "^2.1.10",
|
||||||
"hint.css": "^2.3.2",
|
"hint.css": "^2.3.2",
|
||||||
"json-pointer": "^0.5.0",
|
"json-pointer": "^0.6.0",
|
||||||
"json-schema-ref-parser": "^3.1.2",
|
"json-schema-ref-parser": "^3.1.2",
|
||||||
"openapi-sampler": "^0.3.2",
|
"openapi-sampler": "^0.3.2",
|
||||||
"prismjs": "^1.5.1",
|
"prismjs": "^1.5.1",
|
||||||
|
|
|
@ -106,6 +106,7 @@ if (process.env.JOB === 'e2e-guru') {
|
||||||
delete apisGuruList['clarify.io']; // non-string references
|
delete apisGuruList['clarify.io']; // non-string references
|
||||||
//delete apisGuruList['pushpay.com']; // https://github.com/Rebilly/ReDoc/issues/30
|
//delete apisGuruList['pushpay.com']; // https://github.com/Rebilly/ReDoc/issues/30
|
||||||
delete apisGuruList['bbci.co.uk']; // too big
|
delete apisGuruList['bbci.co.uk']; // too big
|
||||||
|
delete apisGuruList['bbc.com']; // too big
|
||||||
|
|
||||||
// run quick version of e2e test on all builds except releases
|
// run quick version of e2e test on all builds except releases
|
||||||
if (process.env.TRAVIS && !process.env.TRAVIS_TAG) {
|
if (process.env.TRAVIS && !process.env.TRAVIS_TAG) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user