@epam/ai-dial-conversation-stages 1.1.0-dev.182 → 1.1.0-dev.184
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/components/CollapsedGroup/CollapsedGroup.d.ts.map +1 -1
- package/index.css +1 -1
- package/index.js +82 -78
- package/package.json +2 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CollapsedGroup.d.ts","sourceRoot":"","sources":["../../../src/components/CollapsedGroup/CollapsedGroup.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CollapsedGroup.d.ts","sourceRoot":"","sources":["../../../src/components/CollapsedGroup/CollapsedGroup.tsx"],"names":[],"mappings":"AAgBA,OAAO,EAAE,EAAE,EAA+B,MAAM,OAAO,CAAC;AACxD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AAUxE,gJAAgJ;AAChJ,eAAO,MAAM,cAAc,EAAE,EAAE,CAAC,mBAAmB,CAyOlD,CAAC"}
|
package/index.css
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
._panel_vd48n_1{color:var(--cs-text,var(--text-primary,#161b2d))}._row_vd48n_5:hover{background:var(--cs-row-hover,var(--bg-layer-sunken,#eef1f7))}._collapseButton_vd48n_9{background:var(--cs-button-bg,transparent)}._stageName_vd48n_13{color:var(--cs-stage-text,var(--text-secondary,#57647a))}._stageNameFailed_vd48n_17{color:var(--cs-failed-text,var(--text-warning,#7f6300))}._monoName_vd48n_21{font-family:ui-monospace,SF Mono,Menlo,Consolas,monospace}._tag_vd48n_25{color:var(--cs-tag-text,var(--text-tertiary,#848e9c))}._count_vd48n_29{color:var(--cs-count-text,var(--text-tertiary,#848e9c));font-variant-numeric:tabular-nums}._duration_vd48n_34{color:var(--cs-duration-text,var(--text-tertiary,#848e9c));font-variant-numeric:tabular-nums}._iconSecondary_vd48n_39{color:var(--cs-icon-secondary,var(--text-secondary,#57647a));opacity:.7}._iconCompleted_vd48n_44{color:var(--cs-icon-completed,var(--text-tertiary,#848e9c))}._iconError_vd48n_48{color:var(--cs-icon-error,var(--text-warning,#7f6300))}._stageContent_vd48n_52{color:var(--cs-stage-text,var(--text-secondary,#57647a))}._codeBlock_vd48n_56{background:var(--cs-code-bg,var(--bg-layer-raised,#fcfcfc));border-color:var(--cs-code-border,var(--stroke-secondary,#d1dbea));color:var(--cs-code-text,var(--text-primary,#161b2d))}._codeInline_vd48n_62{background:var(--cs-code-bg,var(--bg-layer-raised,#fcfcfc));border:1px solid var(--cs-code-border,var(--stroke-secondary,#d1dbea));color:var(--cs-code-text,var(--text-primary,#161b2d))}._blockquote_vd48n_68{border-color:var(--cs-stage-text,var(--text-secondary,#57647a));color:var(--cs-stage-text,var(--text-secondary,#57647a))}._tableCell_vd48n_73{border-color:var(--cs-border,var(--stroke-secondary,#d1dbea));color:var(--cs-stage-text,var(--text-secondary,#57647a))}.
|
|
1
|
+
._panel_vd48n_1{color:var(--cs-text,var(--text-primary,#161b2d))}._row_vd48n_5:hover{background:var(--cs-row-hover,var(--bg-layer-sunken,#eef1f7))}._collapseButton_vd48n_9{background:var(--cs-button-bg,transparent)}._stageName_vd48n_13{color:var(--cs-stage-text,var(--text-secondary,#57647a))}._stageNameFailed_vd48n_17{color:var(--cs-failed-text,var(--text-warning,#7f6300))}._monoName_vd48n_21{font-family:ui-monospace,SF Mono,Menlo,Consolas,monospace}._tag_vd48n_25{color:var(--cs-tag-text,var(--text-tertiary,#848e9c))}._count_vd48n_29{color:var(--cs-count-text,var(--text-tertiary,#848e9c));font-variant-numeric:tabular-nums}._duration_vd48n_34{color:var(--cs-duration-text,var(--text-tertiary,#848e9c));font-variant-numeric:tabular-nums}._iconSecondary_vd48n_39{color:var(--cs-icon-secondary,var(--text-secondary,#57647a));opacity:.7}._iconCompleted_vd48n_44{color:var(--cs-icon-completed,var(--text-tertiary,#848e9c))}._iconError_vd48n_48{color:var(--cs-icon-error,var(--text-warning,#7f6300))}._stageContent_vd48n_52{color:var(--cs-stage-text,var(--text-secondary,#57647a))}._codeBlock_vd48n_56{background:var(--cs-code-bg,var(--bg-layer-raised,#fcfcfc));border-color:var(--cs-code-border,var(--stroke-secondary,#d1dbea));color:var(--cs-code-text,var(--text-primary,#161b2d))}._codeInline_vd48n_62{background:var(--cs-code-bg,var(--bg-layer-raised,#fcfcfc));border:1px solid var(--cs-code-border,var(--stroke-secondary,#d1dbea));color:var(--cs-code-text,var(--text-primary,#161b2d))}._blockquote_vd48n_68{border-color:var(--cs-stage-text,var(--text-secondary,#57647a));color:var(--cs-stage-text,var(--text-secondary,#57647a))}._tableCell_vd48n_73{border-color:var(--cs-border,var(--stroke-secondary,#d1dbea));color:var(--cs-stage-text,var(--text-secondary,#57647a))}._toggleButton_1sa5v_1{color:var(--cs-cg-label,var(--text-secondary,#57647a));text-align:start;width:100%;min-width:0;justify-content:flex-start!important}._toggleButton_1sa5v_1:hover{color:var(--cs-cg-label-hover,var(--text-primary,#161b2d))}._executedLabel_1sa5v_13{color:var(--cs-cg-label,var(--text-secondary,#57647a))}._stepsCount_1sa5v_17{color:var(--cs-cg-steps-count,var(--text-tertiary,#848e9c));font-variant-numeric:tabular-nums}._doneIcon_1sa5v_22{color:var(--cs-cg-done,var(--text-success,#007274))}._failedText_1sa5v_26{color:var(--cs-cg-failed,var(--text-warning,#7f6300))}._liveName_1sa5v_30{color:var(--cs-cg-label,var(--text-primary,#161b2d))}
|
|
2
2
|
/*$vite$:1*/
|
package/index.js
CHANGED
|
@@ -294,107 +294,110 @@ var w = /[([][^()[\]]*[)\]]/g, T = /(\d+(?:\.\d+)?)\s*s\b/, E = /:\s*$/, D = (e)
|
|
|
294
294
|
})
|
|
295
295
|
});
|
|
296
296
|
}, V = {
|
|
297
|
-
toggleButton: "
|
|
298
|
-
executedLabel: "
|
|
299
|
-
stepsCount: "
|
|
300
|
-
doneIcon: "
|
|
301
|
-
failedText: "
|
|
302
|
-
liveName: "
|
|
303
|
-
}, H = ({ stages: e, isStreaming: r, labels:
|
|
304
|
-
let { executedLabel:
|
|
297
|
+
toggleButton: "_toggleButton_1sa5v_1",
|
|
298
|
+
executedLabel: "_executedLabel_1sa5v_13",
|
|
299
|
+
stepsCount: "_stepsCount_1sa5v_17",
|
|
300
|
+
doneIcon: "_doneIcon_1sa5v_22",
|
|
301
|
+
failedText: "_failedText_1sa5v_26",
|
|
302
|
+
liveName: "_liveName_1sa5v_30"
|
|
303
|
+
}, H = ({ stages: e, isStreaming: r, labels: s, className: c, styles: d }) => {
|
|
304
|
+
let { executedLabel: h = "Executed", stepsLabel: g = () => "steps", failedCountLabel: _ = (e) => `${e} failed`, runningStepLabel: x = (e, t) => `Step ${e} of ${t}`, runningAriaLabel: w = "Running", copyAriaLabel: T, failedAriaLabel: E, attemptLabel: O } = s ?? {}, [N, P] = b(r), F = y(r);
|
|
305
305
|
v(() => {
|
|
306
|
-
|
|
306
|
+
F.current && !r && P(!1), F.current = r;
|
|
307
307
|
}, [r]);
|
|
308
|
-
let { colors:
|
|
309
|
-
"--cs-cg-label":
|
|
310
|
-
"--cs-cg-label-hover":
|
|
311
|
-
"--cs-cg-steps-count":
|
|
312
|
-
"--cs-cg-done":
|
|
313
|
-
"--cs-cg-failed":
|
|
314
|
-
"--cs-text":
|
|
315
|
-
"--cs-row-hover":
|
|
316
|
-
"--cs-button-bg":
|
|
317
|
-
"--cs-stage-text":
|
|
318
|
-
"--cs-failed-text":
|
|
319
|
-
"--cs-tag-text":
|
|
320
|
-
"--cs-count-text":
|
|
321
|
-
"--cs-duration-text":
|
|
322
|
-
"--cs-icon-secondary":
|
|
323
|
-
"--cs-icon-completed":
|
|
324
|
-
"--cs-icon-error":
|
|
325
|
-
"--cs-code-bg":
|
|
326
|
-
"--cs-code-border":
|
|
327
|
-
"--cs-code-text":
|
|
328
|
-
"--cs-border":
|
|
308
|
+
let { colors: I, panel: L } = d ?? {}, R = d?.typography ?? { fontClassName: "dial-small-text" }, z = n({
|
|
309
|
+
"--cs-cg-label": I?.labelColor,
|
|
310
|
+
"--cs-cg-label-hover": I?.labelHoverColor,
|
|
311
|
+
"--cs-cg-steps-count": I?.stepsCountColor,
|
|
312
|
+
"--cs-cg-done": I?.doneColor,
|
|
313
|
+
"--cs-cg-failed": I?.failedColor,
|
|
314
|
+
"--cs-text": L?.text,
|
|
315
|
+
"--cs-row-hover": L?.rowHoverColor,
|
|
316
|
+
"--cs-button-bg": L?.collapsedButtonBg,
|
|
317
|
+
"--cs-stage-text": L?.stageTextColor,
|
|
318
|
+
"--cs-failed-text": L?.failedColor,
|
|
319
|
+
"--cs-tag-text": L?.tagTextColor,
|
|
320
|
+
"--cs-count-text": L?.countTextColor,
|
|
321
|
+
"--cs-duration-text": L?.durationTextColor,
|
|
322
|
+
"--cs-icon-secondary": L?.iconSecondaryColor,
|
|
323
|
+
"--cs-icon-completed": L?.iconCompletedColor,
|
|
324
|
+
"--cs-icon-error": L?.iconErrorColor,
|
|
325
|
+
"--cs-code-bg": L?.codeBg,
|
|
326
|
+
"--cs-code-border": L?.codeBorderColor,
|
|
327
|
+
"--cs-code-text": L?.codeTextColor,
|
|
328
|
+
"--cs-border": L?.borderColor
|
|
329
329
|
});
|
|
330
330
|
if (e.length === 0) return null;
|
|
331
|
-
let
|
|
332
|
-
copyAriaLabel:
|
|
333
|
-
runningAriaLabel:
|
|
334
|
-
failedAriaLabel:
|
|
335
|
-
attemptLabel:
|
|
331
|
+
let H = {
|
|
332
|
+
copyAriaLabel: T,
|
|
333
|
+
runningAriaLabel: w,
|
|
334
|
+
failedAriaLabel: E,
|
|
335
|
+
attemptLabel: O
|
|
336
336
|
};
|
|
337
337
|
if (e.length === 1) return /* @__PURE__ */ S(B, {
|
|
338
338
|
stages: e,
|
|
339
339
|
isStreaming: r,
|
|
340
|
-
className:
|
|
340
|
+
className: c,
|
|
341
341
|
styles: {
|
|
342
|
-
colors:
|
|
343
|
-
typography:
|
|
342
|
+
colors: L,
|
|
343
|
+
typography: d?.typography
|
|
344
344
|
},
|
|
345
|
-
labels:
|
|
345
|
+
labels: H
|
|
346
346
|
});
|
|
347
|
-
let
|
|
347
|
+
let U = e.some((e) => e.status === t.Failed), W = e.reduce((e, t) => {
|
|
348
348
|
let { durationLabel: n } = D(t.name);
|
|
349
349
|
return e + (A(n) ?? 0);
|
|
350
|
-
}, 0),
|
|
350
|
+
}, 0), G = W > 0 ? k(W) : void 0, K = r ? j(e) : void 0, q;
|
|
351
351
|
if (r) {
|
|
352
|
-
let t =
|
|
353
|
-
|
|
352
|
+
let t = K ? M(e, K) : e.length, n = K ? D(K.name).name : "";
|
|
353
|
+
q = /* @__PURE__ */ C("span", {
|
|
354
354
|
role: "status",
|
|
355
355
|
"aria-live": "polite",
|
|
356
|
-
className: "
|
|
356
|
+
className: "flex min-w-0 items-center gap-2",
|
|
357
357
|
children: [
|
|
358
|
-
/* @__PURE__ */ S(
|
|
359
|
-
|
|
360
|
-
|
|
358
|
+
/* @__PURE__ */ S("span", {
|
|
359
|
+
className: "flex flex-none items-center",
|
|
360
|
+
children: /* @__PURE__ */ S(u, {
|
|
361
|
+
size: 14,
|
|
362
|
+
ariaLabel: w
|
|
363
|
+
})
|
|
361
364
|
}),
|
|
362
365
|
/* @__PURE__ */ S("span", {
|
|
363
|
-
className: i(
|
|
364
|
-
children:
|
|
366
|
+
className: i("flex-none whitespace-nowrap", R.fontClassName, V.liveName),
|
|
367
|
+
children: x(t, e.length)
|
|
365
368
|
}),
|
|
366
369
|
n && /* @__PURE__ */ S("span", {
|
|
367
|
-
className: i(
|
|
368
|
-
children: n
|
|
370
|
+
className: i("min-w-0 max-w-[22rem] truncate", R.fontClassName, V.executedLabel),
|
|
371
|
+
children: /* @__PURE__ */ S(o, { text: n })
|
|
369
372
|
})
|
|
370
373
|
]
|
|
371
374
|
});
|
|
372
|
-
} else if (
|
|
375
|
+
} else if (U) {
|
|
373
376
|
let n = e.filter((e) => e.status === t.Failed).length;
|
|
374
|
-
|
|
377
|
+
q = /* @__PURE__ */ C("span", {
|
|
375
378
|
className: "inline-flex items-center gap-1",
|
|
376
379
|
children: [
|
|
377
380
|
/* @__PURE__ */ C("span", {
|
|
378
|
-
className: i(
|
|
381
|
+
className: i(R.fontClassName, V.executedLabel),
|
|
379
382
|
children: [
|
|
380
|
-
|
|
383
|
+
h,
|
|
381
384
|
" ",
|
|
382
385
|
e.length,
|
|
383
386
|
" ",
|
|
384
|
-
|
|
387
|
+
g(e.length)
|
|
385
388
|
]
|
|
386
389
|
}),
|
|
387
390
|
/* @__PURE__ */ S("span", {
|
|
388
|
-
className: i(
|
|
389
|
-
children:
|
|
391
|
+
className: i(R.fontClassName, V.failedText),
|
|
392
|
+
children: _(n)
|
|
390
393
|
}),
|
|
391
|
-
|
|
392
|
-
className: i(
|
|
393
|
-
children:
|
|
394
|
+
G && /* @__PURE__ */ S("span", {
|
|
395
|
+
className: i(R.fontClassName, V.stepsCount),
|
|
396
|
+
children: G
|
|
394
397
|
})
|
|
395
398
|
]
|
|
396
399
|
});
|
|
397
|
-
} else
|
|
400
|
+
} else q = /* @__PURE__ */ C("span", {
|
|
398
401
|
className: "inline-flex items-center gap-1",
|
|
399
402
|
children: [
|
|
400
403
|
/* @__PURE__ */ S(f, {
|
|
@@ -403,29 +406,30 @@ var w = /[([][^()[\]]*[)\]]/g, T = /(\d+(?:\.\d+)?)\s*s\b/, E = /:\s*$/, D = (e)
|
|
|
403
406
|
"aria-hidden": !0
|
|
404
407
|
}),
|
|
405
408
|
/* @__PURE__ */ C("span", {
|
|
406
|
-
className: i(
|
|
409
|
+
className: i(R.fontClassName, V.executedLabel),
|
|
407
410
|
children: [
|
|
408
|
-
|
|
411
|
+
h,
|
|
409
412
|
" ",
|
|
410
413
|
e.length,
|
|
411
414
|
" ",
|
|
412
|
-
|
|
415
|
+
g(e.length)
|
|
413
416
|
]
|
|
414
417
|
}),
|
|
415
|
-
|
|
416
|
-
className: i(
|
|
417
|
-
children:
|
|
418
|
+
G && /* @__PURE__ */ S("span", {
|
|
419
|
+
className: i(R.fontClassName, V.stepsCount),
|
|
420
|
+
children: G
|
|
418
421
|
})
|
|
419
422
|
]
|
|
420
423
|
});
|
|
421
424
|
return /* @__PURE__ */ C("div", {
|
|
422
|
-
style:
|
|
423
|
-
className: i("flex w-full flex-col gap-1",
|
|
425
|
+
style: z,
|
|
426
|
+
className: i("flex w-full flex-col gap-1", c),
|
|
424
427
|
children: [/* @__PURE__ */ S(l, {
|
|
425
428
|
className: V.toggleButton,
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
+
textClassName: "min-w-0",
|
|
430
|
+
onClick: () => P((e) => !e),
|
|
431
|
+
"aria-expanded": N,
|
|
432
|
+
iconAfter: N ? /* @__PURE__ */ S(p, {
|
|
429
433
|
size: 12,
|
|
430
434
|
"aria-hidden": !0
|
|
431
435
|
}) : /* @__PURE__ */ S(m, {
|
|
@@ -433,19 +437,19 @@ var w = /[([][^()[\]]*[)\]]/g, T = /(\d+(?:\.\d+)?)\s*s\b/, E = /:\s*$/, D = (e)
|
|
|
433
437
|
className: "rtl:scale-x-[-1]",
|
|
434
438
|
"aria-hidden": !0
|
|
435
439
|
}),
|
|
436
|
-
label:
|
|
440
|
+
label: q
|
|
437
441
|
}), /* @__PURE__ */ S("div", {
|
|
438
|
-
className: i("grid transition-[grid-template-rows] duration-300 ease-in-out",
|
|
442
|
+
className: i("grid transition-[grid-template-rows] duration-300 ease-in-out", N ? "grid-rows-[1fr]" : "grid-rows-[0fr]"),
|
|
439
443
|
children: /* @__PURE__ */ S("div", {
|
|
440
444
|
className: "overflow-hidden",
|
|
441
445
|
children: /* @__PURE__ */ S(B, {
|
|
442
446
|
stages: e,
|
|
443
447
|
isStreaming: r,
|
|
444
448
|
styles: {
|
|
445
|
-
colors:
|
|
446
|
-
typography:
|
|
449
|
+
colors: L,
|
|
450
|
+
typography: d?.typography
|
|
447
451
|
},
|
|
448
|
-
labels:
|
|
452
|
+
labels: H,
|
|
449
453
|
className: "pt-1"
|
|
450
454
|
})
|
|
451
455
|
})
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@epam/ai-dial-conversation-stages",
|
|
3
3
|
"description": "Panel for displaying agent processing stages during LLM response streaming",
|
|
4
|
-
"version": "1.1.0-dev.
|
|
4
|
+
"version": "1.1.0-dev.184",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"main": "./index.js",
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
"peerDependencies": {
|
|
20
20
|
"react": "^19.0.0",
|
|
21
21
|
"@tabler/icons-react": "^3.0.0",
|
|
22
|
-
"@epam/ai-dial-chat-shared": "1.1.0-dev.
|
|
22
|
+
"@epam/ai-dial-chat-shared": "1.1.0-dev.184",
|
|
23
23
|
"@epam/ai-dial-ui-kit": "^0.13.0-dev.26"
|
|
24
24
|
},
|
|
25
25
|
"repository": {
|