Skip to content

Commit 6040e7a

Browse files
authored
fix: add the missing path-only option to sideNavStyle (#1844)
* fix: add the missing path-only option to sideNavStyle * update snapshots * add changeset
1 parent a83c292 commit 6040e7a

File tree

8 files changed

+43
-31
lines changed

8 files changed

+43
-31
lines changed

.changeset/brave-hotels-deny.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
"@redocly/openapi-core": patch
3+
"@redocly/cli": patch
4+
---
5+
6+
Updated the `sideNavStyle` configuration schema to include the `path-only` option.

.changeset/light-walls-sleep.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@redocly/openapi-core": patch
3+
---
4+
5+
Updated @redocly/config to v0.20.1.

__tests__/lint-config/config-structure/.redocly.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ responseHeaders:
6262
# name: Must be reported as a missing required prop
6363
value: 123 # Must be a string
6464

65-
ssoOnPrem:
65+
ssoDirect:
6666
oidc:
6767
title: 456 # Must be a string
6868
type: OIDC

__tests__/lint-config/config-structure/snapshot.js

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ The field \`name\` must be present on this level.
185185
63 | value: 123 # Must be a string
186186
| ^^^^^^^^^^
187187
64 |
188-
65 | ssoOnPrem:
188+
65 | ssoDirect:
189189
190190
Error was generated by the configuration spec rule.
191191
@@ -213,7 +213,7 @@ Expected type \`string\` but got \`integer\`.
213213
63 | value: 123 # Must be a string
214214
| ^^^
215215
64 |
216-
65 | ssoOnPrem:
216+
65 | ssoDirect:
217217
218218
Error was generated by the configuration spec rule.
219219
@@ -290,11 +290,11 @@ Expected type \`rootRedoclyConfigSchema.apis_additionalProperties.openapi\` (obj
290290
Error was generated by the configuration spec rule.
291291
292292
293-
[21] .redocly.yaml:67:12 at #/ssoOnPrem/oidc/title
293+
[21] .redocly.yaml:67:12 at #/ssoDirect/oidc/title
294294
295295
Expected type \`string\` but got \`integer\`.
296296
297-
65 | ssoOnPrem:
297+
65 | ssoDirect:
298298
66 | oidc:
299299
67 | title: 456 # Must be a string
300300
| ^^^
@@ -304,7 +304,7 @@ Expected type \`string\` but got \`integer\`.
304304
Error was generated by the configuration spec rule.
305305
306306
307-
[22] .redocly.yaml:85:9 at #/ssoOnPrem/oidc/defaultTeams/0
307+
[22] .redocly.yaml:85:9 at #/ssoDirect/oidc/defaultTeams/0
308308
309309
Expected type \`string\` but got \`integer\`.
310310
@@ -318,7 +318,7 @@ Expected type \`string\` but got \`integer\`.
318318
Error was generated by the configuration spec rule.
319319
320320
321-
[23] .redocly.yaml:80:5 at #/ssoOnPrem/oidc/configuration
321+
[23] .redocly.yaml:80:5 at #/ssoDirect/oidc/configuration
322322
323323
The field \`authorization_endpoint\` must be present on this level.
324324
@@ -332,7 +332,7 @@ The field \`authorization_endpoint\` must be present on this level.
332332
Error was generated by the configuration spec rule.
333333
334334
335-
[24] .redocly.yaml:81:23 at #/ssoOnPrem/oidc/configuration/token_endpoint
335+
[24] .redocly.yaml:81:23 at #/ssoDirect/oidc/configuration/token_endpoint
336336
337337
Expected type \`string\` but got \`integer\`.
338338
@@ -346,7 +346,7 @@ Expected type \`string\` but got \`integer\`.
346346
Error was generated by the configuration spec rule.
347347
348348
349-
[25] .redocly.yaml:78:19 at #/ssoOnPrem/oidc/authorizationRequestCustomParams/login_hint
349+
[25] .redocly.yaml:78:19 at #/ssoDirect/oidc/authorizationRequestCustomParams/login_hint
350350
351351
Expected type \`string\` but got \`integer\`.
352352
@@ -360,7 +360,7 @@ Expected type \`string\` but got \`integer\`.
360360
Error was generated by the configuration spec rule.
361361
362362
363-
[26] .redocly.yaml:87:3 at #/ssoOnPrem/sso-config-schema-without-configurationUrl
363+
[26] .redocly.yaml:87:3 at #/ssoDirect/sso-config-schema-without-configurationUrl
364364
365365
The field \`clientId\` must be present on this level.
366366
@@ -374,7 +374,7 @@ The field \`clientId\` must be present on this level.
374374
Error was generated by the configuration spec rule.
375375
376376
377-
[27] .redocly.yaml:87:3 at #/ssoOnPrem/sso-config-schema-without-configurationUrl
377+
[27] .redocly.yaml:87:3 at #/ssoDirect/sso-config-schema-without-configurationUrl
378378
379379
The field \`configurationUrl\` must be present on this level.
380380

package-lock.json

Lines changed: 9 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/core/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
],
3737
"dependencies": {
3838
"@redocly/ajv": "^8.11.2",
39-
"@redocly/config": "^0.17.0",
39+
"@redocly/config": "^0.20.1",
4040
"colorette": "^1.2.0",
4141
"https-proxy-agent": "^7.0.4",
4242
"js-levenshtein": "^1.1.6",

packages/core/src/__tests__/lint.test.ts

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ const testPortalConfig = parseYamlToDocument(
7676
# name: Must be reported as a missing required prop
7777
value: 123 # Must be a string
7878
79-
ssoOnPrem:
79+
ssoDirect:
8080
oidc:
8181
title: 456 # Must be a string
8282
type: OIDC
@@ -791,7 +791,7 @@ describe('lint', () => {
791791
"from": undefined,
792792
"location": [
793793
{
794-
"pointer": "#/ssoOnPrem/oidc/title",
794+
"pointer": "#/ssoDirect/oidc/title",
795795
"reportOnKey": false,
796796
"source": "",
797797
},
@@ -805,7 +805,7 @@ describe('lint', () => {
805805
"from": undefined,
806806
"location": [
807807
{
808-
"pointer": "#/ssoOnPrem/oidc/defaultTeams/0",
808+
"pointer": "#/ssoDirect/oidc/defaultTeams/0",
809809
"reportOnKey": false,
810810
"source": "",
811811
},
@@ -819,7 +819,7 @@ describe('lint', () => {
819819
"from": undefined,
820820
"location": [
821821
{
822-
"pointer": "#/ssoOnPrem/oidc/configuration",
822+
"pointer": "#/ssoDirect/oidc/configuration",
823823
"reportOnKey": true,
824824
"source": "",
825825
},
@@ -833,7 +833,7 @@ describe('lint', () => {
833833
"from": undefined,
834834
"location": [
835835
{
836-
"pointer": "#/ssoOnPrem/oidc/configuration/token_endpoint",
836+
"pointer": "#/ssoDirect/oidc/configuration/token_endpoint",
837837
"reportOnKey": false,
838838
"source": "",
839839
},
@@ -847,7 +847,7 @@ describe('lint', () => {
847847
"from": undefined,
848848
"location": [
849849
{
850-
"pointer": "#/ssoOnPrem/oidc/authorizationRequestCustomParams/login_hint",
850+
"pointer": "#/ssoDirect/oidc/authorizationRequestCustomParams/login_hint",
851851
"reportOnKey": false,
852852
"source": "",
853853
},
@@ -861,7 +861,7 @@ describe('lint', () => {
861861
"from": undefined,
862862
"location": [
863863
{
864-
"pointer": "#/ssoOnPrem/sso-config-schema-without-configurationUrl",
864+
"pointer": "#/ssoDirect/sso-config-schema-without-configurationUrl",
865865
"reportOnKey": true,
866866
"source": "",
867867
},
@@ -875,7 +875,7 @@ describe('lint', () => {
875875
"from": undefined,
876876
"location": [
877877
{
878-
"pointer": "#/ssoOnPrem/sso-config-schema-without-configurationUrl",
878+
"pointer": "#/ssoDirect/sso-config-schema-without-configurationUrl",
879879
"reportOnKey": true,
880880
"source": "",
881881
},
@@ -1205,12 +1205,12 @@ describe('lint', () => {
12051205
"from": undefined,
12061206
"location": [
12071207
{
1208-
"pointer": "#/ssoOnPrem",
1208+
"pointer": "#/ssoDirect",
12091209
"reportOnKey": true,
12101210
"source": "",
12111211
},
12121212
],
1213-
"message": "Property \`ssoOnPrem\` is not expected here.",
1213+
"message": "Property \`ssoDirect\` is not expected here.",
12141214
"ruleId": "configuration spec",
12151215
"severity": "error",
12161216
"suggest": [],

packages/core/src/types/redocly-yaml.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1093,7 +1093,7 @@ const ConfigReferenceDocs: NodeType = {
10931093
showObjectSchemaExamples: { type: 'boolean' },
10941094
disableTryItRequestUrlEncoding: { type: 'boolean' },
10951095
sidebarLinks: 'ConfigSidebarLinks',
1096-
sideNavStyle: { enum: ['summary-only', 'path-first', 'id-only'] },
1096+
sideNavStyle: { enum: ['summary-only', 'path-first', 'id-only', 'path-only'] },
10971097
simpleOneOfTypeLabel: { type: 'boolean' },
10981098
sortEnumValuesAlphabetically: { type: 'boolean' },
10991099
sortOperationsAlphabetically: { type: 'boolean' },

0 commit comments

Comments
 (0)