@antdv-next/x 0.1.0 → 0.2.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.
Files changed (37) hide show
  1. package/LICENSE +21 -0
  2. package/dist/_utils/vue.d.ts +2 -0
  3. package/dist/_utils/vue.js +16 -0
  4. package/dist/actions/Actions.js +3 -2
  5. package/dist/actions/ActionsCopy.js +4 -4
  6. package/dist/attachments/PlaceholderUploader.d.ts +16 -0
  7. package/dist/attachments/PlaceholderUploader.js +31 -5
  8. package/dist/attachments/index.d.ts +8 -1
  9. package/dist/attachments/index.js +7 -1
  10. package/dist/bubble/Bubble.js +5 -8
  11. package/dist/bubble/BubbleList.js +4 -4
  12. package/dist/bubble/Divider.js +1 -1
  13. package/dist/code-highlighter/shiki.js +2 -1
  14. package/dist/conversations/GroupTitle.d.ts +22 -2
  15. package/dist/conversations/GroupTitle.js +25 -3
  16. package/dist/conversations/Item.d.ts +1 -1
  17. package/dist/conversations/Item.js +1 -4
  18. package/dist/conversations/index.d.ts +10 -1
  19. package/dist/conversations/index.js +12 -0
  20. package/dist/conversations/interface.d.ts +7 -0
  21. package/dist/file-card/FileCard.js +1 -1
  22. package/dist/file-card/List.js +1 -1
  23. package/dist/file-card/components/File.d.ts +6 -6
  24. package/dist/file-card/components/File.js +2 -2
  25. package/dist/index.esm.js +149 -85
  26. package/dist/index.umd.js +148 -84
  27. package/dist/mermaid/Mermaid.d.ts +5 -0
  28. package/dist/mermaid/Mermaid.js +22 -1
  29. package/dist/mermaid/index.d.ts +1 -1
  30. package/dist/package.js +1 -1
  31. package/dist/prompts/Prompts.js +1 -4
  32. package/dist/sources/Sources.js +1 -4
  33. package/dist/sources/components/CarouselCard.js +1 -4
  34. package/dist/suggestion/Suggestion.js +1 -4
  35. package/dist/thought-chain/Item.js +3 -6
  36. package/dist/thought-chain/Node.js +1 -4
  37. package/package.json +2 -1
@@ -1,12 +1,9 @@
1
+ import { hasRenderableNode } from "../_utils/vue.js";
1
2
  import { STATUS_ICON_MAP } from "./Status.js";
2
3
  import style_default from "./style/index.js";
3
4
  import { computed, createVNode, defineComponent, ref } from "vue";
4
5
  import { useConfig } from "antdv-next/dist/config-provider/context";
5
6
  //#region components/thought-chain/Item.tsx
6
- function hasRenderableNode(node) {
7
- if (Array.isArray(node)) return node.some((item) => item !== null && item !== void 0 && item !== false);
8
- return node !== null && node !== void 0 && node !== false;
9
- }
10
7
  var XThoughtChainItem = /* @__PURE__ */ defineComponent({
11
8
  name: "AxThoughtChainItem",
12
9
  props: {
@@ -86,9 +83,9 @@ var XThoughtChainItem = /* @__PURE__ */ defineComponent({
86
83
  return () => {
87
84
  const cls = itemPrefixCls.value;
88
85
  const statusCls = `${props.prefixCls}-status`;
89
- const iconRenderSlot = slots.iconRender ?? slots["icon-render"];
86
+ const iconSlot = slots.icon;
90
87
  const originIconNode = props.status ? STATUS_ICON_MAP[props.status] : props.icon;
91
- const iconNode = iconRenderSlot ? iconRenderSlot({
88
+ const iconNode = iconSlot ? iconSlot({
92
89
  originNode: originIconNode,
93
90
  status: props.status
94
91
  }) : originIconNode;
@@ -1,12 +1,9 @@
1
+ import { hasRenderableNode } from "../_utils/vue.js";
1
2
  import { STATUS_ICON_MAP } from "./Status.js";
2
3
  import { Transition, computed, createVNode, defineComponent } from "vue";
3
4
  import { useConfig } from "antdv-next/dist/config-provider/context";
4
5
  import { LeftOutlined, RightOutlined } from "@antdv-next/icons";
5
6
  //#region components/thought-chain/Node.tsx
6
- function hasRenderableNode(node) {
7
- if (Array.isArray(node)) return node.some((item) => item !== null && item !== void 0 && item !== false);
8
- return node !== null && node !== void 0 && node !== false;
9
- }
10
7
  var Node_default = /* @__PURE__ */ defineComponent({
11
8
  name: "ThoughtChainNode",
12
9
  props: {
package/package.json CHANGED
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "name": "@antdv-next/x",
3
- "version": "0.1.0",
3
+ "version": "0.2.0",
4
+ "license": "MIT",
4
5
  "files": [
5
6
  "dist",
6
7
  "global.d.ts"