<?php
/**
 * http://pluginscorner.com
 *
 * @package instant-post-types
 */

if ( ! defined( 'ABSPATH' ) ) {
	exit; // Silence is golden
}

?>
<h5><?php echo __( 'Advanced Settings', CPT_PC_Const::T ) ?></h5>
<div class="cpt-pc-row">
	<div class="cpt-pc-col cpt-pc-s4 cpt-pc-input-field">
		<input placeholder="Query Var" name="query_var" value="<#= model.get('query_var') #>" id="ect-cpt-query-var" class="cpt-pc-input-change" type="text">
		<label for="ect-cpt-query-var"><?php echo __( 'Query Var', CPT_PC_Const::T ) ?></label>
		<i class="cpt-pc-material-icons cpt-pc-info-icon cpt-pc-tooltipped" data-position="top"
		   data-tooltip="Sets the query_var key for this post type.">info_outline</i>
	</div>
	<div class="cpt-pc-col cpt-pc-s4 cpt-pc-input-field">
		<input placeholder="The Position in the menu" name="menu_position" value="<#= model.get('menu_position') #>" id="ect-cpt-menu-position" type="number" class="cpt-pc-input-change">
		<label for="ect-cpt-menu-position"><?php echo __( 'The position in the menu', CPT_PC_Const::T ) ?></label>
		<i class="cpt-pc-material-icons cpt-pc-info-icon cpt-pc-tooltipped" data-position="top"
		   data-tooltip="The position in the menu order the post type should appear. Show in menu must be set to yes.">info_outline</i>
	</div>
	<div class="cpt-pc-col cpt-pc-s4 cpt-pc-input-field">
		<input placeholder="Meta box callback function" name="register_meta_box_cb" value="<#= model.get('register_meta_box_cb') #>" id="ect-cpt-meta-box-cb" class="cpt-pc-input-change"
			   type="text">
		<label for="ect-cpt-meta-box-cb"><?php echo __( 'Meta box callback', CPT_PC_Const::T ) ?></label>
		<i class="cpt-pc-material-icons cpt-pc-info-icon cpt-pc-tooltipped" data-position="top"
		   data-tooltip="Please leave this empty if you don't know what this does.">info_outline</i>
	</div>

	<div class="cpt-pc-col cpt-pc-s4 cpt-pc-input-field">
		<input placeholder="Rewrite the slug" name="rewrite" value="<#= model.get('rewrite').slug #>" id="ect-cpt-rewrite-slug" class="cpt-pc-input-change" type="text">
		<label for="ect-cpt-rewrite-slug"><?php echo __( 'Rewrite the slug', CPT_PC_Const::T ) ?></label>
		<i class="cpt-pc-material-icons cpt-pc-info-icon cpt-pc-tooltipped" data-position="top"
		   data-tooltip="Customize the permalink structure slug. Should be translatable.">info_outline</i>
	</div>
</div>
<div class="cpt-pc-row">
	<div class="cpt-pc-col cpt-pc-s12">
		<label for="cpt-pc-supports"><?php echo __( 'Supports ?', CPT_PC_Const::T ) ?></label>
		<div class="cpt-pc-switch">
			<label>
				<?php echo __( 'No', CPT_PC_Const::T ) ?>
				<input id="cpt-pc-supports" class="cpt-pc-toggle-options" name="supports"
				<#= model.get('supports') ? 'checked="checked"' : '' #> type="checkbox">
					<span class="cpt-pc-lever"></span>
					<?php echo __( 'Yes', CPT_PC_Const::T ) ?>
			</label>
		</div>
	</div>
	<div class="cpt-pc-row ect-no-margin ect-options-toggle"></div>
</div>
<div class="cpt-pc-row">
	<div class="cpt-pc-col cpt-pc-s3">
		<label for="ect-cpt-exclude"><?php echo __( 'Exclude from search ?', CPT_PC_Const::T ) ?></label>
		<div class="cpt-pc-switch">
			<label>
				<?php echo __( 'No', CPT_PC_Const::T ) ?>
				<input id="ect-cpt-exclude" name="exclude_from_search"
				<#= model.get('exclude_from_search') ? 'checked="checked"' : '' #> type="checkbox">
					<span class="cpt-pc-lever"></span>
					<?php echo __( 'Yes', CPT_PC_Const::T ) ?>
			</label>
		</div>
	</div>

	<div class="cpt-pc-col cpt-pc-s3">
		<label for="ect-cpt-queryable"><?php echo __( 'Is it publicly queryable ?', CPT_PC_Const::T ) ?></label>
		<div class="cpt-pc-switch">
			<label>
				<?php echo __( 'No', CPT_PC_Const::T ) ?>
				<input id="ect-cpt-queryable" name="publicly_queryable"
				<#= model.get('publicly_queryable') ? 'checked="checked"' : '' #> type="checkbox">
					<span class="cpt-pc-lever"></span>
					<?php echo __( 'Yes', CPT_PC_Const::T ) ?>
			</label>
		</div>
	</div>

	<div class="cpt-pc-col cpt-pc-s3">
		<label for="ect-cpt-show-nav"><?php echo __( 'Show in nav menus ?', CPT_PC_Const::T ) ?></label>
		<div class="cpt-pc-switch">
			<label>
				<?php echo __( 'No', CPT_PC_Const::T ) ?>
				<input id="ect-cpt-show-nav" name="show_in_nav_menus"
				<#= model.get('show_in_nav_menus') ? 'checked="checked"' : '' #> type="checkbox">
					<span class="cpt-pc-lever"></span>
					<?php echo __( 'Yes', CPT_PC_Const::T ) ?>
			</label>
		</div>
	</div>

	<div class="cpt-pc-col cpt-pc-s3">
		<label for="ect-cpt-show-admin"><?php echo __( 'Show in the Admin Bar ?', CPT_PC_Const::T ) ?></label>
		<div class="cpt-pc-switch">
			<label>
				<?php echo __( 'No', CPT_PC_Const::T ) ?>
				<input id="ect-cpt-show-admin" name="show_in_admin_bar"
				<#= model.get('show_in_admin_bar') ? 'checked="checked"' : '' #> type="checkbox">
					<span class="cpt-pc-lever"></span>
					<?php echo __( 'Yes', CPT_PC_Const::T ) ?>
			</label>
		</div>
	</div>
</div>
<div class="cpt-pc-row">
	<div class="cpt-pc-col cpt-pc-s3">
		<label for="ect-cpt-has-archive"><?php echo __( 'Will it have an Archive ?', CPT_PC_Const::T ) ?></label>
		<div class="cpt-pc-switch">
			<label>
				<?php echo __( 'No', CPT_PC_Const::T ) ?>
				<input id="ect-cpt-has-archive" name="has_archive"
				<#= model.get('has_archive') ? 'checked="checked"' : '' #> type="checkbox">
					<span class="cpt-pc-lever"></span>
					<?php echo __( 'Yes', CPT_PC_Const::T ) ?>
			</label>
		</div>
	</div>

	<div class="cpt-pc-col cpt-pc-s3">
		<label for="ect-cpt-can-export"><?php echo __( 'Can this Post Type be exported ?', CPT_PC_Const::T ) ?></label>
		<div class="cpt-pc-switch">
			<label>
				<?php echo __( 'No', CPT_PC_Const::T ) ?>
				<input id="ect-cpt-can-export" name="can_export"
				<#= model.get('can_export') ? 'checked="checked"' : '' #> type="checkbox">
					<span class="cpt-pc-lever"></span>
					<?php echo __( 'Yes', CPT_PC_Const::T ) ?>
			</label>
		</div>
	</div>

	<div class="cpt-pc-col cpt-pc-s3">
		<label for="ect-cpt-delete-user"><?php echo __( 'Delete posts when deleting a user ?', CPT_PC_Const::T ) ?></label>
		<div class="cpt-pc-switch">
			<label>
				<?php echo __( 'No', CPT_PC_Const::T ) ?>
				<input id="ect-cpt-delete-user" name="delete_with_user"
				<#= model.get('delete_with_user') ? 'checked="checked"' : '' #> type="checkbox">
					<span class="cpt-pc-lever"></span>
					<?php echo __( 'Yes', CPT_PC_Const::T ) ?>
			</label>
		</div>
	</div>
    <div class="cpt-pc-col cpt-pc-s3">
        <label for="ect-cpt-delete-user"><?php echo __( 'Include in REST API ?', CPT_PC_Const::T ) ?></label>
        <div class="cpt-pc-switch">
            <label>
                <?php echo __( 'No', CPT_PC_Const::T ) ?>
                <input id="ect-cpt-delete-user" name="show_in_rest"
                <#= model.get('show_in_rest') ? 'checked="checked"' : '' #> type="checkbox">
                <span class="cpt-pc-lever"></span>
                <?php echo __( 'Yes', CPT_PC_Const::T ) ?>
            </label>
        </div>
    </div>
</div>
