We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bc24a8a commit b2b2e23Copy full SHA for b2b2e23
src/packages/__VUE/empty/empty.vue
@@ -58,15 +58,7 @@ const style = computed(() => {
58
return {}
59
})
60
61
-const src = computed(() => {
62
- if (props.image.startsWith('https://') || props.image.startsWith('http://') || props.image.startsWith('//')) {
63
- return props.image
64
- } else {
65
- return defaultStatus[props.image]
66
- }
67
-})
+const src = computed(() => /^https?:\/\/|^\/\//.test(props.image) ? props.image : defaultStatus[props.image])
68
69
-const descriptionText = computed(() => {
70
- return props.description || translate('noData')
71
+const descriptionText = computed(() => props.description || translate('noData'))
72
</script>
0 commit comments