mirror of
https://github.com/pipipi-pikachu/PPTist.git
synced 2025-04-15 02:20:00 +08:00
fix: 选择面板全部显示/全部隐藏仅操作当前页
This commit is contained in:
parent
f35b96b48b
commit
86be1a4cba
@ -144,10 +144,13 @@ const hideElement = (id: string) => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const showAll = () => {
|
const showAll = () => {
|
||||||
if (hiddenElementIdList.value.length) mainStore.setHiddenElementIdList([])
|
const currentSlideElIdList = currentSlide.value.elements.map(item => item.id)
|
||||||
|
const needHiddenElementIdList = hiddenElementIdList.value.filter(item => !currentSlideElIdList.includes(item))
|
||||||
|
mainStore.setHiddenElementIdList(needHiddenElementIdList)
|
||||||
}
|
}
|
||||||
const hideAll = () => {
|
const hideAll = () => {
|
||||||
mainStore.setHiddenElementIdList(currentSlide.value.elements.map(item => item.id))
|
const currentSlideElIdList = currentSlide.value.elements.map(item => item.id)
|
||||||
|
mainStore.setHiddenElementIdList([...hiddenElementIdList.value, ...currentSlideElIdList])
|
||||||
if (activeElementIdList.value.length) mainStore.setActiveElementIdList([])
|
if (activeElementIdList.value.length) mainStore.setActiveElementIdList([])
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user