@aparte/n8n-chat 1.0.0 → 1.0.2

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.
Files changed (83) hide show
  1. package/LICENSE +21 -21
  2. package/README.md +35 -19
  3. package/dist/cdn/chunks/chunk-4MZPEZPE.js +209 -0
  4. package/dist/cdn/chunks/chunk-4MZPEZPE.js.map +7 -0
  5. package/dist/cdn/chunks/{chunk-UCBMONE6.js → chunk-HASLYSSG.js} +2 -2
  6. package/dist/cdn/chunks/{chunk-UCBMONE6.js.map → chunk-HASLYSSG.js.map} +1 -1
  7. package/dist/cdn/chunks/{chunk-WCZRD7U7.js → chunk-KPADIE5S.js} +1 -1
  8. package/dist/cdn/chunks/{chunk-WCZRD7U7.js.map → chunk-KPADIE5S.js.map} +1 -1
  9. package/dist/cdn/chunks/{chunk-EKOAQWDB.js → chunk-LGVX5DQP.js} +2 -2
  10. package/dist/cdn/chunks/{chunk-EKOAQWDB.js.map → chunk-LGVX5DQP.js.map} +1 -1
  11. package/dist/cdn/chunks/{chunk-FPBJCFJN.js → chunk-PPDOW5CO.js} +2 -2
  12. package/dist/cdn/chunks/{chunk-FPBJCFJN.js.map → chunk-PPDOW5CO.js.map} +1 -1
  13. package/dist/cdn/chunks/{chunk-75MBZEMR.js → chunk-XY3GEFGN.js} +2 -2
  14. package/dist/cdn/chunks/{chunk-75MBZEMR.js.map → chunk-XY3GEFGN.js.map} +1 -1
  15. package/dist/cdn/chunks/de-VHSIFTGU.js +2 -0
  16. package/dist/cdn/chunks/de-VHSIFTGU.js.map +7 -0
  17. package/dist/cdn/chunks/es-CSDZBDZK.js +2 -0
  18. package/dist/cdn/chunks/es-CSDZBDZK.js.map +7 -0
  19. package/dist/cdn/chunks/fr-A7LKKK4U.js +2 -0
  20. package/dist/cdn/chunks/fr-A7LKKK4U.js.map +7 -0
  21. package/dist/cdn/chunks/{highlight-W7QGGHNK.js → highlight-KR6IJJGG.js} +2 -2
  22. package/dist/cdn/chunks/{highlight-W7QGGHNK.js.map → highlight-KR6IJJGG.js.map} +2 -2
  23. package/dist/cdn/chunks/it-4UDH2XVX.js +2 -0
  24. package/dist/cdn/chunks/it-4UDH2XVX.js.map +7 -0
  25. package/dist/cdn/chunks/{items-X2D73Z5A.js → items-FFNVAESC.js} +2 -2
  26. package/dist/cdn/chunks/{items-X2D73Z5A.js.map → items-FFNVAESC.js.map} +1 -1
  27. package/dist/cdn/chunks/ja-5FMFPBXT.js +2 -0
  28. package/dist/cdn/chunks/ja-5FMFPBXT.js.map +7 -0
  29. package/dist/cdn/chunks/ko-KXXFK5U7.js +2 -0
  30. package/dist/cdn/chunks/ko-KXXFK5U7.js.map +7 -0
  31. package/dist/cdn/chunks/{link-LNDRLLUH.js → link-3AMG5PIK.js} +2 -2
  32. package/dist/cdn/chunks/{link-LNDRLLUH.js.map → link-3AMG5PIK.js.map} +1 -1
  33. package/dist/cdn/chunks/{media-JDTPNZHJ.js → media-F3HYZLYR.js} +2 -2
  34. package/dist/cdn/chunks/{media-JDTPNZHJ.js.map → media-F3HYZLYR.js.map} +1 -1
  35. package/dist/cdn/chunks/{order-HS6FXBIB.js → order-L6GKT5I6.js} +2 -2
  36. package/dist/cdn/chunks/{order-HS6FXBIB.js.map → order-L6GKT5I6.js.map} +1 -1
  37. package/dist/cdn/chunks/{place-N3E7T2EV.js → place-J7BDZGKL.js} +2 -2
  38. package/dist/cdn/chunks/{place-N3E7T2EV.js.map → place-J7BDZGKL.js.map} +1 -1
  39. package/dist/cdn/chunks/{plan-TCWRW3OC.js → plan-BAI6GY4A.js} +2 -2
  40. package/dist/cdn/chunks/{plan-TCWRW3OC.js.map → plan-BAI6GY4A.js.map} +1 -1
  41. package/dist/cdn/chunks/{product-JH7QUP6I.js → product-VOKQKP4K.js} +2 -2
  42. package/dist/cdn/chunks/{product-JH7QUP6I.js.map → product-VOKQKP4K.js.map} +1 -1
  43. package/dist/cdn/chunks/pt-BR-T2PIW5LH.js +2 -0
  44. package/dist/cdn/chunks/pt-BR-T2PIW5LH.js.map +7 -0
  45. package/dist/cdn/chunks/ru-CWHLBHXX.js +2 -0
  46. package/dist/cdn/chunks/ru-CWHLBHXX.js.map +7 -0
  47. package/dist/cdn/chunks/{score-GUHJWHW3.js → score-IPBHXWWN.js} +2 -2
  48. package/dist/cdn/chunks/{score-GUHJWHW3.js.map → score-IPBHXWWN.js.map} +1 -1
  49. package/dist/cdn/chunks/{stats-UIVYR2CG.js → stats-V6H3J3WL.js} +2 -2
  50. package/dist/cdn/chunks/{stats-UIVYR2CG.js.map → stats-V6H3J3WL.js.map} +1 -1
  51. package/dist/cdn/chunks/{stock-PV4GC573.js → stock-UNSEZYGA.js} +2 -2
  52. package/dist/cdn/chunks/{stock-PV4GC573.js.map → stock-UNSEZYGA.js.map} +1 -1
  53. package/dist/cdn/chunks/{weather-7L3Y3DNB.js → weather-4IMAIRYF.js} +2 -2
  54. package/dist/cdn/chunks/{weather-7L3Y3DNB.js.map → weather-4IMAIRYF.js.map} +1 -1
  55. package/dist/cdn/chunks/zh-CN-UEBLECMR.js +2 -0
  56. package/dist/cdn/chunks/zh-CN-UEBLECMR.js.map +7 -0
  57. package/dist/cdn/latest.js +11 -0
  58. package/dist/cdn/n8n-chat.js +2 -2
  59. package/dist/cdn/n8n-chat.js.map +2 -2
  60. package/dist/highlight-DDyMJYBk.js.map +1 -1
  61. package/dist/index.js.map +1 -1
  62. package/dist/style.css +1 -1
  63. package/package.json +7 -7
  64. package/dist/cdn/chunks/chunk-FZXRS5MT.js +0 -208
  65. package/dist/cdn/chunks/chunk-FZXRS5MT.js.map +0 -7
  66. package/dist/cdn/chunks/de-7JCOF7FR.js +0 -2
  67. package/dist/cdn/chunks/de-7JCOF7FR.js.map +0 -7
  68. package/dist/cdn/chunks/es-KUX7YCK6.js +0 -2
  69. package/dist/cdn/chunks/es-KUX7YCK6.js.map +0 -7
  70. package/dist/cdn/chunks/fr-VYD7EC55.js +0 -2
  71. package/dist/cdn/chunks/fr-VYD7EC55.js.map +0 -7
  72. package/dist/cdn/chunks/it-BXNO2THQ.js +0 -2
  73. package/dist/cdn/chunks/it-BXNO2THQ.js.map +0 -7
  74. package/dist/cdn/chunks/ja-6VGJFQ66.js +0 -2
  75. package/dist/cdn/chunks/ja-6VGJFQ66.js.map +0 -7
  76. package/dist/cdn/chunks/ko-HUU4F44X.js +0 -2
  77. package/dist/cdn/chunks/ko-HUU4F44X.js.map +0 -7
  78. package/dist/cdn/chunks/pt-BR-SNSDLB4C.js +0 -2
  79. package/dist/cdn/chunks/pt-BR-SNSDLB4C.js.map +0 -7
  80. package/dist/cdn/chunks/ru-QE2LLTEY.js +0 -2
  81. package/dist/cdn/chunks/ru-QE2LLTEY.js.map +0 -7
  82. package/dist/cdn/chunks/zh-CN-WKC5MGZY.js +0 -2
  83. package/dist/cdn/chunks/zh-CN-WKC5MGZY.js.map +0 -7
package/LICENSE CHANGED
@@ -1,21 +1,21 @@
1
- MIT License
2
-
3
- Copyright (c) 2026 aparté
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.
1
+ MIT License
2
+
3
+ Copyright (c) 2026 aparté
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -19,7 +19,7 @@ weather — and offer **quick replies** the visitor clicks. [See it live](https:
19
19
  - Every option of `@n8n/chat` 1.43, the same defaults, the same session in the browser — and the
20
20
  Chat nodes' messages and buttons of a workflow that answers through response nodes.
21
21
  - Ten languages, keyboard and screen-reader access, readable contrast, a dark scheme.
22
- - About 151 KB compressed on the first load, against about 471 KB (measured 2026-11-07 on 1.0.0; `@n8n/chat` 1.44.7 on 2026-10-31).
22
+ - About 155 KB compressed on the first load, against about 471 KB (measured 2026-11-10 on 1.0.1; `@n8n/chat` 1.44.7 on 2026-10-31).
23
23
  - A handle to drive it from your page: `open`, `close`, `toggle`, `send`, `reset`, `setDisabled`,
24
24
  `destroy`.
25
25
  - MIT. A small grey "Powered by aparté" line sits under the input, linking to [apartejs.dev](https://apartejs.dev).
@@ -29,17 +29,33 @@ weather — and offer **quick replies** the visitor clicks. [See it live](https:
29
29
  ### From a CDN — no build step
30
30
 
31
31
  ```html
32
- <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@aparte/n8n-chat@1.0.0/dist/style.css">
33
32
  <script type="module">
34
- import { createChat } from 'https://cdn.jsdelivr.net/npm/@aparte/n8n-chat@1.0.0/dist/cdn/n8n-chat.js';
33
+ import { createChat } from 'https://cdn.jsdelivr.net/npm/@aparte/n8n-chat@1/dist/cdn/latest.js';
35
34
 
36
35
  createChat({ webhookUrl: 'https://your-n8n.example.com/webhook/<id>/chat' });
37
36
  </script>
38
37
  ```
39
38
 
40
- `dist/cdn/n8n-chat.js` is one module with aparté inside it. What only some pages need is fetched
41
- when used, from beside it: a language other than English, and the code highlighter with the first
42
- code block. Keep the version in the URL: the widget you tested is the widget your visitors get.
39
+ `latest.js` loads the latest 1.x and its stylesheet, both from one exact version, so a fix reaches
40
+ your visitors on its own: within 12 hours on jsDelivr, and within a week for a browser that kept the
41
+ previous one. A 2.0 never arrives on its own. The module has aparté inside it; what only some pages
42
+ need is fetched when used, from beside it: a language other than English, and the code highlighter
43
+ with the first code block.
44
+
45
+ To keep one version until you change it, load the module and its stylesheet by their exact version
46
+ instead:
47
+
48
+ ```html
49
+ <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@aparte/n8n-chat@1.0.2/dist/style.css">
50
+ <script type="module">
51
+ import { createChat } from 'https://cdn.jsdelivr.net/npm/@aparte/n8n-chat@1.0.2/dist/cdn/n8n-chat.js';
52
+
53
+ createChat({ webhookUrl: 'https://your-n8n.example.com/webhook/<id>/chat' });
54
+ </script>
55
+ ```
56
+
57
+ Load `n8n-chat.js` by an exact version only: through a range like `@1`, a browser could keep last
58
+ week's module and fetch its chunks from this week's version, where they no longer exist.
43
59
 
44
60
  ### From npm
45
61
 
@@ -57,14 +73,13 @@ chat.open();
57
73
 
58
74
  ## Coming from `@n8n/chat`
59
75
 
60
- Replace the stylesheet and the import; the call stays as it is:
76
+ Replace the import and drop the stylesheet, which `latest.js` loads itself; the call stays as it is:
61
77
 
62
78
  ```diff
63
79
  - <link href="https://cdn.jsdelivr.net/npm/@n8n/chat/dist/style.css" rel="stylesheet" />
64
- + <link href="https://cdn.jsdelivr.net/npm/@aparte/n8n-chat@1.0.0/dist/style.css" rel="stylesheet" />
65
80
  <script type="module">
66
81
  - import { createChat } from 'https://cdn.jsdelivr.net/npm/@n8n/chat/dist/chat.bundle.es.js';
67
- + import { createChat } from 'https://cdn.jsdelivr.net/npm/@aparte/n8n-chat@1.0.0/dist/cdn/n8n-chat.js';
82
+ + import { createChat } from 'https://cdn.jsdelivr.net/npm/@aparte/n8n-chat@1/dist/cdn/latest.js';
68
83
  createChat({ webhookUrl: 'https://your-n8n.example.com/webhook/<id>/chat' });
69
84
  </script>
70
85
  ```
@@ -267,7 +282,7 @@ createChat({
267
282
  ```
268
283
 
269
284
  Take `defineCard` from the widget's own module, as above, and from the same URL when you load
270
- it from a CDN (`…/@aparte/n8n-chat@1.0.0/dist/cdn/n8n-chat.js`): the card and the chat then share
285
+ it from a CDN (`…/@aparte/n8n-chat@1/dist/cdn/latest.js`): the card and the chat then share
271
286
  one copy of aparté. A kit loaded from another URL keeps its cards where the chat never looks.
272
287
 
273
288
  ````md
@@ -383,11 +398,10 @@ so the page puts a fresh token in `metadata` before every message.
383
398
  2. In the page:
384
399
 
385
400
  ```html
386
- <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@aparte/n8n-chat@1.0.0/dist/style.css">
387
401
  <script src="https://challenges.cloudflare.com/turnstile/v0/api.js?render=explicit"></script>
388
402
  <div id="turnstile"></div>
389
403
  <script type="module">
390
- import { createChat } from 'https://cdn.jsdelivr.net/npm/@aparte/n8n-chat@1.0.0/dist/cdn/n8n-chat.js';
404
+ import { createChat } from 'https://cdn.jsdelivr.net/npm/@aparte/n8n-chat@1/dist/cdn/latest.js';
391
405
 
392
406
  // A Turnstile token is single-use and lasts five minutes: ask for a new one before each message.
393
407
  let widgetId;
@@ -573,7 +587,7 @@ or Angular components, inside an `.aparte-n8n` element.
573
587
  | Dark scheme | — | ✓ |
574
588
  | Rich cards | the JSON as text | drawn: order, booking, product, weather… |
575
589
  | Quick replies offered by an answer | the block as code | buttons above the input |
576
- | Weight, first load (compressed) | ~471 KB | ~151 KB |
590
+ | Weight, first load (compressed) | ~471 KB | ~155 KB |
577
591
  | License | Sustainable Use License | MIT |
578
592
 
579
593
  ## Versions
@@ -581,12 +595,14 @@ or Angular components, inside an `.aparte-n8n` element.
581
595
  From 1.0.0 the widget follows semantic versioning: the options of `createChat`, the handle it
582
596
  returns, what the module exports (the card kit included), the `i18n` keys, the `--chat--*`
583
597
  variables, the `.aparte-n8n` root with its `data-aparte-theme`, and the files a page loads
584
- (`dist/cdn/n8n-chat.js`, `dist/style.css`, `./theme.css`) keep their names, and what they do, until
585
- 2.0. A security fix may refuse what was accepted in any release, and says so first in its notes.
586
-
587
- The widget depends on **exact** versions of aparté's packages, and moves to a newer aparté only in
588
- a release of its own. Pin the widget's version in a CDN URL and in your `package.json`, and what you
589
- tested is what your visitors run.
598
+ (`dist/cdn/latest.js`, `dist/cdn/n8n-chat.js`, `dist/style.css`, `./theme.css`) keep their names, and
599
+ what they do, until 2.0. A security fix may refuse what was accepted in any release, and says so first
600
+ in its notes.
601
+
602
+ The widget depends on **exact** versions of aparté's packages, and moves to a newer aparté only in a
603
+ release of its own: within a day of a new aparté 1.x, a patch release of the widget carries it, once
604
+ its tests pass. `@1/dist/cdn/latest.js` brings it to your page on its own. To decide when, pin the
605
+ exact version in the CDN URLs and in your `package.json`: what you tested is what your visitors run.
590
606
 
591
607
  ## Links
592
608