fix: logs scrollbar ux

This commit is contained in:
jialin
2024-10-22 09:29:03 +08:00
parent 57386eeb55
commit eb5cf9da8d
17 changed files with 224 additions and 180 deletions
@@ -173,7 +173,10 @@ const GroundLeft: React.FC<MessageProps> = forwardRef((props, ref) => {
]
: [...formatMessages],
...parameters,
stream: true
stream: true,
stream_otpions: {
include_usage: true
}
};
const result: any = await fetchChunkedData({
data: chatParams,
@@ -173,7 +173,10 @@ const ModelItem: React.FC<ModelItemProps> = forwardRef(
]
: [...formatMessages],
...params,
stream: true
stream: true,
stream_otpions: {
include_usage: true
}
};
// ============== payload end ================
const result: any = await fetchChunkedData({
@@ -4,7 +4,7 @@ import { BulbOutlined } from '@ant-design/icons';
import { useIntl } from '@umijs/max';
import { Button, Modal } from 'antd';
import _ from 'lodash';
import React, { useEffect, useRef, useState } from 'react';
import React, { useEffect, useState } from 'react';
type ViewModalProps = {
systemMessage?: string;
@@ -40,8 +40,6 @@ const ViewCodeModal: React.FC<ViewModalProps> = (props) => {
} = props || {};
const intl = useIntl();
const editorRef = useRef(null);
const [loaded, setLoaded] = useState(false);
const [codeValue, setCodeValue] = useState('');
const [lang, setLang] = useState(langMap.shell);