PluginProbe
aBlocks – Gutenberg Blocks, User Dashboard Builder, Popup Builder, Form Builder & Animation Builder / 2.8.0
aBlocks – Gutenberg Blocks, User Dashboard Builder, Popup Builder, Form Builder & Animation Builder v2.8.0
2.12.0 2.11.1 2.11.0 2.10.0 2.9.0 2.7.4 2.7.5 2.7.6 2.7.7 2.8.0 2.8.1 2.9.1 trunk 1.0 1.0-beta1 1.0-beta2 1.0-beta3 1.0.1 1.0.2 1.0.3 1.1.0 1.1.1 1.1.2 1.2.0 1.2.1 All 78 releases
ablocks / includes / blocks / heading / attributes.php

attributes.php in aBlocks – Gutenberg Blocks, User Dashboard Builder, Popup Builder, Form Builder & Animation Builder 2.8.0, at includes/blocks/heading/attributes.php

102 lines 2.0 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 if ( ! defined( 'ABSPATH' ) ) {
4 exit;
5 }
6
7 use ABlocks\Controls\Alignment;
8 use ABlocks\Controls\Typography;
9 use ABlocks\Controls\TextShadow;
10 use ABlocks\Controls\TextStroke;
11 use ABlocks\Controls\Link;
12 use ABlocks\Controls\Range;
13
14 $attributes = [
15 'block_id' => array(
16 'type' => 'string',
17 'default' => '',
18 ),
19 'blockVersion' => array(
20 'type' => 'number',
21 'default' => '',
22 ),
23 'isAnimated' => array(
24 'type' => 'boolean',
25 'default' => false,
26 ),
27 'heading' => array(
28 'type' => 'string',
29 'source' => 'html',
30 'selector' => '.ablocks-heading-text'
31 ),
32 'headingTag' => array(
33 'type' => 'string',
34 'default' => 'h2',
35 ),
36 'textColor' => array(
37 'type' => 'string',
38 'default' => '',
39 ),
40 'animationType' => array(
41 'type' => 'string',
42 'default' => 'highlighted',
43 ),
44 'animationStyle' => array(
45 'type' => 'string',
46 'default' => 'highlighter-circle',
47 ),
48 'startingText' => array(
49 'type' => 'string',
50 'default' => '',
51 ),
52 'animatedText' => array(
53 'type' => 'string',
54 'default' => 'Animated',
55 ),
56 'endingText' => array(
57 'type' => 'string',
58 'default' => '',
59 ),
60
61 'highlightColor' => array(
62 'type' => 'string',
63 'default' => '#ff000e',
64 ),
65 'highlightDuration' => array(
66 'type' => 'number',
67 'default' => 2000,
68 ),
69 'isInfiniteLoop' => array(
70 'type' => 'boolean',
71 'default' => true,
72 ),
73 'highlightDelay' => array(
74 'type' => 'number',
75 'default' => 1000,
76 ),
77 'animatedTextColor' => array(
78 'type' => 'string',
79 'default' => '',
80 ),
81 ];
82
83 $attributes = array_merge(
84 $attributes,
85 Alignment::get_attribute( 'alignment', true, [ 'value' => 'left' ] ),
86 Typography::get_attribute( 'typography', true ),
87 TextShadow::get_attribute( 'textShadow' ),
88 Link::get_attribute( 'link' ),
89 TextStroke::get_attribute( 'textStroke', true ),
90 Range::get_attribute([
91 'attributeName' => 'highlightStrokeWidth',
92 'attributeObjectKey' => 'value',
93 'isResponsive' => true,
94 'defaultValue' => 10,
95 'hasUnit' => true,
96 'unitDefaultValue' => 'px',
97 ]),
98 );
99
100 return array_merge( $attributes, \ABlocks\Classes\BlockGlobal::get_attributes() );
101
102