wujingjing
2024-07-29 20d6664273b55c0c7a625702008b3769920ba4c4
地图调整
已修改1个文件
13 ■■■■ 文件已修改
src/components/chat/chatComponents/mapCom/MapCom.vue 13 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/components/chat/chatComponents/mapCom/MapCom.vue
@@ -11,7 +11,7 @@
                    :class="{ 'icon-zuoyoujiantou': chartIsShow, 'icon-zuoyoujiantou1': !chartIsShow }"
                ></div>
            </div>
            <RecordSet v-if="chartIsShow" :data="CHART_DATA" class="h-[23vh] mt-2" />
            <RecordSet v-if="chartIsShow" chartHeight="23vh" :data="CHART_DATA" class="mt-2" />
        </div>
    </div>
</template>
@@ -32,9 +32,9 @@
    data: MapData;
};
const createInfoWindow = () => {
    const dom = `<div class="bg-white p-1 flex flex-col border-blue-500 border-solid border">
            <div class="pointer-title bg-[#ca0dab] flex-center py-1 text-white px-5">
    const dom = `<div class="w-48 bg-white p-1 flex flex-col border-blue-500 border-solid border">
            <div class="bg-[#ca0dab] flex py-1 text-white px-5">
                <div class="pointer-title  text-nowrap overflow-hidden text-ellipsis mx-auto"></div>
            </div>
        
        </div>`;
@@ -61,7 +61,7 @@
const updateInfoWindow = (title: string) => {
    const pointerTitle = infoWindow.dom.querySelector('.pointer-title');
    pointerTitle.innerHTML = title;
    pointerTitle.innerHTML = title +'';
};
const addMarkerLayer = () => {
@@ -117,9 +117,10 @@
    addMarkerLayer();
    infoWindow = new AMap.InfoWindow({
        content: createInfoWindow(),
        offset: new AMap.Pixel(0, -18),
        offset: [3,-34],
        closeWhenClickMap: true,
    });
});
</script>
<style scoped lang="scss">