mirror of
https://github.com/qier222/YesPlayMusic.git
synced 2025-01-19 23:22:55 +08:00
feat: 其他小更新
This commit is contained in:
parent
2e41001d02
commit
db5730dfdd
|
@ -5,7 +5,7 @@ import Player from '@/components/Player'
|
|||
import Sidebar from '@/components/Sidebar'
|
||||
import reactQueryClient from '@/utils/reactQueryClient'
|
||||
import Main from './components/Main'
|
||||
import TitleBar from './components/Titlebar'
|
||||
import TitleBar from './components/TitleBar'
|
||||
|
||||
const App = () => {
|
||||
return (
|
||||
|
|
|
@ -1 +0,0 @@
|
|||
<svg width="24" height="24" fill="none" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M3 5.75A2.75 2.75 0 0 1 5.75 3h12.5A2.75 2.75 0 0 1 21 5.75v12.5A2.75 2.75 0 0 1 18.25 21H5.75A2.75 2.75 0 0 1 3 18.25V5.75ZM5.75 4.5c-.69 0-1.25.56-1.25 1.25v12.5c0 .69.56 1.25 1.25 1.25h12.5c.69 0 1.25-.56 1.25-1.25V5.75c0-.69-.56-1.25-1.25-1.25H5.75Z" fill="currentColor"/></svg>
|
Before Width: | Height: | Size: 387 B |
1
src/renderer/assets/icons/windows-maximize.svg
Normal file
1
src/renderer/assets/icons/windows-maximize.svg
Normal file
|
@ -0,0 +1 @@
|
|||
<svg width="24" height="24" fill="none" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M5.75 3h12.5A2.75 2.75 0 0 1 21 5.75v12.5A2.75 2.75 0 0 1 18.25 21H5.75A2.75 2.75 0 0 1 3 18.25V5.75A2.75 2.75 0 0 1 5.75 3Zm0 1.5c-.69 0-1.25.56-1.25 1.25v12.5c0 .69.56 1.25 1.25 1.25h12.5c.69 0 1.25-.56 1.25-1.25V5.75c0-.69-.56-1.25-1.25-1.25H5.75Z" fill="currentColor"/></svg>
|
After Width: | Height: | Size: 384 B |
Before Width: | Height: | Size: 197 B After Width: | Height: | Size: 197 B |
Before Width: | Height: | Size: 570 B After Width: | Height: | Size: 570 B |
|
@ -55,6 +55,7 @@ const MediaControls = () => {
|
|||
}
|
||||
|
||||
const FMCard = () => {
|
||||
const navigate = useNavigate()
|
||||
const [background, setBackground] = useState('')
|
||||
|
||||
const playerSnapshot = useSnapshot(player)
|
||||
|
@ -83,7 +84,11 @@ const FMCard = () => {
|
|||
style={{ background }}
|
||||
>
|
||||
{coverUrl ? (
|
||||
<img className='rounded-lg shadow-2xl' src={coverUrl} />
|
||||
<img
|
||||
onClick={() => track?.al?.id && navigate(`/album/${track.al.id}`)}
|
||||
className='rounded-lg shadow-2xl'
|
||||
src={coverUrl}
|
||||
/>
|
||||
) : (
|
||||
<div className='aspect-square h-full rounded-lg bg-gray-200 dark:bg-white/5'></div>
|
||||
)}
|
||||
|
|
|
@ -7,16 +7,26 @@ import Playlist from '@/pages/Playlist'
|
|||
import Artist from '@/pages/Artist'
|
||||
import Search from '@/pages/Search'
|
||||
import Library from '@/pages/Library'
|
||||
import Podcast from '@/pages/Podcast'
|
||||
import Settings from '@/pages/Settings'
|
||||
|
||||
const routes: RouteObject[] = [
|
||||
{
|
||||
path: '/',
|
||||
element: <Home />,
|
||||
},
|
||||
{
|
||||
path: '/podcast',
|
||||
element: <Podcast />,
|
||||
},
|
||||
{
|
||||
path: '/library',
|
||||
element: <Library />,
|
||||
},
|
||||
{
|
||||
path: '/settings',
|
||||
element: <Settings />,
|
||||
},
|
||||
{
|
||||
path: '/login',
|
||||
element: <Login />,
|
||||
|
|
|
@ -6,10 +6,10 @@ const TitleBar = () => {
|
|||
<div className='ml-2 text-sm text-gray-500'>YesPlayMusic</div>
|
||||
<div className='flex h-full'>
|
||||
<button className='flex w-[2.875rem] items-center justify-center hover:bg-[#e9e9e9]'>
|
||||
<SvgIcon className='h-3 w-3' name='windows-min' />
|
||||
<SvgIcon className='h-3 w-3' name='windows-minimize' />
|
||||
</button>
|
||||
<button className='flex w-[2.875rem] items-center justify-center hover:bg-[#e9e9e9]'>
|
||||
<SvgIcon className='h-3 w-3' name='windows-max' />
|
||||
<SvgIcon className='h-3 w-3' name='windows-maximize' />
|
||||
</button>
|
||||
<button className='flex w-[2.875rem] items-center justify-center hover:bg-[#c42b1c] hover:text-white'>
|
||||
<SvgIcon className='h-3 w-3' name='windows-close' />
|
||||
|
|
2
src/renderer/interface.d.ts
vendored
2
src/renderer/interface.d.ts
vendored
|
@ -11,7 +11,7 @@ declare interface Playlist {
|
|||
adType?: number
|
||||
alg?: string
|
||||
anonimous?: boolean
|
||||
artists?: []
|
||||
artists?: Artist[]
|
||||
backgroundCoverId?: number
|
||||
backgroundCoverUrl?: string | null
|
||||
creator: User
|
||||
|
|
5
src/renderer/pages/Podcast.tsx
Normal file
5
src/renderer/pages/Podcast.tsx
Normal file
|
@ -0,0 +1,5 @@
|
|||
const Podcast = () => {
|
||||
return <div>施工中...</div>
|
||||
}
|
||||
|
||||
export default Podcast
|
5
src/renderer/pages/Settings.tsx
Normal file
5
src/renderer/pages/Settings.tsx
Normal file
|
@ -0,0 +1,5 @@
|
|||
const Settings = () => {
|
||||
return <div></div>
|
||||
}
|
||||
|
||||
export default Settings
|
|
@ -112,6 +112,7 @@ button {
|
|||
cursor: default;
|
||||
}
|
||||
|
||||
img {
|
||||
img,
|
||||
a {
|
||||
-webkit-user-drag: none;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user