view client/src/components/importoverview/LogItem.vue @ 5627:7768f14f6535 729-node-js-newer-version

Transformed scss variables into css custom properties
author Luisa Beerboom <lbeerboom@intevation.de>
date Tue, 09 May 2023 13:17:58 +0200
parents 5e62c467e145
children 84d01a536bec
line wrap: on
line source

<template>
  <div>
    <span
      :class="[
        'kind',
        {
          'text-danger': /error/.test(line.kind),
          'text-warning': /warn/.test(line.kind),
          'font-weight-bold': /warn|error/.test(line.kind)
        }
      ]"
      >{{ line.kind.toUpperCase() }}
    </span>
    <span
      :class="[
        'time',
        {
          'text-danger': /error/.test(line.kind),
          'text-warning': /warn/.test(line.kind),
          'font-weight-bold': /warn|error/.test(line.kind)
        }
      ]"
      >{{ line.time | dateTime }}
    </span>
    <span
      :class="[
        'message',
        {
          'text-danger': /error/.test(line.kind),
          'text-warning': /warn/.test(line.kind),
          'font-weight-bold': /warn|error/.test(line.kind)
        }
      ]"
      >{{ line.message }}
    </span>
  </div>
</template>

<script>
export default {
  name: "Item",
  props: ["height", "line", "index"]
};
</script>

<style lang="sass" scoped>
.kind
  width: 9%

.time
  width: 26%

.message
  width: 65%
  word-wrap: break-word
</style>