Plugin Directory

Changeset 2210468


Ignore:
Timestamp:
12/12/2019 12:16:15 AM (6 years ago)
Author:
echelonso
Message:

Fixed: Missing field descriptions for Before & After widget.
Fixed: Missing field descriptions for Button widget.
Fixed: Missing field descriptions for Card widget.
Fixed: Missing field descriptions for Counter widget.

Location:
echelon-so/trunk
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • echelon-so/trunk/echelon-so.php

    r2172675 r2210468  
    22
    33/*
    4 Plugin Name:    Echelon UIKit for SiteOrigin
     4Plugin Name:    Echelon UIkit for SiteOrigin
    55Plugin URI:     https://echelonso.com
    6 Description:    Echelon UIKit framework for SiteOrigin Page Builder.
    7 Version:        2.0.4
     6Description:    UIkit powered widgets, features and presets for SiteOrigin Page Builder.
     7Version:        2.0.5
    88Author:         Echelon
    99Author URI:     https://echelonso.com
     
    1717
    1818        public function __construct() {
     19
     20            define('ECHELONSO', true);
     21            define('ECHELONSO_VERSION', '2.0.5');
    1922
    2023            register_activation_hook( __FILE__, array( 'EchelonSO', 'install' ) );
     
    9093
    9194        public function current_version() {
    92             return '2.0.4';
     95            return '2.0.5';
    9396        }
    9497
     
    161164                add_filter( 'acf/settings/load_json', array($this, 'acf_json_load_point') );
    162165                add_filter( 'acf/load_field/name=echelonso_post_type', array( $this, 'acf_post_type_choices') );
     166            }
     167
     168            if (is_admin()) {
     169                // check for version mismatch
     170                if ( defined('ECHELONSO_VERSION') && defined('ECHELONSO_PRIME_VERSION') ) {
     171                    if (ECHELONSO_VERSION != ECHELONSO_PRIME_VERSION) {
     172                        add_action( 'admin_notices', array($this, 'version_mismatch_error') );
     173                    }
     174                }
     175                if (!defined('ECHELONSO_PRIME_VERSION')) {
     176                    add_action( 'admin_notices', array($this, 'version_mismatch_error') );
     177                }
    163178            }
    164179
     
    315330        public function scripts() {
    316331            wp_enqueue_style( 'echelonso_uikit_compiled', wp_get_upload_dir()['baseurl'] . "/echelon-so/echelon.css", array(), get_option('eso_css_rand'));
    317             wp_enqueue_script('echelonso_js', plugin_dir_url(__FILE__) . 'inc/echelon.js', array('jquery'), $this->current_version(), true);
    318             wp_enqueue_script('echelonso_uikit', 'https://cdnjs.cloudflare.com/ajax/libs/uikit/3.1.6/js/uikit.min.js', array('jquery'), '3.1.6', true);
    319             wp_enqueue_script('echelonso_uikit_icons', 'https://cdnjs.cloudflare.com/ajax/libs/uikit/3.1.6/js/uikit-icons.min.js', array('jquery'), '3.1.6', true);
     332            wp_enqueue_script('echelonso_js', plugin_dir_url(__FILE__) . 'inc/echelon.js', array('jquery'), $this->current_version(), false);
     333            wp_enqueue_script('echelonso_uikit', 'https://cdnjs.cloudflare.com/ajax/libs/uikit/3.1.6/js/uikit.min.js', array('jquery'), '3.1.6', false);
     334            wp_enqueue_script('echelonso_uikit_icons', 'https://cdnjs.cloudflare.com/ajax/libs/uikit/3.1.6/js/uikit-icons.min.js', array('jquery'), '3.1.6', false);
    320335        }
    321336
     
    541556        }
    542557
     558        public function version_mismatch_error() {
     559            define('ECHELONSO_VERSION_MISMATCH', true);
     560            echo '<div class="notice notice-error"><p>Please update your plugins <strong>Echelon UIkit for SiteOrigin</strong> and <strong>Echelon UIkit for SiteOrigin Prime Upgrade</strong> to the latest versions.</p></div>';
     561        }
     562
    543563        /*
    544564        * Form Teaser
     
    603623        }
    604624
     625
     626
    605627    }
    606628
  • echelon-so/trunk/readme.txt

    r2172670 r2210468  
    1 === UIKit for SiteOrigin Page Builder ===
     1=== UIkit for SiteOrigin Page Builder ===
    22Contributors: echelonso
    3 Requires at least: 5.2
    4 Tested up to: 5.2
     3Requires at least: 5.3
     4Tested up to: 5.3
    55Requires PHP: 7.0
    66Stable tag: trunk
     
    88License URI: https://www.gnu.org/licenses/gpl-3.0.txt
    99
    10 Echelon transforms SiteOrigin's Page Builder into a UIKit 3 development powerhouse that anyone can use.
     10UIkit powered Animations, Transitions, Widgets, Features, Presets and Site Packs for SiteOrigin Page Builder.
    1111
    1212== Description ==
    13 Echelon provides 0ver 40 UIKit powered SiteOrigin Widgets and Features enhancing the functionality of Page Builder with the best web developement framework available today. Building premium level UIKit web pages is now available to anyone who can use Page Builder drag and drop.
     13Echelon combines the web's best frontend framework (UIkit) with SiteOrgin's ease of use to create premium level pages at unbelieable speeds. We have included over 30 widgets, 15 core features and a library of over 240 ready to use interface blocks, making the the unparalled frontend power of UIkit available to anyone who can use SiteOrgin Page Builder.
    1414
    15 [Echelon Home](https://echelonso.com)
     15A word of caution, UIkit is highly addictive, once you start using UIkit you may find it hard to stop.
     16
     17[UIkit for SiteOrgin](https://echelonso.com)
     18
     19### Simple Modifier System
     20What makes building premium pages with Echelon so easy is it's simple modifier system. Echelon widgets are comprised from two parts Data and Modifiers. The Data section of a widget determines what will be displayed and the Modifiers section determines how it will look, simple right?
     21
     22For an example let's take the Text widget. You enter some text into the the Data section and choose the Text Large modifier. The text is now displayed the same size as all text set as large. A simple, easy and fast system for creating pages. Decide later that all large text is to small? No problem, adjust the size in the Customiser and all the text across your site will be adjusted with a single click.
     23
     24### Flexible Combinations
     25While our widgets are simple enough to use individually Echelon is unique as all our widgets are designed to be combined together. Combine Loops with Sliders and Filters, Overlays with Light Boxes, Modals with Galleries, Off Canvas with Menus the possiblilites are endless, flexible and intuative.
    1626
    1727### Reuse Your Content
    18 Echelon Layouts add a flexible additional system to SiteOrigin Page Builder. They provide an area in the WordPress administration (Admin > Echelon Layouts) to store and organize layouts along with a dedicated widget for displaying the content anywhere on your website. If you update the content in the reusable layout it will update in all areas you have it displayed. They are also used to create custom content loops, post boxes, product boxes and layouts for custom post types.
     28Building on the global nature of Echelon we have included a build it once and reuse it system called Echelon Layouts. They provide an area in the WordPress administration (Admin > Echelon Layouts) to store and organize layouts along with a dedicated widget (Reuse Layout) for displaying the content anywhere on your website. If you update the content in the Echelon Layout it will update in all areas you have it displayed.
    1929
    20 ### Animated Entrances for Widgets, Rows & Cells
    21 Adds a selection of entrance animations to widgets. Widgets can be animated individually or set the animation on a row to animate all row widgets in sequence automatically.
     30### Highly Interactive
     31UIkit has a large array of front end Animations and Transitions available, as such Echelon is by default a highly interactive frontend right out of the box. We didnt stop there though, alongside the baked in interactivity we have included two specific interaction features. The Animate feature will add entrance animations to any widget, row or cell, while the Hover Transition feature with add transition animations to widgets when hovered or focused. You can also trigger Transitions on widgets when using them inside the Slider widget and in loads of other places across the plugin.
    2232
    23 ### Animated Gradients
    24 Create color changing backgrounds for widgets rows and cells. Animated Gradients add an eye catching background with 4 transition states, variable speed, left-right, top-down and diagonal directions.
     33### Better Positioning
     34If you have ever tried to layout widgets horizontally without using columns or a tried to add a dynamic label to a widget you will know its not easy to position elements with Page Builder. UIkit has a plethora of positioning options so theres no reason Page Builder can't use them aswell. From absolute and relative postioning to responsive flex box options Echelon can better position your widgets than ever before.
    2535
    26 ### Attribute
    27 Alot of the interactive features of Echelon require attributes to be set on widgets, the Attribute feature makes this simple by providing a section to enter the key value pairs for widgets, e.g attr-key="my-value".
     36### Responsive Visibility
     37Sometimes its just not possbile to have desktop layouts degrade properly and a dedicated replacement section is needed. Echelon provides a simple Visbility feature to hide widgets rows or cells from certain sized screens. Choose if an element should be displayed on mobiles, tablets, desktops or any combintion of the three.
    2838
    29 ### Background RGBA
    30 Adds an additional background color option to the settings for widgets, rows and cells to allow for the easy selection of transparent background colors (rgba). The Helper CSS Darken option can also be set to inherit for transparent color overlays.
     39### Background Images
     40Unfortunately SiteOrigin's background image features are lackluster and minimal, Echelon supercharges backgrounds with some key features sadly missing in the Page Builder core. Choose which image size to use for the background, position the background image, blend the background image with the background color and disable the image responsively are just some of the awesome background image features available with Echelon.
    3141
    32 ### Cell Flex
    33 Its now easy to create sideways horizontal layouts that flow naturally in their grid cell. The Cell Flex feature adds options to grid cells that allow widgets to flow based on flex box and are easier to work with compared to traditional columns.
     42### Custom Color Palette
     43You know those little color squares displayed under the various color pickers? Thats the Color Palette. Would be great if you could set those to colors of your choosing, now you do just that by going to Appearance > Customise > Echelon > Custom Palette.
    3444
    35 ### Custom Palette
    36 Replace the default color palette for the standard and RGBA color pickers with 8 custom colors. Set the colors in Appearance > Customise > Echelon > Custom Palette.
     45### Theme Generation
     46UIkit uses a lot of CSS and is highly customisable. We have built a bespoke theme compiler to allow you create and customise a custom UIkit theme from the WordPress Customiser. Simply set your options and Echelon will output a bespoke theme just for you.
    3747
    38 ### Helper CSS
    39 Add CSS helper classes to widgets, rows and cells. Helpful classes include desktop and mobile visibility, box shadows, box rounding, clipping and positioning.
     48### Recent Posts / Products
     49SiteOrigin allows to you to build templates for loops (Recent Posts, Recent Products) and include them via PHP. Echelon takes this up a notch and provides a easy system to buld loop templates with Page Builder itself. It's super easy too, just add an Echelon Layout and fill with Tempalte tags, WooCommerce Tags and ACF fields then feed it into the Custom Loop widget.
    4050
    41 ### Highlight (Prime)
    42 Adds a larger emphasis border to the bottom of widgets.
     51### Prime
     52We love UIkit and SiteOrigin but we are also fond of electricty and food. Echelon Prime is our paid version and upgrades many of the widgets and features while adding some Prime specific functionality. Echelon is an unlimited product so we have two Prime plans available one for single developers and one for teams.
    4353
    44 ### Hover Transition (Prime)
    45 Apply transitions from the global transition list to widgets when they are hovered or focused.
     54### Features List
     55- Animate: Add entrace animations to widgets rows and cells.
     56- Animated Gradient: Color changing background gradients.
     57- Attribute: Toggle Modal and Off Canvas widgets from any page element.
     58- Background: Supercharged background image options.
     59- Background RGBA: Transparent background colors.
     60- Cell Flex: Layout widgets in a cell horizontally and vertically.
     61- Custom Palette: Choose your own colors for the color picker palettes.
     62- Helper: Add handy additional CSS classes to elements.
     63- Highlight: Make a widget more prominent.
     64- Hover Transition: Trigger transition animations on hover and focus.
     65- Linked Widgets: Link entire widgets to URLs (static, dynamic and loop support).
     66- Parallax: Animate CSS properties relative to the scroll position.
     67- Position: Better positioning of page elements.
     68- Scrollspy: Toggle CSS classes when elemetns enter and leave the view port.
     69- Sticky: Keep widgets visible when the page is scrolled.
    4670
    47 ### Linked Widgets
    48 When enabled the widget will be wrapped in a link tag to your given URL, Post ID, SiteOrigin Syntax or the permalink for the current global post. Simple and quick way to link entire widgets without worrying about buttons or text links.
    49 
    50 ### Parallax (Prime)
    51 Animate the CSS properties of widgets relative to their position in the viewport. Translate X and Y positions, background positions, rotation, scale, opacity, blur and greyscale.
    52 
    53 ### Sticky
    54 Keep important widgets visible by sticking them to their parent row. Stuck widgets can be offset from the viewport top.
    55 
    56 [Feature Examples](https://echelonso.com/features/)
    57 
    58 ### Widgets
    59 
     71### Widgets List
    6072- Before & After: Compare the visual difference between two images with a configurable slider.
    6173- Button: A variety of buttons that take your plugin styles with an optional label.
     
    91103- Video: Inline and autoplay videos, with or without covers.
    92104
    93 [Widget Examples](https://echelonso.com/widgets/)
    94 
    95 ### Advanced Custom Fields
    96 Echelon supports text, number, date and image based ACF fields and makes displaying their data simple. To use the templating functionality of Echelon the free version of ACF needs to be active. ACF field data can be accessed any place you are in the loop such as the Custom Loop widget, single post types or fields attached directly to the page or post you are viewing.
    97 
    98 Field data can be accessed via two methods, the loop or a Post Object field relation. Relation fields allow for easier data storage as you can have a Clients post type and access their data from a Projects post type. If the field relation is to an Echelon Layout you can tell the ACF Field widget to render the layout directly.
    99 
    100 ### Template Tags
    101 The Wordpress provided template tags are available via the Template Tag widget. As with ACF fields you can access template tags anywhere you are in the loop as they work off the global post.
    102 
    103 ### WooCommerce Tag (Prime)
    104 The WooCommerce tag available to Prime subscribers outputs product specific data and allows for the easy creation of product loops while working the same way as the ACF and Tempalte Tag widgets.
    105 
    106 ### Custom Post Types
    107 Building layouts for Custom Post Types is a very simple process. Add an Echelon Layout and set it to Single for the post type under the Echelon Layout options. Fill the Layout with Template Tags and ACF Field widgets. When the post type is viewed the given layout will be used.
    108 
    109 ### 404
    110 For a cherry on top we have enabled Echelon Layouts for 404 pages as well. As they are not in the loop you will need to use Custom Loop widgets to handle dynamic data if such data is needed.
    111 
    112 ### Prime
    113 Echelon Prime is our paid version and upgrades many of the widgets and features and adds Prime specific functionality. Echelon is an unlimited product so we have two plans available one for single developers and one for development teams.
     105Awesome you have made it to the bottom, all that's left now is to get Echelon installed and start building premium quality pages. [UIkit for SiteOrgin](https://echelonso.com)
    114106
    115107== Changelog ==
     108
     109= 2.0.5 =
     110* Fixed: Missing field descriptions for Before & After widget.
     111* Fixed: Missing field descriptions for Button widget.
     112* Fixed: Missing field descriptions for Card widget.
     113* Fixed: Missing field descriptions for Counter widget.
    116114
    117115= 2.0.4 =
  • echelon-so/trunk/widgets/eso-before-after/eso-before-after.php

    r2172670 r2210468  
    5353
    5454    function get_widget_form() {
    55         $return = array();
     55
     56        global $echelon_so;
     57
     58        $label_image_1 = 'Image 1 Label' . $echelon_so->prime_tag();
     59        $label_image_2 = 'Image 2 Label' . $echelon_so->prime_tag();
     60        $option_orientation_vertical = 'Vertical' . $echelon_so->prime_tag();
     61
    5662        $return['before_after'] = array(
    5763            'type' => 'section',
     
    6268                    'type' => 'media',
    6369                    'label' => __( 'Image 1', 'echelon-so' ),
     70                    'description' => __( 'The image to use for the left or top side of the slider.', 'echelon-so' ),
    6471                    'choose' => __( 'Choose image', 'echelon-so' ),
    6572                    'update' => __( 'Set image', 'echelon-so' ),
     
    7178                    'type' => 'image-size',
    7279                    'label' => __( 'Image 1 Size', 'echelon-so' ),
     80                    'description' => __( 'Choose which image size to use from those available.', 'echelon-so' ),
     81                ),
     82                'image_1_label' => array(
     83                    'type' => 'text',
     84                    'label' => __( $label_image_1, 'echelon-so' ),
     85                    'description' => __( 'Replace the default before label with some custom text.', 'echelon-so' ),
     86                    'default' => __( 'Before', 'echelon-so' ),
    7387                ),
    7488                'image_2' => array(
    7589                    'type' => 'media',
    7690                    'label' => __( 'Image 2', 'echelon-so' ),
     91                    'description' => __( 'The image to use for the right or bottom side of the slider.', 'echelon-so' ),
    7792                    'choose' => __( 'Choose image', 'echelon-so' ),
    7893                    'update' => __( 'Set image', 'echelon-so' ),
     
    8297                'image_2_size' => array(
    8398                    'type' => 'image-size',
     99                    'description' => __( 'Choose which image size to use from those available.', 'echelon-so' ),
    84100                    'label' => __( 'Image 2 Size', 'echelon-so' ),
    85101
     102                ),
     103                'image_2_label' => array(
     104                    'type' => 'text',
     105                    'label' => __( $label_image_2, 'echelon-so' ),
     106                    'description' => __( 'Replace the default after label with some custom text.', 'echelon-so' ),
     107                    'default' => __( 'After', 'echelon-so' ),
     108                ),
     109                'orientation' => array(
     110                    'type' => 'select',
     111                    'label' => __( 'Orientation', 'echelon-so' ),
     112                    'description' => __( 'Choose from a Horizontal (left / right) slider or Vertical (top / bottom) slider.', 'echelon-so' ),
     113                    'default' => __( 'horizontal', 'echelon-so' ),
     114                    'options' => array(
     115                        'horizontal' => __('Horizontal', 'echelon-so'),
     116                        'vertical' => __($option_orientation_vertical, 'echelon-so')
     117                    )
    86118                )
    87119            )
  • echelon-so/trunk/widgets/eso-button/eso-button.php

    r2172670 r2210468  
    2828
    2929    function get_template_name($instance) {
    30         return $instance['button']['template'];
     30        return 'default';
    3131    }
    3232
     
    7373    function get_widget_form() {
    7474
    75         global $echelon_so_modifiers;
     75        global $echelon_so, $echelon_so_modifiers;
     76
     77        $option_template_label = 'Label' . $echelon_so->prime_tag();
     78        $label_label_text = 'Label Text' . $echelon_so->prime_tag();
     79        $label_label_color = 'Label Background Color' . $echelon_so->prime_tag();
     80        $label_label_weight = 'Label Font Weight' . $echelon_so->prime_tag();
    7681
    7782        $return['button'] = array(
     
    8590                    'label' => __('Template', 'echelon-so'),
    8691                    'options' => array(
    87                         'default' => __('Default', 'echelon-so'),
     92                        'default' => __('-', 'echelon-so'),
     93                        'label' => __($option_template_label, 'echelon-so'),
    8894                    ),
    8995                    'state_emitter' => array(
     
    94100                'text' => array(
    95101                    'type' => 'text',
    96                     'label' => __('Text', 'echelon-so'),
     102                    'label' => __('Button Text', 'echelon-so'),
     103                    'description' => __('The text to use for the button.', 'echelon-so'),
    97104                    'default' => ''
    98105                ),
    99106                'label' => array(
    100107                    'type' => 'text',
    101                     'label' => __('Label', 'echelon-so'),
     108                    'label' => __($label_label_text, 'echelon-so'),
     109                    'description' => __('The text to use for the buttons label.', 'echelon-so'),
    102110                    'default' => '',
    103111                    'state_handler' => array(
     
    108116                'target_type' => array(
    109117                    'type' => 'select',
    110                     'label' => __('Target Type', 'echelon-so'),
    111                     'description' => __('Loop will automatically generate the Target based on the global post object. Mostly used inside the Custom Loop widget.', 'echelon-so'),
     118                    'label' => __('Destination Type', 'echelon-so'),
     119                    'description' => __('Loop will automatically generate the Destination URL based on the global post object. Mostly used inside the Custom Loop widget.', 'echelon-so'),
    112120                    'default' => 'direct',
    113121                    'options' => array(
    114                         'direct' => __('Direct', 'echelon-so'),
     122                        'direct' => __('-', 'echelon-so'),
    115123                        'loop' => __('Loop', 'echelon-so'),
    116124                    ),
     
    122130                'target' => array(
    123131                    'type' => 'link',
    124                     'label' => __('Target', 'echelon-so'),
     132                    'label' => __('Destination URL', 'echelon-so'),
     133                    'description' => __('The destination URL to use for the button.', 'echelon-so'),
    125134                    'default' => '',
    126135                    'state_handler' => array(
    127                         'target_type[direct]' => array( 'show' ),
    128                         '_else[target_type]' => array( 'hide' ),
     136                        'target_type[direct]' => array('show'),
     137                        '_else[target_type]' => array('hide'),
    129138                    ),
    130139                ),
     
    132141                    'type' => 'font',
    133142                    'default' => 'default',
    134                     'label' => __('Font', 'echelon-so'),
     143                    'label' => __('Button Font', 'echelon-so'),
     144                    'description' => __('Use a Google Font for the buttons text.', 'echelon-so'),
    135145                )
    136146            )
     
    159169                    'type' => 'select',
    160170                    'default' => '0',
    161                     'label' => __('Text Transform', 'echelon-so'),
     171                    'label' => __('Button Text Transform', 'echelon-so'),
    162172                    'description' => $echelon_so_modifiers->text_transform('description'),
    163173                    'options' => $echelon_so_modifiers->text_transform(),
     
    166176                    'type' => 'select',
    167177                    'default' => '0',
    168                     'label' => __('Font Weight', 'echelon-so'),
     178                    'label' => __('Button Font Weight', 'echelon-so'),
    169179                    'description' => $echelon_so_modifiers->font_weight('description'),
    170180                    'options' => $echelon_so_modifiers->font_weight(),
     
    173183                    'type' => 'select',
    174184                    'default' => '0',
    175                     'label' => __('Width', 'echelon-so'),
     185                    'label' => __('Button Width', 'echelon-so'),
    176186                    'description' => $echelon_so_modifiers->width('description'),
    177187                    'options' => $echelon_so_modifiers->width()
     
    180190                    'type' => 'select',
    181191                    'default' => '0',
    182                     'label' => __('Border Radius', 'echelon-so'),
     192                    'label' => __('Button Border Radius', 'echelon-so'),
    183193                    'description' => $echelon_so_modifiers->border_radius('description'),
    184194                    'options' => $echelon_so_modifiers->border_radius()
     
    201211                    'type' => 'select',
    202212                    'default' => '0',
    203                     'label' => __('Label Color', 'echelon-so'),
     213                    'label' => __($label_label_color, 'echelon-so'),
    204214                    'description' => __('Label colors use your global Background settings.', 'echelon-so'),
    205215                    'options' => $echelon_so_modifiers->label(),
     
    212222                    'type' => 'select',
    213223                    'default' => '0',
    214                     'label' => __('Label Weight', 'echelon-so'),
     224                    'label' => __($label_label_weight, 'echelon-so'),
    215225                    'description' => $echelon_so_modifiers->font_weight('description'),
    216226                    'options' => $echelon_so_modifiers->font_weight(),
  • echelon-so/trunk/widgets/eso-card/eso-card.php

    r2172670 r2210468  
    55Author: Echelon
    66Author URI: https://echelonso.com
     7Documentation: https://echelonso.com/widgets/card/
    78*/
    89
     
    1516            array(
    1617                'description' => __('Text and image based content cards.', 'echelon-so' ),
     18                'help' => 'https://echelonso.com/widgets/card/',
    1719            ),
    1820            array(),
     
    2729
    2830    function get_template_name($instance) {
    29         return $instance['card']['template'];
     31
     32        if ( $instance['card']['template'] == 'default' ) {
     33            return 'default';
     34        }
     35
     36        if ( $instance['card']['template'] == 'sub_title' ) {
     37            return 'sub_title';
     38        }
     39
     40        return 'default';
    3041    }
    3142
     
    101112    function get_widget_form() {
    102113
    103         global $echelon_so_modifiers;
     114        global $echelon_so, $echelon_so_modifiers;
     115
     116        $option_template_image_top = 'Image Top' . $echelon_so->prime_tag();
     117        $option_template_image_bottom = 'Image Bottom' . $echelon_so->prime_tag();
     118        $option_template_image_minimal = 'Image Minimal' . $echelon_so->prime_tag();
     119        $label_card_image = 'Card Image' . $echelon_so->prime_tag();
     120        $label_card_image_size = 'Card Image Size' . $echelon_so->prime_tag();
     121        $label_image_transition = 'Image Transition' . $echelon_so->prime_tag();
     122        $label_two_image = 'Two Image' . $echelon_so->prime_tag();
    104123
    105124        $return['card'] = array(
     
    112131                    'default' => 'default',
    113132                    'label' => __('Template', 'echelon-so'),
     133                    'description' => __('The template determines the layout of the Card plus its available Data & modifier fields.', 'echelon-so'),
    114134                    'options' => array(
    115                         'default' => __('Default', 'echelon-so'),
     135                        'default' => __('-', 'echelon-so'),
    116136                        'sub_title' => __('Sub Title', 'echelon-so'),
     137                        'image_top' => __($option_template_image_top, 'echelon-so'),
     138                        'image_bottom' => __($option_template_image_bottom, 'echelon-so'),
     139                        'image_minimal' => __($option_template_image_minimal, 'echelon-so'),
    117140                    ),
    118141                    'state_emitter' => array(
     
    123146                'image' => array(
    124147                    'type' => 'media',
    125                     'label' => __( 'Image', 'echelon-so' ),
     148                    'label' => __( $label_card_image, 'echelon-so' ),
     149                    'description' => __( 'The image to use with image based Card templates.', 'echelon-so' ),
    126150                    'choose' => __( 'Choose Image', 'echelon-so' ),
    127151                    'update' => __( 'Set Image', 'echelon-so' ),
     
    137161                'image_size' => array(
    138162                    'type' => 'image-size',
    139                     'label' => __( 'Image Size', 'echelon-so' ),
     163                    'label' => __( $label_card_image_size, 'echelon-so' ),
     164                    'description' => __( 'The image size to use for the Cards image.', 'echelon-so' ),
    140165                    'state_handler' => array(
    141166                        'template[image_top]' => array( 'show' ),
     
    148173                    'type' => 'text',
    149174                    'default' => '',
    150                     'label' => __('Title', 'echelon-so'),
     175                    'label' => __('Title Text', 'echelon-so'),
     176                    'description' => __('The text to use for the Cards title.', 'echelon-so'),
    151177                ),
    152178                'sub_title' => array(
    153179                    'type' => 'text',
    154                     'default' => 'Sub Title',
    155                     'label' => __('Sub Title', 'echelon-so'),
     180                    'default' => '',
     181                    'label' => __('Sub Title Text', 'echelon-so'),
     182                    'description' => __('The text to use for the Cards sub title.', 'echelon-so'),
    156183                    'state_handler' => array(
    157184                        'template[sub_title]' => array( 'show' ),
     
    162189                    'type' => 'text',
    163190                    'default' => '',
    164                     'label' => __('Body', 'echelon-so'),
     191                    'label' => __('Body Text', 'echelon-so'),
     192                    'description' => __('The text to use for the main body of the Card.', 'echelon-so'),
    165193                ),
    166194                'link_text' => array(
     
    168196                    'default' => '',
    169197                    'label' => __('Link Text', 'echelon-so'),
     198                    'description' => __('The text to use for the card link, if any.', 'echelon-so'),
    170199                ),
    171200                'link_target' => array(
    172201                    'type' => 'link',
    173202                    'label' => __('Link Target', 'echelon-so'),
     203                    'description' => __('The destination URL for the card link, if any.', 'echelon-so'),
    174204                    'default' => ''
    175205                )
     
    198228                    'default' => 'uk-card-small',
    199229                    'label' => __('Size', 'echelon-so'),
    200                     'description' => __( 'Small cards use global Margin, Large cards use global Gutter Large.', 'echelon-so' ),
     230                    'description' => __( 'For padding Small cards use global Margin, Large cards use global Gutter Large.', 'echelon-so' ),
    201231                    'options' => array(
    202232                        'uk-card-small' => __('Small', 'echelon-so'),
     
    206236                'title_size' => array(
    207237                    'type' => 'select',
    208                     'default' => 'uk-text-large',
     238                    'default' => '0',
    209239                    'label' => __('Title Size', 'echelon-so'),
    210240                    'description' => $echelon_so_modifiers->font_size(true),
     
    257287                    'type' => 'select',
    258288                    'default' => '0',
    259                     'label' => __('Alignment', 'echelon-so'),
     289                    'label' => __('Text Alignment', 'echelon-so'),
    260290                    'description' => $echelon_so_modifiers->text_align(true),
    261291                    'options' => $echelon_so_modifiers->text_align()
     
    277307                    'type' => 'select',
    278308                    'default' => '0',
    279                     'label' => __('Image Transition', 'echelon-so'),
     309                    'label' => __( $label_image_transition, 'echelon-so' ),
     310                    'description' => __('The type of hover transition to use for the Card.', 'echelon-so'),
     311                    'description' => __('Add a hover transition to the cards image.', 'echelon-so'),
    280312                    'options' => array(
    281                         '0' => __('Default', 'echelon-so'),
     313                        '0' => __('-', 'echelon-so'),
    282314                        'scale' => __('Scale Up', 'echelon-so'),
    283315                        'two_scale' => __('Two Image Scale', 'echelon-so'),
     
    297329                'image_2' => array(
    298330                    'type' => 'media',
    299                     'label' => __( 'Image 2', 'echelon-so' ),
     331                    'label' => __( $label_two_image, 'echelon-so' ),
     332                    'description' => __( 'The second image to use with a two image transition.', 'echelon-so' ),
    300333                    'choose' => __( 'Choose Image', 'echelon-so' ),
    301334                    'update' => __( 'Set Image', 'echelon-so' ),
  • echelon-so/trunk/widgets/eso-counter/eso-counter.php

    r2172670 r2210468  
    55Author: Echelon
    66Author URI: https://echelonso.com
     7Documentation: https://echelonso.com/widgets/counter/
    78*/
    89
     
    1516            array(
    1617                'description' => __('Animate the count between two numbers.', 'echelon-so' ),
     18                'help' => 'https://echelonso.com/widgets/counter/'
    1719            ),
    1820            array(),
     
    4446        $return['grouping'] = 'false';
    4547
    46         // class
     48        // modifiers
    4749        $return['class'] = array();
    4850        (empty($instance['modifiers']['size'])) ?: $return['class'][] = $instance['modifiers']['size'];
     
    6264    function get_widget_form() {
    6365
    64         global $echelon_so_modifiers;
     66        global $echelon_so, $echelon_so_modifiers;
     67
     68        $option_use_grouping = 'Yes' . $echelon_so->prime_tag();
     69        $label_separator_character = 'Separator Character' . $echelon_so->prime_tag();
     70        $label_decimal_character = 'Decimal Character' . $echelon_so->prime_tag();
     71        $label_decimal_places = 'Decimal Places' . $echelon_so->prime_tag();
    6572
    6673        $return['counter'] = array(
     
    6976            'hide' => true,
    7077            'fields' => array(
    71                 'font' => array(
    72                     'type' => 'font',
    73                     'default' => 'default',
    74                     'label' => __('Font', 'echelon-so'),
    75                 ),
    7678                'start' => array(
    7779                    'type' => 'number',
    78                     'default' => 1,
    7980                    'label' => __( 'Start Number', 'echelon-so' ),
    80                     'description' => __( 'The number to count from.', 'echelon-so' ),
     81                    'description' => __( 'The number to count from. E.g 1', 'echelon-so' ),
    8182                ),
    8283                'end' => array(
    8384                    'type' => 'number',
    84                     'default' => 5000,
    8585                    'label' => __( 'End Number', 'echelon-so' ),
    86                     'description' => __( 'The number to count to.', 'echelon-so' ),
     86                    'description' => __( 'The number to count to. E.g 200', 'echelon-so' ),
    8787                ),
    8888                'duration' => array(
    8989                    'type' => 'number',
    90                     'default' => 2.5,
    9190                    'label' => __( 'Duration', 'echelon-so' ),
    92                     'description' => __( 'Duration of the effect in seconds.', 'echelon-so' ),
     91                    'description' => __( 'Duration of the count in seconds. E.g 2', 'echelon-so' ),
    9392                ),
    9493                'easing' => array(
     
    9897                    'description' => __( 'Slow the counter as it nears the final number.', 'echelon-so' ),
    9998                ),
     99                'use_grouping' => array(
     100                    'type' => 'select',
     101                    'default' => '0',
     102                    'label' => __( 'Use Grouping', 'echelon-so' ),
     103                    'options' => array(
     104                        '0' => __('No', 'echelon-so'),
     105                        '1' => __( $option_use_grouping, 'echelon-so'),
     106                    ),
     107                    'state_emitter' => array(
     108                        'callback' => 'select',
     109                        'args' => array( 'use_grouping' )
     110                    ),
     111                ),
     112                'separator' => array(
     113                    'type' => 'text',
     114                    'default' => '',
     115                    'label' => __( $label_separator_character, 'echelon-so' ),
     116                    'description' => __( 'When grouping numbers this character will be used to separate thousands. E.g , (comma)', 'echelon-so' ),
     117                    'state_handler' => array(
     118                        'use_grouping[1]' => array('show'),
     119                        'use_grouping[0]' => array('hide'),
     120                    ),
     121                ),
     122                'decimal' => array(
     123                    'type' => 'text',
     124                    'default' => '',
     125                    'label' => __( $label_decimal_character, 'echelon-so' ),
     126                    'description' => __( 'When grouping numbers this character will be used to separate decimals. E.g . (dot)', 'echelon-so' ),
     127                    'state_handler' => array(
     128                        'use_grouping[1]' => array('show'),
     129                        'use_grouping[0]' => array('hide'),
     130                    ),
     131                ),
     132                'decimal_places' => array(
     133                    'type' => 'number',
     134                    'label' => __( $label_decimal_places, 'echelon-so' ),
     135                    'description' => __( 'If using decimal values for the start and end numbers set the number of places here. E.g 2', 'echelon-so' ),
     136                    'state_handler' => array(
     137                        'use_grouping[1]' => array('show'),
     138                        'use_grouping[0]' => array('hide'),
     139                    ),
     140                ),
    100141                'offset' => array(
    101142                    'type' => 'number',
    102                     'default' => '350',
    103143                    'label' => __('Inview Offset', 'echelon-so'),
    104144                    'description' => __('How many pixels the counter needs to be in view before it is animated. Recommended values are 0 - 400.', 'echelon-so'),
     145                ),
     146                'font' => array(
     147                    'type' => 'font',
     148                    'default' => 'default',
     149                    'label' => __('Font', 'echelon-so'),
     150                    'description' => __('Use a Google Font for the counter.', 'echelon-so'),
    105151                )
    106152            )
     
    155201
    156202    function enqueue_widget_scripts($instance) {
    157         wp_enqueue_script( 'echelonso_countup_cdn_js', 'https://cdnjs.cloudflare.com/ajax/libs/countup.js/1.9.3/countUp.min.js', array('jquery'), '1.9.3', true );
     203        wp_enqueue_script( 'echelonso_countup_cdn_js', 'https://cdnjs.cloudflare.com/ajax/libs/countup.js/1.9.3/countUp.min.js', array('jquery'), '1.9.3', false );
    158204    }
    159205
  • echelon-so/trunk/widgets/eso-counter/tpl/default.php

    r2166476 r2210468  
    99
    1010    $(document).on('inview', '#<?php echo $int_id; ?>_spy', function() {
    11 
    1211        var options = {
    1312            useEasing: <?php echo $easing; ?>,
Note: See TracChangeset for help on using the changeset viewer.