@commentkit/comment-kit 1.5.1 → 1.6.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 +15 -0
- package/dist/npm/THIRD_PARTY_NOTICES.txt +2 -2
- package/dist/npm/chunks/{AgentSend-DjFZSC0S.js → AgentSend-2JPDseOo.js} +4 -5
- package/dist/npm/chunks/{Checklist-BEz4IZdT.js → Checklist-BpDXQebo.js} +77 -79
- package/dist/npm/chunks/Composer-CAyj-c8e.js +677 -0
- package/dist/npm/chunks/Guest-ZdFmTcXI.js +187 -0
- package/dist/npm/chunks/{MarkupEditor-CPH4yKx4.js → MarkupEditor-BFplZwFy.js} +3 -5
- package/dist/npm/chunks/{Panel-DSoUAlbQ.js → Panel-BhZ4XRDR.js} +300 -302
- package/dist/npm/chunks/{Settings-C_qV4n7J.js → Settings-SPG9EHUZ.js} +70 -72
- package/dist/npm/chunks/{Shortcuts-ChnaribX.js → Shortcuts-C28HVDw6.js} +3 -5
- package/dist/npm/chunks/{StyleEditor-DqZd6C5o.js → StyleEditor-ByZMtq10.js} +4 -5
- package/dist/npm/chunks/{StylePanel-DMC3riYK.js → StylePanel-Iwhce2tE.js} +62 -64
- package/dist/npm/chunks/{TaskFields-BfjjllMx.js → TaskFields-BsP_fVJg.js} +7 -6
- package/dist/npm/chunks/{ThreadCard-DmKAelSL.js → ThreadCard-BzVZdDCb.js} +407 -403
- package/dist/npm/chunks/{Viewer-mw69qSI5.js → Viewer-CqtGrdD8.js} +29 -31
- package/dist/npm/chunks/{agent-CqDO3JMA.js → agent-BDMQtOzH.js} +14 -15
- package/dist/npm/chunks/{anchor-OCQnjp_6.js → anchor-BsradQhn.js} +1 -2
- package/dist/npm/chunks/{ar-BQ9K9Oqf.js → ar-8tPch6W4.js} +5 -2
- package/dist/npm/chunks/{card-bits-C7bIk5KX.js → card-bits-Bna-g3Py.js} +24 -26
- package/dist/npm/chunks/{client-dZeNdizE.js → client-EFTWxHbJ.js} +76 -61
- package/dist/npm/chunks/{colors-CAjY4jxf.js → colors-CWAn_swA.js} +1 -2
- package/dist/npm/chunks/{confetti-DKeKR7-6.js → confetti-DTKpwF3O.js} +1 -2
- package/dist/npm/chunks/{de-CcPi8xdC.js → de-C63897uD.js} +5 -2
- package/dist/npm/chunks/{drafts-CpQdHhcK.js → drafts-akdBsOd0.js} +1 -2
- package/dist/npm/chunks/{es-DXgkjDCG.js → es-CI2bSpvB.js} +5 -2
- package/dist/npm/chunks/{extension-BFkXOmX5.js → extension-BST6LH1q.js} +2 -3
- package/dist/npm/chunks/{extension-Gvei3opb.js → extension-D-V3utTm.js} +3 -4
- package/dist/npm/chunks/{fr-IjJaUbWh.js → fr-rsVe-Lqk.js} +5 -2
- package/dist/npm/chunks/{hi-BhKQK2MU.js → hi-cvwbSaWP.js} +5 -2
- package/dist/npm/chunks/{html2canvas-pro.esm-lgs6tb4C.js → html2canvas-pro.esm-B7b8p5Wr.js} +608 -528
- package/dist/npm/chunks/{i18n-DAJGndZ2.js → i18n-C4v0M-6z.js} +254 -257
- package/dist/npm/chunks/{it-DKiSCkiD.js → it-C8tnV0BF.js} +5 -2
- package/dist/npm/chunks/{ja-BI1WagDg.js → ja-BWxDfC2f.js} +5 -2
- package/dist/npm/chunks/{live-MvvBdoGd.js → live-BCpJVBeN.js} +2 -3
- package/dist/npm/chunks/{lock-C82sC17d.js → lock-B1JLlOhz.js} +0 -1
- package/dist/npm/chunks/{nl-CJw3VUQ5.js → nl-DNQ6eCht.js} +5 -2
- package/dist/npm/chunks/{pick-dDDLxCDI.js → pick-CLyOdjnD.js} +3 -4
- package/dist/npm/chunks/{pt-BR-CjBolC5g.js → pt-BR-CkG7vpU2.js} +5 -2
- package/dist/npm/chunks/{realtime-D22tI_AS.js → realtime-DIo-Wth4.js} +2 -3
- package/dist/npm/chunks/{report-DoDVi1qT.js → report-BBrT3r89.js} +1 -2
- package/dist/npm/chunks/{rolldown-runtime-Y_bBpyJl.js → rolldown-runtime-QGRDbDUS.js} +1 -2
- package/dist/npm/chunks/{source-BQS2_xfB.js → source-CS7C6wJA.js} +2 -3
- package/dist/npm/chunks/{src-C_oUnL0i.js → src-C4FsVoUp.js} +22 -24
- package/dist/npm/chunks/{start-C5-rebEU.js → start-i9M-r3aH.js} +374 -357
- package/dist/npm/chunks/{upload-CzPAjktW.js → upload-DSv7EyBD.js} +2 -3
- package/dist/npm/chunks/uploads-I01kdqQF.js +1103 -0
- package/dist/npm/chunks/{zh-CN-BrZGx2S0.js → zh-CN-BKuZOLBE.js} +5 -2
- package/dist/npm/element.js +2 -3
- package/dist/npm/headless.js +2 -2
- package/dist/npm/index.js +2 -2
- package/dist/npm/react.js +2 -3
- package/dist/npm/svelte.js +2 -3
- package/dist/npm/types/core/auth.d.ts +14 -0
- package/dist/npm/vue.js +2 -3
- package/package.json +8 -8
- package/dist/npm/chunks/Composer-D1wbmdjF.js +0 -681
- package/dist/npm/chunks/Guest-CtyRy8Kz.js +0 -170
- package/dist/npm/chunks/uploads-tpLjiJdH.js +0 -541
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
// src/ui/locales/zh-CN.ts
|
|
2
2
|
var e = {
|
|
3
3
|
comment: "评论",
|
|
4
4
|
commentHint: "点击页面上的任意位置即可评论",
|
|
@@ -167,6 +167,10 @@ var e = {
|
|
|
167
167
|
shareExpired: "此客户链接已过期。请向团队索取新链接。",
|
|
168
168
|
verifyTitle: "请查看邮箱",
|
|
169
169
|
verifyBody: "输入 6 位验证码即可发布你的评论。验证码已发送至 {email}。",
|
|
170
|
+
verifyLookFor: "请查找来自 CommentKit 的邮件:“Your code for {website}”。如果没有收到,请检查垃圾邮件。",
|
|
171
|
+
signInLinkTitle: "欢迎回到 {project}",
|
|
172
|
+
signInLinkBody: "继续即可查看反馈并回复。我们会通过邮件发送一个 6 位验证码,确认是你本人。",
|
|
173
|
+
notNow: "以后再说",
|
|
170
174
|
verifyCode: "6 位验证码",
|
|
171
175
|
verifyPublish: "发布评论",
|
|
172
176
|
verifyResend: "重新发送验证码",
|
|
@@ -359,5 +363,4 @@ var e = {
|
|
|
359
363
|
styleNext: "{property} 的下一个值",
|
|
360
364
|
styleEdit: "编辑建议的样式更改"
|
|
361
365
|
};
|
|
362
|
-
//#endregion
|
|
363
366
|
export { e as default };
|
package/dist/npm/element.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { t as e } from "./chunks/src-
|
|
2
|
-
|
|
1
|
+
import { t as e } from "./chunks/src-C4FsVoUp.js";
|
|
2
|
+
// src/element.ts
|
|
3
3
|
var t, n = class extends HTMLElement {
|
|
4
4
|
constructor(...e) {
|
|
5
5
|
super(...e), this.kit = null;
|
|
@@ -36,5 +36,4 @@ var t, n = class extends HTMLElement {
|
|
|
36
36
|
}
|
|
37
37
|
};
|
|
38
38
|
t = n, t.observedAttributes = ["project"], typeof customElements < "u" && !customElements.get("comment-kit") && customElements.define("comment-kit", n);
|
|
39
|
-
//#endregion
|
|
40
39
|
export { n as CommentKitElement };
|
package/dist/npm/headless.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { f as e, i as t, l as n, n as r, p as i, r as a, t as o } from "./chunks/client-
|
|
2
|
-
import { a as s, o as c, t as l } from "./chunks/anchor-
|
|
1
|
+
import { f as e, i as t, l as n, n as r, p as i, r as a, t as o } from "./chunks/client-EFTWxHbJ.js";
|
|
2
|
+
import { a as s, o as c, t as l } from "./chunks/anchor-BsradQhn.js";
|
|
3
3
|
export { e as ApiClient, n as AuthManager, o as CommentKitClient, i as CommentKitError, r as EDIT_CONFLICT, a as SDK_VERSION, l as createAnchor, t as currentPageUrl, s as resolveAnchor, c as stableSelector };
|
package/dist/npm/index.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { t as e } from "./chunks/src-
|
|
2
|
-
import { p as t, r as n } from "./chunks/client-
|
|
1
|
+
import { t as e } from "./chunks/src-C4FsVoUp.js";
|
|
2
|
+
import { p as t, r as n } from "./chunks/client-EFTWxHbJ.js";
|
|
3
3
|
export { t as CommentKitError, n as SDK_VERSION, e as init };
|
package/dist/npm/react.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { t as e } from "./chunks/src-
|
|
2
|
+
import { t as e } from "./chunks/src-C4FsVoUp.js";
|
|
3
3
|
import { useEffect as t } from "react";
|
|
4
|
-
|
|
4
|
+
// src/adapters/react.tsx
|
|
5
5
|
function n(n) {
|
|
6
6
|
return t(() => {
|
|
7
7
|
try {
|
|
@@ -22,5 +22,4 @@ function n(n) {
|
|
|
22
22
|
n.endpoint
|
|
23
23
|
]), null;
|
|
24
24
|
}
|
|
25
|
-
//#endregion
|
|
26
25
|
export { n as CommentKit, n as default, e as init };
|
package/dist/npm/svelte.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { t as e } from "./chunks/src-
|
|
2
|
-
|
|
1
|
+
import { t as e } from "./chunks/src-C4FsVoUp.js";
|
|
2
|
+
// src/adapters/svelte.ts
|
|
3
3
|
function t(t, n) {
|
|
4
4
|
let r = null;
|
|
5
5
|
try {
|
|
@@ -13,5 +13,4 @@ function t(t, n) {
|
|
|
13
13
|
} catch {}
|
|
14
14
|
} };
|
|
15
15
|
}
|
|
16
|
-
//#endregion
|
|
17
16
|
export { t as commentkit, e as init };
|
|
@@ -12,6 +12,11 @@ export type SignInResult = "signed_in" | "popup_blocked" | "cancelled" | "failed
|
|
|
12
12
|
export type AuthMode = "auto" | "popup" | "redirect";
|
|
13
13
|
/** Token, exchange and revoke requests are aborted after this long; the storage lock's lease (lock.ts HOLD_MS) is longer. */
|
|
14
14
|
export declare const TOKEN_TIMEOUT_MS = 10000;
|
|
15
|
+
/**
|
|
16
|
+
* Client email links carry `?ck_signin=<secret>` (single use, 72 hours, one website; the backend's
|
|
17
|
+
* ClientSignInLinks). The sign-in window (`/widget/guest`) checks it; this only keeps out what can't be one.
|
|
18
|
+
*/
|
|
19
|
+
export declare const SIGNIN_PARAM = "ck_signin";
|
|
15
20
|
/**
|
|
16
21
|
* Widget sign-in: a popup on the CommentKit domain (credentials never touch
|
|
17
22
|
* this page), PKCE, short-lived access tokens and a rotating refresh token.
|
|
@@ -30,6 +35,8 @@ export declare class AuthManager {
|
|
|
30
35
|
private listeners;
|
|
31
36
|
private remember;
|
|
32
37
|
private authorize;
|
|
38
|
+
/** From a client email link: in memory only (never stored or logged), used by the next sign-in. */
|
|
39
|
+
private signInLink;
|
|
33
40
|
constructor(endpoint: string, projectKey: string, origin?: string);
|
|
34
41
|
get storageKey(): string;
|
|
35
42
|
hasSession(): boolean;
|
|
@@ -37,6 +44,13 @@ export declare class AuthManager {
|
|
|
37
44
|
/** A valid access token, refreshing if needed. null when signed out. */
|
|
38
45
|
accessToken(): Promise<string | null>;
|
|
39
46
|
recover(): Promise<boolean>;
|
|
47
|
+
/**
|
|
48
|
+
* Takes `?ck_signin=` off the address bar at once (no reload), so it never reaches the page's analytics,
|
|
49
|
+
* a bookmark or a Referer, and keeps it for the next sign-in. True when a usable link was there.
|
|
50
|
+
*/
|
|
51
|
+
takeSignInLink(): boolean;
|
|
52
|
+
/** A client email link is waiting to be used by the next sign-in. */
|
|
53
|
+
hasSignInLink(): boolean;
|
|
40
54
|
/** Must be called from a user gesture (click) so the popup is allowed. */
|
|
41
55
|
signIn(options?: {
|
|
42
56
|
share?: string | null;
|
package/dist/npm/vue.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { t as e } from "./chunks/src-
|
|
1
|
+
import { t as e } from "./chunks/src-C4FsVoUp.js";
|
|
2
2
|
import { defineComponent as t, onBeforeUnmount as n, onMounted as r } from "vue";
|
|
3
|
-
|
|
3
|
+
// src/adapters/vue.ts
|
|
4
4
|
function i(e) {
|
|
5
5
|
try {
|
|
6
6
|
return e();
|
|
@@ -71,5 +71,4 @@ var a = t({
|
|
|
71
71
|
}), o = { install(t, n) {
|
|
72
72
|
typeof window < "u" && i(() => e(n));
|
|
73
73
|
} };
|
|
74
|
-
//#endregion
|
|
75
74
|
export { a as CommentKit, o as CommentKitPlugin, e as init };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@commentkit/comment-kit",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.6.0",
|
|
4
4
|
"description": "Figma-style comments for any website. Clients pin feedback with an automatic screenshot; developers see it on localhost and hand it to their AI agent.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"comments",
|
|
@@ -88,21 +88,21 @@
|
|
|
88
88
|
"release:status": "changeset status --verbose"
|
|
89
89
|
},
|
|
90
90
|
"devDependencies": {
|
|
91
|
-
"@axe-core/playwright": "4.
|
|
91
|
+
"@axe-core/playwright": "4.14.0",
|
|
92
92
|
"@changesets/cli": "3.0.3",
|
|
93
93
|
"@playwright/test": "1.64.1",
|
|
94
94
|
"@types/react": "19.3.0",
|
|
95
95
|
"@vitest/coverage-v8": "5.0.5",
|
|
96
|
-
"html2canvas-pro": "2.
|
|
96
|
+
"html2canvas-pro": "2.6.0",
|
|
97
97
|
"jsdom": "30.1.3",
|
|
98
|
-
"preact": "11.0
|
|
98
|
+
"preact": "11.1.0",
|
|
99
99
|
"pusher-js": "8.6.0",
|
|
100
100
|
"react": "19.3.1",
|
|
101
101
|
"react-dom": "19.3.1",
|
|
102
|
-
"svelte": "5.57.
|
|
102
|
+
"svelte": "5.57.3",
|
|
103
103
|
"typescript": "7.0.2",
|
|
104
|
-
"vite": "npm:@voidzero-dev/vite-plus-core@1.
|
|
105
|
-
"vite-plus": "1.
|
|
104
|
+
"vite": "npm:@voidzero-dev/vite-plus-core@1.4.0",
|
|
105
|
+
"vite-plus": "1.4.0",
|
|
106
106
|
"vitest": "5.0.5",
|
|
107
107
|
"vue": "3.5.44",
|
|
108
108
|
"yaml": "2.9.1"
|
|
@@ -124,7 +124,7 @@
|
|
|
124
124
|
}
|
|
125
125
|
},
|
|
126
126
|
"overrides": {
|
|
127
|
-
"vite": "npm:@voidzero-dev/vite-plus-core@1.
|
|
127
|
+
"vite": "npm:@voidzero-dev/vite-plus-core@1.4.0",
|
|
128
128
|
"vitest": "5.0.5"
|
|
129
129
|
},
|
|
130
130
|
"engines": {
|