openapi-explorer 2.4.786 → 2.4.791
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -132,8 +132,11 @@ export function replaceState(rawElementId) {
|
|
|
132
132
|
query.delete('route');
|
|
133
133
|
const newQuery = query.toString().length > 1 ? `${query.toString()}&route=${elementId}` : `route=${elementId}`;
|
|
134
134
|
const fragment = `#${currentNavigationHashPart}?${newQuery}`;
|
|
135
|
-
const
|
|
136
|
-
|
|
135
|
+
const currentHref = window.location.href;
|
|
136
|
+
const url = new URL(fragment, currentHref);
|
|
137
|
+
if (url.href !== currentHref) {
|
|
138
|
+
window.history.pushState(null, null, url.href);
|
|
139
|
+
}
|
|
137
140
|
}
|
|
138
141
|
export function toMarkdown(markdownStringRaw) {
|
|
139
142
|
const sanitizedMarkdownString = (markdownStringRaw || ''
|
|
@@ -147,8 +147,11 @@ function replaceState(rawElementId) {
|
|
|
147
147
|
query.delete('route');
|
|
148
148
|
const newQuery = query.toString().length > 1 ? `${query.toString()}&route=${elementId}` : `route=${elementId}`;
|
|
149
149
|
const fragment = `#${currentNavigationHashPart}?${newQuery}`;
|
|
150
|
-
const
|
|
151
|
-
|
|
150
|
+
const currentHref = window.location.href;
|
|
151
|
+
const url = new URL(fragment, currentHref);
|
|
152
|
+
if (url.href !== currentHref) {
|
|
153
|
+
window.history.pushState(null, null, url.href);
|
|
154
|
+
}
|
|
152
155
|
}
|
|
153
156
|
function toMarkdown(markdownStringRaw) {
|
|
154
157
|
const sanitizedMarkdownString = (markdownStringRaw || ''
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "openapi-explorer",
|
|
3
|
-
"version": "2.4.
|
|
3
|
+
"version": "2.4.791",
|
|
4
4
|
"description": "OpenAPI Explorer - API viewer with dynamically generated components, documentation, and interaction console",
|
|
5
5
|
"author": "Authress Developers <developers@authress.io>",
|
|
6
6
|
"type": "module",
|