refac: styling
Some checks are pending
Deploy to HuggingFace Spaces / check-secret (push) Waiting to run
Deploy to HuggingFace Spaces / deploy (push) Blocked by required conditions
Create and publish Docker images with specific build args / build-main-image (linux/amd64) (push) Waiting to run
Create and publish Docker images with specific build args / build-main-image (linux/arm64) (push) Waiting to run
Create and publish Docker images with specific build args / build-cuda-image (linux/amd64) (push) Waiting to run
Create and publish Docker images with specific build args / build-cuda-image (linux/arm64) (push) Waiting to run
Create and publish Docker images with specific build args / build-ollama-image (linux/amd64) (push) Waiting to run
Create and publish Docker images with specific build args / build-ollama-image (linux/arm64) (push) Waiting to run
Create and publish Docker images with specific build args / merge-main-images (push) Blocked by required conditions
Create and publish Docker images with specific build args / merge-cuda-images (push) Blocked by required conditions
Create and publish Docker images with specific build args / merge-ollama-images (push) Blocked by required conditions
Frontend Build / Format & Build Frontend (push) Waiting to run
Frontend Build / Frontend Unit Tests (push) Waiting to run

This commit is contained in:
Timothy Jaeryang Baek 2025-05-05 09:41:25 +04:00
parent 827fd6606c
commit a20a920ca4

View File

@ -458,6 +458,14 @@
} }
}; };
const scrollToBottom = () => {
const element = document.getElementById('note-content-container');
if (element) {
element.scrollTop = element?.scrollHeight;
}
};
const enhanceCompletionHandler = async (model) => { const enhanceCompletionHandler = async (model) => {
let enhancedContent = { let enhancedContent = {
json: null, json: null,
@ -534,6 +542,8 @@ Provide the enhanced notes in markdown format. Use markdown syntax for headings,
note.data.content.md = enhancedContent.md; note.data.content.md = enhancedContent.md;
note.data.content.html = enhancedContent.html; note.data.content.html = enhancedContent.html;
note.data.content.json = null; note.data.content.json = null;
scrollToBottom();
} }
} }
} }
@ -668,7 +678,7 @@ Provide the enhanced notes in markdown format. Use markdown syntax for headings,
</div> </div>
{:else} {:else}
<div class=" w-full flex flex-col {loading ? 'opacity-20' : ''}"> <div class=" w-full flex flex-col {loading ? 'opacity-20' : ''}">
<div class="shrink-0 w-full flex justify-between items-center px-4.5 pt-1 mb-1.5"> <div class="shrink-0 w-full flex justify-between items-center px-4.5 mb-1.5">
<div class="w-full flex items-center"> <div class="w-full flex items-center">
<input <input
class="w-full text-2xl font-medium bg-transparent outline-hidden" class="w-full text-2xl font-medium bg-transparent outline-hidden"
@ -755,7 +765,10 @@ Provide the enhanced notes in markdown format. Use markdown syntax for headings,
</div> </div>
</div> </div>
<div class=" flex-1 w-full h-full overflow-auto px-4 pb-14 relative"> <div
class=" flex-1 w-full h-full overflow-auto px-4 pb-20 relative"
id="note-content-container"
>
{#if enhancing} {#if enhancing}
<div <div
class="w-full h-full fixed top-0 left-0 {streaming class="w-full h-full fixed top-0 left-0 {streaming