cart icon position is top:-20 when scroll

eCommerce WordPress theme with various e-store features and WooCommerce support.
GK User
Wed Mar 04, 2015 4:23 pm
Hi guys, please, check this website:

http://skinius.testwp.net/

If you scroll, the cart icon does not stay at the right place. Can you help me?
User avatar
Expert Boarder

GK User
Wed Mar 04, 2015 11:33 pm
Hi,
Add the following code into the theme’s css/override.css file (make sure to enable the “Use the override.css file” option in Template options > Advanced in the WordPress backend)

Code: Select all
#btn-cart {
margin-top: 60px;
}
User avatar
Moderator

GK User
Thu Mar 05, 2015 10:11 am
Thank you Piotr!

Now the cart it's perfect when you scroll, but is a little bit too down in the start position. Do you know if it's possible to keep the same position?
User avatar
Expert Boarder

GK User
Fri Mar 06, 2015 8:37 am
Hi,

In this case, please remove css modifications, edit StoreBox/js/gk.scripts.js file and edit this fragment:

Code: Select all
if (scroll > 70) {
                        if (scroll < max - 122) {
                            final = scroll - 50;
                        } else {
                            final = max - 172;
                        }
                    } else {
                        final = 20;
                    }

change final values (50, 172, 20) to your own (trial and error method).
User avatar
Moderator

GK User
Sat Mar 07, 2015 5:00 pm
Thank you!
User avatar
Expert Boarder


cron