Plugin Tabs noticias

This commit is contained in:
root
2026-04-14 13:50:04 -06:00
parent 299099d006
commit 19d08e5694
2334 changed files with 628926 additions and 113 deletions

View File

@@ -0,0 +1,23 @@
<?php
$block_folders = array();
$block_folders[$option['block']] = $option['block'] . '/templates';
$templates = lightspeed_get_block_templates( $block_folders );
?>
<select
name="<?php echo esc_attr( $option['name'] ) ?>"
type="text"
id="<?php echo esc_attr( $option['name'] ) ?>"
data-form-type="other"
data-default="<?php echo esc_attr( $option['default'] ) ?>"
>
<?php foreach ( $templates[$option['block']] as $template_key => $template ) : ?>
<option
<?php echo esc_attr( ( $value == $template['value'] ) || ( !$value && $template['value'] == $option['default'] ) ? 'selected="selected"' : '' ) ?>
value="<?php echo esc_attr( $template['value'] ) ?>"
>
<?php echo esc_attr( $template['label'] ) ?>
</option>
<?php endforeach; ?>
</select>

View File

@@ -0,0 +1,11 @@
<label for="<?php echo esc_attr( $option['name'] ) ?>">
<input
name="<?php echo esc_attr( $option['name'] ) ?>"
type="checkbox"
id="<?php echo esc_attr( $option['name'] ) ?>"
value="1"
data-form-type="other"
<?php echo esc_attr( $value ? 'checked="checked"' : '' ) ?>
data-default="<?php echo esc_attr( $option['default'] ) ?>"
>
</label>

View File

@@ -0,0 +1,21 @@
<div class="areoi-variable-row <?php echo esc_attr( $is_variable ? 'areoi-is-variable' : '' ) ?>">
<div class="areoi-field areoi-field-visual">
<input
name="<?php echo esc_attr( $option['name'] ) ?>-color-picker"
type="text"
value="<?php echo esc_attr( $is_variable ? '' : $value ) ?>"
class="regular-text areoi-colour-picker"
data-form-type="other"
data-default="<?php echo esc_attr( $option['default'] ) ?>"
data-alpha-enabled="true"
>
<div></div>
<button type="button" class="areoi-toggle-field">Use SASS variable</button>
</div>
<div class="areoi-field areoi-field-variable">
<?php include( AREOI__PLUGIN_DIR . 'views/inputs/text.php' ); ?>
<div></div>
<button type="button" class="areoi-toggle-field">Use color picker</button>
</div>
</div>

View File

@@ -0,0 +1,23 @@
<?php
$block_folders = array();
$block_folders['dividers'] = 'dividers';
$templates = lightspeed_get_block_templates( $block_folders, false );
?>
<select
name="<?php echo esc_attr( $option['name'] ) ?>"
type="text"
id="<?php echo esc_attr( $option['name'] ) ?>"
data-form-type="other"
data-default="<?php echo esc_attr( $option['default'] ) ?>"
>
<?php foreach ( $templates['dividers'] as $template_key => $template ) : ?>
<option
<?php echo esc_attr( ( $value == $template['value'] ) || ( !$value && $template['value'] == $option['default'] ) ? 'selected="selected"' : '' ) ?>
value="<?php echo esc_attr( $template['value'] ) ?>"
>
<?php echo esc_attr( $template['label'] ) ?>
</option>
<?php endforeach; ?>
</select>

View File

@@ -0,0 +1,54 @@
<?php
$fonts = array(
'Roboto',
'Open Sans',
'Lato',
'Montserrat',
'Oswald',
'Source Sans Pro',
'Roboto Condensed',
'Poppins',
'Noto Sans',
'Roboto Mono',
'Raleway',
'Ubuntu',
'PT Sans',
'Merriweather',
'Roboto Slab',
'Nunito',
'Playfair Display',
'Lora',
'Rubik',
'Open Sans Condensed'
);
?>
<div class="areoi-variable-row <?php echo esc_attr( $is_variable ? 'areoi-is-variable' : '' ) ?>">
<div class="areoi-field areoi-field-visual">
<select
name="<?php echo esc_attr( $option['name'] ) ?>-font-picker"
type="text"
class="regular-text areoi-font-picker"
data-form-type="other"
data-default="<?php echo esc_attr( $option['default'] ) ?>"
>
<option value="<?php echo esc_attr( $option['default'] ) ?>">Default</option>
<?php foreach ( $fonts as $select_option_key => $select_option ) : ?>
<option
<?php echo esc_attr( $value == $select_option ? 'selected="selected"' : '' ) ?>
value="<?php echo esc_attr( $select_option ) ?>"
style="font-family: <?php echo esc_attr( $select_option ) ?>; font-size: 22px;"
>
<?php echo esc_attr( $select_option ) ?>
</option>
<?php endforeach; ?>
</select>
<div></div>
<button type="button" class="areoi-toggle-field">Use SASS variable</button>
</div>
<div class="areoi-field areoi-field-variable">
<?php include( AREOI__PLUGIN_DIR . 'views/inputs/text.php' ); ?>
<div></div>
<button type="button" class="areoi-toggle-field">Use font picker</button>
</div>
</div>

View File

@@ -0,0 +1,21 @@
<?php $icons = json_decode( file_get_contents( AREOI__PLUGIN_DIR . 'blocks/icon/icons.json' ), true ); ?>
<select
name="<?php echo esc_attr( $option['name'] ) ?>"
type="text"
id="<?php echo esc_attr( $option['name'] ) ?>"
data-form-type="other"
data-default="<?php echo esc_attr( $option['default'] ) ?>"
>
<option value="">None</option>
<?php foreach ( $icons as $icon_key => $icon ) : ?>
<option
<?php echo esc_attr( ( $value == $icon ) || ( !$value && $icon == $option['default'] ) ? 'selected="selected"' : '' ) ?>
value="<?php echo esc_attr( $icon ) ?>"
>
<?php echo esc_attr( $icon ) ?>
</option>
<?php endforeach; ?>
</select>
<p>You can browse all available icons <a href="https://icons.getbootstrap.com/" target="_blank">here</a>.</p>

View File

@@ -0,0 +1,19 @@
<?php //echo '<pre>'; print_r( $value ); echo '</pre>'; die; ?>
<div class="areoi-variable-row <?php echo esc_attr( $is_variable ? 'areoi-is-variable' : '' ) ?>">
<div class="areoi-field areoi-field-visual">
<div class="areoi-upl-container <?php echo esc_attr( $value ? 'with-image' : '' ) ?>">
<a href="#" class="areoi-upl areoi-image-opaque">
<img src="<?php echo esc_url( $value ) ?>" style="width: 100%; height: auto;" />
<span class="button">Upload image</span>
</a>
<a href="#" class="areoi-rmv">Remove image</a>
</div><!-- .areoi-upl-container -->
<div></div>
</div>
<div class="areoi-field areoi-field-variable">
<?php include( AREOI__PLUGIN_DIR . 'views/inputs/text.php' ); ?>
<div></div>
<button type="button" class="areoi-toggle-field">Use media uploader</button>
</div>
</div>

View File

@@ -0,0 +1,23 @@
<?php
$block_folders = array();
$block_folders['masks'] = 'masks';
$templates = lightspeed_get_block_templates( $block_folders, false );
?>
<select
name="<?php echo esc_attr( $option['name'] ) ?>"
type="text"
id="<?php echo esc_attr( $option['name'] ) ?>"
data-form-type="other"
data-default="<?php echo esc_attr( $option['default'] ) ?>"
>
<?php foreach ( $templates['masks'] as $template_key => $template ) : ?>
<option
<?php echo esc_attr( ( $value == $template['value'] ) || ( !$value && $template['value'] == $option['default'] ) ? 'selected="selected"' : '' ) ?>
value="<?php echo esc_attr( $template['value'] ) ?>"
>
<?php echo esc_attr( $template['label'] ) ?>
</option>
<?php endforeach; ?>
</select>

View File

@@ -0,0 +1,23 @@
<?php
$block_folders = array();
$block_folders['patterns'] = 'patterns';
$templates = lightspeed_get_block_templates( $block_folders, false );
?>
<select
name="<?php echo esc_attr( $option['name'] ) ?>"
type="text"
id="<?php echo esc_attr( $option['name'] ) ?>"
data-form-type="other"
data-default="<?php echo esc_attr( $option['default'] ) ?>"
>
<?php foreach ( $templates['patterns'] as $template_key => $template ) : ?>
<option
<?php echo esc_attr( ( $value == $template['value'] ) || ( !$value && $template['value'] == $option['default'] ) ? 'selected="selected"' : '' ) ?>
value="<?php echo esc_attr( $template['value'] ) ?>"
>
<?php echo esc_attr( $template['label'] ) ?>
</option>
<?php endforeach; ?>
</select>

View File

@@ -0,0 +1,23 @@
<?php
$block_folders = array();
$block_folders['placeholders'] = 'placeholders';
$templates = lightspeed_get_block_templates( $block_folders, false );
?>
<select
name="<?php echo esc_attr( $option['name'] ) ?>"
type="text"
id="<?php echo esc_attr( $option['name'] ) ?>"
data-form-type="other"
data-default="<?php echo esc_attr( $option['default'] ) ?>"
>
<?php foreach ( $templates['placeholders'] as $template_key => $template ) : ?>
<option
<?php echo esc_attr( ( $value == $template['value'] ) || ( !$value && $template['value'] == $option['default'] ) ? 'selected="selected"' : '' ) ?>
value="<?php echo esc_attr( $template['value'] ) ?>"
>
<?php echo esc_attr( $template['label'] ) ?>
</option>
<?php endforeach; ?>
</select>

View File

@@ -0,0 +1,68 @@
<?php if ( $option['input'] == 'header' ) : ?>
<tr>
<th scope="row" colspan="2">
<h3 id="<?php echo esc_attr( sanitize_title( $option['label'] ) ) ?>" class="areoi-table-header">
<?php echo esc_attr( $option['label'] ) ?>
</h3>
<?php if ( $option['description'] ) : ?>
<p style="margin: 1rem 0; font-weight: normal;"><?php echo esc_attr( $option['description'] ) ?></p>
<?php endif; ?>
</th>
</tr>
<?php else : ?>
<?php
$theme_json = '';
if ( areoi2_has_theme_json() && areoi2_has_theme_json_value( $option['name'] ) ) {
$theme_json = '<p style="text-align:center; max-width: 250px">' . __( 'This field is being populated by your theme.json file. The current value is: ', AREOI__TEXT_DOMAIN ) . '<span class="abb-highlight">' . areoi2_get_theme_json_value( $option['name'] ) . '</span></p>';
}
?>
<tr class="areoi-row-input">
<th>
<label for="<?php echo esc_attr( $option['name'] ) ?>">
<?php echo esc_attr( $option['label'] ) ?>
</label>
<div></div>
<p><code style="font-size: 12px;"><?php echo $option['name'] ?></code></p>
<?php if ( !empty( $option['allow_reset'] ) ) : ?>
<button
class="areoi-reset"
type="button"
data-id="<?php echo esc_attr( $option['name'] ) ?>"
>
Reset to Bootstrap default
</button>
<?php endif; ?>
</th>
<td>
<?php if ( $theme_json ) : ?>
<?php echo $theme_json; ?>
<?php else : ?>
<?php
if ( !empty( $option['input'] ) ) :
$value = get_option( $option['name'], $option['default'] );
$is_variable = ( $value && strpos( $value, '$' ) === false ) && ( strpos( $value, 'theme-json-' ) === false ) ? false : true;
include( AREOI__PLUGIN_DIR . 'views/inputs/' . $option['input'] . '.php' );
endif;
?>
<?php if ( $option['description'] ) : ?>
<p class="areoi-description" id="<?php echo esc_attr( $option['name'] ) ?>-description">
<?php echo esc_attr( $option['description'] ) ?>
</p>
<?php endif; ?>
<?php endif; ?>
</td>
</tr>
<?php endif; ?>

View File

@@ -0,0 +1,16 @@
<select
name="<?php echo esc_attr( $option['name'] ) ?>"
type="text"
id="<?php echo esc_attr( $option['name'] ) ?>"
data-form-type="other"
data-default="<?php echo esc_attr( $option['default'] ) ?>"
>
<?php foreach ( $option['options'] as $select_option_key => $select_option ) : ?>
<option
<?php echo esc_attr( ( $value == $select_option['id'] ) || ( !$value && $select_option['id'] == $option['default'] ) ? 'selected="selected"' : '' ) ?>
value="<?php echo esc_attr( $select_option['id'] ) ?>"
>
<?php echo esc_attr( $select_option['label'] ) ?>
</option>
<?php endforeach; ?>
</select>

View File

@@ -0,0 +1,23 @@
<div class="areoi-field">
<input
name="<?php echo esc_attr( $option['name'] ) ?>"
type="text"
id="<?php echo esc_attr( $option['name'] ) ?>"
value="<?php echo esc_attr( $value ) ?>"
class="areoi-input-text"
data-form-type="other"
data-default="<?php echo esc_attr( $option['default'] ) ?>"
placeholder="<?php echo esc_attr( $option['default'] ) ?>"
>
<?php if ( empty( $option['exclude_variables'] ) ) : ?>
<select class="areoi-select-variable" name="areoi-select-variable">
<option value="">Populate with variable</option>
</select>
<?php if ( !empty( $has_theme_json ) ) : ?>
<select class="areoi-select-theme-json" name="areoi-select-theme-json">
<option value="">Populate with theme.json</option>
</select>
<?php endif; ?>
<?php endif; ?>
</div>

View File

@@ -0,0 +1,24 @@
<div style="float: left; width: 400px; padding: 20px;">
<div class="areoi-card active areoi-card-branded" style="background: #2e085e; border: none;">
<div class="areoi-card-body">
<p>
<img src="<?php echo esc_url( AREOI__PLUGIN_URI . 'assets/img/areoi-logo.svg' ) ?>" width="150">
</p>
<h2 style="line-height: 1.4em;">Democratising digital success.</h2>
<p>Our mission is to democratise digital success by making high-quality websites accessible to every organisation.</p>
<a href="https://areoi.io" target="_blank" class="areoi-button" style="background: #ff7676;">Visit areoi.io</a>
<a href="https://areoi.io/all-bootstrap-blocks/" target="_blank">Plugin Features</a>
<a href="https://areoi.io/all-bootstrap-blocks/documentation" target="_blank">Plugin Docs</a>
</div><!-- .areoi-card-body -->
</div><!-- .areoi-card -->
<div class="areoi-card active" style="background: #fff;">
<div class="areoi-card-body">
<?php include( AREOI__PLUGIN_DIR . 'views/partials/mailchimp.php' ); ?>
</div><!-- .areoi-card-body -->
</div><!-- .areoi-card -->
</div>

View File

@@ -0,0 +1,27 @@
<!-- Begin Mailchimp Signup Form -->
<div id="mc_embed_signup">
<form action="https://areoi.us5.list-manage.com/subscribe/post?u=09c1b05c728be18e6a11cb6d5&amp;id=32f754f47b" method="post" id="mc-embedded-subscribe-form" name="mc-embedded-subscribe-form" class="validate" target="_blank" novalidate>
<div id="mc_embed_signup_scroll">
<div class="indicates-required"><span class="asterisk">*</span> required</div>
<h2>Subscribe</h2>
<p>Be the first to know about our latest releases, new plugins and useful tips.</p>
<div class="mc-field-group">
<label for="mce-EMAIL">Email Address <span class="asterisk">*</span>
</label>
<input type="email" value="" name="EMAIL" class="required email" id="mce-EMAIL">
</div>
<div id="mce-responses" class="clear">
<div class="response" id="mce-error-response" style="display:none"></div>
<div class="response" id="mce-success-response" style="display:none"></div>
</div>
<!-- real people should not fill this in and expect good things - do not remove this or risk form bot signups-->
<div style="position: absolute; left: -5000px;" aria-hidden="true"><input type="text" name="b_09c1b05c728be18e6a11cb6d5_32f754f47b" tabindex="-1" value=""></div>
<div class="clear"><input type="submit" value="Subscribe" name="subscribe" id="mc-embedded-subscribe" class="button"></div>
</div>
</form>
</div>
<script type='text/javascript' src='//s3.amazonaws.com/downloads.mailchimp.com/js/mc-validate.js'></script>
<script type='text/javascript'>(function($) {window.fnames = new Array(); window.ftypes = new Array();fnames[0]='EMAIL';ftypes[0]='email';fnames[1]='FNAME';ftypes[1]='text';fnames[2]='LNAME';ftypes[2]='text';fnames[3]='ADDRESS';ftypes[3]='address';fnames[4]='PHONE';ftypes[4]='phone';fnames[5]='BIRTHDAY';ftypes[5]='birthday';}(jQuery));var $mcj = jQuery.noConflict(true);</script>
<!--End mc_embed_signup-->

View File

@@ -0,0 +1,40 @@
<?php if ( !empty( $active_page['sections'] ) ) : ?>
<?php foreach ( $active_page['sections'] as $section_key => $section ) : ?>
<?php if ( ( sanitize_text_field( !empty( $_GET['section'] ) ) && $section['slug'] == sanitize_text_field( $_GET['section'] ) ) || ( $section_key == 0 && sanitize_text_field( empty( $_GET['section'] ) ) ) ) : ?>
<input type="hidden" name="section" value="<?php echo $section['slug'] ?>">
<div
class="areoi-card active"
style="">
<div class="areoi-card-body">
<h2><?php echo esc_attr( $section['name'] ) ?></h2>
<?php if ( !empty( $section['description'] ) ) : ?>
<p><?php echo wp_kses_post( $section['description'] ) ?></p>
<?php endif; ?>
<?php if ( !empty( $section['options'] ) ) : ?>
<table class="areoi-form-table form-table" role="presentation">
<tbody>
<?php
foreach ( $section['options'] as $option_key => $option ) :
if ( !empty( $option['input'] ) ) :
include( AREOI__PLUGIN_DIR . 'views/inputs/row.php' );
endif;
endforeach;
?>
</tbody>
</table>
<?php endif; ?>
</div><!-- .areoi-card-body -->
</div><!-- .areoi--card -->
<?php endif; ?>
<?php endforeach; ?>
<?php endif; ?>

View File

@@ -0,0 +1,50 @@
<?php
$get_section = sanitize_text_field( !empty( $_GET['section'] ) ) ? sanitize_text_field( $_GET['section'] ) : false;
?>
<div class="areoi-sidebar">
<div class="areoi-sidebar__content">
<?php if ( !areoi_is_lightspeed() ) : ?>
<h1><img style="display: block;" src="<?php echo esc_url( AREOI__PLUGIN_URI . 'assets/img/areoi-logo-dark.svg' ) ?>" width="150"></h1>
<?php endif; ?>
<ul class="areoi-sidebar__list">
<?php foreach ( $page['children'] as $child_key => $child) : ?>
<?php if ( $child_key == 'areoi-dashboard' || get_option( 'areoi-dashboard-global-bootstrap-css', 1 ) == 1 ) : ?>
<li class="
areoi-sidebar__link
<?php echo esc_attr( $child['slug'] == $active_page['slug'] ? 'active' : '' ) ?>
<?php echo esc_attr( !empty( $child['sections'] ) && count( $child['sections'] ) > 1 ? 'has-children' : '' ) ?>
">
<a href="?page=<?php echo esc_attr( $child['slug'] ) ?>">
<?php echo esc_attr( $child['name'] ) ?>
</a>
<?php if ( !empty( $child['sections'] ) && count( $child['sections'] ) > 1 ) : ?>
<ul class="areoi-sidebar__sub-list">
<?php foreach ( $child['sections'] as $section_key => $section ) : ?>
<li class="areoi-sidebar__sub-link <?php echo esc_attr( ( $section_key == 0 && !$get_section || $section['slug'] == $get_section ) ? 'active' : '' ) ?>">
<a href="?page=<?php echo esc_attr( $child['slug'] ) ?>&section=<?php echo esc_attr( $section['slug'] ) ?>">
<?php echo esc_attr( $section['name'] ) ?>
</a>
<?php if ( !empty( $section['options'] ) ) : ?>
<ul class="areoi-sidebar__sub-sub-list">
<?php foreach ( $section['options'] as $option_key => $option ) : ?>
<?php if ( $option['input'] == 'header' ) : ?>
<li class="areoi-sidebar__sub-sub-link">
<a href="#<?php echo esc_attr( sanitize_title( $option['label'] ) ) ?>"><?php echo esc_attr( $option['label'] ) ?></a>
</li>
<?php endif; ?>
<?php endforeach; ?>
</ul>
<?php endif; ?>
</li>
<?php endforeach; ?>
</ul>
<?php endif; ?>
</li>
<?php endif; ?>
<?php endforeach; ?>
</ul><!-- .areoi-sidebar__list-->
</div><!-- .areoi-sidebar__content -->
</div><!-- .areoi-sidebar -->