Repository navigation
rapidoc@15.0.0
Major Changes
- aa3c878: The sidebar has a new look with three levels: upper-case section labels (Overview, tag groups, Components, or the tags themselves when there are no tag groups), rows with icons for the API title, servers and authentication, and compact operation rows under a guide line with the method first. The current item is a filled block. A tag's name opens a closed tag as well as going to its section.
nav-item-spacingis removed (set--sidebar-item-paddinginstead), tag groups no longer collapse, andshow-method-in-nav-barnow defaults toas-colored-text. See the v14 to v15 migration guide. RapiDoc Portal's docs sidebar takes the same three levels: a tab's top-level groups are section labels, their items rows with icons, deeper items compact rows under a guide line.
Patch Changes
-
aa3c878:
rapidoc/flow(<rapi-flow>) is 41 KB smaller (283 KB to 242 KB minified, 89 KB to 76 KB gzipped): Arazzo documents are now read withjs-yaml, half the size ofyaml. Values are read the same way (YAML 1.2, merge keys, no dates); a tag the reader does not know keeps its plain value, and stray control characters are dropped.@rapidoc/mcpdepends onjs-yamlin place ofyaml, and@rapidoc/prerenderon both. OpenAPI specs are read as before. Inrapidoc-min.js, the syntax highlighter no longer carries grammars for Astro, Svelte, Vue, Objective-C, Perl, R and TOML. The first three are drawn as HTML and Objective-C as C; Perl, R and TOML code shows as plain text. -
aa3c878: MCP servers read their settings from
MCP_variables only, the same in an exported server,rapidoc mcp serveand the/mcpendpoint ofrapidoc serve: a security scheme's credential isMCP_AUTH_<SCHEME>(MCP_AUTH_<SCHEME>_USERNAMEandMCP_AUTH_<SCHEME>_PASSWORDfor HTTP Basic), the base URL isMCP_BASE_URL(MCP_BASE_URL_<SOURCE>each when a server has several APIs) and the host allow-list isMCP_EXTERNAL_HOSTS. The old names (<SCHEME>,API_KEY,API_BASE_URL,EXTERNAL_HOSTS) are no longer read, so a scheme calledtokenorpathcan no longer send$TOKENor$PATHto an API, and two schemes that would share a variable stop the export with a message. Tool names are now always valid and stable: at most 64 characters, never empty for a non-LatinoperationId, and a name two operations share ends in a short hash of the operation instead of_2, so reordering the spec renames nothing. Every operation is a tool with all its parameters; aGETbecomes an MCP resource as well only withx-mcp-resource: true, no longer because of its path. Swagger 2.0 specs get HTTP Basic fortype: basicand a form body forformDataparameters. A spec with a relative server URL or none is resolved against the address it was loaded from; read from a file, the manifest has no base URL,rapidoc mcp exportandrapidoc mcp servesay that one is required, and a tool call without one fails with that message instead of callinghttp://localhost. The runtime refuses a manifest version it does not know,<rapi-doc>'smcpattribute shows the export button fortrueonly, and@rapidoc/mcpno longer exportsparseMcpEnabled. -
f0c81ab: The navigation bar's filter area has its frosted-glass background again in Chrome and Edge: the minified bundle had kept only the
-webkit-prefixedbackdrop-filter. In the navigation bar, colored method badges have 2px corners and operation names are 1px smaller. Theambertheme's light scheme has a deeper copper accent,#ab6534, with white text on it (was#ff791awith black text). -
aa3c878:
<rapi-doc>15 clean-up. Removed: thescrollTo(elementId)method (usescrollToPath;scrollTois the browser's own method again),mock-server-status-strategy(write the strategy in front of the codes:mock-server-status-code="random:200, 500"),theme="light"andtheme="dark"(usecolor-scheme),default-schema-tab="model"(useschema),mcp="none"(usefalse), the hidden "Operations" sidebar row with its partsection-navbar-operations-top, andloading,focusedElementId,searchValandadvancedSearchMatchesas attributes.nav-active-changehas one detail from every source,{ elementId, type, operationId? }:idis gone,typeisoperation,tagorsection, andoperationIdis the spec's own operationId.persist-authsaves keys per API (by spec URL, else title), so two APIs on one site no longer share a token; keys saved by v14 are not carried over, and saved keys are applied once per spec load, so a key set withsetApiKeyonspec-loadedstays. Relative server URLs (api/v1,../v2,/v1) resolve against the spec's address. Fixed: the mock stays on after the element is moved in the page; OAuth with a scheme name that has a dot or starts with a digit; the Authentication section with a server URL such as//hostor{scheme}://host;css-filecopied once instead of on every render; the header's local file button reads YAML and reports a file it cannot read. The sidebar follows right-to-left pages, strikes deprecated operations through, and appliesnav-item-overflowto description headings. The API reference, types and schema no longer list removed attributes; the docs have a "Removed attributes" page instead.@rapidoc/starlightand@rapidoc/docusaurusreaddetail.elementIdonly.The sidebar is usable with a keyboard and a screen reader: every item is a real link (so it is announced as one, opens in a new tab with a middle click, and shows its address), a tag's arrow is a separate button that answers Enter and Space, the current item is marked with
aria-current, and the menu button of narrow layouts says whether the menu is open and Escape closes it. The look, class names and CSS parts are unchanged. -
aa3c878: Security fixes.
@rapidoc/server: the sign-in cookie, which/_rapidoc/auth/logingives any visitor, was accepted as a session, opening pages for all signed-in readers without signing in (pages limited to groups or emails were not affected); every sealed cookie and token now has one use. The server also refuses a build whoseprotected/folder has norapidoc-server.json, needs a public URL (site.urlorRAPIDOC_PUBLIC_URL) to sign readers in anywhere butlocalhost, limits request bodies, and sendsframe-ancestors(RAPIDOC_FRAME_ANCESTORS), referrer and HSTS headers.rapidocand@rapidoc/prerender: HTML in descriptions is reduced to a fixed list of elements and attributes, in every browser and in pre-rendered pages, where it was not sanitized at all;javascript:addresses from a spec are no longer links; a spec value can no longer pass for a template in the prerenderer.rapidoc buildrefuses an output folder that is, holds or is inside a source folder (--out-dir publicemptiedpublic/).rapidoc mockandrapidoc devlisten onlocalhostby default (--host 0.0.0.0for a container or a shared server;devhas--hostnow), and the mock takes an imported spec only from a program on its machine or its own page, never from another site's page or through a proxy, and does not let it read other local files.