Skip to content

Commit b680077

Browse files
committed
chore: update track
1 parent 0a9c214 commit b680077

3 files changed

Lines changed: 5 additions & 5 deletions

File tree

src/renderer/components/snippets/SnippetHeader.vue

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,6 @@ const onCodePreview = () => {
121121
122122
const onClickPresentationMode = () => {
123123
router.push('/presentation')
124-
track('snippets/presentation-mode')
125124
}
126125
127126
emitter.on('snippet:focus-name', () => {

src/renderer/views/Presentation.vue

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@
7676
</template>
7777

7878
<script setup lang="ts">
79-
import { i18n, store } from '@/electron'
79+
import { i18n, store, track } from '@/electron'
8080
import { useSnippetStore } from '@/store/snippets'
8181
import { computed, ref, watch } from 'vue'
8282
import { useRouter } from 'vue-router'
@@ -153,6 +153,8 @@ watch(right, v => {
153153
watch(escape, v => {
154154
if (v) toHome()
155155
})
156+
157+
track('presentation')
156158
</script>
157159

158160
<style lang="scss" scoped>

src/shared/types/main/analytics.d.ts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ type SnippetEvents =
1616
| 'format'
1717
| 'markdown-preview'
1818
| 'move-to-trash'
19-
| 'presentation-mode'
2019
| 'search'
2120
| 'set-language'
2221

@@ -37,6 +36,7 @@ type AppEvents =
3736
| 'set-language'
3837

3938
type ApiEvents = 'snippet-create'
39+
type PageEvents = 'main' | 'preferences' | 'presentation'
4040

4141
type TrackSnippetEvents = CombineWith<SnippetEvents, 'snippets'>
4242
type TrackFolderEvents = CombineWith<FolderEvents, 'folders'>
@@ -50,5 +50,4 @@ export type TrackEvents =
5050
| TrackTagEvents
5151
| TrackAppEvents
5252
| TrackApiEvents
53-
| 'main'
54-
| 'preferences'
53+
| PageEvents

0 commit comments

Comments
 (0)