<?php

function socity_post_metabox($options){

	$options[] = array(
		'id'	=>	'socity_slider_meta',
		'title'	=>	esc_html__('Slider Options','socitycore'),
		'post_type'	=>	'slider',
		'context'	=>	'normal',
		'priority'	=>	'high',
		'sections'	=> array(
			array(
				'name'	=> 'socity_project_options_meta',
				'title'	=> esc_html__('Project Option MetaBox','socitycore'),
				'fields'=> array(
					
					array(
					  	'id'       => 'socity_slider_hadding',
					  	'type'     => 'wysiwyg',
					  	'title'    => esc_html__('Slider Big Hadding','socitycore'),
						'desc'	=> esc_html__('Please Type Slider Big Hadding','socitycore'),
						'settings' => array(
							'media_buttons' => false,
						),
					  	'default'  => wp_kses(
							__( '<h1>We do provide creative IT Solution For your Business!</h1>', 'socitycore' ),
							array(
									'span' => array(),
									'strong' => array(),
									'h1' => array(),
									'h2' => array(),
									'h3' => array(),
							)
						),
					),
					array(
						'type'    => 'subheading',
						'content' => esc_html__('Buttons One Options','socitycore')
					),
					array(
					  	'id'       => 'socity_slide_button_test',
					  	'type'     => 'text',
					  	'title'    => esc_html__('Button-1 Text','socitycore'),
					  	'desc'	=> esc_html__('Please Type Button Text','socitycore'),
					  	'default'  => esc_html__('Learn More','socitycore')
					),
					array(
					  	'id'       => 'socity_slide_button_link',
					  	'type'     => 'text',
					  	'title'    => esc_html__('Button-1 Link','socitycore'),
					  	'desc'	=> esc_html__('Please Type Button Link Here.','socitycore'),
					),
					array(
						'type'    => 'subheading',
						'content' => esc_html__('Video Buttons Options','socitycore')
					),
					array(
					  	'id'       => 'socity_slide_button2_test',
					  	'type'     => 'wysiwyg',
					  	'title'    => esc_html__('Video Button Text','socitycore'),
					  	'desc'	=> esc_html__('Please Type Button Text','socitycore'),
						'settings' => array(
							'textarea_rows' => 0,
						    'tinymce'       => false,
						    'media_buttons' => false,
						    'quicktags' => false,
						),
					  	'default'  => wp_kses(
							__( 'Play Our New Video', 'socitycore' ),
							array(
								'span' => array(),
							)
						),
					),
					array(
					  	'id'       	=> 'socity_slide_button2_link',
					  	'type'     	=> 'text',
					  	'title'    	=> esc_html__('Video Link','socitycore'),
						'desc'	=> esc_html__('Please Add Youtube or Vimeo Video link.','socitycore'),
						'default' 	=> esc_html__('https://www.youtube.com/watch?v=u8Egk_j0EbY','socitycore')
					),
				)
			)
		)
	);


	$options[] = array(
		'id'	=>	'socity_project_meta',
		'title'	=>	esc_html__('Project Options','socitycore'),
		'post_type'	=>	'project',
		'context'	=>	'normal',
		'priority'	=>	'high',
		'sections'	=> array(
			array(
				'name'	=> 'socity_project_options_meta',
				'title'	=> esc_html__('Project Option MetaBox','socitycore'),
				'fields'=> array(
					array(
					  	'id'        => 'socity_pro_title',
					  	'type'      => 'text',
					  	'title'     => esc_html__('Project Title','socitycore'),
					  	'desc'	   	=> esc_html__('Please Type Project Title here','socitycore'),
					  	'default'	=> esc_html__('Business Agency ','socitycore')
					),
					array(
					  	'id'       => 'socity_pro_client',
					  	'type'     => 'text',
					  	'title'    => esc_html__('Project Client','socitycore'),
					  	'desc'	   => esc_html__('Please Type Project Client Name here','socitycore'),
					  	'default'  => esc_html__('Mahi Al Rabbi','socitycore')
					),
					array(
					  	'id'       => 'socity_pro_status',
					  	'type'     => 'text',
					  	'title'    => esc_html__('Project Status','socitycore'),
					  	'desc'	   => esc_html__('Please Type Project Status here','socitycore'),
					  	'default'  => esc_html__('Complete','socitycore')
					),
					array(
					  	'id'       => 'socity_pro_date',
					  	'type'     => 'text',
					  	'title'    => esc_html__('Project Date','socitycore'),
					  	'desc'	   => esc_html__('Please Type Project Date here','socitycore'),
					  	'default'  => esc_html__('05 August 2019','socitycore')
					),
					array(
					  	'id'       => 'socity_pro_value',
					  	'type'     => 'text',
					  	'title'    => esc_html__('Project Value','socitycore'),
					  	'desc'	   => esc_html__('Please Type Project Status here','socitycore'),
					  	'default'  => esc_html__('$500','socitycore')
					),

					array(
					  	'id'       => 'socity_pro_video_link',
					  	'type'     => 'text',
					  	'title'    => esc_html__('Project Project video Link','socitycore'),
					  	'desc'	   => esc_html__('Add Project video link','socitycore'),
					  	'default'	 => esc_html__('https://www.youtube.com/watch?v=u8Egk_j0EbY','socitycore'),
					),
				)
			)
		)
	);
    $options[] = array(
        'id'	=>	'socity_team_meta',
        'title'	=>	esc_html__('Team Options','socitycore'),
        'post_type'	=>	'team',
        'context'	=>	'normal',
        'priority'	=>	'high',
        'sections'	=> array(
            array(
                'name'	=> 'socity_team_options_meta',
                'title'	=> esc_html__('Project Option MetaBox','socitycore'),
                'fields'=> array(
                    array(
                        'id'        => 'socity_team_stitle',
                        'type'      => 'text',
                        'title'     => esc_html__('Designation','socitycore'),
                        'desc'	   	=> esc_html__('Please Type Designation here','socitycore'),
                        'default'	=> esc_html__('CEO & Founder ','socitycore')
                    ),
                    array(
                        'id'       => 'socity_team_age',
                        'type'     => 'text',
                        'title'    => esc_html__('Age','socitycore'),
                        'desc'	   => esc_html__('Please Type Age here','socitycore'),
                        'default'  => esc_html__('24','socitycore')
                    ),
                    array(
                        'id'       => 'socity_team_blood',
                        'type'     => 'text',
                        'title'    => esc_html__('Blood Group','socitycore'),
                        'desc'	   => esc_html__('Please Type Blood Group here','socitycore'),
                        'default'  => esc_html__('o+','socitycore')
                    ),
                    array(
                        'id'       => 'socity_team_work_pro',
                        'type'     => 'text',
                        'title'    => esc_html__('Work Progress','socitycore'),
                        'desc'	   => esc_html__('Please Type Work Progress here','socitycore'),
                        'default'  => esc_html__('100%','socitycore')
                    ),
                    array(
                        'id'       => 'socity_team_email',
                        'type'     => 'text',
                        'title'    => esc_html__('Email','socitycore'),
                        'desc'	   => esc_html__('Please Type Email here','socitycore'),
                        'default'  => esc_html__('alex24@example.com','socitycore')
                    ),

                    array(
                        'id'       => 'socity_team_phone',
                        'type'     => 'text',
                        'title'    => esc_html__('Phone Number','socitycore'),
                        'desc'	   => esc_html__('Add Phone Number Here','socitycore'),
                        'default'	 => esc_html__('+555 6666 77 88','socitycore'),
                    ),
                    array(
                        'id'              => 'socity_team_socials',
                        'type'            => 'group',
                        'title'           => esc_html__('Team Social','socitycore'),
                        'desc'    		  => esc_html__('Choose your Social media','socitycore'),
                        'button_title'    => esc_html__('Add New','socitycore'),
                        'accordion_title' => esc_html__('Add New Social Link','socitycore'),
                        'fields'          => array(
                            array(
                                'id'      => 'socity_social_link_text',
                                'type'    => 'text',
                                'title'   => esc_html__('Add social Name','socitycore'),
                                'desc'    => esc_html__('Please Type your Social Name','socitycore'),
                                'default'    => esc_html__('Facebook','socitycore'),
                            ),
                            array(
                                'id'      => 'socity_social_link',
                                'type'    => 'text',
                                'title'   => esc_html__('Add social link','socitycore'),
                                'desc'    => esc_html__('Please Type your Social Link','socitycore'),
                                'default'    => esc_html__('#','socitycore'),
                            ),
                            array(
                                'id'      => 'socity_social_link_icon',
                                'type'    => 'icon',
                                'title'   => esc_html__('Add social icon','socitycore'),
                                'desc'    => esc_html__('Please Select Social icon','socitycore'),
                                'default' => 'fa fa-facebook',
                            ),
                        ),
                    ),
                )
            )
        )
    );
	// Post formate Metabox
	$options[] = array(
		'id'	=>	'socity_pfv_meta',
		'title'	=>	esc_html__('Video Metabox','socitycore'),
		'post_type'	=>	'post',
		'context'	=>	'normal',
		'priority'	=>	'high',
		'sections'	=> array(
			array(
				'name'	=> 'socity_pfv_option_meta',
				'fields'=> array(
					array(
					  	'id'       => 'socity_pfv_link',
					  	'type'     => 'text',
					  	'title'    => esc_html__('Extranal Video Link','socitycore'),
					  	'desc'	   => esc_html__('Please Add Vimeo or Youtube Video Embed Link Here','socitycore'),
					),
				)
			)
		)
	);
	$options[] = array(
		'id'	=>	'socity_pfa_meta',
		'title'	=>	esc_html__('Audio Metabox','socitycore'),
		'post_type'	=>	'post',
		'context'	=>	'normal',
		'priority'	=>	'high',
		'sections'	=> array(
			array(
				'name'	=> 'socity_pfa_option_meta',
				'fields'=> array(
					array(
					  	'id'       => 'socity_pfa_link',
					  	'type'     => 'text',
					  	'title'    => esc_html__('Extranal Audio Link','socitycore'),
					  	'desc'	=> esc_html__('Please Add Extranal Post Audio Link Here','socitycore'),
					),
				)
			)
		)
	);
	$options[] = array(
		'id'	=>	'socity_pfg_meta',
		'title'	=>	esc_html__('Gallery Metabox','socitycore'),
		'post_type'	=>	'post',
		'context'	=>	'normal',
		'priority'	=>	'high',
		'sections'	=> array(
			array(
				'name'	=> 'socity_pfg_option_meta',
				'fields'=> array(
					array(
					  	'id'       => 'socity_pfg_link',
					  	'type'     => 'gallery',
					  	'title'    => esc_html__('Extranal Gallery','socitycore'),
					  	'desc'	   => esc_html__('Please Add Extranal Post Gallery Here','socitycore'),
					),
				)
			)
		)
	);

/** PAGE META OPTIONS **/
	$options[]    = array(
		'id'        => 'socity_page_meta_options',
		'title'     => esc_html__('Page Options','socitycore'),
		'post_type' => array('page','post','project','team'),
		'context'   => 'normal',
		'priority'  => 'default',
		'sections'  => array(
			array(
		      	'name'  	=> 'socity_page_heaer_options',
		      	'title' 	=> esc_html__('Header','socitycore'),
		      	'icon'  	=> esc_attr__('fa fa-map-signs','socitycore'),
		      	'fields' 	=> array(
					array(
						'id'        => 'socity_page_header_enable',
						'type'      => 'switcher',
						'title'     => esc_html__('Change Header ?','socitycore'),
						'default'  	=> false
					),
					array(
						'id'        => 'socity_page_header_select',
						'type'      => 'select',
						'title'     => esc_html__('Select Header','socitycore'),
						'options'   => array(
							'0'   => esc_html__('default','socitycore'),
							'1'   => esc_html__('Style 1','socitycore'),
							'2'   => esc_html__('Style 2','socitycore'),
							'3'   => esc_html__('Style 3','socitycore'),
							'4'   => esc_html__('Style 4','socitycore'),
							'5'   => esc_html__('Style 5','socitycore'),
						),
						'default'	=> '0',
						'desc'	=> esc_html__('if your need change style just select (Yes) options. Default select 1','socitycore'),
						'dependency'   => array( 'socity_page_header_enable', '==', 'true' ),
						
					),
					array(
						'id'      => 'socity_header_top_bg',
						'type'    => 'color_picker',
						'title'   => esc_html__('Header TopBar Background Color','socitycore'),
						'default' => '#ffffff',
						'rgba'    => true,
						'dependency'   => array( 'socity_page_header_select', '==', '2' ),
					),
					array(
						'id'      => 'socity_main_header_bg',
						'type'    => 'color_picker',
						'title'   => esc_html__('Header Main Background Color','socitycore'),
						'default' => '#0b5be0',
						'rgba'    => true,
						'dependency'   => array( 'socity_page_header_select', '==', '2' ),
					),
					array(
						'id'      => 'socity_logo_bg_color',
						'type'    => 'color_picker',
						'title'   => esc_html__('Logo Background Color','socitycore'),
						'default' => '#0b5be0',
						'rgba'    => true,
						'dependency'   => array( 'socity_page_header_select', '==', '4' ),
					),
					array(
						'id'    	=> 'socity_logo_hedigh',
						'type'  	=> 'text',
						'default'	=>  '132px',
						'title' 	=> esc_html__('Logo Height','socitycore'),
						'desc' 	=> esc_html__('Insert custom text for the page title bar.','socitycore'),
						'dependency'   => array( 'socity_page_header_select', '==', '4' ),
					),
					array(
						'id'    	=> 'socity_logo_widght',
						'type'  	=> 'text',
						'default'	=>'140px',
						'title' 	=> esc_html__('Logo Widht','socitycore'),
						'desc' 	=> esc_html__('Add logo area Width','socitycore'),
						'dependency'   => array( 'socity_page_header_select', '==', '4' ),
					),
					array(
						'id'      => 'socity_logo_bg_color5',
						'type'    => 'color_picker',
						'title'   => esc_html__('Logo Background Color','socitycore'),
						'default' => '#ffffff',
						'rgba'    => true,
						'dependency'   => array( 'socity_page_header_select', '==', '5' ),
					),
					array(
						'id'      => 'socity_menu5_color',
						'type'    => 'color_picker',
						'title'   => esc_html__('Header Text Color','socitycore'),
						'default' => '#ffffff',
						'rgba'    => true,
						'dependency'   => array( 'socity_page_header_select', '==', '5' ),
					),
					array(
						'id'      => 'socity_menu5_hcolor',
						'type'    => 'color_picker',
						'title'   => esc_html__('Header Text Hover Color','socitycore'),
						'default' => '#000000',
						'rgba'    => true,
						'dependency'   => array( 'socity_page_header_select', '==', '5' ),
					),
					array(
						'id'    	=> 'socity_logo_hedigh5',
						'type'  	=> 'text',
						'default'	=> '120px',
						'title' 	=> esc_html__('Logo Height','socitycore'),
						'desc' 	=> esc_html__('Insert custom text for the page title bar.','socitycore'),
						'dependency'   => array( 'socity_page_header_select', '==', '5' ),
					),
					array(
						'id'    	=> 'socity_logo_widght5',
						'type'  	=> 'text',
						'default'	=>'120px',
						'title' 	=> esc_html__('Logo Widht','socitycore'),
						'desc' 	=> esc_html__('Add logo area Width','socitycore'),
						'dependency'   => array( 'socity_page_header_select', '==', '5' ),
					),
					array(
						'type'    => 'subheading',
						'content' => esc_html__('Logo Upload Options','socitycore'),
					    ),
					array(
						'id'    	=> 'socity_page_logo_enable',
						'title'   	=> esc_html__('Enable Uplod Logo ?','socitycore'),
						'type'   	=> 'switcher',
						'default' 	=> false,
						'desc'	=> esc_html__('Choose to show or hide Options','socitycore'),
					),
					array(
						'id'        => 'socity_page_logo_upload',
						'type'      => 'image',
						'title'     => esc_html__('Upload Logo','socitycore'),
						'add_title' => esc_html__('Add Logo','socitycore'),
						'dependency'   => array( 'socity_page_logo_enable', '==', 'true' ),
					),
				),
			),
			array(
		      	'name'  	=> 'socity_page_title_bar',
		      	'title' 	=> esc_html__('Page Title Bar','socitycore'),
		      	'icon'  	=> esc_attr__('fa fa-map-signs','socitycore'),
		      	'fields' 	=> array(
					array(
						'id'    	=> 'socity_page_title_enable',
						'title'   	=> esc_html__('Page Title Enable','socitycore'),
						'type'   	=> 'switcher',
						'default' 	=> true,
						'desc'		=> esc_html__('Choose to show or hide the page title bar','socitycore'),
					),
					array(
						'id'    	=> 'socity_custom_page_title',
						'type'  	=> 'text',
						'title' 	=> esc_html__('Custom page title bar.','socitycore'),
						'desc' 		=> esc_html__('Insert custom text for the page title bar.','socitycore'),
						'dependency'   => array( 'socity_page_title_enable', '==', 'true' ),
					),
				),
			),
		),
	);
return $options;
}
add_filter('cs_metabox_options','socity_post_metabox');
