style(Inputbar): format code

This commit is contained in:
icarus 2025-09-28 15:04:21 +08:00
parent cfdeb124b9
commit 128385bfe0

View File

@ -251,11 +251,7 @@ const MentionModelsButton: FC<Props> = ({
if (action === 'esc') {
// 只有在输入触发且有模型选择动作时才删除@字符和搜索文本
const triggerInfo = ctx?.triggerInfo ?? triggerInfoRef.current
if (
hasModelActionRef.current &&
triggerInfo?.type === 'input' &&
triggerInfo?.position !== undefined
) {
if (hasModelActionRef.current && triggerInfo?.type === 'input' && triggerInfo?.position !== undefined) {
// 基于当前光标 + 搜索词精确定位并删除position 仅作兜底
setText((currentText) => {
const textArea = document.querySelector('.inputbar textarea') as HTMLTextAreaElement | null