-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
302 additions
and
0 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
import './src/index' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
/** | ||
* @name indie-theme | ||
* @description A simple and clean theme for Pengu Loader | ||
* @author nomi-san | ||
* @link https://github.com/nomi-san/indie-theme | ||
*/ | ||
|
||
export * from 'https://unpkg.com/indie-theme@latest' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
{ | ||
"name": "indie-theme", | ||
"version": "0.1.0", | ||
"description": "A simple and clean theme for Pengu Loader", | ||
"main": "src/index.js", | ||
"type": "module", | ||
"keywords": [ | ||
"pengu-loader", | ||
"pengu-theme", | ||
"pengu-plugin", | ||
"league-client" | ||
], | ||
"author": "nomi-san", | ||
"license": "MIT", | ||
"files": [ | ||
"assets/", | ||
"src/" | ||
], | ||
"exports": { | ||
".": "./src/index.js", | ||
"./index.js": "./src/index.js" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
async function delay(t) { | ||
return new Promise(r => setTimeout(r, t)) | ||
} | ||
|
||
function toggleSocial() { | ||
/** @type {HTMLDivElement} */ | ||
let pane = document.querySelector('.lol-social-lower-pane-container') | ||
if (pane != null) { | ||
pane.classList.toggle('hidden') | ||
window.DataStore?.set('__social_hidden', pane.classList.contains('hidden')) | ||
} | ||
} | ||
|
||
/** @returns {Promise<HTMLElement>} */ | ||
function watchElement(selector, interval = 500) { | ||
return new Promise(async resolve => { | ||
while (true) { | ||
let el = document.querySelector(selector) | ||
if (el != null) { | ||
resolve(el) | ||
break | ||
} | ||
await delay(interval) | ||
} | ||
}) | ||
} | ||
|
||
export async function load() { | ||
watchElement('.bug-report-button') | ||
.then(el => { | ||
let clone = el.cloneNode(true) | ||
el.style.display = 'none' | ||
el.parentNode.appendChild(clone) | ||
clone.addEventListener('click', (e) => { | ||
e.stopPropagation() | ||
e.preventDefault() | ||
toggleSocial() | ||
}, true) | ||
}) | ||
|
||
watchElement('.lol-social-lower-pane-container') | ||
.then(el => { | ||
let hidden = window.DataStore?.get('__social_hidden', false) | ||
if (hidden === true) { | ||
el.classList.add('hidden') | ||
} | ||
}) | ||
|
||
// watchElement('.rcp-fe-viewport-persistent') | ||
// .then(el => { | ||
// console.log('.rcp-fe-viewport-persistent created') | ||
// let mo = new MutationObserver(mutations => { | ||
// mutations.forEach(mutation => { | ||
// mutation.addedNodes.forEach(node => { | ||
// if (node.nodeName === 'IFRAME') { | ||
// /** @type {HTMLIFrameElement} */ | ||
// // todo | ||
// } | ||
// }) | ||
// }) | ||
// }) | ||
// mo.observe(el, { | ||
// childList: true, | ||
// subtree: true | ||
// }) | ||
// }) | ||
|
||
let url = import.meta.url | ||
if (url.startsWith('https://plugins/')) { | ||
import('./theme.css') | ||
} else { | ||
let link = document.createElement('link') | ||
link.setAttribute('rel', 'stylesheet'); | ||
link.setAttribute('href', new URL('./theme.css', url).href); | ||
document.body.appendChild(link) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,193 @@ | ||
.rcp-fe-viewport-main { | ||
width: 100% !important; | ||
} | ||
|
||
lol-uikit-flyout-frame { | ||
z-index: 100; | ||
} | ||
|
||
.bg-current.uikit-background-switcher { | ||
width: 100% !important; | ||
} | ||
|
||
.rcp-fe-viewport-sidebar { | ||
position: fixed; | ||
right: 0px; | ||
z-index: 1; | ||
background: transparent !important; | ||
height: auto !important; | ||
} | ||
|
||
.lol-social-sidebar { | ||
background: transparent !important; | ||
} | ||
|
||
lol-social-avatar { | ||
transform: scale(0.85); | ||
} | ||
|
||
lol-social-roster { | ||
/* padding-bottom: 160px; */ | ||
} | ||
|
||
.v2-header-component { | ||
top: 0 !important; | ||
} | ||
|
||
.v2-header-component .lobby-header-content { | ||
margin-top: 18px !important; | ||
} | ||
|
||
.v2-parties-invite-info-panel { | ||
background: transparent !important; | ||
} | ||
|
||
.parties-invite-info-panel-body { | ||
border-bottom: none !important; | ||
} | ||
|
||
.lobby-header-buttons-container { | ||
position: absolute; | ||
top: calc(90vh - 4px); | ||
right: calc(60vw + 4px); | ||
} | ||
|
||
.alpha-version-panel { | ||
position: fixed; | ||
bottom: 1px; | ||
right: 1px; | ||
width: 223px !important; | ||
} | ||
|
||
.navbar-blur { | ||
display: none; | ||
} | ||
|
||
.navigation-root-component { | ||
border-bottom: none !important; | ||
} | ||
|
||
/* lol-parties-game-info-panel { | ||
display: none !important; | ||
} */ | ||
|
||
.lol-social-lower-pane-container { | ||
position: fixed; | ||
height: 330px; | ||
right: 1px; | ||
bottom: 36px; | ||
width: 223px; | ||
background-image: linear-gradient(rgb(7, 34, 55), rgb(1, 10, 19)); | ||
/* border-top: 2px solid transparent; | ||
border-image: linear-gradient(0deg, rgb(120, 91, 40), rgb(200, 156, 60) 55%, rgb(200, 163, 85) 71%, rgb(200, 170, 110)) 1 / 1 / 0 stretch; */ | ||
box-sizing: border-box; | ||
|
||
/* flex-flow: column-reverse; */ | ||
box-shadow: -14px -13px 39px 6px rgba(0, 0, 0, 0.5); | ||
} | ||
|
||
.lol-social-lower-pane-container.hidden { | ||
display: none; | ||
} | ||
|
||
.bug-report-button { | ||
background-image: url(../assets/social-button.png) !important; | ||
} | ||
|
||
.play-button-component.disabled { | ||
visibility: hidden; | ||
} | ||
|
||
.navigation-root-component { | ||
justify-content: flex-end !important; | ||
} | ||
|
||
lol-uikit-navigation-bar { | ||
width: unset !important; | ||
} | ||
|
||
.right-nav-vertical-rule { | ||
display: none; | ||
} | ||
|
||
.wallet-and-badges { | ||
margin-right: 0 !important; | ||
} | ||
|
||
.wallet-and-badges>* { | ||
margin-left: 8px !important; | ||
} | ||
|
||
.main-navigation-menu-item, | ||
.wallet-and-badges, | ||
.ticker-button, | ||
lol-social-panel>* { | ||
opacity: .2; | ||
} | ||
|
||
.main-navigation-menu-item:hover, | ||
.main-navigation-menu-item[active], | ||
.wallet-and-badges:hover, | ||
.ticker-button:hover, | ||
lol-social-panel>*:hover { | ||
opacity: .8; | ||
} | ||
|
||
.style-profile-skin-picker-button { | ||
z-index: 100; | ||
} | ||
|
||
.loot-content-wrapper, | ||
.collections-application { | ||
width: 100% !important; | ||
} | ||
|
||
.loot-backdrop { | ||
width: 100% !important; | ||
background-size: cover !important; | ||
} | ||
|
||
.rcp-fe-viewport-overlay { | ||
z-index: 2; | ||
} | ||
|
||
.rcp-fe-viewport-overlay>.screen-root:first-child { | ||
border-top: 1px solid #1e282d; | ||
} | ||
|
||
.invite-info-panel-container { | ||
bottom: 40px !important; | ||
/* z-index: 1; */ | ||
} | ||
|
||
.vng-age-rating { | ||
display: none; | ||
} | ||
|
||
.left-nav-menu>* { | ||
margin: 0 -4px !important; | ||
} | ||
|
||
.right-nav-menu .main-navigation-menu-item:last-of-type { | ||
margin-right: 0 !important; | ||
} | ||
|
||
.right-nav-menu .main-navigation-menu-item { | ||
width: 40px !important; | ||
} | ||
|
||
/* landing pages */ | ||
|
||
.rcp-fe-viewport-persistent, | ||
.rcp-fe-viewport-persistent>* { | ||
width: 100% !important; | ||
} | ||
|
||
|
||
|
||
/* postgame stats */ | ||
|
||
.postgame-header-container { | ||
padding-right: 250px; | ||
width: unset !important; | ||
} |