diff --git a/package.json b/package.json index 0168f81..9596e4a 100644 --- a/package.json +++ b/package.json @@ -1,5 +1,5 @@ { - "name": "hamster_ppt", + "name": "pptist", "version": "0.0.1", "private": true, "scripts": { diff --git a/src/hooks/useLockElement.ts b/src/hooks/useLockElement.ts index bdddfaf..6ffa14a 100644 --- a/src/hooks/useLockElement.ts +++ b/src/hooks/useLockElement.ts @@ -18,6 +18,7 @@ export default () => { if(activeElementIdList.value.includes(element.id)) element.lock = true } store.commit(MutationTypes.UPDATE_SLIDE, { elements: newElementList }) + store.commit(MutationTypes.SET_ACTIVE_ELEMENT_ID_LIST, []) addHistorySnapshot() } @@ -38,6 +39,7 @@ export default () => { } } store.commit(MutationTypes.UPDATE_SLIDE, { elements: newElementList }) + store.commit(MutationTypes.SET_ACTIVE_ELEMENT_ID_LIST, [handleElement.id]) addHistorySnapshot() } diff --git a/src/hooks/useScreening.ts b/src/hooks/useScreening.ts index a8b2f6d..6cbcd0b 100644 --- a/src/hooks/useScreening.ts +++ b/src/hooks/useScreening.ts @@ -10,6 +10,11 @@ export default () => { store.commit(MutationTypes.SET_SCREENING, true) } + const enterScreeningFromStart = () => { + store.commit(MutationTypes.UPDATE_SLIDE_INDEX, 0) + enterScreening() + } + const exitScreening = () => { store.commit(MutationTypes.SET_SCREENING, false) if(isFullscreen()) exitFullscreen() @@ -17,6 +22,7 @@ export default () => { return { enterScreening, + enterScreeningFromStart, exitScreening, } } \ No newline at end of file diff --git a/src/views/Editor/Canvas/MouseSelection.vue b/src/views/Editor/Canvas/MouseSelection.vue index e69d47a..10b9066 100644 --- a/src/views/Editor/Canvas/MouseSelection.vue +++ b/src/views/Editor/Canvas/MouseSelection.vue @@ -43,7 +43,8 @@ export default {