@nubase/frontend 0.1.32 → 0.1.33
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.
- package/dist/index.js +7 -5
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +7 -5
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -15629,19 +15629,21 @@ var NavigationHistoryTracker = class {
|
|
|
15629
15629
|
this.addEntry(location);
|
|
15630
15630
|
}
|
|
15631
15631
|
addEntry(location) {
|
|
15632
|
-
const
|
|
15632
|
+
const searchString = typeof location.search === "string" ? location.search : location.searchStr || "";
|
|
15633
|
+
const searchParams = this.parseSearchParams(searchString);
|
|
15633
15634
|
const title = this.formatTitle(location.pathname, searchParams);
|
|
15634
|
-
const
|
|
15635
|
+
const hash = location.hash || "";
|
|
15636
|
+
const entryId = `${location.pathname}${searchString}${hash}`;
|
|
15635
15637
|
if (this.lastEntryId === entryId) {
|
|
15636
15638
|
return;
|
|
15637
15639
|
}
|
|
15638
15640
|
const entry = {
|
|
15639
15641
|
id: `history-${this.historyIdCounter++}`,
|
|
15640
|
-
path: `${location.pathname}${
|
|
15642
|
+
path: `${location.pathname}${searchString}${hash}`,
|
|
15641
15643
|
pathname: location.pathname,
|
|
15642
|
-
search:
|
|
15644
|
+
search: searchString,
|
|
15643
15645
|
searchParams,
|
|
15644
|
-
hash
|
|
15646
|
+
hash,
|
|
15645
15647
|
timestamp: Date.now(),
|
|
15646
15648
|
title
|
|
15647
15649
|
};
|