refactor(scrape): complete rewrite of content extraction - per-turn parsing for all types
This commit is contained in:
@@ -103,6 +103,8 @@ class ChatPanel {
|
||||
case 'code': return this._renderCode(msg);
|
||||
case 'image': return this._renderImage(msg);
|
||||
case 'actions': return this._renderActions(msg);
|
||||
case 'user': return this._renderUser(msg);
|
||||
case 'status': return this._renderStatus(msg);
|
||||
default: return null;
|
||||
}
|
||||
}
|
||||
@@ -353,4 +355,24 @@ class ChatPanel {
|
||||
_scrollToBottom() {
|
||||
this.messagesEl.scrollTop = this.messagesEl.scrollHeight;
|
||||
}
|
||||
|
||||
/**
|
||||
* 사용자 메시지 렌더링
|
||||
*/
|
||||
_renderUser(msg) {
|
||||
const wrapper = document.createElement('div');
|
||||
wrapper.className = 'msg-user';
|
||||
wrapper.textContent = msg.content;
|
||||
return wrapper;
|
||||
}
|
||||
|
||||
/**
|
||||
* 상태 표시 (Running, Generating 등)
|
||||
*/
|
||||
_renderStatus(msg) {
|
||||
const wrapper = document.createElement('div');
|
||||
wrapper.className = 'msg-status';
|
||||
wrapper.textContent = msg.content;
|
||||
return wrapper;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user