chore(editor): address image-caption review (#221)
- docs: add CHANGELOG Unreleased/Added entry for editable image captions - test: export sanitizeCaption and add vitest unit coverage (whitespace collapse, trim, 500-char boundary) - refactor: drop duplicate .imageCaption CSS module class, keep the global .image-caption as the single source - docs: fix turndown image-caption comment (video rule emits a markdown link, not a <div>) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -7,16 +7,6 @@
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.imageCaption {
|
||||
display: block;
|
||||
text-align: center;
|
||||
font-size: 0.875em;
|
||||
color: var(--mantine-color-dimmed);
|
||||
margin-top: 0.4em;
|
||||
line-height: 1.35;
|
||||
word-break: break-word;
|
||||
}
|
||||
|
||||
.skeleton {
|
||||
animation: pulse 1.2s ease-in-out infinite;
|
||||
|
||||
|
||||
@@ -72,7 +72,7 @@ export default function ImageView(props: NodeViewProps) {
|
||||
{captionText && (
|
||||
<Text
|
||||
component="figcaption"
|
||||
className={clsx(classes.imageCaption, "image-caption")}
|
||||
className="image-caption"
|
||||
>
|
||||
{captionText}
|
||||
</Text>
|
||||
|
||||
Reference in New Issue
Block a user