wordpress/wp-content/themes/basic/themify/megamenu/class-mega-menu.php
/**
 * Add the option to enable mega menu to taxonomy menu types
 *
 * @since 1.0.0
 */
Add the option to enable mega menu to taxonomy menu types
@since 1.0.0
Add the option to enable mega menu to taxonomy menu types @since 1 . 0 . 0
function themify_menu_mega_option( $item_id, $item, $depth, $args ) {
		$dropdown_columns = (int) get_post_meta( $item_id, '_themify_dropdown_columns', true );
		$is_mega = themify_is_mega_menu_type( $item_id, 'mega' );
		$is_column = !$is_mega && themify_is_mega_menu_type( $item_id, 'column' );
		$is_dropdown_column = !$is_column && ! empty( $dropdown_columns );
		$column_layout = get_post_meta( $item_id, '_themify_mega_menu_columns_layout', true );
		?>
		<div class="field-tf-mega description description-thin">
			<label for="edit-menu-item-tf-mega-<?php echo $item_id; ?>">
			<?php _e( 'Mega Menu', 'themify' ) ?>
			<a href="https://themify.me/docs/ultra-documentation#mega-menu" target="_blank"><i class="ti-help"></i></a>
			<br />
				<select name="menu-item-tf-mega[<?php echo $item_id; ?>]" id="edit-menu-item-tf-mega-<?php echo $item_id?>" class="edit-menu-item-tf-mega themify_field_tf-mega widefat"> 
					<option value=""></option>
					<option value="mega" <?php if( $is_mega ) echo 'selected';?>><?php _e( 'Mega Posts', 'themify' ); ?></option>
					<option value="columns" <?php if( $is_column ) echo 'selected';?>><?php _e( 'Fullwidth Columns', 'themify' ); ?></option>
				<option value="drop" <?php if( $is_dropdown_column===true ) echo 'selected';?>><?php _e( 'Dropdown Columns', 'themify' ); ?></option>
				</select>
			</label>
			<div class="tf-mega-columns-layout">
				<?php
				echo '<input type="hidden" name="menu-item-tf-mega-columns-layout[' . $item_id . ']" value="" class="val">';
				foreach ( array(
					'' => __( 'Auto', 'themify' ),
					'4-8' => __( '1/3 - 2/3', 'themify' ),
					'8-4' => __( '2/3 - 1/3', 'themify' ),
					'6-3-3' => __( '2/4 - 1/4 - 1/4', 'themify' ),
					'3-3-6' => __( '1/4 - 1/4 - 2/4', 'themify' ),
					'3-6-3' => __( '1/4 - 2/4 - 1/4', 'themify' ),
					'3-9' => __( '1/4 - 3/4', 'themify' ),
					'9-3' => __( '3/4 - 1/4', 'themify' ),
				) as $key => $label ) {
					$selected = $column_layout === $key ? 'class="selected"' : '';
					echo '<a href="#" ' . $selected . ' data-value="'. $key . '" title="' . $label . '"></a>';
				}
				?>
			</div>
		</div>
	<p class="tf-dropdown-columns-field description description-thin">
		<label for="edit-menu-item-tf-dropdown-columns-<?php echo $item_id; ?>">	
			<?php _e( 'Dropdown Columns', 'themify' ) ?><br />
			<select name="menu-item-tf-dropdown_columns[<?php echo $item_id; ?>]" id="edit-menu-item-tf-dropdown_columns-<?php echo $item_id?>" class="edit-menu-item-tf-dropdown_columns">
				<option value=""></option>
				<option value="2" <?php selected( 2, $dropdown_columns ) ?>>2</option>
				<option value="3" <?php selected( 3, $dropdown_columns ) ?>>3</option>
				<option value="4" <?php selected( 4, $dropdown_columns ) ?>>4</option>
			</select>
		</label>
	</p>
	<?php
			$allow_hightlight = apply_filters( 'themify_menu_highlight_link', false);
			if ($allow_hightlight) :
			$highlight = get_post_meta( $item_id, '_themify_highlight_link', true );
		?>
			<div class="field-tf-highlight description description-thin"><br>
				<label for="edit-menu-item-tf-highlight-<?php echo $item_id; ?>">
					<input type="checkbox" name="menu-item-tf-highlight[<?php echo $item_id; ?>]" value="1" <?php echo ($highlight ? 'checked="checked"' : ''); ?> id="edit-menu-item-tf-highlight-<?php echo $item_id?>" class="edit-menu-item-tf-highlight themify_field_tf-highlight widefat"> 
				<?php _e( 'Highlight this link', 'themify' ) ?><br />
				</label>
			</div>
		<?php endif;
}
function themify_menu_mega_option ( $ item_id , $ item , $ depth , $ args ) { $ dropdown_columns = ( int ) get_post_meta ( $ item_id , '_themify_dropdown_columns' , true ) ; $ is_mega = themify_is_mega_menu_type ( $ item_id , 'mega' ) ; $ is_column = ! $ is_mega && themify_is_mega_menu_type ( $ item_id , 'column' ) ; $ is_dropdown_column = ! $ is_column && ! empty ( $ dropdown_columns ) ; $ column_layout = get_post_meta ( $ item_id , '_themify_mega_menu_columns_layout' , true ) ; ?> <div class="field-tf-mega description description-thin">
			<label for="edit-menu-item-tf-mega- <?php echo $ item_id ; ?> ">
			 <?php _e ( 'Mega Menu' , 'themify' ) ?> <a href="https://themify.me/docs/ultra-documentation#mega-menu" target="_blank"><i class="ti-help"></i></a>
			<br />
				<select name="menu-item-tf-mega[ <?php echo $ item_id ; ?> ]" id="edit-menu-item-tf-mega- <?php echo $ item_id ?> " class="edit-menu-item-tf-mega themify_field_tf-mega widefat"> 
					<option value=""></option>
					<option value="mega"  <?php if ( $ is_mega ) echo 'selected' ; ?> > <?php _e ( 'Mega Posts' , 'themify' ) ; ?> </option>
					<option value="columns"  <?php if ( $ is_column ) echo 'selected' ; ?> > <?php _e ( 'Fullwidth Columns' , 'themify' ) ; ?> </option>
				<option value="drop"  <?php if ( $ is_dropdown_column === true ) echo 'selected' ; ?> > <?php _e ( 'Dropdown Columns' , 'themify' ) ; ?> </option>
				</select>
			</label>
			<div class="tf-mega-columns-layout">
				 <?php echo '<input type="hidden" name="menu-item-tf-mega-columns-layout[' . $ item_id . ']" value="" class="val">' ; foreach ( array ( '' => __ ( 'Auto' , 'themify' ) , '4-8' => __ ( '1/3 - 2/3' , 'themify' ) , '8-4' => __ ( '2/3 - 1/3' , 'themify' ) , '6-3-3' => __ ( '2/4 - 1/4 - 1/4' , 'themify' ) , '3-3-6' => __ ( '1/4 - 1/4 - 2/4' , 'themify' ) , '3-6-3' => __ ( '1/4 - 2/4 - 1/4' , 'themify' ) , '3-9' => __ ( '1/4 - 3/4' , 'themify' ) , '9-3' => __ ( '3/4 - 1/4' , 'themify' ) , ) as $ key => $ label ) { $ selected = $ column_layout === $ key ? 'class="selected"' : '' ; echo '<a href="#" ' . $ selected . ' data-value="' . $ key . '" title="' . $ label . '"></a>' ; } ?> </div>
		</div>

	<p class="tf-dropdown-columns-field description description-thin">
		<label for="edit-menu-item-tf-dropdown-columns- <?php echo $ item_id ; ?> ">	
			 <?php _e ( 'Dropdown Columns' , 'themify' ) ?> <br />
			<select name="menu-item-tf-dropdown_columns[ <?php echo $ item_id ; ?> ]" id="edit-menu-item-tf-dropdown_columns- <?php echo $ item_id ?> " class="edit-menu-item-tf-dropdown_columns">
				<option value=""></option>
				<option value="2"  <?php selected ( 2 , $ dropdown_columns ) ?> >2</option>
				<option value="3"  <?php selected ( 3 , $ dropdown_columns ) ?> >3</option>
				<option value="4"  <?php selected ( 4 , $ dropdown_columns ) ?> >4</option>
			</select>
		</label>
	</p>

	 <?php $ allow_hightlight = apply_filters ( 'themify_menu_highlight_link' , false ) ; if ( $ allow_hightlight ) : $ highlight = get_post_meta ( $ item_id , '_themify_highlight_link' , true ) ; ?> <div class="field-tf-highlight description description-thin"><br>
				<label for="edit-menu-item-tf-highlight- <?php echo $ item_id ; ?> ">
					<input type="checkbox" name="menu-item-tf-highlight[ <?php echo $ item_id ; ?> ]" value="1"  <?php echo ( $ highlight ? 'checked="checked"' : '' ) ; ?> id="edit-menu-item-tf-highlight- <?php echo $ item_id ?> " class="edit-menu-item-tf-highlight themify_field_tf-highlight widefat"> 
				 <?php _e ( 'Highlight this link' , 'themify' ) ?> <br />
				</label>
			</div>
		 <?php endif ; }
Add the option to enable mega menu to taxonomy menu types
 @since 1.0.0
Add the option to enable mega menu to taxonomy menu types @since 1 . 0 . 0