best-email-builder 0.6.0 → 0.8.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 +59 -0
- package/README.md +127 -698
- package/dist/ai-server.js +116 -3
- package/dist/ai-server.js.map +1 -1
- package/dist/ai.js +507 -172
- package/dist/ai.js.map +1 -1
- package/dist/builder.js +8 -8
- package/dist/chunk-62HBUBBI.js +3866 -0
- package/dist/chunk-62HBUBBI.js.map +1 -0
- package/dist/{chunk-NC2YDZSP.js → chunk-6W3QUZR7.js} +8 -8
- package/dist/{chunk-W424KPCR.js → chunk-AXIM6E7T.js} +2 -2
- package/dist/{chunk-JU3OUO6X.js → chunk-DXWIVGHP.js} +3 -3
- package/dist/{chunk-QPAZLCPO.js → chunk-FAEVYSIF.js} +3 -3
- package/dist/{chunk-QPAZLCPO.js.map → chunk-FAEVYSIF.js.map} +1 -1
- package/dist/{chunk-4U7L2NYQ.js → chunk-G4U6PSF6.js} +2 -2
- package/dist/{chunk-5W4TUUPD.js → chunk-ITIG5NTJ.js} +4 -4
- package/dist/{chunk-CNJZLZRH.js → chunk-LUM7J5FF.js} +2 -2
- package/dist/{chunk-SAIW46IC.js → chunk-P7ABBLX6.js} +2 -2
- package/dist/chunk-SHHHYRPC.js +2829 -0
- package/dist/chunk-SHHHYRPC.js.map +1 -0
- package/dist/{chunk-XEFBPP5Y.js → chunk-WM2EEV4Q.js} +4 -4
- package/dist/index.js +10 -10
- package/dist/library.js +5 -5
- package/dist/server.js +8 -8
- package/dist/server.js.map +1 -1
- package/dist/styles.css +1 -1
- package/dist/types/ai/ConnectAi.d.ts +2 -1
- package/dist/types/ai/ModelPicker.d.ts +34 -0
- package/dist/types/ai/agent.d.ts +31 -0
- package/dist/types/ai/agentEndpoint.d.ts +69 -0
- package/dist/types/ai/claude.d.ts +2 -1
- package/dist/types/ai/draft.d.ts +10 -4
- package/dist/types/ai/generator.d.ts +10 -4
- package/dist/types/ai/i18n/de.d.ts +2 -0
- package/dist/types/ai/i18n/es.d.ts +2 -0
- package/dist/types/ai/i18n/pt.d.ts +2 -0
- package/dist/types/ai/i18n/ru.d.ts +2 -0
- package/dist/types/ai/i18n/zh.d.ts +2 -0
- package/dist/types/ai/index.d.ts +2 -1
- package/dist/types/ai/keys.d.ts +14 -1
- package/dist/types/ai/providers.d.ts +48 -5
- package/dist/types/ai/rewrite.d.ts +2 -1
- package/dist/types/ai/server.d.ts +3 -1
- package/dist/types/ai/subjects.d.ts +2 -1
- package/dist/types/core/constants.d.ts +1 -1
- package/dist/types/engine/NativeAdapter.d.ts +1 -1
- package/dist/types/i18n/de.d.ts +2 -0
- package/dist/types/i18n/es.d.ts +2 -0
- package/dist/types/i18n/pt.d.ts +2 -0
- package/dist/types/i18n/ru.d.ts +2 -0
- package/dist/types/i18n/zh.d.ts +2 -0
- package/dist/types/server/handler.d.ts +3 -0
- package/package.json +2 -2
- package/dist/chunk-JI36FNWE.js +0 -1361
- package/dist/chunk-JI36FNWE.js.map +0 -1
- package/dist/chunk-NZIQF7IW.js +0 -1830
- package/dist/chunk-NZIQF7IW.js.map +0 -1
- /package/dist/{chunk-NC2YDZSP.js.map → chunk-6W3QUZR7.js.map} +0 -0
- /package/dist/{chunk-W424KPCR.js.map → chunk-AXIM6E7T.js.map} +0 -0
- /package/dist/{chunk-JU3OUO6X.js.map → chunk-DXWIVGHP.js.map} +0 -0
- /package/dist/{chunk-4U7L2NYQ.js.map → chunk-G4U6PSF6.js.map} +0 -0
- /package/dist/{chunk-5W4TUUPD.js.map → chunk-ITIG5NTJ.js.map} +0 -0
- /package/dist/{chunk-CNJZLZRH.js.map → chunk-LUM7J5FF.js.map} +0 -0
- /package/dist/{chunk-SAIW46IC.js.map → chunk-P7ABBLX6.js.map} +0 -0
- /package/dist/{chunk-XEFBPP5Y.js.map → chunk-WM2EEV4Q.js.map} +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -6,6 +6,65 @@ All notable changes are documented here. The format follows
|
|
|
6
6
|
|
|
7
7
|
## [Unreleased]
|
|
8
8
|
|
|
9
|
+
## [0.8.0] — 2026-10-16
|
|
10
|
+
|
|
11
|
+
### Added
|
|
12
|
+
- **German, Spanish, Portuguese (Brazil), Russian and Chinese** (Simplified),
|
|
13
|
+
built in next to English and French: `locale="de"`, `"es"`, `"pt"`, `"ru"`
|
|
14
|
+
or `"zh"` (`"de-AT"`, `"pt-PT"`, `"zh-CN"`… find them too). Every text is translated — the interface, the
|
|
15
|
+
starting templates, the server's messages and the AI module — and counts
|
|
16
|
+
are written so that no language needs plural forms.
|
|
17
|
+
- The live demo offers the seven languages in a list and opens in the
|
|
18
|
+
visitor's: their browser's language, else the country of their device's
|
|
19
|
+
time zone (read in the page, nothing is sent), else English; a language
|
|
20
|
+
picked is remembered. Its code samples follow the page: their comments and
|
|
21
|
+
`locale` change with the language.
|
|
22
|
+
- `npm run check:i18n` checks every built-in language.
|
|
23
|
+
|
|
24
|
+
### Changed
|
|
25
|
+
- **Documentation.** The README is now a short front page: what the
|
|
26
|
+
builder is, a quick start and where to read next. The reference moved to
|
|
27
|
+
`docs/`, one page per subject: getting started, editor and library,
|
|
28
|
+
server, variables and sending, AI, brand, languages and the security
|
|
29
|
+
model, with an index in `docs/README.md`. The project has a logo.
|
|
30
|
+
|
|
31
|
+
## [0.7.0] — 2026-10-15
|
|
32
|
+
|
|
33
|
+
### Added
|
|
34
|
+
- **The user chooses the model.** In the Connect dialog, under the key, a
|
|
35
|
+
field opens the provider's list of models in place: the default first,
|
|
36
|
+
then the free ones (marked, with a *Free only* filter), then the newest;
|
|
37
|
+
searchable, and an id the list does not have can be used as typed. The
|
|
38
|
+
list is asked with the key (OpenRouter's needs none, so it shows before
|
|
39
|
+
any key); embeddings, speech, pictures and video are left out. The model
|
|
40
|
+
chosen is remembered for each provider and sent with each request.
|
|
41
|
+
`ai.key` gains `model(id?)`, `chooseModel(model, id?)` and
|
|
42
|
+
`listModels(id?, { apiKey, signal })`.
|
|
43
|
+
- **`listProviderModels({ provider, apiKey })`** — the models a provider
|
|
44
|
+
offers for writing, from `/ai` and `/ai/server`. `claudeProvider` lists
|
|
45
|
+
Claude's through the application's SDK and takes the model chosen.
|
|
46
|
+
- The live demo says which model is connected, and its link is now *Change
|
|
47
|
+
provider or model*.
|
|
48
|
+
- **Your own AI agent as the builder's AI** — `agentEmailModel({ url, headers })`
|
|
49
|
+
sends each model turn to an agent of the application's own over a small
|
|
50
|
+
HTTP protocol, `best-email-builder/agent@1` (`{ task, system, messages,
|
|
51
|
+
schema }` in, `{ text }` out, errors as codes the interface explains).
|
|
52
|
+
Generate, Rewrite and Subjects then go through the agent (its tools, its
|
|
53
|
+
knowledge, its users' rights) and its answers are checked like any model's.
|
|
54
|
+
On the server, `headers({ task, user })` gets the user `authorize` returned,
|
|
55
|
+
to forward who asks; the handler now hands that user to the generator and
|
|
56
|
+
its model. The agent's side: `createAgentEndpoint({ complete })` in
|
|
57
|
+
JavaScript, a FastAPI router to copy in `examples/agent/python`;
|
|
58
|
+
`checkAgent({ url, headers })` tries an agent with the builder's own checks.
|
|
59
|
+
See docs/AGENT.md.
|
|
60
|
+
- **`MODEL_UNAVAILABLE`** — a model the provider does not have, or no longer
|
|
61
|
+
(a 404 about the model, OpenRouter's "not a valid model ID"): *Choose
|
|
62
|
+
another one*, instead of *Try again*.
|
|
63
|
+
|
|
64
|
+
### Changed
|
|
65
|
+
- *Get a key* opens the provider's page in a new tab with `window.open`,
|
|
66
|
+
also where a link's target is ignored (some embedded browsers).
|
|
67
|
+
|
|
9
68
|
## [0.6.0] — 2026-10-15
|
|
10
69
|
|
|
11
70
|
### Added
|