Merge branch 'dev/lion/chatbot' of git.targo.ca:Targo/targo_frontend into dev/lion/chatbot
This commit is contained in:
commit
3c615ffe61
|
|
@ -33,8 +33,8 @@ const text = ref('');
|
||||||
const { messages } = useChatStore();
|
const { messages } = useChatStore();
|
||||||
const { sendMessage } = useChatApi();
|
const { sendMessage } = useChatApi();
|
||||||
const handleSend = async () => {
|
const handleSend = async () => {
|
||||||
if (!text.value.trim()) return;
|
const userMessage = text.value.trim();
|
||||||
const userMessage = text.value;
|
if (!userMessage) return
|
||||||
text.value = '';
|
text.value = '';
|
||||||
|
|
||||||
messages.push({
|
messages.push({
|
||||||
|
|
@ -123,18 +123,11 @@ const handleSend = async () => {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 0;
|
top: 0;
|
||||||
left: 0;
|
left: 0;
|
||||||
/* attach to the left edge of the drawer */
|
|
||||||
width: 8px;
|
width: 8px;
|
||||||
/* sensitive area for hover */
|
|
||||||
height: 100%;
|
height: 100%;
|
||||||
/* full height of the drawer */
|
|
||||||
cursor: ew-resize;
|
cursor: ew-resize;
|
||||||
/* horizontal resize cursor */
|
|
||||||
z-index: 1000;
|
z-index: 1000;
|
||||||
/* make sure it's above other content */
|
|
||||||
/* optional: visual feedback */
|
|
||||||
background-color: rgba(0, 0, 0, 0);
|
background-color: rgba(0, 0, 0, 0);
|
||||||
/* invisible but hoverable */
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.line-separator {
|
.line-separator {
|
||||||
|
|
|
||||||
|
|
@ -17,7 +17,7 @@ const md = new MarkdownIt({
|
||||||
// Removes all the h1,h2,h3 to make the Md more user friendly
|
// Removes all the h1,h2,h3 to make the Md more user friendly
|
||||||
const cleanMarkdown = (markdown: string): string => {
|
const cleanMarkdown = (markdown: string): string => {
|
||||||
if (!markdown) return ''
|
if (!markdown) return ''
|
||||||
return markdown.replace(/^#{1,3}\s.*$/gm, '')
|
return markdown.replace(/^#{1,3}\s(.*)$/gm, '#### $1')
|
||||||
}
|
}
|
||||||
|
|
||||||
// Compute parsed content
|
// Compute parsed content
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user