1.0.4 • Published 4 years ago

vue2-easy-controls v1.0.4

Weekly downloads
23
License
-
Repository
github
Last release
4 years ago

Vue Easy Controls

An easy to use Checkbox and Radio components for Vue 2

Installing

npm i vue2-easy-controls

OR

yarn add vue2-easy-controls

Usage

Registering components globally

import { EasyCheckbox, EasyRadio } from 'vue2-easy-controls'

Vue.use(EasyCheckbox)
Vue.use(EasyRadio)

Registering components locally

import { EasyCheckbox, EasyRadio } from 'vue2-easy-controls'

export default {
  name: 'MyLocalComponent'
  components: {
    EasyCheckbox,
    EasyRadio
  }
}

Usage

data () {
  return {
    isChecked: false
  }
}
  <easy-checkbox text="Checkbox component" v-model="isChecked" />

OR

  <easy-radio text="Radio component" v-model="isChecked" />

For more examples check here

NOTE: Props for both of the components are the same

Props

PropTypeDefault
valueAny
checkedBooleanfalse
disabledBooleanfalse
requiredBooleanfalse
textString
labelStyleObject{ color (default: #3D4066), fontSize (default: '16px'), marginLeft (default: '8px'), marginRight: (default: '8px') }
labelOnLeftBooleanfalse
showBooleantrue

TODO:

  • Make components more customizable (custom style, custom icons etc.)
  • Make components more accessible
  • Improve documentation by adding live examples
  • Add switch component
1.0.4

4 years ago

1.0.3

4 years ago

1.0.2

4 years ago

1.0.1

4 years ago

1.0.0

4 years ago