diff --git a/webui-src/app/chat/chat.js b/webui-src/app/chat/chat.js index 0ce91ff..d25ed43 100644 --- a/webui-src/app/chat/chat.js +++ b/webui-src/app/chat/chat.js @@ -1511,6 +1511,25 @@ const Layout = { m('i.fas.fa-quote-right', { style: 'color: #3b82f6;' }), 'Quote Message' ]), + ChatHubState.messageContextMenu.gxsId && + ChatHubState.messageContextMenu.gxsId !== '00000000000000000000000000000000' && + m('.context-menu-item', { + style: 'padding: 0.5rem 1rem; font-size: 0.85rem; font-weight: 600; color: #1e293b; display: flex; align-items: center; gap: 0.6rem; cursor: pointer; transition: background 0.15s ease;', + onmouseenter: (e) => (e.currentTarget.style.background = '#f1f5f9'), + onmouseleave: (e) => (e.currentTarget.style.background = 'transparent'), + onclick: () => { + const { gxsId } = ChatHubState.messageContextMenu; + const peopleState = require('people/people_state'); + peopleState.State.selectedId = gxsId; + peopleState.State.activeFilter = 'all'; + peopleState.fetchIdDetails(gxsId); + ChatHubState.messageContextMenu.show = false; + m.route.set('/people/All'); + }, + }, [ + m('i.fas.fa-user-circle', { style: 'color: #0ea5e9;' }), + 'Show Author in People' + ]), m('.context-menu-item', { style: 'padding: 0.5rem 1rem; font-size: 0.85rem; font-weight: 600; color: #1e293b; display: flex; align-items: center; gap: 0.6rem; cursor: pointer; transition: background 0.15s ease;', onmouseenter: (e) => (e.currentTarget.style.background = '#f1f5f9'), @@ -1522,7 +1541,7 @@ const Layout = { m.redraw(); }, }, [ - m('i.far.fa-copy', { style: 'color: #64748b;' }), + m('i.fas.fa-copy', { style: 'color: #64748b;' }), 'Copy Text' ]), ]) diff --git a/webui-src/app/chat/chat_state.js b/webui-src/app/chat/chat_state.js index 1e8d226..4bf1123 100644 --- a/webui-src/app/chat/chat_state.js +++ b/webui-src/app/chat/chat_state.js @@ -443,6 +443,7 @@ const Message = () => { y: e.clientY, messageText: targetText, username: username, + gxsId: gxsId, }; m.redraw(); }; @@ -885,6 +886,7 @@ const ChatHubState = { y: 0, messageText: '', username: '', + gxsId: '', }, }; diff --git a/webui-src/app/scss/pages/_chat.scss b/webui-src/app/scss/pages/_chat.scss index c39e8d0..3714e0e 100644 --- a/webui-src/app/scss/pages/_chat.scss +++ b/webui-src/app/scss/pages/_chat.scss @@ -1027,25 +1027,27 @@ textarea.chatMsg { } .chat-hub-input-area { - padding: 1rem 1.5rem; + padding: 0.75rem 1.5rem; background-color: #ffffff; border-top: 1px solid #cbd5e1; display: flex; gap: 0.75rem; - align-items: center; + align-items: flex-end; flex-shrink: 0; } .chat-hub-input-area textarea.chat-hub-textarea { flex: 1; - resize: none; + resize: vertical; + min-height: 40px; + max-height: 250px; height: 40px; padding: 0.5rem 0.75rem; border: 1px solid #cbd5e1; border-radius: 0.375rem; font-size: 0.9rem; outline: none; - transition: all 0.2s; + transition: border-color 0.2s, box-shadow 0.2s; background-color: #f8fafc; } diff --git a/webui-src/styles.css b/webui-src/styles.css index 82506e7..e3858ff 100644 --- a/webui-src/styles.css +++ b/webui-src/styles.css @@ -1603,25 +1603,27 @@ h1{font-size:3rem}h2{font-size:2.25rem}h3{font-size:1.875rem}h4{font-size:1.5rem } .chat-hub-input-area { - padding: 1rem 1.5rem; + padding: 0.75rem 1.5rem; background-color: #ffffff; border-top: 1px solid #cbd5e1; display: flex; gap: 0.75rem; - align-items: center; + align-items: flex-end; flex-shrink: 0; } .chat-hub-input-area textarea.chat-hub-textarea { flex: 1; - resize: none; + resize: vertical; + min-height: 40px; + max-height: 250px; height: 40px; padding: 0.5rem 0.75rem; border: 1px solid #cbd5e1; border-radius: 0.375rem; font-size: 0.9rem; outline: none; - transition: all 0.2s; + transition: border-color 0.2s, box-shadow 0.2s; background-color: #f8fafc; }