25 lines
549 B
Vue
25 lines
549 B
Vue
<template>
|
|
<vc-entity :show="show" :position="position">
|
|
<vc-graphics-billboard :image="image" :verticalOrigin="1" />
|
|
</vc-entity>
|
|
</template>
|
|
|
|
<script setup>
|
|
import { computed } from 'vue'
|
|
import { VcEntity, VcGraphicsBillboard } from 'vue-cesium'
|
|
import { isLnglat } from '/@/api/util'
|
|
import pin from '/@/assets/pin.png'
|
|
|
|
const props = defineProps({
|
|
position: {
|
|
type: Object,
|
|
default: { lng: NaN, lat: NaN },
|
|
},
|
|
image: {
|
|
type: String,
|
|
default: pin,
|
|
}
|
|
})
|
|
|
|
const show = computed(() => isLnglat(props.position))
|
|
</script> |