Make WordPress Themes

Changeset 150521


Ignore:
Timestamp:
06/30/2021 07:04:20 PM (4 years ago)
Author:
themedropbox
Message:

New version of Fluida - 1.8.7

Location:
fluida/1.8.7
Files:
8 edited
1 copied

Legend:

Unmodified
Added
Removed
  • fluida/1.8.7/cryout/customizer.php

    r144713 r150521  
    6363
    6464            foreach ($cryout_theme_settings['info_sections'] as $iid=>$info):
     65                if (empty($info)) continue;
    6566                $wp_customize->add_section( new Cryout_Customize_About_Section( $wp_customize, $iid, array(
    6667                    'title'          => $info['title'],
     
    7475
    7576        foreach ($cryout_theme_settings['info_settings'] as $iid => $info):
     77            if (empty($info)) continue;
    7678            $wp_customize->add_setting( $iid, array(
    7779                'default'        => $info['default'],
  • fluida/1.8.7/cryout/framework.php

    r144713 r150521  
    22/**
    33 * @package Cryout Framework
    4  * @version 0.8.5.7
    5  * @revision 20210226
     4 * @version 0.8.6
     5 * @revision 20210609
    66 * @author Cryout Creations - www.cryoutcreations.eu
    77 */
    88
    9 define('_CRYOUT_FRAMEWORK_VERSION', '0.8.5.7');
     9define('_CRYOUT_FRAMEWORK_VERSION', '0.8.6');
    1010
    1111// Load everything
  • fluida/1.8.7/cryout/prototypes.php

    r144713 r150521  
    839839            $wrapper_post = '</nav></div><!-- breadcrumbs -->',
    840840            $layout_class = '',
    841             $text_home,
    842             $text_archive,
    843             $text_search,
    844             $text_tag,
    845             $text_author,
    846             $text_404,
    847             $text_format,
    848             $text_page
     841            $text_home = '',
     842            $text_archive = '',
     843            $text_search = '',
     844            $text_tag = '',
     845            $text_author = '',
     846            $text_404 = '',
     847            $text_format = '',
     848            $text_page = ''
    849849) {
    850850
     
    10711071function cryout_localize_cat( $slug, $tax = 'category' ) {
    10721072    if (empty($slug)) return $slug;
    1073     $cat = get_term_by( 'slug', esc_attr($slug), $tax );
    1074     // TODO: bypass polylang filters? and retrieve id when slug not in current language
     1073    // $cat = get_term_by( 'slug', esc_attr($slug), $tax );
     1074    $cat = get_terms( array('taxonomy' => $tax, 'slug' => esc_attr($slug), 'lang' => '' ) );
     1075    $cat = array_shift( $cat );
    10751076    if (empty($cat)) return false;
    10761077    $id = $cat->term_id;
  • fluida/1.8.7/functions.php

    r145389 r150521  
    1111// theme identification and options management - do NOT edit unless you know what you are doing
    1212define ( "_CRYOUT_THEME_NAME", "fluida" );
    13 define ( "_CRYOUT_THEME_VERSION", "1.8.6.2" );
     13define ( "_CRYOUT_THEME_VERSION", "1.8.7" );
    1414
    1515// prefixes for theme options and functions
  • fluida/1.8.7/readme.txt

    r145389 r150521  
    33Contributors: Cryout Creations
    44Requires at least: 4.5
    5 Tested up to: 5.7
    6 Stable tag: 1.8.6.2
     5Tested up to: 5.7.2
     6Stable tag: 1.8.7
    77Requires PHP: 5.6
    88License: GPLv3
     
    7070https://stocksnap.io/photo/UXDUCODR2B (Liquido)
    7171
    72 Preview demo images:
    73 1.jpg - https://www.pexels.com/photo/close-up-of-pictures-185933/
    74 2.jpg - https://www.pexels.com/photo/people-meeting-workspace-team-7097/
    75 3.jpg - https://www.pexels.com/photo/man-holding-smartphone-capturing-roadway-171933/
    76 4.jpg - https://www.pexels.com/photo/adult-art-artist-blur-297648/
    77 5.jpg - https://www.pexels.com/photo/black-and-white-blog-business-chocolate-261577/
    78 6.jpg - https://www.pexels.com/photo/arts-build-close-up-commerce-273230/
    79 7.jpg - https://www.pexels.com/photo/close-up-of-woman-holding-coffee-cup-at-cafe-312420/
    80 8.jpg - https://www.pexels.com/photo/business-camera-communication-computer-436784/
    81 9.jpg - https://www.pexels.com/photo/above-adult-blur-buildings-373934/
    82 10.jpg - https://www.pexels.com/photo/blackboard-business-chalkboard-concept-355988/
    83 
    8472The rest of the bundled images are created by Cryout Creations and released with the theme under GPLv3
    8573
     
    8775== Changelog ==
    8876
    89 = 1.8.6.2 =
     77= 1.8.7 =
     78*Release date - 30.06.2021*
     79
     80* Added Polylang support for featured boxes categories
     81* Added 'fluida_navbelow_sameterm' filter to control previous/next post link behaviour
     82* Fixed scroll-to-link functionality
     83* Cleaned up frontend.js
     84* Removed min-height from .main class on the landing page
     85* Updated to Cryout Framework 0.8.6:
     86    * Improved PHP 8.0 compatibility
     87
     88= 1.8.6.2 =
    9089*Release date - 29.03.2021*
    9190
    9291* Fixed landing page animated featured boxes missing the overlay effect since 1.8.6
    9392
    94 = 1.8.6.1 = 
     93= 1.8.6.1 =
    9594*Release date - 29.03.2021*
    9695
     
    136135* Updated to Cryout Framework 0.8.5.1:
    137136    * Even more sanitization changes to comply with wp.org requirements
    138    
     137
    139138= 1.8.4.1 =
    140139*Release date - 26.05.2020*
  • fluida/1.8.7/resources/js/frontend.js

    r145389 r150521  
    2222    cryoutRemoveFocus();
    2323
    24     if ( ( (cryout_theme_settings.fitvids == 2) && (cryout_theme_settings.is_mobile == 1) ) || ( cryout_theme_settings.fitvids == 1 ) ) {
    25         jQuery( ".entry-content" ).fitVids();
    26     }
    27 
    28     if ( cryout_theme_settings.autoscroll == 1 ) {
    29         cryoutAutoScroll();
    30     }
    31 
    32 }); /* document.ready */
     24    if ( typeof cryout_theme_settings !== 'undefined' ) {
     25
     26        if ( ( ( cryout_theme_settings.fitvids == 2 ) && ( cryout_theme_settings.is_mobile == 1 ) ) || ( cryout_theme_settings.fitvids == 1 ) ) {
     27            jQuery( '.entry-content' ).fitVids();
     28        }
     29
     30        if ( cryout_theme_settings.autoscroll == 1 ) {
     31            cryoutAutoScroll();
     32        }
     33
     34        /* Animate articles */
     35        if ( cryout_theme_settings.articleanimation ) {
     36            animateScroll( '#content-masonry > article', 'animated-article' );
     37        }
     38
     39    } /* typeof cryout_theme_settings check */
     40
     41} ); /* document.ready */
    3342
    3443jQuery( window ).on( 'load', function() {
    3544
    3645    /* trigger scroll on load */
    37     jQuery( window ).trigger( "scroll" );
     46    jQuery( window ).trigger( 'scroll' );
    3847    cryoutMasonry();
    3948    cryoutPortfolioMasonry();
    4049
    41 }); /* window.load */
     50} ); /* window.load */
    4251
    4352
     
    98107    jQuery( window ).on( 'scroll', function() {
    99108        if ( jQuery( this ).scrollTop() > 500 ) {
    100             jQuery( "#toTop" ).css( { "bottom": "-2px", "opacity": 1 } );
     109            jQuery( '#toTop' ).css( { 'bottom': '-2px', 'opacity': 1 } );
    101110        } else {
    102             jQuery( "#toTop" ).css( { "bottom": "100px", "opacity": 0 } );
     111            jQuery( '#toTop' ).css( { 'bottom': '100px', 'opacity': 0 } );
    103112        }
    104113        if ( jQuery( this ).scrollTop() > 300 ) {
    105             jQuery( ".fluida-fixed-menu #site-header-main" ).addClass( "header-fixed" );
     114            jQuery( '.fluida-fixed-menu #site-header-main' ).addClass( 'header-fixed' );
    106115        } else {
    107             jQuery( ".fluida-fixed-menu #site-header-main" ).removeClass( "header-fixed" );
     116            jQuery( '.fluida-fixed-menu #site-header-main' ).removeClass( 'header-fixed' );
    108117        }
    109118    } );
     
    118127/* Search form animation */
    119128function cryoutSearchFormAnimation() {
    120     var searchIcon = jQuery( "#access .menu-search-animated > a" ),
    121     searchForm = jQuery( ".menu-search-animated .searchform" ),
    122     searchInput = jQuery( "#access .menu-search-animated .s" );
     129    var searchIcon = jQuery( '#access .menu-search-animated > a' ),
     130    searchForm = jQuery( '.menu-search-animated .searchform' ),
     131    searchInput = jQuery( '#access .menu-search-animated .s' );
    123132
    124133    searchIcon.on( 'click', function( event ) {
     
    146155    var firstTab = jQuery('nav#mobile-menu #mobile-nav > li:first-child a');
    147156    var lastTab  = jQuery('#nav-cancel'); /* Cancel button will always be last */
    148     jQuery("#nav-toggle").on( 'click', function(e){
     157    jQuery('#nav-toggle').on( 'click', function(e){
    149158        e.preventDefault();
    150         jQuery("#mobile-menu").show().animate({left: "0"}, 500);
     159        jQuery('#mobile-menu').show().animate({left: 0}, 500);
    151160        jQuery('body').addClass("noscroll");
    152161        firstTab.trigger('focus');
     
    154163    });
    155164
    156     jQuery("#nav-cancel").on( 'click', function(e){
     165    jQuery('#nav-cancel').on( 'click', function(e){
    157166        e.preventDefault();
    158         jQuery("#mobile-menu").animate({left: "100%"},500,function(){jQuery(this).css("left","-100%").hide();});
    159         jQuery('body').removeClass("noscroll");
    160         jQuery("#nav-toggle").trigger('focus');
     167        jQuery('#mobile-menu').animate( {left: '100%'}, 500, function(){ jQuery(this).css('left', '-100%').hide(); });
     168        jQuery('body').removeClass('noscroll');
     169        jQuery('#nav-toggle').trigger('focus');
    161170        return false;
    162171    });
     
    190199
    191200    /* Remove animated class from mobile menu */
    192     jQuery("#mobile-menu .menu-main-search").removeClass("menu-search-animated");
    193 
    194     jQuery( "#mobile-menu > div" ).append( jQuery( "#sheader" ).clone() );
    195     jQuery( "#mobile-menu #sheader" ).attr( "id", "smobile");
     201    jQuery( '#mobile-menu .menu-main-search' ).removeClass( 'menu-search-animated' );
     202
     203    jQuery( '#mobile-menu > div' ).append( jQuery( '#sheader' ).clone() );
     204    jQuery( '#mobile-menu #sheader' ).attr( 'id', 'smobile' );
    196205
    197206} /* cryoutMobileMenuInit() */
     
    200209function cryoutFixedMobileMenu(){
    201210
    202     /* only run if fixed menu is enabled */
    203     if (cryout_theme_settings.menustyle != 1) return;
    204 
    205     var c, currentScrollTop = 0,
     211    /* Only run if fixed menu is enabled */
     212    if ( cryout_theme_settings.menustyle != 1 ) return;
     213
     214    var c, currentScrollTop = 0, currentScrollBottom,
    206215    navbar = jQuery( '#site-header-main' ),
    207216    body = jQuery( 'body' );
    208217
    209     jQuery(window).on( 'scroll', function () {
    210         var a = jQuery(window).scrollTop();
    211         var b = jQuery(document).height();
    212         var viewport = jQuery(window).height();
     218    jQuery( window ).on( 'scroll', function () {
     219        var a = jQuery( window ).scrollTop();
     220        var b = jQuery( document ).height();
     221        var viewport = jQuery( window ).height();
    213222        var navbarHeight = navbar.height();
    214223
     
    217226
    218227        if ( c < currentScrollTop && a > navbarHeight + navbarHeight ) {
    219             /* scrolling down */
    220             body.removeClass('mobile-fixed');
    221         } else if (currentScrollTop > viewport && (currentScrollTop < currentScrollBottom - viewport*2) && c > currentScrollTop && !(a <= navbarHeight)) {
    222             /* scrolling up */
    223             body.addClass('mobile-fixed');
     228            /* Scrolling down */
     229            body.removeClass( 'mobile-fixed' );
     230        } else if ( ( currentScrollTop > viewport ) && ( currentScrollTop < currentScrollBottom - viewport * 2 ) && ( c > currentScrollTop ) && ( ! ( a <= navbarHeight ) ) ) {
     231            /* Scrolling up */
     232            body.addClass( 'mobile-fixed' );
    224233        }
    225234
    226235        c = currentScrollTop;
    227236
    228         /* always clear fixed class when returning to the top */
     237        /* Always clear fixed class when returning to the top */
    229238        if ( currentScrollTop <= navbarHeight ) {
    230             body.removeClass('mobile-fixed');
    231         }
    232 
    233     });
     239            body.removeClass( 'mobile-fixed' );
     240        }
     241
     242    } );
    234243} /* cryoutFixedMobileMenu() */
    235244
     
    237246function cryoutInitNav( selector ) {
    238247
    239     container = jQuery( selector );
     248    var container = jQuery( selector );
    240249
    241250    /* Add dropdown toggle that display child menu items. */
     
    341350
    342351/* Check if element is visible in browser window */
    343 jQuery.fn.visible = function( partial ) {
    344     var $t            = jQuery( this ),
    345         $w            = jQuery( window ),
    346         viewTop       = $w.scrollTop(),
    347         viewBottom    = viewTop + $w.height(),
    348         _top          = $t.offset().top,
    349         _bottom       = _top + $t.height(),
    350         compareTop    = partial === true ? _bottom : _top,
    351         compareBottom = partial === true ? _top : _bottom;
    352 
    353     return ( (compareBottom <= viewBottom) && (compareTop >= viewTop) );
    354 }; /* jQuery.fn.visible() */
     352function isInViewport( el ) {
     353    if ( ! jQuery( el ).length ) return;
     354
     355    var adminHeight = ( jQuery( '#wpadminbar' ).length ) ? jQuery( '#wpadminbar' ).height() : 0;
     356
     357    var elementTop = jQuery( el ).offset().top;
     358    var elementBottom = elementTop + jQuery( el ).outerHeight();
     359
     360    var viewportTop = jQuery( window ).scrollTop();
     361    var viewportBottom = viewportTop + jQuery( window ).height() - adminHeight;
     362
     363    return ( elementBottom > viewportTop ) && ( elementTop < viewportBottom );
     364} /* isInViewport() */
    355365
    356366/* Animate on scroll */
    357 function animateScroll( $articles ) {
     367function animateScroll( $articles, $class = 'animated-article' ) {
    358368
    359369    var $articles = jQuery( $articles );
    360370
    361371    $articles.each( function( i, el ) {
    362       var el = jQuery( el );
    363       if ( ! el.visible( true ) ) {
    364           el.addClass( "animated-article" );
    365       }
    366     });
    367 
    368     jQuery( window ).on({
    369         'scroll': function( e ) {
    370             $articles.each( function( i, el ) {
    371                 var el = jQuery( el );
    372                 if ( el.visible( true ) ) {
    373                     el.removeClass( "animated-article" );
    374                 }
    375             });
    376         }
    377     });
    378 
     372        if ( ! isInViewport( el ) ) {
     373            jQuery( el ).addClass( $class );
     374        }
     375    } );
     376
     377    jQuery( window ).on( 'scroll', function() {
     378        $articles.each( function( i, el ) {
     379            if ( isInViewport( el ) ) {
     380                jQuery( el ).removeClass( $class );
     381            }
     382        } );
     383    } );
     384
     385    jQuery( window ).trigger( 'scroll' );
    379386} /* animateScroll() */
    380387
    381 /* Animate articles */
    382 if ( cryout_theme_settings.articleanimation ) {
    383     animateScroll( "#content-masonry > article" );
    384 }
    385 
    386 /*  Add Social Icons titles */
     388/*  Add social icons titles */
    387389function cryoutSocialTitles() {
    388390
    389     jQuery( ".socials a" ).each(function() {
    390         jQuery( this ).attr( "title", jQuery( this ).children().html() );
    391         jQuery( this ).html( "" );
    392     });
     391    jQuery( '.socials a' ).each( function() {
     392        jQuery( this ).attr( 'title', jQuery( this ).children().html() );
     393        jQuery( this ).html( '' );
     394    } );
    393395
    394396} /* cryoutSocialTitles() */
     
    397399function cryoutBodyClasses() {
    398400    /* Detect and apply custom class for Safari */
    399     if ( navigator.userAgent.indexOf( "Safari" ) != -1 && navigator.userAgent.indexOf( "Chrome" ) == -1) {
    400         jQuery( "body" ).addClass( "safari" );
     401    if ( navigator.userAgent.indexOf( 'Safari' ) != -1 && navigator.userAgent.indexOf( 'Chrome' ) == -1) {
     402        jQuery( 'body' ).addClass( 'safari' );
    401403    }
    402404    /* Add body class if masonry is used on page */
    403     if ( jQuery( "#content-masonry" ).length > 0 ) {
    404         jQuery( "body" ).addClass( "fluida-with-masonry" );
     405    if ( jQuery( '#content-masonry' ).length > 0 ) {
     406        jQuery( 'body' ).addClass( 'fluida-with-masonry' );
    405407    }
    406408} /* cryoutBodyClasses() */
     
    408410/* Remove all off-canvas states */
    409411function cryoutRemoveFocus() {
    410     jQuery( '#access a, #site-title a' ).on('mouseup mousedown', function() {
    411         jQuery( this ).blur();
    412     });
    413     jQuery( 'input, textarea, select, button' ).on('mouseup mousedown', function() {
     412    jQuery( '#access a, #site-title a' ).on( 'mouseup mousedown', function() {
     413        jQuery( this ).trigger( 'blur' );
     414    } );
     415    jQuery( 'input, textarea, select, button' ).on( 'mouseup mousedown', function() {
    414416        jQuery( this ).css('outline', 'none');
    415     })
     417    } )
    416418} /* cryoutRemoveFocus() */
    417419
     
    509511    var anchorScrolls = {
    510512        ANCHOR_REGEX: /^#[^ ]+$/,
    511         OFFSET_HEIGHT_PX: jQuery( '.kahuna-fixed-menu #site-header-main' ).height(),
     513        OFFSET_HEIGHT_PX: jQuery( '.fluida-fixed-menu #site-header-main' ).height(),
    512514
    513515        /* Establish events, and fix initial scroll position if a hash is provided. */
     
    643645        $this.wrap('<div class="fluid-width-video-wrapper"></div>').parent('.fluid-width-video-wrapper').css('padding-top', (aspectRatio * 100)+'%');
    644646        $this.removeAttr('height').removeAttr('width');
    645       });
    646     });
     647      } );
     648    } );
    647649  };
    648650
  • fluida/1.8.7/single.php

    r144713 r150521  
    4747
    4848                    <nav id="nav-below" class="navigation" role="navigation">
    49                         <div class="nav-previous"><?php previous_post_link( '%link', '<i class="icon-angle-left"></i> <span>%title</span>' ); ?></div>
    50                         <div class="nav-next"><?php next_post_link( '%link', '<span>%title</span> <i class="icon-angle-right"></i>' ); ?></div>
     49                        <div class="nav-previous"><?php previous_post_link( '%link', '<i class="icon-angle-left"></i> <span>%title</span>', apply_filters( 'fluida_navbelow_sameterm', false ) ); ?></div>
     50                        <div class="nav-next"><?php next_post_link( '%link', '<span>%title</span> <i class="icon-angle-right"></i>', apply_filters( 'fluida_navbelow_sameterm', false ) ); ?></div>
    5151                    </nav><!-- #nav-below -->
    5252
  • fluida/1.8.7/style.css

    r145389 r150521  
    55Author: Cryout Creations
    66Author URI: http://www.cryoutcreations.eu
    7 Version: 1.8.6.2
     7Version: 1.8.7
    88Requires at least: 4.5
    9 Tested up to: 5.7
     9Tested up to: 5.7.2
    1010Requires PHP: 5.6
    1111License: GNU General Public License v3.0
     
    625625
    626626/* workaround for buttons misalign in 5.7 */
    627 .wp-block-button.aligncenter, 
    628 .wp-block-buttons.aligncenter, 
     627.wp-block-button.aligncenter,
     628.wp-block-buttons.aligncenter,
    629629.wp-block-calendar {
    630630    text-align: center;
     
    648648.main {
    649649    margin-bottom: 0;
    650     min-height: 400px;
     650    /* min-height: 400px; */
    651651    clear: both;
    652652    overflow: hidden;
Note: See TracChangeset for help on using the changeset viewer.