fix: button detection with text alignment
Added data-button attribute selector to TipTap button parseHTML. This ensures buttons are properly detected when text alignment is applied, as alignment may affect CSS class detection. Priority order: 1. a[data-button] - most reliable 2. a.button 3. a.button-outline
This commit is contained in:
@@ -37,6 +37,9 @@ export const ButtonExtension = Node.create<ButtonOptions>({
|
||||
|
||||
parseHTML() {
|
||||
return [
|
||||
{
|
||||
tag: 'a[data-button]',
|
||||
},
|
||||
{
|
||||
tag: 'a.button',
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user