Make WordPress Themes

Changeset 318978


Ignore:
Timestamp:
03/21/2026 11:10:51 AM (7 months ago)
Author:
themedropbox
Message:

New version of Auto Mechanic - 4.7

Location:
auto-mechanic/4.7
Files:
11 edited
1 copied

Legend:

Unmodified
Added
Removed
  • auto-mechanic/4.7/functions.php

    r305951 r318978  
    146146        wp_style_add_data('auto-mechanic-style', 'rtl', 'replace');
    147147
    148         // Animate CSS
    149         wp_enqueue_style( 'animate-style', get_template_directory_uri() . '/resource/css/animate.css' );
     148        if (get_theme_mod('auto_mechanic_enable_animation', true) == true){
     149                // Animate CSS
     150                wp_enqueue_style( 'animate-style', get_template_directory_uri() . '/resource/css/animate.css' );
     151                // Wow script.
     152                wp_enqueue_script( 'wow-jquery', get_template_directory_uri() . '/resource/js/wow.js', array('jquery'),'' ,true );
     153        }
    150154
    151155        // Navigation script.
    … …  
    154158        // Slick script.
    155159        wp_enqueue_script( 'auto-mechanic-slick-script', get_template_directory_uri() . '/resource/js/slick' . $min . '.js', array( 'jquery' ), '1.8.1', true );
    156 
    157         // Wow script.
    158         wp_enqueue_script( 'wow-jquery', get_template_directory_uri() . '/resource/js/wow.js', array('jquery'),'' ,true );
    159160
    160161        // Custom script.
  • auto-mechanic/4.7/readme.txt

    r314891 r318978  
    55Requires at least: 5.0
    66Tested up to: 6.9
    7 Stable tag: 4.6
     7Stable tag: 4.7
    88Requires PHP: 7.2
    99License: GNU General Public License v3 or later
    … …  
    244244* Added first capital letter option in blog post setting.
    245245* Resolved errors.
     246* Updated pot file.
     247
     248= 4.7 =
     249* Added on/off setting of animation in customizer.
     250* Added topbar padding setting in customizer.
     251* Added slider button background color option.
     252* Added slider button lable color option.
     253* Updated rtl file.
    246254* Updated pot file.
    247255
  • auto-mechanic/4.7/sections/banner.php

    r255860 r318978  
    6464                                                                <div class="banner-caption">
    6565                                                                    <div class="asterthemes-wrapper">
    66                                                                         <div class="banner-catption-wrapper">
     66                                                                        <div class="banner-catption-wrapper wow zoomIn delay-1000" data-wow-duration="2s">
    6767                                                                                <!-- New Heading from Customizer -->
    6868                                                                            <h2 class="custom-banner-heading">
  • auto-mechanic/4.7/style-rtl.css

    r314891 r318978  
    27592759}
    27602760
     2761.mag-post-single .mag-post-detail .mag-post-meta .post-comments{
     2762        margin-inline-end: 10px !important;
     2763}
     2764.mag-post-single .mag-post-detail .mag-post-meta .post-time{
     2765        margin-inline-end: 5px;
     2766}
     2767.mag-post-single .mag-post-detail .mag-post-meta .post-comments,
     2768.mag-post-single .mag-post-detail .mag-post-meta .post-comments i,
     2769.mag-post-single .mag-post-detail .mag-post-meta .post-time,
     2770.mag-post-single .mag-post-detail .mag-post-meta .post-time a{
     2771        color: var(--color-text-main);
     2772        text-decoration: none;
     2773    font-size: 16px;
     2774}
     2775
    27612776.auto-mechanic-archive-layout {
    27622777        margin-bottom: 30px;
    … …  
    58565871}
    58575872
    5858 /* .home .bottom-header-outer-wrapper {
    5859     padding: 15px 0;
    5860     position: absolute;
    5861     z-index: 99;
    5862     width: 100%;
    5863 } */
     5873.home header.site-header .header-main-wrapper .bottom-header-outer-wrapper .bottom-header-part {
     5874        position: relative !important;
     5875}
    58645876
    58655877.banner-section.banner-style-1 .banner-single .banner-img::after {
    … …  
    59625974}
    59635975
    5964 .banner-section.banner-style-1 .slick-active.banner-single .banner-catption-wrapper .caption-subtitle,
    5965 .banner-section.banner-style-1 .slick-active.banner-single .banner-catption-wrapper .banner-caption-title,
    5966 .banner-section.banner-style-1 .slick-active.banner-single .banner-catption-wrapper .caption-description,
    5967 .banner-section.banner-style-1 .slick-active.banner-single .banner-catption-wrapper .banner-slider-btn,
    5968 .banner-section.banner-style-1 .slick-active .banner-single .banner-catption-wrapper .caption-subtitle,
    5969 .banner-section.banner-style-1 .slick-active .banner-single .banner-catption-wrapper .banner-caption-title,
    5970 .banner-section.banner-style-1 .slick-active .banner-single .banner-catption-wrapper .caption-description,
    5971 .banner-section.banner-style-1 .slick-active .banner-single .banner-catption-wrapper .banner-slider-btn {
    5972         transform-origin: top;
    5973         animation-name: asterthemes-animation1;
    5974         animation-fill-mode: both;
    5975         animation-duration: 0.7s;
    5976 }
    5977 
    5978 .banner-section.banner-style-1 .slick-active.banner-single .banner-catption-wrapper .caption-subtitle,
    5979 .banner-section.banner-style-1 .slick-active .banner-single .banner-catption-wrapper .caption-subtitle {
    5980         animation-delay: 0.2s;
    5981 }
    5982 
    5983 .banner-section.banner-style-1 .slick-active.banner-single .banner-catption-wrapper .banner-caption-title,
    5984 .banner-section.banner-style-1 .slick-active .banner-single .banner-catption-wrapper .banner-caption-title {
    5985         animation-delay: 0.3s;
    5986 }
    5987 
    5988 .banner-section.banner-style-1 .slick-active.banner-single .banner-catption-wrapper .caption-description,
    5989 .banner-section.banner-style-1 .slick-active .banner-single .banner-catption-wrapper .caption-description {
    5990         animation-delay: 0.4s;
    5991 }
    5992 
    5993 .banner-section.banner-style-1 .slick-active.banner-single .banner-catption-wrapper .banner-slider-btn,
    5994 .banner-section.banner-style-1 .slick-active .banner-single .banner-catption-wrapper .banner-slider-btn {
    5995         animation-delay: 0.5s;
    5996 }
    5997 
    5998 @keyframes asterthemes-animation1 {
    5999         from {
    6000                 opacity: 0;
    6001                 transform: translateY(100px);
    6002         }
    6003         to {
    6004                 opacity: 1;
    6005                 transform: translateY(0);
    6006         }
    6007 }
    6008 
    60095976/* --------------------------------------------- */
    60105977/* products section CSS start
    … …  
    62566223/* footer CSS end
    62576224--------------------------------------------- */
     6225
     6226/* footer social icons CSS start
     6227--------------------------------------------- */
     6228
     6229.socialicons{
     6230        text-align: center;
     6231        background-color: #000;
     6232        padding: 10px 0;
     6233}
     6234.socialicons a{
     6235        color: #fff;
     6236        font-size: 16px;
     6237        padding: 5px;
     6238        cursor: pointer;
     6239}
     6240 
     6241/* footer social icons CSS end
     6242--------------------------------------------- */
     6243
    62586244/* scroll to top CSS start
    62596245--------------------------------------------- */
    … …  
    64276413  margin: 0;
    64286414}
    6429 .woocommerce h2.woocommerce-loop-product__title{
     6415.woocommerce h2.woocommerce-loop-product__title,
     6416.wc-block-grid__product .wc-block-grid__product-title{
    64306417        color: #000;
    64316418}
    6432 .woocommerce h2.woocommerce-loop-product__title:hover{
     6419.woocommerce h2.woocommerce-loop-product__title:hover,
     6420.wc-block-grid__product .wc-block-grid__product-title:hover{
    64336421        color: var(--primary-color);
     6422}
     6423.wc-block-grid__product a{
     6424        text-decoration: none;
    64346425}
    64356426p.price,
    64366427.woocommerce ul.products li.product .price,
    64376428.woocommerce div.product p.price,
    6438 .woocommerce div.product span.price {
     6429.woocommerce div.product span.price,
     6430.wc-block-grid__product-price {
    64396431  color: #fff;
    64406432  font-weight: bold;
    … …  
    64926484.woocommerce a.button.alt,
    64936485.woocommerce button.button.alt,
    6494 .woocommerce input.button.alt,.woocommerce a.added_to_cart {
     6486.woocommerce input.button.alt,.woocommerce a.added_to_cart,
     6487.woocommerce-Address-title.title a,
     6488.wc-block-cart__submit-button {
    64956489        padding: 12px 15px;
    64966490    color: #fff;
    64976491    margin: 3px;
    6498     font-size: 15px;
     6492    font-size: 18px;
    64996493    line-height: 15px;
    65006494    background: var(--primary-color);
     6495        border: 2px solid var(--primary-color);
    65016496}
    65026497.pro-button a:hover,
    … …  
    65086503.woocommerce a.button.alt:hover,
    65096504.woocommerce button.button.alt:hover,
    6510 .woocommerce input.button.alt:hover{
     6505.woocommerce input.button.alt:hover,
     6506.woocommerce ul.products li.product .button:hover,.woocommerce-Address-title.title a:hover,.wc-block-cart__submit-button:hover{
    65116507  background: #111111;
    65126508  color: #fff;
     6509  border: 2px solid var(--primary-color);
    65136510}
    65146511ins {
    … …  
    65356532        min-height: 0;
    65366533        text-transform: uppercase;
     6534        z-index: 1;
    65376535}
    65386536.woocommerce ul.products li.product .star-rating,.woocommerce .star-rating {
    65396537  margin: 0px auto 10px;
    65406538  color: #ffc53f;
     6539}
     6540.woocommerce .star-rating {
     6541    font-size: 20px;
    65416542}
    65426543.woocommerce .woocommerce-ordering select {
    … …  
    65566557.woocommerce-info{
    65576558  border-top-color: var(--primary-color);
     6559}
     6560.woocommerce-info{
     6561        padding: 1em 3.5em 2em 2em;
     6562        margin: 0 0 2em;
     6563        position: relative;
     6564        background-color: #f6f5f8 !important;
     6565        color: #515151;
     6566        border-top: 3px solid var(--primary-color);
     6567        list-style: none outside;
     6568        width: auto;
     6569        word-wrap: break-word;
    65586570}
    65596571.woocommerce-message::before,
    … …  
    65816593  font-size: 15px;
    65826594  font-weight: 600;
     6595  border: 2px solid var(--primary-color);
    65836596}
    65846597.woocommerce-account .woocommerce-MyAccount-navigation ul li a{
    … …  
    65866599  text-decoration: none;
    65876600}
    6588 h2.woocommerce-loop-product__title {
    6589   font-size: 16px !important;
     6601h2.woocommerce-loop-product__title,
     6602.wc-block-grid__product-title {
     6603    font-size: 20px !important;
    65906604  padding: 8px 0 !important;
     6605    font-weight: 700;
     6606  text-decoration:none;
    65916607}
    65926608.woocommerce #customer_login .col2-set .col-1, .woocommerce-page .col2-set .col-1,
    … …  
    66116627    border-left: 0px;
    66126628}
     6629.woocommerce nav.woocommerce-pagination{
     6630        text-align: center;
     6631}
    66136632.woocommerce nav.woocommerce-pagination ul{
    66146633    border: 0px;
    6615    
    6616 }
    6617 .woocommerce nav.woocommerce-pagination ul li a:focus, .woocommerce nav.woocommerce-pagination ul li a:hover, .woocommerce nav.woocommerce-pagination ul li span.current {
     6634        display: block;
     6635    white-space: nowrap;
     6636    padding: 0;
     6637        width: fit-content;
     6638    margin: auto;
     6639        clear: both;
     6640}
     6641.woocommerce nav.woocommerce-pagination ul li a:focus, .woocommerce nav.woocommerce-pagination ul li a:hover, .woocommerce nav.woocommerce-pagination ul li span.current, .woocommerce nav.woocommerce-pagination ul li a:hover {
    66186642    background: var(--primary-color);
    66196643    color: #ffff;
    6620     margin-bottom: 35px;
     6644        margin-bottom: 20px;
     6645}
     6646.woocommerce nav.woocommerce-pagination ul li{
     6647        list-style: none;
     6648        padding: 0;
     6649    margin: 0;
     6650    float: right;
     6651        overflow: hidden;
     6652}
     6653.woocommerce .woocommerce-pagination ul.page-numbers li, .woocommerce-page .woocommerce-pagination ul.page-numbers li {
     6654    display: inline-block;
     6655}
     6656.woocommerce nav.woocommerce-pagination ul li span, .woocommerce nav.woocommerce-pagination ul li a{
     6657        text-decoration: none;
     6658        line-height: 1;
     6659        min-width: 1em;
     6660    display: block;
    66216661}
    66226662.woocommerce-account .woocommerce-MyAccount-navigation,.woocommerce-account .woocommerce-MyAccount-content{
    … …  
    66286668    list-style: none;
    66296669}
    6630 
     6670.wc-block-grid__product-price del,
     6671.wc-block-components-product-price del{
     6672        opacity: 0.5;
     6673        color: #fff !important;
     6674}
     6675.woocommerce-page .price del{
     6676        margin-left: 5px;
     6677}
     6678.wc-block-components-checkout-return-to-cart-button{
     6679 background-color: var(--primary-color);
     6680 padding: 10px;
     6681 padding-right: 25px;
     6682}
     6683.wc-block-checkout__actions .wc-block-checkout__actions_row a{
     6684 color: #fff !important;
     6685}
    66316686.wp-block-button.is-style-squared, .wp-block-button__link.wp-block-button.is-style-squared {
    66326687    border-radius: 0;
    … …  
    66386693}
    66396694.nav-previous a {
    6640         color: #000!important;
     6695        color: #000;
    66416696    border: 2px solid;
    66426697    padding: 8px 16px;
    … …  
    66476702    padding: 8px 16px;
    66486703}
     6704.add_to_cart_button {
     6705        border-radius: 3px !important;
     6706        font-weight: 700 !important;
     6707        padding: 12px 15px !important;
     6708    color: #fff !important;
     6709    margin: 3px !important;
     6710    font-size: 18px !important;
     6711    line-height: 15px !important;
     6712    background: var(--primary-color) !important;
     6713}
     6714.add_to_cart_button:hover{
     6715        background: #111111 !important;
     6716        color: #fff !important;
     6717}
     6718.wc-block-grid__product-onsale {
     6719        top: 0px !important;
     6720        left: auto !important;
     6721        right: 0px !important;
     6722        margin: 0 !important;
     6723        line-height: 1 !important;
     6724        background: #000 !important;
     6725        border-radius: 25px !important;
     6726        padding: 9px 10px !important;
     6727        border-radius: 0px !important;
     6728        height: 33px !important;
     6729        min-height: 0 !important;
     6730        text-transform: uppercase !important;
     6731        color: #fff !important;
     6732        font-size: 13.5px !important;
     6733}
     6734.wc-block-components-button__text{
     6735        color:#fff;
     6736}
     6737.wc-block-components-button{
     6738        text-decoration: none !important;
     6739}
     6740.woocommerce h2.woocommerce-loop-product__title,
     6741.woocommerce ul.products li.product .price,
     6742.wc-block-grid__product .wc-block-grid__product-title,
     6743.wc-block-grid__product .wc-block-grid__product-price{
     6744    color: #fff;
     6745}
     6746.wc-block-grid__product .wc-block-grid__product-title{
     6747    font-size: 16px;
     6748}
     6749.woocommerce ul.products li.product .button{
     6750        max-width: 130px;
     6751        display: block;
     6752        margin: auto !important;
     6753}
     6754.woocommerce a.added_to_cart {
     6755  font-size: 18px;
     6756  font-weight: 700;
     6757  border-radius: 3px;
     6758}
    66496759@media (min-width: 1171px) {
    66506760        body.no-sidebar:not(.asterthemes-boxed-layout) .alignwide {
    … …  
    66636773.wp-block-woocommerce-cart-order-summary-block {
    66646774    border: 1px solid;
    6665     padding: 1px;
     6775    padding: 10px;
    66666776}
    66676777.is-large.wc-block-cart .wc-block-cart-items th {
    … …  
    67056815    float: left;
    67066816}
    6707 
    6708 
     6817.woocommerce-info .wc-forward{
     6818        float: left;
     6819        text-decoration: none;
     6820}
     6821.woocommerce-Address address {
     6822    margin-top: 50px;
     6823}
     6824.woocommerce-Addresses .u-column2{
     6825        margin-right: 20px;
     6826}
    67096827@media only screen and (max-width: 700px) {
    67106828.woocommerce #content div.product div.images, .woocommerce #content div.product div.summary, .woocommerce div.product div.images, .woocommerce div.product div.summary, .woocommerce-page #content div.product div.images, .woocommerce-page #content div.product div.summary, .woocommerce-page div.product div.images, .woocommerce-page div.product div.summary {
    … …  
    71407258        }
    71417259
     7260        #coming-soon-footer-banner .coming-soon-footer-banner__content{
     7261                color:#000;
     7262        }
     7263
    71427264        @media (max-width: 991px) {
    71437265                .auto_mechanic-archive-layout.grid-layout.column-4 {
    … …  
    71827304       
    71837305        .woocommerce-Addresses .woocommerce .col2-set, .woocommerce-page .col2-set {
    7184                 width: 100%;
    71857306                display: flex;
    7186                 flex-direction: column;
    7187         }
     7307        }
     7308        .woocommerce-Address-title.title{
     7309                margin-bottom: 20px !important;
     7310        }
     7311        .woocommerce-account .addresses .title .edit{
     7312                float: right;
     7313                text-decoration: none !important;
     7314                margin-top: 20px !important;
     7315        }
     7316        @media only screen and (max-width: 768px) {
     7317                .woocommerce .col2-set .col-1, .woocommerce .col2-set .col-2, .woocommerce-page .col2-set .col-1, .woocommerce-page .col2-set .col-2 {
     7318                        float: none;
     7319                        width: 100%;
     7320                }
     7321                .woocommerce-Addresses .woocommerce .col2-set, .woocommerce-page .col2-set {
     7322                        display: flex;
     7323                        flex-direction: column;
     7324                }
     7325                .woocommerce-account .woocommerce-MyAccount-navigation ul li {
     7326                        display: inline-block;
     7327                        margin: 5px;
     7328                }
     7329                nav.woocommerce-MyAccount-navigation {
     7330                        margin-top: 0px;
     7331                }
     7332                .right-sidebar .asterthemes-wrapper .asterthemes-page,.left-sidebar .asterthemes-wrapper .asterthemes-page{
     7333                        margin-top:0 ;
     7334                }
     7335                .woocommerce-Addresses .u-column2 {
     7336                        margin-right: 0px;
     7337                }
     7338                .woocommerce-info {
     7339                        text-align: center;
     7340                        padding: 1em 3.5em 1em 2em;
     7341                }
     7342                .woocommerce-info .woocommerce-Button, .woocommerce-info .wc-forward {
     7343                        float: none;
     7344                        display: inline-block;
     7345                }
     7346        }
     7347
     7348        @media (max-width: 1400px) {
     7349                .site-footer .site-footer-bottom .site-footer-bottom-wrapper{
     7350                        padding: 0px 10px;
     7351                }
     7352        }
  • auto-mechanic/4.7/style.css

    r314891 r318978  
    55Author URI: https://asterthemes.com
    66Description: The Auto Mechanic theme is a modern, responsive, and feature-rich WordPress solution designed for automotive professionals, repair shops, and car service businesses. Perfect for auto repair, vehicle maintenance, garage solutions, car tuning, auto detailing, engine repair, and mechanical services, this theme provides a clean and professional online presence. It features dedicated sections for service listings, pricing packages, appointment booking, customer testimonials, and promotional banners, creating a user-friendly and engaging experience for visitors. The design reflects the precision and professionalism associated with the automotive industry, with high-quality visuals and a cohesive layout that builds trust and credibility. Fully responsive and optimized for all devices, the theme ensures seamless browsing across desktops, tablets, and smartphones. Customization options allow you to adjust colors, fonts, and layouts to match your brand identity, while integration with Contact Form 7 and social media platforms facilitates client communication and community engagement. Auto Mechanic offers a complete, SEO-friendly, and high-performing platform to showcase automotive services, attract customers, and grow your business online.
    7 Version: 4.6
     7Version: 4.7
    88Tested up to: 6.9
    99Requires PHP: 7.2
    … …  
    60286028}
    60296029
    6030 .banner-section.banner-style-1 .slick-active.banner-single .banner-catption-wrapper .caption-subtitle,
    6031 .banner-section.banner-style-1 .slick-active.banner-single .banner-catption-wrapper .banner-caption-title,
    6032 .banner-section.banner-style-1 .slick-active.banner-single .banner-catption-wrapper .caption-description,
    6033 .banner-section.banner-style-1 .slick-active.banner-single .banner-catption-wrapper .banner-slider-btn,
    6034 .banner-section.banner-style-1 .slick-active .banner-single .banner-catption-wrapper .caption-subtitle,
    6035 .banner-section.banner-style-1 .slick-active .banner-single .banner-catption-wrapper .banner-caption-title,
    6036 .banner-section.banner-style-1 .slick-active .banner-single .banner-catption-wrapper .caption-description,
    6037 .banner-section.banner-style-1 .slick-active .banner-single .banner-catption-wrapper .banner-slider-btn {
    6038         transform-origin: top;
    6039         animation-name: asterthemes-animation1;
    6040         animation-fill-mode: both;
    6041         animation-duration: 0.7s;
    6042 }
    6043 
    6044 .banner-section.banner-style-1 .slick-active.banner-single .banner-catption-wrapper .caption-subtitle,
    6045 .banner-section.banner-style-1 .slick-active .banner-single .banner-catption-wrapper .caption-subtitle {
    6046         animation-delay: 0.2s;
    6047 }
    6048 
    6049 .banner-section.banner-style-1 .slick-active.banner-single .banner-catption-wrapper .banner-caption-title,
    6050 .banner-section.banner-style-1 .slick-active .banner-single .banner-catption-wrapper .banner-caption-title {
    6051         animation-delay: 0.3s;
    6052 }
    6053 
    6054 .banner-section.banner-style-1 .slick-active.banner-single .banner-catption-wrapper .caption-description,
    6055 .banner-section.banner-style-1 .slick-active .banner-single .banner-catption-wrapper .caption-description {
    6056         animation-delay: 0.4s;
    6057 }
    6058 
    6059 .banner-section.banner-style-1 .slick-active.banner-single .banner-catption-wrapper .banner-slider-btn,
    6060 .banner-section.banner-style-1 .slick-active .banner-single .banner-catption-wrapper .banner-slider-btn {
    6061         animation-delay: 0.5s;
    6062 }
    6063 
    6064 @keyframes asterthemes-animation1 {
    6065         from {
    6066                 opacity: 0;
    6067                 transform: translateY(100px);
    6068         }
    6069         to {
    6070                 opacity: 1;
    6071                 transform: translateY(0);
    6072         }
    6073 }
    6074 
    60756030/* --------------------------------------------- */
    60766031/* products section CSS start
  • auto-mechanic/4.7/template-parts/content-image.php

    r284549 r318978  
    1313
    1414<article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
    15         <div class="mag-post-single <?php echo esc_attr( get_theme_mod( 'auto_mechanic_enable_animation', true ) ? 'wow zoomIn delay-1000' : '' ); ?>">
     15        <div class="mag-post-single wow zoomIn delay-1000">
    1616                <div class="mag-post-img">
    1717                        <?php auto_mechanic_post_thumbnail(); ?>
  • auto-mechanic/4.7/template-parts/content.php

    r284549 r318978  
    1313
    1414<article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
    15         <div class="mag-post-single <?php echo esc_attr( get_theme_mod( 'auto_mechanic_enable_animation', true ) ? 'wow zoomIn delay-1000' : '' ); ?>">
     15        <div class="mag-post-single wow zoomIn delay-1000">
    1616                <div class="mag-post-img">
    1717                        <?php auto_mechanic_post_thumbnail(); ?>
  • auto-mechanic/4.7/theme-library/customizer/front-page-options/banner.php

    r255860 r318978  
    189189        );
    190190}
     191
     192// Banner Button Label Color
     193$wp_customize->add_setting(
     194        'auto_mechanic_banner_btn_color',
     195        array(
     196                'default' => '',
     197                'sanitize_callback' => 'sanitize_hex_color',
     198        )
     199);
     200$wp_customize->add_control(new WP_Customize_Color_Control($wp_customize,'auto_mechanic_banner_btn_color',array(
     201                        'label' => __('Banner Button Label Color','auto-mechanic'),
     202                        'section' => 'auto_mechanic_banner_section',
     203                        'settings' => 'auto_mechanic_banner_btn_color',
     204                        'active_callback' => 'auto_mechanic_is_banner_slider_section_enabled',
     205                )
     206        )
     207);
     208
     209// Banner Button Background Color
     210$wp_customize->add_setting('auto_mechanic_banner_btn_bg_color',array(
     211                'default' => '',
     212                'sanitize_callback' => 'sanitize_hex_color',
     213        )
     214);
     215$wp_customize->add_control(new WP_Customize_Color_Control($wp_customize,'auto_mechanic_banner_btn_bg_color',array(
     216                        'label' => __('Banner Button Background Color','auto-mechanic'),
     217                        'section' => 'auto_mechanic_banner_section',
     218                        'settings' => 'auto_mechanic_banner_btn_bg_color',
     219                        'active_callback' => 'auto_mechanic_is_banner_slider_section_enabled',
     220                )
     221        )
     222);
  • auto-mechanic/4.7/theme-library/customizer/theme-options/post-options.php

    r314891 r318978  
    471471);
    472472
    473 //Show / Hide Animations
    474 $wp_customize->add_setting(
    475         'auto_mechanic_enable_animation',
    476         array(
    477                 'default'           => true,
    478                 'sanitize_callback' => 'auto_mechanic_sanitize_switch',
    479         )
    480 );
    481 
    482 $wp_customize->add_control(
    483         new Auto_Mechanic_Toggle_Switch_Custom_Control(
    484                 $wp_customize,
    485                 'auto_mechanic_enable_animation',
    486                 array(
    487                         'label'   => esc_html__( 'Show / Hide Post Animation', 'auto-mechanic' ),
    488                         'section' => 'auto_mechanic_post_options',
    489                 )
    490         )
    491 );
    492 
    493473$wp_customize->add_setting('auto_mechanic_show_first_caps', array(
    494474        'default'           => false,
  • auto-mechanic/4.7/theme-library/customizer/theme-options/theme-options.php

    r284549 r318978  
    574574    ),
    575575)));
     576
     577// ---------------------------------------- ANIMATION ----------------------------------------------------
     578
     579$wp_customize->add_setting( 'auto_mechanic_animation_separator', array(
     580        'sanitize_callback' => 'sanitize_text_field',
     581) );
     582$wp_customize->add_control( new Auto_Mechanic_Separator_Custom_Control( $wp_customize, 'auto_mechanic_animation_separator', array(
     583        'label' => __( 'Enable / Disable Animation', 'auto-mechanic' ),
     584        'section' => 'auto_mechanic_general_options',
     585        'settings' => 'auto_mechanic_animation_separator',
     586) ) );
     587// Animation Enable / Disable
     588$wp_customize->add_setting('auto_mechanic_enable_animation',array(
     589                'default'           => true,
     590                'sanitize_callback' => 'auto_mechanic_sanitize_switch',
     591        )
     592);
     593$wp_customize->add_control(
     594        new Auto_Mechanic_Toggle_Switch_Custom_Control($wp_customize,'auto_mechanic_enable_animation',array(
     595                        'label'   => esc_html__( 'Enable Animation', 'auto-mechanic' ),
     596                        'section' => 'auto_mechanic_general_options',
     597                )
     598        )
     599);
     600
     601// Topbar Padding Setting
     602$wp_customize->add_setting('auto_mechanic_topbar_padding',array(
     603                'default' => '',
     604                'sanitize_callback' => 'absint'
     605        )
     606);
     607$wp_customize->add_control('auto_mechanic_topbar_padding',array(
     608                'label' => __('Topbar Padding','auto-mechanic'),
     609                'section' => 'auto_mechanic_header_options',
     610                'type' => 'number',
     611                'input_attrs' => array(
     612                        'min' => 0,
     613                        'max' => 50,
     614                        'step' => 1
     615                )
     616        )
     617);
  • auto-mechanic/4.7/theme-library/function-files/customizer-settings-functions.php

    r314891 r318978  
    416416}
    417417add_action( 'wp_enqueue_scripts', 'auto_mechanic_show_first_caps' );
     418
     419// Topbar Padding Dynamic CSS
     420function auto_mechanic_topbar_padding_css(){
     421        $padding = get_theme_mod('auto_mechanic_topbar_padding');
     422        $custom_css = ".top-header-part{
     423                padding-top: {$padding}px !important;
     424                padding-bottom: {$padding}px !important;
     425        }";
     426        wp_add_inline_style('auto-mechanic-style',$custom_css);
     427
     428}
     429add_action('wp_enqueue_scripts','auto_mechanic_topbar_padding_css');
     430
     431// Banner Button Color
     432function auto_mechanic_banner_button_color_css() {
     433    $btn_color = get_theme_mod('auto_mechanic_banner_btn_color');
     434        $btn_bg_color = get_theme_mod('auto_mechanic_banner_btn_bg_color');
     435
     436        $custom_css = '';
     437    if ( !empty($btn_color) ) {
     438                $custom_css .= "
     439                .banner-slider-btn a.asterthemes-button{
     440                        color: {$btn_color};
     441                }";
     442        }
     443
     444        if ( !empty($btn_bg_color) ) {
     445                $custom_css .= "
     446                .banner-slider-btn a.asterthemes-button{
     447                        background-color: {$btn_bg_color};
     448                }";
     449        }
     450
     451        wp_add_inline_style('auto-mechanic-style', $custom_css);
     452}
     453add_action('wp_enqueue_scripts','auto_mechanic_banner_button_color_css');
Note: See TracChangeset for help on using the changeset viewer.