@graphcommerce/magento-product-bundle 8.1.0-canary.9 → 9.0.0-canary.101
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 +197 -18
- package/components/BundleProductCartItemOptions/BundleProductCartItemOptions.tsx +21 -20
- package/components/BundleProductOptions/BundleOption.tsx +2 -6
- package/components/BundleProductOptions/BundleOptionValue.tsx +2 -7
- package/components/BundleProductOptions/types.ts +2 -1
- package/package.json +14 -14
- package/plugins/BundleCartItemActionCard.tsx +6 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,189 @@
|
|
|
1
1
|
# Change Log
|
|
2
2
|
|
|
3
|
+
## 9.0.0-canary.101
|
|
4
|
+
|
|
5
|
+
## 9.0.0-canary.100
|
|
6
|
+
|
|
7
|
+
## 9.0.0-canary.99
|
|
8
|
+
|
|
9
|
+
## 9.0.0-canary.98
|
|
10
|
+
|
|
11
|
+
## 9.0.0-canary.97
|
|
12
|
+
|
|
13
|
+
## 9.0.0-canary.96
|
|
14
|
+
|
|
15
|
+
## 9.0.0-canary.95
|
|
16
|
+
|
|
17
|
+
## 9.0.0-canary.94
|
|
18
|
+
|
|
19
|
+
## 9.0.0-canary.93
|
|
20
|
+
|
|
21
|
+
## 9.0.0-canary.92
|
|
22
|
+
|
|
23
|
+
## 9.0.0-canary.91
|
|
24
|
+
|
|
25
|
+
## 9.0.0-canary.90
|
|
26
|
+
|
|
27
|
+
## 9.0.0-canary.89
|
|
28
|
+
|
|
29
|
+
## 9.0.0-canary.88
|
|
30
|
+
|
|
31
|
+
## 9.0.0-canary.87
|
|
32
|
+
|
|
33
|
+
## 9.0.0-canary.86
|
|
34
|
+
|
|
35
|
+
## 9.0.0-canary.85
|
|
36
|
+
|
|
37
|
+
## 9.0.0-canary.84
|
|
38
|
+
|
|
39
|
+
## 9.0.0-canary.83
|
|
40
|
+
|
|
41
|
+
## 9.0.0-canary.82
|
|
42
|
+
|
|
43
|
+
## 9.0.0-canary.81
|
|
44
|
+
|
|
45
|
+
## 9.0.0-canary.80
|
|
46
|
+
|
|
47
|
+
## 9.0.0-canary.79
|
|
48
|
+
|
|
49
|
+
## 9.0.0-canary.78
|
|
50
|
+
|
|
51
|
+
## 9.0.0-canary.77
|
|
52
|
+
|
|
53
|
+
## 9.0.0-canary.76
|
|
54
|
+
|
|
55
|
+
## 9.0.0-canary.75
|
|
56
|
+
|
|
57
|
+
## 9.0.0-canary.74
|
|
58
|
+
|
|
59
|
+
## 9.0.0-canary.73
|
|
60
|
+
|
|
61
|
+
## 9.0.0-canary.72
|
|
62
|
+
|
|
63
|
+
## 9.0.0-canary.71
|
|
64
|
+
|
|
65
|
+
## 9.0.0-canary.70
|
|
66
|
+
|
|
67
|
+
## 9.0.0-canary.69
|
|
68
|
+
|
|
69
|
+
## 9.0.0-canary.68
|
|
70
|
+
|
|
71
|
+
## 9.0.0-canary.67
|
|
72
|
+
|
|
73
|
+
## 9.0.0-canary.66
|
|
74
|
+
|
|
75
|
+
## 9.0.0-canary.65
|
|
76
|
+
|
|
77
|
+
## 9.0.0-canary.64
|
|
78
|
+
|
|
79
|
+
## 9.0.0-canary.63
|
|
80
|
+
|
|
81
|
+
## 9.0.0-canary.62
|
|
82
|
+
|
|
83
|
+
## 9.0.0-canary.61
|
|
84
|
+
|
|
85
|
+
## 9.0.0-canary.60
|
|
86
|
+
|
|
87
|
+
## 9.0.0-canary.59
|
|
88
|
+
|
|
89
|
+
## 9.0.0-canary.58
|
|
90
|
+
|
|
91
|
+
## 9.0.0-canary.57
|
|
92
|
+
|
|
93
|
+
## 9.0.0-canary.56
|
|
94
|
+
|
|
95
|
+
## 9.0.0-canary.55
|
|
96
|
+
|
|
97
|
+
## 9.0.0-canary.54
|
|
98
|
+
|
|
99
|
+
## 8.1.0-canary.53
|
|
100
|
+
|
|
101
|
+
## 8.1.0-canary.52
|
|
102
|
+
|
|
103
|
+
## 8.1.0-canary.51
|
|
104
|
+
|
|
105
|
+
## 8.1.0-canary.50
|
|
106
|
+
|
|
107
|
+
## 8.1.0-canary.49
|
|
108
|
+
|
|
109
|
+
## 8.1.0-canary.48
|
|
110
|
+
|
|
111
|
+
## 8.1.0-canary.47
|
|
112
|
+
|
|
113
|
+
## 8.1.0-canary.46
|
|
114
|
+
|
|
115
|
+
## 8.1.0-canary.45
|
|
116
|
+
|
|
117
|
+
## 8.1.0-canary.44
|
|
118
|
+
|
|
119
|
+
## 8.1.0-canary.43
|
|
120
|
+
|
|
121
|
+
## 8.1.0-canary.42
|
|
122
|
+
|
|
123
|
+
## 8.1.0-canary.41
|
|
124
|
+
|
|
125
|
+
## 8.1.0-canary.40
|
|
126
|
+
|
|
127
|
+
## 8.1.0-canary.39
|
|
128
|
+
|
|
129
|
+
## 8.1.0-canary.38
|
|
130
|
+
|
|
131
|
+
## 8.1.0-canary.37
|
|
132
|
+
|
|
133
|
+
## 8.1.0-canary.36
|
|
134
|
+
|
|
135
|
+
## 8.1.0-canary.35
|
|
136
|
+
|
|
137
|
+
## 8.1.0-canary.34
|
|
138
|
+
|
|
139
|
+
## 8.1.0-canary.33
|
|
140
|
+
|
|
141
|
+
## 8.1.0-canary.32
|
|
142
|
+
|
|
143
|
+
## 8.1.0-canary.31
|
|
144
|
+
|
|
145
|
+
## 8.1.0-canary.30
|
|
146
|
+
|
|
147
|
+
## 8.1.0-canary.29
|
|
148
|
+
|
|
149
|
+
## 8.1.0-canary.28
|
|
150
|
+
|
|
151
|
+
## 8.1.0-canary.27
|
|
152
|
+
|
|
153
|
+
## 8.1.0-canary.26
|
|
154
|
+
|
|
155
|
+
## 8.1.0-canary.25
|
|
156
|
+
|
|
157
|
+
## 8.1.0-canary.24
|
|
158
|
+
|
|
159
|
+
## 8.1.0-canary.23
|
|
160
|
+
|
|
161
|
+
## 8.1.0-canary.22
|
|
162
|
+
|
|
163
|
+
## 8.1.0-canary.21
|
|
164
|
+
|
|
165
|
+
## 8.1.0-canary.20
|
|
166
|
+
|
|
167
|
+
## 8.1.0-canary.19
|
|
168
|
+
|
|
169
|
+
## 8.1.0-canary.18
|
|
170
|
+
|
|
171
|
+
## 8.1.0-canary.17
|
|
172
|
+
|
|
173
|
+
## 8.1.0-canary.16
|
|
174
|
+
|
|
175
|
+
## 8.1.0-canary.15
|
|
176
|
+
|
|
177
|
+
## 8.1.0-canary.14
|
|
178
|
+
|
|
179
|
+
## 8.1.0-canary.13
|
|
180
|
+
|
|
181
|
+
## 8.1.0-canary.12
|
|
182
|
+
|
|
183
|
+
## 8.1.0-canary.11
|
|
184
|
+
|
|
185
|
+
## 8.1.0-canary.10
|
|
186
|
+
|
|
3
187
|
## 8.1.0-canary.9
|
|
4
188
|
|
|
5
189
|
## 8.1.0-canary.8
|
|
@@ -92,19 +276,15 @@
|
|
|
92
276
|
|
|
93
277
|
### Minor Changes
|
|
94
278
|
|
|
95
|
-
- [#2099](https://github.com/graphcommerce-org/graphcommerce/pull/2099) [`ff796b8`](https://github.com/graphcommerce-org/graphcommerce/commit/ff796b838fae6cb5e35b101500133b0235a8677d) - Support for all customizable product options (except file upload) on the product pages and in the cart.
|
|
96
|
-
([@Jessevdpoel](https://github.com/Jessevdpoel))
|
|
279
|
+
- [#2099](https://github.com/graphcommerce-org/graphcommerce/pull/2099) [`ff796b8`](https://github.com/graphcommerce-org/graphcommerce/commit/ff796b838fae6cb5e35b101500133b0235a8677d) - Support for all customizable product options (except file upload) on the product pages and in the cart. ([@Jessevdpoel](https://github.com/Jessevdpoel))
|
|
97
280
|
|
|
98
|
-
- [#2048](https://github.com/graphcommerce-org/graphcommerce/pull/2048) [`13e23e4`](https://github.com/graphcommerce-org/graphcommerce/commit/13e23e4265bac70fb4d0830e4661019e71ce299f) - Wishlist will now support configurable products and uses the `<ActionCardLayout/>`
|
|
99
|
-
([@Jessevdpoel](https://github.com/Jessevdpoel))
|
|
281
|
+
- [#2048](https://github.com/graphcommerce-org/graphcommerce/pull/2048) [`13e23e4`](https://github.com/graphcommerce-org/graphcommerce/commit/13e23e4265bac70fb4d0830e4661019e71ce299f) - Wishlist will now support configurable products and uses the `<ActionCardLayout/>` ([@Jessevdpoel](https://github.com/Jessevdpoel))
|
|
100
282
|
|
|
101
283
|
### Patch Changes
|
|
102
284
|
|
|
103
|
-
- [#2115](https://github.com/graphcommerce-org/graphcommerce/pull/2115) [`105a1af`](https://github.com/graphcommerce-org/graphcommerce/commit/105a1af8b820de8873e430ae398f1922d39a9110) - Disabled ripple animations on all ActionCard ‘Select’ and ‘Change’ so the rendering is more subtle during checkout.
|
|
104
|
-
([@Jessevdpoel](https://github.com/Jessevdpoel))
|
|
285
|
+
- [#2115](https://github.com/graphcommerce-org/graphcommerce/pull/2115) [`105a1af`](https://github.com/graphcommerce-org/graphcommerce/commit/105a1af8b820de8873e430ae398f1922d39a9110) - Disabled ripple animations on all ActionCard ‘Select’ and ‘Change’ so the rendering is more subtle during checkout. ([@Jessevdpoel](https://github.com/Jessevdpoel))
|
|
105
286
|
|
|
106
|
-
- [#2028](https://github.com/graphcommerce-org/graphcommerce/pull/2028) [`dd5499d`](https://github.com/graphcommerce-org/graphcommerce/commit/dd5499daedb0a5cd38081f2bd7892df40bb23e16) - Solved an issue where the quantity selector was not working for bundled products
|
|
107
|
-
([@Jessevdpoel](https://github.com/Jessevdpoel))
|
|
287
|
+
- [#2028](https://github.com/graphcommerce-org/graphcommerce/pull/2028) [`dd5499d`](https://github.com/graphcommerce-org/graphcommerce/commit/dd5499daedb0a5cd38081f2bd7892df40bb23e16) - Solved an issue where the quantity selector was not working for bundled products ([@Jessevdpoel](https://github.com/Jessevdpoel))
|
|
108
288
|
|
|
109
289
|
## 8.0.0-canary.100
|
|
110
290
|
|
|
@@ -168,8 +348,7 @@
|
|
|
168
348
|
|
|
169
349
|
### Minor Changes
|
|
170
350
|
|
|
171
|
-
- [#2099](https://github.com/graphcommerce-org/graphcommerce/pull/2099) [`ff796b8`](https://github.com/graphcommerce-org/graphcommerce/commit/ff796b838fae6cb5e35b101500133b0235a8677d) - Created UI for all customizable options except for the file upload customizable option
|
|
172
|
-
([@Jessevdpoel](https://github.com/Jessevdpoel))
|
|
351
|
+
- [#2099](https://github.com/graphcommerce-org/graphcommerce/pull/2099) [`ff796b8`](https://github.com/graphcommerce-org/graphcommerce/commit/ff796b838fae6cb5e35b101500133b0235a8677d) - Created UI for all customizable options except for the file upload customizable option ([@Jessevdpoel](https://github.com/Jessevdpoel))
|
|
173
352
|
|
|
174
353
|
## 8.0.0-canary.70
|
|
175
354
|
|
|
@@ -1458,31 +1637,31 @@
|
|
|
1458
1637
|
All occurences of `<Trans>` and `t` need to be replaced:
|
|
1459
1638
|
|
|
1460
1639
|
```tsx
|
|
1461
|
-
import { Trans, t } from
|
|
1640
|
+
import { Trans, t } from '@lingui/macro'
|
|
1462
1641
|
|
|
1463
1642
|
function MyComponent() {
|
|
1464
|
-
const foo =
|
|
1643
|
+
const foo = 'bar'
|
|
1465
1644
|
return (
|
|
1466
1645
|
<div aria-label={t`Account ${foo}`}>
|
|
1467
1646
|
<Trans>My Translation {foo}</Trans>
|
|
1468
1647
|
</div>
|
|
1469
|
-
)
|
|
1648
|
+
)
|
|
1470
1649
|
}
|
|
1471
1650
|
```
|
|
1472
1651
|
|
|
1473
1652
|
Needs to be replaced with:
|
|
1474
1653
|
|
|
1475
1654
|
```tsx
|
|
1476
|
-
import { Trans } from
|
|
1477
|
-
import { i18n } from
|
|
1655
|
+
import { Trans } from '@lingui/react'
|
|
1656
|
+
import { i18n } from '@lingui/core'
|
|
1478
1657
|
|
|
1479
1658
|
function MyComponent() {
|
|
1480
|
-
const foo =
|
|
1659
|
+
const foo = 'bar'
|
|
1481
1660
|
return (
|
|
1482
1661
|
<div aria-label={i18n._(/* i18n */ `Account {foo}`, { foo })}>
|
|
1483
|
-
<Trans key=
|
|
1662
|
+
<Trans key='My Translation {foo}' values={{ foo }}></Trans>
|
|
1484
1663
|
</div>
|
|
1485
|
-
)
|
|
1664
|
+
)
|
|
1486
1665
|
}
|
|
1487
1666
|
```
|
|
1488
1667
|
|
|
@@ -11,27 +11,28 @@ export function BundleProductCartItemOptions(props: BundleProductCartItemOptions
|
|
|
11
11
|
|
|
12
12
|
return (
|
|
13
13
|
<>
|
|
14
|
-
{bundle_options?.map(
|
|
15
|
-
(
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
>
|
|
27
|
-
|
|
28
|
-
{option_value.price > 0 && (
|
|
29
|
-
<Box sx={(theme) => ({ position: 'absolute', right: theme.spacings.xs })}>
|
|
30
|
-
<Money currency={prices?.price.currency} value={option_value.price} />
|
|
31
|
-
</Box>
|
|
32
|
-
)}
|
|
14
|
+
{bundle_options?.map((option) =>
|
|
15
|
+
option?.values.filter(nonNullable).map((option_value) => (
|
|
16
|
+
<Box
|
|
17
|
+
key={option_value.uid}
|
|
18
|
+
sx={(theme) => ({
|
|
19
|
+
display: 'flex',
|
|
20
|
+
gap: theme.spacings.xxs,
|
|
21
|
+
[theme.breakpoints.down('sm')]: {
|
|
22
|
+
fontSize: theme.typography.caption.fontSize,
|
|
23
|
+
},
|
|
24
|
+
})}
|
|
25
|
+
>
|
|
26
|
+
<Box sx={{ color: 'text.primary' }}>
|
|
27
|
+
{option_value.label} {option_value.quantity > 1 && `x${option_value.quantity}`}
|
|
33
28
|
</Box>
|
|
34
|
-
|
|
29
|
+
{option_value.price > 0 && (
|
|
30
|
+
<Box sx={(theme) => ({ position: 'absolute', right: theme.spacings.xs })}>
|
|
31
|
+
<Money currency={prices?.price.currency} value={option_value.price} />
|
|
32
|
+
</Box>
|
|
33
|
+
)}
|
|
34
|
+
</Box>
|
|
35
|
+
)),
|
|
35
36
|
)}
|
|
36
37
|
|
|
37
38
|
<SelectedCustomizableOptions {...props} />
|
|
@@ -1,10 +1,6 @@
|
|
|
1
|
+
import { ActionCardItemBase, ActionCardListForm } from '@graphcommerce/ecommerce-ui'
|
|
1
2
|
import { AddProductsToCartFields, useFormAddProductsToCart } from '@graphcommerce/magento-product'
|
|
2
|
-
import {
|
|
3
|
-
SectionHeader,
|
|
4
|
-
ActionCardListForm,
|
|
5
|
-
ActionCardItemBase,
|
|
6
|
-
filterNonNullableKeys,
|
|
7
|
-
} from '@graphcommerce/next-ui'
|
|
3
|
+
import { SectionHeader, filterNonNullableKeys } from '@graphcommerce/next-ui'
|
|
8
4
|
import { i18n } from '@lingui/core'
|
|
9
5
|
import React, { useMemo } from 'react'
|
|
10
6
|
import { BundleOptionValue } from './BundleOptionValue'
|
|
@@ -1,13 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ActionCardItemRenderProps, NumberFieldElement } from '@graphcommerce/ecommerce-ui'
|
|
2
2
|
import { Image } from '@graphcommerce/image'
|
|
3
3
|
import { useFormAddProductsToCart } from '@graphcommerce/magento-product'
|
|
4
4
|
import { Money } from '@graphcommerce/magento-store'
|
|
5
|
-
import {
|
|
6
|
-
responsiveVal,
|
|
7
|
-
ActionCardItemRenderProps,
|
|
8
|
-
ActionCard,
|
|
9
|
-
Button,
|
|
10
|
-
} from '@graphcommerce/next-ui'
|
|
5
|
+
import { responsiveVal, ActionCard, Button } from '@graphcommerce/next-ui'
|
|
11
6
|
import { Trans } from '@lingui/react'
|
|
12
7
|
import { BundleOptionValueProps } from './types'
|
|
13
8
|
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { ActionCardItemRenderProps
|
|
1
|
+
import { ActionCardItemRenderProps } from '@graphcommerce/ecommerce-ui'
|
|
2
|
+
import { ActionCardListProps } from '@graphcommerce/next-ui'
|
|
2
3
|
import { BundleProductOptionsFragment } from './BundleProductOptions.gql'
|
|
3
4
|
|
|
4
5
|
export type BundleOptionProps = {
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@graphcommerce/magento-product-bundle",
|
|
3
3
|
"homepage": "https://www.graphcommerce.org/",
|
|
4
4
|
"repository": "github:graphcommerce-org/graphcommerce",
|
|
5
|
-
"version": "
|
|
5
|
+
"version": "9.0.0-canary.101",
|
|
6
6
|
"sideEffects": false,
|
|
7
7
|
"prettier": "@graphcommerce/prettier-config-pwa",
|
|
8
8
|
"eslintConfig": {
|
|
@@ -12,19 +12,19 @@
|
|
|
12
12
|
}
|
|
13
13
|
},
|
|
14
14
|
"peerDependencies": {
|
|
15
|
-
"@graphcommerce/ecommerce-ui": "^
|
|
16
|
-
"@graphcommerce/eslint-config-pwa": "^
|
|
17
|
-
"@graphcommerce/graphql": "^
|
|
18
|
-
"@graphcommerce/image": "^
|
|
19
|
-
"@graphcommerce/magento-cart": "^
|
|
20
|
-
"@graphcommerce/magento-cart-items": "^
|
|
21
|
-
"@graphcommerce/magento-product": "^
|
|
22
|
-
"@graphcommerce/magento-product-simple": "^
|
|
23
|
-
"@graphcommerce/magento-product-virtual": "^
|
|
24
|
-
"@graphcommerce/magento-store": "^
|
|
25
|
-
"@graphcommerce/next-ui": "^
|
|
26
|
-
"@graphcommerce/prettier-config-pwa": "^
|
|
27
|
-
"@graphcommerce/typescript-config-pwa": "^
|
|
15
|
+
"@graphcommerce/ecommerce-ui": "^9.0.0-canary.101",
|
|
16
|
+
"@graphcommerce/eslint-config-pwa": "^9.0.0-canary.101",
|
|
17
|
+
"@graphcommerce/graphql": "^9.0.0-canary.101",
|
|
18
|
+
"@graphcommerce/image": "^9.0.0-canary.101",
|
|
19
|
+
"@graphcommerce/magento-cart": "^9.0.0-canary.101",
|
|
20
|
+
"@graphcommerce/magento-cart-items": "^9.0.0-canary.101",
|
|
21
|
+
"@graphcommerce/magento-product": "^9.0.0-canary.101",
|
|
22
|
+
"@graphcommerce/magento-product-simple": "^9.0.0-canary.101",
|
|
23
|
+
"@graphcommerce/magento-product-virtual": "^9.0.0-canary.101",
|
|
24
|
+
"@graphcommerce/magento-store": "^9.0.0-canary.101",
|
|
25
|
+
"@graphcommerce/next-ui": "^9.0.0-canary.101",
|
|
26
|
+
"@graphcommerce/prettier-config-pwa": "^9.0.0-canary.101",
|
|
27
|
+
"@graphcommerce/typescript-config-pwa": "^9.0.0-canary.101",
|
|
28
28
|
"@lingui/core": "^4.2.1",
|
|
29
29
|
"@lingui/macro": "^4.2.1",
|
|
30
30
|
"@lingui/react": "^4.2.1",
|
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
import { CartItemActionCardProps } from '@graphcommerce/magento-cart-items'
|
|
2
|
-
import type { PluginProps } from '@graphcommerce/next-config'
|
|
2
|
+
import type { PluginConfig, PluginProps } from '@graphcommerce/next-config'
|
|
3
3
|
import { isTypename } from '@graphcommerce/next-ui'
|
|
4
4
|
import { BundleProductCartItemOptions } from '../components/BundleProductCartItemOptions/BundleProductCartItemOptions'
|
|
5
5
|
|
|
6
|
-
export const
|
|
7
|
-
|
|
6
|
+
export const config: PluginConfig = {
|
|
7
|
+
type: 'component',
|
|
8
|
+
module: '@graphcommerce/magento-cart-items',
|
|
9
|
+
}
|
|
8
10
|
|
|
9
|
-
export function
|
|
11
|
+
export function CartItemActionCard(props: PluginProps<CartItemActionCardProps>) {
|
|
10
12
|
const { Prev, ...rest } = props
|
|
11
13
|
|
|
12
14
|
if (!isTypename(rest.cartItem, ['BundleCartItem'])) return <Prev {...rest} />
|
|
@@ -23,5 +25,3 @@ export function BundleCartItemActionCard(props: PluginProps<CartItemActionCardPr
|
|
|
23
25
|
/>
|
|
24
26
|
)
|
|
25
27
|
}
|
|
26
|
-
|
|
27
|
-
export const Plugin = BundleCartItemActionCard
|