CFF_Builder_Customizer_Tab.php
1 month ago
CFF_Customize_Tab.php
1 month ago
CFF_Settings_Tab.php
1 month ago
CFF_Styling_Tab.php
1 month ago
index.php
1 month ago
CFF_Styling_Tab.php
733 lines
| 1 | <?php |
| 2 | |
| 3 | /** |
| 4 | * Styling Tab |
| 5 | * Contains different controls for the individual Elements |
| 6 | * |
| 7 | * @since 4.0 |
| 8 | */ |
| 9 | |
| 10 | namespace CustomFacebookFeed\Builder\Tabs; |
| 11 | |
| 12 | if (!defined('ABSPATH')) { |
| 13 | exit; |
| 14 | } |
| 15 | |
| 16 | class CFF_Styling_Tab |
| 17 | { |
| 18 | /** |
| 19 | * Get Customize Tab Individual Elements Nested Section |
| 20 | * |
| 21 | * @since 4.0 |
| 22 | * @return array |
| 23 | */ |
| 24 | public static function post_styling_author() |
| 25 | { |
| 26 | return [ |
| 27 | [ |
| 28 | 'type' => 'separator', |
| 29 | 'top' => 20, |
| 30 | 'bottom' => 5, |
| 31 | ], |
| 32 | [ |
| 33 | 'type' => 'heading', |
| 34 | 'heading' => __('Text', 'custom-facebook-feed'), |
| 35 | ], |
| 36 | [ |
| 37 | 'type' => 'select', |
| 38 | 'id' => 'authorsize', |
| 39 | 'layout' => 'half', |
| 40 | 'strongHeading' => 'false', |
| 41 | 'heading' => __('Size', 'custom-facebook-feed'), |
| 42 | 'stacked' => 'true', |
| 43 | 'style' => ['.cff-post-item-author-name' => 'font-size:{{value}}px!important;'], |
| 44 | 'options' => CFF_Builder_Customizer_Tab::get_text_size_options() |
| 45 | ], |
| 46 | [ |
| 47 | 'type' => 'colorpicker', |
| 48 | 'id' => 'authorcolor', |
| 49 | 'layout' => 'half', |
| 50 | 'strongHeading' => 'false', |
| 51 | 'heading' => __('Color', 'custom-facebook-feed'), |
| 52 | 'style' => ['.cff-post-item-author-name' => 'color:{{value}}!important;'], |
| 53 | 'stacked' => 'true' |
| 54 | ] |
| 55 | ]; |
| 56 | } |
| 57 | |
| 58 | |
| 59 | /** |
| 60 | * Get Customize Tab Individual Elements Nested Section |
| 61 | * |
| 62 | * @since 4.0 |
| 63 | * @return array |
| 64 | */ |
| 65 | public static function post_styling_text() |
| 66 | { |
| 67 | return [ |
| 68 | [ |
| 69 | 'type' => 'separator', |
| 70 | 'top' => 20, |
| 71 | 'bottom' => 5, |
| 72 | ], |
| 73 | [ |
| 74 | 'type' => 'heading', |
| 75 | 'heading' => __('Text', 'custom-facebook-feed'), |
| 76 | ], |
| 77 | [ |
| 78 | 'type' => 'select', |
| 79 | 'id' => 'textsize', |
| 80 | 'layout' => 'half', |
| 81 | 'strongHeading' => 'false', |
| 82 | 'heading' => __('Size', 'custom-facebook-feed'), |
| 83 | 'style' => ['.cff-post-item-text' => 'font-size:{{value}}px!important;'], |
| 84 | 'stacked' => 'true', |
| 85 | 'options' => CFF_Builder_Customizer_Tab::get_text_size_options() |
| 86 | ], |
| 87 | [ |
| 88 | 'type' => 'colorpicker', |
| 89 | 'id' => 'textcolor', |
| 90 | 'layout' => 'half', |
| 91 | 'strongHeading' => 'false', |
| 92 | 'style' => ['.cff-post-item-text,[data-preview-colorscheme="light"] .cff-post-item-text a,[data-preview-colorscheme="dark"] .cff-post-item-text a' => 'color:{{value}};'], |
| 93 | 'heading' => __('Color', 'custom-facebook-feed'), |
| 94 | 'stacked' => 'true' |
| 95 | ], |
| 96 | [ |
| 97 | 'type' => 'number', |
| 98 | 'id' => 'textlength', |
| 99 | 'stacked' => 'true', |
| 100 | 'fieldSuffix' => __('characters', 'custom-facebook-feed'), |
| 101 | 'placeholder' => '200', |
| 102 | 'layout' => 'half', |
| 103 | 'description' => __('Max Length', 'custom-facebook-feed'), |
| 104 | ], |
| 105 | [ |
| 106 | 'type' => 'separator', |
| 107 | 'top' => 10, |
| 108 | 'bottom' => 10, |
| 109 | ], |
| 110 | [ |
| 111 | 'type' => 'switcher', |
| 112 | 'id' => 'textlink', |
| 113 | 'label' => __('Link text to Facebook post', 'custom-facebook-feed'), |
| 114 | 'stacked' => 'true', |
| 115 | 'labelStrong' => 'true', |
| 116 | 'options' => [ |
| 117 | 'enabled' => 'on', |
| 118 | 'disabled' => '' |
| 119 | ] |
| 120 | ], |
| 121 | ]; |
| 122 | } |
| 123 | |
| 124 | |
| 125 | /** |
| 126 | * Get Customize Tab Individual Elements Nested Section |
| 127 | * |
| 128 | * @since 4.0 |
| 129 | * @return array |
| 130 | */ |
| 131 | public static function post_styling_date() |
| 132 | { |
| 133 | return [ |
| 134 | [ |
| 135 | 'type' => 'separator', |
| 136 | 'top' => 20, |
| 137 | 'bottom' => 15, |
| 138 | ], |
| 139 | [ |
| 140 | 'type' => 'heading', |
| 141 | 'stacked' => 'true', |
| 142 | 'heading' => __('Format', 'custom-facebook-feed'), |
| 143 | ], |
| 144 | [ |
| 145 | 'type' => 'select', |
| 146 | 'id' => 'dateformat', |
| 147 | 'strongHeading' => 'false', |
| 148 | 'stacked' => 'true', |
| 149 | 'options' => CFF_Builder_Customizer_Tab::get_date_format_options() |
| 150 | ], |
| 151 | [ |
| 152 | 'type' => 'text', |
| 153 | 'id' => 'datecustom', |
| 154 | 'condition' => ['dateformat' => ['custom']], |
| 155 | 'conditionHide' => true, |
| 156 | 'stacked' => 'true', |
| 157 | 'placeholder' => 'Eg. F j, Y', |
| 158 | ], |
| 159 | [ |
| 160 | 'type' => 'heading', |
| 161 | 'stacked' => 'true', |
| 162 | 'condition' => ['dateformat' => ['custom']], |
| 163 | 'conditionHide' => true, |
| 164 | 'heading' => sprintf(__('%sLearn more about custom formats %s', 'custom-facebook-feed'), '<a class="sb-customizer-ctrl-link" href="https://smashballoon.com/doc/date-formatting-reference/?utm_campaign=facebook-free&utm_source=customizer&utm_medium=docs" target="_blank" rel="noopener">', '</a>'), |
| 165 | ], |
| 166 | [ |
| 167 | 'type' => 'checkbox', |
| 168 | 'id' => 'beforedateenabled', |
| 169 | 'label' => __('Add text before date', 'custom-facebook-feed'), |
| 170 | 'reverse' => 'true', |
| 171 | 'stacked' => 'true', |
| 172 | 'options' => [ |
| 173 | 'enabled' => 'on', |
| 174 | 'disabled' => 'off' |
| 175 | ] |
| 176 | ], |
| 177 | [ |
| 178 | 'type' => 'text', |
| 179 | 'id' => 'beforedate', |
| 180 | 'condition' => ['beforedateenabled' => ['on']], |
| 181 | 'conditionHide' => true, |
| 182 | 'stacked' => 'true', |
| 183 | ], |
| 184 | [ |
| 185 | 'type' => 'checkbox', |
| 186 | 'id' => 'afterdateenabled', |
| 187 | 'label' => __('Add text after date', 'custom-facebook-feed'), |
| 188 | 'reverse' => 'true', |
| 189 | 'stacked' => 'true', |
| 190 | 'options' => [ |
| 191 | 'enabled' => 'on', |
| 192 | 'disabled' => 'off' |
| 193 | ] |
| 194 | ], |
| 195 | [ |
| 196 | 'type' => 'text', |
| 197 | 'id' => 'afterdate', |
| 198 | 'condition' => ['afterdateenabled' => ['on']], |
| 199 | 'conditionHide' => true, |
| 200 | 'stacked' => 'true', |
| 201 | ], |
| 202 | [ |
| 203 | 'type' => 'separator', |
| 204 | 'top' => 25, |
| 205 | 'bottom' => 10, |
| 206 | ], |
| 207 | [ |
| 208 | 'type' => 'heading', |
| 209 | 'heading' => __('Text', 'custom-facebook-feed'), |
| 210 | ], |
| 211 | [ |
| 212 | 'type' => 'select', |
| 213 | 'id' => 'datesize', |
| 214 | 'layout' => 'half', |
| 215 | 'strongHeading' => 'false', |
| 216 | 'heading' => __('Size', 'custom-facebook-feed'), |
| 217 | 'stacked' => 'true', |
| 218 | 'style' => ['.cff-post-item-date' => 'font-size:{{value}}px!important;'], |
| 219 | 'options' => CFF_Builder_Customizer_Tab::get_text_size_options() |
| 220 | ], |
| 221 | [ |
| 222 | 'type' => 'colorpicker', |
| 223 | 'id' => 'datecolor', |
| 224 | 'layout' => 'half', |
| 225 | 'strongHeading' => 'false', |
| 226 | 'heading' => __('Color', 'custom-facebook-feed'), |
| 227 | 'style' => ['.cff-post-item-date' => 'color:{{value}}!important;'], |
| 228 | 'stacked' => 'true' |
| 229 | ] |
| 230 | |
| 231 | ]; |
| 232 | } |
| 233 | |
| 234 | |
| 235 | /** |
| 236 | * Get Customize Tab Individual Elements Nested Section |
| 237 | * |
| 238 | * @since 4.0 |
| 239 | * @return array |
| 240 | */ |
| 241 | public static function post_styling_media() |
| 242 | { |
| 243 | |
| 244 | return [ |
| 245 | [ |
| 246 | 'type' => 'checkbox', |
| 247 | 'id' => 'oneimage', |
| 248 | 'label' => __('Use only one image per post', 'custom-facebook-feed'), |
| 249 | 'reverse' => 'true', |
| 250 | 'options' => [ |
| 251 | 'enabled' => 'on', |
| 252 | 'disabled' => '' |
| 253 | ] |
| 254 | ], |
| 255 | ]; |
| 256 | } |
| 257 | |
| 258 | |
| 259 | /** |
| 260 | * Get Customize Tab Individual Elements Nested Section |
| 261 | * |
| 262 | * @since 4.0 |
| 263 | * @return array |
| 264 | */ |
| 265 | public static function post_styling_social() |
| 266 | { |
| 267 | return [ |
| 268 | [ |
| 269 | 'type' => 'separator', |
| 270 | 'top' => 20, |
| 271 | 'bottom' => 5, |
| 272 | ], |
| 273 | [ |
| 274 | 'type' => 'toggleset', |
| 275 | 'id' => 'iconstyle', |
| 276 | 'heading' => __('Icon Theme', 'custom-facebook-feed'), |
| 277 | 'options' => [ |
| 278 | [ |
| 279 | 'value' => 'auto', |
| 280 | 'icon' => 'cog', |
| 281 | 'label' => __('Auto', 'custom-facebook-feed') |
| 282 | ], |
| 283 | [ |
| 284 | 'value' => 'light', |
| 285 | 'icon' => 'sun', |
| 286 | 'label' => __('Light', 'custom-facebook-feed') |
| 287 | ], |
| 288 | [ |
| 289 | 'value' => 'dark', |
| 290 | 'icon' => 'moon', |
| 291 | 'label' => __('Dark', 'custom-facebook-feed') |
| 292 | ] |
| 293 | ] |
| 294 | ], |
| 295 | [ |
| 296 | 'type' => 'separator', |
| 297 | 'top' => 10, |
| 298 | 'bottom' => 0, |
| 299 | ], |
| 300 | [ |
| 301 | 'type' => 'heading', |
| 302 | 'heading' => __('Color', 'custom-facebook-feed'), |
| 303 | ], |
| 304 | [ |
| 305 | 'type' => 'colorpicker', |
| 306 | 'id' => 'socialtextcolor', |
| 307 | 'layout' => 'half', |
| 308 | 'strongHeading' => 'false', |
| 309 | 'heading' => __('Text', 'custom-facebook-feed'), |
| 310 | 'style' => ['.cff-post-meta-txt' => 'color:{{value}}!important;'], |
| 311 | 'stacked' => 'true' |
| 312 | ], |
| 313 | [ |
| 314 | 'type' => 'colorpicker', |
| 315 | 'id' => 'sociallinkcolor', |
| 316 | 'layout' => 'half', |
| 317 | 'strongHeading' => 'false', |
| 318 | 'heading' => __('Link', 'custom-facebook-feed'), |
| 319 | 'style' => ['.cff-post-meta-link' => 'color:{{value}}!important;'], |
| 320 | 'stacked' => 'true' |
| 321 | ], |
| 322 | [ |
| 323 | 'type' => 'colorpicker', |
| 324 | 'id' => 'socialbgcolor', |
| 325 | 'layout' => 'half', |
| 326 | 'strongHeading' => 'false', |
| 327 | 'heading' => __('Background', 'custom-facebook-feed'), |
| 328 | 'style' => ['.cff-post-item-meta-bg' => 'background:{{value}}!important;'], |
| 329 | 'stacked' => 'true' |
| 330 | ], |
| 331 | [ |
| 332 | 'type' => 'separator', |
| 333 | 'top' => 15, |
| 334 | 'bottom' => 15, |
| 335 | ], |
| 336 | [ |
| 337 | 'type' => 'switcher', |
| 338 | 'id' => 'expandcomments', |
| 339 | 'label' => __('Expand Comments box by default', 'custom-facebook-feed'), |
| 340 | 'ajaxAction' => 'feedPreviewRender', |
| 341 | 'stacked' => 'true', |
| 342 | 'labelStrong' => 'true', |
| 343 | 'options' => [ |
| 344 | 'enabled' => 'on', |
| 345 | 'disabled' => 'off' |
| 346 | ] |
| 347 | ], |
| 348 | [ |
| 349 | 'type' => 'separator', |
| 350 | 'top' => 15, |
| 351 | 'bottom' => 15, |
| 352 | ], |
| 353 | [ |
| 354 | 'type' => 'switcher', |
| 355 | 'id' => 'hidecommentimages', |
| 356 | 'label' => __('Hide Comment Avatars', 'custom-facebook-feed'), |
| 357 | 'stacked' => 'true', |
| 358 | 'labelStrong' => 'true', |
| 359 | 'options' => [ |
| 360 | 'enabled' => 'on', |
| 361 | 'disabled' => '' |
| 362 | ] |
| 363 | ], |
| 364 | [ |
| 365 | 'type' => 'separator', |
| 366 | 'top' => 15, |
| 367 | 'bottom' => 15, |
| 368 | ], |
| 369 | [ |
| 370 | 'type' => 'switcher', |
| 371 | 'id' => 'lightboxcomments', |
| 372 | 'label' => __('Show comments in Lightbox', 'custom-facebook-feed'), |
| 373 | 'stacked' => 'true', |
| 374 | 'labelStrong' => 'true', |
| 375 | 'options' => [ |
| 376 | 'enabled' => 'on', |
| 377 | 'disabled' => '' |
| 378 | ] |
| 379 | ], |
| 380 | |
| 381 | ]; |
| 382 | } |
| 383 | |
| 384 | |
| 385 | /** |
| 386 | * Get Customize Tab Individual Elements Nested Section |
| 387 | * |
| 388 | * @since 4.0 |
| 389 | * @return array |
| 390 | */ |
| 391 | public static function post_styling_eventtitle() |
| 392 | { |
| 393 | return [ |
| 394 | [ |
| 395 | 'type' => 'separator', |
| 396 | 'top' => 20, |
| 397 | 'bottom' => 20, |
| 398 | ], |
| 399 | [ |
| 400 | 'type' => 'select', |
| 401 | 'id' => 'eventtitlesize', |
| 402 | 'strongHeading' => 'false', |
| 403 | 'heading' => __('Text Size', 'custom-facebook-feed'), |
| 404 | 'stacked' => 'true', |
| 405 | 'style' => ['.cff-post-event-title' => 'font-size:{{value}}px!important;'], |
| 406 | 'options' => CFF_Builder_Customizer_Tab::get_text_size_options() |
| 407 | ], |
| 408 | [ |
| 409 | 'type' => 'colorpicker', |
| 410 | 'id' => 'eventtitlecolor', |
| 411 | 'strongHeading' => 'false', |
| 412 | 'heading' => __('Text Color', 'custom-facebook-feed'), |
| 413 | 'style' => ['.cff-post-event-title' => 'color:{{value}}!important;'], |
| 414 | 'stacked' => 'true' |
| 415 | ] |
| 416 | ]; |
| 417 | } |
| 418 | |
| 419 | |
| 420 | /** |
| 421 | * Get Customize Tab Individual Elements Nested Section |
| 422 | * |
| 423 | * @since 4.0 |
| 424 | * @return array |
| 425 | */ |
| 426 | public static function post_styling_eventdetails() |
| 427 | { |
| 428 | return [ |
| 429 | [ |
| 430 | 'type' => 'separator', |
| 431 | 'top' => 20, |
| 432 | 'bottom' => 20, |
| 433 | ], |
| 434 | [ |
| 435 | 'type' => 'select', |
| 436 | 'id' => 'eventdetailssize', |
| 437 | 'strongHeading' => 'false', |
| 438 | 'heading' => __('Text Size', 'custom-facebook-feed'), |
| 439 | 'stacked' => 'true', |
| 440 | 'style' => ['.cff-post-event-location' => 'font-size:{{value}}px!important;'], |
| 441 | 'options' => CFF_Builder_Customizer_Tab::get_text_size_options() |
| 442 | ], |
| 443 | [ |
| 444 | 'type' => 'colorpicker', |
| 445 | 'id' => 'eventdetailscolor', |
| 446 | 'strongHeading' => 'false', |
| 447 | 'heading' => __('Text Color', 'custom-facebook-feed'), |
| 448 | 'style' => ['.cff-post-event-location' => 'color:{{value}}!important;'], |
| 449 | 'stacked' => 'true' |
| 450 | ] |
| 451 | ]; |
| 452 | } |
| 453 | |
| 454 | |
| 455 | /** |
| 456 | * Get Customize Tab Individual Elements Nested Section |
| 457 | * |
| 458 | * @since 4.0 |
| 459 | * @return array |
| 460 | */ |
| 461 | public static function post_styling_link() |
| 462 | { |
| 463 | return [ |
| 464 | [ |
| 465 | 'type' => 'separator', |
| 466 | 'top' => 20, |
| 467 | 'bottom' => 5, |
| 468 | ], |
| 469 | [ |
| 470 | 'type' => 'heading', |
| 471 | 'heading' => __('Text', 'custom-facebook-feed'), |
| 472 | ], |
| 473 | [ |
| 474 | 'type' => 'select', |
| 475 | 'id' => 'linksize', |
| 476 | 'layout' => 'half', |
| 477 | 'strongHeading' => 'false', |
| 478 | 'heading' => __('Size', 'custom-facebook-feed'), |
| 479 | 'stacked' => 'true', |
| 480 | 'style' => ['.cff-post-item-action-txt' => 'font-size:{{value}}px!important;'], |
| 481 | 'options' => CFF_Builder_Customizer_Tab::get_text_size_options() |
| 482 | ], |
| 483 | [ |
| 484 | 'type' => 'colorpicker', |
| 485 | 'id' => 'linkcolor', |
| 486 | 'layout' => 'half', |
| 487 | 'strongHeading' => 'false', |
| 488 | 'heading' => __('Color', 'custom-facebook-feed'), |
| 489 | 'style' => ['.cff-post-item-action-txt' => 'color:{{value}}!important;'], |
| 490 | 'stacked' => 'true' |
| 491 | ], |
| 492 | [ |
| 493 | 'type' => 'separator', |
| 494 | 'top' => 15, |
| 495 | 'bottom' => 15, |
| 496 | ], |
| 497 | [ |
| 498 | 'type' => 'switcher', |
| 499 | 'id' => 'showfacebooklink', |
| 500 | 'layout' => 'half', |
| 501 | 'reverse' => 'true', |
| 502 | 'heading' => __('View on Facebook link', 'custom-facebook-feed'), |
| 503 | 'description' => __('Toggle “View on Facebook” link below each post', 'custom-facebook-feed'), |
| 504 | 'stacked' => 'true', |
| 505 | 'labelStrong' => 'true', |
| 506 | 'switcherTop' => 'true', |
| 507 | 'options' => [ |
| 508 | 'enabled' => 'true', |
| 509 | 'disabled' => 'false' |
| 510 | ] |
| 511 | ], |
| 512 | [ |
| 513 | 'type' => 'text', |
| 514 | 'id' => 'facebooklinktext', |
| 515 | 'condition' => ['showfacebooklink' => ['true']], |
| 516 | 'strongHeading' => 'false', |
| 517 | 'stacked' => 'true', |
| 518 | 'child' => 'true', |
| 519 | 'description' => __('Customize Text', 'custom-facebook-feed'), |
| 520 | ], |
| 521 | [ |
| 522 | 'type' => 'separator', |
| 523 | 'top' => 15, |
| 524 | 'bottom' => 15, |
| 525 | ], |
| 526 | [ |
| 527 | 'type' => 'switcher', |
| 528 | 'id' => 'showsharelink', |
| 529 | 'layout' => 'half', |
| 530 | 'reverse' => 'true', |
| 531 | 'heading' => __('Share link', 'custom-facebook-feed'), |
| 532 | 'description' => __('Toggle “Share” link below each post', 'custom-facebook-feed'), |
| 533 | 'stacked' => 'true', |
| 534 | 'labelStrong' => 'true', |
| 535 | 'switcherTop' => 'true', |
| 536 | 'options' => [ |
| 537 | 'enabled' => 'true', |
| 538 | 'disabled' => 'false' |
| 539 | ] |
| 540 | ], |
| 541 | [ |
| 542 | 'type' => 'text', |
| 543 | 'id' => 'sharelinktext', |
| 544 | 'condition' => ['showsharelink' => ['true']], |
| 545 | 'strongHeading' => 'false', |
| 546 | 'stacked' => 'true', |
| 547 | 'child' => 'true', |
| 548 | 'description' => __('Customize Text', 'custom-facebook-feed'), |
| 549 | ], |
| 550 | ]; |
| 551 | } |
| 552 | |
| 553 | |
| 554 | /** |
| 555 | * Get Customize Tab Individual Elements Nested Section |
| 556 | * |
| 557 | * @since 4.0 |
| 558 | * @return array |
| 559 | */ |
| 560 | public static function post_styling_desc() |
| 561 | { |
| 562 | |
| 563 | return [ |
| 564 | [ |
| 565 | 'type' => 'separator', |
| 566 | 'top' => 20, |
| 567 | 'bottom' => 20, |
| 568 | ], |
| 569 | [ |
| 570 | 'type' => 'select', |
| 571 | 'id' => 'descsize', |
| 572 | 'strongHeading' => 'false', |
| 573 | 'heading' => __('Text Size', 'custom-facebook-feed'), |
| 574 | 'stacked' => 'true', |
| 575 | 'options' => CFF_Builder_Customizer_Tab::get_text_size_options() |
| 576 | ], |
| 577 | [ |
| 578 | 'type' => 'colorpicker', |
| 579 | 'id' => 'desccolor', |
| 580 | 'strongHeading' => 'false', |
| 581 | 'heading' => __('Text Color', 'custom-facebook-feed'), |
| 582 | 'stacked' => 'true' |
| 583 | ] |
| 584 | ]; |
| 585 | } |
| 586 | |
| 587 | |
| 588 | /** |
| 589 | * Get Customize Tab Individual Elements Nested Section |
| 590 | * |
| 591 | * @since 4.0 |
| 592 | * @return array |
| 593 | */ |
| 594 | public static function post_styling_sharedlinks() |
| 595 | { |
| 596 | return [ |
| 597 | [ |
| 598 | 'type' => 'separator', |
| 599 | 'top' => 20, |
| 600 | 'bottom' => 5, |
| 601 | ], |
| 602 | [ |
| 603 | 'type' => 'heading', |
| 604 | 'heading' => __('Box Style', 'custom-facebook-feed'), |
| 605 | ], |
| 606 | [ |
| 607 | 'type' => 'colorpicker', |
| 608 | 'id' => 'linkbgcolor', |
| 609 | 'layout' => 'half', |
| 610 | 'strongHeading' => 'false', |
| 611 | 'condition' => ['disablelinkbox' => ['off']], |
| 612 | 'heading' => __('Background Color', 'custom-facebook-feed'), |
| 613 | 'style' => ['.cff-post-item-link-ctn[data-linkbox="off"]' => 'background:{{value}}!important;'], |
| 614 | 'stacked' => 'true' |
| 615 | ], |
| 616 | [ |
| 617 | 'type' => 'colorpicker', |
| 618 | 'id' => 'linkbordercolor', |
| 619 | 'layout' => 'half', |
| 620 | 'strongHeading' => 'false', |
| 621 | 'condition' => ['disablelinkbox' => ['off']], |
| 622 | 'heading' => __('Border Color', 'custom-facebook-feed'), |
| 623 | 'style' => ['.cff-post-item-link-ctn[data-linkbox="off"]' => 'border-color:{{value}}!important;'], |
| 624 | 'stacked' => 'true' |
| 625 | ], |
| 626 | [ |
| 627 | 'type' => 'checkbox', |
| 628 | 'id' => 'disablelinkbox', |
| 629 | 'label' => __('Remove Background/Border', 'custom-facebook-feed'), |
| 630 | 'reverse' => 'true', |
| 631 | 'options' => [ |
| 632 | 'enabled' => 'on', |
| 633 | 'disabled' => 'off' |
| 634 | ] |
| 635 | ], |
| 636 | [ |
| 637 | 'type' => 'separator', |
| 638 | 'top' => 5, |
| 639 | 'bottom' => 5, |
| 640 | ], |
| 641 | [ |
| 642 | 'type' => 'heading', |
| 643 | 'heading' => __('Link Title', 'custom-facebook-feed'), |
| 644 | ], |
| 645 | [ |
| 646 | 'type' => 'select', |
| 647 | 'id' => 'linktitlesize', |
| 648 | 'layout' => 'half', |
| 649 | 'strongHeading' => 'false', |
| 650 | 'heading' => __('Text Size', 'custom-facebook-feed'), |
| 651 | 'stacked' => 'true', |
| 652 | 'style' => ['.cff-post-item-link-a' => 'font-size:{{value}}px!important;'], |
| 653 | 'options' => CFF_Builder_Customizer_Tab::get_text_size_options() |
| 654 | ], |
| 655 | [ |
| 656 | 'type' => 'colorpicker', |
| 657 | 'id' => 'linktitlecolor', |
| 658 | 'layout' => 'half', |
| 659 | 'strongHeading' => 'false', |
| 660 | 'heading' => __('Text Color', 'custom-facebook-feed'), |
| 661 | 'style' => ['.cff-post-item-link-a' => 'color:{{value}}!important;'], |
| 662 | 'stacked' => 'true' |
| 663 | ], |
| 664 | [ |
| 665 | 'type' => 'separator', |
| 666 | 'top' => 20, |
| 667 | 'bottom' => 5, |
| 668 | ], |
| 669 | [ |
| 670 | 'type' => 'heading', |
| 671 | 'heading' => __('Link URL', 'custom-facebook-feed'), |
| 672 | ], |
| 673 | [ |
| 674 | 'type' => 'select', |
| 675 | 'id' => 'linkurlsize', |
| 676 | 'layout' => 'half', |
| 677 | 'strongHeading' => 'false', |
| 678 | 'heading' => __('Text Size', 'custom-facebook-feed'), |
| 679 | 'stacked' => 'true', |
| 680 | 'style' => ['.cff-post-item-link-small' => 'font-size:{{value}}px!important;'], |
| 681 | 'options' => CFF_Builder_Customizer_Tab::get_text_size_options() |
| 682 | ], |
| 683 | [ |
| 684 | 'type' => 'colorpicker', |
| 685 | 'id' => 'linkurlcolor', |
| 686 | 'layout' => 'half', |
| 687 | 'strongHeading' => 'false', |
| 688 | 'heading' => __('Text Color', 'custom-facebook-feed'), |
| 689 | 'style' => ['.cff-post-item-link-small' => 'color:{{value}}!important;'], |
| 690 | 'stacked' => 'true' |
| 691 | ], |
| 692 | [ |
| 693 | 'type' => 'separator', |
| 694 | 'top' => 20, |
| 695 | 'bottom' => 5, |
| 696 | ], |
| 697 | [ |
| 698 | 'type' => 'heading', |
| 699 | 'heading' => __('Link Description', 'custom-facebook-feed'), |
| 700 | ], |
| 701 | [ |
| 702 | 'type' => 'select', |
| 703 | 'id' => 'linkdescsize', |
| 704 | 'layout' => 'half', |
| 705 | 'strongHeading' => 'false', |
| 706 | 'heading' => __('Text Size', 'custom-facebook-feed'), |
| 707 | 'stacked' => 'true', |
| 708 | 'style' => ['.cff-post-item-link-description' => 'font-size:{{value}}px!important;'], |
| 709 | 'options' => CFF_Builder_Customizer_Tab::get_text_size_options() |
| 710 | ], |
| 711 | [ |
| 712 | 'type' => 'colorpicker', |
| 713 | 'id' => 'linkdesccolor', |
| 714 | 'layout' => 'half', |
| 715 | 'strongHeading' => 'false', |
| 716 | 'heading' => __('Text Color', 'custom-facebook-feed'), |
| 717 | 'style' => ['.cff-post-item-link-description' => 'color:{{value}}!important;'], |
| 718 | 'stacked' => 'true' |
| 719 | ], |
| 720 | [ |
| 721 | 'type' => 'number', |
| 722 | 'id' => 'desclength', |
| 723 | 'stacked' => 'true', |
| 724 | 'fieldSuffix' => __('characters', 'custom-facebook-feed'), |
| 725 | 'placeholder' => '400', |
| 726 | 'layout' => 'half', |
| 727 | 'description' => __('Maximum Text Length', 'custom-facebook-feed'), |
| 728 | ], |
| 729 | |
| 730 | ]; |
| 731 | } |
| 732 | } |
| 733 |