@mujian/js-sdk 0.0.6-beta.1 → 0.0.6-beta.3

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 (2) hide show
  1. package/dist/react.css +232 -30
  2. package/package.json +1 -1
package/dist/react.css CHANGED
@@ -1,26 +1,194 @@
1
1
  :root {
2
- --doc-height: 1102px;
2
+ interpolate-size: allow-keywords;
3
+ --doc-height: 100%;
4
+ --transparent: #0000;
5
+ --black30a: #0000004d;
6
+ --black50a: #00000080;
7
+ --black60a: #0009;
8
+ --black70a: #000000b3;
9
+ --black90a: #000000e6;
10
+ --black100: #000;
11
+ --white20a: #fff3;
12
+ --white30a: #ffffff4d;
13
+ --white50a: #ffffff80;
14
+ --white60a: #fff9;
15
+ --white70a: #ffffffb3;
16
+ --white100: #fff;
17
+ --grey10: #191919;
18
+ --grey30: #4b4b4b;
19
+ --grey50: #7d7d7d;
20
+ --grey5020a: #7d7d7d33;
21
+ --grey5050a: #7d7d7d80;
22
+ --grey70: #afafaf;
23
+ --grey75: #bebebe;
24
+ --grey30a: #3232324d;
25
+ --grey7070a: #afafafb3;
26
+ --fullred: red;
27
+ --crimson70a: #640000b3;
28
+ --crimson-hover: #96323280;
29
+ --okGreen70a: #006400b3;
30
+ --cobalt30a: #6464ff4d;
31
+ --greyCAIbg: #242425;
32
+ --ivory: #dcdcd2;
33
+ --golden: #f8d300;
34
+ --warning: #ff0000e6;
35
+ --active: #58b600;
36
+ --preferred: #f44336;
37
+ --interactable-outline-color: var(--white100);
38
+ --interactable-outline-color-faint: var(--white20a);
39
+ --reasoning-body-color: var(--SmartThemeEmColor);
40
+ --reasoning-em-color: color-mix(in srgb, var(--SmartThemeEmColor) 67%, var(--SmartThemeBlurTintColor) 33%);
41
+ --reasoning-saturation: .5;
3
42
  --SmartThemeBodyColor: #abc6df;
4
- --SmartThemeCheckboxBgColorR: 171;
5
- --SmartThemeCheckboxBgColorG: 198;
6
- --SmartThemeCheckboxBgColorB: 223;
7
- --SmartThemeCheckboxBgColorA: 1;
8
43
  --SmartThemeEmColor: #fff;
9
44
  --SmartThemeUnderlineColor: #bce7cf;
10
45
  --SmartThemeQuoteColor: #6f85fd;
11
- --SmartThemeBlurTintColor: #171e219c;
12
- --SmartThemeChatTintColor: #17171700;
13
- --SmartThemeUserMesBlurTintColor: #001cae33;
14
- --SmartThemeBotMesBlurTintColor: #000d3938;
15
- --SmartThemeShadowColor: #000;
46
+ --SmartThemeBlurTintColor: #171717;
47
+ --SmartThemeChatTintColor: #171717;
48
+ --SmartThemeUserMesBlurTintColor: #0000004d;
49
+ --SmartThemeBotMesBlurTintColor: #3c3c3c4d;
50
+ --SmartThemeBlurStrength: calc(var(--blurStrength) * 1px);
51
+ --SmartThemeShadowColor: #00000080;
16
52
  --SmartThemeBorderColor: #00000080;
17
- --animation-duration: .125s;
18
- --fontScale: 1;
53
+ --SmartThemeCheckboxBgColorR: 220;
54
+ --SmartThemeCheckboxBgColorG: 220;
55
+ --SmartThemeCheckboxBgColorB: 210;
56
+ --SmartThemeCheckboxTickColorValue: calc(((((var(--SmartThemeCheckboxBgColorR) * 299) + (var(--SmartThemeCheckboxBgColorG) * 587) + (var(--SmartThemeCheckboxBgColorB) * 114)) / 1000) - 128) * -1000);
57
+ --SmartThemeCheckboxTickColor: rgb(var(--SmartThemeCheckboxTickColorValue), var(--SmartThemeCheckboxTickColorValue), var(--SmartThemeCheckboxTickColorValue));
19
58
  --sheldWidth: 50vw;
20
- --blurStrength: 11;
21
- --shadowWidth: 5;
22
- --black30a: #0000004d;
23
- --SmartThemeQuoteBg: linear-gradient(90deg, #00e1ff 39%, #ff04e6 100%) text;
59
+ --fontScale: 1;
60
+ --mainFontSize: calc(var(--fontScale) * 15px);
61
+ --mainFontFamily: "Noto Sans", sans-serif;
62
+ --monoFontFamily: "Noto Sans Mono", "Courier New", Consolas, monospace;
63
+ --blurStrength: 10;
64
+ --shadowWidth: 2;
65
+ --bottomFormBlockPadding: calc(var(--mainFontSize) / 2.5);
66
+ --bottomFormIconSize: calc(var(--mainFontSize) * 1.9);
67
+ --bottomFormBlockSize: calc(var(--bottomFormIconSize) + var(--bottomFormBlockPadding));
68
+ --topBarIconSize: calc(var(--mainFontSize) * 2);
69
+ --topBarBlockSize: calc(var(--topBarIconSize) + var(--topBarBlockPadding));
70
+ --topBarBlockPadding: calc(var(--mainFontSize) / 3);
71
+ --tool-cool-color-picker-btn-bg: transparent;
72
+ --tool-cool-color-picker-btn-border-color: transparent;
73
+ --mes-right-spacing: 30px;
74
+ --avatar-base-height: 50px;
75
+ --avatar-base-width: 50px;
76
+ --avatar-base-border-radius: 2px;
77
+ --avatar-base-border-radius-round: 50%;
78
+ --avatar-base-border-radius-rounded: 10px;
79
+ --inline-avatar-small-factor: .6;
80
+ --animation-duration: .125s;
81
+ --animation-duration-2x: calc(var(--animation-duration) * 2);
82
+ --animation-duration-3x: calc(var(--animation-duration) * 3);
83
+ --animation-duration-slow: var(--animation-duration-3x);
84
+ }
85
+
86
+ * {
87
+ box-sizing: border-box;
88
+ -webkit-font-smoothing: antialiased;
89
+ -moz-osx-font-smoothing: grayscale;
90
+ }
91
+
92
+ html {
93
+ -webkit-backface-visibility: hidden;
94
+ -webkit-perspective: 1000px;
95
+ -webkit-transform: translateZ(0);
96
+ }
97
+
98
+ body {
99
+ background-color: var(--SmartThemeBlurTintColor);
100
+ width: 100%;
101
+ height: 100dvh;
102
+ font-family: var(--mainFontFamily);
103
+ font-size: var(--mainFontSize);
104
+ color: var(--SmartThemeBodyColor);
105
+ color-scheme: light only;
106
+ background-repeat: no-repeat;
107
+ background-size: cover;
108
+ background-attachment: fixed;
109
+ margin: 0;
110
+ padding: 0;
111
+ }
112
+
113
+ ::-webkit-scrollbar {
114
+ scrollbar-gutter: stable;
115
+ width: .7rem;
116
+ }
117
+
118
+ ::-webkit-scrollbar-track {
119
+ cursor: default;
120
+ }
121
+
122
+ ::-webkit-scrollbar-track:hover {
123
+ background-color: #7e7e7e33;
124
+ }
125
+
126
+ ::-webkit-scrollbar-thumb {
127
+ cursor: grab;
128
+ }
129
+
130
+ ::-webkit-scrollbar-thumb:active {
131
+ cursor: grabbing;
132
+ }
133
+
134
+ .scrollY {
135
+ overflow-y: auto !important;
136
+ }
137
+
138
+ ::-webkit-scrollbar-thumb:vertical {
139
+ background-color: var(--grey7070a);
140
+ box-shadow: inset 0 0 0 1px var(--black50a);
141
+ background-clip: content-box;
142
+ border: 2px solid #0000;
143
+ border-radius: 10px;
144
+ min-height: 40px;
145
+ }
146
+
147
+ body.movingUI ::-webkit-scrollbar-thumb:vertical {
148
+ border-top: 20px solid #0000;
149
+ }
150
+
151
+ ::-webkit-scrollbar-thumb:horizontal {
152
+ background-color: var(--grey7070a);
153
+ box-shadow: inset 0 0 0 1px var(--black50a);
154
+ background-clip: content-box;
155
+ border: 2px solid #0000;
156
+ border-radius: 10px;
157
+ min-width: 40px;
158
+ }
159
+
160
+ ::-webkit-scrollbar-corner {
161
+ background-color: #0000;
162
+ }
163
+
164
+ .mes_text table, .mes_reasoning table {
165
+ border-spacing: 0;
166
+ border-collapse: collapse;
167
+ margin-bottom: 10px;
168
+ }
169
+
170
+ .mes_text td, .mes_text th, .mes_reasoning td, .mes_reasoning th {
171
+ border-collapse: collapse;
172
+ border: 1px solid;
173
+ padding: .25em;
174
+ }
175
+
176
+ .mes_text p, .mes_reasoning p {
177
+ margin-top: 0;
178
+ margin-bottom: 10px;
179
+ }
180
+
181
+ .mes_text li tt, .mes_reasoning li tt {
182
+ display: inline-block;
183
+ }
184
+
185
+ .mes_text ol, .mes_text ul, .mes_reasoning ol, .mes_reasoning ul {
186
+ margin-top: 5px;
187
+ margin-bottom: 5px;
188
+ }
189
+
190
+ .mes_text br, .mes_bias br, .mes_reasoning br {
191
+ content: " ";
24
192
  }
25
193
 
26
194
  .mes q:before, .mes q:after, .mes_text q:before, .mes_text q:after {
@@ -49,8 +217,18 @@
49
217
  margin-bottom: 16px;
50
218
  }
51
219
 
220
+ .mes_text, .mes_reasoning {
221
+ font-weight: 500;
222
+ line-height: calc(var(--mainFontSize) + .5rem);
223
+ overflow-wrap: anywhere;
224
+ max-width: 100%;
225
+ }
226
+
52
227
  .mes_text {
53
- color: var(--SmartThemeBodyColor);
228
+ padding-top: 5px;
229
+ padding-bottom: 5px;
230
+ padding-left: 0;
231
+ padding-right: var(--mes-right-spacing);
54
232
  }
55
233
 
56
234
  .mes_text p:only-child, .mes_text p:only-of-type {
@@ -96,15 +274,35 @@
96
274
  color: var(--SmartThemeEmColor);
97
275
  }
98
276
 
277
+ .mes_reasoning i, .mes_reasoning em {
278
+ color: hsl(from var(--reasoning-em-color) h calc(s * var(--reasoning-saturation)) l);
279
+ }
280
+
281
+ .mes_text q i, .mes_text q em {
282
+ color: inherit;
283
+ }
284
+
285
+ .mes_reasoning q i, .mes_reasoning q em {
286
+ color: hsl(from var(--SmartThemeQuoteColor) h calc(s * var(--reasoning-saturation)) l);
287
+ }
288
+
99
289
  .mes_text u {
100
290
  color: var(--SmartThemeUnderlineColor);
101
291
  }
102
292
 
293
+ .mes_reasoning u {
294
+ color: hsl(from var(--SmartThemeUnderlineColor) h calc(s * var(--reasoning-saturation)) l);
295
+ }
296
+
103
297
  .mes_text q {
104
- color: #00e1ff;
298
+ color: var(--SmartThemeQuoteColor);
105
299
  }
106
300
 
107
- .mes_text font[color] em, .mes_text font[color] i, .mes_text font[color] q {
301
+ .mes_reasoning q {
302
+ color: hsl(from var(--SmartThemeQuoteColor) h calc(s * var(--reasoning-saturation)) l);
303
+ }
304
+
305
+ .mes_text font[color] em, .mes_text font[color] i, .mes_text font[color] u, .mes_text font[color] q, .mes_reasoning font[color] em, .mes_reasoning font[color] i, .mes_reasoning font[color] u, .mes_reasoning font[color] q {
108
306
  color: inherit;
109
307
  }
110
308
 
@@ -112,23 +310,18 @@
112
310
  display: block;
113
311
  }
114
312
 
115
- .mes_text blockquote {
313
+ .mes_text blockquote, .mes_reasoning blockquote {
116
314
  border-left: 3px solid var(--SmartThemeQuoteColor);
117
315
  background-color: var(--black30a);
118
- width: 100%;
119
- margin-bottom: 16px;
316
+ margin: 0;
120
317
  padding-left: 10px;
121
-
122
- & p {
123
- margin: 0;
124
- }
125
318
  }
126
319
 
127
- .mes_text strong em, .mes_text strong, .mes_text h2, .mes_text h1 {
320
+ .mes_text strong em, .mes_text strong, .mes_text h2, .mes_text h1, .mes_reasoning strong em, .mes_reasoning strong, .mes_reasoning h2, .mes_reasoning h1 {
128
321
  font-weight: bold;
129
322
  }
130
323
 
131
- .mes_text pre code, code {
324
+ .mes_text pre code, .mes_reasoning pre code {
132
325
  padding: 1em;
133
326
  display: block;
134
327
  position: relative;
@@ -138,8 +331,17 @@
138
331
  .mes_text img:not(.mes_img), .mes_reasoning img:not(.mes_img) {
139
332
  max-width: 100%;
140
333
  max-height: var(--doc-height);
141
- object-fit: contain;
142
- height: auto !important;
334
+ }
335
+
336
+ code {
337
+ font-family: var(--monoFontFamily);
338
+ white-space: pre-wrap;
339
+ border: 1px solid var(--SmartThemeBorderColor);
340
+ background-color: var(--black70a);
341
+ line-height: var(--mainFontSize);
342
+ color: var(--white70a);
343
+ border-radius: 5px;
344
+ padding: 0 3px;
143
345
  }
144
346
 
145
347
  .mes-dialogue {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mujian/js-sdk",
3
- "version": "0.0.6-beta.1",
3
+ "version": "0.0.6-beta.3",
4
4
  "type": "module",
5
5
  "exports": {
6
6
  ".": {