Woocommerce中的迷你购物车按钮是错误的吗?(Mini Cart button in Woocommerce is misalligned?)

编程入门 行业动态 更新时间:2024-10-14 16:19:36
Woocommerce中的迷你购物车按钮是错误的吗?(Mini Cart button in Woocommerce is misalligned?)

我的网站一直工作到昨天,当更新一些插件后,我的迷你购物车下拉按钮开始显示奇怪和错误。

更新插件之前,按钮有这种风格:

background-color: #070bf7; padding: 10.5px; border-radius: 15px; color: #ffffff !important;

目前有这个CSS类:

a.festi-cart div.festi-cart-content { display: inline-block; font-style: normal; text-align: left; }

所以将内容放入按钮中,就像产品数量和价格一样显示一个,而不是像左侧的按钮Muj Ucet一样内联。 那么如何像每个普通按钮一样显示按钮内容?

My site worked perfectly until yesterday, when after updating some plugins my Mini Cart dropdown button started to show weird and misalligned.

Before updating plugins button haved this style:

background-color: #070bf7; padding: 10.5px; border-radius: 15px; color: #ffffff !important;

and currently have this CSS class:

a.festi-cart div.festi-cart-content { display: inline-block; font-style: normal; text-align: left; }

so content into button, like number of products and price showing one bellow other, instead showing inline like button Muj Ucet from left side. So how to show button content inline, like every normal button?

最满意答案

所以事情

1)内联对齐在你的style.css行1077中,你有下一个样式

.sf-menu li a span { font-size: 12px; font-family: tahoma; font-weight: normal; text-transform: none; display: block; color: rgba(167, 167, 167, 0.9); margin: 10px 0 0 0; }

此样式会影响您按钮内的跨度。 而且因为他们有一个display: block它会打破你的按钮

固定

添加下一个代码:

.sf-menu li a span { display: inline !important; }

2)你的按钮样式。 我不知道他们发生了什么,但是你可以再次添加它们。可能是插件更改中的一个类,并且在更新时丢失了样式。

固定

.festi-cart-content { background-color: #070bf7; padding: 3px 10px; border-radius: 15px; color: #ffffff !important; }

最终结果

最终结果

希望这有助于:>

So to thing

1) The inline alignment In your style.css line 1077 you have the next style

.sf-menu li a span { font-size: 12px; font-family: tahoma; font-weight: normal; text-transform: none; display: block; color: rgba(167, 167, 167, 0.9); margin: 10px 0 0 0; }

This style affect your spans inside that button. And because they have a display: block it breaks your button

FIX

Add the next code:

.sf-menu li a span { display: inline !important; }

2) Your button styles. I dont know what happend to them but you can just add them again.May be a class from the plugin change and lost the styles on the update.

FIX

.festi-cart-content { background-color: #070bf7; padding: 3px 10px; border-radius: 15px; color: #ffffff !important; }

END RESULT

End Result

Hope this helps :>

更多推荐

本文发布于:2023-08-06 10:10:00,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1446904.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:购物车   按钮   错误   Woocommerce   misalligned

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!