Commit 7e93191
refactor: migrate Button and Accordion to macaw-ui-next, delete legacy filter ui (#6922)
* refactor: migrate Button and Accordion to macaw-ui-next
Replace the last Material-UI / legacy macaw-ui `Button`, `Accordion` and
`AccordionSummary` usages with their macaw-ui-next equivalents.
Legacy macaw `Button` defaulted to `variant="tertiary"`; macaw-ui-next
defaults to `primary`, so bare `<Button>` call sites now pass the variant
explicitly to keep their appearance.
`components/Button/Button` existed only to turn `href` into a react-router
`Link`. Its single consumer (NotFoundPage) always received internal URLs,
so the wrapper is dropped in favour of `as={Link}`.
FilterContent's accordion now relies on Radix single+collapsible behaviour,
which removes the manual open/close handler and the two makeStyles blocks
that only existed to strip Material-UI's default styling.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* fix: use secondary variant for migrated legacy Buttons
Screenshot comparison against main showed legacy macaw's default
variant ("tertiary") renders as a bordered button, not a borderless one.
macaw-ui-next's "tertiary" has no border, so the first pass silently
flattened Remove/Unassign/Edit/Discard into bare text. "secondary" is
the bordered equivalent.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* refactor: remove the legacy filter-select UI
Every <ListFilters> call site passes type="expression-filter", so the
"old-filter-select" branch — FiltersSelect and the FilterContent tree
below it — has been unreachable since the expression filters rollout
finished. Last functional change to it was #1995 (Apr 2022); everything
after that was sweeping refactors.
knip does not flag this on its own: .knip.json sets storybook and jest as
entry points, so the tree's own stories and tests kept it alive in the
graph. Deleting those first and re-running knip to convergence yields the
24 files removed here, including Alert/InlineAlert whose only consumer
was FilterErrorsList.
Filter/types.ts and Filter/utils.ts stay: list views still build a
filterStructure and pass filterDependency into their datagrids.
FilterProps loses its export for the same reason — nothing imports it now
that ListFilters is single-shape, but FilterPageProps still extends it.
Verified: tsc clean, knip clean, and all nine list pages render their
filter bar with no page errors.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
* chore: extract messages, drop orphaned filter types, add changeset
Removing the legacy filter UI orphaned 12 translation messages (key-value
field labels, filter range separators, filter validation errors) — dropped
by re-running extract-messages. The live Filters button keeps its own id
(FNpv6K) and is unaffected.
ValidationErrorCode and InvalidFilters only surfaced as unused once the
commit hook stripped the now-dead imports from Filter/utils.ts, so knip
caught them a round late.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>1 parent c1315d4 commit 7e93191
49 files changed
Lines changed: 70 additions & 2290 deletions
File tree
- .changeset
- locale
- src
- attributes/components/AttributeListPage
- collections/components/CollectionListPage
- components
- Alert
- AppLayout/ListFilters
- components
- Button
- CardTitle
- Filter
- FilterContent
- NotFoundPage
- discounts/components/VoucherListPage
- giftCards/GiftCardsList/GiftCardListSearchAndFilters
- orders/components
- OrderDraftListPage
- OrderListPage
- OrderSendRefundPage/components
- permissionGroups/views/PermissionGroupDetails
- productTypes/components/ProductTypeListPage
- products/components
- ProductExportDialog
- ProductListPage
- shipping/views
- staff/components/StaffListPage
- structures/views/MenuList
- translations/components
- TranslationFieldRow
- TranslationFields
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1308 | 1308 | | |
1309 | 1309 | | |
1310 | 1310 | | |
1311 | | - | |
1312 | | - | |
1313 | | - | |
1314 | | - | |
1315 | 1311 | | |
1316 | 1312 | | |
1317 | 1313 | | |
| |||
5238 | 5234 | | |
5239 | 5235 | | |
5240 | 5236 | | |
5241 | | - | |
5242 | | - | |
5243 | | - | |
5244 | | - | |
5245 | 5237 | | |
5246 | 5238 | | |
5247 | 5239 | | |
| |||
5296 | 5288 | | |
5297 | 5289 | | |
5298 | 5290 | | |
5299 | | - | |
5300 | | - | |
5301 | | - | |
5302 | | - | |
5303 | 5291 | | |
5304 | 5292 | | |
5305 | 5293 | | |
| |||
5415 | 5403 | | |
5416 | 5404 | | |
5417 | 5405 | | |
5418 | | - | |
5419 | | - | |
5420 | | - | |
5421 | | - | |
5422 | 5406 | | |
5423 | 5407 | | |
5424 | 5408 | | |
| |||
7255 | 7239 | | |
7256 | 7240 | | |
7257 | 7241 | | |
7258 | | - | |
7259 | | - | |
7260 | | - | |
7261 | | - | |
7262 | 7242 | | |
7263 | 7243 | | |
7264 | 7244 | | |
| |||
7359 | 7339 | | |
7360 | 7340 | | |
7361 | 7341 | | |
7362 | | - | |
7363 | | - | |
7364 | | - | |
7365 | | - | |
7366 | 7342 | | |
7367 | 7343 | | |
7368 | 7344 | | |
| |||
7511 | 7487 | | |
7512 | 7488 | | |
7513 | 7489 | | |
7514 | | - | |
7515 | | - | |
7516 | | - | |
7517 | | - | |
7518 | 7490 | | |
7519 | 7491 | | |
7520 | 7492 | | |
| |||
8606 | 8578 | | |
8607 | 8579 | | |
8608 | 8580 | | |
8609 | | - | |
8610 | | - | |
8611 | | - | |
8612 | | - | |
8613 | 8581 | | |
8614 | 8582 | | |
8615 | 8583 | | |
| |||
9516 | 9484 | | |
9517 | 9485 | | |
9518 | 9486 | | |
9519 | | - | |
9520 | | - | |
9521 | | - | |
9522 | | - | |
9523 | 9487 | | |
9524 | 9488 | | |
9525 | 9489 | | |
| |||
11396 | 11360 | | |
11397 | 11361 | | |
11398 | 11362 | | |
11399 | | - | |
11400 | | - | |
11401 | | - | |
11402 | | - | |
11403 | 11363 | | |
11404 | 11364 | | |
11405 | 11365 | | |
| |||
14529 | 14489 | | |
14530 | 14490 | | |
14531 | 14491 | | |
14532 | | - | |
14533 | | - | |
14534 | | - | |
14535 | | - | |
14536 | 14492 | | |
14537 | 14493 | | |
14538 | 14494 | | |
| |||
17270 | 17226 | | |
17271 | 17227 | | |
17272 | 17228 | | |
17273 | | - | |
17274 | | - | |
17275 | | - | |
17276 | 17229 | | |
17277 | 17230 | | |
17278 | 17231 | | |
| |||
Lines changed: 1 addition & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
159 | 159 | | |
160 | 160 | | |
161 | 161 | | |
162 | | - | |
163 | | - | |
| 162 | + | |
164 | 163 | | |
165 | 164 | | |
166 | 165 | | |
| |||
Lines changed: 0 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
144 | 144 | | |
145 | 145 | | |
146 | 146 | | |
147 | | - | |
148 | 147 | | |
149 | 148 | | |
150 | 149 | | |
| |||
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
2 | | - | |
| 1 | + | |
3 | 2 | | |
4 | 3 | | |
5 | 4 | | |
6 | 5 | | |
7 | | - | |
8 | 6 | | |
9 | 7 | | |
10 | 8 | | |
11 | | - | |
12 | | - | |
| 9 | + | |
13 | 10 | | |
14 | 11 | | |
15 | 12 | | |
16 | 13 | | |
17 | 14 | | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
| 15 | + | |
32 | 16 | | |
33 | 17 | | |
34 | 18 | | |
35 | 19 | | |
36 | 20 | | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
47 | | - | |
48 | | - | |
49 | | - | |
50 | | - | |
51 | | - | |
52 | | - | |
53 | | - | |
54 | | - | |
55 | | - | |
56 | | - | |
57 | | - | |
58 | | - | |
59 | | - | |
60 | | - | |
61 | | - | |
62 | | - | |
63 | | - | |
64 | | - | |
65 | | - | |
66 | | - | |
67 | | - | |
68 | | - | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
69 | 35 | | |
70 | 36 | | |
71 | | - | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
72 | 40 | | |
73 | | - | |
74 | | - | |
75 | | - | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
76 | 45 | | |
77 | 46 | | |
Lines changed: 0 additions & 124 deletions
This file was deleted.
0 commit comments