0.1.34 • Published 1 year ago

ntl-ui v0.1.34

Weekly downloads
-
License
MIT
Repository
-
Last release
1 year ago

international ui

This is ntl-ui, a set of ui libraries for internationalization. For Vue 2.x. (But Now there is only one component: national-input)

How to install

npm install ntl-ui -S

Quick Start

import Vue from 'vue'
import Ntl from 'ntl-ui'

Vue.use(Ntl)

// or
import {
  NtlInput,
  // ...
} from 'ntl-ui'

Vue.component(NtlInput.name, NtlInput)

Explain

  <itl-input v-model="phoneValue" />
  
  // itl-input main options:
  
  props: {
    value: { // International number
      default() {
        return ''
      }
    },
    options: {
      default() {
        return {
          iso: '', // National iso code
          hoverStatus: true, // Whether to display specific information when opening the floating flag
          focusStatus: true, // Whether to turn on focus display of head text
          placeholder: 'Enter Number', // Input box placeholder
          errorSlot: false, // Whether to enable the placeholder of error prompt
          errorMsg: 'Please input validate PhoneNumber!', // Verification failure error message
          validate: true // Enable verification
        }
      }
    },
  },
  methods: {
    PhoneNumber // Receive a number and return the corresponding international information, specific documents:https://www.npmjs.com/package/libphonenumber-js#min-vs-max-vs-mobile-vs-core
    isValidPhoneNumber:// Check the number
    ...
  }
  
0.1.34

1 year ago

0.1.33

1 year ago

0.1.32

1 year ago

0.1.31

1 year ago

0.1.3

1 year ago

0.1.21

1 year ago

0.1.2

1 year ago

0.1.1

1 year ago

0.1.0

1 year ago