-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathfunctions.php
66 lines (55 loc) · 1.58 KB
/
functions.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
<?php
/**
* Key functions for the Neve child theme.
*
* @package tgwf
*/
if ( ! defined( 'ABSPATH' ) ) {
exit;
}
require 'inc/enqueue.php';
require 'inc/widgets.php';
require 'inc/patterns.php';
require 'inc/news-archive.php';
require 'inc/after-single-posts.php';
require 'inc/fellowship-post.php';
require 'inc/publication-report.php';
require 'inc/rss-newsletter.php';
// Add theme support for gradients, and define them.
add_theme_support(
'editor-gradient-presets',
array(
array(
'name' => __( 'White to primary', 'tgwf' ),
'gradient' => 'linear-gradient(145deg, rgb(255,255,255) 15%, rgb(0,255,0) 100%)',
'slug' => 'white-to-primary',
),
array(
'name' => __( 'Primary to white', 'tgwf' ),
'gradient' => 'linear-gradient(145deg, rgb(0,255,0) 15%, rgb(255,255,255) 100%)',
'slug' => 'primary-to-white',
),
array(
'name' => __( 'White to blue', 'tgwf' ),
'gradient' => 'linear-gradient(145deg, rgb(255,255,255) 15%, rgb(0,102,255) 100%)',
'slug' => 'white-to-blue',
),
array(
'name' => __( 'White to orange', 'tgwf' ),
'gradient' => 'linear-gradient(145deg, rgb(255,255,255) 15%, rgb(250,170,0) 100%)',
'slug' => 'white-to-orange',
),
)
);
add_action( 'init', 'register_acf_blocks' );
function register_acf_blocks() {
register_block_type( __DIR__ . '/blocks/threecols--title-para-button' );
}
add_filter( 'body_class', 'add_slug_body_class' );
function add_slug_body_class( $classes ) {
global $post;
if ( isset( $post ) ) {
$classes[] = $post->post_type . '-' . $post->post_name;
}
return $classes;
}