vue cool select
v3.5.2
현재 버전은 3.x
입니다. 2.x
찾고 있다면 여기에서 찾을 수 있습니다(또한 주요 변경 사항 참조).
종속성 없음
props(30)를 사용하면 다양한 방법으로 구성 요소를 사용자 정의할 수 있습니다.
슬롯(13)을 통해 어디에서나 콘텐츠를 변경할 수 있습니다.
이벤트 (8)는 모든 것에 대해 알려줄 것입니다
자동 완성(사용자 정의 검색을 사용할 수 있으며 검색 입력을 비활성화할 수도 있습니다)
키보드 컨트롤(화살표 뿐만 아니라)
모바일 장치에서 지원
유효성 검사, 오류 상태 및 성공
비활성화 및 읽기 전용
작은 크기와 큰 크기(부트스트랩에서와 같이)
스타일을 설정하는 기능을 사용하면 처음부터 테마를 작성할 수 있습니다. 2가지 테마: 부트스트랩 4(동일 스타일), 머티리얼 디자인
타입스크립트 지원
탭 탐색
SSR(서버 측 렌더링)
메뉴가 뷰포트를 벗어나면 메뉴의 적절한 위치를 자동으로 결정합니다.
귀하의 제안을 작성해 주세요. 추가하게 되어 기쁘게 생각합니다.
yarn add vue-cool-select
또는 npm install --save vue-cool-select
Vue.use
를 통해 플러그인을 추가하세요. import { CoolSelectPlugin } from 'vue-cool-select'
// paste the line below only if you need "bootstrap" theme
import 'vue-cool-select/dist/themes/bootstrap.css'
// paste the line below only if you need "material-design" theme
import 'vue-cool-select/dist/themes/material-design.css'
// you can also import your theme
Vue . use ( CoolSelectPlugin )
import { CoolSelect } from 'vue-cool-select'
export default {
components : { CoolSelect } ,
data ( ) {
return {
// simple example of items
items : [ 'Item 1' , 'Item 2' , 'Item 3' ] ,
// there will be a selected item
selected : null
}
}
}
<template>
에 추가: < cool-select
v-model = " selected "
: items = " items "
/>
페이지에 vue-cool-select를 포함합니다.
< script src =" https://unpkg.com/vue-cool-select " > </ script >
<!-- paste the line below only if you need "bootstrap" theme -->
< link rel =" stylesheet " href =" https://unpkg.com/vue-cool-select/dist/themes/bootstrap.css " >
<!-- paste the line below only if you need "material-design" theme -->
< link rel =" stylesheet " href =" https://unpkg.com/vue-cool-select/dist/themes/material-design.css " >
페이지에서 Vue가 감지되면 플러그인이 자동으로 설치됩니다.
문서 및 예제는 여기에 있습니다.
뭔가를 추가하거나 개선할 수 있어서 기쁘네요. 보고 싶은 것을 쓰셔도 됩니다. 별점을 주시면 저도 일할 의욕이 더 생기네요. 감사합니다! ?