@graphcommerce/magento-cart-shipping-method 3.0.16 → 3.0.19
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.
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Money } from '@graphcommerce/magento-store'
|
|
2
2
|
import { ToggleButton, ToggleButtonProps, extendableComponent } from '@graphcommerce/next-ui'
|
|
3
|
-
import { Trans } from '@lingui/
|
|
3
|
+
import { Trans } from '@lingui/react'
|
|
4
4
|
import { Box, FormHelperText } from '@mui/material'
|
|
5
5
|
import React from 'react'
|
|
6
6
|
import type { SetOptional } from 'type-fest'
|
|
@@ -84,7 +84,7 @@ export const AvailableShippingMethod = React.forwardRef(
|
|
|
84
84
|
},
|
|
85
85
|
}}
|
|
86
86
|
>
|
|
87
|
-
{amount?.value === 0 ? <Trans
|
|
87
|
+
{amount?.value === 0 ? <Trans id='Free' /> : <Money {...amount} />}
|
|
88
88
|
</Box>
|
|
89
89
|
|
|
90
90
|
{error_message ? (
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,75 @@
|
|
|
1
1
|
# Change Log
|
|
2
2
|
|
|
3
|
+
## 3.0.19
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [[`0363b9671`](https://github.com/graphcommerce-org/graphcommerce/commit/0363b9671db7c2932321d97faf6f1eb385238397), [`3ac90b57c`](https://github.com/graphcommerce-org/graphcommerce/commit/3ac90b57c68b96f9d81771d6664ed9435a28fc1d), [`ed2b67a06`](https://github.com/graphcommerce-org/graphcommerce/commit/ed2b67a0618d9db97e79ed2a8226e0ae12403943)]:
|
|
8
|
+
- @graphcommerce/next-ui@4.8.0
|
|
9
|
+
- @graphcommerce/magento-cart@4.2.15
|
|
10
|
+
- @graphcommerce/framer-scroller@2.1.11
|
|
11
|
+
- @graphcommerce/magento-cart-shipping-address@3.0.18
|
|
12
|
+
- @graphcommerce/magento-store@4.2.4
|
|
13
|
+
|
|
14
|
+
## 3.0.18
|
|
15
|
+
|
|
16
|
+
### Patch Changes
|
|
17
|
+
|
|
18
|
+
- Updated dependencies [[`c30893857`](https://github.com/graphcommerce-org/graphcommerce/commit/c3089385791291e812a48c2691a39a2325ee0439)]:
|
|
19
|
+
- @graphcommerce/magento-store@4.2.3
|
|
20
|
+
- @graphcommerce/magento-cart@4.2.14
|
|
21
|
+
- @graphcommerce/magento-cart-shipping-address@3.0.17
|
|
22
|
+
|
|
23
|
+
## 3.0.17
|
|
24
|
+
|
|
25
|
+
### Patch Changes
|
|
26
|
+
|
|
27
|
+
- [#1451](https://github.com/graphcommerce-org/graphcommerce/pull/1451) [`f698ff85d`](https://github.com/graphcommerce-org/graphcommerce/commit/f698ff85df6bb0922288471bb3c81856091b8061) Thanks [@paales](https://github.com/paales)! - Removed all occurences of @lingui/macro and moved to @lingui/macro / @lingui/core in preparation to move to swc.
|
|
28
|
+
|
|
29
|
+
Since we've removed @lingui/macro, all occurences need to be replaced with @lingui/core and @lingui/react.
|
|
30
|
+
|
|
31
|
+
All occurences of `<Trans>` and `t` need to be replaced:
|
|
32
|
+
|
|
33
|
+
```tsx
|
|
34
|
+
import { Trans, t } from '@lingui/macro'
|
|
35
|
+
|
|
36
|
+
function MyComponent() {
|
|
37
|
+
const foo = 'bar'
|
|
38
|
+
return (
|
|
39
|
+
<div aria-label={t`Account ${foo}`}>
|
|
40
|
+
<Trans>My Translation {foo}</Trans>
|
|
41
|
+
</div>
|
|
42
|
+
)
|
|
43
|
+
}
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
Needs to be replaced with:
|
|
47
|
+
|
|
48
|
+
```tsx
|
|
49
|
+
import { Trans } from '@lingui/react'
|
|
50
|
+
import { i18n } from '@lingui/core'
|
|
51
|
+
|
|
52
|
+
function MyComponent() {
|
|
53
|
+
const foo = 'bar'
|
|
54
|
+
return (
|
|
55
|
+
<div aria-label={i18n._(/* i18n */ `Account {foo}`, { foo })}>
|
|
56
|
+
<Trans key='My Translation {foo}' values={{ foo }}></Trans>
|
|
57
|
+
</div>
|
|
58
|
+
)
|
|
59
|
+
}
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
[More examples for Trans](https://lingui.js.org/ref/macro.html#examples-of-jsx-macros) and [more examples for `t`](https://lingui.js.org/ref/macro.html#examples-of-js-macros)
|
|
63
|
+
|
|
64
|
+
- Updated dependencies [[`50188e378`](https://github.com/graphcommerce-org/graphcommerce/commit/50188e378b4c77561ebc600958ea11cd114fa61a), [`f698ff85d`](https://github.com/graphcommerce-org/graphcommerce/commit/f698ff85df6bb0922288471bb3c81856091b8061)]:
|
|
65
|
+
- @graphcommerce/react-hook-form@3.1.3
|
|
66
|
+
- @graphcommerce/framer-scroller@2.1.10
|
|
67
|
+
- @graphcommerce/magento-cart@4.2.13
|
|
68
|
+
- @graphcommerce/magento-cart-shipping-address@3.0.16
|
|
69
|
+
- @graphcommerce/magento-store@4.2.2
|
|
70
|
+
- @graphcommerce/next-ui@4.7.2
|
|
71
|
+
- @graphcommerce/graphql@3.1.3
|
|
72
|
+
|
|
3
73
|
## 3.0.16
|
|
4
74
|
|
|
5
75
|
### Patch Changes
|
|
@@ -13,7 +13,8 @@ import {
|
|
|
13
13
|
extendableComponent,
|
|
14
14
|
} from '@graphcommerce/next-ui'
|
|
15
15
|
import { Controller, useFormCompose, UseFormComposeOptions } from '@graphcommerce/react-hook-form'
|
|
16
|
-
import {
|
|
16
|
+
import { i18n } from '@lingui/core'
|
|
17
|
+
import { Trans } from '@lingui/react'
|
|
17
18
|
import { FormControl, Alert, Box } from '@mui/material'
|
|
18
19
|
import { AvailableShippingMethod } from '../AvailableShippingMethod/AvailableShippingMethod'
|
|
19
20
|
import { GetShippingMethodsDocument } from './GetShippingMethods.gql'
|
|
@@ -106,7 +107,11 @@ export function ShippingMethodForm(props: ShippingMethodFormProps) {
|
|
|
106
107
|
},
|
|
107
108
|
}}
|
|
108
109
|
>
|
|
109
|
-
<IconSvg
|
|
110
|
+
<IconSvg
|
|
111
|
+
src={iconChevronLeft}
|
|
112
|
+
size='small'
|
|
113
|
+
aria-label={i18n._(/* i18n */ `Scroll Left`)}
|
|
114
|
+
/>
|
|
110
115
|
</ScrollerButton>
|
|
111
116
|
</Box>
|
|
112
117
|
|
|
@@ -171,7 +176,7 @@ export function ShippingMethodForm(props: ShippingMethodFormProps) {
|
|
|
171
176
|
carrier_code='none'
|
|
172
177
|
carrier_title='No shipping methods available'
|
|
173
178
|
>
|
|
174
|
-
<Trans
|
|
179
|
+
<Trans id='Please fill in your address to see shipping methods' />
|
|
175
180
|
</AvailableShippingMethod>
|
|
176
181
|
)}
|
|
177
182
|
</Scroller>
|
|
@@ -223,7 +228,11 @@ export function ShippingMethodForm(props: ShippingMethodFormProps) {
|
|
|
223
228
|
}}
|
|
224
229
|
className={classes.buttonRoot}
|
|
225
230
|
>
|
|
226
|
-
<IconSvg
|
|
231
|
+
<IconSvg
|
|
232
|
+
src={iconChevronRight}
|
|
233
|
+
size='small'
|
|
234
|
+
aria-label={i18n._(/* i18n */ `Scroll Right`)}
|
|
235
|
+
/>
|
|
227
236
|
</ScrollerButton>
|
|
228
237
|
</Box>
|
|
229
238
|
</ScrollerProvider>
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@graphcommerce/magento-cart-shipping-method",
|
|
3
3
|
"homepage": "https://www.graphcommerce.org/",
|
|
4
4
|
"repository": "github:graphcommerce-org/graphcommerce",
|
|
5
|
-
"version": "3.0.
|
|
5
|
+
"version": "3.0.19",
|
|
6
6
|
"sideEffects": false,
|
|
7
7
|
"prettier": "@graphcommerce/prettier-config-pwa",
|
|
8
8
|
"eslintConfig": {
|
|
@@ -12,24 +12,25 @@
|
|
|
12
12
|
}
|
|
13
13
|
},
|
|
14
14
|
"devDependencies": {
|
|
15
|
-
"@graphcommerce/eslint-config-pwa": "^4.1.
|
|
15
|
+
"@graphcommerce/eslint-config-pwa": "^4.1.7",
|
|
16
16
|
"@graphcommerce/prettier-config-pwa": "^4.0.6",
|
|
17
|
-
"@graphcommerce/typescript-config-pwa": "^4.0.
|
|
17
|
+
"@graphcommerce/typescript-config-pwa": "^4.0.3",
|
|
18
18
|
"@playwright/test": "^1.21.1",
|
|
19
19
|
"type-fest": "^2.12.2"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"@graphcommerce/framer-scroller": "2.1.
|
|
23
|
-
"@graphcommerce/graphql": "3.1.
|
|
22
|
+
"@graphcommerce/framer-scroller": "2.1.11",
|
|
23
|
+
"@graphcommerce/graphql": "3.1.3",
|
|
24
24
|
"@graphcommerce/image": "3.1.5",
|
|
25
|
-
"@graphcommerce/magento-cart": "4.2.
|
|
26
|
-
"@graphcommerce/magento-cart-shipping-address": "3.0.
|
|
27
|
-
"@graphcommerce/magento-store": "4.2.
|
|
28
|
-
"@graphcommerce/next-ui": "4.
|
|
29
|
-
"@graphcommerce/react-hook-form": "3.1.
|
|
25
|
+
"@graphcommerce/magento-cart": "4.2.15",
|
|
26
|
+
"@graphcommerce/magento-cart-shipping-address": "3.0.18",
|
|
27
|
+
"@graphcommerce/magento-store": "4.2.4",
|
|
28
|
+
"@graphcommerce/next-ui": "4.8.0",
|
|
29
|
+
"@graphcommerce/react-hook-form": "3.1.3"
|
|
30
30
|
},
|
|
31
31
|
"peerDependencies": {
|
|
32
|
-
"@lingui/
|
|
32
|
+
"@lingui/react": "^3.13.2",
|
|
33
|
+
"@lingui/core": "^3.13.2",
|
|
33
34
|
"@mui/material": "5.5.3",
|
|
34
35
|
"framer-motion": "^6.2.4",
|
|
35
36
|
"next": "12.1.2",
|