Big News: Socket raises $60M Series C at a $1B valuation to secure software supply chains for AI-driven development.Announcement
Sign In

@editora/core

Package Overview
Dependencies
Maintainers
1
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@editora/core - npm Package Compare versions

Comparing version
1.0.4
to
1.0.5
dist/CodePlugin.native-B263UI8O.mjs

Sorry, the diff of this file is too big to display

+384
const T = () => {
const d = window.getSelection();
if (d && d.rangeCount > 0) {
let t = d.getRangeAt(0).startContainer;
for (; t && t !== document.body; ) {
if (t.nodeType === Node.ELEMENT_NODE) {
const a = t;
if (a.getAttribute("contenteditable") === "true")
return a;
}
t = t.parentNode;
}
}
const l = document.activeElement;
if (l) {
if (l.getAttribute("contenteditable") === "true")
return l;
const t = l.closest('[contenteditable="true"]');
if (t) return t;
}
return document.querySelector('[contenteditable="true"]');
}, k = '[data-theme="dark"], .dark, .editora-theme-dark', A = () => {
const d = T();
if (d != null && d.closest(k)) return !0;
const l = window.getSelection();
if (l && l.rangeCount > 0) {
const a = l.getRangeAt(0).startContainer, i = a.nodeType === Node.ELEMENT_NODE ? a : a.parentElement;
if (i != null && i.closest(k)) return !0;
}
const t = document.activeElement;
return t != null && t.closest(k) ? !0 : document.body.matches(k) || document.documentElement.matches(k);
}, M = [
{ value: "javascript", label: "JavaScript" },
{ value: "typescript", label: "TypeScript" },
{ value: "python", label: "Python" },
{ value: "java", label: "Java" },
{ value: "csharp", label: "C#" },
{ value: "cpp", label: "C++" },
{ value: "c", label: "C" },
{ value: "php", label: "PHP" },
{ value: "ruby", label: "Ruby" },
{ value: "go", label: "Go" },
{ value: "rust", label: "Rust" },
{ value: "swift", label: "Swift" },
{ value: "kotlin", label: "Kotlin" },
{ value: "html", label: "HTML" },
{ value: "css", label: "CSS" },
{ value: "scss", label: "SCSS" },
{ value: "json", label: "JSON" },
{ value: "xml", label: "XML" },
{ value: "yaml", label: "YAML" },
{ value: "markdown", label: "Markdown" },
{ value: "sql", label: "SQL" },
{ value: "bash", label: "Bash" },
{ value: "shell", label: "Shell" },
{ value: "plaintext", label: "Plain Text" }
], S = /* @__PURE__ */ new Map();
function $(d, l, t, a) {
const i = !!l, n = a || "javascript", f = t || "", p = A(), e = p ? {
overlay: "rgba(0, 0, 0, 0.62)",
dialogBg: "#1f2937",
dialogBorder: "#4b5563",
text: "#e2e8f0",
mutedText: "#a8b5c8",
headerFooterBg: "#222d3a",
border: "#3b4657",
fieldBg: "#111827",
fieldBorder: "#4b5563",
cancelBg: "#334155",
cancelHover: "#475569",
cancelText: "#e2e8f0",
primaryBg: "#3b82f6",
primaryHover: "#2563eb"
} : {
overlay: "rgba(0, 0, 0, 0.5)",
dialogBg: "#ffffff",
dialogBorder: "#e0e0e0",
text: "#333333",
mutedText: "#666666",
headerFooterBg: "#ffffff",
border: "#e0e0e0",
fieldBg: "#ffffff",
fieldBorder: "#dddddd",
cancelBg: "#e5e7eb",
cancelHover: "#d1d5db",
cancelText: "#333333",
primaryBg: "#2563eb",
primaryHover: "#1d4ed8"
}, c = document.createElement("div");
c.className = "rte-code-sample-overlay", p && c.classList.add("rte-theme-dark"), c.style.cssText = `
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: ${e.overlay};
display: flex;
align-items: center;
justify-content: center;
z-index: 10000;
animation: fadeIn 160ms ease-out;
`;
const o = document.createElement("div");
o.className = "rte-code-sample-dialog", o.style.cssText = `
background: ${e.dialogBg};
border: 1px solid ${e.dialogBorder};
border-radius: 8px;
box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
max-width: 700px;
width: 90vw;
max-height: 80vh;
display: flex;
flex-direction: column;
animation: slideUp 200ms cubic-bezier(0.2, 0.9, 0.25, 1);
`;
const u = document.createElement("div");
u.style.cssText = `
padding: 20px;
border-bottom: 1px solid ${e.border};
background: ${e.headerFooterBg};
display: flex;
justify-content: space-between;
align-items: center;
`, u.innerHTML = `
<h2 style="margin: 0; font-size: 18px; font-weight: 600; color: ${e.text};">
${i ? "Edit Code Sample" : "Insert Code Sample"}
</h2>
<button class="rte-code-close-btn" style="background: none; border: none; font-size: 28px; color: ${e.mutedText}; cursor: pointer; padding: 0; width: 32px; height: 32px;">×</button>
`;
const m = document.createElement("div");
m.style.cssText = `
flex: 1;
overflow-y: auto;
padding: 20px;
`;
const s = document.createElement("div");
s.style.marginBottom = "20px", s.innerHTML = `
<label style="display: block; margin-bottom: 8px; font-weight: 500; color: ${e.text}; font-size: 14px;">Language</label>
<select class="rte-code-language" style="
width: 100%;
padding: 10px 12px;
border: 1px solid ${e.fieldBorder};
border-radius: 4px;
font-size: 14px;
background-color: ${e.fieldBg};
color: ${e.text};
cursor: pointer;
">
${M.map((r) => `
<option value="${r.value}" ${r.value === n ? "selected" : ""}>
${r.label}
</option>
`).join("")}
</select>
`;
const b = document.createElement("div");
b.style.marginBottom = "20px", b.innerHTML = `
<label style="display: block; margin-bottom: 8px; font-weight: 500; color: ${e.text}; font-size: 14px;">Code</label>
<textarea class="rte-code-textarea" spellcheck="false" placeholder="Paste or type your code here..." style="
width: 100%;
padding: 12px;
border: 1px solid ${e.fieldBorder};
border-radius: 4px;
font-family: 'Courier New', Courier, monospace;
font-size: 13px;
line-height: 1.5;
resize: vertical;
min-height: 250px;
max-height: 400px;
background-color: ${e.fieldBg};
color: ${e.text};
box-sizing: border-box;
">${f}</textarea>
<div class="rte-code-error" style="color: #dc2626; font-size: 12px; margin-top: 6px; display: none;"></div>
`;
const x = document.createElement("div");
x.style.cssText = `color: ${e.mutedText}; font-size: 12px; margin-top: 10px;`, x.innerHTML = "💡 Tip: Press Ctrl+Enter (or Cmd+Enter on Mac) to save, or Escape to cancel", m.appendChild(s), m.appendChild(b), m.appendChild(x);
const y = document.createElement("div");
y.style.cssText = `
padding: 20px;
border-top: 1px solid ${e.border};
background: ${e.headerFooterBg};
display: flex;
justify-content: flex-end;
gap: 12px;
`, y.innerHTML = `
<button class="rte-code-cancel-btn" style="
padding: 10px 16px;
border: none;
border-radius: 4px;
font-size: 14px;
font-weight: 500;
cursor: pointer;
background: ${e.cancelBg};
color: ${e.cancelText};
">Cancel</button>
<button class="rte-code-save-btn" style="
padding: 10px 16px;
border: none;
border-radius: 4px;
font-size: 14px;
font-weight: 500;
cursor: pointer;
background: ${e.primaryBg};
color: #fff;
">${i ? "Update Code Sample" : "Insert Code Sample"}</button>
`, o.appendChild(u), o.appendChild(m), o.appendChild(y), c.appendChild(o);
const L = s.querySelector(".rte-code-language"), E = b.querySelector(".rte-code-textarea"), w = b.querySelector(".rte-code-error"), g = u.querySelector(".rte-code-close-btn"), v = y.querySelector(".rte-code-cancel-btn"), h = y.querySelector(".rte-code-save-btn");
g.onmouseover = () => {
g.style.color = "#f8fafc", g.style.background = p ? "#334155" : "#f0f0f0", g.style.borderRadius = "4px";
}, g.onmouseout = () => {
g.style.color = e.mutedText, g.style.background = "none";
}, v.onmouseover = () => {
v.style.background = e.cancelHover;
}, v.onmouseout = () => {
v.style.background = e.cancelBg;
}, h.onmouseover = () => {
h.style.background = e.primaryHover;
}, h.onmouseout = () => {
h.style.background = e.primaryBg;
};
const C = () => {
c.remove();
}, B = () => {
const r = E.value.trim();
if (!r) {
w.textContent = "⚠ Code cannot be empty", w.style.display = "block";
return;
}
const N = L.value;
d(r, N), C();
};
if (g.onclick = C, v.onclick = C, h.onclick = B, E.addEventListener("keydown", (r) => {
(r.ctrlKey || r.metaKey) && r.key === "Enter" && (r.preventDefault(), B()), r.key === "Escape" && C();
}), E.addEventListener("input", () => {
w.style.display = "none";
}), c.addEventListener("click", (r) => {
r.target === c && C();
}), !document.getElementById("rte-code-sample-animations")) {
const r = document.createElement("style");
r.id = "rte-code-sample-animations", r.textContent = `
@keyframes fadeIn {
from { opacity: 0; }
to { opacity: 1; }
}
@keyframes slideUp {
from { transform: translateY(20px); opacity: 0; }
to { transform: translateY(0); opacity: 1; }
}
`, document.head.appendChild(r);
}
return document.body.appendChild(c), setTimeout(() => E.focus(), 100), c;
}
function R() {
if (!T()) return;
let l = null;
const t = window.getSelection();
t && t.rangeCount > 0 && (l = t.getRangeAt(0).cloneRange()), $((a, i) => {
const n = window.getSelection();
if (l && (n == null || n.removeAllRanges(), n == null || n.addRange(l)), !n || n.rangeCount === 0) return;
const f = T();
if (!f) return;
const p = n.anchorNode;
if (!p || !f.contains(p)) return;
const e = n.getRangeAt(0), c = `code-block-${Date.now()}`, o = document.createElement("pre");
o.className = "rte-code-block", o.id = c, o.setAttribute("data-type", "code-block"), o.setAttribute("data-lang", i), o.setAttribute("data-code-id", c), o.setAttribute("contenteditable", "false"), o.style.cssText = `
display: block;
position: relative;
background: #f5f5f5;
border: 1px solid #e0e0e0;
border-radius: 6px;
padding: 12px;
margin: 12px 0;
overflow-x: auto;
font-family: 'Courier New', 'Monaco', 'Menlo', monospace;
font-size: 13px;
line-height: 1.5;
color: #333;
user-select: text;
cursor: default;
`;
const u = document.createElement("code");
u.className = `language-${i}`, u.style.cssText = `
font-family: inherit;
font-size: inherit;
line-height: inherit;
color: inherit;
white-space: pre;
word-break: normal;
display: block;
`, u.textContent = a;
const m = document.createElement("span");
m.style.cssText = `
position: absolute;
top: 0;
right: 0;
background: #333;
color: #fff;
padding: 2px 8px;
font-size: 11px;
font-weight: bold;
border-radius: 0 6px 0 4px;
text-transform: uppercase;
letter-spacing: 0.5px;
pointer-events: none;
`, m.textContent = i;
const s = document.createElement("button");
s.className = "rte-code-copy", s.textContent = "Copy", s.style.cssText = `
position: absolute;
top: 8px;
left: 8px;
background: #fff;
border: 1px solid #d0d0d0;
border-radius: 3px;
padding: 4px 8px;
font-size: 11px;
cursor: pointer;
opacity: 0;
transition: opacity 0.2s ease;
`, s.onclick = (x) => {
x.stopPropagation(), navigator.clipboard.writeText(a).then(() => {
s.textContent = "✓ Copied!", setTimeout(() => {
s.textContent = "Copy";
}, 2e3);
});
}, o.appendChild(m), o.appendChild(s), o.appendChild(u), o.addEventListener("mouseenter", () => {
s.style.opacity = "1";
}), o.addEventListener("mouseleave", () => {
s.style.opacity = "0";
}), o.addEventListener("dblclick", () => {
z(c);
}), S.set(c, {
id: c,
language: i,
code: a
}), e.insertNode(o);
const b = document.createRange();
b.setStartAfter(o), b.collapse(!0), n.removeAllRanges(), n.addRange(b);
});
}
function z(d) {
const l = T();
if (!l) return;
const t = l.querySelector(`#${d}`);
if (!t) return;
const a = S.get(d);
a && $(
(i, n) => {
const f = t.querySelector("code");
f && (f.textContent = i, f.className = `language-${n}`);
const p = t.querySelector("span");
p && (p.textContent = n), t.setAttribute("data-lang", n), a.language = n, a.code = i;
const e = t.querySelector(".rte-code-copy");
e && (e.onclick = (c) => {
c.stopPropagation(), navigator.clipboard.writeText(i).then(() => {
e.textContent = "✓ Copied!", setTimeout(() => {
e.textContent = "Copy";
}, 2e3);
});
});
},
d,
a.code,
a.language
);
}
const H = () => ({
name: "codeSample",
toolbar: [
{
label: "Insert Code",
command: "insertCodeBlock",
icon: '<svg width="24" height="26" focusable="false"><path d="M7.1 11a2.8 2.8 0 0 1-.8 2 2.8 2.8 0 0 1 .8 2v1.7c0 .3.1.6.4.8.2.3.5.4.8.4.3 0 .4.2.4.4v.8c0 .2-.1.4-.4.4-.7 0-1.4-.3-2-.8-.5-.6-.8-1.3-.8-2V15c0-.3-.1-.6-.4-.8-.2-.3-.5-.4-.8-.4a.4.4 0 0 1-.4-.4v-.8c0-.2.2-.4.4-.4.3 0 .6-.1.8-.4.3-.2.4-.5.4-.8V9.3c0-.7.3-1.4.8-2 .6-.5 1.3-.8 2-.8.3 0 .4.2.4.4v.8c0 .2-.1.4-.4.4-.3 0-.6.1-.8.4-.3.2-.4.5-.4.8V11Zm9.8 0V9.3c0-.3-.1-.6-.4-.8-.2-.3-.5-.4-.8-.4a.4.4 0 0 1-.4-.4V7c0-.2.1-.4.4-.4.7 0 1.4.3 2 .8.5.6.8 1.3.8 2V11c0 .3.1.6.4.8.2.3.5.4.8.4.2 0 .4.2.4.4v.8c0 .2-.2.4-.4.4-.3 0-.6.1-.8.4-.3.2-.4.5-.4.8v1.7c0 .7-.3 1.4-.8 2-.6.5-1.3.8-2 .8a.4.4 0 0 1-.4-.4v-.8c0-.2.1-.4.4-.4.3 0 .6-.1.8-.4.3-.2.4-.5.4-.8V15a2.8 2.8 0 0 1 .8-2 2.8 2.8 0 0 1-.8-2Zm-3.3-.4c0 .4-.1.8-.5 1.1-.3.3-.7.5-1.1.5-.4 0-.8-.2-1.1-.5-.4-.3-.5-.7-.5-1.1 0-.5.1-.9.5-1.2.3-.3.7-.4 1.1-.4.4 0 .8.1 1.1.4.4.3.5.7.5 1.2ZM12 13c.4 0 .8.1 1.1.5.4.3.5.7.5 1.1 0 1-.1 1.6-.5 2a3 3 0 0 1-1.1 1c-.4.3-.8.4-1.1.4a.5.5 0 0 1-.5-.5V17a3 3 0 0 0 1-.2l.6-.6c-.6 0-1-.2-1.3-.5-.2-.3-.3-.7-.3-1 0-.5.1-1 .5-1.2.3-.4.7-.5 1.1-.5Z" fill-rule="evenodd"></path></svg>',
shortcut: "Mod-Shift-C"
}
],
commands: {
insertCodeBlock: (...d) => (R(), !0)
}
});
export {
H as CodeSamplePlugin
};
//# sourceMappingURL=CodeSamplePlugin.native-CgGoH-X4.mjs.map
const A = ".rte-content, .editora-content";
const y = "__editoraCommandEditorRoot", s = /* @__PURE__ */ new Map(), E = {};
let T = !1, c = null;
function N(t) {
if (!t) return null;
const e = t.querySelector('[contenteditable="true"]');
return e instanceof HTMLElement ? e : null;
}
function z() {
if (typeof window == "undefined") return null;
const t = window[y];
if (!(t instanceof HTMLElement)) return null;
window[y] = null;
const e = t.closest("[data-editora-editor], .rte-editor, .editora-editor, editora-editor") || (t.matches("[data-editora-editor], .rte-editor, .editora-editor, editora-editor") ? t : null);
if (e) {
const o = N(e);
if (o) return o;
if (e.getAttribute("contenteditable") === "true") return e;
}
if (t.getAttribute("contenteditable") === "true")
return t;
const n = t.closest('[contenteditable="true"]');
return n instanceof HTMLElement ? n : null;
}
function F(t) {
return t ? t.nodeType === Node.ELEMENT_NODE ? t : t.parentElement : null;
}
function f(t) {
const e = F(t);
if (!e) return null;
const n = e.closest(A);
if (n) return n;
const o = e.closest('[contenteditable="true"]');
if (!o) return null;
let r = o, i = r.parentElement;
for (; i; )
i.getAttribute("contenteditable") === "true" && (r = i), i = i.parentElement;
return r;
}
function l() {
const t = z();
if (t && document.contains(t))
return t;
const e = window.getSelection();
if (e && e.rangeCount > 0) {
const i = f(e.getRangeAt(0).startContainer);
if (i) return i;
}
const n = document.activeElement;
if (n) {
const i = f(n);
if (i) return i;
}
if (c != null && c.isConnected) return c;
const o = Array.from(s.keys()).find((i) => i.isConnected);
if (o) return o;
const r = document.querySelector(A);
return r || document.querySelector('[contenteditable="true"]');
}
function L() {
for (const t of s.keys())
t.isConnected || (s.delete(t), c === t && (c = null));
}
function M(t) {
L();
let e = s.get(t);
return e || (e = { undoStack: [], redoStack: [] }, s.set(t, e)), e;
}
function d(t) {
t && t.dispatchEvent(new Event("input", { bubbles: !0 }));
}
function h(t) {
return t ? t.innerHTML : "";
}
function m(t, e) {
if (!t) return;
const n = M(t);
n.undoStack.push(e), n.redoStack.length = 0, n.undoStack.length > 100 && n.undoStack.splice(0, n.undoStack.length - 100), c = t;
}
function v(t, e = "undo") {
if (L(), t != null && t.isConnected)
return t;
const n = l();
if (n != null && n.isConnected)
return n;
if (c != null && c.isConnected)
return c;
const o = (r) => e === "undo" ? r.undoStack.length > 0 : r.redoStack.length > 0;
for (const [r, i] of s.entries())
if (r.isConnected && o(i))
return r;
return null;
}
function H(t) {
const e = {};
for (const r of t.getAttributeNames()) {
const i = t.getAttribute(r);
i !== null && (e[r] = i);
}
const n = t instanceof HTMLInputElement || t instanceof HTMLTextAreaElement || t instanceof HTMLSelectElement, o = t instanceof HTMLInputElement;
return {
attributes: e,
innerHTML: t.innerHTML,
value: n ? t.value : null,
checked: o ? t.checked : null
};
}
function w(t, e) {
const n = new Set(t.getAttributeNames());
Object.keys(e.attributes).forEach((o) => n.delete(o)), n.forEach((o) => t.removeAttribute(o)), Object.entries(e.attributes).forEach(([o, r]) => {
t.setAttribute(o, r);
}), t.innerHTML !== e.innerHTML && (t.innerHTML = e.innerHTML), e.value !== null && (t instanceof HTMLInputElement || t instanceof HTMLTextAreaElement || t instanceof HTMLSelectElement) && (t.value = e.value), e.checked !== null && t instanceof HTMLInputElement && (t.checked = e.checked);
}
function u(t, e) {
if (E[t] = e, typeof window == "undefined") return;
const n = window.registerEditorCommand;
typeof n == "function" ? n(t, e) : (window.registerEditorCommand = (o, r) => {
E[o] = r;
}, window.registerEditorCommand(t, e));
}
const S = (t, ...e) => {
const n = E[t];
return n ? n(...e) : !1;
};
function C() {
T || typeof window == "undefined" || (T = !0, window.execEditorCommand || (window.execEditorCommand = S), window.executeEditorCommand || (window.executeEditorCommand = S), u("undo", k), u("redo", O), u("setAttribute", D), u("setText", _), u("autoFixA11y", R), u("recordDomTransaction", I), u("undoDom", b), u("redoDom", p));
}
function x(t, e) {
const n = e || l(), o = h(n);
n == null || n.focus({ preventScroll: !0 });
let r = !1;
try {
r = !!document.execCommand(t, !1);
} catch (g) {
r = !1;
}
const i = h(n), a = o !== i;
return a && d(n), { executed: r, changed: a };
}
const k = () => {
const t = l();
return x("undo", t).changed ? !0 : b(t != null ? t : void 0);
}, O = () => {
const t = l();
return x("redo", t).changed ? !0 : p(t != null ? t : void 0);
}, D = (t, e, n) => {
if (!(t instanceof HTMLElement)) return;
const o = f(t), r = t.hasAttribute(e), i = t.getAttribute(e);
t.setAttribute(e, n), m(o, {
undo: () => {
t.isConnected && (r && i !== null ? t.setAttribute(e, i) : t.removeAttribute(e));
},
redo: () => {
t.isConnected && t.setAttribute(e, n);
}
}), d(o);
}, _ = (t, e) => {
var r;
if (!(t instanceof HTMLElement)) return;
const n = f(t), o = (r = t.textContent) != null ? r : "";
t.textContent = e, m(n, {
undo: () => {
t.isConnected && (t.textContent = o);
},
redo: () => {
t.isConnected && (t.textContent = e);
}
}), d(n);
}, R = (t) => {
var a;
const e = t == null ? void 0 : t.element;
if (!(e instanceof HTMLElement)) return;
const n = f(e), o = (a = window.a11yRuleRegistry) == null ? void 0 : a.find((g) => g.id === t.rule);
if (!o || typeof o.fix != "function") return;
const r = H(e);
o.fix(t);
const i = H(e);
m(n, {
undo: () => {
e.isConnected && w(e, r);
},
redo: () => {
e.isConnected && w(e, i);
}
}), d(n);
}, I = (t, e, n) => {
if (!(t instanceof HTMLElement)) return !1;
const o = typeof n == "string" ? n : t.innerHTML;
return e === o ? !1 : (m(t, {
undo: () => {
t.isConnected && (t.innerHTML = e);
},
redo: () => {
t.isConnected && (t.innerHTML = o);
}
}), !0);
}, b = (t) => {
const e = v(t, "undo");
if (!e) return !1;
const n = M(e), o = n.undoStack.pop();
return o ? (o.undo(), n.redoStack.push(o), c = e, d(e), !0) : !1;
}, p = (t) => {
const e = v(t, "redo");
if (!e) return !1;
const n = M(e), o = n.redoStack.pop();
return o ? (o.redo(), n.undoStack.push(o), c = e, d(e), !0) : !1;
};
typeof window != "undefined" && (document.readyState === "loading" ? document.addEventListener("DOMContentLoaded", C, { once: !0 }) : C());
const Y = () => (C(), {
name: "history",
toolbar: [
{
label: "Undo",
command: "undo",
type: "button",
icon: '<svg width="24" height="24" focusable="false"><path d="M6.4 8H12c3.7 0 6.2 2 6.8 5.1.6 2.7-.4 5.6-2.3 6.8a1 1 0 0 1-1-1.8c1.1-.6 1.8-2.7 1.4-4.6-.5-2.1-2.1-3.5-4.9-3.5H6.4l3.3 3.3a1 1 0 1 1-1.4 1.4l-5-5a1 1 0 0 1 0-1.4l5-5a1 1 0 0 1 1.4 1.4L6.4 8Z" fill-rule="nonzero"></path></svg>',
shortcut: "Mod-z"
},
{
label: "Redo",
command: "redo",
type: "button",
icon: '<svg width="24" height="24" focusable="false"><path d="M17.6 10H12c-2.8 0-4.4 1.4-4.9 3.5-.4 2 .3 4 1.4 4.6a1 1 0 1 1-1 1.8c-2-1.2-2.9-4.1-2.3-6.8.6-3 3-5.1 6.8-5.1h5.6l-3.3-3.3a1 1 0 1 1 1.4-1.4l5 5a1 1 0 0 1 0 1.4l-5 5a1 1 0 0 1-1.4-1.4l3.3-3.3Z" fill-rule="nonzero"></path></svg>',
shortcut: "Mod-y"
}
],
commands: {
undo: k,
redo: O,
setAttribute: D,
setText: _,
autoFixA11y: R,
recordDomTransaction: I,
undoDom: b,
redoDom: p
},
keymap: {
"Mod-z": "undo",
"Mod-Z": "undo",
"Mod-y": "redo",
"Mod-Y": "redo",
"Mod-Shift-z": "redo",
"Mod-Shift-Z": "redo"
}
});
export {
Y as HistoryPlugin,
R as autoFixA11y,
I as recordDomTransaction,
O as redo,
p as redoDom,
D as setAttribute,
_ as setText,
k as undo,
b as undoDom
};
//# sourceMappingURL=HistoryPlugin.native-TDnVMsEO.mjs.map
const D = {
USER: {
name: "User",
tags: [
{ key: "first_name", label: "First Name", category: "User", preview: "John" },
{ key: "last_name", label: "Last Name", category: "User", preview: "Doe" },
{ key: "email", label: "Email", category: "User", preview: "john@example.com" },
{ key: "phone", label: "Phone", category: "User", preview: "+1-555-1234" },
{ key: "full_name", label: "Full Name", category: "User", preview: "John Doe" },
{ key: "username", label: "Username", category: "User", preview: "johndoe" }
]
},
COMPANY: {
name: "Company",
tags: [
{ key: "company_name", label: "Company Name", category: "Company", preview: "Acme Corp" },
{ key: "company_address", label: "Company Address", category: "Company", preview: "123 Main St" },
{ key: "company_phone", label: "Company Phone", category: "Company", preview: "+1-555-0000" },
{ key: "company_email", label: "Company Email", category: "Company", preview: "info@acme.com" }
]
},
DATE: {
name: "Date",
tags: [
{ key: "today", label: "Today", category: "Date", preview: (/* @__PURE__ */ new Date()).toLocaleDateString() },
{ key: "tomorrow", label: "Tomorrow", category: "Date", preview: new Date(Date.now() + 864e5).toLocaleDateString() },
{ key: "next_week", label: "Next Week", category: "Date", preview: new Date(Date.now() + 6048e5).toLocaleDateString() }
]
},
CUSTOM: {
name: "Custom",
tags: []
}
}, v = ".rte-content, .editora-content", K = '[data-theme="dark"], .dark, .editora-theme-dark', A = Object.keys(D), Y = A.reduce(
(t, e) => (t[e] = D[e].tags.map((r) => {
var n;
return {
...r,
searchIndex: `${r.label} ${r.key} ${r.category} ${"description" in r && (n = r.description) != null ? n : ""}`.toLowerCase()
};
}), t),
{}
);
let j = !1, H = !1, E = null, w = null, k = null, P = !1;
function R() {
if (j || typeof document == "undefined") return;
j = !0;
const t = document.createElement("style");
t.id = "merge-tag-plugin-styles", t.textContent = `
.rte-merge-tag-overlay {
--rte-mt-overlay-bg: rgba(15, 23, 36, 0.56);
--rte-mt-dialog-bg: #ffffff;
--rte-mt-dialog-text: #101828;
--rte-mt-border: #d6dbe4;
--rte-mt-subtle-bg: #f7f9fc;
--rte-mt-subtle-hover: #eef2f7;
--rte-mt-muted-text: #5f6b7d;
--rte-mt-accent: #1976d2;
--rte-mt-accent-strong: #1565c0;
position: fixed;
inset: 0;
background-color: var(--rte-mt-overlay-bg);
backdrop-filter: blur(2px);
display: flex;
align-items: center;
justify-content: center;
z-index: 10000;
padding: 16px;
box-sizing: border-box;
}
.rte-merge-tag-overlay.rte-ui-theme-dark {
--rte-mt-overlay-bg: rgba(2, 8, 20, 0.72);
--rte-mt-dialog-bg: #202938;
--rte-mt-dialog-text: #e8effc;
--rte-mt-border: #49566c;
--rte-mt-subtle-bg: #2a3444;
--rte-mt-subtle-hover: #344256;
--rte-mt-muted-text: #a5b1c5;
--rte-mt-accent: #58a6ff;
--rte-mt-accent-strong: #4598f4;
}
.rte-merge-tag-dialog {
background: var(--rte-mt-dialog-bg);
color: var(--rte-mt-dialog-text);
border: 1px solid var(--rte-mt-border);
border-radius: 12px;
box-shadow: 0 24px 48px rgba(10, 15, 24, 0.28);
width: 500px;
max-width: 90vw;
max-height: 80vh;
display: flex;
flex-direction: column;
overflow: hidden;
}
.rte-merge-tag-header { padding: 16px; border-bottom: 1px solid var(--rte-mt-border); display:flex; justify-content:space-between; align-items:center; }
.rte-merge-tag-body { padding: 16px; overflow-y:auto; flex:1; }
.rte-merge-tag-input { width:100%; padding:10px; border:1px solid var(--rte-mt-border); border-radius:4px; background:var(--rte-mt-subtle-bg); color:var(--rte-mt-dialog-text); }
.rte-merge-tag-tabs { display:flex; gap:8px; margin: 12px 0; }
.rte-merge-tag-tab { padding:8px 12px; background:none; border:none; cursor:pointer; color:var(--rte-mt-muted-text); border-bottom:3px solid transparent; }
.rte-merge-tag-tab.active { color:var(--rte-mt-accent); border-bottom-color:var(--rte-mt-accent); }
.rte-merge-tag-list { border:1px solid var(--rte-mt-border); border-radius:4px; max-height:300px; overflow-y:auto; margin-bottom:12px; background:var(--rte-mt-subtle-bg); }
.rte-merge-tag-item { padding:8px 12px; border-bottom:1px solid var(--rte-mt-border); cursor:pointer; transition:background-color 0.16s; color:var(--rte-mt-dialog-text); }
.rte-merge-tag-item:last-child { border-bottom: none; }
.rte-merge-tag-item.selected, .rte-merge-tag-item:hover { background-color:var(--rte-mt-subtle-hover); }
.rte-merge-tag-item-label { font-weight: 600; }
.rte-merge-tag-item-preview { font-size: 12px; color: var(--rte-mt-muted-text); margin-top: 2px; }
.rte-merge-tag-empty { padding: 24px; text-align: center; color: var(--rte-mt-muted-text); }
.rte-merge-tag-preview { padding:8px; background:var(--rte-mt-subtle-bg); border-radius:4px; font-family:monospace; font-size:12px; color:var(--rte-mt-dialog-text); }
.rte-merge-tag-footer { padding:12px 16px; border-top:1px solid var(--rte-mt-border); display:flex; gap:8px; justify-content:flex-end; background:var(--rte-mt-subtle-bg); }
.rte-merge-tag-btn-primary { padding:8px 16px; border:none; border-radius:4px; background:var(--rte-mt-accent); color:#fff; cursor:pointer; }
.rte-merge-tag-btn-primary:hover { background: var(--rte-mt-accent-strong); }
.rte-merge-tag-btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }
.rte-merge-tag-btn-secondary { padding:8px 16px; border:1px solid var(--rte-mt-border); border-radius:4px; background:var(--rte-mt-subtle-bg); color:var(--rte-mt-dialog-text); cursor:pointer; }
.rte-merge-tag {
display: inline-flex;
align-items: center;
white-space: nowrap;
user-select: none;
background-color: #e3f2fd;
border: 1px solid #bbdefb;
border-radius: 3px;
padding: 1px 6px;
margin: 0 2px;
color: #1976d2;
font-weight: 600;
line-height: 1.3;
}
:is([data-theme="dark"], .dark, .editora-theme-dark) .rte-merge-tag {
background: #223247;
border-color: #3f5f84;
color: #8dc4ff;
}
`, document.head.appendChild(t);
}
function $() {
H || typeof document == "undefined" || (H = !0, document.addEventListener("focusin", (t) => {
const e = t.target, r = e == null ? void 0 : e.closest(v);
r && (E = r);
}), document.addEventListener("selectionchange", () => {
const t = V();
t && (E = t);
}));
}
function V() {
const t = window.getSelection();
if (!t || t.rangeCount === 0) return null;
const r = t.getRangeAt(0).startContainer, n = r.nodeType === Node.ELEMENT_NODE ? r : r.parentElement;
return (n == null ? void 0 : n.closest(v)) || null;
}
function J() {
const t = V();
if (t) return t;
const e = document.activeElement, r = e == null ? void 0 : e.closest(v);
return r || (E != null && E.isConnected ? E : document.querySelector(v));
}
function Q(t) {
const e = t.parentNode;
if (!e) return;
const r = window.getSelection();
if (!r) return;
const n = document.createRange(), o = Array.from(e.childNodes).indexOf(t);
o < 0 || (n.setStart(e, o), n.setEnd(e, o + 1), r.removeAllRanges(), r.addRange(n));
}
function B(t, e) {
var r;
t instanceof Text && t.data.length !== 0 && (e ? (t.data.startsWith(" ") || t.data.startsWith(" ")) && t.deleteData(0, 1) : (t.data.endsWith(" ") || t.data.endsWith(" ")) && t.deleteData(t.data.length - 1, 1), t.data.length === 0 && ((r = t.parentNode) == null || r.removeChild(t)));
}
function G(t, e) {
const r = window.getSelection();
if (!r) return;
const n = document.createRange(), i = Math.max(0, Math.min(e, t.childNodes.length));
n.setStart(t, i), n.collapse(!0), r.removeAllRanges(), r.addRange(n);
}
function Z(t, e) {
var d;
const r = t.parentNode;
if (!r) return !1;
const i = Array.from(r.childNodes).indexOf(t);
if (i < 0) return !1;
const o = t.previousSibling, c = t.nextSibling;
r.removeChild(t), e === "Backspace" ? (B(c, !0), G(r, i)) : (B(o, !1), G(r, i));
const g = r instanceof HTMLElement ? r.closest(v) : ((d = r.parentElement) == null ? void 0 : d.closest(v)) || null;
return g && g.dispatchEvent(new Event("input", { bubbles: !0 })), !0;
}
function ee(t) {
if (t.collapsed || !(t.startContainer instanceof HTMLElement || t.startContainer instanceof Text) || t.startContainer !== t.endContainer || t.endOffset !== t.startOffset + 1) return null;
const e = t.startContainer;
if (!(e instanceof Element || e instanceof DocumentFragment)) return null;
const r = e.childNodes[t.startOffset];
return r instanceof HTMLElement && r.classList.contains("rte-merge-tag") ? r : null;
}
function te(t, e) {
if (!t.collapsed) return null;
const { startContainer: r, startOffset: n } = t, i = (o) => o instanceof HTMLElement && o.classList.contains("rte-merge-tag") ? o : null;
if (r.nodeType === Node.ELEMENT_NODE) {
const o = r;
return e === "Backspace" && n > 0 ? i(o.childNodes[n - 1] || null) : e === "Delete" ? i(o.childNodes[n] || null) : null;
}
if (r.nodeType === Node.TEXT_NODE) {
const o = r;
return e === "Backspace" ? n === 0 ? i(o.previousSibling) : n === 1 && (o.data[0] === " " || o.data[0] === " ") && o.previousSibling instanceof HTMLElement && o.previousSibling.classList.contains("rte-merge-tag") ? o.previousSibling : null : n === o.data.length ? i(o.nextSibling) : null;
}
return null;
}
function q() {
P || typeof document == "undefined" || (P = !0, document.addEventListener("click", (t) => {
const e = t.target, r = e == null ? void 0 : e.closest(".rte-merge-tag");
if (!r) return;
const n = r.closest(v);
n && (t.preventDefault(), t.stopPropagation(), n.focus({ preventScroll: !0 }), Q(r));
}), document.addEventListener("keydown", (t) => {
if (t.key !== "Backspace" && t.key !== "Delete") return;
const e = window.getSelection();
if (!e || e.rangeCount === 0) return;
const r = e.getRangeAt(0), n = J();
if (!n || !n.contains(r.commonAncestorContainer)) return;
let i = ee(r);
i || (i = te(r, t.key)), i && (t.preventDefault(), t.stopPropagation(), Z(i, t.key));
}));
}
function re(t) {
return t ? !!t.closest(K) : !1;
}
function ne() {
k && (k(), k = null), w = null;
}
function W(t) {
const e = document.createRange();
return e.selectNodeContents(t), e.collapse(!1), e;
}
function ae(t, e) {
const r = window.getSelection(), n = e ? e.cloneRange() : W(t), o = n.startContainer.isConnected && n.endContainer.isConnected && t.contains(n.commonAncestorContainer) ? n : W(t);
return r && (r.removeAllRanges(), r.addRange(o)), o;
}
function oe(t) {
const e = document.createElement("span");
return e.className = "rte-merge-tag", e.setAttribute("contenteditable", "false"), e.setAttribute("data-key", t.key), e.setAttribute("data-category", t.category), e.setAttribute("data-label", t.label), e.setAttribute("aria-label", `Merge tag: ${t.label}`), e.textContent = `{{ ${t.label} }}`, e;
}
function ie(t, e, r) {
const n = window.getSelection();
if (!n) return !1;
t.focus({ preventScroll: !0 });
const i = ae(t, e), o = i.startContainer.nodeType === Node.ELEMENT_NODE ? i.startContainer : i.startContainer.parentElement, c = o == null ? void 0 : o.closest(".rte-merge-tag");
c && t.contains(c) && (i.setStartAfter(c), i.setEndAfter(c));
try {
i.deleteContents();
const g = oe(r), d = document.createTextNode(" "), u = document.createDocumentFragment();
u.appendChild(g), u.appendChild(d), i.insertNode(u);
const f = document.createRange();
return f.setStartAfter(d), f.collapse(!0), n.removeAllRanges(), n.addRange(f), t.dispatchEvent(new Event("input", { bubbles: !0 })), !0;
} catch (g) {
return console.error("Failed to insert merge tag:", g), !1;
}
}
function le(t, e) {
const r = Y[t], n = e.trim().toLowerCase();
return n ? r.filter((i) => i.searchIndex.includes(n)) : r;
}
function se(t) {
ne(), R();
const e = {
category: "USER",
searchTerm: "",
filteredTags: Y.USER,
selectedIndex: 0,
savedRange: (() => {
const a = window.getSelection();
if (!a || a.rangeCount === 0) return null;
const l = a.getRangeAt(0);
return t.contains(l.commonAncestorContainer) ? l.cloneRange() : null;
})(),
searchRaf: null
}, r = document.createElement("div");
r.className = "rte-merge-tag-overlay", r.setAttribute("role", "dialog"), r.setAttribute("aria-modal", "true"), re(t) && r.classList.add("rte-ui-theme-dark");
const n = document.createElement("div");
n.className = "rte-merge-tag-dialog";
const i = document.createElement("div");
i.className = "rte-merge-tag-header", i.innerHTML = `
<h2 style="margin:0; font-size:18px; font-weight:700;">Insert Merge Tag</h2>
<button class="rte-merge-tag-close" aria-label="Close" style="background:none;border:none;color:inherit;cursor:pointer;font-size:20px;">✕</button>
`;
const o = document.createElement("div");
o.className = "rte-merge-tag-body";
const c = document.createElement("input");
c.type = "text", c.className = "rte-merge-tag-input", c.placeholder = "Search merge tags...", c.setAttribute("aria-label", "Search merge tags");
const g = document.createElement("div");
g.className = "rte-merge-tag-tabs", A.forEach((a) => {
const l = document.createElement("button");
l.type = "button", l.className = "rte-merge-tag-tab", l.setAttribute("data-category", a), l.textContent = D[a].name, g.appendChild(l);
});
const d = document.createElement("div");
d.className = "rte-merge-tag-list";
const u = document.createElement("div");
u.className = "rte-merge-tag-preview", o.appendChild(c), o.appendChild(g), o.appendChild(d), o.appendChild(u);
const f = document.createElement("div");
f.className = "rte-merge-tag-footer";
const x = document.createElement("button");
x.type = "button", x.className = "rte-merge-tag-btn-secondary", x.textContent = "Cancel";
const p = document.createElement("button");
p.type = "button", p.className = "rte-merge-tag-btn-primary", p.textContent = "Insert", f.appendChild(x), f.appendChild(p), n.appendChild(i), n.appendChild(o), n.appendChild(f), r.appendChild(n), document.body.appendChild(r), w = r;
const I = () => {
g.querySelectorAll(".rte-merge-tag-tab").forEach((l) => {
const m = l.dataset.category === e.category;
l.classList.toggle("active", m);
});
}, N = () => {
if (e.filteredTags.length === 0) {
e.selectedIndex = -1;
return;
}
e.selectedIndex < 0 && (e.selectedIndex = 0), e.selectedIndex >= e.filteredTags.length && (e.selectedIndex = e.filteredTags.length - 1);
}, M = () => {
N();
const a = e.selectedIndex >= 0 ? e.filteredTags[e.selectedIndex] : null;
if (!a) {
u.style.display = "none", p.disabled = !0;
return;
}
u.style.display = "block", u.innerHTML = `<strong>Preview:</strong> {{ ${a.label} }}`, p.disabled = !1;
}, X = () => {
if (e.selectedIndex < 0) return;
const a = d.querySelector(`.rte-merge-tag-item[data-index="${e.selectedIndex}"]`);
a == null || a.scrollIntoView({ block: "nearest" });
}, h = () => {
if (e.filteredTags = le(e.category, e.searchTerm), e.filteredTags.length > 0 && e.selectedIndex < 0 && (e.selectedIndex = 0), N(), d.innerHTML = "", e.filteredTags.length === 0) {
const l = document.createElement("div");
l.className = "rte-merge-tag-empty", l.textContent = "No merge tags found", d.appendChild(l), M();
return;
}
const a = document.createDocumentFragment();
e.filteredTags.forEach((l, m) => {
const s = document.createElement("div");
s.className = "rte-merge-tag-item", s.setAttribute("data-index", String(m)), s.classList.toggle("selected", m === e.selectedIndex);
const S = document.createElement("div");
if (S.className = "rte-merge-tag-item-label", S.textContent = l.label, s.appendChild(S), l.preview) {
const L = document.createElement("div");
L.className = "rte-merge-tag-item-preview", L.textContent = l.preview, s.appendChild(L);
}
a.appendChild(s);
}), d.appendChild(a), M(), X();
}, O = () => {
e.searchRaf !== null && cancelAnimationFrame(e.searchRaf), e.searchRaf = requestAnimationFrame(() => {
e.searchRaf = null, e.searchTerm = c.value, e.selectedIndex = 0, h();
});
}, b = () => {
e.searchRaf !== null && (cancelAnimationFrame(e.searchRaf), e.searchRaf = null), r.remove(), w === r && (w = null, k = null);
}, T = () => {
if (N(), e.selectedIndex < 0) return;
const a = e.filteredTags[e.selectedIndex];
ie(t, e.savedRange, a) && b();
}, _ = (a) => {
const m = a.target.closest(".rte-merge-tag-tab");
if (!m) return;
const s = m.dataset.category;
!s || !A.includes(s) || (e.category = s, e.searchTerm = "", c.value = "", e.selectedIndex = 0, I(), h());
}, F = (a) => {
const m = a.target.closest(".rte-merge-tag-item");
if (!m) return;
const s = Number(m.dataset.index || "-1");
Number.isNaN(s) || s < 0 || s >= e.filteredTags.length || (e.selectedIndex = s, h());
}, U = (a) => {
const m = a.target.closest(".rte-merge-tag-item");
if (!m) return;
const s = Number(m.dataset.index || "-1");
Number.isNaN(s) || s < 0 || s >= e.filteredTags.length || (e.selectedIndex = s, T());
}, C = (a) => {
if (a.key === "Escape") {
a.preventDefault(), b();
return;
}
if (a.key === "ArrowDown") {
if (a.preventDefault(), e.filteredTags.length === 0) return;
e.selectedIndex = Math.min(e.filteredTags.length - 1, e.selectedIndex + 1), h();
return;
}
if (a.key === "ArrowUp") {
if (a.preventDefault(), e.filteredTags.length === 0) return;
e.selectedIndex = Math.max(0, e.selectedIndex - 1), h();
return;
}
a.key === "Enter" && (a.preventDefault(), T());
}, z = (a) => {
a.target === r && b();
}, y = i.querySelector(".rte-merge-tag-close");
g.addEventListener("click", _), d.addEventListener("click", F), d.addEventListener("dblclick", U), c.addEventListener("input", O), c.addEventListener("keydown", C), r.addEventListener("click", z), n.addEventListener("keydown", C), y == null || y.addEventListener("click", b), x.addEventListener("click", b), p.addEventListener("click", T), k = () => {
g.removeEventListener("click", _), d.removeEventListener("click", F), d.removeEventListener("dblclick", U), c.removeEventListener("input", O), c.removeEventListener("keydown", C), r.removeEventListener("click", z), n.removeEventListener("keydown", C), y == null || y.removeEventListener("click", b), x.removeEventListener("click", b), p.removeEventListener("click", T), e.searchRaf !== null && (cancelAnimationFrame(e.searchRaf), e.searchRaf = null), r.remove();
}, I(), h(), setTimeout(() => {
c.focus();
}, 0);
}
const ce = () => ({
name: "mergeTag",
init: () => {
R(), $(), q();
},
toolbar: [
{
label: "Merge Tag",
command: "insertMergeTag",
icon: "{{ }}"
}
],
commands: {
insertMergeTag: () => {
R(), $(), q();
const t = J();
return t ? (se(t), !0) : !1;
}
}
});
export {
ce as MergeTagPlugin
};
//# sourceMappingURL=MergeTagPlugin.native-DIGWhdnF.mjs.map
+2
-2
const r = {
codeSample: () => import("./CodeSamplePlugin.native-B-KS1pOl.mjs").then((e) => e.CodeSamplePlugin()),
codeSample: () => import("./CodeSamplePlugin.native-CgGoH-X4.mjs").then((e) => e.CodeSamplePlugin()),
checklist: () => import("./ChecklistPlugin.native-nuSSEFNI.mjs").then((e) => e.ChecklistPlugin()),

@@ -19,3 +19,3 @@ textAlignment: () => import("./TextAlignmentPlugin.native-sM_1s00t.mjs").then((e) => e.TextAlignmentPlugin()),

image: () => import("./MediaManagerPlugin.native-CgP5iInD.mjs").then((e) => e.MediaManagerPlugin()),
mergeTag: () => import("./MergeTagPlugin.native-CU9LtsfD.mjs").then((e) => e.MergeTagPlugin()),
mergeTag: () => import("./MergeTagPlugin.native-DIGWhdnF.mjs").then((e) => e.MergeTagPlugin()),
pageBreak: () => import("./PageBreakPlugin.native-CGiQxXqR.mjs").then((e) => e.PageBreakPlugin()),

@@ -22,0 +22,0 @@ print: () => import("./PrintPlugin.native-7qt5v7L5.mjs").then((e) => e.PrintPlugin()),

@@ -1,1 +0,1 @@

.editora-editor{display:flex;flex-direction:column;border:1px solid #ddd;border-radius:4px;background:#fff;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,sans-serif;font-size:14px;overflow:hidden}.editora-editor *{box-sizing:border-box}.editora-theme-light{background:#fff;color:#333}.editora-theme-dark{--editora-dark-toolbar-bg-start: #353d48;--editora-dark-toolbar-bg-end: #2d3540;--editora-dark-button-bg-start: #46505f;--editora-dark-button-bg-end: #3b4553;--editora-dark-button-hover-start: #525d6d;--editora-dark-button-hover-end: #465262;--editora-dark-button-active-start: #5eaaf6;--editora-dark-button-active-end: #4a95de;--editora-dark-border: #475263;--editora-dark-border-strong: #566275;--editora-dark-text: #e1e9f5;--editora-dark-text-strong: #f3f7ff;--editora-dark-text-muted: #aeb9cc;--editora-dark-surface: #1d242d;--editora-dark-content: #1f2732;background:linear-gradient(180deg,#1b2330,#1c2430);color:var(--editora-dark-text);border-color:var(--editora-dark-border)}.editora-toolbar{display:flex;align-items:center;gap:4px;padding:8px;background:#f5f5f5;border-bottom:1px solid #ddd;flex-wrap:wrap}.editora-theme-dark .editora-toolbar{background:linear-gradient(180deg,var(--editora-dark-toolbar-bg-start) 0%,var(--editora-dark-toolbar-bg-end) 100%);border-bottom-color:var(--editora-dark-border);box-shadow:inset 0 1px #ffffff0d}.editora-toolbar-sticky{position:sticky;top:0;z-index:100;position:-webkit-sticky}.editora-toolbar-group{display:flex;align-items:center;gap:2px}.editora-toolbar-button{padding:6px 12px;border:1px solid #ccc;background:#fff;cursor:pointer;border-radius:3px;font-weight:600;font-size:14px;height:30px;display:flex;align-items:center;white-space:nowrap}.editora-toolbar-group-button{display:flex;align-items:center}.editora-toolbar-input.font-size{width:40px;padding:.25rem;text-align:center;font-size:14px;background:#fff;border:1px solid var(--rte-color-border-light);border-radius:var(--rte-radius-sm)}.editora-toolbar-group-items{display:flex;align-items:center;border:1px solid #ccc;.editora-toolbar-button{border:none;border-radius:0;&:first-child{border-right:1px solid #ccc;border-top-left-radius:3px;border-bottom-left-radius:3px}&:last-child{border-left:1px solid #ccc;border-top-right-radius:3px;border-bottom-right-radius:3px}}}.editora-theme-dark .editora-toolbar-button{background:linear-gradient(180deg,var(--editora-dark-button-bg-start) 0%,var(--editora-dark-button-bg-end) 100%);border-color:var(--editora-dark-border-strong);color:var(--editora-dark-text);box-shadow:inset 0 1px #ffffff14,0 1px 1px #00000059}.editora-theme-dark .editora-toolbar-group-items{border-color:var(--editora-dark-border-strong);background:linear-gradient(180deg,var(--editora-dark-button-bg-start) 0%,var(--editora-dark-button-bg-end) 100%)}.editora-theme-dark .editora-toolbar-group-items .editora-toolbar-button:first-child{border-right-color:#566275}.editora-theme-dark .editora-toolbar-group-items .editora-toolbar-button:last-child{border-left-color:#566275}.editora-theme-dark .editora-toolbar-input.font-size{background-color:#2e3642;color:var(--editora-dark-text-strong);border-color:var(--editora-dark-border-strong);caret-color:var(--editora-dark-text-strong)}.editora-theme-dark .editora-toolbar-input.font-size::placeholder{color:var(--editora-dark-text-strong);opacity:1}.editora-toolbar-button:hover{background:#e0e0e0;border-color:#ccc}.editora-theme-dark .editora-toolbar-button:hover{background:linear-gradient(180deg,var(--editora-dark-button-hover-start) 0%,var(--editora-dark-button-hover-end) 100%);border-color:#66748a;color:var(--editora-dark-text-strong)}.editora-toolbar-button:active,.editora-toolbar-button.active{background:#d0d0d0;border-color:#999}.editora-theme-dark .editora-toolbar-button:active,.editora-theme-dark .editora-toolbar-button.active{background:linear-gradient(180deg,var(--editora-dark-button-active-start) 0%,var(--editora-dark-button-active-end) 100%);border-color:#67adf4;color:#0f1b2a}.editora-theme-dark .editora-toolbar-button:disabled{background:#313946;border-color:#424d5e;color:#7f8ca1}.editora-theme-dark .editora-toolbar-button[data-command=insertTable],.editora-theme-dark .editora-toolbar-button[data-command=print],.editora-theme-dark .editora-toolbar-button[data-command=toggleSpellCheck],.editora-theme-dark .editora-toolbar-button[data-command=toggleA11yChecker],.editora-theme-dark .editora-toolbar-button[data-command=setDirectionLTR],.editora-theme-dark .editora-toolbar-button[data-command=setDirectionRTL]{color:#f1f6ff}.editora-toolbar-button:disabled{opacity:.5;cursor:not-allowed}.editora-toolbar-icon{display:inline-flex;align-items:center;justify-content:center;width:24px;height:24px;line-height:1}.editora-toolbar-button svg,.editora-toolbar-icon svg{width:20px;height:20px;display:block;color:currentColor;fill:currentColor}.editora-theme-dark .editora-toolbar-icon,.editora-theme-dark .editora-toolbar-icon *{color:inherit}.editora-theme-dark :is(.editora-toolbar-button,.editora-toolbar-icon) svg :is([stroke="#000" i],[stroke="#000000" i],[stroke=black i],[stroke="#0f0f0f" i],[stroke="#111111" i],[style*="stroke:#000" i],[style*="stroke: #000" i],[style*="stroke:black" i],[style*="stroke: black" i],[style*="stroke:#0f0f0f" i],[style*="stroke: #0f0f0f" i]){stroke:currentColor!important}.editora-theme-dark :is(.editora-toolbar-button,.editora-toolbar-icon) svg :is([fill="#000" i],[fill="#000000" i],[fill=black i],[fill="#0f0f0f" i],[fill="#111111" i],[style*="fill:#000" i],[style*="fill: #000" i],[style*="fill:black" i],[style*="fill: black" i],[style*="fill:#0f0f0f" i],[style*="fill: #0f0f0f" i]){fill:currentColor!important}.editora-toolbar-separator{width:1px;height:24px;background:#ddd;margin:0 4px}.editora-theme-dark .editora-toolbar-separator{background:#4d596b}.editora-toolbar-dropdown{position:relative}.editora-toolbar-dropdown-menu{position:absolute;top:100%;left:0;min-width:150px;margin-top:4px;padding:4px 0;background:#fff;border:1px solid #ddd;border-radius:4px;box-shadow:0 2px 8px #00000026;z-index:1000}.editora-theme-dark .editora-toolbar-dropdown-menu{background:#29323d;border-color:#4d596b;box-shadow:0 8px 20px #00000073}.editora-toolbar-dropdown-item{display:block;width:100%;padding:8px 12px;border:none;background:transparent;color:#333;text-align:left;cursor:pointer;font-size:13px;transition:background .15s ease}.editora-theme-dark .editora-toolbar-dropdown-item{color:#d7deea}.editora-toolbar-dropdown-item:hover{background:#f5f5f5}.editora-theme-dark .editora-toolbar-dropdown-item:hover{background:#3a4554;color:#f0f6ff}.editora-content{flex:1;min-height:200px;padding:16px;outline:none;overflow-y:auto;line-height:1.6}.editora-theme-dark .editora-content{color:#ecf3ff;background:linear-gradient(180deg,var(--editora-dark-content) 0%,#1c232e 100%)}.editora-content:empty:before{content:attr(data-placeholder);color:#999;pointer-events:none}.editora-theme-dark .editora-content:empty:before{color:#8f9bb0}.editora-content h1{font-size:2em;margin:.67em 0;font-weight:600}.editora-content h2{font-size:1.5em;margin:.75em 0;font-weight:600}.editora-content h3{font-size:1.17em;margin:.83em 0;font-weight:600}.editora-content p{margin:1em 0}.editora-content ul,.editora-content ol{margin:1em 0;padding-left:2em}.editora-content a{color:#06c;text-decoration:underline}.editora-theme-dark .editora-content a{color:#4db8ff}.editora-content code{padding:2px 4px;background:#f5f5f5;border-radius:3px;font-family:Monaco,Menlo,Consolas,monospace;font-size:.9em}.editora-theme-dark .editora-content code{background:#1e1e1e}.editora-content pre{padding:12px;background:#f5f5f5;border-radius:4px;overflow-x:auto;margin:1em 0}.editora-theme-dark .editora-content pre{background:#1e1e1e}.editora-theme-dark .rte-code-block{background:linear-gradient(180deg,#212a36,#1b2430)!important;border-color:#4f5b70!important;color:#e7effc!important}.editora-theme-dark .rte-code-block code{color:#e7effc!important}.editora-theme-dark .rte-code-block:before{background:#111927!important;color:#dce8ff!important}.editora-theme-dark .rte-code-block .rte-code-copy{background:#2b3441!important;border-color:#5a667b!important;color:#dce8ff!important}.editora-content blockquote{margin:1em 0;padding-left:1em;border-left:4px solid #ddd;color:#666}.editora-theme-dark .editora-content blockquote{border-left-color:#3c3c3c;color:#9a9a9a}.editora-floating-toolbar{position:absolute;padding:4px;background:#fff;border:1px solid #ddd;border-radius:4px;box-shadow:0 2px 8px #00000026;z-index:1000}.editora-theme-dark .editora-floating-toolbar{background:#29323d;border-color:#4d596b;box-shadow:0 8px 20px #00000073}.editora-theme-dark .editora-statusbar{background:linear-gradient(180deg,#2c3440,#252d37);border-top-color:#3f4a5b;color:#d7deea}.editora-statusbar-item{white-space:nowrap}.editora-theme-dark .editora-statusbar-separator{color:#566275}.editora-editor[readonly] .editora-content{background:#fafafa;cursor:not-allowed}.editora-theme-dark.editora-editor[readonly] .editora-content{background:#1a1a1a}.editora-editor:focus-within{border-color:#06c;box-shadow:0 0 0 3px #0066cc1a}.editora-theme-dark.editora-editor:focus-within{border-color:#4db8ff;box-shadow:0 0 0 3px #4db8ff1a}.editora-editor[disabled]{opacity:.6;pointer-events:none}@media(max-width:768px){.editora-toolbar{padding:4px}.editora-toolbar-button{min-width:28px;min-height:28px;padding:4px 8px;font-size:12px}.editora-content{padding:12px}}.editora-content ::selection{background:#06c3}.editora-theme-dark .editora-content ::selection{background:#4db8ff33}.editora-content table{border-collapse:collapse;width:100%;margin:1em 0}.editora-content th,.editora-content td{border:1px solid #ddd;padding:8px 12px;text-align:left}.editora-theme-dark .editora-content th,.editora-theme-dark .editora-content td{border-color:#3c3c3c}.editora-content th{background:#f5f5f5;font-weight:600}.editora-theme-dark .editora-content th{background:#252526}.editora-content img{max-width:100%;height:auto;border-radius:4px;display:block}.editora-content video{max-width:100%;height:auto;border-radius:4px;display:block}.editora-editor.loading{opacity:.7;pointer-events:none}.editora-editor.loading:after{content:"";position:absolute;top:50%;left:50%;width:24px;height:24px;margin:-12px 0 0 -12px;border:3px solid #ddd;border-top-color:#06c;border-radius:50%;animation:editora-spin .8s linear infinite}@keyframes editora-spin{to{transform:rotate(360deg)}}.toolbar-container-wrapper{display:flex;align-items:center;background:#fff;border-bottom:1px solid #e0e0e0;padding:0;margin:0;width:100%;box-sizing:border-box;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,sans-serif;font-size:14px;line-height:1.5;position:relative}.toolbar-container-wrapper[data-toolbar-sticky=true]{position:sticky;top:0;z-index:999;box-shadow:0 2px 4px #0000001a}.toolbar-container-wrapper[data-toolbar-floating=true]{position:fixed;top:0;left:0;right:0;z-index:1000;box-shadow:0 4px 12px #00000026}.toolbar-container-wrapper[data-toolbar-position=bottom]{border-bottom:none;border-top:1px solid #e0e0e0}.toolbar-container-wrapper .toolbar-wrapper{display:flex;width:100%;padding:8px;gap:4px;flex-wrap:wrap;align-items:center}.toolbar-container-wrapper .toolbar{display:flex;width:100%;gap:4px;flex-wrap:wrap;align-items:center}.toolbar-container-wrapper .toolbar-container{display:flex;gap:4px;flex-wrap:wrap;align-items:center;flex:1;position:relative}.toolbar-container-wrapper .toolbar-item{display:flex;align-items:center;gap:2px}.toolbar-container-wrapper .toolbar-button{padding:6px 10px;border:1px solid #d1d5db;background:#fff;border-radius:4px;cursor:pointer;font-size:13px;display:flex;align-items:center;justify-content:center;gap:4px;transition:all .15s ease;min-height:32px;white-space:nowrap}.toolbar-container-wrapper .toolbar-button:hover{background-color:#f3f4f6;border-color:#9ca3af}.toolbar-container-wrapper .toolbar-button:active,.toolbar-container-wrapper .toolbar-button[data-active=true]{background-color:#06c;color:#fff;border-color:#0052a3;box-shadow:inset 0 1px 3px #0000001a}.toolbar-container-wrapper .toolbar-button:disabled{opacity:.5;cursor:not-allowed;background-color:#f9fafb}.toolbar-container-wrapper .toolbar-more-button{padding:6px 8px;font-size:16px;font-weight:500;line-height:1}.toolbar-container-wrapper .toolbar-separator{width:1px;height:24px;background-color:#d1d5db;margin:0 4px}.toolbar-container-wrapper .toolbar-icon{display:inline-flex;align-items:center;justify-content:center;width:18px;height:18px;flex-shrink:0}.toolbar-container-wrapper .toolbar-icon svg{width:100%;height:100%}.toolbar-container-wrapper .toolbar-dropdown{position:relative;display:flex;align-items:center}.toolbar-container-wrapper .toolbar-dropdown-arrow{font-size:10px;margin-left:2px;line-height:1}.toolbar-container-wrapper .toolbar-dropdown-menu{position:absolute;top:100%;left:0;background:#fff;border:1px solid #d1d5db;border-radius:6px;box-shadow:0 4px 12px #00000026;z-index:1000;min-width:160px;padding:4px 0;margin-top:4px;display:none}.toolbar-container-wrapper .toolbar-dropdown-menu.show{display:block}.toolbar-container-wrapper .toolbar-dropdown-item{display:block;width:100%;padding:8px 12px;border:none;background:transparent;text-align:left;cursor:pointer;font-size:13px;color:#1f2937;transition:background-color .15s ease;font-family:inherit}.toolbar-container-wrapper .toolbar-dropdown-item:hover{background-color:#f3f4f6}.toolbar-container-wrapper .toolbar-dropdown-item:active{background-color:#e5e7eb}.toolbar-container-wrapper .toolbar-input{padding:6px 8px;border:1px solid #d1d5db;border-radius:4px;font-size:13px;font-family:inherit;background-color:#fff;color:#1f2937;transition:all .15s ease}.toolbar-container-wrapper .toolbar-input:focus{outline:none;border-color:#06c;box-shadow:0 0 0 3px #0066cc1a;background-color:#fff}.toolbar-container-wrapper .toolbar-input::placeholder{color:#9ca3af}.toolbar-overflow-menu{animation:slideDown .2s ease-out}@keyframes slideDown{0%{opacity:0;transform:translateY(-8px)}to{opacity:1;transform:translateY(0)}}.toolbar-overflow-item{transition:background-color .15s ease}.floating-toolbar{user-select:none;-webkit-user-select:none;font-family:system-ui,-apple-system,sans-serif;font-size:14px;animation:fadeInUp .15s ease-out}@keyframes fadeInUp{0%{opacity:0;transform:translate(-50%) translateY(10px)}to{opacity:1;transform:translate(-50%) translateY(0)}}.floating-toolbar-btn{display:flex;align-items:center;justify-content:center;width:32px;height:32px;border:none;background:transparent;border-radius:4px;color:#495057;cursor:pointer;font-size:14px;font-weight:500;transition:all .15s ease;outline:none}.floating-toolbar-btn:hover{background:#f8f9fa;color:#212529}.floating-toolbar-btn:active{background:#e9ecef;transform:scale(.95)}.floating-toolbar-btn.floating-toolbar-toggle{color:#dc3545;font-weight:700}.floating-toolbar-btn.floating-toolbar-toggle:hover{background:#f8d7da;color:#721c24}.floating-toolbar-separator{width:1px;height:20px;background:#e1e5e9;margin:0 2px}@media(max-width:768px){.toolbar-container-wrapper .toolbar-button{padding:5px 8px;font-size:12px;min-height:28px}.toolbar-container-wrapper .toolbar-icon{width:16px;height:16px}.toolbar-container-wrapper .toolbar-dropdown-menu{min-width:140px}.toolbar-container-wrapper .toolbar-dropdown-item{padding:6px 10px;font-size:12px}.floating-toolbar{padding:4px;gap:2px}.floating-toolbar-btn{width:28px;height:28px;font-size:12px}}@media(max-width:480px){.toolbar-container-wrapper{padding:4px}.toolbar-container-wrapper .toolbar-wrapper{padding:4px;gap:2px}.toolbar-container-wrapper .toolbar-button{padding:4px 6px;font-size:11px;min-height:24px}.toolbar-container-wrapper .toolbar-icon{width:14px;height:14px}}.floating-toolbar{pointer-events:auto}.floating-toolbar{max-width:calc(100vw - 20px);overflow-x:auto}@media(prefers-color-scheme:dark){.floating-toolbar{background:#2d3748;border-color:#4a5568;color:#e2e8f0}.floating-toolbar-btn:hover{background:#4a5568;color:#f7fafc}.floating-toolbar-btn:active{background:#718096}.floating-toolbar-separator{background:#4a5568}}.rte-editor{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,sans-serif}.rte-toolbar-wrapper{border-radius:4px 4px 0 0}.rte-toolbar{display:flex;gap:4px;padding:8px;background:#f5f5f5;border:1px solid #ddd;border-bottom:none;border-radius:4px 4px 0 0;align-items:center;position:relative}.rte-toolbar-items-container{display:flex;gap:4px;flex-wrap:nowrap;align-items:center;flex:1}.rte-toolbar-item{position:relative;display:flex;align-items:center;white-space:nowrap}.rte-toolbar-group-items.font-size{display:flex;align-items:center;border:1px solid #ccc;.rte-toolbar-input.font-size{width:40px;padding:.25rem;text-align:center;font-size:14px;background:#fff;border:1px solid var(--rte-color-border-light);border-radius:var(--rte-radius-sm)}.rte-toolbar-button{border:none;border-radius:0}.rte-toolbar-item{&:first-child{border-right:1px solid #ccc;border-top-left-radius:3px;border-bottom-left-radius:3px}&:last-child{border-left:1px solid #ccc;border-top-right-radius:3px;border-bottom-right-radius:3px}}}.rte-toolbar-button{padding:6px 12px;border:1px solid #ccc;background:#fff;cursor:pointer;border-radius:3px;font-weight:600;font-size:14px;height:30px;display:flex;align-items:center;white-space:nowrap}.rte-toolbar-button:hover{background:#e9e9e9}.rte-toolbar-input{width:26px;padding:6px 8px;border:1px solid #ccc;border-radius:3px;font-size:14px;text-align:center}.rte-toolbar-dropdown{position:relative}.rte-toolbar-dropdown-menu{position:absolute;top:100%;left:0;background:#fff;border:1px solid #ccc;border-radius:3px;box-shadow:0 2px 8px #00000026;min-width:150px;z-index:1000;margin-top:2px}.rte-toolbar-dropdown-item{padding:8px 12px;cursor:pointer}.rte-toolbar-dropdown-item:hover{background:#f0f0f0}.rte-toolbar-more-button{padding:6px 10px;border:1px solid #ccc;background:#fff;cursor:pointer;border-radius:3px;font-weight:600;font-size:16px;height:30px;display:flex;align-items:center;justify-content:center;min-width:30px;transition:background-color .2s ease;margin-left:auto}.rte-toolbar-more-button:hover{background:#e9e9e9}.rte-toolbar-more-button.active{background:#ddd;border-color:#999}.rte-toolbar-expanded-row{display:flex;transform:scaleY(0);transform-origin:top;max-height:0;padding:0;overflow:hidden;opacity:0;transition:transform .25s ease,opacity .2s ease,max-height .25s ease}.rte-toolbar-expanded-row.show{transform:scaleY(1);max-height:200px;padding:1px 8px 8px;opacity:1;background:#f5f5f5;border:1px solid #ddd;border-top:none;gap:4px}.rte-content{font-size:16px;line-height:1.6}.rte-content.rte-content-empty:before,.rte-content:empty:before{content:attr(data-placeholder);color:var(--rte-color-text-muted, #6b7280);pointer-events:none}.rte-content p{margin:0 0 1em}.rte-content h1{font-size:2em;margin:.67em 0}.rte-content h2{font-size:1.5em;margin:.75em 0}.rte-content h3{font-size:1.17em;margin:.83em 0}.rte-content h4{font-size:1em;margin:1em 0}.rte-content h5{font-size:.83em;margin:1.17em 0}.rte-content h6{font-size:.67em;margin:1.33em 0}.rte-content ul,.rte-content ol{margin:1em 0;padding-left:2em}.rte-content code{background:#f4f4f4;padding:2px 6px;border-radius:3px;font-family:Courier New,monospace;font-size:.9em}.rte-content blockquote{border-left:4px solid #ddd;margin:1em 0;padding-left:1em;color:#666}.rte-content a{color:#06c;text-decoration:underline}.rte-content a:hover{color:#0052a3}.rte-dialog-overlay{position:fixed;inset:0;background:#00000080;display:flex;align-items:center;justify-content:center;z-index:10000}.rte-dialog-content{background:#fff;border-radius:8px;box-shadow:0 4px 20px #0000004d;max-width:400px;width:90%;max-height:90vh;overflow-y:auto}.rte-dialog-header{padding:16px 20px;border-bottom:1px solid #e0e0e0;display:flex;justify-content:space-between;align-items:center}.rte-dialog-header h3{margin:0;font-size:18px;font-weight:600;color:#333}.rte-dialog-close{background:none;border:none;font-size:24px;cursor:pointer;color:#666;padding:0;width:30px;height:30px;display:flex;align-items:center;justify-content:center}.rte-dialog-close:hover{color:#333}.rte-dialog-body{padding:20px}.rte-dialog-footer{padding:16px 20px;border-top:1px solid #e0e0e0;display:flex;justify-content:flex-end;gap:12px}.rte-btn{padding:8px 16px;border:1px solid #ccc;border-radius:4px;cursor:pointer;font-size:14px;font-weight:500;transition:all .2s}.rte-btn:hover{border-color:#999}.rte-btn-primary{background:#06c;color:#fff;border-color:#06c}.rte-btn-primary:hover{background:#0052a3;border-color:#0052a3}.rte-btn-secondary{background:#fff;color:#333}.rte-btn-secondary:hover{background:#f5f5f5}.rte-form-group{margin-bottom:16px}.rte-form-label{display:block;margin-bottom:6px;font-weight:500;color:#333;font-size:14px}.rte-form-input{width:100%;padding:8px 12px;border:1px solid #ccc;border-radius:4px;font-size:14px;box-sizing:border-box}.rte-form-input:focus{outline:none;border-color:#06c;box-shadow:0 0 0 2px #06c3}.rte-form-row{display:flex;gap:12px}.rte-form-row .rte-form-group{flex:1}.rte-color-preview{display:flex;align-items:center;gap:12px;margin-bottom:20px;padding:12px;background:#f8f9fa;border-radius:4px}.rte-color-sample{width:40px;height:40px;border-radius:4px;border:2px solid #ddd}.rte-color-value{font-family:monospace;font-size:14px;font-weight:500;color:#333}.rte-color-section{margin-bottom:20px}.rte-color-label{margin-bottom:8px;font-size:14px;font-weight:500}.rte-color-palette{display:grid;grid-template-columns:repeat(6,1fr);gap:8px;margin-bottom:16px}.rte-color-swatch{width:24px;height:24px;border:2px solid #ddd;border-radius:4px;cursor:pointer;transition:all .2s}.rte-color-swatch:hover{border-color:#999;transform:scale(1.1)}.rte-color-swatch.selected{border-color:#06c;box-shadow:0 0 0 2px #0066cc4d}.rte-custom-color{display:flex;align-items:center;gap:12px}.rte-color-input{width:60px;height:40px;border:2px solid #ddd;border-radius:4px;cursor:pointer}.rte-color-text-input{flex:1;padding:8px 12px;border:1px solid #ccc;border-radius:4px;font-family:monospace;font-size:14px}.rte-color-text-input:focus{outline:none;border-color:#06c;box-shadow:0 0 0 2px #06c3}.rte-iframe-preview{border:1px solid #ddd;border-radius:4px;overflow:hidden;background:#f8f9fa}.rte-iframe-preview iframe{display:block;border:none}.rte-size-presets{display:flex;flex-direction:column;gap:8px}.rte-radio-option{display:flex;align-items:flex-start;gap:8px;padding:8px;border:1px solid #e0e0e0;border-radius:4px;background:#fafbfc}.rte-radio-option:hover{background:#f1f3f4}.rte-radio-option input[type=radio]{margin-top:2px}.rte-radio-label{flex:1;line-height:1.4}.rte-content ul[data-type=checklist]{list-style:none;padding-left:0;margin:1em 0}.rte-content li[data-type=checklist-item]{position:relative;padding-left:2em;margin-bottom:.5em;line-height:1.6}.rte-content li[data-type=checklist-item]:before{content:"";position:absolute;left:0;top:.1em;width:1.2em;height:1.2em;border:2px solid #ccc;border-radius:3px;background:#fff;cursor:pointer;transition:all .2s ease}.rte-content li[data-type=checklist-item]:hover:before{border-color:#999}.rte-content li[data-type=checklist-item][data-checked=true]:before{background:#06c;border-color:#06c}.rte-content li[data-type=checklist-item][data-checked=true]:after{content:"✓";position:absolute;left:.36em;top:.12em;color:#fff;font-size:.9em;font-weight:700;pointer-events:none}.rte-content li[data-type=checklist-item][data-checked=true] p{text-decoration:line-through;color:#666}.editora-statusbar-container{display:flex;flex-direction:column}.rte-editor{.editora-statusbar-bottom{top:-32px}}.editora-statusbar-bottom{position:relative;border-left:1px solid rgb(221,221,221);border-right:1px solid rgb(221,221,221)}.editora-statusbar{display:flex;align-items:center;gap:12px;padding:6px 12px;background:#f5f5f5;border-top:1px solid #ddd;font-size:12px;color:#666}.editora-theme-dark .editora-statusbar{background:#252526;border-top-color:#3c3c3c;color:#9a9a9a}.editora-statusbar-top{border-top:none;border-bottom:1px solid #e0e0e0}.editora-statusbar-left{display:flex;align-items:center;gap:8px}.editora-statusbar-right{display:flex;align-items:center;gap:8px;margin-left:auto}.editora-statusbar-item{white-space:nowrap;padding:2px 4px}.editora-statusbar-separator{color:#ddd}.editora-theme-dark .editora-statusbar-separator{color:#3c3c3c}.editora-theme-dark .rte-content,.editora-theme-dark .rte-content h1,.editora-theme-dark .rte-content h2,.editora-theme-dark .rte-content h3,.editora-theme-dark .rte-content h4,.editora-theme-dark .rte-content h5,.editora-theme-dark .rte-content h6{color:#fff}.rte-inline-menu{position:fixed;z-index:1000;background:#fff;border:1px solid #ccc;border-radius:4px;box-shadow:0 2px 8px #00000026;min-width:120px;max-width:200px;pointer-events:auto}.rte-inline-menu-item{padding:8px 12px;cursor:pointer;font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;background-color:transparent}.rte-inline-menu-item:hover{background-color:#f5f5f5}.floating-toolbar{--rte-floating-toolbar-bg: #ffffff;--rte-floating-toolbar-border: #d7dee8;--rte-floating-toolbar-text: #364152;--rte-floating-toolbar-hover-bg: #f2f6fb;--rte-floating-toolbar-hover-text: #101828;--rte-floating-toolbar-active-bg: #e7eef7;--rte-floating-toolbar-separator: #d8e1ec;--rte-floating-toolbar-shadow: 0 10px 28px rgba(15, 23, 36, .16);user-select:none;-webkit-user-select:none;align-items:center;gap:4px;padding:6px;border-radius:8px;border:1px solid var(--rte-floating-toolbar-border);background:var(--rte-floating-toolbar-bg);color:var(--rte-floating-toolbar-text);box-shadow:var(--rte-floating-toolbar-shadow);pointer-events:auto;animation:rteFloatingToolbarIn .15s ease-out}.floating-toolbar-btn{display:inline-flex;align-items:center;justify-content:center;min-width:32px;height:32px;border:none;border-radius:6px;background:transparent;color:inherit;cursor:pointer;font-size:14px;font-weight:600;transition:background-color .15s ease,color .15s ease,transform .12s ease}.floating-toolbar-btn:hover{background:var(--rte-floating-toolbar-hover-bg);color:var(--rte-floating-toolbar-hover-text)}.floating-toolbar-btn:active{background:var(--rte-floating-toolbar-active-bg);transform:scale(.96)}.floating-toolbar-separator{width:1px;height:20px;margin:0 2px;background:var(--rte-floating-toolbar-separator)}@keyframes rteFloatingToolbarIn{0%{opacity:0;transform:translate(-50%) translateY(8px)}to{opacity:1;transform:translate(-50%) translateY(0)}}.editora-toolbar-group-button{display:flex;align-items:center;border-radius:var(--rte-radius);overflow:hidden;border:1px solid var(--rte-color-border-light);background:var(--rte-color-bg-secondary, #f9fafb);margin-right:.5rem;padding:0}.editora-toolbar-group-items{display:flex;align-items:center;gap:0}.editora-toolbar-group-button .editora-toolbar-button,.editora-toolbar-group-button .editora-toolbar-input{border-radius:0;border:none;margin:0;background:transparent;box-shadow:none}.editora-toolbar-group-button .editora-toolbar-button:first-child{border-radius:var(--rte-radius) 0 0 var(--rte-radius)}.editora-toolbar-group-button .editora-toolbar-button:last-child{border-radius:0 var(--rte-radius) var(--rte-radius) 0}.editora-toolbar-group-button .editora-toolbar-input{min-width:44px;width:44px;text-align:center;font-size:15px;background:#fff;border-left:1px solid var(--rte-color-border-light);border-right:1px solid var(--rte-color-border-light)}.editora-toolbar-group-button .editora-toolbar-button:active,.editora-toolbar-group-button .editora-toolbar-button:focus{background:#e5e7eb}.editora-toolbar-group-button .editora-toolbar-input:focus{outline:1.5px solid var(--rte-color-primary, #2563eb)}:root{--rte-color-primary: #007bff;--rte-color-primary-hover: #0056b3;--rte-color-secondary: #6c757d;--rte-color-success: #28a745;--rte-color-danger: #dc3545;--rte-color-warning: #ffc107;--rte-color-info: #17a2b8;--rte-color-text-primary: #212529;--rte-color-text-secondary: #6c757d;--rte-color-text-muted: #868e96;--rte-color-text-inverse: #ffffff;--rte-color-bg-primary: #ffffff;--rte-color-bg-secondary: #f8f9fa;--rte-color-bg-tertiary: #e9ecef;--rte-color-bg-hover: #f8f9fa;--rte-color-bg-active: #e9ecef;--rte-color-border: #dee2e6;--rte-color-border-light: #f8f9fa;--rte-color-border-focus: #007bff;--rte-shadow-sm: 0 1px 2px rgba(0, 0, 0, .05);--rte-shadow: 0 1px 3px rgba(0, 0, 0, .1), 0 1px 2px rgba(0, 0, 0, .06);--rte-shadow-lg: 0 10px 15px rgba(0, 0, 0, .1), 0 4px 6px rgba(0, 0, 0, .05);--rte-space-xs: .25rem;--rte-space-sm: .5rem;--rte-space-md: 1rem;--rte-space-lg: 1.5rem;--rte-space-xl: 2rem;--rte-space-xxl: 3rem;--rte-font-family-base: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;--rte-font-family-mono: "SFMono-Regular", Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;--rte-font-size-xs: .75rem;--rte-font-size-sm: .875rem;--rte-font-size-base: 1rem;--rte-font-size-lg: 1.125rem;--rte-font-size-xl: 1.25rem;--rte-font-size-xxl: 1.5rem;--rte-font-size-xxxl: 2rem;--rte-font-weight-normal: 400;--rte-font-weight-medium: 500;--rte-font-weight-semibold: 600;--rte-font-weight-bold: 700;--rte-line-height-tight: 1.25;--rte-line-height-normal: 1.5;--rte-line-height-relaxed: 1.75;--rte-radius-sm: .125rem;--rte-radius: .25rem;--rte-radius-md: .375rem;--rte-radius-lg: .5rem;--rte-radius-xl: .75rem;--rte-transition-fast: .15s ease-in-out;--rte-transition-normal: .25s ease-in-out;--rte-transition-slow: .35s ease-in-out;--rte-z-dropdown: 1000;--rte-z-sticky: 1020;--rte-z-modal: 1050;--rte-z-popover: 1060;--rte-z-tooltip: 1070}.rte-editor{font-family:var(--rte-font-family-base);font-size:var(--rte-font-size-base);line-height:var(--rte-line-height-normal);color:var(--rte-color-text-primary);background-color:var(--rte-color-bg-primary);border:1px solid var(--rte-color-border);border-radius:var(--rte-radius);box-shadow:var(--rte-shadow);transition:border-color var(--rte-transition-fast),box-shadow var(--rte-transition-fast)}.rte-editor:focus-within{border-color:var(--rte-color-border-focus);box-shadow:var(--rte-shadow),0 0 0 3px #007bff1a}.rte-toolbar{display:flex;align-items:center;padding:var(--rte-space-sm);border-bottom:1px solid var(--rte-color-border);background-color:var(--rte-color-bg-secondary);border-radius:var(--rte-radius) var(--rte-radius) 0 0;flex-wrap:wrap;gap:2px}.rte-toolbar-group{display:flex;align-items:center;border-radius:var(--rte-radius);overflow:hidden;border:1px solid var(--rte-color-border-light)}.rte-toolbar-button{display:flex;align-items:center;justify-content:center;width:2rem;height:2rem;padding:0;border:none;background:transparent;color:var(--rte-color-text-secondary);cursor:pointer;border-radius:var(--rte-radius-sm);transition:background-color var(--rte-transition-fast),color var(--rte-transition-fast);font-size:14px;line-height:1}.rte-toolbar-button svg,.editora-toolbar-button svg,.editora-toolbar-icon svg{flex-shrink:0;width:20px;height:20px;display:block;color:currentColor;fill:currentColor}.rte-toolbar-button:hover svg{opacity:.9}:is(.rte-toolbar-button[data-active=true],.editora-toolbar-button.active) svg{color:var(--rte-color-text-inverse)}.rte-toolbar-button:hover{background-color:var(--rte-color-bg-hover);color:var(--rte-color-text-primary)}.rte-toolbar-button:active,.rte-toolbar-button[data-active=true]{background-color:var(--rte-color-primary);color:var(--rte-color-text-inverse)}.rte-toolbar-button:disabled{opacity:.5;cursor:not-allowed}.rte-content{padding:var(--rte-space-md);min-height:200px;outline:none;overflow-wrap:break-word;word-wrap:break-word}.rte-content[contenteditable=true]{cursor:text}.rte-content h1,.rte-content h2,.rte-content h3,.rte-content h4,.rte-content h5,.rte-content h6{margin:var(--rte-space-lg) 0 var(--rte-space-md) 0;font-weight:var(--rte-font-weight-semibold);line-height:var(--rte-line-height-tight);color:var(--rte-color-text-primary)}.rte-content h1{font-size:var(--rte-font-size-xxxl)}.rte-content h2{font-size:var(--rte-font-size-xxl)}.rte-content h3{font-size:var(--rte-font-size-xl)}.rte-content h4{font-size:var(--rte-font-size-lg)}.rte-content h5{font-size:var(--rte-font-size-base)}.rte-content h6{font-size:var(--rte-font-size-sm)}.rte-content p{margin:var(--rte-space-md) 0}.rte-content blockquote{margin:var(--rte-space-lg) 0;padding:var(--rte-space-md);padding-left:var(--rte-space-lg);border-left:4px solid var(--rte-color-primary);background-color:var(--rte-color-bg-secondary);font-style:italic;color:var(--rte-color-text-secondary)}.rte-content ul,.rte-content ol{margin:var(--rte-space-md) 0;padding-left:var(--rte-space-xl)}.rte-content li{margin:var(--rte-space-xs) 0}.rte-content ul{list-style-type:disc}.rte-content ol{list-style-type:decimal}.rte-link{color:var(--rte-color-primary);text-decoration:none;transition:color var(--rte-transition-fast)}.rte-link:hover{color:var(--rte-color-primary-hover);text-decoration:underline}.rte-content code{font-family:var(--rte-font-family-mono);font-size:.875em;background-color:var(--rte-color-bg-tertiary);padding:.125rem .25rem;border-radius:var(--rte-radius-sm);color:var(--rte-color-danger)}.rte-content::selection{background-color:#007bff33}.rte-content:empty:before,.rte-content.rte-content-empty:before{content:attr(data-placeholder);color:var(--rte-color-text-muted);pointer-events:none}.rte-content:focus{outline:none}.rte-sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.rte-text-left{text-align:left}.rte-text-center{text-align:center}.rte-text-right{text-align:right}.rte-text-justify{text-align:justify}.rte-table,table{border-collapse:collapse;width:100%;margin:1rem 0;border:1px solid #ddd;font-size:14px;line-height:1.4;position:relative}.rte-table td,.rte-table th,table td,table th{border:1px solid #ddd;padding:8px 12px;min-width:80px;vertical-align:top;position:relative;-webkit-user-select:none;user-select:none}.rte-table td:focus,.rte-table th:focus,table td:focus,table th:focus{outline:2px solid #007acc;outline-offset:-2px}.rte-table th,table th{background-color:#f8f9fa;font-weight:600;text-align:left}.rte-table td p,table td p{margin:0;padding:0}.rte-table td p:empty:before,table td p:empty:before{content:"​";display:inline-block}.rte-table td[contenteditable]:empty:before,table td[contenteditable]:empty:before{content:"Type here...";color:#999;font-style:italic;pointer-events:none}.rte-table tr:hover,table tr:hover{background-color:#f8f9fa}.rte-table td.selected,table td.selected{background-color:#e3f2fd;border-color:#2196f3}.table-toolbar{background:#fff;border:1px solid #d0d0d0;border-radius:4px;box-shadow:0 2px 8px #0000001a;padding:4px;display:flex;align-items:center;gap:0;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,sans-serif;min-width:max-content}.toolbar-section{display:flex;align-items:center;gap:2px}.toolbar-divider{width:1px;height:20px;background:#e0e0e0;margin:0 4px}.toolbar-icon-btn{display:flex;align-items:center;justify-content:center;width:28px;height:28px;padding:0;border:1px solid transparent;background:transparent;cursor:pointer;color:#333;border-radius:3px;transition:all .2s ease;flex-shrink:0;font-size:14px;line-height:1}.toolbar-icon-btn svg{width:16px;height:16px}.toolbar-icon-btn:hover:not(:disabled){background:#f0f0f0;border-color:#d0d0d0;color:#06c}.toolbar-icon-btn:active:not(:disabled){background:#e8f0ff;border-color:#06c;transform:scale(.95)}.toolbar-icon-btn:disabled{opacity:.4;cursor:not-allowed;color:#ccc}.toolbar-icon-btn-danger{color:#d32f2f}.toolbar-icon-btn-danger:hover:not(:disabled){background:#fff3f3;border-color:#fcc;color:#d32f2f}.toolbar-icon-btn-danger:active:not(:disabled){background:#ffebee}.toolbar-icon-btn-delete{color:#d32f2f}.toolbar-icon-btn-delete:hover:not(:disabled){background:#fff3f3;border-color:#fcc;color:#d32f2f}.toolbar-icon-btn-delete:active:not(:disabled){background:#ffebee}.resize-handle{opacity:0;transition:all .15s ease}.resize-handle:hover{opacity:1}td:hover>.resize-handle,th:hover>.resize-handle{opacity:1}.table-resize-handle{position:absolute;bottom:-4px;right:-4px;width:12px;height:12px;background:transparent;cursor:nwse-resize;z-index:10;transition:background .15s ease}.table-resize-handle:after{content:"";position:absolute;bottom:0;right:0;width:8px;height:8px;background:#0066cc4d;border-bottom:2px solid #0066cc;border-right:2px solid #0066cc;border-radius:0 0 2px;opacity:0;transition:opacity .15s ease}.table-resize-handle:hover:after{opacity:1}.rte-table:hover .table-resize-handle:after,table:hover .table-resize-handle:after{opacity:1}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table,table){border-color:#607088;background:#24303c;color:#e6eefb}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table td,.rte-table th,table td,table th){border-color:#607088;color:#e6eefb}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table th,table th){background:linear-gradient(180deg,#3b4553,#333d4a);color:#f3f8ff}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table tr:hover,table tr:hover){background-color:#58a6ff1f}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table td.selected,table td.selected){background-color:#58a6ff47;border-color:#79beff}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table td[contenteditable]:empty:before,table td[contenteditable]:empty:before){color:#94a3b8}:is([data-theme=dark],.dark,.editora-theme-dark) .table-toolbar{background:linear-gradient(180deg,#2f3844,#2a323c);border-color:#4d596b;box-shadow:0 8px 20px #00000073}.table-toolbar.rte-theme-dark{background:linear-gradient(180deg,#2f3844,#2a323c);border-color:#4d596b;box-shadow:0 8px 20px #00000073}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-divider{background:#4d596b}.table-toolbar.rte-theme-dark .toolbar-divider{background:#4d596b}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn{color:#d7deea;border-color:transparent}.table-toolbar.rte-theme-dark .toolbar-icon-btn{color:#d7deea;border-color:transparent}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg{color:currentColor;fill:currentColor}.table-toolbar.rte-theme-dark .toolbar-icon-btn svg{color:currentColor;fill:currentColor}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [stroke="#000" i],:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [stroke="#000000" i],:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [stroke=black i]{stroke:currentColor!important}.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [stroke="#000" i],.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [stroke="#000000" i],.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [stroke=black i]{stroke:currentColor!important}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [fill="#000" i],:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [fill="#000000" i],:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [fill=black i]{fill:currentColor!important}.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [fill="#000" i],.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [fill="#000000" i],.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [fill=black i]{fill:currentColor!important}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn:hover:not(:disabled){background:#3a4554;border-color:#607088;color:#f3f8ff}.table-toolbar.rte-theme-dark .toolbar-icon-btn:hover:not(:disabled){background:#3a4554;border-color:#607088;color:#f3f8ff}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn:active:not(:disabled){background:#4a95de;border-color:#67adf4;color:#0f1b2a}.table-toolbar.rte-theme-dark .toolbar-icon-btn:active:not(:disabled){background:#4a95de;border-color:#67adf4;color:#0f1b2a}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn:disabled{color:#7f8ca1}.table-toolbar.rte-theme-dark .toolbar-icon-btn:disabled{color:#7f8ca1}@media(max-width:768px){.rte-table,table{font-size:12px}.rte-table td,.rte-table th,table td,table th{padding:4px 6px;min-width:60px}.table-toolbar{padding:3px;gap:0;max-width:90vw;overflow-x:auto}.toolbar-icon-btn{width:26px;height:26px}.toolbar-divider{height:18px}}@media print{.rte-table,table{border:1px solid #000}.rte-table td,.rte-table th,table td,table th{border:1px solid #000;padding:4px}.table-toolbar{display:none}}
.editora-editor{display:flex;flex-direction:column;border:1px solid #ddd;border-radius:4px;background:#fff;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,sans-serif;font-size:14px;overflow:hidden}.editora-editor *{box-sizing:border-box}.editora-theme-light{background:#fff;color:#333}.editora-theme-dark{--editora-dark-toolbar-bg-start: #353d48;--editora-dark-toolbar-bg-end: #2d3540;--editora-dark-button-bg-start: #46505f;--editora-dark-button-bg-end: #3b4553;--editora-dark-button-hover-start: #525d6d;--editora-dark-button-hover-end: #465262;--editora-dark-button-active-start: #5eaaf6;--editora-dark-button-active-end: #4a95de;--editora-dark-border: #475263;--editora-dark-border-strong: #566275;--editora-dark-text: #e1e9f5;--editora-dark-text-strong: #f3f7ff;--editora-dark-text-muted: #aeb9cc;--editora-dark-surface: #1d242d;--editora-dark-content: #1f2732;background:linear-gradient(180deg,#1b2330,#1c2430);color:var(--editora-dark-text);border-color:var(--editora-dark-border)}.editora-toolbar{display:flex;align-items:center;gap:4px;padding:8px;background:#f5f5f5;border-bottom:1px solid #ddd;flex-wrap:wrap}.editora-theme-dark .editora-toolbar{background:linear-gradient(180deg,var(--editora-dark-toolbar-bg-start) 0%,var(--editora-dark-toolbar-bg-end) 100%);border-bottom-color:var(--editora-dark-border);box-shadow:inset 0 1px #ffffff0d}.editora-toolbar-sticky{position:sticky;top:0;z-index:100;position:-webkit-sticky}.editora-toolbar-group{display:flex;align-items:center;gap:2px}.editora-toolbar-button{padding:6px 12px;border:1px solid #ccc;background:#fff;cursor:pointer;border-radius:3px;font-weight:600;font-size:14px;height:30px;display:flex;align-items:center;white-space:nowrap}.editora-toolbar-group-button{display:flex;align-items:center}.editora-toolbar-input.font-size{width:40px;padding:.25rem;text-align:center;font-size:14px;background:#fff;border:1px solid var(--rte-color-border-light);border-radius:var(--rte-radius-sm)}.editora-toolbar-group-items{display:flex;align-items:center;border:1px solid #ccc;.editora-toolbar-button{border:none;border-radius:0;&:first-child{border-right:1px solid #ccc;border-top-left-radius:3px;border-bottom-left-radius:3px}&:last-child{border-left:1px solid #ccc;border-top-right-radius:3px;border-bottom-right-radius:3px}}}.editora-theme-dark .editora-toolbar-button{background:linear-gradient(180deg,var(--editora-dark-button-bg-start) 0%,var(--editora-dark-button-bg-end) 100%);border-color:var(--editora-dark-border-strong);color:var(--editora-dark-text);box-shadow:inset 0 1px #ffffff14,0 1px 1px #00000059}.editora-theme-dark .editora-toolbar-group-items{border-color:var(--editora-dark-border-strong);background:linear-gradient(180deg,var(--editora-dark-button-bg-start) 0%,var(--editora-dark-button-bg-end) 100%)}.editora-theme-dark .editora-toolbar-group-items .editora-toolbar-button:first-child{border-right-color:#566275}.editora-theme-dark .editora-toolbar-group-items .editora-toolbar-button:last-child{border-left-color:#566275}.editora-theme-dark .editora-toolbar-input.font-size{background-color:#2e3642;color:var(--editora-dark-text-strong);border-color:var(--editora-dark-border-strong);caret-color:var(--editora-dark-text-strong)}.editora-theme-dark .editora-toolbar-input.font-size::placeholder{color:var(--editora-dark-text-strong);opacity:1}.editora-toolbar-button:hover{background:#e0e0e0;border-color:#ccc}.editora-theme-dark .editora-toolbar-button:hover{background:linear-gradient(180deg,var(--editora-dark-button-hover-start) 0%,var(--editora-dark-button-hover-end) 100%);border-color:#66748a;color:var(--editora-dark-text-strong)}.editora-toolbar-button:active,.editora-toolbar-button.active{background:#d0d0d0;border-color:#999}.editora-theme-dark .editora-toolbar-button:active,.editora-theme-dark .editora-toolbar-button.active{background:linear-gradient(180deg,var(--editora-dark-button-active-start) 0%,var(--editora-dark-button-active-end) 100%);border-color:#67adf4;color:#0f1b2a}.editora-theme-dark .editora-toolbar-button:disabled{background:#313946;border-color:#424d5e;color:#7f8ca1}.editora-theme-dark .editora-toolbar-button[data-command=insertTable],.editora-theme-dark .editora-toolbar-button[data-command=print],.editora-theme-dark .editora-toolbar-button[data-command=toggleSpellCheck],.editora-theme-dark .editora-toolbar-button[data-command=toggleA11yChecker],.editora-theme-dark .editora-toolbar-button[data-command=setDirectionLTR],.editora-theme-dark .editora-toolbar-button[data-command=setDirectionRTL]{color:#f1f6ff}.editora-toolbar-button:disabled{opacity:.5;cursor:not-allowed}.editora-toolbar-icon{display:inline-flex;align-items:center;justify-content:center;width:24px;height:24px;line-height:1}.editora-toolbar-button svg,.editora-toolbar-icon svg{width:20px;height:20px;display:block;color:currentColor;fill:currentColor}.editora-theme-dark .editora-toolbar-icon,.editora-theme-dark .editora-toolbar-icon *{color:inherit}.editora-theme-dark :is(.editora-toolbar-button,.editora-toolbar-icon) svg :is([stroke="#000" i],[stroke="#000000" i],[stroke=black i],[stroke="#0f0f0f" i],[stroke="#111111" i],[style*="stroke:#000" i],[style*="stroke: #000" i],[style*="stroke:black" i],[style*="stroke: black" i],[style*="stroke:#0f0f0f" i],[style*="stroke: #0f0f0f" i]){stroke:currentColor!important}.editora-theme-dark :is(.editora-toolbar-button,.editora-toolbar-icon) svg :is([fill="#000" i],[fill="#000000" i],[fill=black i],[fill="#0f0f0f" i],[fill="#111111" i],[style*="fill:#000" i],[style*="fill: #000" i],[style*="fill:black" i],[style*="fill: black" i],[style*="fill:#0f0f0f" i],[style*="fill: #0f0f0f" i]){fill:currentColor!important}.editora-toolbar-separator{width:1px;height:24px;background:#ddd;margin:0 4px}.editora-theme-dark .editora-toolbar-separator{background:#4d596b}.editora-toolbar-dropdown{position:relative}.editora-toolbar-dropdown-menu{position:absolute;top:100%;left:0;min-width:150px;margin-top:4px;padding:4px 0;background:#fff;border:1px solid #ddd;border-radius:4px;box-shadow:0 2px 8px #00000026;z-index:1000}.editora-theme-dark .editora-toolbar-dropdown-menu{background:#29323d;border-color:#4d596b;box-shadow:0 8px 20px #00000073}.editora-toolbar-dropdown-item{display:block;width:100%;padding:8px 12px;border:none;background:transparent;color:#333;text-align:left;cursor:pointer;font-size:13px;transition:background .15s ease}.editora-theme-dark .editora-toolbar-dropdown-item{color:#d7deea}.editora-toolbar-dropdown-item:hover{background:#f5f5f5}.editora-theme-dark .editora-toolbar-dropdown-item:hover{background:#3a4554;color:#f0f6ff}.editora-content{flex:1;min-height:200px;padding:16px;outline:none;overflow-y:auto;line-height:1.6}.editora-theme-dark .editora-content{color:#ecf3ff;background:linear-gradient(180deg,var(--editora-dark-content) 0%,#1c232e 100%)}.editora-content:empty:before{content:attr(data-placeholder);color:#999;pointer-events:none}.editora-theme-dark .editora-content:empty:before{color:#8f9bb0}.editora-content h1{font-size:2em;margin:.67em 0;font-weight:600}.editora-content h2{font-size:1.5em;margin:.75em 0;font-weight:600}.editora-content h3{font-size:1.17em;margin:.83em 0;font-weight:600}.editora-content p{margin:1em 0}.editora-content ul,.editora-content ol{margin:1em 0;padding-left:2em}.editora-content a{color:#06c;text-decoration:underline}.editora-theme-dark .editora-content a{color:#4db8ff}.editora-content code{padding:2px 4px;background:#f5f5f5;border-radius:3px;font-family:Monaco,Menlo,Consolas,monospace;font-size:.9em}.editora-theme-dark .editora-content code{background:#1e1e1e}.editora-content pre{padding:12px;background:#f5f5f5;border-radius:4px;overflow-x:auto;margin:1em 0}.editora-theme-dark .editora-content pre{background:#1e1e1e}.editora-theme-dark .rte-code-block{background:linear-gradient(180deg,#212a36,#1b2430)!important;border-color:#4f5b70!important;color:#e7effc!important}.editora-theme-dark .rte-code-block code{color:#e7effc!important}.editora-theme-dark .rte-code-block:before{background:#111927!important;color:#dce8ff!important}.editora-theme-dark .rte-code-block .rte-code-copy{background:#2b3441!important;border-color:#5a667b!important;color:#dce8ff!important}.editora-content blockquote{margin:1em 0;padding-left:1em;border-left:4px solid #ddd;color:#666}.editora-theme-dark .editora-content blockquote{border-left-color:#3c3c3c;color:#9a9a9a}.editora-floating-toolbar{position:absolute;padding:4px;background:#fff;border:1px solid #ddd;border-radius:4px;box-shadow:0 2px 8px #00000026;z-index:1000}.editora-theme-dark .editora-floating-toolbar{background:#29323d;border-color:#4d596b;box-shadow:0 8px 20px #00000073}.editora-theme-dark .editora-statusbar{background:linear-gradient(180deg,#2c3440,#252d37);border-top-color:#3f4a5b;color:#d7deea}.editora-statusbar-item{white-space:nowrap}.editora-theme-dark .editora-statusbar-separator{color:#566275}.editora-editor[readonly] .editora-content{background:#fafafa;cursor:not-allowed}.editora-theme-dark.editora-editor[readonly] .editora-content{background:#1a1a1a}.editora-editor:focus-within{border-color:#06c;box-shadow:0 0 0 3px #0066cc1a}.editora-theme-dark.editora-editor:focus-within{border-color:#4db8ff;box-shadow:0 0 0 3px #4db8ff1a}.editora-editor[disabled]{opacity:.6;pointer-events:none}@media(max-width:768px){.editora-toolbar{padding:4px}.editora-toolbar-button{min-width:28px;min-height:28px;padding:4px 8px;font-size:12px}.editora-content{padding:12px}}.editora-content ::selection{background:#06c3}.editora-theme-dark .editora-content ::selection{background:#4db8ff33}.editora-content table{border-collapse:collapse;width:100%;margin:1em 0}.editora-content th,.editora-content td{border:1px solid #ddd;padding:8px 12px;text-align:left}.editora-theme-dark .editora-content th,.editora-theme-dark .editora-content td{border-color:#3c3c3c}.editora-content th{background:#f5f5f5;font-weight:600}.editora-theme-dark .editora-content th{background:#252526}.editora-content img{max-width:100%;height:auto;border-radius:4px;display:block}.editora-content video{max-width:100%;height:auto;border-radius:4px;display:block}.editora-editor.loading{opacity:.7;pointer-events:none}.editora-editor.loading:after{content:"";position:absolute;top:50%;left:50%;width:24px;height:24px;margin:-12px 0 0 -12px;border:3px solid #ddd;border-top-color:#06c;border-radius:50%;animation:editora-spin .8s linear infinite}@keyframes editora-spin{to{transform:rotate(360deg)}}.toolbar-container-wrapper{display:flex;align-items:center;background:#fff;border-bottom:1px solid #e0e0e0;padding:0;margin:0;width:100%;box-sizing:border-box;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,sans-serif;font-size:14px;line-height:1.5;position:relative}.toolbar-container-wrapper[data-toolbar-sticky=true]{position:sticky;top:0;z-index:999;box-shadow:0 2px 4px #0000001a}.toolbar-container-wrapper[data-toolbar-floating=true]{position:fixed;top:0;left:0;right:0;z-index:1000;box-shadow:0 4px 12px #00000026}.toolbar-container-wrapper[data-toolbar-position=bottom]{border-bottom:none;border-top:1px solid #e0e0e0}.toolbar-container-wrapper .toolbar-wrapper{display:flex;width:100%;padding:8px;gap:4px;flex-wrap:wrap;align-items:center}.toolbar-container-wrapper .toolbar{display:flex;width:100%;gap:4px;flex-wrap:wrap;align-items:center}.toolbar-container-wrapper .toolbar-container{display:flex;gap:4px;flex-wrap:wrap;align-items:center;flex:1;position:relative}.toolbar-container-wrapper .toolbar-item{display:flex;align-items:center;gap:2px}.toolbar-container-wrapper .toolbar-button{padding:6px 10px;border:1px solid #d1d5db;background:#fff;border-radius:4px;cursor:pointer;font-size:13px;display:flex;align-items:center;justify-content:center;gap:4px;transition:all .15s ease;min-height:32px;white-space:nowrap}.toolbar-container-wrapper .toolbar-button:hover{background-color:#f3f4f6;border-color:#9ca3af}.toolbar-container-wrapper .toolbar-button:active,.toolbar-container-wrapper .toolbar-button[data-active=true]{background-color:#06c;color:#fff;border-color:#0052a3;box-shadow:inset 0 1px 3px #0000001a}.toolbar-container-wrapper .toolbar-button:disabled{opacity:.5;cursor:not-allowed;background-color:#f9fafb}.toolbar-container-wrapper .toolbar-more-button{padding:6px 8px;font-size:16px;font-weight:500;line-height:1}.toolbar-container-wrapper .toolbar-separator{width:1px;height:24px;background-color:#d1d5db;margin:0 4px}.toolbar-container-wrapper .toolbar-icon{display:inline-flex;align-items:center;justify-content:center;width:18px;height:18px;flex-shrink:0}.toolbar-container-wrapper .toolbar-icon svg{width:100%;height:100%}.toolbar-container-wrapper .toolbar-dropdown{position:relative;display:flex;align-items:center}.toolbar-container-wrapper .toolbar-dropdown-arrow{font-size:10px;margin-left:2px;line-height:1}.toolbar-container-wrapper .toolbar-dropdown-menu{position:absolute;top:100%;left:0;background:#fff;border:1px solid #d1d5db;border-radius:6px;box-shadow:0 4px 12px #00000026;z-index:1000;min-width:160px;padding:4px 0;margin-top:4px;display:none}.toolbar-container-wrapper .toolbar-dropdown-menu.show{display:block}.toolbar-container-wrapper .toolbar-dropdown-item{display:block;width:100%;padding:8px 12px;border:none;background:transparent;text-align:left;cursor:pointer;font-size:13px;color:#1f2937;transition:background-color .15s ease;font-family:inherit}.toolbar-container-wrapper .toolbar-dropdown-item:hover{background-color:#f3f4f6}.toolbar-container-wrapper .toolbar-dropdown-item:active{background-color:#e5e7eb}.toolbar-container-wrapper .toolbar-input{padding:6px 8px;border:1px solid #d1d5db;border-radius:4px;font-size:13px;font-family:inherit;background-color:#fff;color:#1f2937;transition:all .15s ease}.toolbar-container-wrapper .toolbar-input:focus{outline:none;border-color:#06c;box-shadow:0 0 0 3px #0066cc1a;background-color:#fff}.toolbar-container-wrapper .toolbar-input::placeholder{color:#9ca3af}.toolbar-overflow-menu{animation:slideDown .2s ease-out}@keyframes slideDown{0%{opacity:0;transform:translateY(-8px)}to{opacity:1;transform:translateY(0)}}.toolbar-overflow-item{transition:background-color .15s ease}.floating-toolbar{user-select:none;-webkit-user-select:none;font-family:system-ui,-apple-system,sans-serif;font-size:14px;animation:fadeInUp .15s ease-out}@keyframes fadeInUp{0%{opacity:0;transform:translate(-50%) translateY(10px)}to{opacity:1;transform:translate(-50%) translateY(0)}}.floating-toolbar-btn{display:flex;align-items:center;justify-content:center;width:32px;height:32px;border:none;background:transparent;border-radius:4px;color:#495057;cursor:pointer;font-size:14px;font-weight:500;transition:all .15s ease;outline:none}.floating-toolbar-btn:hover{background:#f8f9fa;color:#212529}.floating-toolbar-btn:active{background:#e9ecef;transform:scale(.95)}.floating-toolbar-btn.floating-toolbar-toggle{color:#dc3545;font-weight:700}.floating-toolbar-btn.floating-toolbar-toggle:hover{background:#f8d7da;color:#721c24}.floating-toolbar-separator{width:1px;height:20px;background:#e1e5e9;margin:0 2px}@media(max-width:768px){.toolbar-container-wrapper .toolbar-button{padding:5px 8px;font-size:12px;min-height:28px}.toolbar-container-wrapper .toolbar-icon{width:16px;height:16px}.toolbar-container-wrapper .toolbar-dropdown-menu{min-width:140px}.toolbar-container-wrapper .toolbar-dropdown-item{padding:6px 10px;font-size:12px}.floating-toolbar{padding:4px;gap:2px}.floating-toolbar-btn{width:28px;height:28px;font-size:12px}}@media(max-width:480px){.toolbar-container-wrapper{padding:4px}.toolbar-container-wrapper .toolbar-wrapper{padding:4px;gap:2px}.toolbar-container-wrapper .toolbar-button{padding:4px 6px;font-size:11px;min-height:24px}.toolbar-container-wrapper .toolbar-icon{width:14px;height:14px}}.floating-toolbar{pointer-events:auto}.floating-toolbar{max-width:calc(100vw - 20px);overflow-x:auto}@media(prefers-color-scheme:dark){.floating-toolbar{background:#2d3748;border-color:#4a5568;color:#e2e8f0}.floating-toolbar-btn:hover{background:#4a5568;color:#f7fafc}.floating-toolbar-btn:active{background:#718096}.floating-toolbar-separator{background:#4a5568}}.rte-editor{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,sans-serif}.rte-toolbar-wrapper{border-radius:4px 4px 0 0}.rte-toolbar{display:flex;gap:4px;padding:8px;background:#f5f5f5;border:1px solid #ddd;border-bottom:none;border-radius:4px 4px 0 0;align-items:center;position:relative}.rte-toolbar-items-container{display:flex;gap:4px;flex-wrap:nowrap;align-items:center;flex:1}.rte-toolbar-item{position:relative;display:flex;align-items:center;white-space:nowrap}.rte-toolbar-group-items.font-size{display:flex;align-items:center;border:1px solid #ccc;.rte-toolbar-input.font-size{width:40px;padding:.25rem;text-align:center;font-size:14px;background:#fff;border:1px solid var(--rte-color-border-light);border-radius:var(--rte-radius-sm)}.rte-toolbar-button{border:none;border-radius:0}.rte-toolbar-item{&:first-child{border-right:1px solid #ccc;border-top-left-radius:3px;border-bottom-left-radius:3px}&:last-child{border-left:1px solid #ccc;border-top-right-radius:3px;border-bottom-right-radius:3px}}}.rte-toolbar-button{padding:6px 12px;border:1px solid #ccc;background:#fff;cursor:pointer;border-radius:3px;font-weight:600;font-size:14px;height:30px;display:flex;align-items:center;white-space:nowrap}.rte-toolbar-button:hover{background:#e9e9e9}.rte-toolbar-input{width:26px;padding:6px 8px;border:1px solid #ccc;border-radius:3px;font-size:14px;text-align:center}.rte-toolbar-dropdown{position:relative}.rte-toolbar-dropdown-menu{position:absolute;top:100%;left:0;background:#fff;border:1px solid #ccc;border-radius:3px;box-shadow:0 2px 8px #00000026;min-width:150px;z-index:1000;margin-top:2px}.rte-toolbar-dropdown-item{padding:8px 12px;cursor:pointer}.rte-toolbar-dropdown-item:hover{background:#f0f0f0}.rte-toolbar-more-button{padding:6px 10px;border:1px solid #ccc;background:#fff;cursor:pointer;border-radius:3px;font-weight:600;font-size:16px;height:30px;display:flex;align-items:center;justify-content:center;min-width:30px;transition:background-color .2s ease;margin-left:auto}.rte-toolbar-more-button:hover{background:#e9e9e9}.rte-toolbar-more-button.active{background:#ddd;border-color:#999}.rte-toolbar-expanded-row{display:flex;transform:scaleY(0);transform-origin:top;max-height:0;padding:0;overflow:hidden;opacity:0;transition:transform .25s ease,opacity .2s ease,max-height .25s ease}.rte-toolbar-expanded-row.show{transform:scaleY(1);max-height:200px;padding:1px 8px 8px;opacity:1;background:#f5f5f5;border:1px solid #ddd;border-top:none;gap:4px}.rte-content{font-size:16px;line-height:1.6}.rte-content.rte-content-empty:before,.rte-content:empty:before{content:attr(data-placeholder);color:var(--rte-color-text-muted, #6b7280);pointer-events:none}.rte-content p{margin:0 0 1em}.rte-content h1{font-size:2em;margin:.67em 0}.rte-content h2{font-size:1.5em;margin:.75em 0}.rte-content h3{font-size:1.17em;margin:.83em 0}.rte-content h4{font-size:1em;margin:1em 0}.rte-content h5{font-size:.83em;margin:1.17em 0}.rte-content h6{font-size:.67em;margin:1.33em 0}.rte-content ul,.rte-content ol{margin:1em 0;padding-left:2em}.rte-content code{background:#f4f4f4;padding:2px 6px;border-radius:3px;font-family:Courier New,monospace;font-size:.9em}.rte-content blockquote{border-left:4px solid #ddd;margin:1em 0;padding-left:1em;color:#666}.rte-content a{color:#06c;text-decoration:underline}.rte-content a:hover{color:#0052a3}.rte-dialog-overlay{position:fixed;inset:0;background:#00000080;display:flex;align-items:center;justify-content:center;z-index:10000}.rte-dialog-content{background:#fff;border-radius:8px;box-shadow:0 4px 20px #0000004d;max-width:400px;width:90%;max-height:90vh;overflow-y:auto}.rte-dialog-header{padding:16px 20px;border-bottom:1px solid #e0e0e0;display:flex;justify-content:space-between;align-items:center}.rte-dialog-header h3{margin:0;font-size:18px;font-weight:600;color:#333}.rte-dialog-close{background:none;border:none;font-size:24px;cursor:pointer;color:#666;padding:0;width:30px;height:30px;display:flex;align-items:center;justify-content:center}.rte-dialog-close:hover{color:#333}.rte-dialog-body{padding:20px}.rte-dialog-footer{padding:16px 20px;border-top:1px solid #e0e0e0;display:flex;justify-content:flex-end;gap:12px}.rte-btn{padding:8px 16px;border:1px solid #ccc;border-radius:4px;cursor:pointer;font-size:14px;font-weight:500;transition:all .2s}.rte-btn:hover{border-color:#999}.rte-btn-primary{background:#06c;color:#fff;border-color:#06c}.rte-btn-primary:hover{background:#0052a3;border-color:#0052a3}.rte-btn-secondary{background:#fff;color:#333}.rte-btn-secondary:hover{background:#f5f5f5}.rte-form-group{margin-bottom:16px}.rte-form-label{display:block;margin-bottom:6px;font-weight:500;color:#333;font-size:14px}.rte-form-input{width:100%;padding:8px 12px;border:1px solid #ccc;border-radius:4px;font-size:14px;box-sizing:border-box}.rte-form-input:focus{outline:none;border-color:#06c;box-shadow:0 0 0 2px #06c3}.rte-form-row{display:flex;gap:12px}.rte-form-row .rte-form-group{flex:1}.rte-color-preview{display:flex;align-items:center;gap:12px;margin-bottom:20px;padding:12px;background:#f8f9fa;border-radius:4px}.rte-color-sample{width:40px;height:40px;border-radius:4px;border:2px solid #ddd}.rte-color-value{font-family:monospace;font-size:14px;font-weight:500;color:#333}.rte-color-section{margin-bottom:20px}.rte-color-label{margin-bottom:8px;font-size:14px;font-weight:500}.rte-color-palette{display:grid;grid-template-columns:repeat(6,1fr);gap:8px;margin-bottom:16px}.rte-color-swatch{width:24px;height:24px;border:2px solid #ddd;border-radius:4px;cursor:pointer;transition:all .2s}.rte-color-swatch:hover{border-color:#999;transform:scale(1.1)}.rte-color-swatch.selected{border-color:#06c;box-shadow:0 0 0 2px #0066cc4d}.rte-custom-color{display:flex;align-items:center;gap:12px}.rte-color-input{width:60px;height:40px;border:2px solid #ddd;border-radius:4px;cursor:pointer}.rte-color-text-input{flex:1;padding:8px 12px;border:1px solid #ccc;border-radius:4px;font-family:monospace;font-size:14px}.rte-color-text-input:focus{outline:none;border-color:#06c;box-shadow:0 0 0 2px #06c3}.rte-iframe-preview{border:1px solid #ddd;border-radius:4px;overflow:hidden;background:#f8f9fa}.rte-iframe-preview iframe{display:block;border:none}.rte-size-presets{display:flex;flex-direction:column;gap:8px}.rte-radio-option{display:flex;align-items:flex-start;gap:8px;padding:8px;border:1px solid #e0e0e0;border-radius:4px;background:#fafbfc}.rte-radio-option:hover{background:#f1f3f4}.rte-radio-option input[type=radio]{margin-top:2px}.rte-radio-label{flex:1;line-height:1.4}.rte-content ul[data-type=checklist]{list-style:none;padding-left:0;margin:1em 0}.rte-content li[data-type=checklist-item]{position:relative;padding-left:2em;margin-bottom:.5em;line-height:1.6}.rte-content li[data-type=checklist-item]:before{content:"";position:absolute;left:0;top:.1em;width:1.2em;height:1.2em;border:2px solid #ccc;border-radius:3px;background:#fff;cursor:pointer;transition:all .2s ease}.rte-content li[data-type=checklist-item]:hover:before{border-color:#999}.rte-content li[data-type=checklist-item][data-checked=true]:before{background:#06c;border-color:#06c}.rte-content li[data-type=checklist-item][data-checked=true]:after{content:"✓";position:absolute;left:.36em;top:.12em;color:#fff;font-size:.9em;font-weight:700;pointer-events:none}.rte-content li[data-type=checklist-item][data-checked=true] p{text-decoration:line-through;color:#666}.editora-statusbar-container{display:flex;flex-direction:column}.rte-editor{.editora-statusbar-bottom{top:-32px}}.editora-statusbar-bottom{position:relative;border-left:1px solid rgb(221,221,221);border-right:1px solid rgb(221,221,221)}.editora-statusbar{display:flex;align-items:center;gap:12px;padding:6px 12px;background:#f5f5f5;border-top:1px solid #ddd;font-size:12px;color:#666}.editora-theme-dark .editora-statusbar{background:#252526;border-top-color:#3c3c3c;color:#9a9a9a}.editora-statusbar-top{border-top:none;border-bottom:1px solid #e0e0e0}.editora-statusbar-left{display:flex;align-items:center;gap:8px}.editora-statusbar-right{display:flex;align-items:center;gap:8px;margin-left:auto}.editora-statusbar-item{white-space:nowrap;padding:2px 4px}.editora-statusbar-separator{color:#ddd}.editora-theme-dark .editora-statusbar-separator{color:#3c3c3c}.editora-theme-dark .rte-content,.editora-theme-dark .rte-content h1,.editora-theme-dark .rte-content h2,.editora-theme-dark .rte-content h3,.editora-theme-dark .rte-content h4,.editora-theme-dark .rte-content h5,.editora-theme-dark .rte-content h6{color:#fff}.rte-inline-menu{position:fixed;z-index:1000;background:#fff;border:1px solid #ccc;border-radius:4px;box-shadow:0 2px 8px #00000026;min-width:120px;max-width:200px;pointer-events:auto}.rte-inline-menu-item{padding:8px 12px;cursor:pointer;font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;background-color:transparent}.rte-inline-menu-item:hover{background-color:#f5f5f5}.floating-toolbar{--rte-floating-toolbar-bg: #ffffff;--rte-floating-toolbar-border: #d7dee8;--rte-floating-toolbar-text: #364152;--rte-floating-toolbar-hover-bg: #f2f6fb;--rte-floating-toolbar-hover-text: #101828;--rte-floating-toolbar-active-bg: #e7eef7;--rte-floating-toolbar-separator: #d8e1ec;--rte-floating-toolbar-shadow: 0 10px 28px rgba(15, 23, 36, .16);user-select:none;-webkit-user-select:none;align-items:center;gap:4px;padding:6px;border-radius:8px;border:1px solid var(--rte-floating-toolbar-border);background:var(--rte-floating-toolbar-bg);color:var(--rte-floating-toolbar-text);box-shadow:var(--rte-floating-toolbar-shadow);pointer-events:auto;animation:rteFloatingToolbarIn .15s ease-out}.floating-toolbar-btn{display:inline-flex;align-items:center;justify-content:center;min-width:32px;height:32px;border:none;border-radius:6px;background:transparent;color:inherit;cursor:pointer;font-size:14px;font-weight:600;transition:background-color .15s ease,color .15s ease,transform .12s ease}.floating-toolbar-btn:hover{background:var(--rte-floating-toolbar-hover-bg);color:var(--rte-floating-toolbar-hover-text)}.floating-toolbar-btn:active{background:var(--rte-floating-toolbar-active-bg);transform:scale(.96)}.floating-toolbar-separator{width:1px;height:20px;margin:0 2px;background:var(--rte-floating-toolbar-separator)}@keyframes rteFloatingToolbarIn{0%{opacity:0;transform:translate(-50%) translateY(8px)}to{opacity:1;transform:translate(-50%) translateY(0)}}.editora-toolbar-group-button{display:flex;align-items:center;border-radius:var(--rte-radius);overflow:hidden;border:1px solid var(--rte-color-border-light);background:var(--rte-color-bg-secondary, #f9fafb);margin-right:.5rem;padding:0}.editora-toolbar-group-items{display:flex;align-items:center;gap:0}.editora-toolbar-group-button .editora-toolbar-button,.editora-toolbar-group-button .editora-toolbar-input{border-radius:0;border:none;margin:0;background:transparent;box-shadow:none}.editora-toolbar-group-button .editora-toolbar-button:first-child{border-radius:var(--rte-radius) 0 0 var(--rte-radius)}.editora-toolbar-group-button .editora-toolbar-button:last-child{border-radius:0 var(--rte-radius) var(--rte-radius) 0}.editora-toolbar-group-button .editora-toolbar-input{min-width:44px;width:44px;text-align:center;font-size:15px;background:#fff;border-left:1px solid var(--rte-color-border-light);border-right:1px solid var(--rte-color-border-light)}.editora-toolbar-group-button .editora-toolbar-button:active,.editora-toolbar-group-button .editora-toolbar-button:focus{background:#e5e7eb}.editora-toolbar-group-button .editora-toolbar-input:focus{outline:1.5px solid var(--rte-color-primary, #2563eb)}:root{--rte-color-primary: #007bff;--rte-color-primary-hover: #0056b3;--rte-color-secondary: #6c757d;--rte-color-success: #28a745;--rte-color-danger: #dc3545;--rte-color-warning: #ffc107;--rte-color-info: #17a2b8;--rte-color-text-primary: #212529;--rte-color-text-secondary: #6c757d;--rte-color-text-muted: #868e96;--rte-color-text-inverse: #ffffff;--rte-color-bg-primary: #ffffff;--rte-color-bg-secondary: #f8f9fa;--rte-color-bg-tertiary: #e9ecef;--rte-color-bg-hover: #f8f9fa;--rte-color-bg-active: #e9ecef;--rte-color-border: #dee2e6;--rte-color-border-light: #f8f9fa;--rte-color-border-focus: #007bff;--rte-shadow-sm: 0 1px 2px rgba(0, 0, 0, .05);--rte-shadow: 0 1px 3px rgba(0, 0, 0, .1), 0 1px 2px rgba(0, 0, 0, .06);--rte-shadow-lg: 0 10px 15px rgba(0, 0, 0, .1), 0 4px 6px rgba(0, 0, 0, .05);--rte-space-xs: .25rem;--rte-space-sm: .5rem;--rte-space-md: 1rem;--rte-space-lg: 1.5rem;--rte-space-xl: 2rem;--rte-space-xxl: 3rem;--rte-font-family-base: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;--rte-font-family-mono: "SFMono-Regular", Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;--rte-font-size-xs: .75rem;--rte-font-size-sm: .875rem;--rte-font-size-base: 1rem;--rte-font-size-lg: 1.125rem;--rte-font-size-xl: 1.25rem;--rte-font-size-xxl: 1.5rem;--rte-font-size-xxxl: 2rem;--rte-font-weight-normal: 400;--rte-font-weight-medium: 500;--rte-font-weight-semibold: 600;--rte-font-weight-bold: 700;--rte-line-height-tight: 1.25;--rte-line-height-normal: 1.5;--rte-line-height-relaxed: 1.75;--rte-radius-sm: .125rem;--rte-radius: .25rem;--rte-radius-md: .375rem;--rte-radius-lg: .5rem;--rte-radius-xl: .75rem;--rte-transition-fast: .15s ease-in-out;--rte-transition-normal: .25s ease-in-out;--rte-transition-slow: .35s ease-in-out;--rte-z-dropdown: 1000;--rte-z-sticky: 1020;--rte-z-modal: 1050;--rte-z-popover: 1060;--rte-z-tooltip: 1070}.rte-editor{font-family:var(--rte-font-family-base);font-size:var(--rte-font-size-base);line-height:var(--rte-line-height-normal);color:var(--rte-color-text-primary);background-color:var(--rte-color-bg-primary);border:1px solid var(--rte-color-border);border-radius:var(--rte-radius);box-shadow:var(--rte-shadow);transition:border-color var(--rte-transition-fast),box-shadow var(--rte-transition-fast)}.rte-editor:focus-within{border-color:var(--rte-color-border-focus);box-shadow:var(--rte-shadow),0 0 0 3px #007bff1a}.rte-toolbar{display:flex;align-items:center;padding:var(--rte-space-sm);border-bottom:1px solid var(--rte-color-border);background-color:var(--rte-color-bg-secondary);border-radius:var(--rte-radius) var(--rte-radius) 0 0;flex-wrap:wrap;gap:2px}.rte-toolbar-group{display:flex;align-items:center;border-radius:var(--rte-radius);overflow:hidden;border:1px solid var(--rte-color-border-light)}.rte-toolbar-button{display:flex;align-items:center;justify-content:center;width:2rem;height:2rem;padding:0;border:none;background:transparent;color:var(--rte-color-text-secondary);cursor:pointer;border-radius:var(--rte-radius-sm);transition:background-color var(--rte-transition-fast),color var(--rte-transition-fast);font-size:14px;line-height:1}.rte-toolbar-button span{display:flex;justify-content:center;align-items:center}.rte-toolbar-button svg,.editora-toolbar-button svg,.editora-toolbar-icon svg{flex-shrink:0;width:20px;height:20px;display:block;color:currentColor;fill:currentColor}.rte-toolbar-button:hover svg{opacity:.9}:is(.rte-toolbar-button[data-active=true],.editora-toolbar-button.active) svg{color:var(--rte-color-text-inverse)}.rte-toolbar-button:hover{background-color:var(--rte-color-bg-hover);color:var(--rte-color-text-primary)}.rte-toolbar-button:active,.rte-toolbar-button[data-active=true]{background-color:var(--rte-color-primary);color:var(--rte-color-text-inverse)}.rte-toolbar-button:disabled{opacity:.5;cursor:not-allowed}.rte-content{padding:var(--rte-space-md);min-height:200px;outline:none;overflow-wrap:break-word;word-wrap:break-word}.rte-content[contenteditable=true]{cursor:text}.rte-content h1,.rte-content h2,.rte-content h3,.rte-content h4,.rte-content h5,.rte-content h6{margin:var(--rte-space-lg) 0 var(--rte-space-md) 0;font-weight:var(--rte-font-weight-semibold);line-height:var(--rte-line-height-tight);color:var(--rte-color-text-primary)}.rte-content h1{font-size:var(--rte-font-size-xxxl)}.rte-content h2{font-size:var(--rte-font-size-xxl)}.rte-content h3{font-size:var(--rte-font-size-xl)}.rte-content h4{font-size:var(--rte-font-size-lg)}.rte-content h5{font-size:var(--rte-font-size-base)}.rte-content h6{font-size:var(--rte-font-size-sm)}.rte-content p{margin:var(--rte-space-md) 0}.rte-content blockquote{margin:var(--rte-space-lg) 0;padding:var(--rte-space-md);padding-left:var(--rte-space-lg);border-left:4px solid var(--rte-color-primary);background-color:var(--rte-color-bg-secondary);font-style:italic;color:var(--rte-color-text-secondary)}.rte-content ul,.rte-content ol{margin:var(--rte-space-md) 0;padding-left:var(--rte-space-xl)}.rte-content li{margin:var(--rte-space-xs) 0}.rte-content ul{list-style-type:disc}.rte-content ol{list-style-type:decimal}.rte-link{color:var(--rte-color-primary);text-decoration:none;transition:color var(--rte-transition-fast)}.rte-link:hover{color:var(--rte-color-primary-hover);text-decoration:underline}.rte-content code{font-family:var(--rte-font-family-mono);font-size:.875em;background-color:var(--rte-color-bg-tertiary);padding:.125rem .25rem;border-radius:var(--rte-radius-sm);color:var(--rte-color-danger)}.rte-content::selection{background-color:#007bff33}.rte-content:empty:before,.rte-content.rte-content-empty:before{content:attr(data-placeholder);color:var(--rte-color-text-muted);pointer-events:none}.rte-content:focus{outline:none}.rte-sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.rte-text-left{text-align:left}.rte-text-center{text-align:center}.rte-text-right{text-align:right}.rte-text-justify{text-align:justify}.rte-table,table{border-collapse:collapse;width:100%;margin:1rem 0;border:1px solid #ddd;font-size:14px;line-height:1.4;position:relative}.rte-table td,.rte-table th,table td,table th{border:1px solid #ddd;padding:8px 12px;min-width:80px;vertical-align:top;position:relative;-webkit-user-select:none;user-select:none}.rte-table td:focus,.rte-table th:focus,table td:focus,table th:focus{outline:2px solid #007acc;outline-offset:-2px}.rte-table th,table th{background-color:#f8f9fa;font-weight:600;text-align:left}.rte-table td p,table td p{margin:0;padding:0}.rte-table td p:empty:before,table td p:empty:before{content:"​";display:inline-block}.rte-table td[contenteditable]:empty:before,table td[contenteditable]:empty:before{content:"Type here...";color:#999;font-style:italic;pointer-events:none}.rte-table tr:hover,table tr:hover{background-color:#f8f9fa}.rte-table td.selected,table td.selected{background-color:#e3f2fd;border-color:#2196f3}.table-toolbar{background:#fff;border:1px solid #d0d0d0;border-radius:4px;box-shadow:0 2px 8px #0000001a;padding:4px;display:flex;align-items:center;gap:0;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,sans-serif;min-width:max-content}.toolbar-section{display:flex;align-items:center;gap:2px}.toolbar-divider{width:1px;height:20px;background:#e0e0e0;margin:0 4px}.toolbar-icon-btn{display:flex;align-items:center;justify-content:center;width:28px;height:28px;padding:0;border:1px solid transparent;background:transparent;cursor:pointer;color:#333;border-radius:3px;transition:all .2s ease;flex-shrink:0;font-size:14px;line-height:1}.toolbar-icon-btn svg{width:16px;height:16px}.toolbar-icon-btn:hover:not(:disabled){background:#f0f0f0;border-color:#d0d0d0;color:#06c}.toolbar-icon-btn:active:not(:disabled){background:#e8f0ff;border-color:#06c;transform:scale(.95)}.toolbar-icon-btn:disabled{opacity:.4;cursor:not-allowed;color:#ccc}.toolbar-icon-btn-danger{color:#d32f2f}.toolbar-icon-btn-danger:hover:not(:disabled){background:#fff3f3;border-color:#fcc;color:#d32f2f}.toolbar-icon-btn-danger:active:not(:disabled){background:#ffebee}.toolbar-icon-btn-delete{color:#d32f2f}.toolbar-icon-btn-delete:hover:not(:disabled){background:#fff3f3;border-color:#fcc;color:#d32f2f}.toolbar-icon-btn-delete:active:not(:disabled){background:#ffebee}.resize-handle{opacity:0;transition:all .15s ease}.resize-handle:hover{opacity:1}td:hover>.resize-handle,th:hover>.resize-handle{opacity:1}.table-resize-handle{position:absolute;bottom:-4px;right:-4px;width:12px;height:12px;background:transparent;cursor:nwse-resize;z-index:10;transition:background .15s ease}.table-resize-handle:after{content:"";position:absolute;bottom:0;right:0;width:8px;height:8px;background:#0066cc4d;border-bottom:2px solid #0066cc;border-right:2px solid #0066cc;border-radius:0 0 2px;opacity:0;transition:opacity .15s ease}.table-resize-handle:hover:after{opacity:1}.rte-table:hover .table-resize-handle:after,table:hover .table-resize-handle:after{opacity:1}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table,table){border-color:#607088;background:#24303c;color:#e6eefb}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table td,.rte-table th,table td,table th){border-color:#607088;color:#e6eefb}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table th,table th){background:linear-gradient(180deg,#3b4553,#333d4a);color:#f3f8ff}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table tr:hover,table tr:hover){background-color:#58a6ff1f}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table td.selected,table td.selected){background-color:#58a6ff47;border-color:#79beff}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table td[contenteditable]:empty:before,table td[contenteditable]:empty:before){color:#94a3b8}:is([data-theme=dark],.dark,.editora-theme-dark) .table-toolbar{background:linear-gradient(180deg,#2f3844,#2a323c);border-color:#4d596b;box-shadow:0 8px 20px #00000073}.table-toolbar.rte-theme-dark{background:linear-gradient(180deg,#2f3844,#2a323c);border-color:#4d596b;box-shadow:0 8px 20px #00000073}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-divider{background:#4d596b}.table-toolbar.rte-theme-dark .toolbar-divider{background:#4d596b}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn{color:#d7deea;border-color:transparent}.table-toolbar.rte-theme-dark .toolbar-icon-btn{color:#d7deea;border-color:transparent}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg{color:currentColor;fill:currentColor}.table-toolbar.rte-theme-dark .toolbar-icon-btn svg{color:currentColor;fill:currentColor}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [stroke="#000" i],:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [stroke="#000000" i],:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [stroke=black i]{stroke:currentColor!important}.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [stroke="#000" i],.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [stroke="#000000" i],.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [stroke=black i]{stroke:currentColor!important}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [fill="#000" i],:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [fill="#000000" i],:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [fill=black i]{fill:currentColor!important}.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [fill="#000" i],.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [fill="#000000" i],.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [fill=black i]{fill:currentColor!important}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn:hover:not(:disabled){background:#3a4554;border-color:#607088;color:#f3f8ff}.table-toolbar.rte-theme-dark .toolbar-icon-btn:hover:not(:disabled){background:#3a4554;border-color:#607088;color:#f3f8ff}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn:active:not(:disabled){background:#4a95de;border-color:#67adf4;color:#0f1b2a}.table-toolbar.rte-theme-dark .toolbar-icon-btn:active:not(:disabled){background:#4a95de;border-color:#67adf4;color:#0f1b2a}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn:disabled{color:#7f8ca1}.table-toolbar.rte-theme-dark .toolbar-icon-btn:disabled{color:#7f8ca1}@media(max-width:768px){.rte-table,table{font-size:12px}.rte-table td,.rte-table th,table td,table th{padding:4px 6px;min-width:60px}.table-toolbar{padding:3px;gap:0;max-width:90vw;overflow-x:auto}.toolbar-icon-btn{width:26px;height:26px}.toolbar-divider{height:18px}}@media print{.rte-table,table{border:1px solid #000}.rte-table td,.rte-table th,table td,table th{border:1px solid #000;padding:4px}.table-toolbar{display:none}}

@@ -1,1 +0,1 @@

.editora-editor{display:flex;flex-direction:column;border:1px solid #ddd;border-radius:4px;background:#fff;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,sans-serif;font-size:14px;overflow:hidden}.editora-editor *{box-sizing:border-box}.editora-theme-light{background:#fff;color:#333}.editora-theme-dark{--editora-dark-toolbar-bg-start: #353d48;--editora-dark-toolbar-bg-end: #2d3540;--editora-dark-button-bg-start: #46505f;--editora-dark-button-bg-end: #3b4553;--editora-dark-button-hover-start: #525d6d;--editora-dark-button-hover-end: #465262;--editora-dark-button-active-start: #5eaaf6;--editora-dark-button-active-end: #4a95de;--editora-dark-border: #475263;--editora-dark-border-strong: #566275;--editora-dark-text: #e1e9f5;--editora-dark-text-strong: #f3f7ff;--editora-dark-text-muted: #aeb9cc;--editora-dark-surface: #1d242d;--editora-dark-content: #1f2732;background:linear-gradient(180deg,#1b2330,#1c2430);color:var(--editora-dark-text);border-color:var(--editora-dark-border)}.editora-toolbar{display:flex;align-items:center;gap:4px;padding:8px;background:#f5f5f5;border-bottom:1px solid #ddd;flex-wrap:wrap}.editora-theme-dark .editora-toolbar{background:linear-gradient(180deg,var(--editora-dark-toolbar-bg-start) 0%,var(--editora-dark-toolbar-bg-end) 100%);border-bottom-color:var(--editora-dark-border);box-shadow:inset 0 1px #ffffff0d}.editora-toolbar-sticky{position:sticky;top:0;z-index:100;position:-webkit-sticky}.editora-toolbar-group{display:flex;align-items:center;gap:2px}.editora-toolbar-button{padding:6px 12px;border:1px solid #ccc;background:#fff;cursor:pointer;border-radius:3px;font-weight:600;font-size:14px;height:30px;display:flex;align-items:center;white-space:nowrap}.editora-toolbar-group-button{display:flex;align-items:center}.editora-toolbar-input.font-size{width:40px;padding:.25rem;text-align:center;font-size:14px;background:#fff;border:1px solid var(--rte-color-border-light);border-radius:var(--rte-radius-sm)}.editora-toolbar-group-items{display:flex;align-items:center;border:1px solid #ccc;.editora-toolbar-button{border:none;border-radius:0;&:first-child{border-right:1px solid #ccc;border-top-left-radius:3px;border-bottom-left-radius:3px}&:last-child{border-left:1px solid #ccc;border-top-right-radius:3px;border-bottom-right-radius:3px}}}.editora-theme-dark .editora-toolbar-button{background:linear-gradient(180deg,var(--editora-dark-button-bg-start) 0%,var(--editora-dark-button-bg-end) 100%);border-color:var(--editora-dark-border-strong);color:var(--editora-dark-text);box-shadow:inset 0 1px #ffffff14,0 1px 1px #00000059}.editora-theme-dark .editora-toolbar-group-items{border-color:var(--editora-dark-border-strong);background:linear-gradient(180deg,var(--editora-dark-button-bg-start) 0%,var(--editora-dark-button-bg-end) 100%)}.editora-theme-dark .editora-toolbar-group-items .editora-toolbar-button:first-child{border-right-color:#566275}.editora-theme-dark .editora-toolbar-group-items .editora-toolbar-button:last-child{border-left-color:#566275}.editora-theme-dark .editora-toolbar-input.font-size{background-color:#2e3642;color:var(--editora-dark-text-strong);border-color:var(--editora-dark-border-strong);caret-color:var(--editora-dark-text-strong)}.editora-theme-dark .editora-toolbar-input.font-size::placeholder{color:var(--editora-dark-text-strong);opacity:1}.editora-toolbar-button:hover{background:#e0e0e0;border-color:#ccc}.editora-theme-dark .editora-toolbar-button:hover{background:linear-gradient(180deg,var(--editora-dark-button-hover-start) 0%,var(--editora-dark-button-hover-end) 100%);border-color:#66748a;color:var(--editora-dark-text-strong)}.editora-toolbar-button:active,.editora-toolbar-button.active{background:#d0d0d0;border-color:#999}.editora-theme-dark .editora-toolbar-button:active,.editora-theme-dark .editora-toolbar-button.active{background:linear-gradient(180deg,var(--editora-dark-button-active-start) 0%,var(--editora-dark-button-active-end) 100%);border-color:#67adf4;color:#0f1b2a}.editora-theme-dark .editora-toolbar-button:disabled{background:#313946;border-color:#424d5e;color:#7f8ca1}.editora-theme-dark .editora-toolbar-button[data-command=insertTable],.editora-theme-dark .editora-toolbar-button[data-command=print],.editora-theme-dark .editora-toolbar-button[data-command=toggleSpellCheck],.editora-theme-dark .editora-toolbar-button[data-command=toggleA11yChecker],.editora-theme-dark .editora-toolbar-button[data-command=setDirectionLTR],.editora-theme-dark .editora-toolbar-button[data-command=setDirectionRTL]{color:#f1f6ff}.editora-toolbar-button:disabled{opacity:.5;cursor:not-allowed}.editora-toolbar-icon{display:inline-flex;align-items:center;justify-content:center;width:24px;height:24px;line-height:1}.editora-toolbar-button svg,.editora-toolbar-icon svg{width:20px;height:20px;display:block;color:currentColor;fill:currentColor}.editora-theme-dark .editora-toolbar-icon,.editora-theme-dark .editora-toolbar-icon *{color:inherit}.editora-theme-dark :is(.editora-toolbar-button,.editora-toolbar-icon) svg :is([stroke="#000" i],[stroke="#000000" i],[stroke=black i],[stroke="#0f0f0f" i],[stroke="#111111" i],[style*="stroke:#000" i],[style*="stroke: #000" i],[style*="stroke:black" i],[style*="stroke: black" i],[style*="stroke:#0f0f0f" i],[style*="stroke: #0f0f0f" i]){stroke:currentColor!important}.editora-theme-dark :is(.editora-toolbar-button,.editora-toolbar-icon) svg :is([fill="#000" i],[fill="#000000" i],[fill=black i],[fill="#0f0f0f" i],[fill="#111111" i],[style*="fill:#000" i],[style*="fill: #000" i],[style*="fill:black" i],[style*="fill: black" i],[style*="fill:#0f0f0f" i],[style*="fill: #0f0f0f" i]){fill:currentColor!important}.editora-toolbar-separator{width:1px;height:24px;background:#ddd;margin:0 4px}.editora-theme-dark .editora-toolbar-separator{background:#4d596b}.editora-toolbar-dropdown{position:relative}.editora-toolbar-dropdown-menu{position:absolute;top:100%;left:0;min-width:150px;margin-top:4px;padding:4px 0;background:#fff;border:1px solid #ddd;border-radius:4px;box-shadow:0 2px 8px #00000026;z-index:1000}.editora-theme-dark .editora-toolbar-dropdown-menu{background:#29323d;border-color:#4d596b;box-shadow:0 8px 20px #00000073}.editora-toolbar-dropdown-item{display:block;width:100%;padding:8px 12px;border:none;background:transparent;color:#333;text-align:left;cursor:pointer;font-size:13px;transition:background .15s ease}.editora-theme-dark .editora-toolbar-dropdown-item{color:#d7deea}.editora-toolbar-dropdown-item:hover{background:#f5f5f5}.editora-theme-dark .editora-toolbar-dropdown-item:hover{background:#3a4554;color:#f0f6ff}.editora-content{flex:1;min-height:200px;padding:16px;outline:none;overflow-y:auto;line-height:1.6}.editora-theme-dark .editora-content{color:#ecf3ff;background:linear-gradient(180deg,var(--editora-dark-content) 0%,#1c232e 100%)}.editora-content:empty:before{content:attr(data-placeholder);color:#999;pointer-events:none}.editora-theme-dark .editora-content:empty:before{color:#8f9bb0}.editora-content h1{font-size:2em;margin:.67em 0;font-weight:600}.editora-content h2{font-size:1.5em;margin:.75em 0;font-weight:600}.editora-content h3{font-size:1.17em;margin:.83em 0;font-weight:600}.editora-content p{margin:1em 0}.editora-content ul,.editora-content ol{margin:1em 0;padding-left:2em}.editora-content a{color:#06c;text-decoration:underline}.editora-theme-dark .editora-content a{color:#4db8ff}.editora-content code{padding:2px 4px;background:#f5f5f5;border-radius:3px;font-family:Monaco,Menlo,Consolas,monospace;font-size:.9em}.editora-theme-dark .editora-content code{background:#1e1e1e}.editora-content pre{padding:12px;background:#f5f5f5;border-radius:4px;overflow-x:auto;margin:1em 0}.editora-theme-dark .editora-content pre{background:#1e1e1e}.editora-theme-dark .rte-code-block{background:linear-gradient(180deg,#212a36,#1b2430)!important;border-color:#4f5b70!important;color:#e7effc!important}.editora-theme-dark .rte-code-block code{color:#e7effc!important}.editora-theme-dark .rte-code-block:before{background:#111927!important;color:#dce8ff!important}.editora-theme-dark .rte-code-block .rte-code-copy{background:#2b3441!important;border-color:#5a667b!important;color:#dce8ff!important}.editora-content blockquote{margin:1em 0;padding-left:1em;border-left:4px solid #ddd;color:#666}.editora-theme-dark .editora-content blockquote{border-left-color:#3c3c3c;color:#9a9a9a}.editora-floating-toolbar{position:absolute;padding:4px;background:#fff;border:1px solid #ddd;border-radius:4px;box-shadow:0 2px 8px #00000026;z-index:1000}.editora-theme-dark .editora-floating-toolbar{background:#29323d;border-color:#4d596b;box-shadow:0 8px 20px #00000073}.editora-theme-dark .editora-statusbar{background:linear-gradient(180deg,#2c3440,#252d37);border-top-color:#3f4a5b;color:#d7deea}.editora-statusbar-item{white-space:nowrap}.editora-theme-dark .editora-statusbar-separator{color:#566275}.editora-editor[readonly] .editora-content{background:#fafafa;cursor:not-allowed}.editora-theme-dark.editora-editor[readonly] .editora-content{background:#1a1a1a}.editora-editor:focus-within{border-color:#06c;box-shadow:0 0 0 3px #0066cc1a}.editora-theme-dark.editora-editor:focus-within{border-color:#4db8ff;box-shadow:0 0 0 3px #4db8ff1a}.editora-editor[disabled]{opacity:.6;pointer-events:none}@media(max-width:768px){.editora-toolbar{padding:4px}.editora-toolbar-button{min-width:28px;min-height:28px;padding:4px 8px;font-size:12px}.editora-content{padding:12px}}.editora-content ::selection{background:#06c3}.editora-theme-dark .editora-content ::selection{background:#4db8ff33}.editora-content table{border-collapse:collapse;width:100%;margin:1em 0}.editora-content th,.editora-content td{border:1px solid #ddd;padding:8px 12px;text-align:left}.editora-theme-dark .editora-content th,.editora-theme-dark .editora-content td{border-color:#3c3c3c}.editora-content th{background:#f5f5f5;font-weight:600}.editora-theme-dark .editora-content th{background:#252526}.editora-content img{max-width:100%;height:auto;border-radius:4px;display:block}.editora-content video{max-width:100%;height:auto;border-radius:4px;display:block}.editora-editor.loading{opacity:.7;pointer-events:none}.editora-editor.loading:after{content:"";position:absolute;top:50%;left:50%;width:24px;height:24px;margin:-12px 0 0 -12px;border:3px solid #ddd;border-top-color:#06c;border-radius:50%;animation:editora-spin .8s linear infinite}@keyframes editora-spin{to{transform:rotate(360deg)}}.toolbar-container-wrapper{display:flex;align-items:center;background:#fff;border-bottom:1px solid #e0e0e0;padding:0;margin:0;width:100%;box-sizing:border-box;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,sans-serif;font-size:14px;line-height:1.5;position:relative}.toolbar-container-wrapper[data-toolbar-sticky=true]{position:sticky;top:0;z-index:999;box-shadow:0 2px 4px #0000001a}.toolbar-container-wrapper[data-toolbar-floating=true]{position:fixed;top:0;left:0;right:0;z-index:1000;box-shadow:0 4px 12px #00000026}.toolbar-container-wrapper[data-toolbar-position=bottom]{border-bottom:none;border-top:1px solid #e0e0e0}.toolbar-container-wrapper .toolbar-wrapper{display:flex;width:100%;padding:8px;gap:4px;flex-wrap:wrap;align-items:center}.toolbar-container-wrapper .toolbar{display:flex;width:100%;gap:4px;flex-wrap:wrap;align-items:center}.toolbar-container-wrapper .toolbar-container{display:flex;gap:4px;flex-wrap:wrap;align-items:center;flex:1;position:relative}.toolbar-container-wrapper .toolbar-item{display:flex;align-items:center;gap:2px}.toolbar-container-wrapper .toolbar-button{padding:6px 10px;border:1px solid #d1d5db;background:#fff;border-radius:4px;cursor:pointer;font-size:13px;display:flex;align-items:center;justify-content:center;gap:4px;transition:all .15s ease;min-height:32px;white-space:nowrap}.toolbar-container-wrapper .toolbar-button:hover{background-color:#f3f4f6;border-color:#9ca3af}.toolbar-container-wrapper .toolbar-button:active,.toolbar-container-wrapper .toolbar-button[data-active=true]{background-color:#06c;color:#fff;border-color:#0052a3;box-shadow:inset 0 1px 3px #0000001a}.toolbar-container-wrapper .toolbar-button:disabled{opacity:.5;cursor:not-allowed;background-color:#f9fafb}.toolbar-container-wrapper .toolbar-more-button{padding:6px 8px;font-size:16px;font-weight:500;line-height:1}.toolbar-container-wrapper .toolbar-separator{width:1px;height:24px;background-color:#d1d5db;margin:0 4px}.toolbar-container-wrapper .toolbar-icon{display:inline-flex;align-items:center;justify-content:center;width:18px;height:18px;flex-shrink:0}.toolbar-container-wrapper .toolbar-icon svg{width:100%;height:100%}.toolbar-container-wrapper .toolbar-dropdown{position:relative;display:flex;align-items:center}.toolbar-container-wrapper .toolbar-dropdown-arrow{font-size:10px;margin-left:2px;line-height:1}.toolbar-container-wrapper .toolbar-dropdown-menu{position:absolute;top:100%;left:0;background:#fff;border:1px solid #d1d5db;border-radius:6px;box-shadow:0 4px 12px #00000026;z-index:1000;min-width:160px;padding:4px 0;margin-top:4px;display:none}.toolbar-container-wrapper .toolbar-dropdown-menu.show{display:block}.toolbar-container-wrapper .toolbar-dropdown-item{display:block;width:100%;padding:8px 12px;border:none;background:transparent;text-align:left;cursor:pointer;font-size:13px;color:#1f2937;transition:background-color .15s ease;font-family:inherit}.toolbar-container-wrapper .toolbar-dropdown-item:hover{background-color:#f3f4f6}.toolbar-container-wrapper .toolbar-dropdown-item:active{background-color:#e5e7eb}.toolbar-container-wrapper .toolbar-input{padding:6px 8px;border:1px solid #d1d5db;border-radius:4px;font-size:13px;font-family:inherit;background-color:#fff;color:#1f2937;transition:all .15s ease}.toolbar-container-wrapper .toolbar-input:focus{outline:none;border-color:#06c;box-shadow:0 0 0 3px #0066cc1a;background-color:#fff}.toolbar-container-wrapper .toolbar-input::placeholder{color:#9ca3af}.toolbar-overflow-menu{animation:slideDown .2s ease-out}@keyframes slideDown{0%{opacity:0;transform:translateY(-8px)}to{opacity:1;transform:translateY(0)}}.toolbar-overflow-item{transition:background-color .15s ease}.floating-toolbar{user-select:none;-webkit-user-select:none;font-family:system-ui,-apple-system,sans-serif;font-size:14px;animation:fadeInUp .15s ease-out}@keyframes fadeInUp{0%{opacity:0;transform:translate(-50%) translateY(10px)}to{opacity:1;transform:translate(-50%) translateY(0)}}.floating-toolbar-btn{display:flex;align-items:center;justify-content:center;width:32px;height:32px;border:none;background:transparent;border-radius:4px;color:#495057;cursor:pointer;font-size:14px;font-weight:500;transition:all .15s ease;outline:none}.floating-toolbar-btn:hover{background:#f8f9fa;color:#212529}.floating-toolbar-btn:active{background:#e9ecef;transform:scale(.95)}.floating-toolbar-btn.floating-toolbar-toggle{color:#dc3545;font-weight:700}.floating-toolbar-btn.floating-toolbar-toggle:hover{background:#f8d7da;color:#721c24}.floating-toolbar-separator{width:1px;height:20px;background:#e1e5e9;margin:0 2px}@media(max-width:768px){.toolbar-container-wrapper .toolbar-button{padding:5px 8px;font-size:12px;min-height:28px}.toolbar-container-wrapper .toolbar-icon{width:16px;height:16px}.toolbar-container-wrapper .toolbar-dropdown-menu{min-width:140px}.toolbar-container-wrapper .toolbar-dropdown-item{padding:6px 10px;font-size:12px}.floating-toolbar{padding:4px;gap:2px}.floating-toolbar-btn{width:28px;height:28px;font-size:12px}}@media(max-width:480px){.toolbar-container-wrapper{padding:4px}.toolbar-container-wrapper .toolbar-wrapper{padding:4px;gap:2px}.toolbar-container-wrapper .toolbar-button{padding:4px 6px;font-size:11px;min-height:24px}.toolbar-container-wrapper .toolbar-icon{width:14px;height:14px}}.floating-toolbar{pointer-events:auto}.floating-toolbar{max-width:calc(100vw - 20px);overflow-x:auto}@media(prefers-color-scheme:dark){.floating-toolbar{background:#2d3748;border-color:#4a5568;color:#e2e8f0}.floating-toolbar-btn:hover{background:#4a5568;color:#f7fafc}.floating-toolbar-btn:active{background:#718096}.floating-toolbar-separator{background:#4a5568}}.rte-editor{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,sans-serif}.rte-toolbar-wrapper{border-radius:4px 4px 0 0}.rte-toolbar{display:flex;gap:4px;padding:8px;background:#f5f5f5;border:1px solid #ddd;border-bottom:none;border-radius:4px 4px 0 0;align-items:center;position:relative}.rte-toolbar-items-container{display:flex;gap:4px;flex-wrap:nowrap;align-items:center;flex:1}.rte-toolbar-item{position:relative;display:flex;align-items:center;white-space:nowrap}.rte-toolbar-group-items.font-size{display:flex;align-items:center;border:1px solid #ccc;.rte-toolbar-input.font-size{width:40px;padding:.25rem;text-align:center;font-size:14px;background:#fff;border:1px solid var(--rte-color-border-light);border-radius:var(--rte-radius-sm)}.rte-toolbar-button{border:none;border-radius:0}.rte-toolbar-item{&:first-child{border-right:1px solid #ccc;border-top-left-radius:3px;border-bottom-left-radius:3px}&:last-child{border-left:1px solid #ccc;border-top-right-radius:3px;border-bottom-right-radius:3px}}}.rte-toolbar-button{padding:6px 12px;border:1px solid #ccc;background:#fff;cursor:pointer;border-radius:3px;font-weight:600;font-size:14px;height:30px;display:flex;align-items:center;white-space:nowrap}.rte-toolbar-button:hover{background:#e9e9e9}.rte-toolbar-input{width:26px;padding:6px 8px;border:1px solid #ccc;border-radius:3px;font-size:14px;text-align:center}.rte-toolbar-dropdown{position:relative}.rte-toolbar-dropdown-menu{position:absolute;top:100%;left:0;background:#fff;border:1px solid #ccc;border-radius:3px;box-shadow:0 2px 8px #00000026;min-width:150px;z-index:1000;margin-top:2px}.rte-toolbar-dropdown-item{padding:8px 12px;cursor:pointer}.rte-toolbar-dropdown-item:hover{background:#f0f0f0}.rte-toolbar-more-button{padding:6px 10px;border:1px solid #ccc;background:#fff;cursor:pointer;border-radius:3px;font-weight:600;font-size:16px;height:30px;display:flex;align-items:center;justify-content:center;min-width:30px;transition:background-color .2s ease;margin-left:auto}.rte-toolbar-more-button:hover{background:#e9e9e9}.rte-toolbar-more-button.active{background:#ddd;border-color:#999}.rte-toolbar-expanded-row{display:flex;transform:scaleY(0);transform-origin:top;max-height:0;padding:0;overflow:hidden;opacity:0;transition:transform .25s ease,opacity .2s ease,max-height .25s ease}.rte-toolbar-expanded-row.show{transform:scaleY(1);max-height:200px;padding:1px 8px 8px;opacity:1;background:#f5f5f5;border:1px solid #ddd;border-top:none;gap:4px}.rte-content{font-size:16px;line-height:1.6}.rte-content.rte-content-empty:before,.rte-content:empty:before{content:attr(data-placeholder);color:var(--rte-color-text-muted, #6b7280);pointer-events:none}.rte-content p{margin:0 0 1em}.rte-content h1{font-size:2em;margin:.67em 0}.rte-content h2{font-size:1.5em;margin:.75em 0}.rte-content h3{font-size:1.17em;margin:.83em 0}.rte-content h4{font-size:1em;margin:1em 0}.rte-content h5{font-size:.83em;margin:1.17em 0}.rte-content h6{font-size:.67em;margin:1.33em 0}.rte-content ul,.rte-content ol{margin:1em 0;padding-left:2em}.rte-content code{background:#f4f4f4;padding:2px 6px;border-radius:3px;font-family:Courier New,monospace;font-size:.9em}.rte-content blockquote{border-left:4px solid #ddd;margin:1em 0;padding-left:1em;color:#666}.rte-content a{color:#06c;text-decoration:underline}.rte-content a:hover{color:#0052a3}.rte-dialog-overlay{position:fixed;inset:0;background:#00000080;display:flex;align-items:center;justify-content:center;z-index:10000}.rte-dialog-content{background:#fff;border-radius:8px;box-shadow:0 4px 20px #0000004d;max-width:400px;width:90%;max-height:90vh;overflow-y:auto}.rte-dialog-header{padding:16px 20px;border-bottom:1px solid #e0e0e0;display:flex;justify-content:space-between;align-items:center}.rte-dialog-header h3{margin:0;font-size:18px;font-weight:600;color:#333}.rte-dialog-close{background:none;border:none;font-size:24px;cursor:pointer;color:#666;padding:0;width:30px;height:30px;display:flex;align-items:center;justify-content:center}.rte-dialog-close:hover{color:#333}.rte-dialog-body{padding:20px}.rte-dialog-footer{padding:16px 20px;border-top:1px solid #e0e0e0;display:flex;justify-content:flex-end;gap:12px}.rte-btn{padding:8px 16px;border:1px solid #ccc;border-radius:4px;cursor:pointer;font-size:14px;font-weight:500;transition:all .2s}.rte-btn:hover{border-color:#999}.rte-btn-primary{background:#06c;color:#fff;border-color:#06c}.rte-btn-primary:hover{background:#0052a3;border-color:#0052a3}.rte-btn-secondary{background:#fff;color:#333}.rte-btn-secondary:hover{background:#f5f5f5}.rte-form-group{margin-bottom:16px}.rte-form-label{display:block;margin-bottom:6px;font-weight:500;color:#333;font-size:14px}.rte-form-input{width:100%;padding:8px 12px;border:1px solid #ccc;border-radius:4px;font-size:14px;box-sizing:border-box}.rte-form-input:focus{outline:none;border-color:#06c;box-shadow:0 0 0 2px #06c3}.rte-form-row{display:flex;gap:12px}.rte-form-row .rte-form-group{flex:1}.rte-color-preview{display:flex;align-items:center;gap:12px;margin-bottom:20px;padding:12px;background:#f8f9fa;border-radius:4px}.rte-color-sample{width:40px;height:40px;border-radius:4px;border:2px solid #ddd}.rte-color-value{font-family:monospace;font-size:14px;font-weight:500;color:#333}.rte-color-section{margin-bottom:20px}.rte-color-label{margin-bottom:8px;font-size:14px;font-weight:500}.rte-color-palette{display:grid;grid-template-columns:repeat(6,1fr);gap:8px;margin-bottom:16px}.rte-color-swatch{width:24px;height:24px;border:2px solid #ddd;border-radius:4px;cursor:pointer;transition:all .2s}.rte-color-swatch:hover{border-color:#999;transform:scale(1.1)}.rte-color-swatch.selected{border-color:#06c;box-shadow:0 0 0 2px #0066cc4d}.rte-custom-color{display:flex;align-items:center;gap:12px}.rte-color-input{width:60px;height:40px;border:2px solid #ddd;border-radius:4px;cursor:pointer}.rte-color-text-input{flex:1;padding:8px 12px;border:1px solid #ccc;border-radius:4px;font-family:monospace;font-size:14px}.rte-color-text-input:focus{outline:none;border-color:#06c;box-shadow:0 0 0 2px #06c3}.rte-iframe-preview{border:1px solid #ddd;border-radius:4px;overflow:hidden;background:#f8f9fa}.rte-iframe-preview iframe{display:block;border:none}.rte-size-presets{display:flex;flex-direction:column;gap:8px}.rte-radio-option{display:flex;align-items:flex-start;gap:8px;padding:8px;border:1px solid #e0e0e0;border-radius:4px;background:#fafbfc}.rte-radio-option:hover{background:#f1f3f4}.rte-radio-option input[type=radio]{margin-top:2px}.rte-radio-label{flex:1;line-height:1.4}.rte-content ul[data-type=checklist]{list-style:none;padding-left:0;margin:1em 0}.rte-content li[data-type=checklist-item]{position:relative;padding-left:2em;margin-bottom:.5em;line-height:1.6}.rte-content li[data-type=checklist-item]:before{content:"";position:absolute;left:0;top:.1em;width:1.2em;height:1.2em;border:2px solid #ccc;border-radius:3px;background:#fff;cursor:pointer;transition:all .2s ease}.rte-content li[data-type=checklist-item]:hover:before{border-color:#999}.rte-content li[data-type=checklist-item][data-checked=true]:before{background:#06c;border-color:#06c}.rte-content li[data-type=checklist-item][data-checked=true]:after{content:"✓";position:absolute;left:.36em;top:.12em;color:#fff;font-size:.9em;font-weight:700;pointer-events:none}.rte-content li[data-type=checklist-item][data-checked=true] p{text-decoration:line-through;color:#666}.editora-statusbar-container{display:flex;flex-direction:column}.rte-editor{.editora-statusbar-bottom{top:-32px}}.editora-statusbar-bottom{position:relative;border-left:1px solid rgb(221,221,221);border-right:1px solid rgb(221,221,221)}.editora-statusbar{display:flex;align-items:center;gap:12px;padding:6px 12px;background:#f5f5f5;border-top:1px solid #ddd;font-size:12px;color:#666}.editora-theme-dark .editora-statusbar{background:#252526;border-top-color:#3c3c3c;color:#9a9a9a}.editora-statusbar-top{border-top:none;border-bottom:1px solid #e0e0e0}.editora-statusbar-left{display:flex;align-items:center;gap:8px}.editora-statusbar-right{display:flex;align-items:center;gap:8px;margin-left:auto}.editora-statusbar-item{white-space:nowrap;padding:2px 4px}.editora-statusbar-separator{color:#ddd}.editora-theme-dark .editora-statusbar-separator{color:#3c3c3c}.editora-theme-dark .rte-content,.editora-theme-dark .rte-content h1,.editora-theme-dark .rte-content h2,.editora-theme-dark .rte-content h3,.editora-theme-dark .rte-content h4,.editora-theme-dark .rte-content h5,.editora-theme-dark .rte-content h6{color:#fff}.rte-inline-menu{position:fixed;z-index:1000;background:#fff;border:1px solid #ccc;border-radius:4px;box-shadow:0 2px 8px #00000026;min-width:120px;max-width:200px;pointer-events:auto}.rte-inline-menu-item{padding:8px 12px;cursor:pointer;font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;background-color:transparent}.rte-inline-menu-item:hover{background-color:#f5f5f5}.floating-toolbar{--rte-floating-toolbar-bg: #ffffff;--rte-floating-toolbar-border: #d7dee8;--rte-floating-toolbar-text: #364152;--rte-floating-toolbar-hover-bg: #f2f6fb;--rte-floating-toolbar-hover-text: #101828;--rte-floating-toolbar-active-bg: #e7eef7;--rte-floating-toolbar-separator: #d8e1ec;--rte-floating-toolbar-shadow: 0 10px 28px rgba(15, 23, 36, .16);user-select:none;-webkit-user-select:none;align-items:center;gap:4px;padding:6px;border-radius:8px;border:1px solid var(--rte-floating-toolbar-border);background:var(--rte-floating-toolbar-bg);color:var(--rte-floating-toolbar-text);box-shadow:var(--rte-floating-toolbar-shadow);pointer-events:auto;animation:rteFloatingToolbarIn .15s ease-out}.floating-toolbar-btn{display:inline-flex;align-items:center;justify-content:center;min-width:32px;height:32px;border:none;border-radius:6px;background:transparent;color:inherit;cursor:pointer;font-size:14px;font-weight:600;transition:background-color .15s ease,color .15s ease,transform .12s ease}.floating-toolbar-btn:hover{background:var(--rte-floating-toolbar-hover-bg);color:var(--rte-floating-toolbar-hover-text)}.floating-toolbar-btn:active{background:var(--rte-floating-toolbar-active-bg);transform:scale(.96)}.floating-toolbar-separator{width:1px;height:20px;margin:0 2px;background:var(--rte-floating-toolbar-separator)}@keyframes rteFloatingToolbarIn{0%{opacity:0;transform:translate(-50%) translateY(8px)}to{opacity:1;transform:translate(-50%) translateY(0)}}.editora-toolbar-group-button{display:flex;align-items:center;border-radius:var(--rte-radius);overflow:hidden;border:1px solid var(--rte-color-border-light);background:var(--rte-color-bg-secondary, #f9fafb);margin-right:.5rem;padding:0}.editora-toolbar-group-items{display:flex;align-items:center;gap:0}.editora-toolbar-group-button .editora-toolbar-button,.editora-toolbar-group-button .editora-toolbar-input{border-radius:0;border:none;margin:0;background:transparent;box-shadow:none}.editora-toolbar-group-button .editora-toolbar-button:first-child{border-radius:var(--rte-radius) 0 0 var(--rte-radius)}.editora-toolbar-group-button .editora-toolbar-button:last-child{border-radius:0 var(--rte-radius) var(--rte-radius) 0}.editora-toolbar-group-button .editora-toolbar-input{min-width:44px;width:44px;text-align:center;font-size:15px;background:#fff;border-left:1px solid var(--rte-color-border-light);border-right:1px solid var(--rte-color-border-light)}.editora-toolbar-group-button .editora-toolbar-button:active,.editora-toolbar-group-button .editora-toolbar-button:focus{background:#e5e7eb}.editora-toolbar-group-button .editora-toolbar-input:focus{outline:1.5px solid var(--rte-color-primary, #2563eb)}:root{--rte-color-primary: #007bff;--rte-color-primary-hover: #0056b3;--rte-color-secondary: #6c757d;--rte-color-success: #28a745;--rte-color-danger: #dc3545;--rte-color-warning: #ffc107;--rte-color-info: #17a2b8;--rte-color-text-primary: #212529;--rte-color-text-secondary: #6c757d;--rte-color-text-muted: #868e96;--rte-color-text-inverse: #ffffff;--rte-color-bg-primary: #ffffff;--rte-color-bg-secondary: #f8f9fa;--rte-color-bg-tertiary: #e9ecef;--rte-color-bg-hover: #f8f9fa;--rte-color-bg-active: #e9ecef;--rte-color-border: #dee2e6;--rte-color-border-light: #f8f9fa;--rte-color-border-focus: #007bff;--rte-shadow-sm: 0 1px 2px rgba(0, 0, 0, .05);--rte-shadow: 0 1px 3px rgba(0, 0, 0, .1), 0 1px 2px rgba(0, 0, 0, .06);--rte-shadow-lg: 0 10px 15px rgba(0, 0, 0, .1), 0 4px 6px rgba(0, 0, 0, .05);--rte-space-xs: .25rem;--rte-space-sm: .5rem;--rte-space-md: 1rem;--rte-space-lg: 1.5rem;--rte-space-xl: 2rem;--rte-space-xxl: 3rem;--rte-font-family-base: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;--rte-font-family-mono: "SFMono-Regular", Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;--rte-font-size-xs: .75rem;--rte-font-size-sm: .875rem;--rte-font-size-base: 1rem;--rte-font-size-lg: 1.125rem;--rte-font-size-xl: 1.25rem;--rte-font-size-xxl: 1.5rem;--rte-font-size-xxxl: 2rem;--rte-font-weight-normal: 400;--rte-font-weight-medium: 500;--rte-font-weight-semibold: 600;--rte-font-weight-bold: 700;--rte-line-height-tight: 1.25;--rte-line-height-normal: 1.5;--rte-line-height-relaxed: 1.75;--rte-radius-sm: .125rem;--rte-radius: .25rem;--rte-radius-md: .375rem;--rte-radius-lg: .5rem;--rte-radius-xl: .75rem;--rte-transition-fast: .15s ease-in-out;--rte-transition-normal: .25s ease-in-out;--rte-transition-slow: .35s ease-in-out;--rte-z-dropdown: 1000;--rte-z-sticky: 1020;--rte-z-modal: 1050;--rte-z-popover: 1060;--rte-z-tooltip: 1070}.rte-editor{font-family:var(--rte-font-family-base);font-size:var(--rte-font-size-base);line-height:var(--rte-line-height-normal);color:var(--rte-color-text-primary);background-color:var(--rte-color-bg-primary);border:1px solid var(--rte-color-border);border-radius:var(--rte-radius);box-shadow:var(--rte-shadow);transition:border-color var(--rte-transition-fast),box-shadow var(--rte-transition-fast)}.rte-editor:focus-within{border-color:var(--rte-color-border-focus);box-shadow:var(--rte-shadow),0 0 0 3px #007bff1a}.rte-toolbar{display:flex;align-items:center;padding:var(--rte-space-sm);border-bottom:1px solid var(--rte-color-border);background-color:var(--rte-color-bg-secondary);border-radius:var(--rte-radius) var(--rte-radius) 0 0;flex-wrap:wrap;gap:2px}.rte-toolbar-group{display:flex;align-items:center;border-radius:var(--rte-radius);overflow:hidden;border:1px solid var(--rte-color-border-light)}.rte-toolbar-button{display:flex;align-items:center;justify-content:center;width:2rem;height:2rem;padding:0;border:none;background:transparent;color:var(--rte-color-text-secondary);cursor:pointer;border-radius:var(--rte-radius-sm);transition:background-color var(--rte-transition-fast),color var(--rte-transition-fast);font-size:14px;line-height:1}.rte-toolbar-button svg,.editora-toolbar-button svg,.editora-toolbar-icon svg{flex-shrink:0;width:20px;height:20px;display:block;color:currentColor;fill:currentColor}.rte-toolbar-button:hover svg{opacity:.9}:is(.rte-toolbar-button[data-active=true],.editora-toolbar-button.active) svg{color:var(--rte-color-text-inverse)}.rte-toolbar-button:hover{background-color:var(--rte-color-bg-hover);color:var(--rte-color-text-primary)}.rte-toolbar-button:active,.rte-toolbar-button[data-active=true]{background-color:var(--rte-color-primary);color:var(--rte-color-text-inverse)}.rte-toolbar-button:disabled{opacity:.5;cursor:not-allowed}.rte-content{padding:var(--rte-space-md);min-height:200px;outline:none;overflow-wrap:break-word;word-wrap:break-word}.rte-content[contenteditable=true]{cursor:text}.rte-content h1,.rte-content h2,.rte-content h3,.rte-content h4,.rte-content h5,.rte-content h6{margin:var(--rte-space-lg) 0 var(--rte-space-md) 0;font-weight:var(--rte-font-weight-semibold);line-height:var(--rte-line-height-tight);color:var(--rte-color-text-primary)}.rte-content h1{font-size:var(--rte-font-size-xxxl)}.rte-content h2{font-size:var(--rte-font-size-xxl)}.rte-content h3{font-size:var(--rte-font-size-xl)}.rte-content h4{font-size:var(--rte-font-size-lg)}.rte-content h5{font-size:var(--rte-font-size-base)}.rte-content h6{font-size:var(--rte-font-size-sm)}.rte-content p{margin:var(--rte-space-md) 0}.rte-content blockquote{margin:var(--rte-space-lg) 0;padding:var(--rte-space-md);padding-left:var(--rte-space-lg);border-left:4px solid var(--rte-color-primary);background-color:var(--rte-color-bg-secondary);font-style:italic;color:var(--rte-color-text-secondary)}.rte-content ul,.rte-content ol{margin:var(--rte-space-md) 0;padding-left:var(--rte-space-xl)}.rte-content li{margin:var(--rte-space-xs) 0}.rte-content ul{list-style-type:disc}.rte-content ol{list-style-type:decimal}.rte-link{color:var(--rte-color-primary);text-decoration:none;transition:color var(--rte-transition-fast)}.rte-link:hover{color:var(--rte-color-primary-hover);text-decoration:underline}.rte-content code{font-family:var(--rte-font-family-mono);font-size:.875em;background-color:var(--rte-color-bg-tertiary);padding:.125rem .25rem;border-radius:var(--rte-radius-sm);color:var(--rte-color-danger)}.rte-content::selection{background-color:#007bff33}.rte-content:empty:before,.rte-content.rte-content-empty:before{content:attr(data-placeholder);color:var(--rte-color-text-muted);pointer-events:none}.rte-content:focus{outline:none}.rte-sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.rte-text-left{text-align:left}.rte-text-center{text-align:center}.rte-text-right{text-align:right}.rte-text-justify{text-align:justify}.rte-table td,.rte-table th,table td,table th{border:1px solid #ddd;padding:8px 12px;min-width:80px;vertical-align:top;position:relative;-webkit-user-select:none;user-select:none}.table-toolbar{background:#fff;border:1px solid #d0d0d0;border-radius:4px;box-shadow:0 2px 8px #0000001a;padding:4px;display:flex;align-items:center;gap:0;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,sans-serif;min-width:max-content}.rte-table,table{border-collapse:collapse;width:100%;margin:1rem 0;border:1px solid #ddd;font-size:14px;line-height:1.4;position:relative}.rte-table td,.rte-table th,table td,table th{border:1px solid #ddd;padding:8px 12px;min-width:80px;vertical-align:top;position:relative;user-select:none}.rte-table td:focus,.rte-table th:focus,table td:focus,table th:focus{outline:2px solid #007acc;outline-offset:-2px}.rte-table th,table th{background-color:#f8f9fa;font-weight:600;text-align:left}.rte-table td p,table td p{margin:0;padding:0}.rte-table td p:empty:before,table td p:empty:before{content:"​";display:inline-block}.rte-table td[contenteditable]:empty:before,table td[contenteditable]:empty:before{content:"Type here...";color:#999;font-style:italic;pointer-events:none}.rte-table tr:hover,table tr:hover{background-color:#f8f9fa}.rte-table td.selected,table td.selected{background-color:#e3f2fd;border-color:#2196f3}.table-toolbar{background:#fff;border:1px solid #d0d0d0;border-radius:4px;box-shadow:0 2px 8px #0000001a;padding:4px;display:flex;align-items:center;gap:0;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,sans-serif;min-width:max-content}.toolbar-section{display:flex;align-items:center;gap:2px}.toolbar-divider{width:1px;height:20px;background:#e0e0e0;margin:0 4px}.toolbar-icon-btn{display:flex;align-items:center;justify-content:center;width:28px;height:28px;padding:0;border:1px solid transparent;background:transparent;cursor:pointer;color:#333;border-radius:3px;transition:all .2s ease;flex-shrink:0;font-size:14px;line-height:1}.toolbar-icon-btn svg{width:16px;height:16px}.toolbar-icon-btn:hover:not(:disabled){background:#f0f0f0;border-color:#d0d0d0;color:#06c}.toolbar-icon-btn:active:not(:disabled){background:#e8f0ff;border-color:#06c;transform:scale(.95)}.toolbar-icon-btn:disabled{opacity:.4;cursor:not-allowed;color:#ccc}.toolbar-icon-btn-danger{color:#d32f2f}.toolbar-icon-btn-danger:hover:not(:disabled){background:#fff3f3;border-color:#fcc;color:#d32f2f}.toolbar-icon-btn-danger:active:not(:disabled){background:#ffebee}.toolbar-icon-btn-delete{color:#d32f2f}.toolbar-icon-btn-delete:hover:not(:disabled){background:#fff3f3;border-color:#fcc;color:#d32f2f}.toolbar-icon-btn-delete:active:not(:disabled){background:#ffebee}.resize-handle{opacity:0;transition:all .15s ease}.resize-handle:hover{opacity:1}td:hover>.resize-handle,th:hover>.resize-handle{opacity:1}.table-resize-handle{position:absolute;bottom:-4px;right:-4px;width:12px;height:12px;background:transparent;cursor:nwse-resize;z-index:10;transition:background .15s ease}.table-resize-handle:after{content:"";position:absolute;bottom:0;right:0;width:8px;height:8px;background:#0066cc4d;border-bottom:2px solid #0066cc;border-right:2px solid #0066cc;border-radius:0 0 2px;opacity:0;transition:opacity .15s ease}.table-resize-handle:hover:after{opacity:1}.rte-table:hover .table-resize-handle:after,table:hover .table-resize-handle:after{opacity:1}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table,table){border-color:#607088;background:#24303c;color:#e6eefb}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table td,.rte-table th,table td,table th){border-color:#607088;color:#e6eefb}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table th,table th){background:linear-gradient(180deg,#3b4553,#333d4a);color:#f3f8ff}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table tr:hover,table tr:hover){background-color:#58a6ff1f}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table td.selected,table td.selected){background-color:#58a6ff47;border-color:#79beff}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table td[contenteditable]:empty:before,table td[contenteditable]:empty:before){color:#94a3b8}:is([data-theme=dark],.dark,.editora-theme-dark) .table-toolbar{background:linear-gradient(180deg,#2f3844,#2a323c);border-color:#4d596b;box-shadow:0 8px 20px #00000073}.table-toolbar.rte-theme-dark{background:linear-gradient(180deg,#2f3844,#2a323c);border-color:#4d596b;box-shadow:0 8px 20px #00000073}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-divider{background:#4d596b}.table-toolbar.rte-theme-dark .toolbar-divider{background:#4d596b}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn{color:#d7deea;border-color:transparent}.table-toolbar.rte-theme-dark .toolbar-icon-btn{color:#d7deea;border-color:transparent}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg{color:currentColor;fill:currentColor}.table-toolbar.rte-theme-dark .toolbar-icon-btn svg{color:currentColor;fill:currentColor}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [stroke="#000" i],:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [stroke="#000000" i],:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [stroke=black i]{stroke:currentColor!important}.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [stroke="#000" i],.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [stroke="#000000" i],.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [stroke=black i]{stroke:currentColor!important}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [fill="#000" i],:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [fill="#000000" i],:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [fill=black i]{fill:currentColor!important}.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [fill="#000" i],.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [fill="#000000" i],.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [fill=black i]{fill:currentColor!important}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn:hover:not(:disabled){background:#3a4554;border-color:#607088;color:#f3f8ff}.table-toolbar.rte-theme-dark .toolbar-icon-btn:hover:not(:disabled){background:#3a4554;border-color:#607088;color:#f3f8ff}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn:active:not(:disabled){background:#4a95de;border-color:#67adf4;color:#0f1b2a}.table-toolbar.rte-theme-dark .toolbar-icon-btn:active:not(:disabled){background:#4a95de;border-color:#67adf4;color:#0f1b2a}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn:disabled{color:#7f8ca1}.table-toolbar.rte-theme-dark .toolbar-icon-btn:disabled{color:#7f8ca1}@media(max-width:768px){.rte-table,table{font-size:12px}.rte-table td,.rte-table th,table td,table th{padding:4px 6px;min-width:60px}.table-toolbar{padding:3px;gap:0;max-width:90vw;overflow-x:auto}.toolbar-icon-btn{width:26px;height:26px}.toolbar-divider{height:18px}}@media print{.rte-table,table{border:1px solid #000}.rte-table td,.rte-table th,table td,table th{border:1px solid #000;padding:4px}.table-toolbar{display:none}}
.editora-editor{display:flex;flex-direction:column;border:1px solid #ddd;border-radius:4px;background:#fff;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,sans-serif;font-size:14px;overflow:hidden}.editora-editor *{box-sizing:border-box}.editora-theme-light{background:#fff;color:#333}.editora-theme-dark{--editora-dark-toolbar-bg-start: #353d48;--editora-dark-toolbar-bg-end: #2d3540;--editora-dark-button-bg-start: #46505f;--editora-dark-button-bg-end: #3b4553;--editora-dark-button-hover-start: #525d6d;--editora-dark-button-hover-end: #465262;--editora-dark-button-active-start: #5eaaf6;--editora-dark-button-active-end: #4a95de;--editora-dark-border: #475263;--editora-dark-border-strong: #566275;--editora-dark-text: #e1e9f5;--editora-dark-text-strong: #f3f7ff;--editora-dark-text-muted: #aeb9cc;--editora-dark-surface: #1d242d;--editora-dark-content: #1f2732;background:linear-gradient(180deg,#1b2330,#1c2430);color:var(--editora-dark-text);border-color:var(--editora-dark-border)}.editora-toolbar{display:flex;align-items:center;gap:4px;padding:8px;background:#f5f5f5;border-bottom:1px solid #ddd;flex-wrap:wrap}.editora-theme-dark .editora-toolbar{background:linear-gradient(180deg,var(--editora-dark-toolbar-bg-start) 0%,var(--editora-dark-toolbar-bg-end) 100%);border-bottom-color:var(--editora-dark-border);box-shadow:inset 0 1px #ffffff0d}.editora-toolbar-sticky{position:sticky;top:0;z-index:100;position:-webkit-sticky}.editora-toolbar-group{display:flex;align-items:center;gap:2px}.editora-toolbar-button{padding:6px 12px;border:1px solid #ccc;background:#fff;cursor:pointer;border-radius:3px;font-weight:600;font-size:14px;height:30px;display:flex;align-items:center;white-space:nowrap}.editora-toolbar-group-button{display:flex;align-items:center}.editora-toolbar-input.font-size{width:40px;padding:.25rem;text-align:center;font-size:14px;background:#fff;border:1px solid var(--rte-color-border-light);border-radius:var(--rte-radius-sm)}.editora-toolbar-group-items{display:flex;align-items:center;border:1px solid #ccc;.editora-toolbar-button{border:none;border-radius:0;&:first-child{border-right:1px solid #ccc;border-top-left-radius:3px;border-bottom-left-radius:3px}&:last-child{border-left:1px solid #ccc;border-top-right-radius:3px;border-bottom-right-radius:3px}}}.editora-theme-dark .editora-toolbar-button{background:linear-gradient(180deg,var(--editora-dark-button-bg-start) 0%,var(--editora-dark-button-bg-end) 100%);border-color:var(--editora-dark-border-strong);color:var(--editora-dark-text);box-shadow:inset 0 1px #ffffff14,0 1px 1px #00000059}.editora-theme-dark .editora-toolbar-group-items{border-color:var(--editora-dark-border-strong);background:linear-gradient(180deg,var(--editora-dark-button-bg-start) 0%,var(--editora-dark-button-bg-end) 100%)}.editora-theme-dark .editora-toolbar-group-items .editora-toolbar-button:first-child{border-right-color:#566275}.editora-theme-dark .editora-toolbar-group-items .editora-toolbar-button:last-child{border-left-color:#566275}.editora-theme-dark .editora-toolbar-input.font-size{background-color:#2e3642;color:var(--editora-dark-text-strong);border-color:var(--editora-dark-border-strong);caret-color:var(--editora-dark-text-strong)}.editora-theme-dark .editora-toolbar-input.font-size::placeholder{color:var(--editora-dark-text-strong);opacity:1}.editora-toolbar-button:hover{background:#e0e0e0;border-color:#ccc}.editora-theme-dark .editora-toolbar-button:hover{background:linear-gradient(180deg,var(--editora-dark-button-hover-start) 0%,var(--editora-dark-button-hover-end) 100%);border-color:#66748a;color:var(--editora-dark-text-strong)}.editora-toolbar-button:active,.editora-toolbar-button.active{background:#d0d0d0;border-color:#999}.editora-theme-dark .editora-toolbar-button:active,.editora-theme-dark .editora-toolbar-button.active{background:linear-gradient(180deg,var(--editora-dark-button-active-start) 0%,var(--editora-dark-button-active-end) 100%);border-color:#67adf4;color:#0f1b2a}.editora-theme-dark .editora-toolbar-button:disabled{background:#313946;border-color:#424d5e;color:#7f8ca1}.editora-theme-dark .editora-toolbar-button[data-command=insertTable],.editora-theme-dark .editora-toolbar-button[data-command=print],.editora-theme-dark .editora-toolbar-button[data-command=toggleSpellCheck],.editora-theme-dark .editora-toolbar-button[data-command=toggleA11yChecker],.editora-theme-dark .editora-toolbar-button[data-command=setDirectionLTR],.editora-theme-dark .editora-toolbar-button[data-command=setDirectionRTL]{color:#f1f6ff}.editora-toolbar-button:disabled{opacity:.5;cursor:not-allowed}.editora-toolbar-icon{display:inline-flex;align-items:center;justify-content:center;width:24px;height:24px;line-height:1}.editora-toolbar-button svg,.editora-toolbar-icon svg{width:20px;height:20px;display:block;color:currentColor;fill:currentColor}.editora-theme-dark .editora-toolbar-icon,.editora-theme-dark .editora-toolbar-icon *{color:inherit}.editora-theme-dark :is(.editora-toolbar-button,.editora-toolbar-icon) svg :is([stroke="#000" i],[stroke="#000000" i],[stroke=black i],[stroke="#0f0f0f" i],[stroke="#111111" i],[style*="stroke:#000" i],[style*="stroke: #000" i],[style*="stroke:black" i],[style*="stroke: black" i],[style*="stroke:#0f0f0f" i],[style*="stroke: #0f0f0f" i]){stroke:currentColor!important}.editora-theme-dark :is(.editora-toolbar-button,.editora-toolbar-icon) svg :is([fill="#000" i],[fill="#000000" i],[fill=black i],[fill="#0f0f0f" i],[fill="#111111" i],[style*="fill:#000" i],[style*="fill: #000" i],[style*="fill:black" i],[style*="fill: black" i],[style*="fill:#0f0f0f" i],[style*="fill: #0f0f0f" i]){fill:currentColor!important}.editora-toolbar-separator{width:1px;height:24px;background:#ddd;margin:0 4px}.editora-theme-dark .editora-toolbar-separator{background:#4d596b}.editora-toolbar-dropdown{position:relative}.editora-toolbar-dropdown-menu{position:absolute;top:100%;left:0;min-width:150px;margin-top:4px;padding:4px 0;background:#fff;border:1px solid #ddd;border-radius:4px;box-shadow:0 2px 8px #00000026;z-index:1000}.editora-theme-dark .editora-toolbar-dropdown-menu{background:#29323d;border-color:#4d596b;box-shadow:0 8px 20px #00000073}.editora-toolbar-dropdown-item{display:block;width:100%;padding:8px 12px;border:none;background:transparent;color:#333;text-align:left;cursor:pointer;font-size:13px;transition:background .15s ease}.editora-theme-dark .editora-toolbar-dropdown-item{color:#d7deea}.editora-toolbar-dropdown-item:hover{background:#f5f5f5}.editora-theme-dark .editora-toolbar-dropdown-item:hover{background:#3a4554;color:#f0f6ff}.editora-content{flex:1;min-height:200px;padding:16px;outline:none;overflow-y:auto;line-height:1.6}.editora-theme-dark .editora-content{color:#ecf3ff;background:linear-gradient(180deg,var(--editora-dark-content) 0%,#1c232e 100%)}.editora-content:empty:before{content:attr(data-placeholder);color:#999;pointer-events:none}.editora-theme-dark .editora-content:empty:before{color:#8f9bb0}.editora-content h1{font-size:2em;margin:.67em 0;font-weight:600}.editora-content h2{font-size:1.5em;margin:.75em 0;font-weight:600}.editora-content h3{font-size:1.17em;margin:.83em 0;font-weight:600}.editora-content p{margin:1em 0}.editora-content ul,.editora-content ol{margin:1em 0;padding-left:2em}.editora-content a{color:#06c;text-decoration:underline}.editora-theme-dark .editora-content a{color:#4db8ff}.editora-content code{padding:2px 4px;background:#f5f5f5;border-radius:3px;font-family:Monaco,Menlo,Consolas,monospace;font-size:.9em}.editora-theme-dark .editora-content code{background:#1e1e1e}.editora-content pre{padding:12px;background:#f5f5f5;border-radius:4px;overflow-x:auto;margin:1em 0}.editora-theme-dark .editora-content pre{background:#1e1e1e}.editora-theme-dark .rte-code-block{background:linear-gradient(180deg,#212a36,#1b2430)!important;border-color:#4f5b70!important;color:#e7effc!important}.editora-theme-dark .rte-code-block code{color:#e7effc!important}.editora-theme-dark .rte-code-block:before{background:#111927!important;color:#dce8ff!important}.editora-theme-dark .rte-code-block .rte-code-copy{background:#2b3441!important;border-color:#5a667b!important;color:#dce8ff!important}.editora-content blockquote{margin:1em 0;padding-left:1em;border-left:4px solid #ddd;color:#666}.editora-theme-dark .editora-content blockquote{border-left-color:#3c3c3c;color:#9a9a9a}.editora-floating-toolbar{position:absolute;padding:4px;background:#fff;border:1px solid #ddd;border-radius:4px;box-shadow:0 2px 8px #00000026;z-index:1000}.editora-theme-dark .editora-floating-toolbar{background:#29323d;border-color:#4d596b;box-shadow:0 8px 20px #00000073}.editora-theme-dark .editora-statusbar{background:linear-gradient(180deg,#2c3440,#252d37);border-top-color:#3f4a5b;color:#d7deea}.editora-statusbar-item{white-space:nowrap}.editora-theme-dark .editora-statusbar-separator{color:#566275}.editora-editor[readonly] .editora-content{background:#fafafa;cursor:not-allowed}.editora-theme-dark.editora-editor[readonly] .editora-content{background:#1a1a1a}.editora-editor:focus-within{border-color:#06c;box-shadow:0 0 0 3px #0066cc1a}.editora-theme-dark.editora-editor:focus-within{border-color:#4db8ff;box-shadow:0 0 0 3px #4db8ff1a}.editora-editor[disabled]{opacity:.6;pointer-events:none}@media(max-width:768px){.editora-toolbar{padding:4px}.editora-toolbar-button{min-width:28px;min-height:28px;padding:4px 8px;font-size:12px}.editora-content{padding:12px}}.editora-content ::selection{background:#06c3}.editora-theme-dark .editora-content ::selection{background:#4db8ff33}.editora-content table{border-collapse:collapse;width:100%;margin:1em 0}.editora-content th,.editora-content td{border:1px solid #ddd;padding:8px 12px;text-align:left}.editora-theme-dark .editora-content th,.editora-theme-dark .editora-content td{border-color:#3c3c3c}.editora-content th{background:#f5f5f5;font-weight:600}.editora-theme-dark .editora-content th{background:#252526}.editora-content img{max-width:100%;height:auto;border-radius:4px;display:block}.editora-content video{max-width:100%;height:auto;border-radius:4px;display:block}.editora-editor.loading{opacity:.7;pointer-events:none}.editora-editor.loading:after{content:"";position:absolute;top:50%;left:50%;width:24px;height:24px;margin:-12px 0 0 -12px;border:3px solid #ddd;border-top-color:#06c;border-radius:50%;animation:editora-spin .8s linear infinite}@keyframes editora-spin{to{transform:rotate(360deg)}}.toolbar-container-wrapper{display:flex;align-items:center;background:#fff;border-bottom:1px solid #e0e0e0;padding:0;margin:0;width:100%;box-sizing:border-box;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,sans-serif;font-size:14px;line-height:1.5;position:relative}.toolbar-container-wrapper[data-toolbar-sticky=true]{position:sticky;top:0;z-index:999;box-shadow:0 2px 4px #0000001a}.toolbar-container-wrapper[data-toolbar-floating=true]{position:fixed;top:0;left:0;right:0;z-index:1000;box-shadow:0 4px 12px #00000026}.toolbar-container-wrapper[data-toolbar-position=bottom]{border-bottom:none;border-top:1px solid #e0e0e0}.toolbar-container-wrapper .toolbar-wrapper{display:flex;width:100%;padding:8px;gap:4px;flex-wrap:wrap;align-items:center}.toolbar-container-wrapper .toolbar{display:flex;width:100%;gap:4px;flex-wrap:wrap;align-items:center}.toolbar-container-wrapper .toolbar-container{display:flex;gap:4px;flex-wrap:wrap;align-items:center;flex:1;position:relative}.toolbar-container-wrapper .toolbar-item{display:flex;align-items:center;gap:2px}.toolbar-container-wrapper .toolbar-button{padding:6px 10px;border:1px solid #d1d5db;background:#fff;border-radius:4px;cursor:pointer;font-size:13px;display:flex;align-items:center;justify-content:center;gap:4px;transition:all .15s ease;min-height:32px;white-space:nowrap}.toolbar-container-wrapper .toolbar-button:hover{background-color:#f3f4f6;border-color:#9ca3af}.toolbar-container-wrapper .toolbar-button:active,.toolbar-container-wrapper .toolbar-button[data-active=true]{background-color:#06c;color:#fff;border-color:#0052a3;box-shadow:inset 0 1px 3px #0000001a}.toolbar-container-wrapper .toolbar-button:disabled{opacity:.5;cursor:not-allowed;background-color:#f9fafb}.toolbar-container-wrapper .toolbar-more-button{padding:6px 8px;font-size:16px;font-weight:500;line-height:1}.toolbar-container-wrapper .toolbar-separator{width:1px;height:24px;background-color:#d1d5db;margin:0 4px}.toolbar-container-wrapper .toolbar-icon{display:inline-flex;align-items:center;justify-content:center;width:18px;height:18px;flex-shrink:0}.toolbar-container-wrapper .toolbar-icon svg{width:100%;height:100%}.toolbar-container-wrapper .toolbar-dropdown{position:relative;display:flex;align-items:center}.toolbar-container-wrapper .toolbar-dropdown-arrow{font-size:10px;margin-left:2px;line-height:1}.toolbar-container-wrapper .toolbar-dropdown-menu{position:absolute;top:100%;left:0;background:#fff;border:1px solid #d1d5db;border-radius:6px;box-shadow:0 4px 12px #00000026;z-index:1000;min-width:160px;padding:4px 0;margin-top:4px;display:none}.toolbar-container-wrapper .toolbar-dropdown-menu.show{display:block}.toolbar-container-wrapper .toolbar-dropdown-item{display:block;width:100%;padding:8px 12px;border:none;background:transparent;text-align:left;cursor:pointer;font-size:13px;color:#1f2937;transition:background-color .15s ease;font-family:inherit}.toolbar-container-wrapper .toolbar-dropdown-item:hover{background-color:#f3f4f6}.toolbar-container-wrapper .toolbar-dropdown-item:active{background-color:#e5e7eb}.toolbar-container-wrapper .toolbar-input{padding:6px 8px;border:1px solid #d1d5db;border-radius:4px;font-size:13px;font-family:inherit;background-color:#fff;color:#1f2937;transition:all .15s ease}.toolbar-container-wrapper .toolbar-input:focus{outline:none;border-color:#06c;box-shadow:0 0 0 3px #0066cc1a;background-color:#fff}.toolbar-container-wrapper .toolbar-input::placeholder{color:#9ca3af}.toolbar-overflow-menu{animation:slideDown .2s ease-out}@keyframes slideDown{0%{opacity:0;transform:translateY(-8px)}to{opacity:1;transform:translateY(0)}}.toolbar-overflow-item{transition:background-color .15s ease}.floating-toolbar{user-select:none;-webkit-user-select:none;font-family:system-ui,-apple-system,sans-serif;font-size:14px;animation:fadeInUp .15s ease-out}@keyframes fadeInUp{0%{opacity:0;transform:translate(-50%) translateY(10px)}to{opacity:1;transform:translate(-50%) translateY(0)}}.floating-toolbar-btn{display:flex;align-items:center;justify-content:center;width:32px;height:32px;border:none;background:transparent;border-radius:4px;color:#495057;cursor:pointer;font-size:14px;font-weight:500;transition:all .15s ease;outline:none}.floating-toolbar-btn:hover{background:#f8f9fa;color:#212529}.floating-toolbar-btn:active{background:#e9ecef;transform:scale(.95)}.floating-toolbar-btn.floating-toolbar-toggle{color:#dc3545;font-weight:700}.floating-toolbar-btn.floating-toolbar-toggle:hover{background:#f8d7da;color:#721c24}.floating-toolbar-separator{width:1px;height:20px;background:#e1e5e9;margin:0 2px}@media(max-width:768px){.toolbar-container-wrapper .toolbar-button{padding:5px 8px;font-size:12px;min-height:28px}.toolbar-container-wrapper .toolbar-icon{width:16px;height:16px}.toolbar-container-wrapper .toolbar-dropdown-menu{min-width:140px}.toolbar-container-wrapper .toolbar-dropdown-item{padding:6px 10px;font-size:12px}.floating-toolbar{padding:4px;gap:2px}.floating-toolbar-btn{width:28px;height:28px;font-size:12px}}@media(max-width:480px){.toolbar-container-wrapper{padding:4px}.toolbar-container-wrapper .toolbar-wrapper{padding:4px;gap:2px}.toolbar-container-wrapper .toolbar-button{padding:4px 6px;font-size:11px;min-height:24px}.toolbar-container-wrapper .toolbar-icon{width:14px;height:14px}}.floating-toolbar{pointer-events:auto}.floating-toolbar{max-width:calc(100vw - 20px);overflow-x:auto}@media(prefers-color-scheme:dark){.floating-toolbar{background:#2d3748;border-color:#4a5568;color:#e2e8f0}.floating-toolbar-btn:hover{background:#4a5568;color:#f7fafc}.floating-toolbar-btn:active{background:#718096}.floating-toolbar-separator{background:#4a5568}}.rte-editor{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,sans-serif}.rte-toolbar-wrapper{border-radius:4px 4px 0 0}.rte-toolbar{display:flex;gap:4px;padding:8px;background:#f5f5f5;border:1px solid #ddd;border-bottom:none;border-radius:4px 4px 0 0;align-items:center;position:relative}.rte-toolbar-items-container{display:flex;gap:4px;flex-wrap:nowrap;align-items:center;flex:1}.rte-toolbar-item{position:relative;display:flex;align-items:center;white-space:nowrap}.rte-toolbar-group-items.font-size{display:flex;align-items:center;border:1px solid #ccc;.rte-toolbar-input.font-size{width:40px;padding:.25rem;text-align:center;font-size:14px;background:#fff;border:1px solid var(--rte-color-border-light);border-radius:var(--rte-radius-sm)}.rte-toolbar-button{border:none;border-radius:0}.rte-toolbar-item{&:first-child{border-right:1px solid #ccc;border-top-left-radius:3px;border-bottom-left-radius:3px}&:last-child{border-left:1px solid #ccc;border-top-right-radius:3px;border-bottom-right-radius:3px}}}.rte-toolbar-button{padding:6px 12px;border:1px solid #ccc;background:#fff;cursor:pointer;border-radius:3px;font-weight:600;font-size:14px;height:30px;display:flex;align-items:center;white-space:nowrap}.rte-toolbar-button:hover{background:#e9e9e9}.rte-toolbar-input{width:26px;padding:6px 8px;border:1px solid #ccc;border-radius:3px;font-size:14px;text-align:center}.rte-toolbar-dropdown{position:relative}.rte-toolbar-dropdown-menu{position:absolute;top:100%;left:0;background:#fff;border:1px solid #ccc;border-radius:3px;box-shadow:0 2px 8px #00000026;min-width:150px;z-index:1000;margin-top:2px}.rte-toolbar-dropdown-item{padding:8px 12px;cursor:pointer}.rte-toolbar-dropdown-item:hover{background:#f0f0f0}.rte-toolbar-more-button{padding:6px 10px;border:1px solid #ccc;background:#fff;cursor:pointer;border-radius:3px;font-weight:600;font-size:16px;height:30px;display:flex;align-items:center;justify-content:center;min-width:30px;transition:background-color .2s ease;margin-left:auto}.rte-toolbar-more-button:hover{background:#e9e9e9}.rte-toolbar-more-button.active{background:#ddd;border-color:#999}.rte-toolbar-expanded-row{display:flex;transform:scaleY(0);transform-origin:top;max-height:0;padding:0;overflow:hidden;opacity:0;transition:transform .25s ease,opacity .2s ease,max-height .25s ease}.rte-toolbar-expanded-row.show{transform:scaleY(1);max-height:200px;padding:1px 8px 8px;opacity:1;background:#f5f5f5;border:1px solid #ddd;border-top:none;gap:4px}.rte-content{font-size:16px;line-height:1.6}.rte-content.rte-content-empty:before,.rte-content:empty:before{content:attr(data-placeholder);color:var(--rte-color-text-muted, #6b7280);pointer-events:none}.rte-content p{margin:0 0 1em}.rte-content h1{font-size:2em;margin:.67em 0}.rte-content h2{font-size:1.5em;margin:.75em 0}.rte-content h3{font-size:1.17em;margin:.83em 0}.rte-content h4{font-size:1em;margin:1em 0}.rte-content h5{font-size:.83em;margin:1.17em 0}.rte-content h6{font-size:.67em;margin:1.33em 0}.rte-content ul,.rte-content ol{margin:1em 0;padding-left:2em}.rte-content code{background:#f4f4f4;padding:2px 6px;border-radius:3px;font-family:Courier New,monospace;font-size:.9em}.rte-content blockquote{border-left:4px solid #ddd;margin:1em 0;padding-left:1em;color:#666}.rte-content a{color:#06c;text-decoration:underline}.rte-content a:hover{color:#0052a3}.rte-dialog-overlay{position:fixed;inset:0;background:#00000080;display:flex;align-items:center;justify-content:center;z-index:10000}.rte-dialog-content{background:#fff;border-radius:8px;box-shadow:0 4px 20px #0000004d;max-width:400px;width:90%;max-height:90vh;overflow-y:auto}.rte-dialog-header{padding:16px 20px;border-bottom:1px solid #e0e0e0;display:flex;justify-content:space-between;align-items:center}.rte-dialog-header h3{margin:0;font-size:18px;font-weight:600;color:#333}.rte-dialog-close{background:none;border:none;font-size:24px;cursor:pointer;color:#666;padding:0;width:30px;height:30px;display:flex;align-items:center;justify-content:center}.rte-dialog-close:hover{color:#333}.rte-dialog-body{padding:20px}.rte-dialog-footer{padding:16px 20px;border-top:1px solid #e0e0e0;display:flex;justify-content:flex-end;gap:12px}.rte-btn{padding:8px 16px;border:1px solid #ccc;border-radius:4px;cursor:pointer;font-size:14px;font-weight:500;transition:all .2s}.rte-btn:hover{border-color:#999}.rte-btn-primary{background:#06c;color:#fff;border-color:#06c}.rte-btn-primary:hover{background:#0052a3;border-color:#0052a3}.rte-btn-secondary{background:#fff;color:#333}.rte-btn-secondary:hover{background:#f5f5f5}.rte-form-group{margin-bottom:16px}.rte-form-label{display:block;margin-bottom:6px;font-weight:500;color:#333;font-size:14px}.rte-form-input{width:100%;padding:8px 12px;border:1px solid #ccc;border-radius:4px;font-size:14px;box-sizing:border-box}.rte-form-input:focus{outline:none;border-color:#06c;box-shadow:0 0 0 2px #06c3}.rte-form-row{display:flex;gap:12px}.rte-form-row .rte-form-group{flex:1}.rte-color-preview{display:flex;align-items:center;gap:12px;margin-bottom:20px;padding:12px;background:#f8f9fa;border-radius:4px}.rte-color-sample{width:40px;height:40px;border-radius:4px;border:2px solid #ddd}.rte-color-value{font-family:monospace;font-size:14px;font-weight:500;color:#333}.rte-color-section{margin-bottom:20px}.rte-color-label{margin-bottom:8px;font-size:14px;font-weight:500}.rte-color-palette{display:grid;grid-template-columns:repeat(6,1fr);gap:8px;margin-bottom:16px}.rte-color-swatch{width:24px;height:24px;border:2px solid #ddd;border-radius:4px;cursor:pointer;transition:all .2s}.rte-color-swatch:hover{border-color:#999;transform:scale(1.1)}.rte-color-swatch.selected{border-color:#06c;box-shadow:0 0 0 2px #0066cc4d}.rte-custom-color{display:flex;align-items:center;gap:12px}.rte-color-input{width:60px;height:40px;border:2px solid #ddd;border-radius:4px;cursor:pointer}.rte-color-text-input{flex:1;padding:8px 12px;border:1px solid #ccc;border-radius:4px;font-family:monospace;font-size:14px}.rte-color-text-input:focus{outline:none;border-color:#06c;box-shadow:0 0 0 2px #06c3}.rte-iframe-preview{border:1px solid #ddd;border-radius:4px;overflow:hidden;background:#f8f9fa}.rte-iframe-preview iframe{display:block;border:none}.rte-size-presets{display:flex;flex-direction:column;gap:8px}.rte-radio-option{display:flex;align-items:flex-start;gap:8px;padding:8px;border:1px solid #e0e0e0;border-radius:4px;background:#fafbfc}.rte-radio-option:hover{background:#f1f3f4}.rte-radio-option input[type=radio]{margin-top:2px}.rte-radio-label{flex:1;line-height:1.4}.rte-content ul[data-type=checklist]{list-style:none;padding-left:0;margin:1em 0}.rte-content li[data-type=checklist-item]{position:relative;padding-left:2em;margin-bottom:.5em;line-height:1.6}.rte-content li[data-type=checklist-item]:before{content:"";position:absolute;left:0;top:.1em;width:1.2em;height:1.2em;border:2px solid #ccc;border-radius:3px;background:#fff;cursor:pointer;transition:all .2s ease}.rte-content li[data-type=checklist-item]:hover:before{border-color:#999}.rte-content li[data-type=checklist-item][data-checked=true]:before{background:#06c;border-color:#06c}.rte-content li[data-type=checklist-item][data-checked=true]:after{content:"✓";position:absolute;left:.36em;top:.12em;color:#fff;font-size:.9em;font-weight:700;pointer-events:none}.rte-content li[data-type=checklist-item][data-checked=true] p{text-decoration:line-through;color:#666}.editora-statusbar-container{display:flex;flex-direction:column}.rte-editor{.editora-statusbar-bottom{top:-32px}}.editora-statusbar-bottom{position:relative;border-left:1px solid rgb(221,221,221);border-right:1px solid rgb(221,221,221)}.editora-statusbar{display:flex;align-items:center;gap:12px;padding:6px 12px;background:#f5f5f5;border-top:1px solid #ddd;font-size:12px;color:#666}.editora-theme-dark .editora-statusbar{background:#252526;border-top-color:#3c3c3c;color:#9a9a9a}.editora-statusbar-top{border-top:none;border-bottom:1px solid #e0e0e0}.editora-statusbar-left{display:flex;align-items:center;gap:8px}.editora-statusbar-right{display:flex;align-items:center;gap:8px;margin-left:auto}.editora-statusbar-item{white-space:nowrap;padding:2px 4px}.editora-statusbar-separator{color:#ddd}.editora-theme-dark .editora-statusbar-separator{color:#3c3c3c}.editora-theme-dark .rte-content,.editora-theme-dark .rte-content h1,.editora-theme-dark .rte-content h2,.editora-theme-dark .rte-content h3,.editora-theme-dark .rte-content h4,.editora-theme-dark .rte-content h5,.editora-theme-dark .rte-content h6{color:#fff}.rte-inline-menu{position:fixed;z-index:1000;background:#fff;border:1px solid #ccc;border-radius:4px;box-shadow:0 2px 8px #00000026;min-width:120px;max-width:200px;pointer-events:auto}.rte-inline-menu-item{padding:8px 12px;cursor:pointer;font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;background-color:transparent}.rte-inline-menu-item:hover{background-color:#f5f5f5}.floating-toolbar{--rte-floating-toolbar-bg: #ffffff;--rte-floating-toolbar-border: #d7dee8;--rte-floating-toolbar-text: #364152;--rte-floating-toolbar-hover-bg: #f2f6fb;--rte-floating-toolbar-hover-text: #101828;--rte-floating-toolbar-active-bg: #e7eef7;--rte-floating-toolbar-separator: #d8e1ec;--rte-floating-toolbar-shadow: 0 10px 28px rgba(15, 23, 36, .16);user-select:none;-webkit-user-select:none;align-items:center;gap:4px;padding:6px;border-radius:8px;border:1px solid var(--rte-floating-toolbar-border);background:var(--rte-floating-toolbar-bg);color:var(--rte-floating-toolbar-text);box-shadow:var(--rte-floating-toolbar-shadow);pointer-events:auto;animation:rteFloatingToolbarIn .15s ease-out}.floating-toolbar-btn{display:inline-flex;align-items:center;justify-content:center;min-width:32px;height:32px;border:none;border-radius:6px;background:transparent;color:inherit;cursor:pointer;font-size:14px;font-weight:600;transition:background-color .15s ease,color .15s ease,transform .12s ease}.floating-toolbar-btn:hover{background:var(--rte-floating-toolbar-hover-bg);color:var(--rte-floating-toolbar-hover-text)}.floating-toolbar-btn:active{background:var(--rte-floating-toolbar-active-bg);transform:scale(.96)}.floating-toolbar-separator{width:1px;height:20px;margin:0 2px;background:var(--rte-floating-toolbar-separator)}@keyframes rteFloatingToolbarIn{0%{opacity:0;transform:translate(-50%) translateY(8px)}to{opacity:1;transform:translate(-50%) translateY(0)}}.editora-toolbar-group-button{display:flex;align-items:center;border-radius:var(--rte-radius);overflow:hidden;border:1px solid var(--rte-color-border-light);background:var(--rte-color-bg-secondary, #f9fafb);margin-right:.5rem;padding:0}.editora-toolbar-group-items{display:flex;align-items:center;gap:0}.editora-toolbar-group-button .editora-toolbar-button,.editora-toolbar-group-button .editora-toolbar-input{border-radius:0;border:none;margin:0;background:transparent;box-shadow:none}.editora-toolbar-group-button .editora-toolbar-button:first-child{border-radius:var(--rte-radius) 0 0 var(--rte-radius)}.editora-toolbar-group-button .editora-toolbar-button:last-child{border-radius:0 var(--rte-radius) var(--rte-radius) 0}.editora-toolbar-group-button .editora-toolbar-input{min-width:44px;width:44px;text-align:center;font-size:15px;background:#fff;border-left:1px solid var(--rte-color-border-light);border-right:1px solid var(--rte-color-border-light)}.editora-toolbar-group-button .editora-toolbar-button:active,.editora-toolbar-group-button .editora-toolbar-button:focus{background:#e5e7eb}.editora-toolbar-group-button .editora-toolbar-input:focus{outline:1.5px solid var(--rte-color-primary, #2563eb)}:root{--rte-color-primary: #007bff;--rte-color-primary-hover: #0056b3;--rte-color-secondary: #6c757d;--rte-color-success: #28a745;--rte-color-danger: #dc3545;--rte-color-warning: #ffc107;--rte-color-info: #17a2b8;--rte-color-text-primary: #212529;--rte-color-text-secondary: #6c757d;--rte-color-text-muted: #868e96;--rte-color-text-inverse: #ffffff;--rte-color-bg-primary: #ffffff;--rte-color-bg-secondary: #f8f9fa;--rte-color-bg-tertiary: #e9ecef;--rte-color-bg-hover: #f8f9fa;--rte-color-bg-active: #e9ecef;--rte-color-border: #dee2e6;--rte-color-border-light: #f8f9fa;--rte-color-border-focus: #007bff;--rte-shadow-sm: 0 1px 2px rgba(0, 0, 0, .05);--rte-shadow: 0 1px 3px rgba(0, 0, 0, .1), 0 1px 2px rgba(0, 0, 0, .06);--rte-shadow-lg: 0 10px 15px rgba(0, 0, 0, .1), 0 4px 6px rgba(0, 0, 0, .05);--rte-space-xs: .25rem;--rte-space-sm: .5rem;--rte-space-md: 1rem;--rte-space-lg: 1.5rem;--rte-space-xl: 2rem;--rte-space-xxl: 3rem;--rte-font-family-base: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;--rte-font-family-mono: "SFMono-Regular", Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;--rte-font-size-xs: .75rem;--rte-font-size-sm: .875rem;--rte-font-size-base: 1rem;--rte-font-size-lg: 1.125rem;--rte-font-size-xl: 1.25rem;--rte-font-size-xxl: 1.5rem;--rte-font-size-xxxl: 2rem;--rte-font-weight-normal: 400;--rte-font-weight-medium: 500;--rte-font-weight-semibold: 600;--rte-font-weight-bold: 700;--rte-line-height-tight: 1.25;--rte-line-height-normal: 1.5;--rte-line-height-relaxed: 1.75;--rte-radius-sm: .125rem;--rte-radius: .25rem;--rte-radius-md: .375rem;--rte-radius-lg: .5rem;--rte-radius-xl: .75rem;--rte-transition-fast: .15s ease-in-out;--rte-transition-normal: .25s ease-in-out;--rte-transition-slow: .35s ease-in-out;--rte-z-dropdown: 1000;--rte-z-sticky: 1020;--rte-z-modal: 1050;--rte-z-popover: 1060;--rte-z-tooltip: 1070}.rte-editor{font-family:var(--rte-font-family-base);font-size:var(--rte-font-size-base);line-height:var(--rte-line-height-normal);color:var(--rte-color-text-primary);background-color:var(--rte-color-bg-primary);border:1px solid var(--rte-color-border);border-radius:var(--rte-radius);box-shadow:var(--rte-shadow);transition:border-color var(--rte-transition-fast),box-shadow var(--rte-transition-fast)}.rte-editor:focus-within{border-color:var(--rte-color-border-focus);box-shadow:var(--rte-shadow),0 0 0 3px #007bff1a}.rte-toolbar{display:flex;align-items:center;padding:var(--rte-space-sm);border-bottom:1px solid var(--rte-color-border);background-color:var(--rte-color-bg-secondary);border-radius:var(--rte-radius) var(--rte-radius) 0 0;flex-wrap:wrap;gap:2px}.rte-toolbar-group{display:flex;align-items:center;border-radius:var(--rte-radius);overflow:hidden;border:1px solid var(--rte-color-border-light)}.rte-toolbar-button{display:flex;align-items:center;justify-content:center;width:2rem;height:2rem;padding:0;border:none;background:transparent;color:var(--rte-color-text-secondary);cursor:pointer;border-radius:var(--rte-radius-sm);transition:background-color var(--rte-transition-fast),color var(--rte-transition-fast);font-size:14px;line-height:1}.rte-toolbar-button span{display:flex;justify-content:center;align-items:center}.rte-toolbar-button svg,.editora-toolbar-button svg,.editora-toolbar-icon svg{flex-shrink:0;width:20px;height:20px;display:block;color:currentColor;fill:currentColor}.rte-toolbar-button:hover svg{opacity:.9}:is(.rte-toolbar-button[data-active=true],.editora-toolbar-button.active) svg{color:var(--rte-color-text-inverse)}.rte-toolbar-button:hover{background-color:var(--rte-color-bg-hover);color:var(--rte-color-text-primary)}.rte-toolbar-button:active,.rte-toolbar-button[data-active=true]{background-color:var(--rte-color-primary);color:var(--rte-color-text-inverse)}.rte-toolbar-button:disabled{opacity:.5;cursor:not-allowed}.rte-content{padding:var(--rte-space-md);min-height:200px;outline:none;overflow-wrap:break-word;word-wrap:break-word}.rte-content[contenteditable=true]{cursor:text}.rte-content h1,.rte-content h2,.rte-content h3,.rte-content h4,.rte-content h5,.rte-content h6{margin:var(--rte-space-lg) 0 var(--rte-space-md) 0;font-weight:var(--rte-font-weight-semibold);line-height:var(--rte-line-height-tight);color:var(--rte-color-text-primary)}.rte-content h1{font-size:var(--rte-font-size-xxxl)}.rte-content h2{font-size:var(--rte-font-size-xxl)}.rte-content h3{font-size:var(--rte-font-size-xl)}.rte-content h4{font-size:var(--rte-font-size-lg)}.rte-content h5{font-size:var(--rte-font-size-base)}.rte-content h6{font-size:var(--rte-font-size-sm)}.rte-content p{margin:var(--rte-space-md) 0}.rte-content blockquote{margin:var(--rte-space-lg) 0;padding:var(--rte-space-md);padding-left:var(--rte-space-lg);border-left:4px solid var(--rte-color-primary);background-color:var(--rte-color-bg-secondary);font-style:italic;color:var(--rte-color-text-secondary)}.rte-content ul,.rte-content ol{margin:var(--rte-space-md) 0;padding-left:var(--rte-space-xl)}.rte-content li{margin:var(--rte-space-xs) 0}.rte-content ul{list-style-type:disc}.rte-content ol{list-style-type:decimal}.rte-link{color:var(--rte-color-primary);text-decoration:none;transition:color var(--rte-transition-fast)}.rte-link:hover{color:var(--rte-color-primary-hover);text-decoration:underline}.rte-content code{font-family:var(--rte-font-family-mono);font-size:.875em;background-color:var(--rte-color-bg-tertiary);padding:.125rem .25rem;border-radius:var(--rte-radius-sm);color:var(--rte-color-danger)}.rte-content::selection{background-color:#007bff33}.rte-content:empty:before,.rte-content.rte-content-empty:before{content:attr(data-placeholder);color:var(--rte-color-text-muted);pointer-events:none}.rte-content:focus{outline:none}.rte-sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.rte-text-left{text-align:left}.rte-text-center{text-align:center}.rte-text-right{text-align:right}.rte-text-justify{text-align:justify}.rte-table td,.rte-table th,table td,table th{border:1px solid #ddd;padding:8px 12px;min-width:80px;vertical-align:top;position:relative;-webkit-user-select:none;user-select:none}.table-toolbar{background:#fff;border:1px solid #d0d0d0;border-radius:4px;box-shadow:0 2px 8px #0000001a;padding:4px;display:flex;align-items:center;gap:0;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,sans-serif;min-width:max-content}.rte-table,table{border-collapse:collapse;width:100%;margin:1rem 0;border:1px solid #ddd;font-size:14px;line-height:1.4;position:relative}.rte-table td,.rte-table th,table td,table th{border:1px solid #ddd;padding:8px 12px;min-width:80px;vertical-align:top;position:relative;user-select:none}.rte-table td:focus,.rte-table th:focus,table td:focus,table th:focus{outline:2px solid #007acc;outline-offset:-2px}.rte-table th,table th{background-color:#f8f9fa;font-weight:600;text-align:left}.rte-table td p,table td p{margin:0;padding:0}.rte-table td p:empty:before,table td p:empty:before{content:"​";display:inline-block}.rte-table td[contenteditable]:empty:before,table td[contenteditable]:empty:before{content:"Type here...";color:#999;font-style:italic;pointer-events:none}.rte-table tr:hover,table tr:hover{background-color:#f8f9fa}.rte-table td.selected,table td.selected{background-color:#e3f2fd;border-color:#2196f3}.table-toolbar{background:#fff;border:1px solid #d0d0d0;border-radius:4px;box-shadow:0 2px 8px #0000001a;padding:4px;display:flex;align-items:center;gap:0;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,sans-serif;min-width:max-content}.toolbar-section{display:flex;align-items:center;gap:2px}.toolbar-divider{width:1px;height:20px;background:#e0e0e0;margin:0 4px}.toolbar-icon-btn{display:flex;align-items:center;justify-content:center;width:28px;height:28px;padding:0;border:1px solid transparent;background:transparent;cursor:pointer;color:#333;border-radius:3px;transition:all .2s ease;flex-shrink:0;font-size:14px;line-height:1}.toolbar-icon-btn svg{width:16px;height:16px}.toolbar-icon-btn:hover:not(:disabled){background:#f0f0f0;border-color:#d0d0d0;color:#06c}.toolbar-icon-btn:active:not(:disabled){background:#e8f0ff;border-color:#06c;transform:scale(.95)}.toolbar-icon-btn:disabled{opacity:.4;cursor:not-allowed;color:#ccc}.toolbar-icon-btn-danger{color:#d32f2f}.toolbar-icon-btn-danger:hover:not(:disabled){background:#fff3f3;border-color:#fcc;color:#d32f2f}.toolbar-icon-btn-danger:active:not(:disabled){background:#ffebee}.toolbar-icon-btn-delete{color:#d32f2f}.toolbar-icon-btn-delete:hover:not(:disabled){background:#fff3f3;border-color:#fcc;color:#d32f2f}.toolbar-icon-btn-delete:active:not(:disabled){background:#ffebee}.resize-handle{opacity:0;transition:all .15s ease}.resize-handle:hover{opacity:1}td:hover>.resize-handle,th:hover>.resize-handle{opacity:1}.table-resize-handle{position:absolute;bottom:-4px;right:-4px;width:12px;height:12px;background:transparent;cursor:nwse-resize;z-index:10;transition:background .15s ease}.table-resize-handle:after{content:"";position:absolute;bottom:0;right:0;width:8px;height:8px;background:#0066cc4d;border-bottom:2px solid #0066cc;border-right:2px solid #0066cc;border-radius:0 0 2px;opacity:0;transition:opacity .15s ease}.table-resize-handle:hover:after{opacity:1}.rte-table:hover .table-resize-handle:after,table:hover .table-resize-handle:after{opacity:1}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table,table){border-color:#607088;background:#24303c;color:#e6eefb}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table td,.rte-table th,table td,table th){border-color:#607088;color:#e6eefb}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table th,table th){background:linear-gradient(180deg,#3b4553,#333d4a);color:#f3f8ff}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table tr:hover,table tr:hover){background-color:#58a6ff1f}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table td.selected,table td.selected){background-color:#58a6ff47;border-color:#79beff}:is([data-theme=dark],.dark,.editora-theme-dark) :is(.rte-table td[contenteditable]:empty:before,table td[contenteditable]:empty:before){color:#94a3b8}:is([data-theme=dark],.dark,.editora-theme-dark) .table-toolbar{background:linear-gradient(180deg,#2f3844,#2a323c);border-color:#4d596b;box-shadow:0 8px 20px #00000073}.table-toolbar.rte-theme-dark{background:linear-gradient(180deg,#2f3844,#2a323c);border-color:#4d596b;box-shadow:0 8px 20px #00000073}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-divider{background:#4d596b}.table-toolbar.rte-theme-dark .toolbar-divider{background:#4d596b}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn{color:#d7deea;border-color:transparent}.table-toolbar.rte-theme-dark .toolbar-icon-btn{color:#d7deea;border-color:transparent}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg{color:currentColor;fill:currentColor}.table-toolbar.rte-theme-dark .toolbar-icon-btn svg{color:currentColor;fill:currentColor}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [stroke="#000" i],:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [stroke="#000000" i],:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [stroke=black i]{stroke:currentColor!important}.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [stroke="#000" i],.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [stroke="#000000" i],.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [stroke=black i]{stroke:currentColor!important}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [fill="#000" i],:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [fill="#000000" i],:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn svg [fill=black i]{fill:currentColor!important}.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [fill="#000" i],.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [fill="#000000" i],.table-toolbar.rte-theme-dark .toolbar-icon-btn svg [fill=black i]{fill:currentColor!important}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn:hover:not(:disabled){background:#3a4554;border-color:#607088;color:#f3f8ff}.table-toolbar.rte-theme-dark .toolbar-icon-btn:hover:not(:disabled){background:#3a4554;border-color:#607088;color:#f3f8ff}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn:active:not(:disabled){background:#4a95de;border-color:#67adf4;color:#0f1b2a}.table-toolbar.rte-theme-dark .toolbar-icon-btn:active:not(:disabled){background:#4a95de;border-color:#67adf4;color:#0f1b2a}:is([data-theme=dark],.dark,.editora-theme-dark) .toolbar-icon-btn:disabled{color:#7f8ca1}.table-toolbar.rte-theme-dark .toolbar-icon-btn:disabled{color:#7f8ca1}@media(max-width:768px){.rte-table,table{font-size:12px}.rte-table td,.rte-table th,table td,table th{padding:4px 6px;min-width:60px}.table-toolbar{padding:3px;gap:0;max-width:90vw;overflow-x:auto}.toolbar-icon-btn{width:26px;height:26px}.toolbar-divider{height:18px}}@media print{.rte-table,table{border:1px solid #000}.rte-table td,.rte-table th,table td,table th{border:1px solid #000;padding:4px}.table-toolbar{display:none}}

@@ -69,3 +69,3 @@ export interface NodeSpec {

export type PluginCommand = (...args: unknown[]) => PluginCommandResult;
export type PluginCommand = (...args: any[]) => PluginCommandResult;

@@ -81,8 +81,8 @@ export interface Plugin {

config?: PluginConfig;
init?: (...args: unknown[]) => void | Promise<void>;
init?: (...args: any[]) => void | Promise<void>;
initialize?: (config?: PluginConfig) => void | Promise<void>;
destroy?: (...args: unknown[]) => void | Promise<void>;
executeLocal?: (command: string, ...args: unknown[]) => unknown;
executeAPI?: (command: string, ...args: unknown[]) => Promise<unknown>;
executeHybrid?: (command: string, ...args: unknown[]) => Promise<unknown>;
destroy?: (...args: any[]) => void | Promise<void>;
executeLocal?: (command: string, ...args: any[]) => unknown;
executeAPI?: (command: string, ...args: any[]) => Promise<unknown>;
executeHybrid?: (command: string, ...args: any[]) => Promise<unknown>;
}

@@ -89,0 +89,0 @@

{
"name": "@editora/core",
"version": "1.0.4",
"version": "1.0.5",
"description": "Framework-agnostic core editor engine for Editora Rich Text Editor",

@@ -112,5 +112,6 @@ "author": "Ajay Kumar <ajaykr089@gmail.com>",

"build": "vite build && vite build --config vite.umd.config.ts && vite build --config vite.webcomponent.config.ts && vite build --config vite.webcomponent-core.config.ts && vite build --config vite.plugin-loader.config.ts",
"typecheck:build": "tsc -p tsconfig.build.json --noEmit",
"dev": "vite build --watch",
"clean": "rm -rf dist",
"prepublishOnly": "npm run build"
"prepublishOnly": "npm run typecheck:build && npm run build"
},

@@ -117,0 +118,0 @@ "devDependencies": {

Sorry, the diff of this file is too big to display

const w = () => {
const d = window.getSelection();
if (d && d.rangeCount > 0) {
let t = d.getRangeAt(0).startContainer;
for (; t && t !== document.body; ) {
if (t.nodeType === Node.ELEMENT_NODE) {
const r = t;
if (r.getAttribute("contenteditable") === "true")
return r;
}
t = t.parentNode;
}
}
const l = document.activeElement;
if (l) {
if (l.getAttribute("contenteditable") === "true")
return l;
const t = l.closest('[contenteditable="true"]');
if (t) return t;
}
return document.querySelector('[contenteditable="true"]');
}, k = '[data-theme="dark"], .dark, .editora-theme-dark', N = () => {
const d = w();
if (d != null && d.closest(k)) return !0;
const l = window.getSelection();
if (l && l.rangeCount > 0) {
const r = l.getRangeAt(0).startContainer, i = r.nodeType === Node.ELEMENT_NODE ? r : r.parentElement;
if (i != null && i.closest(k)) return !0;
}
const t = document.activeElement;
return t != null && t.closest(k) ? !0 : document.body.matches(k) || document.documentElement.matches(k);
}, A = [
{ value: "javascript", label: "JavaScript" },
{ value: "typescript", label: "TypeScript" },
{ value: "python", label: "Python" },
{ value: "java", label: "Java" },
{ value: "csharp", label: "C#" },
{ value: "cpp", label: "C++" },
{ value: "c", label: "C" },
{ value: "php", label: "PHP" },
{ value: "ruby", label: "Ruby" },
{ value: "go", label: "Go" },
{ value: "rust", label: "Rust" },
{ value: "swift", label: "Swift" },
{ value: "kotlin", label: "Kotlin" },
{ value: "html", label: "HTML" },
{ value: "css", label: "CSS" },
{ value: "scss", label: "SCSS" },
{ value: "json", label: "JSON" },
{ value: "xml", label: "XML" },
{ value: "yaml", label: "YAML" },
{ value: "markdown", label: "Markdown" },
{ value: "sql", label: "SQL" },
{ value: "bash", label: "Bash" },
{ value: "shell", label: "Shell" },
{ value: "plaintext", label: "Plain Text" }
], S = /* @__PURE__ */ new Map();
function $(d, l, t, r) {
const i = !!l, n = r || "javascript", g = t || "", p = N(), e = p ? {
overlay: "rgba(0, 0, 0, 0.62)",
dialogBg: "#1f2937",
dialogBorder: "#4b5563",
text: "#e2e8f0",
mutedText: "#a8b5c8",
headerFooterBg: "#222d3a",
border: "#3b4657",
fieldBg: "#111827",
fieldBorder: "#4b5563",
cancelBg: "#334155",
cancelHover: "#475569",
cancelText: "#e2e8f0",
primaryBg: "#3b82f6",
primaryHover: "#2563eb"
} : {
overlay: "rgba(0, 0, 0, 0.5)",
dialogBg: "#ffffff",
dialogBorder: "#e0e0e0",
text: "#333333",
mutedText: "#666666",
headerFooterBg: "#ffffff",
border: "#e0e0e0",
fieldBg: "#ffffff",
fieldBorder: "#dddddd",
cancelBg: "#e5e7eb",
cancelHover: "#d1d5db",
cancelText: "#333333",
primaryBg: "#2563eb",
primaryHover: "#1d4ed8"
}, c = document.createElement("div");
c.className = "rte-code-sample-overlay", p && c.classList.add("rte-theme-dark"), c.style.cssText = `
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: ${e.overlay};
display: flex;
align-items: center;
justify-content: center;
z-index: 10000;
animation: fadeIn 160ms ease-out;
`;
const o = document.createElement("div");
o.className = "rte-code-sample-dialog", o.style.cssText = `
background: ${e.dialogBg};
border: 1px solid ${e.dialogBorder};
border-radius: 8px;
box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
max-width: 700px;
width: 90vw;
max-height: 80vh;
display: flex;
flex-direction: column;
animation: slideUp 200ms cubic-bezier(0.2, 0.9, 0.25, 1);
`;
const u = document.createElement("div");
u.style.cssText = `
padding: 20px;
border-bottom: 1px solid ${e.border};
background: ${e.headerFooterBg};
display: flex;
justify-content: space-between;
align-items: center;
`, u.innerHTML = `
<h2 style="margin: 0; font-size: 18px; font-weight: 600; color: ${e.text};">
${i ? "Edit Code Sample" : "Insert Code Sample"}
</h2>
<button class="rte-code-close-btn" style="background: none; border: none; font-size: 28px; color: ${e.mutedText}; cursor: pointer; padding: 0; width: 32px; height: 32px;">×</button>
`;
const m = document.createElement("div");
m.style.cssText = `
flex: 1;
overflow-y: auto;
padding: 20px;
`;
const s = document.createElement("div");
s.style.marginBottom = "20px", s.innerHTML = `
<label style="display: block; margin-bottom: 8px; font-weight: 500; color: ${e.text}; font-size: 14px;">Language</label>
<select class="rte-code-language" style="
width: 100%;
padding: 10px 12px;
border: 1px solid ${e.fieldBorder};
border-radius: 4px;
font-size: 14px;
background-color: ${e.fieldBg};
color: ${e.text};
cursor: pointer;
">
${A.map((a) => `
<option value="${a.value}" ${a.value === n ? "selected" : ""}>
${a.label}
</option>
`).join("")}
</select>
`;
const b = document.createElement("div");
b.style.marginBottom = "20px", b.innerHTML = `
<label style="display: block; margin-bottom: 8px; font-weight: 500; color: ${e.text}; font-size: 14px;">Code</label>
<textarea class="rte-code-textarea" spellcheck="false" placeholder="Paste or type your code here..." style="
width: 100%;
padding: 12px;
border: 1px solid ${e.fieldBorder};
border-radius: 4px;
font-family: 'Courier New', Courier, monospace;
font-size: 13px;
line-height: 1.5;
resize: vertical;
min-height: 250px;
max-height: 400px;
background-color: ${e.fieldBg};
color: ${e.text};
box-sizing: border-box;
">${g}</textarea>
<div class="rte-code-error" style="color: #dc2626; font-size: 12px; margin-top: 6px; display: none;"></div>
`;
const x = document.createElement("div");
x.style.cssText = `color: ${e.mutedText}; font-size: 12px; margin-top: 10px;`, x.innerHTML = "💡 Tip: Press Ctrl+Enter (or Cmd+Enter on Mac) to save, or Escape to cancel", m.appendChild(s), m.appendChild(b), m.appendChild(x);
const y = document.createElement("div");
y.style.cssText = `
padding: 20px;
border-top: 1px solid ${e.border};
background: ${e.headerFooterBg};
display: flex;
justify-content: flex-end;
gap: 12px;
`, y.innerHTML = `
<button class="rte-code-cancel-btn" style="
padding: 10px 16px;
border: none;
border-radius: 4px;
font-size: 14px;
font-weight: 500;
cursor: pointer;
background: ${e.cancelBg};
color: ${e.cancelText};
">Cancel</button>
<button class="rte-code-save-btn" style="
padding: 10px 16px;
border: none;
border-radius: 4px;
font-size: 14px;
font-weight: 500;
cursor: pointer;
background: ${e.primaryBg};
color: #fff;
">${i ? "Update Code Sample" : "Insert Code Sample"}</button>
`, o.appendChild(u), o.appendChild(m), o.appendChild(y), c.appendChild(o);
const L = s.querySelector(".rte-code-language"), E = b.querySelector(".rte-code-textarea"), B = b.querySelector(".rte-code-error"), f = u.querySelector(".rte-code-close-btn"), v = y.querySelector(".rte-code-cancel-btn"), h = y.querySelector(".rte-code-save-btn");
f.onmouseover = () => {
f.style.color = "#f8fafc", f.style.background = p ? "#334155" : "#f0f0f0", f.style.borderRadius = "4px";
}, f.onmouseout = () => {
f.style.color = e.mutedText, f.style.background = "none";
}, v.onmouseover = () => {
v.style.background = e.cancelHover;
}, v.onmouseout = () => {
v.style.background = e.cancelBg;
}, h.onmouseover = () => {
h.style.background = e.primaryHover;
}, h.onmouseout = () => {
h.style.background = e.primaryBg;
};
const C = () => {
c.remove();
}, T = () => {
const a = E.value.trim();
if (!a) {
B.textContent = "⚠ Code cannot be empty", B.style.display = "block";
return;
}
const M = L.value;
d(a, M), C();
};
if (f.onclick = C, v.onclick = C, h.onclick = T, E.addEventListener("keydown", (a) => {
(a.ctrlKey || a.metaKey) && a.key === "Enter" && (a.preventDefault(), T()), a.key === "Escape" && C();
}), E.addEventListener("input", () => {
B.style.display = "none";
}), c.addEventListener("click", (a) => {
a.target === c && C();
}), !document.getElementById("rte-code-sample-animations")) {
const a = document.createElement("style");
a.id = "rte-code-sample-animations", a.textContent = `
@keyframes fadeIn {
from { opacity: 0; }
to { opacity: 1; }
}
@keyframes slideUp {
from { transform: translateY(20px); opacity: 0; }
to { transform: translateY(0); opacity: 1; }
}
`, document.head.appendChild(a);
}
return document.body.appendChild(c), setTimeout(() => E.focus(), 100), c;
}
function R() {
if (!w()) return;
let l = null;
const t = window.getSelection();
t && t.rangeCount > 0 && (l = t.getRangeAt(0).cloneRange()), $((r, i) => {
const n = window.getSelection();
if (l && (n == null || n.removeAllRanges(), n == null || n.addRange(l)), !n || n.rangeCount === 0) return;
const g = w();
if (!g) return;
const p = n.anchorNode;
if (!p || !g.contains(p)) return;
const e = n.getRangeAt(0), c = `code-block-${Date.now()}`, o = document.createElement("pre");
o.className = "rte-code-block", o.id = c, o.setAttribute("data-type", "code-block"), o.setAttribute("data-lang", i), o.setAttribute("data-code-id", c), o.setAttribute("contenteditable", "false"), o.style.cssText = `
display: block;
position: relative;
background: #f5f5f5;
border: 1px solid #e0e0e0;
border-radius: 6px;
padding: 12px;
margin: 12px 0;
overflow-x: auto;
font-family: 'Courier New', 'Monaco', 'Menlo', monospace;
font-size: 13px;
line-height: 1.5;
color: #333;
user-select: text;
cursor: default;
`;
const u = document.createElement("code");
u.className = `language-${i}`, u.style.cssText = `
font-family: inherit;
font-size: inherit;
line-height: inherit;
color: inherit;
white-space: pre;
word-break: normal;
display: block;
`, u.textContent = r;
const m = document.createElement("span");
m.style.cssText = `
position: absolute;
top: 0;
right: 0;
background: #333;
color: #fff;
padding: 2px 8px;
font-size: 11px;
font-weight: bold;
border-radius: 0 6px 0 4px;
text-transform: uppercase;
letter-spacing: 0.5px;
pointer-events: none;
`, m.textContent = i;
const s = document.createElement("button");
s.className = "rte-code-copy", s.textContent = "Copy", s.style.cssText = `
position: absolute;
top: 8px;
left: 8px;
background: #fff;
border: 1px solid #d0d0d0;
border-radius: 3px;
padding: 4px 8px;
font-size: 11px;
cursor: pointer;
opacity: 0;
transition: opacity 0.2s ease;
`, s.onclick = (x) => {
x.stopPropagation(), navigator.clipboard.writeText(r).then(() => {
s.textContent = "✓ Copied!", setTimeout(() => {
s.textContent = "Copy";
}, 2e3);
});
}, o.appendChild(m), o.appendChild(s), o.appendChild(u), o.addEventListener("mouseenter", () => {
s.style.opacity = "1";
}), o.addEventListener("mouseleave", () => {
s.style.opacity = "0";
}), o.addEventListener("dblclick", () => {
z(c);
}), S.set(c, {
id: c,
language: i,
code: r
}), e.insertNode(o);
const b = document.createRange();
b.setStartAfter(o), b.collapse(!0), n.removeAllRanges(), n.addRange(b);
});
}
function z(d) {
const l = w();
if (!l) return;
const t = l.querySelector(`#${d}`);
if (!t) return;
const r = S.get(d);
r && $(
(i, n) => {
const g = t.querySelector("code");
g && (g.textContent = i, g.className = `language-${n}`);
const p = t.querySelector("span");
p && (p.textContent = n), t.setAttribute("data-lang", n), r.language = n, r.code = i;
const e = t.querySelector(".rte-code-copy");
e && (e.onclick = (c) => {
c.stopPropagation(), navigator.clipboard.writeText(i).then(() => {
e.textContent = "✓ Copied!", setTimeout(() => {
e.textContent = "Copy";
}, 2e3);
});
});
},
d,
r.code,
r.language
);
}
const H = () => ({
name: "codeSample",
toolbar: [
{
label: "Code Block",
command: "insertCodeBlock",
icon: '<svg width="18px" height="18px" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M7 8L3 11.6923L7 16M17 8L21 11.6923L17 16M14 4L10 20" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/></svg>',
shortcut: "Mod-Shift-C"
}
],
commands: {
insertCodeBlock: (...d) => (R(), !0)
}
});
export {
H as CodeSamplePlugin
};
//# sourceMappingURL=CodeSamplePlugin.native-B-KS1pOl.mjs.map
const A = ".rte-content, .editora-content";
const y = "__editoraCommandEditorRoot", d = /* @__PURE__ */ new Map(), E = {};
let T = !1, c = null;
function N(t) {
if (!t) return null;
const e = t.querySelector('[contenteditable="true"]');
return e instanceof HTMLElement ? e : null;
}
function z() {
if (typeof window == "undefined") return null;
const t = window[y];
if (!(t instanceof HTMLElement)) return null;
window[y] = null;
const e = t.closest("[data-editora-editor], .rte-editor, .editora-editor, editora-editor") || (t.matches("[data-editora-editor], .rte-editor, .editora-editor, editora-editor") ? t : null);
if (e) {
const o = N(e);
if (o) return o;
if (e.getAttribute("contenteditable") === "true") return e;
}
if (t.getAttribute("contenteditable") === "true")
return t;
const n = t.closest('[contenteditable="true"]');
return n instanceof HTMLElement ? n : null;
}
function F(t) {
return t ? t.nodeType === Node.ELEMENT_NODE ? t : t.parentElement : null;
}
function f(t) {
const e = F(t);
if (!e) return null;
const n = e.closest(A);
if (n) return n;
const o = e.closest('[contenteditable="true"]');
if (!o) return null;
let r = o, i = r.parentElement;
for (; i; )
i.getAttribute("contenteditable") === "true" && (r = i), i = i.parentElement;
return r;
}
function l() {
const t = z();
if (t && document.contains(t))
return t;
const e = window.getSelection();
if (e && e.rangeCount > 0) {
const i = f(e.getRangeAt(0).startContainer);
if (i) return i;
}
const n = document.activeElement;
if (n) {
const i = f(n);
if (i) return i;
}
if (c != null && c.isConnected) return c;
const o = Array.from(d.keys()).find((i) => i.isConnected);
if (o) return o;
const r = document.querySelector(A);
return r || document.querySelector('[contenteditable="true"]');
}
function L() {
for (const t of d.keys())
t.isConnected || (d.delete(t), c === t && (c = null));
}
function M(t) {
L();
let e = d.get(t);
return e || (e = { undoStack: [], redoStack: [] }, d.set(t, e)), e;
}
function s(t) {
t && t.dispatchEvent(new Event("input", { bubbles: !0 }));
}
function h(t) {
return t ? t.innerHTML : "";
}
function m(t, e) {
if (!t) return;
const n = M(t);
n.undoStack.push(e), n.redoStack.length = 0, n.undoStack.length > 100 && n.undoStack.splice(0, n.undoStack.length - 100), c = t;
}
function x(t, e = "undo") {
if (L(), t != null && t.isConnected)
return t;
const n = l();
if (n != null && n.isConnected)
return n;
if (c != null && c.isConnected)
return c;
const o = (r) => e === "undo" ? r.undoStack.length > 0 : r.redoStack.length > 0;
for (const [r, i] of d.entries())
if (r.isConnected && o(i))
return r;
return null;
}
function H(t) {
const e = {};
for (const r of t.getAttributeNames()) {
const i = t.getAttribute(r);
i !== null && (e[r] = i);
}
const n = t instanceof HTMLInputElement || t instanceof HTMLTextAreaElement || t instanceof HTMLSelectElement, o = t instanceof HTMLInputElement;
return {
attributes: e,
innerHTML: t.innerHTML,
value: n ? t.value : null,
checked: o ? t.checked : null
};
}
function w(t, e) {
const n = new Set(t.getAttributeNames());
Object.keys(e.attributes).forEach((o) => n.delete(o)), n.forEach((o) => t.removeAttribute(o)), Object.entries(e.attributes).forEach(([o, r]) => {
t.setAttribute(o, r);
}), t.innerHTML !== e.innerHTML && (t.innerHTML = e.innerHTML), e.value !== null && (t instanceof HTMLInputElement || t instanceof HTMLTextAreaElement || t instanceof HTMLSelectElement) && (t.value = e.value), e.checked !== null && t instanceof HTMLInputElement && (t.checked = e.checked);
}
function u(t, e) {
if (E[t] = e, typeof window == "undefined") return;
const n = window.registerEditorCommand;
typeof n == "function" ? n(t, e) : (window.registerEditorCommand = (o, r) => {
E[o] = r;
}, window.registerEditorCommand(t, e));
}
const S = (t, ...e) => {
const n = E[t];
return n ? n(...e) : !1;
};
function C() {
T || typeof window == "undefined" || (T = !0, window.execEditorCommand || (window.execEditorCommand = S), window.executeEditorCommand || (window.executeEditorCommand = S), u("undo", k), u("redo", O), u("setAttribute", D), u("setText", _), u("autoFixA11y", R), u("recordDomTransaction", I), u("undoDom", b), u("redoDom", p));
}
function v(t, e) {
const n = e || l(), o = h(n);
n == null || n.focus({ preventScroll: !0 });
let r = !1;
try {
r = !!document.execCommand(t, !1);
} catch (g) {
r = !1;
}
const i = h(n), a = o !== i;
return a && s(n), { executed: r, changed: a };
}
const k = () => {
const t = l();
return v("undo", t).changed ? !0 : b(t);
}, O = () => {
const t = l();
return v("redo", t).changed ? !0 : p(t);
}, D = (t, e, n) => {
if (!(t instanceof HTMLElement)) return;
const o = f(t), r = t.hasAttribute(e), i = t.getAttribute(e);
t.setAttribute(e, n), m(o, {
undo: () => {
t.isConnected && (r && i !== null ? t.setAttribute(e, i) : t.removeAttribute(e));
},
redo: () => {
t.isConnected && t.setAttribute(e, n);
}
}), s(o);
}, _ = (t, e) => {
var r;
if (!(t instanceof HTMLElement)) return;
const n = f(t), o = (r = t.textContent) != null ? r : "";
t.textContent = e, m(n, {
undo: () => {
t.isConnected && (t.textContent = o);
},
redo: () => {
t.isConnected && (t.textContent = e);
}
}), s(n);
}, R = (t) => {
var a;
const e = t == null ? void 0 : t.element;
if (!(e instanceof HTMLElement)) return;
const n = f(e), o = (a = window.a11yRuleRegistry) == null ? void 0 : a.find((g) => g.id === t.rule);
if (!o || typeof o.fix != "function") return;
const r = H(e);
o.fix(t);
const i = H(e);
m(n, {
undo: () => {
e.isConnected && w(e, r);
},
redo: () => {
e.isConnected && w(e, i);
}
}), s(n);
}, I = (t, e, n) => {
if (!(t instanceof HTMLElement)) return !1;
const o = typeof n == "string" ? n : t.innerHTML;
return e === o ? !1 : (m(t, {
undo: () => {
t.isConnected && (t.innerHTML = e);
},
redo: () => {
t.isConnected && (t.innerHTML = o);
}
}), !0);
}, b = (t) => {
const e = x(t, "undo");
if (!e) return !1;
const n = M(e), o = n.undoStack.pop();
return o ? (o.undo(), n.redoStack.push(o), c = e, s(e), !0) : !1;
}, p = (t) => {
const e = x(t, "redo");
if (!e) return !1;
const n = M(e), o = n.redoStack.pop();
return o ? (o.redo(), n.undoStack.push(o), c = e, s(e), !0) : !1;
};
typeof window != "undefined" && (document.readyState === "loading" ? document.addEventListener("DOMContentLoaded", C, { once: !0 }) : C());
const Y = () => (C(), {
name: "history",
toolbar: [
{
label: "Undo",
command: "undo",
type: "button",
icon: '<svg width="24" height="24" focusable="false"><path d="M6.4 8H12c3.7 0 6.2 2 6.8 5.1.6 2.7-.4 5.6-2.3 6.8a1 1 0 0 1-1-1.8c1.1-.6 1.8-2.7 1.4-4.6-.5-2.1-2.1-3.5-4.9-3.5H6.4l3.3 3.3a1 1 0 1 1-1.4 1.4l-5-5a1 1 0 0 1 0-1.4l5-5a1 1 0 0 1 1.4 1.4L6.4 8Z" fill-rule="nonzero"></path></svg>',
shortcut: "Mod-z"
},
{
label: "Redo",
command: "redo",
type: "button",
icon: '<svg width="24" height="24" focusable="false"><path d="M17.6 10H12c-2.8 0-4.4 1.4-4.9 3.5-.4 2 .3 4 1.4 4.6a1 1 0 1 1-1 1.8c-2-1.2-2.9-4.1-2.3-6.8.6-3 3-5.1 6.8-5.1h5.6l-3.3-3.3a1 1 0 1 1 1.4-1.4l5 5a1 1 0 0 1 0 1.4l-5 5a1 1 0 0 1-1.4-1.4l3.3-3.3Z" fill-rule="nonzero"></path></svg>',
shortcut: "Mod-y"
}
],
commands: {
undo: k,
redo: O,
setAttribute: D,
setText: _,
autoFixA11y: R,
recordDomTransaction: I,
undoDom: b,
redoDom: p
},
keymap: {
"Mod-z": "undo",
"Mod-Z": "undo",
"Mod-y": "redo",
"Mod-Y": "redo",
"Mod-Shift-z": "redo",
"Mod-Shift-Z": "redo"
}
});
export {
Y as HistoryPlugin,
R as autoFixA11y,
I as recordDomTransaction,
O as redo,
p as redoDom,
D as setAttribute,
_ as setText,
k as undo,
b as undoDom
};
//# sourceMappingURL=HistoryPlugin.native-DCrPdeSW.mjs.map
const D = {
USER: {
name: "User",
tags: [
{ key: "first_name", label: "First Name", category: "User", preview: "John" },
{ key: "last_name", label: "Last Name", category: "User", preview: "Doe" },
{ key: "email", label: "Email", category: "User", preview: "john@example.com" },
{ key: "phone", label: "Phone", category: "User", preview: "+1-555-1234" },
{ key: "full_name", label: "Full Name", category: "User", preview: "John Doe" },
{ key: "username", label: "Username", category: "User", preview: "johndoe" }
]
},
COMPANY: {
name: "Company",
tags: [
{ key: "company_name", label: "Company Name", category: "Company", preview: "Acme Corp" },
{ key: "company_address", label: "Company Address", category: "Company", preview: "123 Main St" },
{ key: "company_phone", label: "Company Phone", category: "Company", preview: "+1-555-0000" },
{ key: "company_email", label: "Company Email", category: "Company", preview: "info@acme.com" }
]
},
DATE: {
name: "Date",
tags: [
{ key: "today", label: "Today", category: "Date", preview: (/* @__PURE__ */ new Date()).toLocaleDateString() },
{ key: "tomorrow", label: "Tomorrow", category: "Date", preview: new Date(Date.now() + 864e5).toLocaleDateString() },
{ key: "next_week", label: "Next Week", category: "Date", preview: new Date(Date.now() + 6048e5).toLocaleDateString() }
]
},
CUSTOM: {
name: "Custom",
tags: []
}
}, v = ".rte-content, .editora-content", K = '[data-theme="dark"], .dark, .editora-theme-dark', A = Object.keys(D), Y = A.reduce(
(t, e) => (t[e] = D[e].tags.map((r) => ({
...r,
searchIndex: `${r.label} ${r.key} ${r.category} ${r.description || ""}`.toLowerCase()
})), t),
{}
);
let j = !1, H = !1, E = null, w = null, k = null, P = !1;
function R() {
if (j || typeof document == "undefined") return;
j = !0;
const t = document.createElement("style");
t.id = "merge-tag-plugin-styles", t.textContent = `
.rte-merge-tag-overlay {
--rte-mt-overlay-bg: rgba(15, 23, 36, 0.56);
--rte-mt-dialog-bg: #ffffff;
--rte-mt-dialog-text: #101828;
--rte-mt-border: #d6dbe4;
--rte-mt-subtle-bg: #f7f9fc;
--rte-mt-subtle-hover: #eef2f7;
--rte-mt-muted-text: #5f6b7d;
--rte-mt-accent: #1976d2;
--rte-mt-accent-strong: #1565c0;
position: fixed;
inset: 0;
background-color: var(--rte-mt-overlay-bg);
backdrop-filter: blur(2px);
display: flex;
align-items: center;
justify-content: center;
z-index: 10000;
padding: 16px;
box-sizing: border-box;
}
.rte-merge-tag-overlay.rte-ui-theme-dark {
--rte-mt-overlay-bg: rgba(2, 8, 20, 0.72);
--rte-mt-dialog-bg: #202938;
--rte-mt-dialog-text: #e8effc;
--rte-mt-border: #49566c;
--rte-mt-subtle-bg: #2a3444;
--rte-mt-subtle-hover: #344256;
--rte-mt-muted-text: #a5b1c5;
--rte-mt-accent: #58a6ff;
--rte-mt-accent-strong: #4598f4;
}
.rte-merge-tag-dialog {
background: var(--rte-mt-dialog-bg);
color: var(--rte-mt-dialog-text);
border: 1px solid var(--rte-mt-border);
border-radius: 12px;
box-shadow: 0 24px 48px rgba(10, 15, 24, 0.28);
width: 500px;
max-width: 90vw;
max-height: 80vh;
display: flex;
flex-direction: column;
overflow: hidden;
}
.rte-merge-tag-header { padding: 16px; border-bottom: 1px solid var(--rte-mt-border); display:flex; justify-content:space-between; align-items:center; }
.rte-merge-tag-body { padding: 16px; overflow-y:auto; flex:1; }
.rte-merge-tag-input { width:100%; padding:10px; border:1px solid var(--rte-mt-border); border-radius:4px; background:var(--rte-mt-subtle-bg); color:var(--rte-mt-dialog-text); }
.rte-merge-tag-tabs { display:flex; gap:8px; margin: 12px 0; }
.rte-merge-tag-tab { padding:8px 12px; background:none; border:none; cursor:pointer; color:var(--rte-mt-muted-text); border-bottom:3px solid transparent; }
.rte-merge-tag-tab.active { color:var(--rte-mt-accent); border-bottom-color:var(--rte-mt-accent); }
.rte-merge-tag-list { border:1px solid var(--rte-mt-border); border-radius:4px; max-height:300px; overflow-y:auto; margin-bottom:12px; background:var(--rte-mt-subtle-bg); }
.rte-merge-tag-item { padding:8px 12px; border-bottom:1px solid var(--rte-mt-border); cursor:pointer; transition:background-color 0.16s; color:var(--rte-mt-dialog-text); }
.rte-merge-tag-item:last-child { border-bottom: none; }
.rte-merge-tag-item.selected, .rte-merge-tag-item:hover { background-color:var(--rte-mt-subtle-hover); }
.rte-merge-tag-item-label { font-weight: 600; }
.rte-merge-tag-item-preview { font-size: 12px; color: var(--rte-mt-muted-text); margin-top: 2px; }
.rte-merge-tag-empty { padding: 24px; text-align: center; color: var(--rte-mt-muted-text); }
.rte-merge-tag-preview { padding:8px; background:var(--rte-mt-subtle-bg); border-radius:4px; font-family:monospace; font-size:12px; color:var(--rte-mt-dialog-text); }
.rte-merge-tag-footer { padding:12px 16px; border-top:1px solid var(--rte-mt-border); display:flex; gap:8px; justify-content:flex-end; background:var(--rte-mt-subtle-bg); }
.rte-merge-tag-btn-primary { padding:8px 16px; border:none; border-radius:4px; background:var(--rte-mt-accent); color:#fff; cursor:pointer; }
.rte-merge-tag-btn-primary:hover { background: var(--rte-mt-accent-strong); }
.rte-merge-tag-btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }
.rte-merge-tag-btn-secondary { padding:8px 16px; border:1px solid var(--rte-mt-border); border-radius:4px; background:var(--rte-mt-subtle-bg); color:var(--rte-mt-dialog-text); cursor:pointer; }
.rte-merge-tag {
display: inline-flex;
align-items: center;
white-space: nowrap;
user-select: none;
background-color: #e3f2fd;
border: 1px solid #bbdefb;
border-radius: 3px;
padding: 1px 6px;
margin: 0 2px;
color: #1976d2;
font-weight: 600;
line-height: 1.3;
}
:is([data-theme="dark"], .dark, .editora-theme-dark) .rte-merge-tag {
background: #223247;
border-color: #3f5f84;
color: #8dc4ff;
}
`, document.head.appendChild(t);
}
function $() {
H || typeof document == "undefined" || (H = !0, document.addEventListener("focusin", (t) => {
const e = t.target, r = e == null ? void 0 : e.closest(v);
r && (E = r);
}), document.addEventListener("selectionchange", () => {
const t = V();
t && (E = t);
}));
}
function V() {
const t = window.getSelection();
if (!t || t.rangeCount === 0) return null;
const r = t.getRangeAt(0).startContainer, n = r.nodeType === Node.ELEMENT_NODE ? r : r.parentElement;
return (n == null ? void 0 : n.closest(v)) || null;
}
function J() {
const t = V();
if (t) return t;
const e = document.activeElement, r = e == null ? void 0 : e.closest(v);
return r || (E != null && E.isConnected ? E : document.querySelector(v));
}
function Q(t) {
const e = t.parentNode;
if (!e) return;
const r = window.getSelection();
if (!r) return;
const n = document.createRange(), o = Array.from(e.childNodes).indexOf(t);
o < 0 || (n.setStart(e, o), n.setEnd(e, o + 1), r.removeAllRanges(), r.addRange(n));
}
function B(t, e) {
var r;
t instanceof Text && t.data.length !== 0 && (e ? (t.data.startsWith(" ") || t.data.startsWith(" ")) && t.deleteData(0, 1) : (t.data.endsWith(" ") || t.data.endsWith(" ")) && t.deleteData(t.data.length - 1, 1), t.data.length === 0 && ((r = t.parentNode) == null || r.removeChild(t)));
}
function G(t, e) {
const r = window.getSelection();
if (!r) return;
const n = document.createRange(), i = Math.max(0, Math.min(e, t.childNodes.length));
n.setStart(t, i), n.collapse(!0), r.removeAllRanges(), r.addRange(n);
}
function Z(t, e) {
var d;
const r = t.parentNode;
if (!r) return !1;
const i = Array.from(r.childNodes).indexOf(t);
if (i < 0) return !1;
const o = t.previousSibling, c = t.nextSibling;
r.removeChild(t), e === "Backspace" ? (B(c, !0), G(r, i)) : (B(o, !1), G(r, i));
const g = r instanceof HTMLElement ? r.closest(v) : ((d = r.parentElement) == null ? void 0 : d.closest(v)) || null;
return g && g.dispatchEvent(new Event("input", { bubbles: !0 })), !0;
}
function ee(t) {
if (t.collapsed || !(t.startContainer instanceof HTMLElement || t.startContainer instanceof Text) || t.startContainer !== t.endContainer || t.endOffset !== t.startOffset + 1) return null;
const e = t.startContainer;
if (!(e instanceof Element || e instanceof DocumentFragment)) return null;
const r = e.childNodes[t.startOffset];
return r instanceof HTMLElement && r.classList.contains("rte-merge-tag") ? r : null;
}
function te(t, e) {
if (!t.collapsed) return null;
const { startContainer: r, startOffset: n } = t, i = (o) => o instanceof HTMLElement && o.classList.contains("rte-merge-tag") ? o : null;
if (r.nodeType === Node.ELEMENT_NODE) {
const o = r;
return e === "Backspace" && n > 0 ? i(o.childNodes[n - 1] || null) : e === "Delete" ? i(o.childNodes[n] || null) : null;
}
if (r.nodeType === Node.TEXT_NODE) {
const o = r;
return e === "Backspace" ? n === 0 ? i(o.previousSibling) : n === 1 && (o.data[0] === " " || o.data[0] === " ") && o.previousSibling instanceof HTMLElement && o.previousSibling.classList.contains("rte-merge-tag") ? o.previousSibling : null : n === o.data.length ? i(o.nextSibling) : null;
}
return null;
}
function q() {
P || typeof document == "undefined" || (P = !0, document.addEventListener("click", (t) => {
const e = t.target, r = e == null ? void 0 : e.closest(".rte-merge-tag");
if (!r) return;
const n = r.closest(v);
n && (t.preventDefault(), t.stopPropagation(), n.focus({ preventScroll: !0 }), Q(r));
}), document.addEventListener("keydown", (t) => {
if (t.key !== "Backspace" && t.key !== "Delete") return;
const e = window.getSelection();
if (!e || e.rangeCount === 0) return;
const r = e.getRangeAt(0), n = J();
if (!n || !n.contains(r.commonAncestorContainer)) return;
let i = ee(r);
i || (i = te(r, t.key)), i && (t.preventDefault(), t.stopPropagation(), Z(i, t.key));
}));
}
function re(t) {
return t ? !!t.closest(K) : !1;
}
function ne() {
k && (k(), k = null), w = null;
}
function W(t) {
const e = document.createRange();
return e.selectNodeContents(t), e.collapse(!1), e;
}
function ae(t, e) {
const r = window.getSelection(), n = e ? e.cloneRange() : W(t), o = n.startContainer.isConnected && n.endContainer.isConnected && t.contains(n.commonAncestorContainer) ? n : W(t);
return r && (r.removeAllRanges(), r.addRange(o)), o;
}
function oe(t) {
const e = document.createElement("span");
return e.className = "rte-merge-tag", e.setAttribute("contenteditable", "false"), e.setAttribute("data-key", t.key), e.setAttribute("data-category", t.category), e.setAttribute("data-label", t.label), e.setAttribute("aria-label", `Merge tag: ${t.label}`), e.textContent = `{{ ${t.label} }}`, e;
}
function ie(t, e, r) {
const n = window.getSelection();
if (!n) return !1;
t.focus({ preventScroll: !0 });
const i = ae(t, e), o = i.startContainer.nodeType === Node.ELEMENT_NODE ? i.startContainer : i.startContainer.parentElement, c = o == null ? void 0 : o.closest(".rte-merge-tag");
c && t.contains(c) && (i.setStartAfter(c), i.setEndAfter(c));
try {
i.deleteContents();
const g = oe(r), d = document.createTextNode(" "), u = document.createDocumentFragment();
u.appendChild(g), u.appendChild(d), i.insertNode(u);
const f = document.createRange();
return f.setStartAfter(d), f.collapse(!0), n.removeAllRanges(), n.addRange(f), t.dispatchEvent(new Event("input", { bubbles: !0 })), !0;
} catch (g) {
return console.error("Failed to insert merge tag:", g), !1;
}
}
function le(t, e) {
const r = Y[t], n = e.trim().toLowerCase();
return n ? r.filter((i) => i.searchIndex.includes(n)) : r;
}
function se(t) {
ne(), R();
const e = {
category: "USER",
searchTerm: "",
filteredTags: Y.USER,
selectedIndex: 0,
savedRange: (() => {
const a = window.getSelection();
if (!a || a.rangeCount === 0) return null;
const l = a.getRangeAt(0);
return t.contains(l.commonAncestorContainer) ? l.cloneRange() : null;
})(),
searchRaf: null
}, r = document.createElement("div");
r.className = "rte-merge-tag-overlay", r.setAttribute("role", "dialog"), r.setAttribute("aria-modal", "true"), re(t) && r.classList.add("rte-ui-theme-dark");
const n = document.createElement("div");
n.className = "rte-merge-tag-dialog";
const i = document.createElement("div");
i.className = "rte-merge-tag-header", i.innerHTML = `
<h2 style="margin:0; font-size:18px; font-weight:700;">Insert Merge Tag</h2>
<button class="rte-merge-tag-close" aria-label="Close" style="background:none;border:none;color:inherit;cursor:pointer;font-size:20px;">✕</button>
`;
const o = document.createElement("div");
o.className = "rte-merge-tag-body";
const c = document.createElement("input");
c.type = "text", c.className = "rte-merge-tag-input", c.placeholder = "Search merge tags...", c.setAttribute("aria-label", "Search merge tags");
const g = document.createElement("div");
g.className = "rte-merge-tag-tabs", A.forEach((a) => {
const l = document.createElement("button");
l.type = "button", l.className = "rte-merge-tag-tab", l.setAttribute("data-category", a), l.textContent = D[a].name, g.appendChild(l);
});
const d = document.createElement("div");
d.className = "rte-merge-tag-list";
const u = document.createElement("div");
u.className = "rte-merge-tag-preview", o.appendChild(c), o.appendChild(g), o.appendChild(d), o.appendChild(u);
const f = document.createElement("div");
f.className = "rte-merge-tag-footer";
const x = document.createElement("button");
x.type = "button", x.className = "rte-merge-tag-btn-secondary", x.textContent = "Cancel";
const p = document.createElement("button");
p.type = "button", p.className = "rte-merge-tag-btn-primary", p.textContent = "Insert", f.appendChild(x), f.appendChild(p), n.appendChild(i), n.appendChild(o), n.appendChild(f), r.appendChild(n), document.body.appendChild(r), w = r;
const I = () => {
g.querySelectorAll(".rte-merge-tag-tab").forEach((l) => {
const m = l.dataset.category === e.category;
l.classList.toggle("active", m);
});
}, N = () => {
if (e.filteredTags.length === 0) {
e.selectedIndex = -1;
return;
}
e.selectedIndex < 0 && (e.selectedIndex = 0), e.selectedIndex >= e.filteredTags.length && (e.selectedIndex = e.filteredTags.length - 1);
}, M = () => {
N();
const a = e.selectedIndex >= 0 ? e.filteredTags[e.selectedIndex] : null;
if (!a) {
u.style.display = "none", p.disabled = !0;
return;
}
u.style.display = "block", u.innerHTML = `<strong>Preview:</strong> {{ ${a.label} }}`, p.disabled = !1;
}, X = () => {
if (e.selectedIndex < 0) return;
const a = d.querySelector(`.rte-merge-tag-item[data-index="${e.selectedIndex}"]`);
a == null || a.scrollIntoView({ block: "nearest" });
}, h = () => {
if (e.filteredTags = le(e.category, e.searchTerm), e.filteredTags.length > 0 && e.selectedIndex < 0 && (e.selectedIndex = 0), N(), d.innerHTML = "", e.filteredTags.length === 0) {
const l = document.createElement("div");
l.className = "rte-merge-tag-empty", l.textContent = "No merge tags found", d.appendChild(l), M();
return;
}
const a = document.createDocumentFragment();
e.filteredTags.forEach((l, m) => {
const s = document.createElement("div");
s.className = "rte-merge-tag-item", s.setAttribute("data-index", String(m)), s.classList.toggle("selected", m === e.selectedIndex);
const S = document.createElement("div");
if (S.className = "rte-merge-tag-item-label", S.textContent = l.label, s.appendChild(S), l.preview) {
const L = document.createElement("div");
L.className = "rte-merge-tag-item-preview", L.textContent = l.preview, s.appendChild(L);
}
a.appendChild(s);
}), d.appendChild(a), M(), X();
}, O = () => {
e.searchRaf !== null && cancelAnimationFrame(e.searchRaf), e.searchRaf = requestAnimationFrame(() => {
e.searchRaf = null, e.searchTerm = c.value, e.selectedIndex = 0, h();
});
}, b = () => {
e.searchRaf !== null && (cancelAnimationFrame(e.searchRaf), e.searchRaf = null), r.remove(), w === r && (w = null, k = null);
}, T = () => {
if (N(), e.selectedIndex < 0) return;
const a = e.filteredTags[e.selectedIndex];
ie(t, e.savedRange, a) && b();
}, _ = (a) => {
const m = a.target.closest(".rte-merge-tag-tab");
if (!m) return;
const s = m.dataset.category;
!s || !A.includes(s) || (e.category = s, e.searchTerm = "", c.value = "", e.selectedIndex = 0, I(), h());
}, F = (a) => {
const m = a.target.closest(".rte-merge-tag-item");
if (!m) return;
const s = Number(m.dataset.index || "-1");
Number.isNaN(s) || s < 0 || s >= e.filteredTags.length || (e.selectedIndex = s, h());
}, U = (a) => {
const m = a.target.closest(".rte-merge-tag-item");
if (!m) return;
const s = Number(m.dataset.index || "-1");
Number.isNaN(s) || s < 0 || s >= e.filteredTags.length || (e.selectedIndex = s, T());
}, C = (a) => {
if (a.key === "Escape") {
a.preventDefault(), b();
return;
}
if (a.key === "ArrowDown") {
if (a.preventDefault(), e.filteredTags.length === 0) return;
e.selectedIndex = Math.min(e.filteredTags.length - 1, e.selectedIndex + 1), h();
return;
}
if (a.key === "ArrowUp") {
if (a.preventDefault(), e.filteredTags.length === 0) return;
e.selectedIndex = Math.max(0, e.selectedIndex - 1), h();
return;
}
a.key === "Enter" && (a.preventDefault(), T());
}, z = (a) => {
a.target === r && b();
}, y = i.querySelector(".rte-merge-tag-close");
g.addEventListener("click", _), d.addEventListener("click", F), d.addEventListener("dblclick", U), c.addEventListener("input", O), c.addEventListener("keydown", C), r.addEventListener("click", z), n.addEventListener("keydown", C), y == null || y.addEventListener("click", b), x.addEventListener("click", b), p.addEventListener("click", T), k = () => {
g.removeEventListener("click", _), d.removeEventListener("click", F), d.removeEventListener("dblclick", U), c.removeEventListener("input", O), c.removeEventListener("keydown", C), r.removeEventListener("click", z), n.removeEventListener("keydown", C), y == null || y.removeEventListener("click", b), x.removeEventListener("click", b), p.removeEventListener("click", T), e.searchRaf !== null && (cancelAnimationFrame(e.searchRaf), e.searchRaf = null), r.remove();
}, I(), h(), setTimeout(() => {
c.focus();
}, 0);
}
const ce = () => ({
name: "mergeTag",
init: () => {
R(), $(), q();
},
toolbar: [
{
label: "Merge Tag",
command: "insertMergeTag",
icon: "{{ }}"
}
],
commands: {
insertMergeTag: () => {
R(), $(), q();
const t = J();
return t ? (se(t), !0) : !1;
}
}
});
export {
ce as MergeTagPlugin
};
//# sourceMappingURL=MergeTagPlugin.native-CU9LtsfD.mjs.map

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display