PluginProbe
Smart Post – Post Grid, Post Carousel, Post Slider Gutenberg Blocks for Blog & News / 4.0.8
Smart Post – Post Grid, Post Carousel, Post Slider Gutenberg Blocks for Blog & News v4.0.8
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-typography.php

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

213 lines 7.1 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * The Typography Meta-box configurations.
4 *
5 * @package Smart_Post_Show
6 * @subpackage Smart_Post_Show/admin
7 */
8
9 if ( ! defined( 'ABSPATH' ) ) {
10 die; } // Cannot access pages directly.
11
12 /**
13 * The Typography class.
14 */
15 class SPS_Typography {
16
17 /**
18 * Typography section metabox.
19 *
20 * @param string $prefix The metabox key.
21 * @return void
22 */
23 public static function section( $prefix ) {
24 SP_PC::createSection(
25 $prefix,
26 array(
27 'title' => __( 'Typography', 'post-carousel' ),
28 'icon' => 'sps-icon-typography',
29 'enqueue_webfont' => true,
30 'fields' => array(
31 array(
32 'type' => 'notice',
33 'class' => 'taxonomy-ajax-filter-notice',
34 'content' => __( 'Want to easily customize everything (Typography, Colors, Margin)?', 'post-carousel' ) . ' <a href="https://wpsmartpost.com/pricing/?ref=1" target="_blank"><b>' . __( 'Upgrade To Pro!', 'post-carousel' ) . '</b></a> ' . __( 'P.S. Note: The color fields work in the lite version.', 'post-carousel' ),
35 ),
36 array(
37 'id' => 'section_title_typography',
38 'type' => 'typography',
39 'title' => __( 'Section Title', 'post-carousel' ),
40 'subtitle' => __( 'Set item showcase section title font properties.', 'post-carousel' ),
41 'default' => array(
42 'color' => '#444',
43 'font-family' => '',
44 'font-weight' => '',
45 'subset' => '',
46 'font-size' => '24',
47 'tablet-font-size' => '20',
48 'mobile-font-size' => '18',
49 'line-height' => '28',
50 'tablet-line-height' => '24',
51 'mobile-line-height' => '20',
52 'letter-spacing' => '0',
53 'text-align' => 'left',
54 'text-transform' => 'none',
55 'type' => '',
56 'unit' => 'px',
57 ),
58 'dependency' => array( 'section_title', '==', 'true', 'all' ),
59 ),
60 array(
61 'id' => 'section_title_margin',
62 'type' => 'spacing',
63 'title' => __( 'Section Title Margin', 'post-carousel' ),
64 'subtitle' => __( 'Set margin for the section title.', 'post-carousel' ),
65 'all_icon' => '<i class="fa fa-long-arrow-down"></i>',
66 'units' => array(
67 'px',
68 ),
69 'all_placeholder' => 'margin',
70 'default' => array(
71 'top' => '0',
72 'right' => '0',
73 'bottom' => '30',
74 'left' => '0',
75 ),
76 'dependency' => array(
77 'section_title',
78 '==',
79 'true',
80 true,
81 ),
82 ),
83 array(
84 'id' => 'post_title_typography',
85 'type' => 'typography',
86 'title' => __( 'Title', 'post-carousel' ),
87 'subtitle' => __( 'Set title font properties.', 'post-carousel' ),
88 'hover_color' => true,
89 'default' => array(
90 'color' => '#111',
91 'hover_color' => '#e1624b',
92 'font-family' => '',
93 'font-weight' => '',
94 'subset' => '',
95 'font-size' => '20',
96 'tablet-font-size' => '18',
97 'mobile-font-size' => '16',
98 'line-height' => '24',
99 'tablet-line-height' => '22',
100 'mobile-line-height' => '20',
101 'letter-spacing' => '0',
102 'text-align' => 'left',
103 'text-transform' => 'none',
104 'type' => '',
105 'unit' => 'px',
106 ),
107 'dependency' => array( 'show_post_title', '==', 'true', 'all' ),
108 ),
109 array(
110 'id' => 'post_meta_typography',
111 'type' => 'typography',
112 'title' => __( 'Meta Fields', 'post-carousel' ),
113 'subtitle' => __( 'Set meta fields font properties.', 'post-carousel' ),
114 'hover_color' => true,
115 'default' => array(
116 'color' => '#888',
117 'hover_color' => '#e1624b',
118 'font-family' => '',
119 'font-weight' => '',
120 'subset' => '',
121 'font-size' => '14',
122 'tablet-font-size' => '14',
123 'mobile-font-size' => '12',
124 'line-height' => '16',
125 'tablet-line-height' => '16',
126 'mobile-line-height' => '16',
127 'letter-spacing' => '0',
128 'text-align' => 'left',
129 'text-transform' => 'none',
130 'type' => '',
131 'unit' => 'px',
132 ),
133 ),
134 array(
135 'id' => 'post_content_typography',
136 'type' => 'typography',
137 'title' => __( 'Content', 'post-carousel' ),
138 'subtitle' => __( 'Set content font properties.', 'post-carousel' ),
139 'default' => array(
140 'color' => '#444',
141 'font-family' => '',
142 'font-weight' => '',
143 'subset' => '',
144 'font-size' => '16',
145 'tablet-font-size' => '14',
146 'mobile-font-size' => '12',
147 'line-height' => '20',
148 'tablet-line-height' => '18',
149 'mobile-line-height' => '18',
150 'letter-spacing' => '0',
151 'text-align' => 'left',
152 'text-transform' => 'none',
153 'type' => '',
154 'unit' => 'px',
155 ),
156 'dependency' => array( 'show_post_content', '==', 'true', 'all' ),
157 ),
158 array(
159 'id' => 'read_more_typography',
160 'type' => 'typography',
161 'title' => __( 'Read More', 'post-carousel' ),
162 'subtitle' => __( 'Set read more font properties.', 'post-carousel' ),
163 'color' => false,
164 'default' => array(
165 'font-family' => '',
166 'font-weight' => '600',
167 'subset' => '',
168 'font-size' => '12',
169 'tablet-font-size' => '12',
170 'mobile-font-size' => '10',
171 'line-height' => '18',
172 'tablet-line-height' => '18',
173 'mobile-line-height' => '16',
174 'letter-spacing' => '0',
175 'text-align' => 'left',
176 'text-transform' => 'uppercase',
177 'type' => '',
178 'unit' => 'px',
179 ),
180 'dependency' => array( 'show_read_more|show_post_content', '==|==', 'true|true', 'all' ),
181 ),
182
183 array(
184 'id' => 'custom_fields_typography',
185 'type' => 'typography',
186 'title' => __( 'Custom Fields', 'post-carousel' ),
187 'subtitle' => __( 'Set custom fields font properties.', 'post-carousel' ),
188 'color' => false,
189 'default' => array(
190 // 'color' => '#888',
191 // 'hover_color' => '#444',
192 'font-family' => '',
193 'font-weight' => '',
194 'subset' => '',
195 'font-size' => '14',
196 'tablet-font-size' => '14',
197 'mobile-font-size' => '12',
198 'line-height' => '18',
199 'tablet-line-height' => '18',
200 'mobile-line-height' => '16',
201 'letter-spacing' => '0',
202 'text-align' => 'left',
203 'text-transform' => 'none',
204 'type' => '',
205 'unit' => 'px',
206 ),
207 ),
208 ), // End of fields array.
209 )
210 );
211 }
212 }
213