@haklex/rich-ext-chat 0.31.1 → 0.33.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/dist/{ChatNode-CxLDjOKe.js → ChatNode-SYkdpaVD.js} +4 -4
- package/dist/{ChatRenderer-DaR63wyn.js → ChatRenderer-aRyOSnat.js} +4 -2
- package/dist/ChatRenderer.d.ts.map +1 -1
- package/dist/{edit-BDA0pjWI.js → edit-B1FM9FiW.js} +2 -2
- package/dist/edit.mjs +1 -1
- package/dist/index.mjs +3 -3
- package/dist/node.mjs +1 -1
- package/dist/renderer.mjs +1 -1
- package/dist/static.mjs +2 -2
- package/package.json +17 -17
|
@@ -37,7 +37,7 @@ function createDefaultParticipants(variant) {
|
|
|
37
37
|
*/
|
|
38
38
|
var CHAT_NODE_KEY = "Chat";
|
|
39
39
|
//#endregion
|
|
40
|
-
//#region \0@oxc-project+runtime@0.
|
|
40
|
+
//#region \0@oxc-project+runtime@0.142.0/helpers/esm/typeof.js
|
|
41
41
|
function _typeof(o) {
|
|
42
42
|
"@babel/helpers - typeof";
|
|
43
43
|
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(o) {
|
|
@@ -47,7 +47,7 @@ function _typeof(o) {
|
|
|
47
47
|
}, _typeof(o);
|
|
48
48
|
}
|
|
49
49
|
//#endregion
|
|
50
|
-
//#region \0@oxc-project+runtime@0.
|
|
50
|
+
//#region \0@oxc-project+runtime@0.142.0/helpers/esm/toPrimitive.js
|
|
51
51
|
function toPrimitive(t, r) {
|
|
52
52
|
if ("object" != _typeof(t) || !t) return t;
|
|
53
53
|
var e = t[Symbol.toPrimitive];
|
|
@@ -59,13 +59,13 @@ function toPrimitive(t, r) {
|
|
|
59
59
|
return ("string" === r ? String : Number)(t);
|
|
60
60
|
}
|
|
61
61
|
//#endregion
|
|
62
|
-
//#region \0@oxc-project+runtime@0.
|
|
62
|
+
//#region \0@oxc-project+runtime@0.142.0/helpers/esm/toPropertyKey.js
|
|
63
63
|
function toPropertyKey(t) {
|
|
64
64
|
var i = toPrimitive(t, "string");
|
|
65
65
|
return "symbol" == _typeof(i) ? i : i + "";
|
|
66
66
|
}
|
|
67
67
|
//#endregion
|
|
68
|
-
//#region \0@oxc-project+runtime@0.
|
|
68
|
+
//#region \0@oxc-project+runtime@0.142.0/helpers/esm/defineProperty.js
|
|
69
69
|
function _defineProperty(e, r, t) {
|
|
70
70
|
return (r = toPropertyKey(r)) in e ? Object.defineProperty(e, r, {
|
|
71
71
|
value: t,
|
|
@@ -93,9 +93,10 @@ var Avatar = ({ participant, dark, small }) => {
|
|
|
93
93
|
src: participant.avatar
|
|
94
94
|
})
|
|
95
95
|
});
|
|
96
|
+
const initial = (participant.name ?? defaultName(participant.kind)).trim().charAt(0).toUpperCase() || "?";
|
|
96
97
|
return /* @__PURE__ */ jsx("span", {
|
|
97
98
|
className,
|
|
98
|
-
children:
|
|
99
|
+
children: initial
|
|
99
100
|
});
|
|
100
101
|
};
|
|
101
102
|
var Markdown = ({ content }) => /* @__PURE__ */ jsx(Streamdown, {
|
|
@@ -138,8 +139,9 @@ var UserUserRow = ({ message, participants, isRight }) => {
|
|
|
138
139
|
const participant = resolveParticipant(participants, message.participantId);
|
|
139
140
|
const displayName = participant.name ?? defaultName(participant.kind);
|
|
140
141
|
const tailClass = isRight ? bubbleRightTail : bubbleLeftTail;
|
|
142
|
+
const clusterClass = `${authorCluster}${isRight ? ` ${authorClusterRight}` : ""}`;
|
|
141
143
|
const cluster = /* @__PURE__ */ jsxs("div", {
|
|
142
|
-
className:
|
|
144
|
+
className: clusterClass,
|
|
143
145
|
children: [/* @__PURE__ */ jsx("span", {
|
|
144
146
|
className: `${authorLabel} ${semanticClassNames.author}`,
|
|
145
147
|
children: displayName
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ChatRenderer.d.ts","sourceRoot":"","sources":["../src/ChatRenderer.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"ChatRenderer.d.ts","sourceRoot":"","sources":["../src/ChatRenderer.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAkB,EAAE,EAAgB,MAAM,OAAO,CAAC;AAI9D,OAAO,KAAK,EAIV,iBAAiB,EAElB,MAAM,SAAS,CAAC;AAsIjB,eAAO,MAAM,YAAY,EAAE,EAAE,CAAC,iBAAiB,CA8B9C,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { A as variantPill, C as participantLabel, D as rail, E as participantRow, M as variantPillHint, N as variantPillName, O as sectionLabel, P as variantStack, S as participantInput, T as participantPillUser, _ as modalBody, a as buttonGhost, b as pane, c as editLabel, d as messageActions, f as messageCard, g as modal, h as messageTextarea, i as button, j as variantPillActive, k as semanticClassNames, l as editOverlay, m as messageSelect, n as addMessage, o as buttonPrimary, p as messageHead, r as addMessageButton, s as editContainer, t as ChatRenderer, u as editorDialogPopup, v as modalFooter, w as participantPill, x as participantCard, y as modalHeader } from "./ChatRenderer-
|
|
2
|
-
import { i as _defineProperty, n as $isChatNode, o as createMessageId, r as ChatNode } from "./ChatNode-
|
|
1
|
+
import { A as variantPill, C as participantLabel, D as rail, E as participantRow, M as variantPillHint, N as variantPillName, O as sectionLabel, P as variantStack, S as participantInput, T as participantPillUser, _ as modalBody, a as buttonGhost, b as pane, c as editLabel, d as messageActions, f as messageCard, g as modal, h as messageTextarea, i as button, j as variantPillActive, k as semanticClassNames, l as editOverlay, m as messageSelect, n as addMessage, o as buttonPrimary, p as messageHead, r as addMessageButton, s as editContainer, t as ChatRenderer, u as editorDialogPopup, v as modalFooter, w as participantPill, x as participantCard, y as modalHeader } from "./ChatRenderer-aRyOSnat.js";
|
|
2
|
+
import { i as _defineProperty, n as $isChatNode, o as createMessageId, r as ChatNode } from "./ChatNode-SYkdpaVD.js";
|
|
3
3
|
import { $getNodeByKey, $insertNodes } from "lexical";
|
|
4
4
|
import { ArrowDown, ArrowUp, MessageSquare, Pencil, Trash2 } from "lucide-react";
|
|
5
5
|
import { createElement, useCallback, useEffect, useRef, useState } from "react";
|
package/dist/edit.mjs
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { t as __augmentLoaded_chat } from "./augment-jeNYpQAa.js";
|
|
2
|
-
import { a as ChatEditDecorator, i as ChatEditNode, n as $createChatEditNode, o as ChatEditRenderer, r as $isChatEditNode, s as ChatEditorModal, t as chatEditNodes } from "./edit-
|
|
2
|
+
import { a as ChatEditDecorator, i as ChatEditNode, n as $createChatEditNode, o as ChatEditRenderer, r as $isChatEditNode, s as ChatEditorModal, t as chatEditNodes } from "./edit-B1FM9FiW.js";
|
|
3
3
|
export { $createChatEditNode, $isChatEditNode, ChatEditDecorator, ChatEditNode, ChatEditRenderer, ChatEditorModal, __augmentLoaded_chat, chatEditNodes };
|
package/dist/index.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { t as __augmentLoaded_chat } from "./augment-jeNYpQAa.js";
|
|
2
|
-
import { t as ChatRenderer } from "./ChatRenderer-
|
|
3
|
-
import { a as CHAT_NODE_KEY, n as $isChatNode, r as ChatNode, t as $createChatNode } from "./ChatNode-
|
|
4
|
-
import { a as ChatEditDecorator, i as ChatEditNode, n as $createChatEditNode, o as ChatEditRenderer, r as $isChatEditNode, s as ChatEditorModal, t as chatEditNodes } from "./edit-
|
|
2
|
+
import { t as ChatRenderer } from "./ChatRenderer-aRyOSnat.js";
|
|
3
|
+
import { a as CHAT_NODE_KEY, n as $isChatNode, r as ChatNode, t as $createChatNode } from "./ChatNode-SYkdpaVD.js";
|
|
4
|
+
import { a as ChatEditDecorator, i as ChatEditNode, n as $createChatEditNode, o as ChatEditRenderer, r as $isChatEditNode, s as ChatEditorModal, t as chatEditNodes } from "./edit-B1FM9FiW.js";
|
|
5
5
|
import { chatNodes } from "./node.mjs";
|
|
6
6
|
import "./renderer.mjs";
|
|
7
7
|
export { $createChatEditNode, $createChatNode, $isChatEditNode, $isChatNode, CHAT_NODE_KEY, ChatEditDecorator, ChatEditNode, ChatEditRenderer, ChatEditorModal, ChatNode, ChatRenderer, __augmentLoaded_chat, chatEditNodes, chatNodes };
|
package/dist/node.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { t as __augmentLoaded_chat } from "./augment-jeNYpQAa.js";
|
|
2
|
-
import { a as CHAT_NODE_KEY, n as $isChatNode, r as ChatNode, t as $createChatNode } from "./ChatNode-
|
|
2
|
+
import { a as CHAT_NODE_KEY, n as $isChatNode, r as ChatNode, t as $createChatNode } from "./ChatNode-SYkdpaVD.js";
|
|
3
3
|
//#region src/node.ts
|
|
4
4
|
var chatNodes = [ChatNode];
|
|
5
5
|
//#endregion
|
package/dist/renderer.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { t as __augmentLoaded_chat } from "./augment-jeNYpQAa.js";
|
|
2
|
-
import { t as ChatRenderer } from "./ChatRenderer-
|
|
2
|
+
import { t as ChatRenderer } from "./ChatRenderer-aRyOSnat.js";
|
|
3
3
|
//#region src/renderer.ts
|
|
4
4
|
var renderer_default = ChatRenderer;
|
|
5
5
|
//#endregion
|
package/dist/static.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { t as __augmentLoaded_chat } from "./augment-jeNYpQAa.js";
|
|
2
|
-
import { t as ChatRenderer } from "./ChatRenderer-
|
|
3
|
-
import { a as CHAT_NODE_KEY, n as $isChatNode, r as ChatNode, t as $createChatNode } from "./ChatNode-
|
|
2
|
+
import { t as ChatRenderer } from "./ChatRenderer-aRyOSnat.js";
|
|
3
|
+
import { a as CHAT_NODE_KEY, n as $isChatNode, r as ChatNode, t as $createChatNode } from "./ChatNode-SYkdpaVD.js";
|
|
4
4
|
import { chatNodes } from "./node.mjs";
|
|
5
5
|
import "./renderer.mjs";
|
|
6
6
|
export { $createChatNode, $isChatNode, CHAT_NODE_KEY, ChatNode, ChatRenderer, __augmentLoaded_chat, chatNodes };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@haklex/rich-ext-chat",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.33.0",
|
|
4
4
|
"description": "Static chat-snapshot node for the haklex rich editor",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -42,27 +42,27 @@
|
|
|
42
42
|
"streamdown": "^2.5.0"
|
|
43
43
|
},
|
|
44
44
|
"devDependencies": {
|
|
45
|
-
"@lexical/react": "^0.
|
|
46
|
-
"@types/react": "^19.2.
|
|
47
|
-
"@types/react-dom": "^19.2.
|
|
48
|
-
"@vanilla-extract/css": "^1.21.
|
|
49
|
-
"@vanilla-extract/vite-plugin": "^5.2.
|
|
50
|
-
"lexical": "^0.
|
|
51
|
-
"react": "^19.2.
|
|
52
|
-
"react-dom": "19.2.
|
|
53
|
-
"typescript": "^
|
|
45
|
+
"@lexical/react": "^0.49.0",
|
|
46
|
+
"@types/react": "^19.2.18",
|
|
47
|
+
"@types/react-dom": "^19.2.4",
|
|
48
|
+
"@vanilla-extract/css": "^1.21.2",
|
|
49
|
+
"@vanilla-extract/vite-plugin": "^5.2.6",
|
|
50
|
+
"lexical": "^0.49.0",
|
|
51
|
+
"react": "^19.2.8",
|
|
52
|
+
"react-dom": "^19.2.8",
|
|
53
|
+
"typescript": "^7.0.2",
|
|
54
54
|
"unplugin-dts": "^1.0.3",
|
|
55
|
-
"vite": "^8.
|
|
56
|
-
"@haklex/rich-editor": "0.
|
|
55
|
+
"vite": "^8.2.0",
|
|
56
|
+
"@haklex/rich-editor": "0.33.0"
|
|
57
57
|
},
|
|
58
58
|
"peerDependencies": {
|
|
59
|
-
"@lexical/react": "^0.
|
|
60
|
-
"lexical": "^0.
|
|
59
|
+
"@lexical/react": "^0.49.0",
|
|
60
|
+
"lexical": "^0.49.0",
|
|
61
61
|
"lucide-react": "^1.0.0",
|
|
62
62
|
"react": ">=19",
|
|
63
|
-
"@haklex/rich-editor": "^0.
|
|
64
|
-
"@haklex/rich-editor-ui": "^0.
|
|
65
|
-
"@haklex/rich-style-token": "^0.
|
|
63
|
+
"@haklex/rich-editor": "^0.33.0",
|
|
64
|
+
"@haklex/rich-editor-ui": "^0.33.0",
|
|
65
|
+
"@haklex/rich-style-token": "^0.33.0"
|
|
66
66
|
},
|
|
67
67
|
"publishConfig": {
|
|
68
68
|
"access": "public"
|