tanghaolin
3 天以前 5ab9267c972308b7d1b250071d3d48ff98f23254
src/components/CustomerService.vue
@@ -8,7 +8,7 @@
const emit = defineEmits(['close']);
import { ref, onMounted } from 'vue';
import { ChildRegister, setParentFunction } from '@/utils/iframeCall';
import { ChildRegister } from '@/utils/iframeCall';
const getUrl = () => {
   const isDev = import.meta.env.DEV;
   if (isDev) {
@@ -25,11 +25,11 @@
   window.addEventListener('message', (event) => {
      if (event.data.type === 'close') {
         emit('close');
      } else if (event.data.type === 'childIsReady') {
         console.log('🚀 ~ child is ready',);
         ChildRegister.registerNotifyFunction();
      }
   });
   setTimeout(() => {
      ChildRegister.registerNotifyFunction();
   }, 800);
});
</script>
<style scoped lang="scss"></style>