AttributeTextarea.vue 540 B

1234567891011121314151617
  1. <!-- Copyright (C) 2012-2025 Zammad Foundation, https://zammad-foundation.org/ -->
  2. <script setup lang="ts">
  3. /* eslint-disable vue/no-v-html */
  4. import { textToHtml } from '#shared/utils/helpers.ts'
  5. import type { ObjectAttributeTextarea } from './attributeTextareaTypes.ts'
  6. import type { ObjectAttributeProps } from '../../types.ts'
  7. defineProps<ObjectAttributeProps<ObjectAttributeTextarea, string>>()
  8. </script>
  9. <template>
  10. <div v-if="mode === 'view'" v-html="textToHtml(value)" />
  11. <template v-else>{{ value }}</template>
  12. </template>