blah blah

This commit is contained in:
Donavon McDowell 2024-12-19 16:56:20 -07:00
parent 70254cbf2a
commit 1a52779ec3
2 changed files with 8 additions and 4 deletions

View File

@ -31,7 +31,10 @@
extensions: [
StarterKit,
Underline,
Image.configure({ block: true }),
Image.configure({
inline: true,
allowBase64: true,
}),
Dropcursor,
CodeBlock.configure({
exitOnTripleEnter: true,
@ -86,7 +89,7 @@
}),
],
// place the cursor in the editor after initialization
autofocus: true,
autofocus: false,
// make the text editable (but thats the default anyway)
editable: true,
// disable the loading of the default CSS (which is not much anyway)

View File

@ -1,6 +1,7 @@
<script>
import { onMount } from 'svelte';
import { page } from "$app/stores"
import { PUBLIC_BASE_URL } from '$env/static/public';
//import { PUBLIC_BASE_URL } from '$env/static/public';
//import { PUBLIC_BASE_URL } from '$env/dynamic/private'
@ -26,7 +27,7 @@
// Function to simulate search API call
async function searchDocuments(query) {
try {
const res = await fetch(`https://docucenter.mpe.ca/api/document/search?query=${query}`);
const res = await fetch(`${PUBLIC_BASE_URL}/api/document/search?query=${query}`);
const data = await res.json();
if (data.length > 0) {
@ -43,7 +44,7 @@
// Function to fetch all documents from the API
async function getAllDocuments() {
try {
const res = await fetch(`https://docucenter.mpe.ca/api/document`);
const res = await fetch(`${PUBLIC_BASE_URL}/api/document`);
if (!res.ok) {
throw new Error(`Failed to fetch documents: ${res.statusText}`);