2017 © Pedro Peláez
 

library wp-awesome-widgets

A library to add some awesome widgets for WordPress.

image

inc2734/wp-awesome-widgets

A library to add some awesome widgets for WordPress.

  • Friday, July 27, 2018
  • by inc2734
  • Repository
  • 1 Watchers
  • 0 Stars
  • 1,442 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 0 Forks
  • 1 Open issues
  • 86 Versions
  • 22 % Grown

The README.md

WP Awesome Widgets

CI Latest Stable Version License, (*1)

Widgets

  • PR Box
  • Slider (slick)
  • Pickup slider (slick)
  • Showcase
  • Site branding (Displaying the Logo)
  • Recent posts
  • Any posts
  • Ranking (Self updating)
  • Taxonomy posts
  • Contents outline
  • Profile box
  • Carousel (Any posts)
  • Local navigation

Install

$ composer require inc2734/wp-awesome-widgets

How to use

<?php
new \Inc2734\WP_Awesome_Widgets\Bootstrap();

How to overwite widget templates

You can overwite the widget template. For example,, (*2)

$ cd wp-content/your-theme
$ mkdir -p templates/widget
$ cp vendor/inc2734/wp-awesome-widgets/src/widget/slider/_widget.php templates/widget/slider.php
$ vi templates/widget/slider.php

Filter hooks

#

/**
 * Customize widget options

 * @param array $widget_options
 * @param string The widget class name
 * @return array
 */
add_filter(
    'inc2734_wp_awesome_widgets_widget_options',
    function( $widget_options, $classname ) {
        return $widget_options;
    },
    10,
    2
);

inc2734_wp_awesome_widgets_recent_posts_widget_args

/**
 * Customize recent posts widget args
 *
 * @param array $query_args
 * @return array
 */
add_filter(
    'inc2734_wp_awesome_widgets_recent_posts_widget_args',
    function( $query_args ) {
        return $query_args;
    }
);

inc2734_wp_awesome_widgets_recent_posts_widget_args_<$widget_number>

/**
 * Customize specific recent posts widget args
 *
 * @param array $query_args
 * @return array
 */
add_filter(
    'inc2734_wp_awesome_widgets_recent_posts_widget_args_'. $widget_number,
    function( $query_args ) {
        return $query_args;
    }
);

inc2734_wp_awesome_widgets_ranking_widget_args

/**
 * Customize ranking widget args
 *
 * @param array $query_args
 * @return array
 */
add_filter(
    'inc2734_wp_awesome_widgets_ranking_widget_args',
    function( $query_args ) {
        return $query_args;
    }
);

inc2734_wp_awesome_widgets_ranking_widget_args_<$widget_number>

/**
 * Customize specific ranking widget args
 *
 * @param array $query_args
 * @return array
 */
add_filter(
    'inc2734_wp_awesome_widgets_ranking_widget_args_' . $widget_number,
    function( $query_args ) {
        return $query_args;
    }
);
/**
 * Customize carousel any posts widget args
 *
 * @param array $query_args
 * @return array
 */
add_filter(
    'inc2734_wp_awesome_widgets_carousel_any_posts_widget_args',
    function( $query_args ) {
        return $query_args;
    }
);
/**
 * Customize specific carousel any posts widget args
 *
 * @param array $query_args
 * @return array
 */
add_filter(
    'inc2734_wp_awesome_widgets_carousel_any_posts_widget_args_'. $widget_number,
    function( $query_args ) {
        return $query_args;
    }
);
/**
 * Customize carousel image size
 *
 * @param string $image_size
 * @param boolean $is_mobile
 * @param numeric $widget_id
 * @return string
 */
add_filter(
    'inc2734_wp_awesome_widgets_carousel_image_size',
    function( $image_size, $is_mobile, $widget_id ) {
        return $image_size;
    },
    10,
    3
);

inc2734_wp_awesome_widgets_any_posts_widget_args

/**
 * Customize any posts widget args
 *
 * @param array $query_args
 * @return array
 */
add_filter(
    'inc2734_wp_awesome_widgets_any_posts_widget_args',
    function( $query_args ) {
        return $query_args;
    }
);

inc2734_wp_awesome_widgets_any_posts_widget_args_<$widget_number>

/**
 * Customize specific any posts widget args
 *
 * @param array $query_args
 * @return array
 */
add_filter(
    'inc2734_wp_awesome_widgets_any_posts_widget_args_' . $widget_number,
    function( $query_args ) {
        return $query_args;
    }
);

inc2734_wp_awesome_widgets_showcase_backgroud_image_size

/**
 * Customize showcase widget background image size
 *
 * @param string $image_size
 * @param boolean $is_mobile
 * @param numeric $widget_id
 * @return string
 */
add_filter(
    'inc2734_wp_awesome_widgets_showcase_backgroud_image_size',
    function( $image_size, $is_mobile, $widget_id ) {
        return $image_size;
    },
    10,
    3
);

inc2734_wp_awesome_widgets_showcase_image_size

/**
 * Customize showcase widget image size
 *
 * @param string $image_size
 * @param boolean $is_mobile
 * @param numeric $widget_id
 * @return string
 */
add_filter(
    'inc2734_wp_awesome_widgets_showcase_image_size',
    function( $image_size, $is_mobile, $widget_id ) {
        return $image_size;
    },
    10,
    3
);

inc2734_wp_awesome_widgets_widget_templates

/**
 * Customize custom widget template slug (directory)
 *
 * @param string $slug
 * @return string
 */
add_filter(
    'inc2734_wp_awesome_widgets_widget_templates',
    function( $slug ) {
        return $slug;
    }
);

inc2734_wp_awesome_widgets_render_widget

/**
 * Customzie widget html
 *
 * @param string $html
 * @param array $widget_args
 * @param array $instance
 * @return string
 */
add_filter(
    'inc2734_wp_awesome_widgets_render_widget',
    function( $html, $widget_args, $instance ) {
        return $html;
    },
    10,
    3
);

inc2734_wp_awesome_widgets_taxonomy_posts_widget_args

/**
 * Customzize taxonomy posts widget args
 *
 * @param array $query_args
 * @return array
 */
add_filter(
    'inc2734_wp_awesome_widgets_taxonomy_posts_widget_args',
    function( $query_args ) {
        return $query_args;
    }
);

inc2734_wp_awesome_widgets_taxonomy_posts_widget_args_<$widget_number>

/**
 * Customize specific taxonomy posts widget args
 *
 * @param array $query_args
 * @return array
 */
add_filter(
    'inc2734_wp_awesome_widgets_taxonomy_posts_widget_args_' . $widget_number,
    function( $query_args ) {
        return $query_args;
    }
);

inc2734_wp_awesome_widgets_pickup_slider_widget_args

/**
 * Customize pickup slider widget args
 *
 * @param array $query_args
 * @return array
 */
add_filter(
    'inc2734_wp_awesome_widgets_pickup_slider_widget_args',
    function( $query_args ) {
        return $query_args;
    }
);

inc2734_wp_awesome_widgets_pickup_slider_widget_args_<$widget_number>

/**
 * Customize specific pickup slider widget args
 *
 * @param array $query_args
 * @return array
 */
add_filter(
    'inc2734_wp_awesome_widgets_pickup_slider_widget_args_' . $widget_number,
    function( $query_args ) {
        return $query_args;
    }
);

inc2734_wp_awesome_widgets_pickup_slider_image_size

/**
 * Customize pickup slider widget image size
 *
 * @param string $image_size
 * @param boolean $is_mobile
 * @param numeric widget_id
 * @return string
 */
add_filter(
    'inc2734_wp_awesome_widgets_pickup_slider_image_size',
    function( $image_size, $is_mobile, $widget_id ) {
        return $image_size;
    },
    10,
    3
);

inc2734_wp_awesome_widgets_child_nav_args

/**
 * Customize child nav args
 *
 * @param array $query_args
 * @return array
 */
add_filter(
    'inc2734_wp_awesome_widgets_child_nav_args',
    function( $query_args ) {
        return $query_args;
    }
);

inc2734_wp_awesome_widgets_posts_list_image_size

/**
 * Customize posts list widget (recent posts, ranking any posts) image size
 *
 * @param string $image_size
 * @param boolean $is_mobile
 * @param numeric widget_id
 * @return string
 */
add_filter(
    'inc2734_wp_awesome_widgets_posts_list_image_size',
    function( $image_size, $is_mobile, $widget_id ) {
        return $image_size;
    },
    10,
    3
);

inc2734_wp_awesome_widgets_view_args

/**
 * @param array $args
 *  @var string $slug
 *  @var string $name
 *  @var array $vars
 * @param array
 */
add_filter(
    'inc2734_wp_awesome_widgets_view_args',
    function( $args ) {
        return $args;
    }
);

inc2734_wp_awesome_widgets_view_render

/**
 * @param string $html
 * @param string $slug
 * @param string $name
 * @param array $vars
 * @return string
 */
add_filter(
    'inc2734_wp_awesome_widgets_view_render',
    function( $html, $slug, $name, $vars ) {
        return $html;
    },
    10,
    4
);

Action hooks

inc2734_wp_awesome_widgets_before_admin_enqueue_scripts

inc2734_wp_awesome_widgets_after_admin_enqueue_scripts

inc2734_wp_awesome_widgets_view_pre_render

/**
 * @param array $args
 *  @var string $slug
 *  @var string $name
 *  @var array $vars
 */
add_action(
    'inc2734_wp_awesome_widgets_view_pre_render',
    function( $args ) {
    }
);

inc2734_wp_awesome_widgets_view_post_render

/**
 * @param array $args
 *  @var string $slug
 *  @var string $name
 *  @var array $vars
 */
add_action(
    'inc2734_wp_awesome_widgets_view_post_render',
    function( $args ) {
    }
);

inc2734_wp_awesome_widgets_view_<slug>

/**
 * @param string $name
 * @param array $vars
 */
add_action(
    'inc2734_wp_awesome_widgets_view_<slug>',
    function( $name, $vars ) {
        ?>
        HTML
        <?php
    },
    10,
    2
);

inc2734_wp_awesome_widgets_view_<slug>-<name>

/**
 * @param array $vars
 */
add_action(
    'inc2734_wp_awesome_widgets_view_<slug>-<name>',
    function( $vars ) {
        ?>
        HTML
        <?php
    }
);

Thirt-party resources

slick

http://kenwheeler.github.io/slick/, (*3)

The Versions

14/06 2018

2.2.2

2.2.2.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

24/05 2018

2.2.1

2.2.1.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

16/05 2018

2.2.0

2.2.0.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

14/05 2018

2.1.1

2.1.1.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

11/05 2018

2.1.0

2.1.0.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

11/05 2018

2.0.3

2.0.3.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

09/05 2018

2.0.2

2.0.2.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

08/05 2018

2.0.1

2.0.1.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

08/05 2018

2.0.0

2.0.0.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

02/05 2018

1.11.6

1.11.6.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

01/05 2018

1.11.5

1.11.5.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

28/04 2018

1.11.4

1.11.4.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

28/04 2018

1.11.3

1.11.3.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

24/04 2018

1.11.2

1.11.2.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

23/04 2018

1.11.1

1.11.1.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

23/04 2018

1.11.0

1.11.0.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

22/04 2018

1.10.2

1.10.2.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

09/03 2018

1.10.1

1.10.1.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

06/03 2018

1.10.0

1.10.0.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

04/03 2018

1.9.11

1.9.11.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

04/03 2018

1.9.10

1.9.10.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

04/03 2018

1.9.9

1.9.9.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

04/03 2018

1.9.8

1.9.8.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

28/02 2018

1.9.7

1.9.7.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

26/02 2018

1.9.6

1.9.6.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

17/02 2018

1.9.5

1.9.5.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

17/02 2018

1.9.4

1.9.4.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

14/02 2018

1.9.3

1.9.3.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

14/02 2018

1.9.2

1.9.2.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

14/02 2018

1.9.1

1.9.1.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

14/02 2018

1.9.0

1.9.0.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

11/02 2018

1.8.4

1.8.4.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

08/02 2018

1.8.3

1.8.3.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

07/02 2018

1.8.2

1.8.2.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

07/02 2018

1.8.1

1.8.1.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

03/02 2018

1.8.0

1.8.0.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

02/02 2018

1.7.0

1.7.0.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

01/02 2018

1.6.1

1.6.1.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

29/01 2018

1.6.0

1.6.0.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

28/01 2018

1.5.1

1.5.1.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

26/01 2018

1.5.0

1.5.0.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

26/01 2018

1.4.0

1.4.0.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0-or-later

The Requires

 

The Development Requires

27/12 2017
11/12 2017

1.3.3

1.3.3.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

28/11 2017

1.3.2

1.3.2.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

28/11 2017

1.3.1

1.3.1.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

22/11 2017

1.3.0

1.3.0.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

17/11 2017

1.2.1

1.2.1.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

14/11 2017

1.2.0

1.2.0.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

09/11 2017

dev-inc2734-patch-1

dev-inc2734-patch-1

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

17/10 2017

1.1.0

1.1.0.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

12/10 2017

1.0.5

1.0.5.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

06/10 2017

1.0.4

1.0.4.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

06/10 2017

1.0.3

1.0.3.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

02/10 2017

1.0.2

1.0.2.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

02/10 2017

1.0.1

1.0.1.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

30/09 2017

1.0.0

1.0.0.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

27/09 2017

0.4.6

0.4.6.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

27/09 2017

0.4.5

0.4.5.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

27/09 2017

0.4.4

0.4.4.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

22/09 2017

0.4.3

0.4.3.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

11/09 2017

0.4.2

0.4.2.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

01/09 2017

0.4.1

0.4.1.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

01/09 2017

0.4.0

0.4.0.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

29/08 2017

0.3.2

0.3.2.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

29/08 2017

0.3.1

0.3.1.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

27/08 2017

0.3.0

0.3.0.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

23/08 2017

0.2.2

0.2.2.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

15/08 2017

0.2.1

0.2.1.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

10/08 2017

0.2.0

0.2.0.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

 

The Development Requires

09/08 2017

0.1.1

0.1.1.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.6

 

The Development Requires

08/08 2017

0.1.0

0.1.0.0

A library to add some awesome widgets for WordPress.

  Sources   Download

GPL-2.0+

The Requires

  • php >=5.6

 

The Development Requires