Plugin Directory

Changeset 1745800


Ignore:
Timestamp:
10/13/2017 06:54:03 AM (8 years ago)
Author:
codetic
Message:

compatibility fixed with Cornerstone 2.1.x and Post Grid element added

Location:
essential-addons-for-cornerstone-lite
Files:
100 added
1 deleted
25 edited

Legend:

Unmodified
Added
Removed
  • essential-addons-for-cornerstone-lite/trunk/README.txt

    r1740132 r1745800  
    55Requires at least: 4.5
    66Tested up to: 4.8.2
    7 Stable tag: 1.2
     7Stable tag: 1.3.0
    88License: GPLv3 or later
    99License URI: https://www.gnu.org/licenses/gpl-3.0.en.html
     
    1717 <a href="https://essential-addons.com/cornerstone/" rel="nofollow">Check the demos</a>
    1818
     19
     20### Now 100% Compatible with Cornerstone 2.1.x and Pro 1.2.x
     21
    1922### Features
    20 * 6+ Elements
     23* 7+ Free Elements
    2124* Fully Customizable
    2225* Unlimited Design Options
     
    2528### Available Elements
    2629
     30
     31* <a href="https://essential-addons.com/cornerstone/post-grid/">Post Grid (Masonry)</a>
    2732* <a href="https://essential-addons.com/cornerstone/logo-carousel/">Logo Carousel</a>
    2833* <a href="https://essential-addons.com/cornerstone/post-carousel/">Post Carousel</a>
     
    4348* <a href="https://essential-addons.com/cornerstone/responsive-lightbox/">Responsive Lightbox & Modal</a>
    4449* <a href="https://essential-addons.com/cornerstone/post-block/">Post Block (Flex)</a>
    45 * <a href="https://essential-addons.com/cornerstone/post-grid/">Post Grid (Masonry)</a>
    4650
    4751== Installation ==
     
    7377== Changelog ==
    7478
     79= 1.3.0 =
     80
     81* Compatibility fixed with Cornerstone 2.1.x and Pro 1.2.x
     82* Post Grid element added
     83* Post Carousel element improved and lots of options added
     84* Lots of improvement and bugfix
     85
     86
    7587= 1.2 =
    7688* Options Panel improved
  • essential-addons-for-cornerstone-lite/trunk/admin/assets/css/admin.css

    r1740132 r1745800  
    286286}
    287287
    288 
     288.eacs-settings-tab img.eacs-logo-admin {
     289    padding: 50px 0;
     290    max-width: 500px;
     291    margin: 0 auto;
     292    display: block;
     293}
     294
     295.row.general-row {
     296    padding: 20px;
     297}
     298
  • essential-addons-for-cornerstone-lite/trunk/admin/assets/js/admin.js

    r1737068 r1745800  
    2929
    3030        var logoCarousel        = $( '#logo-carousel' ).attr( 'checked' ) ? 1 : 0;
    31         var logoCarouselItem    = $( '#logo-carousel-item' ).attr( 'checked' ) ? 1 : 0;
     31        var postGrid            = $( '#post-grid' ).attr( 'checked' ) ? 1 : 0;
    3232        var postCarousel        = $( '#post-carousel' ).attr( 'checked' ) ? 1 : 0;
    3333        var productCarousel     = $( '#product-carousel' ).attr( 'checked' ) ? 1 : 0;
    3434        var productGrid         = $( '#product-grid' ).attr( 'checked' ) ? 1 : 0;
    3535        var teamMembers         = $( '#team-members' ).attr( 'checked' ) ? 1 : 0;
    36         var teamMembersItem     = $( '#team-members-item' ).attr( 'checked' ) ? 1 : 0;
    37         var testimonialItem     = $( '#testimonial-item' ).attr( 'checked' ) ? 1 : 0;
    3836        var testimonialSlider   = $( '#testimonial-slider' ).attr( 'checked' ) ? 1 : 0;
    3937
     
    4442                action: 'save_settings_with_ajax',
    4543                logoCarousel: logoCarousel,
    46                 logoCarouselItem: logoCarouselItem,
     44                postGrid: postGrid,
    4745                postCarousel: postCarousel,
    4846                productCarousel: productCarousel,
    4947                productGrid: productGrid,
    5048                teamMembers: teamMembers,
    51                 teamMembersItem: teamMembersItem,
    52                 testimonialItem: testimonialItem,
    5349                testimonialSlider: testimonialSlider,
    5450            },
  • essential-addons-for-cornerstone-lite/trunk/admin/settings.php

    r1740132 r1745800  
    1010    private $eacs_default_settings = array(
    1111       'logo-carousel'      => true,
     12       'post-grid'          => true,
    1213       'post-carousel'      => true,
     14       'product-grid'       => true,
    1315       'product-carousel'   => true,
    1416       'product-grid'       => true,
     
    113115                    </ul>
    114116                    <div id="general" class="eacs-settings-tab">
    115                         <div class="row">
    116                             <div class="col-half">
    117 
    118                                 <img src="<?php echo plugins_url( '/', __FILE__ ).'assets/images/eacs-featured.jpg'; ?>">
    119                             </div>
     117                        <div class="row general-row">
     118
    120119                            <div class="col-half">
    121120                                <a href="https://essential-addons.com/cornerstone/" target="_blank" class="button eacs-btn eacs-demo-btn">Explore Demos</a>
    122                                 <a href="https://essential-addons.com/cornerstone/buy.php" target="_blank" class="button eacs-btn eacs-license-btn">Get Pro License</a>
     121                                <a href="https://essential-addons.com/cornerstone/buy.php" target="_blank" class="button eacs-btn eacs-license-btn">Update to Premium</a>
    123122
    124123                                <div class="eacs-notice">
     
    127126                                </div>
    128127                            </div>
     128                            <div class="col-half">
     129
     130                                <img class="eacs-logo-admin" src="<?php echo plugins_url( '/', __FILE__ ).'assets/images/eacs-logo.png'; ?>">
     131                            </div>
    129132                        </div>
    130133                    </div>
     
    136139                                        <td>
    137140                                            <div class="eacs-checkbox">
     141                                                <p class="title"><?php _e( 'Post Grid', 'essential-addons-cs' ); ?></p>
     142                                                <p class="desc"><?php _e( 'Activate / Deactivate Post Grid', 'essential-addons-cs' ); ?></p>
     143                                        <input type="checkbox" id="post-grid" name="post-grid" <?php checked( 1, $this->eacs_get_settings['post-grid'], true ); ?> >
     144                                        <label for="post-grid"></label>
     145                                        </div>
     146                                        </td>
     147                                        <td>
     148                                            <div class="eacs-checkbox">
    138149                                                <p class="title"><?php _e( 'Logo Carousel', 'essential-addons-cs' ); ?></p>
    139                                                 <p class="desc"><?php _e( 'Activate / Deactive Logo Carousel', 'essential-addons-cs' ); ?></p>
     150                                                <p class="desc"><?php _e( 'Activate / Deactivate Logo Carousel', 'essential-addons-cs' ); ?></p>
    140151                                        <input type="checkbox" id="logo-carousel" name="logo-carousel" <?php checked( 1, $this->eacs_get_settings['logo-carousel'], true ); ?> >
    141152                                        <label for="logo-carousel"></label>
     
    145156                                            <div class="eacs-checkbox">
    146157                                                <p class="title"><?php _e( 'Post Carousel', 'essential-addons-cs' ); ?></p>
    147                                                 <p class="desc"><?php _e( 'Activate / Deactive Post Carousel', 'essential-addons-cs' ); ?></p>
     158                                                <p class="desc"><?php _e( 'Activate / Deactivate Post Carousel', 'essential-addons-cs' ); ?></p>
    148159                                        <input type="checkbox" id="post-carousel" name="post-carousel" <?php checked( 1, $this->eacs_get_settings['post-carousel'], true ); ?> >
    149160                                        <label for="post-carousel"></label>
     
    153164                                            <div class="eacs-checkbox">
    154165                                                <p class="title"><?php _e( 'Product Carousel', 'essential-addons-cs' ) ?></p>
    155                                                 <p class="desc"><?php _e( 'Activate / Deactive Product Carousel', 'essential-addons-cs' ); ?></p>
     166                                                <p class="desc"><?php _e( 'Activate / Deactivate Product Carousel', 'essential-addons-cs' ); ?></p>
    156167                                        <input type="checkbox" id="product-carousel" name="product-carousel" <?php checked( 1, $this->eacs_get_settings['product-carousel'], true ); ?> >
    157168                                        <label for="product-carousel"></label>
     
    163174                                            <div class="eacs-checkbox">
    164175                                                <p class="title"><?php _e( 'Team Members', 'essential-addons-cs' ) ?></p>
    165                                                 <p class="desc"><?php _e( 'Activate / Deactive Team Members', 'essential-addons-cs' ); ?></p>
     176                                                <p class="desc"><?php _e( 'Activate / Deactivate Team Members', 'essential-addons-cs' ); ?></p>
    166177                                        <input type="checkbox" id="team-members" name="team-members" <?php checked( 1, $this->eacs_get_settings['team-members'], true ); ?> >
    167178                                        <label for="team-members"></label>
     
    171182                                            <div class="eacs-checkbox">
    172183                                                <p class="title"><?php _e( 'Testimonial Slider', 'essential-addons-cs' ) ?></p>
    173                                                 <p class="desc"><?php _e( 'Activate / Deactive Testimonial Slider', 'essential-addons-cs' ); ?></p>
     184                                                <p class="desc"><?php _e( 'Activate / Deactivate Testimonial Slider', 'essential-addons-cs' ); ?></p>
    174185                                        <input type="checkbox" id="testimonial-slider" name="testimonial-slider" <?php checked( 1, $this->eacs_get_settings['testimonial-slider'], true ); ?> >
    175186                                        <label for="testimonial-slider"></label>
     
    179190                                            <div class="eacs-checkbox">
    180191                                                <p class="title"><?php _e( 'Product Grid', 'essential-addons-cs' ) ?></p>
    181                                                 <p class="desc"><?php _e( 'Activate / Deactive Product Grid', 'essential-addons-cs' ); ?></p>
     192                                                <p class="desc"><?php _e( 'Activate / Deactivate Product Grid', 'essential-addons-cs' ); ?></p>
    182193                                        <input type="checkbox" id="product-grid" name="product-grid" <?php checked( 1, $this->eacs_get_settings['product-grid'], true ); ?> >
    183194                                        <label for="product-grid"></label>
     
    197208                                            <div class="eacs-checkbox">
    198209                                                <p class="title"><?php _e( 'Count Down', 'essential-addons-cs' ); ?></p>
    199                                                 <p class="desc"><?php _e( 'Activate / Deactive Count Down', 'essential-addons-cs' ); ?></p>
     210                                                <p class="desc"><?php _e( 'Activate / Deactivate Count Down', 'essential-addons-cs' ); ?></p>
    200211                                        <input type="checkbox" id="count-down" name="count-down" disabled >
    201212                                        <label for="count-down" class="<?php if( (bool) $is_pro === false ) : echo 'eacs-get-pro'; endif; ?>"></label>
     
    205216                                            <div class="eacs-checkbox">
    206217                                                <p class="title"><?php _e( 'Creative Button', 'essential-addons-cs' ); ?></p>
    207                                                 <p class="desc"><?php _e( 'Activate / Deactive Creative Button', 'essential-addons-cs' ); ?></p>
     218                                                <p class="desc"><?php _e( 'Activate / Deactivate Creative Button', 'essential-addons-cs' ); ?></p>
    208219                                        <input type="checkbox" id="creative-btn" name="creative-btn" disabled >
    209220                                        <label for="creative-btn" class="<?php if( (bool) $is_pro === false ) : echo 'eacs-get-pro'; endif; ?>"></label>
     
    213224                                            <div class="eacs-checkbox">
    214225                                                <p class="title"><?php _e( 'Image Comparison', 'essential-addons-cs' ); ?></p>
    215                                                 <p class="desc"><?php _e( 'Activate / Deactive Image Comparison', 'essential-addons-cs' ); ?></p>
     226                                                <p class="desc"><?php _e( 'Activate / Deactivate Image Comparison', 'essential-addons-cs' ); ?></p>
    216227                                        <input type="checkbox" id="img-comparison" name="img-comparison" disabled >
    217228                                        <label for="img-comparison" class="<?php if( (bool) $is_pro === false ) : echo 'eacs-get-pro'; endif; ?>"></label>
     
    221232                                            <div class="eacs-checkbox">
    222233                                                <p class="title"><?php _e( 'Instagram Feed', 'essential-addons-cs' ); ?></p>
    223                                                 <p class="desc"><?php _e( 'Activate / Deactive Instagram Feed', 'essential-addons-cs' ); ?></p>
     234                                                <p class="desc"><?php _e( 'Activate / Deactivate Instagram Feed', 'essential-addons-cs' ); ?></p>
    224235                                        <input type="checkbox" id="instagram-feed" name="instagram-feed" disabled >
    225236                                        <label for="instagram-feed" class="<?php if( (bool) $is_pro === false ) : echo 'eacs-get-pro'; endif; ?>"></label>
     
    229240                                            <div class="eacs-checkbox">
    230241                                                <p class="title"><?php _e( 'Interactive Promo', 'essential-addons-cs' ); ?></p>
    231                                                 <p class="desc"><?php _e( 'Activate / Deactive Interactive Promo', 'essential-addons-cs' ); ?></p>
     242                                                <p class="desc"><?php _e( 'Activate / Deactivate Interactive Promo', 'essential-addons-cs' ); ?></p>
    232243                                        <input type="checkbox" id="interactive-promo" name="interactive-promo" disabled >
    233244                                        <label for="interactive-promo" class="<?php if( (bool) $is_pro === false ) : echo 'eacs-get-pro'; endif; ?>"></label>
     
    239250                                            <div class="eacs-checkbox">
    240251                                                <p class="title"><?php _e( 'Lightbox', 'essential-addons-cs' ); ?></p>
    241                                                 <p class="desc"><?php _e( 'Activate / Deactive Lightbox', 'essential-addons-cs' ); ?></p>
     252                                                <p class="desc"><?php _e( 'Activate / Deactivate Lightbox', 'essential-addons-cs' ); ?></p>
    242253                                        <input type="checkbox" id="lightbox" name="lightbox" disabled >
    243254                                        <label for="lightbox" class="<?php if( (bool) $is_pro === false ) : echo 'eacs-get-pro'; endif; ?>"></label>
     
    247258                                            <div class="eacs-checkbox">
    248259                                                <p class="title"><?php _e( 'Post Block', 'essential-addons-cs' ); ?></p>
    249                                                 <p class="desc"><?php _e( 'Activate / Deactive Post Block', 'essential-addons-cs' ); ?></p>
     260                                                <p class="desc"><?php _e( 'Activate / Deactivate Post Block', 'essential-addons-cs' ); ?></p>
    250261                                        <input type="checkbox" id="post-block" name="post-block" disabled >
    251262                                        <label for="post-block" class="<?php if( (bool) $is_pro === false ) : echo 'eacs-get-pro'; endif; ?>"></label>
     
    254265                                        <td>
    255266                                            <div class="eacs-checkbox">
    256                                                 <p class="title"><?php _e( 'Post Grid', 'essential-addons-cs' ); ?></p>
    257                                                 <p class="desc"><?php _e( 'Activate / Deactive Post Grid', 'essential-addons-cs' ); ?></p>
    258                                         <input type="checkbox" id="post-grid" name="post-grid" disabled >
    259                                         <label for="post-grid" class="<?php if( (bool) $is_pro === false ) : echo 'eacs-get-pro'; endif; ?>"></label>
    260                                         </div>
    261                                         </td>
    262                                         <td>
    263                                             <div class="eacs-checkbox">
    264267                                                <p class="title"><?php _e( 'Post Timeline', 'essential-addons-cs' ); ?></p>
    265                                                 <p class="desc"><?php _e( 'Activate / Deactive Post Timeline', 'essential-addons-cs' ); ?></p>
     268                                                <p class="desc"><?php _e( 'Activate / Deactivate Post Timeline', 'essential-addons-cs' ); ?></p>
    266269                                        <input type="checkbox" id="post-timeline" name="post-timeline" disabled >
    267270                                        <label for="post-timeline" class="<?php if( (bool) $is_pro === false ) : echo 'eacs-get-pro'; endif; ?>"></label>
     
    271274                                            <div class="eacs-checkbox">
    272275                                                <p class="title"><?php _e( 'Social Icons', 'essential-addons-cs' ); ?></p>
    273                                                 <p class="desc"><?php _e( 'Activate / Deactive Social Icons', 'essential-addons-cs' ); ?></p>
     276                                                <p class="desc"><?php _e( 'Activate / Deactivate Social Icons', 'essential-addons-cs' ); ?></p>
    274277                                        <input type="checkbox" id="social-icons" name="social-icons" disabled >
    275278                                        <label for="social-icons" class="<?php if( (bool) $is_pro === false ) : echo 'eacs-get-pro'; endif; ?>"></label>
     
    339342            $this->eacs_settings = array(
    340343                'logo-carousel'         => intval( $_POST['logoCarousel'] ? 1 : 0 ),
     344                'post-grid'             => intval( $_POST['postGrid'] ? 1 : 0 ),
    341345                'post-carousel'         => intval( $_POST['postCarousel'] ? 1 : 0 ),
    342                 'product-carousel'  => intval( $_POST['productCarousel'] ? 1 : 0 ),
    343                 'product-grid'      => intval( $_POST['productGrid'] ? 1 : 0 ),
    344                 'team-members'      => intval( $_POST['teamMembers'] ? 1 : 0 ),
    345                 'testimonial-slider' => intval( $_POST['testimonialSlider'] ? 1 : 0 ),
     346                'product-carousel'      => intval( $_POST['productCarousel'] ? 1 : 0 ),
     347                'product-grid'          => intval( $_POST['productGrid'] ? 1 : 0 ),
     348                'team-members'          => intval( $_POST['teamMembers'] ? 1 : 0 ),
     349                'testimonial-slider'    => intval( $_POST['testimonialSlider'] ? 1 : 0 ),
    346350            );
    347351            update_option( 'eacs_save_settings', $this->eacs_settings );
  • essential-addons-for-cornerstone-lite/trunk/assets/styles/essential-addons-cs.css

    r1670744 r1745800  
    159159
    160160
     161/* Responsive Styles / Common */
     162
     163@media only screen and (max-width: 400px) {
     164.eacs-testimonial-slider .slick-prev,
     165.eacs-team-slider .slick-prev,
     166.eacs-logo-carousel .slick-prev,
     167.eacs-post-carousel .slick-prev {
     168  left: -35px;
     169}
     170
     171.eacs-testimonial-slider .slick-next,
     172.eacs-team-slider .slick-next,
     173.eacs-logo-carousel .slick-next,
     174.eacs-post-carousel .slick-next {
     175  right: -35px;
     176}
     177
     178}
     179
     180
    161181/* Testimonial Slider Styles */
    162182
     
    164184
    165185.testimonial-avatar-disabled .eacs-testimonial-image {
    166     display: none;
     186  display: none;
    167187}
    168188
     
    850870}
    851871
    852 /* Responsive Styles / Common */
    853 
    854 @media only screen and (max-width: 400px) {
    855 .eacs-testimonial-slider .slick-prev,
    856 .eacs-team-slider .slick-prev,
    857 .eacs-logo-carousel .slick-prev,
    858 .eacs-post-carousel .slick-prev {
    859   left: -35px;
    860 }
    861 
    862 .eacs-testimonial-slider .slick-next,
    863 .eacs-team-slider .slick-next,
    864 .eacs-logo-carousel .slick-next,
    865 .eacs-post-carousel .slick-next {
    866   right: -35px;
    867 }
    868 
    869 }
    870 
     872
     873/* Post Grid Style */
     874
     875
     876.eacs-grid-post {
     877  float: left;
     878  padding: 10px;
     879}
     880
     881.eacs-grid-post-holder {
     882  border: 1px solid rgba(0,0,0,.1);
     883  overflow: hidden;
     884}
     885
     886.eacs-grid-post-holder-inner {
     887  height: 100%;
     888}
     889
     890.eacs-entry-media {
     891  position: relative;
     892}
     893
     894.eacs-entry-overlay {
     895  position: absolute;
     896  top: 0;
     897  left: 0;
     898  width: 100%;
     899  height: 100%;
     900  z-index: 999;
     901  opacity: 0;
     902  -webkit-transition: opacity .2s ease-in-out,-webkit-transform .25s cubic-bezier(.19,1,.22,1);
     903  -moz-transition: opacity .2s ease-in-out,-moz-transform .25s cubic-bezier(.19,1,.22,1);
     904  transition: opacity .2s ease-in-out,transform .25s cubic-bezier(.19,1,.22,1);
     905}
     906
     907.eacs-entry-overlay:hover {
     908  opacity: 1;
     909}
     910
     911
     912.eacs-entry-overlay > a {
     913  position: absolute;
     914  top: 0;
     915  left: 0;
     916  width: 100%;
     917  height: 100%;
     918  z-index: 99999;
     919}
     920
     921.eacs-entry-title {
     922  margin: 10px 0 5px;
     923  font-size: 1.2em;
     924}
     925
     926.eacs-entry-overlay i {
     927  color: #fff;
     928  width: 60px;
     929  text-align: center;
     930  line-height: 60px;
     931  height: 60px;
     932  position: absolute;
     933  left: 50%;
     934  margin-left: -30px;
     935  font-size: 32px;
     936  top: 50%;
     937  margin-top: -30px;
     938  -webkit-perspective: 1000;
     939  -moz-perspective: 1000;
     940  -ms-perspective: 1000;
     941  perspective: 1000;
     942  opacity: 0;
     943  -webkit-transform: translatex(-20px);
     944  -moz-transform: translatex(-20px);
     945  -ms-transform: translatex(-20px);
     946  transform: translatex(-20px);
     947  -webkit-transition: opacity .2s ease-in-out,-webkit-transform .25s cubic-bezier(.19,1,.22,1);
     948  -moz-transition: opacity .2s ease-in-out,-moz-transform .25s cubic-bezier(.19,1,.22,1);
     949  transition: opacity .2s ease-in-out,transform .25s cubic-bezier(.19,1,.22,1);
     950}
     951
     952.eacs-entry-media:hover .eacs-entry-overlay i {
     953  -webkit-transform: translatex(0px);
     954  -moz-transform: translatex(0px);
     955  -ms-transform: translatex(0px);
     956  transform: translatex(0px);
     957  opacity: 1;
     958}
     959
     960.eacs-entry-thumbnail img {
     961  width: 100%;
     962  max-width: 100%;
     963  vertical-align: middle;
     964}
     965
     966.eacs-grid-post-excerpt {
     967  padding-top: 5px;
     968}
     969
     970.eacs-entry-footer {
     971  display: flex;
     972  flex-flow: row nowrap;
     973  align-items: center;
     974}
     975
     976.eacs-entry-footer .eacs-author-avatar {
     977  flex: 0 0 auto;
     978  width: 50px;
     979}
     980
     981.eacs-entry-footer .eacs-author-avatar .avatar {
     982  border-radius: 50%;
     983}
     984
     985.eacs-post-grid .eacs-entry-footer  .eacs-entry-meta {
     986  padding-left: 8px;
     987}
     988
     989.eacs-entry-meta > div {
     990  font-size: 12px;
     991  line-height: 1.2;
     992  padding-bottom: 5px;
     993}
     994
     995.eacs-grid-post-excerpt p {
     996  margin: 0;
     997  font-size: 14px;
     998}
     999
     1000.eacs-entry-meta .eacs-entry-footer  .eacs-posted-by {
     1001  display: block;
     1002}
     1003
     1004.eacs-grid-post .eacs-entry-wrapper, .eacs-grid-post .eacs-entry-footer {
     1005  padding: 15px;
     1006}
     1007
     1008.eacs-post-grid .eacs-entry-header .eacs-entry-meta span.eacs-posted-on {
     1009  padding-left: 5px;
     1010}
     1011
     1012.eacs-post-grid .eacs-entry-header .eacs-entry-meta span.eacs-posted-on::before {
     1013  content: '\f111';
     1014  font-family: FontAwesome;
     1015  color: inherit;
     1016  opacity: .4;
     1017  font-size: .8em;
     1018  padding-right: 7px;
     1019}
     1020
     1021.fa-long-arrow-right::before {
     1022  content: "\f178";
     1023  font-family: FontAwesome;
     1024}
     1025
     1026/* Post Grid Column */
     1027
     1028.eacs-col-1 .eacs-post-grid-column {
     1029  float: none;
     1030  width: 100%;
     1031}
     1032.eacs-col-2 .eacs-post-grid-column{
     1033  float: left;
     1034  width: 50%;
     1035}
     1036.eacs-col-3 .eacs-post-grid-column {
     1037  float: left;
     1038  width: 33.3333%;
     1039}
     1040.eacs-col-4 .eacs-post-grid-column {
     1041  float: left;
     1042  width: 25%;
     1043}
     1044.eacs-col-5 .eacs-post-grid-column {
     1045  float: left;
     1046  width: 20%;
     1047}
     1048.eacs-col-6 .eacs-post-grid-column {
     1049  float: left;
     1050  width: 16.6666%;
     1051}
     1052
     1053/* Responsive Styles for Post Grid */
     1054
     1055@media only screen and (max-width: 979px) {
     1056.eacs-col-1 .eacs-post-grid-column, .eacs-col-2 .eacs-post-grid-column,
     1057.eacs-col-3 .eacs-post-grid-column, .eacs-col-4 .eacs-post-grid-column,
     1058.eacs-col-5 .eacs-post-grid-column, .eacs-col-6 .eacs-post-grid-column {
     1059  width: 33.3333%;
     1060}
     1061}
     1062
     1063@media only screen and (max-width: 767px) {
     1064.eacs-col-1 .eacs-post-grid-column, .eacs-col-2 .eacs-post-grid-column,
     1065.eacs-col-3 .eacs-post-grid-column, .eacs-col-4 .eacs-post-grid-column,
     1066.eacs-col-5 .eacs-post-grid-column, .eacs-col-6 .eacs-post-grid-column {
     1067  width: 50%;
     1068}
     1069}
     1070
     1071@media only screen and (max-width: 480px) {
     1072.eacs-col-1 .eacs-post-grid-column, .eacs-col-2 .eacs-post-grid-column,
     1073.eacs-col-3 .eacs-post-grid-column, .eacs-col-4 .eacs-post-grid-column,
     1074.eacs-col-5 .eacs-post-grid-column, .eacs-col-6 .eacs-post-grid-column {
     1075  float: none;
     1076  width: 100%;
     1077}
     1078}
     1079
     1080/* alignment */
     1081
     1082.eacs-post-align-left, .eacs-post-align-left .eacs-entry-header {
     1083  text-align: left;
     1084}
     1085.eacs-post-align-centered, .eacs-post-align-centered .eacs-entry-header {
     1086  text-align: center;
     1087}
     1088
     1089.eacs-post-align-right, .eacs-post-align-right .eacs-entry-header {
     1090  text-align: right;
     1091}
     1092
     1093.eacs-post-align-left .eacs-entry-footer {
     1094  justify-content: flex-start;
     1095}
     1096.eacs-post-align-centered .eacs-entry-footer {
     1097  justify-content: center;
     1098}
     1099.eacs-post-align-right .eacs-entry-footer {
     1100  justify-content: flex-end;
     1101}
  • essential-addons-for-cornerstone-lite/trunk/essential_addons_cs.php

    r1740132 r1745800  
    66Author: Codetic
    77Author URI: http://www.codetic.net/
    8 Version: 1.2
     8Version: 1.3.0
    99Text Domain: essential-addons-cs
    1010*/
     
    2323       'logo-carousel'      => true,
    2424       'logo-carousel-item' => true,
     25       'post-grid'          => true,
    2526       'post-carousel'      => true,
    2627       'product-carousel'   => true,
     
    4445        cornerstone_register_element( 'EACS_Team_Item', 'eacs-team-item', ESSENTIAL_ADDONS_CS_PATH . 'includes/team-members-item' );
    4546    }
     47    if( $is_component_active['post-grid'] ) {
     48        cornerstone_register_element( 'EACS_Post_Grid', 'eacs-post-grid', ESSENTIAL_ADDONS_CS_PATH . 'includes/post-grid' );
     49    }
    4650    if( $is_component_active['post-carousel'] ) {
    4751        cornerstone_register_element( 'EACS_Post_Carousel', 'eacs-post-carousel', ESSENTIAL_ADDONS_CS_PATH . 'includes/post-carousel' );
     
    5963    if( $is_component_active['logo-carousel'] || $is_component_active['post-carousel'] || $is_component_active['team-members'] || $is_component_active['testimonial-slider'] ) {
    6064        wp_enqueue_script( 'essential_addons_cs-slick-js', ESSENTIAL_ADDONS_CS_URL . 'assets/slick/slick.min.js', array('jquery'), null, true );
     65    }   
     66    if( $is_component_active['post-grid'] ) {
     67        wp_enqueue_script( 'essential_addons_cs-masonry-js', ESSENTIAL_ADDONS_CS_URL . 'assets/js/masonry.min.js', array('jquery'), null, true );
    6168    }
    6269    wp_enqueue_style( 'essential_addons_cs-styles', ESSENTIAL_ADDONS_CS_URL . 'assets/styles/essential-addons-cs.css', array(), '1.0.0' );
  • essential-addons-for-cornerstone-lite/trunk/includes/logo-carousel-item/definition.php

    r1670744 r1745800  
    1919    }
    2020
    21     // public function update_build_shortcode_atts( $atts, $parent ) {
    22 
    23     //  if ( ! is_null( $parent ) ) {
    24     //      $atts['linked'] = $parent['linked'];
    25     //  }
    26 
    27     //  return $atts;
    28 
    29     // }
    30 
    3121
    3222}
  • essential-addons-for-cornerstone-lite/trunk/includes/logo-carousel/defaults.php

    r1670744 r1745800  
    1313    'max_visible_items_mobile' => 2,
    1414    'slide_to_scroll'   => 1,
    15     'auto_play'         => false,
    16     'loop'              => false,
     15    'auto_play'         => true,
     16    'loop'              => true,
    1717    'pause_hover'       => false,
    1818    'draggable'         => true,
  • essential-addons-for-cornerstone-lite/trunk/includes/logo-carousel/definition.php

    r1670744 r1745800  
    1616
    1717    public function flags() {
    18         // dynamic_child allows child elements to render individually, but may cause
    19         // styling or behavioral issues in the page builder depending on how your
    20         // shortcodes work. If you have trouble with element presentation, try
    21         // removing this flag.
    2218        return array(
    23             'dynamic_child' => false
     19
     20            // dynamic_child allows child elements to render individually, but may cause
     21            // styling or behavioral issues in the page builder depending on how your
     22            // shortcodes work. If you have trouble with element presentation, try
     23            // removing this flag.
     24            'dynamic_child' => true,
     25
     26            // Add this in addition to dynamic_child to trigger child preview renders
     27            // when parent attributes are updated.
     28            'linked_child' => true
    2429        );
    2530    }
  • essential-addons-for-cornerstone-lite/trunk/includes/logo-carousel/shortcode.php

    r1670744 r1745800  
    8686    <?php echo do_shortcode( $content ); ?>
    8787  </div>
    88 </div>
    89 
    90 
     88 
    9189<script type="text/javascript">
    9290
    9391  jQuery(document).ready(function($) {
    94     $("<?= '#'.$logo_carousel_id ?>").slick({
    95       autoplay: <?= $auto_play ?>,
    96       infinite: <?= $loop ?>,
    97       slidesToShow: <?= $max_visible_items ?>,
    98       slidesToScroll: <?= $slide_to_scroll ?>,
    99       arrows: <?= $nav ?>,
    100       dots: <?= $dots ?>,
    101       pauseOnHover: <?= $pause_hover ?>,
    102       draggable: <?= $draggable ?>,
    103       variableWidth: <?= $variable_width ?>,
    104       responsive: [
    105     {
    106       breakpoint: 1024,
    107       settings: {
    108         slidesToShow: <?= $max_visible_items_tablet ?>,
    109         slidesToScroll: 1
    110       }
    111     },
    112     {
    113       breakpoint: 768,
    114       settings: {
    115         slidesToShow: <?= $max_visible_items_mobile ?>,
    116         slidesToScroll: 1
    117       }
     92
     93    function createLogoCarousel() {
     94
     95      $("<?= '#'.$logo_carousel_id ?>").not('.slick-initialized').slick({
     96        autoplay: <?= $auto_play ?>,
     97        infinite: <?= $loop ?>,
     98        slidesToShow: <?= $max_visible_items ?>,
     99        slidesToScroll: <?= $slide_to_scroll ?>,
     100        arrows: <?= $nav ?>,
     101        dots: <?= $dots ?>,
     102        pauseOnHover: <?= $pause_hover ?>,
     103        draggable: <?= $draggable ?>,
     104        variableWidth: <?= $variable_width ?>,
     105        responsive: [
     106            {
     107              breakpoint: 1024,
     108              settings: {
     109                slidesToShow: <?= $max_visible_items_tablet ?>,
     110                slidesToScroll: 1
     111              }
     112            },
     113            {
     114              breakpoint: 768,
     115              settings: {
     116                slidesToShow: <?= $max_visible_items_mobile ?>,
     117                slidesToScroll: 1
     118              }
     119            }
     120          ]
     121      });
    118122    }
    119   ]
    120     });
     123
     124  createLogoCarousel();
     125
     126  $(window).on( 'resize', createLogoCarousel );
     127
    121128  });
    122129</script>
     130</div>
    123131
    124132<style type="text/css">
  • essential-addons-for-cornerstone-lite/trunk/includes/post-carousel/controls.php

    r1670744 r1745800  
    4444    ),
    4545
     46    // Excerpt length
     47
     48    'excerpt_length' => array(
     49        'type'    => 'number',
     50        'ui' => array(
     51            'title'   => __( 'Excerpt Length', 'essential-addons-cs' ),
     52            'tooltip' => __( 'Enter the number of words you want to show as excerpts', 'essential-addons-cs' ),
     53        ),
     54        'condition' => array(
     55      'show_excerpt' => true
     56    ),
     57    'suggest' => __( '20', 'essential-addons-cs' ),
     58    ),
     59
    4660    // Hide Featured Image
    4761
     
    5468    ),
    5569
     70
     71    // Hide Meta
     72
     73    'hide_post_meta' => array(
     74        'type'    => 'toggle',
     75        'ui' => array(
     76            'title'   => __( 'Hide Meta Info', 'essential-addons-cs' ),
     77            'tooltip' => __( 'Hide or Show post meta information', 'essential-addons-cs' ),
     78        )
     79    ),
     80
     81    // Meta Position
     82
     83    'meta_position' => array(
     84        'type' => 'select',
     85        'ui'   => array(
     86            'title' => __( 'Meta Position', 'essential-addons-cs' ),
     87      'tooltip' => __( 'Choose where to display meta info', 'essential-addons-cs' ),
     88        ),
     89        'options' => array(
     90            'choices' => array(
     91        array( 'value' => 'entry-header',        'label' => __( 'Entry Header', 'essential-addons-cs' ) ),
     92        array( 'value' => 'entry-footer',    'label' => __( 'Entry Footer', 'essential-addons-cs' ) )
     93      ),
     94        ),
     95        'condition' => array(
     96      'hide_post_meta' => false
     97    ),
     98    ),
    5699
    57100    // Offset
     
    273316    ),
    274317
     318
     319    //
     320    // Text Align
     321    //
     322
     323    'post_alignment' => array(
     324        'type' => 'choose',
     325        'ui' => array(
     326            'title' => __( 'Set Alignment', 'essential-addons-cs' ),
     327            'tooltip' =>__( 'Set a alignment for the text and image',  'essential-addons-cs' ),
     328        ),
     329        'options' => array(
     330            'columns' => '4',
     331            'offValue' => '',
     332            'choices' => array(
     333                array( 'value' => 'eacs-post-align-default', 'icon' => fa_entity( 'ban' ),    'tooltip' => __( 'Default', 'essential-addons-cs' ) ),
     334                array( 'value' => 'eacs-post-align-left', 'icon' => fa_entity( 'align-left' ),    'tooltip' => __( 'Left', 'essential-addons-cs' ) ),
     335                array( 'value' => 'eacs-post-align-centered', 'icon' => fa_entity( 'align-center' ),  'tooltip' => __( 'Center', 'essential-addons-cs' ) ),
     336                array( 'value' => 'eacs-post-align-right', 'icon' => fa_entity( 'align-right' ),   'tooltip' => __( 'Right', 'essential-addons-cs' ) )
     337            )
     338        )
     339    ),
     340
     341    // Post Background Color
     342
     343
     344    'post_background_color' => array(
     345        'type' => 'color',
     346        'ui' => array(
     347            'title'   => __( 'Post Background Color)', 'essential-addons-cs' ),
     348            'tooltip' => __( 'Set background color for post', 'essential-addons-cs' ),
     349        )
     350    ),
     351
     352    // Thumbnail Overlay color
     353
     354
     355    'thumbnail_overlay_color' => array(
     356        'type' => 'color',
     357        'ui' => array(
     358            'title'   => __( 'Thumbnail Overlay Color', 'essential-addons-cs' ),
     359            'tooltip' => __( 'Set overlay color that will show on hover', 'essential-addons-cs' ),
     360        )
     361    ),
     362
     363    // Post Title Color
     364
     365
     366    'post_title_color' => array(
     367        'type' => 'color',
     368        'ui' => array(
     369            'title'   => __( 'Post Title Color', 'essential-addons-cs' ),
     370            'tooltip' => __( 'Set Post Title Color', 'essential-addons-cs' ),
     371        )
     372    ),
     373
     374    // Post Title hover Color
     375
     376
     377    'post_title_hover_color' => array(
     378        'type' => 'color',
     379        'ui' => array(
     380            'title'   => __( 'Post Title Hover Color', 'essential-addons-cs' ),
     381            'tooltip' => __( 'Set Post Title Hover Color', 'essential-addons-cs' ),
     382        )
     383    ),
     384
     385    // Post title font size
     386
     387    'post_title_font_size' => array(
     388        'type'    => 'number',
     389        'ui' => array(
     390            'title'   => __( 'Post Title Font Size (px)', 'essential-addons-cs' ),
     391            'tooltip' => __( 'Set the font-size for post title', 'essential-addons-cs' ),
     392        ),
     393    'suggest' => __( '18', 'essential-addons-cs' ),
     394    ),
     395
     396
     397    // Post Excerpt Color
     398
     399    'post_excerpt_color' => array(
     400        'type' => 'color',
     401        'ui' => array(
     402            'title'   => __( 'Post Excerpt Color', 'essential-addons-cs' ),
     403            'tooltip' => __( 'Set Post Excerpt Color', 'essential-addons-cs' ),
     404        )
     405
     406    ),
     407
     408    // Post Meta Color
     409
     410    'post_meta_color' => array(
     411        'type' => 'color',
     412        'ui' => array(
     413            'title'   => __( 'Post Meta Color', 'essential-addons-cs' ),
     414            'tooltip' => __( 'Set Post Meta Color', 'essential-addons-cs' ),
     415        )
     416
     417    ),
     418
    275419    //
    276420    // Visibility
     
    281425        'ui' => array(
    282426            'title' => __( 'Hide based on screen width', 'essential-addons-cs' ),
    283             'toolip' => __( 'Hide this element at different screen widths. Keep in mind that the &ldquo;Extra Large&rdquo; toggle is 1200px+, so you may not see your element disappear if your preview window is not large enough.', 'cornerstone' )
     427            'toolip' => __( 'Hide this element at different screen widths. Keep in mind that the &ldquo;Extra Large&rdquo; toggle is 1200px+, so you may not see your element disappear if your preview window is not large enough.', 'essential-addons-cs' )
    284428        ),
    285429        'options' => array(
  • essential-addons-for-cornerstone-lite/trunk/includes/post-carousel/defaults.php

    r1670744 r1745800  
    1212    'max_post_count' => 4,
    1313    'show_excerpt'      => true,
     14    'excerpt_length' => 20,
    1415    'hide_featured_image'      => false,
     16    'hide_post_meta'      => false,
     17    'meta_position' => 'entry-footer',
    1518    'offset' => '',
    1619    'category' => '',
     
    1922    'max_visible_items_mobile' => 1,
    2023    'slide_to_scroll'   => 1,
    21     'auto_play'         => false,
    22     'loop'              => false,
     24    'auto_play'         => true,
     25    'loop'              => true,
    2326    'pause_hover'       => false,
    2427    'draggable'         => true,
     
    3134    'pagination_type'   => 'none',
    3235    'pagination_position'   => 'normal',
     36    'post_title_font_size' => 18,
     37    'post_background_color'    => '#fff',
     38    'thumbnail_overlay_color'    => 'rgba(0,0,0, .5)',
     39    'post_title_color'    => '#303133',
     40    'post_title_hover_color'    => '#ff2a13',
     41    'post_excerpt_color'    => '#7a7a7a',
     42    'post_meta_color'    => '',
     43    'post_alignment'    => 'eacs-post-align-default',
    3344);
  • essential-addons-for-cornerstone-lite/trunk/includes/post-carousel/definition.php

    r1670744 r1745800  
    1616    }
    1717
    18     public function flags() {
    19         // dynamic_child allows child elements to render individually, but may cause
    20         // styling or behavioral issues in the page builder depending on how your
    21         // shortcodes work. If you have trouble with element presentation, try
    22         // removing this flag.
    23         return array(
    24             'dynamic_child' => false
    25         );
    26     }
     18  public function flags() {
     19    // dynamic_child allows child elements to render individually, but may cause
     20    // styling or behavioral issues in the page builder depending on how your
     21    // shortcodes work. If you have trouble with element presentation, try
     22    // removing this flag.
     23    return array(
     24      'dynamic_child' => false
     25    );
     26  }
    2727
    2828}
     
    3030
    3131// Recent Post with excerpt
    32 // ==============================================
     32// ================================
    3333
    3434
     
    4444    'orientation'  => '',
    4545    'show_excerpt' => 'true',
     46    'excerpt_length' => '',
    4647    'no_sticky'    => '',
    4748    'no_image'     => '',
    48     'fade'         => ''
    49   ), $atts, 'x_recent_posts' ) );
     49    'fade'         => '',
     50    'meta_position' => ''
     51  ), $atts, 'eacs_post_carousel' ) );
    5052
    5153  $allowed_post_types = apply_filters( 'cs_recent_posts_post_types', array( 'post' => 'post' ) );
     
    5355
    5456  $id            = ( $id           != ''     ) ? 'id="' . esc_attr( $id ) . '"' : '';
    55   $class         = ( $class        != ''     ) ? 'x-recent-posts cf ' . esc_attr( $class ) : 'x-recent-posts cf';
     57  $class         = ( $class        != ''     ) ? 'eacs-post-grid row ' . esc_attr( $class ) : 'eacs-post-grid row';
    5658  $style         = ( $style        != ''     ) ? 'style="' . $style . '"' : '';
    5759  $count         = ( $count        != ''     ) ? $count : 9999;
     
    5961  $category_type = ( $type         == 'post' ) ? 'category_name' : 'portfolio-category';
    6062  $offset        = ( $offset       != ''     ) ? $offset : 0;
    61   $orientation   = ( $orientation  != ''     ) ? ' ' . $orientation : ' horizontal';
     63  $orientation   = ( $orientation  != ''     ) ? ' ' . $orientation : ' horizontal clearfix';
    6264  $show_excerpt  = ( $show_excerpt == 'true' );
     65  $excerpt_length   = ( $excerpt_length      != ''     ) ? $excerpt_length : 50;
    6366  $no_sticky     = ( $no_sticky    == 'true' );
    6467  $no_image      = ( $no_image     == 'true' ) ? $no_image : '';
    6568  $fade          = ( $fade         == 'true' ) ? $fade : 'false';
     69  $meta_position = ( ($meta_position   == 'entry-footer') ? "entry-footer" : "entry-header" );
     70  $entry_header = '';
     71  $entry_footer = '';
    6672
    6773  $js_params = array(
     
    8591
    8692      if ( $no_image == 'true' ) {
    87         $image_output       = '';
    88         $image_output_class = 'no-image';
     93        $entry_media        = '';
    8994      } else {
    9095        $image              = wp_get_attachment_image_src( get_post_thumbnail_id(), 'entry-cropped' );
    91         $bg_image           = ( $image[0] != '' ) ? ' style="background-image: url(' . $image[0] . ');"' : '';
    92         $image_output       = '<div class="x-recent-posts-img"' . $bg_image . '></div>';
    93         $image_output_class = 'with-image';
     96        $entry_media        = ( $image[0] != '' ) ? '<div class="eacs-entry-media">'
     97                        . '<div class="eacs-entry-overlay">'
     98                          . '<i class="fa fa-long-arrow-right" aria-hidden="true"></i>'
     99                          . '<a href="' . get_permalink( get_the_ID() ) . '"></a>'
     100                        . '</div>'
     101                          .  '<div class="eacs-entry-thumbnail">'
     102                             . '<img src=' . $image[0] . '>'
     103                           . '</div>'
     104                      . '</div>' : '';
    94105      }
    95106
    96        $excerpt = ( $show_excerpt ) ? '<div class="x-recent-posts-excerpt"><p>' . preg_replace('/<a.*?more-link.*?<\/a>/', '', cs_get_raw_excerpt() ) . '</p></div>' : '';
     107        $trimmed_excerpt =  wp_trim_words( cs_get_raw_excerpt(), $excerpt_length, '...' );   
     108        $excerpt = ( $show_excerpt ) ? '<div class="eacs-grid-post-excerpt"><p>' . preg_replace('/<a.*?more-link.*?<\/a>/', '', $trimmed_excerpt ) . '</p></div>' : '';
    97109
    98       $output .= '<a class="x-recent-post' .' ' . $image_output_class . '" href="' . get_permalink( get_the_ID() ) . '" title="' . esc_attr( sprintf( __( 'Permalink to: "%s"', 'cornerstone' ), the_title_attribute( 'echo=0' ) ) ) . '">'
    99                  . '<article id="post-' . get_the_ID() . '" class="' . implode( ' ', get_post_class() ) . '">'
    100                    . '<div class="entry-wrap">'
    101                      . $image_output
    102                      . '<div class="x-recent-posts-content">'
    103                        . '<h3 class="h-recent-posts">' . get_the_title() . '</h3>'
    104                        . '<span class="x-recent-posts-date">' . get_the_date() . '</span>'
    105                        . $excerpt
    106                      . '</div>'
     110
     111
     112      if ( $meta_position == 'entry-header' ) : {
     113        $entry_header ='<div class="eacs-entry-meta">'
     114          . '<span class="eacs-posted-by">'
     115          . '<a href="'. get_author_posts_url( get_the_author_meta( 'ID' ), get_the_author_meta( 'user_nicename' ) ). '">'. get_the_author_meta( 'display_name' ) .'</a>'
     116          .'</span>'
     117          . '<span class="eacs-posted-on"><time datetime="'. get_the_date() .'">'. get_the_date() .'</time></span>'
     118        . '</div>';
     119      } else: {
     120        $entry_footer = '<div class="eacs-entry-footer">'
     121          . '<div class="eacs-author-avatar">'
     122            . '<a href="' .  get_author_posts_url( get_the_author_meta( 'ID' ), get_the_author_meta( 'user_nicename' ) ). '">'
     123            . get_avatar( get_the_author_meta( 'ID' ), 96 )
     124            .'</a>'
     125          . '</div>'
     126          . '<div class="eacs-entry-meta">'
     127            . '<div class="eacs-posted-by">'
     128            .'<a href="'. get_author_posts_url( get_the_author_meta( 'ID' ), get_the_author_meta( 'user_nicename' ) ). '">'. get_the_author_meta( 'display_name' ) .'</a>'
     129            . '</div>'
     130            . '<div class="eacs-posted-on"><time datetime="'. get_the_date() .'">'. get_the_date() .'</time></div>'
     131          . '</div>'
     132        . '</div>';
     133      } endif;
     134
     135      $output .= '<article id="post-' . get_the_ID() . '" class="eacs-grid-post eacs-post-grid-column">'
     136                  .'<div class="eacs-grid-post-holder">'
     137                   . '<div class="eacs-grid-post-holder-inner">'
     138
     139                             .$entry_media
     140
     141                        . '<div class="eacs-entry-wrapper">'
     142                         . '<header class="eacs-entry-header">'
     143
     144                            . '<h2 class="eacs-entry-title"><a class="eacs-grid-post-link" href="' . get_permalink( get_the_ID() ) . '" title="'. get_the_title() .'">'. get_the_title() .'</a></h2>'
     145
     146                             .$entry_header
     147
     148                          . '</header>'
     149
     150                          . '<div class="eacs-entry-content">'
     151
     152                            . $excerpt
     153
     154                          . '</div>'
     155                        . '</div>'
     156
     157                            .$entry_footer
    107158                   . '</div>'
    108                  . '</article>'
    109                . '</a>';
     159                  . '</div>'
     160               . '</article>';
    110161
    111162    endwhile; endif; wp_reset_postdata();
     
    117168
    118169add_shortcode( 'eacs_post_carousel', 'eacs_post_carousel' );
    119 ?>
  • essential-addons-for-cornerstone-lite/trunk/includes/post-carousel/shortcode.php

    r1670744 r1745800  
    4343
    4444
    45 // Class, ID, Styles
    46 $post_carousel_id = "eacs-post-carousel-".$randnum;
    47 $post_carousel_class      = "eacs-post-carousel" . " " . $add_border . " " . $nav_position . " " . $class ;
    48 
    4945// Toggle
    5046$show_excerpt = ( ($show_excerpt   == 1) ? "true" : "false" );
     
    5450$pause_hover = ( ($pause_hover == 1) ? "true" : "false" );
    5551$draggable   = ( ($draggable == 1) ? "true" : "false" );
    56 
     52$hide_post_meta = ( ($hide_post_meta   == 1) ? "hide-post-meta" : "" );
    5753
    5854// Pagination type
     
    8076
    8177
     78
     79// Class, ID, Styles
     80$post_carousel_id = "eacs-post-carousel-".$randnum;
     81$post_carousel_class = "eacs-post-carousel" . " " . $add_border . " " . $nav_position . " " . $hide_post_meta . " " . $post_alignment ;
     82
     83
    8284?>
    8385
    84 <div id="<?= $post_carousel_id ?>">
    85     <div id="<?= $id ?>" class="<?= $post_carousel_class ?>" style="<?= $style ?>" >
    86         <?php echo do_shortcode("[eacs_post_carousel type=\"$post_type\" count=\"$max_post_count\" offset=\"$offset\" category=\"$category\" show_excerpt=\"$show_excerpt\" no_image=\"$hide_featured_image\"]") ?>
     86<div <?php echo cs_atts( array( 'id' => $id, 'class' => $class, 'style' => $style ) ); ?>>
     87  <div id="<?= $post_carousel_id; ?>">
     88    <div class="<?php echo $post_carousel_class; ?>">
     89      <?php echo do_shortcode("[eacs_post_carousel type=\"$post_type\" count=\"$max_post_count\" excerpt_length=\"$excerpt_length\"  offset=\"$offset\" category=\"$category\" show_excerpt=\"$show_excerpt\" meta_position=\"$meta_position\" no_sticky=\"true\" no_image=\"$hide_featured_image\"]") ?>
     90    </div>
    8791    </div>
    88 </div>
    89 
    9092
    9193<script type="text/javascript">
    9294
    9395  jQuery(document).ready(function($) {
    94      $("<?= '#'.$post_carousel_id . ' ' . '.x-recent-posts' ?>").slick({
    95       autoplay: <?= $auto_play ?>,
    96       infinite: <?= $loop ?>,
    97       slidesToShow: <?= $max_visible_items ?>,
    98       slidesToScroll: <?= $slide_to_scroll ?>,
    99       arrows: <?= $nav ?>,
    100       dots: <?= $dots ?>,
    101       pauseOnHover: <?= $pause_hover ?>,
    102       draggable: <?= $draggable ?>,
    103       responsive: [
    104     {
    105       breakpoint: 1024,
    106       settings: {
    107         slidesToShow: <?= $max_visible_items_tablet ?>,
    108         slidesToScroll: 1
    109       }
    110     },
    111     {
    112       breakpoint: 768,
    113       settings: {
    114         slidesToShow: <?= $max_visible_items_mobile ?>,
    115         slidesToScroll: 1
    116       }
     96
     97    function createPostCarousel() {
     98     
     99      $("<?= '#'.$post_carousel_id ?> .eacs-post-grid").not('.slick-initialized').slick({
     100        autoplay: <?= $auto_play ?>,
     101        infinite: <?= $loop ?>,
     102        slidesToShow: <?= $max_visible_items ?>,
     103        slidesToScroll: <?= $slide_to_scroll ?>,
     104        arrows: <?= $nav ?>,
     105        dots: <?= $dots ?>,
     106        pauseOnHover: <?= $pause_hover ?>,
     107        draggable: <?= $draggable ?>,
     108        responsive: [
     109            {
     110              breakpoint: 1024,
     111              settings: {
     112                slidesToShow: <?= $max_visible_items_tablet ?>,
     113                slidesToScroll: 1
     114              }
     115            },
     116            {
     117              breakpoint: 768,
     118              settings: {
     119                slidesToShow: <?= $max_visible_items_mobile ?>,
     120                slidesToScroll: 1
     121              }
     122            }
     123          ]
     124      });
    117125    }
    118   ]
    119     });
     126
     127  createPostCarousel();
     128
     129  $(window).on( 'resize', createPostCarousel );
     130
    120131  });
    121132</script>
    122 
     133</div>
    123134
    124135<style type="text/css">
    125136
    126 <?php echo '#'.$post_carousel_id; ?> .eacs-post-carousel .x-recent-posts a {
     137<?php echo '#'.$post_carousel_id; ?> .eacs-post-carousel .eacs-grid-post {
    127138  margin: <?php echo $slide_spacing; ?>;
    128139}
    129140
    130 <?php echo '#'.$post_carousel_id; ?> .eacs-post-carousel.slide-border-enabled .x-recent-posts a {
     141<?php echo '#'.$post_carousel_id; ?> .eacs-post-carousel.slide-border-enabled .eacs-grid-post-holder {
    131142  border: <?= $post_border_width ?>px solid <?= $post_border_color?>;
    132143}
     
    148159}
    149160
     161<?php echo '#'.$post_carousel_id; ?> .eacs-grid-post-holder {
     162    background-color: <?php echo $post_background_color; ?>;
     163}
     164<?php echo '#'.$post_carousel_id; ?> .eacs-entry-overlay {
     165    background-color: <?php echo $thumbnail_overlay_color; ?>;
     166}
     167
     168<?php echo '#'.$post_carousel_id; ?> .eacs-entry-title, <?php echo '#'.$post_carousel_id; ?> .eacs-entry-title a {
     169    color: <?php echo $post_title_color; ?>;
     170    font-size: <?php echo $post_title_font_size; ?>px;
     171}
     172<?php echo '#'.$post_carousel_id; ?> .eacs-entry-title:hover, <?php echo '#'.$post_carousel_id; ?> .eacs-entry-title a:hover {
     173    color: <?php echo $post_title_hover_color; ?>;
     174}
     175
     176<?php echo '#'.$post_carousel_id; ?> .eacs-grid-post-excerpt p {
     177    color: <?php echo $post_excerpt_color; ?>;
     178}
     179<?php echo '#'.$post_carousel_id; ?> .eacs-entry-meta, <?php echo '#'.$post_carousel_id; ?> .eacs-entry-meta a {
     180    color: <?php echo $post_meta_color; ?>;
     181}
    150182
    151183</style>
  • essential-addons-for-cornerstone-lite/trunk/includes/product-carousel/defaults.php

    r1670744 r1745800  
    2121    'max_visible_items_mobile' => 1,
    2222    'slide_to_scroll'   => 1,
    23     'auto_play'         => false,
    24     'loop'              => false,
     23    'auto_play'         => true,
     24    'loop'              => true,
    2525    'pause_hover'       => false,
    2626    'draggable'         => true,
  • essential-addons-for-cornerstone-lite/trunk/includes/product-carousel/shortcode.php

    r1670744 r1745800  
    103103    <?php echo do_shortcode("[recent_products per_page=\"$max_product_count\" category=\"$category\"]") ?>
    104104  </div>
    105 </div>
    106 
    107105
    108106<script type="text/javascript">
    109107
    110108  jQuery(document).ready(function($) {
    111      $("<?= '#'.$product_carousel_id . ' ' . '.woocommerce .products' ?>").slick({
     109
     110    function createProductCarousel() {
     111     $("<?= '#'.$product_carousel_id . ' ' . '.woocommerce .products' ?>").not('.slick-initialized').slick({
    112112      autoplay: <?= $auto_play ?>,
    113113      infinite: <?= $loop ?>,
     
    119119      draggable: <?= $draggable ?>,
    120120      responsive: [
    121     {
    122       breakpoint: 1024,
    123       settings: {
    124         slidesToShow: <?= $max_visible_items_tablet ?>,
    125         slidesToScroll: 1
    126       }
    127     },
    128     {
    129       breakpoint: 768,
    130       settings: {
    131         slidesToShow: <?= $max_visible_items_mobile ?>,
    132         slidesToScroll: 1
    133       }
    134     }
    135   ]
     121          {
     122            breakpoint: 1024,
     123            settings: {
     124              slidesToShow: <?= $max_visible_items_tablet ?>,
     125              slidesToScroll: 1
     126            }
     127          },
     128          {
     129            breakpoint: 768,
     130            settings: {
     131              slidesToShow: <?= $max_visible_items_mobile ?>,
     132              slidesToScroll: 1
     133            }
     134          }
     135        ]
    136136    });
     137  }
     138
     139  createProductCarousel();
     140
     141  $(window).on( 'resize', createProductCarousel );
     142
    137143  });
    138144</script>
    139 
     145</div>
    140146
    141147<style type="text/css">
     
    167173}
    168174
    169 .eacs-product-carousel <?php echo '#'.$product_carousel_id; ?> .slick-prev, <?php echo '#'.$product_carousel_id; ?> .eacs-product-carousel .slick-next {
     175.eacs-product-carousel <?php echo '#'.$product_carousel_id; ?> .slick-prev, .eacs-product-carousel <?php echo '#'.$product_carousel_id; ?> .slick-next {
    170176  background-color: <?php echo $slide_nav_bg_color; ?>;
    171177}
  • essential-addons-for-cornerstone-lite/trunk/includes/product-grid/shortcode.php

    r1670744 r1745800  
    7979    <div class="clearfix"></div>
    8080    </div>
    81 </div>
    8281
    8382<script type="text/javascript">
     
    9493
    9594</script>
    96 
     95</div>
    9796
    9897
  • essential-addons-for-cornerstone-lite/trunk/includes/team-members-item/definition.php

    r1670744 r1745800  
    1919    }
    2020
    21     // public function update_build_shortcode_atts( $atts, $parent ) {
    22 
    23     //  if ( ! is_null( $parent ) ) {
    24     //      $atts['linked'] = $parent['linked'];
    25     //  }
    26 
    27     //  return $atts;
    28 
    29     // }
    3021
    3122
  • essential-addons-for-cornerstone-lite/trunk/includes/team-members/defaults.php

    r1670744 r1745800  
    1414    'max_visible_items_mobile' => 1,
    1515    'slide_to_scroll'   => 1,
    16     'auto_play'         => false,
    17     'loop'              => false,
     16    'auto_play'         => true,
     17    'loop'              => true,
    1818    'pause_hover'       => false,
    1919    'draggable'         => true,
  • essential-addons-for-cornerstone-lite/trunk/includes/team-members/definition.php

    r1670744 r1745800  
    1717
    1818    public function flags() {
    19         // dynamic_child allows child elements to render individually, but may cause
    20         // styling or behavioral issues in the page builder depending on how your
    21         // shortcodes work. If you have trouble with element presentation, try
    22         // removing this flag.
    2319        return array(
    24             'dynamic_child' => false
     20
     21            // dynamic_child allows child elements to render individually, but may cause
     22            // styling or behavioral issues in the page builder depending on how your
     23            // shortcodes work. If you have trouble with element presentation, try
     24            // removing this flag.
     25            'dynamic_child' => true,
     26
     27            // Add this in addition to dynamic_child to trigger child preview renders
     28            // when parent attributes are updated.
     29            'linked_child' => true
    2530        );
    2631    }
  • essential-addons-for-cornerstone-lite/trunk/includes/team-members/shortcode.php

    r1670744 r1745800  
    9797    <?php echo do_shortcode( $content ); ?>
    9898  </div>
    99 </div>
    100 
    10199
    102100<script type="text/javascript">
    103101
    104102  jQuery(document).ready(function($) {
    105     $("<?= '#'.$team_members_id?>").slick({
    106       autoplay: <?= $auto_play ?>,
    107       infinite: <?= $loop ?>,
    108       slidesToShow: <?= $max_visible_items ?>,
    109       slidesToScroll: <?= $slide_to_scroll ?>,
    110       arrows: <?= $nav ?>,
    111       dots: <?= $dots ?>,
    112       pauseOnHover: <?= $pause_hover ?>,
    113       draggable: <?= $draggable ?>,
    114       variableWidth: <?= $variable_width ?>,
    115       responsive: [
    116     {
    117       breakpoint: 1024,
    118       settings: {
    119         slidesToShow: <?= $max_visible_items_tablet ?>,
    120         slidesToScroll: 1
    121       }
    122     },
    123     {
    124       breakpoint: 768,
    125       settings: {
    126         slidesToShow: <?= $max_visible_items_mobile ?>,
    127         slidesToScroll: 1
    128       }
     103
     104    function createTeamCarousel() {
     105      $("<?= '#'.$team_members_id?>").not('.slick-initialized').slick({
     106        autoplay: <?= $auto_play ?>,
     107        infinite: <?= $loop ?>,
     108        slidesToShow: <?= $max_visible_items ?>,
     109        slidesToScroll: <?= $slide_to_scroll ?>,
     110        arrows: <?= $nav ?>,
     111        dots: <?= $dots ?>,
     112        pauseOnHover: <?= $pause_hover ?>,
     113        draggable: <?= $draggable ?>,
     114        variableWidth: <?= $variable_width ?>,
     115        responsive: [
     116            {
     117              breakpoint: 1024,
     118              settings: {
     119                slidesToShow: <?= $max_visible_items_tablet ?>,
     120                slidesToScroll: 1
     121              }
     122            },
     123            {
     124              breakpoint: 768,
     125              settings: {
     126                slidesToShow: <?= $max_visible_items_mobile ?>,
     127                slidesToScroll: 1
     128              }
     129            }
     130          ]
     131      });
    129132    }
    130   ]
    131     });
     133
     134  createTeamCarousel();
     135
     136  $(window).on( 'resize', createTeamCarousel );
     137
    132138  });
    133139</script>
     140</div>
    134141
    135142<style type="text/css">
  • essential-addons-for-cornerstone-lite/trunk/includes/testimonial-item/definition.php

    r1670744 r1745800  
    1919    }
    2020
    21     // public function update_build_shortcode_atts( $atts, $parent ) {
    22 
    23     //  if ( ! is_null( $parent ) ) {
    24     //      $atts['linked'] = $parent['linked'];
    25     //  }
    26 
    27     //  return $atts;
    28 
    29     // }
    30 
    3121
    3222}
  • essential-addons-for-cornerstone-lite/trunk/includes/testimonial-slider/defaults.php

    r1670744 r1745800  
    1313    'max_visible_items_mobile' => 1,
    1414    'slide_to_scroll'   => 1,
    15     'auto_play'         => false,
    16     'loop'              => false,
     15    'auto_play'         => true,
     16    'loop'              => true,
    1717    'pause_hover'       => false,
    1818    'draggable'         => true,
  • essential-addons-for-cornerstone-lite/trunk/includes/testimonial-slider/definition.php

    r1670744 r1745800  
    1717
    1818    public function flags() {
    19         // dynamic_child allows child elements to render individually, but may cause
    20         // styling or behavioral issues in the page builder depending on how your
    21         // shortcodes work. If you have trouble with element presentation, try
    22         // removing this flag.
    2319        return array(
    24             'dynamic_child' => false
     20
     21            // dynamic_child allows child elements to render individually, but may cause
     22            // styling or behavioral issues in the page builder depending on how your
     23            // shortcodes work. If you have trouble with element presentation, try
     24            // removing this flag.
     25            'dynamic_child' => true,
     26
     27            // Add this in addition to dynamic_child to trigger child preview renders
     28            // when parent attributes are updated.
     29            'linked_child' => true
    2530        );
    2631    }
  • essential-addons-for-cornerstone-lite/trunk/includes/testimonial-slider/shortcode.php

    r1670744 r1745800  
    8686    <?php echo do_shortcode( $content ); ?>
    8787  </div>
    88 </div>
    89 
    9088
    9189<script type="text/javascript">
    9290
    9391  jQuery(document).ready(function($) {
    94     $("<?= '#'.$testimonial_id ?>").slick({
    95       autoplay: <?= $auto_play ?>,
    96       infinite: <?= $loop ?>,
    97       slidesToShow: <?= $max_visible_items ?>,
    98       slidesToScroll: <?= $slide_to_scroll ?>,
    99       arrows: <?= $nav ?>,
    100       dots: <?= $dots ?>,
    101       pauseOnHover: <?= $pause_hover ?>,
    102       draggable: <?= $draggable ?>,
    103       variableWidth: <?= $variable_width ?>,
    104       responsive: [
    105     {
    106       breakpoint: 1024,
    107       settings: {
    108         slidesToShow: <?= $max_visible_items_tablet ?>,
    109         slidesToScroll: 1
    110       }
    111     },
    112     {
    113       breakpoint: 768,
    114       settings: {
    115         slidesToShow: <?= $max_visible_items_mobile ?>,
    116         slidesToScroll: 1
    117       }
     92
     93    function createTestimonialCarousel() {
     94      $("<?= '#'.$testimonial_id ?>").not('.slick-initialized').slick({
     95        autoplay: <?= $auto_play ?>,
     96        infinite: <?= $loop ?>,
     97        slidesToShow: <?= $max_visible_items ?>,
     98        slidesToScroll: <?= $slide_to_scroll ?>,
     99        arrows: <?= $nav ?>,
     100        dots: <?= $dots ?>,
     101        pauseOnHover: <?= $pause_hover ?>,
     102        draggable: <?= $draggable ?>,
     103        variableWidth: <?= $variable_width ?>,
     104        responsive: [
     105            {
     106              breakpoint: 1024,
     107              settings: {
     108                slidesToShow: <?= $max_visible_items_tablet ?>,
     109                slidesToScroll: 1
     110              }
     111            },
     112            {
     113              breakpoint: 768,
     114              settings: {
     115                slidesToShow: <?= $max_visible_items_mobile ?>,
     116                slidesToScroll: 1
     117              }
     118            }
     119          ]
     120      });
    118121    }
    119   ]
    120     });
     122  createTestimonialCarousel();
     123
     124  $(window).on( 'resize', createTestimonialCarousel );
     125
    121126  });
    122127</script>
     128</div>
     129
    123130
    124131<style type="text/css">
Note: See TracChangeset for help on using the changeset viewer.