- This topic has 13 replies, 3 voices, and was last updated 4 years, 8 months ago by Leo.
-
AuthorPosts
-
August 25, 2019 at 3:30 pm #993310tenchystryder
Hi guys
Well finally installed Woocommerce and had a little help and a few tips from David earlier.
One thing I cannot seem to resolve even after searching the GP forums is the cart icon size and position.(display cart in menu option). I have “Display mini cart sub-menu” option active also.
I use mega menu and it has placed it directly to the right, and the icon is quite small.Would be really good (better) if I could have it within the top bar to the right, I would move/remove the other bit about as required.
Is this possible ?
August 25, 2019 at 4:45 pm #993347TomLead DeveloperLead DeveloperHi there,
We can make it bigger with some CSS:
nav li.wc-menu-item { line-height: 90px; } nav li.wc-menu-item a { font-size: 25px; }
If you want to add it to the top bar, you would need to implement a Secondary Navigation and set it to display in the top bar: https://docs.generatepress.com/article/top-bar-widget-area/#secondary-navigation
Then you can move the menu item into the secondary nav like this: https://docs.generatepress.com/article/generate_woocommerce_menu_item_location/
Let us know if you need more info π
August 26, 2019 at 12:56 am #993497tenchystryderHi Tom
Hope your wellSo I have moved it OK.
The CSS you gave me has not affected the icon size of the cart.
Is that code for the basket icon or the pop out mini cart overall size ?August 26, 2019 at 1:57 am #993528tenchystryderRight. Quick update. If I increase the font size in secondary nav, the icon grows as well.
Also, The secondary nav isn’t showing on mobile devices. I’ve tried a few settings for sticky nav etc but no good.August 26, 2019 at 9:10 am #993928TomLead DeveloperLead DeveloperThat CSS is for the icon size – not the mini cart. What about the mini cart are you trying to adjust?
Try adding this to show it on mobile:
@media (max-width: 768px) { .secondary-navigation ul { display: block; } }
August 26, 2019 at 9:46 am #993953tenchystryderThe mini cart (pop out) is fine, I wanted the cart icon bigger, That code isn’t working Tom.
Now have visibility on mobile device though thank you.
Another thing, The icon won’t align left on that top nav bar. The links move but the icon stays over on the right …. Not too worried about this but would like to know why it won’t move with everything else
August 26, 2019 at 9:51 am #993958tenchystryderThe line-height changes the section overall height including the view basket and checkout buttons on the pop-out part of cart.
Changing the px size of this isn’t doing anything Tom.
nav li.wc-menu-item a { font-size: 20px; }
August 26, 2019 at 10:13 am #993973LeoStaffCustomer SupportHi there,
Try this CSS instead:
.secondary-navigation .main-nav ul li.wc-menu-item > a:before { font-size: 15px; }
Let me know π
August 26, 2019 at 10:30 am #993988tenchystryderClose. But changed the price size also AND everything in the pop out cart LOL. It was massive
I might just give up and settle for what I have ha ha
August 26, 2019 at 10:47 am #993994LeoStaffCustomer SupportDon’t give up yet π
Can you try the edited CSS?
https://generatepress.com/forums/topic/cart-icon-size-and-position/#post-993973August 26, 2019 at 10:49 am #993997tenchystryderHi Leo
It was that css I was referring to. It changed the icon, the amount (£££) in the basket and everything in the pop out cart when you hover over it
August 26, 2019 at 10:53 am #993999LeoStaffCustomer SupportAugust 26, 2019 at 10:55 am #994001tenchystryderThat worked. Brilliant thank you Leo and Tom
Great work.
August 26, 2019 at 10:56 am #994002LeoStaffCustomer SupportGlad we could help π
-
AuthorPosts
- You must be logged in to reply to this topic.