Minor changes
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
# One Sky IT's Aether App - SvelteKit v2
|
||||
|
||||
This uses SvelteKit version 2, TailwindCSS, and Skelton.
|
||||
This uses SvelteKit version 2.x with Svelte version 5.x, TailwindCSS, and Skelton.
|
||||
|
||||
|
||||
# Current Modules
|
||||
|
||||
@@ -38,6 +38,9 @@ Waiting to upgrade to 4.x when ShadCN is ready. ShadCN is still being worked on
|
||||
* https://ui.shadcn.com/docs/tailwind-v4
|
||||
|
||||
|
||||
## CodeMirror 6.x (text and code editor)
|
||||
* https://codemirror.net
|
||||
|
||||
## ShadCN (Tailwind Components)
|
||||
* https://ui.shadcn.com/docs
|
||||
* https://github.com/shadcn-ui/ui
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "ae-app-svelte5",
|
||||
"version": "0.2.507",
|
||||
"version": "0.2.513",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"dev": "vite dev",
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
// *** Import Svelte version 5 specific
|
||||
import { browser } from '$app/environment';
|
||||
|
||||
import { onMount, onDestroy, createEventDispatcher } from 'svelte';
|
||||
import { onMount, onDestroy } from 'svelte';
|
||||
import {
|
||||
EditorView, keymap, highlightSpecialChars, drawSelection,
|
||||
highlightActiveLine, dropCursor, rectangularSelection,
|
||||
@@ -38,8 +38,10 @@ import { languages } from '@codemirror/language-data';
|
||||
// import { } from '@codemirror/gutter'; // Merged into @codemirror/view
|
||||
import { basicSetup } from 'codemirror';
|
||||
import { markdown, markdownLanguage } from '@codemirror/lang-markdown';
|
||||
import { javascript } from '@codemirror/lang-javascript';
|
||||
import { json } from '@codemirror/lang-json';
|
||||
// import { css } from '@codemirror/lang-css';
|
||||
// import { javascript } from '@codemirror/lang-javascript';
|
||||
// import { json } from '@codemirror/lang-json';
|
||||
// import { html } from '@codemirror/lang-html';
|
||||
import { oneDark } from "@codemirror/theme-one-dark";
|
||||
|
||||
// Props
|
||||
@@ -64,8 +66,6 @@ export let tab_size: number = 4;
|
||||
let classes = "";
|
||||
export { classes as class };
|
||||
|
||||
const dispatch = createEventDispatcher<{ change: string }>();
|
||||
|
||||
let editor_element: HTMLDivElement;
|
||||
let editorView: EditorView;
|
||||
|
||||
@@ -152,8 +152,10 @@ $: editor_extensions = [
|
||||
// placeholderExt(placeholder),
|
||||
// language,
|
||||
markdown({base: markdownLanguage, codeLanguages: languages}),
|
||||
javascript({typescript: true}),
|
||||
json({ jsx: true }),
|
||||
// javascript({typescript: true}),
|
||||
// json(),
|
||||
// css(),
|
||||
// html(),
|
||||
theme,
|
||||
|
||||
...extensions
|
||||
@@ -193,7 +195,7 @@ onMount(() => {
|
||||
if (transaction.docChanged) {
|
||||
new_content = editorView.state.doc.toString();
|
||||
const newContent = editorView.state.doc.toString();
|
||||
dispatch('change', newContent);
|
||||
// dispatch('change', newContent);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user