/** @return boolean True if at least one Leyka form is currently on the screen, false otherwise */
function leyka_form_is_screening($widgets_also = true)
{
    $template = get_page_template_slug();
    $content_has_shortcode = false;
    if (get_post()) {
        foreach (leyka_get_shortcodes() as $shortcode_tag) {
            if (has_shortcode(get_post()->post_content, $shortcode_tag)) {
                $content_has_shortcode = true;
                break;
            }
        }
    }
    $form_is_screening = leyka()->form_is_screening || is_singular(Leyka_Campaign_Management::$post_type) || stristr($template, 'home-campaign_one') !== false || stripos($template, 'leyka') !== false || $content_has_shortcode || (!!$widgets_also ? leyka_is_widget_active() : false);
    return $form_is_screening;
}
    public function guide_metabox_screen()
    {
        $row['step_1'] = array('txt' => __('Fill in information about your organisation', 'leyka'), 'action' => leyka_are_settings_complete('beneficiary') ? false : admin_url('admin.php?page=leyka_settings'), 'docs' => 'https://leyka.te-st.ru/docs/nastrojka-lejki/');
        $row['step_2'] = array('txt' => __('Set up at least one payment gateway - bank order, for example', 'leyka'), 'action' => leyka_is_min_payment_settings_complete() ? false : admin_url('admin.php?page=leyka_settings&stage=payment'), 'docs' => 'https://leyka.te-st.ru/docs/nastrojka-lejki-vkladka-2-platezhnye-optsii/');
        $row['step_3'] = array('txt' => __('Create and publsih your first campaign', 'leyka'), 'action' => leyka_is_campaign_published() ? false : admin_url('post-new.php?post_type=' . Leyka_Campaign_Management::$post_type), 'docs' => 'https://leyka.te-st.ru/docs/sozdanie-kampanii/');
        if (current_theme_supports('widgets')) {
            $row['step_4'] = array('txt' => __('Display campaign and donation information on your site using widgets', 'leyka'), 'action' => leyka_is_widget_active() ? false : admin_url('widgets.php'), 'docs' => 'https://leyka.te-st.ru/docs/video-urok-ispolzovanie-novyh-vozmozhnostej-lejki/');
        } elseif (current_theme_supports('menus')) {
            $row['step_4'] = array('txt' => __('Display campaign\'s link on your site using menus', 'leyka'), 'action' => leyka_is_campaign_link_in_menu() ? false : admin_url('nav-menus.php'), 'docs' => 'https://leyka.te-st.ru/docs/video-urok-ispolzovanie-novyh-vozmozhnostej-lejki/');
        }
        ?>
	<table class="leyka-guide-table">		
		<tbody>
		<?php 
        $count = 0;
        foreach ($row as $key => $obj) {
            $count++;
            ?>

			<tr class="<?php 
            echo esc_attr($key);
            ?>
">
				<td class="count"><?php 
            echo $count;
            ?>
.</td>
				<td class="step"><?php 
            echo $obj['txt'];
            ?>
</td>
				<?php 
            if ($obj['action']) {
                ?>
				<td class="action"><a href="<?php 
                echo esc_url($obj['action']);
                ?>
"><?php 
                _e('Set up', 'leyka');
                ?>
</a></td>
				<td class="docs"><a href="<?php 
                echo esc_url($obj['docs']);
                ?>
" title="<?php 
                esc_attr_e('Additional information on the plugin website', 'leyka');
                ?>
" target="_blank"><span class="dashicons dashicons-editor-help"></span></a></td>
				<?php 
            } else {
                ?>
				<td class="action complete"><span><?php 
                _e('Complete', 'leyka');
                ?>
</span></td>
				<?php 
            }
            ?>
			</tr>
		<?php 
        }
        ?>
		</tbody>
	</table>
    <?php 
    }