vue-element-ui-x 0.1.6-beta → 0.1.8-beta

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 (92) hide show
  1. package/lib/attachments.js +3082 -0
  2. package/lib/bubble-list.js +13840 -0
  3. package/lib/bubble.js +13125 -0
  4. package/lib/components/Attachments/index.js +2 -2
  5. package/lib/components/Bubble/index.js +74 -79
  6. package/lib/components/BubbleList/index.js +75 -80
  7. package/lib/components/Conversations/index.js +6 -6
  8. package/lib/components/FilesCard/index.js +1 -1
  9. package/lib/components/Prompts/index.js +21 -21
  10. package/lib/components/Sender/index.js +4 -4
  11. package/lib/components/Think/index.js +1 -1
  12. package/lib/components/Thinking/index.js +11 -11
  13. package/lib/components/ThoughtChain/index.js +77 -82
  14. package/lib/components/Typewriter/index.js +73 -78
  15. package/lib/components/Welcome/index.js +1 -1
  16. package/lib/conversations.js +18825 -0
  17. package/lib/files-card.js +2471 -0
  18. package/lib/index.common.js +1 -1
  19. package/lib/index.esm.js +1 -1
  20. package/lib/index.js +1463 -1457
  21. package/lib/index.umd.js +1 -1
  22. package/lib/mixins/index.js +2 -2
  23. package/lib/mixins.js +1016 -0
  24. package/lib/prompts.js +832 -0
  25. package/lib/sender.js +1911 -0
  26. package/lib/think.js +799 -0
  27. package/lib/thinking.js +809 -0
  28. package/lib/thought-chain.js +30391 -0
  29. package/lib/typewriter.js +12788 -0
  30. package/lib/welcome.js +755 -0
  31. package/package.json +1 -2
  32. package/src/components/Attachments/index.js +8 -8
  33. package/src/components/Bubble/index.js +6 -6
  34. package/src/components/Bubble/src/main.vue +299 -299
  35. package/src/components/BubbleList/index.js +8 -8
  36. package/src/components/BubbleList/src/loading.vue +75 -75
  37. package/src/components/BubbleList/src/main.vue +466 -466
  38. package/src/components/Conversations/index.js +8 -8
  39. package/src/components/Conversations/src/main.vue +635 -635
  40. package/src/components/FilesCard/index.js +8 -8
  41. package/src/components/FilesCard/src/fileSvg/audio.vue +38 -38
  42. package/src/components/FilesCard/src/fileSvg/code.vue +35 -35
  43. package/src/components/FilesCard/src/fileSvg/database.vue +94 -94
  44. package/src/components/FilesCard/src/fileSvg/excel.vue +38 -38
  45. package/src/components/FilesCard/src/fileSvg/file.vue +40 -40
  46. package/src/components/FilesCard/src/fileSvg/image.vue +40 -40
  47. package/src/components/FilesCard/src/fileSvg/index.js +46 -46
  48. package/src/components/FilesCard/src/fileSvg/link.vue +54 -54
  49. package/src/components/FilesCard/src/fileSvg/mark.vue +38 -38
  50. package/src/components/FilesCard/src/fileSvg/pdf.vue +38 -38
  51. package/src/components/FilesCard/src/fileSvg/ppt.vue +38 -38
  52. package/src/components/FilesCard/src/fileSvg/three.vue +38 -38
  53. package/src/components/FilesCard/src/fileSvg/txt.vue +38 -38
  54. package/src/components/FilesCard/src/fileSvg/unknown.vue +54 -54
  55. package/src/components/FilesCard/src/fileSvg/video.vue +38 -38
  56. package/src/components/FilesCard/src/fileSvg/word.vue +38 -38
  57. package/src/components/FilesCard/src/fileSvg/zip.vue +38 -38
  58. package/src/components/FilesCard/src/options.js +18 -18
  59. package/src/components/Prompts/index.js +8 -8
  60. package/src/components/Prompts/src/main.vue +248 -248
  61. package/src/components/Sender/index.js +8 -8
  62. package/src/components/Sender/src/components/ClearButton.vue +28 -28
  63. package/src/components/Sender/src/components/Loading.vue +53 -53
  64. package/src/components/Sender/src/components/LoadingButton.vue +39 -39
  65. package/src/components/Sender/src/components/SendButton.vue +26 -26
  66. package/src/components/Sender/src/components/SpeechButton.vue +24 -24
  67. package/src/components/Sender/src/components/SpeechLoading.vue +87 -87
  68. package/src/components/Sender/src/components/SpeechLoadingButton.vue +43 -43
  69. package/src/components/Think/index.js +8 -8
  70. package/src/components/Think/src/main.vue +190 -190
  71. package/src/components/Thinking/index.js +8 -8
  72. package/src/components/Thinking/src/main.vue +1 -1
  73. package/src/components/ThoughtChain/index.js +8 -8
  74. package/src/components/ThoughtChain/src/main.vue +293 -293
  75. package/src/components/Typewriter/index.js +8 -8
  76. package/src/components/Welcome/index.js +8 -8
  77. package/src/components/Welcome/src/main.vue +151 -151
  78. package/src/index.js +23 -3
  79. package/src/styles/Attachments.scss +236 -236
  80. package/src/styles/Bubble.scss +157 -157
  81. package/src/styles/BubbleList.scss +148 -148
  82. package/src/styles/Conversations.scss +260 -260
  83. package/src/styles/FilesCard.scss +221 -221
  84. package/src/styles/Prompts.scss +195 -195
  85. package/src/styles/Sender.scss +199 -199
  86. package/src/styles/Think.scss +134 -134
  87. package/src/styles/Thinking.scss +2 -2
  88. package/src/styles/ThoughtChain.scss +113 -113
  89. package/src/styles/Typewriter.scss +66 -66
  90. package/src/styles/button.scss +302 -0
  91. package/src/styles/var.scss +1052 -0
  92. package/src/theme/var.scss +72 -72
@@ -1,236 +1,236 @@
1
- @import '../theme/var.scss';
2
-
3
- /* CSS 动画样式调整 */
4
- .card-motion {
5
- &-enter-active,
6
- &-move,
7
- &-leave-active {
8
- transition: all 0.3s ease;
9
- opacity: 1;
10
- transform: translateX(0);
11
- }
12
-
13
- &-enter,
14
- &-leave-to {
15
- opacity: 0;
16
- /* 从左侧外进入(进场)/ 移动到右侧外(退场) */
17
- transform: translateX(-100%);
18
- /* 进场初始位置在左侧外 */
19
- }
20
-
21
- &-leave-active {
22
- /* 退场时从当前位置移动到右侧外 */
23
- transform: translateX(100%);
24
- opacity: 0;
25
- }
26
- }
27
-
28
- .el-x-attachments {
29
- &-file-card-wrap {
30
- display: flex;
31
- height: 100%;
32
- align-items: center;
33
- }
34
-
35
- &-upload-placeholder {
36
- display: inline-block;
37
- width: fit-content;
38
- align-self: center;
39
- margin: 6px;
40
- }
41
-
42
- &-card {
43
- display: inline-block;
44
- vertical-align: top;
45
-
46
- &-item {
47
- margin: 6px;
48
- }
49
- }
50
-
51
- &-prev-btn,
52
- &-next-btn {
53
- position: absolute;
54
- top: 50%;
55
- transform: translateY(-50%);
56
- z-index: 10;
57
- background-color: rgba(0, 0, 0, 0.3);
58
- color: white;
59
- border: none;
60
- padding: 4px 0px;
61
- border-radius: 3px;
62
- transition: background-color 0.3s ease;
63
-
64
- &:hover {
65
- background-color: rgba(0, 0, 0, 0.5);
66
- }
67
-
68
- &:active {
69
- background-color: rgba(0, 0, 0, 0.7);
70
- }
71
- }
72
-
73
- &-prev-btn {
74
- left: 8px;
75
- border-top-left-radius: 0px;
76
- border-bottom-left-radius: 0px;
77
- }
78
-
79
- &-next-btn {
80
- right: 8px;
81
- border-top-right-radius: 0px;
82
- border-bottom-right-radius: 0px;
83
- }
84
-
85
- &-background {
86
- position: absolute;
87
- top: 0;
88
- left: 0;
89
- right: 0;
90
- bottom: 0;
91
- width: 100%;
92
- pointer-events: none;
93
-
94
- &-start {
95
- position: absolute;
96
- top: 0;
97
- left: 0;
98
- bottom: 0;
99
- width: 50px;
100
- background: linear-gradient(to right, rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0));
101
- z-index: 5;
102
- }
103
-
104
- &-end {
105
- position: absolute;
106
- top: 0;
107
- right: 0;
108
- bottom: 0;
109
- width: 50px;
110
- background: linear-gradient(to left, rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0));
111
- z-index: 5;
112
- }
113
- }
114
-
115
- &-overflow-scrollX {
116
- height: 100%;
117
-
118
- &::-webkit-scrollbar {
119
- display: none;
120
- }
121
-
122
- scrollbar-width: none;
123
- }
124
-
125
- &-overflow-scrollY {
126
- width: 100%;
127
- height: 100%;
128
- }
129
-
130
- &-wrapper {
131
- position: relative;
132
- display: block;
133
- }
134
-
135
- &-upload-btn {
136
- display: flex;
137
-
138
- ::v-deep .el-upload {
139
- border: 1px dashed $--border-color-base;
140
- border-radius: 6px;
141
- cursor: pointer;
142
- position: relative;
143
- overflow: hidden;
144
- transition: $--all-transition;
145
- box-sizing: border-box;
146
- text-align: center;
147
-
148
- &:hover {
149
- border-color: $--color-primary;
150
-
151
- .uploader-icon {
152
- color: $--color-primary;
153
- }
154
- }
155
- }
156
-
157
- .uploader-icon {
158
- font-size: 28px;
159
- color: #8c939d;
160
- text-align: center;
161
- width: var(--el-x-attachments-upload-icon-size);
162
- height: var(--el-x-attachments-upload-icon-size);
163
- line-height: var(--el-x-attachments-upload-icon-size);
164
- }
165
-
166
- ::v-deep .el-upload-dragger {
167
- padding: 0;
168
- width: auto !important;
169
- height: auto !important;
170
- background-color: transparent;
171
-
172
- &:hover .el-icon {
173
- color: $--color-primary;
174
- }
175
- }
176
- }
177
-
178
- /* 设置拖放区域的样式 */
179
- &-drop-area {
180
- position: absolute !important;
181
- top: 0 !important;
182
- left: 0 !important;
183
- width: calc(100% - 4px) !important;
184
- height: calc(100% - 4px) !important;
185
- border-radius: 15px !important;
186
- border: 2px dashed $--color-primary !important;
187
- z-index: 9999 !important;
188
- display: flex !important;
189
- align-items: center !important;
190
- justify-content: center !important;
191
- flex-direction: column !important;
192
- background: rgba(225, 225, 225, 0.8) !important; // 增加透明度
193
- backdrop-filter: blur(4px) !important; // 增加模糊效果
194
- animation: dragAreaShow 0.3s ease-in-out !important; // 添加显示动画
195
- pointer-events: none !important; // 防止拖拽区域本身阻止事件
196
-
197
- &-icon {
198
- font-size: 50px !important;
199
- color: $--color-primary !important;
200
- animation: bounce 1s infinite alternate !important; // 添加跳动动画
201
- }
202
-
203
- &-text {
204
- font-size: 16px !important;
205
- color: $--color-primary !important;
206
- margin-top: 10px !important;
207
- text-align: center !important;
208
- width: 100% !important;
209
- max-width: 300px !important;
210
- font-weight: bold !important;
211
- }
212
- }
213
-
214
- // 添加动画关键帧
215
- @keyframes dragAreaShow {
216
- from {
217
- opacity: 0;
218
- transform: scale(0.9);
219
- }
220
-
221
- to {
222
- opacity: 1;
223
- transform: scale(1);
224
- }
225
- }
226
-
227
- @keyframes bounce {
228
- from {
229
- transform: translateY(0);
230
- }
231
-
232
- to {
233
- transform: translateY(-10px);
234
- }
235
- }
236
- }
1
+ @import '../theme/var.scss';
2
+
3
+ /* CSS 动画样式调整 */
4
+ .card-motion {
5
+ &-enter-active,
6
+ &-move,
7
+ &-leave-active {
8
+ transition: all 0.3s ease;
9
+ opacity: 1;
10
+ transform: translateX(0);
11
+ }
12
+
13
+ &-enter,
14
+ &-leave-to {
15
+ opacity: 0;
16
+ /* 从左侧外进入(进场)/ 移动到右侧外(退场) */
17
+ transform: translateX(-100%);
18
+ /* 进场初始位置在左侧外 */
19
+ }
20
+
21
+ &-leave-active {
22
+ /* 退场时从当前位置移动到右侧外 */
23
+ transform: translateX(100%);
24
+ opacity: 0;
25
+ }
26
+ }
27
+
28
+ .el-x-attachments {
29
+ &-file-card-wrap {
30
+ display: flex;
31
+ height: 100%;
32
+ align-items: center;
33
+ }
34
+
35
+ &-upload-placeholder {
36
+ display: inline-block;
37
+ width: fit-content;
38
+ align-self: center;
39
+ margin: 6px;
40
+ }
41
+
42
+ &-card {
43
+ display: inline-block;
44
+ vertical-align: top;
45
+
46
+ &-item {
47
+ margin: 6px;
48
+ }
49
+ }
50
+
51
+ &-prev-btn,
52
+ &-next-btn {
53
+ position: absolute;
54
+ top: 50%;
55
+ transform: translateY(-50%);
56
+ z-index: 10;
57
+ background-color: rgba(0, 0, 0, 0.3);
58
+ color: white;
59
+ border: none;
60
+ padding: 4px 0px;
61
+ border-radius: 3px;
62
+ transition: background-color 0.3s ease;
63
+
64
+ &:hover {
65
+ background-color: rgba(0, 0, 0, 0.5);
66
+ }
67
+
68
+ &:active {
69
+ background-color: rgba(0, 0, 0, 0.7);
70
+ }
71
+ }
72
+
73
+ &-prev-btn {
74
+ left: 8px;
75
+ border-top-left-radius: 0px;
76
+ border-bottom-left-radius: 0px;
77
+ }
78
+
79
+ &-next-btn {
80
+ right: 8px;
81
+ border-top-right-radius: 0px;
82
+ border-bottom-right-radius: 0px;
83
+ }
84
+
85
+ &-background {
86
+ position: absolute;
87
+ top: 0;
88
+ left: 0;
89
+ right: 0;
90
+ bottom: 0;
91
+ width: 100%;
92
+ pointer-events: none;
93
+
94
+ &-start {
95
+ position: absolute;
96
+ top: 0;
97
+ left: 0;
98
+ bottom: 0;
99
+ width: 50px;
100
+ background: linear-gradient(to right, rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0));
101
+ z-index: 5;
102
+ }
103
+
104
+ &-end {
105
+ position: absolute;
106
+ top: 0;
107
+ right: 0;
108
+ bottom: 0;
109
+ width: 50px;
110
+ background: linear-gradient(to left, rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0));
111
+ z-index: 5;
112
+ }
113
+ }
114
+
115
+ &-overflow-scrollX {
116
+ height: 100%;
117
+
118
+ &::-webkit-scrollbar {
119
+ display: none;
120
+ }
121
+
122
+ scrollbar-width: none;
123
+ }
124
+
125
+ &-overflow-scrollY {
126
+ width: 100%;
127
+ height: 100%;
128
+ }
129
+
130
+ &-wrapper {
131
+ position: relative;
132
+ display: block;
133
+ }
134
+
135
+ &-upload-btn {
136
+ display: flex;
137
+
138
+ ::v-deep .el-upload {
139
+ border: 1px dashed $--border-color-base;
140
+ border-radius: 6px;
141
+ cursor: pointer;
142
+ position: relative;
143
+ overflow: hidden;
144
+ transition: $--all-transition;
145
+ box-sizing: border-box;
146
+ text-align: center;
147
+
148
+ &:hover {
149
+ border-color: $--color-primary;
150
+
151
+ .uploader-icon {
152
+ color: $--color-primary;
153
+ }
154
+ }
155
+ }
156
+
157
+ .uploader-icon {
158
+ font-size: 28px;
159
+ color: #8c939d;
160
+ text-align: center;
161
+ width: var(--el-x-attachments-upload-icon-size);
162
+ height: var(--el-x-attachments-upload-icon-size);
163
+ line-height: var(--el-x-attachments-upload-icon-size);
164
+ }
165
+
166
+ ::v-deep .el-upload-dragger {
167
+ padding: 0;
168
+ width: auto !important;
169
+ height: auto !important;
170
+ background-color: transparent;
171
+
172
+ &:hover .el-icon {
173
+ color: $--color-primary;
174
+ }
175
+ }
176
+ }
177
+
178
+ /* 设置拖放区域的样式 */
179
+ &-drop-area {
180
+ position: absolute !important;
181
+ top: 0 !important;
182
+ left: 0 !important;
183
+ width: calc(100% - 4px) !important;
184
+ height: calc(100% - 4px) !important;
185
+ border-radius: 15px !important;
186
+ border: 2px dashed $--color-primary !important;
187
+ z-index: 9999 !important;
188
+ display: flex !important;
189
+ align-items: center !important;
190
+ justify-content: center !important;
191
+ flex-direction: column !important;
192
+ background: rgba(225, 225, 225, 0.8) !important; // 增加透明度
193
+ backdrop-filter: blur(4px) !important; // 增加模糊效果
194
+ animation: dragAreaShow 0.3s ease-in-out !important; // 添加显示动画
195
+ pointer-events: none !important; // 防止拖拽区域本身阻止事件
196
+
197
+ &-icon {
198
+ font-size: 50px !important;
199
+ color: $--color-primary !important;
200
+ animation: bounce 1s infinite alternate !important; // 添加跳动动画
201
+ }
202
+
203
+ &-text {
204
+ font-size: 16px !important;
205
+ color: $--color-primary !important;
206
+ margin-top: 10px !important;
207
+ text-align: center !important;
208
+ width: 100% !important;
209
+ max-width: 300px !important;
210
+ font-weight: bold !important;
211
+ }
212
+ }
213
+
214
+ // 添加动画关键帧
215
+ @keyframes dragAreaShow {
216
+ from {
217
+ opacity: 0;
218
+ transform: scale(0.9);
219
+ }
220
+
221
+ to {
222
+ opacity: 1;
223
+ transform: scale(1);
224
+ }
225
+ }
226
+
227
+ @keyframes bounce {
228
+ from {
229
+ transform: translateY(0);
230
+ }
231
+
232
+ to {
233
+ transform: translateY(-10px);
234
+ }
235
+ }
236
+ }