@vtex/faststore-plugin-buyer-portal 2.0.4 → 2.0.5
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/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [2.0.5] - 2026-06-17
|
|
11
|
+
|
|
12
|
+
### Fixed
|
|
13
|
+
|
|
14
|
+
- Use useRouter insted of window.location on OrderEntry handshake
|
|
15
|
+
|
|
10
16
|
## [2.0.4] - 2026-06-17
|
|
11
17
|
|
|
12
18
|
### Added
|
|
@@ -696,7 +702,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
696
702
|
- Add CHANGELOG file
|
|
697
703
|
- Add README file
|
|
698
704
|
|
|
699
|
-
[unreleased]: https://github.com/vtex/faststore-plugin-buyer-portal/compare/v2.0.
|
|
705
|
+
[unreleased]: https://github.com/vtex/faststore-plugin-buyer-portal/compare/v2.0.5...HEAD
|
|
700
706
|
[1.3.55]: https://github.com/vtex/faststore-plugin-buyer-portal/compare/v1.3.54...v1.3.55
|
|
701
707
|
[1.3.54]: https://github.com/vtex/faststore-plugin-buyer-portal/compare/v1.3.53...v1.3.54
|
|
702
708
|
[1.3.53]: https://github.com/vtex/faststore-plugin-buyer-portal/compare/v1.3.52...v1.3.53
|
|
@@ -782,6 +788,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
782
788
|
[1.3.85]: https://github.com/vtex/faststore-plugin-buyer-portal/releases/tag/1.3.85
|
|
783
789
|
[1.3.87]: https://github.com/vtex/faststore-plugin-buyer-portal/compare/v1.3.86...v1.3.87
|
|
784
790
|
[1.3.86]: https://github.com/vtex/faststore-plugin-buyer-portal/releases/tag/1.3.86
|
|
791
|
+
[2.0.5]: https://github.com/vtex/faststore-plugin-buyer-portal/compare/v2.0.4...v2.0.5
|
|
785
792
|
[2.0.4]: https://github.com/vtex/faststore-plugin-buyer-portal/compare/v2.0.3...v2.0.4
|
|
786
793
|
[2.0.3]: https://github.com/vtex/faststore-plugin-buyer-portal/compare/v2.0.2...v2.0.3
|
|
787
794
|
[2.0.2]: https://github.com/vtex/faststore-plugin-buyer-portal/compare/v2.0.1...v2.0.2
|
package/package.json
CHANGED
|
@@ -2,6 +2,8 @@ import { useEffect, useMemo, useRef } from "react";
|
|
|
2
2
|
|
|
3
3
|
import storeConfig from "discovery.config";
|
|
4
4
|
|
|
5
|
+
import { useRouter } from "next/router";
|
|
6
|
+
|
|
5
7
|
import { isDevelopment } from "../../shared/utils/environment";
|
|
6
8
|
|
|
7
9
|
const B2B_AGENT_URL = isDevelopment()
|
|
@@ -45,12 +47,15 @@ export const OrderEntryLayout = ({
|
|
|
45
47
|
userId,
|
|
46
48
|
}: OrderEntryLayoutProps) => {
|
|
47
49
|
const iframeRef = useRef<HTMLIFrameElement>(null);
|
|
50
|
+
const router = useRouter();
|
|
48
51
|
|
|
49
52
|
const agentOrigin = useMemo(() => new URL(B2B_AGENT_URL).origin, []);
|
|
50
53
|
|
|
51
54
|
useEffect(() => {
|
|
52
55
|
function postAuthToIframe() {
|
|
53
56
|
const targetWindow = iframeRef.current?.contentWindow;
|
|
57
|
+
const quoteId = router.query.quoteId ?? "";
|
|
58
|
+
|
|
54
59
|
if (!targetWindow) return;
|
|
55
60
|
|
|
56
61
|
// We send only the token (not the full Cookie header) to reduce exposure.
|
|
@@ -65,6 +70,7 @@ export const OrderEntryLayout = ({
|
|
|
65
70
|
locale,
|
|
66
71
|
customerId,
|
|
67
72
|
userId,
|
|
73
|
+
quoteId,
|
|
68
74
|
},
|
|
69
75
|
agentOrigin
|
|
70
76
|
);
|