vue-phone-number-input icon indicating copy to clipboard operation
vue-phone-number-input copied to clipboard

Country names

Open webistomin opened this issue 5 years ago • 4 comments

Hi! Is there a way to translate country names?😢

https://github.com/LouisMazel/vue-phone-number-input/blob/master/src/VuePhoneNumberInput/assets/js/phoneCodeCountries.js

webistomin avatar Jan 24 '20 16:01 webistomin

What is the best ? Each country in the language of the country?

LouisMazel avatar Jan 29 '20 18:01 LouisMazel

What is the best ? Each country in the language of the country?

I think you should add language prop with type Array. Default value for the prop will be your array. So we can use it like this:

<template>
  <VuePhoneNumberInput v-model="yourValue" :language="language" />
</template>

<script>
  import { ru } from 'vue-phone-number-input/dist/locale'

  export default {
    data() {
     return {
       language: ru,
     }
    }
  };
</script>

People can contribute their own translation to your project.

webistomin avatar Feb 01 '20 07:02 webistomin

How can I clear the VuePhoneNumberInput after form submitting? I tried to make model to null but the green border still exits even the number disappears. Is there any way of doing it thanks 👍

NuwanDhanushka avatar Feb 08 '20 23:02 NuwanDhanushka

@LouisMazel is there a way to translate the country names in the list?

ahmadjaffal avatar Sep 07 '22 10:09 ahmadjaffal