diff --git a/pages/admin/index.js b/pages/admin/index.js index b8efb5e..73f8bcd 100644 --- a/pages/admin/index.js +++ b/pages/admin/index.js @@ -154,66 +154,153 @@ export default function AdminPanel() { } }; - const MarkdownToolbar = ({ contentIndex }) => ( -
- - - - - - - -
- ); + const MarkdownToolbar = ({ contentIndex }) => { + const buttonClass = "px-2 py-1 text-xs bg-white border rounded hover:bg-gray-50 flex items-center justify-center min-w-[32px]"; + + return ( +
+ {/* Text Formatierung */} +
+ + + +
+ + {/* Überschriften */} +
+ + + +
+ + {/* Listen */} +
+ + + +
+ + {/* Code */} +
+ + +
+ + {/* Sonstiges */} +
+ + + + +
+
+ ); + }; return (
@@ -324,9 +411,12 @@ export default function AdminPanel() { code: ({node, inline, className, children, ...props}) => { const match = /language-(\w+)/.exec(className || ''); return !inline ? ( -
+                                
+                                  
+ {match ? match[1] : 'code'} +
{children} @@ -334,7 +424,7 @@ export default function AdminPanel() {
) : ( {children} diff --git a/pages/blog/[slug].js b/pages/blog/[slug].js index 53422a1..c56d703 100644 --- a/pages/blog/[slug].js +++ b/pages/blog/[slug].js @@ -62,9 +62,12 @@ export default function BlogPost({ blog }) { code: ({node, inline, className, children, ...props}) => { const match = /language-(\w+)/.exec(className || ''); return !inline ? ( -
+                            
+                              
+ {match ? match[1] : 'code'} +
{children} @@ -72,7 +75,7 @@ export default function BlogPost({ blog }) {
) : ( {children}