ofcold-vue-security-code

A powerful security code input supports dynamic configuration of the number of input boxes.
4,292 61
Install
npm install ofcold-vue-security-code
Latest Version:2.6.0
Vue:3
License:MIT
Last Updated:Aug 5, 2021
Links: GitHub  ·  npm
Maintainer: olivia-bill

Ofcold Security Code

A powerful security code input supports dynamic configuration of the number of input boxes.

Features

  • Automatic next input box.
  • Page initialization automatic countdown.
  • The number of custom input boxes.
  • Support copy and paste.
  • Support tailwindcss by version >=2.0.0

Installation

npm install --save ofcold-vue-security-code

// OR

yarn add ofcold-vue-security-code

Usage

<!-- Html  -->
<input-code v-model="code"/>
VUE 2.0 And 3.0
// Javascript
import InputCode from 'ofcold-vue-security-code';

export default {
	data:() => ({
		code: ''
	}),
	components: {
		InputCode
	}
}

// OR ...
import {defineComponent, ref} from 'vue'
import InputCode from 'ofcold-vue-security-code'

export default defineComponent({
	components: {
		InputCode
	},
	setup(props, ctx) {
		const code = ref('')

		return {
			code
		}
	}
})

API

  • isArray Deprecated version 2.x please use returnArray.
  • returnArray boolean default false The return data type.
  • val string|array default ''.
  • len The code length default 6.
  • size The input size default md The options are small, default, lg, xl.

Example loading...

CODE

Related Packages

ofcold-security-code

A powerful security code input supports dynamic configuration of the number of i...

800 61
atalevue

a vue module

1,819
vue-slug-input

An input that transforms strings to slugs

12,733 0
@justfork/maska

Simple zero-dependency input mask for Vue.js and vanilla JS

4,780 2,021
@gits-id/modal

GITS Modal Component

3,059

Version History

Version Released Vue License
2.6.0 ^3.0.0 MIT
2.4.0 ^3.0.0 MIT
2.3.0 ^3.0.0 MIT
2.2.0 ^3.0.0 MIT