@gomusdev/web-components 4.6.0 → 4.6.1

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/README.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # Changelog
2
2
 
3
+ ## 4.6.1 (2026-07-14)
4
+
5
+ ### Bug Fixes
6
+
7
+ * **go-order:** clear cart and guest session on token change, closes [gomus/frontend#142](https://gitlab.giantmonkey.de/gomus/frontend/issues/142)
8
+
3
9
  ## 4.6.0 (2026-07-14)
4
10
 
5
11
  ### Features
@@ -36151,9 +36151,12 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
36151
36151
  let token = prop($$props, "token", 7);
36152
36152
  const orderDetails = new OrderDetails(token());
36153
36153
  setDetails($$props.$$host, orderDetails);
36154
- onMount(() => {
36155
- shop.cart.clearItems();
36156
- if (shop.auth.isGuest()) shop.auth.signOut();
36154
+ user_effect(() => {
36155
+ orderDetails.token = token();
36156
+ untrack(() => {
36157
+ shop.cart.clearItems();
36158
+ if (shop.auth.isGuest()) shop.auth.signOut();
36159
+ });
36157
36160
  });
36158
36161
  return pop({
36159
36162
  orderDetails,
@@ -36150,9 +36150,12 @@ function Order($$anchor, $$props) {
36150
36150
  let token = prop($$props, "token", 7);
36151
36151
  const orderDetails = new OrderDetails(token());
36152
36152
  setDetails($$props.$$host, orderDetails);
36153
- onMount(() => {
36154
- shop.cart.clearItems();
36155
- if (shop.auth.isGuest()) shop.auth.signOut();
36153
+ user_effect(() => {
36154
+ orderDetails.token = token();
36155
+ untrack(() => {
36156
+ shop.cart.clearItems();
36157
+ if (shop.auth.isGuest()) shop.auth.signOut();
36158
+ });
36156
36159
  });
36157
36160
  return pop({
36158
36161
  orderDetails,