mirror of
https://github.com/the1812/Bilibili-Evolved.git
synced 2025-11-04 21:22:45 +08:00
Add "about"
This commit is contained in:
parent
4fa42708c1
commit
f90388a6cb
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -145,7 +145,7 @@ const fixedSettings = {
|
|||||||
downloadAudio: true,
|
downloadAudio: true,
|
||||||
playerLayout: true,
|
playerLayout: true,
|
||||||
medalHelper: true,
|
medalHelper: true,
|
||||||
about: false,
|
about: true,
|
||||||
forceWide: false,
|
forceWide: false,
|
||||||
useNewStyle: false,
|
useNewStyle: false,
|
||||||
overrideNavBar: false,
|
overrideNavBar: false,
|
||||||
@ -1547,7 +1547,7 @@ Resource.manifest = {
|
|||||||
about: {
|
about: {
|
||||||
path: "about.min.js",
|
path: "about.min.js",
|
||||||
html: true,
|
html: true,
|
||||||
style: "instant",
|
style: "important",
|
||||||
displayNames: {
|
displayNames: {
|
||||||
"about": "关于",
|
"about": "关于",
|
||||||
}
|
}
|
||||||
|
|||||||
@ -145,7 +145,7 @@ const fixedSettings = {
|
|||||||
downloadAudio: true,
|
downloadAudio: true,
|
||||||
playerLayout: true,
|
playerLayout: true,
|
||||||
medalHelper: true,
|
medalHelper: true,
|
||||||
about: false,
|
about: true,
|
||||||
forceWide: false,
|
forceWide: false,
|
||||||
useNewStyle: false,
|
useNewStyle: false,
|
||||||
overrideNavBar: false,
|
overrideNavBar: false,
|
||||||
@ -1547,7 +1547,7 @@ Resource.manifest = {
|
|||||||
about: {
|
about: {
|
||||||
path: "about.min.js",
|
path: "about.min.js",
|
||||||
html: true,
|
html: true,
|
||||||
style: "instant",
|
style: "important",
|
||||||
displayNames: {
|
displayNames: {
|
||||||
"about": "关于",
|
"about": "关于",
|
||||||
}
|
}
|
||||||
|
|||||||
@ -310,7 +310,7 @@ Resource.manifest = {
|
|||||||
about: {
|
about: {
|
||||||
path: "about.min.js",
|
path: "about.min.js",
|
||||||
html: true,
|
html: true,
|
||||||
style: "instant",
|
style: "important",
|
||||||
displayNames: {
|
displayNames: {
|
||||||
"about": "关于",
|
"about": "关于",
|
||||||
}
|
}
|
||||||
|
|||||||
@ -120,7 +120,7 @@ const fixedSettings = {
|
|||||||
downloadAudio: true,
|
downloadAudio: true,
|
||||||
playerLayout: true,
|
playerLayout: true,
|
||||||
medalHelper: true,
|
medalHelper: true,
|
||||||
about: false,
|
about: true,
|
||||||
forceWide: false,
|
forceWide: false,
|
||||||
useNewStyle: false,
|
useNewStyle: false,
|
||||||
overrideNavBar: false,
|
overrideNavBar: false,
|
||||||
|
|||||||
2
min/about.min.css
vendored
2
min/about.min.css
vendored
@ -1 +1 @@
|
|||||||
.about.gui-settings-footer{height:24px;font-size:14px;justify-content:space-between;padding:6px 24px;border-top:1px dashed #8884}.about.gui-settings-footer>span{opacity:.2}.bilibili-evolved-about{display:flex;width:400px;height:70vh;background-color:#fff;position:fixed;top:15%;left:calc(50% - 200px);z-index:100000;box-shadow:0 3px 20px 2px #0004;border-top:4px solid var(--theme-color);flex-direction:column;transition:.2s ease-out;transform-origin:center;transform:scale(0)}.bilibili-evolved-about.opened{transform:scale(1)}.bilibili-evolved-info a{margin:0 4px}.bilibili-evolved-info>p{margin:8px 0}.bilibili-evolved-about>div{flex:1 0 0;display:flex;align-items:center;justify-content:space-between;flex-direction:column;padding:8px}.bilibili-evolved-about>div.about-block{flex:4 0 0;padding:32px;align-items:stretch}.bilibili-evolved-about h1{font-size:36px;margin-bottom:16px}.bilibili-evolved-about h2{font-size:18px;margin-bottom:8px}.open-source-components>li{margin:12px 0;padding:12px 24px;background:rgba(0,0,0,.2);border-left:4px solid var(--theme-color);cursor:pointer;transition:.2s ease-out}.open-source-components>li:hover{opacity:.8}.component-name{font-size:18px;font-weight:700}.component-info{margin-top:8px}#about-link{cursor:pointer;transition:.2s}.bilibili-evolved-about a{color:var(--theme-color)}#about-link:hover{opacity:1;color:var(--theme-color)}#about-close{background-color:#8884;border-color:transparent;opacity:1;transition:.2s ease-out;width:80px;height:32px;color:inherit;cursor:pointer}#about-close:hover{opacity:.8}#about-close:active{outline:0;opacity:.6}
|
.bilibili-evolved-about{height:100%;width:400px;background:#fff;color:#000;position:fixed;top:0;left:0;z-index:100000;transform:translateX(-100%);transition:.3s cubic-bezier(0,.86,.58,1);display:flex;flex-direction:column;box-shadow:4px 0 16px 0 #0000}body.dark .bilibili-evolved-about{background:#222;color:#eee}.bilibili-evolved-about.opened{transform:translateX(0);box-shadow:4px 0 16px 0 #0005}
|
||||||
@ -1 +1 @@
|
|||||||
<div class=bilibili-evolved-about><div class=about-block><h1>Bilibili Evolved</h1><h2 class=bilibili-evolved-version></h2><div class=bilibili-evolved-info><p>作者:<a target=_blank href=https://github.com/the1812>Grant Howard</a>,<a target=_blank href=https://github.com/Coulomb-G>Coulomb-G</a><p>网站:<a target=_blank href=https://github.com/the1812/Bilibili-Evolved>GitHub</a></div></div><div class=about-block><h2>开源组件</h2><ul class=open-source-components></ul></div><div><button id=about-close>关闭</button></div></div>
|
<div class=bilibili-evolved-about><div class=gui-settings-header><i class="mdi mdi-information-outline mdi-24"></i><span class=gui-settings-title>关于</span></div></div>
|
||||||
2
min/about.min.js
vendored
2
min/about.min.js
vendored
@ -1 +1 @@
|
|||||||
(()=>{return(e,i)=>{$("body").append((i.data.aboutDom||i.data.aboutHtml).text);const n=GM_info.script.name.replace("Bilibili Evolved","").replace(/^[\(\) ]+|[\(\) ]+$/g,"")+" · "+e.currentVersion;$(".bilibili-evolved-version").text(n);const o=[{name:"jQuery",homepage:"https://jquery.com/",license:"MIT",version:"3.2.1"},{name:"JSZip",homepage:"https://stuk.github.io/jszip/",license:"MIT",version:"3.1.5"}];o.forEach(e=>{$(".open-source-components").append(`\n <li>\n <a target="_blank" href="${e.homepage}">\n <div class="component-name">${e.name}</div>\n <div class="component-info">${e.version} · ${e.license}</div>\n </a>\n </li>\n `)});function t(){$("#about-close").on("click",()=>{$(".bilibili-evolved-about").toggleClass("opened")});$(".gui-settings").on("click",e=>{if(e.shiftKey===true){$(".bilibili-evolved-about").toggleClass("opened")}})}return{widget:{success:t}}}})();
|
(()=>{return(t,n)=>{(async()=>{const t=await n.importAsync("aboutHtml");document.body.insertAdjacentHTML("beforeend",t)})()}})();
|
||||||
2
min/gui-settings.min.css
vendored
2
min/gui-settings.min.css
vendored
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
2
min/gui-settings.min.js
vendored
2
min/gui-settings.min.js
vendored
@ -1 +1 @@
|
|||||||
(()=>{return(e,t)=>{const{ThemeColors:n}=t.import("theme-colors");const{SettingsSearch:i}=t.import("settings-search");const{Validator:s}=t.import("text-validate");let o=[];let r=[];let c=[];function a(e){let t=e.nextElementSibling;const n=[];while(t!==null&&!t.classList.contains("category")){n.push(t);t=t.nextElementSibling}return n}function l(){c.forEach(t=>t.value=e[t.getAttribute("key")]);r.forEach(t=>t.checked=e[t.getAttribute("key")])}function u(){document.querySelector(".gui-settings-mask").addEventListener("click",()=>{document.querySelectorAll(".gui-settings-widgets-box,.gui-settings-box,.gui-settings-mask").forEach(e=>e.classList.remove("opened"))});c.forEach(t=>{t.setAttribute("placeholder",e[t.getAttribute("key")])});document.querySelectorAll(".gui-settings-content ul li.category").forEach(e=>{e.addEventListener("click",e=>{const t=document.querySelector(".gui-settings-search");if(t.value!==""){t.value="";raiseEvent(t,"input")}e.currentTarget.classList.toggle("folded");a(e.currentTarget).forEach(e=>e.classList.toggle("folded"))})});document.querySelectorAll(".gui-settings-dropdown>input").forEach(e=>{e.addEventListener("click",e=>{e.currentTarget.parentElement.classList.toggle("opened")})})}function d(){const t=e=>{};r.forEach(n=>{n.addEventListener("change",()=>{const i=n.getAttribute("key");const s=n.checked;e[i]=s;t(i);saveSettings(e)})});c.forEach(n=>{n.addEventListener("change",()=>{const i=n.getAttribute("key");const o=s.getValidator(i).validate(n.value);e[i]=o;n.value=o;t(i);saveSettings(e)})})}function g(){const e=o.map(e=>[e.getAttribute("dependencies").split(" ").map(e=>o.find(t=>t.getAttribute("key")===e)),e]);const t=e=>e.nodeName.toUpperCase()==="LI"?e:t(e.parentElement);e.forEach(([e,n])=>{if(e[0]===undefined){return}const i=()=>{if(e.every(e=>e.checked)){t(n).classList.remove("disabled")}else{t(n).classList.add("disabled")}};e.forEach(e=>e.addEventListener("change",i));i()})}function f(){if(typeof offlineData!=="undefined"){document.querySelector(".gui-settings-checkbox-container>input[key=useCache]").parentElement.parentElement.classList.add("disabled");document.querySelector("input[key=useCache]").disabled=true}}function m(){document.querySelectorAll(".gui-settings-content ul li.category").forEach(e=>{e.click()})}function b(){if(!CSS.supports("backdrop-filter","blur(24px)")&&!CSS.supports("-webkit-backdrop-filter","blur(24px)")){o.find(e=>e.getAttribute("key")==="blurVideoControl").disabled=true;e.blurVideoControl=false;saveSettings(e)}if(window.devicePixelRatio===1){o.find(e=>e.getAttribute("key")==="harunaScale").disabled=true;o.find(e=>e.getAttribute("key")==="imageResolution").disabled=true;e.harunaScale=false;e.imageResolution=false;saveSettings(e)}if(e.defaultPlayerLayout==="旧版"){const t=o.find(e=>e.getAttribute("key")==="overrideNavBar");t.disabled=true;raiseEvent(t,"change");if(e.overrideNavBar){t.checked=false;raiseEvent(t,"change");e.overrideNavBar=false;saveSettings(e)}}}function y(){for(const[e,t]of Object.entries(Resource.displayNames)){const n=o.find(t=>t.getAttribute("key")===e);if(!n){continue}switch(n.type){case"checkbox":n.nextElementSibling.nextElementSibling.innerHTML=t;break;case"text":const e=n.parentElement;if(e.classList.contains("gui-settings-textbox-container")){n.previousElementSibling.innerHTML=t}else if(e.classList.contains("gui-settings-dropdown")){e.previousElementSibling.innerHTML=t}break;default:break}}}(async()=>{t.applyStyle("guiSettingsStyle");document.body.insertAdjacentHTML("afterbegin",`<link rel="stylesheet" href="//cdn.materialdesignicons.com/3.5.95/css/materialdesignicons.min.css">`);const e=document.body&&unsafeWindow.parent.window!==unsafeWindow;if(e){document.querySelector(".gui-settings-icon-panel").style.display="none"}const s=(t.data.guiSettingsDom||t.data.guiSettingsHtml).text;document.body.insertAdjacentHTML("beforeend",s);const a=document.querySelector(".widgets-container");const p=a.querySelector(".empty-tip");Observer.childList(a,()=>{if(a.childElementCount<=1){p.classList.add("show")}else{p.classList.remove("show")}});o=[...document.querySelectorAll("input[key]")];r=o.filter(e=>e.type==="checkbox");c=o.filter(e=>e.type==="text");u();f();l();g();d();m();b();y();(new n).setupDom();new i;const h=document.querySelectorAll(".gui-settings-widgets-box,.gui-settings-box");document.querySelector(".gui-settings-icon-panel").addEventListener("mouseover",()=>{h.forEach(e=>e.classList.add("loaded"))},{once:true})})()}})();
|
(()=>{return(e,t)=>{const{ThemeColors:n}=t.import("theme-colors");const{SettingsSearch:i}=t.import("settings-search");const{Validator:s}=t.import("text-validate");let o=[];let r=[];let c=[];function a(e){let t=e.nextElementSibling;const n=[];while(t!==null&&!t.classList.contains("category")){n.push(t);t=t.nextElementSibling}return n}function l(){c.forEach(t=>t.value=e[t.getAttribute("key")]);r.forEach(t=>t.checked=e[t.getAttribute("key")])}function u(){document.querySelector(".gui-settings-mask").addEventListener("click",()=>{document.querySelectorAll(".gui-settings-widgets-box,.gui-settings-box,.gui-settings-mask,.bilibili-evolved-about").forEach(e=>e.classList.remove("opened"))});c.forEach(t=>{t.setAttribute("placeholder",e[t.getAttribute("key")])});document.querySelectorAll(".gui-settings-content ul li.category").forEach(e=>{e.addEventListener("click",e=>{const t=document.querySelector(".gui-settings-search");if(t.value!==""){t.value="";raiseEvent(t,"input")}e.currentTarget.classList.toggle("folded");a(e.currentTarget).forEach(e=>e.classList.toggle("folded"))})});document.querySelectorAll(".gui-settings-dropdown>input").forEach(e=>{e.addEventListener("click",e=>{e.currentTarget.parentElement.classList.toggle("opened")})})}function d(){const t=e=>{};r.forEach(n=>{n.addEventListener("change",()=>{const i=n.getAttribute("key");const s=n.checked;e[i]=s;t(i);saveSettings(e)})});c.forEach(n=>{n.addEventListener("change",()=>{const i=n.getAttribute("key");const o=s.getValidator(i).validate(n.value);e[i]=o;n.value=o;t(i);saveSettings(e)})})}function g(){const e=o.map(e=>[e.getAttribute("dependencies").split(" ").map(e=>o.find(t=>t.getAttribute("key")===e)),e]);const t=e=>e.nodeName.toUpperCase()==="LI"?e:t(e.parentElement);e.forEach(([e,n])=>{if(e[0]===undefined){return}const i=()=>{if(e.every(e=>e.checked)){t(n).classList.remove("disabled")}else{t(n).classList.add("disabled")}};e.forEach(e=>e.addEventListener("change",i));i()})}function f(){if(typeof offlineData!=="undefined"){document.querySelector(".gui-settings-checkbox-container>input[key=useCache]").parentElement.parentElement.classList.add("disabled");document.querySelector("input[key=useCache]").disabled=true}}function b(){document.querySelectorAll(".gui-settings-content ul li.category").forEach(e=>{e.click()})}function m(){if(!CSS.supports("backdrop-filter","blur(24px)")&&!CSS.supports("-webkit-backdrop-filter","blur(24px)")){o.find(e=>e.getAttribute("key")==="blurVideoControl").disabled=true;e.blurVideoControl=false;saveSettings(e)}if(window.devicePixelRatio===1){o.find(e=>e.getAttribute("key")==="harunaScale").disabled=true;o.find(e=>e.getAttribute("key")==="imageResolution").disabled=true;e.harunaScale=false;e.imageResolution=false;saveSettings(e)}if(e.defaultPlayerLayout==="旧版"){const t=o.find(e=>e.getAttribute("key")==="overrideNavBar");t.disabled=true;raiseEvent(t,"change");if(e.overrideNavBar){t.checked=false;raiseEvent(t,"change");e.overrideNavBar=false;saveSettings(e)}}}function y(){for(const[e,t]of Object.entries(Resource.displayNames)){const n=o.find(t=>t.getAttribute("key")===e);if(!n){continue}switch(n.type){case"checkbox":n.nextElementSibling.nextElementSibling.innerHTML=t;break;case"text":const e=n.parentElement;if(e.classList.contains("gui-settings-textbox-container")){n.previousElementSibling.innerHTML=t}else if(e.classList.contains("gui-settings-dropdown")){e.previousElementSibling.innerHTML=t}break;default:break}}}(async()=>{t.applyStyle("guiSettingsStyle");document.body.insertAdjacentHTML("afterbegin",`<link rel="stylesheet" href="//cdn.materialdesignicons.com/3.5.95/css/materialdesignicons.min.css">`);const e=document.body&&unsafeWindow.parent.window!==unsafeWindow;if(e){document.querySelector(".gui-settings-icon-panel").style.display="none"}const s=(t.data.guiSettingsDom||t.data.guiSettingsHtml).text;document.body.insertAdjacentHTML("beforeend",s);const a=document.querySelector(".widgets-container");const p=a.querySelector(".empty-tip");Observer.childList(a,()=>{if(a.childElementCount<=1){p.classList.add("show")}else{p.classList.remove("show")}});o=[...document.querySelectorAll("input[key]")];r=o.filter(e=>e.type==="checkbox");c=o.filter(e=>e.type==="text");u();f();l();g();d();b();m();y();(new n).setupDom();new i;const h=document.querySelectorAll(".gui-settings-widgets-box,.gui-settings-box");document.querySelector(".gui-settings-icon-panel").addEventListener("mouseover",()=>{h.forEach(e=>e.classList.add("loaded"))},{once:true})})()}})();
|
||||||
2
min/settings-side-bar.min.js
vendored
2
min/settings-side-bar.min.js
vendored
@ -1 +1 @@
|
|||||||
(()=>{return(i,s)=>{if($(".gui-settings-icon-panel").length===0){$("body").append(`\n <div class='gui-settings-icon-panel icons-enabled'>\n <div class='gui-settings-widgets' title='附加功能'>\n <i class="icon-widgets"></i>\n </div>\n <div class='gui-settings' title='设置'>\n <i class="icon-settings"></i>\n </div>\n </div>`);$(".gui-settings").on("click",i=>{if(i.shiftKey===false){$(".gui-settings-box,.gui-settings-mask").addClass("opened")}});$(".gui-settings-widgets").on("click",()=>{$(".gui-settings-widgets-box,.gui-settings-mask").addClass("opened")})}}})();
|
(()=>{return(e,i)=>{if(document.querySelector(".gui-settings-icon-panel")===null){document.body.insertAdjacentHTML("beforeend",`\n <div class='gui-settings-icon-panel icons-enabled'>\n <div class='gui-settings-widgets' title='附加功能'>\n <i class="icon-widgets"></i>\n </div>\n <div class='gui-settings' title='设置'>\n <i class="icon-settings"></i>\n </div>\n </div>`);document.querySelector(".gui-settings").addEventListener("click",e=>{if(e.shiftKey===false){document.querySelectorAll(".gui-settings-box,.gui-settings-mask").forEach(e=>e.classList.add("opened"))}else{document.querySelectorAll(".bilibili-evolved-about,.gui-settings-mask").forEach(e=>e.classList.add("opened"))}});document.querySelector(".gui-settings-widgets").addEventListener("click",()=>{document.querySelectorAll(".gui-settings-widgets-box,.gui-settings-mask").forEach(e=>e.classList.add("opened"))})}}})();
|
||||||
@ -1,122 +1,26 @@
|
|||||||
.about.gui-settings-footer
|
|
||||||
{
|
|
||||||
height: 24px;
|
|
||||||
font-size: 14px;
|
|
||||||
justify-content: space-between;
|
|
||||||
padding: 6px 24px;
|
|
||||||
border-top: 1px dashed #8884;
|
|
||||||
}
|
|
||||||
.about.gui-settings-footer>span
|
|
||||||
{
|
|
||||||
opacity: 0.2;
|
|
||||||
}
|
|
||||||
.bilibili-evolved-about
|
.bilibili-evolved-about
|
||||||
{
|
{
|
||||||
display: flex;
|
height: 100%;
|
||||||
width: 400px;
|
width: 400px;
|
||||||
height: 70vh;
|
background: white;
|
||||||
background-color: white;
|
color: #000;
|
||||||
position: fixed;
|
position: fixed;
|
||||||
top: 15%;
|
top: 0;
|
||||||
left: calc(50% - 200px);
|
left: 0;
|
||||||
z-index: 100000;
|
z-index: 100000;
|
||||||
box-shadow: 0px 3px 20px 2px #0004;
|
transform: translateX(-100%);
|
||||||
border-top: 4px solid var(--theme-color);
|
transition: all .3s cubic-bezier(0, 0.86, 0.58, 1);
|
||||||
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
transition: all .2s ease-out;
|
box-shadow: 4px 0px 16px 0px #0000;
|
||||||
transform-origin: center;
|
}
|
||||||
transform: scale(0);
|
body.dark .bilibili-evolved-about
|
||||||
|
{
|
||||||
|
background: #222;
|
||||||
|
color: #eee;
|
||||||
}
|
}
|
||||||
.bilibili-evolved-about.opened
|
.bilibili-evolved-about.opened
|
||||||
{
|
{
|
||||||
transform: scale(1);
|
transform: translateX(0);
|
||||||
}
|
box-shadow: 4px 0px 16px 0px #0005;
|
||||||
.bilibili-evolved-info a
|
|
||||||
{
|
|
||||||
margin: 0 4px;
|
|
||||||
}
|
|
||||||
.bilibili-evolved-info>p
|
|
||||||
{
|
|
||||||
margin: 8px 0;
|
|
||||||
}
|
|
||||||
.bilibili-evolved-about>div
|
|
||||||
{
|
|
||||||
flex: 1 0 0;
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
justify-content: space-between;
|
|
||||||
flex-direction: column;
|
|
||||||
padding: 8px;
|
|
||||||
}
|
|
||||||
.bilibili-evolved-about>div.about-block
|
|
||||||
{
|
|
||||||
flex: 4 0 0;
|
|
||||||
padding: 32px;
|
|
||||||
align-items: stretch;
|
|
||||||
}
|
|
||||||
.bilibili-evolved-about h1
|
|
||||||
{
|
|
||||||
font-size: 36px;
|
|
||||||
margin-bottom: 16px;
|
|
||||||
}
|
|
||||||
.bilibili-evolved-about h2
|
|
||||||
{
|
|
||||||
font-size: 18px;
|
|
||||||
margin-bottom: 8px;
|
|
||||||
}
|
|
||||||
.open-source-components>li
|
|
||||||
{
|
|
||||||
margin: 12px 0;
|
|
||||||
padding: 12px 24px;
|
|
||||||
background: rgba(0, 0, 0, 0.2);
|
|
||||||
border-left: 4px solid var(--theme-color);
|
|
||||||
cursor: pointer;
|
|
||||||
transition: all .2s ease-out;
|
|
||||||
}
|
|
||||||
.open-source-components>li:hover
|
|
||||||
{
|
|
||||||
opacity: 0.8;
|
|
||||||
}
|
|
||||||
.component-name
|
|
||||||
{
|
|
||||||
font-size: 18px;
|
|
||||||
font-weight: bold;
|
|
||||||
}
|
|
||||||
.component-info
|
|
||||||
{
|
|
||||||
margin-top: 8px;
|
|
||||||
}
|
|
||||||
#about-link
|
|
||||||
{
|
|
||||||
cursor: pointer;
|
|
||||||
transition: all .2s;
|
|
||||||
}
|
|
||||||
.bilibili-evolved-about a
|
|
||||||
{
|
|
||||||
color: var(--theme-color);
|
|
||||||
}
|
|
||||||
#about-link:hover
|
|
||||||
{
|
|
||||||
opacity: 1;
|
|
||||||
color: var(--theme-color);
|
|
||||||
}
|
|
||||||
#about-close
|
|
||||||
{
|
|
||||||
background-color: #8884;
|
|
||||||
border-color: transparent;
|
|
||||||
opacity: 1;
|
|
||||||
transition: all .2s ease-out;
|
|
||||||
width: 80px;
|
|
||||||
height: 32px;
|
|
||||||
color: inherit;
|
|
||||||
cursor: pointer;
|
|
||||||
}
|
|
||||||
#about-close:hover
|
|
||||||
{
|
|
||||||
opacity: 0.8;
|
|
||||||
}
|
|
||||||
#about-close:active
|
|
||||||
{
|
|
||||||
outline: none;
|
|
||||||
opacity: 0.6;
|
|
||||||
}
|
}
|
||||||
@ -1,25 +1,6 @@
|
|||||||
<div class="bilibili-evolved-about">
|
<div class="bilibili-evolved-about">
|
||||||
<div class="about-block">
|
<div class="gui-settings-header">
|
||||||
<h1>Bilibili Evolved</h1>
|
<i class="mdi mdi-information-outline mdi-24"></i>
|
||||||
<h2 class="bilibili-evolved-version"></h2>
|
<span class="gui-settings-title">关于</span>
|
||||||
<div class="bilibili-evolved-info">
|
|
||||||
<p>
|
|
||||||
作者:
|
|
||||||
<a target="_blank" href="https://github.com/the1812">Grant Howard</a>,
|
|
||||||
<a target="_blank" href="https://github.com/Coulomb-G">Coulomb-G</a>
|
|
||||||
</p>
|
|
||||||
<p>
|
|
||||||
网站: <a target="_blank" href="https://github.com/the1812/Bilibili-Evolved">GitHub</a>
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="about-block">
|
|
||||||
<h2>开源组件</h2>
|
|
||||||
<ul class="open-source-components">
|
|
||||||
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
<button id="about-close">关闭</button>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -1,48 +1,6 @@
|
|||||||
$("body").append((resources.data.aboutDom || resources.data.aboutHtml).text);
|
(async () =>
|
||||||
const version = GM_info.script.name.replace("Bilibili Evolved", "").replace(/^[\(\) ]+|[\(\) ]+$/g, '') + " · " + settings.currentVersion;
|
|
||||||
$(".bilibili-evolved-version").text(version);
|
|
||||||
const openSourceComponents = [
|
|
||||||
{
|
|
||||||
name: "jQuery",
|
|
||||||
homepage: "https://jquery.com/",
|
|
||||||
license: "MIT",
|
|
||||||
version: "3.2.1"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
name: "JSZip",
|
|
||||||
homepage: "https://stuk.github.io/jszip/",
|
|
||||||
license: "MIT",
|
|
||||||
version: "3.1.5"
|
|
||||||
}
|
|
||||||
];
|
|
||||||
openSourceComponents.forEach(component =>
|
|
||||||
{
|
{
|
||||||
$(".open-source-components").append(/*html*/`
|
const html = await import("aboutHtml");
|
||||||
<li>
|
document.body.insertAdjacentHTML("beforeend", html);
|
||||||
<a target="_blank" href="${component.homepage}">
|
|
||||||
<div class="component-name">${component.name}</div>
|
|
||||||
<div class="component-info">${component.version} · ${component.license}</div>
|
|
||||||
</a>
|
|
||||||
</li>
|
|
||||||
`);
|
|
||||||
});
|
|
||||||
|
|
||||||
function init()
|
})();
|
||||||
{
|
|
||||||
$("#about-close").on("click", () =>
|
|
||||||
{
|
|
||||||
$(".bilibili-evolved-about").toggleClass("opened");
|
|
||||||
});
|
|
||||||
$(".gui-settings").on("click", e =>
|
|
||||||
{
|
|
||||||
if (e.shiftKey === true)
|
|
||||||
{
|
|
||||||
$(".bilibili-evolved-about").toggleClass("opened");
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
export default {
|
|
||||||
widget: {
|
|
||||||
success: init
|
|
||||||
}
|
|
||||||
};
|
|
||||||
@ -454,7 +454,7 @@ li.category.folded i.icon-arrow
|
|||||||
position: fixed;
|
position: fixed;
|
||||||
top: 0;
|
top: 0;
|
||||||
left: 0;
|
left: 0;
|
||||||
z-index: 100000;
|
z-index: 99999;
|
||||||
pointer-events: none;
|
pointer-events: none;
|
||||||
transition: all .3s cubic-bezier(0, 0.86, 0.58, 1);
|
transition: all .3s cubic-bezier(0, 0.86, 0.58, 1);
|
||||||
overscroll-behavior: contain;
|
overscroll-behavior: contain;
|
||||||
|
|||||||
@ -5,7 +5,7 @@
|
|||||||
<span class="gui-settings-title">附加功能</span>
|
<span class="gui-settings-title">附加功能</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="widgets-container">
|
<div class="widgets-container">
|
||||||
<div class="empty-tip">空空如也哦...</div>
|
<div class="empty-tip">空空如也哦 = ̄ω ̄=</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="gui-settings-box icons-enabled">
|
<div class="gui-settings-box icons-enabled">
|
||||||
|
|||||||
@ -44,7 +44,7 @@ function setupEvents()
|
|||||||
{
|
{
|
||||||
document.querySelector(".gui-settings-mask").addEventListener("click", () =>
|
document.querySelector(".gui-settings-mask").addEventListener("click", () =>
|
||||||
{
|
{
|
||||||
document.querySelectorAll(".gui-settings-widgets-box,.gui-settings-box,.gui-settings-mask")
|
document.querySelectorAll(".gui-settings-widgets-box,.gui-settings-box,.gui-settings-mask,.bilibili-evolved-about")
|
||||||
.forEach(it => it.classList.remove("opened"));
|
.forEach(it => it.classList.remove("opened"));
|
||||||
});
|
});
|
||||||
textBoxes.forEach(element =>
|
textBoxes.forEach(element =>
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
if ($(".gui-settings-icon-panel").length === 0)
|
if (document.querySelector(".gui-settings-icon-panel") === null)
|
||||||
{
|
{
|
||||||
$("body").append(/*html*/`
|
document.body.insertAdjacentHTML("beforeend", /*html*/`
|
||||||
<div class='gui-settings-icon-panel icons-enabled'>
|
<div class='gui-settings-icon-panel icons-enabled'>
|
||||||
<div class='gui-settings-widgets' title='附加功能'>
|
<div class='gui-settings-widgets' title='附加功能'>
|
||||||
<i class="icon-widgets"></i>
|
<i class="icon-widgets"></i>
|
||||||
@ -9,15 +9,19 @@ if ($(".gui-settings-icon-panel").length === 0)
|
|||||||
<i class="icon-settings"></i>
|
<i class="icon-settings"></i>
|
||||||
</div>
|
</div>
|
||||||
</div>`);
|
</div>`);
|
||||||
$(".gui-settings").on("click", e =>
|
document.querySelector(".gui-settings").addEventListener("click", e =>
|
||||||
{
|
{
|
||||||
if (e.shiftKey === false)
|
if (e.shiftKey === false)
|
||||||
{
|
{
|
||||||
$(".gui-settings-box,.gui-settings-mask").addClass("opened");
|
document.querySelectorAll(".gui-settings-box,.gui-settings-mask").forEach(it => it.classList.add("opened"));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
document.querySelectorAll(".bilibili-evolved-about,.gui-settings-mask").forEach(it => it.classList.add("opened"));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
$(".gui-settings-widgets").on("click", () =>
|
document.querySelector(".gui-settings-widgets").addEventListener("click", () =>
|
||||||
{
|
{
|
||||||
$(".gui-settings-widgets-box,.gui-settings-mask").addClass("opened");
|
document.querySelectorAll(".gui-settings-widgets-box,.gui-settings-mask").forEach(it => it.classList.add("opened"));
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
Loading…
Reference in New Issue
Block a user