<?php /**
 * Template part for displaying the a row of the footer
 *
 * @package kadence
 */

namespace Kadence;

$row              = get_query_var( 'row' );
$tablet_contain   = ( kadence()->sub_option( 'footer_' . $row . '_contain', 'tablet' ) ? kadence()-&gt;sub_option( 'footer_' . $row . '_contain', 'tablet' ) : 'default' );
$mobile_contain   = ( kadence()-&gt;sub_option( 'footer_' . $row . '_contain', 'mobile' ) ? kadence()-&gt;sub_option( 'footer_' . $row . '_contain', 'mobile' ) : 'default' );
$tablet_layout    = ( kadence()-&gt;sub_option( 'footer_' . $row . '_layout', 'tablet' ) ? kadence()-&gt;sub_option( 'footer_' . $row . '_layout', 'tablet' ) : 'default' );
$link_style       = kadence()-&gt;option( 'footer_' . $row . '_link_style' );
$columns          = absint( kadence()-&gt;option( 'footer_' . $row . '_columns' ) );
$tablet_direction = ( kadence()-&gt;sub_option( 'footer_' . $row . '_direction', 'tablet' ) ? kadence()-&gt;sub_option( 'footer_' . $row . '_direction', 'tablet' ) : 'default' );
$mobile_direction = ( kadence()-&gt;sub_option( 'footer_' . $row . '_direction', 'mobile' ) ? kadence()-&gt;sub_option( 'footer_' . $row . '_direction', 'mobile' ) : 'default' );
$i                = 0;
?&gt;
<div class="site-&lt;?php echo esc_attr( $row ); ?&gt;-footer-wrap site-footer-row-container site-footer-focus-item site-footer-row-layout-&lt;?php echo esc_attr( kadence()-&gt;sub_option( 'footer_' . $row . '_contain', 'desktop' ) ); ?&gt; site-footer-row-tablet-layout-&lt;?php echo esc_attr( $tablet_contain ); ?&gt; site-footer-row-mobile-layout-&lt;?php echo esc_attr( $mobile_contain ); ?&gt;" data-section="kadence_customizer_footer_&lt;?php echo esc_attr( $row ); ?&gt;">
	<div class="site-footer-row-container-inner">
		<?php if ( is_customize_preview() ) { ?>
			<div class="customize-partial-edit-shortcut kadence-custom-partial-edit-shortcut">
				<button aria-label="&lt;?php esc_attr_e( 'Click to edit this element.', 'kadence' ); ?&gt;" title="&lt;?php esc_attr_e( 'Click to edit this element.', 'kadence' ); ?&gt;" class="customize-partial-edit-shortcut-button item-customizer-focus"><svg xmlns="http://www.w3.org/2000/svg" viewbox="0 0 20 20"><path d="M13.89 3.39l2.71 2.72c.46.46.42 1.24.03 1.64l-8.01 8.02-5.56 1.16 1.16-5.58s7.6-7.63 7.99-8.03c.39-.39 1.22-.39 1.68.07zm-2.73 2.79l-5.59 5.61 1.11 1.11 5.54-5.65zm-2.97 8.23l5.58-5.6-1.07-1.08-5.59 5.6z"></path></svg></button>
			</div>
		<?php } ?>
		<div class="site-container">
			<div class="site-&lt;?php echo esc_attr( $row ); ?&gt;-footer-inner-wrap site-footer-row site-footer-row-columns-&lt;?php echo esc_attr( kadence()-&gt;option( 'footer_' . $row . '_columns' ) ); ?&gt; site-footer-row-column-layout-&lt;?php echo esc_attr( kadence()-&gt;sub_option( 'footer_' . $row . '_layout', 'desktop' ) ); ?&gt; site-footer-row-tablet-column-layout-&lt;?php echo esc_attr( $tablet_layout ); ?&gt; site-footer-row-mobile-column-layout-&lt;?php echo esc_attr( kadence()-&gt;sub_option( 'footer_' . $row . '_layout', 'mobile' ) ); ?&gt; ft-ro-dir-&lt;?php echo esc_attr( kadence()-&gt;sub_option( 'footer_' . $row . '_direction', 'desktop' ) ); ?&gt; ft-ro-collapse-&lt;?php echo esc_attr( kadence()-&gt;option( 'footer_' . $row . '_collapse' ) ); ?&gt; ft-ro-t-dir-&lt;?php echo esc_attr( $tablet_direction ); ?&gt; ft-ro-m-dir-&lt;?php echo esc_attr( $mobile_direction ); ?&gt; ft-ro-lstyle-&lt;?php echo esc_attr( $link_style ); ?&gt;">
				<?php while ( $i++ < $columns ) {
					?>
					<div class="site-footer-&lt;?php echo esc_attr( $row ); ?&gt;-section-&lt;?php echo esc_attr( $i ); ?&gt; site-footer-section footer-section-inner-items-&lt;?php echo esc_attr( kadence()-&gt;footer_column_item_count( $row, $i ) ); ?&gt;">
						<?php /**
						 * Kadence Render Footer Column
						 *
						 * Hooked Kadence\footer_column
						 */
						do_action( 'kadence_render_footer_column', $row, $i );
						?>
					</div>
					<?php }
				?>
			</div>
		</div>
	</div>
</div>
