Skip to content

Commit

Permalink
Merge pull request #8 from joshhoughton/0.1.0
Browse files Browse the repository at this point in the history
0.1.0
  • Loading branch information
joshhoughton authored Oct 7, 2024
2 parents 4935bd4 + 988db86 commit 4d6c008
Show file tree
Hide file tree
Showing 13 changed files with 208 additions and 127 deletions.
28 changes: 28 additions & 0 deletions .github/upload-chrome-extension.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Upload Chrome Extension

on:
push:
branches:
- main

jobs:
zip_and_upload:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Create ZIP file
run: mkdir -p dist && zip -r dist/extension.zip manifest.json src/ _locales/ channels/ icons/ js/jquery/jquery.min.js

- name: Upload & release
uses: mnao305/[email protected]
with:
file-path: dist/extension.zip
extension-id: ${{ secrets.EXTENSION_ID }}
client-id: ${{ secrets.CLIENT_ID }}
client-secret: ${{ secrets.CLIENT_SECRET }}
refresh-token: ${{ secrets.REFRESH_TOKEN }}
publish: false

2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
node_modules
dist/
1 change: 1 addition & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
*.min.js
5 changes: 5 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"semi": true,
"singleQuote": true,
"trailingComma": "es5"
}
19 changes: 19 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@

# Change Log
All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](http://keepachangelog.com/)
and this project adheres to [Semantic Versioning](http://semver.org/).


## [0.1.0] - 2024-10-07

### Added
- This changelog.
- A mapping of preset YouTube channels to their corresponding Twitch usernames to allow easy additions in the future without having to bump this extension.

### Changed

- Entered streamers are now saved to local storage to prevent having to re-enter each time.
- Extension icon can now be double clicked to change chats.
- Chat is now resized to match the height of YouTube video.
2 changes: 0 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
<!-- PROJECT LOGO -->
<br />
<p align="center">

Expand All @@ -12,4 +11,3 @@
<br />

</p>

4 changes: 1 addition & 3 deletions _locales/en/messages.json
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
{

}
{}
23 changes: 13 additions & 10 deletions channels/stream_chat.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
{
"tockerslol": "tockerslol",
"oquequehouve": "brtt",
"rangerlol": "rangerlol1",
"cblol": "cblol",
"arthurlanches": "arthur_lanches",
"baianotv1": "baiano",
"cazetv":"cazetv_",
"inteligencialtda":"inteligencialimitada",
"linustechtips":"linustech"
}
"tockerslol": "tockerslol",
"oquequehouve": "brtt",
"rangerlol": "rangerlol1",
"cblol": "cblol",
"arthurlanches": "arthur_lanches",
"baianotv1": "baiano",
"cazetv": "cazetv_",
"inteligencialtda": "inteligencialimitada",
"linustechtips": "linustech",
"eslcs": "esl_csgo",
"blastpremier": "blastpremier",
"pgl": "pgl"
}
12 changes: 4 additions & 8 deletions manifest.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "Twitch Chat for YouTube™",
"version": "0.0.5",
"version": "0.1.0",
"manifest_version": 3,
"description": "Click the extension to load Twitch chat onto YouTube live page, replacing YouTube chat.",
"icons": {
Expand All @@ -10,14 +10,10 @@
},
"default_locale": "en",
"action": {
"default_title": "Get Twitch Chat on YouTube"
"default_title": "Get Twitch Chat on YouTube (double click to change chat)"
},
"permissions": [
"storage",
"activeTab",
"scripting"
],
"permissions": ["storage", "activeTab", "scripting"],
"background": {
"service_worker": "src/background/background.js"
}
}
}
28 changes: 28 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 5 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"devDependencies": {
"prettier": "^3.3.3"
}
}
11 changes: 5 additions & 6 deletions src/background/background.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@

chrome.action.onClicked.addListener((tab) => {
chrome.scripting.executeScript({
target: {tabId: tab.id},
files: ["js/jquery/jquery.min.js", "src/main.js"]
});
});
chrome.scripting.executeScript({
target: { tabId: tab.id },
files: ['js/jquery/jquery.min.js', 'src/main.js'],
});
});
Loading

0 comments on commit 4d6c008

Please sign in to comment.