Skip to content

Commit c3d6766

Browse files
committed
fix: The image displayed by the application cannot be enlarged by clicking #3663
1 parent 83a1ffb commit c3d6766

File tree

1 file changed

+4
-12
lines changed

1 file changed

+4
-12
lines changed

ui/src/components/markdown/MdPreview.vue

Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<template>
2-
<MdPreview :language="language" noIconfont noPrettier :codeFoldable="false" v-bind="$attrs" @click.stop="handleClick"/>
2+
<MdPreview :language="language" noIconfont noPrettier :codeFoldable="false" v-bind="$attrs" />
33
</template>
44

55
<script setup lang="ts">
@@ -19,18 +19,10 @@ const language = computed(() => user.getLanguage() || getBrowserLang() || '')
1919
config({
2020
editorConfig: {
2121
languageUserDefined: {
22-
'zh-Hant': ZH_TW
23-
}
24-
}
22+
'zh-Hant': ZH_TW,
23+
},
24+
},
2525
})
26-
27-
function handleClick(e: MouseEvent) {
28-
if ((e.target as HTMLElement).closest('a') || (e.target as HTMLElement).closest('.md-editor-copy-button')) {
29-
e.stopPropagation()
30-
} else {
31-
emit('clickPreview')
32-
}
33-
}
3426
</script>
3527

3628
<style lang="scss" scoped>

0 commit comments

Comments
 (0)