Add quote indicator and distinct callout styling for Note/Tip/Warning/Important
- Description editor: blockquotes get a left accent line and muted color so it's clear when typing in "quote mode" (matches the existing active Quote toolbar button highlight). - Editor block cards: each text block's left border is colored by its level (info/success/warn/error) so Note/Tip/Warning/Important are distinguishable at a glance. - PDF/HTML/DOCX exports: callouts now get a level-specific accent color and tinted background/shading (blue/green/amber/red), instead of all looking identical except for the label text. Co-Authored-By: Claude Sonnet 4.6 <[email protected]>
This commit is contained in:
@@ -674,6 +674,7 @@ class GuideEditor {
|
||||
}, header);
|
||||
|
||||
if (kind === 'text') {
|
||||
card.dataset.level = block.level || 'info';
|
||||
const position = makeSelect(block.position, [
|
||||
{ value: 'before-title', label: 'Before title' },
|
||||
{ value: 'after-title', label: 'After title' },
|
||||
@@ -696,7 +697,7 @@ class GuideEditor {
|
||||
body.dataset.blockField = 'body';
|
||||
body.value = (block.descriptionHtml || '').replace(/<[^>]+>/g, '');
|
||||
position.addEventListener('change', () => { block.position = position.value; save(); });
|
||||
level.addEventListener('change', () => { block.level = level.value; save(); });
|
||||
level.addEventListener('change', () => { block.level = level.value; card.dataset.level = level.value; save(); });
|
||||
title.addEventListener('input', () => { block.title = title.value; save(); });
|
||||
body.addEventListener('input', () => { block.descriptionHtml = `<p>${escapeHtml(body.value)}</p>`; save(); });
|
||||
card.append(
|
||||
|
||||
Reference in New Issue
Block a user