mirror of
https://github.com/ikun0014/lx-music-mobile.git
synced 2025-05-23 22:37:41 +08:00
修复无法打开外部歌单的问题(#385)
This commit is contained in:
parent
1c8c5a53e8
commit
442c7c6a23
@ -1,4 +1,4 @@
|
|||||||
import songlistState, { type TagInfo, type ListDetailInfo, type ListInfo, type ListInfoItem } from '@/store/songlist/state'
|
import songlistState, { type TagInfo, type ListDetailInfo, type ListInfo } from '@/store/songlist/state'
|
||||||
import songlistActions from '@/store/songlist/action'
|
import songlistActions from '@/store/songlist/action'
|
||||||
import { deduplicationList, toNewMusicInfo } from '@/utils'
|
import { deduplicationList, toNewMusicInfo } from '@/utils'
|
||||||
import musicSdk from '@/utils/musicSdk'
|
import musicSdk from '@/utils/musicSdk'
|
||||||
@ -12,15 +12,6 @@ const cache = new Map<string, CacheValue>()
|
|||||||
const LIST_LOAD_LIMIT = 30
|
const LIST_LOAD_LIMIT = 30
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 设置要打开的歌单详情信息
|
|
||||||
* @param source
|
|
||||||
* @returns
|
|
||||||
*/
|
|
||||||
export const setSelectListInfo = (info: ListInfoItem) => {
|
|
||||||
songlistActions.clearListDetail()
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取排序列表
|
* 获取排序列表
|
||||||
* @param source
|
* @param source
|
||||||
|
@ -7,7 +7,6 @@ import { type Source } from '@/store/songlist/state'
|
|||||||
import { createStyle } from '@/utils/tools'
|
import { createStyle } from '@/utils/tools'
|
||||||
import Text from '@/components/common/Text'
|
import Text from '@/components/common/Text'
|
||||||
import { useI18n } from '@/lang'
|
import { useI18n } from '@/lang'
|
||||||
import { setSelectListInfo } from '@/core/songlist'
|
|
||||||
import { navigations } from '@/navigation'
|
import { navigations } from '@/navigation'
|
||||||
import commonState from '@/store/common/state'
|
import commonState from '@/store/common/state'
|
||||||
|
|
||||||
@ -32,7 +31,7 @@ export default forwardRef<OpenListType, {}>((props, ref) => {
|
|||||||
|
|
||||||
const handleOpenSonglist = (id: string) => {
|
const handleOpenSonglist = (id: string) => {
|
||||||
// console.log(id, songlistInfoRef.current.source)
|
// console.log(id, songlistInfoRef.current.source)
|
||||||
setSelectListInfo({
|
navigations.pushSonglistDetailScreen(commonState.componentIds.home!, {
|
||||||
play_count: undefined,
|
play_count: undefined,
|
||||||
id,
|
id,
|
||||||
author: '',
|
author: '',
|
||||||
@ -41,7 +40,6 @@ export default forwardRef<OpenListType, {}>((props, ref) => {
|
|||||||
desc: undefined,
|
desc: undefined,
|
||||||
source: songlistInfoRef.current.source,
|
source: songlistInfoRef.current.source,
|
||||||
})
|
})
|
||||||
navigations.pushSonglistDetailScreen(commonState.componentIds.home!, id)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// const handleSourceChange: ModalProps['onSourceChange'] = (source) => {
|
// const handleSourceChange: ModalProps['onSourceChange'] = (source) => {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user