Plugin Directory

Changeset 2873649


Ignore:
Timestamp:
03/02/2023 01:09:02 PM (3 years ago)
Author:
sendsmaily
Message:

Release 3.1.0, see readme.txt for the changelog.

Location:
smaily-for-wp
Files:
20 added
60 edited
1 copied

Legend:

Unmodified
Added
Removed
  • smaily-for-wp/tags/3.1.0/admin/class-smaily-for-wp-admin.php

    r2486965 r2873649  
    7979        // Load configuration data.
    8080        $has_credentials = $this->options->has_credentials();
    81         $form_options     = $this->options->get_form_options();
     81        $form_options    = $this->options->get_form_options();
    8282
    8383        // Create admin template.
     
    8787        add_menu_page( 'smaily', 'Smaily', 'manage_options', SMLY4WP_PLUGIN_PATH, '', SMLY4WP_PLUGIN_URL . '/gfx/icon.png' );
    8888        add_submenu_page( 'smaily', 'Newsletter subscription form', 'Form', 'manage_options', SMLY4WP_PLUGIN_PATH, array( $template, 'dispatch' ) );
     89    }
     90
     91    /**
     92     * Load newsletter subscription block.
     93     *
     94     * @since 3.1.0
     95     */
     96    public function smaily_subscription_block_init( $screen ) {
     97        if ( ! in_array( $screen, array( 'site-editor.php', 'post.php', 'page.php' ), true ) ) {
     98            return;
     99        }
     100
     101        $autoresponders = array(
     102            array(
     103                'label' => __( 'No autoresponder', 'smaily-for-wp' ),
     104                'value' => '',
     105            ),
     106        );
     107
     108        foreach ( $this->get_autoresponders() as $autoresponder_id => $title ) {
     109            $autoresponders[] = array(
     110                'label' => $title,
     111                'value' => (string) $autoresponder_id,
     112            );
     113        }
     114
     115        wp_enqueue_script(
     116            $this->plugin_name,
     117            SMLY4WP_PLUGIN_URL . '/blocks/index.js',
     118            array(),
     119            false,
     120            true
     121        );
     122
     123        wp_localize_script(
     124            $this->plugin_name,
     125            'autoresponders',
     126            json_encode( $autoresponders )
     127        );
    89128    }
    90129
     
    151190        if ( $refresh && $result['error'] === false ) {
    152191            $has_credentials   = $this->options->has_credentials();
    153             $form_options       = $this->options->get_form_options();
     192            $form_options      = $this->options->get_form_options();
    154193            $result['content'] = $this->generate_admin_template( 'form.php', $has_credentials, $form_options )->render();
    155194        }
     
    195234        $rqst = ( new Smaily_For_WP_Request() )
    196235            ->auth( $params['username'], $params['password'] )
    197             ->setUrl( 'https://' . $params['subdomain'] . '.sendsmaily.net/api/workflows.php?trigger_type=form_submitted' )
     236            ->set_url( 'https://' . $params['subdomain'] . '.sendsmaily.net/api/workflows.php?trigger_type=form_submitted' )
    198237            ->get();
    199238
     
    288327            // Render template.
    289328            $template = $this->generate_optin_template( 'basic.php', $subdomain );
    290             $form = $template->render();
     329            $form     = $template->render();
    291330        }
    292331
     
    392431
    393432        $result = ( new Smaily_For_WP_Request() )
    394             ->setUrl( 'https://' . $api_credentials['subdomain'] . '.sendsmaily.net/api/workflows.php?trigger_type=form_submitted' )
     433            ->set_url( 'https://' . $api_credentials['subdomain'] . '.sendsmaily.net/api/workflows.php?trigger_type=form_submitted' )
    395434            ->auth( $api_credentials['username'], $api_credentials['password'] )
    396435            ->get();
  • smaily-for-wp/tags/3.1.0/admin/css/smaily-for-wp-admin.css

    r2485930 r2873649  
    22 * All of the CSS used for the admin view.
    33 */
    4 .hidden {display:none}
     4.hidden {
     5    display: none;
     6}
    57
    6 .wrap h2 sup {color:#090}
     8.wrap h2 sup {
     9    color: #009900;
     10}
    711
    812/* form container styles */
    9 #form-container img, #form-container span {vertical-align:middle}
    10     #form-container .wrap {padding:5px 0; margin:0}
    11     #form-container .wrap label {font-weight:bold}
    12     #form-container .wrap em {display:block; font-style:normal; color:#999; padding-bottom:5px}
    13     #form-container .wrap input.input-text, #form-container .wrap select, #form-container .wrap textarea {width:100%}
     13#form-container img,
     14#form-container span {
     15    vertical-align: middle;
     16}
     17
     18#form-container .wrap {
     19    margin: 0;
     20    padding: 5px 0;
     21}
     22#form-container .wrap label {
     23    font-weight: bold;
     24}
     25#form-container .wrap em {
     26    color: #999999;
     27    display: block;
     28    font-style: normal;
     29    padding-bottom: 5px;
     30}
     31#form-container .wrap input.input-text,
     32#form-container .wrap select,
     33#form-container .wrap textarea {
     34    width: 100%;
     35}
    1436
    1537/* content tabs */
    16 .tab-content {padding:5px 4px 10px}
     38.tab-content {
     39    padding: 5px 4px 10px;
     40}
    1741
    18 .tabs {padding-top:10px}
    19 .tabs li {float:left; margin-right:2px}
    20 .tabs li a {background:#ccc; -moz-border-radius-topleft:5px; -moz-border-radius-topright:5px; padding:4px 6px; color:#999; text-decoration:none}
    21 .tabs li a.selected {background:#21759B; color:#fff}
     42.tabs {
     43    padding-top: 10px;
     44}
     45.tabs li {
     46    float: left;
     47    margin-right: 2px;
     48}
     49.tabs li a {
     50    -moz-border-radius-topleft: 5px;
     51    -moz-border-radius-topright: 5px;
     52    background: #cccccc;
     53    color: #999999;
     54    padding: 4px 6px;
     55    text-decoration: none;
     56}
     57.tabs li a.selected {
     58    background: #21759B;
     59    color: #fff;
     60}
  • smaily-for-wp/tags/3.1.0/admin/js/smaily-for-wp-admin.js

    r2485930 r2873649  
    1 var Default = (function(){
     1var Default = (function () {
    22    var _form = null;
    33
     
    66     * @return void
    77     */
    8     function _throwMessage(text, error){
     8    function _throwMessage(text, error) {
    99        // create message and insert to dom
    1010        var message = jQuery('<div></div>').attr({
     
    2222     * @return void|bool
    2323     */
    24     function _handleResponse(response){
    25         if(!response){ return false; }
    26 
    27         if(response.message){
     24    function _handleResponse(response) {
     25        if (!response) { return false; }
     26
     27        if (response.message) {
    2828            // remove previous messages
    2929            jQuery('#message').remove();
     
    3939     * @return String
    4040     */
    41     function _buildQuery(){
     41    function _buildQuery() {
    4242        var result = {};
    4343
    4444        // get serialized data and restructure
    4545        var data = jQuery('#form-container').serializeArray();
    46         for(var i in data){
     46        for (var i in data) {
    4747            var item = data[i];
    4848            result[item['name']] = item['value'];
     
    5656     * @return void
    5757     */
    58     function _request(data, callback){
     58    function _request(data, callback) {
    5959        // show loader
    6060        jQuery('#h2-loader').show();
     
    6565            smaily_for_wp.ajax_url,
    6666            {
    67                 'action' : 'smaily_admin_save',
    68                 'form_data' : jQuery.param(data)
     67                'action': 'smaily_admin_save',
     68                'form_data': jQuery.param(data)
    6969            },
    70             function(response) {
     70            function (response) {
    7171                // handle response
    7272                _handleResponse(response);
    7373
    7474                // execute callback function
    75                 if(typeof(callback) == 'function'){
     75                if (typeof (callback) == 'function') {
    7676                    callback(response);
    7777                }
     
    8787         * @return void
    8888         */
    89         validateApiKey: function(){
     89        validateApiKey: function () {
    9090            // build query
    9191            var query = _buildQuery();
     
    9494
    9595            // make the request
    96             _request(query, function(response){
    97                 if(response.content){
     96            _request(query, function (response) {
     97                if (response.content) {
    9898                    jQuery('#form-container').html(response.content);
    9999                }
     
    105105         * @return void
    106106         */
    107         removeApiKey: function(){
     107        removeApiKey: function () {
    108108            // build query
    109109            var query = {
     
    113113
    114114            // make the request
    115             _request(query, function(response){
    116                 if(response.content){
     115            _request(query, function (response) {
     116                if (response.content) {
    117117                    jQuery('#form-container').html(response.content);
    118118                }
     
    125125         * @return void
    126126         */
    127         resetForm: function(){
     127        resetForm: function () {
    128128            // build query
    129129            var query = {
     
    132132
    133133            // make the request
    134             _request(query, function(response){
     134            _request(query, function (response) {
    135135                // set textarea content
    136136                var content = response.content;
     
    143143         * @return void
    144144         */
    145         save: function(){
     145        save: function () {
    146146            // build query
    147147            var query = _buildQuery();
     
    158158 * @param {Object} args
    159159 */
    160 var Tabs = (function(args){
     160var Tabs = (function (args) {
    161161    // default options
    162162    var _options = {
     
    169169
    170170    // check required target
    171     if(!_options.target || _options.target.length < 1){ return false; }
     171    if (!_options.target || _options.target.length < 1) { return false; }
    172172
    173173    // bind click event to target tabs
    174     jQuery(_options.target+' a').click(function(){
     174    jQuery(_options.target + ' a').click(function () {
    175175        _select(this);
    176176    });
     
    178178    // use location hash to select tab
    179179    var hash = location.hash.length > 0 ? location.hash : '';
    180     if(hash.length > 0){
    181         var target = jQuery(_options.target+' a[href='+hash+']');
     180    if (hash.length > 0) {
     181        var target = jQuery(_options.target + ' a[href=' + hash + ']');
    182182        _select(target);
    183183    }
     
    187187     * @param {Object} element
    188188     */
    189     function _select(element){
    190         if(!element || element.length < 1){ return false; }
     189    function _select(element) {
     190        if (!element || element.length < 1) { return false; }
    191191        var href = jQuery(element).attr('href');
    192192        var hash = (href.length > 0 && /#/.test(href)) ? href.split('#')[1] : '';
    193193
    194194        // exit if does not have hash
    195         if(hash.length < 1){ return false; }
     195        if (hash.length < 1) { return false; }
    196196
    197197        // reset target tabs selected state
    198         jQuery(_options.target+' a').removeClass('selected');
     198        jQuery(_options.target + ' a').removeClass('selected');
    199199
    200200        // set this tab's state to selected
     
    203203        // hide tabs and make clicked tab contents visible
    204204        jQuery('*[id^=content\-]').addClass('hidden');
    205         jQuery('#content-'+hash).removeClass('hidden');
     205        jQuery('#content-' + hash).removeClass('hidden');
    206206    }
    207207});
  • smaily-for-wp/tags/3.1.0/admin/partials/smaily-for-wp-admin-form.php

    r2614685 r2873649  
    4646<?php if ( $this->has_credentials ) : ?>
    4747<ul class="tabs">
    48     <li><a id="link-basic" href="#basic"<?php if ( $this->form_options['is_advanced'] === false): ?> class="selected"<?php endif; ?>><?php echo esc_html__( 'Basic', 'smaily-for-wp' ); ?></a></li>
    49     <li><a id="link-advanced" href="#advanced"<?php if ( $this->form_options['is_advanced'] === true): ?> class="selected"<?php endif; ?>><?php echo esc_html__( 'Advanced', 'smaily-for-wp' ); ?></a></li>
     48    <li>
     49        <?php if ( $this->form_options['is_advanced'] === false ) : ?>
     50        <a id="link-basic" href="#basic" class="selected"><?php echo esc_html__( 'Basic', 'smaily-for-wp' ); ?></a>
     51        <?php else : ?>
     52        <a id="link-basic" href="#basic"><?php echo esc_html__( 'Basic', 'smaily-for-wp' ); ?></a>
     53        <?php endif; ?>
     54    </li>
     55    <li>
     56        <?php if ( $this->form_options['is_advanced'] === true ) : ?>
     57        <a id="link-advanced" href="#advanced" class="selected"><?php echo esc_html__( 'Advanced', 'smaily-for-wp' ); ?></a>
     58        <?php else : ?>
     59        <a id="link-advanced" href="#advanced"><?php echo esc_html__( 'Advanced', 'smaily-for-wp' ); ?></a>
     60        <?php endif; ?>
     61    </li>
    5062</ul>
    5163<div class="clear"></div>
    5264
    53 <div id="content-advanced" class="tab-content<?php if ( $this->form_options['is_advanced'] === false): ?> hidden<?php endif; ?>">
     65    <?php if ( $this->form_options['is_advanced'] === false ) : ?>
     66<div id="content-advanced" class="tab-content hidden">
     67<?php else : ?>
     68<div id="content-advanced" class="tab-content">
     69<?php endif; ?>">
    5470    <div class="wrap">
    5571        <label><?php echo esc_html__( 'Newsletter subscription form', 'smaily-for-wp' ); ?> <a href="#" onclick="javascript:Default.resetForm();return false;" title="<?php echo esc_html__( 'Restore original subscription form', 'smaily-for-wp' ); ?>">(<?php echo esc_html__( 'Regenerate', 'smaily-for-wp' ); ?>)</a></label>
     
    6783
    6884<script type="text/javascript">//<![CDATA[
    69   new Tabs({'target':'ul.tabs'});
    70   jQuery('#link-basic').click(function(){
    71       jQuery('input[name=is_advanced]').val('0');
    72   });
    73   jQuery('#link-advanced').click(function(){
    74       jQuery('input[name=is_advanced]').val('1');
    75   });
     85    new Tabs({'target':'ul.tabs'});
     86    jQuery('#link-basic').click(function(){
     87        jQuery('input[name=is_advanced]').val('0');
     88    });
     89    jQuery('#link-advanced').click(function(){
     90        jQuery('input[name=is_advanced]').val('1');
     91    });
    7692//]]></script>
  • smaily-for-wp/tags/3.1.0/admin/partials/smaily-for-wp-admin-page.php

    r2485930 r2873649  
    66
    77    <form id="form-container" action="<?php echo esc_url( admin_url( 'admin-ajax.php' ) ); ?>" method="post">
    8         <?php echo $this->partial( 'admin/partials/smaily-for-wp-admin-form.php', $this->getVars() ); ?>
     8        <?php echo $this->partial( 'admin/partials/smaily-for-wp-admin-form.php', $this->get_vars() ); ?>
    99    </form>
    1010</div>
  • smaily-for-wp/tags/3.1.0/includes/class-smaily-for-wp-i18n.php

    r2485930 r2873649  
    11<?php
     2
    23/**
    34 * Define the internationalization functionality.
     
    78 * @subpackage Smaily_For_WP/includes
    89 */
    9 class Smaily_For_WP_i18n {
     10
     11class Smaily_For_WP_I18n {
    1012
    1113    /**
  • smaily-for-wp/tags/3.1.0/includes/class-smaily-for-wp-lifecycle.php

    r2575319 r2873649  
    11<?php
     2
    23/**
    34 * Define all the logic related to plugin activation, upgrade and uninstall logic.
     
    78 * @subpackage Smaily_For_WP/includes
    89 */
     10
    911class Smaily_For_WP_Lifecycle {
    1012
  • smaily-for-wp/tags/3.1.0/includes/class-smaily-for-wp-loader.php

    r2485930 r2873649  
    11<?php
     2
    23/**
    34 * Register all actions and filters for the plugin.
     
    1112 * @subpackage Smaily_For_WP/includes
    1213 */
     14
    1315class Smaily_For_WP_Loader {
    1416
     
    8991            'callback'      => $callback,
    9092            'priority'      => $priority,
    91             'accepted_args' => $accepted_args
     93            'accepted_args' => $accepted_args,
    9294        );
    9395
  • smaily-for-wp/tags/3.1.0/includes/class-smaily-for-wp-options.php

    r2485930 r2873649  
    11<?php
     2
    23/**
    34 * This class is used to work with the plugin's options
     
    89 * @subpackage Smaily_For_WP/includes
    910 */
     11
    1012class Smaily_For_WP_Options {
    1113
     
    115117        if ( is_array( $form_options ) ) {
    116118            $this->form_options = array(
    117                 'form' => isset( $form_options['form'] ) ? esc_textarea( $form_options['form'] ) : '',
     119                'form'        => isset( $form_options['form'] ) ? esc_textarea( $form_options['form'] ) : '',
    118120                'is_advanced' => isset( $form_options['form'] ) ? (bool) $form_options['is_advanced'] : false,
    119121            );
  • smaily-for-wp/tags/3.1.0/includes/class-smaily-for-wp-request.php

    r2485930 r2873649  
    11<?php
     2
    23/**
    34 * Defines the request making functionality of the plugin.
     
    78 * @subpackage Smaily_For_WP/includes
    89 */
     10
    911class Smaily_For_WP_Request {
    1012
     
    6668     * @return Smaily_For_WP_Request For method chaining.
    6769     */
    68     public function setUrl( $url ) {
     70    public function set_url( $url ) {
    6971        $this->_url = $url;
    7072        return $this;
     
    7880     * @return Smaily_For_WP_Request For method chaining.
    7981     */
    80     public function setData( array $data ) {
     82    public function set_data( array $data ) {
    8183        $this->_data = $data;
    8284        return $this;
     
    9395        $useragent = 'smaily-for-wp/' . SMLY4WP_PLUGIN_VERSION . ' (WordPress/' . get_bloginfo( 'version' ) . '; +' . get_bloginfo( 'url' ) . ')';
    9496        $args      = array(
    95             'headers' => array(
     97            'headers'    => array(
    9698                'Authorization' => 'Basic ' . base64_encode( $this->_username . ':' . $this->_password ),
    9799            ),
  • smaily-for-wp/tags/3.1.0/includes/class-smaily-for-wp-template.php

    r2485930 r2873649  
    11<?php
     2
    23/**
    34 * Defines the template generating and rendering functionality of the plugin.
     
    78 * @subpackage Smaily_For_WP/includes
    89 */
     10
    911class Smaily_For_WP_Template {
    1012
     
    108110     * @return string $lang Language code.
    109111     */
    110     private function getLanguageCode() {
     112    private function get_language_code() {
    111113        // Language code if using WPML.
    112114        $lang = '';
     
    132134     * @return array
    133135     */
    134     public function getVars() {
     136    public function get_vars() {
    135137        return $this->_vars;
    136138    }
  • smaily-for-wp/tags/3.1.0/includes/class-smaily-for-wp-widget.php

    r2625099 r2873649  
    11<?php
     2
    23/**
    34 * Defines the widget functionality of the plugin.
     
    78 * @subpackage Smaily/includes
    89 */
     10
    911class Smaily_For_WP_Widget extends WP_Widget {
    1012
     
    7072        $file     = $form_options['is_advanced'] === true ? 'advanced.php' : 'basic.php';
    7173        $template = new Smaily_For_WP_Template( 'public/partials/smaily-for-wp-public-' . $file );
    72         $template->assign( array(
    73             'domain'           => $api_credentials['subdomain'],
    74             'form'             => $form_options['form'],
    75             'is_advanced'      => $form_options['is_advanced'],
    76             'show_name'        => $show_name,
    77             'success_url'      => $success_url,
    78             'failure_url'      => $failure_url,
    79             'autoresponder_id' => $autoresponder,
    80         ) );
     74        $template->assign(
     75            array(
     76                'domain'           => $api_credentials['subdomain'],
     77                'form'             => $form_options['form'],
     78                'is_advanced'      => $form_options['is_advanced'],
     79                'show_name'        => $show_name,
     80                'success_url'      => $success_url,
     81                'failure_url'      => $failure_url,
     82                'autoresponder_id' => $autoresponder,
     83            )
     84        );
    8185
    8286        // Display responses on Smaily subscription form.
     
    129133     */
    130134    public function update( $new_instance, $old_instance ) {
    131         $instance                = $old_instance;
    132         $instance['title']       = sanitize_text_field( $new_instance['title'] );
    133         $instance['show_name']   = isset( $new_instance['show_name'] ) ? (bool) $new_instance['show_name'] : false;
    134         $instance['success_url'] = esc_url_raw( $new_instance['success_url'] );
    135         $instance['failure_url'] = esc_url_raw( $new_instance['failure_url'] );
     135        $instance                  = $old_instance;
     136        $instance['title']         = sanitize_text_field( $new_instance['title'] );
     137        $instance['show_name']     = isset( $new_instance['show_name'] ) ? (bool) $new_instance['show_name'] : false;
     138        $instance['success_url']   = esc_url_raw( $new_instance['success_url'] );
     139        $instance['failure_url']   = esc_url_raw( $new_instance['failure_url'] );
    136140        $instance['autoresponder'] = sanitize_text_field( $new_instance['autoresponder'] );
    137141
     
    174178            <label for="' . $show_name_id . '">' . __( 'Display name field?', 'smaily-for-wp' ) . '</label>' .
    175179        '</p>';
     180
    176181        // Display inputs for success/failure URLs.
    177182        $success_url_id          = esc_attr( $this->get_field_id( 'success_url' ) );
     
    190195            <input id="' . $failure_url_id . '" name="' . $failure_url . '" type="text" value="' . $instance['failure_url'] . '" />
    191196        </p>';
     197
    192198        // Display autoresponder select menu.
    193199        $autoresponder_id          = esc_attr( $this->get_field_id( 'autoresponder' ) );
  • smaily-for-wp/tags/3.1.0/includes/class-smaily-for-wp.php

    r2486913 r2873649  
    11<?php
     2
    23/**
    34 * The core plugin class.
     
    1314 * @subpackage Smaily_For_WP/includes
    1415 */
     16
    1517class Smaily_For_WP {
    1618
     
    6264     */
    6365    public function __construct() {
    64         $this->version = SMLY4WP_PLUGIN_VERSION;
     66        $this->version     = SMLY4WP_PLUGIN_VERSION;
    6567        $this->plugin_name = 'smaily-for-wp';
    6668        $this->load_dependencies();
    6769        $this->set_locale();
    6870        $this->define_lifecycle_hooks();
     71        $this->init_blocks();
    6972        $this->define_admin_hooks();
    7073        $this->define_public_hooks();
     
    9497    private function load_dependencies() {
    9598        require_once SMLY4WP_PLUGIN_PATH . 'admin/class-smaily-for-wp-admin.php';
     99        require_once SMLY4WP_PLUGIN_PATH . 'includes/class-smaily-for-wp-block.php';
    96100        require_once SMLY4WP_PLUGIN_PATH . 'includes/class-smaily-for-wp-i18n.php';
    97101        require_once SMLY4WP_PLUGIN_PATH . 'includes/class-smaily-for-wp-lifecycle.php';
     
    109113     * Define the locale for this plugin for internationalization.
    110114     *
    111      * Uses the Smaily_For_WP_i18n class in order to set the domain and to register the hook
     115     * Uses the Smaily_For_WP_I18n class in order to set the domain and to register the hook
    112116     * with WordPress.
    113117     *
     
    116120     */
    117121    private function set_locale() {
    118         $plugin_i18n = new Smaily_For_WP_i18n();
     122        $plugin_i18n = new Smaily_For_WP_I18n();
    119123        $this->loader->add_action( 'plugins_loaded', $plugin_i18n, 'load_plugin_textdomain' );
     124    }
     125
     126    /**
     127     * Initialize Gutenberg blocks.
     128     *
     129     * @since 3.1.0
     130     * @access private
     131     */
     132    private function init_blocks() {
     133        $plugin_block = new Smaily_For_WP_Block( $this->options, $this->get_plugin_name(), $this->get_version() );
     134
     135        register_block_type(
     136            SMLY4WP_PLUGIN_PATH . '/blocks',
     137            array(
     138                'render_callback' => array( $plugin_block, 'render' ),
     139            )
     140        );
    120141    }
    121142
     
    148169        $this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'enqueue_styles' );
    149170        $this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'enqueue_scripts' );
     171        $this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'smaily_subscription_block_init' );
    150172        $this->loader->add_action( 'wp_ajax_smaily_admin_save', $plugin_admin, 'smaily_admin_save' );
    151173        $this->loader->add_action( 'widgets_init', $plugin_admin, 'smaily_subscription_widget_init' );
  • smaily-for-wp/tags/3.1.0/lang/smaily-for-wp-et.po

    r2575319 r2873649  
    22msgstr ""
    33"Project-Id-Version: Smaily for WP\n"
    4 "POT-Creation-Date: 2021-07-30 11:07+0300\n"
    5 "PO-Revision-Date: 2021-07-30 11:07+0300\n"
     4"POT-Creation-Date: 2023-03-02 15:00+0200\n"
     5"PO-Revision-Date: 2023-03-02 15:00+0200\n"
    66"Last-Translator: Smaily <[email protected]>\n"
    77"Language-Team: Smaily <[email protected]>\n"
     
    1010"Content-Type: text/plain; charset=UTF-8\n"
    1111"Content-Transfer-Encoding: 8bit\n"
    12 "X-Generator: Poedit 2.3\n"
     12"Plural-Forms: nplurals=2; plural=(n != 1);\n"
     13"X-Generator: Poedit 3.2.2\n"
    1314"X-Poedit-Basepath: ..\n"
    14 "Plural-Forms: nplurals=2; plural=(n != 1);\n"
    1515"X-Poedit-KeywordsList: __;_e;_n:1,2;_n_noop:1,2;_x:1,2c;_nx:4c,1,2;"
    1616"_nx_noop:4c,1,2;_ex:1,2c;esc_attr__;esc_attr_e;esc_attr_x:1,2c;esc_html__;"
     
    1818"X-Poedit-SearchPath-0: .\n"
    1919
    20 #: admin/class-smaily-for-wp-admin.php:182
     20#: admin/class-smaily-for-wp-admin.php:103
     21#: includes/class-smaily-for-wp-widget.php:205
     22msgid "No autoresponder"
     23msgstr "Ilma automaatvastajata vorm"
     24
     25#: admin/class-smaily-for-wp-admin.php:221
    2126msgid "Please enter subdomain!"
    2227msgstr "Palun sisesta alamdomeen!"
    2328
    24 #: admin/class-smaily-for-wp-admin.php:186
     29#: admin/class-smaily-for-wp-admin.php:225
    2530msgid "Please enter username!"
    2631msgstr "Palun sisesta kasutajatunnus!"
    2732
    28 #: admin/class-smaily-for-wp-admin.php:190
     33#: admin/class-smaily-for-wp-admin.php:229
    2934msgid "Please enter password!"
    3035msgstr "Palun sisesta parool!"
    3136
    32 #: admin/class-smaily-for-wp-admin.php:206
     37#: admin/class-smaily-for-wp-admin.php:245
    3338msgid "Wrong credentials"
    3439msgstr "Valed autentimise tunnused"
    3540
    36 #: admin/class-smaily-for-wp-admin.php:211
     41#: admin/class-smaily-for-wp-admin.php:250
    3742msgid "Error in subdomain"
    3843msgstr "Viga alamdomeenis"
    3944
    40 #: admin/class-smaily-for-wp-admin.php:221
     45#: admin/class-smaily-for-wp-admin.php:260
    4146msgid "Something went wrong with request to Smaily"
    4247msgstr "Ilmnes probleem Smaily-ga ühendamisel"
    4348
    44 #: admin/class-smaily-for-wp-admin.php:230
     49#: admin/class-smaily-for-wp-admin.php:269
    4550msgid "Credentials validated."
    4651msgstr "Autentimise tunnused valideeritud."
    4752
    48 #: admin/class-smaily-for-wp-admin.php:247
     53#: admin/class-smaily-for-wp-admin.php:286
    4954msgid "Credentials removed."
    5055msgstr "Autentimise tunnused eemaldatud."
    5156
    52 #: admin/class-smaily-for-wp-admin.php:264
     57#: admin/class-smaily-for-wp-admin.php:303
    5358msgid "Newsletter subscription form reset to default."
    5459msgstr "Liitumisvormi kood taasloodud."
    5560
    56 #: admin/class-smaily-for-wp-admin.php:303
     61#: admin/class-smaily-for-wp-admin.php:342
    5762msgid "Changes saved."
    5863msgstr "Salvestatud."
     
    8691msgstr "Kontrolli"
    8792
    88 #: admin/partials/smaily-for-wp-admin-form.php:48
     93#: admin/partials/smaily-for-wp-admin-form.php:50
     94#: admin/partials/smaily-for-wp-admin-form.php:52
    8995msgid "Basic"
    9096msgstr "Tavaseaded"
    9197
    92 #: admin/partials/smaily-for-wp-admin-form.php:49
     98#: admin/partials/smaily-for-wp-admin-form.php:57
     99#: admin/partials/smaily-for-wp-admin-form.php:59
    93100msgid "Advanced"
    94101msgstr "Spetsialisti seaded"
    95102
    96 #: admin/partials/smaily-for-wp-admin-form.php:55
     103#: admin/partials/smaily-for-wp-admin-form.php:71
    97104msgid "Newsletter subscription form"
    98105msgstr "Uudiskirja liitumisvorm"
    99106
    100 #: admin/partials/smaily-for-wp-admin-form.php:55
     107#: admin/partials/smaily-for-wp-admin-form.php:71
    101108msgid "Restore original subscription form"
    102109msgstr "Taasta algne liitumisvorm"
    103110
    104 #: admin/partials/smaily-for-wp-admin-form.php:55
     111#: admin/partials/smaily-for-wp-admin-form.php:71
    105112msgid "Regenerate"
    106113msgstr "Taastekita"
    107114
    108 #: admin/partials/smaily-for-wp-admin-form.php:56
     115#: admin/partials/smaily-for-wp-admin-form.php:72
    109116msgid "HTML of subscription form"
    110117msgstr "Liitumisvormi HTML"
    111118
    112 #: admin/partials/smaily-for-wp-admin-form.php:61
     119#: admin/partials/smaily-for-wp-admin-form.php:77
    113120msgid "Note: When you save under Basic tab, default form will be used."
    114121msgstr ""
    115122"Hoiatus: Kui salvestad Tavaseadete vaates, kasutatakse lehel vaikimisi vormi."
    116123
    117 #: admin/partials/smaily-for-wp-admin-form.php:64
     124#: admin/partials/smaily-for-wp-admin-form.php:80
    118125msgid "Save changes"
    119126msgstr "Salvesta muudatused"
     
    127134msgstr "Palun oota..."
    128135
    129 #: includes/class-smaily-for-wp-widget.php:37
     136#: blocks/index.js:221
     137#, fuzzy
     138#| msgid "Email"
     139msgid "E-mail"
     140msgstr "E-post"
     141
     142#: blocks/index.js:221
     143#, fuzzy
     144#| msgid "Email"
     145msgid "Smaily"
     146msgstr "E-post"
     147
     148#: blocks/index.js:225 includes/class-smaily-for-wp-widget.php:40
     149msgid "Smaily Newsletter Subscription"
     150msgstr "Smaily uudiskirjaga liitumine"
     151
     152#: includes/class-smaily-for-wp-widget.php:39
    130153msgid "Smaily newsletter subscription form"
    131154msgstr "Smaily uudiskirjaga liitumise vorm"
    132155
    133 #: includes/class-smaily-for-wp-widget.php:38
    134 msgid "Smaily Newsletter Subscription"
    135 msgstr "Smaily uudiskirjaga liitumine"
    136 
    137 #: includes/class-smaily-for-wp-widget.php:89
    138 #: public/class-smaily-for-wp-public.php:104
     156#: includes/class-smaily-for-wp-widget.php:93
     157#: public/class-smaily-for-wp-public.php:106
    139158msgid "Smaily credentials not validated. Subscription form will not work!"
    140159msgstr "Smaily kasutajatunnused on valideerimata.  Uudiskirja vorm ei tööta!"
    141160
    142 #: includes/class-smaily-for-wp-widget.php:96
    143 #: public/class-smaily-for-wp-public.php:111
     161#: includes/class-smaily-for-wp-widget.php:100
     162#: public/class-smaily-for-wp-public.php:113
    144163msgid "Form was not submitted using POST method."
    145164msgstr "Andmeid peab saatma POST tegevusviisiga."
    146165
    147 #: includes/class-smaily-for-wp-widget.php:99
    148 #: public/class-smaily-for-wp-public.php:114
     166#: includes/class-smaily-for-wp-widget.php:103
     167#: public/class-smaily-for-wp-public.php:116
    149168msgid "Input does not contain a recognizable email address."
    150169msgstr "Sisend ei sisalda tuntavat emaili aadressi."
    151170
    152 #: includes/class-smaily-for-wp-widget.php:102
    153 #: public/class-smaily-for-wp-public.php:117
     171#: includes/class-smaily-for-wp-widget.php:106
     172#: public/class-smaily-for-wp-public.php:119
    154173msgid ""
    155174"Could not add to subscriber list for an unknown reason. Probably something "
     
    159178"probleem Smaily-s."
    160179
    161 #: includes/class-smaily-for-wp-widget.php:164
     180#: includes/class-smaily-for-wp-widget.php:168
    162181msgid "Title"
    163182msgstr "Pealkiri"
    164183
    165 #: includes/class-smaily-for-wp-widget.php:174
     184#: includes/class-smaily-for-wp-widget.php:178
    166185msgid "Display name field?"
    167186msgstr "Näita nime välja?"
    168187
    169 #: includes/class-smaily-for-wp-widget.php:181
     188#: includes/class-smaily-for-wp-widget.php:186
    170189msgid "Success URL"
    171190msgstr "Õnnestumise URL"
    172191
    173 #: includes/class-smaily-for-wp-widget.php:189
     192#: includes/class-smaily-for-wp-widget.php:194
    174193msgid "Failure URL"
    175194msgstr "Ebaõnnestumise URL"
    176195
    177 #: includes/class-smaily-for-wp-widget.php:197
     196#: includes/class-smaily-for-wp-widget.php:203
    178197msgid "Autoresponders"
    179198msgstr "Automaatvastajad"
    180 
    181 #: includes/class-smaily-for-wp-widget.php:199
    182 msgid "No autoresponder"
    183 msgstr "Ilma automaatvastajata vorm"
    184199
    185200#: public/partials/smaily-for-wp-public-basic.php:3
  • smaily-for-wp/tags/3.1.0/migrations/upgrade-3-0-0.php

    r2575319 r2873649  
    11<?php
     2
    23/**
    34 * Apply any database upgrades required for 3.0.0.
     
    1112 * @since 3.0.0
    1213 */
     14
    1315$upgrade = function() {
    1416    global $wpdb;
    15     $table_name = $wpdb->prefix . 'smaily_config';
    1617
    17     if ( $wpdb->get_var( "SHOW TABLES LIKE '$table_name'" ) === $table_name ) {
    18         $config = $wpdb->get_row( "SELECT * FROM `$table_name` LIMIT 1", ARRAY_A );
     18    if ( $wpdb->get_var( "SHOW TABLES LIKE {$wpdb->prefix}smaily_config" ) === $wpdb->prefix . 'smaily_config' ) {
     19        $config = $wpdb->get_row( "SELECT * FROM {$wpdb->prefix}smaily_config LIMIT 1", ARRAY_A );
    1920        // Get saved autoresponder ID.
    2021        $autoresponder_id = isset( $config['autoresponder'] ) ? $config['autoresponder'] : '';
  • smaily-for-wp/tags/3.1.0/public/class-smaily-for-wp-public.php

    r2493245 r2873649  
    11<?php
     2
    23/**
    34 * The public-facing functionality of the plugin.
     
    78 * @subpackage Smaily_For_WP/public
    89 */
     10
    911class Smaily_For_WP_Public {
    1012
     
    7678
    7779        // Parse attributes out of shortcode tag.
    78         $shortcode_atts = shortcode_atts(
     80        $shortcode_atts             = shortcode_atts(
    7981            array(
    8082                'success_url'      => get_site_url(),
  • smaily-for-wp/tags/3.1.0/public/partials/smaily-for-wp-public-advanced.php

    r2485930 r2873649  
    1 <?php echo html_entity_decode( $this->form ); ?>
     1<?php echo html_entity_decode( $this->form );
  • smaily-for-wp/tags/3.1.0/public/partials/smaily-for-wp-public-basic.php

    r2485930 r2873649  
    22    <p class="error" style="padding:15px;background-color:#f2dede;margin:0 0 10px;display:<?php echo $this->form_has_response ? 'block' : 'none'; ?>"><?php echo esc_html( $this->response_message ); ?></p>
    33    <p class="success" style="padding:15px;background-color:#dff0d8;margin:0 0 10px;display:<?php echo $this->form_is_successful ? 'block' : 'none'; ?>"><?php echo esc_html__( 'Thank you for subscribing to our newsletter.', 'smaily-for-wp' ); ?></p>
    4     <?php if ( $this->autoresponder_id ): ?>
     4    <?php if ( $this->autoresponder_id ) : ?>
    55        <input type="hidden" name="autoresponder" value="<?php echo $this->autoresponder_id; ?>" />
    66    <?php endif; ?>
    7     <input type="hidden" name="lang" value="<?php echo esc_html( $this->getLanguageCode() ); ?>" />
     7    <input type="hidden" name="lang" value="<?php echo esc_html( $this->get_language_code() ); ?>" />
    88    <input type="hidden" name="success_url" value="<?php echo $this->success_url ? $this->success_url : get_site_url(); ?>" />
    99    <input type="hidden" name="failure_url" value="<?php echo $this->failure_url ? $this->failure_url : get_site_url(); ?>" />
  • smaily-for-wp/tags/3.1.0/readme.txt

    r2625099 r2873649  
    44Requires PHP: 5.6
    55Requires at least: 4.0
    6 Stable tag: 3.0.7
     6Stable tag: 3.1.0
    77Tags: widget, plugin, sidebar, api, mail, email, marketing, smaily
    8 Tested up to: 5.8.0
     8Tested up to: 6.1.1
    99
    1010Smaily newsletter subscription plugin for WordPress
     
    7777== Changelog ==
    7878
     79= 3.1.0 =
     80- Basic Gutenberg blocks support
     81
    7982= 3.0.7 =
    8083- Fix automation workflows being fetched on every operation in WordPress.
  • smaily-for-wp/tags/3.1.0/smaily-for-wp.php

    r2625099 r2873649  
    1010 * Text Domain:       smaily-for-wp
    1111 * Description:       Smaily newsletter subscription form.
    12  * Version:           3.0.7
     12 * Version:           3.1.0
    1313 * Author:            Sendsmaily LLC
    1414 * Author URI:        https://smaily.com
     
    2525 * Current plugin version.
    2626 */
    27 define( 'SMLY4WP_PLUGIN_VERSION', '3.0.7' );
     27define( 'SMLY4WP_PLUGIN_VERSION', '3.1.0' );
    2828
    2929/**
  • smaily-for-wp/tags/3.1.0/vendor/autoload.php

    r2625099 r2873649  
    33// autoload.php @generated by Composer
    44
     5if (PHP_VERSION_ID < 50600) {
     6    if (!headers_sent()) {
     7        header('HTTP/1.1 500 Internal Server Error');
     8    }
     9    $err = 'Composer 2.3.0 dropped support for autoloading on PHP <5.6 and you are running '.PHP_VERSION.', please upgrade PHP or use Composer 2.2 LTS via "composer self-update --2.2". Aborting.'.PHP_EOL;
     10    if (!ini_get('display_errors')) {
     11        if (PHP_SAPI === 'cli' || PHP_SAPI === 'phpdbg') {
     12            fwrite(STDERR, $err);
     13        } elseif (!headers_sent()) {
     14            echo $err;
     15        }
     16    }
     17    trigger_error(
     18        $err,
     19        E_USER_ERROR
     20    );
     21}
     22
    523require_once __DIR__ . '/composer/autoload_real.php';
    624
    7 return ComposerAutoloaderInit88c0474316a09b223d787fb04022e877::getLoader();
     25return ComposerAutoloaderInit814b5d616008b0576aeb0740be7b0990::getLoader();
  • smaily-for-wp/tags/3.1.0/vendor/composer/ClassLoader.php

    r2614685 r2873649  
    4343class ClassLoader
    4444{
     45    /** @var \Closure(string):void */
     46    private static $includeFile;
     47
    4548    /** @var ?string */
    4649    private $vendorDir;
     
    107110    {
    108111        $this->vendorDir = $vendorDir;
     112        self::initializeIncludeClosure();
    109113    }
    110114
     
    150154    /**
    151155     * @return string[] Array of classname => path
    152      * @psalm-var array<string, string>
     156     * @psalm-return array<string, string>
    153157     */
    154158    public function getClassMap()
     
    426430    {
    427431        if ($file = $this->findFile($class)) {
    428             includeFile($file);
     432            $includeFile = self::$includeFile;
     433            $includeFile($file);
    429434
    430435            return true;
     
    556561        return false;
    557562    }
     563
     564    /**
     565     * @return void
     566     */
     567    private static function initializeIncludeClosure()
     568    {
     569        if (self::$includeFile !== null) {
     570            return;
     571        }
     572
     573        /**
     574         * Scope isolated include.
     575         *
     576         * Prevents access to $this/self from included files.
     577         *
     578         * @param  string $file
     579         * @return void
     580         */
     581        self::$includeFile = \Closure::bind(static function($file) {
     582            include $file;
     583        }, null, null);
     584    }
    558585}
    559 
    560 /**
    561  * Scope isolated include.
    562  *
    563  * Prevents access to $this/self from included files.
    564  *
    565  * @param  string $file
    566  * @return void
    567  * @private
    568  */
    569 function includeFile($file)
    570 {
    571     include $file;
    572 }
  • smaily-for-wp/tags/3.1.0/vendor/composer/InstalledVersions.php

    r2625099 r2873649  
    2222 *
    2323 * To require its presence, you can require `composer-runtime-api ^2.0`
     24 *
     25 * @final
    2426 */
    2527class InstalledVersions
     
    2729    /**
    2830     * @var mixed[]|null
    29      * @psalm-var array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>}|array{}|null
     31     * @psalm-var array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}|array{}|null
    3032     */
    3133    private static $installed;
     
    3840    /**
    3941     * @var array[]
    40      * @psalm-var array<string, array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>}>
     42     * @psalm-var array<string, array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}>
    4143     */
    4244    private static $installedByVendor = array();
     
    242244    /**
    243245     * @return array
    244      * @psalm-return array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}
     246     * @psalm-return array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}
    245247     */
    246248    public static function getRootPackage()
     
    256258     * @deprecated Use getAllRawData() instead which returns all datasets for all autoloaders present in the process. getRawData only returns the first dataset loaded, which may not be what you expect.
    257259     * @return array[]
    258      * @psalm-return array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>}
     260     * @psalm-return array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}
    259261     */
    260262    public static function getRawData()
     
    279281     *
    280282     * @return array[]
    281      * @psalm-return list<array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>}>
     283     * @psalm-return list<array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}>
    282284     */
    283285    public static function getAllRawData()
     
    302304     * @return void
    303305     *
    304      * @psalm-param array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>} $data
     306     * @psalm-param array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>} $data
    305307     */
    306308    public static function reload($data)
     
    312314    /**
    313315     * @return array[]
    314      * @psalm-return list<array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>}>
     316     * @psalm-return list<array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}>
    315317     */
    316318    private static function getInstalled()
  • smaily-for-wp/tags/3.1.0/vendor/composer/autoload_classmap.php

    r2575319 r2873649  
    33// autoload_classmap.php @generated by Composer
    44
    5 $vendorDir = dirname(dirname(__FILE__));
     5$vendorDir = dirname(__DIR__);
    66$baseDir = dirname($vendorDir);
    77
  • smaily-for-wp/tags/3.1.0/vendor/composer/autoload_namespaces.php

    r2575319 r2873649  
    33// autoload_namespaces.php @generated by Composer
    44
    5 $vendorDir = dirname(dirname(__FILE__));
     5$vendorDir = dirname(__DIR__);
    66$baseDir = dirname($vendorDir);
    77
  • smaily-for-wp/tags/3.1.0/vendor/composer/autoload_psr4.php

    r2575319 r2873649  
    33// autoload_psr4.php @generated by Composer
    44
    5 $vendorDir = dirname(dirname(__FILE__));
     5$vendorDir = dirname(__DIR__);
    66$baseDir = dirname($vendorDir);
    77
  • smaily-for-wp/tags/3.1.0/vendor/composer/autoload_real.php

    r2625099 r2873649  
    33// autoload_real.php @generated by Composer
    44
    5 class ComposerAutoloaderInit88c0474316a09b223d787fb04022e877
     5class ComposerAutoloaderInit814b5d616008b0576aeb0740be7b0990
    66{
    77    private static $loader;
     
    2323        }
    2424
    25         spl_autoload_register(array('ComposerAutoloaderInit88c0474316a09b223d787fb04022e877', 'loadClassLoader'), true, true);
    26         self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(\dirname(__FILE__)));
    27         spl_autoload_unregister(array('ComposerAutoloaderInit88c0474316a09b223d787fb04022e877', 'loadClassLoader'));
     25        spl_autoload_register(array('ComposerAutoloaderInit814b5d616008b0576aeb0740be7b0990', 'loadClassLoader'), true, true);
     26        self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__));
     27        spl_autoload_unregister(array('ComposerAutoloaderInit814b5d616008b0576aeb0740be7b0990', 'loadClassLoader'));
    2828
    29         $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
    30         if ($useStaticLoader) {
    31             require __DIR__ . '/autoload_static.php';
    32 
    33             call_user_func(\Composer\Autoload\ComposerStaticInit88c0474316a09b223d787fb04022e877::getInitializer($loader));
    34         } else {
    35             $map = require __DIR__ . '/autoload_namespaces.php';
    36             foreach ($map as $namespace => $path) {
    37                 $loader->set($namespace, $path);
    38             }
    39 
    40             $map = require __DIR__ . '/autoload_psr4.php';
    41             foreach ($map as $namespace => $path) {
    42                 $loader->setPsr4($namespace, $path);
    43             }
    44 
    45             $classMap = require __DIR__ . '/autoload_classmap.php';
    46             if ($classMap) {
    47                 $loader->addClassMap($classMap);
    48             }
    49         }
     29        require __DIR__ . '/autoload_static.php';
     30        call_user_func(\Composer\Autoload\ComposerStaticInit814b5d616008b0576aeb0740be7b0990::getInitializer($loader));
    5031
    5132        $loader->register(true);
  • smaily-for-wp/tags/3.1.0/vendor/composer/autoload_static.php

    r2625099 r2873649  
    55namespace Composer\Autoload;
    66
    7 class ComposerStaticInit88c0474316a09b223d787fb04022e877
     7class ComposerStaticInit814b5d616008b0576aeb0740be7b0990
    88{
    99    public static $classMap = array (
     
    1414    {
    1515        return \Closure::bind(function () use ($loader) {
    16             $loader->classMap = ComposerStaticInit88c0474316a09b223d787fb04022e877::$classMap;
     16            $loader->classMap = ComposerStaticInit814b5d616008b0576aeb0740be7b0990::$classMap;
    1717
    1818        }, null, ClassLoader::class);
  • smaily-for-wp/tags/3.1.0/vendor/composer/installed.php

    r2625099 r2873649  
    11<?php return array(
    22    'root' => array(
    3         'pretty_version' => '3.0.7',
    4         'version' => '3.0.7.0',
     3        'name' => 'smaily/smaily_for_wp',
     4        'pretty_version' => '3.1.0',
     5        'version' => '3.1.0.0',
     6        'reference' => 'b04212fd42f202551db5ff56b280643da8a68edc',
    57        'type' => 'plugin',
    68        'install_path' => __DIR__ . '/../../',
    79        'aliases' => array(),
    8         'reference' => 'fa56715956b0051386be20ffb4993a7539c91528',
    9         'name' => 'smaily/smaily_for_wp',
    1010        'dev' => false,
    1111    ),
    1212    'versions' => array(
    1313        'smaily/smaily_for_wp' => array(
    14             'pretty_version' => '3.0.7',
    15             'version' => '3.0.7.0',
     14            'pretty_version' => '3.1.0',
     15            'version' => '3.1.0.0',
     16            'reference' => 'b04212fd42f202551db5ff56b280643da8a68edc',
    1617            'type' => 'plugin',
    1718            'install_path' => __DIR__ . '/../../',
    1819            'aliases' => array(),
    19             'reference' => 'fa56715956b0051386be20ffb4993a7539c91528',
    2020            'dev_requirement' => false,
    2121        ),
  • smaily-for-wp/trunk/admin/class-smaily-for-wp-admin.php

    r2486965 r2873649  
    7979        // Load configuration data.
    8080        $has_credentials = $this->options->has_credentials();
    81         $form_options     = $this->options->get_form_options();
     81        $form_options    = $this->options->get_form_options();
    8282
    8383        // Create admin template.
     
    8787        add_menu_page( 'smaily', 'Smaily', 'manage_options', SMLY4WP_PLUGIN_PATH, '', SMLY4WP_PLUGIN_URL . '/gfx/icon.png' );
    8888        add_submenu_page( 'smaily', 'Newsletter subscription form', 'Form', 'manage_options', SMLY4WP_PLUGIN_PATH, array( $template, 'dispatch' ) );
     89    }
     90
     91    /**
     92     * Load newsletter subscription block.
     93     *
     94     * @since 3.1.0
     95     */
     96    public function smaily_subscription_block_init( $screen ) {
     97        if ( ! in_array( $screen, array( 'site-editor.php', 'post.php', 'page.php' ), true ) ) {
     98            return;
     99        }
     100
     101        $autoresponders = array(
     102            array(
     103                'label' => __( 'No autoresponder', 'smaily-for-wp' ),
     104                'value' => '',
     105            ),
     106        );
     107
     108        foreach ( $this->get_autoresponders() as $autoresponder_id => $title ) {
     109            $autoresponders[] = array(
     110                'label' => $title,
     111                'value' => (string) $autoresponder_id,
     112            );
     113        }
     114
     115        wp_enqueue_script(
     116            $this->plugin_name,
     117            SMLY4WP_PLUGIN_URL . '/blocks/index.js',
     118            array(),
     119            false,
     120            true
     121        );
     122
     123        wp_localize_script(
     124            $this->plugin_name,
     125            'autoresponders',
     126            json_encode( $autoresponders )
     127        );
    89128    }
    90129
     
    151190        if ( $refresh && $result['error'] === false ) {
    152191            $has_credentials   = $this->options->has_credentials();
    153             $form_options       = $this->options->get_form_options();
     192            $form_options      = $this->options->get_form_options();
    154193            $result['content'] = $this->generate_admin_template( 'form.php', $has_credentials, $form_options )->render();
    155194        }
     
    195234        $rqst = ( new Smaily_For_WP_Request() )
    196235            ->auth( $params['username'], $params['password'] )
    197             ->setUrl( 'https://' . $params['subdomain'] . '.sendsmaily.net/api/workflows.php?trigger_type=form_submitted' )
     236            ->set_url( 'https://' . $params['subdomain'] . '.sendsmaily.net/api/workflows.php?trigger_type=form_submitted' )
    198237            ->get();
    199238
     
    288327            // Render template.
    289328            $template = $this->generate_optin_template( 'basic.php', $subdomain );
    290             $form = $template->render();
     329            $form     = $template->render();
    291330        }
    292331
     
    392431
    393432        $result = ( new Smaily_For_WP_Request() )
    394             ->setUrl( 'https://' . $api_credentials['subdomain'] . '.sendsmaily.net/api/workflows.php?trigger_type=form_submitted' )
     433            ->set_url( 'https://' . $api_credentials['subdomain'] . '.sendsmaily.net/api/workflows.php?trigger_type=form_submitted' )
    395434            ->auth( $api_credentials['username'], $api_credentials['password'] )
    396435            ->get();
  • smaily-for-wp/trunk/admin/css/smaily-for-wp-admin.css

    r2485930 r2873649  
    22 * All of the CSS used for the admin view.
    33 */
    4 .hidden {display:none}
     4.hidden {
     5    display: none;
     6}
    57
    6 .wrap h2 sup {color:#090}
     8.wrap h2 sup {
     9    color: #009900;
     10}
    711
    812/* form container styles */
    9 #form-container img, #form-container span {vertical-align:middle}
    10     #form-container .wrap {padding:5px 0; margin:0}
    11     #form-container .wrap label {font-weight:bold}
    12     #form-container .wrap em {display:block; font-style:normal; color:#999; padding-bottom:5px}
    13     #form-container .wrap input.input-text, #form-container .wrap select, #form-container .wrap textarea {width:100%}
     13#form-container img,
     14#form-container span {
     15    vertical-align: middle;
     16}
     17
     18#form-container .wrap {
     19    margin: 0;
     20    padding: 5px 0;
     21}
     22#form-container .wrap label {
     23    font-weight: bold;
     24}
     25#form-container .wrap em {
     26    color: #999999;
     27    display: block;
     28    font-style: normal;
     29    padding-bottom: 5px;
     30}
     31#form-container .wrap input.input-text,
     32#form-container .wrap select,
     33#form-container .wrap textarea {
     34    width: 100%;
     35}
    1436
    1537/* content tabs */
    16 .tab-content {padding:5px 4px 10px}
     38.tab-content {
     39    padding: 5px 4px 10px;
     40}
    1741
    18 .tabs {padding-top:10px}
    19 .tabs li {float:left; margin-right:2px}
    20 .tabs li a {background:#ccc; -moz-border-radius-topleft:5px; -moz-border-radius-topright:5px; padding:4px 6px; color:#999; text-decoration:none}
    21 .tabs li a.selected {background:#21759B; color:#fff}
     42.tabs {
     43    padding-top: 10px;
     44}
     45.tabs li {
     46    float: left;
     47    margin-right: 2px;
     48}
     49.tabs li a {
     50    -moz-border-radius-topleft: 5px;
     51    -moz-border-radius-topright: 5px;
     52    background: #cccccc;
     53    color: #999999;
     54    padding: 4px 6px;
     55    text-decoration: none;
     56}
     57.tabs li a.selected {
     58    background: #21759B;
     59    color: #fff;
     60}
  • smaily-for-wp/trunk/admin/js/smaily-for-wp-admin.js

    r2485930 r2873649  
    1 var Default = (function(){
     1var Default = (function () {
    22    var _form = null;
    33
     
    66     * @return void
    77     */
    8     function _throwMessage(text, error){
     8    function _throwMessage(text, error) {
    99        // create message and insert to dom
    1010        var message = jQuery('<div></div>').attr({
     
    2222     * @return void|bool
    2323     */
    24     function _handleResponse(response){
    25         if(!response){ return false; }
    26 
    27         if(response.message){
     24    function _handleResponse(response) {
     25        if (!response) { return false; }
     26
     27        if (response.message) {
    2828            // remove previous messages
    2929            jQuery('#message').remove();
     
    3939     * @return String
    4040     */
    41     function _buildQuery(){
     41    function _buildQuery() {
    4242        var result = {};
    4343
    4444        // get serialized data and restructure
    4545        var data = jQuery('#form-container').serializeArray();
    46         for(var i in data){
     46        for (var i in data) {
    4747            var item = data[i];
    4848            result[item['name']] = item['value'];
     
    5656     * @return void
    5757     */
    58     function _request(data, callback){
     58    function _request(data, callback) {
    5959        // show loader
    6060        jQuery('#h2-loader').show();
     
    6565            smaily_for_wp.ajax_url,
    6666            {
    67                 'action' : 'smaily_admin_save',
    68                 'form_data' : jQuery.param(data)
     67                'action': 'smaily_admin_save',
     68                'form_data': jQuery.param(data)
    6969            },
    70             function(response) {
     70            function (response) {
    7171                // handle response
    7272                _handleResponse(response);
    7373
    7474                // execute callback function
    75                 if(typeof(callback) == 'function'){
     75                if (typeof (callback) == 'function') {
    7676                    callback(response);
    7777                }
     
    8787         * @return void
    8888         */
    89         validateApiKey: function(){
     89        validateApiKey: function () {
    9090            // build query
    9191            var query = _buildQuery();
     
    9494
    9595            // make the request
    96             _request(query, function(response){
    97                 if(response.content){
     96            _request(query, function (response) {
     97                if (response.content) {
    9898                    jQuery('#form-container').html(response.content);
    9999                }
     
    105105         * @return void
    106106         */
    107         removeApiKey: function(){
     107        removeApiKey: function () {
    108108            // build query
    109109            var query = {
     
    113113
    114114            // make the request
    115             _request(query, function(response){
    116                 if(response.content){
     115            _request(query, function (response) {
     116                if (response.content) {
    117117                    jQuery('#form-container').html(response.content);
    118118                }
     
    125125         * @return void
    126126         */
    127         resetForm: function(){
     127        resetForm: function () {
    128128            // build query
    129129            var query = {
     
    132132
    133133            // make the request
    134             _request(query, function(response){
     134            _request(query, function (response) {
    135135                // set textarea content
    136136                var content = response.content;
     
    143143         * @return void
    144144         */
    145         save: function(){
     145        save: function () {
    146146            // build query
    147147            var query = _buildQuery();
     
    158158 * @param {Object} args
    159159 */
    160 var Tabs = (function(args){
     160var Tabs = (function (args) {
    161161    // default options
    162162    var _options = {
     
    169169
    170170    // check required target
    171     if(!_options.target || _options.target.length < 1){ return false; }
     171    if (!_options.target || _options.target.length < 1) { return false; }
    172172
    173173    // bind click event to target tabs
    174     jQuery(_options.target+' a').click(function(){
     174    jQuery(_options.target + ' a').click(function () {
    175175        _select(this);
    176176    });
     
    178178    // use location hash to select tab
    179179    var hash = location.hash.length > 0 ? location.hash : '';
    180     if(hash.length > 0){
    181         var target = jQuery(_options.target+' a[href='+hash+']');
     180    if (hash.length > 0) {
     181        var target = jQuery(_options.target + ' a[href=' + hash + ']');
    182182        _select(target);
    183183    }
     
    187187     * @param {Object} element
    188188     */
    189     function _select(element){
    190         if(!element || element.length < 1){ return false; }
     189    function _select(element) {
     190        if (!element || element.length < 1) { return false; }
    191191        var href = jQuery(element).attr('href');
    192192        var hash = (href.length > 0 && /#/.test(href)) ? href.split('#')[1] : '';
    193193
    194194        // exit if does not have hash
    195         if(hash.length < 1){ return false; }
     195        if (hash.length < 1) { return false; }
    196196
    197197        // reset target tabs selected state
    198         jQuery(_options.target+' a').removeClass('selected');
     198        jQuery(_options.target + ' a').removeClass('selected');
    199199
    200200        // set this tab's state to selected
     
    203203        // hide tabs and make clicked tab contents visible
    204204        jQuery('*[id^=content\-]').addClass('hidden');
    205         jQuery('#content-'+hash).removeClass('hidden');
     205        jQuery('#content-' + hash).removeClass('hidden');
    206206    }
    207207});
  • smaily-for-wp/trunk/admin/partials/smaily-for-wp-admin-form.php

    r2614685 r2873649  
    4646<?php if ( $this->has_credentials ) : ?>
    4747<ul class="tabs">
    48     <li><a id="link-basic" href="#basic"<?php if ( $this->form_options['is_advanced'] === false): ?> class="selected"<?php endif; ?>><?php echo esc_html__( 'Basic', 'smaily-for-wp' ); ?></a></li>
    49     <li><a id="link-advanced" href="#advanced"<?php if ( $this->form_options['is_advanced'] === true): ?> class="selected"<?php endif; ?>><?php echo esc_html__( 'Advanced', 'smaily-for-wp' ); ?></a></li>
     48    <li>
     49        <?php if ( $this->form_options['is_advanced'] === false ) : ?>
     50        <a id="link-basic" href="#basic" class="selected"><?php echo esc_html__( 'Basic', 'smaily-for-wp' ); ?></a>
     51        <?php else : ?>
     52        <a id="link-basic" href="#basic"><?php echo esc_html__( 'Basic', 'smaily-for-wp' ); ?></a>
     53        <?php endif; ?>
     54    </li>
     55    <li>
     56        <?php if ( $this->form_options['is_advanced'] === true ) : ?>
     57        <a id="link-advanced" href="#advanced" class="selected"><?php echo esc_html__( 'Advanced', 'smaily-for-wp' ); ?></a>
     58        <?php else : ?>
     59        <a id="link-advanced" href="#advanced"><?php echo esc_html__( 'Advanced', 'smaily-for-wp' ); ?></a>
     60        <?php endif; ?>
     61    </li>
    5062</ul>
    5163<div class="clear"></div>
    5264
    53 <div id="content-advanced" class="tab-content<?php if ( $this->form_options['is_advanced'] === false): ?> hidden<?php endif; ?>">
     65    <?php if ( $this->form_options['is_advanced'] === false ) : ?>
     66<div id="content-advanced" class="tab-content hidden">
     67<?php else : ?>
     68<div id="content-advanced" class="tab-content">
     69<?php endif; ?>">
    5470    <div class="wrap">
    5571        <label><?php echo esc_html__( 'Newsletter subscription form', 'smaily-for-wp' ); ?> <a href="#" onclick="javascript:Default.resetForm();return false;" title="<?php echo esc_html__( 'Restore original subscription form', 'smaily-for-wp' ); ?>">(<?php echo esc_html__( 'Regenerate', 'smaily-for-wp' ); ?>)</a></label>
     
    6783
    6884<script type="text/javascript">//<![CDATA[
    69   new Tabs({'target':'ul.tabs'});
    70   jQuery('#link-basic').click(function(){
    71       jQuery('input[name=is_advanced]').val('0');
    72   });
    73   jQuery('#link-advanced').click(function(){
    74       jQuery('input[name=is_advanced]').val('1');
    75   });
     85    new Tabs({'target':'ul.tabs'});
     86    jQuery('#link-basic').click(function(){
     87        jQuery('input[name=is_advanced]').val('0');
     88    });
     89    jQuery('#link-advanced').click(function(){
     90        jQuery('input[name=is_advanced]').val('1');
     91    });
    7692//]]></script>
  • smaily-for-wp/trunk/admin/partials/smaily-for-wp-admin-page.php

    r2485930 r2873649  
    66
    77    <form id="form-container" action="<?php echo esc_url( admin_url( 'admin-ajax.php' ) ); ?>" method="post">
    8         <?php echo $this->partial( 'admin/partials/smaily-for-wp-admin-form.php', $this->getVars() ); ?>
     8        <?php echo $this->partial( 'admin/partials/smaily-for-wp-admin-form.php', $this->get_vars() ); ?>
    99    </form>
    1010</div>
  • smaily-for-wp/trunk/includes/class-smaily-for-wp-i18n.php

    r2485930 r2873649  
    11<?php
     2
    23/**
    34 * Define the internationalization functionality.
     
    78 * @subpackage Smaily_For_WP/includes
    89 */
    9 class Smaily_For_WP_i18n {
     10
     11class Smaily_For_WP_I18n {
    1012
    1113    /**
  • smaily-for-wp/trunk/includes/class-smaily-for-wp-lifecycle.php

    r2575319 r2873649  
    11<?php
     2
    23/**
    34 * Define all the logic related to plugin activation, upgrade and uninstall logic.
     
    78 * @subpackage Smaily_For_WP/includes
    89 */
     10
    911class Smaily_For_WP_Lifecycle {
    1012
  • smaily-for-wp/trunk/includes/class-smaily-for-wp-loader.php

    r2485930 r2873649  
    11<?php
     2
    23/**
    34 * Register all actions and filters for the plugin.
     
    1112 * @subpackage Smaily_For_WP/includes
    1213 */
     14
    1315class Smaily_For_WP_Loader {
    1416
     
    8991            'callback'      => $callback,
    9092            'priority'      => $priority,
    91             'accepted_args' => $accepted_args
     93            'accepted_args' => $accepted_args,
    9294        );
    9395
  • smaily-for-wp/trunk/includes/class-smaily-for-wp-options.php

    r2485930 r2873649  
    11<?php
     2
    23/**
    34 * This class is used to work with the plugin's options
     
    89 * @subpackage Smaily_For_WP/includes
    910 */
     11
    1012class Smaily_For_WP_Options {
    1113
     
    115117        if ( is_array( $form_options ) ) {
    116118            $this->form_options = array(
    117                 'form' => isset( $form_options['form'] ) ? esc_textarea( $form_options['form'] ) : '',
     119                'form'        => isset( $form_options['form'] ) ? esc_textarea( $form_options['form'] ) : '',
    118120                'is_advanced' => isset( $form_options['form'] ) ? (bool) $form_options['is_advanced'] : false,
    119121            );
  • smaily-for-wp/trunk/includes/class-smaily-for-wp-request.php

    r2485930 r2873649  
    11<?php
     2
    23/**
    34 * Defines the request making functionality of the plugin.
     
    78 * @subpackage Smaily_For_WP/includes
    89 */
     10
    911class Smaily_For_WP_Request {
    1012
     
    6668     * @return Smaily_For_WP_Request For method chaining.
    6769     */
    68     public function setUrl( $url ) {
     70    public function set_url( $url ) {
    6971        $this->_url = $url;
    7072        return $this;
     
    7880     * @return Smaily_For_WP_Request For method chaining.
    7981     */
    80     public function setData( array $data ) {
     82    public function set_data( array $data ) {
    8183        $this->_data = $data;
    8284        return $this;
     
    9395        $useragent = 'smaily-for-wp/' . SMLY4WP_PLUGIN_VERSION . ' (WordPress/' . get_bloginfo( 'version' ) . '; +' . get_bloginfo( 'url' ) . ')';
    9496        $args      = array(
    95             'headers' => array(
     97            'headers'    => array(
    9698                'Authorization' => 'Basic ' . base64_encode( $this->_username . ':' . $this->_password ),
    9799            ),
  • smaily-for-wp/trunk/includes/class-smaily-for-wp-template.php

    r2485930 r2873649  
    11<?php
     2
    23/**
    34 * Defines the template generating and rendering functionality of the plugin.
     
    78 * @subpackage Smaily_For_WP/includes
    89 */
     10
    911class Smaily_For_WP_Template {
    1012
     
    108110     * @return string $lang Language code.
    109111     */
    110     private function getLanguageCode() {
     112    private function get_language_code() {
    111113        // Language code if using WPML.
    112114        $lang = '';
     
    132134     * @return array
    133135     */
    134     public function getVars() {
     136    public function get_vars() {
    135137        return $this->_vars;
    136138    }
  • smaily-for-wp/trunk/includes/class-smaily-for-wp-widget.php

    r2625099 r2873649  
    11<?php
     2
    23/**
    34 * Defines the widget functionality of the plugin.
     
    78 * @subpackage Smaily/includes
    89 */
     10
    911class Smaily_For_WP_Widget extends WP_Widget {
    1012
     
    7072        $file     = $form_options['is_advanced'] === true ? 'advanced.php' : 'basic.php';
    7173        $template = new Smaily_For_WP_Template( 'public/partials/smaily-for-wp-public-' . $file );
    72         $template->assign( array(
    73             'domain'           => $api_credentials['subdomain'],
    74             'form'             => $form_options['form'],
    75             'is_advanced'      => $form_options['is_advanced'],
    76             'show_name'        => $show_name,
    77             'success_url'      => $success_url,
    78             'failure_url'      => $failure_url,
    79             'autoresponder_id' => $autoresponder,
    80         ) );
     74        $template->assign(
     75            array(
     76                'domain'           => $api_credentials['subdomain'],
     77                'form'             => $form_options['form'],
     78                'is_advanced'      => $form_options['is_advanced'],
     79                'show_name'        => $show_name,
     80                'success_url'      => $success_url,
     81                'failure_url'      => $failure_url,
     82                'autoresponder_id' => $autoresponder,
     83            )
     84        );
    8185
    8286        // Display responses on Smaily subscription form.
     
    129133     */
    130134    public function update( $new_instance, $old_instance ) {
    131         $instance                = $old_instance;
    132         $instance['title']       = sanitize_text_field( $new_instance['title'] );
    133         $instance['show_name']   = isset( $new_instance['show_name'] ) ? (bool) $new_instance['show_name'] : false;
    134         $instance['success_url'] = esc_url_raw( $new_instance['success_url'] );
    135         $instance['failure_url'] = esc_url_raw( $new_instance['failure_url'] );
     135        $instance                  = $old_instance;
     136        $instance['title']         = sanitize_text_field( $new_instance['title'] );
     137        $instance['show_name']     = isset( $new_instance['show_name'] ) ? (bool) $new_instance['show_name'] : false;
     138        $instance['success_url']   = esc_url_raw( $new_instance['success_url'] );
     139        $instance['failure_url']   = esc_url_raw( $new_instance['failure_url'] );
    136140        $instance['autoresponder'] = sanitize_text_field( $new_instance['autoresponder'] );
    137141
     
    174178            <label for="' . $show_name_id . '">' . __( 'Display name field?', 'smaily-for-wp' ) . '</label>' .
    175179        '</p>';
     180
    176181        // Display inputs for success/failure URLs.
    177182        $success_url_id          = esc_attr( $this->get_field_id( 'success_url' ) );
     
    190195            <input id="' . $failure_url_id . '" name="' . $failure_url . '" type="text" value="' . $instance['failure_url'] . '" />
    191196        </p>';
     197
    192198        // Display autoresponder select menu.
    193199        $autoresponder_id          = esc_attr( $this->get_field_id( 'autoresponder' ) );
  • smaily-for-wp/trunk/includes/class-smaily-for-wp.php

    r2486913 r2873649  
    11<?php
     2
    23/**
    34 * The core plugin class.
     
    1314 * @subpackage Smaily_For_WP/includes
    1415 */
     16
    1517class Smaily_For_WP {
    1618
     
    6264     */
    6365    public function __construct() {
    64         $this->version = SMLY4WP_PLUGIN_VERSION;
     66        $this->version     = SMLY4WP_PLUGIN_VERSION;
    6567        $this->plugin_name = 'smaily-for-wp';
    6668        $this->load_dependencies();
    6769        $this->set_locale();
    6870        $this->define_lifecycle_hooks();
     71        $this->init_blocks();
    6972        $this->define_admin_hooks();
    7073        $this->define_public_hooks();
     
    9497    private function load_dependencies() {
    9598        require_once SMLY4WP_PLUGIN_PATH . 'admin/class-smaily-for-wp-admin.php';
     99        require_once SMLY4WP_PLUGIN_PATH . 'includes/class-smaily-for-wp-block.php';
    96100        require_once SMLY4WP_PLUGIN_PATH . 'includes/class-smaily-for-wp-i18n.php';
    97101        require_once SMLY4WP_PLUGIN_PATH . 'includes/class-smaily-for-wp-lifecycle.php';
     
    109113     * Define the locale for this plugin for internationalization.
    110114     *
    111      * Uses the Smaily_For_WP_i18n class in order to set the domain and to register the hook
     115     * Uses the Smaily_For_WP_I18n class in order to set the domain and to register the hook
    112116     * with WordPress.
    113117     *
     
    116120     */
    117121    private function set_locale() {
    118         $plugin_i18n = new Smaily_For_WP_i18n();
     122        $plugin_i18n = new Smaily_For_WP_I18n();
    119123        $this->loader->add_action( 'plugins_loaded', $plugin_i18n, 'load_plugin_textdomain' );
     124    }
     125
     126    /**
     127     * Initialize Gutenberg blocks.
     128     *
     129     * @since 3.1.0
     130     * @access private
     131     */
     132    private function init_blocks() {
     133        $plugin_block = new Smaily_For_WP_Block( $this->options, $this->get_plugin_name(), $this->get_version() );
     134
     135        register_block_type(
     136            SMLY4WP_PLUGIN_PATH . '/blocks',
     137            array(
     138                'render_callback' => array( $plugin_block, 'render' ),
     139            )
     140        );
    120141    }
    121142
     
    148169        $this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'enqueue_styles' );
    149170        $this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'enqueue_scripts' );
     171        $this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'smaily_subscription_block_init' );
    150172        $this->loader->add_action( 'wp_ajax_smaily_admin_save', $plugin_admin, 'smaily_admin_save' );
    151173        $this->loader->add_action( 'widgets_init', $plugin_admin, 'smaily_subscription_widget_init' );
  • smaily-for-wp/trunk/lang/smaily-for-wp-et.po

    r2575319 r2873649  
    22msgstr ""
    33"Project-Id-Version: Smaily for WP\n"
    4 "POT-Creation-Date: 2021-07-30 11:07+0300\n"
    5 "PO-Revision-Date: 2021-07-30 11:07+0300\n"
     4"POT-Creation-Date: 2023-03-02 15:00+0200\n"
     5"PO-Revision-Date: 2023-03-02 15:00+0200\n"
    66"Last-Translator: Smaily <[email protected]>\n"
    77"Language-Team: Smaily <[email protected]>\n"
     
    1010"Content-Type: text/plain; charset=UTF-8\n"
    1111"Content-Transfer-Encoding: 8bit\n"
    12 "X-Generator: Poedit 2.3\n"
     12"Plural-Forms: nplurals=2; plural=(n != 1);\n"
     13"X-Generator: Poedit 3.2.2\n"
    1314"X-Poedit-Basepath: ..\n"
    14 "Plural-Forms: nplurals=2; plural=(n != 1);\n"
    1515"X-Poedit-KeywordsList: __;_e;_n:1,2;_n_noop:1,2;_x:1,2c;_nx:4c,1,2;"
    1616"_nx_noop:4c,1,2;_ex:1,2c;esc_attr__;esc_attr_e;esc_attr_x:1,2c;esc_html__;"
     
    1818"X-Poedit-SearchPath-0: .\n"
    1919
    20 #: admin/class-smaily-for-wp-admin.php:182
     20#: admin/class-smaily-for-wp-admin.php:103
     21#: includes/class-smaily-for-wp-widget.php:205
     22msgid "No autoresponder"
     23msgstr "Ilma automaatvastajata vorm"
     24
     25#: admin/class-smaily-for-wp-admin.php:221
    2126msgid "Please enter subdomain!"
    2227msgstr "Palun sisesta alamdomeen!"
    2328
    24 #: admin/class-smaily-for-wp-admin.php:186
     29#: admin/class-smaily-for-wp-admin.php:225
    2530msgid "Please enter username!"
    2631msgstr "Palun sisesta kasutajatunnus!"
    2732
    28 #: admin/class-smaily-for-wp-admin.php:190
     33#: admin/class-smaily-for-wp-admin.php:229
    2934msgid "Please enter password!"
    3035msgstr "Palun sisesta parool!"
    3136
    32 #: admin/class-smaily-for-wp-admin.php:206
     37#: admin/class-smaily-for-wp-admin.php:245
    3338msgid "Wrong credentials"
    3439msgstr "Valed autentimise tunnused"
    3540
    36 #: admin/class-smaily-for-wp-admin.php:211
     41#: admin/class-smaily-for-wp-admin.php:250
    3742msgid "Error in subdomain"
    3843msgstr "Viga alamdomeenis"
    3944
    40 #: admin/class-smaily-for-wp-admin.php:221
     45#: admin/class-smaily-for-wp-admin.php:260
    4146msgid "Something went wrong with request to Smaily"
    4247msgstr "Ilmnes probleem Smaily-ga ühendamisel"
    4348
    44 #: admin/class-smaily-for-wp-admin.php:230
     49#: admin/class-smaily-for-wp-admin.php:269
    4550msgid "Credentials validated."
    4651msgstr "Autentimise tunnused valideeritud."
    4752
    48 #: admin/class-smaily-for-wp-admin.php:247
     53#: admin/class-smaily-for-wp-admin.php:286
    4954msgid "Credentials removed."
    5055msgstr "Autentimise tunnused eemaldatud."
    5156
    52 #: admin/class-smaily-for-wp-admin.php:264
     57#: admin/class-smaily-for-wp-admin.php:303
    5358msgid "Newsletter subscription form reset to default."
    5459msgstr "Liitumisvormi kood taasloodud."
    5560
    56 #: admin/class-smaily-for-wp-admin.php:303
     61#: admin/class-smaily-for-wp-admin.php:342
    5762msgid "Changes saved."
    5863msgstr "Salvestatud."
     
    8691msgstr "Kontrolli"
    8792
    88 #: admin/partials/smaily-for-wp-admin-form.php:48
     93#: admin/partials/smaily-for-wp-admin-form.php:50
     94#: admin/partials/smaily-for-wp-admin-form.php:52
    8995msgid "Basic"
    9096msgstr "Tavaseaded"
    9197
    92 #: admin/partials/smaily-for-wp-admin-form.php:49
     98#: admin/partials/smaily-for-wp-admin-form.php:57
     99#: admin/partials/smaily-for-wp-admin-form.php:59
    93100msgid "Advanced"
    94101msgstr "Spetsialisti seaded"
    95102
    96 #: admin/partials/smaily-for-wp-admin-form.php:55
     103#: admin/partials/smaily-for-wp-admin-form.php:71
    97104msgid "Newsletter subscription form"
    98105msgstr "Uudiskirja liitumisvorm"
    99106
    100 #: admin/partials/smaily-for-wp-admin-form.php:55
     107#: admin/partials/smaily-for-wp-admin-form.php:71
    101108msgid "Restore original subscription form"
    102109msgstr "Taasta algne liitumisvorm"
    103110
    104 #: admin/partials/smaily-for-wp-admin-form.php:55
     111#: admin/partials/smaily-for-wp-admin-form.php:71
    105112msgid "Regenerate"
    106113msgstr "Taastekita"
    107114
    108 #: admin/partials/smaily-for-wp-admin-form.php:56
     115#: admin/partials/smaily-for-wp-admin-form.php:72
    109116msgid "HTML of subscription form"
    110117msgstr "Liitumisvormi HTML"
    111118
    112 #: admin/partials/smaily-for-wp-admin-form.php:61
     119#: admin/partials/smaily-for-wp-admin-form.php:77
    113120msgid "Note: When you save under Basic tab, default form will be used."
    114121msgstr ""
    115122"Hoiatus: Kui salvestad Tavaseadete vaates, kasutatakse lehel vaikimisi vormi."
    116123
    117 #: admin/partials/smaily-for-wp-admin-form.php:64
     124#: admin/partials/smaily-for-wp-admin-form.php:80
    118125msgid "Save changes"
    119126msgstr "Salvesta muudatused"
     
    127134msgstr "Palun oota..."
    128135
    129 #: includes/class-smaily-for-wp-widget.php:37
     136#: blocks/index.js:221
     137#, fuzzy
     138#| msgid "Email"
     139msgid "E-mail"
     140msgstr "E-post"
     141
     142#: blocks/index.js:221
     143#, fuzzy
     144#| msgid "Email"
     145msgid "Smaily"
     146msgstr "E-post"
     147
     148#: blocks/index.js:225 includes/class-smaily-for-wp-widget.php:40
     149msgid "Smaily Newsletter Subscription"
     150msgstr "Smaily uudiskirjaga liitumine"
     151
     152#: includes/class-smaily-for-wp-widget.php:39
    130153msgid "Smaily newsletter subscription form"
    131154msgstr "Smaily uudiskirjaga liitumise vorm"
    132155
    133 #: includes/class-smaily-for-wp-widget.php:38
    134 msgid "Smaily Newsletter Subscription"
    135 msgstr "Smaily uudiskirjaga liitumine"
    136 
    137 #: includes/class-smaily-for-wp-widget.php:89
    138 #: public/class-smaily-for-wp-public.php:104
     156#: includes/class-smaily-for-wp-widget.php:93
     157#: public/class-smaily-for-wp-public.php:106
    139158msgid "Smaily credentials not validated. Subscription form will not work!"
    140159msgstr "Smaily kasutajatunnused on valideerimata.  Uudiskirja vorm ei tööta!"
    141160
    142 #: includes/class-smaily-for-wp-widget.php:96
    143 #: public/class-smaily-for-wp-public.php:111
     161#: includes/class-smaily-for-wp-widget.php:100
     162#: public/class-smaily-for-wp-public.php:113
    144163msgid "Form was not submitted using POST method."
    145164msgstr "Andmeid peab saatma POST tegevusviisiga."
    146165
    147 #: includes/class-smaily-for-wp-widget.php:99
    148 #: public/class-smaily-for-wp-public.php:114
     166#: includes/class-smaily-for-wp-widget.php:103
     167#: public/class-smaily-for-wp-public.php:116
    149168msgid "Input does not contain a recognizable email address."
    150169msgstr "Sisend ei sisalda tuntavat emaili aadressi."
    151170
    152 #: includes/class-smaily-for-wp-widget.php:102
    153 #: public/class-smaily-for-wp-public.php:117
     171#: includes/class-smaily-for-wp-widget.php:106
     172#: public/class-smaily-for-wp-public.php:119
    154173msgid ""
    155174"Could not add to subscriber list for an unknown reason. Probably something "
     
    159178"probleem Smaily-s."
    160179
    161 #: includes/class-smaily-for-wp-widget.php:164
     180#: includes/class-smaily-for-wp-widget.php:168
    162181msgid "Title"
    163182msgstr "Pealkiri"
    164183
    165 #: includes/class-smaily-for-wp-widget.php:174
     184#: includes/class-smaily-for-wp-widget.php:178
    166185msgid "Display name field?"
    167186msgstr "Näita nime välja?"
    168187
    169 #: includes/class-smaily-for-wp-widget.php:181
     188#: includes/class-smaily-for-wp-widget.php:186
    170189msgid "Success URL"
    171190msgstr "Õnnestumise URL"
    172191
    173 #: includes/class-smaily-for-wp-widget.php:189
     192#: includes/class-smaily-for-wp-widget.php:194
    174193msgid "Failure URL"
    175194msgstr "Ebaõnnestumise URL"
    176195
    177 #: includes/class-smaily-for-wp-widget.php:197
     196#: includes/class-smaily-for-wp-widget.php:203
    178197msgid "Autoresponders"
    179198msgstr "Automaatvastajad"
    180 
    181 #: includes/class-smaily-for-wp-widget.php:199
    182 msgid "No autoresponder"
    183 msgstr "Ilma automaatvastajata vorm"
    184199
    185200#: public/partials/smaily-for-wp-public-basic.php:3
  • smaily-for-wp/trunk/migrations/upgrade-3-0-0.php

    r2575319 r2873649  
    11<?php
     2
    23/**
    34 * Apply any database upgrades required for 3.0.0.
     
    1112 * @since 3.0.0
    1213 */
     14
    1315$upgrade = function() {
    1416    global $wpdb;
    15     $table_name = $wpdb->prefix . 'smaily_config';
    1617
    17     if ( $wpdb->get_var( "SHOW TABLES LIKE '$table_name'" ) === $table_name ) {
    18         $config = $wpdb->get_row( "SELECT * FROM `$table_name` LIMIT 1", ARRAY_A );
     18    if ( $wpdb->get_var( "SHOW TABLES LIKE {$wpdb->prefix}smaily_config" ) === $wpdb->prefix . 'smaily_config' ) {
     19        $config = $wpdb->get_row( "SELECT * FROM {$wpdb->prefix}smaily_config LIMIT 1", ARRAY_A );
    1920        // Get saved autoresponder ID.
    2021        $autoresponder_id = isset( $config['autoresponder'] ) ? $config['autoresponder'] : '';
  • smaily-for-wp/trunk/public/class-smaily-for-wp-public.php

    r2493245 r2873649  
    11<?php
     2
    23/**
    34 * The public-facing functionality of the plugin.
     
    78 * @subpackage Smaily_For_WP/public
    89 */
     10
    911class Smaily_For_WP_Public {
    1012
     
    7678
    7779        // Parse attributes out of shortcode tag.
    78         $shortcode_atts = shortcode_atts(
     80        $shortcode_atts             = shortcode_atts(
    7981            array(
    8082                'success_url'      => get_site_url(),
  • smaily-for-wp/trunk/public/partials/smaily-for-wp-public-advanced.php

    r2485930 r2873649  
    1 <?php echo html_entity_decode( $this->form ); ?>
     1<?php echo html_entity_decode( $this->form );
  • smaily-for-wp/trunk/public/partials/smaily-for-wp-public-basic.php

    r2485930 r2873649  
    22    <p class="error" style="padding:15px;background-color:#f2dede;margin:0 0 10px;display:<?php echo $this->form_has_response ? 'block' : 'none'; ?>"><?php echo esc_html( $this->response_message ); ?></p>
    33    <p class="success" style="padding:15px;background-color:#dff0d8;margin:0 0 10px;display:<?php echo $this->form_is_successful ? 'block' : 'none'; ?>"><?php echo esc_html__( 'Thank you for subscribing to our newsletter.', 'smaily-for-wp' ); ?></p>
    4     <?php if ( $this->autoresponder_id ): ?>
     4    <?php if ( $this->autoresponder_id ) : ?>
    55        <input type="hidden" name="autoresponder" value="<?php echo $this->autoresponder_id; ?>" />
    66    <?php endif; ?>
    7     <input type="hidden" name="lang" value="<?php echo esc_html( $this->getLanguageCode() ); ?>" />
     7    <input type="hidden" name="lang" value="<?php echo esc_html( $this->get_language_code() ); ?>" />
    88    <input type="hidden" name="success_url" value="<?php echo $this->success_url ? $this->success_url : get_site_url(); ?>" />
    99    <input type="hidden" name="failure_url" value="<?php echo $this->failure_url ? $this->failure_url : get_site_url(); ?>" />
  • smaily-for-wp/trunk/readme.txt

    r2625099 r2873649  
    44Requires PHP: 5.6
    55Requires at least: 4.0
    6 Stable tag: 3.0.7
     6Stable tag: 3.1.0
    77Tags: widget, plugin, sidebar, api, mail, email, marketing, smaily
    8 Tested up to: 5.8.0
     8Tested up to: 6.1.1
    99
    1010Smaily newsletter subscription plugin for WordPress
     
    7777== Changelog ==
    7878
     79= 3.1.0 =
     80- Basic Gutenberg blocks support
     81
    7982= 3.0.7 =
    8083- Fix automation workflows being fetched on every operation in WordPress.
  • smaily-for-wp/trunk/smaily-for-wp.php

    r2625099 r2873649  
    1010 * Text Domain:       smaily-for-wp
    1111 * Description:       Smaily newsletter subscription form.
    12  * Version:           3.0.7
     12 * Version:           3.1.0
    1313 * Author:            Sendsmaily LLC
    1414 * Author URI:        https://smaily.com
     
    2525 * Current plugin version.
    2626 */
    27 define( 'SMLY4WP_PLUGIN_VERSION', '3.0.7' );
     27define( 'SMLY4WP_PLUGIN_VERSION', '3.1.0' );
    2828
    2929/**
  • smaily-for-wp/trunk/vendor/autoload.php

    r2625099 r2873649  
    33// autoload.php @generated by Composer
    44
     5if (PHP_VERSION_ID < 50600) {
     6    if (!headers_sent()) {
     7        header('HTTP/1.1 500 Internal Server Error');
     8    }
     9    $err = 'Composer 2.3.0 dropped support for autoloading on PHP <5.6 and you are running '.PHP_VERSION.', please upgrade PHP or use Composer 2.2 LTS via "composer self-update --2.2". Aborting.'.PHP_EOL;
     10    if (!ini_get('display_errors')) {
     11        if (PHP_SAPI === 'cli' || PHP_SAPI === 'phpdbg') {
     12            fwrite(STDERR, $err);
     13        } elseif (!headers_sent()) {
     14            echo $err;
     15        }
     16    }
     17    trigger_error(
     18        $err,
     19        E_USER_ERROR
     20    );
     21}
     22
    523require_once __DIR__ . '/composer/autoload_real.php';
    624
    7 return ComposerAutoloaderInit88c0474316a09b223d787fb04022e877::getLoader();
     25return ComposerAutoloaderInit814b5d616008b0576aeb0740be7b0990::getLoader();
  • smaily-for-wp/trunk/vendor/composer/ClassLoader.php

    r2614685 r2873649  
    4343class ClassLoader
    4444{
     45    /** @var \Closure(string):void */
     46    private static $includeFile;
     47
    4548    /** @var ?string */
    4649    private $vendorDir;
     
    107110    {
    108111        $this->vendorDir = $vendorDir;
     112        self::initializeIncludeClosure();
    109113    }
    110114
     
    150154    /**
    151155     * @return string[] Array of classname => path
    152      * @psalm-var array<string, string>
     156     * @psalm-return array<string, string>
    153157     */
    154158    public function getClassMap()
     
    426430    {
    427431        if ($file = $this->findFile($class)) {
    428             includeFile($file);
     432            $includeFile = self::$includeFile;
     433            $includeFile($file);
    429434
    430435            return true;
     
    556561        return false;
    557562    }
     563
     564    /**
     565     * @return void
     566     */
     567    private static function initializeIncludeClosure()
     568    {
     569        if (self::$includeFile !== null) {
     570            return;
     571        }
     572
     573        /**
     574         * Scope isolated include.
     575         *
     576         * Prevents access to $this/self from included files.
     577         *
     578         * @param  string $file
     579         * @return void
     580         */
     581        self::$includeFile = \Closure::bind(static function($file) {
     582            include $file;
     583        }, null, null);
     584    }
    558585}
    559 
    560 /**
    561  * Scope isolated include.
    562  *
    563  * Prevents access to $this/self from included files.
    564  *
    565  * @param  string $file
    566  * @return void
    567  * @private
    568  */
    569 function includeFile($file)
    570 {
    571     include $file;
    572 }
  • smaily-for-wp/trunk/vendor/composer/InstalledVersions.php

    r2625099 r2873649  
    2222 *
    2323 * To require its presence, you can require `composer-runtime-api ^2.0`
     24 *
     25 * @final
    2426 */
    2527class InstalledVersions
     
    2729    /**
    2830     * @var mixed[]|null
    29      * @psalm-var array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>}|array{}|null
     31     * @psalm-var array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}|array{}|null
    3032     */
    3133    private static $installed;
     
    3840    /**
    3941     * @var array[]
    40      * @psalm-var array<string, array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>}>
     42     * @psalm-var array<string, array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}>
    4143     */
    4244    private static $installedByVendor = array();
     
    242244    /**
    243245     * @return array
    244      * @psalm-return array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}
     246     * @psalm-return array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}
    245247     */
    246248    public static function getRootPackage()
     
    256258     * @deprecated Use getAllRawData() instead which returns all datasets for all autoloaders present in the process. getRawData only returns the first dataset loaded, which may not be what you expect.
    257259     * @return array[]
    258      * @psalm-return array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>}
     260     * @psalm-return array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}
    259261     */
    260262    public static function getRawData()
     
    279281     *
    280282     * @return array[]
    281      * @psalm-return list<array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>}>
     283     * @psalm-return list<array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}>
    282284     */
    283285    public static function getAllRawData()
     
    302304     * @return void
    303305     *
    304      * @psalm-param array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>} $data
     306     * @psalm-param array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>} $data
    305307     */
    306308    public static function reload($data)
     
    312314    /**
    313315     * @return array[]
    314      * @psalm-return list<array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string, type: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string, type?: string}>}>
     316     * @psalm-return list<array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}>
    315317     */
    316318    private static function getInstalled()
  • smaily-for-wp/trunk/vendor/composer/autoload_classmap.php

    r2575319 r2873649  
    33// autoload_classmap.php @generated by Composer
    44
    5 $vendorDir = dirname(dirname(__FILE__));
     5$vendorDir = dirname(__DIR__);
    66$baseDir = dirname($vendorDir);
    77
  • smaily-for-wp/trunk/vendor/composer/autoload_namespaces.php

    r2575319 r2873649  
    33// autoload_namespaces.php @generated by Composer
    44
    5 $vendorDir = dirname(dirname(__FILE__));
     5$vendorDir = dirname(__DIR__);
    66$baseDir = dirname($vendorDir);
    77
  • smaily-for-wp/trunk/vendor/composer/autoload_psr4.php

    r2575319 r2873649  
    33// autoload_psr4.php @generated by Composer
    44
    5 $vendorDir = dirname(dirname(__FILE__));
     5$vendorDir = dirname(__DIR__);
    66$baseDir = dirname($vendorDir);
    77
  • smaily-for-wp/trunk/vendor/composer/autoload_real.php

    r2625099 r2873649  
    33// autoload_real.php @generated by Composer
    44
    5 class ComposerAutoloaderInit88c0474316a09b223d787fb04022e877
     5class ComposerAutoloaderInit814b5d616008b0576aeb0740be7b0990
    66{
    77    private static $loader;
     
    2323        }
    2424
    25         spl_autoload_register(array('ComposerAutoloaderInit88c0474316a09b223d787fb04022e877', 'loadClassLoader'), true, true);
    26         self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(\dirname(__FILE__)));
    27         spl_autoload_unregister(array('ComposerAutoloaderInit88c0474316a09b223d787fb04022e877', 'loadClassLoader'));
     25        spl_autoload_register(array('ComposerAutoloaderInit814b5d616008b0576aeb0740be7b0990', 'loadClassLoader'), true, true);
     26        self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__));
     27        spl_autoload_unregister(array('ComposerAutoloaderInit814b5d616008b0576aeb0740be7b0990', 'loadClassLoader'));
    2828
    29         $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
    30         if ($useStaticLoader) {
    31             require __DIR__ . '/autoload_static.php';
    32 
    33             call_user_func(\Composer\Autoload\ComposerStaticInit88c0474316a09b223d787fb04022e877::getInitializer($loader));
    34         } else {
    35             $map = require __DIR__ . '/autoload_namespaces.php';
    36             foreach ($map as $namespace => $path) {
    37                 $loader->set($namespace, $path);
    38             }
    39 
    40             $map = require __DIR__ . '/autoload_psr4.php';
    41             foreach ($map as $namespace => $path) {
    42                 $loader->setPsr4($namespace, $path);
    43             }
    44 
    45             $classMap = require __DIR__ . '/autoload_classmap.php';
    46             if ($classMap) {
    47                 $loader->addClassMap($classMap);
    48             }
    49         }
     29        require __DIR__ . '/autoload_static.php';
     30        call_user_func(\Composer\Autoload\ComposerStaticInit814b5d616008b0576aeb0740be7b0990::getInitializer($loader));
    5031
    5132        $loader->register(true);
  • smaily-for-wp/trunk/vendor/composer/autoload_static.php

    r2625099 r2873649  
    55namespace Composer\Autoload;
    66
    7 class ComposerStaticInit88c0474316a09b223d787fb04022e877
     7class ComposerStaticInit814b5d616008b0576aeb0740be7b0990
    88{
    99    public static $classMap = array (
     
    1414    {
    1515        return \Closure::bind(function () use ($loader) {
    16             $loader->classMap = ComposerStaticInit88c0474316a09b223d787fb04022e877::$classMap;
     16            $loader->classMap = ComposerStaticInit814b5d616008b0576aeb0740be7b0990::$classMap;
    1717
    1818        }, null, ClassLoader::class);
  • smaily-for-wp/trunk/vendor/composer/installed.php

    r2625099 r2873649  
    11<?php return array(
    22    'root' => array(
    3         'pretty_version' => '3.0.7',
    4         'version' => '3.0.7.0',
     3        'name' => 'smaily/smaily_for_wp',
     4        'pretty_version' => '3.1.0',
     5        'version' => '3.1.0.0',
     6        'reference' => 'b04212fd42f202551db5ff56b280643da8a68edc',
    57        'type' => 'plugin',
    68        'install_path' => __DIR__ . '/../../',
    79        'aliases' => array(),
    8         'reference' => 'fa56715956b0051386be20ffb4993a7539c91528',
    9         'name' => 'smaily/smaily_for_wp',
    1010        'dev' => false,
    1111    ),
    1212    'versions' => array(
    1313        'smaily/smaily_for_wp' => array(
    14             'pretty_version' => '3.0.7',
    15             'version' => '3.0.7.0',
     14            'pretty_version' => '3.1.0',
     15            'version' => '3.1.0.0',
     16            'reference' => 'b04212fd42f202551db5ff56b280643da8a68edc',
    1617            'type' => 'plugin',
    1718            'install_path' => __DIR__ . '/../../',
    1819            'aliases' => array(),
    19             'reference' => 'fa56715956b0051386be20ffb4993a7539c91528',
    2020            'dev_requirement' => false,
    2121        ),
Note: See TracChangeset for help on using the changeset viewer.