Skip to content

Commit

Permalink
fix: global layer pointer events, close #216
Browse files Browse the repository at this point in the history
  • Loading branch information
antfu committed Jun 3, 2021
1 parent f53f07b commit f4cc0ce
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 12 deletions.
2 changes: 1 addition & 1 deletion cypress/fixtures/basic/global.vue
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<template>
<div
v-if="$slidev.nav.currentPage % 2 === 1"
class="absolute bottom-0 right-0 p-10"
class="absolute bottom-0 right-0 m-10 hover:text-red-400"
>
Global Footer (appear only on odd page)
</div>
Expand Down
12 changes: 2 additions & 10 deletions packages/client/internals/SlidesShow.vue
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,7 @@ watch(currentRoute, () => {

<template>
<!-- Global Bottom -->
<SlideWrapper>
<div class="slidev-global-bottom -z-1 absolute top-0 left-0 bottom-0 right-0 w-full h-full">
<GlobalBottom />
</div>
</SlideWrapper>
<GlobalBottom />

<!-- Slides -->
<template v-for="route of rawRoutes" :key="route.path">
Expand All @@ -39,9 +35,5 @@ watch(currentRoute, () => {
</template>
<!-- Global Top -->
<SlideWrapper>
<div class="slidev-global-top absolute top-0 left-0 bottom-0 right-0 w-full h-full">
<GlobalTop />
</div>
</SlideWrapper>
<GlobalTop />
</template>
1 change: 0 additions & 1 deletion packages/slidev/node/plugins/loaders.ts
Original file line number Diff line number Diff line change
Expand Up @@ -451,7 +451,6 @@ export function createSlidesLoader(
if (layer === 'top') {
return [
join(root, 'global.vue'),
join(root, 'Global.vue'),
join(root, 'global-top.vue'),
join(root, 'GlobalTop.vue'),
]
Expand Down

0 comments on commit f4cc0ce

Please sign in to comment.