| 1 |
<?php |
| 2 |
|
| 3 |
if ( ! defined( 'ABSPATH' ) ) { |
| 4 |
exit; |
| 5 |
} |
| 6 |
|
| 7 |
use ABlocks\Controls\Alignment; |
| 8 |
use ABlocks\Controls\TextShadow; |
| 9 |
use ABlocks\Controls\TextStroke; |
| 10 |
use ABlocks\Controls\Typography; |
| 11 |
|
| 12 |
$attributes = [ |
| 13 |
'block_id' => [ |
| 14 |
'type' => 'string', |
| 15 |
'default' => '' |
| 16 |
], |
| 17 |
'blockVersion' => array( |
| 18 |
'type' => 'number', |
| 19 |
'default' => '', |
| 20 |
), |
| 21 |
'paragraph' => [ |
| 22 |
'type' => 'string', |
| 23 |
'source' => 'html', |
| 24 |
'selector' => '.ablocks-paragraph-text' |
| 25 |
], |
| 26 |
'dropCaps' => [ |
| 27 |
'type' => 'boolean', |
| 28 |
'default' => false, |
| 29 |
], |
| 30 |
'dropCapsTextColor' => [ |
| 31 |
'type' => 'string', |
| 32 |
'default' => '#0f2aff', |
| 33 |
], |
| 34 |
'paragraphSize' => [ |
| 35 |
'type' => 'string', |
| 36 |
'default' => 'md', |
| 37 |
], |
| 38 |
'textColor' => [ |
| 39 |
'type' => 'string', |
| 40 |
'default' => '#000000', |
| 41 |
] |
| 42 |
]; |
| 43 |
|
| 44 |
$attributes = array_merge( |
| 45 |
$attributes, |
| 46 |
Alignment::get_attribute( 'alignment', true, [ 'value' => 'left' ] ), |
| 47 |
Typography::get_attribute( 'typography', true ), |
| 48 |
TextShadow::get_attribute( 'textShadow' ), |
| 49 |
TextStroke::get_attribute( 'textStroke', true ), |
| 50 |
); |
| 51 |
|
| 52 |
return array_merge( $attributes, \ABlocks\Classes\BlockGlobal::get_attributes() ); |
| 53 |
|
| 54 |
|