PluginProbe
Smart Post – Post Grid, Post Carousel, Post Slider Gutenberg Blocks for Blog & News / 2.4.19
Smart Post – Post Grid, Post Carousel, Post Slider Gutenberg Blocks for Blog & News v2.4.19
4.0.8 4.0.7 4.0.6 4.0.5 4.0.4 4.0.3 4.0.2 4.0.1 2.3.5 2.3.6 2.4.0 2.4.1 2.4.10 2.4.11 2.4.12 2.4.13 2.4.14 2.4.15 2.4.16 2.4.17 2.4.18 2.4.19 2.4.2 2.4.20 2.4.21 All 88 releases
post-carousel / admin / views / configs / generator / class-sps-detailsettings.php

class-sps-detailsettings.php in Smart Post – Post Grid, Post Carousel, Post Slider Gutenberg Blocks for Blog & News 2.4.19, at admin/views/configs/generator/class-sps-detailsettings.php

260 lines 9.2 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * The Popup Settings Meta-box configurations.
4 *
5 * @package Smart_Post_Show
6 * @subpackage Smart_Post_Show/admin
7 */
8
9 if ( ! defined( 'ABSPATH' ) ) {
10 die;
11 } // Cannot access pages directly.
12
13 /**
14 * The Popup settings class.
15 */
16 class SPS_DetailSettings {
17
18 /**
19 * Popup settings section metabox.
20 *
21 * @param string $prefix The metabox key.
22 * @return void
23 */
24 public static function section( $prefix ) {
25 SP_PC::createSection(
26 $prefix,
27 array(
28 'title' => __( 'Detail page Settings', 'post-carousel' ),
29 'icon' => 'fa fa-external-link-square',
30 'fields' => array(
31 array(
32 'id' => 'pcp_page_link_type',
33 'class' => 'pcp_page_link_type',
34 'type' => 'radio',
35 'title' => __( 'Detail Page Link Type', 'post-carousel' ),
36 'subtitle' => __( 'Choose a link type for the (item) detail page.', 'post-carousel' ),
37 'options' => array(
38 'popup' => __( 'Popup (Pro)', 'post-carousel' ),
39 'single_page' => __( 'Single Page', 'post-carousel' ),
40 'none' => __( 'None (no link action)', 'post-carousel' ),
41 ),
42 'default' => 'single_page',
43 ),
44 array(
45 'id' => 'pcp_link_target',
46 'type' => 'radio',
47 'title' => __( 'Target', 'post-carousel' ),
48 'subtitle' => __( 'Set a target for the item link.', 'post-carousel' ),
49 'options' => array(
50 '_self' => __( 'Current Tab', 'post-carousel' ),
51 '_blank' => __( 'New Tab', 'post-carousel' ),
52 '_parent' => __( 'Parent', 'post-carousel' ),
53 '_top' => __( 'Top', 'post-carousel' ),
54 ),
55 'default' => '_self',
56 'dependency' => array( 'pcp_page_link_type', '==', 'single_page' ),
57 ),
58 array(
59 'id' => 'pcp_link_rel',
60 'type' => 'checkbox',
61 'title' => __( 'Add rel="nofollow" to item links', 'post-carousel' ),
62 'default' => false,
63 ),
64 array(
65 'type' => 'notice',
66 'content' => __( 'To unlock the following amazing Popup Settings</b>, <a href="//smartpostshow.com" target="_blank"><b>Upgrade To Pro!</b></a>', 'post-carousel' ),
67 ),
68 array(
69 'id' => 'pcp_popup_settings',
70 'class' => 'pcp_popup_settings_field',
71 'type' => 'fieldset',
72 'fields' => array(
73 array(
74 'id' => 'pcp_popup_type',
75 'type' => 'radio',
76 'title' => __( 'Popup Type', 'post-carousel' ),
77 'subtitle' => __( 'Choose a popup type.', 'post-carousel' ),
78 'options' => array(
79 'single_popup' => __( 'Single Popup', 'post-carousel' ),
80 'multi_popup' => __( 'Multi Popup (Preview with navigation)', 'post-carousel' ),
81 ),
82 'default' => 'single_popup',
83 ),
84 array(
85 'id' => 'popup_width',
86 'type' => 'spacing',
87 'title' => __( 'Maximum Width', 'post-carousel' ),
88 'subtitle' => __( 'Set maximum popup width.', 'post-carousel' ),
89 'all' => true,
90 'min' => 0,
91 'max' => 3000,
92 'all_icon' => '<i class="fa fa-arrows-h"></i>',
93 'units' => array( 'px', '%' ),
94 'default' => array(
95 'all' => '1050',
96 ),
97 ),
98 array(
99 'id' => 'popup_height',
100 'type' => 'spacing',
101 'title' => __( 'Maximum Height', 'post-carousel' ),
102 'subtitle' => __( 'Set maximum popup height.', 'post-carousel' ),
103 'all' => true,
104 'min' => 0,
105 'max' => 3000,
106 'all_icon' => '<i class="fa fa-arrows-v"></i>',
107 'units' => array( 'vh', 'px', '%' ),
108 'default' => array(
109 'all' => '700',
110 ),
111 ),
112 array(
113 'id' => 'popup_content_color',
114 'type' => 'color_group',
115 'title' => __( 'Content Color', 'post-carousel' ),
116 'subtitle' => __( 'Set the popup content color.', 'post-carousel' ),
117 'options' => array(
118 'post-title' => __( 'Post Title', 'post-carousel' ),
119 'post-meta' => __( 'Post Meta', 'post-carousel' ),
120 'post-content' => __( 'Post Content', 'post-carousel' ),
121 'custom-fields' => __( 'Custom Fields', 'post-carousel' ),
122 ),
123 'default' => array(
124 'post-title' => '#111',
125 'post-meta' => '#888',
126 'post-content' => '#444',
127 'custom-fields' => '#888',
128 ),
129 ),
130 array(
131 'id' => 'popup_bg_color',
132 'type' => 'color',
133 'title' => __( 'Background Color', 'post-carousel' ),
134 'subtitle' => __( 'Change the popup background color.', 'post-carousel' ),
135 'default' => '#fff',
136 ),
137 array(
138 'id' => 'popup_overlay_color',
139 'type' => 'color',
140 'title' => __( 'Overlay Color', 'post-carousel' ),
141 'subtitle' => __( 'Change the popup overlay color.', 'post-carousel' ),
142 'default' => 'rgba(11,11,11,0.8)',
143 ),
144 array(
145 'id' => 'popup_close_button',
146 'type' => 'switcher',
147 'title' => __( 'Close Button', 'post-carousel' ),
148 'subtitle' => __( 'Show/Hide popup close button.', 'post-carousel' ),
149 'text_on' => __( 'Show', 'post-carousel' ),
150 'text_off' => __( 'Hide', 'post-carousel' ),
151 'text_width' => 80,
152 'default' => true,
153 ),
154 array(
155 'id' => 'popup_close_button_color',
156 'type' => 'color_group',
157 'title' => __( 'Close Button Color', 'post-carousel' ),
158 'subtitle' => __( 'Change the popup close button color.', 'post-carousel' ),
159 'options' => array(
160 'color' => __( 'Color', 'post-carousel' ),
161 'hover-color' => __( 'Hover Color', 'post-carousel' ),
162 ),
163 'default' => array(
164 'color' => '#fc0c0c',
165 'hover-color' => '#e1624b',
166 ),
167 ),
168 array(
169 'id' => 'popup_nav_color',
170 'type' => 'color_group',
171 'title' => __( 'Navigation Color', 'post-carousel' ),
172 'subtitle' => __( 'Change the popup navigation color.', 'post-carousel' ),
173 'options' => array(
174 'color' => __( 'Color', 'post-carousel' ),
175 'hover-color' => __( 'Hover Color', 'post-carousel' ),
176 'bg' => __( 'Background', 'post-carousel' ),
177 'hover-bg' => __( 'Hover Background', 'post-carousel' ),
178 ),
179 'default' => array(
180 'color' => '#aaa',
181 'hover-color' => '#fff',
182 'bg' => 'rgba(0,0,0,0.5)',
183 'hover-bg' => '#e1624b',
184 ),
185 ),
186 array(
187 'id' => 'popup_post_content_sorter',
188 'type' => 'sortable',
189 'title' => __( 'Popup Fields', 'post-carousel' ),
190 'subtitle' => __( 'Show/Hide content fields in the popup. These fields are also sortable.', 'post-carousel' ),
191 'class' => 'post_content_sorter_sortable',
192 'default' => array(
193 'popup_show_post_thumb' => true,
194 'popup_show_post_title' => true,
195 'popup_show_post_meta' => true,
196 'popup_show_post_content' => true,
197 'popup_show_social_share' => true,
198 'popup_show_custom_fields' => false,
199 ),
200 'fields' => array(
201 array(
202 'id' => 'popup_show_post_thumb',
203 'type' => 'switcher',
204 'title' => __( 'Thumbnail', 'post-carousel' ),
205 'text_on' => __( 'Show', 'post-carousel' ),
206 'text_off' => __( 'Hide', 'post-carousel' ),
207 'text_width' => 80,
208 ),
209 array(
210 'id' => 'popup_show_post_title',
211 'type' => 'switcher',
212 'title' => __( 'Title', 'post-carousel' ),
213 'text_on' => __( 'Show', 'post-carousel' ),
214 'text_off' => __( 'Hide', 'post-carousel' ),
215 'text_width' => 80,
216 ),
217 array(
218 'id' => 'popup_show_post_meta',
219 'type' => 'switcher',
220 'title' => __( 'Meta Fields', 'post-carousel' ),
221 'text_on' => __( 'Show', 'post-carousel' ),
222 'text_off' => __( 'Hide', 'post-carousel' ),
223 'text_width' => 80,
224 ),
225 array(
226 'id' => 'popup_show_post_content',
227 'type' => 'switcher',
228 'title' => __( 'Content', 'post-carousel' ),
229 'text_on' => __( 'Show', 'post-carousel' ),
230 'text_off' => __( 'Hide', 'post-carousel' ),
231 'text_width' => 80,
232 ),
233 array(
234 'id' => 'popup_show_social_share',
235 'type' => 'switcher',
236 'title' => __( 'Social Share', 'post-carousel' ),
237 'text_on' => __( 'Show', 'post-carousel' ),
238 'text_off' => __( 'Hide', 'post-carousel' ),
239 'text_width' => 80,
240 ),
241 array(
242 'id' => 'popup_show_custom_fields',
243 'type' => 'switcher',
244 'title' => __( 'Custom Fields', 'post-carousel' ),
245 'text_on' => __( 'Show', 'post-carousel' ),
246 'text_off' => __( 'Hide', 'post-carousel' ),
247 'text_width' => 80,
248 ),
249
250 ),
251 ),
252 ),
253 ),
254
255 ), // End of fields array.
256 )
257 ); // Display settings section end.
258 }
259 }
260