PluginProbe
aBlocks – Gutenberg Blocks, User Dashboard Builder, Popup Builder, Form Builder & Animation Builder / 2.9.1
aBlocks – Gutenberg Blocks, User Dashboard Builder, Popup Builder, Form Builder & Animation Builder v2.9.1
2.13.0 2.13.1 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 All 80 releases
ablocks / includes / blocks / content-timeline-child / attributes.php

attributes.php in aBlocks – Gutenberg Blocks, User Dashboard Builder, Popup Builder, Form Builder & Animation Builder 2.9.1, at includes/blocks/content-timeline-child/attributes.php

136 lines 2.9 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\Helper;
8 use ABlocks\Controls\Dimensions;
9 use ABlocks\Controls\Border;
10 use ABlocks\Controls\Range;
11 use ABlocks\Controls\Typography;
12 use ABlocks\Controls\Icon;
13
14 $attributes = [
15 'block_id' => [
16 'type' => 'string',
17 'default' => '',
18 ],
19 'text_date' => [
20 'type' => 'string',
21 'default' => 'January 1, 2024',
22 ],
23 'indexContent' => [
24 'type' => 'number',
25 ],
26 'parentAttribute' => [
27 'type' => 'object',
28 'default' => new stdClass(),
29 ],
30 'changeChildIcon' => [
31 'type' => 'boolean',
32 'default' => false
33 ],
34 'contentPosition' => [
35 'type' => 'string',
36 'default' => 'center',
37 ],
38 'arrowAlignment' => [
39 'type' => 'string',
40 'default' => 'center',
41 ],
42 'iconColor' => [
43 'type' => 'string',
44 'default' => '#000000',
45 ],
46 'iconBackgroundColor' => [
47 'type' => 'string',
48 'default' => '#eee',
49 ],
50 'thicknessColor' => [
51 'type' => 'string',
52 'default' => '#eee',
53 ],
54 'showAnimation' => [
55 'type' => 'boolean',
56 'default' => true,
57 ],
58 'connectorAnimationColor' => [
59 'type' => 'string',
60 'default' => '#00ad6b',
61 ],
62 'contentBackgroundColor' => [
63 'type' => 'string',
64 'default' => '#eee',
65 ],
66 'showDate' => [
67 'type' => 'boolean',
68 'default' => true,
69 ],
70 'showDateTablet' => [
71 'type' => 'boolean',
72 'default' => true,
73 ],
74 'showDateMobile' => [
75 'type' => 'boolean',
76 'default' => true,
77 ],
78 'dateColor' => [
79 'type' => 'string',
80 'default' => '#333333'
81 ],
82 'dateAlign' => [
83 'type' => 'string',
84 'default' => 'left',
85 ],
86 'dateFormat' => [
87 'type' => 'string',
88 'default' => 'F j, Y',
89 ],
90 'dateBackground' => [
91 'type' => 'string',
92 'default' => '#eee',
93 ]
94
95 ];
96 $attributes = array_merge(
97 $attributes,
98 Range::get_attribute( [
99 'attributeName' => 'iconBackgroundSize',
100 'isResponsive' => false,
101 'defaultValue' => 48,
102 ] ),
103 Range::get_attribute([
104 'attributeName' => 'itemGap',
105 'attributeObjectKey' => 'value',
106 'isResponsive' => true,
107 'defaultValue' => 10,
108 'hasUnit' => true,
109 'unitDefaultValue' => 'px'
110 ] ),
111 Range::get_attribute([
112 'attributeName' => 'thickness',
113 'isResponsive' => false,
114 'defaultValue' => 3,
115 ] ),
116 Range::get_attribute([
117 'attributeName' => 'iconSize',
118 'isResponsive' => false,
119 'defaultValue' => 18,
120 ] ),
121 Icon::get_attribute(
122 'icon', [
123 'path' => 'M256 504c137 0 248-111 248-248S393 8 256 8 8 119 8 256s111 248 248 248zm0-448c110.5 0 200 89.5 200 200s-89.5 200-200 200S56 366.5 56 256 145.5 56 256 56zm20 328h-40c-6.6 0-12-5.4-12-12V256h-67c-10.7 0-16-12.9-8.5-20.5l99-99c4.7-4.7 12.3-4.7 17 0l99 99c7.6 7.6 2.2 20.5-8.5 20.5h-67v116c0 6.6-5.4 12-12 12z',
124 'viewBox' => '0 0 512 512',
125 'className' => 'far fa-arrow-alt-circle-up',
126 ]
127 ),
128 Typography::get_attribute( 'dateTypography', true ),
129 Dimensions::get_attribute( 'contentPadding', true ),
130 Dimensions::get_attribute( 'datePadding', true ),
131 Border::get_attribute( 'dateBorder', true ),
132 );
133 return array_merge( $attributes, \ABlocks\Classes\BlockGlobal::get_attributes() );
134
135
136