aboutsummaryrefslogtreecommitdiff
path: root/src/tools/ipv4-range-expander/result-row.vue
blob: b1782fea309f898dbeb7711a37b7b440616ff82d (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
<template>
  <tr>
    <td>
      <n-text strong>{{ label }}</n-text>
    </td>
    <td :data-test-id="testId + '.old'"><span-copyable :value="oldValue" class="monospace" /></td>
    <td :data-test-id="testId + '.new'">
      <span-copyable :value="newValue"></span-copyable>
    </td>
  </tr>
</template>

<script setup lang="ts">
import SpanCopyable from '@/components/SpanCopyable.vue';
import _ from 'lodash';

const props = withDefaults(defineProps<{ label: string; oldValue?: string; newValue?: string }>(), {
  label: '',
  oldValue: '',
  newValue: '',
});
const { label, oldValue, newValue } = toRefs(props);

const testId = computed(() => _.kebabCase(label.value));
</script>

<style scoped lang="less"></style>