reverse proxy info

This commit is contained in:
Mateusz Gruszczyński
2026-07-24 13:39:40 +02:00
parent 21800b9bcb
commit 2c46314425
4 changed files with 37 additions and 3 deletions
+5 -1
View File
@@ -53,7 +53,11 @@ export function applyFormat(editor, format) {
if (format === "codeblock-lines") toggleWrap(editor, "```text=\n", "\n```", "code");
if (format === "mermaid") toggleWrap(editor, "```mermaid\n", "\n```", "graph TD\n A[Start] --> B[End]");
if (format === "details") toggleWrap(editor, "<details>\n<summary>Click me</summary>\n\n", "\n</details>", "Content");
if (format === "toc") toggleWrap(editor, "", "", "[TOC]");
if (format === "toc") {
const { start, end } = selection(editor);
const selected = editor.value.slice(start, end);
editor.setRangeText(selected || "[TOC]", start, end, selected ? "select" : "end");
}
if (format.startsWith("alert-")) {
const type = format.slice("alert-".length);
toggleWrap(editor, `:::${type}\n`, "\n:::", "Alert content");