From 4be1b34b2ab683cd4719e0ad751eea09be5815f9 Mon Sep 17 00:00:00 2001 From: TruongSa Date: Mon, 10 Sep 2018 15:03:31 +0700 Subject: [PATCH] Update sections navigation settings --- assets/js/customizer-liveview.js | 2 +- assets/sass/_bully.scss | 42 ++++++++++++++++--------------- inc/class-sections-navigation.php | 36 +++++++++++++++----------- style.css | 25 ++++-------------- 4 files changed, 49 insertions(+), 56 deletions(-) diff --git a/assets/js/customizer-liveview.js b/assets/js/customizer-liveview.js index 88769ca9..e0cb8b19 100644 --- a/assets/js/customizer-liveview.js +++ b/assets/js/customizer-liveview.js @@ -81,7 +81,7 @@ var css_code = $( '#onepress-style-inline-css' ).html(); // Fix Chrome Lost CSS When resize ?? $( '#onepress-style-inline-css' ).replaceWith( '' ); - + } // When preview ready diff --git a/assets/sass/_bully.scss b/assets/sass/_bully.scss index 610899ea..45d721cc 100644 --- a/assets/sass/_bully.scss +++ b/assets/sass/_bully.scss @@ -42,33 +42,35 @@ &title { position: absolute; - right: 35px; - top: 0px; + right: 26px; + top: 1px; left: auto; - background: rgba( 0,0,0, .6 ); - padding: 3px 10px; + background: rgba( 0,0,0, .7 ); + padding: 1px 10px; + border-radius: 2px; transition: all 0.2s ease-out; display: block; opacity: 0; white-space: nowrap; color: rgba( 255, 255, 255, .8); transform: scale(.6); - &::after { - content: ''; - width: 0; - height: 0; - border-style: solid; - border-width: 13px 0 13px 13px; - border-color: transparent transparent transparent rgba(0, 0, 0, .6); - display: inline-block; - position: absolute; - right: 0px; - top: 50%; - transform: translate(100%, -50%); - border-radius: 2px; - border-top-right-radius: 1px; - border-bottom-right-radius: 1px; - } + + //&::after { + // content: ''; + // width: 0; + // height: 0; + // border-style: solid; + // border-width: 13px 0 13px 13px; + // border-color: transparent transparent transparent rgba(0, 0, 0, .6); + // display: inline-block; + // position: absolute; + // right: 0px; + // top: 50%; + // transform: translate(100%, -50%); + // border-radius: 2px; + // border-top-right-radius: 1px; + // border-bottom-right-radius: 1px; + //} } } diff --git a/inc/class-sections-navigation.php b/inc/class-sections-navigation.php index 0011335a..ee86d0c2 100644 --- a/inc/class-sections-navigation.php +++ b/inc/class-sections-navigation.php @@ -37,57 +37,63 @@ function get_sections(){ 'hero' => array( 'label' => __( 'Section: Hero', 'onepress' ), 'title' => __( 'Home', 'onepress' ), - 'default' => 1, - 'inverse' => 1, + 'default' => false, + 'inverse' => false, ), 'about' => array( 'label' => __( 'Section: About', 'onepress' ), 'title' => __( 'About Us', 'onepress' ), - 'default' => 1, + 'default' => false, 'inverse' => false, ), 'contact' => array( 'label' => __( 'Section: Contact', 'onepress' ), 'title' => __( 'Get in touch', 'onepress' ), - 'default' => 1, + 'default' => false, + 'inverse' => false, ), 'counter' => array( 'label' => __( 'Section: Counter', 'onepress' ), 'title' => __( 'Our Numbers', 'onepress' ), - 'default' => 1, - 'inverse' => 1, + 'default' => false, + 'inverse' => false, ), 'features' => array( 'label' => __( 'Section: Features', 'onepress' ), 'title' => __( 'Features', 'onepress' ), - 'default' => 1 + 'default' => false, + 'inverse' => false, ), 'gallery' => array( 'label' => __( 'Section: Gallery', 'onepress' ), 'title' => __( 'Gallery', 'onepress' ), - 'default' => 1 + 'default' => false, + 'inverse' => false, ), 'news' => array( 'label' => __( 'Section: News', 'onepress' ), 'title' => __( 'Latest News', 'onepress' ), - 'default' => 1 + 'default' => false, + 'inverse' => false, ), 'services' => array( 'label' => __( 'Section: Services', 'onepress' ), 'title' => __( 'Our Services', 'onepress' ), - 'default' => 1 + 'default' => false, + 'inverse' => false, ), 'team' => array( 'label' => __( 'Section: Team', 'onepress' ), 'title' => __( 'Our Team', 'onepress' ), - 'default' => 1 + 'default' => false, + 'inverse' => false, ), 'videolightbox' => array( 'label' => __( 'Section: Video Lightbox', 'onepress' ), 'title' => '', - 'default' => 1, - 'inverse' => 1, + 'default' => false, + 'inverse' => false, ), ); @@ -133,7 +139,7 @@ function add_customize( $wp_customize, $section_id ){ ); $wp_customize->add_control( $this->get_name( '__enable' ), array( - 'label' => __( 'Enable section navigation', 'onepress' ), + 'label' => __( 'Enable in section navigation', 'onepress' ), 'section' => $section_id, 'type' => 'checkbox', ) @@ -210,7 +216,7 @@ function add_customize( $wp_customize, $section_id ){ ); $wp_customize->add_control( $name, array( - 'label' => __( 'Enable section navigation', 'onepress' ), + 'label' => __( 'Enable in section navigation', 'onepress' ), 'section' => $section_id, 'type' => 'checkbox', ) diff --git a/style.css b/style.css index b8c6c382..73a1ab54 100644 --- a/style.css +++ b/style.css @@ -4265,11 +4265,12 @@ img.mfp-img { } .c-bully__title { position: absolute; - right: 35px; - top: 0px; + right: 26px; + top: 1px; left: auto; - background: rgba(0, 0, 0, 0.6); - padding: 3px 10px; + background: rgba(0, 0, 0, 0.7); + padding: 1px 10px; + border-radius: 2px; transition: all 0.2s ease-out; display: block; opacity: 0; @@ -4277,22 +4278,6 @@ img.mfp-img { color: rgba(255, 255, 255, 0.8); transform: scale(0.6); } -.c-bully__title::after { - content: ''; - width: 0; - height: 0; - border-style: solid; - border-width: 13px 0 13px 13px; - border-color: transparent transparent transparent rgba(0, 0, 0, 0.6); - display: inline-block; - position: absolute; - right: 0px; - top: 50%; - transform: translate(100%, -50%); - border-radius: 2px; - border-top-right-radius: 1px; - border-bottom-right-radius: 1px; -} .c-bully__bullet:after { content: "";