Merge branch 'main' into bugfixes

This commit is contained in:
Hakadao
2024-04-12 18:49:06 +08:00
5 changed files with 25 additions and 183 deletions

View File

@@ -10,15 +10,8 @@
<p align="center">只需对您的 Bilibili 主页进行一些小更改即可。</p>
![Image 3840x2400](https://github.com/hakadao/BewlyBewly/assets/33394391/ad726480-e6ef-4823-82e0-e3c3735a3909)
![Snipaste_2023-11-21_00-26-26](https://github.com/hakadao/BewlyBewly/assets/33394391/b1c1c25a-482a-438f-8e61-4d67cb32aea1)
![Snipaste_2023-11-21_00-30-03](https://github.com/hakadao/BewlyBewly/assets/33394391/1a9f0c56-5053-40d9-bec8-72665f85962d)
![Snipaste_2023-11-21_00-30-30](https://github.com/hakadao/BewlyBewly/assets/33394391/4cb44949-8352-4607-9dd4-74a8d1e00a74)
![Snipaste_2023-11-21_00-31-33](https://github.com/hakadao/BewlyBewly/assets/33394391/9ebebfd9-d8a8-411d-8c10-cf7cdb60abd4)
![Snipaste_2023-11-21_00-31-54](https://github.com/hakadao/BewlyBewly/assets/33394391/86ad5303-56b2-4d68-985d-300f2825ee49)
![Snipaste_2023-11-21_00-32-06](https://github.com/hakadao/BewlyBewly/assets/33394391/64b6eac1-d9ee-4157-a850-b940700a565b)
![Snipaste_2023-11-21_00-32-22](https://github.com/hakadao/BewlyBewly/assets/33394391/2533a1f9-3cb1-402e-96bb-3755404ddf02)
![Snipaste_2023-11-21_00-32-51](https://github.com/hakadao/BewlyBewly/assets/33394391/a439ea59-cc80-48aa-9c6a-ec5d4da98441)
![min1](https://github.com/hakadao/BewlyBewly/assets/33394391/951f9e2a-d0e1-452c-83a9-dc6d85c4d441)
![min2](https://github.com/hakadao/BewlyBewly/assets/33394391/3e75dd20-f60b-4645-b434-23a24c72959c)
## 👋 介绍
@@ -34,7 +27,7 @@ BewlyBewly 是一个用于 BiliBili 的浏览器扩展,旨在通过重新设
- Chrome: <https://chromewebstore.google.com/detail/bewlybewly/bbbiejemhfihiooipfcjmjmbfdmobobp>
- Edge: <https://microsoftedge.microsoft.com/addons/detail/bewlybewly/kceadhehfjdiakpiphpjgolbgehjdmja>
- Firefox: **我需要一些帮助!!!!!!!!!!!!!!!!!! ( ;∀;)**
- Firefox: <https://addons.mozilla.org/lt/firefox/addon/bewlybewly/>
### 本地安装
@@ -69,7 +62,9 @@ BewlyBewly 是一个用于 BiliBili 的浏览器扩展,旨在通过重新设
</details>
## 🔧 开发 & 构建
## 🔧 开发和构建项目
请使用 dev 分支进行开发
### Chrome or Edge browser
@@ -83,7 +78,7 @@ pnpm dev
```
然后**在浏览器中使用 `加载已解压的拓展程序` 加载 `extension` 文件夹**。
每次修改后,您需要单击 [重新加载](https://chromewebstore.google.com/detail/extensions-reloader/fimgfedafeadlieiabdeeaodndnlbhid) 按钮并刷新页面以确保应用更改。
每次修改后,您需要单击 [Reload Extensions](https://chromewebstore.google.com/detail/extensions-reloader/fimgfedafeadlieiabdeeaodndnlbhid) 按钮并刷新页面以确保应用更改。
#### 构建 (Chrome or Edge)
@@ -99,8 +94,6 @@ pnpm build
### Firefox browser
在此之前,请使用 `dev-firefox` 分支来执行以下操作。它可能包含一些错误或不清晰的代码,欢迎您帮助解决这些问题!:D
<details>
<summary>Firefox</summary>

View File

@@ -10,15 +10,8 @@
<p align="center">只需對您的 Bilibili 主頁進行一些小改動就好。</p>
![Image 3840x2400](https://github.com/hakadao/BewlyBewly/assets/33394391/ad726480-e6ef-4823-82e0-e3c3735a3909)
![Snipaste_2023-11-21_00-26-26](https://github.com/hakadao/BewlyBewly/assets/33394391/b1c1c25a-482a-438f-8e61-4d67cb32aea1)
![Snipaste_2023-11-21_00-30-03](https://github.com/hakadao/BewlyBewly/assets/33394391/1a9f0c56-5053-40d9-bec8-72665f85962d)
![Snipaste_2023-11-21_00-30-30](https://github.com/hakadao/BewlyBewly/assets/33394391/4cb44949-8352-4607-9dd4-74a8d1e00a74)
![Snipaste_2023-11-21_00-31-33](https://github.com/hakadao/BewlyBewly/assets/33394391/9ebebfd9-d8a8-411d-8c10-cf7cdb60abd4)
![Snipaste_2023-11-21_00-31-54](https://github.com/hakadao/BewlyBewly/assets/33394391/86ad5303-56b2-4d68-985d-300f2825ee49)
![Snipaste_2023-11-21_00-32-06](https://github.com/hakadao/BewlyBewly/assets/33394391/64b6eac1-d9ee-4157-a850-b940700a565b)
![Snipaste_2023-11-21_00-32-22](https://github.com/hakadao/BewlyBewly/assets/33394391/2533a1f9-3cb1-402e-96bb-3755404ddf02)
![Snipaste_2023-11-21_00-32-51](https://github.com/hakadao/BewlyBewly/assets/33394391/a439ea59-cc80-48aa-9c6a-ec5d4da98441)
![min1](https://github.com/hakadao/BewlyBewly/assets/33394391/951f9e2a-d0e1-452c-83a9-dc6d85c4d441)
![min2](https://github.com/hakadao/BewlyBewly/assets/33394391/3e75dd20-f60b-4645-b434-23a24c72959c)
## 👋 介紹
@@ -34,7 +27,7 @@ BewlyBewly 是一個針對 BiliBili 的瀏覽器擴充功能,旨在透過重
- Chrome: <https://chromewebstore.google.com/detail/bewlybewly/bbbiejemhfihiooipfcjmjmbfdmobobp>
- Edge: <https://microsoftedge.microsoft.com/addons/detail/bewlybewly/kceadhehfjdiakpiphpjgolbgehjdmja>
- Firefox: **我需要幫助!!!!!!!!!!!!!!!!!! ( ;∀;)**
- Firefox: <https://addons.mozilla.org/lt/firefox/addon/bewlybewly/>
### 離線安裝
@@ -69,7 +62,9 @@ BewlyBewly 是一個針對 BiliBili 的瀏覽器擴充功能,旨在透過重
</details>
## 🔧 開發與建置
## 🔧 開發與建置專案
請使用 dev 分支進行開發
### Chrome or Edge browser
@@ -99,8 +94,6 @@ pnpm build
### Firefox browser
在那之前,請使用 `dev-firefox` 分支來進行以下操作。它可能包含一些錯誤或不清楚的代碼,歡迎您幫忙解決這些問題!:D
<details>
<summary>Firefox browser</summary>

View File

@@ -10,15 +10,8 @@
<p align="center">係咁以執吓你嘅 Bilibili 主頁。</p>
![Image 3840x2400](https://github.com/hakadao/BewlyBewly/assets/33394391/ad726480-e6ef-4823-82e0-e3c3735a3909)
![Snipaste_2023-11-21_00-26-26](https://github.com/hakadao/BewlyBewly/assets/33394391/b1c1c25a-482a-438f-8e61-4d67cb32aea1)
![Snipaste_2023-11-21_00-30-03](https://github.com/hakadao/BewlyBewly/assets/33394391/1a9f0c56-5053-40d9-bec8-72665f85962d)
![Snipaste_2023-11-21_00-30-30](https://github.com/hakadao/BewlyBewly/assets/33394391/4cb44949-8352-4607-9dd4-74a8d1e00a74)
![Snipaste_2023-11-21_00-31-33](https://github.com/hakadao/BewlyBewly/assets/33394391/9ebebfd9-d8a8-411d-8c10-cf7cdb60abd4)
![Snipaste_2023-11-21_00-31-54](https://github.com/hakadao/BewlyBewly/assets/33394391/86ad5303-56b2-4d68-985d-300f2825ee49)
![Snipaste_2023-11-21_00-32-06](https://github.com/hakadao/BewlyBewly/assets/33394391/64b6eac1-d9ee-4157-a850-b940700a565b)
![Snipaste_2023-11-21_00-32-22](https://github.com/hakadao/BewlyBewly/assets/33394391/2533a1f9-3cb1-402e-96bb-3755404ddf02)
![Snipaste_2023-11-21_00-32-51](https://github.com/hakadao/BewlyBewly/assets/33394391/a439ea59-cc80-48aa-9c6a-ec5d4da98441)
![min1](https://github.com/hakadao/BewlyBewly/assets/33394391/951f9e2a-d0e1-452c-83a9-dc6d85c4d441)
![min2](https://github.com/hakadao/BewlyBewly/assets/33394391/3e75dd20-f60b-4645-b434-23a24c72959c)
## 👋 介紹
@@ -34,7 +27,7 @@ BewlyBewly 係一個用於 BiliBili 嘅瀏覽器延伸功能,目的係透過
- Chrome: <https://chromewebstore.google.com/detail/bewlybewly/bbbiejemhfihiooipfcjmjmbfdmobobp>
- Edge: <https://microsoftedge.microsoft.com/addons/detail/bewlybewly/kceadhehfjdiakpiphpjgolbgehjdmja>
- Firefox: **我要人幫手!!!!!!!!!!!!!!!!!! ( ;∀;)**
- Firefox: <https://addons.mozilla.org/lt/firefox/addon/bewlybewly/>
### 離線單嘢
@@ -69,7 +62,9 @@ BewlyBewly 係一個用於 BiliBili 嘅瀏覽器延伸功能,目的係透過
</details>
## 🔧 開發同建置
## 🔧 開發同建置專案
請使用 dev 分支進行開發
### Chrome or Edge browser
@@ -99,8 +94,6 @@ pnpm build
### Firefox browser
整之前呢,請用 dev-firefox 分支去做下低嘅操作。佢可能會有啲 bugs 抑或亂晒籠嘅程式碼,歡迎閣下幫手解決呢啲問題!:D
<details>
<summary>Firefox</summary>

View File

@@ -1,6 +1,6 @@
# BewlyBewly
English | [简体中文](README-cmn_CN.md) | [正體中文](README-cmn_TW.md) | [廣東話](README-jyut.md)
English | [官话 - 简体中文](README-cmn_CN.md) | [官話 - 正體中文](README-cmn_TW.md) | [廣東話](README-jyut.md)
<p align="center" style="margin-bottom: 0px !important;">
<img width="150" src="https://user-images.githubusercontent.com/33394391/160250512-410b71fc-7f25-4caf-b850-429227ff082a.png"><br/>
@@ -10,15 +10,8 @@ English | [简体中文](README-cmn_CN.md) | [正體中文](README-cmn_TW.md) |
<p align="center">Just make a few small changes to your Bilibili homepage.</p>
![Image 3840x2400](https://github.com/hakadao/BewlyBewly/assets/33394391/ad726480-e6ef-4823-82e0-e3c3735a3909)
![Snipaste_2023-11-21_00-26-26](https://github.com/hakadao/BewlyBewly/assets/33394391/b1c1c25a-482a-438f-8e61-4d67cb32aea1)
![Snipaste_2023-11-21_00-30-03](https://github.com/hakadao/BewlyBewly/assets/33394391/1a9f0c56-5053-40d9-bec8-72665f85962d)
![Snipaste_2023-11-21_00-30-30](https://github.com/hakadao/BewlyBewly/assets/33394391/4cb44949-8352-4607-9dd4-74a8d1e00a74)
![Snipaste_2023-11-21_00-31-33](https://github.com/hakadao/BewlyBewly/assets/33394391/9ebebfd9-d8a8-411d-8c10-cf7cdb60abd4)
![Snipaste_2023-11-21_00-31-54](https://github.com/hakadao/BewlyBewly/assets/33394391/86ad5303-56b2-4d68-985d-300f2825ee49)
![Snipaste_2023-11-21_00-32-06](https://github.com/hakadao/BewlyBewly/assets/33394391/64b6eac1-d9ee-4157-a850-b940700a565b)
![Snipaste_2023-11-21_00-32-22](https://github.com/hakadao/BewlyBewly/assets/33394391/2533a1f9-3cb1-402e-96bb-3755404ddf02)
![Snipaste_2023-11-21_00-32-51](https://github.com/hakadao/BewlyBewly/assets/33394391/a439ea59-cc80-48aa-9c6a-ec5d4da98441)
![min1](https://github.com/hakadao/BewlyBewly/assets/33394391/951f9e2a-d0e1-452c-83a9-dc6d85c4d441)
![min2](https://github.com/hakadao/BewlyBewly/assets/33394391/3e75dd20-f60b-4645-b434-23a24c72959c)
## 👋 Introduction
@@ -34,7 +27,7 @@ Even in the Edge browser, we strongly recommend you install it in the Chrome web
- Chrome: <https://chromewebstore.google.com/detail/bewlybewly/bbbiejemhfihiooipfcjmjmbfdmobobp>
- Edge: <https://microsoftedge.microsoft.com/addons/detail/bewlybewly/kceadhehfjdiakpiphpjgolbgehjdmja>
- Firefox: **I NEED SOME HELP!!!!!!!!!!!!!!!!!! ( ;∀;)**
- Firefox: <https://addons.mozilla.org/lt/firefox/addon/bewlybewly/>
### Local Installation
@@ -71,6 +64,8 @@ Opening the `edge://extensions` page in the Edge or `chrome://extensions` page i
## 🔧 Development & Build
Please use the dev branch for development
### Chrome or Edge browser
<details>
@@ -99,8 +94,6 @@ And then pack files under the `extension`
### Firefox browser
Before that, please use the `dev-firefox` branch to perform the operations below. It may contain some bugs or unclear code, and your help in addressing these issues is welcome! :D
<details>
<summary>Firefox browser</summary>

View File

@@ -8,135 +8,5 @@ browser.runtime.onInstalled.addListener((): void => {
console.log('Extension installed')
})
// const previousTabId = 0
// communication example: send previous tab title from background page
// see shim.d.ts for type declaration
// browser.tabs.onActivated.addListener(async ({ tabId }) => {
// if (!previousTabId) {
// previousTabId = tabId
// return
// }
// let tab: Tabs.Tab
// try {
// tab = await browser.tabs.get(previousTabId)
// previousTabId = tabId
// }
// catch {
// return
// }
// // eslint-disable-next-line no-console
// console.log('previous tab', tab)
// sendMessage('tab-prev', { title: tab.title }, { context: 'content-script', tabId })
// })
// onMessage('get-current-tab', async () => {
// try {
// const tab = await browser.tabs.get(previousTabId)
// return {
// title: tab?.title,
// }
// }
// catch {
// return {
// title: undefined,
// }
// }
// })
// // preinsert css
// browser.tabs.onUpdated.addListener((tabId: number, changInfo: Tabs.OnUpdatedChangeInfoType, tab: Tabs.Tab) => {
// if (
// // homepage
// /https?:\/\/bilibili.com\/?$/.test(`${tab.url}`)
// || /https?:\/\/bilibili.com\/index.html\/?$/.test(`${tab.url}`)
// || /https?:\/\/www.bilibili.com\/index.html\/?$/.test(`${tab.url}`)
// || /https?:\/\/www.bilibili.com\/?$/.test(`${tab.url}`)
// || /https?:\/\/bilibili.com\/\?spm_id_from=.*/.test(`${tab.url}`)
// || /https?:\/\/www.bilibili.com\/\?spm_id_from=(.)*/.test(`${tab.url}`)
// // video page
// || /https?:\/\/(www.)?bilibili.com\/video\/.*/.test(`${tab.url}`)
// // watch later playlist
// || /https?:\/\/(www.)?bilibili.com\/list\/watchlater.*/.test(`${tab.url}`)
// // favorite playlist
// || /https?:\/\/(www.)?bilibili.com\/list\/ml.*/.test(`${tab.url}`)
// // search page
// || /https?:\/\/search.bilibili.com\.*/.test(`${tab.url}`)
// // moments page
// || /https?:\/\/t.bilibili.com\.*/.test(`${tab.url}`)
// ) {
// if (changInfo.status === 'loading') {
// // browser.scripting.insertCSS({
// // css: `
// // body {
// // opacity: 0;
// // transition: opacity 0.5s;
// // overflow-y: hidden;
// // pointer-events: none;
// // }
// // `,
// // target: {
// // tabId,
// // },
// // })
// browser.scripting.insertCSS({
// css: resetCss,
// target: {
// tabId,
// },
// })
// // If it not a macOS, we will inject CSS to design the scrollbar
// if (!navigator.userAgent.includes('Mac OS X')) {
// browser.scripting.insertCSS({
// css: `
// ::-webkit-scrollbar {
// width: 8px;
// height: 8px;
// }
// ::-webkit-scrollbar-track {
// background: transparent;
// }
// html > ::-webkit-scrollbar-track {
// background: var(--bew-bg);
// }
// ::-webkit-scrollbar-thumb {
// background-color: rgba(120, 120, 122, 0.6);
// border-radius: 20px;
// }
// ::-webkit-scrollbar-corner {
// background: transparent;
// }
// `,
// target: { tabId },
// })
// }
// }
// else if (changInfo.status === 'complete') {
// // const css = `
// // body {
// // opacity: 1;
// // overflow-y: auto;
// // pointer-events: auto;
// // }
// // `
// // browser.scripting.insertCSS({
// // css,
// // target: { tabId },
// // })
// }
// }
// })
// Setup all message listeners
setupAllMsgLstnrs()