<?php
/**
 * Typography Setting
 *
 * @package aster_portfolio
 */

// Typography Setting
$wp_customize->add_section(
    'aster_portfolio_typography_setting',
    array(
        'panel' => 'aster_portfolio_theme_options',
        'title' => esc_html__( 'Typography Setting', 'aster-portfolio' ),
    )
);

$wp_customize->add_setting(
    'aster_portfolio_site_title_font',
    array(
        'default'           => 'Eater',
        'sanitize_callback' => 'aster_portfolio_sanitize_google_fonts',
    )
);

$wp_customize->add_control(
    'aster_portfolio_site_title_font',
    array(
        'label'    => esc_html__( 'Site Title Font Family', 'aster-portfolio' ),
        'section'  => 'aster_portfolio_typography_setting',
        'settings' => 'aster_portfolio_site_title_font',
        'type'     => 'select',
        'choices'  => aster_portfolio_get_all_google_font_families(),
    )
);

// Typography - Site Description Font.
$wp_customize->add_setting(
	'aster_portfolio_site_description_font',
	array(
		'default'           => 'Sora',
		'sanitize_callback' => 'aster_portfolio_sanitize_google_fonts',
	)
);

$wp_customize->add_control(
	'aster_portfolio_site_description_font',
	array(
		'label'    => esc_html__( 'Site Description Font Family', 'aster-portfolio' ),
		'section'  => 'aster_portfolio_typography_setting',
		'settings' => 'aster_portfolio_site_description_font',
		'type'     => 'select',
		'choices'  => aster_portfolio_get_all_google_font_families(),
	)
);

// Typography - Header Font.
$wp_customize->add_setting(
	'aster_portfolio_header_font',
	array(
		'default'           => 'DM Sans',
		'sanitize_callback' => 'aster_portfolio_sanitize_google_fonts',
	)
);

$wp_customize->add_control(
	'aster_portfolio_header_font',
	array(
		'label'    => esc_html__( 'Heading Font Family', 'aster-portfolio' ),
		'section'  => 'aster_portfolio_typography_setting',
		'settings' => 'aster_portfolio_header_font',
		'type'     => 'select',
		'choices'  => aster_portfolio_get_all_google_font_families(),
	)
);

// Typography - Body Font.
$wp_customize->add_setting(
	'aster_portfolio_content_font',
	array(
		'default'           => 'Sora',
		'sanitize_callback' => 'aster_portfolio_sanitize_google_fonts',
	)
);

$wp_customize->add_control(
	'aster_portfolio_content_font',
	array(
		'label'    => esc_html__( 'Content Font Family', 'aster-portfolio' ),
		'section'  => 'aster_portfolio_typography_setting',
		'settings' => 'aster_portfolio_content_font',
		'type'     => 'select',
		'choices'  => aster_portfolio_get_all_google_font_families(),
	)
);