@graphcommerce/magento-review 10.0.0-canary.72 → 10.0.1-canary.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,44 +1,12 @@
1
1
  # Change Log
2
2
 
3
- ## 10.0.0-canary.72
3
+ ## 10.0.1-canary.0
4
4
 
5
- ## 10.0.0-canary.71
6
-
7
- ## 10.0.0-canary.70
8
-
9
- ## 10.0.0-canary.69
10
-
11
- ## 10.0.0-canary.68
12
-
13
- ### Major Changes
14
-
15
- - [#2557](https://github.com/graphcommerce-org/graphcommerce/pull/2557) [`ceaadd8`](https://github.com/graphcommerce-org/graphcommerce/commit/ceaadd87f0648982a068a3b07b1fa149c9127f49) - ## Material UI v5 → v7 Migration
16
-
17
- This release upgrades Material UI from v5 to v7 with full CSS variables support. ([@paales](https://github.com/paales))
18
-
19
- ## 10.0.0-canary.67
20
-
21
- ## 10.0.0-canary.66
22
-
23
- ## 10.0.0-canary.65
24
-
25
- ## 10.0.0-canary.64
26
-
27
- ## 10.0.0-canary.63
28
-
29
- ## 10.0.0-canary.62
30
-
31
- ## 10.0.0-canary.61
32
-
33
- ## 10.0.0-canary.60
34
-
35
- ## 10.0.0-canary.59
36
-
37
- ## 10.0.0-canary.58
5
+ ### Patch Changes
38
6
 
39
- ## 10.0.0-canary.57
7
+ - [#2568](https://github.com/graphcommerce-org/graphcommerce/pull/2568) [`ddeaf5d`](https://github.com/graphcommerce-org/graphcommerce/commit/ddeaf5df2c1f3902a80738a547a703221e02170f) - Solve hydration erorr while loading reviews ([@paales](https://github.com/paales))
40
8
 
41
- ## 10.0.0-canary.56
9
+ ## 10.0.0
42
10
 
43
11
  ### Major Changes
44
12
 
@@ -118,117 +86,9 @@
118
86
  - `@mui/*` modern alias rewrites
119
87
  - Debug plugins (`CircularDependencyPlugin`, `DuplicatesPlugin`) ([@paales](https://github.com/paales))
120
88
 
121
- ## 9.1.0-canary.55
122
-
123
- ## 9.1.0-canary.54
124
-
125
- ## 9.1.0-canary.53
126
-
127
- ## 9.1.0-canary.52
128
-
129
- ## 9.1.0-canary.51
130
-
131
- ## 9.1.0-canary.50
132
-
133
- ## 9.1.0-canary.49
134
-
135
- ## 9.1.0-canary.48
136
-
137
- ## 9.1.0-canary.47
138
-
139
- ## 9.1.0-canary.46
140
-
141
- ## 9.1.0-canary.45
142
-
143
- ## 9.1.0-canary.44
144
-
145
- ## 9.1.0-canary.43
146
-
147
- ## 9.1.0-canary.42
148
-
149
- ## 9.1.0-canary.41
150
-
151
- ## 9.1.0-canary.40
152
-
153
- ## 9.1.0-canary.39
154
-
155
- ## 9.1.0-canary.38
156
-
157
- ## 9.1.0-canary.37
158
-
159
- ## 9.1.0-canary.36
160
-
161
- ## 9.1.0-canary.35
162
-
163
- ## 9.1.0-canary.34
164
-
165
- ## 9.1.0-canary.33
166
-
167
- ## 9.1.0-canary.32
168
-
169
- ## 9.1.0-canary.31
170
-
171
- ## 9.1.0-canary.30
172
-
173
- ## 9.1.0-canary.29
174
-
175
- ## 9.1.0-canary.28
176
-
177
- ## 9.1.0-canary.27
178
-
179
- ## 9.1.0-canary.26
180
-
181
- ## 9.1.0-canary.25
182
-
183
- ## 9.1.0-canary.24
184
-
185
- ## 9.1.0-canary.23
186
-
187
- ## 9.1.0-canary.22
188
-
189
- ## 9.1.0-canary.21
190
-
191
- ## 9.1.0-canary.20
192
-
193
- ## 9.1.0-canary.19
194
-
195
- ## 9.1.0-canary.18
196
-
197
- ## 9.1.0-canary.17
198
-
199
- ## 9.1.0-canary.16
200
-
201
- ## 9.1.0-canary.15
202
-
203
- ## 9.0.4-canary.14
204
-
205
- ## 9.0.4-canary.13
206
-
207
- ## 9.0.4-canary.12
208
-
209
- ## 9.0.4-canary.11
210
-
211
- ## 9.0.4-canary.10
212
-
213
- ## 9.0.4-canary.9
214
-
215
- ## 9.0.4-canary.8
216
-
217
- ## 9.0.4-canary.7
218
-
219
- ## 9.0.4-canary.6
220
-
221
- ## 9.0.4-canary.5
222
-
223
- ## 9.0.4-canary.4
224
-
225
- ## 9.0.4-canary.3
226
-
227
- ## 9.0.4-canary.2
228
-
229
- ## 9.0.4-canary.1
89
+ - [#2557](https://github.com/graphcommerce-org/graphcommerce/pull/2557) [`ceaadd8`](https://github.com/graphcommerce-org/graphcommerce/commit/ceaadd87f0648982a068a3b07b1fa149c9127f49) - ## Material UI v5 → v7 Migration
230
90
 
231
- ## 9.0.4-canary.0
91
+ This release upgrades Material UI from v5 to v7 with full CSS variables support. ([@paales](https://github.com/paales))
232
92
 
233
93
  ## 9.0.0
234
94
 
@@ -41,7 +41,7 @@ export function ProductReviews(props: ProductReviewsProps) {
41
41
 
42
42
  const [reviewPage, setPage] = useState<number>(1)
43
43
 
44
- const { data: otherReviewsPage, loading } = useQuery(ProductReviewsPageDocument, {
44
+ const { data: otherReviewsPage } = useQuery(ProductReviewsPageDocument, {
45
45
  skip: reviewPage === 1,
46
46
  variables: {
47
47
  urlKey: url_key ?? '',
@@ -142,96 +142,95 @@ export function ProductReviews(props: ProductReviewsProps) {
142
142
  className={classes.container}
143
143
  sx={sxx((theme) => ({ marginTop: `calc(${theme.spacings.xxs} * -1)` }), sx)}
144
144
  >
145
- {!loading &&
146
- myReviews.items.map((review) => (
145
+ {myReviews.items.map((review) => (
146
+ <Box
147
+ key={review?.summary}
148
+ className={classes.review}
149
+ sx={(theme) => ({
150
+ display: 'grid',
151
+ gap: theme.spacings.sm,
152
+ borderBottom: `1px solid ${theme.vars.palette.divider}`,
153
+ padding: `${theme.spacings.md} 0`,
154
+ typography: 'body1',
155
+ })}
156
+ >
147
157
  <Box
148
- key={review?.summary}
149
- className={classes.review}
158
+ className={classes.title}
150
159
  sx={(theme) => ({
151
160
  display: 'grid',
152
- gap: theme.spacings.sm,
153
- borderBottom: `1px solid ${theme.vars.palette.divider}`,
154
- padding: `${theme.spacings.md} 0`,
155
- typography: 'body1',
161
+ gridAutoFlow: 'column',
162
+ justifyContent: 'start',
163
+ gap: theme.spacings.xs,
164
+ alignItems: 'center',
156
165
  })}
157
166
  >
167
+ <ProductReviewChip rating={review?.average_rating} />
168
+ <Typography component='h3' variant='h5'>
169
+ {review?.summary}
170
+ </Typography>
171
+ </Box>
172
+ <Typography variant='body1'>{review?.text}</Typography>
173
+
174
+ {(review?.ratings_breakdown.length ?? 0) > 1 && (
158
175
  <Box
159
- className={classes.title}
176
+ className={classes.ratingRow}
160
177
  sx={(theme) => ({
161
- display: 'grid',
162
- gridAutoFlow: 'column',
163
- justifyContent: 'start',
164
- gap: theme.spacings.xs,
165
- alignItems: 'center',
178
+ display: 'flex',
179
+ flexWrap: 'wrap',
180
+ gap: theme.spacings.sm,
181
+ color: theme.vars.palette.text.disabled,
182
+ typography: 'body2',
166
183
  })}
167
184
  >
168
- <ProductReviewChip rating={review?.average_rating} />
169
- <Typography component='h3' variant='h5'>
170
- {review?.summary}
171
- </Typography>
185
+ {review?.ratings_breakdown.map((ratingBreakdown) => (
186
+ <Box
187
+ key={`rating-${ratingBreakdown?.value}`}
188
+ className={classes.rating}
189
+ sx={(theme) => ({
190
+ display: 'grid',
191
+ gridAutoFlow: 'column',
192
+ gridTemplateColumns: '0.4fr 0.6fr',
193
+ justifyContent: 'space-between',
194
+ marginRight: theme.spacings.xxs,
195
+ rowGap: responsiveVal(8, 16),
196
+ gap: 8,
197
+ alignItems: 'center',
198
+ })}
199
+ >
200
+ <span>{ratingBreakdown?.name}</span>
201
+ <StarRatingField
202
+ readOnly
203
+ size='small'
204
+ defaultValue={Number(ratingBreakdown?.value ?? 0)}
205
+ />
206
+ </Box>
207
+ ))}
172
208
  </Box>
173
- <Typography variant='body1'>{review?.text}</Typography>
174
-
175
- {(review?.ratings_breakdown.length ?? 0) > 1 && (
176
- <Box
177
- className={classes.ratingRow}
178
- sx={(theme) => ({
179
- display: 'flex',
180
- flexWrap: 'wrap',
181
- gap: theme.spacings.sm,
182
- color: theme.vars.palette.text.disabled,
183
- typography: 'body2',
184
- })}
185
- >
186
- {review?.ratings_breakdown.map((ratingBreakdown) => (
187
- <Box
188
- key={`rating-${ratingBreakdown?.value}`}
189
- className={classes.rating}
190
- sx={(theme) => ({
191
- display: 'grid',
192
- gridAutoFlow: 'column',
193
- gridTemplateColumns: '0.4fr 0.6fr',
194
- justifyContent: 'space-between',
195
- marginRight: theme.spacings.xxs,
196
- rowGap: responsiveVal(8, 16),
197
- gap: 8,
198
- alignItems: 'center',
199
- })}
200
- >
201
- <span>{ratingBreakdown?.name}</span>
202
- <StarRatingField
203
- readOnly
204
- size='small'
205
- defaultValue={Number(ratingBreakdown?.value ?? 0)}
206
- />
207
- </Box>
208
- ))}
209
- </Box>
210
- )}
209
+ )}
211
210
 
211
+ <Box
212
+ className={classes.meta}
213
+ sx={(theme) => ({
214
+ color: theme.vars.palette.text.disabled,
215
+ display: 'grid',
216
+ gridAutoFlow: 'column',
217
+ justifyContent: 'space-between',
218
+ })}
219
+ >
220
+ <Box className={classes.nickname} sx={{ typography: 'body2' }}>
221
+ <Trans>Written by {review?.nickname}</Trans>
222
+ </Box>
212
223
  <Box
213
- className={classes.meta}
214
- sx={(theme) => ({
215
- color: theme.vars.palette.text.disabled,
216
- display: 'grid',
217
- gridAutoFlow: 'column',
218
- justifyContent: 'space-between',
219
- })}
224
+ component='time'
225
+ className={classes.date}
226
+ dateTime={review?.created_at}
227
+ sx={{ typography: 'body2' }}
220
228
  >
221
- <Box className={classes.nickname} sx={{ typography: 'body2' }}>
222
- <Trans>Written by {review?.nickname}</Trans>
223
- </Box>
224
- <Box
225
- component='time'
226
- className={classes.date}
227
- dateTime={review?.created_at}
228
- sx={{ typography: 'body2' }}
229
- >
230
- <DateTimeFormat dateStyle='long' timeStyle='short' date={review?.created_at} />
231
- </Box>
229
+ <DateTimeFormat dateStyle='long' timeStyle='short' date={review?.created_at} />
232
230
  </Box>
233
231
  </Box>
234
- ))}
232
+ </Box>
233
+ ))}
235
234
  {actions}
236
235
  </Box>
237
236
  )
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": "10.0.0-canary.72",
5
+ "version": "10.0.1-canary.0",
6
6
  "sideEffects": false,
7
7
  "prettier": "@graphcommerce/prettier-config-pwa",
8
8
  "eslintConfig": {
@@ -18,18 +18,18 @@
18
18
  "typescript": "5.9.3"
19
19
  },
20
20
  "peerDependencies": {
21
- "@graphcommerce/ecommerce-ui": "^10.0.0-canary.72",
22
- "@graphcommerce/eslint-config-pwa": "^10.0.0-canary.72",
23
- "@graphcommerce/graphql": "^10.0.0-canary.72",
24
- "@graphcommerce/graphql-mesh": "^10.0.0-canary.72",
25
- "@graphcommerce/image": "^10.0.0-canary.72",
26
- "@graphcommerce/magento-customer": "^10.0.0-canary.72",
27
- "@graphcommerce/magento-product": "^10.0.0-canary.72",
28
- "@graphcommerce/magento-store": "^10.0.0-canary.72",
29
- "@graphcommerce/next-ui": "^10.0.0-canary.72",
30
- "@graphcommerce/prettier-config-pwa": "^10.0.0-canary.72",
31
- "@graphcommerce/react-hook-form": "^10.0.0-canary.72",
32
- "@graphcommerce/typescript-config-pwa": "^10.0.0-canary.72",
21
+ "@graphcommerce/ecommerce-ui": "^10.0.1-canary.0",
22
+ "@graphcommerce/eslint-config-pwa": "^10.0.1-canary.0",
23
+ "@graphcommerce/graphql": "^10.0.1-canary.0",
24
+ "@graphcommerce/graphql-mesh": "^10.0.1-canary.0",
25
+ "@graphcommerce/image": "^10.0.1-canary.0",
26
+ "@graphcommerce/magento-customer": "^10.0.1-canary.0",
27
+ "@graphcommerce/magento-product": "^10.0.1-canary.0",
28
+ "@graphcommerce/magento-store": "^10.0.1-canary.0",
29
+ "@graphcommerce/next-ui": "^10.0.1-canary.0",
30
+ "@graphcommerce/prettier-config-pwa": "^10.0.1-canary.0",
31
+ "@graphcommerce/react-hook-form": "^10.0.1-canary.0",
32
+ "@graphcommerce/typescript-config-pwa": "^10.0.1-canary.0",
33
33
  "@lingui/core": "^5",
34
34
  "@lingui/macro": "^5",
35
35
  "@lingui/react": "^5",