Use new code style

This commit is contained in:
David Stone
2025-02-07 19:02:33 -07:00
parent 0181024ae1
commit 8433379d90
672 changed files with 37107 additions and 45249 deletions

View File

@ -8,50 +8,50 @@
<div id="wp-ultimo-footer" class="wu-pt-6 wu-pb-1 wu--mx-5 wu-mb-0 wu-text-gray-500 wu-text-center wu-bg-gray-100 wu-border-0 wu-border-gray-300 wu-border-t wu-border-solid">
<ul id="wu-footer-nav" class="wu-text-xs wu-pb-0">
<li class="wu-inline-block wu-mx-1 wu-font-medium">
<?php printf(__('Version %s', 'wp-ultimo'), wu_get_version()); ?>
</li>
<ul id="wu-footer-nav" class="wu-text-xs wu-pb-0">
<li class="wu-inline-block wu-mx-1 wu-font-medium">
<?php printf(__('Version %s', 'wp-ultimo'), wu_get_version()); ?>
</li>
<?php if (WP_Ultimo()->is_loaded()) : ?>
<?php if (WP_Ultimo()->is_loaded()) : ?>
<li class="wu-inline-block wu-mx-1">
<a href="<?php echo wu_network_admin_url('wp-ultimo-system-info'); ?>" class="wu-text-gray-500 hover:wu-text-gray-600">
<?php _e('System Info', 'wp-ultimo'); ?>
</a>
</li>
<li class="wu-inline-block wu-mx-1">
<a href="<?php echo wu_network_admin_url('wp-ultimo-shortcodes'); ?>" class="wu-text-gray-500 hover:wu-text-gray-600">
<?php _e('Available Shortcodes', 'wp-ultimo'); ?>
</a>
</li>
<li class="wu-inline-block wu-mx-1">
<a href="<?php echo wu_network_admin_url('wp-ultimo-system-info'); ?>" class="wu-text-gray-500 hover:wu-text-gray-600">
<?php _e('System Info', 'wp-ultimo'); ?>
</a>
</li>
<li class="wu-inline-block wu-mx-1">
<a href="<?php echo wu_network_admin_url('wp-ultimo-shortcodes'); ?>" class="wu-text-gray-500 hover:wu-text-gray-600">
<?php _e('Available Shortcodes', 'wp-ultimo'); ?>
</a>
</li>
<?php endif; ?>
<?php endif; ?>
<?php if (WP_Ultimo()->is_loaded()) : ?>
<?php if (WP_Ultimo()->is_loaded()) : ?>
<li class="wu-inline-block wu-mx-1">
<a href="<?php echo wu_network_admin_url('wp-ultimo-settings'); ?>" class="wu-text-gray-500 hover:wu-text-gray-600">
<?php _e('Settings', 'wp-ultimo'); ?>
</a>
</li>
<li class="wu-inline-block wu-mx-1">
<a href="<?php echo wu_network_admin_url('wp-ultimo-settings'); ?>" class="wu-text-gray-500 hover:wu-text-gray-600">
<?php _e('Settings', 'wp-ultimo'); ?>
</a>
</li>
<?php endif; ?>
<?php endif; ?>
<?php if (WP_Ultimo()->is_loaded()) : ?>
<?php if (WP_Ultimo()->is_loaded()) : ?>
<li class="wu-inline-block wu-mx-1">
<a href="<?php echo wu_network_admin_url('wp-ultimo-jobs'); ?>" class="wu-text-gray-500 hover:wu-text-gray-600">
<?php _e('Job Queue', 'wp-ultimo'); ?>
</a>
</li>
<li class="wu-inline-block wu-mx-1">
<a href="<?php echo wu_network_admin_url('wp-ultimo-jobs'); ?>" class="wu-text-gray-500 hover:wu-text-gray-600">
<?php _e('Job Queue', 'wp-ultimo'); ?>
</a>
</li>
<?php endif; ?>
<?php endif; ?>
<?php do_action('wu_footer_left'); ?>
<li class="wu-inline-block wu-mx-2">
• <a href="https://wpmultisitewaas.org/support" class="wu-text-gray-500 hover:wu-text-gray-600">Support</a>
</li>
</ul>
<?php do_action('wu_footer_left'); ?>
<li class="wu-inline-block wu-mx-2">
• <a href="https://wpmultisitewaas.org/support" class="wu-text-gray-500 hover:wu-text-gray-600">Support</a>
</li>
</ul>
</div>

View File

@ -7,67 +7,67 @@
?>
<div id="wp-ultimo-header" class="wu-px-4 wu--ml-5 wu-bg-white wu-border-0 wu-border-gray-300 wu-border-b wu-border-solid wu-pb-3 sm:wu-py-3 sm:wu-pt-3 wu-hidden sm:wu-flex">
<div class="wu-w-7/12 wu-self-center">
<div class="wu-w-7/12 wu-self-center">
<span class="dashicons-before dashicons-wu-wp-ultimo"></span>
<span class="dashicons-before dashicons-wu-wp-ultimo"></span>
<div class="wu-text-gray-600 wu-uppercase wu-text-xs wu-font-bold wu-align-middle wu-ml-2 wu-hidden md:wu-inline-block">
<div class="wu-text-gray-600 wu-uppercase wu-text-xs wu-font-bold wu-align-middle wu-ml-2 wu-hidden md:wu-inline-block">
<?php if (WP_Ultimo()->is_loaded()) : ?>
<?php if (WP_Ultimo()->is_loaded()) : ?>
<div class="wu-hidden md:wu-inline-block">
<div class="wu-hidden md:wu-inline-block">
<?php
<?php
/**
* Allow plugin developers to add more elements on left header container.
*
* @since 2.0.0
*
* @param \WP_Ultimo\Admin_Pages\Base_Admin_Page $page WP Multisite WaaS admin page instance.
*/
do_action('wu_header_left', $page);
/**
* Allow plugin developers to add more elements on left header container.
*
* @since 2.0.0
*
* @param \WP_Ultimo\Admin_Pages\Base_Admin_Page $page WP Multisite WaaS admin page instance.
*/
do_action('wu_header_left', $page);
?>
?>
</div>
</div>
<?php endif; ?>
<?php endif; ?>
</div>
</div>
</div>
</div>
<div class="wu-w-5/12 wu-text-right wu-self-center">
<div class="wu-w-5/12 wu-text-right wu-self-center">
<?php if (WP_Ultimo()->is_loaded()) : ?>
<?php if (WP_Ultimo()->is_loaded()) : ?>
<?php
<?php
/**
* Allow plugin developers to add more elements on right header container.
*
* @since 2.0.0
*
* @param \WP_Ultimo\Admin_Pages\Base_Admin_Page $page WP Multisite WaaS admin page instance.
*/
do_action('wu_header_right', $page);
/**
* Allow plugin developers to add more elements on right header container.
*
* @since 2.0.0
*
* @param \WP_Ultimo\Admin_Pages\Base_Admin_Page $page WP Multisite WaaS admin page instance.
*/
do_action('wu_header_right', $page);
?>
?>
<small class="wu-ticker-container wu-hidden md:wu-inline-block">
<strong>
<span class="wu-inline-block wu-bg-gray-200 wu-rounded-full wu-py-1 wu-pl-2 wu-pr-3 wu-uppercase">
<span title="<?php esc_attr_e('Server Clock', 'wp-ultimo'); ?>" class="dashicons dashicons-wu-clock wu-text-sm wu-w-auto wu-h-auto wu-align-text-top wu-mr-1 wu-relative"></span>
<span id="wu-ticker" class="wu-font-mono wu-font-normal">
<?php echo gmdate('Y-m-d H:i:s', wu_get_current_time('timestamp')); ?>
</span>
</span>
</strong>
</small>
<small class="wu-ticker-container wu-hidden md:wu-inline-block">
<strong>
<span class="wu-inline-block wu-bg-gray-200 wu-rounded-full wu-py-1 wu-pl-2 wu-pr-3 wu-uppercase">
<span title="<?php esc_attr_e('Server Clock', 'wp-ultimo'); ?>" class="dashicons dashicons-wu-clock wu-text-sm wu-w-auto wu-h-auto wu-align-text-top wu-mr-1 wu-relative"></span>
<span id="wu-ticker" class="wu-font-mono wu-font-normal">
<?php echo gmdate('Y-m-d H:i:s', wu_get_current_time('timestamp')); ?>
</span>
</span>
</strong>
</small>
<?php endif; ?>
<?php endif; ?>
</div>
</div>
</div>

View File

@ -6,56 +6,56 @@
*/
?>
<small>
<strong>
<a id="wu-container-toggle" role="tooltip" aria-label='<?php _e('Toggle container', 'wp-ultimo'); ?>' href="#" class="wu-tooltip wu-inline-block wu-py-1 wu-pl-2 md:wu-pr-3 wu-uppercase wu-text-gray-600 wu-no-underline">
<strong>
<a id="wu-container-toggle" role="tooltip" aria-label='<?php _e('Toggle container', 'wp-ultimo'); ?>' href="#" class="wu-tooltip wu-inline-block wu-py-1 wu-pl-2 md:wu-pr-3 wu-uppercase wu-text-gray-600 wu-no-underline">
<span title="<?php esc_attr_e('Boxed', 'wp-ultimo'); ?>" class="wu-use-container dashicons dashicons-wu-arrow-with-circle-left wu-text-sm wu-w-auto wu-h-auto wu-align-text-bottom wu-relative"></span>
<span class="wu-font-bold wu-use-container">
<?php esc_attr_e('Boxed', 'wp-ultimo'); ?>
</span>
<span title="<?php esc_attr_e('Boxed', 'wp-ultimo'); ?>" class="wu-use-container dashicons dashicons-wu-arrow-with-circle-left wu-text-sm wu-w-auto wu-h-auto wu-align-text-bottom wu-relative"></span>
<span class="wu-font-bold wu-use-container">
<?php esc_attr_e('Boxed', 'wp-ultimo'); ?>
</span>
<span title="<?php esc_attr_e('Boxed', 'wp-ultimo'); ?>" class="wu-no-container dashicons dashicons-wu-arrow-with-circle-right wu-text-sm wu-w-auto wu-h-auto wu-align-text-bottom wu-relative"></span>
<span class="wu-font-bold wu-no-container">
<?php esc_attr_e('Wide', 'wp-ultimo'); ?>
</span>
<span title="<?php esc_attr_e('Boxed', 'wp-ultimo'); ?>" class="wu-no-container dashicons dashicons-wu-arrow-with-circle-right wu-text-sm wu-w-auto wu-h-auto wu-align-text-bottom wu-relative"></span>
<span class="wu-font-bold wu-no-container">
<?php esc_attr_e('Wide', 'wp-ultimo'); ?>
</span>
</a>
</strong>
</a>
</strong>
</small>
<style>
body.has-wu-container .wu-no-container {
display: none;
display: none;
}
body:not(.has-wu-container) .wu-use-container {
display: none;
display: none;
}
</style>
<script>
(function($) {
$(document).ready(function() {
$(document).ready(function() {
$('#wu-container-toggle').on('click', function(e) {
$('#wu-container-toggle').on('click', function(e) {
e.preventDefault();
e.preventDefault();
wu_block_ui('#wpcontent');
wu_block_ui('#wpcontent');
$.ajax(ajaxurl + '?action=wu_toggle_container&nonce=<?php echo wp_create_nonce('wu_toggle_container'); ?>').done(function() {
$.ajax(ajaxurl + '?action=wu_toggle_container&nonce=<?php echo wp_create_nonce('wu_toggle_container'); ?>').done(function() {
$('.wrap').toggleClass('admin-lg:wu-container admin-lg:wu-mx-auto');
$('.wrap').toggleClass('admin-lg:wu-container admin-lg:wu-mx-auto');
$('body').toggleClass('has-wu-container');
$('body').toggleClass('has-wu-container');
wu_block_ui('#wpcontent').unblock();
wu_block_ui('#wpcontent').unblock();
});;
});;
});
});
});
});
}(jQuery));
</script>

View File

@ -6,12 +6,12 @@
*/
?>
<small>
<strong>
<a id="wu-jumper-button-trigger" role="tooltip" aria-label='<?php echo esc_attr($jumper->add_jumper_footer_message('')); ?>' href="#" class="wu-tooltip wu-inline-block wu-py-1 wu-pl-2 md:wu-pr-3 wu-uppercase wu-text-gray-600 wu-no-underline">
<span title="<?php esc_attr_e('Jumper', 'wp-ultimo'); ?>" class="dashicons dashicons-wu-flash wu-text-sm wu-w-auto wu-h-auto wu-align-text-top wu-relative wu--mr-1"></span>
<span class="wu-font-bold">
<?php esc_attr_e('Jumper', 'wp-ultimo'); ?>
</span>
</a>
</strong>
<strong>
<a id="wu-jumper-button-trigger" role="tooltip" aria-label='<?php echo esc_attr($jumper->add_jumper_footer_message('')); ?>' href="#" class="wu-tooltip wu-inline-block wu-py-1 wu-pl-2 md:wu-pr-3 wu-uppercase wu-text-gray-600 wu-no-underline">
<span title="<?php esc_attr_e('Jumper', 'wp-ultimo'); ?>" class="dashicons dashicons-wu-flash wu-text-sm wu-w-auto wu-h-auto wu-align-text-top wu-relative wu--mr-1"></span>
<span class="wu-font-bold">
<?php esc_attr_e('Jumper', 'wp-ultimo'); ?>
</span>
</a>
</strong>
</small>

View File

@ -10,95 +10,95 @@
?>
<div id="wu-jumper" style="display: none;" class="wu-styling">
<div class="wu-jumper-icon-container wu-relative wu-w-full wu-bg-gray-100 wu-rounded">
<div class="wu-jumper-icon-container wu-relative wu-w-full wu-bg-gray-100 wu-rounded">
<select id="wu-jumper-select" data-placeholder="<?php esc_attr_e('Search Anything...', 'wp-ultimo'); ?>">
<select id="wu-jumper-select" data-placeholder="<?php esc_attr_e('Search Anything...', 'wp-ultimo'); ?>">
<option></option>
<option></option>
<?php if (!count($menu_groups)) : ?>
<?php if ( ! count($menu_groups)) : ?>
<option></option>
<option></option>
<optgroup label="<?php esc_attr_e('Error', 'wp-ultimo'); ?>">
<optgroup label="<?php esc_attr_e('Error', 'wp-ultimo'); ?>">
<option value="<?php echo network_admin_url('?wu-rebuild-jumper=1'); ?>">
<option value="<?php echo network_admin_url('?wu-rebuild-jumper=1'); ?>">
<?php _e('Click to rebuild menu list', 'wp-ultimo'); ?>
<?php _e('Click to rebuild menu list', 'wp-ultimo'); ?>
</option>
</option>
</optgroup>
</optgroup>
<?php endif; ?>
<?php endif; ?>
<?php foreach ($menu_groups as $optgroup => $menus) : ?>
<?php foreach ($menu_groups as $optgroup => $menus) : ?>
<optgroup label="<?php esc_attr_e('Menu', 'wp-ultimo'); ?> - <?php echo esc_attr($optgroup); ?>" value="<?php esc_attr_e('Menu', 'wp-ultimo'); ?> - <?php echo esc_attr($optgroup); ?>">
<optgroup label="<?php esc_attr_e('Menu', 'wp-ultimo'); ?> - <?php echo esc_attr($optgroup); ?>" value="<?php esc_attr_e('Menu', 'wp-ultimo'); ?> - <?php echo esc_attr($optgroup); ?>">
<?php foreach ($menus as $url => $menu) : ?>
<?php foreach ($menus as $url => $menu) : ?>
<option value="<?php echo esc_attr($url); ?>">
<option value="<?php echo esc_attr($url); ?>">
<?php echo $menu; ?>
<?php echo $menu; ?>
</option>
</option>
<?php endforeach; ?>
<?php endforeach; ?>
</optgroup>
</optgroup>
<?php endforeach; ?>
<?php endforeach; ?>
<optgroup label="<?php esc_attr_e('Settings', 'wp-ultimo'); ?>" value="setting"></optgroup>
<optgroup label="<?php esc_attr_e('Settings', 'wp-ultimo'); ?>" value="setting"></optgroup>
<optgroup label="<?php esc_attr_e('Users', 'wp-ultimo'); ?>" value="user"></optgroup>
<optgroup label="<?php esc_attr_e('Users', 'wp-ultimo'); ?>" value="user"></optgroup>
<optgroup label="<?php esc_attr_e('Customers', 'wp-ultimo'); ?>" value="customer"></optgroup>
<optgroup label="<?php esc_attr_e('Customers', 'wp-ultimo'); ?>" value="customer"></optgroup>
<optgroup label="<?php esc_attr_e('Products', 'wp-ultimo'); ?>" value="product"></optgroup>
<optgroup label="<?php esc_attr_e('Products', 'wp-ultimo'); ?>" value="product"></optgroup>
<optgroup label="<?php esc_attr_e('Domains', 'wp-ultimo'); ?>" value="domain"></optgroup>
<optgroup label="<?php esc_attr_e('Domains', 'wp-ultimo'); ?>" value="domain"></optgroup>
<optgroup label="<?php esc_attr_e('Sites', 'wp-ultimo'); ?>" value="site"></optgroup>
<optgroup label="<?php esc_attr_e('Sites', 'wp-ultimo'); ?>" value="site"></optgroup>
<optgroup label="<?php esc_attr_e('Memberships', 'wp-ultimo'); ?>" value="membership"></optgroup>
<optgroup label="<?php esc_attr_e('Memberships', 'wp-ultimo'); ?>" value="membership"></optgroup>
<optgroup label="<?php esc_attr_e('Payments', 'wp-ultimo'); ?>" value="payment"></optgroup>
<optgroup label="<?php esc_attr_e('Payments', 'wp-ultimo'); ?>" value="payment"></optgroup>
<optgroup label="<?php esc_attr_e('Discount Codes', 'wp-ultimo'); ?>" value="discount-code"></optgroup>
<optgroup label="<?php esc_attr_e('Discount Codes', 'wp-ultimo'); ?>" value="discount-code"></optgroup>
<optgroup label="<?php esc_attr_e('Webhooks', 'wp-ultimo'); ?>" value="webhook"></optgroup>
<optgroup label="<?php esc_attr_e('Webhooks', 'wp-ultimo'); ?>" value="webhook"></optgroup>
<optgroup label="<?php esc_attr_e('Broadcasts', 'wp-ultimo'); ?>" value="broadcast"></optgroup>
<optgroup label="<?php esc_attr_e('Broadcasts', 'wp-ultimo'); ?>" value="broadcast"></optgroup>
<optgroup label="<?php esc_attr_e('Checkout Forms', 'wp-ultimo'); ?>" value="checkout-form"></optgroup>
<optgroup label="<?php esc_attr_e('Checkout Forms', 'wp-ultimo'); ?>" value="checkout-form"></optgroup>
<?php
<?php
/**
* Allow plugin developers to add new opt-groups.
*
* @since 2.0.0
*/
do_action('wu_jumper_options');
/**
* Allow plugin developers to add new opt-groups.
*
* @since 2.0.0
*/
do_action('wu_jumper_options');
?>
?>
</select>
</select>
</div>
</div>
<div class="wu-jumper-redirecting wu-bg-gray-200">
<div class="wu-jumper-redirecting wu-bg-gray-200">
<?php _e('Redirecting you to the target page...', 'wp-ultimo'); ?>
<?php _e('Redirecting you to the target page...', 'wp-ultimo'); ?>
</div>
</div>
<div class="wu-jumper-loading wu-bg-gray-200">
<div class="wu-jumper-loading wu-bg-gray-200">
<?php _e('Searching Results...', 'wp-ultimo'); ?>
<?php _e('Searching Results...', 'wp-ultimo'); ?>
</div>
</div>
</div>

View File

@ -8,23 +8,23 @@
<!-- WP User Template -->
<script type="text/html" id="wu-template-user">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div>
<div>
{{ typeof avatar !== 'undefined' ? avatar : '' }}
{{ typeof avatar !== 'undefined' ? avatar : '' }}
</div>
</div>
<div>
<div>
<span class="wu-block">{{ display_name }} (#{{ ID }})</span>
<span class="wu-block">{{ display_name }} (#{{ ID }})</span>
<small>{{ typeof user_email !== 'undefined' ? user_email : '<?php _e('Undefined'); ?>' }}</small>
<small>{{ typeof user_email !== 'undefined' ? user_email : '<?php _e('Undefined'); ?>' }}</small>
</div>
</div>
</div>
</div>
</script>
<!-- /WP User Template -->
@ -32,23 +32,23 @@
<!-- Customer Template -->
<script type="text/html" id="wu-template-customer">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div>
<div>
{{ typeof avatar !== 'undefined' ? avatar : '' }}
{{ typeof avatar !== 'undefined' ? avatar : '' }}
</div>
</div>
<div>
<div>
<span class="wu-block">{{ display_name }} (#{{ id }})</span>
<span class="wu-block">{{ display_name }} (#{{ id }})</span>
<small>{{ typeof user_email !== 'undefined' ? user_email : '<?php _e('Undefined'); ?>' }}</small>
<small>{{ typeof user_email !== 'undefined' ? user_email : '<?php _e('Undefined'); ?>' }}</small>
</div>
</div>
</div>
</div>
</script>
<!-- /Customer Template -->
@ -56,25 +56,25 @@
<!-- Membership Template -->
<script type="text/html" id="wu-template-membership">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div>
<div>
{{ typeof customer.avatar !== 'undefined' ? customer.avatar : '' }}
{{ typeof customer.avatar !== 'undefined' ? customer.avatar : '' }}
</div>
</div>
<div>
<div>
<span class="wu-block">{{ reference_code }} (#{{ id }})</span>
<span class="wu-block">{{ reference_code }} (#{{ id }})</span>
<small>Customer: {{ customer.display_name }}</small><br>
<small>Customer: {{ customer.display_name }}</small><br>
<small>{{ formatted_price }}</small>
<small>{{ formatted_price }}</small>
</div>
</div>
</div>
</div>
</script>
<!-- /Membership Template -->
@ -82,23 +82,23 @@
<!-- Site Template -->
<script type="text/html" id="wu-template-site">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div>
<div>
{{ typeof image !== 'undefined' ? image : '' }}
{{ typeof image !== 'undefined' ? image : '' }}
</div>
</div>
<div>
<div>
<span class="wu-block">{{ title }}</span>
<span class="wu-block">{{ title }}</span>
<small>{{ siteurl }}</small><br>
<small>{{ siteurl }}</small><br>
</div>
</div>
</div>
</div>
</script>
<!-- /Site Template -->
@ -106,19 +106,19 @@
<!-- Setting Template -->
<script type="text/html" id="wu-template-setting">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div>
<div>
<span class="wu-block">{{ title }}</span>
<span class="wu-block">{{ title }}</span>
<small>{{ section_title }}</small><br>
<small>{{ section_title }}</small><br>
<small>{{ desc }}</small>
<small>{{ desc }}</small>
</div>
</div>
</div>
</div>
</script>
<!-- /Setting Template -->
@ -126,23 +126,23 @@
<!-- Product Template -->
<script type="text/html" id="wu-template-product">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div>
<div>
{{ typeof image !== 'undefined' ? image : '' }}
{{ typeof image !== 'undefined' ? image : '' }}
</div>
</div>
<div>
<div>
<span class="wu-block">{{ name }} ({{ type }})</span>
<span class="wu-block">{{ name }} ({{ type }})</span>
<small>{{ formatted_price }}</small>
<small>{{ formatted_price }}</small>
</div>
</div>
</div>
</div>
</script>
<!-- /Product Template -->
@ -150,23 +150,23 @@
<!-- Plan Template -->
<script type="text/html" id="wu-template-plan">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div>
<div>
{{ typeof image !== 'undefined' ? image : '' }}
{{ typeof image !== 'undefined' ? image : '' }}
</div>
</div>
<div>
<div>
<span class="wu-block">{{ name }} ({{ type }})</span>
<span class="wu-block">{{ name }} ({{ type }})</span>
<small>{{ formatted_price }}</small>
<small>{{ formatted_price }}</small>
</div>
</div>
</div>
</div>
</script>
<!-- /Plan Template -->
@ -174,17 +174,17 @@
<!-- Jumper Link Template -->
<script type="text/html" id="wu-template-jumper-link">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div>
<div>
<span class="wu-block">{{ text }}</span>
<span class="wu-block">{{ text }}</span>
<small><?php _e('Network Admin', 'wp-ultimo'); ?> &rarr; {{ group }}</small>
<small><?php _e('Network Admin', 'wp-ultimo'); ?> &rarr; {{ group }}</small>
</div>
</div>
</div>
</div>
</script>
<!-- /Jumper Link Template -->
@ -192,17 +192,17 @@
<!-- Discount Code Template -->
<script type="text/html" id="wu-template-discount_code">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div>
<div>
<span class="wu-block">{{ code }} (#{{ id }})</span>
<span class="wu-block">{{ code }} (#{{ id }})</span>
<small>{{ discount_description }}</small>
<small>{{ discount_description }}</small>
</div>
</div>
</div>
</div>
</script>
<!-- /Discount Code Template -->
@ -210,17 +210,17 @@
<!-- Domain Template -->
<script type="text/html" id="wu-template-domain">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div>
<div>
<span class="wu-block">{{ domain }}</span>
<span class="wu-block">{{ domain }}</span>
<small><?php _e('Mapped Domain', 'wp-ultimo'); ?></small>
<small><?php _e('Mapped Domain', 'wp-ultimo'); ?></small>
</div>
</div>
</div>
</div>
</script>
<!-- /Domain Template -->
@ -228,17 +228,17 @@
<!-- Webhook Template -->
<script type="text/html" id="wu-template-webhook">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div>
<div>
<span class="wu-block">{{ name }}</span>
<span class="wu-block">{{ name }}</span>
<small>{{ webhook_url }}</small>
<small>{{ webhook_url }}</small>
</div>
</div>
</div>
</div>
</script>
<!-- /Webhook Template -->
@ -246,15 +246,15 @@
<!-- Broadcast Template -->
<script type="text/html" id="wu-template-broadcast">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div>
<div>
<span class="wu-block">{{ title }}</span>
<span class="wu-block">{{ title }}</span>
</div>
</div>
</div>
</div>
</script>
<!-- /Broadcast Template -->
@ -262,17 +262,17 @@
<!-- Checkout Form Template -->
<script type="text/html" id="wu-template-checkout_form">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div>
<div>
<span class="wu-block">{{ name }}</span>
<span class="wu-block">{{ name }}</span>
<small>{{ slug }}</small>
<small>{{ slug }}</small>
</div>
</div>
</div>
</div>
</script>
<!-- /Checkout Form Template -->
@ -280,17 +280,17 @@
<!-- Page Template -->
<script type="text/html" id="wu-template-page">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div>
<div>
<span class="wu-block">{{ post_title }} (#{{ ID }})</span>
<span class="wu-block">{{ post_title }} (#{{ ID }})</span>
<small>/{{ post_name }} - {{ post_status.charAt(0).toUpperCase() + post_status.slice(1) }}</small>
<small>/{{ post_name }} - {{ post_status.charAt(0).toUpperCase() + post_status.slice(1) }}</small>
</div>
</div>
</div>
</div>
</script>
<!-- /Page Template -->
@ -298,23 +298,23 @@
<!-- Default Template -->
<script type="text/html" id="wu-template-default">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div v-if="avatar">
<div v-if="avatar">
{{ avatar }}
{{ avatar }}
</div>
</div>
<div>
<div>
<span class="wu-block">{{ label ?? id }} (#{{ id }})</span>
<span class="wu-block">{{ label ?? id }} (#{{ id }})</span>
<small>{{ description ?? id }}</small>
<small>{{ description ?? id }}</small>
</div>
</div>
</div>
</div>
</script>
<!-- /Default Template -->
@ -322,23 +322,22 @@
<!-- Nothing Found Template -->
<script type="text/html" id="wu-template-none">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<div class="wu-p-4 wu-block wu-flex wu-items-center">
<?php _e('Nothing Found...', 'wp-ultimo'); ?>
<?php _e('Nothing Found...', 'wp-ultimo'); ?>
</div>
</div>
</script>
<!-- /Nothing Found Template -->
<?php
/**
* Allow plugin developers to add more selectize templates.
*
* @since 2.0.0
*
*/
do_action('wu_selectize_templates');
/**
* Allow plugin developers to add more selectize templates.
*
* @since 2.0.0
*/
do_action('wu_selectize_templates');
?>

View File

@ -15,8 +15,7 @@
* @version 1.0.0
*/
if (!defined('ABSPATH')) {
if ( ! defined('ABSPATH')) {
exit; // Exit if accessed directly
} // end if;
@ -29,190 +28,198 @@ do_action('wu_template_previewer_before');
?>
<!DOCTYPE html>
<html <?php language_attributes(); ?>>
<head>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta charset="<?php bloginfo('charset'); ?>">
<?php wu_ignore_errors(function() {
wp_head();
}); ?>
<?php
wu_ignore_errors(
function () {
wp_head();
}
);
?>
</head>
</head>
<body>
<body>
<div id="switcher">
<div id="switcher">
<div class="center">
<div class="center">
<div class="logo">
<div class="logo">
<a title="<?php echo get_network_option(null, 'site_name'); ?>" href="<?php echo network_home_url(); ?>" target="_blank">
<a title="<?php echo get_network_option(null, 'site_name'); ?>" href="<?php echo network_home_url(); ?>" target="_blank">
<?php if ($use_custom_logo && $custom_logo) : ?>
<?php if ($use_custom_logo && $custom_logo) : ?>
<?php echo wp_get_attachment_image($custom_logo, 'full'); ?>
<?php echo wp_get_attachment_image($custom_logo, 'full'); ?>
<?php else : ?>
<?php else : ?>
<img src="<?php echo $logo_url; ?>" alt="<?php echo get_network_option(null, 'site_name'); ?>">
<img src="<?php echo $logo_url; ?>" alt="<?php echo get_network_option(null, 'site_name'); ?>">
<?php endif; ?>
<?php endif; ?>
</a>
</a>
</div>
</div>
<ul id="theme_list_selector">
<ul id="theme_list_selector">
<li id="theme_list">
<li id="theme_list">
<?php if ($selected_template) : ?>
<?php if ($selected_template) : ?>
<a id="template_selector" href="#">
<a id="template_selector" href="#">
<?php echo $selected_template->get_title(); ?>
<?php echo $selected_template->get_title(); ?>
<span style="float: right; margin-top: -3px" class="dashicons dashicons-arrow-down-alt2"></span>
<span style="float: right; margin-top: -3px" class="dashicons dashicons-arrow-down-alt2"></span>
</a>
</a>
<?php else : ?>
<?php else : ?>
<a id="template_selector" href="#">
<a id="template_selector" href="#">
<?php _e('Select template...', 'wp-ultimo'); ?>
<?php _e('Select template...', 'wp-ultimo'); ?>
<span style="float: right; margin-top: -3px" class="dashicons dashicons-arrow-down-alt2"></span>
<span style="float: right; margin-top: -3px" class="dashicons dashicons-arrow-down-alt2"></span>
</a>
</a>
<?php endif; ?>
<?php endif; ?>
<ul id="test1a">
<ul id="test1a">
<?php foreach ($templates as $template) : ?>
<?php foreach ($templates as $template) : ?>
<li>
<li>
<a
href="<?php echo $tp->get_preview_url($template->get_id()); ?>"
data-frame="<?php echo $template->get_active_site_url(); ?>"
data-title="<?php echo $template->get_title(); ?>"
data-id="<?php echo $template->get_id(); ?>"
>
<a
href="<?php echo $tp->get_preview_url($template->get_id()); ?>"
data-frame="<?php echo $template->get_active_site_url(); ?>"
data-title="<?php echo $template->get_title(); ?>"
data-id="<?php echo $template->get_id(); ?>"
>
<?php echo $template->get_title(); ?>
<?php echo $template->get_title(); ?>
</a>
</a>
<img alt="" class="preview" src="<?php echo $template->get_featured_image(); ?>">
<img alt="" class="preview" src="<?php echo $template->get_featured_image(); ?>">
</li>
</li>
<?php endforeach; ?>
<?php endforeach; ?>
</ul>
</ul>
</li>
</li>
</ul>
</ul>
<?php if ($display_responsive_controls) : ?>
<?php if ($display_responsive_controls) : ?>
<div class="responsive">
<div class="responsive">
<a href="#" class="desktop active dashicons-before dashicons-desktop" title="<?php esc_attr_e('View Desktop Version', 'wp-ultimo'); ?>"></a>
<a href="#" class="desktop active dashicons-before dashicons-desktop" title="<?php esc_attr_e('View Desktop Version', 'wp-ultimo'); ?>"></a>
<a href="#" class="tabletlandscape dashicons-before dashicons-tablet" title="<?php esc_attr_e('View Tablet Landscape (1024x768)', 'wp-ultimo'); ?>"></a>
<a href="#" class="tabletlandscape dashicons-before dashicons-tablet" title="<?php esc_attr_e('View Tablet Landscape (1024x768)', 'wp-ultimo'); ?>"></a>
<a href="#" class="tabletportrait dashicons-before dashicons-tablet" title="<?php esc_attr_e('View Tablet Portrait (768x1024)', 'wp-ultimo'); ?>"></a>
<a href="#" class="tabletportrait dashicons-before dashicons-tablet" title="<?php esc_attr_e('View Tablet Portrait (768x1024)', 'wp-ultimo'); ?>"></a>
<a href="#" class="mobilelandscape dashicons-before dashicons-smartphone" title="<?php esc_attr_e('View Mobile Landscape (480x320)', 'wp-ultimo'); ?>"></a>
<a href="#" class="mobilelandscape dashicons-before dashicons-smartphone" title="<?php esc_attr_e('View Mobile Landscape (480x320)', 'wp-ultimo'); ?>"></a>
<a href="#" class="mobileportrait dashicons-before dashicons-smartphone" title="<?php esc_attr_e('View Mobile Portrait (320x480)', 'wp-ultimo'); ?>"></a>
<a href="#" class="mobileportrait dashicons-before dashicons-smartphone" title="<?php esc_attr_e('View Mobile Portrait (320x480)', 'wp-ultimo'); ?>"></a>
</div>
</div>
<?php endif; ?>
<?php endif; ?>
</div>
</div>
<?php if (!isset($_GET['switching'])) : ?>
<?php if ( ! isset($_GET['switching'])) : ?>
<ul class="links">
<ul class="links">
<?php if (wu_request('open')) : ?>
<?php if (wu_request('open')) : ?>
<li class="select-template">
<li class="select-template">
<a id="action-select" href="#"><?php echo $button_text; ?> &rarr;</a>
<a id="action-select" href="#"><?php echo $button_text; ?> &rarr;</a>
</li>
</li>
<?php else : ?>
<?php else : ?>
<li class="select-template">
<li class="select-template">
<a id="action-select-link" href="<?php echo wu_get_registration_url('?template_selection='.$selected_template->get_id()); ?>"><?php echo $button_text; ?> &rarr;</a>
<a id="action-select-link" href="<?php echo wu_get_registration_url('?template_selection=' . $selected_template->get_id()); ?>"><?php echo $button_text; ?> &rarr;</a>
</li>
</li>
<?php endif; ?>
<?php endif; ?>
</ul>
</ul>
<?php endif; ?>
<?php endif; ?>
<input type="hidden" id="template-selector" value="<?php echo esc_attr($_GET['template-preview']); ?>" />
<input type="hidden" id="template-selector" value="<?php echo esc_attr($_GET['template-preview']); ?>" />
</div>
</div>
<?php if (!isset($_GET['switching'])) : ?>
<?php if ( ! isset($_GET['switching'])) : ?>
<div class="mobile-selector">
<div class="mobile-selector">
<?php if (wu_request('open')) : ?>
<?php if (wu_request('open')) : ?>
<a id="action-select2" href="#"><?php echo $button_text; ?> &rarr;</a>
<a id="action-select2" href="#"><?php echo $button_text; ?> &rarr;</a>
<?php else : ?>
<?php else : ?>
<a id="action-select-link" href="<?php echo wu_get_registration_url('?template_id='.$selected_template->get_id()); ?>"><?php echo $button_text; ?> &rarr;</a>
<a id="action-select-link" href="<?php echo wu_get_registration_url('?template_id=' . $selected_template->get_id()); ?>"><?php echo $button_text; ?> &rarr;</a>
<?php endif; ?>
<?php endif; ?>
</div>
</div>
<?php endif; ?>
<?php endif; ?>
<?php if (!wu_request('customizer')) : ?>
<?php if ( ! wu_request('customizer')) : ?>
<iframe id="iframe" src="<?php echo set_url_scheme(add_query_arg('wu-preview', '1', get_home_url($selected_template->get_id()))); ?>" width="100%" height="100%"></iframe>
<iframe id="iframe" src="<?php echo set_url_scheme(add_query_arg('wu-preview', '1', get_home_url($selected_template->get_id()))); ?>" width="100%" height="100%"></iframe>
<?php else : ?>
<?php else : ?>
<div class="wu-styling">
<div class="wu-styling">
<div class="wu-w-full wu-text-center wu-relative wu-flex wu-justify-center wu-items-center wu-h-screen">
<div class="wu-w-full wu-text-center wu-relative wu-flex wu-justify-center wu-items-center wu-h-screen">
<div class="wu-text-xl wu-rounded wu-font-bold wu-uppercase wu-inline-block wu-p-8 wu-opacity-50" style="margin-top: 62px; background-color: #000; color: #666;">
<div class="wu-text-xl wu-rounded wu-font-bold wu-uppercase wu-inline-block wu-p-8 wu-opacity-50" style="margin-top: 62px; background-color: #000; color: #666;">
<?php _e('Site Template Preview will go here!', 'wp-ultimo'); ?>
<?php _e('Site Template Preview will go here!', 'wp-ultimo'); ?>
</div>
</div>
</div>
</div>
</div>
</div>
<?php endif; ?>
<?php endif; ?>
<?php wu_ignore_errors(function() {
wp_footer();
}); ?>
<?php
wu_ignore_errors(
function () {
wp_footer();
}
);
?>
</body>
</body>
</html>

View File

@ -11,111 +11,111 @@
<div id="wu-toolbox" class="wu-styling">
<div
class="wu-fixed wu-bottom-0 wu-right-0 wu-mr-4 wu-mb-4 wu-bg-white wu-px-4 wu-py-2 wu-pl-2 wu-shadow-md wu-rounded-full wu-uppercase wu-text-xs wu-text-gray-700">
<div
class="wu-fixed wu-bottom-0 wu-right-0 wu-mr-4 wu-mb-4 wu-bg-white wu-px-4 wu-py-2 wu-pl-2 wu-shadow-md wu-rounded-full wu-uppercase wu-text-xs wu-text-gray-700">
<ul class="wu-inline-block wu-m-0 wu-p-0 wu-align-middle wu-mx-1">
<li class="wu-inline-block wu-m-0 wu-p-0">
<span id="wu-toolbox-toggle" class="dashicons-before dashicons-wu-wp-ultimo" <?php echo wu_tooltip_text(__('Toggle Toolbox', 'wp-ultimo')); ?>></span>
</li>
</ul>
<ul class="wu-inline-block wu-m-0 wu-p-0 wu-align-middle wu-mx-1">
<li class="wu-inline-block wu-m-0 wu-p-0">
<span id="wu-toolbox-toggle" class="dashicons-before dashicons-wu-wp-ultimo" <?php echo wu_tooltip_text(__('Toggle Toolbox', 'wp-ultimo')); ?>></span>
</li>
</ul>
<ul id="wu-toolbox-links" class="wu-inline-block wu-m-0 wu-p-0 wu-align-middle wu-mx-1">
<ul id="wu-toolbox-links" class="wu-inline-block wu-m-0 wu-p-0 wu-align-middle wu-mx-1">
<li class="wu-inline-block wu-m-0 wu-p-0 wu-px-2">
<li class="wu-inline-block wu-m-0 wu-p-0 wu-px-2">
<a href="<?php echo esc_attr(wu_network_admin_url('wp-ultimo-edit-site', array('id' => $current_site->get_id()))); ?>"
class="wu-inline-block wu-uppercase wu-text-gray-600 wu-no-underline">
<span title="<?php esc_attr_e('Current Site', 'wp-ultimo'); ?>"
class="dashicons-wu-browser wu-text-sm wu-w-auto wu-h-auto wu-align-text-bottom wu-relative"></span>
<span class="">
<?php echo $current_site->get_title(); ?>
</span>
</a>
<a href="<?php echo esc_attr(wu_network_admin_url('wp-ultimo-edit-site', array('id' => $current_site->get_id()))); ?>"
class="wu-inline-block wu-uppercase wu-text-gray-600 wu-no-underline">
<span title="<?php esc_attr_e('Current Site', 'wp-ultimo'); ?>"
class="dashicons-wu-browser wu-text-sm wu-w-auto wu-h-auto wu-align-text-bottom wu-relative"></span>
<span class="">
<?php echo $current_site->get_title(); ?>
</span>
</a>
</li>
</li>
<?php if ($customer) : ?>
<?php if ($customer) : ?>
<li class="wu-inline-block wu-m-0 wu-p-0 wu-px-2">
<li class="wu-inline-block wu-m-0 wu-p-0 wu-px-2">
<a href="<?php echo esc_attr(wu_network_admin_url('wp-ultimo-edit-customer', array('id' => $customer->get_id()))); ?>"
class="wu-inline-block wu-uppercase wu-text-gray-600 wu-no-underline">
<span title="<?php esc_attr_e('Current Site', 'wp-ultimo'); ?>"
class="dashicons-wu-user wu-text-sm wu-w-auto wu-h-auto wu-align-text-bottom wu-relative"></span>
<span class="">
<?php echo $customer->get_display_name(); ?>
</span>
</a>
<a href="<?php echo esc_attr(wu_network_admin_url('wp-ultimo-edit-customer', array('id' => $customer->get_id()))); ?>"
class="wu-inline-block wu-uppercase wu-text-gray-600 wu-no-underline">
<span title="<?php esc_attr_e('Current Site', 'wp-ultimo'); ?>"
class="dashicons-wu-user wu-text-sm wu-w-auto wu-h-auto wu-align-text-bottom wu-relative"></span>
<span class="">
<?php echo $customer->get_display_name(); ?>
</span>
</a>
</li>
</li>
<?php endif; ?>
<?php endif; ?>
<?php if ($membership) : ?>
<?php if ($membership) : ?>
<li class="wu-inline-block wu-m-0 wu-p-0 wu-px-2">
<li class="wu-inline-block wu-m-0 wu-p-0 wu-px-2">
<a href="<?php echo esc_attr(wu_network_admin_url('wp-ultimo-edit-membership', array('id' => $membership->get_id()))); ?>"
class="wu-inline-block wu-uppercase wu-text-gray-600 wu-no-underline">
<span title="<?php esc_attr_e('Current Site', 'wp-ultimo'); ?>"
class="dashicons-wu-circular-graph wu-text-sm wu-w-auto wu-h-auto wu-align-text-bottom wu-relative"></span>
<span class="">
<?php echo sprintf(__('Membership <Strong>%s</strong>', 'wp-ultimo'), $membership->get_hash()); ?>
</span>
<span id="wu-toolbox-membership-status" class="wu-inline-block wu-w-3 wu-h-3 wu-rounded-full wu-align-text-top <?php echo esc_attr($membership->get_status_class()); ?>" <?php echo wu_tooltip_text($membership->get_status_label()); ?>>
&nbsp;
</span>
</a>
<a href="<?php echo esc_attr(wu_network_admin_url('wp-ultimo-edit-membership', array('id' => $membership->get_id()))); ?>"
class="wu-inline-block wu-uppercase wu-text-gray-600 wu-no-underline">
<span title="<?php esc_attr_e('Current Site', 'wp-ultimo'); ?>"
class="dashicons-wu-circular-graph wu-text-sm wu-w-auto wu-h-auto wu-align-text-bottom wu-relative"></span>
<span class="">
<?php printf(__('Membership <Strong>%s</strong>', 'wp-ultimo'), $membership->get_hash()); ?>
</span>
<span id="wu-toolbox-membership-status" class="wu-inline-block wu-w-3 wu-h-3 wu-rounded-full wu-align-text-top <?php echo esc_attr($membership->get_status_class()); ?>" <?php echo wu_tooltip_text($membership->get_status_label()); ?>>
&nbsp;
</span>
</a>
</li>
</li>
<?php endif; ?>
<?php endif; ?>
</ul>
</ul>
<ul class="wu-inline-block wu-m-0 wu-p-0 wu-align-middle wu-mx-1">
<li class="wu-inline-block wu-m-0 wu-p-0">
<ul class="wu-inline-block wu-m-0 wu-p-0 wu-align-middle wu-mx-1">
<li class="wu-inline-block wu-m-0 wu-p-0">
<a id="wu-jumper-button-trigger" href="#"
class="wu-inline-block wu-uppercase wu-text-gray-600 wu-no-underline">
<span title="<?php esc_attr_e('Jumper', 'wp-ultimo'); ?>"
class="dashicons dashicons-wu-flash wu-text-sm wu-w-auto wu-h-auto wu-align-text-top wu-relative wu--mr-1"></span>
<span class="wu-font-bold">
<?php esc_attr_e('Jumper', 'wp-ultimo'); ?>
</span>
</a>
<a id="wu-jumper-button-trigger" href="#"
class="wu-inline-block wu-uppercase wu-text-gray-600 wu-no-underline">
<span title="<?php esc_attr_e('Jumper', 'wp-ultimo'); ?>"
class="dashicons dashicons-wu-flash wu-text-sm wu-w-auto wu-h-auto wu-align-text-top wu-relative wu--mr-1"></span>
<span class="wu-font-bold">
<?php esc_attr_e('Jumper', 'wp-ultimo'); ?>
</span>
</a>
</li>
</ul>
</li>
</ul>
</div>
</div>
</div>
<script>
if (typeof jQuery !== 'undefined') {
(function($) {
$(document).ready(function() {
$('body').on('click', '#wu-toolbox-toggle', function() {
$(this).parents('#wu-toolbox').toggleClass('wu-toolbox-closed');
});
});
})(jQuery);
(function($) {
$(document).ready(function() {
$('body').on('click', '#wu-toolbox-toggle', function() {
$(this).parents('#wu-toolbox').toggleClass('wu-toolbox-closed');
});
});
})(jQuery);
} // end if;
</script>
<style>
#wu-toolbox-links {
transition: width 2s;
transition: width 2s;
}
.wu-toolbox-closed #wu-toolbox-links {
transition: width 2s;
width: 1px;
height: 1px;
overflow: hidden;
transition: width 2s;
width: 1px;
height: 1px;
overflow: hidden;
}
#wu-toolbox-membership-status {
margin-top: 2px;
margin-top: 2px;
}
</style>