mirror of
https://github.com/CorentinTh/it-tools.git
synced 2025-04-30 19:39:14 -04:00
chore(lint): switched to a better lint config
This commit is contained in:
parent
4d2b037dbe
commit
33c9b6643f
178 changed files with 4105 additions and 3371 deletions
|
@ -1,36 +1,3 @@
|
|||
<template>
|
||||
<div>
|
||||
<n-alert title="Info" type="info">
|
||||
This tool uses the first method suggested by IETF using the current timestamp plus the mac address, sha1 hashed,
|
||||
and the lower 40 bits to generate your random ULA.
|
||||
</n-alert>
|
||||
|
||||
<c-input-text
|
||||
v-model:value="macAddress"
|
||||
placeholder="Type a MAC address"
|
||||
clearable
|
||||
label="MAC address:"
|
||||
raw-text
|
||||
my-8
|
||||
:validation="addressValidation"
|
||||
/>
|
||||
|
||||
<div v-if="addressValidation.isValid">
|
||||
<input-copyable
|
||||
v-for="{ label, value } in calculatedSections"
|
||||
:key="label"
|
||||
:value="value"
|
||||
:label="label"
|
||||
label-width="160px"
|
||||
label-align="right"
|
||||
label-position="left"
|
||||
readonly
|
||||
mb-2
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { SHA1 } from 'crypto-js';
|
||||
import InputCopyable from '@/components/InputCopyable.vue';
|
||||
|
@ -43,7 +10,7 @@ const calculatedSections = computed(() => {
|
|||
.toString()
|
||||
.substring(30);
|
||||
|
||||
const ula = 'fd' + hex40bit.substring(0, 2) + ':' + hex40bit.substring(2, 6) + ':' + hex40bit.substring(6);
|
||||
const ula = `fd${hex40bit.substring(0, 2)}:${hex40bit.substring(2, 6)}:${hex40bit.substring(6)}`;
|
||||
|
||||
return [
|
||||
{
|
||||
|
@ -64,4 +31,35 @@ const calculatedSections = computed(() => {
|
|||
const addressValidation = macAddressValidation(macAddress);
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped></style>
|
||||
<template>
|
||||
<div>
|
||||
<n-alert title="Info" type="info">
|
||||
This tool uses the first method suggested by IETF using the current timestamp plus the mac address, sha1 hashed,
|
||||
and the lower 40 bits to generate your random ULA.
|
||||
</n-alert>
|
||||
|
||||
<c-input-text
|
||||
v-model:value="macAddress"
|
||||
placeholder="Type a MAC address"
|
||||
clearable
|
||||
label="MAC address:"
|
||||
raw-text
|
||||
my-8
|
||||
:validation="addressValidation"
|
||||
/>
|
||||
|
||||
<div v-if="addressValidation.isValid">
|
||||
<InputCopyable
|
||||
v-for="{ label, value } in calculatedSections"
|
||||
:key="label"
|
||||
:value="value"
|
||||
:label="label"
|
||||
label-width="160px"
|
||||
label-align="right"
|
||||
label-position="left"
|
||||
readonly
|
||||
mb-2
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue