-
- {name}
-
+
setIsHovered(true)}
+ onMouseLeave={() => setIsHovered(false)}
+ >
+
+
+
+
+
+
+
+ {formatFileType(fileContent.fileType)}
+
+
+
+ {isEditing && isHovered && (
+
+
+
+
+ )}
+
- );
-}
+ )
+}
\ No newline at end of file
diff --git a/docs/src/components/blocks/HeadingBlock.tsx b/docs/src/components/blocks/HeadingBlock.tsx
index a93c186..3dfe36c 100644
--- a/docs/src/components/blocks/HeadingBlock.tsx
+++ b/docs/src/components/blocks/HeadingBlock.tsx
@@ -40,6 +40,7 @@ export function HeadingTitle({ id, level, children, align = 'left', styles, isEd
className={cn(
`font-bold mb-2 py-4 ${sizeClasses[level as keyof typeof sizeClasses]} ${alignClass}`,
'focus:outline-none rounded-md',
+ 'max-w-4xl break-words',
styles?.italic && 'italic',
styles?.underline && 'underline'
)}
@@ -53,7 +54,8 @@ export function HeadingTitle({ id, level, children, align = 'left', styles, isEd
{children}
diff --git a/docs/src/components/blocks/ImageBlock.tsx b/docs/src/components/blocks/ImageBlock.tsx
index 1c465d1..4ffbb8b 100644
--- a/docs/src/components/blocks/ImageBlock.tsx
+++ b/docs/src/components/blocks/ImageBlock.tsx
@@ -21,24 +21,6 @@ interface ImageBlockProps {
export function ImageBlock({ content, id, onUpdate, isEditing, metadata }: ImageBlockProps) {
const [isHovered, setIsHovered] = useState(false)
- const handleFileUpload = async (e: React.ChangeEvent
) => {
- e.stopPropagation()
- const file = e.target.files?.[0]
- if (!file) return
-
- const url = URL.createObjectURL(file)
-
- const imageContent = JSON.stringify({
- url,
- alt: metadata?.alt || file.name,
- caption: metadata?.caption,
- alignment: metadata?.alignment || 'center',
- size: metadata?.size || 'medium'
- })
-
- onUpdate?.(imageContent)
- }
-
// Helper function to parse content
const parseImageContent = (content: string) => {
try {
@@ -63,7 +45,6 @@ export function ImageBlock({ content, id, onUpdate, isEditing, metadata }: Image
id={`image-upload-${id}`}
className="hidden"
accept="image/*"
- onChange={handleFileUpload}
/>