-
Notifications
You must be signed in to change notification settings - Fork 0
/
functions.php
executable file
·50 lines (40 loc) · 1.72 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
<?php
function my_et_enqueue_styles() {
wp_enqueue_style( 'parent-style', get_template_directory_uri() . '/style.css' );
wp_enqueue_style( 'custom-css', mix('/dist/css/styles.css',['is_child'=>true,'manifest_directory' => 'dist']));
wp_enqueue_script( 'custom-js', mix('/dist/js/scripts.js',['is_child'=>true,'manifest_directory' => 'dist']), array('jquery'));
}
add_action( 'wp_enqueue_scripts', 'my_et_enqueue_styles' );
/* === Add your own functions below this line ===
* -------------------------------------------- */
/*
add_action( 'after_setup_theme', 'my_custom_image_sizes' );
function my_custom_image_sizes() {
if ( function_exists( 'add_image_size' ) ) {
add_image_size( 'designers-square', 567, 421, true );
add_image_size( 'hero-rectangle', 1220, 830, true );
add_image_size( 'square-v1', 345, 378, true );
add_image_size( 'portrait-lg', 756, 945, true );
add_image_size( 'portrait-md', 612, 834, true );
add_image_size( 'square-v2', 800, 800, true );
}
}
*/
// This enables the function that lets you set new image sizes
add_theme_support( 'post-thumbnails' );
// These are the new image sizes we cooked up
// Now we register the size so it appears as an option within the editor
/*
add_filter( 'image_size_names_choose', 'my_custom_image_sizes_chooser' );
function my_custom_image_sizes_chooser( $sizes ) {
return array_merge( $sizes, array(
'designers-square' => __( 'Designers square' ),
'hero-rectangle' => __( 'Hero (rectangle)' ),
'square-v1' => __( 'Square medium' ),
'square-v2' => __( 'Square large' ),
'portrait-lg' => __( 'Portrait Large' ),
'portrait-md' => __( 'Portrait Medium' ),
) );
}
*/
?>