Commit 047cd36
authored
fix(registry): include unsuffixed logos in index, add logo SVG API (#48)
* fix(registry): include unsuffixed logos in index, add logo SVG API
The logos index was built with `name.endsWith("-logo")`, which silently
excluded every logo whose item name carries no suffix. All 35 AWS service
logos (aws-s3, aws-lambda, ...) were published and reachable but invisible
to logos-index.json and therefore to @tryelements/cli.
Filter on the `logo` category instead, excluding bundle items under
_bundles/. Type is not a reliable discriminator here: 28 individual logos
(docker, figma, linear, resend, ...) are typed registry:block.
Index: 171 -> 206, matching the 206 logo directories on disk.
SVG generation:
- Derive the list from logos-index.json so it cannot drift from the index
- Resolve module-level constants, string arrays rendered via .map(), and
sub-components returning static JSX. amp, antigravity, codex and zep
previously emitted raw JSX
- Reject output containing unresolved expressions instead of writing a
broken file and counting it as a success
- Clear the output directory so removed logos leave no stale files, while
still writing the historical `<slug>-logo.svg` names that are already
published
All 377 emitted files validate as XML.
Add /api/logos returning a logo as svg, json (viewBox, paths, monochrome)
or dataurl, and /api/logos/all for the whole catalog in one request, so
non-React consumers do not have to parse the JSX component source.
* chore(registry): rebuild manifests with all 206 logos1 parent 5ecc481 commit 047cd36
219 files changed
Lines changed: 4534 additions & 370 deletions
File tree
- public/r
- svg
- scripts
- src/app/api/logos
- all
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 | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
12 | 29 | | |
13 | 30 | | |
14 | 31 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
11 | 36 | | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
12 | 47 | | |
13 | 48 | | |
14 | 49 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| |||
Loading
Loading
Loading
Loading
Loading
Loading
0 commit comments