mirror of
https://github.com/GiriNeko/YesPlayMusic.git
synced 2025-12-17 05:38:04 +00:00
feat: monorepo
This commit is contained in:
parent
4d54060a4f
commit
42089d4996
200 changed files with 1530 additions and 1521 deletions
38
packages/web/global.d.ts
vendored
Normal file
38
packages/web/global.d.ts
vendored
Normal file
|
|
@ -0,0 +1,38 @@
|
|||
import { IpcChannelsParams, IpcChannelsReturns } from '@/shared/IpcChannels'
|
||||
import { ElectronLog } from 'electron-log'
|
||||
|
||||
export {}
|
||||
|
||||
declare global {
|
||||
interface Window {
|
||||
ipcRenderer?: {
|
||||
sendSync: <T extends keyof IpcChannelsParams>(
|
||||
channel: T,
|
||||
params?: IpcChannelsParams[T]
|
||||
) => IpcChannelsReturns[T]
|
||||
send: <T extends keyof IpcChannelsParams>(
|
||||
channel: T,
|
||||
params?: IpcChannelsParams[T]
|
||||
) => void
|
||||
on: <T extends keyof IpcChannelsParams>(
|
||||
channel: T,
|
||||
listener: (
|
||||
event: Electron.IpcRendererEvent,
|
||||
value: IpcChannelsReturns[T]
|
||||
) => void
|
||||
) => void
|
||||
}
|
||||
env?: {
|
||||
isElectron: boolean
|
||||
isEnableTitlebar: boolean
|
||||
isLinux: boolean
|
||||
isMac: boolean
|
||||
isWin: boolean
|
||||
}
|
||||
log?: ElectronLog
|
||||
}
|
||||
}
|
||||
|
||||
declare module 'valtio' {
|
||||
function useSnapshot<T extends object>(p: T): T
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue