@graphcommerce/magento-review 3.0.5 → 3.1.0

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
@@ -1,18 +1,55 @@
1
1
  # Change Log
2
2
 
3
+ ## 3.1.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#1322](https://github.com/graphcommerce-org/graphcommerce/pull/1322) [`0298a0de1`](https://github.com/graphcommerce-org/graphcommerce/commit/0298a0de1d13e543c4124a6a099297b4e27e2b05) Thanks [@paales](https://github.com/paales)! - Added `<Slider size='large' />` and made styling with variants
8
+
9
+ ### Patch Changes
10
+
11
+ - [#1322](https://github.com/graphcommerce-org/graphcommerce/pull/1322) [`6f9d23688`](https://github.com/graphcommerce-org/graphcommerce/commit/6f9d23688ea26c74a41623c7f62597d33281d7c1) Thanks [@paales](https://github.com/paales)! - Review form had the wrong colors
12
+
13
+ * [#1322](https://github.com/graphcommerce-org/graphcommerce/pull/1322) [`ffb3dfa75`](https://github.com/graphcommerce-org/graphcommerce/commit/ffb3dfa752bd2304f92caaf253ffe685d7652a9e) Thanks [@paales](https://github.com/paales)! - reviews error because rows was defined
14
+
15
+ - [#1322](https://github.com/graphcommerce-org/graphcommerce/pull/1322) [`a26db0656`](https://github.com/graphcommerce-org/graphcommerce/commit/a26db0656e371f2bad4901aefa14507840e3d4cd) Thanks [@paales](https://github.com/paales)! - ProductReviews nested buttons
16
+
17
+ - Updated dependencies [[`5266388ea`](https://github.com/graphcommerce-org/graphcommerce/commit/5266388eaffda41592623ef7a3ddbbe03c8e0dad), [`9b35403d9`](https://github.com/graphcommerce-org/graphcommerce/commit/9b35403d9dbb2606ac7cf3bb641a0f9cc3d8a2ba), [`0298a0de1`](https://github.com/graphcommerce-org/graphcommerce/commit/0298a0de1d13e543c4124a6a099297b4e27e2b05), [`815132ea4`](https://github.com/graphcommerce-org/graphcommerce/commit/815132ea43937b4b84b59ec9974ac593cb4eb456), [`3326742a0`](https://github.com/graphcommerce-org/graphcommerce/commit/3326742a0dceb45f0cac4741ca09dc4d4f09ad90), [`7a3799bfc`](https://github.com/graphcommerce-org/graphcommerce/commit/7a3799bfc107f26aa9991a91db5f228e3476f4aa), [`9a77f88ed`](https://github.com/graphcommerce-org/graphcommerce/commit/9a77f88ed26cbecdae9a135c3cb234a5b7ecf4df), [`bc8826b9d`](https://github.com/graphcommerce-org/graphcommerce/commit/bc8826b9dc1e6418b2720c9211e46791c33fca8a), [`0eeaad304`](https://github.com/graphcommerce-org/graphcommerce/commit/0eeaad30461b1d5b486438f0287fa76d49429044), [`bc5213547`](https://github.com/graphcommerce-org/graphcommerce/commit/bc52135471479c83d989449dad24798112e898f4), [`3f1912f55`](https://github.com/graphcommerce-org/graphcommerce/commit/3f1912f553318d5888f8af2b841918ef4ae96a84), [`7e910f3b8`](https://github.com/graphcommerce-org/graphcommerce/commit/7e910f3b8eb73cff33261956937124f95520d8e5), [`3b4d46de2`](https://github.com/graphcommerce-org/graphcommerce/commit/3b4d46de2555db9eed733c8fac574bc809d75da4), [`b6c68cda8`](https://github.com/graphcommerce-org/graphcommerce/commit/b6c68cda8836a1d0c78ef351899cec9ec1037385), [`e4ded94d7`](https://github.com/graphcommerce-org/graphcommerce/commit/e4ded94d7b0f0c87f86abcd31340d75533bde73e)]:
18
+ - @graphcommerce/next-ui@4.3.0
19
+ - @graphcommerce/magento-product@4.1.0
20
+ - @graphcommerce/magento-store@4.1.3
21
+ - @graphcommerce/magento-customer@4.1.5
22
+
23
+ ## 3.0.7
24
+
25
+ ### Patch Changes
26
+
27
+ - [#1310](https://github.com/graphcommerce-org/graphcommerce/pull/1310) [`bcae21cfa`](https://github.com/graphcommerce-org/graphcommerce/commit/bcae21cfafe5bf8e0768f9b52028e0e3195cd3b7) Thanks [@LaurensFranken](https://github.com/LaurensFranken)! - Make texts in product reviews component translatable
28
+
29
+ ## 3.0.6
30
+
31
+ ### Patch Changes
32
+
33
+ - [#1307](https://github.com/ho-nl/m2-pwa/pull/1307) [`bd10506d3`](https://github.com/ho-nl/m2-pwa/commit/bd10506d32fdbc91d01dadc29a12ebd1e0943655) Thanks [@paales](https://github.com/paales)! - All default exports are now named exports internally and all `index.tsx` are renamed to the component name.
34
+
35
+ * [#1307](https://github.com/ho-nl/m2-pwa/pull/1307) [`27cb1f2d8`](https://github.com/ho-nl/m2-pwa/commit/27cb1f2d8dbfb8f1b301ce56fb6a2b6c1fc6a5ef) Thanks [@paales](https://github.com/paales)! - upgrade dependencies
36
+
37
+ * Updated dependencies [[`3d63b39f7`](https://github.com/ho-nl/m2-pwa/commit/3d63b39f7e330d1827a32dba782667d7b21adaba), [`bd10506d3`](https://github.com/ho-nl/m2-pwa/commit/bd10506d32fdbc91d01dadc29a12ebd1e0943655), [`27cb1f2d8`](https://github.com/ho-nl/m2-pwa/commit/27cb1f2d8dbfb8f1b301ce56fb6a2b6c1fc6a5ef)]:
38
+ - @graphcommerce/next-ui@4.2.4
39
+ - @graphcommerce/graphql@3.0.4
40
+ - @graphcommerce/image@3.1.1
41
+ - @graphcommerce/magento-customer@4.1.4
42
+ - @graphcommerce/magento-product@4.0.6
43
+ - @graphcommerce/magento-store@4.1.2
44
+ - @graphcommerce/react-hook-form@3.0.4
45
+
3
46
  ## 3.0.5
4
47
 
5
48
  ### Patch Changes
6
49
 
7
- - [#1292](https://github.com/ho-nl/m2-pwa/pull/1292)
8
- [`5a1ba9e66`](https://github.com/ho-nl/m2-pwa/commit/5a1ba9e664abbac89c4f5f71f7d6d6ed1aefa5c0)
9
- Thanks [@paales](https://github.com/paales)! - Renamed SvgIcon to IconSvg to prevent collisions
10
- with MUI
50
+ - [#1292](https://github.com/ho-nl/m2-pwa/pull/1292) [`5a1ba9e66`](https://github.com/ho-nl/m2-pwa/commit/5a1ba9e664abbac89c4f5f71f7d6d6ed1aefa5c0) Thanks [@paales](https://github.com/paales)! - Renamed SvgIcon to IconSvg to prevent collisions with MUI
11
51
 
12
- - Updated dependencies
13
- [[`5a1ba9e66`](https://github.com/ho-nl/m2-pwa/commit/5a1ba9e664abbac89c4f5f71f7d6d6ed1aefa5c0),
14
- [`990df655b`](https://github.com/ho-nl/m2-pwa/commit/990df655b73b469718d6cb5837ee65dfe2ad6a1d),
15
- [`63f9b56eb`](https://github.com/ho-nl/m2-pwa/commit/63f9b56eb68ba790567ff1427e599fd2c3c8f1ee)]:
52
+ - Updated dependencies [[`5a1ba9e66`](https://github.com/ho-nl/m2-pwa/commit/5a1ba9e664abbac89c4f5f71f7d6d6ed1aefa5c0), [`990df655b`](https://github.com/ho-nl/m2-pwa/commit/990df655b73b469718d6cb5837ee65dfe2ad6a1d), [`63f9b56eb`](https://github.com/ho-nl/m2-pwa/commit/63f9b56eb68ba790567ff1427e599fd2c3c8f1ee)]:
16
53
  - @graphcommerce/magento-customer@4.1.3
17
54
  - @graphcommerce/magento-product@4.0.5
18
55
  - @graphcommerce/next-ui@4.2.0
@@ -21,13 +58,9 @@
21
58
 
22
59
  ### Patch Changes
23
60
 
24
- - [#1285](https://github.com/ho-nl/m2-pwa/pull/1285)
25
- [`c85294ba6`](https://github.com/ho-nl/m2-pwa/commit/c85294ba6d742ce78c074559a1e95409b25a5017)
26
- Thanks [@paales](https://github.com/paales)! - upgraded dependencies
61
+ - [#1285](https://github.com/ho-nl/m2-pwa/pull/1285) [`c85294ba6`](https://github.com/ho-nl/m2-pwa/commit/c85294ba6d742ce78c074559a1e95409b25a5017) Thanks [@paales](https://github.com/paales)! - upgraded dependencies
27
62
 
28
- - Updated dependencies
29
- [[`ed9703b06`](https://github.com/ho-nl/m2-pwa/commit/ed9703b062d23ee01b1605ff9917c0ac3247fc25),
30
- [`c85294ba6`](https://github.com/ho-nl/m2-pwa/commit/c85294ba6d742ce78c074559a1e95409b25a5017)]:
63
+ - Updated dependencies [[`ed9703b06`](https://github.com/ho-nl/m2-pwa/commit/ed9703b062d23ee01b1605ff9917c0ac3247fc25), [`c85294ba6`](https://github.com/ho-nl/m2-pwa/commit/c85294ba6d742ce78c074559a1e95409b25a5017)]:
31
64
  - @graphcommerce/magento-store@4.1.0
32
65
  - @graphcommerce/magento-product@4.0.4
33
66
  - @graphcommerce/next-ui@4.1.3
@@ -36,19 +69,11 @@
36
69
 
37
70
  ### Patch Changes
38
71
 
39
- - [#1280](https://github.com/ho-nl/m2-pwa/pull/1280)
40
- [`bdd460c6f`](https://github.com/ho-nl/m2-pwa/commit/bdd460c6f09af148a96c55324012b8f53c3618f1)
41
- Thanks [@paales](https://github.com/paales)! - Review forms now work by using the url_key of a
42
- product instead of the SKU. Some backends do not support filtering by sku
72
+ - [#1280](https://github.com/ho-nl/m2-pwa/pull/1280) [`bdd460c6f`](https://github.com/ho-nl/m2-pwa/commit/bdd460c6f09af148a96c55324012b8f53c3618f1) Thanks [@paales](https://github.com/paales)! - Review forms now work by using the url_key of a product instead of the SKU. Some backends do not support filtering by sku
43
73
 
44
- * [`973ff8645`](https://github.com/ho-nl/m2-pwa/commit/973ff86452a70ade9f4db13fdda6e963d7220e96)
45
- Thanks [@paales](https://github.com/paales)! - made packages public
74
+ * [`973ff8645`](https://github.com/ho-nl/m2-pwa/commit/973ff86452a70ade9f4db13fdda6e963d7220e96) Thanks [@paales](https://github.com/paales)! - made packages public
46
75
 
47
- * Updated dependencies
48
- [[`973ff8645`](https://github.com/ho-nl/m2-pwa/commit/973ff86452a70ade9f4db13fdda6e963d7220e96),
49
- [`81ea406d5`](https://github.com/ho-nl/m2-pwa/commit/81ea406d54d6b5c662c030a7fea444abc4117a20),
50
- [`3a719c88c`](https://github.com/ho-nl/m2-pwa/commit/3a719c88cad1eab58602de28c41adc0fc4827e1d),
51
- [`5ffcb56bf`](https://github.com/ho-nl/m2-pwa/commit/5ffcb56bfcbe49ebeaf24f9341e819a145ab9a14)]:
76
+ * Updated dependencies [[`973ff8645`](https://github.com/ho-nl/m2-pwa/commit/973ff86452a70ade9f4db13fdda6e963d7220e96), [`81ea406d5`](https://github.com/ho-nl/m2-pwa/commit/81ea406d54d6b5c662c030a7fea444abc4117a20), [`3a719c88c`](https://github.com/ho-nl/m2-pwa/commit/3a719c88cad1eab58602de28c41adc0fc4827e1d), [`5ffcb56bf`](https://github.com/ho-nl/m2-pwa/commit/5ffcb56bfcbe49ebeaf24f9341e819a145ab9a14)]:
52
77
  - @graphcommerce/graphql@3.0.3
53
78
  - @graphcommerce/image@3.1.0
54
79
  - @graphcommerce/magento-customer@4.1.2
@@ -61,29 +86,13 @@
61
86
 
62
87
  ### Patch Changes
63
88
 
64
- - [#1276](https://github.com/ho-nl/m2-pwa/pull/1276)
65
- [`ce09388e0`](https://github.com/ho-nl/m2-pwa/commit/ce09388e0d7ef33aee660612340f6fbae15ceec2)
66
- Thanks [@paales](https://github.com/paales)! - We've moved lots of internal packages from
67
- `dependencies` to `peerDependencies`. The result of this is that there will be significantly less
68
- duplicate packages in the node_modules folders.
69
-
70
- * [#1276](https://github.com/ho-nl/m2-pwa/pull/1276)
71
- [`52a45bba4`](https://github.com/ho-nl/m2-pwa/commit/52a45bba4dc6dd6df3c81f5023df7d23ed8a534d)
72
- Thanks [@paales](https://github.com/paales)! - Upgraded to
73
- [NextJS 12.1](https://nextjs.org/blog/next-12-1)! This is just for compatibility, but we'll be
74
- implementing
75
- [On-demand Incremental Static Regeneration](https://nextjs.org/blog/next-12-1#on-demand-incremental-static-regeneration-beta)
76
- soon.
77
-
78
- This will greatly reduce the requirement to rebuid stuff and we'll add a management UI on the
79
- frontend to be able to revalidate pages manually.
80
-
81
- * Updated dependencies
82
- [[`381e4c86a`](https://github.com/ho-nl/m2-pwa/commit/381e4c86a8321ce96e1fa5c7d3c0a0c0ff3e02c7),
83
- [`ce09388e0`](https://github.com/ho-nl/m2-pwa/commit/ce09388e0d7ef33aee660612340f6fbae15ceec2),
84
- [`e7c8e2756`](https://github.com/ho-nl/m2-pwa/commit/e7c8e2756d637cbcd2e793d62ef5721d35d9fa7b),
85
- [`b08a8eb1d`](https://github.com/ho-nl/m2-pwa/commit/b08a8eb1d024b9d3e7712ef034029151670db275),
86
- [`52a45bba4`](https://github.com/ho-nl/m2-pwa/commit/52a45bba4dc6dd6df3c81f5023df7d23ed8a534d)]:
89
+ - [#1276](https://github.com/ho-nl/m2-pwa/pull/1276) [`ce09388e0`](https://github.com/ho-nl/m2-pwa/commit/ce09388e0d7ef33aee660612340f6fbae15ceec2) Thanks [@paales](https://github.com/paales)! - We've moved lots of internal packages from `dependencies` to `peerDependencies`. The result of this is that there will be significantly less duplicate packages in the node_modules folders.
90
+
91
+ * [#1276](https://github.com/ho-nl/m2-pwa/pull/1276) [`52a45bba4`](https://github.com/ho-nl/m2-pwa/commit/52a45bba4dc6dd6df3c81f5023df7d23ed8a534d) Thanks [@paales](https://github.com/paales)! - Upgraded to [NextJS 12.1](https://nextjs.org/blog/next-12-1)! This is just for compatibility, but we'll be implementing [On-demand Incremental Static Regeneration](https://nextjs.org/blog/next-12-1#on-demand-incremental-static-regeneration-beta) soon.
92
+
93
+ This will greatly reduce the requirement to rebuid stuff and we'll add a management UI on the frontend to be able to revalidate pages manually.
94
+
95
+ * Updated dependencies [[`381e4c86a`](https://github.com/ho-nl/m2-pwa/commit/381e4c86a8321ce96e1fa5c7d3c0a0c0ff3e02c7), [`ce09388e0`](https://github.com/ho-nl/m2-pwa/commit/ce09388e0d7ef33aee660612340f6fbae15ceec2), [`e7c8e2756`](https://github.com/ho-nl/m2-pwa/commit/e7c8e2756d637cbcd2e793d62ef5721d35d9fa7b), [`b08a8eb1d`](https://github.com/ho-nl/m2-pwa/commit/b08a8eb1d024b9d3e7712ef034029151670db275), [`52a45bba4`](https://github.com/ho-nl/m2-pwa/commit/52a45bba4dc6dd6df3c81f5023df7d23ed8a534d)]:
87
96
  - @graphcommerce/magento-customer@4.1.1
88
97
  - @graphcommerce/next-ui@4.1.1
89
98
  - @graphcommerce/react-hook-form@3.0.2
@@ -96,11 +105,8 @@
96
105
 
97
106
  ### Patch Changes
98
107
 
99
- - [`0cbaa878b`](https://github.com/ho-nl/m2-pwa/commit/0cbaa878b8a844d5abbeb1797b625a33130e6514)
100
- Thanks [@paales](https://github.com/paales)! - Added homepage and repository package.json files,
101
- so that the packages link to back to the website and repository
102
- - Updated dependencies
103
- [[`0cbaa878b`](https://github.com/ho-nl/m2-pwa/commit/0cbaa878b8a844d5abbeb1797b625a33130e6514)]:
108
+ - [`0cbaa878b`](https://github.com/ho-nl/m2-pwa/commit/0cbaa878b8a844d5abbeb1797b625a33130e6514) Thanks [@paales](https://github.com/paales)! - Added homepage and repository package.json files, so that the packages link to back to the website and repository
109
+ - Updated dependencies [[`0cbaa878b`](https://github.com/ho-nl/m2-pwa/commit/0cbaa878b8a844d5abbeb1797b625a33130e6514)]:
104
110
  - @graphcommerce/graphql@3.0.1
105
111
  - @graphcommerce/image@3.0.1
106
112
  - @graphcommerce/magento-customer@4.0.1
@@ -113,14 +119,11 @@
113
119
 
114
120
  ### Major Changes
115
121
 
116
- - [#1258](https://github.com/ho-nl/m2-pwa/pull/1258)
117
- [`ad36382a4`](https://github.com/ho-nl/m2-pwa/commit/ad36382a4d55d83d9e47b7eb6a02671a2a631a05)
118
- Thanks [@paales](https://github.com/paales)! - Upgraded to Material UI 5
122
+ - [#1258](https://github.com/ho-nl/m2-pwa/pull/1258) [`ad36382a4`](https://github.com/ho-nl/m2-pwa/commit/ad36382a4d55d83d9e47b7eb6a02671a2a631a05) Thanks [@paales](https://github.com/paales)! - Upgraded to Material UI 5
119
123
 
120
124
  ### Patch Changes
121
125
 
122
- - Updated dependencies
123
- [[`ad36382a4`](https://github.com/ho-nl/m2-pwa/commit/ad36382a4d55d83d9e47b7eb6a02671a2a631a05)]:
126
+ - Updated dependencies [[`ad36382a4`](https://github.com/ho-nl/m2-pwa/commit/ad36382a4d55d83d9e47b7eb6a02671a2a631a05)]:
124
127
  - @graphcommerce/graphql@3.0.0
125
128
  - @graphcommerce/image@3.0.0
126
129
  - @graphcommerce/magento-customer@4.0.0
@@ -129,116 +132,88 @@
129
132
  - @graphcommerce/next-ui@4.0.0
130
133
  - @graphcommerce/react-hook-form@3.0.0
131
134
 
132
- All notable changes to this project will be documented in this file. See
133
- [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
135
+ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
134
136
 
135
137
  # [2.111.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-review@2.110.2...@graphcommerce/magento-review@2.111.0) (2021-12-01)
136
138
 
137
139
  ### Features
138
140
 
139
- - borderRadius based on theme.shape.borderRadius
140
- ([7c34937](https://github.com/ho-nl/m2-pwa/commit/7c349376cd41a131c628324c299106fdb7e60484))
141
+ - borderRadius based on theme.shape.borderRadius ([7c34937](https://github.com/ho-nl/m2-pwa/commit/7c349376cd41a131c628324c299106fdb7e60484))
141
142
 
142
143
  # [2.110.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-review@2.109.1...@graphcommerce/magento-review@2.110.0) (2021-11-22)
143
144
 
144
145
  ### Bug Fixes
145
146
 
146
- - allow styling from parent
147
- ([ed1b4dc](https://github.com/ho-nl/m2-pwa/commit/ed1b4dc446fa19244cc73f87063256809b914d15))
148
- - cleanup
149
- ([7937ac5](https://github.com/ho-nl/m2-pwa/commit/7937ac5c6163a4ffe10d8a8d61847fcc86e82a9d))
150
- - make stylable
151
- ([54aea4c](https://github.com/ho-nl/m2-pwa/commit/54aea4c177c708de07df9ef9c590da6bff43aea8))
152
- - remove styles
153
- ([fabde1f](https://github.com/ho-nl/m2-pwa/commit/fabde1f1dba9f75dea60bb2c7c69d4793c6197cd))
154
- - rename summary chip fragment
155
- ([bb23dfc](https://github.com/ho-nl/m2-pwa/commit/bb23dfc8bb82e99832196b4080d2c4c9f269cc5d))
156
- - revert to SvgImageSimple
157
- ([b247c6b](https://github.com/ho-nl/m2-pwa/commit/b247c6b96979bc313e597a8ffe1275b73f38bd6a))
158
- - review form size large
159
- ([9f45336](https://github.com/ho-nl/m2-pwa/commit/9f45336d310b120088fe6440dd95a51944ff77cb))
160
- - use fragment types
161
- ([0a06309](https://github.com/ho-nl/m2-pwa/commit/0a0630916e191c59eed402904b9ace6b87831bd8))
147
+ - allow styling from parent ([ed1b4dc](https://github.com/ho-nl/m2-pwa/commit/ed1b4dc446fa19244cc73f87063256809b914d15))
148
+ - cleanup ([7937ac5](https://github.com/ho-nl/m2-pwa/commit/7937ac5c6163a4ffe10d8a8d61847fcc86e82a9d))
149
+ - make stylable ([54aea4c](https://github.com/ho-nl/m2-pwa/commit/54aea4c177c708de07df9ef9c590da6bff43aea8))
150
+ - remove styles ([fabde1f](https://github.com/ho-nl/m2-pwa/commit/fabde1f1dba9f75dea60bb2c7c69d4793c6197cd))
151
+ - rename summary chip fragment ([bb23dfc](https://github.com/ho-nl/m2-pwa/commit/bb23dfc8bb82e99832196b4080d2c4c9f269cc5d))
152
+ - revert to SvgImageSimple ([b247c6b](https://github.com/ho-nl/m2-pwa/commit/b247c6b96979bc313e597a8ffe1275b73f38bd6a))
153
+ - review form size large ([9f45336](https://github.com/ho-nl/m2-pwa/commit/9f45336d310b120088fe6440dd95a51944ff77cb))
154
+ - use fragment types ([0a06309](https://github.com/ho-nl/m2-pwa/commit/0a0630916e191c59eed402904b9ace6b87831bd8))
162
155
 
163
156
  ### Features
164
157
 
165
- - add ReviewSummary component
166
- ([b823669](https://github.com/ho-nl/m2-pwa/commit/b823669d32e92238d05cac181c3453a13da49601))
167
- - use Rating component
168
- ([ec54f45](https://github.com/ho-nl/m2-pwa/commit/ec54f4522adb2d330bbdecc2ce032f86f13fb7a6))
158
+ - add ReviewSummary component ([b823669](https://github.com/ho-nl/m2-pwa/commit/b823669d32e92238d05cac181c3453a13da49601))
159
+ - use Rating component ([ec54f45](https://github.com/ho-nl/m2-pwa/commit/ec54f4522adb2d330bbdecc2ce032f86f13fb7a6))
169
160
 
170
161
  # [2.109.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-review@2.108.6...@graphcommerce/magento-review@2.109.0) (2021-11-12)
171
162
 
172
163
  ### Bug Fixes
173
164
 
174
- - even more translations
175
- ([1a1f988](https://github.com/ho-nl/m2-pwa/commit/1a1f98837c704b978f6b42b619d9c52f540b2d48))
165
+ - even more translations ([1a1f988](https://github.com/ho-nl/m2-pwa/commit/1a1f98837c704b978f6b42b619d9c52f540b2d48))
176
166
 
177
167
  ### Features
178
168
 
179
- - added tons of translations
180
- ([9bb0ac7](https://github.com/ho-nl/m2-pwa/commit/9bb0ac709b58df6ea6141e92e4923a5ca9ae2963))
169
+ - added tons of translations ([9bb0ac7](https://github.com/ho-nl/m2-pwa/commit/9bb0ac709b58df6ea6141e92e4923a5ca9ae2963))
181
170
 
182
171
  # [2.108.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-review@2.107.21...@graphcommerce/magento-review@2.108.0) (2021-11-09)
183
172
 
184
173
  ### Features
185
174
 
186
- - added translations to all pages
187
- ([8cf4ecd](https://github.com/ho-nl/m2-pwa/commit/8cf4ecd5db5edfec04ab205aa49f5de433d26579))
175
+ - added translations to all pages ([8cf4ecd](https://github.com/ho-nl/m2-pwa/commit/8cf4ecd5db5edfec04ab205aa49f5de433d26579))
188
176
 
189
177
  ## [2.107.13](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-review@2.107.12...@graphcommerce/magento-review@2.107.13) (2021-11-03)
190
178
 
191
179
  ### Bug Fixes
192
180
 
193
- - various accessibility improvements
194
- ([47481a9](https://github.com/ho-nl/m2-pwa/commit/47481a9a882ba87968de6dd797557b0b275d75fb))
181
+ - various accessibility improvements ([47481a9](https://github.com/ho-nl/m2-pwa/commit/47481a9a882ba87968de6dd797557b0b275d75fb))
195
182
 
196
183
  ## [2.107.6](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-review@2.107.5...@graphcommerce/magento-review@2.107.6) (2021-11-02)
197
184
 
198
185
  ### Bug Fixes
199
186
 
200
- - remove text='bold', make contained button text stronger by default
201
- ([cd277c9](https://github.com/ho-nl/m2-pwa/commit/cd277c9f434a4a765eac372467e5a05c822d5512))
202
- - remove unused imports
203
- ([b832188](https://github.com/ho-nl/m2-pwa/commit/b8321887f10a4a026adc5ca39166eeef90e60669))
204
- - ReviewChip should only differ from default MuiChip in product grid
205
- ([c22a029](https://github.com/ho-nl/m2-pwa/commit/c22a0291afbbc03099fd0487421ff9fd31caf226))
187
+ - remove text='bold', make contained button text stronger by default ([cd277c9](https://github.com/ho-nl/m2-pwa/commit/cd277c9f434a4a765eac372467e5a05c822d5512))
188
+ - remove unused imports ([b832188](https://github.com/ho-nl/m2-pwa/commit/b8321887f10a4a026adc5ca39166eeef90e60669))
189
+ - ReviewChip should only differ from default MuiChip in product grid ([c22a029](https://github.com/ho-nl/m2-pwa/commit/c22a0291afbbc03099fd0487421ff9fd31caf226))
206
190
 
207
191
  ## [2.107.1](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-review@2.107.0...@graphcommerce/magento-review@2.107.1) (2021-10-28)
208
192
 
209
193
  ### Bug Fixes
210
194
 
211
- - External SVG's can't have alt tags
212
- ([1b1414a](https://github.com/ho-nl/m2-pwa/commit/1b1414a782d55d3acf7b0e6bcaa50f2ad5f18f39))
195
+ - External SVG's can't have alt tags ([1b1414a](https://github.com/ho-nl/m2-pwa/commit/1b1414a782d55d3acf7b0e6bcaa50f2ad5f18f39))
213
196
 
214
197
  # [2.107.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-review@2.106.2...@graphcommerce/magento-review@2.107.0) (2021-10-28)
215
198
 
216
199
  ### Bug Fixes
217
200
 
218
- - keep original review chip
219
- ([3f2f834](https://github.com/ho-nl/m2-pwa/commit/3f2f834478b7b8252f6164442815e5c081de6411))
220
- - keep original review chip for now
221
- ([9664cd9](https://github.com/ho-nl/m2-pwa/commit/9664cd90801c6776e1c694eec8f393118810a792))
222
- - review button size
223
- ([9074102](https://github.com/ho-nl/m2-pwa/commit/9074102c1866b14d0e7f1f0f3dfabe6e6c0b324d))
224
- - size of default ReviewChip
225
- ([e1d4969](https://github.com/ho-nl/m2-pwa/commit/e1d49699776b15fa056677f042f6c9939b6acada))
201
+ - keep original review chip ([3f2f834](https://github.com/ho-nl/m2-pwa/commit/3f2f834478b7b8252f6164442815e5c081de6411))
202
+ - keep original review chip for now ([9664cd9](https://github.com/ho-nl/m2-pwa/commit/9664cd90801c6776e1c694eec8f393118810a792))
203
+ - review button size ([9074102](https://github.com/ho-nl/m2-pwa/commit/9074102c1866b14d0e7f1f0f3dfabe6e6c0b324d))
204
+ - size of default ReviewChip ([e1d4969](https://github.com/ho-nl/m2-pwa/commit/e1d49699776b15fa056677f042f6c9939b6acada))
226
205
 
227
206
  ### Features
228
207
 
229
- - cleanup grid, add visual star chip
230
- ([0571569](https://github.com/ho-nl/m2-pwa/commit/057156937f603bc399f5f8f8ac2837ff5cfaef28))
231
- - dynamic icons, update SvgImage uses to SvgImageSimple
232
- ([3d3cc0e](https://github.com/ho-nl/m2-pwa/commit/3d3cc0e0336fcde1cce6ba19705f82c1edf9bfc6))
233
- - enable use of both small and medium chips in design
234
- ([4536f96](https://github.com/ho-nl/m2-pwa/commit/4536f96b031734a71faf7c10f94aa5d5da90b9a8))
208
+ - cleanup grid, add visual star chip ([0571569](https://github.com/ho-nl/m2-pwa/commit/057156937f603bc399f5f8f8ac2837ff5cfaef28))
209
+ - dynamic icons, update SvgImage uses to SvgImageSimple ([3d3cc0e](https://github.com/ho-nl/m2-pwa/commit/3d3cc0e0336fcde1cce6ba19705f82c1edf9bfc6))
210
+ - enable use of both small and medium chips in design ([4536f96](https://github.com/ho-nl/m2-pwa/commit/4536f96b031734a71faf7c10f94aa5d5da90b9a8))
235
211
 
236
212
  # [2.106.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-review@2.105.37...@graphcommerce/magento-review@2.106.0) (2021-10-27)
237
213
 
238
214
  ### Features
239
215
 
240
- - **nextjs:** upgraded to nextjs 12
241
- ([9331bc8](https://github.com/ho-nl/m2-pwa/commit/9331bc801f6419522115cc47d291d49d608d5a90))
216
+ - **nextjs:** upgraded to nextjs 12 ([9331bc8](https://github.com/ho-nl/m2-pwa/commit/9331bc801f6419522115cc47d291d49d608d5a90))
242
217
 
243
218
  ## [2.105.1](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-review@2.105.0...@graphcommerce/magento-review@2.105.1) (2021-09-27)
244
219
 
@@ -248,115 +223,89 @@ All notable changes to this project will be documented in this file. See
248
223
 
249
224
  ### Bug Fixes
250
225
 
251
- - customer-order folder structure
252
- ([b7fabd1](https://github.com/ho-nl/m2-pwa/commit/b7fabd12014b2925d0b89c21f58e9974ce1c8b40))
253
- - introduced SvgImageSimple and solve issue with review chips
254
- ([931d7fd](https://github.com/ho-nl/m2-pwa/commit/931d7fdcf0faa9d2264899b72e564138215b6bd8))
255
- - make separate queries folder, create injectable for account and inject reviews
256
- ([5d82a5d](https://github.com/ho-nl/m2-pwa/commit/5d82a5d9162f687c2678cce215b77eedbaf1669e))
257
- - remove coupon form style was too large
258
- ([30df274](https://github.com/ho-nl/m2-pwa/commit/30df274ecdffdcebd76710a5304d6fa248e81211))
259
- - **review:** make sure chip is rendered correctly
260
- ([387df34](https://github.com/ho-nl/m2-pwa/commit/387df3456973290f9ce98d47823a7c71a6d95850))
261
- - SvgSimpleImage sizing didn't use rem
262
- ([1ba07a5](https://github.com/ho-nl/m2-pwa/commit/1ba07a5694bd60ad3cee2e8102814643d2a7c79d))
226
+ - customer-order folder structure ([b7fabd1](https://github.com/ho-nl/m2-pwa/commit/b7fabd12014b2925d0b89c21f58e9974ce1c8b40))
227
+ - introduced SvgImageSimple and solve issue with review chips ([931d7fd](https://github.com/ho-nl/m2-pwa/commit/931d7fdcf0faa9d2264899b72e564138215b6bd8))
228
+ - make separate queries folder, create injectable for account and inject reviews ([5d82a5d](https://github.com/ho-nl/m2-pwa/commit/5d82a5d9162f687c2678cce215b77eedbaf1669e))
229
+ - remove coupon form style was too large ([30df274](https://github.com/ho-nl/m2-pwa/commit/30df274ecdffdcebd76710a5304d6fa248e81211))
230
+ - **review:** make sure chip is rendered correctly ([387df34](https://github.com/ho-nl/m2-pwa/commit/387df3456973290f9ce98d47823a7c71a6d95850))
231
+ - SvgSimpleImage sizing didn't use rem ([1ba07a5](https://github.com/ho-nl/m2-pwa/commit/1ba07a5694bd60ad3cee2e8102814643d2a7c79d))
263
232
 
264
233
  ### Features
265
234
 
266
- - **playwright:** added new playwright package to enable browser testing
267
- ([6f49ec7](https://github.com/ho-nl/m2-pwa/commit/6f49ec7595563775b96ebf21c27e39da1282e8d9))
268
- - renamed all packages to use [@graphcommerce](https://github.com/graphcommerce) instead of
269
- [@reachdigital](https://github.com/reachdigital)
270
- ([491e4ce](https://github.com/ho-nl/m2-pwa/commit/491e4cec9a2686472dac36b79f999257c0811ffe))
271
- - **theme:** restructured fonts and applied to home and category page
272
- ([6adf5f1](https://github.com/ho-nl/m2-pwa/commit/6adf5f11321bdfbf499125f1161c5abf5a1bfe4a))
273
- - upgraded to nextjs 11
274
- ([0053beb](https://github.com/ho-nl/m2-pwa/commit/0053beb7ef597c190add7264256a0eaec35868da))
235
+ - **playwright:** added new playwright package to enable browser testing ([6f49ec7](https://github.com/ho-nl/m2-pwa/commit/6f49ec7595563775b96ebf21c27e39da1282e8d9))
236
+ - renamed all packages to use [@graphcommerce](https://github.com/graphcommerce) instead of [@reachdigital](https://github.com/reachdigital) ([491e4ce](https://github.com/ho-nl/m2-pwa/commit/491e4cec9a2686472dac36b79f999257c0811ffe))
237
+ - **theme:** restructured fonts and applied to home and category page ([6adf5f1](https://github.com/ho-nl/m2-pwa/commit/6adf5f11321bdfbf499125f1161c5abf5a1bfe4a))
238
+ - upgraded to nextjs 11 ([0053beb](https://github.com/ho-nl/m2-pwa/commit/0053beb7ef597c190add7264256a0eaec35868da))
275
239
 
276
240
  ### Reverts
277
241
 
278
- - Revert "chore: upgrade @apollo/client"
279
- ([55ff24e](https://github.com/ho-nl/m2-pwa/commit/55ff24ede0e56c85b8095edadadd1ec5e0b1b8d2))
242
+ - Revert "chore: upgrade @apollo/client" ([55ff24e](https://github.com/ho-nl/m2-pwa/commit/55ff24ede0e56c85b8095edadadd1ec5e0b1b8d2))
280
243
 
281
244
  # Change Log
282
245
 
283
- All notable changes to this project will be documented in this file. See
284
- [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
246
+ All notable changes to this project will be documented in this file. See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
285
247
 
286
248
  # [2.104.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-review@2.103.2...@graphcommerce/magento-review@2.104.0) (2021-08-12)
287
249
 
288
250
  ### Bug Fixes
289
251
 
290
- - remove coupon form style was too large
291
- ([30df274](https://github.com/ho-nl/m2-pwa/commit/30df274ecdffdcebd76710a5304d6fa248e81211))
252
+ - remove coupon form style was too large ([30df274](https://github.com/ho-nl/m2-pwa/commit/30df274ecdffdcebd76710a5304d6fa248e81211))
292
253
 
293
254
  ### Features
294
255
 
295
- - upgraded to nextjs 11
296
- ([0053beb](https://github.com/ho-nl/m2-pwa/commit/0053beb7ef597c190add7264256a0eaec35868da))
256
+ - upgraded to nextjs 11 ([0053beb](https://github.com/ho-nl/m2-pwa/commit/0053beb7ef597c190add7264256a0eaec35868da))
297
257
 
298
258
  ## [2.103.2](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-review@2.103.1...@graphcommerce/magento-review@2.103.2) (2021-08-09)
299
259
 
300
260
  ### Bug Fixes
301
261
 
302
- - SvgSimpleImage sizing didn't use rem
303
- ([1ba07a5](https://github.com/ho-nl/m2-pwa/commit/1ba07a5694bd60ad3cee2e8102814643d2a7c79d))
262
+ - SvgSimpleImage sizing didn't use rem ([1ba07a5](https://github.com/ho-nl/m2-pwa/commit/1ba07a5694bd60ad3cee2e8102814643d2a7c79d))
304
263
 
305
264
  ### Reverts
306
265
 
307
- - Revert "chore: upgrade @apollo/client"
308
- ([55ff24e](https://github.com/ho-nl/m2-pwa/commit/55ff24ede0e56c85b8095edadadd1ec5e0b1b8d2))
266
+ - Revert "chore: upgrade @apollo/client" ([55ff24e](https://github.com/ho-nl/m2-pwa/commit/55ff24ede0e56c85b8095edadadd1ec5e0b1b8d2))
309
267
 
310
268
  ## [2.103.1](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-review@2.103.0...@graphcommerce/magento-review@2.103.1) (2021-08-09)
311
269
 
312
270
  ### Bug Fixes
313
271
 
314
- - **review:** make sure chip is rendered correctly
315
- ([387df34](https://github.com/ho-nl/m2-pwa/commit/387df3456973290f9ce98d47823a7c71a6d95850))
272
+ - **review:** make sure chip is rendered correctly ([387df34](https://github.com/ho-nl/m2-pwa/commit/387df3456973290f9ce98d47823a7c71a6d95850))
316
273
 
317
274
  # [2.103.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-review@2.102.6...@graphcommerce/magento-review@2.103.0) (2021-08-06)
318
275
 
319
276
  ### Bug Fixes
320
277
 
321
- - introduced SvgImageSimple and solve issue with review chips
322
- ([931d7fd](https://github.com/ho-nl/m2-pwa/commit/931d7fdcf0faa9d2264899b72e564138215b6bd8))
278
+ - introduced SvgImageSimple and solve issue with review chips ([931d7fd](https://github.com/ho-nl/m2-pwa/commit/931d7fdcf0faa9d2264899b72e564138215b6bd8))
323
279
 
324
280
  ### Features
325
281
 
326
- - **theme:** restructured fonts and applied to home and category page
327
- ([6adf5f1](https://github.com/ho-nl/m2-pwa/commit/6adf5f11321bdfbf499125f1161c5abf5a1bfe4a))
282
+ - **theme:** restructured fonts and applied to home and category page ([6adf5f1](https://github.com/ho-nl/m2-pwa/commit/6adf5f11321bdfbf499125f1161c5abf5a1bfe4a))
328
283
 
329
284
  # [2.102.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-review@2.101.3...@graphcommerce/magento-review@2.102.0) (2021-07-26)
330
285
 
331
286
  ### Features
332
287
 
333
- - **playwright:** added new playwright package to enable browser testing
334
- ([6f49ec7](https://github.com/ho-nl/m2-pwa/commit/6f49ec7595563775b96ebf21c27e39da1282e8d9))
288
+ - **playwright:** added new playwright package to enable browser testing ([6f49ec7](https://github.com/ho-nl/m2-pwa/commit/6f49ec7595563775b96ebf21c27e39da1282e8d9))
335
289
 
336
290
  ## 2.101.1 (2021-07-23)
337
291
 
338
292
  ### Bug Fixes
339
293
 
340
- - customer-order folder structure
341
- ([b7fabd1](https://github.com/ho-nl/m2-pwa/commit/b7fabd12014b2925d0b89c21f58e9974ce1c8b40))
342
- - make separate queries folder, create injectable for account and inject reviews
343
- ([5d82a5d](https://github.com/ho-nl/m2-pwa/commit/5d82a5d9162f687c2678cce215b77eedbaf1669e))
294
+ - customer-order folder structure ([b7fabd1](https://github.com/ho-nl/m2-pwa/commit/b7fabd12014b2925d0b89c21f58e9974ce1c8b40))
295
+ - make separate queries folder, create injectable for account and inject reviews ([5d82a5d](https://github.com/ho-nl/m2-pwa/commit/5d82a5d9162f687c2678cce215b77eedbaf1669e))
344
296
 
345
297
  # [2.101.0](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-product-review@2.100.14...@graphcommerce/magento-product-review@2.101.0) (2021-07-21)
346
298
 
347
299
  ### Bug Fixes
348
300
 
349
- - write review button mobile styles
350
- ([8f6b883](https://github.com/ho-nl/m2-pwa/commit/8f6b883fa0a513f84b7c6d8ed376b0e8d4b8a3bd))
301
+ - write review button mobile styles ([8f6b883](https://github.com/ho-nl/m2-pwa/commit/8f6b883fa0a513f84b7c6d8ed376b0e8d4b8a3bd))
351
302
 
352
303
  ### Features
353
304
 
354
- - **reviews:** no reviews written message
355
- ([8ade3db](https://github.com/ho-nl/m2-pwa/commit/8ade3dbe830f5a59af09c002dfa38fa5349a4b61))
305
+ - **reviews:** no reviews written message ([8ade3db](https://github.com/ho-nl/m2-pwa/commit/8ade3dbe830f5a59af09c002dfa38fa5349a4b61))
356
306
 
357
307
  ## [2.100.11](https://github.com/ho-nl/m2-pwa/compare/@graphcommerce/magento-product-review@2.100.10...@graphcommerce/magento-product-review@2.100.11) (2021-07-20)
358
308
 
359
309
  ### Bug Fixes
360
310
 
361
- - ignore md files from triggering version updates
362
- ([4f98392](https://github.com/ho-nl/m2-pwa/commit/4f9839250b3a32d3070da5290e5efcc5e2243fba))
311
+ - ignore md files from triggering version updates ([4f98392](https://github.com/ho-nl/m2-pwa/commit/4f9839250b3a32d3070da5290e5efcc5e2243fba))
@@ -1,13 +1,13 @@
1
1
  import { SectionContainer, extendableComponent } from '@graphcommerce/next-ui'
2
2
  import { Box, Skeleton } from '@mui/material'
3
- import CustomerReview from '../CustomerReview'
3
+ import { CustomerReview } from '../CustomerReview/CustomerReview'
4
4
  import { AccountReviewsFragment } from './AccountReviews.gql'
5
5
 
6
6
  type AccountReviewsProps = AccountReviewsFragment & { loading: boolean }
7
7
 
8
8
  const { classes } = extendableComponent('AccountReviews', ['root', 'older'] as const)
9
9
 
10
- export default function AccountReviews(props: AccountReviewsProps) {
10
+ export function AccountReviews(props: AccountReviewsProps) {
11
11
  const { items, loading } = props
12
12
  const showLatestReviews = 2
13
13
  const latestReviews = items?.slice(0, Math.min(items?.length, showLatestReviews))
@@ -1,5 +1,4 @@
1
- import { useQuery } from '@graphcommerce/graphql'
2
- import { ProductReviewRatingInput } from '@graphcommerce/graphql'
1
+ import { useQuery, ProductReviewRatingInput } from '@graphcommerce/graphql'
3
2
  import { ApolloCustomerErrorAlert } from '@graphcommerce/magento-customer'
4
3
  import {
5
4
  Form,
@@ -35,7 +34,7 @@ const parts = [
35
34
  ] as const
36
35
  const { classes } = extendableComponent(name, parts)
37
36
 
38
- export default function CreateProductReviewForm(props: CreateProductReviewFormProps) {
37
+ export function CreateProductReviewForm(props: CreateProductReviewFormProps) {
39
38
  const { sku, nickname, sx = [] } = props
40
39
  const router = useRouter()
41
40
  const [ratings, setRatings] = useState<ProductReviewRatingInput[]>([])
@@ -88,7 +87,7 @@ export default function CreateProductReviewForm(props: CreateProductReviewFormPr
88
87
  }
89
88
 
90
89
  return (
91
- <Form onSubmit={submitHandler} noValidate className={classes.root}>
90
+ <Form onSubmit={submitHandler} noValidate className={classes.root} sx={sx}>
92
91
  <FormRow>
93
92
  <TextField
94
93
  variant='outlined'
@@ -111,9 +110,9 @@ export default function CreateProductReviewForm(props: CreateProductReviewFormPr
111
110
  marginBottom: theme.spacings.xxs,
112
111
  })}
113
112
  >
114
- {data?.productReviewRatingsMetadata?.items?.map((prrvm) => (
113
+ {data?.productReviewRatingsMetadata?.items?.map((item) => (
115
114
  <FormRow
116
- key={prrvm?.id}
115
+ key={item?.id}
117
116
  className={classes.rating}
118
117
  sx={{
119
118
  paddingBottom: 'unset',
@@ -122,7 +121,7 @@ export default function CreateProductReviewForm(props: CreateProductReviewFormPr
122
121
  }}
123
122
  >
124
123
  <Typography
125
- variant='h5'
124
+ variant='subtitle1'
126
125
  component='span'
127
126
  className={classes.ratingLabel}
128
127
  sx={{
@@ -130,11 +129,11 @@ export default function CreateProductReviewForm(props: CreateProductReviewFormPr
130
129
  justifySelf: 'left',
131
130
  }}
132
131
  >
133
- {prrvm?.name}
132
+ {item?.name}
134
133
  </Typography>
135
- {prrvm && (
134
+ {item && (
136
135
  <StarRatingField
137
- id={prrvm?.id ?? ''}
136
+ id={item?.id ?? ''}
138
137
  size='large'
139
138
  onChange={(id, value) => {
140
139
  const productReviewRatingInputValue =
@@ -191,8 +190,7 @@ export default function CreateProductReviewForm(props: CreateProductReviewFormPr
191
190
  helperText={formState.errors.text?.message}
192
191
  disabled={formState.isSubmitting}
193
192
  multiline
194
- rows={8}
195
- maxRows={8}
193
+ minRows={4}
196
194
  />
197
195
  </FormRow>
198
196
 
@@ -19,7 +19,7 @@ const { classes } = extendableComponent('ScrollerDots', [
19
19
  'date',
20
20
  ] as const)
21
21
 
22
- export default function CustomerReview(props: CustomerReviewProps) {
22
+ export function CustomerReview(props: CustomerReviewProps) {
23
23
  const { product, text, average_rating, created_at, sx = [] } = props
24
24
 
25
25
  const maxAverageRating = 100
@@ -6,16 +6,16 @@ export type ProductReviewChipProps = {
6
6
  rating?: number
7
7
  reviewSectionId?: string
8
8
  max?: number
9
- } & ChipProps
9
+ } & ChipProps<'button'>
10
10
 
11
- export default function ProductReviewChip(props: ProductReviewChipProps) {
11
+ export function ProductReviewChip(props: ProductReviewChipProps) {
12
12
  const { rating, reviewSectionId = '', max = 5, ...chipProps } = props
13
13
 
14
14
  if (!rating) return null
15
15
 
16
16
  const normalizedRating = Math.round(rating / (10 / max)) / 10
17
17
 
18
- const handleClick: React.MouseEventHandler<HTMLDivElement> = (e) => {
18
+ const handleClick: React.MouseEventHandler<HTMLButtonElement> = (e) => {
19
19
  const element = document.getElementById(reviewSectionId)
20
20
  e.preventDefault()
21
21
  if (!element) return
@@ -29,12 +29,13 @@ export default function ProductReviewChip(props: ProductReviewChipProps) {
29
29
 
30
30
  const chip = (
31
31
  <Chip
32
+ component='button'
32
33
  variant='outlined'
33
34
  clickable={!!reviewSectionId}
34
35
  onClick={handleClick}
35
- icon={<IconSvg src={iconStar} size='small' sx={{ stroke: '#FFDA1C', fill: '#FFDA1C' }} />}
36
+ icon={<IconSvg src={iconStar} sx={{ stroke: '#FFDA1C', fill: '#FFDA1C' }} />}
36
37
  color='default'
37
- size='small'
38
+ size='medium'
38
39
  label={`${normalizedRating}/5`}
39
40
  {...chipProps}
40
41
  />
@@ -8,7 +8,7 @@ const name = 'ProductReviewSummary' as const
8
8
  const parts = ['root', 'rating', 'iconStar', 'iconStarDisabled'] as const
9
9
  const { classes } = extendableComponent(name, parts)
10
10
 
11
- export default function ProductReviewSummary(props: ProductReviewSummaryProps) {
11
+ export function ProductReviewSummary(props: ProductReviewSummaryProps) {
12
12
  const { rating_summary, sx = [] } = props
13
13
 
14
14
  if (!rating_summary) return null
@@ -6,10 +6,10 @@ import {
6
6
  extendableComponent,
7
7
  } from '@graphcommerce/next-ui'
8
8
  import { Trans } from '@lingui/macro'
9
- import { Typography, Button, Box, SxProps, Theme } from '@mui/material'
10
- import Link from 'next/link'
9
+ import { Typography, Button, Box, SxProps, Theme, Link } from '@mui/material'
10
+ import PageLink from 'next/link'
11
11
  import React, { useState } from 'react'
12
- import ProductReviewChip from '../ProductReviewChip'
12
+ import { ProductReviewChip } from '../ProductReviewChip/ProductReviewChip'
13
13
  import { ProductReviewsFragment } from './ProductReviews.gql'
14
14
  import { ProductReviewsPageDocument } from './ProductReviewsPage.gql'
15
15
 
@@ -32,7 +32,7 @@ const parts = [
32
32
  ] as const
33
33
  const { classes } = extendableComponent(name, parts)
34
34
 
35
- export default function ProductReviews(props: ProductReviewsProps) {
35
+ export function ProductReviews(props: ProductReviewsProps) {
36
36
  const { reviews, url_key, sx = [] } = props
37
37
  const config = 'en_US'
38
38
  const locale = config.replace('_', '-')
@@ -74,7 +74,7 @@ export default function ProductReviews(props: ProductReviewsProps) {
74
74
  marginTop: theme.spacings.sm,
75
75
  })}
76
76
  >
77
- <Link href={`/account/reviews/add?url_key=${url_key}`} passHref>
77
+ <PageLink href={`/account/reviews/add?url_key=${url_key}`} passHref>
78
78
  <Button
79
79
  variant='pill'
80
80
  color='primary'
@@ -88,7 +88,7 @@ export default function ProductReviews(props: ProductReviewsProps) {
88
88
  >
89
89
  <Trans>Write a review</Trans>
90
90
  </Button>
91
- </Link>
91
+ </PageLink>
92
92
 
93
93
  {!!total_pages && total_pages > 1 && (
94
94
  <Pagination
@@ -99,20 +99,9 @@ export default function ProductReviews(props: ProductReviewsProps) {
99
99
  margin: `0 -16px 0`,
100
100
  }}
101
101
  renderLink={(p: number, icon: React.ReactNode) => (
102
- <Button
103
- onClick={() => setPage(p)}
104
- className={classes.paginationButton}
105
- sx={{
106
- padding: 0,
107
- minWidth: 'unset',
108
- borderRadius: '100%',
109
- '& > .MuiButton-label': {
110
- padding: 0,
111
- },
112
- }}
113
- >
102
+ <Link color='inherit' underline='hover' onClick={() => setPage(p)}>
114
103
  {icon}
115
- </Button>
104
+ </Link>
116
105
  )}
117
106
  />
118
107
  )}
@@ -148,7 +137,9 @@ export default function ProductReviews(props: ProductReviewsProps) {
148
137
  alignItems: 'center',
149
138
  })}
150
139
  >
151
- <Typography variant='subtitle1'>Be the first to write a review!</Typography>
140
+ <Typography variant='subtitle1'>
141
+ <Trans>Be the first to write a review!</Trans>
142
+ </Typography>
152
143
  </Box>
153
144
  </Box>
154
145
  {actions}
@@ -187,7 +178,7 @@ export default function ProductReviews(props: ProductReviewsProps) {
187
178
  alignItems: 'center',
188
179
  })}
189
180
  >
190
- <ProductReviewChip rating={review?.average_rating} size='small' />
181
+ <ProductReviewChip rating={review?.average_rating} />
191
182
  <Typography component='h3' variant='h5'>
192
183
  {review?.summary}
193
184
  </Typography>
@@ -241,7 +232,7 @@ export default function ProductReviews(props: ProductReviewsProps) {
241
232
  })}
242
233
  >
243
234
  <Box className={classes.nickname} sx={{ typography: 'body2' }}>
244
- Written by {review?.nickname}
235
+ <Trans>Written by</Trans> {review?.nickname}
245
236
  </Box>
246
237
  <Box
247
238
  component='time'
@@ -1,18 +1,15 @@
1
- export { default as AccountReviews } from './AccountReviews'
2
- export { default as CreateProductReviewForm } from './CreateProductReviewForm'
3
- export { default as CustomerReview } from './CustomerReview'
4
- export { default as ProductReviews } from './ProductReviews'
5
- export { default as ProductReviewChip } from './ProductReviewChip'
6
- export { default as ProductReviewSummary } from './ProductReviewSummary'
7
-
1
+ export * from './AccountReviews/AccountReviews'
8
2
  export * from './AccountReviews/AccountReviews.gql'
9
- export * from './ProductReviews'
10
- export * from './CustomerReview/CustomerReview.gql'
11
- export * from './ProductReviewSummary/ProductReviewSummary.gql'
12
- export * from './ProductReviewChip/ProductReviewSummaryChip.gql'
13
- export * from './ProductReviews/ProductReviewProductName.gql'
14
3
  export * from './CreateProductReviewForm/CreateProductReview.gql'
4
+ export * from './CreateProductReviewForm/CreateProductReviewForm'
15
5
  export * from './CreateProductReviewForm/ProductReviewRatingsMetadata.gql'
16
-
6
+ export * from './CustomerReview/CustomerReview'
7
+ export * from './CustomerReview/CustomerReview.gql'
8
+ export * from './JsonLdProductReview/jsonLdProductReview'
17
9
  export * from './JsonLdProductReview/JsonLdProductReview.gql'
18
- export * from './JsonLdProductReview'
10
+ export * from './ProductReviewChip/ProductReviewChip'
11
+ export * from './ProductReviewChip/ProductReviewSummaryChip.gql'
12
+ export * from './ProductReviews/ProductReviewProductName.gql'
13
+ export * from './ProductReviews/ProductReviews'
14
+ export * from './ProductReviewSummary/ProductReviewSummary'
15
+ export * from './ProductReviewSummary/ProductReviewSummary.gql'
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@graphcommerce/magento-review",
3
3
  "homepage": "https://www.graphcommerce.org/",
4
4
  "repository": "github:graphcommerce-org/graphcommerce",
5
- "version": "3.0.5",
5
+ "version": "3.1.0",
6
6
  "sideEffects": false,
7
7
  "prettier": "@graphcommerce/prettier-config-pwa",
8
8
  "eslintConfig": {
@@ -12,19 +12,19 @@
12
12
  }
13
13
  },
14
14
  "devDependencies": {
15
- "@graphcommerce/eslint-config-pwa": "^4.0.4",
16
- "@graphcommerce/prettier-config-pwa": "^4.0.2",
15
+ "@graphcommerce/eslint-config-pwa": "^4.0.5",
16
+ "@graphcommerce/prettier-config-pwa": "^4.0.3",
17
17
  "@graphcommerce/typescript-config-pwa": "^4.0.2",
18
- "@playwright/test": "^1.19.1"
18
+ "@playwright/test": "^1.19.2"
19
19
  },
20
20
  "dependencies": {
21
- "@graphcommerce/graphql": "^3.0.3",
22
- "@graphcommerce/image": "^3.1.0",
23
- "@graphcommerce/magento-customer": "^4.1.3",
24
- "@graphcommerce/magento-product": "^4.0.5",
25
- "@graphcommerce/magento-store": "^4.1.0",
26
- "@graphcommerce/next-ui": "^4.2.0",
27
- "@graphcommerce/react-hook-form": "^3.0.3",
21
+ "@graphcommerce/graphql": "^3.0.4",
22
+ "@graphcommerce/image": "^3.1.1",
23
+ "@graphcommerce/magento-customer": "^4.1.5",
24
+ "@graphcommerce/magento-product": "^4.1.0",
25
+ "@graphcommerce/magento-store": "^4.1.3",
26
+ "@graphcommerce/next-ui": "^4.3.0",
27
+ "@graphcommerce/react-hook-form": "^3.0.4",
28
28
  "schema-dts": "^1.1.0"
29
29
  },
30
30
  "peerDependencies": {