@adecore/agents-react 0.54.7 → 0.54.9
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.
|
@@ -2,7 +2,7 @@ import { c as _c } from "react/compiler-runtime";
|
|
|
2
2
|
import { uiChoiceLabel } from '@adecore/intelligent-ui';
|
|
3
3
|
import { DisabledReason, formatShortcut, Icon, KEY_SHORTCUTS, Spinner, Tooltip } from '@adecore/ui';
|
|
4
4
|
import clsx from 'clsx';
|
|
5
|
-
import {
|
|
5
|
+
import { CircleCheck } from 'lucide-react';
|
|
6
6
|
import { useId, useState } from 'react';
|
|
7
7
|
import { useTranslation } from 'react-i18next';
|
|
8
8
|
import { useChatHost } from '../../../../host.js';
|
|
@@ -249,9 +249,13 @@ export function ChoiceRenderer(t0) {
|
|
|
249
249
|
children: [slow ? /*#__PURE__*/_jsx(Spinner, {
|
|
250
250
|
size: 12
|
|
251
251
|
}) : /*#__PURE__*/_jsx(Icon, {
|
|
252
|
-
icon:
|
|
253
|
-
size: 12
|
|
254
|
-
|
|
252
|
+
icon: CircleCheck,
|
|
253
|
+
size: 12,
|
|
254
|
+
className: clsx(!strong && "text-positive")
|
|
255
|
+
}), answer.state === "queued" ? t("blocks.choice.queued") : /*#__PURE__*/_jsx("span", {
|
|
256
|
+
className: "sr-only",
|
|
257
|
+
children: t("blocks.choice.sent")
|
|
258
|
+
})]
|
|
255
259
|
});
|
|
256
260
|
$[38] = answer;
|
|
257
261
|
$[39] = chosen;
|
|
@@ -3,7 +3,7 @@ import { WAITING_NOTE_PREFIX } from '@adecore/agent-contracts';
|
|
|
3
3
|
import { Icon, IconButton, MiddleTruncate, Tooltip, useTickingText } from '@adecore/ui';
|
|
4
4
|
import { formatAgo, formatElapsedShort, formatMoment, formatTokens } from '@adecore/ui/format';
|
|
5
5
|
import clsx from 'clsx';
|
|
6
|
-
import { Bot, Brain,
|
|
6
|
+
import { Bot, Brain, ChevronDown, CircleAlert, CircleCheck, CircleX, File, Info, MessageCircleQuestionMark, Reply, Send, SquareTerminal, TriangleAlert } from 'lucide-react';
|
|
7
7
|
import { useContext, useState } from 'react';
|
|
8
8
|
import { useTranslation } from 'react-i18next';
|
|
9
9
|
import { useChatHost } from '../../../host.js';
|
|
@@ -2381,19 +2381,21 @@ function _temp0(row) {
|
|
|
2381
2381
|
}
|
|
2382
2382
|
const DECISION_ICON = {
|
|
2383
2383
|
allow: /*#__PURE__*/_jsx(Icon, {
|
|
2384
|
-
icon:
|
|
2385
|
-
size: 12
|
|
2384
|
+
icon: CircleCheck,
|
|
2385
|
+
size: 12,
|
|
2386
|
+
className: "text-positive"
|
|
2386
2387
|
}),
|
|
2387
2388
|
'allow-always': /*#__PURE__*/_jsx(Icon, {
|
|
2388
|
-
icon:
|
|
2389
|
-
size: 12
|
|
2389
|
+
icon: CircleCheck,
|
|
2390
|
+
size: 12,
|
|
2391
|
+
className: "text-positive"
|
|
2390
2392
|
}),
|
|
2391
2393
|
deny: /*#__PURE__*/_jsx(Icon, {
|
|
2392
|
-
icon:
|
|
2394
|
+
icon: CircleX,
|
|
2393
2395
|
size: 12
|
|
2394
2396
|
}),
|
|
2395
2397
|
cancelled: /*#__PURE__*/_jsx(Icon, {
|
|
2396
|
-
icon:
|
|
2398
|
+
icon: CircleX,
|
|
2397
2399
|
size: 12
|
|
2398
2400
|
})
|
|
2399
2401
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@adecore/agents-react",
|
|
3
|
-
"version": "0.54.
|
|
3
|
+
"version": "0.54.9",
|
|
4
4
|
"description": "React agent chat threads, composers, approvals, provider accounts and usage views.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": {
|
|
@@ -72,12 +72,12 @@
|
|
|
72
72
|
"test:visuals": "bun --config=integration.bunfig.toml --conditions=source test ./src/chat/visual-viewport.integration.test.ts"
|
|
73
73
|
},
|
|
74
74
|
"dependencies": {
|
|
75
|
-
"@adecore/agent-contracts": "0.54.
|
|
76
|
-
"@adecore/editor": "0.54.
|
|
77
|
-
"@adecore/editor-react": "0.54.
|
|
78
|
-
"@adecore/intelligent-ui": "0.54.
|
|
79
|
-
"@adecore/merge": "0.54.
|
|
80
|
-
"@adecore/utils": "0.54.
|
|
75
|
+
"@adecore/agent-contracts": "0.54.9",
|
|
76
|
+
"@adecore/editor": "0.54.9",
|
|
77
|
+
"@adecore/editor-react": "0.54.9",
|
|
78
|
+
"@adecore/intelligent-ui": "0.54.9",
|
|
79
|
+
"@adecore/merge": "0.54.9",
|
|
80
|
+
"@adecore/utils": "0.54.9",
|
|
81
81
|
"@codemirror/commands": "^6.11.1",
|
|
82
82
|
"@codemirror/language": "^6.13.1",
|
|
83
83
|
"@codemirror/state": "^6.7.6",
|
|
@@ -101,14 +101,14 @@
|
|
|
101
101
|
"zustand": "^5.0.16"
|
|
102
102
|
},
|
|
103
103
|
"peerDependencies": {
|
|
104
|
-
"@adecore/ui": "^0.54.
|
|
104
|
+
"@adecore/ui": "^0.54.9",
|
|
105
105
|
"i18next": "^26.4.2",
|
|
106
106
|
"react": "^19.3.0",
|
|
107
107
|
"react-dom": "^19.3.0",
|
|
108
108
|
"react-i18next": "^17.0.15"
|
|
109
109
|
},
|
|
110
110
|
"devDependencies": {
|
|
111
|
-
"@adecore/ui": "0.54.
|
|
111
|
+
"@adecore/ui": "0.54.9",
|
|
112
112
|
"@types/bun": "^1.4.4",
|
|
113
113
|
"@types/react": "^19.3.0",
|
|
114
114
|
"@types/react-dom": "^19.3.0",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { uiChoiceLabel, type UiProps } from '@adecore/intelligent-ui';
|
|
2
2
|
import { DisabledReason, formatShortcut, Icon, KEY_SHORTCUTS, Spinner, Tooltip } from '@adecore/ui';
|
|
3
3
|
import clsx from 'clsx';
|
|
4
|
-
import {
|
|
4
|
+
import { CircleCheck } from 'lucide-react';
|
|
5
5
|
import { useId, useState } from 'react';
|
|
6
6
|
import { useTranslation } from 'react-i18next';
|
|
7
7
|
import { useChatHost } from '../../../../host';
|
|
@@ -98,8 +98,9 @@ export function ChoiceRenderer({ node, children, context }: UiRendererProps<UiPr
|
|
|
98
98
|
)}
|
|
99
99
|
{chosen && (
|
|
100
100
|
<span className={clsx('flex shrink-0 items-center gap-1 text-2xs', strong ? 'text-accent-text' : 'text-accent')}>
|
|
101
|
-
{slow ? <Spinner size={12} /> : <Icon icon={
|
|
102
|
-
{
|
|
101
|
+
{slow ? <Spinner size={12} /> : <Icon icon={CircleCheck} size={12} className={clsx(!strong && 'text-positive')} />}
|
|
102
|
+
{/* The mark says it was sent; the word stays for a screen reader. */}
|
|
103
|
+
{answer.state === 'queued' ? t('blocks.choice.queued') : <span className="sr-only">{t('blocks.choice.sent')}</span>}
|
|
103
104
|
</span>
|
|
104
105
|
)}
|
|
105
106
|
</button>
|
|
@@ -17,17 +17,17 @@ import clsx from 'clsx';
|
|
|
17
17
|
import {
|
|
18
18
|
Bot,
|
|
19
19
|
Brain,
|
|
20
|
-
Check,
|
|
21
20
|
ChevronDown,
|
|
22
21
|
CircleAlert,
|
|
22
|
+
CircleCheck,
|
|
23
|
+
CircleX,
|
|
23
24
|
File,
|
|
24
25
|
Info,
|
|
25
26
|
MessageCircleQuestionMark,
|
|
26
27
|
Reply,
|
|
27
28
|
Send,
|
|
28
29
|
SquareTerminal,
|
|
29
|
-
TriangleAlert
|
|
30
|
-
X
|
|
30
|
+
TriangleAlert
|
|
31
31
|
} from 'lucide-react';
|
|
32
32
|
import { useContext, useState, type ReactNode } from 'react';
|
|
33
33
|
import { useTranslation } from 'react-i18next';
|
|
@@ -742,10 +742,10 @@ export function SelectionSwitchRow({ chatId, from, to }: { chatId: string; from:
|
|
|
742
742
|
}
|
|
743
743
|
|
|
744
744
|
const DECISION_ICON: Record<Exclude<ChatApprovalItem['decision'], 'pending'>, ReactNode> = {
|
|
745
|
-
allow: <Icon icon={
|
|
746
|
-
'allow-always': <Icon icon={
|
|
747
|
-
deny: <Icon icon={
|
|
748
|
-
cancelled: <Icon icon={
|
|
745
|
+
allow: <Icon icon={CircleCheck} size={12} className="text-positive" />,
|
|
746
|
+
'allow-always': <Icon icon={CircleCheck} size={12} className="text-positive" />,
|
|
747
|
+
deny: <Icon icon={CircleX} size={12} />,
|
|
748
|
+
cancelled: <Icon icon={CircleX} size={12} />
|
|
749
749
|
};
|
|
750
750
|
|
|
751
751
|
/* The outcome of a permission request, one quiet line; the request itself lived on the composer. */
|