Intercom.vue 850 B

123456789101112131415161718192021222324252627282930313233343536
  1. <template>
  2. <n-button text :disabled="intercomDisabled === 'loading'" @click="intercomClick">
  3. <template #icon>
  4. <Icon
  5. v-if="intercomDisabled === 'close'"
  6. icon="material-symbols:record-voice-over-outline"
  7. width="22"
  8. height="22"
  9. />
  10. <Icon
  11. v-else-if="intercomDisabled === 'loading'"
  12. icon="eos-icons:three-dots-loading"
  13. width="22"
  14. height="22"
  15. />
  16. <Icon
  17. v-else
  18. class="fade-open"
  19. icon="icon-park-outline:voice"
  20. width="22"
  21. height="22"
  22. color="red"
  23. />
  24. </template>
  25. </n-button>
  26. </template>
  27. <script setup>
  28. import { IntercomFn } from '@/utils/Intercom';
  29. const intercomDisabled = ref('close');
  30. const intercomClick = () => {
  31. // IntercomFn(intercomDisabled.value, props.data.id);
  32. };
  33. </script>