@done-coding/forge-kit-agent 0.100.1 → 0.100.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.
package/README.md CHANGED
@@ -28,7 +28,7 @@ import "@done-coding/forge-kit-agent/style.css";
28
28
  | `lodash` | `^4.17.21` |
29
29
  | `vue` | `^3.4.0` |
30
30
 
31
- 文档与完整 API:[使用文档](https://done-coding.github.io/done-coding-showcase/docs/)。
31
+ 文档与完整 API:[使用文档](https://done-coding.github.io/forge/)。
32
32
 
33
33
  MIT,Copyright (c) JustSoSu。完整许可见本包 LICENSE。
34
34
 
@@ -1,7 +1,7 @@
1
1
  import _sfc_main from "./AiDialogue.vue2.mjs";
2
2
  /* empty css */
3
3
  import _export_sfc from "../../_virtual/_plugin-vue_export-helper.mjs";
4
- const AiDialogue = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-2da88577"]]);
4
+ const AiDialogue = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-517e169f"]]);
5
5
  export {
6
6
  AiDialogue as default
7
7
  };
@@ -65,10 +65,10 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
65
65
  emit: __emit
66
66
  }) {
67
67
  useCssVars((_ctx) => ({
68
- "v24b11b8b": titleHeightPx.value,
69
- "fe3d968e": unref(emptyCenterOffset),
70
- "v02fd7481": bubbleAvatarDisplay.value,
71
- "d7d6d72c": _ctx.bubbleMaxWidth
68
+ "v656abd16": titleHeightPx.value,
69
+ "d7dc94ba": unref(emptyCenterOffset),
70
+ "v0c1162eb": bubbleAvatarDisplay.value,
71
+ "v02a86880": _ctx.bubbleMaxWidth
72
72
  }));
73
73
  const props = __props;
74
74
  const emits = __emit;
@@ -1,7 +1,7 @@
1
1
  import _sfc_main from "./AiDialogueGroup.vue2.mjs";
2
2
  /* empty css */
3
3
  import _export_sfc from "../../_virtual/_plugin-vue_export-helper.mjs";
4
- const AiDialogueGroup = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-8dff57f8"]]);
4
+ const AiDialogueGroup = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-e9b9fa58"]]);
5
5
  export {
6
6
  AiDialogueGroup as default
7
7
  };
package/es/style.css CHANGED
@@ -377,7 +377,7 @@ to {
377
377
  white-space: nowrap;
378
378
  text-overflow: ellipsis;
379
379
  }
380
- .ai-dialogue[data-v-2da88577] {
380
+ .ai-dialogue[data-v-517e169f] {
381
381
  container-type: inline-size;
382
382
  container-name: dc-agent;
383
383
  height: 100%;
@@ -389,14 +389,14 @@ to {
389
389
  color: var(--dc-agent-text);
390
390
  overflow: hidden;
391
391
  position: relative;
392
- padding-top: calc(var(--v24b11b8b) + var(--dc-agent-space-4) + var(--dc-agent-safe-top));
392
+ padding-top: calc(var(--v656abd16) + var(--dc-agent-space-4) + var(--dc-agent-safe-top));
393
393
  }
394
- .ai-dialogue[data-v-2da88577],
395
- .ai-dialogue[data-v-2da88577] * {
394
+ .ai-dialogue[data-v-517e169f],
395
+ .ai-dialogue[data-v-517e169f] * {
396
396
  box-sizing: border-box;
397
397
  }
398
- .ai-dialogue-title[data-v-2da88577] {
399
- height: calc(var(--v24b11b8b) + var(--dc-agent-safe-top));
398
+ .ai-dialogue-title[data-v-517e169f] {
399
+ height: calc(var(--v656abd16) + var(--dc-agent-safe-top));
400
400
  width: 100%;
401
401
  background-color: var(--dc-agent-bg);
402
402
  color: var(--dc-agent-text);
@@ -411,10 +411,10 @@ to {
411
411
  padding: var(--dc-agent-safe-top) var(--dc-agent-space-4) 0;
412
412
  word-break: break-all;
413
413
  }
414
- .ai-dialogue-title-text[data-v-2da88577] {
414
+ .ai-dialogue-title-text[data-v-517e169f] {
415
415
  width: 100%;
416
416
  }
417
- .ai-dialogue-sender[data-v-2da88577] {
417
+ .ai-dialogue-sender[data-v-517e169f] {
418
418
  position: absolute;
419
419
  width: 100%;
420
420
  height: var(--dc-agent-sender-height);
@@ -423,11 +423,11 @@ to {
423
423
  bottom: calc(var(--dc-agent-safe-bottom) + var(--dc-agent-keyboard-inset));
424
424
  transform: translate(-50%, 0);
425
425
  }
426
- .ai-dialogue-sender_newSession[data-v-2da88577] {
426
+ .ai-dialogue-sender_newSession[data-v-517e169f] {
427
427
  bottom: 50%;
428
- transform: translate(-50%, calc(50% + var(--fe3d968e)));
428
+ transform: translate(-50%, calc(50% + var(--d7dc94ba)));
429
429
  }
430
- .ai-dialogue-sender-header[data-v-2da88577] {
430
+ .ai-dialogue-sender-header[data-v-517e169f] {
431
431
  position: absolute;
432
432
  left: 50%;
433
433
  transform: translateX(-50%);
@@ -435,106 +435,106 @@ to {
435
435
  padding: 0 0 var(--dc-agent-space-6);
436
436
  bottom: 100%;
437
437
  }
438
- .ai-dialogue-sender[data-v-2da88577] .el-sender {
438
+ .ai-dialogue-sender[data-v-517e169f] .el-sender {
439
439
  background-color: var(--dc-agent-bubble-bg);
440
440
  }
441
- .ai-dialogue-sender[data-v-2da88577] .el-sender:after {
441
+ .ai-dialogue-sender[data-v-517e169f] .el-sender:after {
442
442
  border-width: 1px !important;
443
443
  }
444
- .ai-dialogue-sender[data-v-2da88577] .el-sender:focus-within:after {
444
+ .ai-dialogue-sender[data-v-517e169f] .el-sender:focus-within:after {
445
445
  border-color: var(--dc-agent-color-primary) !important;
446
446
  }
447
- .ai-dialogue-sender[data-v-2da88577] .el-sender-header {
447
+ .ai-dialogue-sender[data-v-517e169f] .el-sender-header {
448
448
  border: none !important;
449
449
  }
450
- .ai-dialogue-sender[data-v-2da88577] .el-send-button .el-button {
450
+ .ai-dialogue-sender[data-v-517e169f] .el-send-button .el-button {
451
451
  background-color: var(--dc-agent-color-primary);
452
452
  border-color: var(--dc-agent-color-primary);
453
453
  color: var(--el-color-white, #fff);
454
454
  }
455
- .ai-dialogue-sender[data-v-2da88577] .el-send-button .el-button .loading-svg {
455
+ .ai-dialogue-sender[data-v-517e169f] .el-send-button .el-button .loading-svg {
456
456
  color: var(--el-color-white, #fff);
457
457
  }
458
- .ai-dialogue-sender[data-v-2da88577] .el-send-button .el-button.is-disabled {
458
+ .ai-dialogue-sender[data-v-517e169f] .el-send-button .el-button.is-disabled {
459
459
  background-color: var(--dc-agent-bubble-bg);
460
460
  border-color: transparent;
461
461
  color: var(--dc-agent-text-secondary);
462
462
  }
463
- .ai-dialogue-shim[data-v-2da88577] {
463
+ .ai-dialogue-shim[data-v-517e169f] {
464
464
  width: 100%;
465
465
  height: 100%;
466
466
  padding-bottom: calc(var(--dc-agent-sender-height) + var(--dc-agent-safe-bottom) + var(--dc-agent-keyboard-inset) + var(--dc-agent-space-4));
467
467
  position: relative;
468
468
  }
469
- .ai-dialogue-shim[data-v-2da88577] .el-bubble {
469
+ .ai-dialogue-shim[data-v-517e169f] .el-bubble {
470
470
  width: 100%;
471
471
  max-width: var(--dc-agent-read-width);
472
472
  margin-left: auto;
473
473
  margin-right: auto;
474
474
  }
475
- .ai-dialogue-shim[data-v-2da88577] .el-bubble-avatar {
476
- display: var(--v02fd7481);
475
+ .ai-dialogue-shim[data-v-517e169f] .el-bubble-avatar {
476
+ display: var(--v0c1162eb);
477
477
  }
478
- .ai-dialogue-shim[data-v-2da88577] .el-bubble-end .el-bubble-content {
479
- max-width: var(--d7d6d72c);
478
+ .ai-dialogue-shim[data-v-517e169f] .el-bubble-end .el-bubble-content {
479
+ max-width: var(--v02a86880);
480
480
  }
481
- .ai-dialogue-shim[data-v-2da88577] .el-bubble-end .el-bubble-content-filled {
481
+ .ai-dialogue-shim[data-v-517e169f] .el-bubble-end .el-bubble-content-filled {
482
482
  background-color: var(--dc-agent-bubble-bg);
483
483
  border-radius: var(--dc-agent-radius-lg);
484
484
  }
485
- .ai-dialogue-shim[data-v-2da88577] .el-bubble-start .el-bubble-content {
485
+ .ai-dialogue-shim[data-v-517e169f] .el-bubble-start .el-bubble-content {
486
486
  max-width: 100%;
487
487
  font-size: var(--dc-agent-font-size-base);
488
488
  line-height: var(--dc-agent-line-height-base);
489
489
  border-radius: 0;
490
490
  }
491
- .ai-dialogue-shim[data-v-2da88577] .el-bubble-start .el-bubble-content-filled {
491
+ .ai-dialogue-shim[data-v-517e169f] .el-bubble-start .el-bubble-content-filled {
492
492
  background-color: transparent;
493
493
  }
494
- .ai-dialogue-shim[data-v-2da88577] .el-bubble-start .el-bubble-footer {
494
+ .ai-dialogue-shim[data-v-517e169f] .el-bubble-start .el-bubble-footer {
495
495
  margin-top: 0;
496
496
  align-self: stretch;
497
497
  }
498
- .ai-dialogue-shim[data-v-2da88577] .el-bubble-start .ai-bubble-footer {
498
+ .ai-dialogue-shim[data-v-517e169f] .el-bubble-start .ai-bubble-footer {
499
499
  padding-left: var(--dc-agent-space-4);
500
500
  }
501
501
  @container dc-agent (max-width: 360px) {
502
- .ai-dialogue-shim[data-v-2da88577] .el-bubble-start .ai-bubble-footer {
502
+ .ai-dialogue-shim[data-v-517e169f] .el-bubble-start .ai-bubble-footer {
503
503
  padding-left: var(--dc-agent-space-2);
504
504
  }
505
505
  }
506
- .ai-dialogue-shim[data-v-2da88577] .el-bubble .ai-bubble-actions {
506
+ .ai-dialogue-shim[data-v-517e169f] .el-bubble .ai-bubble-actions {
507
507
  opacity: 0;
508
508
  transition: opacity var(--dc-agent-motion-fast) var(--dc-agent-ease);
509
509
  }
510
- .ai-dialogue-shim[data-v-2da88577] .el-bubble:hover .ai-bubble-actions {
510
+ .ai-dialogue-shim[data-v-517e169f] .el-bubble:hover .ai-bubble-actions {
511
511
  opacity: 1;
512
512
  }
513
513
  @media (hover: none) {
514
- .ai-dialogue-shim[data-v-2da88577] .el-bubble .ai-bubble-actions {
514
+ .ai-dialogue-shim[data-v-517e169f] .el-bubble .ai-bubble-actions {
515
515
  opacity: 1;
516
516
  }
517
517
  }
518
- .ai-dialogue-shim[data-v-2da88577] .el-bubble-list {
518
+ .ai-dialogue-shim[data-v-517e169f] .el-bubble-list {
519
519
  overscroll-behavior: contain;
520
520
  -webkit-overflow-scrolling: touch;
521
521
  }
522
- .ai-dialogue-shim[data-v-2da88577] .el-bubble-list-back-to-bottom-icon {
522
+ .ai-dialogue-shim[data-v-517e169f] .el-bubble-list-back-to-bottom-icon {
523
523
  overflow: hidden;
524
524
  }
525
- .ai-dialogue-shim[data-v-2da88577] .el-bubble-list-default-back-button {
525
+ .ai-dialogue-shim[data-v-517e169f] .el-bubble-list-default-back-button {
526
526
  background-color: var(--dc-agent-bg);
527
527
  border: var(--dc-agent-border-width-hairline) solid var(--dc-agent-border);
528
528
  box-shadow: var(--dc-agent-shadow);
529
529
  }
530
- .ai-dialogue-shim_noScrollAnimation[data-v-2da88577] .el-bubble-list {
530
+ .ai-dialogue-shim_noScrollAnimation[data-v-517e169f] .el-bubble-list {
531
531
  scroll-behavior: auto !important;
532
532
  }
533
533
  @media (prefers-reduced-motion: reduce) {
534
- .ai-dialogue .ai-dialogue-sender[data-v-2da88577] {
534
+ .ai-dialogue .ai-dialogue-sender[data-v-517e169f] {
535
535
  transition: none;
536
536
  }
537
- .ai-dialogue[data-v-2da88577] .el-bubble .ai-bubble-actions {
537
+ .ai-dialogue[data-v-517e169f] .el-bubble .ai-bubble-actions {
538
538
  transition: none;
539
539
  }
540
540
  }
@@ -748,36 +748,36 @@ to {
748
748
  font-size: var(--dc-agent-font-size-sm);
749
749
  color: var(--dc-agent-text-secondary);
750
750
  }
751
- .ai-dialogue-group[data-v-8dff57f8] {
751
+ .ai-dialogue-group[data-v-e9b9fa58] {
752
752
  height: 100%;
753
753
  display: flex;
754
754
  background-color: var(--dc-agent-bg);
755
755
  }
756
- .ai-dialogue-group[data-v-8dff57f8],
757
- .ai-dialogue-group[data-v-8dff57f8] * {
756
+ .ai-dialogue-group[data-v-e9b9fa58],
757
+ .ai-dialogue-group[data-v-e9b9fa58] * {
758
758
  box-sizing: border-box;
759
759
  }
760
- .ai-dialogue-group_side_left[data-v-8dff57f8] {
760
+ .ai-dialogue-group_side_left[data-v-e9b9fa58] {
761
761
  flex-direction: row;
762
762
  border-right: 1px solid var(--dc-agent-border);
763
763
  }
764
- .ai-dialogue-group_side_right[data-v-8dff57f8] {
764
+ .ai-dialogue-group_side_right[data-v-e9b9fa58] {
765
765
  flex-direction: row-reverse;
766
766
  border-left: 1px solid var(--dc-agent-border);
767
767
  }
768
- .ai-dialogue-group[data-v-8dff57f8] .ai-dialogue {
768
+ .ai-dialogue-group[data-v-e9b9fa58] .ai-dialogue {
769
769
  box-shadow: none;
770
770
  }
771
- .ai-dialogue-group-operation-bar[data-v-8dff57f8] {
771
+ .ai-dialogue-group-operation-bar[data-v-e9b9fa58] {
772
772
  height: 100%;
773
773
  position: relative;
774
774
  }
775
- .ai-dialogue-group-main[data-v-8dff57f8] {
775
+ .ai-dialogue-group-main[data-v-e9b9fa58] {
776
776
  height: 100%;
777
777
  flex: 1;
778
778
  position: relative;
779
779
  }
780
- .ai-dialogue-group-main-item[data-v-8dff57f8] {
780
+ .ai-dialogue-group-main-item[data-v-e9b9fa58] {
781
781
  width: 100%;
782
782
  height: 100%;
783
783
  position: absolute;
@@ -787,7 +787,7 @@ to {
787
787
  top: 50%;
788
788
  transform: translate(-50%, -50%);
789
789
  }
790
- .ai-dialogue-group-main-item_active[data-v-8dff57f8] {
790
+ .ai-dialogue-group-main-item_active[data-v-e9b9fa58] {
791
791
  opacity: 1;
792
792
  pointer-events: auto;
793
793
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@done-coding/forge-kit-agent",
3
- "version": "0.100.1",
3
+ "version": "0.100.2",
4
4
  "description": "Vue 3 AI 对话与智能体 UI 组件库",
5
5
  "private": false,
6
6
  "module": "es/index.mjs",
@@ -81,5 +81,5 @@
81
81
  "node": ">=18.0.0",
82
82
  "pnpm": ">=9.0.0"
83
83
  },
84
- "gitHead": "d9b600542ecd57b69e69966b87d7e3c7ac0f7c26"
84
+ "gitHead": "7f67bb1a7bbe1e2ef30c016e83cd971e3d5a4752"
85
85
  }
@@ -15,7 +15,7 @@ declare function __VLS_template(): {
15
15
  * 作用域键名与 `AiMessageList` 的 `#part` 刻意不同(此处是内部气泡项
16
16
  * `XBubbleListItemProps`,那边是对外 `AiMessage`)——同名会制造虚假可移植性。
17
17
  */
18
- part: (props: {
18
+ part?: (props: {
19
19
  part: AiDataPart;
20
20
  item: XBubbleListItemProps;
21
21
  }) => unknown;
@@ -25,7 +25,7 @@ declare function __VLS_template(): {
25
25
  * 人在环回发:`part.id` === `AiToolCtx.toolCallId`,用它作 key 找到自己在
26
26
  * `AiTool.execute` 里存下的 resolve 即可(库不代持 pending 句柄)。
27
27
  */
28
- tool: (props: {
28
+ tool?: (props: {
29
29
  part: AiToolPart;
30
30
  item: XBubbleListItemProps;
31
31
  }) => unknown;
@@ -39,7 +39,7 @@ declare function __VLS_template(): {
39
39
  * 作用域键名与 `AiMessageList` 的 `#part` 刻意不同(此处是内部气泡项
40
40
  * `XBubbleListItemProps`,那边是对外 `AiMessage`)——同名会制造虚假可移植性。
41
41
  */
42
- part: (props: {
42
+ part?: (props: {
43
43
  part: AiDataPart;
44
44
  item: XBubbleListItemProps;
45
45
  }) => unknown;
@@ -49,7 +49,7 @@ declare function __VLS_template(): {
49
49
  * 人在环回发:`part.id` === `AiToolCtx.toolCallId`,用它作 key 找到自己在
50
50
  * `AiTool.execute` 里存下的 resolve 即可(库不代持 pending 句柄)。
51
51
  */
52
- tool: (props: {
52
+ tool?: (props: {
53
53
  part: AiToolPart;
54
54
  item: XBubbleListItemProps;
55
55
  }) => unknown;
@@ -7,23 +7,23 @@ declare function __VLS_template(): {
7
7
  attrs: Partial<{}>;
8
8
  slots: Readonly<{
9
9
  /** 业务 data part 渲染口(透传 AiDialogue)。 */
10
- part: (props: {
10
+ part?: (props: {
11
11
  part: AiDataPart;
12
12
  item: XBubbleListItemProps;
13
13
  }) => unknown;
14
14
  /** 工具调用 part 渲染口(透传 AiDialogue)。 */
15
- tool: (props: {
15
+ tool?: (props: {
16
16
  part: AiToolPart;
17
17
  item: XBubbleListItemProps;
18
18
  }) => unknown;
19
19
  }> & {
20
20
  /** 业务 data part 渲染口(透传 AiDialogue)。 */
21
- part: (props: {
21
+ part?: (props: {
22
22
  part: AiDataPart;
23
23
  item: XBubbleListItemProps;
24
24
  }) => unknown;
25
25
  /** 工具调用 part 渲染口(透传 AiDialogue)。 */
26
- tool: (props: {
26
+ tool?: (props: {
27
27
  part: AiToolPart;
28
28
  item: XBubbleListItemProps;
29
29
  }) => unknown;