feat(rendering): gate rendering based on valid version identifiers (#4614)

* create VersionPragmaFilter component

* use VersionPragmaFilter in BaseLayout

* tighten version idenitifier constraints

* handle case where user specifies a valid `swagger` and `openapi` field

* add traceable class names for each message

* add tests

* linter fixes!

* UNRELATED CHANGE: remove travis short-circuit

* add bypass switch to VersionPragmaFilter
This commit is contained in:
kyle
2018-06-01 16:04:27 -07:00
committed by GitHub
parent a51bf1ea3e
commit a03c12786a
7 changed files with 161 additions and 13 deletions

View File

@@ -796,3 +796,30 @@ a.nostyle {
cursor: pointer;
}
}
.version-pragma {
height: 100%;
padding: 5em 0px;
&__message {
display: flex;
justify-content: center;
height: 100%;
font-size: 1.2em;
text-align: center;
line-height: 1.5em;
padding: 0px .6em;
> div {
max-width: 55ch;
flex: 1;
}
code {
background-color: #dedede;
padding: 4px 4px 2px;
white-space: pre;
}
}
}