/** * Content styles for @crux-kit/editor-tiptap. * Plain CSS on purpose: this file is imported directly by consumers and must not * depend on the host app's Tailwind pipeline. Colors reference the shared * design-system CSS variables (--foreground, --border, …) so the editor themes * automatically in light/dark mode. */ .crux-editor__content { min-height: 12rem; padding: 0.75rem 0.875rem; outline: none; color: var(--foreground); font-size: 0.875rem; line-height: 1.6; border-bottom: 1px solid var(--color-input); border-left: 1px solid var(--color-input); border-right: 1px solid var(--color-input); border-bottom-right-radius: var(--radius-md); border-bottom-left-radius: var(--radius-md); } .crux-editor__content :first-child { margin-top: 0; } .crux-editor__content :last-child { margin-bottom: 0; } .crux-editor__content p { margin: 0 0 0.75em; } .crux-editor__content h1, .crux-editor__content h2, .crux-editor__content h3 { margin: 1.25em 0 0.5em; font-weight: 600; line-height: 1.25; color: var(--foreground); } .crux-editor__content h1 { font-size: 1.75em; } .crux-editor__content h2 { font-size: 1.4em; } .crux-editor__content h3 { font-size: 1.15em; } .crux-editor__content ul, .crux-editor__content ol { margin: 0 0 0.75em; padding-left: 1.5rem; } .crux-editor__content ul { list-style: disc; } .crux-editor__content ol { list-style: decimal; } .crux-editor__content li { margin: 0.25em 0; } .crux-editor__content li p { margin: 0; } .crux-editor__content blockquote { margin: 0 0 0.75em; padding-left: 1rem; border-left: 3px solid var(--border); color: var(--muted-foreground); } .crux-editor__content a { color: var(--primary); text-decoration: underline; text-underline-offset: 2px; cursor: pointer; } .crux-editor__content strong { font-weight: 600; } /* Placeholder (from @tiptap/extensions Placeholder) */ .crux-editor__content p.is-editor-empty:first-child::before { content: attr(data-placeholder); float: left; height: 0; pointer-events: none; color: var(--muted-foreground); } /* ProseMirror selection niceties */ .crux-editor__content .ProseMirror-selectednode { outline: 2px solid var(--ring); }