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

// Typography Setting
$wp_customize->add_section(
    'appointment_management_typography_setting',
    array(
        'panel' => 'appointment_management_theme_options',
        'title' => esc_html__( 'Typography Setting', 'appointment-management' ),
    )
);

$wp_customize->add_setting(
    'appointment_management_site_title_font',
    array(
        'default'           => 'Open Sans',
        'sanitize_callback' => 'appointment_management_sanitize_google_fonts',
    )
);

$wp_customize->add_control(
    'appointment_management_site_title_font',
    array(
        'label'    => esc_html__( 'Site Title Font Family', 'appointment-management' ),
        'section'  => 'appointment_management_typography_setting',
        'settings' => 'appointment_management_site_title_font',
        'type'     => 'select',
        'choices'  => appointment_management_get_all_google_font_families(),
    )
);

// Typography - Site Description Font.
$wp_customize->add_setting(
	'appointment_management_site_description_font',
	array(
		'default'           => 'Open Sans',
		'sanitize_callback' => 'appointment_management_sanitize_google_fonts',
	)
);

$wp_customize->add_control(
	'appointment_management_site_description_font',
	array(
		'label'    => esc_html__( 'Site Description Font Family', 'appointment-management' ),
		'section'  => 'appointment_management_typography_setting',
		'settings' => 'appointment_management_site_description_font',
		'type'     => 'select',
		'choices'  => appointment_management_get_all_google_font_families(),
	)
);

// Typography - Header Font.
$wp_customize->add_setting(
	'appointment_management_header_font',
	array(
		'default'           => 'Open Sans',
		'sanitize_callback' => 'appointment_management_sanitize_google_fonts',
	)
);

$wp_customize->add_control(
	'appointment_management_header_font',
	array(
		'label'    => esc_html__( 'Heading Font Family', 'appointment-management' ),
		'section'  => 'appointment_management_typography_setting',
		'settings' => 'appointment_management_header_font',
		'type'     => 'select',
		'choices'  => appointment_management_get_all_google_font_families(),
	)
);

// Typography - Body Font.
$wp_customize->add_setting(
	'appointment_management_content_font',
	array(
		'default'           => 'Open Sans',
		'sanitize_callback' => 'appointment_management_sanitize_google_fonts',
	)
);

$wp_customize->add_control(
	'appointment_management_content_font',
	array(
		'label'    => esc_html__( 'Content Font Family', 'appointment-management' ),
		'section'  => 'appointment_management_typography_setting',
		'settings' => 'appointment_management_content_font',
		'type'     => 'select',
		'choices'  => appointment_management_get_all_google_font_families(),
	)
);
