diff --git a/docs/examples/redoc-dark.html b/docs/examples/redoc-dark.html index 4f079b2..7948626 100644 --- a/docs/examples/redoc-dark.html +++ b/docs/examples/redoc-dark.html @@ -202,7 +202,7 @@ placeHolder: 'Search endpoints', data: { src: this.filterEndpoints(openapi), - keys: ['method', 'path', 'summary'], + keys: ['searchKey'], }, searchEngine: 'loose', threshold: 0, @@ -265,14 +265,16 @@ if (method === 'parameters') { continue } + const summary = paths[path][method].summary || '' endpoints.push({ + searchKey: `${method} ${path} ${summary}`, method: method.toUpperCase(), path, operationId: paths[path][method].operationId, tag: paths[path][method].tags ? paths[path][method].tags[0] : 'default', - summary: paths[path][method].summary || '', + summary, }) } } diff --git a/docs/examples/redoc-light.html b/docs/examples/redoc-light.html index 4686521..c8ae307 100644 --- a/docs/examples/redoc-light.html +++ b/docs/examples/redoc-light.html @@ -202,7 +202,7 @@ placeHolder: 'Search endpoints', data: { src: this.filterEndpoints(openapi), - keys: ['method', 'path', 'summary'], + keys: ['searchKey'], }, searchEngine: 'loose', threshold: 0, @@ -265,14 +265,16 @@ if (method === 'parameters') { continue } + const summary = paths[path][method].summary || '' endpoints.push({ + searchKey: `${method} ${path} ${summary}`, method: method.toUpperCase(), path, operationId: paths[path][method].operationId, tag: paths[path][method].tags ? paths[path][method].tags[0] : 'default', - summary: paths[path][method].summary || '', + summary, }) } } diff --git a/docs/examples/stoplight-dark.html b/docs/examples/stoplight-dark.html index eea3d3e..20312cb 100644 --- a/docs/examples/stoplight-dark.html +++ b/docs/examples/stoplight-dark.html @@ -203,7 +203,7 @@ placeHolder: 'Search endpoints', data: { src: this.filterEndpoints(openapi), - keys: ['method', 'path', 'summary'], + keys: ['searchKey'], }, searchEngine: 'loose', threshold: 0, @@ -266,14 +266,16 @@ if (method === 'parameters') { continue } + const summary = paths[path][method].summary || '' endpoints.push({ + searchKey: `${method} ${path} ${summary}`, method: method.toUpperCase(), path, operationId: paths[path][method].operationId, tag: paths[path][method].tags ? paths[path][method].tags[0] : 'default', - summary: paths[path][method].summary || '', + summary, }) } } diff --git a/docs/examples/stoplight-light.html b/docs/examples/stoplight-light.html index 05b7fa6..732c4f3 100644 --- a/docs/examples/stoplight-light.html +++ b/docs/examples/stoplight-light.html @@ -203,7 +203,7 @@ placeHolder: 'Search endpoints', data: { src: this.filterEndpoints(openapi), - keys: ['method', 'path', 'summary'], + keys: ['searchKey'], }, searchEngine: 'loose', threshold: 0, @@ -266,14 +266,16 @@ if (method === 'parameters') { continue } + const summary = paths[path][method].summary || '' endpoints.push({ + searchKey: `${method} ${path} ${summary}`, method: method.toUpperCase(), path, operationId: paths[path][method].operationId, tag: paths[path][method].tags ? paths[path][method].tags[0] : 'default', - summary: paths[path][method].summary || '', + summary, }) } } diff --git a/docs/examples/swagger-dark.html b/docs/examples/swagger-dark.html index 8202f4d..5ea8e7c 100644 --- a/docs/examples/swagger-dark.html +++ b/docs/examples/swagger-dark.html @@ -201,7 +201,7 @@ placeHolder: 'Search endpoints', data: { src: this.filterEndpoints(openapi), - keys: ['method', 'path', 'summary'], + keys: ['searchKey'], }, searchEngine: 'loose', threshold: 0, @@ -264,14 +264,16 @@ if (method === 'parameters') { continue } + const summary = paths[path][method].summary || '' endpoints.push({ + searchKey: `${method} ${path} ${summary}`, method: method.toUpperCase(), path, operationId: paths[path][method].operationId, tag: paths[path][method].tags ? paths[path][method].tags[0] : 'default', - summary: paths[path][method].summary || '', + summary, }) } } diff --git a/docs/examples/swagger-light.html b/docs/examples/swagger-light.html index 1df1cab..a7210cc 100644 --- a/docs/examples/swagger-light.html +++ b/docs/examples/swagger-light.html @@ -201,7 +201,7 @@ placeHolder: 'Search endpoints', data: { src: this.filterEndpoints(openapi), - keys: ['method', 'path', 'summary'], + keys: ['searchKey'], }, searchEngine: 'loose', threshold: 0, @@ -264,14 +264,16 @@ if (method === 'parameters') { continue } + const summary = paths[path][method].summary || '' endpoints.push({ + searchKey: `${method} ${path} ${summary}`, method: method.toUpperCase(), path, operationId: paths[path][method].operationId, tag: paths[path][method].tags ? paths[path][method].tags[0] : 'default', - summary: paths[path][method].summary || '', + summary, }) } } diff --git a/package-lock.json b/package-lock.json index 0884f77..e1f943c 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "openapi-generate-html", - "version": "0.5.0", + "version": "0.5.1", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "openapi-generate-html", - "version": "0.5.0", + "version": "0.5.1", "license": "MIT", "dependencies": { "@apidevtools/json-schema-ref-parser": "^14.1.0", diff --git a/package.json b/package.json index 50231e8..a4944c2 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "openapi-generate-html", - "version": "0.5.0", + "version": "0.5.1", "description": "Generate standalone HTML from OpenAPI Specification", "type": "module", "bin": { diff --git a/resources/common/index.js b/resources/common/index.js index 93672ed..c0e8e15 100644 --- a/resources/common/index.js +++ b/resources/common/index.js @@ -14,7 +14,7 @@ class SearchDialog { placeHolder: 'Search endpoints', data: { src: this.filterEndpoints(openapi), - keys: ['method', 'path', 'summary'], + keys: ['searchKey'], }, searchEngine: 'loose', threshold: 0, @@ -77,14 +77,16 @@ class SearchDialog { if (method === 'parameters') { continue } + const summary = paths[path][method].summary || '' endpoints.push({ + searchKey: `${method} ${path} ${summary}`, method: method.toUpperCase(), path, operationId: paths[path][method].operationId, tag: paths[path][method].tags ? paths[path][method].tags[0] : 'default', - summary: paths[path][method].summary || '', + summary, }) } }