logomarks 0.0.0-stage → 1.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 +42 -0
- package/LICENSE +21 -0
- package/README.md +56 -2
- package/bin/logomarks.js +4 -0
- package/data/fonts/BricolageGrotesque-SemiBold.ttf +0 -0
- package/data/fonts/Cagliostro-Regular.ttf +0 -0
- package/data/fonts/Fraunces-SemiBold.ttf +0 -0
- package/data/fonts/IBMPlexMono-Regular.ttf +0 -0
- package/data/fonts/IBMPlexMono-SemiBold.ttf +0 -0
- package/data/fonts/InstrumentSans-SemiBold.ttf +0 -0
- package/data/fonts/InstrumentSerif-Regular.ttf +0 -0
- package/data/fonts/Inter-SemiBold.ttf +0 -0
- package/data/fonts/Limelight-Regular.ttf +0 -0
- package/data/fonts/OFL.txt +103 -0
- package/data/fonts/Shrikhand-Regular.ttf +0 -0
- package/data/fonts/SpaceGrotesk-SemiBold.ttf +0 -0
- package/data/index.bin +0 -0
- package/docs/api.md +31 -0
- package/docs/commands.md +412 -0
- package/docs/editing.md +61 -0
- package/docs/mcp.md +45 -0
- package/package.json +94 -4
- package/src/brand/brand.d.ts +23 -0
- package/src/brand/brand.js +29 -0
- package/src/brand/fonts.d.ts +61 -0
- package/src/brand/fonts.js +93 -0
- package/src/brand/mark.d.ts +53 -0
- package/src/brand/mark.js +151 -0
- package/src/checks/finding.d.ts +56 -0
- package/src/checks/finding.js +57 -0
- package/src/checks/fit.d.ts +5 -0
- package/src/checks/fit.js +46 -0
- package/src/checks/index.d.ts +33 -0
- package/src/checks/index.js +57 -0
- package/src/checks/specks.d.ts +5 -0
- package/src/checks/specks.js +38 -0
- package/src/checks/widths.d.ts +7 -0
- package/src/checks/widths.js +48 -0
- package/src/cli/args.d.ts +20 -0
- package/src/cli/args.js +35 -0
- package/src/cli/commands/check.d.ts +10 -0
- package/src/cli/commands/check.js +66 -0
- package/src/cli/commands/combine.d.ts +10 -0
- package/src/cli/commands/combine.js +54 -0
- package/src/cli/commands/cover.d.ts +10 -0
- package/src/cli/commands/cover.js +53 -0
- package/src/cli/commands/edit.d.ts +10 -0
- package/src/cli/commands/edit.js +70 -0
- package/src/cli/commands/find.d.ts +10 -0
- package/src/cli/commands/find.js +61 -0
- package/src/cli/commands/get.d.ts +10 -0
- package/src/cli/commands/get.js +57 -0
- package/src/cli/commands/glitch.d.ts +10 -0
- package/src/cli/commands/glitch.js +57 -0
- package/src/cli/commands/index.d.ts +15 -0
- package/src/cli/commands/index.js +24 -0
- package/src/cli/commands/kit.d.ts +10 -0
- package/src/cli/commands/kit.js +66 -0
- package/src/cli/commands/mcp.d.ts +9 -0
- package/src/cli/commands/mcp.js +36 -0
- package/src/cli/commands/mockup.d.ts +10 -0
- package/src/cli/commands/mockup.js +61 -0
- package/src/cli/commands/parts.d.ts +10 -0
- package/src/cli/commands/parts.js +44 -0
- package/src/cli/commands/sheet.d.ts +10 -0
- package/src/cli/commands/sheet.js +66 -0
- package/src/cli/commands/similar.d.ts +10 -0
- package/src/cli/commands/similar.js +111 -0
- package/src/cli/commands/social.d.ts +10 -0
- package/src/cli/commands/social.js +65 -0
- package/src/cli/commands/specks.d.ts +20 -0
- package/src/cli/commands/specks.js +103 -0
- package/src/cli/edited.d.ts +6 -0
- package/src/cli/edited.js +32 -0
- package/src/cli/files.d.ts +4 -0
- package/src/cli/files.js +27 -0
- package/src/cli/help.d.ts +20 -0
- package/src/cli/help.js +55 -0
- package/src/cli/index.d.ts +10 -0
- package/src/cli/index.js +104 -0
- package/src/cli/options.d.ts +30 -0
- package/src/cli/options.js +155 -0
- package/src/cli/report.d.ts +4 -0
- package/src/cli/report.js +28 -0
- package/src/cli/style.d.ts +4 -0
- package/src/cli/style.js +34 -0
- package/src/cover/index.d.ts +49 -0
- package/src/cover/index.js +63 -0
- package/src/edit/combine.d.ts +31 -0
- package/src/edit/combine.js +103 -0
- package/src/edit/doc.d.ts +34 -0
- package/src/edit/doc.js +96 -0
- package/src/edit/glitch.d.ts +48 -0
- package/src/edit/glitch.js +43 -0
- package/src/edit/index.d.ts +8 -0
- package/src/edit/index.js +11 -0
- package/src/edit/ops.d.ts +51 -0
- package/src/edit/ops.js +90 -0
- package/src/edit/preview.d.ts +8 -0
- package/src/edit/preview.js +51 -0
- package/src/find/index.d.ts +54 -0
- package/src/find/index.js +88 -0
- package/src/index.d.ts +30 -0
- package/src/index.js +28 -0
- package/src/kit/index.d.ts +26 -0
- package/src/kit/index.js +31 -0
- package/src/mcp/content.d.ts +30 -0
- package/src/mcp/content.js +56 -0
- package/src/mcp/edited.d.ts +5 -0
- package/src/mcp/edited.js +25 -0
- package/src/mcp/index.d.ts +41 -0
- package/src/mcp/index.js +72 -0
- package/src/mcp/inputs.d.ts +46 -0
- package/src/mcp/inputs.js +122 -0
- package/src/mcp/preview.d.ts +4 -0
- package/src/mcp/preview.js +24 -0
- package/src/mcp/tools/check.d.ts +15 -0
- package/src/mcp/tools/check.js +47 -0
- package/src/mcp/tools/combine.d.ts +15 -0
- package/src/mcp/tools/combine.js +42 -0
- package/src/mcp/tools/cover.d.ts +20 -0
- package/src/mcp/tools/cover.js +46 -0
- package/src/mcp/tools/edit.d.ts +21 -0
- package/src/mcp/tools/edit.js +73 -0
- package/src/mcp/tools/find.d.ts +14 -0
- package/src/mcp/tools/find.js +36 -0
- package/src/mcp/tools/get.d.ts +15 -0
- package/src/mcp/tools/get.js +44 -0
- package/src/mcp/tools/glitch.d.ts +12 -0
- package/src/mcp/tools/glitch.js +39 -0
- package/src/mcp/tools/index.d.ts +4 -0
- package/src/mcp/tools/index.js +23 -0
- package/src/mcp/tools/kit.d.ts +28 -0
- package/src/mcp/tools/kit.js +51 -0
- package/src/mcp/tools/mockup.d.ts +22 -0
- package/src/mcp/tools/mockup.js +51 -0
- package/src/mcp/tools/sheet.d.ts +15 -0
- package/src/mcp/tools/sheet.js +43 -0
- package/src/mcp/tools/similar.d.ts +13 -0
- package/src/mcp/tools/similar.js +42 -0
- package/src/mcp/tools/social.d.ts +5 -0
- package/src/mcp/tools/social.js +68 -0
- package/src/mockup/index.d.ts +52 -0
- package/src/mockup/index.js +152 -0
- package/src/raster/render.d.ts +30 -0
- package/src/raster/render.js +100 -0
- package/src/rules.d.ts +73 -0
- package/src/rules.js +139 -0
- package/src/sheet/card.d.ts +20 -0
- package/src/sheet/card.js +190 -0
- package/src/sheet/draw.d.ts +26 -0
- package/src/sheet/draw.js +94 -0
- package/src/sheet/grid.d.ts +2 -0
- package/src/sheet/grid.js +32 -0
- package/src/sheet/index.d.ts +31 -0
- package/src/sheet/index.js +47 -0
- package/src/sheet/theme.d.ts +8 -0
- package/src/sheet/theme.js +45 -0
- package/src/similar/folder.d.ts +20 -0
- package/src/similar/folder.js +66 -0
- package/src/similar/nearest.d.ts +32 -0
- package/src/similar/nearest.js +60 -0
- package/src/similar/signature.d.ts +12 -0
- package/src/similar/signature.js +42 -0
- package/src/similar/store.d.ts +67 -0
- package/src/similar/store.js +88 -0
- package/src/util/color.d.ts +2 -0
- package/src/util/color.js +23 -0
- package/src/util/files.d.ts +8 -0
- package/src/util/files.js +60 -0
- package/src/util/round.d.ts +2 -0
- package/src/util/round.js +14 -0
- package/src/util/version.d.ts +2 -0
- package/src/util/version.js +10 -0
package/docs/commands.md
ADDED
|
@@ -0,0 +1,412 @@
|
|
|
1
|
+
# Commands
|
|
2
|
+
|
|
3
|
+
```
|
|
4
|
+
logomarks <command> [arguments] [options]
|
|
5
|
+
logomarks <command> --help
|
|
6
|
+
```
|
|
7
|
+
|
|
8
|
+
A `<mark>` is a live slug or name (`hex-gem`, `"Hex Gem"`) or the path to your own `.svg`, fitted to the grid first. A miss suggests the closest slugs.
|
|
9
|
+
|
|
10
|
+
Every command takes `--json` (machine-readable output on stdout) and `-h, --help`. `logomarks --version` prints the version.
|
|
11
|
+
|
|
12
|
+
| Exit code | Meaning |
|
|
13
|
+
|---|---|
|
|
14
|
+
| 0 | OK: every mark passed, or the file was written. |
|
|
15
|
+
| 1 | A check failed (`check`, `similar`, `specks`, `sheet`, and an edit whose result fails a check), nothing matched (`find`), or the command failed (a file it can't read or write). |
|
|
16
|
+
| 2 | Usage: an unknown command or option, a missing argument, or a value out of range. |
|
|
17
|
+
|
|
18
|
+
Set `LOGOMARKS_DEBUG=1` to print the stack trace behind an exit 1.
|
|
19
|
+
|
|
20
|
+
- Find and get: [`find`](#find), [`get`](#get)
|
|
21
|
+
- Check: [`check`](#check), [`similar`](#similar), [`specks`](#specks), [`sheet`](#sheet)
|
|
22
|
+
- Edit: [`parts`](#parts), [`edit`](#edit), [`glitch`](#glitch), [`combine`](#combine)
|
|
23
|
+
- Build: [`kit`](#kit), [`social`](#social), [`mockup`](#mockup), [`cover`](#cover)
|
|
24
|
+
- Agents: [`mcp`](#mcp)
|
|
25
|
+
|
|
26
|
+
## find
|
|
27
|
+
|
|
28
|
+
Search the live set by words, style, tag, industry or letter.
|
|
29
|
+
|
|
30
|
+
```
|
|
31
|
+
logomarks find <words…> [options]
|
|
32
|
+
logomarks find [options]
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
It searches as logomarks.ai does: every word must match a mark's name, search words, industries, style, tags, mood, letter or description (synonyms, plurals, and UK and US trade names included), and the best fits come first. With no words or filters it lists every style, tag, mood and industry, with counts.
|
|
36
|
+
|
|
37
|
+
| Option | Default | |
|
|
38
|
+
|---|---|---|
|
|
39
|
+
| `--style <style>` | | One style: `bold`, `badge`, `letter`, `monogram`, `animal`, `iso`, `grid`, `glitch`, `line`, `modular`, `woven`, `detailed`, `inflated`, `organic`, `glyph`. |
|
|
40
|
+
| `--tag <tags>` | | Tags a mark must all have, comma-separated: `round`, `square`, `symmetric`, `radial`, `solid`, `light`, `wide`, `tall`, `letter`, `number`, `new`. |
|
|
41
|
+
| `--industry <id>` | | An industry it suits, e.g. `coffee-shop`, `fintech`, `law-firm`. `logomarks find` lists them all. |
|
|
42
|
+
| `--letter <char>` | | The letter or number a lettermark shows. |
|
|
43
|
+
| `--top <n>` | 20 | How many marks to list (1–500). |
|
|
44
|
+
|
|
45
|
+
Exit 1 when nothing matches.
|
|
46
|
+
|
|
47
|
+
```bash
|
|
48
|
+
logomarks find coffee
|
|
49
|
+
logomarks find calm hexagon --top 5
|
|
50
|
+
logomarks find --style letter --letter K --json
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
## get
|
|
54
|
+
|
|
55
|
+
Get a live mark's SVG, or a PNG of any mark.
|
|
56
|
+
|
|
57
|
+
```
|
|
58
|
+
logomarks get <mark> [-o file] [options]
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
The SVG is 512 × 512, the mark's longest side 448, centred, filled paths in `currentColor`. Live marks are CC0. Without `-o` the SVG goes to stdout.
|
|
62
|
+
|
|
63
|
+
| Option | Default | |
|
|
64
|
+
|---|---|---|
|
|
65
|
+
| `--color <hex>` | `currentColor` (SVG), black (PNG) | Paint it, e.g. `#ff5c3a`. |
|
|
66
|
+
| `--size <px>` | 512 | A PNG this many pixels square (16–4096). |
|
|
67
|
+
| `--format <svg \| png>` | from `-o`; `png` with `--size` | |
|
|
68
|
+
| `-o, --out <file>` | stdout | Write `.svg` or `.png`. A PNG needs `-o`. |
|
|
69
|
+
|
|
70
|
+
```bash
|
|
71
|
+
logomarks get hex-gem -o logo.svg
|
|
72
|
+
logomarks get "Hex Gem" --color '#ff5c3a' --size 512 -o logo.png
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
## check
|
|
76
|
+
|
|
77
|
+
Check SVG marks against the house rules.
|
|
78
|
+
|
|
79
|
+
```
|
|
80
|
+
logomarks check <file.svg | folder>… [options]
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
Each finding has an id, a severity, a message and a box `[x0, y0, x1, y1]` on the 512 canvas. Folders are expanded to the `.svg` files in them (not recursively).
|
|
84
|
+
|
|
85
|
+
| Option | Default | |
|
|
86
|
+
|---|---|---|
|
|
87
|
+
| `--fix` | off | Refit to the grid in place: the only automatic fix. |
|
|
88
|
+
| `--strict` | off | Count warnings as failures too. |
|
|
89
|
+
| `--ignore <ids>` | | Leave these finding ids out, e.g. `speck,uneven-gaps`. |
|
|
90
|
+
|
|
91
|
+
| Id | Severity | |
|
|
92
|
+
|---|---|---|
|
|
93
|
+
| `viewbox`, `size`, `centre`, `clipped` | error | `viewBox="0 0 512 512"`, longest side 448 (±0.5), centred, nothing outside the canvas. `--fix` refits. |
|
|
94
|
+
| `markup`, `empty` | error | Filled paths only: no groups, transforms, strokes, styles, masks, text or images. |
|
|
95
|
+
| `speck`, `sliver`, `pinhole` | error | Pieces under 60 square units, and holes under 30, left by booleans. Touch points, hairlines and repeated dots are left out. |
|
|
96
|
+
| `fill`, `precision` | warning | `currentColor`; one decimal place. `--fix` refits. |
|
|
97
|
+
| `thin`, `narrow-gap` | warning | Strokes or gaps under 10 units: they vanish or close up at 32 px. |
|
|
98
|
+
| `uneven-gaps` | warning | One gap width per mark (22), or a clear 1:2 ratio. |
|
|
99
|
+
|
|
100
|
+
```
|
|
101
|
+
✗ speck.svg 448 × 448 1 error
|
|
102
|
+
error speck A stray piece of 36.0 sq units. [253, 250, 259, 256]
|
|
103
|
+
! gap-10.svg 448 × 448 1 warning
|
|
104
|
+
warning uneven-gaps A gap 9.8 wide, against the mark's main gap of 21.8: keep one gap width (22), or a clear 1:2 ratio. [250.6, 24.1, 261.4, 487.9]
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
Exit 1 when any mark fails.
|
|
108
|
+
|
|
109
|
+
```bash
|
|
110
|
+
logomarks check mark.svg
|
|
111
|
+
logomarks check marks/ --fix
|
|
112
|
+
logomarks check out/*.svg --strict --json
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
## similar
|
|
116
|
+
|
|
117
|
+
Find the live marks nearest to yours, with scores.
|
|
118
|
+
|
|
119
|
+
```
|
|
120
|
+
logomarks similar <file.svg | folder>… [options]
|
|
121
|
+
logomarks similar --all <data dir> [-o similar.json]
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
Compares outlines, rotations and mirrors included. A score of 0.72 or more is too close (compare the two by eye: solid shapes often share an outline); 0.9 or more is a near-copy. The same trick as an existing mark is a copy even when it scores low, so look at the matches.
|
|
125
|
+
|
|
126
|
+
| Option | Default | |
|
|
127
|
+
|---|---|---|
|
|
128
|
+
| `--top <n>` | 5 | How many matches per mark. |
|
|
129
|
+
| `--letters` | off | Compare a badge's knocked-out letter instead of its outline (0.7 too close, 0.85 a near-copy). |
|
|
130
|
+
| `--against <dir>` | the bundled set | Compare with a folder of SVGs instead. |
|
|
131
|
+
| `--each` | off | Compare the candidates with each other too (marked `*`). |
|
|
132
|
+
| `--all <data dir>` | | Write every mark's 8 nearest for a whole set ("More like this"), from its `marks.json`, `descriptions.json` and `svg/`. |
|
|
133
|
+
| `-o, --out <file>` | stdout | Where `--all` writes. |
|
|
134
|
+
|
|
135
|
+
Exit 1 when any mark is a near-copy.
|
|
136
|
+
|
|
137
|
+
```bash
|
|
138
|
+
logomarks similar mark.svg
|
|
139
|
+
logomarks similar out/ --top 3 --each
|
|
140
|
+
logomarks similar badge.svg --letters --json
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
## specks
|
|
144
|
+
|
|
145
|
+
List every speck, sliver and pin-hole, with its box.
|
|
146
|
+
|
|
147
|
+
```
|
|
148
|
+
logomarks specks <file.svg | folder>… [options]
|
|
149
|
+
```
|
|
150
|
+
|
|
151
|
+
The set's speck review: pieces under `--piece` and holes under `--hole`, smallest first. Tiny, hairline, repeated and reviewed parts are left out unless `--all`. Render each hit large before changing anything: many small parts are meant.
|
|
152
|
+
|
|
153
|
+
| Option | Default | |
|
|
154
|
+
|---|---|---|
|
|
155
|
+
| `--piece <area>` | 60 | Report pieces smaller than this, in square units. |
|
|
156
|
+
| `--hole <area>` | 30 | Report holes smaller than this. |
|
|
157
|
+
| `--allow <slugs>` | | Marks whose small parts are meant, comma-separated. |
|
|
158
|
+
| `--all` | off | Report every small part, reviewed and repeated ones included. |
|
|
159
|
+
| `--raster` | off | Read each mark from the scanline raster instead of its outline. |
|
|
160
|
+
|
|
161
|
+
Exit 1 when anything is listed.
|
|
162
|
+
|
|
163
|
+
```bash
|
|
164
|
+
logomarks specks out/
|
|
165
|
+
logomarks specks mark.svg --piece 80 --json
|
|
166
|
+
```
|
|
167
|
+
|
|
168
|
+
## sheet
|
|
169
|
+
|
|
170
|
+
Draw review cards for marks, as one PNG.
|
|
171
|
+
|
|
172
|
+
```
|
|
173
|
+
logomarks sheet <file.svg | folder>… [-o sheet.png] [options]
|
|
174
|
+
```
|
|
175
|
+
|
|
176
|
+
Each card shows the mark large on dark and light with its findings boxed and numbered, at 32 and 16 px, and beside its three nearest live marks (amber: too close; red: a near-copy).
|
|
177
|
+
|
|
178
|
+
| Option | Default | |
|
|
179
|
+
|---|---|---|
|
|
180
|
+
| `-o, --out <file.png>` | `sheet.png` | The PNG to write. |
|
|
181
|
+
| `--strict` | off | Count warnings as failures too. |
|
|
182
|
+
| `--ignore <ids>` | | Leave these finding ids out. |
|
|
183
|
+
| `--plain` | off | A plain labelled grid instead of review cards. |
|
|
184
|
+
| `--cols <n>` | 8 | Columns in the plain grid. |
|
|
185
|
+
|
|
186
|
+
Exit 1 when any mark fails a check or is a near-copy.
|
|
187
|
+
|
|
188
|
+
```bash
|
|
189
|
+
logomarks sheet out/*.svg -o sheet.png
|
|
190
|
+
logomarks sheet out/ --plain --cols 6 -o batch.png
|
|
191
|
+
```
|
|
192
|
+
|
|
193
|
+
## parts
|
|
194
|
+
|
|
195
|
+
List a mark's parts by index, as `edit --ops` names them.
|
|
196
|
+
|
|
197
|
+
```
|
|
198
|
+
logomarks parts <mark> [-o parts.png]
|
|
199
|
+
```
|
|
200
|
+
|
|
201
|
+
Each part has its index in drawing order, its box and centre on the 512 canvas, its area (holes taken out), its holes and its tone.
|
|
202
|
+
|
|
203
|
+
| Option | Default | |
|
|
204
|
+
|---|---|---|
|
|
205
|
+
| `-o, --out <file.png>` | | Also draw the mark with every part boxed and numbered. |
|
|
206
|
+
|
|
207
|
+
```bash
|
|
208
|
+
logomarks parts quad-cove
|
|
209
|
+
logomarks parts mark.svg -o parts.png
|
|
210
|
+
```
|
|
211
|
+
|
|
212
|
+
## edit
|
|
213
|
+
|
|
214
|
+
Edit a mark by part, with a list of ops.
|
|
215
|
+
|
|
216
|
+
```
|
|
217
|
+
logomarks edit <mark> --ops '<json>' [-o out.svg]
|
|
218
|
+
logomarks edit <mark> --ops @ops.json [-o out.svg]
|
|
219
|
+
```
|
|
220
|
+
|
|
221
|
+
The ops run in order: `delete`, `move`, `rotate`, `scale`, `flip`, `round`, `offset`, `mirror`, `radial`, `union`, `subtract`, `color`, `tone`. Each op's settings are in [editing](editing.md). The result is fitted to the grid and checked; without `-o` the SVG goes to stdout and the checks to stderr.
|
|
222
|
+
|
|
223
|
+
| Option | Default | |
|
|
224
|
+
|---|---|---|
|
|
225
|
+
| `--ops <json \| @file>` | required | The ops as a JSON array, or `@` and a file holding one. |
|
|
226
|
+
| `-o, --out <file>` | stdout | Write `.svg`, or `.png` drawn at 512. |
|
|
227
|
+
|
|
228
|
+
Exit 1 when the result fails a check.
|
|
229
|
+
|
|
230
|
+
```bash
|
|
231
|
+
logomarks edit quad-cove --ops '[{"op":"delete","parts":[3]},{"op":"round","radius":18}]' -o mine.svg
|
|
232
|
+
logomarks edit mark.svg --ops @ops.json -o mine.png
|
|
233
|
+
```
|
|
234
|
+
|
|
235
|
+
## glitch
|
|
236
|
+
|
|
237
|
+
Make a glitch edition of a mark: cut with the house gap and slid.
|
|
238
|
+
|
|
239
|
+
```
|
|
240
|
+
logomarks glitch <mark> [--preset shear] [-o out.svg] [options]
|
|
241
|
+
```
|
|
242
|
+
|
|
243
|
+
The result is fitted and checked, and the same seed gives the same bytes. See [editing](editing.md) for the presets.
|
|
244
|
+
|
|
245
|
+
| Option | Default | |
|
|
246
|
+
|---|---|---|
|
|
247
|
+
| `--preset <name>` | `shear` | `shear`, `slice`, `bands`, `stepped`, `lane`. |
|
|
248
|
+
| `--seed <n>` | 1 | Places the cuts; another seed is a shuffle. |
|
|
249
|
+
| `--angle <deg>` | the mark's slope (`shear`), across the lanes (`lane`), else 0 | Cut direction, clockwise from across. |
|
|
250
|
+
| `--place <0–1>` | seeded | Where the first cut crosses the mark. |
|
|
251
|
+
| `--slide <units>` | 44 | How far the sides slide apart along the cut. |
|
|
252
|
+
| `--gap <units>` | 22 | The gap at each cut. |
|
|
253
|
+
| `--cuts <n>` | seeded | Cuts for `slice` (1–3), bands for `bands` (3–5). |
|
|
254
|
+
| `-o, --out <file>` | stdout | Write `.svg`, or `.png` drawn at 512. |
|
|
255
|
+
|
|
256
|
+
Exit 1 when the result fails a check: try another seed.
|
|
257
|
+
|
|
258
|
+
```bash
|
|
259
|
+
logomarks glitch quad-cove --preset shear --seed 3 -o glitched.svg
|
|
260
|
+
logomarks glitch mark.svg --preset bands --cuts 4 -o preview.png
|
|
261
|
+
```
|
|
262
|
+
|
|
263
|
+
## combine
|
|
264
|
+
|
|
265
|
+
Combine two marks into one.
|
|
266
|
+
|
|
267
|
+
```
|
|
268
|
+
logomarks combine <a> <b> [--op union] [-o out.svg] [options]
|
|
269
|
+
```
|
|
270
|
+
|
|
271
|
+
`b` is placed over `a` on the 512 canvas (both fitted first), then combined. The result is fitted and checked.
|
|
272
|
+
|
|
273
|
+
| Option | Default | |
|
|
274
|
+
|---|---|---|
|
|
275
|
+
| `--op <op>` | `union` | `union`, `subtract` (b cut out of a), `intersect`, `exclude` (where exactly one covers), `place` (both as they are). |
|
|
276
|
+
| `--scale <factor>` | 1 | Scale `b` about its own centre. |
|
|
277
|
+
| `--rotate <deg>` | 0 | Turn `b` clockwise about its own centre. |
|
|
278
|
+
| `--flip <axis>` | | Flip `b`: `horizontal` or `vertical`. |
|
|
279
|
+
| `--x <units>`, `--y <units>` | 0 | Move `b` across and down. |
|
|
280
|
+
| `-o, --out <file>` | stdout | Write `.svg`, or `.png` drawn at 512. |
|
|
281
|
+
|
|
282
|
+
Exit 1 when the result fails a check.
|
|
283
|
+
|
|
284
|
+
```bash
|
|
285
|
+
logomarks combine quad-cove shear-a --op subtract --scale 0.5 -o combined.svg
|
|
286
|
+
logomarks combine a.svg b.svg --op place --x 120 -o both.png
|
|
287
|
+
```
|
|
288
|
+
|
|
289
|
+
## kit
|
|
290
|
+
|
|
291
|
+
Build a brand kit on a mark and write it to a folder.
|
|
292
|
+
|
|
293
|
+
```
|
|
294
|
+
logomarks kit <mark> --name "Brand" [-o dir/] [options]
|
|
295
|
+
```
|
|
296
|
+
|
|
297
|
+
The kit, from [`@logomarks/brand-kit`](https://github.com/Logomarks/brand-kit):
|
|
298
|
+
|
|
299
|
+
- `mark/`: SVG on light, dark and colour, and one that follows dark mode; PNG 64–2048.
|
|
300
|
+
- `favicon/`: `favicon.ico`, `favicon.svg`, `apple-touch-icon.png`, any and maskable icons, `site.webmanifest`, `head.html`.
|
|
301
|
+
- `lockup/`: horizontal and stacked, on light, dark and colour, the name as outlines.
|
|
302
|
+
- `colors/`: `palette.css`, a Tailwind theme and design tokens: a 50–950 OKLCH scale with WCAG pairings.
|
|
303
|
+
- `social/`: the social pack, as [`social`](#social) makes it.
|
|
304
|
+
- `brand-sheet.png` and `.svg`, `brand.json` (the brand, the files, a live mark credited, CC0) and `README.md`.
|
|
305
|
+
|
|
306
|
+
A light brand colour gets a darker mark on light grounds (it must clear 3:1), and the text colours clear WCAG AA. Look at `brand-sheet.png` before handing the kit over.
|
|
307
|
+
|
|
308
|
+
| Option | Default | |
|
|
309
|
+
|---|---|---|
|
|
310
|
+
| `--name <text>` | the mark's name | The brand's name. |
|
|
311
|
+
| `--color <hex>` | `#d4ff3a` | The brand colour. |
|
|
312
|
+
| `--font <id>` | `inter` | The typeface for the name: `inter`, `space-grotesk`, `instrument-sans`, `bricolage-grotesque`, `instrument-serif`, `plex-mono`; for restaurants `fraunces` (warm serif: bistro, wine bar), `cagliostro` (flared sans, set wide: fine dining), `limelight` (art deco: cocktail bar), `shrikhand` (retro chunky: diner, brunch, ice cream). All SIL OFL, bundled. |
|
|
313
|
+
| `--tagline <text>` | | A short line under the name on social images and the brand sheet. |
|
|
314
|
+
| `--url <url>` | | The brand's website, for the brand sheet and the email signature. |
|
|
315
|
+
| `--handle <@name>` | `@` and the name | The social handle. |
|
|
316
|
+
| `--styles <ids>` | `minimal,bold,pattern` | Social styles: `minimal`, `bold`, `pattern`, and `gradient` (a grainy gradient of the brand colour) when asked for. |
|
|
317
|
+
| `--platforms <ids>` | every one | Social images by id (`x-header`) or platform (`instagram`). |
|
|
318
|
+
| `--animated` | off | Also write animated SVGs for avatars, stories and banners. |
|
|
319
|
+
| `--no-social` | off | Leave the social pack out. |
|
|
320
|
+
| `-o, --out <dir>` | `<name>-kit` | The folder to write; files in it are replaced. |
|
|
321
|
+
|
|
322
|
+
```bash
|
|
323
|
+
logomarks kit hex-gem --name "Hexa Labs" --color '#ff5c3a' --font space-grotesk -o hexa/
|
|
324
|
+
logomarks kit mark.svg --name Acme --no-social
|
|
325
|
+
```
|
|
326
|
+
|
|
327
|
+
## social
|
|
328
|
+
|
|
329
|
+
Draw the brand for every social platform at its size, and write it to a folder.
|
|
330
|
+
|
|
331
|
+
```
|
|
332
|
+
logomarks social <mark> --name "Brand" [-o dir/] [options]
|
|
333
|
+
```
|
|
334
|
+
|
|
335
|
+
Every platform image (Instagram, LinkedIn, X, YouTube, Facebook, TikTok, Twitch, Discord, Threads, Bluesky) at its current size, with the logo inside its safe zone, in each style as `<style>/<id>.png` and `.svg`; an email signature, the Open Graph card, and a README of sizes and sources.
|
|
336
|
+
|
|
337
|
+
Options: as [`kit`](#kit), without `--no-social`. `-o, --out <dir>` defaults to `<name>-social`.
|
|
338
|
+
|
|
339
|
+
```bash
|
|
340
|
+
logomarks social hex-gem --name "Hexa Labs" --platforms instagram,linkedin --styles bold
|
|
341
|
+
logomarks social mark.svg --name Acme --animated -o acme-social/
|
|
342
|
+
```
|
|
343
|
+
|
|
344
|
+
## mockup
|
|
345
|
+
|
|
346
|
+
Put a brand on an object and write the image.
|
|
347
|
+
|
|
348
|
+
```
|
|
349
|
+
logomarks mockup <mark> --object <object> [-o file.png] [options]
|
|
350
|
+
```
|
|
351
|
+
|
|
352
|
+
Objects, from [`@logomarks/mockups`](https://github.com/Logomarks/mockups), with their layouts (the first is the default): `card` (pair, flat, stack, fan), `letterhead` (set, flat, envelope), `ticket`, `lanyard`, `sticker` (laptop, bottle, sheet), `tote`, `tee`, `hoodie`, `cap`, `mug` (single, pair), `bag`, `box`, `poster`, `vinyl`, `cd`, `cassette`, `phone`, `laptop`, `billboard`, `shopfront`. Garments, mugs and bags carry the mark; prints carry the lockup on the brand colour.
|
|
353
|
+
|
|
354
|
+
| Option | Default | |
|
|
355
|
+
|---|---|---|
|
|
356
|
+
| `--object <id>` | required | The object. |
|
|
357
|
+
| `--name`, `--color`, `--font` | as [`kit`](#kit) | The brand. |
|
|
358
|
+
| `--layout <id>` | the object's first | One of the object's layouts. |
|
|
359
|
+
| `--surface <id>` | the object's own | What it lies on: `oak`, `concrete`, `linen`, `paper`, `light`, `dark`, or a hex colour. |
|
|
360
|
+
| `--view <front \| angle>` | `front` | A screen's or a sign's view. |
|
|
361
|
+
| `--base <colour>` | the object's own | The object's colour: `white`, `black`, `navy` or a hex for garments, mugs and bags; a box's board; a device's finish. |
|
|
362
|
+
| `--size <px>` | 1600 | The longest side, 200–4000. |
|
|
363
|
+
| `--seed <text>` | the mark's slug | Drives every random choice. |
|
|
364
|
+
| `-o, --out <file>` | `<object>.png` | Write `.png`, or `.svg` for the layered SVG. |
|
|
365
|
+
|
|
366
|
+
```bash
|
|
367
|
+
logomarks mockup hex-gem --name "Hexa Labs" --object card -o card.png
|
|
368
|
+
logomarks mockup mark.svg --object tee --base black -o tee.png
|
|
369
|
+
```
|
|
370
|
+
|
|
371
|
+
## cover
|
|
372
|
+
|
|
373
|
+
Draw a cover (an Open Graph image, a header or a post) with the mark on it.
|
|
374
|
+
|
|
375
|
+
```
|
|
376
|
+
logomarks cover <mark> [--recipe mark] [--title "…"] [-o cover.png] [options]
|
|
377
|
+
```
|
|
378
|
+
|
|
379
|
+
Recipes, from [`@arraypress/covers`](https://github.com/arraypress/covers): `mark`, `gradient`, `tile`, `stripes`, `aurora`, `grid`, `cutout`.
|
|
380
|
+
|
|
381
|
+
| Option | Default | |
|
|
382
|
+
|---|---|---|
|
|
383
|
+
| `--recipe <id>` | `mark` | The look. |
|
|
384
|
+
| `--title <text>` | | A headline; the mark moves out of its way. |
|
|
385
|
+
| `--label <text>` | | A small line over the title. |
|
|
386
|
+
| `--color <hex>` | `#d4ff3a` | The brand colour. |
|
|
387
|
+
| `--aspect <ratio>` | `og` | `og` (1200 × 630), `1:1`, `16:9`, `4:5`, `9:16`, any `w:h`, or a number. |
|
|
388
|
+
| `--width <px>` | 1200 | The width, 200–6000. |
|
|
389
|
+
| `--seed <text>` | the mark's slug | Drives every random choice. |
|
|
390
|
+
| `-o, --out <file>` | `cover.png` | Write `.png`, or `.svg` (text as outlines). |
|
|
391
|
+
|
|
392
|
+
```bash
|
|
393
|
+
logomarks cover hex-gem --recipe aurora --title "Introducing Hexa" -o cover.png
|
|
394
|
+
logomarks cover mark.svg --recipe stripes --aspect 1:1 -o post.png
|
|
395
|
+
```
|
|
396
|
+
|
|
397
|
+
## mcp
|
|
398
|
+
|
|
399
|
+
Run the MCP server on stdio, for Claude Code, Codex, Cursor and other agents.
|
|
400
|
+
|
|
401
|
+
```
|
|
402
|
+
logomarks mcp
|
|
403
|
+
```
|
|
404
|
+
|
|
405
|
+
Every command as an MCP tool, run locally: nothing leaves the machine. See [MCP tools](mcp.md).
|
|
406
|
+
|
|
407
|
+
```bash
|
|
408
|
+
claude mcp add logomarks -- npx -y logomarks mcp
|
|
409
|
+
codex mcp add logomarks -- npx -y logomarks mcp
|
|
410
|
+
```
|
|
411
|
+
|
|
412
|
+
PNGs are drawn by resvg in WebAssembly, so nothing needs `sharp` or a native build.
|
package/docs/editing.md
ADDED
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
# Editing
|
|
2
|
+
|
|
3
|
+
`glitch`, `edit` and `combine` (and the `glitch_mark`, `edit_mark` and `combine_marks` tools) run [`@logomarks/editor`](https://github.com/Logomarks/editor)'s operations without a page: curves are kept, booleans are exact, and the house gap is 22. Every result is fitted to the standard (longest side 448 on the 512 canvas, centred: @logomarks/core's `fitMark`) and run through every check, so a speck, sliver, pin-hole or stray gap a change leaves is reported with its box. The same input and seed give the same bytes.
|
|
4
|
+
|
|
5
|
+
## Glitch
|
|
6
|
+
|
|
7
|
+
| Preset | |
|
|
8
|
+
|---|---|
|
|
9
|
+
| `shear` | One cut along the mark's own slope, the sides slid apart. |
|
|
10
|
+
| `slice` | 1–3 parallel cuts, alternate bands slid. |
|
|
11
|
+
| `bands` | 3–5 bands across, each nudged by a seeded amount. |
|
|
12
|
+
| `stepped` | A stair-step cut, the sides slid apart. |
|
|
13
|
+
| `lane` | One cut across a Track mark's lanes, one side slid one lane (Track marks only). |
|
|
14
|
+
|
|
15
|
+
| Setting | Default | |
|
|
16
|
+
|---|---|---|
|
|
17
|
+
| `seed` | 1 | Places the cuts; another seed is a shuffle. |
|
|
18
|
+
| `angle` | the mark's slope (shear), across the lanes (lane), else 0 | Degrees, clockwise from across. |
|
|
19
|
+
| `place` | seeded | Where the first cut crosses, 0–1 across the mark. |
|
|
20
|
+
| `slide` | 44 | How far the sides end up apart along the cut. |
|
|
21
|
+
| `gap` | 22 | The gap at each cut. |
|
|
22
|
+
| `cuts` | seeded | Cuts for `slice` (1–3), bands for `bands` (3–5). |
|
|
23
|
+
|
|
24
|
+
A placement that would leave a speck or a sliver is nudged across, then reseeded. When none is clean the call fails with a message: try another seed.
|
|
25
|
+
|
|
26
|
+
## Edit
|
|
27
|
+
|
|
28
|
+
A list of ops, run in order. `parts` are indices from `parts` / `list_parts`, as they stand when the op runs (a delete renumbers what follows); leave it out for every part.
|
|
29
|
+
|
|
30
|
+
| Op | Settings | |
|
|
31
|
+
|---|---|---|
|
|
32
|
+
| `delete` | `parts` | Remove parts. |
|
|
33
|
+
| `move` | `dx`, `dy` | Move parts, in units. |
|
|
34
|
+
| `rotate` | `angle`, `about` | Degrees clockwise, about the parts' centre (or `[x, y]`). |
|
|
35
|
+
| `scale` | `by` (a factor or `[sx, sy]`), `about` | About the parts' centre. |
|
|
36
|
+
| `flip` | `axis` (`horizontal`, `vertical`), `about` | |
|
|
37
|
+
| `round` | `radius` | Every corner of the parts rounded; existing rounds are adjusted; 0 takes them out. |
|
|
38
|
+
| `offset` | `distance`, `join` (`miter`, `round`) | Grow (positive) or shrink (negative); curves kept. |
|
|
39
|
+
| `mirror` | `axis` (`vertical`, `horizontal`, `both`) | The whole mark reflected across the centre; overlaps are unioned. |
|
|
40
|
+
| `radial` | `count` | The whole mark repeated about the centre. |
|
|
41
|
+
| `union`, `subtract` | `parts` | Join parts into one; cut the rest out of the first. |
|
|
42
|
+
| `color` | `color` | Paint the whole mark (it is `currentColor` otherwise; the checks warn). |
|
|
43
|
+
| `tone` | `parts`, `color` | A second colour on the parts: `fill="var(--tone-2, #hex)"` beside `currentColor`. |
|
|
44
|
+
|
|
45
|
+
```json
|
|
46
|
+
[{ "op": "delete", "parts": [3] }, { "op": "round", "radius": 18 }, { "op": "tone", "parts": [0], "color": "#ff5c3a" }]
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
The live marks store their curves as short lines, so `round` has little room at a corner that is already rounded; it rounds real corners as asked.
|
|
50
|
+
|
|
51
|
+
## Combine
|
|
52
|
+
|
|
53
|
+
`b` is placed on `a`'s 512 canvas (both fitted first): `scale` and `rotate` about its own centre, `flip`, then moved by `x`, `y`. Then:
|
|
54
|
+
|
|
55
|
+
| Op | |
|
|
56
|
+
|---|---|
|
|
57
|
+
| `union` | Everything either covers. |
|
|
58
|
+
| `subtract` | `a` with `b` cut out. |
|
|
59
|
+
| `intersect` | Where both cover. |
|
|
60
|
+
| `exclude` | Where exactly one covers. |
|
|
61
|
+
| `place` | Both, as they are. |
|
package/docs/mcp.md
ADDED
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
# MCP tools
|
|
2
|
+
|
|
3
|
+
`logomarks mcp` runs the CLI's functions as MCP tools on stdio, locally: nothing leaves the machine. Relative paths resolve against the server's working folder (the project the agent is in). The renderer, the typefaces and the live set load once and stay warm.
|
|
4
|
+
|
|
5
|
+
```bash
|
|
6
|
+
claude mcp add logomarks -- npx -y logomarks mcp # Claude Code
|
|
7
|
+
codex mcp add logomarks -- npx -y logomarks mcp # Codex (or ~/.codex/config.toml → [mcp_servers.logomarks])
|
|
8
|
+
```
|
|
9
|
+
|
|
10
|
+
Or install the Claude Code plugin, which adds the server and the two Logomarks skills:
|
|
11
|
+
|
|
12
|
+
```
|
|
13
|
+
/plugin marketplace add logomarks/skills
|
|
14
|
+
/plugin install logomarks@logomarks
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
Any other MCP client: run `npx -y logomarks mcp` over stdio. The first run downloads the package, so allow a longer start-up timeout.
|
|
18
|
+
|
|
19
|
+
## Tools
|
|
20
|
+
|
|
21
|
+
| Tool | Use it to | Arguments | Returns |
|
|
22
|
+
|---|---|---|---|
|
|
23
|
+
| `find_marks` | Search the set for a mark to use or build on. | `query`, `style`, `tags`, `industry`, `letter`, `limit` (20) | `{ total, marks }`; with no arguments, every style, tag, mood and industry. |
|
|
24
|
+
| `get_mark` | Get a mark's SVG, a PNG to look at, or a file. | `mark`, `color`, `size`, `out` | `{ slug, name, url, licence, color, svg }`; `file` instead of `svg` with `out`; an image with `size`. |
|
|
25
|
+
| `check_mark` | Check marks against the house rules. | `svg` or `paths`, `svgName`, `fix`, `strict`, `ignore` | `{ ok, passed, failed, marks: [{ findings: [{ id, severity, message, box }] }] }`. |
|
|
26
|
+
| `similar_marks` | Find the live marks nearest to a new one. | `svg` or `paths`, `svgName`, `top` (5), `letters` | `{ ok, thresholds, marks: [{ matches: [{ slug, score, verdict }] }] }`. |
|
|
27
|
+
| `review_sheet` | Look at review cards before handing marks over. | `svg` or `paths`, `svgName`, `strict`, `ignore`, `out` | Each mark's check summary and nearest marks, and the cards as an image. |
|
|
28
|
+
| `list_parts` | See a mark's parts by index, before `edit_mark`. | `mark` or `svg` | `{ count, parts: [{ index, box, centre, area, holes, tone }] }`, and the parts numbered, as an image. |
|
|
29
|
+
| `edit_mark` | Edit a mark by part. | `mark` or `svg`, `ops`, `out` | `{ ok, parts, svg, checks }` (`file` instead of `svg` with `out`), and the result as an image. |
|
|
30
|
+
| `glitch_mark` | Make a glitch edition. | `mark` or `svg`, `preset`, `seed` (1), `angle`, `place`, `slide` (44), `gap` (22), `cuts`, `out` | `{ ok, glitch, svg, checks }` (`file` instead of `svg` with `out`), and the result as an image. |
|
|
31
|
+
| `combine_marks` | Make two marks one. | `a`, `b` (slug, path or SVG text), `op`, `transform: { scale, rotate, flip, x, y }`, `out` | `{ ok, svg, checks }` (`file` instead of `svg` with `out`), and the result as an image. |
|
|
32
|
+
| `build_brand_kit` | Set a chosen mark up as a brand. | `mark`, `name`, `color`, `font`, `tagline`, `url`, `handle`, `styles`, `platforms`, `animated`, `social` (true), `out` (`<name>-kit`) | Writes the folder; its path, the file count, `brand.json`, and the brand sheet as an image. |
|
|
33
|
+
| `build_social_pack` | Make every platform's profile images, banners and posts. | `mark`, `name`, `color`, `font`, `tagline`, `url`, `handle`, `platforms`, `styles`, `animated`, `out` (`<name>-social`) | Writes the folder; its path and files, and a preview of each style. |
|
|
34
|
+
| `render_mockup` | Show the brand on an object. | `mark`, `object`, `name`, `color`, `font`, `layout`, `surface`, `view`, `base`, `size` (1600), `seed`, `out` | A preview image (up to 800 px); `out` writes the full size. |
|
|
35
|
+
| `render_cover` | Make an Open Graph image, header or post. | `mark`, `recipe` (`mark`), `title`, `label`, `color`, `aspect` (`og`), `width` (1200), `seed`, `out` | A preview image (up to 800 px); `out` writes the full size. |
|
|
36
|
+
|
|
37
|
+
Every argument is described, with its type, choices and default, in the tool's input schema. The editing tools' settings and ops are in [editing](editing.md).
|
|
38
|
+
|
|
39
|
+
## Annotations
|
|
40
|
+
|
|
41
|
+
`find_marks`, `similar_marks` and `list_parts` are read-only. `check_mark` (with `fix`), `build_brand_kit` and `build_social_pack` are marked destructive: they rewrite files in place or replace files in a folder. The other tools write only when given `out`, and replace that file. No tool reaches the network (`openWorldHint: false`).
|
|
42
|
+
|
|
43
|
+
## Errors
|
|
44
|
+
|
|
45
|
+
A tool that fails returns a tool error (`isError`) with a message to act on: a missing mark comes with the closest slugs, an unknown part with how many the mark has, a missing file with its path.
|
package/package.json
CHANGED
|
@@ -1,6 +1,96 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "logomarks",
|
|
3
|
-
"version": "
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
|
|
3
|
+
"version": "1.1.0",
|
|
4
|
+
"description": "Find, check, edit and build on free geometric logomarks from the command line or an AI agent: search the CC0 Logomarks set, check marks against its house rules, edit and glitch them, and build a brand kit, social pack, mockups and covers. Includes an MCP server.",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"logo",
|
|
7
|
+
"logomark",
|
|
8
|
+
"logomarks",
|
|
9
|
+
"brand",
|
|
10
|
+
"brand-kit",
|
|
11
|
+
"svg",
|
|
12
|
+
"favicon",
|
|
13
|
+
"icon",
|
|
14
|
+
"mockup",
|
|
15
|
+
"og-image",
|
|
16
|
+
"social-media",
|
|
17
|
+
"design",
|
|
18
|
+
"cli",
|
|
19
|
+
"mcp",
|
|
20
|
+
"mcp-server",
|
|
21
|
+
"model-context-protocol",
|
|
22
|
+
"claude-code",
|
|
23
|
+
"codex",
|
|
24
|
+
"cursor",
|
|
25
|
+
"cc0"
|
|
26
|
+
],
|
|
27
|
+
"homepage": "https://logomarks.ai",
|
|
28
|
+
"repository": {
|
|
29
|
+
"type": "git",
|
|
30
|
+
"url": "git+https://github.com/Logomarks/cli.git"
|
|
31
|
+
},
|
|
32
|
+
"bugs": {
|
|
33
|
+
"url": "https://github.com/Logomarks/cli/issues"
|
|
34
|
+
},
|
|
35
|
+
"license": "MIT",
|
|
36
|
+
"author": {
|
|
37
|
+
"name": "David Sherlock",
|
|
38
|
+
"url": "https://davidsherlock.com"
|
|
39
|
+
},
|
|
40
|
+
"type": "module",
|
|
41
|
+
"main": "src/index.js",
|
|
42
|
+
"types": "src/index.d.ts",
|
|
43
|
+
"bin": {
|
|
44
|
+
"logomarks": "bin/logomarks.js"
|
|
45
|
+
},
|
|
46
|
+
"exports": {
|
|
47
|
+
".": {
|
|
48
|
+
"types": "./src/index.d.ts",
|
|
49
|
+
"import": "./src/index.js",
|
|
50
|
+
"default": "./src/index.js"
|
|
51
|
+
},
|
|
52
|
+
"./mcp": {
|
|
53
|
+
"types": "./src/mcp/index.d.ts",
|
|
54
|
+
"import": "./src/mcp/index.js",
|
|
55
|
+
"default": "./src/mcp/index.js"
|
|
56
|
+
},
|
|
57
|
+
"./package.json": "./package.json"
|
|
58
|
+
},
|
|
59
|
+
"files": [
|
|
60
|
+
"bin",
|
|
61
|
+
"src",
|
|
62
|
+
"data",
|
|
63
|
+
"docs",
|
|
64
|
+
"README.md",
|
|
65
|
+
"CHANGELOG.md",
|
|
66
|
+
"LICENSE"
|
|
67
|
+
],
|
|
68
|
+
"engines": {
|
|
69
|
+
"node": ">=20.0.0"
|
|
70
|
+
},
|
|
71
|
+
"scripts": {
|
|
72
|
+
"test": "node --test tests/*.test.js",
|
|
73
|
+
"typecheck": "tsc --noEmit",
|
|
74
|
+
"index": "node scripts/index.js"
|
|
75
|
+
},
|
|
76
|
+
"publishConfig": {
|
|
77
|
+
"access": "public",
|
|
78
|
+
"registry": "https://registry.npmjs.org/"
|
|
79
|
+
},
|
|
80
|
+
"dependencies": {
|
|
81
|
+
"@arraypress/color-utils": "^1.5.0",
|
|
82
|
+
"@arraypress/covers": "^1.8.0",
|
|
83
|
+
"@arraypress/search": "^0.1.0",
|
|
84
|
+
"@logomarks/brand-kit": "^0.4.1",
|
|
85
|
+
"@logomarks/core": "^0.1.8",
|
|
86
|
+
"@logomarks/editor": "^0.2.4",
|
|
87
|
+
"@logomarks/mockups": "^0.5.0",
|
|
88
|
+
"@modelcontextprotocol/sdk": "1.32.1",
|
|
89
|
+
"@resvg/resvg-wasm": "2.6.2",
|
|
90
|
+
"zod": "4.6.7"
|
|
91
|
+
},
|
|
92
|
+
"devDependencies": {
|
|
93
|
+
"@types/node": "^26.6.6",
|
|
94
|
+
"typescript": "^6.0.3"
|
|
95
|
+
}
|
|
96
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import type { BrandInput } from '@logomarks/brand-kit';
|
|
2
|
+
import type { Mark } from './mark.js';
|
|
3
|
+
import type { FontId } from './fonts.js';
|
|
4
|
+
|
|
5
|
+
/** What a brand is built from. */
|
|
6
|
+
export interface BrandOptions {
|
|
7
|
+
mark: Mark;
|
|
8
|
+
/** The brand's name (the mark's). */
|
|
9
|
+
name?: string;
|
|
10
|
+
/** The brand colour, hex (Logomarks' yellow). */
|
|
11
|
+
color?: string;
|
|
12
|
+
/** A bundled face (inter). */
|
|
13
|
+
font?: FontId;
|
|
14
|
+
/** A line under the name on social images and the sheet. */
|
|
15
|
+
tagline?: string;
|
|
16
|
+
/** The website, for the sheet and the email signature. */
|
|
17
|
+
url?: string;
|
|
18
|
+
/** The social handle (`@` and the slug). */
|
|
19
|
+
handle?: string;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
/** The brand as `@logomarks/brand-kit` takes it; a live mark is credited (CC0). */
|
|
23
|
+
export function brandInput(o: BrandOptions): BrandInput;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @module logomarks/brand/brand
|
|
3
|
+
*
|
|
4
|
+
* A brand as `@logomarks/brand-kit` takes it, from what the CLI and the MCP
|
|
5
|
+
* tools are given: a mark (live or a file), a name, a colour, a bundled
|
|
6
|
+
* face, and the words for social images. A live mark is credited, CC0.
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
import { brandFont } from './fonts.js';
|
|
10
|
+
import { MARK_URL } from './mark.js';
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* The brand-kit inputs.
|
|
14
|
+
*
|
|
15
|
+
* @param {import('./brand.js').BrandOptions} o The mark, name, colour, face and words.
|
|
16
|
+
* @returns {import('@logomarks/brand-kit').BrandInput} The inputs.
|
|
17
|
+
*/
|
|
18
|
+
export function brandInput({ mark, name, color, font, tagline, url, handle }) {
|
|
19
|
+
return {
|
|
20
|
+
svg: mark.svg,
|
|
21
|
+
name: name?.trim() || mark.name,
|
|
22
|
+
color,
|
|
23
|
+
font: brandFont(font),
|
|
24
|
+
tagline,
|
|
25
|
+
url,
|
|
26
|
+
handle,
|
|
27
|
+
...(mark.live && { source: { name: mark.name, url: MARK_URL + mark.slug, license: 'CC0-1.0' } }),
|
|
28
|
+
};
|
|
29
|
+
}
|