mirror of
https://github.com/th-ch/youtube-music.git
synced 2026-01-14 03:41:46 +00:00
style check
This commit is contained in:
8
index.js
8
index.js
@ -93,10 +93,10 @@ function createMainWindow() {
|
|||||||
affinity: "main-window", // main window, and addition windows should work in one process
|
affinity: "main-window", // main window, and addition windows should work in one process
|
||||||
...(isTesting()
|
...(isTesting()
|
||||||
? {
|
? {
|
||||||
// Only necessary when testing with Spectron
|
// Only necessary when testing with Spectron
|
||||||
contextIsolation: false,
|
contextIsolation: false,
|
||||||
nodeIntegration: true,
|
nodeIntegration: true,
|
||||||
}
|
}
|
||||||
: undefined),
|
: undefined),
|
||||||
},
|
},
|
||||||
frame: !is.macOS() && !config.plugins.isEnabled("styled-bars"),
|
frame: !is.macOS() && !config.plugins.isEnabled("styled-bars"),
|
||||||
|
|||||||
@ -1,11 +1,10 @@
|
|||||||
const {injectCSS} = require('../utils');
|
const {injectCSS} = require('../utils');
|
||||||
const {Menu} = require('electron');
|
const {Menu , app} = require('electron');
|
||||||
const path = require('path');
|
const path = require('path');
|
||||||
const electronLocalshortcut = require("electron-localshortcut");
|
const electronLocalshortcut = require("electron-localshortcut");
|
||||||
const is = require('electron-is');
|
const is = require('electron-is');
|
||||||
const {getAllPlugins} = require('../../plugins/utils');
|
const {getAllPlugins} = require('../../plugins/utils');
|
||||||
const config = require('../../config');
|
const config = require('../../config');
|
||||||
const { app } = require('electron')
|
|
||||||
|
|
||||||
module.exports = win => {
|
module.exports = win => {
|
||||||
// css for custom scrollbar + disable drag area(was causing bugs)
|
// css for custom scrollbar + disable drag area(was causing bugs)
|
||||||
@ -86,6 +85,7 @@ const mainMenuTemplate = win => [
|
|||||||
checked: config.get('options.disableHardwareAcceleration'),
|
checked: config.get('options.disableHardwareAcceleration'),
|
||||||
click: item => {
|
click: item => {
|
||||||
config.set('options.disableHardwareAcceleration', item.checked);
|
config.set('options.disableHardwareAcceleration', item.checked);
|
||||||
|
checkCheckbox(item);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
@ -2,7 +2,6 @@ const customTitlebar = require('custom-electron-titlebar');
|
|||||||
const {remote, ipcRenderer} = require('electron');
|
const {remote, ipcRenderer} = require('electron');
|
||||||
|
|
||||||
module.exports = () => {
|
module.exports = () => {
|
||||||
//const windowProxy = window.open('https://music.youtube.com', null);
|
|
||||||
const myBar = new customTitlebar.Titlebar({
|
const myBar = new customTitlebar.Titlebar({
|
||||||
backgroundColor: customTitlebar.Color.fromHex('#030303'),
|
backgroundColor: customTitlebar.Color.fromHex('#030303'),
|
||||||
itemBackgroundColor: customTitlebar.Color.fromHex('#121212')
|
itemBackgroundColor: customTitlebar.Color.fromHex('#121212')
|
||||||
@ -11,8 +10,6 @@ module.exports = () => {
|
|||||||
document.title = 'Youtube Music';
|
document.title = 'Youtube Music';
|
||||||
|
|
||||||
ipcRenderer.on('updateMenu', function (event, menu) {
|
ipcRenderer.on('updateMenu', function (event, menu) {
|
||||||
//let menu = Menu.buildFromTemplate(template);
|
|
||||||
//Menu.setApplicationMenu(menu);
|
|
||||||
if (menu) {
|
if (menu) {
|
||||||
myBar.updateMenu(remote.Menu.getApplicationMenu());
|
myBar.updateMenu(remote.Menu.getApplicationMenu());
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@ -3,6 +3,7 @@ ytmusic-nav-bar {
|
|||||||
-webkit-app-region : unset;
|
-webkit-app-region : unset;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Move navBar downwards and make it opaque */
|
||||||
ytmusic-app-layout {
|
ytmusic-app-layout {
|
||||||
--ytmusic-nav-bar-height: 120px;
|
--ytmusic-nav-bar-height: 120px;
|
||||||
}
|
}
|
||||||
@ -20,6 +21,7 @@ yt-page-navigation-progress, #progress.yt-page-navigation-progress {
|
|||||||
ytmusic-item-section-renderer[has-item-section-tabbed-header-renderer_] #header.ytmusic-item-section-renderer {
|
ytmusic-item-section-renderer[has-item-section-tabbed-header-renderer_] #header.ytmusic-item-section-renderer {
|
||||||
top: 90px !important;
|
top: 90px !important;
|
||||||
}
|
}
|
||||||
|
/* Custom scrollbar */
|
||||||
::-webkit-scrollbar {
|
::-webkit-scrollbar {
|
||||||
width: 12px;
|
width: 12px;
|
||||||
background-color: #030303;
|
background-color: #030303;
|
||||||
|
|||||||
Reference in New Issue
Block a user