mirror of
				https://github.com/lingble/chatwoot.git
				synced 2025-11-04 04:57:51 +00:00 
			
		
		
		
	These fixes are all auto generated and can be merged directly Fixes the following issues 1. Event used on components should be hypenated 2. Attribute orders in components 3. Use `unmounted` instead of `destroyed` 4. Add explicit `emits` declarations for components, autofixed [using this script](https://gist.github.com/scmmishra/6f549109b96400006bb69bbde392eddf) We ignore the top level v-if for now, we will fix it later
		
			
				
	
	
		
			43 lines
		
	
	
		
			1.1 KiB
		
	
	
	
		
			Vue
		
	
	
	
	
	
			
		
		
	
	
			43 lines
		
	
	
		
			1.1 KiB
		
	
	
	
		
			Vue
		
	
	
	
	
	
<script>
 | 
						|
import FluentIcon from 'shared/components/FluentIcon/Index.vue';
 | 
						|
 | 
						|
export default {
 | 
						|
  name: 'FooterReplyTo',
 | 
						|
  components: { FluentIcon },
 | 
						|
  props: {
 | 
						|
    inReplyTo: {
 | 
						|
      type: Object,
 | 
						|
      default: () => {},
 | 
						|
    },
 | 
						|
  },
 | 
						|
  emits: ['dismiss'],
 | 
						|
  computed: {
 | 
						|
    replyToAttachment() {
 | 
						|
      if (!this.inReplyTo?.attachments?.length) {
 | 
						|
        return '';
 | 
						|
      }
 | 
						|
 | 
						|
      const [{ file_type: fileType } = {}] = this.inReplyTo.attachments;
 | 
						|
      return this.$t(`ATTACHMENTS.${fileType}.CONTENT`);
 | 
						|
    },
 | 
						|
  },
 | 
						|
};
 | 
						|
</script>
 | 
						|
 | 
						|
<template>
 | 
						|
  <div
 | 
						|
    class="mb-2.5 rounded-[7px] dark:bg-slate-900 dark:text-slate-100 bg-slate-100 px-2 py-1.5 text-sm text-slate-700 flex items-center gap-2"
 | 
						|
  >
 | 
						|
    <div class="items-center flex-grow truncate">
 | 
						|
      <strong>{{ $t('FOOTER_REPLY_TO.REPLY_TO') }}</strong>
 | 
						|
      {{ inReplyTo.content || replyToAttachment }}
 | 
						|
    </div>
 | 
						|
    <button
 | 
						|
      class="items-end flex-shrink-0 p-1 rounded-md hover:bg-slate-200 dark:hover:bg-slate-800"
 | 
						|
      @click="$emit('dismiss')"
 | 
						|
    >
 | 
						|
      <FluentIcon icon="dismiss" size="12" />
 | 
						|
    </button>
 | 
						|
  </div>
 | 
						|
</template>
 |