2023-05-28 23:13:24 +02:00
|
|
|
<script setup lang="ts">
|
|
|
|
import { textToNatoAlphabet } from './text-to-nato-alphabet.service';
|
feat(Text to NATO): add other languages, upper/lower and other
Add support for many languages and countries ((International), (France), (Belgium), (Switzerland), (Québec), (Germany, 2022), (Austria), (Germany, informal, 2022), (Netherlands), Italian, Spanish, (Brazil), (Portugal), Swedish, Danish, Norwegian, Finnish, Turkish, Romanian, Czech, Yugoslav, Serbian, Slovene, Russian, Korean, Greek, Japanese)
Handle uppercase/lowercase and some punctuations
Fix #794
2024-04-02 08:57:13 +02:00
|
|
|
import { allLanguagesAndCountries } from './text-to-nato-alphabet.constants';
|
2023-05-28 23:13:24 +02:00
|
|
|
import { useCopy } from '@/composable/copy';
|
|
|
|
|
feat(Text to NATO): add other languages, upper/lower and other
Add support for many languages and countries ((International), (France), (Belgium), (Switzerland), (Québec), (Germany, 2022), (Austria), (Germany, informal, 2022), (Netherlands), Italian, Spanish, (Brazil), (Portugal), Swedish, Danish, Norwegian, Finnish, Turkish, Romanian, Czech, Yugoslav, Serbian, Slovene, Russian, Korean, Greek, Japanese)
Handle uppercase/lowercase and some punctuations
Fix #794
2024-04-02 08:57:13 +02:00
|
|
|
const lang = useStorage('text-to-nato:lang', '(International)');
|
2023-05-28 23:13:24 +02:00
|
|
|
const input = ref('');
|
feat(Text to NATO): add other languages, upper/lower and other
Add support for many languages and countries ((International), (France), (Belgium), (Switzerland), (Québec), (Germany, 2022), (Austria), (Germany, informal, 2022), (Netherlands), Italian, Spanish, (Brazil), (Portugal), Swedish, Danish, Norwegian, Finnish, Turkish, Romanian, Czech, Yugoslav, Serbian, Slovene, Russian, Korean, Greek, Japanese)
Handle uppercase/lowercase and some punctuations
Fix #794
2024-04-02 08:57:13 +02:00
|
|
|
const natoText = computed(() => textToNatoAlphabet({ text: input.value, langOrCountry: lang.value }));
|
2023-05-28 23:13:24 +02:00
|
|
|
const { copy } = useCopy({ source: natoText, text: 'NATO alphabet string copied.' });
|
|
|
|
</script>
|
|
|
|
|
2023-02-15 00:43:08 +01:00
|
|
|
<template>
|
|
|
|
<div>
|
feat(Text to NATO): add other languages, upper/lower and other
Add support for many languages and countries ((International), (France), (Belgium), (Switzerland), (Québec), (Germany, 2022), (Austria), (Germany, informal, 2022), (Netherlands), Italian, Spanish, (Brazil), (Portugal), Swedish, Danish, Norwegian, Finnish, Turkish, Romanian, Czech, Yugoslav, Serbian, Slovene, Russian, Korean, Greek, Japanese)
Handle uppercase/lowercase and some punctuations
Fix #794
2024-04-02 08:57:13 +02:00
|
|
|
<c-select
|
|
|
|
v-model:value="lang"
|
|
|
|
:options="allLanguagesAndCountries"
|
|
|
|
searchable
|
|
|
|
/>
|
|
|
|
|
2023-05-14 21:26:18 +02:00
|
|
|
<c-input-text
|
|
|
|
v-model:value="input"
|
|
|
|
label="Your text to convert to NATO phonetic alphabet"
|
|
|
|
placeholder="Put your text here..."
|
|
|
|
clearable
|
|
|
|
mb-5
|
|
|
|
/>
|
2023-02-15 00:43:08 +01:00
|
|
|
|
2023-05-27 17:36:15 +02:00
|
|
|
<div v-if="natoText">
|
2023-06-25 15:49:43 +02:00
|
|
|
<div mb-2>
|
feat(Text to NATO): add other languages, upper/lower and other
Add support for many languages and countries ((International), (France), (Belgium), (Switzerland), (Québec), (Germany, 2022), (Austria), (Germany, informal, 2022), (Netherlands), Italian, Spanish, (Brazil), (Portugal), Swedish, Danish, Norwegian, Finnish, Turkish, Romanian, Czech, Yugoslav, Serbian, Slovene, Russian, Korean, Greek, Japanese)
Handle uppercase/lowercase and some punctuations
Fix #794
2024-04-02 08:57:13 +02:00
|
|
|
Your text in NATO phonetic alphabet ({{ lang }})
|
2023-06-25 15:49:43 +02:00
|
|
|
</div>
|
2023-04-20 20:49:28 +02:00
|
|
|
<c-card>
|
2023-02-15 00:43:08 +01:00
|
|
|
{{ natoText }}
|
2023-04-20 20:49:28 +02:00
|
|
|
</c-card>
|
2023-02-15 00:43:08 +01:00
|
|
|
|
2023-05-27 17:36:15 +02:00
|
|
|
<div mt-3 flex justify-center>
|
2023-08-10 00:07:44 +02:00
|
|
|
<c-button autofocus @click="copy()">
|
2023-05-28 23:13:24 +02:00
|
|
|
Copy NATO string
|
|
|
|
</c-button>
|
2023-05-27 17:36:15 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
2023-02-15 00:43:08 +01:00
|
|
|
</div>
|
|
|
|
</template>
|