[WP]修改WP插件样式(简码插入)思路之一(修改AudioIgniter插件样式)

/ 4,439评论 / 17657阅读 / 0点赞

简介

修改插件样式的方式有多种,可以直接通过wordpress自带的插件文件编辑器修改插件文件,但显然插件更新时需要重新修改。本文将介绍通过”自定义HTML“模块来修改通过简码插入的插件样式。


前言/起因

起初是想建一个在线播放音乐的网站,需要一个音乐播放器插件,且需要带有播放列表,循环播放等功能。但一直找不到好用的,最后找到了一个功能上满足我的基本需求的插件:AudioIgniter。但它的外观没有长在我的审美上,于是用上刚学俩星期的前端三件套,走上了自己动手,丰衣足食的道路。


AudioIgniter样式对比


AudioIgniter插件样式源码/使用方法

样式源码

<style>
/*取消原来的部分设置*/
.ai-wrap .ai-track.ai-track-active, .ai-wrap .ai-track:hover {
    background-color: transparent;  
    background: rgba( 255, 255, 255, 0.25);
}
.ai-wrap .ai-track {
    background-color: transparent;
}
.ai-wrap .ai-track-control{
    border-left: transparent;
}

/*播放器背景div*/
.ai-wrap{
    background: linear-gradient(200deg,#8eeac7,#b5e6fe);
    /* 溢出隐藏 */
    overflow: hidden;
    /*圆角*/
    border-radius: 30px;
    /* 阴影 */
    box-shadow: 0 5px 20px rgba(102,204,255,2);
}

/*播放列表*/
.ai-track{}
.ai-track:hover, .ai-track-active{
    background: rgba( 255, 255, 255, 0.5 );
    backdrop-filter: blur( 6px );
    -webkit-backdrop-filter: blur( 6px );
    border-radius: 10px;
    border: 1px solid rgba( 255, 255, 255, 0.3);
    /* 阴影 */
    box-shadow: 0 2px 20px rgba(208, 216, 222, 1);
}
.ai-track-name{
    font-weight: 900;
    color:#535273;
}

/*专辑图*/
.ai-wrap .ai-track-no-thumb, .ai-wrap .ai-control-wrap-thumb{
    background-color: transparent;
}
.ai-track-no-thumb, .ai-track-thumb, .ai-wrap .ai-control-wrap-thumb{
    background: rgba( 255, 255, 255, 0.2);
    backdrop-filter: blur( 20px );
    -webkit-backdrop-filter: blur( 20px );
    border-radius: 10px;
    /* 阴影 */
    box-shadow: 0 2px 20px rgba(208, 216, 222, 1);
}


/*正在播放歌曲的标题*/
.ai-track-title span{
    font-weight: 900;
    color: #535273;
}
.ai-track-subtitle span{
    color:#b187a2;
}

/*播放/暂停按钮*/
.ai-wrap .ai-audio-control, .ai-wrap .ai-audio-control:focus{
    background-color: transparent;
    background: rgba( 255, 255, 255, 0.1);
    backdrop-filter: blur( 20px );
    -webkit-backdrop-filter: blur( 20px );
    border-radius: 50px;
    border: 1px solid rgba( 255, 255, 255, 0.3);
    /* 阴影 */
    box-shadow: 0 2px 20px rgba(208, 216, 222, 1);
}
.ai-wrap .ai-audio-control:hover, .ai-wrap .ai-btn:hover, .ai-wrap .ai-btn.ai-btn-active:hover{
    background: rgba( 255, 255, 255, 0.35);
}

/*控制按钮*/
.ai-wrap .ai-btn{
    background-color: transparent;
    background: transparent;
    border-radius: 10px;
    border: transparent;
}

/*循环播放按钮,选中状态*/
.ai-wrap .ai-btn.ai-btn-active{
    background-color:transparent;
}
.ai-wrap .ai-btn.ai-btn-active svg{
    fill: #66ccff;
}

/*音量条*/
.ai-wrap .ai-volume-bar {
    background-color: transparent;
    border-right: transparent;
}
.ai-wrap .ai-volume-bar:before {
    background-color: #b7eee7;
}
.ai-wrap .ai-volume-bar.ai-volume-bar-active:before{
    background-color: #d9f6f3;
}

/*进度条*/
.ai-wrap .ai-track-progress-bar{
    border-radius: 50px;
    background-color: #b8eee7;
}
.ai-wrap .ai-track-progress{
    border-radius: 50px;
    background-color: #66ccff;
}

/*滚动条*/
.ai-wrap .ai-scroll-wrap>div:last-child{
    background-color: #b5eee4;
}
.ai-wrap .ai-scroll-wrap>div:last-child div{
    background-color: #d9f6f3!important;
}
</style>

使用方法:


思路

<style>
.ai-wrap {
    background-color: #66ccff;
}
</style>

疑难杂症

如果想改的元素没有类名也没有id怎么办?

.ai-wrap .ai-scroll-wrap>div:last-child div {
    background-color: #f70f5d!important;
}
.ai-wrap .ai-scroll-wrap>div:last-child div {
    background-color: #66ccff!important;
}

  1. Douglasnug说道:

    purple pharmacy mexico price list: Purple pharmacy online ordering – mexico pharmacies prescription drugs

  2. Leonardskarm说道:

    http://edpillpharmacy.store/# erectile dysfunction medication online

  3. Douglasnug说道:

    buying from online mexican pharmacy: Best pharmacy in Mexico – purple pharmacy mexico price list

  4. Hi! I just wish to offer you a huge thumbs up for your great information you have here on this post. I’ll be coming back to your site for more soon.

  5. Howdy! I could have sworn I’ve been to your blog before but after looking at many of the posts I realized it’s new to me. Nonetheless, I’m definitely happy I discovered it and I’ll be bookmarking it and checking back frequently!

  6. Douglasnug说道:

    best ed pills online: ED meds online with insurance – affordable ed medication

  7. Douglasnug说道:

    mexican rx online: mexico pharmacy win – mexican border pharmacies shipping to usa

  8. Douglasnug说道:

    pharmacy website india: Online pharmacy – best online pharmacy india

  9. Leonardskarm说道:

    http://mexicopharmacy.win/# mexico pharmacies prescription drugs

  10. The next time I read a blog, I hope that it does not fail me just as much as this particular one. I mean, Yes, it was my choice to read, nonetheless I genuinely thought you would have something helpful to say. All I hear is a bunch of whining about something that you can fix if you weren’t too busy searching for attention.

  11. ngentot pepek说道:

    Saved as a favorite, I like your site.

  12. Douglasnug说道:

    indian pharmacy: Top mail order pharmacies – indian pharmacy

  13. memek说道:

    This is a topic that’s near to my heart… Best wishes! Where are your contact details though?

  14. Douglasnug说道:

    where can i buy ed pills: Best ED meds online – order ed pills

  15. Leonardskarm说道:

    https://indiapharmacy.shop/# Online medicine home delivery

  16. The New Backpage说道:

    Oh my goodness! Awesome article dude! Thank you so much, However I am experiencing problems with your RSS. I don’t know why I am unable to join it. Is there anybody getting identical RSS issues? Anyone who knows the solution will you kindly respond? Thanx!!

  17. The New Backpage说道:

    Good post. I learn something totally new and challenging on blogs I stumbleupon on a daily basis. It’s always exciting to read through articles from other authors and practice something from their web sites.

  18. Douglasnug说道:

    mexico pharmacies prescription drugs: mexico drug stores pharmacies – mexico drug stores pharmacies

  19. Douglasnug说道:

    mexican online pharmacies prescription drugs: mexican pharmacy – mexico pharmacies prescription drugs

  20. I like it when folks get together and share views. Great website, continue the good work.

  21. Douglasnug说道:

    indian pharmacies safe: Top online pharmacy in India – buy medicines online in india

  22. Douglasnug说道:

    top 10 pharmacies in india: Online pharmacy – п»їlegitimate online pharmacies india

  23. Leonardskarm说道:

    https://indiapharmacy.shop/# indian pharmacy online

  24. Douglasnug说道:

    ed pills cheap: ed pills online – low cost ed meds online

  25. Douglasnug说道:

    cheapest online pharmacy india: Online medicine home delivery – world pharmacy india

  26. Saved as a favorite, I like your site.

  27. Leonardskarm说道:

    http://indiapharmacy.shop/# cheapest online pharmacy india

  28. Douglasnug说道:

    mexico pharmacies prescription drugs: Best online Mexican pharmacy – mexico pharmacies prescription drugs

  29. article说道:

    Aw, this was a very good post. Taking the time and actual effort to make a very good article… but what can I say… I hesitate a whole lot and don’t seem to get nearly anything done.

  30. Georgemuh说道:

    cialis us pharmacy: Buy Tadalafil 20mg – buy cialis online free shipping

  31. Georgemuh说道:

    cialis on line overnight: Generic Cialis without a doctor prescription – cialis generic overnite

  32. download mp3说道:

    You should be a part of a contest for one of the finest websites on the net. I most certainly will recommend this site!

  33. Georgemuh说道:

    us pharmacy cialis: cheapest tadalafil – cialis 5mg daily how long before it works

  34. Samuelrip说道:

    http://tadalafil.auction/# lowest price cialis

  35. Georgemuh说道:

    viagra pills: buy sildenafil online canada – п»їover the counter viagra

  36. on their website说道:

    Very nice blog post. I definitely appreciate this site. Continue the good work!

  37. You made some good points there. I checked on the net to find out more about the issue and found most individuals will go along with your views on this site.

  38. Georgemuh说道:

    buy generic viagra online: Buy Viagra online in USA – viagra without a doctor prescription usa

  39. Georgemuh说道:

    cialis canada purchase: Buy Cialis online – buy cialis pro

  40. Samuelrip说道:

    http://sildenafil.llc/# cost of viagra

  41. Georgemuh说道:

    viagra: Buy Viagra online in USA – buy viagra

  42. Timothyomide说道:

    https://viagragenerico.site/# pillole per erezione immediata

  43. RandyBulty说道:

    acquistare farmaci senza ricetta: sildenafil oral jelly 100mg kamagra – acquisto farmaci con ricetta

  44. video chat说道:

    This site truly has all the info I wanted about this subject and didn’t know who to ask.

  45. RandyBulty说道:

    farmacia online: Cialis generico prezzo – farmaci senza ricetta elenco

  46. free sex chat说道:

    I really like looking through a post that will make people think. Also, many thanks for permitting me to comment.

  47. kontol说道:

    After I initially commented I appear to have clicked the -Notify me when new comments are added- checkbox and now whenever a comment is added I receive 4 emails with the same comment. There has to be a way you can remove me from that service? Thank you.

  48. RandyBulty说道:

    farmaci senza ricetta elenco: kamagra gel prezzo – comprare farmaci online con ricetta

  49. memek说道:

    Great info. Lucky me I found your blog by accident (stumbleupon). I have bookmarked it for later.

  50. RandyBulty说道:

    comprare farmaci online all’estero: kamagra oral jelly consegna 24 ore – Farmacie online sicure

发表回复

您的电子邮箱地址不会被公开。 必填项已用 * 标注