mirror of
https://github.com/th-ch/youtube-music.git
synced 2026-01-11 10:31:47 +00:00
fix(in-app-menu): overlay-scrollbar
This commit is contained in:
@ -1,21 +0,0 @@
|
||||
// eslint-disable-next-line import/no-unresolved
|
||||
import { Titlebar, Color } from 'custom-electron-titlebar';
|
||||
|
||||
const customTitlebarFunction = () => {
|
||||
new Titlebar({
|
||||
backgroundColor: Color.fromHex('#050505'),
|
||||
minimizable: false,
|
||||
maximizable: false,
|
||||
menu: undefined,
|
||||
});
|
||||
const mainStyle = document.querySelector<HTMLElement>('#container')?.style;
|
||||
if (mainStyle) {
|
||||
mainStyle.width = '100%';
|
||||
mainStyle.position = 'fixed';
|
||||
mainStyle.border = 'unset';
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
module.exports = customTitlebarFunction;
|
||||
export default customTitlebarFunction;
|
||||
@ -1,18 +1,8 @@
|
||||
import path from 'node:path';
|
||||
|
||||
import is from 'electron-is';
|
||||
|
||||
import { isEnabled } from '../config/plugins';
|
||||
|
||||
const iconPath = path.join(__dirname, '..', 'assets', 'youtube-music-tray.png');
|
||||
const customTitlebarPath = path.join(__dirname, 'prompt-custom-titlebar.js');
|
||||
|
||||
const promptOptions = !is.macOS() && isEnabled('in-app-menu') ? {
|
||||
customStylesheet: 'dark',
|
||||
// The following are used for custom titlebar
|
||||
frame: false,
|
||||
customScript: customTitlebarPath,
|
||||
} : {
|
||||
const promptOptions = {
|
||||
customStylesheet: 'dark',
|
||||
icon: iconPath,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user