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 / menu-child-sub / attributes.php

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

165 lines 3.2 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3
4 use ABlocks\Controls\Dimensions;
5 use ABlocks\Controls\Typography;
6 use ABlocks\Controls\Border;
7 use ABlocks\Controls\Range;
8 use ABlocks\Controls\BoxShadow;
9 if ( ! defined( 'ABSPATH' ) ) {
10 exit;
11 }
12
13 $attributes = [
14 'block_id' => [
15 'type' => 'string',
16 'default' => '',
17 ],
18 'background' => [
19 'type' => 'string',
20 'default' => 'white'
21 ],
22
23 // flex direction start
24 'direction' => [
25 'type' => 'string',
26 'default' => 'column',
27 ],
28 'directionTablet' => [
29 'type' => 'string',
30 'default' => '',
31 ],
32 'directionMobile' => [
33 'type' => 'string',
34 'default' => '',
35 ],
36 // flex direction end
37 // flex 'justify content' start
38 'justify' => [
39 'type' => 'string',
40 'default' => '',
41 ],
42 'justifyTablet' => [
43 'type' => 'string',
44 'default' => '',
45 ],
46 'justifyMobile' => [
47 'type' => 'string',
48 'default' => '',
49 ],
50 // flex 'justify content' end
51 // flex 'align items" start
52 'align' => [
53 'type' => 'string',
54 'default' => '',
55 ],
56 'alignTablet' => [
57 'type' => 'string',
58 'default' => '',
59 ],
60 'alignMobile' => [
61 'type' => 'string',
62 'default' => '',
63 ],
64 // flex 'align items" end
65
66 'menuItemTextColor' => [
67 'type' => 'string',
68 'default' => ''
69 ],
70 'menuItemTextColorH' => [
71 'type' => 'string',
72 'default' => '#000000',
73 ],
74 'menuItemBackground' => [
75 'type' => 'string',
76 'default' => '',
77 ],
78 'menuItemBackgroundH' => [
79 'type' => 'string',
80 'default' => '',
81 ],
82 'menuItemTransition' => [
83 'type' => 'number',
84 'default' => 0
85 ],
86 'menuItemAlign' => [
87 'type' => 'string',
88 'default' => '',
89 'copyStyle' => true,
90 ],
91 'menuItemAlignTablet' => [
92 'type' => 'string',
93 'default' => '',
94 'copyStyle' => true,
95 ],
96 'menuItemAlignMobile' => [
97 'type' => 'string',
98 'default' => '',
99 'copyStyle' => true,
100 ],
101 'menuItemDirection' => [
102 'type' => 'string',
103 'default' => 'row',
104 'copyStyle' => true,
105 ],
106 'menuItemDirectionTablet' => [
107 'type' => 'string',
108 'default' => '',
109 'copyStyle' => true,
110 ],
111 'menuItemDirectionMobile' => [
112 'type' => 'string',
113 'default' => '',
114 'copyStyle' => true,
115 ],
116 'menuItemJustify' => [
117 'type' => 'string',
118 'default' => 'space-between',
119 'copyStyle' => true,
120 ],
121 'menuItemJustifyTablet' => [
122 'type' => 'string',
123 'default' => 'space-between',
124 'copyStyle' => true,
125 ],
126 'menuItemJustifyMobile' => [
127 'type' => 'string',
128 'default' => 'space-between',
129 'copyStyle' => true,
130 ],
131
132 ];
133
134 $attributes = array_merge(
135 $attributes,
136 BoxShadow::get_attribute( 'boxShadow', true ),
137 Dimensions::get_attribute( 'padding', false ),
138 Dimensions::get_attribute( 'menuItemPadding', false ),
139 Dimensions::get_attribute( 'menuItemMargin', false ),
140 Border::get_attribute( 'menuItemBorder', true ),
141 Border::get_attribute( 'border', true ),
142 Typography::get_attribute( 'menuItemTypography', true ),
143 Range::get_attribute([
144 'attributeName' => 'width',
145 'attributeObjectKey' => 'value',
146 'isResponsive' => true,
147 'hasUnit' => true,
148 'unitDefaultValue' => 'px',
149 ]),
150 Range::get_attribute([
151 'attributeName' => 'positionX',
152 'attributeObjectKey' => 'value',
153 'isResponsive' => true,
154 'defaultValue' => 0,
155
156 ]),
157 Range::get_attribute([
158 'attributeName' => 'positionY',
159 'attributeObjectKey' => 'value',
160 'isResponsive' => true,
161 'defaultValue' => 0,
162 ]),
163 );
164 return $attributes;
165