Commit Graph

6 Commits

Author SHA1 Message Date
Niklas Mischkulnig 0e6f52e99b Turbopack: fix bundle-analyzer for NFT change (#93363)
We have no testing infrastructure, unfortunately

<img width="2254" height="1260" alt="Bildschirmfoto 2026-05-28 um 20 29
58"
src="https://github.com/user-attachments/assets/a9f1b646-994d-4417-98d7-160ce5249032"
/>
2026-06-02 18:24:38 +02:00
Will Binns-Smith 39c6cbb208 bundle-analyzer: use <Select> and multiselect for top bar (#87254)
The top bar is getting quite wide with all of its button toggle groups.
This:

- Converts the Compressed/Uncompressed and Client/Server toggles to
shadcn `<Select>`s
- Adds a custom `<MultiSelect>` implementation since this is missing in
shadcn. This composes shadcn’s popovers and a series of checkboxes,
along with accessibility attributes and keyboard shortcuts.
- Uses this `<MultiSelect>` for the type filter
- Removes the divider between these since there aren’t any groups left
to divide

<img width="1547" height="719" alt="image"
src="https://github.com/user-attachments/assets/4041f6b7-2a47-4e17-b020-448ac0103740"
/>
2025-12-16 23:09:32 -08:00
Will Binns-Smith ec85895d74 bundle-analyzer: Show compressed sizes (#87093) 2025-12-16 05:49:54 +00:00
Will Binns-Smith 5099903e88 bundle-analyzer: add kbd shortcut labels and fix focus bugs (#87001)
- Adds decorated kbd-style shortcut labels to cue the user into using them
- Listens only for the appropriate OS or Ctrl key on Mac/Others
- Esc now clears and focuses the search field and the treemap focus
- Does not trigger in the case where the user has another element focused

![image.png](https://app.graphite.com/user-attachments/assets/6a85d1e7-a711-432d-86b0-f65c0b89de74.png)
2025-12-09 23:36:19 -08:00
Will Binns-Smith 585126e2b3 bundle-analyzer: Add sizes to treemap, status bar (#86966)
![CleanShot 2025-12-08 at 19.58.55@2x.png](https://app.graphite.com/user-attachments/assets/43f13844-abe2-4a1b-bbc4-764554ca6634.png)
2025-12-09 15:02:54 -08:00
Will Binns-Smith 617ead5753 Turbopack: Add bundle analyzer UI to next build --experimental-analyze (#85788)
This adds an interactive Treemap-style bundle analyzer app to the Next.js codebase and writes a copy to disk when `next build --experimental-analyze` is run.

* It's a separate app in `apps/bundle-analyzer` as `@next/bundle-analyzer-ui` that uses `output: 'export'` to export a purely static Next.js app
* These static resources are copied into Next.js's published `dist` directory in the `next` package itself. Users never depend on `@next/bundle-analyzer-ui`
* When users run `next build --experimental-analyze`, these static resources are copied into the user's `.next/diagnostics/analyze` along with the data payloads needed to visualize the user's app

In an upcoming PR, we'll add `next experimental-analyze` that will create analysis files without build artifacts, as well as optionally start a static file server.

Test Plan: Ran `next build --experimental-analyze` in a test app and ran a static file server to run it.
2025-11-14 15:50:42 -08:00